auto import from //depot/cupcake/@135843
diff --git a/apps/Development/Android.mk b/apps/Development/Android.mk
deleted file mode 100644
index 9578e79..0000000
--- a/apps/Development/Android.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := eng development tests
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-LOCAL_STATIC_JAVA_LIBRARIES := googlelogin-client
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files) \
-                src/com/android/development/IRemoteService.aidl \
-
-LOCAL_PACKAGE_NAME := Development
-LOCAL_CERTIFICATE := platform
-
-include $(BUILD_PACKAGE)
diff --git a/apps/Development/AndroidManifest.xml b/apps/Development/AndroidManifest.xml
deleted file mode 100644
index 879e7d6..0000000
--- a/apps/Development/AndroidManifest.xml
+++ /dev/null
@@ -1,136 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-        package="com.android.development"
-        android:versionCode="1" android:versionName="1.0">
-    <uses-permission android:name="android.permission.WRITE_SETTINGS" />
-    <uses-permission android:name="android.permission.DUMP" />
-    <uses-permission android:name="android.permission.SET_PREFERRED_APPLICATIONS" />
-    <uses-permission android:name="android.permission.RESTART_PACKAGES" />
-    <uses-permission android:name="android.permission.SET_ANIMATION_SCALE" />
-    <uses-permission android:name="android.permission.SET_PROCESS_LIMIT" />
-    <uses-permission android:name="android.permission.SET_ALWAYS_FINISH" />
-    <uses-permission android:name="android.permission.SET_DEBUG_APP" />
-    <uses-permission android:name="android.permission.HARDWARE_TEST" />
-    <uses-permission android:name="android.permission.INTERNET" />
-    <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH" />
-    <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH.ALL_SERVICES" />
-    <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH.YouTubeUser" />
-    <uses-permission android:name="com.google.android.googleapps.permission.ACCESS_GOOGLE_PASSWORD" />
-
-    <application android:label="Dev Tools"
-            android:icon="@drawable/ic_launcher_devtools">
-
-        <uses-library android:name="android.test.runner" />
-        <uses-library android:name="com.google.android.maps" />
-
-        <activity android:name="Development" android:label="Dev Tools"
-            android:icon="@drawable/ic_launcher_devtools">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-        <activity android:name="PackageBrowser" android:label="Package Browser">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-        <activity android:name="ExceptionBrowser" android:label="Exception Browser">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-        <activity android:name="StacktraceViewer" android:label="Stacktrace Viewer"/>
-        <activity android:name="PackageSummary" android:label="Package Summary">
-        </activity>
-        <activity android:name="ShowActivity" android:label="Activity">
-        </activity>
-        <activity android:name="AppPicker"
-                android:theme="@android:style/Theme.Dialog">
-        </activity>
-        <activity android:name="PointerLocation" android:label="Pointer Location"
-                android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen"
-                android:configChanges="keyboard|keyboardHidden|navigation|orientation">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name="DataList">
-        </activity>
-        <activity android:name="Details">
-        </activity>
-        <activity android:name="DevelopmentSettings" android:label="Development Settings" >
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name="InstrumentationList" android:label="Instrumentation">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name="MediaScannerActivity" android:label="Media Scanner">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-
-    <activity android:name="GLSTester" android:label="Google Login Service">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-
-    <activity android:name="RunningProcesses" android:label="Running processes">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-    <activity android:name="ProcessInfo" android:label="Process Information">
-            <intent-filter>
-                <action android:name="android.intent.action.VIEW" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-    </activity>
-    <!--
-    <activity android:name="AppHwConfigList" android:label="Applications Hw Configuration">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-    </activity>
-    -->
-    <activity android:name="AppHwPref" android:label="Applications Hardware Preferences">
-            <intent-filter>
-                <action android:name="android.intent.action.VIEW" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-    </activity>
-    </application>
-</manifest>
diff --git a/apps/Development/res/drawable/box.xml b/apps/Development/res/drawable/box.xml
deleted file mode 100644
index 6849bd3..0000000
--- a/apps/Development/res/drawable/box.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/drawable/box.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#00000000"/>
-    <stroke android:width="1dp" color="#ff000000"/>
-    <padding android:left="1dp" android:top="1dp"
-        android:right="1dp" android:bottom="1dp" />
-</shape>
diff --git a/apps/Development/res/drawable/ic_launcher_devtools.png b/apps/Development/res/drawable/ic_launcher_devtools.png
deleted file mode 100644
index cb40a19..0000000
--- a/apps/Development/res/drawable/ic_launcher_devtools.png
+++ /dev/null
Binary files differ
diff --git a/apps/Development/res/drawable/stat_sample.png b/apps/Development/res/drawable/stat_sample.png
deleted file mode 100644
index a2e5ce3..0000000
--- a/apps/Development/res/drawable/stat_sample.png
+++ /dev/null
Binary files differ
diff --git a/apps/Development/res/layout/application_hw_pref.xml b/apps/Development/res/layout/application_hw_pref.xml
deleted file mode 100755
index 859c7ab..0000000
--- a/apps/Development/res/layout/application_hw_pref.xml
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:padding="4dip" >
-    
-        <TextView android:id="@+id/attr_package_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/package_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_package"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-        <TextView android:id="@+id/attr_touchscreen_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/touchscreen_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_touchscreen"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-        <TextView android:id="@+id/attr_input_method_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/input_method_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_input_method"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-        <TextView android:id="@+id/attr_hard_keyboard_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/hard_keyboard_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_hard_keyboard"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-        <TextView android:id="@+id/attr_navigation_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/navigation_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_navigation"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-        <TextView android:id="@+id/attr_five_way_nav_label"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/five_way_nav_label"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/attr_five_way_nav"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-    </LinearLayout>
-</ScrollView>
-
diff --git a/apps/Development/res/layout/development_settings.xml b/apps/Development/res/layout/development_settings.xml
deleted file mode 100644
index 0486748..0000000
--- a/apps/Development/res/layout/development_settings.xml
+++ /dev/null
@@ -1,156 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Settings/assets/res/any/layout/keyboard_version.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <RelativeLayout 
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent">
-
-        <TextView android:id="@+id/debug_app_label"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_alignParentTop="true"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_debug_app_label_text" />
-
-        <Button android:id="@+id/debug_app"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/debug_app_label"
-            android:layout_alignParentLeft="true"
-            android:layout_toRightOf="@id/debug_app_label" />
-
-        <!-- android:visibility="gone" -->
-                
-        <CheckBox android:id="@+id/wait_for_debugger"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/debug_app"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_wait_for_debugger_text" />
-
-        <View android:id="@+id/separator"
-            android:layout_width="8dip"
-            android:layout_height="8dip"
-            android:layout_below="@id/wait_for_debugger"
-            android:layout_alignParentLeft="true" />
-
-        <CheckBox android:id="@+id/show_load"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/separator"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_load_text" />
-
-        <CheckBox android:id="@+id/show_updates"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_load"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_updates_text" />
-
-        <Spinner android:id="@+id/max_procs"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_updates"
-            android:layout_alignParentLeft="true" />
-
-        <View android:id="@+id/separator2"
-            android:layout_width="8dip"
-            android:layout_height="8dip"
-            android:layout_below="@id/max_procs"
-            android:layout_alignParentLeft="true" />
-
-        <CheckBox android:id="@+id/always_finish"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/separator2"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_always_finish_text" />
-
-        <CheckBox android:id="@+id/show_cpu"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/always_finish"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_cpu_text" />
-
-        <CheckBox android:id="@+id/enable_gl"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_cpu"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_enable_gl_text" />
-
-        <CheckBox android:id="@+id/show_background"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/enable_gl"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_background_text" />
-
-        <CheckBox android:id="@+id/show_sleep"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_background"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_sleep_text" />
-            
-        <Spinner android:id="@+id/window_animation_scale"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_sleep"
-            android:layout_alignParentLeft="true">
-        </Spinner>
-
-        <Spinner android:id="@+id/transition_animation_scale"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/window_animation_scale"
-            android:layout_alignParentLeft="true">
-        </Spinner>
-
-        <Spinner android:id="@+id/font_hinting"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/transition_animation_scale"
-            android:layout_alignParentLeft="true">
-        </Spinner>
-
-        <CheckBox android:id="@+id/show_xmpp"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/font_hinting"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_xmpp_text" />
-
-        <CheckBox android:id="@+id/show_maps_compass"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/show_xmpp"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_maps_compass_text" />
-            
-    </RelativeLayout>
-
-</ScrollView>
-
diff --git a/apps/Development/res/layout/enter_url.xml b/apps/Development/res/layout/enter_url.xml
deleted file mode 100644
index 062c67e..0000000
--- a/apps/Development/res/layout/enter_url.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">          	
-    <com.android.development.UrlEditText android:id="@+id/url_edit_text"
-        android:textSize="13sp"
-        android:autoText="false"
-        android:capitalize="none"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"/>
-    <com.android.development.DisplayEditText android:id="@+id/display_edit_text"
-        android:textSize="13sp"
-        android:autoText="false"
-        android:capitalize="none"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"/>
-    <ListView android:id="@android:id/list"
-        android:layout_width="fill_parent" android:layout_height="fill_parent"/>
-</LinearLayout>
-
-
diff --git a/apps/Development/res/layout/gls_tester.xml b/apps/Development/res/layout/gls_tester.xml
deleted file mode 100644
index fbd4549..0000000
--- a/apps/Development/res/layout/gls_tester.xml
+++ /dev/null
@@ -1,111 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-       android:orientation="horizontal"
-       android:layout_width="fill_parent"
-       android:layout_height="wrap_content">
-
-      <Button
-         android:id="@+id/prefer_hosted"
-         android:layout_width="wrap_content"
-         android:layout_height="wrap_content"
-         android:text="@string/gls_tester_prefer_hosted"/>
-
-      <Button
-         android:id="@+id/require_google"
-         android:layout_width="wrap_content"
-         android:layout_height="wrap_content"
-         android:text="@string/gls_tester_require_google"/>
-
-      <Button
-         android:id="@+id/get_accounts"
-         android:layout_width="wrap_content"
-         android:layout_height="wrap_content"
-         android:text="@string/gls_tester_get_accounts"/>
-
-      <Button
-         android:id="@+id/clear"
-         android:layout_width="wrap_content"
-         android:layout_height="wrap_content"
-         android:text="@string/gls_tester_clear"/>
-
-      <Button android:id="@+id/go"
-              android:layout_width="wrap_content"
-              android:layout_height="wrap_content"
-              android:text="@string/gls_tester_go"/>
-
-    </LinearLayout>
-
-    <EditText android:id="@+id/username_edit"
-              android:singleLine="true"
-              android:layout_width="fill_parent"
-              android:layout_height="wrap_content"
-              android:minWidth="250dip"
-              android:scrollHorizontally="true"
-              android:capitalize="none"
-              android:autoText="false"/>
-
-    <LinearLayout android:orientation="horizontal"
-                  android:layout_width="fill_parent"
-                  android:layout_height="wrap_content">
-
-      <CheckBox android:id="@+id/do_notification"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/gls_tester_do_notification"/>
-
-      <CheckBox android:id="@+id/run_intent"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/gls_tester_run_intent"/>
-
-    </LinearLayout>
-
-    <LinearLayout
-       android:orientation="horizontal"
-       android:layout_width="fill_parent"
-       android:layout_height="wrap_content">
-
-      <Spinner android:id="@+id/service_spinner"
-               android:layout_width="wrap_content"
-               android:layout_height="wrap_content"
-               android:entries="@array/glstester_services"/>
-
-      <Button
-         android:id="@+id/wipe_passwords"
-         android:layout_width="wrap_content"
-         android:layout_height="wrap_content"
-         android:text="@string/gls_tester_wipe_passwords"/>
-    </LinearLayout>
-
-    <com.android.development.LogTextBox
-        android:id="@+id/text"
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="0dip"
-        android:layout_weight="1"
-        android:scrollbars="vertical"
-        android:textSize="10dip"
-       />
-
-</LinearLayout>
diff --git a/apps/Development/res/layout/log_viewer.xml b/apps/Development/res/layout/log_viewer.xml
deleted file mode 100644
index 98fe14e..0000000
--- a/apps/Development/res/layout/log_viewer.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<com.android.development.LogTextBox xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    />
diff --git a/apps/Development/res/layout/media_scanner_activity.xml b/apps/Development/res/layout/media_scanner_activity.xml
deleted file mode 100644
index 53f2b15..0000000
--- a/apps/Development/res/layout/media_scanner_activity.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 	 	
-	android:layout_width="fill_parent" 
-	android:layout_height="fill_parent"
-	android:orientation="horizontal">
-
-    <TextView android:id="@+id/title" android:textSize="16sp" android:textStyle="bold"
-        android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-</LinearLayout>
diff --git a/apps/Development/res/layout/monkey_screen.xml b/apps/Development/res/layout/monkey_screen.xml
deleted file mode 100644
index c508338..0000000
--- a/apps/Development/res/layout/monkey_screen.xml
+++ /dev/null
@@ -1,70 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingTop="10dip" >
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:paddingRight="5dip"
-            android:text="@string/monkey_screen_initial_activity_label" />
-
-        <Button android:id="@+id/initialActivity"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/monkey_screen_initialActivity_text" />
-    </LinearLayout>
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingTop="5dip" >
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:paddingRight="5dip"
-            android:text="@string/monkey_screen_number_of_events_label" />
-
-        <EditText android:id="@+id/numberOfEvents"
-            android:layout_marginLeft="2dip"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:background="@android:drawable/editbox_background"
-            android:numeric="integer"
-            android:scrollHorizontally="true"
-            android:maxLines="1" />
-    </LinearLayout>
-
-    <Button android:id="@+id/start"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:paddingTop="10dip"
-        android:text="@string/monkey_screen_start_text" />
-
-</LinearLayout>
-
-
diff --git a/apps/Development/res/layout/package_item.xml b/apps/Development/res/layout/package_item.xml
deleted file mode 100644
index 7860f9b..0000000
--- a/apps/Development/res/layout/package_item.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<Button xmlns:android="http://schemas.android.com/apk/res/android"
-	android:layout_width="fill_parent"
-	android:layout_height="wrap_content" />
-    <!--android:background="@android:drawable/list_highlight"-->
diff --git a/apps/Development/res/layout/package_summary.xml b/apps/Development/res/layout/package_summary.xml
deleted file mode 100644
index 99717e6..0000000
--- a/apps/Development/res/layout/package_summary.xml
+++ /dev/null
@@ -1,151 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:padding="4dip" >
-    
-        <TextView android:id="@+id/packageView"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" />
-
-        <LinearLayout
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:orientation="horizontal"
-            android:paddingTop="4dip"
-            android:paddingBottom="6dip"
-            android:paddingRight="4dip" >
-
-            <ImageView android:id="@+id/icon"
-                android:layout_width="wrap_content" android:layout_height="wrap_content"
-                android:paddingRight="8dip" />
-
-            <LinearLayout
-                android:layout_width="wrap_content" android:layout_height="wrap_content"
-                android:orientation="vertical">
-
-                <TextView android:id="@+id/classView"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-                <TextView android:id="@+id/label"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-                <TextView android:id="@+id/disabled"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content"
-                    android:text="@string/disabled" />
-
-                <TextView android:id="@+id/system"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content"
-                    android:text="@string/system" />
-
-                <TextView android:id="@+id/debuggable"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content"
-                    android:text="@string/debuggable" />
-
-                <TextView android:id="@+id/nocode"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content"
-                    android:text="@string/nocode" />
-
-                <TextView android:id="@+id/persistent"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content"
-                    android:text="@string/persistent" />
-
-            </LinearLayout>
-
-            <Button android:id="@+id/restart"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_gravity="center"
-                android:text="@string/restart" />
-            
-        </LinearLayout>
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_process_label" />
-
-        <TextView android:id="@+id/process"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_uid_label" />
-
-        <TextView android:id="@+id/uid"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_task_label" />
-
-        <TextView android:id="@+id/task"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_version_label" />
-
-        <TextView android:id="@+id/version"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_source_label" />
-
-        <TextView android:id="@+id/source"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/package_summary_data_label" />
-
-        <TextView android:id="@+id/data"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-        <LinearLayout android:id="@+id/activities" style="@style/SummaryCategoryLayout">
-            <TextView style="@style/SummaryCategoryHeader"
-                android:text="@string/package_summary_activities_label" />
-        </LinearLayout>
-    
-        <LinearLayout android:id="@+id/receivers" style="@style/SummaryCategoryLayout">
-            <TextView style="@style/SummaryCategoryHeader"
-                android:text="@string/package_summary_receivers_label" />
-        </LinearLayout>
-    
-        <LinearLayout android:id="@+id/services" style="@style/SummaryCategoryLayout">
-            <TextView style="@style/SummaryCategoryHeader"
-                android:text="@string/package_summary_services_label" />
-        </LinearLayout>
-    
-        <LinearLayout android:id="@+id/providers" style="@style/SummaryCategoryLayout">
-            <TextView style="@style/SummaryCategoryHeader"
-                android:text="@string/package_summary_providers_label" />
-        </LinearLayout>
-
-        <LinearLayout android:id="@+id/instrumentation" style="@style/SummaryCategoryLayout">
-            <TextView style="@style/SummaryCategoryHeader"
-                android:text="@string/package_summary_instrumentation_label" />
-        </LinearLayout>
-    
-    </LinearLayout>
-</ScrollView>
-
diff --git a/apps/Development/res/layout/process_info.xml b/apps/Development/res/layout/process_info.xml
deleted file mode 100755
index b25f223..0000000
--- a/apps/Development/res/layout/process_info.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:padding="4dip" >
-    
-        <TextView android:id="@+id/process_name_header"
-            android:layout_width="fill_parent" 
-            android:layout_height="wrap_content"
-            android:text="@string/process_name_header"
-            android:textStyle="bold" />
-        <TextView android:id="@+id/process_name"
-            android:layout_width="fill_parent" 
-            android:layout_height="wrap_content" />
-        <TextView android:id="@+id/package_list_header"
-            android:layout_width="fill_parent" 
-            android:layout_height="wrap_content"
-            android:text="@string/package_list_header"
-            android:textStyle="bold" />
-
-        <LinearLayout android:id="@+id/package_list"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:orientation="vertical"
-            android:paddingTop="4dip"
-            android:paddingBottom="6dip"
-            android:paddingRight="4dip" />
-
-    </LinearLayout>
-</ScrollView>
-
diff --git a/apps/Development/res/layout/radio_issue.xml b/apps/Development/res/layout/radio_issue.xml
deleted file mode 100644
index b13b6bb..0000000
--- a/apps/Development/res/layout/radio_issue.xml
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <LinearLayout
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <Button android:id="@+id/submit" 
-            android:textSize="14sp" 
-            android:layout_marginTop="8dip"
-            android:layout_width="wrap_content" android:layout_height="wrap_content" 
-            android:text="@string/radio_issue_submit_text"
-            />	         
-        <TextView android:id="@+id/instructions"
-            android:textSize="14sp" 
-            android:layout_marginTop="10dip"
-            android:layout_marginLeft="4dip"
-            android:layout_width="wrap_content" android:layout_height="wrap_content" 
-            android:text="@string/radio_issue_instructions_text"
-            />
-
-    </LinearLayout>
-
-    <EditText android:id="@+id/report_text"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:textSize="14sp"
-        />
-
-</LinearLayout>
diff --git a/apps/Development/res/layout/show_activity.xml b/apps/Development/res/layout/show_activity.xml
deleted file mode 100644
index 6a7617c..0000000
--- a/apps/Development/res/layout/show_activity.xml
+++ /dev/null
@@ -1,106 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Settings/res/layout/keyguard.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:layout_width="fill_parent" android:layout_height="fill_parent"
-        android:orientation="vertical"
-        android:paddingTop="8dip" android:paddingLeft="2dip" android:paddingRight="2dip" >
-    
-        <TextView android:id="@+id/packageView"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" />
-    
-        <LinearLayout
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:orientation="horizontal"
-            android:paddingTop="4dip"
-            android:paddingBottom="6dip" >
-    
-            <ImageView android:id="@+id/icon"
-                android:layout_width="wrap_content" android:layout_height="wrap_content"
-                android:paddingRight="8dip" />
-                 
-            <LinearLayout
-                android:layout_width="fill_parent" android:layout_height="wrap_content"
-                android:orientation="vertical">
-    
-                <TextView android:id="@+id/classView"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-                <TextView android:id="@+id/label"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-                <TextView android:id="@+id/launch"
-                    android:layout_width="fill_parent" android:layout_height="wrap_content" />
-
-            </LinearLayout>
-    
-        </LinearLayout>
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_process_label" />
-    
-        <TextView android:id="@+id/process"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_task_affinity_label" />
-    
-        <TextView android:id="@+id/taskAffinity"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_required_permission_label" />
-    
-        <TextView android:id="@+id/permission"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_multiprocess_label" />
-    
-        <TextView android:id="@+id/multiprocess"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_clear_on_background_label" />
-    
-        <TextView android:id="@+id/clearOnBackground"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-        <TextView style="@style/SummaryCategoryLayout"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:textStyle="bold" android:text="@string/show_activity_state_not_needed_label" />
-    
-        <TextView android:id="@+id/stateNotNeeded"
-            android:layout_width="fill_parent" android:layout_height="wrap_content" />
-    
-    </LinearLayout>
-
-</ScrollView>
-
diff --git a/apps/Development/res/layout/url_list.xml b/apps/Development/res/layout/url_list.xml
deleted file mode 100644
index f004eff..0000000
--- a/apps/Development/res/layout/url_list.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/text1" 
-	android:layout_width="fill_parent"
-	android:layout_height="wrap_content"
-	android:textColor="#FF000000"
-	android:textSize="13sp"
-	android:maxLines="1" />
diff --git a/apps/Development/res/values/arrays.xml b/apps/Development/res/values/arrays.xml
deleted file mode 100644
index cb38127..0000000
--- a/apps/Development/res/values/arrays.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-  <string-array name="glstester_services">
-    <item>mail</item>
-    <item>SID</item>
-    <item>LSID</item>
-    <item>youtube</item>
-    <item>YouTubeUser</item>
-    <item>sierra</item>
-    <item>lh2</item>
-    <item>cl</item>
-    <item>cp</item>
-  </string-array>
-</resources>
-
-			
diff --git a/apps/Development/res/values/strings.xml b/apps/Development/res/values/strings.xml
deleted file mode 100644
index 8d343ae..0000000
--- a/apps/Development/res/values/strings.xml
+++ /dev/null
@@ -1,126 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/assets/res/any/strings.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-<resources>
-    <string name="menu_upload_exceptions">Upload Exceptions</string>
-    <string name="menu_clear_exceptions">Clear Exceptions</string>
-
-        <string name="device_info_default">unknown</string>
-        <string name="device_info_uptime">Uptime</string>
-        <string name="device_info_awaketime">Awake Time</string>
-        <string name="device_info_asleeptime">Asleep Time</string>
-
-    <string name="build_id_label">Build ID</string>
-    <string name="build_date_label">Build Date</string>
-    <string name="build_type_label">Build Type</string>
-    <string name="build_product_label">Build Product</string>
-    <string name="build_user_label">Build Label</string>
-    <string name="build_host_label">Build Host</string>
-    <string name="gsm_version_baseband_label">Baseband Version</string>
-    <string name="gsm_version_ril_impl_label">RIL Impl Version</string>
-
-    <string name="turn_on_radio">Turn on radio</string>
-    <string name="turn_off_radio">Turn off radio</string>
-
-    <string name="refresh_networks">Refresh Network List</string>
-
-    <string name="radioInfo_menu_viewADN">View SIM Address Book</string>
-    <string name="radioInfo_menu_viewFDN">View Fixed Dialing Numbers</string>
-    <string name="radioInfo_menu_viewSDN">View Service Dialing Numbers</string>
-
-    <!-- Package summary in Package Browser -->
-    <string name="disabled"><i>disabled</i></string>
-    <string name="system"><i>system</i></string>
-    <string name="debuggable"><i>debuggable</i></string>
-    <string name="nocode"><i>no code</i></string>
-    <string name="persistent"><i>persistent</i></string>
-    <string name="restart">Restart</string>
-    <string name="package_summary_uid_label">User ID</string>
-    <string name="package_summary_task_label">Task Affinity</string>
-    <string name="package_summary_version_label">Version</string>
-    <string name="package_summary_source_label">Source</string>
-    <string name="package_summary_receivers_label">Receivers</string>
-    <string name="package_summary_data_label">Data</string>
-    <string name="package_summary_instrumentation_label">Instrumentation</string>
-    <string name="package_summary_process_label">Process</string>
-    <string name="package_summary_services_label">Services</string>
-    <string name="package_summary_providers_label">Providers</string>
-    <string name="package_summary_activities_label">Activities</string>
-
-    <!-- Activity details in Package Browser -->
-    <string name="none">"(none)"</string>
-    <string name="yes">Yes</string>
-    <string name="no">No</string>
-    <string name="launch_multiple">Multiple (normal)</string>
-    <string name="launch_singleTop">Single Top</string>
-    <string name="launch_singleTask">Single Task</string>
-    <string name="launch_singleInstance">Single Instance</string>
-    <string name="launch_unknown">"(Unknown)"</string>
-
-    <string name="development_settings_show_cpu_text">Show CPU usage</string>
-    <string name="development_settings_always_finish_text">Immediately destroy activities</string>
-    <string name="development_settings_show_load_text">Show running processes</string>
-    <string name="development_settings_show_updates_text">Show screen updates</string>
-    <string name="development_settings_enable_gl_text">Enable OpenGL ES (reboot needed)</string>
-    <string name="development_settings_allow_mock_location_text">Allow mock locations for testing</string>
-    <string name="development_settings_wait_for_debugger_text">Wait for debugger</string>
-    <string name="development_settings_show_background_text">Show background</string>
-    <string name="development_settings_show_xmpp_text">Show GTalk service connection status</string>
-    <string name="development_settings_debug_app_label_text">Debug App:</string>
-    <string name="development_settings_show_sleep_text">Show sleep state on LED</string>
-    <string name="development_settings_show_maps_compass_text">Show compass in Maps</string>
-    <string name="development_settings_keep_screen_on_text">Keep screen on while plugged in</string>
-
-    <string name="monkey_screen_initialActivity_text"></string>
-    <string name="monkey_screen_number_of_events_label">Number of Events: </string>
-    <string name="monkey_screen_start_text">Start</string>
-    <string name="monkey_screen_initial_activity_label">Initial Activity: </string>
-
-    <string name="radio_issue_submit_text">Submit report</string>
-    <string name="radio_issue_instructions_text">Enter a description of the issue.</string>
-
-    <string name="show_activity_clear_on_background_label">Clear on Background</string>
-    <string name="show_activity_task_affinity_label">Task Affinity</string>
-    <string name="show_activity_process_label">Process</string>
-    <string name="show_activity_state_not_needed_label">State Not Needed</string>
-    <string name="show_activity_required_permission_label">Required Permission</string>
-    <string name="show_activity_multiprocess_label">Multiprocess</string>
-
-    <string name="red_button_behavior_label">End Button Behavior</string>
-
-    <string name="gls_tester_label">GLS Tester</string>
-    <string name="gls_tester_prefer_hosted">Hosted</string>
-    <string name="gls_tester_require_google">Google</string>
-    <string name="gls_tester_get_accounts">List</string>
-    <string name="gls_tester_clear">Clear</string>
-    <string name="gls_tester_go">Go</string>
-    <string name="gls_tester_do_notification">Notify on failure</string>
-    <string name="gls_tester_run_intent">Run intent</string>
-    <string name="gls_tester_wipe_passwords">Wipe passwords</string>
-    <string name="process_name_header">Process Name:</string>
-    <string name="package_list_header">Packages in process:</string>
-    <string name="package_label">Package Name:</string>
-
-    <!-- Application configuration requirements related attributes -->
-    <string name="touchscreen_label">touchscreen:</string>
-    <string name="input_method_label">inputMethod:</string>
-    <string name="hard_keyboard_label">hardKeyboard:</string>
-    <string name="navigation_label">navigation:</string>
-    <string name="five_way_nav_label">five way nav:</string>
-</resources>
diff --git a/apps/Development/res/values/styles.xml b/apps/Development/res/values/styles.xml
deleted file mode 100644
index 591eed8..0000000
--- a/apps/Development/res/values/styles.xml
+++ /dev/null
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <style name="SummaryCategoryLayout">
-        <item name="android:layout_width">fill_parent</item>
-        <item name="android:layout_height">wrap_content</item>
-        <item name="android:orientation">vertical</item>
-    </style>
-    <style name="SummaryCategoryHeader">
-        <item name="android:layout_width">wrap_content</item>
-        <item name="android:layout_height">wrap_content</item>
-        <item name="android:paddingTop">7dip</item>
-        <item name="android:paddingBottom">1dip</item>
-        <item name="android:maxLines">1</item>
-        <item name="android:textAppearance">@style/TextAppearance.SummaryCategoryHeader</item>
-    </style>
-    <style name="info_layout">
-        <item name="android:orientation">vertical</item>
-        <item name="android:paddingLeft">10dip</item>
-        <item name="android:paddingTop">10dip</item>
-        <item name="android:paddingRight">10dip</item>
-        <item name="android:paddingBottom">10dip</item>
-        <item name="android:layout_width">fill_parent</item>
-        <item name="android:layout_height">fill_parent</item>
-    </style>
-    <style name="entry_layout">
-        <item name="android:orientation">horizontal</item>
-        <item name="android:layout_width">wrap_content</item>
-        <item name="android:layout_height">wrap_content</item>
-    </style>
-    <style name="info_label">
-        <item name="android:layout_height">wrap_content</item>
-        <item name="android:layout_width">wrap_content</item>
-        <item name="android:textAppearance">@style/TextAppearance.info_label</item>
-        <item name="android:paddingRight">4dip</item>
-    </style>
-
-    <style name="info_value">
-        <item name="android:layout_height">wrap_content</item>
-        <item name="android:layout_width">wrap_content</item>
-        <item name="android:textAppearance">@style/TextAppearance.info_value</item>
-    </style>
-
-    <style name="TextAppearance" parent="android:TextAppearance">
-    </style>
-
-    <style name="TextAppearance.info_label">
-        <item name="android:textSize">14sp</item>
-        <item name="android:textStyle">bold</item>
-    </style>
-
-    <style name="TextAppearance.SummaryCategoryHeader">
-        <item name="android:textStyle">bold</item>
-    </style>
-
-    <style name="TextAppearance.info_value">
-        <item name="android:textSize">14sp</item>
-        <item name="android:textStyle">normal</item>
-    </style>
-
-</resources>
-
diff --git a/apps/Development/src/com/android/development/AppHwConfigList.java b/apps/Development/src/com/android/development/AppHwConfigList.java
deleted file mode 100755
index 52aff0d..0000000
--- a/apps/Development/src/com/android/development/AppHwConfigList.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.PackageInfo;
-import android.content.pm.PackageManager;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-import java.text.Collator;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-public class AppHwConfigList extends ListActivity {
-    private static final String TAG = "AppHwConfigList";
-    PackageManager mPm;
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        mPm = getPackageManager();
-        mAdapter = new AppListAdapter(this);
-        if (mAdapter.getCount() <= 0) {
-            finish();
-        } else {
-            setListAdapter(mAdapter);
-        }
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-    }
-
-    @Override
-    protected void onStop() {
-        super.onStop();
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) {
-        PackageInfo app = mAdapter.appForPosition(position);
-        // TODO display all preference settings
-        Intent intent = new Intent(Intent.ACTION_VIEW);
-        intent.setClass(this, AppHwPref.class);
-        intent.putExtra("packageName", app.packageName);
-        startActivity(intent);
-    }
-
-    private final class AppListAdapter extends BaseAdapter {
-        public AppListAdapter(Context context) {
-            mContext = context;
-            mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-
-            List<ApplicationInfo> appList = mPm.getInstalledApplications(0);
-            for (ApplicationInfo app : appList) {
-                PackageInfo pkgInfo = null;
-                try {
-                    pkgInfo = mPm.getPackageInfo(app.packageName, 0);
-                } catch (NameNotFoundException e) {
-                    // TODO Auto-generated catch block
-                    e.printStackTrace();
-                }
-                if ((pkgInfo != null)) {
-                        if(mList == null) {
-                             mList = new ArrayList<PackageInfo>();
-                         }
-                         mList.add(pkgInfo);
-                }
-            }
-            if (mList != null) {
-                Collections.sort(mList, sDisplayNameComparator);
-            }
-        }
-    
-        public PackageInfo appForPosition(int position) {
-            if (mList == null) {
-                return null;
-            }
-            return mList.get(position);
-        }
-
-        public int getCount() {
-            return mList != null ? mList.size() : 0;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-    
-        public long getItemId(int position) {
-            return position;
-        }
-    
-        public View getView(int position, View convertView, ViewGroup parent) {
-            View view;
-            if (convertView == null) {
-                view = mInflater.inflate(
-                        android.R.layout.simple_list_item_1, parent, false);
-            } else {
-                view = convertView;
-            }
-            bindView(view, mList.get(position));
-            return view;
-        }
-    
-        private final void bindView(View view, PackageInfo info) {
-            TextView text = (TextView)view.findViewById(android.R.id.text1);
-            text.setText(info != null ? info.applicationInfo.loadLabel(mPm) : "(none)");
-        }
-    
-        protected final Context mContext;
-        protected final LayoutInflater mInflater;
-        protected List<PackageInfo> mList;
-        
-    }
-
-    private final Comparator sDisplayNameComparator = new Comparator() {
-        public final int compare(Object a, Object b) {
-            CharSequence  sa = ((PackageInfo) a).applicationInfo.loadLabel(mPm);
-            CharSequence  sb = ((PackageInfo) b).applicationInfo.loadLabel(mPm);
-            return collator.compare(sa, sb);
-        }
-        private final Collator   collator = Collator.getInstance();
-    };
-
-    private AppListAdapter mAdapter;
-}
-
diff --git a/apps/Development/src/com/android/development/AppHwPref.java b/apps/Development/src/com/android/development/AppHwPref.java
deleted file mode 100644
index bf0f84f..0000000
--- a/apps/Development/src/com/android/development/AppHwPref.java
+++ /dev/null
@@ -1,228 +0,0 @@
-/*
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import com.android.development.R;
-import android.app.Activity;
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.ConfigurationInfo;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.PackageInfo;
-import android.content.pm.PackageManager;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.content.res.Configuration;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.LinearLayout;
-import android.widget.ListView;
-import android.widget.TextView;
-import java.text.Collator;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashSet;
-import java.util.List;
-
-/* This activity displays the hardware configuration details
- * of an application as defined in its manifests
- */
-public class AppHwPref extends Activity {
-    private static final String TAG = "AppHwPref";
-    PackageManager mPm;
-    private static final int BASE = 0;
-    private static final int TOUCHSCREEN = BASE + 1;
-    private static final int KEYBOARD_TYPE = BASE + 2;
-    private static final int NAVIGATION = BASE + 3;
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        Intent intent = getIntent();
-        String pkgName = intent.getStringExtra("packageName");
-        if(pkgName == null) {
-           handleError("Null package name", true);
-           return;
-        }
-        mPm = getPackageManager();
-        PackageInfo pInfo;
-        try {
-            pInfo = mPm.getPackageInfo(pkgName, PackageManager.GET_CONFIGURATIONS);
-        } catch (NameNotFoundException e) {
-            pInfo = null;
-        }
-        if(pInfo == null) {
-            handleError("Failed retrieving packageInfo for pkg:"+pkgName, true);
-            return;
-        }
-        ConfigurationInfo appHwPref[] = pInfo.configPreferences;
-        
-        setContentView(R.layout.application_hw_pref);
-        if(appHwPref != null) {
-        	displayTextView(R.id.attr_package, pInfo.applicationInfo.loadLabel(mPm));
-        	displayTextView(R.id.attr_touchscreen, appHwPref, TOUCHSCREEN);
-        	displayTextView(R.id.attr_input_method, appHwPref, KEYBOARD_TYPE);
-        	displayTextView(R.id.attr_navigation, appHwPref, NAVIGATION);
-        	displayFlag(R.id.attr_hard_keyboard, ConfigurationInfo.INPUT_FEATURE_HARD_KEYBOARD, appHwPref);
-        	displayFlag(R.id.attr_five_way_nav, ConfigurationInfo.INPUT_FEATURE_FIVE_WAY_NAV, appHwPref);
-        }
-    }
-    
-    void displayFlag(int viewId, int flagMask, ConfigurationInfo[] appHwPref) {
-    	if(appHwPref == null) {
-    		return;
-    	}
-    	boolean flag = false;
-    	for (int i = 0; i < appHwPref.length; i++) {
-    		ConfigurationInfo pref = appHwPref[i];
-        	if((pref.reqInputFeatures & flagMask) != 0) {
-        		flag = true;
-        		break;
-        	}
-        }
-        if(flag) {
-            displayTextView(viewId, "true");
-        } else {
-        	displayTextView(viewId, "false");
-        }
-    }
-    
-    void handleError(String errMsg, boolean finish) {
-        // TODO display dialog
-        Log.i(TAG, errMsg);
-        if(finish) {
-            finish();
-        }
-    }
-    
-    void displayTextView(int textViewId, CharSequence displayStr) {
-        TextView tView = (TextView) findViewById(textViewId);
-        if(displayStr != null) {
-            tView.setText(displayStr);
-        }
-    }
-    
-    void displayTextView(int viewId, ConfigurationInfo[] config, int type) {
-        if((config == null) || (config.length < 1)) {
-            return;
-        }
-        
-        HashSet<String> list = new HashSet<String>();
-        for(int i = 0; i < config.length; i++) {
-            String str = null;
-            switch(type) {
-            case TOUCHSCREEN:
-                str = getTouchScreenStr(config[i]);
-                break;
-            case KEYBOARD_TYPE:
-                str =  getKeyboardTypeStr(config[i]);
-                break;
-            case NAVIGATION:
-                str = getNavigationStr(config[i]);
-                break;
-            }
-            if(str != null) {
-                list.add(str);
-            }
-        }
-        String listStr = "";
-        boolean set = false;
-        for(String str : list) {
-            set = true;
-            listStr += str+",";
-        }
-        if(set) {
-            TextView tView = (TextView)findViewById(viewId);
-            CharSequence txt = listStr.subSequence(0, listStr.length()-1);
-            tView.setText(txt);
-        }
-    }
-    
-    String getTouchScreenStr(ConfigurationInfo appHwPref) {
-        if(appHwPref == null) {
-            handleError("Invalid HardwareConfigurationObject", true);
-            return null;
-        }
-        switch(appHwPref.reqTouchScreen) {
-        case Configuration.TOUCHSCREEN_FINGER:
-            return "finger";
-        case Configuration.TOUCHSCREEN_NOTOUCH:
-            return "notouch";
-        case Configuration.TOUCHSCREEN_STYLUS:
-            return "stylus";
-        case Configuration.TOUCHSCREEN_UNDEFINED:
-            return null;
-        default:
-                return null;
-        }
-    }
-    
-    String getKeyboardTypeStr(ConfigurationInfo appHwPref) {
-        if(appHwPref == null) {
-            handleError("Invalid HardwareConfigurationObject", true);
-            return null;
-        }
-        switch(appHwPref.reqKeyboardType) {
-        case Configuration.KEYBOARD_12KEY:
-            return "12key";
-        case Configuration.KEYBOARD_NOKEYS:
-            return "nokeys";
-        case Configuration.KEYBOARD_QWERTY:
-            return "querty";
-        case Configuration.KEYBOARD_UNDEFINED:
-            return null;
-        default:
-                return null;
-        }
-    }
-    
-    String getNavigationStr(ConfigurationInfo appHwPref) {
-        if(appHwPref == null) {
-            handleError("Invalid HardwareConfigurationObject", true);
-            return null;
-        }
-        switch(appHwPref.reqNavigation) {
-        case Configuration.NAVIGATION_DPAD:
-            return "dpad";
-        case Configuration.NAVIGATION_TRACKBALL:
-            return "trackball";
-        case Configuration.NAVIGATION_WHEEL:
-            return "wheel";
-        case Configuration.NAVIGATION_UNDEFINED:
-            return null;
-        default:
-                return null;
-        }
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-    }
-
-    @Override
-    protected void onStop() {
-        super.onStop();
-    }
-}
-
diff --git a/apps/Development/src/com/android/development/AppPicker.java b/apps/Development/src/com/android/development/AppPicker.java
deleted file mode 100644
index 693defb..0000000
--- a/apps/Development/src/com/android/development/AppPicker.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/* //device/java/android/android/app/ResolveListActivity.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.ActivityManagerNative;
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.ApplicationInfo;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.provider.Settings;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-
-import java.text.Collator;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-public class AppPicker extends ListActivity
-{
-    @Override
-    protected void onCreate(Bundle icicle)
-    {
-        super.onCreate(icicle);
-
-        mAdapter = new AppListAdapter(this);
-        if (mAdapter.getCount() <= 0) {
-            finish();
-        } else {
-            setListAdapter(mAdapter);
-        }
-    }
-    
-    @Override
-    protected void onResume()
-    {
-        super.onResume();
-    }
-
-    @Override
-    protected void onStop()
-    {
-        super.onStop();
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        ApplicationInfo app = mAdapter.appForPosition(position);
-        Intent intent = new Intent();
-        if (app != null) intent.setAction(app.packageName);
-        setResult(RESULT_OK, intent);
-        
-        /* This is a temporary fix for 824637 while it is blocked by 805226.  When 805226 is resolved, please remove this. */
-        try {
-            boolean waitForDebugger = Settings.System.getInt(
-                    getContentResolver(), Settings.System.WAIT_FOR_DEBUGGER, 0) != 0;
-            ActivityManagerNative.getDefault().setDebugApp(
-                    app != null ? app.packageName : null, waitForDebugger, true);
-        } catch (RemoteException ex) {
-        }
-        
-        finish();
-    }
-
-    private final class AppListAdapter extends BaseAdapter
-    {
-        public AppListAdapter(Context context)
-        {
-            mContext = context;
-            mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-
-            mList = context.getPackageManager().getInstalledApplications(0);
-            if (mList != null) {
-                Collections.sort(mList, sDisplayNameComparator);
-                mList.add(0, null);
-            }
-        }
-    
-        public ApplicationInfo appForPosition(int position)
-        {
-            if (mList == null) {
-                return null;
-            }
-
-            return mList.get(position);
-        }
-
-        public int getCount()
-        {
-            return mList != null ? mList.size() : 0;
-        }
-
-        public Object getItem(int position)
-        {
-            return position;
-        }
-    
-        public long getItemId(int position)
-        {
-            return position;
-        }
-    
-        public View getView(int position, View convertView, ViewGroup parent)
-        {
-            View view;
-            if (convertView == null) {
-                view = mInflater.inflate(
-                        android.R.layout.simple_list_item_1, parent, false);
-            } else {
-                view = convertView;
-            }
-            bindView(view, mList.get(position));
-            return view;
-        }
-    
-        private final void bindView(View view, ApplicationInfo info)
-        {
-            TextView text = (TextView)view.findViewById(android.R.id.text1);
-    
-            text.setText(info != null ? info.packageName : "(none)");
-        }
-    
-        protected final Context mContext;
-        protected final LayoutInflater mInflater;
-    
-        protected List<ApplicationInfo> mList;
-        
-    }
-
-    private final static Comparator sDisplayNameComparator = new Comparator() {
-        public final int
-        compare(Object a, Object b)
-        {
-            CharSequence  sa = ((ApplicationInfo) a).packageName;
-            CharSequence  sb = ((ApplicationInfo) b).packageName;
-
-            return collator.compare(sa, sb);
-        }
-
-        private final Collator   collator = Collator.getInstance();
-    };
-
-    private AppListAdapter mAdapter;
-}
-
diff --git a/apps/Development/src/com/android/development/ArrayAdapter.java b/apps/Development/src/com/android/development/ArrayAdapter.java
deleted file mode 100644
index 378e98f..0000000
--- a/apps/Development/src/com/android/development/ArrayAdapter.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.content.Context;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-
-import java.util.List;
-
-public abstract class ArrayAdapter<E> extends BaseAdapter
-{
-    public ArrayAdapter(Context context, int layoutRes) {
-        mContext = context;
-        mInflater = (LayoutInflater)context.getSystemService(
-            Context.LAYOUT_INFLATER_SERVICE);
-        mLayoutRes = layoutRes;
-    }
-
-    public void setSource(List<E> list) {
-        mList = list;
-    }
-
-    public abstract void bindView(View view, E item);
-
-    public E itemForPosition(int position) {
-        if (mList == null) {
-            return null;
-        }
-
-        return mList.get(position);
-    }
-
-    public int getCount() {
-        return mList != null ? mList.size() : 0;
-    }
-
-    public Object getItem(int position) {
-        return position;
-    }
-
-    public long getItemId(int position) {
-        return position;
-    }
-
-    public View getView(int position, View convertView, ViewGroup parent) {
-        View view;
-        if (convertView == null) {
-            view = mInflater.inflate(mLayoutRes, parent, false);
-        } else {
-            view = convertView;
-        }
-        bindView(view, mList.get(position));
-        return view;
-    }
-
-    private final Context mContext;
-    private final LayoutInflater mInflater;
-    private final int mLayoutRes;
-    private List<E> mList;
-}
-
diff --git a/apps/Development/src/com/android/development/ColumnData.java b/apps/Development/src/com/android/development/ColumnData.java
deleted file mode 100644
index 28781c2..0000000
--- a/apps/Development/src/com/android/development/ColumnData.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/* //device/apps/Notes/NotesList.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-package com.android.development;
-
-import java.util.ArrayList;
-
-class ColumnData
-{
-    ColumnData(String k, String v)
-    {
-        key = k;
-        value = v;
-    }
-    public String key;
-    public String value;
-}
-
diff --git a/apps/Development/src/com/android/development/DataList.java b/apps/Development/src/com/android/development/DataList.java
deleted file mode 100644
index 5dee2fe..0000000
--- a/apps/Development/src/com/android/development/DataList.java
+++ /dev/null
@@ -1,134 +0,0 @@
-/* //device/apps/Notes/NotesList.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-package com.android.development;
-
-import android.app.ListActivity;
-import android.content.Intent;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.ListView;
-import android.widget.SimpleCursorAdapter;
-
-import java.util.ArrayList;
-
-public class DataList extends ListActivity
-{
-    public void onCreate(Bundle icicle)
-    {
-        super.onCreate(icicle);
-
-        Intent intent = getIntent();
-
-        mCursor = getContentResolver().query(intent.getData(), null, null, null, null);
-        mDisplay = intent.getStringExtra("display");
-        if (mDisplay == null) {
-            mDisplay = "_id";
-        }
-        
-        if (mCursor != null) {
-            setListAdapter(new SimpleCursorAdapter(
-                    this,
-                    R.layout.url_list,
-                    mCursor,
-                    new String[] {mDisplay},
-                    new int[] {android.R.id.text1}));
-        }
-    }
-
-    public void onStop()
-    {
-        super.onStop();
-
-        if (mCursor != null) {
-            mCursor.deactivate();
-        }
-    }
-
-    public void onResume()
-    {
-        super.onResume();
-
-        if (mCursor != null) {
-            mCursor.requery();
-        }
-        
-        setTitle("Showing " + mDisplay);
-    }
-
-    public boolean onCreateOptionsMenu(Menu menu)
-    {
-        super.onCreateOptionsMenu(menu);
-        menu.add(0, 0, 0, "Requery").setOnMenuItemClickListener(mRequery);
-        return true;
-    }
-
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        mCursor.moveToPosition(position);
-
-        ArrayList<ColumnData> data = new ArrayList<ColumnData>();
-
-        String[] columnNames = mCursor.getColumnNames();
-        for (int i=0; i<columnNames.length; i++) {
-            String str = mCursor.getString(i);
-            ColumnData cd = new ColumnData(columnNames[i], str);
-            data.add(cd);
-        }
-
-
-        Uri uri = null;
-        int idCol = mCursor.getColumnIndex("_id");
-        if (idCol >= 0) {
-            uri = Uri.withAppendedPath(getIntent().getData(), mCursor.getString(idCol));
-        }
-        Intent intent = new Intent(Intent.ACTION_VIEW, uri);
-        intent.setClass(this, Details.class);
-
-        intent.putExtra("data", data);
-        int displayColumn = mCursor.getColumnIndex(mDisplay);
-        if (displayColumn >= 0) {
-            intent.putExtra("title",
-                                ((ColumnData)data.get(displayColumn)).value);
-        }
-
-        startActivity(intent);
-    }
-
-    MenuItem.OnMenuItemClickListener mRequery = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            // Should just do requery on cursor, but 
-            // doesn't work right now.  So do this instead.
-            mCursor.requery();
-            if (mCursor != null) {
-                setListAdapter(new SimpleCursorAdapter(
-                        DataList.this,
-                        R.layout.url_list,
-                        mCursor,
-                        new String[] {mDisplay},
-                        new int[] {android.R.id.text1}));
-            }
-            return true;
-        }
-    };
-
-    private String mDisplay;
-    private Cursor mCursor;
-}
diff --git a/apps/Development/src/com/android/development/Details.java b/apps/Development/src/com/android/development/Details.java
deleted file mode 100644
index 16722a3..0000000
--- a/apps/Development/src/com/android/development/Details.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/* //device/apps/Notes/NotesList.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-package com.android.development;
-
-import java.util.ArrayList;
-
-import android.content.Intent;
-import android.app.Activity;
-import android.database.Cursor;
-import android.graphics.Typeface;
-import android.widget.LinearLayout;
-import android.widget.ScrollView;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.TextView;
-
-public class Details extends Activity
-{
-    public void onCreate(Bundle icicle)
-    {
-        super.onCreate(icicle);
-
-        Intent intent = getIntent();
-
-        String title = intent.getStringExtra("title");
-        if (title == null) {
-            title = "Details";
-        }
-        setTitle(title);
-
-        mScrollView = new ScrollView(this);
-        setContentView(mScrollView);
-        mScrollView.setFocusable(true);
-
-        mData = (ArrayList<ColumnData>)getIntent().getExtra("data");
-        addDataViews();
-    }
-
-    public void onResume()
-    {
-        super.onResume();
-    }
-
-    public boolean onCreateOptionsMenu(Menu menu)
-    {
-        super.onCreateOptionsMenu(menu);
-        menu.add(0, 0, 0, "Requery").setOnMenuItemClickListener(mRequery);
-        menu.add(0, 0, 0, "Print to stdout").setOnMenuItemClickListener(mPrintToStdout);
-        return true;
-    }
-
-    void addDataViews()
-    {
-        int oldScroll = 0;
-
-        if (mLinearLayout != null) {
-            mScrollView.removeView(mLinearLayout);
-        }
-        mLinearLayout = new LinearLayout(this);
-        mScrollView.addView(mLinearLayout, new ViewGroup.LayoutParams(
-                                        ViewGroup.LayoutParams.FILL_PARENT,
-                                        ViewGroup.LayoutParams.FILL_PARENT));
-        mLinearLayout.setOrientation(LinearLayout.VERTICAL);
-
-        // Here in onStart, we're given data.  We use that because some
-        // data that we show is transient and can't be retrieved from a url.
-        // We'll try to use that in requery
-        int count = mData.size();
-        for (int i=0; i<count; i++) {
-            ColumnData cd = mData.get(i);
-            TextView label = makeView(cd.key, true, 12);
-            TextView contents = makeView(cd.value, false, 12);
-            contents.setPadding(3, 0, 0, i==count-1?0:3);
-            mLinearLayout.addView(label, lazy());
-            mLinearLayout.addView(contents, lazy());
-        }
-    }
-
-    TextView makeView(String str, boolean bold, int fontSize)
-    {
-        if (str == null) {
-            str = "(null)";
-        }
-        TextView v = new TextView(this);
-        v.setText(str);
-        v.setTextSize(fontSize);
-        if (bold) {
-            v.setTypeface(Typeface.DEFAULT_BOLD);
-        }
-        return v;
-    }
-    
-    LinearLayout.LayoutParams lazy()
-    {
-        return new LinearLayout.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT,
-                                 ViewGroup.LayoutParams.WRAP_CONTENT, 0);
-    }
-
-    MenuItem.OnMenuItemClickListener mRequery = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            Intent intent = getIntent();
-            Cursor c = getContentResolver().query(intent.getData(), null, null, null, null);
-            if (c != null && c.moveToNext()) {
-                mData.clear();
-                String[] columnNames = c.getColumnNames();
-                for (int i=0; i<columnNames.length; i++) {
-                    String str = c.getString(i);
-                    ColumnData cd = new ColumnData(columnNames[i], str);
-                    mData.add(cd);
-                }
-                addDataViews();
-            } else {
-                TextView error = new TextView(Details.this);
-                error.setText("Showing old data.\nURL couldn't be requeried:\n"
-                        + intent.getData());
-                error.setTextColor(0xffff0000);
-                error.setTextSize(11);
-                mLinearLayout.addView(error, 0, lazy());
-            }
-            return true;
-        }
-    };
-
-    MenuItem.OnMenuItemClickListener mPrintToStdout = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            System.out.println("=== begin data ===");
-            int count = mData.size();
-            for (int i=0; i<count; i++) {
-                ColumnData cd = mData.get(i);
-                System.out.println("  " + cd.key + ": " + cd.value);
-            }
-            System.out.println("=== end data ===");
-            return true;
-        }
-    };
-
-    LinearLayout mLinearLayout;
-    ScrollView mScrollView;
-    ArrayList<ColumnData> mData;
-}
diff --git a/apps/Development/src/com/android/development/Development.java b/apps/Development/src/com/android/development/Development.java
deleted file mode 100644
index a3979f2..0000000
--- a/apps/Development/src/com/android/development/Development.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.LauncherActivity;
-import android.content.Intent;
-
-public class Development extends LauncherActivity
-{
-    @Override
-    protected Intent getTargetIntent() {
-        Intent targetIntent = new Intent(Intent.ACTION_MAIN, null);
-        targetIntent.addCategory(Intent.CATEGORY_TEST);
-        targetIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-        return targetIntent;
-    }
-}
diff --git a/apps/Development/src/com/android/development/DevelopmentSettings.java b/apps/Development/src/com/android/development/DevelopmentSettings.java
deleted file mode 100644
index cdc1e0a..0000000
--- a/apps/Development/src/com/android/development/DevelopmentSettings.java
+++ /dev/null
@@ -1,510 +0,0 @@
-/* //device/apps/Settings/src/com/android/settings/Keyguard.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.Activity;
-import android.app.ActivityManagerNative;
-import android.content.Context;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.os.RemoteException;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.os.ServiceManager;
-import android.os.ServiceManagerNative;
-import android.provider.Settings;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.IWindowManager;
-import android.view.View;
-import android.widget.ArrayAdapter;
-import android.widget.Button;
-import android.widget.CheckBox;
-import android.widget.CompoundButton;
-import android.widget.Spinner;
-import android.widget.AdapterView.OnItemSelectedListener;
-
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.util.Map;
-
-public class DevelopmentSettings extends Activity {
-    private static final String TAG = "DevelopmentSettings";
-    private static final int DEBUG_APP_REQUEST = 1;
-
-    private Button mDebugAppButton;
-    private CheckBox mWaitForDebuggerCB;
-    private CheckBox mAlwaysFinishCB;
-    private CheckBox mShowLoadCB;
-    private CheckBox mShowCpuCB;
-    private CheckBox mEnableGLCB;
-    private CheckBox mShowUpdatesCB;
-    private CheckBox mShowBackgroundCB;
-    private CheckBox mShowSleepCB;
-    private CheckBox mShowMapsCompassCB;
-    private CheckBox mShowXmppCB;
-    private Spinner mMaxProcsSpinner;
-    private Spinner mWindowAnimationScaleSpinner;
-    private Spinner mTransitionAnimationScaleSpinner;
-    private Spinner mFontHintingSpinner;
-
-    private String mDebugApp;
-    private boolean mWaitForDebugger;
-    private boolean mAlwaysFinish;
-    private int mProcessLimit;
-    private boolean mShowSleep;
-    private boolean mShowMapsCompass;
-    private boolean mShowXmpp;
-    private AnimationScaleSelectedListener mWindowAnimationScale
-            = new AnimationScaleSelectedListener(0);
-    private AnimationScaleSelectedListener mTransitionAnimationScale
-            = new AnimationScaleSelectedListener(1);
-    private SharedPreferences mSharedPrefs;
-    private IWindowManager mWindowManager;
-
-    private static final boolean FONT_HINTING_ENABLED = true;
-    private static final String  FONT_HINTING_FILE = "/data/misc/font-hack";
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        setContentView(R.layout.development_settings);
-
-        mDebugAppButton = (Button)findViewById(R.id.debug_app);
-        mDebugAppButton.setOnClickListener(mDebugAppClicked);
-        mWaitForDebuggerCB = (CheckBox)findViewById(R.id.wait_for_debugger);
-        mWaitForDebuggerCB.setOnClickListener(mWaitForDebuggerClicked);
-        mAlwaysFinishCB = (CheckBox)findViewById(R.id.always_finish);
-        mAlwaysFinishCB.setOnClickListener(mAlwaysFinishClicked);
-        mShowLoadCB = (CheckBox)findViewById(R.id.show_load);
-        mShowLoadCB.setOnClickListener(mShowLoadClicked);
-        mShowCpuCB = (CheckBox)findViewById(R.id.show_cpu);
-        mShowCpuCB.setOnCheckedChangeListener(new SurfaceFlingerClicker(1000));
-        mEnableGLCB = (CheckBox)findViewById(R.id.enable_gl);
-        mEnableGLCB.getLayoutParams().height = 0; // doesn't do anything
-        mEnableGLCB.setOnCheckedChangeListener(new SurfaceFlingerClicker(1004));
-        mShowUpdatesCB = (CheckBox)findViewById(R.id.show_updates);
-        mShowUpdatesCB.setOnCheckedChangeListener(new SurfaceFlingerClicker(1002));
-        mShowBackgroundCB = (CheckBox)findViewById(R.id.show_background);
-        mShowBackgroundCB.setOnCheckedChangeListener(new SurfaceFlingerClicker(1003));
-        mShowSleepCB = (CheckBox)findViewById(R.id.show_sleep);
-        mShowSleepCB.setOnClickListener(mShowSleepClicked);
-        mShowMapsCompassCB = (CheckBox)findViewById(R.id.show_maps_compass);
-        mShowMapsCompassCB.setOnClickListener(mShowMapsCompassClicked);
-        mShowXmppCB = (CheckBox)findViewById(R.id.show_xmpp);
-        mShowXmppCB.setOnClickListener(mShowXmppClicked);
-        mMaxProcsSpinner = (Spinner)findViewById(R.id.max_procs);
-        mMaxProcsSpinner.setOnItemSelectedListener(mMaxProcsChanged);
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(
-                this,
-                android.R.layout.simple_spinner_item,
-                new String[] {
-                        "No App Process Limit",
-                        "Max 1 App Process",
-                        "Max 2 App Processes",
-                        "Max 3 App Processes",
-                        "Max 4 App Processes" });
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        mMaxProcsSpinner.setAdapter(adapter);
-        mWindowAnimationScaleSpinner = setupAnimationSpinner(
-                R.id.window_animation_scale, mWindowAnimationScale, "Window");
-        mTransitionAnimationScaleSpinner = setupAnimationSpinner(
-                R.id.transition_animation_scale, mTransitionAnimationScale, "Transition");
-
-        if (FONT_HINTING_ENABLED) {
-            mFontHintingSpinner = (Spinner)findViewById(R.id.font_hinting);
-            mFontHintingSpinner.setOnItemSelectedListener(mFontHintingChanged);
-            adapter = new ArrayAdapter<String>(
-                    this,
-                    android.R.layout.simple_spinner_item,
-                    new String[] {
-                            "Light Hinting",
-                            "Medium Hinting" });
-            adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-            mFontHintingSpinner.setAdapter(adapter);
-        }
-        mSharedPrefs = getSharedPreferences("global", 0);
-        mWindowManager = IWindowManager.Stub.asInterface(ServiceManager.getService("window"));
-    }
-
-    Spinner setupAnimationSpinner(int resid,
-            AnimationScaleSelectedListener listener, String name) {
-        Spinner spinner = (Spinner)findViewById(resid);
-        spinner.setOnItemSelectedListener(listener);
-        ArrayAdapter adapter = new ArrayAdapter<String>(
-                this,
-                android.R.layout.simple_spinner_item,
-                new String[] {
-                        name + " Animation Scale 1x",
-                        name + " Animation Scale 2x",
-                        name + " Animation Scale 5x",
-                        name + " Animation Scale 10x",
-                        name + " Animation Off" });
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        spinner.setAdapter(adapter);
-        listener.spinner = spinner;
-        return spinner;
-    }
-    
-    @Override
-    public void onResume() {
-        super.onResume();
-        updateDebugOptions();
-        updateFinishOptions();
-        updateProcessLimitOptions();
-        updateSharedOptions();
-        updateFlingerOptions();
-        updateSleepOptions();
-        updateMapsCompassOptions();
-        updateXmppOptions();        
-
-        try {
-            FileInputStream  in = new FileInputStream( FONT_HINTING_FILE );
-            int    mode = in.read() - 48;
-            if (mode >= 0 && mode < 3)
-                mFontHintingSpinner.setSelection(mode);
-            in.close();
-        } catch (Exception e) {
-        }
-
-        mWindowAnimationScale.load();
-        mTransitionAnimationScale.load();
-    }
-
-    private void writeDebugOptions() {
-        try {
-            ActivityManagerNative.getDefault().setDebugApp(
-                mDebugApp, mWaitForDebugger, true);
-        } catch (RemoteException ex) {
-        }
-    }
-
-    private void updateDebugOptions() {
-        mDebugApp = Settings.System.getString(
-            getContentResolver(), Settings.System.DEBUG_APP);
-        mWaitForDebugger = Settings.System.getInt(
-            getContentResolver(), Settings.System.WAIT_FOR_DEBUGGER, 0) != 0;
-
-        mDebugAppButton.setText(
-            mDebugApp == null || mDebugApp.length() == 0 ? "(none)" : mDebugApp);
-        mWaitForDebuggerCB.setChecked(mWaitForDebugger);
-    }
-
-    private void writeFinishOptions() {
-        try {
-            ActivityManagerNative.getDefault().setAlwaysFinish(mAlwaysFinish);
-        } catch (RemoteException ex) {
-        }
-    }
-
-    private void updateFinishOptions() {
-        mAlwaysFinish = Settings.System.getInt(
-            getContentResolver(), Settings.System.ALWAYS_FINISH_ACTIVITIES, 0) != 0;
-        mAlwaysFinishCB.setChecked(mAlwaysFinish);
-    }
-
-    private void writeProcessLimitOptions() {
-        try {
-            ActivityManagerNative.getDefault().setProcessLimit(mProcessLimit);
-        } catch (RemoteException ex) {
-        }
-    }
-
-    private void updateProcessLimitOptions() {
-        try {
-            mProcessLimit = ActivityManagerNative.getDefault().getProcessLimit();
-            mMaxProcsSpinner.setSelection(mProcessLimit);
-        } catch (RemoteException ex) {
-        }
-    }
-
-    private void updateSharedOptions() {
-        mShowLoadCB.setChecked(Settings.System.getInt(getContentResolver(),
-                Settings.System.SHOW_PROCESSES, 0) != 0);
-    }
-
-    private void updateFlingerOptions() {
-        // magic communication with surface flinger.
-        try {
-            IBinder flinger = ServiceManager.getService("SurfaceFlinger");
-            if (flinger != null) {
-                Parcel data = Parcel.obtain();
-                Parcel reply = Parcel.obtain();
-                data.writeInterfaceToken("android.ui.ISurfaceComposer");
-                flinger.transact(1010, data, reply, 0);
-                int v;
-                v = reply.readInt();
-                mShowCpuCB.setChecked(v != 0);
-                v = reply.readInt();
-                mEnableGLCB.setChecked(v != 0);
-                v = reply.readInt();
-                mShowUpdatesCB.setChecked(v != 0);
-                v = reply.readInt();
-                mShowBackgroundCB.setChecked(v != 0);
-                reply.recycle();
-                data.recycle();
-            }
-        } catch (RemoteException ex) {
-        }
-    }
-
-    private void writeSleepOptions() {
-        try {
-            FileOutputStream os = new FileOutputStream(
-                "/sys/devices/platform/gpio_sleep_debug/enable", true);
-            if(mShowSleep)
-                os.write(new byte[] { (byte)'1' });
-            else
-                os.write(new byte[] { (byte)'0' });
-            os.close();
-        } catch (Exception e) {
-            Log.w(TAG, "Failed setting gpio_sleep_debug");
-        }
-    }
-
-    private void updateSleepOptions() {
-        try {
-            FileInputStream is = new FileInputStream(
-                "/sys/devices/platform/gpio_sleep_debug/enable");
-            int character = is.read();
-            mShowSleep = character == '1';
-            is.close();
-        } catch (Exception e) {
-            Log.w(TAG, "Failed reading gpio_sleep_debug");
-            mShowSleep = false;
-        }
-        mShowSleepCB.setChecked(mShowSleep);
-    }
-
-    private void writeMapsCompassOptions() {
-        try {
-            Context c = createPackageContext("com.google.android.apps.maps", 0);
-            c.getSharedPreferences("extra-features", MODE_WORLD_WRITEABLE)
-                .edit()
-                .putBoolean("compass", mShowMapsCompass)
-                .commit();
-        } catch (NameNotFoundException e) {
-            Log.w(TAG, "Failed setting maps compass");
-            e.printStackTrace();
-        }
-    }
-
-    private void updateMapsCompassOptions() {
-        try {
-            Context c = createPackageContext("com.google.android.apps.maps", 0);
-            mShowMapsCompass = c.getSharedPreferences("extra-features", MODE_WORLD_READABLE)
-                .getBoolean("compass", false);
-        } catch (NameNotFoundException e) {
-            Log.w(TAG, "Failed reading maps compass");
-            e.printStackTrace();
-        }
-        mShowMapsCompassCB.setChecked(mShowMapsCompass);
-    }
-
-    private void writeXmppOptions() {
-        Settings.System.setShowGTalkServiceStatus(getContentResolver(), mShowXmpp);
-    }
-
-    private void updateXmppOptions() {
-        mShowXmpp = Settings.System.getShowGTalkServiceStatus(getContentResolver());
-        mShowXmppCB.setChecked(mShowXmpp);
-    }
-
-    private View.OnClickListener mDebugAppClicked = new View.OnClickListener() {
-        public void onClick(View v) {
-            Intent intent = new Intent(Intent.ACTION_MAIN);
-            intent.setClass(DevelopmentSettings.this, AppPicker.class);
-            startActivityForResult(intent, DEBUG_APP_REQUEST);
-        }
-    };
-
-    @Override
-    public void onActivityResult(int requestCode, int resultCode, Intent intent) {
-        if (requestCode == DEBUG_APP_REQUEST && resultCode == RESULT_OK) {
-            mDebugApp = intent.getAction();
-            writeDebugOptions();
-            updateDebugOptions();
-        }
-    }
-
-    private View.OnClickListener mWaitForDebuggerClicked =
-            new View.OnClickListener() {
-        public void onClick(View v) {
-            mWaitForDebugger = ((CheckBox)v).isChecked();
-            writeDebugOptions();
-            updateDebugOptions();
-        }
-    };
-
-    private View.OnClickListener mAlwaysFinishClicked =
-            new View.OnClickListener() {
-        public void onClick(View v) {
-            mAlwaysFinish = ((CheckBox)v).isChecked();
-            writeFinishOptions();
-            updateFinishOptions();
-        }
-    };
-
-    private View.OnClickListener mShowLoadClicked = new View.OnClickListener() {
-        public void onClick(View v) {
-            boolean value = ((CheckBox)v).isChecked();
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.SHOW_PROCESSES, value ? 1 : 0);
-            Intent service = (new Intent())
-                    .setClassName("android", "com.android.server.LoadAverageService");
-            if (value) {
-                startService(service);
-            } else {
-                stopService(service);
-            }
-        }
-    };
-
-    private class SurfaceFlingerClicker implements CheckBox.OnCheckedChangeListener {
-        SurfaceFlingerClicker(int code) {
-            mCode = code;
-        }
-
-        public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
-            try {
-                IBinder flinger = ServiceManager.getService("SurfaceFlinger");
-                if (flinger != null) {
-                    Parcel data = Parcel.obtain();
-                    data.writeInterfaceToken("android.ui.ISurfaceComposer");
-                    data.writeInt(isChecked ? 1 : 0);
-                    flinger.transact(mCode, data, null, 0);
-                    data.recycle();
-
-                    updateFlingerOptions();
-                }
-            } catch (RemoteException ex) {
-            }
-        }
-
-        final int mCode;
-    }
-
-    private View.OnClickListener mShowSleepClicked =
-            new View.OnClickListener() {
-        public void onClick(View v) {
-            mShowSleep = ((CheckBox)v).isChecked();
-            writeSleepOptions();
-            updateSleepOptions();
-        }
-    };
-
-    private View.OnClickListener mShowMapsCompassClicked =
-        new View.OnClickListener() {
-        public void onClick(View v) {
-            mShowMapsCompass = ((CheckBox)v).isChecked();
-            writeMapsCompassOptions();
-            updateMapsCompassOptions();
-        }
-    };
-
-    
-    private View.OnClickListener mShowXmppClicked = new View.OnClickListener() {
-        public void onClick(View v) {
-            mShowXmpp = ((CheckBox)v).isChecked();
-            // can streamline these calls, but keeping consistent with the
-            // other development settings code.
-            writeXmppOptions();
-            updateXmppOptions();
-        }
-    };
-
-    private Spinner.OnItemSelectedListener mMaxProcsChanged
-                                    = new Spinner.OnItemSelectedListener() {
-        public void onItemSelected(android.widget.AdapterView av, View v,
-                                    int position, long id) {
-            mProcessLimit = position;
-            writeProcessLimitOptions();
-        }
-
-        public void onNothingSelected(android.widget.AdapterView av) {
-        }
-    };
-
-    private Spinner.OnItemSelectedListener mFontHintingChanged
-                                    = new Spinner.OnItemSelectedListener() {
-        public void onItemSelected(android.widget.AdapterView  av, View v,
-                                    int position, long id) {
-            try {
-                FileOutputStream  out = new FileOutputStream( FONT_HINTING_FILE );
-                out.write(position+48);
-                out.close();
-            } catch (Exception e) {
-                Log.w(TAG, "Failed to write font hinting settings to /data/misc/font-hack");
-            }
-        }
-
-        public void onNothingSelected(android.widget.AdapterView av) {
-        }
-    };
-
-    class AnimationScaleSelectedListener implements OnItemSelectedListener {
-        final int which;
-        float scale;
-        Spinner spinner;
-        
-        AnimationScaleSelectedListener(int _which) {
-            which = _which;
-        }
-        
-        void load() {
-            try {
-                scale = mWindowManager.getAnimationScale(which);
-
-                if (scale > 0.1f && scale < 2.0f) {
-                    spinner.setSelection(0);
-                } else if (scale >= 2.0f && scale < 3.0f) {
-                    spinner.setSelection(1);
-                } else if (scale >= 4.9f && scale < 6.0f) {
-                    spinner.setSelection(2);
-                }  else if (scale >= 9.9f && scale < 11.0f) {
-                    spinner.setSelection(3);
-                } else {
-                    spinner.setSelection(4);
-                }
-            } catch (RemoteException e) {
-            }
-        }
-        
-        public void onItemSelected(android.widget.AdapterView av, View v,
-                int position, long id) {
-            switch (position) {
-                case 0: scale = 1.0f; break;
-                case 1: scale = 2.0f; break;
-                case 2: scale = 5.0f; break;
-                case 3: scale = 10.0f; break;
-                case 4: scale = 0.0f; break;
-                default: break;
-            }
-
-            try {
-                mWindowManager.setAnimationScale(which, scale);
-            } catch (RemoteException e) {
-            }
-        }
-
-        public void onNothingSelected(android.widget.AdapterView av) {
-        }
-    }
-}
diff --git a/apps/Development/src/com/android/development/EnterURL.java b/apps/Development/src/com/android/development/EnterURL.java
deleted file mode 100644
index 76b8a34..0000000
--- a/apps/Development/src/com/android/development/EnterURL.java
+++ /dev/null
@@ -1,310 +0,0 @@
-/* //device/apps/Notes/NotesList.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-package com.android.development;
-
-import android.app.ListActivity;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.Intent;
-import android.database.Cursor;
-import android.database.sqlite.SQLiteDatabase;
-import android.net.Uri;
-import android.os.Bundle;
-import android.text.Editable;
-import android.text.Selection;
-import android.text.format.DateUtils;
-import android.util.AttributeSet;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.EditText;
-import android.widget.ListView;
-import android.widget.SimpleAdapter;
-import android.graphics.Rect;
-
-import java.io.FileNotFoundException;
-import java.util.ArrayList;
-import java.util.GregorianCalendar;
-import java.util.HashMap;
-
-public class EnterURL extends ListActivity
-{
-    private static final int DATABASE_VERSION = 1;
-    public static class UrlEditText extends EditText
-    {
-        public UrlEditText(Context context, AttributeSet attrs)
-        {
-            super(context, attrs);
-        }
-        
-        @Override
-        protected void onFocusChanged(boolean focused, int direction, Rect previouslyFocusedRect)
-        {
-            super.onFocusChanged(focused, direction, previouslyFocusedRect);
-            if (focused) {
-                Editable text = getText();
-                String str = text.toString();
-                int highlightStart = 0;
-                if (str.startsWith("content://")) {
-                    highlightStart = "content://".length();
-                }
-                Selection.setSelection(text, highlightStart, text.length());
-            }
-        }
-    }
-
-    public static class DisplayEditText extends EditText
-    {
-        public DisplayEditText(Context context, AttributeSet attrs)
-        {
-            super(context, attrs);
-        }
-        
-        @Override
-        protected void onFocusChanged(boolean focused, int direction, Rect previouslyFocusedRect)
-        {
-            super.onFocusChanged(focused, direction, previouslyFocusedRect);
-            if (focused) {
-                Editable text = getText();
-                Selection.setSelection(text, 0, text.length());
-            }
-        }
-    }
-
-    @Override
-    public View onCreateView(String name, Context context, AttributeSet attrs)
-    {
-        if (name.equals("com.android.development.UrlEditText")) {
-            return new UrlEditText(this, attrs);
-        }
-        if (name.equals("com.android.development.DisplayEditText")) {
-            return new DisplayEditText(this, attrs);
-        }
-        return null;
-    }
-
-    View.OnClickListener mViewItemAction = new View.OnClickListener () {
-        public void onClick(View v)
-        {
-            String url = mUrlField.getText().toString();
-            String display = mDisplayField.getText().toString();
-            viewItem(url, display);
-        }
-    };
-
-    public void onCreate(Bundle icicle)
-    {
-        super.onCreate(icicle);
-        setContentView(R.layout.enter_url);
-
-        // display
-        mDisplayField = (DisplayEditText)findViewById(R.id.display_edit_text);
-        mDisplayField.setOnClickListener(mViewItemAction);
-        // url
-        mUrlField = (UrlEditText)findViewById(R.id.url_edit_text);
-        mUrlField.setOnClickListener(mViewItemAction);
-    }
-
-    public void onStop()
-    {
-        super.onStop();
-
-        if (mCursor != null) {
-            mCursor.deactivate();
-        }
-    }
-
-    public void onResume()
-    {
-        super.onResume();
-
-        // show the history
-        loadPrefs();
-        fillListView();
-        if (mHistory.size() > 0) {
-            ListView lv = this.getListView();
-            lv.setSelection(0);
-            lv.requestFocus();
-        }
-    }
-
-    public boolean onCreateOptionsMenu(Menu menu)
-    {
-        super.onCreateOptionsMenu(menu);
-        menu.add(0, 0, 0, "Clear Bookmarks").setOnMenuItemClickListener(mClearBookmarks);
-        return true;
-    }
-
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        HistoryEntry he = mHistory.get(position);
-        viewItem(he.url, he.display);
-    }
-
-    private final void viewItem(String url, String display)
-    {
-        // -------------- save this in the history ----------------
-        // look in the history
-        int count = mHistory.size();
-        int i;
-        for (i=0; i<count; i++) {
-            HistoryEntry he = mHistory.get(i);
-            if (he.url.equals(url) && he.display.equals(display)) {
-                he.updateAccessTime();
-                mHistory.remove(i);
-                mHistory.add(0, he);
-                break;
-            }
-        }
-        if (i >= count) {
-            // didn't find it, add it first
-            HistoryEntry he = new HistoryEntry();
-            he.url = url;
-            he.display = display;
-            he.updateAccessTime();
-            mHistory.add(0, he);
-        }
-
-        savePrefs();
-
-        // -------------- view it ---------------------------------
-        Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url));
-        intent.setClass(this, DataList.class);
-        intent.putExtra("display", display);
-        startActivity(intent);
-    }
-
-    MenuItem.OnMenuItemClickListener mClearBookmarks = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            mHistory.clear();
-            savePrefs();
-            fillListView();
-            return true;
-        }
-    };
-
-    private void fillListView()
-    {
-        loadPrefs();
-        ArrayList<HashMap<String, String>> d = new ArrayList<HashMap<String, String>>();
-        int count = mHistory.size();
-        for (int i=0; i<count; i++) {
-            HashMap<String, String> m = new HashMap<String, String>();
-            HistoryEntry he = mHistory.get(i);
-            m.put("title", he.url + " (" + he.display + ")");
-            d.add(m);
-        }
-        setListAdapter(new SimpleAdapter(this, d, R.layout.url_list,
-                                         new String[] {"title"},
-                                         new int[] {android.R.id.text1}));
-    }
-
-    SQLiteDatabase openDB()
-    {
-        SQLiteDatabase db = null;
-        db = openOrCreateDatabase("inspector.db", 0, null);
-        int version = db.getVersion();
-        if (version != DATABASE_VERSION) {
-            db.execSQL("CREATE TABLE History ("
-                        + " url TEXT,"
-                        + " display TEXT,"
-                        + " lastAccessTime TEXT"
-                        + ");");
-            db.execSQL("CREATE TABLE FieldState ("
-                        + " url TEXT,"
-                        + " display TEXT"
-                        + ");");
-            db.setVersion(DATABASE_VERSION);
-        }
-        return db;
-    }
-
-    private void loadPrefs()
-    {
-        SQLiteDatabase db = openDB();
-        Cursor c = db.query("History",
-                            new String[] { "url", "display", "lastAccessTime" },
-                            null, null, null, null, "lastAccessTime DESC");
-        int urlCol = c.getColumnIndex("url");
-        int accessCol = c.getColumnIndex("lastAccessTime");
-        int displayCol = c.getColumnIndex("display");
-        mHistory.clear();
-        while (c.moveToNext()) {
-            HistoryEntry he = new HistoryEntry();
-            he.url = c.getString(urlCol);
-            he.display = c.getString(displayCol);
-            he.lastAccessTime = c.getString(accessCol);
-            mHistory.add(he);
-        }
-
-        c = db.query("FieldState", null, null, null, null, null, null);
-        if (c.moveToNext()) {
-            urlCol = c.getColumnIndex("url");
-            displayCol = c.getColumnIndex("display");
-            mUrlField.setText(c.getString(urlCol));
-            mDisplayField.setText(c.getString(displayCol));
-        } else {
-            mDisplayField.setText("_id");
-            mUrlField.setText("content://");
-        }
-
-        db.close();
-    }
-
-    private void savePrefs()
-    {
-        ContentValues m;
-        HistoryEntry he;
-
-        SQLiteDatabase db = openDB();
-        db.execSQL("DELETE FROM History;");
-        int count = mHistory.size();
-        for (int i=0; i<count; i++) {
-            m = new ContentValues();
-            he = mHistory.get(i);
-            m.put("url", he.url);
-            m.put("display", he.display);
-            m.put("lastAccessTime", he.lastAccessTime);
-            db.insert("History", null, m);
-        }
-
-        db.execSQL("DELETE FROM FieldState");
-        m = new ContentValues();
-        m.put("url", mUrlField.getText().toString());
-        m.put("display", mDisplayField.getText().toString());
-        db.insert("FieldState", null, m);
-
-        db.close();
-    }
-
-    private class HistoryEntry
-    {
-        public String url;
-        public String display;
-        public String lastAccessTime;
-        public void updateAccessTime()
-        {
-            this.lastAccessTime = DateUtils.writeDateTime(
-                                                    new GregorianCalendar());
-        }
-    }
-
-    private ArrayList<HistoryEntry> mHistory = new ArrayList<HistoryEntry>();
-    private UrlEditText mUrlField;
-    private DisplayEditText mDisplayField;
-    private Cursor mCursor;
-}
diff --git a/apps/Development/src/com/android/development/ExceptionBrowser.java b/apps/Development/src/com/android/development/ExceptionBrowser.java
deleted file mode 100644
index 63270aa..0000000
--- a/apps/Development/src/com/android/development/ExceptionBrowser.java
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.database.Cursor;
-import android.database.ContentObserver;
-import android.database.DataSetObserver;
-import android.graphics.Typeface;
-import android.os.RemoteException;
-import android.os.ServiceManager;
-import android.provider.Checkin;
-import android.server.data.CrashData;
-import android.server.data.ThrowableData;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.KeyEvent;
-import android.widget.*;
-
-import org.apache.commons.codec.binary.Base64;
-
-import java.io.ByteArrayInputStream;
-import java.io.DataInputStream;
-import java.io.IOException;
-
-/**
- *
- *
- */
-public class ExceptionBrowser extends ListActivity {
-    /** Logging identifier. */
-    private static final String TAG = "ExceptionBrowser";
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        Cursor cursor = getContentResolver().query(
-                Checkin.Crashes.CONTENT_URI,
-                new String[] { Checkin.Crashes._ID, Checkin.Crashes.DATA },
-                null, null, null);
-
-        if (cursor != null) {
-            startManagingCursor(cursor);
-
-            setListAdapter(new CursorAdapter(this, cursor, true) {
-                public View newView(Context context, Cursor c, ViewGroup v) {
-                    return new CrashListItem(context);
-                }
-
-                public void bindView(View view, Context c, Cursor cursor) {
-                    CrashListItem item = (CrashListItem) view;
-                    try {
-                        String data = cursor.getString(1);
-                        CrashData crash = new CrashData(
-                            new DataInputStream(
-                                new ByteArrayInputStream(
-                                    Base64.decodeBase64(data.getBytes()))));
-
-                        ThrowableData exc = crash.getThrowableData();
-                        item.setText(exc.getType() + ": " + exc.getMessage());
-                        item.setCrashData(crash);
-                    } catch (IOException e) {
-                        item.setText("Invalid crash: " + e);
-                        Log.e(TAG, "Invalid crash", e);
-                    }
-                }
-            });
-        } else {
-            // No database, no exceptions, empty list.
-            setListAdapter(new BaseAdapter() {
-                public int getCount() {
-                    return 0;
-                }
-
-                public Object getItem(int position) {
-                    throw new AssertionError();
-                }
-
-                public long getItemId(int position) {
-                    throw new AssertionError();
-                }
-
-                public View getView(int position, View convertView,
-                        ViewGroup parent) {
-                    throw new AssertionError();
-                }
-            });
-        }
-    }
-
-    private static final int UPLOAD_ID = Menu.FIRST;
-    private static final int CLEAR_ID = Menu.FIRST + 1;
-
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        menu.add(0, UPLOAD_ID, 0, R.string.menu_upload_exceptions);
-        menu.add(0, CLEAR_ID, 0, R.string.menu_clear_exceptions);
-
-        return true;
-    }
-
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        // Handle all of the possible menu actions.
-        switch (item.getItemId()) {
-            case UPLOAD_ID:
-                sendBroadcast(new Intent(Checkin.TriggerIntent.ACTION));
-                break;
-            case CLEAR_ID:
-                getContentResolver().delete(
-                        Checkin.Crashes.CONTENT_URI, null, null);
-                break;
-        }
-        return super.onOptionsItemSelected(item);
-    }
-
-    static class CrashListItem extends TextView {
-        CrashData crashData = null;
-
-        public CrashListItem(Context context) {
-            super(context);
-            setTextSize(10);
-            setTypeface(Typeface.MONOSPACE);
-        }
-
-        public CrashData getCrashData() {
-            return crashData;
-        }
-
-        public void setCrashData(CrashData crashData) {
-            this.crashData = crashData;
-        }
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View view, int pos, long id) {
-        // TODO: Use a generic VIEW action on the crash's content URI.
-        CrashData crash = ((CrashListItem) view).getCrashData();
-        if (crash != null) {
-            Intent intent = new Intent();
-            intent.setClass(this, StacktraceViewer.class);
-            intent.putExtra(
-                    CrashData.class.getName(),
-                    crash.getThrowableData().toString());
-            startActivity(intent);
-        }
-    }
-}
diff --git a/apps/Development/src/com/android/development/GLSTester.java b/apps/Development/src/com/android/development/GLSTester.java
deleted file mode 100644
index 4995b4d..0000000
--- a/apps/Development/src/com/android/development/GLSTester.java
+++ /dev/null
@@ -1,210 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import com.google.android.googleapps.GoogleLoginCredentialsResult;
-import com.google.android.googlelogin.GoogleLoginServiceConstants;
-import com.google.android.googleapps.IGoogleLoginService;
-import com.google.android.googleapps.LoginData;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.content.ServiceConnection;
-import android.os.Bundle;
-import android.os.IBinder;
-import android.os.RemoteException;
-import android.util.Log;
-import android.view.View;
-import android.widget.Button;
-import android.widget.CheckBox;
-import android.widget.EditText;
-import android.widget.Spinner;
-
-/**
- * Using a LogTextBox to display a scrollable text area
- * to which text is appended.
- *
- */
-public class GLSTester extends Activity {
-
-    private static final String TAG = "GLSTester";
-
-    private LogTextBox mText;
-
-    private IGoogleLoginService mGls = null;
-    private ServiceConnection mConnection = null;
-
-    CheckBox mDoNotify = null;
-    CheckBox mRunIntent = null;
-    Spinner mService = null;
-    EditText mUsernameEdit = null;
-
-    private class Listener implements View.OnClickListener {
-        public Listener() {
-        }
-
-        public void onClick(View v) {
-            if (mGls == null) {
-                mText.append("mGls is null\n");
-                return;
-            }
-            try {
-                String service = (String) mService.getSelectedItem();
-                mText.append("service: " + service + "\n");
-
-                String account = mUsernameEdit.getText().toString();
-                if (account.length() == 0) {
-                    account = null;
-                }
-                mText.append("account: " + account + "\n");
-                GoogleLoginCredentialsResult result =
-                    mGls.blockingGetCredentials(account, service, mDoNotify.isChecked());
-                mText.append("result account: " + result.getAccount() + "\n");
-                mText.append("result string: " + result.getCredentialsString() + "\n");
-                Intent intent = result.getCredentialsIntent();
-                mText.append("result intent: " + intent + "\n");
-
-                if (intent != null && mRunIntent.isChecked()) {
-                    startActivityForResult(intent, 0);
-                }
-            } catch (RemoteException e) {
-                mText.append("caught exception " + e + "\n");
-            }
-        }
-    }
-
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
-        mText.append("resultCode: " + resultCode + "\n");
-        if (data != null) {
-            mText.append("account: " +
-                         data.getStringExtra(GoogleLoginServiceConstants.AUTH_ACCOUNT_KEY) + "\n");
-            mText.append("authtoken: " +
-                         data.getStringExtra(GoogleLoginServiceConstants.AUTHTOKEN_KEY) + "\n");
-        } else {
-            mText.append("intent is null");
-        }
-    }
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Open a connection to the Google Login Service.  Return the account.
-        mConnection = new ServiceConnection() {
-                public void onServiceConnected(ComponentName className, IBinder service) {
-                    mGls = IGoogleLoginService.Stub.asInterface(service);
-                }
-                public void onServiceDisconnected(ComponentName className) {
-                    mGls = null;
-                }
-            };
-
-        bindService(GoogleLoginServiceConstants.SERVICE_INTENT,
-                    mConnection, Context.BIND_AUTO_CREATE);
-
-        setContentView(R.layout.gls_tester);
-
-        mText = (LogTextBox) findViewById(R.id.text);
-        mText.append("Hello, world!\n");
-        Log.v(TAG, "hello, world!");
-
-        mDoNotify = (CheckBox) findViewById(R.id.do_notification);
-        mRunIntent = (CheckBox) findViewById(R.id.run_intent);
-        mRunIntent.setChecked(true);
-
-        mService = (Spinner) findViewById(R.id.service_spinner);
-
-        mUsernameEdit = (EditText) findViewById(R.id.username_edit);
-
-        Button b;
-        b = (Button) findViewById(R.id.require_google);
-        b.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                try {
-                    String account = mGls.getAccount(GoogleLoginServiceConstants.REQUIRE_GOOGLE);
-                    mText.append("REQUIRE_GOOGLE gave: " + account + "\n");
-                    mUsernameEdit.setText(account == null ? "" : account);
-                } catch (RemoteException e) {
-                    mText.append("exception: " + e + "\n");
-                }
-            } });
-
-        b = (Button) findViewById(R.id.prefer_hosted);
-        b.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                try {
-                    String account = mGls.getAccount(GoogleLoginServiceConstants.PREFER_HOSTED);
-                    mText.append("PREFER_HOSTED gave: " + account + "\n");
-                    mUsernameEdit.setText(account == null ? "" : account);
-                } catch (RemoteException e) {
-                    mText.append("exception: " + e + "\n");
-                }
-            } });
-
-
-        b = (Button) findViewById(R.id.get_accounts);
-        b.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                try {
-                    String[] accounts = mGls.getAccounts();
-                    mText.append("account list: (" + accounts.length + " entries)\n");
-                    for (String username: accounts) {
-                        mText.append("  " + username + "\n");
-                    }
-                } catch (RemoteException e) {
-                    mText.append("exception: " + e + "\n");
-                }
-            } });
-
-        b = (Button) findViewById(R.id.clear);
-        b.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                mText.setText("");
-            } });
-
-        b = (Button) findViewById(R.id.go);
-        b.setOnClickListener(new Listener());
-
-        b = (Button) findViewById(R.id.wipe_passwords);
-        b.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                mText.setText("wiping passwords:\n");
-                try {
-                    String[] accounts = mGls.getAccounts();
-                    LoginData ld = new LoginData();
-                    for (String username: accounts) {
-                        ld.mUsername = username;
-                        mGls.updatePassword(ld);
-                        mText.append("  " + username + "\n");
-                    }
-                    mText.append("done.\n");
-                } catch (RemoteException e) {
-                    mText.append("caught exception " + e + "\n");
-                }
-            } });
-
-    }
-
-    @Override
-    protected void onDestroy() {
-        super.onDestroy();
-        unbindService(mConnection);
-    }
-}
diff --git a/apps/Development/src/com/android/development/IRemoteService.aidl b/apps/Development/src/com/android/development/IRemoteService.aidl
deleted file mode 100644
index 0a60d34..0000000
--- a/apps/Development/src/com/android/development/IRemoteService.aidl
+++ /dev/null
@@ -1,24 +0,0 @@
-/* //device/samples/SampleCode/src/com/android/development/IRemoteService.aidl
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-interface IRemoteService
-{
-    int getPid();
-}
-
diff --git a/apps/Development/src/com/android/development/InstrumentationList.java b/apps/Development/src/com/android/development/InstrumentationList.java
deleted file mode 100644
index 88f09f8..0000000
--- a/apps/Development/src/com/android/development/InstrumentationList.java
+++ /dev/null
@@ -1,197 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.ActivityManagerNative;
-import android.app.IInstrumentationWatcher;
-import android.app.ListActivity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.pm.InstrumentationInfo;
-import android.content.pm.PackageManager;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.util.Log;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-
-import java.util.Collections;
-import java.util.List;
-
-class InstrumentationAdapter extends BaseAdapter
-{
-    private PackageManager mPM;
-
-    public InstrumentationAdapter(Context context, String targetPackage)
-    {
-        mContext = context;
-        mTargetPackage = targetPackage;
-        mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        mPM = context.getPackageManager();
-
-        mList = context.getPackageManager().queryInstrumentation(mTargetPackage, 0);
-        if (mList != null) {
-            Collections.sort(mList, new InstrumentationInfo.DisplayNameComparator(mPM));
-        }
-    }
-
-    public ComponentName instrumentationForPosition(int position)
-    {
-        if (mList == null) {
-            return null;
-        }
-        InstrumentationInfo ii = mList.get(position);
-        return new ComponentName(ii.packageName, ii.name);
-    }
-
-    public int getCount()
-    {
-        return mList != null ? mList.size() : 0;
-    }
-
-    public Object getItem(int position)
-    {
-        return position;
-    }
-
-    public long getItemId(int position)
-    {
-        return position;
-    }
-
-    public View getView(int position, View convertView, ViewGroup parent)
-    {
-        View view;
-        if (convertView == null) {
-            view = mInflater.inflate(
-                    android.R.layout.simple_list_item_1, parent, false);
-        } else {
-            view = convertView;
-        }
-        bindView(view, mList.get(position));
-        return view;
-    }
-
-    private final void bindView(View view, InstrumentationInfo info)
-    {
-        TextView text = (TextView)view.findViewById(android.R.id.text1);
-        CharSequence label = info.loadLabel(mPM);
-        text.setText(label != null ? label : info.name);
-    }
-
-    protected final Context mContext;
-    protected final String mTargetPackage;
-    protected final LayoutInflater mInflater;
-
-    protected List<InstrumentationInfo> mList;
-}
-
-public class InstrumentationList extends ListActivity
-{
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        mProfilingMode = icicle != null && icicle.containsKey("profiling");
-        setListAdapter(new InstrumentationAdapter(this, null));
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu)
-    {
-        super.onCreateOptionsMenu(menu);
-        mProfilingItem = menu.add(0, 0, 0, "Profiling Mode")
-        .setOnMenuItemClickListener(mProfilingCallback);
-        mProfilingItem.setCheckable(true);
-        return true;
-    }
-
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu)
-    {
-        super.onPrepareOptionsMenu(menu);
-        mProfilingItem.setChecked(mProfilingMode);
-        return true;
-    }
-
-    @Override
-    protected void onSaveInstanceState(Bundle outState)
-    {
-        if (mProfilingMode) {
-            outState.putBoolean("profiling", true);
-        }
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        ComponentName className = ((InstrumentationAdapter)getListAdapter()).
-            instrumentationForPosition(position);
-        if (className != null) {
-            String profilingFile = null;
-            if (mProfilingMode) {
-                profilingFile = "/tmp/trace/" + className + ".dmtrace";
-            }
-            try {
-                ActivityManagerNative.getDefault().
-                    startInstrumentation(className, profilingFile, 0, null, mWatcher);
-            } catch (RemoteException ex) {
-            }
-        }
-    }
-
-    private MenuItem.OnMenuItemClickListener mProfilingCallback =
-            new MenuItem.OnMenuItemClickListener()
-    {
-        public boolean onMenuItemClick(MenuItem item) {
-            mProfilingMode = !mProfilingMode;
-            return true;
-        }
-    };
-
-    private IInstrumentationWatcher mWatcher = new IInstrumentationWatcher.Stub() {
-        
-        public void instrumentationStatus(ComponentName name, int resultCode, Bundle results) {
-            if (results != null) {
-                for (String key : results.keySet()) {
-                    Log.i("instrumentation", 
-                            "INSTRUMENTATION_STATUS_RESULT: " + key + "=" + results.get(key));
-                }
-            }
-            Log.i("instrumentation", "INSTRUMENTATION_STATUS_CODE: " + resultCode);
-        }
-    	public void instrumentationFinished(ComponentName name,
-    	            int resultCode, Bundle results) {
-            if (results != null) {
-                for (String key : results.keySet()) {
-                    Log.i("instrumentation", 
-                            "INSTRUMENTATION_RESULT: " + key + "=" + results.get(key));
-                }
-            }
-            Log.i("instrumentation", "INSTRUMENTATION_CODE: " + resultCode);
-    	}
-    };
-
-    private MenuItem mProfilingItem;
-    private boolean mProfilingMode;
-}
diff --git a/apps/Development/src/com/android/development/LogTextBox.java b/apps/Development/src/com/android/development/LogTextBox.java
deleted file mode 100644
index 2f99ab2..0000000
--- a/apps/Development/src/com/android/development/LogTextBox.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.widget.TextView;
-import android.content.Context;
-import android.text.method.ScrollingMovementMethod;
-import android.text.method.MovementMethod;
-import android.text.method.KeyListener;
-import android.text.method.TransformationMethod;
-import android.text.Editable;
-import android.util.AttributeSet;
-
-
-/**
- * This is a TextView that is Editable and by default scrollable,
- * like EditText without a cursor.
- *
- * <p>
- * <b>XML attributes</b>
- * <p>
- * See
- * {@link android.R.styleable#TextView TextView Attributes},
- * {@link android.R.styleable#View View Attributes}
- */
-public class LogTextBox extends TextView {
-    public LogTextBox(Context context) {
-        this(context, null);
-    }
-
-    public LogTextBox(Context context, AttributeSet attrs) {
-        this(context, attrs, android.R.attr.textViewStyle);
-    }
-
-    public LogTextBox(Context context, AttributeSet attrs, int defStyle) {
-        super(context, attrs, defStyle);
-    }
-
-    @Override
-    protected boolean getDefaultEditable() {
-        return true;
-    }
-
-    @Override
-    protected MovementMethod getDefaultMovementMethod() {
-        return ScrollingMovementMethod.getInstance();
-    }
-
-    @Override
-    public Editable getText() {
-        return (Editable) super.getText();
-    }
-
-    @Override
-    public void setText(CharSequence text, BufferType type) {
-        super.setText(text, BufferType.EDITABLE);
-    }
-}
diff --git a/apps/Development/src/com/android/development/LogViewer.java b/apps/Development/src/com/android/development/LogViewer.java
deleted file mode 100644
index aadc0d4..0000000
--- a/apps/Development/src/com/android/development/LogViewer.java
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import static com.android.internal.util.CharSequences.forAsciiBytes;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.io.FileOutputStream;
-import java.net.Socket;
-
-import android.app.Activity;
-import android.os.Handler;
-import android.os.Bundle;
-import android.util.Log;
-import android.graphics.Typeface;
-import android.view.Gravity;
-
-/**
- * Views the device log.
- */
-public class LogViewer extends Activity {
-
-    static final String TAG = LogViewer.class.getSimpleName();
-
-    FileOutputStream logger;
-
-    volatile boolean active = true;
-    Handler handler;
-    LogTextBox text;
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.log_viewer);
-        this.handler = new Handler();
-
-        text = (LogTextBox) findViewById(R.id.text);
-
-        text.setTextSize(10);
-        text.setHorizontallyScrolling(true);
-        text.setTypeface(Typeface.MONOSPACE);
-        text.setGravity(Gravity.BOTTOM | Gravity.LEFT);
-
-        this.active = true;
-        try {
-            logger = new FileOutputStream("/tmp/logviewer.txt");
-            new Thread(new LogReader()).start();
-        } catch (IOException e) {
-            appendThrowable(e);
-        }
-    }
-
-    private void appendThrowable(Throwable t) {
-        StringBuilder builder = new StringBuilder();
-        builder.append("Error reading log: ");
-        builder.append(Log.getStackTraceString(t));
-        text.getText().append(builder);
-    }
-
-    private class LogReader implements Runnable {
-
-        final Socket socket;
-        final DataInputStream in;
-        StringBuilder builder = new StringBuilder();
-        long lastTime = System.currentTimeMillis();
-
-        private static final int HEADER_SIZE = 24;
-
-        public LogReader() throws IOException {
-            this.socket = new Socket("127.0.0.1", 5040);
-            this.in = new DataInputStream(this.socket.getInputStream());
-            // Write two newlines to indicate "no reader args"
-            this.socket.getOutputStream().write('\n');
-            this.socket.getOutputStream().write('\n');
-        }
-
-        public void run() {
-            while (active) {
-                try {
-                    while (in.available() > 0) {
-                        logger.write("Reading message.\n".getBytes());
-
-                        int length = in.readInt();
-                        byte[] bytes = new byte[length];
-                        in.readFully(bytes);
-
-                        int tagEnd = next0(bytes, HEADER_SIZE);
-                        int fileEnd = next0(bytes, tagEnd + 1);
-                        int messageEnd = next0(bytes, fileEnd + 1);
-
-                        CharSequence tag
-                                = forAsciiBytes(bytes, HEADER_SIZE, tagEnd);
-                        CharSequence message
-                                = forAsciiBytes(bytes, fileEnd + 1, messageEnd);
-
-                        builder.append(tag)
-                                .append(": ")
-                                .append(message)
-                                .append("\n");
-                    }
-
-                    logger.write("Updating UI.\n".getBytes());
-                    handler.post(new AppendCharacters(builder));
-                    builder = new StringBuilder();
-
-                    try {
-                        Thread.sleep(1000);
-                    } catch (InterruptedException e) {}
-                } catch (final IOException e) {
-                    handler.post(new AppendThrowable(e));
-                }
-            }
-        }
-    }
-
-    static int next0(byte[] bytes, int start) {
-        for (int current = start; current < bytes.length; current++) {
-            if (bytes[current] == 0)
-                return current;
-        }
-        return bytes.length;
-    }
-
-    private class AppendThrowable implements Runnable {
-
-        private final Throwable t;
-
-        public AppendThrowable(Throwable t) {
-            this.t = t;
-        }
-
-        public void run() {
-            appendThrowable(t);
-        }
-    }
-
-    private class AppendCharacters implements Runnable {
-
-        private final CharSequence message;
-
-        public AppendCharacters(CharSequence message) {
-            this.message = message;
-        }
-
-        public void run() {
-            text.getText().append(message);
-//            try {
-//                logger.write(builder.toString().getBytes());
-//            } catch (IOException e) {
-//                appendThrowable(e);
-//            }
-        }
-    }
-}
diff --git a/apps/Development/src/com/android/development/MediaScannerActivity.java b/apps/Development/src/com/android/development/MediaScannerActivity.java
deleted file mode 100644
index f78910a..0000000
--- a/apps/Development/src/com/android/development/MediaScannerActivity.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.IntentFilter;
-import android.content.BroadcastReceiver;
-import android.net.Uri;
-import android.os.Environment;
-import android.widget.TextView;
-
-public class MediaScannerActivity extends Activity
-{
-    public MediaScannerActivity() {
-    }
- 
-    /** Called when the activity is first created or resumed. */
-    @Override
-    public void onResume() {
-        super.onResume();
-        
-        setContentView(R.layout.media_scanner_activity);
-        
-        IntentFilter intentFilter = new IntentFilter(Intent.ACTION_MEDIA_SCANNER_STARTED);
-        intentFilter.addAction(Intent.ACTION_MEDIA_SCANNER_FINISHED);
-        intentFilter.addDataScheme("file");
-        registerReceiver(mReceiver, intentFilter);
-        
-        sendBroadcast(new Intent(Intent.ACTION_MEDIA_MOUNTED, Uri.parse("file://"
-                + Environment.getExternalStorageDirectory())));
-            
-        mTitle = (TextView) findViewById(R.id.title);
-        mTitle.setText("Sent ACTION_MEDIA_MOUNTED to trigger the Media Scanner.");
-    }
-
-    /** Called when the activity going into the background or being destroyed. */
-    @Override
-    public void onPause() {
-        super.onPause();
-        unregisterReceiver(mReceiver);
-    }
-    
-    private final BroadcastReceiver mReceiver = new BroadcastReceiver() {
-        @Override
-        public void onReceive(Context context, Intent intent) {
-            if (intent.getAction().equals(Intent.ACTION_MEDIA_SCANNER_STARTED)) {
-                mTitle.setText("Media Scanner started scanning " + intent.getData().getPath());     
-            }
-            else if (intent.getAction().equals(Intent.ACTION_MEDIA_SCANNER_FINISHED)) {
-                mTitle.setText("Media Scanner finished scanning " + intent.getData().getPath());     
-            }
-        }
-    };
-
-    private TextView mTitle;
-}
diff --git a/apps/Development/src/com/android/development/PackageBrowser.java b/apps/Development/src/com/android/development/PackageBrowser.java
deleted file mode 100644
index e4c233f..0000000
--- a/apps/Development/src/com/android/development/PackageBrowser.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.AlertDialog;
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.pm.IPackageDeleteObserver;
-import android.content.Intent;
-import android.content.IntentFilter;
-import android.content.BroadcastReceiver;
-import android.content.pm.PackageInfo;
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.os.Handler;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.ListView;
-import android.widget.TextView;
-
-import java.text.Collator;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-public class PackageBrowser extends ListActivity
-{
-    private PackageListAdapter mAdapter;
-    private List<PackageInfo> mPackageInfoList = null;
-    private Handler mHandler;
-
-    public class PackageListAdapter extends ArrayAdapter<PackageInfo>
-    {
-
-        public PackageListAdapter(Context context)
-        {
-            super(context, android.R.layout.simple_list_item_1);
-            mPackageInfoList = context.getPackageManager().getInstalledPackages(0);
-            if (mPackageInfoList != null) {
-                Collections.sort(mPackageInfoList, sDisplayNameComparator);
-            }
-            setSource(mPackageInfoList);
-        }
-    
-        @Override
-        public void bindView(View view, PackageInfo info)
-        {
-            TextView text = (TextView)view.findViewById(android.R.id.text1);
-            text.setText(info.packageName);
-        }
-    }
-
-    /**
-     * Receives notifications when applications are added/removed.
-     */
-    private class ApplicationsIntentReceiver extends BroadcastReceiver {
-        @Override
-        public void onReceive(Context context, Intent intent) {
-            // todo: this is a bit brute force.  We should probably get the action and package name
-            //       from the intent and just add to or delete from the mPackageInfoList
-            setupAdapter();
-        }
-    }
-
-    private final static Comparator sDisplayNameComparator = new Comparator() {
-        public final int
-        compare(Object a, Object b)
-        {
-            CharSequence  sa = ((PackageInfo) a).packageName;
-            CharSequence  sb = ((PackageInfo) b).packageName;
-            return collator.compare(sa, sb);
-        }
-
-        private final Collator   collator = Collator.getInstance();
-    };
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setupAdapter();
-        mHandler= new Handler();
-        registerIntentReceivers();
-    }
-
-    private void setupAdapter() {
-        mAdapter = new PackageListAdapter(this);
-        setListAdapter(mAdapter);
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        menu.add(0, 0, 0, "Delete package").setOnMenuItemClickListener(
-                new MenuItem.OnMenuItemClickListener() {
-            public boolean onMenuItemClick(MenuItem item) {
-                deletePackage();
-                return true;
-            }
-        });
-        return true;
-    }
-
-    private void deletePackage() {
-        final int curSelection = getSelectedItemPosition();
-        if (curSelection >= 0) {
-            // todo: verification dialog for package deletion
-            final PackageInfo packageInfo = mAdapter.itemForPosition(curSelection);
-            if (packageInfo != null) {
-                getPackageManager().deletePackage(packageInfo.packageName,
-                                                  new IPackageDeleteObserver.Stub() {
-                    public void packageDeleted(boolean succeeded) throws RemoteException {
-                        if (succeeded) {
-                            mPackageInfoList.remove(curSelection);
-                            mHandler.post(new Runnable() {
-                                    public void run() {
-                                        mAdapter.notifyDataSetChanged();
-                                    }
-                                });
-
-                            // todo: verification dialog for data directory
-                            final String dataPath = packageInfo.applicationInfo.dataDir;
-                            // todo: delete the data directory
-                        } else {
-                            mHandler.post(new Runnable() {
-                                    public void run() {
-                                        new AlertDialog.Builder(PackageBrowser.this)
-                                            .setTitle("Oops")
-                                            .setMessage("Could not delete package." +
-                                                "  Maybe it is in /system/app rather than /data/app?")
-                                            .show();
-                                    }
-                                });
-
-                        }
-                    }
-                },
-                                                  0);
-            }
-        }
-    }
-
-    private void registerIntentReceivers() {
-        IntentFilter filter = new IntentFilter(Intent.ACTION_PACKAGE_ADDED);
-        filter.addAction(Intent.ACTION_PACKAGE_REMOVED);
-        filter.addAction(Intent.ACTION_PACKAGE_CHANGED);
-        filter.addDataScheme("package");
-        registerReceiver(new ApplicationsIntentReceiver(), filter);
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        PackageInfo info =
-            mAdapter.itemForPosition(position);
-        if (info != null) {
-            Intent intent = new Intent(
-                null, Uri.fromParts("package", info.packageName, null));
-            intent.setClass(this, PackageSummary.class);
-            startActivity(intent);
-        }
-    }
-}
diff --git a/apps/Development/src/com/android/development/PackageSummary.java b/apps/Development/src/com/android/development/PackageSummary.java
deleted file mode 100644
index a6bbbb2..0000000
--- a/apps/Development/src/com/android/development/PackageSummary.java
+++ /dev/null
@@ -1,269 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.Activity;
-import android.app.ActivityManagerNative;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.ActivityInfo;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.InstrumentationInfo;
-import android.content.pm.PackageInfo;
-import android.content.pm.PackageManager;
-import android.content.pm.ProviderInfo;
-import android.content.pm.ServiceInfo;
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.widget.Button;
-import android.widget.ImageView;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-
-public class PackageSummary extends Activity {
-
-    String mPackageName;
-    private TextView mPackage;
-    private ImageView mIconImage;
-    private TextView mClass;
-    private TextView mLabel;
-    private View mDisabled;
-    private View mSystem;
-    private View mDebuggable;
-    private View mNoCode;
-    private View mPersistent;
-    private Button mRestart;
-    private TextView mTask;
-    private TextView mVersion;
-    private TextView mProcess;
-    private TextView mUid;
-    private TextView mSource;
-    private TextView mData;
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        setContentView(R.layout.package_summary);
-
-        final PackageManager pm = getPackageManager();
-
-        mPackage = (TextView)findViewById(R.id.packageView);
-        mIconImage = (ImageView)findViewById(R.id.icon);
-        mClass = (TextView)findViewById(R.id.classView);
-        mLabel = (TextView)findViewById(R.id.label);
-        mDisabled = findViewById(R.id.disabled);
-        mSystem = findViewById(R.id.system);
-        mDebuggable = findViewById(R.id.debuggable);
-        mNoCode = findViewById(R.id.nocode);
-        mPersistent = findViewById(R.id.persistent);
-        mRestart = (Button)findViewById(R.id.restart);
-        mTask = (TextView)findViewById(R.id.task);
-        mVersion = (TextView)findViewById(R.id.version);
-        mUid = (TextView)findViewById(R.id.uid);
-        mProcess = (TextView)findViewById(R.id.process);
-        mSource = (TextView)findViewById(R.id.source);
-        mData = (TextView)findViewById(R.id.data);
-
-        mPackageName = getIntent().getData().getSchemeSpecificPart();
-        PackageInfo info = null;
-        try {
-            info = pm.getPackageInfo(mPackageName,
-                PackageManager.GET_ACTIVITIES | PackageManager.GET_RECEIVERS
-                | PackageManager.GET_SERVICES | PackageManager.GET_PROVIDERS
-                | PackageManager.GET_INSTRUMENTATION);
-        } catch (PackageManager.NameNotFoundException e) {
-        }
-
-        if (info != null) {
-            mPackage.setText(info.packageName);
-            CharSequence label = null;
-            String appClass = null;
-            if (info.applicationInfo != null) {
-                mIconImage.setImageDrawable(
-                    pm.getApplicationIcon(info.applicationInfo));
-                label = info.applicationInfo.nonLocalizedLabel;
-                appClass = info.applicationInfo.className;
-                if (info.applicationInfo.enabled) {
-                    mDisabled.setVisibility(View.GONE);
-                }
-                if ((info.applicationInfo.flags&ApplicationInfo.FLAG_SYSTEM) == 0) {
-                    mSystem.setVisibility(View.GONE);
-                }
-                if ((info.applicationInfo.flags&ApplicationInfo.FLAG_DEBUGGABLE) == 0) {
-                    mDebuggable.setVisibility(View.GONE);
-                }
-                if ((info.applicationInfo.flags&ApplicationInfo.FLAG_HAS_CODE) != 0) {
-                    mNoCode.setVisibility(View.GONE);
-                }
-                if ((info.applicationInfo.flags&ApplicationInfo.FLAG_PERSISTENT) == 0) {
-                    mPersistent.setVisibility(View.GONE);
-                }
-                mUid.setText(Integer.toString(info.applicationInfo.uid));
-                mProcess.setText(info.applicationInfo.processName);
-                if (info.versionName != null) {
-                    mVersion.setText(info.versionName + " (#" + info.versionCode + ")");
-                } else {
-                    mVersion.setText("(#" + info.versionCode + ")");
-                }
-                mSource.setText(info.applicationInfo.sourceDir);
-                mData.setText(info.applicationInfo.dataDir);
-                if (info.applicationInfo.taskAffinity != null) {
-                    mTask.setText("\"" + info.applicationInfo.taskAffinity + "\"");
-                } else {
-                    mTask.setText("(No Task Affinity)");
-                }
-            }
-            if (appClass != null) {
-                if (appClass.startsWith(info.packageName + "."))
-                    mClass.setText(appClass.substring(info.packageName.length()));
-                else
-                    mClass.setText(appClass);
-            } else {
-                mClass.setText("(No Application Class)");
-            }
-            if (label != null) {
-                mLabel.setText("\"" + label + "\"");
-            } else {
-                mLabel.setText("(No Label)");
-            }
-
-            mRestart.setOnClickListener(new View.OnClickListener() {
-                public void onClick(View v) {
-                    try {
-                        ActivityManagerNative.getDefault().restartPackage(mPackageName);
-                    } catch (RemoteException e) {
-                    }
-                }
-            });
-            
-            final LayoutInflater inflate =
-                (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-            LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(
-                LinearLayout.LayoutParams.WRAP_CONTENT,
-                LinearLayout.LayoutParams.WRAP_CONTENT);
-            LinearLayout activities = (LinearLayout)findViewById(R.id.activities);
-            LinearLayout receivers = (LinearLayout)findViewById(R.id.receivers);
-            LinearLayout services = (LinearLayout)findViewById(R.id.services);
-            LinearLayout providers = (LinearLayout)findViewById(R.id.providers);
-            LinearLayout instrumentation = (LinearLayout)findViewById(R.id.instrumentation);
-
-            if (info.activities != null) {
-                final int N = info.activities.length;
-                for (int i=0; i<N; i++) {
-                    ActivityInfo ai = info.activities[i];
-                    // If an activity is disabled then the ActivityInfo will be null 
-                    if (ai != null) {
-                        Button view = (Button)inflate.inflate(
-                                R.layout.package_item, null, false);
-                        view.setOnClickListener(new ActivityOnClick(
-                                new ComponentName(ai.applicationInfo.packageName,
-                                                  ai.name)));
-                        setItemText(view, info, ai.name);
-                        activities.addView(view, lp);
-                    }
-                }
-            } else {
-                activities.setVisibility(View.GONE);
-            }
-
-            if (info.receivers != null) {
-                final int N = info.receivers.length;
-                for (int i=0; i<N; i++) {
-                    ActivityInfo ai = info.receivers[i];
-                    Button view = (Button)inflate.inflate(
-                        R.layout.package_item, null, false);
-                    setItemText(view, info, ai.name);
-                    receivers.addView(view, lp);
-                }
-            } else {
-                receivers.setVisibility(View.GONE);
-            }
-
-            if (info.services != null) {
-                final int N = info.services.length;
-                for (int i=0; i<N; i++) {
-                    ServiceInfo si = info.services[i];
-                    Button view = (Button)inflate.inflate(
-                        R.layout.package_item, null, false);
-                    setItemText(view, info, si.name);
-                    services.addView(view, lp);
-                }
-            } else {
-                services.setVisibility(View.GONE);
-            }
-
-            if (info.providers != null) {
-                final int N = info.providers.length;
-                for (int i=0; i<N; i++) {
-                    ProviderInfo pi = info.providers[i];
-                    Button view = (Button)inflate.inflate(
-                        R.layout.package_item, null, false);
-                    setItemText(view, info, pi.name);
-                    providers.addView(view, lp);
-                }
-            } else {
-                providers.setVisibility(View.GONE);
-            }
-
-            if (info.instrumentation != null) {
-                final int N = info.instrumentation.length;
-                for (int i=0; i<N; i++) {
-                    InstrumentationInfo ii = info.instrumentation[i];
-                    Button view = (Button)inflate.inflate(
-                        R.layout.package_item, null, false);
-                    setItemText(view, info, ii.name);
-                    instrumentation.addView(view, lp);
-                }
-            } else {
-                instrumentation.setVisibility(View.GONE);
-            }
-
-        }
-        
-        // Put focus here, so a button doesn't get focus and cause the
-        // scroll view to move to it.
-        mPackage.requestFocus();
-    }
-
-    private final static void setItemText(Button item, PackageInfo pi,
-                                          String className)
-    {
-        item.setText(className.substring(pi.packageName.length()+1));
-    }
-
-    private final class ActivityOnClick implements View.OnClickListener
-    {
-        private final ComponentName mClassName;
-        ActivityOnClick(ComponentName className) {
-            mClassName = className;
-        }
-
-        public void onClick(View v) {
-            Intent intent = new Intent(
-                null, Uri.fromParts("component",
-                    mClassName.flattenToString(), null));
-            intent.setClass(PackageSummary.this, ShowActivity.class);
-            startActivity(intent);
-        }
-    }
-}
diff --git a/apps/Development/src/com/android/development/PointerLocation.java b/apps/Development/src/com/android/development/PointerLocation.java
deleted file mode 100644
index 668e9ba..0000000
--- a/apps/Development/src/com/android/development/PointerLocation.java
+++ /dev/null
@@ -1,197 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.graphics.Paint.FontMetricsInt;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.MotionEvent;
-import android.view.WindowManager;
-import android.view.VelocityTracker;
-import android.view.View;
-
-import java.util.ArrayList;
-
-/**
- * Demonstrates wrapping a layout in a ScrollView.
- *
- */
-public class PointerLocation extends Activity {
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(new MyView(this));
-        
-        // Make the screen full bright for this activity.
-        WindowManager.LayoutParams lp = getWindow().getAttributes();
-        lp.screenBrightness = 1.0f;
-        getWindow().setAttributes(lp);
-    }
-    
-    public class MyView extends View {
-        private final Paint mTextPaint;
-        private final Paint mTextBackgroundPaint;
-        private final Paint mTextLevelPaint;
-        private final Paint mPaint;
-        private final Paint mTargetPaint;
-        private final FontMetricsInt mTextMetrics = new FontMetricsInt();
-        private final ArrayList<Float> mXs = new ArrayList<Float>();
-        private final ArrayList<Float> mYs = new ArrayList<Float>();
-        private int mHeaderBottom;
-        private boolean mCurDown;
-        private int mCurX;
-        private int mCurY;
-        private float mCurPressure;
-        private float mCurSize;
-        private int mCurWidth;
-        private VelocityTracker mVelocity;
-        
-        public MyView(Context c) {
-            super(c);
-            mTextPaint = new Paint();
-            mTextPaint.setAntiAlias(true);
-            mTextPaint.setTextSize(10);
-            mTextPaint.setARGB(255, 0, 0, 0);
-            mTextBackgroundPaint = new Paint();
-            mTextBackgroundPaint.setAntiAlias(false);
-            mTextBackgroundPaint.setARGB(128, 255, 255, 255);
-            mTextLevelPaint = new Paint();
-            mTextLevelPaint.setAntiAlias(false);
-            mTextLevelPaint.setARGB(192, 255, 0, 0);
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-            mPaint.setARGB(255, 255, 255, 255);
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setStrokeWidth(2);
-            mTargetPaint = new Paint();
-            mTargetPaint.setAntiAlias(false);
-            mTargetPaint.setARGB(192, 0, 0, 255);
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setStrokeWidth(1);
-        }
-
-        @Override
-        protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-            super.onMeasure(widthMeasureSpec, heightMeasureSpec);
-            mTextPaint.getFontMetricsInt(mTextMetrics);
-            mHeaderBottom = -mTextMetrics.ascent+mTextMetrics.descent+2;
-            Log.i("foo", "Metrics: ascent=" + mTextMetrics.ascent
-                    + " descent=" + mTextMetrics.descent
-                    + " leading=" + mTextMetrics.leading
-                    + " top=" + mTextMetrics.top
-                    + " bottom=" + mTextMetrics.bottom);
-        }
-
-        @Override
-        protected void onDraw(Canvas canvas) {
-            int w = getWidth()/5;
-            int base = -mTextMetrics.ascent+1;
-            int bottom = mHeaderBottom;
-            canvas.drawRect(0, 0, w-1, bottom, mTextBackgroundPaint);
-            canvas.drawText("X: " + mCurX, 1, base, mTextPaint);
-            canvas.drawRect(w, 0, (w * 2) - 1, bottom, mTextBackgroundPaint);
-            canvas.drawText("Y: " + mCurY, 1 + w, base, mTextPaint);
-            canvas.drawRect(w * 2, 0, (w * 3) - 1, bottom, mTextBackgroundPaint);
-            canvas.drawRect(w * 2, 0, (w * 2) + (mCurPressure * w) - 1, bottom, mTextLevelPaint);
-            canvas.drawText("Pres: " + mCurPressure, 1 + w * 2, base, mTextPaint);
-            canvas.drawRect(w * 3, 0, (w * 4) - 1, bottom, mTextBackgroundPaint);
-            canvas.drawRect(w * 3, 0, (w * 3) + (mCurSize * w) - 1, bottom, mTextLevelPaint);
-            canvas.drawText("Size: " + mCurSize, 1 + w * 3, base, mTextPaint);
-            canvas.drawRect(w * 4, 0, getWidth(), bottom, mTextBackgroundPaint);
-            int velocity = mVelocity == null ? 0 : (int) (mVelocity.getYVelocity() * 1000);
-            canvas.drawText("yVel: " + velocity, 1 + w * 4, base, mTextPaint);
-            
-            final int N = mXs.size();
-            float lastX=0, lastY=0;
-            mPaint.setARGB(255, 0, 255, 255);
-            for (int i=0; i<N; i++) {
-                float x = mXs.get(i);
-                float y = mYs.get(i);
-                if (i > 0) {
-                    canvas.drawLine(lastX, lastY, x, y, mTargetPaint);
-                    canvas.drawPoint(lastX, lastY, mPaint);
-                }
-                lastX = x;
-                lastY = y;
-            }
-            if (mVelocity != null) {
-                mPaint.setARGB(255, 255, 0, 0);
-                float xVel = mVelocity.getXVelocity() * (1000/60);
-                float yVel = mVelocity.getYVelocity() * (1000/60);
-                canvas.drawLine(lastX, lastY, lastX+xVel, lastY+yVel, mPaint);
-            } else {
-                canvas.drawPoint(lastX, lastY, mPaint);
-            }
-            
-            if (mCurDown) {
-                canvas.drawLine(0, (int)mCurY, getWidth(), (int)mCurY, mTargetPaint);
-                canvas.drawLine((int)mCurX, 0, (int)mCurX, getHeight(), mTargetPaint);
-                int pressureLevel = (int)(mCurPressure*255);
-                mPaint.setARGB(255, pressureLevel, 128, 255-pressureLevel);
-                canvas.drawPoint(mCurX, mCurY, mPaint);
-                canvas.drawCircle(mCurX, mCurY, mCurWidth, mPaint);
-            }
-        }
-
-        @Override
-        public boolean onTouchEvent(MotionEvent event) {
-            int action = event.getAction();
-            //mRect.set(0, 0, getWidth(), mHeaderBottom+1);
-            //invalidate(mRect);
-            //if (mCurDown) {
-            //    mRect.set(mCurX-mCurWidth-3, mCurY-mCurWidth-3,
-            //            mCurX+mCurWidth+3, mCurY+mCurWidth+3);
-            //} else {
-            //    mRect.setEmpty();
-            //}
-            if (action == MotionEvent.ACTION_DOWN) {
-                mXs.clear();
-                mYs.clear();
-                mVelocity = VelocityTracker.obtain();
-            }
-            mVelocity.addMovement(event);
-            mVelocity.computeCurrentVelocity(1);
-            final int N = event.getHistorySize();
-            for (int i=0; i<N; i++) {
-                mXs.add(event.getHistoricalX(i));
-                mYs.add(event.getHistoricalY(i));
-            }
-            mXs.add(event.getX());
-            mYs.add(event.getY());
-            mCurDown = action == MotionEvent.ACTION_DOWN
-                    || action == MotionEvent.ACTION_MOVE;
-            mCurX = (int)event.getX();
-            mCurY = (int)event.getY();
-            mCurPressure = event.getPressure();
-            mCurSize = event.getSize();
-            mCurWidth = (int)(mCurSize*(getWidth()/3));
-            //if (mCurDown) {
-            //    mRect.union(mCurX-mCurWidth-3, mCurY-mCurWidth-3,
-            //            mCurX+mCurWidth+3, mCurY+mCurWidth+3);
-            //}
-            //invalidate(mRect);
-            invalidate();
-            return true;
-        }
-        
-    }
-}
diff --git a/apps/Development/src/com/android/development/ProcessInfo.java b/apps/Development/src/com/android/development/ProcessInfo.java
deleted file mode 100755
index 5ece1a4..0000000
--- a/apps/Development/src/com/android/development/ProcessInfo.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.os.Bundle;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-public class ProcessInfo extends Activity {
-    PackageManager mPm;
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        Intent intent = getIntent();
-        String processName = intent.getStringExtra("processName");
-        String pkgList[] = intent.getStringArrayExtra("packageList");
-        mPm = getPackageManager();
-        setContentView(R.layout.process_info);
-       TextView processNameView = (TextView) findViewById(R.id.process_name);
-       LinearLayout pkgListView = (LinearLayout) findViewById(R.id.package_list);
-       if(processName != null) {
-           processNameView.setText(processName);
-       }
-       if(pkgList != null) {
-           for(String pkg : pkgList) {
-               TextView pkgView = new TextView(this);
-               pkgView.setText(pkg);
-               pkgListView.addView(pkgView);
-           }
-       }
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-    }
-
-    @Override
-    protected void onStop() {
-        super.onStop();
-    }
-}
-
diff --git a/apps/Development/src/com/android/development/RadioIssueReport.java b/apps/Development/src/com/android/development/RadioIssueReport.java
deleted file mode 100644
index b1a95f4..0000000
--- a/apps/Development/src/com/android/development/RadioIssueReport.java
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.os.SystemProperties;
-import android.provider.Checkin;
-import com.android.internal.telephony.Phone;
-import com.android.internal.telephony.PhoneFactory;
-import android.telephony.ServiceState;
-import android.text.format.DateFormat;
-import static com.android.internal.util.CharSequences.forAsciiBytes;
-import android.util.Log;
-import android.view.View.OnClickListener;
-import android.view.View;
-import android.widget.Button;
-import android.widget.EditText;
-
-import com.google.android.collect.Maps;
-
-import java.io.DataInputStream;
-import java.io.EOFException;
-import java.io.IOException;
-import java.net.Socket;
-import java.util.Calendar;
-import java.util.GregorianCalendar;
-import java.util.Map;
-
-/**
- * Report radio issues to the StatisticsService.
- */
-public class RadioIssueReport extends Activity
-{
-    private static final String TAG = "RadioIssue";
-    private static final int HEADER_SIZE = 24;
-    private static final String RADIO_BUFFER_OPTIONS = "-b radio\n-d\n";
-
-    /** List of system properties to snapshot. */
-    private static String[] SYSTEM_PROPERTIES = {
-        "net.gsm.radio-reset",
-        "net.gsm.attempt-gprs",
-        "net.gsm.succeed-gprs",
-        "net.gsm.disconnect",
-        "net.ppp.sent",
-        "net.ppp.received",
-        "gsm.version.baseband",
-        "gsm.version.ril-impl",
-    };
-
-    private Button          mSubmitButton;
-    private EditText        mReportText;
-    private ServiceState mServiceState;
-    private Phone.State     mPhoneState;
-    private int             mSignalStrength;
-    private Phone.DataState mDataState;
-    private String          mRadioLog;
-
-    /** Snapshot of interesting variables relevant to the radio. */
-    private Map<String, String> mRadioState;
-
-    @Override
-    public void
-    onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        setContentView(R.layout.radio_issue);
-
-        initSubmitButton();
-        initReportText();
-
-        mRadioState = snapState();
-    }
-
-    /**
-     * @return a snapshot of phone state variables to report.
-     */
-    private static Map<String, String> snapState() {
-        Map<String, String> state = Maps.newHashMap();
-
-        // Capture a bunch of system properties
-        for (String property: SYSTEM_PROPERTIES) {
-            String value = SystemProperties.get(property);
-            state.put(property, SystemProperties.get(property));
-        }
-
-        Phone phone = PhoneFactory.getDefaultPhone();
-        state.put("phone-data", phone.getDataConnectionState().toString());
-        state.put("phone-service", phone.getServiceState().toString());
-        state.put("phone-signal", String.valueOf(phone.getSignalStrengthASU()));
-        state.put("phone-state", phone.getState().toString());
-
-        try {
-            state.put("radio-log", getRadioLog());
-        } catch (IOException e) {
-            Log.e(TAG, "Error reading radio log", e);
-        }
-
-        return state;
-    }
-
-    private void initSubmitButton() {
-        mSubmitButton = (Button) findViewById(R.id.submit);
-        mSubmitButton.setOnClickListener(mSubmitButtonHandler);
-    }
-
-    private void initReportText() {
-        mReportText = (EditText) findViewById(R.id.report_text);
-        mReportText.requestFocus();
-    }
-
-    OnClickListener mSubmitButtonHandler = new OnClickListener() {
-        public void onClick(View v) {
-            // Include the user-supplied report text.
-            mRadioState.put("user-report", mReportText.getText().toString());
-
-            // Dump the state variables directly into the report.
-            Checkin.logEvent(getContentResolver(),
-                    Checkin.Events.Tag.RADIO_BUG_REPORT,
-                    mRadioState.toString());
-
-            finish();
-        }
-    };
-
-    // Largely stolen from LogViewer.java
-    private static String getRadioLog() throws IOException {
-        Socket sock = new Socket("127.0.0.1", 5040);
-        DataInputStream in = new DataInputStream(sock.getInputStream());
-        StringBuilder log = new StringBuilder();
-
-        // Set options
-        sock.getOutputStream().write(RADIO_BUFFER_OPTIONS.getBytes());
-        sock.getOutputStream().write('\n');
-        sock.getOutputStream().write('\n');
-
-        // Read in the log
-        try {
-            Calendar cal = new GregorianCalendar();
-
-            while (true) {
-                int length = in.readInt();
-                long when = (long)in.readInt();
-                byte[] bytes = new byte[length-4];
-                in.readFully(bytes);
-
-                int tagEnd = next0(bytes, HEADER_SIZE-4);
-                int fileEnd = next0(bytes, tagEnd + 1);
-                int messageEnd = next0(bytes, fileEnd + 1);
-
-                CharSequence tag
-                        = forAsciiBytes(bytes, HEADER_SIZE-4, tagEnd);
-                CharSequence message
-                        = forAsciiBytes(bytes, fileEnd + 1, messageEnd);
-
-                cal.setTimeInMillis(when*1000);
-                log.append(DateFormat.format("MM-dd kk:mm:ss ", cal));
-                log.append(tag)
-                   .append(": ")
-                   .append(message)
-                   .append("\n");
-            }
-        } catch (EOFException e) {
-            Log.d(TAG, "reached end of stream");
-        }
-
-        return log.toString();
-    }
-
-    private static int next0(byte[] bytes, int start) {
-        for (int current = start; current < bytes.length; current++) {
-            if (bytes[current] == 0)
-                return current;
-        }
-        return bytes.length;
-    }
-}
diff --git a/apps/Development/src/com/android/development/RunningProcesses.java b/apps/Development/src/com/android/development/RunningProcesses.java
deleted file mode 100755
index 7b56be9..0000000
--- a/apps/Development/src/com/android/development/RunningProcesses.java
+++ /dev/null
@@ -1,154 +0,0 @@
-/*
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.ActivityManager;
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-import java.text.Collator;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-public class RunningProcesses extends ListActivity {
-    PackageManager mPm;
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        mPm = getPackageManager();
-        mAdapter = new AppListAdapter(this);
-        if (mAdapter.getCount() <= 0) {
-            finish();
-        } else {
-            setListAdapter(mAdapter);
-        }
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-    }
-
-    @Override
-    protected void onStop() {
-        super.onStop();
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) {
-        ListItem app = mAdapter.appForPosition(position);
-        // Create intent to start new activity
-        Intent intent = new Intent(Intent.ACTION_VIEW);
-        intent.setClass(this, ProcessInfo.class);
-        intent.putExtra("processName", app.procInfo.processName);
-        intent.putExtra("packageList", app.procInfo.pkgList);
-        // start new activity to display extended information
-        startActivity(intent);
-    }
-
-    private final class AppListAdapter extends BaseAdapter {
-        public AppListAdapter(Context context) {
-            mContext = context;
-            mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-
-            ActivityManager am = (ActivityManager)getSystemService(Context.ACTIVITY_SERVICE);
-            List<ActivityManager.RunningAppProcessInfo> appList = am.getRunningAppProcesses();
-            for (ActivityManager.RunningAppProcessInfo app : appList) {
-                if(mList == null) {
-                    mList = new ArrayList<ListItem>();
-                }
-                mList.add(new ListItem(app));    
-            }
-            if (mList != null) {
-                Collections.sort(mList, sDisplayNameComparator);
-            }
-        }
-    
-        public ListItem appForPosition(int position) {
-            if (mList == null) {
-                return null;
-            }
-            return mList.get(position);
-        }
-
-        public int getCount() {
-            return mList != null ? mList.size() : 0;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-    
-        public long getItemId(int position) {
-            return position;
-        }
-    
-        public View getView(int position, View convertView, ViewGroup parent) {
-            View view;
-            if (convertView == null) {
-                view = mInflater.inflate(
-                        android.R.layout.simple_list_item_1, parent, false);
-            } else {
-                view = convertView;
-            }
-            bindView(view, mList.get(position));
-            return view;
-        }
-    
-        private final void bindView(View view, ListItem info) {
-            TextView text = (TextView)view.findViewById(android.R.id.text1);
-            text.setText(info != null ? info.procInfo.processName : "(none)");
-        }
-    
-        protected final Context mContext;
-        protected final LayoutInflater mInflater;
-        protected List<ListItem> mList;
-        
-    }
-
-    private final Comparator sDisplayNameComparator = new Comparator() {
-        public final int compare(Object a, Object b) {
-            CharSequence  sa = ((ListItem) a).procInfo.processName;
-            CharSequence  sb = ((ListItem) b).procInfo.processName;
-            return collator.compare(sa, sb);
-        }
-        private final Collator   collator = Collator.getInstance();
-    };
-    
-    private class ListItem {
-        ActivityManager.RunningAppProcessInfo procInfo;
-        public ListItem(ActivityManager.RunningAppProcessInfo pInfo) {
-            procInfo = pInfo;
-        }
-    }
-
-    private AppListAdapter mAdapter;
-}
-
diff --git a/apps/Development/src/com/android/development/ShowActivity.java b/apps/Development/src/com/android/development/ShowActivity.java
deleted file mode 100644
index 1fc2816..0000000
--- a/apps/Development/src/com/android/development/ShowActivity.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/* //device/apps/Settings/src/com/android/settings/Keyguard.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.content.pm.ActivityInfo;
-import android.content.pm.PackageManager;
-import android.content.res.Resources;
-import android.provider.Settings;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.ImageView;
-import android.widget.TextView;
-
-
-public class ShowActivity extends Activity {
-
-    private ActivityInfo mActivityInfo;
-
-    private TextView mPackage;
-    private ImageView mIconImage;
-    private TextView mClass;
-    private TextView mLabel;
-    private TextView mLaunch;
-    private TextView mProcess;
-    private TextView mTaskAffinity;
-    private TextView mPermission;
-    private TextView mMultiprocess;
-    private TextView mClearOnBackground;
-    private TextView mStateNotNeeded;
-
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        setContentView(R.layout.show_activity);
-
-        mPackage = (TextView)findViewById(R.id.packageView);
-        mIconImage = (ImageView)findViewById(R.id.icon);
-        mClass = (TextView)findViewById(R.id.classView);
-        mLabel = (TextView)findViewById(R.id.label);
-        mLaunch = (TextView)findViewById(R.id.launch);
-        mProcess = (TextView)findViewById(R.id.process);
-        mTaskAffinity = (TextView)findViewById(R.id.taskAffinity);
-        mPermission = (TextView)findViewById(R.id.permission);
-        mMultiprocess = (TextView)findViewById(R.id.multiprocess);
-        mClearOnBackground = (TextView)findViewById(R.id.clearOnBackground);
-        mStateNotNeeded = (TextView)findViewById(R.id.stateNotNeeded);
-
-        final PackageManager pm = getPackageManager();
-        try {
-            mActivityInfo = pm.getActivityInfo(ComponentName.unflattenFromString(
-                getIntent().getData().getSchemeSpecificPart()), 0);
-        } catch (PackageManager.NameNotFoundException e) {
-        }
-        if (mActivityInfo != null) {
-            mPackage.setText(mActivityInfo.applicationInfo.packageName);
-            mIconImage.setImageDrawable(mActivityInfo.loadIcon(pm));
-            if (mActivityInfo.name.startsWith(
-                    mActivityInfo.applicationInfo.packageName + ".")) {
-                mClass.setText(mActivityInfo.name.substring(
-                        mActivityInfo.applicationInfo.packageName.length()));
-            } else {
-                mClass.setText(mActivityInfo.name);
-            }
-            CharSequence label = mActivityInfo.loadLabel(pm);
-            mLabel.setText("\"" + (label != null ? label : "") + "\"");
-            switch (mActivityInfo.launchMode) {
-            case ActivityInfo.LAUNCH_MULTIPLE:
-                mLaunch.setText(getText(R.string.launch_multiple));
-                break;
-            case ActivityInfo.LAUNCH_SINGLE_TOP:
-                mLaunch.setText(getText(R.string.launch_singleTop));
-                break;
-            case ActivityInfo.LAUNCH_SINGLE_TASK:
-                mLaunch.setText(getText(R.string.launch_singleTask));
-                break;
-            case ActivityInfo.LAUNCH_SINGLE_INSTANCE:
-                mLaunch.setText(getText(R.string.launch_singleInstance));
-                break;
-            default:
-                mLaunch.setText(getText(R.string.launch_unknown));
-            }
-            mProcess.setText(mActivityInfo.processName);
-            mTaskAffinity.setText(mActivityInfo.taskAffinity != null
-                    ? mActivityInfo.taskAffinity : getText(R.string.none));
-            mPermission.setText(mActivityInfo.permission != null
-                    ? mActivityInfo.permission : getText(R.string.none));
-            mMultiprocess.setText(
-                    (mActivityInfo.flags&ActivityInfo.FLAG_MULTIPROCESS) != 0
-                    ? getText(R.string.yes) : getText(R.string.no));
-            mClearOnBackground.setText(
-                    (mActivityInfo.flags&ActivityInfo.FLAG_CLEAR_TASK_ON_LAUNCH) != 0
-                    ? getText(R.string.yes) : getText(R.string.no));
-            mStateNotNeeded.setText(
-                    (mActivityInfo.flags&ActivityInfo.FLAG_STATE_NOT_NEEDED) != 0
-                    ? getText(R.string.yes) : getText(R.string.no));
-        }
-    }
-
-    public void onResume() {
-        super.onResume();
-    }
-}
diff --git a/apps/Development/src/com/android/development/StacktraceViewer.java b/apps/Development/src/com/android/development/StacktraceViewer.java
deleted file mode 100644
index 96b0521..0000000
--- a/apps/Development/src/com/android/development/StacktraceViewer.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.development;
-
-
-import android.app.Activity;
-import android.widget.EditText;
-import android.widget.TextView;
-import android.text.method.ScrollingMovementMethod;
-import android.os.Bundle;
-import android.server.data.CrashData;
-import android.server.data.ThrowableData;
-import android.server.data.StackTraceElementData;
-import android.graphics.Typeface;
-
-/**
- * Views a single stack trace.
- */
-public class StacktraceViewer extends Activity {
-
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.log_viewer);
-
-        TextView text = (TextView) findViewById(R.id.text);
-        text.setTextSize(10);
-        text.setHorizontallyScrolling(true);
-        text.setTypeface(Typeface.MONOSPACE);
-        text.setMovementMethod(ScrollingMovementMethod.getInstance());
-        
-        String stacktrace = getIntent().getExtras().getString(
-                CrashData.class.getName());
-
-        text.setText(stacktrace);
-    }
-}
diff --git a/apps/Development/src/com/android/development/UnderdevelopedSettings.java b/apps/Development/src/com/android/development/UnderdevelopedSettings.java
deleted file mode 100644
index 9cf1b90..0000000
--- a/apps/Development/src/com/android/development/UnderdevelopedSettings.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.development;
-
-import android.app.LauncherActivity;
-import android.content.Intent;
-
-public class UnderdevelopedSettings extends LauncherActivity {
-
-    @Override
-    protected Intent getTargetIntent() {
-        Intent targetIntent = new Intent(Intent.ACTION_MAIN, null);
-        targetIntent.addCategory(Intent.CATEGORY_DEVELOPMENT_PREFERENCE);
-        return targetIntent;
-    }
-
-}
diff --git a/apps/Fallback/Android.mk b/apps/Fallback/Android.mk
deleted file mode 100644
index 64b7d17..0000000
--- a/apps/Fallback/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := user development
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := Fallback
-
-include $(BUILD_PACKAGE)
diff --git a/apps/Fallback/AndroidManifest.xml b/apps/Fallback/AndroidManifest.xml
deleted file mode 100644
index 802406d..0000000
--- a/apps/Fallback/AndroidManifest.xml
+++ /dev/null
@@ -1,62 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.fallback">
-    <application android:label="@string/appTitle">
-
-        <activity android:name="Fallback" android:label="@string/title"
-				android:theme="@android:style/Theme.Dialog">
-<!-- for debugging on non-SDK builds
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
--->
-			<!-- SMS intents -->
-            <intent-filter android:priority="-1000">
-                <action android:name="android.intent.action.VIEW" />
-				<category android:name="android.intent.category.DEFAULT" />
-                <data android:mimeType="vnd.android.cursor.item/sms-chat" />
-            </intent-filter>
-            <intent-filter android:priority="-1000">
-                <action android:name="android.intent.action.VIEW" />
-                <action android:name="android.intent.action.SENDTO" />
-				<category android:name="android.intent.category.DEFAULT" />
-                <data android:scheme="sms" />
-            </intent-filter>
-            <intent-filter android:priority="-1000">
-	            <action android:name="android.intent.action.VIEW" />
-				<category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.BROWSABLE" />
-	            <data android:mimeType="vnd.android.cursor.item/sms" />
-            </intent-filter>
-
-			<!-- Mail intents -->
-            <intent-filter android:priority="-1000">
-                <action android:name="android.intent.action.VIEW" />
-                <action android:name="android.intent.action.SENDTO" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.BROWSABLE" />
-                <data android:scheme="mailto" />
-            </intent-filter>
-
-			<!-- Wallpaper intents -->
-            <intent-filter android:priority="-1000">
-                <action android:name="android.intent.action.WALLPAPER_SETTINGS" />
-				<category android:name="android.intent.category.DEFAULT" />
-			</intent-filter>
-			
-			<!-- Camera intents -->
-			<intent-filter android:priority="-1000">
-			    <action android:name="android.intent.action.GET_CONTENT" />
-                <category android:name="android.intent.category.DEFAULT" />
-			    <data android:mimeType="image/*" />
-			</intent-filter>
-			
-			<!-- Settings Intent -->
-			<intent-filter android:priority="-1000">
-				<action android:name="android.settings.SETTINGS" />
-				<category android:name="android.intent.category.DEFAULT" />
-			</intent-filter>
-        </activity>
-                                
-    </application>
-
-</manifest>
diff --git a/apps/Fallback/MODULE_LICENSE_APACHE2 b/apps/Fallback/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/apps/Fallback/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/apps/Fallback/NOTICE b/apps/Fallback/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/apps/Fallback/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/apps/Fallback/res/layout/fallback.xml b/apps/Fallback/res/layout/fallback.xml
deleted file mode 100644
index 5ddfd82..0000000
--- a/apps/Fallback/res/layout/fallback.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:orientation="vertical">
-
-    <TextView android:id="@+id/text"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="6dip"
-        android:layout_marginLeft="6dip"
-        android:text="@string/error" />
-</RelativeLayout>
diff --git a/apps/Fallback/res/values-cs/strings.xml b/apps/Fallback/res/values-cs/strings.xml
deleted file mode 100644
index b9d34f9..0000000
--- a/apps/Fallback/res/values-cs/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Záloha"</string>
-    <string name="title">"Akce není podporována"</string>
-    <string name="error">"Tato akce není momentálně podporována."</string>
-</resources>
diff --git a/apps/Fallback/res/values-de/strings.xml b/apps/Fallback/res/values-de/strings.xml
deleted file mode 100644
index 8d59ddf..0000000
--- a/apps/Fallback/res/values-de/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"Nicht unterstützte Aktion"</string>
-    <string name="error">"Diese Aktion wird zurzeit nicht unterstützt."</string>
-</resources>
diff --git a/apps/Fallback/res/values-es/strings.xml b/apps/Fallback/res/values-es/strings.xml
deleted file mode 100644
index 0ce5751..0000000
--- a/apps/Fallback/res/values-es/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"Acción no admitida"</string>
-    <string name="error">"Esa acción no se admite actualmente."</string>
-</resources>
diff --git a/apps/Fallback/res/values-fr/strings.xml b/apps/Fallback/res/values-fr/strings.xml
deleted file mode 100644
index 024ae42..0000000
--- a/apps/Fallback/res/values-fr/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Application de secours"</string>
-    <string name="title">"Action non prise en charge"</string>
-    <string name="error">"Cette action n\'est actuellement pas prise en charge."</string>
-</resources>
diff --git a/apps/Fallback/res/values-it/strings.xml b/apps/Fallback/res/values-it/strings.xml
deleted file mode 100644
index d216e59..0000000
--- a/apps/Fallback/res/values-it/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"Azione non supportata"</string>
-    <string name="error">"L\'azione non è al momento supportata."</string>
-</resources>
diff --git a/apps/Fallback/res/values-ja/strings.xml b/apps/Fallback/res/values-ja/strings.xml
deleted file mode 100644
index 79aeb42..0000000
--- a/apps/Fallback/res/values-ja/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"サポートされていない操作"</string>
-    <string name="error">"現在サポートされていない操作です。"</string>
-</resources>
diff --git a/apps/Fallback/res/values-ko/strings.xml b/apps/Fallback/res/values-ko/strings.xml
deleted file mode 100644
index 1e98e20..0000000
--- a/apps/Fallback/res/values-ko/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"지원되지 않는 작업"</string>
-    <string name="error">"이 작업은 현재 지원되지 않습니다."</string>
-</resources>
diff --git a/apps/Fallback/res/values-nb/strings.xml b/apps/Fallback/res/values-nb/strings.xml
deleted file mode 100644
index 6fed660..0000000
--- a/apps/Fallback/res/values-nb/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"Ustøttet handling"</string>
-    <string name="error">"Denne handlingen er ikke støttet nå."</string>
-</resources>
diff --git a/apps/Fallback/res/values-nl/strings.xml b/apps/Fallback/res/values-nl/strings.xml
deleted file mode 100644
index f347964..0000000
--- a/apps/Fallback/res/values-nl/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Reserve"</string>
-    <string name="title">"Niet-ondersteunde actie"</string>
-    <string name="error">"Die actie wordt momenteel niet ondersteund."</string>
-</resources>
diff --git a/apps/Fallback/res/values-pl/strings.xml b/apps/Fallback/res/values-pl/strings.xml
deleted file mode 100644
index 73a176a..0000000
--- a/apps/Fallback/res/values-pl/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Wycofanie"</string>
-    <string name="title">"Nieobsługiwana czynność"</string>
-    <string name="error">"Ta czynność nie jest aktualnie obsługiwana."</string>
-</resources>
diff --git a/apps/Fallback/res/values-ru/strings.xml b/apps/Fallback/res/values-ru/strings.xml
deleted file mode 100644
index dc292a8..0000000
--- a/apps/Fallback/res/values-ru/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"Действие не поддерживается"</string>
-    <string name="error">"В настоящее время это действие не поддерживается."</string>
-</resources>
diff --git a/apps/Fallback/res/values-zh-rCN/strings.xml b/apps/Fallback/res/values-zh-rCN/strings.xml
deleted file mode 100644
index 13ef687..0000000
--- a/apps/Fallback/res/values-zh-rCN/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"Fallback"</string>
-    <string name="title">"不支持的操作"</string>
-    <string name="error">"当前不支持该操作。"</string>
-</resources>
diff --git a/apps/Fallback/res/values-zh-rTW/strings.xml b/apps/Fallback/res/values-zh-rTW/strings.xml
deleted file mode 100644
index 52afdbe..0000000
--- a/apps/Fallback/res/values-zh-rTW/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="appTitle">"備用"</string>
-    <string name="title">"不支援的操作"</string>
-    <string name="error">"目前不支援此操作。"</string>
-</resources>
diff --git a/apps/Fallback/res/values/strings.xml b/apps/Fallback/res/values/strings.xml
deleted file mode 100644
index bc0b71d..0000000
--- a/apps/Fallback/res/values/strings.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- Name of the fallback application. It's used only on the SDK when applications from
-         real phones aren't available. -->
-    <string name="appTitle">Fallback</string>
-    <!-- Dialog title informing the user that the requested action is not supported -->
-    <string name="title">Unsupported action</string>
-    <!-- Dialog content informing the user that the requested action is not supported -->
-    <string name="error">That action is not currently supported.</string>
-</resources>
diff --git a/apps/Fallback/src/com/android/fallback/Fallback.java b/apps/Fallback/src/com/android/fallback/Fallback.java
deleted file mode 100644
index 1a7600e..0000000
--- a/apps/Fallback/src/com/android/fallback/Fallback.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.fallback;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-/**
- * A fall back activity that registers itself for common intents which
- * may possibly not otherwise be handled.
- */
-public class Fallback extends Activity {
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.fallback);
-    }
-}
diff --git a/apps/FontLab/Android.mk b/apps/FontLab/Android.mk
deleted file mode 100644
index 3cad52a..0000000
--- a/apps/FontLab/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := FontLab
-
-include $(BUILD_PACKAGE)
diff --git a/apps/FontLab/AndroidManifest.xml b/apps/FontLab/AndroidManifest.xml
deleted file mode 100644
index ea961d5..0000000
--- a/apps/FontLab/AndroidManifest.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.fontlab">
-    <application android:label="Font lab">
-		<activity android:name="FontLab">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-		</activity>
-		<activity android:name="BackgroundPicker"/>
-		<activity android:name="FontPicker"/>
-    </application>
-</manifest>
diff --git a/apps/FontLab/MODULE_LICENSE_APACHE2 b/apps/FontLab/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/apps/FontLab/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/apps/FontLab/NOTICE b/apps/FontLab/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/apps/FontLab/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/apps/FontLab/res/layout/font_lab.xml b/apps/FontLab/res/layout/font_lab.xml
deleted file mode 100644
index 1a79add..0000000
--- a/apps/FontLab/res/layout/font_lab.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/content"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical"
-    android:paddingLeft="4dip" android:paddingRight="4dip"
-    android:paddingTop="4dip" android:paddingBottom="4dip">
-        
-    <TextView android:id="@+id/column1" android:layout_width="fill_parent" android:layout_height="0dip" android:layout_weight="1"
-        android:layout_marginBottom="8dip" />
-    <TextView android:id="@+id/column2" android:layout_width="fill_parent" android:layout_height="0dip" android:layout_weight="1" />
-        
-</LinearLayout>
-
-
diff --git a/apps/FontLab/src/com/android/fontlab/BackgroundPicker.java b/apps/FontLab/src/com/android/fontlab/BackgroundPicker.java
deleted file mode 100644
index e23ac82..0000000
--- a/apps/FontLab/src/com/android/fontlab/BackgroundPicker.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.fontlab;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import android.app.ListActivity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.ListView;
-import android.widget.SimpleAdapter;
-
-
-public abstract class BackgroundPicker extends ListActivity 
-{
-    
-    public void onCreate(Bundle icicle) 
-    {
-        super.onCreate(icicle);
-
-        setListAdapter(new SimpleAdapter(this,
-                getData(),
-                android.R.layout.simple_list_item_1,
-                new String[] {"title"},
-                new int[] {android.R.id.text1}));
-    }
-    
-    protected List getData()
-    {
-        List myData = new ArrayList<Bundle>();
-        addItem(myData, "Solid White", 0, 0xFFFFFFFF, 0xFF000000);
-        addItem(myData, "Solid Light Gray", 0, 0xFFBFBFBF, 0xFF000000);
-        addItem(myData, "Solid Dark Gray", 0, 0xFF404040, 0xFFFFFFFF);
-        addItem(myData, "Solid Black", 0, 0xFF000000, 0xFFFFFFFF);
-        addItem(myData, "Solid Blue", 0, 0xFF1a387a, 0xFFFFFFFF);
-        addItem(myData, "Textured White", 0, 0, 0xFF000000);
-        // addItem(myData, "Textured Blue", android.R.drawable.screen_background_blue, 0, 0xFFFFFFFF);
-
-        return myData;
-    }
-    
-    protected void addItem(List<Bundle> data, String name, int textureRes, int bgColor, int textColor)
-    {
-        Bundle temp = new Bundle();
-        temp.putString("title", name);
-        if (textureRes != 0) {
-            temp.putInt("texture", textureRes);
-        }
-        temp.putInt("bgcolor", bgColor);
-        temp.putInt("text", textColor);
-        data.add(temp);
-    }
-
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        Bundle map = (Bundle) l.getItemAtPosition(position);
-        setResult(RESULT_OK, (new Intent()).putExtras(map));
-        finish();
-    }
-  
-}
diff --git a/apps/FontLab/src/com/android/fontlab/FontLab.java b/apps/FontLab/src/com/android/fontlab/FontLab.java
deleted file mode 100644
index 27f2d4c..0000000
--- a/apps/FontLab/src/com/android/fontlab/FontLab.java
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.fontlab;
-
-import java.util.Map;
-
-import android.app.Activity;
-import android.graphics.Color;
-import android.graphics.Paint;
-import android.graphics.Typeface;
-import android.graphics.drawable.PaintDrawable;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.TextView;
-
-class FontLab extends Activity
-{
-    private static final int MIN_SIZE = 1;
-    private static final int MAX_SIZE = 60;
-    
-    private static final float SCALE_X_RANGE = 20;
-    private static final int MAX_SCALE_X = 20;
-    private static final int MIN_SCALE_X = -19;   // -20 would make zero-scale
-
-    private static final String[] sText = {
-        "Applications Contacts Maps Google Browser Text messages Address book"
-        + " Development Earth Quake Settings Voicemail Zoolander. Four score"
-        + " and seven years ago our fathers brought forth on this continent, a"
-        + " new nation, conceived in Liberty, and dedicated to the proposition"
-        + " that all men are created equal. Now we are engaged in a great civil"
-        + " war, testing whether that nation, or any nation so conceived and so"
-        + " dedicated, can long endure. We are met on a great battle-field of"
-        + " that war. We have come to dedicate a portion of that field, as a"
-        + " final resting place for those who here gave their lives that that"
-        + " nation might live. It is altogether fitting and proper that we"
-        + " should do this. But, in a larger sense, we can not dedicate - we"
-        + " can not consecrate - we can not hallow - this ground. The brave"
-        + " men, living and dead, who struggled here, have consecrated it, far"
-        + " above our poor power to add or detract. The world will little note,"
-        + " nor long remember what we say here, but it can never forget what"
-        + " they did here. It is for us the living, rather, to be dedicated"
-        + " here to the unfinished work which they who fought here have thus"
-        + " far so nobly advanced. It is rather for us to be here dedicated to"
-        + " the great task remaining before us - that from these honored dead"
-        + " we take increased devotion to that cause for which they gave the"
-        + " last full measure of devotion - that we here highly resolve that"
-        + " these dead shall not have died in vain - that this nation, under"
-        + " God, shall have a new birth of freedom - and that government of the"
-        + " people, by the people, for the people, shall not perish from the"
-        + " earth."
-        ,
-        "A Spanish doctor on Tuesday stood by his opinion that Fidel Castro is recovering from stomach surgery despite a newspaper report stating the Cuban leader is in a serious condition after a number of failed operations."
-        + " When Senator Wayne Allard, Republican of Colorado, announced Monday that he would not seek re-election, the uphill battle for his party to reclaim the Senate in 2008 became an even steeper climb."
-        + " Naomi Campbell was today sentenced to five days' community service and ordered to attend an anger management course after she admitted throwing a mobile phone at her maid."
-        ,
-        "ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz 0123456789 !@#$%^&*()-_=+[]\\{}|;':\",./<>?"
-        ,
-        "HaH HbH HcH HdH HeH HfH HgH HhH HiH HjH HkH HlH HmH HnH HoH HpH HqH HrH HsH HtH HuH HvH HwH HxH HyH HzH"
-        + "HAH HBH HCH HDH HEH HFH HGH HHH HIH HJH HKH HLH HMH HNH HOH HPH HQH HRH HSH HTH HUH HVH HWH HXH HYH HZH"
-    };
-    
-    private void updateText() {
-        mTextIndex %= sText.length;
-        String s = sText[mTextIndex];
-        mColumn1.setText(s);
-        mColumn2.setText(s);
-    }
-    
-    public FontLab() {}
-
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.font_lab);
-        
-        mColumn1 = (TextView)findViewById(R.id.column1);
-        mColumn2 = (TextView)findViewById(R.id.column2);
-        mContentView = findViewById(R.id.content);
-
-        
-        mColumn1.setTextSize(mFontSize);
-        mColumn2.setTextSize(mFontSize);
-        
-        mColumn1.setTextColor(Color.BLACK);
-        mColumn1.setBackgroundDrawable(new PaintDrawable(Color.WHITE));
-        mColumn2.setTextColor(Color.WHITE);
-        mColumn2.setBackgroundDrawable(new PaintDrawable(Color.BLACK));
-        
-        refreshFont();
-        updateTitle();
-        updateText();
-        
-        setDefaultKeyMode(Activity.DEFAULT_KEYS_SHORTCUT);
-    }
-    
-    private void updateTitle() {
-        Typeface tf = mColumn1.getTypeface();
-        String title = " ps=" + mFontSize + " scaleX="
-                    + (1 + mTextScaleXDelta/SCALE_X_RANGE)
-                    + " gamma=" + (mGamma/20.f)
-                    + " " + sTypefaceName[mFontIndex]
-                    + " " + sStyleName[tf.getStyle()]
-                    ;
-        setTitle(title);
-    }
-    
-    /** Called when it is time to initialize the activity state. */
-    protected void onRestoreInstanceState(Bundle state) {
-        super.onRestoreInstanceState(state);
-    }
-
-    protected void onResume() {
-        super.onResume();
-    }
-    
-    private static final String sStyleName[] = {
-        "Regular", "Bold", "Italic", "Bold Italic"
-    };
-    private static final String sTypefaceName[] = {
-        "Droid Sans",
-        "Droid Serif",
-        "Droid Mono"
-    };
-    private static final Typeface sTypeface[] = {
-        Typeface.SANS_SERIF,
-        Typeface.SERIF,
-        Typeface.MONOSPACE
-    };
-    private static final int FONT_INDEX_SANS = 0;   // index into sTypeface
-    private static final int FONT_INDEX_SERIF = 1;  // index into sTypeface
-    private static final int FONT_INDEX_MONO = 2;   // index into sTypeface
-    
-    private static boolean canSupportStyle(Typeface tf, int styleBits) {
-        tf = Typeface.create(tf, styleBits);
-        return (tf.getStyle() & styleBits) == styleBits;
-    }
-
-    private void refreshFont() {
-        Typeface tf = Typeface.create(sTypeface[mFontIndex], mFontStyle);
-        mColumn1.setTypeface(tf);
-        mColumn2.setTypeface(tf);
-        updateTitle();
-    }
-    
-    private MenuItem.OnMenuItemClickListener mFontClickListener = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            mFontIndex = item.getItemId();
-            refreshFont();
-            return true;
-        }
-    };
-    
-    private void addFontMenu(Menu menu, int index) {
-        MenuItem item = menu.add(0, index, 0, sTypefaceName[index]);
-        item.setCheckable(true);
-        item.setOnMenuItemClickListener(mFontClickListener);
-        item.setChecked(index == mFontIndex);
-    }
-    
-    private MenuItem.OnMenuItemClickListener mStyleClickListener = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            mFontStyle = mFontStyle ^ item.getItemId();
-            refreshFont();
-            return true;
-        }
-    };
-    
-    private void addStyleMenu(Menu menu, int style, char shortCut) {
-        MenuItem item = menu.add(0, style, 0, (style == Typeface.BOLD) ? "Bold" : "Italic");
-        item.setCheckable(true);
-        item.setOnMenuItemClickListener(mStyleClickListener);
-        item.setChecked((mFontStyle & style) != 0);
-
-        item.setVisible(canSupportStyle(sTypeface[mFontIndex], style));
-        if (shortCut != 0) {
-            item.setAlphabeticShortcut(shortCut);
-        }
-    }
-    
-    private MenuItem.OnMenuItemClickListener mFlagClickListener = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            int mask = item.getItemId();
-            mColumn1.setPaintFlags(mColumn1.getPaintFlags() ^ mask);
-            mColumn2.setPaintFlags(mColumn2.getPaintFlags() ^ mask);
-            return true;
-        }
-    };
-    
-    private
-    void addFlagMenu(Menu menu, int paintFlag, String label, char shortCut) {
-        MenuItem item = menu.add(0, paintFlag, 0, label);
-        item.setCheckable(true);
-        item.setOnMenuItemClickListener(mFlagClickListener);
-        item.setChecked((mColumn1.getPaintFlags() & paintFlag) != 0);
-        if (shortCut != 0) {
-            item.setAlphabeticShortcut(shortCut);
-        }
-    }
-    
-    private static void addListenerMenu(MenuItem item,
-                                        MenuItem.OnMenuItemClickListener listener,
-                                        char keyChar) {
-        item.setOnMenuItemClickListener(listener);
-        if (keyChar != '\0') {
-            item.setAlphabeticShortcut(keyChar);
-        }
-    }
-    
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-        return true;
-    }
-    
-    @Override public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-        menu.clear();
-
-        addFontMenu(menu, FONT_INDEX_SANS);
-        addFontMenu(menu, FONT_INDEX_SERIF);
-        addFontMenu(menu, FONT_INDEX_MONO);
-        addStyleMenu(menu, Typeface.BOLD, 'b');
-        addStyleMenu(menu, Typeface.ITALIC, 'i');
-        addFlagMenu(menu, Paint.DEV_KERN_TEXT_FLAG, "DevKern", 'k');
-        menu.add(0, 0, 0, "Text").setOnMenuItemClickListener(mTextCallback).setAlphabeticShortcut('t');
-        
-        return true;
-    }
-
-    protected void onActivityResult(int requestCode, int resultCode,
-                                    String data, Map extras) {
-        if (resultCode == RESULT_OK) {
-            switch (requestCode) {
-            case BACKGROUND_PICKED:
-                {
-                    int color = ((Integer)extras.get("text")).intValue();
-                    mColumn1.setTextColor(color);
-                    mColumn2.setTextColor(color);
-                    
-                    int colorTranslucent = (color & 0x00FFFFFF) + 0x77000000;
-                    
-                    setTitleColor(color);
-                    
-                    Integer texture = (Integer)extras.get("texture");
-                    if (texture != null) {
-                        mContentView.setBackgroundResource(texture.intValue());
-                    } else {
-                        color = ((Integer)extras.get("bgcolor")).intValue();
-                        mContentView.setBackgroundColor(color);
-                    }
-                }
-                break;   
-            }
-        }
-    }
-
-    @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-        int size = mFontSize;
-        int scaleX = mTextScaleXDelta;
-        
-        switch (keyCode) {
-            case KeyEvent.KEYCODE_DPAD_DOWN:
-                size -= 1;
-                break;
-            case KeyEvent.KEYCODE_DPAD_UP:
-                size += 1;
-                break;
-            case KeyEvent.KEYCODE_DPAD_RIGHT:
-                scaleX += 1;
-                break;
-            case KeyEvent.KEYCODE_DPAD_LEFT:
-                scaleX -= 1;
-                break;
-                /*
-            case KeyEvent.KEYCODE_U:
-                changeGamma(1);
-                return true;
-            case KeyEvent.KEYCODE_D:
-                changeGamma(-1);
-                return true;
-                 */
-            default:
-                return super.onKeyDown(keyCode, event);
-        }
-        
-        size = Math.min(MAX_SIZE, Math.max(MIN_SIZE, size));
-        if (size != mFontSize) {
-            mFontSize = size;
-            mColumn1.setTextSize(mFontSize);
-            mColumn2.setTextSize(mFontSize);
-            updateTitle();
-            return true;
-        }
-        
-        scaleX = Math.min(MAX_SCALE_X, Math.max(MIN_SCALE_X, scaleX));
-        if (scaleX != mTextScaleXDelta) {
-            mTextScaleXDelta = scaleX;
-            mColumn1.setTextScaleX(1 + scaleX / SCALE_X_RANGE);
-            mColumn2.setTextScaleX(1 + scaleX / SCALE_X_RANGE);
-            updateTitle();
-            return true;
-        }
-
-        return super.onKeyDown(keyCode, event);
-    }
-    
-    private int mGamma = 28;    // current default is 1.4 (* 20)
-    private void changeGamma(int delta) {
-        int gamma = Math.min(100, Math.max(1, mGamma + delta));
-        if (gamma != mGamma) {
-            mGamma = gamma;
-            updateTitle();
-//            Paint.setTextGamma(mGamma / 20.f);
-            mContentView.invalidate();
-            android.util.Log.d("skia", "setTextGamma " + mGamma);
-        }
-    }
-    
-    private void setFont(TextView t, TextView f, Map extras) {
-        int style = ((Integer)extras.get("style")).intValue();
-        String font = (String)extras.get("font");
-        t.setTypeface(Typeface.create(font, style));
-        
-        f.setText((String)extras.get("title"));
-    }
-
-    MenuItem.OnMenuItemClickListener mTextCallback = new MenuItem.OnMenuItemClickListener() {
-        public boolean onMenuItemClick(MenuItem item) {
-            mTextIndex += 1;
-            updateText();
-            return true;
-        }
-    };
-
-    private static final int BACKGROUND_PICKED = 1;
-    
-    private TextView mColumn1;
-    private TextView mColumn2;
-    private View mContentView;
-    private int mFontIndex = FONT_INDEX_SANS;
-    private int mFontStyle = Typeface.NORMAL;
-    private int mFontSize = 18;
-    private int mTextIndex;
-    private int mTextScaleXDelta;
-}
-
diff --git a/apps/FontLab/src/com/android/fontlab/FontPicker.java b/apps/FontLab/src/com/android/fontlab/FontPicker.java
deleted file mode 100644
index 7f4fdb6..0000000
--- a/apps/FontLab/src/com/android/fontlab/FontPicker.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.fontlab;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import android.app.ListActivity;
-import android.content.Intent;
-import android.graphics.Typeface;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.ListView;
-import android.widget.SimpleAdapter;
-
-
-public abstract class FontPicker extends ListActivity 
-{
-    
-    public void onCreate(Bundle icicle) 
-    {
-        super.onCreate(icicle);
-
-        setListAdapter(new SimpleAdapter(this,
-                getData(),
-                android.R.layout.simple_list_item_1,
-                new String[] {"title"},
-                new int[] {android.R.id.text1}));
-    }
-    
-    protected List getData()
-    {
-        List myData = new ArrayList<Bundle>(7);
-        addItem(myData, "Sans",                 "sans-serif",   Typeface.NORMAL);
-        addItem(myData, "Sans Bold",            "sans-serif",   Typeface.BOLD);
-        addItem(myData, "Serif",                "serif",        Typeface.NORMAL);
-        addItem(myData, "Serif Bold",           "serif",        Typeface.BOLD);
-        addItem(myData, "Serif Italic",         "serif",        Typeface.ITALIC);
-        addItem(myData, "Serif Bold Italic",    "serif",        Typeface.BOLD_ITALIC);
-        addItem(myData, "Mono",                 "monospace",    Typeface.NORMAL);
-        return myData;
-    }
-    
-    protected void addItem(List<Bundle> data, String name, String fontName, int style)
-    {
-        Bundle temp = new Bundle();
-        temp.putString("title", name);
-        temp.putString("font", fontName);
-        temp.putInt("style", style);
-        data.add(temp);
-    }
-
-    protected void onListItemClick(ListView l, View v, int position, long id)
-    {
-        Bundle map = (Bundle) l.getItemAtPosition(position);
-        setResult(RESULT_OK, (new Intent()).putExtras(map));
-        finish();
-    }
-  
-}
diff --git a/apps/OBJViewer/Android.mk b/apps/OBJViewer/Android.mk
deleted file mode 100644
index 3d5786c..0000000
--- a/apps/OBJViewer/Android.mk
+++ /dev/null
@@ -1,13 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := OBJViewer
-
-LOCAL_MODULE_TAGS := tests
-
-# currently disabled because of API changes. won't be fixed for 1.0
-#include $(BUILD_PACKAGE)
diff --git a/apps/OBJViewer/AndroidManifest.xml b/apps/OBJViewer/AndroidManifest.xml
deleted file mode 100644
index b1c39b8..0000000
--- a/apps/OBJViewer/AndroidManifest.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.objviewer">
-    <application>
-        <activity android:name="OBJViewer" android:label="3D .obj File Viewer">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest>
diff --git a/apps/OBJViewer/MODULE_LICENSE_APACHE2 b/apps/OBJViewer/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/apps/OBJViewer/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/apps/OBJViewer/NOTICE b/apps/OBJViewer/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/apps/OBJViewer/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/apps/OBJViewer/assets/al.gles b/apps/OBJViewer/assets/al.gles
deleted file mode 100644
index 086de08..0000000
--- a/apps/OBJViewer/assets/al.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/apple.gles b/apps/OBJViewer/assets/apple.gles
deleted file mode 100644
index 41860a0..0000000
--- a/apps/OBJViewer/assets/apple.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/dolphins.gles b/apps/OBJViewer/assets/dolphins.gles
deleted file mode 100644
index 9066962..0000000
--- a/apps/OBJViewer/assets/dolphins.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/earth.raw b/apps/OBJViewer/assets/earth.raw
deleted file mode 100644
index f884e75..0000000
--- a/apps/OBJViewer/assets/earth.raw
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/f16.gles b/apps/OBJViewer/assets/f16.gles
deleted file mode 100644
index 51f3ef3..0000000
--- a/apps/OBJViewer/assets/f16.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/flowers.gles b/apps/OBJViewer/assets/flowers.gles
deleted file mode 100644
index 7726428..0000000
--- a/apps/OBJViewer/assets/flowers.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/porsche.gles b/apps/OBJViewer/assets/porsche.gles
deleted file mode 100644
index 383ed77..0000000
--- a/apps/OBJViewer/assets/porsche.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/rosevase.gles b/apps/OBJViewer/assets/rosevase.gles
deleted file mode 100644
index e83fe07..0000000
--- a/apps/OBJViewer/assets/rosevase.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/shuttle.gles b/apps/OBJViewer/assets/shuttle.gles
deleted file mode 100644
index e12e3e0..0000000
--- a/apps/OBJViewer/assets/shuttle.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/skin.raw b/apps/OBJViewer/assets/skin.raw
deleted file mode 100644
index 2c0f9dd..0000000
--- a/apps/OBJViewer/assets/skin.raw
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/soccerball.gles b/apps/OBJViewer/assets/soccerball.gles
deleted file mode 100644
index 08a7f84..0000000
--- a/apps/OBJViewer/assets/soccerball.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/stem_color.raw b/apps/OBJViewer/assets/stem_color.raw
deleted file mode 100644
index 1aada90..0000000
--- a/apps/OBJViewer/assets/stem_color.raw
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/assets/world.gles b/apps/OBJViewer/assets/world.gles
deleted file mode 100644
index 654692c..0000000
--- a/apps/OBJViewer/assets/world.gles
+++ /dev/null
Binary files differ
diff --git a/apps/OBJViewer/com/android/objviewer/OBJViewer.java b/apps/OBJViewer/com/android/objviewer/OBJViewer.java
deleted file mode 100644
index 3929a87..0000000
--- a/apps/OBJViewer/com/android/objviewer/OBJViewer.java
+++ /dev/null
@@ -1,334 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.objviewer;
-
-import android.app.Activity;
-import android.content.AssetManager;
-import android.content.Context;
-import android.graphics.Canvas;
-import android.graphics.OpenGLContext;
-import android.graphics.Paint;
-import android.graphics.glutils.GLView;
-import android.graphics.glutils.Object3D;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.os.SystemClock;
-import android.view.KeyEvent;
-import android.view.View;
-import android.view.Window;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.microedition.khronos.opengles.GL10;
-
-class OBJView extends View {
-
-    // Mathematical constants
-    private static final float PI = (float)Math.PI;
-    private static final float TWO_PI = (float)(2.0*Math.PI);
-    private static final float PI_OVER_TWO = (float)(Math.PI/2.0);
-
-    // Ambient light to apply
-    // private float[] lightModelAmbient = { 0.0f, 0.0f, 0.0f, 1.0f };
-    private float[] lightModelAmbient = { 0.2f, 0.2f, 0.2f, 1.0f };
-
-    // Paint object for drawing the FPS display
-    private Paint paint = new Paint();
-
-    // GLView object to manage drawing    
-    private GLView glView = new GLView();
-
-    private boolean         initialized = false;
-
-    private OpenGLContext   mGLContext;
-
-    // Next time to draw
-    private long            mNextTime;
-
-    // View transformation controlled by UI
-    private float           mRotAngle = 0.0f;
-    private float           mRotVelocity = 1.0f;
-    private float           mTiltAngle = 0.0f;
-
-    // Object bounds
-    private float           mCenterX = 0.0f;
-    private float           mCenterY = 0.0f;
-    private float           mCenterZ = 0.0f;
-    private float           mScale   = 1.0f;
-
-    // Light direction
-    private float[] mLightDir = { 0.0f, 0.0f, 1.0f, 0.0f };
-
-    public OBJView(Context context) {
-        super(context);
-
-        mGLContext = new OpenGLContext(OpenGLContext.DEPTH_BUFFER);
-
-        Message msg = mHandler.obtainMessage(INVALIDATE);
-        mNextTime = SystemClock.uptimeMillis() + 100;
-        mHandler.sendMessageAtTime(msg, mNextTime);
-
-        requestFocus();
-    }
-
-    public void reset() {
-        initialized = false;
-
-        mRotAngle = 0.0f;
-        mRotVelocity = 1.0f;
-        mTiltAngle = 0.0f;
-
-        mCenterX = 0.0f;
-        mCenterY = 0.0f;
-        mCenterZ = 0.0f;
-        mScale   = 1.0f;
-    }
-
-    public boolean onKeyDown(int keyCode, KeyEvent event) {
-        // Hand the key to the GLView object first
-        if (glView.processKey(keyCode)) {
-            return true;
-        }
-
-        switch (keyCode) {
-            case KeyEvent.KEYCODE_DPAD_LEFT:
-                mRotVelocity -= 1.0f;
-                break;
-
-            case KeyEvent.KEYCODE_DPAD_RIGHT:
-                mRotVelocity += 1.0f;
-                break;
-
-            case KeyEvent.KEYCODE_DPAD_CENTER:
-                mRotVelocity = 0.0f;
-                break;
-
-            case KeyEvent.KEYCODE_DPAD_UP:	
-                mTiltAngle -= 360.0f/24.0f;
-                break;
-
-            case KeyEvent.KEYCODE_DPAD_DOWN:
-                mTiltAngle += 360.0f/24.0f;
-                break;
-
-            case KeyEvent.KEYCODE_U:
-                OBJViewer.nextObject();
-                reset();
-                break;
-
-            default:
-                return super.onKeyDown(keyCode, event);
-        }
-
-        return true;
-    }
-
-    private void init(GL10 gl) {
-        glView.reset();
-
-        paint.setColor(0xffffffff);
-
-        gl.glEnable(gl.GL_DEPTH_TEST);
-
-        gl.glDisable(gl.GL_SCISSOR_TEST);
-
-        // Some quality settings...
-        gl.glEnable(gl.GL_DITHER);
-
-        gl.glShadeModel(gl.GL_SMOOTH);
-
-        gl.glEnable(gl.GL_CULL_FACE);
-        gl.glFrontFace(gl.GL_CCW);
-
-        gl.glClearColor(0, 0, 0, 1);
-
-        gl.glLightModelf(gl.GL_LIGHT_MODEL_TWO_SIDE, 0);
-        gl.glLightModelfv(gl.GL_LIGHT_MODEL_AMBIENT, lightModelAmbient, 0);
-    }
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-        GL10 gl = (GL10)mGLContext.getGL();
-        mGLContext.makeCurrent(this);
-
-        if (!initialized) {
-            init(gl);
-            initialized = true;
-
-            // Load the object
-            Object3D obj = OBJViewer.getObject();
-
-            // Compute a scale factor and translation to bring it
-            // into view
-            mCenterX = (obj.getBoundsMinX() + obj.getBoundsMaxX())/2.0f;
-            mCenterY = (obj.getBoundsMinY() + obj.getBoundsMaxY())/2.0f;
-            mCenterZ = (obj.getBoundsMinZ() + obj.getBoundsMaxZ())/2.0f;
-            float spanX = obj.getBoundsMaxX() - obj.getBoundsMinX();
-            float spanY = obj.getBoundsMaxY() - obj.getBoundsMinY();
-            float spanZ = obj.getBoundsMaxZ() - obj.getBoundsMinZ();
-            float maxSpan = Math.max(spanX, spanY);
-            maxSpan = Math.max(maxSpan, spanZ);
-            mScale = 2.0f/maxSpan;
-        }
-
-        int w = getWidth();
-        int h = getHeight();
-        gl.glViewport(0, 0, w, h);
-
-        float ratio = (float)w/h;
-        glView.setAspectRatio(ratio);
-
-        // Clear buffers
-        gl.glClear(gl.GL_COLOR_BUFFER_BIT | gl.GL_DEPTH_BUFFER_BIT);
-
-        // Set up the projection and view
-        glView.setProjection(gl);
-        glView.setView(gl);
-
-        // Set up lighting
-        gl.glMatrixMode(gl.GL_MODELVIEW);
-        gl.glEnable(gl.GL_LIGHTING);
-        gl.glEnable(gl.GL_LIGHT0);
-        gl.glLightfv(gl.GL_LIGHT0, gl.GL_POSITION, mLightDir, 0);
-        glView.setLights(gl, gl.GL_LIGHT0);
-
-        // Rotate the viewpoint around the model
-        gl.glRotatef(mTiltAngle, 1, 0, 0);
-        gl.glRotatef(mRotAngle, 0, 1, 0);
-
-        // Scale object to fit in [-1, 1]
-        gl.glScalef(mScale, mScale, mScale);
-
-        // Center the object at the origin
-        gl.glTranslatef(-mCenterX, -mCenterY, -mCenterZ);
-
-        // Increment the rotation angle
-        mRotAngle += mRotVelocity;
-        if (mRotAngle < 0.0f) {
-            mRotAngle += 360.0f;
-        }
-        if (mRotAngle > 360.0f) {
-            mRotAngle -= 360.0f;
-        }
-
-        // Draw the object
-        Object3D object = OBJViewer.getObject();
-        object.draw(gl);
-
-        // Allow GL to complete
-        mGLContext.post();
-
-        // Draw GLView messages and/or FPS
-        glView.showMessages(canvas);
-        glView.setNumTriangles(object.getNumTriangles());
-        glView.showStatistics(canvas, w);
-    }
-
-    private static final int INVALIDATE = 1;
-
-    private final Handler mHandler = new Handler() {
-        public void handleMessage(Message msg) {
-            if (msg.what == INVALIDATE) {
-                invalidate();
-                msg = obtainMessage(INVALIDATE);
-                long current = SystemClock.uptimeMillis();
-                if (mNextTime < current) {
-                    mNextTime = current + 20;
-                }
-                sendMessageAtTime(msg, mNextTime);
-                mNextTime += 20;
-            }
-        }
-    };
-}
-
-
-public class OBJViewer extends Activity {
-
-    private static Object3D object = null;
-
-    private static List<String> objectFiles = new ArrayList<String>();
-    private static int objectIndex = 0;
-
-    static {
-        objectFiles.add("world.gles");
-        objectFiles.add("al.gles");
-        objectFiles.add("apple.gles");
-        objectFiles.add("dolphins.gles");
-        objectFiles.add("f16.gles");
-        objectFiles.add("flowers.gles");
-        objectFiles.add("porsche.gles");
-        objectFiles.add("rosevase.gles");
-        objectFiles.add("shuttle.gles");
-        objectFiles.add("soccerball.gles");
-    }
-
-    private int readInt16(InputStream is) throws Exception {
-        return is.read() | (is.read() << 8);
-    }
-
-    public static Object3D getObject() {
-        return object;
-    }
-
-    public static void nextObject() {
-        try {
-            objectIndex = (objectIndex + 1) % objectFiles.size();
-            object.load(objectFiles.get(objectIndex));
-        } catch (IOException e) {
-            throw new RuntimeException(e);
-        }
-    }
-
-    @Override protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        // Get rid of the title
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-        // Make sure we're not drawing a background
-        setTheme(R.style.Theme);
-        setContentView(new OBJView((Context)getApplication()));
-
-        if (object == null) {
-            try {
-                final AssetManager am = getAssets();
-                this.object = new Object3D() {
-                    public InputStream readFile(String filename)
-                    throws IOException {
-                        return am.open(filename);
-
-                    }
-                };
-                object.load(objectFiles.get(0));
-            } catch (Exception e) {
-                throw new RuntimeException(e);
-            }
-        }
-    }
-
-    @Override protected void onResume() {
-        super.onResume();
-    }
-
-    @Override protected void onStop() {
-        super.onStop();
-    }
-}
diff --git a/apps/OBJViewer/res/values/styles.xml b/apps/OBJViewer/res/values/styles.xml
deleted file mode 100644
index 62f4684..0000000
--- a/apps/OBJViewer/res/values/styles.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Calendar/assets/res/any/styles.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-<resources>
-    <style name="Theme" parent="android:Theme">
-        <item name="android:windowBackground">@null</item>
-    </style>
-</resources>
diff --git a/apps/SdkSetup/Android.mk b/apps/SdkSetup/Android.mk
deleted file mode 100644
index b89baaf..0000000
--- a/apps/SdkSetup/Android.mk
+++ /dev/null
@@ -1,11 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := foo
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := SdkSetup
-LOCAL_CERTIFICATE := platform
-
-include $(BUILD_PACKAGE)
diff --git a/apps/SdkSetup/AndroidManifest.xml b/apps/SdkSetup/AndroidManifest.xml
deleted file mode 100644
index 966eeb1..0000000
--- a/apps/SdkSetup/AndroidManifest.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- Copyright (C) 2008 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
-      http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-        package="com.android.sdksetup">
-
-    <!-- For miscellaneous settings -->
-    <uses-permission android:name="android.permission.WRITE_SETTINGS" />
-    <uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS" />
-
-    <application>
-        <activity android:name="DefaultActivity"
-                android:excludeFromRecents="true">
-            <intent-filter android:priority="1">
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.HOME" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest>
-
diff --git a/apps/SdkSetup/src/com/android/sdksetup/DefaultActivity.java b/apps/SdkSetup/src/com/android/sdksetup/DefaultActivity.java
deleted file mode 100644
index db6385c..0000000
--- a/apps/SdkSetup/src/com/android/sdksetup/DefaultActivity.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdksetup;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.pm.PackageManager;
-import android.location.LocationManager;
-import android.os.Bundle;
-import android.provider.Settings;
-
-/**
- * Entry point for SDK SetupWizard.
- *
- */
-public class DefaultActivity extends Activity {
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        
-        // Add a persistent setting to allow other apps to know the device has been provisioned.
-        Settings.Secure.putInt(getContentResolver(), Settings.Secure.DEVICE_PROVISIONED, 1);
-
-        // Enable the GPS.
-        // Not needed since this SDK will contain the Settings app.
-        LocationManager locationManager = (LocationManager)getSystemService(LOCATION_SERVICE);
-        Settings.Secure.putString(getContentResolver(), Settings.Secure.LOCATION_PROVIDERS_ALLOWED, LocationManager.GPS_PROVIDER);
-        locationManager.updateProviders();
-        
-        // enable install from non market
-        Settings.Secure.putInt(getContentResolver(), Settings.Secure.INSTALL_NON_MARKET_APPS, 1);
-
-        // remove this activity from the package manager.
-        PackageManager pm = getPackageManager();
-        ComponentName name = new ComponentName(this, DefaultActivity.class);
-        pm.setComponentEnabledSetting(name, PackageManager.COMPONENT_ENABLED_STATE_DISABLED, 0);
-
-        // terminate the activity.
-        finish();
-    }
-}
-
diff --git a/apps/SpareParts/Android.mk b/apps/SpareParts/Android.mk
deleted file mode 100644
index ccf6c6d..0000000
--- a/apps/SpareParts/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := eng development
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := SpareParts
-
-include $(BUILD_PACKAGE)
diff --git a/apps/SpareParts/AndroidManifest.xml b/apps/SpareParts/AndroidManifest.xml
deleted file mode 100644
index 85de7a4..0000000
--- a/apps/SpareParts/AndroidManifest.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-        package="com.android.spare_parts">
-    <uses-permission android:name="android.permission.SET_ANIMATION_SCALE" />
-    <uses-permission android:name="android.permission.CHANGE_CONFIGURATION" />
-    <uses-permission android:name="android.permission.WRITE_SETTINGS" />
-    
-    <application android:label="@string/app_label"
-            android:icon="@drawable/app_icon">
-
-        <activity android:name="SpareParts">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-
-    </application>
-</manifest>
diff --git a/apps/SpareParts/res/drawable/app_icon.png b/apps/SpareParts/res/drawable/app_icon.png
deleted file mode 100644
index cb40a19..0000000
--- a/apps/SpareParts/res/drawable/app_icon.png
+++ /dev/null
Binary files differ
diff --git a/apps/SpareParts/res/layout/spare_parts.xml b/apps/SpareParts/res/layout/spare_parts.xml
deleted file mode 100644
index f39298b..0000000
--- a/apps/SpareParts/res/layout/spare_parts.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Settings/assets/res/any/layout/keyboard_version.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <RelativeLayout 
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent">
-
-        <Spinner android:id="@+id/window_animation_scale"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_alignParentLeft="true">
-        </Spinner>
-
-        <Spinner android:id="@+id/transition_animation_scale"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_below="@id/window_animation_scale"
-            android:layout_alignParentLeft="true">
-        </Spinner>
-
-        <CheckBox android:id="@+id/show_maps_compass"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_below="@+id/transition_animation_scale"
-            android:layout_alignParentLeft="true"
-            android:text="@string/development_settings_show_maps_compass_text" />
-            
-    </RelativeLayout>
-
-</ScrollView>
-
diff --git a/apps/SpareParts/res/values/arrays.xml b/apps/SpareParts/res/values/arrays.xml
deleted file mode 100644
index e6026da..0000000
--- a/apps/SpareParts/res/values/arrays.xml
+++ /dev/null
@@ -1,68 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- -->
-
-<resources>
-    <string-array name="entries_animations">
-        <item>Off</item>
-        <item>Fast</item>
-        <item>Normal</item>
-        <item>Slow</item>
-        <item>Very Slow</item>
-    </string-array>
-
-    <string-array name="entryvalues_animations">
-        <item>0.0</item>
-        <item>0.5</item>
-        <item>1.0</item>
-        <item>1.5</item>
-        <item>2.0</item>
-    </string-array>
-    
-    <string-array name="entries_font_size">
-        <item>Extremely Small</item>
-        <item>Extra Small</item>
-        <item>Small</item>
-        <item>Normal</item>
-        <item>Large</item>
-        <item>Extra Large</item>
-        <item>Extremely Large</item>
-    </string-array>
-
-    <string-array name="entryvalues_font_size">
-        <item>0.70</item>
-        <item>0.85</item>
-        <item>0.95</item>
-        <item>1.0</item>
-        <item>1.05</item>
-        <item>1.15</item>
-        <item>1.30</item>
-    </string-array>
-    
-    <string-array name="entries_end_button">
-        <item>Nothing</item>
-        <item>Go to home</item>
-        <item>Go to sleep</item>
-        <item>Home, then sleep</item>
-    </string-array>
-    
-    <string-array name="entryvalues_end_button">
-        <item>0</item>
-        <item>1</item>
-        <item>2</item>
-        <item>3</item>
-    </string-array>
-</resources>
diff --git a/apps/SpareParts/res/values/strings.xml b/apps/SpareParts/res/values/strings.xml
deleted file mode 100644
index 42234c1..0000000
--- a/apps/SpareParts/res/values/strings.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/assets/res/any/strings.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-<resources>
-    <string name="app_label">Spare Parts</string>
-
-    <string name="general_title">General</string>
-    
-    <string name="title_window_animations">Window animations</string>
-    <string name="summary_window_animations">Speed of animations in individual windows</string>
-    <string name="dialog_title_window_animations">Select window speed</string>
-    
-    <string name="title_transition_animations">Transition animations</string>
-    <string name="summary_transition_animations">Speed of animations moving between screens</string>
-    <string name="dialog_title_transition_animations">Select transition speed</string>
-    
-    <string name="title_fancy_ime_animations">Fancy input animations</string>
-    <string name="summary_on_fancy_ime_animations">Use fancier animations for input method windows</string>
-    <string name="summary_off_fancy_ime_animations">Use normal animations for input method windows</string>
-    
-    <string name="title_haptic_feedback">Haptic feedback</string>
-    <string name="summary_on_haptic_feedback">Use haptic feedback with user interaction</string>
-    <string name="summary_off_haptic_feedback">Use haptic feedback with user interaction</string>
-    
-    <string name="title_font_size">Font size</string>
-    <string name="summary_font_size">Overall size of fonts</string>
-    <string name="dialog_title_font_size">Select font size</string>
-    
-    <string name="title_end_button">End button behavior</string>
-    <string name="summary_end_button">Select End (red) button action</string>
-    <string name="dialog_title_end_button">Select End button</string>
-    
-    <string name="title_accelerometer">Display rotation</string>
-    <string name="summary_on_accelerometer">Display rotates from orientation</string>
-    <string name="summary_off_accelerometer">Display rotates when lid is open</string>
-    
-    <string name="applications_title">Applications</string>
-    
-    <string name="title_maps_compass">Show compass in Maps</string>
-    <string name="summary_on_maps_compass">Compass is displayed in Maps</string>
-    <string name="summary_off_maps_compass">Compass is not displayed in Maps</string>
-    
-    <string name="development_settings_show_maps_compass_text">Show compass in Maps</string>
-</resources>
diff --git a/apps/SpareParts/res/xml/spare_parts.xml b/apps/SpareParts/res/xml/spare_parts.xml
deleted file mode 100644
index 87525c9..0000000
--- a/apps/SpareParts/res/xml/spare_parts.xml
+++ /dev/null
@@ -1,87 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-/*
- * Copyright 2008, The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <PreferenceCategory
-        android:title="@string/general_title">
-        
-        <ListPreference
-                android:key="window_animations"
-                android:title="@string/title_window_animations"
-                android:summary="@string/summary_window_animations"
-                android:entries="@array/entries_animations"
-                android:entryValues="@array/entryvalues_animations"
-                android:dialogTitle="@string/dialog_title_window_animations" />
-                
-        <ListPreference
-                android:key="transition_animations"
-                android:title="@string/title_transition_animations"
-                android:summary="@string/summary_transition_animations"
-                android:entries="@array/entries_animations"
-                android:entryValues="@array/entryvalues_animations"
-                android:dialogTitle="@string/dialog_title_transition_animations" />
-        
-        <CheckBoxPreference 
-            android:key="fancy_ime_animations" 
-            android:title="@string/title_fancy_ime_animations" 
-            android:summaryOn="@string/summary_on_fancy_ime_animations"
-            android:summaryOff="@string/summary_off_fancy_ime_animations"/>
-        
-        <ListPreference
-                android:key="font_size"
-                android:title="@string/title_font_size"
-                android:summary="@string/summary_font_size"
-                android:entries="@array/entries_font_size"
-                android:entryValues="@array/entryvalues_font_size"
-                android:dialogTitle="@string/dialog_title_font_size" />
-        
-        <ListPreference
-                android:key="end_button"
-                android:title="@string/title_end_button"
-                android:summary="@string/summary_end_button"
-                android:entries="@array/entries_end_button"
-                android:entryValues="@array/entryvalues_end_button"
-                android:dialogTitle="@string/dialog_title_end_button" />
-        
-        <CheckBoxPreference 
-            android:key="accelerometer" 
-            android:title="@string/title_accelerometer" 
-            android:summaryOn="@string/summary_on_accelerometer"
-            android:summaryOff="@string/summary_off_accelerometer"/>
-        
-        <CheckBoxPreference 
-            android:key="haptic_feedback" 
-            android:title="@string/title_haptic_feedback" 
-            android:summaryOn="@string/summary_on_haptic_feedback"
-            android:summaryOff="@string/summary_off_haptic_feedback"/>
-        
-    </PreferenceCategory>
-            
-    <PreferenceCategory
-        android:title="@string/applications_title">
-                
-        <CheckBoxPreference 
-            android:key="maps_compass" 
-            android:title="@string/title_maps_compass" 
-            android:summaryOn="@string/summary_on_maps_compass"
-            android:summaryOff="@string/summary_off_maps_compass"/>
-        
-    </PreferenceCategory>
-        
-</PreferenceScreen>
diff --git a/apps/SpareParts/src/com/android/spare_parts/SpareParts.java b/apps/SpareParts/src/com/android/spare_parts/SpareParts.java
deleted file mode 100644
index 0f2347e..0000000
--- a/apps/SpareParts/src/com/android/spare_parts/SpareParts.java
+++ /dev/null
@@ -1,227 +0,0 @@
-/* //device/apps/Settings/src/com/android/settings/Keyguard.java
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
-
-package com.android.spare_parts;
-
-import android.app.ActivityManagerNative;
-import android.content.Context;
-import android.content.SharedPreferences;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.content.res.Configuration;
-import android.os.RemoteException;
-import android.os.ServiceManager;
-import android.preference.CheckBoxPreference;
-import android.preference.ListPreference;
-import android.preference.Preference;
-import android.preference.PreferenceActivity;
-import android.preference.PreferenceScreen;
-import android.provider.Settings;
-import android.provider.Settings.SettingNotFoundException;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.IWindowManager;
-
-public class SpareParts extends PreferenceActivity
-        implements Preference.OnPreferenceChangeListener,
-        SharedPreferences.OnSharedPreferenceChangeListener {
-    private static final String TAG = "SpareParts";
-
-    private static final String WINDOW_ANIMATIONS_PREF = "window_animations";
-    private static final String TRANSITION_ANIMATIONS_PREF = "transition_animations";
-    private static final String FANCY_IME_ANIMATIONS_PREF = "fancy_ime_animations";
-    private static final String HAPTIC_FEEDBACK_PREF = "haptic_feedback";
-    private static final String FONT_SIZE_PREF = "font_size";
-    private static final String END_BUTTON_PREF = "end_button";
-    private static final String ACCELEROMETER_PREF = "accelerometer";
-    private static final String MAPS_COMPASS_PREF = "maps_compass";
-    
-    private final Configuration mCurConfig = new Configuration();
-    
-    private ListPreference mWindowAnimationsPref;
-    private ListPreference mTransitionAnimationsPref;
-    private CheckBoxPreference mFancyImeAnimationsPref;
-    private CheckBoxPreference mHapticFeedbackPref;
-    private ListPreference mFontSizePref;
-    private ListPreference mEndButtonPref;
-    private CheckBoxPreference mAccelerometerPref;
-    private CheckBoxPreference mShowMapsCompassPref;
-    
-    private IWindowManager mWindowManager;
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        addPreferencesFromResource(R.xml.spare_parts);
-
-        PreferenceScreen prefSet = getPreferenceScreen();
-        
-        mWindowAnimationsPref = (ListPreference) prefSet.findPreference(WINDOW_ANIMATIONS_PREF);
-        mWindowAnimationsPref.setOnPreferenceChangeListener(this);
-        mTransitionAnimationsPref = (ListPreference) prefSet.findPreference(TRANSITION_ANIMATIONS_PREF);
-        mTransitionAnimationsPref.setOnPreferenceChangeListener(this);
-        mFancyImeAnimationsPref = (CheckBoxPreference) prefSet.findPreference(FANCY_IME_ANIMATIONS_PREF);
-        mHapticFeedbackPref = (CheckBoxPreference) prefSet.findPreference(HAPTIC_FEEDBACK_PREF);
-        mFontSizePref = (ListPreference) prefSet.findPreference(FONT_SIZE_PREF);
-        mFontSizePref.setOnPreferenceChangeListener(this);
-        mEndButtonPref = (ListPreference) prefSet.findPreference(END_BUTTON_PREF);
-        mEndButtonPref.setOnPreferenceChangeListener(this);
-        mAccelerometerPref = (CheckBoxPreference) prefSet.findPreference(ACCELEROMETER_PREF);
-        mShowMapsCompassPref = (CheckBoxPreference) prefSet.findPreference(MAPS_COMPASS_PREF);
-        
-        mWindowManager = IWindowManager.Stub.asInterface(ServiceManager.getService("window"));
-        
-        getPreferenceScreen().getSharedPreferences().registerOnSharedPreferenceChangeListener(this);
-    }
-
-    private void updateToggles() {
-        try {
-            mFancyImeAnimationsPref.setChecked(Settings.System.getInt(
-                    getContentResolver(), 
-                    Settings.System.FANCY_IME_ANIMATIONS, 0) != 0);
-            mHapticFeedbackPref.setChecked(Settings.System.getInt(
-                    getContentResolver(), 
-                    Settings.System.HAPTIC_FEEDBACK_ENABLED, 0) != 0);
-            mAccelerometerPref.setChecked(Settings.System.getInt(
-                    getContentResolver(), 
-                    Settings.System.ACCELEROMETER_ROTATION, 0) != 0);
-            Context c = createPackageContext("com.google.android.apps.maps", 0);
-            mShowMapsCompassPref.setChecked(c.getSharedPreferences("extra-features", MODE_WORLD_READABLE)
-                .getBoolean("compass", false));
-        } catch (NameNotFoundException e) {
-            Log.w(TAG, "Failed reading maps compass");
-            e.printStackTrace();
-        }
-    }
-    
-    public boolean onPreferenceChange(Preference preference, Object objValue) {
-        if (preference == mWindowAnimationsPref) {
-            writeAnimationPreference(0, objValue);
-        } else if (preference == mTransitionAnimationsPref) {
-            writeAnimationPreference(1, objValue);
-        } else if (preference == mFontSizePref) {
-            writeFontSizePreference(objValue);
-        } else if (preference == mEndButtonPref) {
-            writeEndButtonPreference(objValue);
-        }
-
-        // always let the preference setting proceed.
-        return true;
-    }
-    
-    public void writeAnimationPreference(int which, Object objValue) {
-        try {
-            float val = Float.parseFloat(objValue.toString());
-            mWindowManager.setAnimationScale(which, val);
-        } catch (NumberFormatException e) {
-        } catch (RemoteException e) {
-        }
-    }
-    
-    public void writeFontSizePreference(Object objValue) {
-        try {
-            mCurConfig.fontScale = Float.parseFloat(objValue.toString());
-            ActivityManagerNative.getDefault().updateConfiguration(mCurConfig);
-        } catch (RemoteException e) {
-        }
-    }
-    
-    public void writeEndButtonPreference(Object objValue) {
-        try {
-            int val = Integer.parseInt(objValue.toString());
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.END_BUTTON_BEHAVIOR, val);
-        } catch (NumberFormatException e) {
-        }
-    }
-    
-    int floatToIndex(float val, int resid) {
-        String[] indices = getResources().getStringArray(resid);
-        float lastVal = Float.parseFloat(indices[0]);
-        for (int i=1; i<indices.length; i++) {
-            float thisVal = Float.parseFloat(indices[i]);
-            if (val < (lastVal + (thisVal-lastVal)*.5f)) {
-                return i-1;
-            }
-            lastVal = thisVal;
-        }
-        return indices.length-1;
-    }
-    
-    public void readAnimationPreference(int which, ListPreference pref) {
-        try {
-            float scale = mWindowManager.getAnimationScale(which);
-            pref.setValueIndex(floatToIndex(scale,
-                    R.array.entryvalues_animations));
-        } catch (RemoteException e) {
-        }
-    }
-    
-    public void readFontSizePreference(ListPreference pref) {
-        try {
-            mCurConfig.updateFrom(
-                ActivityManagerNative.getDefault().getConfiguration());
-        } catch (RemoteException e) {
-        }
-        pref.setValueIndex(floatToIndex(mCurConfig.fontScale,
-                R.array.entryvalues_font_size));
-    }
-    
-    public void readEndButtonPreference(ListPreference pref) {
-        try {
-            pref.setValueIndex(Settings.System.getInt(getContentResolver(),
-                    Settings.System.END_BUTTON_BEHAVIOR));
-        } catch (SettingNotFoundException e) {
-        }
-    }
-    
-    public void onSharedPreferenceChanged(SharedPreferences preferences, String key) {
-        if (ACCELEROMETER_PREF.equals(key)) {
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.ACCELEROMETER_ROTATION,
-                    mAccelerometerPref.isChecked() ? 1 : 0);
-        } else if (FANCY_IME_ANIMATIONS_PREF.equals(key)) {
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.FANCY_IME_ANIMATIONS,
-                    mFancyImeAnimationsPref.isChecked() ? 1 : 0);
-        } else if (HAPTIC_FEEDBACK_PREF.equals(key)) {
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.HAPTIC_FEEDBACK_ENABLED,
-                    mHapticFeedbackPref.isChecked() ? 1 : 0);
-        } else if (MAPS_COMPASS_PREF.equals(key)) {
-            try {
-                Context c = createPackageContext("com.google.android.apps.maps", 0);
-                c.getSharedPreferences("extra-features", MODE_WORLD_WRITEABLE)
-                    .edit()
-                    .putBoolean("compass", mShowMapsCompassPref.isChecked())
-                    .commit();
-            } catch (NameNotFoundException e) {
-                Log.w(TAG, "Failed setting maps compass");
-                e.printStackTrace();
-            }
-        }
-    }
-    
-    @Override
-    public void onResume() {
-        super.onResume();
-        readAnimationPreference(0, mWindowAnimationsPref);
-        readAnimationPreference(1, mTransitionAnimationsPref);
-        readFontSizePreference(mFontSizePref);
-        readEndButtonPreference(mEndButtonPref);
-        updateToggles();
-    }
-}
diff --git a/apps/Term/Android.mk b/apps/Term/Android.mk
deleted file mode 100644
index 843aec5..0000000
--- a/apps/Term/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := eng
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := Term
-
-include $(BUILD_PACKAGE)
diff --git a/apps/Term/AndroidManifest.xml b/apps/Term/AndroidManifest.xml
deleted file mode 100644
index 7084d2c..0000000
--- a/apps/Term/AndroidManifest.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.term">
-    <application android:icon="@drawable/app_terminal"
-                android:label="@string/application_terminal">
-        <activity android:name="Term"
-                android:theme="@style/Theme"
-                android:launchMode="singleInstance"
-                android:configChanges="keyboard|keyboardHidden|orientation"
-                android:windowSoftInputMode="adjustResize|stateVisible">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.TEST" />
-            </intent-filter>
-        </activity>
-        <activity android:name="TermPreferences"/>
-    </application>
-</manifest> 
diff --git a/apps/Term/MODULE_LICENSE_APACHE2 b/apps/Term/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/apps/Term/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/apps/Term/NOTICE b/apps/Term/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/apps/Term/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/apps/Term/res/drawable/app_terminal.png b/apps/Term/res/drawable/app_terminal.png
deleted file mode 100644
index 1ec3b4b..0000000
--- a/apps/Term/res/drawable/app_terminal.png
+++ /dev/null
Binary files differ
diff --git a/apps/Term/res/drawable/atari_small.png b/apps/Term/res/drawable/atari_small.png
deleted file mode 100644
index 535e295..0000000
--- a/apps/Term/res/drawable/atari_small.png
+++ /dev/null
Binary files differ
diff --git a/apps/Term/res/drawable/atari_small_notice.txt b/apps/Term/res/drawable/atari_small_notice.txt
deleted file mode 100644
index afa8539..0000000
--- a/apps/Term/res/drawable/atari_small_notice.txt
+++ /dev/null
@@ -1,11 +0,0 @@
-COMMENT  Copyright (c) 1999, Thomas A. Fine
-COMMENT
-COMMENT  License to copy, modify, and distribute for both commercial and
-COMMENT  non-commercial use is herby granted, provided this notice
-COMMENT  is preserved.
-COMMENT
-COMMENT  Email to my last name at head.cfa.harvard.edu
-COMMENT  http://hea-www.harvard.edu/~fine/
-COMMENT
-COMMENT  Produced with bdfedit, a tcl/tk font editing program
-COMMENT  written by Thomas A. Fine
\ No newline at end of file
diff --git a/apps/Term/res/layout/term_activity.xml b/apps/Term/res/layout/term_activity.xml
deleted file mode 100644
index 7d93d16..0000000
--- a/apps/Term/res/layout/term_activity.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <com.android.term.EmulatorView android:id="@+id/emulatorView"
-	      android:layout_width="wrap_content"
-	      android:layout_height="wrap_content"
-	      android:layout_alignParentLeft="true"
-	      />
-   
-</LinearLayout>
diff --git a/apps/Term/res/menu/main.xml b/apps/Term/res/menu/main.xml
deleted file mode 100644
index 5f6e9d8..0000000
--- a/apps/Term/res/menu/main.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:id="@+id/menu_preferences"
-    	android:title="@string/preferences" />
-    <item android:id="@+id/menu_reset"
-    	android:title="@string/reset" />
-    <item android:id="@+id/menu_send_email"
-    	android:title="@string/send_email" />
-    <item android:id="@+id/menu_special_keys"
-    	android:title="@string/special_keys" />
-</menu>
diff --git a/apps/Term/res/values/arrays.xml b/apps/Term/res/values/arrays.xml
deleted file mode 100644
index b4857a2..0000000
--- a/apps/Term/res/values/arrays.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- -->
-
-<resources>
-    <string-array name="entries_fontsize_preference">
-        <item>4 x 8 pixels</item>
-        <item>6 pt</item>
-        <item>7 pt</item>
-        <item>8 pt</item>
-        <item>9 pt</item>
-        <item>10 pt</item>
-        <item>12 pt</item>
-        <item>14 pt</item>
-        <item>16 pt</item>
-        <item>20 pt</item>
-    </string-array>
-
-	<!-- Do not localize entryvalues -->
-    <string-array name="entryvalues_fontsize_preference">
-        <item>0</item>
-        <item>6</item>
-        <item>7</item>
-        <item>8</item>
-        <item>9</item>
-        <item>10</item>
-        <item>12</item>
-        <item>14</item>
-        <item>16</item>
-        <item>20</item>  
-    </string-array>
-
-    <string-array name="entries_color_preference">
-        <item>Black text on white</item>
-        <item>White text on black</item>
-        <item>White text on blue</item>  
-    </string-array>
-
-	<!-- Do not localize entryvalues -->
-    <string-array name="entryvalues_color_preference">
-        <item>0</item>
-        <item>1</item>
-        <item>2</item>  
-    </string-array>
-    
-    <string-array name="entries_controlkey_preference">
-        <item>Jog ball</item>
-        <item>\@ key</item>
-        <item>Left Alt key</item>
-        <item>Right Alt key</item>
-    </string-array>
-
-	<!-- Do not localize entryvalues -->
-    <string-array name="entryvalues_controlkey_preference">
-        <item>0</item>
-        <item>1</item>
-        <item>2</item>
-        <item>3</item>
-    </string-array>
-</resources>
diff --git a/apps/Term/res/values/attrs.xml b/apps/Term/res/values/attrs.xml
deleted file mode 100644
index 3787d7e..0000000
--- a/apps/Term/res/values/attrs.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<resources>
-     <declare-styleable name="EmulatorView">
-    </declare-styleable>
-</resources>
diff --git a/apps/Term/res/values/strings.xml b/apps/Term/res/values/strings.xml
deleted file mode 100644
index e3f8fcf..0000000
--- a/apps/Term/res/values/strings.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
--->
-<resources>
-   <string name="application_terminal">Terminal Emulator</string>
-   <string name="preferences">Preferences</string>
-   <string name="reset">Reset term</string>
-   <string name="send_email">Email to</string>
-   <string name="special_keys">Special keys</string>
-
-   <!-- Preference dialog -->
-   <string name="text_preferences">Text</string>
-
-   <string name="title_fontsize_preference">Font size</string>
-   <string name="summary_fontsize_preference">Choose character height in pixels.</string>
-   <string name="dialog_title_fontsize_preference">Font size</string>
-
-   <string name="title_color_preference">Colors</string>
-   <string name="summary_color_preference">Choose text color.</string>
-   <string name="dialog_title_color_preference">Text color</string>
-
-   <string name="keyboard_preferences">Keyboard</string>
-   <string name="title_controlkey_preference">Control key</string>
-   <string name="summary_controlkey_preference">Choose control key.</string>
-   <string name="dialog_title_controlkey_preference">Control key</string>
-
-   <string name="shell_preferences">Shell</string>
-   <string name="title_shell_preference">Command line</string>
-   <string name="summary_shell_preference">Specify the shell command line.</string>
-   <string name="dialog_title_shell_preference">Shell</string>
-
-   <string name="title_initialcommand_preference">Initial command</string>
-   <string name="summary_initialcommand_preference">Sent to the shell when it starts.</string>
-   <string name="dialog_title_initialcommand_preference">Initial Command</string>
-
-   <!-- Don't localize these default values -->
-   <string name="default_value_fontsize_preference">10</string>
-   <string name="default_value_color_preference">2</string>
-   <string name="default_value_controlkey_preference">0</string>
-   <string name="default_value_shell_preference">/system/bin/sh -</string>
-   <string name="default_value_initialcommand_preference">export PATH=/data/local/bin:$PATH</string>
-</resources>
diff --git a/apps/Term/res/values/styles.xml b/apps/Term/res/values/styles.xml
deleted file mode 100644
index 0e59f4a..0000000
--- a/apps/Term/res/values/styles.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <style name="Theme" parent="@android:style/Theme.Light">
-        <item name="android:windowNoTitle">true</item>
-        <item name="android:windowFrame">@null</item>
-    </style>
-</resources>
-
diff --git a/apps/Term/res/xml/preferences.xml b/apps/Term/res/xml/preferences.xml
deleted file mode 100644
index 7792153..0000000
--- a/apps/Term/res/xml/preferences.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<PreferenceScreen
-        xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <PreferenceCategory
-            android:title="@string/text_preferences">
-
-        <ListPreference
-                android:key="fontsize"
-                android:defaultValue="@string/default_value_fontsize_preference"
-                android:title="@string/title_fontsize_preference"
-                android:summary="@string/summary_fontsize_preference"
-                android:entries="@array/entries_fontsize_preference"
-                android:entryValues="@array/entryvalues_fontsize_preference"
-                android:dialogTitle="@string/dialog_title_fontsize_preference" />
-
-        <ListPreference
-                android:key="color"
-                android:defaultValue="@string/default_value_color_preference"
-                android:title="@string/title_color_preference"
-                android:summary="@string/summary_color_preference"
-                android:entries="@array/entries_color_preference"
-                android:entryValues="@array/entryvalues_color_preference"
-                android:dialogTitle="@string/dialog_title_color_preference" />
-
-    </PreferenceCategory>
-
-    <PreferenceCategory
-            android:title="@string/keyboard_preferences">
-
-        <ListPreference
-                android:key="controlkey"
-                android:defaultValue="@string/default_value_controlkey_preference"
-                android:title="@string/title_controlkey_preference"
-                android:summary="@string/summary_controlkey_preference"
-                android:entries="@array/entries_controlkey_preference"
-                android:entryValues="@array/entryvalues_controlkey_preference"
-                android:dialogTitle="@string/dialog_title_controlkey_preference" />
-
-    </PreferenceCategory>
-
-    <PreferenceCategory
-        android:title="@string/shell_preferences">
-
-    <EditTextPreference
-            android:key="shell"
-            android:defaultValue="@string/default_value_shell_preference"
-            android:title="@string/title_shell_preference"
-            android:summary="@string/summary_shell_preference"
-            android:dialogTitle="@string/dialog_title_shell_preference" />
-    <EditTextPreference
-            android:key="initialcommand"
-            android:defaultValue="@string/default_value_initialcommand_preference"
-            android:title="@string/title_initialcommand_preference"
-            android:summary="@string/summary_initialcommand_preference"
-            android:dialogTitle="@string/dialog_title_initialcommand_preference" />
-    </PreferenceCategory>
-</PreferenceScreen>
diff --git a/apps/Term/src/com/android/term/Term.java b/apps/Term/src/com/android/term/Term.java
deleted file mode 100644
index d74159b..0000000
--- a/apps/Term/src/com/android/term/Term.java
+++ /dev/null
@@ -1,3262 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.term;
-
-import android.app.Activity;
-import android.app.AlertDialog;
-import android.content.Context;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.content.res.Configuration;
-import android.content.res.Resources;
-import android.content.res.TypedArray;
-import android.graphics.Bitmap;
-import android.graphics.BitmapFactory;
-import android.graphics.Canvas;
-import android.graphics.ColorMatrixColorFilter;
-import android.graphics.Paint;
-import android.graphics.PorterDuff;
-import android.graphics.PorterDuffXfermode;
-import android.graphics.Rect;
-import android.graphics.Typeface;
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.Exec;
-import android.os.Handler;
-import android.os.Message;
-import android.os.SystemClock;
-import android.preference.PreferenceManager;
-import android.util.AttributeSet;
-import android.util.Log;
-import android.view.GestureDetector;
-import android.view.KeyEvent;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.MotionEvent;
-import android.view.View;
-import android.view.inputmethod.BaseInputConnection;
-import android.view.inputmethod.CompletionInfo;
-import android.view.inputmethod.EditorInfo;
-import android.view.inputmethod.ExtractedText;
-import android.view.inputmethod.ExtractedTextRequest;
-import android.view.inputmethod.InputConnection;
-import android.view.inputmethod.InputMethodManager;
-
-import java.io.FileDescriptor;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.util.ArrayList;
-
-/**
- * A terminal emulator activity.
- */
-
-public class Term extends Activity {
-    /**
-     * Set to true to add debugging code and logging.
-     */
-    public static final boolean DEBUG = false;
-
-    /**
-     * Set to true to log each character received from the remote process to the
-     * android log, which makes it easier to debug some kinds of problems with
-     * emulating escape sequences and control codes.
-     */
-    public static final boolean LOG_CHARACTERS_FLAG = DEBUG && false;
-
-    /**
-     * Set to true to log unknown escape sequences.
-     */
-    public static final boolean LOG_UNKNOWN_ESCAPE_SEQUENCES = DEBUG && false;
-
-    /**
-     * The tag we use when logging, so that our messages can be distinguished
-     * from other messages in the log. Public because it's used by several
-     * classes.
-     */
-    public static final String LOG_TAG = "Term";
-
-    /**
-     * Our main view. Displays the emulated terminal screen.
-     */
-    private EmulatorView mEmulatorView;
-
-    /**
-     * The pseudo-teletype (pty) file descriptor that we use to communicate with
-     * another process, typically a shell. Currently we just use this to get the
-     * mTermIn / mTermOut file descriptors, but when we implement resizing of
-     * the terminal we will need it to issue the ioctl to inform the other
-     * process that we've changed the terminal size.
-     */
-    private FileDescriptor mTermFd;
-
-    private boolean mShellRunning;
-
-    /**
-     * Used to send data to the remote process.
-     */
-    private FileOutputStream mTermOut;
-
-    /**
-     * A key listener that tracks the modifier keys and allows the full ASCII
-     * character set to be entered.
-     */
-    private TermKeyListener mKeyListener;
-
-    /**
-     * The name of our emulator view in the view resource.
-     */
-    private static final int EMULATOR_VIEW = R.id.emulatorView;
-
-    private int mFontSize = 9;
-    private int mColorId = 2;
-    private int mControlKeyId = 0;
-
-    private static final String FONTSIZE_KEY = "fontsize";
-    private static final String COLOR_KEY = "color";
-    private static final String CONTROLKEY_KEY = "controlkey";
-    private static final String SHELL_KEY = "shell";
-    private static final String INITIALCOMMAND_KEY = "initialcommand";
-
-    public static final int WHITE = 0xffffffff;
-    public static final int BLACK = 0xff000000;
-    public static final int BLUE = 0xff344ebd;
-
-    private static final int[][] COLOR_SCHEMES = {
-        {BLACK, WHITE}, {WHITE, BLACK}, {WHITE, BLUE}};
-
-    private static final int[] CONTROL_KEY_SCHEMES = {
-        KeyEvent.KEYCODE_DPAD_CENTER,
-        KeyEvent.KEYCODE_AT,
-        KeyEvent.KEYCODE_ALT_LEFT,
-        KeyEvent.KEYCODE_ALT_RIGHT
-    };
-    private static final String[] CONTROL_KEY_NAME = {
-        "Ball", "@", "Left-Alt", "Right-Alt"
-    };
-
-    private int mControlKeyCode;
-
-    private final static String DEFAULT_SHELL = "/system/bin/sh -";
-    private String mShell;
-
-    private final static String DEFAULT_INITIAL_COMMAND =
-        "export PATH=/data/local/bin:$PATH";
-    private String mInitialCommand;
-
-    private SharedPreferences mPrefs;
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        Log.e(Term.LOG_TAG, "onCreate");
-        mPrefs = PreferenceManager.getDefaultSharedPreferences(this);
-        mPrefs.registerOnSharedPreferenceChangeListener(
-                new SharedPreferences.OnSharedPreferenceChangeListener(){
-
-                    public void onSharedPreferenceChanged(
-                            SharedPreferences sharedPreferences, String key) {
-                        readPrefs();
-                        updatePrefs();
-                    }});
-        readPrefs();
-
-        setContentView(R.layout.term_activity);
-
-        mEmulatorView = (EmulatorView) findViewById(EMULATOR_VIEW);
-
-        startListening();
-
-        mKeyListener = new TermKeyListener();
-
-        mEmulatorView.setFocusable(true);
-        mEmulatorView.requestFocus();
-
-        updatePrefs();
-    }
-
-    private void startListening() {
-        int[] processId = new int[1];
-
-        createSubprocess(processId);
-        mShellRunning = true;
-
-        final int procId = processId[0];
-
-        final Handler handler = new Handler() {
-            @Override
-            public void handleMessage(Message msg) {
-                mShellRunning = false;
-            }
-        };
-
-        Runnable watchForDeath = new Runnable() {
-
-            public void run() {
-                Log.i(Term.LOG_TAG, "waiting for: " + procId);
-               int result = Exec.waitFor(procId);
-                Log.i(Term.LOG_TAG, "Subprocess exited: " + result);
-                handler.sendEmptyMessage(result);
-             }
-
-        };
-        Thread watcher = new Thread(watchForDeath);
-        watcher.start();
-
-        mTermOut = new FileOutputStream(mTermFd);
-
-        mEmulatorView.initialize(mTermFd, mTermOut);
-
-        sendInitialCommand();
-    }
-
-    private void sendInitialCommand() {
-        String initialCommand = mInitialCommand;
-        if (initialCommand == null) {
-            initialCommand = DEFAULT_INITIAL_COMMAND;
-        }
-        if (initialCommand.length() > 0) {
-            write(initialCommand + '\r');
-        }
-    }
-
-    private void restart() {
-        startActivity(getIntent());
-        finish();
-    }
-
-    private void write(String data) {
-        try {
-            mTermOut.write(data.getBytes());
-            mTermOut.flush();
-        } catch (IOException e) {
-            // Ignore exception
-            // We don't really care if the receiver isn't listening.
-            // We just make a best effort to answer the query.
-        }
-    }
-
-    private void createSubprocess(int[] processId) {
-        String shell = mShell;
-        if (shell == null) {
-            shell = DEFAULT_SHELL;
-        }
-        ArrayList<String> args = parse(shell);
-        String arg0 = args.get(0);
-        String arg1 = null;
-        String arg2 = null;
-        if (args.size() >= 2) {
-            arg1 = args.get(1);
-        }
-        if (args.size() >= 3) {
-            arg2 = args.get(2);
-        }
-        mTermFd = Exec.createSubprocess(arg0, arg1, arg2, processId);
-    }
-
-    private ArrayList<String> parse(String cmd) {
-        final int PLAIN = 0;
-        final int WHITESPACE = 1;
-        final int INQUOTE = 2;
-        int state = WHITESPACE;
-        ArrayList<String> result =  new ArrayList<String>();
-        int cmdLen = cmd.length();
-        StringBuilder builder = new StringBuilder();
-        for (int i = 0; i < cmdLen; i++) {
-            char c = cmd.charAt(i);
-            if (state == PLAIN) {
-                if (Character.isWhitespace(c)) {
-                    result.add(builder.toString());
-                    builder.delete(0,builder.length());
-                    state = WHITESPACE;
-                } else if (c == '"') {
-                    state = INQUOTE;
-                } else {
-                    builder.append(c);
-                }
-            } else if (state == WHITESPACE) {
-                if (Character.isWhitespace(c)) {
-                    // do nothing
-                } else if (c == '"') {
-                    state = INQUOTE;
-                } else {
-                    state = PLAIN;
-                    builder.append(c);
-                }
-            } else if (state == INQUOTE) {
-                if (c == '\\') {
-                    if (i + 1 < cmdLen) {
-                        i += 1;
-                        builder.append(cmd.charAt(i));
-                    }
-                } else if (c == '"') {
-                    state = PLAIN;
-                } else {
-                    builder.append(c);
-                }
-            }
-        }
-        if (builder.length() > 0) {
-            result.add(builder.toString());
-        }
-        return result;
-    }
-
-    private void readPrefs() {
-        mFontSize = readIntPref(FONTSIZE_KEY, mFontSize, 20);
-        mColorId = readIntPref(COLOR_KEY, mColorId, COLOR_SCHEMES.length - 1);
-        mControlKeyId = readIntPref(CONTROLKEY_KEY, mControlKeyId,
-                CONTROL_KEY_SCHEMES.length - 1);
-        {
-            String newShell = readStringPref(SHELL_KEY, mShell);
-            if ((newShell == null) || ! newShell.equals(mShell)) {
-                if (mShell != null) {
-                    Log.i(Term.LOG_TAG, "New shell set. Restarting.");
-                    restart();
-                }
-                mShell = newShell;
-            }
-        }
-        {
-            String newInitialCommand = readStringPref(INITIALCOMMAND_KEY,
-                    mInitialCommand);
-            if ((newInitialCommand == null)
-                    || ! newInitialCommand.equals(mInitialCommand)) {
-                if (mInitialCommand != null) {
-                    Log.i(Term.LOG_TAG, "New initial command set. Restarting.");
-                    restart();
-                }
-                mInitialCommand = newInitialCommand;
-            }
-        }
-    }
-
-    private void updatePrefs() {
-        mEmulatorView.setTextSize(mFontSize);
-        setColors();
-        mControlKeyCode = CONTROL_KEY_SCHEMES[mControlKeyId];
-    }
-
-    private int readIntPref(String key, int defaultValue, int maxValue) {
-        int val;
-        try {
-            val = Integer.parseInt(
-                mPrefs.getString(key, Integer.toString(defaultValue)));
-        } catch (NumberFormatException e) {
-            val = defaultValue;
-        }
-        val = Math.max(0, Math.min(val, maxValue));
-        return val;
-    }
-
-    private String readStringPref(String key, String defaultValue) {
-        return mPrefs.getString(key, defaultValue);
-    }
-
-    @Override
-    public void onPause() {
-        SharedPreferences.Editor e = mPrefs.edit();
-        e.clear();
-        e.putString(FONTSIZE_KEY, Integer.toString(mFontSize));
-        e.putString(COLOR_KEY, Integer.toString(mColorId));
-        e.putString(CONTROLKEY_KEY, Integer.toString(mControlKeyId));
-        e.putString(SHELL_KEY, mShell);
-        e.putString(INITIALCOMMAND_KEY, mInitialCommand);
-        e.commit();
-
-        super.onPause();
-    }
-
-    @Override
-    public void onConfigurationChanged(Configuration newConfig) {
-        super.onConfigurationChanged(newConfig);
-
-        mEmulatorView.updateSize();
-    }
-
-    @Override
-    public boolean onKeyDown(int keyCode, KeyEvent event) {
-        if (handleControlKey(keyCode, true)) {
-            return true;
-        } else if (isSystemKey(keyCode, event)) {
-            // Don't intercept the system keys
-            return super.onKeyDown(keyCode, event);
-        } else if (handleDPad(keyCode, true)) {
-            return true;
-        }
-
-        // Translate the keyCode into an ASCII character.
-        int letter = mKeyListener.keyDown(keyCode, event);
-
-        if (letter >= 0) {
-            try {
-                mTermOut.write(letter);
-            } catch (IOException e) {
-                // Ignore I/O exceptions
-            }
-        }
-        return true;
-    }
-
-    @Override
-    public boolean onKeyUp(int keyCode, KeyEvent event) {
-        if (handleControlKey(keyCode, false)) {
-            return true;
-        } else if (isSystemKey(keyCode, event)) {
-            // Don't intercept the system keys
-            return super.onKeyUp(keyCode, event);
-        } else if (handleDPad(keyCode, false)) {
-            return true;
-        }
-
-        mKeyListener.keyUp(keyCode);
-        return true;
-    }
-
-    private boolean handleControlKey(int keyCode, boolean down) {
-        if (keyCode == mControlKeyCode) {
-            mKeyListener.handleControlKey(down);
-            return true;
-        }
-        return false;
-    }
-
-    /**
-     * Handle dpad left-right-up-down events. Don't handle
-     * dpad-center, that's our control key.
-     * @param keyCode
-     * @param down
-     */
-    private boolean handleDPad(int keyCode, boolean down) {
-        if (keyCode < KeyEvent.KEYCODE_DPAD_UP ||
-                keyCode > KeyEvent.KEYCODE_DPAD_CENTER) {
-            return false;
-        }
-
-        if (down) {
-            try {
-                if (keyCode == KeyEvent.KEYCODE_DPAD_CENTER) {
-                    mTermOut.write('\r');
-                } else {
-                    char code;
-                    switch (keyCode) {
-                    case KeyEvent.KEYCODE_DPAD_UP:
-                        code = 'A';
-                        break;
-                    case KeyEvent.KEYCODE_DPAD_DOWN:
-                        code = 'B';
-                        break;
-                    case KeyEvent.KEYCODE_DPAD_LEFT:
-                        code = 'D';
-                        break;
-                    default:
-                    case KeyEvent.KEYCODE_DPAD_RIGHT:
-                        code = 'C';
-                        break;
-                    }
-                    mTermOut.write(27); // ESC
-                    if (mEmulatorView.getKeypadApplicationMode()) {
-                        mTermOut.write('O');
-                    } else {
-                        mTermOut.write('[');
-                    }
-                    mTermOut.write(code);
-                }
-            } catch (IOException e) {
-                // Ignore
-            }
-        }
-        return true;
-    }
-
-    private boolean isSystemKey(int keyCode, KeyEvent event) {
-        return event.isSystem();
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        getMenuInflater().inflate(R.menu.main, menu);
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        int id = item.getItemId();
-        if (id == R.id.menu_preferences) {
-            doPreferences();
-        } else if (id == R.id.menu_reset) {
-            doResetTerminal();
-        } else if (id == R.id.menu_send_email) {
-            doEmailTranscript();
-        } else if (id == R.id.menu_special_keys) {
-            doDocumentKeys();
-        }
-        return super.onOptionsItemSelected(item);
-    }
-
-    private void doPreferences() {
-        startActivity(new Intent(this, TermPreferences.class));
-    }
-
-    private void setColors() {
-        int[] scheme = COLOR_SCHEMES[mColorId];
-        mEmulatorView.setColors(scheme[0], scheme[1]);
-    }
-
-    private void doResetTerminal() {
-        restart();
-    }
-
-    private void doEmailTranscript() {
-        // Don't really want to supply an address, but
-        // currently it's required, otherwise we get an
-        // exception.
-        String addr = "user@example.com";
-        Intent intent =
-                new Intent(Intent.ACTION_SENDTO, Uri.parse("mailto:"
-                        + addr));
-
-        intent.putExtra("body", mEmulatorView.getTranscriptText());
-        startActivity(intent);
-    }
-
-    private void doDocumentKeys() {
-        String controlKey = CONTROL_KEY_NAME[mControlKeyId];
-        new AlertDialog.Builder(this).
-            setTitle("Press " + controlKey + " and Key").
-            setMessage(controlKey + " Space ==> Control-@ (NUL)\n"
-                    + controlKey + " A..Z ==> Control-A..Z\n"
-                    + controlKey + " 1 ==> Control-[ (ESC)\n"
-                    + controlKey + " 5 ==> Control-_\n"
-                    + controlKey + " . ==> Control-\\\n"
-                    + controlKey + " 0 ==> Control-]\n"
-                    + controlKey + " 6 ==> Control-^").
-            show();
-     }
-
-    private void print(String msg) {
-        char[] chars = msg.toCharArray();
-        int len = chars.length;
-        byte[] bytes = new byte[len];
-        for (int i = 0; i < len; i++) {
-            bytes[i] = (byte) chars[i];
-        }
-        mEmulatorView.append(bytes, 0, len);
-    }
-}
-
-
-/**
- * An abstract screen interface. A terminal screen stores lines of text. (The
- * reason to abstract it is to allow different implementations, and to hide
- * implementation details from clients.)
- */
-interface Screen {
-
-    /**
-     * Set line wrap flag for a given row. Affects how lines are logically
-     * wrapped when changing screen size or converting to a transcript.
-     */
-    void setLineWrap(int row);
-
-    /**
-     * Store byte b into the screen at location (x, y)
-     *
-     * @param x X coordinate (also known as column)
-     * @param y Y coordinate (also known as row)
-     * @param b ASCII character to store
-     * @param foreColor the foreground color
-     * @param backColor the background color
-     */
-    void set(int x, int y, byte b, int foreColor, int backColor);
-
-    /**
-     * Scroll the screen down one line. To scroll the whole screen of a 24 line
-     * screen, the arguments would be (0, 24).
-     *
-     * @param topMargin First line that is scrolled.
-     * @param bottomMargin One line after the last line that is scrolled.
-     */
-    void scroll(int topMargin, int bottomMargin, int foreColor, int backColor);
-
-    /**
-     * Block copy characters from one position in the screen to another. The two
-     * positions can overlap. All characters of the source and destination must
-     * be within the bounds of the screen, or else an InvalidParemeterException
-     * will be thrown.
-     *
-     * @param sx source X coordinate
-     * @param sy source Y coordinate
-     * @param w width
-     * @param h height
-     * @param dx destination X coordinate
-     * @param dy destination Y coordinate
-     */
-    void blockCopy(int sx, int sy, int w, int h, int dx, int dy);
-
-    /**
-     * Block set characters. All characters must be within the bounds of the
-     * screen, or else and InvalidParemeterException will be thrown. Typically
-     * this is called with a "val" argument of 32 to clear a block of
-     * characters.
-     *
-     * @param sx source X
-     * @param sy source Y
-     * @param w width
-     * @param h height
-     * @param val value to set.
-     * @param foreColor the foreground color
-     * @param backColor the background color
-     */
-    void blockSet(int sx, int sy, int w, int h, int val, int foreColor, int
-            backColor);
-
-    /**
-     * Get the contents of the transcript buffer as a text string.
-     *
-     * @return the contents of the transcript buffer.
-     */
-    String getTranscriptText();
-
-    /**
-     * Resize the screen
-     * @param columns
-     * @param rows
-     */
-    void resize(int columns, int rows, int foreColor, int backColor);
-}
-
-
-/**
- * A TranscriptScreen is a screen that remembers data that's been scrolled. The
- * old data is stored in a ring buffer to minimize the amount of copying that
- * needs to be done. The transcript does its own drawing, to avoid having to
- * expose its internal data structures.
- */
-class TranscriptScreen implements Screen {
-
-    /**
-     * The width of the transcript, in characters. Fixed at initialization.
-     */
-    private int mColumns;
-
-    /**
-     * The total number of rows in the transcript and the screen. Fixed at
-     * initialization.
-     */
-    private int mTotalRows;
-
-    /**
-     * The number of rows in the active portion of the transcript. Doesn't
-     * include the screen.
-     */
-    private int mActiveTranscriptRows;
-
-    /**
-     * Which row is currently the topmost line of the transcript. Used to
-     * implement a circular buffer.
-     */
-    private int mHead;
-
-    /**
-     * The number of active rows, includes both the transcript and the screen.
-     */
-    private int mActiveRows;
-
-    /**
-     * The number of rows in the screen.
-     */
-    private int mScreenRows;
-
-    /**
-     * The data for both the screen and the transcript. The first mScreenRows *
-     * mLineWidth characters are the screen, the rest are the transcript.
-     * The low byte encodes the ASCII character, the high byte encodes the
-     * foreground and background colors, plus underline and bold.
-     */
-    private char[] mData;
-
-    /**
-     * The data's stored as color-encoded chars, but the drawing routines require chars, so we
-     * need a temporary buffer to hold a row's worth of characters.
-     */
-    private char[] mRowBuffer;
-
-    /**
-     * Flags that keep track of whether the current line logically wraps to the
-     * next line. This is used when resizing the screen and when copying to the
-     * clipboard or an email attachment
-     */
-
-    private boolean[] mLineWrap;
-
-    /**
-     * Create a transcript screen.
-     *
-     * @param columns the width of the screen in characters.
-     * @param totalRows the height of the entire text area, in rows of text.
-     * @param screenRows the height of just the screen, not including the
-     *        transcript that holds lines that have scrolled off the top of the
-     *        screen.
-     */
-    public TranscriptScreen(int columns, int totalRows, int screenRows,
-            int foreColor, int backColor) {
-        init(columns, totalRows, screenRows, foreColor, backColor);
-    }
-
-    private void init(int columns, int totalRows, int screenRows, int foreColor, int backColor) {
-        mColumns = columns;
-        mTotalRows = totalRows;
-        mActiveTranscriptRows = 0;
-        mHead = 0;
-        mActiveRows = screenRows;
-        mScreenRows = screenRows;
-        int totalSize = columns * totalRows;
-        mData = new char[totalSize];
-        blockSet(0, 0, mColumns, mScreenRows, ' ', foreColor, backColor);
-        mRowBuffer = new char[columns];
-        mLineWrap = new boolean[totalRows];
-        consistencyCheck();
-   }
-
-    /**
-     * Convert a row value from the public external coordinate system to our
-     * internal private coordinate system. External coordinate system:
-     * -mActiveTranscriptRows to mScreenRows-1, with the screen being
-     * 0..mScreenRows-1 Internal coordinate system: 0..mScreenRows-1 rows of
-     * mData are the visible rows. mScreenRows..mActiveRows - 1 are the
-     * transcript, stored as a circular buffer.
-     *
-     * @param row a row in the external coordinate system.
-     * @return The row corresponding to the input argument in the private
-     *         coordinate system.
-     */
-    private int externalToInternalRow(int row) {
-        if (row < -mActiveTranscriptRows || row >= mScreenRows) {
-            throw new IllegalArgumentException();
-        }
-        if (row >= 0) {
-            return row; // This is a visible row.
-        }
-        return mScreenRows
-                + ((mHead + mActiveTranscriptRows + row) % mActiveTranscriptRows);
-    }
-
-    private int getOffset(int externalLine) {
-        return externalToInternalRow(externalLine) * mColumns;
-    }
-
-    private int getOffset(int x, int y) {
-        return getOffset(y) + x;
-    }
-
-    public void setLineWrap(int row) {
-        mLineWrap[externalToInternalRow(row)] = true;
-    }
-
-    /**
-     * Store byte b into the screen at location (x, y)
-     *
-     * @param x X coordinate (also known as column)
-     * @param y Y coordinate (also known as row)
-     * @param b ASCII character to store
-     * @param foreColor the foreground color
-     * @param backColor the background color
-     */
-    public void set(int x, int y, byte b, int foreColor, int backColor) {
-        mData[getOffset(x, y)] = encode(b, foreColor, backColor);
-    }
-
-    private char encode(int b, int foreColor, int backColor) {
-        return (char) ((foreColor << 12) | (backColor << 8) | b);
-    }
-
-    /**
-     * Scroll the screen down one line. To scroll the whole screen of a 24 line
-     * screen, the arguments would be (0, 24).
-     *
-     * @param topMargin First line that is scrolled.
-     * @param bottomMargin One line after the last line that is scrolled.
-     */
-    public void scroll(int topMargin, int bottomMargin, int foreColor,
-            int backColor) {
-        if (topMargin > bottomMargin - 2 || topMargin > mScreenRows - 2
-                || bottomMargin > mScreenRows) {
-            throw new IllegalArgumentException();
-        }
-
-        // Adjust the transcript so that the last line of the transcript
-        // is ready to receive the newly scrolled data
-        consistencyCheck();
-        int expansionRows = Math.min(1, mTotalRows - mActiveRows);
-        int rollRows = 1 - expansionRows;
-        mActiveRows += expansionRows;
-        mActiveTranscriptRows += expansionRows;
-        if (mActiveTranscriptRows > 0) {
-            mHead = (mHead + rollRows) % mActiveTranscriptRows;
-        }
-        consistencyCheck();
-
-        // Block move the scroll line to the transcript
-        int topOffset = getOffset(topMargin);
-        int destOffset = getOffset(-1);
-        System.arraycopy(mData, topOffset, mData, destOffset, mColumns);
-
-        int topLine = externalToInternalRow(topMargin);
-        int destLine = externalToInternalRow(-1);
-        System.arraycopy(mLineWrap, topLine, mLineWrap, destLine, 1);
-
-        // Block move the scrolled data up
-        int numScrollChars = (bottomMargin - topMargin - 1) * mColumns;
-        System.arraycopy(mData, topOffset + mColumns, mData, topOffset,
-                numScrollChars);
-        int numScrollLines = (bottomMargin - topMargin - 1);
-        System.arraycopy(mLineWrap, topLine + 1, mLineWrap, topLine,
-                numScrollLines);
-
-        // Erase the bottom line of the scroll region
-        blockSet(0, bottomMargin - 1, mColumns, 1, ' ', foreColor, backColor);
-        mLineWrap[externalToInternalRow(bottomMargin-1)] = false;
-    }
-
-    private void consistencyCheck() {
-        checkPositive(mColumns);
-        checkPositive(mTotalRows);
-        checkRange(0, mActiveTranscriptRows, mTotalRows);
-        if (mActiveTranscriptRows == 0) {
-            checkEqual(mHead, 0);
-        } else {
-            checkRange(0, mHead, mActiveTranscriptRows-1);
-        }
-        checkEqual(mScreenRows + mActiveTranscriptRows, mActiveRows);
-        checkRange(0, mScreenRows, mTotalRows);
-
-        checkEqual(mTotalRows, mLineWrap.length);
-        checkEqual(mTotalRows*mColumns, mData.length);
-        checkEqual(mColumns, mRowBuffer.length);
-    }
-
-    private void checkPositive(int n) {
-        if (n < 0) {
-            throw new IllegalArgumentException("checkPositive " + n);
-        }
-    }
-
-    private void checkRange(int a, int b, int c) {
-        if (a > b || b > c) {
-            throw new IllegalArgumentException("checkRange " + a + " <= " + b + " <= " + c);
-        }
-    }
-
-    private void checkEqual(int a, int b) {
-        if (a != b) {
-            throw new IllegalArgumentException("checkEqual " + a + " == " + b);
-        }
-    }
-
-    /**
-     * Block copy characters from one position in the screen to another. The two
-     * positions can overlap. All characters of the source and destination must
-     * be within the bounds of the screen, or else an InvalidParemeterException
-     * will be thrown.
-     *
-     * @param sx source X coordinate
-     * @param sy source Y coordinate
-     * @param w width
-     * @param h height
-     * @param dx destination X coordinate
-     * @param dy destination Y coordinate
-     */
-    public void blockCopy(int sx, int sy, int w, int h, int dx, int dy) {
-        if (sx < 0 || sx + w > mColumns || sy < 0 || sy + h > mScreenRows
-                || dx < 0 || dx + w > mColumns || dy < 0
-                || dy + h > mScreenRows) {
-            throw new IllegalArgumentException();
-        }
-        if (sy <= dy) {
-            // Move in increasing order
-            for (int y = 0; y < h; y++) {
-                int srcOffset = getOffset(sx, sy + y);
-                int dstOffset = getOffset(dx, dy + y);
-                System.arraycopy(mData, srcOffset, mData, dstOffset, w);
-            }
-        } else {
-            // Move in decreasing order
-            for (int y = 0; y < h; y++) {
-                int y2 = h - (y + 1);
-                int srcOffset = getOffset(sx, sy + y2);
-                int dstOffset = getOffset(dx, dy + y2);
-                System.arraycopy(mData, srcOffset, mData, dstOffset, w);
-            }
-        }
-    }
-
-    /**
-     * Block set characters. All characters must be within the bounds of the
-     * screen, or else and InvalidParemeterException will be thrown. Typically
-     * this is called with a "val" argument of 32 to clear a block of
-     * characters.
-     *
-     * @param sx source X
-     * @param sy source Y
-     * @param w width
-     * @param h height
-     * @param val value to set.
-     */
-    public void blockSet(int sx, int sy, int w, int h, int val,
-            int foreColor, int backColor) {
-        if (sx < 0 || sx + w > mColumns || sy < 0 || sy + h > mScreenRows) {
-            throw new IllegalArgumentException();
-        }
-        char[] data = mData;
-        char encodedVal = encode(val, foreColor, backColor);
-        for (int y = 0; y < h; y++) {
-            int offset = getOffset(sx, sy + y);
-            for (int x = 0; x < w; x++) {
-                data[offset + x] = encodedVal;
-            }
-        }
-    }
-
-    /**
-     * Draw a row of text. Out-of-bounds rows are blank, not errors.
-     *
-     * @param row The row of text to draw.
-     * @param canvas The canvas to draw to.
-     * @param x The x coordinate origin of the drawing
-     * @param y The y coordinate origin of the drawing
-     * @param renderer The renderer to use to draw the text
-     * @param cx the cursor X coordinate, -1 means don't draw it
-     */
-    public final void drawText(int row, Canvas canvas, float x, float y,
-            TextRenderer renderer, int cx) {
-
-        // Out-of-bounds rows are blank.
-        if (row < -mActiveTranscriptRows || row >= mScreenRows) {
-            return;
-        }
-
-        // Copy the data from the byte array to a char array so they can
-        // be drawn.
-
-        int offset = getOffset(row);
-        char[] rowBuffer = mRowBuffer;
-        char[] data = mData;
-        int columns = mColumns;
-        int lastColors = 0;
-        int lastRunStart = -1;
-        final int CURSOR_MASK = 0x10000;
-        for (int i = 0; i < columns; i++) {
-            char c = data[offset + i];
-            int colors = (char) (c & 0xff00);
-            if (cx == i) {
-                // Set cursor background color:
-                colors |= CURSOR_MASK;
-            }
-            rowBuffer[i] = (char) (c & 0x00ff);
-            if (colors != lastColors) {
-                if (lastRunStart >= 0) {
-                    renderer.drawTextRun(canvas, x, y, lastRunStart, rowBuffer,
-                            lastRunStart, i - lastRunStart,
-                            (lastColors & CURSOR_MASK) != 0,
-                            0xf & (lastColors >> 12), 0xf & (lastColors >> 8));
-                }
-                lastColors = colors;
-                lastRunStart = i;
-            }
-        }
-        if (lastRunStart >= 0) {
-            renderer.drawTextRun(canvas, x, y, lastRunStart, rowBuffer,
-                    lastRunStart, columns - lastRunStart,
-                    (lastColors & CURSOR_MASK) != 0,
-                    0xf & (lastColors >> 12), 0xf & (lastColors >> 8));
-        }
-     }
-
-    /**
-     * Get the count of active rows.
-     *
-     * @return the count of active rows.
-     */
-    public int getActiveRows() {
-        return mActiveRows;
-    }
-
-    /**
-     * Get the count of active transcript rows.
-     *
-     * @return the count of active transcript rows.
-     */
-    public int getActiveTranscriptRows() {
-        return mActiveTranscriptRows;
-    }
-
-    public String getTranscriptText() {
-        return internalGetTranscriptText(true);
-    }
-
-    private String internalGetTranscriptText(boolean stripColors) {
-        StringBuilder builder = new StringBuilder();
-        char[] rowBuffer = mRowBuffer;
-        char[] data = mData;
-        int columns = mColumns;
-        for (int row = -mActiveTranscriptRows; row < mScreenRows; row++) {
-            int offset = getOffset(row);
-            int lastPrintingChar = -1;
-            for (int column = 0; column < columns; column++) {
-                char c = data[offset + column];
-                if (stripColors) {
-                    c = (char) (c & 0xff);
-                }
-                if ((c & 0xff) != ' ') {
-                    lastPrintingChar = column;
-                }
-                rowBuffer[column] = c;
-            }
-            if (mLineWrap[externalToInternalRow(row)]) {
-                builder.append(rowBuffer, 0, columns);
-            } else {
-                builder.append(rowBuffer, 0, lastPrintingChar + 1);
-                builder.append('\n');
-            }
-        }
-        return builder.toString();
-    }
-
-    public void resize(int columns, int rows, int foreColor, int backColor) {
-        init(columns, mTotalRows, rows, foreColor, backColor);
-    }
-}
-
-/**
- * Renders text into a screen. Contains all the terminal-specific knowlege and
- * state. Emulates a subset of the X Window System xterm terminal, which in turn
- * is an emulator for a subset of the Digital Equipment Corporation vt100
- * terminal. Missing functionality: text attributes (bold, underline, reverse
- * video, color) alternate screen cursor key and keypad escape sequences.
- */
-class TerminalEmulator {
-
-    /**
-     * The cursor row. Numbered 0..mRows-1.
-     */
-    private int mCursorRow;
-
-    /**
-     * The cursor column. Numbered 0..mColumns-1.
-     */
-    private int mCursorCol;
-
-    /**
-     * The number of character rows in the terminal screen.
-     */
-    private int mRows;
-
-    /**
-     * The number of character columns in the terminal screen.
-     */
-    private int mColumns;
-
-    /**
-     * Used to send data to the remote process. Needed to implement the various
-     * "report" escape sequences.
-     */
-    private FileOutputStream mTermOut;
-
-    /**
-     * Stores the characters that appear on the screen of the emulated terminal.
-     */
-    private Screen mScreen;
-
-    /**
-     * Keeps track of the current argument of the current escape sequence.
-     * Ranges from 0 to MAX_ESCAPE_PARAMETERS-1. (Typically just 0 or 1.)
-     */
-    private int mArgIndex;
-
-    /**
-     * The number of parameter arguments. This name comes from the ANSI standard
-     * for terminal escape codes.
-     */
-    private static final int MAX_ESCAPE_PARAMETERS = 16;
-
-    /**
-     * Holds the arguments of the current escape sequence.
-     */
-    private int[] mArgs = new int[MAX_ESCAPE_PARAMETERS];
-
-    // Escape processing states:
-
-    /**
-     * Escape processing state: Not currently in an escape sequence.
-     */
-    private static final int ESC_NONE = 0;
-
-    /**
-     * Escape processing state: Have seen an ESC character
-     */
-    private static final int ESC = 1;
-
-    /**
-     * Escape processing state: Have seen ESC POUND
-     */
-    private static final int ESC_POUND = 2;
-
-    /**
-     * Escape processing state: Have seen ESC and a character-set-select char
-     */
-    private static final int ESC_SELECT_LEFT_PAREN = 3;
-
-    /**
-     * Escape processing state: Have seen ESC and a character-set-select char
-     */
-    private static final int ESC_SELECT_RIGHT_PAREN = 4;
-
-    /**
-     * Escape processing state: ESC [
-     */
-    private static final int ESC_LEFT_SQUARE_BRACKET = 5;
-
-    /**
-     * Escape processing state: ESC [ ?
-     */
-    private static final int ESC_LEFT_SQUARE_BRACKET_QUESTION_MARK = 6;
-
-    /**
-     * True if the current escape sequence should continue, false if the current
-     * escape sequence should be terminated. Used when parsing a single
-     * character.
-     */
-    private boolean mContinueSequence;
-
-    /**
-     * The current state of the escape sequence state machine.
-     */
-    private int mEscapeState;
-
-    /**
-     * Saved state of the cursor row, Used to implement the save/restore cursor
-     * position escape sequences.
-     */
-    private int mSavedCursorRow;
-
-    /**
-     * Saved state of the cursor column, Used to implement the save/restore
-     * cursor position escape sequences.
-     */
-    private int mSavedCursorCol;
-
-    // DecSet booleans
-
-    /**
-     * This mask indicates 132-column mode is set. (As opposed to 80-column
-     * mode.)
-     */
-    private static final int K_132_COLUMN_MODE_MASK = 1 << 3;
-
-    /**
-     * This mask indicates that origin mode is set. (Cursor addressing is
-     * relative to the absolute screen size, rather than the currently set top
-     * and bottom margins.)
-     */
-    private static final int K_ORIGIN_MODE_MASK = 1 << 6;
-
-    /**
-     * This mask indicates that wraparound mode is set. (As opposed to
-     * stop-at-right-column mode.)
-     */
-    private static final int K_WRAPAROUND_MODE_MASK = 1 << 7;
-
-    /**
-     * Holds multiple DECSET flags. The data is stored this way, rather than in
-     * separate booleans, to make it easier to implement the save-and-restore
-     * semantics. The various k*ModeMask masks can be used to extract and modify
-     * the individual flags current states.
-     */
-    private int mDecFlags;
-
-    /**
-     * Saves away a snapshot of the DECSET flags. Used to implement save and
-     * restore escape sequences.
-     */
-    private int mSavedDecFlags;
-
-    // Modes set with Set Mode / Reset Mode
-
-    /**
-     * True if insert mode (as opposed to replace mode) is active. In insert
-     * mode new characters are inserted, pushing existing text to the right.
-     */
-    private boolean mInsertMode;
-
-    /**
-     * Automatic newline mode. Configures whether pressing return on the
-     * keyboard automatically generates a return as well. Not currently
-     * implemented.
-     */
-    private boolean mAutomaticNewlineMode;
-
-    /**
-     * An array of tab stops. mTabStop[i] is true if there is a tab stop set for
-     * column i.
-     */
-    private boolean[] mTabStop;
-
-    // The margins allow portions of the screen to be locked.
-
-    /**
-     * The top margin of the screen, for scrolling purposes. Ranges from 0 to
-     * mRows-2.
-     */
-    private int mTopMargin;
-
-    /**
-     * The bottom margin of the screen, for scrolling purposes. Ranges from
-     * mTopMargin + 2 to mRows. (Defines the first row after the scrolling
-     * region.
-     */
-    private int mBottomMargin;
-
-    /**
-     * True if the next character to be emitted will be automatically wrapped to
-     * the next line. Used to disambiguate the case where the cursor is
-     * positioned on column mColumns-1.
-     */
-    private boolean mAboutToAutoWrap;
-
-    /**
-     * Used for debugging, counts how many chars have been processed.
-     */
-    private int mProcessedCharCount;
-
-    /**
-     * Foreground color, 0..7, mask with 8 for bold
-     */
-    private int mForeColor;
-
-    /**
-     * Background color, 0..7, mask with 8 for underline
-     */
-    private int mBackColor;
-
-    private boolean mInverseColors;
-
-    private boolean mbKeypadApplicationMode;
-
-    private boolean mAlternateCharSet;
-
-    /**
-     * Construct a terminal emulator that uses the supplied screen
-     *
-     * @param screen the screen to render characters into.
-     * @param columns the number of columns to emulate
-     * @param rows the number of rows to emulate
-     * @param termOut the output file descriptor that talks to the pseudo-tty.
-     */
-    public TerminalEmulator(Screen screen, int columns, int rows,
-            FileOutputStream termOut) {
-        mScreen = screen;
-        mRows = rows;
-        mColumns = columns;
-        mTabStop = new boolean[mColumns];
-        mTermOut = termOut;
-        reset();
-    }
-
-    public void updateSize(int columns, int rows) {
-        if (mRows == rows && mColumns == columns) {
-            return;
-        }
-        String transcriptText = mScreen.getTranscriptText();
-
-        mScreen.resize(columns, rows, mForeColor, mBackColor);
-
-        if (mRows != rows) {
-            mRows = rows;
-            mTopMargin = 0;
-            mBottomMargin = mRows;
-        }
-        if (mColumns != columns) {
-            int oldColumns = mColumns;
-            mColumns = columns;
-            boolean[] oldTabStop = mTabStop;
-            mTabStop = new boolean[mColumns];
-            int toTransfer = Math.min(oldColumns, columns);
-            System.arraycopy(oldTabStop, 0, mTabStop, 0, toTransfer);
-            while (mCursorCol >= columns) {
-                mCursorCol -= columns;
-                mCursorRow = Math.min(mBottomMargin-1, mCursorRow + 1);
-            }
-        }
-        mCursorRow = 0;
-        mCursorCol = 0;
-        mAboutToAutoWrap = false;
-
-        int end = transcriptText.length()-1;
-        while ((end >= 0) && transcriptText.charAt(end) == '\n') {
-            end--;
-        }
-        for(int i = 0; i <= end; i++) {
-            byte c = (byte) transcriptText.charAt(i);
-            if (c == '\n') {
-                setCursorCol(0);
-                doLinefeed();
-            } else {
-                emit(c);
-            }
-        }
-    }
-
-    /**
-     * Get the cursor's current row.
-     *
-     * @return the cursor's current row.
-     */
-    public final int getCursorRow() {
-        return mCursorRow;
-    }
-
-    /**
-     * Get the cursor's current column.
-     *
-     * @return the cursor's current column.
-     */
-    public final int getCursorCol() {
-        return mCursorCol;
-    }
-
-    public final boolean getKeypadApplicationMode() {
-        return mbKeypadApplicationMode;
-    }
-
-    private void setDefaultTabStops() {
-        for (int i = 0; i < mColumns; i++) {
-            mTabStop[i] = (i & 7) == 0 && i != 0;
-        }
-    }
-
-    /**
-     * Accept bytes (typically from the pseudo-teletype) and process them.
-     *
-     * @param buffer a byte array containing the bytes to be processed
-     * @param base the first index of the array to process
-     * @param length the number of bytes in the array to process
-     */
-    public void append(byte[] buffer, int base, int length) {
-        for (int i = 0; i < length; i++) {
-            byte b = buffer[base + i];
-            try {
-                if (Term.LOG_CHARACTERS_FLAG) {
-                    char printableB = (char) b;
-                    if (b < 32 || b > 126) {
-                        printableB = ' ';
-                    }
-                    Log.w(Term.LOG_TAG, "'" + Character.toString(printableB)
-                            + "' (" + Integer.toString((int) b) + ")");
-                }
-                process(b);
-                mProcessedCharCount++;
-            } catch (Exception e) {
-                Log.e(Term.LOG_TAG, "Exception while processing character "
-                        + Integer.toString(mProcessedCharCount) + " code "
-                        + Integer.toString(b), e);
-            }
-        }
-    }
-
-    private void process(byte b) {
-        switch (b) {
-        case 0: // NUL
-            // Do nothing
-            break;
-
-        case 7: // BEL
-            // Do nothing
-            break;
-
-        case 8: // BS
-            setCursorCol(Math.max(0, mCursorCol - 1));
-            break;
-
-        case 9: // HT
-            // Move to next tab stop, but not past edge of screen
-            setCursorCol(nextTabStop(mCursorCol));
-            break;
-
-        case 13:
-            setCursorCol(0);
-            break;
-
-        case 10: // CR
-        case 11: // VT
-        case 12: // LF
-            doLinefeed();
-            break;
-
-        case 14: // SO:
-            setAltCharSet(true);
-            break;
-
-        case 15: // SI:
-            setAltCharSet(false);
-            break;
-
-
-        case 24: // CAN
-        case 26: // SUB
-            if (mEscapeState != ESC_NONE) {
-                mEscapeState = ESC_NONE;
-                emit((byte) 127);
-            }
-            break;
-
-        case 27: // ESC
-            // Always starts an escape sequence
-            startEscapeSequence(ESC);
-            break;
-
-        case (byte) 0x9b: // CSI
-            startEscapeSequence(ESC_LEFT_SQUARE_BRACKET);
-            break;
-
-        default:
-            mContinueSequence = false;
-            switch (mEscapeState) {
-            case ESC_NONE:
-                if (b >= 32) {
-                    emit(b);
-                }
-                break;
-
-            case ESC:
-                doEsc(b);
-                break;
-
-            case ESC_POUND:
-                doEscPound(b);
-                break;
-
-            case ESC_SELECT_LEFT_PAREN:
-                doEscSelectLeftParen(b);
-                break;
-
-            case ESC_SELECT_RIGHT_PAREN:
-                doEscSelectRightParen(b);
-                break;
-
-            case ESC_LEFT_SQUARE_BRACKET:
-                doEscLeftSquareBracket(b);
-                break;
-
-            case ESC_LEFT_SQUARE_BRACKET_QUESTION_MARK:
-                doEscLSBQuest(b);
-                break;
-
-            default:
-                unknownSequence(b);
-                break;
-            }
-            if (!mContinueSequence) {
-                mEscapeState = ESC_NONE;
-            }
-            break;
-        }
-    }
-
-    private void setAltCharSet(boolean alternateCharSet) {
-        mAlternateCharSet = alternateCharSet;
-    }
-
-    private int nextTabStop(int cursorCol) {
-        for (int i = cursorCol; i < mColumns; i++) {
-            if (mTabStop[i]) {
-                return i;
-            }
-        }
-        return mColumns - 1;
-    }
-
-    private void doEscLSBQuest(byte b) {
-        int mask = getDecFlagsMask(getArg0(0));
-        switch (b) {
-        case 'h': // Esc [ ? Pn h - DECSET
-            mDecFlags |= mask;
-            break;
-
-        case 'l': // Esc [ ? Pn l - DECRST
-            mDecFlags &= ~mask;
-            break;
-
-        case 'r': // Esc [ ? Pn r - restore
-            mDecFlags = (mDecFlags & ~mask) | (mSavedDecFlags & mask);
-            break;
-
-        case 's': // Esc [ ? Pn s - save
-            mSavedDecFlags = (mSavedDecFlags & ~mask) | (mDecFlags & mask);
-            break;
-
-        default:
-            parseArg(b);
-            break;
-        }
-
-        // 132 column mode
-        if ((mask & K_132_COLUMN_MODE_MASK) != 0) {
-            // We don't actually set 132 cols, but we do want the
-            // side effect of clearing the screen and homing the cursor.
-            blockClear(0, 0, mColumns, mRows);
-            setCursorRowCol(0, 0);
-        }
-
-        // origin mode
-        if ((mask & K_ORIGIN_MODE_MASK) != 0) {
-            // Home the cursor.
-            setCursorPosition(0, 0);
-        }
-    }
-
-    private int getDecFlagsMask(int argument) {
-        if (argument >= 1 && argument <= 9) {
-            return (1 << argument);
-        }
-
-        return 0;
-    }
-
-    private void startEscapeSequence(int escapeState) {
-        mEscapeState = escapeState;
-        mArgIndex = 0;
-        for (int j = 0; j < MAX_ESCAPE_PARAMETERS; j++) {
-            mArgs[j] = -1;
-        }
-    }
-
-    private void doLinefeed() {
-        int newCursorRow = mCursorRow + 1;
-        if (newCursorRow >= mBottomMargin) {
-            scroll();
-            newCursorRow = mBottomMargin - 1;
-        }
-        setCursorRow(newCursorRow);
-    }
-
-    private void continueSequence() {
-        mContinueSequence = true;
-    }
-
-    private void continueSequence(int state) {
-        mEscapeState = state;
-        mContinueSequence = true;
-    }
-
-    private void doEscSelectLeftParen(byte b) {
-        doSelectCharSet(true, b);
-    }
-
-    private void doEscSelectRightParen(byte b) {
-        doSelectCharSet(false, b);
-    }
-
-    private void doSelectCharSet(boolean isG0CharSet, byte b) {
-        switch (b) {
-        case 'A': // United Kingdom character set
-            break;
-        case 'B': // ASCII set
-            break;
-        case '0': // Special Graphics
-            break;
-        case '1': // Alternate character set
-            break;
-        case '2':
-            break;
-        default:
-            unknownSequence(b);
-        }
-    }
-
-    private void doEscPound(byte b) {
-        switch (b) {
-        case '8': // Esc # 8 - DECALN alignment test
-            mScreen.blockSet(0, 0, mColumns, mRows, 'E',
-                    getForeColor(), getBackColor());
-            break;
-
-        default:
-            unknownSequence(b);
-            break;
-        }
-    }
-
-    private void doEsc(byte b) {
-        switch (b) {
-        case '#':
-            continueSequence(ESC_POUND);
-            break;
-
-        case '(':
-            continueSequence(ESC_SELECT_LEFT_PAREN);
-            break;
-
-        case ')':
-            continueSequence(ESC_SELECT_RIGHT_PAREN);
-            break;
-
-        case '7': // DECSC save cursor
-            mSavedCursorRow = mCursorRow;
-            mSavedCursorCol = mCursorCol;
-            break;
-
-        case '8': // DECRC restore cursor
-            setCursorRowCol(mSavedCursorRow, mSavedCursorCol);
-            break;
-
-        case 'D': // INDEX
-            doLinefeed();
-            break;
-
-        case 'E': // NEL
-            setCursorCol(0);
-            doLinefeed();
-            break;
-
-        case 'F': // Cursor to lower-left corner of screen
-            setCursorRowCol(0, mBottomMargin - 1);
-            break;
-
-        case 'H': // Tab set
-            mTabStop[mCursorCol] = true;
-            break;
-
-        case 'M': // Reverse index
-            if (mCursorRow == 0) {
-                mScreen.blockCopy(0, mTopMargin + 1, mColumns, mBottomMargin
-                        - (mTopMargin + 1), 0, mTopMargin);
-                blockClear(0, mBottomMargin - 1, mColumns);
-            } else {
-                mCursorRow--;
-            }
-
-            break;
-
-        case 'N': // SS2
-            unimplementedSequence(b);
-            break;
-
-        case '0': // SS3
-            unimplementedSequence(b);
-            break;
-
-        case 'P': // Device control string
-            unimplementedSequence(b);
-            break;
-
-        case 'Z': // return terminal ID
-            sendDeviceAttributes();
-            break;
-
-        case '[':
-            continueSequence(ESC_LEFT_SQUARE_BRACKET);
-            break;
-
-        case '=': // DECKPAM
-            mbKeypadApplicationMode = true;
-            break;
-
-        case '>' : // DECKPNM
-            mbKeypadApplicationMode = false;
-            break;
-
-        default:
-            unknownSequence(b);
-            break;
-        }
-    }
-
-    private void doEscLeftSquareBracket(byte b) {
-        switch (b) {
-        case '@': // ESC [ Pn @ - ICH Insert Characters
-        {
-            int charsAfterCursor = mColumns - mCursorCol;
-            int charsToInsert = Math.min(getArg0(1), charsAfterCursor);
-            int charsToMove = charsAfterCursor - charsToInsert;
-            mScreen.blockCopy(mCursorCol, mCursorRow, charsToMove, 1,
-                    mCursorCol + charsToInsert, mCursorRow);
-            blockClear(mCursorCol, mCursorRow, charsToInsert);
-        }
-            break;
-
-        case 'A': // ESC [ Pn A - Cursor Up
-            setCursorRow(Math.max(mTopMargin, mCursorRow - getArg0(1)));
-            break;
-
-        case 'B': // ESC [ Pn B - Cursor Down
-            setCursorRow(Math.min(mBottomMargin - 1, mCursorRow + getArg0(1)));
-            break;
-
-        case 'C': // ESC [ Pn C - Cursor Right
-            setCursorCol(Math.min(mColumns - 1, mCursorCol + getArg0(1)));
-            break;
-
-        case 'D': // ESC [ Pn D - Cursor Left
-            setCursorCol(Math.max(0, mCursorCol - getArg0(1)));
-            break;
-
-        case 'G': // ESC [ Pn G - Cursor Horizontal Absolute
-            setCursorCol(Math.min(Math.max(1, getArg0(1)), mColumns) - 1);
-            break;
-
-        case 'H': // ESC [ Pn ; H - Cursor Position
-            setHorizontalVerticalPosition();
-            break;
-
-        case 'J': // ESC [ Pn J - Erase in Display
-            switch (getArg0(0)) {
-            case 0: // Clear below
-                blockClear(mCursorCol, mCursorRow, mColumns - mCursorCol);
-                blockClear(0, mCursorRow + 1, mColumns,
-                        mBottomMargin - (mCursorRow + 1));
-                break;
-
-            case 1: // Erase from the start of the screen to the cursor.
-                blockClear(0, mTopMargin, mColumns, mCursorRow - mTopMargin);
-                blockClear(0, mCursorRow, mCursorCol + 1);
-                break;
-
-            case 2: // Clear all
-                blockClear(0, mTopMargin, mColumns, mBottomMargin - mTopMargin);
-                break;
-
-            default:
-                unknownSequence(b);
-                break;
-            }
-            break;
-
-        case 'K': // ESC [ Pn K - Erase in Line
-            switch (getArg0(0)) {
-            case 0: // Clear to right
-                blockClear(mCursorCol, mCursorRow, mColumns - mCursorCol);
-                break;
-
-            case 1: // Erase start of line to cursor (including cursor)
-                blockClear(0, mCursorRow, mCursorCol + 1);
-                break;
-
-            case 2: // Clear whole line
-                blockClear(0, mCursorRow, mColumns);
-                break;
-
-            default:
-                unknownSequence(b);
-                break;
-            }
-            break;
-
-        case 'L': // Insert Lines
-        {
-            int linesAfterCursor = mBottomMargin - mCursorRow;
-            int linesToInsert = Math.min(getArg0(1), linesAfterCursor);
-            int linesToMove = linesAfterCursor - linesToInsert;
-            mScreen.blockCopy(0, mCursorRow, mColumns, linesToMove, 0,
-                    mCursorRow + linesToInsert);
-            blockClear(0, mCursorRow, mColumns, linesToInsert);
-        }
-            break;
-
-        case 'M': // Delete Lines
-        {
-            int linesAfterCursor = mBottomMargin - mCursorRow;
-            int linesToDelete = Math.min(getArg0(1), linesAfterCursor);
-            int linesToMove = linesAfterCursor - linesToDelete;
-            mScreen.blockCopy(0, mCursorRow + linesToDelete, mColumns,
-                    linesToMove, 0, mCursorRow);
-            blockClear(0, mCursorRow + linesToMove, mColumns, linesToDelete);
-        }
-            break;
-
-        case 'P': // Delete Characters
-        {
-            int charsAfterCursor = mColumns - mCursorCol;
-            int charsToDelete = Math.min(getArg0(1), charsAfterCursor);
-            int charsToMove = charsAfterCursor - charsToDelete;
-            mScreen.blockCopy(mCursorCol + charsToDelete, mCursorRow,
-                    charsToMove, 1, mCursorCol, mCursorRow);
-            blockClear(mCursorCol + charsToMove, mCursorRow, charsToDelete);
-        }
-            break;
-
-        case 'T': // Mouse tracking
-            unimplementedSequence(b);
-            break;
-
-        case '?': // Esc [ ? -- start of a private mode set
-            continueSequence(ESC_LEFT_SQUARE_BRACKET_QUESTION_MARK);
-            break;
-
-        case 'c': // Send device attributes
-            sendDeviceAttributes();
-            break;
-
-        case 'd': // ESC [ Pn d - Vert Position Absolute
-            setCursorRow(Math.min(Math.max(1, getArg0(1)), mRows) - 1);
-            break;
-
-        case 'f': // Horizontal and Vertical Position
-            setHorizontalVerticalPosition();
-            break;
-
-        case 'g': // Clear tab stop
-            switch (getArg0(0)) {
-            case 0:
-                mTabStop[mCursorCol] = false;
-                break;
-
-            case 3:
-                for (int i = 0; i < mColumns; i++) {
-                    mTabStop[i] = false;
-                }
-                break;
-
-            default:
-                // Specified to have no effect.
-                break;
-            }
-            break;
-
-        case 'h': // Set Mode
-            doSetMode(true);
-            break;
-
-        case 'l': // Reset Mode
-            doSetMode(false);
-            break;
-
-        case 'm': // Esc [ Pn m - character attributes.
-            selectGraphicRendition();
-            break;
-
-        case 'r': // Esc [ Pn ; Pn r - set top and bottom margins
-        {
-            // The top margin defaults to 1, the bottom margin
-            // (unusually for arguments) defaults to mRows.
-            //
-            // The escape sequence numbers top 1..23, but we
-            // number top 0..22.
-            // The escape sequence numbers bottom 2..24, and
-            // so do we (because we use a zero based numbering
-            // scheme, but we store the first line below the
-            // bottom-most scrolling line.
-            // As a result, we adjust the top line by -1, but
-            // we leave the bottom line alone.
-            //
-            // Also require that top + 2 <= bottom
-
-            int top = Math.max(0, Math.min(getArg0(1) - 1, mRows - 2));
-            int bottom = Math.max(top + 2, Math.min(getArg1(mRows), mRows));
-            mTopMargin = top;
-            mBottomMargin = bottom;
-
-            // The cursor is placed in the home position
-            setCursorRowCol(mTopMargin, 0);
-        }
-            break;
-
-        default:
-            parseArg(b);
-            break;
-        }
-    }
-
-    private void selectGraphicRendition() {
-        for (int i = 0; i <= mArgIndex; i++) {
-            int code = mArgs[i];
-            if ( code < 0) {
-                if (mArgIndex > 0) {
-                    continue;
-                } else {
-                    code = 0;
-                }
-            }
-            if (code == 0) { // reset
-                mInverseColors = false;
-                mForeColor = 7;
-                mBackColor = 0;
-            } else if (code == 1) { // bold
-                mForeColor |= 0x8;
-            } else if (code == 4) { // underscore
-                mBackColor |= 0x8;
-            } else if (code == 7) { // inverse
-                mInverseColors = true;
-            } else if (code >= 30 && code <= 37) { // foreground color
-                mForeColor = (mForeColor & 0x8) | (code - 30);
-            } else if (code >= 40 && code <= 47) { // background color
-                mBackColor = (mBackColor & 0x8) | (code - 40);
-            } else {
-                if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-                    Log.w(Term.LOG_TAG, String.format("SGR unknown code %d", code));
-                }
-            }
-        }
-    }
-
-    private void blockClear(int sx, int sy, int w) {
-        blockClear(sx, sy, w, 1);
-    }
-
-    private void blockClear(int sx, int sy, int w, int h) {
-        mScreen.blockSet(sx, sy, w, h, ' ', getForeColor(), getBackColor());
-    }
-
-    private int getForeColor() {
-        return mInverseColors ?
-                ((mBackColor & 0x7) | (mForeColor & 0x8)) : mForeColor;
-    }
-
-    private int getBackColor() {
-        return mInverseColors ?
-                ((mForeColor & 0x7) | (mBackColor & 0x8)) : mBackColor;
-    }
-
-    private void doSetMode(boolean newValue) {
-        int modeBit = getArg0(0);
-        switch (modeBit) {
-        case 4:
-            mInsertMode = newValue;
-            break;
-
-        case 20:
-            mAutomaticNewlineMode = newValue;
-            break;
-
-        default:
-            unknownParameter(modeBit);
-            break;
-        }
-    }
-
-    private void setHorizontalVerticalPosition() {
-
-        // Parameters are Row ; Column
-
-        setCursorPosition(getArg1(1) - 1, getArg0(1) - 1);
-    }
-
-    private void setCursorPosition(int x, int y) {
-        int effectiveTopMargin = 0;
-        int effectiveBottomMargin = mRows;
-        if ((mDecFlags & K_ORIGIN_MODE_MASK) != 0) {
-            effectiveTopMargin = mTopMargin;
-            effectiveBottomMargin = mBottomMargin;
-        }
-        int newRow =
-                Math.max(effectiveTopMargin, Math.min(effectiveTopMargin + y,
-                        effectiveBottomMargin - 1));
-        int newCol = Math.max(0, Math.min(x, mColumns - 1));
-        setCursorRowCol(newRow, newCol);
-    }
-
-    private void sendDeviceAttributes() {
-        // This identifies us as a DEC vt100 with advanced
-        // video options. This is what the xterm terminal
-        // emulator sends.
-        byte[] attributes =
-                {
-                /* VT100 */
-                 (byte) 27, (byte) '[', (byte) '?', (byte) '1',
-                 (byte) ';', (byte) '2', (byte) 'c'
-
-                /* VT220
-                (byte) 27, (byte) '[', (byte) '?', (byte) '6',
-                (byte) '0',  (byte) ';',
-                (byte) '1',  (byte) ';',
-                (byte) '2',  (byte) ';',
-                (byte) '6',  (byte) ';',
-                (byte) '8',  (byte) ';',
-                (byte) '9',  (byte) ';',
-                (byte) '1',  (byte) '5', (byte) ';',
-                (byte) 'c'
-                */
-                };
-
-        write(attributes);
-    }
-
-    /**
-     * Send data to the shell process
-     * @param data
-     */
-    private void write(byte[] data) {
-        try {
-            mTermOut.write(data);
-            mTermOut.flush();
-        } catch (IOException e) {
-            // Ignore exception
-            // We don't really care if the receiver isn't listening.
-            // We just make a best effort to answer the query.
-        }
-    }
-
-    private void scroll() {
-        mScreen.scroll(mTopMargin, mBottomMargin,
-                getForeColor(), getBackColor());
-    }
-
-    /**
-     * Process the next ASCII character of a parameter.
-     *
-     * @param b The next ASCII character of the paramater sequence.
-     */
-    private void parseArg(byte b) {
-        if (b >= '0' && b <= '9') {
-            if (mArgIndex < mArgs.length) {
-                int oldValue = mArgs[mArgIndex];
-                int thisDigit = b - '0';
-                int value;
-                if (oldValue >= 0) {
-                    value = oldValue * 10 + thisDigit;
-                } else {
-                    value = thisDigit;
-                }
-                mArgs[mArgIndex] = value;
-            }
-            continueSequence();
-        } else if (b == ';') {
-            if (mArgIndex < mArgs.length) {
-                mArgIndex++;
-            }
-            continueSequence();
-        } else {
-            unknownSequence(b);
-        }
-    }
-
-    private int getArg0(int defaultValue) {
-        return getArg(0, defaultValue);
-    }
-
-    private int getArg1(int defaultValue) {
-        return getArg(1, defaultValue);
-    }
-
-    private int getArg(int index, int defaultValue) {
-        int result = mArgs[index];
-        if (result < 0) {
-            result = defaultValue;
-        }
-        return result;
-    }
-
-    private void unimplementedSequence(byte b) {
-        if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-            logError("unimplemented", b);
-        }
-        finishSequence();
-    }
-
-    private void unknownSequence(byte b) {
-        if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-            logError("unknown", b);
-        }
-        finishSequence();
-    }
-
-    private void unknownParameter(int parameter) {
-        if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-            StringBuilder buf = new StringBuilder();
-            buf.append("Unknown parameter");
-            buf.append(parameter);
-            logError(buf.toString());
-        }
-    }
-
-    private void logError(String errorType, byte b) {
-        if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-            StringBuilder buf = new StringBuilder();
-            buf.append(errorType);
-            buf.append(" sequence ");
-            buf.append(" EscapeState: ");
-            buf.append(mEscapeState);
-            buf.append(" char: '");
-            buf.append((char) b);
-            buf.append("' (");
-            buf.append((int) b);
-            buf.append(")");
-            boolean firstArg = true;
-            for (int i = 0; i <= mArgIndex; i++) {
-                int value = mArgs[i];
-                if (value >= 0) {
-                    if (firstArg) {
-                        firstArg = false;
-                        buf.append("args = ");
-                    }
-                    buf.append(String.format("%d; ", value));
-                }
-            }
-            logError(buf.toString());
-        }
-    }
-
-    private void logError(String error) {
-        if (Term.LOG_UNKNOWN_ESCAPE_SEQUENCES) {
-            Log.e(Term.LOG_TAG, error);
-        }
-        finishSequence();
-    }
-
-    private void finishSequence() {
-        mEscapeState = ESC_NONE;
-    }
-
-    private boolean autoWrapEnabled() {
-        // Always enable auto wrap, because it's useful on a small screen
-        return true;
-        // return (mDecFlags & K_WRAPAROUND_MODE_MASK) != 0;
-    }
-
-    /**
-     * Send an ASCII character to the screen.
-     *
-     * @param b the ASCII character to display.
-     */
-    private void emit(byte b) {
-        boolean autoWrap = autoWrapEnabled();
-
-        if (autoWrap) {
-            if (mCursorCol == mColumns - 1 && mAboutToAutoWrap) {
-                mScreen.setLineWrap(mCursorRow);
-                mCursorCol = 0;
-                if (mCursorRow + 1 < mBottomMargin) {
-                    mCursorRow++;
-                } else {
-                    scroll();
-                }
-            }
-        }
-
-        if (mInsertMode) { // Move character to right one space
-            int destCol = mCursorCol + 1;
-            if (destCol < mColumns) {
-                mScreen.blockCopy(mCursorCol, mCursorRow, mColumns - destCol,
-                        1, destCol, mCursorRow);
-            }
-        }
-
-        mScreen.set(mCursorCol, mCursorRow, b, getForeColor(), getBackColor());
-
-        if (autoWrap) {
-            mAboutToAutoWrap = (mCursorCol == mColumns - 1);
-        }
-
-        mCursorCol = Math.min(mCursorCol + 1, mColumns - 1);
-    }
-
-    private void setCursorRow(int row) {
-        mCursorRow = row;
-        mAboutToAutoWrap = false;
-    }
-
-    private void setCursorCol(int col) {
-        mCursorCol = col;
-        mAboutToAutoWrap = false;
-    }
-
-    private void setCursorRowCol(int row, int col) {
-        mCursorRow = Math.min(row, mRows-1);
-        mCursorCol = Math.min(col, mColumns-1);
-        mAboutToAutoWrap = false;
-    }
-
-    /**
-     * Reset the terminal emulator to its initial state.
-     */
-    public void reset() {
-        mCursorRow = 0;
-        mCursorCol = 0;
-        mArgIndex = 0;
-        mContinueSequence = false;
-        mEscapeState = ESC_NONE;
-        mSavedCursorRow = 0;
-        mSavedCursorCol = 0;
-        mDecFlags = 0;
-        mSavedDecFlags = 0;
-        mInsertMode = false;
-        mAutomaticNewlineMode = false;
-        mTopMargin = 0;
-        mBottomMargin = mRows;
-        mAboutToAutoWrap = false;
-        mForeColor = 7;
-        mBackColor = 0;
-        mInverseColors = false;
-        mbKeypadApplicationMode = false;
-        mAlternateCharSet = false;
-        // mProcessedCharCount is preserved unchanged.
-        setDefaultTabStops();
-        blockClear(0, 0, mColumns, mRows);
-    }
-
-    public String getTranscriptText() {
-        return mScreen.getTranscriptText();
-    }
-}
-
-/**
- * Text renderer interface
- */
-
-interface TextRenderer {
-    int getCharacterWidth();
-    int getCharacterHeight();
-    void drawTextRun(Canvas canvas, float x, float y,
-            int lineOffset, char[] text,
-            int index, int count, boolean cursor, int foreColor, int backColor);
-}
-
-abstract class BaseTextRenderer implements TextRenderer {
-    protected int[] mForePaint = {
-            0xff000000, // Black
-            0xffff0000, // Red
-            0xff00ff00, // green
-            0xffffff00, // yellow
-            0xff0000ff, // blue
-            0xffff00ff, // magenta
-            0xff00ffff, // cyan
-            0xffffffff  // white -- is overridden by constructor
-    };
-    protected int[] mBackPaint = {
-            0xff000000, // Black -- is overridden by constructor
-            0xffcc0000, // Red
-            0xff00cc00, // green
-            0xffcccc00, // yellow
-            0xff0000cc, // blue
-            0xffff00cc, // magenta
-            0xff00cccc, // cyan
-            0xffffffff  // white
-    };
-    protected final static int mCursorPaint = 0xff808080;
-
-    public BaseTextRenderer(int forePaintColor, int backPaintColor) {
-        mForePaint[7] = forePaintColor;
-        mBackPaint[0] = backPaintColor;
-
-    }
-}
-
-class Bitmap4x8FontRenderer extends BaseTextRenderer {
-    private final static int kCharacterWidth = 4;
-    private final static int kCharacterHeight = 8;
-    private Bitmap mFont;
-    private int mCurrentForeColor;
-    private int mCurrentBackColor;
-    private float[] mColorMatrix;
-    private Paint mPaint;
-    private static final float BYTE_SCALE = 1.0f / 255.0f;
-
-    public Bitmap4x8FontRenderer(Resources resources,
-            int forePaintColor, int backPaintColor) {
-        super(forePaintColor, backPaintColor);
-        mFont = BitmapFactory.decodeResource(resources,
-                R.drawable.atari_small);
-        mPaint = new Paint();
-        mPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
-    }
-
-    public int getCharacterWidth() {
-        return kCharacterWidth;
-    }
-
-    public int getCharacterHeight() {
-        return kCharacterHeight;
-    }
-
-    public void drawTextRun(Canvas canvas, float x, float y,
-            int lineOffset, char[] text, int index, int count,
-            boolean cursor, int foreColor, int backColor) {
-        setColorMatrix(mForePaint[foreColor & 7],
-                cursor ? mCursorPaint : mBackPaint[backColor & 7]);
-        int destX = (int) x + kCharacterWidth * lineOffset;
-        int destY = (int) y;
-        Rect srcRect = new Rect();
-        Rect destRect = new Rect();
-        destRect.top = (destY - kCharacterHeight);
-        destRect.bottom = destY;
-        for(int i = 0; i < count; i++) {
-            char c = text[i + index];
-            if ((cursor || (c != 32)) && (c < 128)) {
-                int cellX = c & 31;
-                int cellY = (c >> 5) & 3;
-                int srcX = cellX * kCharacterWidth;
-                int srcY = cellY * kCharacterHeight;
-                srcRect.set(srcX, srcY,
-                        srcX + kCharacterWidth, srcY + kCharacterHeight);
-                destRect.left = destX;
-                destRect.right = destX + kCharacterWidth;
-                canvas.drawBitmap(mFont, srcRect, destRect, mPaint);
-            }
-            destX += kCharacterWidth;
-        }
-    }
-
-    private void setColorMatrix(int foreColor, int backColor) {
-        if ((foreColor != mCurrentForeColor)
-                || (backColor != mCurrentBackColor)
-                || (mColorMatrix == null)) {
-            mCurrentForeColor = foreColor;
-            mCurrentBackColor = backColor;
-            if (mColorMatrix == null) {
-                mColorMatrix = new float[20];
-                mColorMatrix[18] = 1.0f; // Just copy Alpha
-            }
-            for (int component = 0; component < 3; component++) {
-                int rightShift = (2 - component) << 3;
-                int fore = 0xff & (foreColor >> rightShift);
-                int back = 0xff & (backColor >> rightShift);
-                int delta = back - fore;
-                mColorMatrix[component * 6] = delta * BYTE_SCALE;
-                mColorMatrix[component * 5 + 4] = fore;
-            }
-            mPaint.setColorFilter(new ColorMatrixColorFilter(mColorMatrix));
-        }
-    }
-}
-
-class PaintRenderer extends BaseTextRenderer {
-    public PaintRenderer(int fontSize, int forePaintColor, int backPaintColor) {
-        super(forePaintColor, backPaintColor);
-        mTextPaint = new Paint();
-        mTextPaint.setTypeface(Typeface.MONOSPACE);
-        mTextPaint.setAntiAlias(true);
-        mTextPaint.setTextSize(fontSize);
-
-        mCharHeight = (int) Math.ceil(mTextPaint.getFontSpacing());
-        mCharAscent = (int) Math.ceil(mTextPaint.ascent());
-        mCharDescent = mCharHeight + mCharAscent;
-        mCharWidth = (int) mTextPaint.measureText(EXAMPLE_CHAR, 0, 1);
-    }
-
-    public void drawTextRun(Canvas canvas, float x, float y, int lineOffset,
-            char[] text, int index, int count,
-            boolean cursor, int foreColor, int backColor) {
-        if (cursor) {
-            mTextPaint.setColor(mCursorPaint);
-        } else {
-            mTextPaint.setColor(mBackPaint[backColor & 0x7]);
-        }
-        float left = x + lineOffset * mCharWidth;
-        canvas.drawRect(left, y + mCharAscent,
-                left + count * mCharWidth, y + mCharDescent,
-                mTextPaint);
-        boolean bold = ( foreColor & 0x8 ) != 0;
-        boolean underline = (backColor & 0x8) != 0;
-        if (bold) {
-            mTextPaint.setFakeBoldText(true);
-        }
-        if (underline) {
-            mTextPaint.setUnderlineText(true);
-        }
-        mTextPaint.setColor(mForePaint[foreColor & 0x7]);
-        canvas.drawText(text, index, count, left, y, mTextPaint);
-        if (bold) {
-            mTextPaint.setFakeBoldText(false);
-        }
-        if (underline) {
-            mTextPaint.setUnderlineText(false);
-        }
-    }
-
-    public int getCharacterHeight() {
-        return mCharHeight;
-    }
-
-    public int getCharacterWidth() {
-        return mCharWidth;
-    }
-
-
-    private Paint mTextPaint;
-    private int mCharWidth;
-    private int mCharHeight;
-    private int mCharAscent;
-    private int mCharDescent;
-    private static final char[] EXAMPLE_CHAR = {'X'};
-    }
-
-/**
- * A multi-thread-safe produce-consumer byte array.
- * Only allows one producer and one consumer.
- */
-
-class ByteQueue {
-    public ByteQueue(int size) {
-        mBuffer = new byte[size];
-    }
-
-    public int getBytesAvailable() {
-        synchronized(this) {
-            return mStoredBytes;
-        }
-    }
-
-    public int read(byte[] buffer, int offset, int length)
-        throws InterruptedException {
-        if (length + offset > buffer.length) {
-            throw
-                new IllegalArgumentException("length + offset > buffer.length");
-        }
-        if (length < 0) {
-            throw
-            new IllegalArgumentException("length < 0");
-
-        }
-        if (length == 0) {
-            return 0;
-        }
-        synchronized(this) {
-            while (mStoredBytes == 0) {
-                wait();
-            }
-            int totalRead = 0;
-            int bufferLength = mBuffer.length;
-            boolean wasFull = bufferLength == mStoredBytes;
-            while (length > 0 && mStoredBytes > 0) {
-                int oneRun = Math.min(bufferLength - mHead, mStoredBytes);
-                int bytesToCopy = Math.min(length, oneRun);
-                System.arraycopy(mBuffer, mHead, buffer, offset, bytesToCopy);
-                mHead += bytesToCopy;
-                if (mHead >= bufferLength) {
-                    mHead = 0;
-                }
-                mStoredBytes -= bytesToCopy;
-                length -= bytesToCopy;
-                offset += bytesToCopy;
-                totalRead += bytesToCopy;
-            }
-            if (wasFull) {
-                notify();
-            }
-            return totalRead;
-        }
-    }
-
-    public void write(byte[] buffer, int offset, int length)
-    throws InterruptedException {
-        if (length + offset > buffer.length) {
-            throw
-                new IllegalArgumentException("length + offset > buffer.length");
-        }
-        if (length < 0) {
-            throw
-            new IllegalArgumentException("length < 0");
-
-        }
-        if (length == 0) {
-            return;
-        }
-        synchronized(this) {
-            int bufferLength = mBuffer.length;
-            boolean wasEmpty = mStoredBytes == 0;
-            while (length > 0) {
-                while(bufferLength == mStoredBytes) {
-                    wait();
-                }
-                int tail = mHead + mStoredBytes;
-                int oneRun;
-                if (tail >= bufferLength) {
-                    tail = tail - bufferLength;
-                    oneRun = mHead - tail;
-                } else {
-                    oneRun = bufferLength - tail;
-                }
-                int bytesToCopy = Math.min(oneRun, length);
-                System.arraycopy(buffer, offset, mBuffer, tail, bytesToCopy);
-                offset += bytesToCopy;
-                mStoredBytes += bytesToCopy;
-                length -= bytesToCopy;
-            }
-            if (wasEmpty) {
-                notify();
-            }
-        }
-    }
-
-    private byte[] mBuffer;
-    private int mHead;
-    private int mStoredBytes;
-}
-/**
- * A view on a transcript and a terminal emulator. Displays the text of the
- * transcript and the current cursor position of the terminal emulator.
- */
-class EmulatorView extends View implements GestureDetector.OnGestureListener {
-
-    /**
-     * We defer some initialization until we have been layed out in the view
-     * hierarchy. The boolean tracks when we know what our size is.
-     */
-    private boolean mKnownSize;
-
-    /**
-     * Our transcript. Contains the screen and the transcript.
-     */
-    private TranscriptScreen mTranscriptScreen;
-
-    /**
-     * Number of rows in the transcript.
-     */
-    private static final int TRANSCRIPT_ROWS = 10000;
-
-    /**
-     * Total width of each character, in pixels
-     */
-    private int mCharacterWidth;
-
-    /**
-     * Total height of each character, in pixels
-     */
-    private int mCharacterHeight;
-
-    /**
-     * Used to render text
-     */
-    private TextRenderer mTextRenderer;
-
-    /**
-     * Text size. Zero means 4 x 8 font.
-     */
-    private int mTextSize;
-
-    /**
-     * Foreground color.
-     */
-    private int mForeground;
-
-    /**
-     * Background color.
-     */
-    private int mBackground;
-
-    /**
-     * Used to paint the cursor
-     */
-    private Paint mCursorPaint;
-
-    private Paint mBackgroundPaint;
-
-    /**
-     * Our terminal emulator. We use this to get the current cursor position.
-     */
-    private TerminalEmulator mEmulator;
-
-    /**
-     * The number of rows of text to display.
-     */
-    private int mRows;
-
-    /**
-     * The number of columns of text to display.
-     */
-    private int mColumns;
-
-    /**
-     * The number of columns that are visible on the display.
-     */
-
-    private int mVisibleColumns;
-
-    /**
-     * The top row of text to display. Ranges from -activeTranscriptRows to 0
-     */
-    private int mTopRow;
-
-    private int mLeftColumn;
-
-    private FileDescriptor mTermFd;
-    /**
-     * Used to receive data from the remote process.
-     */
-    private FileInputStream mTermIn;
-
-    private FileOutputStream mTermOut;
-
-    private ByteQueue mByteQueue;
-
-    /**
-     * Used to temporarily hold data received from the remote process. Allocated
-     * once and used permanently to minimize heap thrashing.
-     */
-    private byte[] mReceiveBuffer;
-
-    /**
-     * Our private message id, which we use to receive new input from the
-     * remote process.
-     */
-    private static final int UPDATE = 1;
-
-    /**
-     * Thread that polls for input from the remote process
-     */
-
-    private Thread mPollingThread;
-
-    private GestureDetector mGestureDetector;
-    private float mScrollRemainder;
-
-    /**
-     * Our message handler class. Implements a periodic callback.
-     */
-    private final Handler mHandler = new Handler() {
-        /**
-         * Handle the callback message. Call our enclosing class's update
-         * method.
-         *
-         * @param msg The callback message.
-         */
-        public void handleMessage(Message msg) {
-            if (msg.what == UPDATE) {
-                update();
-            }
-        }
-    };
-
-    public EmulatorView(Context context) {
-        super(context);
-        commonConstructor();
-    }
-
-    public void setColors(int foreground, int background) {
-        mForeground = foreground;
-        mBackground = background;
-        updateText();
-    }
-
-    public String getTranscriptText() {
-        return mEmulator.getTranscriptText();
-    }
-
-    public void resetTerminal() {
-        mEmulator.reset();
-        invalidate();
-    }
-
-    @Override
-    public boolean onCheckIsTextEditor() {
-        return true;
-    }
-
-    @Override
-    public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
-        return new BaseInputConnection(this, false) {
-
-            public boolean beginBatchEdit() {
-                return true;
-            }
-
-            public boolean clearMetaKeyStates(int states) {
-                return true;
-            }
-
-            public boolean commitCompletion(CompletionInfo text) {
-                return true;
-            }
-
-            public boolean commitText(CharSequence text, int newCursorPosition) {
-                sendText(text);
-                return true;
-            }
-
-            public boolean deleteSurroundingText(int leftLength, int rightLength) {
-                return true;
-            }
-
-            public boolean endBatchEdit() {
-                return true;
-            }
-
-            public boolean finishComposingText() {
-                return true;
-            }
-
-            public int getCursorCapsMode(int reqModes) {
-                return 0;
-            }
-
-            public ExtractedText getExtractedText(ExtractedTextRequest request,
-                    int flags) {
-                return null;
-            }
-
-            public CharSequence getTextAfterCursor(int n, int flags) {
-                return null;
-            }
-
-            public CharSequence getTextBeforeCursor(int n, int flags) {
-                return null;
-            }
-
-            public boolean hideStatusIcon() {
-                return true;
-            }
-
-            public boolean performContextMenuAction(int id) {
-                return true;
-            }
-
-            public boolean performPrivateCommand(String action, Bundle data) {
-                return true;
-            }
-
-            public boolean sendKeyEvent(KeyEvent event) {
-                switch(event.getKeyCode()) {
-                case KeyEvent.KEYCODE_ENTER:
-                    sendChar('\r');
-                    break;
-                case KeyEvent.KEYCODE_DEL:
-                    sendChar(127);
-                    break;
-                }
-                return true;
-            }
-
-            public boolean setComposingText(CharSequence text, int newCursorPosition) {
-                return true;
-            }
-
-            public boolean setSelection(int start, int end) {
-                return true;
-            }
-
-            public boolean showStatusIcon(String packageName, int resId) {
-                return true;
-            }
-
-            private void sendChar(int c) {
-                try {
-                    mTermOut.write(c);
-                } catch (IOException ex) {
-
-                }
-            }
-            private void sendText(CharSequence text) {
-                int n = text.length();
-                try {
-                    for(int i = 0; i < n; i++) {
-                        char c = text.charAt(i);
-                        mTermOut.write(c);
-                    }
-                } catch (IOException e) {
-                }
-            }
-        };
-    }
-
-    public boolean getKeypadApplicationMode() {
-        return mEmulator.getKeypadApplicationMode();
-    }
-
-    public EmulatorView(Context context, AttributeSet attrs) {
-        this(context, attrs, 0);
-    }
-
-    public EmulatorView(Context context, AttributeSet attrs,
-            int defStyle) {
-        super(context, attrs, defStyle);
-        TypedArray a =
-                context.obtainStyledAttributes(android.R.styleable.View);
-        initializeScrollbars(a);
-        a.recycle();
-        commonConstructor();
-    }
-
-    private void commonConstructor() {
-        mTextRenderer = null;
-        mCursorPaint = new Paint();
-        mCursorPaint.setARGB(255,128,128,128);
-        mBackgroundPaint = new Paint();
-        mTopRow = 0;
-        mLeftColumn = 0;
-        mGestureDetector = new GestureDetector(this);
-        mGestureDetector.setIsLongpressEnabled(false);
-        setVerticalScrollBarEnabled(true);
-    }
-
-    @Override
-    protected int computeVerticalScrollRange() {
-        return mTranscriptScreen.getActiveRows();
-    }
-
-    @Override
-    protected int computeVerticalScrollExtent() {
-        return mRows;
-    }
-
-    @Override
-    protected int computeVerticalScrollOffset() {
-        return mTranscriptScreen.getActiveRows() + mTopRow - mRows;
-    }
-
-    /**
-     * Call this to initialize the view.
-     *
-     * @param termFd the file descriptor
-     * @param termOut the output stream for the pseudo-teletype
-     */
-    public void initialize(FileDescriptor termFd, FileOutputStream termOut) {
-        mTermOut = termOut;
-        mTermFd = termFd;
-        mTextSize = 10;
-        mForeground = Term.WHITE;
-        mBackground = Term.BLACK;
-        updateText();
-        mTermIn = new FileInputStream(mTermFd);
-        mReceiveBuffer = new byte[4 * 1024];
-        mByteQueue = new ByteQueue(4 * 1024);
-    }
-
-    /**
-     * Accept a sequence of bytes (typically from the pseudo-tty) and process
-     * them.
-     *
-     * @param buffer a byte array containing bytes to be processed
-     * @param base the index of the first byte in the buffer to process
-     * @param length the number of bytes to process
-     */
-    public void append(byte[] buffer, int base, int length) {
-        mEmulator.append(buffer, base, length);
-        ensureCursorVisible();
-        invalidate();
-    }
-
-    /**
-     * Page the terminal view (scroll it up or down by delta screenfulls.)
-     *
-     * @param delta the number of screens to scroll. Positive means scroll down,
-     *        negative means scroll up.
-     */
-    public void page(int delta) {
-        mTopRow =
-                Math.min(0, Math.max(-(mTranscriptScreen
-                        .getActiveTranscriptRows()), mTopRow + mRows * delta));
-        invalidate();
-    }
-
-    /**
-     * Page the terminal view horizontally.
-     *
-     * @param deltaColumns the number of columns to scroll. Positive scrolls to
-     *        the right.
-     */
-    public void pageHorizontal(int deltaColumns) {
-        mLeftColumn =
-                Math.max(0, Math.min(mLeftColumn + deltaColumns, mColumns
-                        - mVisibleColumns));
-        invalidate();
-    }
-
-    /**
-     * Sets the text size, which in turn sets the number of rows and columns
-     *
-     * @param fontSize the new font size, in pixels.
-     */
-    public void setTextSize(int fontSize) {
-        mTextSize = fontSize;
-        updateText();
-    }
-
-    // Begin GestureDetector.OnGestureListener methods
-
-    public boolean onSingleTapUp(MotionEvent e) {
-        return true;
-    }
-
-    public void onLongPress(MotionEvent e) {
-    }
-
-    public boolean onScroll(MotionEvent e1, MotionEvent e2,
-            float distanceX, float distanceY) {
-        distanceY += mScrollRemainder;
-        int deltaRows = (int) (distanceY / mCharacterHeight);
-        mScrollRemainder = distanceY - deltaRows * mCharacterHeight;
-        mTopRow =
-            Math.min(0, Math.max(-(mTranscriptScreen
-                    .getActiveTranscriptRows()), mTopRow + deltaRows));
-        invalidate();
-
-        return true;
-   }
-
-    public void onSingleTapConfirmed(MotionEvent e) {
-    }
-
-    public boolean onJumpTapDown(MotionEvent e1, MotionEvent e2) {
-       // Scroll to bottom
-       mTopRow = 0;
-       invalidate();
-       return true;
-    }
-
-    public boolean onJumpTapUp(MotionEvent e1, MotionEvent e2) {
-        // Scroll to top
-        mTopRow = -mTranscriptScreen.getActiveTranscriptRows();
-        invalidate();
-        return true;
-    }
-
-    public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX,
-            float velocityY) {
-        // TODO: add animation man's (non animated) fling
-        mScrollRemainder = 0.0f;
-        onScroll(e1, e2, 2 * velocityX, -2 * velocityY);
-        return true;
-    }
-
-    public void onShowPress(MotionEvent e) {
-    }
-
-    public boolean onDown(MotionEvent e) {
-        mScrollRemainder = 0.0f;
-        return true;
-    }
-
-    // End GestureDetector.OnGestureListener methods
-
-    @Override public boolean onTouchEvent(MotionEvent ev) {
-        return mGestureDetector.onTouchEvent(ev);
-    }
-
-    private void updateText() {
-        if (mTextSize > 0) {
-            mTextRenderer = new PaintRenderer(mTextSize, mForeground,
-                    mBackground);
-        }
-        else {
-            mTextRenderer = new Bitmap4x8FontRenderer(getResources(),
-                    mForeground, mBackground);
-        }
-        mBackgroundPaint.setColor(mBackground);
-        mCharacterWidth = mTextRenderer.getCharacterWidth();
-        mCharacterHeight = mTextRenderer.getCharacterHeight();
-
-        if (mKnownSize) {
-            updateSize(getWidth(), getHeight());
-        }
-    }
-
-    @Override
-    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
-        updateSize(w, h);
-        if (!mKnownSize) {
-            mKnownSize = true;
-
-            // Set up a thread to read input from the
-            // pseudo-teletype:
-
-            mPollingThread = new Thread(new Runnable() {
-
-                public void run() {
-                    try {
-                        while(true) {
-                            int read = mTermIn.read(mBuffer);
-                            mByteQueue.write(mBuffer, 0, read);
-                            mHandler.sendMessage(
-                                    mHandler.obtainMessage(UPDATE));
-                        }
-                    } catch (IOException e) {
-                    } catch (InterruptedException e) {
-                    }
-                }
-                private byte[] mBuffer = new byte[4096];
-            });
-            mPollingThread.setName("Input reader");
-            mPollingThread.start();
-        }
-    }
-
-    private void updateSize(int w, int h) {
-        mColumns = w / mCharacterWidth;
-        mRows = h / mCharacterHeight;
-
-        // Inform the attached pty of our new size:
-        Exec.setPtyWindowSize(mTermFd, mRows, mColumns, w, h);
-
-
-        if (mTranscriptScreen != null) {
-            mEmulator.updateSize(mColumns, mRows);
-        } else {
-            mTranscriptScreen =
-                    new TranscriptScreen(mColumns, TRANSCRIPT_ROWS, mRows, 0, 7);
-            mEmulator =
-                    new TerminalEmulator(mTranscriptScreen, mColumns, mRows,
-                            mTermOut);
-        }
-
-        // Reset our paging:
-        mTopRow = 0;
-        mLeftColumn = 0;
-
-        invalidate();
-    }
-
-    void updateSize() {
-        if (mKnownSize) {
-            updateSize(getWidth(), getHeight());
-        }
-    }
-
-    /**
-     * Look for new input from the ptty, send it to the terminal emulator.
-     */
-    private void update() {
-        int bytesAvailable = mByteQueue.getBytesAvailable();
-        int bytesToRead = Math.min(bytesAvailable, mReceiveBuffer.length);
-        try {
-            int bytesRead = mByteQueue.read(mReceiveBuffer, 0, bytesToRead);
-            append(mReceiveBuffer, 0, bytesRead);
-        } catch (InterruptedException e) {
-        }
-    }
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-        int w = getWidth();
-        int h = getHeight();
-        canvas.drawRect(0, 0, w, h, mBackgroundPaint);
-        mVisibleColumns = w / mCharacterWidth;
-        float x = -mLeftColumn * mCharacterWidth;
-        float y = mCharacterHeight;
-        int endLine = mTopRow + mRows;
-        int cx = mEmulator.getCursorCol();
-        int cy = mEmulator.getCursorRow();
-        for (int i = mTopRow; i < endLine; i++) {
-            int cursorX = -1;
-            if (i == cy) {
-                cursorX = cx;
-            }
-            mTranscriptScreen.drawText(i, canvas, x, y, mTextRenderer, cursorX);
-            y += mCharacterHeight;
-        }
-    }
-
-    private void ensureCursorVisible() {
-        mTopRow = 0;
-        if (mVisibleColumns > 0) {
-            int cx = mEmulator.getCursorCol();
-            int visibleCursorX = mEmulator.getCursorCol() - mLeftColumn;
-            if (visibleCursorX < 0) {
-                mLeftColumn = cx;
-            } else if (visibleCursorX >= mVisibleColumns) {
-                mLeftColumn = (cx - mVisibleColumns) + 1;
-            }
-        }
-    }
-}
-
-
-/**
- * An ASCII key listener. Supports control characters and escape. Keeps track of
- * the current state of the alt, shift, and control keys.
- */
-class TermKeyListener {
-    /**
-     * The state engine for a modifier key. Can be pressed, released, locked,
-     * and so on.
-     *
-     */
-    private class ModifierKey {
-
-        private int mState;
-
-        private static final int UNPRESSED = 0;
-
-        private static final int PRESSED = 1;
-
-        private static final int RELEASED = 2;
-
-        private static final int USED = 3;
-
-        private static final int LOCKED = 4;
-
-        /**
-         * Construct a modifier key. UNPRESSED by default.
-         *
-         */
-        public ModifierKey() {
-            mState = UNPRESSED;
-        }
-
-        public void onPress() {
-            switch (mState) {
-            case PRESSED:
-                // This is a repeat before use
-                break;
-            case RELEASED:
-                mState = LOCKED;
-                break;
-            case USED:
-                // This is a repeat after use
-                break;
-            case LOCKED:
-                mState = UNPRESSED;
-                break;
-            default:
-                mState = PRESSED;
-                break;
-            }
-        }
-
-        public void onRelease() {
-            switch (mState) {
-            case USED:
-                mState = UNPRESSED;
-                break;
-            case PRESSED:
-                mState = RELEASED;
-                break;
-            default:
-                // Leave state alone
-                break;
-            }
-        }
-
-        public void adjustAfterKeypress() {
-            switch (mState) {
-            case PRESSED:
-                mState = USED;
-                break;
-            case RELEASED:
-                mState = UNPRESSED;
-                break;
-            default:
-                // Leave state alone
-                break;
-            }
-        }
-
-        public boolean isActive() {
-            return mState != UNPRESSED;
-        }
-    }
-
-    private ModifierKey mAltKey = new ModifierKey();
-
-    private ModifierKey mCapKey = new ModifierKey();
-
-    private ModifierKey mControlKey = new ModifierKey();
-
-    /**
-     * Construct a term key listener.
-     *
-     */
-    public TermKeyListener() {
-    }
-
-    public void handleControlKey(boolean down) {
-        if (down) {
-            mControlKey.onPress();
-        } else {
-            mControlKey.onRelease();
-        }
-    }
-
-    /**
-     * Handle a keyDown event.
-     *
-     * @param keyCode the keycode of the keyDown event
-     * @return the ASCII byte to transmit to the pseudo-teletype, or -1 if this
-     *         event does not produce an ASCII byte.
-     */
-    public int keyDown(int keyCode, KeyEvent event) {
-        int result = -1;
-        switch (keyCode) {
-        case KeyEvent.KEYCODE_ALT_RIGHT:
-        case KeyEvent.KEYCODE_ALT_LEFT:
-            mAltKey.onPress();
-            break;
-
-        case KeyEvent.KEYCODE_SHIFT_LEFT:
-        case KeyEvent.KEYCODE_SHIFT_RIGHT:
-            mCapKey.onPress();
-            break;
-
-        case KeyEvent.KEYCODE_ENTER:
-            // Convert newlines into returns. The vt100 sends a
-            // '\r' when the 'Return' key is pressed, but our
-            // KeyEvent translates this as a '\n'.
-            result = '\r';
-            break;
-
-        case KeyEvent.KEYCODE_DEL:
-            // Convert DEL into 127 (instead of 8)
-            result = 127;
-            break;
-
-        default: {
-            result = event.getUnicodeChar(
-                   (mCapKey.isActive() ? KeyEvent.META_SHIFT_ON : 0) |
-                   (mAltKey.isActive() ? KeyEvent.META_ALT_ON : 0));
-            break;
-            }
-        }
-
-        if (mControlKey.isActive()) {
-            // Search is the control key.
-            if (result >= 'a' && result <= 'z') {
-                result = (char) (result - 'a' + '\001');
-            } else if (result == ' ') {
-                result = 0;
-            } else if ((result == '[') || (result == '1')) {
-                result = 27;
-            } else if ((result == '\\') || (result == '.')) {
-                result = 28;
-            } else if ((result == ']') || (result == '0')) {
-                result = 29;
-            } else if ((result == '^') || (result == '6')) {
-                result = 30; // control-^
-            } else if ((result == '_') || (result == '5')) {
-                result = 31;
-            }
-        }
-
-        if (result > -1) {
-            mAltKey.adjustAfterKeypress();
-            mCapKey.adjustAfterKeypress();
-            mControlKey.adjustAfterKeypress();
-        }
-
-        return result;
-    }
-
-    /**
-     * Handle a keyUp event.
-     *
-     * @param keyCode the keyCode of the keyUp event
-     */
-    public void keyUp(int keyCode) {
-        switch (keyCode) {
-        case KeyEvent.KEYCODE_ALT_LEFT:
-        case KeyEvent.KEYCODE_ALT_RIGHT:
-            mAltKey.onRelease();
-            break;
-        case KeyEvent.KEYCODE_SHIFT_LEFT:
-        case KeyEvent.KEYCODE_SHIFT_RIGHT:
-            mCapKey.onRelease();
-            break;
-        default:
-            // Ignore other keyUps
-            break;
-        }
-    }
-}
diff --git a/apps/Term/src/com/android/term/TermPreferences.java b/apps/Term/src/com/android/term/TermPreferences.java
deleted file mode 100644
index 3102963..0000000
--- a/apps/Term/src/com/android/term/TermPreferences.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.term;
-
-import android.os.Bundle;
-import android.preference.PreferenceActivity;
-
-public class TermPreferences extends PreferenceActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Load the preferences from an XML resource
-        addPreferencesFromResource(R.xml.preferences);
-    }
-
-}
diff --git a/apps/launchperf/Android.mk b/apps/launchperf/Android.mk
deleted file mode 100644
index f3d29bb..0000000
--- a/apps/launchperf/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := launchperf
-
-LOCAL_MODULE_TAGS := tests
-
-include $(BUILD_PACKAGE)
diff --git a/apps/launchperf/AndroidManifest.xml b/apps/launchperf/AndroidManifest.xml
deleted file mode 100644
index 8cf53c4..0000000
--- a/apps/launchperf/AndroidManifest.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.launchperf">
-  <application android:label="Launch Performance">
-      <uses-library android:name="android.test.runner" />
-
-    <activity android:name="SimpleActivity" android:label="Simple Activity">
-      <intent-filter>
-        <action android:name="android.intent.action.MAIN" />
-        <category android:name="android.intent.category.DEFAULT" />
-      </intent-filter>
-    </activity>
-
-    <activity android:name="EmptyActivity" android:label="Empty Activity">
-      <intent-filter>
-        <action android:name="android.intent.action.MAIN" />
-        <category android:name="android.intent.category.DEFAULT" />
-      </intent-filter>
-    </activity>
-
-    <activity android:name="ComplexActivity" android:label="Complex Activity">
-      <intent-filter>
-        <action android:name="android.intent.action.MAIN" />
-        <category android:name="android.intent.category.DEFAULT" />
-      </intent-filter>
-    </activity>
-
-  </application>
-
-  <instrumentation android:name="SimpleActivityLaunchPerformance"
-    android:targetPackage="com.android.launchperf"
-    android:label="Simple Activity Launch Performance">
-  </instrumentation>
-
-  <instrumentation android:name="ComplexActivityLaunchPerformance"
-    android:targetPackage="com.android.launchperf"
-    android:label="Complex Activity Launch Performance">
-  </instrumentation>
-
-  <instrumentation android:name="EmptyActivityLaunchPerformance"
-    android:targetPackage="com.android.launchperf"
-    android:label="Empty Activity Launch Performance">
-  </instrumentation>
-
-  <instrumentation android:name="HelloWorldLaunchPerformance"
-    android:targetPackage="com.example.android.apis"
-    android:label="Hello World Launch Performance">
-  </instrumentation>
-
-</manifest>
diff --git a/apps/launchperf/res/layout/complex_layout.xml b/apps/launchperf/res/layout/complex_layout.xml
deleted file mode 100644
index 4e585b9..0000000
--- a/apps/launchperf/res/layout/complex_layout.xml
+++ /dev/null
@@ -1,288 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/tests/ComplexLayout/res/layout/complex_layout.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<!-- This file describes the layout of the main ComplexLayout activity
-     user interface.
- -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-<!--    <TabHost
-        android:layout_width="fill_parent"
-        android:layout_height="200dip">
-    </TabHost>
-
-    <GridView
-        android:layout_width="fill_parent"
-        android:layout_height="200dip"
-        android:numColumns="5">
-    </GridView> -->
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="200dip"
-        android:orientation="vertical">
-        
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/header_absolute"/>
-
-        <AbsoluteLayout
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:layout_x="0dip"
-                android:layout_y="0dip"
-                android:background="@color/red"
-                android:text="@string/test_short_paragraph"/>
-            
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="0dip"
-                android:layout_y="0dip"
-                android:background="@color/gray0"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="8dip"
-                android:layout_y="4dip"
-                android:background="@color/gray1"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="16dip"
-                android:layout_y="8dip"
-                android:background="@color/gray2"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="24dip"
-                android:layout_y="12dip"
-                android:background="@color/gray3"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="32dip"
-                android:layout_y="16dip"
-                android:background="@color/gray4"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="40dip"
-                android:layout_y="20dip"
-                android:background="@color/gray5"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="48dip"
-                android:layout_y="24dip"
-                android:background="@color/gray6"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="56dip"
-                android:layout_y="28dip"
-                android:background="@color/gray7"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="64dip"
-                android:layout_y="32dip"
-                android:background="@color/gray8"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="72dip"
-                android:layout_y="36dip"
-                android:background="@color/gray9"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="80dip"
-                android:layout_y="40dip"
-                android:background="@color/grayA"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="88dip"
-                android:layout_y="44dip"
-                android:background="@color/grayB"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="96dip"
-                android:layout_y="48dip"
-                android:background="@color/grayC"
-                android:text="@string/test_word"/>
-             <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="104dip"
-                android:layout_y="52dip"
-                android:background="@color/grayD"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="112dip"
-                android:layout_y="56dip"
-                android:background="@color/grayE"
-                android:text="@string/test_word"/>
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_x="120dip"
-                android:layout_y="60dip"
-                android:background="@color/grayF"
-                android:text="@string/test_word"/>
-
-        </AbsoluteLayout>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/header_relative"/>
-
-        <RelativeLayout
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-
-            <Button android:id="@+id/relative_button1"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/relative_button1"/>
-            <Button android:id="@+id/relative_button2"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_button1"
-                android:text="@string/relative_button2"/>
-            <Button android:id="@+id/relative_button3"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_button2"
-                android:text="@string/relative_button3"/>
-            <Button android:id="@+id/relative_button4"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_button3"
-                android:text="@string/relative_button4"/>
-
-            <TextView android:id="@+id/relative_text"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_toRightOf="@id/relative_button1"
-                android:background="@color/green"
-                android:text="@string/test_short_paragraph"/>
-
-            <Button android:id="@+id/relative_button5"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_text"
-                android:layout_alignParentRight="true"
-                android:text="@string/relative_button5"/>
-            <Button android:id="@+id/relative_button6"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_text"
-                android:layout_toLeftOf="@id/relative_button5"
-                android:text="@string/relative_button6"/>
-            <Button android:id="@+id/relative_button7"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_text"
-                android:layout_toLeftOf="@id/relative_button6"
-                android:text="@string/relative_button7"/>
-            <Button android:id="@+id/relative_button8"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_below="@id/relative_text"
-                android:layout_toLeftOf="@id/relative_button7"
-                android:text="@string/relative_button8"/>
-
-        </RelativeLayout>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/header_linear"/>
-
-        <LinearLayout
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:orientation="vertical">
-
-            <LinearLayout
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal">
-
-                <Button
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="@string/relative_button1"/>
-                <Button
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="@string/relative_button2"/>
-                <Button
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="@string/relative_button3"/>
-                <Button
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:text="@string/relative_button4"/>
-
-            </LinearLayout>
-
-            <EditText
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"/>
-
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:background="@color/blue"
-                android:text="@string/test_long_paragraph"/>
-
-        </LinearLayout>
-
-    </LinearLayout>
-
-</ScrollView>
diff --git a/apps/launchperf/res/layout/simple_layout.xml b/apps/launchperf/res/layout/simple_layout.xml
deleted file mode 100644
index 3a61724..0000000
--- a/apps/launchperf/res/layout/simple_layout.xml
+++ /dev/null
@@ -1,86 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/tests/SimpleLayout/res/layout/simple_layout.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<!-- This file describes the layout of the main SimpleLayout activity
-     user interface.
- -->
-
-<!-- The top view is a layout manager that places its child views into
-     a row, here set to be vertical (so the first is at the top) -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <RelativeLayout
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent">
-
-
-        <RelativeLayout android:id="@+id/replay_pane"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_alignParentBottom="True"
-            android:background="@color/replay_background">
-
-            <TextView android:id="@+id/instructions"
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:text="@string/response" />
-
-            <EditText android:id="@+id/entry"
-                android:layout_width="fill_parent" 
-                android:layout_height="44dip" 
-                android:layout_below="@id/instructions"/>
-  
-            <Button android:id="@+id/ok" 
-                android:layout_width="wrap_content" 
-                android:layout_height="wrap_content" 
-                android:layout_below="@id/entry"
-                android:layout_alignParentRight="true"
-                android:text="@string/ok" />
-
-            <Button android:id="@+id/cancel"
-                android:layout_width="wrap_content" 
-                android:layout_height="wrap_content"
-                android:layout_toLeftOf="@id/ok"
-                android:layout_alignTop="@id/ok"
-                android:text="@string/cancel" />
-
-        </RelativeLayout>
-
-        <ScrollView android:id="@+id/scroll_pane"
-            android:layout_width="fill_parent"
-            android:layout_height="fill_parent"
-            android:layout_above="@id/replay_pane">
-
-            <TextView android:id="@+id/text_field"
-                android:layout_width="fill_parent"
-                android:layout_height="fill_parent"
-                android:text="@string/text"/>
-            
-            <requestFocus/>
-
-        </ScrollView>
-
-    </RelativeLayout>
-    
-</LinearLayout>
diff --git a/apps/launchperf/res/values/colors.xml b/apps/launchperf/res/values/colors.xml
deleted file mode 100644
index 9510c25..0000000
--- a/apps/launchperf/res/values/colors.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/tests/ComplexLayout/res/values/colors.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<!-- This file contains resource definitions for displayed strings, allowing
-     them to be changed based on the locale and options. -->
-
-<resources>
-    <color name="gray0">#F000</color>
-    <color name="gray1">#E111</color>
-    <color name="gray2">#D222</color>
-    <color name="gray3">#C333</color>
-    <color name="gray4">#B444</color>
-    <color name="gray5">#A555</color>
-    <color name="gray6">#9666</color>
-    <color name="gray7">#8777</color>
-    <color name="gray8">#7888</color>
-    <color name="gray9">#6999</color>
-    <color name="grayA">#5AAA</color>
-    <color name="grayB">#4BBB</color>
-    <color name="grayC">#3CCC</color>
-    <color name="grayD">#2DDD</color>
-    <color name="grayE">#1EEE</color>
-    <color name="grayF">#0FFF</color>
-    <color name="red">#F00</color>
-    <color name="green">#0F0</color>
-    <color name="blue">#00F</color>
-    <color name="replay_background">#e0eaff</color>
-</resources>
diff --git a/apps/launchperf/res/values/strings.xml b/apps/launchperf/res/values/strings.xml
deleted file mode 100644
index 21c406c..0000000
--- a/apps/launchperf/res/values/strings.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/tests/ComplexLayout/res/values/strings.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<!-- This file contains resource definitions for displayed strings, allowing
-     them to be changed based on the locale and options. -->
-
-<resources>
-    <string name="test_word">test</string>
-    <string name="test_sentence">This is a test sentence.</string>
-    <string name="test_short_paragraph">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Cras consectetuer dolor. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent nec sapien nec orci feugiat sodales.</string>
-    <string name="test_long_paragraph">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Cras consectetuer dolor. Vivamus bibendum semper lorem. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent nec sapien nec orci feugiat sodales. Praesent ut tortor. Suspendisse sed magna quis ante pellentesque faucibus. Nunc feugiat. Quisque porta. Nunc velit magna, varius in, fringilla quis, ornare eget, magna. Suspendisse potenti. Nam eu felis. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Quisque vulputate suscipit magna. Nunc vestibulum lorem ac odio.</string>
-    <string name="header_absolute">Absolute view</string>
-
-    <string name="header_relative">Relative layout</string>
-    <string name="header_linear">Linear layout</string>
-
-    <string name="relative_button1">Button1</string>
-    <string name="relative_button2">Button2</string>
-    <string name="relative_button3">Button3</string>
-    <string name="relative_button4">Button4</string>
-    <string name="relative_button5">Button5</string>
-    <string name="relative_button6">Button6</string>
-    <string name="relative_button7">Button7</string>
-    <string name="relative_button8">Button8</string>
-    <string name="response">Type Response:</string>
-    <string name="ok">OK</string>
-    <string name="cancel">Cancel</string>
-    <string name="text">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. In congue varius tortor. Etiam dolor nisl, lacinia et, venenatis vitae, nonummy ut, mi. Praesent a risus. Ut nisi. Nullam nonummy, lorem vel bibendum pellentesque, dolor massa egestas risus, luctus vehicula metus metus non nibh. Suspendisse potenti. In malesuada dolor. Fusce sodales fermentum metus. Mauris bibendum. Morbi faucibus eros sed enim. Pellentesque bibendum diam a justo. Suspendisse condimentum. Nam luctus, turpis molestie aliquet congue, nulla ante vulputate ipsum, nec nonummy neque tellus eu mi. Phasellus semper. Aenean adipiscing erat nec turpis. Curabitur euismod sapien quis nisl. Pellentesque tempor tristique lectus. Praesent fermentum.</string>
-</resources>
diff --git a/apps/launchperf/src/com/android/launchperf/ComplexActivity.java b/apps/launchperf/src/com/android/launchperf/ComplexActivity.java
deleted file mode 100644
index b909bd3..0000000
--- a/apps/launchperf/src/com/android/launchperf/ComplexActivity.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/* //device/tests/ComplexLayout/src/com/android/complexlayout/ComplexLayout.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.launchperf;
-
-import java.util.Map;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class ComplexActivity extends Activity {
-   
-    /** Called with the activity is first created. */
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.complex_layout);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/ComplexActivityLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/ComplexActivityLaunchPerformance.java
deleted file mode 100644
index 0030f6b..0000000
--- a/apps/launchperf/src/com/android/launchperf/ComplexActivityLaunchPerformance.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Complex Activity launch performance testing.
- */
-public class ComplexActivityLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "ComplexActivityLaunchPerformance";
-
-    public ComplexActivityLaunchPerformance() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getContext(), "com.android.launchperf.ComplexActivity");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/EmptyActivity.java b/apps/launchperf/src/com/android/launchperf/EmptyActivity.java
deleted file mode 100644
index b431ea4..0000000
--- a/apps/launchperf/src/com/android/launchperf/EmptyActivity.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-import java.util.Map;
-
-public class EmptyActivity extends Activity {
-    
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-    }
-
-}
diff --git a/apps/launchperf/src/com/android/launchperf/EmptyActivityLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/EmptyActivityLaunchPerformance.java
deleted file mode 100644
index 5dc586b..0000000
--- a/apps/launchperf/src/com/android/launchperf/EmptyActivityLaunchPerformance.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Empty Activity launch performance testing.
- */
-public class EmptyActivityLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "EmptyActivityLaunchPerformance";
-
-    public EmptyActivityLaunchPerformance() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getContext(), "com.android.launchperf.EmptyActivity");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/HelloWorldLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/HelloWorldLaunchPerformance.java
deleted file mode 100644
index 0500165..0000000
--- a/apps/launchperf/src/com/android/launchperf/HelloWorldLaunchPerformance.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Hello World launch performance testing.
- */
-public class HelloWorldLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "HelloWorldLaunchPerformance";
-
-    public HelloWorldLaunchPerformance() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getTargetContext(), "com.example.android.apis.app.HelloWorld");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/NotePadLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/NotePadLaunchPerformance.java
deleted file mode 100644
index a33fe63..0000000
--- a/apps/launchperf/src/com/android/launchperf/NotePadLaunchPerformance.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Notepad launch performance testing.
- */
-public class NotePadLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "NotePadLaunchPerformance";
-
-    public NotePadLaunchPerformance() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getTargetContext(), "com.android.notepad.NotesList");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/PhoneLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/PhoneLaunchPerformance.java
deleted file mode 100644
index 02e2a3b..0000000
--- a/apps/launchperf/src/com/android/launchperf/PhoneLaunchPerformance.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Phone launch performance testing.
- */
-public class PhoneLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "PhoneLaunchPerformance";
-   
-    public PhoneLaunchPerformance() {
-        super();
-    }
-    
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getTargetContext(), "com.android.phone.CallLogList");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/SimpleActivity.java b/apps/launchperf/src/com/android/launchperf/SimpleActivity.java
deleted file mode 100644
index e6425ab..0000000
--- a/apps/launchperf/src/com/android/launchperf/SimpleActivity.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/* //device/tests/SimpleLayout/src/com/android/simplelayout/SimpleLayout.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.launchperf;
-
-import java.util.Map;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class SimpleActivity extends Activity {
-   
-    /** Called with the activity is first created. */
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.simple_layout);
-    }
-}
diff --git a/apps/launchperf/src/com/android/launchperf/SimpleActivityLaunchPerformance.java b/apps/launchperf/src/com/android/launchperf/SimpleActivityLaunchPerformance.java
deleted file mode 100644
index 2f92500..0000000
--- a/apps/launchperf/src/com/android/launchperf/SimpleActivityLaunchPerformance.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.launchperf;
-
-import android.app.Activity;
-import android.test.LaunchPerformanceBase;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * Instrumentation class for Simple Activity launch performance testing.
- */
-public class SimpleActivityLaunchPerformance extends LaunchPerformanceBase {
- 
-    public static final String LOG_TAG = "SimpleActivityLaunchPerformance";
-
-    public SimpleActivityLaunchPerformance() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        mIntent.setClassName(getContext(), "com.android.launchperf.SimpleActivity");
-        start();
-    }
-
-    /**
-     * Calls LaunchApp and finish.
-     */
-    @Override
-    public void onStart() {
-        super.onStart();
-        LaunchApp();
-        finish(Activity.RESULT_OK, mResults);
-    }
-}
diff --git a/build/Android.mk b/build/Android.mk
deleted file mode 100644
index cba96c6..0000000
--- a/build/Android.mk
+++ /dev/null
@@ -1,65 +0,0 @@
-LOCAL_PATH := $(call my-dir)
-
-# The source files for this library are _all_ generated, something we don't do
-# anywhere else, and the rules don't support.  Aditionally, the depenencies on
-# these files don't really matter, because they are all generated as part of
-# building the docs.  So for the dependency, we just use the
-# offline-sdk-timestamp file, which is the $@ of the droiddoc rule.
-# We also need to depend on framework-res.apk, in order to pull the
-# resource files out of there for aapt.
-#
-# Normally the package rule runs aapt, which includes the resource,
-# but we're not running that in our package rule so just copy in the
-# resource files here.
-intermediates := $(TARGET_OUT_COMMON_INTERMEDIATES)/JAVA_LIBRARIES/android_stubs_current_intermediates
-full_target := $(intermediates)/classes.jar
-src_dir := $(intermediates)/src
-classes_dir := $(intermediates)/classes
-framework_res_package := $(call intermediates-dir-for,APPS,framework-res)/package.apk
-
-$(full_target): PRIVATE_SRC_DIR := $(src_dir)
-$(full_target): PRIVATE_INTERMEDIATES_DIR := $(intermediates)
-$(full_target): PRIVATE_CLASS_INTERMEDIATES_DIR := $(classes_dir)
-$(full_target): PRIVATE_FRAMEWORK_RES_PACKAGE := $(framework_res_package)
-
-$(full_target): $(OUT_DOCS)/offline-sdk-timestamp $(framework_res_package)
-	@echo Compiling SDK Stubs: $@
-	$(hide) rm -rf $(PRIVATE_CLASS_INTERMEDIATES_DIR)
-	$(hide) mkdir -p $(PRIVATE_CLASS_INTERMEDIATES_DIR)
-	$(hide) find $(PRIVATE_SRC_DIR) -name "*.java" > \
-        $(PRIVATE_INTERMEDIATES_DIR)/java-source-list
-	$(hide) $(TARGET_JAVAC) -encoding ascii -bootclasspath "" \
-			-g $(xlint_unchecked) \
-			-extdirs "" -d $(PRIVATE_CLASS_INTERMEDIATES_DIR) \
-			\@$(PRIVATE_INTERMEDIATES_DIR)/java-source-list \
-		|| ( rm -rf $(PRIVATE_CLASS_INTERMEDIATES_DIR) ; exit 41 )
-	$(hide) if [ ! -f $(PRIVATE_FRAMEWORK_RES_PACKAGE) ]; then \
-		echo Missing file $(PRIVATE_FRAMEWORK_RES_PACKAGE); \
-		rm -rf $(PRIVATE_CLASS_INTERMEDIATES_DIR); \
-		exit 1; \
-	fi;
-	$(hide) unzip -qo $(PRIVATE_FRAMEWORK_RES_PACKAGE) -d $(PRIVATE_CLASS_INTERMEDIATES_DIR)
-	$(hide) (cd $(PRIVATE_CLASS_INTERMEDIATES_DIR) && rm -rf classes.dex META-INF)
-	$(hide) mkdir -p $(dir $@)
-	$(hide) jar -cf $@ -C $(PRIVATE_CLASS_INTERMEDIATES_DIR) .
-
-.PHONY: android_stubs
-android_stubs: $(full_target)
-
-# The real rules create a javalib.jar that contains a classes.dex file.  This
-# code is never going to be run anywhere, so just make a copy of the file.
-# The package installation stuff doesn't know about this file, so nobody will
-# ever be able to write a rule that installs it to a device.
-$(dir $(full_target))javalib.jar: $(full_target)
-	$(hide)$(ACP) $< $@
-
-
-android_jar_intermediates := $(TARGET_OUT_COMMON_INTERMEDIATES)/PACKAGING/android_jar_intermediates
-android_jar_full_target := $(android_jar_intermediates)/android.jar
-
-$(android_jar_full_target): $(full_target)
-	@echo Package SDK Stubs: $@
-	$(hide)mkdir -p $(dir $@)
-	$(hide)$(ACP) $< $@
-
-ALL_SDK_FILES += $(android_jar_full_target)
diff --git a/build/sdk-darwin-x86.atree b/build/sdk-darwin-x86.atree
deleted file mode 100644
index 1e27678..0000000
--- a/build/sdk-darwin-x86.atree
+++ /dev/null
@@ -1,10 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-
-# swt
-lib/libswt-carbon-3236.jnilib tools/lib/libswt-carbon-3236.jnilib
-lib/libswt-pi-carbon-3236.jnilib tools/lib/libswt-pi-carbon-3236.jnilib
-framework/swt.jar tools/lib/swt.jar
-framework/org.eclipse.core.commands_3.2.0.I20060605-1400.jar tools/lib/org.eclipse.core.commands_3.2.0.I20060605-1400.jar
-framework/org.eclipse.equinox.common_3.2.0.v20060603.jar tools/lib/org.eclipse.equinox.common_3.2.0.v20060603.jar
-framework/org.eclipse.jface_3.2.0.I20060605-1400.jar tools/lib/org.eclipse.jface_3.2.0.I20060605-1400.jar
diff --git a/build/sdk-linux-x86.atree b/build/sdk-linux-x86.atree
deleted file mode 100644
index 1324f55..0000000
--- a/build/sdk-linux-x86.atree
+++ /dev/null
@@ -1,12 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-
-# swt
-lib/libswt-atk-gtk-3236.so tools/lib/libswt-atk-gtk-3236.so
-lib/libswt-gtk-3236.so tools/lib/libswt-gtk-3236.so
-lib/libswt-pi-gtk-3236.so tools/lib/libswt-pi-gtk-3236.so
-lib/libswt-cairo-gtk-3236.so tools/lib/libswt-cairo-gtk-3236.so
-framework/swt.jar tools/lib/swt.jar
-framework/org.eclipse.core.commands_3.2.0.I20060605-1400.jar tools/lib/org.eclipse.core.commands_3.2.0.I20060605-1400.jar
-framework/org.eclipse.equinox.common_3.2.0.v20060603.jar tools/lib/org.eclipse.equinox.common_3.2.0.v20060603.jar
-framework/org.eclipse.jface_3.2.0.I20060605-1400.jar tools/lib/org.eclipse.jface_3.2.0.I20060605-1400.jar
diff --git a/build/sdk.atree b/build/sdk.atree
deleted file mode 100644
index 4fb768b..0000000
--- a/build/sdk.atree
+++ /dev/null
@@ -1,167 +0,0 @@
-#
-# Copyright (C) 2007 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-#
-# These are the files that comprise that SDK
-#
-
-# host tools from out/host/$(HOST_OS)-$(HOST_ARCH)/
-bin/aapt platforms/${PLATFORM_NAME}/tools/aapt
-bin/aidl platforms/${PLATFORM_NAME}/tools/aidl
-bin/adb tools/adb
-bin/sqlite3 tools/sqlite3
-bin/dmtracedump tools/dmtracedump
-bin/mksdcard tools/mksdcard
-
-# other tools
-development/tools/scripts/add-accounts-sdk tools/add-accounts.py
-
-# the uper-jar file that apps link against
-out/target/common/obj/PACKAGING/android_jar_intermediates/android.jar platforms/${PLATFORM_NAME}/android.jar
-
-sdk/sdk-build.prop platforms/${PLATFORM_NAME}/build.prop
-development/tools/scripts/plugin.prop tools/lib/plugin.prop
-
-# the aidl precompiled include
-obj/framework.aidl platforms/${PLATFORM_NAME}/framework.aidl
-
-# sdk scripts
-development/tools/scripts/AndroidManifest.template platforms/${PLATFORM_NAME}/templates/AndroidManifest.template
-development/tools/scripts/AndroidManifest.alias.template platforms/${PLATFORM_NAME}/templates/AndroidManifest.alias.template
-development/tools/scripts/AndroidManifest.tests.template platforms/${PLATFORM_NAME}/templates/AndroidManifest.tests.template
-development/tools/scripts/iml.template platforms/${PLATFORM_NAME}/templates/iml.template
-development/tools/scripts/ipr.template platforms/${PLATFORM_NAME}/templates/ipr.template
-development/tools/scripts/iws.template platforms/${PLATFORM_NAME}/templates/iws.template
-development/tools/scripts/java_file.template platforms/${PLATFORM_NAME}/templates/java_file.template
-development/tools/scripts/java_tests_file.template platforms/${PLATFORM_NAME}/templates/java_tests_file.template
-development/tools/scripts/layout.template platforms/${PLATFORM_NAME}/templates/layout.template
-development/tools/scripts/strings.template platforms/${PLATFORM_NAME}/templates/strings.template
-development/tools/scripts/alias.template platforms/${PLATFORM_NAME}/templates/alias.template
-development/tools/scripts/android_rules.xml platforms/${PLATFORM_NAME}/templates/android_rules.xml
-development/tools/scripts/alias_rules.xml platforms/${PLATFORM_NAME}/templates/alias_rules.xml
-development/tools/scripts/build.template tools/lib/build.template
-development/tools/scripts/build.alias.template tools/lib/build.alias.template
-
-# emacs support
-development/tools/scripts/android.el tools/lib/android.el
-
-# samples
-development/samples/HelloActivity platforms/${PLATFORM_NAME}/samples/HelloActivity
-development/samples/Home platforms/${PLATFORM_NAME}/samples/Home
-development/samples/LunarLander platforms/${PLATFORM_NAME}/samples/LunarLander
-development/samples/NotePad platforms/${PLATFORM_NAME}/samples/NotePad
-development/samples/ApiDemos platforms/${PLATFORM_NAME}/samples/ApiDemos
-development/samples/SkeletonApp platforms/${PLATFORM_NAME}/samples/SkeletonApp
-development/samples/Snake platforms/${PLATFORM_NAME}/samples/Snake
-
-# dx
-bin/dx platforms/${PLATFORM_NAME}/tools/dx
-bin/dexdump platforms/${PLATFORM_NAME}/tools/dexdump
-framework/dx.jar platforms/${PLATFORM_NAME}/tools/lib/dx.jar
-
-#androidprefs
-framework/androidprefs.jar tools/lib/androidprefs.jar
-
-#jarutils
-framework/jarutils.jar tools/lib/jarutils.jar
-
-#apkbuilder
-bin/apkbuilder tools/apkbuilder
-framework/apkbuilder.jar tools/lib/apkbuilder.jar
-
-# sdkstats service
-framework/sdkstats.jar tools/lib/sdkstats.jar
-
-# jfreechart. needed by ddms.
-framework/jcommon-1.0.12.jar tools/lib/jcommon-1.0.12.jar
-framework/jfreechart-1.0.9.jar tools/lib/jfreechart-1.0.9.jar
-framework/jfreechart-1.0.9-swt.jar tools/lib/jfreechart-1.0.9-swt.jar
-
-# ddms
-bin/ddms tools/ddms
-framework/ddms.jar tools/lib/ddms.jar
-framework/ddmlib.jar tools/lib/ddmlib.jar
-framework/ddmuilib.jar tools/lib/ddmuilib.jar
-
-# hierarchyviewer
-bin/hierarchyviewer tools/hierarchyviewer
-framework/hierarchyviewer.jar tools/lib/hierarchyviewer.jar
-framework/org-netbeans-api-visual.jar tools/lib/org-netbeans-api-visual.jar
-framework/org-openide-util.jar tools/lib/org-openide-util.jar
-framework/swing-worker-1.1.jar tools/lib/swing-worker-1.1.jar
-
-# draw9patch
-bin/draw9patch tools/draw9patch
-framework/draw9patch.jar tools/lib/draw9patch.jar
-framework/swing-worker-1.1.jar tools/lib/swing-worker-1.1.jar
-
-# traceview
-bin/traceview tools/traceview
-framework/traceview.jar tools/lib/traceview.jar
-
-# custom ant tasks
-framework/anttasks.jar tools/lib/anttasks.jar
-
-# sdkmanager
-bin/android tools/android
-framework/sdklib.jar tools/lib/sdklib.jar
-framework/sdkmanager.jar tools/lib/sdkmanager.jar
-
-# emulator
-bin/emulator tools/emulator
-system.img platforms/${PLATFORM_NAME}/images/system.img
-ramdisk.img platforms/${PLATFORM_NAME}/images/ramdisk.img
-userdata.img platforms/${PLATFORM_NAME}/images/userdata.img
-prebuilt/android-arm/kernel/kernel-qemu platforms/${PLATFORM_NAME}/images/kernel-qemu
-external/qemu/android/avd/hardware-properties.ini tools/lib/hardware-properties.ini
-
-# emulator skins
-development/emulator/skins/HVGA   platforms/${PLATFORM_NAME}/skins/HVGA
-development/emulator/skins/HVGA-L platforms/${PLATFORM_NAME}/skins/HVGA-L
-development/emulator/skins/HVGA-P platforms/${PLATFORM_NAME}/skins/HVGA-P
-development/emulator/skins/QVGA-L platforms/${PLATFORM_NAME}/skins/QVGA-L
-development/emulator/skins/QVGA-P platforms/${PLATFORM_NAME}/skins/QVGA-P
-
-# NOTICE files are copied by build/core/Makefile
-
-# the readme
-development/docs/SDK_RELEASE_NOTES RELEASE_NOTES.html
-
-# the docs
-docs/offline-sdk docs
-frameworks/base/docs/docs-redirect.html documentation.html
-frameworks/base/docs/docs-samples-redirect.html docs/samples/index.html
-
-# tools support
-docs/activity_actions.txt platforms/${PLATFORM_NAME}/data/activity_actions.txt
-docs/broadcast_actions.txt platforms/${PLATFORM_NAME}/data/broadcast_actions.txt
-docs/service_actions.txt platforms/${PLATFORM_NAME}/data/service_actions.txt
-docs/categories.txt platforms/${PLATFORM_NAME}/data/categories.txt
-docs/widgets.txt platforms/${PLATFORM_NAME}/data/widgets.txt
-framework/layoutlib.jar platforms/${PLATFORM_NAME}/data/layoutlib.jar
-frameworks/base/core/res/res platforms/${PLATFORM_NAME}/data/res
-frameworks/base/data/fonts/fonts.xml platforms/${PLATFORM_NAME}/data/fonts/fonts.xml
-frameworks/base/data/fonts/DroidSans.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSans.ttf
-frameworks/base/data/fonts/DroidSans-Bold.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSans-Bold.ttf
-frameworks/base/data/fonts/DroidSansFallback.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSansFallback.ttf
-frameworks/base/data/fonts/DroidSansMono.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSansMono.ttf
-frameworks/base/data/fonts/DroidSerif-Bold.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSerif-Bold.ttf
-frameworks/base/data/fonts/DroidSerif-BoldItalic.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSerif-BoldItalic.ttf
-frameworks/base/data/fonts/DroidSerif-Italic.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSerif-Italic.ttf
-frameworks/base/data/fonts/DroidSerif-Regular.ttf platforms/${PLATFORM_NAME}/data/fonts/DroidSerif-Regular.ttf
-
-# empty add-on folder with just a readme
-development/tools/scripts/README_add-ons.txt add-ons/README.txt
diff --git a/build/sdk.exclude.atree b/build/sdk.exclude.atree
deleted file mode 100644
index 5a93b1b..0000000
--- a/build/sdk.exclude.atree
+++ /dev/null
@@ -1,27 +0,0 @@
-#
-# Copyright (C) 2007 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# excludes
--Makefile
--Android.mk
--.*.swp
--.DS_Store
--*~
--_*
--.*
--OWNERS
--MODULE_LICENSE_*
--*.ezt
diff --git a/build/tools/make_windows_sdk.sh b/build/tools/make_windows_sdk.sh
deleted file mode 100755
index a32546c..0000000
--- a/build/tools/make_windows_sdk.sh
+++ /dev/null
@@ -1,155 +0,0 @@
-#!/bin/bash
-# Quick semi-auto file to build Windows SDK tools.
-#
-# Limitations:
-# - Expects the emulator has been built first, will pick it up from prebuilt.
-# - Run in Cygwin
-# - Needs Cygwin package zip
-# - Expects to have one of the existing SDK (Darwin or Linux) to build the Windows one
-
-set -e  # Fail this script as soon as a command fails -- fail early, fail fast
-
-# Set to 1 to force removal of old unzipped SDK. Only disable for debugging, as it
-# will make some rm/mv commands to fail.
-FORCE="1" 
-
-SDK_ZIP="$1"
-DIST_DIR="$2"
-
-function die() {
-  echo "Error:" $*
-  echo "Aborting"
-  exit 1
-}
-
-function check() {
-    [ -f "$SDK_ZIP" ] || die "Pass the path of an existing Linux/Darwin SDK .zip as first parameter"
-    [ -d "$DIST_DIR" ] || die "Pass the output directory as second parameter"
-
-    # Use the BUILD_ID as SDK_NUMBER if defined, otherwise try to get it from the
-    # provided zip filename.
-    if [ -f config/build_id.make ]; then
-        BUILD_ID=`cat config/build_id.make | sed -n '/BUILD_ID=/s/^[^=]\+=\(.*\)$/\1/p'`
-        [ -n "$BUILD_ID" ] && SDK_NUMBER="$BUILD_ID"
-    fi
-    if [ -z "$SDK_NUMBER" ]; then
-        # Look for a pattern like "anything_sdknumber.extension"
-        # The pattern is now "any-thing_sdknumber_anything-else.extension"
-        #
-        # The bottom line is that the SDK number is whatever is enclosed by
-        # the LAST couple of underscores. You can have underscores *before* the
-        # SDK number if you want, but not after, e.g these are valid:
-        #    android_sdk_4242_platform.zip or blah_42_.zip
-        #
-        # SDK_NUMBER will be empty if nothing matched.
-        filename=`basename "$SDK_ZIP"`
-        SDK_NUMBER=`echo $filename | sed -n 's/^.*_\([^_./]\+\)_[^_.]*\..*$/\1/p'`
-    fi
-
-    [ -n "$SDK_NUMBER" ] || die "Failed to extract the SDK number from $SDK_ZIP. Check its format."
-
-    [ $OSTYPE == "cygwin" ] || die "This expects to run under Cygwin"
-    [ -e `which zip` ] || die "Please install 'zip' package in Cygwin"
-    [ -f "build/envsetup.sh" ] || die "Please run this from the 'android' directory"
-
-    echo "Using SDK ${SDK_NUMBER}"
-}
-
-function build() {
-
-    echo 
-    echo "Building..."
-    [ -n "$MAKE_OPT" ] && echo "Make options: $MAKE_OPT"
-    . build/envsetup.sh
-    make -j 4 emulator || die "Build failed"
-    # Disable parallel build: it generates "permission denied" issues when
-    # multiple "ar.exe" are running in parallel.
-    make prebuilt adb fastboot aidl aapt dexdump dmtracedump mksdcard sqlite3 || die "Build failed"
-}
-
-function package() {
-    echo
-    echo "Packaging..."
-    DEST_NAME="android-sdk_${SDK_NUMBER}_windows"
-    DEST="$DIST_DIR/$DEST_NAME"
-    DEST_NAME_ZIP="${DEST_NAME}.zip"
-
-    # Unzip current linux/mac SDK and rename using the windows name
-    if [[ -n "$FORCE" || ! -d "$DEST" ]]; then
-        [ -e "$DEST" ] && rm -rfv "$DEST"  # cleanup dest first if exists
-        UNZIPPED=`basename "$SDK_ZIP"`
-        UNZIPPED="$DIST_DIR/${UNZIPPED/.zip/}"
-        [ -e "$UNZIPPED" ] && rm -rfv "$UNZIPPED"  # cleanup unzip dir (if exists)
-        unzip "$SDK_ZIP" -d "$DIST_DIR"
-        mv -v "$UNZIPPED" "$DEST"
-    fi
-    
-    # Assert that the package contains only one platform
-    PLATFORMS="$DEST/platforms"
-    THE_PLATFORM=`echo $PLATFORMS/*`
-    PLATFORM_TOOLS=$THE_PLATFORM/tools
-    echo "Platform found: " $THE_PLATFORM
-    [[ -d "$THE_PLATFORM" ]] || die \
-        "Error: One platform was expected in $SDK_ZIP. " \
-        "Instead found " $THE_PLATFORM
-    [[ -d "$PLATFORM_TOOLS" ]] || die "Missing folder $PLATFORM_TOOLS."
-
-
-    # USB Driver for ADB
-    mkdir -pv $DEST/usb_driver/x86
-    cp -rv development/host/windows/prebuilt/usb/driver/* $DEST/usb_driver/x86/
-    mkdir -pv $DEST/usb_driver/amd64
-    cp -rv development/host/windows/prebuilt/usb/driver_amd_64/* $DEST/usb_driver/amd64/
-
-    # Remove obsolete stuff from tools & platform
-    TOOLS="$DEST/tools"
-    LIB="$DEST/tools/lib"
-    rm -v "$TOOLS"/{adb,emulator,traceview,draw9patch,hierarchyviewer,apkbuilder,ddms,dmtracedump,mksdcard,sqlite3,android}
-    rm -v --force "$LIB"/*.so "$LIB"/*.jnilib
-    rm -v "$PLATFORM_TOOLS"/{aapt,aidl,dx,dexdump}
-
-
-    # Copy all the new stuff in tools
-    # Note: some tools are first copied here and then moved in platforms/<name>/tools/
-    cp -v out/host/windows-x86/bin/*.{exe,dll} "$TOOLS"
-    cp -v prebuilt/windows/swt/*.{jar,dll} "$LIB"
-
-    # If you want the emulator NOTICE in the tools dir, uncomment the following line:
-    # cp -v external/qemu/NOTICE "$TOOLS"/emulator_NOTICE.txt
-
-    # We currently need libz from MinGW for aapt
-    cp -v /cygdrive/c/cygwin/bin/mgwz.dll "$TOOLS"
-
-    # Update a bunch of bat files
-    cp -v development/tools/apkbuilder/etc/apkbuilder.bat "$TOOLS"
-    cp -v development/tools/ddms/app/etc/ddms.bat "$TOOLS"
-    cp -v development/tools/traceview/etc/traceview.bat "$TOOLS"
-    cp -v development/tools/hierarchyviewer/etc/hierarchyviewer.bat "$TOOLS"
-    cp -v development/tools/draw9patch/etc/draw9patch.bat "$TOOLS"
-    cp -v development/tools/sdkmanager/app/etc/android.bat "$TOOLS"
-
-    # Copy or move platform specific tools to the default platform.
-    cp -v dalvik/dx/etc/dx.bat "$PLATFORM_TOOLS"
-    # Note: mgwz.dll must be in same folder than aapt.exe
-    mv -v "$TOOLS"/{aapt.exe,aidl.exe,dexdump.exe,mgwz.dll} "$PLATFORM_TOOLS"
-
-    # Fix EOL chars to make window users happy - fix all files at the top level only
-    # as well as all batch files including those in platforms/<name>/tools/
-    find "$DIST_DIR" -maxdepth 1 -type f -writable -print0 | xargs -0 unix2dos -D
-    find "$DIST_DIR" -maxdepth 3 -name "*.bat" -type f -writable -print0 | xargs -0 unix2dos -D
-
-    # Done.. Zip it
-    pushd "$DIST_DIR" > /dev/null
-    [ -e "$DEST_NAME_ZIP" ] && rm -rfv "$DEST_NAME_ZIP"
-    zip -9r "$DEST_NAME_ZIP" "$DEST_NAME" && rm -rfv "$DEST_NAME"
-    popd > /dev/null
-    echo "Done"
-    echo
-    echo "Resulting SDK is in $DIST_DIR/$DEST_NAME_ZIP"
-}
-
-check
-build
-package
-
-echo "Done"
diff --git a/cmds/monkey/Android.mk b/cmds/monkey/Android.mk
deleted file mode 100644
index 6bedc43..0000000
--- a/cmds/monkey/Android.mk
+++ /dev/null
@@ -1,13 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_MODULE := monkey
-include $(BUILD_JAVA_LIBRARY)
-
-include $(CLEAR_VARS)
-ALL_PREBUILT += $(TARGET_OUT)/bin/monkey
-$(TARGET_OUT)/bin/monkey : $(LOCAL_PATH)/monkey | $(ACP)
-	$(transform-prebuilt-to-target)
diff --git a/cmds/monkey/MODULE_LICENSE_APACHE2 b/cmds/monkey/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/cmds/monkey/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/cmds/monkey/NOTICE b/cmds/monkey/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/cmds/monkey/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/cmds/monkey/monkey b/cmds/monkey/monkey
deleted file mode 100755
index 45f43a4..0000000
--- a/cmds/monkey/monkey
+++ /dev/null
@@ -1,7 +0,0 @@
-# Script to start "monkey" on the device, which has a very rudimentary
-# shell.
-#
-base=/system
-export CLASSPATH=$base/framework/monkey.jar
-exec app_process $base/bin com.android.commands.monkey.Monkey $*
-
diff --git a/cmds/monkey/src/com/android/commands/monkey/Monkey.java b/cmds/monkey/src/com/android/commands/monkey/Monkey.java
deleted file mode 100644
index f6ab19d..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/Monkey.java
+++ /dev/null
@@ -1,906 +0,0 @@
-/**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-
-package com.android.commands.monkey;
-
-import android.app.ActivityManagerNative;
-import android.app.IActivityManager;
-import android.app.IActivityWatcher;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.content.pm.IPackageManager;
-import android.content.pm.ResolveInfo;
-import android.os.Debug;
-import android.os.Process;
-import android.os.RemoteException;
-import android.os.ServiceManager;
-import android.server.data.CrashData;
-import android.view.IWindowManager;
-
-import java.io.BufferedReader;
-import java.io.ByteArrayInputStream;
-import java.io.DataInputStream;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * Application that injects random key events and other actions into the system.
- */
-public class Monkey {
-    
-    /**
-     * Monkey Debugging/Dev Support
-     * 
-     * All values should be zero when checking in.
-     */
-    private final static int DEBUG_ALLOW_ANY_STARTS = 0;
-    private final static int DEBUG_ALLOW_ANY_RESTARTS = 0;
-    private IActivityManager mAm;
-    private IWindowManager mWm;
-    private IPackageManager mPm;
-
-    /** Command line arguments */
-    private String[] mArgs;
-    /** Current argument being parsed */
-    private int mNextArg;
-    /** Data of current argument */
-    private String mCurArgData;
-
-    /** Running in verbose output mode? 1= verbose, 2=very verbose */
-    private int mVerbose;
-
-    /** Ignore any application crashes while running? */
-    private boolean mIgnoreCrashes;
-
-    /** Ignore any not responding timeouts while running? */
-    private boolean mIgnoreTimeouts;
-    
-    /** Ignore security exceptions when launching activities */
-    /** (The activity launch still fails, but we keep pluggin' away) */
-    private boolean mIgnoreSecurityExceptions;
-    
-    /** Monitor /data/tombstones and stop the monkey if new files appear. */
-    private boolean mMonitorNativeCrashes;
-    
-    /** Send no events.  Use with long throttle-time to watch user operations */
-    private boolean mSendNoEvents;
-
-    /** This is set when we would like to abort the running of the monkey. */
-    private boolean mAbort;
-    
-    /** This is set by the ActivityWatcher thread to request collection of ANR trace files */
-    private boolean mRequestAnrTraces = false;
-
-    /** This is set by the ActivityWatcher thread to request a "dumpsys meminfo" */
-    private boolean mRequestDumpsysMemInfo = false;
-
-    /** Kill the process after a timeout or crash. */
-    private boolean mKillProcessAfterError;
-    
-    /** Generate hprof reports before/after monkey runs */
-    private boolean mGenerateHprof;
-
-    /** Packages we are allowed to run, or empty if no restriction. */
-    private HashSet<String> mValidPackages = new HashSet<String>();
-    /** Categories we are allowed to launch **/
-    ArrayList<String> mMainCategories = new ArrayList<String>();
-    /** Applications we can switch to. */
-    private ArrayList<ComponentName> mMainApps = new ArrayList<ComponentName>();
-    
-    /** The delay between event inputs **/
-    long mThrottle = 0;
-    
-    /** The number of iterations **/
-    int mCount = 1000;
-    
-    /** The random number seed **/
-    long mSeed = 0;
-    
-    /** Dropped-event statistics **/
-    long mDroppedKeyEvents = 0;
-    long mDroppedPointerEvents = 0;
-    long mDroppedTrackballEvents = 0;
-    long mDroppedFlipEvents = 0;
-
-    /** a filename to the script (if any) **/
-    private String mScriptFileName = null;
-    
-    private static final File TOMBSTONES_PATH = new File("/data/tombstones");
-    private HashSet<String> mTombstones = null;
-    
-    float[] mFactors = new float[MonkeySourceRandom.FACTORZ_COUNT];    
-    MonkeyEventSource mEventSource;
-
-    /**
-     * Monitor operations happening in the system.
-     */
-    private class ActivityWatcher extends IActivityWatcher.Stub {
-        public boolean activityStarting(Intent intent, String pkg) {
-            boolean allow = checkEnteringPackage(pkg) || (DEBUG_ALLOW_ANY_STARTS != 0);
-            if (mVerbose > 0) {
-                System.out.println("    // " + (allow ? "Allowing" : "Rejecting")
-                        + " start of " + intent + " in package " + pkg);
-            }
-            return allow;
-        }
-        
-        public boolean activityResuming(String pkg) {
-            System.out.println("    // activityResuming(" + pkg + ")");
-            boolean allow = checkEnteringPackage(pkg) || (DEBUG_ALLOW_ANY_RESTARTS != 0);
-            if (!allow) {
-                if (mVerbose > 0) {
-                    System.out.println("    // " + (allow ? "Allowing" : "Rejecting")
-                            + " resume of package " + pkg);
-                }
-            }
-            return allow;
-        }
-        
-        private boolean checkEnteringPackage(String pkg) {
-            if (pkg == null) {
-                return true;
-            }
-            // preflight the hash lookup to avoid the cost of hash key generation
-            if (mValidPackages.size() == 0) {
-                return true;
-            } else {
-                return mValidPackages.contains(pkg);
-            }
-        }
-        
-        public boolean appCrashed(String processName, int pid, String shortMsg,
-                String longMsg, byte[] crashData) {
-            System.err.println("// CRASH: " + processName + " (pid " + pid
-                    + ")");
-            System.err.println("// Short Msg: " + shortMsg);
-            System.err.println("// Long Msg: " + longMsg);
-            if (crashData != null) {
-                try {
-                    CrashData cd = new CrashData(new DataInputStream(
-                            new ByteArrayInputStream(crashData)));
-                    System.err.println("// Build Label: "
-                            + cd.getBuildData().getFingerprint());
-                    System.err.println("// Build Changelist: "
-                            + cd.getBuildData().getIncrementalVersion());
-                    System.err.println("// Build Time: "
-                            + cd.getBuildData().getTime());
-                    System.err.println("// ID: " + cd.getId());
-                    System.err.println("// Tag: " + cd.getActivity());
-                    System.err.println(cd.getThrowableData().toString(
-                            "// "));
-                } catch (IOException e) {
-                    System.err.println("// BAD STACK CRAWL");
-                }
-            }
-
-            if (!mIgnoreCrashes) {
-                synchronized (Monkey.this) {
-                    mAbort = true;
-                }
-
-                return !mKillProcessAfterError;
-            }
-            return false;
-        }
-
-        public int appNotResponding(String processName, int pid,
-                String processStats) {
-            System.err.println("// NOT RESPONDING: " + processName
-                    + " (pid " + pid + ")");
-            System.err.println(processStats);
-            reportProcRank();
-            synchronized (Monkey.this) {
-                mRequestAnrTraces = true;
-                mRequestDumpsysMemInfo = true;
-            }
-            if (!mIgnoreTimeouts) {
-                synchronized (Monkey.this) {
-                    mAbort = true;
-                }
-                return (mKillProcessAfterError) ? -1 : 1;
-            }
-            return 1;
-        }
-    }
-    
-    /**
-     * Run the procrank tool to insert system status information into the debug report.
-     */
-    private void reportProcRank() {
-      commandLineReport("procrank", "procrank");
-    }
-    
-    /**
-     * Run "cat /data/anr/traces.txt".  Wait about 5 seconds first, to let the asynchronous
-     * report writing complete.
-     */
-    private void reportAnrTraces() {
-        try {
-            Thread.sleep(5 * 1000);
-        } catch (InterruptedException e) { 
-        }
-        commandLineReport("anr traces", "cat /data/anr/traces.txt");
-    }
-    
-    /**
-     * Run "dumpsys meminfo"
-     * 
-     * NOTE:  You cannot perform a dumpsys call from the ActivityWatcher callback, as it will
-     * deadlock.  This should only be called from the main loop of the monkey.
-     */
-    private void reportDumpsysMemInfo() {
-        commandLineReport("meminfo", "dumpsys meminfo");
-    }
-    
-    /**
-     * Print report from a single command line.
-     * @param reportName Simple tag that will print before the report and in various annotations.
-     * @param command Command line to execute.
-     * TODO: Use ProcessBuilder & redirectErrorStream(true) to capture both streams (might be
-     * important for some command lines)
-     */
-    private void commandLineReport(String reportName, String command) {
-        System.err.println(reportName + ":");
-        Runtime rt = Runtime.getRuntime();
-        try {
-            // Process must be fully qualified here because android.os.Process is used elsewhere
-            java.lang.Process p = Runtime.getRuntime().exec(command);
-            
-            // pipe everything from process stdout -> System.err
-            InputStream inStream = p.getInputStream();
-            InputStreamReader inReader = new InputStreamReader(inStream);
-            BufferedReader inBuffer = new BufferedReader(inReader);
-            String s;
-            while ((s = inBuffer.readLine()) != null) {
-                System.err.println(s);
-            }
-            
-            int status = p.waitFor();
-            System.err.println("// " + reportName + " status was " + status);
-        } catch (Exception e) {
-            System.err.println("// Exception from " + reportName + ":");
-            System.err.println(e.toString());
-        }
-    }
-
-    /**
-     * Command-line entry point.
-     *
-     * @param args The command-line arguments
-     */
-    public static void main(String[] args) {
-        int resultCode = (new Monkey()).run(args);
-        System.exit(resultCode);
-    }
-
-    /**
-     * Run the command!
-     *
-     * @param args The command-line arguments
-     * @return Returns a posix-style result code.  0 for no error.
-     */
-    private int run(String[] args) {
-        // Super-early debugger wait
-        for (String s : args) {
-            if ("--wait-dbg".equals(s)) {
-                Debug.waitForDebugger();
-            }
-        }
-        
-        // Default values for some command-line options
-        mVerbose = 0;
-        mCount = 1000;
-        mSeed = 0;
-        mThrottle = 0;
-        
-        // prepare for command-line processing
-        mArgs = args;
-        mNextArg = 0;
-        
-        //set a positive value, indicating none of the factors is provided yet
-        for (int i = 0; i < MonkeySourceRandom.FACTORZ_COUNT; i++) {
-            mFactors[i] = 1.0f;
-        }
-        
-        if (!processOptions()) {
-            return -1;
-        }
-        
-        // now set up additional data in preparation for launch
-        if (mMainCategories.size() == 0) {
-            mMainCategories.add(Intent.CATEGORY_LAUNCHER);
-            mMainCategories.add(Intent.CATEGORY_MONKEY);
-        }
-
-        if (mVerbose > 0) {
-            System.out.println(":Monkey: seed=" + mSeed + " count=" + mCount);
-            if (mValidPackages.size() > 0) {
-                Iterator<String> it = mValidPackages.iterator();
-                while (it.hasNext()) {
-                    System.out.println(":AllowPackage: " + it.next());
-                }
-            }
-            if (mMainCategories.size() != 0) {
-                Iterator<String> it = mMainCategories.iterator();
-                while (it.hasNext()) {
-                    System.out.println(":IncludeCategory: " + it.next());
-                }
-            }
-        }
-        
-        if (!checkInternalConfiguration()) {
-            return -2;
-        }
-        
-        if (!getSystemInterfaces()) {
-            return -3;
-        }
-
-        if (!getMainApps()) {
-            return -4;
-        }
-        
-        if (mScriptFileName != null) {
-            // script mode, ignore other options
-            mEventSource = new MonkeySourceScript(mScriptFileName);
-            mEventSource.setVerbose(mVerbose);
-        } else {
-            // random source by default
-            if (mVerbose >= 2) {    // check seeding performance
-                System.out.println("// Seeded: " + mSeed);
-            }
-            mEventSource = new MonkeySourceRandom(mSeed, mMainApps);
-            mEventSource.setVerbose(mVerbose);
-            //set any of the factors that has been set
-            for (int i = 0; i < MonkeySourceRandom.FACTORZ_COUNT; i++) {
-                if (mFactors[i] <= 0.0f) {
-                    ((MonkeySourceRandom) mEventSource).setFactors(i, mFactors[i]);
-                }
-            }
-            
-            //in random mode, we start with a random activity
-            ((MonkeySourceRandom) mEventSource).generateActivity();
-        }
-
-        //validate source generator
-        if (!mEventSource.validate()) {
-            return -5;
-        }
-        
-        if (mScriptFileName != null) {
-            // in random mode, count is the number of single events
-            // while in script mode, count is the number of repetition
-            // for a sequence of events, so we need do multiply the length of
-            // that sequence
-            mCount = mCount * ((MonkeySourceScript) mEventSource)
-                .getOneRoundEventCount();
-        }
-        
-        // If we're profiling, do it immediately before/after the main monkey loop
-        if (mGenerateHprof) {
-            signalPersistentProcesses();
-        }
-        
-        int crashedAtCycle = runMonkeyCycles();
-
-        synchronized (this) {
-            if (mRequestAnrTraces) {
-                reportAnrTraces();
-                mRequestAnrTraces = false;
-            }
-            if (mRequestDumpsysMemInfo) {
-                reportDumpsysMemInfo();
-                mRequestDumpsysMemInfo = false;
-            }
-        }
-
-        if (mGenerateHprof) {
-            signalPersistentProcesses();
-            if (mVerbose > 0) {
-                System.out.println("// Generated profiling reports in /data/misc");
-            }
-        }
-        
-        try {
-            mAm.setActivityWatcher(null);
-        } catch (RemoteException e) {
-            // just in case this was latent (after mCount cycles), make sure
-            // we report it
-            if (crashedAtCycle >= mCount) {
-                crashedAtCycle = mCount - 1;
-            }
-        }
-        
-        // report dropped event stats
-        if (mVerbose > 0) {
-            System.out.print(":Dropped: keys=");
-            System.out.print(mDroppedKeyEvents);
-            System.out.print(" pointers=");
-            System.out.print(mDroppedPointerEvents);
-            System.out.print(" trackballs=");
-            System.out.print(mDroppedTrackballEvents);
-            System.out.print(" flips=");
-            System.out.println(mDroppedFlipEvents);
-        }
-
-        if (crashedAtCycle < mCount - 1) {
-            System.err.println("** System appears to have crashed at event "
-                    + crashedAtCycle + " of " + mCount + " using seed " + mSeed);
-           return crashedAtCycle;
-        } else {
-            if (mVerbose > 0) {
-                System.out.println("// Monkey finished");
-            }
-            return 0;
-        }
-    }
-    
-    /**
-     * Process the command-line options
-     * 
-     * @return Returns true if options were parsed with no apparent errors.
-     */
-    private boolean processOptions() {
-        // quick (throwaway) check for unadorned command
-        if (mArgs.length < 1) {
-            showUsage();
-            return false;
-        }
-
-        try {
-            String opt;
-            while ((opt = nextOption()) != null) {
-                if (opt.equals("-s")) {
-                    mSeed = nextOptionLong("Seed");
-                } else if (opt.equals("-p")) {
-                    mValidPackages.add(nextOptionData());
-                } else if (opt.equals("-c")) {
-                    mMainCategories.add(nextOptionData());
-                } else if (opt.equals("-v")) {
-                    mVerbose += 1;
-                } else if (opt.equals("--ignore-crashes")) {
-                    mIgnoreCrashes = true;
-                } else if (opt.equals("--ignore-timeouts")) {
-                    mIgnoreTimeouts = true;
-                } else if (opt.equals("--ignore-security-exceptions")) {
-                    mIgnoreSecurityExceptions = true;
-                } else if (opt.equals("--monitor-native-crashes")) {
-                    mMonitorNativeCrashes = true;
-                } else if (opt.equals("--kill-process-after-error")) {
-                    mKillProcessAfterError = true;
-                } else if (opt.equals("--hprof")) {
-                    mGenerateHprof = true;
-                } else if (opt.equals("--pct-touch")) {
-                    mFactors[MonkeySourceRandom.FACTOR_TOUCH] = 
-                        -nextOptionLong("touch events percentage");
-                } else if (opt.equals("--pct-motion")) {
-                    mFactors[MonkeySourceRandom.FACTOR_MOTION] = 
-                        -nextOptionLong("motion events percentage");
-                } else if (opt.equals("--pct-trackball")) {
-                    mFactors[MonkeySourceRandom.FACTOR_TRACKBALL] = 
-                        -nextOptionLong("trackball events percentage");
-                } else if (opt.equals("--pct-nav")) {
-                    mFactors[MonkeySourceRandom.FACTOR_NAV] = 
-                        -nextOptionLong("nav events percentage");
-                } else if (opt.equals("--pct-majornav")) {
-                    mFactors[MonkeySourceRandom.FACTOR_MAJORNAV] = 
-                        -nextOptionLong("major nav events percentage");
-                } else if (opt.equals("--pct-appswitch")) {
-                    mFactors[MonkeySourceRandom.FACTOR_APPSWITCH] = 
-                        -nextOptionLong("app switch events percentage");
-                } else if (opt.equals("--pct-flip")) {
-                    mFactors[MonkeySourceRandom.FACTOR_FLIP] =
-                        -nextOptionLong("keyboard flip percentage");
-                } else if (opt.equals("--pct-anyevent")) {
-                    mFactors[MonkeySourceRandom.FACTOR_ANYTHING] = 
-                        -nextOptionLong("any events percentage");
-                } else if (opt.equals("--throttle")) {
-                    mThrottle = nextOptionLong("delay (in milliseconds) to wait between events");
-                } else if (opt.equals("--wait-dbg")) {
-                    // do nothing - it's caught at the very start of run()
-                } else if (opt.equals("--dbg-no-events")) {
-                    mSendNoEvents = true;
-                } else  if (opt.equals("-f")) {
-                    mScriptFileName = nextOptionData();
-                } else if (opt.equals("-h")) {
-                    showUsage();
-                    return false;
-                } else {
-                    System.err.println("** Error: Unknown option: " + opt);
-                    showUsage();
-                    return false;
-                }
-            }
-        } catch (RuntimeException ex) {
-            System.err.println("** Error: " + ex.toString());
-            showUsage();
-            return false;
-        }
-
-        String countStr = nextArg();
-        if (countStr == null) {
-            System.err.println("** Error: Count not specified");
-            showUsage();
-            return false;
-        }
-
-        try {
-            mCount = Integer.parseInt(countStr);
-        } catch (NumberFormatException e) {
-            System.err.println("** Error: Count is not a number");
-            showUsage();
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Check for any internal configuration (primarily build-time) errors.
-     * 
-     * @return Returns true if ready to rock.
-     */
-    private boolean checkInternalConfiguration() {
-        // Check KEYCODE name array, make sure it's up to date.
-
-        String lastKeyName = null;
-        try {
-            lastKeyName = MonkeySourceRandom.getLastKeyName();
-        } catch (RuntimeException e) {
-        }
-        if (!"TAG_LAST_KEYCODE".equals(lastKeyName)) {
-            System.err.println("** Error: Key names array malformed (internal error).");
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Attach to the required system interfaces.
-     * 
-     * @return Returns true if all system interfaces were available.
-     */
-    private boolean getSystemInterfaces() {
-        mAm = ActivityManagerNative.getDefault();
-        if (mAm == null) {
-            System.err.println("** Error: Unable to connect to activity manager; is the system running?");
-            return false;
-        }
-
-        mWm = IWindowManager.Stub.asInterface(ServiceManager.getService("window"));
-        if (mWm == null) {
-            System.err.println("** Error: Unable to connect to window manager; is the system running?");
-            return false;
-        }
-
-        mPm = IPackageManager.Stub.asInterface(ServiceManager.getService("package"));
-        if (mPm == null) {
-            System.err.println("** Error: Unable to connect to package manager; is the system running?");
-            return false;
-        }
-
-        try {
-            mAm.setActivityWatcher(new ActivityWatcher());
-        } catch (RemoteException e) {
-            System.err.println("** Failed talking with activity manager!");
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Using the restrictions provided (categories & packages), generate a list of activities
-     * that we can actually switch to.
-     * 
-     * @return Returns true if it could successfully build a list of target activities
-     */
-    private boolean getMainApps() {
-        try {
-            final int N = mMainCategories.size();
-            for (int i = 0; i< N; i++) {
-                Intent intent = new Intent(Intent.ACTION_MAIN);
-                String category = mMainCategories.get(i);
-                if (category.length() > 0) {
-                    intent.addCategory(category);
-                }
-                List<ResolveInfo> mainApps = mPm.queryIntentActivities(intent, null, 0);
-                if (mainApps == null || mainApps.size() == 0) {
-                    System.err.println("// Warning: no activities found for category " + category);
-                    continue;
-                }
-                if (mVerbose >= 2) {     // very verbose
-                    System.out.println("// Selecting main activities from category " + category);
-                }
-                final int NA = mainApps.size();
-                for (int a = 0; a < NA; a++) {
-                    ResolveInfo r = mainApps.get(a);
-                    if (mValidPackages.size() == 0 || 
-                            mValidPackages.contains(r.activityInfo.applicationInfo.packageName)) {
-                        if (mVerbose >= 2) {     // very verbose
-                            System.out.println("//   + Using main activity "
-                                    + r.activityInfo.name
-                                    + " (from package "
-                                    + r.activityInfo.applicationInfo.packageName
-                                    + ")");
-                        }
-                        mMainApps.add(new ComponentName(
-                                r.activityInfo.applicationInfo.packageName,
-                                r.activityInfo.name));
-                    } else {
-                        if (mVerbose >= 3) {     // very very verbose
-                            System.out.println("//   - NOT USING main activity "
-                                    + r.activityInfo.name
-                                    + " (from package "
-                                    + r.activityInfo.applicationInfo.packageName
-                                    + ")");
-                        }
-                    }
-                }
-            }
-        } catch (RemoteException e) {
-            System.err.println("** Failed talking with package manager!");
-            return false;
-        }
-
-        if (mMainApps.size() == 0) {
-            System.out.println("** No activities found to run, monkey aborted.");
-            return false;
-        }
-        
-        return true;
-    }
-
-    /**
-     * Run mCount cycles and see if we hit any crashers.
-     * 
-     * TODO: Meta state on keys
-     * 
-     * @return Returns the last cycle which executed. If the value == mCount, no errors detected.
-     */
-    private int runMonkeyCycles() {
-        int i = 0;
-        int lastKey = 0;
-
-        boolean systemCrashed = false;
-
-        while (!systemCrashed && i < mCount) {
-            synchronized (this) {
-                if (mRequestAnrTraces) {
-                    reportAnrTraces();
-                    mRequestAnrTraces = false;
-                }
-                if (mRequestDumpsysMemInfo) {
-                    reportDumpsysMemInfo();
-                    mRequestDumpsysMemInfo = false;
-                }
-                if (mMonitorNativeCrashes) {
-                    // first time through, when i == 0, just set up the watcher (ignore the error)
-                    if (checkNativeCrashes() && (i > 0)) {
-                        System.out.println("** New native crash detected.");
-                        mAbort = mAbort || mKillProcessAfterError;
-                    }
-                }
-                if (mAbort) {
-                    System.out.println("** Monkey aborted due to error.");
-                    System.out.println("Events injected: " + i);
-                    return i;
-                }
-            }
-
-            try {
-                Thread.sleep(mThrottle);
-            } catch (InterruptedException e1) {
-                System.out.println("** Monkey interrupted in sleep.");
-                return i;
-            }
-
-            // In this debugging mode, we never send any events.  This is primarily
-            // here so you can manually test the package or category limits, while manually
-            // exercising the system.
-            if (mSendNoEvents) {
-                i++;
-                continue;
-            }
-
-            if ((mVerbose > 0) && (i % 100) == 0 && i != 0 && lastKey == 0) {
-                System.out.println("    // Sending event #" + i);
-            }
-
-            MonkeyEvent ev = mEventSource.getNextEvent();
-            if (ev != null) {
-                i++;
-                int injectCode = ev.injectEvent(mWm, mAm, mVerbose);
-                if (injectCode == MonkeyEvent.INJECT_FAIL) {
-                    if (ev instanceof MonkeyKeyEvent) {
-                        mDroppedKeyEvents++;
-                    } else if (ev instanceof MonkeyMotionEvent) {
-                        mDroppedPointerEvents++;
-                    } else if (ev instanceof MonkeyFlipEvent) {
-                        mDroppedFlipEvents++;
-                    }
-                } else if (injectCode == MonkeyEvent.INJECT_ERROR_REMOTE_EXCEPTION) {
-                    systemCrashed = true;
-                } else if (injectCode == MonkeyEvent.INJECT_ERROR_SECURITY_EXCEPTION) {
-                    systemCrashed = !mIgnoreSecurityExceptions;
-                }
-            }
-        }
-
-        // If we got this far, we succeeded!
-        return mCount;
-    }
-
-    /**
-     * Send SIGNAL_USR1 to all processes.  This will generate large (5mb) profiling reports
-     * in data/misc, so use with care.
-     */
-    private void signalPersistentProcesses() {
-        try {
-            mAm.signalPersistentProcesses(Process.SIGNAL_USR1);
-
-            synchronized (this) {
-                wait(2000);
-            }
-        } catch (RemoteException e) {
-            System.err.println("** Failed talking with activity manager!");
-        } catch (InterruptedException e) {
-        }
-    }
-
-    /**
-     * Watch for appearance of new tombstone files, which indicate native crashes.
-     * 
-     * @return Returns true if new files have appeared in the list
-     */
-    private boolean checkNativeCrashes() {
-        String[] tombstones = TOMBSTONES_PATH.list();
-        
-        // shortcut path for usually empty directory, so we don't waste even more objects
-        if ((tombstones == null) || (tombstones.length == 0)) {
-            mTombstones = null;
-            return false;
-        }
-        
-        // use set logic to look for new files
-        HashSet<String> newStones = new HashSet<String>();
-        for (String x : tombstones) {
-            newStones.add(x);
-        }
-
-        boolean result = (mTombstones == null) || !mTombstones.containsAll(newStones);
-
-        // keep the new list for the next time
-        mTombstones = newStones;
-
-        return result;
-    }
-
-    /**
-     * Return the next command line option.  This has a number of special cases which
-     * closely, but not exactly, follow the POSIX command line options patterns:
-     *  
-     * -- means to stop processing additional options
-     * -z means option z
-     * -z ARGS means option z with (non-optional) arguments ARGS
-     * -zARGS means option z with (optional) arguments ARGS
-     * --zz means option zz
-     * --zz ARGS means option zz with (non-optional) arguments ARGS
-     * 
-     * Note that you cannot combine single letter options;  -abc != -a -b -c
-     *
-     * @return Returns the option string, or null if there are no more options.
-     */
-    private String nextOption() {
-        if (mNextArg >= mArgs.length) {
-            return null;
-        }
-        String arg = mArgs[mNextArg];
-        if (!arg.startsWith("-")) {
-            return null;
-        }
-        mNextArg++;
-        if (arg.equals("--")) {
-            return null;
-        }
-        if (arg.length() > 1 && arg.charAt(1) != '-') {
-            if (arg.length() > 2) {
-                mCurArgData = arg.substring(2);
-                return arg.substring(0, 2);
-            } else {
-                mCurArgData = null;
-                return arg;
-            }
-        }
-        mCurArgData = null;
-        return arg;
-    }
-
-    /**
-     * Return the next data associated with the current option.
-     *
-     * @return Returns the data string, or null of there are no more arguments.
-     */
-    private String nextOptionData() {
-        if (mCurArgData != null) {
-            return mCurArgData;
-        }
-        if (mNextArg >= mArgs.length) {
-            return null;
-        }
-        String data = mArgs[mNextArg];
-        mNextArg++;
-        return data;
-    }
-    
-    /**
-     * Returns a long converted from the next data argument, with error handling if not available.
-     * 
-     * @param opt The name of the option.
-     * @return Returns a long converted from the argument.
-     */
-    private long nextOptionLong(final String opt) {
-        long result;
-        try {
-            result = Long.parseLong(nextOptionData());
-        } catch (NumberFormatException e) {
-            System.err.println("** Error: " + opt + " is not a number");
-            throw e;
-        }
-        return result;
-    }
-
-    /**
-     * Return the next argument on the command line.
-     *
-     * @return Returns the argument string, or null if we have reached the end.
-     */
-    private String nextArg() {
-        if (mNextArg >= mArgs.length) {
-            return null;
-        }
-        String arg = mArgs[mNextArg];
-        mNextArg++;
-        return arg;
-    }
-
-    /**
-     * Print how to use this command.
-     */
-    private void showUsage() {
-      System.err.println("usage: monkey [-p ALLOWED_PACKAGE [-p ALLOWED_PACKAGE] ...]");
-      System.err.println("              [-c MAIN_CATEGORY [-c MAIN_CATEGORY] ...]");
-      System.err.println("              [--ignore-crashes] [--ignore-timeouts]");
-      System.err.println("              [--ignore-security-exceptions] [--monitor-native-crashes]");
-      System.err.println("              [--kill-process-after-error] [--hprof]");
-      System.err.println("              [--pct-touch PERCENT] [--pct-motion PERCENT]");
-      System.err.println("              [--pct-trackball PERCENT] [--pct-syskeys PERCENT]");
-      System.err.println("              [--pct-nav PERCENT] [--pct-majornav PERCENT]");
-      System.err.println("              [--pct-appswitch PERCENT] [--pct-flip PERCENT]");
-      System.err.println("              [--pct-anyevent PERCENT]");
-      System.err.println("              [--wait-dbg] [--dbg-no-events] [-f scriptfile]");
-      System.err.println("              [-s SEED] [-v [-v] ...] [--throttle MILLISEC]");
-      System.err.println("              COUNT");
-  }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyActivityEvent.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyActivityEvent.java
deleted file mode 100644
index 68e6e6d..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyActivityEvent.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.app.IActivityManager;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.os.RemoteException;
-import android.view.IWindowManager;
-
-/**
- * monkey activity event
- */
-public class MonkeyActivityEvent extends MonkeyEvent {    
-    private ComponentName mApp; 
-    
-    public MonkeyActivityEvent(ComponentName app) {
-        super(EVENT_TYPE_ACTIVITY);
-        mApp = app;
-    }
-     
-    /** 
-     * @return Intent for the new activity
-     */        
-    private Intent getEvent() {        
-        Intent intent = new Intent(Intent.ACTION_MAIN);
-        intent.addCategory(Intent.CATEGORY_LAUNCHER);
-        intent.setComponent(mApp);
-        intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);        
-        return intent;
-    }
-
-    @Override
-    public int injectEvent(IWindowManager iwm, IActivityManager iam, int verbose) {
-        Intent intent = getEvent();
-        if (verbose > 0) {
-            System.out.println(":Switch: " + intent.toURI());
-        }
-        try {
-            iam.startActivity(null, intent, null, null, 0, null, null, 0,
-                    false, false);
-        } catch (RemoteException e) {
-            System.err.println("** Failed talking with activity manager!");
-            return MonkeyEvent.INJECT_ERROR_REMOTE_EXCEPTION;
-        } catch (SecurityException e) {
-            if (verbose > 0) {
-                System.out.println("** Permissions error starting activity "
-                        + intent.toURI());
-            }
-            return MonkeyEvent.INJECT_ERROR_SECURITY_EXCEPTION;
-        }
-        return MonkeyEvent.INJECT_SUCCESS;
-    }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyEvent.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyEvent.java
deleted file mode 100644
index ff99f5f..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyEvent.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.app.IActivityManager;
-import android.view.IWindowManager;
-
-/**
- * abstract class for monkey event
- */
-public abstract class MonkeyEvent {    
-    protected int eventType;
-    public static final int EVENT_TYPE_KEY = 0;
-    public static final int EVENT_TYPE_POINTER = 1;
-    public static final int EVENT_TYPE_TRACKBALL = 2;
-    public static final int EVENT_TYPE_ACTIVITY = 3;
-    public static final int EVENT_TYPE_FLIP = 4; // Keyboard flip
-        
-    public static final int INJECT_SUCCESS = 1;
-    public static final int INJECT_FAIL = 0;
-
-    // error code for remote exception during injection
-    public static final int INJECT_ERROR_REMOTE_EXCEPTION = -1;    
-    // error code for security exception during injection
-    public static final int INJECT_ERROR_SECURITY_EXCEPTION = -2;
-        
-    public MonkeyEvent(int type) {
-        eventType = type;
-    }
-  
-    /** 
-     * @return event type
-     */    
-    public int getEventType() {
-        return eventType;
-    }
-    
-    /**
-     * a method for injecting event
-     * @param iwm wires to current window manager
-     * @param iam wires to current activity manager
-     * @param verbose a log switch 
-     * @return INJECT_SUCCESS if it goes through, and INJECT_FAIL if it fails
-     *         in the case of exceptions, return its corresponding error code
-     */
-    public abstract int injectEvent(IWindowManager iwm, IActivityManager iam, int verbose);    
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyEventSource.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyEventSource.java
deleted file mode 100644
index a236554..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyEventSource.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-/**
- * event source interface
- */
-public interface MonkeyEventSource {    
-    /**
-     * 
-     * @return the next monkey event from the source
-     */
-    public MonkeyEvent getNextEvent();
-    
-    /**
-     * set verbose to allow different level of log
-     * @param verbose output mode? 1= verbose, 2=very verbose
-     */
-    public void setVerbose(int verbose);
-    
-    /**
-     * check whether precondition is satisfied
-     * @return false if something fails, e.g. factor failure in random source
-     * or file can not open from script source etc
-     */
-    public boolean validate();
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyFlipEvent.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyFlipEvent.java
deleted file mode 100644
index 08fbedb..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyFlipEvent.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2008 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-
-import android.app.IActivityManager;
-import android.view.IWindowManager;
-/**
- * monkey keyboard flip event
- */
-public class MonkeyFlipEvent extends MonkeyEvent {
-
-    // Raw keyboard flip event data
-    // Works on emulator and dream
-
-    private static final byte[] FLIP_0 = {
-        0x7f, 0x06,
-        0x00, 0x00,
-        (byte) 0xe0, 0x39,
-        0x01, 0x00,
-        0x05, 0x00,
-        0x00, 0x00,
-        0x01, 0x00,
-        0x00, 0x00 };
-
-    private static final byte[] FLIP_1 = {
-        (byte) 0x85, 0x06,
-        0x00, 0x00,
-        (byte) 0x9f, (byte) 0xa5,
-        0x0c, 0x00,
-        0x05, 0x00,
-        0x00, 0x00,
-        0x00, 0x00,
-        0x00, 0x00 };
-
-    private final boolean mKeyboardOpen;
-
-    public MonkeyFlipEvent(boolean keyboardOpen) {
-        super(EVENT_TYPE_FLIP);
-        mKeyboardOpen = keyboardOpen;
-    }
-
-    @Override
-    public int injectEvent(IWindowManager iwm, IActivityManager iam, int verbose) {
-        if (verbose > 0) {
-            System.out.println(":Sending Flip keyboardOpen=" + mKeyboardOpen);
-        }
-
-        // inject flip event
-        try {
-            FileOutputStream f = new FileOutputStream("/dev/input/event0");
-            f.write(mKeyboardOpen ? FLIP_0 : FLIP_1);
-            f.close();
-            return MonkeyEvent.INJECT_SUCCESS;
-        } catch (IOException e) {
-            System.out.println("Got IOException performing flip" + e);
-            return MonkeyEvent.INJECT_FAIL;
-        }
-    }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyKeyEvent.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyKeyEvent.java
deleted file mode 100644
index c1e0ffc..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyKeyEvent.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.app.IActivityManager;
-import android.os.RemoteException;
-import android.view.IWindowManager;
-import android.view.KeyEvent;
-/**
- * monkey key event
- */
-public class MonkeyKeyEvent extends MonkeyEvent {    
-    private long mDownTime = -1;
-    private int mMetaState = -1;
-    private int mAction = -1;
-    private int mKeyCode = -1;
-    private int mScancode = -1;
-    private int mRepeatCount = -1;
-    private int mDeviceId = -1;
-    private long mEventTime = -1;
-    
-    public MonkeyKeyEvent(int action, int keycode) {
-        super(EVENT_TYPE_KEY);
-        mAction = action;
-        mKeyCode = keycode;
-    }
-    
-    public MonkeyKeyEvent(long downTime, long eventTime, int action,
-            int code, int repeat, int metaState,
-            int device, int scancode) {
-        super(EVENT_TYPE_KEY);
-        
-        mAction = action;
-        mKeyCode = code;
-        mMetaState = metaState;
-        mScancode = scancode;
-        mRepeatCount = repeat;
-        mDeviceId = device;
-        mDownTime = downTime;
-        mEventTime = eventTime;
-    }
-    
-    public int getKeyCode() {
-        return mKeyCode;
-    }
-    
-    public int getAction() {
-        return mAction;
-    }
-    
-    public long getDownTime() {
-        return mDownTime;
-    }
-    
-    public long getEventTime() {
-        return mEventTime;
-    }
-    
-    public void setDownTime(long downTime) {
-        mDownTime = downTime;
-    }
-    
-    public void setEventTime(long eventTime) {
-        mEventTime = eventTime;
-    }
-    
-    /** 
-     * @return the key event
-     */        
-    private KeyEvent getEvent() {
-        if (mDeviceId < 0) {
-            return new KeyEvent(mAction, mKeyCode);
-        }       
-        
-        // for scripts
-        return new KeyEvent(mDownTime, mEventTime, mAction, 
-                mKeyCode, mRepeatCount, mMetaState, mDeviceId, mScancode);
-    }
-
-    @Override
-    public int injectEvent(IWindowManager iwm, IActivityManager iam, int verbose) {
-        if (verbose > 1) {
-            String note;
-            if (mAction == KeyEvent.ACTION_UP) {
-                note = "ACTION_UP";
-            } else {
-                note = "ACTION_DOWN";
-            }
-
-            try {
-                System.out.println(":SendKey (" + note + "): "
-                        + mKeyCode + "    // "
-                        + MonkeySourceRandom.getKeyName(mKeyCode));
-            } catch (ArrayIndexOutOfBoundsException e) {
-                System.out.println(":SendKey (ACTION_UP): "
-                        + mKeyCode + "    // Unknown key event");
-            }
-        }
-
-        // inject key event
-        try {
-            if (!iwm.injectKeyEvent(getEvent(), false)) {
-                return MonkeyEvent.INJECT_FAIL;
-            }
-        } catch (RemoteException ex) {
-            return MonkeyEvent.INJECT_ERROR_REMOTE_EXCEPTION;
-        }
-        
-        return MonkeyEvent.INJECT_SUCCESS;
-    }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeyMotionEvent.java b/cmds/monkey/src/com/android/commands/monkey/MonkeyMotionEvent.java
deleted file mode 100644
index 2657061..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeyMotionEvent.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.app.IActivityManager;
-import android.os.RemoteException;
-import android.os.SystemClock;
-import android.view.IWindowManager;
-import android.view.MotionEvent;
-
-
-/**
- * monkey motion event
- */
-public class MonkeyMotionEvent extends MonkeyEvent {
-    private long mDownTime = -1;
-    private long mEventTime = -1;    
-    private int mAction = -1;
-    private float mX = -1;
-    private float mY = -1;
-    private float mPressure = -1;
-    private float mSize = -1;
-    private int mMetaState = -1;
-    private float mXPrecision = -1;
-    private float mYPrecision = -1;
-    private int mDeviceId = -1;
-    private int mEdgeFlags = -1;
-    
-    //If true, this is an intermediate step (more verbose logging, only)
-    private boolean mIntermediateNote;  
-        
-    public MonkeyMotionEvent(int type, long downAt, int action, 
-            float x, float y, int metaState) {
-        super(type);
-        mDownTime = downAt;
-        mAction = action;
-        mX = x;
-        mY = y;
-        mMetaState = metaState;
-    }
-    
-    public MonkeyMotionEvent(int type, long downTime, long eventTime, int action,
-            float x, float y, float pressure, float size, int metaState,
-            float xPrecision, float yPrecision, int deviceId, int edgeFlags) {
-        super(type);
-        mDownTime = downTime;
-        mEventTime = eventTime;
-        mAction = action;
-        mX = x;
-        mY = y;
-        mPressure = pressure;
-        mSize = size;
-        mMetaState = metaState;
-        mXPrecision = xPrecision;
-        mYPrecision = yPrecision;
-        mDeviceId = deviceId;
-        mEdgeFlags = edgeFlags;
-    }    
-    
-    public void setIntermediateNote(boolean b) {
-        mIntermediateNote = b;
-    }
-    
-    public boolean getIntermediateNote() {
-        return mIntermediateNote;
-    }
-    
-    public float getX() {
-        return mX;
-    }
-    
-    public float getY() {
-        return mY;
-    }
-    
-    public int getAction() {
-        return mAction;
-    }
-    
-    public long getDownTime() {
-        return mDownTime;
-    }
-    
-    public long getEventTime() {
-        return mEventTime;
-    }
-    
-    public void setDownTime(long downTime) {
-        mDownTime = downTime;
-    }
-    
-    public void setEventTime(long eventTime) {
-        mEventTime = eventTime;
-    }
-    
-    /**
-     * 
-     * @return instance of a motion event
-     */
-    private MotionEvent getEvent() {
-        if (mDeviceId < 0) {
-            return MotionEvent.obtain(mDownTime, SystemClock.uptimeMillis(), 
-                mAction, mX, mY, mMetaState);
-        }
-        
-        // for scripts
-        return MotionEvent.obtain(mDownTime, mEventTime, 
-                mAction, mX, mY, mPressure, mSize, mMetaState,
-                mXPrecision, mYPrecision, mDeviceId, mEdgeFlags);
-    }
-
-    @Override
-    public int injectEvent(IWindowManager iwm, IActivityManager iam, int verbose) {
-        
-        String note;
-        if ((verbose > 0 && !mIntermediateNote) || verbose > 1) {
-            if (mAction == MotionEvent.ACTION_DOWN) {
-                note = "DOWN";
-            } else if (mAction == MotionEvent.ACTION_UP) {
-                note = "UP";
-            } else {
-                note = "MOVE";
-            }
-            System.out.println(":Sending Pointer ACTION_" + note + 
-                    " x=" + mX + " y=" + mY);
-        }
-        try {
-            int type = this.getEventType();
-            MotionEvent me = getEvent();
-            
-            if ((type == MonkeyEvent.EVENT_TYPE_POINTER && 
-                    !iwm.injectPointerEvent(me, false))
-                    || (type == MonkeyEvent.EVENT_TYPE_TRACKBALL && 
-                            !iwm.injectTrackballEvent(me, false))) {
-                return MonkeyEvent.INJECT_FAIL;
-            }
-        } catch (RemoteException ex) {
-            return MonkeyEvent.INJECT_ERROR_REMOTE_EXCEPTION;
-        }
-        return MonkeyEvent.INJECT_SUCCESS;
-    }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeySourceRandom.java b/cmds/monkey/src/com/android/commands/monkey/MonkeySourceRandom.java
deleted file mode 100644
index 3dbb575..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeySourceRandom.java
+++ /dev/null
@@ -1,467 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.content.ComponentName;
-import android.os.SystemClock;
-import android.view.Display;
-import android.view.KeyEvent;
-import android.view.MotionEvent;
-import android.view.WindowManagerImpl;
-
-import java.security.SecureRandom;
-import java.util.ArrayList;
-import java.util.LinkedList;
-import java.util.Random;
-
-/**
- * monkey event queue
- */
-public class MonkeySourceRandom implements MonkeyEventSource{    
-    /** Key events that move around the UI. */
-    private static final int[] NAV_KEYS = {
-        KeyEvent.KEYCODE_DPAD_UP, KeyEvent.KEYCODE_DPAD_DOWN,
-        KeyEvent.KEYCODE_DPAD_LEFT, KeyEvent.KEYCODE_DPAD_RIGHT,
-    };
-    /**
-     * Key events that perform major navigation options (so shouldn't be sent
-     * as much).
-     */
-    private static final int[] MAJOR_NAV_KEYS = {
-        KeyEvent.KEYCODE_MENU, /*KeyEvent.KEYCODE_SOFT_RIGHT,*/
-        KeyEvent.KEYCODE_DPAD_CENTER,
-    };
-    /** Key events that perform system operations. */
-    private static final int[] SYS_KEYS = {
-        KeyEvent.KEYCODE_HOME, KeyEvent.KEYCODE_BACK,
-        KeyEvent.KEYCODE_CALL, KeyEvent.KEYCODE_ENDCALL,
-        KeyEvent.KEYCODE_VOLUME_UP, KeyEvent.KEYCODE_VOLUME_DOWN,
-        KeyEvent.KEYCODE_MUTE,
-    };
-    /** Nice names for all key events. */
-    private static final String[] KEY_NAMES = {
-        "KEYCODE_UNKNOWN",
-        "KEYCODE_MENU",
-        "KEYCODE_SOFT_RIGHT",
-        "KEYCODE_HOME",
-        "KEYCODE_BACK",
-        "KEYCODE_CALL",
-        "KEYCODE_ENDCALL",
-        "KEYCODE_0",
-        "KEYCODE_1",
-        "KEYCODE_2",
-        "KEYCODE_3",
-        "KEYCODE_4",
-        "KEYCODE_5",
-        "KEYCODE_6",
-        "KEYCODE_7",
-        "KEYCODE_8",
-        "KEYCODE_9",
-        "KEYCODE_STAR",
-        "KEYCODE_POUND",
-        "KEYCODE_DPAD_UP",
-        "KEYCODE_DPAD_DOWN",
-        "KEYCODE_DPAD_LEFT",
-        "KEYCODE_DPAD_RIGHT",
-        "KEYCODE_DPAD_CENTER",
-        "KEYCODE_VOLUME_UP",
-        "KEYCODE_VOLUME_DOWN",
-        "KEYCODE_POWER",
-        "KEYCODE_CAMERA",
-        "KEYCODE_CLEAR",
-        "KEYCODE_A",
-        "KEYCODE_B",
-        "KEYCODE_C",
-        "KEYCODE_D",
-        "KEYCODE_E",
-        "KEYCODE_F",
-        "KEYCODE_G",
-        "KEYCODE_H",
-        "KEYCODE_I",
-        "KEYCODE_J",
-        "KEYCODE_K",
-        "KEYCODE_L",
-        "KEYCODE_M",
-        "KEYCODE_N",
-        "KEYCODE_O",
-        "KEYCODE_P",
-        "KEYCODE_Q",
-        "KEYCODE_R",
-        "KEYCODE_S",
-        "KEYCODE_T",
-        "KEYCODE_U",
-        "KEYCODE_V",
-        "KEYCODE_W",
-        "KEYCODE_X",
-        "KEYCODE_Y",
-        "KEYCODE_Z",
-        "KEYCODE_COMMA",
-        "KEYCODE_PERIOD",
-        "KEYCODE_ALT_LEFT",
-        "KEYCODE_ALT_RIGHT",
-        "KEYCODE_SHIFT_LEFT",
-        "KEYCODE_SHIFT_RIGHT",
-        "KEYCODE_TAB",
-        "KEYCODE_SPACE",
-        "KEYCODE_SYM",
-        "KEYCODE_EXPLORER",
-        "KEYCODE_ENVELOPE",
-        "KEYCODE_ENTER",
-        "KEYCODE_DEL",
-        "KEYCODE_GRAVE",
-        "KEYCODE_MINUS",
-        "KEYCODE_EQUALS",
-        "KEYCODE_LEFT_BRACKET",
-        "KEYCODE_RIGHT_BRACKET",
-        "KEYCODE_BACKSLASH",
-        "KEYCODE_SEMICOLON",
-        "KEYCODE_APOSTROPHE",
-        "KEYCODE_SLASH",
-        "KEYCODE_AT",
-        "KEYCODE_NUM",
-        "KEYCODE_HEADSETHOOK",
-        "KEYCODE_FOCUS",
-        "KEYCODE_PLUS",
-        "KEYCODE_MENU",
-        "KEYCODE_NOTIFICATION",
-        "KEYCODE_SEARCH",
-        "KEYCODE_PLAYPAUSE",
-        "KEYCODE_STOP",
-        "KEYCODE_NEXTSONG",
-        "KEYCODE_PREVIOUSSONG",
-        "KEYCODE_REWIND",
-        "KEYCODE_FORWARD",
-        "KEYCODE_MUTE",
-        
-        "TAG_LAST_KEYCODE"      // EOL.  used to keep the lists in sync
-    };
-
-    public static final int FACTOR_TOUCH        = 0;
-    public static final int FACTOR_MOTION       = 1;
-    public static final int FACTOR_TRACKBALL    = 2;
-    public static final int FACTOR_NAV          = 3;
-    public static final int FACTOR_MAJORNAV     = 4;
-    public static final int FACTOR_SYSOPS       = 5;
-    public static final int FACTOR_APPSWITCH    = 6;
-    public static final int FACTOR_FLIP         = 7;
-    public static final int FACTOR_ANYTHING     = 8;    
-    public static final int FACTORZ_COUNT       = 9;    // should be last+1
-    
-    
-    /** percentages for each type of event.  These will be remapped to working
-     * values after we read any optional values.
-     **/    
-    private float[] mFactors = new float[FACTORZ_COUNT];
-    private ArrayList<ComponentName> mMainApps;
-    private int mEventCount = 0;  //total number of events generated so far
-    private LinkedList<MonkeyEvent> mQ = new LinkedList<MonkeyEvent>();
-    private Random mRandom;    
-    private int mVerbose = 0;
-
-    private boolean mKeyboardOpen = false;
-
-    /** 
-     * @return the last name in the key list
-     */
-    public static String getLastKeyName() {
-        return KEY_NAMES[KeyEvent.getMaxKeyCode() + 1];
-    }
-    
-    public static String getKeyName(int keycode) {
-        return KEY_NAMES[keycode];
-    }
-    
-    public MonkeySourceRandom(long seed, ArrayList<ComponentName> MainApps) {
-        // default values for random distributions
-        // note, these are straight percentages, to match user input (cmd line args)
-        // but they will be converted to 0..1 values before the main loop runs.
-        mFactors[FACTOR_TOUCH] = 15.0f;
-        mFactors[FACTOR_MOTION] = 10.0f;
-        mFactors[FACTOR_TRACKBALL] = 15.0f;
-        mFactors[FACTOR_NAV] = 25.0f;
-        mFactors[FACTOR_MAJORNAV] = 15.0f;
-        mFactors[FACTOR_SYSOPS] = 2.0f;
-        mFactors[FACTOR_APPSWITCH] = 2.0f;
-        mFactors[FACTOR_FLIP] = 1.0f;
-        mFactors[FACTOR_ANYTHING] = 15.0f;
-        
-        mRandom = new SecureRandom();
-        mRandom.setSeed((seed == 0) ? -1 : seed);
-        mMainApps = MainApps;
-    }
-
-    /**
-     * Adjust the percentages (after applying user values) and then normalize to a 0..1 scale.
-     */
-    private boolean adjustEventFactors() {
-        // go through all values and compute totals for user & default values
-        float userSum = 0.0f;
-        float defaultSum = 0.0f;
-        int defaultCount = 0;
-        for (int i = 0; i < FACTORZ_COUNT; ++i) {
-            if (mFactors[i] <= 0.0f) {   // user values are zero or negative
-                userSum -= mFactors[i];
-            } else {
-                defaultSum += mFactors[i];
-                ++defaultCount;
-            }            
-        }
-        
-        // if the user request was > 100%, reject it
-        if (userSum > 100.0f) {
-            System.err.println("** Event weights > 100%");
-            return false;
-        }
-        
-        // if the user specified all of the weights, then they need to be 100%
-        if (defaultCount == 0 && (userSum < 99.9f || userSum > 100.1f)) {
-            System.err.println("** Event weights != 100%");
-            return false;
-        }
-        
-        // compute the adjustment necessary
-        float defaultsTarget = (100.0f - userSum);
-        float defaultsAdjustment = defaultsTarget / defaultSum;
-        
-        // fix all values, by adjusting defaults, or flipping user values back to >0
-        for (int i = 0; i < FACTORZ_COUNT; ++i) {
-            if (mFactors[i] <= 0.0f) {   // user values are zero or negative
-                mFactors[i] = -mFactors[i];
-            } else {
-                mFactors[i] *= defaultsAdjustment;
-            }
-        }
-        
-        // if verbose, show factors
-        
-        if (mVerbose > 0) {
-            System.out.println("// Event percentages:");
-            for (int i = 0; i < FACTORZ_COUNT; ++i) {
-                System.out.println("//   " + i + ": " + mFactors[i] + "%");
-            }
-        } 
-        
-        // finally, normalize and convert to running sum
-        float sum = 0.0f;
-        for (int i = 0; i < FACTORZ_COUNT; ++i) {
-            sum += mFactors[i] / 100.0f;
-            mFactors[i] = sum;
-        }        
-        return true;
-    }
-   
-    /**
-     * set the factors
-     * 
-     * @param factors: percentages for each type of event
-     */
-    public void setFactors(float factors[]) {
-        int c = FACTORZ_COUNT;
-        if (factors.length < c) {
-            c = factors.length;
-        }        
-        for (int i = 0; i < c; i++)
-            mFactors[i] = factors[i];
-    }
-    
-    public void setFactors(int index, float v) {
-        mFactors[index] = v;
-    }
-    
-    /**
-     * Generates a random motion event. This method counts a down, move, and up as multiple events.
-     * 
-     * TODO:  Test & fix the selectors when non-zero percentages
-     * TODO:  Longpress.
-     * TODO:  Fling.
-     * TODO:  Meta state
-     * TODO:  More useful than the random walk here would be to pick a single random direction
-     * and distance, and divvy it up into a random number of segments.  (This would serve to
-     * generate fling gestures, which are important).
-     * 
-     * @param random Random number source for positioning
-     * @param motionEvent If false, touch/release.  If true, touch/move/release. 
-     * 
-     */
-    private void generateMotionEvent(Random random, boolean motionEvent){
-        
-        Display display = WindowManagerImpl.getDefault().getDefaultDisplay();
-
-        float x = Math.abs(random.nextInt() % display.getWidth());
-        float y = Math.abs(random.nextInt() % display.getHeight());
-        long downAt = SystemClock.uptimeMillis();
-        long eventTime = SystemClock.uptimeMillis();
-        if (downAt == -1) {
-            downAt = eventTime;
-        }
-        
-        MonkeyMotionEvent e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_POINTER, 
-                downAt, MotionEvent.ACTION_DOWN, x, y, 0);        
-        e.setIntermediateNote(false);        
-        mQ.addLast(e);
-        
-        // sometimes we'll move during the touch
-        if (motionEvent) {
-            int count = random.nextInt(10);
-            for (int i = 0; i < count; i++) {
-                // generate some slop in the up event
-                x = (x + (random.nextInt() % 10)) % display.getWidth();
-                y = (y + (random.nextInt() % 10)) % display.getHeight();
-                
-                e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_POINTER, 
-                        downAt, MotionEvent.ACTION_MOVE, x, y, 0);        
-                e.setIntermediateNote(true);        
-                mQ.addLast(e);
-            }
-        }
-
-        // TODO generate some slop in the up event
-        e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_POINTER, 
-                downAt, MotionEvent.ACTION_UP, x, y, 0);        
-        e.setIntermediateNote(false);        
-        mQ.addLast(e);
-    }
-  
-    /**
-     * Generates a random trackball event. This consists of a sequence of small moves, followed by
-     * an optional single click.
-     * 
-     * TODO:  Longpress.
-     * TODO:  Meta state
-     * TODO:  Parameterize the % clicked
-     * TODO:  More useful than the random walk here would be to pick a single random direction
-     * and distance, and divvy it up into a random number of segments.  (This would serve to
-     * generate fling gestures, which are important).
-     * 
-     * @param random Random number source for positioning
-     * 
-     */
-    private void generateTrackballEvent(Random random) {
-        Display display = WindowManagerImpl.getDefault().getDefaultDisplay();
-
-        boolean drop = false;
-        int count = random.nextInt(10);
-        MonkeyMotionEvent e;
-        for (int i = 0; i < 10; ++i) {
-            // generate a small random step
-            int dX = random.nextInt(10) - 5;
-            int dY = random.nextInt(10) - 5;
-            
-            
-            e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_TRACKBALL, -1, 
-                    MotionEvent.ACTION_MOVE, dX, dY, 0);        
-            e.setIntermediateNote(i > 0);        
-            mQ.addLast(e);
-        }
-        
-        // 10% of trackball moves end with a click
-        if (0 == random.nextInt(10)) {
-            long downAt = SystemClock.uptimeMillis();
-            
-            
-            e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_TRACKBALL, downAt, 
-                    MotionEvent.ACTION_DOWN, 0, 0, 0);        
-            e.setIntermediateNote(true);        
-            mQ.addLast(e);
-            
-            
-            e = new MonkeyMotionEvent(MonkeyEvent.EVENT_TYPE_TRACKBALL, downAt, 
-                    MotionEvent.ACTION_UP, 0, 0, 0);        
-            e.setIntermediateNote(false);        
-            mQ.addLast(e);
-        }        
-    }
-    
-    /** 
-     * generate a random event based on mFactor
-     */
-    private void generateEvents() {        
-        float cls = mRandom.nextFloat();
-        int lastKey = 0;
-
-        boolean touchEvent = cls < mFactors[FACTOR_TOUCH];
-        boolean motionEvent = !touchEvent && (cls < mFactors[FACTOR_MOTION]);
-        if (touchEvent || motionEvent) {            
-            generateMotionEvent(mRandom, motionEvent);
-            return;
-        }
-        
-        if (cls < mFactors[FACTOR_TRACKBALL]) {            
-            generateTrackballEvent(mRandom);
-            return;
-        }
-
-        // The remaining event categories are injected as key events
-        if (cls < mFactors[FACTOR_NAV]) {
-            lastKey = NAV_KEYS[mRandom.nextInt(NAV_KEYS.length)];
-        } else if (cls < mFactors[FACTOR_MAJORNAV]) {
-            lastKey = MAJOR_NAV_KEYS[mRandom.nextInt(MAJOR_NAV_KEYS.length)];
-        } else if (cls < mFactors[FACTOR_SYSOPS]) {
-            lastKey = SYS_KEYS[mRandom.nextInt(SYS_KEYS.length)];
-        } else if (cls < mFactors[FACTOR_APPSWITCH]) {
-            MonkeyActivityEvent e = new MonkeyActivityEvent(mMainApps.get(
-                    mRandom.nextInt(mMainApps.size())));
-            mQ.addLast(e);
-            return;
-        } else if (cls < mFactors[FACTOR_FLIP]) {
-            MonkeyFlipEvent e = new MonkeyFlipEvent(mKeyboardOpen);
-            mKeyboardOpen = !mKeyboardOpen;
-            mQ.addLast(e);
-            return;
-        } else {
-            lastKey = 1 + mRandom.nextInt(KeyEvent.getMaxKeyCode() - 1);
-        }
-                
-        MonkeyKeyEvent e = new MonkeyKeyEvent(KeyEvent.ACTION_DOWN, lastKey);
-        mQ.addLast(e);
-        
-        e = new MonkeyKeyEvent(KeyEvent.ACTION_UP, lastKey);
-        mQ.addLast(e);
-    }
-    
-    public boolean validate() {
-        //check factors
-        return adjustEventFactors();
-    }
-    
-    public void setVerbose(int verbose) {
-        mVerbose = verbose;
-    }
-    
-    /**
-     * generate an activity event
-     */
-    public void generateActivity() {
-        MonkeyActivityEvent e = new MonkeyActivityEvent(mMainApps.get(
-                mRandom.nextInt(mMainApps.size())));
-        mQ.addLast(e);
-    }
-    
-    /**
-     * if the queue is empty, we generate events first
-     * @return the first event in the queue 
-     */
-    public MonkeyEvent getNextEvent() {
-        if (mQ.isEmpty()) {
-                generateEvents();
-        }        
-        mEventCount++;        
-        MonkeyEvent e = mQ.getFirst();        
-        mQ.removeFirst();        
-        return e;
-    }
-}
diff --git a/cmds/monkey/src/com/android/commands/monkey/MonkeySourceScript.java b/cmds/monkey/src/com/android/commands/monkey/MonkeySourceScript.java
deleted file mode 100644
index aadda9f..0000000
--- a/cmds/monkey/src/com/android/commands/monkey/MonkeySourceScript.java
+++ /dev/null
@@ -1,427 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.commands.monkey;
-
-import android.os.SystemClock;
-import android.view.KeyEvent;
-
-import java.io.BufferedReader;
-import java.io.DataInputStream;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.LinkedList;
-import java.util.StringTokenizer;
-
-/**
- * monkey event queue. It takes a script to produce events
- * 
- * sample script format:
- *      type= raw events
- *      count= 10
- *      speed= 1.0
- *      captureDispatchPointer(5109520,5109520,0,230.75429,458.1814,0.20784314,
- *          0.06666667,0,0.0,0.0,65539,0)
- *      captureDispatchKey(5113146,5113146,0,20,0,0,0,0)
- *      captureDispatchFlip(true)
- *      ...
- */
-public class MonkeySourceScript implements MonkeyEventSource{    
-    private int mEventCountInScript = 0;  //total number of events in the file
-    private int mVerbose = 0;
-    private double mSpeed = 1.0;
-    private String mScriptFileName; 
-    private LinkedList<MonkeyEvent> mQ = new LinkedList<MonkeyEvent>();
-    
-    private static final String HEADER_TYPE = "type=";
-    private static final String HEADER_COUNT = "count=";
-    private static final String HEADER_SPEED = "speed=";
-    
-    private long mLastRecordedDownTimeKey = 0;    
-    private long mLastRecordedDownTimeMotion = 0;
-    private long mLastExportDownTimeKey = 0;
-    private long mLastExportDownTimeMotion = 0;
-    private long mLastExportEventTime = -1;
-    private long mLastRecordedEventTime = -1;
-    
-    private static final boolean THIS_DEBUG = false;
-    // a parameter that compensates the difference of real elapsed time and 
-    // time in theory
-    private static final long SLEEP_COMPENSATE_DIFF = 16;    
-    
-    // maximum number of events that we read at one time
-    private static final int MAX_ONE_TIME_READS = 100;
-    
-    // number of additional events added to the script 
-    // add HOME_KEY down and up events to make start UI consistent in each round 
-    private static final int POLICY_ADDITIONAL_EVENT_COUNT = 2;
-
-    // event key word in the capture log    
-    private static final String EVENT_KEYWORD_POINTER = "DispatchPointer";
-    private static final String EVENT_KEYWORD_TRACKBALL = "DispatchTrackball";
-    private static final String EVENT_KEYWORD_KEY = "DispatchKey";
-    private static final String EVENT_KEYWORD_FLIP = "DispatchFlip";
-    
-    // a line at the end of the header
-    private static final String STARTING_DATA_LINE = "start data >>";    
-    private boolean mFileOpened = false;    
-    FileInputStream mFStream;
-    DataInputStream mInputStream;
-    BufferedReader mBufferReader;
-    
-    public MonkeySourceScript(String filename) {
-        mScriptFileName = filename;
-    }
-    
-    /**
-     * 
-     * @return the number of total events that will be generated in a round 
-     */
-    public int getOneRoundEventCount() {
-        //plus one home key down and up event
-        return mEventCountInScript + POLICY_ADDITIONAL_EVENT_COUNT; 
-    }
-    
-    private void resetValue() {
-        mLastRecordedDownTimeKey = 0;    
-        mLastRecordedDownTimeMotion = 0;
-        mLastExportDownTimeKey = 0;
-        mLastExportDownTimeMotion = 0;    
-        mLastRecordedEventTime = -1;        
-        mLastExportEventTime = -1;
-    }
-    
-    private boolean readScriptHeader() {
-        mEventCountInScript = -1;
-        mFileOpened = false;        
-        try {
-            if (THIS_DEBUG) {
-                System.out.println("reading script header");
-            }
-            
-            mFStream  =  new FileInputStream(mScriptFileName);
-            mInputStream  = new DataInputStream(mFStream);
-            mBufferReader = new BufferedReader(
-                    new InputStreamReader(mInputStream));
-            String sLine;
-            while ((sLine = mBufferReader.readLine()) != null) {
-                sLine = sLine.trim();
-                if (sLine.indexOf(HEADER_TYPE) >= 0) {
-                    // at this point, we only have one type of script
-                } else if (sLine.indexOf(HEADER_COUNT) >= 0) {
-                    try {
-                        mEventCountInScript = Integer.parseInt(sLine.substring(
-                                HEADER_COUNT.length() + 1).trim());
-                    } catch (NumberFormatException e) {
-                        System.err.println(e);
-                    }
-                } else if (sLine.indexOf(HEADER_SPEED) >= 0) {
-                    try {
-                        mSpeed = Double.parseDouble(sLine.substring(
-                                HEADER_SPEED.length() + 1).trim());
-                        
-                    } catch (NumberFormatException e) {
-                        System.err.println(e);
-                    }
-                } else if (sLine.indexOf(STARTING_DATA_LINE) >= 0) {
-                    // header ends until we read the start data mark
-                    mFileOpened = true;
-                    if (THIS_DEBUG) {
-                        System.out.println("read script header success");
-                    }    
-                    return true;
-                }
-            }            
-        } catch (FileNotFoundException e) {
-            System.err.println(e);
-        } catch (IOException e) {
-            System.err.println(e);
-        }
-        
-        if (THIS_DEBUG) {
-            System.out.println("Error in reading script header");
-        }        
-        return false;        
-    }    
-    
-    private void processLine(String s) {
-        int index1 = s.indexOf('(');
-        int index2 = s.indexOf(')');
-        
-        if (index1 < 0 || index2 < 0) {
-            return;
-        }
-        
-        StringTokenizer st = new StringTokenizer(
-                s.substring(index1 + 1, index2), ",");
-        
-        if (s.indexOf(EVENT_KEYWORD_KEY) >= 0) {
-            // key events
-            try {
-                long downTime = Long.parseLong(st.nextToken());
-                long eventTime = Long.parseLong(st.nextToken());
-                int action = Integer.parseInt(st.nextToken());
-                int code = Integer.parseInt(st.nextToken());
-                int repeat = Integer.parseInt(st.nextToken());
-                int metaState = Integer.parseInt(st.nextToken());
-                int device = Integer.parseInt(st.nextToken());
-                int scancode = Integer.parseInt(st.nextToken());
-                
-                MonkeyKeyEvent e = new MonkeyKeyEvent(downTime, eventTime,
-                        action, code, repeat, metaState, device, scancode);
-                mQ.addLast(e);
-                
-            } catch (NumberFormatException e) {
-                // something wrong with this line in the script               
-            }
-        } else if (s.indexOf(EVENT_KEYWORD_POINTER) >= 0 || 
-                s.indexOf(EVENT_KEYWORD_TRACKBALL) >= 0) {
-            // trackball/pointer event 
-            try {                
-                long downTime = Long.parseLong(st.nextToken());
-                long eventTime = Long.parseLong(st.nextToken());
-                int action = Integer.parseInt(st.nextToken());
-                float x = Float.parseFloat(st.nextToken());
-                float y = Float.parseFloat(st.nextToken());
-                float pressure = Float.parseFloat(st.nextToken());
-                float size = Float.parseFloat(st.nextToken());
-                int metaState = Integer.parseInt(st.nextToken());
-                float xPrecision = Float.parseFloat(st.nextToken());
-                float yPrecision = Float.parseFloat(st.nextToken());
-                int device = Integer.parseInt(st.nextToken());
-                int edgeFlags = Integer.parseInt(st.nextToken());
-                
-                int type = MonkeyEvent.EVENT_TYPE_TRACKBALL;                
-                if (s.indexOf("Pointer") > 0) {
-                    type = MonkeyEvent.EVENT_TYPE_POINTER;
-                }                
-                MonkeyMotionEvent e = new MonkeyMotionEvent(type, downTime, eventTime,
-                        action, x, y, pressure, size, metaState, xPrecision, yPrecision,
-                        device, edgeFlags);
-                mQ.addLast(e);                
-            } catch (NumberFormatException e) {
-                // we ignore this event                
-            }
-        } else if (s.indexOf(EVENT_KEYWORD_FLIP) >= 0) {
-            boolean keyboardOpen = Boolean.parseBoolean(st.nextToken());
-            MonkeyFlipEvent e = new MonkeyFlipEvent(keyboardOpen);
-            mQ.addLast(e);
-        }
-    }
-    
-    private void closeFile() {
-        mFileOpened = false;        
-        if (THIS_DEBUG) {
-            System.out.println("closing script file");
-        }
-        
-        try {
-            mFStream.close();
-            mInputStream.close();
-        } catch (IOException e) {
-            System.out.println(e);
-        }
-    }
-    
-    /**
-     * add home key press/release event to the queue
-     */
-    private void addHomeKeyEvent() {        
-        MonkeyKeyEvent e = new MonkeyKeyEvent(KeyEvent.ACTION_DOWN, 
-                KeyEvent.KEYCODE_HOME);
-        mQ.addLast(e);        
-        e = new MonkeyKeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_HOME);
-        mQ.addLast(e);
-    }
-    
-    /**
-     * read next batch of events from the provided script file
-     * @return true if success
-     */
-    private boolean readNextBatch() {
-        String sLine = null;
-        int readCount = 0;
-        
-        if (THIS_DEBUG) {
-            System.out.println("readNextBatch(): reading next batch of events");
-        }
-        
-        if (!mFileOpened) {
-            if (!readScriptHeader()) {
-                closeFile();
-                return false;
-            }             
-            resetValue();
-            
-            /* 
-            * In order to allow the Monkey to replay captured events multiple times
-            * we need to define a default start UI, which is the home screen
-            * Otherwise, it won't be accurate since the captured events 
-            * could end anywhere
-            */
-            addHomeKeyEvent();
-        }
-        
-        try {            
-            while (readCount++ < MAX_ONE_TIME_READS &&                    
-                   (sLine = mBufferReader.readLine()) != null) {
-                sLine = sLine.trim();                        
-                processLine(sLine);
-            }
-        } catch (IOException e) {
-            System.err.println(e);
-            return false;
-        }
-        
-        if (sLine == null) {
-            // to the end of the file
-            if (THIS_DEBUG) {
-                System.out.println("readNextBatch(): to the end of file");
-            }
-            closeFile();
-        }        
-        return true;
-    }
-    
-    /**
-     * sleep for a period of given time, introducing latency among events
-     * @param time to sleep in millisecond
-     */
-    private void needSleep(long time) {        
-        if (time < 1) {
-            return;    
-        }        
-        try {
-            Thread.sleep(time);
-        } catch (InterruptedException e) {            
-        }        
-    }    
-    
-    /**
-     * check whether we can successfully read the header of the script file
-     */
-    public boolean validate() {
-        boolean b = readNextBatch(); 
-        if (mVerbose > 0) {
-            System.out.println("Replaying " + mEventCountInScript + 
-                    " events with speed " + mSpeed);
-        }
-        return b;        
-    }
-    
-    public void setVerbose(int verbose) {
-        mVerbose = verbose;
-    }
-    
-    /**
-     * adjust key downtime and eventtime according to both  
-     * recorded values and current system time 
-     * @param e KeyEvent
-     */
-    private void adjustKeyEventTime(MonkeyKeyEvent e) {
-        if (e.getEventTime() < 0) {
-            return;
-        }      
-        long thisDownTime = 0;
-        long thisEventTime = 0;
-        long expectedDelay = 0;
-        
-        if (mLastRecordedEventTime <= 0) {
-            // first time event            
-            thisDownTime = SystemClock.uptimeMillis();
-            thisEventTime = thisDownTime;
-        } else {            
-            if (e.getDownTime() != mLastRecordedDownTimeKey) {
-                thisDownTime = e.getDownTime();
-            } else {
-                thisDownTime = mLastExportDownTimeKey;
-            }            
-            expectedDelay = (long) ((e.getEventTime() - 
-                    mLastRecordedEventTime) * mSpeed);            
-            thisEventTime = mLastExportEventTime + expectedDelay;
-            // add sleep to simulate everything in recording
-            needSleep(expectedDelay - SLEEP_COMPENSATE_DIFF);
-        }        
-        mLastRecordedDownTimeKey = e.getDownTime();
-        mLastRecordedEventTime = e.getEventTime();         
-        e.setDownTime(thisDownTime);
-        e.setEventTime(thisEventTime);        
-        mLastExportDownTimeKey = thisDownTime;
-        mLastExportEventTime =  thisEventTime;
-    }
-    
-    /**
-     * adjust motion downtime and eventtime according to both  
-     * recorded values and current system time 
-     * @param e KeyEvent
-     */
-    private void adjustMotionEventTime(MonkeyMotionEvent e) {
-        if (e.getEventTime() < 0) {
-            return;
-        }      
-        long thisDownTime = 0;
-        long thisEventTime = 0;
-        long expectedDelay = 0;
-        
-        if (mLastRecordedEventTime <= 0) {
-            // first time event            
-            thisDownTime = SystemClock.uptimeMillis();
-            thisEventTime = thisDownTime;
-        } else {            
-            if (e.getDownTime() != mLastRecordedDownTimeMotion) {
-                thisDownTime = e.getDownTime();
-            } else {
-                thisDownTime = mLastExportDownTimeMotion;
-            }            
-            expectedDelay = (long) ((e.getEventTime() - 
-                    mLastRecordedEventTime) * mSpeed);            
-            thisEventTime = mLastExportEventTime + expectedDelay;
-            // add sleep to simulate everything in recording
-            needSleep(expectedDelay - SLEEP_COMPENSATE_DIFF);
-        }
-        
-        mLastRecordedDownTimeMotion = e.getDownTime();
-        mLastRecordedEventTime = e.getEventTime();         
-        e.setDownTime(thisDownTime);
-        e.setEventTime(thisEventTime);        
-        mLastExportDownTimeMotion = thisDownTime;
-        mLastExportEventTime =  thisEventTime;
-    }    
-    
-    /**
-     * if the queue is empty, we generate events first
-     * @return the first event in the queue, if null, indicating the system crashes 
-     */
-    public MonkeyEvent getNextEvent() {
-        long recordedEventTime = -1;
-        
-        if (mQ.isEmpty()) {
-            readNextBatch();
-        }
-        MonkeyEvent e = mQ.getFirst();
-        mQ.removeFirst();
-        
-        if (e.getEventType() == MonkeyEvent.EVENT_TYPE_KEY) {
-            adjustKeyEventTime((MonkeyKeyEvent) e);        
-        } else if (e.getEventType() == MonkeyEvent.EVENT_TYPE_POINTER || 
-                e.getEventType() == MonkeyEvent.EVENT_TYPE_TRACKBALL) {
-            adjustMotionEventTime((MonkeyMotionEvent) e);
-        }
-        return e;
-    }
-}
diff --git a/data/etc/apns-conf_sdk.xml b/data/etc/apns-conf_sdk.xml
deleted file mode 100644
index 5129dc7..0000000
--- a/data/etc/apns-conf_sdk.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file contains fake APNs that are necessary for the emulator
-     to talk to the network.  It should only be installed for SDK builds.
-
-     This file is not installed by the local Android.mk, it's installed using
-     a PRODUCT_COPY_FILES line in the sdk section of the toplevel Makefile.
--->
-
-<!-- use empty string to specify no proxy or port -->
-<!-- This version must agree with that in apps/common/res/apns.xml -->
-<apns version="6">
-    <apn carrier="Android"
-        mcc="310"
-        mnc="995"
-        apn="internet"
-        user="*"
-        server="*"
-        password="*"
-        mmsc="null"
-    />
-    <apn carrier="TelKila"
-        mcc="310"
-        mnc="260"
-        apn="internet"
-        user="*"
-        server="*"
-        password="*"
-        mmsc="null"
-    />
-</apns>
diff --git a/docs/SDK_RELEASE_NOTES b/docs/SDK_RELEASE_NOTES
deleted file mode 100644
index e117528..0000000
--- a/docs/SDK_RELEASE_NOTES
+++ /dev/null
@@ -1,8 +0,0 @@
-<html>
-<head>
-<meta http-equiv="refresh" content="0;url=docs/sdk/1.1_r1/index.html">
-</head>
-<body>
-<a href="docs/sdk/1.1_r1/index.html">click here if you are not redirected</a>
-</body>
-</html>
\ No newline at end of file
diff --git a/emulator/keymaps/Android.mk b/emulator/keymaps/Android.mk
deleted file mode 100644
index 90db52e..0000000
--- a/emulator/keymaps/Android.mk
+++ /dev/null
@@ -1,13 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := qwerty.kcm
-include $(BUILD_KEY_CHAR_MAP)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := qwerty2.kcm
-include $(BUILD_KEY_CHAR_MAP)
-
-file := $(TARGET_OUT_KEYLAYOUT)/qwerty.kl
-ALL_PREBUILT += $(file)
-$(file): $(LOCAL_PATH)/qwerty.kl | $(ACP)
-	$(transform-prebuilt-to-target)
diff --git a/emulator/keymaps/qwerty.kcm b/emulator/keymaps/qwerty.kcm
deleted file mode 100644
index 8056364..0000000
--- a/emulator/keymaps/qwerty.kcm
+++ /dev/null
@@ -1,64 +0,0 @@
-[type=QWERTY]                                           
-                                                        
-# keycode       display number  base    caps    fn      caps_fn
-                                                        
-A               'A'     '2'     'a'     'A'     '#'     0x00
-B               'B'     '2'     'b'     'B'     '<'     0x00
-C               'C'     '2'     'c'     'C'     '9'     0x00E7
-D               'D'     '3'     'd'     'D'     '5'     0x00
-E               'E'     '3'     'e'     'E'     '2'     0x0301
-F               'F'     '3'     'f'     'F'     '6'     0x00A5
-G               'G'     '4'     'g'     'G'     '-'     '_'
-H               'H'     '4'     'h'     'H'     '['     '{'
-I               'I'     '4'     'i'     'I'     '$'     0x0302
-J               'J'     '5'     'j'     'J'     ']'     '}'
-K               'K'     '5'     'k'     'K'     '"'     '~'
-L               'L'     '5'     'l'     'L'     '''     '`'
-M               'M'     '6'     'm'     'M'     '!'     0x00
-N               'N'     '6'     'n'     'N'     '>'     0x0303
-O               'O'     '6'     'o'     'O'     '('     0x00
-P               'P'     '7'     'p'     'P'     ')'     0x00
-Q               'Q'     '7'     'q'     'Q'     '*'     0x0300
-R               'R'     '7'     'r'     'R'     '3'     0x20AC
-S               'S'     '7'     's'     'S'     '4'     0x00DF
-T               'T'     '8'     't'     'T'     '+'     0x00A3
-U               'U'     '8'     'u'     'U'     '&'     0x0308
-V               'V'     '8'     'v'     'V'     '='     '^'
-W               'W'     '9'     'w'     'W'     '1'     0x00
-X               'X'     '9'     'x'     'X'     '8'     0xEF00
-Y               'Y'     '9'     'y'     'Y'     '%'     0x00A1
-Z               'Z'     '9'     'z'     'Z'     '7'     0x00
-                                                        
-# on pc keyboards
-COMMA           ','     ','     ','     ';'     ';'     '|'
-PERIOD          '.'     '.'     '.'     ':'     ':'     0x2026
-AT              '@'     '0'     '@'     '0'     '0'     0x2022
-SLASH           '/'     '/'     '/'     '?'     '?'     '\'
-                                                        
-SPACE           0x20    0x20    0x20    0x20    0xEF01  0xEF01
-ENTER         0xa     0xa     0xa     0xa     0xa     0xa
-                                                        
-TAB             0x9     0x9     0x9     0x9     0x9     0x9
-0               '0'     '0'     '0'     ')'     ')'     ')'
-1               '1'     '1'     '1'     '!'     '!'     '!'
-2               '2'     '2'     '2'     '@'     '@'     '@'
-3               '3'     '3'     '3'     '#'     '#'     '#'
-4               '4'     '4'     '4'     '$'     '$'     '$'
-5               '5'     '5'     '5'     '%'     '%'     '%'
-6               '6'     '6'     '6'     '^'     '^'     '^'
-7               '7'     '7'     '7'     '&'     '&'     '&'
-8               '8'     '8'     '8'     '*'     '*'     '*'
-9               '9'     '9'     '9'     '('     '('     '('
-                                                        
-GRAVE           '`'     '`'     '`'     '~'     '`'     '~'
-MINUS           '-'     '-'     '-'     '_'     '-'     '_'
-EQUALS          '='     '='     '='     '+'     '='     '+'
-LEFT_BRACKET    '['     '['     '['     '{'     '['     '{'
-RIGHT_BRACKET   ']'     ']'     ']'     '}'     ']'     '}'
-BACKSLASH       '\'     '\'     '\'     '|'     '\'     '|'
-SEMICOLON       ';'     ';'     ';'     ':'     ';'     ':'
-APOSTROPHE      '''     '''     '''     '"'     '''     '"'
-STAR            '*'     '*'     '*'     '*'     '*'     '*'
-POUND           '#'     '#'     '#'     '#'     '#'     '#'
-PLUS            '+'     '+'     '+'     '+'     '+'     '+'
-                                                        
diff --git a/emulator/keymaps/qwerty.kl b/emulator/keymaps/qwerty.kl
deleted file mode 100644
index c525fdd..0000000
--- a/emulator/keymaps/qwerty.kl
+++ /dev/null
@@ -1,89 +0,0 @@
-key 399   GRAVE
-key 2     1
-key 3     2
-key 4     3
-key 5     4
-key 6     5
-key 7     6
-key 8     7
-key 9     8
-key 10    9
-key 11    0
-key 158   BACK              WAKE_DROPPED
-key 230   SOFT_RIGHT        WAKE
-key 60    SOFT_RIGHT        WAKE
-key 107   ENDCALL           WAKE_DROPPED
-key 62    ENDCALL           WAKE_DROPPED
-key 229   MENU              WAKE_DROPPED
-key 139   MENU              WAKE_DROPPED
-key 59    MENU              WAKE_DROPPED
-key 127   SEARCH            WAKE_DROPPED
-key 217   SEARCH            WAKE_DROPPED
-key 228   POUND
-key 227   STAR
-key 231   CALL              WAKE_DROPPED
-key 61    CALL              WAKE_DROPPED
-key 232   DPAD_CENTER       WAKE_DROPPED
-key 108   DPAD_DOWN         WAKE_DROPPED
-key 103   DPAD_UP           WAKE_DROPPED
-key 102   HOME              WAKE
-key 105   DPAD_LEFT         WAKE_DROPPED
-key 106   DPAD_RIGHT        WAKE_DROPPED
-key 115   VOLUME_UP
-key 114   VOLUME_DOWN
-key 116   POWER             WAKE
-key 212   CAMERA
-
-key 16    Q
-key 17    W
-key 18    E
-key 19    R
-key 20    T
-key 21    Y
-key 22    U
-key 23    I
-key 24    O
-key 25    P
-key 26    LEFT_BRACKET
-key 27    RIGHT_BRACKET
-key 43    BACKSLASH
-
-key 30    A
-key 31    S
-key 32    D
-key 33    F
-key 34    G
-key 35    H
-key 36    J
-key 37    K
-key 38    L
-key 39    SEMICOLON
-key 40    APOSTROPHE
-key 14    DEL
-        
-key 44    Z
-key 45    X
-key 46    C
-key 47    V
-key 48    B
-key 49    N
-key 50    M
-key 51    COMMA
-key 52    PERIOD
-key 53    SLASH
-key 28    ENTER
-        
-key 56    ALT_LEFT
-key 100   ALT_RIGHT
-key 42    SHIFT_LEFT
-key 54    SHIFT_RIGHT
-key 15    TAB
-key 57    SPACE
-key 150   EXPLORER
-key 155   ENVELOPE        
-
-key 12    MINUS
-key 13    EQUALS
-key 215   AT
-
-
diff --git a/emulator/keymaps/qwerty2.kcm b/emulator/keymaps/qwerty2.kcm
deleted file mode 100644
index 1487fb7..0000000
--- a/emulator/keymaps/qwerty2.kcm
+++ /dev/null
@@ -1,81 +0,0 @@
-[type=QWERTY]                                           
-                                                        
-# this keymap is to be used in the emulator only. note
-# that I have liberally modified certain key strokes to
-# make it more usable in this context. the main differences
-# with the reference keyboard image are:
-#
-#  - cap-2 produces '@', and not '"', without that, typing
-#    email addresses becomes a major pain with a qwerty
-#    keyboard. note that you can type '"' with fn-E anyway.
-#
-#  - cap-COMMA and cap-PERIOD return '<' and '>', instead
-#    of nothing.
-#
-#
-                                                        
-# keycode       display  number base    caps    fn      caps_fn
-                                                        
-A               'A'     '2'     'a'     'A'     'a'     'A'
-B               'B'     '2'     'b'     'B'     'b'     'B'
-C               'C'     '2'     'c'     'C'     0x00e7  0x00E7
-D               'D'     '3'     'd'     'D'     '''     '''
-E               'E'     '3'     'e'     'E'     '"'     0x0301
-F               'F'     '3'     'f'     'F'     '['     '['
-G               'G'     '4'     'g'     'G'     ']'     ']'
-H               'H'     '4'     'h'     'H'     '<'     '<'
-I               'I'     '4'     'i'     'I'     '-'     0x0302
-J               'J'     '5'     'j'     'J'     '>'     '>'
-K               'K'     '5'     'k'     'K'     ';'     '~'
-L               'L'     '5'     'l'     'L'     ':'     '`'
-M               'M'     '6'     'm'     'M'     '%'     0x00
-N               'N'     '6'     'n'     'N'     0x00    0x0303
-O               'O'     '6'     'o'     'O'     '+'     '+'
-P               'P'     '7'     'p'     'P'     '='     0x00A5
-Q               'Q'     '7'     'q'     'Q'     '|'     0x0300
-R               'R'     '7'     'r'     'R'     '`'     0x20AC
-S               'S'     '7'     's'     'S'     '\'     0x00DF
-T               'T'     '8'     't'     'T'     '{'     0x00A3
-U               'U'     '8'     'u'     'U'     '_'     0x0308
-V               'V'     '8'     'v'     'V'     'v'     'V'
-W               'W'     '9'     'w'     'W'     '~'     '~'
-X               'X'     '9'     'x'     'X'     'x'     0xEF00
-Y               'Y'     '9'     'y'     'Y'     '}'     0x00A1
-Z               'Z'     '9'     'z'     'Z'     'z'     'Z'
-                                                        
-COMMA           ','     ','     ','     '<'     ','     ','
-PERIOD          '.'     '.'     '.'     '>'     '.'     0x2026
-AT              '@'     '@'     '@'     '@'     '@'     0x2022
-SLASH           '/'     '/'     '/'     '?'     '?'     '?'
-                                                        
-SPACE           0x20    0x20    0x20    0x20    0xEF01  0xEF01
-ENTER         0xa     0xa     0xa     0xa     0xa     0xa
-                                                        
-0               '0'     '0'     '0'     ')'     ')'     ')'
-1               '1'     '1'     '1'     '!'     '!'     '!'
-2               '2'     '2'     '2'     '@'     '@'     '@'
-3               '3'     '3'     '3'     '#'     '#'     '#'
-4               '4'     '4'     '4'     '$'     '$'     '$'
-5               '5'     '5'     '5'     '%'     '%'     '%'
-6               '6'     '6'     '6'     '^'     '^'     '^'
-7               '7'     '7'     '7'     '&'     '&'     '&'
-8               '8'     '8'     '8'     '*'     '*'     '*'
-9               '9'     '9'     '9'     '('     '('     '('
-                                                        
-# the rest is for a qwerty keyboard
-#
-TAB             0x9     0x9     0x9     0x9     0x9     0x9
-GRAVE           '`'     '`'     '`'     '~'     '`'     '~'
-MINUS           '-'     '-'     '-'     '_'     '-'     '_'
-EQUALS          '='     '='     '='     '+'     '='     '+'
-LEFT_BRACKET    '['     '['     '['     '{'     '['     '{'
-RIGHT_BRACKET   ']'     ']'     ']'     '}'     ']'     '}'
-BACKSLASH       '\'     '\'     '\'     '|'     '\'     '|'
-SEMICOLON       ';'     ';'     ';'     ':'     ';'     ':'
-APOSTROPHE      '''     '''     '''     '"'     '''     '"'
-STAR            '*'     '*'     '*'     '*'     '*'     '*'
-POUND           '#'     '#'     '#'     '#'     '#'     '#'
-PLUS            '+'     '+'     '+'     '+'     '+'     '+'
-                                                        
-                                                        
-                                                        
diff --git a/emulator/mksdcard/Android.mk b/emulator/mksdcard/Android.mk
deleted file mode 100644
index a5641b4..0000000
--- a/emulator/mksdcard/Android.mk
+++ /dev/null
@@ -1,11 +0,0 @@
-# Copyright 2006 The Android Open Source Project
-
-LOCAL_PATH:= $(call my-dir)
-
-# host executable
-#
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES:= mksdcard.c
-LOCAL_MODULE = mksdcard
-include $(BUILD_HOST_EXECUTABLE)
-
diff --git a/emulator/mksdcard/mksdcard.c b/emulator/mksdcard/mksdcard.c
deleted file mode 100644
index c85d0f8..0000000
--- a/emulator/mksdcard/mksdcard.c
+++ /dev/null
@@ -1,304 +0,0 @@
-/* mksdcard.c
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are met:
-**     * Redistributions of source code must retain the above copyright
-**       notice, this list of conditions and the following disclaimer.
-**     * Redistributions in binary form must reproduce the above copyright
-**       notice, this list of conditions and the following disclaimer in the
-**       documentation and/or other materials provided with the distribution.
-**     * Neither the name of Google Inc. nor the names of its contributors may
-**       be used to endorse or promote products derived from this software
-**       without specific prior written permission.
-**
-** THIS SOFTWARE IS PROVIDED BY Google Inc. ``AS IS'' AND ANY EXPRESS OR
-** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
-** MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
-** EVENT SHALL Google Inc. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-** PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
-** OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-** WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
-** OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
-** ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-
-/* a simple and portable program used to generate a blank FAT32 image file
- *
- * usage:  mksdcard  [-l label] <size> <filename>
- */
-
-#include <time.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-#include <unistd.h>
-
-/* believe me, you *don't* want to change these constants !! */
-#define  BYTES_PER_SECTOR    512
-#define  RESERVED_SECTORS    32
-#define  BACKUP_BOOT_SECTOR  6
-#define  NUM_FATS            2
-
-typedef long long      Wide;   /* might be something else if you don't use GCC */
-typedef unsigned char  Byte;
-typedef Byte*          Bytes;
-
-#define  BYTE_(p,i)      (((Bytes)(p))[(i)])
-
-#define  POKEB(p,v)     BYTE_(p,0) = (Byte)(v)
-#define  POKES(p,v)   ( BYTE_(p,0) = (Byte)(v), BYTE_(p,1) = (Byte)((v) >> 8) )
-#define  POKEW(p,v)   ( BYTE_(p,0) = (Byte)(v), BYTE_(p,1) = (Byte)((v) >> 8), BYTE_(p,2) = (Byte)((v) >> 16), BYTE_(p,3) = (Byte)((v) >> 24) )
-
-static Byte  s_boot_sector   [ BYTES_PER_SECTOR ];       /* boot sector */
-static Byte  s_fsinfo_sector [ BYTES_PER_SECTOR ];   /* FS Info sector */
-static Byte  s_fat_head      [ BYTES_PER_SECTOR ];        /* first FAT sector */
-static Byte  s_zero_sector   [ BYTES_PER_SECTOR ];     /* empty sector */
-
-/* this is the date and time when creating the disk */
-static int
-get_serial_id( void )
-{
-    unsigned short  lo, hi, mid;
-    time_t          now = time(NULL);
-    struct tm       tm  = gmtime( &now )[0];
-
-    lo  = (unsigned short)(tm.tm_mday + ((tm.tm_mon+1) << 8) + (tm.tm_sec << 8));
-    hi  = (unsigned short)(tm.tm_min + (tm.tm_hour << 8) + (tm.tm_year + 1900));
-
-    return lo + (hi << 16);
-}
-
-static int
-get_sectors_per_cluster( Wide  disk_size )
-{
-    Wide  disk_MB = disk_size/(1024*1024);
-
-    if (disk_MB < 260)
-        return 1;
-
-    if (disk_MB < 8192)
-        return 4;
-
-    if (disk_MB < 16384)
-        return 8;
-
-    if (disk_MB < 32768)
-        return 16;
-
-    return 32;
-}
-
-static int
-get_sectors_per_fat( Wide  disk_size, int  sectors_per_cluster )
-{
-    Wide   divider;
-
-    /* weird computation from MS - see fatgen103.doc for details */
-    disk_size -= RESERVED_SECTORS * BYTES_PER_SECTOR;  /* don't count 32 reserved sectors */
-    disk_size /= BYTES_PER_SECTOR;       /* disk size in sectors */
-    divider = ((256 * sectors_per_cluster) + NUM_FATS) / 2;
-
-    return (int)( (disk_size + (divider-1)) / divider );
-}
-
-static void
-boot_sector_init( Bytes  boot, Bytes  info, Wide   disk_size, const char*  label )
-{
-    int   sectors_per_cluster = get_sectors_per_cluster(disk_size);
-    int   sectors_per_fat    = get_sectors_per_fat(disk_size, sectors_per_cluster);
-    int   sectors_per_disk   = (int)(disk_size / BYTES_PER_SECTOR);
-    int   serial_id          = get_serial_id();
-    int   free_count;
-
-    if (label == NULL)
-        label = "SDCARD";
-
-    POKEB(boot, 0xeb);
-    POKEB(boot+1, 0x5a);
-    POKEB(boot+2, 0x90);
-    strcpy( (char*)boot + 3, "MSWIN4.1" );
-    POKES( boot + 0x0b, BYTES_PER_SECTOR );    /* sector size */
-    POKEB( boot + 0xd, sectors_per_cluster );  /* sectors per cluster */
-    POKES( boot + 0xe, RESERVED_SECTORS );     /* reserved sectors before first FAT */
-    POKEB( boot + 0x10, NUM_FATS );            /* number of FATs */
-    POKES( boot + 0x11, 0 );                   /* max root directory entries for FAT12/FAT16, 0 for FAT32 */
-    POKES( boot + 0x13, 0 );                   /* total sectors, 0 to use 32-bit value at offset 0x20 */
-    POKEB( boot + 0x15, 0xF8 );                /* media descriptor, 0xF8 == hard disk */
-    POKES( boot + 0x16, 0 );                   /* Sectors per FAT for FAT12/16, 0 for FAT32 */
-    POKES( boot + 0x18, 9 );                   /* Sectors per track (whatever) */
-    POKES( boot + 0x1a, 2 );                   /* Number of heads (whatever) */
-    POKEW( boot + 0x1c, 0 );                   /* Hidden sectors */
-    POKEW( boot + 0x20, sectors_per_disk );    /* Total sectors */
-
-    /* extension */
-    POKEW( boot + 0x24, sectors_per_fat );       /* Sectors per FAT */
-    POKES( boot + 0x28, 0 );         /* FAT flags */
-    POKES( boot + 0x2a, 0 );         /* version */
-    POKEW( boot + 0x2c, 2 );         /* cluster number of root directory start */
-    POKES( boot + 0x30, 1 );         /* sector number of FS information sector */
-    POKES( boot + 0x32, BACKUP_BOOT_SECTOR );         /* sector number of a copy of this boot sector */
-    POKEB( boot + 0x40, 0x80 );      /* physical drive number */
-    POKEB( boot + 0x42, 0x29 );      /* extended boot signature ?? */
-    POKEW( boot + 0x43, serial_id ); /* serial ID */
-    strncpy( (char*)boot + 0x47, label, 11 );  /* Volume Label */
-    memcpy( boot + 0x52, "FAT32   ", 8 );  /* FAT system type, padded with 0x20 */
-
-    POKEB( boot + BYTES_PER_SECTOR-2, 0x55 );    /* boot sector signature */
-    POKEB( boot + BYTES_PER_SECTOR-1, 0xAA );
-
-    /* FSInfo sector */
-    free_count = sectors_per_disk - 32 - 2*sectors_per_fat;
-
-    POKEW( info + 0,   0x41615252 );
-    POKEW( info + 484, 0x61417272 );
-    POKEW( info + 488, free_count );   /* number of free clusters */
-    POKEW( info + 492, 3 );            /* next free clusters, 0-1 reserved, 2 is used for the root dir */
-    POKEW( info + 508, 0xAA550000 );
-}
-
-static void
-fat_init( Bytes  fat )
-{
-    POKEW( fat,     0x0ffffff8 );  /* reserve cluster 1, media id in low byte */
-    POKEW( fat + 4, 0x0fffffff );  /* reserve cluster 2 */
-    POKEW( fat + 8, 0x0fffffff );  /* end of clust chain for root dir */
-}
-
-
-static int
-write_sector( FILE*  file, Bytes  sector )
-{
-    return fwrite( sector, 1, 512, file ) != 512;
-}
-
-static int
-write_empty( FILE*   file, Wide  count )
-{
-    static  Byte  empty[64*1024];
-
-    count *= 512;
-    while (count > 0) {
-        int  len = sizeof(empty);
-        if (len > count)
-            len = count;
-
-        if ( fwrite( empty, 1, len, file ) != (size_t)len )
-            return 1;
-
-        count -= len;
-    }
-    return 0;
-}
-
-static void usage (void)
-{
-    fprintf(stderr, "mksdcard: create a blank FAT32 image to be used with the Android emulator\n" );
-    fprintf(stderr, "usage: mksdcard [-l label] <size> <file>\n\n");
-    fprintf(stderr, "  if <size> is a simple integer, it specifies a size in bytes\n" );
-    fprintf(stderr, "  if <size> is an integer followed by 'K', it specifies a size in KiB\n" );
-    fprintf(stderr, "  if <size> is an integer followed by 'M', it specifies a size in MiB\n" );
-    exit(1);
-}
-
-int  main( int argc, char**  argv )
-{
-    Wide   disk_size;
-    int    sectors_per_fat;
-    int    sectors_per_disk;
-    char*  end;
-    const char*  label = NULL;
-    FILE*  f;
-
-    for ( ; argc > 1 && argv[1][0] == '-'; argc--, argv++ )
-    {
-        char*  arg = argv[1] + 1;
-        switch (arg[0]) {
-            case 'l':
-                if (arg[1] != 0)
-                    arg += 2;
-                else {
-                    argc--;
-                    argv++;
-                    if (argc <= 1)
-                        usage();
-                    arg = argv[1];
-                }
-                label = arg;
-                break;
-
-            default:
-                usage();
-        }
-    }
-
-    if (argc != 3)
-        usage();
-
-    disk_size = strtol( argv[1], &end, 10 );
-    if (disk_size == 0 && errno == EINVAL)
-        usage();
-
-    if (*end == 'K')
-        disk_size *= 1024;
-    else if (*end == 'M')
-        disk_size *= 1024*1024;
-
-    if (disk_size < 8*1024*1024)
-        fprintf(stderr, "### WARNING : SD Card images < 8 MB cannot be used with the Android emulator\n");
-
-    sectors_per_disk = disk_size / 512;
-    sectors_per_fat  = get_sectors_per_fat( disk_size, get_sectors_per_cluster( disk_size ) );
-
-    boot_sector_init( s_boot_sector, s_fsinfo_sector, disk_size, NULL );
-    fat_init( s_fat_head );
-
-    f = fopen( argv[2], "wb" );
-    if ( !f ) {
-        fprintf(stderr, "could not create file '%s', aborting...\n", argv[2] );
-    }
-
-   /* here's the layout:
-    *
-    *  boot_sector
-    *  fsinfo_sector
-    *  empty
-    *  backup boot sector
-    *  backup fsinfo sector
-    *  RESERVED_SECTORS - 4 empty sectors (if backup sectors), or RESERVED_SECTORS - 2 (if no backup)
-    *  first fat
-    *  second fat
-    *  zero sectors
-   */
-
-    if ( write_sector( f, s_boot_sector ) )  goto FailWrite;
-    if ( write_sector( f, s_fsinfo_sector ) ) goto FailWrite;
-    if ( BACKUP_BOOT_SECTOR > 0 ) {
-        if ( write_empty( f, BACKUP_BOOT_SECTOR - 2 ) ) goto FailWrite;
-        if ( write_sector( f, s_boot_sector ) ) goto FailWrite;
-        if ( write_sector( f, s_fsinfo_sector ) ) goto FailWrite;
-        if ( write_empty( f, RESERVED_SECTORS - 2 - BACKUP_BOOT_SECTOR ) ) goto FailWrite;
-    }
-    else
-        if ( write_empty( f, RESERVED_SECTORS - 2 ) ) goto FailWrite;
-
-    if ( write_sector( f, s_fat_head ) ) goto FailWrite;
-    if ( write_empty( f, sectors_per_fat-1 ) ) goto FailWrite;
-
-    if ( write_sector( f, s_fat_head ) ) goto FailWrite;
-    if ( write_empty( f, sectors_per_fat-1 ) ) goto FailWrite;
-
-    if ( write_empty( f, sectors_per_disk - RESERVED_SECTORS - 2*sectors_per_fat ) ) goto FailWrite;
-
-    fclose(f);
-    return 0;
-
-FailWrite:
-    fprintf(stderr, "could not write to '%s', aborting...\n", argv[2] );
-    unlink( argv[2] );
-    fclose(f);
-    return 1;
-}
diff --git a/emulator/mksdcard/vfat-empty-32MB.img.gz b/emulator/mksdcard/vfat-empty-32MB.img.gz
deleted file mode 100644
index b205da3..0000000
--- a/emulator/mksdcard/vfat-empty-32MB.img.gz
+++ /dev/null
Binary files differ
diff --git a/emulator/qemud/Android.mk b/emulator/qemud/Android.mk
deleted file mode 100644
index 454f32d..0000000
--- a/emulator/qemud/Android.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES:= \
-	qemud.c
-
-
-LOCAL_SHARED_LIBRARIES := \
-	libcutils \
-
-LOCAL_MODULE:= qemud
-
-include $(BUILD_EXECUTABLE)
diff --git a/emulator/qemud/qemud.c b/emulator/qemud/qemud.c
deleted file mode 100644
index ae6797e..0000000
--- a/emulator/qemud/qemud.c
+++ /dev/null
@@ -1,1335 +0,0 @@
-#include <stdint.h>
-#include <stdarg.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <string.h>
-#include <sys/socket.h>
-#include <termios.h>
-#include <cutils/sockets.h>
-
-/*
- *  the qemud program is only used within the Android emulator as a bridge
- *  between the emulator program and the emulated system. it really works as
- *  a simple stream multiplexer that works as follows:
- *
- *    - qemud communicates with the emulator program through a single serial
- *      port, whose name is passed through a kernel boot parameter
- *      (e.g. android.qemud=ttyS1)
- *
- *    - qemud setups one or more unix local stream sockets in the
- *      emulated system each one of these represent a different communication
- *      'channel' between the emulator program and the emulated system.
- *
- *      as an example, one channel is used for the emulated GSM modem
- *      (AT command channel), another channel is used for the emulated GPS,
- *      etc...
- *
- *    - the protocol used on the serial connection is pretty simple:
- *
- *          offset    size    description
- *              0       4     4-char hex string giving the payload size
- *              4       2     2-char hex string giving the destination or
- *                            source channel
- *              6       n     the message payload
- *
- *      for emulator->system messages, the 'channel' index indicates
- *      to which channel the payload must be sent
- *
- *      for system->emulator messages, the 'channel' index indicates from
- *      which channel the payload comes from.
- *
- *   - a special channel index (0) is used to communicate with the qemud
- *     program directly from the emulator. this is used for the following
- *     commands:  (content of the payload):
- *
- *        request:  connect:<name>
- *        answer:   ok:connect:<name>:XX       // succesful name lookup
- *        answer:   ko:connect:bad name        // failed lookup
- *
- *           the emulator queries the index of a given channel given
- *           its human-readable name. the answer contains a 2-char hex
- *           string for the channel index.
- *
- *           not all emulated systems may need the same communication
- *           channels, so this function may fail.
- *
- *     any invalid request will get an answer of:
- *
- *           ko:unknown command
- *
- *
- *  here's a diagram of how things work:
- *
- *
- *                                                  _________
- *                        _____________   creates  |         |
- *         ________      |             |==========>| Channel |--*--
- *        |        |---->| Multiplexer |           |_________|
- *   --*--| Serial |     |_____________|               || creates
- *        |________|            |                 _____v___
- *             A                +--------------->|         |
- *             |                                 | Client  |--*--
- *             +---------------------------------|_________|
- *
- *  which really means that:
- *
- *    - the multiplexer creates one Channel object per control socket qemud
- *      handles (e.g. /dev/socket/qemud_gsm, /dev/socket/qemud_gps)
- *
- *    - each Channel object has a numerical index that is >= 1, and waits
- *      for client connection. it will create a Client object when this
- *      happens
- *
- *    - the Serial object receives packets from the serial port and sends them
- *      to the multiplexer
- *
- *    - the multiplexer tries to find a channel the packet is addressed to,
- *      and will send the packet to all clients that correspond to it
- *
- *    - when a Client receives data, it sends it directly to the Serial object
- *
- *    - there are two kinds of Channel objects:
- *
- *         CHANNEL_BROADCAST :: used for emulator -> clients broadcasts only
- *
- *         CHANNEL_DUPLEX    :: used for bidirectional communication with the
- *                              emulator, with only *one* client allowed per
- *                              duplex channel
- */
-
-#define  DEBUG  0
-
-#if DEBUG
-#  define LOG_TAG  "qemud"
-#  include <cutils/log.h>
-#  define  D(...)   LOGD(__VA_ARGS__)
-#else
-#  define  D(...)  ((void)0)
-#endif
-
-/** UTILITIES
- **/
-
-static void
-fatal( const char*  fmt, ... )
-{
-    va_list  args;
-    va_start(args, fmt);
-    fprintf(stderr, "PANIC: ");
-    vfprintf(stderr, fmt, args);
-    fprintf(stderr, "\n" );
-    va_end(args);
-    exit(1);
-}
-
-static void*
-xalloc( size_t   sz )
-{
-    void*  p;
-
-    if (sz == 0)
-        return NULL;
-
-    p = malloc(sz);
-    if (p == NULL)
-        fatal( "not enough memory" );
-
-    return p;
-}
-
-#define  xnew(p)   (p) = xalloc(sizeof(*(p)))
-
-static void*
-xalloc0( size_t  sz )
-{
-    void*  p = xalloc(sz);
-    memset( p, 0, sz );
-    return p;
-}
-
-#define  xnew0(p)   (p) = xalloc0(sizeof(*(p)))
-
-#define  xfree(p)    (free((p)), (p) = NULL)
-
-static void*
-xrealloc( void*  block, size_t  size )
-{
-    void*  p = realloc( block, size );
-
-    if (p == NULL && size > 0)
-        fatal( "not enough memory" );
-
-    return p;
-}
-
-#define  xrenew(p,count)  (p) = xrealloc((p),sizeof(*(p))*(count))
-
-static int
-hex2int( const uint8_t*  data, int  len )
-{
-    int  result = 0;
-    while (len > 0) {
-        int       c = *data++;
-        unsigned  d;
-
-        result <<= 4;
-        do {
-            d = (unsigned)(c - '0');
-            if (d < 10)
-                break;
-
-            d = (unsigned)(c - 'a');
-            if (d < 6) {
-                d += 10;
-                break;
-            }
-
-            d = (unsigned)(c - 'A');
-            if (d < 6) {
-                d += 10;
-                break;
-            }
-
-            return -1;
-        }
-        while (0);
-
-        result |= d;
-        len    -= 1;
-    }
-    return  result;
-}
-
-
-static void
-int2hex( int  value, uint8_t*  to, int  width )
-{
-    int  nn = 0;
-    static const char hexchars[16] = "0123456789abcdef";
-
-    for ( --width; width >= 0; width--, nn++ ) {
-        to[nn] = hexchars[(value >> (width*4)) & 15];
-    }
-}
-
-static int
-fd_read(int  fd, void*  to, int  len)
-{
-    int  ret;
-
-    do {
-        ret = read(fd, to, len);
-    } while (ret < 0 && errno == EINTR);
-
-    return ret;
-}
-
-static int
-fd_write(int  fd, const void*  from, int  len)
-{
-    int  ret;
-
-    do {
-        ret = write(fd, from, len);
-    } while (ret < 0 && errno == EINTR);
-
-    return ret;
-}
-
-static void
-fd_setnonblock(int  fd)
-{
-    int  ret, flags;
-
-    do {
-        flags = fcntl(fd, F_GETFD);
-    } while (flags < 0 && errno == EINTR);
-
-    if (flags < 0) {
-        fatal( "%s: could not get flags for fd %d: %s",
-               __FUNCTION__, fd, strerror(errno) );
-    }
-
-    do {
-        ret = fcntl(fd, F_SETFD, flags | O_NONBLOCK);
-    } while (ret < 0 && errno == EINTR);
-
-    if (ret < 0) {
-        fatal( "%s: could not set fd %d to non-blocking: %s",
-               __FUNCTION__, fd, strerror(errno) );
-    }
-}
-
-/** FD EVENT LOOP
- **/
-
-#include <sys/epoll.h>
-
-#define  MAX_CHANNELS  16
-#define  MAX_EVENTS    (MAX_CHANNELS+1)  /* each channel + the serial fd */
-
-typedef void (*EventFunc)( void*  user, int  events );
-
-enum {
-    HOOK_PENDING = (1 << 0),
-    HOOK_CLOSING = (1 << 1),
-};
-
-typedef struct {
-    int        fd;
-    int        wanted;
-    int        events;
-    int        state;
-    void*      ev_user;
-    EventFunc  ev_func;
-} LoopHook;
-
-typedef struct {
-    int                  epoll_fd;
-    int                  num_fds;
-    int                  max_fds;
-    struct epoll_event*  events;
-    LoopHook*            hooks;
-} Looper;
-
-static void
-looper_init( Looper*  l )
-{
-    l->epoll_fd = epoll_create(4);
-    l->num_fds  = 0;
-    l->max_fds  = 0;
-    l->events   = NULL;
-    l->hooks    = NULL;
-}
-
-static void
-looper_done( Looper*  l )
-{
-    xfree(l->events);
-    xfree(l->hooks);
-    l->max_fds = 0;
-    l->num_fds = 0;
-
-    close(l->epoll_fd);
-    l->epoll_fd  = -1;
-}
-
-static LoopHook*
-looper_find( Looper*  l, int  fd )
-{
-    LoopHook*  hook = l->hooks;
-    LoopHook*  end  = hook + l->num_fds;
-
-    for ( ; hook < end; hook++ ) {
-        if (hook->fd == fd)
-            return hook;
-    }
-    return NULL;
-}
-
-static void
-looper_grow( Looper*  l )
-{
-    int  old_max = l->max_fds;
-    int  new_max = old_max + (old_max >> 1) + 4;
-    int  n;
-
-    xrenew( l->events, new_max );
-    xrenew( l->hooks,  new_max );
-    l->max_fds = new_max;
-
-    /* now change the handles to all events */
-    for (n = 0; n < l->num_fds; n++) {
-        struct epoll_event ev;
-        LoopHook*          hook = l->hooks + n;
-
-        ev.events   = hook->wanted;
-        ev.data.ptr = hook;
-        epoll_ctl( l->epoll_fd, EPOLL_CTL_MOD, hook->fd, &ev );
-    }
-}
-
-static void
-looper_add( Looper*  l, int  fd, EventFunc  func, void*  user )
-{
-    struct epoll_event  ev;
-    LoopHook*           hook;
-
-    if (l->num_fds >= l->max_fds)
-        looper_grow(l);
-
-    hook = l->hooks + l->num_fds;
-
-    hook->fd      = fd;
-    hook->ev_user = user;
-    hook->ev_func = func;
-    hook->state   = 0;
-    hook->wanted  = 0;
-    hook->events  = 0;
-
-    fd_setnonblock(fd);
-
-    ev.events   = 0;
-    ev.data.ptr = hook;
-    epoll_ctl( l->epoll_fd, EPOLL_CTL_ADD, fd, &ev );
-
-    l->num_fds += 1;
-}
-
-static void
-looper_del( Looper*  l, int  fd )
-{
-    LoopHook*  hook = looper_find( l, fd );
-
-    if (!hook) {
-        D( "%s: invalid fd: %d", __FUNCTION__, fd );
-        return;
-    }
-    /* don't remove the hook yet */
-    hook->state |= HOOK_CLOSING;
-
-    epoll_ctl( l->epoll_fd, EPOLL_CTL_DEL, fd, NULL );
-}
-
-static void
-looper_enable( Looper*  l, int  fd, int  events )
-{
-    LoopHook*  hook = looper_find( l, fd );
-
-    if (!hook) {
-        D("%s: invalid fd: %d", __FUNCTION__, fd );
-        return;
-    }
-
-    if (events & ~hook->wanted) {
-        struct epoll_event  ev;
-
-        hook->wanted |= events;
-        ev.events   = hook->wanted;
-        ev.data.ptr = hook;
-
-        epoll_ctl( l->epoll_fd, EPOLL_CTL_MOD, fd, &ev );
-    }
-}
-
-static void
-looper_disable( Looper*  l, int  fd, int  events )
-{
-    LoopHook*  hook = looper_find( l, fd );
-
-    if (!hook) {
-        D("%s: invalid fd: %d", __FUNCTION__, fd );
-        return;
-    }
-
-    if (events & hook->wanted) {
-        struct epoll_event  ev;
-
-        hook->wanted &= ~events;
-        ev.events   = hook->wanted;
-        ev.data.ptr = hook;
-
-        epoll_ctl( l->epoll_fd, EPOLL_CTL_MOD, fd, &ev );
-    }
-}
-
-static void
-looper_loop( Looper*  l )
-{
-    for (;;) {
-        int  n, count;
-
-        do {
-            count = epoll_wait( l->epoll_fd, l->events, l->num_fds, -1 );
-        } while (count < 0 && errno == EINTR);
-
-        if (count < 0) {
-            D("%s: error: %s", __FUNCTION__, strerror(errno) );
-            return;
-        }
-
-        /* mark all pending hooks */
-        for (n = 0; n < count; n++) {
-            LoopHook*  hook = l->events[n].data.ptr;
-            hook->state  = HOOK_PENDING;
-            hook->events = l->events[n].events;
-        }
-
-        /* execute hook callbacks. this may change the 'hooks'
-         * and 'events' array, as well as l->num_fds, so be careful */
-        for (n = 0; n < l->num_fds; n++) {
-            LoopHook*  hook = l->hooks + n;
-            if (hook->state & HOOK_PENDING) {
-                hook->state &= ~HOOK_PENDING;
-                hook->ev_func( hook->ev_user, hook->events );
-            }
-        }
-
-        /* now remove all the hooks that were closed by
-         * the callbacks */
-        for (n = 0; n < l->num_fds;) {
-            LoopHook*  hook = l->hooks + n;
-
-            if (!(hook->state & HOOK_CLOSING)) {
-                n++;
-                continue;
-            }
-
-            hook[0]     = l->hooks[l->num_fds-1];
-            l->num_fds -= 1;
-        }
-    }
-}
-
-/** PACKETS
- **/
-
-typedef struct Packet   Packet;
-
-/* we want to ensure that Packet is no more than a single page */
-#define  MAX_PAYLOAD  (4096-16-6)
-
-struct Packet {
-    Packet*   next;
-    int       len;
-    int       channel;
-    uint8_t   data[ MAX_PAYLOAD ];
-};
-
-static Packet*   _free_packets;
-
-static Packet*
-packet_alloc(void)
-{
-    Packet*  p = _free_packets;
-    if (p != NULL) {
-        _free_packets = p->next;
-    } else {
-        xnew(p);
-    }
-    p->next = NULL;
-    p->len  = 0;
-    p->channel = -1;
-    return p;
-}
-
-static void
-packet_free( Packet*  *ppacket )
-{
-    Packet*  p = *ppacket;
-    if (p) {
-        p->next       = _free_packets;
-        _free_packets = p;
-        *ppacket = NULL;
-    }
-}
-
-static Packet*
-packet_dup( Packet*  p )
-{
-    Packet*  p2 = packet_alloc();
-
-    p2->len     = p->len;
-    p2->channel = p->channel;
-    memcpy(p2->data, p->data, p->len);
-    return p2;
-}
-
-/** PACKET RECEIVER
- **/
-
-typedef void (*PostFunc) ( void*  user, Packet*  p );
-typedef void (*CloseFunc)( void*  user );
-
-typedef struct {
-    PostFunc   post;
-    CloseFunc  close;
-    void*      user;
-} Receiver;
-
-static __inline__ void
-receiver_post( Receiver*  r, Packet*  p )
-{
-    r->post( r->user, p );
-}
-
-static __inline__ void
-receiver_close( Receiver*  r )
-{
-    r->close( r->user );
-}
-
-
-/** FD HANDLERS
- **
- ** these are smart listeners that send incoming packets to a receiver
- ** and can queue one or more outgoing packets and send them when possible
- **/
-
-typedef struct FDHandler {
-    int          fd;
-    Looper*      looper;
-    Receiver     receiver[1];
-    int          out_pos;
-    Packet*      out_first;
-    Packet**     out_ptail;
-
-} FDHandler;
-
-
-static void
-fdhandler_done( FDHandler*  f )
-{
-    /* get rid of unsent packets */
-    if (f->out_first) {
-        Packet*  p;
-        while ((p = f->out_first) != NULL) {
-            f->out_first = p->next;
-            packet_free(&p);
-        }
-    }
-
-    /* get rid of file descriptor */
-    if (f->fd >= 0) {
-        looper_del( f->looper, f->fd );
-        close(f->fd);
-        f->fd = -1;
-    }
-    f->looper = NULL;
-}
-
-
-static void
-fdhandler_enqueue( FDHandler*  f, Packet*  p )
-{
-    Packet*  first = f->out_first;
-
-    p->next         = NULL;
-    f->out_ptail[0] = p;
-    f->out_ptail    = &p->next;
-
-    if (first == NULL) {
-        f->out_pos = 0;
-        looper_enable( f->looper, f->fd, EPOLLOUT );
-    }
-}
-
-
-static void
-fdhandler_event( FDHandler*  f, int  events )
-{
-   int  len;
-
-    if (events & EPOLLIN) {
-        Packet*  p = packet_alloc();
-        int      len;
-
-        if ((len = fd_read(f->fd, p->data, MAX_PAYLOAD)) < 0) {
-            D("%s: can't recv: %s", __FUNCTION__, strerror(errno));
-            packet_free(&p);
-        } else {
-            p->len     = len;
-            p->channel = -101;  /* special debug value */
-            receiver_post( f->receiver, p );
-        }
-    }
-
-    /* in certain cases, it's possible to have both EPOLLIN and
-     * EPOLLHUP at the same time. This indicates that there is incoming
-     * data to read, but that the connection was nonetheless closed
-     * by the sender. Be sure to read the data before closing
-     * the receiver to avoid packet loss.
-     */
-    if (events & (EPOLLHUP|EPOLLERR)) {
-        /* disconnection */
-        D("%s: disconnect on fd %d", __FUNCTION__, f->fd);
-        receiver_close( f->receiver );
-        return;
-    }
-
-    if (events & EPOLLOUT && f->out_first) {
-        Packet*  p = f->out_first;
-        int      avail, len;
-
-        avail = p->len - f->out_pos;
-        if ((len = fd_write(f->fd, p->data + f->out_pos, avail)) < 0) {
-            D("%s: can't send: %s", __FUNCTION__, strerror(errno));
-        } else {
-            f->out_pos += len;
-            if (f->out_pos >= p->len) {
-                f->out_pos   = 0;
-                f->out_first = p->next;
-                packet_free(&p);
-                if (f->out_first == NULL) {
-                    f->out_ptail = &f->out_first;
-                    looper_disable( f->looper, f->fd, EPOLLOUT );
-                }
-            }
-        }
-    }
-}
-
-
-static void
-fdhandler_init( FDHandler*      f,
-                int             fd,
-                Looper*         looper,
-                Receiver*       receiver )
-{
-    f->fd          = fd;
-    f->looper      = looper;
-    f->receiver[0] = receiver[0];
-    f->out_first   = NULL;
-    f->out_ptail   = &f->out_first;
-    f->out_pos     = 0;
-
-    looper_add( looper, fd, (EventFunc) fdhandler_event, f );
-    looper_enable( looper, fd, EPOLLIN );
-}
-
-
-static void
-fdhandler_accept_event( FDHandler*  f, int  events )
-{
-    if (events & EPOLLIN) {
-        /* this is an accept - send a dummy packet to the receiver */
-        Packet*  p = packet_alloc();
-
-        D("%s: accepting on fd %d", __FUNCTION__, f->fd);
-        p->data[0] = 1;
-        p->len     = 1;
-        receiver_post( f->receiver, p );
-    }
-
-    if (events & (EPOLLHUP|EPOLLERR)) {
-        /* disconnecting !! */
-        D("%s: closing fd %d", __FUNCTION__, f->fd);
-        receiver_close( f->receiver );
-        return;
-    }
-}
-
-
-static void
-fdhandler_init_accept( FDHandler*  f,
-                       int         fd,
-                       Looper*     looper,
-                       Receiver*   receiver )
-{
-    f->fd          = fd;
-    f->looper      = looper;
-    f->receiver[0] = receiver[0];
-
-    looper_add( looper, fd, (EventFunc) fdhandler_accept_event, f );
-    looper_enable( looper, fd, EPOLLIN );
-}
-
-/** CLIENTS
- **/
-
-typedef struct Client {
-    struct Client*   next;
-    struct Client**  pref;
-    int              channel;
-    FDHandler        fdhandler[1];
-    Receiver         receiver[1];
-} Client;
-
-static Client*   _free_clients;
-
-static void
-client_free( Client*  c )
-{
-    c->pref[0] = c->next;
-    c->next    = NULL;
-    c->pref    = &c->next;
-
-    fdhandler_done( c->fdhandler );
-    free(c);
-}
-
-static void
-client_receive( Client*  c, Packet*  p )
-{
-    p->channel = c->channel;
-    receiver_post( c->receiver, p );
-}
-
-static void
-client_send( Client*  c, Packet*  p )
-{
-    fdhandler_enqueue( c->fdhandler, p );
-}
-
-static void
-client_close( Client*  c )
-{
-    D("disconnecting client on fd %d", c->fdhandler->fd);
-    client_free(c);
-}
-
-static Client*
-client_new( int         fd,
-            int         channel,
-            Looper*     looper,
-            Receiver*   receiver )
-{
-    Client*   c;
-    Receiver  recv;
-
-    xnew(c);
-
-    c->next = NULL;
-    c->pref = &c->next;
-    c->channel = channel;
-    c->receiver[0] = receiver[0];
-
-    recv.user  = c;
-    recv.post  = (PostFunc)  client_receive;
-    recv.close = (CloseFunc) client_close;
-
-    fdhandler_init( c->fdhandler, fd, looper, &recv );
-    return c;
-}
-
-static void
-client_link( Client*  c, Client**  plist )
-{
-    c->next  = plist[0];
-    c->pref  = plist;
-    plist[0] = c;
-}
-
-
-/** CHANNELS
- **/
-
-typedef enum {
-    CHANNEL_BROADCAST = 0,
-    CHANNEL_DUPLEX,
-
-    CHANNEL_MAX  /* do not remove */
-
-} ChannelType;
-
-#define  CHANNEL_CONTROL   0
-
-typedef struct Channel {
-    struct Channel*     next;
-    struct Channel**    pref;
-    FDHandler           fdhandler[1];
-    ChannelType         ctype;
-    const char*         name;
-    int                 index;
-    Receiver            receiver[1];
-    Client*             clients;
-} Channel;
-
-static void
-channel_free( Channel*  c )
-{
-    while (c->clients)
-        client_free(c->clients);
-
-    c->pref[0] = c->next;
-    c->pref    = &c->next;
-    c->next    = NULL;
-
-    fdhandler_done( c->fdhandler );
-    free(c);
-}
-
-static void
-channel_close( Channel*  c )
-{
-    D("closing channel '%s' on fd %d", c->name, c->fdhandler->fd);
-    channel_free(c);
-}
-
-
-static void
-channel_accept( Channel*  c, Packet*  p )
-{
-    int   fd;
-    struct sockaddr  from;
-    socklen_t        fromlen = sizeof(from);
-
-    /* get rid of dummy packet (see fdhandler_event_accept) */
-    packet_free(&p);
-
-    do {
-        fd = accept( c->fdhandler->fd, &from, &fromlen );
-    } while (fd < 0 && errno == EINTR);
-
-    if (fd >= 0) {
-        Client*  client;
-
-        /* DUPLEX channels can only have one client at a time */
-        if (c->ctype == CHANNEL_DUPLEX && c->clients != NULL) {
-            D("refusing client connection on duplex channel '%s'", c->name);
-            close(fd);
-            return;
-        }
-        client = client_new( fd, c->index, c->fdhandler->looper, c->receiver );
-        client_link( client, &c->clients );
-        D("new client for channel '%s' on fd %d", c->name, fd);
-    }
-    else
-        D("could not accept connection: %s", strerror(errno));
-}
-
-
-static Channel*
-channel_new( int          fd,
-             ChannelType  ctype,
-             const char*  name,
-             int          index,
-             Looper*      looper,
-             Receiver*    receiver )
-{
-    Channel*  c;
-    Receiver  recv;
-
-    xnew(c);
-
-    c->next  = NULL;
-    c->pref  = &c->next;
-    c->ctype = ctype;
-    c->name  = name;
-    c->index = index;
-
-    /* saved for future clients */
-    c->receiver[0] = receiver[0];
-
-    recv.user  = c;
-    recv.post  = (PostFunc)  channel_accept;
-    recv.close = (CloseFunc) channel_close;
-
-    fdhandler_init_accept( c->fdhandler, fd, looper, &recv );
-    listen( fd, 5 );
-
-    return c;
-}
-
-static void
-channel_link( Channel*  c, Channel** plist )
-{
-    c->next  = plist[0];
-    c->pref  = plist;
-    plist[0] = c;
-}
-
-static void
-channel_send( Channel*  c, Packet*  p )
-{
-    Client*  client = c->clients;
-    for ( ; client; client = client->next ) {
-        Packet*  q = packet_dup(p);
-        client_send( client, q );
-    }
-    packet_free( &p );
-}
-
-
-/* each packet is made of a 6 byte header followed by a payload
- * the header looks like:
- *
- *   offset   size    description
- *       0       4    a 4-char hex string for the size of the payload
- *       4       2    a 2-byte hex string for the channel number
- *       6       n    the payload itself
- */
-#define  HEADER_SIZE    6
-#define  LENGTH_OFFSET  0
-#define  LENGTH_SIZE    4
-#define  CHANNEL_OFFSET 4
-#define  CHANNEL_SIZE   2
-
-#define  CHANNEL_INDEX_NONE     0
-#define  CHANNEL_INDEX_CONTROL  1
-
-#define  TOSTRING(x)   _TOSTRING(x)
-#define  _TOSTRING(x)  #x
-
-/** SERIAL HANDLER
- **/
-
-typedef struct Serial {
-    FDHandler   fdhandler[1];
-    Receiver    receiver[1];
-    int         in_len;
-    int         in_datalen;
-    int         in_channel;
-    Packet*     in_packet;
-} Serial;
-
-static void
-serial_done( Serial*  s )
-{
-    packet_free(&s->in_packet);
-    s->in_len     = 0;
-    s->in_datalen = 0;
-    s->in_channel = 0;
-    fdhandler_done(s->fdhandler);
-}
-
-static void
-serial_close( Serial*  s )
-{
-    fatal("unexpected serial port close !!");
-}
-
-/* receive packets from the serial port */
-static void
-serial_receive( Serial*  s, Packet*  p )
-{
-    int      rpos  = 0, rcount = p->len;
-    Packet*  inp   = s->in_packet;
-    int      inpos = s->in_len;
-
-    //D("received from serial: %d bytes: '%.*s'", p->len, p->len, p->data);
-
-    while (rpos < rcount)
-    {
-        int  avail = rcount - rpos;
-
-        /* first, try to read the header */
-        if (s->in_datalen == 0) {
-            int  wanted = HEADER_SIZE - inpos;
-            if (avail > wanted)
-                avail = wanted;
-
-            memcpy( inp->data + inpos, p->data + rpos, avail );
-            inpos += avail;
-            rpos  += avail;
-
-            if (inpos == HEADER_SIZE) {
-                s->in_datalen = hex2int( inp->data + LENGTH_OFFSET,  LENGTH_SIZE );
-                s->in_channel = hex2int( inp->data + CHANNEL_OFFSET, CHANNEL_SIZE );
-
-                if (s->in_datalen <= 0)
-                    D("ignoring empty packet from serial port");
-
-                //D("received %d bytes packet for channel %d", s->in_datalen, s->in_channel);
-                inpos = 0;
-            }
-        }
-        else /* then, populate the packet itself */
-        {
-            int   wanted = s->in_datalen - inpos;
-
-            if (avail > wanted)
-                avail = wanted;
-
-            memcpy( inp->data + inpos, p->data + rpos, avail );
-            inpos += avail;
-            rpos  += avail;
-
-            if (inpos == s->in_datalen) {
-                if (s->in_channel < 0) {
-                    D("ignoring %d bytes addressed to channel %d",
-                       inpos, s->in_channel);
-                } else {
-                    inp->len     = inpos;
-                    inp->channel = s->in_channel;
-                    receiver_post( s->receiver, inp );
-                    s->in_packet  = inp = packet_alloc();
-                }
-                s->in_datalen = 0;
-                inpos         = 0;
-            }
-        }
-    }
-    s->in_len = inpos;
-    packet_free(&p);
-}
-
-
-/* send a packet to the serial port */
-static void
-serial_send( Serial*  s, Packet*  p )
-{
-    Packet*  h = packet_alloc();
-
-    //D("sending to serial %d bytes from channel %d: '%.*s'", p->len, p->channel, p->len, p->data);
-
-    /* insert a small header before this packet */
-    h->len = HEADER_SIZE;
-    int2hex( p->len,     h->data + LENGTH_OFFSET,  LENGTH_SIZE );
-    int2hex( p->channel, h->data + CHANNEL_OFFSET, CHANNEL_SIZE );
-
-    fdhandler_enqueue( s->fdhandler, h );
-    fdhandler_enqueue( s->fdhandler, p );
-}
-
-
-static void
-serial_init( Serial*    s,
-             int        fd,
-             Looper*    looper,
-             Receiver*  receiver )
-{
-    Receiver  recv;
-
-    recv.user  = s;
-    recv.post  = (PostFunc)  serial_receive;
-    recv.close = (CloseFunc) serial_close;
-
-    s->receiver[0] = receiver[0];
-
-    fdhandler_init( s->fdhandler, fd, looper, &recv );
-    s->in_len     = 0;
-    s->in_datalen = 0;
-    s->in_channel = 0;
-    s->in_packet  = packet_alloc();
-}
-
-/**  GLOBAL MULTIPLEXER
- **/
-
-typedef struct {
-    Looper     looper[1];
-    Serial     serial[1];
-    Channel*   channels;
-    uint16_t   channel_last;
-} Multiplexer;
-
-/* receive a packet from the serial port, send it to the relevant client/channel */
-static void  multiplexer_receive_serial( Multiplexer*  m, Packet*  p );
-
-static void
-multiplexer_init( Multiplexer*  m, const char*  serial_dev )
-{
-    int       fd;
-    Receiver  recv;
-
-    looper_init( m->looper );
-
-    fd = open(serial_dev, O_RDWR);
-    if (fd < 0) {
-        fatal( "%s: could not open '%s': %s", __FUNCTION__, serial_dev,
-               strerror(errno) );
-    }
-    // disable echo on serial lines
-    if ( !memcmp( serial_dev, "/dev/ttyS", 9 ) ) {
-        struct termios  ios;
-        tcgetattr( fd, &ios );
-        ios.c_lflag = 0;  /* disable ECHO, ICANON, etc... */
-        tcsetattr( fd, TCSANOW, &ios );
-    }
-
-    recv.user  = m;
-    recv.post  = (PostFunc) multiplexer_receive_serial;
-    recv.close = NULL;
-
-    serial_init( m->serial, fd, m->looper, &recv );
-
-    m->channels     = NULL;
-    m->channel_last = CHANNEL_CONTROL+1;
-}
-
-static void
-multiplexer_add_channel( Multiplexer*  m, int  fd, const char*  name, ChannelType  ctype )
-{
-    Channel*  c;
-    Receiver  recv;
-
-    /* send channel client data directly to the serial port */
-    recv.user  = m->serial;
-    recv.post  = (PostFunc) serial_send;
-    recv.close = (CloseFunc) client_close;
-
-    /* connect each channel directly to the serial port */
-    c = channel_new( fd, ctype, name, m->channel_last, m->looper, &recv );
-    channel_link( c, &m->channels );
-
-    m->channel_last += 1;
-    if (m->channel_last <= CHANNEL_CONTROL)
-        m->channel_last += 1;
-}
-
-
-static void
-multiplexer_done( Multiplexer*  m )
-{
-    while (m->channels)
-        channel_close(m->channels);
-
-    serial_done( m->serial );
-    looper_done( m->looper );
-}
-
-
-static void
-multiplexer_send_answer( Multiplexer*  m, Packet*  p, const char*  answer )
-{
-    p->len = strlen( answer );
-    if (p->len >= MAX_PAYLOAD)
-        p->len = MAX_PAYLOAD-1;
-
-    memcpy( (char*)p->data, answer, p->len );
-    p->channel = CHANNEL_CONTROL;
-
-    serial_send( m->serial, p );
-}
-
-
-static void
-multiplexer_handle_connect( Multiplexer*  m, Packet*  p, char*  name )
-{
-    int       n;
-    Channel*  c;
-
-    if (p->len >= MAX_PAYLOAD) {
-        multiplexer_send_answer( m, p, "ko:connect:bad name" );
-        return;
-    }
-    p->data[p->len] = 0;
-
-    for (c = m->channels; c != NULL; c = c->next)
-        if ( !strcmp(c->name, name) )
-            break;
-
-    if (c == NULL) {
-        D("can't connect to unknown channel '%s'", name);
-        multiplexer_send_answer( m, p, "ko:connect:bad name" );
-        return;
-    }
-
-    p->channel = CHANNEL_CONTROL;
-    p->len     = snprintf( (char*)p->data, MAX_PAYLOAD,
-                       "ok:connect:%s:%02x", c->name, c->index );
-
-    serial_send( m->serial, p );
-}
-
-
-static void
-multiplexer_receive_serial( Multiplexer*  m, Packet*  p )
-{
-    Channel*  c = m->channels;
-
-    /* check the destination channel index */
-    if (p->channel != CHANNEL_CONTROL) {
-        Channel*  c;
-
-        for (c = m->channels; c; c = c->next ) {
-            if (c->index == p->channel) {
-                channel_send( c, p );
-                break;
-            }
-        }
-        if (c == NULL) {
-            D("ignoring %d bytes packet for unknown channel index %d",
-                p->len, p->channel );
-            packet_free(&p);
-        }
-    }
-    else  /* packet addressed to the control channel */
-    {
-        D("received control message:  '%.*s'", p->len, p->data);
-        if (p->len > 8 && strncmp( (char*)p->data, "connect:", 8) == 0) {
-            multiplexer_handle_connect( m, p, (char*)p->data + 8 );
-        } else {
-            /* unknown command */
-            multiplexer_send_answer( m, p, "ko:unknown command" );
-        }
-        return;
-    }
-}
-
-
-/** MAIN LOOP
- **/
-
-static Multiplexer  _multiplexer[1];
-
-#define  QEMUD_PREFIX  "qemud_"
-
-static const struct { const char* name; ChannelType  ctype; }   default_channels[] = {
-    { "gsm", CHANNEL_DUPLEX },       /* GSM AT command channel, used by commands/rild/rild.c */
-    { "gps", CHANNEL_BROADCAST },    /* GPS NMEA commands, used by libs/hardware_legacy/qemu_gps.c  */
-    { "control", CHANNEL_DUPLEX },   /* Used for power/leds/vibrator/etc... */
-    { NULL, 0 }
-};
-
-int  main( void )
-{
-    Multiplexer*  m = _multiplexer;
-
-   /* extract the name of our serial device from the kernel
-    * boot options that are stored in /proc/cmdline
-    */
-#define  KERNEL_OPTION  "android.qemud="
-
-    {
-        char          buff[1024];
-        int           fd, len;
-        char*         p;
-        char*         q;
-
-        fd = open( "/proc/cmdline", O_RDONLY );
-        if (fd < 0) {
-            D("%s: can't open /proc/cmdline !!: %s", __FUNCTION__,
-            strerror(errno));
-            exit(1);
-        }
-
-        len = fd_read( fd, buff, sizeof(buff)-1 );
-        close(fd);
-        if (len < 0) {
-            D("%s: can't read /proc/cmdline: %s", __FUNCTION__,
-            strerror(errno));
-            exit(1);
-        }
-        buff[len] = 0;
-
-        p = strstr( buff, KERNEL_OPTION );
-        if (p == NULL) {
-            D("%s: can't find '%s' in /proc/cmdline",
-            __FUNCTION__, KERNEL_OPTION );
-            exit(1);
-        }
-
-        p += sizeof(KERNEL_OPTION)-1;  /* skip option */
-        q  = p;
-        while ( *q && *q != ' ' && *q != '\t' )
-            q += 1;
-
-        snprintf( buff, sizeof(buff), "/dev/%.*s", q-p, p );
-
-        multiplexer_init( m, buff );
-    }
-
-    D("multiplexer inited, creating default channels");
-
-    /* now setup all default channels */
-    {
-        int  nn;
-
-        for (nn = 0; default_channels[nn].name != NULL; nn++) {
-            char         control_name[32];
-            int          fd;
-            Channel*     chan;
-            const char*  name  = default_channels[nn].name;
-            ChannelType  ctype = default_channels[nn].ctype;
-
-            snprintf(control_name, sizeof(control_name), "%s%s",
-                     QEMUD_PREFIX, name);
-
-            if ((fd = android_get_control_socket(control_name)) < 0) {
-                D("couldn't get fd for control socket '%s'", name);
-                continue;
-            }
-            D( "got control socket '%s' on fd %d", control_name, fd);
-            multiplexer_add_channel( m, fd, name, ctype );
-        }
-    }
-
-    D( "entering main loop");
-    looper_loop( m->looper );
-    D( "unexpected termination !!" );
-    return 0;
-}
diff --git a/emulator/qtools/Android.mk b/emulator/qtools/Android.mk
deleted file mode 100644
index afbb3e8..0000000
--- a/emulator/qtools/Android.mk
+++ /dev/null
@@ -1,141 +0,0 @@
-# 
-# Copyright 2006 The Android Open Source Project
-#
-# Java method trace dump tool
-#
-
-LOCAL_PATH:= $(call my-dir)
-
-common_includes := external/qemu
-common_cflags := -O0 -g
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := post_trace.cpp trace_reader.cpp decoder.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := post_trace
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := read_trace.cpp trace_reader.cpp decoder.cpp armdis.cpp \
-	thumbdis.cpp opcode.cpp read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := read_trace
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := check_trace.cpp trace_reader.cpp decoder.cpp \
-	opcode.cpp read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := check_trace
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := bb_dump.cpp trace_reader.cpp decoder.cpp \
-	read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := bb_dump
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := bb2sym.cpp trace_reader.cpp decoder.cpp \
-	read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := bb2sym
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := profile_trace.cpp trace_reader.cpp decoder.cpp \
-	opcode.cpp read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := profile_trace
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := bbprof.cpp trace_reader.cpp decoder.cpp armdis.cpp \
-	thumbdis.cpp opcode.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := bbprof
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := q2g.cpp trace_reader.cpp decoder.cpp \
-	opcode.cpp read_elf.cpp parse_options.cpp gtrace.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := q2g
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := q2dm.cpp trace_reader.cpp decoder.cpp armdis.cpp \
-	thumbdis.cpp opcode.cpp read_elf.cpp parse_options.cpp dmtrace.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := q2dm
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := coverage.cpp trace_reader.cpp decoder.cpp armdis.cpp \
-	thumbdis.cpp opcode.cpp read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := coverage
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := stack_dump.cpp trace_reader.cpp decoder.cpp armdis.cpp \
-	thumbdis.cpp opcode.cpp read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := stack_dump
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := hist_trace.cpp trace_reader.cpp decoder.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := hist_trace
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := read_addr.cpp trace_reader.cpp decoder.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := read_addr
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := read_pid.cpp trace_reader.cpp decoder.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := read_pid
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := exc_dump.cpp trace_reader.cpp decoder.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := exc_dump
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := read_method.cpp trace_reader.cpp decoder.cpp \
-	read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := read_method
-include $(BUILD_HOST_EXECUTABLE)
-
-include $(CLEAR_VARS)
-LOCAL_SRC_FILES := profile_pid.cpp trace_reader.cpp decoder.cpp \
-	read_elf.cpp parse_options.cpp
-LOCAL_C_INCLUDES += $(common_includes)
-LOCAL_CFLAGS += $(common_cflags)
-LOCAL_MODULE := profile_pid
-include $(BUILD_HOST_EXECUTABLE)
diff --git a/emulator/qtools/armdis.cpp b/emulator/qtools/armdis.cpp
deleted file mode 100644
index 593f460..0000000
--- a/emulator/qtools/armdis.cpp
+++ /dev/null
@@ -1,905 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <string.h>
-#include "armdis.h"
-#include "opcode.h"
-
-static char *cond_names[] = {
-    "eq",
-    "ne",
-    "cs",
-    "cc",
-    "mi",
-    "pl",
-    "vs",
-    "vc",
-    "hi",
-    "ls",
-    "ge",
-    "lt",
-    "gt",
-    "le",
-    "",
-    "RESERVED"
-};
-
-// Indexed by the shift type (bits 6-5)
-static const char *shift_names[] = {
-    "LSL",
-    "LSR",
-    "ASR",
-    "ROR"
-};
-
-static char* cond_to_str(int cond) {
-    return cond_names[cond];
-}
-
-char *Arm::disasm(uint32_t addr, uint32_t insn, char *result)
-{
-    static char   buf[80];
-    char          *ptr;
-
-    ptr = result ? result : buf;
-    Opcode opcode = decode(insn);
-    switch (opcode) {
-        case OP_INVALID:
-            sprintf(ptr, "Invalid");
-            return ptr;
-        case OP_UNDEFINED:
-            sprintf(ptr, "Undefined");
-            return ptr;
-        case OP_ADC:
-        case OP_ADD:
-        case OP_AND:
-        case OP_BIC:
-        case OP_CMN:
-        case OP_CMP:
-        case OP_EOR:
-        case OP_MOV:
-        case OP_MVN:
-        case OP_ORR:
-        case OP_RSB:
-        case OP_RSC:
-        case OP_SBC:
-        case OP_SUB:
-        case OP_TEQ:
-        case OP_TST:
-            return disasm_alu(opcode, insn, ptr);
-        case OP_B:
-        case OP_BL:
-            return disasm_branch(addr, opcode, insn, ptr);
-        case OP_BKPT:
-            return disasm_bkpt(insn, ptr);
-        case OP_BLX:
-            // not supported yet
-            break;
-        case OP_BX:
-            return disasm_bx(insn, ptr);
-        case OP_CDP:
-            sprintf(ptr, "cdp");
-            return ptr;
-        case OP_CLZ:
-            return disasm_clz(insn, ptr);
-        case OP_LDC:
-            sprintf(ptr, "ldc");
-            return ptr;
-        case OP_LDM:
-        case OP_STM:
-            return disasm_memblock(opcode, insn, ptr);
-        case OP_LDR:
-        case OP_LDRB:
-        case OP_LDRBT:
-        case OP_LDRT:
-        case OP_STR:
-        case OP_STRB:
-        case OP_STRBT:
-        case OP_STRT:
-            return disasm_mem(insn, ptr);
-        case OP_LDRH:
-        case OP_LDRSB:
-        case OP_LDRSH:
-        case OP_STRH:
-            return disasm_memhalf(insn, ptr);
-        case OP_MCR:
-        case OP_MRC:
-            return disasm_mcr(opcode, insn, ptr);
-        case OP_MLA:
-            return disasm_mla(opcode, insn, ptr);
-        case OP_MRS:
-            return disasm_mrs(insn, ptr);
-        case OP_MSR:
-            return disasm_msr(insn, ptr);
-        case OP_MUL:
-            return disasm_mul(opcode, insn, ptr);
-        case OP_PLD:
-            return disasm_pld(insn, ptr);
-        case OP_STC:
-            sprintf(ptr, "stc");
-            return ptr;
-        case OP_SWI:
-            return disasm_swi(insn, ptr);
-        case OP_SWP:
-        case OP_SWPB:
-            return disasm_swp(opcode, insn, ptr);
-        case OP_UMLAL:
-        case OP_UMULL:
-        case OP_SMLAL:
-        case OP_SMULL:
-            return disasm_umlal(opcode, insn, ptr);
-        default:
-            sprintf(ptr, "Error");
-            return ptr;
-    }
-    return NULL;
-}
-
-char *Arm::disasm_alu(Opcode opcode, uint32_t insn, char *ptr)
-{
-    static const uint8_t kNoOperand1 = 1;
-    static const uint8_t kNoDest = 2;
-    static const uint8_t kNoSbit = 4;
-
-    char rn_str[20];
-    char rd_str[20];
-    uint8_t flags = 0;
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t is_immed = (insn >> 25) & 0x1;
-    uint8_t bit_s = (insn >> 20) & 1;
-    uint8_t rn = (insn >> 16) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint8_t immed = insn & 0xff;
-
-    const char *opname = opcode_names[opcode];
-    switch (opcode) {
-        case OP_CMN:
-        case OP_CMP:
-        case OP_TEQ:
-        case OP_TST:
-            flags = kNoDest | kNoSbit;
-            break;
-        case OP_MOV:
-        case OP_MVN:
-            flags = kNoOperand1;
-            break;
-        default:
-            break;
-    }
-
-    // The "mov" instruction ignores the first operand (rn).
-    rn_str[0] = 0;
-    if ((flags & kNoOperand1) == 0) {
-        sprintf(rn_str, "r%d, ", rn);
-    }
-
-    // The following instructions do not write the result register (rd):
-    // tst, teq, cmp, cmn.
-    rd_str[0] = 0;
-    if ((flags & kNoDest) == 0) {
-        sprintf(rd_str, "r%d, ", rd);
-    }
-
-    char *sbit_str = "";
-    if (bit_s && !(flags & kNoSbit))
-        sbit_str = "s";
-
-    if (is_immed) {
-        sprintf(ptr, "%s%s%s\t%s%s#%u  ; 0x%x",
-                opname, cond_to_str(cond), sbit_str, rd_str, rn_str, immed, immed);
-        return ptr;
-    }
-
-    uint8_t shift_is_reg = (insn >> 4) & 1;
-    uint8_t rotate = (insn >> 8) & 0xf;
-    uint8_t rm = insn & 0xf;
-    uint8_t shift_type = (insn >> 5) & 0x3;
-    uint8_t rs = (insn >> 8) & 0xf;
-    uint8_t shift_amount = (insn >> 7) & 0x1f;
-    uint32_t rotated_val = immed;
-    uint8_t rotate2 = rotate << 1;
-    rotated_val = (rotated_val >> rotate2) | (rotated_val << (32 - rotate2));
-
-    if (!shift_is_reg && shift_type == 0 && shift_amount == 0) {
-        sprintf(ptr, "%s%s%s\t%s%sr%d",
-                opname, cond_to_str(cond), sbit_str, rd_str, rn_str, rm);
-        return ptr;
-    }
-
-    const char *shift_name = shift_names[shift_type];
-    if (shift_is_reg) {
-        sprintf(ptr, "%s%s%s\t%s%sr%d, %s r%d",
-                opname, cond_to_str(cond), sbit_str, rd_str, rn_str, rm,
-                shift_name, rs);
-        return ptr;
-    }
-    if (shift_amount == 0) {
-        if (shift_type == 3) {
-            sprintf(ptr, "%s%s%s\t%s%sr%d, RRX",
-                    opname, cond_to_str(cond), sbit_str, rd_str, rn_str, rm);
-            return ptr;
-        }
-        shift_amount = 32;
-    }
-    sprintf(ptr, "%s%s%s\t%s%sr%d, %s #%u",
-            opname, cond_to_str(cond), sbit_str, rd_str, rn_str, rm,
-            shift_name, shift_amount);
-    return ptr;
-}
-
-char *Arm::disasm_branch(uint32_t addr, Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint32_t offset = insn & 0xffffff;
-    // Sign-extend the 24-bit offset
-    if ((offset >> 23) & 1)
-        offset |= 0xff000000;
-
-    // Pre-compute the left-shift and the prefetch offset
-    offset <<= 2;
-    offset += 8;
-    addr += offset;
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s\t0x%x", opname, cond_to_str(cond), addr);
-    return ptr;
-}
-
-char *Arm::disasm_bx(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rn = insn & 0xf;
-    sprintf(ptr, "bx%s\tr%d", cond_to_str(cond), rn);
-    return ptr;
-}
-
-char *Arm::disasm_bkpt(uint32_t insn, char *ptr)
-{
-    uint32_t immed = (((insn >> 8) & 0xfff) << 4) | (insn & 0xf);
-    sprintf(ptr, "bkpt\t#%d", immed);
-    return ptr;
-}
-
-char *Arm::disasm_clz(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint8_t rm = insn & 0xf;
-    sprintf(ptr, "clz%s\tr%d, r%d", cond_to_str(cond), rd, rm);
-    return ptr;
-}
-
-char *Arm::disasm_memblock(Opcode opcode, uint32_t insn, char *ptr)
-{
-    char tmp_reg[10], tmp_list[80];
-
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t write_back = (insn >> 21) & 0x1;
-    uint8_t bit_s = (insn >> 22) & 0x1;
-    uint8_t is_up = (insn >> 23) & 0x1;
-    uint8_t is_pre = (insn >> 24) & 0x1;
-    uint8_t rn = (insn >> 16) & 0xf;
-    uint16_t reg_list = insn & 0xffff;
-
-    const char *opname = opcode_names[opcode];
-
-    char *bang = "";
-    if (write_back)
-        bang = "!";
-
-    char *carret = "";
-    if (bit_s)
-        carret = "^";
-
-    char *comma = "";
-    tmp_list[0] = 0;
-    for (int ii = 0; ii < 16; ++ii) {
-        if (reg_list & (1 << ii)) {
-            sprintf(tmp_reg, "%sr%d", comma, ii);
-            strcat(tmp_list, tmp_reg);
-            comma = ",";
-        }
-    }
-
-    char *addr_mode = "";
-    if (is_pre) {
-        if (is_up) {
-            addr_mode = "ib";
-        } else {
-            addr_mode = "db";
-        }
-    } else {
-        if (is_up) {
-            addr_mode = "ia";
-        } else {
-            addr_mode = "da";
-        }
-    }
-
-    sprintf(ptr, "%s%s%s\tr%d%s, {%s}%s",
-            opname, cond_to_str(cond), addr_mode, rn, bang, tmp_list, carret);
-    return ptr;
-}
-
-char *Arm::disasm_mem(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t is_reg = (insn >> 25) & 0x1;
-    uint8_t is_load = (insn >> 20) & 0x1;
-    uint8_t write_back = (insn >> 21) & 0x1;
-    uint8_t is_byte = (insn >> 22) & 0x1;
-    uint8_t is_up = (insn >> 23) & 0x1;
-    uint8_t is_pre = (insn >> 24) & 0x1;
-    uint8_t rn = (insn >> 16) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint16_t offset = insn & 0xfff;
-
-    char *opname = "ldr";
-    if (!is_load)
-        opname = "str";
-
-    char *bang = "";
-    if (write_back)
-        bang = "!";
-
-    char *minus = "";
-    if (is_up == 0)
-        minus = "-";
-
-    char *byte = "";
-    if (is_byte)
-        byte = "b";
-
-    if (is_reg == 0) {
-        if (is_pre) {
-            if (offset == 0) {
-                sprintf(ptr, "%s%s%s\tr%d, [r%d]",
-                        opname, cond_to_str(cond), byte, rd, rn);
-            } else {
-                sprintf(ptr, "%s%s%s\tr%d, [r%d, #%s%u]%s",
-                        opname, cond_to_str(cond), byte, rd, rn, minus, offset, bang);
-            }
-        } else {
-            char *transfer = "";
-            if (write_back)
-                transfer = "t";
-            sprintf(ptr, "%s%s%s%s\tr%d, [r%d], #%s%u",
-                    opname, cond_to_str(cond), byte, transfer, rd, rn, minus, offset);
-        }
-        return ptr;
-    }
-
-    uint8_t rm = insn & 0xf;
-    uint8_t shift_type = (insn >> 5) & 0x3;
-    uint8_t shift_amount = (insn >> 7) & 0x1f;
-
-    const char *shift_name = shift_names[shift_type];
-
-    if (is_pre) {
-        if (shift_amount == 0) {
-            if (shift_type == 0) {
-                sprintf(ptr, "%s%s%s\tr%d, [r%d, %sr%d]%s",
-                        opname, cond_to_str(cond), byte, rd, rn, minus, rm, bang);
-                return ptr;
-            }
-            if (shift_type == 3) {
-                sprintf(ptr, "%s%s%s\tr%d, [r%d, %sr%d, RRX]%s",
-                        opname, cond_to_str(cond), byte, rd, rn, minus, rm, bang);
-                return ptr;
-            }
-            shift_amount = 32;
-        }
-        sprintf(ptr, "%s%s%s\tr%d, [r%d, %sr%d, %s #%u]%s",
-                opname, cond_to_str(cond), byte, rd, rn, minus, rm,
-                shift_name, shift_amount, bang);
-        return ptr;
-    }
-
-    char *transfer = "";
-    if (write_back)
-        transfer = "t";
-
-    if (shift_amount == 0) {
-        if (shift_type == 0) {
-            sprintf(ptr, "%s%s%s%s\tr%d, [r%d], %sr%d",
-                    opname, cond_to_str(cond), byte, transfer, rd, rn, minus, rm);
-            return ptr;
-        }
-        if (shift_type == 3) {
-            sprintf(ptr, "%s%s%s%s\tr%d, [r%d], %sr%d, RRX",
-                    opname, cond_to_str(cond), byte, transfer, rd, rn, minus, rm);
-            return ptr;
-        }
-        shift_amount = 32;
-    }
-
-    sprintf(ptr, "%s%s%s%s\tr%d, [r%d], %sr%d, %s #%u",
-            opname, cond_to_str(cond), byte, transfer, rd, rn, minus, rm,
-            shift_name, shift_amount);
-    return ptr;
-}
-
-char *Arm::disasm_memhalf(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t is_load = (insn >> 20) & 0x1;
-    uint8_t write_back = (insn >> 21) & 0x1;
-    uint8_t is_immed = (insn >> 22) & 0x1;
-    uint8_t is_up = (insn >> 23) & 0x1;
-    uint8_t is_pre = (insn >> 24) & 0x1;
-    uint8_t rn = (insn >> 16) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint8_t bits_65 = (insn >> 5) & 0x3;
-    uint8_t rm = insn & 0xf;
-    uint8_t offset = (((insn >> 8) & 0xf) << 4) | (insn & 0xf);
-
-    char *opname = "ldr";
-    if (is_load == 0)
-        opname = "str";
-
-    char *width = "";
-    if (bits_65 == 1)
-        width = "h";
-    else if (bits_65 == 2)
-        width = "sb";
-    else
-        width = "sh";
-
-    char *bang = "";
-    if (write_back)
-        bang = "!";
-    char *minus = "";
-    if (is_up == 0)
-        minus = "-";
-
-    if (is_immed) {
-        if (is_pre) {
-            if (offset == 0) {
-                sprintf(ptr, "%s%sh\tr%d, [r%d]", opname, cond_to_str(cond), rd, rn);
-            } else {
-                sprintf(ptr, "%s%sh\tr%d, [r%d, #%s%u]%s",
-                        opname, cond_to_str(cond), rd, rn, minus, offset, bang);
-            }
-        } else {
-            sprintf(ptr, "%s%sh\tr%d, [r%d], #%s%u",
-                    opname, cond_to_str(cond), rd, rn, minus, offset);
-        }
-        return ptr;
-    }
-
-    if (is_pre) {
-        sprintf(ptr, "%s%sh\tr%d, [r%d, %sr%d]%s",
-                opname, cond_to_str(cond), rd, rn, minus, rm, bang);
-    } else {
-        sprintf(ptr, "%s%sh\tr%d, [r%d], %sr%d",
-                opname, cond_to_str(cond), rd, rn, minus, rm);
-    }
-    return ptr;
-}
-
-char *Arm::disasm_mcr(Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t crn = (insn >> 16) & 0xf;
-    uint8_t crd = (insn >> 12) & 0xf;
-    uint8_t cpnum = (insn >> 8) & 0xf;
-    uint8_t opcode2 = (insn >> 5) & 0x7;
-    uint8_t crm = insn & 0xf;
-
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s\t%d, 0, r%d, cr%d, cr%d, {%d}",
-            opname, cond_to_str(cond), cpnum, crd, crn, crm, opcode2);
-    return ptr;
-}
-
-char *Arm::disasm_mla(Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rd = (insn >> 16) & 0xf;
-    uint8_t rn = (insn >> 12) & 0xf;
-    uint8_t rs = (insn >> 8) & 0xf;
-    uint8_t rm = insn & 0xf;
-    uint8_t bit_s = (insn >> 20) & 1;
-
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s%s\tr%d, r%d, r%d, r%d",
-            opname, cond_to_str(cond), bit_s ? "s" : "", rd, rm, rs, rn);
-    return ptr;
-}
-
-char *Arm::disasm_umlal(Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rdhi = (insn >> 16) & 0xf;
-    uint8_t rdlo = (insn >> 12) & 0xf;
-    uint8_t rs = (insn >> 8) & 0xf;
-    uint8_t rm = insn & 0xf;
-    uint8_t bit_s = (insn >> 20) & 1;
-
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s%s\tr%d, r%d, r%d, r%d",
-            opname, cond_to_str(cond), bit_s ? "s" : "", rdlo, rdhi, rm, rs);
-    return ptr;
-}
-
-char *Arm::disasm_mul(Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rd = (insn >> 16) & 0xf;
-    uint8_t rs = (insn >> 8) & 0xf;
-    uint8_t rm = insn & 0xf;
-    uint8_t bit_s = (insn >> 20) & 1;
-
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s%s\tr%d, r%d, r%d",
-            opname, cond_to_str(cond), bit_s ? "s" : "", rd, rm, rs);
-    return ptr;
-}
-
-char *Arm::disasm_mrs(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint8_t ps = (insn >> 22) & 1;
-
-    sprintf(ptr, "mrs%s\tr%d, %s", cond_to_str(cond), rd, ps ? "spsr" : "cpsr");
-    return ptr;
-}
-
-char *Arm::disasm_msr(uint32_t insn, char *ptr)
-{
-    char flags[8];
-    int flag_index = 0;
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t is_immed = (insn >> 25) & 0x1;
-    uint8_t pd = (insn >> 22) & 1;
-    uint8_t mask = (insn >> 16) & 0xf;
-
-    if (mask & 1)
-        flags[flag_index++] = 'c';
-    if (mask & 2)
-        flags[flag_index++] = 'x';
-    if (mask & 4)
-        flags[flag_index++] = 's';
-    if (mask & 8)
-        flags[flag_index++] = 'f';
-    flags[flag_index] = 0;
-
-    if (is_immed) {
-        uint32_t immed = insn & 0xff;
-        uint8_t rotate = (insn >> 8) & 0xf;
-        uint8_t rotate2 = rotate << 1;
-        uint32_t rotated_val = (immed >> rotate2) | (immed << (32 - rotate2));
-        sprintf(ptr, "msr%s\t%s_%s, #0x%x",
-                cond_to_str(cond), pd ? "spsr" : "cpsr", flags, rotated_val);
-        return ptr;
-    }
-
-    uint8_t rm = insn & 0xf;
-
-    sprintf(ptr, "msr%s\t%s_%s, r%d",
-            cond_to_str(cond), pd ? "spsr" : "cpsr", flags, rm);
-    return ptr;
-}
-
-char *Arm::disasm_pld(uint32_t insn, char *ptr)
-{
-    uint8_t is_reg = (insn >> 25) & 0x1;
-    uint8_t is_up = (insn >> 23) & 0x1;
-    uint8_t rn = (insn >> 16) & 0xf;
-
-    char *minus = "";
-    if (is_up == 0)
-        minus = "-";
-
-    if (is_reg) {
-        uint8_t rm = insn & 0xf;
-        sprintf(ptr, "pld\t[r%d, %sr%d]", rn, minus, rm);
-        return ptr;
-    }
-
-    uint16_t offset = insn & 0xfff;
-    if (offset == 0) {
-        sprintf(ptr, "pld\t[r%d]", rn);
-    } else {
-        sprintf(ptr, "pld\t[r%d, #%s%u]", rn, minus, offset);
-    }
-    return ptr;
-}
-
-char *Arm::disasm_swi(uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint32_t sysnum = insn & 0x00ffffff;
-
-    sprintf(ptr, "swi%s 0x%x", cond_to_str(cond), sysnum);
-    return ptr;
-}
-
-char *Arm::disasm_swp(Opcode opcode, uint32_t insn, char *ptr)
-{
-    uint8_t cond = (insn >> 28) & 0xf;
-    uint8_t rn = (insn >> 16) & 0xf;
-    uint8_t rd = (insn >> 12) & 0xf;
-    uint8_t rm = insn & 0xf;
-
-    const char *opname = opcode_names[opcode];
-    sprintf(ptr, "%s%s\tr%d, r%d, [r%d]", opname, cond_to_str(cond), rd, rm, rn);
-    return ptr;
-}
-
-Opcode Arm::decode(uint32_t insn) {
-    uint32_t bits27_26 = (insn >> 26) & 0x3;
-    switch (bits27_26) {
-        case 0x0:
-            return decode00(insn);
-        case 0x1:
-            return decode01(insn);
-        case 0x2:
-            return decode10(insn);
-        case 0x3:
-            return decode11(insn);
-    }
-    return OP_INVALID;
-}
-
-Opcode Arm::decode00(uint32_t insn) {
-    uint8_t bit25 = (insn >> 25) & 0x1;
-    uint8_t bit4 = (insn >> 4) & 0x1;
-    if (bit25 == 0 && bit4 == 1) {
-        if ((insn & 0x0ffffff0) == 0x012fff10) {
-            // Bx instruction
-            return OP_BX;
-        }
-        if ((insn & 0x0ff000f0) == 0x01600010) {
-            // Clz instruction
-            return OP_CLZ;
-        }
-        if ((insn & 0xfff000f0) == 0xe1200070) {
-            // Bkpt instruction
-            return OP_BKPT;
-        }
-        uint32_t bits7_4 = (insn >> 4) & 0xf;
-        if (bits7_4 == 0x9) {
-            if ((insn & 0x0ff00ff0) == 0x01000090) {
-                // Swp instruction
-                uint8_t bit22 = (insn >> 22) & 0x1;
-                if (bit22)
-                    return OP_SWPB;
-                return OP_SWP;
-            }
-            // One of the multiply instructions
-            return decode_mul(insn);
-        }
-
-        uint8_t bit7 = (insn >> 7) & 0x1;
-        if (bit7 == 1) {
-            // One of the load/store halfword/byte instructions
-            return decode_ldrh(insn);
-        }
-    }
-
-    // One of the data processing instructions
-    return decode_alu(insn);
-}
-
-Opcode Arm::decode01(uint32_t insn) {
-    uint8_t is_reg = (insn >> 25) & 0x1;
-    uint8_t bit4 = (insn >> 4) & 0x1;
-    if (is_reg == 1 && bit4 == 1)
-        return OP_UNDEFINED;
-    uint8_t is_load = (insn >> 20) & 0x1;
-    uint8_t is_byte = (insn >> 22) & 0x1;
-    if ((insn & 0xfd70f000) == 0xf550f000) {
-        // Pre-load
-        return OP_PLD;
-    }
-    if (is_load) {
-        if (is_byte) {
-            // Load byte
-            return OP_LDRB;
-        }
-        // Load word
-        return OP_LDR;
-    }
-    if (is_byte) {
-        // Store byte
-        return OP_STRB;
-    }
-    // Store word
-    return OP_STR;
-}
-
-Opcode Arm::decode10(uint32_t insn) {
-    uint8_t bit25 = (insn >> 25) & 0x1;
-    if (bit25 == 0) {
-        // LDM/STM
-        uint8_t is_load = (insn >> 20) & 0x1;
-        if (is_load)
-            return OP_LDM;
-        return OP_STM;
-    }
-    // Branch or Branch with link
-    uint8_t is_link = (insn >> 24) & 1;
-    uint32_t offset = insn & 0xffffff;
-
-    // Sign-extend the 24-bit offset
-    if ((offset >> 23) & 1)
-        offset |= 0xff000000;
-
-    // Pre-compute the left-shift and the prefetch offset
-    offset <<= 2;
-    offset += 8;
-    if (is_link == 0)
-        return OP_B;
-    return OP_BL;
-}
-
-Opcode Arm::decode11(uint32_t insn) {
-    uint8_t bit25 = (insn >> 25) & 0x1;
-    if (bit25 == 0) {
-        // LDC, SDC
-        uint8_t is_load = (insn >> 20) & 0x1;
-        if (is_load) {
-            // LDC
-            return OP_LDC;
-        }
-        // STC
-        return OP_STC;
-    }
-
-    uint8_t bit24 = (insn >> 24) & 0x1;
-    if (bit24 == 0x1) {
-        // SWI
-        return OP_SWI;
-    }
-  
-    uint8_t bit4 = (insn >> 4) & 0x1;
-    uint8_t cpnum = (insn >> 8) & 0xf;
-
-    if (cpnum == 15) {
-        // Special case for coprocessor 15
-        uint8_t opcode = (insn >> 21) & 0x7;
-        if (bit4 == 0 || opcode != 0) {
-            // This is an unexpected bit pattern.  Create an undefined
-            // instruction in case this is ever executed.
-            return OP_UNDEFINED;
-        }
-
-        // MRC, MCR
-        uint8_t is_mrc = (insn >> 20) & 0x1;
-        if (is_mrc)
-            return OP_MRC;
-        return OP_MCR;
-    }
-
-    if (bit4 == 0) {
-        // CDP
-        return OP_CDP;
-    }
-    // MRC, MCR
-    uint8_t is_mrc = (insn >> 20) & 0x1;
-    if (is_mrc)
-        return OP_MRC;
-    return OP_MCR;
-}
-
-Opcode Arm::decode_mul(uint32_t insn) {
-    uint8_t bit24 = (insn >> 24) & 0x1;
-    if (bit24 != 0) {
-        // This is an unexpected bit pattern.  Create an undefined
-        // instruction in case this is ever executed.
-        return OP_UNDEFINED;
-    }
-    uint8_t bit23 = (insn >> 23) & 0x1;
-    uint8_t bit22_U = (insn >> 22) & 0x1;
-    uint8_t bit21_A = (insn >> 21) & 0x1;
-    if (bit23 == 0) {
-        // 32-bit multiply
-        if (bit22_U != 0) {
-            // This is an unexpected bit pattern.  Create an undefined
-            // instruction in case this is ever executed.
-            return OP_UNDEFINED;
-        }
-        if (bit21_A == 0)
-            return OP_MUL;
-        return OP_MLA;
-    }
-    // 64-bit multiply
-    if (bit22_U == 0) {
-        // Unsigned multiply long
-        if (bit21_A == 0)
-            return OP_UMULL;
-        return OP_UMLAL;
-    }
-    // Signed multiply long
-    if (bit21_A == 0)
-        return OP_SMULL;
-    return OP_SMLAL;
-}
-
-Opcode Arm::decode_ldrh(uint32_t insn) {
-    uint8_t is_load = (insn >> 20) & 0x1;
-    uint8_t bits_65 = (insn >> 5) & 0x3;
-    if (is_load) {
-        if (bits_65 == 0x1) {
-            // Load unsigned halfword
-            return OP_LDRH;
-        } else if (bits_65 == 0x2) {
-            // Load signed byte
-            return OP_LDRSB;
-        }
-        // Signed halfword
-        if (bits_65 != 0x3) {
-            // This is an unexpected bit pattern.  Create an undefined
-            // instruction in case this is ever executed.
-            return OP_UNDEFINED;
-        }
-        // Load signed halfword
-        return OP_LDRSH;
-    }
-    // Store halfword
-    if (bits_65 != 0x1) {
-        // This is an unexpected bit pattern.  Create an undefined
-        // instruction in case this is ever executed.
-        return OP_UNDEFINED;
-    }
-    // Store halfword
-    return OP_STRH;
-}
-
-Opcode Arm::decode_alu(uint32_t insn) {
-    uint8_t is_immed = (insn >> 25) & 0x1;
-    uint8_t opcode = (insn >> 21) & 0xf;
-    uint8_t bit_s = (insn >> 20) & 1;
-    uint8_t shift_is_reg = (insn >> 4) & 1;
-    uint8_t bit7 = (insn >> 7) & 1;
-    if (!is_immed && shift_is_reg && (bit7 != 0)) {
-        // This is an unexpected bit pattern.  Create an undefined
-        // instruction in case this is ever executed.
-        return OP_UNDEFINED;
-    }
-    switch (opcode) {
-        case 0x0:
-            return OP_AND;
-        case 0x1:
-            return OP_EOR;
-        case 0x2:
-            return OP_SUB;
-        case 0x3:
-            return OP_RSB;
-        case 0x4:
-            return OP_ADD;
-        case 0x5:
-            return OP_ADC;
-        case 0x6:
-            return OP_SBC;
-        case 0x7:
-            return OP_RSC;
-        case 0x8:
-            if (bit_s)
-                return OP_TST;
-            return OP_MRS;
-        case 0x9:
-            if (bit_s)
-                return OP_TEQ;
-            return OP_MSR;
-        case 0xa:
-            if (bit_s)
-                return OP_CMP;
-            return OP_MRS;
-        case 0xb:
-            if (bit_s)
-                return OP_CMN;
-            return OP_MSR;
-        case 0xc:
-            return OP_ORR;
-        case 0xd:
-            return OP_MOV;
-        case 0xe:
-            return OP_BIC;
-        case 0xf:
-            return OP_MVN;
-    }
-    // Unreachable
-    return OP_INVALID;
-}
diff --git a/emulator/qtools/armdis.h b/emulator/qtools/armdis.h
deleted file mode 100644
index 230f833..0000000
--- a/emulator/qtools/armdis.h
+++ /dev/null
@@ -1,45 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef ARMDIS_H
-#define ARMDIS_H
-
-#include <inttypes.h>
-#include "opcode.h"
-
-class Arm {
- public:
-  static char *disasm(uint32_t addr, uint32_t insn, char *buffer);
-  static Opcode decode(uint32_t insn);
-
- private:
-  static Opcode decode00(uint32_t insn);
-  static Opcode decode01(uint32_t insn);
-  static Opcode decode10(uint32_t insn);
-  static Opcode decode11(uint32_t insn);
-  static Opcode decode_mul(uint32_t insn);
-  static Opcode decode_ldrh(uint32_t insn);
-  static Opcode decode_alu(uint32_t insn);
-
-  static char *disasm_alu(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_branch(uint32_t addr, Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_bx(uint32_t insn, char *ptr);
-  static char *disasm_bkpt(uint32_t insn, char *ptr);
-  static char *disasm_clz(uint32_t insn, char *ptr);
-  static char *disasm_memblock(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_mem(uint32_t insn, char *ptr);
-  static char *disasm_memhalf(uint32_t insn, char *ptr);
-  static char *disasm_mcr(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_mla(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_umlal(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_mul(Opcode opcode, uint32_t insn, char *ptr);
-  static char *disasm_mrs(uint32_t insn, char *ptr);
-  static char *disasm_msr(uint32_t insn, char *ptr);
-  static char *disasm_pld(uint32_t insn, char *ptr);
-  static char *disasm_swi(uint32_t insn, char *ptr);
-  static char *disasm_swp(Opcode opcode, uint32_t insn, char *ptr);
-};
-
-extern char *disasm_insn_thumb(uint32_t pc, uint32_t insn1, uint32_t insn2, char *result);
-extern Opcode decode_insn_thumb(uint32_t given);
-
-#endif /* ARMDIS_H */
diff --git a/emulator/qtools/bb2sym.cpp b/emulator/qtools/bb2sym.cpp
deleted file mode 100644
index 8a18b67..0000000
--- a/emulator/qtools/bb2sym.cpp
+++ /dev/null
@@ -1,140 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-struct MyStaticRec {
-    StaticRec   bb;
-    symbol_type *sym;
-    MyStaticRec *inner;    // pointer to an inner basic block
-    int         is_thumb;
-};
-
-MyStaticRec **assign_inner_blocks(int num_blocks, MyStaticRec *blocks);
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_file elf_file\n", program);
-    OptionsUsage();
-}
-
-// This function is called from quicksort to compare addresses of basic
-// blocks.
-int cmp_inc_addr(const void *a, const void *b) {
-    MyStaticRec *bb1, *bb2;
-
-    bb1 = *(MyStaticRec**)a;
-    bb2 = *(MyStaticRec**)b;
-    if (bb1->bb.bb_addr < bb2->bb.bb_addr)
-        return -1;
-    if (bb1->bb.bb_addr > bb2->bb.bb_addr)
-        return 1;
-    return bb1->bb.bb_num - bb2->bb.bb_num;
-}
-
-int main(int argc, char **argv) {
-    uint32_t insns[kMaxInsnPerBB];
-
-    // Parse the options
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<> *trace = new TraceReader<>;
-    trace->Open(trace_filename);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    TraceHeader *header = trace->GetHeader();
-    uint32_t num_static_bb = header->num_static_bb;
-
-    // Allocate space for all of the static blocks
-    MyStaticRec *blocks = new MyStaticRec[num_static_bb];
-
-    // Read in all the static blocks
-    for (uint32_t ii = 0; ii < num_static_bb; ++ii) {
-        trace->ReadStatic(&blocks[ii].bb);
-        blocks[ii].is_thumb = blocks[ii].bb.bb_addr & 1;
-        blocks[ii].bb.bb_addr &= ~1;
-        blocks[ii].sym = NULL;
-        blocks[ii].inner = NULL;
-        trace->ReadStaticInsns(blocks[ii].bb.num_insns, insns);
-    }
-
-    MyStaticRec **sorted = assign_inner_blocks(num_static_bb, blocks);
-
-    while (1) {
-        symbol_type *sym;
-        BBEvent event;
-        BBEvent ignored;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &sym))
-            break;
-
-        uint64_t bb_num = event.bb_num;
-        blocks[bb_num].sym = sym;
-    }
-        
-    printf("#     bb num_insns     bb_addr file  symbol\n");
-    for (uint32_t ii = 0; ii < num_static_bb; ++ii) {
-        if (sorted[ii]->bb.bb_addr == 0 || sorted[ii]->bb.num_insns == 0
-            || sorted[ii]->sym == NULL)
-            continue;
-
-        printf("%8lld       %3d  0x%08x %s %s\n",
-               sorted[ii]->bb.bb_num, sorted[ii]->bb.num_insns,
-               sorted[ii]->bb.bb_addr, sorted[ii]->sym->region->path,
-               sorted[ii]->sym->name);
-    }
-    return 0;
-}
-
-// Find the basic blocks that are subsets of other basic blocks.
-MyStaticRec **assign_inner_blocks(int num_blocks, MyStaticRec *blocks)
-{
-    int ii;
-    uint32_t addr_end, addr_diff;
-
-    // Create a list of pointers to the basic blocks that we can sort.
-    MyStaticRec **sorted = new MyStaticRec*[num_blocks];
-    for (ii = 0; ii < num_blocks; ++ii) {
-        sorted[ii] = &blocks[ii];
-    }
-
-    // Sort the basic blocks into increasing address order
-    qsort(sorted, num_blocks, sizeof(MyStaticRec*), cmp_inc_addr);
-
-    // Create pointers to inner blocks and break up the enclosing block
-    // so that there is no overlap.
-    for (ii = 0; ii < num_blocks - 1; ++ii) {
-        int num_bytes;
-        if (sorted[ii]->is_thumb)
-            num_bytes = sorted[ii]->bb.num_insns << 1;
-        else
-            num_bytes = sorted[ii]->bb.num_insns << 2;
-        addr_end = sorted[ii]->bb.bb_addr + num_bytes;
-        if (addr_end > sorted[ii + 1]->bb.bb_addr) {
-            sorted[ii]->inner = sorted[ii + 1];
-            addr_diff = sorted[ii + 1]->bb.bb_addr - sorted[ii]->bb.bb_addr;
-            uint32_t num_insns;
-            if (sorted[ii]->is_thumb)
-                num_insns = addr_diff >> 1;
-            else
-                num_insns = addr_diff >> 2;
-            sorted[ii]->bb.num_insns = num_insns;
-        }
-    }
-
-    return sorted;
-}
diff --git a/emulator/qtools/bb_dump.cpp b/emulator/qtools/bb_dump.cpp
deleted file mode 100644
index de241fb..0000000
--- a/emulator/qtools/bb_dump.cpp
+++ /dev/null
@@ -1,47 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_file elf_file\n", program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv) {
-    // Parse the options
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<> *trace = new TraceReader<>;
-    trace->Open(trace_filename);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    printf("#  time   bb   pid num_insns  bb_addr\n");
-    while (1) {
-        symbol_type *sym;
-        BBEvent event;
-        BBEvent ignored;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &sym))
-            break;
-        printf("%7lld %4lld %5d       %3d  0x%08x %s\n",
-               event.time, event.bb_num, event.pid, event.num_insns,
-               event.bb_addr, sym->name);
-    }
-    return 0;
-}
diff --git a/emulator/qtools/bbprof.cpp b/emulator/qtools/bbprof.cpp
deleted file mode 100644
index 36d0941..0000000
--- a/emulator/qtools/bbprof.cpp
+++ /dev/null
@@ -1,222 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-#include "armdis.h"
-
-struct MyStaticRec {
-    StaticRec   bb;
-    uint32_t    *insns;
-    uint32_t    *cycles;    // number of cycles for each insn
-    uint32_t    elapsed;    // number of cycles for basic block
-    int         freq;       // execution frequency
-    MyStaticRec *inner;     // pointer to an inner basic block
-    int         is_thumb;
-};
-
-MyStaticRec **assign_inner_blocks(int num_blocks, MyStaticRec *blocks);
-
-// This function is called from quicksort to compare addresses of basic
-// blocks.
-int cmp_inc_addr(const void *a, const void *b) {
-    MyStaticRec *bb1, *bb2;
-
-    bb1 = *(MyStaticRec**)a;
-    bb2 = *(MyStaticRec**)b;
-    if (bb1->bb.bb_addr < bb2->bb.bb_addr)
-        return -1;
-    if (bb1->bb.bb_addr > bb2->bb.bb_addr)
-        return 1;
-    return bb1->bb.bb_num - bb2->bb.bb_num;
-}
-
-// This function is called from quicksort to compare the elapsed time
-// of basic blocks.
-int cmp_dec_elapsed(const void *a, const void *b) {
-    MyStaticRec *bb1, *bb2;
-
-    bb1 = *(MyStaticRec**)a;
-    bb2 = *(MyStaticRec**)b;
-    if (bb1->elapsed < bb2->elapsed)
-        return 1;
-    if (bb1->elapsed > bb2->elapsed)
-        return -1;
-    return bb1->bb.bb_num - bb2->bb.bb_num;
-}
-
-// This function is called from quicksort to compare frequencies of
-// basic blocks.
-int cmp_dec_freq(const void *a, const void *b) {
-    MyStaticRec *bb1, *bb2;
-
-    bb1 = *(MyStaticRec**)a;
-    bb2 = *(MyStaticRec**)b;
-    if (bb1->freq < bb2->freq)
-        return 1;
-    if (bb1->freq > bb2->freq)
-        return -1;
-    return bb1->bb.bb_num - bb2->bb.bb_num;
-}
-
-int main(int argc, char **argv)
-{
-    if (argc != 2) {
-        fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[1];
-    TraceReaderBase *trace = new TraceReaderBase;
-    trace->Open(trace_filename);
-    TraceHeader *header = trace->GetHeader();
-    uint32_t num_static_bb = header->num_static_bb;
-
-    // Allocate space for all of the static blocks
-    MyStaticRec *blocks = new MyStaticRec[num_static_bb];
-
-    // Read in all the static blocks
-    for (uint32_t ii = 0; ii < num_static_bb; ++ii) {
-        trace->ReadStatic(&blocks[ii].bb);
-        blocks[ii].is_thumb = blocks[ii].bb.bb_addr & 1;
-        blocks[ii].bb.bb_addr &= ~1;
-        uint32_t num_insns = blocks[ii].bb.num_insns;
-        blocks[ii].insns = new uint32_t[num_insns];
-        blocks[ii].cycles = new uint32_t[num_insns];
-        memset(blocks[ii].cycles, 0, num_insns * sizeof(uint32_t));
-        trace->ReadStaticInsns(num_insns, blocks[ii].insns);
-        blocks[ii].elapsed = 0;
-        blocks[ii].freq = 0;
-        blocks[ii].inner = NULL;
-    }
-
-    MyStaticRec **sorted = assign_inner_blocks(num_static_bb, blocks);
-
-    uint32_t prev_time = 0;
-    uint32_t elapsed = 0;
-    uint32_t dummy;
-    uint32_t *cycle_ptr = &dummy;
-    uint32_t *bb_elapsed_ptr = &dummy;
-    while (1) {
-        BBEvent event;
-
-        if (trace->ReadBB(&event))
-            break;
-        // Assign frequencies to each basic block
-        uint64_t bb_num = event.bb_num;
-        int num_insns = event.num_insns;
-        blocks[bb_num].freq += 1;
-        for (MyStaticRec *bptr = blocks[bb_num].inner; bptr; bptr = bptr->inner)
-            bptr->freq += 1;
-
-        // Assign simulation time to each instruction
-        for (MyStaticRec *bptr = &blocks[bb_num]; bptr; bptr = bptr->inner) {
-            uint32_t bb_num_insns = bptr->bb.num_insns;
-            for (uint32_t ii = 0; num_insns && ii < bb_num_insns; ++ii, --num_insns) {
-                uint32_t sim_time = trace->ReadInsnTime(event.time);
-                elapsed = sim_time - prev_time;
-                prev_time = sim_time;
-
-                // Attribute the elapsed time to the previous instruction and
-                // basic block.
-                *cycle_ptr += elapsed;
-                *bb_elapsed_ptr += elapsed;
-                cycle_ptr = &bptr->cycles[ii];
-                bb_elapsed_ptr = &bptr->elapsed;
-            }
-        }
-    }
-    *cycle_ptr += 1;
-    *bb_elapsed_ptr += 1;
-
-    // Sort the basic blocks into decreasing elapsed time
-    qsort(sorted, num_static_bb, sizeof(MyStaticRec*), cmp_dec_elapsed);
-
-    char spaces[80];
-    memset(spaces, ' ', 79);
-    spaces[79] = 0;
-    for (uint32_t ii = 0; ii < num_static_bb; ++ii) {
-        printf("bb %lld addr: 0x%x, insns: %d freq: %u elapsed: %u\n",
-               sorted[ii]->bb.bb_num, sorted[ii]->bb.bb_addr,
-               sorted[ii]->bb.num_insns, sorted[ii]->freq,
-               sorted[ii]->elapsed);
-        int num_insns = sorted[ii]->bb.num_insns;
-        uint32_t addr = sorted[ii]->bb.bb_addr;
-        for (int jj = 0; jj < num_insns; ++jj) {
-            uint32_t elapsed = sorted[ii]->cycles[jj];
-            uint32_t insn = sorted[ii]->insns[jj];
-            if (insn_is_thumb(insn)) {
-                insn = insn_unwrap_thumb(insn);
-
-                // thumb_pair is true if this is the first of a pair of
-                // thumb instructions (BL or BLX).
-                bool thumb_pair = ((insn & 0xf800) == 0xf000);
-
-                // Get the next thumb instruction (if any) because we may need
-                // it for the case where insn is BL or BLX.
-                uint32_t insn2 = 0;
-                if (thumb_pair && (jj + 1 < num_insns)) {
-                    insn2 = sorted[ii]->insns[jj + 1];
-                    insn2 = insn_unwrap_thumb(insn2);
-                    jj += 1;
-                }
-                char *disasm = disasm_insn_thumb(addr, insn, insn2, NULL);
-                if (thumb_pair) {
-                    printf("  %4u %08x %04x %04x %s\n", elapsed, addr, insn,
-                           insn2, disasm);
-                    addr += 2;
-                } else {
-                    printf("  %4u %08x     %04x %s\n", elapsed, addr, insn,
-                           disasm);
-                }
-                addr += 2;
-            } else {
-                char *disasm = Arm::disasm(addr, insn, NULL);
-                printf("  %4u %08x %08x %s\n", elapsed, addr, insn, disasm);
-                addr += 4;
-            }
-        }
-    }
-
-    delete[] sorted;
-    return 0;
-}
-
-// Find the basic blocks that are subsets of other basic blocks.
-MyStaticRec **assign_inner_blocks(int num_blocks, MyStaticRec *blocks)
-{
-    int ii;
-    uint32_t addr_end, addr_diff;
-
-    // Create a list of pointers to the basic blocks that we can sort.
-    MyStaticRec **sorted = new MyStaticRec*[num_blocks];
-    for (ii = 0; ii < num_blocks; ++ii) {
-        sorted[ii] = &blocks[ii];
-    }
-
-    // Sort the basic blocks into increasing address order
-    qsort(sorted, num_blocks, sizeof(MyStaticRec*), cmp_inc_addr);
-
-    // Create pointers to inner blocks and break up the enclosing block
-    // so that there is no overlap.
-    for (ii = 0; ii < num_blocks - 1; ++ii) {
-        int num_bytes;
-        if (sorted[ii]->is_thumb)
-            num_bytes = sorted[ii]->bb.num_insns << 1;
-        else
-            num_bytes = sorted[ii]->bb.num_insns << 2;
-        addr_end = sorted[ii]->bb.bb_addr + num_bytes;
-        if (addr_end > sorted[ii + 1]->bb.bb_addr) {
-            sorted[ii]->inner = sorted[ii + 1];
-            addr_diff = sorted[ii + 1]->bb.bb_addr - sorted[ii]->bb.bb_addr;
-            uint32_t num_insns;
-            if (sorted[ii]->is_thumb)
-                num_insns = addr_diff >> 1;
-            else
-                num_insns = addr_diff >> 2;
-            sorted[ii]->bb.num_insns = num_insns;
-        }
-    }
-
-    return sorted;
-}
diff --git a/emulator/qtools/bitvector.h b/emulator/qtools/bitvector.h
deleted file mode 100644
index d3f5cf1..0000000
--- a/emulator/qtools/bitvector.h
+++ /dev/null
@@ -1,40 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef BITVECTOR_H
-#define BITVECTOR_H
-
-#include <inttypes.h>
-#include <assert.h>
-
-class Bitvector {
- public:
-  explicit Bitvector(int num_bits) {
-    num_bits_ = num_bits;
-
-    // Round up to a multiple of 32
-    num_bits = (num_bits + 31) & ~31;
-    vector_ = new uint32_t[num_bits >> 5];
-  }
-  ~Bitvector() {
-    delete[] vector_;
-  }
-
-  void        SetBit(int bitnum) {
-    assert(bitnum < num_bits_);
-    vector_[bitnum >> 5] |= 1 << (bitnum & 31);
-  }
-  void        ClearBit(int bitnum) {
-    assert(bitnum < num_bits_);
-    vector_[bitnum >> 5] &= ~(1 << (bitnum & 31));
-  }
-  bool        GetBit(int bitnum) {
-    assert(bitnum < num_bits_);
-    return (vector_[bitnum >> 5] >> (bitnum & 31)) & 1;
-  }
-
- private:
-  int         num_bits_;
-  uint32_t    *vector_;
-};
-
-#endif  // BITVECTOR_H
diff --git a/emulator/qtools/callstack.h b/emulator/qtools/callstack.h
deleted file mode 100644
index b869956..0000000
--- a/emulator/qtools/callstack.h
+++ /dev/null
@@ -1,760 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef CALL_STACK_H
-#define CALL_STACK_H
-
-#include "opcode.h"
-#include "armdis.h"
-
-class CallStackBase {
-  public:
-    int    getId()          { return mId; }
-    void   setId(int id)    { mId = id; }
-
-  private:
-    int    mId;
-};
-
-// Define a template class for the stack frame.  The template parameter
-// SYM is the symbol_type from the TraceReader<> template class. To
-// use the CallStack class, the user derives a subclass of StackFrame
-// and defines push() and pop() methods.  This derived class is then
-// passed as a template parameter to CallStack.
-template <class SYM>
-class StackFrame {
-  public:
-
-    virtual ~StackFrame() {};
-
-    virtual void push(int stackLevel, uint64_t time, CallStackBase *base) {};
-    virtual void pop(int stackLevel, uint64_t time, CallStackBase *base) {};
-
-    typedef SYM symbol_type;
-    static const uint32_t kCausedException = 0x01;
-    static const uint32_t kInterpreted     = 0x02;
-    static const uint32_t kPopBarrier      = (kCausedException | kInterpreted);
-
-    symbol_type *function;      // the symbol for the function we entered
-    uint32_t    addr;           // return address when this function returns
-    uint32_t    flags;
-    uint32_t    time;           // for debugging when a problem occurred
-    uint32_t    global_time;    // for debugging when a problem occurred
-};
-
-template <class FRAME, class BASE = CallStackBase>
-class CallStack : public BASE {
-  public:
-    typedef typename FRAME::symbol_type symbol_type;
-    typedef typename FRAME::symbol_type::region_type region_type;
-    typedef BASE base_type;
-
-    CallStack(int id, int numFrames, TraceReaderType *trace);
-    ~CallStack();
-
-    void    updateStack(BBEvent *event, symbol_type *function);
-    void    popAll(uint64_t time);
-    void    threadStart(uint64_t time);
-    void    threadStop(uint64_t time);
-
-    // Set to true if you don't want to see any Java methods
-    void    setNativeOnly(bool nativeOnly) {
-        mNativeOnly = nativeOnly;
-    }
-
-    int         getStackLevel() { return mTop; }
-
-    uint64_t    getGlobalTime(uint64_t time) { return time + mSkippedTime; }
-    void        showStack();
-    void        showSnapshotStack();
-
-  private:
-    enum Action { NONE, PUSH, POP };
-
-    Action      getAction(BBEvent *event, symbol_type *function);
-    Action      getMethodAction(BBEvent *event, symbol_type *function);
-    void        doSimplePush(symbol_type *function, uint32_t addr,
-                             uint64_t time);
-    void        doSimplePop(uint64_t time);
-    void        doPush(BBEvent *event, symbol_type *function);
-    void        doPop(BBEvent *event, symbol_type *function, Action methodAction);
-
-    void        transitionToJava();
-    void        transitionFromJava(uint64_t time);
-
-    TraceReaderType *mTrace;
-    bool        mNativeOnly;
-
-    symbol_type mDummyFunction;
-    region_type mDummyRegion;
-
-    int         mNumFrames;
-    FRAME       *mFrames;
-    int         mTop;           // index of the next stack frame to write
-
-    int         mJavaTop;
-
-    int         mSnapshotNumFrames;
-    FRAME       *mSnapshotFrames;
-    int         mSnapshotTop;   // index of the next stack frame to write
-
-    symbol_type *mPrevFunction;
-    BBEvent     mPrevEvent;
-
-    symbol_type *mUserFunction;
-    BBEvent     mUserEvent;     // the previous user-mode event
-
-    uint64_t    mSkippedTime;
-    uint64_t    mLastRunTime;
-
-    static MethodRec    sCurrentMethod;
-    static MethodRec    sNextMethod;
-};
-
-template<class FRAME, class BASE>
-MethodRec CallStack<FRAME, BASE>::sCurrentMethod;
-template<class FRAME, class BASE>
-MethodRec CallStack<FRAME, BASE>::sNextMethod;
-
-template<class FRAME, class BASE>
-CallStack<FRAME, BASE>::CallStack(int id, int numFrames, TraceReaderType *trace)
-{
-    mNativeOnly = false;
-    mTrace = trace;
-    BASE::setId(id);
-    mNumFrames = numFrames;
-    mFrames = new FRAME[mNumFrames];
-    mTop = 0;
-
-    mSnapshotNumFrames = numFrames;
-    mSnapshotFrames = new FRAME[mSnapshotNumFrames];
-    mSnapshotTop = 0;
-
-    memset(&mDummyFunction, 0, sizeof(symbol_type));
-    memset(&mDummyRegion, 0, sizeof(region_type));
-    mDummyFunction.region = &mDummyRegion;
-    mPrevFunction = &mDummyFunction;
-    memset(&mPrevEvent, 0, sizeof(BBEvent));
-    mUserFunction = &mDummyFunction;
-    memset(&mUserEvent, 0, sizeof(BBEvent));
-    mSkippedTime = 0;
-    mLastRunTime = 0;
-    mJavaTop = 0;
-
-    // Read the first two methods from the trace if we haven't already read
-    // from the method trace yet.
-    if (sCurrentMethod.time == 0) {
-        if (mTrace->ReadMethod(&sCurrentMethod)) {
-            sCurrentMethod.time = ~0ull;
-            sNextMethod.time = ~0ull;
-        }
-        if (sNextMethod.time != ~0ull && mTrace->ReadMethod(&sNextMethod)) {
-            sNextMethod.time = ~0ull;
-        }
-    }
-}
-
-template<class FRAME, class BASE>
-CallStack<FRAME, BASE>::~CallStack()
-{
-    delete mFrames;
-}
-
-template<class FRAME, class BASE>
-void
-CallStack<FRAME, BASE>::updateStack(BBEvent *event, symbol_type *function)
-{
-    if (mNativeOnly) {
-        // If this is an interpreted function, then use the native VM function
-        // instead.
-        if (function->vm_sym != NULL)
-            function = function->vm_sym;
-    }
-
-    Action action = getAction(event, function);
-    Action methodAction = getMethodAction(event, function);
-
-    // Pop off native functions before pushing or popping Java methods.
-    if (action == POP && mPrevFunction->vm_sym == NULL) {
-        // Pop off the previous function first.
-        doPop(event, function, NONE);
-        if (methodAction == POP) {
-            doPop(event, function, POP);
-        } else if (methodAction == PUSH) {
-            doPush(event, function);
-        }
-    } else {
-        if (methodAction != NONE) {
-            // If the method trace has a push or pop, then do it.
-            action = methodAction;
-        } else if (function->vm_sym != NULL) {
-            // This function is a Java method.  Don't push or pop the
-            // Java method without a corresponding method trace record.
-            action = NONE;
-        }
-        if (action == POP) {
-            doPop(event, function, methodAction);
-        } else if (action == PUSH) {
-            doPush(event, function);
-        }
-    }
-
-    // If the stack is now empty, then push the current function.
-    if (mTop == 0) {
-        uint64_t time = event->time - mSkippedTime;
-        doSimplePush(function, 0, time);
-    }
-
-    mPrevFunction = function;
-    mPrevEvent = *event;
-}
-
-template<class FRAME, class BASE>
-void
-CallStack<FRAME, BASE>::threadStart(uint64_t time)
-{
-    mSkippedTime += time - mLastRunTime;
-}
-
-template<class FRAME, class BASE>
-void
-CallStack<FRAME, BASE>::threadStop(uint64_t time)
-{
-    mLastRunTime = time;
-}
-
-template<class FRAME, class BASE>
-typename CallStack<FRAME, BASE>::Action
-CallStack<FRAME, BASE>::getAction(BBEvent *event, symbol_type *function)
-{
-    Action action;
-    uint32_t offset;
-
-    // Compute the offset from the start of the function to this basic
-    // block address.
-    offset = event->bb_addr - function->addr - function->region->base_addr;
-
-    // Get the previously executed instruction
-    Opcode op = OP_INVALID;
-    int numInsns = mPrevEvent.num_insns;
-    uint32_t insn = 0;
-    if (numInsns > 0) {
-        insn = mPrevEvent.insns[numInsns - 1];
-        if (mPrevEvent.is_thumb) {
-            insn = insn_unwrap_thumb(insn);
-            op = decode_insn_thumb(insn);
-        } else {
-            op = Arm::decode(insn);
-        }
-    }
-
-    // The number of bytes in the previous basic block depends on
-    // whether the basic block was ARM or THUMB instructions.
-    int numBytes;
-    if (mPrevEvent.is_thumb) {
-        numBytes = numInsns << 1;
-    } else {
-        numBytes = numInsns << 2;
-    }
-
-    // If this basic block follows the previous one, then return NONE.
-    // If we don't do this, then we may be fooled into thinking this
-    // is a POP if the previous block ended with a conditional
-    // (non-executed) ldmia instruction.  We do this check before
-    // checking if we are in a different function because we otherwise
-    // we might be fooled into thinking this is a PUSH to a new function
-    // when it is really just a fall-thru into a local kernel symbol
-    // that just looks like a new function.
-    uint32_t prev_end_addr = mPrevEvent.bb_addr + numBytes;
-    if (prev_end_addr == event->bb_addr) {
-        return NONE;
-    }
-
-    // If this basic block is in the same function as the last basic block,
-    // then just return NONE (but see the exceptions below).
-    // Exception 1: if the function calls itself (offset == 0) then we
-    // want to push this function.
-    // Exception 2: if the function returns to itself, then we want
-    // to pop this function.  We detect this case by checking if the last
-    // instruction in the previous basic block was a load-multiple (ldm)
-    // and included r15 as one of the loaded registers.
-    if (function == mPrevFunction) {
-        if (numInsns > 0) {
-            // If this is the beginning of the function and the previous
-            // instruction was not a branch, then it's a PUSH.
-            if (offset == 0 && op != OP_B && op != OP_THUMB_B)
-                return PUSH;
-
-            // If the previous instruction was an ldm that loaded r15,
-            // then it's a POP.
-            if (offset != 0 && ((op == OP_LDM && (insn & 0x8000))
-                                || (op == OP_THUMB_POP && (insn & 0x100)))) {
-                return POP;
-            }
-        }
-
-        return NONE;
-    }
-
-    // We have to figure out if this new function is a call or a
-    // return.  We don't necessarily have a complete call stack (since
-    // we could have started tracing at any point), so we have to use
-    // heuristics.  If the address we are jumping to is the beginning
-    // of a function, or if the instruction that took us there was
-    // either "bl" or "blx" then this is a PUSH.  Also, if the
-    // function offset is non-zero and the previous instruction is a
-    // branch instruction, we will call it a PUSH.  This happens in
-    // the kernel a lot when there is a branch to an offset from a
-    // label. A couple more special cases:
-    //
-    //   - entering a .plt section ("procedure linkage table") is a PUSH,
-    //   - an exception that jumps into the kernel vector entry point
-    //     is also a push.
-    // 
-    // If the function offset is non-zero and the previous instruction
-    // is a bx or some non-branch instruction, then it's a POP.
-    //
-    // There's another special case that comes up.  The user code
-    // might execute an instruction that returns but before the pc
-    // starts executing in the caller, a kernel interrupt occurs.
-    // But it may be hard to tell if this is a return until after
-    // the kernel interrupt code is done and returns to user space.
-    // So we save the last user basic block and look at it when
-    // we come back into user space.
-
-    const uint32_t kIsKernelRegion = region_type::kIsKernelRegion;
-
-    if (((mPrevFunction->region->flags & kIsKernelRegion) == 0)
-        && (function->region->flags & kIsKernelRegion)) {
-        // We just switched into the kernel.  Save the previous
-        // user-mode basic block and function.
-        mUserEvent = mPrevEvent;
-        mUserFunction = mPrevFunction;
-    } else if ((mPrevFunction->region->flags & kIsKernelRegion)
-               && ((function->region->flags & kIsKernelRegion) == 0)) {
-        // We just switched from kernel to user mode.
-        return POP;
-    }
-
-    action = PUSH;
-    if (offset != 0 && mPrevFunction != &mDummyFunction) {
-        // We are jumping into the middle of a function, so this is
-        // probably a return, not a function call.  But look at the
-        // previous instruction first to see if it was a branch-and-link.
-
-        // If the previous instruction was not a branch (and not a
-        // branch-and-link) then POP; or if it is a "bx" instruction
-        // then POP because that is used to return from functions.
-        if (!isBranch(op) || op == OP_BX || op == OP_THUMB_BX) {
-            action = POP;
-        } else if (isBranch(op) && !isBranchLink(op)) {
-            // If the previous instruction was a normal branch to a
-            // local symbol then don't count it as a push or a pop.
-            action = NONE;
-        }
-
-        if (function->flags & symbol_type::kIsVectorTable)
-            action = PUSH;
-    }
-    return action;
-}
-
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::doPush(BBEvent *event, symbol_type *function)
-{
-    uint64_t time = event->time - mSkippedTime;
-
-    // Check for stack overflow
-    if (mTop >= mNumFrames) {
-#if 0
-        showStack();
-#endif
-        fprintf(stderr, "Error: stack overflow (%d frames)\n", mTop);
-        exit(1);
-    }
-
-    // Compute the return address here because we may need to change
-    // it if we are popping off a frame for a vector table.
-    int numBytes;
-    if (mPrevEvent.is_thumb) {
-        numBytes = mPrevEvent.num_insns << 1;
-    } else {
-        numBytes = mPrevEvent.num_insns << 2;
-    }
-    uint32_t retAddr = mPrevEvent.bb_addr + numBytes;
-
-    // If this is a Java method then set the return address to zero.
-    // We won't be using it for popping the method and it may lead
-    // to false matches when searching the stack.
-    if (function->vm_sym != NULL) {
-        retAddr = 0;
-    }
-
-#if 0
-    if (function->flags & symbol_type::kIsVectorStart) {
-        printf("stack before entering exception\n");
-        showStack();
-    }
-#endif
-
-    // If the previous function was a vector table, then pop it
-    // off before pushing on the new function.  Also, change the
-    // return address for the new function to the return address
-    // from the vector table.
-    if ((mPrevFunction->flags & symbol_type::kIsVectorTable) && mTop > 0) {
-        retAddr = mFrames[mTop - 1].addr;
-        doSimplePop(time);
-    }
-
-    const uint32_t kIsKernelRegion = region_type::kIsKernelRegion;
-
-    // The following code handles the case where one function, F1,
-    // calls another function, F2, but the before F2 can start
-    // executing, it takes a page fault (on the first instruction
-    // in F2).  The kernel is entered, handles the page fault, and
-    // then returns to the called function.  The problem is that
-    // this looks like a new function call to F2 from the kernel.
-    // The following code cleans up the stack by popping the
-    // kernel frames back to F1 (but not including F1).  The
-    // return address for F2 also has to be fixed up to point to
-    // F1 instead of the kernel.
-    //
-    // We detect this case by checking if the previous basic block
-    // was in the kernel and the current basic block is not.
-    if ((mPrevFunction->region->flags & kIsKernelRegion)
-        && ((function->region->flags & kIsKernelRegion) == 0)
-        && mTop > 0) {
-        // We are switching from kernel mode to user mode.
-#if 0
-        printf("  doPush(): popping to user mode, bb_addr: 0x%08x\n",
-               event->bb_addr);
-        showStack();
-#endif
-        do {
-            // Pop off the kernel frames until we reach the one that
-            // caused the exception.
-            doSimplePop(time);
-
-            // If the next stack frame is the one that caused an
-            // exception then stop popping frames.
-            if (mTop > 0
-                && (mFrames[mTop - 1].flags & FRAME::kCausedException)) {
-                mFrames[mTop - 1].flags &= ~FRAME::kCausedException;
-                retAddr = mFrames[mTop].addr;
-                break;
-            }
-        } while (mTop > 0);
-#if 0
-        printf("  doPush() popping to level %d, using retAddr 0x%08x\n",
-               mTop, retAddr);
-#endif
-    }
-
-    // If we are starting an exception handler, then mark the previous
-    // stack frame so that we know where to return when the exception
-    // handler finishes.
-    if ((function->flags & symbol_type::kIsVectorStart) && mTop > 0)
-        mFrames[mTop - 1].flags |= FRAME::kCausedException;
-
-    doSimplePush(function, retAddr, time);
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::doSimplePush(symbol_type *function,
-                                          uint32_t addr, uint64_t time)
-{
-    // Check for stack overflow
-    if (mTop >= mNumFrames) {
-        showStack();
-        fprintf(stderr, "too many stack frames (%d)\n", mTop);
-        exit(1);
-    }
-
-    // Keep track of the number of Java methods we push on the stack.
-    if (!mNativeOnly && function->vm_sym != NULL) {
-        // If we are pushing the first Java method on the stack, then
-        // save a snapshot of the stack so that we can clean things up
-        // later when we pop off the last Java stack frame.
-        if (mJavaTop == 0) {
-            transitionToJava();
-        }
-        mJavaTop += 1;
-    }
-
-    mFrames[mTop].addr = addr;
-    mFrames[mTop].function = function;
-    mFrames[mTop].flags = 0;
-    mFrames[mTop].time = time;
-    mFrames[mTop].global_time = time + mSkippedTime;
-
-    // If the function being pushed is a Java method, then mark it on
-    // the stack so that we don't pop it off until we get a matching
-    // trace record from the method trace file.
-    if (function->vm_sym != NULL) {
-        mFrames[mTop].flags = FRAME::kInterpreted;
-    }
-
-    mFrames[mTop].push(mTop, time, this);
-    mTop += 1;
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::doSimplePop(uint64_t time)
-{
-    if (mTop <= 0) {
-        return;
-    }
-
-    mTop -= 1;
-    mFrames[mTop].pop(mTop, time, this);
-
-    // Keep track of the number of Java methods we have on the stack.
-    symbol_type *function = mFrames[mTop].function;
-    if (!mNativeOnly && function->vm_sym != NULL) {
-        mJavaTop -= 1;
-
-        // When there are no more Java stack frames, then clean up
-        // the client's stack.  We need to do this because the client
-        // doesn't see the changes to the native stack underlying the
-        // fake Java stack until the last Java method is popped off.
-        if (mJavaTop == 0) {
-            transitionFromJava(time);
-        }
-    }
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::doPop(BBEvent *event, symbol_type *function,
-                                   Action methodAction)
-{
-    uint64_t time = event->time - mSkippedTime;
-
-    // Search backward on the stack for a matching return address.
-    // The most common case is that we pop one stack frame, but
-    // sometimes we pop more than one.
-    int stackLevel;
-    bool allowMethodPop = (methodAction == POP);
-    for (stackLevel = mTop - 1; stackLevel >= 0; --stackLevel) {
-        if (event->bb_addr == mFrames[stackLevel].addr) {
-            // We found a matching return address on the stack.
-            break;
-        }
-
-        // If this stack frame caused an exception, then do not pop
-        // this stack frame.
-        if (mFrames[stackLevel].flags & FRAME::kPopBarrier) {
-            // If this is a Java method, then allow a pop only if we
-            // have a matching trace record.
-            if (mFrames[stackLevel].flags & FRAME::kInterpreted) {
-                if (allowMethodPop) {
-                    // Allow at most one method pop
-                    allowMethodPop = false;
-                    continue;
-                }
-            }
-            stackLevel += 1;
-            break;
-        }
-    }
-
-    // If we didn't find a matching return address then search the stack
-    // again for a matching function.
-    if (stackLevel < 0 || event->bb_addr != mFrames[stackLevel].addr) {
-        bool allowMethodPop = (methodAction == POP);
-        for (stackLevel = mTop - 1; stackLevel >= 0; --stackLevel) {
-            // Compare the function with the one in the stack frame.
-            if (function == mFrames[stackLevel].function) {
-                // We found a matching function.  We want to pop up to but not
-                // including this frame.
-                stackLevel += 1;
-                break;
-            }
-
-            // If this stack frame caused an exception, then do not pop
-            // this stack frame.
-            if (mFrames[stackLevel].flags & FRAME::kPopBarrier) {
-                // If this is a Java method, then allow a pop only if we
-                // have a matching trace record.
-                if (mFrames[stackLevel].flags & FRAME::kInterpreted) {
-                    if (allowMethodPop) {
-                        // Allow at most one method pop
-                        allowMethodPop = false;
-                        continue;
-                    }
-                }
-                stackLevel += 1;
-                break;
-            }
-        }
-        if (stackLevel < 0)
-            stackLevel = 0;
-    }
-
-    // Note that if we didn't find a matching stack frame, we will pop
-    // the whole stack (unless there is a Java method or exception
-    // frame on the stack).  This is intentional because we may have
-    // started the trace in the middle of an executing program that is
-    // returning up the stack and we do not know the whole stack.  So
-    // the right thing to do is to empty the stack.
-
-    // If we are emptying the stack, then add the current function
-    // on top.  If the current function is the same as the top of
-    // stack, then avoid an extraneous pop and push.
-    if (stackLevel == 0 && mFrames[0].function == function)
-        stackLevel = 1;
-
-#if 0
-    if (mTop - stackLevel > 7) {
-        printf("popping thru level %d\n", stackLevel);
-        showStack();
-    }
-#endif
-
-    // Pop the stack frames
-    for (int ii = mTop - 1; ii >= stackLevel; --ii)
-        doSimplePop(time);
-
-    // Clear the "caused exception" bit on the current stack frame
-    if (mTop > 0) {
-        mFrames[mTop - 1].flags &= ~FRAME::kCausedException;
-    }
-
-    // Also handle the case where F1 calls F2 and F2 returns to
-    // F1, but before we can execute any instructions in F1, we
-    // switch to the kernel.  Then when we return from the kernel
-    // we want to pop off F2 from the stack instead of pushing F1
-    // on top of F2.  To handle this case, we saved the last
-    // user-mode basic block when we entered the kernel (in
-    // the getAction() function) and now we can check to see if
-    // that was a return to F1 instead of a call.  We use the
-    // getAction() function to determine this.
-    const uint32_t kIsKernelRegion = region_type::kIsKernelRegion;
-    if ((mPrevFunction->region->flags & kIsKernelRegion)
-        && ((function->region->flags & kIsKernelRegion) == 0)) {
-        mPrevEvent = mUserEvent;
-        mPrevFunction = mUserFunction;
-        if (getAction(event, function) == POP) {
-            // We may need to pop more than one frame, so just
-            // call doPop() again.  This won't be an infinite loop
-            // here because we changed mPrevEvent to the last
-            // user-mode event.
-            doPop(event, function, methodAction);
-            return;
-        }
-    }
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::popAll(uint64_t time)
-{
-    time -= mSkippedTime;
-    while (mTop != 0) {
-        doSimplePop(time);
-    }
-}
-
-template<class FRAME, class BASE>
-typename CallStack<FRAME, BASE>::Action
-CallStack<FRAME, BASE>::getMethodAction(BBEvent *event, symbol_type *function)
-{
-    if (function->vm_sym == NULL && mPrevFunction->vm_sym == NULL) {
-        return NONE;
-    }
-
-    Action action = NONE;
-    uint32_t prevAddr = mPrevFunction->addr + mPrevFunction->region->base_addr;
-    uint32_t addr = function->addr + function->region->base_addr;
-
-    // If the events get ahead of the method trace, then read ahead until we
-    // sync up again.  This can happen if there is a pop of a method in the
-    // method trace for which we don't have a previous push.
-    while (event->time >= sNextMethod.time) {
-        sCurrentMethod = sNextMethod;
-        if (mTrace->ReadMethod(&sNextMethod)) {
-            sNextMethod.time = ~0ull;
-        }
-    }
-
-    if (event->time >= sCurrentMethod.time) {
-        if (addr == sCurrentMethod.addr || prevAddr == sCurrentMethod.addr) {
-            action = (sCurrentMethod.flags == 0) ? PUSH : POP;
-            // We found a match, so read the next record.
-            sCurrentMethod = sNextMethod;
-            if (sNextMethod.time != ~0ull && mTrace->ReadMethod(&sNextMethod)) {
-                sNextMethod.time = ~0ull;
-            }
-        }
-    }
-    return action;
-}
-
-// When the first Java method is pushed on the stack, this method is
-// called to save a snapshot of the current native stack so that the
-// client's view of the native stack can be patched up later when the
-// Java stack is empty.
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::transitionToJava()
-{
-    mSnapshotTop = mTop;
-    for (int ii = 0; ii < mTop; ++ii) {
-        mSnapshotFrames[ii] = mFrames[ii];
-    }
-}
-
-// When the Java stack becomes empty, the native stack becomes
-// visible.  This method is called when the Java stack becomes empty
-// to patch up the client's view of the native stack, which may have
-// changed underneath the Java stack.  The stack snapshot is used to
-// create a sequence of pops and pushes to make the client's view of
-// the native stack match the current native stack.
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::transitionFromJava(uint64_t time)
-{
-    int top = mTop;
-    if (top > mSnapshotTop) {
-        top = mSnapshotTop;
-    }
-    for (int ii = 0; ii < top; ++ii) {
-        if (mSnapshotFrames[ii].function->addr == mFrames[ii].function->addr) {
-            continue;
-        }
-
-        // Pop off all the rest of the frames from the snapshot
-        for (int jj = top - 1; jj >= ii; --jj) {
-            mSnapshotFrames[jj].pop(jj, time, this);
-        }
-
-        // Push the new frames from the native stack
-        for (int jj = ii; jj < mTop; ++jj) {
-            mFrames[jj].push(jj, time, this);
-        }
-        break;
-    }
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::showStack()
-{
-    fprintf(stderr, "mTop: %d skippedTime: %llu\n", mTop, mSkippedTime);
-    for (int ii = 0; ii < mTop; ++ii) {
-        fprintf(stderr, "  %d: t %d gt %d f %x 0x%08x 0x%08x %s\n",
-                ii, mFrames[ii].time, mFrames[ii].global_time,
-                mFrames[ii].flags,
-                mFrames[ii].addr, mFrames[ii].function->addr,
-                mFrames[ii].function->name);
-    }
-}
-
-template<class FRAME, class BASE>
-void CallStack<FRAME, BASE>::showSnapshotStack()
-{
-    fprintf(stderr, "mSnapshotTop: %d\n", mSnapshotTop);
-    for (int ii = 0; ii < mSnapshotTop; ++ii) {
-        fprintf(stderr, "  %d: t %d f %x 0x%08x 0x%08x %s\n",
-                ii, mSnapshotFrames[ii].time, mSnapshotFrames[ii].flags,
-                mSnapshotFrames[ii].addr, mSnapshotFrames[ii].function->addr,
-                mSnapshotFrames[ii].function->name);
-    }
-}
-
-#endif /* CALL_STACK_H */
diff --git a/emulator/qtools/check_trace.cpp b/emulator/qtools/check_trace.cpp
deleted file mode 100644
index d933a87..0000000
--- a/emulator/qtools/check_trace.cpp
+++ /dev/null
@@ -1,61 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "armdis.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-static const uint32_t kOffsetThreshold = 0x100000;
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_file elf_file\n", program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv) {
-    // Parse the options
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<> *trace = new TraceReader<>;
-    trace->Open(trace_filename);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    while (1) {
-        symbol_type *sym;
-        BBEvent event;
-        BBEvent ignored;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &sym))
-            break;
-        if (event.bb_num == 0)
-            break;
-        //printf("t%llu bb %lld %d\n", event.time, event.bb_num, event.num_insns);
-        uint64_t insn_time = trace->ReadInsnTime(event.time);
-        if (insn_time != event.time) {
-            printf("time: %llu insn time: %llu bb: %llu addr: 0x%x num_insns: %d, pid: %d\n",
-                   event.time, insn_time, event.bb_num, event.bb_addr,
-                   event.num_insns, event.pid);
-            exit(1);
-        }
-        for (int ii = 1; ii < event.num_insns; ++ii) {
-            trace->ReadInsnTime(event.time);
-        }
-    }
-
-    delete trace;
-    return 0;
-}
diff --git a/emulator/qtools/coverage.cpp b/emulator/qtools/coverage.cpp
deleted file mode 100644
index fb1fe52..0000000
--- a/emulator/qtools/coverage.cpp
+++ /dev/null
@@ -1,153 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <string.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-#include "opcode.h"
-
-const int kMillion = 1000000;
-const int kMHz = 200 * kMillion;
-
-struct symbol {
-    int    numCalls;    // number of times this function is called
-};
-
-typedef TraceReader<symbol> TraceReaderType;
-
-#include "parse_options-inl.h"
-#include "callstack.h"
-
-class MyFrame : public StackFrame<symbol_type> {
-  public:
-    void    push(int stackLevel, uint64_t time, CallStackBase *base) {
-        function->numCalls += 1;
-    }
-    void    pop(int stackLevel, uint64_t time, CallStackBase *base) {
-    }
-};
-
-typedef CallStack<MyFrame> CallStackType;
-
-static const int kNumStackFrames = 500;
-static const int kMaxThreads = (32 * 1024);
-CallStackType *stacks[kMaxThreads];
-
-// This comparison function is called from qsort() to sort symbols
-// into decreasing number of calls.
-int cmp_sym_calls(const void *a, const void *b) {
-    const symbol_type *syma, *symb;
-    uint64_t calls1, calls2;
-
-    syma = static_cast<symbol_type const *>(a);
-    symb = static_cast<symbol_type const *>(b);
-    calls1 = syma->numCalls;
-    calls2 = symb->numCalls;
-    if (calls1 < calls2)
-        return 1;
-    if (calls1 == calls2) {
-        int cmp = strcmp(syma->name, symb->name);
-        if (cmp == 0)
-            cmp = strcmp(syma->region->path, symb->region->path);
-        return cmp;
-    }
-    return -1;
-}
-
-// This comparison function is called from qsort() to sort symbols
-// into alphabetical order.
-int cmp_sym_names(const void *a, const void *b) {
-    const symbol_type *syma, *symb;
-
-    syma = static_cast<symbol_type const *>(a);
-    symb = static_cast<symbol_type const *>(b);
-    int cmp = strcmp(syma->region->path, symb->region->path);
-    if (cmp == 0)
-        cmp = strcmp(syma->name, symb->name);
-    return cmp;
-}
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_file elf_file\n", program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv)
-{
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<symbol> *trace = new TraceReader<symbol>;
-    trace->Open(trace_filename);
-    trace->SetDemangle(demangle);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    BBEvent event;
-    while (1) {
-        BBEvent ignored;
-        symbol_type *function;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &function))
-            break;
-        if (event.bb_num == 0)
-            break;
-
-        // Get the stack for the current thread
-        CallStackType *pStack = stacks[event.pid];
-
-        // If the stack does not exist, then allocate a new one.
-        if (pStack == NULL) {
-            pStack = new CallStackType(event.pid, kNumStackFrames, trace);
-            stacks[event.pid] = pStack;
-        }
-
-        // Update the stack
-        pStack->updateStack(&event, function);
-    }
-
-    for (int ii = 0; ii < kMaxThreads; ++ii) {
-        if (stacks[ii])
-            stacks[ii]->popAll(event.time);
-    }
-
-    int nsyms;
-    symbol_type *syms = trace->GetSymbols(&nsyms);
-
-    // Sort the symbols into decreasing number of calls
-    qsort(syms, nsyms, sizeof(symbol_type), cmp_sym_names);
-
-    symbol_type *psym = syms;
-    for (int ii = 0; ii < nsyms; ++ii, ++psym) {
-        // Ignore functions with non-zero calls
-        if (psym->numCalls)
-            continue;
-
-        // Ignore some symbols
-        if (strcmp(psym->name, "(end)") == 0)
-            continue;
-        if (strcmp(psym->name, "(unknown)") == 0)
-            continue;
-        if (strcmp(psym->name, ".plt") == 0)
-            continue;
-        char *ksym = " ";
-        if (psym->region->flags & region_type::kIsKernelRegion)
-            ksym = "k";
-        printf("%s %s %s\n", ksym, psym->name, psym->region->path);
-#if 0
-        printf("#%d %5d %s %s %s\n", ii + 1, psym->numCalls, ksym, psym->name,
-               psym->region->path);
-#endif
-    }
-    delete[] syms;
-    delete trace;
-
-    return 0;
-}
diff --git a/emulator/qtools/decoder.cpp b/emulator/qtools/decoder.cpp
deleted file mode 100644
index ec53181..0000000
--- a/emulator/qtools/decoder.cpp
+++ /dev/null
@@ -1,278 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <assert.h>
-#include "decoder.h"
-#include "trace_common.h"
-
-// This array provides a fast conversion from the initial byte in
-// a varint-encoded object to the length (in bytes) of that object.
-int prefix_to_len[] = {
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-    2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-    2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-    2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-    2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-    3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
-    3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
-    4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
-    5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 9, 9, 17, 17
-};
-
-// This array provides a fast conversion from the initial byte in
-// a varint-encoded object to the initial data bits for that object.
-int prefix_to_data[] = {
-    0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-    16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
-    32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
-    48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
-    64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
-    80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
-    96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
-    112, 113, 114, 115, 116, 117, 118, 119,
-    120, 121, 122, 123, 124, 125, 126, 127,
-    0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-    16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
-    32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
-    48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
-    0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-    16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
-    0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
-    0, 1, 2, 3, 4, 5, 6, 7, 0, 1, 2, 3, 0, 0, 0, 0
-};
-
-signed char prefix_to_signed_data[] = {
-    0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-    0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
-    0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
-    0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f,
-    0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27,
-    0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f,
-    0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37,
-    0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f,
-    0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7,
-    0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf,
-    0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7,
-    0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf,
-    0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7,
-    0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef,
-    0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7,
-    0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff,
-    0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-    0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
-    0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
-    0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f,
-    0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7,
-    0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef,
-    0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7,
-    0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff,
-    0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-    0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
-    0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7,
-    0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff,
-    0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
-    0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff,
-    0x00, 0x01, 0x02, 0x03, 0xfc, 0xfd, 0xfe, 0xff,
-    0x00, 0x01, 0xfe, 0xff, 0x00, 0xff, 0x00, 0xff,
-};
-
-Decoder::Decoder()
-{
-    filename_ = NULL;
-    fstream_ = NULL;
-    next_ = NULL;
-    end_ = NULL;
-}
-
-Decoder::~Decoder()
-{
-    Close();
-    delete[] filename_;
-}
-
-void Decoder::Close()
-{
-    if (fstream_) {
-        fclose(fstream_);
-        fstream_ = NULL;
-    }
-}
-
-void Decoder::Open(char *filename)
-{
-    if (filename_ != NULL) {
-        delete[] filename_;
-    }
-    filename_ = new char[strlen(filename) + 1];
-    strcpy(filename_, filename);
-    fstream_ = fopen(filename_, "r");
-    if (fstream_ == NULL) {
-        perror(filename_);
-        exit(1);
-    }
-
-    int rval = fread(buf_, 1, kBufSize, fstream_);
-    if (rval != kBufSize) {
-        if (ferror(fstream_)) {
-            perror(filename_);
-            exit(1);
-        }
-        if (!feof(fstream_)) {
-            fprintf(stderr, "Unexpected short fread() before eof\n");
-            exit(1);
-        }
-    }
-    next_ = buf_;
-    end_ = buf_ + rval;
-}
-
-void Decoder::FillBuffer()
-{
-    assert(next_ <= end_);
-  
-    if (end_ - next_ < kDecodingSpace && end_ == &buf_[kBufSize]) {
-        // Copy the unused bytes left at the end to the beginning of the
-        // buffer.
-        int len = end_ - next_;
-        if (len > 0)
-            memcpy(buf_, next_, len);
-
-        // Read enough bytes to fill up the buffer, if possible.
-        int nbytes = kBufSize - len;
-        int rval = fread(buf_ + len, 1, nbytes, fstream_);
-        if (rval < nbytes) {
-            if (ferror(fstream_)) {
-                perror(filename_);
-                exit(1);
-            }
-            if (!feof(fstream_)) {
-                fprintf(stderr, "Unexpected short fread() before eof\n");
-                exit(1);
-            }
-        }
-        end_ = &buf_[len + rval];
-        next_ = buf_;
-    }
-}
-
-void Decoder::Read(char *dest, int len)
-{
-    while (len > 0) {
-        int nbytes = end_ - next_;
-        if (nbytes == 0) {
-            FillBuffer();
-            nbytes = end_ - next_;
-            if (nbytes == 0)
-                break;
-        }
-        if (nbytes > len)
-            nbytes = len;
-        memcpy(dest, next_, nbytes);
-        dest += nbytes;
-        len -= nbytes;
-        next_ += nbytes;
-    }
-}
-
-// Decode a varint-encoded object starting at the current position in
-// the array "buf_" and return the decoded value as a 64-bit integer.
-// A varint-encoded object has an initial prefix that specifies how many
-// data bits follow.  If the first bit is zero, for example, then there
-// are 7 data bits that follow.  The table below shows the prefix values
-// and corresponding data bits.
-//
-// Prefix     Bytes  Data bits
-// 0          1      7
-// 10         2      14
-// 110        3      21
-// 1110       4      28
-// 11110      5      35
-// 111110     6      42
-// 11111100   9      64
-// 11111101   reserved
-// 11111110   reserved
-// 11111111   reserved
-int64_t Decoder::Decode(bool is_signed)
-{
-    int64_t val64;
-
-    if (end_ - next_ < kDecodingSpace)
-        FillBuffer();
-
-#if BYTE_ORDER == BIG_ENDIAN
-    uint8_t byte0 = *next_;
-
-    // Get the number of bytes to decode based on the first byte.
-    int len = prefix_to_len[byte0];
-
-    if (next_ + len > end_) {
-        fprintf(stderr, "%s: decoding past end of file.\n", filename_);
-        exit(1);
-    }
-
-    // Get the first data byte.
-    if (is_signed)
-        val64 = prefix_to_signed_data[byte0];
-    else
-        val64 = prefix_to_data[byte0];
-
-    next_ += 1;
-    for (int ii = 1; ii < len; ++ii) {
-        val64 = (val64 << 8) | *next_++;
-    }
-#else
-    // If we are on a little-endian machine, then use large, unaligned loads.
-    uint64_t data = *(reinterpret_cast<uint64_t*>(next_));
-    uint8_t byte0 = data;
-    data = bswap64(data);
-
-    // Get the number of bytes to decode based on the first byte.
-    int len = prefix_to_len[byte0];
-
-    if (next_ + len > end_) {
-        fprintf(stderr, "%s: decoding past end of file.\n", filename_);
-        exit(1);
-    }
-
-    // Get the first data byte.
-    if (is_signed)
-        val64 = prefix_to_signed_data[byte0];
-    else
-        val64 = prefix_to_data[byte0];
-
-    switch (len) {
-        case 1:
-            break;
-        case 2:
-            val64 = (val64 << 8) | ((data >> 48) & 0xffull);
-            break;
-        case 3:
-            val64 = (val64 << 16) | ((data >> 40) & 0xffffull);
-            break;
-        case 4:
-            val64 = (val64 << 24) | ((data >> 32) & 0xffffffull);
-            break;
-        case 5:
-            val64 = (val64 << 32) | ((data >> 24) & 0xffffffffull);
-            break;
-        case 6:
-            val64 = (val64 << 40) | ((data >> 16) & 0xffffffffffull);
-            break;
-        case 9:
-            data = *(reinterpret_cast<uint64_t*>(&next_[1]));
-            val64 = bswap64(data);
-            break;
-    }
-    next_ += len;
-#endif
-    return val64;
-}
diff --git a/emulator/qtools/decoder.h b/emulator/qtools/decoder.h
deleted file mode 100644
index 44905fd..0000000
--- a/emulator/qtools/decoder.h
+++ /dev/null
@@ -1,28 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <inttypes.h>
-
-class Decoder {
- public:
-  Decoder();
-  ~Decoder();
-
-  void          Open(char *filename);
-  void          Close();
-  int64_t       Decode(bool is_signed);
-  void          Read(char *dest, int len);
-  bool          IsEOF()          { return (end_ == next_) && feof(fstream_); }
-
- private:
-  static const int kBufSize = 4096;
-  static const int kDecodingSpace = 9;
-
-  void          FillBuffer();
-
-  char          *filename_;
-  FILE          *fstream_;
-  uint8_t       buf_[kBufSize];
-  uint8_t       *next_;
-  uint8_t       *end_;
-};
diff --git a/emulator/qtools/dmtrace.cpp b/emulator/qtools/dmtrace.cpp
deleted file mode 100644
index 6d9250a..0000000
--- a/emulator/qtools/dmtrace.cpp
+++ /dev/null
@@ -1,254 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-#include <inttypes.h>
-#include <string.h>
-#include "dmtrace.h"
-
-static const short kVersion = 2;
-
-const DmTrace::Header DmTrace::header = {
-    0x574f4c53, kVersion, sizeof(DmTrace::Header), 0LL
-};
-
-static char *keyHeader = "*version\n" "2\n" "clock=thread-cpu\n";
-static char *keyThreadHeader = "*threads\n";
-static char *keyFunctionHeader = "*methods\n";
-static char *keyEnd = "*end\n";
-
-DmTrace::DmTrace() {
-    fData = NULL;
-    fTrace = NULL;
-    threads = new std::vector<ThreadRecord*>;
-    functions = new std::vector<FunctionRecord*>;
-}
-
-DmTrace::~DmTrace() {
-    delete threads;
-    delete functions;
-}
-
-void DmTrace::open(const char *dmtrace_file, uint64_t start_time)
-{
-    fTrace = fopen(dmtrace_file, "w");
-    if (fTrace == NULL) {
-        perror(dmtrace_file);
-        exit(1);
-    }
-
-    // Make a temporary file to write the data into.
-    char tmpData[32];
-    strcpy(tmpData, "/tmp/dmtrace-data-XXXXXX");
-    int data_fd = mkstemp(tmpData);
-    if (data_fd < 0) {
-        perror("Cannot create temporary file");
-        exit(1);
-    }
-
-    // Ensure it goes away on exit.
-    unlink(tmpData);
-    fData = fdopen(data_fd, "w+");
-    if (fData == NULL) {
-        perror("Can't make temp data file");
-        exit(1);
-    }
-
-    writeHeader(fData, start_time);
-}
-
-void DmTrace::close()
-{
-    if (fTrace == NULL)
-        return;
-    writeKeyFile(fTrace);
-
-    // Take down how much data we wrote to the temp data file.
-    long size = ftell(fData);
-    // Rewind the data file and append its contents to the trace file.
-    rewind(fData);
-    char *data = (char *)malloc(size);
-    fread(data, size, 1, fData);
-    fwrite(data, size, 1, fTrace);
-    free(data);
-    fclose(fData);
-    fclose(fTrace);
-}
-
-/*
- * Write values to the binary data file.
- */
-void DmTrace::write2LE(FILE* fstream, unsigned short val)
-{
-    putc(val & 0xff, fstream);
-    putc(val >> 8, fstream);
-}
-
-void DmTrace::write4LE(FILE* fstream, unsigned int val)
-{
-    putc(val & 0xff, fstream);
-    putc((val >> 8) & 0xff, fstream);
-    putc((val >> 16) & 0xff, fstream);
-    putc((val >> 24) & 0xff, fstream);
-}
-
-void DmTrace::write8LE(FILE* fstream, unsigned long long val)
-{
-    putc(val & 0xff, fstream);
-    putc((val >> 8) & 0xff, fstream);
-    putc((val >> 16) & 0xff, fstream);
-    putc((val >> 24) & 0xff, fstream);
-    putc((val >> 32) & 0xff, fstream);
-    putc((val >> 40) & 0xff, fstream);
-    putc((val >> 48) & 0xff, fstream);
-    putc((val >> 56) & 0xff, fstream);
-}
-
-void DmTrace::writeHeader(FILE *fstream, uint64_t startTime)
-{
-    write4LE(fstream, header.magic);
-    write2LE(fstream, header.version);
-    write2LE(fstream, header.offset);
-    write8LE(fstream, startTime);
-}
-
-void DmTrace::writeDataRecord(FILE *fstream, int threadId,
-                             unsigned int methodVal,
-                             unsigned int elapsedTime)
-{
-    write2LE(fstream, threadId);
-    write4LE(fstream, methodVal);
-    write4LE(fstream, elapsedTime);
-}
-
-void DmTrace::addFunctionEntry(int functionId, uint32_t cycle, uint32_t pid)
-{
-    writeDataRecord(fData, pid, functionId, cycle);
-}
-
-void DmTrace::addFunctionExit(int functionId, uint32_t cycle, uint32_t pid)
-{
-    writeDataRecord(fData, pid, functionId | 1, cycle);
-}
-
-void DmTrace::addFunction(int functionId, const char *name)
-{
-    FunctionRecord *rec = new FunctionRecord;
-    rec->id = functionId;
-    rec->name = name;
-    functions->push_back(rec);
-}
-
-void DmTrace::addFunction(int functionId, const char *clazz,
-                          const char *method, const char *sig)
-{
-    // Allocate space for all the strings, plus 2 tab separators plus null byte.
-    // We currently don't reclaim this space.
-    int len = strlen(clazz) + strlen(method) + strlen(sig) + 3;
-    char *name = new char[len];
-    sprintf(name, "%s\t%s\t%s", clazz, method, sig);
-
-    addFunction(functionId, name);
-}
-
-void DmTrace::parseAndAddFunction(int functionId, const char *name)
-{
-    // Parse the "name" string into "class", "method" and "signature".
-    // The "name" string should look something like this:
-    //   name = "java.util.LinkedList.size()I"
-    // and it will be parsed into this:
-    //   clazz = "java.util.LinkedList"
-    //   method = "size"
-    //   sig = "()I"
-
-    // Find the first parenthesis, the start of the signature.
-    char *paren = strchr(name, '(');
-
-    // If not found, then add the original name.
-    if (paren == NULL) {
-        addFunction(functionId, name);
-        return;
-    }
-
-    // Copy the signature
-    int len = strlen(paren) + 1;
-    char *sig = new char[len];
-    strcpy(sig, paren);
-
-    // Zero the parenthesis so that we can search backwards from the signature
-    *paren = 0;
-
-    // Search for the last period, the start of the method name
-    char *dot = strrchr(name, '.');
-
-    // If not found, then add the original name.
-    if (dot == NULL || dot == name) {
-        delete[] sig;
-        *paren = '(';
-        addFunction(functionId, name);
-        return;
-    }
-
-    // Copy the method, not including the dot
-    len = strlen(dot + 1) + 1;
-    char *method = new char[len];
-    strcpy(method, dot + 1);
-
-    // Zero the dot to delimit the class name
-    *dot = 0;
-
-    addFunction(functionId, name, method, sig);
-
-    // Free the space we allocated.
-    delete[] sig;
-    delete[] method;
-}
-
-void DmTrace::addThread(int threadId, const char *name)
-{
-    ThreadRecord *rec = new ThreadRecord;
-    rec->id = threadId;
-    rec->name = name;
-    threads->push_back(rec);
-}
-
-void DmTrace::updateName(int threadId, const char *name)
-{
-    std::vector<ThreadRecord*>::iterator iter;
-
-    for (iter = threads->begin(); iter != threads->end(); ++iter) {
-        if ((*iter)->id == threadId) {
-            (*iter)->name = name;
-            return;
-        }
-    }
-}
-
-void DmTrace::writeKeyFile(FILE *fstream)
-{
-    fwrite(keyHeader, strlen(keyHeader), 1, fstream);
-    writeThreads(fstream);
-    writeFunctions(fstream);
-    fwrite(keyEnd, strlen(keyEnd), 1, fstream);
-}
-
-void DmTrace::writeThreads(FILE *fstream)
-{
-    std::vector<ThreadRecord*>::iterator iter;
-
-    fwrite(keyThreadHeader, strlen(keyThreadHeader), 1, fstream);
-    for (iter = threads->begin(); iter != threads->end(); ++iter) {
-        fprintf(fstream, "%d\t%s\n", (*iter)->id, (*iter)->name);
-    }
-}
-
-void DmTrace::writeFunctions(FILE *fstream)
-{
-    std::vector<FunctionRecord*>::iterator iter;
-
-    fwrite(keyFunctionHeader, strlen(keyFunctionHeader), 1, fstream);
-    for (iter = functions->begin(); iter != functions->end(); ++iter) {
-        fprintf(fstream, "0x%x\t%s\n", (*iter)->id, (*iter)->name);
-    }
-}
diff --git a/emulator/qtools/dmtrace.h b/emulator/qtools/dmtrace.h
deleted file mode 100644
index 6e20921..0000000
--- a/emulator/qtools/dmtrace.h
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef DMTRACE_H
-#define DMTRACE_H
-
-#include <vector>
-
-class DmTrace {
-  public:
-    struct Header {
-        uint32_t        magic;
-        uint16_t        version;
-        uint16_t        offset;
-        uint64_t        date_time;
-    };
-
-    DmTrace();
-    ~DmTrace();
-
-    void        open(const char *dmtrace_file, uint64_t startTime);
-    void        close();
-    void        addFunctionEntry(int methodId, uint32_t cycle, uint32_t pid);
-    void        addFunctionExit(int methodId, uint32_t cycle, uint32_t pid);
-    void        addFunction(int functionId, const char *name);
-    void        addFunction(int functionId, const char *clazz, const char *method,
-                            const char *sig);
-    void        parseAndAddFunction(int functionId, const char *name);
-    void        addThread(int threadId, const char *name);
-    void        updateName(int threadId, const char *name);
-
-  private:
-    static const Header header;
-
-    struct ThreadRecord {
-        int             id;
-        const char      *name;
-    };
-
-    struct FunctionRecord {
-        int             id;
-        const char      *name;
-    };
-
-    void        write2LE(FILE* fstream, unsigned short val);
-    void        write4LE(FILE* fstream, unsigned int val);
-    void        write8LE(FILE* fstream, unsigned long long val);
-    void        writeHeader(FILE *fstream, uint64_t startTime);
-    void        writeDataRecord(FILE *fstream, int threadId,
-                                unsigned int methodVal,
-                                unsigned int elapsedTime);
-    void        writeKeyFile(FILE *fstream);
-    void        writeThreads(FILE *fstream);
-    void        writeFunctions(FILE *fstream);
-
-    FILE        *fData;
-    FILE        *fTrace;
-    std::vector<ThreadRecord*> *threads;
-    std::vector<FunctionRecord*> *functions;
-};
-
-#endif  // DMTRACE_H
diff --git a/emulator/qtools/exc_dump.cpp b/emulator/qtools/exc_dump.cpp
deleted file mode 100644
index 166586f..0000000
--- a/emulator/qtools/exc_dump.cpp
+++ /dev/null
@@ -1,28 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "trace_reader_base.h"
-
-int main(int argc, char **argv) {
-    if (argc != 2) {
-        fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[1];
-    TraceReaderBase *trace = new TraceReaderBase;
-    trace->Open(trace_filename);
-
-    while (1) {
-        uint64_t time, recnum, bb_num, bb_start_time;
-        uint32_t pc, target_pc;
-        int num_insns;
-
-        if (trace->ReadExc(&time, &pc, &recnum, &target_pc, &bb_num,
-                           &bb_start_time, &num_insns))
-            break;
-        printf("time: %lld rec: %llu pc: %08x target: %08x bb: %llu bb_start: %llu insns: %d\n",
-               time, recnum, pc, target_pc, bb_num, bb_start_time, num_insns);
-    }
-    return 0;
-}
diff --git a/emulator/qtools/gtrace.cpp b/emulator/qtools/gtrace.cpp
deleted file mode 100644
index 673d8a4..0000000
--- a/emulator/qtools/gtrace.cpp
+++ /dev/null
@@ -1,152 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "gtrace.h"
-
-// A buffer of zeros
-static char zeros[Gtrace::kGtraceEntriesPerBlock * sizeof(Gtrace::trace_entry)];
-
-Gtrace::Gtrace() {
-  gtrace_file_ = NULL;
-  ftrace_ = NULL;
-  fnames_ = NULL;
-  start_sec_ = 0;
-  pdate_ = 0;
-  ptime_ = 0;
-  num_entries_ = 0;
-  blockno_ = 1;
-  current_pid_ = 0;
-}
-
-Gtrace::~Gtrace() {
-  if (ftrace_) {
-    // Extend the trace file to a multiple of 8k. Otherwise gtracepost64
-    // complains.
-    long pos = ftell(ftrace_);
-    long pos_end = (pos + 0x1fff) & ~0x1fff;
-    if (pos_end > pos) {
-      char ch = 0;
-      fseek(ftrace_, pos_end - 1, SEEK_SET);
-      fwrite(&ch, 1, 1, ftrace_);
-    }
-    fclose(ftrace_);
-  }
-  if (fnames_)
-    fclose(fnames_);
-}
-
-void Gtrace::Open(const char *gtrace_file, uint32_t pdate, uint32_t ptime)
-{
-  ftrace_ = fopen(gtrace_file, "w");
-  if (ftrace_ == NULL) {
-    perror(gtrace_file);
-    exit(1);
-  }
-  gtrace_file_ = gtrace_file;
-
-  pdate_ = pdate;
-  ptime_ = ptime;
-  sprintf(gname_file_, "gname_%x_%06x.txt", pdate, ptime);
-  fnames_ = fopen(gname_file_, "w");
-  if (fnames_ == NULL) {
-    perror(gname_file_);
-    exit(1);
-  }
-  fprintf(fnames_, "# File# Proc# Line# Name\n");
-}
-
-void Gtrace::WriteFirstHeader(uint32_t start_sec, uint32_t pid)
-{
-  first_header fh;
-  current_pid_ = pid;
-  start_sec_ = start_sec;
-  FillFirstHeader(start_sec, pid, &fh);
-  fwrite(&fh, sizeof(fh), 1, ftrace_);
-  num_entries_ = 8;
-}
-
-void Gtrace::FillFirstHeader(uint32_t start_sec, uint32_t pid,
-                             first_header *fh) {
-  int cpu = 0;
-  int max_files = 16;
-  int max_procedures = 12;
-
-  fh->common.blockno = 0;
-  fh->common.entry_width = 8;
-  fh->common.block_tic = kBaseTic;
-  fh->common.block_time = start_sec;
-  //fh->common.usec_cpu = (start_usec << 8) | (cpu & 0xff);
-  fh->common.usec_cpu = cpu & 0xff;
-  fh->common.pid = pid;
-  fh->common.bug_count = 0;
-  fh->common.zero_count = 0;
-
-  fh->tic = kBaseTic + 1;
-  fh->one = 1;
-  fh->tics_per_second = kTicsPerSecond;
-  fh->trace_time = start_sec;
-  fh->version = 5;
-  fh->file_proc = (max_files << 8) | max_procedures;
-  fh->pdate = pdate_;
-  fh->ptime = ptime_;
-}
-
-void Gtrace::WriteBlockHeader(uint32_t cycle, uint32_t pid)
-{
-  int cpu = 0;
-  block_header bh;
-
-  bh.blockno = blockno_++;
-  bh.entry_width = 8;
-  bh.block_tic = cycle + kBaseTic;
-  bh.block_time = start_sec_ + cycle / kTicsPerSecond;
-  //bh.usec_cpu = (start_usec << 8) | (cpu & 0xff);
-  bh.usec_cpu = cpu & 0xff;
-  bh.pid = pid;
-  bh.bug_count = 0;
-  bh.zero_count = 0;
-  fwrite(&bh, sizeof(bh), 1, ftrace_);
-}
-
-void Gtrace::AddGtraceRecord(int filenum, int procnum, uint32_t cycle, uint32_t pid,
-                             int is_exit)
-{
-  trace_entry	entry;
-
-  if (current_pid_ != pid) {
-    current_pid_ = pid;
-
-    // We are switching to a new process id, so pad the current block
-    // with zeros.
-    int num_zeros = (kGtraceEntriesPerBlock - num_entries_) * sizeof(entry);
-    fwrite(zeros, num_zeros, 1, ftrace_);
-    WriteBlockHeader(cycle, pid);
-    num_entries_ = 4;
-  }
-
-  // If the current block is full, write out a new block header
-  if (num_entries_ == kGtraceEntriesPerBlock) {
-    WriteBlockHeader(cycle, pid);
-    num_entries_ = 4;
-  }
-
-  entry.cycle = cycle + kBaseTic;
-  entry.event = (filenum << 13) | (procnum << 1) | is_exit;
-  fwrite(&entry, sizeof(entry), 1, ftrace_);
-  num_entries_ += 1;
-}
-
-void Gtrace::AddProcEntry(int filenum, int procnum, uint32_t cycle, uint32_t pid)
-{
-  AddGtraceRecord(filenum, procnum, cycle, pid, 0);
-}
-
-void Gtrace::AddProcExit(int filenum, int procnum, uint32_t cycle, uint32_t pid)
-{
-  AddGtraceRecord(filenum, procnum, cycle, pid, 1);
-}
-
-void Gtrace::AddProcedure(int filenum, int procnum, const char *proc_name)
-{
-  fprintf(fnames_, "%d %d %d %s\n", filenum, procnum, procnum, proc_name);
-}
diff --git a/emulator/qtools/gtrace.h b/emulator/qtools/gtrace.h
deleted file mode 100644
index 542adc2..0000000
--- a/emulator/qtools/gtrace.h
+++ /dev/null
@@ -1,69 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef GTRACE_H
-#define GTRACE_H
-
-class Gtrace {
- public:
-  static const int kGtraceEntriesPerBlock = 1024;
-  static const uint32_t kMillion = 1000000;
-  static const uint32_t kTicsPerSecond = 200 * kMillion;
-  static const int kBaseTic = 0x1000;
-
-  struct trace_entry {
-    uint32_t	cycle;
-    uint32_t	event;
-  };
-
-  struct block_header {
-    uint32_t	blockno;
-    uint32_t	entry_width;
-    uint32_t	block_tic;
-    uint32_t	block_time;
-    uint32_t	usec_cpu;
-    uint32_t	pid;
-    uint32_t	bug_count;
-    uint32_t	zero_count;
-  };
-
-  struct first_header {
-    block_header	common;
-    uint32_t		tic;
-    uint32_t		one;
-    uint32_t		tics_per_second;
-    uint32_t		trace_time;
-    uint32_t		version;
-    uint32_t		file_proc;
-    uint32_t		pdate;
-    uint32_t		ptime;
-  };
-
-  Gtrace();
-  ~Gtrace();
-
-  void		Open(const char *gtrace_file, uint32_t pdate, uint32_t ptime);
-  void		WriteFirstHeader(uint32_t start_sec, uint32_t pid);
-  void		AddProcedure(int filenum, int procnum, const char *proc_name);
-  void		AddProcEntry(int filenum, int procnum, uint32_t cycle, uint32_t pid);
-  void		AddProcExit(int filenum, int procnum, uint32_t cycle, uint32_t pid);
-
- private:
-  void		AddGtraceRecord(int filenum, int procnum, uint32_t cycle, uint32_t pid,
-                                int is_exit);
-  void		FillFirstHeader(uint32_t start_sec, uint32_t pid,
-                                first_header *fh);
-  void		WriteBlockHeader(uint32_t cycle, uint32_t pid);
-
-  const char	*gtrace_file_;
-  char		gname_file_[100];
-  FILE		*ftrace_;
-  FILE		*fnames_;
-  uint32_t	start_sec_;
-  uint32_t	pdate_;
-  uint32_t	ptime_;
-  int		num_entries_;
-  int		blockno_;
-  uint32_t	current_pid_;
-};
-
-#endif  // GTRACE_H
diff --git a/emulator/qtools/hash_table.h b/emulator/qtools/hash_table.h
deleted file mode 100644
index 45786ec..0000000
--- a/emulator/qtools/hash_table.h
+++ /dev/null
@@ -1,193 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef HASH_TABLE_H
-#define HASH_TABLE_H
-
-#include <string.h>
-#include <inttypes.h>
-
-template<class T>
-class HashTable {
-  public:
-    HashTable(int size, T default_value = T());
-    ~HashTable();
-
-    typedef struct entry {
-        entry    *next;
-        char     *key;
-        T        value;
-    } entry_type;
-
-    typedef T value_type;
-
-    void         Update(const char *key, T value);
-    T            Find(const char *key);
-    entry_type*  GetFirst();
-    entry_type*  GetNext();
-
-  private:
-    uint32_t     HashFunction(const char *key);
-
-    int          size_;
-    int          mask_;
-    T            default_value_;
-    entry_type   **table_;
-    int          num_entries_;
-    int          current_index_;
-    entry_type   *current_ptr_;
-};
-
-template<class T>
-HashTable<T>::HashTable(int size, T default_value)
-{
-    int pow2;
-
-    // Round up size to a power of two
-    for (pow2 = 2; pow2 < size; pow2 <<= 1)
-        ;    // empty body
-
-    size_ = pow2;
-    mask_ = pow2 - 1;
-    default_value_ = default_value;
-
-    // Allocate a table of pointers and initialize them all to NULL.
-    table_ = new entry_type*[size_];
-    for (int ii = 0; ii < size_; ++ii)
-        table_[ii] = NULL;
-    num_entries_ = 0;
-    current_index_ = 0;
-    current_ptr_ = NULL;
-}
-
-template<class T>
-HashTable<T>::~HashTable()
-{
-    for (int ii = 0; ii < size_; ++ii) {
-        entry_type *ptr, *next;
-
-        // Delete all the pointers in the chain at this table position.
-        // Save the next pointer before deleting each entry so that we
-        // don't dereference part of a deallocated object.
-        for (ptr = table_[ii]; ptr; ptr = next) {
-            next = ptr->next;
-            delete[] ptr->key;
-            delete ptr;
-        }
-    }
-    delete[] table_;
-}
-
-// Professor Daniel J. Bernstein's hash function.  See
-// http://www.partow.net/programming/hashfunctions/
-template<class T>
-uint32_t HashTable<T>::HashFunction(const char *key)
-{
-    uint32_t hash = 5381;
-
-    int len = strlen(key);
-    for(int ii = 0; ii < len; ++key, ++ii)
-        hash = ((hash << 5) + hash) + *key;
-
-    return hash;
-}
-
-template<class T>
-void HashTable<T>::Update(const char *key, T value)
-{
-    // Hash the key to get the table position
-    int len = strlen(key);
-    int pos = HashFunction(key) & mask_;
-
-    // Search the chain for a matching key
-    for (entry_type *ptr = table_[pos]; ptr; ptr = ptr->next) {
-        if (strcmp(ptr->key, key) == 0) {
-            ptr->value = value;
-            return;
-        }
-    }
-
-    // Create a new hash entry and fill in the values
-    entry_type *ptr = new entry_type;
-
-    // Copy the string
-    ptr->key = new char[len + 1];
-    strcpy(ptr->key, key);
-    ptr->value = value;
-
-    // Insert the new entry at the beginning of the list
-    ptr->next = table_[pos];
-    table_[pos] = ptr;
-    num_entries_ += 1;
-}
-
-template<class T>
-typename HashTable<T>::value_type HashTable<T>::Find(const char *key)
-{
-    // Hash the key to get the table position
-    int pos = HashFunction(key) & mask_;
-
-    // Search the chain for a matching key
-    for (entry_type *ptr = table_[pos]; ptr; ptr = ptr->next) {
-        if (strcmp(ptr->key, key) == 0)
-            return ptr->value;
-    }
-
-    // If we get here, then we didn't find the key
-    return default_value_;
-}
-
-template<class T>
-typename HashTable<T>::entry_type* HashTable<T>::GetFirst()
-{
-    // Find the first non-NULL table entry.
-    for (current_index_ = 0; current_index_ < size_; ++current_index_) {
-        if (table_[current_index_])
-            break;
-    }
-
-    // If there are no table entries, then return NULL.
-    if (current_index_ == size_)
-        return NULL;
-
-    // Remember and return the current element.
-    current_ptr_ = table_[current_index_];
-    return current_ptr_;
-}
-
-template<class T>
-typename HashTable<T>::entry_type* HashTable<T>::GetNext()
-{
-    // If we already iterated part way through the hash table, then continue
-    // to the next element.
-    if (current_ptr_) {
-        current_ptr_ = current_ptr_->next;
-
-        // If we are pointing to a valid element, then return it.
-        if (current_ptr_)
-            return current_ptr_;
-
-        // Otherwise, start searching at the next table index.
-        current_index_ += 1;
-    }
-
-    // Find the next non-NULL table entry.
-    for (; current_index_ < size_; ++current_index_) {
-        if (table_[current_index_])
-            break;
-    }
-
-    // If there are no more non-NULL table entries, then return NULL.
-    if (current_index_ == size_) {
-        // Reset the current index so that we will start over from the
-        // beginning on the next call to GetNext().
-        current_index_ = 0;
-        return NULL;
-    }
-
-    // Remember and return the current element.
-    current_ptr_ = table_[current_index_];
-    return current_ptr_;
-}
-
-
-#endif  // HASH_TABLE_H
diff --git a/emulator/qtools/hist_trace.cpp b/emulator/qtools/hist_trace.cpp
deleted file mode 100644
index d2c6a90..0000000
--- a/emulator/qtools/hist_trace.cpp
+++ /dev/null
@@ -1,64 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-
-static const int kMaxHistEntries = 256;
-static const int kMaxHistEntries2 = kMaxHistEntries /  2;
-int hist[kMaxHistEntries];
-int underflow, overflow;
-
-int main(int argc, char **argv) {
-  if (argc != 2) {
-    fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-    exit(1);
-  }
-
-  char *trace_filename = argv[1];
-  TraceReaderBase *trace = new TraceReaderBase;
-  trace->Open(trace_filename);
-
-  uint64_t prev_bb_num = 0;
-  uint64_t prev_time = 0;
-  int total = 0;
-  
-  while (1) {
-    BBEvent event;
-
-    if (trace->ReadBB(&event))
-      break;
-    int bb_diff = event.bb_num - prev_bb_num;
-    //int time_diff = event.time - prev_time;
-    //printf("bb_num: %llu prev: %llu, diff: %d\n",
-    // event.bb_num, prev_bb_num, bb_diff);
-    prev_bb_num = event.bb_num;
-    prev_time = event.time;
-
-    bb_diff += kMaxHistEntries2;
-    if (bb_diff < 0)
-      underflow += 1;
-    else if (bb_diff >= kMaxHistEntries)
-      overflow += 1;
-    else
-      hist[bb_diff] += 1;
-    total += 1;
-  }
-
-  int sum = 0;
-  double sum_per = 0;
-  double per = 0;
-  for (int ii = 0; ii < kMaxHistEntries; ++ii) {
-    if (hist[ii] == 0)
-      continue;
-    per = 100.0 * hist[ii] / total;
-    sum += hist[ii];
-    sum_per = 100.0 * sum / total;
-    printf(" %4d: %6d %6.2f %6.2f\n", ii - kMaxHistEntries2, hist[ii], per, sum_per);
-  }
-  per = 100.0 * underflow / total;
-  printf("under: %6d %6.2f\n", underflow, per);
-  per = 100.0 * overflow / total;
-  printf("over:  %6d %6.2f\n", overflow, per);
-  printf("total: %6d\n", total);
-  return 0;
-}
diff --git a/emulator/qtools/opcode.cpp b/emulator/qtools/opcode.cpp
deleted file mode 100644
index 41bef3a..0000000
--- a/emulator/qtools/opcode.cpp
+++ /dev/null
@@ -1,204 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <inttypes.h>
-#include "opcode.h"
-
-// Note: this array depends on the Opcode enum defined in opcode.h
-uint32_t opcode_flags[] = {
-    0,                                             // OP_INVALID
-    0,                                             // OP_UNDEFINED
-    kCatAlu,                                       // OP_ADC
-    kCatAlu,                                       // OP_ADD
-    kCatAlu,                                       // OP_AND
-    kCatBranch,                                    // OP_B
-    kCatBranch | kCatBranchLink,                   // OP_BL
-    kCatAlu,                                       // OP_BIC
-    0,                                             // OP_BKPT
-    kCatBranch | kCatBranchLink | kCatBranchExch,  // OP_BLX
-    kCatBranch | kCatBranchExch,                   // OP_BX
-    kCatCoproc,                                    // OP_CDP
-    kCatAlu,                                       // OP_CLZ
-    kCatAlu,                                       // OP_CMN
-    kCatAlu,                                       // OP_CMP
-    kCatAlu,                                       // OP_EOR
-    kCatCoproc | kCatLoad,                         // OP_LDC
-    kCatLoad | kCatMultiple,                       // OP_LDM
-    kCatLoad | kCatWord,                           // OP_LDR
-    kCatLoad | kCatByte,                           // OP_LDRB
-    kCatLoad | kCatByte,                           // OP_LDRBT
-    kCatLoad | kCatHalf,                           // OP_LDRH
-    kCatLoad | kCatByte | kCatSigned,              // OP_LDRSB
-    kCatLoad | kCatHalf | kCatSigned,              // OP_LDRSH
-    kCatLoad | kCatWord,                           // OP_LDRT
-    kCatCoproc,                                    // OP_MCR
-    kCatAlu,                                       // OP_MLA
-    kCatAlu,                                       // OP_MOV
-    kCatCoproc,                                    // OP_MRC
-    0,                                             // OP_MRS
-    0,                                             // OP_MSR
-    kCatAlu,                                       // OP_MUL
-    kCatAlu,                                       // OP_MVN
-    kCatAlu,                                       // OP_ORR
-    0,                                             // OP_PLD
-    kCatAlu,                                       // OP_RSB
-    kCatAlu,                                       // OP_RSC
-    kCatAlu,                                       // OP_SBC
-    kCatAlu,                                       // OP_SMLAL
-    kCatAlu,                                       // OP_SMULL
-    kCatCoproc | kCatStore,                        // OP_STC
-    kCatStore | kCatMultiple,                      // OP_STM
-    kCatStore | kCatWord,                          // OP_STR
-    kCatStore | kCatByte,                          // OP_STRB
-    kCatStore | kCatByte,                          // OP_STRBT
-    kCatStore | kCatHalf,                          // OP_STRH
-    kCatStore | kCatWord,                          // OP_STRT
-    kCatAlu,                                       // OP_SUB
-    0,                                             // OP_SWI
-    kCatLoad | kCatStore,                          // OP_SWP
-    kCatLoad | kCatStore | kCatByte,               // OP_SWPB
-    kCatAlu,                                       // OP_TEQ
-    kCatAlu,                                       // OP_TST
-    kCatAlu,                                       // OP_UMLAL
-    kCatAlu,                                       // OP_UMULL
-
-    0,                                             // OP_THUMB_UNDEFINED,
-    kCatAlu,                                       // OP_THUMB_ADC,
-    kCatAlu,                                       // OP_THUMB_ADD,
-    kCatAlu,                                       // OP_THUMB_AND,
-    kCatAlu,                                       // OP_THUMB_ASR,
-    kCatBranch,                                    // OP_THUMB_B,
-    kCatAlu,                                       // OP_THUMB_BIC,
-    0,                                             // OP_THUMB_BKPT,
-    kCatBranch | kCatBranchLink,                   // OP_THUMB_BL,
-    kCatBranch | kCatBranchLink | kCatBranchExch,  // OP_THUMB_BLX,
-    kCatBranch | kCatBranchExch,                   // OP_THUMB_BX,
-    kCatAlu,                                       // OP_THUMB_CMN,
-    kCatAlu,                                       // OP_THUMB_CMP,
-    kCatAlu,                                       // OP_THUMB_EOR,
-    kCatLoad | kCatMultiple,                       // OP_THUMB_LDMIA,
-    kCatLoad | kCatWord,                           // OP_THUMB_LDR,
-    kCatLoad | kCatByte,                           // OP_THUMB_LDRB,
-    kCatLoad | kCatHalf,                           // OP_THUMB_LDRH,
-    kCatLoad | kCatByte | kCatSigned,              // OP_THUMB_LDRSB,
-    kCatLoad | kCatHalf | kCatSigned,              // OP_THUMB_LDRSH,
-    kCatAlu,                                       // OP_THUMB_LSL,
-    kCatAlu,                                       // OP_THUMB_LSR,
-    kCatAlu,                                       // OP_THUMB_MOV,
-    kCatAlu,                                       // OP_THUMB_MUL,
-    kCatAlu,                                       // OP_THUMB_MVN,
-    kCatAlu,                                       // OP_THUMB_NEG,
-    kCatAlu,                                       // OP_THUMB_ORR,
-    kCatLoad | kCatMultiple,                       // OP_THUMB_POP,
-    kCatStore | kCatMultiple,                      // OP_THUMB_PUSH,
-    kCatAlu,                                       // OP_THUMB_ROR,
-    kCatAlu,                                       // OP_THUMB_SBC,
-    kCatStore | kCatMultiple,                      // OP_THUMB_STMIA,
-    kCatStore | kCatWord,                          // OP_THUMB_STR,
-    kCatStore | kCatByte,                          // OP_THUMB_STRB,
-    kCatStore | kCatHalf,                          // OP_THUMB_STRH,
-    kCatAlu,                                       // OP_THUMB_SUB,
-    0,                                             // OP_THUMB_SWI,
-    kCatAlu,                                       // OP_THUMB_TST,
-
-    0,                                             // OP_END
-};
-
-const char *opcode_names[] = {
-    "invalid",
-    "undefined",
-    "adc",
-    "add",
-    "and",
-    "b",
-    "bl",
-    "bic",
-    "bkpt",
-    "blx",
-    "bx",
-    "cdp",
-    "clz",
-    "cmn",
-    "cmp",
-    "eor",
-    "ldc",
-    "ldm",
-    "ldr",
-    "ldrb",
-    "ldrbt",
-    "ldrh",
-    "ldrsb",
-    "ldrsh",
-    "ldrt",
-    "mcr",
-    "mla",
-    "mov",
-    "mrc",
-    "mrs",
-    "msr",
-    "mul",
-    "mvn",
-    "orr",
-    "pld",
-    "rsb",
-    "rsc",
-    "sbc",
-    "smlal",
-    "smull",
-    "stc",
-    "stm",
-    "str",
-    "strb",
-    "strbt",
-    "strh",
-    "strt",
-    "sub",
-    "swi",
-    "swp",
-    "swpb",
-    "teq",
-    "tst",
-    "umlal",
-    "umull",
-
-    "undefined",
-    "adc",
-    "add",
-    "and",
-    "asr",
-    "b",
-    "bic",
-    "bkpt",
-    "bl",
-    "blx",
-    "bx",
-    "cmn",
-    "cmp",
-    "eor",
-    "ldmia",
-    "ldr",
-    "ldrb",
-    "ldrh",
-    "ldrsb",
-    "ldrsh",
-    "lsl",
-    "lsr",
-    "mov",
-    "mul",
-    "mvn",
-    "neg",
-    "orr",
-    "pop",
-    "push",
-    "ror",
-    "sbc",
-    "stmia",
-    "str",
-    "strb",
-    "strh",
-    "sub",
-    "swi",
-    "tst",
-
-    NULL
-};
diff --git a/emulator/qtools/opcode.h b/emulator/qtools/opcode.h
deleted file mode 100644
index c8b67a6..0000000
--- a/emulator/qtools/opcode.h
+++ /dev/null
@@ -1,166 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef OPCODE_H
-#define OPCODE_H
-
-#include <inttypes.h>
-
-// Note: this list of opcodes must match the list used to initialize
-// the opflags[] array in opcode.cpp.
-enum Opcode {
-    OP_INVALID,
-    OP_UNDEFINED,
-    OP_ADC,
-    OP_ADD,
-    OP_AND,
-    OP_B,
-    OP_BL,
-    OP_BIC,
-    OP_BKPT,
-    OP_BLX,
-    OP_BX,
-    OP_CDP,
-    OP_CLZ,
-    OP_CMN,
-    OP_CMP,
-    OP_EOR,
-    OP_LDC,
-    OP_LDM,
-    OP_LDR,
-    OP_LDRB,
-    OP_LDRBT,
-    OP_LDRH,
-    OP_LDRSB,
-    OP_LDRSH,
-    OP_LDRT,
-    OP_MCR,
-    OP_MLA,
-    OP_MOV,
-    OP_MRC,
-    OP_MRS,
-    OP_MSR,
-    OP_MUL,
-    OP_MVN,
-    OP_ORR,
-    OP_PLD,
-    OP_RSB,
-    OP_RSC,
-    OP_SBC,
-    OP_SMLAL,
-    OP_SMULL,
-    OP_STC,
-    OP_STM,
-    OP_STR,
-    OP_STRB,
-    OP_STRBT,
-    OP_STRH,
-    OP_STRT,
-    OP_SUB,
-    OP_SWI,
-    OP_SWP,
-    OP_SWPB,
-    OP_TEQ,
-    OP_TST,
-    OP_UMLAL,
-    OP_UMULL,
-
-    // Define thumb opcodes
-    OP_THUMB_UNDEFINED,
-    OP_THUMB_ADC,
-    OP_THUMB_ADD,
-    OP_THUMB_AND,
-    OP_THUMB_ASR,
-    OP_THUMB_B,
-    OP_THUMB_BIC,
-    OP_THUMB_BKPT,
-    OP_THUMB_BL,
-    OP_THUMB_BLX,
-    OP_THUMB_BX,
-    OP_THUMB_CMN,
-    OP_THUMB_CMP,
-    OP_THUMB_EOR,
-    OP_THUMB_LDMIA,
-    OP_THUMB_LDR,
-    OP_THUMB_LDRB,
-    OP_THUMB_LDRH,
-    OP_THUMB_LDRSB,
-    OP_THUMB_LDRSH,
-    OP_THUMB_LSL,
-    OP_THUMB_LSR,
-    OP_THUMB_MOV,
-    OP_THUMB_MUL,
-    OP_THUMB_MVN,
-    OP_THUMB_NEG,
-    OP_THUMB_ORR,
-    OP_THUMB_POP,
-    OP_THUMB_PUSH,
-    OP_THUMB_ROR,
-    OP_THUMB_SBC,
-    OP_THUMB_STMIA,
-    OP_THUMB_STR,
-    OP_THUMB_STRB,
-    OP_THUMB_STRH,
-    OP_THUMB_SUB,
-    OP_THUMB_SWI,
-    OP_THUMB_TST,
-
-    OP_END                // must be last
-};
-
-extern uint32_t opcode_flags[];
-extern const char *opcode_names[];
-
-// Define bit flags for the opcode categories
-static const uint32_t kCatByte          = 0x0001;
-static const uint32_t kCatHalf          = 0x0002;
-static const uint32_t kCatWord          = 0x0004;
-static const uint32_t kCatLong          = 0x0008;
-static const uint32_t kCatNumBytes      = (kCatByte | kCatHalf | kCatWord | kCatLong);
-static const uint32_t kCatMultiple      = 0x0010;
-static const uint32_t kCatSigned        = 0x0020;
-static const uint32_t kCatLoad          = 0x0040;
-static const uint32_t kCatStore         = 0x0080;
-static const uint32_t kCatMemoryRef     = (kCatLoad | kCatStore);
-static const uint32_t kCatAlu           = 0x0100;
-static const uint32_t kCatBranch        = 0x0200;
-static const uint32_t kCatBranchLink    = 0x0400;
-static const uint32_t kCatBranchExch    = 0x0800;
-static const uint32_t kCatCoproc        = 0x1000;
-static const uint32_t kCatLoadMultiple  = (kCatLoad | kCatMultiple);
-static const uint32_t kCatStoreMultiple = (kCatStore | kCatMultiple);
-
-inline bool isALU(Opcode op)    { return (opcode_flags[op] & kCatAlu) != 0; }
-inline bool isBranch(Opcode op) { return (opcode_flags[op] & kCatBranch) != 0; }
-inline bool isBranchLink(Opcode op) {
-    return (opcode_flags[op] & kCatBranchLink) != 0;
-}
-inline bool isBranchExch(Opcode op) {
-    return (opcode_flags[op] & kCatBranchExch) != 0;
-}
-inline bool isLoad(Opcode op)   { return (opcode_flags[op] & kCatLoad) != 0; }
-inline bool isLoadMultiple(Opcode op) {
-    return (opcode_flags[op] & kCatLoadMultiple) == kCatLoadMultiple;
-}
-inline bool isStoreMultiple(Opcode op) {
-    return (opcode_flags[op] & kCatStoreMultiple) == kCatStoreMultiple;
-}
-inline bool isStore(Opcode op)  { return (opcode_flags[op] & kCatStore) != 0; }
-inline bool isSigned(Opcode op) { return (opcode_flags[op] & kCatSigned) != 0; }
-inline bool isMemoryRef(Opcode op) {
-    return (opcode_flags[op] & kCatMemoryRef) != 0;
-}
-inline int getAccessSize(Opcode op) { return opcode_flags[op] & kCatNumBytes; }
-inline bool isCoproc(Opcode op) { return (opcode_flags[op] & kCatCoproc) != 0; }
-inline int getNumAccesses(Opcode op, uint32_t binary) {
-  extern int num_one_bits[];
-  int num_accesses = 0;
-  if (opcode_flags[op] & kCatNumBytes)
-    num_accesses = 1;
-  else if (opcode_flags[op] & kCatMultiple) {
-    num_accesses = num_one_bits[(binary >> 8) & 0xff]
-                   + num_one_bits[binary & 0xff];
-  }
-  return num_accesses;
-}
-
-#endif  // OPCODE_H
diff --git a/emulator/qtools/parse_options-inl.h b/emulator/qtools/parse_options-inl.h
deleted file mode 100644
index f218cc1..0000000
--- a/emulator/qtools/parse_options-inl.h
+++ /dev/null
@@ -1,147 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef PARSE_OPTIONS_INL_H
-#define PARSE_OPTIONS_INL_H
-
-// Define a typedef for TraceReaderType and include "parse_options.h"
-// before including this header file in a C++ source file.
-//
-// For example:
-// 
-// struct symbol {
-//   int  elapsed;
-// };
-// 
-// typedef TraceReader<symbol> TraceReaderType;
-
-
-typedef TraceReaderType::symbol_type symbol_type;
-typedef TraceReaderType::region_type region_type;
-typedef TraceReaderType::ProcessState ProcessState;
-
-symbol_type *kernel_sym;
-symbol_type *library_sym;
-
-// Returns true if the given event is included (or not excluded)
-// from the list of valid events specified by the user on the
-// command line.
-inline bool IsValidEvent(BBEvent *event, symbol_type *sym)
-{
-  if (include_some_pids && pid_include_vector.GetBit(event->pid) == 0)
-      return false;
-  if (exclude_some_pids && pid_exclude_vector.GetBit(event->pid))
-      return false;
-  if (include_some_procedures) {
-    if (sym == NULL || included_procedures.Find(sym->name) == 0)
-      return false;
-  }
-  if (exclude_some_procedures) {
-    if (sym == NULL || excluded_procedures.Find(sym->name))
-      return false;
-  }
-  return true;
-}
-
-inline symbol_type *GetSymbol(TraceReaderType *trace, int pid, uint32_t addr,
-                              uint64_t time)
-{
-  symbol_type *sym = trace->LookupFunction(pid, addr, time);
-
-  if (lump_kernel && (sym->region->flags & region_type::kIsKernelRegion)) {
-    if (kernel_sym == NULL) {
-      kernel_sym = sym;
-      sym->name = ":kernel";
-    } else {
-      sym = kernel_sym;
-    }
-  }
-
-  if (lump_libraries && (sym->region->flags & region_type::kIsLibraryRegion)) {
-    if (library_sym == NULL) {
-      library_sym = sym;
-      sym->name = ":libs";
-    } else {
-      sym = library_sym;
-    }
-  }
-
-  return sym;
-}
-
-inline bool IsIncludedProcedure(symbol_type *sym)
-{
-  if (include_kernel_syms && (sym->region->flags & region_type::kIsKernelRegion))
-    return true;
-  if (include_library_syms && (sym->region->flags & region_type::kIsLibraryRegion))
-    return true;
-  return included_procedures.Find(sym->name);
-}
-
-inline bool IsExcludedProcedure(symbol_type *sym)
-{
-  if (exclude_kernel_syms && (sym->region->flags & region_type::kIsKernelRegion))
-    return true;
-  if (exclude_library_syms && (sym->region->flags & region_type::kIsLibraryRegion))
-    return true;
-  return excluded_procedures.Find(sym->name);
-}
-
-// Returns true on end-of-file.
-inline bool GetNextValidEvent(TraceReaderType *trace,
-                              BBEvent *event,
-                              BBEvent *first_ignored_event,
-                              symbol_type **sym_ptr)
-{
-  symbol_type *sym = NULL;
-  first_ignored_event->time = 0;
-  if (trace->ReadBB(event))
-    return true;
-  bool recheck = true;
-  while (recheck) {
-    recheck = false;
-    if (include_some_pids) {
-      while (pid_include_vector.GetBit(event->pid) == 0) {
-        if (first_ignored_event->time == 0)
-          *first_ignored_event = *event;
-        if (trace->ReadBB(event))
-          return true;
-      }
-    } else if (exclude_some_pids) {
-      while (pid_exclude_vector.GetBit(event->pid)) {
-        if (first_ignored_event->time == 0)
-          *first_ignored_event = *event;
-        if (trace->ReadBB(event))
-          return true;
-      }
-    }
-
-    if (include_some_procedures) {
-      sym = GetSymbol(trace, event->pid, event->bb_addr, event->time);
-      while (!IsIncludedProcedure(sym)) {
-        if (first_ignored_event->time == 0)
-          *first_ignored_event = *event;
-        if (trace->ReadBB(event))
-          return true;
-        recheck = true;
-        sym = GetSymbol(trace, event->pid, event->bb_addr, event->time);
-      }
-    } else if (exclude_some_procedures) {
-      sym = GetSymbol(trace, event->pid, event->bb_addr, event->time);
-      while (IsExcludedProcedure(sym)) {
-        if (first_ignored_event->time == 0)
-          *first_ignored_event = *event;
-        if (trace->ReadBB(event))
-          return true;
-        recheck = true;
-        sym = GetSymbol(trace, event->pid, event->bb_addr, event->time);
-      }
-    }
-  }
-  if (sym == NULL)
-    sym = GetSymbol(trace, event->pid, event->bb_addr, event->time);
-
-  *sym_ptr = sym;
-  return false;
-}
-
-#endif  // PARSE_OPTIONS_INL_H
diff --git a/emulator/qtools/parse_options.cpp b/emulator/qtools/parse_options.cpp
deleted file mode 100644
index 395e9a1..0000000
--- a/emulator/qtools/parse_options.cpp
+++ /dev/null
@@ -1,119 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <ctype.h>
-#include "bitvector.h"
-#include "parse_options.h"
-#include "hash_table.h"
-
-const char *root = "";
-bool lump_kernel;
-bool lump_libraries;
-Bitvector pid_include_vector(32768);
-Bitvector pid_exclude_vector(32768);
-bool include_some_pids;
-bool exclude_some_pids;
-
-HashTable<int> excluded_procedures(2000);
-HashTable<int> included_procedures(2000);
-bool exclude_some_procedures;
-bool include_some_procedures;
-
-bool exclude_kernel_syms;
-bool exclude_library_syms;
-bool include_kernel_syms;
-bool include_library_syms;
-bool demangle = true;
-
-static const char *OptionsUsageStr =
-    "  -e :kernel exclude all kernel symbols\n"
-    "  -e :libs   exclude all library symbols\n"
-    "  -e <func>  exclude function <func>\n"
-    "  -e <pid>   exclude process <pid>\n"
-    "  -i :kernel include all kernel symbols\n"
-    "  -i :libs   include all library symbols\n"
-    "  -i <func>  include function <func>\n"
-    "  -i <pid>   include process <pid>\n"
-    "  -l :kernel lump all the kernel symbols together\n"
-    "  -l :libs   lump all the library symbols together\n"
-    "  -m         do not demangle C++ symbols (m for 'mangle')\n"
-    "  -r <root>  use <root> as the path for finding ELF executables\n"
-    ;
-
-void OptionsUsage()
-{
-    fprintf(stderr, "%s", OptionsUsageStr);
-}
-
-void ParseOptions(int argc, char **argv)
-{
-    bool err = false;
-    while (!err) {
-        int opt = getopt(argc, argv, "+e:i:l:mr:");
-        if (opt == -1)
-            break;
-        switch (opt) {
-        case 'e':
-            if (*optarg == ':') {
-                if (strcmp(optarg, ":kernel") == 0)
-                    exclude_kernel_syms = true;
-                else if (strcmp(optarg, ":libs") == 0)
-                    exclude_library_syms = true;
-                else
-                    err = true;
-                excluded_procedures.Update(optarg, 1);
-                exclude_some_procedures = true;
-            } else if (isdigit(*optarg)) {
-                int bitnum = atoi(optarg);
-                pid_exclude_vector.SetBit(bitnum);
-                exclude_some_pids = true;
-            } else {
-                excluded_procedures.Update(optarg, 1);
-                exclude_some_procedures = true;
-            }
-            break;
-        case 'i':
-            if (*optarg == ':') {
-                if (strcmp(optarg, ":kernel") == 0)
-                    include_kernel_syms = true;
-                else if (strcmp(optarg, ":libs") == 0)
-                    include_library_syms = true;
-                else
-                    err = true;
-                included_procedures.Update(optarg, 1);
-                include_some_procedures = true;
-            } else if (isdigit(*optarg)) {
-                int bitnum = atoi(optarg);
-                pid_include_vector.SetBit(bitnum);
-                include_some_pids = true;
-            } else {
-                included_procedures.Update(optarg, 1);
-                include_some_procedures = true;
-            }
-            break;
-        case 'l':
-            if (strcmp(optarg, ":kernel") == 0)
-                lump_kernel = true;
-            else if (strcmp(optarg, ":libs") == 0)
-                lump_libraries = true;
-            else
-                err = true;
-            break;
-        case 'm':
-            demangle = false;
-            break;
-        case 'r':
-            root = optarg;
-            break;
-        default:
-            err = true;
-            break;
-        }
-    }
-
-    if (err) {
-        Usage(argv[0]);
-        exit(1);
-    }
-}
diff --git a/emulator/qtools/parse_options.h b/emulator/qtools/parse_options.h
deleted file mode 100644
index aacbb9e..0000000
--- a/emulator/qtools/parse_options.h
+++ /dev/null
@@ -1,32 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef PARSE_OPTIONS_H
-#define PARSE_OPTIONS_H
-
-#include "bitvector.h"
-#include "hash_table.h"
-
-extern const char *root;
-extern bool lump_kernel;
-extern bool lump_libraries;
-extern Bitvector pid_include_vector;
-extern Bitvector pid_exclude_vector;
-extern bool include_some_pids;
-extern bool exclude_some_pids;
-
-extern HashTable<int> excluded_procedures;
-extern HashTable<int> included_procedures;
-extern bool exclude_some_procedures;
-extern bool include_some_procedures;
-
-extern bool exclude_kernel_syms;
-extern bool exclude_library_syms;
-extern bool include_kernel_syms;
-extern bool include_library_syms;
-extern bool demangle;
-
-extern void Usage(const char *program);
-extern void ParseOptions(int argc, char **argv);
-extern void OptionsUsage();
-
-#endif  // PARSE_OPTIONS_H
diff --git a/emulator/qtools/post_trace.cpp b/emulator/qtools/post_trace.cpp
deleted file mode 100644
index 99525fb..0000000
--- a/emulator/qtools/post_trace.cpp
+++ /dev/null
@@ -1,151 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-
-typedef struct MyStaticRec {
-  StaticRec bb;
-  uint32_t  *insns;
-} MyStaticRec;
-
-const int kNumPids = 32768;
-char usedPids[kNumPids];
-
-int main(int argc, char **argv) {
-  uint32_t insns[kMaxInsnPerBB];
-
-  if (argc != 2) {
-    fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-    exit(1);
-  }
-
-  char *trace_filename = argv[1];
-  TraceReaderBase *trace = new TraceReaderBase;
-  trace->SetPostProcessing(true);
-  trace->Open(trace_filename);
-
-  // Count the number of static basic blocks and instructions.
-  uint64_t num_static_bb = 0;
-  uint64_t num_static_insn = 0;
-  while (1) {
-    StaticRec static_rec;
-
-    if (trace->ReadStatic(&static_rec))
-      break;
-    if (static_rec.bb_num != num_static_bb) {
-      fprintf(stderr,
-              "Error: basic block numbers out of order; expected %lld, got %lld\n",
-              num_static_bb, static_rec.bb_num);
-      exit(1);
-    }
-    num_static_bb += 1;
-    num_static_insn += static_rec.num_insns;
-    trace->ReadStaticInsns(static_rec.num_insns, insns);
-  }
-  trace->Close();
-
-  // Allocate space for all of the static blocks
-  MyStaticRec *blocks = new MyStaticRec[num_static_bb];
-
-  // Read the static blocks again and save pointers to them
-  trace->Open(trace_filename);
-  for (uint32_t ii = 0; ii < num_static_bb; ++ii) {
-    trace->ReadStatic(&blocks[ii].bb);
-    uint32_t num_insns = blocks[ii].bb.num_insns;
-    if (num_insns > 0) {
-      blocks[ii].insns = new uint32_t[num_insns];
-      trace->ReadStaticInsns(num_insns, blocks[ii].insns);
-    }
-  }
-
-  // Check the last basic block.  If it contains a special undefined
-  // instruction, then truncate the basic block at that point.
-  uint32_t num_insns = blocks[num_static_bb - 1].bb.num_insns;
-  uint32_t *insn_ptr = blocks[num_static_bb - 1].insns;
-  for (uint32_t ii = 0; ii < num_insns; ++ii, ++insn_ptr) {
-    if (*insn_ptr == 0xe6c00110) {
-      uint32_t actual_num_insns = ii + 1;
-      blocks[num_static_bb - 1].bb.num_insns = actual_num_insns;
-      num_static_insn -= (num_insns - actual_num_insns);
-
-      // Write the changes back to the trace file
-      trace->TruncateLastBlock(actual_num_insns);
-      break;
-    }
-  }
-  TraceHeader *header = trace->GetHeader();
-  strcpy(header->ident, TRACE_IDENT);
-  header->num_static_bb = num_static_bb;
-  header->num_dynamic_bb = 0;
-  header->num_static_insn = num_static_insn;
-  header->num_dynamic_insn = 0;
-  trace->WriteHeader(header);
-
-  // Reopen the trace file in order to force the trace manager to reread
-  // the static blocks now that we have written that information to the
-  // header.
-  trace->Close();
-  trace->Open(trace_filename);
-
-  // Count the number of dynamic executions of basic blocks and instructions.
-  // Also keep track of which process ids are used.
-  uint64_t num_dynamic_bb = 0;
-  uint64_t num_dynamic_insn = 0;
-  while (1) {
-    BBEvent event;
-
-    if (trace->ReadBB(&event))
-      break;
-    if (event.bb_num >= num_static_bb) {
-      fprintf(stderr,
-              "Error: basic block number (%lld) too large (num blocks: %lld)\n",
-              event.bb_num, num_static_bb);
-      exit(1);
-    }
-    usedPids[event.pid] = 1;
-    num_dynamic_bb += 1;
-    num_dynamic_insn += event.num_insns;
-  }
-
-  // Count the number of process ids that are used and remember the first
-  // unused pid.
-  int numUsedPids = 0;
-  int unusedPid = -1;
-  for (int pid = 0; pid < kNumPids; pid++) {
-      if (usedPids[pid] == 1) {
-          numUsedPids += 1;
-      } else if (unusedPid == -1) {
-          unusedPid = pid;
-      }
-  }
-
-  // Rewrite the header with the dynamic counts
-  header->num_dynamic_bb = num_dynamic_bb;
-  header->num_dynamic_insn = num_dynamic_insn;
-  header->num_used_pids = numUsedPids;
-  header->first_unused_pid = unusedPid;
-  trace->WriteHeader(header);
-  trace->Close();
-
-  printf("Static basic blocks: %llu, Dynamic basic blocks: %llu\n",
-         num_static_bb, num_dynamic_bb);
-  printf("Static instructions: %llu, Dynamic instructions: %llu\n",
-         num_static_insn, num_dynamic_insn);
-
-  double elapsed_secs = header->elapsed_usecs / 1000000.0;
-  double insn_per_sec = 0;
-  if (elapsed_secs != 0)
-    insn_per_sec = num_dynamic_insn / elapsed_secs;
-  char *suffix = "";
-  if (insn_per_sec >= 1000000) {
-    insn_per_sec /= 1000000.0;
-    suffix = "M";
-  } else if (insn_per_sec > 1000) {
-    insn_per_sec /= 1000.0;
-    suffix = "K";
-  }
-  printf("Elapsed seconds: %.2f, simulated instructions/sec: %.1f%s\n",
-         elapsed_secs, insn_per_sec, suffix);
-  return 0;
-}
diff --git a/emulator/qtools/profile_pid.cpp b/emulator/qtools/profile_pid.cpp
deleted file mode 100644
index aa37847..0000000
--- a/emulator/qtools/profile_pid.cpp
+++ /dev/null
@@ -1,93 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <string.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-// This function is called from quicksort to compare the cpu time
-// of processes and sort into decreasing order.
-int cmp_dec_cpu_time(const void *a, const void *b) {
-  ProcessState *proc1, *proc2;
-
-  proc1 = (ProcessState*)a;
-  proc2 = (ProcessState*)b;
-  if (proc1 == NULL) {
-    if (proc2 == NULL)
-      return 0;
-    return 1;
-  }
-  if (proc2 == NULL)
-    return -1;
-  if (proc1->cpu_time < proc2->cpu_time)
-    return 1;
-  if (proc1->cpu_time > proc2->cpu_time)
-    return -1;
-  // If the cpu_time times are the same, then sort into increasing
-  // order of pid.
-  return proc1->pid - proc2->pid;
-}
-
-void Usage(const char *program)
-{
-  fprintf(stderr, "Usage: %s [options] trace_file\n", program);
-  OptionsUsage();
-}
-
-int main(int argc, char **argv) {
-  // Parse the options
-  ParseOptions(argc, argv);
-  if (argc - optind != 1) {
-    Usage(argv[0]);
-    exit(1);
-  }
-
-  char *trace_filename = argv[optind];
-  TraceReader<> *trace = new TraceReader<>;
-  trace->Open(trace_filename);
-  trace->SetRoot(root);
-
-  while (1) {
-    BBEvent event, ignored;
-    symbol_type *dummy_sym;
-
-    if (GetNextValidEvent(trace, &event, &ignored, &dummy_sym))
-      break;
-  }
-
-  int num_procs;
-  ProcessState *processes = trace->GetProcesses(&num_procs);
-  qsort(processes, num_procs, sizeof(ProcessState), cmp_dec_cpu_time);
-
-  uint64_t total_time = 0;
-  for (int ii = 0; ii < num_procs; ++ii) {
-    total_time += processes[ii].cpu_time;
-  }
-
-  uint64_t sum_time = 0;
-  printf("  pid parent   cpu_time      %%      %% flags argv\n"); 
-  ProcessState *pstate = &processes[0];
-  for (int ii = 0; ii < num_procs; ++ii, ++pstate) {
-    sum_time += pstate->cpu_time;
-    double per = 100.0 * pstate->cpu_time / total_time;
-    double sum_per = 100.0 * sum_time / total_time;
-    char *print_flags = "";
-    if ((pstate->flags & ProcessState::kCalledExec) == 0)
-      print_flags = "T";
-    if (pstate->name == NULL)
-      pstate->name = "";
-    printf("%5d  %5d %10llu %6.2f %6.2f %5s %s",
-           pstate->pid, pstate->parent_pid, pstate->cpu_time,
-           per, sum_per, print_flags, pstate->name);
-    for (int ii = 1; ii < pstate->argc; ++ii) {
-      printf(" %s", pstate->argv[ii]);
-    }
-    printf("\n");
-  }
-  return 0;
-}
diff --git a/emulator/qtools/profile_trace.cpp b/emulator/qtools/profile_trace.cpp
deleted file mode 100644
index 9d14a03..0000000
--- a/emulator/qtools/profile_trace.cpp
+++ /dev/null
@@ -1,131 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <string.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-
-const int kMillion = 1000000;
-const int kMHz = 200 * kMillion;
-
-struct symbol {
-    int         count;      // number of times a function is executed
-    uint64_t    elapsed;    // elapsed time for this function
-};
-
-typedef TraceReader<symbol> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-static const uint32_t kOffsetThreshold = 0x100000;
-
-// This comparison function is called from qsort() to sort
-// symbols into decreasing elapsed time.
-int cmp_sym_elapsed(const void *a, const void *b) {
-    const symbol_type *syma, *symb;
-    uint64_t elapsed1, elapsed2;
-
-    syma = static_cast<symbol_type const *>(a);
-    symb = static_cast<symbol_type const *>(b);
-    elapsed1 = syma->elapsed;
-    elapsed2 = symb->elapsed;
-    if (elapsed1 < elapsed2)
-        return 1;
-    if (elapsed1 == elapsed2)
-        return strcmp(syma->name, symb->name);
-    return -1;
-}
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_file elf_file\n", program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv)
-{
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<symbol> *trace = new TraceReader<symbol>;
-    trace->Open(trace_filename);
-    trace->SetDemangle(demangle);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    symbol_type dummy;
-    dummy.count = 0;
-    dummy.elapsed = 0;
-    symbol_type *prev_sym = &dummy;
-    uint64_t prev_bb_time = 0;
-    while (1) {
-        symbol_type *sym;
-        BBEvent event;
-        BBEvent first_ignored_event;
-
-        bool eof = GetNextValidEvent(trace, &event, &first_ignored_event, &sym);
-
-        // Assign the elapsed time to the previous function symbol
-        uint64_t elapsed = 0;
-        if (first_ignored_event.time != 0)
-            elapsed = first_ignored_event.time - prev_bb_time;
-        else if (!eof)
-            elapsed = event.time - prev_bb_time;
-        prev_sym->elapsed += elapsed;
-
-        if (eof)
-            break;
-
-        prev_bb_time = event.time;
-        sym->count += 1;
-        prev_sym = sym;
-#if 0
-        printf("t%lld bb_num: %d, bb_addr: 0x%x func: %s, addr: 0x%x, count: %d\n",
-               bb_time, bb_num, bb_addr, sym->name, sym->addr, sym->count);
-#endif
-    }
-
-    int nsyms;
-    symbol_type *syms = trace->GetSymbols(&nsyms);
-
-    // Sort the symbols into decreasing order of elapsed time
-    qsort(syms, nsyms, sizeof(symbol_type), cmp_sym_elapsed);
-
-    // Add up all the cycles
-    uint64_t total = 0;
-    symbol_type *sym = syms;
-    for (int ii = 0; ii < nsyms; ++ii, ++sym) {
-        total += sym->elapsed;
-    }
-
-    double secs = 1.0 * total / kMHz;
-    printf("Total seconds: %.2f, total cycles: %lld, MHz: %d\n\n",
-           secs, total, kMHz / kMillion);
-
-    uint64_t sum = 0;
-    printf("Elapsed secs Elapsed cyc      %%      %%    Function\n");
-    sym = syms;
-    for (int ii = 0; ii < nsyms; ++ii, ++sym) {
-        if (sym->elapsed == 0)
-            break;
-        sum += sym->elapsed;
-        double per = 100.0 * sym->elapsed / total;
-        double sum_per = 100.0 * sum / total;
-        double secs = 1.0 * sym->elapsed / kMHz;
-        char *ksym = " ";
-        if (sym->region->flags & region_type::kIsKernelRegion)
-            ksym = "k";
-        printf("%12.2f %11lld %6.2f %6.2f  %s %s\n",
-               secs, sym->elapsed, per, sum_per, ksym, sym->name);
-    }
-    delete[] syms;
-    delete trace;
-
-    return 0;
-}
diff --git a/emulator/qtools/q2dm.cpp b/emulator/qtools/q2dm.cpp
deleted file mode 100644
index 7f987dc..0000000
--- a/emulator/qtools/q2dm.cpp
+++ /dev/null
@@ -1,275 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "bitvector.h"
-#include "parse_options.h"
-#include "dmtrace.h"
-#include "armdis.h"
-
-struct symbol {
-    uint32_t id;
-};
-
-typedef TraceReader<symbol> TraceReaderType;
-
-#include "parse_options-inl.h"
-#include "callstack.h"
-
-DmTrace *dmtrace;
-
-class MyFrame : public StackFrame<symbol_type> {
-  public:
-    void push(int stackLevel, uint64_t time, CallStackBase *base);
-    void pop(int stackLevel, uint64_t time, CallStackBase *base);
-};
-
-typedef CallStack<MyFrame> CallStackType;
-
-static const int kNumStackFrames = 500;
-static const int kMaxThreads = (32 * 1024);
-uint64_t thread_time[kMaxThreads];
-
-class FunctionStack {
-  public:
-    FunctionStack() {
-        top = 0;
-    }
-    void push(symbol_type *sym) {
-        if (top >= kNumStackFrames)
-            return;
-        frames[top] = sym;
-        top += 1;
-    }
-
-    symbol_type* pop() {
-        if (top <= 0) {
-            return NULL;
-        }
-        top -= 1;
-        return frames[top];
-    }
-
-    void showStack() {
-        fprintf(stderr, "top %d\n", top);
-        for (int ii = 0; ii < top; ii++) {
-            fprintf(stderr, "  %d: %s\n", ii, frames[ii]->name);
-        }
-    }
-
-  private:
-    int top;
-    symbol_type *frames[kNumStackFrames];
-};
-
-FunctionStack *dmtrace_stack[kMaxThreads];
-
-void MyFrame::push(int stackLevel, uint64_t time, CallStackBase *base)
-{
-    int pid = base->getId();
-    CallStackType *stack = (CallStackType *) base;
-
-#if 0
-    fprintf(stderr, "native push t %llu p %d s %d fid %d 0x%x %s\n",
-            stack->getGlobalTime(time), pid, stackLevel,
-            function->id, function->addr, function->name);
-#endif
-
-    FunctionStack *fstack = dmtrace_stack[pid];
-    if (fstack == NULL) {
-        fstack = new FunctionStack();
-        dmtrace_stack[pid] = fstack;
-    }
-
-    fstack->push(function);
-    thread_time[pid] = time;
-    dmtrace->addFunctionEntry(function->id, time, pid);
-}
-
-void MyFrame::pop(int stackLevel, uint64_t time, CallStackBase *base)
-{
-    int pid = base->getId();
-    CallStackType *stack = (CallStackType *) base;
-
-#if 0
-    fprintf(stderr, "native pop  t %llu p %d s %d fid %d 0x%x %s\n",
-            stack->getGlobalTime(time), pid, stackLevel,
-            function->id, function->addr, function->name);
-#endif
-
-    FunctionStack *fstack = dmtrace_stack[pid];
-    if (fstack == NULL) {
-        fstack = new FunctionStack();
-        dmtrace_stack[pid] = fstack;
-    }
-
-    symbol_type *sym = fstack->pop();
-    if (sym != NULL && sym != function) {
-        fprintf(stderr, "Error: q2dm function mismatch at time %llu pid %d sym %s\n",
-                stack->getGlobalTime(time), pid, sym->name);
-        fstack->showStack();
-        exit(1);
-    }
-
-    thread_time[pid] = time;
-    dmtrace->addFunctionExit(function->id, time, pid);
-}
-
-uint32_t nextFunctionId = 4;
-CallStackType *stacks[kMaxThreads];
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_name elf_file dmtrace_name\n",
-            program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv)
-{
-    bool useKernelStack = true;
-
-    ParseOptions(argc, argv);
-    if (argc - optind != 3) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *qemu_trace_file = argv[optind++];
-    char *elf_file = argv[optind++];
-    char *dmtrace_file = argv[optind++];
-    TraceReaderType *trace = new TraceReaderType;
-    trace->Open(qemu_trace_file);
-    trace->SetDemangle(demangle);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-    TraceHeader *qheader = trace->GetHeader();
-    uint64_t startTime = qheader->start_sec;
-    startTime = (startTime << 32) | qheader->start_usec;
-    int kernelPid = qheader->first_unused_pid;
-
-    dmtrace = new DmTrace;
-    dmtrace->open(dmtrace_file, startTime);
-
-    bool inKernel = false;
-    CallStackType *kernelStack = NULL;
-    if (useKernelStack) {
-        // Create a fake kernel thread stack where we will put all the kernel
-        // code.
-        kernelStack = new CallStackType(kernelPid, kNumStackFrames, trace);
-        dmtrace->addThread(kernelPid, "(kernel)");
-    }
-
-    CallStackType *prevStack = NULL;
-    BBEvent event;
-    while (1) {
-        BBEvent ignored;
-        symbol_type *function;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &function))
-            break;
-        if (event.bb_num == 0)
-            break;
-#if 0
-        fprintf(stderr, "event t %llu p %d %s\n",
-                event.time, event.pid, function->name);
-#endif
-
-        CallStackType *pStack;
-        if (useKernelStack) {
-            uint32_t flags = function->region->flags;
-            uint32_t region_mask = region_type::kIsKernelRegion
-                    | region_type::kIsUserMappedRegion;
-            if ((flags & region_mask) == region_type::kIsKernelRegion) {
-                // Use the kernel stack
-                pStack = kernelStack;
-                inKernel = true;
-            } else {
-                // If we were just in the kernel then pop off all of the
-                // stack frames for the kernel thread.
-                if (inKernel == true) {
-                    inKernel = false;
-                    kernelStack->popAll(event.time);
-                }
-                
-                // Get the stack for the current thread
-                pStack = stacks[event.pid];
-            }
-        } else {
-            // Get the stack for the current thread
-            pStack = stacks[event.pid];
-        }
-
-        // If the stack does not exist, then allocate a new one.
-        if (pStack == NULL) {
-            pStack = new CallStackType(event.pid, kNumStackFrames, trace);
-            stacks[event.pid] = pStack;
-            char *name = trace->GetProcessName(event.pid);
-            dmtrace->addThread(event.pid, name);
-        }
-
-        if (prevStack != pStack) {
-            pStack->threadStart(event.time);
-            if (prevStack)
-                prevStack->threadStop(event.time);
-        }
-        prevStack = pStack;
-
-        // If we have never seen this function before, then add it to the
-        // list of known functions.
-        if (function->id == 0) {
-            function->id = nextFunctionId;
-            nextFunctionId += 4;
-            uint32_t flags = function->region->flags;
-            const char *name = function->name;
-            if (flags & region_type::kIsKernelRegion) {
-                // To distinguish kernel function names from user library
-                // names, add a marker to the name.
-                int len = strlen(name) + strlen(" [kernel]") + 1;
-                char *kernelName = new char[len];
-                strcpy(kernelName, name);
-                strcat(kernelName, " [kernel]");
-                name = kernelName;
-            }
-            dmtrace->parseAndAddFunction(function->id, name);
-        }
-
-        // Update the stack
-        pStack->updateStack(&event, function);
-    }
-
-    if (prevStack == NULL) {
-        fprintf(stderr, "Error: no events in trace.\n");
-        exit(1);
-    }
-    prevStack->threadStop(event.time);
-    for (int ii = 0; ii < kMaxThreads; ++ii) {
-        if (stacks[ii]) {
-            stacks[ii]->threadStart(event.time);
-            stacks[ii]->popAll(event.time);
-        }
-    }
-    if (useKernelStack) {
-        kernelStack->popAll(event.time);
-    }
-
-    // Read the pid events to find the names of the processes
-    while (1) {
-        PidEvent pid_event;
-        if (trace->ReadPidEvent(&pid_event))
-            break;
-        if (pid_event.rec_type == kPidName) {
-            dmtrace->updateName(pid_event.pid, pid_event.path);
-        }
-    }
-
-
-    dmtrace->close();
-    delete dmtrace;
-    delete trace;
-    return 0;
-}
diff --git a/emulator/qtools/q2g.cpp b/emulator/qtools/q2g.cpp
deleted file mode 100644
index 6b2ae92..0000000
--- a/emulator/qtools/q2g.cpp
+++ /dev/null
@@ -1,108 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "gtrace.h"
-#include "bitvector.h"
-#include "parse_options.h"
-
-struct symbol {
-  int		filenum;	// the file number (for gtrace)
-  int		procnum;	// the procedure number (for gtrace)
-};
-
-typedef TraceReader<symbol> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-const int kMaxProcNum = 4095;
-int next_filenum = 1;
-int next_procnum = 1;
-
-void Usage(const char *program)
-{
-  fprintf(stderr, "Usage: %s [options] trace_file elf_file gtrace_file\n",
-          program);
-  OptionsUsage();
-}
-
-int main(int argc, char **argv)
-{
-  ParseOptions(argc, argv);
-  if (argc - optind != 3) {
-    Usage(argv[0]);
-    exit(1);
-  }
-
-  char *qemu_trace_file = argv[optind++];
-  char *elf_file = argv[optind++];
-  char *gtrace_file = argv[optind++];
-  TraceReader<symbol> *trace = new TraceReader<symbol>;
-  trace->Open(qemu_trace_file);
-  trace->ReadKernelSymbols(elf_file);
-  trace->SetRoot(root);
-  TraceHeader *qheader = trace->GetHeader();
-
-  // Get the first valid event to get the process id for the gtrace header.
-  BBEvent event;
-  BBEvent ignored;
-  symbol_type *sym;
-  if (GetNextValidEvent(trace, &event, &ignored, &sym))
-    return 0;
-
-  Gtrace *gtrace = new Gtrace;
-  gtrace->Open(gtrace_file, qheader->pdate, qheader->ptime);
-  gtrace->WriteFirstHeader(qheader->start_sec, event.pid);
-
-  symbol_type *prev_sym = NULL;
-  bool eof = false;
-  while (!eof) {
-    if (sym != prev_sym) {
-      // This procedure is different from the previous procedure.
-
-      // If we have never seen this symbol before, then add it to the
-      // list of known procedures.
-      if (sym->filenum == 0) {
-        sym->filenum = next_filenum;
-        sym->procnum = next_procnum;
-        gtrace->AddProcedure(sym->filenum, sym->procnum, sym->name);
-        next_procnum += 1;
-        if (next_procnum > kMaxProcNum) {
-          next_filenum += 1;
-          next_procnum = 1;
-        }
-      }
-
-      // If we haven't yet recorded the procedure exit for the previous
-      // procedure, then do it now.
-      if (prev_sym) {
-        gtrace->AddProcExit(prev_sym->filenum, prev_sym->procnum, event.time,
-                            event.pid);
-      }
-
-      // If this is not the terminating record, then record a procedure
-      // entry.
-      if (event.bb_num != 0) {
-        gtrace->AddProcEntry(sym->filenum, sym->procnum, event.time, event.pid);
-        prev_sym = sym;
-      }
-    }
-
-    eof = GetNextValidEvent(trace, &event, &ignored, &sym);
-    if (ignored.time != 0 && prev_sym) {
-      // We read an event that we are ignoring.
-      // If we haven't already recorded a procedure exit, then do so.
-      gtrace->AddProcExit(prev_sym->filenum, prev_sym->procnum, ignored.time,
-                          ignored.pid);
-      prev_sym = NULL;
-    }
-  }
-
-  delete gtrace;
-  delete trace;
-  return 0;
-}
diff --git a/emulator/qtools/read_addr.cpp b/emulator/qtools/read_addr.cpp
deleted file mode 100644
index 38fc62a..0000000
--- a/emulator/qtools/read_addr.cpp
+++ /dev/null
@@ -1,29 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-
-int main(int argc, char **argv) {
-  if (argc != 2) {
-    fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-    exit(1);
-  }
-
-  char *trace_filename = argv[1];
-  TraceReaderBase *trace = new TraceReaderBase;
-  trace->Open(trace_filename);
-
-  while (1) {
-    uint64_t time;
-    uint32_t addr;
-    int flags;
-
-    if (trace->ReadAddr(&time, &addr, &flags))
-      break;
-    char *op = "ld";
-    if (flags == 1)
-        op = "st";
-    printf("%lld 0x%08x %s\n", time, addr, op);
-  }
-  return 0;
-}
diff --git a/emulator/qtools/read_elf.cpp b/emulator/qtools/read_elf.cpp
deleted file mode 100644
index 1d1a74a..0000000
--- a/emulator/qtools/read_elf.cpp
+++ /dev/null
@@ -1,210 +0,0 @@
-/*************************************************************************
-    Copyright (C) 2002,2003,2004,2005 Wei Qin
-    See file COPYING for more information.
-
-    This program is free software; you can redistribute it and/or modify    
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-*************************************************************************/
-
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-#include <assert.h>
-#include "read_elf.h"
-
-#define SwapHalf(a) (((a & 0x00ff) << 8) | ((a & 0xff00) >> 8))
-#define SwapWord(a) (((a & 0xff000000) >> 24) | ((a & 0x00ff0000) >> 8) | ((a & 0x0000ff00) << 8) | ((a & 0x000000ff) << 24))
-#define SwapAddr(a) SwapWord(a)
-#define SwapOff(a) SwapWord(a)
-#define SwapSection(a) SwapHalf(a)
-
-int LittleEndian()
-{
-  Elf32_Word a = 0x01020304;
-  return *(char *) &a == 0x04;
-}
-
-void SwapElfHeader(Elf32_Ehdr *hdr)
-{
-  hdr->e_type = SwapHalf(hdr->e_type);
-  hdr->e_machine = SwapHalf(hdr->e_machine);
-  hdr->e_version = SwapWord(hdr->e_version);
-  hdr->e_entry = SwapAddr(hdr->e_entry);
-  hdr->e_phoff = SwapOff(hdr->e_phoff);
-  hdr->e_shoff = SwapOff(hdr->e_shoff);
-  hdr->e_flags = SwapWord(hdr->e_flags);
-  hdr->e_ehsize = SwapHalf(hdr->e_ehsize);
-  hdr->e_phentsize = SwapHalf(hdr->e_phentsize);
-  hdr->e_phnum = SwapHalf(hdr->e_phnum);
-  hdr->e_shentsize = SwapHalf(hdr->e_shentsize);
-  hdr->e_shnum = SwapHalf(hdr->e_shnum);
-  hdr->e_shstrndx = SwapHalf(hdr->e_shstrndx);
-}
-
-void SwapSectionHeader(Elf32_Shdr *shdr)
-{
-  shdr->sh_name = SwapWord(shdr->sh_name);
-  shdr->sh_type = SwapWord(shdr->sh_type);
-  shdr->sh_flags = SwapWord(shdr->sh_flags);
-  shdr->sh_addr = SwapAddr(shdr->sh_addr);
-  shdr->sh_offset = SwapOff(shdr->sh_offset);
-  shdr->sh_size = SwapWord(shdr->sh_size);
-  shdr->sh_link = SwapWord(shdr->sh_link);
-  shdr->sh_info = SwapWord(shdr->sh_info);
-  shdr->sh_addralign = SwapWord(shdr->sh_addralign);
-  shdr->sh_entsize = SwapWord(shdr->sh_entsize);
-}
-
-void SwapElfSymbol(Elf32_Sym *sym)
-{
-    sym->st_name = SwapWord(sym->st_name);
-    sym->st_value = SwapAddr(sym->st_value);
-    sym->st_size = SwapWord(sym->st_size);
-    sym->st_shndx = SwapSection(sym->st_shndx);
-}
-
-void AdjustElfHeader(Elf32_Ehdr *hdr)
-{
-  switch(hdr->e_ident[EI_DATA])
-  {
-    case ELFDATA2LSB:
-      if (!LittleEndian())
-        SwapElfHeader(hdr);
-      break;
-    case ELFDATA2MSB:
-      if (LittleEndian())
-        SwapElfHeader(hdr);
-      break;
-  }
-}
-
-void AdjustSectionHeader(Elf32_Ehdr *hdr, Elf32_Shdr *shdr)
-{
-  switch(hdr->e_ident[EI_DATA])
-  {
-    case ELFDATA2LSB:
-      if (!LittleEndian())
-        SwapSectionHeader(shdr);
-      break;
-    case ELFDATA2MSB:
-      if (LittleEndian())
-        SwapSectionHeader(shdr);
-      break;
-  }
-}
-
-void AdjustElfSymbols(Elf32_Ehdr *hdr, Elf32_Sym *elf_symbols, int num_entries)
-{
-    if (hdr->e_ident[EI_DATA] == ELFDATA2LSB && LittleEndian())
-        return;
-    if (hdr->e_ident[EI_DATA] == ELFDATA2MSB && !LittleEndian())
-        return;
-    for (int ii = 0; ii < num_entries; ++ii) {
-        SwapElfSymbol(&elf_symbols[ii]);
-    }
-}
-
-Elf32_Ehdr *ReadElfHeader(FILE *fobj)
-{
-  Elf32_Ehdr *hdr = new Elf32_Ehdr;
-  int rval = fread(hdr, sizeof(Elf32_Ehdr), 1, fobj);
-  if (rval != 1) {
-    delete hdr;
-    return NULL;
-  }
-  if (hdr->e_ident[EI_MAG0] != 0x7f || hdr->e_ident[EI_MAG1] != 'E' ||
-      hdr->e_ident[EI_MAG2] != 'L' || hdr->e_ident[EI_MAG3] != 'F') {
-    delete hdr;
-    return NULL;
-  }
-  AdjustElfHeader(hdr);
-  return hdr;
-}
-
-Elf32_Shdr *ReadSectionHeaders(Elf32_Ehdr *hdr, FILE *f)
-{
-  int i;
-  unsigned long sz = hdr->e_shnum * hdr->e_shentsize;
-  assert(sizeof(Elf32_Shdr) == hdr->e_shentsize);
-  Elf32_Shdr *shdr = new Elf32_Shdr[hdr->e_shnum];
-
-  if (fseek(f, hdr->e_shoff, SEEK_SET) != 0)
-  {
-    delete[] shdr;
-    return NULL;
-  }
-  if (fread(shdr, sz, 1, f) != 1)
-  {
-    delete[] shdr;
-    return NULL;
-  }
-
-  for(i = 0; i < hdr->e_shnum; i++)
-    AdjustSectionHeader(hdr, shdr + i);
-
-  return shdr;
-}
-
-
-char *ReadStringTable(Elf32_Ehdr *hdr, Elf32_Shdr *shdr_table, FILE *f)
-{
-  Elf32_Shdr *shdr = shdr_table + hdr->e_shstrndx;
-  char *string_table;
-
-  string_table = new char[shdr->sh_size];
-  fseek(f, shdr->sh_offset, SEEK_SET);
-  fread(string_table, shdr->sh_size, 1, f);
-
-  return string_table;
-}
-
-int ReadSection(Elf32_Shdr *shdr, void *buffer, FILE *f)
-{
-  if (fseek(f, shdr->sh_offset, SEEK_SET) != 0)
-    return -1;
-  if (fread(buffer, shdr->sh_size, 1, f) != 1)
-    return -1;
-  return 0;
-}
-
-char *GetSymbolName(Elf32_Half index, char *string_table)
-{
-  return string_table + index;
-}
-
-Elf32_Shdr *FindSymbolTableSection(Elf32_Ehdr *hdr,
-                                   Elf32_Shdr *shdr,
-                                   char *string_table)
-{
-  for(int ii = 0; ii < hdr->e_shnum; ii++) {
-    if (shdr[ii].sh_type == SHT_SYMTAB &&
-       strcmp(GetSymbolName(shdr[ii].sh_name, string_table),
-              ".symtab") == 0)
-    {
-      return &shdr[ii];
-    }
-  }
-  return NULL;
-}
-
-Elf32_Shdr *FindSymbolStringTableSection(Elf32_Ehdr *hdr,
-                                         Elf32_Shdr *shdr,
-                                         char *string_table)
-{
-  for(int ii = 0; ii < hdr->e_shnum; ii++) {
-    if (shdr[ii].sh_type == SHT_STRTAB &&
-       strcmp(GetSymbolName(shdr[ii].sh_name, string_table),
-              ".strtab") == 0)
-    {
-      return &shdr[ii];
-    }
-  }
-  return NULL;
-}
diff --git a/emulator/qtools/read_elf.h b/emulator/qtools/read_elf.h
deleted file mode 100644
index 72266c3..0000000
--- a/emulator/qtools/read_elf.h
+++ /dev/null
@@ -1,20 +0,0 @@
-#ifndef READ_ELF_H
-#define READ_ELF_H
-
-#include <stdio.h>
-#include <elf.h>
-
-Elf32_Ehdr *ReadElfHeader(FILE *fobj);
-Elf32_Shdr *ReadSectionHeaders(Elf32_Ehdr *hdr, FILE *fobj);
-char *ReadStringTable(Elf32_Ehdr *hdr, Elf32_Shdr *shdr, FILE *fobj);
-Elf32_Shdr *FindSymbolTableSection(Elf32_Ehdr *hdr,
-                                   Elf32_Shdr *shdr,
-                                   char *string_table);
-Elf32_Shdr *FindSymbolStringTableSection(Elf32_Ehdr *hdr,
-                                         Elf32_Shdr *shdr,
-                                         char *string_table);
-int ReadSection(Elf32_Shdr *shdr, void *buffer, FILE *f);
-void AdjustElfSymbols(Elf32_Ehdr *hdr, Elf32_Sym *elf_symbols,
-                      int num_entries);
-
-#endif /* READ_ELF_H */
diff --git a/emulator/qtools/read_method.cpp b/emulator/qtools/read_method.cpp
deleted file mode 100644
index e48edad..0000000
--- a/emulator/qtools/read_method.cpp
+++ /dev/null
@@ -1,52 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_name elf_file\n",
-            program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv) {
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *qemu_trace_file = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReaderType *trace = new TraceReaderType;
-    trace->Open(qemu_trace_file);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    while (1) {
-        MethodRec method_record;
-        symbol_type *sym;
-        TraceReaderType::ProcessState *proc;
-
-        if (trace->ReadMethodSymbol(&method_record, &sym, &proc))
-            break;
-        if (sym != NULL) {
-            printf("%lld p %d 0x%x %d %s\n",
-                   method_record.time, proc->pid, method_record.addr,
-                   method_record.flags, sym->name);
-        } else {
-            printf("%lld p %d 0x%x %d\n",
-                   method_record.time, proc->pid, method_record.addr,
-                   method_record.flags);
-        }
-        proc->DumpStack();
-    }
-    return 0;
-}
diff --git a/emulator/qtools/read_pid.cpp b/emulator/qtools/read_pid.cpp
deleted file mode 100644
index a2d69d4..0000000
--- a/emulator/qtools/read_pid.cpp
+++ /dev/null
@@ -1,71 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include "trace_reader.h"
-
-int main(int argc, char **argv) {
-  if (argc != 2) {
-    fprintf(stderr, "Usage: %s trace_file\n", argv[0]);
-    exit(1);
-  }
-
-  char *trace_filename = argv[1];
-  TraceReaderBase *trace = new TraceReaderBase;
-  trace->Open(trace_filename);
-
-  while (1) {
-    PidEvent event;
-    if (trace->ReadPidEvent(&event))
-      break;
-    switch (event.rec_type) {
-      case kPidFork:
-        printf("t%lld fork tgid %d pid %d\n", event.time, event.tgid, event.pid);
-        break;
-      case kPidClone:
-        printf("t%lld clone tgid %d pid %d\n", event.time, event.tgid, event.pid);
-        break;
-      case kPidSwitch:
-        printf("t%lld switch %d\n", event.time, event.pid);
-        break;
-      case kPidExit:
-        printf("t%lld exit %d\n", event.time, event.pid);
-        break;
-      case kPidMmap:
-        printf("t%lld mmap %08x - %08x, offset %08x '%s'\n",
-               event.time, event.vstart, event.vend, event.offset, event.path);
-        delete[] event.path;
-        break;
-      case kPidMunmap:
-        printf("t%lld munmap %08x - %08x\n",
-               event.time, event.vstart, event.vend);
-        break;
-      case kPidSymbolAdd:
-        printf("t%lld add sym %08x '%s'\n",
-               event.time, event.vstart, event.path);
-        delete[] event.path;
-        break;
-      case kPidSymbolRemove:
-        printf("t%lld remove %08x\n", event.time, event.vstart);
-        break;
-      case kPidExec:
-        printf("t%lld argc: %d\n", event.time, event.argc);
-        for (int ii = 0; ii < event.argc; ++ii) {
-          printf("  argv[%d]: %s\n", ii, event.argv[ii]);
-          delete[] event.argv[ii];
-        }
-        delete[] event.argv;
-        break;
-      case kPidKthreadName:
-        printf("t%lld kthread tgid %d pid %d %s\n",
-               event.time, event.tgid, event.pid, event.path);
-        delete[] event.path;
-        break;
-      case kPidName:
-        printf("t%lld name %d %s\n",
-               event.time, event.pid, event.path);
-        delete[] event.path;
-        break;
-    }
-  }
-  return 0;
-}
diff --git a/emulator/qtools/read_trace.cpp b/emulator/qtools/read_trace.cpp
deleted file mode 100644
index fb4917c..0000000
--- a/emulator/qtools/read_trace.cpp
+++ /dev/null
@@ -1,165 +0,0 @@
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "armdis.h"
-#include "parse_options.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-
-static const uint32_t kOffsetThreshold = 0x100000;
-static uint64_t startTime = 0;
-
-void Usage(const char *program)
-{
-    fprintf(stderr,
-            "Usage: %s [options] [-- -s start_time] trace_file elf_file\n",
-            program);
-    OptionsUsage();
-}
-
-
-bool localParseOptions(int argc, char **argv)
-{
-    bool err = false;
-    while (!err) {
-        int opt = getopt(argc, argv, "+s:");
-        if (opt == -1)
-            break;
-        switch (opt) {
-        case 's':
-            startTime = strtoull(optarg, NULL, 0);
-            break;
-        default:
-            err = true;
-            break;
-        }
-    }
-    return err;
-}
-
-int main(int argc, char **argv) {
-    // Parse the options
-    ParseOptions(argc, argv);
-    localParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *trace_filename = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReader<> *trace = new TraceReader<>;
-    trace->Open(trace_filename);
-    trace->SetDemangle(demangle);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-
-    while (1) {
-        symbol_type *sym;
-        char buf[1024];
-        BBEvent event;
-        BBEvent ignored;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &sym))
-            break;
-#if 0
-        fprintf(stderr, "t%llu bb %lld %d\n",
-                event.time, event.bb_num, event.num_insns);
-#endif
-
-        uint32_t *insns = event.insns;
-        uint32_t addr = event.bb_addr;
-        uint32_t offset = addr - sym->addr - sym->region->base_addr;
-        symbol_type *vm_sym = sym->vm_sym;
-        const char *vm_name = NULL;
-        if (vm_sym != NULL) {
-            vm_name = vm_sym->name;
-            offset = addr - vm_sym->addr - vm_sym->region->base_addr;
-        }
-#if 0
-        if (strcmp(sym->name, "(unknown)") == 0 || offset > kOffsetThreshold) {
-            ProcessState *process = trace->GetCurrentProcess();
-            ProcessState *manager = process->addr_manager;
-            for (int ii = 0; ii < manager->nregions; ++ii) {
-                printf("  %2d: %08x - %08x base: %08x offset: %u nsyms: %4d flags: 0x%x %s\n",
-                       ii,
-                       manager->regions[ii]->vstart,
-                       manager->regions[ii]->vend,
-                       manager->regions[ii]->base_addr,
-                       manager->regions[ii]->file_offset,
-                       manager->regions[ii]->nsymbols,
-                       manager->regions[ii]->flags,
-                       manager->regions[ii]->path);
-                int nsymbols = manager->regions[ii]->nsymbols;
-                for (int jj = 0; jj < 10 && jj < nsymbols; ++jj) {
-                    printf("    %08x %s\n",
-                           manager->regions[ii]->symbols[jj].addr,
-                           manager->regions[ii]->symbols[jj].name);
-                }
-            }
-        }
-#endif
-#if 1
-        for (int ii = 0; ii < event.num_insns; ++ii) {
-            uint64_t sim_time = trace->ReadInsnTime(event.time);
-            if (sim_time < startTime)
-                continue;
-
-            uint32_t insn = insns[ii];
-            char *disasm;
-            int bytes;
-            if (vm_name != NULL) {
-                sprintf(buf, "%s+%02x: %s", vm_name, offset, sym->name);
-            } else {
-                sprintf(buf, "%s+%02x", sym->name, offset);
-            }
-
-            if (insn_is_thumb(insn)) {
-                bytes = 2;
-                insn = insn_unwrap_thumb(insn);
-
-                // thumb_pair is true if this is the first of a pair of
-                // thumb instructions (BL or BLX).
-                bool thumb_pair = ((insn & 0xf800) == 0xf000);
-
-                // Get the next thumb instruction (if any) because we may need
-                // it for the case where insn is BL or BLX.
-                uint32_t insn2 = 0;
-                if (thumb_pair && (ii + 1 < event.num_insns)) {
-                    insn2 = insns[ii + 1];
-                    insn2 = insn_unwrap_thumb(insn2);
-                    bytes = 4;
-                    ii += 1;
-                }
-                disasm = disasm_insn_thumb(addr, insn, insn2, NULL);
-                if (thumb_pair) {
-                    printf("%llu p%-4d %08x %04x %04x %-30s %s\n",
-                           sim_time, event.pid, addr, insn, insn2, buf, disasm);
-                } else {
-                    printf("%llu p%-4d %08x     %04x %-30s %s\n",
-                           sim_time, event.pid, addr, insn, buf, disasm);
-                }
-            } else {
-                bytes = 4;
-                disasm = Arm::disasm(addr, insn, NULL);
-                printf("%llu p%-4d %08x %08x %-30s %s\n",
-                       sim_time, event.pid, addr, insn, buf, disasm);
-            }
-            //printf("t%llu \t%08x\n", sim_time, addr);
-            addr += bytes;
-            offset += bytes;
-        }
-#endif
-#if 0
-        assert(offset < kOffsetThreshold);
-#endif
-    }
-
-    delete trace;
-    return 0;
-}
diff --git a/emulator/qtools/stack_dump.cpp b/emulator/qtools/stack_dump.cpp
deleted file mode 100644
index b5014ef..0000000
--- a/emulator/qtools/stack_dump.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <assert.h>
-#include "trace_reader.h"
-#include "bitvector.h"
-#include "parse_options.h"
-#include "armdis.h"
-
-typedef TraceReader<> TraceReaderType;
-
-#include "parse_options-inl.h"
-#include "callstack.h"
-
-class MyFrame : public StackFrame<symbol_type> {
-  public:
-    void    push(int stackLevel, uint64_t time, CallStackBase *base);
-    void    pop(int stackLevel, uint64_t time, CallStackBase *base);
-};
-
-typedef CallStack<MyFrame> CallStackType;
-
-void MyFrame::push(int stackLevel, uint64_t time, CallStackBase *base)
-{
-    printf("%llu en thr %d %3d", time, base->getId(), stackLevel);
-    for (int ii = 0; ii < stackLevel; ++ii)
-        printf(".");
-    printf(" 0x%08x %s\n", addr, function->name);
-}
-
-void MyFrame::pop(int stackLevel, uint64_t time, CallStackBase *base)
-{
-    printf("%llu x  thr %d %3d", time, base->getId(), stackLevel);
-    for (int ii = 0; ii < stackLevel; ++ii)
-        printf(".");
-    printf(" 0x%08x %s\n", addr, function->name);
-}
-
-static const int kNumStackFrames = 500;
-static const int kMaxThreads = (32 * 1024);
-CallStackType *stacks[kMaxThreads];
-
-static uint64_t debugTime;
-
-void Usage(const char *program)
-{
-    fprintf(stderr, "Usage: %s [options] trace_name elf_file\n",
-            program);
-    OptionsUsage();
-}
-
-int main(int argc, char **argv)
-{
-    ParseOptions(argc, argv);
-    if (argc - optind != 2) {
-        Usage(argv[0]);
-        exit(1);
-    }
-
-    char *qemu_trace_file = argv[optind++];
-    char *elf_file = argv[optind++];
-    TraceReaderType *trace = new TraceReaderType;
-    trace->Open(qemu_trace_file);
-    trace->ReadKernelSymbols(elf_file);
-    trace->SetRoot(root);
-    TraceHeader *qheader = trace->GetHeader();
-    uint64_t startTime = qheader->start_sec;
-    startTime = (startTime << 32) | qheader->start_usec;
-
-    BBEvent event;
-    while (1) {
-        BBEvent ignored;
-        symbol_type *function;
-
-        if (GetNextValidEvent(trace, &event, &ignored, &function))
-            break;
-        if (event.bb_num == 0)
-            break;
-
-        // Get the stack for the current thread
-        CallStackType *pStack = stacks[event.pid];
-
-        // If the stack does not exist, then allocate a new one.
-        if (pStack == NULL) {
-            pStack = new CallStackType(event.pid, kNumStackFrames, trace);
-            stacks[event.pid] = pStack;
-        }
-        if (debugTime != 0 && event.time >= debugTime)
-            printf("debug time: %lld\n", debugTime);
-
-        // Update the stack
-        pStack->updateStack(&event, function);
-    }
-
-    for (int ii = 0; ii < kMaxThreads; ++ii) {
-        if (stacks[ii])
-            stacks[ii]->popAll(event.time);
-    }
-
-    delete trace;
-    return 0;
-}
diff --git a/emulator/qtools/tests/common_head.mk b/emulator/qtools/tests/common_head.mk
deleted file mode 100644
index e8170e9..0000000
--- a/emulator/qtools/tests/common_head.mk
+++ /dev/null
@@ -1,25 +0,0 @@
-CC := arm-elf-gcc
-LD := arm-elf-ld
-AS := arm-elf-as
-OBJCOPY := arm-elf-objcopy
-OBJDUMP := arm-elf-objdump
-
-OPT := -g
-CFLAGS := $(OPT) -mcpu=arm9
-
-.SUFFIXES: .dis .bin .elf
-
-.c.elf:
-	$(CC) $(CFLAGS)  -Xlinker --script ../tests.ld -o $@ $< -nostdlib
-
-.c.s:
-	$(CC) $(CFLAGS) -static -S $<
-
-.S.elf:
-	$(CC) $(CFLAGS) -Xlinker --script ../tests.ld -nostdlib -o $@ $<
-
-.elf.dis:
-	$(OBJDUMP) -adx $< > $@
-
-.elf.bin:
-	$(OBJCOPY) -O binary $< $@
diff --git a/emulator/qtools/tests/common_tail.mk b/emulator/qtools/tests/common_tail.mk
deleted file mode 100644
index be1c141..0000000
--- a/emulator/qtools/tests/common_tail.mk
+++ /dev/null
@@ -1,3 +0,0 @@
-
-clean:
-	rm -f *.elf *.dis *.bin *.o *~ a.out
diff --git a/emulator/qtools/tests/gtrace/Makefile b/emulator/qtools/tests/gtrace/Makefile
deleted file mode 100644
index 1d2050c..0000000
--- a/emulator/qtools/tests/gtrace/Makefile
+++ /dev/null
@@ -1,18 +0,0 @@
-include ../common_head.mk
-
-P4ROOT=/work/android
-QEMU=$(P4ROOT)/device/tools/qemu/arm-softmmu/qemu-system-arm
-QTOOLS=$(P4ROOT)/device/tools/qtools
-
-all: test.elf test.bin test.dis
-
-trace: test.elf test.bin
-	$(QEMU) -QEMU -kernel test.bin -trace foo
-	$(QTOOLS)/post_trace foo
-	$(QTOOLS)/read_trace foo test.elf > t1
-
-gtrace: trace
-	$(QTOOLS)/q2g -r $(P4ROOT)/device/out/linux-arm-release/symbols foo test.elf foo.gtrace
-	gtracepost64 foo.gtrace > t2
-
-include ../common_tail.mk
diff --git a/emulator/qtools/tests/gtrace/test.c b/emulator/qtools/tests/gtrace/test.c
deleted file mode 100644
index e56a0f1..0000000
--- a/emulator/qtools/tests/gtrace/test.c
+++ /dev/null
@@ -1,201 +0,0 @@
-#include "../macros.h"
-
-int foo1();
-int foo2();
-void bar();
-int child1();
-int child2();
-int child3();
-int child4();
-int child5();
-
-int global;
-
-void start()
-{
-  // Set the stack pointer
-  asm("  mov r13,#0x200000");
-  PRINT_STR("hello\n");
-  TRACE_INIT_NAME(701, "proc_foo");
-  TRACE_INIT_NAME(702, "proc_bar");
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-  TRACE_SWITCH(702);
-  if (global++ > 0)
-      global++;
-  bar();
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo2();
-  TRACE_SWITCH(703);
-  if (global++ > 0)
-      global++;
-  foo1();
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(704);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(705);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(706);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(707);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(708);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(709);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(701);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_SWITCH(710);
-  if (global++ > 0)
-      global++;
-  foo1();
-
-  TRACE_STOP_EMU();
-}
-
-int foo1()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 3; ++ii) {
-    a += child1();
-    a += child2();
-    a += child3();
-  }
-  return a;
-}
-
-int foo2()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 2; ++ii) {
-    a += child3();
-    a += child4();
-    a += child5();
-  }
-  return a;
-}
-
-#define kStride 64
-void bar()
-{
-  int a = 0;
-
-  static char mem[1000 * kStride];
-
-  int ii, jj;
-
-  for (ii = 0; ii < 4; ++ii) {
-    for (jj = 0; jj < 10; ++jj)
-      a += mem[jj * kStride];
-    foo1();
-    foo2();
-  }
-}
-
-int child1()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 2; ++ii)
-    a += ii;
-  return a;
-}
-
-int child2()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 4; ++ii)
-    a += ii;
-  return a;
-}
-
-int child3()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 6; ++ii)
-    a += ii;
-  return a;
-}
-
-int child4()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 8; ++ii)
-    a += ii;
-  return a;
-}
-
-int child5()
-{
-  int a = 0;
-
-  int ii;
-  for (ii = 0; ii < 10; ++ii)
-    a += ii;
-  return a;
-}
diff --git a/emulator/qtools/tests/macros.h b/emulator/qtools/tests/macros.h
deleted file mode 100644
index 066374b..0000000
--- a/emulator/qtools/tests/macros.h
+++ /dev/null
@@ -1,93 +0,0 @@
-#ifndef _TEST_TRACE_C_H_
-#define _TEST_TRACE_C_H_
-
-/* the base address of trace device */
-#define TRACE_DEV_BASE_ADDR             0x21000000
-
-/*the register addresses of the trace device */
-#define TRACE_DEV_REG_SWITCH            0
-#define TRACE_DEV_REG_FORK              1
-#define TRACE_DEV_REG_EXECVE_PID        2
-#define TRACE_DEV_REG_EXECVE_VMSTART    3
-#define TRACE_DEV_REG_EXECVE_VMEND      4
-#define TRACE_DEV_REG_EXECVE_OFFSET     5
-#define TRACE_DEV_REG_EXECVE_EXEPATH    6
-#define TRACE_DEV_REG_EXIT              7
-#define TRACE_DEV_REG_CMDLINE           8
-#define TRACE_DEV_REG_CMDLINE_LEN       9
-#define TRACE_DEV_REG_MMAP_EXEPATH      10
-#define TRACE_DEV_REG_INIT_PID          11
-#define TRACE_DEV_REG_INIT_NAME         12
-#define TRACE_DEV_REG_CLONE             13
-#define TRACE_DEV_REG_DYN_SYM           50
-#define TRACE_DEV_REG_DYN_SYM_ADDR      51
-#define TRACE_DEV_REG_PRINT_STR         60
-#define TRACE_DEV_REG_PRINT_NUM_DEC     61
-#define TRACE_DEV_REG_PRINT_NUM_HEX     62
-#define TRACE_DEV_REG_STOP_EMU          90
-#define TRACE_DEV_REG_ENABLE            100
-#define TRACE_DEV_REG_DISABLE           101
-
-/* write a word to a trace device register */
-#define DEV_WRITE_WORD(addr,value)\
-    (*(volatile unsigned long *)(TRACE_DEV_BASE_ADDR + ((addr) << 2)) = (value))
-
-/*************************************************************/
-/* generates test events */
-
-/* context switch */
-#define TRACE_SWITCH(pid)            DEV_WRITE_WORD(TRACE_DEV_REG_SWITCH, (pid))
-/* fork */
-#define TRACE_FORK(pid)              DEV_WRITE_WORD(TRACE_DEV_REG_FORK, (pid))
-/* clone */
-#define TRACE_CLONE(pid)             DEV_WRITE_WORD(TRACE_DEV_REG_CLONE, (pid))
-/* dump name and path of threads executed before trace device created */
-#define TRACE_INIT_NAME(pid,path)\
-do {\
-    DEV_WRITE_WORD(TRACE_DEV_REG_INIT_PID, (pid));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_INIT_NAME, (unsigned long)(path));\
-}while(0)
-/* dump exec mapping of threads executed before trace device created */
-#define TRACE_INIT_EXEC(vstart,vend,eoff,path)\
-do {\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_VMSTART, (vstart));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_VMEND, (vend));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_OFFSET, (eoff));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_EXEPATH, (unsigned long)(path));\
-}while(0)
-/* mmap */
-#define TRACE_MMAP(vstart,vend,eoff,path)\
-do {\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_VMSTART, (vstart));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_VMEND, (vend));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_EXECVE_OFFSET, (eoff));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_MMAP_EXEPATH, (unsigned long)(path));\
-}while(0)
-/* execve */
-#define TRACE_EXECVE(cmdlen,cmd)\
-do {\
-    DEV_WRITE_WORD(TRACE_DEV_REG_CMDLINE_LEN, (cmdlen));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_CMDLINE, (unsigned long)(cmd));\
-}while(0)
-/* exit */
-#define TRACE_EXIT(retv)             DEV_WRITE_WORD(TRACE_DEV_REG_EXIT, (retv))
-
-/* other commands */
-
-/* stop emulation */
-#define TRACE_STOP_EMU()             DEV_WRITE_WORD(TRACE_DEV_REG_STOP_EMU, 1)
-/* enable/disable tracing */
-#define TRACE_ENABLE_TRACING()       DEV_WRITE_WORD(TRACE_DEV_REG_ENABLE, 1)
-#define TRACE_DISABLE_TRACING()      DEV_WRITE_WORD(TRACE_DEV_REG_DISABLE, 1)
-/* dynamic symbols */
-#define TRACE_DYN_SYM(addr,sym)\
-do {\
-    DEV_WRITE_WORD(TRACE_DEV_REG_DYN_SYM_ADDR, (addr));\
-    DEV_WRITE_WORD(TRACE_DEV_REG_DYN_SYM, (unsigned long)(sym));\
-}while(0)
-/* prints */
-#define PRINT_STR(str)         DEV_WRITE_WORD(TRACE_DEV_REG_PRINT_STR, (unsigned long)(str))
-#define PRINT_NUM_DEC(num)     DEV_WRITE_WORD(TRACE_DEV_REG_PRINT_NUM_DEC, (num))
-#define PRINT_NUM_HEX(num)     DEV_WRITE_WORD(TRACE_DEV_REG_PRINT_NUM_HEX, (num))
-
-#endif
diff --git a/emulator/qtools/tests/tests.ld b/emulator/qtools/tests/tests.ld
deleted file mode 100644
index 05fe41b..0000000
--- a/emulator/qtools/tests/tests.ld
+++ /dev/null
@@ -1,10 +0,0 @@
-SECTIONS {
-  TEXT_START = 0x00010000 ;
-  DATA_START = 0x00200000 ;
-  handlers 0x0 : { *(handlers) }
-  .text TEXT_START : { *(.text) }
-  .data DATA_START : { *(.data) }
-  .bss  : { *(.bss) *(COMMON) }
-  p00300000 0x00300000 : { *(p00300000) }
-  p00400000 0x00400000 : { *(p00400000) }
-}
diff --git a/emulator/qtools/thumbdis.cpp b/emulator/qtools/thumbdis.cpp
deleted file mode 100644
index f4294dd..0000000
--- a/emulator/qtools/thumbdis.cpp
+++ /dev/null
@@ -1,503 +0,0 @@
-/* Instruction printing code for the ARM
-   Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
-   Free Software Foundation, Inc.
-   Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
-   Modification by James G. Smith (jsmith@cygnus.co.uk)
-
-This file is part of libopcodes. 
-
-This program is free software; you can redistribute it and/or modify it under
-the terms of the GNU General Public License as published by the Free
-Software Foundation; either version 2 of the License, or (at your option)
-any later version. 
-
-This program is distributed in the hope that it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
-more details. 
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-/* Modified to fit into the qtools framework.  The main differences are:
- *
- * - The disassembly function returns a string instead of writing it to a
- * file stream.
- *
- * - All the references to the struct "disassemble_info" have been removed.
- *
- * - A set of enums for the thumb opcodes have been defined, along with a
- * "decode()" function that maps a thumb instruction to an opcode enum.
- *
- * - Eliminated uses of the special characters ', `, and ? from the
- * thumb_opcodes[] table so that we can easily specify separate opcodes
- * for distinct instructions.
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <inttypes.h>
-#include "opcode.h"
-
-
-struct thumb_opcode
-{
-    unsigned short value, mask;  /* recognise instruction if (op&mask)==value */
-    Opcode opcode;
-    char * assembler;            /* how to disassemble this instruction */
-};
-
-/* format of the assembler string :
-   
-   %%                   %
-   %<bitfield>d         print the bitfield in decimal
-   %<bitfield>x         print the bitfield in hex
-   %<bitfield>X         print the bitfield as 1 hex digit without leading "0x"
-   %<bitfield>r         print as an ARM register
-   %<bitfield>f         print a floating point constant if >7 else a
-                          floating point register
-   %<code>y             print a single precision VFP reg.
-                          Codes: 0=>Sm, 1=>Sd, 2=>Sn, 3=>multi-list, 4=>Sm pair
-   %<code>z             print a double precision VFP reg
-                          Codes: 0=>Dm, 1=>Dd, 2=>Dn, 3=>multi-list
-   %c                   print condition code (always bits 28-31)
-   %P                   print floating point precision in arithmetic insn
-   %Q                   print floating point precision in ldf/stf insn
-   %R                   print floating point rounding mode
-   %<bitnum>'c          print specified char iff bit is one
-   %<bitnum>`c          print specified char iff bit is zero
-   %<bitnum>?ab         print a if bit is one else print b
-   %p                   print 'p' iff bits 12-15 are 15
-   %t                   print 't' iff bit 21 set and bit 24 clear
-   %o                   print operand2 (immediate or register + shift)
-   %a                   print address for ldr/str instruction
-   %s                   print address for ldr/str halfword/signextend instruction
-   %b                   print branch destination
-   %B                   print arm BLX(1) destination
-   %A                   print address for ldc/stc/ldf/stf instruction
-   %m                   print register mask for ldm/stm instruction
-   %C                   print the PSR sub type.
-   %F                   print the COUNT field of a LFM/SFM instruction.
-Thumb specific format options:
-   %D                   print Thumb register (bits 0..2 as high number if bit 7 set)
-   %S                   print Thumb register (bits 3..5 as high number if bit 6 set)
-   %<bitfield>I         print bitfield as a signed decimal
-                          (top bit of range being the sign bit)
-   %M                   print Thumb register mask
-   %N                   print Thumb register mask (with LR)
-   %O                   print Thumb register mask (with PC)
-   %T                   print Thumb condition code (always bits 8-11)
-   %I                   print cirrus signed shift immediate: bits 0..3|4..6
-   %<bitfield>B         print Thumb branch destination (signed displacement)
-   %<bitfield>W         print (bitfield * 4) as a decimal
-   %<bitfield>H         print (bitfield * 2) as a decimal
-   %<bitfield>a         print (bitfield * 4) as a pc-rel offset + decoded symbol
-*/
-
-
-static struct thumb_opcode thumb_opcodes[] =
-{
-    /* Thumb instructions.  */
-
-    /* ARM V5 ISA extends Thumb.  */
-    {0xbe00, 0xff00, OP_THUMB_BKPT, "bkpt\t%0-7x"},
-    {0x4780, 0xff87, OP_THUMB_BLX, "blx\t%3-6r"},  /* note: 4 bit register number.  */
-    /* Format 5 instructions do not update the PSR.  */
-    {0x1C00, 0xFFC0, OP_THUMB_MOV, "mov\t%0-2r, %3-5r"},
-    /* Format 4.  */
-    {0x4000, 0xFFC0, OP_THUMB_AND, "and\t%0-2r, %3-5r"},
-    {0x4040, 0xFFC0, OP_THUMB_EOR, "eor\t%0-2r, %3-5r"},
-    {0x4080, 0xFFC0, OP_THUMB_LSL, "lsl\t%0-2r, %3-5r"},
-    {0x40C0, 0xFFC0, OP_THUMB_LSR, "lsr\t%0-2r, %3-5r"},
-    {0x4100, 0xFFC0, OP_THUMB_ASR, "asr\t%0-2r, %3-5r"},
-    {0x4140, 0xFFC0, OP_THUMB_ADC, "adc\t%0-2r, %3-5r"},
-    {0x4180, 0xFFC0, OP_THUMB_SBC, "sbc\t%0-2r, %3-5r"},
-    {0x41C0, 0xFFC0, OP_THUMB_ROR, "ror\t%0-2r, %3-5r"},
-    {0x4200, 0xFFC0, OP_THUMB_TST, "tst\t%0-2r, %3-5r"},
-    {0x4240, 0xFFC0, OP_THUMB_NEG, "neg\t%0-2r, %3-5r"},
-    {0x4280, 0xFFC0, OP_THUMB_CMP, "cmp\t%0-2r, %3-5r"},
-    {0x42C0, 0xFFC0, OP_THUMB_CMN, "cmn\t%0-2r, %3-5r"},
-    {0x4300, 0xFFC0, OP_THUMB_ORR, "orr\t%0-2r, %3-5r"},
-    {0x4340, 0xFFC0, OP_THUMB_MUL, "mul\t%0-2r, %3-5r"},
-    {0x4380, 0xFFC0, OP_THUMB_BIC, "bic\t%0-2r, %3-5r"},
-    {0x43C0, 0xFFC0, OP_THUMB_MVN, "mvn\t%0-2r, %3-5r"},
-    /* format 13 */
-    {0xB000, 0xFF80, OP_THUMB_ADD, "add\tsp, #%0-6W"},
-    {0xB080, 0xFF80, OP_THUMB_SUB, "sub\tsp, #%0-6W"},
-    /* format 5 */
-    {0x4700, 0xFF80, OP_THUMB_BX, "bx\t%S"},
-    {0x4400, 0xFF00, OP_THUMB_ADD, "add\t%D, %S"},
-    {0x4500, 0xFF00, OP_THUMB_CMP, "cmp\t%D, %S"},
-    {0x4600, 0xFF00, OP_THUMB_MOV, "mov\t%D, %S"},
-    /* format 14 */
-    {0xB400, 0xFE00, OP_THUMB_PUSH, "push\t%N"},
-    {0xBC00, 0xFE00, OP_THUMB_POP, "pop\t%O"},
-    /* format 2 */
-    {0x1800, 0xFE00, OP_THUMB_ADD, "add\t%0-2r, %3-5r, %6-8r"},
-    {0x1A00, 0xFE00, OP_THUMB_SUB, "sub\t%0-2r, %3-5r, %6-8r"},
-    {0x1C00, 0xFE00, OP_THUMB_ADD, "add\t%0-2r, %3-5r, #%6-8d"},
-    {0x1E00, 0xFE00, OP_THUMB_SUB, "sub\t%0-2r, %3-5r, #%6-8d"},
-    /* format 8 */
-    {0x5200, 0xFE00, OP_THUMB_STRH, "strh\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5A00, 0xFE00, OP_THUMB_LDRH, "ldrh\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5600, 0xFE00, OP_THUMB_LDRSB, "ldrsb\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5E00, 0xFE00, OP_THUMB_LDRSH, "ldrsh\t%0-2r, [%3-5r, %6-8r]"},
-    /* format 7 */
-    {0x5000, 0xFE00, OP_THUMB_STR, "str\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5400, 0xFE00, OP_THUMB_STRB, "strb\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5800, 0xFE00, OP_THUMB_LDR, "ldr\t%0-2r, [%3-5r, %6-8r]"},
-    {0x5C00, 0xFE00, OP_THUMB_LDRB, "ldrb\t%0-2r, [%3-5r, %6-8r]"},
-    /* format 1 */
-    {0x0000, 0xF800, OP_THUMB_LSL, "lsl\t%0-2r, %3-5r, #%6-10d"},
-    {0x0800, 0xF800, OP_THUMB_LSR, "lsr\t%0-2r, %3-5r, #%6-10d"},
-    {0x1000, 0xF800, OP_THUMB_ASR, "asr\t%0-2r, %3-5r, #%6-10d"},
-    /* format 3 */
-    {0x2000, 0xF800, OP_THUMB_MOV, "mov\t%8-10r, #%0-7d"},
-    {0x2800, 0xF800, OP_THUMB_CMP, "cmp\t%8-10r, #%0-7d"},
-    {0x3000, 0xF800, OP_THUMB_ADD, "add\t%8-10r, #%0-7d"},
-    {0x3800, 0xF800, OP_THUMB_SUB, "sub\t%8-10r, #%0-7d"},
-    /* format 6 */
-    /* TODO: Disassemble PC relative "LDR rD,=<symbolic>" */
-    {0x4800, 0xF800, OP_THUMB_LDR, "ldr\t%8-10r, [pc, #%0-7W]\t(%0-7a)"},
-    /* format 9 */
-    {0x6000, 0xF800, OP_THUMB_STR, "str\t%0-2r, [%3-5r, #%6-10W]"},
-    {0x6800, 0xF800, OP_THUMB_LDR, "ldr\t%0-2r, [%3-5r, #%6-10W]"},
-    {0x7000, 0xF800, OP_THUMB_STRB, "strb\t%0-2r, [%3-5r, #%6-10d]"},
-    {0x7800, 0xF800, OP_THUMB_LDRB, "ldrb\t%0-2r, [%3-5r, #%6-10d]"},
-    /* format 10 */
-    {0x8000, 0xF800, OP_THUMB_STRH, "strh\t%0-2r, [%3-5r, #%6-10H]"},
-    {0x8800, 0xF800, OP_THUMB_LDRH, "ldrh\t%0-2r, [%3-5r, #%6-10H]"},
-    /* format 11 */
-    {0x9000, 0xF800, OP_THUMB_STR, "str\t%8-10r, [sp, #%0-7W]"},
-    {0x9800, 0xF800, OP_THUMB_LDR, "ldr\t%8-10r, [sp, #%0-7W]"},
-    /* format 12 */
-    {0xA000, 0xF800, OP_THUMB_ADD, "add\t%8-10r, pc, #%0-7W\t(adr %8-10r,%0-7a)"},
-    {0xA800, 0xF800, OP_THUMB_ADD, "add\t%8-10r, sp, #%0-7W"},
-    /* format 15 */
-    {0xC000, 0xF800, OP_THUMB_STMIA, "stmia\t%8-10r!,%M"},
-    {0xC800, 0xF800, OP_THUMB_LDMIA, "ldmia\t%8-10r!,%M"},
-    /* format 18 */
-    {0xE000, 0xF800, OP_THUMB_B, "b\t%0-10B"},
-    /* format 19 */
-    /* special processing required in disassembler */
-    {0xF000, 0xF800, OP_THUMB_BL, ""},
-    {0xF800, 0xF800, OP_THUMB_BL, "second half of BL instruction %0-15x"},
-    {0xE800, 0xF800, OP_THUMB_BLX, "second half of BLX instruction %0-15x"},
-    /* format 16 */
-    {0xD000, 0xFF00, OP_THUMB_B, "beq\t%0-7B"},
-    {0xD100, 0xFF00, OP_THUMB_B, "bne\t%0-7B"},
-    {0xD200, 0xFF00, OP_THUMB_B, "bcs\t%0-7B"},
-    {0xD300, 0xFF00, OP_THUMB_B, "bcc\t%0-7B"},
-    {0xD400, 0xFF00, OP_THUMB_B, "bmi\t%0-7B"},
-    {0xD500, 0xFF00, OP_THUMB_B, "bpl\t%0-7B"},
-    {0xD600, 0xFF00, OP_THUMB_B, "bvs\t%0-7B"},
-    {0xD700, 0xFF00, OP_THUMB_B, "bvc\t%0-7B"},
-    {0xD800, 0xFF00, OP_THUMB_B, "bhi\t%0-7B"},
-    {0xD900, 0xFF00, OP_THUMB_B, "bls\t%0-7B"},
-    {0xDA00, 0xFF00, OP_THUMB_B, "bge\t%0-7B"},
-    {0xDB00, 0xFF00, OP_THUMB_B, "blt\t%0-7B"},
-    {0xDC00, 0xFF00, OP_THUMB_B, "bgt\t%0-7B"},
-    {0xDD00, 0xFF00, OP_THUMB_B, "ble\t%0-7B"},
-    /* format 17 */
-    {0xDE00, 0xFF00, OP_THUMB_UNDEFINED, "undefined"},
-    {0xDF00, 0xFF00, OP_THUMB_SWI, "swi\t%0-7d"},
-    /* format 9 */
-    {0x6000, 0xF800, OP_THUMB_STR, "str\t%0-2r, [%3-5r, #%6-10W]"},
-    {0x6800, 0xF800, OP_THUMB_LDR, "ldr\t%0-2r, [%3-5r, #%6-10W]"},
-    {0x7000, 0xF800, OP_THUMB_STRB, "strb\t%0-2r, [%3-5r, #%6-10d]"},
-    {0x7800, 0xF800, OP_THUMB_LDRB, "ldrb\t%0-2r, [%3-5r, #%6-10d]"},
-    /* the rest */
-    {0x0000, 0x0000, OP_THUMB_UNDEFINED, "undefined instruction %0-15x"},
-    {0x0000, 0x0000, OP_END, 0}
-};
-
-#define BDISP23(x,y) ((((((x) & 0x07ff) << 11) | ((y) & 0x07ff)) \
-                     ^ 0x200000) - 0x200000) /* 23bit */
-
-static char * arm_conditional[] =
-{"eq", "ne", "cs", "cc", "mi", "pl", "vs", "vc",
- "hi", "ls", "ge", "lt", "gt", "le", "", "nv"};
-
-typedef struct
-{
-  const char * name;
-  const char * description;
-  const char * reg_names[16];
-}
-arm_regname;
-
-static arm_regname regnames[] =
-{
-  { "raw" , "Select raw register names",
-    { "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15"}},
-  { "gcc",  "Select register names used by GCC",
-    { "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "sl",  "fp",  "ip",  "sp",  "lr",  "pc" }},
-  { "std",  "Select register names used in ARM's ISA documentation",
-    { "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12", "sp",  "lr",  "pc" }},
-  { "apcs", "Select register names used in the APCS",
-    { "a1", "a2", "a3", "a4", "v1", "v2", "v3", "v4", "v5", "v6", "sl",  "fp",  "ip",  "sp",  "lr",  "pc" }},
-  { "atpcs", "Select register names used in the ATPCS",
-    { "a1", "a2", "a3", "a4", "v1", "v2", "v3", "v4", "v5", "v6", "v7",  "v8",  "IP",  "SP",  "LR",  "PC" }},
-  { "special-atpcs", "Select special register names used in the ATPCS",
-    { "a1", "a2", "a3", "a4", "v1", "v2", "v3", "WR", "v5", "SB", "SL",  "FP",  "IP",  "SP",  "LR",  "PC" }}
-};
-
-/* Default to STD register name set.  */
-static unsigned int regname_selected = 2;
-
-#define NUM_ARM_REGNAMES  NUM_ELEM (regnames)
-#define arm_regnames      regnames[regname_selected].reg_names
-
-Opcode decode_insn_thumb(uint32_t given)
-{
-    struct thumb_opcode * insn;
-
-    for (insn = thumb_opcodes; insn->assembler; insn++) {
-        if ((given & insn->mask) == insn->value)
-            return insn->opcode;
-    }
-    return OP_THUMB_UNDEFINED;
-}
-
-// Generates the disassembly string for the thumb instruction "insn1".
-// If "insn1" is a BL or BLX instruction that is the first of two Thumb
-// instructions, then insn2 is the second of two instructions.  Otherwise,
-// insn2 is ignored.
-char *disasm_insn_thumb(uint32_t pc, uint32_t insn1, uint32_t insn2, char *result)
-{
-    struct thumb_opcode * insn;
-    static char buf[80];
-    char *ptr;
-    uint32_t addr;
-    int len;
-
-    if (result == NULL)
-        result = buf;
-    ptr = result;
-
-    for (insn = thumb_opcodes; insn->assembler; insn++) {
-        if ((insn1 & insn->mask) != insn->value)
-            continue;
-
-        char * c = insn->assembler;
-
-        /* Special processing for Thumb 2-instruction BL sequence:  */
-        if (!*c) { /* Check for empty (not NULL) assembler string.  */
-            uint32_t offset;
-
-            offset = BDISP23 (insn1, insn2);
-            offset = offset * 2 + pc + 4;
-            
-            if ((insn2 & 0x1000) == 0) {
-                len = sprintf(ptr, "blx\t");
-                offset &= 0xfffffffc;
-            } else {
-                len = sprintf(ptr, "bl\t");
-            }
-            ptr += len;
-            
-            sprintf(ptr, "0x%x", offset);
-            return result;
-        }
-        
-        insn1 &= 0xffff;
-        
-        for (; *c; c++) {
-            if (*c != '%') {
-                len = sprintf(ptr, "%c", *c);
-                ptr += len;
-                continue;
-            }
-
-            int domaskpc = 0;
-            int domasklr = 0;
-            
-            switch (*++c) {
-                case '%':
-                    len = sprintf(ptr, "%%");
-                    ptr += len;
-                    break;
-                    
-                case 'S': {
-                    uint32_t reg;
-                    
-                    reg = (insn1 >> 3) & 0x7;
-                    if (insn1 & (1 << 6))
-                        reg += 8;
-                    
-                    len = sprintf(ptr, "%s", arm_regnames[reg]);
-                    ptr += len;
-                    break;
-                }
-                    
-                case 'D': {
-                    uint32_t reg;
-                    
-                    reg = insn1 & 0x7;
-                    if (insn1 & (1 << 7))
-                        reg += 8;
-                    
-                    len = sprintf(ptr, "%s", arm_regnames[reg]);
-                    ptr += len;
-                    break;
-                }
-                    
-                case 'T':
-                    len = sprintf(ptr, "%s",
-                          arm_conditional [(insn1 >> 8) & 0xf]);
-                    ptr += len;
-                    break;
-                    
-                case 'N':
-                    if (insn1 & (1 << 8))
-                        domasklr = 1;
-                    /* Fall through.  */
-                case 'O':
-                    if (*c == 'O' && (insn1 & (1 << 8)))
-                        domaskpc = 1;
-                    /* Fall through.  */
-                case 'M': {
-                    int started = 0;
-                    int reg;
-                    
-                    len = sprintf(ptr, "{");
-                    ptr += len;
-                    
-                    /* It would be nice if we could spot
-                       ranges, and generate the rS-rE format: */
-                    for (reg = 0; (reg < 8); reg++)
-                        if ((insn1 & (1 << reg)) != 0) {
-                            if (started) {
-                                len = sprintf(ptr, ", ");
-                                ptr += len;
-                            }
-                            started = 1;
-                            len = sprintf(ptr, "%s", arm_regnames[reg]);
-                            ptr += len;
-                        }
-                    
-                    if (domasklr) {
-                        if (started) {
-                            len = sprintf(ptr, ", ");
-                            ptr += len;
-                        }
-                        started = 1;
-                        len = sprintf(ptr, arm_regnames[14] /* "lr" */);
-                        ptr += len;
-                    }
-                    
-                    if (domaskpc) {
-                        if (started) {
-                            len = sprintf(ptr, ", ");
-                            ptr += len;
-                        }
-                        len = sprintf(ptr, arm_regnames[15] /* "pc" */);
-                        ptr += len;
-                    }
-                    
-                    len = sprintf(ptr, "}");
-                    ptr += len;
-                    break;
-                }
-                    
-                case '0': case '1': case '2': case '3': case '4': 
-                case '5': case '6': case '7': case '8': case '9': {
-                    int bitstart = *c++ - '0';
-                    int bitend = 0;
-                    
-                    while (*c >= '0' && *c <= '9')
-                        bitstart = (bitstart * 10) + *c++ - '0';
-                    
-                    switch (*c) {
-                        case '-': {
-                            uint32_t reg;
-                            
-                            c++;
-                            while (*c >= '0' && *c <= '9')
-                                bitend = (bitend * 10) + *c++ - '0';
-                            if (!bitend)
-                                abort ();
-                            reg = insn1 >> bitstart;
-                            reg &= (2 << (bitend - bitstart)) - 1;
-                            switch (*c) {
-                                case 'r':
-                                    len = sprintf(ptr, "%s", arm_regnames[reg]);
-                                    break;
-                                    
-                                case 'd':
-                                    len = sprintf(ptr, "%d", reg);
-                                    break;
-                                    
-                                case 'H':
-                                    len = sprintf(ptr, "%d", reg << 1);
-                                    break;
-                                    
-                                case 'W':
-                                    len = sprintf(ptr, "%d", reg << 2);
-                                    break;
-                                    
-                                case 'a':
-                                    /* PC-relative address -- the bottom two
-                                       bits of the address are dropped
-                                       before the calculation.  */
-                                    addr = ((pc + 4) & ~3) + (reg << 2);
-                                    len = sprintf(ptr, "0x%x", addr);
-                                    break;
-                                    
-                                case 'x':
-                                    len = sprintf(ptr, "0x%04x", reg);
-                                    break;
-                                    
-                                case 'I':
-                                    reg = ((reg ^ (1 << bitend)) - (1 << bitend));
-                                    len = sprintf(ptr, "%d", reg);
-                                    break;
-                                    
-                                case 'B':
-                                    reg = ((reg ^ (1 << bitend)) - (1 << bitend));
-                                    addr = reg * 2 + pc + 4;
-                                    len = sprintf(ptr, "0x%x", addr);
-                                    break;
-                                    
-                                default:
-                                    abort ();
-                            }
-                            ptr += len;
-                            break;
-                        }
-                            
-                        case '\'':
-                            c++;
-                            if ((insn1 & (1 << bitstart)) != 0) {
-                                len = sprintf(ptr, "%c", *c);
-                                ptr += len;
-                            }
-                            break;
-                            
-                        case '?':
-                            ++c;
-                            if ((insn1 & (1 << bitstart)) != 0)
-                                len = sprintf(ptr, "%c", *c++);
-                            else
-                                len = sprintf(ptr, "%c", *++c);
-                            ptr += len;
-                            break;
-                            
-                        default:
-                            abort ();
-                    }
-                    break;
-                }
-                    
-                default:
-                    abort ();
-            }
-        }
-        return result;
-    }
-    
-    /* No match.  */
-    abort ();
-}
diff --git a/emulator/qtools/trace_reader.cpp b/emulator/qtools/trace_reader.cpp
deleted file mode 100644
index b38c0b4..0000000
--- a/emulator/qtools/trace_reader.cpp
+++ /dev/null
@@ -1,1201 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <limits.h>
-#include <inttypes.h>
-#include <assert.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <elf.h>
-#include "trace_reader.h"
-#include "decoder.h"
-
-// A struct for creating temporary linked-lists of DexSym structs
-struct DexSymList {
-    DexSymList  *next;
-    DexSym      sym;
-};
-
-// Declare static functions used in this file
-static char *ExtractDexPathFromMmap(const char *mmap_path);
-static void CopyDexSymbolsToArray(DexFileList *dexfile,
-                                  DexSymList *head, int num_symbols);
-
-// This function creates the pathname to the a specific trace file.  The
-// string space is allocated in this routine and must be freed by the
-// caller.
-static char *CreateTracePath(const char *filename, const char *ext)
-{
-    char *fname;
-    const char *base_start, *base_end;
-    int ii, len, base_len, dir_len, path_len, qtrace_len;
-
-    // Handle error cases
-    if (filename == NULL || *filename == 0 || strcmp(filename, "/") == 0)
-        return NULL;
-
-    // Ignore a trailing slash, if any
-    len = strlen(filename);
-    if (filename[len - 1] == '/')
-        len -= 1;
-
-    // Find the basename.  We don't use basename(3) because there are
-    // different behaviors for GNU and Posix in the case where the
-    // last character is a slash.
-    base_start = base_end = &filename[len];
-    for (ii = 0; ii < len; ++ii) {
-        base_start -= 1;
-        if (*base_start == '/') {
-            base_start += 1;
-            break;
-        }
-    }
-    base_len = base_end - base_start;
-    dir_len = len - base_len;
-    qtrace_len = strlen("/qtrace");
-
-    // Create space for the pathname: "/dir/basename/qtrace.ext"
-    // The "ext" string already contains the dot, so just add a byte
-    // for the terminating zero.
-    path_len = dir_len + base_len + qtrace_len + strlen(ext) + 1;
-    fname = new char[path_len];
-    if (dir_len > 0)
-        strncpy(fname, filename, dir_len);
-    fname[dir_len] = 0;
-    strncat(fname, base_start, base_len);
-    strcat(fname, "/qtrace");
-    strcat(fname, ext);
-    return fname;
-}
-
-inline BBReader::Future *BBReader::AllocFuture()
-{
-    Future *future = free_;
-    free_ = free_->next;
-    return future;
-}
-
-inline void BBReader::FreeFuture(Future *future)
-{
-    future->next = free_;
-    free_ = future;
-}
-
-inline void BBReader::InsertFuture(Future *future)
-{
-    uint64_t future_time = future->bb.next_time;
-    Future *prev = NULL;
-    Future *ptr;
-    for (ptr = head_; ptr; prev = ptr, ptr = ptr->next) {
-        if (future_time <= ptr->bb.next_time)
-            break;
-    }
-    if (prev == NULL) {
-        // link it at the front
-        future->next = head_;
-        head_ = future;
-    } else {
-        // link it after "prev"
-        future->next = prev->next;
-        prev->next = future;
-    }
-}
-
-// Decodes the next basic block record from the file.  Returns 1
-// at end-of-file, otherwise returns 0.
-inline int BBReader::DecodeNextRec()
-{
-    int64_t bb_diff = decoder_->Decode(true);
-    uint64_t time_diff = decoder_->Decode(false);
-    nextrec_.bb_rec.repeat = decoder_->Decode(false);
-    if (time_diff == 0)
-        return 1;
-    if (nextrec_.bb_rec.repeat)
-        nextrec_.bb_rec.time_diff = decoder_->Decode(false);
-    nextrec_.bb_rec.bb_num += bb_diff;
-    nextrec_.bb_rec.start_time += time_diff;
-    return 0;
-}
-
-BBReader::BBReader(TraceReaderBase *trace)
-{
-    trace_ = trace;
-    decoder_ = new Decoder;
-}
-
-BBReader::~BBReader()
-{
-    delete decoder_;
-}
-
-void BBReader::Open(char *filename)
-{
-    // Initialize the class variables
-    memset(&nextrec_, 0, sizeof(TimeRec));
-    memset(futures_, 0, sizeof(Future) * kMaxNumBasicBlocks);
-    head_ = NULL;
-
-    // Link all of the futures_[] array elements on the free list.
-    for (int ii = 0; ii < kMaxNumBasicBlocks - 1; ++ii) {
-        futures_[ii].next = &futures_[ii + 1];
-    }
-    futures_[kMaxNumBasicBlocks - 1].next = 0;
-    free_ = &futures_[0];
-
-    // Open the trace.bb file
-    char *fname = CreateTracePath(filename, ".bb");
-    decoder_->Open(fname);
-    is_eof_ = DecodeNextRec();
-    delete[] fname;
-}
-
-void BBReader::Close()
-{
-    decoder_->Close();
-}
-
-// Returns true at end of file.
-bool BBReader::ReadBB(BBEvent *event)
-{
-    if (is_eof_ && head_ == NULL) {
-        return true;
-    }
-
-#if 0
-    if (nextrec_) {
-        printf("nextrec: buffer[%d], bb_num: %lld start: %d diff %d repeat %d next %u\n",
-               nextrec_ - &buffer_[0],
-               nextrec_->bb_rec.bb_num, nextrec_->bb_rec.start_time,
-               nextrec_->bb_rec.time_diff, nextrec_->bb_rec.repeat,
-               nextrec_->next_time);
-    }
-    if (head_) {
-        printf("head: 0x%x, bb_num: %lld start: %d diff %d repeat %d next %u\n",
-               head_,
-               head_->bb->bb_rec.bb_num, head_->bb->bb_rec.start_time,
-               head_->bb->bb_rec.time_diff, head_->bb->bb_rec.repeat,
-               head_->bb->next_time);
-    }
-#endif
-    if (!is_eof_) {
-        if (head_) {
-            TimeRec *bb = &head_->bb;
-            if (bb->next_time < nextrec_.bb_rec.start_time) {
-                // The head is earlier.
-                event->time = bb->next_time;
-                event->bb_num = bb->bb_rec.bb_num;
-                event->bb_addr = trace_->GetBBAddr(event->bb_num);
-                event->insns = trace_->GetInsns(event->bb_num);
-                event->num_insns = trace_->FindNumInsns(event->bb_num, event->time);
-                event->pid = trace_->FindCurrentPid(event->time);
-                event->is_thumb = trace_->GetIsThumb(event->bb_num);
-
-                // Remove the head element from the list
-                Future *future = head_;
-                head_ = head_->next;
-                if (bb->bb_rec.repeat > 0) {
-                    // there are more repetitions of this bb
-                    bb->bb_rec.repeat -= 1;
-                    bb->next_time += bb->bb_rec.time_diff;
-
-                    // Insert this future into the sorted list
-                    InsertFuture(future);
-                } else {
-                    // Add this future to the free list
-                    FreeFuture(future);
-                }
-                return false;
-            }
-        }
-        // The nextrec is earlier (or there was no head)
-        event->time = nextrec_.bb_rec.start_time;
-        event->bb_num = nextrec_.bb_rec.bb_num;
-        event->bb_addr = trace_->GetBBAddr(event->bb_num);
-        event->insns = trace_->GetInsns(event->bb_num);
-        event->num_insns = trace_->FindNumInsns(event->bb_num, event->time);
-        event->pid = trace_->FindCurrentPid(event->time);
-        event->is_thumb = trace_->GetIsThumb(event->bb_num);
-        if (nextrec_.bb_rec.repeat > 0) {
-            Future *future = AllocFuture();
-            future->bb.bb_rec = nextrec_.bb_rec;
-            future->bb.bb_rec.repeat -= 1;
-            future->bb.next_time = nextrec_.bb_rec.start_time + nextrec_.bb_rec.time_diff;
-            InsertFuture(future);
-        }
-
-        is_eof_ = DecodeNextRec();
-        return false;
-    }
-
-    //printf("using head_ 0x%x\n", head_);
-    assert(head_);
-    TimeRec *bb = &head_->bb;
-    event->time = bb->next_time;
-    event->bb_num = bb->bb_rec.bb_num;
-    event->bb_addr = trace_->GetBBAddr(event->bb_num);
-    event->insns = trace_->GetInsns(event->bb_num);
-    event->num_insns = trace_->FindNumInsns(event->bb_num, event->time);
-    event->pid = trace_->FindCurrentPid(event->time);
-    event->is_thumb = trace_->GetIsThumb(event->bb_num);
-
-    // Remove the head element from the list
-    Future *future = head_;
-    head_ = head_->next;
-    if (bb->bb_rec.repeat > 0) {
-        // there are more repetitions of this bb
-        bb->bb_rec.repeat -= 1;
-        bb->next_time += bb->bb_rec.time_diff;
-
-        // Insert this future into the sorted list
-        InsertFuture(future);
-    } else {
-        // Add this future to the free list
-        FreeFuture(future);
-    }
-    return false;
-}
-
-InsnReader::InsnReader()
-{
-    decoder_ = new Decoder;
-}
-
-InsnReader::~InsnReader()
-{
-    delete decoder_;
-}
-
-void InsnReader::Open(char *filename)
-{
-    prev_time_ = 0;
-    time_diff_ = 0;
-    repeat_ = -1;
-
-    // Open the trace.insn file
-    char *fname = CreateTracePath(filename, ".insn");
-    decoder_->Open(fname);
-    delete[] fname;
-}
-
-void InsnReader::Close()
-{
-    decoder_->Close();
-}
-
-uint64_t InsnReader::ReadInsnTime(uint64_t min_time)
-{
-    do {
-        if (repeat_ == -1) {
-            time_diff_ = decoder_->Decode(false);
-            repeat_ = decoder_->Decode(false);
-        }
-        prev_time_ += time_diff_;
-        repeat_ -= 1;
-    } while (prev_time_ < min_time);
-    return prev_time_;
-}
-
-AddrReader::AddrReader()
-{
-    decoder_ = new Decoder;
-    opened_ = false;
-}
-
-AddrReader::~AddrReader()
-{
-    delete decoder_;
-}
-
-// Returns true if there is an error opening the file
-bool AddrReader::Open(char *filename, char *suffix)
-{
-    struct stat stat_buf;
-
-    prev_addr_ = 0;
-    prev_time_ = 0;
-
-    // Open the trace.addr file
-    char *fname = CreateTracePath(filename, suffix);
-    int rval = stat(fname, &stat_buf);
-    if (rval == -1) {
-        // The file does not exist
-        delete[] fname;
-        return true;
-    }
-    decoder_->Open(fname);
-    opened_ = true;
-    delete[] fname;
-    return false;
-}
-
-void AddrReader::Close()
-{
-    decoder_->Close();
-}
-
-// Returns true at end of file.
-bool AddrReader::ReadAddr(uint64_t *time, uint32_t *addr)
-{
-    if (!opened_) {
-        fprintf(stderr, "Cannot read address trace\n");
-        exit(1);
-    }
-    uint32_t addr_diff = decoder_->Decode(true);
-    uint64_t time_diff = decoder_->Decode(false);
-    if (time_diff == 0 && addr_diff == 0) {
-        *addr = 0;
-        *time = 0;
-        return true;
-    }
-    prev_addr_ += addr_diff;
-    prev_time_ += time_diff;
-    *addr = prev_addr_;
-    *time = prev_time_;
-    return false;
-}
-
-ExcReader::ExcReader()
-{
-    decoder_ = new Decoder;
-}
-
-ExcReader::~ExcReader()
-{
-    delete decoder_;
-}
-
-void ExcReader::Open(char *filename)
-{
-    prev_time_ = 0;
-    prev_recnum_ = 0;
-
-    // Open the trace.exc file
-    char *fname = CreateTracePath(filename, ".exc");
-    decoder_->Open(fname);
-    delete[] fname;
-}
-
-void ExcReader::Close()
-{
-    decoder_->Close();
-}
-
-// Returns true at end of file.
-bool ExcReader::ReadExc(uint64_t *time, uint32_t *current_pc, uint64_t *recnum,
-                        uint32_t *target_pc, uint64_t *bb_num,
-                        uint64_t *bb_start_time, int *num_insns)
-{
-    uint64_t time_diff = decoder_->Decode(false);
-    uint32_t pc = decoder_->Decode(false);
-    if ((time_diff | pc) == 0) {
-        decoder_->Decode(false);
-        decoder_->Decode(false);
-        decoder_->Decode(false);
-        decoder_->Decode(false);
-        decoder_->Decode(false);
-        return true;
-    }
-    uint64_t recnum_diff = decoder_->Decode(false);
-    prev_time_ += time_diff;
-    prev_recnum_ += recnum_diff;
-    *time = prev_time_;
-    *current_pc = pc;
-    *recnum = prev_recnum_;
-    *target_pc = decoder_->Decode(false);
-    *bb_num = decoder_->Decode(false);
-    *bb_start_time = decoder_->Decode(false);
-    *num_insns = decoder_->Decode(false);
-    return false;
-}
-
-PidReader::PidReader()
-{
-    decoder_ = new Decoder;
-}
-
-PidReader::~PidReader()
-{
-    delete decoder_;
-}
-
-void PidReader::Open(char *filename)
-{
-    prev_time_ = 0;
-
-    // Open the trace.pid file
-    char *fname = CreateTracePath(filename, ".pid");
-    decoder_->Open(fname);
-    delete[] fname;
-}
-
-void PidReader::Close()
-{
-    decoder_->Close();
-}
-
-// Returns true at end of file.
-bool PidReader::ReadPidEvent(PidEvent *event)
-{
-    uint64_t time_diff = decoder_->Decode(false);
-    int rec_type = decoder_->Decode(false);
-    prev_time_ += time_diff;
-    event->time = prev_time_;
-    event->rec_type = rec_type;
-    switch(rec_type) {
-        case kPidEndOfFile:
-            return true;
-        case kPidSwitch:
-        case kPidExit:
-            event->pid = decoder_->Decode(false);
-            break;
-        case kPidFork:
-        case kPidClone:
-            event->tgid = decoder_->Decode(false);
-            event->pid = decoder_->Decode(false);
-            break;
-        case kPidMmap:
-            {
-                event->vstart = decoder_->Decode(false);
-                event->vend = decoder_->Decode(false);
-                event->offset = decoder_->Decode(false);
-                int len = decoder_->Decode(false);
-                char *path = new char[len + 1];
-                decoder_->Read(path, len);
-                path[len] = 0;
-                event->path = path;
-                event->mmap_path = path;
-                char *dexfile = ExtractDexPathFromMmap(path);
-                if (dexfile != NULL) {
-                    delete[] event->path;
-                    event->path = dexfile;
-                }
-            }
-            break;
-        case kPidMunmap:
-            {
-                event->vstart = decoder_->Decode(false);
-                event->vend = decoder_->Decode(false);
-            }
-            break;
-        case kPidSymbolAdd:
-            {
-                event->vstart = decoder_->Decode(false);
-                int len = decoder_->Decode(false);
-                char *path = new char[len + 1];
-                decoder_->Read(path, len);
-                path[len] = 0;
-                event->path = path;
-            }
-            break;
-        case kPidSymbolRemove:
-            event->vstart = decoder_->Decode(false);
-            break;
-        case kPidExec:
-            {
-                int argc = decoder_->Decode(false);
-                event->argc = argc;
-                char **argv = new char*[argc];
-                event->argv = argv;
-                for (int ii = 0; ii < argc; ++ii) {
-                    int alen = decoder_->Decode(false);
-                    argv[ii] = new char[alen + 1];
-                    decoder_->Read(argv[ii], alen);
-                    argv[ii][alen] = 0;
-                }
-            }
-            break;
-        case kPidName:
-        case kPidKthreadName:
-            {
-                if (rec_type == kPidKthreadName) {
-                    event->tgid = decoder_->Decode(false);
-                }
-                event->pid = decoder_->Decode(false);
-                int len = decoder_->Decode(false);
-                char *path = new char[len + 1];
-                decoder_->Read(path, len);
-                path[len] = 0;
-                event->path = path;
-            }
-            break;
-    }
-    return false;
-}
-
-// Frees the memory that might have been allocated for the given event.
-void PidReader::Dispose(PidEvent *event)
-{
-    switch(event->rec_type) {
-        case kPidMmap:
-        case kPidSymbolAdd:
-        case kPidName:
-        case kPidKthreadName:
-            delete[] event->path;
-            event->path = NULL;
-            event->mmap_path = NULL;
-            break;
-
-        case kPidExec:
-            for (int ii = 0; ii < event->argc; ++ii) {
-                delete[] event->argv[ii];
-            }
-            delete[] event->argv;
-            event->argv = NULL;
-            event->argc = 0;
-            break;
-    }
-}
-
-
-MethodReader::MethodReader()
-{
-    decoder_ = new Decoder;
-    opened_ = false;
-}
-
-MethodReader::~MethodReader()
-{
-    delete decoder_;
-}
-
-bool MethodReader::Open(char *filename)
-{
-    struct stat stat_buf;
-
-    prev_time_ = 0;
-    prev_addr_ = 0;
-    prev_pid_ = 0;
-
-    // Open the trace.method file
-    char *fname = CreateTracePath(filename, ".method");
-    int rval = stat(fname, &stat_buf);
-    if (rval == -1) {
-        // The file does not exist
-        delete[] fname;
-        return true;
-    }
-    decoder_->Open(fname);
-    delete[] fname;
-    opened_ = true;
-    return false;
-}
-
-void MethodReader::Close()
-{
-    decoder_->Close();
-}
-
-// Returns true at end of file.
-bool MethodReader::ReadMethod(MethodRec *method_record)
-{
-    if (!opened_)
-        return true;
-    uint64_t time_diff = decoder_->Decode(false);
-    int32_t addr_diff = decoder_->Decode(true);
-    if (time_diff == 0) {
-        method_record->time = 0;
-        method_record->addr = 0;
-        method_record->flags = 0;
-        return true;
-    }
-    int32_t pid_diff = decoder_->Decode(true);
-    prev_time_ += time_diff;
-    prev_addr_ += addr_diff;
-    prev_pid_ += pid_diff;
-    method_record->time = prev_time_;
-    method_record->addr = prev_addr_;
-    method_record->pid = prev_pid_;
-    method_record->flags = decoder_->Decode(false);
-    return false;
-}
-
-TraceReaderBase::TraceReaderBase()
-{
-    static_filename_ = NULL;
-    static_fstream_ = NULL;
-    header_ = new TraceHeader;
-    bb_reader_ = new BBReader(this);
-    insn_reader_ = new InsnReader;
-    load_addr_reader_ = new AddrReader;
-    store_addr_reader_ = new AddrReader;
-    exc_reader_ = new ExcReader;
-    pid_reader_ = new PidReader;
-    method_reader_ = new MethodReader;
-    internal_exc_reader_ = new ExcReader;
-    internal_pid_reader_ = new PidReader;
-    internal_method_reader_ = new MethodReader;
-    blocks_ = NULL;
-    bb_recnum_ = 0;
-    exc_recnum_ = 0;
-    exc_end_ = false;
-    exc_bb_num_ = 0;
-    exc_time_ = 0;
-    exc_num_insns_ = 0;
-    current_pid_ = 0;
-    next_pid_ = 0;
-    next_pid_switch_time_ = 0;
-    post_processing_ = false;
-    dex_hash_ = NULL;
-    load_eof_ = false;
-    load_time_ = 0;
-    load_addr_ = 0;
-    store_eof_ = false;
-    store_time_ = 0;
-    store_addr_ = 0;
-}
-
-TraceReaderBase::~TraceReaderBase()
-{
-    Close();
-    delete bb_reader_;
-    delete insn_reader_;
-    delete load_addr_reader_;
-    delete store_addr_reader_;
-    delete exc_reader_;
-    delete pid_reader_;
-    delete method_reader_;
-    delete internal_exc_reader_;
-    delete internal_pid_reader_;
-    delete internal_method_reader_;
-    if (blocks_) {
-        int num_static_bb = header_->num_static_bb;
-        for (int ii = 0; ii < num_static_bb; ++ii) {
-            delete[] blocks_[ii].insns;
-        }
-        delete[] blocks_;
-    }
-    delete header_;
-    if (dex_hash_ != NULL) {
-        HashTable<DexFileList*>::entry_type *ptr;
-        for (ptr = dex_hash_->GetFirst(); ptr; ptr = dex_hash_->GetNext()) {
-            DexFileList *dexfile = ptr->value;
-            delete[] dexfile->path;
-            int nsymbols = dexfile->nsymbols;
-            DexSym *symbols = dexfile->symbols;
-            for (int ii = 0; ii < nsymbols; ii++) {
-                delete[] symbols[ii].name;
-            }
-            delete[] dexfile->symbols;
-            delete dexfile;
-        }
-    }
-    delete dex_hash_;
-    delete[] static_filename_;
-}
-
-void TraceReaderBase::ReadTraceHeader(FILE *fstream, char *filename,
-                                      char *tracename, TraceHeader *header)
-{
-    int rval = fread(header, sizeof(TraceHeader), 1, fstream);
-    if (rval != 1) {
-        perror(filename);
-        exit(1);
-    }
-
-    if (!post_processing_ && strcmp(header->ident, TRACE_IDENT) != 0) {
-        fprintf(stderr, "%s: missing trace header; run 'post_trace %s' first\n",
-                filename, tracename);
-        exit(1);
-    }
-
-    if (header->version != TRACE_VERSION) {
-        fprintf(stderr,
-                "%s: trace header version (%d) does not match compiled tools version (%d)\n",
-                tracename, header->version, TRACE_VERSION);
-        exit(1);
-    }
-
-    convert32(header->version);
-    convert32(header->start_sec);
-    convert32(header->start_usec);
-    convert32(header->pdate);
-    convert32(header->ptime);
-    convert64(header->num_static_bb);
-    convert64(header->num_static_insn);
-    convert64(header->num_dynamic_bb);
-    convert64(header->num_dynamic_insn);
-    convert64(header->elapsed_usecs);
-}
-
-
-void TraceReaderBase::Open(char *filename)
-{
-    char *fname;
-    FILE *fstream;
-
-    // Open the qtrace.bb file
-    bb_reader_->Open(filename);
-
-    // Open the qtrace.insn file
-    insn_reader_->Open(filename);
-
-    // Open the qtrace.load file and read the first line
-    load_eof_ = load_addr_reader_->Open(filename, ".load");
-    if (!load_eof_)
-        load_eof_ = load_addr_reader_->ReadAddr(&load_time_, &load_addr_);
-
-    // Open the qtrace.store file and read the first line
-    store_eof_ = store_addr_reader_->Open(filename, ".store");
-    if (!store_eof_)
-        store_eof_ = store_addr_reader_->ReadAddr(&store_time_, &store_addr_);
-
-    // Open the qtrace.exc file
-    exc_reader_->Open(filename);
-
-    // Open another file stream to the qtrace.exc file for internal reads.
-    // This allows the caller to also read from the qtrace.exc file.
-    internal_exc_reader_->Open(filename);
-
-    // Open the qtrace.pid file
-    pid_reader_->Open(filename);
-    internal_pid_reader_->Open(filename);
-
-    // Open the qtrace.method file
-    method_reader_->Open(filename);
-    internal_method_reader_->Open(filename);
-
-    // Open the qtrace.static file
-    fname = CreateTracePath(filename, ".static");
-    static_filename_ = fname;
-
-    fstream = fopen(fname, "r");
-    if (fstream == NULL) {
-        perror(fname);
-        exit(1);
-    }
-    static_fstream_ = fstream;
-
-    // Read the header
-    ReadTraceHeader(fstream, fname, filename, header_);
-
-    // Allocate space for all of the static blocks
-    int num_static_bb = header_->num_static_bb;
-    if (num_static_bb) {
-        blocks_ = new StaticBlock[num_static_bb];
-
-        // Read in all the static blocks
-        for (int ii = 0; ii < num_static_bb; ++ii) {
-            ReadStatic(&blocks_[ii].rec);
-            int num_insns = blocks_[ii].rec.num_insns;
-            if (num_insns > 0) {
-                blocks_[ii].insns = new uint32_t[num_insns];
-                ReadStaticInsns(num_insns, blocks_[ii].insns);
-            } else {
-                blocks_[ii].insns = NULL;
-            }
-        }
-        fseek(static_fstream_, sizeof(TraceHeader), SEEK_SET);
-    }
-
-    ParseDexList(filename);
-
-    // If the dex_hash_ is NULL, then assign it a small hash table
-    // so that we can simply do a Find() operation without having
-    // to check for NULL first.
-    if (dex_hash_ == NULL) {
-        dex_hash_ = new HashTable<DexFileList*>(1, NULL);
-    }
-}
-
-// Reads the list of pid events looking for an mmap of a dex file.
-PidEvent * TraceReaderBase::FindMmapDexFileEvent()
-{
-    static PidEvent event;
-
-    while (!pid_reader_->ReadPidEvent(&event)) {
-        if (event.rec_type == kPidMmap && event.path != event.mmap_path) {
-            return &event;
-        }
-        pid_reader_->Dispose(&event);
-    }
-    return NULL;
-}
-
-static void CopyDexSymbolsToArray(DexFileList *dexfile,
-                                  DexSymList *head, int num_symbols)
-{
-    if (dexfile == NULL)
-        return;
-
-    DexSym *symbols = NULL;
-    if (num_symbols > 0) {
-        symbols = new DexSym[num_symbols];
-    }
-    dexfile->nsymbols = num_symbols;
-    dexfile->symbols = symbols;
-    
-    // Copy the linked-list to the array.
-    DexSymList *next_sym = NULL;
-    int next_index = 0;
-    for (DexSymList *sym = head; sym; sym = next_sym) {
-        next_sym = sym->next;
-        symbols[next_index].addr = sym->sym.addr;
-        symbols[next_index].len = sym->sym.len;
-        symbols[next_index].name = sym->sym.name;
-        next_index += 1;
-        delete sym;
-    }
-}
-
-void TraceReaderBase::ParseDexList(char *filename)
-{
-    struct stat stat_buf;
-    static const int kBufSize = 4096;
-    char buf[kBufSize];
-    char current_file[kBufSize];
-
-    // Find an example dex file in the list of mmaps
-    PidEvent *event = FindMmapDexFileEvent();
-
-    // Reset the pid_reader to the beginning of the file.
-    pid_reader_->Close();
-    pid_reader_->Open(filename);
-
-    // If there were no mmapped dex files, then there is no need to parse
-    // the dexlist.
-    if (event == NULL)
-        return;
-    char *mmap_dexfile = event->path;
-
-    // Check if the dexlist file exists.  It should have the name
-    // "qtrace.dexlist"
-    char *fname = CreateTracePath(filename, ".dexlist");
-    int rval = stat(fname, &stat_buf);
-    if (rval == -1) {
-        // The file does not exist
-        delete[] fname;
-        return;
-    }
-
-    // Open the qtrace.dexlist file
-    FILE *fstream = fopen(fname, "r");
-    if (fstream == NULL) {
-        perror(fname);
-        exit(1);
-    }
-
-    // First pass: read all the filenames, looking for a match for the
-    // example mmap dex filename.  Also count the files so that we
-    // know how big to make the hash table.
-    char *match = NULL;
-    int num_files = 0;
-    while (fgets(buf, kBufSize, fstream)) {
-        if (buf[0] != '#')
-            continue;
-        num_files += 1;
-        match = strstr(buf + 1, mmap_dexfile);
-
-        // Check that the dexlist file ends with the string mmap_dexfile.
-        // We add one to the length of the mmap_dexfile because buf[]
-        // ends with a newline.  The strlen(mmap_dexfile) computation
-        // could be moved above the loop but it should only ever be
-        // executed once.
-        if (match != NULL && strlen(match) == strlen(mmap_dexfile) + 1)
-            break;
-    }
-
-    // Count the rest of the files
-    while (fgets(buf, kBufSize, fstream)) {
-        if (buf[0] == '#')
-            num_files += 1;
-    }
-
-    if (match == NULL) {
-        fprintf(stderr,
-                "Cannot find the mmapped dex file '%s' in the dexlist\n",
-                mmap_dexfile);
-        exit(1);
-    }
-    delete[] mmap_dexfile;
-
-    // The prefix length includes the leading '#'.
-    int prefix_len = match - buf;
-
-    // Allocate a hash table
-    dex_hash_ = new HashTable<DexFileList*>(4 * num_files, NULL);
-
-    // Reset the file stream to the beginning
-    rewind(fstream);
-
-    // Second pass: read the filenames, stripping off the common prefix.
-    // And read all the (address, method) mappings.  When we read a new
-    // filename, create a new DexFileList and add it to the hash table.
-    // Add new symbol mappings to a linked list until we have the whole
-    // list and then create an array for them so that we can use binary
-    // search on the address to find the symbol name quickly.
-
-    // Use a linked list for storing the symbols
-    DexSymList *head = NULL;
-    DexSymList *prev = NULL;
-    int num_symbols = 0;
-
-    DexFileList *dexfile = NULL;
-    int linenum = 0;
-    while (fgets(buf, kBufSize, fstream)) {
-        linenum += 1;
-        if (buf[0] == '#') {
-            // Everything after the '#' is a filename.
-            // Ignore the common prefix.
-
-            // First, save all the symbols from the previous file (if any).
-            CopyDexSymbolsToArray(dexfile, head, num_symbols);
-
-            dexfile = new DexFileList;
-            // Subtract one because buf[] contains a trailing newline
-            int pathlen = strlen(buf) - prefix_len - 1;
-            char *path = new char[pathlen + 1];
-            strncpy(path, buf + prefix_len, pathlen);
-            path[pathlen] = 0;
-            dexfile->path = path;
-            dexfile->nsymbols = 0;
-            dexfile->symbols = NULL;
-            dex_hash_->Update(path, dexfile);
-            num_symbols = 0;
-            head = NULL;
-            prev = NULL;
-            continue;
-        }
-
-        uint32_t addr;
-        int len, line;
-        char clazz[kBufSize], method[kBufSize], sig[kBufSize], file[kBufSize];
-        if (sscanf(buf, "0x%x %d %s %s %s %s %d",
-                   &addr, &len, clazz, method, sig, file, &line) != 7) {
-            fprintf(stderr, "Cannot parse line %d of file %s:\n%s",
-                    linenum, fname, buf);
-            exit(1);
-        }
-
-        // Concatenate the class name, method name, and signature
-        // plus one for the period separating the class and method.
-        int nchars = strlen(clazz) + strlen(method) + strlen(sig) + 1;
-        char *name = new char[nchars + 1];
-        strcpy(name, clazz);
-        strcat(name, ".");
-        strcat(name, method);
-        strcat(name, sig);
-
-        DexSymList *symbol = new DexSymList;
-        symbol->sym.addr = addr;
-        symbol->sym.len = len;
-        symbol->sym.name = name;
-        symbol->next = NULL;
-
-        // Keep the list in the same order as the file
-        if (head == NULL)
-            head = symbol;
-        if (prev != NULL)
-            prev->next = symbol;
-        prev = symbol;
-        num_symbols += 1;
-    }
-    fclose(fstream);
-
-    // Copy the symbols from the last file.
-    CopyDexSymbolsToArray(dexfile, head, num_symbols);
-    delete[] fname;
-}
-
-// Extracts the pathname to a jar file (or .apk file) from the mmap pathname.
-// An example mmap pathname looks something like this:
-//   /data/dalvik-cache/system@app@TestHarness.apk@classes.dex
-// We want to convert that to this:
-//   /system/app/TestHarness.apk
-// If the pathname is not of the expected form, then NULL is returned.
-// The space for the extracted path is allocated in this routine and should
-// be freed by the caller after it is no longer needed.
-static char *ExtractDexPathFromMmap(const char *mmap_path)
-{
-    char *end = rindex(mmap_path, '@');
-    if (end == NULL)
-        return NULL;
-    char *start = rindex(mmap_path, '/');
-    if (start == NULL)
-        return NULL;
-    int len = end - start;
-    char *path = new char[len + 1];
-    strncpy(path, start, len);
-    path[len] = 0;
-
-    // Replace all the occurrences of '@' with '/'
-    for (int ii = 0; ii < len; ii++) {
-        if (path[ii] == '@')
-            path[ii] = '/';
-    }
-    return path;
-}
-
-void TraceReaderBase::Close()
-{
-    bb_reader_->Close();
-    insn_reader_->Close();
-    load_addr_reader_->Close();
-    store_addr_reader_->Close();
-    exc_reader_->Close();
-    pid_reader_->Close();
-    method_reader_->Close();
-    internal_exc_reader_->Close();
-    internal_pid_reader_->Close();
-    internal_method_reader_->Close();
-    fclose(static_fstream_);
-    static_fstream_ = NULL;
-}
-
-void TraceReaderBase::WriteHeader(TraceHeader *header)
-{
-    TraceHeader swappedHeader;
-
-    freopen(static_filename_, "r+", static_fstream_);
-    fseek(static_fstream_, 0, SEEK_SET);
-
-    memcpy(&swappedHeader, header, sizeof(TraceHeader));
-
-    convert32(swappedHeader.version);
-    convert32(swappedHeader.start_sec);
-    convert32(swappedHeader.start_usec);
-    convert32(swappedHeader.pdate);
-    convert32(swappedHeader.ptime);
-    convert64(swappedHeader.num_static_bb);
-    convert64(swappedHeader.num_static_insn);
-    convert64(swappedHeader.num_dynamic_bb);
-    convert64(swappedHeader.num_dynamic_insn);
-    convert64(swappedHeader.elapsed_usecs);
-
-    fwrite(&swappedHeader, sizeof(TraceHeader), 1, static_fstream_);
-}
-
-// Reads the next StaticRec from the trace file (not including the list
-// of instructions).  On end-of-file, this function returns true.
-int TraceReaderBase::ReadStatic(StaticRec *rec)
-{
-    int rval = fread(rec, sizeof(StaticRec), 1, static_fstream_);
-    if (rval != 1) {
-        if (feof(static_fstream_)) {
-            return true;
-        }
-        perror(static_filename_);
-        exit(1);
-    }
-    convert64(rec->bb_num);
-    convert32(rec->bb_addr);
-    convert32(rec->num_insns);
-    return false;
-}
-
-// Reads "num" instructions into the array "insns" which must be large
-// enough to hold the "num" instructions.
-// Returns the actual number of instructions read.  This will usually
-// be "num" but may be less if end-of-file occurred.
-int TraceReaderBase::ReadStaticInsns(int num, uint32_t *insns)
-{
-    if (num == 0)
-        return 0;
-    int rval = fread(insns, sizeof(uint32_t), num, static_fstream_);
-
-    // Convert from little-endian, if necessary
-    for (int ii = 0; ii < num; ++ii)
-        convert32(insns[ii]);
-
-    if (rval != num) {
-        if (feof(static_fstream_)) {
-            return rval;
-        }
-        perror(static_filename_);
-        exit(1);
-    }
-    return rval;
-}
-
-void TraceReaderBase::TruncateLastBlock(uint32_t num_insns)
-{
-    uint32_t insns[kMaxInsnPerBB];
-    StaticRec static_rec;
-    long loc = 0, prev_loc = 0;
-
-    freopen(static_filename_, "r+", static_fstream_);
-    fseek(static_fstream_, sizeof(TraceHeader), SEEK_SET);
-
-    // Find the last record
-    while (1) {
-        prev_loc = loc;
-        loc = ftell(static_fstream_);
-
-        // We don't need to byte-swap static_rec here because we are just
-        // reading the records until we get to the last one.
-        int rval = fread(&static_rec, sizeof(StaticRec), 1, static_fstream_);
-        if (rval != 1)
-            break;
-        ReadStaticInsns(static_rec.num_insns, insns);
-    }
-    if (prev_loc != 0) {
-        fseek(static_fstream_, prev_loc, SEEK_SET);
-        static_rec.num_insns = num_insns;
-
-        // Now we need to byte-swap, but just the field that we changed.
-        convert32(static_rec.num_insns);
-        fwrite(&static_rec, sizeof(StaticRec), 1, static_fstream_);
-        int fd = fileno(static_fstream_);
-        long len = ftell(static_fstream_);
-        len += num_insns * sizeof(uint32_t);
-        ftruncate(fd, len);
-    }
-}
-
-int TraceReaderBase::FindNumInsns(uint64_t bb_num, uint64_t bb_start_time)
-{
-    int num_insns;
-
-    // Read the exception trace file.  "bb_recnum_" is the number of
-    // basic block records that have been read so far, and "exc_recnum_"
-    // is the record number from the exception trace.
-    while (!exc_end_ && exc_recnum_ < bb_recnum_) {
-        uint32_t current_pc, target_pc;
-        uint64_t time;
-
-        exc_end_ = internal_exc_reader_->ReadExc(&time, &current_pc, &exc_recnum_,
-                                                 &target_pc, &exc_bb_num_,
-                                                 &exc_time_, &exc_num_insns_);
-    }
-
-    // If an exception occurred in this basic block, then use the
-    // number of instructions specified in the exception record.
-    if (!exc_end_ && exc_recnum_ == bb_recnum_) {
-        num_insns = exc_num_insns_;
-    } else {
-        // Otherwise, use the number of instructions specified in the
-        // static basic block.
-        num_insns = blocks_[bb_num].rec.num_insns;
-    }
-    return num_insns;
-}
-
-// Finds the current pid for the given time.  This routine reads the pid
-// trace file and assumes that the "time" parameter is monotonically
-// increasing.
-int TraceReaderBase::FindCurrentPid(uint64_t time)
-{
-    PidEvent event;
-
-    if (time < next_pid_switch_time_)
-        return current_pid_;
-
-    current_pid_ = next_pid_;
-    while (1) {
-        if (internal_pid_reader_->ReadPidEvent(&event)) {
-            next_pid_switch_time_ = ~0ull;
-            break;
-        }
-        if (event.rec_type != kPidSwitch)
-            continue;
-        if (event.time > time) {
-            next_pid_ = event.pid;
-            next_pid_switch_time_ = event.time;
-            break;
-        }
-        current_pid_ = event.pid;
-    }
-    return current_pid_;
-}
diff --git a/emulator/qtools/trace_reader.h b/emulator/qtools/trace_reader.h
deleted file mode 100644
index 4123014..0000000
--- a/emulator/qtools/trace_reader.h
+++ /dev/null
@@ -1,1408 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef TRACE_READER_H
-#define TRACE_READER_H
-
-#include <string.h>
-#include <inttypes.h>
-#include <elf.h>
-#include <assert.h>
-#include <cxxabi.h>
-#include "read_elf.h"
-#include "trace_reader_base.h"
-#include "hash_table.h"
-
-struct TraceReaderEmptyStruct {
-};
-
-template <class T = TraceReaderEmptyStruct>
-class TraceReader : public TraceReaderBase {
-  public:
-
-    struct region_entry;
-    typedef struct symbol_entry : public T {
-        typedef region_entry region_type;
-
-        // Define flag values
-        static const uint32_t kIsPlt = 0x01;
-        static const uint32_t kIsVectorStart = 0x02;
-        static const uint32_t kIsVectorTable = (kIsPlt | kIsVectorStart);
-        static const uint32_t kIsInterpreter = 0x04;
-        static const uint32_t kIsMethod = 0x08;
-
-        uint32_t        addr;
-
-        // This may hold the name of the interpreted method instead of
-        // the name of the native function if the native function is a
-        // virtual machine interpreter.
-        const char      *name;
-
-        // The symbol for the virtual machine interpreter, or NULL
-        symbol_entry    *vm_sym;
-        region_type     *region;
-        uint32_t        flags;
-    } symbol_type;
-
-    typedef struct region_entry {
-        // Define flag values
-        static const uint32_t kIsKernelRegion           = 0x01;
-        static const uint32_t kSharedSymbols            = 0x02;
-        static const uint32_t kIsLibraryRegion          = 0x04;
-        static const uint32_t kIsUserMappedRegion       = 0x08;
-
-        region_entry() : refs(0), path(NULL), vstart(0), vend(0), base_addr(0),
-                         file_offset(0), flags(0), nsymbols(0), symbols(NULL) {}
-
-        symbol_type    *LookupFunctionByName(char *name) {
-            // Just do a linear search
-            for (int ii = 0; ii < nsymbols; ++ii) {
-                if (strcmp(symbols[ii].name, name) == 0)
-                    return &symbols[ii];
-            }
-            return NULL;
-        }
-
-        int             refs;        // reference count
-        char            *path;
-        uint32_t        vstart;
-        uint32_t        vend;
-        uint32_t        base_addr;
-        uint32_t        file_offset;
-        uint32_t        flags;
-        int             nsymbols;
-        symbol_type     *symbols;
-    } region_type;
-
-    typedef typename HashTable<region_type*>::entry_type hash_entry_type;
-
-    class ProcessState {
-      public:
-
-        // The "regions" array below is a pointer to array of pointers to
-        // regions.  The size of the pointer array is kInitialNumRegions,
-        // but grows if needed.  There is a separate region for each mmap
-        // call which includes shared libraries as well as .dex and .jar
-        // files.  In addition, there is a region for the main executable
-        // for this process, as well as a few regions for the kernel.
-        //
-        // If a child process is a clone of a parent process, the
-        // regions array is unused.  Instead, the "addr_manager" pointer is
-        // used to find the process that is the address space manager for
-        // both the parent and child processes.
-        static const int kInitialNumRegions = 10;
-
-        static const int kMaxMethodStackSize = 1000;
-
-        // Define values for the ProcessState flag bits
-        static const int kCalledExec            = 0x01;
-        static const int kCalledExit            = 0x02;
-        static const int kIsClone               = 0x04;
-        static const int kHasKernelRegion       = 0x08;
-        static const int kHasFirstMmap          = 0x10;
-
-        ProcessState() {
-            cpu_time = 0;
-            tgid = 0;
-            pid = 0;
-            parent_pid = 0;
-            exit_val = 0;
-            flags = 0;
-            argc = 0;
-            argv = NULL;
-            name = NULL;
-            nregions = 0;
-            max_regions = 0;
-            // Don't allocate space yet until we know if we are a clone.
-            regions = NULL;
-            parent = NULL;
-            addr_manager = this;
-            next = NULL;
-            current_method_sym = NULL;
-            method_stack_top = 0;
-        }
-
-        ~ProcessState() {
-            delete[] name;
-            if ((flags & kIsClone) != 0) {
-                return;
-            }
-
-            // Free the regions.  We must be careful not to free the symbols
-            // within each region because the symbols are sometimes shared
-            // between multiple regions.  The TraceReader class has a hash
-            // table containing all the unique regions and it will free the
-            // region symbols in its destructor.  We need to free only the
-            // regions and the array of region pointers.
-            //
-            // Each region is also reference-counted.  The count is zero
-            // if no other processes are sharing this region.
-            for (int ii = 0; ii < nregions; ii++) {
-                if (regions[ii]->refs > 0) {
-                    regions[ii]->refs -= 1;
-                    continue;
-                }
-
-                delete regions[ii];
-            }
-
-            delete[] regions;
-
-            for (int ii = 0; ii < argc; ++ii)
-                delete[] argv[ii];
-            delete[] argv;
-        }
-
-        // Dumps the stack contents to standard output.  For debugging.
-        void            DumpStack();
-
-        uint64_t        cpu_time;
-        uint64_t        start_time;
-        uint64_t        end_time;
-        int             tgid;
-        int             pid;
-        int             parent_pid;
-        int             exit_val;
-        uint32_t        flags;
-        int             argc;
-        char            **argv;
-        char            *name;
-        int             nregions;        // num regions in use
-        int             max_regions;     // max regions allocated
-        region_type     **regions;
-        ProcessState    *parent;
-        ProcessState    *addr_manager;   // the address space manager process
-        ProcessState    *next;
-        int             method_stack_top;
-        uint32_t        method_stack[kMaxMethodStackSize];
-        symbol_type     *current_method_sym;
-    };
-
-    TraceReader();
-    ~TraceReader();
-
-    void                ReadKernelSymbols(const char *kernel_file);
-    void                CopyKernelRegion(ProcessState *pstate);
-    void                ClearRegions(ProcessState *pstate);
-    void                CopyRegions(ProcessState *parent, ProcessState *child);
-    symbol_type         *LookupFunction(int pid, uint32_t addr, uint64_t time);
-    symbol_type         *GetSymbols(int *num_syms);
-    ProcessState        *GetCurrentProcess()            { return current_; }
-    ProcessState        *GetProcesses(int *num_procs);
-    ProcessState        *GetNextProcess();
-    char                *GetProcessName(int pid);
-    void                SetRoot(const char *root)       { root_ = root; }
-    void                SetDemangle(bool demangle)      { demangle_ = demangle; }
-    bool                ReadMethodSymbol(MethodRec *method_record,
-                                         symbol_type **psym,
-                                         ProcessState **pproc);
-
-  protected:
-    virtual int FindCurrentPid(uint64_t time);
-
-  private:
-
-    static const int kNumPids = 32768;
-    static const uint32_t kIncludeLocalSymbols = 0x1;
-
-    void                AddPredefinedRegion(region_type *region, const char *path,
-                                            uint32_t vstart, uint32_t vend,
-                                            uint32_t base);
-    void                InitRegionSymbols(region_type *region, int nsymbols);
-    void                AddRegionSymbol(region_type *region, int idx,
-                                        uint32_t addr, const char *name,
-                                        uint32_t flags);
-    void                AddPredefinedRegions(ProcessState *pstate);
-    void                demangle_names(int nfuncs, symbol_type *functions);
-    bool                ReadElfSymbols(region_type *region, uint32_t flags);
-    void                AddRegion(ProcessState *pstate, region_type *region);
-    region_type         *FindRegion(uint32_t addr, int nregions,
-                                    region_type **regions);
-    symbol_type         *FindFunction(uint32_t addr, int nsyms,
-                                      symbol_type *symbols, bool exact_match);
-    symbol_type         *FindCurrentMethod(int pid, uint64_t time);
-    void                PopulateSymbolsFromDexFile(const DexFileList *dexfile,
-                                                   region_type *region);
-    void                HandlePidEvent(PidEvent *event);
-    void                HandleMethodRecord(ProcessState *pstate,
-                                           MethodRec *method_rec);
-
-    int                 cached_pid_;
-    symbol_type         *cached_func_;
-    symbol_type         unknown_;
-    int                 next_pid_;
-
-    PidEvent            next_pid_event_;
-    ProcessState        *processes_[kNumPids];
-    ProcessState        *current_;
-    MethodRec           next_method_;
-    uint64_t            function_start_time_;
-    const char          *root_;
-    HashTable<region_type*> *hash_;
-    bool                demangle_;
-};
-
-template<class T>
-TraceReader<T>::TraceReader()
-{
-    static PidEvent event_no_action;
-
-    cached_pid_ = -1;
-    cached_func_ = NULL;
-
-    memset(&unknown_, 0, sizeof(symbol_type));
-    unknown_.name = "(unknown)";
-    next_pid_ = 0;
-
-    memset(&event_no_action, 0, sizeof(PidEvent));
-    event_no_action.rec_type = kPidNoAction;
-    next_pid_event_ = event_no_action;
-    for (int ii = 1; ii < kNumPids; ++ii)
-        processes_[ii] = NULL;
-    current_ = new ProcessState;
-    processes_[0] = current_;
-    next_method_.time = 0;
-    next_method_.addr = 0;
-    next_method_.flags = 0;
-    function_start_time_ = 0;
-    root_ = "";
-    hash_ = new HashTable<region_type*>(512);
-    AddPredefinedRegions(current_);
-    demangle_ = true;
-}
-
-template<class T>
-TraceReader<T>::~TraceReader()
-{
-    hash_entry_type *ptr;
-    for (ptr = hash_->GetFirst(); ptr; ptr = hash_->GetNext()) {
-        region_type *region = ptr->value;
-        int nsymbols = region->nsymbols;
-        for (int ii = 0; ii < nsymbols; ii++) {
-            delete[] region->symbols[ii].name;
-        }
-        delete[] region->symbols;
-        delete[] region->path;
-
-        // Do not delete the region itself here.  Each region
-        // is reference-counted and deleted by the ProcessState
-        // object that owns it.
-    }
-    delete hash_;
-
-    // Delete the ProcessState objects after the region symbols in
-    // the hash table above so that we still have valid region pointers
-    // when deleting the region symbols.
-    for (int ii = 0; ii < kNumPids; ++ii) {
-        delete processes_[ii];
-    }
-}
-
-// This function is used by the qsort() routine to sort symbols
-// into increasing address order.
-template<class T>
-int cmp_symbol_addr(const void *a, const void *b) {
-    typedef typename TraceReader<T>::symbol_type stype;
-
-    const stype *syma = static_cast<stype const *>(a);
-    const stype *symb = static_cast<stype const *>(b);
-    uint32_t addr1 = syma->addr;
-    uint32_t addr2 = symb->addr;
-    if (addr1 < addr2)
-        return -1;
-    if (addr1 > addr2)
-        return 1;
-
-    // The addresses are the same, sort the symbols into
-    // increasing alphabetical order.  But put symbols that
-    // that start with "_" last.
-    if (syma->name[0] == '_' || symb->name[0] == '_') {
-        // Count the number of leading underscores and sort the
-        // symbol with the most underscores last.
-        int aCount = 0;
-        while (syma->name[aCount] == '_')
-            aCount += 1;
-        int bCount = 0;
-        while (symb->name[bCount] == '_')
-            bCount += 1;
-        if (aCount < bCount) {
-            return -1;
-        }
-        if (aCount > bCount) {
-            return 1;
-        }
-        // If the symbols have the same number of underscores, then
-        // fall through and sort by the whole name.
-    }
-    return strcmp(syma->name, symb->name);
-}
-
-// This function is used by the qsort() routine to sort region entries
-// into increasing address order.
-template<class T>
-int cmp_region_addr(const void *a, const void *b) {
-    typedef typename TraceReader<T>::region_type rtype;
-
-    const rtype *ma = *static_cast<rtype* const *>(a);
-    const rtype *mb = *static_cast<rtype* const *>(b);
-    uint32_t addr1 = ma->vstart;
-    uint32_t addr2 = mb->vstart;
-    if (addr1 < addr2)
-        return -1;
-    if (addr1 == addr2)
-        return 0;
-    return 1;
-}
-
-// This routine returns a new array containing all the symbols.
-template<class T>
-typename TraceReader<T>::symbol_type*
-TraceReader<T>::GetSymbols(int *num_syms)
-{
-    // Count the symbols
-    int nsyms = 0;
-    for (hash_entry_type *ptr = hash_->GetFirst(); ptr; ptr = hash_->GetNext()) {
-        region_type *region = ptr->value;
-        nsyms += region->nsymbols;
-    }
-    *num_syms = nsyms;
-
-    // Allocate space
-    symbol_type *syms = new symbol_type[nsyms];
-    symbol_type *next_sym = syms;
-
-    // Copy the symbols
-    for (hash_entry_type *ptr = hash_->GetFirst(); ptr; ptr = hash_->GetNext()) {
-        region_type *region = ptr->value;
-        memcpy(next_sym, region->symbols, region->nsymbols * sizeof(symbol_type));
-        next_sym += region->nsymbols;
-    }
-
-    return syms;
-}
-
-// This routine returns all the valid processes.
-template<class T>
-typename TraceReader<T>::ProcessState*
-TraceReader<T>::GetProcesses(int *num_procs)
-{
-    // Count the valid processes
-    int nprocs = 0;
-    for (int ii = 0; ii < kNumPids; ++ii) {
-        if (processes_[ii])
-            nprocs += 1;
-    }
-
-    // Allocate a new array to hold the valid processes.
-    ProcessState *procs = new ProcessState[nprocs];
-
-    // Copy the processes to the new array.
-    ProcessState *pstate = procs;
-    for (int ii = 0; ii < kNumPids; ++ii) {
-        if (processes_[ii])
-            memcpy(pstate++, processes_[ii], sizeof(ProcessState));
-    }
-
-    *num_procs = nprocs;
-    return procs;
-}
-
-// This routine returns the next valid process, or NULL if there are no
-// more valid processes.
-template<class T>
-typename TraceReader<T>::ProcessState*
-TraceReader<T>::GetNextProcess()
-{
-    while (next_pid_ < kNumPids) {
-        if (processes_[next_pid_])
-            return processes_[next_pid_++];
-        next_pid_ += 1;
-    }
-    next_pid_ = 0;
-    return NULL;
-}
-
-template<class T>
-char* TraceReader<T>::GetProcessName(int pid)
-{
-    if (pid < 0 || pid >= kNumPids || processes_[pid] == NULL)
-        return "(unknown)";
-    return processes_[pid]->name;
-}
-
-template<class T>
-void TraceReader<T>::AddPredefinedRegion(region_type *region, const char *path,
-                                         uint32_t vstart, uint32_t vend,
-                                         uint32_t base)
-{
-    // Copy the path to make it easy to delete later.
-    int len = strlen(path);
-    region->path = new char[len + 1];
-    strcpy(region->path, path);
-    region->vstart = vstart;
-    region->vend = vend;
-    region->base_addr = base;
-    region->flags = region_type::kIsKernelRegion;
-}
-
-template<class T>
-void TraceReader<T>::InitRegionSymbols(region_type *region, int nsymbols)
-{
-    region->nsymbols = nsymbols;
-    region->symbols = new symbol_type[nsymbols];
-    memset(region->symbols, 0, nsymbols * sizeof(symbol_type));
-}
-
-template<class T>
-void TraceReader<T>::AddRegionSymbol(region_type *region, int idx,
-                                     uint32_t addr, const char *name,
-                                     uint32_t flags)
-{
-    region->symbols[idx].addr = addr;
-    region->symbols[idx].name = Strdup(name);
-    region->symbols[idx].vm_sym = NULL;
-    region->symbols[idx].region = region;
-    region->symbols[idx].flags = flags;
-}
-
-template<class T>
-void TraceReader<T>::AddPredefinedRegions(ProcessState *pstate)
-{
-    region_type *region = new region_type;
-    AddPredefinedRegion(region, "(bootloader)", 0, 0x14, 0);
-    InitRegionSymbols(region, 2);
-    AddRegionSymbol(region, 0, 0, "(bootloader_start)", 0);
-    AddRegionSymbol(region, 1, 0x14, "(bootloader_end)", 0);
-    AddRegion(pstate, region);
-    hash_->Update(region->path, region);
-
-    region = new region_type;
-    AddPredefinedRegion(region, "(exception vectors)", 0xffff0000, 0xffff0500,
-                        0xffff0000);
-    InitRegionSymbols(region, 2);
-    AddRegionSymbol(region, 0, 0x0, "(vector_start)",
-                    symbol_type::kIsVectorStart);
-    AddRegionSymbol(region, 1, 0x500, "(vector_end)", 0);
-    AddRegion(pstate, region);
-    hash_->Update(region->path, region);
-
-    region = new region_type;
-    AddPredefinedRegion(region, "(atomic ops)", 0xffff0f80, 0xffff1000,
-                        0xffff0f80);
-    // Mark this region as also being mapped in user-space.
-    // This isn't used anywhere in this code but client code can test for
-    // this flag and decide whether to treat this as kernel or user code.
-    region->flags |= region_type::kIsUserMappedRegion;
-
-    InitRegionSymbols(region, 4);
-    AddRegionSymbol(region, 0, 0x0, "(kuser_atomic_inc)", 0);
-    AddRegionSymbol(region, 1, 0x20, "(kuser_atomic_dec)", 0);
-    AddRegionSymbol(region, 2, 0x40, "(kuser_cmpxchg)", 0);
-    AddRegionSymbol(region, 3, 0x80, "(kuser_end)", 0);
-    AddRegion(pstate, region);
-    hash_->Update(region->path, region);
-}
-
-template<class T>
-void TraceReader<T>::ReadKernelSymbols(const char *kernel_file)
-{
-    region_type *region = new region_type;
-    // Copy the path to make it easy to delete later.
-    int len = strlen(kernel_file);
-    region->path = new char[len + 1];
-    strcpy(region->path, kernel_file);
-    region->flags = region_type::kIsKernelRegion;
-    ReadElfSymbols(region, kIncludeLocalSymbols);
-    region->vend = 0xffff0000;
-    AddRegion(processes_[0], region);
-    processes_[0]->flags |= ProcessState::kHasKernelRegion;
-    hash_->Update(region->path, region);
-}
-
-template<class T>
-void TraceReader<T>::demangle_names(int nfuncs, symbol_type *functions)
-{
-    char *demangled;
-    int status;
-
-    for (int ii = 0; ii < nfuncs; ++ii) {
-        demangled = NULL;
-        int len = strlen(functions[ii].name);
-
-        // If we don't check for "len > 1" then the demangler will incorrectly
-        // expand 1-letter function names.  For example, "b" becomes "bool",
-        // "c" becomes "char" and "d" becomes "double".  Also check that the
-        // first character is an underscore.  Otherwise, on some strings
-        // the demangler will try to read past the end of the string (because
-        // the string is not really a C++ mangled name) and valgrind will
-        // complain.
-        if (demangle_ && len > 1 && functions[ii].name[0] == '_') {
-            demangled = abi::__cxa_demangle(functions[ii].name, 0, NULL,
-                                            &status);
-        }
-
-        if (demangled != NULL) {
-            delete[] functions[ii].name;
-            functions[ii].name = Strdup(demangled);
-            free(demangled);
-        }
-    }
-}
-
-// Adds the symbols from the given ELF file to the given process.
-// Returns false if the file was not an ELF file or if there was an
-// error trying to read the sections of the ELF file.
-template<class T>
-bool TraceReader<T>::ReadElfSymbols(region_type *region, uint32_t flags)
-{
-    static char full_path[4096];
-    Elf32_Shdr  *symtab, *symstr;
-    Elf32_Ehdr  *hdr;
-    Elf32_Shdr  *shdr;
-
-    full_path[0] = 0;
-    if (root_ && strcmp(root_, "/")) {
-        strcpy(full_path, root_);
-    }
-    strcat(full_path, region->path);
-    FILE *fobj = fopen(full_path, "r");
-    if(fobj == NULL) {
-    EmptyRegion:
-        // we need to create an (unknown) symbol with address 0, otherwise some
-        // other parts of the trace reader will simply crash when dealing with
-        // an empty region
-        region->vstart = 0;
-        region->nsymbols = 1;
-        region->symbols  = new symbol_type[1];
-        memset(region->symbols, 0, sizeof(symbol_type));
-
-        region->symbols[0].addr   = 0;
-        region->symbols[0].name   = Strdup("(unknown)");
-        region->symbols[0].vm_sym = NULL;
-        region->symbols[0].region = region;
-        region->symbols[0].flags  = 0;
-
-        if (fobj != NULL)
-            fclose(fobj);
-        return false;
-    }
-
-    hdr = ReadElfHeader(fobj);
-    if (hdr == NULL) {
-        fprintf(stderr, "Cannot read ELF header from '%s'\n", full_path);
-        goto EmptyRegion;
-    }
-
-    shdr = ReadSectionHeaders(hdr, fobj);
-    if(shdr == NULL) {
-        fprintf(stderr, "Can't read section headers from executable\n");
-        goto EmptyRegion;
-    }
-    char *section_names = ReadStringTable(hdr, shdr, fobj);
-
-    // Get the symbol table section
-    symtab = FindSymbolTableSection(hdr, shdr, section_names);
-    if (symtab == NULL || symtab->sh_size == 0) {
-        fprintf(stderr, "Can't read symbol table from '%s'\n", full_path);
-        goto EmptyRegion;
-    }
-
-    // Get the symbol string table section
-    symstr = FindSymbolStringTableSection(hdr, shdr, section_names);
-    if (symstr == NULL || symstr->sh_size == 0) {
-        fprintf(stderr, "Can't read symbol string table from '%s'\n", full_path);
-        goto EmptyRegion;
-    }
-
-    // Load the symbol string table data
-    char *symbol_names = new char[symstr->sh_size];
-    ReadSection(symstr, symbol_names, fobj);
-
-    int num_entries = symtab->sh_size / symtab->sh_entsize;
-    Elf32_Sym *elf_symbols = new Elf32_Sym[num_entries];
-    ReadSection(symtab, elf_symbols, fobj);
-    AdjustElfSymbols(hdr, elf_symbols, num_entries);
-#if 0
-    printf("size: %d, ent_size: %d, num_entries: %d\n",
-           symtab->sh_size, symtab->sh_entsize, num_entries);
-#endif
-    int nfuncs = 0;
-
-    // Allocate space for all of the symbols for now.  We will
-    // reallocate space for just the function symbols after we
-    // know how many there are.  Also, make sure there is room
-    // for some extra symbols, including the text section names.
-    int num_alloc = num_entries + hdr->e_shnum + 1;
-    symbol_type *func_symbols = new symbol_type[num_alloc];
-    memset(func_symbols, 0, num_alloc * sizeof(symbol_type));
-
-    // If this is the shared library for a virtual machine, then
-    // set the IsInterpreter flag for all symbols in that shared library.
-    // This will allow us to replace the symbol names with the name of
-    // the currently executing method on the virtual machine.
-    int symbol_flags = 0;
-    char *cp = strrchr(region->path, '/');
-    if (cp != NULL) {
-        // Move past the '/'
-        cp += 1;
-    } else {
-        // There was no '/', so use the whole path
-        cp = region->path;
-    }
-    if (strcmp(cp, "libdvm.so") == 0) {
-        symbol_flags = symbol_type::kIsInterpreter;
-    }
-
-    bool zero_found = false;
-    for (int ii = 1; ii < num_entries; ++ii) {
-        int idx = elf_symbols[ii].st_name;
-
-        // If the symbol does not have a name, or if the name starts with a
-        // dollar sign ($), then skip it.
-        if (idx == 0 || symbol_names[idx] == 0 || symbol_names[idx] == '$')
-            continue;
-
-        // If the section index is not executable, then skip it.
-        uint32_t section = elf_symbols[ii].st_shndx;
-        if (section == 0 || section >= hdr->e_shnum)
-            continue;
-        if ((shdr[section].sh_flags & SHF_EXECINSTR) == 0)
-            continue;
-
-        uint8_t sym_type = ELF32_ST_TYPE(elf_symbols[ii].st_info);
-        uint8_t sym_bind = ELF32_ST_BIND(elf_symbols[ii].st_info);
-
-        // Allow the caller to decide if we want local non-function
-        // symbols to be included.  We currently include these symbols
-        // only for the kernel, where it is useful because the kernel
-        // has lots of assembly language labels that have meaningful names.
-        if ((flags & kIncludeLocalSymbols) == 0 && sym_bind == STB_LOCAL
-            && sym_type != STT_FUNC) {
-            continue;
-        }
-#if 0
-        printf("%08x %x %x %s\n",
-               elf_symbols[ii].st_value,
-               sym_bind,
-               sym_type,
-               &symbol_names[idx]);
-#endif
-        if (sym_type != STT_FUNC && sym_type != STT_NOTYPE)
-            continue;
-
-        if (elf_symbols[ii].st_value == 0)
-            zero_found = true;
-
-        // The address of thumb functions seem to have the low bit set,
-        // even though the instructions are really at an even address.
-        uint32_t addr = elf_symbols[ii].st_value & ~0x1;
-        func_symbols[nfuncs].addr = addr;
-        func_symbols[nfuncs].name = Strdup(&symbol_names[idx]);
-        func_symbols[nfuncs].flags = symbol_flags;
-
-        nfuncs += 1;
-    }
-
-    // Add a [0, "(unknown)"] symbol pair if there is not already a
-    // symbol with the address zero.  We don't need to reallocate space
-    // because we already have more than we need.
-    if (!zero_found) {
-        func_symbols[nfuncs].addr = 0;
-        func_symbols[nfuncs].name = Strdup("(0 unknown)");
-        nfuncs += 1;
-    }
-
-    // Add another entry at the end
-    func_symbols[nfuncs].addr = 0xffffffff;
-    func_symbols[nfuncs].name = Strdup("(end)");
-    nfuncs += 1;
-
-    // Add in the names of the text sections, but only if there
-    // are no symbols with that address already.
-    for (int section = 0; section < hdr->e_shnum; ++section) {
-        if ((shdr[section].sh_flags & SHF_EXECINSTR) == 0)
-            continue;
-
-        uint32_t addr = shdr[section].sh_addr;
-        // Search for a symbol with a matching address.  The symbols aren't
-        // sorted yet so we just search the whole list.
-        int ii;
-        for (ii = 0; ii < nfuncs; ++ii) {
-            if (addr == func_symbols[ii].addr)
-                break;
-        }
-        if (ii == nfuncs) {
-            // Symbol at address "addr" does not exist, so add the text
-            // section name.  This will usually add the ".plt" section
-            // (procedure linkage table).
-            int idx = shdr[section].sh_name;
-            func_symbols[nfuncs].addr = addr;
-            func_symbols[nfuncs].name = Strdup(&section_names[idx]);
-            if (strcmp(func_symbols[nfuncs].name, ".plt") == 0) {
-                func_symbols[nfuncs].flags |= symbol_type::kIsPlt;
-                // Change the name of the symbol to include the
-                // name of the library.  Otherwise we will have lots
-                // of ".plt" symbols.
-                int len = strlen(region->path);
-                len += strlen(":.plt");
-                char *name = new char[len + 1];
-                strcpy(name, region->path);
-                strcat(name, ":.plt");
-                delete[] func_symbols[nfuncs].name;
-                func_symbols[nfuncs].name = name;
-
-                // Check if this is part of the virtual machine interpreter
-                char *cp = strrchr(region->path, '/');
-                if (cp != NULL) {
-                    // Move past the '/'
-                    cp += 1;
-                } else {
-                    // There was no '/', so use the whole path
-                    cp = region->path;
-                }
-                if (strcmp(cp, "libdvm.so") == 0) {
-                    func_symbols[nfuncs].flags |= symbol_type::kIsInterpreter;
-                }
-            }
-            nfuncs += 1;
-        }
-    }
-
-    // Allocate just the space we need now that we know exactly
-    // how many symbols we have.
-    symbol_type *functions = new symbol_type[nfuncs];
-
-    // Copy the symbols to the functions array
-    memcpy(functions, func_symbols, nfuncs * sizeof(symbol_type));
-    delete[] func_symbols;
-
-    // Assign the region pointers
-    for (int ii = 0; ii < nfuncs; ++ii) {
-        functions[ii].region = region;
-    }
-
-    // Sort the symbols into increasing address order
-    qsort(functions, nfuncs, sizeof(symbol_type), cmp_symbol_addr<T>);
-
-    // If there are multiple symbols with the same address, then remove
-    // the duplicates.  First, count the number of duplicates.
-    uint32_t prev_addr = ~0;
-    int num_duplicates = 0;
-    for (int ii = 0; ii < nfuncs; ++ii) {
-        if (prev_addr == functions[ii].addr)
-            num_duplicates += 1;
-        prev_addr = functions[ii].addr;
-    }
- 
-    if (num_duplicates > 0) {
-        int num_uniq = nfuncs - num_duplicates;
-
-        // Allocate space for the unique functions
-        symbol_type *uniq_functions = new symbol_type[num_uniq];
-
-        // Copy the unique functions
-        prev_addr = ~0;
-        int next_uniq = 0;
-        for (int ii = 0; ii < nfuncs; ++ii) {
-            if (prev_addr == functions[ii].addr) {
-                delete[] functions[ii].name;
-                continue;
-            }
-            memcpy(&uniq_functions[next_uniq++], &functions[ii],
-                   sizeof(symbol_type));
-            prev_addr = functions[ii].addr;
-        }
-        assert(next_uniq == num_uniq);
-
-        delete[] functions;
-        functions = uniq_functions;
-        nfuncs = num_uniq;
-    }
-
-    // Finally, demangle all of the symbol names
-    demangle_names(nfuncs, functions);
-
-    uint32_t min_addr = 0;
-    if (!zero_found)
-        min_addr = functions[1].addr;
-    if (region->vstart == 0)
-        region->vstart = min_addr;
-    region->nsymbols = nfuncs;
-    region->symbols = functions;
-
-#if 0
-    printf("%s num symbols: %d min_addr: 0x%x\n", region->path, nfuncs, min_addr);
-    for (int ii = 0; ii < nfuncs; ++ii) {
-        printf("0x%08x %s\n", functions[ii].addr, functions[ii].name);
-    }
-#endif
-    delete[] elf_symbols;
-    delete[] symbol_names;
-    delete[] section_names;
-    delete[] shdr;
-    delete hdr;
-    fclose(fobj);
-    
-    return true;
-}
-
-template<class T>
-void TraceReader<T>::CopyKernelRegion(ProcessState *pstate)
-{
-    ProcessState *manager = pstate->addr_manager;
-    if (manager->flags & ProcessState::kHasKernelRegion)
-        return;
-
-    int nregions = processes_[0]->nregions;
-    region_type **regions = processes_[0]->regions;
-    for (int ii = 0; ii < nregions; ii++) {
-        if (regions[ii]->flags & region_type::kIsKernelRegion) {
-            AddRegion(manager, regions[ii]);
-            regions[ii]->refs += 1;
-        }
-    }
-    manager->flags |= ProcessState::kHasKernelRegion;
-}
-
-template<class T>
-void TraceReader<T>::ClearRegions(ProcessState *pstate)
-{
-    assert(pstate->pid != 0);
-    int nregions = pstate->nregions;
-    region_type **regions = pstate->regions;
-
-    // Decrement the reference count on all the regions
-    for (int ii = 0; ii < nregions; ii++) {
-        if (regions[ii]->refs > 0) {
-            regions[ii]->refs -= 1;
-            continue;
-        }
-
-        delete regions[ii];
-    }
-    delete[] pstate->regions;
-    pstate->regions = NULL;
-    pstate->nregions = 0;
-    pstate->max_regions = 0;
-    pstate->addr_manager = pstate;
-    pstate->flags &= ~ProcessState::kIsClone;
-    pstate->flags &= ~ProcessState::kHasKernelRegion;
-    CopyKernelRegion(pstate);
-}
-
-template<class T>
-void TraceReader<T>::AddRegion(ProcessState *pstate, region_type *region)
-{
-    ProcessState *manager = pstate->addr_manager;
-    if (manager->regions == NULL) {
-        manager->max_regions = ProcessState::kInitialNumRegions;
-        manager->regions = new region_type*[manager->max_regions];
-        manager->nregions = 0;
-    }
-
-    // Check if we need to grow the array
-    int nregions = manager->nregions;
-    int max_regions = manager->max_regions;
-    if (nregions >= max_regions) {
-        max_regions <<= 1;
-        manager->max_regions = max_regions;
-        region_type **regions = new region_type*[max_regions];
-        for (int ii = 0; ii < nregions; ii++) {
-            regions[ii] = manager->regions[ii];
-        }
-        delete[] manager->regions;
-        manager->regions = regions;
-    }
-
-    // Add the new region to the end of the array and resort
-    manager->regions[nregions] = region;
-    nregions += 1;
-    manager->nregions = nregions;
-
-    // Resort the regions into increasing start address
-    qsort(manager->regions, nregions, sizeof(region_type*), cmp_region_addr<T>);
-}
-
-template<class T>
-void TraceReader<T>::CopyRegions(ProcessState *parent, ProcessState *child)
-{
-    // Copy the parent's address space
-    ProcessState *manager = parent->addr_manager;
-    int nregions = manager->nregions;
-    child->nregions = nregions;
-    child->max_regions = manager->max_regions;
-    region_type **regions = new region_type*[manager->max_regions];
-    child->regions = regions;
-    memcpy(regions, manager->regions, nregions * sizeof(region_type*));
-
-    // Increment the reference count on all the regions
-    for (int ii = 0; ii < nregions; ii++) {
-        regions[ii]->refs += 1;
-    }
-}
-
-template<class T>
-typename TraceReader<T>::region_type *
-TraceReader<T>::FindRegion(uint32_t addr, int nregions, region_type **regions)
-{
-    int high = nregions;
-    int low = -1;
-    while (low + 1 < high) {
-        int middle = (high + low) / 2;
-        uint32_t middle_addr = regions[middle]->vstart;
-        if (middle_addr == addr)
-            return regions[middle];
-        if (middle_addr > addr)
-            high = middle;
-        else
-            low = middle;
-    }
-
-    // If we get here then we did not find an exact address match.  So use
-    // the closest region address that is less than the given address.
-    if (low < 0)
-        low = 0;
-    return regions[low];
-}
-
-template<class T>
-typename TraceReader<T>::symbol_type *
-TraceReader<T>::FindFunction(uint32_t addr, int nsyms, symbol_type *symbols,
-                             bool exact_match)
-{
-    int high = nsyms;
-    int low = -1;
-    while (low + 1 < high) {
-        int middle = (high + low) / 2;
-        uint32_t middle_addr = symbols[middle].addr;
-        if (middle_addr == addr)
-            return &symbols[middle];
-        if (middle_addr > addr)
-            high = middle;
-        else
-            low = middle;
-    }
-
-    // If we get here then we did not find an exact address match.  So use
-    // the closest function address that is less than the given address.
-    // We added a symbol with address zero so if there is no known
-    // function containing the given address, then we will return the
-    // "(unknown)" symbol.
-    if (low >= 0 && !exact_match)
-        return &symbols[low];
-    return NULL;
-}
-
-template<class T>
-typename TraceReader<T>::symbol_type *
-TraceReader<T>::LookupFunction(int pid, uint32_t addr, uint64_t time)
-{
-    // Check if the previous match is still a good match.
-    if (cached_pid_ == pid) {
-        uint32_t vstart = cached_func_->region->vstart;
-        uint32_t vend = cached_func_->region->vend;
-        if (addr >= vstart && addr < vend) {
-            uint32_t sym_addr = addr - cached_func_->region->base_addr;
-            if (sym_addr >= cached_func_->addr
-                && sym_addr < (cached_func_ + 1)->addr) {
-                // If this function is the virtual machine interpreter, then
-                // read the method trace to find the "real" method name based
-                // on the current time and pid.
-                if (cached_func_->flags & symbol_type::kIsInterpreter) {
-                    symbol_type *sym = FindCurrentMethod(pid, time);
-                    if (sym != NULL) {
-                        sym->vm_sym = cached_func_;
-                        return sym;
-                    }
-                }
-                return cached_func_;
-            }
-        }
-    }
-
-    ProcessState *pstate = processes_[pid];
-    if (pstate == NULL) {
-        // There is no process state for the specified pid.
-        // This should never happen.
-        cached_pid_ = -1;
-        cached_func_ = NULL;
-        return NULL;
-    }
-    ProcessState *manager = pstate->addr_manager;
-    cached_pid_ = pid;
-    region_type *region = FindRegion(addr, manager->nregions, manager->regions);
-    uint32_t sym_addr = addr - region->base_addr;
-
-    cached_func_ = FindFunction(sym_addr, region->nsymbols, region->symbols,
-                                false /* no exact match */);
-    if (cached_func_ != NULL) {
-        cached_func_->region = region;
-
-        // If this function is the virtual machine interpreter, then
-        // read the method trace to find the "real" method name based
-        // on the current time and pid.
-        if (cached_func_->flags & symbol_type::kIsInterpreter) {
-            symbol_type *sym = FindCurrentMethod(pid, time);
-            if (sym != NULL) {
-                sym->vm_sym = cached_func_;
-                return sym;
-            }
-        }
-    }
-
-    return cached_func_;
-}
-
-template <class T>
-void TraceReader<T>::HandlePidEvent(PidEvent *event)
-{
-    switch (event->rec_type) {
-    case kPidFork:
-    case kPidClone:
-        // event->pid is the process id of the child
-        if (event->pid >= kNumPids) {
-            fprintf(stderr, "Error: pid (%d) too large\n", event->pid);
-            exit(1);
-        }
-        // Create a new ProcessState struct for the child
-        // and link it in at the front of the list for that
-        // pid.
-        {
-            ProcessState *child = new ProcessState;
-            processes_[event->pid] = child;
-            child->pid = event->pid;
-            child->tgid = event->tgid;
-
-            // Link the new child at the front of the list (only needed if
-            // pids wrap around, which will probably never happen when
-            // tracing because it would take so long).
-            child->next = processes_[event->pid];
-            child->parent_pid = current_->pid;
-            child->parent = current_;
-            child->start_time = event->time;
-            child->name = Strdup(current_->name);
-            if (event->rec_type == kPidFork) {
-                CopyRegions(current_, child);
-            } else {
-                // Share the parent's address space
-                child->flags |= ProcessState::kIsClone;
-
-                // The address space manager for the clone is the same
-                // as the address space manager for the parent.  This works
-                // even if the child later clones itself.
-                child->addr_manager = current_->addr_manager;
-            }
-        }
-        break;
-    case kPidSwitch:
-        // event->pid is the process id of the process we are
-        // switching to.
-        {
-            uint64_t elapsed = event->time - function_start_time_;
-            function_start_time_ = event->time;
-            current_->cpu_time += elapsed;
-        }
-        if (current_->flags & ProcessState::kCalledExit)
-            current_->end_time = event->time;
-
-        if (event->pid >= kNumPids) {
-            fprintf(stderr, "Error: pid (%d) too large\n", event->pid);
-            exit(1);
-        }
-
-        // If the process we are switching to does not exist, then
-        // create one.  This can happen because the tracing code does
-        // not start tracing from the very beginning of the kernel.
-        current_ = processes_[event->pid];
-        if (current_ == NULL) {
-            current_ = new ProcessState;
-            processes_[event->pid] = current_;
-            current_->pid = event->pid;
-            current_->start_time = event->time;
-            CopyKernelRegion(current_);
-        }
-#if 0
-        {
-            printf("switching to p%d\n", current_->pid);
-            ProcessState *manager = current_->addr_manager;
-            for (int ii = 0; ii < manager->nregions; ++ii) {
-                printf("  %08x - %08x offset: %d nsyms: %4d %s\n",
-                       manager->regions[ii]->vstart,
-                       manager->regions[ii]->vend,
-                       manager->regions[ii]->file_offset,
-                       manager->regions[ii]->nsymbols,
-                       manager->regions[ii]->path);
-            }
-        }
-#endif
-        break;
-    case kPidExit:
-        current_->exit_val = event->pid;
-        current_->flags |= ProcessState::kCalledExit;
-        break;
-    case kPidMmap:
-        {
-            region_type *region;
-            region_type *existing_region = hash_->Find(event->path);
-            if (existing_region == NULL || existing_region->vstart != event->vstart) {
-                // Create a new region and add it to the current process'
-                // address space.
-                region = new region_type;
-
-                // The event->path is allocated by ReadPidEvent() and owned
-                // by us.
-                region->path = event->path;
-                region->vstart = event->vstart;
-                region->vend = event->vend;
-                region->file_offset = event->offset;
-                if (existing_region == NULL) {
-                    DexFileList *dexfile = dex_hash_->Find(event->path);
-                    if (dexfile != NULL) {
-                        PopulateSymbolsFromDexFile(dexfile, region);
-                    } else {
-                        ReadElfSymbols(region, 0);
-                    }
-                    hash_->Update(region->path, region);
-                } else {
-                    region->nsymbols = existing_region->nsymbols;
-                    region->symbols = existing_region->symbols;
-                    region->path = existing_region->path;
-                    delete[] event->path;
-                    region->flags |= region_type::kSharedSymbols;
-                }
-
-                // The base_addr is subtracted from an address before the
-                // symbol name lookup and is either zero or event->vstart.
-                // HACK: Determine if base_addr is non-zero by looking at the
-                // second symbol address (skip the first symbol because that is
-                // the special symbol "(unknown)" with an address of zero).
-                if (region->nsymbols > 2 && region->symbols[1].addr < event->vstart)
-                    region->base_addr = event->vstart;
-
-                // Treat all mmapped regions after the first as "libraries".
-                // Profiling tools can test for this property.
-                if (current_->flags & ProcessState::kHasFirstMmap)
-                    region->flags |= region_type::kIsLibraryRegion;
-                else
-                    current_->flags |= ProcessState::kHasFirstMmap;
-#if 0
-                printf("%s vstart: 0x%x vend: 0x%x offset: 0x%x\n",
-                       region->path, region->vstart, region->vend, region->file_offset);
-#endif
-            } else {
-                region = existing_region;
-                region->refs += 1;
-                delete[] event->path;
-            }
-            AddRegion(current_, region);
-        }
-        break;
-    case kPidExec:
-        if (current_->argc > 0) {
-            for (int ii = 0; ii < current_->argc; ii++) {
-                delete[] current_->argv[ii];
-            }
-            delete[] current_->argv;
-        }
-        delete[] current_->name;
-
-        current_->argc = event->argc;
-        current_->argv = event->argv;
-        current_->name = Strdup(current_->argv[0]);
-        current_->flags |= ProcessState::kCalledExec;
-        ClearRegions(current_);
-        break;
-    case kPidName:
-    case kPidKthreadName:
-        {
-            ProcessState *pstate = processes_[event->pid];
-            if (pstate == NULL) {
-                pstate = new ProcessState;
-                if (event->rec_type == kPidKthreadName) {
-                    pstate->tgid = event->tgid;
-                }
-                pstate->pid = event->pid;
-                pstate->start_time = event->time;
-                processes_[event->pid] = pstate;
-                CopyKernelRegion(pstate);
-            } else {
-                delete[] pstate->name;
-            }
-            pstate->name = event->path;
-        }
-        break;
-    case kPidNoAction:
-        break;
-    case kPidSymbolAdd:
-        delete[] event->path;
-        break;
-    case kPidSymbolRemove:
-        break;
-    }
-}
-
-// Finds the current pid for the given time.  This routine reads the pid
-// trace file and assumes that the "time" parameter is monotonically
-// increasing.
-template <class T>
-int TraceReader<T>::FindCurrentPid(uint64_t time)
-{
-    if (time < next_pid_event_.time)
-        return current_->pid;
-
-    while (1) {
-        HandlePidEvent(&next_pid_event_);
-
-        if (internal_pid_reader_->ReadPidEvent(&next_pid_event_)) {
-            next_pid_event_.time = ~0ull;
-            break;
-        }
-        if (next_pid_event_.time > time)
-            break;
-    }
-    return current_->pid;
-}
-
-template <class T>
-void TraceReader<T>::ProcessState::DumpStack()
-{
-    for (int ii = 0; ii < method_stack_top; ii++) {
-        printf("%2d: 0x%08x\n", ii, method_stack[ii]);
-    }
-}
-
-template <class T>
-void TraceReader<T>::HandleMethodRecord(ProcessState *pstate,
-                                        MethodRec *method_rec)
-{
-    uint32_t addr;
-    int top = pstate->method_stack_top;
-    if (method_rec->flags == kMethodEnter) {
-        // Push this method on the stack
-        if (top >= pstate->kMaxMethodStackSize) {
-            fprintf(stderr, "Stack overflow at time %llu\n", method_rec->time);
-            exit(1);
-        }
-        pstate->method_stack[top] = method_rec->addr;
-        pstate->method_stack_top = top + 1;
-        addr = method_rec->addr;
-    } else {
-        if (top <= 0) {
-            // If the stack underflows, then set the current method to NULL.
-            pstate->current_method_sym = NULL;
-            return;
-        }
-        top -= 1;
-        addr = pstate->method_stack[top];
-        if (addr != method_rec->addr) {
-            fprintf(stderr,
-                    "Stack method (0x%x) at index %d does not match trace record (0x%x) at time %llu\n",
-                    addr, top, method_rec->addr, method_rec->time);
-            for (int ii = 0; ii <= top; ii++) {
-                fprintf(stderr, "  %d: 0x%x\n", ii, pstate->method_stack[ii]);
-            }
-            exit(1);
-        }
-
-        pstate->method_stack_top = top;
-        if (top == 0) {
-            // When we empty the stack, set the current method to NULL
-            pstate->current_method_sym = NULL;
-            return;
-        }
-        addr = pstate->method_stack[top - 1];
-    }
-    ProcessState *manager = pstate->addr_manager;
-    region_type *region = FindRegion(addr, manager->nregions, manager->regions);
-    uint32_t sym_addr = addr - region->base_addr;
-    symbol_type *sym = FindFunction(sym_addr, region->nsymbols,
-                                    region->symbols, true /* exact match */);
-
-    pstate->current_method_sym = sym;
-    if (sym != NULL) {
-        sym->region = region;
-    }
-}
-
-template <class T>
-typename TraceReader<T>::symbol_type*
-TraceReader<T>::FindCurrentMethod(int pid, uint64_t time)
-{
-    ProcessState *procState = processes_[pid];
-
-    if (time < next_method_.time) {
-        return procState->current_method_sym;
-    }
-
-    while (1) {
-        if (next_method_.time != 0) {
-            // We may have to process methods from a different pid so use
-            // a local variable here so that we don't overwrite procState.
-            ProcessState *pState = processes_[next_method_.pid];
-            HandleMethodRecord(pState, &next_method_);
-        }
-
-        if (internal_method_reader_->ReadMethod(&next_method_)) {
-            next_method_.time = ~0ull;
-            break;
-        }
-        if (next_method_.time > time)
-            break;
-    }
-    return procState->current_method_sym;
-}
-
-template <class T>
-void TraceReader<T>::PopulateSymbolsFromDexFile(const DexFileList *dexfile,
-                                                region_type *region)
-                                                
-{
-    int nsymbols = dexfile->nsymbols;
-    DexSym *dexsyms = dexfile->symbols;
-    region->nsymbols = nsymbols + 1;
-    symbol_type *symbols = new symbol_type[nsymbols + 1];
-    memset(symbols, 0, (nsymbols + 1) * sizeof(symbol_type));
-    region->symbols = symbols;
-    for (int ii = 0; ii < nsymbols; ii++) {
-        symbols[ii].addr = dexsyms[ii].addr;
-        symbols[ii].name = Strdup(dexsyms[ii].name);
-        symbols[ii].vm_sym = NULL;
-        symbols[ii].region = region;
-        symbols[ii].flags = symbol_type::kIsMethod;
-    }
-
-    // Add an entry at the end with an address of 0xffffffff.  This
-    // is required for LookupFunction() to work.
-    symbol_type *symbol = &symbols[nsymbols];
-    symbol->addr = 0xffffffff;
-    symbol->name = Strdup("(end)");
-    symbol->vm_sym = NULL;
-    symbol->region = region;
-    symbol->flags = symbol_type::kIsMethod;
-}
-
-template <class T>
-bool TraceReader<T>::ReadMethodSymbol(MethodRec *method_record,
-                                      symbol_type **psym,
-                                      ProcessState **pproc)
-{
-    if (internal_method_reader_->ReadMethod(&next_method_)) {
-        return true;
-    }
-
-    // Copy the whole MethodRec struct
-    *method_record = next_method_;
-
-    uint64_t time = next_method_.time;
-    
-    // Read the pid trace file up to this point to make sure the
-    // process state is valid.
-    FindCurrentPid(time);
-
-    ProcessState *pstate = processes_[next_method_.pid];
-    *pproc = pstate;
-    HandleMethodRecord(pstate, &next_method_);
-    *psym = pstate->current_method_sym;
-    return false;
-}
-
-#endif /* TRACE_READER_H */
diff --git a/emulator/qtools/trace_reader_base.h b/emulator/qtools/trace_reader_base.h
deleted file mode 100644
index 281d085..0000000
--- a/emulator/qtools/trace_reader_base.h
+++ /dev/null
@@ -1,332 +0,0 @@
-// Copyright 2006 The Android Open Source Project
-
-#ifndef TRACE_READER_BASE_H
-#define TRACE_READER_BASE_H
-
-#include <inttypes.h>
-#include "trace_common.h"
-#include "hash_table.h"
-
-class BBReader;
-class InsnReader;
-class AddrReader;
-class ExcReader;
-class PidReader;
-class MethodReader;
-
-struct StaticRec {
-    uint64_t    bb_num;
-    uint32_t    bb_addr;
-    uint32_t    num_insns;
-};
-
-struct StaticBlock {
-    StaticRec   rec;
-    uint32_t    *insns;
-};
-
-struct BBEvent {
-    uint64_t    time;
-    uint64_t    bb_num;
-    uint32_t    bb_addr;
-    uint32_t    *insns;
-    int         num_insns;
-    int         pid;
-    int         is_thumb;
-};
-
-struct PidEvent {
-    uint64_t    time;
-    int         rec_type;       // record type: fork, context switch, exit ...
-    int         tgid;           // thread group id
-    int         pid;            // for fork: child pid; for switch: next pid;
-                                //   for exit: exit value
-    uint32_t    vstart;         // virtual start address (only used with mmap)
-    uint32_t    vend;           // virtual end address (only used with mmap)
-    uint32_t    offset;         // virtual file offset (only used with mmap)
-
-    // Dynamically allocated path to executable (or lib). In the case of
-    // an mmapped dex file, the path is modified to be more useful for
-    // comparing against the output of dexlist.  For example, instead of this:
-    //   /data/dalvik-cache/system@app@TestHarness.apk@classes.dex
-    // We convert to this:
-    //   /system/app/TestHarness.apk
-    char        *path;
-    char        *mmap_path;     // unmodified mmap path
-    int         argc;           // number of args
-    char        **argv;         // dynamically allocated array of args
-};
-
-struct MethodRec {
-    uint64_t    time;
-    uint32_t    addr;
-    int         pid;
-    int         flags;
-};
-
-struct DexSym {
-    uint32_t    addr;
-    int         len;
-    char        *name;
-};
-
-struct DexFileList {
-    char        *path;
-    int         nsymbols;
-    DexSym      *symbols;
-};
-
-class TraceReaderBase {
-  public:
-    TraceReaderBase();
-    virtual ~TraceReaderBase();
-
-    friend class BBReader;
-
-    void                Open(char *filename);
-    void                Close();
-    void                WriteHeader(TraceHeader *header);
-    inline bool         ReadBB(BBEvent *event);
-    int                 ReadStatic(StaticRec *rec);
-    int                 ReadStaticInsns(int num, uint32_t *insns);
-    TraceHeader         *GetHeader()                { return header_; }
-    inline uint64_t     ReadInsnTime(uint64_t min_time);
-    void                TruncateLastBlock(uint32_t num_insns);
-    inline bool         ReadAddr(uint64_t *time, uint32_t *addr, int *flags);
-    inline bool         ReadExc(uint64_t *time, uint32_t *current_pc,
-                                uint64_t *recnum, uint32_t *target_pc,
-                                uint64_t *bb_num, uint64_t *bb_start_time,
-                                int *num_insns);
-    inline bool         ReadPidEvent(PidEvent *event);
-    inline bool         ReadMethod(MethodRec *method_record);
-    StaticBlock         *GetStaticBlock(uint64_t bb_num) { return &blocks_[bb_num]; }
-    uint32_t            *GetInsns(uint64_t bb_num) { return blocks_[bb_num].insns; }
-    uint32_t            GetBBAddr(uint64_t bb_num) {
-        return blocks_[bb_num].rec.bb_addr & ~1;
-    }
-    int                 GetIsThumb(uint64_t bb_num) {
-        return blocks_[bb_num].rec.bb_addr & 1;
-    }
-    void                SetPostProcessing(bool val) { post_processing_ = val; }
-
-  protected:
-    virtual int         FindCurrentPid(uint64_t time);
-    int                 current_pid_;
-    int                 next_pid_;
-    uint64_t            next_pid_switch_time_;
-    PidReader           *internal_pid_reader_;
-    MethodReader        *internal_method_reader_;
-    HashTable<DexFileList*> *dex_hash_;
-
-  private:
-    int          FindNumInsns(uint64_t bb_num, uint64_t bb_start_time);
-    void         ReadTraceHeader(FILE *fstream, char *filename,
-                                char *tracename, TraceHeader *header);
-    PidEvent     *FindMmapDexFileEvent();
-    void         ParseDexList(char *filename);
-
-    char         *static_filename_;
-    FILE         *static_fstream_;
-    TraceHeader  *header_;
-    BBReader     *bb_reader_;
-    InsnReader   *insn_reader_;
-    AddrReader   *load_addr_reader_;
-    AddrReader   *store_addr_reader_;
-    ExcReader    *exc_reader_;
-    PidReader    *pid_reader_;
-    MethodReader *method_reader_;
-    ExcReader    *internal_exc_reader_;
-    StaticBlock  *blocks_;
-    bool         exc_end_;
-    uint64_t     bb_recnum_;
-    uint64_t     exc_recnum_;
-    uint64_t     exc_bb_num_;
-    uint64_t     exc_time_;
-    int          exc_num_insns_;
-    bool         post_processing_;
-
-    bool         load_eof_;
-    uint64_t     load_time_;
-    uint32_t     load_addr_;
-    bool         store_eof_;
-    uint64_t     store_time_;
-    uint32_t     store_addr_;
-};
-
-class Decoder;
-
-class BBReader {
-  public:
-    explicit BBReader(TraceReaderBase *trace);
-    ~BBReader();
-    void     Open(char *filename);
-    void     Close();
-    bool     ReadBB(BBEvent *event);
-
-  private:
-    struct TimeRec {
-        BBRec       bb_rec;
-        uint64_t    next_time;
-    };
-
-    struct Future {
-        Future      *next;
-        TimeRec     bb;
-    };
-
-    inline Future   *AllocFuture();
-    inline void     FreeFuture(Future *future);
-    inline void     InsertFuture(Future *future);
-    inline int      DecodeNextRec();
-
-    TimeRec         nextrec_;
-    Future          futures_[kMaxNumBasicBlocks];
-    Future          *head_;
-    Future          *free_;
-    Decoder         *decoder_;
-    bool            is_eof_;
-    TraceReaderBase *trace_;
-};
-
-class InsnReader {
-  public:
-    InsnReader();
-    ~InsnReader();
-
-    void        Open(char *filename);
-    void        Close();
-    uint64_t    ReadInsnTime(uint64_t min_time);
-
-  private:
-    Decoder     *decoder_;
-    uint64_t    prev_time_;
-    uint64_t    time_diff_;
-    int         repeat_;
-};
-
-class AddrReader {
-  public:
-    AddrReader();
-    ~AddrReader();
-
-    bool        Open(char *filename, char *suffix);
-    void        Close();
-    bool        ReadAddr(uint64_t *time, uint32_t *addr);
-
-  private:
-    Decoder     *decoder_;
-    uint32_t    prev_addr_;
-    uint64_t    prev_time_;
-    bool        opened_;        // true after file is opened
-};
-
-class ExcReader {
-  public:
-    ExcReader();
-    ~ExcReader();
-
-    void        Open(char *filename);
-    void        Close();
-    bool        ReadExc(uint64_t *time, uint32_t *current_pc,
-                        uint64_t *recnum, uint32_t *target_pc,
-                        uint64_t *bb_num, uint64_t *bb_start_time,
-                        int *num_insns);
-
-  private:
-    Decoder     *decoder_;
-    uint64_t    prev_time_;
-    uint64_t    prev_recnum_;
-};
-
-class PidReader {
-  public:
-    PidReader();
-    ~PidReader();
-
-    void        Open(char *filename);
-    void        Close();
-    bool        ReadPidEvent(struct PidEvent *event);
-    void        Dispose(struct PidEvent *event);
-
-  private:
-    Decoder     *decoder_;
-    uint64_t    prev_time_;
-};
-
-class MethodReader {
-  public:
-    MethodReader();
-    ~MethodReader();
-
-    bool        Open(char *filename);
-    void        Close();
-    bool        ReadMethod(MethodRec *method_record);
-
-  private:
-    Decoder     *decoder_;
-    uint64_t    prev_time_;
-    uint32_t    prev_addr_;
-    int32_t     prev_pid_;
-    bool        opened_;        // true after file is opened
-};
-
-// Reads the next dynamic basic block from the trace.
-// Returns true on end-of-file.
-inline bool TraceReaderBase::ReadBB(BBEvent *event)
-{
-    bb_recnum_ += 1;
-    return bb_reader_->ReadBB(event);
-}
-
-inline uint64_t TraceReaderBase::ReadInsnTime(uint64_t min_time)
-{
-    return insn_reader_->ReadInsnTime(min_time);
-}
-
-inline bool TraceReaderBase::ReadAddr(uint64_t *time, uint32_t *addr, int *flags)
-{
-    if (load_eof_ && store_eof_)
-        return true;
-
-    if (store_eof_ || (!load_eof_ && load_time_ <= store_time_)) {
-        *time = load_time_;
-        *addr = load_addr_;
-        *flags = 0;
-        load_eof_ = load_addr_reader_->ReadAddr(&load_time_, &load_addr_);
-    } else {
-        *time = store_time_;
-        *addr = store_addr_;
-        *flags = 1;
-        store_eof_ = store_addr_reader_->ReadAddr(&store_time_, &store_addr_);
-    }
-    return false;
-}
-
-inline bool TraceReaderBase::ReadExc(uint64_t *time, uint32_t *current_pc,
-                                     uint64_t *recnum, uint32_t *target_pc,
-                                     uint64_t *bb_num, uint64_t *bb_start_time,
-                                     int *num_insns)
-{
-    return exc_reader_->ReadExc(time, current_pc, recnum, target_pc, bb_num,
-                                bb_start_time, num_insns);
-}
-
-inline bool TraceReaderBase::ReadPidEvent(PidEvent *event)
-{
-    return pid_reader_->ReadPidEvent(event);
-}
-
-inline bool TraceReaderBase::ReadMethod(MethodRec *method_record)
-{
-    return method_reader_->ReadMethod(method_record);
-}
-
-// Duplicates a string, allocating space using new[].
-inline char * Strdup(const char *src) {
-    int len = strlen(src);
-    char *copy = new char[len + 1];
-    strcpy(copy, src);
-    return copy;
-}
-
-#endif /* TRACE_READER_BASE_H */
diff --git a/emulator/skins/HVGA-L/arrow_down.png b/emulator/skins/HVGA-L/arrow_down.png
deleted file mode 100644
index 374299c..0000000
--- a/emulator/skins/HVGA-L/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/arrow_left.png b/emulator/skins/HVGA-L/arrow_left.png
deleted file mode 100644
index ba7dd3f..0000000
--- a/emulator/skins/HVGA-L/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/arrow_right.png b/emulator/skins/HVGA-L/arrow_right.png
deleted file mode 100644
index 271311d..0000000
--- a/emulator/skins/HVGA-L/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/arrow_up.png b/emulator/skins/HVGA-L/arrow_up.png
deleted file mode 100644
index 01f4554..0000000
--- a/emulator/skins/HVGA-L/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/back.png b/emulator/skins/HVGA-L/back.png
deleted file mode 100644
index 46cca3d..0000000
--- a/emulator/skins/HVGA-L/back.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/background.png b/emulator/skins/HVGA-L/background.png
deleted file mode 100644
index fde44b5..0000000
--- a/emulator/skins/HVGA-L/background.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/end.png b/emulator/skins/HVGA-L/end.png
deleted file mode 100644
index 760a614..0000000
--- a/emulator/skins/HVGA-L/end.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/home.png b/emulator/skins/HVGA-L/home.png
deleted file mode 100644
index 47beb77..0000000
--- a/emulator/skins/HVGA-L/home.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/key.png b/emulator/skins/HVGA-L/key.png
deleted file mode 100644
index 7a3f563..0000000
--- a/emulator/skins/HVGA-L/key.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/layout b/emulator/skins/HVGA-L/layout
deleted file mode 100644
index 1a98bfd..0000000
--- a/emulator/skins/HVGA-L/layout
+++ /dev/null
@@ -1,332 +0,0 @@
-display {
-	width  480
-	height 320
-	x 145
-	y 78
-}
-
-background {
-	image background.png
-	x 0
-	y 0
-}
-
-button {
-	1 {
-	   image  key.png
-	   x  224
-	   y  468
-	}
-	2 {
-	   image  key.png
-	   x 261
-	   y 468
-	}
-	3 {
-	   image  key.png
-	   x 298
-	   y 468
-	}
-	4 {
-	   image  key.png
-	   x 335
-	   y 468
-	}
-	5 {
-	   image  key.png
-	   x 372
-	   y 468
-	}
-	6 {
-	   image  key.png
-	   x 409
-	   y 468
-	}
-	7 {
-	   image  key.png
-	   x 446
-	   y 468
-	}
-	8 {
-	   image  key.png
-	   x 482
-	   y 468
-	}
-	9 {
-	   image  key.png
-	   x 520
-	   y 468
-	}
-	0 {
-	   image  key.png
-	   x 557
-	   y 468
-	}
-
-	q {
-	   image  key.png
-	   x  224
-	   y  504
-	}
-	w {
-	   image  key.png
-	   x 261
-	   y 504
-	}
-	e {
-	   image  key.png
-	   x 298
-	   y 504
-	}
-	r {
-	   image  key.png
-	   x 335
-	   y 504
-	}
-	t {
-	   image  key.png
-	   x 372
-	   y 504
-	}
-	y {
-	   image  key.png
-	   x 409
-	   y 504
-	}
-	u {
-	   image  key.png
-	   x 446
-	   y 504
-	}
-	i {
-	   image  key.png
-	   x 482
-	   y 504
-	}
-	o {
-	   image  key.png
-	   x 520
-	   y 504
-	}
-	p {
-	   image  key.png
-	   x 557
-	   y 504
-	}
-
-	a {
-	   image  key.png
-	   x  224
-	   y  540
-	}
-	s {
-	   image  key.png
-	   x 261
-	   y 540
-	}
-	d {
-	   image  key.png
-	   x 298
-	   y 540
-	}
-	f {
-	   image  key.png
-	   x 335
-	   y 540
-	}
-	g {
-	   image  key.png
-	   x 372
-	   y 540
-	}
-	h {
-	   image  key.png
-	   x 409
-	   y 540
-	}
-	j {
-	   image  key.png
-	   x 446
-	   y 540
-	}
-	k {
-	   image  key.png
-	   x 482
-	   y 540
-	}
-	l {
-	   image  key.png
-	   x 520
-	   y 540
-	}
-	DEL {
-	   image  key.png
-	   x 557
-	   y 540
-	}
-
-	CAP {
-	   image  key.png
-	   x  224
-	   y  576
-	}
-	z {
-	   image  key.png
-	   x 261
-	   y 576
-	}
-	x {
-	   image  key.png
-	   x 298
-	   y 576
-	}
-	c {
-	   image  key.png
-	   x 335
-	   y 576
-	}
-	v {
-	   image  key.png
-	   x 372
-	   y 576
-	}
-	b {
-	   image  key.png
-	   x 409
-	   y 576
-	}
-	n {
-	   image  key.png
-	   x 446
-	   y 576
-	}
-	m {
-	   image  key.png
-	   x 482
-	   y 576
-	}
-	PERIOD {
-	   image  key.png
-	   x 520
-	   y 576
-	}
-	ENTER {
-	   image  key.png
-	   x 557
-	   y 576
-	}
-
-	ALT {
-	   image  key.png
-	   x  224
-	   y  612
-	}
-	SYM {
-	   image  key.png
-	   x 261
-	   y 612
-	}
-	AT {
-	   image  key.png
-	   x 298
-	   y 612
-	}
-	SPACE {
-	   image  spacebar.png
-	   x 335
-	   y 612
-	}
-	SLASH {
-	   image  key.png
-	   x 482
-	   y 612
-	}
-	COMMA {
-	   image  key.png
-	   x 520
-	   y 612
-	}
-	ALT2 {
-	   image  key.png
-	   x 557
-	   y 612
-	}
-
-	soft-left {
-		image menu.png
-		x 630
-		y 196
-	}
-	home {
-		image home.png
-		x 665
-		y 334
-	}
-	back {
-		image back.png
-		x 664
-		y 96
-	}
-	dpad-up {
-		image arrow_up.png
-		x 671
-		y 160
-	}
-	dpad-down {
-		image arrow_down.png
-		x 671
-		y 270
-	}
-	dpad-left {
-		image arrow_left.png
-		x 669
-		y 190
-	}
-	dpad-right {
-		image arrow_right.png
-		x 730
-		y 190
-	}
-	dpad-center {
-		image select.png
-		x 698
-		y 190
-	}
-	phone-dial {
-		image send.png
-		x 720
-		y 334
-	}
-	phone-hangup {
-		image end.png
-		x 720
-		y 96
-	}
-
-	power {
-		image power.png
-		x 128
-		y 407
-	}
-
-	volume-up {
-		image volume_up.png
-		x 336
-		y 0
-	}
-
-	volume-down {
-		image volume_down.png
-		x 386
-		y 0
-	}
-}
-
-network {
-    speed  full
-    delay  none
-}
-
-keyboard {
-    charmap qwerty2
-}
diff --git a/emulator/skins/HVGA-L/menu.png b/emulator/skins/HVGA-L/menu.png
deleted file mode 100644
index 7510f33..0000000
--- a/emulator/skins/HVGA-L/menu.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/power.png b/emulator/skins/HVGA-L/power.png
deleted file mode 100644
index e947d4d..0000000
--- a/emulator/skins/HVGA-L/power.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/select.png b/emulator/skins/HVGA-L/select.png
deleted file mode 100644
index 82fb762..0000000
--- a/emulator/skins/HVGA-L/select.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/send.png b/emulator/skins/HVGA-L/send.png
deleted file mode 100644
index 2669515..0000000
--- a/emulator/skins/HVGA-L/send.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/spacebar.png b/emulator/skins/HVGA-L/spacebar.png
deleted file mode 100644
index 19fe604..0000000
--- a/emulator/skins/HVGA-L/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/volume_down.png b/emulator/skins/HVGA-L/volume_down.png
deleted file mode 100644
index f1c0fbf..0000000
--- a/emulator/skins/HVGA-L/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-L/volume_up.png b/emulator/skins/HVGA-L/volume_up.png
deleted file mode 100644
index 67d2d2a..0000000
--- a/emulator/skins/HVGA-L/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/arrow_down.png b/emulator/skins/HVGA-P/arrow_down.png
deleted file mode 100644
index 19b3764..0000000
--- a/emulator/skins/HVGA-P/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/arrow_left.png b/emulator/skins/HVGA-P/arrow_left.png
deleted file mode 100644
index 113e584..0000000
--- a/emulator/skins/HVGA-P/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/arrow_right.png b/emulator/skins/HVGA-P/arrow_right.png
deleted file mode 100644
index ffe3356..0000000
--- a/emulator/skins/HVGA-P/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/arrow_up.png b/emulator/skins/HVGA-P/arrow_up.png
deleted file mode 100644
index 81c54df..0000000
--- a/emulator/skins/HVGA-P/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/back.png b/emulator/skins/HVGA-P/back.png
deleted file mode 100644
index 41034d9..0000000
--- a/emulator/skins/HVGA-P/back.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/background.png b/emulator/skins/HVGA-P/background.png
deleted file mode 100644
index bab8c6d..0000000
--- a/emulator/skins/HVGA-P/background.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/end.png b/emulator/skins/HVGA-P/end.png
deleted file mode 100644
index 6830a60..0000000
--- a/emulator/skins/HVGA-P/end.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/home.png b/emulator/skins/HVGA-P/home.png
deleted file mode 100644
index 7d02136..0000000
--- a/emulator/skins/HVGA-P/home.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/key.png b/emulator/skins/HVGA-P/key.png
deleted file mode 100644
index 7a3f563..0000000
--- a/emulator/skins/HVGA-P/key.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/layout b/emulator/skins/HVGA-P/layout
deleted file mode 100644
index 1189ca5..0000000
--- a/emulator/skins/HVGA-P/layout
+++ /dev/null
@@ -1,332 +0,0 @@
-display {
-	width  320
-	height 480
-	x 75
-	y 84
-}
-
-background {
-	image background.png
-	x 0
-	y 0
-}
-
-button {
-	1 {
-	   image  key.png
-	   x  468
-	   y  276
-	}
-	2 {
-	   image  key.png
-	   x 505
-	   y 276
-	}
-	3 {
-	   image  key.png
-	   x 543
-	   y 276
-	}
-	4 {
-	   image  key.png
-	   x 579
-	   y 276
-	}
-	5 {
-	   image  key.png
-	   x 616
-	   y 276
-	}
-	6 {
-	   image  key.png
-	   x 653
-	   y 276
-	}
-	7 {
-	   image  key.png
-	   x 690
-	   y 276
-	}
-	8 {
-	   image  key.png
-	   x 727
-	   y 276
-	}
-	9 {
-	   image  key.png
-	   x 763
-	   y 276
-	}
-	0 {
-	   image  key.png
-	   x 801
-	   y 276
-	}
-
-	q {
-	   image  key.png
-	   x  468
-	   y  312
-	}
-	w {
-	   image  key.png
-	   x 505
-	   y 312
-	}
-	e {
-	   image  key.png
-	   x 543
-	   y 312
-	}
-	r {
-	   image  key.png
-	   x 579
-	   y 312
-	}
-	t {
-	   image  key.png
-	   x 616
-	   y 312
-	}
-	y {
-	   image  key.png
-	   x 653
-	   y 312
-	}
-	u {
-	   image  key.png
-	   x 690
-	   y 312
-	}
-	i {
-	   image  key.png
-	   x 727
-	   y 312
-	}
-	o {
-	   image  key.png
-	   x 763
-	   y 312
-	}
-	p {
-	   image  key.png
-	   x 801
-	   y 312
-	}
-
-	a {
-	   image  key.png
-	   x  468
-	   y  348
-	}
-	s {
-	   image  key.png
-	   x 505
-	   y 348
-	}
-	d {
-	   image  key.png
-	   x 543
-	   y 348
-	}
-	f {
-	   image  key.png
-	   x 579
-	   y 348
-	}
-	g {
-	   image  key.png
-	   x 616
-	   y 348
-	}
-	h {
-	   image  key.png
-	   x 653
-	   y 348
-	}
-	j {
-	   image  key.png
-	   x 690
-	   y 348
-	}
-	k {
-	   image  key.png
-	   x 727
-	   y 348
-	}
-	l {
-	   image  key.png
-	   x 763
-	   y 348
-	}
-	DEL {
-	   image  key.png
-	   x 801
-	   y 348
-	}
-
-	CAP {
-	   image  key.png
-	   x  468
-	   y  384
-	}
-	z {
-	   image  key.png
-	   x 505
-	   y 384
-	}
-	x {
-	   image  key.png
-	   x 543
-	   y 384
-	}
-	c {
-	   image  key.png
-	   x 579
-	   y 384
-	}
-	v {
-	   image  key.png
-	   x 616
-	   y 384
-	}
-	b {
-	   image  key.png
-	   x 653
-	   y 384
-	}
-	n {
-	   image  key.png
-	   x 690
-	   y 384
-	}
-	m {
-	   image  key.png
-	   x 727
-	   y 384
-	}
-	PERIOD {
-	   image  key.png
-	   x 763
-	   y 384
-	}
-	ENTER {
-	   image  key.png
-	   x 801
-	   y 384
-	}
-
-	ALT {
-	   image  key.png
-	   x  468
-	   y  420
-	}
-	SYM {
-	   image  key.png
-	   x 505
-	   y 420
-	}
-	AT {
-	   image  key.png
-	   x 543
-	   y 420
-	}
-	SPACE {
-	   image  spacebar.png
-	   x 579
-	   y 420
-	}
-	SLASH {
-	   image  key.png
-	   x 727
-	   y 420
-	}
-	COMMA {
-	   image  key.png
-	   x 763
-	   y 420
-	}
-	ALT2 {
-	   image  key.png
-	   x 801
-	   y 420
-	}
-
-	soft-left {
-		image menu.png
-		x 192
-		y 569
-	}
-	home {
-		image home.png
-		x 93
-		y 602
-	}
-	back {
-		image back.png
-		x 331
-		y 602
-	}
-	dpad-up {
-		image arrow_up.png
-		x 185
-		y 608
-	}
-	dpad-down {
-		image arrow_down.png
-		x 185
-		y 669
-	}
-	dpad-left {
-		image arrow_left.png
-		x 155
-		y 610
-	}
-	dpad-right {
-		image arrow_right.png
-		x 266
-		y 610
-	}
-	dpad-center {
-		image select.png
-		x 186
-		y 637
-	}
-	phone-dial {
-		image send.png
-		x 93
-		y 658
-	}
-	phone-hangup {
-		image end.png
-		x 331
-		y 658
-	}
-
-	power {
-		image power.png
-		x 7
-		y 66
-	}
-
-	volume-up {
-		image volume_up.png
-		x 407
-		y 274
-	}
-
-	volume-down {
-		image volume_down.png
-		x 407
-		y 324
-	}
-}
-
-keyboard {
-    charmap qwerty2
-}
-
-network {
-    speed  full
-    delay  none
-}
diff --git a/emulator/skins/HVGA-P/menu.png b/emulator/skins/HVGA-P/menu.png
deleted file mode 100644
index e81d8ab..0000000
--- a/emulator/skins/HVGA-P/menu.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/power.png b/emulator/skins/HVGA-P/power.png
deleted file mode 100644
index 5894288..0000000
--- a/emulator/skins/HVGA-P/power.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/select.png b/emulator/skins/HVGA-P/select.png
deleted file mode 100644
index 803d493..0000000
--- a/emulator/skins/HVGA-P/select.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/send.png b/emulator/skins/HVGA-P/send.png
deleted file mode 100644
index f547c88..0000000
--- a/emulator/skins/HVGA-P/send.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/spacebar.png b/emulator/skins/HVGA-P/spacebar.png
deleted file mode 100644
index 19fe604..0000000
--- a/emulator/skins/HVGA-P/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/volume_down.png b/emulator/skins/HVGA-P/volume_down.png
deleted file mode 100644
index f8a88de..0000000
--- a/emulator/skins/HVGA-P/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA-P/volume_up.png b/emulator/skins/HVGA-P/volume_up.png
deleted file mode 100644
index 940457f..0000000
--- a/emulator/skins/HVGA-P/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/arrow_down.png b/emulator/skins/HVGA/arrow_down.png
deleted file mode 100644
index 19b3764..0000000
--- a/emulator/skins/HVGA/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/arrow_left.png b/emulator/skins/HVGA/arrow_left.png
deleted file mode 100644
index 113e584..0000000
--- a/emulator/skins/HVGA/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/arrow_right.png b/emulator/skins/HVGA/arrow_right.png
deleted file mode 100644
index ffe3356..0000000
--- a/emulator/skins/HVGA/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/arrow_up.png b/emulator/skins/HVGA/arrow_up.png
deleted file mode 100644
index 81c54df..0000000
--- a/emulator/skins/HVGA/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/back.png b/emulator/skins/HVGA/back.png
deleted file mode 100644
index 41034d9..0000000
--- a/emulator/skins/HVGA/back.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/device.png b/emulator/skins/HVGA/device.png
deleted file mode 100644
index 465eb02..0000000
--- a/emulator/skins/HVGA/device.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/end.png b/emulator/skins/HVGA/end.png
deleted file mode 100644
index 6830a60..0000000
--- a/emulator/skins/HVGA/end.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/home.png b/emulator/skins/HVGA/home.png
deleted file mode 100644
index 7d02136..0000000
--- a/emulator/skins/HVGA/home.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/key.png b/emulator/skins/HVGA/key.png
deleted file mode 100644
index 7a3f563..0000000
--- a/emulator/skins/HVGA/key.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/keyboard.png b/emulator/skins/HVGA/keyboard.png
deleted file mode 100644
index bb076d3..0000000
--- a/emulator/skins/HVGA/keyboard.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/layout b/emulator/skins/HVGA/layout
deleted file mode 100644
index 4c3d764..0000000
--- a/emulator/skins/HVGA/layout
+++ /dev/null
@@ -1,380 +0,0 @@
-parts {
-    device {
-        background {
-            image   device.png
-        }
-        display {
-            width   320
-            height  480
-            x       31
-            y       72
-        }
-
-        buttons {
-            soft-left {
-                    image menu.png
-                    x 147
-                    y 555
-            }
-            home {
-                    image home.png
-                    x 48
-                    y 590
-            }
-            back {
-                    image back.png
-                    x 286
-                    y 590
-            }
-            dpad-up {
-                    image arrow_up.png
-                    x 140
-                    y 595
-            }
-            dpad-down {
-                    image arrow_down.png
-                    x 140
-                    y 656
-            }
-            dpad-left {
-                    image arrow_left.png
-                    x 111
-                    y 598
-            }
-            dpad-right {
-                    image arrow_right.png
-                    x 222
-                    y 598
-            }
-            dpad-center {
-                    image select.png
-                    x 142
-                    y 626
-            }
-            phone-dial {
-                    image send.png
-                    x 48
-                    y 646
-            }
-            phone-hangup {
-                    image end.png
-                    x 286
-                    y 646
-            }
-
-            power {
-                    image power.png
-                    x -38
-                    y 52
-            }
-
-            volume-up {
-                    image volume_up.png
-                    x 362
-                    y 260
-            }
-
-            volume-down {
-                    image volume_down.png
-                    x 362
-                    y 310
-            }
-        }
-    }
-
-    keyboard {
-        background {
-            image   keyboard.png
-        }
-        buttons {
-            1 {
-                image  key.png
-                x  0
-                y  0
-            }
-            2 {
-                image  key.png
-                x 37
-                y 0
-            }
-            3 {
-                image  key.png
-                x 74
-                y 0
-            }
-            4 {
-                image  key.png
-                x 111
-                y 0
-            }
-            5 {
-                image  key.png
-                x 148
-                y 0
-            }
-            6 {
-                image  key.png
-                x 185
-                y 0
-            }
-            7 {
-                image  key.png
-                x 222
-                y 0
-            }
-            8 {
-                image  key.png
-                x 259
-                y 0
-            }
-            9 {
-                image  key.png
-                x 296
-                y 0
-            }
-            0 {
-                image  key.png
-                x 333
-                y 0
-            }
-
-            q {
-                image  key.png
-                x  0
-                y  36
-            }
-            w {
-                image  key.png
-                x 37
-                y 36
-            }
-            e {
-                image  key.png
-                x 74
-                y 36
-            }
-            r {
-                image  key.png
-                x 111
-                y 36
-            }
-            t {
-                image  key.png
-                x 148
-                y 36
-            }
-            y {
-                image  key.png
-                x 185
-                y 36
-            }
-            u {
-                image  key.png
-                x 222
-                y 36
-            }
-            i {
-                image  key.png
-                x 259
-                y 36
-            }
-            o {
-                image  key.png
-                x 296
-                y 36
-            }
-            p {
-                image  key.png
-                x 333
-                y 36
-            }
-
-            a {
-                image  key.png
-                x  0
-                y  72
-            }
-            s {
-                image  key.png
-                x 37
-                y 72
-            }
-            d {
-                image  key.png
-                x 74
-                y 72
-            }
-            f {
-                image  key.png
-                x 111
-                y 72
-            }
-            g {
-                image  key.png
-                x 148
-                y 72
-            }
-            h {
-                image  key.png
-                x 185
-                y 72
-            }
-            j {
-                image  key.png
-                x 222
-                y 72
-            }
-            k {
-                image  key.png
-                x 259
-                y 72
-            }
-            l {
-                image  key.png
-                x 296
-                y 72
-            }
-            DEL {
-                image  key.png
-                x 333
-                y 72
-            }
-
-            CAP {
-                image  key.png
-                x  0
-                y  108
-            }
-            z {
-                image  key.png
-                x 37
-                y 108
-            }
-            x {
-                image  key.png
-                x 74
-                y 108
-            }
-            c {
-                image  key.png
-                x 111
-                y 108
-            }
-            v {
-                image  key.png
-                x 148
-                y 108
-            }
-            b {
-                image  key.png
-                x 185
-                y 108
-            }
-            n {
-                image  key.png
-                x 222
-                y 108
-            }
-            m {
-                image  key.png
-                x 259
-                y 108
-            }
-            PERIOD {
-                image  key.png
-                x 296
-                y 108
-            }
-            ENTER {
-                image  key.png
-                x 333
-                y 108
-            }
-
-            ALT {
-                image  key.png
-                x  0
-                y  144
-            }
-            SYM {
-                image  key.png
-                x 37
-                y 144
-            }
-            AT {
-                image  key.png
-                x 74
-                y 144
-            }
-            SPACE {
-                image  spacebar.png
-                x 111
-                y 144
-            }
-            SLASH {
-                image  key.png
-                x 259
-                y 144
-            }
-            COMMA {
-                image  key.png
-                x 296
-                y 144
-            }
-            ALT2 {
-                image  key.png
-                x 333
-                y 144
-            }
-
-        }
-    }
-}
-
-layouts {
-    portrait {
-        width     900
-        height    730
-        color     0xe0e0e0
-        event     EV_SW:0:1
-
-        part1 {
-            name    device
-            x       40
-            y       -18
-        }
-        part2 {
-            name    keyboard
-            x       480
-            y       200
-        }
-    }
-
-    landscape {
-        width     900
-        height    670
-        color     0xe0e0e0
-        event     EV_SW:0:0
-
-        part1 {
-            name      device
-            x         50
-            y         440
-            rotation  3
-        }
-        part2 {
-            name     keyboard
-            x        250
-            y        470
-        }
-    }
-}
-
-keyboard {
-    charmap qwerty2
-}
-
-network {
-    speed  full
-    delay  none
-}
diff --git a/emulator/skins/HVGA/menu.png b/emulator/skins/HVGA/menu.png
deleted file mode 100644
index e81d8ab..0000000
--- a/emulator/skins/HVGA/menu.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/power.png b/emulator/skins/HVGA/power.png
deleted file mode 100644
index 5894288..0000000
--- a/emulator/skins/HVGA/power.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/select.png b/emulator/skins/HVGA/select.png
deleted file mode 100644
index 803d493..0000000
--- a/emulator/skins/HVGA/select.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/send.png b/emulator/skins/HVGA/send.png
deleted file mode 100644
index f547c88..0000000
--- a/emulator/skins/HVGA/send.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/spacebar.png b/emulator/skins/HVGA/spacebar.png
deleted file mode 100644
index 19fe604..0000000
--- a/emulator/skins/HVGA/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/volume_down.png b/emulator/skins/HVGA/volume_down.png
deleted file mode 100644
index f8a88de..0000000
--- a/emulator/skins/HVGA/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/HVGA/volume_up.png b/emulator/skins/HVGA/volume_up.png
deleted file mode 100644
index 940457f..0000000
--- a/emulator/skins/HVGA/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/arrow_down.png b/emulator/skins/QVGA-L/arrow_down.png
deleted file mode 100644
index 7398bae..0000000
--- a/emulator/skins/QVGA-L/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/arrow_left.png b/emulator/skins/QVGA-L/arrow_left.png
deleted file mode 100644
index f7e3c12..0000000
--- a/emulator/skins/QVGA-L/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/arrow_right.png b/emulator/skins/QVGA-L/arrow_right.png
deleted file mode 100644
index 33fa169..0000000
--- a/emulator/skins/QVGA-L/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/arrow_up.png b/emulator/skins/QVGA-L/arrow_up.png
deleted file mode 100644
index f21105a..0000000
--- a/emulator/skins/QVGA-L/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/back.png b/emulator/skins/QVGA-L/back.png
deleted file mode 100644
index 883b4ca..0000000
--- a/emulator/skins/QVGA-L/back.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/background.png b/emulator/skins/QVGA-L/background.png
deleted file mode 100644
index 81832ec..0000000
--- a/emulator/skins/QVGA-L/background.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/end.png b/emulator/skins/QVGA-L/end.png
deleted file mode 100644
index 7a6ae1c..0000000
--- a/emulator/skins/QVGA-L/end.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/favorites.png b/emulator/skins/QVGA-L/favorites.png
deleted file mode 100644
index ad85c5c..0000000
--- a/emulator/skins/QVGA-L/favorites.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/home.png b/emulator/skins/QVGA-L/home.png
deleted file mode 100644
index 36f314e..0000000
--- a/emulator/skins/QVGA-L/home.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/key.png b/emulator/skins/QVGA-L/key.png
deleted file mode 100644
index 3c17cec..0000000
--- a/emulator/skins/QVGA-L/key.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/layout b/emulator/skins/QVGA-L/layout
deleted file mode 100644
index fd86934..0000000
--- a/emulator/skins/QVGA-L/layout
+++ /dev/null
@@ -1,275 +0,0 @@
-display {
-	width  320
-	height 240
-	x 78
-	y 96
-}
-
-background {
-	image background.png
-	x 0
-	y 0
-}
-
-button {
-	soft-left {
-		image menu.png
-		x 136
-		y 378
-	}
-	home {
-		image home.png
-		x 312
-		y 372
-	}
-	back {
-		image back.png
-		x 137
-		y 420
-	}
-	dpad-up {
-		image arrow_up.png
-		x 190
-		y 364
-	}
-	dpad-down {
-		image arrow_down.png
-		x 190
-		y 421
-	}
-	dpad-left {
-		image arrow_left.png
-		x 181
-		y 372
-	}
-	dpad-right {
-		image arrow_right.png
-		x 257
-		y 372
-	}
-	dpad-center {
-		image select.png
-		x 216
-		y 394
-	}
-	phone-dial {
-		image send.png
-		x 76
-		y 394
-	}
-	phone-hangup {
-		image end.png
-		x 358
-		y 394
-	}
-	
-	q {
-	       image  key.png
-	       x  55
-	       y  480
-	}
-	w {
-	       image  key.png
-	       x 91
-	       y 480
-	}
-	e {
-	       image  key.png
-	       x 128
-	       y 480
-	}
-	r {
-	       image  key.png
-	       x 163
-	       y 480
-	}
-	t {
-	       image  key.png
-	       x 200
-	       y 480
-	}
-	y {
-	       image  key.png
-	       x 237
-	       y 480
-	}
-	u {
-	       image  key.png
-	       x 273
-	       y 480
-	}
-	i {
-	       image  key.png
-	       x 310
-	       y 480
-	}
-	o {
-	       image  key.png
-	       x 346
-	       y 480
-	}
-	p {
-	       image  key.png
-	       x 382
-	       y 480
-	}
-
-	a {
-	       image  key.png
-	       x  55
-	       y  530
-	}
-	s {
-	       image  key.png
-	       x 91
-	       y 530
-	}
-	d {
-	       image  key.png
-	       x 128
-	       y 530
-	}
-	f {
-	       image  key.png
-	       x 163
-	       y 530
-	}
-	g {
-	       image  key.png
-	       x 200
-	       y 530
-	}
-	h {
-	       image  key.png
-	       x 237
-	       y 530
-	}
-	j {
-	       image  key.png
-	       x 273
-	       y 530
-	}
-	k {
-	       image  key.png
-	       x 310
-	       y 530
-	}
-	l {
-	       image  key.png
-	       x 346
-	       y 530
-	}
-	DEL {
-	       image  key.png
-	       x 382
-	       y 530
-	}
-	
-	CAP {
-	       image  key.png
-	       x  55
-	       y  580
-	}
-	z {
-	       image  key.png
-	       x 91
-	       y 580
-	}
-	x {
-	       image  key.png
-	       x 128
-	       y 580
-	}
-	c {
-	       image  key.png
-	       x 163
-	       y 580
-	}
-	v {
-	       image  key.png
-	       x 200
-	       y 580
-	}
-	b {
-	       image  key.png
-	       x 237
-	       y 580
-	}
-	n {
-	       image  key.png
-	       x 273
-	       y 580
-	}
-	m {
-	       image  key.png
-	       x 310
-	       y 580
-	}
-	PERIOD {
-	       image  key.png
-	       x 346
-	       y 580
-	}
-	ENTER {
-	       image  key.png
-	       x 382
-	       y 580
-	}
-
-	ALT {
-	       image  key.png
-	       x  55
-	       y  630
-	}
-	SYM {
-	       image  key.png
-	       x 91
-	       y 630
-	}
-	AT {
-	       image  key.png
-	       x 128
-	       y 630
-	}
-	SPACE {
-	       image  spacebar.png
-	       x 165
-	       y 630
-	}
-	SLASH {
-	       image  key.png
-	       x 310
-	       y 630
-	}
-	COMMA {
-	       image  key.png
-	       x 346
-	       y 630
-	}
-	CAP2 {
-	       image  key.png
-	       x 382
-	       y 630
-	}
-	
-	power {
-		image power.png
-		x     4
-		y     38
-	}
-	volume-up {
-		image volume_up.png
-		x     420
-		y     165
-	}
-	volume-down {
-		image volume_down.png
-		x     420
-		y     218
-	}
-}
-
-network {
-    speed  full
-    delay  none
-}
diff --git a/emulator/skins/QVGA-L/menu.png b/emulator/skins/QVGA-L/menu.png
deleted file mode 100644
index 224b077..0000000
--- a/emulator/skins/QVGA-L/menu.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/power.png b/emulator/skins/QVGA-L/power.png
deleted file mode 100644
index 7886a16..0000000
--- a/emulator/skins/QVGA-L/power.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/select.png b/emulator/skins/QVGA-L/select.png
deleted file mode 100644
index 8691f53..0000000
--- a/emulator/skins/QVGA-L/select.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/send.png b/emulator/skins/QVGA-L/send.png
deleted file mode 100644
index 8519ebd..0000000
--- a/emulator/skins/QVGA-L/send.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/spacebar.png b/emulator/skins/QVGA-L/spacebar.png
deleted file mode 100644
index c45a580..0000000
--- a/emulator/skins/QVGA-L/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/volume_down.png b/emulator/skins/QVGA-L/volume_down.png
deleted file mode 100644
index 09175b1..0000000
--- a/emulator/skins/QVGA-L/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-L/volume_up.png b/emulator/skins/QVGA-L/volume_up.png
deleted file mode 100644
index ab52c63..0000000
--- a/emulator/skins/QVGA-L/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/arrow_down.png b/emulator/skins/QVGA-P/arrow_down.png
deleted file mode 100644
index 7398bae..0000000
--- a/emulator/skins/QVGA-P/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/arrow_left.png b/emulator/skins/QVGA-P/arrow_left.png
deleted file mode 100644
index f7e3c12..0000000
--- a/emulator/skins/QVGA-P/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/arrow_right.png b/emulator/skins/QVGA-P/arrow_right.png
deleted file mode 100644
index 33fa169..0000000
--- a/emulator/skins/QVGA-P/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/arrow_up.png b/emulator/skins/QVGA-P/arrow_up.png
deleted file mode 100644
index f21105a..0000000
--- a/emulator/skins/QVGA-P/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/background.png b/emulator/skins/QVGA-P/background.png
deleted file mode 100644
index 39348c4..0000000
--- a/emulator/skins/QVGA-P/background.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/button.png b/emulator/skins/QVGA-P/button.png
deleted file mode 100644
index 8519ebd..0000000
--- a/emulator/skins/QVGA-P/button.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/key.png b/emulator/skins/QVGA-P/key.png
deleted file mode 100644
index 7a3f563..0000000
--- a/emulator/skins/QVGA-P/key.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/layout b/emulator/skins/QVGA-P/layout
deleted file mode 100644
index a9abb1b..0000000
--- a/emulator/skins/QVGA-P/layout
+++ /dev/null
@@ -1,329 +0,0 @@
-display {
-	width  240
-	height 320
-	x 50
-	y 83
-}
-
-background {
-	image background.png
-	x 0
-	y 0
-}
-
-button {
-	soft-left {
-		image button.png
-		x 148
-		y 418
-	}
-	home {
-		image button.png
-		x 94
-		y 418
-	}
-	back {
-		image button.png
-		x 202
-		y 418
-	}
-	dpad-up {
-		image arrow_up.png
-		x 122
-		y 475
-	}
-	dpad-down {
-		image arrow_down.png
-		x 122
-		y 534
-	}
-	dpad-left {
-		image arrow_left.png
-		x 113
-		y 483
-	}
-	dpad-right {
-		image arrow_right.png
-		x 189
-		y 483
-	}
-	dpad-center {
-		image select.png
-		x 148
-		y 506
-	}
-	phone-dial {
-		image button.png
-		x 40
-		y 418
-	}
-	phone-hangup {
-		image button.png
-		x 256
-		y 418
-	}
-	power {
-		image power.png
-		x     5
-		y     18
-	}
-	volume-up {
-		image volume_up.png
-		x     306
-		y     192
-	}
-	volume-down {
-		image volume_down.png
-		x     306
-		y     245
-	}
-	1 {
-	   image  key.png
-	   x  367
-	   y  242
-	}
-	2 {
-	   image  key.png
-	   x 404
-	   y 242
-	}
-	3 {
-	   image  key.png
-	   x 441
-	   y 242
-	}
-	4 {
-	   image  key.png
-	   x 478
-	   y 242
-	}
-	5 {
-	   image  key.png
-	   x 515
-	   y 242
-	}
-	6 {
-	   image  key.png
-	   x 552
-	   y 242
-	}
-	7 {
-	   image  key.png
-	   x 589
-	   y 242
-	}
-	8 {
-	   image  key.png
-	   x 626
-	   y 242
-	}
-	9 {
-	   image  key.png
-	   x 663
-	   y 242
-	}
-	0 {
-	   image  key.png
-	   x 700
-	   y 242
-	}
-
-	q {
-	   image  key.png
-	   x  367
-	   y  278
-	}
-	w {
-	   image  key.png
-	   x 404
-	   y 278
-	}
-	e {
-	   image  key.png
-	   x 441
-	   y 278
-	}
-	r {
-	   image  key.png
-	   x 478
-	   y 278
-	}
-	t {
-	   image  key.png
-	   x 515
-	   y 278
-	}
-	y {
-	   image  key.png
-	   x 552
-	   y 278
-	}
-	u {
-	   image  key.png
-	   x 589
-	   y 278
-	}
-	i {
-	   image  key.png
-	   x 626
-	   y 278
-	}
-	o {
-	   image  key.png
-	   x 663
-	   y 278
-	}
-	p {
-	   image  key.png
-	   x 700
-	   y 278
-	}
-
-	a {
-	   image  key.png
-	   x  367
-	   y  314
-	}
-	s {
-	   image  key.png
-	   x 404
-	   y 314
-	}
-	d {
-	   image  key.png
-	   x 441
-	   y 314
-	}
-	f {
-	   image  key.png
-	   x 478
-	   y 314
-	}
-	g {
-	   image  key.png
-	   x 515
-	   y 314
-	}
-	h {
-	   image  key.png
-	   x 552
-	   y 314
-	}
-	j {
-	   image  key.png
-	   x 589
-	   y 314
-	}
-	k {
-	   image  key.png
-	   x 626
-	   y 314
-	}
-	l {
-	   image  key.png
-	   x 663
-	   y 314
-	}
-	DEL {
-	   image  key.png
-	   x 700
-	   y 314
-	}
-
-	CAP {
-	   image  key.png
-	   x  367
-	   y  350
-	}
-	z {
-	   image  key.png
-	   x 404
-	   y 350
-	}
-	x {
-	   image  key.png
-	   x 441
-	   y 350
-	}
-	c {
-	   image  key.png
-	   x 478
-	   y 350
-	}
-	v {
-	   image  key.png
-	   x 515
-	   y 350
-	}
-	b {
-	   image  key.png
-	   x 552
-	   y 350
-	}
-	n {
-	   image  key.png
-	   x 589
-	   y 350
-	}
-	m {
-	   image  key.png
-	   x 626
-	   y 350
-	}
-	PERIOD {
-	   image  key.png
-	   x 663
-	   y 350
-	}
-	ENTER {
-	   image  key.png
-	   x 700
-	   y 350
-	}
-
-	ALT {
-	   image  key.png
-	   x  367
-	   y  386
-	}
-	SYM {
-	   image  key.png
-	   x 404
-	   y 386
-	}
-	AT {
-	   image  key.png
-	   x 441
-	   y 386
-	}
-	SPACE {
-	   image  spacebar.png
-	   x 478
-	   y 386
-	}
-	SLASH {
-	   image  key.png
-	   x 626
-	   y 386
-	}
-	COMMA {
-	   image  key.png
-	   x 663
-	   y 386
-	}
-	ALT2 {
-	   image  key.png
-	   x 408
-	   y 855
-	}
-
-}
-
-network {
-    speed  full
-    delay  none
-}
-
-keyboard {
-    charmap qwerty2
-}
diff --git a/emulator/skins/QVGA-P/power.png b/emulator/skins/QVGA-P/power.png
deleted file mode 100644
index 0c04ced..0000000
--- a/emulator/skins/QVGA-P/power.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/select.png b/emulator/skins/QVGA-P/select.png
deleted file mode 100644
index 8691f53..0000000
--- a/emulator/skins/QVGA-P/select.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/spacebar.png b/emulator/skins/QVGA-P/spacebar.png
deleted file mode 100644
index 19fe604..0000000
--- a/emulator/skins/QVGA-P/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/volume_down.png b/emulator/skins/QVGA-P/volume_down.png
deleted file mode 100644
index 09175b1..0000000
--- a/emulator/skins/QVGA-P/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/emulator/skins/QVGA-P/volume_up.png b/emulator/skins/QVGA-P/volume_up.png
deleted file mode 100644
index ab52c63..0000000
--- a/emulator/skins/QVGA-P/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/host/Android.mk b/host/Android.mk
deleted file mode 100644
index 5e318e1..0000000
--- a/host/Android.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(my-dir)
-
-dir := $(wildcard $(LOCAL_PATH)/$(HOST_PREBUILT_TAG))
-ifdef dir
-  include $(call first-makefiles-under,$(dir))
-endif
diff --git a/host/windows/prebuilt/adb.exe b/host/windows/prebuilt/adb.exe
deleted file mode 100755
index 4cba503..0000000
--- a/host/windows/prebuilt/adb.exe
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/javawrap.exe b/host/windows/prebuilt/javawrap.exe
deleted file mode 100755
index d42ac2b..0000000
--- a/host/windows/prebuilt/javawrap.exe
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/AdbWinApi.a b/host/windows/prebuilt/usb/AdbWinApi.a
deleted file mode 100644
index 93ccd66..0000000
--- a/host/windows/prebuilt/usb/AdbWinApi.a
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/AdbWinApi.def b/host/windows/prebuilt/usb/AdbWinApi.def
deleted file mode 100644
index 1894148..0000000
--- a/host/windows/prebuilt/usb/AdbWinApi.def
+++ /dev/null
@@ -1,15 +0,0 @@
-LIBRARY AdbWinApi.dll
-EXPORTS
-AdbEnumInterfaces
-AdbNextInterface
-AdbCreateInterfaceByName
-AdbOpenDefaultBulkReadEndpoint
-AdbOpenDefaultBulkWriteEndpoint
-AdbCloseHandle
-AdbGetInterfaceName
-AdbWriteEndpointSync
-AdbReadEndpointSync
-AdbGetSerialNumber
-AdbGetUsbInterfaceDescriptor
-AdbGetUsbDeviceDescriptor
-AdbGetEndpointInformation
diff --git a/host/windows/prebuilt/usb/AdbWinApi.dll b/host/windows/prebuilt/usb/AdbWinApi.dll
deleted file mode 100755
index 9670b4f..0000000
--- a/host/windows/prebuilt/usb/AdbWinApi.dll
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/Android.mk b/host/windows/prebuilt/usb/Android.mk
deleted file mode 100644
index 1806101..0000000
--- a/host/windows/prebuilt/usb/Android.mk
+++ /dev/null
@@ -1,23 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_LIBS := \
-	AdbWinApi.a
-
-LOCAL_PREBUILT_EXECUTABLES := \
-	AdbWinApi.dll
-	
-.PHONY : kill-adb
-	
-$(LOCAL_PATH)/AdbWinApi.dll : kill-adb
-
-kill-adb:
-	@echo "Killing adb server so we can replace AdbWinApi.dll"
-	@adb kill-server || echo "adb appears to be missing"
-
-# generate AdbWinApi stub library
-#$(LOCAL_PATH)/AdbWinApi.a: $(LOCAL_PATH)/AdbWinApi.def
-#	dlltool --def $(LOCAL_PATH)/AdbWinApi.def --dllname AdbWinApi.dll --output-lib $(LOCAL_PATH)/AdbWinApi.a
-
-include $(BUILD_HOST_PREBUILT)
diff --git a/host/windows/prebuilt/usb/driver/WdfCoInstaller01005.dll b/host/windows/prebuilt/usb/driver/WdfCoInstaller01005.dll
deleted file mode 100644
index 12d2768..0000000
--- a/host/windows/prebuilt/usb/driver/WdfCoInstaller01005.dll
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/driver/android_usb.inf b/host/windows/prebuilt/usb/driver/android_usb.inf
deleted file mode 100644
index fff0440..0000000
--- a/host/windows/prebuilt/usb/driver/android_usb.inf
+++ /dev/null
@@ -1,126 +0,0 @@
-;/*++
-;
-;Abstract:
-;    Installation inf for the Android USB Bulk device
-;
-;--*/
-
-[Version]
-Signature="$WINDOWS NT$"
-Class=USB
-ClassGuid={F72FE0D4-CBCB-407d-8814-9ED673D0DD6B}
-Provider=%GOOG%
-DriverVer=1/29/2009,1.0.0010.00000
-CatalogFile.NTx86=androidusb86.cat
-CatalogFile.NTamd64=androidusba64.cat
-
-; ================= Class section =====================
-
-[ClassInstall32]
-Addreg=AndroidUsbClassReg
-
-[AndroidUsbClassReg]
-HKR,,,0,%ClassName%
-HKR,,Icon,,-5
-
-[DestinationDirs]
-DefaultDestDir = 12
-
-; ================= Device section =====================
-
-[Manufacturer]
-%MfgName%=Google,NTx86,NTamd64
-
-; For Win2K
-[Google]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For XP and later
-[Google.NTx86]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For AMD64 and later
-[Google.NTamd64]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-[androidusb.Dev.NT]
-CopyFiles=androidusb.Files.Ext
-
-[androidusb.Dev.NT.Services]
-Addservice = androidusb, 0x00000002, androidusb.AddService
-
-[androidusb.AddService]
-DisplayName    = %androidusb.SvcDesc%
-ServiceType    = 1                  ; SERVICE_KERNEL_DRIVER
-StartType      = 3                  ; SERVICE_DEMAND_START
-ErrorControl   = 1                  ; SERVICE_ERROR_NORMAL
-ServiceBinary  = %10%\System32\Drivers\androidusb.sys
-AddReg         = androidusb.AddReg
-LoadOrderGroup = Base
-
-[androidusb.AddReg]
-HKR,"Parameters","MaximumTransferSize",0x10001,4096
-HKR,"Parameters","DebugLevel",0x10001,2
-HKR, Parameters\Wdf, VerboseOn,       0x00010001, 1
-HKR, Parameters\Wdf, VerifierOn,      0x00010001, 1
-HKR, Parameters\Wdf, DbgBreakOnError, 0x00010001, 1
-
-[androidusb.Files.Ext]
-androidusb.sys
-
-[SourceDisksNames]
-1=%Disk_Description%,,,
-
-[SourceDisksFiles]
-androidusb.sys = 1
-
-;-------------- WDF Coinstaller installation
-[DestinationDirs]
-CoInstaller_CopyFiles = 11
-
-[androidusb.Dev.NT.CoInstallers]
-AddReg=CoInstaller_AddReg
-CopyFiles=CoInstaller_CopyFiles
-
-[CoInstaller_CopyFiles]
-wdfcoinstaller01005.dll
-
-[SourceDisksFiles]
-wdfcoinstaller01005.dll=1 ; make sure the number matches with SourceDisksNames
-
-[CoInstaller_AddReg]
-HKR,,CoInstallers32,0x00010000, "wdfcoinstaller01005.dll,WdfCoInstaller"
-
-[androidusb.Dev.NT.Wdf]
-KmdfService = androidusb, androidusb_wdfsect
-
-[androidusb_wdfsect]
-KmdfLibraryVersion = 1.5
-
-;---------------------------------------------------------------;
-
-[Strings]
-GOOG            = "Google, Inc"
-MfgName         = "Google, Inc"
-Disk_Description= "ADB Interface Installation Disk"
-androidusb.SvcDesc = "ADB Interface Driver"
-ClassName       = "ADB Interface"
-USB\VID_18D1&PID_DDDD.DeviceDescTest="ADB Testing Interface"
-USB\VID_0BB4&PID_0C01.DeviceDescRelease="HTC Dream"
-USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease="HTC Dream Composite ADB Interface"
-USB\VID_0BB4&PID_0FFF.DeviceDescRelease="HTC Bootloader"
diff --git a/host/windows/prebuilt/usb/driver/androidusb.sys b/host/windows/prebuilt/usb/driver/androidusb.sys
deleted file mode 100644
index fe64531..0000000
--- a/host/windows/prebuilt/usb/driver/androidusb.sys
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/driver/androidusb86.cat b/host/windows/prebuilt/usb/driver/androidusb86.cat
deleted file mode 100644
index 12836dc..0000000
--- a/host/windows/prebuilt/usb/driver/androidusb86.cat
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/driver_amd_64/WdfCoInstaller01005.dll b/host/windows/prebuilt/usb/driver_amd_64/WdfCoInstaller01005.dll
deleted file mode 100644
index 32519fb..0000000
--- a/host/windows/prebuilt/usb/driver_amd_64/WdfCoInstaller01005.dll
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/driver_amd_64/android_usb.inf b/host/windows/prebuilt/usb/driver_amd_64/android_usb.inf
deleted file mode 100644
index fff0440..0000000
--- a/host/windows/prebuilt/usb/driver_amd_64/android_usb.inf
+++ /dev/null
@@ -1,126 +0,0 @@
-;/*++
-;
-;Abstract:
-;    Installation inf for the Android USB Bulk device
-;
-;--*/
-
-[Version]
-Signature="$WINDOWS NT$"
-Class=USB
-ClassGuid={F72FE0D4-CBCB-407d-8814-9ED673D0DD6B}
-Provider=%GOOG%
-DriverVer=1/29/2009,1.0.0010.00000
-CatalogFile.NTx86=androidusb86.cat
-CatalogFile.NTamd64=androidusba64.cat
-
-; ================= Class section =====================
-
-[ClassInstall32]
-Addreg=AndroidUsbClassReg
-
-[AndroidUsbClassReg]
-HKR,,,0,%ClassName%
-HKR,,Icon,,-5
-
-[DestinationDirs]
-DefaultDestDir = 12
-
-; ================= Device section =====================
-
-[Manufacturer]
-%MfgName%=Google,NTx86,NTamd64
-
-; For Win2K
-[Google]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For XP and later
-[Google.NTx86]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For AMD64 and later
-[Google.NTamd64]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-[androidusb.Dev.NT]
-CopyFiles=androidusb.Files.Ext
-
-[androidusb.Dev.NT.Services]
-Addservice = androidusb, 0x00000002, androidusb.AddService
-
-[androidusb.AddService]
-DisplayName    = %androidusb.SvcDesc%
-ServiceType    = 1                  ; SERVICE_KERNEL_DRIVER
-StartType      = 3                  ; SERVICE_DEMAND_START
-ErrorControl   = 1                  ; SERVICE_ERROR_NORMAL
-ServiceBinary  = %10%\System32\Drivers\androidusb.sys
-AddReg         = androidusb.AddReg
-LoadOrderGroup = Base
-
-[androidusb.AddReg]
-HKR,"Parameters","MaximumTransferSize",0x10001,4096
-HKR,"Parameters","DebugLevel",0x10001,2
-HKR, Parameters\Wdf, VerboseOn,       0x00010001, 1
-HKR, Parameters\Wdf, VerifierOn,      0x00010001, 1
-HKR, Parameters\Wdf, DbgBreakOnError, 0x00010001, 1
-
-[androidusb.Files.Ext]
-androidusb.sys
-
-[SourceDisksNames]
-1=%Disk_Description%,,,
-
-[SourceDisksFiles]
-androidusb.sys = 1
-
-;-------------- WDF Coinstaller installation
-[DestinationDirs]
-CoInstaller_CopyFiles = 11
-
-[androidusb.Dev.NT.CoInstallers]
-AddReg=CoInstaller_AddReg
-CopyFiles=CoInstaller_CopyFiles
-
-[CoInstaller_CopyFiles]
-wdfcoinstaller01005.dll
-
-[SourceDisksFiles]
-wdfcoinstaller01005.dll=1 ; make sure the number matches with SourceDisksNames
-
-[CoInstaller_AddReg]
-HKR,,CoInstallers32,0x00010000, "wdfcoinstaller01005.dll,WdfCoInstaller"
-
-[androidusb.Dev.NT.Wdf]
-KmdfService = androidusb, androidusb_wdfsect
-
-[androidusb_wdfsect]
-KmdfLibraryVersion = 1.5
-
-;---------------------------------------------------------------;
-
-[Strings]
-GOOG            = "Google, Inc"
-MfgName         = "Google, Inc"
-Disk_Description= "ADB Interface Installation Disk"
-androidusb.SvcDesc = "ADB Interface Driver"
-ClassName       = "ADB Interface"
-USB\VID_18D1&PID_DDDD.DeviceDescTest="ADB Testing Interface"
-USB\VID_0BB4&PID_0C01.DeviceDescRelease="HTC Dream"
-USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease="HTC Dream Composite ADB Interface"
-USB\VID_0BB4&PID_0FFF.DeviceDescRelease="HTC Bootloader"
diff --git a/host/windows/prebuilt/usb/driver_amd_64/androidusb.sys b/host/windows/prebuilt/usb/driver_amd_64/androidusb.sys
deleted file mode 100644
index 70ce24f..0000000
--- a/host/windows/prebuilt/usb/driver_amd_64/androidusb.sys
+++ /dev/null
Binary files differ
diff --git a/host/windows/prebuilt/usb/driver_amd_64/androidusba64.cat b/host/windows/prebuilt/usb/driver_amd_64/androidusba64.cat
deleted file mode 100644
index dd7850d..0000000
--- a/host/windows/prebuilt/usb/driver_amd_64/androidusba64.cat
+++ /dev/null
Binary files differ
diff --git a/host/windows/usb/api/AdbWinApi.cpp b/host/windows/usb/api/AdbWinApi.cpp
deleted file mode 100644
index c7e5303..0000000
--- a/host/windows/usb/api/AdbWinApi.cpp
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// AdbWinApi.cpp : Implementation of DLL Exports.
-
-#include "stdafx.h"
-
-class CAdbWinApiModule : public CAtlDllModuleT< CAdbWinApiModule > {
-public:
-};
-
-CAdbWinApiModule _AtlModule;
-
-// DLL Entry Point
-extern "C" BOOL WINAPI DllMain(HINSTANCE instance,
-                               DWORD reason,
-                               LPVOID reserved) {
-    return _AtlModule.DllMain(reason, reserved); 
-}
diff --git a/host/windows/usb/api/AdbWinApi.def b/host/windows/usb/api/AdbWinApi.def
deleted file mode 100644
index d55786e..0000000
--- a/host/windows/usb/api/AdbWinApi.def
+++ /dev/null
@@ -1,5 +0,0 @@
-; AdbWinApi.def : Declares the module parameters.
-
-LIBRARY      "AdbWinApi.DLL"
-
-EXPORTS
diff --git a/host/windows/usb/api/AdbWinApi.rc b/host/windows/usb/api/AdbWinApi.rc
deleted file mode 100644
index 013ea03..0000000
--- a/host/windows/usb/api/AdbWinApi.rc
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-//Microsoft Visual C++ generated resource script.
-//
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "winres.h"
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
-LANGUAGE 9, 1
-#pragma code_page(1252)
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE  
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE  
-BEGIN
-    "#include ""winres.h""\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-#ifndef _MAC
-/////////////////////////////////////////////////////////////////////////////
-//
-// Version
-//
-
-VS_VERSION_INFO VERSIONINFO
- FILEVERSION 1,0,0,1
- PRODUCTVERSION 1,0,0,1
- FILEFLAGSMASK 0x3fL
-#ifdef _DEBUG
- FILEFLAGS 0x1L
-#else
- FILEFLAGS 0x0L
-#endif
- FILEOS 0x4L
- FILETYPE 0x2L
- FILESUBTYPE 0x0L
-BEGIN
-    BLOCK "StringFileInfo"
-    BEGIN
-        BLOCK "040904e4"
-        BEGIN
-            VALUE "CompanyName", "Google, inc"
-            VALUE "FileDescription", "TODO: <File description>"
-            VALUE "FileVersion", "1.0.0.1"
-            VALUE "LegalCopyright", "Copyright (C) 2006 The Android Open Source Project"
-            VALUE "InternalName", "AdbWinApi.dll"
-            VALUE "OriginalFilename", "AdbWinApi.dll"
-            VALUE "ProductName", "TODO: <Product name>"
-            VALUE "ProductVersion", "1.0.0.1"
-            VALUE "OLESelfRegister", ""
-        END
-    END
-    BLOCK "VarFileInfo"
-    BEGIN
-		VALUE "Translation", 0x0409, 1252
-    END
-END
-
-#endif    // !_MAC
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE  
-BEGIN
-	IDS_PROJNAME					"AdbWinApi"
-END
-
-////////////////////////////////////////////////////////////////////////////
-
-
-#endif
-
-#ifndef APSTUDIO_INVOKED
-#endif    // not APSTUDIO_INVOKED
diff --git a/host/windows/usb/api/AdbWinApi.sln b/host/windows/usb/api/AdbWinApi.sln
deleted file mode 100644
index f6f4fc0..0000000
--- a/host/windows/usb/api/AdbWinApi.sln
+++ /dev/null
@@ -1,21 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 8.00
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AdbWinApi", "AdbWinApi.vcproj", "{C0A471E9-6892-4270-96DE-DB5F8D526FB1}"
-	ProjectSection(ProjectDependencies) = postProject
-	EndProjectSection
-EndProject
-Global
-	GlobalSection(SolutionConfiguration) = preSolution
-		Debug = Debug
-		Release = Release
-	EndGlobalSection
-	GlobalSection(ProjectConfiguration) = postSolution
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.ActiveCfg = Debug|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.Build.0 = Debug|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.ActiveCfg = Release|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.Build.0 = Release|Win32
-	EndGlobalSection
-	GlobalSection(ExtensibilityGlobals) = postSolution
-	EndGlobalSection
-	GlobalSection(ExtensibilityAddIns) = postSolution
-	EndGlobalSection
-EndGlobal
diff --git a/host/windows/usb/api/AdbWinApi.vcproj b/host/windows/usb/api/AdbWinApi.vcproj
deleted file mode 100644
index c8dfe55..0000000
--- a/host/windows/usb/api/AdbWinApi.vcproj
+++ /dev/null
@@ -1,290 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="7.10"
-	Name="AdbWinApi"
-	ProjectGUID="{C0A471E9-6892-4270-96DE-DB5F8D526FB1}"
-	Keyword="AtlProj">
-	<Platforms>
-		<Platform
-			Name="Win32"/>
-	</Platforms>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			OutputDirectory="Debug"
-			IntermediateDirectory="Debug"
-			ConfigurationType="2"
-			UseOfATL="1"
-			ATLMinimizesCRunTimeLibraryUsage="FALSE"
-			CharacterSet="1">
-			<Tool
-				Name="VCCLCompilerTool"
-				Optimization="0"
-				AdditionalIncludeDirectories="c:\winddk\6000\inc\api;..\common"
-				PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;ADBWIN_EXPORTS"
-				MinimalRebuild="FALSE"
-				BasicRuntimeChecks="3"
-				RuntimeLibrary="1"
-				BufferSecurityCheck="TRUE"
-				TreatWChar_tAsBuiltInType="TRUE"
-				UsePrecompiledHeader="3"
-				ProgramDataBaseFileName="..\build\$(OutDir)\i386\$(TargetName).pdb"
-				WarningLevel="4"
-				WarnAsError="TRUE"
-				Detect64BitPortabilityProblems="TRUE"
-				DebugInformationFormat="4"
-				DisableSpecificWarnings="4100;4200;4702"/>
-			<Tool
-				Name="VCCustomBuildTool"/>
-			<Tool
-				Name="VCLinkerTool"
-				IgnoreImportLibrary="TRUE"
-				AdditionalDependencies="c:\winddk\6000\lib\wxp\i386\usbd.lib setupapi.lib"
-				OutputFile="..\build\$(OutDir)\i386/AdbWinApi.dll"
-				LinkIncremental="2"
-				AdditionalLibraryDirectories=""
-				ModuleDefinitionFile=".\AdbWinApi.def"
-				GenerateDebugInformation="TRUE"
-				ProgramDatabaseFile="..\build\$(OutDir)\i386/$(ProjectName).pdb"
-				SubSystem="2"
-				ImportLibrary="..\build\$(OutDir)\i386/AdbWinApi.lib"
-				TargetMachine="1"/>
-			<Tool
-				Name="VCMIDLTool"
-				PreprocessorDefinitions="_DEBUG"
-				MkTypLibCompatible="FALSE"
-				TargetEnvironment="1"
-				GenerateStublessProxies="TRUE"
-				TypeLibraryName="$(IntDir)/AdbWinApi.tlb"
-				HeaderFileName="AdbWinApi.h"
-				DLLDataFileName=""
-				InterfaceIdentifierFileName="AdbWinApi_i.c"
-				ProxyFileName="AdbWinApi_p.c"/>
-			<Tool
-				Name="VCPostBuildEventTool"/>
-			<Tool
-				Name="VCPreBuildEventTool"/>
-			<Tool
-				Name="VCPreLinkEventTool"/>
-			<Tool
-				Name="VCResourceCompilerTool"
-				PreprocessorDefinitions="_DEBUG"
-				Culture="1033"
-				AdditionalIncludeDirectories="$(IntDir)"/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"/>
-			<Tool
-				Name="VCWebDeploymentTool"/>
-			<Tool
-				Name="VCManagedWrapperGeneratorTool"/>
-			<Tool
-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			OutputDirectory="Release"
-			IntermediateDirectory="Release"
-			ConfigurationType="2"
-			UseOfATL="1"
-			ATLMinimizesCRunTimeLibraryUsage="FALSE"
-			CharacterSet="1">
-			<Tool
-				Name="VCCLCompilerTool"
-				Optimization="4"
-				InlineFunctionExpansion="2"
-				AdditionalIncludeDirectories="c:\winddk\6000\inc\api;..\common"
-				PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG;_USRDLL;ADBWIN_EXPORTS"
-				MinimalRebuild="FALSE"
-				RuntimeLibrary="0"
-				BufferSecurityCheck="TRUE"
-				TreatWChar_tAsBuiltInType="TRUE"
-				UsePrecompiledHeader="3"
-				ProgramDataBaseFileName="..\build\$(OutDir)\i386\$(TargetName).pdb"
-				WarningLevel="4"
-				WarnAsError="TRUE"
-				Detect64BitPortabilityProblems="TRUE"
-				DebugInformationFormat="3"
-				DisableSpecificWarnings="4100;4200;4702"/>
-			<Tool
-				Name="VCCustomBuildTool"/>
-			<Tool
-				Name="VCLinkerTool"
-				IgnoreImportLibrary="TRUE"
-				AdditionalDependencies="c:\winddk\6000\lib\wxp\i386\usbd.lib setupapi.lib"
-				OutputFile="..\build\$(OutDir)\i386/AdbWinApi.dll"
-				LinkIncremental="1"
-				AdditionalLibraryDirectories=""
-				ModuleDefinitionFile=".\AdbWinApi.def"
-				GenerateDebugInformation="TRUE"
-				ProgramDatabaseFile="..\build\$(OutDir)\i386/$(ProjectName).pdb"
-				SubSystem="2"
-				OptimizeReferences="2"
-				EnableCOMDATFolding="2"
-				ImportLibrary="..\build\$(OutDir)\i386/AdbWinApi.lib"
-				TargetMachine="1"/>
-			<Tool
-				Name="VCMIDLTool"
-				PreprocessorDefinitions="NDEBUG"
-				MkTypLibCompatible="FALSE"
-				TargetEnvironment="1"
-				GenerateStublessProxies="TRUE"
-				TypeLibraryName="$(IntDir)/AdbWinApi.tlb"
-				HeaderFileName="AdbWinApi.h"
-				DLLDataFileName=""
-				InterfaceIdentifierFileName="AdbWinApi_i.c"
-				ProxyFileName="AdbWinApi_p.c"/>
-			<Tool
-				Name="VCPostBuildEventTool"/>
-			<Tool
-				Name="VCPreBuildEventTool"/>
-			<Tool
-				Name="VCPreLinkEventTool"/>
-			<Tool
-				Name="VCResourceCompilerTool"
-				PreprocessorDefinitions="NDEBUG"
-				Culture="1033"
-				AdditionalIncludeDirectories="$(IntDir)"/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"/>
-			<Tool
-				Name="VCWebDeploymentTool"/>
-			<Tool
-				Name="VCManagedWrapperGeneratorTool"/>
-			<Tool
-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="Source Files"
-			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
-			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
-			<File
-				RelativePath=".\adb_api.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_endpoint_object.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_helper_routines.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_interface.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_interface_enum.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_io_completion.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_io_object.cpp">
-			</File>
-			<File
-				RelativePath=".\adb_object_handle.cpp">
-			</File>
-			<File
-				RelativePath=".\AdbWinApi.cpp">
-			</File>
-			<File
-				RelativePath=".\AdbWinApi.def">
-			</File>
-			<File
-				RelativePath=".\stdafx.cpp">
-				<FileConfiguration
-					Name="Debug|Win32">
-					<Tool
-						Name="VCCLCompilerTool"
-						UsePrecompiledHeader="1"/>
-				</FileConfiguration>
-				<FileConfiguration
-					Name="Release|Win32">
-					<Tool
-						Name="VCCLCompilerTool"
-						UsePrecompiledHeader="1"/>
-				</FileConfiguration>
-			</File>
-		</Filter>
-		<Filter
-			Name="Header Files"
-			Filter="h;hpp;hxx;hm;inl;inc;xsd"
-			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
-			<File
-				RelativePath=".\adb_api.h">
-			</File>
-			<File
-				RelativePath=".\adb_api_private_defines.h">
-			</File>
-			<File
-				RelativePath=".\adb_endpoint_object.h">
-			</File>
-			<File
-				RelativePath=".\adb_helper_routines.h">
-			</File>
-			<File
-				RelativePath=".\adb_interface.h">
-			</File>
-			<File
-				RelativePath=".\adb_interface_enum.h">
-			</File>
-			<File
-				RelativePath=".\adb_io_completion.h">
-			</File>
-			<File
-				RelativePath=".\adb_io_object.h">
-			</File>
-			<File
-				RelativePath=".\adb_object_handle.h">
-			</File>
-			<File
-				RelativePath=".\Resource.h">
-			</File>
-			<File
-				RelativePath=".\stdafx.h">
-			</File>
-			<Filter
-				Name="common"
-				Filter="">
-				<File
-					RelativePath=".\adb_api_extra.h">
-				</File>
-				<File
-					RelativePath="..\common\android_usb_common_defines.h">
-				</File>
-			</Filter>
-			<Filter
-				Name="USB"
-				Filter="">
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb100.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb200.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usbdi.h">
-				</File>
-			</Filter>
-		</Filter>
-		<Filter
-			Name="Resource Files"
-			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
-			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">
-			<File
-				RelativePath=".\AdbWinApi.rc">
-			</File>
-		</Filter>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
diff --git a/host/windows/usb/api/Resource.h b/host/windows/usb/api/Resource.h
deleted file mode 100644
index fd2b2f9..0000000
--- a/host/windows/usb/api/Resource.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-//{{NO_DEPENDENCIES}}
-// Microsoft Visual C++ generated include file.
-// Used by AdbWinApi.rc
-//
-
-#define IDS_PROJNAME                    100
-#define IDR_ADBWINAPI	101
-
-// Next default values for new objects
-// 
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE        201
-#define _APS_NEXT_COMMAND_VALUE         32768
-#define _APS_NEXT_CONTROL_VALUE         201
-#define _APS_NEXT_SYMED_VALUE           102
-#endif
-#endif
diff --git a/host/windows/usb/api/adb_api.cpp b/host/windows/usb/api/adb_api.cpp
deleted file mode 100644
index 50356c7..0000000
--- a/host/windows/usb/api/adb_api.cpp
+++ /dev/null
@@ -1,508 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of rotines that are exported
-  from this DLL.
-*/
-
-#include "stdafx.h"
-#include "adb_api.h"
-#include "adb_object_handle.h"
-#include "adb_interface_enum.h"
-#include "adb_interface.h"
-#include "adb_endpoint_object.h"
-#include "adb_io_completion.h"
-#include "adb_helper_routines.h"
-
-ADBAPIHANDLE AdbEnumInterfaces(GUID class_id,
-                               bool exclude_not_present,
-                               bool exclude_removed,
-                               bool active_only) {
-  AdbInterfaceEnumObject* enum_obj = NULL;
-  ADBAPIHANDLE ret = NULL;
-
-  try {
-    // Instantiate and initialize enum object
-    enum_obj = new AdbInterfaceEnumObject();
-
-    if (enum_obj->InitializeEnum(class_id,
-                                 exclude_not_present,
-                                 exclude_removed,
-                                 active_only)) {
-      // After successful initialization we can create handle.
-      ret = enum_obj->CreateHandle();
-    }
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-  }
-
-  if (NULL != enum_obj)
-    enum_obj->Release();
-
-  return ret;
-}
-
-bool AdbNextInterface(ADBAPIHANDLE adb_handle,
-                      AdbInterfaceInfo* info,
-                      unsigned long* size) {
-  if (NULL == size) {
-    SetLastError(ERROR_INVALID_PARAMETER);
-    return false;
-  }
-
-  // Lookup AdbInterfaceEnumObject object for the handle
-  AdbInterfaceEnumObject* adb_ienum_object =
-    LookupObject<AdbInterfaceEnumObject>(adb_handle);
-  if (NULL == adb_ienum_object)
-    return false;
-
-  // Everything is verified. Pass it down to the object
-  bool ret = adb_ienum_object->Next(info, size);
-
-  adb_ienum_object->Release();
-
-  return ret;
-}
-
-bool AdbResetInterfaceEnum(ADBAPIHANDLE adb_handle) {
-  // Lookup AdbInterfaceEnumObject object for the handle
-  AdbInterfaceEnumObject* adb_ienum_object =
-    LookupObject<AdbInterfaceEnumObject>(adb_handle);
-  if (NULL == adb_ienum_object)
-    return false;
-
-  // Everything is verified. Pass it down to the object
-  bool ret = adb_ienum_object->Reset();
-
-  adb_ienum_object->Release();
-
-  return ret;
-}
-
-ADBWIN_API ADBAPIHANDLE AdbCreateInterfaceByName(
-    const wchar_t* interface_name) {
-  AdbInterfaceObject* obj = NULL;
-  ADBAPIHANDLE ret = NULL;
-
-  try {
-    // Instantiate object
-    obj = new AdbInterfaceObject(interface_name);
-
-    // Create handle for it
-    ret = obj->CreateHandle();
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-  }
-
-  if (NULL != obj)
-    obj->Release();
-
-  return ret;
-}
-
-ADBAPIHANDLE AdbCreateInterface(GUID class_id,
-                                unsigned short vendor_id,
-                                unsigned short product_id,
-                                unsigned char interface_id) {
-  // Enumerate all active interfaces for the given class
-  AdbEnumInterfaceArray interfaces;
-
-  if (!EnumerateDeviceInterfaces(class_id,
-                                 DIGCF_DEVICEINTERFACE | DIGCF_PRESENT,
-                                 true,
-                                 true,
-                                 &interfaces)) {
-    return NULL;
-  }
-
-  if (interfaces.empty()) {
-    SetLastError(ERROR_DEVICE_NOT_AVAILABLE);
-    return NULL;
-  }
-
-  // Now iterate over active interfaces looking for the name match.
-  // The name is formatted as such:
-  // "\\\\?\\usb#vid_xxxx&pid_xxxx&mi_xx#123456789abcdef#{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}"
-  // where
-  //    vid_xxxx is for the vendor id (xxxx are hex for the given vendor id),
-  //    pid_xxxx is for the product id (xxxx are hex for the given product id)
-  //    mi_xx is for the interface id  (xx are hex for the given interface id)
-  // EnumerateDeviceInterfaces will guarantee that returned interface names
-  // will have our class id at the end of the name (those last XXXes in the
-  // format). So, we only need to match the beginning of the name
-  wchar_t match_name[64];
-  if (0xFF == interface_id) {
-    // No interface id for the name.
-    swprintf(match_name, L"\\\\?\\usb#vid_%04x&pid_%04x#",
-             vendor_id, product_id);
-  } else {
-    // With interface id for the name.
-    swprintf(match_name, L"\\\\?\\usb#vid_%04x&pid_%04x&mi_%02x#",
-             vendor_id, product_id, interface_id);
-  }
-  size_t match_len = wcslen(match_name);
-
-  for (AdbEnumInterfaceArray::iterator it = interfaces.begin();
-       it != interfaces.end(); it++) {
-    const AdbInstanceEnumEntry& next_interface = *it;
-    if (0 == wcsnicmp(match_name,
-                      next_interface.device_name().c_str(),
-                      match_len)) {
-      // Found requested interface among active interfaces.
-      return AdbCreateInterfaceByName(next_interface.device_name().c_str());
-    }
-  }
-
-  SetLastError(ERROR_DEVICE_NOT_AVAILABLE);
-  return NULL;
-}
-
-bool AdbGetInterfaceName(ADBAPIHANDLE adb_interface,
-                         void* buffer,
-                         unsigned long* buffer_char_size,
-                         bool ansi) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch call to the found object
-    bool ret = adb_object->GetInterfaceName(buffer, buffer_char_size, ansi);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetSerialNumber(ADBAPIHANDLE adb_interface,
-                        void* buffer,
-                        unsigned long* buffer_char_size,
-                        bool ansi) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch call to the found object
-    bool ret = adb_object->GetSerialNumber(buffer, buffer_char_size, ansi);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetUsbDeviceDescriptor(ADBAPIHANDLE adb_interface,
-                               USB_DEVICE_DESCRIPTOR* desc) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    bool ret = adb_object->GetUsbDeviceDescriptor(desc);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetUsbConfigurationDescriptor(ADBAPIHANDLE adb_interface,
-                                      USB_CONFIGURATION_DESCRIPTOR* desc) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    bool ret = adb_object->GetUsbConfigurationDescriptor(desc);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetUsbInterfaceDescriptor(ADBAPIHANDLE adb_interface,
-                                  USB_INTERFACE_DESCRIPTOR* desc) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    bool ret = adb_object->GetUsbInterfaceDescriptor(desc);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetEndpointInformation(ADBAPIHANDLE adb_interface,
-                               UCHAR endpoint_index,
-                               AdbEndpointInformation* info) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    bool ret = adb_object->GetEndpointInformation(endpoint_index, info);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetDefaultBulkReadEndpointInformation(ADBAPIHANDLE adb_interface,
-                                              AdbEndpointInformation* info) {
-  return AdbGetEndpointInformation(adb_interface,
-                                   ADB_QUERY_BULK_READ_ENDPOINT_INDEX,
-                                   info);
-}
-
-bool AdbGetDefaultBulkWriteEndpointInformation(ADBAPIHANDLE adb_interface,
-                                               AdbEndpointInformation* info) {
-  return AdbGetEndpointInformation(adb_interface,
-                                   ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX,
-                                   info);
-}
-
-ADBAPIHANDLE AdbOpenEndpoint(ADBAPIHANDLE adb_interface,
-                             unsigned char endpoint_index,
-                             AdbOpenAccessType access_type,
-                             AdbOpenSharingMode sharing_mode) {
-  // Lookup interface object for the handle
-  AdbInterfaceObject* adb_object =
-    LookupObject<AdbInterfaceObject>(adb_interface);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    ADBAPIHANDLE ret =
-      adb_object->OpenEndpoint(endpoint_index, access_type, sharing_mode);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return NULL;
-  }
-}
-
-ADBAPIHANDLE AdbOpenDefaultBulkReadEndpoint(ADBAPIHANDLE adb_interface,
-                                            AdbOpenAccessType access_type,
-                                            AdbOpenSharingMode sharing_mode) {
-  return AdbOpenEndpoint(adb_interface,
-                         ADB_QUERY_BULK_READ_ENDPOINT_INDEX,
-                         access_type,
-                         sharing_mode);
-}
-
-ADBAPIHANDLE AdbOpenDefaultBulkWriteEndpoint(ADBAPIHANDLE adb_interface,
-                                             AdbOpenAccessType access_type,
-                                             AdbOpenSharingMode sharing_mode) {
-  return AdbOpenEndpoint(adb_interface,
-                         ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX,
-                         access_type,
-                         sharing_mode);
-}
-
-ADBAPIHANDLE AdbGetEndpointInterface(ADBAPIHANDLE adb_endpoint) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    ADBAPIHANDLE ret = adb_object->GetParentInterfaceHandle();
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return NULL;
-  }
-}
-
-bool AdbQueryInformationEndpoint(ADBAPIHANDLE adb_endpoint,
-                                 AdbEndpointInformation* info) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    bool ret = adb_object->GetEndpointInformation(info);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-ADBAPIHANDLE AdbReadEndpointAsync(ADBAPIHANDLE adb_endpoint,
-                                  void* buffer,
-                                  unsigned long bytes_to_read,
-                                  unsigned long* bytes_read,
-                                  unsigned long time_out,
-                                  HANDLE event_handle) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    ADBAPIHANDLE ret = adb_object->AsyncRead(buffer,
-                                             bytes_to_read,
-                                             bytes_read,
-                                             event_handle,
-                                             time_out);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return NULL;
-  }
-}
-
-ADBAPIHANDLE AdbWriteEndpointAsync(ADBAPIHANDLE adb_endpoint,
-                                   void* buffer,
-                                   unsigned long bytes_to_write,
-                                   unsigned long* bytes_written,
-                                   unsigned long time_out,
-                                   HANDLE event_handle) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    ADBAPIHANDLE ret = adb_object->AsyncWrite(buffer,
-                                              bytes_to_write,
-                                              bytes_written,
-                                              event_handle,
-                                              time_out);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbReadEndpointSync(ADBAPIHANDLE adb_endpoint,
-                         void* buffer,
-                         unsigned long bytes_to_read,
-                         unsigned long* bytes_read,
-                         unsigned long time_out) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    bool ret =
-      adb_object->SyncRead(buffer, bytes_to_read, bytes_read, time_out);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return NULL;
-  }
-}
-
-bool AdbWriteEndpointSync(ADBAPIHANDLE adb_endpoint,
-                          void* buffer,
-                          unsigned long bytes_to_write,
-                          unsigned long* bytes_written,
-                          unsigned long time_out) {
-  // Lookup endpoint object for the handle
-  AdbEndpointObject* adb_object =
-    LookupObject<AdbEndpointObject>(adb_endpoint);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    bool ret =
-      adb_object->SyncWrite(buffer, bytes_to_write, bytes_written, time_out);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbGetOvelappedIoResult(ADBAPIHANDLE adb_io_completion,
-                             LPOVERLAPPED overlapped,
-                             unsigned long* bytes_transferred,
-                             bool wait) {
-  // Lookup endpoint object for the handle
-  AdbIOCompletion* adb_object =
-    LookupObject<AdbIOCompletion>(adb_io_completion);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    bool ret =
-      adb_object->GetOvelappedIoResult(overlapped, bytes_transferred, wait);
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
-
-bool AdbHasOvelappedIoComplated(ADBAPIHANDLE adb_io_completion) {
-  // Lookup endpoint object for the handle
-  AdbIOCompletion* adb_object =
-    LookupObject<AdbIOCompletion>(adb_io_completion);
-
-  if (NULL != adb_object) {
-    // Dispatch the call to the found object
-    bool ret =
-      adb_object->IsCompleted();
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return true;
-  }
-}
-
-bool AdbCloseHandle(ADBAPIHANDLE adb_handle) {
-  // Lookup object for the handle
-  AdbObjectHandle* adb_object = AdbObjectHandle::Lookup(adb_handle);
-
-  if (NULL != adb_object) {
-    // Dispatch close to the found object
-    bool ret = adb_object->CloseHandle();
-    adb_object->Release();
-    return ret;
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-}
diff --git a/host/windows/usb/api/adb_api.h b/host/windows/usb/api/adb_api.h
deleted file mode 100644
index 98a32dc..0000000
--- a/host/windows/usb/api/adb_api.h
+++ /dev/null
@@ -1,541 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADBWINAPI_H__
-#define ANDROID_USB_API_ADBWINAPI_H__
-/** \file
-  This file consists of declarations of routines exported by the API as well
-  as types, structures, and constants definitions used in the API.
-  Declarations in this file, combined with definitions found in adb_api_extra.h
-  comprise ADB API for windows.
-*/
-
-#include "adb_api_extra.h"
-
-// Enables compillation for "straight" C
-#ifdef __cplusplus
-  #define EXTERN_C    extern "C"
-#else
-  #define EXTERN_C    extern
-  typedef int bool;
-  #define true  1
-  #define false 0
-#endif
-
-// The following ifdef block is the standard way of creating macros which make
-// exporting  from a DLL simpler. All files within this DLL are compiled with
-// the ADBWIN_EXPORTS symbol defined on the command line. this symbol should
-// not be defined on any project that uses this DLL. This way any other project
-// whose source files include this file see ADBWIN_API functions as being
-// imported from a DLL, whereas this DLL sees symbols defined with this macro
-// as being exported.
-#ifdef ADBWIN_EXPORTS
-#define ADBWIN_API EXTERN_C __declspec(dllexport)
-#else
-#define ADBWIN_API EXTERN_C __declspec(dllimport)
-#endif
-
-/** Handle to an API object
-
-  To access USB interface and its components clients must first obtain a
-  handle to the required object. API Objects that are represented by a
-  handle are:
-  1. Interface enumerator that provides access to a list of interfaces that
-     match certain criterias that were specified when interface enumerator
-     has been created. This handle is created in AdbEnumInterfaces routine.
-  2. Interface that is the major object this API deals with. In Windows
-     model of the USB stack each USB device (that is physical device,
-     attached to a USB port) exposes one or more interfaces that become the
-     major entities through which that device gets accessed. Each of these
-     interfaces are represented as Windows Device Objects on the USB stack.
-     So, to this extent, at least as this API is concerned, terms "interface"
-     and "device" are interchangeable, since each interface is represented by
-     a device object on the Windows USB stack. This handle is created in
-     either AdbCreateInterface or AdbCreateInterfaceByName routines.
-  3. Endpoint object (also called a pipe) represents an endpoint on interface
-     through which all I/O operations are performed. This handle is created in
-     one of these routines: AdbOpenEndpoint, AdbOpenDefaultBulkReadEndpoint,
-     or AdbOpenDefaultBulkWriteEndpoint.
-  4. I/O completion object that tracks completion information of asynchronous
-     I/O performed on an endpoint. When an endpoint object gets opened through
-     this API it is opened for asynchronous (or overlapped) I/O. And each time
-     an asynchronous I/O is performed by this API an I/O completion object is
-     created to track the result of that I/O when it gets completed. Clients
-     of the API can then use a handle to I/O completion object to query for
-     the status and result of asynchronous I/O as well as wait for this I/O
-     completion. This handle is created in one of these routines:
-     AdbReadEndpointAsync, or AdbWriteEndpointAsync.
-  After object is no longer needed by the client, its handle must be closed
-  using AdbCloseHandle routine.
-*/
-typedef void* ADBAPIHANDLE;
-
-/** Enumeration AdbOpenAccessType defines access type with which
-  an I/O object (endpoint) should be opened.
-*/
-typedef enum _AdbOpenAccessType {
-  /// Opens for read and write access
-  AdbOpenAccessTypeReadWrite,
-
-  /// Opens for read only access
-  AdbOpenAccessTypeRead,
-
-  /// Opens for write only access
-  AdbOpenAccessTypeWrite,
-
-  /// Opens for querying information
-  AdbOpenAccessTypeQueryInfo,
-} AdbOpenAccessType;
-
-/** Enumeration AdbOpenSharingMode defines sharing mode with which
-  an I/O object (endpoint) should be opened.
-*/
-typedef enum _AdbOpenSharingMode {
-  /// Shares read and write
-  AdbOpenSharingModeReadWrite,
-
-  /// Shares only read
-  AdbOpenSharingModeRead,
-
-  /// Shares only write
-  AdbOpenSharingModeWrite,
-
-  /// Opens exclusive
-  AdbOpenSharingModeExclusive,
-} AdbOpenSharingMode;
-
-/** Structure AdbInterfaceInfo provides information about an interface
-*/
-typedef struct _AdbInterfaceInfo {
-  /// Inteface's class id (see SP_DEVICE_INTERFACE_DATA for details)
-  GUID          class_id;
-
-  /// Interface flags (see SP_DEVICE_INTERFACE_DATA for details)
-  unsigned long flags;
-
-  /// Device name for the interface (see SP_DEVICE_INTERFACE_DETAIL_DATA
-  /// for details)
-  wchar_t       device_name[1];
-} AdbInterfaceInfo;
-
-/** \brief Creates USB interface enumerator
-
-  This routine enumerates all USB interfaces that match provided class ID.
-  This routine uses SetupDiGetClassDevs SDK routine to enumerate devices that
-  match class ID and then SetupDiEnumDeviceInterfaces SDK routine is called
-  to enumerate interfaces on the devices.
-  @param class_id[in] Device class ID, assigned by the driver.
-  @param exclude_not_present[in] If 'true' enumation will include only those
-         devices that are currently present.
-  @param exclude_removed[in] If 'true' interfaces with SPINT_REMOVED flag set
-         will be not included in the enumeration.
-  @param active_only[in] If 'true' only active interfaces (with flag
-           SPINT_ACTIVE set) will be included in the enumeration.
-  @return Handle to the enumerator object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbEnumInterfaces(GUID class_id,
-                                          bool exclude_not_present,
-                                          bool exclude_removed,
-                                          bool active_only);
-
-/** \brief Gets next interface information
-
-  @param adb_handle[in] Handle to interface enumerator object obtained via
-         AdbEnumInterfaces call.
-  @param info[out] Upon successful completion will receive interface
-         information. Can be NULL. If it is NULL, upon return from this
-         routine size parameter will contain memory size required for the
-         next entry.
-  @param size[in,out]. On the way in provides size of the memory buffer
-         addressed by info parameter. On the way out (only if buffer was not
-         big enough) will provide memory size required for the next entry.
-  @return true on success, false on error. If false is returned
-          GetLastError() provides extended error information.
-          ERROR_INSUFFICIENT_BUFFER indicates that buffer provided in info
-          parameter was not big enough and size parameter contains memory size
-          required for the next entry. ERROR_NO_MORE_ITEMS indicates that
-          enumeration is over and there are no more entries to return.
-*/
-ADBWIN_API bool AdbNextInterface(ADBAPIHANDLE adb_handle,
-                                 AdbInterfaceInfo* info,
-                                 unsigned long* size);
-
-/** \brief Resets enumerator so next call to AdbNextInterface will start
-  from the beginning.
-
-  @param adb_handle[in] Handle to interface enumerator object obtained via
-         AdbEnumInterfaces call.
-  @return true on success, false on error. If false is returned GetLastError()
-          provides extended error information.
-*/
-ADBWIN_API bool AdbResetInterfaceEnum(ADBAPIHANDLE adb_handle);
-
-/** \brief Creates USB interface object
-
-  This routine creates an object that represents a USB interface.
-  @param interface_name[in] Name of the interface.
-  @return Handle to the interface object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbCreateInterfaceByName(const wchar_t* interface_name);
-
-/** \brief
-  Creates USB interface object based on vendor, product and interface IDs.
-
-  This routine creates and object that represents a USB interface on our
-  device. It uses AdbCreateInterfaceByName to actually do the create.
-  @param class_id[in] Device class ID, assigned by the driver.
-  @param vendor_id[in] Device vendor ID
-  @param product_id[in] Device product ID
-  @param interface_id[in] Device interface ID. This parameter is optional.
-         Value 0xFF indicates that interface should be addressed by vendor
-         and product IDs only.
-  @return Handle to the interface object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbCreateInterface(GUID class_id,
-                                           unsigned short vendor_id,
-                                           unsigned short product_id,
-                                           unsigned char interface_id);
-
-/** \brief Gets interface name.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param buffer[out] Buffer for the name. Can be NULL in which case
-         buffer_char_size will contain number of characters required for
-         the name.
-  @param buffer_char_size[in/out] On the way in supplies size (in characters)
-         of the buffer. On the way out, if method failed and GetLastError
-         reports ERROR_INSUFFICIENT_BUFFER, will contain number of characters
-         required for the name.
-  @param ansi[in] If 'true' the name will be returned as single character
-         string. Otherwise name will be returned as wide character string.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetInterfaceName(ADBAPIHANDLE adb_interface,
-                                    void* buffer,
-                                    unsigned long* buffer_char_size,
-                                    bool ansi);
-
-/** \brief Gets serial number for interface's device.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param buffer[out] Buffer for the serail number string. Can be NULL in which
-         case buffer_char_size will contain number of characters required for
-         the string.
-  @param buffer_char_size[in/out] On the way in supplies size (in characters)
-         of the buffer. On the way out, if method failed and GetLastError
-         reports ERROR_INSUFFICIENT_BUFFER, will contain number of characters
-         required for the name.
-  @param ansi[in] If 'true' the name will be returned as single character
-         string. Otherwise name will be returned as wide character string.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetSerialNumber(ADBAPIHANDLE adb_interface,
-                                   void* buffer,
-                                   unsigned long* buffer_char_size,
-                                   bool ansi);
-
-/** \brief Gets device descriptor for the USB device associated with
-  the given interface.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param desc[out] Upon successful completion will have usb device
-         descriptor.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetUsbDeviceDescriptor(ADBAPIHANDLE adb_interface,
-                                          USB_DEVICE_DESCRIPTOR* desc);
-
-/** \brief Gets descriptor for the selected USB device configuration.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param desc[out] Upon successful completion will have usb device
-         configuration descriptor.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetUsbConfigurationDescriptor(ADBAPIHANDLE adb_interface,
-                                                 USB_CONFIGURATION_DESCRIPTOR* desc);
-
-/** \brief Gets descriptor for the given interface.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param desc[out] Upon successful completion will have usb device
-         configuration descriptor.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetUsbInterfaceDescriptor(ADBAPIHANDLE adb_interface,
-                                             USB_INTERFACE_DESCRIPTOR* desc);
-
-/** \brief Gets information about an endpoint on the given interface.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param endpoint_index[in] Zero-based endpoint index. There are two
-         shortcuts for this parameter: ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX
-         and ADB_QUERY_BULK_READ_ENDPOINT_INDEX that provide information
-         about bulk write and bulk read endpoints respectively.
-  @param info[out] Upon successful completion will have endpoint information.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetEndpointInformation(ADBAPIHANDLE adb_interface,
-                                          unsigned char endpoint_index,
-                                          AdbEndpointInformation* info);
-
-/** \brief
-  Gets information about default bulk read endpoint on the given interface.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param info[out] Upon successful completion will have endpoint information.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetDefaultBulkReadEndpointInformation(ADBAPIHANDLE adb_interface,
-                                                         AdbEndpointInformation* info);
-
-/** \brief
-  Gets information about default bulk write endpoint on the given interface.
-
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param info[out] Upon successful completion will have endpoint information.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbGetDefaultBulkWriteEndpointInformation(ADBAPIHANDLE adb_interface,
-                                                          AdbEndpointInformation* info);
-
-/** \brief Opens an endpoint on the given interface.
-
-  Endpoints are always opened for overlapped I/O.
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param endpoint_index[in] Zero-based endpoint index. There are two
-         shortcuts for this parameter: ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX
-         and ADB_QUERY_BULK_READ_ENDPOINT_INDEX that provide information
-         about bulk write and bulk read endpoints respectively.
-  @param access_type[in] Desired access type. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always read / write access.
-  @param sharing_mode[in] Desired share mode. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always shared for read / write.
-  @return Handle to the opened endpoint object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbOpenEndpoint(ADBAPIHANDLE adb_interface,
-                                        unsigned char endpoint_index,
-                                        AdbOpenAccessType access_type,
-                                        AdbOpenSharingMode sharing_mode);
-
-/** \brief Opens default bulk read endpoint on the given interface.
-
-  Endpoints are always opened for overlapped I/O.
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param access_type[in] Desired access type. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always read / write access.
-  @param sharing_mode[in] Desired share mode. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always shared for read / write.
-  @return Handle to the opened endpoint object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbOpenDefaultBulkReadEndpoint(ADBAPIHANDLE adb_interface,
-                                                       AdbOpenAccessType access_type,
-                                                       AdbOpenSharingMode sharing_mode);
-
-/** \brief Opens default bulk write endpoint on the given interface.
-
-  Endpoints are always opened for overlapped I/O.
-  @param adb_interface[in] A handle to interface object created with 
-         AdbCreateInterface call.
-  @param access_type[in] Desired access type. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always read / write access.
-  @param sharing_mode[in] Desired share mode. In the current implementation
-         this parameter has no effect on the way endpoint is opened. It's
-         always shared for read / write.
-  @return Handle to the opened endpoint object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbOpenDefaultBulkWriteEndpoint(ADBAPIHANDLE adb_interface,
-                                                        AdbOpenAccessType access_type,
-                                                        AdbOpenSharingMode sharing_mode);
-
-/** \brief Gets handle to interface object for the given endpoint
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @return Handle to the interface for this endpoint or NULL on failure. If NULL
-          is returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbGetEndpointInterface(ADBAPIHANDLE adb_endpoint);
-
-/** \brief Gets information about the given endpoint.
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @param info[out] Upon successful completion will have endpoint information.
-  @return 'true' on success, 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbQueryInformationEndpoint(ADBAPIHANDLE adb_endpoint,
-                                            AdbEndpointInformation* info);
-
-/** \brief Asynchronously reads from the given endpoint.
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @param buffer[out] Pointer to the buffer that receives the data.
-  @param bytes_to_read[in] Number of bytes to be read.
-  @param bytes_read[out] Number of bytes read. Can be NULL.
-  @param event_handle[in] Event handle that should be signaled when async I/O
-         completes. Can be NULL. If it's not NULL this handle will be used to
-         initialize OVERLAPPED structure for this I/O.
-  @param time_out[in] A timeout (in milliseconds) required for this I/O to
-         complete. Zero value for this parameter means that there is no
-         timeout for this I/O.
-  @return A handle to IO completion object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbReadEndpointAsync(ADBAPIHANDLE adb_endpoint,
-                                             void* buffer,
-                                             unsigned long bytes_to_read,
-                                             unsigned long* bytes_read,
-                                             unsigned long time_out,
-                                             HANDLE event_handle);
-
-/** \brief Asynchronously writes to the given endpoint.
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @param buffer[in] Pointer to the buffer containing the data to be written.
-  @param bytes_to_write[in] Number of bytes to be written.
-  @param bytes_written[out] Number of bytes written. Can be NULL.
-  @param event_handle[in] Event handle that should be signaled when async I/O
-         completes. Can be NULL. If it's not NULL this handle will be used to
-         initialize OVERLAPPED structure for this I/O.
-  @param time_out[in] A timeout (in milliseconds) required for this I/O to
-         complete. Zero value for this parameter means that there is no
-         timeout for this I/O.
-  @return A handle to IO completion object or NULL on failure. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API ADBAPIHANDLE AdbWriteEndpointAsync(ADBAPIHANDLE adb_endpoint,
-                                              void* buffer,
-                                              unsigned long bytes_to_write,
-                                              unsigned long* bytes_written,
-                                              unsigned long time_out,
-                                              HANDLE event_handle);
-
-/** \brief Synchronously reads from the given endpoint.
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @param buffer[out] Pointer to the buffer that receives the data.
-  @param bytes_to_read[in] Number of bytes to be read.
-  @param bytes_read[out] Number of bytes read. Can be NULL.
-  @param time_out[in] A timeout (in milliseconds) required for this I/O to
-         complete. Zero value for this parameter means that there is no
-         timeout for this I/O.
-  @return 'true' on success and 'false' on failure. If 'false' is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbReadEndpointSync(ADBAPIHANDLE adb_endpoint,
-                                    void* buffer,
-                                    unsigned long bytes_to_read,
-                                    unsigned long* bytes_read,
-                                    unsigned long time_out);
-
-/** \brief Synchronously writes to the given endpoint.
-
-  @param adb_endpoint[in] A handle to opened endpoint object, obtained via one
-         of the AdbOpenXxxEndpoint calls.
-  @param buffer[in] Pointer to the buffer containing the data to be written.
-  @param bytes_to_write[in] Number of bytes to be written.
-  @param bytes_written[out] Number of bytes written. Can be NULL.
-  @param time_out[in] A timeout (in milliseconds) required for this I/O to
-         complete. Zero value for this parameter means that there is no
-         timeout for this I/O.
-  @return 'true' on success and 'false' on failure. If 'false' is
-          returned GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbWriteEndpointSync(ADBAPIHANDLE adb_endpoint,
-                                     void* buffer,
-                                     unsigned long bytes_to_write,
-                                     unsigned long* bytes_written,
-                                     unsigned long time_out);
-
-/** \brief Gets overlapped I/O result for async I/O performed on the
-  given endpoint
-
-  @param adb_io_completion[in] A handle to an I/O completion object returned
-         from AdbRead/WriteAsync routines.
-  @param ovl_data[out] Buffer for the copy of this object's OVERLAPPED
-         structure. Can be NULL.
-  @param bytes_transferred[out] Pointer to a variable that receives the
-         number of bytes that were actually transferred by a read or write
-         operation. See SDK doc on GetOvelappedResult for more information.
-         Unlike regular GetOvelappedResult call this parameter can be NULL.
-  @param wait[in] If this parameter is 'true', the method does not return
-         until the operation has been completed. If this parameter is 'false'
-         and the operation is still pending, the method returns 'false' and
-         the GetLastError function returns ERROR_IO_INCOMPLETE.
-  @return 'true' if I/O has been completed or 'false' on failure or if request
-         is not yet completed. If 'false' is returned GetLastError() provides
-         extended error information. If GetLastError returns
-         ERROR_IO_INCOMPLETE it means that I/O is not yet completed.
-*/
-ADBWIN_API bool AdbGetOvelappedIoResult(ADBAPIHANDLE adb_io_completion,
-                                        LPOVERLAPPED overlapped,
-                                        unsigned long* bytes_transferred,
-                                        bool wait);
-
-/** \brief Checks if overlapped I/O has been completed.
-
-  @param adb_io_completion[in] A handle to an I/O completion object returned
-         from AdbRead/WriteAsync routines.
-  @return 'true' if I/O has been completed or 'false' if it's still
-          incomplete. Regardless of the returned value, caller should
-          check GetLastError to validate that handle was OK.
-*/
-ADBWIN_API bool AdbHasOvelappedIoComplated(ADBAPIHANDLE adb_io_completion);
-
-/** \brief Closes handle previously opened with one of the API calls
-
-  @param adb_handle[in] ADB handle previously opened with one of the API calls
-  @return 'true' on success or 'false' on failure. If 'false' is returned
-          GetLastError() provides extended error information.
-*/
-ADBWIN_API bool AdbCloseHandle(ADBAPIHANDLE adb_handle);
-
-
-#endif  // ANDROID_USB_API_ADBWINAPI_H__
diff --git a/host/windows/usb/api/adb_api_extra.h b/host/windows/usb/api/adb_api_extra.h
deleted file mode 100644
index e644b01..0000000
--- a/host/windows/usb/api/adb_api_extra.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_API_EXTRA_H__
-#define ANDROID_USB_API_ADB_API_EXTRA_H__
-/** \file
-  This file consists of public API declarations that are also used by the
-  driver and as such cannot be declared in adb_api.h
-*/
-
-/** AdbEndpointType enumerates endpoint types. It enum is taken from
-  WDF_USB_PIPE_TYPE enum found in WDK.
-*/
-typedef enum _AdbEndpointType {
-    AdbEndpointTypeInvalid = 0,
-    AdbEndpointTypeControl,
-    AdbEndpointTypeIsochronous,
-    AdbEndpointTypeBulk,
-    AdbEndpointTypeInterrupt,
-} AdbEndpointType;
-
-/** Structure AdbEndpointInformation describes an endpoint. It is
-  based on WDF_USB_PIPE_INFORMATION structure found in WDK.
-*/
-typedef struct _AdbEndpointInformation {
-  /// Maximum packet size this endpoint is capable of
-  unsigned long max_packet_size;
-
-  // Maximum size of one transfer which should be sent to the host controller
-  unsigned long max_transfer_size;
-
-  // The type of the endpoint
-  AdbEndpointType endpoint_type;
-
-  /// Raw endpoint address of the device as described by its descriptor
-  unsigned char endpoint_address;
-
-  /// Polling interval
-  unsigned char polling_interval;
-
-  /// Which alternate setting this structure is relevant for
-  unsigned char setting_index;
-} AdbEndpointInformation;
-
-/// Shortcut to default write bulk endpoint in zero-based endpoint index API
-#define ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX  0xFC
-
-/// Shortcut to default read bulk endpoint in zero-based endpoint index API
-#define ADB_QUERY_BULK_READ_ENDPOINT_INDEX  0xFE
-
-// {F72FE0D4-CBCB-407d-8814-9ED673D0DD6B}
-/// Our USB class id that driver uses to register our device
-#define ANDROID_USB_CLASS_ID \
-{0xf72fe0d4, 0xcbcb, 0x407d, {0x88, 0x14, 0x9e, 0xd6, 0x73, 0xd0, 0xdd, 0x6b}};
-
-/// Defines vendor ID for the device
-#define DEVICE_VENDOR_ID            0x0BB4
-
-/// Defines product ID for the device with single interface.
-#define DEVICE_SINGLE_PRODUCT_ID    0x0C01
-
-/// Defines product ID for the composite device.
-#define DEVICE_COMPOSITE_PRODUCT_ID 0x0C02
-
-/// Defines interface ID for the device.
-#define DEVICE_INTERFACE_ID         0x01
-
-/// Defines vendor ID for the device
-#define DEVICE_EMULATOR_VENDOR_ID   0x18D1
-
-/// Defines product ID for a SoftUSB device simulator that is used to test
-/// the driver in isolation from hardware.
-#define DEVICE_EMULATOR_PROD_ID     0xDDDD
-
-#endif  // ANDROID_USB_API_ADB_API_EXTRA_H__
diff --git a/host/windows/usb/api/adb_api_instance.cpp b/host/windows/usb/api/adb_api_instance.cpp
deleted file mode 100644
index 4f66b98..0000000
--- a/host/windows/usb/api/adb_api_instance.cpp
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AdbApiInstance that is a main
-  API object representing a device interface that is in the interest of
-  the API client. All device (interface) related operations go through this
-  class first.
-*/
-
-#include "stdafx.h"
-#include "adb_api_instance.h"
-#include "adb_helper_routines.h"
-
-/// Map that holds all instances of this object
-AdbApiInstanceMap adb_app_instance_map;
-ULONG_PTR adb_app_instance_id = 0;
-CComAutoCriticalSection adb_app_instance_map_locker;
-
-AdbApiInstance::AdbApiInstance()
-    : ref_count_(1) {
-  // Generate inteface handle
-  adb_app_instance_map_locker.Lock();
-  adb_app_instance_id++;
-  adb_app_instance_map_locker.Unlock();
-  instance_handle_ =
-    reinterpret_cast<ADBAPIINSTANCEHANDLE>(adb_app_instance_id);
-}
-
-AdbApiInstance::~AdbApiInstance() {
-}
-
-void AdbApiInstance::LastReferenceReleased() {
-}
diff --git a/host/windows/usb/api/adb_api_instance.h b/host/windows/usb/api/adb_api_instance.h
deleted file mode 100644
index 9bc80b8..0000000
--- a/host/windows/usb/api/adb_api_instance.h
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_API_INSTANCE_H__
-#define ANDROID_USB_API_ADB_API_INSTANCE_H__
-/** \file
-  This file consists of declaration of class AdbApiInstance that is a main
-  API object representing a device interface that is in the interest of
-  the API client. All device (interface) related operations go through this
-  class first.
-*/
-
-#include "adb_api.h"
-#include "adb_api_private_defines.h"
-
-/** Class AdbApiInstance is the main API interbal object representing a device
-  interface that is in the interest of the API client. All device (interface)
-  related operations go through this class first. So, before doing anything
-  meaningfull with the API a client must first create instance of the API
-  via CreateAdbApiInstance, select a device interface for that instance and
-  then do everything else.
-  Objects of this class are globally stored in the map that matches
-  ADBAPIINSTANCEHANDLE to the corresponded object.
-  This class is self-referenced with the following reference model:
-  1. When object of this class is created and added to the map, its recount
-     is set to 1.
-  2. Every time the client makes an API call that uses ADBAPIINSTANCEHANDLE
-     a corresponded AdbApiInstance object is looked up in the table and its
-     refcount is incremented. Upon return from the API call that incremented
-     the refcount refcount gets decremented.
-  3. When the client closes ADBAPIINSTANCEHANDLE via DeleteAdbApiInstance call
-     corresponded object gets deleted from the map and its refcount is
-     decremented.
-  So, at the end, this object destroys itself when refcount drops to zero.
-*/
-class AdbApiInstance {
- public:
-  /** \brief Constructs the object
-    
-    @param handle[in] Instance handle associated with this object
-  */
-  AdbApiInstance();
-
- private:
-  /// Destructs the object
-  ~AdbApiInstance();
-
-  /** \brief
-    This method is called when last reference to this object has been released
-
-    In this method object is uninitialized and deleted (that is "delete this"
-    is called).
-  */
-  void LastReferenceReleased();
-
- public:
-   /// Gets name of the USB interface (device name) for this instance
-   const std::wstring& interface_name() const {
-     return interface_name_;
-   }
-
-   /// References the object and returns number of references
-   LONG AddRef() {
-     return InterlockedIncrement(&ref_count_);
-   }
-
-   /** \brief Dereferences the object and returns number of references
-
-    Object may be deleted in this method, so you cannot touch it after
-    this method returns, even if returned value is not zero, because object
-    can be deleted in another thread.
-   */
-   LONG Release() {
-     LONG ret = InterlockedDecrement(&ref_count_);
-     if (0 == ret)
-       LastReferenceReleased();
-
-     return ret;
-   }
-
-   /// Checks if instance has been initialized
-   bool IsInitialized() const {
-     return !interface_name_.empty();
-   }
-
-private:
-  /// Name of the USB interface (device name) for this instance
-  std::wstring          interface_name_;
-
-  /// Instance handle for this object
-  ADBAPIINSTANCEHANDLE  instance_handle_;
-
-  /// Reference counter for this instance
-  LONG                  ref_count_;
-};
-
-/// Defines map that matches ADBAPIINSTANCEHANDLE with AdbApiInstance object
-typedef std::map< ADBAPIINSTANCEHANDLE, AdbApiInstance* > AdbApiInstanceMap;
-
-#endif  // ANDROID_USB_API_ADB_API_INSTANCE_H__
diff --git a/host/windows/usb/api/adb_api_private_defines.h b/host/windows/usb/api/adb_api_private_defines.h
deleted file mode 100644
index e1da7fe..0000000
--- a/host/windows/usb/api/adb_api_private_defines.h
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_ADB_API_PRIVATE_DEFINES_H__
-#define ANDROID_USB_ADB_API_PRIVATE_DEFINES_H__
-/** \file
-  This file consists of private definitions used inside the API
-*/
-
-#include "adb_api.h"
-
-/** Class AdbInstanceEnumEntry encapsulates an entry in the array of
-  enumerated interfaces.
-*/
-class AdbInstanceEnumEntry {
- public:
-  /** \brief Constructs an empty object.
-  */
-  AdbInstanceEnumEntry()
-      : flags_(0) {
-    ZeroMemory(&class_id_, sizeof(class_id_));
-  }
-
-  /** \brief Copy constructor
-  */
-  AdbInstanceEnumEntry(const AdbInstanceEnumEntry& proto) {
-    Set(proto.device_name().c_str(), proto.class_id(), proto.flags());
-  }
-
-  /** \brief Constructs the object with parameters.
-  */
-  AdbInstanceEnumEntry(const wchar_t* dev_name, GUID cls_id, DWORD flgs) {
-    Set(dev_name, cls_id, flgs);
-  }
-
-  /** \brief Destructs the object.
-  */
-  ~AdbInstanceEnumEntry() {
-  }
-
-  /// Operator =
-  AdbInstanceEnumEntry& operator=(const AdbInstanceEnumEntry& proto) {
-    Set(proto.device_name().c_str(), proto.class_id(), proto.flags());
-    return *this;
-  }
-
-  /// Initializes instance with parameters
-  void Set(const wchar_t* dev_name, GUID cls_id, DWORD flgs) {
-    device_name_ = dev_name;
-    class_id_ = cls_id;
-    flags_ = flgs;
-  }
-
-  /// Calculates memory size needed to save this entry into AdbInterfaceInfo
-  /// structure
-  ULONG GetFlatSize() const {
-    return static_cast<ULONG>(FIELD_OFFSET(AdbInterfaceInfo, device_name) +
-                              (device_name_.length() + 1) * sizeof(wchar_t));
-  }
-
-  /** \brief Saves this entry into AdbInterfaceInfo structure.
-
-    @param info[in] Buffer to save this entry to. Must be big enough to fit it.
-           Use GetFlatSize() method to get buffer size needed for that.
-
-  */
-  void Save(AdbInterfaceInfo* info) const {
-    info->class_id = class_id();
-    info->flags = flags();
-    wcscpy(info->device_name, device_name().c_str());
-  }
-
-  /// Gets interface's device name
-  const std::wstring& device_name() const {
-    return device_name_;
-  }
-
-  /// Gets inteface's class id
-  GUID class_id() const {
-    return class_id_;
-  }
-
-  /// Gets interface flags
-  DWORD flags() const {
-    return flags_;
-  }
-
- private:
-  /// Inteface's class id (see SP_DEVICE_INTERFACE_DATA)
-  GUID          class_id_;
-
-  /// Interface's device name
-  std::wstring  device_name_;
-
-  /// Interface flags (see SP_DEVICE_INTERFACE_DATA)
-  DWORD         flags_;
-};
-
-/// Defines array of enumerated interface entries
-typedef std::vector< AdbInstanceEnumEntry > AdbEnumInterfaceArray;
-
-#endif  // ANDROID_USB_ADB_API_PRIVATE_DEFINES_H__
diff --git a/host/windows/usb/api/adb_endpoint_object.cpp b/host/windows/usb/api/adb_endpoint_object.cpp
deleted file mode 100644
index 90f698f..0000000
--- a/host/windows/usb/api/adb_endpoint_object.cpp
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AdbIOObject that
-  encapsulates an interface on our USB device.
-*/
-
-#include "stdafx.h"
-#include "adb_endpoint_object.h"
-
-AdbEndpointObject::AdbEndpointObject(AdbInterfaceObject* parent_interf)
-    : AdbIOObject(parent_interf, AdbObjectTypeEndpoint) {
-}
-
-AdbEndpointObject::~AdbEndpointObject() {
-}
-
-bool AdbEndpointObject::IsObjectOfType(AdbObjectType obj_type) const {
-  return ((obj_type == AdbObjectTypeEndpoint) ||
-          (obj_type == AdbObjectTypeIo));
-}
-
-bool AdbEndpointObject::GetEndpointInformation(AdbEndpointInformation* info) {
-  if (!IsOpened() || !IsUsbOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  // Send IOCTL
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_handle(),
-                             ADB_IOCTL_GET_ENDPOINT_INFORMATION,
-                             NULL, 0,
-                             info, sizeof(AdbEndpointInformation),
-                             &ret_bytes,
-                             NULL);
-  ATLASSERT(!ret || (sizeof(AdbEndpointInformation) == ret_bytes));
-
-  return ret ? true : false;
-}
diff --git a/host/windows/usb/api/adb_endpoint_object.h b/host/windows/usb/api/adb_endpoint_object.h
deleted file mode 100644
index eda8ffa..0000000
--- a/host/windows/usb/api/adb_endpoint_object.h
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_ENDPOINT_OBJECT_H__
-#define ANDROID_USB_API_ADB_ENDPOINT_OBJECT_H__
-/** \file
-  This file consists of declaration of class AdbIOObject that encapsulates a
-  handle opened to an endpoint on our device.
-*/
-
-#include "adb_io_object.h"
-
-/** Class AdbEndpointObject encapsulates a handle opened to an endpoint on
-  our device.
-*/
-class AdbEndpointObject : public AdbIOObject {
- public:
-  /** \brief Constructs the object
-    
-    @param interface[in] Parent interface for this object. Interface will be
-           referenced in this object's constructur and released in the
-           destructor.
-    @param obj_type[in] Object type from AdbObjectType enum
-  */
-  AdbEndpointObject(AdbInterfaceObject* parent_interf);
-
- protected:
-  /** \brief Destructs the object.
-
-    parent_interface_ will be dereferenced here.
-    We hide destructor in order to prevent ourseves from accidentaly allocating
-    instances on the stack. If such attemp occur, compiler will error.
-  */
-  virtual ~AdbEndpointObject();
-
- public:
-  /** \brief Gets information about this endpoint.
-
-    @param info[out] Upon successful completion will have endpoint information.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetEndpointInformation(AdbEndpointInformation* info);
-
-  /** \brief Checks if this object is of the given type
-
-    @param obj_type[in] One of the AdbObjectType types to check
-    @return 'true' is this object type matches obj_type and 'false' otherwise.
-  */
-  virtual bool IsObjectOfType(AdbObjectType obj_type) const;
-
-  // This is a helper for extracting object from the AdbObjectHandleMap
-  static AdbObjectType Type() {
-    return AdbObjectTypeEndpoint;
-  }
-};
-
-#endif  // ANDROID_USB_API_ADB_ENDPOINT_OBJECT_H__
diff --git a/host/windows/usb/api/adb_helper_routines.cpp b/host/windows/usb/api/adb_helper_routines.cpp
deleted file mode 100644
index f2cd938..0000000
--- a/host/windows/usb/api/adb_helper_routines.cpp
+++ /dev/null
@@ -1,248 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of helper routines used
-  in the API.
-*/
-
-#include "stdafx.h"
-#include "adb_api.h"
-#include "adb_helper_routines.h"
-#include "adb_interface_enum.h"
-
-bool GetSDKComplientParam(AdbOpenAccessType access_type,
-                          AdbOpenSharingMode sharing_mode,
-                          ULONG* desired_access,
-                          ULONG* desired_sharing) {
-  if (NULL != desired_access) {
-    switch (access_type) {
-      case AdbOpenAccessTypeReadWrite:
-        *desired_access = GENERIC_READ | GENERIC_WRITE;
-        break;
-
-      case AdbOpenAccessTypeRead:
-        *desired_access = GENERIC_READ;
-        break;
-
-      case AdbOpenAccessTypeWrite:
-        *desired_access = GENERIC_WRITE;
-        break;
-
-      case AdbOpenAccessTypeQueryInfo:
-        *desired_access = FILE_READ_ATTRIBUTES | FILE_READ_EA;
-        break;
-
-      default:
-        AtlTrace("\n!!!!! ADB API -> GetSDKComplientParam %u is unknown access type",
-                 access_type);
-        SetLastError(ERROR_INVALID_ACCESS);
-        return false;
-    }
-  }
-
-  if (NULL != desired_sharing) {
-    switch (sharing_mode) {
-      case AdbOpenSharingModeReadWrite:
-        *desired_sharing = FILE_SHARE_READ | FILE_SHARE_WRITE;
-        break;
-
-      case AdbOpenSharingModeRead:
-        *desired_sharing = FILE_SHARE_READ;
-        break;
-
-      case AdbOpenSharingModeWrite:
-        *desired_sharing = FILE_SHARE_WRITE;
-        break;
-
-      case AdbOpenSharingModeExclusive:
-        *desired_sharing = 0;
-        break;
-
-      default:
-        AtlTrace("\n!!!!! ADB API -> GetSDKComplientParam %u is unknown share mode",
-                 sharing_mode);
-        SetLastError(ERROR_INVALID_PARAMETER);
-        return false;
-    }
-  }
-
-  return true;
-}
-
-bool EnumerateDeviceInterfaces(HDEVINFO hardware_dev_info,
-                               GUID class_id,
-                               bool exclude_removed,
-                               bool active_only,
-                               AdbEnumInterfaceArray* interfaces) {
-  AdbEnumInterfaceArray tmp;
-  bool ret = false;
-
-  // Enumerate interfaces on this device
-  for (ULONG index = 0; ; index++) {
-    SP_DEVICE_INTERFACE_DATA interface_data;
-    interface_data.cbSize = sizeof(SP_DEVICE_INTERFACE_DATA);
-
-    // SetupDiEnumDeviceInterfaces() returns information about device
-    // interfaces exposed by one or more devices defined by our interface
-    // class. Each call returns information about one interface. The routine
-    // can be called repeatedly to get information about several interfaces
-    // exposed by one or more devices.
-    if (SetupDiEnumDeviceInterfaces(hardware_dev_info,
-                                    0, 
-                                    &class_id,
-                                    index,
-                                    &interface_data)) {
-      // Satisfy "exclude removed" and "active only" filters.
-      if ((!exclude_removed || (0 == (interface_data.Flags & SPINT_REMOVED))) &&
-          (!active_only || (interface_data.Flags & SPINT_ACTIVE))) {
-        std::wstring dev_name;
-
-        if (GetUsbDeviceName(hardware_dev_info, &interface_data, &dev_name)) {
-          try {
-            // Add new entry to the array
-            tmp.push_back(AdbInstanceEnumEntry(dev_name.c_str(),
-                                               interface_data.InterfaceClassGuid,
-                                               interface_data.Flags));
-          } catch (... ) {
-            SetLastError(ERROR_OUTOFMEMORY);
-            break;
-          }
-        } else {
-          // Something went wrong in getting device name
-          break;
-        }
-      }
-    } else {
-      if (ERROR_NO_MORE_ITEMS == GetLastError()) {
-        // There are no more items in the list. Enum is completed.
-        ret = true;
-        break;
-      } else {
-        // Something went wrong in SDK enum
-        break;
-      }
-    }
-  }
-
-  // On success, swap temp array with the returning one
-  if (ret)
-    interfaces->swap(tmp);
-
-  return ret;
-}
-
-bool EnumerateDeviceInterfaces(GUID class_id,
-                               ULONG flags,
-                               bool exclude_removed,
-                               bool active_only,
-                               AdbEnumInterfaceArray* interfaces) {
-  // Open a handle to the plug and play dev node.
-  // SetupDiGetClassDevs() returns a device information set that
-  // contains info on all installed devices of a specified class.
-  HDEVINFO hardware_dev_info =
-    SetupDiGetClassDevs(&class_id, NULL, NULL, flags);
-
-  bool ret = false;
-
-  if (INVALID_HANDLE_VALUE != hardware_dev_info) {
-    // Do the enum
-    ret = EnumerateDeviceInterfaces(hardware_dev_info,
-                                    class_id,
-                                    exclude_removed,
-                                    active_only,
-                                    interfaces);
-
-    // Preserve last error accross hardware_dev_info destruction
-    ULONG error_to_report = ret ? NO_ERROR : GetLastError();
-
-    SetupDiDestroyDeviceInfoList(hardware_dev_info);
-
-    if (NO_ERROR != error_to_report)
-      SetLastError(error_to_report);
-  }
-
-  return ret;
-}
-
-bool GetUsbDeviceDetails(
-    HDEVINFO hardware_dev_info,
-    PSP_DEVICE_INTERFACE_DATA dev_info_data,
-    PSP_DEVICE_INTERFACE_DETAIL_DATA* dev_info_detail_data) {
-  ULONG required_len = 0;
-
-  // First query for the structure size. At this point we expect this call
-  // to fail with ERROR_INSUFFICIENT_BUFFER error code.
-  if (SetupDiGetDeviceInterfaceDetail(hardware_dev_info,
-                                      dev_info_data,
-                                      NULL,
-                                      0,
-                                      &required_len,
-                                      NULL)) {
-    return false;
-  }
-
-  if (ERROR_INSUFFICIENT_BUFFER != GetLastError())
-    return false;
-
-  // Allocate buffer for the structure
-  PSP_DEVICE_INTERFACE_DETAIL_DATA buffer =
-    reinterpret_cast<PSP_DEVICE_INTERFACE_DETAIL_DATA>(malloc(required_len));
-
-  if (NULL == buffer) {
-    SetLastError(ERROR_OUTOFMEMORY);
-    return false;
-  }
-
-  buffer->cbSize = sizeof(SP_DEVICE_INTERFACE_DETAIL_DATA);
-
-  // Retrieve the information from Plug and Play.
-  if (SetupDiGetDeviceInterfaceDetail(hardware_dev_info,
-                                      dev_info_data,
-                                      buffer,
-                                      required_len,
-                                      &required_len,
-                                      NULL)) {
-    *dev_info_detail_data = buffer;
-    return true;
-  } else {
-    // Free the buffer if this call failed
-    free(buffer);
-
-    return false;
-  }
-}
-
-bool GetUsbDeviceName(HDEVINFO hardware_dev_info,
-                      PSP_DEVICE_INTERFACE_DATA dev_info_data,
-                      std::wstring* name) {
-  PSP_DEVICE_INTERFACE_DETAIL_DATA func_class_dev_data = NULL;
-  if (!GetUsbDeviceDetails(hardware_dev_info,
-                           dev_info_data,
-                           &func_class_dev_data)) {
-    return false;
-  }
-
-  try {
-    *name = func_class_dev_data->DevicePath;
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-  }
-
-  free(func_class_dev_data);
-
-  return !name->empty();
-}
diff --git a/host/windows/usb/api/adb_helper_routines.h b/host/windows/usb/api/adb_helper_routines.h
deleted file mode 100644
index 18709f0..0000000
--- a/host/windows/usb/api/adb_helper_routines.h
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_HELPER_ROUTINES_H__
-#define ANDROID_USB_API_ADB_HELPER_ROUTINES_H__
-/** \file
-  This file consists of declarations of helper routines used
-  in the API.
-*/
-
-#include "adb_api_private_defines.h"
-
-/** \brief Converts access type and share mode from our enum into
-  SDK - complient values.
-
-  @param access_type[in] Enumerated access type
-  @param sharing_mode[in] Enumerated share mode
-  @param desired_access[out] Will receive SDK - complient desired access
-         flags. This parameter can be NULL.
-  @param desired_sharing[out] Will receive SDK - complient share mode.
-         This parameter can be NULL.
-  @return True on success, false on failure, in which case GetLastError()
-          provides extended information about the error that occurred.
-*/
-bool GetSDKComplientParam(AdbOpenAccessType access_type,
-                          AdbOpenSharingMode sharing_mode,
-                          ULONG* desired_access,
-                          ULONG* desired_sharing);
-
-/** \brief
-  Given the hardware device information enumerates interfaces for this device
-
-  @param hardware_dev_info[in] A handle to hardware device information obtained
-         from PnP manager via SetupDiGetClassDevs()
-  @param class_id[in] Device class ID how it is specified by our USB driver
-  @param exclude_removed[in] If true interfaces with SPINT_REMOVED flag set
-         will be not included in the enumeration.
-  @param active_only[in] If 'true' only active interfaces (with flag
-         SPINT_ACTIVE set) will be included in the enumeration.
-  @param interfaces[out] Upon successfull completion will consist of array of
-         all interfaces found for this device (matching all filters).
-  @return True on success, false on failure, in which case GetLastError()
-          provides extended information about the error that occurred.
-*/
-bool EnumerateDeviceInterfaces(HDEVINFO hardware_dev_info,
-                               GUID class_id,
-                               bool exclude_removed,
-                               bool active_only,
-                               AdbEnumInterfaceArray* interfaces);
-
-/** \brief Enumerates all interfaces for our device class
-
-  This routine uses SetupDiGetClassDevs to get our device info and calls
-  EnumerateDeviceInterfaces to perform the enumeration.
-  @param class_id[in] Device class ID how it is specified by our USB driver
-  @param flags[in] Flags to pass to SetupDiGetClassDevs to filter devices. See
-         SetupDiGetClassDevs() in SDK for more info on these flags.
-  @param exclude_removed[in] If true interfaces with SPINT_REMOVED flag set
-         will be not included in the enumeration.
-  @param active_only[in] If 'true' only active interfaces (with flag
-         SPINT_ACTIVE set) will be included in the enumeration.
-  @param interfaces[out] Upon successfull completion will consist of array of
-         all interfaces found for this device (matching all filters).
-  @return True on success, false on failure, in which case GetLastError()
-          provides extended information about the error that occurred.
-*/
-bool EnumerateDeviceInterfaces(GUID class_id,
-                               ULONG flags,
-                               bool exclude_removed,
-                               bool active_only,
-                               AdbEnumInterfaceArray* interfaces);
-
-/** \brief Given the hardware device information and data gets data details
-
-  Given the hardware_dev_info, representing a handle to the plug and
-  play information, and dev_info_data, representing a specific usb device,
-  gets detailed data about the device (interface).
-  @param hardware_dev_info[in] A handle to hardware device information obtained
-         from PnP manager via SetupDiGetClassDevs()
-  @param dev_info_data[in] Device information data obtained via call to
-         SetupDiEnumDeviceInterfaces()
-  @param dev_info_detail_data[out] Upon successfull completion will consist of
-         the detailed data about device interface. This routine always
-         allocates memory for the output structure so content of this pointer
-         doesn't matter and will be overwritten by this routine. The caller
-         of this method is responsible for freeing allocated data using free()
-         routine.
-  @return True on success, false on failure, in which case GetLastError()
-          provides extended information about the error that occurred.
-*/
-bool GetUsbDeviceDetails(HDEVINFO hardware_dev_info,
-                         PSP_DEVICE_INTERFACE_DATA dev_info_data,
-                         PSP_DEVICE_INTERFACE_DETAIL_DATA* dev_info_detail_data);
-
-/** \brief Given the hardware device information and data gets device name.
-
-  Given the hardware_dev_info, representing a handle to the plug and
-  play information, and dev_info_data, representing a specific usb device,
-  gets device name. This routine uses GetUsbDeviceDetails to extract device
-  name.
-  @param hardware_dev_info[in] A handle to hardware device information obtained
-         from PnP manager via SetupDiGetClassDevs()
-  @param dev_info_data[in] Device information data obtained via call to
-         SetupDiEnumDeviceInterfaces()
-  @param name[out] Upon successfull completion will have name for the device.
-  @return True on success, false on failure, in which case GetLastError()
-          provides extended information about the error that occurred.
-*/
-bool GetUsbDeviceName(HDEVINFO hardware_dev_info,
-                      PSP_DEVICE_INTERFACE_DATA dev_info_data,
-                      std::wstring* name);
-
-#endif  // ANDROID_USB_API_ADB_HELPER_ROUTINES_H__
diff --git a/host/windows/usb/api/adb_interface.cpp b/host/windows/usb/api/adb_interface.cpp
deleted file mode 100644
index 9369e13..0000000
--- a/host/windows/usb/api/adb_interface.cpp
+++ /dev/null
@@ -1,344 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AdbInterfaceObject that
-  encapsulates an interface on our USB device.
-*/
-
-#include "stdafx.h"
-#include "adb_interface.h"
-#include "adb_endpoint_object.h"
-
-AdbInterfaceObject::AdbInterfaceObject(const wchar_t* interf_name)
-    : AdbObjectHandle(AdbObjectTypeInterface),
-      interface_name_(interf_name) {
-  ATLASSERT(NULL != interf_name);
-}
-
-AdbInterfaceObject::~AdbInterfaceObject() {
-}
-
-ADBAPIHANDLE AdbInterfaceObject::CreateHandle() {
-  // Open USB device for this intefface
-  HANDLE usb_device_handle = CreateFile(interface_name().c_str(),
-                                        GENERIC_READ | GENERIC_WRITE,
-                                        FILE_SHARE_READ | FILE_SHARE_WRITE,
-                                        NULL,
-                                        OPEN_EXISTING,
-                                        0,
-                                        NULL);
-  if (INVALID_HANDLE_VALUE == usb_device_handle)
-    return NULL;
-
-  // Now, we ensured that our usb device / interface is up and running.
-  // Lets collect device, interface and pipe information
-  bool ok = true;
-  if (!CacheUsbDeviceDescriptor(usb_device_handle) ||
-      !CacheUsbConfigurationDescriptor(usb_device_handle) ||
-      !CacheUsbInterfaceDescriptor(usb_device_handle)) {
-    ok = false;
-  }
-
-  // Preserve error accross handle close
-  ULONG error = ok ? NO_ERROR : GetLastError();
-
-  ::CloseHandle(usb_device_handle);
-
-  if (NO_ERROR != error)
-    SetLastError(error);
-
-  if (!ok)
-    return false;
-
-  return AdbObjectHandle::CreateHandle();
-}
-
-bool AdbInterfaceObject::GetInterfaceName(void* buffer,
-                                          unsigned long* buffer_char_size,
-                                          bool ansi) {
-  // Lets see if buffer is big enough
-  ULONG name_len = static_cast<ULONG>(interface_name_.length() + 1);
-  if ((NULL == buffer) || (*buffer_char_size < name_len)) {
-    *buffer_char_size = name_len;
-    SetLastError(ERROR_INSUFFICIENT_BUFFER);
-    return false;
-  }
-
-  if (!ansi) {
-    // If user asked for wide char name just return it
-    wcscpy(reinterpret_cast<wchar_t*>(buffer), interface_name().c_str());
-    return true;
-  }
-
-  // We need to convert name from wide char to ansi string
-  int res = WideCharToMultiByte(CP_ACP,
-                                0,
-                                interface_name().c_str(),
-                                static_cast<int>(name_len),
-                                reinterpret_cast<PSTR>(buffer),
-                                static_cast<int>(*buffer_char_size),
-                                NULL,
-                                NULL);
-  return (res != 0);
-}
-
-bool AdbInterfaceObject::GetSerialNumber(void* buffer,
-                                         unsigned long* buffer_char_size,
-                                         bool ansi) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  // Open USB device for this intefface
-  HANDLE usb_device_handle = CreateFile(interface_name().c_str(),
-                                        GENERIC_READ,
-                                        FILE_SHARE_READ | FILE_SHARE_WRITE,
-                                        NULL,
-                                        OPEN_EXISTING,
-                                        0,
-                                        NULL);
-  if (INVALID_HANDLE_VALUE == usb_device_handle)
-    return NULL;
-
-  WCHAR serial_number[512];
-
-  // Send IOCTL
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_device_handle,
-                             ADB_IOCTL_GET_SERIAL_NUMBER,
-                             NULL, 0,
-                             serial_number, sizeof(serial_number),
-                             &ret_bytes,
-                             NULL);
-
-  // Preserve error accross CloseHandle
-  ULONG error = ret ? NO_ERROR : GetLastError();
-
-  ::CloseHandle(usb_device_handle);
-
-  if (NO_ERROR != error) {
-    SetLastError(error);
-    return false;
-  }
-
-  unsigned long str_len =
-    static_cast<unsigned long>(wcslen(serial_number) + 1);
-
-  if ((NULL == buffer) || (*buffer_char_size < str_len)) {
-    *buffer_char_size = str_len;
-    SetLastError(ERROR_INSUFFICIENT_BUFFER);
-    return false;
-  }
-
-  if (!ansi) {
-    // If user asked for wide char name just return it
-    wcscpy(reinterpret_cast<wchar_t*>(buffer), serial_number);
-    return true;
-  }
-
-  // We need to convert name from wide char to ansi string
-  int res = WideCharToMultiByte(CP_ACP,
-                                0,
-                                serial_number,
-                                static_cast<int>(str_len),
-                                reinterpret_cast<PSTR>(buffer),
-                                static_cast<int>(*buffer_char_size),
-                                NULL,
-                                NULL);
-  return (res != 0);
-}
-
-bool AdbInterfaceObject::GetUsbDeviceDescriptor(USB_DEVICE_DESCRIPTOR* desc) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  CopyMemory(desc, usb_device_descriptor(), sizeof(USB_DEVICE_DESCRIPTOR));
-
-  return true;
-}
-
-bool AdbInterfaceObject::GetUsbConfigurationDescriptor(
-    USB_CONFIGURATION_DESCRIPTOR* desc) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  CopyMemory(desc, usb_config_descriptor(),
-             sizeof(USB_CONFIGURATION_DESCRIPTOR));
-
-  return true;
-}
-
-bool AdbInterfaceObject::GetUsbInterfaceDescriptor(
-    USB_INTERFACE_DESCRIPTOR* desc) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  CopyMemory(desc, usb_interface_descriptor(), sizeof(USB_INTERFACE_DESCRIPTOR));
-
-  return true;
-}
-
-bool AdbInterfaceObject::GetEndpointInformation(UCHAR endpoint_index,
-                                                AdbEndpointInformation* info) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  // Open USB device for this intefface
-  HANDLE usb_device_handle = CreateFile(interface_name().c_str(),
-                                        GENERIC_READ,
-                                        FILE_SHARE_READ | FILE_SHARE_WRITE,
-                                        NULL,
-                                        OPEN_EXISTING,
-                                        0,
-                                        NULL);
-  if (INVALID_HANDLE_VALUE == usb_device_handle)
-    return NULL;
-
-  // Init ICTL param
-  AdbQueryEndpointInformation param;
-  param.endpoint_index = endpoint_index;
-
-  // Send IOCTL
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_device_handle,
-                             ADB_IOCTL_GET_ENDPOINT_INFORMATION,
-                             &param, sizeof(param),
-                             info, sizeof(AdbEndpointInformation),
-                             &ret_bytes,
-                             NULL);
-  ATLASSERT(!ret || (sizeof(AdbEndpointInformation) == ret_bytes));
-
-  // Preserve error accross CloseHandle
-  ULONG error = ret ? NO_ERROR : GetLastError();
-
-  ::CloseHandle(usb_device_handle);
-
-  if (NO_ERROR != error)
-    SetLastError(error);
-
-  return ret ? true : false;
-}
-
-ADBAPIHANDLE AdbInterfaceObject::OpenEndpoint(
-    UCHAR endpoint_index,
-    AdbOpenAccessType access_type,
-    AdbOpenSharingMode sharing_mode) {
-  // Convert index into name
-  std::wstring endpoint_name;
-
-  try {
-    if (ADB_QUERY_BULK_READ_ENDPOINT_INDEX == endpoint_index) {
-      endpoint_name = DEVICE_BULK_READ_PIPE_NAME;
-    } else if (ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX == endpoint_index) {
-      endpoint_name = DEVICE_BULK_WRITE_PIPE_NAME;
-    } else {
-      wchar_t fmt[265];
-      swprintf(fmt, L"%ws%u", DEVICE_PIPE_NAME_PREFIX, endpoint_index);
-      endpoint_name = fmt;
-    }
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-    return NULL;
-  }
-
-  return OpenEndpoint(endpoint_name.c_str(), access_type, sharing_mode);
-}
-
-ADBAPIHANDLE AdbInterfaceObject::OpenEndpoint(
-    const wchar_t* endpoint_name,
-    AdbOpenAccessType access_type,
-    AdbOpenSharingMode sharing_mode) {
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  AdbEndpointObject* adb_endpoint = NULL;
-  
-  try {
-    adb_endpoint = new AdbEndpointObject(this);
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-    return NULL;
-  }
-
-  // Build full path to the object
-  std::wstring endpoint_path = interface_name();
-  endpoint_path += L"\\";
-  endpoint_path += endpoint_name;
-
-  ADBAPIHANDLE ret = adb_endpoint->CreateHandle(endpoint_path.c_str(),
-                                                access_type,
-                                                sharing_mode);
-
-  adb_endpoint->Release();
-
-  return ret;
-}
-
-bool AdbInterfaceObject::CacheUsbDeviceDescriptor(HANDLE usb_device_handle) {
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_device_handle,
-                             ADB_IOCTL_GET_USB_DEVICE_DESCRIPTOR,
-                             NULL, 0,
-                             &usb_device_descriptor_,
-                             sizeof(usb_device_descriptor_),
-                             &ret_bytes,
-                             NULL);
-  ATLASSERT(!ret || (sizeof(USB_DEVICE_DESCRIPTOR) == ret_bytes));
-
-  return ret ? true : false;
-}
-
-bool AdbInterfaceObject::CacheUsbConfigurationDescriptor(
-    HANDLE usb_device_handle) {
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_device_handle,
-                             ADB_IOCTL_GET_USB_CONFIGURATION_DESCRIPTOR,
-                             NULL, 0,
-                             &usb_config_descriptor_,
-                             sizeof(usb_config_descriptor_),
-                             &ret_bytes,
-                             NULL);
-  ATLASSERT(!ret || (sizeof(USB_CONFIGURATION_DESCRIPTOR) == ret_bytes));
-
-  return ret ? true : false;
-}
-
-bool AdbInterfaceObject::CacheUsbInterfaceDescriptor(
-    HANDLE usb_device_handle) {
-  DWORD ret_bytes = 0;
-  BOOL ret = DeviceIoControl(usb_device_handle,
-                             ADB_IOCTL_GET_USB_INTERFACE_DESCRIPTOR,
-                             NULL, 0,
-                             &usb_interface_descriptor_,
-                             sizeof(usb_interface_descriptor_),
-                             &ret_bytes,
-                             NULL);
-  ATLASSERT(!ret || (sizeof(USB_INTERFACE_DESCRIPTOR) == ret_bytes));
-
-  return ret ? true : false;
-}
diff --git a/host/windows/usb/api/adb_interface.h b/host/windows/usb/api/adb_interface.h
deleted file mode 100644
index cead454..0000000
--- a/host/windows/usb/api/adb_interface.h
+++ /dev/null
@@ -1,244 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_INTERFACE_H__
-#define ANDROID_USB_API_ADB_INTERFACE_H__
-/** \file
-  This file consists of declaration of class AdbInterfaceObject that
-  encapsulates an interface on our USB device.
-*/
-
-#include "adb_object_handle.h"
-
-/** Class AdbInterfaceObject encapsulates an interface on our USB device.
-*/
-class AdbInterfaceObject : public AdbObjectHandle {
- public:
-  /** \brief Constructs the object
-    
-    @param interf_name[in] Name of the interface
-  */
-  explicit AdbInterfaceObject(const wchar_t* interf_name);
-
- protected:
-  /** \brief Destructs the object.
-
-   We hide destructor in order to prevent ourseves from accidentaly allocating
-   instances on the stack. If such attemp occur, compiler will error.
-  */
-  virtual ~AdbInterfaceObject();
-
- public:
-  /** \brief Creates handle to this object
-
-    In this call a handle for this object is generated and object is added
-    to the AdbObjectHandleMap. We override this method in order to verify that
-    interface indeed exists and gather device, interface and pipe properties.
-    If this step succeeds then and only then AdbObjectHandle::CreateHandle
-    will be called.
-    @return A handle to this object on success or NULL on an error.
-            If NULL is returned GetLastError() provides extended error
-            information. ERROR_GEN_FAILURE is set if an attempt was
-            made to create already opened object.
-  */
-  virtual ADBAPIHANDLE CreateHandle();
-
-  /** \brief Gets interface device name.
-
-    @param buffer[out] Buffer for the name. Can be NULL in which case
-           buffer_char_size will contain number of characters required to fit
-           the name.
-    @param buffer_char_size[in/out] On the way in supplies size (in characters)
-           of the buffer. On the way out if method failed and GetLastError
-           reports ERROR_INSUFFICIENT_BUFFER will contain number of characters
-           required to fit the name.
-    @param ansi[in] If true the name will be returned as single character
-           string. Otherwise name will be returned as wide character string.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetInterfaceName(void* buffer,
-                        unsigned long* buffer_char_size,
-                        bool ansi);
-
-  /** \brief Gets serial number for interface's device.
-
-    @param buffer[out] Buffer for the serail number string. Can be NULL in
-           which case buffer_char_size will contain number of characters
-           required for the string.
-    @param buffer_char_size[in/out] On the way in supplies size (in characters)
-           of the buffer. On the way out, if method failed and GetLastError
-           reports ERROR_INSUFFICIENT_BUFFER, will contain number of characters
-           required for the name.
-    @param ansi[in] If 'true' the name will be returned as single character
-           string. Otherwise name will be returned as wide character string.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetSerialNumber(void* buffer,
-                       unsigned long* buffer_char_size,
-                       bool ansi);
-
-  /** \brief Gets device descriptor for the USB device associated with
-    this interface.
-
-    @param desc[out] Upon successful completion will have usb device
-           descriptor.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetUsbDeviceDescriptor(USB_DEVICE_DESCRIPTOR* desc);
-
-  /** \brief Gets descriptor for the selected USB device configuration.
-
-    @param desc[out] Upon successful completion will have usb device
-           configuration descriptor.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetUsbConfigurationDescriptor(USB_CONFIGURATION_DESCRIPTOR* desc);
-
-  /** \brief Gets descriptor for this interface.
-
-    @param desc[out] Upon successful completion will have interface
-           descriptor.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetUsbInterfaceDescriptor(USB_INTERFACE_DESCRIPTOR* desc);
-
-  /** \brief Gets information about an endpoint on this interface.
-
-    @param endpoint_index[in] Zero-based endpoint index. There are two
-           shortcuts for this parameter: ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX
-           and ADB_QUERY_BULK_READ_ENDPOINT_INDEX that provide infor about
-           (default?) bulk write and read endpoints respectively.
-    @param info[out] Upon successful completion will have endpoint information.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool GetEndpointInformation(UCHAR endpoint_index, AdbEndpointInformation* info);
-
-  /** \brief Opens an endpoint on this interface.
-
-    @param endpoint_index[in] Zero-based endpoint index. There are two
-           shortcuts for this parameter: ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX
-           and ADB_QUERY_BULK_READ_ENDPOINT_INDEX that provide infor about
-           (default?) bulk write and read endpoints respectively.
-    @param access_type[in] Desired access type. In the current implementation
-           this parameter has no effect on the way endpoint is opened. It's
-           always read / write access.
-    @param sharing_mode[in] Desired share mode. In the current implementation
-           this parameter has no effect on the way endpoint is opened. It's
-           always shared for read / write.
-    @return Handle to the opened endpoint object or NULL on failure.
-            If NULL is returned GetLastError() provides extended information
-            about the error that occurred.
-  */
-  ADBAPIHANDLE OpenEndpoint(UCHAR endpoint_index,
-                            AdbOpenAccessType access_type,
-                            AdbOpenSharingMode sharing_mode);
-
-  /** \brief Opens an endpoint on this interface.
-
-    @param endpoint_name[in] Endpoint file name.
-    @param access_type[in] Desired access type. In the current implementation
-           this parameter has no effect on the way endpoint is opened. It's
-           always read / write access.
-    @param sharing_mode[in] Desired share mode. In the current implementation
-           this parameter has no effect on the way endpoint is opened. It's
-           always shared for read / write.
-    @return Handle to the opened endpoint object or NULL on failure.
-            If NULL is returned GetLastError() provides extended information
-            about the error that occurred.
-  */
-  ADBAPIHANDLE OpenEndpoint(const wchar_t* endpoint_name,
-                            AdbOpenAccessType access_type,
-                            AdbOpenSharingMode sharing_mode);
-
- private:
-  /** \brief Caches device descriptor for the USB device associated with
-    this interface.
-
-    This method is called from CreateHandle method to cache some interface
-    information.
-    @param usb_device_handle[in] Handle to USB device.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool CacheUsbDeviceDescriptor(HANDLE usb_device_handle);
-
-  /** \brief Caches descriptor for the selected USB device configuration.
-
-    This method is called from CreateHandle method to cache some interface
-    information.
-    @param usb_device_handle[in] Handle to USB device.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool CacheUsbConfigurationDescriptor(HANDLE usb_device_handle);
-
-  /** \brief Caches descriptor for this interface.
-
-    This method is called from CreateHandle method to cache some interface
-    information.
-    @param usb_device_handle[in] Handle to USB device.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  bool CacheUsbInterfaceDescriptor(HANDLE usb_device_handle);
-
- public:
-  /// Gets name of the USB interface (device name) for this object
-  const std::wstring& interface_name() const {
-    return interface_name_;
-  }
-
-  // This is a helper for extracting object from the AdbObjectHandleMap
-  static AdbObjectType Type() {
-    return AdbObjectTypeInterface;
-  }
-
-  /// Gets cached usb device descriptor
-  const USB_DEVICE_DESCRIPTOR* usb_device_descriptor() const {
-    return &usb_device_descriptor_;
-  }
-
-  /// Gets cached usb configuration descriptor
-  const USB_CONFIGURATION_DESCRIPTOR* usb_config_descriptor() const {
-    return &usb_config_descriptor_;
-  }
-
-  /// Gets cached usb interface descriptor
-  const USB_INTERFACE_DESCRIPTOR* usb_interface_descriptor() const {
-    return &usb_interface_descriptor_;
-  }
-
-private:
-  /// Name of the USB interface (device name) for this object
-  std::wstring                  interface_name_;
-
-  /// Cached usb device descriptor
-  USB_DEVICE_DESCRIPTOR         usb_device_descriptor_;
-
-  /// Cached usb configuration descriptor
-  USB_CONFIGURATION_DESCRIPTOR  usb_config_descriptor_;
-
-  /// Cached usb interface descriptor
-  USB_INTERFACE_DESCRIPTOR      usb_interface_descriptor_;
-};
-
-#endif  // ANDROID_USB_API_ADB_INTERFACE_H__
diff --git a/host/windows/usb/api/adb_interface_enum.cpp b/host/windows/usb/api/adb_interface_enum.cpp
deleted file mode 100644
index 6e2808c..0000000
--- a/host/windows/usb/api/adb_interface_enum.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of AdbInterfaceEnumObject class that
-  encapsulates enumerator of USB interfaces available through this API.
-*/
-
-#include "stdafx.h"
-#include "adb_api.h"
-#include "adb_interface_enum.h"
-#include "adb_helper_routines.h"
-
-AdbInterfaceEnumObject::AdbInterfaceEnumObject()
-    : AdbObjectHandle(AdbObjectTypeInterfaceEnumerator) {
-  current_interface_ = interfaces_.begin();
-}
-
-AdbInterfaceEnumObject::~AdbInterfaceEnumObject() {
-}
-
-bool AdbInterfaceEnumObject::InitializeEnum(GUID class_id,
-                                            bool exclude_not_present,
-                                            bool exclude_removed,
-                                            bool active_only) {
-  // Calc flags for SetupDiGetClassDevs
-  DWORD flags = DIGCF_DEVICEINTERFACE;
-  if (exclude_not_present)
-    flags |= DIGCF_PRESENT;
-
-  // Do the enum
-  bool ret = EnumerateDeviceInterfaces(class_id,
-                                       flags,
-                                       exclude_removed,
-                                       active_only,
-                                       &interfaces_);
-
-  // If enum was successfull set current enum pointer
-  // to the beginning of the array
-  if (ret)
-    current_interface_ = interfaces_.begin();
-
-  return ret;
-}
-
-bool AdbInterfaceEnumObject::Next(AdbInterfaceInfo* info, ULONG* size) {
-  // Make sure that it's opened
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  ATLASSERT(NULL != size);
-  if (NULL == size) {
-    SetLastError(ERROR_INVALID_PARAMETER);
-    return false;
-  }
-
-  // Lets see if enum is over
-  if (interfaces_.end() == current_interface_) {
-    SetLastError(ERROR_NO_MORE_ITEMS);
-    return false;
-  }
-
-  AdbInstanceEnumEntry& entry = *current_interface_;
-
-  // Big enough?
-  if ((NULL == info) || (*size < entry.GetFlatSize())) {
-    *size = entry.GetFlatSize();
-    SetLastError(ERROR_INSUFFICIENT_BUFFER);
-    return false;
-  }
-
-  // All checks passed
-  entry.Save(info);
-  current_interface_++;
-  return true;
-}
-
-bool AdbInterfaceEnumObject::Reset() {
-  // Make sure that it's opened
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  current_interface_ = interfaces_.begin();
-
-  return true;
-}
diff --git a/host/windows/usb/api/adb_interface_enum.h b/host/windows/usb/api/adb_interface_enum.h
deleted file mode 100644
index f46b31b..0000000
--- a/host/windows/usb/api/adb_interface_enum.h
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_INTERFACE_ENUM_H__
-#define ANDROID_USB_API_ADB_INTERFACE_ENUM_H__
-/** \file
-  This file consists of declaration of AdbInterfaceEnumObject class that
-  encapsulates enumerator of USB interfaces available through this API.
-*/
-
-#include "adb_object_handle.h"
-
-/** Class AdbInterfaceEnumObject encapsulates enumerator of USB
-  interfaces available through this API.
-*/
-class AdbInterfaceEnumObject : public AdbObjectHandle {
- public:
-  /** \brief Constructs the object.
-  */
-  AdbInterfaceEnumObject();
-
- protected:
-  /** \brief Destructs the object.
-
-   We hide destructor in order to prevent ourseves from accidentaly allocating
-   instances on the stack. If such attemp occur, compiler will error.
-  */
-  virtual ~AdbInterfaceEnumObject();
-
- public:
-  /** \brief Enumerates all interfaces for our device class
-
-    This routine uses SetupDiGetClassDevs to get our device info and calls
-    EnumerateDeviceInterfaces to perform the enumeration.
-    @param class_id[in] Device class ID that is specified by our USB driver
-    @param exclude_not_present[in] If set include only those devices that are
-           currently present.
-    @param exclude_removed[in] If true interfaces with SPINT_REMOVED flag set
-           will be not included in the enumeration.
-    @param active_only[in] If 'true' only active interfaces (with flag
-           SPINT_ACTIVE set) will be included in the enumeration.
-    @return True on success, false on failure, in which case GetLastError()
-            provides extended information about the error that occurred.
-  */
-  bool InitializeEnum(GUID class_id,
-                      bool exclude_not_present,
-                      bool exclude_removed,
-                      bool active_only);
-
-  /** \brief Gets next enumerated interface information
-
-    @param info[out] Upon successful completion will receive interface
-           information. Can be NULL. If it is NULL, upon return from this
-           method *size will have memory size required to fit this entry.
-    @param size[in,out]. On the way in provides size of the memory buffer
-           addressed by info param. On the way out (only if buffer is not
-           big enough) will provide memory size required to fit this entry.
-    @return true on success, false on error. If false is returned
-            GetLastError() provides extended information about the error that
-            occurred. ERROR_INSUFFICIENT_BUFFER indicates that buffer provided
-            in info param was not big enough and *size specifies memory size
-            required to fit this entry. ERROR_NO_MORE_ITEMS indicates that
-            enumeration is over and there are no more entries to return.
-  */
-  bool Next(AdbInterfaceInfo* info, ULONG* size);
-
-  /** \brief Makes enumerator to start from the beginning.
-
-    @return true on success, false on error. If false is returned
-            GetLastError() provides extended information about the error that
-            occurred.
-  */
-  bool Reset();
-
-  // This is a helper for extracting object from the AdbObjectHandleMap
-  static AdbObjectType Type() {
-    return AdbObjectTypeInterfaceEnumerator;
-  }
-
- protected:
-  /// Array of interfaces enumerated with this object
-  AdbEnumInterfaceArray           interfaces_;
-
-  /// Current enumerator
-  AdbEnumInterfaceArray::iterator current_interface_;
-};
-
-#endif  // ANDROID_USB_API_ADB_INTERFACE_ENUM_H__
diff --git a/host/windows/usb/api/adb_io_completion.cpp b/host/windows/usb/api/adb_io_completion.cpp
deleted file mode 100644
index 02519c9..0000000
--- a/host/windows/usb/api/adb_io_completion.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AdbIOCompletion that
-  encapsulates a wrapper around OVERLAPPED Win32 structure returned
-  from asynchronous I/O requests.
-*/
-
-#include "stdafx.h"
-#include "adb_io_completion.h"
-
-AdbIOCompletion::AdbIOCompletion(AdbIOObject* parent_io_obj,
-                                 bool is_write_ctl,
-                                 ULONG expected_trans_size,
-                                 HANDLE event_hndl)
-    : AdbObjectHandle(AdbObjectTypeIoCompletion),
-      transferred_bytes_(0),
-      expected_transfer_size_(expected_trans_size),
-      is_write_ioctl_(is_write_ctl),
-      parent_io_object_(parent_io_obj) {
-  ATLASSERT(NULL != parent_io_obj);
-  parent_io_obj->AddRef();
-  ZeroMemory(&overlapped_, sizeof(overlapped_));
-  overlapped_.hEvent = event_hndl;
-}
-
-AdbIOCompletion::~AdbIOCompletion() {
-  parent_io_object_->Release();
-}
-
-bool AdbIOCompletion::GetOvelappedIoResult(LPOVERLAPPED ovl_data,
-                                           ULONG* bytes_transferred,
-                                           bool wait) {
-  if (NULL != bytes_transferred)
-    *bytes_transferred = 0;
-
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  ULONG transfer;
-  bool ret = GetOverlappedResult(parent_io_object()->usb_handle(),
-                                 overlapped(),
-                                 &transfer,
-                                 wait) ? true :
-                                         false;
-
-  // TODO: This is bizzare but I've seen it happening
-  // that GetOverlappedResult with wait set to true returns "prematurely",
-  // with wrong transferred bytes value and GetLastError reporting
-  // ERROR_IO_PENDING. So, lets give it an up to a 20 ms loop!
-  ULONG error = GetLastError();
-
-  if (wait && ret && (0 == transfer) && (0 != expected_transfer_size_) &&
-      ((ERROR_IO_INCOMPLETE == error) || (ERROR_IO_PENDING == error))) {
-    for (int trying = 0; trying < 10; trying++) {
-      Sleep(2);
-      ret = GetOverlappedResult(parent_io_object()->usb_handle(),
-                                overlapped(),
-                                &transfer,
-                                wait) ? true :
-                                        false;
-      error = GetLastError();
-      if (!ret || (0 != transfer) ||
-          ((ERROR_IO_INCOMPLETE != error) && (ERROR_IO_PENDING != error))) {
-        break;
-      }
-    }
-  }
-
-  if (NULL != ovl_data)
-    CopyMemory(ovl_data, overlapped(), sizeof(OVERLAPPED));
-
-  if (NULL != bytes_transferred)
-    *bytes_transferred = is_write_ioctl() ? transferred_bytes_ : transfer;
-
-  return ret;
-}
-
-bool AdbIOCompletion::IsCompleted() {
-  SetLastError(NO_ERROR);
-  if (!IsOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return true;
-  }
-
-  return  HasOverlappedIoCompleted(overlapped()) ? true : false;
-}
diff --git a/host/windows/usb/api/adb_io_completion.h b/host/windows/usb/api/adb_io_completion.h
deleted file mode 100644
index d29f5e1..0000000
--- a/host/windows/usb/api/adb_io_completion.h
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_IO_COMPLETION_H__
-#define ANDROID_USB_API_ADB_IO_COMPLETION_H__
-/** \file
-  This file consists of declaration of class AdbIOCompletion that encapsulates
-  a wrapper around OVERLAPPED Win32 structure returned from asynchronous I/O
-  requests.
-*/
-
-#include "adb_io_object.h"
-
-/** Class AdbIOCompletion encapsulates encapsulates a wrapper around
-  OVERLAPPED Win32 structure returned from asynchronous I/O requests.
-  A handle to this object is returned to the caller of each successful
-  asynchronous I/O request. Just like all other handles this handle
-  must be closed after it's no longer needed.
-*/
-class AdbIOCompletion : public AdbObjectHandle {
- public:
-  /** \brief Constructs the object
-    
-    @param parent_io_obj[in] Parent I/O object that created this instance.
-           Parent object will be referenced in this object's constructur and
-           released in the destructor.
-    @param is_write_ctl[in] Flag indicating whether or not this completion
-           object is created for ADB_IOCTL_BULK_WRITE I/O.
-    @param event_hndl[in] Event handle that should be signaled when I/O
-           completes. Can be NULL. If it's not NULL this handle will be
-           used to initialize OVERLAPPED structure for this object.
-  */
-  AdbIOCompletion(AdbIOObject* parent_io_obj,
-                  bool is_write_ctl,
-                  ULONG expected_trans_size,
-                  HANDLE event_hndl);
-
- protected:
-  /** \brief Destructs the object.
-
-    parent_io_object_ will be dereferenced here.
-    We hide destructor in order to prevent ourseves from accidentaly allocating
-    instances on the stack. If such attemp occur, compiler will error.
-  */
-  virtual ~AdbIOCompletion();
-
- public:
-  /** \brief Gets overlapped I/O result
-
-    @param ovl_data[out] Buffer for the copy of this object's OVERLAPPED
-           structure. Can be NULL.
-    @param bytes_transferred[out] Pointer to a variable that receives the
-           number of bytes that were actually transferred by a read or write
-           operation. See SDK doc on GetOvelappedResult for more information.
-           Unlike regular GetOvelappedResult call this parameter can be NULL.
-    @param wait[in] If this parameter is 'true', the method does not return
-           until the operation has been completed. If this parameter is 'false'
-           and the operation is still pending, the method returns 'false' and
-           the GetLastError function returns ERROR_IO_INCOMPLETE.
-    @return 'true' if I/O has been completed or 'false' on failure or if request
-           is not yet completed. If 'false' is returned GetLastError() provides
-           extended error information. If GetLastError returns
-           ERROR_IO_INCOMPLETE it means that I/O is not yet completed.
-  */
-  virtual bool GetOvelappedIoResult(LPOVERLAPPED ovl_data,
-                                    ULONG* bytes_transferred,
-                                    bool wait);
-
-  /** \brief Checks if I/O that this object represents has completed.
-
-    @return 'true' if I/O has been completed or 'false' if it's still
-            incomplete. Regardless of the returned value, caller should
-            check GetLastError to validate that handle was OK.
-  */
-  virtual bool IsCompleted();
-
- public:
-  /// Gets overlapped structure for this I/O
-  LPOVERLAPPED overlapped() {
-    return &overlapped_;
-  }
-
-  /// Gets parent object
-  AdbIOObject* parent_io_object() const {
-    return parent_io_object_;
-  }
-
-  /// Gets parent object handle
-  ADBAPIHANDLE GetParentObjectHandle() const {
-    return (NULL != parent_io_object()) ? parent_io_object()->adb_handle() :
-                                          NULL;
-  }
-
-  /// Gets address for ADB_IOCTL_BULK_WRITE output buffer
-  ULONG* transferred_bytes_ptr() {
-    ATLASSERT(is_write_ioctl());
-    return &transferred_bytes_;
-  }
-
-  /// Gets write IOCTL flag
-  bool is_write_ioctl() const {
-    return is_write_ioctl_;
-  }
-
-  // This is a helper for extracting object from the AdbObjectHandleMap
-  static AdbObjectType Type() {
-    return AdbObjectTypeIoCompletion;
-  }
-
- protected:
-  /// Overlapped structure for this I/O
-  OVERLAPPED    overlapped_;
-
-  /// Parent I/O object
-  AdbIOObject*  parent_io_object_;
-
-  /// Recepient for number of transferred bytes in write IOCTL
-  ULONG         transferred_bytes_;
-
-  /// Expected number of bytes transferred in thi I/O
-  ULONG         expected_transfer_size_;
-
-  /// Write IOCTL flag
-  bool          is_write_ioctl_;
-};
-
-#endif  // ANDROID_USB_API_ADB_IO_COMPLETION_H__
diff --git a/host/windows/usb/api/adb_io_object.cpp b/host/windows/usb/api/adb_io_object.cpp
deleted file mode 100644
index 732dc22..0000000
--- a/host/windows/usb/api/adb_io_object.cpp
+++ /dev/null
@@ -1,284 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AdbIOObject that encapsulates
-  an item on our device that is opened for read / write / IOCTL I/O.
-*/
-
-#include "stdafx.h"
-#include "adb_io_object.h"
-#include "adb_io_completion.h"
-#include "adb_helper_routines.h"
-
-AdbIOObject::AdbIOObject(AdbInterfaceObject* parent_interf,
-                         AdbObjectType obj_type)
-    : AdbObjectHandle(obj_type),
-      usb_handle_(INVALID_HANDLE_VALUE),
-      parent_interface_(parent_interf) {
-  ATLASSERT(NULL != parent_interf);
-  parent_interf->AddRef();
-}
-
-AdbIOObject::~AdbIOObject() {
-  if (INVALID_HANDLE_VALUE != usb_handle_)
-    ::CloseHandle(usb_handle_);
-  parent_interface_->Release();
-}
-
-ADBAPIHANDLE AdbIOObject::CreateHandle(const wchar_t* item_path,
-                                       AdbOpenAccessType access_type,
-                                       AdbOpenSharingMode share_mode) {
-  // Make sure that we don't have USB handle here
-  if (IsUsbOpened()) {
-    SetLastError(ERROR_GEN_FAILURE);
-    return NULL;
-  }
-
-  // Convert access / share parameters into CreateFile - compatible
-  ULONG desired_access;
-  ULONG desired_sharing;
-
-  if (!GetSDKComplientParam(access_type, share_mode,
-                            &desired_access, &desired_sharing)) {
-    return NULL;
-  }
-
-  // Open USB handle
-  usb_handle_ = CreateFile(item_path,
-                           desired_access,
-                           share_mode,
-                           NULL,
-                           OPEN_EXISTING,
-                           FILE_FLAG_OVERLAPPED,  // Always overlapped!
-                           NULL);
-  if (INVALID_HANDLE_VALUE == usb_handle_)
-    return NULL;
-
-  // Create ADB handle
-  ADBAPIHANDLE ret = AdbObjectHandle::CreateHandle();
-
-  if (NULL == ret) {
-    // If creation of ADB handle failed we have to close USB handle too.
-    ULONG error = GetLastError();
-    ::CloseHandle(usb_handle());
-    usb_handle_ = INVALID_HANDLE_VALUE;
-    SetLastError(error);
-  }
-
-  return ret;
-}
-
-bool AdbIOObject::CloseHandle() {
-  // Lets close USB item first
-  if (IsUsbOpened()) {
-    ::CloseHandle(usb_handle());
-    usb_handle_ = INVALID_HANDLE_VALUE;
-  }
-
-  return AdbObjectHandle::CloseHandle();
-}
-
-ADBAPIHANDLE AdbIOObject::AsyncRead(void* buffer,
-                                    ULONG bytes_to_read,
-                                    ULONG* bytes_read,
-                                    HANDLE event_handle,
-                                    ULONG time_out) {
-  return CommonAsyncReadWrite(true,
-                              buffer,
-                              bytes_to_read,
-                              bytes_read,
-                              event_handle,
-                              time_out);
-}
-
-ADBAPIHANDLE AdbIOObject::AsyncWrite(void* buffer,
-                                     ULONG bytes_to_write,
-                                     ULONG* bytes_written,
-                                     HANDLE event_handle,
-                                     ULONG time_out) {
-  return CommonAsyncReadWrite(false,
-                              buffer,
-                              bytes_to_write,
-                              bytes_written,
-                              event_handle,
-                              time_out);
-}
-
-bool AdbIOObject::SyncRead(void* buffer,
-                           ULONG bytes_to_read,
-                           ULONG* bytes_read,
-                           ULONG time_out) {
-  return CommonSyncReadWrite(true,
-                             buffer,
-                             bytes_to_read,
-                             bytes_read,
-                             time_out);
-}
-
-bool AdbIOObject::SyncWrite(void* buffer,
-                            ULONG bytes_to_write,
-                            ULONG* bytes_written,
-                            ULONG time_out) {
-  return CommonSyncReadWrite(false,
-                             buffer,
-                             bytes_to_write,
-                             bytes_written,
-                             time_out);
-}
-
-ADBAPIHANDLE AdbIOObject::CommonAsyncReadWrite(bool is_read,
-                                               void* buffer,
-                                               ULONG bytes_to_transfer,
-                                               ULONG* bytes_transferred,
-                                               HANDLE event_handle,
-                                               ULONG time_out) {
-  if (NULL != bytes_transferred)
-    *bytes_transferred = 0;
-
-  if (!IsOpened() || !IsUsbOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  bool is_ioctl_write = is_read ? false : (0 != time_out);
-
-  // Create completion i/o object
-  AdbIOCompletion* adb_io_completion = NULL;
-
-  try {
-    adb_io_completion = new AdbIOCompletion(this,
-                                            is_ioctl_write,
-                                            bytes_to_transfer,
-                                            event_handle);
-  } catch (... ) {
-    SetLastError(ERROR_OUTOFMEMORY);
-    return NULL;
-  }
-
-  // Create a handle for it
-  ADBAPIHANDLE ret = adb_io_completion->CreateHandle();
-  ULONG transferred = 0;
-  if (NULL != ret) {
-    BOOL res = TRUE;
-    if (0 == time_out) {
-      // Go the read / write file way
-      res = is_read ? ReadFile(usb_handle(),
-                               buffer,
-                               bytes_to_transfer,
-                               &transferred,
-                               adb_io_completion->overlapped()) :
-                      WriteFile(usb_handle(),
-                                buffer,
-                                bytes_to_transfer,
-                                &transferred,
-                                adb_io_completion->overlapped());
-    } else {
-      // Go IOCTL way
-      AdbBulkTransfer transfer_param;
-      transfer_param.time_out = time_out;
-      transfer_param.transfer_size = is_read ? 0 : bytes_to_transfer;
-      transfer_param.SetWriteBuffer(is_read ? NULL : buffer);
-
-      res = DeviceIoControl(usb_handle(),
-        is_read ? ADB_IOCTL_BULK_READ : ADB_IOCTL_BULK_WRITE,
-        &transfer_param, sizeof(transfer_param),
-        is_read ? buffer : adb_io_completion->transferred_bytes_ptr(),
-        is_read ? bytes_to_transfer : sizeof(ULONG),
-        &transferred,
-        adb_io_completion->overlapped());
-    }
-
-    if (NULL != bytes_transferred)
-      *bytes_transferred = transferred;
-
-    ULONG error = GetLastError();
-    if (!res && (ERROR_IO_PENDING != error)) {
-      // I/O failed immediatelly. We need to close i/o completion object
-      // before we return NULL to the caller.
-      adb_io_completion->CloseHandle();
-      ret = NULL;
-      SetLastError(error);
-    }
-  }
-
-  // Offseting 'new'
-  adb_io_completion->Release();
-
-  return ret;
-}
-
-bool AdbIOObject::CommonSyncReadWrite(bool is_read,
-                                      void* buffer,
-                                      ULONG bytes_to_transfer,
-                                      ULONG* bytes_transferred,
-                                      ULONG time_out) {
-  if (NULL != bytes_transferred)
-    *bytes_transferred = 0;
-
-  if (!IsOpened() || !IsUsbOpened()) {
-    SetLastError(ERROR_INVALID_HANDLE);
-    return false;
-  }
-
-  bool is_ioctl_write = is_read ? false : (0 != time_out);
-
-  // This is synchronous I/O. Since we always open I/O items for
-  // overlapped I/O we're obligated to always provide OVERLAPPED
-  // structure to read / write routines. Prepare it now.
-  OVERLAPPED overlapped;
-  ZeroMemory(&overlapped, sizeof(overlapped));
-
-  BOOL ret = TRUE;
-  ULONG ioctl_write_transferred = 0;
-  if (0 == time_out) {
-    // Go the read / write file way
-    ret = is_read ?
-      ReadFile(usb_handle(), buffer, bytes_to_transfer, bytes_transferred, &overlapped) :
-      WriteFile(usb_handle(), buffer, bytes_to_transfer, bytes_transferred, &overlapped);
-  } else {
-    // Go IOCTL way
-    AdbBulkTransfer transfer_param;
-    transfer_param.time_out = time_out;
-    transfer_param.transfer_size = is_read ? 0 : bytes_to_transfer;
-    transfer_param.SetWriteBuffer(is_read ? NULL : buffer);
-
-    ULONG tmp;
-    ret = DeviceIoControl(usb_handle(),
-      is_read ? ADB_IOCTL_BULK_READ : ADB_IOCTL_BULK_WRITE,
-      &transfer_param, sizeof(transfer_param),
-      is_read ? buffer : &ioctl_write_transferred,
-      is_read ? bytes_to_transfer : sizeof(ULONG),
-      &tmp,
-      &overlapped);
-  }
-
-  // Lets see the result
-  if (!ret && (ERROR_IO_PENDING != GetLastError())) {
-    // I/O failed.
-    return false;
-  }
-
-  // Lets wait till I/O completes
-  ULONG transferred = 0;
-  ret = GetOverlappedResult(usb_handle(), &overlapped, &transferred, TRUE);
-  if (ret && (NULL != bytes_transferred)) {
-    *bytes_transferred = is_ioctl_write ? ioctl_write_transferred :
-                                          transferred;
-  }
-
-  return ret ? true : false;
-}
diff --git a/host/windows/usb/api/adb_io_object.h b/host/windows/usb/api/adb_io_object.h
deleted file mode 100644
index 7161b67..0000000
--- a/host/windows/usb/api/adb_io_object.h
+++ /dev/null
@@ -1,238 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_IO_OBJECT_H__
-#define ANDROID_USB_API_ADB_IO_OBJECT_H__
-/** \file
-  This file consists of declaration of class AdbIOObject that encapsulates an
-  item on our device that is opened for read / write / IOCTL I/O.
-*/
-
-#include "adb_interface.h"
-
-/** Class AdbIOObject encapsulates an item on our device that is opened for
-  read / write / IOCTL I/O.. All I/O items (currently only endpoints) are
-  always opened for overlapped I/O (i.e. FILE_OVERLAPPED flag is set in
-  create attributes). This way each object of the derived class automatically
-  supports both, synchronous as well as asynchronous I/O. Since async I/O
-  requires "giving out" some I/O context, we have to provide async I/O caller
-  with some safe handle to this context. This is done wia allocating
-  AdbIOCompletion object that holds async I/O context and returning handle to
-  this object to the caller of async I/O.
-*/
-class AdbIOObject : public AdbObjectHandle {
- public:
-  /** \brief Constructs the object
-    
-    @param interface[in] Parent interface for this object. Interface will be
-           referenced in this object's constructur and released in the
-           destructor.
-    @param obj_type[in] Object type from AdbObjectType enum
-  */
-  AdbIOObject(AdbInterfaceObject* parent_interf, AdbObjectType obj_type);
-
- protected:
-  /** \brief Destructs the object.
-
-    parent_interface_ will be dereferenced here.
-    We hide destructor in order to prevent ourseves from accidentaly allocating
-    instances on the stack. If such attemp occur, compiler will error.
-  */
-  virtual ~AdbIOObject();
-
- public:
-  /** \brief Opens USB item and creates a handle to this object
-
-    We combine in this method ADB handle association and opening required
-    object on our USB device. The sequence is to open USB item first and if
-    (and only if) this open succeedes we proceed to creating ADB handle by
-    calling AdbObjectHandle::CreateHandle(). We always open USB handle for
-    overlapped I/O.
-    @param item_path[in] Path to the item on our USB device.
-    @param access_type[in] Desired access type. In the current implementation
-          this parameter has no effect on the way item is opened. It's
-          always read / write access.
-    @param sharing_mode[in] Desired share mode. In the current implementation
-          this parameter has no effect on the way item is opened. It's
-          always shared for read / write.
-    @return A handle to this object on success or NULL on an error.
-            If NULL is returned GetLastError() provides extended error
-            information. ERROR_GEN_FAILURE is set if an attempt was
-            made to create already opened object.
-  */
-  virtual ADBAPIHANDLE CreateHandle(const wchar_t* item_path,
-                                    AdbOpenAccessType access_type,
-                                    AdbOpenSharingMode share_mode);
-
-  /** \brief This method is called when handle to this object gets closed
-
-    We overwrite this method in order to close USB handle along with this
-    object handle.
-    @return 'true' on success or 'false' if object is already closed. If
-            'false' is returned GetLastError() provides extended error
-            information.
-  */
-  virtual bool CloseHandle();
-
-  /** \brief Reads from opened I/O object asynchronously
-
-    @param buffer[out] Pointer to the buffer that receives the data.
-    @param bytes_to_read[in] Number of bytes to be read.
-    @param bytes_read[out] Number of bytes read. Can be NULL.
-    @param event_handle[in] Event handle that should be signaled when async I/O
-           completes. Can be NULL. If it's not NULL this handle will be used to
-           initialize OVERLAPPED structure for this I/O.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return A handle to IO completion object or NULL on failure. If NULL is
-            returned GetLastError() provides extended error information.
-  */
-  virtual ADBAPIHANDLE AsyncRead(void* buffer,
-                                 ULONG bytes_to_read,
-                                 ULONG* bytes_read,
-                                 HANDLE event_handle,
-                                 ULONG time_out);
-
-  /** \brief Writes to opened I/O object asynchronously
-
-    @param buffer[in] Pointer to the buffer containing the data to be written.
-    @param bytes_to_write[in] Number of bytes to be written.
-    @param bytes_written[out] Number of bytes written. Can be NULL.
-    @param event_handle[in] Event handle that should be signaled when async I/O
-           completes. Can be NULL. If it's not NULL this handle will be used to
-           initialize OVERLAPPED structure for this I/O.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return A handle to IO completion object or NULL on failure. If NULL is
-            returned GetLastError() provides extended error information.
-  */
-  virtual ADBAPIHANDLE AsyncWrite(void* buffer,
-                                  ULONG bytes_to_write,
-                                  ULONG* bytes_written,
-                                  HANDLE event_handle,
-                                  ULONG time_out);
-
-  /** \brief Reads from opened I/O object synchronously
-
-    @param buffer[out] Pointer to the buffer that receives the data.
-    @param bytes_to_read[in] Number of bytes to be read.
-    @param bytes_read[out] Number of bytes read. Can be NULL.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return 'true' on success and 'false' on failure. If 'false' is
-            returned GetLastError() provides extended error information.
-  */
-  virtual bool SyncRead(void* buffer,
-                        ULONG bytes_to_read,
-                        ULONG* bytes_read,
-                        ULONG time_out);
-
-  /** \brief Writes to opened I/O object synchronously
-
-    @param buffer[in] Pointer to the buffer containing the data to be written.
-    @param bytes_to_write[in] Number of bytes to be written.
-    @param bytes_written[out] Number of bytes written. Can be NULL.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return 'true' on success and 'false' on failure. If 'false' is
-            returned GetLastError() provides extended error information.
-  */
-  virtual bool SyncWrite(void* buffer,
-                         ULONG bytes_to_write,
-                         ULONG* bytes_written,
-                         ULONG time_out);
-
- protected:
-  /** \brief Common code for async read / write
-
-    @param is_read[in] Read or write selector.
-    @param buffer[in,out] Pointer to the buffer for read / write.
-    @param bytes_to_transfer[in] Number of bytes to be read / written.
-    @param bytes_transferred[out] Number of bytes read / written. Can be NULL.
-    @param event_handle[in] Event handle that should be signaled when async I/O
-           completes. Can be NULL. If it's not NULL this handle will be used to
-           initialize OVERLAPPED structure for this I/O.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return A handle to IO completion object or NULL on failure. If NULL is
-            returned GetLastError() provides extended error information.
-  */
-  virtual ADBAPIHANDLE CommonAsyncReadWrite(bool is_read,
-                                            void* buffer,
-                                            ULONG bytes_to_transfer,
-                                            ULONG* bytes_transferred,
-                                            HANDLE event_handle,
-                                            ULONG time_out);
-
-  /** \brief Common code for sync read / write
-
-    @param is_read[in] Read or write selector.
-    @param buffer[in,out] Pointer to the buffer for read / write.
-    @param bytes_to_transfer[in] Number of bytes to be read / written.
-    @param bytes_transferred[out] Number of bytes read / written. Can be NULL.
-    @param time_out[in] A timeout (in milliseconds) required for this I/O to
-           complete. Zero value in this parameter means that there is no
-           timeout set for this I/O.
-    @return 'true' on success, 'false' on failure. If 'false' is returned
-            GetLastError() provides extended error information.
-  */
-  virtual bool CommonSyncReadWrite(bool is_read,
-                                   void* buffer,
-                                   ULONG bytes_to_transfer,
-                                   ULONG* bytes_transferred,
-                                   ULONG time_out);
-
- public:
-  /// Gets parent interface 
-  AdbInterfaceObject* parent_interface() const {
-    return parent_interface_;
-  }
-
-  /// Gets parent interface handle
-  ADBAPIHANDLE GetParentInterfaceHandle() const {
-    return (NULL != parent_interface()) ? parent_interface()->adb_handle() :
-                                          NULL;
-  }
-
-  /// Gets handle to an item opened on our USB device
-  HANDLE usb_handle() const {
-    return usb_handle_;
-  }
-
-  /// Checks if USB item is opened
-  bool IsUsbOpened() const {
-    return (INVALID_HANDLE_VALUE != usb_handle());
-  }
-
-  // This is a helper for extracting object from the AdbObjectHandleMap
-  static AdbObjectType Type() {
-    return AdbObjectTypeIo;
-  }
-
- protected:
-  /// Parent interface
-  AdbInterfaceObject* parent_interface_;
-
-  /// Handle to an item opened on our USB device
-  HANDLE              usb_handle_;
-};
-
-#endif  // ANDROID_USB_API_ADB_IO_OBJECT_H__
diff --git a/host/windows/usb/api/adb_object_handle.cpp b/host/windows/usb/api/adb_object_handle.cpp
deleted file mode 100644
index 8c643b4..0000000
--- a/host/windows/usb/api/adb_object_handle.cpp
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of a class AdbObjectHandle that
-  encapsulates an internal API object that is visible to the outside
-  of the API through a handle.
-*/
-
-#include "stdafx.h"
-#include "adb_api.h"
-#include "adb_object_handle.h"
-
-/// Global ADBAPIHANDLE -> AdbObjectHandle* map
-AdbObjectHandleMap      the_map;
-
-/// Locker for the AdbObjectHandleMap instance
-CComAutoCriticalSection the_map_locker;
-
-/// Next adb handle value generator
-ULONG_PTR               next_adb_handle_value = 0;
-
-AdbObjectHandle::AdbObjectHandle(AdbObjectType obj_type)
-    : adb_handle_(NULL),
-      object_type_(obj_type),
-      ref_count_(1) {
-  ATLASSERT(obj_type < AdbObjectTypeMax);
-}
-
-AdbObjectHandle::~AdbObjectHandle() {
-  ATLASSERT(0 == ref_count_);
-  ATLASSERT(NULL == adb_handle_);
-}
-
-LONG AdbObjectHandle::AddRef() {
-  ATLASSERT(ref_count_ > 0);
-  return InterlockedIncrement(&ref_count_);
-}
-
-LONG AdbObjectHandle::Release() {
-  ATLASSERT(ref_count_ > 0);
-  LONG ret = InterlockedDecrement(&ref_count_);
-  ATLASSERT(ret >= 0);
-  if (0 == ret) {
-    LastReferenceReleased();
-    delete this;
-  }
-  return ret;
-}
-
-ADBAPIHANDLE AdbObjectHandle::CreateHandle() {
-  ADBAPIHANDLE ret = NULL;
-
-  // We have to hold this lock while we're dealing with the handle
-  // and the table
-  the_map_locker.Lock();
-  
-  ATLASSERT(!IsOpened());
-
-  if (!IsOpened()) {
-    try {
-      // Generate next handle value
-      next_adb_handle_value++;
-      ret = reinterpret_cast<ADBAPIHANDLE>(next_adb_handle_value);
-
-      // Add ourselves to the map
-      the_map[ret] = this;
-
-      // Save handle, addref and return
-      adb_handle_ = ret;
-      AddRef();
-    } catch (...) {
-      ret = NULL;
-      SetLastError(ERROR_OUTOFMEMORY);
-    }
-  } else {
-    // Signaling that this object is already opened
-    SetLastError(ERROR_GEN_FAILURE);
-  }
-
-  the_map_locker.Unlock();
-
-  return ret;
-}
-
-bool AdbObjectHandle::CloseHandle() {
-  bool ret = false;
-
-  // Addref just in case that last reference to this object is being
-  // held in the map
-  AddRef();
-
-  the_map_locker.Lock();
-  
-  ATLASSERT(IsOpened());
-
-  if (IsOpened()) {
-    try {
-      // Look us up in the map.
-      AdbObjectHandleMap::iterator found = the_map.find(adb_handle());
-      ATLASSERT((found != the_map.end()) && (this == found->second));
-
-      if ((found != the_map.end()) && (this == found->second)) {
-        // Remove ourselves from the map, close and release the object
-        the_map.erase(found);
-        adb_handle_ = NULL;
-        Release();
-        ret = true;
-      } else {
-        SetLastError(ERROR_INVALID_HANDLE);
-      }
-    } catch (...) {
-      ret = false;
-      SetLastError(ERROR_OUTOFMEMORY);
-    }
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-  }
-
-  the_map_locker.Unlock();
-
-  Release();
-
-  return ret;
-}
-
-bool AdbObjectHandle::IsObjectOfType(AdbObjectType obj_type) const {
-  return (obj_type == object_type());
-}
-
-void AdbObjectHandle::LastReferenceReleased() {
-  ATLASSERT(!IsOpened());
-}
-
-AdbObjectHandle* AdbObjectHandle::Lookup(ADBAPIHANDLE adb_hndl) {
-  AdbObjectHandle* ret = NULL;
-
-  the_map_locker.Lock();
-
-  try {
-    // Look us up in the map.
-    AdbObjectHandleMap::iterator found = the_map.find(adb_hndl);
-    if (found != the_map.end()) {
-      ret = found->second;
-      ret->AddRef();
-    }
-  } catch (...) {
-    SetLastError(ERROR_OUTOFMEMORY);
-  }
-
-  the_map_locker.Unlock();
-
-  return ret;
-}
diff --git a/host/windows/usb/api/adb_object_handle.h b/host/windows/usb/api/adb_object_handle.h
deleted file mode 100644
index 088971c..0000000
--- a/host/windows/usb/api/adb_object_handle.h
+++ /dev/null
@@ -1,213 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_API_ADB_OBJECT_HANDLE_H__
-#define ANDROID_USB_API_ADB_OBJECT_HANDLE_H__
-/** \file
-  This file consists of declaration of a class AdbObjectHandle that
-  encapsulates an internal API object that is visible to the outside
-  of the API through a handle.
-*/
-
-#include "adb_api_private_defines.h"
-
-/** AdbObjectType enum defines types of internal API objects
-*/
-enum AdbObjectType {
-  /// Object is AdbInterfaceEnumObject
-  AdbObjectTypeInterfaceEnumerator,
-
-  /// Object is AdbInterfaceObject
-  AdbObjectTypeInterface,
-
-  /// Object is derived from AdbIOObject
-  AdbObjectTypeIo,
-
-  /// Object is AdbEndpointObject
-  AdbObjectTypeEndpoint,
-
-  /// Object is AdbIOCompletion
-  AdbObjectTypeIoCompletion,
-
-  AdbObjectTypeMax
-};
-
-/** Class AdbObjectHandle encapsulates an internal API basic object that is
-  visible to the outside of the API through a handle. In order to prevent
-  crashes when API client tries to access an object through an invalid or
-  already closed handle, we keep track of all opened handles in
-  AdbObjectHandleMap that maps association between valid ADBAPIHANDLE and
-  an object that this handle represents. All objects that are exposed to the
-  outside of API via ADBAPIHANDLE are self-destructing referenced objects.
-  The reference model for these objects is as such:
-  1. When CreateHandle() method is called on an object, a handle (ADBAPIHANDLE
-     that is) is assigned to it, a pair <handle, object> is added to the global
-     AdbObjectHandleMap instance, object is referenced and then handle is
-     returned to the API client.
-  2. Every time API is called with a handle, a lookup is performed in 
-     AdbObjectHandleMap to find an object that is associated with the handle.
-     If object is not found then ERROR_INVALID_HANDLE is immediatelly returned
-     (via SetLastError() call). If object is found then it is referenced and
-     API call is dispatched to appropriate method of the found object. Upon
-     return from this method, just before returning from the API call, object
-     is dereferenced back to match lookup reference.
-  3. When object handle gets closed, assuming object is found in the map, that
-     <handle, object> pair is deleted from the map and object's refcount is
-     decremented to match refcount increment performed when object has been
-     added to the map.
-  4. When object's refcount drops to zero, the object commits suicide by
-     calling "delete this".
-  All API objects that have handles that are sent back to API client must be
-  derived from this class.
-*/
-class AdbObjectHandle {
- public:
-  /** \brief Constructs the object
-
-    Refernce counter is set to 1 in the constructor.
-    @param obj_type[in] Object type from AdbObjectType enum
-  */
-  explicit AdbObjectHandle(AdbObjectType obj_type);
-
- protected:
-  /** \brief Destructs the object.
-
-   We hide destructor in order to prevent ourseves from accidentaly allocating
-   instances on the stack. If such attempt occurs, compiler will error.
-  */
-  virtual ~AdbObjectHandle();
-
- public:
-  /** \brief References the object
-
-    @return Value of the reference counter after object is referenced in this
-            method.
-  */
-  virtual LONG AddRef();
-
-  /** \brief Releases the object
-
-    If refcount drops to zero as the result of this release, the object is
-    destroyed in this method. As a general rule, objects must not be touched
-    after this method returns even if returned value is not zero.
-    @return Value of the reference counter after object is released in this
-            method.
-  */
-  virtual LONG Release();
-
-  /** \brief Creates handle to this object
-
-    In this call a handle for this object is generated and object is added
-    to the AdbObjectHandleMap.
-    @return A handle to this object on success or NULL on an error.
-            If NULL is returned GetLastError() provides extended error
-            information. ERROR_GEN_FAILURE is set if an attempt was
-            made to create already opened object.
-  */
-  virtual ADBAPIHANDLE CreateHandle();
-
-  /** \brief This method is called when handle to this object gets closed
-
-    In this call object is deleted from the AdbObjectHandleMap.
-    @return 'true' on success or 'false' if object is already closed. If
-            'false' is returned GetLastError() provides extended error
-            information.
-  */
-  virtual bool CloseHandle();
-
-  /** \brief Checks if this object is of the given type
-
-    @param obj_type[in] One of the AdbObjectType types to check
-    @return 'true' is this object type matches obj_type, or 'false' otherwise.
-  */
-  virtual bool IsObjectOfType(AdbObjectType obj_type) const;
-
-  /** \brief Looks up AdbObjectHandle instance associated with the given handle
-    in the AdbObjectHandleMap.
-
-    This method increments reference counter for the returned found object.
-    @param adb_handle[in] ADB handle to the object
-    @return API object associated with the handle or NULL if object is not
-            found. If NULL is returned GetLastError() provides extended error
-            information.
-  */
-  static AdbObjectHandle* Lookup(ADBAPIHANDLE adb_handle);
-
- protected:
-  /** \brief Called when last reference to this object is released.
-
-    Derived object should override this method to perform cleanup that is not
-    suitable for destructors.
-  */
-  virtual void LastReferenceReleased();
-
- public:
-  /// Gets ADB handle associated with this object
-  ADBAPIHANDLE adb_handle() const {
-    return adb_handle_;
-  }
-
-  /// Gets type of this object
-  AdbObjectType object_type() const {
-    return object_type_;
-  }
-
-  /// Checks if object is still opened. Note that it is not guaranteed that
-  /// object remains opened when this method returns.
-  bool IsOpened() const {
-    return (NULL != adb_handle());
-  }
-
- protected:
-  /// API handle associated with this object
-  ADBAPIHANDLE  adb_handle_;
-
-  /// Type of this object
-  AdbObjectType object_type_;
-
-  /// This object's reference counter
-  LONG          ref_count_;
-};
-
-/// Maps ADBAPIHANDLE to associated AdbObjectHandle object
-typedef std::map< ADBAPIHANDLE, AdbObjectHandle* > AdbObjectHandleMap;
-
-/** \brief Template routine that unifies extracting of objects of different
-  types from the AdbObjectHandleMap
-
-  @param adb_handle[in] API handle for the object
-  @return Object associated with the handle or NULL on error. If NULL is
-          returned GetLastError() provides extended error information.
-*/
-template<class obj_class>
-obj_class* LookupObject(ADBAPIHANDLE adb_handle) {
-  // Lookup object for the handle in the map
-  AdbObjectHandle* adb_object = AdbObjectHandle::Lookup(adb_handle);
-  if (NULL != adb_object) {
-    // Make sure it's of the correct type
-    if (!adb_object->IsObjectOfType(obj_class::Type())) {
-      adb_object->Release();
-      adb_object = NULL;
-      SetLastError(ERROR_INVALID_HANDLE);
-    }
-  } else {
-    SetLastError(ERROR_INVALID_HANDLE);
-  }
-  return (adb_object != NULL) ? reinterpret_cast<obj_class*>(adb_object) :
-                                NULL;
-}
-
-#endif  // ANDROID_USB_API_ADB_OBJECT_HANDLE_H__
diff --git a/host/windows/usb/api/stdafx.cpp b/host/windows/usb/api/stdafx.cpp
deleted file mode 100644
index 87db2cd..0000000
--- a/host/windows/usb/api/stdafx.cpp
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// stdafx.cpp : source file that includes just the standard includes
-// AdbWinApi.pch will be the pre-compiled header
-// stdafx.obj will contain the pre-compiled type information
-
-#include "stdafx.h"
diff --git a/host/windows/usb/api/stdafx.h b/host/windows/usb/api/stdafx.h
deleted file mode 100644
index f47936f..0000000
--- a/host/windows/usb/api/stdafx.h
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  Visual Studio generated include file for standard system include files, or
-  project specific include files that are used frequently, but are changed
-  infrequently.
-*/
-
-#pragma once
-
-#ifndef STRICT
-#define STRICT
-#endif
-
-// Modify the following defines if you have to target a platform prior to the ones specified below.
-// Refer to MSDN for the latest info on corresponding values for different platforms.
-#ifndef WINVER				// Allow use of features specific to Windows 95 and Windows NT 4 or later.
-#define WINVER 0x0500		// Change this to the appropriate value to target Windows 98 and Windows 2000 or later.
-#endif
-
-#ifndef _WIN32_WINNT		// Allow use of features specific to Windows NT 4 or later.
-#define _WIN32_WINNT 0x0500	// Change this to the appropriate value to target Windows 2000 or later.
-#endif						
-
-#ifndef _WIN32_WINDOWS		// Allow use of features specific to Windows 98 or later.
-#define _WIN32_WINDOWS 0x0500 // Change this to the appropriate value to target Windows Me or later.
-#endif
-
-#ifndef _WIN32_IE			// Allow use of features specific to IE 4.0 or later.
-#define _WIN32_IE 0x0501	// Change this to the appropriate value to target IE 5.0 or later.
-#endif
-
-#define _ATL_APARTMENT_THREADED
-#define _ATL_NO_AUTOMATIC_NAMESPACE
-
-#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS	// some CString constructors will be explicit
-
-// turns off ATL's hiding of some common and often safely ignored warning messages
-#define _ATL_ALL_WARNINGS
-
-#pragma warning(disable: 4702)
-#include "resource.h"
-#include <atlbase.h>
-#include <atlcom.h>
-#include <winioctl.h>
-#include <setupapi.h>
-#include <vector>
-#include <map>
-#include <string>
-#pragma warning(disable: 4200)
-extern "C" {
-#include <usbdi.h>
-}
-
-#include "android_usb_common_defines.h"
-
-using namespace ATL;
diff --git a/host/windows/usb/common/android_usb_common_defines.h b/host/windows/usb/common/android_usb_common_defines.h
deleted file mode 100644
index 723f4a3..0000000
--- a/host/windows/usb/common/android_usb_common_defines.h
+++ /dev/null
@@ -1,179 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_COMMON_DEFINES_H__
-#define ANDROID_USB_COMMON_DEFINES_H__
-/** \file
-  This file consists of declarations common for both, User and Kernel mode
-  parts of the system.
-*/
-
-/// Name for the default bulk read pipe
-#define DEVICE_BULK_READ_PIPE_NAME  L"BulkRead"
-
-/// Name for the default bulk write pipe
-#define DEVICE_BULK_WRITE_PIPE_NAME L"BulkWrite"
-
-/// Prefix for an index-based pipe name 
-#define DEVICE_PIPE_NAME_PREFIX     L"PIPE_"
-
-/** \name IOCTL codes for the driver
-*/
-///@{
-
-/// Control code for IOCTL that gets USB_DEVICE_DESCRIPTOR
-#define ADB_CTL_GET_USB_DEVICE_DESCRIPTOR         10
-
-/// Control code for IOCTL that gets USB_CONFIGURATION_DESCRIPTOR
-#define ADB_CTL_GET_USB_CONFIGURATION_DESCRIPTOR  11
-
-/// Control code for IOCTL that gets USB_INTERFACE_DESCRIPTOR
-#define ADB_CTL_GET_USB_INTERFACE_DESCRIPTOR      12
-
-/// Control code for IOCTL that gets endpoint information
-#define ADB_CTL_GET_ENDPOINT_INFORMATION          13
-
-/// Control code for bulk read IOCTL
-#define ADB_CTL_BULK_READ                         14
-
-/// Control code for bulk write IOCTL
-#define ADB_CTL_BULK_WRITE                        15
-
-/// Control code for IOCTL that gets device serial number
-#define ADB_CTL_GET_SERIAL_NUMBER                 16
-
-/// IOCTL that gets USB_DEVICE_DESCRIPTOR
-#define ADB_IOCTL_GET_USB_DEVICE_DESCRIPTOR \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_GET_USB_DEVICE_DESCRIPTOR, \
-                       METHOD_BUFFERED, \
-                       FILE_READ_ACCESS)
-
-/// IOCTL that gets USB_CONFIGURATION_DESCRIPTOR
-#define ADB_IOCTL_GET_USB_CONFIGURATION_DESCRIPTOR \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_GET_USB_CONFIGURATION_DESCRIPTOR, \
-                       METHOD_BUFFERED, \
-                       FILE_READ_ACCESS)
-
-/// IOCTL that gets USB_INTERFACE_DESCRIPTOR
-#define ADB_IOCTL_GET_USB_INTERFACE_DESCRIPTOR \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_GET_USB_INTERFACE_DESCRIPTOR, \
-                       METHOD_BUFFERED, \
-                       FILE_READ_ACCESS)
-
-/// IOCTL that gets endpoint information
-#define ADB_IOCTL_GET_ENDPOINT_INFORMATION \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_GET_ENDPOINT_INFORMATION, \
-                       METHOD_BUFFERED, \
-                       FILE_READ_ACCESS)
-
-/// Bulk read IOCTL
-#define ADB_IOCTL_BULK_READ \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_BULK_READ, \
-                       METHOD_OUT_DIRECT, \
-                       FILE_READ_ACCESS)
-
-// For bulk write IOCTL we send request data in the form of AdbBulkTransfer
-// structure and output buffer is just ULONG that receives number of bytes
-// actually written. Since both of these are tiny we can use buffered I/O
-// for this IOCTL.
-/// Bulk write IOCTL
-#define ADB_IOCTL_BULK_WRITE \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_BULK_WRITE, \
-                       METHOD_BUFFERED, \
-                       FILE_WRITE_ACCESS)
-
-/// IOCTL that gets device serial number
-#define ADB_IOCTL_GET_SERIAL_NUMBER \
-              CTL_CODE(FILE_DEVICE_UNKNOWN, \
-                       ADB_CTL_GET_SERIAL_NUMBER, \
-                       METHOD_BUFFERED, \
-                       FILE_READ_ACCESS)
-
-///@}
-
-/** Structure AdbQueryEndpointInformation formats input for
-  ADB_IOCTL_GET_ENDPOINT_INFORMATION IOCTL request
-*/
-struct AdbQueryEndpointInformation {
-  /// Zero-based endpoint index for which information is queried.
-  /// See ADB_QUERY_BULK_xxx_ENDPOINT_INDEX for shortcuts.
-  UCHAR endpoint_index;
-};
-
-/** Structure AdbBulkTransfer formats parameters for ADB_CTL_BULK_READ and
-  ADB_CTL_BULK_WRITE IOCTL requests.
-*/
-struct AdbBulkTransfer {
-  /// Time in milliseconds to complete this request
-  ULONG time_out;
-
-  /// Size of the data to transfer. This parameter is used only for
-  /// ADB_CTL_BULK_WRITE request. For ADB_CTL_BULK_READ requests transfer
-  /// size is defined by the output buffer size.
-  ULONG transfer_size;
-
-  /// Initializes statically allocated structure
-  __forceinline AdbBulkTransfer() {
-    time_out = 0;
-    transfer_size = 0;
-    for_x64 = 0;
-  }
-
-  /// Provides access to protected write_buffer field
-  void* GetWriteBuffer() {
-    return write_buffer;
-  }
-
-  /// Provides access to protected write_buffer field
-  const void* GetWriteBuffer() const {
-    return write_buffer;
-  }
-
-  /// Sets write_buffer field.
-  void SetWriteBuffer(void* buffer) {
-    // For 32-bit we must zero out high 32 bit of the address, so 64-bit
-    // driver will see valid address when accessing 64-bit write_buffer.
-    for_x64 = 0;
-    write_buffer = buffer;
-  }
-
-protected:
-  /// Pointer to the actual buffer for ADB_CTL_BULK_WRITE request. This field
-  /// is not used in ADB_CTL_BULK_READ request. Note that in order to support
-  /// compatibility between 32-bit and 64-bit versions of both, driver and
-  /// application we must sizeof this field to the max pointer sizeof (which
-  /// is 64 bit in our case). The idea is that if IOCTL was issued by a 64-bit
-  /// process to a 64-bit driver, write_buffer will be valid 64-bit pointer to
-  /// the write buffer. Same is true for 32-bit app talking to 32-bit driver.
-  /// If, however, a 32-bit app is talking to 64-bit driver, then write_buffer
-  /// initialized by 32-bit app will contain 32-bit address, which will be
-  /// correctly picked up ("extended") by 64-bit driver. Since when setting
-  /// this field by a 32-bit app requires some extra work (see SetWriteBuffer)
-  /// we hide this field, making it accessible only throug the accessor
-  /// methods (Get/SetWriteBuffer).
-  union {
-    void* write_buffer;
-    __int64 for_x64;
-  };
-};
-
-#endif  // ANDROID_USB_COMMON_DEFINES_H__
diff --git a/host/windows/usb/driver/android_usb.inf b/host/windows/usb/driver/android_usb.inf
deleted file mode 100644
index fff0440..0000000
--- a/host/windows/usb/driver/android_usb.inf
+++ /dev/null
@@ -1,126 +0,0 @@
-;/*++
-;
-;Abstract:
-;    Installation inf for the Android USB Bulk device
-;
-;--*/
-
-[Version]
-Signature="$WINDOWS NT$"
-Class=USB
-ClassGuid={F72FE0D4-CBCB-407d-8814-9ED673D0DD6B}
-Provider=%GOOG%
-DriverVer=1/29/2009,1.0.0010.00000
-CatalogFile.NTx86=androidusb86.cat
-CatalogFile.NTamd64=androidusba64.cat
-
-; ================= Class section =====================
-
-[ClassInstall32]
-Addreg=AndroidUsbClassReg
-
-[AndroidUsbClassReg]
-HKR,,,0,%ClassName%
-HKR,,Icon,,-5
-
-[DestinationDirs]
-DefaultDestDir = 12
-
-; ================= Device section =====================
-
-[Manufacturer]
-%MfgName%=Google,NTx86,NTamd64
-
-; For Win2K
-[Google]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For XP and later
-[Google.NTx86]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-; For AMD64 and later
-[Google.NTamd64]
-; For loopback testing
-%USB\VID_18D1&PID_DDDD.DeviceDescTest%=androidusb.Dev, USB\VID_18D1&PID_DDDD
-; HTC Dream
-%USB\VID_0BB4&PID_0C01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C01
-%USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0C02&MI_01
-%USB\VID_0BB4&PID_0FFF.DeviceDescRelease%=androidusb.Dev, USB\VID_0BB4&PID_0FFF
-
-[androidusb.Dev.NT]
-CopyFiles=androidusb.Files.Ext
-
-[androidusb.Dev.NT.Services]
-Addservice = androidusb, 0x00000002, androidusb.AddService
-
-[androidusb.AddService]
-DisplayName    = %androidusb.SvcDesc%
-ServiceType    = 1                  ; SERVICE_KERNEL_DRIVER
-StartType      = 3                  ; SERVICE_DEMAND_START
-ErrorControl   = 1                  ; SERVICE_ERROR_NORMAL
-ServiceBinary  = %10%\System32\Drivers\androidusb.sys
-AddReg         = androidusb.AddReg
-LoadOrderGroup = Base
-
-[androidusb.AddReg]
-HKR,"Parameters","MaximumTransferSize",0x10001,4096
-HKR,"Parameters","DebugLevel",0x10001,2
-HKR, Parameters\Wdf, VerboseOn,       0x00010001, 1
-HKR, Parameters\Wdf, VerifierOn,      0x00010001, 1
-HKR, Parameters\Wdf, DbgBreakOnError, 0x00010001, 1
-
-[androidusb.Files.Ext]
-androidusb.sys
-
-[SourceDisksNames]
-1=%Disk_Description%,,,
-
-[SourceDisksFiles]
-androidusb.sys = 1
-
-;-------------- WDF Coinstaller installation
-[DestinationDirs]
-CoInstaller_CopyFiles = 11
-
-[androidusb.Dev.NT.CoInstallers]
-AddReg=CoInstaller_AddReg
-CopyFiles=CoInstaller_CopyFiles
-
-[CoInstaller_CopyFiles]
-wdfcoinstaller01005.dll
-
-[SourceDisksFiles]
-wdfcoinstaller01005.dll=1 ; make sure the number matches with SourceDisksNames
-
-[CoInstaller_AddReg]
-HKR,,CoInstallers32,0x00010000, "wdfcoinstaller01005.dll,WdfCoInstaller"
-
-[androidusb.Dev.NT.Wdf]
-KmdfService = androidusb, androidusb_wdfsect
-
-[androidusb_wdfsect]
-KmdfLibraryVersion = 1.5
-
-;---------------------------------------------------------------;
-
-[Strings]
-GOOG            = "Google, Inc"
-MfgName         = "Google, Inc"
-Disk_Description= "ADB Interface Installation Disk"
-androidusb.SvcDesc = "ADB Interface Driver"
-ClassName       = "ADB Interface"
-USB\VID_18D1&PID_DDDD.DeviceDescTest="ADB Testing Interface"
-USB\VID_0BB4&PID_0C01.DeviceDescRelease="HTC Dream"
-USB\VID_0BB4&PID_0C02&MI_01.DeviceDescRelease="HTC Dream Composite ADB Interface"
-USB\VID_0BB4&PID_0FFF.DeviceDescRelease="HTC Bootloader"
diff --git a/host/windows/usb/driver/android_usb.rc b/host/windows/usb/driver/android_usb.rc
deleted file mode 100644
index 3b19416..0000000
--- a/host/windows/usb/driver/android_usb.rc
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <windows.h>
-
-// Don't let the resource editor in here
-#ifdef APSTUDIO_INVOKED
-    #error this file is not editable by Visual C++
-#endif //APSTUDIO_INVOKED
-
-
-#define VER_FILETYPE    VFT_DRV
-#define VER_FILESUBTYPE VFT2_DRV_SYSTEM
-#define VER_FILEDESCRIPTION_STR     "ADB Interface"
-#define VER_INTERNALNAME_STR        "androidusb.sys"
-#define VER_ORIGINALFILENAME_STR    "androidusb.sys"
-#define VER_FILEOS VOS_NT
-#define VER_FILEFLAGSMASK (VS_FF_DEBUG | VS_FF_PRERELEASE)
-
-#if DBG
-  #define VER_FILEFLAGS     VS_FF_DEBUG | VS_FF_PRERELEASE
-#else  // DBG
-  #define VER_FILEFLAGS     VS_FF_PRERELEASE
-#endif // DBG
-
-#include "common.ver"
diff --git a/host/windows/usb/driver/android_usb.sln b/host/windows/usb/driver/android_usb.sln
deleted file mode 100644
index ac4cbe9..0000000
--- a/host/windows/usb/driver/android_usb.sln
+++ /dev/null
@@ -1,27 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 8.00
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "android_usb", "android_usb.vcproj", "{D980BE56-A7AB-4E05-919B-677FB7716307}"
-	ProjectSection(ProjectDependencies) = postProject
-	EndProjectSection
-EndProject
-Global
-	GlobalSection(SolutionConfiguration) = preSolution
-		Debug = Debug
-		Debug-64 = Debug-64
-		Release = Release
-		Release-64 = Release-64
-	EndGlobalSection
-	GlobalSection(ProjectConfiguration) = postSolution
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug.ActiveCfg = Debug|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug.Build.0 = Debug|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug-64.ActiveCfg = Debug-64|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug-64.Build.0 = Debug-64|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release.ActiveCfg = Release|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release.Build.0 = Release|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release-64.ActiveCfg = Release-64|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release-64.Build.0 = Release-64|Win32
-	EndGlobalSection
-	GlobalSection(ExtensibilityGlobals) = postSolution
-	EndGlobalSection
-	GlobalSection(ExtensibilityAddIns) = postSolution
-	EndGlobalSection
-EndGlobal
diff --git a/host/windows/usb/driver/android_usb.vcproj b/host/windows/usb/driver/android_usb.vcproj
deleted file mode 100644
index 5402b0c..0000000
--- a/host/windows/usb/driver/android_usb.vcproj
+++ /dev/null
@@ -1,1273 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="7.10"
-	Name="android_usb"
-	ProjectGUID="{D980BE56-A7AB-4E05-919B-677FB7716307}"
-	RootNamespace="android_usb"
-	Keyword="MakeFileProj">
-	<Platforms>
-		<Platform
-			Name="Win32"/>
-	</Platforms>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			OutputDirectory="Debug"
-			IntermediateDirectory="Debug"
-			ConfigurationType="0">
-			<Tool
-				Name="VCNMakeTool"
-				BuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -beEIFZ
-cd %PROJECTDIR%
-copy /Y android_usb.inf ..\build\debug\i386\android_usb.inf
-copy /Y C:\WINDDK\6000\redist\wdf\x86\WdfCoInstaller01005.dll ..\build\debug\i386
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\debug\i386 /os:XP_X86,Server2003_X86,Vista_X86
-"
-				ReBuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -cbeEIFZ
-cd %PROJECTDIR%
-copy /Y android_usb.inf ..\build\debug\i386\android_usb.inf
-copy /Y C:\WINDDK\6000\redist\wdf\x86\WdfCoInstaller01005.dll ..\build\debug\i386
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\debug\i386 /os:XP_X86,Server2003_X86,Vista_X86
-"
-				CleanCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -c0"/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			OutputDirectory="Release"
-			IntermediateDirectory="Release"
-			ConfigurationType="0">
-			<Tool
-				Name="VCNMakeTool"
-				BuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -beEIFZ
-cd %PROJECTDIR%
-copy /Y android_usb.inf ..\build\release\i386\android_usb.inf
-copy /Y C:\WINDDK\6000\redist\wdf\x86\WdfCoInstaller01005.dll ..\build\release\i386
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\release\i386 /os:XP_X86,Server2003_X86,Vista_X86
-"
-				ReBuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -cbeEIFZ
-cd %PROJECTDIR%
-copy /Y android_usb.inf ..\build\release\i386\android_usb.inf
-copy /Y C:\WINDDK\6000\redist\wdf\x86\WdfCoInstaller01005.dll ..\build\release\i386
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\release\i386 /os:XP_X86,Server2003_X86,Vista_X86
-"
-				CleanCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre WXP
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -c0"/>
-		</Configuration>
-		<Configuration
-			Name="Debug-64|Win32"
-			OutputDirectory="$(ConfigurationName)"
-			IntermediateDirectory="$(ConfigurationName)"
-			ConfigurationType="0">
-			<Tool
-				Name="VCNMakeTool"
-				BuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -beEIFZ
-cd %PROJECTDIR%
-copy android_usb.inf ..\build\debug\amd64\android_usb.inf
-copy C:\WINDDK\6000\redist\wdf\amd64\WdfCoInstaller01005.dll ..\build\debug\amd64
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\debug\amd64 /os:XP_X64,Server2003_X64,Vista_X64
-"
-				ReBuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -cbeEIFZ
-cd %PROJECTDIR%
-copy android_usb.inf ..\build\debug\amd64\android_usb.inf
-copy C:\WINDDK\6000\redist\wdf\amd64\WdfCoInstaller01005.dll ..\build\debug\amd64
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-SignTool sign /v /s AndroidTestCertStore /n Android /t http://timestamp.verisign.com/scripts/timestamp.dll ..\build\debug\amd64\androidusb.sys
-Inf2Cat /driver:..\build\debug\amd64 /os:XP_X64,Server2003_X64,Vista_X64
-SignTool sign /v /s AndroidTestCertStore /n Android /t http://timestamp.verisign.com/scripts/timestamp.dll ..\build\debug\amd64\androidusba64.cat"
-				CleanCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ chk AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -c0"/>
-		</Configuration>
-		<Configuration
-			Name="Release-64|Win32"
-			OutputDirectory="$(ConfigurationName)"
-			IntermediateDirectory="$(ConfigurationName)"
-			ConfigurationType="0">
-			<Tool
-				Name="VCNMakeTool"
-				BuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -beEIFZ
-cd %PROJECTDIR%
-copy android_usb.inf ..\build\release\amd64\android_usb.inf
-copy C:\WINDDK\6000\redist\wdf\amd64\WdfCoInstaller01005.dll ..\build\release\amd64
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\release\amd64 /os:XP_X64,Server2003_X64,Vista_X64
-"
-				ReBuildCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -cbeEIFZ
-cd %PROJECTDIR%
-copy android_usb.inf ..\build\release\amd64\android_usb.inf
-copy C:\WINDDK\6000\redist\wdf\amd64\WdfCoInstaller01005.dll ..\build\release\amd64
-set PATH=%PATH%;C:\WINDDK\6001.18001\bin\SelfSign
-Inf2Cat /driver:..\build\release\amd64 /os:XP_X64,Server2003_X64,Vista_X64
-"
-				CleanCommandLine="call C:\WinDDK\6000\bin\setenv.bat C:\WinDDK\6000\ fre AMD64 WNET
-set PROJECTDIR=$(ProjectDir)
-set DRIVE=%PROJECTDIR:~0,2%
-%DRIVE%
-cd %PROJECTDIR%
-build -c0"/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="Source Files"
-			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
-			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
-			<File
-				RelativePath=".\android_usb_device_object.cpp">
-			</File>
-			<File
-				RelativePath=".\android_usb_driver_object.cpp">
-			</File>
-			<File
-				RelativePath=".\android_usb_wdf_object.cpp">
-			</File>
-			<Filter
-				Name="File"
-				Filter="">
-				<File
-					RelativePath=".\android_usb_bulk_file_object.cpp">
-				</File>
-				<File
-					RelativePath=".\android_usb_device_file_object.cpp">
-				</File>
-				<File
-					RelativePath=".\android_usb_file_object.cpp">
-				</File>
-				<File
-					RelativePath=".\android_usb_interrupt_file_object.cpp">
-				</File>
-				<File
-					RelativePath=".\android_usb_pipe_file_object.cpp">
-				</File>
-			</Filter>
-		</Filter>
-		<Filter
-			Name="Header Files"
-			Filter="h;hpp;hxx;hm;inl;inc;xsd"
-			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
-			<File
-				RelativePath=".\android_usb_device_object.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_driver_defines.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_driver_object.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_inl.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_new_delete.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_pool_tags.h">
-			</File>
-			<File
-				RelativePath=".\android_usb_wdf_object.h">
-			</File>
-			<File
-				RelativePath=".\precomp.h">
-			</File>
-			<Filter
-				Name="DDK"
-				Filter="">
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\1394.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\61883.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\accctrl.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\acpiioct.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\amtvuids.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ata.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\atm.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\aux_klib.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\avc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\avcstrm.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\backpack.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bdasup.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bthddi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bthguid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bthioctl.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bthref.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\bthsdpddi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\buffring.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\classpnp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\clfs.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\clfslsn.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\clfsmsg.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\cloneviewhelper.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\cloneviewhelper.idl">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\codecapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\csq.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d3dhal.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d3dhalex.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d3dkmdt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d3dukmdt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d3dvec.inl">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d4drvif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\d4iface.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dciddi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dciman.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dderror.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dispmprt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dmusicks.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dmusics.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dmusprop.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\driverspecs.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\drivinit.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\drmk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dsfhrmports.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dsfif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dxapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\dxva9typ.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ExDispid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fcb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fcbtable.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\filterpipeline.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\filterpipelineutil.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fltKernel.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fltsafe.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fltUser.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fltUserStructures.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fltWinError.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\fsctlbuf.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hbaapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hbapiwmi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hdaudio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hidclass.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hidpddi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hidport.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\hubbusif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\i2cgpio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\imgerror.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\imgerror.idl">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ioaccess.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iointex.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ip6firewall.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ipfirewall.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ipinfo.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\irb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\irclass_ioctl.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsicfg.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsidef.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsierr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsifnd.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsilog.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsimgt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsiop.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\iscsiprf.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\isvbop.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\isvbop.inc">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\kbdmou.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ksi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\lmstats.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\lmuseflg.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\lmwksta.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\lowio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mcd.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mce.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mf.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\midatlax.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\miniport.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\minitape.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mmc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mountdev.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mountmgr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mrx.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mrxfcb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\msdadc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\msdaguid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\msdasc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mshtmhst.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\mshtml.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\msviddrv.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\namcache.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ndis.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ndisguid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ndistapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ndiswan.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ndr64types.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\netioddk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\netpnp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\nodetype.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\npapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntagp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntddk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntddnlb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntddpcm.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntddsd.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntddsfio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntifs.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntimage.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntintsafe.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntlmsp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntnls.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntpoapi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntrxdef.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntsam.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\ntstatus.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\api\ntstatus.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ntstrsafe.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\oledberr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\oprghdlr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\parallel.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\pciprop.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\pfhook.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\poclass.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portabledevice.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portabledeviceclassextension.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portabledeviceclassextension.idl">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portabledevicetypes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portabledevicetypes.idl">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\portcls.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\prefix.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\prnasnot.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ptpusd.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\punknown.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rdbss.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\richedit.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\richole.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rx.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxassert.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxce.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxcehdlr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxcommon.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxcontx.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxdata.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxdebug.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxexcept.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxlog.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxovride.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxpooltg.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxprocs.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxstruc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxtimer.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxtrace.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxtypes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\rxworkq.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\scarderr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\scavengr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\scsi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\scsiscan.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\scsiwmi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\sddef.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\sdplib.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\sdpnode.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\sffdisk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\sffprtcl.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\softehciif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\softhidusbif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\softusbif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\srb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\stdcall.inc">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\stdunk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\stiusd.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\storduid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\storport.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\storswtr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\stortrce.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\strmini.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\struchdr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\swenum.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\tdikrnl.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\tdistat.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\upssvc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\api\usb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\api\usb100.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb100.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usb200.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbbusif.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\api\usbdi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbdlib.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbdrivr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbkern.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbprint.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\USBProtocolDefs.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\usbscan.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\vcclr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\vfwext.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\video.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\videoagp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf10.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf10.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf11.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdf11.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfassert.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfassert.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfbugcodes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfbugcodes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfchildlist.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfchildlist.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcollection.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcollection.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcommonbuffer.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcommonbuffer.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcontrol.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcontrol.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcore.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfcore.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdevice.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdevice.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdmaenabler.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdmaenabler.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdmatransaction.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdmatransaction.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdpc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdpc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdriver.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfdriver.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffdo.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffdo.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffileobject.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffileobject.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffuncenum.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdffuncenum.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfglobals.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfglobals.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfinstaller.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfinstaller.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfinterrupt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfinterrupt.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfiotarget.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfiotarget.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfmemory.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfmemory.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfminiport.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfminiport.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfobject.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfobject.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfpdo.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfpdo.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfpool.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfpool.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfqueryinterface.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfqueryinterface.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfregistry.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfregistry.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfrequest.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfrequest.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfresource.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfresource.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfstatus.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfstatus.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfstring.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfstring.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfsync.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfsync.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftimer.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftimer.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftraceenums.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftraceenums.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftypes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdftypes.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfusb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfusb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfverifier.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfverifier.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfwmi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfwmi.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfworkitem.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\wdf\kmdf\10\wdfworkitem.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\..\..\..\..\Winddk\6000\inc\ddk\wdm.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wdm.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wdmguid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wdmsec.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wdmwarn4.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wia_lh.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wia_xp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiaintfc.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiamdef.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiamicro.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiamindr.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiamindr_lh.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiamindr_xp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiatwcmp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wiautil.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\WindowsSideShow.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\WindowsSideShowClassExtension.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\WindowsSideShowDriverEvents.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\Winusb.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\Winusbio.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wmidata.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wmiguid.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wmilib.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ws2san.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\ws2sdp.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\wsk.h">
-				</File>
-				<File
-					RelativePath="..\..\..\..\Winddk\6000\inc\ddk\xfilter.h">
-				</File>
-			</Filter>
-			<Filter
-				Name="File"
-				Filter="">
-				<File
-					RelativePath=".\android_usb_bulk_file_object.h">
-				</File>
-				<File
-					RelativePath=".\android_usb_device_file_object.h">
-				</File>
-				<File
-					RelativePath=".\android_usb_file_object.h">
-				</File>
-				<File
-					RelativePath=".\android_usb_interrupt_file_object.h">
-				</File>
-				<File
-					RelativePath=".\android_usb_pipe_file_object.h">
-				</File>
-			</Filter>
-			<Filter
-				Name="common"
-				Filter="">
-				<File
-					RelativePath="..\api\adb_api_extra.h">
-				</File>
-				<File
-					RelativePath="..\common\android_usb_common_defines.h">
-				</File>
-			</Filter>
-		</Filter>
-		<Filter
-			Name="Resource Files"
-			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
-			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">
-			<File
-				RelativePath=".\android_usb.rc">
-			</File>
-		</Filter>
-		<File
-			RelativePath=".\android_usb.inf">
-		</File>
-		<File
-			RelativePath=".\makefile">
-		</File>
-		<File
-			RelativePath=".\makefile.inc">
-		</File>
-		<File
-			RelativePath=".\sources">
-		</File>
-		<File
-			RelativePath=".\sources.inc">
-		</File>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
diff --git a/host/windows/usb/driver/android_usb_bulk_file_object.cpp b/host/windows/usb/driver/android_usb_bulk_file_object.cpp
deleted file mode 100644
index 9b3a59c..0000000
--- a/host/windows/usb/driver/android_usb_bulk_file_object.cpp
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbBulkPipeFileObject
-  that encapsulates extension to a bulk pipe file objects.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_bulk_file_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbBulkPipeFileObject::AndroidUsbBulkPipeFileObject(
-    AndroidUsbDeviceObject* dev_obj,
-    WDFFILEOBJECT wdf_fo,
-    WDFUSBPIPE wdf_pipe_obj)
-    : AndroidUsbPipeFileObject(dev_obj, wdf_fo, wdf_pipe_obj) {
-  ASSERT_IRQL_PASSIVE();
-
-#if DBG
-  WDF_USB_PIPE_INFORMATION pipe_info;
-  WDF_USB_PIPE_INFORMATION_INIT(&pipe_info);
-  WdfUsbTargetPipeGetInformation(wdf_pipe_obj, &pipe_info);
-  ASSERT(WdfUsbPipeTypeBulk == pipe_info.PipeType);
-#endif  // DBG
-}
-
-#pragma code_seg()
-
-AndroidUsbBulkPipeFileObject::~AndroidUsbBulkPipeFileObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_bulk_file_object.h b/host/windows/usb/driver/android_usb_bulk_file_object.h
deleted file mode 100644
index 8b75eee..0000000
--- a/host/windows/usb/driver/android_usb_bulk_file_object.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_BULK_PIPE_FILE_OBJECT_H__
-#define ANDROID_USB_BULK_PIPE_FILE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbBulkPipeFileObject
-  that encapsulates extension to a bulk pipe file objects.
-*/
-
-#include "android_usb_pipe_file_object.h"
-
-/** AndroidUsbBulkPipeFileObject class encapsulates extension to a KMDF file
-  object that represent opened bulk pipe. Instances of this class must be
-  allocated from NonPagedPool.
-*/
-class AndroidUsbBulkPipeFileObject : public AndroidUsbPipeFileObject {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-    @param dev_obj[in] Our device object for which this file has been created
-    @param wdf_fo[in] KMDF file object this extension wraps
-    @param wdf_pipe_obj[in] KMDF pipe for this file
-  */
-  AndroidUsbBulkPipeFileObject(AndroidUsbDeviceObject* dev_obj,
-                               WDFFILEOBJECT wdf_fo,
-                               WDFUSBPIPE wdf_pipe_obj);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   virtual ~AndroidUsbBulkPipeFileObject();
-};
-
-#endif  // ANDROID_USB_BULK_PIPE_FILE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_device_file_object.cpp b/host/windows/usb/driver/android_usb_device_file_object.cpp
deleted file mode 100644
index e134ebb..0000000
--- a/host/windows/usb/driver/android_usb_device_file_object.cpp
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbDeviceFileObject
-  that encapsulates an extension for a KMDF file object that represent
-  opened device.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_device_file_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbDeviceFileObject::AndroidUsbDeviceFileObject(
-    AndroidUsbDeviceObject* dev_obj,
-    WDFFILEOBJECT wdf_fo)
-    : AndroidUsbFileObject(AndroidUsbFileObjectTypeDevice, dev_obj, wdf_fo) {
-  ASSERT_IRQL_PASSIVE();
-}
-
-#pragma code_seg()
-
-AndroidUsbDeviceFileObject::~AndroidUsbDeviceFileObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-void AndroidUsbDeviceFileObject::OnEvtIoDeviceControl(WDFREQUEST request,
-                                                      size_t output_buf_len,
-                                                      size_t input_buf_len,
-                                                      ULONG ioctl_code) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  switch (ioctl_code) {
-    case ADB_IOCTL_GET_USB_DEVICE_DESCRIPTOR:
-      device_object()->OnGetUsbDeviceDescriptorCtl(request, output_buf_len);
-      break;
-
-    case ADB_IOCTL_GET_USB_CONFIGURATION_DESCRIPTOR:
-      device_object()->OnGetUsbConfigDescriptorCtl(request, output_buf_len);
-      break;
-
-    case ADB_IOCTL_GET_USB_INTERFACE_DESCRIPTOR:
-      device_object()->OnGetUsbInterfaceDescriptorCtl(request, output_buf_len);
-      break;
-
-    case ADB_IOCTL_GET_ENDPOINT_INFORMATION:
-      device_object()->OnGetEndpointInformationCtl(request,
-                                                   input_buf_len,
-                                                   output_buf_len);
-      break;
-
-    case ADB_IOCTL_GET_SERIAL_NUMBER:
-      device_object()->OnGetSerialNumberCtl(request, output_buf_len);
-      break;
-
-    default:
-      AndroidUsbFileObject::OnEvtIoDeviceControl(request,
-                                                 output_buf_len,
-                                                 input_buf_len,
-                                                 ioctl_code);
-      break;
-  }
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_device_file_object.h b/host/windows/usb/driver/android_usb_device_file_object.h
deleted file mode 100644
index c40bb50..0000000
--- a/host/windows/usb/driver/android_usb_device_file_object.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_DEVICE_FILE_OBJECT_H__
-#define ANDROID_USB_DEVICE_FILE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbDeviceFileObject that
-  encapsulates an extension for a KMDF file object that represent opened
-  device.
-*/
-
-#include "android_usb_file_object.h"
-
-/** AndroidUsbDeviceFileObject class encapsulates an extension for a KMDF
-  file object that represent opened device. Instances of this class must be
-  allocated from NonPagedPool.
-*/
-class AndroidUsbDeviceFileObject : public AndroidUsbFileObject  {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-    @param dev_obj[in] Our device object for which this file has been created
-    @param wdf_fo[in] KMDF file object this extension wraps
-  */
-  AndroidUsbDeviceFileObject(AndroidUsbDeviceObject* dev_obj,
-                             WDFFILEOBJECT wdf_fo);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   virtual ~AndroidUsbDeviceFileObject();
-
-  /** \brief IOCTL event handler
-
-    This method is called when a device control request comes to the file
-    object this extension wraps. We override this method to handle the
-    following IOCTL requests:
-      1. ADB_CTL_GET_USB_DEVICE_DESCRIPTOR
-      2. ADB_CTL_GET_USB_CONFIGURATION_DESCRIPTOR
-      3. ADB_CTL_GET_USB_INTERFACE_DESCRIPTOR
-      4. ADB_CTL_GET_ENDPOINT_INFORMATION
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param ioctl_code[in] The driver-defined or system-defined I/O control code
-           that is associated with the request.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoDeviceControl(WDFREQUEST request,
-                                    size_t output_buf_len,
-                                    size_t input_buf_len,
-                                    ULONG ioctl_code);
-};
-
-#endif  // ANDROID_USB_DEVICE_FILE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_device_object.cpp b/host/windows/usb/driver/android_usb_device_object.cpp
deleted file mode 100644
index b20c1b7..0000000
--- a/host/windows/usb/driver/android_usb_device_object.cpp
+++ /dev/null
@@ -1,1216 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbDeviceObject that
-  encapsulates an extension for KMDF device (FDO) object.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_device_object.h"
-#include "android_usb_file_object.h"
-#include "android_usb_device_file_object.h"
-#include "android_usb_pipe_file_object.h"
-#include "android_usb_bulk_file_object.h"
-#include "android_usb_interrupt_file_object.h"
-
-#pragma data_seg()
-
-/// Buffer for bulk read pipe name
-const WCHAR bulk_read_pipe_str[] = L"\\" DEVICE_BULK_READ_PIPE_NAME;
-
-/// Unicode string for bulk read pipe name
-UNICODE_STRING bulk_read_pipe_name = {
-  sizeof(bulk_read_pipe_str) - sizeof(WCHAR),
-  sizeof(bulk_read_pipe_str) - sizeof(WCHAR),
-  const_cast<PWSTR>(bulk_read_pipe_str)
-};
-
-/// Buffer for bulk write pipe name
-const WCHAR bulk_write_pipe_str[] = L"\\" DEVICE_BULK_WRITE_PIPE_NAME;
-
-/// Unicode string for bulk write pipe name
-UNICODE_STRING bulk_write_pipe_name = {
-  sizeof(bulk_write_pipe_str) - sizeof(WCHAR),
-  sizeof(bulk_write_pipe_str) - sizeof(WCHAR),
-  const_cast<PWSTR>(bulk_write_pipe_str)
-};
-
-/// Buffer for an index-based pipe name prefix
-const WCHAR index_pipe_prefix_str[] = L"\\" DEVICE_PIPE_NAME_PREFIX;
-
-/// Unicode string for index-based pipe name prefix
-UNICODE_STRING index_pipe_prefix = {
-  sizeof(index_pipe_prefix_str) - sizeof(WCHAR),
-  sizeof(index_pipe_prefix_str) - sizeof(WCHAR),
-  const_cast<PWSTR>(index_pipe_prefix_str)
-};
-
-/// GUID that sets class ID for our device
-const GUID android_guid = ANDROID_USB_CLASS_ID;
-
-#pragma code_seg("PAGE")
-
-AndroidUsbDeviceObject::AndroidUsbDeviceObject()
-    : AndroidUsbWdfObject(AndroidUsbWdfObjectTypeDevice),
-      wdf_target_device_(NULL),
-      wdf_usb_interface_(NULL),
-      serial_number_handle_(NULL),
-      serial_number_char_len_(0),
-      configured_pipes_num_(0),
-      bulk_read_pipe_index_(INVALID_UCHAR),
-      bulk_write_pipe_index_(INVALID_UCHAR),
-      configuration_descriptor_(NULL) {
-  ASSERT_IRQL_PASSIVE();
-}
-
-#pragma code_seg()
-
-AndroidUsbDeviceObject::~AndroidUsbDeviceObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  if (NULL != serial_number_handle_)
-    WdfObjectDelete(serial_number_handle_);
-}
-
-#pragma code_seg("PAGE")
-
-NTSTATUS AndroidUsbDeviceObject::CreateFDODevice(PWDFDEVICE_INIT device_init) {
-  ASSERT_IRQL_PASSIVE();
-
-  ASSERT(!IsTaretDeviceCreated());
-  if (IsTaretDeviceCreated())
-    return STATUS_INTERNAL_ERROR;
-
-  // Initialize our object attributes first
-  WDF_OBJECT_ATTRIBUTES device_attr;
-  NTSTATUS status = InitObjectAttributes(&device_attr, NULL);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Initialize the pnp_power_callbacks structure.  Callback events for PnP
-  // and Power are specified here. If we don't supply any callbacks, the
-  // KMDF will take appropriate default actions for an FDO device object.
-  // EvtDevicePrepareHardware and EvtDeviceReleaseHardware are major entry
-  // points for initializing / cleaning up our device. Probably, we can leave
-  // the rest to the framework.
-  WDF_PNPPOWER_EVENT_CALLBACKS pnp_power_callbacks;
-  WDF_PNPPOWER_EVENT_CALLBACKS_INIT(&pnp_power_callbacks);
-  pnp_power_callbacks.EvtDevicePrepareHardware =
-    EvtDevicePrepareHardwareEntry;
-  pnp_power_callbacks.EvtDeviceReleaseHardware =
-    EvtDeviceReleaseHardwareEntry;
-  WdfDeviceInitSetPnpPowerEventCallbacks(device_init, &pnp_power_callbacks);
-
-  // Initialize the request attributes to specify the context size and type
-  // for every request created by framework for this device.
-  WDF_OBJECT_ATTRIBUTES request_attr;
-  WDF_OBJECT_ATTRIBUTES_INIT(&request_attr);
-  WDF_OBJECT_ATTRIBUTES_SET_CONTEXT_TYPE(&request_attr, AndroidUsbWdfRequestContext);
-  WdfDeviceInitSetRequestAttributes(device_init, &request_attr);
-
-  // Initialize WDF_FILEOBJECT_CONFIG_INIT struct to tell the KMDF that we are
-  // interested in handling Create requests that get genereated when an
-  // application or another kernel component opens a handle through the device.
-  // We are not interested in receiving cleanup / close IRPs at this point.
-  WDF_FILEOBJECT_CONFIG file_config;
-  WDF_OBJECT_ATTRIBUTES file_attr;
-  WDF_FILEOBJECT_CONFIG_INIT(&file_config,
-                             EvtDeviceFileCreateEntry,
-                             WDF_NO_EVENT_CALLBACK,
-                             WDF_NO_EVENT_CALLBACK);
-  WDF_OBJECT_ATTRIBUTES_INIT(&file_attr);
-  WDF_OBJECT_ATTRIBUTES_SET_CONTEXT_TYPE(&file_attr,
-                                         AndroidUsbWdfObjectContext);
-  file_attr.EvtCleanupCallback = AndroidUsbWdfObject::EvtCleanupCallbackEntry;
-  file_attr.EvtDestroyCallback = AndroidUsbWdfObject::EvtDestroyCallbackEntry;
-  // We will provide our own synchronization for file access
-  file_attr.SynchronizationScope = WdfSynchronizationScopeNone;
-  WdfDeviceInitSetFileObjectConfig(device_init, &file_config, &file_attr);
-
-  // I/O type is buffered by default. It could be very inefficient if we have
-  // large reads / writes through our device.
-  WdfDeviceInitSetIoType(device_init, WdfDeviceIoDirect);
-
-  // DeviceInit is completely initialized. So call the framework
-  // to create the device and attach it to the lower stack.
-  WDFDEVICE wdf_dev = NULL;
-  status = WdfDeviceCreate(&device_init, &device_attr, &wdf_dev);
-  ASSERT(NT_SUCCESS(status) && (NULL != wdf_dev));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Save handle to the created device
-  set_wdf_object(wdf_dev);
-
-  // Tell the framework to set the SurpriseRemovalOK in the DeviceCaps so
-  // that we don't get the popup in usermode (on Win2K) when we surprise
-  // remove the device.
-  WDF_DEVICE_PNP_CAPABILITIES pnp_caps;
-  WDF_DEVICE_PNP_CAPABILITIES_INIT(&pnp_caps);
-  pnp_caps.SurpriseRemovalOK = WdfTrue;
-  WdfDeviceSetPnpCapabilities(wdf_device(), &pnp_caps);
-
-  // Create our default queue object for this device to start receiving I/O
-  status = CreateDefaultQueue();
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Register a device interface so that app can find our device and talk to it.
-  status = WdfDeviceCreateDeviceInterface(wdf_device(), &android_guid, NULL);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Initialize our extension to that device. We will do this at the very end
-  // so we know that we successfully passed entire device create chain when
-  // we are called with other callbacks to that device.
-  status = InitializeContext();
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  return STATUS_SUCCESS;
-}
-
-NTSTATUS AndroidUsbDeviceObject::ResetDevice() {
-  ASSERT_IRQL_PASSIVE();
-
-  if (!IsTaretDeviceCreated())
-    return STATUS_SUCCESS;
-
-  // Reset the device
-  NTSTATUS status =
-    status = WdfUsbTargetDeviceResetPortSynchronously(wdf_target_device());
-
-  // !!!!! Note that after the call to WdfUsbTargetDeviceResetPortSynchronously
-  // this object may be no longer valid !!!!!
-
-  if (!NT_SUCCESS(status))
-    GoogleDbgPrint("\n!!!!! AndroidUsbDeviceObject::ResetDevice failed %X", status);
-
-  return status;
-}
-
-NTSTATUS AndroidUsbDeviceObject::OnEvtDevicePrepareHardware(
-    WDFCMRESLIST resources_raw,
-    WDFCMRESLIST resources_translated) {
-  ASSERT_IRQL_PASSIVE();
-
-  // Create a USB device handle so that we can communicate with the underlying
-  // USB stack. The wdf_target_device_ handle is used to query, configure, and
-  // manage all aspects of the USB device. These aspects include device
-  // properties, bus properties, and I/O creation and synchronization. This
-  // call gets the device and configuration descriptors and stores them in
-  // wdf_target_device_ object.
-  NTSTATUS status = WdfUsbTargetDeviceCreate(wdf_device(),
-                                             WDF_NO_OBJECT_ATTRIBUTES,
-                                             &wdf_target_device_);
-  ASSERT(NT_SUCCESS(status) && (NULL != wdf_target_device_));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Retrieve USBD version information, port driver capabilites and device
-  // capabilites such as speed, power, etc.
-  WDF_USB_DEVICE_INFORMATION_INIT(&usb_device_info_);
-  status = WdfUsbTargetDeviceRetrieveInformation(wdf_target_device(),
-                                                 &usb_device_info_);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  WdfUsbTargetDeviceGetDeviceDescriptor(wdf_target_device(),
-                                        &usb_device_descriptor_);
-#if DBG
-  PrintUsbTargedDeviceInformation(usb_device_info());
-  PrintUsbDeviceDescriptor(&usb_device_descriptor_);
-#endif  // DBG
-
-  // Save device serial number
-  status =

-    WdfUsbTargetDeviceAllocAndQueryString(wdf_target_device(),

-                                          WDF_NO_OBJECT_ATTRIBUTES,

-                                          &serial_number_handle_,

-                                          &serial_number_char_len_,

-                                          usb_device_descriptor_.iSerialNumber,

-                                          0x0409);  // English (US)

-  if (!NT_SUCCESS(status))

-    return status;

-

-#if DBG

-  UNICODE_STRING ser_num;

-  ser_num.Length = serial_number_byte_len();

-  ser_num.MaximumLength = ser_num.Length;

-  ser_num.Buffer = const_cast<WCHAR*>

-    (serial_number());

-  GoogleDbgPrint("\n*** Device serial number %wZ", &ser_num);

-#endif  // DBG

-

-  // Configure our device now
-  status = ConfigureDevice();
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Select device interfaces
-  status = SelectInterfaces();
-  if (!NT_SUCCESS(status))
-    return status;
-
-  return status;
-}
-
-NTSTATUS AndroidUsbDeviceObject::OnEvtDeviceReleaseHardware(
-    WDFCMRESLIST resources_translated) {
-  ASSERT_IRQL_PASSIVE();
-
-  // It's possible that Preparehardware failed half way thru. So make
-  // sure the target device exists.
-  if (!IsTaretDeviceCreated())
-    return STATUS_SUCCESS;
-
-  // Cancel all the currently queued I/O. This is better than sending an
-  // explicit USB abort request down because release hardware gets
-  // called even when the device surprise-removed.
-  WdfIoTargetStop(WdfUsbTargetDeviceGetIoTarget(wdf_target_device()),
-                  WdfIoTargetCancelSentIo);
-
-  // Unselect all selected configurations
-  WDF_USB_DEVICE_SELECT_CONFIG_PARAMS config_params;
-  WDF_USB_DEVICE_SELECT_CONFIG_PARAMS_INIT_DECONFIG(&config_params);
-
-  NTSTATUS status = WdfUsbTargetDeviceSelectConfig(wdf_target_device(),
-                                                   WDF_NO_OBJECT_ATTRIBUTES,
-                                                   &config_params);
-  ASSERT(NT_SUCCESS(status) || (STATUS_DEVICE_NOT_CONNECTED == status));
-  return status;
-}
-
-void AndroidUsbDeviceObject::OnEvtDeviceFileCreate(WDFREQUEST request,
-                                                   WDFFILEOBJECT wdf_fo) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(IsInterfaceSelected());
-  if (!IsInterfaceSelected()) {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_STATE);
-    return;
-  }
-
-  PUNICODE_STRING file_name = WdfFileObjectGetFileName(wdf_fo);
-  ASSERT(NULL != file_name);
-  if (NULL == file_name) {
-    WdfRequestComplete(request, STATUS_OBJECT_NAME_INVALID);
-    return;
-  }
-
-  WDFUSBPIPE wdf_pipe_obj = NULL;
-  WDF_USB_PIPE_INFORMATION pipe_info;
-
-  // TODO: Share / access check here?
-
-  // Lets see if this is a device open
-  if (0 != file_name->Length) {
-    // This is a pipe open. Lets retrieve pipe index from the name
-    UCHAR pipe_index = GetPipeIndexFromFileName(file_name);
-    if (INVALID_UCHAR == pipe_index) {
-      GoogleDbgPrint("\n!!!!! There is no pipe index for file %wZ", file_name);
-      WdfRequestComplete(request, STATUS_OBJECT_NAME_INVALID);
-      return;
-    }
-
-    // Make sure that pipe index doesn't exceed number of pipes
-    if (pipe_index >= configured_pipes_num()) {
-      WdfRequestComplete(request, STATUS_OBJECT_NAME_NOT_FOUND);
-      return;
-    }
-
-    // Retrieve the pipe along with the pipe info
-    WDF_USB_PIPE_INFORMATION_INIT(&pipe_info);
-    wdf_pipe_obj = WdfUsbInterfaceGetConfiguredPipe(wdf_usb_interface(),
-                                                    pipe_index,
-                                                    &pipe_info);
-    if (NULL == wdf_pipe_obj) {
-      GoogleDbgPrint("\n!!!!! There is no pipe for index %u for file %wZ",
-                     pipe_index, file_name);
-      WdfRequestComplete(request, STATUS_OBJECT_NAME_NOT_FOUND);
-      return;
-    }
-  }
-
-  // If we're here this must be either device open or pipe open
-  ASSERT((NULL != wdf_pipe_obj) || (0 == file_name->Length));
-
-  // Create our file object extension for this file
-  AndroidUsbFileObject* wdf_file_ext = NULL;
-  NTSTATUS status;
-
-  if (0 == file_name->Length) {
-    // This is a device FO. Create wrapper for device FO
-    ASSERT(NULL == wdf_pipe_obj);
-    wdf_file_ext = new(NonPagedPool, GANDR_POOL_TAG_DEVICE_FO)
-      AndroidUsbDeviceFileObject(this, wdf_fo);
-    ASSERT(NULL != wdf_file_ext);
-    if (NULL == wdf_file_ext) {
-      WdfRequestComplete(request, STATUS_INSUFFICIENT_RESOURCES);
-      return;
-    }
-
-    // Initialize extension
-    status = wdf_file_ext->Initialize();
-    if (!NT_SUCCESS(status)) {
-      delete wdf_file_ext;
-      WdfRequestComplete(request, status);
-      return;
-    }
-  } else {
-    // This is a pipe file. Create and initialize appropriate extension for it.
-    status =
-      CreatePipeFileObjectExt(wdf_fo, wdf_pipe_obj, &pipe_info, &wdf_file_ext);
-    ASSERT((NULL != wdf_file_ext) || !NT_SUCCESS(status));
-    if (!NT_SUCCESS(status)) {
-      WdfRequestComplete(request, status);
-      return;
-    }
-  }
-  ASSERT(GetAndroidUsbFileObjectFromHandle(wdf_fo) == wdf_file_ext);
-  WdfRequestComplete(request, STATUS_SUCCESS);
-}
-
-NTSTATUS AndroidUsbDeviceObject::EvtDevicePrepareHardwareEntry(
-    WDFDEVICE wdf_dev,
-    WDFCMRESLIST resources_raw,
-    WDFCMRESLIST resources_translated) {
-  ASSERT_IRQL_PASSIVE();
-
-  // Get our wrapper for the device and redirect event to its handler
-  AndroidUsbDeviceObject* wdf_device_ext =
-    GetAndroidUsbDeviceObjectFromHandle(wdf_dev);
-  ASSERT(NULL != wdf_device_ext);
-  return (NULL != wdf_device_ext) ?
-    wdf_device_ext->OnEvtDevicePrepareHardware(resources_raw,
-                                               resources_translated) :
-    STATUS_INVALID_DEVICE_REQUEST;
-}
-
-NTSTATUS AndroidUsbDeviceObject::EvtDeviceReleaseHardwareEntry(
-    WDFDEVICE wdf_dev,
-    WDFCMRESLIST resources_translated) {
-  ASSERT_IRQL_PASSIVE();
-
-  // Get our wrapper for the device and redirect event to its handler
-  AndroidUsbDeviceObject* wdf_device_ext =
-    GetAndroidUsbDeviceObjectFromHandle(wdf_dev);
-  ASSERT(NULL != wdf_device_ext);
-  return (NULL != wdf_device_ext) ?
-    wdf_device_ext->OnEvtDeviceReleaseHardware(resources_translated) :
-    STATUS_INVALID_DEVICE_REQUEST;
-}
-
-void AndroidUsbDeviceObject::EvtDeviceFileCreateEntry(
-    WDFDEVICE wdf_dev,
-    WDFREQUEST request,
-    WDFFILEOBJECT wdf_fo) {
-  ASSERT_IRQL_PASSIVE();
-
-  ASSERT(NULL != wdf_fo);
-  if (NULL == wdf_fo) {
-    WdfRequestComplete(request, STATUS_INVALID_PARAMETER);
-    return;
-  }
-
-  // Get our wrapper for the device and redirect event to its handler
-  AndroidUsbDeviceObject* wdf_device_ext =
-    GetAndroidUsbDeviceObjectFromHandle(wdf_dev);
-  ASSERT(NULL != wdf_device_ext);
-  if (NULL != wdf_device_ext) {
-    wdf_device_ext->OnEvtDeviceFileCreate(request, wdf_fo);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-#pragma code_seg()
-
-void AndroidUsbDeviceObject::OnEvtIoRead(WDFREQUEST request,
-                                         size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(IsInterfaceSelected());
-  if (!IsInterfaceSelected()) {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_STATE);
-    return;
-  }
-
-  // Get our file extension and dispatch this event to its handler
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->OnEvtIoRead(request, length);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::OnEvtIoWrite(WDFREQUEST request,
-                                          size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(IsInterfaceSelected());
-  if (!IsInterfaceSelected()) {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_STATE);
-    return;
-  }
-
-  // Get our file extension and dispatch this event to its handler
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->OnEvtIoWrite(request, length);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::OnEvtIoDeviceControl(WDFREQUEST request,
-                                                  size_t output_buf_len,
-                                                  size_t input_buf_len,
-                                                  ULONG ioctl_code) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(IsInterfaceSelected());
-  if (!IsInterfaceSelected()) {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_STATE);
-    return;
-  }
-
-  // Get our file extension and dispatch this event to its handler
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->OnEvtIoDeviceControl(request,
-                                       output_buf_len,
-                                       input_buf_len,
-                                       ioctl_code);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::EvtIoReadEntry(WDFQUEUE queue,
-                                            WDFREQUEST request,
-                                            size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Get our file extension and dispatch this event to the appropriate handler
-  // inside our device extension.
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->device_object()->OnEvtIoRead(request, length);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::EvtIoWriteEntry(WDFQUEUE queue,
-                                            WDFREQUEST request,
-                                            size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Get our file extension and dispatch this event to the appropriate handler
-  // inside our device extension.
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->device_object()->OnEvtIoWrite(request, length);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::EvtIoDeviceControlEntry(WDFQUEUE queue,
-                                                    WDFREQUEST request,
-                                                    size_t output_buf_len,
-                                                    size_t input_buf_len,
-                                                    ULONG ioctl_code) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Get our file extension and dispatch this event to the appropriate handler
-  // inside our device extension.
-  AndroidUsbFileObject* wdf_file_ext =
-    GetAndroidUsbFileObjectForRequest(request);
-  ASSERT(NULL != wdf_file_ext);
-  if (NULL != wdf_file_ext) {
-    wdf_file_ext->device_object()->OnEvtIoDeviceControl(request,
-                                                        output_buf_len,
-                                                        input_buf_len,
-                                                        ioctl_code);
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::OnGetUsbDeviceDescriptorCtl(WDFREQUEST request,
-                                                         size_t output_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Check the buffer first
-  if (output_buf_len >= sizeof(USB_DEVICE_DESCRIPTOR)) {
-    // Get the output buffer
-    NTSTATUS status;
-    void* ret_info = OutAddress(request, &status);
-    ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-    if (NT_SUCCESS(status)) {
-      // Copy requested info into output buffer and complete request
-      RtlCopyMemory(ret_info,
-                    usb_device_descriptor(),
-                    sizeof(USB_DEVICE_DESCRIPTOR));
-
-      WdfRequestCompleteWithInformation(request,
-                                        STATUS_SUCCESS,
-                                        sizeof(USB_DEVICE_DESCRIPTOR));
-    } else {
-      WdfRequestComplete(request, status);
-    }
-  } else {
-    WdfRequestCompleteWithInformation(request,
-                                      STATUS_BUFFER_TOO_SMALL,
-                                      sizeof(USB_DEVICE_DESCRIPTOR));
-  }
-}
-
-void AndroidUsbDeviceObject::OnGetUsbConfigDescriptorCtl(WDFREQUEST request,
-                                                         size_t output_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  if (NULL != configuration_descriptor()) {
-    // Check the buffer first
-    if (output_buf_len >= sizeof(USB_CONFIGURATION_DESCRIPTOR)) {
-      // Get the output buffer
-      NTSTATUS status;
-      void* ret_info = OutAddress(request, &status);
-      ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-      if (NT_SUCCESS(status)) {
-        // Copy requested info into output buffer and complete request
-        RtlCopyMemory(ret_info,
-                      configuration_descriptor(),
-                      sizeof(USB_CONFIGURATION_DESCRIPTOR));
-
-        WdfRequestCompleteWithInformation(request,
-                                          STATUS_SUCCESS,
-                                          sizeof(USB_CONFIGURATION_DESCRIPTOR));
-      } else {
-        WdfRequestComplete(request, status);
-      }
-    } else {
-      WdfRequestCompleteWithInformation(request,
-                                        STATUS_BUFFER_TOO_SMALL,
-                                        sizeof(USB_CONFIGURATION_DESCRIPTOR));
-    }
-  } else {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-  }
-}
-
-void AndroidUsbDeviceObject::OnGetUsbInterfaceDescriptorCtl(WDFREQUEST request,
-                                                            size_t output_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Check the buffer first
-  if (output_buf_len >= sizeof(USB_INTERFACE_DESCRIPTOR)) {
-    // Get the output buffer
-    NTSTATUS status;
-    void* ret_info = OutAddress(request, &status);
-    ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-    if (NT_SUCCESS(status)) {
-      // Copy requested info into output buffer and complete request
-      RtlCopyMemory(ret_info,
-                    interface_descriptor(),
-                    sizeof(USB_INTERFACE_DESCRIPTOR));
-
-      WdfRequestCompleteWithInformation(request,
-                                        STATUS_SUCCESS,
-                                        sizeof(USB_INTERFACE_DESCRIPTOR));
-    } else {
-      WdfRequestComplete(request, status);
-    }
-  } else {
-    WdfRequestCompleteWithInformation(request,
-                                      STATUS_BUFFER_TOO_SMALL,
-                                      sizeof(USB_INTERFACE_DESCRIPTOR));
-  }
-}
-
-void AndroidUsbDeviceObject::OnGetEndpointInformationCtl(
-    WDFREQUEST request,
-    size_t input_buf_len,
-    size_t output_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Check the buffers first
-  if (input_buf_len < sizeof(AdbQueryEndpointInformation)) {
-    WdfRequestComplete(request, STATUS_INVALID_BUFFER_SIZE);
-    return;
-  }
-
-  if (output_buf_len < sizeof(AdbEndpointInformation)) {
-    WdfRequestCompleteWithInformation(request,
-                                      STATUS_BUFFER_TOO_SMALL,
-                                      sizeof(AdbEndpointInformation));
-    return;
-  }
-
-  // Get the output buffer
-  NTSTATUS status;
-  AdbEndpointInformation* ret_info = reinterpret_cast<AdbEndpointInformation*>
-    (OutAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Get the input buffer
-  AdbQueryEndpointInformation* in = reinterpret_cast<AdbQueryEndpointInformation*>
-    (InAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != in));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Lets see what exactly is queried
-  UCHAR endpoint_index = in->endpoint_index;
-  if (ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX == endpoint_index)
-    endpoint_index = bulk_write_pipe_index();
-  else if (ADB_QUERY_BULK_READ_ENDPOINT_INDEX == endpoint_index)
-    endpoint_index = bulk_read_pipe_index();
-
-  // Make sure index is valid and within interface range
-  if ((INVALID_UCHAR == endpoint_index) ||
-      (endpoint_index >= configured_pipes_num())) {
-    WdfRequestComplete(request, STATUS_NOT_FOUND);
-    return;
-  }
-
-  // Get endpoint information
-  WDF_USB_PIPE_INFORMATION pipe_info;
-  WDF_USB_PIPE_INFORMATION_INIT(&pipe_info);
-  WDFUSBPIPE wdf_pipe_obj =
-      WdfUsbInterfaceGetConfiguredPipe(wdf_usb_interface(), endpoint_index, &pipe_info);
-  if (NULL == wdf_pipe_obj) {
-    WdfRequestComplete(request, STATUS_NOT_FOUND);
-    return;
-  }
-
-  // Copy endpoint info to the output
-  ret_info->max_packet_size = pipe_info.MaximumPacketSize;
-  ret_info->endpoint_address = pipe_info.EndpointAddress;
-  ret_info->polling_interval = pipe_info.Interval;
-  ret_info->setting_index = pipe_info.SettingIndex;
-  ret_info->endpoint_type = static_cast<AdbEndpointType>(pipe_info.PipeType);
-  ret_info->max_transfer_size = pipe_info.MaximumTransferSize;
-
-  WdfRequestCompleteWithInformation(request,
-                                    STATUS_SUCCESS,
-                                    sizeof(AdbEndpointInformation));
-}
-
-void AndroidUsbDeviceObject::OnGetSerialNumberCtl(WDFREQUEST request,
-                                                  size_t output_buf_len) {
-  ASSERT_IRQL_LOW();
-
-  if (NULL == serial_number()) {
-    // There is no serial number saved for this device!
-    WdfRequestComplete(request, STATUS_INTERNAL_ERROR);
-    return;
-  }
-
-  size_t expected_len = serial_number_byte_len() + sizeof(WCHAR);
-
-  // Check the buffer first
-  if (output_buf_len >= expected_len) {
-    // Get the output buffer
-    NTSTATUS status;
-    WCHAR* ret_info = reinterpret_cast<WCHAR*>(OutAddress(request, &status));
-    ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-    if (NT_SUCCESS(status)) {
-      // Copy serial number
-      RtlCopyMemory(ret_info, serial_number(), serial_number_byte_len());
-      ret_info[serial_number_char_len()] = L'\0';
-      WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, expected_len);
-    } else {
-      WdfRequestComplete(request, status);
-    }
-  } else {
-    WdfRequestCompleteWithInformation(request,
-                                      STATUS_BUFFER_TOO_SMALL,
-                                      sizeof(expected_len));
-  }
-}
-
-#pragma code_seg("PAGE")
-
-NTSTATUS AndroidUsbDeviceObject::CreateDefaultQueue() {
-  ASSERT_IRQL_PASSIVE();
-
-  // Register I/O callbacks to tell the framework that we are interested
-  // in handling WdfRequestTypeRead, WdfRequestTypeWrite, and
-  // WdfRequestTypeDeviceControl requests. WdfIoQueueDispatchParallel means
-  // that we are capable of handling all the I/O request simultaneously and we
-  // are responsible for protecting data that could be accessed by these
-  // callbacks simultaneously. This queue will be, by default, automanaged by
-  // the framework with respect to PnP and Power events. That is, framework
-  // will take care of queuing, failing, dispatching incoming requests based
-  // on the current PnP / Power state of the device. We also need to register
-  // a EvtIoStop handler so that we can acknowledge requests that are pending
-  // at the target driver.
-  WDF_IO_QUEUE_CONFIG io_queue_config;
-  WDF_IO_QUEUE_CONFIG_INIT_DEFAULT_QUEUE(&io_queue_config,
-                                         WdfIoQueueDispatchParallel);
-
-  io_queue_config.EvtIoDeviceControl = EvtIoDeviceControlEntry;
-  io_queue_config.EvtIoRead = EvtIoReadEntry;
-  io_queue_config.EvtIoWrite = EvtIoWriteEntry;
-  io_queue_config.AllowZeroLengthRequests = TRUE;
-  // By default KMDF will take care of the power management of this queue
-  io_queue_config.PowerManaged = WdfUseDefault;
-
-  // Create queue object
-  WDFQUEUE wdf_queue_obj = NULL;
-  NTSTATUS status = WdfIoQueueCreate(wdf_device(),
-                                     &io_queue_config,
-                                     WDF_NO_OBJECT_ATTRIBUTES,
-                                     &wdf_queue_obj);
-  ASSERT(NT_SUCCESS(status) && (NULL != wdf_queue_obj));
-  if (!NT_SUCCESS(status))
-    return status;
-  return STATUS_SUCCESS;
-}
-
-NTSTATUS AndroidUsbDeviceObject::ConfigureDevice() {
-  ASSERT_IRQL_PASSIVE();
-
-  ASSERT(IsTaretDeviceCreated());
-  if (!IsTaretDeviceCreated())
-    return STATUS_INTERNAL_ERROR;
-
-  // In order to get the configuration descriptor we must first query for its
-  // size (by supplying NULL for the descriptor's address), allocate enough
-  // memory and then retrieve the descriptor.
-  USHORT size = 0;
-
-  // Query descriptor size first
-  NTSTATUS status =
-    WdfUsbTargetDeviceRetrieveConfigDescriptor(wdf_target_device(),
-                                               WDF_NO_HANDLE,
-                                               &size);
-  ASSERT((status == STATUS_BUFFER_TOO_SMALL) || !NT_SUCCESS(status));
-  if (status != STATUS_BUFFER_TOO_SMALL)
-    return status;
-
-  // Create a memory object and specify our device as the parent so that
-  // it will be freed automatically along with our device.
-  WDFMEMORY memory = NULL;
-  WDF_OBJECT_ATTRIBUTES attributes;
-  WDF_OBJECT_ATTRIBUTES_INIT(&attributes);
-  attributes.ParentObject = wdf_device();
-  status = WdfMemoryCreate(&attributes,
-                           NonPagedPool,
-                           GANDR_POOL_TAG_DEV_CFG_DESC,
-                           size,
-                           &memory,
-                           reinterpret_cast<PVOID*>(&configuration_descriptor_));
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Now retrieve configuration descriptor
-  status =
-    WdfUsbTargetDeviceRetrieveConfigDescriptor(wdf_target_device(),
-                                               configuration_descriptor_,
-                                               &size);
-  ASSERT(NT_SUCCESS(status) && (NULL != configuration_descriptor_));
-  if (!NT_SUCCESS(status))
-    return status;
-
-#if DBG
-  PrintConfigDescriptor(configuration_descriptor(), size);
-#endif  // DBG
-
-  return status;
-}
-
-NTSTATUS AndroidUsbDeviceObject::SelectInterfaces() {
-  ASSERT_IRQL_PASSIVE();
-
-  ASSERT(IsDeviceConfigured());
-  if (!IsDeviceConfigured())
-    return STATUS_INTERNAL_ERROR;
-
-  WDF_USB_DEVICE_SELECT_CONFIG_PARAMS config_params;
-  PWDF_USB_INTERFACE_SETTING_PAIR pairs = NULL;
-  // TODO: We need to find a way (possibly by looking at each
-  // interface descriptor) to get index of the ADB interface in multiinterface
-  // configuration.
-  UCHAR adb_interface_index = 0;
-
-  if (IsSingleInterfaceDevice()) {
-    // Our device has only one interface, so we don't have to bother with
-    // multiple interfaces at all.
-    GoogleDbgPrint("\n********** Device reports single interface");
-    // Select single interface configuration
-    WDF_USB_DEVICE_SELECT_CONFIG_PARAMS_INIT_SINGLE_INTERFACE(&config_params);
-  } else {
-    // Configure multiple interfaces
-    ULONG num_interf = GetInterfaceCount();
-    GoogleDbgPrint("\n********** Device reports %u interfaces",
-             num_interf);
-
-    // Allocate pairs for each interface
-    pairs = new(PagedPool, GANDR_POOL_TAG_INTERF_PAIRS)
-              WDF_USB_INTERFACE_SETTING_PAIR[num_interf];
-    ASSERT(NULL != pairs);
-    if (NULL == pairs)
-      return STATUS_INSUFFICIENT_RESOURCES;
-
-    adb_interface_index = 1;
-    // Initialize each interface pair
-    for (UCHAR pair = 0; pair < num_interf; pair++) {
-      pairs[pair].SettingIndex = 0;
-      pairs[pair].UsbInterface =
-        WdfUsbTargetDeviceGetInterface(wdf_target_device(), pair);
-      ASSERT(NULL != pairs[pair].UsbInterface);
-      if (NULL == pairs[pair].UsbInterface) {
-        delete[] pairs;
-        return STATUS_INTERNAL_ERROR;
-      }
-    }
-
-    // Select multiinterface configuration
-    WDF_USB_DEVICE_SELECT_CONFIG_PARAMS_INIT_MULTIPLE_INTERFACES(&config_params,
-                                                                 (UCHAR)num_interf,
-                                                                 pairs);
-  }
-
-  NTSTATUS status =
-    WdfUsbTargetDeviceSelectConfig(wdf_target_device(),
-                                   WDF_NO_OBJECT_ATTRIBUTES,
-                                   &config_params);
-  if (NULL != pairs)
-    delete[] pairs;
-
-  // ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-#if DBG
-  PrintSelectedConfig(&config_params);
-#endif  // DBG
-
-  wdf_usb_interface_ =
-    WdfUsbTargetDeviceGetInterface(wdf_target_device(), adb_interface_index);
-  ASSERT(NULL != wdf_usb_interface_);
-  if (NULL == wdf_usb_interface_)
-    return STATUS_INTERNAL_ERROR;
-
-  configured_pipes_num_ = WdfUsbInterfaceGetNumEndpoints(wdf_usb_interface(), 0);
-  ASSERT(0 != configured_pipes_num_);
-
-  // Cache selected interface descriptor
-  BYTE setting_index =
-    WdfUsbInterfaceGetConfiguredSettingIndex(wdf_usb_interface());
-
-  WdfUsbInterfaceGetDescriptor(wdf_usb_interface(),
-                               setting_index,
-                               &interface_descriptor_);
-
-#if DBG
-  PrintInterfaceDescriptor(interface_descriptor());
-#endif  // DBG
-
-  // Iterate over pipes, decoding and saving info about bulk r/w pipes for
-  // easier and faster addressing later on when they get opened
-  for (UCHAR pipe = 0; pipe < configured_pipes_num(); pipe++) {
-    WDF_USB_PIPE_INFORMATION pipe_info;
-    WDF_USB_PIPE_INFORMATION_INIT(&pipe_info);
-    WDFUSBPIPE wdf_pipe_obj =
-      WdfUsbInterfaceGetConfiguredPipe(wdf_usb_interface(), pipe, &pipe_info);
-    ASSERT(NULL != wdf_pipe_obj);
-    if (NULL != wdf_pipe_obj) {
-      if ((WdfUsbPipeTypeBulk  == pipe_info.PipeType) &&
-          WDF_USB_PIPE_DIRECTION_IN(pipe_info.EndpointAddress)) {
-        // This is a bulk read pipe
-        ASSERT(!IsBulkReadPipeKnown());
-        bulk_read_pipe_index_ = pipe;
-      } else {
-        ASSERT(!IsBulkWritePipeKnown());
-        bulk_write_pipe_index_ = pipe;
-      }
-    }
-#if DBG
-    PrintPipeInformation(&pipe_info, pipe);
-#endif  // DBG
-  }
-
-  // At the end we must have calculated indexes for both,
-  // bulk read and write pipes
-  ASSERT(!NT_SUCCESS(status) || (IsBulkReadPipeKnown() &&
-                                 IsBulkWritePipeKnown()));
-
-  return status;
-}
-
-UCHAR AndroidUsbDeviceObject::GetPipeIndexFromFileName(
-    PUNICODE_STRING file_path) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT((NULL != file_path) && (0 != file_path->Length) && (NULL != file_path->Buffer));
-  if ((NULL == file_path) ||
-      (0 == file_path->Length) ||
-      (NULL == file_path->Buffer)) {
-    return INVALID_UCHAR;
-  }
-
-  // Lets check for explicit r/w pipe names
-  if (0 == RtlCompareUnicodeString(file_path, &bulk_read_pipe_name, TRUE))
-    return bulk_read_pipe_index();
-  if (0 == RtlCompareUnicodeString(file_path, &bulk_write_pipe_name, TRUE))
-    return bulk_write_pipe_index();
-
-  // Lets check path format
-  if (file_path->Length <= index_pipe_prefix.Length) {
-    GoogleDbgPrint("\n!!!!! Bad format for pipe name: %wZ", file_path);
-    return INVALID_UCHAR;
-  }
-
-  // Now when whe know that file_path->Length is sufficient lets match this
-  // path with the prefix
-  UNICODE_STRING prefix_match = *file_path;
-  prefix_match.Length = index_pipe_prefix.Length;
-  prefix_match.MaximumLength = prefix_match.Length;
-
-  if (0 != RtlCompareUnicodeString(&prefix_match, &index_pipe_prefix, TRUE)) {
-    GoogleDbgPrint("\n!!!!! Bad format for pipe name: %wZ", file_path);
-    return INVALID_UCHAR;
-  }
-
-  // Prefix matches. Make sure that remaining chars are all decimal digits.
-  // Pipe index begins right after the prefix ends.
-  const ULONG index_begins_at = WcharLen(index_pipe_prefix.Length);
-  const ULONG name_len = WcharLen(file_path->Length);
-  for (ULONG index = index_begins_at; index < name_len; index++) {
-    if ((file_path->Buffer[index] > L'9') ||
-        (file_path->Buffer[index] < L'0')) {
-      GoogleDbgPrint("\n!!!!! Bad format for pipe name: %wZ", file_path);
-      return INVALID_UCHAR;
-    }
-  }
-
-  // Parse the pipe#
-  ULONG uval = 0;
-  ULONG umultiplier = 1;
-
-  // traversing least to most significant digits.
-  for (ULONG index = name_len - 1; index >= index_begins_at; index--) {
-    uval += (umultiplier * static_cast<ULONG>(file_path->Buffer[index] - L'0'));
-    umultiplier *= 10;
-  }
-
-  return static_cast<UCHAR>(uval);
-}
-
-NTSTATUS AndroidUsbDeviceObject::CreatePipeFileObjectExt(
-    WDFFILEOBJECT wdf_fo,
-    WDFUSBPIPE wdf_pipe_obj,
-    const WDF_USB_PIPE_INFORMATION* pipe_info,
-    AndroidUsbFileObject** wdf_file_ext) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT((NULL != wdf_fo) && (NULL != wdf_pipe_obj) && (NULL != pipe_info) && (NULL != wdf_file_ext));
-  if ((NULL == wdf_fo) || (NULL == wdf_pipe_obj) || (NULL == pipe_info) || (NULL == wdf_file_ext)) {
-    return STATUS_INTERNAL_ERROR;
-  }
-  *wdf_file_ext = NULL;
-
-  AndroidUsbPipeFileObject* wdf_pipe_file_ext = NULL;
-
-  // We support only WdfUsbPipeTypeBulk and WdfUsbPipeTypeInterrupt files
-  // at this point.
-  switch (pipe_info->PipeType) {
-    case WdfUsbPipeTypeBulk:
-      wdf_pipe_file_ext = new(NonPagedPool, GANDR_POOL_TAG_BULK_FILE)
-            AndroidUsbBulkPipeFileObject(this, wdf_fo, wdf_pipe_obj);
-      break;
-
-    case WdfUsbPipeTypeInterrupt:
-      wdf_pipe_file_ext = new(NonPagedPool, GANDR_POOL_TAG_INTERRUPT_FILE)
-          AndroidUsbInterruptPipeFileObject(this, wdf_fo, wdf_pipe_obj);
-      break;;
-
-    case WdfUsbPipeTypeIsochronous:
-    case WdfUsbPipeTypeControl:
-    case WdfUsbPipeTypeInvalid:
-    default:
-      return STATUS_OBJECT_TYPE_MISMATCH;
-  }
-
-  // If we reached here instance of a file wrapper must be created.
-  ASSERT(NULL != wdf_pipe_file_ext);
-  if (NULL == wdf_pipe_file_ext)
-    return STATUS_INSUFFICIENT_RESOURCES;
-    
-  // Initialize the wrapper.
-  NTSTATUS status = wdf_pipe_file_ext->InitializePipe(pipe_info);
-  ASSERT(NT_SUCCESS(status));
-  if (NT_SUCCESS(status)) {
-    *wdf_file_ext = wdf_pipe_file_ext;
-  } else {
-    delete wdf_pipe_file_ext;
-  }
-
-  return STATUS_SUCCESS;
-}
-
-#if DBG
-#pragma code_seg()
-
-void AndroidUsbDeviceObject::PrintUsbDeviceDescriptor(
-    const USB_DEVICE_DESCRIPTOR* desc) {
-  GoogleDbgPrint("\n***** USB_DEVICE_DESCRIPTOR %p for device %p", desc, this);
-  GoogleDbgPrint("\n      bDescriptorType    = %u", desc->bDescriptorType);
-  GoogleDbgPrint("\n      bcdUSB             = x%02X", desc->bcdUSB);
-  GoogleDbgPrint("\n      bDeviceClass       = x%02X", desc->bDeviceClass);
-  GoogleDbgPrint("\n      bDeviceSubClass    = x%02X", desc->bDeviceSubClass);
-  GoogleDbgPrint("\n      bDeviceProtocol    = x%02X", desc->bDeviceProtocol);
-  GoogleDbgPrint("\n      bMaxPacketSize     = %u", desc->bMaxPacketSize0);
-  GoogleDbgPrint("\n      idVendor           = x%04X", desc->idVendor);
-  GoogleDbgPrint("\n      idProduct          = x%04X", desc->idProduct);
-  GoogleDbgPrint("\n      bcdDevice          = x%02X", desc->bcdDevice);
-  GoogleDbgPrint("\n      iManufacturer      = %u", desc->iManufacturer);
-  GoogleDbgPrint("\n      iProduct           = %u", desc->iProduct);
-  GoogleDbgPrint("\n      iSerialNumber      = %u", desc->iSerialNumber);
-  GoogleDbgPrint("\n      bNumConfigurations = %u", desc->bNumConfigurations);
-}
-
-void AndroidUsbDeviceObject::PrintUsbTargedDeviceInformation(
-    const WDF_USB_DEVICE_INFORMATION* info) {
-  GoogleDbgPrint("\n***** WDF_USB_DEVICE_INFORMATION %p for device %p", info, this);
-  GoogleDbgPrint("\n      HcdPortCapabilities               = x%08X", info->HcdPortCapabilities);
-  GoogleDbgPrint("\n      Traits                            = x%08X", info->Traits);
-  GoogleDbgPrint("\n      VersionInfo.USBDI_Version         = x%08X",
-           info->UsbdVersionInformation.USBDI_Version);
-  GoogleDbgPrint("\n      VersionInfo.Supported_USB_Version = x%08X",
-           info->UsbdVersionInformation.Supported_USB_Version);
-}
-
-void AndroidUsbDeviceObject::PrintConfigDescriptor(
-    const USB_CONFIGURATION_DESCRIPTOR* desc,
-    ULONG size) {
-  GoogleDbgPrint("\n***** USB_CONFIGURATION_DESCRIPTOR %p for device %p size %u",
-           desc, this, size);
-  GoogleDbgPrint("\n      bDescriptorType     = %u", desc->bDescriptorType);
-  GoogleDbgPrint("\n      wTotalLength        = %u", desc->wTotalLength);
-  GoogleDbgPrint("\n      bNumInterfaces      = %u", desc->bNumInterfaces);
-  GoogleDbgPrint("\n      bConfigurationValue = %u", desc->bConfigurationValue);
-  GoogleDbgPrint("\n      iConfiguration      = %u", desc->iConfiguration);
-  GoogleDbgPrint("\n      bmAttributes        = %u", desc->bmAttributes);
-  GoogleDbgPrint("\n      MaxPower            = %u", desc->MaxPower);
-}
-
-void AndroidUsbDeviceObject::PrintSelectedConfig(
-    const WDF_USB_DEVICE_SELECT_CONFIG_PARAMS* config) {
-  GoogleDbgPrint("\n***** WDF_USB_DEVICE_SELECT_CONFIG_PARAMS %p for device %p", config, this);
-  GoogleDbgPrint("\n      Type = %u", config->Type);
-  switch (config->Type) {
-    case WdfUsbTargetDeviceSelectConfigTypeSingleInterface:
-      GoogleDbgPrint("\n      SingleInterface:");
-      GoogleDbgPrint("\n         NumberConfiguredPipes  = %u",
-               config->Types.SingleInterface.NumberConfiguredPipes);
-      GoogleDbgPrint("\n         ConfiguredUsbInterface = %p",
-               config->Types.SingleInterface.ConfiguredUsbInterface);
-      break;
-
-    case WdfUsbTargetDeviceSelectConfigTypeMultiInterface:
-      GoogleDbgPrint("\n      MultiInterface:");
-      GoogleDbgPrint("\n         NumberInterfaces              = %u",
-               config->Types.MultiInterface.NumberInterfaces);
-      GoogleDbgPrint("\n         NumberOfConfiguredInterfaces  = %u",
-               config->Types.MultiInterface.NumberOfConfiguredInterfaces);
-      GoogleDbgPrint("\n         Pairs                         = %p",
-               config->Types.MultiInterface.Pairs);
-      break;
-
-    case WdfUsbTargetDeviceSelectConfigTypeInterfacesDescriptor:
-      GoogleDbgPrint("\n      Descriptor:");
-      GoogleDbgPrint("\n         NumInterfaceDescriptors = %u",
-               config->Types.Descriptor.NumInterfaceDescriptors);
-      GoogleDbgPrint("\n         ConfigurationDescriptor = %p",
-               config->Types.Descriptor.ConfigurationDescriptor);
-      GoogleDbgPrint("\n         InterfaceDescriptors    = %p",
-               config->Types.Descriptor.InterfaceDescriptors);
-      break;
-
-    case WdfUsbTargetDeviceSelectConfigTypeUrb:
-      GoogleDbgPrint("\n      Urb:");
-      GoogleDbgPrint("\n         Urb = %p",
-               config->Types.Urb.Urb);
-      break;
-
-    case WdfUsbTargetDeviceSelectConfigTypeInterfacesPairs:
-    case WdfUsbTargetDeviceSelectConfigTypeInvalid:
-    case WdfUsbTargetDeviceSelectConfigTypeDeconfig:
-    default:
-      GoogleDbgPrint("\n      Config type is unknown or invalid or not printable.");
-      break;
-  }
-}
-
-void AndroidUsbDeviceObject::PrintInterfaceDescriptor(
-    const USB_INTERFACE_DESCRIPTOR* desc) {
-  GoogleDbgPrint("\n***** USB_INTERFACE_DESCRIPTOR %p for device %p",
-           desc, this);
-  GoogleDbgPrint("\n      bLength            = %u", desc->bLength);
-  GoogleDbgPrint("\n      bDescriptorType    = %u", desc->bDescriptorType);
-  GoogleDbgPrint("\n      bInterfaceNumber   = %u", desc->bInterfaceNumber);
-  GoogleDbgPrint("\n      bAlternateSetting  = %u", desc->bAlternateSetting);
-  GoogleDbgPrint("\n      bNumEndpoints      = %u", desc->bNumEndpoints);
-  GoogleDbgPrint("\n      bInterfaceClass    = x%02X", desc->bInterfaceClass);
-  GoogleDbgPrint("\n      bInterfaceSubClass = x%02X", desc->bInterfaceSubClass);
-  GoogleDbgPrint("\n      bInterfaceProtocol = x%02X", desc->bInterfaceProtocol);
-  GoogleDbgPrint("\n      iInterface         = %u", desc->iInterface);
-}
-
-void AndroidUsbDeviceObject::PrintPipeInformation(
-    const WDF_USB_PIPE_INFORMATION* info,
-    UCHAR pipe_index) {
-  GoogleDbgPrint("\n***** WDF_USB_PIPE_INFORMATION[%u] %p for device %p",
-           pipe_index, info, this);
-  GoogleDbgPrint("\n      Size                = %u", info->Size);
-  GoogleDbgPrint("\n      MaximumPacketSize   = %u", info->MaximumPacketSize);
-  GoogleDbgPrint("\n      EndpointAddress     = x%02X", info->EndpointAddress);
-  GoogleDbgPrint("\n      Interval            = %u", info->Interval);
-  GoogleDbgPrint("\n      SettingIndex        = %u", info->SettingIndex);
-  GoogleDbgPrint("\n      PipeType            = %u", info->PipeType);
-  GoogleDbgPrint("\n      MaximumTransferSize = %u", info->MaximumTransferSize);
-}
-
-#endif  // DBG
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_device_object.h b/host/windows/usb/driver/android_usb_device_object.h
deleted file mode 100644
index 5c97e9c..0000000
--- a/host/windows/usb/driver/android_usb_device_object.h
+++ /dev/null
@@ -1,603 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_DEVICE_OBJECT_H__
-#define ANDROID_USB_DEVICE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbDeviceObject that
-  encapsulates an extension for KMDF device (FDO) object.
-*/
-
-#include "android_usb_wdf_object.h"
-
-// Forward declaration for file object extension
-class AndroidUsbFileObject;
-
-/** AndroidUsbDeviceObject class encapsulates an extension for KMDF FDO device
-  object. Instances of this class must be allocated from NonPagedPool.
-*/
-class AndroidUsbDeviceObject : public AndroidUsbWdfObject {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-  */
-  AndroidUsbDeviceObject();
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   ~AndroidUsbDeviceObject();
-
- public:
-  /** \brief Creates and initializes FDO device object extension
-
-    This method is called from driver's OnAddDevice method in response to
-    AddDevice call from the PnP manager
-    @param device_init[in] A pointer to a framework-allocated WDFDEVICE_INIT
-           structure.
-    @return If the routine succeeds, it returns STATUS_SUCCESS. Otherwise,
-            it returns one of the error status values defined in ntstatus.h.
-  */
-  NTSTATUS CreateFDODevice(PWDFDEVICE_INIT device_init);
-
-  /** \brief Resets target device
-
-    When executing this method instance of this class may be deleted!
-    This method must be called at PASSIVE IRQL.
-    @return STATUS_SUCCESS or an appropriate error code
-  */
-  NTSTATUS ResetDevice();
-
- private:
-  /** \name Device event handlers and callbacks
-  */
-  ///@{
-
-  /** \brief Handler for PnP prepare hardware event
-
-    This method performs any operations that are needed to make a device
-    accessible to the driver. The framework calls this callback after the PnP
-    manager has assigned hardware resources to the device and after the device
-    has entered its uninitialized D0 state. This callback is called before
-    calling the driver's EvtDeviceD0Entry callback function.
-    This method is called at PASSIVE IRQL.
-    @param resources_raw[in] A handle to a framework resource-list object that
-           identifies the raw hardware resources that the PnP manager has
-           assigned to the device.
-    @param resources_translated[in] A handle to a framework resource-list
-           object that identifies the translated hardware resources that the
-           PnP manager has assigned to the device. 
-    @return Successful status or an appropriate error code
-  */
-  NTSTATUS OnEvtDevicePrepareHardware(WDFCMRESLIST resources_raw,
-                                      WDFCMRESLIST resources_translated);
-
-  /** \brief Handler for PnP release hardware event
-
-    This method performs operations that  that are needed when a device is no
-    longer accessible. Framework calls the callback function if the device is
-    being removed, or if the PnP manager is attempting to redistribute hardware
-    resources. The framework calls the EvtDeviceReleaseHardware callback
-    function after the driver's device has been shut off, the PnP manager has
-    reclaimed the hardware resources that it assigned to the device, and the
-    device is no longer accessible. (The PCI configuration state is still
-    accessible.) Typically, a EvtDeviceReleaseHardware callback function unmaps
-    memory that the driver's EvtDevicePrepareHardware callback function mapped.
-    Usually, all other hardware shutdown operations should take place in the
-    driver's EvtDeviceD0Exit callback function.
-    This method is called at PASSIVE IRQL.
-    @param wdf_device[in] A handle to a framework device object. 
-    @param resources_translated[in] A handle to a framework resource-list
-           object that identifies the translated hardware resources that the
-           PnP manager has assigned to the device. 
-    @return Successful status or an appropriate error code
-  */
-  NTSTATUS OnEvtDeviceReleaseHardware(WDFCMRESLIST resources_translated);
-
-  /** \brief Handler for create file event (request)
-
-    This method performs operations that are needed when an application
-    requests access to an item within this device path (including device
-    itself). This method is called synchronously, in the context of the
-    user thread that opens the item.
-    This method is called at PASSIVE IRQL.
-    @param request[in] A handle to a framework request object that represents
-           a file creation request.
-    @param wdf_fo[in] A handle to a framework file object that describes a
-           file that is being created with this request.
-    @return Successful status or an appropriate error code
-  */
-  void OnEvtDeviceFileCreate(WDFREQUEST request, WDFFILEOBJECT wdf_fo);
-
-  /** \brief Entry point for PnP prepare hardware event
-
-    This callback performs any operations that are needed to make a device
-    accessible to the driver. The framework calls this callback after the PnP
-    manager has assigned hardware resources to the device and after the device
-    has entered its uninitialized D0 state. This callback is called before
-    calling the driver's EvtDeviceD0Entry callback function.
-    This callback is called at PASSIVE IRQL.
-    @param wdf_dev[in] A handle to a framework device object. 
-    @param resources_raw[in] A handle to a framework resource-list object that
-           identifies the raw hardware resources that the PnP manager has
-           assigned to the device.
-    @param resources_translated[in] A handle to a framework resource-list
-           object that identifies the translated hardware resources that the
-           PnP manager has assigned to the device. 
-    @return Successful status or an appropriate error code
-  */
-  static NTSTATUS EvtDevicePrepareHardwareEntry(WDFDEVICE wdf_dev,
-                                                WDFCMRESLIST resources_raw,
-                                                WDFCMRESLIST resources_translated);
-
-  /** \brief Entry point for PnP release hardware event
-
-    This callback performs operations that  that are needed when a device is no
-    longer accessible. Framework calls the callback function if the device is
-    being removed, or if the PnP manager is attempting to redistribute hardware
-    resources. The framework calls the EvtDeviceReleaseHardware callback
-    function after the driver's device has been shut off, the PnP manager has
-    reclaimed the hardware resources that it assigned to the device, and the
-    device is no longer accessible. (The PCI configuration state is still
-    accessible.) Typically, a EvtDeviceReleaseHardware callback function unmaps
-    memory that the driver's EvtDevicePrepareHardware callback function mapped.
-    Usually, all other hardware shutdown operations should take place in the
-    driver's EvtDeviceD0Exit callback function.
-    This callback is called at PASSIVE IRQL.
-    @param wdf_dev[in] A handle to a framework device object. 
-    @param resources_translated[in] A handle to a framework resource-list
-           object that identifies the translated hardware resources that the
-           PnP manager has assigned to the device. 
-    @return Successful status or an appropriate error code
-  */
-  static NTSTATUS EvtDeviceReleaseHardwareEntry(WDFDEVICE wdf_dev,
-                                                WDFCMRESLIST resources_translated);
-
-  /** \brief Entry point for create file event (request)
-
-    This callback performs operations that that are needed when an application
-    requests access to a device. The framework calls a driver's
-    EvtDeviceFileCreate callback function when a user application or another
-    driver opens the device (or file on this device) to perform an I/O
-    operation, such as reading or writing a file. This callback function is
-    called synchronously, in the context of the user thread that opens the
-    device.
-    This callback is called at PASSIVE IRQL.
-    @param wdf_dev[in] A handle to a framework device object. 
-    @param request[in] A handle to a framework request object that represents
-           a file creation request.
-    @param wdf_fo[in] A handle to a framework file object that describes a
-           file that is being created with this request.
-    @return Successful status or an appropriate error code
-  */
-  static void EvtDeviceFileCreateEntry(WDFDEVICE wdf_dev,
-                                       WDFREQUEST request,
-                                       WDFFILEOBJECT wdf_fo);
-
-  ///@}
-
- private:
-  /** \name I/O request event handlers and callbacks
-  */
-  ///@{
-
-  /** \brief Read event handler
-
-    This method is called when a read request comes to a file object opened
-    on this device.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be read.
-  */
-  void OnEvtIoRead(WDFREQUEST request, size_t length);
-
-  /** \brief Write event handler
-
-    This method is called when a write request comes to a file object opened
-    on this device.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be written.
-  */
-  void OnEvtIoWrite(WDFREQUEST request, size_t length);
-
-  /** \brief IOCTL event handler
-
-    This method is called when a device control request comes to a file object
-    opened on this device.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param ioctl_code[in] The driver-defined or system-defined I/O control code
-           that is associated with the request.
-  */
-  void OnEvtIoDeviceControl(WDFREQUEST request,
-                            size_t output_buf_len,
-                            size_t input_buf_len,
-                            ULONG ioctl_code);
-
-  /** \brief Entry point for read event
-
-    This callback is called when a read request comes to a file object opened
-    on this device.
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param queue[in] A handle to the framework queue object that is associated
-           with the I/O request.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be read.
-  */
-  static void EvtIoReadEntry(WDFQUEUE queue,
-                             WDFREQUEST request,
-                             size_t length);
-
-  /** \brief Entry point for write event
-
-    This callback is called when a write request comes to a file object opened
-    on this device.
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param queue[in] A handle to the framework queue object that is associated
-           with the I/O request.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be written.
-  */
-  static void EvtIoWriteEntry(WDFQUEUE queue,
-                              WDFREQUEST request,
-                              size_t length);
-
-  /** \brief Entry point for device IOCTL event
-
-    This callback is called when a device control request comes to a file
-    object opened on this device.
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param queue[in] A handle to the framework queue object that is associated
-           with the I/O request.
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param ioctl_code[in] The driver-defined or system-defined I/O control code
-           that is associated with the request.
-  */
-  static void EvtIoDeviceControlEntry(WDFQUEUE queue,
-                                      WDFREQUEST request,
-                                      size_t output_buf_len,
-                                      size_t input_buf_len,
-                                      ULONG ioctl_code);
-
-  ///@}
-
- public:
-  /** \name Device level I/O request handlers
-  */
-  ///@{
-
-  /** \brief Gets USB device descriptor
-
-    This method can be called at IRQL <= DISPATCH_LEVEL
-    @param request[in] A handle to a framework request object for this IOCTL.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  void OnGetUsbDeviceDescriptorCtl(WDFREQUEST request, size_t output_buf_len);
-
-  /** \brief Gets USB configuration descriptor for the selected configuration.
-
-    This method can be called at IRQL <= DISPATCH_LEVEL
-    @param request[in] A handle to a framework request object for this IOCTL.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  void OnGetUsbConfigDescriptorCtl(WDFREQUEST request, size_t output_buf_len);
-
-  /** \brief Gets USB configuration descriptor for the selected interface.
-
-    This method can be called at IRQL <= DISPATCH_LEVEL
-    @param request[in] A handle to a framework request object for this IOCTL.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  void OnGetUsbInterfaceDescriptorCtl(WDFREQUEST request, size_t output_buf_len);
-
-  /** \brief Gets information about an endpoint.
-
-    This method can be called at IRQL <= DISPATCH_LEVEL
-    @param request[in] A handle to a framework request object for this IOCTL.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  void OnGetEndpointInformationCtl(WDFREQUEST request,
-                                   size_t input_buf_len,
-                                   size_t output_buf_len);
-
-  /** \brief Gets device serial number.
-
-    Serial number is returned in form of zero-terminated string that in the
-    output buffer. This method must be called at low IRQL.
-    @param request[in] A handle to a framework request object for this IOCTL.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  void OnGetSerialNumberCtl(WDFREQUEST request, size_t output_buf_len);
-
-  ///@}
-
- private:
-  /** \name Internal methods
-  */
-  ///@{
-
-  /** \brief Creates default request queue for this device.
-
-    In KMDF all I/O requests are coming through the queue object. So, in order
-    to enable our device to receive I/O requests we must create a queue for it.
-    This method is called at PASSIVE IRQL.
-    @return STATUS_SUCCESS or an appropriate error code.
-  */
-  NTSTATUS CreateDefaultQueue();
-
-  /** \brief Configures our device.
-
-    This method is called from the prepare hardware handler after underlying
-    FDO device has been created.
-    This method is called at PASSSIVE IRQL.
-    @return STATUS_SUCCESS or an appropriate error code.
-  */
-  NTSTATUS ConfigureDevice();
-
-  /** \brief Selects interfaces on our device.
-
-    This method is called from the prepare hardware handler after underlying
-    FDO device has been created and configured.
-    This method is called at PASSSIVE IRQL.
-    @return STATUS_SUCCESS or an appropriate error code.
-  */
-  NTSTATUS SelectInterfaces();
-  
-  /** \brief Gets pipe index from a file name
-
-    This method is called from OnEvtDeviceFileCreate to determine index of
-    the pipe this file is addressing.
-    This method is called at PASSIVE IRQL.
-    @param file_path[in] Path to the file that being opened.
-    @return Pipe index or INVALID_UCHAR if index cannot be calculated.
-  */
-  UCHAR GetPipeIndexFromFileName(PUNICODE_STRING file_path);
-
-  /** \brief Creates file object extension for a pipe
-
-    This method is called from OnEvtDeviceFileCreate to create an appropriate
-    file object extension for a particular pipe type.
-    This method is called at PASSIVE IRQL.
-    @param wdf_fo[in] KMDF file to extend.
-    @param wdf_pipe_obj[in] KMDF pipe for this extension
-    @param pipe_info[in] Pipe information
-    @param wdf_file_ext[out] Upon successfull completion will receive instance
-           of the extension.
-    @return STATUS_SUCCESS or an appropriate error code
-  */
-  NTSTATUS CreatePipeFileObjectExt(WDFFILEOBJECT wdf_fo,
-                                   WDFUSBPIPE wdf_pipe_obj,
-                                   const WDF_USB_PIPE_INFORMATION* pipe_info,
-                                   AndroidUsbFileObject** wdf_file_ext);
-
-  ///@}
-
- private:
-  /** \name Debugging support
-  */
-  ///@{
-
-#if DBG
-  /// Prints USB_DEVICE_DESCRIPTOR to debug output
-  void PrintUsbDeviceDescriptor(const USB_DEVICE_DESCRIPTOR* desc);
-
-  /// Prints WDF_USB_DEVICE_INFORMATION to debug output
-  void PrintUsbTargedDeviceInformation(const WDF_USB_DEVICE_INFORMATION* info);
-
-  /// Prints USB_CONFIGURATION_DESCRIPTOR to debug output
-  void PrintConfigDescriptor(const USB_CONFIGURATION_DESCRIPTOR* desc,
-                             ULONG size);
-
-  /// Prints WDF_USB_DEVICE_SELECT_CONFIG_PARAMS to debug output
-  void PrintSelectedConfig(const WDF_USB_DEVICE_SELECT_CONFIG_PARAMS* config);
-
-  /// Prints USB_INTERFACE_DESCRIPTOR to debug output
-  void PrintInterfaceDescriptor(const USB_INTERFACE_DESCRIPTOR* desc);
-
-  /// Prints WDF_USB_PIPE_INFORMATION to debug output
-  void PrintPipeInformation(const WDF_USB_PIPE_INFORMATION* info,
-                            UCHAR pipe_index);
-
-#endif  // DBG
-
-  ///@}
-
- public:
-  /// Gets WDF device handle for this device
-  __forceinline WDFDEVICE wdf_device() const {
-    return reinterpret_cast<WDFDEVICE>(wdf_object());
-  }
-
-  /// Gets target USB device descriptor
-  __forceinline const USB_DEVICE_DESCRIPTOR* usb_device_descriptor() const {
-    return &usb_device_descriptor_;
-  }
-
-  /// Gets target USB device information
-  __forceinline const WDF_USB_DEVICE_INFORMATION* usb_device_info() const {
-    return &usb_device_info_;
-  }
-
-  /// Gets selected interface descriptor
-  __forceinline const USB_INTERFACE_DESCRIPTOR* interface_descriptor() const {
-    return &interface_descriptor_;
-  }
-
-  /// Gets target (PDO) device handle
-  __forceinline WDFUSBDEVICE wdf_target_device() const {
-    return wdf_target_device_;
-  }
-
-  /// Checks if target device has been created
-  __forceinline bool IsTaretDeviceCreated() const {
-    return (NULL != wdf_target_device());
-  }
-
-  /// Gets USB configuration descriptor
-  __forceinline const USB_CONFIGURATION_DESCRIPTOR* configuration_descriptor() const {
-    return configuration_descriptor_;
-  }
-
-  /// Checks if device has been configured
-  __forceinline bool IsDeviceConfigured() const {
-    return (NULL != configuration_descriptor());
-  }
-
-  /// Gets number of interfaces for this device
-  __forceinline UCHAR GetInterfaceCount() const {
-    ASSERT(IsDeviceConfigured());
-    return IsDeviceConfigured() ? configuration_descriptor()->bNumInterfaces : 0;
-  }
-
-  /// Checks if this is "single interface" device
-  __forceinline bool IsSingleInterfaceDevice() const {
-    return (1 == GetInterfaceCount());
-  }
-
-  /// Gets USB interface selected on this device
-  __forceinline WDFUSBINTERFACE wdf_usb_interface() const {
-    return wdf_usb_interface_;
-  }
-
-  /// Checks if an interface has been selected on this device
-  __forceinline bool IsInterfaceSelected() const {
-    return (NULL != wdf_usb_interface());
-  }
-
-  /// Gets number of pipes configured on this device
-  __forceinline UCHAR configured_pipes_num() const {
-    return configured_pipes_num_;
-  }
-
-  /// Gets index of the bulk read pipe
-  __forceinline UCHAR bulk_read_pipe_index() const {
-    return bulk_read_pipe_index_;
-  }
-
-  /// Gets index of the bulk write pipe
-  __forceinline UCHAR bulk_write_pipe_index() const {
-    return bulk_write_pipe_index_;
-  }
-
-  /// Checks if this is a high speed device
-  __forceinline bool IsHighSpeed() const {
-    return (0 != (usb_device_info()->Traits & WDF_USB_DEVICE_TRAIT_AT_HIGH_SPEED));
-  }
-
-  /// Checks if bulk read pipe index is known
-  __forceinline bool IsBulkReadPipeKnown() const {
-    return (INVALID_UCHAR != bulk_read_pipe_index());
-  }
-
-  /// Checks if bulk write pipe index is known
-  __forceinline bool IsBulkWritePipeKnown() const {
-    return (INVALID_UCHAR != bulk_write_pipe_index());
-  }
-
-  /// Gets device serial number string. Note that string may be
-  /// not zero-terminated. Use serial_number_len() to get actual
-  /// length of this string.
-  __forceinline const WCHAR* serial_number() const {
-    ASSERT(NULL != serial_number_handle_);
-    return (NULL != serial_number_handle_) ?
-      reinterpret_cast<const WCHAR*>
-        (WdfMemoryGetBuffer(serial_number_handle_, NULL)) :
-      NULL;
-  }
-
-  /// Gets length (in bytes) of device serial number string
-  __forceinline USHORT serial_number_char_len() const {
-    return serial_number_char_len_;
-  }
-
-  /// Gets length (in bytes) of device serial number string
-  __forceinline USHORT serial_number_byte_len() const {
-    return serial_number_char_len() * sizeof(WCHAR);
-  }
-
- protected:
-  /// Target USB device descriptor
-  USB_DEVICE_DESCRIPTOR         usb_device_descriptor_;
-
-  /// Target USB device information
-  WDF_USB_DEVICE_INFORMATION    usb_device_info_;
-
-  /// Selected interface descriptor
-  USB_INTERFACE_DESCRIPTOR      interface_descriptor_;
-
-  /// USB configuration descriptor
-  PUSB_CONFIGURATION_DESCRIPTOR configuration_descriptor_;
-
-  /// Target (PDO?) device handle
-  WDFUSBDEVICE                  wdf_target_device_;
-
-  /// USB interface selected on this device
-  WDFUSBINTERFACE               wdf_usb_interface_;
-
-  /// Device serial number
-  WDFMEMORY                     serial_number_handle_;
-
-  /// Device serial number string length
-  USHORT                        serial_number_char_len_;
-
-  /// Number of pipes configured on this device
-  UCHAR                         configured_pipes_num_;
-
-  /// Index of the bulk read pipe
-  UCHAR                         bulk_read_pipe_index_;
-
-  /// Index of the bulk write pipe
-  UCHAR                         bulk_write_pipe_index_;
-};
-
-/** \brief Gets device KMDF object extension for the given KMDF object
-
-  @param wdf_dev[in] KMDF handle describing device object
-  @return Instance of AndroidUsbDeviceObject associated with KMDF object or
-          NULL if association is not found.
-*/
-__forceinline AndroidUsbDeviceObject* GetAndroidUsbDeviceObjectFromHandle(
-    WDFDEVICE wdf_dev) {
-  AndroidUsbWdfObject* wdf_object_ext =
-    GetAndroidUsbWdfObjectFromHandle(wdf_dev);
-  ASSERT((NULL != wdf_object_ext) &&
-         wdf_object_ext->Is(AndroidUsbWdfObjectTypeDevice));
-  if ((NULL != wdf_object_ext) &&
-      wdf_object_ext->Is(AndroidUsbWdfObjectTypeDevice)) {
-    return reinterpret_cast<AndroidUsbDeviceObject*>(wdf_object_ext);
-  }
-  return NULL;
-}
-
-#endif  // ANDROID_USB_DEVICE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_driver_defines.h b/host/windows/usb/driver/android_usb_driver_defines.h
deleted file mode 100644
index 4fe25d7..0000000
--- a/host/windows/usb/driver/android_usb_driver_defines.h
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_DRIVER_DEFINES_H__
-#define ANDROID_USB_DRIVER_DEFINES_H__
-/** \file
-  This file consists of constants, types and macros used (and useful) in driver
-  development.
-*/
-
-/** \name IRQL assertions
-  These assertions help to verify that code is running at expected IRQL
-*/
-///@{
-
-/// Asserts that current IRQL is less than provided level
-#define ASSERT_IRQL_LESS(irql_level) ASSERT(KeGetCurrentIrql() < irql_level)
-/// Asserts that current IRQL is less or equal than provided level
-#define ASSERT_IRQL_LESS_OR_EQUAL(irql_level) ASSERT(KeGetCurrentIrql() <= irql_level)
-/// Asserts that current IRQL is the same as provided level
-#define ASSERT_IRQL_IS(irql_level) ASSERT(irql_level == KeGetCurrentIrql())
-/// Asserts that current IRQL is less than DISPATCH_LEVEL
-#define ASSERT_IRQL_LOW() ASSERT_IRQL_LESS(DISPATCH_LEVEL)
-/// Asserts that current IRQL is above APC_LEVEL
-#define ASSERT_IRQL_HIGH() ASSERT(KeGetCurrentIrql() >= DISPATCH_LEVEL)
-/// Asserts that current IRQL is at PASSIVE_LEVEL
-#define ASSERT_IRQL_PASSIVE() ASSERT_IRQL_IS(PASSIVE_LEVEL)
-/// Asserts that current IRQL is at APC_LEVEL
-#define ASSERT_IRQL_APC() ASSERT_IRQL_IS(APC_LEVEL)
-/// Asserts that current IRQL is at DISPATCH_LEVEL
-#define ASSERT_IRQL_DISPATCH() ASSERT_IRQL_IS(DISPATCH_LEVEL)
-/// Asserts that current IRQL is at APC or DISPATCH_LEVEL
-#define ASSERT_IRQL_APC_OR_DISPATCH() \
-  ASSERT((KeGetCurrentIrql() == APC_LEVEL) || (KeGetCurrentIrql() == DISPATCH_LEVEL))
-/// Asserts that current IRQL is less or equal DISPATCH_LEVEL
-#define ASSERT_IRQL_LOW_OR_DISPATCH() \
-  ASSERT_IRQL_LESS_OR_EQUAL(DISPATCH_LEVEL)
-
-///@}
-
-#if DBG
-/** \brief Overrides DbgPrint to make sure that nothing gets printed
-  to debug output in release build.
-*/
-ULONG __cdecl GoogleDbgPrint(char* format, ...);
-#else 
-#define GoogleDbgPrint(Arg) NOTHING
-#endif
-
-/// Invalid UCHAR value
-#define INVALID_UCHAR   (static_cast<UCHAR>(0xFF))
-
-/// Invalid ULONG value
-#define INVALID_ULONG   (static_cast<ULONG>(-1))
-
-/** Enum AndroidUsbWdfObjectType enumerates types of KMDF objects that
-  we extend in our driver.
-*/
-enum AndroidUsbWdfObjectType {
-  // We start enum with 1 insetead of 0 to protect orselves from a dangling
-  // or uninitialized context structures because KMDF will zero our extension
-  // when it gets created.
-
-  /// Device object context
-  AndroidUsbWdfObjectTypeDevice = 1,
-
-  /// File object context
-  AndroidUsbWdfObjectTypeFile,
-
-  /// Request object context
-  AndroidUsbWdfObjectTypeRequest,
-
-  /// Workitem object context
-  AndroidUsbWdfObjectTypeWorkitem,
-
-  /// Illegal (maximum) context id
-  AndroidUsbWdfObjectTypeMax
-};
-
-/** Structure AndroidUsbWdfObjectContext represents our context that extends
-  every KMDF object (device, file, pipe, etc).
-*/
-typedef struct TagAndroidUsbWdfObjectContext {
-  /// KMDF object type that is extended with this context
-  AndroidUsbWdfObjectType     object_type;
-
-  /// Instance of the class that extends KMDF object with this context
-  class AndroidUsbWdfObject*  wdf_object_ext;
-} AndroidUsbWdfObjectContext;
-
-// KMDF woodoo to register our extension and implement accessor method
-WDF_DECLARE_CONTEXT_TYPE_WITH_NAME(AndroidUsbWdfObjectContext,
-                                   GetAndroidUsbWdfObjectContext)
-
-/** Structure AndroidUsbWdfRequestContext represents our context that is
-  associated with every request recevied by the driver.
-*/
-typedef struct TagAndroidUsbWdfRequestContext {
-  /// KMDF object type that is extended with this context
-  /// (must be AndroidUsbWdfObjectTypeRequest)
-  AndroidUsbWdfObjectType object_type;
-
-  /// System time request has been first scheduled
-  // (time of the first WdfRequestSend is called for it)
-  LARGE_INTEGER           sent_at;
-
-  /// KMDF descriptor for the memory allocated for URB
-  WDFMEMORY               urb_mem;
-
-  /// MDL describing the transfer buffer
-  PMDL                    transfer_mdl;
-
-  /// Private MDL that we build in order to perform the transfer
-  PMDL                    mdl;
-
-  // Virtual address for the current segment of transfer.
-  void*                   virtual_address;
-
-  /// Number of bytes remaining to transfer
-  ULONG                   length;
-
-  /// Number of bytes requested to transfer
-  ULONG                   transfer_size;
-
-  /// Accummulated number of bytes transferred
-  ULONG                   num_xfer;
-
-  /// Initial timeout (in millisec) set for this request
-  ULONG                   initial_time_out;
-
-  // Read / Write selector
-  bool                    is_read;
-
-  // IOCTL selector
-  bool                    is_ioctl;
-} AndroidUsbWdfRequestContext;
-
-// KMDF woodoo to register our extension and implement accessor method
-WDF_DECLARE_CONTEXT_TYPE_WITH_NAME(AndroidUsbWdfRequestContext,
-                                   GetAndroidUsbWdfRequestContext)
-
-/** Structure AndroidUsbWorkitemContext represents our context that is
-  associated with workitems created by our driver.
-*/
-typedef struct TagAndroidUsbWorkitemContext {
-  /// KMDF object type that is extended with this context
-  /// (must be AndroidUsbWdfObjectTypeWorkitem)
-  AndroidUsbWdfObjectType         object_type;
-
-  /// Pipe file object extension that enqueued this work item
-  class AndroidUsbPipeFileObject* pipe_file_ext;
-} AndroidUsbWorkitemContext;
-
-// KMDF woodoo to register our extension and implement accessor method
-WDF_DECLARE_CONTEXT_TYPE_WITH_NAME(AndroidUsbWorkitemContext,
-                                   GetAndroidUsbWorkitemContext)
-
-#endif  // ANDROID_USB_DRIVER_DEFINES_H__
diff --git a/host/windows/usb/driver/android_usb_driver_object.cpp b/host/windows/usb/driver/android_usb_driver_object.cpp
deleted file mode 100644
index d8be50f..0000000
--- a/host/windows/usb/driver/android_usb_driver_object.cpp
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbDriverObject that
-  encapsulates our driver object
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_device_object.h"
-#include "android_usb_driver_object.h"
-
-#pragma data_seg()
-
-/** Globally accessible instance of the AndroidUsbDriverObject.
-  NT OS design allows us using of a global pointer to our driver object
-  instance since it can't be created or destroyed concurently and its value
-  is not going to change between creation and destruction.
-*/
-AndroidUsbDriverObject* global_driver_object = NULL;
-
-#pragma code_seg("INIT")
-
-extern "C" {
-
-/// Main entry point to the driver
-NTSTATUS DriverEntry(PDRIVER_OBJECT drv_object, PUNICODE_STRING reg_path) {
-  // Just pass it down inside the class
-  return AndroidUsbDriverObject::DriverEntry(drv_object, reg_path);
-}
-
-}  // extern "C"
-
-NTSTATUS AndroidUsbDriverObject::DriverEntry(PDRIVER_OBJECT drv_object,
-                                             PUNICODE_STRING reg_path) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(NULL != drv_object);
-  ASSERT((NULL != reg_path) &&
-         (NULL != reg_path->Buffer) &&
-         (0 != reg_path->Length));
-
-  // Instantiate driver object
-  global_driver_object = new(NonPagedPool, GANDR_POOL_TAG_DRIVER_OBJECT)
-    AndroidUsbDriverObject(drv_object, reg_path);
-  ASSERT(NULL != global_driver_object);
-  if (NULL == global_driver_object)
-    return STATUS_INSUFFICIENT_RESOURCES;
-
-  // Initialize driver object
-  NTSTATUS status = global_driver_object->OnDriverEntry(drv_object, reg_path);
-
-  if (!NT_SUCCESS(status)) {
-    // Something went wrong. Delete our driver object and get out of here.
-    delete global_driver_object;
-  }
-
-  return status;
-}
-
-AndroidUsbDriverObject::AndroidUsbDriverObject(PDRIVER_OBJECT drv_object,
-                                               PUNICODE_STRING reg_path)
-    : driver_object_(drv_object),
-      wdf_driver_(NULL) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(NULL != driver_object());
-}
-
-NTSTATUS AndroidUsbDriverObject::OnDriverEntry(PDRIVER_OBJECT drv_object,
-                                               PUNICODE_STRING reg_path) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(driver_object() == drv_object);
-
-  // Initiialize driver config, specifying our unload callback and default
-  // pool tag for memory allocations that KMDF does on our behalf.
-  WDF_DRIVER_CONFIG config;
-  WDF_DRIVER_CONFIG_INIT(&config, EvtDeviceAddEntry);
-  config.EvtDriverUnload = EvtDriverUnloadEntry;
-  config.DriverPoolTag = GANDR_POOL_TAG_DEFAULT;
-
-  // Create a framework driver object to represent our driver.
-  NTSTATUS status = WdfDriverCreate(drv_object,
-                                    reg_path,
-                                    WDF_NO_OBJECT_ATTRIBUTES,
-                                    &config,
-                                    &wdf_driver_);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  GoogleDbgPrint("\n>>>>>>>>>> Android USB driver has started >>>>>>>>>>");
-
-  return STATUS_SUCCESS;
-}
-
-#pragma code_seg("PAGE")
-
-AndroidUsbDriverObject::~AndroidUsbDriverObject() {
-  ASSERT_IRQL_PASSIVE();
-}
-
-NTSTATUS AndroidUsbDriverObject::OnAddDevice(PWDFDEVICE_INIT device_init) {
-  ASSERT_IRQL_PASSIVE();
-  GoogleDbgPrint("\n++++++++++ AndroidUsbDriverObject::OnAddDevice ++++++++++");
-  // Instantiate our device object extension for this device
-  AndroidUsbDeviceObject* wdf_device_ext =
-    new(NonPagedPool, GANDR_POOL_TAG_KMDF_DEVICE) AndroidUsbDeviceObject();
-  ASSERT(NULL != wdf_device_ext);
-  if (NULL == wdf_device_ext)
-    return STATUS_INSUFFICIENT_RESOURCES;
-
-  // Create and initialize FDO device
-  NTSTATUS status = wdf_device_ext->CreateFDODevice(device_init);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    delete wdf_device_ext;
-
-  return status;
-}
-
-void AndroidUsbDriverObject::OnDriverUnload() {
-  ASSERT_IRQL_PASSIVE();
-  GoogleDbgPrint("\n<<<<<<<<<< Android USB driver is unloaded <<<<<<<<<<");
-}
-
-NTSTATUS AndroidUsbDriverObject::EvtDeviceAddEntry(
-    WDFDRIVER wdf_drv,
-    PWDFDEVICE_INIT device_init) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT((NULL != global_driver_object) && (global_driver_object->wdf_driver() == wdf_drv));
-
-  // Pass it down to our driver object
-  if ((NULL == global_driver_object) ||
-      (global_driver_object->wdf_driver() != wdf_drv)) {
-    return STATUS_INTERNAL_ERROR;
-  }
-
-  return global_driver_object->OnAddDevice(device_init);
-}
-
-VOID AndroidUsbDriverObject::EvtDriverUnloadEntry(WDFDRIVER wdf_drv) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT((NULL != global_driver_object) &&
-         (global_driver_object->wdf_driver() == wdf_drv));
-
-  // Pass it down to our driver object
-  if ((NULL != global_driver_object) &&
-      (global_driver_object->wdf_driver() == wdf_drv)) {
-    global_driver_object->OnDriverUnload();
-    // Now we can (and have to) delete our driver object
-    delete global_driver_object;
-  }
-}
-
-#if DBG
-
-#pragma code_seg()
-
-ULONG __cdecl GoogleDbgPrint(char* format, ...) {
-  va_list arg_list;
-  va_start(arg_list, format);
-  ULONG ret =
-    vDbgPrintEx(DPFLTR_IHVDRIVER_ID, DPFLTR_ERROR_LEVEL, format, arg_list);
-  va_end(arg_list);
-
-  return ret;
-}
-
-#endif  // DBG
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_driver_object.h b/host/windows/usb/driver/android_usb_driver_object.h
deleted file mode 100644
index 8f68a80..0000000
--- a/host/windows/usb/driver/android_usb_driver_object.h
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_DRIVER_OBJECT_H__
-#define ANDROID_USB_DRIVER_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbDriverObject that
-  encapsulates our driver object.
-*/
-
-/// Globally accessible pointer to the driver object
-extern class AndroidUsbDriverObject* global_driver_object;
-
-/** AndroidUsbDriverObject class encapsulates driver object and provides
-  overall initialization / cleanup as well as management of globally used
-  resources. We use KMDF framework for this driver because it takes care of
-  most of the USB related "things" (like PnP, power management and other
-  stuff) so we can concentrate more on real functionality. This driver is
-  based on KMDF's usbsamp driver sample available at DDK's src\kmdf\usbsamp
-  directory. Instance of this class (always one) must be allocated from
-  NonPagedPool.
-*/
-class AndroidUsbDriverObject {
-
- public:
-  /** \brief Driver initialization entry point.
-
-    This method is a "gate" to our driver class from main DriverEntry routine.
-    Since this method is called from within DriverEntry only it is placed in
-    "INIT" code segment.
-    This method is called at IRQL PASSIVE_LEVEL.
-    @param drv_object[in] Driver object passed to DriverEntry routine
-    @param reg_path[in] Path to the driver's Registry passed to DriverEntry
-          routine
-    @returns STATUS_SUCCESS on success or an appropriate error code.
-  */
-  static NTSTATUS DriverEntry(PDRIVER_OBJECT drv_object,
-                              PUNICODE_STRING reg_path);
-
- private:
-  /** \brief Constructs driver object.
-
-    Constructor for driver class must be as light as possible. All
-    initialization that may fail must be deferred to OnDriverEntry method.
-    Since this method is called from within DriverEntry only it is placed in
-    "INIT" code segment.
-    This method is called at IRQL PASSIVE_LEVEL.
-    @param drv_object[in] Driver object passed to DriverEntry routine
-    @param reg_path[in] Path to the driver's Registry passed to DriverEntry
-          routine
-  */
-  AndroidUsbDriverObject(PDRIVER_OBJECT drv_object, PUNICODE_STRING reg_path);
-
-  /** \brief Destructs driver object.
-
-    Destructor for driver class must be as light as possible. All
-    uninitialization must be done in OnDriverUnload method.
-    This method must be called at PASSIVE IRQL.
-  */
-   ~AndroidUsbDriverObject();
-
-  /** \brief Initializes instance of the driver object.
-
-    This method is called immediatelly after driver object has been
-    instantiated to perform actual initialization of the driver. Since this
-    method is called from within DriverEntry only it is placed in
-    "INIT" code segment.
-    This method is called at IRQL PASSIVE_LEVEL.
-    @param drv_object[in] Driver object passed to DriverEntry routine
-    @param reg_path[in] Path to the driver's Registry passed to DriverEntry
-          routine
-    @returns STATUS_SUCCESS on success or an appropriate error code.
-  */
-  NTSTATUS OnDriverEntry(PDRIVER_OBJECT drv_object, PUNICODE_STRING reg_path);
-
-  /** \brief Actual handler for KMDF's AddDevice event
-
-    This method is called by the framework in response to AddDevice call from
-    the PnP manager. We create and initialize a device object to represent a
-    new instance of the device.
-    This method is called at IRQL PASSIVE_LEVEL.
-    @param device_init[in] A pointer to a framework-allocated WDFDEVICE_INIT
-           structure.
-    @return If the routine succeeds, it returns STATUS_SUCCESS. Otherwise,
-            it returns one of the error status values defined in ntstatus.h.
-  */
-  NTSTATUS OnAddDevice(PWDFDEVICE_INIT device_init);
-
-  /** \brief Actual driver unload event handler.
-
-    This method is called when driver is being unloaded.
-    This method is called at IRQL PASSIVE_LEVEL.
-  */
-  void OnDriverUnload();
-
-  /** \brief KMDF's DeviceAdd event entry point
-
-    This callback is called by the framework in response to AddDevice call from
-    the PnP manager. We create and initialize a device object to represent a
-    new instance of the device. All the software resources should be allocated
-    in this callback.
-    This method is called at IRQL PASSIVE_LEVEL.
-    @param wdf_drv[in] WDF driver handle.
-    @param device_init[in] A pointer to a framework-allocated WDFDEVICE_INIT
-           structure.
-    @return If the routine succeeds, it returns STATUS_SUCCESS. Otherwise,
-            it returns one of the error status values defined in ntstatus.h.
-  */
-  static NTSTATUS EvtDeviceAddEntry(WDFDRIVER wdf_drv,
-                                    PWDFDEVICE_INIT device_init);
-
-  /** \brief Driver unload event entry point.
-
-    Framework calls this callback when driver is being unloaded.
-    This method is called at IRQL PASSIVE_LEVEL.
-  */
-  static VOID EvtDriverUnloadEntry(WDFDRIVER wdf_drv);
-
- public:
-
-  /// Gets this driver's DRIVER_OBJECT
-  __forceinline PDRIVER_OBJECT driver_object() const {
-    return driver_object_;
-  }
-
-  /// Gets KMDF driver handle
-  __forceinline WDFDRIVER wdf_driver() const {
-    return wdf_driver_;
-  }
-
- private:
-  /// This driver's driver object
-  PDRIVER_OBJECT    driver_object_;
-
-  /// KMDF driver handle
-  WDFDRIVER         wdf_driver_;
-};
-
-#endif  // ANDROID_USB_DRIVER_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_file_object.cpp b/host/windows/usb/driver/android_usb_file_object.cpp
deleted file mode 100644
index e5ce0a2..0000000
--- a/host/windows/usb/driver/android_usb_file_object.cpp
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbFileObject that
-  encapsulates a common extension for all KMDF file object types.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_file_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbFileObject::AndroidUsbFileObject(AndroidUsbFileObjectType fo_type,
-                                           AndroidUsbDeviceObject* dev_obj,
-                                           WDFFILEOBJECT wdf_fo)
-    : AndroidUsbWdfObject(AndroidUsbWdfObjectTypeFile),
-      file_type_(fo_type),
-      device_object_(dev_obj) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(NULL != dev_obj);
-  ASSERT(fo_type < AndroidUsbFileObjectTypeMax);
-  ASSERT(NULL != wdf_fo);
-  set_wdf_object(wdf_fo);
-}
-
-#pragma code_seg()
-
-AndroidUsbFileObject::~AndroidUsbFileObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-#pragma code_seg("PAGE")
-
-NTSTATUS AndroidUsbFileObject::Initialize() {
-  ASSERT_IRQL_LOW();
-  ASSERT(NULL != wdf_file());
-  if (NULL == wdf_file())
-    return STATUS_INTERNAL_ERROR;
-  
-  // Register context for this file object
-  return InitializeContext();
-}
-
-#pragma code_seg()
-
-void AndroidUsbFileObject::OnEvtIoRead(WDFREQUEST request,
-                                       size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(WdfRequestGetFileObject(request) == wdf_file());
-  // Complete zero reads with success
-  if (0 == length) {
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, 0);
-    return;
-  }
-
-  WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-}
-
-void AndroidUsbFileObject::OnEvtIoWrite(WDFREQUEST request,
-                                        size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(WdfRequestGetFileObject(request) == wdf_file());
-  // Complete zero writes with success
-  if (0 == length) {
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, 0);
-    return;
-  }
-
-  WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-}
-
-void AndroidUsbFileObject::OnEvtIoDeviceControl(WDFREQUEST request,
-                                                size_t output_buf_len,
-                                                size_t input_buf_len,
-                                                ULONG ioctl_code) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  ASSERT(WdfRequestGetFileObject(request) == wdf_file());
-
-  WdfRequestComplete(request, STATUS_INVALID_DEVICE_REQUEST);
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_file_object.h b/host/windows/usb/driver/android_usb_file_object.h
deleted file mode 100644
index 1dbb92b..0000000
--- a/host/windows/usb/driver/android_usb_file_object.h
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_FILE_OBJECT_H__
-#define ANDROID_USB_FILE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbFileObject that
-  encapsulates a common extension for all KMDF file object types.
-*/
-
-#include "android_usb_wdf_object.h"
-#include "android_usb_device_object.h"
-
-/** Enumerator AndroidUsbFileObjectType defines possible types for our file
-  object extension.
-*/
-enum AndroidUsbFileObjectType {
-  /// File extends device FO
-  AndroidUsbFileObjectTypeDevice,
-
-  // File extends a pipe FO
-  AndroidUsbFileObjectTypePipe,
-
-  AndroidUsbFileObjectTypeMax,
-};
-
-/** AndroidUsbFileObject class encapsulates a common extension for all KMDF
-  file object types. Instances of this class must be allocated from
-  NonPagedPool.
-*/
-class AndroidUsbFileObject : public AndroidUsbWdfObject {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-    @param fo_type[in] Type of the file object that this object extends
-    @param dev_obj[in] Our device object for which this file has been created
-    @param wdf_fo[in] KMDF file object for this extension 
-  */
-  AndroidUsbFileObject(AndroidUsbFileObjectType fo_type,
-                       AndroidUsbDeviceObject* dev_obj,
-                       WDFFILEOBJECT wdf_fo);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   virtual ~AndroidUsbFileObject();
-
-  /** \brief Initializes the object
-
-    This method verifies that instance has been created and calls base class's
-    InitializeContext method to register itself with the wrapped FO. All
-    derived classes must call this method when initializing.
-    This method must be called at low IRQL.
-    @return STATUS_SUCCESS on success or an appropriate error code
-  */
-  virtual NTSTATUS Initialize();
-
-  /** \brief Read event handler
-
-    This method is called when a read request comes to the file object this
-    class extends.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be read.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoRead(WDFREQUEST request, size_t length);
-
-  /** \brief Write event handler
-
-    This method is called when a write request comes to the file object this
-    class extends.
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be written.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoWrite(WDFREQUEST request, size_t length);
-
-  /** \brief IOCTL event handler
-
-    This method is called when a device control request comes to the file
-    object this class extends.
-    This callback can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param ioctl_code[in] The driver-defined or system-defined I/O control code
-           that is associated with the request.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoDeviceControl(WDFREQUEST request,
-                                    size_t output_buf_len,
-                                    size_t input_buf_len,
-                                    ULONG ioctl_code);
-
- public:
-  /// Gets KMDF file handle for this extension
-  __forceinline WDFFILEOBJECT wdf_file() const {
-    return reinterpret_cast<WDFFILEOBJECT>(wdf_object());
-  }
-
-  /// Gets device object that owns this file
-  __forceinline AndroidUsbDeviceObject* device_object() const {
-    return device_object_;
-  }
-
-  /// Gets type of the file object that this extension wraps
-  __forceinline AndroidUsbFileObjectType file_type() const {
-    return file_type_;
-  }
-
-  /// Gets WDF device handle for device that owns this file
-  __forceinline WDFDEVICE wdf_device() const {
-    ASSERT(NULL != device_object());
-    return (NULL != device_object()) ? device_object()->wdf_device() :
-                                       NULL;
-  }
-
-  /// Gets target (PDO) device handle for the device that owns this file
-  __forceinline WDFUSBDEVICE wdf_target_device() const {
-    ASSERT(NULL != device_object());
-    return (NULL != device_object()) ? device_object()->wdf_target_device() :
-                                       NULL;
-  }
-
- protected:
-  /// Device object that owns this file
-  AndroidUsbDeviceObject*   device_object_;
-
-  /// Type of the file object that this extension wraps
-  AndroidUsbFileObjectType  file_type_;
-};
-
-/** \brief Gets file KMDF object extension for the given KMDF file object
-
-  This method can be called at any IRQL
-  @param wdf_fo[in] KMDF file handle describing file object
-  @return Instance of AndroidUsbFileObject associated with this object or NULL
-          if association is not found.
-*/
-__forceinline AndroidUsbFileObject* GetAndroidUsbFileObjectFromHandle(
-    WDFFILEOBJECT wdf_fo) {
-  AndroidUsbWdfObject* wdf_object_ext =
-    GetAndroidUsbWdfObjectFromHandle(wdf_fo);
-  ASSERT(NULL != wdf_object_ext);
-  if (NULL != wdf_object_ext) {
-    ASSERT(wdf_object_ext->Is(AndroidUsbWdfObjectTypeFile));
-    if (wdf_object_ext->Is(AndroidUsbWdfObjectTypeFile))
-      return reinterpret_cast<AndroidUsbFileObject*>(wdf_object_ext);
-  }
-  return NULL;
-}
-
-/** \brief Gets file KMDF file object extension for the given request
-
-  This method can be called at any IRQL
-  @param request[in] KMDF request object
-  @return Instance of AndroidUsbFileObject associated with this request or NULL
-          if association is not found.
-*/
-__forceinline AndroidUsbFileObject* GetAndroidUsbFileObjectForRequest(
-    WDFREQUEST request) {
-  return GetAndroidUsbFileObjectFromHandle(WdfRequestGetFileObject(request));
-}
-
-#endif  // ANDROID_USB_FILE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_inl.h b/host/windows/usb/driver/android_usb_inl.h
deleted file mode 100644
index 8d697cf..0000000
--- a/host/windows/usb/driver/android_usb_inl.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_INL_H__
-#define ANDROID_USB_INL_H__
-/** \file
-  This file consists of inline routines for the driver.
-*/
-
-/// Gets control code out of the entire IOCTL code packet
-__forceinline ULONG GetCtlCode(ULONG ioctl_code) {
-  return (ioctl_code >> 2) & 0x0FFF;
-}
-
-/** \brief
-  Converts string length from number of wide characters into number of bytes.
-*/
-__forceinline USHORT ByteLen(USHORT wchar_len) {
-  return static_cast<USHORT>(wchar_len * sizeof(WCHAR));
-}
-
-/** \brief Gets byte length of a zero-terminated string not including
-  zero terminator. Must be called at low IRQL.
-*/
-__forceinline USHORT ByteLen(const WCHAR* str) {
-  ASSERT_IRQL_LOW();
-  return (NULL != str) ? ByteLen(static_cast<USHORT>(wcslen(str))) : 0;
-}
-
-/** \brief
-  Converts string length from number of bytes into number of wide characters.
-  Can be called at any IRQL.
-*/
-__forceinline USHORT WcharLen(USHORT byte_len) {
-  return byte_len / sizeof(WCHAR);
-}
-
-/** \brief Retrieves pointer out of the WDFMEMORY handle
-*/
-__forceinline void* GetAddress(WDFMEMORY wdf_mem) {
-  ASSERT(NULL != wdf_mem);
-  return (NULL != wdf_mem) ? WdfMemoryGetBuffer(wdf_mem, NULL) : NULL;
-}
-
-/** \brief Retrieves output memory address for WDFREQUEST
-
-  @param request[in] A handle to KMDF request object
-  @param status[out] Receives status of the call. Can be NULL.
-*/
-__forceinline void* OutAddress(WDFREQUEST request, NTSTATUS* status) {
-  ASSERT(NULL != request);
-  WDFMEMORY wdf_mem = NULL;
-  NTSTATUS stat = WdfRequestRetrieveOutputMemory(request, &wdf_mem);
-  ASSERT((NULL != wdf_mem) || (!NT_SUCCESS(stat)));
-  if (NULL != status)
-    *status = stat;
-  return NT_SUCCESS(stat) ? GetAddress(wdf_mem) : NULL;
-}
-
-/** \brief Retrieves input memory address for WDFREQUEST
-
-  @param request[in] A handle to KMDF request object
-  @param status[out] Receives status of the call. Can be NULL.
-*/
-__forceinline void* InAddress(WDFREQUEST request, NTSTATUS* status) {
-  ASSERT(NULL != request);
-  WDFMEMORY wdf_mem = NULL;
-  NTSTATUS stat = WdfRequestRetrieveInputMemory(request, &wdf_mem);
-  ASSERT((NULL != wdf_mem) || (!NT_SUCCESS(stat)));
-  if (NULL != status)
-    *status = stat;
-  return NT_SUCCESS(stat) ? GetAddress(wdf_mem) : NULL;
-}
-
-#endif  // ANDROID_USB_INL_H__
diff --git a/host/windows/usb/driver/android_usb_interrupt_file_object.cpp b/host/windows/usb/driver/android_usb_interrupt_file_object.cpp
deleted file mode 100644
index d6303bb..0000000
--- a/host/windows/usb/driver/android_usb_interrupt_file_object.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbInterruptPipeFileObject
-  that encapsulates extension to an interrupt pipe file objects.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_interrupt_file_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbInterruptPipeFileObject::AndroidUsbInterruptPipeFileObject(
-    AndroidUsbDeviceObject* dev_obj,
-    WDFFILEOBJECT wdf_fo,
-    WDFUSBPIPE wdf_pipe_obj)
-    : AndroidUsbPipeFileObject(dev_obj, wdf_fo, wdf_pipe_obj) {
-  ASSERT_IRQL_PASSIVE();
-
-#if DBG
-  WDF_USB_PIPE_INFORMATION pipe_info;
-  WDF_USB_PIPE_INFORMATION_INIT(&pipe_info);
-  WdfUsbTargetPipeGetInformation(wdf_pipe_obj, &pipe_info);
-  ASSERT(WdfUsbPipeTypeInterrupt == pipe_info.PipeType);
-#endif  // DBG
-
-}
-
-#pragma code_seg()
-
-AndroidUsbInterruptPipeFileObject::~AndroidUsbInterruptPipeFileObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_interrupt_file_object.h b/host/windows/usb/driver/android_usb_interrupt_file_object.h
deleted file mode 100644
index 5bf097b..0000000
--- a/host/windows/usb/driver/android_usb_interrupt_file_object.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_INTERRUPT_PIPE_FILE_OBJECT_H__
-#define ANDROID_USB_INTERRUPT_PIPE_FILE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbInterruptPipeFileObject
-  that encapsulates extension to an interrupt pipe file objects.
-*/
-
-#include "android_usb_pipe_file_object.h"
-
-/** AndroidUsbInterruptPipeFileObject class encapsulates extension for a KMDF
-  file object that represent opened interrupt pipe. Instances of this class
-  must be allocated from NonPagedPool.
-*/
-class AndroidUsbInterruptPipeFileObject : public AndroidUsbPipeFileObject {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-    @param dev_obj[in] Our device object for which this file has been created
-    @param wdf_fo[in] KMDF file object this extension wraps
-    @param wdf_pipe_obj[in] KMDF pipe for this file
-  */
-  AndroidUsbInterruptPipeFileObject(AndroidUsbDeviceObject* dev_obj,
-                                    WDFFILEOBJECT wdf_fo,
-                                    WDFUSBPIPE wdf_pipe_obj);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   virtual ~AndroidUsbInterruptPipeFileObject();
-};
-
-#endif  // ANDROID_USB_INTERRUPT_PIPE_FILE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_new_delete.h b/host/windows/usb/driver/android_usb_new_delete.h
deleted file mode 100644
index dc4634d..0000000
--- a/host/windows/usb/driver/android_usb_new_delete.h
+++ /dev/null
@@ -1,154 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_NEW_DELETE_H__
-#define ANDROID_USB_NEW_DELETE_H__
-/** \file
-  This file consists implementations of our 'new' and 'delete' operators
-*/
-
-#include "android_usb_pool_tags.h"
-
-/** \brief Checks if given pool type is one of NonPaged pool kinds.
-
-  All numeric values for all NonPaged pool types are even numbers while all
-  numeric values for all PagedPool types are odd numbers (see definition of
-  POOL_TYPE enum). So this routine utilizes this to see whether given pool
-  type is one of NonPaged pool kinds. This routine can be called at any IRQL.
-  @param pool_type[in] Pool type
-  @return True if pool type is one of NonPaged pool types, false otherwise
-*/
-__forceinline bool IsPoolNonPaged(POOL_TYPE pool_type) {
-  return (0 == (pool_type & 0x1));
-}
-
-/** @name Operators new and delete
- 
-  In Kernel Mode development each memory allocation must specify type of the
-  pool from which memory should be allocated, usualy PagedPool or NonPagedPool.
-  Because of that "traditional" operator 'new' that takes only one parameter
-  (memory size) is not good so we modify that operator by adding two more
-  parameters: pool type and memory tag (last one is optional but highly
-  encouraged). To prevent from mistakes, traditional operator 'new' is also
-  defined. It will allocate requested number of bytes from NonPagedPool with
-  default memory tag but it will always assert on checked (debug) builds.
-  Since there is no infrastructure for C++ exceptions in Kernel Mode we are
-  not using them to report memory allocation error. So, on failure operators
-  'new' are returning NULL instead of throwing an exception.
-*/
-///@{
-
-/** \brief Main operator new
-
-  This is the main operator new that allocates specified number of bytes from
-  the specified pool and assigns a custom tag to the allocated memory.
-  Inherits IRQL restrictions for ExAllocatePoolWithTag (see the DDK doc).
-  @param size[in] Number of bytes to allocate.
-  @param pool_type[in] Type of the pool to allocate from.
-  @param pool_tag[in] A tag to attach to the allocated memory. Since utilities
-         that display tags use their ASCII representations it's advisable to
-         use tag values that are ASCII symbols, f.i. 'ATag'. Note that due to
-         inversion of bytes in stored ULONG value, to read 'ATag' in the tag
-         displaying utility, the actual value passed to operator 'new' must be
-         'gaTA'
-  @return Pointer to allocated memory on success, NULL on error.
-*/
-__forceinline void* __cdecl operator new(size_t size,
-                                         POOL_TYPE pool_type,
-                                         ULONG pool_tag) {
-  ASSERT((pool_type < MaxPoolType) && (0 != size));
-  // Enforce IRQL restriction check.
-  ASSERT(IsPoolNonPaged(pool_type) || (KeGetCurrentIrql() < DISPATCH_LEVEL));
-  return size ? ExAllocatePoolWithTag(pool_type,
-                                      static_cast<ULONG>(size),
-                                      pool_tag) :
-                NULL;
-}
-
-/** \brief
-  Short operator new that attaches a default tag to the allocated memory.
-
-  This version of operator new allocates specified number of bytes from the
-  specified pool and assigns a default tag (GANDR_POOL_TAG_DEFAULT) to the
-  allocated memory. Inherits IRQL restrictions for ExAllocatePoolWithTag.
-  @param size[in] Number of bytes to allocate.
-  @param pool_type[in] Type of the pool to allocate from.
-  @return Pointer to allocated memory on success, NULL on error.
-*/
-__forceinline void* __cdecl operator new(size_t size, POOL_TYPE pool_type) {
-  ASSERT((pool_type < MaxPoolType) && (0 != size));
-  // Enforce IRQL restriction check.
-  ASSERT(IsPoolNonPaged(pool_type) || (KeGetCurrentIrql() < DISPATCH_LEVEL));
-  return size ? ExAllocatePoolWithTag(pool_type,
-                                      static_cast<ULONG>(size),
-                                      GANDR_POOL_TAG_DEFAULT) :
-                NULL;
-}
-
-/** \brief Traditional operator new that should never be used.
-
-  Using of this version of operator 'new' is prohibited in Kernel Mode
-  development. For the sake of safety it is implemented though to allocate
-  requested number of bytes from the NonPagedPool and attach default tag
-  to the allocated memory. It will assert on checked (debug) builds.
-  Inherits IRQL restrictions for ExAllocatePoolWithTag.
-  @param size[in] Number of bytes to allocate.
-  @return Pointer to memory allocated from NonPagedPool on success or NULL on
-          error.
-*/
-__forceinline void* __cdecl operator new(size_t size) {
-  ASSERTMSG("\n!!! Using of operator new(size_t size) is detected!\n"
-    "This is illegal in our driver C++ development environment to use "
-    "this version of operator 'new'. Please switch to\n"
-    "new(size_t size, POOL_TYPE pool_type) or "
-    "new(size_t size, POOL_TYPE pool_type, ULONG pool_tag) ASAP!!!\n",
-    false);
-  ASSERT(0 != size);
-  return size ? ExAllocatePoolWithTag(NonPagedPool,
-                                      static_cast<ULONG>(size),
-                                      GANDR_POOL_TAG_DEFAULT) :
-                NULL;
-}
-
-/** \brief Operator delete.
-
-  Frees memory allocated by 'new' operator.
-  @param pointer[in] Memory to free. If this parameter is NULL operator does
-         nothing but asserts on checked build. Inherits IRQL restrictions
-         for ExFreePool.
-*/
-__forceinline void __cdecl operator delete(void* pointer) {
-  ASSERT(NULL != pointer);
-  if (NULL != pointer)
-    ExFreePool(pointer);
-}
-
-/** \brief Operator delete for arrays.
-
-  Frees memory allocated by 'new' operator.
-  @param pointer[in] Memory to free. If this parameter is NULL operator does
-         nothing but asserts on checked build. Inherits IRQL restrictions
-         for ExFreePool.
-*/
-__forceinline void __cdecl operator delete[](void* pointer) {
-  ASSERT(NULL != pointer);
-  if (NULL != pointer)
-    ExFreePool(pointer);
-}
-
-///@}
-
-#endif  // ANDROID_USB_NEW_DELETE_H__
diff --git a/host/windows/usb/driver/android_usb_pipe_file_object.cpp b/host/windows/usb/driver/android_usb_pipe_file_object.cpp
deleted file mode 100644
index 3846683..0000000
--- a/host/windows/usb/driver/android_usb_pipe_file_object.cpp
+++ /dev/null
@@ -1,738 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of class AndroidUsbPipeFileObject that
-  encapsulates a common extension for pipe file objects.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_pipe_file_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbPipeFileObject::AndroidUsbPipeFileObject(
-    AndroidUsbDeviceObject* dev_obj,
-    WDFFILEOBJECT wdf_fo,
-    WDFUSBPIPE wdf_pipe_obj)
-    : AndroidUsbFileObject(AndroidUsbFileObjectTypePipe, dev_obj, wdf_fo),
-      wdf_pipe_(wdf_pipe_obj) {
-  ASSERT_IRQL_PASSIVE();
-  ASSERT(NULL != wdf_pipe_obj);
-}
-
-#pragma code_seg()
-
-AndroidUsbPipeFileObject::~AndroidUsbPipeFileObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-#pragma code_seg("PAGE")
-
-NTSTATUS AndroidUsbPipeFileObject::InitializePipe(
-    const WDF_USB_PIPE_INFORMATION* pipe_info) {
-  ASSERT_IRQL_LOW();
-  ASSERT(IsPipeAttached());
-  if (!IsPipeAttached())
-    return STATUS_INTERNAL_ERROR;
-
-  // Initialize base class
-  NTSTATUS status = AndroidUsbFileObject::Initialize();
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Save pipe information
-  pipe_information_ = *pipe_info;
-
-  // We will provide size check ourselves (less surprizes always better)
-  WdfUsbTargetPipeSetNoMaximumPacketSizeCheck(wdf_pipe());
-
-  GoogleDbgPrint("\n===== File %p for %s pipe. max_transfer_size = %X, max_packet_size = %X",
-                 this, is_input_pipe() ? "read" : "write",
-                 max_transfer_size(), max_packet_size());
-  return STATUS_SUCCESS;
-}
-
-#pragma code_seg()
-
-void AndroidUsbPipeFileObject::OnEvtIoRead(WDFREQUEST request,
-                                           size_t length) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Make sure that this is an input pipe
-  if (is_output_pipe()) {
-    GoogleDbgPrint("\n!!!! Attempt to read from output pipe %p", this);
-    WdfRequestComplete(request, STATUS_ACCESS_DENIED);
-    return;
-  }
-
-  // Make sure zero length I/O doesn't go through
-  if (0 == length) {
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, 0);
-    return;
-  }
-
-  // Get MDL for this request.
-  PMDL request_mdl = NULL;
-  NTSTATUS status = WdfRequestRetrieveOutputWdmMdl(request, &request_mdl);
-  ASSERT(NT_SUCCESS(status) && (NULL != request_mdl));
-  if (NT_SUCCESS(status)) {
-    CommonBulkReadWrite(request,
-                        request_mdl,
-                        static_cast<ULONG>(length),
-                        true,
-                        0,
-                        false);
-  } else {
-    WdfRequestComplete(request, status);
-  }
-}
-
-void AndroidUsbPipeFileObject::OnEvtIoWrite(WDFREQUEST request,
-                                            size_t length) {
-
-  // Make sure that this is an output pipe
-  if (is_input_pipe()) {
-    GoogleDbgPrint("\n!!!! Attempt to write to input pipe %p", this);
-    WdfRequestComplete(request, STATUS_ACCESS_DENIED);
-    return;
-  }
-
-  // Make sure zero length I/O doesn't go through
-  if (0 == length) {
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, 0);
-    return;
-  }
-
-  // Get MDL for this request.
-  PMDL request_mdl = NULL;
-  NTSTATUS status = WdfRequestRetrieveInputWdmMdl(request, &request_mdl);
-  ASSERT(NT_SUCCESS(status) && (NULL != request_mdl));
-  if (NT_SUCCESS(status)) {
-    CommonBulkReadWrite(request,
-                        request_mdl,
-                        static_cast<ULONG>(length),
-                        false,
-                        0,
-                        false);
-  } else {
-    WdfRequestComplete(request, status);
-  }
-}
-
-void AndroidUsbPipeFileObject::OnEvtIoDeviceControl(WDFREQUEST request,
-                                                    size_t output_buf_len,
-                                                    size_t input_buf_len,
-                                                    ULONG ioctl_code) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  switch (ioctl_code) {
-    case ADB_IOCTL_GET_ENDPOINT_INFORMATION:
-      OnCtlGetEndpointInformation(request, output_buf_len);
-      break;
-
-    case ADB_IOCTL_BULK_READ:
-      OnCtlBulkRead(request, output_buf_len, input_buf_len);
-      break;
-
-    case ADB_IOCTL_BULK_WRITE:
-      OnCtlBulkWrite(request, output_buf_len, input_buf_len);
-      break;
-
-    default:
-      AndroidUsbFileObject::OnEvtIoDeviceControl(request,
-                                                 output_buf_len,
-                                                 input_buf_len,
-                                                 ioctl_code);
-      break;
-  }
-}
-
-void AndroidUsbPipeFileObject::OnCtlGetEndpointInformation(
-    WDFREQUEST request,
-    size_t output_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Verify output buffer
-  if (output_buf_len < sizeof(AdbEndpointInformation)) {
-    WdfRequestCompleteWithInformation(request,
-                                      STATUS_BUFFER_TOO_SMALL,
-                                      sizeof(AdbEndpointInformation));
-    return;
-  }
-
-  // Get the output buffer
-  NTSTATUS status;
-  AdbEndpointInformation* ret_info =
-    reinterpret_cast<AdbEndpointInformation*>(OutAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != ret_info));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Copy endpoint info to the output
-  ret_info->max_packet_size = pipe_information_.MaximumPacketSize;
-  ret_info->endpoint_address = pipe_information_.EndpointAddress;
-  ret_info->polling_interval = pipe_information_.Interval;
-  ret_info->setting_index = pipe_information_.SettingIndex;
-  ret_info->endpoint_type =
-    static_cast<AdbEndpointType>(pipe_information_.PipeType);
-  ret_info->max_transfer_size = pipe_information_.MaximumTransferSize;
-
-  WdfRequestCompleteWithInformation(request,
-                                    STATUS_SUCCESS,
-                                    sizeof(AdbEndpointInformation));
-}
-
-void AndroidUsbPipeFileObject::OnCtlBulkRead(WDFREQUEST request,
-                                             size_t output_buf_len,
-                                             size_t input_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Make sure that this is an input pipe
-  if (is_output_pipe()) {
-    GoogleDbgPrint("\n!!!! Attempt to IOCTL read from output pipe %p", this);
-    WdfRequestComplete(request, STATUS_ACCESS_DENIED);
-    return;
-  }
-
-  // Make sure zero length I/O doesn't go through
-  if (0 == output_buf_len) {
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, 0);
-    return;
-  }
-
-  // Verify buffers
-  ASSERT(input_buf_len >= sizeof(AdbBulkTransfer));
-  if (input_buf_len < sizeof(AdbBulkTransfer)) {
-    WdfRequestComplete(request, STATUS_INVALID_BUFFER_SIZE);
-    return;
-  }
-
-  // Get the input buffer
-  NTSTATUS status;
-  AdbBulkTransfer* transfer_param =
-    reinterpret_cast<AdbBulkTransfer*>(InAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != transfer_param));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Get MDL for this request.
-  PMDL request_mdl = NULL;
-  status = WdfRequestRetrieveOutputWdmMdl(request, &request_mdl);
-  ASSERT(NT_SUCCESS(status) && (NULL != request_mdl));
-  if (NT_SUCCESS(status)) {
-    // Perform the read
-    CommonBulkReadWrite(request,
-                        request_mdl,
-                        static_cast<ULONG>(output_buf_len),
-                        true,
-                        transfer_param->time_out,
-                        true);
-  } else {
-    WdfRequestComplete(request, status);
-  }
-}
-
-void AndroidUsbPipeFileObject::OnCtlBulkWrite(WDFREQUEST request,
-                                              size_t output_buf_len,
-                                              size_t input_buf_len) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Make sure that this is an output pipe
-  if (is_input_pipe()) {
-    GoogleDbgPrint("\n!!!! Attempt to IOCTL write to input pipe %p", this);
-    WdfRequestComplete(request, STATUS_ACCESS_DENIED);
-    return;
-  }
-
-  // Verify buffers
-  ASSERT(input_buf_len >= sizeof(AdbBulkTransfer));
-  // Output buffer points to ULONG that receives number of transferred bytes
-  ASSERT(output_buf_len >= sizeof(ULONG));
-  if ((input_buf_len < sizeof(AdbBulkTransfer)) ||
-      (output_buf_len < sizeof(ULONG))) {
-    WdfRequestComplete(request, STATUS_INVALID_BUFFER_SIZE);
-    return;
-  }
-
-  // Get the input buffer
-  NTSTATUS status = STATUS_SUCCESS;
-  AdbBulkTransfer* transfer_param =
-    reinterpret_cast<AdbBulkTransfer*>(InAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != transfer_param));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Get the output buffer
-  ULONG* ret_transfer =
-    reinterpret_cast<ULONG*>(OutAddress(request, &status));
-  ASSERT(NT_SUCCESS(status) && (NULL != ret_transfer));
-  if (!NT_SUCCESS(status)) {
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Cache these param to prevent us from sudden change after we've chacked it.
-  // This is common practice in protecting ourselves from malicious code:
-  // 1. Never trust anything that comes from the User Mode.
-  // 2. Never assume that anything that User Mode buffer has will remain
-  // unchanged.
-  void* transfer_buffer = transfer_param->GetWriteBuffer();
-  ULONG transfer_size = transfer_param->transfer_size;
-
-  // Make sure zero length I/O doesn't go through
-  if (0 == transfer_size) {
-    *ret_transfer = 0;
-    WdfRequestCompleteWithInformation(request, STATUS_SUCCESS, sizeof(ULONG));
-    return;
-  }
-
-  // Make sure that buffer is not NULL
-  ASSERT(NULL != transfer_buffer);
-  if (NULL == transfer_buffer) {
-    WdfRequestComplete(request, STATUS_INVALID_PARAMETER);
-    return;
-  }
-
-  // At this point we are ready to build MDL for the user buffer.
-  PMDL write_mdl =
-    IoAllocateMdl(transfer_buffer, transfer_size, FALSE, FALSE, NULL);
-  ASSERT(NULL != write_mdl);
-  if (NULL == write_mdl) {
-    WdfRequestComplete(request, STATUS_INSUFFICIENT_RESOURCES);
-    return;
-  }
-
-  // Now we need to probe/lock this mdl
-  __try {
-    MmProbeAndLockPages(write_mdl,
-                        WdfRequestGetRequestorMode(request),
-                        IoReadAccess);
-    status = STATUS_SUCCESS;
-  } __except (EXCEPTION_EXECUTE_HANDLER) {
-    status = GetExceptionCode();
-    ASSERTMSG("\n!!!!! AndroidUsbPipeFileObject::OnCtlBulkWrite exception",
-              false);
-  }
-
-  if (!NT_SUCCESS(status)) {
-    IoFreeMdl(write_mdl);
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Perform the write
-  status = CommonBulkReadWrite(request,
-                               write_mdl,
-                               transfer_size,
-                               false,
-                               transfer_param->time_out,
-                               true);
-  if (!NT_SUCCESS(status)) {
-    // If CommonBulkReadWrite failed we need to unlock and free MDL here
-    MmUnlockPages(write_mdl);
-    IoFreeMdl(write_mdl);
-  }
-}
-
-NTSTATUS AndroidUsbPipeFileObject::CommonBulkReadWrite(
-    WDFREQUEST request,
-    PMDL transfer_mdl,
-    ULONG length,
-    bool is_read,
-    ULONG time_out,
-    bool is_ioctl) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  ASSERT(IsPipeAttached());
-  if (!IsPipeAttached()) {
-    WdfRequestComplete(request, STATUS_INVALID_DEVICE_STATE);
-    return STATUS_INVALID_DEVICE_STATE;
-  }
-
-  // Quick access check. Might be redundant though...
-  ASSERT((is_read && is_input_pipe()) || (!is_read && is_output_pipe()));
-  if ((is_read && is_output_pipe()) || (!is_read && is_input_pipe())) {
-    WdfRequestComplete(request, STATUS_ACCESS_DENIED);
-    return STATUS_ACCESS_DENIED;
-  }
-
-  // Set URB flags
-  ULONG urb_flags = USBD_SHORT_TRANSFER_OK | (is_read ?
-                                                USBD_TRANSFER_DIRECTION_IN :
-                                                USBD_TRANSFER_DIRECTION_OUT);
-
-  // Calculate transfer length for this stage.
-  ULONG stage_len =
-    (length > GetTransferGranularity()) ? GetTransferGranularity() : length;
-
-  // Get virtual address that we're gonna use in the transfer.
-  // We rely here on the fact that we're in the context of the calling thread.
-  void* virtual_address = MmGetMdlVirtualAddress(transfer_mdl);
-
-  // Allocate our private MDL for this address which we will use for the transfer
-  PMDL new_mdl = IoAllocateMdl(virtual_address, length, FALSE, FALSE, NULL);
-  ASSERT(NULL != new_mdl);
-  if (NULL == new_mdl) {
-    WdfRequestComplete(request, STATUS_INSUFFICIENT_RESOURCES);
-    return STATUS_INSUFFICIENT_RESOURCES;
-  }
-
-  // Map the portion of user buffer that we're going to transfer at this stage
-  // to our mdl.
-  IoBuildPartialMdl(transfer_mdl, new_mdl, virtual_address, stage_len);
-
-  // Allocate memory for URB and associate it with this request
-  WDF_OBJECT_ATTRIBUTES mem_attrib;
-  WDF_OBJECT_ATTRIBUTES_INIT(&mem_attrib);
-  mem_attrib.ParentObject = request;
-
-  WDFMEMORY urb_mem = NULL;
-  PURB urb = NULL;
-  NTSTATUS status =
-    WdfMemoryCreate(&mem_attrib,
-                    NonPagedPool,
-                    GANDR_POOL_TAG_BULKRW_URB,
-                    sizeof(struct _URB_BULK_OR_INTERRUPT_TRANSFER),
-                    &urb_mem,
-                    reinterpret_cast<PVOID*>(&urb));
-  ASSERT(NT_SUCCESS(status) && (NULL != urb));
-  if (!NT_SUCCESS(status)) {
-    IoFreeMdl(new_mdl);
-    WdfRequestComplete(request, STATUS_INSUFFICIENT_RESOURCES);
-    return STATUS_INSUFFICIENT_RESOURCES;
-  }
-
-  // Get USB pipe handle for our pipe and initialize transfer request for it
-  USBD_PIPE_HANDLE usbd_pipe_hndl = usbd_pipe();
-  ASSERT(NULL != usbd_pipe_hndl);
-  if (NULL == usbd_pipe_hndl) {
-    IoFreeMdl(new_mdl);
-    WdfRequestComplete(request, STATUS_INTERNAL_ERROR);
-    return STATUS_INTERNAL_ERROR;
-  }
-
-  // Initialize URB with request information
-  UsbBuildInterruptOrBulkTransferRequest(
-    urb,
-    sizeof(struct _URB_BULK_OR_INTERRUPT_TRANSFER),
-    usbd_pipe_hndl,
-    NULL,
-    new_mdl,
-    stage_len,
-    urb_flags,
-    NULL);
-
-  // Build transfer request
-  status = WdfUsbTargetPipeFormatRequestForUrb(wdf_pipe(),
-                                               request,
-                                               urb_mem,
-                                               NULL);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status)) {
-    IoFreeMdl(new_mdl);
-    WdfRequestComplete(request, status);
-    return status;
-  }
-
-  // Initialize our request context.
-  AndroidUsbWdfRequestContext* context =
-    GetAndroidUsbWdfRequestContext(request);
-  ASSERT(NULL != context);
-  if (NULL == context) {
-    IoFreeMdl(new_mdl);
-    WdfRequestComplete(request, STATUS_INTERNAL_ERROR);
-    return STATUS_INTERNAL_ERROR;
-  }
-
-  context->object_type = AndroidUsbWdfObjectTypeRequest;
-  context->urb_mem = urb_mem;
-  context->transfer_mdl = transfer_mdl;
-  context->mdl = new_mdl;
-  context->length = length;
-  context->transfer_size = stage_len;
-  context->num_xfer = 0;
-  context->virtual_address = virtual_address;
-  context->is_read = is_read;
-  context->initial_time_out = time_out;
-  context->is_ioctl = is_ioctl;
-
-  // Set our completion routine
-  WdfRequestSetCompletionRoutine(request,
-                                 CommonReadWriteCompletionEntry,
-                                 this);
-
-  // Init send options (our timeout goes here)
-  WDF_REQUEST_SEND_OPTIONS send_options;
-  if (0 != time_out) {
-    WDF_REQUEST_SEND_OPTIONS_INIT(&send_options, WDF_REQUEST_SEND_OPTION_TIMEOUT);
-    WDF_REQUEST_SEND_OPTIONS_SET_TIMEOUT(&send_options, WDF_REL_TIMEOUT_IN_MS(time_out));
-  }
-
-  // Timestamp first WdfRequestSend
-  KeQuerySystemTime(&context->sent_at);
-
-  // Send request asynchronously.
-  if (WdfRequestSend(request, wdf_pipe_io_target(),
-                     (0 == time_out) ? WDF_NO_SEND_OPTIONS : &send_options)) {
-    return STATUS_SUCCESS;
-  }
-
-  // Something went wrong here
-  status = WdfRequestGetStatus(request);
-  ASSERT(!NT_SUCCESS(status));
-  GoogleDbgPrint("\n!!!!! CommonBulkReadWrite: WdfRequestGetStatus (is_read = %u) failed: %08X",
-           is_read, status);
-  WdfRequestCompleteWithInformation(request, status, 0);
-
-  return status;
-}
-
-void AndroidUsbPipeFileObject::OnCommonReadWriteCompletion(
-    WDFREQUEST request,
-    PWDF_REQUEST_COMPLETION_PARAMS completion_params,
-    AndroidUsbWdfRequestContext* context) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  NTSTATUS status = completion_params->IoStatus.Status;
-  if (!NT_SUCCESS(status)){
-    GoogleDbgPrint("\n========== Request completed with failure: %X", status);
-    IoFreeMdl(context->mdl);
-    // If this was IOCTL-originated write we must unlock and free
-    // our transfer MDL.
-    if (context->is_ioctl && !context->is_read) {
-      MmUnlockPages(context->transfer_mdl);
-      IoFreeMdl(context->transfer_mdl);
-    }
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Get our URB buffer
-  PURB urb
-    = reinterpret_cast<PURB>(WdfMemoryGetBuffer(context->urb_mem, NULL));
-  ASSERT(NULL != urb);
-
-  // Lets see how much has been transfered and update our counters accordingly
-  ULONG bytes_transfered =
-    urb->UrbBulkOrInterruptTransfer.TransferBufferLength;
-  // We expect writes to transfer entire packet
-  ASSERT((bytes_transfered == context->transfer_size) || context->is_read);
-  context->num_xfer += bytes_transfered;
-  context->length -= bytes_transfered;
-
-  // Is there anything left to transfer? Now, by the protocol we should
-  // successfuly complete partial reads, instead of waiting on full set
-  // of requested bytes being accumulated in the read buffer.
-  if ((0 == context->length) || context->is_read) {
-    status = STATUS_SUCCESS;
-
-    // This was the last transfer
-    if (context->is_ioctl && !context->is_read) {
-      // For IOCTL-originated writes we have to return transfer size through
-      // the IOCTL's output buffer.
-      ULONG* ret_transfer =
-        reinterpret_cast<ULONG*>(OutAddress(request, NULL));
-      ASSERT(NULL != ret_transfer);
-      if (NULL != ret_transfer)
-        *ret_transfer = context->num_xfer;
-      WdfRequestSetInformation(request, sizeof(ULONG));
-
-      // We also must unlock / free transfer MDL
-      MmUnlockPages(context->transfer_mdl);
-      IoFreeMdl(context->transfer_mdl);
-    } else {
-      // For other requests we report transfer size through the request I/O
-      // completion status.
-      WdfRequestSetInformation(request, context->num_xfer);
-    }
-    IoFreeMdl(context->mdl);
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // There are something left for the transfer. Prepare for it.
-  // Required to free any mapping made on the partial MDL and
-  // reset internal MDL state.
-  MmPrepareMdlForReuse(context->mdl);
-
-  // Update our virtual address
-  context->virtual_address = 
-    reinterpret_cast<char*>(context->virtual_address) + bytes_transfered;
-
-  // Calculate size of this transfer
-  ULONG stage_len =
-    (context->length > GetTransferGranularity()) ? GetTransferGranularity() :
-                                                   context->length;
-
-  IoBuildPartialMdl(context->transfer_mdl,
-                    context->mdl,
-                    context->virtual_address,
-                    stage_len);
-
-  // Reinitialize the urb and context
-  urb->UrbBulkOrInterruptTransfer.TransferBufferLength = stage_len;
-  context->transfer_size = stage_len;
-
-  // Format the request to send a URB to a USB pipe.
-  status = WdfUsbTargetPipeFormatRequestForUrb(wdf_pipe(),
-                                               request,
-                                               context->urb_mem,
-                                               NULL);
-  ASSERT(NT_SUCCESS(status));
-  if (!NT_SUCCESS(status)) {
-    if (context->is_ioctl && !context->is_read) {
-      MmUnlockPages(context->transfer_mdl);
-      IoFreeMdl(context->transfer_mdl);
-    }
-    IoFreeMdl(context->mdl);
-    WdfRequestComplete(request, status);
-    return;
-  }
-
-  // Reset the completion routine
-  WdfRequestSetCompletionRoutine(request,
-                                 CommonReadWriteCompletionEntry,
-                                 this);
-
-  // Send the request asynchronously.
-  if (!WdfRequestSend(request, wdf_pipe_io_target(), WDF_NO_SEND_OPTIONS)) {
-    if (context->is_ioctl && !context->is_read) {
-      MmUnlockPages(context->transfer_mdl);
-      IoFreeMdl(context->transfer_mdl);
-    }
-    status = WdfRequestGetStatus(request);
-    IoFreeMdl(context->mdl);
-    WdfRequestComplete(request, status);
-  }
-}
-
-NTSTATUS AndroidUsbPipeFileObject::ResetPipe() {
-  ASSERT_IRQL_PASSIVE();
-
-  // This routine synchronously submits a URB_FUNCTION_RESET_PIPE
-  // request down the stack.
-  NTSTATUS status = WdfUsbTargetPipeAbortSynchronously(wdf_pipe(),
-                                                       WDF_NO_HANDLE,
-                                                       NULL);
-  if (NT_SUCCESS(status)) {
-    status = WdfUsbTargetPipeResetSynchronously(wdf_pipe(),
-                                                WDF_NO_HANDLE,
-                                                NULL);
-    if (!NT_SUCCESS(status))
-      GoogleDbgPrint("\n!!!!! AndroidUsbPipeFileObject::ResetPipe failed %X", status);
-  } else {
-      GoogleDbgPrint("\n!!!!! WdfUsbTargetPipeAbortSynchronously failed %X", status);
-  }
-
-  return status;
-}
-
-NTSTATUS AndroidUsbPipeFileObject::QueueResetPipePassiveCallback() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // Initialize workitem
-  WDF_OBJECT_ATTRIBUTES attr;
-  WDF_OBJECT_ATTRIBUTES_INIT(&attr);
-  WDF_OBJECT_ATTRIBUTES_SET_CONTEXT_TYPE(&attr, AndroidUsbWorkitemContext);
-  attr.ParentObject = wdf_device();
-
-  WDFWORKITEM wdf_work_item = NULL;
-  WDF_WORKITEM_CONFIG workitem_config;
-  WDF_WORKITEM_CONFIG_INIT(&workitem_config, ResetPipePassiveCallbackEntry);
-  NTSTATUS status = WdfWorkItemCreate(&workitem_config,
-                                      &attr,
-                                      &wdf_work_item);
-  ASSERT(NT_SUCCESS(status) && (NULL != wdf_work_item));
-  if (!NT_SUCCESS(status))
-    return status;
-
-  // Initialize our extension to work item
-  AndroidUsbWorkitemContext* context =
-    GetAndroidUsbWorkitemContext(wdf_work_item);
-  ASSERT(NULL != context);
-  if (NULL == context) {
-    WdfObjectDelete(wdf_work_item);
-    return STATUS_INTERNAL_ERROR;
-  }
-
-  context->object_type = AndroidUsbWdfObjectTypeWorkitem;
-  context->pipe_file_ext = this;
-
-  // Enqueue this work item.
-  WdfWorkItemEnqueue(wdf_work_item);
-
-  return STATUS_SUCCESS;
-}
-
-void AndroidUsbPipeFileObject::CommonReadWriteCompletionEntry(
-    WDFREQUEST request,
-    WDFIOTARGET wdf_target,
-    PWDF_REQUEST_COMPLETION_PARAMS completion_params,
-    WDFCONTEXT completion_context) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  AndroidUsbWdfRequestContext*
-    context = GetAndroidUsbWdfRequestContext(request);
-  ASSERT((NULL != context) && (AndroidUsbWdfObjectTypeRequest == context->object_type));
-
-  AndroidUsbPipeFileObject* pipe_file_ext =
-    reinterpret_cast<AndroidUsbPipeFileObject*>(completion_context);
-  ASSERT((NULL != pipe_file_ext) &&
-         (pipe_file_ext->wdf_pipe() == (WDFUSBPIPE)wdf_target));
-
-  pipe_file_ext->OnCommonReadWriteCompletion(request,
-                                             completion_params,
-                                             context);
-}
-
-void AndroidUsbPipeFileObject::ResetPipePassiveCallbackEntry(
-    WDFWORKITEM wdf_work_item) {
-  ASSERT_IRQL_PASSIVE();
-
-  AndroidUsbWorkitemContext* context =
-    GetAndroidUsbWorkitemContext(wdf_work_item);
-  ASSERT((NULL != context) &&
-         (AndroidUsbWdfObjectTypeWorkitem == context->object_type));
-  if ((NULL == context) ||
-      (AndroidUsbWdfObjectTypeWorkitem != context->object_type)) {
-    WdfObjectDelete(wdf_work_item);
-    return;
-  }
-
-  // In the sample they reset the device if pipe reset failed
-  AndroidUsbDeviceObject* wdf_device_ext =
-    context->pipe_file_ext->device_object();
-
-  NTSTATUS status = context->pipe_file_ext->ResetPipe();
-  if (!NT_SUCCESS(status))
-    status = wdf_device_ext->ResetDevice();
-  
-  WdfObjectDelete(wdf_work_item);
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_pipe_file_object.h b/host/windows/usb/driver/android_usb_pipe_file_object.h
deleted file mode 100644
index b0db9a8..0000000
--- a/host/windows/usb/driver/android_usb_pipe_file_object.h
+++ /dev/null
@@ -1,305 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_PIPE_FILE_OBJECT_H__
-#define ANDROID_USB_PIPE_FILE_OBJECT_H__
-/** \file
-  This file consists of declaration of class AndroidUsbPipeFileObject that
-  encapsulates a common extension for pipe file objects.
-*/
-
-#include "android_usb_file_object.h"
-
-/** AndroidUsbPipeFileObject class encapsulates extension for a KMDF file
-  object that represents opened pipe. Instances of this class must be
-  allocated from NonPagedPool.
-*/
-class AndroidUsbPipeFileObject : public AndroidUsbFileObject {
- public:
-  /** \brief Constructs the object.
-
-    This method must be called at low IRQL.
-    @param dev_obj[in] Our device object for which this file has been created
-    @param wdf_fo[in] KMDF file object this extension wraps
-    @param wdf_pipe_obj[in] KMDF pipe for this file
-  */
-  AndroidUsbPipeFileObject(AndroidUsbDeviceObject* dev_obj,
-                           WDFFILEOBJECT wdf_fo,
-                           WDFUSBPIPE wdf_pipe_obj);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-   virtual ~AndroidUsbPipeFileObject();
-
-  /** \brief Initializes the pipe file object extension
-
-    This method internally calls AndroidUsbFileObject::Initialize()
-    This method must be called at low IRQL
-    @param pipe_info[in] Pipe information
-    @return STATUS_SUCCESS or an appropriate error code
-  */
-  virtual NTSTATUS InitializePipe(const WDF_USB_PIPE_INFORMATION* pipe_info);
-
-  /** \brief Read event handler
-
-    This method is called when a read request comes to the file object this
-    extension wraps. This method is an override.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be read.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoRead(WDFREQUEST request, size_t length);
-
-  /** \brief Write event handler
-
-    This method is called when a write request comes to the file object this
-    extension wraps. This method is an override.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param length[in] The number of bytes to be written.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoWrite(WDFREQUEST request, size_t length);
-
-  /** \brief IOCTL event handler
-
-    This method is called when a device control request comes to the file
-    object this extension wraps. We hanlde the following IOCTLs here:
-    1. ADB_CTL_GET_ENDPOINT_INFORMATION
-    2. ADB_CTL_BULK_READ
-    3. ADB_CTL_BULK_WRITE
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-    @param ioctl_code[in] The driver-defined or system-defined I/O control code
-           that is associated with the request.
-    @return Successful status or an appropriate error code
-  */
-  virtual void OnEvtIoDeviceControl(WDFREQUEST request,
-                                    size_t output_buf_len,
-                                    size_t input_buf_len,
-                                    ULONG ioctl_code);
-
- protected:
-  /** \brief Handler for ADB_CTL_GET_ENDPOINT_INFORMATION IOCTL request
-    
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-  */
-  virtual void OnCtlGetEndpointInformation(WDFREQUEST request,
-                                           size_t output_buf_len);
-
-  /** \brief Handler for ADB_CTL_BULK_READ IOCTL request
-    
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-  */
-  virtual void OnCtlBulkRead(WDFREQUEST request,
-                             size_t output_buf_len,
-                             size_t input_buf_len);
-
-  /** \brief Handler for ADB_CTL_BULK_WRITE IOCTL request
-    
-    @param request[in] A handle to a framework request object.
-    @param output_buf_len[in] The length, in bytes, of the request's output
-           buffer, if an output buffer is available.
-    @param input_buf_len[in] The length, in bytes, of the request's input
-           buffer, if an input buffer is available.
-  */
-  virtual void OnCtlBulkWrite(WDFREQUEST request,
-                              size_t output_buf_len,
-                              size_t input_buf_len);
-
-  /** \brief Performs common bulk read / write on the pipe
-
-    This method is called from bulk and interrupt pipe file extensions to
-    perform read to / write from the pipe this file represents. Typicaly,
-    this method is called from OnEvtIoRead / OnEvtIoWrite /
-    OnEvtIoDeviceControl methods. One very special case for this method is
-    IOCTL-originated write request. If this is IOCTL-originated write request
-    we can't report transfer size through the request's status block. Instead,
-    for IOCTL-originated writes, the output buffer must a) exist and b) point
-    to an ULONG that will receive size of the transfer. Besides, for this type
-    of writes we create / lock write buffer MDL ourselves so we need to unlock
-    and free it in the completion routine.
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object.
-    @param transfer_mdl[in] MDL for the transferring buffer. The MDL must be
-           locked prior to this call.
-    @param length[in] The number of bytes to be read / written. If this method
-           is actually IOCTL originated write request this parameter must be
-           taken from AdbBulkTransfer.transfer_size by the caller of this
-           method. AdbBulkTransfer is available at the beginning of the input
-           buffer for bulk read / write IOCTLs.
-    @param is_read[in] If true this is a read operation, otherwise it's write
-           operation.
-    @param time_out[in] Number of milliseconds for this request to complete.
-           If this parameter is zero there will be no timeout associated with
-           the request. Otherwise, if request doesn't complete within the given
-           timeframe it will be cancelled.
-    @param is_ioctl[in] If 'true' this method has been called from IOCTL
-           handler. Otherwise it has been called from read / write handler. If
-           this is IOCTL-originated write request we need to report bytes
-           transferred through the IOCTL's output buffer.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-    @return STATUS_SUCCESS or an appropriate error code
-  */
-  virtual NTSTATUS CommonBulkReadWrite(WDFREQUEST request,
-                                       PMDL transfer_mdl,
-                                       ULONG length,
-                                       bool is_read,
-                                       ULONG time_out,
-                                       bool is_ioctl);
-
-  /** \brief Handles request completion for CommonBulkReadWrite
-
-    This method is called from CommonReadWriteCompletionEntry.
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object that is being
-           completed.
-    @param params[in] A pointer to a WDF_REQUEST_COMPLETION_PARAMS structure
-           that contains information about the completed request.
-    @param context[in] Context associated with this request in
-           CommonBulkReadWrite
-    This method can be called IRQL <= DISPATCH_LEVEL.
-  */
-  virtual void OnCommonReadWriteCompletion(WDFREQUEST request,
-                                           PWDF_REQUEST_COMPLETION_PARAMS completion_params,
-                                           AndroidUsbWdfRequestContext* context);
-
-  /** \brief Resets pipe associated with this file
-
-    After reseting the pipe this object might be destroyed.
-    This method must be called at PASSIVE IRQL.
-    @param read_device_on_failure[in] If true and reset pipe has failed this
-           method will attempt to reset the device.
-    @return STATUS_SUCCESS on success or an appropriate error code
-  */
-  virtual NTSTATUS ResetPipe();
-
-  /** \brief Queues a workitem to launch pipe reset at PASSIVE IRQL
-
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-    @return STATUS_SUCCESS or an appropriate error code.
-  */
-  virtual NTSTATUS QueueResetPipePassiveCallback();
-
- private:
-  /** \brief Request completion routine for CommonBulkReadWrite
-
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-    @param request[in] A handle to a framework request object that is being
-           completed.
-    @param wdf_target[in] A handle to an I/O target object that represents the
-           I/O target that completed the request. In this case this is a pipe.
-    @param params[in] A pointer to a WDF_REQUEST_COMPLETION_PARAMS structure
-           that contains information about the completed request.
-    @param completion_context[in] A handle to driver-supplied context
-           information, which the driver specified in a previous call to 
-           WdfRequestSetCompletionRoutine. In our case this is a pointer
-           to this class instance that issued the request.
-    This method can be called IRQL <= DISPATCH_LEVEL.
-  */
-  static void CommonReadWriteCompletionEntry(WDFREQUEST request,
-                                             WDFIOTARGET wdf_target,
-                                             PWDF_REQUEST_COMPLETION_PARAMS params,
-                                             WDFCONTEXT completion_context);
-
-  /** \brief Entry point for pipe reset workitem callback
-
-    This method is called at PASSIVE IRQL
-    @param wdf_work_item[in] A handle to a framework work item object.
-  */
-  static void ResetPipePassiveCallbackEntry(WDFWORKITEM wdf_work_item);
-
- public:
-  /// Gets KMDF pipe handle for this file
-  __forceinline WDFUSBPIPE wdf_pipe() const {
-    return wdf_pipe_;
-  }
-
-  /// Gets maximum transfer size for this pipe
-  __forceinline ULONG max_transfer_size() const {
-    ASSERT(0 != pipe_information_.MaximumTransferSize);
-    return pipe_information_.MaximumTransferSize;
-  }
-
-  /// Gets maximum packet size this pipe is capable of
-  __forceinline ULONG max_packet_size() const {
-    ASSERT(0 != pipe_information_.MaximumPacketSize);
-    return pipe_information_.MaximumPacketSize;
-  }
-
-  /// Gets transfer granularity
-  // TODO: It looks like device USB is capable of handling
-  // packets with size greater than pipe_information_.MaximumPacketSize!
-  // So, looks like we are not bound by this parameter in this driver.
-  __forceinline ULONG GetTransferGranularity() const {
-    return max_transfer_size();
-  }
-
-  /// Checks if this is an input pipe
-  __forceinline bool is_input_pipe() const {
-    return WDF_USB_PIPE_DIRECTION_IN(pipe_information_.EndpointAddress) ?
-          true : false;
-  }
-
-  /// Checks if this is an output pipe
-  __forceinline bool is_output_pipe() const {
-    return WDF_USB_PIPE_DIRECTION_OUT(pipe_information_.EndpointAddress) ?
-          true : false;
-  }
-
-  /// Checks if pipe is attached to this file
-  __forceinline bool IsPipeAttached() const {
-    return (NULL != wdf_pipe());
-  }
-
-  /// Gets USBD pipe handle
-  // TODO: Can we cache this?
-  __forceinline USBD_PIPE_HANDLE usbd_pipe() const {
-    ASSERT(IsPipeAttached());
-    return (IsPipeAttached()) ? WdfUsbTargetPipeWdmGetPipeHandle(wdf_pipe()) :
-                                NULL;
-  }
-
-  /// Gets I/O target handle for this pipe
-  // TODO: Can we cache this?
-  __forceinline WDFIOTARGET wdf_pipe_io_target() const {
-    ASSERT(IsPipeAttached());
-    return (IsPipeAttached()) ? WdfUsbTargetPipeGetIoTarget(wdf_pipe()) :
-                                NULL;
-  }
-
- protected:
-  /// Cached pipe information
-  WDF_USB_PIPE_INFORMATION  pipe_information_;
-
-  /// KMDF pipe handle for this file
-  WDFUSBPIPE                wdf_pipe_;
-};
-
-#endif  // ANDROID_USB_PIPE_FILE_OBJECT_H__
diff --git a/host/windows/usb/driver/android_usb_pool_tags.h b/host/windows/usb/driver/android_usb_pool_tags.h
deleted file mode 100644
index 708dcb7..0000000
--- a/host/windows/usb/driver/android_usb_pool_tags.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_POOL_TAGS_H__
-#define ANDROID_USB_POOL_TAGS_H__
-/** \file 
-  This file consists definitions for pool tags used in memory allocations for
-  the driver.
-*/
-
-/// Default pool tag for memory allocations (GAND)
-#define GANDR_POOL_TAG_DEFAULT                  'DNAG'
-
-/// Pool tag for the driver object (GADR)
-#define GANDR_POOL_TAG_DRIVER_OBJECT            'RDAG'
-
-/// Pool tag for KMDF device object extension (GADx)
-#define GANDR_POOL_TAG_KMDF_DEVICE              'xDAG'
-
-/// Pool tag for target device configuration descriptor (GACD)
-#define GANDR_POOL_TAG_DEV_CFG_DESC             'DCAG'
-
-/// Pool tag for device file object extension (GADf)
-#define GANDR_POOL_TAG_DEVICE_FO                'fDAG'
-
-/// Pool tag for a bulk file object extension (GABx)
-#define GANDR_POOL_TAG_BULK_FILE                'xBAG'
-
-/// Pool tag for an interrupt file object extension (GAIx)
-#define GANDR_POOL_TAG_INTERRUPT_FILE           'xIAG'
-
-/// Pool tag for URB allocated in bulk read / write (GAbu)
-#define GANDR_POOL_TAG_BULKRW_URB               'ubAG'
-
-/// Pool tag for interface pairs (GAip)
-#define GANDR_POOL_TAG_INTERF_PAIRS             'piAG'
-
-#endif  // ANDROID_USB_POOL_TAGS_H__
diff --git a/host/windows/usb/driver/android_usb_wdf_object.cpp b/host/windows/usb/driver/android_usb_wdf_object.cpp
deleted file mode 100644
index 68e2f99..0000000
--- a/host/windows/usb/driver/android_usb_wdf_object.cpp
+++ /dev/null
@@ -1,153 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  This file consists of implementation of a class AndroidUsbWdfObject that
-  encapsulates a basic extension to all KMDF objects. Currently, device and
-  file object extensions ared derived from it.
-*/
-#pragma data_seg()
-#pragma code_seg()
-
-#include "precomp.h"
-#include "android_usb_wdf_object.h"
-
-#pragma data_seg()
-#pragma code_seg("PAGE")
-
-AndroidUsbWdfObject::AndroidUsbWdfObject(AndroidUsbWdfObjectType obj_type)
-    : wdf_object_(NULL),
-      object_type_(obj_type) {
-  ASSERT_IRQL_LOW();
-  ASSERT(obj_type < AndroidUsbWdfObjectTypeMax);
-}
-
-#pragma code_seg()
-
-AndroidUsbWdfObject::~AndroidUsbWdfObject() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-}
-
-#pragma code_seg("PAGE")
-
-NTSTATUS AndroidUsbWdfObject::InitObjectAttributes(
-    PWDF_OBJECT_ATTRIBUTES wdf_obj_attr,
-    WDFOBJECT parent) {
-  ASSERT_IRQL_LOW();
-
-  // Enforce file object extension exception.
-  ASSERT(!Is(AndroidUsbWdfObjectTypeFile));
-  if (Is(AndroidUsbWdfObjectTypeFile))
-    return STATUS_INTERNAL_ERROR;
-
-  // Initialize attributes and set cleanup and destroy callbacks
-  WDF_OBJECT_ATTRIBUTES_INIT(wdf_obj_attr);
-  WDF_OBJECT_ATTRIBUTES_SET_CONTEXT_TYPE(wdf_obj_attr,
-                                         AndroidUsbWdfObjectContext);
-  wdf_obj_attr->EvtCleanupCallback = EvtCleanupCallbackEntry;
-  wdf_obj_attr->EvtDestroyCallback = EvtDestroyCallbackEntry;
-  wdf_obj_attr->ParentObject = parent;
-  wdf_obj_attr->SynchronizationScope = GetWdfSynchronizationScope();
-
-  return STATUS_SUCCESS;
-}
-
-NTSTATUS AndroidUsbWdfObject::InitializeContext() {
-  ASSERT_IRQL_LOW();
-  ASSERT(IsAttached());
-  if (!IsAttached())
-    return STATUS_INTERNAL_ERROR;
-
-  // Initialize our extension to that object
-  AndroidUsbWdfObjectContext* context =
-    GetAndroidUsbWdfObjectContext(wdf_object());
-  ASSERT(NULL != context);
-  if (NULL == context)
-    return STATUS_INTERNAL_ERROR;
-
-  // Make sure that extension has not been initialized
-  ASSERT((0 == context->object_type) && (NULL == context->wdf_object_ext));
-  if ((0 != context->object_type) || (NULL != context->wdf_object_ext))
-    return STATUS_INTERNAL_ERROR;
-
-  context->object_type = object_type();
-  context->wdf_object_ext = this;
-  ASSERT(this == GetAndroidUsbWdfObjectFromHandle(wdf_object()));
-
-  return STATUS_SUCCESS;
-}
-
-#pragma code_seg()
-
-WDF_SYNCHRONIZATION_SCOPE AndroidUsbWdfObject::GetWdfSynchronizationScope() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  // By default we don't want KMDF to synchronize access to our objects
-  return WdfSynchronizationScopeNone;
-}
-
-void AndroidUsbWdfObject::OnEvtCleanupCallback() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  GoogleDbgPrint("\n----- Object %p of type %u is cleaned up",
-           this, object_type());
-}
-
-void AndroidUsbWdfObject::OnEvtDestroyCallback() {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-  GoogleDbgPrint("\n----- Object %p of type %u is destroyed",
-           this, object_type());
-}
-
-void AndroidUsbWdfObject::EvtCleanupCallbackEntry(WDFOBJECT wdf_obj) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  AndroidUsbWdfObjectContext* context = GetAndroidUsbWdfObjectContext(wdf_obj);
-  ASSERT(NULL != context);
-  if (NULL != context) {
-    // For file objects we will be always called here even though we didn't
-    // create any extension for them. In this case the context must not be
-    // initialized.
-    ASSERT(((0 == context->object_type) && (NULL == context->wdf_object_ext)) ||
-           ((0 != context->object_type) && (NULL != context->wdf_object_ext)));
-    if (NULL != context->wdf_object_ext) {
-      ASSERT(context->wdf_object_ext->Is(context->object_type));
-      context->wdf_object_ext->OnEvtCleanupCallback();
-    }
-  }
-}
-
-void AndroidUsbWdfObject::EvtDestroyCallbackEntry(WDFOBJECT wdf_obj) {
-  ASSERT_IRQL_LOW_OR_DISPATCH();
-
-  AndroidUsbWdfObjectContext* context =
-    GetAndroidUsbWdfObjectContext(wdf_obj);
-  ASSERT(NULL != context);
-  if (NULL != context) {
-    // For file objects we will be always called here even though we didn't
-    // create any extension for them. In this case the context must not be
-    // initialized.
-    ASSERT(((0 == context->object_type) && (NULL == context->wdf_object_ext)) ||
-          ((0 != context->object_type) && (NULL != context->wdf_object_ext)));
-    if (NULL != context->wdf_object_ext) {
-      ASSERT(context->wdf_object_ext->Is(context->object_type));
-      context->wdf_object_ext->OnEvtDestroyCallback();
-      delete context->wdf_object_ext;
-    }
-  }
-}
-
-#pragma data_seg()
-#pragma code_seg()
diff --git a/host/windows/usb/driver/android_usb_wdf_object.h b/host/windows/usb/driver/android_usb_wdf_object.h
deleted file mode 100644
index aedd14a..0000000
--- a/host/windows/usb/driver/android_usb_wdf_object.h
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef ANDROID_USB_WDF_OBJECT_H__
-#define ANDROID_USB_WDF_OBJECT_H__
-/** \file
-  This file consists of declaration of a class AndroidUsbWdfObject that
-  encapsulates a basic extension to all KMDF objects. Currently, device and
-  file object extensions ared derived from it.
-*/
-
-/** AndroidUsbWdfObject class encapsulates a basic extension to all KMDF
-  objects. Currently, device and file object extensions ared derived from it.
-  Instances of this and derived classes must be allocated from NonPagedPool.
-*/
-class AndroidUsbWdfObject {
- public:
-  /** \brief Constructs the object.
-
-    @param obj_type[in] Type of the object that this wrapper represents.
-    This method must be called at low IRQL.
-  */
-  AndroidUsbWdfObject(AndroidUsbWdfObjectType obj_type);
-
-  /** \brief Destructs the object.
-
-    This method can be called at any IRQL.
-  */
-  virtual ~AndroidUsbWdfObject();
-
-  /** \brief Initializes object attributes for new KMDF object.
-
-    Each KMDF extension object must perform attribute initializations in order
-    to register an extension with KMDF framework. Since all our extensions are
-    derived from the base AndroidUsbWdfObject we use a single WDF object
-    extension context for all KMDF objects that we extend. So we can initialize
-    and register our context extension structure here. Note that object
-    attributes for file object wrappers are initialized globaly, when device
-    object is created. So file object extensions must not call this method.
-    This method must be called at low IRQL.
-    @param wdf_obj_attr[out] Object attributes to initialize.
-    @param parent[in] Parent object for this object. Can be NULL.
-    @return STATUS_SUCCESS on success or an appropriate error code.
-  */
-  virtual NTSTATUS InitObjectAttributes(PWDF_OBJECT_ATTRIBUTES wdf_obj_attr,
-                                        WDFOBJECT parent);
-
-  /** \brief Initializes context for this extension
-
-    This method initializes AndroidUsbWdfObjectContext structure that KMDF
-    allocated for the object that is being extended with this class.
-    InitObjectAttributes method must be called prior to the call to this
-    method. Besides, before calling this method, instance of this class must
-    be already attached to the KMDF object it represents. Otherwise this
-    method will fail with STATUS_INTERNAL_ERROR.
-    This method must be called at low IRQL.
-    @return STATUS_SUCCESS on success or an appropriate error code
-  */
-  virtual NTSTATUS InitializeContext();
-
-
- protected:
-  /** \brief Returns syncronisation scope for this extension type.
-
-    This method is called from InitObjectAttributes method to specify what
-    type of synchronization is required for instances of this type. By
-    default we return WdfSynchronizationScopeNone which makes KMDF not
-    to synchronize access to this type of object.
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-  */
-  virtual WDF_SYNCHRONIZATION_SCOPE GetWdfSynchronizationScope();
-
-  /** \brief Handler for cleanup event fired for associated KMDF object.
-
-    The framework calls this callback function when either the framework or a
-    driver attempts to delete the object.
-    This method can be called at IRQL <= DISPATCH_LEVEL.
-  */
-  virtual void OnEvtCleanupCallback();
-
-  /** \brief Handler for destroy callback
-
-    The framework calls the EvtDestroyCallback callback function after the
-    object's reference count has been decremented to zero. The framework
-    deletes the object immediately after the EvtDestroyCallback callback
-    function returns.
-    This callback can be called at IRQL <= DISPATCH_LEVEL.
-  */
-  virtual void OnEvtDestroyCallback();
-
-  /** \brief Removes driver's references on an object so it can be deleted.
-
-    The framework calls the callback function when either the framework or a
-    driver attempts to delete the object.
-    This callback can be called at IRQL <= DISPATCH_LEVEL.
-    @param wdf_obj[in] A handle to a framework object this class wraps.
-  */
-  static void EvtCleanupCallbackEntry(WDFOBJECT wdf_obj);
-
-  /** \brief Called when framework object is being deleted
-
-    The framework calls the EvtDestroyCallback callback function after the
-    object's reference count has been decremented to zero. The framework
-    deletes the object immediately after the EvtDestroyCallback callback
-    function returns.
-    This callback can be called at IRQL <= DISPATCH_LEVEL.
-    @param wdf_obj[in] A handle to a framework object this class wraps.
-  */
-  static void EvtDestroyCallbackEntry(WDFOBJECT wdf_obj);
-
- public:
-
-  /// Gets KMDF object extended with this instance
-  __forceinline WDFOBJECT wdf_object() const {
-    return wdf_object_;
-  }
-
-  /// Sets KMDF object associated with this extension
-  __forceinline void set_wdf_object(WDFOBJECT wdf_obj) {
-    ASSERT(NULL == wdf_object_);
-    wdf_object_ = wdf_obj;
-  }
-
-  /// Gets KMDF object type for this extension
-  __forceinline AndroidUsbWdfObjectType object_type() const {
-    return object_type_;
-  }
-
-  /** \brief Checks if this extension represends KMDF object of the given type
-
-    @param obj_type[in] Object type to check
-    @return true if this wrapper represents object of that type and
-            false otherwise.
-  */
-  __forceinline Is(AndroidUsbWdfObjectType obj_type) const {
-    return (obj_type == object_type());
-  }
-
-  /// Checks if extension is attached to a KMDF object
-  __forceinline bool IsAttached() const {
-    return (NULL != wdf_object());
-  }
-
- protected:
-  /// KMDF object that is extended with this instance
-  WDFOBJECT               wdf_object_;
-
-  /// KMDF object type for this extension
-  AndroidUsbWdfObjectType object_type_;
-};
-
-/** \brief Gets our extension for the given KMDF object
-
-  This method can be called at any IRQL
-  @param wdf_obj[in] KMDF handle describing an object
-  @return Instance of AndroidUsbWdfObject associated with this object or NULL
-          if association is not found.
-*/
-__forceinline AndroidUsbWdfObject* GetAndroidUsbWdfObjectFromHandle(
-    WDFOBJECT wdf_obj) {
-  ASSERT(NULL != wdf_obj);
-  if (NULL != wdf_obj) {
-    AndroidUsbWdfObjectContext* context =
-      GetAndroidUsbWdfObjectContext(wdf_obj);
-    ASSERT((NULL != context) && (NULL != context->wdf_object_ext) &&
-           (context->wdf_object_ext->Is(context->object_type)));
-    if ((NULL != context) && (NULL != context->wdf_object_ext) &&
-        context->wdf_object_ext->Is(context->object_type)) {
-      return context->wdf_object_ext;
-    }
-  }
-  return NULL;
-}
-
-#endif  // ANDROID_USB_WDF_OBJECT_H__
diff --git a/host/windows/usb/driver/makefile b/host/windows/usb/driver/makefile
deleted file mode 100644
index 3c0d3a5..0000000
--- a/host/windows/usb/driver/makefile
+++ /dev/null
@@ -1,36 +0,0 @@
-!IF 0
-
-Copyright (C) 2006 The Android Open Source Project
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Module Name:
-
-    makefile.
-
-Notes:
-
-    DO NOT EDIT THIS FILE!!!  Edit .\sources. if you want to add a new source
-    file to this component.  This file merely indirects to the real make file
-    that is shared by all the components of Windows NT (DDK)
-
-!ENDIF
-
-!if "$(DDK_TARGET_OS)"=="Win2K"
-!message This driver is not intended to target the Windows 2000 platform.
-!elseif "$(DDK_TARGET_OS)"=="WinNET"
-!INCLUDE $(NTMAKEENV)\makefile.def
-!else
-!INCLUDE $(NTMAKEENV)\makefile.def
-!endif
-
diff --git a/host/windows/usb/driver/makefile.inc b/host/windows/usb/driver/makefile.inc
deleted file mode 100644
index 1955cef..0000000
--- a/host/windows/usb/driver/makefile.inc
+++ /dev/null
@@ -1,7 +0,0 @@
-_LNG=$(LANGUAGE)
-_INX=.
-STAMP=stampinf -f $@ -a $(_BUILDARCH)
-
-$(OBJ_PATH)\$(O)\$(INF_NAME).inf: $(_INX)\$(INF_NAME).inx 
-    copy $(_INX)\$(@B).inx $@
-    $(STAMP)
diff --git a/host/windows/usb/driver/precomp.h b/host/windows/usb/driver/precomp.h
deleted file mode 100644
index 97be2a6..0000000
--- a/host/windows/usb/driver/precomp.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  Standard precompile file
-*/
-#pragma warning(disable:4200)
-#pragma warning(disable:4201)  // nameless struct/union
-#pragma warning(disable:4214)  // bit field types other than int
-extern "C" {
-#include <initguid.h>
-#include <ntddk.h>
-#include <ntintsafe.h>
-#include <ntstrsafe.h>
-#include "usbdi.h"
-#include "usbdlib.h"
-#include <wdf.h>
-#include <wdfusb.h>
-}  // extern "C"
-#pragma warning(default:4200)
-#pragma warning(default:4201)
-#pragma warning(default:4214)
-
-#include "adb_api_extra.h"
-#include "android_usb_common_defines.h"
-#include "android_usb_pool_tags.h"
-#include "android_usb_driver_defines.h"
-#include "android_usb_new_delete.h"
-#include "android_usb_inl.h"
diff --git a/host/windows/usb/driver/sources b/host/windows/usb/driver/sources
deleted file mode 100644
index 07fce7e..0000000
--- a/host/windows/usb/driver/sources
+++ /dev/null
@@ -1,32 +0,0 @@
-!IF 0
-
-Copyright (C) 2007 The Android Open Source Project
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Module Name:
-
-    sources.
-
-Abstract:
-
-    This file specifies the target component being built and the list of
-    sources files needed to build that component.  Also specifies optional
-    compiler switches and libraries that are unique for the component being
-    built.
-
-!ENDIF
-
-!include sources.inc
-
-SOURCES= $(MOST_SOURCES) android_usb.rc
diff --git a/host/windows/usb/driver/sources.inc b/host/windows/usb/driver/sources.inc
deleted file mode 100644
index 5928f73..0000000
--- a/host/windows/usb/driver/sources.inc
+++ /dev/null
@@ -1,84 +0,0 @@
-!IF 0
-
-Copyright (C) 2007 The Android Open Source Project
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Module Name:
-
-    sources.
-
-Abstract:
-
-    This file specifies the target component being built and the list of
-    sources files needed to build that driver.  Also specifies optional
-    compiler switches and libraries that are unique for the component being
-    built.
-
-!ENDIF
-
-TARGETNAME=androidusb
-!IF "$(DDKBUILDENV)"=="chk"
-TARGETPATH=..\build\Debug
-!ELSE
-TARGETPATH=..\build\Release
-!ENDIF
-TARGETTYPE=DRIVER
-KMDF_VERSION=1
-USECXX_FLAG=/TP
-USER_C_FLAGS=$(USER_C_FLAGS) /wd4100 /wd4002 /wd4509 /wd4390 /TP
-
-INCLUDES=$(INCLUDES); \
-    	 $(IFSKIT_INC_PATH); \
-    	 ..\common; \
-    	 ..\api;
-
-TARGETLIBS=$(DDK_LIB_PATH)\usbd.lib
-
-MSC_WARNING_LEVEL=/W4 /WX /Wp64
-MSC_OPTIMIZATION = /Oi /Ob1
-C_DEFINES=$(C_DEFINES) -DEXPLODE_POOLTAGS -DRTL_USE_AVL_TABLES
-
-RCOPTIONS=$(RCOPTIONS) /dVER_COMPANYNAME_STR="\"Google Inc\"" 
-RCOPTIONS=$(RCOPTIONS) /dVER_LEGALCOPYRIGHT_YEARS="\"2007\"" 
-RCOPTIONS=$(RCOPTIONS) /dVER_LEGALCOPYRIGHT_STR="\"\251 Google Inc. All rights reserved.\"" 
-RCOPTIONS=$(RCOPTIONS) /dVER_PRODUCTNAME_STR="\"Google Android USB Driver\"" 
-RCOPTIONS=$(RCOPTIONS) /dVER_PRODUCTVERSION="1,00,01,001" 
-RCOPTIONS=$(RCOPTIONS) /dVER_PRODUCTVERSION_STR="\"1.00\""
-
-!IF 0
-
-By overriding .rsrc section properties (!D removes Discardable attribute)
-we make sure that all our vtables will be placed properly into non-discardable
-data segment. Because of the nature of this driver we don't need to have
-vtables in NonPaged data sections because all our objects can be paged.
-Otherwise we may want to add /SECTION:.rsrc,X option that locks section in memory
-
-!ENDIF
-
-LINKER_FLAGS=$(LINKER_FLAGS) /MAP /MAPINFO:LINES /SECTION:.rsrc,!D
-
-MOST_SOURCES=  \
-  android_usb_driver_object.cpp \
-  android_usb_wdf_object.cpp \
-  android_usb_device_object.cpp \
-  android_usb_file_object.cpp \
-  android_usb_device_file_object.cpp \
-  android_usb_pipe_file_object.cpp \
-  android_usb_bulk_file_object.cpp \
-  android_usb_interrupt_file_object.cpp
-
-PRECOMPILED_INCLUDE=precomp.h
-PRECOMPILED_PCH=precomp.pch
-PRECOMPILED_OBJ=precomp.obj
-
diff --git a/host/windows/usb/test/android_usb_test/android_usb_test.cpp b/host/windows/usb/test/android_usb_test/android_usb_test.cpp
deleted file mode 100644
index a5c3906..0000000
--- a/host/windows/usb/test/android_usb_test/android_usb_test.cpp
+++ /dev/null
@@ -1,1366 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// android_usb_test.cpp : Defines the entry point for the console application.

-//

-

-#include "stdafx.h"

-#include <stdio.h>

-#include <conio.h>

-

-#define MAX_PAYLOAD 4096
-
-#define A_SYNC 0x434e5953
-#define A_CNXN 0x4e584e43
-#define A_OPEN 0x4e45504f
-#define A_OKAY 0x59414b4f
-#define A_CLSE 0x45534c43
-#define A_WRTE 0x45545257
-
-#define A_VERSION 0x01000000
-

-struct message {
-    unsigned int command;       /* command identifier constant      */
-    unsigned int arg0;          /* first argument                   */
-    unsigned int arg1;          /* second argument                  */
-    unsigned int data_length;   /* length of payload (0 is allowed) */
-    unsigned int data_crc32;    /* crc32 of data payload            */
-    unsigned int magic;         /* command ^ 0xffffffff             */
-};
-

-USB_DEVICE_DESCRIPTOR test_dev_desc = {

-  sizeof(USB_DEVICE_DESCRIPTOR),

-  1,      // bDescriptorType

-  0x200,  // bcdUSB

-  0xFF,   // bDeviceClass

-  0xFF,   // bDeviceSubClass

-  0xFF,   // bDeviceProtocol

-  64,     // bMaxPacketSize

-  0x18D1, // idVendor

-  0xDDDD, // idProduct

-  0x100,  // bcdDevice

-  1,      // iManufacturer

-  2,      // iProduct

-  3,      // iSerialNumber

-  1       // bNumConfigurations

-};

-

-USB_CONFIGURATION_DESCRIPTOR test_config_desc = {

-  9,      // bLength

-  2,      // bDescriptorType

-  32,     // wTotalLength

-  1,      // bNumInterfaces

-  1,      // bConfigurationValue

-  4,      // iConfiguration

-  64,     // bmAttributes

-  50      // MaxPower

-};

-

-USB_INTERFACE_DESCRIPTOR test_interface_desc = {

-  9,      // bLength

-  4,      // bDescriptorType

-  0,      // bInterfaceNumber

-  0,      // bAlternateSetting

-  2,      // bNumEndpoints

-  0xFF,   // bInterfaceClass

-  0xFF,   // bInterfaceSubClass

-  0xFF,   // bInterfaceProtocol

-  5       // iInterface

-};

-

-AdbEndpointInformation test_pipe_00 = {

-  1024,       // MaximumPacketSize

-  0xFFFFFFFF, // MaximumTransferSize

-  static_cast<AdbEndpointType>(3),          // PipeType

-  0x81,       // EndpointAddress

-  0,          // Interval

-  0           // SettingIndex

-};

-

-AdbEndpointInformation test_pipe_01 = {

-  1024,       // MaximumPacketSize

-  0xFFFFFFFF, // MaximumTransferSize

-  static_cast<AdbEndpointType>(3),          // PipeType

-  0x02,       // EndpointAddress

-  0,          // Interval

-  0           // SettingIndex

-};

-

-AdbEndpointInformation* test_read_pipe = &test_pipe_00;

-AdbEndpointInformation* test_write_pipe = &test_pipe_01;

-

-const UCHAR test_read_pipe_index = 0;

-const UCHAR test_write_pipe_index = 1;

-

-bool device_active = false;

-

-GUID adb_class_id = ANDROID_USB_CLASS_ID;

-const wchar_t test_interface_name[] = L"\\\\?\\usb#vid_18d1&pid_dddd#123456789abcdef#{F72FE0D4-CBCB-407d-8814-9ED673D0DD6B}";

-bool RunInterfaceEnumTest();

-bool RunInterfaceEnumTest(bool exclude_not_present,

-                          bool exclude_removed,

-                          bool active_only);

-bool RunInterfaceCreateTest();

-bool RunEndpointInfoTest();

-bool RunEndpointInfoTest(ADBAPIHANDLE adb_interface, UCHAR index);

-bool RunEndpointOpenTest();

-bool RunEndpointOpenTest(ADBAPIHANDLE adb_interface, UCHAR index);

-bool RunEndpointIoTest(ULONG time_out_base);

-bool RunTimeoutsTest();

-bool RunGeneralTests();

-bool DeviceHandShake();

-bool CheckEndpointInfo(UCHAR index, AdbEndpointInformation* info);

-

-int _tmain(int argc, _TCHAR* argv[]) {

-  argc = argc;

-  argv = argv;

-

-  // General startup tests.

-  if (!RunGeneralTests())

-    return 1;

-

-	return 0;

-}

-

-bool RunGeneralTests() {

-  // Test interface enum

-  if (!RunInterfaceEnumTest())

-    return false;

-

-  // Test interface create

-  if (!RunInterfaceCreateTest())

-    return false;

-

-  // Test endpoint information

-  if (!RunEndpointInfoTest())

-    return false;

-

-  // Test endpoint open

-  if (!RunEndpointOpenTest())

-    return false;

-

-  // Test timeout i/o

-  if (!RunTimeoutsTest())

-    return false;

-

-  // Test read / write (no timeouts)

-  if (!RunEndpointIoTest(0))

-    return false;

-

-  // Test read / write (OK timeouts)

-  if (!RunEndpointIoTest(10))

-    return false;

-

-  return true;

-/*

-  if (!DeviceHandShake())

-    return false;

-

-  return true;

-*/

-}

-

-bool DeviceHandShake() {

-  printf("\n\n===== Running DeviceHandShake... ");

-

-  // Get interface

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_COMPOSITE_PRODUCT_ID,

-                                                  DEVICE_INTERFACE_ID);

-  if (NULL == adb_interface) {

-    adb_interface = AdbCreateInterface(adb_class_id,

-                                       DEVICE_VENDOR_ID,

-                                       DEVICE_SINGLE_PRODUCT_ID,

-                                       0xFF);

-  }

-

-  if (NULL == adb_interface) {

-    printf("\n      AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  char interf_name[1024];

-  unsigned long name_size = sizeof(interf_name);

-

-  if (!AdbGetInterfaceName(adb_interface, interf_name, &name_size, true)) {

-    printf("\n      AdbGetInterfaceName returned error %u", GetLastError());

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  printf("\n      Interface name is %s", interf_name);

-

-  char* ser_num = NULL;

-  name_size = 0;

-  if (!AdbGetSerialNumber(adb_interface, ser_num, &name_size, true)) {

-    ser_num = reinterpret_cast<char*>(malloc(name_size));

-    if (NULL != ser_num) {

-      if (!AdbGetSerialNumber(adb_interface, ser_num, &name_size, true)) {

-        printf("\n      AdbGetSerialNumber returned error %u", GetLastError());

-        AdbCloseHandle(adb_interface);

-        return false;

-      }

-      printf("\n      Interface serial number is %s", ser_num);

-      free(ser_num);

-    }

-  } else {

-    printf("\nAdbGetSerialNumber(adb_interface, ser_num, &name_size, true)");

-  }

-

-  // Get default read endpoint

-  ADBAPIHANDLE adb_read = AdbOpenDefaultBulkReadEndpoint(adb_interface,

-                                                         AdbOpenAccessTypeReadWrite,

-                                                         AdbOpenSharingModeReadWrite);

-  if (NULL == adb_read) {

-    printf("\n      AdbOpenDefaultBulkReadEndpoint returned error %u", GetLastError());

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Get default write endpoint

-  ADBAPIHANDLE adb_write = AdbOpenDefaultBulkWriteEndpoint(adb_interface,

-                                                           AdbOpenAccessTypeReadWrite,

-                                                           AdbOpenSharingModeReadWrite);

-  if (NULL == adb_write) {

-    printf("\n      AdbOpenDefaultBulkWriteEndpoint returned error %u", GetLastError());

-    AdbCloseHandle(adb_read);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Send connect message

-  message msg_send;

-  msg_send.command = A_CNXN;

-  msg_send.arg0 = A_VERSION;
-  msg_send.arg1 = MAX_PAYLOAD;
-  msg_send.data_length = 0;
-  msg_send.data_crc32 = 0;
-  msg_send.magic = msg_send.command ^ 0xffffffff;
-

-  ULONG written_bytes = 0;

-  bool write_res = AdbWriteEndpointSync(adb_write, &msg_send, sizeof(msg_send), &written_bytes, 0);

-  if (!write_res) {

-    printf("\n       AdbWriteEndpointSync returned error %u", GetLastError());

-    AdbCloseHandle(adb_write);

-    AdbCloseHandle(adb_read);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Receive handshake

-  message msg_rcv;

-  ULONG read_bytes = 0;

-  bool read_res = AdbReadEndpointSync(adb_read, &msg_rcv, sizeof(msg_rcv), &read_bytes, 0);

-  if (!read_res) {

-    printf("\n       AdbReadEndpointSync returned error %u", GetLastError());

-    AdbCloseHandle(adb_write);

-    AdbCloseHandle(adb_read);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  printf("\n      Read handshake: %u bytes received", read_bytes);

-  char* cmd_ansi = reinterpret_cast<char*>(&msg_rcv.command);

-  printf("\n         command     = %08X (%c%c%c%c)", msg_rcv.command,

-         cmd_ansi[0], cmd_ansi[1], cmd_ansi[2], cmd_ansi[3]);

-  printf("\n         arg0        = %08X", msg_rcv.arg0);

-  printf("\n         arg1        = %08X", msg_rcv.arg1);

-  printf("\n         data_length = %u", msg_rcv.data_length);

-  printf("\n         data_crc32  = %08X", msg_rcv.data_crc32);

-  printf("\n         magic       = %08X", msg_rcv.magic);

-

-  if (0 != msg_rcv.data_length) {

-    char* buf = reinterpret_cast<char*>(malloc(msg_rcv.data_length));

-    read_res = AdbReadEndpointSync(adb_read, buf, msg_rcv.data_length, &read_bytes, 0);

-    if (!read_res) {

-      printf("\n       AdbReadEndpointSync (data) returned error %u", GetLastError());

-      free(buf);

-      AdbCloseHandle(adb_write);

-      AdbCloseHandle(adb_read);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-

-    for (ULONG n = 0; n < read_bytes; n++) {

-      if (0 == (n % 16))

-        printf("\n          ");

-      printf("%02X ", buf[n]);

-    }

-

-    printf("\n          %s", buf);

-

-    delete buf;

-  }

-

-  printf("\nPress any key to close handles...");

-  getch();

-  AdbCloseHandle(adb_write);

-  AdbCloseHandle(adb_read);

-  AdbCloseHandle(adb_interface);

-

-  return true;

-}

-

-bool RunInterfaceEnumTest() {

-  if (!RunInterfaceEnumTest(true, true, true))

-    return false;

-

-  if (!RunInterfaceEnumTest(false, false, false))

-    return false;

-

-  if (device_active) {

-    return true;

-  } else {

-    // Device has not found in the list of active devices

-    printf("\nPlease start the USB device emulator to run the tests");

-    return false;

-  }

-}

-

-bool RunInterfaceEnumTest(bool exclude_not_present,

-                          bool exclude_removed,

-                          bool active_only) {

-  printf("\n\n=== Running RunInterfaceEnumTest(%s, %s, %s)... ",

-         exclude_not_present ? "true" : "false",

-         exclude_removed ? "true" : "false",

-         active_only ? "true" : "false");

-

-  ADBAPIHANDLE adb_handle =

-    AdbEnumInterfaces(adb_class_id, exclude_not_present, exclude_removed, active_only);

-  if (NULL == adb_handle) {

-    printf("\n     Unable to AdbEnumInterfaces. Error %u", GetLastError());

-    return false;

-  }

-

-  bool res;

-

-  do {

-    AdbInterfaceInfo* info = NULL;

-    ULONG size = 0;

-

-    res = AdbNextInterface(adb_handle, NULL, &size);

-    // We expect 'false' and GetLastError() being either ERROR_NO_MORE_ITEMS

-    // or ERROR_INSUFFICIENT_BUFFER

-    if (res || ((ERROR_INSUFFICIENT_BUFFER != GetLastError()) &&

-                (ERROR_NO_MORE_ITEMS != GetLastError()))) {

-      printf("\n    Unexpected AdbNextInterface(NULL) result. Res = %u, Error = %u",

-             res, GetLastError());

-      AdbCloseHandle(adb_handle);

-      return false;

-    }

-

-    if (ERROR_INSUFFICIENT_BUFFER == GetLastError()) {

-      info = reinterpret_cast<AdbInterfaceInfo*>(malloc(size));

-      // Try one byte less than required length

-      size--;

-      res = AdbNextInterface(adb_handle, info, &size);

-      if (res || (ERROR_INSUFFICIENT_BUFFER != GetLastError())) {

-        printf("\n    Unexpected AdbNextInterface(small) result. Res = %u, Error = %u",

-               res, GetLastError());

-        free(info);

-        AdbCloseHandle(adb_handle);

-        return false;

-      }

-

-      size++;

-      res = AdbNextInterface(adb_handle, info, &size);

-

-      if (res) {

-        if (exclude_not_present && active_only &&

-            (0 == wcsicmp(info->device_name, test_interface_name))) {

-          device_active = true;

-        }

-      } else {

-        printf("\n    AdbNextInterface failed: %u", GetLastError());

-        free(info);

-        AdbCloseHandle(adb_handle);

-        return false;

-      }

-

-      free(info);

-    } else {

-      res = false;

-    }

-  } while (res);

-

-  res = AdbCloseHandle(adb_handle);

-  if (!res) {

-    printf("\n    Unable to AdbCloseHandle:  %u", GetLastError());

-    return false;

-  }

-

-  // Closing closed handle

-  res = AdbCloseHandle(adb_handle);

-  if (res || (ERROR_INVALID_HANDLE != GetLastError())) {

-    printf("\n    Unexpected AdbCloseHandle(closed) result. Ret = %u, Error = %u",

-           res, GetLastError());

-    return false;

-  }

-

-  printf(" SUCCESS.");

-  return true;

-}

-

-bool RunInterfaceCreateTest() {

-  printf("\n\n=== Running RunInterfaceCreateTest()... ");

-

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_EMULATOR_PROD_ID,

-                                                  0xFF);

-  if (NULL == adb_interface) {

-    printf("\n    AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  // Gather information

-  USB_DEVICE_DESCRIPTOR dev_desc;

-  USB_CONFIGURATION_DESCRIPTOR config_desc;

-  USB_INTERFACE_DESCRIPTOR interface_desc;

-

-  bool res = AdbGetUsbDeviceDescriptor(adb_interface, &dev_desc);

-  if (!res) {

-    printf("\n    AdbGetUsbDeviceDescriptor error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  res = AdbGetUsbConfigurationDescriptor(adb_interface, &config_desc);

-  if (!res) {

-    printf("\n    AdbGetUsbDeviceDescriptor error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  res = AdbGetUsbInterfaceDescriptor(adb_interface, &interface_desc);

-  if (!res) {

-    printf("\n    AdbGetUsbDeviceDescriptor error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  wchar_t* wide_buffer = NULL;

-  char* char_buffer = NULL;

-  ULONG buffer_size = 0;

-

-  res = AdbGetInterfaceName(adb_interface, wide_buffer, &buffer_size, false);

-  if (!res) {

-    if (ERROR_INSUFFICIENT_BUFFER != GetLastError()) {

-      printf("\n    Unable to AdbGetInterfaceName(NULL). Error %u", GetLastError());

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-    wide_buffer = reinterpret_cast<wchar_t*>(malloc(buffer_size * sizeof(wchar_t)));

-    res = AdbGetInterfaceName(adb_interface, wide_buffer, &buffer_size, false);

-    if (!res) {

-      printf("\n    Unable to AdbGetInterfaceName(%u). Error %u", buffer_size, GetLastError());

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-  }

-

-  res = AdbGetInterfaceName(adb_interface, char_buffer, &buffer_size, true);

-  if (!res) {

-    if (ERROR_INSUFFICIENT_BUFFER != GetLastError()) {

-      printf("\n    Unable to AdbGetInterfaceName(NULL). Error %u", GetLastError());

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-    char_buffer = reinterpret_cast<char*>(malloc(buffer_size * sizeof(char)));

-    res = AdbGetInterfaceName(adb_interface, char_buffer, &buffer_size, true);

-    if (!res) {

-      printf("\n    Unable to AdbGetInterfaceName(%u). Error %u", buffer_size, GetLastError());

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-  }

-

-  res = AdbCloseHandle(adb_interface);

-  if (!res) {

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-    printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  res = AdbCloseHandle(adb_interface);

-  if (res || (ERROR_INVALID_HANDLE != GetLastError())) {

-    printf("\n    Unexpected AdbCloseHandle(closed) result. Ret = %u, Error = %u",

-           res, GetLastError());

-    return false;

-  }

-

-  if (0 != memcmp(&dev_desc, &test_dev_desc, sizeof(USB_DEVICE_DESCRIPTOR))) {

-    printf("\n    Wrong USB_DEVICE_DESCRIPTOR");

-    return false;

-  }

-

-  if (0 != memcmp(&config_desc, &test_config_desc, sizeof(USB_CONFIGURATION_DESCRIPTOR))) {

-    printf("\n    Wrong USB_CONFIGURATION_DESCRIPTOR");

-    return false;

-  }

-

-  if (0 != memcmp(&interface_desc, &test_interface_desc, sizeof(USB_INTERFACE_DESCRIPTOR))) {

-    printf("\n    Wrong USB_INTERFACE_DESCRIPTOR");

-    return false;

-  }

-

-  printf(" SUCCESS.");

-  return true;

-}

-

-bool RunEndpointInfoTest() {

-  printf("\n\n=== Running RunEndpointInfoTest()");

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_EMULATOR_PROD_ID,

-                                                  0xFF);

-  if (NULL == adb_interface) {

-    printf("\n    AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  USB_INTERFACE_DESCRIPTOR interface_desc;

-  BOOL res = AdbGetUsbInterfaceDescriptor(adb_interface, &interface_desc);

-  if (!res) {

-    printf("\n    AdbGetUsbDeviceDescriptor error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  if (0 != memcmp(&interface_desc, &test_interface_desc, sizeof(USB_INTERFACE_DESCRIPTOR))) {

-    printf("\n    Wrong USB_INTERFACE_DESCRIPTOR");

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  for (UCHAR index = 0; index < interface_desc.bNumEndpoints; index++) {

-    if (!RunEndpointInfoTest(adb_interface, index)) {

-      res = AdbCloseHandle(adb_interface);

-      if (!res)

-        printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-      return false;

-    }

-  }

-

-  if (RunEndpointInfoTest(adb_interface, index)) {

-    printf("\n    Unexpected success of RunEndpointInfoTest(%u - invalid index)", index);

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  if (!RunEndpointInfoTest(adb_interface, ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX))

-    return false;

-

-  if (!RunEndpointInfoTest(adb_interface, ADB_QUERY_BULK_READ_ENDPOINT_INDEX))

-    return false;

-

-  res = AdbCloseHandle(adb_interface);

-  if (!res) {

-    printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  return true;

-}

-

-bool RunEndpointInfoTest(ADBAPIHANDLE adb_interface, UCHAR index) {

-  printf("\n======= Running RunEndpointInfoTest(%X)... ", index);

-

-  AdbEndpointInformation info;

-

-  if (!AdbGetEndpointInformation(adb_interface, index, &info)) {

-    if ((index < 2) || (ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX == index) ||

-        (ADB_QUERY_BULK_READ_ENDPOINT_INDEX == index)) {

-      printf("\n        AdbGetEndpointInformation(u) failed: %u", index, GetLastError());

-    }

-    return false;

-  }

-

-  if (!CheckEndpointInfo(index, &info)) {

-    printf("\n        Wrong AdbEndpointInformation(%X)", index);

-    return false;

-  }

-

-  printf(" SUCCESS.");

-  return true;

-}

-

-bool RunEndpointOpenTest() {

-  printf("\n\n=== Running RunEndpointOpenTest()... ");

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_EMULATOR_PROD_ID,

-                                                  0xFF);

-  if (NULL == adb_interface) {

-    printf("\n    AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  USB_INTERFACE_DESCRIPTOR interface_desc;

-  BOOL res = AdbGetUsbInterfaceDescriptor(adb_interface, &interface_desc);

-  if (!res) {

-    printf("\n    AdbGetUsbDeviceDescriptor error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  ADBAPIHANDLE adb_endpoint = AdbOpenDefaultBulkReadEndpoint(adb_interface,

-                                                             AdbOpenAccessTypeReadWrite,

-                                                             AdbOpenSharingModeReadWrite);

-  if (NULL == adb_endpoint) {

-    printf("\n    AdbOpenDefaultBulkReadEndpoint error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  // Make sure that we can't write to it

-  ULONG transfer = 0;

-  res = AdbWriteEndpointSync(adb_endpoint,

-                         &adb_endpoint,

-                         sizeof(adb_endpoint),

-                         &transfer,

-                         0);

-  if (res || (ERROR_ACCESS_DENIED != GetLastError())) {

-    printf("\n    AdbWriteEndpoint failure: Ret = %u, error = %u", res, GetLastError());

-    AdbCloseHandle(adb_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  AdbCloseHandle(adb_endpoint);

-

-  adb_endpoint = AdbOpenDefaultBulkWriteEndpoint(adb_interface,

-                                                 AdbOpenAccessTypeReadWrite,

-                                                 AdbOpenSharingModeReadWrite);

-  if (NULL == adb_endpoint) {

-    printf("\n    AdbOpenDefaultBulkWriteEndpoint error %u", GetLastError());

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  // Make sure we cannot read from it

-  ULONG to_read;

-  res = AdbReadEndpointSync(adb_endpoint,

-                        &to_read,

-                        sizeof(to_read),

-                        &transfer,

-                        0);

-  if (res || (ERROR_ACCESS_DENIED != GetLastError())) {

-    printf("\n    AdbReadEndpoint failure: Ret = %u, error = %u", res, GetLastError());

-    AdbCloseHandle(adb_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  AdbCloseHandle(adb_endpoint);

-

-  for (UCHAR index = 0; index < interface_desc.bNumEndpoints; index++) {

-    if (!RunEndpointOpenTest(adb_interface, index)) {

-      res = AdbCloseHandle(adb_interface);

-      if (!res)

-        printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-      return false;

-    }

-  }

-

-  if (RunEndpointOpenTest(adb_interface, index)) {

-    printf("\nRunEndpointOpenTest failed: succeeded on invalid EP %u", index);

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  if (!RunEndpointOpenTest(adb_interface, ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX)) {

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  if (!RunEndpointOpenTest(adb_interface, ADB_QUERY_BULK_READ_ENDPOINT_INDEX)) {

-    res = AdbCloseHandle(adb_interface);

-    if (!res)

-      printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  res = AdbCloseHandle(adb_interface);

-  if (!res) {

-    printf("\n    Unable to AdbCloseHandle. Error %u", GetLastError());

-    return false;

-  }

-

-  return true;

-}

-

-bool RunEndpointOpenTest(ADBAPIHANDLE adb_interface, UCHAR index) {

-  printf("\n======= Running RunEndpointOpenTest(%X)... ", index);

-  ADBAPIHANDLE adb_endpoint = AdbOpenEndpoint(adb_interface,

-                                              index,

-                                              AdbOpenAccessTypeReadWrite,

-                                              AdbOpenSharingModeReadWrite);

-  if (NULL == adb_endpoint) {

-    if ((index < 2) || (ADB_QUERY_BULK_WRITE_ENDPOINT_INDEX == index) ||

-        (ADB_QUERY_BULK_READ_ENDPOINT_INDEX == index)) {

-      printf("\n        AdbOpenEndpoint(%X) error %u", index, GetLastError());

-    }

-    return false;

-  }

-

-  ADBAPIHANDLE parent = AdbGetEndpointInterface(adb_endpoint);

-  if (parent != adb_interface) {

-    printf("\n        AdbGetEndpointInterface(%X) failure: expected %p returned %p, error %u",

-           index, adb_interface, parent, GetLastError());

-    AdbCloseHandle(adb_endpoint);

-    return false;

-  }

-

-  AdbEndpointInformation info;

-  if (!AdbQueryInformationEndpoint(adb_endpoint, &info)) {

-    printf("\n    Unable to AdbGetEndpointInformationForHandle(%X): %u",

-           index, GetLastError());

-    AdbCloseHandle(adb_endpoint);

-    return false;

-  }

-

-  if (!CheckEndpointInfo(index, &info)) {

-    printf("\n        Wrong AdbEndpointInformation(%X)", index);

-    AdbCloseHandle(adb_endpoint);

-    return false;

-  }

-

-  AdbCloseHandle(adb_endpoint);

-

-  printf(" SUCCESS");

-  return true;

-}

-

-bool RunEndpointIoTest(ULONG time_out_base) {

-  printf("\n\n=== Running RunEndpointIoTest(%u)... ", time_out_base);

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_EMULATOR_PROD_ID,

-                                                  0xFF);

-  if (NULL == adb_interface) {

-    printf("\n    AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  ADBAPIHANDLE adb_read_endpoint =

-    AdbOpenDefaultBulkReadEndpoint(adb_interface,

-                                   AdbOpenAccessTypeReadWrite,

-                                   AdbOpenSharingModeReadWrite);

-  if (NULL == adb_read_endpoint) {

-    printf("\n    AdbOpenDefaultBulkReadEndpoint error %u", GetLastError());

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  ADBAPIHANDLE adb_write_endpoint =

-    AdbOpenDefaultBulkWriteEndpoint(adb_interface,

-                                    AdbOpenAccessTypeReadWrite,

-                                    AdbOpenSharingModeReadWrite);

-  if (NULL == adb_write_endpoint) {

-    printf("\n    AdbOpenDefaultBulkWriteEndpoint error %u", GetLastError());

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  AdbEndpointInformation read_info;

-  AdbEndpointInformation write_info;

-

-  if (!AdbQueryInformationEndpoint(adb_read_endpoint, &read_info)) {

-    printf("\n    AdbQueryInformationEndpoint(read) error %u", GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  if (!AdbQueryInformationEndpoint(adb_write_endpoint, &write_info)) {

-    printf("\n    AdbQueryInformationEndpoint(write) error %u", GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  char read_buf[40960];

-  char write_buf[40960];

-  ULONG written, read;

-  ULONG small_block = 101;

-  ULONG partial_small_block = small_block - 10;

-  ULONG large_block = write_info.max_packet_size * 3 + 3;

-

-  bool wr_res;

-  bool rd_res;

-

-  // Simple synchronous write / read of a small block

-  memset(write_buf, '0', small_block);

-  wr_res = AdbWriteEndpointSync(adb_write_endpoint, write_buf, small_block, &written, time_out_base * small_block);

-  if (!wr_res || (written != small_block)) {

-    printf("\n    AdbWriteEndpointSync(%u) failure (%u). Written %u. Error %u",

-           small_block, wr_res, written, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbReadEndpointSync(adb_read_endpoint, read_buf, small_block, &read, time_out_base * small_block);

-  if (!rd_res || (small_block != read)) {

-    printf("\n    AdbReadEndpointSync(%u) failure (%u). Read %u. Error %u",

-           small_block, rd_res, read, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  if (0 != memcmp(read_buf, write_buf, read)) {

-    printf("\n    Simple sync r/w %u data wrong.", small_block);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Simple synchronous write / read of a large block

-  memset(write_buf, '1', large_block);

-  wr_res = AdbWriteEndpointSync(adb_write_endpoint, write_buf, large_block, &written, time_out_base * large_block);

-  if (!wr_res || (written != large_block)) {

-    printf("\n    AdbWriteEndpointSync(%u) failure (%u). Written %u. Error %u",

-           large_block, wr_res, written, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbReadEndpointSync(adb_read_endpoint, read_buf, large_block, &read, time_out_base * large_block);

-  if (!rd_res || (large_block != read)) {

-    printf("\n    AdbReadEndpointSync(%u) failure (%u). Read %u. Error %u",

-           large_block, rd_res, read, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  if (0 != memcmp(read_buf, write_buf, read)) {

-    printf("\n    Simple sync r/w %u data wrong.", large_block);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Simple synchronous write / partial read of a small block

-  memset(write_buf, 'u', small_block);

-  wr_res = AdbWriteEndpointSync(adb_write_endpoint, write_buf, partial_small_block, &written, time_out_base * small_block);

-  if (!wr_res || (written != partial_small_block)) {

-    printf("\n    AdbWriteEndpointSync(%u) failure (%u). Written %u. Error %u",

-           partial_small_block, wr_res, written, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbReadEndpointSync(adb_read_endpoint, read_buf, small_block, &read, time_out_base * small_block);

-  if (!rd_res || (partial_small_block != read)) {

-    printf("\n    AdbReadEndpointSync(%u) failure (%u). Read %u. Error %u",

-           partial_small_block, rd_res, read, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  if (0 != memcmp(read_buf, write_buf, read)) {

-    printf("\n    Simple sync r/w %u data wrong.", small_block);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Simple Aynchronous write / read

-  memset(write_buf, 'A', small_block);

-

-  ADBAPIHANDLE adb_w_complete = 

-    AdbWriteEndpointAsync(adb_write_endpoint, write_buf, small_block, &written, time_out_base * small_block, NULL);

-

-  if (NULL == adb_w_complete) {

-    printf("\n    AdbWriteEndpointAsync(%u) error %u",

-           small_block, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  wr_res = AdbGetOvelappedIoResult(adb_w_complete, NULL, &written, true);

-  if (!wr_res || (small_block != written)) {

-    printf("\n    AdbGetOvelappedIoResult(write %u) failure (%u). Error %u, written %u",

-           small_block, wr_res, GetLastError(), written);

-    AdbCloseHandle(adb_w_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_w_complete);

-

-  ADBAPIHANDLE adb_r_complete = 

-    AdbReadEndpointAsync(adb_read_endpoint, read_buf, small_block, &read, time_out_base * small_block, NULL);

-  if (NULL == adb_r_complete) {

-    printf("\n    AdbReadEndpointAsync(%u) error %u", small_block, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbGetOvelappedIoResult(adb_r_complete, NULL, &read, true);

-  if (!rd_res || (read != small_block)) {

-    printf("\n    AdbGetOvelappedIoResult(read %u) failure (%u). Error %u, read %u",

-           small_block, rd_res, GetLastError(), read);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_r_complete);

-

-  if (0 != memcmp(read_buf, write_buf, read)) {

-    printf("\n    Simple async r/w %u data wrong", small_block);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // Large Aynchronous write / read

-  memset(write_buf, 'B', large_block);

-

-  adb_w_complete = 

-    AdbWriteEndpointAsync(adb_write_endpoint, write_buf, large_block, &written, time_out_base * large_block, NULL);

-

-  if (NULL == adb_w_complete) {

-    printf("\n    AdbWriteEndpointAsync(%u) error %u",

-           large_block, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  wr_res = AdbGetOvelappedIoResult(adb_w_complete, NULL, &written, true);

-  if (!wr_res || (large_block != written)) {

-    printf("\n    AdbGetOvelappedIoResult(write %u) failure (%u). Error %u, written %u",

-           large_block, wr_res, GetLastError(), written);

-    AdbCloseHandle(adb_w_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_w_complete);

-

-  adb_r_complete = 

-    AdbReadEndpointAsync(adb_read_endpoint, read_buf, large_block, &read, time_out_base * large_block, NULL);

-  if (NULL == adb_r_complete) {

-    printf("\n    AdbReadEndpointAsync(%u) error %u", large_block, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbGetOvelappedIoResult(adb_r_complete, NULL, &read, true);

-  if (!rd_res || (read != large_block)) {

-    printf("\n    AdbGetOvelappedIoResult(read %u) failure (%u). Error %u, read %u",

-           large_block, rd_res, GetLastError(), read);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_r_complete);

-

-  if (0 != memcmp(read_buf, write_buf, read)) {

-    printf("\n    Simple async r/w %u data wrong", large_block);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  // We disable this test because our new read model is no longer accumulative

-#if 0

-  // One async read, many async writes

-  ULONG total = write_info.max_packet_size * 5 + 3;

-  ULONG block1 = write_info.max_packet_size + 1;

-  ULONG block2 = write_info.max_packet_size * 3 + 7;

-  ULONG block3 = total - block2 - block1;

-  memset(write_buf, 'a', block1);

-  memset(write_buf + block1, 'b', block2);

-  memset(write_buf + block1 + block2, 'c', block3);

-

-  adb_r_complete = 

-    AdbReadEndpointAsync(adb_read_endpoint, read_buf, total, &read, time_out_base * total, NULL);

-  if (NULL == adb_r_complete) {

-    printf("\n    AdbReadEndpointAsync(%u) error %u", total, GetLastError());

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbGetOvelappedIoResult(adb_r_complete, NULL, &read, false);

-  if (rd_res || (GetLastError() != ERROR_IO_INCOMPLETE)) {

-    printf("\n    AdbGetOvelappedIoResult(read %u) failure (%u). Error %u, read %u",

-           total, rd_res, GetLastError(), read);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  ADBAPIHANDLE adb_w_complete1 = 

-    AdbWriteEndpointAsync(adb_write_endpoint, write_buf, block1, &written, time_out_base * block1, NULL);

-  if (NULL == adb_w_complete1) {

-    printf("\n    Multiwrite block 1 AdbWriteEndpointAsync(%u) error %u",

-           block1, GetLastError());

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  ADBAPIHANDLE adb_w_complete2 = 

-    AdbWriteEndpointAsync(adb_write_endpoint, write_buf + block1, block2, &written, time_out_base * block2, NULL);

-  if (NULL == adb_w_complete2) {

-    printf("\n    Multiwrite block 2 AdbWriteEndpointAsync(%u) error %u",

-           block1, GetLastError());

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  ADBAPIHANDLE adb_w_complete3 = 

-    AdbWriteEndpointAsync(adb_write_endpoint, write_buf + block1 + block2, block3, &written, time_out_base * block3, NULL);

-  if (NULL == adb_w_complete3) {

-    printf("\n    Multiwrite block 3 AdbWriteEndpointAsync(%u) error %u",

-           block1, GetLastError());

-    AdbCloseHandle(adb_w_complete2);

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  rd_res = AdbGetOvelappedIoResult(adb_r_complete, NULL, &read, true);

-  if (!rd_res || (read != total)) {

-    printf("\n    AdbGetOvelappedIoResult(read %u) failure (%u). Error %u, read %u",

-           total, rd_res, GetLastError(), read);

-    AdbCloseHandle(adb_w_complete3);

-    AdbCloseHandle(adb_w_complete2);

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_r_complete);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_r_complete);

-

-  wr_res = AdbGetOvelappedIoResult(adb_w_complete3, NULL, &written, true);

-  if (!wr_res || (block3 != written)) {

-    printf("\n    Multiwrite block 3 AdbGetOvelappedIoResult(write %u) failure (%u). Error %u, written %u",

-           block3, wr_res, GetLastError(), written);

-    AdbCloseHandle(adb_w_complete3);

-    AdbCloseHandle(adb_w_complete2);

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_w_complete3);

-

-  wr_res = AdbGetOvelappedIoResult(adb_w_complete2, NULL, &written, true);

-  if (!wr_res || (block2 != written)) {

-    printf("\n    Multiwrite block 2 AdbGetOvelappedIoResult(write %u) failure (%u). Error %u, written %u",

-           block2, wr_res, GetLastError(), written);

-    AdbCloseHandle(adb_w_complete2);

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_w_complete2);

-

-  wr_res = AdbGetOvelappedIoResult(adb_w_complete1, NULL, &written, true);

-  if (!wr_res || (block1 != written)) {

-    printf("\n    Multiwrite block 1 AdbGetOvelappedIoResult(write %u) failure (%u). Error %u, written %u",

-           block1, wr_res, GetLastError(), written);

-    AdbCloseHandle(adb_w_complete1);

-    AdbCloseHandle(adb_write_endpoint);

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-  AdbCloseHandle(adb_w_complete1);

-#endif  // 0

-

-#if 0

-  // Async writes are not syncronized

-  if (0 != memcmp(read_buf, write_buf, block1)) {

-    printf("\n   First block wrong");

-  } else {

-    if (0 != memcmp(read_buf + block1, write_buf + block1, block2)) {

-      printf("\n   Second block wrong");

-    } else {

-      if (0 != memcmp(read_buf + block1 + block2, write_buf + block1 + block2, block3)) {

-        printf("\n   Second block wrong");

-      }

-    }

-  }

-#endif  // 0

-

-  AdbCloseHandle(adb_write_endpoint);

-  AdbCloseHandle(adb_read_endpoint);

-  AdbCloseHandle(adb_interface);

-

-  printf(" SUCCESS.");

-  return true;

-}

-

-bool RunTimeoutsTest() {

-  printf("\n\n=== Running RunTimeoutsTest... ");

-  ADBAPIHANDLE adb_interface = AdbCreateInterface(adb_class_id,

-                                                  DEVICE_VENDOR_ID,

-                                                  DEVICE_EMULATOR_PROD_ID,

-                                                  0xFF);

-  if (NULL == adb_interface) {

-    printf("\n    AdbCreateInterface returned error %u", GetLastError());

-    return false;

-  }

-

-  ADBAPIHANDLE adb_read_endpoint =

-    AdbOpenDefaultBulkReadEndpoint(adb_interface,

-                                   AdbOpenAccessTypeReadWrite,

-                                   AdbOpenSharingModeReadWrite);

-  if (NULL == adb_read_endpoint) {

-    printf("\n    AdbOpenDefaultBulkReadEndpoint error %u", GetLastError());

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  ADBAPIHANDLE adb_write_endpoint =

-    AdbOpenDefaultBulkWriteEndpoint(adb_interface,

-                                    AdbOpenAccessTypeReadWrite,

-                                    AdbOpenSharingModeReadWrite);

-  if (NULL == adb_write_endpoint) {

-    printf("\n    AdbOpenDefaultBulkWriteEndpoint error %u", GetLastError());

-    AdbCloseHandle(adb_read_endpoint);

-    AdbCloseHandle(adb_interface);

-    return false;

-  }

-

-  char read_buf[40960];

-  char write_buf[40960];

-  ULONG written, read;

-  ULONG small_block = 60;

-

-  // Test virtually no timeouts

-  for (int n = 0; n < 8; n++) {

-    memset(write_buf, 'S', small_block);

-    bool wr_res = AdbWriteEndpointSync(adb_write_endpoint, write_buf, small_block, &written, 0xFFFFFFF);

-    if (!wr_res || (written != small_block)) {

-      printf("\n    AdbWriteEndpointSync(%u) failure (%u). Written %u. Error %u",

-            small_block, wr_res, written, GetLastError());

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-

-    bool rd_res = AdbReadEndpointSync(adb_read_endpoint, read_buf, small_block, &read, 0xFFFFFFF);

-    if (!rd_res || (small_block != read)) {

-      printf("\n    AdbReadEndpointSync(%u) failure (%u). Read %u. Error %u",

-            small_block, rd_res, read, GetLastError());

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-

-    if (0 != memcmp(read_buf, write_buf, read)) {

-      printf("\n    Simple sync r/w %u data wrong.", small_block);

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-  }

-/*

-  ULONG large_block = 2048;

-

-  // Test rediculously small timeouts

-  for (n = 0; n < 20; n++) {

-    memset(write_buf, 'L', large_block);

-    bool wr_res = AdbWriteEndpointSync(adb_write_endpoint, write_buf, large_block, &written, 1);

-    if (!wr_res || (written != small_block)) {

-      printf("\n    AdbWriteEndpointSync(%u) failure (%u). Written %u. Error %u",

-            large_block, wr_res, written, GetLastError());

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-

-    bool rd_res = AdbReadEndpointSync(adb_read_endpoint, read_buf, large_block, &read, 1);

-    if (!rd_res || (small_block != read)) {

-      printf("\n    AdbReadEndpointSync(%u) failure (%u). Read %u. Error %u",

-            large_block, rd_res, read, GetLastError());

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-

-    if (0 != memcmp(read_buf, write_buf, read)) {

-      printf("\n    Simple sync r/w %u data wrong.", small_block);

-      AdbCloseHandle(adb_write_endpoint);

-      AdbCloseHandle(adb_read_endpoint);

-      AdbCloseHandle(adb_interface);

-      return false;

-    }

-  }

-*/

-  AdbCloseHandle(adb_write_endpoint);

-  AdbCloseHandle(adb_read_endpoint);

-  AdbCloseHandle(adb_interface);

-

-  printf(" SUCCESS.");

-  return true;

-}

-

-bool CheckEndpointInfo(UCHAR index, AdbEndpointInformation* info) {

-  AdbEndpointInformation* cmp;

-

-  switch (index) {

-    case test_read_pipe_index:

-    case ADB_QUERY_BULK_READ_ENDPOINT_INDEX:

-      cmp = test_read_pipe;

-      break;

-

-    default:

-      cmp = test_write_pipe;

-      break;

-  };

-

-  if ((info->max_packet_size != cmp->max_packet_size) ||

-      (info->endpoint_address != cmp->endpoint_address) ||

-      (info->polling_interval != cmp->polling_interval) ||

-      (info->setting_index != cmp->setting_index) ||

-      (info->endpoint_type != cmp->endpoint_type) ||

-      (info->max_transfer_size != cmp->max_transfer_size)) {

-    return false;

-  }

-

-  return true;

-}

-

-/*

-  printf("\n***** USB_DEVICE_DESCRIPTOR");

-  printf("\n      bDescriptorType    = %u", dev_desc.bDescriptorType);

-  printf("\n      bcdUSB             = x%02X", dev_desc.bcdUSB);

-  printf("\n      bDeviceClass       = x%02X", dev_desc.bDeviceClass);

-  printf("\n      bDeviceSubClass    = x%02X", dev_desc.bDeviceSubClass);

-  printf("\n      bDeviceProtocol    = x%02X", dev_desc.bDeviceProtocol);

-  printf("\n      bMaxPacketSize     = %u", dev_desc.bMaxPacketSize0);

-  printf("\n      idVendor           = x%04X", dev_desc.idVendor);

-  printf("\n      idProduct          = x%04X", dev_desc.idProduct);

-  printf("\n      bcdDevice          = x%02X", dev_desc.bcdDevice);

-  printf("\n      iManufacturer      = %u", dev_desc.iManufacturer);

-  printf("\n      iProduct           = %u", dev_desc.iProduct);

-  printf("\n      iSerialNumber      = %u", dev_desc.iSerialNumber);

-  printf("\n      bNumConfigurations = %u", dev_desc.bNumConfigurations);

-

-  printf("\n\n***** USB_CONFIGURATION_DESCRIPTOR");

-  printf("\n      bDescriptorType     = %u", config_desc.bDescriptorType);

-  printf("\n      wTotalLength        = %u", config_desc.wTotalLength);

-  printf("\n      bNumInterfaces      = %u", config_desc.bNumInterfaces);

-  printf("\n      bConfigurationValue = %u", config_desc.bConfigurationValue);

-  printf("\n      iConfiguration      = %u", config_desc.iConfiguration);

-  printf("\n      bmAttributes        = %u", config_desc.bmAttributes);

-  printf("\n      MaxPower            = %u", config_desc.MaxPower);

-

-  printf("\n\n***** USB_INTERFACE_DESCRIPTOR");

-  printf("\n      bLength            = %u", interface_desc.bLength);

-  printf("\n      bDescriptorType    = %u", interface_desc.bDescriptorType);

-  printf("\n      bInterfaceNumber   = %u", interface_desc.bInterfaceNumber);

-  printf("\n      bAlternateSetting  = %u", interface_desc.bAlternateSetting);

-  printf("\n      bNumEndpoints      = %u", interface_desc.bNumEndpoints);

-  printf("\n      bInterfaceClass    = x%02X", interface_desc.bInterfaceClass);

-  printf("\n      bInterfaceSubClass = x%02X", interface_desc.bInterfaceSubClass);

-  printf("\n      bInterfaceProtocol = x%02X", interface_desc.bInterfaceProtocol);

-  printf("\n      iInterface         = %u", interface_desc.iInterface);

-

-  printf("\n***** ENDPOINT[%X]", index);

-  printf("\n      MaximumPacketSize   = %u", info.max_packet_size);

-  printf("\n      EndpointAddress     = x%02X", info.endpoint_address);

-  printf("\n      Interval            = %u", info.polling_interval);

-  printf("\n      SettingIndex        = %u", info.setting_index);

-  printf("\n      PipeType            = %u", info.endpoint_type);

-  printf("\n      MaximumTransferSize = %u", info.max_transfer_size);

-*/
diff --git a/host/windows/usb/test/android_usb_test/android_usb_test.sln b/host/windows/usb/test/android_usb_test/android_usb_test.sln
deleted file mode 100644
index 1202096..0000000
--- a/host/windows/usb/test/android_usb_test/android_usb_test.sln
+++ /dev/null
@@ -1,29 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 8.00

-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "android_usb_test", "android_usb_test.vcproj", "{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}"

-	ProjectSection(ProjectDependencies) = postProject

-	EndProjectSection

-EndProject

-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AdbWinApi", "..\..\api\AdbWinApi.vcproj", "{C0A471E9-6892-4270-96DE-DB5F8D526FB1}"

-	ProjectSection(ProjectDependencies) = postProject

-	EndProjectSection

-EndProject

-Global

-	GlobalSection(SolutionConfiguration) = preSolution

-		Debug = Debug

-		Release = Release

-	EndGlobalSection

-	GlobalSection(ProjectConfiguration) = postSolution

-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Debug.ActiveCfg = Debug|Win32

-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Debug.Build.0 = Debug|Win32

-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Release.ActiveCfg = Release|Win32

-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Release.Build.0 = Release|Win32

-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.ActiveCfg = Debug|Win32

-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.Build.0 = Debug|Win32

-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.ActiveCfg = Release|Win32

-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.Build.0 = Release|Win32

-	EndGlobalSection

-	GlobalSection(ExtensibilityGlobals) = postSolution

-	EndGlobalSection

-	GlobalSection(ExtensibilityAddIns) = postSolution

-	EndGlobalSection

-EndGlobal

diff --git a/host/windows/usb/test/android_usb_test/android_usb_test.vcproj b/host/windows/usb/test/android_usb_test/android_usb_test.vcproj
deleted file mode 100644
index ff93586..0000000
--- a/host/windows/usb/test/android_usb_test/android_usb_test.vcproj
+++ /dev/null
@@ -1,174 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>

-<VisualStudioProject

-	ProjectType="Visual C++"

-	Version="7.10"

-	Name="android_usb_test"

-	ProjectGUID="{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}"

-	RootNamespace="android_usb_test"

-	Keyword="Win32Proj">

-	<Platforms>

-		<Platform

-			Name="Win32"/>

-	</Platforms>

-	<Configurations>

-		<Configuration

-			Name="Debug|Win32"

-			OutputDirectory="Debug"

-			IntermediateDirectory="Debug"

-			ConfigurationType="1"

-			UseOfATL="1"

-			CharacterSet="1">

-			<Tool

-				Name="VCCLCompilerTool"

-				Optimization="0"

-				AdditionalIncludeDirectories="C:\WINDDK\6000\inc\api;..\..\common;..\..\api;..\..\..\..\..\..\..\..\google3\testing\base"

-				PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"

-				MinimalRebuild="TRUE"

-				ExceptionHandling="TRUE"

-				BasicRuntimeChecks="3"

-				RuntimeLibrary="1"

-				TreatWChar_tAsBuiltInType="TRUE"

-				UsePrecompiledHeader="3"

-				ProgramDataBaseFileName="..\..\build\$(OutDir)\i386\$(TargetName).pdb"

-				WarningLevel="4"

-				WarnAsError="TRUE"

-				Detect64BitPortabilityProblems="TRUE"

-				DebugInformationFormat="4"/>

-			<Tool

-				Name="VCCustomBuildTool"/>

-			<Tool

-				Name="VCLinkerTool"

-				AdditionalDependencies="AdbWinApi.lib shlwapi.lib"

-				OutputFile="..\..\build\$(OutDir)\i386/android_usb_test.exe"

-				LinkIncremental="2"

-				AdditionalLibraryDirectories="&quot;..\..\build\$(OutDir)\i386&quot;"

-				GenerateDebugInformation="TRUE"

-				ProgramDatabaseFile="..\..\build\$(OutDir)\i386\$(TargetName).pdb"

-				SubSystem="1"

-				TargetMachine="1"/>

-			<Tool

-				Name="VCMIDLTool"/>

-			<Tool

-				Name="VCPostBuildEventTool"/>

-			<Tool

-				Name="VCPreBuildEventTool"

-				Description="Set DDK environment"

-				CommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ chk WXP"/>

-			<Tool

-				Name="VCPreLinkEventTool"/>

-			<Tool

-				Name="VCResourceCompilerTool"/>

-			<Tool

-				Name="VCWebServiceProxyGeneratorTool"/>

-			<Tool

-				Name="VCXMLDataGeneratorTool"/>

-			<Tool

-				Name="VCWebDeploymentTool"/>

-			<Tool

-				Name="VCManagedWrapperGeneratorTool"/>

-			<Tool

-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>

-		</Configuration>

-		<Configuration

-			Name="Release|Win32"

-			OutputDirectory="Release"

-			IntermediateDirectory="Release"

-			ConfigurationType="1"

-			UseOfATL="1"

-			CharacterSet="1">

-			<Tool

-				Name="VCCLCompilerTool"

-				Optimization="4"

-				InlineFunctionExpansion="1"

-				AdditionalIncludeDirectories="C:\WINDDK\6000\inc\api;..\..\common;..\..\api;..\..\..\..\..\..\..\..\google3\testing\base"

-				PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"

-				ExceptionHandling="TRUE"

-				RuntimeLibrary="0"

-				TreatWChar_tAsBuiltInType="TRUE"

-				UsePrecompiledHeader="3"

-				ProgramDataBaseFileName="..\..\build\$(OutDir)\i386\$(TargetName).pdb"

-				WarningLevel="4"

-				WarnAsError="TRUE"

-				Detect64BitPortabilityProblems="TRUE"

-				DebugInformationFormat="3"/>

-			<Tool

-				Name="VCCustomBuildTool"/>

-			<Tool

-				Name="VCLinkerTool"

-				AdditionalDependencies="AdbWinApi.lib"

-				OutputFile="..\..\build\$(OutDir)\i386/android_usb_test.exe"

-				LinkIncremental="1"

-				AdditionalLibraryDirectories="&quot;..\..\build\$(OutDir)\i386&quot;"

-				GenerateDebugInformation="TRUE"

-				ProgramDatabaseFile="..\..\build\$(OutDir)\i386\$(TargetName).pdb"

-				SubSystem="1"

-				OptimizeReferences="2"

-				EnableCOMDATFolding="2"

-				TargetMachine="1"/>

-			<Tool

-				Name="VCMIDLTool"/>

-			<Tool

-				Name="VCPostBuildEventTool"/>

-			<Tool

-				Name="VCPreBuildEventTool"

-				Description="Set DKK environment"

-				CommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ fre WXP"/>

-			<Tool

-				Name="VCPreLinkEventTool"/>

-			<Tool

-				Name="VCResourceCompilerTool"/>

-			<Tool

-				Name="VCWebServiceProxyGeneratorTool"/>

-			<Tool

-				Name="VCXMLDataGeneratorTool"/>

-			<Tool

-				Name="VCWebDeploymentTool"/>

-			<Tool

-				Name="VCManagedWrapperGeneratorTool"/>

-			<Tool

-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>

-		</Configuration>

-	</Configurations>

-	<References>

-	</References>

-	<Files>

-		<Filter

-			Name="Source Files"

-			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"

-			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">

-			<File

-				RelativePath=".\android_usb_test.cpp">

-			</File>

-			<File

-				RelativePath=".\stdafx.cpp">

-				<FileConfiguration

-					Name="Debug|Win32">

-					<Tool

-						Name="VCCLCompilerTool"

-						UsePrecompiledHeader="1"/>

-				</FileConfiguration>

-				<FileConfiguration

-					Name="Release|Win32">

-					<Tool

-						Name="VCCLCompilerTool"

-						UsePrecompiledHeader="1"/>

-				</FileConfiguration>

-			</File>

-		</Filter>

-		<Filter

-			Name="Header Files"

-			Filter="h;hpp;hxx;hm;inl;inc;xsd"

-			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">

-			<File

-				RelativePath=".\stdafx.h">

-			</File>

-		</Filter>

-		<Filter

-			Name="Resource Files"

-			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"

-			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">

-		</Filter>

-	</Files>

-	<Globals>

-	</Globals>

-</VisualStudioProject>

diff --git a/host/windows/usb/test/android_usb_test/stdafx.cpp b/host/windows/usb/test/android_usb_test/stdafx.cpp
deleted file mode 100644
index 536a4ef..0000000
--- a/host/windows/usb/test/android_usb_test/stdafx.cpp
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// stdafx.cpp : source file that includes just the standard includes

-// android_usb_test.pch will be the pre-compiled header

-// stdafx.obj will contain the pre-compiled type information

-

-#include "stdafx.h"

-

-// TODO: reference any additional headers you need in STDAFX.H

-// and not in this file

diff --git a/host/windows/usb/test/android_usb_test/stdafx.h b/host/windows/usb/test/android_usb_test/stdafx.h
deleted file mode 100644
index ab0e165..0000000
--- a/host/windows/usb/test/android_usb_test/stdafx.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// stdafx.h : include file for standard system include files,

-// or project specific include files that are used frequently, but

-// are changed infrequently

-//

-

-#pragma once

-

-

-#include <iostream>

-#include <tchar.h>

-#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS	// some CString constructors will be explicit

-

-#include <atlbase.h>

-#pragma warning(disable: 4200)
-extern "C" {
-#include <usbdi.h>

-}

-#include "android_usb_common_defines.h"
-#include "adb_api.h"

-

-// TODO: reference additional headers your program requires here

diff --git a/host/windows/usb/test/device_emulator/DeviceEmulator.cpp b/host/windows/usb/test/device_emulator/DeviceEmulator.cpp
deleted file mode 100644
index 155a6f6..0000000
--- a/host/windows/usb/test/device_emulator/DeviceEmulator.cpp
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file definies entry point for the DLL.

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-    

-#include "stdafx.h"

-#include "resource.h"

-#include <dsfif.h>

-#include <USBProtocolDefs.h>

-#include <softusbif.h>

-#include "LoopbackDevice.h"

-#include "DeviceEmulator.h"

-

-class CDeviceEmulatorModule : public CAtlDllModuleT<CDeviceEmulatorModule> {

- public: 

-  DECLARE_LIBID(LIBID_DeviceEmulatorLib)

-  DECLARE_REGISTRY_APPID_RESOURCEID(IDR_DEVICEEMULATOR, "{D1C80253-8DB4-4F72-BF74-270A0EDA1FA9}")

-};

-

-CDeviceEmulatorModule _AtlModule;

-

-/////////////////////////////////////////////////////////////////////////////

-// DLL Entry Point

-

-extern "C"

-BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) {

-  hInstance;

-  return _AtlModule.DllMain(dwReason, lpReserved);

-}

-

-/////////////////////////////////////////////////////////////////////////////

-// Used to determine whether the DLL can be unloaded by OLE

-

-STDAPI DllCanUnloadNow(void) {

-  return (_AtlModule.DllCanUnloadNow());

-}

-

-/////////////////////////////////////////////////////////////////////////////

-// Returns a class factory to create an object of the requested type

-

-STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv) {

-  return _AtlModule.DllGetClassObject(rclsid, riid, ppv);

-}

-

-/////////////////////////////////////////////////////////////////////////////

-// DllRegisterServer - Adds entries to the system registry

-

-STDAPI DllRegisterServer(void) {

-  // registers object, typelib and all interfaces in typelib

-  HRESULT hr =  _AtlModule.DllRegisterServer();

-  return hr;

-}

-

-/////////////////////////////////////////////////////////////////////////////

-// DllUnregisterServer - Removes entries from the system registry

-

-STDAPI DllUnregisterServer(void) {

-  HRESULT hr = _AtlModule.DllUnregisterServer();

-  return hr;

-}

-

-

-

-

-

diff --git a/host/windows/usb/test/device_emulator/DeviceEmulator.def b/host/windows/usb/test/device_emulator/DeviceEmulator.def
deleted file mode 100644
index 2a7cd7c..0000000
--- a/host/windows/usb/test/device_emulator/DeviceEmulator.def
+++ /dev/null
@@ -1,16 +0,0 @@
-;Module Name:

-;

-;   DeviceEmulator.def 

-;

-;Abstract:

-;    Declares the module parameters

-;

-

-LIBRARY      "DeviceEmulator.DLL"

-

-EXPORTS

-    DllCanUnloadNow     PRIVATE

-    DllGetClassObject   PRIVATE

-    DllRegisterServer   PRIVATE

-    DllUnregisterServer PRIVATE

-

diff --git a/host/windows/usb/test/device_emulator/DeviceEmulator.idl b/host/windows/usb/test/device_emulator/DeviceEmulator.idl
deleted file mode 100644
index 9b60eb2..0000000
--- a/host/windows/usb/test/device_emulator/DeviceEmulator.idl
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file consists of library definition for DeviceEmulator device.

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-

-import "oaidl.idl";

-import "ocidl.idl";

-

-[

-    uuid(0C206596-5CC2-4d16-898D-4D1699BB6282),

-    version(1.0),

-    helpstring("DeviceEmulator 1.0 Type Library")

-]

-library DeviceEmulatorLib

-{

-    importlib("stdole2.tlb");

-    importlib("dsfif.tlb");

-

-

-    [

-        object,

-        uuid(0A7E88B6-E38F-4d78-ABA3-AA30DC836B7D),

-        oleautomation,

-        dual,

-        nonextensible,

-        helpstring("ILoopbackDevice Interface"),

-        pointer_default(unique)

-    ]

-    interface ILoopbackDevice : IDispatch

-    {

-        [

-            propget, 

-            id(1), 

-            helpstring("property DSFDevice")

-        ]

-        HRESULT DSFDevice([out, retval] DSFDevice** ppDSFDEevice);

-

-        [

-            id(2),

-            helpstring("Demonstrates how to use the queue method to read/write data")

-        ]

-        HRESULT _stdcall DoPolledLoopback([in] long LoopInterval);

-

-        [

-            id(3),

-            helpstring("Demonstrates how to use the eventing mechanism to read/write data")

-        ]

-        HRESULT _stdcall StartEventProcessing();

-

-        [

-            id(4),

-            helpstring("Starts event-driven simulation and returns immediately to caller.")

-        ]

-        HRESULT _stdcall StartAsyncEventProcessing();

-

-        [

-            id(5),

-            helpstring("Stops event-driven simulation started by a prior call to StartAsyncEventProcessing.")

-        ]

-        HRESULT _stdcall StopAsyncEventProcessing();

-

-        [

-            id(6),

-            helpstring("Check to see if there is any key strokes to be processed")

-        ]

-        HRESULT AreKeystrokesWaiting([out, retval] VARIANT_BOOL *pfvarKeysWaiting);

-    };

-

-    [

-        uuid(4F28A221-47B1-4f74-9ECC-CEADEDA0A287),

-        nonextensible,

-        helpstring("Loopback device event interface."),

-

-    ]

-    dispinterface ILoopbackDeviceEvents

-    {

-        properties:

-        methods:

-        [

-            id(1),

-            helpstring("Detemine if the device should stop polling the endpoint for data")

-        ]

-        HRESULT _stdcall ContinueToPoll([out,retval] VARIANT_BOOL *pfvarConitnue);

-

-        [

-            id(2),

-            helpstring("Detemine if the device should stop the event processing")

-        ]

-        HRESULT _stdcall ContinueEventProcessing([out,retval] VARIANT_BOOL *pfvarConitnue);

-    }

-

-    [

-        uuid(9A0BD4A6-E346-4668-A89C-ACA546212CD4),

-        helpstring("LoopbackDevice Class")

-    ]

-    coclass LoopbackDevice

-    {

-        [default] interface ILoopbackDevice;

-        [default, source] dispinterface ILoopbackDeviceEvents;

-    };

-};

-

diff --git a/host/windows/usb/test/device_emulator/DeviceEmulator.rc b/host/windows/usb/test/device_emulator/DeviceEmulator.rc
deleted file mode 100644
index 89fcd04..0000000
--- a/host/windows/usb/test/device_emulator/DeviceEmulator.rc
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file
-  Resource file for Device USB emulator.
-*/
-#include "resource.h"
-
-#define APSTUDIO_READONLY_SYMBOLS
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 2 resource.
-//
-#include "winres.h"
-
-/////////////////////////////////////////////////////////////////////////////
-#undef APSTUDIO_READONLY_SYMBOLS
-
-/////////////////////////////////////////////////////////////////////////////
-// English (U.S.) resources
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
-#ifdef _WIN32
-LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
-#pragma code_page(1252)
-#endif //_WIN32
-
-#ifdef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// TEXTINCLUDE
-//
-
-1 TEXTINCLUDE 
-BEGIN
-    "resource.h\0"
-END
-
-2 TEXTINCLUDE 
-BEGIN
-    "#include ""winres.h""\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE 
-BEGIN
-    "1 TYPELIB ""DeviceEmulator.tlb""\r\n"
-    "\0"
-END
-
-#endif    // APSTUDIO_INVOKED
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// Version
-//
-
-VS_VERSION_INFO VERSIONINFO
- FILEVERSION 1,0,0,1
- PRODUCTVERSION 1,0,0,1
- FILEFLAGSMASK 0x3fL
-#ifdef _DEBUG
- FILEFLAGS 0x1L
-#else
- FILEFLAGS 0x0L
-#endif
- FILEOS 0x4L
- FILETYPE 0x1L
- FILESUBTYPE 0x0L
-BEGIN
-    BLOCK "StringFileInfo"
-    BEGIN
-        BLOCK "040904e4"
-        BEGIN
-            VALUE "CompanyName", "Google, Inc."
-            VALUE "FileDescription", "Device USB Device Emulator"
-            VALUE "FileVersion", "1.0.0.1"
-            VALUE "LegalCopyright", "Copyright (C) 2007 The Android Open Source Project"
-            VALUE "InternalName", "DeviceEmulator.dll"
-            VALUE "OriginalFilename", "DeviceEmulator.dll"
-            VALUE "ProductName", "Android"
-            VALUE "ProductVersion", "1.0.0.1"
-        END
-    END
-    BLOCK "VarFileInfo"
-    BEGIN
-        VALUE "Translation", 0x409, 1252
-    END
-END
-
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// REGISTRY
-//
-
-IDR_DEVICEEMULATOR      REGISTRY                "DeviceEmulator.rgs"
-IDR_LOOPBACKDEVICE      REGISTRY                "LoopbackDevice.rgs"
-
-/////////////////////////////////////////////////////////////////////////////
-//
-// String Table
-//
-
-STRINGTABLE 
-BEGIN
-    IDS_PROJNAME            "DeviceEmulator"
-END
-
-#endif    // English (U.S.) resources
-/////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-1 TYPELIB "DeviceEmulator.tlb"
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
-
diff --git a/host/windows/usb/test/device_emulator/DeviceEmulator.rgs b/host/windows/usb/test/device_emulator/DeviceEmulator.rgs
deleted file mode 100644
index a660ea5..0000000
--- a/host/windows/usb/test/device_emulator/DeviceEmulator.rgs
+++ /dev/null
@@ -1,12 +0,0 @@
-HKCR

-{

-    NoRemove AppID

-    {

-        '%APPID%' = s 'DeviceEmulator'

-        'DeviceEmulator.EXE'

-        {

-            val AppID = s '%APPID%'

-        }

-    }

-}

-

diff --git a/host/windows/usb/test/device_emulator/LoopbackDevice.cpp b/host/windows/usb/test/device_emulator/LoopbackDevice.cpp
deleted file mode 100644
index 64ca8c6..0000000
--- a/host/windows/usb/test/device_emulator/LoopbackDevice.cpp
+++ /dev/null
@@ -1,796 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file consists of implementation of the class CLoopbackDevice:

-    Implements the interface ILoopbackDevice and

-    configures the loopback device to be a valid USB device.

-    The device then processes input to its endpoint in one of 

-    two ways.

-

-    1. By running in polled mode where the data is simply 

-       passed from the OUT Endpoint to the IN Endpoint

-

-       or

-    2. In Event mode where the loopback device receives a 

-       callback to indicate that data needs to be processed,

-       and then processes the data.

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-

-#include "stdafx.h"

-#include <stdio.h>

-#include <conio.h>

-#include <USBProtocolDefs.h>

-#include <dsfif.h>

-#include <softusbif.h>

-#include "android_usb_common_defines.h"

-#include "adb_api_extra.h"

-#include "LoopbackDevice.h"

-#include "DeviceEmulator_i.c"

-

-// These are the indexes of the string descriptors. They are used both

-// as the indexes of the strings with SoftUSBDevice.Strings and as the

-// string descriptor index property values on the various objects (e.g.

-// SoftUSBDevice.Manufacturer = STRING_IDX_MANUFACTURER).

-

-#define STRING_IDX_MANUFACTURER     1

-#define STRING_IDX_PRODUCT_DESC     2

-#define STRING_IDX_SERIAL_NO        3

-#define STRING_IDX_CONFIG           4

-#define STRING_IDX_INTERFACE        5

-

-CLoopbackDevice::CLoopbackDevice() {

-  InitMemberVariables();

-}

-

-CLoopbackDevice::~CLoopbackDevice() {

-  // Release the conneciton point

-  ReleaseConnectionPoint();

-    

-  // Release any interface which the device is holding

-  RELEASE(m_piConnectionPoint);

-  RELEASE(m_piINEndpoint);

-  RELEASE(m_piOUTEndpoint);

-

-  if (NULL != m_piSoftUSBDevice) {

-    (void)m_piSoftUSBDevice->Destroy();

-    RELEASE(m_piSoftUSBDevice);

-  }

-

-  InitMemberVariables();

-}

-

-void CLoopbackDevice::InitMemberVariables() {

-  m_piSoftUSBDevice = NULL;

-  m_piINEndpoint = NULL;

-  m_piOUTEndpoint = NULL;

-  m_piConnectionPoint = NULL;

-  m_iInterfaceString = 0;

-  m_iConfigString = 0;

-  m_dwConnectionCookie = 0;

-}

-

-HRESULT CLoopbackDevice::FinalConstruct() {

-  // Perform tasks which may fail when the class CLoopbackDevice

-  // is finally constructed. This involves creating the USB device 

-  // object and initializing the device so that it is recognized

-  // as a valid USB device by the controller

-  HRESULT hr = S_OK;

-

-  hr = CreateUSBDevice();

-  IfFailHrGo(hr);

-

-  hr = ConfigureDevice();

-  IfFailHrGo(hr);

-

-Exit:

-    return hr;

-}

-

-void CLoopbackDevice::FinalRelease() {

-}

-

-HRESULT CLoopbackDevice::CreateUSBDevice() {

-  // Creates the USB device and initializes the device member variables

-  // and creates and initializes the device qualifier. The device qualifier

-  // is required for USB2.0 devices.

-

-  HRESULT hr = S_OK;

-  ISoftUSBDeviceQualifier* piDeviceQual = NULL;

-  USHORT prod_id = DEVICE_EMULATOR_PROD_ID;

-

-  hr = ::CoCreateInstance(CLSID_SoftUSBDevice, 

-                          NULL,

-                          CLSCTX_INPROC_SERVER,

-                          __uuidof(ISoftUSBDevice),     

-                          reinterpret_cast<void**>(&m_piSoftUSBDevice));

-

-  IfFailHrGo(hr);

-

-  // Create the device qualifer

-  hr = ::CoCreateInstance(CLSID_SoftUSBDeviceQualifier, 

-                          NULL,

-                          CLSCTX_INPROC_SERVER,

-                          __uuidof(ISoftUSBDeviceQualifier),     

-                          reinterpret_cast<void**>(&piDeviceQual));

-

-  IfFailHrGo(hr);

-

-  // Setup the device qualifier

-  // binary coded decimal USB version 2.0

-  IfFailHrGo(piDeviceQual->put_USB(0x0200));

-  // FF=Vendor specfic device class

-  IfFailHrGo(piDeviceQual->put_DeviceClass(0xff)); 

-  // FF = Vendor specific device sub-class

-  IfFailHrGo(piDeviceQual->put_DeviceSubClass(0xff));

-  // FF = Vendor specific device protocol

-  IfFailHrGo(piDeviceQual->put_DeviceProtocol(0xff)); 

-  // Max packet size endpoint 0

-  IfFailHrGo(piDeviceQual->put_MaxPacketSize0(64)); 

-  // Number of configurations

-  IfFailHrGo(piDeviceQual->put_NumConfigurations(1));

-

-  // Setup the device 

-  // binary coded decimal USB version 2.0

-  IfFailHrGo(m_piSoftUSBDevice->put_USB(0x0200));

-  // FF=Vendor specfic device class

-  IfFailHrGo(m_piSoftUSBDevice->put_DeviceClass(0xff));

-  // FF = Vendor specific device sub-class

-  IfFailHrGo(m_piSoftUSBDevice->put_DeviceSubClass(0xff));

-  // FF = Vendor specific device protocol

-  IfFailHrGo(m_piSoftUSBDevice->put_DeviceProtocol(0xff)); 

-  // Max packet size endpoint 0

-  IfFailHrGo(m_piSoftUSBDevice->put_MaxPacketSize0(64)); 

-  // Vendor ID - Google

-  IfFailHrGo(m_piSoftUSBDevice->put_Vendor(DEVICE_VENDOR_ID));

-  // product id - Device Emulator

-  IfFailHrGo(m_piSoftUSBDevice->put_Product(static_cast<SHORT>(prod_id))); 

-  // Binary decimal coded version 1.0

-  IfFailHrGo(m_piSoftUSBDevice->put_Device(0x0100));

-  // Device does not suppport remote wake up

-  IfFailHrGo(m_piSoftUSBDevice->put_RemoteWakeup(VARIANT_FALSE));

-  // Index of the manufacturer string

-  IfFailHrGo(m_piSoftUSBDevice->put_Manufacturer(STRING_IDX_MANUFACTURER));

-  // Index of the product descripton string

-  IfFailHrGo(m_piSoftUSBDevice->put_ProductDesc(STRING_IDX_PRODUCT_DESC)); 

-  // Index of the serial number string

-  IfFailHrGo(m_piSoftUSBDevice->put_SerialNumber(STRING_IDX_SERIAL_NO));

-  // Indicate that the device is self-powered

-  IfFailHrGo(m_piSoftUSBDevice->put_SelfPowered(VARIANT_TRUE));

-  // Indicate that the device has power

-  IfFailHrGo(m_piSoftUSBDevice->put_Powered(VARIANT_TRUE));

-

-  // Create the strings associated with the device

-  IfFailHrGo(CreateStrings());

-

-  // Add the device qualifier

-  IfFailHrGo(m_piSoftUSBDevice->put_DeviceQualifier(piDeviceQual));

-

-Exit:

-  RELEASE(piDeviceQual);

-  return hr;

-}

-

-

-HRESULT CLoopbackDevice::ConfigureConfig(ISoftUSBConfiguration* piConfig) {

-  HRESULT hr = S_OK;

-  // config number passed to SetConfig

-  IfFailHrGo(piConfig->put_ConfigurationValue(1));

-  // Index of string descriptor

-  IfFailHrGo(piConfig->put_Configuration((BYTE)m_iConfigString));

-  // Self powered

-  IfFailHrGo(piConfig->put_Attributes(0x40));

-  // Max power in 2mA units: 50 = 100mA

-  IfFailHrGo(piConfig->put_MaxPower(50));

-

-Exit:

-  return hr;

-}

-

-HRESULT CLoopbackDevice::ConfigureINEndpoint() {

-  HRESULT hr = S_OK;

-

-  if (NULL == m_piINEndpoint) {

-    IfFailHrGo(E_UNEXPECTED);

-  }

-

-  // Endpoint #1 IN 

-  IfFailHrGo(m_piINEndpoint->put_EndpointAddress(0x81));

-  // Bulk data endpoint

-  IfFailHrGo(m_piINEndpoint->put_Attributes(0x02));

-  IfFailHrGo(m_piINEndpoint->put_MaxPacketSize(1024));

-  IfFailHrGo(m_piINEndpoint->put_Interval(0));

-  IfFailHrGo(m_piINEndpoint->put_Halted(FALSE));

-  // back pointer to the device

-  IfFailHrGo(m_piINEndpoint->put_USBDevice(reinterpret_cast<SoftUSBDevice*>(m_piSoftUSBDevice)));

-    

-Exit:    

-  return hr;

-}

-

-HRESULT CLoopbackDevice::ConfigureOUTEndpoint() {

-  HRESULT hr = S_OK;

-

-  if (NULL == m_piOUTEndpoint) {

-    IfFailHrGo(E_UNEXPECTED);

-  }

-

-  // Endpoint #2 OUT

-  IfFailHrGo(m_piOUTEndpoint->put_EndpointAddress(0x02));

-  // Bulk data endpoint

-  IfFailHrGo(m_piOUTEndpoint->put_Attributes(0x02));

-  IfFailHrGo(m_piOUTEndpoint->put_MaxPacketSize(1024));

-  IfFailHrGo(m_piOUTEndpoint->put_Interval(0));

-  IfFailHrGo(m_piOUTEndpoint->put_Halted(FALSE));

-  //back pointer to the device

-  IfFailHrGo(m_piOUTEndpoint->put_USBDevice(reinterpret_cast<SoftUSBDevice*>(m_piSoftUSBDevice)));

-    

-Exit:    

-  return hr;

-}

-

-HRESULT CLoopbackDevice::ConfigureInterface(ISoftUSBInterface* piInterface) {

-  HRESULT hr = S_OK;

-

-  IfFailHrGo(piInterface->put_InterfaceNumber(0));

-  IfFailHrGo(piInterface->put_AlternateSetting(0));

-  // Vendor specific class code

-  IfFailHrGo(piInterface->put_InterfaceClass(0xFF));

-  // Vendor specific sub class code

-  IfFailHrGo(piInterface->put_InterfaceSubClass(0xFF));

-  // Vendor specific protcol

-  IfFailHrGo(piInterface->put_InterfaceProtocol(0xFF));

-  //Index for string describing the interface

-  IfFailHrGo(piInterface->put_Interface((BYTE)m_iInterfaceString));

-

-Exit:

-  return hr;

-}

-

-HRESULT CLoopbackDevice::ConfigureDevice() {

-  HRESULT hr = S_OK;

-  ISoftUSBConfiguration* piConfig = NULL;

-  ISoftUSBInterface* piInterface = NULL;

-  ISoftUSBConfigList* piConfigList = NULL;

-  ISoftUSBInterfaceList* piInterfaceList = NULL;

-  ISoftUSBEndpointList* piEndpointList= NULL; 

-  VARIANT varIndex;

-  VariantInit(&varIndex);

-

-  // All members of the collection will be added at the default locations

-  // so set up the index appropriately

-  varIndex.vt = VT_ERROR;

-  varIndex.scode = DISP_E_PARAMNOTFOUND;

-

-  // Create the IN Endpoint

-  hr = CoCreateInstance(CLSID_SoftUSBEndpoint, 

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBEndpoint),     

-                        reinterpret_cast<void**>(&m_piINEndpoint));

-  IfFailHrGo(hr);

-

-  // Setup the IN Endpoint

-  IfFailHrGo(ConfigureINEndpoint());

-

-  // Create the OUT Endpoint

-  hr = CoCreateInstance(CLSID_SoftUSBEndpoint, 

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBEndpoint),     

-                        reinterpret_cast<void**>(&m_piOUTEndpoint));

-  IfFailHrGo(hr);

-

-  // Setup the OUT Endpoint

-  IfFailHrGo(ConfigureOUTEndpoint());

-

-  // Create the device interface

-  hr = CoCreateInstance(CLSID_SoftUSBInterface, 

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBInterface),     

-                        reinterpret_cast<void**>(&piInterface));

-  IfFailHrGo(hr);

-

-  // Setup the device interface

-  IfFailHrGo(ConfigureInterface(piInterface));

-

-  // Add the Endpoints to the endpoint list

-  IfFailHrGo(piInterface->get_Endpoints(&piEndpointList));

-  IfFailHrGo(piEndpointList->Add(reinterpret_cast<SoftUSBEndpoint*>(m_piINEndpoint), varIndex));

-  IfFailHrGo(piEndpointList->Add(reinterpret_cast<SoftUSBEndpoint*>(m_piOUTEndpoint), varIndex));

-

-  // Create the configuration

-  hr = CoCreateInstance(CLSID_SoftUSBConfiguration, 

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBConfiguration),     

-                        reinterpret_cast<void**>(&piConfig));

-  IfFailHrGo(hr);

-

-  // Set the configuration data up

-  IfFailHrGo(ConfigureConfig(piConfig));

-

-  // Add the interface to the interface collection

-  IfFailHrGo(piConfig->get_Interfaces(&piInterfaceList));

-  IfFailHrGo(piInterfaceList->Add(reinterpret_cast<SoftUSBInterface*>(piInterface), varIndex));

-

-  // Add the configuration to the configuration collection

-  IfFailHrGo(m_piSoftUSBDevice->get_Configurations(&piConfigList));

-  IfFailHrGo(piConfigList->Add(reinterpret_cast<SoftUSBConfiguration*>(piConfig), varIndex));

-

-Exit:

-  RELEASE(piConfig);

-  RELEASE(piInterface);

-  RELEASE(piConfigList);

-  RELEASE(piInterfaceList);

-  RELEASE(piEndpointList);

-  return hr;

-}

-

-HRESULT CLoopbackDevice::CreateStrings() {

-  HRESULT hr = S_OK;

-  ISoftUSBStringList* piStringList = NULL;

-  ISoftUSBString* piStringManufacturer = NULL;

-  ISoftUSBString* piStringProductDesc = NULL;

-  ISoftUSBString* piStringSerialNo = NULL;

-  ISoftUSBString* piStringConfig = NULL;

-  ISoftUSBString* piStringEndpoint = NULL;

-  BSTR bstrManufacturer = ::SysAllocString(L"Google, Inc");

-  BSTR bstrProductDesc = ::SysAllocString(L"USB Emulating Device");

-  BSTR bstrSerialNo = ::SysAllocString(L"123456789ABCDEF");

-  BSTR bstrConfig = ::SysAllocString(L"Configuration with a single interface");

-  BSTR bstrEndpoint = ::SysAllocString(L"Interface with bulk IN endpoint and bulk OUT endpoint");

-  VARIANT varIndex;

-  VariantInit(&varIndex);

-

-  // Check that all BSTR allocations succeeded

-  IfFalseHrGo(0 != ::SysStringLen(bstrManufacturer), E_OUTOFMEMORY);

-  IfFalseHrGo(0 != ::SysStringLen(bstrProductDesc), E_OUTOFMEMORY);

-  IfFalseHrGo(0 != ::SysStringLen(bstrSerialNo), E_OUTOFMEMORY);

-  IfFalseHrGo(0 != ::SysStringLen(bstrConfig), E_OUTOFMEMORY);

-  IfFalseHrGo(0 != ::SysStringLen(bstrEndpoint), E_OUTOFMEMORY);

-

-  //Set up the varaint used as the index

-  varIndex.vt = VT_I4;

-  varIndex.lVal = STRING_IDX_MANUFACTURER;

-

-  //Create and initialize the string descriptors. Also create a string 

-  //descriptor index for each. This index is used both to set the string's

-  //descriptors position in the m_piSoftUSBDevice.Strings and is the index value 

-  //the GetDescriptors request from the host. Note that we don't use 

-  //string descriptor index zero because that is a reserved value for a 

-  //device's language ID descriptor.

-

-  //Get the string list from the device

-  hr = m_piSoftUSBDevice->get_Strings(&piStringList);

-  IfFailHrGo(hr);

-

-  hr = CoCreateInstance(CLSID_SoftUSBString,

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBString),     

-                        reinterpret_cast<void**>(&piStringManufacturer));

-  IfFailHrGo(hr);

-

-  IfFailHrGo(piStringManufacturer->put_Value(bstrManufacturer));

-  IfFailHrGo(piStringList->Add(reinterpret_cast<SoftUSBString*>(piStringManufacturer), varIndex));

-    

-  hr = CoCreateInstance(CLSID_SoftUSBString,

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBString),     

-                        reinterpret_cast<void**>(&piStringProductDesc));

-

-  IfFailHrGo(hr);

-  IfFailHrGo(piStringProductDesc->put_Value(bstrProductDesc));

-  varIndex.lVal = STRING_IDX_PRODUCT_DESC;

-  IfFailHrGo(piStringList->Add(reinterpret_cast<SoftUSBString*>(piStringProductDesc), varIndex));

-

-  hr = CoCreateInstance(CLSID_SoftUSBString,

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBString),     

-                        reinterpret_cast<void**>(&piStringSerialNo));

-  IfFailHrGo(hr);

-  IfFailHrGo(piStringSerialNo->put_Value(bstrSerialNo));

-  varIndex.lVal = STRING_IDX_SERIAL_NO;

-  IfFailHrGo(piStringList->Add(reinterpret_cast<SoftUSBString*>(piStringSerialNo), varIndex));

-

-  hr = CoCreateInstance(CLSID_SoftUSBString,

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBString),     

-                        reinterpret_cast<void**>(&piStringConfig));

-  IfFailHrGo(hr);

-  IfFailHrGo(piStringConfig->put_Value(bstrConfig));

-  varIndex.lVal = STRING_IDX_CONFIG;

-  m_iConfigString = varIndex.lVal;

-  IfFailHrGo(piStringList->Add(reinterpret_cast<SoftUSBString*>(piStringConfig), varIndex));

-

-  hr = CoCreateInstance(CLSID_SoftUSBString,

-                        NULL,

-                        CLSCTX_INPROC_SERVER,

-                        __uuidof(ISoftUSBString),     

-                        reinterpret_cast<void**>(&piStringEndpoint));

-  IfFailHrGo(hr);

-  IfFailHrGo(piStringEndpoint->put_Value(bstrEndpoint));

-  varIndex.lVal = STRING_IDX_INTERFACE;

-  m_iInterfaceString = varIndex.lVal;

-  IfFailHrGo(piStringList->Add(reinterpret_cast<SoftUSBString*>(piStringEndpoint), varIndex));

-

-Exit:

-  RELEASE(piStringList);

-  RELEASE(piStringManufacturer);

-  RELEASE(piStringProductDesc);

-  RELEASE(piStringSerialNo);

-  RELEASE(piStringConfig);

-  RELEASE(piStringEndpoint);

-  ::SysFreeString(bstrManufacturer);

-  ::SysFreeString(bstrProductDesc);

-  ::SysFreeString(bstrSerialNo);

-  ::SysFreeString(bstrConfig);

-  ::SysFreeString(bstrEndpoint);

-

-  return hr;

-}

-

-HRESULT CLoopbackDevice::ReleaseConnectionPoint() {

-  HRESULT hr = S_OK;

-    

-  if (NULL != m_piConnectionPoint) {

-    m_piConnectionPoint->Unadvise(m_dwConnectionCookie);

-    m_dwConnectionCookie = 0;

-  }

-

-  RELEASE(m_piConnectionPoint);

-

-  return hr;

-}

-

-

-HRESULT CLoopbackDevice::SetupConnectionPoint(IUnknown* punkObject,

-                                              REFIID iidConnectionPoint) {

-  HRESULT hr = S_OK;

-  IConnectionPointContainer* piConnectionPointContainer = NULL;

-  IUnknown* punkSink = NULL;

-

-  //If there is already connection point enabled, disable it

-  if(NULL != m_piConnectionPoint) {

-    IfFailHrGo(ReleaseConnectionPoint());

-  }

-        

-  IfFailHrGo(punkObject->QueryInterface(IID_IConnectionPointContainer,

-                                        reinterpret_cast<void **>(&piConnectionPointContainer)));

-

-  IfFailHrGo(piConnectionPointContainer->FindConnectionPoint(iidConnectionPoint,

-                                                             &m_piConnectionPoint));

-

-  // Get the IUknown of this interface as this is the event sink

-  punkSink = (this)->GetUnknown(); 

-

-  if(NULL == punkSink) {

-    IfFailHrGo(E_UNEXPECTED);

-  }

-

-  IfFailHrGo(m_piConnectionPoint->Advise(punkSink, &m_dwConnectionCookie));

-

-

-Exit:

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::get_DSFDevice(DSFDevice** ppDSFDevice) {

-  HRESULT hr = S_OK;

-  DSFDevice* pDSFDevice = NULL;

-

-  //Validate the the UDB device exists else this is an

-  //internal error

-  if (NULL == m_piSoftUSBDevice) {

-    IfFailHrGo(E_UNEXPECTED);

-  }    

-

-  if (NULL == ppDSFDevice) {

-    IfFailHrGo(E_POINTER);

-  }

-

-  IfFailHrGo(m_piSoftUSBDevice->get_DSFDevice(&pDSFDevice));

-  IfFailHrGo(reinterpret_cast<IDSFDevice *>(pDSFDevice)->QueryInterface(__uuidof(IDispatch), reinterpret_cast<void **>(ppDSFDevice)));

-

-Exit:

-  if (NULL != pDSFDevice)

-    reinterpret_cast<IDSFDevice *>(pDSFDevice)->Release();

-

-  return hr;

-}

-

-

-STDMETHODIMP CLoopbackDevice::DoPolledLoopback(long lTimeInterval) {

-/*

-   Demonstrates how to use the drain OUT queue and queue IN data

-   methods to communicate with the host controller. 

-

-   The code checks to see if there is any data in the OUT, if no 

-   data is present an event is fired to indicate if the function 

-   should exit. If the function should not exit then the function 

-   sleeps for the time interval before re-checking the queue.

-

-   If there is data then the function reads the data and passes the

-   data to the IN queue. This simply provides a loopback mechanism

-   to the host controller.

-*/

-  HRESULT hr = S_OK;

-  BOOL fKeepLooping = TRUE;

-  // Number of items currently in the queue

-  ULONG ulNoOfQueuedItems = 0;

-  // Only going to read one transfer at a time

-  ULONG ulTransfers = 1;

-  SOFTUSB_OUT_TRANSFER* pOUTTransfer = NULL;

-  // Copied the message status

-  BYTE bStatus = 0;

-  // Copied the message data

-  BYTE* pDataBuffer = NULL;

-  // Holds the size of the data buffer

-  ULONG cbDataBuffer      = 0;

-  VARIANT_BOOL fvarContinue = VARIANT_TRUE;

-

-  if (NULL == m_piINEndpoint || NULL == m_piOUTEndpoint) {

-    IfFailHrGo(E_UNEXPECTED);

-  }

-

-  while (fKeepLooping) {

-    // Reset the number of queued items

-    ulNoOfQueuedItems = 0;

-        

-    // Check to see if there is any data in the out queue

-    IfFailHrGo(m_piOUTEndpoint->DrainOUTQueue(0, &ulNoOfQueuedItems, NULL));

-

-    if (0 == ulNoOfQueuedItems) {

-      // There is no data in the list so we need to check

-      // If we should continue to loop

-      // Fire Event to check if more processing is required

-      IfFailHrGo(Fire_ContinueToPoll(&fvarContinue));

-

-      // Check to see if the return value is VARIANT_FALSE

-      if (VARIANT_FALSE == fvarContinue)

-        fKeepLooping = FALSE;

-            

-      if (fKeepLooping)

-        ::Sleep(lTimeInterval);

-    } else {

-      // There is data to read, loop until we have moved all 

-      // the data from the OUT queue to the IN queue moving

-      // one data item at a time

-      do {

-        // Get the OUT data

-        IfFailHrGo(m_piOUTEndpoint->DrainOUTQueue(ulTransfers, 

-                                                  &ulNoOfQueuedItems, 

-                                                  &pOUTTransfer));

-

-        // Setup the IN data

-        bStatus= pOUTTransfer->bStatus;

-        cbDataBuffer = pOUTTransfer->cbData;

-        pDataBuffer =&pOUTTransfer->Data[0];

-                

-        // Send the data to the out queue

-        IfFailHrGo(m_piINEndpoint->QueueINData(pDataBuffer,

-                                               cbDataBuffer,

-                                               bStatus,

-                                               SOFTUSB_FOREVER));

-

-        // Free the memory used by pOUTTransfer   

-        m_piOUTEndpoint->FreeOUTQueue(pOUTTransfer);

-        pOUTTransfer = NULL;

-

-        // Force a context switch 

-        ::Sleep(1);

-      } while (0 != ulNoOfQueuedItems);

-    }

-  }

-

-Exit:

-  // If one of the calls failed pOUTTransfer will be NON-NULL 

-  // And needs to be freed

-  if (NULL != pOUTTransfer) {

-    // Free the memory used by pOUTTransfer   

-    m_piOUTEndpoint->FreeOUTQueue(pOUTTransfer);

-    pOUTTransfer = NULL;

-  }

-

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::StartEventProcessing() {

-/*

-   Demonstrates how to setup event sinks so that the 

-   event mechanism can be used to control data flow to and

-   from the USB controller. In this example an event sink

-   is installed on the OUT USB endpoint, when the controller

-   has data to send to the device the OnWriteTransfer event

-   will fire, this will occur on an arbitrary thread. The 

-   device then simply copies this data and passes it the

-   IN queue of the IN Endpoint.

-*/

-  HRESULT               hr                = S_OK;

-  BOOL                  fKeepLooping      = TRUE;

-  VARIANT_BOOL          fvarContinue      = VARIANT_TRUE;

-

-  // Set up event sink on the OUT endpoint

-  IfFailHrGo(SetupConnectionPoint(m_piOUTEndpoint, __uuidof(ISoftUSBEndpointEvents)));

-

-  // Loop waiting for Events to be fired

-  while (TRUE == fKeepLooping) {

-    // Context switch to allow other threads to process

-    ::Sleep(1);

-

-    // Fire Event to check if the caller want to continue processing

-    IfFailHrGo(Fire_ContinueEventProcessing(&fvarContinue));

-

-    // Check to see if the return value is VARIANT_FALSE

-    if (VARIANT_FALSE == fvarContinue)

-      fKeepLooping = FALSE;

-  }

-

-  // Remove the event sink from the OUT endpoint

-  IfFailHrGo(ReleaseConnectionPoint());

-    

-Exit:

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::StartAsyncEventProcessing() {

-/*

-   Demonstrates how to setup event sinks so that the event mechanism can

-   be used to control data flow to and from the USB controller. In this

-   example an event sink is installed on the OUT USB endpoint, when the

-   controller has data to send to the device the OnWriteTransfer event

-   will fire, this will occur on an arbitrary thread. The device then

-   simply copies this data and passes it the IN queue of the IN

-   Endpoint. Control returns to the caller and event processing

-   continues in an arbitrary thread. To terminate event processing call

-   StopAsyncEventProcessing.

-*/

-  HRESULT hr = S_OK;

-

-  // Set up event sink on the OUT endpoint

-  IfFailHrGo(SetupConnectionPoint(m_piOUTEndpoint, __uuidof(ISoftUSBEndpointEvents)));

-

-Exit:

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::StopAsyncEventProcessing() {

-  HRESULT hr = S_OK;

-  // Remove the event sink on the OUT endpoint

-  IfFailHrGo(ReleaseConnectionPoint());

-

-Exit:

-  return hr;

-}

-

-

-

-STDMETHODIMP CLoopbackDevice::AreKeystrokesWaiting(

-    VARIANT_BOOL* pfvarKeyWaiting) {

-/*

-   Implements IDeviceEmulator::AreKeystrokesWaiting. It calls the low level 

-   IO function _kbhit to see if the keyboard has been struck. If the Keyboard

-   has been hit the function return VARIANT_TRUE otherwise it returns VARIANT_FALSE

-*/

-  HRESULT hr = S_OK;

-  int iKeyHit = 0;

-

-  if (NULL == pfvarKeyWaiting) {

-    IfFailHrGo(E_POINTER);

-  }

-    

-  *pfvarKeyWaiting = VARIANT_FALSE;

-

-  iKeyHit = _kbhit();

-

-  if (0 != iKeyHit)

-    *pfvarKeyWaiting = VARIANT_TRUE;

-

-Exit:

-  return hr;

-}

-

-//ISoftUSBEndpointEvents

-

-STDMETHODIMP CLoopbackDevice::OnSetupTransfer(BYTE DataToggle,

-                                              BYTE* pbDataBuffer,

-                                              ULONG cbDataBuffer,

-                                              BYTE *pbStatus) {

-  HRESULT hr = E_NOTIMPL;

-  UNREFERENCED_PARAMETER(DataToggle);

-  UNREFERENCED_PARAMETER(pbDataBuffer);

-  UNREFERENCED_PARAMETER(cbDataBuffer);

-  UNREFERENCED_PARAMETER(pbStatus);

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::OnWriteTransfer(BYTE DataToggle,

-                                              BYTE* pbDataBuffer,

-                                              ULONG cbDataBuffer,

-                                              BYTE * pbStatus) {

-    

-  HRESULT hr = S_OK;

-  BYTE bINStatus = USB_ACK;

-  UNREFERENCED_PARAMETER(DataToggle);

-

-  // Check that the IN endpoint is valid

-  if (NULL == m_piINEndpoint) {

-    IfFailHrGo(E_UNEXPECTED);

-  }

-

-  // Send the data to the IN Endpoint

-  IfFailHrGo(m_piINEndpoint->QueueINData(pbDataBuffer,

-                                         cbDataBuffer,

-                                         bINStatus,

-                                         SOFTUSB_FOREVER));

-

-  // ACK the status as the data was successfully sent to the IN endpoint

-  *pbStatus = USB_ACK;

-

-Exit:

-  if (FAILED(hr))

-    *pbStatus = USB_STALL;

-

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::OnReadTransfer(BYTE DataToggle,

-                                             BYTE* pbDataBuffer,

-                                             ULONG cbDataBuffer,

-                                             ULONG* cbDataWritten,

-                                             BYTE* pbStatus) {

-  HRESULT hr = E_NOTIMPL;

-  UNREFERENCED_PARAMETER(DataToggle);

-  UNREFERENCED_PARAMETER(pbDataBuffer);

-  UNREFERENCED_PARAMETER(cbDataBuffer);

-  UNREFERENCED_PARAMETER(cbDataWritten);

-  UNREFERENCED_PARAMETER(pbStatus);

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::OnDeviceRequest(USBSETUPREQUEST *pSetupRequest,

-                                              ULONG_PTR* RequestHandle,

-                                              BYTE* pbHostData,

-                                              ULONG cbHostData,

-                                              BYTE** ppbResponseData,

-                                              ULONG* pcbResponseData,

-                                              BYTE* pbSetupStatus) {

-  HRESULT hr = E_NOTIMPL;

-  UNREFERENCED_PARAMETER(pSetupRequest);

-  UNREFERENCED_PARAMETER(RequestHandle);

-  UNREFERENCED_PARAMETER(pbHostData);

-  UNREFERENCED_PARAMETER(cbHostData);

-  UNREFERENCED_PARAMETER(ppbResponseData);

-  UNREFERENCED_PARAMETER(pcbResponseData);

-  UNREFERENCED_PARAMETER(pbSetupStatus);

-  return hr;

-}

-

-STDMETHODIMP CLoopbackDevice::OnDeviceRequestComplete(

-    ULONG_PTR RequestHandle,

-    BYTE* pbFinalRequestStatus) {

-  HRESULT hr = E_NOTIMPL;

-  UNREFERENCED_PARAMETER(RequestHandle);

-  UNREFERENCED_PARAMETER(pbFinalRequestStatus);

-  return hr;

-}

diff --git a/host/windows/usb/test/device_emulator/LoopbackDevice.h b/host/windows/usb/test/device_emulator/LoopbackDevice.h
deleted file mode 100644
index 0df3fba..0000000
--- a/host/windows/usb/test/device_emulator/LoopbackDevice.h
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file consists of definition of the class CLoopbackDevice

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-

-#pragma once

-#include "resource.h"

-

-#include "DeviceEmulator.h"

-#include "LoopbackDeviceEvents.h"

-

-

-//Release and Add ref macros

-#define ADDREF(punk) { \

-  if ((punk) != NULL) { \

-    (punk)->AddRef(); \

-  } \

-}

-

-

-#define RELEASE(punk) { \

-  if ((punk) != NULL) { \

-    IUnknown *_punkXxx = (punk); \

-    (punk) = NULL; \

-    _punkXxx->Release(); \

-  } \

-}

-

-//HR check

-#define IfFailHrGo(EXPR) { hr = (EXPR); if(FAILED(hr)) goto Exit; }

-#define IfFalseHrGo(EXPR, HR) { if(!(EXPR)) { hr = (HR); goto Exit; } }

-

-#pragma warning(disable: 4995) //Pragma deprecated

-

-class ATL_NO_VTABLE CLoopbackDevice : 

-    public CComObjectRootEx<CComSingleThreadModel>,

-    public CComCoClass<CLoopbackDevice, &CLSID_LoopbackDevice>,

-    public IConnectionPointContainerImpl<CLoopbackDevice>,

-    public CProxy_ILoopbackDeviceEvents<CLoopbackDevice>, 

-    public ISoftUSBEndpointEvents,

-    public IDispatchImpl<ILoopbackDevice, &IID_ILoopbackDevice,

-                         &LIBID_DeviceEmulatorLib,

-                         /*wMajor =*/ 1, /*wMinor =*/ 0> {

- public:

-    CLoopbackDevice();

-    virtual ~CLoopbackDevice();

-DECLARE_REGISTRY_RESOURCEID(IDR_LOOPBACKDEVICE)

-

-

-BEGIN_COM_MAP(CLoopbackDevice)

-    COM_INTERFACE_ENTRY(ILoopbackDevice)

-    COM_INTERFACE_ENTRY(IDispatch)

-    COM_INTERFACE_ENTRY(ISoftUSBEndpointEvents)

-    COM_INTERFACE_ENTRY(IConnectionPointContainer)

-END_COM_MAP()

-

-BEGIN_CONNECTION_POINT_MAP(CLoopbackDevice)

-    CONNECTION_POINT_ENTRY(__uuidof(ILoopbackDeviceEvents))

-END_CONNECTION_POINT_MAP()

-

-

-  DECLARE_PROTECT_FINAL_CONSTRUCT()

-

-  HRESULT FinalConstruct();

-    

-  void FinalRelease();

-

- private:

-  void InitMemberVariables();

-

-   HRESULT CreateUSBDevice();

-   HRESULT CreateStrings();

-   HRESULT ConfigureDevice();

-   HRESULT ConfigureOUTEndpoint();

-   HRESULT ConfigureINEndpoint();

-   HRESULT ConfigureInterface(ISoftUSBInterface* piInterface);

-   HRESULT ConfigureConfig(ISoftUSBConfiguration* piConfig);

-

-   HRESULT SetupConnectionPoint(IUnknown* punkObject,

-                                REFIID iidConnectionPoint);

-   HRESULT ReleaseConnectionPoint();

-

-   // Underlying SoftUSBDevice object

-   ISoftUSBDevice          *m_piSoftUSBDevice;

-   // IN Endpoint

-   ISoftUSBEndpoint        *m_piINEndpoint;

-   // OUT Endpoint

-   ISoftUSBEndpoint        *m_piOUTEndpoint;

-   // Connection point interface

-   IConnectionPoint        *m_piConnectionPoint;

-   // Connection point cookie.

-   DWORD                    m_dwConnectionCookie;

-   // Index of interface identifier string

-   int                      m_iInterfaceString;

-   // Index of config identifier string

-   int                      m_iConfigString;

-     

- public:

-  //ILoopbackDevice

-  STDMETHOD(get_DSFDevice)(DSFDevice** ppDSFDevice);

-  STDMETHOD(DoPolledLoopback)(long lTimeInterval);

-  STDMETHOD(StartEventProcessing)();

-  STDMETHOD(StartAsyncEventProcessing)();

-  STDMETHOD(StopAsyncEventProcessing)();

-  STDMETHOD(AreKeystrokesWaiting)(VARIANT_BOOL* pfvarKeyWaiting);

-

-  //ISoftUSBEndpointEvents

-  STDMETHOD(OnSetupTransfer)(BYTE DataToggle, BYTE* pbDataBuffer,

-                             ULONG cbDataBuffer, BYTE* pbStatus);

-

-  STDMETHOD(OnWriteTransfer)(BYTE DataToggle, BYTE* pbDataBuffer,

-                             ULONG cbDataBuffer, BYTE* pbStatus);

-

-  STDMETHOD(OnReadTransfer)(BYTE DataToggle, BYTE* pbDataBuffer,

-                            ULONG cbDataBuffer,ULONG* cbDataWritten,

-                            BYTE* pbStatus);       

-

-  STDMETHOD(OnDeviceRequest)(USBSETUPREQUEST* pSetupRequest,

-                             ULONG_PTR* RequestHandle, 

-                             BYTE* pbHostData, ULONG cbHostData,

-                             BYTE** ppbResponseData,

-                             ULONG* pcbResponseData,BYTE* pbSetupStatus);

-

-  STDMETHOD(OnDeviceRequestComplete)(ULONG_PTR RequestHandle,

-                                     BYTE* pbFinalRequestStatus);

-};

-

-OBJECT_ENTRY_AUTO(__uuidof(LoopbackDevice), CLoopbackDevice)

diff --git a/host/windows/usb/test/device_emulator/LoopbackDevice.rgs b/host/windows/usb/test/device_emulator/LoopbackDevice.rgs
deleted file mode 100644
index 422f654..0000000
--- a/host/windows/usb/test/device_emulator/LoopbackDevice.rgs
+++ /dev/null
@@ -1,27 +0,0 @@
-HKCR

-{

-    DeviceEmulator.LoopbackDevice.1 = s 'LoopbackDevice Class'

-    {

-        CLSID = s '{9A0BD4A6-E346-4668-A89C-ACA546212CD4}'

-    }

-    DeviceEmulator.LoopbackDevice = s 'LoopbackDevice Class'

-    {

-        CLSID = s '{9A0BD4A6-E346-4668-A89C-ACA546212CD4}'

-        CurVer = s 'DeviceEmulator.LoopbackDevice.1'

-    }

-    NoRemove CLSID

-    {

-        ForceRemove {9A0BD4A6-E346-4668-A89C-ACA546212CD4} = s 'LoopbackDevice Class'

-        {

-            ProgID = s 'DeviceEmulator.LoopbackDevice.1'

-            VersionIndependentProgID = s 'DeviceEmulator.LoopbackDevice'

-            ForceRemove 'Programmable'

-            InprocServer32 = s '%MODULE%'

-            {

-                val ThreadingModel = s 'Apartment'

-            }

-            'TypeLib' = s '{0C206596-5CC2-4d16-898D-4D1699BB6282}'

-        }

-    }

-}

-

diff --git a/host/windows/usb/test/device_emulator/LoopbackDeviceEvents.h b/host/windows/usb/test/device_emulator/LoopbackDeviceEvents.h
deleted file mode 100644
index 9bde9e0..0000000
--- a/host/windows/usb/test/device_emulator/LoopbackDeviceEvents.h
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file consists of definition of the template class which implements the

-  event interface ILoopbackDeviceEvents.

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-

-template<class T>

-class CProxy_ILoopbackDeviceEvents :

-    public IConnectionPointImpl<T, &__uuidof(ILoopbackDeviceEvents)> {

- public:

-  HRESULT _stdcall Fire_ContinueToPoll(VARIANT_BOOL *pfvarContinue) {

-    HRESULT hr = S_OK;

-    T* pThis = static_cast<T *>(this);

-    int cConnections = m_vec.GetSize();

-

-    for (int iConnection = 0; iConnection < cConnections; iConnection++) {

-      pThis->Lock();

-      CComPtr<IUnknown> punkConnection = m_vec.GetAt(iConnection);

-      pThis->Unlock();

-

-      IDispatch * pConnection = static_cast<IDispatch *>(punkConnection.p);

-

-      if (pConnection) {

-        CComVariant varResult;

-

-        DISPPARAMS params = { NULL, NULL, 0, 0 };

-        hr = pConnection->Invoke(1, IID_NULL, LOCALE_USER_DEFAULT,

-                                 DISPATCH_METHOD, &params, &varResult,

-                                 NULL, NULL);

-

-        //Set the return parameter

-        *pfvarContinue  = varResult.boolVal;

-      }

-    }

-    return hr;

-  }

-

-  HRESULT _stdcall Fire_ContinueEventProcessing(VARIANT_BOOL *pfvarContinue) {

-    HRESULT hr = S_OK;

-    T * pThis = static_cast<T *>(this);

-    int cConnections = m_vec.GetSize();

-

-    for (int iConnection = 0; iConnection < cConnections; iConnection++) {

-      pThis->Lock();

-      CComPtr<IUnknown> punkConnection = m_vec.GetAt(iConnection);

-      pThis->Unlock();

-

-      IDispatch * pConnection = static_cast<IDispatch *>(punkConnection.p);

-

-      if (pConnection) {

-        CComVariant varResult;

-

-        DISPPARAMS params = { NULL, NULL, 0, 0 };

-        hr = pConnection->Invoke(2, IID_NULL, LOCALE_USER_DEFAULT,

-                                 DISPATCH_METHOD, &params, &varResult,

-                                 NULL, NULL);

-

-        //Set the return parameter

-        *pfvarContinue  = varResult.boolVal;

-      }

-    }

-    return hr;

-  }

-};

-

diff --git a/host/windows/usb/test/device_emulator/device_emulator.sln b/host/windows/usb/test/device_emulator/device_emulator.sln
deleted file mode 100644
index 3fff7ca..0000000
--- a/host/windows/usb/test/device_emulator/device_emulator.sln
+++ /dev/null
@@ -1,21 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 8.00

-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "device_emulator", "device_emulator.vcproj", "{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}"

-	ProjectSection(ProjectDependencies) = postProject

-	EndProjectSection

-EndProject

-Global

-	GlobalSection(SolutionConfiguration) = preSolution

-		Debug = Debug

-		Release = Release

-	EndGlobalSection

-	GlobalSection(ProjectConfiguration) = postSolution

-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Debug.ActiveCfg = Debug|Win32

-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Debug.Build.0 = Debug|Win32

-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Release.ActiveCfg = Release|Win32

-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Release.Build.0 = Release|Win32

-	EndGlobalSection

-	GlobalSection(ExtensibilityGlobals) = postSolution

-	EndGlobalSection

-	GlobalSection(ExtensibilityAddIns) = postSolution

-	EndGlobalSection

-EndGlobal

diff --git a/host/windows/usb/test/device_emulator/device_emulator.vcproj b/host/windows/usb/test/device_emulator/device_emulator.vcproj
deleted file mode 100644
index 34a66c3..0000000
--- a/host/windows/usb/test/device_emulator/device_emulator.vcproj
+++ /dev/null
@@ -1,144 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>

-<VisualStudioProject

-	ProjectType="Visual C++"

-	Version="7.10"

-	Name="device_emulator"

-	ProjectGUID="{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}"

-	Keyword="MakeFileProj">

-	<Platforms>

-		<Platform

-			Name="Win32"/>

-	</Platforms>

-	<Configurations>

-		<Configuration

-			Name="Debug|Win32"

-			OutputDirectory="Debug"

-			IntermediateDirectory="Debug"

-			ConfigurationType="0">

-			<Tool

-				Name="VCNMakeTool"

-				BuildCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ chk WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -beEIFZ

-"

-				ReBuildCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ chk WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -cbeEIFZ

-"

-				CleanCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ chk WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -c0

-"/>

-		</Configuration>

-		<Configuration

-			Name="Release|Win32"

-			OutputDirectory="Release"

-			IntermediateDirectory="Release"

-			ConfigurationType="0">

-			<Tool

-				Name="VCNMakeTool"

-				BuildCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ free WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -beEIFZ"

-				ReBuildCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ free WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -cbeEIFZ"

-				CleanCommandLine="call c:\winddk\6000\bin\setenv.bat c:\winddk\6000\ free WXP

-set PROJECTDIR=$(ProjectDir)

-set DRIVE=%PROJECTDIR:~0,2%

-%DRIVE%

-cd %PROJECTDIR%

-build -c0

-"

-				Output="device_emulator.dll"/>

-		</Configuration>

-	</Configurations>

-	<References>

-	</References>

-	<Files>

-		<Filter

-			Name="Source Files"

-			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"

-			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">

-			<File

-				RelativePath=".\LoopbackDevice.cpp">

-			</File>

-			<File

-				RelativePath=".\DeviceEmulator.cpp">

-			</File>

-			<File

-				RelativePath=".\DeviceEmulator.idl">

-			</File>

-			<File

-				RelativePath=".\stdafx.cpp">

-			</File>

-		</Filter>

-		<Filter

-			Name="Header Files"

-			Filter="h;hpp;hxx;hm;inl;inc;xsd"

-			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">

-			<File

-				RelativePath=".\LoopbackDevice.h">

-			</File>

-			<File

-				RelativePath=".\LoopbackDeviceEvents.h">

-			</File>

-			<File

-				RelativePath=".\resource.h">

-			</File>

-			<File

-				RelativePath=".\stdafx.h">

-			</File>

-			<Filter

-				Name="common"

-				Filter="">

-				<File

-					RelativePath="..\..\common\android_usb_common_defines.h">

-				</File>

-			</Filter>

-		</Filter>

-		<Filter

-			Name="Resource Files"

-			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"

-			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">

-			<File

-				RelativePath=".\LoopbackDevice.rgs">

-			</File>

-			<File

-				RelativePath=".\DeviceEmulator.rc">

-			</File>

-			<File

-				RelativePath=".\DeviceEmulator.rgs">

-			</File>

-		</Filter>

-		<File

-			RelativePath=".\makefile">

-		</File>

-		<File

-			RelativePath=".\RunDeviceLoopbackSample.wsf">

-		</File>

-		<File

-			RelativePath=".\DeviceEmulator.def">

-		</File>

-		<File

-			RelativePath=".\sources">

-		</File>

-	</Files>

-	<Globals>

-	</Globals>

-</VisualStudioProject>

diff --git a/host/windows/usb/test/device_emulator/makefile b/host/windows/usb/test/device_emulator/makefile
deleted file mode 100644
index 66f1c8e..0000000
--- a/host/windows/usb/test/device_emulator/makefile
+++ /dev/null
@@ -1,8 +0,0 @@
-#

-# DO NOT EDIT THIS FILE!!!  Edit .\sources. if you want to add a new source

-# file to this component.  This file merely indirects to the real make file

-# that is shared by all the driver components of the Windows NT DDK

-#

-

-!INCLUDE $(NTMAKEENV)\makefile.def

-

diff --git a/host/windows/usb/test/device_emulator/resource.h b/host/windows/usb/test/device_emulator/resource.h
deleted file mode 100644
index 6e5e435..0000000
--- a/host/windows/usb/test/device_emulator/resource.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/** \file

-  This file defines resources used by Emulator.rc

-  This project has been created from DDK's SoftUSBLoopback sample project

-  that is located at $(DDK_PATH)\src\Test\DSF\USB\SoftUSBLoopback

-*/

-

-#define IDS_PROJNAME                    100

-#define IDR_DEVICEEMULATOR              101

-#define IDR_LOOPBACKDEVICE              102

-

-// Next default values for new objects

-// 

-#ifdef APSTUDIO_INVOKED

-#ifndef APSTUDIO_READONLY_SYMBOLS

-#define _APS_NEXT_RESOURCE_VALUE        201

-#define _APS_NEXT_COMMAND_VALUE         32768

-#define _APS_NEXT_CONTROL_VALUE         201

-#define _APS_NEXT_SYMED_VALUE           103

-#endif

-#endif

-

diff --git a/host/windows/usb/test/device_emulator/sources b/host/windows/usb/test/device_emulator/sources
deleted file mode 100644
index b65a1d8..0000000
--- a/host/windows/usb/test/device_emulator/sources
+++ /dev/null
@@ -1,56 +0,0 @@
-TARGETNAME= DeviceEmulator

-TARGETTYPE=DYNLINK

-

-DLLENTRY=_DllMainCRTStartup

-

-DLLDEF=DeviceEmulator.def

-

-USE_NATIVE_EH=ASYNC

-

-MUI = 0

-MUI_COMMENT=TEST_TOOL, Device Simulation Framework

-

-PRECOMPILED_CXX = 1

-

-MSC_WARNING_LEVEL=/W4 /WX

-

-USE_ATL = 1

-ATL_VER = 70

-

-USE_MSVCRT = 1

-USE_OBJECT_ROOT=1

-

-!IF "$(DDKBUILDENV)"=="chk"
-TARGETPATH=..\..\build\Debug
-!ELSE
-TARGETPATH=..\..\build\Release
-!ENDIF
-

-

-C_DEFINES = $(C_DEFINES) -DDSF_USER_MODE -DUNICODE

-

-PRECOMPILED_CXX=1

-

-TARGETLIBS= \

-           $(SDK_LIB_PATH)\kernel32.lib \

-           $(SDK_LIB_PATH)\user32.lib \

-           $(SDK_LIB_PATH)\advapi32.lib \

-           $(SDK_LIB_PATH)\ole32.lib \

-           $(SDK_LIB_PATH)\oleaut32.lib \

-           $(SDK_LIB_PATH)\uuid.lib \

-           $(SDK_LIB_PATH)\shlwapi.lib \

-           $(DDK_LIB_PATH)\SoftUSBIf.lib \

-

-

-INCLUDES=\

-    ..\..\api; \

-    ..\..\common; \

-    $(DDK_LIB_DEST)\$(TARGET_DIRECTORY); \

-    $(DDK_INC_PATH); \

-    

-SOURCES= \

-    DeviceEmulator.idl \

-    LoopbackDevice.cpp \

-    DeviceEmulator.cpp \

-    DeviceEmulator.rc \

-

diff --git a/host/windows/usb/test/device_emulator/stdafx.cpp b/host/windows/usb/test/device_emulator/stdafx.cpp
deleted file mode 100644
index 5e452ed..0000000
--- a/host/windows/usb/test/device_emulator/stdafx.cpp
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include "stdafx.h"

-

diff --git a/host/windows/usb/test/device_emulator/stdafx.h b/host/windows/usb/test/device_emulator/stdafx.h
deleted file mode 100644
index 8651cd0..0000000
--- a/host/windows/usb/test/device_emulator/stdafx.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#pragma once

-

-#ifndef STRICT

-#define STRICT

-#endif

-

-// Modify the following defines if you have to target a platform prior to the ones specified below.

-// Refer to MSDN for the latest info on corresponding values for different platforms.

-#ifndef WINVER              // Allow use of features specific to Windows 95 and Windows NT 4 or later.

-#define WINVER 0x0500       // Change this to the appropriate value to target Windows 98 and Windows 2000 or later.

-#endif

-

-#ifndef _WIN32_WINNT        // Allow use of features specific to Windows NT 4 or later.

-#define _WIN32_WINNT 0x0500 // Change this to the appropriate value to target Windows 2000 or later.

-#endif                      

-

-#ifndef _WIN32_WINDOWS      // Allow use of features specific to Windows 98 or later.

-#define _WIN32_WINDOWS 0x0500 // Change this to the appropriate value to target Windows Me or later.

-#endif

-

-#ifndef _WIN32_IE           // Allow use of features specific to IE 4.0 or later.

-#define _WIN32_IE 0x0501    // Change this to the appropriate value to target IE 5.0 or later.

-#endif

-

-#define _ATL_APARTMENT_THREADED

-#define _ATL_NO_AUTOMATIC_NAMESPACE

-

-#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS  // some CString constructors will be explicit

-

-// turns off ATL's hiding of some common and often safely ignored warning messages

-#define _ATL_ALL_WARNINGS

-

-

-#include "resource.h"

-#include <atlbase.h>

-#include <atlcom.h>

-

-using namespace ATL;

-

diff --git a/host/windows/usb/usb_windows.sln b/host/windows/usb/usb_windows.sln
deleted file mode 100644
index 7dfff9b..0000000
--- a/host/windows/usb/usb_windows.sln
+++ /dev/null
@@ -1,53 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 8.00
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "android_usb", "driver\android_usb.vcproj", "{D980BE56-A7AB-4E05-919B-677FB7716307}"
-	ProjectSection(ProjectDependencies) = postProject
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AdbWinApi", "api\AdbWinApi.vcproj", "{C0A471E9-6892-4270-96DE-DB5F8D526FB1}"
-	ProjectSection(ProjectDependencies) = postProject
-		{D980BE56-A7AB-4E05-919B-677FB7716307} = {D980BE56-A7AB-4E05-919B-677FB7716307}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "device_emulator", "test\device_emulator\device_emulator.vcproj", "{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}"
-	ProjectSection(ProjectDependencies) = postProject
-		{D980BE56-A7AB-4E05-919B-677FB7716307} = {D980BE56-A7AB-4E05-919B-677FB7716307}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "android_usb_test", "test\android_usb_test\android_usb_test.vcproj", "{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}"
-	ProjectSection(ProjectDependencies) = postProject
-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59} = {EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}
-		{D980BE56-A7AB-4E05-919B-677FB7716307} = {D980BE56-A7AB-4E05-919B-677FB7716307}
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1} = {C0A471E9-6892-4270-96DE-DB5F8D526FB1}
-	EndProjectSection
-EndProject
-Global
-	GlobalSection(SolutionConfiguration) = preSolution
-		Debug = Debug
-		Release = Release
-	EndGlobalSection
-	GlobalSection(ProjectConfiguration) = postSolution
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug.ActiveCfg = Debug|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Debug.Build.0 = Debug|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release.ActiveCfg = Release|Win32
-		{D980BE56-A7AB-4E05-919B-677FB7716307}.Release.Build.0 = Release|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.ActiveCfg = Debug|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Debug.Build.0 = Debug|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.ActiveCfg = Release|Win32
-		{C0A471E9-6892-4270-96DE-DB5F8D526FB1}.Release.Build.0 = Release|Win32
-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Debug.ActiveCfg = Debug|Win32
-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Debug.Build.0 = Debug|Win32
-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Release.ActiveCfg = Release|Win32
-		{EAB61831-9DDA-40AA-A5EF-2D9E8F9A5C59}.Release.Build.0 = Release|Win32
-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Debug.ActiveCfg = Debug|Win32
-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Debug.Build.0 = Debug|Win32
-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Release.ActiveCfg = Release|Win32
-		{9C6DBEED-9D2C-4FD8-B83D-88254035F78B}.Release.Build.0 = Release|Win32
-	EndGlobalSection
-	GlobalSection(SolutionItems) = postSolution
-		usb_windows.c = usb_windows.c
-	EndGlobalSection
-	GlobalSection(ExtensibilityGlobals) = postSolution
-	EndGlobalSection
-	GlobalSection(ExtensibilityAddIns) = postSolution
-	EndGlobalSection
-EndGlobal
diff --git a/ide/eclipse/.classpath b/ide/eclipse/.classpath
deleted file mode 100644
index a871dc0..0000000
--- a/ide/eclipse/.classpath
+++ /dev/null
@@ -1,115 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="packages/apps/AlarmClock/src"/>
-	<classpathentry kind="src" path="packages/apps/Browser/src"/>
-	<classpathentry kind="src" path="packages/apps/Calendar/src"/>
-	<classpathentry kind="src" path="packages/apps/Calculator/src"/>
-	<classpathentry kind="src" path="packages/apps/Camera/src"/>
-	<classpathentry kind="src" path="packages/apps/Contacts/src"/>
-	<classpathentry kind="src" path="packages/apps/Email/src"/>
-	<classpathentry kind="src" path="packages/apps/GoogleSearch/src"/>
-	<classpathentry kind="src" path="packages/apps/HTMLViewer/src"/>
-	<classpathentry kind="src" path="packages/apps/IM/src"/>
-	<classpathentry kind="src" path="packages/apps/IM/plugin"/>
-	<classpathentry kind="src" path="packages/apps/Launcher/src"/>
-	<classpathentry kind="src" path="packages/apps/Music/src"/>
-	<classpathentry kind="src" path="packages/apps/Mms/src"/>
-	<classpathentry kind="src" path="packages/apps/PackageInstaller/src"/>
-	<classpathentry kind="src" path="packages/apps/Phone/src"/>
-	<classpathentry kind="src" path="packages/apps/Settings/src"/>
-	<classpathentry kind="src" path="packages/apps/SoundRecorder/src"/>
-	<classpathentry kind="src" path="packages/apps/Stk/src"/>
-	<classpathentry kind="src" path="packages/apps/Updater/src"/>
-	<classpathentry kind="src" path="packages/apps/VoiceDialer/src"/>
-	<classpathentry kind="src" path="packages/providers/CalendarProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/ContactsProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/DownloadProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/DrmProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/ImProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/MediaProvider/src"/>
-	<classpathentry kind="src" path="packages/providers/TelephonyProvider/src"/>
-	<classpathentry kind="src" path="vendor/google/apps/Street/src"/>
-	<classpathentry kind="src" path="vendor/google/apps/YouTube/src"/>
-	<classpathentry kind="src" path="frameworks/base/awt"/>
-	<classpathentry kind="src" path="frameworks/base/cmds/am/src"/>
-	<classpathentry kind="src" path="frameworks/base/cmds/input/src"/>
-	<classpathentry kind="src" path="frameworks/base/cmds/pm/src"/>
-	<classpathentry kind="src" path="frameworks/base/cmds/svc/src"/>
-	<classpathentry kind="src" path="frameworks/base/core/java"/>
-	<classpathentry kind="src" path="frameworks/base/graphics/java"/>
-	<classpathentry kind="src" path="frameworks/base/im/java"/>
-	<classpathentry kind="src" path="frameworks/base/location/java"/>
-	<classpathentry kind="src" path="frameworks/base/media/java"/>
-	<classpathentry kind="src" path="frameworks/base/opengl/java"/>
-	<classpathentry kind="src" path="frameworks/base/packages/SettingsProvider/src"/>
-	<classpathentry kind="src" path="frameworks/base/packages/SubscribedFeedsProvider/src"/>
-	<classpathentry kind="src" path="frameworks/base/sax/java"/>
-	<classpathentry kind="src" path="frameworks/base/services/java"/>
-	<classpathentry kind="src" path="frameworks/base/telephony/java"/>
-	<classpathentry kind="src" path="frameworks/base/test-runner"/>
-	<classpathentry kind="src" path="frameworks/base/wifi/java"/>
-	<classpathentry kind="src" path="frameworks/policies/base/phone"/>
-	<classpathentry kind="src" path="development/samples/ApiDemos/src"/>
-	<classpathentry kind="src" path="development/samples/ApiDemos/tests/src"/>
-	<classpathentry kind="src" path="development/samples/Compass/src"/>
-	<classpathentry kind="src" path="development/samples/HelloActivity/src"/>
-	<classpathentry kind="src" path="development/samples/HelloActivity/tests/src"/>
-	<classpathentry kind="src" path="development/samples/Home/src"/>
-	<classpathentry kind="src" path="development/samples/LunarLander/src"/>
-	<classpathentry kind="src" path="development/samples/LunarLander/tests/src"/>
-	<classpathentry kind="src" path="development/samples/NotePad/src"/>
-	<classpathentry kind="src" path="development/samples/NotePad/tests/src"/>
-	<classpathentry kind="src" path="development/samples/RSSReader/src"/>
-	<classpathentry kind="src" path="development/samples/SkeletonApp/src"/>
-	<classpathentry kind="src" path="development/samples/SkeletonApp/tests/src"/>
-	<classpathentry kind="src" path="development/samples/Snake/src"/>
-	<classpathentry kind="src" path="development/samples/Snake/tests/src"/>
-	<classpathentry kind="src" path="dalvik/libcore/annotation/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/archive/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/auth/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/awt-kernel/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/concurrent/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/crypto/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/dalvik/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/icu/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/json/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/junit/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/logging/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/luni-kernel/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/luni/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/math/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/nio_char/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/nio/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/openssl/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/prefs/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/regex/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/security-kernel/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/security/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/sql/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/suncompat/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/text/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/x-net/src/main/java"/>
-	<classpathentry kind="src" path="dalvik/libcore/xml/src/main/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/APPS/ApiDemos_intermediates/src/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/APPS/Browser_intermediates/src/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/APPS/IM_intermediates/src/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/APPS/Music_intermediates/src/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/APPS/Phone_intermediates/src/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/com.android.im.plugin_intermediates/src"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/core/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/im/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/location/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/media/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/telephony/java"/>
-	<classpathentry kind="src" path="out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/wifi/java"/>
-	<classpathentry kind="src" path="out/target/common/R"/>
-	<classpathentry kind="src" path="external/tagsoup/src"/>
-	<classpathentry kind="src" path="external/protobuf/src"/>
-	<classpathentry kind="src" path="external/gdata/src"/>
-	<classpathentry kind="src" path="external/apache-http/src"/>
-	<classpathentry kind="lib" path="external/googleclient/googleclient-lib.jar"/>
-	<classpathentry kind="lib" path="out/target/common/obj/JAVA_LIBRARIES/google-framework_intermediates/javalib.jar"/>
-	<classpathentry kind="lib" path="out/target/common/obj/JAVA_LIBRARIES/googlelogin-client_intermediates/javalib.jar"/>
-	<classpathentry kind="lib" path="packages/apps/Calculator/arity-1.3.1.jar"/>
-	<classpathentry kind="output" path="out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/classes"/>
-</classpath>
diff --git a/ide/eclipse/android-formatting.xml b/ide/eclipse/android-formatting.xml
deleted file mode 100644
index 71af915..0000000
--- a/ide/eclipse/android-formatting.xml
+++ /dev/null
@@ -1,251 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<profiles version="10">
-<profile name="Android" version="10">
-<setting id="org.eclipse.jdt.core.formatter.align_type_members_on_columns" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_assignment" value="0"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_binary_expression" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_compact_if" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_conditional_expression" value="80"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_enum_constants" value="0"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_multiple_fields" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_imports" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_package" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_field" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration" value="0"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_imports" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_member_type" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_method" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_package" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_array_initializer" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block_in_case" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_constant" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_method_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_switch" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.brace_position_for_type_declaration" value="end_of_line"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_comments" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_header" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_html" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_source_code" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.indent_parameter_description" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.indent_root_tags" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.line_length" value="80"/>
-<setting id="org.eclipse.jdt.core.formatter.compact_else_if" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="2"/>
-<setting id="org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer" value="2"/>
-<setting id="org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_empty_lines" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_block" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_body" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.indentation.size" value="4"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_binary_operator" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_ellipsis" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_unary_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_binary_operator" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_ellipsis" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_before_unary_operator" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.lineSplit" value="100"/>
-<setting id="org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body" value="0"/>
-<setting id="org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve" value="1"/>
-<setting id="org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.tabulation.char" value="space"/>
-<setting id="org.eclipse.jdt.core.formatter.tabulation.size" value="4"/>
-<setting id="org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations" value="false"/>
-</profile>
-</profiles>
diff --git a/ide/eclipse/android.importorder b/ide/eclipse/android.importorder
deleted file mode 100644
index 09966ec..0000000
--- a/ide/eclipse/android.importorder
+++ /dev/null
@@ -1,7 +0,0 @@
-#Organize Import Order
-#Wed Apr 04 11:32:05 CDT 2007
-4=javax
-3=java
-2=android
-1=org
-0=com
diff --git a/ide/intellij/IndecentExposure.xml b/ide/intellij/IndecentExposure.xml
deleted file mode 100644
index bd61db2..0000000
--- a/ide/intellij/IndecentExposure.xml
+++ /dev/null
@@ -1,426 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<inspections profile_name="IndecentExposure" version="1.0" is_locked="false">
-  <option name="myName" value="IndecentExposure" />
-  <option name="myLocal" value="true" />
-  <inspection_tool class="FieldCanBeLocal" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryModuleDependencyInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="WebProperties" level="ERROR" enabled="false" />
-  <inspection_tool class="RedundantTypeArguments" level="WARNING" enabled="false" />
-  <inspection_tool class="XmlWrongClosingTagName" level="ERROR" enabled="false" />
-  <inspection_tool class="CssOverwrittenProperties" level="WARNING" enabled="false" />
-  <inspection_tool class="MissedExecutable" level="WARNING" enabled="false" />
-  <inspection_tool class="CheckJsfComponentUnderViewTag" level="INFO" enabled="false" />
-  <inspection_tool class="DuplicatedBeanNamesInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="EmptyCatchBlock" level="WARNING" enabled="false">
-    <option name="m_includeComments" value="true" />
-    <option name="m_ignoreTestCases" value="true" />
-    <option name="m_ignoreIgnoreParameter" value="true" />
-  </inspection_tool>
-  <inspection_tool class="StringToString" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringBeanAutowiringInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="CssRgbFunctionInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="MalformedRegex" level="WARNING" enabled="false" />
-  <inspection_tool class="UtilSchemaInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="TrivialIfJS" level="WARNING" enabled="false" />
-  <inspection_tool class="CaughtExceptionImmediatelyRethrown" level="WARNING" enabled="false" />
-  <inspection_tool class="EjbWarningInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="AntMissingPropertiesFileInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="NonSerializableServiceParameters" level="ERROR" enabled="false" />
-  <inspection_tool class="InconsistentResourceBundle" level="ERROR" enabled="false">
-    <option name="REPORT_MISSING_TRANSLATIONS" value="true" />
-    <option name="REPORT_INCONSISTENT_PROPERTIES" value="true" />
-    <option name="REPORT_DUPLICATED_PROPERTIES" value="true" />
-  </inspection_tool>
-  <inspection_tool class="HtmlExtraClosingTag" level="ERROR" enabled="false" />
-  <inspection_tool class="MissingMnemonic" level="WARNING" enabled="false" />
-  <inspection_tool class="OneButtonGroup" level="WARNING" enabled="false" />
-  <inspection_tool class="SuspiciousSystemArraycopy" level="WARNING" enabled="false" />
-  <inspection_tool class="BadExpressionStatementJS" level="WARNING" enabled="false" />
-  <inspection_tool class="GwtMethodWithParametersInConstantsInterface" level="ERROR" enabled="false" />
-  <inspection_tool class="UnusedLabel" level="WARNING" enabled="false" />
-  <inspection_tool class="SimplifiableIfStatement" level="WARNING" enabled="false" />
-  <inspection_tool class="ComponentRegistrationProblems" level="ERROR" enabled="false">
-    <option name="CHECK_PLUGIN_XML" value="true" />
-    <option name="CHECK_JAVA_CODE" value="true" />
-    <option name="CHECK_ACTIONS" value="true" />
-  </inspection_tool>
-  <inspection_tool class="ReturnFromFinallyBlock" level="WARNING" enabled="false" />
-  <inspection_tool class="InfiniteRecursion" level="WARNING" enabled="false" />
-  <inspection_tool class="ConstantConditions" level="WARNING" enabled="false">
-    <option name="SUGGEST_NULLABLE_ANNOTATIONS" value="false" />
-    <option name="DONT_REPORT_TRUE_ASSERT_STATEMENTS" value="false" />
-  </inspection_tool>
-  <inspection_tool class="IgnoreResultOfCall" level="WARNING" enabled="false">
-    <option name="m_reportAllNonLibraryCalls" value="false" />
-    <option name="callCheckString" value="java.io.InputStream,read,java.io.InputStream,skip,java.lang.StringBuffer,toString,java.lang.StringBuilder,toString,java.lang.String,.*,java.math.BigInteger,.*,java.math.BigDecimal,.*,java.net.InetAddress,.*" />
-  </inspection_tool>
-  <inspection_tool class="Deprecation" level="WARNING" enabled="false" />
-  <inspection_tool class="JSUnusedLocalSymbols" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryBoxing" level="WARNING" enabled="false" />
-  <inspection_tool class="JSDeprecatedSymbols" level="INFO" enabled="false" />
-  <inspection_tool class="PrimitiveArrayArgumentToVariableArgMethod" level="WARNING" enabled="false" />
-  <inspection_tool class="StrutsValidatorInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="StringConstructor" level="WARNING" enabled="false">
-    <option name="ignoreSubstringArguments" value="false" />
-  </inspection_tool>
-  <inspection_tool class="FunctionWithInconsistentReturnsJS" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryLocalVariableJS" level="WARNING" enabled="false">
-    <option name="m_ignoreImmediatelyReturnedVariables" value="false" />
-    <option name="m_ignoreAnnotatedVariables" value="false" />
-  </inspection_tool>
-  <inspection_tool class="InjectionValueTypeInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="HibernateConfigDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="UnhandledExceptionInJSP" level="WARNING" enabled="false" />
-  <inspection_tool class="ContinueOrBreakFromFinallyBlock" level="WARNING" enabled="false" />
-  <inspection_tool class="StrutsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="InfiniteLoopStatement" level="WARNING" enabled="false" />
-  <inspection_tool class="EjbDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="CheckTagEmptyBody" level="WARNING" enabled="false" />
-  <inspection_tool class="FacesModelInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="FinallyBlockCannotCompleteNormally" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryLabelOnContinueStatement" level="WARNING" enabled="false" />
-  <inspection_tool class="CssUnknownProperty" level="WARNING" enabled="false">
-    <option name="myCustomPropertiesEnabled" value="false" />
-    <option name="myCustomPropertiesList">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </inspection_tool>
-  <inspection_tool class="EmptyStatementBody" level="WARNING" enabled="false">
-    <option name="m_reportEmptyBlocks" value="false" />
-  </inspection_tool>
-  <inspection_tool class="ShiftOutOfRangeJS" level="WARNING" enabled="false" />
-  <inspection_tool class="CssUnusedSymbolInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="NumberEquality" level="WARNING" enabled="false" />
-  <inspection_tool class="RequiredAttributes" level="WARNING" enabled="false">
-    <option name="myAdditionalRequiredHtmlAttributes" value="" />
-  </inspection_tool>
-  <inspection_tool class="ArrayEquals" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringReplacedMethodsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="UnusedMessageFormatParameter" level="WARNING" enabled="false" />
-  <inspection_tool class="AutowiredDependenciesInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringScopesInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="DuplicateMnemonic" level="WARNING" enabled="false" />
-  <inspection_tool class="JavaeeApplicationDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="RedundantCast" level="WARNING" enabled="false" />
-  <inspection_tool class="TrivialIf" level="WARNING" enabled="false" />
-  <inspection_tool class="HibernateMappingDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="ThrowFromFinallyBlockJS" level="WARNING" enabled="false" />
-  <inspection_tool class="AntDuplicateImportedTargetsInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="HtmlUnknownTag" level="WARNING" enabled="false">
-    <option name="myValues">
-      <value>
-        <list size="5">
-          <item index="0" class="java.lang.String" itemvalue="embed" />
-          <item index="1" class="java.lang.String" itemvalue="nobr" />
-          <item index="2" class="java.lang.String" itemvalue="noembed" />
-          <item index="3" class="java.lang.String" itemvalue="comment" />
-          <item index="4" class="java.lang.String" itemvalue="script" />
-        </list>
-      </value>
-    </option>
-    <option name="myCustomValuesEnabled" value="true" />
-  </inspection_tool>
-  <inspection_tool class="DefaultFileTemplate" level="WARNING" enabled="false">
-    <option name="CHECK_FILE_HEADER" value="true" />
-    <option name="CHECK_TRY_CATCH_SECTION" value="true" />
-    <option name="CHECK_METHOD_BODY" value="true" />
-  </inspection_tool>
-  <inspection_tool class="UnnecessaryLabelOnBreakStatementJS" level="WARNING" enabled="false" />
-  <inspection_tool class="NoLabelFor" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryReturn" level="WARNING" enabled="false" />
-  <inspection_tool class="JpaModelErrorInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="ThrowableInstanceNeverThrown" level="WARNING" enabled="false" />
-  <inspection_tool class="DuplicateCaseLabelJS" level="WARNING" enabled="false" />
-  <inspection_tool class="ComparatorMethodParameterNotUsed" level="WARNING" enabled="false" />
-  <inspection_tool class="InfiniteLoopJS" level="WARNING" enabled="false" />
-  <inspection_tool class="GwtServiceNotRegistered" level="ERROR" enabled="false" />
-  <inspection_tool class="BooleanMethodIsAlwaysInverted" level="WARNING" enabled="false" />
-  <inspection_tool class="JSShowOverridingMarkers" level="INFO" enabled="false" />
-  <inspection_tool class="UnnecessaryUnboxing" level="WARNING" enabled="false" />
-  <inspection_tool class="NonJREEmulationClassesInClientCode" level="ERROR" enabled="false" />
-  <inspection_tool class="PointlessBitwiseExpression" level="WARNING" enabled="false">
-    <option name="m_ignoreExpressionsContainingConstants" value="false" />
-  </inspection_tool>
-  <inspection_tool class="MismatchedArrayReadWrite" level="WARNING" enabled="false" />
-  <inspection_tool class="JSUnresolvedFunction" level="INFO" enabled="false" />
-  <inspection_tool class="ELValidationInJSP" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryTemporaryOnConversionFromString" level="WARNING" enabled="false" />
-  <inspection_tool class="EqualsWhichDoesntCheckParameterClass" level="WARNING" enabled="false" />
-  <inspection_tool class="FinalStaticMethod" level="WARNING" enabled="false" />
-  <inspection_tool class="SameParameterValue" level="WARNING" enabled="false" />
-  <inspection_tool class="JpaORMDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="JpaQueryApiInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="AntDuplicateTargetsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="ReservedWordUsedAsNameJS" level="WARNING" enabled="false" />
-  <inspection_tool class="ComponentNotRegistered" level="WARNING" enabled="false">
-    <option name="CHECK_ACTIONS" value="true" />
-    <option name="IGNORE_NON_PUBLIC" value="true" />
-  </inspection_tool>
-  <inspection_tool class="ReflectionForUnavailableAnnotation" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringFactoryMethodInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="CheckXmlFileWithXercesValidator" level="ERROR" enabled="false" />
-  <inspection_tool class="ExceptionCaughtLocallyJS" level="WARNING" enabled="false" />
-  <inspection_tool class="PointlessBooleanExpressionJS" level="WARNING" enabled="false" />
-  <inspection_tool class="JSDuplicatedDeclaration" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringInjectionValueConsistencyInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="GwtJavaScriptReferences" level="ERROR" enabled="false" />
-  <inspection_tool class="CssInvalidElementInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="Glassfish" level="ERROR" enabled="false" />
-  <inspection_tool class="WrongPackageStatement" level="ERROR" enabled="false" />
-  <inspection_tool class="UnusedReturnValue" level="WARNING" enabled="false" />
-  <inspection_tool class="GwtToHtmlReferences" level="ERROR" enabled="false" />
-  <inspection_tool class="GWTRemoteServiceAsyncCheck" level="ERROR" enabled="false" />
-  <inspection_tool class="InfiniteRecursionJS" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringInjectionValueStyleInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="UnusedAssignment" level="WARNING" enabled="false">
-    <option name="REPORT_PREFIX_EXPRESSIONS" value="false" />
-    <option name="REPORT_POSTFIX_EXPRESSIONS" value="true" />
-    <option name="REPORT_REDUNDANT_INITIALIZER" value="true" />
-  </inspection_tool>
-  <inspection_tool class="SimplifiableConditionalExpression" level="WARNING" enabled="false" />
-  <inspection_tool class="IncompatibleMask" level="WARNING" enabled="false" />
-  <inspection_tool class="ToArrayCallWithZeroLengthArrayArgument" level="WARNING" enabled="false" />
-  <inspection_tool class="Dependency" level="ERROR" enabled="false" />
-  <inspection_tool class="ArgNamesWarningsInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="ImplicitlyExposedWebServiceMethods" level="INFO" enabled="false" />
-  <inspection_tool class="SillyAssignmentJS" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringAopWarningsInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="GwtInconsistentI18nInterface" level="ERROR" enabled="false" />
-  <inspection_tool class="FinalPrivateMethod" level="WARNING" enabled="false" />
-  <inspection_tool class="NullableProblems" level="WARNING" enabled="false">
-    <option name="REPORT_NULLABLE_METHOD_OVERRIDES_NOTNULL" value="true" />
-    <option name="REPORT_NOT_ANNOTATED_METHOD_OVERRIDES_NOTNULL" value="true" />
-    <option name="REPORT_NOTNULL_PARAMETER_OVERRIDES_NULLABLE" value="true" />
-    <option name="REPORT_NOT_ANNOTATED_PARAMETER_OVERRIDES_NOTNULL" value="true" />
-    <option name="REPORT_NOT_ANNOTATED_GETTER" value="true" />
-    <option name="REPORT_NOT_ANNOTATED_SETTER_PARAMETER" value="true" />
-    <option name="REPORT_ANNOTATION_NOT_PROPAGATED_TO_OVERRIDERS" value="true" />
-  </inspection_tool>
-  <inspection_tool class="UnnecessaryLabelOnContinueStatementJS" level="WARNING" enabled="false" />
-  <inspection_tool class="CssUnitlessNumber" level="WARNING" enabled="false" />
-  <inspection_tool class="BooleanConstructor" level="WARNING" enabled="false" />
-  <inspection_tool class="EjbQlInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="groupsTestNG" level="WARNING" enabled="false">
-    <option name="groups">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </inspection_tool>
-  <inspection_tool class="DeclareParentsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="UnusedParameters" level="WARNING" enabled="false" />
-  <inspection_tool class="PointlessArithmeticExpressionJS" level="WARNING" enabled="false" />
-  <inspection_tool class="ConstantIfStatement" level="WARNING" enabled="false" />
-  <inspection_tool class="JSUnresolvedVariable" level="INFO" enabled="false" />
-  <inspection_tool class="JpaDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="SpringBeanConstructorArgInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="CheckValidXmlInScriptTagBody" level="ERROR" enabled="false" />
-  <inspection_tool class="PointlessBitwiseExpressionJS" level="WARNING" enabled="false">
-    <option name="m_ignoreExpressionsContainingConstants" value="false" />
-  </inspection_tool>
-  <inspection_tool class="StrutsTilesInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="PointlessArithmeticExpression" level="WARNING" enabled="false">
-    <option name="m_ignoreExpressionsContainingConstants" value="false" />
-  </inspection_tool>
-  <inspection_tool class="UnnecessaryLocalVariable" level="WARNING" enabled="false">
-    <option name="m_ignoreImmediatelyReturnedVariables" value="false" />
-    <option name="m_ignoreAnnotatedVariables" value="false" />
-  </inspection_tool>
-  <inspection_tool class="ArgNamesErrorsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="SpringModelInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="ImplicitArrayToString" level="WARNING" enabled="false" />
-  <inspection_tool class="FinalizeCallsSuperFinalize" level="WARNING" enabled="false">
-    <option name="m_ignoreForObjectSubclasses" value="false" />
-  </inspection_tool>
-  <inspection_tool class="HtmlUnknownAttribute" level="WARNING" enabled="false">
-    <option name="myValues">
-      <value>
-        <list size="5">
-          <item index="0" class="java.lang.String" itemvalue="type" />
-          <item index="1" class="java.lang.String" itemvalue="wmode" />
-          <item index="2" class="java.lang.String" itemvalue="src" />
-          <item index="3" class="java.lang.String" itemvalue="width" />
-          <item index="4" class="java.lang.String" itemvalue="height" />
-        </list>
-      </value>
-    </option>
-    <option name="myCustomValuesEnabled" value="true" />
-  </inspection_tool>
-  <inspection_tool class="SynchronizeOnNonFinalField" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringBeanDepedencyCheckInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="SpringAopErrorsInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="JpaDataSourceORMDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="OctalLiteral" level="WARNING" enabled="false" />
-  <inspection_tool class="Geronimo" level="ERROR" enabled="false" />
-  <inspection_tool class="UnnecessarySemicolon" level="WARNING" enabled="false" />
-  <inspection_tool class="PointlessBooleanExpression" level="WARNING" enabled="false">
-    <option name="m_ignoreExpressionsContainingConstants" value="false" />
-  </inspection_tool>
-  <inspection_tool class="BoundFieldAssignment" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringJamErrorInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="GWTStyleCheck" level="ERROR" enabled="false" />
-  <inspection_tool class="ExtendsAnnotation" level="WARNING" enabled="false" />
-  <inspection_tool class="ShiftOutOfRange" level="WARNING" enabled="false" />
-  <inspection_tool class="MismatchedCollectionQueryUpdate" level="WARNING" enabled="false" />
-  <inspection_tool class="SuspiciousMethodCalls" level="WARNING" enabled="false">
-    <option name="REPORT_CONVERTIBLE_METHOD_CALLS" value="true" />
-  </inspection_tool>
-  <inspection_tool class="ManualArrayCopy" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryLabelOnBreakStatement" level="WARNING" enabled="false" />
-  <inspection_tool class="StringEquality" level="WARNING" enabled="false" />
-  <inspection_tool class="RedundantArrayCreation" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryReturnJS" level="WARNING" enabled="false" />
-  <inspection_tool class="SelfIncludingJspFiles" level="ERROR" enabled="false" />
-  <inspection_tool class="DuplicatePropertyOnObjectJS" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringBeanInstantiationInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="OneWayWebMethod" level="ERROR" enabled="false" />
-  <inspection_tool class="SameReturnValue" level="WARNING" enabled="false" />
-  <inspection_tool class="UnreachableCodeJS" level="WARNING" enabled="false" />
-  <inspection_tool class="EmptyTryBlock" level="WARNING" enabled="false" />
-  <inspection_tool class="ConstantConditionalExpression" level="WARNING" enabled="false" />
-  <inspection_tool class="ELSpecValidationInJSP" level="WARNING" enabled="false" />
-  <inspection_tool class="JpaQlInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="LoopStatementThatDoesntLoopJS" level="WARNING" enabled="false" />
-  <inspection_tool class="NoExplicitFinalizeCalls" level="WARNING" enabled="false" />
-  <inspection_tool class="ThrowFromFinallyBlock" level="WARNING" enabled="false" />
-  <inspection_tool class="EmptyWebServiceClass" level="WARNING" enabled="false" />
-  <inspection_tool class="AccessStaticViaInstance" level="WARNING" enabled="false" />
-  <inspection_tool class="ObjectEqualsNull" level="WARNING" enabled="false" />
-  <inspection_tool class="InstantiatingObjectToGetClassObject" level="WARNING" enabled="false" />
-  <inspection_tool class="UnusedDeclaration" level="WARNING" enabled="false">
-    <option name="ADD_MAINS_TO_ENTRIES" value="true" />
-    <option name="ADD_APPLET_TO_ENTRIES" value="true" />
-    <option name="ADD_SERVLET_TO_ENTRIES" value="true" />
-    <option name="ADD_NONJAVA_TO_ENTRIES" value="true" />
-    <option name="ADDITIONAL_ANNOTATIONS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-    <option name="ADD_EJB_TO_ENTRIES" value="true" />
-    <option name="ADD_JUNIT_TO_ENTRIES" value="true" />
-    <option name="ADD_TESTNG_TO_ENTRIES" value="true" />
-  </inspection_tool>
-  <inspection_tool class="DuplicateThrows" level="WARNING" enabled="false" />
-  <inspection_tool class="ForCanBeForeach" level="WARNING" enabled="false">
-    <option name="REPORT_INDEXED_LOOP" value="true" />
-  </inspection_tool>
-  <inspection_tool class="MalformedXPath" level="WARNING" enabled="false" />
-  <inspection_tool class="NonJaxWsWebServices" level="WARNING" enabled="false" />
-  <inspection_tool class="MalformedFormatString" level="WARNING" enabled="false" />
-  <inspection_tool class="ContinueOrBreakFromFinallyBlockJS" level="WARNING" enabled="false" />
-  <inspection_tool class="SillyAssignment" level="WARNING" enabled="false" />
-  <inspection_tool class="EjbErrorInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="JBoss" level="ERROR" enabled="false" />
-  <inspection_tool class="NewStringBufferWithCharArgument" level="WARNING" enabled="false" />
-  <inspection_tool class="IncompatibleMaskJS" level="WARNING" enabled="false" />
-  <inspection_tool class="CssInvalidShorthandPropertyValue" level="ERROR" enabled="false" />
-  <inspection_tool class="dependsOnMethodTestNG" level="WARNING" enabled="false" />
-  <inspection_tool class="NullArgumentToVariableArgMethod" level="WARNING" enabled="false" />
-  <inspection_tool class="JSUntypedDeclaration" level="INFO" enabled="false" />
-  <inspection_tool class="WebWarnings" level="WARNING" enabled="false" />
-  <inspection_tool class="CssNoGenericFontName" level="WARNING" enabled="false" />
-  <inspection_tool class="SuspiciousToArrayCall" level="WARNING" enabled="false" />
-  <inspection_tool class="UNCHECKED_WARNING" level="WARNING" enabled="false" />
-  <inspection_tool class="LoopStatementsThatDontLoop" level="WARNING" enabled="false" />
-  <inspection_tool class="AssertEqualsBetweenInconvertibleTypes" level="WARNING" enabled="false" />
-  <inspection_tool class="ExtendsObject" level="WARNING" enabled="false" />
-  <inspection_tool class="JpaDataSourceORMInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="TrivialConditionalJS" level="WARNING" enabled="false" />
-  <inspection_tool class="JSUndeclaredVariable" level="INFO" enabled="false" />
-  <inspection_tool class="GwtInconsistentSerializableClass" level="ERROR" enabled="false" />
-  <inspection_tool class="JavadocReference" level="ERROR" enabled="false" />
-  <inspection_tool class="RedundantThrows" level="WARNING" enabled="false" />
-  <inspection_tool class="ConstantConditionalExpressionJS" level="WARNING" enabled="false" />
-  <inspection_tool class="AbstractBeanReferencesInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="FallthroughInSwitchStatementJS" level="WARNING" enabled="false" />
-  <inspection_tool class="JpaModelWarningInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="WhileCanBeForeach" level="WARNING" enabled="false" />
-  <inspection_tool class="JavaDoc" level="WARNING" enabled="false">
-    <option name="TOP_LEVEL_CLASS_OPTIONS">
-      <value>
-        <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-        <option name="REQUIRED_TAGS" value="" />
-      </value>
-    </option>
-    <option name="INNER_CLASS_OPTIONS">
-      <value>
-        <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-        <option name="REQUIRED_TAGS" value="" />
-      </value>
-    </option>
-    <option name="METHOD_OPTIONS">
-      <value>
-        <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-        <option name="REQUIRED_TAGS" value="@return@param@throws or @exception" />
-      </value>
-    </option>
-    <option name="FIELD_OPTIONS">
-      <value>
-        <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-        <option name="REQUIRED_TAGS" value="" />
-      </value>
-    </option>
-    <option name="IGNORE_DEPRECATED" value="false" />
-    <option name="IGNORE_JAVADOC_PERIOD" value="true" />
-    <option name="myAdditionalJavadocTags" value="" />
-  </inspection_tool>
-  <inspection_tool class="SuspiciousNameCombination" level="WARNING" enabled="false">
-    <group names="x,width,left,right" />
-    <group names="y,height,top,bottom" />
-  </inspection_tool>
-  <inspection_tool class="UNUSED_SYMBOL" level="WARNING" enabled="false">
-    <option name="LOCAL_VARIABLE" value="true" />
-    <option name="FIELD" value="true" />
-    <option name="METHOD" value="true" />
-    <option name="CLASS" value="true" />
-    <option name="PARAMETER" value="true" />
-    <option name="REPORT_PARAMETER_FOR_PUBLIC_METHODS" value="true" />
-    <option name="INJECTION_ANNOS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </inspection_tool>
-  <inspection_tool class="ReturnFromFinallyBlockJS" level="WARNING" enabled="false" />
-  <inspection_tool class="StrutsValidatorFormInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="CheckImageSize" level="WARNING" enabled="false" />
-  <inspection_tool class="TypeParameterExtendsObject" level="WARNING" enabled="false" />
-  <inspection_tool class="ManualArrayToCollectionCopy" level="WARNING" enabled="false" />
-  <inspection_tool class="MimeType" level="ERROR" enabled="false" />
-  <inspection_tool class="ConstantIfStatementJS" level="WARNING" enabled="false" />
-  <inspection_tool class="UnresolvedPropertyKey" level="ERROR" enabled="false" />
-  <inspection_tool class="EmptyStatementBodyJS" level="WARNING" enabled="false">
-    <option name="m_reportEmptyBlocks" value="false" />
-  </inspection_tool>
-  <inspection_tool class="SpringBeanLookupMethodInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="ThisExpressionReferencesGlobalObjectJS" level="WARNING" enabled="false" />
-  <inspection_tool class="EmptyFinallyBlock" level="WARNING" enabled="false" />
-  <inspection_tool class="HibernateMappingDatasourceDomInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="XmlWrongRootElement" level="ERROR" enabled="false" />
-  <inspection_tool class="StringConcatenationInsideStringBufferAppend" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryTemporaryOnConversionToString" level="WARNING" enabled="false" />
-  <inspection_tool class="EqualsBetweenInconvertibleTypes" level="WARNING" enabled="false" />
-  <inspection_tool class="CloneCallsSuperClone" level="WARNING" enabled="false" />
-  <inspection_tool class="Weblogic" level="ERROR" enabled="false" />
-  <inspection_tool class="UnnecessaryLabelJS" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryContinueJS" level="WARNING" enabled="false" />
-  <inspection_tool class="CloneDeclaresCloneNotSupported" level="WARNING" enabled="false" />
-  <inspection_tool class="SpringBeanNameConventionInspection" level="WARNING" enabled="false" />
-  <inspection_tool class="EmptyMethod" level="WARNING" enabled="false" />
-  <inspection_tool class="UNUSED_IMPORT" level="WARNING" enabled="false" />
-  <inspection_tool class="CheckDtdRefs" level="ERROR" enabled="false" />
-  <inspection_tool class="ReferencesToClassesFromDefaultPackagesInJSPFile" level="ERROR" enabled="false" />
-  <inspection_tool class="ValidExternallyBoundObject" level="ERROR" enabled="false" />
-  <inspection_tool class="CheckEmptyScriptTag" level="WARNING" enabled="false" />
-  <inspection_tool class="NoScrollPane" level="WARNING" enabled="false" />
-  <inspection_tool class="NoButtonGroup" level="WARNING" enabled="false" />
-  <inspection_tool class="UnnecessaryConditionalExpression" level="WARNING" enabled="false" />
-  <inspection_tool class="CssNegativeValueInspection" level="ERROR" enabled="false" />
-  <inspection_tool class="UnnecessaryContinue" level="WARNING" enabled="false" />
-  <expanded_node name="Inspections" />
-  <selected_node name="Inspections" />
-</inspections>
-
diff --git a/ide/intellij/build.xml b/ide/intellij/build.xml
deleted file mode 100644
index d82d67f..0000000
--- a/ide/intellij/build.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<project name="android" default="make" basedir="../../">
-    <target name="make"
-            description="Run make and then regenerate IntelliJ configuration.">
-        <exec executable="/bin/bash">
-            <arg value="ide/intellij/make+intelligen.sh"/>
-        </exec>
-    </target>
-</project>
\ No newline at end of file
diff --git a/ide/intellij/codestyles/AndroidStyle.xml b/ide/intellij/codestyles/AndroidStyle.xml
deleted file mode 100644
index 113ffca..0000000
--- a/ide/intellij/codestyles/AndroidStyle.xml
+++ /dev/null
@@ -1,71 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<code_scheme name="AndroidStyle">
-  <option name="JAVA_INDENT_OPTIONS">
-    <value>
-      <option name="INDENT_SIZE" value="4" />
-      <option name="CONTINUATION_INDENT_SIZE" value="8" />
-      <option name="TAB_SIZE" value="8" />
-      <option name="USE_TAB_CHARACTER" value="false" />
-      <option name="SMART_TABS" value="false" />
-      <option name="LABEL_INDENT_SIZE" value="0" />
-      <option name="LABEL_INDENT_ABSOLUTE" value="false" />
-    </value>
-  </option>
-  <option name="KEEP_CONTROL_STATEMENT_IN_ONE_LINE" value="false" />
-  <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
-  <option name="ALIGN_MULTILINE_FOR" value="false" />
-  <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
-  <option name="BLANK_LINES_AROUND_FIELD" value="1" />
-  <option name="BLANK_LINES_AFTER_CLASS_HEADER" value="1" />
-  <option name="FIELD_NAME_PREFIX" value="m" />
-  <option name="STATIC_FIELD_NAME_PREFIX" value="m" />
-  <option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="99" />
-  <option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="99" />
-  <option name="IMPORT_LAYOUT_TABLE">
-    <value>
-      <package name="com.google" withSubpackages="true" />
-      <emptyLine />
-      <package name="com" withSubpackages="true" />
-      <emptyLine />
-      <package name="junit" withSubpackages="true" />
-      <emptyLine />
-      <package name="net" withSubpackages="true" />
-      <emptyLine />
-      <package name="org" withSubpackages="true" />
-      <emptyLine />
-      <package name="android" withSubpackages="true" />
-      <emptyLine />
-      <package name="java" withSubpackages="true" />
-      <emptyLine />
-      <package name="javax" withSubpackages="true" />
-      <emptyLine />
-      <package name="" withSubpackages="true" />
-    </value>
-  </option>
-  <option name="RIGHT_MARGIN" value="80" />
-  <option name="CALL_PARAMETERS_WRAP" value="1" />
-  <option name="METHOD_PARAMETERS_WRAP" value="1" />
-  <option name="EXTENDS_LIST_WRAP" value="1" />
-  <option name="THROWS_LIST_WRAP" value="1" />
-  <option name="EXTENDS_KEYWORD_WRAP" value="1" />
-  <option name="THROWS_KEYWORD_WRAP" value="1" />
-  <option name="METHOD_CALL_CHAIN_WRAP" value="1" />
-  <option name="BINARY_OPERATION_WRAP" value="1" />
-  <option name="BINARY_OPERATION_SIGN_ON_NEXT_LINE" value="true" />
-  <option name="TERNARY_OPERATION_WRAP" value="1" />
-  <option name="TERNARY_OPERATION_SIGNS_ON_NEXT_LINE" value="true" />
-  <option name="FOR_STATEMENT_WRAP" value="1" />
-  <option name="ARRAY_INITIALIZER_WRAP" value="1" />
-  <option name="ASSIGNMENT_WRAP" value="1" />
-  <option name="PLACE_ASSIGNMENT_SIGN_ON_NEXT_LINE" value="true" />
-  <option name="WRAP_COMMENTS" value="true" />
-  <option name="IF_BRACE_FORCE" value="3" />
-  <option name="DOWHILE_BRACE_FORCE" value="3" />
-  <option name="WHILE_BRACE_FORCE" value="3" />
-  <option name="FOR_BRACE_FORCE" value="3" />
-  <option name="JD_P_AT_EMPTY_LINES" value="false" />
-  <option name="JD_KEEP_EMPTY_PARAMETER" value="false" />
-  <option name="JD_KEEP_EMPTY_EXCEPTION" value="false" />
-  <option name="JD_KEEP_EMPTY_RETURN" value="false" />
-</code_scheme>
-
diff --git a/ide/intellij/fileTemplates/includes/FileHeader.java b/ide/intellij/fileTemplates/includes/FileHeader.java
deleted file mode 100644
index 2757128..0000000
--- a/ide/intellij/fileTemplates/includes/FileHeader.java
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
- 
- 
diff --git a/ide/intellij/make+intelligen.sh b/ide/intellij/make+intelligen.sh
deleted file mode 100755
index fcb5fbd..0000000
--- a/ide/intellij/make+intelligen.sh
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/bash
-
-if [ ! -f buildspec.mk.default ]; then
-    echo "Error: Please run from the root of the tree."
-    exit 1
-fi
-    
-. envsetup.sh
-lunch 6
-
-if make -j4; then
-    tools/javabuild/intelligen.sh
-fi
diff --git a/ide/intellij/moduleDefinitions/testing.iml b/ide/intellij/moduleDefinitions/testing.iml
deleted file mode 100644
index e784403..0000000
--- a/ide/intellij/moduleDefinitions/testing.iml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module relativePaths="true" type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../../../device/dalvik/libcore">
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/android/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/annotation/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/apache-commons-logging/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/apache-commons/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/archive/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/auth/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/awt/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/beans/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/concurrent/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/crypto/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/instrument/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/json/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/junit/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/kxml2/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/luni-kernel/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/luni/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/math/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/nio/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/nio_char/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/security-kernel/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/security/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/suncompat/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/text/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/x-net/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/dalvik/libcore/xmlpull/src/main/java" isTestSource="false" />
-    </content>
-    <content url="file://$MODULE_DIR$/../../../device/java">
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/java/android" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/java/config/release" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/java/ext" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/java/tests" isTestSource="true" />
-    </content>
-    <content url="file://$MODULE_DIR$/../../../device/out/target/common/obj">
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/out/target/common/obj/JAVA_LIBRARIES/framework-res_intermediates/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../../device/out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src" isTestSource="false" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="inheritedJdk" />
-    <orderEntryProperties />
-  </component>
-</module>
-
diff --git a/ide/intellij/p4.sh b/ide/intellij/p4.sh
deleted file mode 100755
index 0665a63..0000000
--- a/ide/intellij/p4.sh
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh
-
-if [ $1 == "fstat" ] && [ $2 =~ ".*/out/.*" ]; then
-  echo "$2 - file(s) not in client view." >&2
-  exit 0
-fi
-
-exec /opt/local/bin/p4 $*
diff --git a/ide/xcode/GL.xcodeproj/project.pbxproj b/ide/xcode/GL.xcodeproj/project.pbxproj
deleted file mode 100644
index 1a11676..0000000
--- a/ide/xcode/GL.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,267 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 44;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		004BBD460DAC439E00E4E298 /* SkGLDevice_FBO.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 004BBD440DAC439E00E4E298 /* SkGLDevice_FBO.cpp */; };
-		004BBD750DAC48A600E4E298 /* SkGLDevice_FBO.h in Headers */ = {isa = PBXBuildFile; fileRef = 004BBD740DAC48A600E4E298 /* SkGLDevice_FBO.h */; };
-		004BBE310DAC71A000E4E298 /* SkGLDevice_SWLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 004BBE2F0DAC71A000E4E298 /* SkGLDevice_SWLayer.cpp */; };
-		004BBE320DAC71A000E4E298 /* SkGLDevice_SWLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 004BBE300DAC71A000E4E298 /* SkGLDevice_SWLayer.h */; };
-		009A73DB0DA1179A00876C03 /* SkGL.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A73D40DA1179A00876C03 /* SkGL.cpp */; };
-		009A73DC0DA1179A00876C03 /* SkGL.h in Headers */ = {isa = PBXBuildFile; fileRef = 009A73D50DA1179A00876C03 /* SkGL.h */; };
-		009A73DD0DA1179A00876C03 /* SkGLCanvas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A73D60DA1179A00876C03 /* SkGLCanvas.cpp */; };
-		009A73DE0DA1179A00876C03 /* SkGLTextCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A73D70DA1179A00876C03 /* SkGLTextCache.cpp */; };
-		009A73DF0DA1179A00876C03 /* SkGLTextCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 009A73D80DA1179A00876C03 /* SkGLTextCache.h */; };
-		009A73E00DA1179A00876C03 /* SkTextureCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A73D90DA1179A00876C03 /* SkTextureCache.cpp */; };
-		009A73E10DA1179A00876C03 /* SkTextureCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 009A73DA0DA1179A00876C03 /* SkTextureCache.h */; };
-		009A75D90DA1DF3800876C03 /* SkGLDevice.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A75D70DA1DF3800876C03 /* SkGLDevice.cpp */; };
-		009A75DA0DA1DF3800876C03 /* SkGLDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 009A75D80DA1DF3800876C03 /* SkGLDevice.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		004BBD440DAC439E00E4E298 /* SkGLDevice_FBO.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGLDevice_FBO.cpp; path = ../../libs/graphics/gl/SkGLDevice_FBO.cpp; sourceTree = SOURCE_ROOT; };
-		004BBD740DAC48A600E4E298 /* SkGLDevice_FBO.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGLDevice_FBO.h; path = ../../libs/graphics/gl/SkGLDevice_FBO.h; sourceTree = SOURCE_ROOT; };
-		004BBE2F0DAC71A000E4E298 /* SkGLDevice_SWLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGLDevice_SWLayer.cpp; path = ../../libs/graphics/gl/SkGLDevice_SWLayer.cpp; sourceTree = SOURCE_ROOT; };
-		004BBE300DAC71A000E4E298 /* SkGLDevice_SWLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGLDevice_SWLayer.h; path = ../../libs/graphics/gl/SkGLDevice_SWLayer.h; sourceTree = SOURCE_ROOT; };
-		009A73D40DA1179A00876C03 /* SkGL.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGL.cpp; path = ../../libs/graphics/gl/SkGL.cpp; sourceTree = SOURCE_ROOT; };
-		009A73D50DA1179A00876C03 /* SkGL.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGL.h; path = ../../libs/graphics/gl/SkGL.h; sourceTree = SOURCE_ROOT; };
-		009A73D60DA1179A00876C03 /* SkGLCanvas.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGLCanvas.cpp; path = ../../libs/graphics/gl/SkGLCanvas.cpp; sourceTree = SOURCE_ROOT; };
-		009A73D70DA1179A00876C03 /* SkGLTextCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGLTextCache.cpp; path = ../../libs/graphics/gl/SkGLTextCache.cpp; sourceTree = SOURCE_ROOT; };
-		009A73D80DA1179A00876C03 /* SkGLTextCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGLTextCache.h; path = ../../libs/graphics/gl/SkGLTextCache.h; sourceTree = SOURCE_ROOT; };
-		009A73D90DA1179A00876C03 /* SkTextureCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkTextureCache.cpp; path = ../../libs/graphics/gl/SkTextureCache.cpp; sourceTree = SOURCE_ROOT; };
-		009A73DA0DA1179A00876C03 /* SkTextureCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkTextureCache.h; path = ../../libs/graphics/gl/SkTextureCache.h; sourceTree = SOURCE_ROOT; };
-		009A75D70DA1DF3800876C03 /* SkGLDevice.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkGLDevice.cpp; path = ../../libs/graphics/gl/SkGLDevice.cpp; sourceTree = SOURCE_ROOT; };
-		009A75D80DA1DF3800876C03 /* SkGLDevice.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGLDevice.h; path = ../../libs/graphics/gl/SkGLDevice.h; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libGL.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libGL.a; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* GL */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = GL;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				004BBE2F0DAC71A000E4E298 /* SkGLDevice_SWLayer.cpp */,
-				004BBE300DAC71A000E4E298 /* SkGLDevice_SWLayer.h */,
-				004BBD740DAC48A600E4E298 /* SkGLDevice_FBO.h */,
-				004BBD440DAC439E00E4E298 /* SkGLDevice_FBO.cpp */,
-				009A75D70DA1DF3800876C03 /* SkGLDevice.cpp */,
-				009A75D80DA1DF3800876C03 /* SkGLDevice.h */,
-				009A73D40DA1179A00876C03 /* SkGL.cpp */,
-				009A73D50DA1179A00876C03 /* SkGL.h */,
-				009A73D60DA1179A00876C03 /* SkGLCanvas.cpp */,
-				009A73D70DA1179A00876C03 /* SkGLTextCache.cpp */,
-				009A73D80DA1179A00876C03 /* SkGLTextCache.h */,
-				009A73D90DA1179A00876C03 /* SkTextureCache.cpp */,
-				009A73DA0DA1179A00876C03 /* SkTextureCache.h */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libGL.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				009A73DC0DA1179A00876C03 /* SkGL.h in Headers */,
-				009A73DF0DA1179A00876C03 /* SkGLTextCache.h in Headers */,
-				009A73E10DA1179A00876C03 /* SkTextureCache.h in Headers */,
-				009A75DA0DA1DF3800876C03 /* SkGLDevice.h in Headers */,
-				004BBD750DAC48A600E4E298 /* SkGLDevice_FBO.h in Headers */,
-				004BBE320DAC71A000E4E298 /* SkGLDevice_SWLayer.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* GL */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "GL" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = GL;
-			productName = GL;
-			productReference = D2AAC046055464E500DB518D /* libGL.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "GL" */;
-			compatibilityVersion = "Xcode 3.0";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* GL */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				D2AAC045055464E500DB518D /* GL */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				009A73DB0DA1179A00876C03 /* SkGL.cpp in Sources */,
-				009A73DD0DA1179A00876C03 /* SkGLCanvas.cpp in Sources */,
-				009A73DE0DA1179A00876C03 /* SkGLTextCache.cpp in Sources */,
-				009A73E00DA1179A00876C03 /* SkTextureCache.cpp in Sources */,
-				009A75D90DA1DF3800876C03 /* SkGLDevice.cpp in Sources */,
-				004BBD460DAC439E00E4E298 /* SkGLDevice_FBO.cpp in Sources */,
-				004BBE310DAC71A000E4E298 /* SkGLDevice_SWLayer.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = GL;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = GL;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_DEBUG,
-					SK_BUILD_FOR_MAC,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
-				GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_SIGN_COMPARE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../libs/graphics/sgl ../../include/corecg ../../include/graphics";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
-				GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_SIGN_COMPARE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../libs/graphics/sgl ../../include/corecg ../../include/graphics";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "GL" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "GL" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/SampleCode/English.lproj/InfoPlist.strings b/ide/xcode/SampleCode/English.lproj/InfoPlist.strings
deleted file mode 100644
index e842e19..0000000
--- a/ide/xcode/SampleCode/English.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,3 +0,0 @@
-/* Localized versions of Info.plist keys */
-
-NSHumanReadableCopyright = "© __MyCompanyName__, 2008";
diff --git a/ide/xcode/SampleCode/English.lproj/main.nib/classes.nib b/ide/xcode/SampleCode/English.lproj/main.nib/classes.nib
deleted file mode 100644
index c4b887e..0000000
--- a/ide/xcode/SampleCode/English.lproj/main.nib/classes.nib
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>IBVersion</key>
-	<string>1</string>
-</dict>
-</plist>
diff --git a/ide/xcode/SampleCode/English.lproj/main.nib/info.nib b/ide/xcode/SampleCode/English.lproj/main.nib/info.nib
deleted file mode 100644
index 2af896b..0000000
--- a/ide/xcode/SampleCode/English.lproj/main.nib/info.nib
+++ /dev/null
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>IBFramework Version</key>
-	<string>629</string>
-	<key>IBLastKnownRelativeProjectPath</key>
-	<string>../../SampleCode.xcodeproj</string>
-	<key>IBOldestOS</key>
-	<integer>5</integer>
-	<key>IBOpenObjects</key>
-	<array/>
-	<key>IBSystem Version</key>
-	<string>9B18</string>
-	<key>targetFramework</key>
-	<string>IBCarbonFramework</string>
-</dict>
-</plist>
diff --git a/ide/xcode/SampleCode/English.lproj/main.nib/objects.xib b/ide/xcode/SampleCode/English.lproj/main.nib/objects.xib
deleted file mode 100644
index a9e438e..0000000
--- a/ide/xcode/SampleCode/English.lproj/main.nib/objects.xib
+++ /dev/null
@@ -1,269 +0,0 @@
-<?xml version="1.0" standalone="yes"?>
-<object class="NSIBObjectData">
-  <object name="rootObject" class="NSCustomObject" id="1">
-  </object>
-  <array count="38" name="allObjects">
-    <object class="IBCarbonMenuItem" id="193">
-      <string name="title">Arrange in Front</string>
-      <boolean name="dynamic">TRUE</boolean>
-      <int name="keyEquivalentModifier">1572864</int>
-      <ostype name="command">frnt</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="148">
-      <string name="title">Select All</string>
-      <string name="keyEquivalent">a</string>
-      <ostype name="command">sall</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="152">
-      <string name="title">Edit</string>
-      <object name="submenu" class="IBCarbonMenu" id="147">
-        <string name="title">Edit</string>
-        <array count="10" name="items">
-          <object class="IBCarbonMenuItem" id="141">
-            <string name="title">Undo</string>
-            <string name="keyEquivalent">z</string>
-            <ostype name="command">undo</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="146">
-            <string name="title">Redo</string>
-            <string name="keyEquivalent">Z</string>
-            <ostype name="command">redo</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="142">
-            <boolean name="separator">TRUE</boolean>
-          </object>
-          <object class="IBCarbonMenuItem" id="143">
-            <string name="title">Cut</string>
-            <string name="keyEquivalent">x</string>
-            <ostype name="command">cut </ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="149">
-            <string name="title">Copy</string>
-            <string name="keyEquivalent">c</string>
-            <ostype name="command">copy</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="144">
-            <string name="title">Paste</string>
-            <string name="keyEquivalent">v</string>
-            <ostype name="command">past</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="151">
-            <string name="title">Delete</string>
-            <ostype name="command">clea</ostype>
-          </object>
-          <reference idRef="148"/>
-          <object class="IBCarbonMenuItem" id="199">
-            <boolean name="separator">TRUE</boolean>
-          </object>
-          <object class="IBCarbonMenuItem" id="198">
-            <string name="title">Special Characters…</string>
-            <ostype name="command">chrp</ostype>
-          </object>
-        </array>
-      </object>
-    </object>
-    <object class="IBCarbonRootControl" id="167">
-      <string name="bounds">0 0 360 480 </string>
-    </object>
-    <object class="IBCarbonMenuItem" id="139">
-      <string name="title">New</string>
-      <string name="keyEquivalent">n</string>
-      <ostype name="command">new </ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="192">
-      <string name="title">Window</string>
-      <object name="submenu" class="IBCarbonMenu" id="195">
-        <string name="title">Window</string>
-        <string name="name">_NSWindowsMenu</string>
-        <array count="6" name="items">
-          <object class="IBCarbonMenuItem" id="190">
-            <string name="title">Minimize</string>
-            <string name="keyEquivalent">m</string>
-            <boolean name="dynamic">TRUE</boolean>
-            <ostype name="command">mini</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="191">
-            <string name="title">Minimize All</string>
-            <string name="keyEquivalent">m</string>
-            <boolean name="dynamic">TRUE</boolean>
-            <int name="keyEquivalentModifier">1572864</int>
-            <ostype name="command">mina</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="197">
-            <string name="title">Zoom</string>
-            <ostype name="command">zoom</ostype>
-          </object>
-          <object class="IBCarbonMenuItem" id="194">
-            <boolean name="separator">TRUE</boolean>
-          </object>
-          <object class="IBCarbonMenuItem" id="196">
-            <string name="title">Bring All to Front</string>
-            <boolean name="dynamic">TRUE</boolean>
-            <ostype name="command">bfrt</ostype>
-          </object>
-          <reference idRef="193"/>
-        </array>
-      </object>
-    </object>
-    <object class="IBCarbonMenuItem" id="132">
-      <string name="title">Revert</string>
-      <string name="keyEquivalent">r</string>
-      <ostype name="command">rvrt</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="187">
-      <string name="title">About Foo</string>
-      <int name="keyEquivalentModifier">0</int>
-      <ostype name="command">abou</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="138">
-      <string name="title">Save</string>
-      <string name="keyEquivalent">s</string>
-      <ostype name="command">save</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="137">
-      <string name="title">Save As…</string>
-      <string name="keyEquivalent">S</string>
-      <ostype name="command">svas</ostype>
-    </object>
-    <object class="IBCarbonMenuItem" id="136">
-      <string name="title">Print…</string>
-      <string name="keyEquivalent">p</string>
-      <ostype name="command">prnt</ostype>
-    </object>
-    <reference idRef="146"/>
-    <reference idRef="142"/>
-    <reference idRef="143"/>
-    <object class="IBCarbonWindow" id="166">
-      <boolean name="liveResize">TRUE</boolean>
-      <int name="scalingMode">1048576</int>
-      <string name="title">Window</string>
-      <reference name="rootControl" idRef="167"/>
-      <string name="windowRect">1001 727 1361 1207 </string>
-      <string name="ScreenRectAtEncodeTime">0 0 768 1024 </string>
-    </object>
-    <reference idRef="199"/>
-    <object class="IBCarbonMenuItem" id="135">
-      <string name="title">Page Setup…</string>
-      <string name="keyEquivalent">P</string>
-      <ostype name="command">page</ostype>
-    </object>
-    <reference idRef="144"/>
-    <object class="IBCarbonMenuItem" id="134">
-      <string name="title">Open…</string>
-      <string name="keyEquivalent">o</string>
-      <ostype name="command">open</ostype>
-    </object>
-    <object class="IBCarbonMenu" id="131">
-      <string name="title">File</string>
-      <array count="10" name="items">
-        <reference idRef="139"/>
-        <reference idRef="134"/>
-        <object class="IBCarbonMenuItem" id="133">
-          <boolean name="separator">TRUE</boolean>
-        </object>
-        <object class="IBCarbonMenuItem" id="130">
-          <string name="title">Close</string>
-          <string name="keyEquivalent">w</string>
-          <ostype name="command">clos</ostype>
-        </object>
-        <reference idRef="138"/>
-        <reference idRef="137"/>
-        <reference idRef="132"/>
-        <object class="IBCarbonMenuItem" id="128">
-          <boolean name="separator">TRUE</boolean>
-        </object>
-        <reference idRef="135"/>
-        <reference idRef="136"/>
-      </array>
-    </object>
-    <reference idRef="128"/>
-    <reference idRef="141"/>
-    <reference idRef="198"/>
-    <object class="IBCarbonMenu" id="29">
-      <string name="title">main</string>
-      <string name="name">_NSMainMenu</string>
-      <array count="4" name="items">
-        <object class="IBCarbonMenuItem" id="185">
-          <string name="title">Foo</string>
-          <object name="submenu" class="IBCarbonMenu" id="184">
-            <string name="title">Foo</string>
-            <string name="name">_NSAppleMenu</string>
-            <array count="1" name="items">
-              <reference idRef="187"/>
-            </array>
-          </object>
-        </object>
-        <object class="IBCarbonMenuItem" id="127">
-          <string name="title">File</string>
-          <reference name="submenu" idRef="131"/>
-        </object>
-        <reference idRef="152"/>
-        <reference idRef="192"/>
-      </array>
-    </object>
-    <reference idRef="184"/>
-    <reference idRef="194"/>
-    <reference idRef="195"/>
-    <reference idRef="127"/>
-    <reference idRef="147"/>
-    <reference idRef="133"/>
-    <reference idRef="149"/>
-    <reference idRef="151"/>
-    <reference idRef="190"/>
-    <reference idRef="185"/>
-    <reference idRef="197"/>
-    <reference idRef="130"/>
-    <reference idRef="191"/>
-    <reference idRef="196"/>
-  </array>
-  <array count="38" name="allParents">
-    <reference idRef="195"/>
-    <reference idRef="147"/>
-    <reference idRef="29"/>
-    <reference idRef="166"/>
-    <reference idRef="131"/>
-    <reference idRef="29"/>
-    <reference idRef="131"/>
-    <reference idRef="184"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="1"/>
-    <reference idRef="147"/>
-    <reference idRef="131"/>
-    <reference idRef="147"/>
-    <reference idRef="131"/>
-    <reference idRef="127"/>
-    <reference idRef="131"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="1"/>
-    <reference idRef="185"/>
-    <reference idRef="195"/>
-    <reference idRef="192"/>
-    <reference idRef="29"/>
-    <reference idRef="152"/>
-    <reference idRef="131"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="195"/>
-    <reference idRef="29"/>
-    <reference idRef="195"/>
-    <reference idRef="131"/>
-    <reference idRef="195"/>
-    <reference idRef="195"/>
-  </array>
-  <dictionary count="3" name="nameTable">
-    <string>File&apos;s Owner</string>
-    <reference idRef="1"/>
-    <string>MainWindow</string>
-    <reference idRef="166"/>
-    <string>MenuBar</string>
-    <reference idRef="29"/>
-  </dictionary>
-  <string name="targetFramework">IBCarbonFramework</string>
-  <unsigned_int name="nextObjectID">200</unsigned_int>
-</object>
diff --git a/ide/xcode/SampleCode/Info.plist b/ide/xcode/SampleCode/Info.plist
deleted file mode 100644
index e12ff9b..0000000
--- a/ide/xcode/SampleCode/Info.plist
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.yourcompany.SampleCode</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>CSResourcesFileMapped</key>
-	<true/>
-</dict>
-</plist>
diff --git a/ide/xcode/SampleCode/SampleCode.xcodeproj/project.pbxproj b/ide/xcode/SampleCode/SampleCode.xcodeproj/project.pbxproj
deleted file mode 100644
index 826bb6a..0000000
--- a/ide/xcode/SampleCode/SampleCode.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,1082 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 44;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		0007A8F30DB4DFF30068AF40 /* SampleXfermodes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0007A8F20DB4DFF30068AF40 /* SampleXfermodes.cpp */; };
-		0008AEE10DABF08F00477EFB /* libgiflib.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 0008AEDE0DABF01400477EFB /* libgiflib.a */; };
-		000A1CB00DA522ED003DAC04 /* SamplePolyToPoly.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000A1CAF0DA522ED003DAC04 /* SamplePolyToPoly.cpp */; };
-		000DC0C60D63796E00854F5A /* SampleTextAlpha.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000DC0C50D63796E00854F5A /* SampleTextAlpha.cpp */; };
-		001142AB0DCA20650070D0A3 /* SamplePicture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001142AA0DCA20650070D0A3 /* SamplePicture.cpp */; };
-		0017F1490D6A0A6A008D9B31 /* SampleEmboss.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0017F1460D6A0A6A008D9B31 /* SampleEmboss.cpp */; };
-		0017F14A0D6A0A6A008D9B31 /* SampleLines.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0017F1470D6A0A6A008D9B31 /* SampleLines.cpp */; };
-		0017F2CF0D6F3933008D9B31 /* libgraphics.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C440D3E999300651393 /* libgraphics.a */; };
-		0017F2D00D6F393F008D9B31 /* libcorecg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C2C0D3E999300651393 /* libcorecg.a */; };
-		0017F2D60D6F3949008D9B31 /* libviews.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C5E0D3E999300651393 /* libviews.a */; };
-		0019628A0EACB9D300447A07 /* SamplePatch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001962890EACB9D300447A07 /* SamplePatch.cpp */; };
-		001962900EACBA2A00447A07 /* SamplePageFlip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0019628F0EACBA2A00447A07 /* SamplePageFlip.cpp */; };
-		002919440DEBA08100AF67D5 /* SkBitmapFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002919430DEBA08100AF67D5 /* SkBitmapFilter.cpp */; };
-		002919510DEC39C700AF67D5 /* SkConvolutionBitmapFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002919500DEC39C700AF67D5 /* SkConvolutionBitmapFilter.cpp */; };
-		00298C2A0E7085E7005E85ED /* SampleStrokeText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00298C290E7085E7005E85ED /* SampleStrokeText.cpp */; };
-		003474ED0D5B61BA00F3F389 /* SampleVertices.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003474EC0D5B61BA00F3F389 /* SampleVertices.cpp */; };
-		003476840DF8DEC400A270A4 /* SampleCircle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003476830DF8DEC400A270A4 /* SampleCircle.cpp */; };
-		003A10170E0C29F800136848 /* SampleOverflow.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003A10160E0C29F800136848 /* SampleOverflow.cpp */; };
-		003FA70A0D58CA4D0063AD75 /* SampleMeasure.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003FA7090D58CA4D0063AD75 /* SampleMeasure.cpp */; };
-		0061A77B0DB7A7150007094E /* SampleFillType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0061A77A0DB7A7150007094E /* SampleFillType.cpp */; };
-		00648B5A0DDB15B90087F2E8 /* SampleTypeface.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00648B590DDB15B90087F2E8 /* SampleTypeface.cpp */; };
-		00685FCE0D8A16C300CD71AA /* SampleAll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C650D3E99A800651393 /* SampleAll.cpp */; };
-		006860100D8A1C8B00CD71AA /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0068600F0D8A1C8A00CD71AA /* OpenGL.framework */; };
-		006860290D8A1DFB00CD71AA /* AGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 006860280D8A1DFB00CD71AA /* AGL.framework */; };
-		0071BCEF0D746BDF00F667CE /* SampleFilter2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0071BCEE0D746BDF00F667CE /* SampleFilter2.cpp */; };
-		009A74250DA11C5D00876C03 /* libGL.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 009A740E0DA11B1F00876C03 /* libGL.a */; };
-		00B8EBFC0EB64ABC003C2F6F /* SampleDrawLooper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00B8EBFB0EB64ABC003C2F6F /* SampleDrawLooper.cpp */; };
-		00C5D1E10EBFFE4D00C6702C /* test.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00C5D1E00EBFFE4D00C6702C /* test.cpp */; };
-		00C5D1E50EC0007400C6702C /* test_drawcolor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00C5D1E40EC0007400C6702C /* test_drawcolor.cpp */; };
-		00C5D2010EC00F0300C6702C /* SampleTests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00C5D2000EC00F0300C6702C /* SampleTests.cpp */; };
-		00C5D20E0EC0106F00C6702C /* test_drawrect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00C5D1F00EC0044600C6702C /* test_drawrect.cpp */; };
-		00D12E4D0DAD3D0A003918C5 /* libanimator.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 0013C7920D94043200B41703 /* libanimator.a */; };
-		00D315710D5A5B1D004B2209 /* SampleBitmapRect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00D315700D5A5B1D004B2209 /* SampleBitmapRect.cpp */; };
-		00ED8C7C0D3E99A800651393 /* SampleApp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C660D3E99A800651393 /* SampleApp.cpp */; };
-		00ED8C7D0D3E99A800651393 /* SampleArc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C670D3E99A800651393 /* SampleArc.cpp */; };
-		00ED8C7E0D3E99A800651393 /* SampleCamera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C680D3E99A800651393 /* SampleCamera.cpp */; };
-		00ED8C7F0D3E99A800651393 /* SampleCull.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6A0D3E99A800651393 /* SampleCull.cpp */; };
-		00ED8C800D3E99A800651393 /* SampleDither.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6B0D3E99A800651393 /* SampleDither.cpp */; };
-		00ED8C810D3E99A800651393 /* SampleEncode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6C0D3E99A800651393 /* SampleEncode.cpp */; };
-		00ED8C820D3E99A800651393 /* SampleFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6D0D3E99A800651393 /* SampleFilter.cpp */; };
-		00ED8C830D3E99A800651393 /* SampleFontCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6E0D3E99A800651393 /* SampleFontCache.cpp */; };
-		00ED8C840D3E99A800651393 /* SampleImage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C6F0D3E99A800651393 /* SampleImage.cpp */; };
-		00ED8C850D3E99A800651393 /* SampleImageDir.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C700D3E99A800651393 /* SampleImageDir.cpp */; };
-		00ED8C860D3E99A800651393 /* SampleLayers.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C710D3E99A800651393 /* SampleLayers.cpp */; };
-		00ED8C870D3E99A800651393 /* SamplePath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C720D3E99A800651393 /* SamplePath.cpp */; };
-		00ED8C880D3E99A800651393 /* SamplePathEffects.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C730D3E99A800651393 /* SamplePathEffects.cpp */; };
-		00ED8C890D3E99A800651393 /* SamplePoints.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C740D3E99A800651393 /* SamplePoints.cpp */; };
-		00ED8C8A0D3E99A800651393 /* SampleRegion.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C750D3E99A800651393 /* SampleRegion.cpp */; };
-		00ED8C8B0D3E99A800651393 /* SampleShaders.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C760D3E99A800651393 /* SampleShaders.cpp */; };
-		00ED8C8C0D3E99A800651393 /* SampleText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C770D3E99A800651393 /* SampleText.cpp */; };
-		00ED8C8D0D3E99A800651393 /* SampleTextEffects.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C780D3E99A800651393 /* SampleTextEffects.cpp */; };
-		00ED8C8E0D3E99A800651393 /* SampleTextOnPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C790D3E99A800651393 /* SampleTextOnPath.cpp */; };
-		00ED8C8F0D3E99A800651393 /* SampleTiling.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00ED8C7A0D3E99A800651393 /* SampleTiling.cpp */; };
-		00ED8CD70D3E9FD900651393 /* libexpat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C320D3E999300651393 /* libexpat.a */; };
-		00ED8CD80D3E9FDB00651393 /* libfreetype.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C380D3E999300651393 /* libfreetype.a */; };
-		00ED8CDB0D3E9FE300651393 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C480D3E999300651393 /* libjpeg.a */; };
-		00ED8CDC0D3E9FE500651393 /* liblibpng.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C4C0D3E999300651393 /* liblibpng.a */; };
-		00ED8CDD0D3E9FE700651393 /* libports-mac.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C520D3E999300651393 /* libports-mac.a */; };
-		00ED8CDE0D3E9FEA00651393 /* libports.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C580D3E999300651393 /* libports.a */; };
-		00ED8CE00D3E9FEF00651393 /* libzlib.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00ED8C620D3E999300651393 /* libzlib.a */; };
-		00F9D6860E7F51680031AAA2 /* SkSetPoly3To3_A.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00F9D6850E7F51670031AAA2 /* SkSetPoly3To3_A.cpp */; };
-		8D0C4E8D0486CD37000505A6 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */; };
-		8D0C4E8E0486CD37000505A6 /* main.nib in Resources */ = {isa = PBXBuildFile; fileRef = 02345980000FD03B11CA0E72 /* main.nib */; };
-		8D0C4E920486CD37000505A6 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 20286C33FDCF999611CA2CEA /* Carbon.framework */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXContainerItemProxy section */
-		0008AEDD0DABF01400477EFB /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 0008AED90DABF01300477EFB /* giflib.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = giflib;
-		};
-		0008AF0F0DABF9BD00477EFB /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 0008AED90DABF01300477EFB /* giflib.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = giflib;
-		};
-		0013C7910D94043200B41703 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 0013C78A0D94043200B41703 /* animator.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = animator;
-		};
-		0013C7940D94044800B41703 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 0013C78A0D94043200B41703 /* animator.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = animator;
-		};
-		009A740D0DA11B1F00876C03 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 009A74060DA11B1F00876C03 /* GL.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = GL;
-		};
-		009A741C0DA11BAE00876C03 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 009A74060DA11B1F00876C03 /* GL.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = GL;
-		};
-		00ED8C2B0D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C060D3E999300651393 /* corecg.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = corecg;
-		};
-		00ED8C310D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C090D3E999300651393 /* expat.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = expat;
-		};
-		00ED8C370D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C0C0D3E999300651393 /* freetype2.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = freetype;
-		};
-		00ED8C430D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C120D3E999300651393 /* graphics.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC06F0554671400DB518D;
-			remoteInfo = graphics;
-		};
-		00ED8C470D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C150D3E999300651393 /* jpeg.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = jpeg;
-		};
-		00ED8C4B0D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C180D3E999300651393 /* libpng.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = libpng;
-		};
-		00ED8C510D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C1B0D3E999300651393 /* ports-mac.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = "ports-mac";
-		};
-		00ED8C570D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C1E0D3E999300651393 /* ports.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = ports;
-		};
-		00ED8C5D0D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C210D3E999300651393 /* views.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = views;
-		};
-		00ED8C610D3E999300651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C240D3E999300651393 /* zlib.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = zlib;
-		};
-		00ED8C9D0D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C1B0D3E999300651393 /* ports-mac.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = "ports-mac";
-		};
-		00ED8C9F0D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C1E0D3E999300651393 /* ports.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = ports;
-		};
-		00ED8CA10D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C150D3E999300651393 /* jpeg.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = jpeg;
-		};
-		00ED8CA30D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C120D3E999300651393 /* graphics.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC06E0554671400DB518D;
-			remoteInfo = graphics;
-		};
-		00ED8CA70D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C090D3E999300651393 /* expat.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = expat;
-		};
-		00ED8CA90D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C210D3E999300651393 /* views.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = views;
-		};
-		00ED8CAB0D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C060D3E999300651393 /* corecg.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = corecg;
-		};
-		00ED8CAD0D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C240D3E999300651393 /* zlib.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = zlib;
-		};
-		00ED8CAF0D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C0C0D3E999300651393 /* freetype2.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = freetype;
-		};
-		00ED8CB10D3E9AFA00651393 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = 00ED8C180D3E999300651393 /* libpng.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = libpng;
-		};
-/* End PBXContainerItemProxy section */
-
-/* Begin PBXFileReference section */
-		0007A8F20DB4DFF30068AF40 /* SampleXfermodes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleXfermodes.cpp; path = ../../../tests/skia/SampleCode/SampleXfermodes.cpp; sourceTree = SOURCE_ROOT; };
-		0008AED90DABF01300477EFB /* giflib.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = giflib.xcodeproj; path = ../giflib.xcodeproj; sourceTree = SOURCE_ROOT; };
-		000A1CAF0DA522ED003DAC04 /* SamplePolyToPoly.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePolyToPoly.cpp; path = ../../../tests/skia/SampleCode/SamplePolyToPoly.cpp; sourceTree = SOURCE_ROOT; };
-		000DC0C50D63796E00854F5A /* SampleTextAlpha.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTextAlpha.cpp; path = ../../../tests/skia/SampleCode/SampleTextAlpha.cpp; sourceTree = SOURCE_ROOT; };
-		001142AA0DCA20650070D0A3 /* SamplePicture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePicture.cpp; path = ../../../tests/skia/SampleCode/SamplePicture.cpp; sourceTree = SOURCE_ROOT; };
-		0013C78A0D94043200B41703 /* animator.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = animator.xcodeproj; path = ../animator.xcodeproj; sourceTree = SOURCE_ROOT; };
-		0017F1460D6A0A6A008D9B31 /* SampleEmboss.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleEmboss.cpp; path = ../../../tests/skia/SampleCode/SampleEmboss.cpp; sourceTree = SOURCE_ROOT; };
-		0017F1470D6A0A6A008D9B31 /* SampleLines.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleLines.cpp; path = ../../../tests/skia/SampleCode/SampleLines.cpp; sourceTree = SOURCE_ROOT; };
-		0017F1510D6A0A8A008D9B31 /* SkGeometry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkGeometry.h; path = ../../../libs/graphics/sgl/SkGeometry.h; sourceTree = SOURCE_ROOT; };
-		001962890EACB9D300447A07 /* SamplePatch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePatch.cpp; path = ../../../tests/skia/SampleCode/SamplePatch.cpp; sourceTree = SOURCE_ROOT; };
-		0019628F0EACBA2A00447A07 /* SamplePageFlip.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePageFlip.cpp; path = ../../../tests/skia/SampleCode/SamplePageFlip.cpp; sourceTree = SOURCE_ROOT; };
-		002919430DEBA08100AF67D5 /* SkBitmapFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapFilter.cpp; path = ../../../libs/graphics/sgl/SkBitmapFilter.cpp; sourceTree = SOURCE_ROOT; };
-		002919500DEC39C700AF67D5 /* SkConvolutionBitmapFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkConvolutionBitmapFilter.cpp; path = ../../../libs/graphics/effects/SkConvolutionBitmapFilter.cpp; sourceTree = SOURCE_ROOT; };
-		00298C290E7085E7005E85ED /* SampleStrokeText.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleStrokeText.cpp; path = ../../../tests/skia/SampleCode/SampleStrokeText.cpp; sourceTree = SOURCE_ROOT; };
-		003474EC0D5B61BA00F3F389 /* SampleVertices.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleVertices.cpp; path = ../../../tests/skia/SampleCode/SampleVertices.cpp; sourceTree = SOURCE_ROOT; };
-		003476830DF8DEC400A270A4 /* SampleCircle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleCircle.cpp; path = ../../../tests/skia/SampleCode/SampleCircle.cpp; sourceTree = SOURCE_ROOT; };
-		003A10160E0C29F800136848 /* SampleOverflow.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleOverflow.cpp; path = ../../../tests/skia/SampleCode/SampleOverflow.cpp; sourceTree = SOURCE_ROOT; };
-		003FA7090D58CA4D0063AD75 /* SampleMeasure.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleMeasure.cpp; path = ../../../tests/skia/SampleCode/SampleMeasure.cpp; sourceTree = SOURCE_ROOT; };
-		0041F4860DE1157900C74590 /* SkFontHost_FONTPATH.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_FONTPATH.cpp; path = ../../../libs/graphics/ports/SkFontHost_FONTPATH.cpp; sourceTree = SOURCE_ROOT; };
-		0041F4870DE1157900C74590 /* SkFontHost_none.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_none.cpp; path = ../../../libs/graphics/ports/SkFontHost_none.cpp; sourceTree = SOURCE_ROOT; };
-		0041F4880DE1157900C74590 /* SkFontHost_win.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_win.cpp; path = ../../../libs/graphics/ports/SkFontHost_win.cpp; sourceTree = SOURCE_ROOT; };
-		0061A77A0DB7A7150007094E /* SampleFillType.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleFillType.cpp; path = ../../../tests/skia/SampleCode/SampleFillType.cpp; sourceTree = SOURCE_ROOT; };
-		00648B590DDB15B90087F2E8 /* SampleTypeface.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTypeface.cpp; path = ../../../tests/skia/SampleCode/SampleTypeface.cpp; sourceTree = SOURCE_ROOT; };
-		0068600F0D8A1C8A00CD71AA /* OpenGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGL.framework; path = SDKs/MacOSX10.5.sdk/System/Library/Frameworks/OpenGL.framework; sourceTree = DEVELOPER_DIR; };
-		006860280D8A1DFB00CD71AA /* AGL.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AGL.framework; path = SDKs/MacOSX10.5.sdk/System/Library/Frameworks/AGL.framework; sourceTree = DEVELOPER_DIR; };
-		0071BCEE0D746BDF00F667CE /* SampleFilter2.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleFilter2.cpp; path = ../../../tests/skia/SampleCode/SampleFilter2.cpp; sourceTree = SOURCE_ROOT; };
-		009A74060DA11B1F00876C03 /* GL.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = GL.xcodeproj; path = ../GL.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00B8EBDF0EB63983003C2F6F /* SkLayerDrawLooper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkLayerDrawLooper.cpp; path = ../../../libs/graphics/effects/SkLayerDrawLooper.cpp; sourceTree = SOURCE_ROOT; };
-		00B8EBFB0EB64ABC003C2F6F /* SampleDrawLooper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleDrawLooper.cpp; path = ../../../tests/skia/SampleCode/SampleDrawLooper.cpp; sourceTree = SOURCE_ROOT; };
-		00C5D1DD0EBFFC5C00C6702C /* test.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = test.h; path = ../../../tests/skia/test/test.h; sourceTree = SOURCE_ROOT; };
-		00C5D1E00EBFFE4D00C6702C /* test.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = test.cpp; path = ../../../tests/skia/test/test.cpp; sourceTree = SOURCE_ROOT; };
-		00C5D1E40EC0007400C6702C /* test_drawcolor.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = test_drawcolor.cpp; path = ../../../tests/skia/test/test_drawcolor.cpp; sourceTree = SOURCE_ROOT; };
-		00C5D1F00EC0044600C6702C /* test_drawrect.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = test_drawrect.cpp; path = ../../../tests/skia/test/test_drawrect.cpp; sourceTree = SOURCE_ROOT; };
-		00C5D2000EC00F0300C6702C /* SampleTests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTests.cpp; path = ../../../tests/skia/SampleCode/SampleTests.cpp; sourceTree = SOURCE_ROOT; };
-		00D315700D5A5B1D004B2209 /* SampleBitmapRect.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleBitmapRect.cpp; path = ../../../tests/skia/SampleCode/SampleBitmapRect.cpp; sourceTree = SOURCE_ROOT; };
-		00DB0B0D0E06CEC80061DE48 /* SampleNinePatch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleNinePatch.cpp; path = ../../../tests/skia/SampleCode/SampleNinePatch.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C060D3E999300651393 /* corecg.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = corecg.xcodeproj; path = ../corecg.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C090D3E999300651393 /* expat.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = expat.xcodeproj; path = ../expat.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C0C0D3E999300651393 /* freetype2.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = freetype2.xcodeproj; path = ../freetype2.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C120D3E999300651393 /* graphics.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = graphics.xcodeproj; path = ../graphics.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C150D3E999300651393 /* jpeg.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = jpeg.xcodeproj; path = ../jpeg.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C180D3E999300651393 /* libpng.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = libpng.xcodeproj; path = ../libpng.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C1B0D3E999300651393 /* ports-mac.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = "ports-mac.xcodeproj"; path = "../ports-mac.xcodeproj"; sourceTree = SOURCE_ROOT; };
-		00ED8C1E0D3E999300651393 /* ports.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = ports.xcodeproj; path = ../ports.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C210D3E999300651393 /* views.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = views.xcodeproj; path = ../views.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C240D3E999300651393 /* zlib.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = zlib.xcodeproj; path = ../zlib.xcodeproj; sourceTree = SOURCE_ROOT; };
-		00ED8C650D3E99A800651393 /* SampleAll.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleAll.cpp; path = ../../../tests/skia/SampleCode/SampleAll.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C660D3E99A800651393 /* SampleApp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleApp.cpp; path = ../../../tests/skia/SampleCode/SampleApp.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C670D3E99A800651393 /* SampleArc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleArc.cpp; path = ../../../tests/skia/SampleCode/SampleArc.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C680D3E99A800651393 /* SampleCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleCamera.cpp; path = ../../../tests/skia/SampleCode/SampleCamera.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C690D3E99A800651393 /* SampleCode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SampleCode.h; path = ../../../tests/skia/SampleCode/SampleCode.h; sourceTree = SOURCE_ROOT; };
-		00ED8C6A0D3E99A800651393 /* SampleCull.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleCull.cpp; path = ../../../tests/skia/SampleCode/SampleCull.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C6B0D3E99A800651393 /* SampleDither.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleDither.cpp; path = ../../../tests/skia/SampleCode/SampleDither.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C6C0D3E99A800651393 /* SampleEncode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleEncode.cpp; path = ../../../tests/skia/SampleCode/SampleEncode.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C6D0D3E99A800651393 /* SampleFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleFilter.cpp; path = ../../../tests/skia/SampleCode/SampleFilter.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C6E0D3E99A800651393 /* SampleFontCache.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleFontCache.cpp; path = ../../../tests/skia/SampleCode/SampleFontCache.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C6F0D3E99A800651393 /* SampleImage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleImage.cpp; path = ../../../tests/skia/SampleCode/SampleImage.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C700D3E99A800651393 /* SampleImageDir.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleImageDir.cpp; path = ../../../tests/skia/SampleCode/SampleImageDir.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C710D3E99A800651393 /* SampleLayers.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleLayers.cpp; path = ../../../tests/skia/SampleCode/SampleLayers.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C720D3E99A800651393 /* SamplePath.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePath.cpp; path = ../../../tests/skia/SampleCode/SamplePath.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C730D3E99A800651393 /* SamplePathEffects.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePathEffects.cpp; path = ../../../tests/skia/SampleCode/SamplePathEffects.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C740D3E99A800651393 /* SamplePoints.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SamplePoints.cpp; path = ../../../tests/skia/SampleCode/SamplePoints.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C750D3E99A800651393 /* SampleRegion.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleRegion.cpp; path = ../../../tests/skia/SampleCode/SampleRegion.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C760D3E99A800651393 /* SampleShaders.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleShaders.cpp; path = ../../../tests/skia/SampleCode/SampleShaders.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C770D3E99A800651393 /* SampleText.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleText.cpp; path = ../../../tests/skia/SampleCode/SampleText.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C780D3E99A800651393 /* SampleTextEffects.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTextEffects.cpp; path = ../../../tests/skia/SampleCode/SampleTextEffects.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C790D3E99A800651393 /* SampleTextOnPath.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTextOnPath.cpp; path = ../../../tests/skia/SampleCode/SampleTextOnPath.cpp; sourceTree = SOURCE_ROOT; };
-		00ED8C7A0D3E99A800651393 /* SampleTiling.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SampleTiling.cpp; path = ../../../tests/skia/SampleCode/SampleTiling.cpp; sourceTree = SOURCE_ROOT; };
-		00F9D6230E7EC9E60031AAA2 /* SkSetPoly3To3.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkSetPoly3To3.cpp; path = ../../../libs/corecg/SkSetPoly3To3.cpp; sourceTree = SOURCE_ROOT; };
-		00F9D6540E7EEE580031AAA2 /* SkSetPoly3To3_D.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkSetPoly3To3_D.cpp; path = ../../../libs/corecg/SkSetPoly3To3_D.cpp; sourceTree = SOURCE_ROOT; };
-		00F9D6850E7F51670031AAA2 /* SkSetPoly3To3_A.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkSetPoly3To3_A.cpp; path = ../../../libs/corecg/SkSetPoly3To3_A.cpp; sourceTree = SOURCE_ROOT; };
-		0867D6ABFE840B52C02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		1870340FFE93FCAF11CA0CD7 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/main.nib; sourceTree = "<group>"; };
-		20286C33FDCF999611CA2CEA /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = /System/Library/Frameworks/Carbon.framework; sourceTree = "<absolute>"; };
-		8D0C4E960486CD37000505A6 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
-		8D0C4E970486CD37000505A6 /* SampleCode.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SampleCode.app; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		8D0C4E910486CD37000505A6 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				00ED8CD70D3E9FD900651393 /* libexpat.a in Frameworks */,
-				00ED8CD80D3E9FDB00651393 /* libfreetype.a in Frameworks */,
-				00ED8CDB0D3E9FE300651393 /* libjpeg.a in Frameworks */,
-				00ED8CDC0D3E9FE500651393 /* liblibpng.a in Frameworks */,
-				00ED8CDD0D3E9FE700651393 /* libports-mac.a in Frameworks */,
-				00ED8CDE0D3E9FEA00651393 /* libports.a in Frameworks */,
-				00ED8CE00D3E9FEF00651393 /* libzlib.a in Frameworks */,
-				8D0C4E920486CD37000505A6 /* Carbon.framework in Frameworks */,
-				0017F2CF0D6F3933008D9B31 /* libgraphics.a in Frameworks */,
-				0017F2D00D6F393F008D9B31 /* libcorecg.a in Frameworks */,
-				0017F2D60D6F3949008D9B31 /* libviews.a in Frameworks */,
-				006860100D8A1C8B00CD71AA /* OpenGL.framework in Frameworks */,
-				006860290D8A1DFB00CD71AA /* AGL.framework in Frameworks */,
-				009A74250DA11C5D00876C03 /* libGL.a in Frameworks */,
-				0008AEE10DABF08F00477EFB /* libgiflib.a in Frameworks */,
-				00D12E4D0DAD3D0A003918C5 /* libanimator.a in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		0008AEDA0DABF01300477EFB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				0008AEDE0DABF01400477EFB /* libgiflib.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		0013C78B0D94043200B41703 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				0013C7920D94043200B41703 /* libanimator.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		0041F4850DE1154C00C74590 /* fonthosts */ = {
-			isa = PBXGroup;
-			children = (
-				0041F4860DE1157900C74590 /* SkFontHost_FONTPATH.cpp */,
-				0041F4870DE1157900C74590 /* SkFontHost_none.cpp */,
-				0041F4880DE1157900C74590 /* SkFontHost_win.cpp */,
-			);
-			name = fonthosts;
-			sourceTree = "<group>";
-		};
-		009A74070DA11B1F00876C03 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				009A740E0DA11B1F00876C03 /* libGL.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00C5D1DB0EBFF83100C6702C /* tests */ = {
-			isa = PBXGroup;
-			children = (
-				00C5D1E00EBFFE4D00C6702C /* test.cpp */,
-				00C5D1F00EC0044600C6702C /* test_drawrect.cpp */,
-				00C5D1E40EC0007400C6702C /* test_drawcolor.cpp */,
-				00C5D1DD0EBFFC5C00C6702C /* test.h */,
-			);
-			name = tests;
-			sourceTree = "<group>";
-		};
-		00ED8C070D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C2C0D3E999300651393 /* libcorecg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C0A0D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C320D3E999300651393 /* libexpat.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C0D0D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C380D3E999300651393 /* libfreetype.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C130D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C440D3E999300651393 /* libgraphics.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C160D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C480D3E999300651393 /* libjpeg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C190D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C4C0D3E999300651393 /* liblibpng.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C1C0D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C520D3E999300651393 /* libports-mac.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C1F0D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C580D3E999300651393 /* libports.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C220D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C5E0D3E999300651393 /* libviews.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		00ED8C250D3E999300651393 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				00ED8C620D3E999300651393 /* libzlib.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		195DF8CFFE9D517E11CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				8D0C4E970486CD37000505A6 /* SampleCode.app */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		20286C29FDCF999611CA2CEA /* SampleCode */ = {
-			isa = PBXGroup;
-			children = (
-				00C5D1DB0EBFF83100C6702C /* tests */,
-				00F9D6230E7EC9E60031AAA2 /* SkSetPoly3To3.cpp */,
-				00B8EBDF0EB63983003C2F6F /* SkLayerDrawLooper.cpp */,
-				00F9D6850E7F51670031AAA2 /* SkSetPoly3To3_A.cpp */,
-				00F9D6540E7EEE580031AAA2 /* SkSetPoly3To3_D.cpp */,
-				002919500DEC39C700AF67D5 /* SkConvolutionBitmapFilter.cpp */,
-				002919430DEBA08100AF67D5 /* SkBitmapFilter.cpp */,
-				0041F4850DE1154C00C74590 /* fonthosts */,
-				0008AED90DABF01300477EFB /* giflib.xcodeproj */,
-				009A74060DA11B1F00876C03 /* GL.xcodeproj */,
-				0013C78A0D94043200B41703 /* animator.xcodeproj */,
-				00ED8C060D3E999300651393 /* corecg.xcodeproj */,
-				00ED8C090D3E999300651393 /* expat.xcodeproj */,
-				00ED8C0C0D3E999300651393 /* freetype2.xcodeproj */,
-				00ED8C120D3E999300651393 /* graphics.xcodeproj */,
-				00ED8C150D3E999300651393 /* jpeg.xcodeproj */,
-				00ED8C180D3E999300651393 /* libpng.xcodeproj */,
-				00ED8C1B0D3E999300651393 /* ports-mac.xcodeproj */,
-				00ED8C1E0D3E999300651393 /* ports.xcodeproj */,
-				00ED8C210D3E999300651393 /* views.xcodeproj */,
-				00ED8C240D3E999300651393 /* zlib.xcodeproj */,
-				20286C2AFDCF999611CA2CEA /* Sources */,
-				20286C2CFDCF999611CA2CEA /* Resources */,
-				20286C32FDCF999611CA2CEA /* External Frameworks and Libraries */,
-				195DF8CFFE9D517E11CA2CBB /* Products */,
-			);
-			name = SampleCode;
-			sourceTree = "<group>";
-		};
-		20286C2AFDCF999611CA2CEA /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				001962890EACB9D300447A07 /* SamplePatch.cpp */,
-				00298C290E7085E7005E85ED /* SampleStrokeText.cpp */,
-				001142AA0DCA20650070D0A3 /* SamplePicture.cpp */,
-				0007A8F20DB4DFF30068AF40 /* SampleXfermodes.cpp */,
-				000A1CAF0DA522ED003DAC04 /* SamplePolyToPoly.cpp */,
-				0017F1510D6A0A8A008D9B31 /* SkGeometry.h */,
-				0017F1460D6A0A6A008D9B31 /* SampleEmboss.cpp */,
-				0017F1470D6A0A6A008D9B31 /* SampleLines.cpp */,
-				00ED8C650D3E99A800651393 /* SampleAll.cpp */,
-				00ED8C660D3E99A800651393 /* SampleApp.cpp */,
-				00ED8C670D3E99A800651393 /* SampleArc.cpp */,
-				00ED8C680D3E99A800651393 /* SampleCamera.cpp */,
-				00ED8C690D3E99A800651393 /* SampleCode.h */,
-				00ED8C6A0D3E99A800651393 /* SampleCull.cpp */,
-				0061A77A0DB7A7150007094E /* SampleFillType.cpp */,
-				00ED8C6B0D3E99A800651393 /* SampleDither.cpp */,
-				00648B590DDB15B90087F2E8 /* SampleTypeface.cpp */,
-				003FA7090D58CA4D0063AD75 /* SampleMeasure.cpp */,
-				00ED8C6C0D3E99A800651393 /* SampleEncode.cpp */,
-				00ED8C6D0D3E99A800651393 /* SampleFilter.cpp */,
-				00ED8C6E0D3E99A800651393 /* SampleFontCache.cpp */,
-				0019628F0EACBA2A00447A07 /* SamplePageFlip.cpp */,
-				00B8EBFB0EB64ABC003C2F6F /* SampleDrawLooper.cpp */,
-				00ED8C6F0D3E99A800651393 /* SampleImage.cpp */,
-				00ED8C700D3E99A800651393 /* SampleImageDir.cpp */,
-				0071BCEE0D746BDF00F667CE /* SampleFilter2.cpp */,
-				00D315700D5A5B1D004B2209 /* SampleBitmapRect.cpp */,
-				003474EC0D5B61BA00F3F389 /* SampleVertices.cpp */,
-				000DC0C50D63796E00854F5A /* SampleTextAlpha.cpp */,
-				00ED8C710D3E99A800651393 /* SampleLayers.cpp */,
-				00C5D2000EC00F0300C6702C /* SampleTests.cpp */,
-				00ED8C720D3E99A800651393 /* SamplePath.cpp */,
-				00ED8C730D3E99A800651393 /* SamplePathEffects.cpp */,
-				00ED8C740D3E99A800651393 /* SamplePoints.cpp */,
-				00ED8C750D3E99A800651393 /* SampleRegion.cpp */,
-				00ED8C760D3E99A800651393 /* SampleShaders.cpp */,
-				00ED8C770D3E99A800651393 /* SampleText.cpp */,
-				00ED8C780D3E99A800651393 /* SampleTextEffects.cpp */,
-				00ED8C790D3E99A800651393 /* SampleTextOnPath.cpp */,
-				00ED8C7A0D3E99A800651393 /* SampleTiling.cpp */,
-				003476830DF8DEC400A270A4 /* SampleCircle.cpp */,
-				003A10160E0C29F800136848 /* SampleOverflow.cpp */,
-				00DB0B0D0E06CEC80061DE48 /* SampleNinePatch.cpp */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		20286C2CFDCF999611CA2CEA /* Resources */ = {
-			isa = PBXGroup;
-			children = (
-				8D0C4E960486CD37000505A6 /* Info.plist */,
-				0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */,
-				02345980000FD03B11CA0E72 /* main.nib */,
-			);
-			name = Resources;
-			sourceTree = "<group>";
-		};
-		20286C32FDCF999611CA2CEA /* External Frameworks and Libraries */ = {
-			isa = PBXGroup;
-			children = (
-				006860280D8A1DFB00CD71AA /* AGL.framework */,
-				0068600F0D8A1C8A00CD71AA /* OpenGL.framework */,
-				20286C33FDCF999611CA2CEA /* Carbon.framework */,
-			);
-			name = "External Frameworks and Libraries";
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		8D0C4E890486CD37000505A6 /* SampleCode */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = C0E91AC508A95435008D54AB /* Build configuration list for PBXNativeTarget "SampleCode" */;
-			buildPhases = (
-				8D0C4E8C0486CD37000505A6 /* Resources */,
-				8D0C4E8F0486CD37000505A6 /* Sources */,
-				8D0C4E910486CD37000505A6 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-				00ED8C9E0D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CA00D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CA20D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CA40D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CA80D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CAA0D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CAC0D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CAE0D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CB00D3E9AFA00651393 /* PBXTargetDependency */,
-				00ED8CB20D3E9AFA00651393 /* PBXTargetDependency */,
-				0013C7950D94044800B41703 /* PBXTargetDependency */,
-				009A741D0DA11BAE00876C03 /* PBXTargetDependency */,
-				0008AF100DABF9BD00477EFB /* PBXTargetDependency */,
-			);
-			name = SampleCode;
-			productInstallPath = "$(HOME)/Applications";
-			productName = SampleCode;
-			productReference = 8D0C4E970486CD37000505A6 /* SampleCode.app */;
-			productType = "com.apple.product-type.application";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		20286C28FDCF999611CA2CEA /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = C0E91AC908A95435008D54AB /* Build configuration list for PBXProject "SampleCode" */;
-			compatibilityVersion = "Xcode 3.0";
-			hasScannedForEncodings = 1;
-			mainGroup = 20286C29FDCF999611CA2CEA /* SampleCode */;
-			projectDirPath = "";
-			projectReferences = (
-				{
-					ProductGroup = 0013C78B0D94043200B41703 /* Products */;
-					ProjectRef = 0013C78A0D94043200B41703 /* animator.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C070D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C060D3E999300651393 /* corecg.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C0A0D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C090D3E999300651393 /* expat.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C0D0D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C0C0D3E999300651393 /* freetype2.xcodeproj */;
-				},
-				{
-					ProductGroup = 0008AEDA0DABF01300477EFB /* Products */;
-					ProjectRef = 0008AED90DABF01300477EFB /* giflib.xcodeproj */;
-				},
-				{
-					ProductGroup = 009A74070DA11B1F00876C03 /* Products */;
-					ProjectRef = 009A74060DA11B1F00876C03 /* GL.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C130D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C120D3E999300651393 /* graphics.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C160D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C150D3E999300651393 /* jpeg.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C190D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C180D3E999300651393 /* libpng.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C1C0D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C1B0D3E999300651393 /* ports-mac.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C1F0D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C1E0D3E999300651393 /* ports.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C220D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C210D3E999300651393 /* views.xcodeproj */;
-				},
-				{
-					ProductGroup = 00ED8C250D3E999300651393 /* Products */;
-					ProjectRef = 00ED8C240D3E999300651393 /* zlib.xcodeproj */;
-				},
-			);
-			projectRoot = "";
-			targets = (
-				8D0C4E890486CD37000505A6 /* SampleCode */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXReferenceProxy section */
-		0008AEDE0DABF01400477EFB /* libgiflib.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libgiflib.a;
-			remoteRef = 0008AEDD0DABF01400477EFB /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		0013C7920D94043200B41703 /* libanimator.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libanimator.a;
-			remoteRef = 0013C7910D94043200B41703 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		009A740E0DA11B1F00876C03 /* libGL.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libGL.a;
-			remoteRef = 009A740D0DA11B1F00876C03 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C2C0D3E999300651393 /* libcorecg.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libcorecg.a;
-			remoteRef = 00ED8C2B0D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C320D3E999300651393 /* libexpat.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libexpat.a;
-			remoteRef = 00ED8C310D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C380D3E999300651393 /* libfreetype.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libfreetype.a;
-			remoteRef = 00ED8C370D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C440D3E999300651393 /* libgraphics.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libgraphics.a;
-			remoteRef = 00ED8C430D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C480D3E999300651393 /* libjpeg.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libjpeg.a;
-			remoteRef = 00ED8C470D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C4C0D3E999300651393 /* liblibpng.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = liblibpng.a;
-			remoteRef = 00ED8C4B0D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C520D3E999300651393 /* libports-mac.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = "libports-mac.a";
-			remoteRef = 00ED8C510D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C580D3E999300651393 /* libports.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libports.a;
-			remoteRef = 00ED8C570D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C5E0D3E999300651393 /* libviews.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libviews.a;
-			remoteRef = 00ED8C5D0D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		00ED8C620D3E999300651393 /* libzlib.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libzlib.a;
-			remoteRef = 00ED8C610D3E999300651393 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-/* End PBXReferenceProxy section */
-
-/* Begin PBXResourcesBuildPhase section */
-		8D0C4E8C0486CD37000505A6 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				8D0C4E8D0486CD37000505A6 /* InfoPlist.strings in Resources */,
-				8D0C4E8E0486CD37000505A6 /* main.nib in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		8D0C4E8F0486CD37000505A6 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				00685FCE0D8A16C300CD71AA /* SampleAll.cpp in Sources */,
-				00ED8C7C0D3E99A800651393 /* SampleApp.cpp in Sources */,
-				00ED8C7F0D3E99A800651393 /* SampleCull.cpp in Sources */,
-				00ED8C820D3E99A800651393 /* SampleFilter.cpp in Sources */,
-				00ED8C830D3E99A800651393 /* SampleFontCache.cpp in Sources */,
-				00ED8C870D3E99A800651393 /* SamplePath.cpp in Sources */,
-				00ED8C8A0D3E99A800651393 /* SampleRegion.cpp in Sources */,
-				00ED8C8B0D3E99A800651393 /* SampleShaders.cpp in Sources */,
-				00ED8C8C0D3E99A800651393 /* SampleText.cpp in Sources */,
-				003FA70A0D58CA4D0063AD75 /* SampleMeasure.cpp in Sources */,
-				00ED8C8D0D3E99A800651393 /* SampleTextEffects.cpp in Sources */,
-				0017F1490D6A0A6A008D9B31 /* SampleEmboss.cpp in Sources */,
-				0017F14A0D6A0A6A008D9B31 /* SampleLines.cpp in Sources */,
-				0071BCEF0D746BDF00F667CE /* SampleFilter2.cpp in Sources */,
-				00D315710D5A5B1D004B2209 /* SampleBitmapRect.cpp in Sources */,
-				00ED8C7E0D3E99A800651393 /* SampleCamera.cpp in Sources */,
-				003474ED0D5B61BA00F3F389 /* SampleVertices.cpp in Sources */,
-				000DC0C60D63796E00854F5A /* SampleTextAlpha.cpp in Sources */,
-				00ED8C8F0D3E99A800651393 /* SampleTiling.cpp in Sources */,
-				00ED8C890D3E99A800651393 /* SamplePoints.cpp in Sources */,
-				00ED8C880D3E99A800651393 /* SamplePathEffects.cpp in Sources */,
-				00ED8C8E0D3E99A800651393 /* SampleTextOnPath.cpp in Sources */,
-				00648B5A0DDB15B90087F2E8 /* SampleTypeface.cpp in Sources */,
-				00ED8C840D3E99A800651393 /* SampleImage.cpp in Sources */,
-				0007A8F30DB4DFF30068AF40 /* SampleXfermodes.cpp in Sources */,
-				002919440DEBA08100AF67D5 /* SkBitmapFilter.cpp in Sources */,
-				002919510DEC39C700AF67D5 /* SkConvolutionBitmapFilter.cpp in Sources */,
-				001142AB0DCA20650070D0A3 /* SamplePicture.cpp in Sources */,
-				00298C2A0E7085E7005E85ED /* SampleStrokeText.cpp in Sources */,
-				00ED8C810D3E99A800651393 /* SampleEncode.cpp in Sources */,
-				000A1CB00DA522ED003DAC04 /* SamplePolyToPoly.cpp in Sources */,
-				00F9D6860E7F51680031AAA2 /* SkSetPoly3To3_A.cpp in Sources */,
-				0019628A0EACB9D300447A07 /* SamplePatch.cpp in Sources */,
-				001962900EACBA2A00447A07 /* SamplePageFlip.cpp in Sources */,
-				00ED8C860D3E99A800651393 /* SampleLayers.cpp in Sources */,
-				00C5D1E10EBFFE4D00C6702C /* test.cpp in Sources */,
-				00C5D1E50EC0007400C6702C /* test_drawcolor.cpp in Sources */,
-				00C5D2010EC00F0300C6702C /* SampleTests.cpp in Sources */,
-				00C5D20E0EC0106F00C6702C /* test_drawrect.cpp in Sources */,
-				00ED8C850D3E99A800651393 /* SampleImageDir.cpp in Sources */,
-				003A10170E0C29F800136848 /* SampleOverflow.cpp in Sources */,
-				00ED8C800D3E99A800651393 /* SampleDither.cpp in Sources */,
-				00ED8C7D0D3E99A800651393 /* SampleArc.cpp in Sources */,
-				0061A77B0DB7A7150007094E /* SampleFillType.cpp in Sources */,
-				003476840DF8DEC400A270A4 /* SampleCircle.cpp in Sources */,
-				00B8EBFC0EB64ABC003C2F6F /* SampleDrawLooper.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXTargetDependency section */
-		0008AF100DABF9BD00477EFB /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = giflib;
-			targetProxy = 0008AF0F0DABF9BD00477EFB /* PBXContainerItemProxy */;
-		};
-		0013C7950D94044800B41703 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = animator;
-			targetProxy = 0013C7940D94044800B41703 /* PBXContainerItemProxy */;
-		};
-		009A741D0DA11BAE00876C03 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = GL;
-			targetProxy = 009A741C0DA11BAE00876C03 /* PBXContainerItemProxy */;
-		};
-		00ED8C9E0D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = "ports-mac";
-			targetProxy = 00ED8C9D0D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CA00D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = ports;
-			targetProxy = 00ED8C9F0D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CA20D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = jpeg;
-			targetProxy = 00ED8CA10D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CA40D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = graphics;
-			targetProxy = 00ED8CA30D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CA80D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = expat;
-			targetProxy = 00ED8CA70D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CAA0D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = views;
-			targetProxy = 00ED8CA90D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CAC0D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = corecg;
-			targetProxy = 00ED8CAB0D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CAE0D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = zlib;
-			targetProxy = 00ED8CAD0D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CB00D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = freetype;
-			targetProxy = 00ED8CAF0D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-		00ED8CB20D3E9AFA00651393 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = libpng;
-			targetProxy = 00ED8CB10D3E9AFA00651393 /* PBXContainerItemProxy */;
-		};
-/* End PBXTargetDependency section */
-
-/* Begin PBXVariantGroup section */
-		02345980000FD03B11CA0E72 /* main.nib */ = {
-			isa = PBXVariantGroup;
-			children = (
-				1870340FFE93FCAF11CA0CD7 /* English */,
-			);
-			name = main.nib;
-			sourceTree = "<group>";
-		};
-		0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				0867D6ABFE840B52C02AAC07 /* English */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		C0E91AC608A95435008D54AB /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(inherited)",
-					"\"$(DEVELOPER_DIR)/SDKs/MacOSX10.5.sdk/System/Library/Frameworks\"",
-				);
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PRECOMPILE_PREFIX_HEADER = NO;
-				GCC_PREFIX_HEADER = SampleCode_Prefix.pch;
-				INFOPLIST_FILE = Info.plist;
-				INSTALL_PATH = "$(HOME)/Applications";
-				PRODUCT_NAME = SampleCode;
-				WRAPPER_EXTENSION = app;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		C0E91AC708A95435008D54AB /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(inherited)",
-					"\"$(DEVELOPER_DIR)/SDKs/MacOSX10.5.sdk/System/Library/Frameworks\"",
-				);
-				GCC_MODEL_TUNING = G5;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = SampleCode_Prefix.pch;
-				INFOPLIST_FILE = Info.plist;
-				INSTALL_PATH = "$(HOME)/Applications";
-				PRODUCT_NAME = SampleCode;
-				WRAPPER_EXTENSION = app;
-			};
-			name = Release;
-		};
-		C0E91ACA08A95435008D54AB /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_DEBUGGING_SYMBOLS = full;
-				GCC_ENABLE_ASM_KEYWORD = NO;
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREFIX_HEADER = " ";
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_DEBUG,
-					SK_BUILD_FOR_MAC,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../../include/corecg/** ../../../include/graphics/**";
-			};
-			name = Debug;
-		};
-		C0E91ACB08A95435008D54AB /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_DEBUGGING_SYMBOLS = full;
-				GCC_ENABLE_ASM_KEYWORD = NO;
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PRECOMPILE_PREFIX_HEADER = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_FOUR_CHARACTER_CONSTANTS = NO;
-				GCC_WARN_PEDANTIC = NO;
-				GCC_WARN_SHADOW = YES;
-				GCC_WARN_SIGN_COMPARE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.4u.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../../include/corecg/** ../../../include/graphics/**";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		C0E91AC508A95435008D54AB /* Build configuration list for PBXNativeTarget "SampleCode" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				C0E91AC608A95435008D54AB /* Debug */,
-				C0E91AC708A95435008D54AB /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		C0E91AC908A95435008D54AB /* Build configuration list for PBXProject "SampleCode" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				C0E91ACA08A95435008D54AB /* Debug */,
-				C0E91ACB08A95435008D54AB /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 20286C28FDCF999611CA2CEA /* Project object */;
-}
diff --git a/ide/xcode/SampleCode/SampleCode_Prefix.pch b/ide/xcode/SampleCode/SampleCode_Prefix.pch
deleted file mode 100644
index 4291858..0000000
--- a/ide/xcode/SampleCode/SampleCode_Prefix.pch
+++ /dev/null
@@ -1,5 +0,0 @@
-//
-// Prefix header for all source files of the 'SampleCode' target in the 'SampleCode' project.
-//
-
-#include <Carbon/Carbon.h>
diff --git a/ide/xcode/animator.xcodeproj/project.pbxproj b/ide/xcode/animator.xcodeproj/project.pbxproj
deleted file mode 100644
index 3b3bee4..0000000
--- a/ide/xcode/animator.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,851 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		FE49EAAC09FD5DB800D28411 /* SkDrawExtraPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FE49EAAB09FD5DB800D28411 /* SkDrawExtraPathEffect.h */; };
-		FE49EB4D09FE783600D28411 /* SkDisplayNumber.h in Headers */ = {isa = PBXBuildFile; fileRef = FE49EB4C09FE783600D28411 /* SkDisplayNumber.h */; };
-		FE49EB5109FE785E00D28411 /* SkDisplayNumber.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE49EB5009FE785E00D28411 /* SkDisplayNumber.cpp */; };
-		FE49EE0C09FFDB0300D28411 /* SkAnimateProperties.h in Headers */ = {isa = PBXBuildFile; fileRef = FE49EE0B09FFDB0300D28411 /* SkAnimateProperties.h */; };
-		FE51FB850A6FDCE500ABA91D /* SkDrawSaveLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE51FB840A6FDCE400ABA91D /* SkDrawSaveLayer.h */; };
-		FE51FB8F0A6FE7DC00ABA91D /* SkDrawSaveLayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE51FB8E0A6FE7DC00ABA91D /* SkDrawSaveLayer.cpp */; };
-		FE5F49840948A5390095980F /* SkAnimateBase.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48F30948A5380095980F /* SkAnimateBase.h */; };
-		FE5F49850948A5390095980F /* SkAnimateActive.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48F60948A5380095980F /* SkAnimateActive.cpp */; };
-		FE5F49860948A5390095980F /* SkAnimateActive.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48F70948A5380095980F /* SkAnimateActive.h */; };
-		FE5F49870948A5390095980F /* SkAnimateField.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48F80948A5380095980F /* SkAnimateField.cpp */; };
-		FE5F49880948A5390095980F /* SkAnimate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48F90948A5380095980F /* SkAnimate.h */; };
-		FE5F49890948A5390095980F /* SkAnimateMaker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48FA0948A5380095980F /* SkAnimateMaker.cpp */; };
-		FE5F498A0948A5390095980F /* SkAnimateMaker.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48FB0948A5380095980F /* SkAnimateMaker.h */; };
-		FE5F498B0948A5390095980F /* SkAnimateSet.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48FE0948A5380095980F /* SkAnimateSet.cpp */; };
-		FE5F498C0948A5390095980F /* SkAnimateSet.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48FF0948A5380095980F /* SkAnimateSet.h */; };
-		FE5F498D0948A5390095980F /* SkAnimator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49000948A5380095980F /* SkAnimator.cpp */; };
-		FE5F498E0948A5390095980F /* SkAnimatorScript.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49010948A5380095980F /* SkAnimatorScript.cpp */; };
-		FE5F498F0948A5390095980F /* SkAnimatorScript.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49020948A5380095980F /* SkAnimatorScript.h */; };
-		FE5F49900948A5390095980F /* SkBase64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49030948A5380095980F /* SkBase64.cpp */; };
-		FE5F49910948A5390095980F /* SkBase64.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49040948A5380095980F /* SkBase64.h */; };
-		FE5F49920948A5390095980F /* SkBoundable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49050948A5380095980F /* SkBoundable.cpp */; };
-		FE5F49930948A5390095980F /* SkBoundable.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49060948A5380095980F /* SkBoundable.h */; };
-		FE5F49940948A5390095980F /* SkBuildCondensedInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49070948A5380095980F /* SkBuildCondensedInfo.cpp */; };
-		FE5F49970948A5390095980F /* SkDisplayable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F490A0948A5380095980F /* SkDisplayable.cpp */; };
-		FE5F49980948A5390095980F /* SkDisplayable.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F490B0948A5380095980F /* SkDisplayable.h */; };
-		FE5F49990948A5390095980F /* SkDisplayAdd.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F490C0948A5380095980F /* SkDisplayAdd.cpp */; };
-		FE5F499A0948A5390095980F /* SkDisplayAdd.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F490D0948A5380095980F /* SkDisplayAdd.h */; };
-		FE5F499B0948A5390095980F /* SkDisplayApply.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F490E0948A5380095980F /* SkDisplayApply.cpp */; };
-		FE5F499C0948A5390095980F /* SkDisplayApply.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F490F0948A5380095980F /* SkDisplayApply.h */; };
-		FE5F499D0948A5390095980F /* SkDisplayBounds.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49100948A5380095980F /* SkDisplayBounds.cpp */; };
-		FE5F499E0948A5390095980F /* SkDisplayBounds.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49110948A5380095980F /* SkDisplayBounds.h */; };
-		FE5F499F0948A5390095980F /* SkDisplayEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49120948A5380095980F /* SkDisplayEvent.cpp */; };
-		FE5F49A00948A5390095980F /* SkDisplayEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49130948A5380095980F /* SkDisplayEvent.h */; };
-		FE5F49A10948A5390095980F /* SkDisplayEvents.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49140948A5380095980F /* SkDisplayEvents.cpp */; };
-		FE5F49A20948A5390095980F /* SkDisplayEvents.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49150948A5380095980F /* SkDisplayEvents.h */; };
-		FE5F49A30948A5390095980F /* SkDisplayInclude.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49160948A5380095980F /* SkDisplayInclude.cpp */; };
-		FE5F49A40948A5390095980F /* SkDisplayInclude.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49170948A5380095980F /* SkDisplayInclude.h */; };
-		FE5F49A50948A5390095980F /* SkDisplayInput.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49180948A5380095980F /* SkDisplayInput.cpp */; };
-		FE5F49A60948A5390095980F /* SkDisplayInput.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49190948A5380095980F /* SkDisplayInput.h */; };
-		FE5F49A70948A5390095980F /* SkDisplayList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F491A0948A5380095980F /* SkDisplayList.cpp */; };
-		FE5F49A80948A5390095980F /* SkDisplayList.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F491B0948A5380095980F /* SkDisplayList.h */; };
-		FE5F49A90948A5390095980F /* SkDisplayMath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F491C0948A5380095980F /* SkDisplayMath.cpp */; };
-		FE5F49AA0948A5390095980F /* SkDisplayMath.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F491D0948A5380095980F /* SkDisplayMath.h */; };
-		FE5F49AB0948A5390095980F /* SkDisplayMovie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F491E0948A5380095980F /* SkDisplayMovie.cpp */; };
-		FE5F49AC0948A5390095980F /* SkDisplayMovie.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F491F0948A5380095980F /* SkDisplayMovie.h */; };
-		FE5F49AD0948A5390095980F /* SkDisplayPost.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49200948A5380095980F /* SkDisplayPost.cpp */; };
-		FE5F49AE0948A5390095980F /* SkDisplayPost.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49210948A5380095980F /* SkDisplayPost.h */; };
-		FE5F49AF0948A5390095980F /* SkDisplayRandom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49220948A5380095980F /* SkDisplayRandom.cpp */; };
-		FE5F49B00948A5390095980F /* SkDisplayRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49230948A5380095980F /* SkDisplayRandom.h */; };
-		FE5F49B10948A5390095980F /* SkDisplayScreenplay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49240948A5380095980F /* SkDisplayScreenplay.cpp */; };
-		FE5F49B20948A5390095980F /* SkDisplayScreenplay.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49250948A5380095980F /* SkDisplayScreenplay.h */; };
-		FE5F49B30948A5390095980F /* SkDisplayType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49260948A5380095980F /* SkDisplayType.cpp */; };
-		FE5F49B40948A5390095980F /* SkDisplayType.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49270948A5380095980F /* SkDisplayType.h */; };
-		FE5F49B50948A5390095980F /* SkDisplayTypes.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49280948A5380095980F /* SkDisplayTypes.cpp */; };
-		FE5F49B60948A5390095980F /* SkDisplayTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49290948A5380095980F /* SkDisplayTypes.h */; };
-		FE5F49B70948A5390095980F /* SkDisplayXMLParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F492A0948A5380095980F /* SkDisplayXMLParser.cpp */; };
-		FE5F49B80948A5390095980F /* SkDisplayXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F492B0948A5380095980F /* SkDisplayXMLParser.h */; };
-		FE5F49B90948A5390095980F /* SkDraw3D.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F492C0948A5380095980F /* SkDraw3D.cpp */; };
-		FE5F49BA0948A5390095980F /* SkDraw3D.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F492D0948A5380095980F /* SkDraw3D.h */; };
-		FE5F49BB0948A5390095980F /* SkDrawable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F492E0948A5380095980F /* SkDrawable.cpp */; };
-		FE5F49BC0948A5390095980F /* SkDrawable.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F492F0948A5380095980F /* SkDrawable.h */; };
-		FE5F49BD0948A5390095980F /* SkDrawBitmap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49300948A5380095980F /* SkDrawBitmap.cpp */; };
-		FE5F49BE0948A5390095980F /* SkDrawBitmap.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49310948A5380095980F /* SkDrawBitmap.h */; };
-		FE5F49BF0948A5390095980F /* SkDrawBlur.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49320948A5380095980F /* SkDrawBlur.cpp */; };
-		FE5F49C00948A5390095980F /* SkDrawBlur.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49330948A5380095980F /* SkDrawBlur.h */; };
-		FE5F49C10948A5390095980F /* SkDrawClip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49340948A5380095980F /* SkDrawClip.cpp */; };
-		FE5F49C20948A5390095980F /* SkDrawClip.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49350948A5380095980F /* SkDrawClip.h */; };
-		FE5F49C30948A5390095980F /* SkDrawColor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49360948A5380095980F /* SkDrawColor.cpp */; };
-		FE5F49C40948A5390095980F /* SkDrawColor.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49370948A5380095980F /* SkDrawColor.h */; };
-		FE5F49C50948A5390095980F /* SkDrawDash.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49380948A5380095980F /* SkDrawDash.cpp */; };
-		FE5F49C60948A5390095980F /* SkDrawDash.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49390948A5380095980F /* SkDrawDash.h */; };
-		FE5F49C70948A5390095980F /* SkDrawDiscrete.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F493A0948A5380095980F /* SkDrawDiscrete.cpp */; };
-		FE5F49C80948A5390095980F /* SkDrawDiscrete.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F493B0948A5380095980F /* SkDrawDiscrete.h */; };
-		FE5F49C90948A5390095980F /* SkDrawEmboss.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F493C0948A5380095980F /* SkDrawEmboss.cpp */; };
-		FE5F49CA0948A5390095980F /* SkDrawEmboss.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F493D0948A5380095980F /* SkDrawEmboss.h */; };
-		FE5F49CB0948A5390095980F /* SkDrawExtraPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F493E0948A5380095980F /* SkDrawExtraPathEffect.cpp */; };
-		FE5F49CC0948A5390095980F /* SkDrawFull.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F493F0948A5380095980F /* SkDrawFull.cpp */; };
-		FE5F49CD0948A5390095980F /* SkDrawFull.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49400948A5380095980F /* SkDrawFull.h */; };
-		FE5F49CE0948A5390095980F /* SkDrawGradient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49410948A5380095980F /* SkDrawGradient.cpp */; };
-		FE5F49CF0948A5390095980F /* SkDrawGradient.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49420948A5380095980F /* SkDrawGradient.h */; };
-		FE5F49D00948A5390095980F /* SkDrawGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49430948A5380095980F /* SkDrawGroup.cpp */; };
-		FE5F49D10948A5390095980F /* SkDrawGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49440948A5380095980F /* SkDrawGroup.h */; };
-		FE5F49D20948A5390095980F /* SkDrawLine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49450948A5380095980F /* SkDrawLine.cpp */; };
-		FE5F49D30948A5390095980F /* SkDrawLine.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49460948A5380095980F /* SkDrawLine.h */; };
-		FE5F49D40948A5390095980F /* SkDrawMatrix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49470948A5380095980F /* SkDrawMatrix.cpp */; };
-		FE5F49D50948A5390095980F /* SkDrawMatrix.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49480948A5380095980F /* SkDrawMatrix.h */; };
-		FE5F49D60948A5390095980F /* SkDrawOval.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49490948A5380095980F /* SkDrawOval.cpp */; };
-		FE5F49D70948A5390095980F /* SkDrawOval.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F494A0948A5380095980F /* SkDrawOval.h */; };
-		FE5F49D80948A5390095980F /* SkDrawPaint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F494B0948A5390095980F /* SkDrawPaint.cpp */; };
-		FE5F49D90948A5390095980F /* SkDrawPaint.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F494C0948A5390095980F /* SkDrawPaint.h */; };
-		FE5F49DA0948A5390095980F /* SkDrawPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F494D0948A5390095980F /* SkDrawPath.cpp */; };
-		FE5F49DB0948A5390095980F /* SkDrawPath.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F494E0948A5390095980F /* SkDrawPath.h */; };
-		FE5F49DC0948A5390095980F /* SkDrawPoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F494F0948A5390095980F /* SkDrawPoint.cpp */; };
-		FE5F49DD0948A5390095980F /* SkDrawPoint.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49500948A5390095980F /* SkDrawPoint.h */; };
-		FE5F49DE0948A5390095980F /* SkDrawRectangle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49510948A5390095980F /* SkDrawRectangle.cpp */; };
-		FE5F49DF0948A5390095980F /* SkDrawRectangle.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49520948A5390095980F /* SkDrawRectangle.h */; };
-		FE5F49E00948A5390095980F /* SkDrawShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49530948A5390095980F /* SkDrawShader.cpp */; };
-		FE5F49E10948A5390095980F /* SkDrawShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49540948A5390095980F /* SkDrawShader.h */; };
-		FE5F49E20948A5390095980F /* SkDrawText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49550948A5390095980F /* SkDrawText.cpp */; };
-		FE5F49E30948A5390095980F /* SkDrawText.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49560948A5390095980F /* SkDrawText.h */; };
-		FE5F49E40948A5390095980F /* SkDrawTextBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49570948A5390095980F /* SkDrawTextBox.cpp */; };
-		FE5F49E50948A5390095980F /* SkDrawTextBox.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49580948A5390095980F /* SkDrawTextBox.h */; };
-		FE5F49E60948A5390095980F /* SkDrawTo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49590948A5390095980F /* SkDrawTo.cpp */; };
-		FE5F49E70948A5390095980F /* SkDrawTo.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F495A0948A5390095980F /* SkDrawTo.h */; };
-		FE5F49E80948A5390095980F /* SkDrawTransparentShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F495B0948A5390095980F /* SkDrawTransparentShader.cpp */; };
-		FE5F49E90948A5390095980F /* SkDrawTransparentShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F495C0948A5390095980F /* SkDrawTransparentShader.h */; };
-		FE5F49EA0948A5390095980F /* SkDump.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F495D0948A5390095980F /* SkDump.cpp */; };
-		FE5F49EB0948A5390095980F /* SkDump.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F495E0948A5390095980F /* SkDump.h */; };
-		FE5F49EC0948A5390095980F /* SkExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49600948A5390095980F /* SkExtras.h */; };
-		FE5F49ED0948A5390095980F /* SkGetCondensedInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49610948A5390095980F /* SkGetCondensedInfo.cpp */; };
-		FE5F49EE0948A5390095980F /* SkHitClear.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49620948A5390095980F /* SkHitClear.cpp */; };
-		FE5F49EF0948A5390095980F /* SkHitClear.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49630948A5390095980F /* SkHitClear.h */; };
-		FE5F49F00948A5390095980F /* SkHitTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49640948A5390095980F /* SkHitTest.cpp */; };
-		FE5F49F10948A5390095980F /* SkHitTest.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49650948A5390095980F /* SkHitTest.h */; };
-		FE5F49F20948A5390095980F /* SkIntArray.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49660948A5390095980F /* SkIntArray.h */; };
-		FE5F49F40948A5390095980F /* SkMatrixParts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49680948A5390095980F /* SkMatrixParts.cpp */; };
-		FE5F49F50948A5390095980F /* SkMatrixParts.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49690948A5390095980F /* SkMatrixParts.h */; };
-		FE5F49F60948A5390095980F /* SkMemberInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F496A0948A5390095980F /* SkMemberInfo.cpp */; };
-		FE5F49F70948A5390095980F /* SkMemberInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F496B0948A5390095980F /* SkMemberInfo.h */; };
-		FE5F49F80948A5390095980F /* SkOperand.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F496C0948A5390095980F /* SkOperand.h */; };
-		FE5F49F90948A5390095980F /* SkOperandInterpolator.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F496D0948A5390095980F /* SkOperandInterpolator.h */; };
-		FE5F49FA0948A5390095980F /* SkOperandIterpolator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F496E0948A5390095980F /* SkOperandIterpolator.cpp */; };
-		FE5F49FB0948A5390095980F /* SkPaintParts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F496F0948A5390095980F /* SkPaintParts.cpp */; };
-		FE5F49FC0948A5390095980F /* SkPaintParts.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49700948A5390095980F /* SkPaintParts.h */; };
-		FE5F49FD0948A5390095980F /* SkPathParts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49710948A5390095980F /* SkPathParts.cpp */; };
-		FE5F49FE0948A5390095980F /* SkPathParts.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49720948A5390095980F /* SkPathParts.h */; };
-		FE5F49FF0948A5390095980F /* SkPostParts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49730948A5390095980F /* SkPostParts.cpp */; };
-		FE5F4A000948A5390095980F /* SkPostParts.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49740948A5390095980F /* SkPostParts.h */; };
-		FE5F4A010948A5390095980F /* SkScript.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49750948A5390095980F /* SkScript.cpp */; };
-		FE5F4A020948A5390095980F /* SkScript.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49760948A5390095980F /* SkScript.h */; };
-		FE5F4A030948A5390095980F /* SkSnapshot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49770948A5390095980F /* SkSnapshot.cpp */; };
-		FE5F4A040948A5390095980F /* SkSnapshot.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49780948A5390095980F /* SkSnapshot.h */; };
-		FE5F4A050948A5390095980F /* SkSVGPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49790948A5390095980F /* SkSVGPath.cpp */; };
-		FE5F4A060948A5390095980F /* SkTDArray_Experimental.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F497A0948A5390095980F /* SkTDArray_Experimental.h */; };
-		FE5F4A070948A5390095980F /* SkTextOnPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F497B0948A5390095980F /* SkTextOnPath.cpp */; };
-		FE5F4A080948A5390095980F /* SkTextOnPath.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F497C0948A5390095980F /* SkTextOnPath.h */; };
-		FE5F4A090948A5390095980F /* SkTextToPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F497D0948A5390095980F /* SkTextToPath.cpp */; };
-		FE5F4A0A0948A5390095980F /* SkTextToPath.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F497E0948A5390095980F /* SkTextToPath.h */; };
-		FE5F4A0B0948A5390095980F /* SkTime.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F497F0948A5390095980F /* SkTime.cpp */; };
-		FE5F4A0C0948A5390095980F /* SkTypedArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49800948A5390095980F /* SkTypedArray.cpp */; };
-		FE5F4A0D0948A5390095980F /* SkTypedArray.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49810948A5390095980F /* SkTypedArray.h */; };
-		FE5F4A0E0948A5390095980F /* SkXMLAnimatorWriter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F49820948A5390095980F /* SkXMLAnimatorWriter.cpp */; };
-		FE5F4A0F0948A5390095980F /* SkXMLAnimatorWriter.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F49830948A5390095980F /* SkXMLAnimatorWriter.h */; };
-		FE76553E09DFF6610088D6CA /* SkScriptTokenizer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE76553D09DFF6610088D6CA /* SkScriptTokenizer.cpp */; };
-		FECB4EF409DF3E3600D03FF8 /* SkAnimatorScript2.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECB4EEA09DF3E3600D03FF8 /* SkAnimatorScript2.cpp */; };
-		FECB4EF509DF3E3600D03FF8 /* SkAnimatorScript2.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EEB09DF3E3600D03FF8 /* SkAnimatorScript2.h */; };
-		FECB4EF609DF3E3600D03FF8 /* SkOpArray.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECB4EEC09DF3E3600D03FF8 /* SkOpArray.cpp */; };
-		FECB4EF709DF3E3600D03FF8 /* SkOpArray.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EED09DF3E3600D03FF8 /* SkOpArray.h */; };
-		FECB4EF809DF3E3600D03FF8 /* SkOperand2.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EEE09DF3E3600D03FF8 /* SkOperand2.h */; };
-		FECB4EF909DF3E3600D03FF8 /* SkScript2.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EEF09DF3E3600D03FF8 /* SkScript2.h */; };
-		FECB4EFA09DF3E3600D03FF8 /* SkScriptCallBack.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EF009DF3E3600D03FF8 /* SkScriptCallBack.h */; };
-		FECB4EFB09DF3E3600D03FF8 /* SkScriptDecompile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECB4EF109DF3E3600D03FF8 /* SkScriptDecompile.cpp */; };
-		FECB4EFC09DF3E3600D03FF8 /* SkScriptRuntime.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECB4EF209DF3E3600D03FF8 /* SkScriptRuntime.cpp */; };
-		FECB4EFD09DF3E3600D03FF8 /* SkScriptRuntime.h in Headers */ = {isa = PBXBuildFile; fileRef = FECB4EF309DF3E3600D03FF8 /* SkScriptRuntime.h */; };
-		FEE7D79F094613A600B11B76 /* SkAnimateBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEE7D79E094613A600B11B76 /* SkAnimateBase.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		D2AAC046055464E500DB518D /* libanimator.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libanimator.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE49EAAB09FD5DB800D28411 /* SkDrawExtraPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawExtraPathEffect.h; path = ../../include/graphics/SkDrawExtraPathEffect.h; sourceTree = SOURCE_ROOT; };
-		FE49EB4C09FE783600D28411 /* SkDisplayNumber.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayNumber.h; path = ../../libs/graphics/animator/SkDisplayNumber.h; sourceTree = SOURCE_ROOT; };
-		FE49EB5009FE785E00D28411 /* SkDisplayNumber.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayNumber.cpp; path = ../../libs/graphics/animator/SkDisplayNumber.cpp; sourceTree = SOURCE_ROOT; };
-		FE49EE0B09FFDB0300D28411 /* SkAnimateProperties.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimateProperties.h; path = ../../libs/graphics/animator/SkAnimateProperties.h; sourceTree = SOURCE_ROOT; };
-		FE51FB840A6FDCE400ABA91D /* SkDrawSaveLayer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawSaveLayer.h; path = ../../libs/graphics/animator/SkDrawSaveLayer.h; sourceTree = SOURCE_ROOT; };
-		FE51FB8E0A6FE7DC00ABA91D /* SkDrawSaveLayer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawSaveLayer.cpp; path = ../../libs/graphics/animator/SkDrawSaveLayer.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48F30948A5380095980F /* SkAnimateBase.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimateBase.h; path = ../../libs/graphics/animator/SkAnimateBase.h; sourceTree = SOURCE_ROOT; };
-		FE5F48F40948A5380095980F /* SkAnimate3DSchema.xsd */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = SkAnimate3DSchema.xsd; path = ../../libs/graphics/animator/SkAnimate3DSchema.xsd; sourceTree = SOURCE_ROOT; };
-		FE5F48F50948A5380095980F /* SkAnimate3DSchema.xsx */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.xml; name = SkAnimate3DSchema.xsx; path = ../../libs/graphics/animator/SkAnimate3DSchema.xsx; sourceTree = SOURCE_ROOT; };
-		FE5F48F60948A5380095980F /* SkAnimateActive.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimateActive.cpp; path = ../../libs/graphics/animator/SkAnimateActive.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48F70948A5380095980F /* SkAnimateActive.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimateActive.h; path = ../../libs/graphics/animator/SkAnimateActive.h; sourceTree = SOURCE_ROOT; };
-		FE5F48F80948A5380095980F /* SkAnimateField.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimateField.cpp; path = ../../libs/graphics/animator/SkAnimateField.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48F90948A5380095980F /* SkAnimate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimate.h; path = ../../libs/graphics/animator/SkAnimate.h; sourceTree = SOURCE_ROOT; };
-		FE5F48FA0948A5380095980F /* SkAnimateMaker.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimateMaker.cpp; path = ../../libs/graphics/animator/SkAnimateMaker.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48FB0948A5380095980F /* SkAnimateMaker.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimateMaker.h; path = ../../libs/graphics/animator/SkAnimateMaker.h; sourceTree = SOURCE_ROOT; };
-		FE5F48FC0948A5380095980F /* SkAnimateSchema.xsd */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = SkAnimateSchema.xsd; path = ../../libs/graphics/animator/SkAnimateSchema.xsd; sourceTree = SOURCE_ROOT; };
-		FE5F48FD0948A5380095980F /* SkAnimateSchema.xsx */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.xml; name = SkAnimateSchema.xsx; path = ../../libs/graphics/animator/SkAnimateSchema.xsx; sourceTree = SOURCE_ROOT; };
-		FE5F48FE0948A5380095980F /* SkAnimateSet.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimateSet.cpp; path = ../../libs/graphics/animator/SkAnimateSet.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48FF0948A5380095980F /* SkAnimateSet.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimateSet.h; path = ../../libs/graphics/animator/SkAnimateSet.h; sourceTree = SOURCE_ROOT; };
-		FE5F49000948A5380095980F /* SkAnimator.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimator.cpp; path = ../../libs/graphics/animator/SkAnimator.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49010948A5380095980F /* SkAnimatorScript.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimatorScript.cpp; path = ../../libs/graphics/animator/SkAnimatorScript.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49020948A5380095980F /* SkAnimatorScript.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimatorScript.h; path = ../../libs/graphics/animator/SkAnimatorScript.h; sourceTree = SOURCE_ROOT; };
-		FE5F49030948A5380095980F /* SkBase64.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBase64.cpp; path = ../../libs/graphics/animator/SkBase64.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49040948A5380095980F /* SkBase64.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBase64.h; path = ../../libs/graphics/animator/SkBase64.h; sourceTree = SOURCE_ROOT; };
-		FE5F49050948A5380095980F /* SkBoundable.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBoundable.cpp; path = ../../libs/graphics/animator/SkBoundable.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49060948A5380095980F /* SkBoundable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBoundable.h; path = ../../libs/graphics/animator/SkBoundable.h; sourceTree = SOURCE_ROOT; };
-		FE5F49070948A5380095980F /* SkBuildCondensedInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBuildCondensedInfo.cpp; path = ../../libs/graphics/animator/SkBuildCondensedInfo.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F490A0948A5380095980F /* SkDisplayable.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayable.cpp; path = ../../libs/graphics/animator/SkDisplayable.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F490B0948A5380095980F /* SkDisplayable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayable.h; path = ../../libs/graphics/animator/SkDisplayable.h; sourceTree = SOURCE_ROOT; };
-		FE5F490C0948A5380095980F /* SkDisplayAdd.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayAdd.cpp; path = ../../libs/graphics/animator/SkDisplayAdd.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F490D0948A5380095980F /* SkDisplayAdd.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayAdd.h; path = ../../libs/graphics/animator/SkDisplayAdd.h; sourceTree = SOURCE_ROOT; };
-		FE5F490E0948A5380095980F /* SkDisplayApply.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayApply.cpp; path = ../../libs/graphics/animator/SkDisplayApply.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F490F0948A5380095980F /* SkDisplayApply.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayApply.h; path = ../../libs/graphics/animator/SkDisplayApply.h; sourceTree = SOURCE_ROOT; };
-		FE5F49100948A5380095980F /* SkDisplayBounds.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayBounds.cpp; path = ../../libs/graphics/animator/SkDisplayBounds.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49110948A5380095980F /* SkDisplayBounds.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayBounds.h; path = ../../libs/graphics/animator/SkDisplayBounds.h; sourceTree = SOURCE_ROOT; };
-		FE5F49120948A5380095980F /* SkDisplayEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayEvent.cpp; path = ../../libs/graphics/animator/SkDisplayEvent.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49130948A5380095980F /* SkDisplayEvent.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayEvent.h; path = ../../libs/graphics/animator/SkDisplayEvent.h; sourceTree = SOURCE_ROOT; };
-		FE5F49140948A5380095980F /* SkDisplayEvents.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayEvents.cpp; path = ../../libs/graphics/animator/SkDisplayEvents.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49150948A5380095980F /* SkDisplayEvents.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayEvents.h; path = ../../libs/graphics/animator/SkDisplayEvents.h; sourceTree = SOURCE_ROOT; };
-		FE5F49160948A5380095980F /* SkDisplayInclude.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayInclude.cpp; path = ../../libs/graphics/animator/SkDisplayInclude.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49170948A5380095980F /* SkDisplayInclude.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayInclude.h; path = ../../libs/graphics/animator/SkDisplayInclude.h; sourceTree = SOURCE_ROOT; };
-		FE5F49180948A5380095980F /* SkDisplayInput.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayInput.cpp; path = ../../libs/graphics/animator/SkDisplayInput.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49190948A5380095980F /* SkDisplayInput.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayInput.h; path = ../../libs/graphics/animator/SkDisplayInput.h; sourceTree = SOURCE_ROOT; };
-		FE5F491A0948A5380095980F /* SkDisplayList.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayList.cpp; path = ../../libs/graphics/animator/SkDisplayList.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F491B0948A5380095980F /* SkDisplayList.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayList.h; path = ../../libs/graphics/animator/SkDisplayList.h; sourceTree = SOURCE_ROOT; };
-		FE5F491C0948A5380095980F /* SkDisplayMath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayMath.cpp; path = ../../libs/graphics/animator/SkDisplayMath.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F491D0948A5380095980F /* SkDisplayMath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayMath.h; path = ../../libs/graphics/animator/SkDisplayMath.h; sourceTree = SOURCE_ROOT; };
-		FE5F491E0948A5380095980F /* SkDisplayMovie.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayMovie.cpp; path = ../../libs/graphics/animator/SkDisplayMovie.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F491F0948A5380095980F /* SkDisplayMovie.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayMovie.h; path = ../../libs/graphics/animator/SkDisplayMovie.h; sourceTree = SOURCE_ROOT; };
-		FE5F49200948A5380095980F /* SkDisplayPost.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayPost.cpp; path = ../../libs/graphics/animator/SkDisplayPost.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49210948A5380095980F /* SkDisplayPost.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayPost.h; path = ../../libs/graphics/animator/SkDisplayPost.h; sourceTree = SOURCE_ROOT; };
-		FE5F49220948A5380095980F /* SkDisplayRandom.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayRandom.cpp; path = ../../libs/graphics/animator/SkDisplayRandom.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49230948A5380095980F /* SkDisplayRandom.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayRandom.h; path = ../../libs/graphics/animator/SkDisplayRandom.h; sourceTree = SOURCE_ROOT; };
-		FE5F49240948A5380095980F /* SkDisplayScreenplay.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayScreenplay.cpp; path = ../../libs/graphics/animator/SkDisplayScreenplay.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49250948A5380095980F /* SkDisplayScreenplay.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayScreenplay.h; path = ../../libs/graphics/animator/SkDisplayScreenplay.h; sourceTree = SOURCE_ROOT; };
-		FE5F49260948A5380095980F /* SkDisplayType.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayType.cpp; path = ../../libs/graphics/animator/SkDisplayType.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49270948A5380095980F /* SkDisplayType.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayType.h; path = ../../libs/graphics/animator/SkDisplayType.h; sourceTree = SOURCE_ROOT; };
-		FE5F49280948A5380095980F /* SkDisplayTypes.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayTypes.cpp; path = ../../libs/graphics/animator/SkDisplayTypes.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49290948A5380095980F /* SkDisplayTypes.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayTypes.h; path = ../../libs/graphics/animator/SkDisplayTypes.h; sourceTree = SOURCE_ROOT; };
-		FE5F492A0948A5380095980F /* SkDisplayXMLParser.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDisplayXMLParser.cpp; path = ../../libs/graphics/animator/SkDisplayXMLParser.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F492B0948A5380095980F /* SkDisplayXMLParser.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDisplayXMLParser.h; path = ../../libs/graphics/animator/SkDisplayXMLParser.h; sourceTree = SOURCE_ROOT; };
-		FE5F492C0948A5380095980F /* SkDraw3D.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDraw3D.cpp; path = ../../libs/graphics/animator/SkDraw3D.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F492D0948A5380095980F /* SkDraw3D.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDraw3D.h; path = ../../libs/graphics/animator/SkDraw3D.h; sourceTree = SOURCE_ROOT; };
-		FE5F492E0948A5380095980F /* SkDrawable.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawable.cpp; path = ../../libs/graphics/animator/SkDrawable.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F492F0948A5380095980F /* SkDrawable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawable.h; path = ../../libs/graphics/animator/SkDrawable.h; sourceTree = SOURCE_ROOT; };
-		FE5F49300948A5380095980F /* SkDrawBitmap.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawBitmap.cpp; path = ../../libs/graphics/animator/SkDrawBitmap.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49310948A5380095980F /* SkDrawBitmap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawBitmap.h; path = ../../libs/graphics/animator/SkDrawBitmap.h; sourceTree = SOURCE_ROOT; };
-		FE5F49320948A5380095980F /* SkDrawBlur.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawBlur.cpp; path = ../../libs/graphics/animator/SkDrawBlur.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49330948A5380095980F /* SkDrawBlur.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawBlur.h; path = ../../libs/graphics/animator/SkDrawBlur.h; sourceTree = SOURCE_ROOT; };
-		FE5F49340948A5380095980F /* SkDrawClip.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawClip.cpp; path = ../../libs/graphics/animator/SkDrawClip.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49350948A5380095980F /* SkDrawClip.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawClip.h; path = ../../libs/graphics/animator/SkDrawClip.h; sourceTree = SOURCE_ROOT; };
-		FE5F49360948A5380095980F /* SkDrawColor.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawColor.cpp; path = ../../libs/graphics/animator/SkDrawColor.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49370948A5380095980F /* SkDrawColor.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawColor.h; path = ../../libs/graphics/animator/SkDrawColor.h; sourceTree = SOURCE_ROOT; };
-		FE5F49380948A5380095980F /* SkDrawDash.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawDash.cpp; path = ../../libs/graphics/animator/SkDrawDash.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49390948A5380095980F /* SkDrawDash.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawDash.h; path = ../../libs/graphics/animator/SkDrawDash.h; sourceTree = SOURCE_ROOT; };
-		FE5F493A0948A5380095980F /* SkDrawDiscrete.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawDiscrete.cpp; path = ../../libs/graphics/animator/SkDrawDiscrete.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F493B0948A5380095980F /* SkDrawDiscrete.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawDiscrete.h; path = ../../libs/graphics/animator/SkDrawDiscrete.h; sourceTree = SOURCE_ROOT; };
-		FE5F493C0948A5380095980F /* SkDrawEmboss.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawEmboss.cpp; path = ../../libs/graphics/animator/SkDrawEmboss.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F493D0948A5380095980F /* SkDrawEmboss.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawEmboss.h; path = ../../libs/graphics/animator/SkDrawEmboss.h; sourceTree = SOURCE_ROOT; };
-		FE5F493E0948A5380095980F /* SkDrawExtraPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawExtraPathEffect.cpp; path = ../../libs/graphics/animator/SkDrawExtraPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F493F0948A5380095980F /* SkDrawFull.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawFull.cpp; path = ../../libs/graphics/animator/SkDrawFull.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49400948A5380095980F /* SkDrawFull.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawFull.h; path = ../../libs/graphics/animator/SkDrawFull.h; sourceTree = SOURCE_ROOT; };
-		FE5F49410948A5380095980F /* SkDrawGradient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawGradient.cpp; path = ../../libs/graphics/animator/SkDrawGradient.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49420948A5380095980F /* SkDrawGradient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawGradient.h; path = ../../libs/graphics/animator/SkDrawGradient.h; sourceTree = SOURCE_ROOT; };
-		FE5F49430948A5380095980F /* SkDrawGroup.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawGroup.cpp; path = ../../libs/graphics/animator/SkDrawGroup.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49440948A5380095980F /* SkDrawGroup.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawGroup.h; path = ../../libs/graphics/animator/SkDrawGroup.h; sourceTree = SOURCE_ROOT; };
-		FE5F49450948A5380095980F /* SkDrawLine.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawLine.cpp; path = ../../libs/graphics/animator/SkDrawLine.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49460948A5380095980F /* SkDrawLine.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawLine.h; path = ../../libs/graphics/animator/SkDrawLine.h; sourceTree = SOURCE_ROOT; };
-		FE5F49470948A5380095980F /* SkDrawMatrix.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawMatrix.cpp; path = ../../libs/graphics/animator/SkDrawMatrix.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49480948A5380095980F /* SkDrawMatrix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawMatrix.h; path = ../../libs/graphics/animator/SkDrawMatrix.h; sourceTree = SOURCE_ROOT; };
-		FE5F49490948A5380095980F /* SkDrawOval.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawOval.cpp; path = ../../libs/graphics/animator/SkDrawOval.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F494A0948A5380095980F /* SkDrawOval.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawOval.h; path = ../../libs/graphics/animator/SkDrawOval.h; sourceTree = SOURCE_ROOT; };
-		FE5F494B0948A5390095980F /* SkDrawPaint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawPaint.cpp; path = ../../libs/graphics/animator/SkDrawPaint.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F494C0948A5390095980F /* SkDrawPaint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawPaint.h; path = ../../libs/graphics/animator/SkDrawPaint.h; sourceTree = SOURCE_ROOT; };
-		FE5F494D0948A5390095980F /* SkDrawPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawPath.cpp; path = ../../libs/graphics/animator/SkDrawPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F494E0948A5390095980F /* SkDrawPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawPath.h; path = ../../libs/graphics/animator/SkDrawPath.h; sourceTree = SOURCE_ROOT; };
-		FE5F494F0948A5390095980F /* SkDrawPoint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawPoint.cpp; path = ../../libs/graphics/animator/SkDrawPoint.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49500948A5390095980F /* SkDrawPoint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawPoint.h; path = ../../libs/graphics/animator/SkDrawPoint.h; sourceTree = SOURCE_ROOT; };
-		FE5F49510948A5390095980F /* SkDrawRectangle.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawRectangle.cpp; path = ../../libs/graphics/animator/SkDrawRectangle.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49520948A5390095980F /* SkDrawRectangle.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawRectangle.h; path = ../../libs/graphics/animator/SkDrawRectangle.h; sourceTree = SOURCE_ROOT; };
-		FE5F49530948A5390095980F /* SkDrawShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawShader.cpp; path = ../../libs/graphics/animator/SkDrawShader.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49540948A5390095980F /* SkDrawShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawShader.h; path = ../../libs/graphics/animator/SkDrawShader.h; sourceTree = SOURCE_ROOT; };
-		FE5F49550948A5390095980F /* SkDrawText.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawText.cpp; path = ../../libs/graphics/animator/SkDrawText.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49560948A5390095980F /* SkDrawText.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawText.h; path = ../../libs/graphics/animator/SkDrawText.h; sourceTree = SOURCE_ROOT; };
-		FE5F49570948A5390095980F /* SkDrawTextBox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawTextBox.cpp; path = ../../libs/graphics/animator/SkDrawTextBox.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49580948A5390095980F /* SkDrawTextBox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawTextBox.h; path = ../../libs/graphics/animator/SkDrawTextBox.h; sourceTree = SOURCE_ROOT; };
-		FE5F49590948A5390095980F /* SkDrawTo.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawTo.cpp; path = ../../libs/graphics/animator/SkDrawTo.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F495A0948A5390095980F /* SkDrawTo.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawTo.h; path = ../../libs/graphics/animator/SkDrawTo.h; sourceTree = SOURCE_ROOT; };
-		FE5F495B0948A5390095980F /* SkDrawTransparentShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDrawTransparentShader.cpp; path = ../../libs/graphics/animator/SkDrawTransparentShader.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F495C0948A5390095980F /* SkDrawTransparentShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDrawTransparentShader.h; path = ../../libs/graphics/animator/SkDrawTransparentShader.h; sourceTree = SOURCE_ROOT; };
-		FE5F495D0948A5390095980F /* SkDump.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDump.cpp; path = ../../libs/graphics/animator/SkDump.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F495E0948A5390095980F /* SkDump.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkDump.h; path = ../../libs/graphics/animator/SkDump.h; sourceTree = SOURCE_ROOT; };
-		FE5F495F0948A5390095980F /* SkExtraPathEffects.xsd */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = SkExtraPathEffects.xsd; path = ../../libs/graphics/animator/SkExtraPathEffects.xsd; sourceTree = SOURCE_ROOT; };
-		FE5F49600948A5390095980F /* SkExtras.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkExtras.h; path = ../../libs/graphics/animator/SkExtras.h; sourceTree = SOURCE_ROOT; };
-		FE5F49610948A5390095980F /* SkGetCondensedInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGetCondensedInfo.cpp; path = ../../libs/graphics/animator/SkGetCondensedInfo.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49620948A5390095980F /* SkHitClear.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkHitClear.cpp; path = ../../libs/graphics/animator/SkHitClear.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49630948A5390095980F /* SkHitClear.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkHitClear.h; path = ../../libs/graphics/animator/SkHitClear.h; sourceTree = SOURCE_ROOT; };
-		FE5F49640948A5390095980F /* SkHitTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkHitTest.cpp; path = ../../libs/graphics/animator/SkHitTest.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49650948A5390095980F /* SkHitTest.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkHitTest.h; path = ../../libs/graphics/animator/SkHitTest.h; sourceTree = SOURCE_ROOT; };
-		FE5F49660948A5390095980F /* SkIntArray.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkIntArray.h; path = ../../libs/graphics/animator/SkIntArray.h; sourceTree = SOURCE_ROOT; };
-		FE5F49680948A5390095980F /* SkMatrixParts.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMatrixParts.cpp; path = ../../libs/graphics/animator/SkMatrixParts.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49690948A5390095980F /* SkMatrixParts.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkMatrixParts.h; path = ../../libs/graphics/animator/SkMatrixParts.h; sourceTree = SOURCE_ROOT; };
-		FE5F496A0948A5390095980F /* SkMemberInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMemberInfo.cpp; path = ../../libs/graphics/animator/SkMemberInfo.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F496B0948A5390095980F /* SkMemberInfo.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkMemberInfo.h; path = ../../libs/graphics/animator/SkMemberInfo.h; sourceTree = SOURCE_ROOT; };
-		FE5F496C0948A5390095980F /* SkOperand.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkOperand.h; path = ../../libs/graphics/animator/SkOperand.h; sourceTree = SOURCE_ROOT; };
-		FE5F496D0948A5390095980F /* SkOperandInterpolator.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkOperandInterpolator.h; path = ../../libs/graphics/animator/SkOperandInterpolator.h; sourceTree = SOURCE_ROOT; };
-		FE5F496E0948A5390095980F /* SkOperandIterpolator.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOperandIterpolator.cpp; path = ../../libs/graphics/animator/SkOperandIterpolator.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F496F0948A5390095980F /* SkPaintParts.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPaintParts.cpp; path = ../../libs/graphics/animator/SkPaintParts.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49700948A5390095980F /* SkPaintParts.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPaintParts.h; path = ../../libs/graphics/animator/SkPaintParts.h; sourceTree = SOURCE_ROOT; };
-		FE5F49710948A5390095980F /* SkPathParts.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPathParts.cpp; path = ../../libs/graphics/animator/SkPathParts.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49720948A5390095980F /* SkPathParts.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPathParts.h; path = ../../libs/graphics/animator/SkPathParts.h; sourceTree = SOURCE_ROOT; };
-		FE5F49730948A5390095980F /* SkPostParts.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPostParts.cpp; path = ../../libs/graphics/animator/SkPostParts.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49740948A5390095980F /* SkPostParts.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPostParts.h; path = ../../libs/graphics/animator/SkPostParts.h; sourceTree = SOURCE_ROOT; };
-		FE5F49750948A5390095980F /* SkScript.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScript.cpp; path = ../../libs/graphics/animator/SkScript.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49760948A5390095980F /* SkScript.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScript.h; path = ../../libs/graphics/animator/SkScript.h; sourceTree = SOURCE_ROOT; };
-		FE5F49770948A5390095980F /* SkSnapshot.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkSnapshot.cpp; path = ../../libs/graphics/animator/SkSnapshot.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49780948A5390095980F /* SkSnapshot.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkSnapshot.h; path = ../../libs/graphics/animator/SkSnapshot.h; sourceTree = SOURCE_ROOT; };
-		FE5F49790948A5390095980F /* SkSVGPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkSVGPath.cpp; path = ../../libs/graphics/animator/SkSVGPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F497A0948A5390095980F /* SkTDArray_Experimental.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTDArray_Experimental.h; path = ../../libs/graphics/animator/SkTDArray_Experimental.h; sourceTree = SOURCE_ROOT; };
-		FE5F497B0948A5390095980F /* SkTextOnPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTextOnPath.cpp; path = ../../libs/graphics/animator/SkTextOnPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F497C0948A5390095980F /* SkTextOnPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTextOnPath.h; path = ../../libs/graphics/animator/SkTextOnPath.h; sourceTree = SOURCE_ROOT; };
-		FE5F497D0948A5390095980F /* SkTextToPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTextToPath.cpp; path = ../../libs/graphics/animator/SkTextToPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F497E0948A5390095980F /* SkTextToPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTextToPath.h; path = ../../libs/graphics/animator/SkTextToPath.h; sourceTree = SOURCE_ROOT; };
-		FE5F497F0948A5390095980F /* SkTime.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTime.cpp; path = ../../libs/graphics/animator/SkTime.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49800948A5390095980F /* SkTypedArray.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTypedArray.cpp; path = ../../libs/graphics/animator/SkTypedArray.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49810948A5390095980F /* SkTypedArray.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTypedArray.h; path = ../../libs/graphics/animator/SkTypedArray.h; sourceTree = SOURCE_ROOT; };
-		FE5F49820948A5390095980F /* SkXMLAnimatorWriter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLAnimatorWriter.cpp; path = ../../libs/graphics/animator/SkXMLAnimatorWriter.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F49830948A5390095980F /* SkXMLAnimatorWriter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkXMLAnimatorWriter.h; path = ../../libs/graphics/animator/SkXMLAnimatorWriter.h; sourceTree = SOURCE_ROOT; };
-		FE6C3DFA0A061B0D00602871 /* thingstodo.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = thingstodo.txt; path = ../../libs/graphics/animator/thingstodo.txt; sourceTree = SOURCE_ROOT; };
-		FE76553D09DFF6610088D6CA /* SkScriptTokenizer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScriptTokenizer.cpp; path = ../../libs/graphics/animator/SkScriptTokenizer.cpp; sourceTree = SOURCE_ROOT; };
-		FECB4EEA09DF3E3600D03FF8 /* SkAnimatorScript2.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimatorScript2.cpp; path = ../../libs/graphics/animator/SkAnimatorScript2.cpp; sourceTree = SOURCE_ROOT; };
-		FECB4EEB09DF3E3600D03FF8 /* SkAnimatorScript2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAnimatorScript2.h; path = ../../libs/graphics/animator/SkAnimatorScript2.h; sourceTree = SOURCE_ROOT; };
-		FECB4EEC09DF3E3600D03FF8 /* SkOpArray.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOpArray.cpp; path = ../../libs/graphics/animator/SkOpArray.cpp; sourceTree = SOURCE_ROOT; };
-		FECB4EED09DF3E3600D03FF8 /* SkOpArray.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkOpArray.h; path = ../../libs/graphics/animator/SkOpArray.h; sourceTree = SOURCE_ROOT; };
-		FECB4EEE09DF3E3600D03FF8 /* SkOperand2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkOperand2.h; path = ../../libs/graphics/animator/SkOperand2.h; sourceTree = SOURCE_ROOT; };
-		FECB4EEF09DF3E3600D03FF8 /* SkScript2.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScript2.h; path = ../../libs/graphics/animator/SkScript2.h; sourceTree = SOURCE_ROOT; };
-		FECB4EF009DF3E3600D03FF8 /* SkScriptCallBack.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScriptCallBack.h; path = ../../libs/graphics/animator/SkScriptCallBack.h; sourceTree = SOURCE_ROOT; };
-		FECB4EF109DF3E3600D03FF8 /* SkScriptDecompile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScriptDecompile.cpp; path = ../../libs/graphics/animator/SkScriptDecompile.cpp; sourceTree = SOURCE_ROOT; };
-		FECB4EF209DF3E3600D03FF8 /* SkScriptRuntime.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScriptRuntime.cpp; path = ../../libs/graphics/animator/SkScriptRuntime.cpp; sourceTree = SOURCE_ROOT; };
-		FECB4EF309DF3E3600D03FF8 /* SkScriptRuntime.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScriptRuntime.h; path = ../../libs/graphics/animator/SkScriptRuntime.h; sourceTree = SOURCE_ROOT; };
-		FEE7D79E094613A600B11B76 /* SkAnimateBase.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAnimateBase.cpp; path = ../../libs/graphics/animator/SkAnimateBase.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* animator */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = animator;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				FE6C3DFA0A061B0D00602871 /* thingstodo.txt */,
-				FE76553D09DFF6610088D6CA /* SkScriptTokenizer.cpp */,
-				FECB4EEA09DF3E3600D03FF8 /* SkAnimatorScript2.cpp */,
-				FECB4EEB09DF3E3600D03FF8 /* SkAnimatorScript2.h */,
-				FECB4EEC09DF3E3600D03FF8 /* SkOpArray.cpp */,
-				FECB4EED09DF3E3600D03FF8 /* SkOpArray.h */,
-				FECB4EEE09DF3E3600D03FF8 /* SkOperand2.h */,
-				FECB4EEF09DF3E3600D03FF8 /* SkScript2.h */,
-				FECB4EF009DF3E3600D03FF8 /* SkScriptCallBack.h */,
-				FECB4EF109DF3E3600D03FF8 /* SkScriptDecompile.cpp */,
-				FECB4EF209DF3E3600D03FF8 /* SkScriptRuntime.cpp */,
-				FECB4EF309DF3E3600D03FF8 /* SkScriptRuntime.h */,
-				FEE7D79E094613A600B11B76 /* SkAnimateBase.cpp */,
-				FE5F48F30948A5380095980F /* SkAnimateBase.h */,
-				FE5F48F40948A5380095980F /* SkAnimate3DSchema.xsd */,
-				FE5F48F50948A5380095980F /* SkAnimate3DSchema.xsx */,
-				FE5F48F60948A5380095980F /* SkAnimateActive.cpp */,
-				FE5F48F70948A5380095980F /* SkAnimateActive.h */,
-				FE5F48F80948A5380095980F /* SkAnimateField.cpp */,
-				FE5F48F90948A5380095980F /* SkAnimate.h */,
-				FE5F48FA0948A5380095980F /* SkAnimateMaker.cpp */,
-				FE5F48FB0948A5380095980F /* SkAnimateMaker.h */,
-				FE49EAAB09FD5DB800D28411 /* SkDrawExtraPathEffect.h */,
-				FE5F48FC0948A5380095980F /* SkAnimateSchema.xsd */,
-				FE49EE0B09FFDB0300D28411 /* SkAnimateProperties.h */,
-				FE5F48FD0948A5380095980F /* SkAnimateSchema.xsx */,
-				FE5F48FE0948A5380095980F /* SkAnimateSet.cpp */,
-				FE5F48FF0948A5380095980F /* SkAnimateSet.h */,
-				FE5F49000948A5380095980F /* SkAnimator.cpp */,
-				FE5F49010948A5380095980F /* SkAnimatorScript.cpp */,
-				FE5F49020948A5380095980F /* SkAnimatorScript.h */,
-				FE5F49030948A5380095980F /* SkBase64.cpp */,
-				FE5F49040948A5380095980F /* SkBase64.h */,
-				FE5F49050948A5380095980F /* SkBoundable.cpp */,
-				FE5F49060948A5380095980F /* SkBoundable.h */,
-				FE5F49070948A5380095980F /* SkBuildCondensedInfo.cpp */,
-				FE5F490A0948A5380095980F /* SkDisplayable.cpp */,
-				FE5F490B0948A5380095980F /* SkDisplayable.h */,
-				FE5F490C0948A5380095980F /* SkDisplayAdd.cpp */,
-				FE5F490D0948A5380095980F /* SkDisplayAdd.h */,
-				FE5F490E0948A5380095980F /* SkDisplayApply.cpp */,
-				FE5F490F0948A5380095980F /* SkDisplayApply.h */,
-				FE5F49100948A5380095980F /* SkDisplayBounds.cpp */,
-				FE5F49110948A5380095980F /* SkDisplayBounds.h */,
-				FE5F49120948A5380095980F /* SkDisplayEvent.cpp */,
-				FE5F49130948A5380095980F /* SkDisplayEvent.h */,
-				FE5F49140948A5380095980F /* SkDisplayEvents.cpp */,
-				FE5F49150948A5380095980F /* SkDisplayEvents.h */,
-				FE5F49160948A5380095980F /* SkDisplayInclude.cpp */,
-				FE5F49170948A5380095980F /* SkDisplayInclude.h */,
-				FE5F49180948A5380095980F /* SkDisplayInput.cpp */,
-				FE5F49190948A5380095980F /* SkDisplayInput.h */,
-				FE5F491A0948A5380095980F /* SkDisplayList.cpp */,
-				FE5F491B0948A5380095980F /* SkDisplayList.h */,
-				FE5F491C0948A5380095980F /* SkDisplayMath.cpp */,
-				FE49EB5009FE785E00D28411 /* SkDisplayNumber.cpp */,
-				FE49EB4C09FE783600D28411 /* SkDisplayNumber.h */,
-				FE5F491D0948A5380095980F /* SkDisplayMath.h */,
-				FE5F491E0948A5380095980F /* SkDisplayMovie.cpp */,
-				FE5F491F0948A5380095980F /* SkDisplayMovie.h */,
-				FE5F49200948A5380095980F /* SkDisplayPost.cpp */,
-				FE5F49210948A5380095980F /* SkDisplayPost.h */,
-				FE5F49220948A5380095980F /* SkDisplayRandom.cpp */,
-				FE5F49230948A5380095980F /* SkDisplayRandom.h */,
-				FE5F49240948A5380095980F /* SkDisplayScreenplay.cpp */,
-				FE5F49250948A5380095980F /* SkDisplayScreenplay.h */,
-				FE5F49260948A5380095980F /* SkDisplayType.cpp */,
-				FE5F49270948A5380095980F /* SkDisplayType.h */,
-				FE5F49280948A5380095980F /* SkDisplayTypes.cpp */,
-				FE5F49290948A5380095980F /* SkDisplayTypes.h */,
-				FE5F492A0948A5380095980F /* SkDisplayXMLParser.cpp */,
-				FE5F492B0948A5380095980F /* SkDisplayXMLParser.h */,
-				FE5F492C0948A5380095980F /* SkDraw3D.cpp */,
-				FE5F492D0948A5380095980F /* SkDraw3D.h */,
-				FE5F492E0948A5380095980F /* SkDrawable.cpp */,
-				FE5F492F0948A5380095980F /* SkDrawable.h */,
-				FE5F49300948A5380095980F /* SkDrawBitmap.cpp */,
-				FE5F49310948A5380095980F /* SkDrawBitmap.h */,
-				FE5F49320948A5380095980F /* SkDrawBlur.cpp */,
-				FE5F49330948A5380095980F /* SkDrawBlur.h */,
-				FE5F49340948A5380095980F /* SkDrawClip.cpp */,
-				FE5F49350948A5380095980F /* SkDrawClip.h */,
-				FE5F49360948A5380095980F /* SkDrawColor.cpp */,
-				FE5F49370948A5380095980F /* SkDrawColor.h */,
-				FE5F49380948A5380095980F /* SkDrawDash.cpp */,
-				FE5F49390948A5380095980F /* SkDrawDash.h */,
-				FE5F493A0948A5380095980F /* SkDrawDiscrete.cpp */,
-				FE5F493B0948A5380095980F /* SkDrawDiscrete.h */,
-				FE5F493C0948A5380095980F /* SkDrawEmboss.cpp */,
-				FE5F493D0948A5380095980F /* SkDrawEmboss.h */,
-				FE5F493E0948A5380095980F /* SkDrawExtraPathEffect.cpp */,
-				FE5F493F0948A5380095980F /* SkDrawFull.cpp */,
-				FE5F49400948A5380095980F /* SkDrawFull.h */,
-				FE5F49410948A5380095980F /* SkDrawGradient.cpp */,
-				FE5F49420948A5380095980F /* SkDrawGradient.h */,
-				FE5F49430948A5380095980F /* SkDrawGroup.cpp */,
-				FE5F49440948A5380095980F /* SkDrawGroup.h */,
-				FE5F49450948A5380095980F /* SkDrawLine.cpp */,
-				FE5F49460948A5380095980F /* SkDrawLine.h */,
-				FE5F49470948A5380095980F /* SkDrawMatrix.cpp */,
-				FE5F49480948A5380095980F /* SkDrawMatrix.h */,
-				FE5F49490948A5380095980F /* SkDrawOval.cpp */,
-				FE5F494A0948A5380095980F /* SkDrawOval.h */,
-				FE5F494B0948A5390095980F /* SkDrawPaint.cpp */,
-				FE5F494C0948A5390095980F /* SkDrawPaint.h */,
-				FE5F494D0948A5390095980F /* SkDrawPath.cpp */,
-				FE5F494E0948A5390095980F /* SkDrawPath.h */,
-				FE5F494F0948A5390095980F /* SkDrawPoint.cpp */,
-				FE5F49500948A5390095980F /* SkDrawPoint.h */,
-				FE5F49510948A5390095980F /* SkDrawRectangle.cpp */,
-				FE5F49520948A5390095980F /* SkDrawRectangle.h */,
-				FE5F49530948A5390095980F /* SkDrawShader.cpp */,
-				FE5F49540948A5390095980F /* SkDrawShader.h */,
-				FE5F49550948A5390095980F /* SkDrawText.cpp */,
-				FE5F49560948A5390095980F /* SkDrawText.h */,
-				FE5F49570948A5390095980F /* SkDrawTextBox.cpp */,
-				FE5F49580948A5390095980F /* SkDrawTextBox.h */,
-				FE5F49590948A5390095980F /* SkDrawTo.cpp */,
-				FE51FB840A6FDCE400ABA91D /* SkDrawSaveLayer.h */,
-				FE51FB8E0A6FE7DC00ABA91D /* SkDrawSaveLayer.cpp */,
-				FE5F495A0948A5390095980F /* SkDrawTo.h */,
-				FE5F495B0948A5390095980F /* SkDrawTransparentShader.cpp */,
-				FE5F495C0948A5390095980F /* SkDrawTransparentShader.h */,
-				FE5F495D0948A5390095980F /* SkDump.cpp */,
-				FE5F495E0948A5390095980F /* SkDump.h */,
-				FE5F495F0948A5390095980F /* SkExtraPathEffects.xsd */,
-				FE5F49600948A5390095980F /* SkExtras.h */,
-				FE5F49610948A5390095980F /* SkGetCondensedInfo.cpp */,
-				FE5F49620948A5390095980F /* SkHitClear.cpp */,
-				FE5F49630948A5390095980F /* SkHitClear.h */,
-				FE5F49640948A5390095980F /* SkHitTest.cpp */,
-				FE5F49650948A5390095980F /* SkHitTest.h */,
-				FE5F49660948A5390095980F /* SkIntArray.h */,
-				FE5F49680948A5390095980F /* SkMatrixParts.cpp */,
-				FE5F49690948A5390095980F /* SkMatrixParts.h */,
-				FE5F496A0948A5390095980F /* SkMemberInfo.cpp */,
-				FE5F496B0948A5390095980F /* SkMemberInfo.h */,
-				FE5F496C0948A5390095980F /* SkOperand.h */,
-				FE5F496D0948A5390095980F /* SkOperandInterpolator.h */,
-				FE5F496E0948A5390095980F /* SkOperandIterpolator.cpp */,
-				FE5F496F0948A5390095980F /* SkPaintParts.cpp */,
-				FE5F49700948A5390095980F /* SkPaintParts.h */,
-				FE5F49710948A5390095980F /* SkPathParts.cpp */,
-				FE5F49720948A5390095980F /* SkPathParts.h */,
-				FE5F49730948A5390095980F /* SkPostParts.cpp */,
-				FE5F49740948A5390095980F /* SkPostParts.h */,
-				FE5F49750948A5390095980F /* SkScript.cpp */,
-				FE5F49760948A5390095980F /* SkScript.h */,
-				FE5F49770948A5390095980F /* SkSnapshot.cpp */,
-				FE5F49780948A5390095980F /* SkSnapshot.h */,
-				FE5F49790948A5390095980F /* SkSVGPath.cpp */,
-				FE5F497A0948A5390095980F /* SkTDArray_Experimental.h */,
-				FE5F497B0948A5390095980F /* SkTextOnPath.cpp */,
-				FE5F497C0948A5390095980F /* SkTextOnPath.h */,
-				FE5F497D0948A5390095980F /* SkTextToPath.cpp */,
-				FE5F497E0948A5390095980F /* SkTextToPath.h */,
-				FE5F497F0948A5390095980F /* SkTime.cpp */,
-				FE5F49800948A5390095980F /* SkTypedArray.cpp */,
-				FE5F49810948A5390095980F /* SkTypedArray.h */,
-				FE5F49820948A5390095980F /* SkXMLAnimatorWriter.cpp */,
-				FE5F49830948A5390095980F /* SkXMLAnimatorWriter.h */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libanimator.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE5F49840948A5390095980F /* SkAnimateBase.h in Headers */,
-				FE5F49860948A5390095980F /* SkAnimateActive.h in Headers */,
-				FE5F49880948A5390095980F /* SkAnimate.h in Headers */,
-				FE5F498A0948A5390095980F /* SkAnimateMaker.h in Headers */,
-				FE5F498C0948A5390095980F /* SkAnimateSet.h in Headers */,
-				FE5F498F0948A5390095980F /* SkAnimatorScript.h in Headers */,
-				FE5F49910948A5390095980F /* SkBase64.h in Headers */,
-				FE5F49930948A5390095980F /* SkBoundable.h in Headers */,
-				FE5F49980948A5390095980F /* SkDisplayable.h in Headers */,
-				FE5F499A0948A5390095980F /* SkDisplayAdd.h in Headers */,
-				FE5F499C0948A5390095980F /* SkDisplayApply.h in Headers */,
-				FE5F499E0948A5390095980F /* SkDisplayBounds.h in Headers */,
-				FE5F49A00948A5390095980F /* SkDisplayEvent.h in Headers */,
-				FE5F49A20948A5390095980F /* SkDisplayEvents.h in Headers */,
-				FE5F49A40948A5390095980F /* SkDisplayInclude.h in Headers */,
-				FE5F49A60948A5390095980F /* SkDisplayInput.h in Headers */,
-				FE5F49A80948A5390095980F /* SkDisplayList.h in Headers */,
-				FE5F49AA0948A5390095980F /* SkDisplayMath.h in Headers */,
-				FE5F49AC0948A5390095980F /* SkDisplayMovie.h in Headers */,
-				FE5F49AE0948A5390095980F /* SkDisplayPost.h in Headers */,
-				FE5F49B00948A5390095980F /* SkDisplayRandom.h in Headers */,
-				FE5F49B20948A5390095980F /* SkDisplayScreenplay.h in Headers */,
-				FE5F49B40948A5390095980F /* SkDisplayType.h in Headers */,
-				FE5F49B60948A5390095980F /* SkDisplayTypes.h in Headers */,
-				FE5F49B80948A5390095980F /* SkDisplayXMLParser.h in Headers */,
-				FE5F49BA0948A5390095980F /* SkDraw3D.h in Headers */,
-				FE5F49BC0948A5390095980F /* SkDrawable.h in Headers */,
-				FE5F49BE0948A5390095980F /* SkDrawBitmap.h in Headers */,
-				FE5F49C00948A5390095980F /* SkDrawBlur.h in Headers */,
-				FE5F49C20948A5390095980F /* SkDrawClip.h in Headers */,
-				FE5F49C40948A5390095980F /* SkDrawColor.h in Headers */,
-				FE5F49C60948A5390095980F /* SkDrawDash.h in Headers */,
-				FE5F49C80948A5390095980F /* SkDrawDiscrete.h in Headers */,
-				FE5F49CA0948A5390095980F /* SkDrawEmboss.h in Headers */,
-				FE5F49CD0948A5390095980F /* SkDrawFull.h in Headers */,
-				FE5F49CF0948A5390095980F /* SkDrawGradient.h in Headers */,
-				FE5F49D10948A5390095980F /* SkDrawGroup.h in Headers */,
-				FE5F49D30948A5390095980F /* SkDrawLine.h in Headers */,
-				FE5F49D50948A5390095980F /* SkDrawMatrix.h in Headers */,
-				FE5F49D70948A5390095980F /* SkDrawOval.h in Headers */,
-				FE5F49D90948A5390095980F /* SkDrawPaint.h in Headers */,
-				FE5F49DB0948A5390095980F /* SkDrawPath.h in Headers */,
-				FE5F49DD0948A5390095980F /* SkDrawPoint.h in Headers */,
-				FE5F49DF0948A5390095980F /* SkDrawRectangle.h in Headers */,
-				FE5F49E10948A5390095980F /* SkDrawShader.h in Headers */,
-				FE5F49E30948A5390095980F /* SkDrawText.h in Headers */,
-				FE5F49E50948A5390095980F /* SkDrawTextBox.h in Headers */,
-				FE5F49E70948A5390095980F /* SkDrawTo.h in Headers */,
-				FE5F49E90948A5390095980F /* SkDrawTransparentShader.h in Headers */,
-				FE5F49EB0948A5390095980F /* SkDump.h in Headers */,
-				FE5F49EC0948A5390095980F /* SkExtras.h in Headers */,
-				FE5F49EF0948A5390095980F /* SkHitClear.h in Headers */,
-				FE5F49F10948A5390095980F /* SkHitTest.h in Headers */,
-				FE5F49F20948A5390095980F /* SkIntArray.h in Headers */,
-				FE5F49F50948A5390095980F /* SkMatrixParts.h in Headers */,
-				FE5F49F70948A5390095980F /* SkMemberInfo.h in Headers */,
-				FE5F49F80948A5390095980F /* SkOperand.h in Headers */,
-				FE5F49F90948A5390095980F /* SkOperandInterpolator.h in Headers */,
-				FE5F49FC0948A5390095980F /* SkPaintParts.h in Headers */,
-				FE5F49FE0948A5390095980F /* SkPathParts.h in Headers */,
-				FE5F4A000948A5390095980F /* SkPostParts.h in Headers */,
-				FE5F4A020948A5390095980F /* SkScript.h in Headers */,
-				FE5F4A040948A5390095980F /* SkSnapshot.h in Headers */,
-				FE5F4A060948A5390095980F /* SkTDArray_Experimental.h in Headers */,
-				FE5F4A080948A5390095980F /* SkTextOnPath.h in Headers */,
-				FE5F4A0A0948A5390095980F /* SkTextToPath.h in Headers */,
-				FE5F4A0D0948A5390095980F /* SkTypedArray.h in Headers */,
-				FE5F4A0F0948A5390095980F /* SkXMLAnimatorWriter.h in Headers */,
-				FECB4EF509DF3E3600D03FF8 /* SkAnimatorScript2.h in Headers */,
-				FECB4EF709DF3E3600D03FF8 /* SkOpArray.h in Headers */,
-				FECB4EF809DF3E3600D03FF8 /* SkOperand2.h in Headers */,
-				FECB4EF909DF3E3600D03FF8 /* SkScript2.h in Headers */,
-				FECB4EFA09DF3E3600D03FF8 /* SkScriptCallBack.h in Headers */,
-				FECB4EFD09DF3E3600D03FF8 /* SkScriptRuntime.h in Headers */,
-				FE49EAAC09FD5DB800D28411 /* SkDrawExtraPathEffect.h in Headers */,
-				FE49EB4D09FE783600D28411 /* SkDisplayNumber.h in Headers */,
-				FE49EE0C09FFDB0300D28411 /* SkAnimateProperties.h in Headers */,
-				FE51FB850A6FDCE500ABA91D /* SkDrawSaveLayer.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* animator */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "animator" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = animator;
-			productName = animator;
-			productReference = D2AAC046055464E500DB518D /* libanimator.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "animator" */;
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* animator */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* animator */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FEE7D79F094613A600B11B76 /* SkAnimateBase.cpp in Sources */,
-				FE5F49850948A5390095980F /* SkAnimateActive.cpp in Sources */,
-				FE5F49870948A5390095980F /* SkAnimateField.cpp in Sources */,
-				FE5F49890948A5390095980F /* SkAnimateMaker.cpp in Sources */,
-				FE5F498B0948A5390095980F /* SkAnimateSet.cpp in Sources */,
-				FE5F498D0948A5390095980F /* SkAnimator.cpp in Sources */,
-				FE5F498E0948A5390095980F /* SkAnimatorScript.cpp in Sources */,
-				FE5F49900948A5390095980F /* SkBase64.cpp in Sources */,
-				FE5F49920948A5390095980F /* SkBoundable.cpp in Sources */,
-				FE5F49940948A5390095980F /* SkBuildCondensedInfo.cpp in Sources */,
-				FE5F49970948A5390095980F /* SkDisplayable.cpp in Sources */,
-				FE5F49990948A5390095980F /* SkDisplayAdd.cpp in Sources */,
-				FE5F499B0948A5390095980F /* SkDisplayApply.cpp in Sources */,
-				FE5F499D0948A5390095980F /* SkDisplayBounds.cpp in Sources */,
-				FE5F499F0948A5390095980F /* SkDisplayEvent.cpp in Sources */,
-				FE5F49A10948A5390095980F /* SkDisplayEvents.cpp in Sources */,
-				FE5F49A30948A5390095980F /* SkDisplayInclude.cpp in Sources */,
-				FE5F49A50948A5390095980F /* SkDisplayInput.cpp in Sources */,
-				FE5F49A70948A5390095980F /* SkDisplayList.cpp in Sources */,
-				FE5F49A90948A5390095980F /* SkDisplayMath.cpp in Sources */,
-				FE5F49AB0948A5390095980F /* SkDisplayMovie.cpp in Sources */,
-				FE5F49AD0948A5390095980F /* SkDisplayPost.cpp in Sources */,
-				FE5F49AF0948A5390095980F /* SkDisplayRandom.cpp in Sources */,
-				FE5F49B10948A5390095980F /* SkDisplayScreenplay.cpp in Sources */,
-				FE5F49B30948A5390095980F /* SkDisplayType.cpp in Sources */,
-				FE5F49B50948A5390095980F /* SkDisplayTypes.cpp in Sources */,
-				FE5F49B70948A5390095980F /* SkDisplayXMLParser.cpp in Sources */,
-				FE5F49B90948A5390095980F /* SkDraw3D.cpp in Sources */,
-				FE5F49BB0948A5390095980F /* SkDrawable.cpp in Sources */,
-				FE5F49BD0948A5390095980F /* SkDrawBitmap.cpp in Sources */,
-				FE5F49BF0948A5390095980F /* SkDrawBlur.cpp in Sources */,
-				FE5F49C10948A5390095980F /* SkDrawClip.cpp in Sources */,
-				FE5F49C30948A5390095980F /* SkDrawColor.cpp in Sources */,
-				FE5F49C50948A5390095980F /* SkDrawDash.cpp in Sources */,
-				FE5F49C70948A5390095980F /* SkDrawDiscrete.cpp in Sources */,
-				FE5F49C90948A5390095980F /* SkDrawEmboss.cpp in Sources */,
-				FE5F49CB0948A5390095980F /* SkDrawExtraPathEffect.cpp in Sources */,
-				FE5F49CC0948A5390095980F /* SkDrawFull.cpp in Sources */,
-				FE5F49CE0948A5390095980F /* SkDrawGradient.cpp in Sources */,
-				FE5F49D00948A5390095980F /* SkDrawGroup.cpp in Sources */,
-				FE5F49D20948A5390095980F /* SkDrawLine.cpp in Sources */,
-				FE5F49D40948A5390095980F /* SkDrawMatrix.cpp in Sources */,
-				FE5F49D60948A5390095980F /* SkDrawOval.cpp in Sources */,
-				FE5F49D80948A5390095980F /* SkDrawPaint.cpp in Sources */,
-				FE5F49DA0948A5390095980F /* SkDrawPath.cpp in Sources */,
-				FE5F49DC0948A5390095980F /* SkDrawPoint.cpp in Sources */,
-				FE5F49DE0948A5390095980F /* SkDrawRectangle.cpp in Sources */,
-				FE5F49E00948A5390095980F /* SkDrawShader.cpp in Sources */,
-				FE5F49E20948A5390095980F /* SkDrawText.cpp in Sources */,
-				FE5F49E40948A5390095980F /* SkDrawTextBox.cpp in Sources */,
-				FE5F49E60948A5390095980F /* SkDrawTo.cpp in Sources */,
-				FE5F49E80948A5390095980F /* SkDrawTransparentShader.cpp in Sources */,
-				FE5F49EA0948A5390095980F /* SkDump.cpp in Sources */,
-				FE5F49ED0948A5390095980F /* SkGetCondensedInfo.cpp in Sources */,
-				FE5F49EE0948A5390095980F /* SkHitClear.cpp in Sources */,
-				FE5F49F00948A5390095980F /* SkHitTest.cpp in Sources */,
-				FE5F49F40948A5390095980F /* SkMatrixParts.cpp in Sources */,
-				FE5F49F60948A5390095980F /* SkMemberInfo.cpp in Sources */,
-				FE5F49FA0948A5390095980F /* SkOperandIterpolator.cpp in Sources */,
-				FE5F49FB0948A5390095980F /* SkPaintParts.cpp in Sources */,
-				FE5F49FD0948A5390095980F /* SkPathParts.cpp in Sources */,
-				FE5F49FF0948A5390095980F /* SkPostParts.cpp in Sources */,
-				FE5F4A010948A5390095980F /* SkScript.cpp in Sources */,
-				FE5F4A030948A5390095980F /* SkSnapshot.cpp in Sources */,
-				FE5F4A050948A5390095980F /* SkSVGPath.cpp in Sources */,
-				FE5F4A070948A5390095980F /* SkTextOnPath.cpp in Sources */,
-				FE5F4A090948A5390095980F /* SkTextToPath.cpp in Sources */,
-				FE5F4A0B0948A5390095980F /* SkTime.cpp in Sources */,
-				FE5F4A0C0948A5390095980F /* SkTypedArray.cpp in Sources */,
-				FE5F4A0E0948A5390095980F /* SkXMLAnimatorWriter.cpp in Sources */,
-				FECB4EF409DF3E3600D03FF8 /* SkAnimatorScript2.cpp in Sources */,
-				FECB4EF609DF3E3600D03FF8 /* SkOpArray.cpp in Sources */,
-				FECB4EFB09DF3E3600D03FF8 /* SkScriptDecompile.cpp in Sources */,
-				FECB4EFC09DF3E3600D03FF8 /* SkScriptRuntime.cpp in Sources */,
-				FE76553E09DFF6610088D6CA /* SkScriptTokenizer.cpp in Sources */,
-				FE49EB5109FE785E00D28411 /* SkDisplayNumber.cpp in Sources */,
-				FE51FB8F0A6FE7DC00ABA91D /* SkDrawSaveLayer.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = animator;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = animator;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_BUILD_FOR_MAC;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "animator" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "animator" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/animatorTest/English.lproj/InfoPlist.strings b/ide/xcode/animatorTest/English.lproj/InfoPlist.strings
deleted file mode 100644
index 4137b0e..0000000
--- a/ide/xcode/animatorTest/English.lproj/InfoPlist.strings
+++ /dev/null
Binary files differ
diff --git a/ide/xcode/animatorTest/English.lproj/main.nib/classes.nib b/ide/xcode/animatorTest/English.lproj/main.nib/classes.nib
deleted file mode 100644
index ea58db1..0000000
--- a/ide/xcode/animatorTest/English.lproj/main.nib/classes.nib
+++ /dev/null
@@ -1,4 +0,0 @@
-{
-IBClasses = ();
-IBVersion = 1;
-}
diff --git a/ide/xcode/animatorTest/English.lproj/main.nib/info.nib b/ide/xcode/animatorTest/English.lproj/main.nib/info.nib
deleted file mode 100644
index 61c153e..0000000
--- a/ide/xcode/animatorTest/English.lproj/main.nib/info.nib
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>IBDocumentLocation</key>
-	<string>395 231 356 240 0 0 1440 938 </string>
-	<key>IBEditorPositions</key>
-	<dict>
-		<key>29</key>
-		<string>79 238 204 44 0 0 1440 938 </string>
-	</dict>
-	<key>IBFramework Version</key>
-	<string>443.0</string>
-	<key>IBOldestOS</key>
-	<integer>3</integer>
-	<key>IBOpenObjects</key>
-	<array>
-		<integer>166</integer>
-		<integer>29</integer>
-	</array>
-	<key>IBSystem Version</key>
-	<string>8F46</string>
-	<key>targetFramework</key>
-	<string>IBCarbonFramework</string>
-</dict>
-</plist>
diff --git a/ide/xcode/animatorTest/English.lproj/main.nib/objects.xib b/ide/xcode/animatorTest/English.lproj/main.nib/objects.xib
deleted file mode 100644
index 8ae9ed6..0000000
--- a/ide/xcode/animatorTest/English.lproj/main.nib/objects.xib
+++ /dev/null
@@ -1,269 +0,0 @@
-<?xml version="1.0" standalone="yes"?>
-<object class="NSIBObjectData">
-  <string name="targetFramework">IBCarbonFramework</string>
-  <object name="rootObject" class="NSCustomObject" id="1">
-    <string name="customClass">NSApplication</string>
-  </object>
-  <array count="38" name="allObjects">
-    <object class="IBCarbonMenu" id="29">
-      <string name="title">main</string>
-      <array count="4" name="items">
-        <object class="IBCarbonMenuItem" id="185">
-          <string name="title">Foo</string>
-          <object name="submenu" class="IBCarbonMenu" id="184">
-            <string name="title">Foo</string>
-            <array count="1" name="items">
-              <object class="IBCarbonMenuItem" id="187">
-                <string name="title">About Foo</string>
-                <int name="keyEquivalentModifier">0</int>
-                <ostype name="command">abou</ostype>
-              </object>
-            </array>
-            <string name="name">_NSAppleMenu</string>
-          </object>
-        </object>
-        <object class="IBCarbonMenuItem" id="127">
-          <string name="title">File</string>
-          <object name="submenu" class="IBCarbonMenu" id="131">
-            <string name="title">File</string>
-            <array count="10" name="items">
-              <object class="IBCarbonMenuItem" id="139">
-                <string name="title">New</string>
-                <string name="keyEquivalent">n</string>
-                <ostype name="command">new </ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="134">
-                <string name="title">Open…</string>
-                <string name="keyEquivalent">o</string>
-                <ostype name="command">open</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="133">
-                <boolean name="separator">TRUE</boolean>
-              </object>
-              <object class="IBCarbonMenuItem" id="130">
-                <string name="title">Close</string>
-                <string name="keyEquivalent">w</string>
-                <ostype name="command">clos</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="138">
-                <string name="title">Save</string>
-                <string name="keyEquivalent">s</string>
-                <ostype name="command">save</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="137">
-                <string name="title">Save As…</string>
-                <string name="keyEquivalent">S</string>
-                <ostype name="command">svas</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="132">
-                <string name="title">Revert</string>
-                <string name="keyEquivalent">r</string>
-                <ostype name="command">rvrt</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="128">
-                <boolean name="separator">TRUE</boolean>
-              </object>
-              <object class="IBCarbonMenuItem" id="135">
-                <string name="title">Page Setup…</string>
-                <string name="keyEquivalent">P</string>
-                <ostype name="command">page</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="136">
-                <string name="title">Print…</string>
-                <string name="keyEquivalent">p</string>
-                <ostype name="command">prnt</ostype>
-              </object>
-            </array>
-          </object>
-        </object>
-        <object class="IBCarbonMenuItem" id="152">
-          <string name="title">Edit</string>
-          <object name="submenu" class="IBCarbonMenu" id="147">
-            <string name="title">Edit</string>
-            <array count="10" name="items">
-              <object class="IBCarbonMenuItem" id="141">
-                <string name="title">Undo</string>
-                <string name="keyEquivalent">z</string>
-                <ostype name="command">undo</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="146">
-                <string name="title">Redo</string>
-                <string name="keyEquivalent">Z</string>
-                <ostype name="command">redo</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="142">
-                <boolean name="separator">TRUE</boolean>
-              </object>
-              <object class="IBCarbonMenuItem" id="143">
-                <string name="title">Cut</string>
-                <string name="keyEquivalent">x</string>
-                <ostype name="command">cut </ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="149">
-                <string name="title">Copy</string>
-                <string name="keyEquivalent">c</string>
-                <ostype name="command">copy</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="144">
-                <string name="title">Paste</string>
-                <string name="keyEquivalent">v</string>
-                <ostype name="command">past</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="151">
-                <string name="title">Delete</string>
-                <ostype name="command">clea</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="148">
-                <string name="title">Select All</string>
-                <string name="keyEquivalent">a</string>
-                <ostype name="command">sall</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="199">
-                <boolean name="separator">TRUE</boolean>
-              </object>
-              <object class="IBCarbonMenuItem" id="198">
-                <string name="title">Special Characters…</string>
-                <ostype name="command">chrp</ostype>
-              </object>
-            </array>
-          </object>
-        </object>
-        <object class="IBCarbonMenuItem" id="192">
-          <string name="title">Window</string>
-          <object name="submenu" class="IBCarbonMenu" id="195">
-            <string name="title">Window</string>
-            <array count="6" name="items">
-              <object class="IBCarbonMenuItem" id="190">
-                <boolean name="dynamic">TRUE</boolean>
-                <string name="title">Minimize</string>
-                <string name="keyEquivalent">m</string>
-                <ostype name="command">mini</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="191">
-                <boolean name="dynamic">TRUE</boolean>
-                <string name="title">Minimize All</string>
-                <string name="keyEquivalent">m</string>
-                <int name="keyEquivalentModifier">1572864</int>
-                <ostype name="command">mina</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="197">
-                <string name="title">Zoom</string>
-                <ostype name="command">zoom</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="194">
-                <boolean name="separator">TRUE</boolean>
-              </object>
-              <object class="IBCarbonMenuItem" id="196">
-                <boolean name="dynamic">TRUE</boolean>
-                <string name="title">Bring All to Front</string>
-                <ostype name="command">bfrt</ostype>
-              </object>
-              <object class="IBCarbonMenuItem" id="193">
-                <boolean name="dynamic">TRUE</boolean>
-                <string name="title">Arrange in Front</string>
-                <int name="keyEquivalentModifier">1572864</int>
-                <ostype name="command">frnt</ostype>
-              </object>
-            </array>
-            <string name="name">_NSWindowsMenu</string>
-          </object>
-        </object>
-      </array>
-      <string name="name">_NSMainMenu</string>
-    </object>
-    <reference idRef="127"/>
-    <reference idRef="128"/>
-    <reference idRef="130"/>
-    <reference idRef="131"/>
-    <reference idRef="132"/>
-    <reference idRef="133"/>
-    <reference idRef="134"/>
-    <reference idRef="135"/>
-    <reference idRef="136"/>
-    <reference idRef="137"/>
-    <reference idRef="138"/>
-    <reference idRef="139"/>
-    <reference idRef="141"/>
-    <reference idRef="142"/>
-    <reference idRef="143"/>
-    <reference idRef="144"/>
-    <reference idRef="146"/>
-    <reference idRef="147"/>
-    <reference idRef="148"/>
-    <reference idRef="149"/>
-    <reference idRef="151"/>
-    <reference idRef="152"/>
-    <object class="IBCarbonWindow" id="166">
-      <string name="windowRect">204 300 564 780 </string>
-      <string name="title">Window</string>
-      <object name="rootControl" class="IBCarbonRootControl" id="167">
-        <string name="bounds">0 0 360 480 </string>
-      </object>
-      <boolean name="liveResize">TRUE</boolean>
-      <boolean name="isConstrained">FALSE</boolean>
-    </object>
-    <reference idRef="167"/>
-    <reference idRef="184"/>
-    <reference idRef="185"/>
-    <reference idRef="187"/>
-    <reference idRef="190"/>
-    <reference idRef="191"/>
-    <reference idRef="192"/>
-    <reference idRef="193"/>
-    <reference idRef="194"/>
-    <reference idRef="195"/>
-    <reference idRef="196"/>
-    <reference idRef="197"/>
-    <reference idRef="198"/>
-    <reference idRef="199"/>
-  </array>
-  <array count="38" name="allParents">
-    <reference idRef="1"/>
-    <reference idRef="29"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="127"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="131"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="152"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-    <reference idRef="29"/>
-    <reference idRef="1"/>
-    <reference idRef="166"/>
-    <reference idRef="185"/>
-    <reference idRef="29"/>
-    <reference idRef="184"/>
-    <reference idRef="195"/>
-    <reference idRef="195"/>
-    <reference idRef="29"/>
-    <reference idRef="195"/>
-    <reference idRef="195"/>
-    <reference idRef="192"/>
-    <reference idRef="195"/>
-    <reference idRef="195"/>
-    <reference idRef="147"/>
-    <reference idRef="147"/>
-  </array>
-  <dictionary count="3" name="nameTable">
-    <string>Files Owner</string>
-    <reference idRef="1"/>
-    <string>MainWindow</string>
-    <reference idRef="166"/>
-    <string>MenuBar</string>
-    <reference idRef="29"/>
-  </dictionary>
-  <unsigned_int name="nextObjectID">200</unsigned_int>
-</object>
diff --git a/ide/xcode/animatorTest/Info.plist b/ide/xcode/animatorTest/Info.plist
deleted file mode 100644
index 90c4211..0000000
--- a/ide/xcode/animatorTest/Info.plist
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.yourcompany.animatorTest</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>CSResourcesFileMapped</key>
-	<true/>
-</dict>
-</plist>
diff --git a/ide/xcode/animatorTest/animatorTest.xcodeproj/project.pbxproj b/ide/xcode/animatorTest/animatorTest.xcodeproj/project.pbxproj
deleted file mode 100644
index 26004dc..0000000
--- a/ide/xcode/animatorTest/animatorTest.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,1112 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		8D0C4E8D0486CD37000505A6 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */; };
-		8D0C4E8E0486CD37000505A6 /* main.nib in Resources */ = {isa = PBXBuildFile; fileRef = 02345980000FD03B11CA0E72 /* main.nib */; };
-		8D0C4E920486CD37000505A6 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 20286C33FDCF999611CA2CEA /* Carbon.framework */; };
-		FE33CA3A094E2D2500C4A640 /* libgraphics.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA1F094E2CC900C4A640 /* libgraphics.a */; };
-		FE33CA3B094E2D2E00C4A640 /* libfreetype.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA19094E2CC900C4A640 /* libfreetype.a */; };
-		FE33CA49094E2D3A00C4A640 /* libports.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA1C094E2CC900C4A640 /* libports.a */; };
-		FE33CA4A094E2D4600C4A640 /* libports-mac.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA01094E2CC900C4A640 /* libports-mac.a */; };
-		FE33CA4B094E2D4D00C4A640 /* libgif.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA0A094E2CC900C4A640 /* libgif.a */; };
-		FE33CA4C094E2D5400C4A640 /* libjpeg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA0D094E2CC900C4A640 /* libjpeg.a */; };
-		FE33CA4D094E2D5B00C4A640 /* liblibpng.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA10094E2CC900C4A640 /* liblibpng.a */; };
-		FE33CA4E094E2D6600C4A640 /* libzlib.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA13094E2CC900C4A640 /* libzlib.a */; };
-		FE33CA4F094E2D7000C4A640 /* libviews.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA16094E2CC900C4A640 /* libviews.a */; };
-		FE33CA50094E2D7600C4A640 /* libanimator.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA07094E2CC900C4A640 /* libanimator.a */; };
-		FE3485990950D204003F0C3F /* libsvg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE3485980950D1EE003F0C3F /* libsvg.a */; };
-		FE61323709B616EA004BB4B8 /* libcorecg.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE61323609B616A5004BB4B8 /* libcorecg.a */; };
-		FEBB00B00D7DD8D70027C5D6 /* CacheBuilder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00A20D7DD8D70027C5D6 /* CacheBuilder.cpp */; };
-		FEBB00B10D7DD8D70027C5D6 /* CachedFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00A50D7DD8D70027C5D6 /* CachedFrame.cpp */; };
-		FEBB00B20D7DD8D70027C5D6 /* CachedHistory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00A70D7DD8D70027C5D6 /* CachedHistory.cpp */; };
-		FEBB00B30D7DD8D70027C5D6 /* CachedNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00A90D7DD8D70027C5D6 /* CachedNode.cpp */; };
-		FEBB00B40D7DD8D70027C5D6 /* CachedRoot.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00AD0D7DD8D70027C5D6 /* CachedRoot.cpp */; };
-		FEBB00B90D7DD8F20027C5D6 /* BrowserDebug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEBB00B70D7DD8F20027C5D6 /* BrowserDebug.cpp */; };
-		FEBB00C60D7DDA4A0027C5D6 /* animatorTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE33CAC4094F301100C4A640 /* animatorTest.cpp */; };
-		FEF4C9AA09574C4600F2B941 /* libexpat.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FE33CA04094E2CC900C4A640 /* libexpat.a */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXContainerItemProxy section */
-		FE33CA00094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9DE094E2CC900C4A640 /* ports-mac.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = "ports-mac";
-		};
-		FE33CA03094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E1094E2CC900C4A640 /* expat.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = expat;
-		};
-		FE33CA06094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E4094E2CC900C4A640 /* animator.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = animator;
-		};
-		FE33CA09094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E7094E2CC900C4A640 /* gif.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = gif;
-		};
-		FE33CA0C094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9EA094E2CC900C4A640 /* jpeg.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = jpeg;
-		};
-		FE33CA0F094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9ED094E2CC900C4A640 /* libpng.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = libpng;
-		};
-		FE33CA12094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F0094E2CC900C4A640 /* zlib.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = zlib;
-		};
-		FE33CA15094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F3094E2CC900C4A640 /* views.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = views;
-		};
-		FE33CA18094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F6094E2CC900C4A640 /* freetype2.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = freetype;
-		};
-		FE33CA1B094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F9094E2CC900C4A640 /* ports.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = ports;
-		};
-		FE33CA1E094E2CC900C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9FC094E2CC900C4A640 /* graphics.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC06F0554671400DB518D;
-			remoteInfo = graphics;
-		};
-		FE33CA20094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F9094E2CC900C4A640 /* ports.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = ports;
-		};
-		FE33CA22094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F3094E2CC900C4A640 /* views.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = views;
-		};
-		FE33CA24094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9ED094E2CC900C4A640 /* libpng.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = libpng;
-		};
-		FE33CA26094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E7094E2CC900C4A640 /* gif.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = gif;
-		};
-		FE33CA28094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E4094E2CC900C4A640 /* animator.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = animator;
-		};
-		FE33CA2A094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9DE094E2CC900C4A640 /* ports-mac.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = "ports-mac";
-		};
-		FE33CA2C094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9FC094E2CC900C4A640 /* graphics.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC06E0554671400DB518D;
-			remoteInfo = graphics;
-		};
-		FE33CA2E094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F6094E2CC900C4A640 /* freetype2.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = freetype;
-		};
-		FE33CA30094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9F0094E2CC900C4A640 /* zlib.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = zlib;
-		};
-		FE33CA32094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9EA094E2CC900C4A640 /* jpeg.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = jpeg;
-		};
-		FE33CA34094E2CFD00C4A640 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE33C9E1094E2CC900C4A640 /* expat.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = expat;
-		};
-		FE3485970950D1EE003F0C3F /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE3485930950D1EE003F0C3F /* svg.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = svg;
-		};
-		FE34859A0950D21C003F0C3F /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE3485930950D1EE003F0C3F /* svg.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = svg;
-		};
-		FE61323509B616A5004BB4B8 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE61323009B616A5004BB4B8 /* corecg.xcodeproj */;
-			proxyType = 2;
-			remoteGlobalIDString = D2AAC046055464E500DB518D;
-			remoteInfo = corecg;
-		};
-		FE61324709B6191D004BB4B8 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = FE61323009B616A5004BB4B8 /* corecg.xcodeproj */;
-			proxyType = 1;
-			remoteGlobalIDString = D2AAC045055464E500DB518D;
-			remoteInfo = corecg;
-		};
-/* End PBXContainerItemProxy section */
-
-/* Begin PBXFileReference section */
-		000419F90B4AD2C1002A456B /* SkFontHost_FONTPATH.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_FONTPATH.cpp; path = ../../../libs/graphics/ports/SkFontHost_FONTPATH.cpp; sourceTree = SOURCE_ROOT; };
-		000419FA0B4AD2C1002A456B /* SkFontHost_none.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_none.cpp; path = ../../../libs/graphics/ports/SkFontHost_none.cpp; sourceTree = SOURCE_ROOT; };
-		0009590E0A27775D001F29C8 /* pathTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = pathTest.cpp; path = ../../../tests/skia/animatorTest/pathTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3EE0C88591F00CC4316 /* cameraTest3.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = cameraTest3.cpp; path = ../../../tests/skia/animatorTest/cameraTest3.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3EF0C88591F00CC4316 /* ditherTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = ditherTest.cpp; path = ../../../tests/skia/animatorTest/ditherTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F00C88591F00CC4316 /* imageditherTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = imageditherTest.cpp; path = ../../../tests/skia/animatorTest/imageditherTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F10C88591F00CC4316 /* layerTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = layerTest.cpp; path = ../../../tests/skia/animatorTest/layerTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F20C88591F00CC4316 /* maskTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = maskTest.cpp; path = ../../../tests/skia/animatorTest/maskTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F30C88591F00CC4316 /* mipmapTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = mipmapTest.cpp; path = ../../../tests/skia/animatorTest/mipmapTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F40C88591F00CC4316 /* pathEffectTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = pathEffectTest.cpp; path = ../../../tests/skia/animatorTest/pathEffectTest.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F50C88591F00CC4316 /* regionToPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = regionToPath.cpp; path = ../../../tests/skia/animatorTest/regionToPath.cpp; sourceTree = SOURCE_ROOT; };
-		000BB3F60C88591F00CC4316 /* testImage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = testImage.cpp; path = ../../../tests/skia/animatorTest/testImage.cpp; sourceTree = SOURCE_ROOT; };
-		000F5ED00B77BB82007BC854 /* shaderTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = shaderTest.cpp; path = ../../../tests/skia/animatorTest/shaderTest.cpp; sourceTree = SOURCE_ROOT; };
-		001164400CE0CC3400050E37 /* SampleAll.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleAll.cpp; sourceTree = "<group>"; };
-		0011644A0CE119B800050E37 /* SampleEncode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleEncode.cpp; sourceTree = "<group>"; };
-		002136F80CFF35C80017CD78 /* SampleCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleCamera.cpp; sourceTree = "<group>"; };
-		002A08F90CE9F563009DE5DB /* SamplePath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SamplePath.cpp; sourceTree = "<group>"; };
-		0031B9800CC3A97D00366339 /* SkPackBits.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPackBits.cpp; path = ../../../libs/graphics/sgl/SkPackBits.cpp; sourceTree = SOURCE_ROOT; };
-		004F37A90D1B73EB00FCE06A /* SampleFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleFilter.cpp; sourceTree = "<group>"; };
-		00540DFD09D04C9B00307DCB /* regionTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = regionTest.cpp; path = ../../../tests/skia/animatorTest/regionTest.cpp; sourceTree = SOURCE_ROOT; };
-		00625C700CB32B70003DB915 /* SampleImage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleImage.cpp; sourceTree = "<group>"; };
-		006EEFA50AA611910064EC7C /* ninepatchTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = ninepatchTest.cpp; path = ../../../tests/skia/animatorTest/ninepatchTest.cpp; sourceTree = SOURCE_ROOT; };
-		00731B110C8F4DC900AF4FB6 /* SampleCull.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleCull.cpp; sourceTree = "<group>"; };
-		00731B120C8F4DC900AF4FB6 /* SampleLayers.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleLayers.cpp; sourceTree = "<group>"; };
-		0077DCA50B2087C000ED5E84 /* textOnPathTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = textOnPathTest.cpp; path = ../../../tests/skia/animatorTest/textOnPathTest.cpp; sourceTree = SOURCE_ROOT; };
-		0092A3610AD6EC13000FECBC /* cameraTest2.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = cameraTest2.cpp; path = ../../../tests/skia/animatorTest/cameraTest2.cpp; sourceTree = SOURCE_ROOT; };
-		00A1F4C60C90383200BCF1B6 /* SamplePoints.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SamplePoints.cpp; sourceTree = "<group>"; };
-		00A1F4C70C90383200BCF1B6 /* SampleText.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleText.cpp; sourceTree = "<group>"; };
-		00A1F4C80C90383200BCF1B6 /* SampleTiling.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleTiling.cpp; sourceTree = "<group>"; };
-		00A1F4ED0C903D1600BCF1B6 /* SampleTextOnPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleTextOnPath.cpp; sourceTree = "<group>"; };
-		00AAB9FE0A0A6DEF009B65B1 /* textTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = textTest.cpp; path = ../../../tests/skia/animatorTest/textTest.cpp; sourceTree = SOURCE_ROOT; };
-		00AB5FFF0A8267AE0038DE0A /* tilingTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = tilingTest.cpp; path = ../../../tests/skia/animatorTest/tilingTest.cpp; sourceTree = SOURCE_ROOT; };
-		00B1596D0AA37F6100B118AB /* testcull.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = testcull.cpp; path = ../../../tests/skia/animatorTest/testcull.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BA70CD01F7600BFAB53 /* jpgdec_api.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpgdec_api.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_api.h; sourceTree = SOURCE_ROOT; };
-		00BF1BA80CD01F7600BFAB53 /* jpgdec_bitstream.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_bitstream.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_bitstream.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BA90CD01F7600BFAB53 /* jpgdec_cint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_cint.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_cint.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BAA0CD01F7600BFAB53 /* jpgdec_colorconv.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_colorconv.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_colorconv.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BAB0CD01F7600BFAB53 /* jpgdec_config.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpgdec_config.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_config.h; sourceTree = SOURCE_ROOT; };
-		00BF1BAC0CD01F7600BFAB53 /* jpgdec_ct.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_ct.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_ct.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BAD0CD01F7600BFAB53 /* jpgdec_decoder.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_decoder.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_decoder.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BAE0CD01F7600BFAB53 /* jpgdec_error.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpgdec_error.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_error.h; sourceTree = SOURCE_ROOT; };
-		00BF1BAF0CD01F7600BFAB53 /* jpgdec_header.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_header.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_header.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB00CD01F7600BFAB53 /* jpgdec_huffman.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_huffman.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_huffman.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB10CD01F7600BFAB53 /* jpgdec_idctp.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_idctp.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_idctp.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB20CD01F7600BFAB53 /* jpgdec_idcts.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_idcts.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_idcts.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB30CD01F7600BFAB53 /* jpgdec_prototype.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpgdec_prototype.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_prototype.h; sourceTree = SOURCE_ROOT; };
-		00BF1BB40CD01F7600BFAB53 /* jpgdec_scan.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_scan.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_scan.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB50CD01F7600BFAB53 /* jpgdec_table.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_table.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_table.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB60CD01F7600BFAB53 /* jpgdec_table.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpgdec_table.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_table.h; sourceTree = SOURCE_ROOT; };
-		00BF1BB70CD01F7600BFAB53 /* jpgdec_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_utils.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_utils.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB80CD01F7600BFAB53 /* pvjpgdecoder_factory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = pvjpgdecoder_factory.cpp; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/pvjpgdecoder_factory.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1BB90CD01F7600BFAB53 /* pvjpgdecoder.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = pvjpgdecoder.h; path = ../../../extlibs/pv/codecs_v2/image/jpeg/dec/src/pvjpgdecoder.h; sourceTree = SOURCE_ROOT; };
-		00BF1E950CD0274100BFAB53 /* SkImageDecoder_libpvjpeg.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libpvjpeg.cpp; path = ../../../libs/graphics/images/SkImageDecoder_libpvjpeg.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F240CD0E40D00BFAB53 /* oscl_assert.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_assert.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_assert.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F250CD0E40E00BFAB53 /* oscl_base.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_base.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_base.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F260CD0E40E00BFAB53 /* oscl_byte_order.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_byte_order.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_byte_order.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F270CD0E40E00BFAB53 /* oscl_int64_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_int64_utils.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_int64_utils.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F280CD0E40E00BFAB53 /* oscl_int64.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_int64.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_int64.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F290CD0E40E00BFAB53 /* oscl_mem_basic_functions.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mem_basic_functions.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_mem_basic_functions.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2A0CD0E40E00BFAB53 /* oscl_singleton.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_singleton.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_singleton.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2B0CD0E40E00BFAB53 /* oscl_stdstring.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_stdstring.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_stdstring.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2C0CD0E40E00BFAB53 /* oscl_string_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_string_utils.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_string_utils.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2D0CD0E40E00BFAB53 /* oscl_tagtree.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_tagtree.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_tagtree.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2E0CD0E40E00BFAB53 /* oscl_tree.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_tree.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_tree.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F2F0CD0E40E00BFAB53 /* oscl_uint64.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_uint64.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_uint64.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F520CD0E4A700BFAB53 /* oscl_tls.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_tls.cpp; path = ../../../extlibs/pv/oscl/oscl/osclbase/src/oscl_tls.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F5D0CD0E52300BFAB53 /* oscl_errno.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_errno.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_errno.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F5E0CD0E52300BFAB53 /* oscl_error_imp_jumps.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_error_imp_jumps.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_error_imp_jumps.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F5F0CD0E52300BFAB53 /* oscl_error_trapcleanup.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_error_trapcleanup.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_error_trapcleanup.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F600CD0E52300BFAB53 /* oscl_heapbase.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_heapbase.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_heapbase.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F610CD0E52300BFAB53 /* oscl_mempool_allocator.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mempool_allocator.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_mempool_allocator.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F6E0CD0E56A00BFAB53 /* oscl_error.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_error.cpp; path = ../../../extlibs/pv/oscl/oscl/osclerror/src/oscl_error.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F790CD0E5BB00BFAB53 /* oscl_mem_audit.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mem_audit.cpp; path = ../../../extlibs/pv/oscl/oscl/osclmemory/src/oscl_mem_audit.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F7A0CD0E5BB00BFAB53 /* oscl_mem_imp.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mem_imp.cpp; path = ../../../extlibs/pv/oscl/oscl/osclmemory/src/oscl_mem_imp.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F7B0CD0E5BB00BFAB53 /* oscl_mem_mempool.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mem_mempool.cpp; path = ../../../extlibs/pv/oscl/oscl/osclmemory/src/oscl_mem_mempool.cpp; sourceTree = SOURCE_ROOT; };
-		00BF1F7C0CD0E5BB00BFAB53 /* oscl_mem.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = oscl_mem.cpp; path = ../../../extlibs/pv/oscl/oscl/osclmemory/src/oscl_mem.cpp; sourceTree = SOURCE_ROOT; };
-		00C7F00B0ADBDC6200202BAB /* cameraTest4.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = cameraTest4.cpp; path = ../../../tests/skia/animatorTest/cameraTest4.cpp; sourceTree = SOURCE_ROOT; };
-		00E6E1790CCCE62A00F102DB /* SampleImageDir.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleImageDir.cpp; sourceTree = "<group>"; };
-		00E6E2B90CCD122A00F102DB /* SampleFontCache.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleFontCache.cpp; sourceTree = "<group>"; };
-		00F0528D0AD2D26D00B085B7 /* testbitmaptile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = testbitmaptile.cpp; path = ../../../tests/skia/animatorTest/testbitmaptile.cpp; sourceTree = SOURCE_ROOT; };
-		00F0DC640D1846C00089B0C1 /* SampleDither.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleDither.cpp; sourceTree = "<group>"; };
-		00F6F7C70C8F1C890064A10D /* SampleApp.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleApp.cpp; sourceTree = "<group>"; };
-		00F6F7C80C8F1C890064A10D /* SampleArc.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleArc.cpp; sourceTree = "<group>"; };
-		00F6F7C90C8F1C890064A10D /* SamplePathEffects.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SamplePathEffects.cpp; sourceTree = "<group>"; };
-		00F6F7CA0C8F1C890064A10D /* SampleRegion.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleRegion.cpp; sourceTree = "<group>"; };
-		00F6F7CB0C8F1C890064A10D /* SampleShaders.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleShaders.cpp; sourceTree = "<group>"; };
-		00F6F7CC0C8F1C890064A10D /* SampleTextEffects.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SampleTextEffects.cpp; sourceTree = "<group>"; };
-		00F714FB0ACC056500453651 /* TextSpeedTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = TextSpeedTest.cpp; path = ../../../tests/skia/animatorTest/TextSpeedTest.cpp; sourceTree = SOURCE_ROOT; };
-		0867D6ABFE840B52C02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		1870340FFE93FCAF11CA0CD7 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/main.nib; sourceTree = "<group>"; };
-		20286C33FDCF999611CA2CEA /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = /System/Library/Frameworks/Carbon.framework; sourceTree = "<absolute>"; };
-		32DBCF6D0370B57F00C91783 /* animatorTest_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = animatorTest_Prefix.pch; sourceTree = "<group>"; };
-		4A9504C8FFE6A3BC11CA0CBA /* ApplicationServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = ApplicationServices.framework; path = /System/Library/Frameworks/ApplicationServices.framework; sourceTree = "<absolute>"; };
-		4A9504CAFFE6A41611CA0CBA /* CoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreServices.framework; path = /System/Library/Frameworks/CoreServices.framework; sourceTree = "<absolute>"; };
-		8D0C4E960486CD37000505A6 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist; path = Info.plist; sourceTree = "<group>"; };
-		8D0C4E970486CD37000505A6 /* animatorTest.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = animatorTest.app; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE21C73309537F3800D016FB /* animatorTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = animatorTest.h; path = ../../../tests/skia/animatorTest/animatorTest.h; sourceTree = SOURCE_ROOT; };
-		FE33C9DE094E2CC900C4A640 /* ports-mac.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = "ports-mac.xcodeproj"; path = "../ports-mac.xcodeproj"; sourceTree = SOURCE_ROOT; };
-		FE33C9E1094E2CC900C4A640 /* expat.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = expat.xcodeproj; path = ../expat.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9E4094E2CC900C4A640 /* animator.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = animator.xcodeproj; path = ../animator.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9E7094E2CC900C4A640 /* gif.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = gif.xcodeproj; path = ../gif.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9EA094E2CC900C4A640 /* jpeg.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = jpeg.xcodeproj; path = ../jpeg.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9ED094E2CC900C4A640 /* libpng.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = libpng.xcodeproj; path = ../libpng.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9F0094E2CC900C4A640 /* zlib.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = zlib.xcodeproj; path = ../zlib.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9F3094E2CC900C4A640 /* views.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = views.xcodeproj; path = ../views.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9F6094E2CC900C4A640 /* freetype2.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = freetype2.xcodeproj; path = ../freetype2.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9F9094E2CC900C4A640 /* ports.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = ports.xcodeproj; path = ../ports.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33C9FC094E2CC900C4A640 /* graphics.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = graphics.xcodeproj; path = ../graphics.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE33CAC4094F301100C4A640 /* animatorTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = animatorTest.cpp; path = ../../../tests/skia/animatorTest/animatorTest.cpp; sourceTree = SOURCE_ROOT; };
-		FE3485930950D1EE003F0C3F /* svg.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = svg.xcodeproj; path = ../svg.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FE61323009B616A5004BB4B8 /* corecg.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = corecg.xcodeproj; path = ../corecg.xcodeproj; sourceTree = SOURCE_ROOT; };
-		FEACF22A09E4636400D0C2E2 /* animatorUnitTest.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = animatorUnitTest.cpp; path = ../../../tests/skia/animatorTest/animatorUnitTest.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00A20D7DD8D70027C5D6 /* CacheBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = CacheBuilder.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CacheBuilder.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00A30D7DD8D70027C5D6 /* CacheBuilder.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CacheBuilder.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CacheBuilder.h; sourceTree = SOURCE_ROOT; };
-		FEBB00A40D7DD8D70027C5D6 /* CachedDebug.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedDebug.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedDebug.h; sourceTree = SOURCE_ROOT; };
-		FEBB00A50D7DD8D70027C5D6 /* CachedFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = CachedFrame.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedFrame.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00A60D7DD8D70027C5D6 /* CachedFrame.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedFrame.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedFrame.h; sourceTree = SOURCE_ROOT; };
-		FEBB00A70D7DD8D70027C5D6 /* CachedHistory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = CachedHistory.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedHistory.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00A80D7DD8D70027C5D6 /* CachedHistory.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedHistory.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedHistory.h; sourceTree = SOURCE_ROOT; };
-		FEBB00A90D7DD8D70027C5D6 /* CachedNode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = CachedNode.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedNode.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00AA0D7DD8D70027C5D6 /* CachedNode.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedNode.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedNode.h; sourceTree = SOURCE_ROOT; };
-		FEBB00AB0D7DD8D70027C5D6 /* CachedNodeType.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedNodeType.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedNodeType.h; sourceTree = SOURCE_ROOT; };
-		FEBB00AC0D7DD8D70027C5D6 /* CachedPrefix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedPrefix.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedPrefix.h; sourceTree = SOURCE_ROOT; };
-		FEBB00AD0D7DD8D70027C5D6 /* CachedRoot.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = CachedRoot.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedRoot.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00AE0D7DD8D70027C5D6 /* CachedRoot.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = CachedRoot.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/CachedRoot.h; sourceTree = SOURCE_ROOT; };
-		FEBB00AF0D7DD8D70027C5D6 /* WebView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = WebView.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/nav/WebView.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00B70D7DD8F20027C5D6 /* BrowserDebug.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = BrowserDebug.cpp; path = ../../../tests/browser/focusNavigation/BrowserDebug.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00B80D7DD8F20027C5D6 /* BrowserDebug.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = BrowserDebug.h; path = ../../../tests/browser/focusNavigation/BrowserDebug.h; sourceTree = SOURCE_ROOT; };
-		FEBB00D20D7DE0710027C5D6 /* android_widget_htmlwidget.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = android_widget_htmlwidget.cpp; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/jni/android_widget_htmlwidget.cpp; sourceTree = SOURCE_ROOT; };
-		FEBB00D30D7DE0710027C5D6 /* android_widget_htmlwidget.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = android_widget_htmlwidget.h; path = ../../../libs/WebKitLib/WebKit/WebCore/platform/android/jni/android_widget_htmlwidget.h; sourceTree = SOURCE_ROOT; };
-		FEBB00D60D7DE0B50027C5D6 /* WebView.java */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.java; name = WebView.java; path = ../../../java/android/android/webkit/WebView.java; sourceTree = SOURCE_ROOT; };
-		FEBB00D70D7DE0B50027C5D6 /* WebViewCore.java */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.java; name = WebViewCore.java; path = ../../../java/android/android/webkit/WebViewCore.java; sourceTree = SOURCE_ROOT; };
-		FEDCDA7309B892550042D964 /* masterList.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = masterList.cpp; path = ../../../tests/skia/masterList/masterList.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		8D0C4E910486CD37000505A6 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE33CA50094E2D7600C4A640 /* libanimator.a in Frameworks */,
-				FE3485990950D204003F0C3F /* libsvg.a in Frameworks */,
-				FE33CA4F094E2D7000C4A640 /* libviews.a in Frameworks */,
-				FE33CA3A094E2D2500C4A640 /* libgraphics.a in Frameworks */,
-				FE61323709B616EA004BB4B8 /* libcorecg.a in Frameworks */,
-				FE33CA3B094E2D2E00C4A640 /* libfreetype.a in Frameworks */,
-				FEF4C9AA09574C4600F2B941 /* libexpat.a in Frameworks */,
-				FE33CA49094E2D3A00C4A640 /* libports.a in Frameworks */,
-				FE33CA4A094E2D4600C4A640 /* libports-mac.a in Frameworks */,
-				FE33CA4C094E2D5400C4A640 /* libjpeg.a in Frameworks */,
-				FE33CA4B094E2D4D00C4A640 /* libgif.a in Frameworks */,
-				FE33CA4D094E2D5B00C4A640 /* liblibpng.a in Frameworks */,
-				FE33CA4E094E2D6600C4A640 /* libzlib.a in Frameworks */,
-				8D0C4E920486CD37000505A6 /* Carbon.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		00BF1BA60CD01F5200BFAB53 /* pv_decode */ = {
-			isa = PBXGroup;
-			children = (
-				00BF1F790CD0E5BB00BFAB53 /* oscl_mem_audit.cpp */,
-				00BF1F7A0CD0E5BB00BFAB53 /* oscl_mem_imp.cpp */,
-				00BF1F7B0CD0E5BB00BFAB53 /* oscl_mem_mempool.cpp */,
-				00BF1F7C0CD0E5BB00BFAB53 /* oscl_mem.cpp */,
-				00BF1F6E0CD0E56A00BFAB53 /* oscl_error.cpp */,
-				00BF1F5D0CD0E52300BFAB53 /* oscl_errno.cpp */,
-				00BF1F5E0CD0E52300BFAB53 /* oscl_error_imp_jumps.cpp */,
-				00BF1F5F0CD0E52300BFAB53 /* oscl_error_trapcleanup.cpp */,
-				00BF1F600CD0E52300BFAB53 /* oscl_heapbase.cpp */,
-				00BF1F610CD0E52300BFAB53 /* oscl_mempool_allocator.cpp */,
-				00BF1F520CD0E4A700BFAB53 /* oscl_tls.cpp */,
-				00BF1F240CD0E40D00BFAB53 /* oscl_assert.cpp */,
-				00BF1F250CD0E40E00BFAB53 /* oscl_base.cpp */,
-				00BF1F260CD0E40E00BFAB53 /* oscl_byte_order.cpp */,
-				00BF1F270CD0E40E00BFAB53 /* oscl_int64_utils.cpp */,
-				00BF1F280CD0E40E00BFAB53 /* oscl_int64.cpp */,
-				00BF1F290CD0E40E00BFAB53 /* oscl_mem_basic_functions.cpp */,
-				00BF1F2A0CD0E40E00BFAB53 /* oscl_singleton.cpp */,
-				00BF1F2B0CD0E40E00BFAB53 /* oscl_stdstring.cpp */,
-				00BF1F2C0CD0E40E00BFAB53 /* oscl_string_utils.cpp */,
-				00BF1F2D0CD0E40E00BFAB53 /* oscl_tagtree.cpp */,
-				00BF1F2E0CD0E40E00BFAB53 /* oscl_tree.cpp */,
-				00BF1F2F0CD0E40E00BFAB53 /* oscl_uint64.cpp */,
-				00BF1BA70CD01F7600BFAB53 /* jpgdec_api.h */,
-				00BF1BA80CD01F7600BFAB53 /* jpgdec_bitstream.cpp */,
-				00BF1BA90CD01F7600BFAB53 /* jpgdec_cint.cpp */,
-				00BF1BAA0CD01F7600BFAB53 /* jpgdec_colorconv.cpp */,
-				00BF1BAB0CD01F7600BFAB53 /* jpgdec_config.h */,
-				00BF1BAC0CD01F7600BFAB53 /* jpgdec_ct.cpp */,
-				00BF1BAD0CD01F7600BFAB53 /* jpgdec_decoder.cpp */,
-				00BF1BAE0CD01F7600BFAB53 /* jpgdec_error.h */,
-				00BF1BAF0CD01F7600BFAB53 /* jpgdec_header.cpp */,
-				00BF1BB00CD01F7600BFAB53 /* jpgdec_huffman.cpp */,
-				00BF1BB10CD01F7600BFAB53 /* jpgdec_idctp.cpp */,
-				00BF1BB20CD01F7600BFAB53 /* jpgdec_idcts.cpp */,
-				00BF1BB30CD01F7600BFAB53 /* jpgdec_prototype.h */,
-				00BF1BB40CD01F7600BFAB53 /* jpgdec_scan.cpp */,
-				00BF1BB50CD01F7600BFAB53 /* jpgdec_table.cpp */,
-				00BF1BB60CD01F7600BFAB53 /* jpgdec_table.h */,
-				00BF1BB70CD01F7600BFAB53 /* jpgdec_utils.cpp */,
-				00BF1BB80CD01F7600BFAB53 /* pvjpgdecoder_factory.cpp */,
-				00BF1BB90CD01F7600BFAB53 /* pvjpgdecoder.h */,
-			);
-			name = pv_decode;
-			sourceTree = "<group>";
-		};
-		00F6F7C50C8F1C890064A10D /* SampleCode */ = {
-			isa = PBXGroup;
-			children = (
-				00F6F7C70C8F1C890064A10D /* SampleApp.cpp */,
-				00F6F7C80C8F1C890064A10D /* SampleArc.cpp */,
-				0011644A0CE119B800050E37 /* SampleEncode.cpp */,
-				001164400CE0CC3400050E37 /* SampleAll.cpp */,
-				00A1F4C60C90383200BCF1B6 /* SamplePoints.cpp */,
-				00A1F4C70C90383200BCF1B6 /* SampleText.cpp */,
-				00A1F4C80C90383200BCF1B6 /* SampleTiling.cpp */,
-				00731B110C8F4DC900AF4FB6 /* SampleCull.cpp */,
-				002136F80CFF35C80017CD78 /* SampleCamera.cpp */,
-				00731B120C8F4DC900AF4FB6 /* SampleLayers.cpp */,
-				00F0DC640D1846C00089B0C1 /* SampleDither.cpp */,
-				004F37A90D1B73EB00FCE06A /* SampleFilter.cpp */,
-				00F6F7C90C8F1C890064A10D /* SamplePathEffects.cpp */,
-				00F6F7CA0C8F1C890064A10D /* SampleRegion.cpp */,
-				00F6F7CB0C8F1C890064A10D /* SampleShaders.cpp */,
-				00625C700CB32B70003DB915 /* SampleImage.cpp */,
-				002A08F90CE9F563009DE5DB /* SamplePath.cpp */,
-				00E6E1790CCCE62A00F102DB /* SampleImageDir.cpp */,
-				00E6E2B90CCD122A00F102DB /* SampleFontCache.cpp */,
-				00F6F7CC0C8F1C890064A10D /* SampleTextEffects.cpp */,
-				00A1F4ED0C903D1600BCF1B6 /* SampleTextOnPath.cpp */,
-			);
-			name = SampleCode;
-			path = ../../../tests/skia/SampleCode;
-			sourceTree = SOURCE_ROOT;
-		};
-		195DF8CFFE9D517E11CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				8D0C4E970486CD37000505A6 /* animatorTest.app */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		20286C29FDCF999611CA2CEA /* animatorTest */ = {
-			isa = PBXGroup;
-			children = (
-				00BF1BA60CD01F5200BFAB53 /* pv_decode */,
-				00F6F7C50C8F1C890064A10D /* SampleCode */,
-				FE33C9E1094E2CC900C4A640 /* expat.xcodeproj */,
-				FE61323009B616A5004BB4B8 /* corecg.xcodeproj */,
-				FE3485930950D1EE003F0C3F /* svg.xcodeproj */,
-				FE33C9DE094E2CC900C4A640 /* ports-mac.xcodeproj */,
-				FE33C9E4094E2CC900C4A640 /* animator.xcodeproj */,
-				FE33C9E7094E2CC900C4A640 /* gif.xcodeproj */,
-				FE33C9EA094E2CC900C4A640 /* jpeg.xcodeproj */,
-				FE33C9ED094E2CC900C4A640 /* libpng.xcodeproj */,
-				FE33C9F0094E2CC900C4A640 /* zlib.xcodeproj */,
-				FE33C9F3094E2CC900C4A640 /* views.xcodeproj */,
-				FE33C9F6094E2CC900C4A640 /* freetype2.xcodeproj */,
-				FE33C9F9094E2CC900C4A640 /* ports.xcodeproj */,
-				FE33C9FC094E2CC900C4A640 /* graphics.xcodeproj */,
-				20286C2AFDCF999611CA2CEA /* Sources */,
-				20286C2CFDCF999611CA2CEA /* Resources */,
-				20286C32FDCF999611CA2CEA /* External Frameworks and Libraries */,
-				195DF8CFFE9D517E11CA2CBB /* Products */,
-				00BF1E950CD0274100BFAB53 /* SkImageDecoder_libpvjpeg.cpp */,
-			);
-			name = animatorTest;
-			sourceTree = "<group>";
-		};
-		20286C2AFDCF999611CA2CEA /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				FEBB00D60D7DE0B50027C5D6 /* WebView.java */,
-				FEBB00D70D7DE0B50027C5D6 /* WebViewCore.java */,
-				FEBB00D20D7DE0710027C5D6 /* android_widget_htmlwidget.cpp */,
-				FEBB00D30D7DE0710027C5D6 /* android_widget_htmlwidget.h */,
-				FEBB00B70D7DD8F20027C5D6 /* BrowserDebug.cpp */,
-				FEBB00B80D7DD8F20027C5D6 /* BrowserDebug.h */,
-				FEBB00A20D7DD8D70027C5D6 /* CacheBuilder.cpp */,
-				FEBB00A30D7DD8D70027C5D6 /* CacheBuilder.h */,
-				FEBB00A40D7DD8D70027C5D6 /* CachedDebug.h */,
-				FEBB00A50D7DD8D70027C5D6 /* CachedFrame.cpp */,
-				FEBB00A60D7DD8D70027C5D6 /* CachedFrame.h */,
-				FEBB00A70D7DD8D70027C5D6 /* CachedHistory.cpp */,
-				FEBB00A80D7DD8D70027C5D6 /* CachedHistory.h */,
-				FEBB00A90D7DD8D70027C5D6 /* CachedNode.cpp */,
-				FEBB00AA0D7DD8D70027C5D6 /* CachedNode.h */,
-				FEBB00AB0D7DD8D70027C5D6 /* CachedNodeType.h */,
-				FEBB00AC0D7DD8D70027C5D6 /* CachedPrefix.h */,
-				FEBB00AD0D7DD8D70027C5D6 /* CachedRoot.cpp */,
-				FEBB00AE0D7DD8D70027C5D6 /* CachedRoot.h */,
-				FEBB00AF0D7DD8D70027C5D6 /* WebView.cpp */,
-				0031B9800CC3A97D00366339 /* SkPackBits.cpp */,
-				000BB3EE0C88591F00CC4316 /* cameraTest3.cpp */,
-				000BB3EF0C88591F00CC4316 /* ditherTest.cpp */,
-				000BB3F00C88591F00CC4316 /* imageditherTest.cpp */,
-				000BB3F10C88591F00CC4316 /* layerTest.cpp */,
-				000BB3F20C88591F00CC4316 /* maskTest.cpp */,
-				000BB3F30C88591F00CC4316 /* mipmapTest.cpp */,
-				000BB3F40C88591F00CC4316 /* pathEffectTest.cpp */,
-				000BB3F50C88591F00CC4316 /* regionToPath.cpp */,
-				000BB3F60C88591F00CC4316 /* testImage.cpp */,
-				000419F90B4AD2C1002A456B /* SkFontHost_FONTPATH.cpp */,
-				000419FA0B4AD2C1002A456B /* SkFontHost_none.cpp */,
-				00C7F00B0ADBDC6200202BAB /* cameraTest4.cpp */,
-				00F0528D0AD2D26D00B085B7 /* testbitmaptile.cpp */,
-				00B1596D0AA37F6100B118AB /* testcull.cpp */,
-				FEACF22A09E4636400D0C2E2 /* animatorUnitTest.cpp */,
-				0009590E0A27775D001F29C8 /* pathTest.cpp */,
-				006EEFA50AA611910064EC7C /* ninepatchTest.cpp */,
-				00540DFD09D04C9B00307DCB /* regionTest.cpp */,
-				00AAB9FE0A0A6DEF009B65B1 /* textTest.cpp */,
-				00F714FB0ACC056500453651 /* TextSpeedTest.cpp */,
-				000F5ED00B77BB82007BC854 /* shaderTest.cpp */,
-				0092A3610AD6EC13000FECBC /* cameraTest2.cpp */,
-				0077DCA50B2087C000ED5E84 /* textOnPathTest.cpp */,
-				00AB5FFF0A8267AE0038DE0A /* tilingTest.cpp */,
-				FEDCDA7309B892550042D964 /* masterList.cpp */,
-				FE21C73309537F3800D016FB /* animatorTest.h */,
-				FE33CAC4094F301100C4A640 /* animatorTest.cpp */,
-				32DBCF6D0370B57F00C91783 /* animatorTest_Prefix.pch */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		20286C2CFDCF999611CA2CEA /* Resources */ = {
-			isa = PBXGroup;
-			children = (
-				8D0C4E960486CD37000505A6 /* Info.plist */,
-				0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */,
-				02345980000FD03B11CA0E72 /* main.nib */,
-			);
-			name = Resources;
-			sourceTree = "<group>";
-		};
-		20286C32FDCF999611CA2CEA /* External Frameworks and Libraries */ = {
-			isa = PBXGroup;
-			children = (
-				20286C33FDCF999611CA2CEA /* Carbon.framework */,
-				4A9504CAFFE6A41611CA0CBA /* CoreServices.framework */,
-				4A9504C8FFE6A3BC11CA0CBA /* ApplicationServices.framework */,
-			);
-			name = "External Frameworks and Libraries";
-			sourceTree = "<group>";
-		};
-		FE33C9DF094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA01094E2CC900C4A640 /* libports-mac.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9E2094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA04094E2CC900C4A640 /* libexpat.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9E5094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA07094E2CC900C4A640 /* libanimator.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9E8094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA0A094E2CC900C4A640 /* libgif.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9EB094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA0D094E2CC900C4A640 /* libjpeg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9EE094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA10094E2CC900C4A640 /* liblibpng.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9F1094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA13094E2CC900C4A640 /* libzlib.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9F4094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA16094E2CC900C4A640 /* libviews.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9F7094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA19094E2CC900C4A640 /* libfreetype.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9FA094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA1C094E2CC900C4A640 /* libports.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE33C9FD094E2CC900C4A640 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE33CA1F094E2CC900C4A640 /* libgraphics.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE3485940950D1EE003F0C3F /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE3485980950D1EE003F0C3F /* libsvg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		FE61323109B616A5004BB4B8 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE61323609B616A5004BB4B8 /* libcorecg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		8D0C4E890486CD37000505A6 /* animatorTest */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = C0E91AC508A95435008D54AB /* Build configuration list for PBXNativeTarget "animatorTest" */;
-			buildPhases = (
-				8D0C4E8C0486CD37000505A6 /* Resources */,
-				8D0C4E8F0486CD37000505A6 /* Sources */,
-				8D0C4E910486CD37000505A6 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-				FE33CA21094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA23094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA25094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA27094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA29094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA2B094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA2D094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA2F094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA31094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA33094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE33CA35094E2CFD00C4A640 /* PBXTargetDependency */,
-				FE34859B0950D21C003F0C3F /* PBXTargetDependency */,
-				FE61324809B6191D004BB4B8 /* PBXTargetDependency */,
-			);
-			name = animatorTest;
-			productInstallPath = "$(HOME)/Applications";
-			productName = animatorTest;
-			productReference = 8D0C4E970486CD37000505A6 /* animatorTest.app */;
-			productType = "com.apple.product-type.application";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		20286C28FDCF999611CA2CEA /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = C0E91AC908A95435008D54AB /* Build configuration list for PBXProject "animatorTest" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 20286C29FDCF999611CA2CEA /* animatorTest */;
-			projectDirPath = "";
-			projectReferences = (
-				{
-					ProductGroup = FE33C9E5094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9E4094E2CC900C4A640 /* animator.xcodeproj */;
-				},
-				{
-					ProductGroup = FE61323109B616A5004BB4B8 /* Products */;
-					ProjectRef = FE61323009B616A5004BB4B8 /* corecg.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9E2094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9E1094E2CC900C4A640 /* expat.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9F7094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9F6094E2CC900C4A640 /* freetype2.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9E8094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9E7094E2CC900C4A640 /* gif.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9FD094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9FC094E2CC900C4A640 /* graphics.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9EB094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9EA094E2CC900C4A640 /* jpeg.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9EE094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9ED094E2CC900C4A640 /* libpng.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9DF094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9DE094E2CC900C4A640 /* ports-mac.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9FA094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9F9094E2CC900C4A640 /* ports.xcodeproj */;
-				},
-				{
-					ProductGroup = FE3485940950D1EE003F0C3F /* Products */;
-					ProjectRef = FE3485930950D1EE003F0C3F /* svg.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9F4094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9F3094E2CC900C4A640 /* views.xcodeproj */;
-				},
-				{
-					ProductGroup = FE33C9F1094E2CC900C4A640 /* Products */;
-					ProjectRef = FE33C9F0094E2CC900C4A640 /* zlib.xcodeproj */;
-				},
-			);
-			projectRoot = "";
-			targets = (
-				8D0C4E890486CD37000505A6 /* animatorTest */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXReferenceProxy section */
-		FE33CA01094E2CC900C4A640 /* libports-mac.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = "libports-mac.a";
-			remoteRef = FE33CA00094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA04094E2CC900C4A640 /* libexpat.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libexpat.a;
-			remoteRef = FE33CA03094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA07094E2CC900C4A640 /* libanimator.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libanimator.a;
-			remoteRef = FE33CA06094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA0A094E2CC900C4A640 /* libgif.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libgif.a;
-			remoteRef = FE33CA09094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA0D094E2CC900C4A640 /* libjpeg.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libjpeg.a;
-			remoteRef = FE33CA0C094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA10094E2CC900C4A640 /* liblibpng.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = liblibpng.a;
-			remoteRef = FE33CA0F094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA13094E2CC900C4A640 /* libzlib.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libzlib.a;
-			remoteRef = FE33CA12094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA16094E2CC900C4A640 /* libviews.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libviews.a;
-			remoteRef = FE33CA15094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA19094E2CC900C4A640 /* libfreetype.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libfreetype.a;
-			remoteRef = FE33CA18094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA1C094E2CC900C4A640 /* libports.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libports.a;
-			remoteRef = FE33CA1B094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE33CA1F094E2CC900C4A640 /* libgraphics.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libgraphics.a;
-			remoteRef = FE33CA1E094E2CC900C4A640 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE3485980950D1EE003F0C3F /* libsvg.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libsvg.a;
-			remoteRef = FE3485970950D1EE003F0C3F /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-		FE61323609B616A5004BB4B8 /* libcorecg.a */ = {
-			isa = PBXReferenceProxy;
-			fileType = archive.ar;
-			path = libcorecg.a;
-			remoteRef = FE61323509B616A5004BB4B8 /* PBXContainerItemProxy */;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-/* End PBXReferenceProxy section */
-
-/* Begin PBXResourcesBuildPhase section */
-		8D0C4E8C0486CD37000505A6 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				8D0C4E8D0486CD37000505A6 /* InfoPlist.strings in Resources */,
-				8D0C4E8E0486CD37000505A6 /* main.nib in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		8D0C4E8F0486CD37000505A6 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FEBB00B00D7DD8D70027C5D6 /* CacheBuilder.cpp in Sources */,
-				FEBB00B10D7DD8D70027C5D6 /* CachedFrame.cpp in Sources */,
-				FEBB00B20D7DD8D70027C5D6 /* CachedHistory.cpp in Sources */,
-				FEBB00B30D7DD8D70027C5D6 /* CachedNode.cpp in Sources */,
-				FEBB00B40D7DD8D70027C5D6 /* CachedRoot.cpp in Sources */,
-				FEBB00B90D7DD8F20027C5D6 /* BrowserDebug.cpp in Sources */,
-				FEBB00C60D7DDA4A0027C5D6 /* animatorTest.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXTargetDependency section */
-		FE33CA21094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = ports;
-			targetProxy = FE33CA20094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA23094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = views;
-			targetProxy = FE33CA22094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA25094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = libpng;
-			targetProxy = FE33CA24094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA27094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = gif;
-			targetProxy = FE33CA26094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA29094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = animator;
-			targetProxy = FE33CA28094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA2B094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = "ports-mac";
-			targetProxy = FE33CA2A094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA2D094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = graphics;
-			targetProxy = FE33CA2C094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA2F094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = freetype;
-			targetProxy = FE33CA2E094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA31094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = zlib;
-			targetProxy = FE33CA30094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA33094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = jpeg;
-			targetProxy = FE33CA32094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE33CA35094E2CFD00C4A640 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = expat;
-			targetProxy = FE33CA34094E2CFD00C4A640 /* PBXContainerItemProxy */;
-		};
-		FE34859B0950D21C003F0C3F /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = svg;
-			targetProxy = FE34859A0950D21C003F0C3F /* PBXContainerItemProxy */;
-		};
-		FE61324809B6191D004BB4B8 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			name = corecg;
-			targetProxy = FE61324709B6191D004BB4B8 /* PBXContainerItemProxy */;
-		};
-/* End PBXTargetDependency section */
-
-/* Begin PBXVariantGroup section */
-		02345980000FD03B11CA0E72 /* main.nib */ = {
-			isa = PBXVariantGroup;
-			children = (
-				1870340FFE93FCAF11CA0CD7 /* English */,
-			);
-			name = main.nib;
-			sourceTree = "<group>";
-		};
-		0867D6AAFE840B52C02AAC07 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				0867D6ABFE840B52C02AAC07 /* English */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		C0E91AC608A95435008D54AB /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				DEBUG_INFORMATION_FORMAT = stabs;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_ENABLE_OBJC_EXCEPTIONS = NO;
-				GCC_FAST_OBJC_DISPATCH = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = animatorTest_Prefix.pch;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_DEBUG,
-					BROWSER_DEBUG,
-					DEBUG_NAV_UI,
-					ANDROID_CANVAS_IMPL,
-				);
-				INFOPLIST_FILE = Info.plist;
-				INSTALL_PATH = "$(HOME)/Applications";
-				PRODUCT_NAME = animatorTest;
-				SCAN_ALL_SOURCE_FILES_FOR_INCLUDES = YES;
-				WRAPPER_EXTENSION = app;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		C0E91AC708A95435008D54AB /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = animatorTest_Prefix.pch;
-				INFOPLIST_FILE = Info.plist;
-				INSTALL_PATH = "$(HOME)/Applications";
-				PRODUCT_NAME = animatorTest;
-				WRAPPER_EXTENSION = app;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		C0E91ACA08A95435008D54AB /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_DEBUG,
-					PV_PRODUCT_SERVER,
-					BUILD_OMX_DEC_NODE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LIBRARY_SEARCH_PATHS = ../build/Debug;
-				LINK_WITH_STANDARD_LIBRARIES = YES;
-				OTHER_LDFLAGS = "";
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				PRODUCT_NAME = animatorTest;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-				STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
-				USER_HEADER_SEARCH_PATHS = "../../../include/graphics ../../../include/corecg ../../../libs/WebKitLib/WebKit/JavaScriptCore ../../../libs/WebKitLib/WebKit/WebCore/platform/android ../../../libs/WebKitLib/WebKit/WebCore/platform/graphics ../../../libs/WebKitLib/WebKit/WebCore/platform/graphics/android ../../../tests/browser/focusNavigation";
-			};
-			name = Debug;
-		};
-		C0E91ACB08A95435008D54AB /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LIBRARY_SEARCH_PATHS = ../build/Release;
-				OTHER_LDFLAGS = "";
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				PRODUCT_NAME = animatorTest;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-				USER_HEADER_SEARCH_PATHS = "../../../include/graphics ../../../include/corecg ../../../libs/WebKitLib/WebKit/JavaScriptCore ../../../libs/WebKitLib/WebKit/WebCore/bridge/android ../../../libs/WebKitLib/WebKit/WebCore/platform/android ../../../libs/WebKitLib/WebKit/WebCore/platform/graphics ../../../libs/WebKitLib/WebKit/WebCore/rendering ../../../tests/browser/focusNavigation ../../../extlibs/pv/oscl/oscl/osclbase/src ../../../extlibs/pv/oscl/oscl/config/linux_nj ../../../extlibs/pv/oscl/oscl/config/shared ../../../extlibs/pv/codecs_v2/image/jpeg/dec/include ../../../extlibs/pv/oscl/oscl/osclmemory/src ../../../extlibs/pv/oscl/oscl/osclerror/src";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		C0E91AC508A95435008D54AB /* Build configuration list for PBXNativeTarget "animatorTest" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				C0E91AC608A95435008D54AB /* Debug */,
-				C0E91AC708A95435008D54AB /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		C0E91AC908A95435008D54AB /* Build configuration list for PBXProject "animatorTest" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				C0E91ACA08A95435008D54AB /* Debug */,
-				C0E91ACB08A95435008D54AB /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 20286C28FDCF999611CA2CEA /* Project object */;
-}
diff --git a/ide/xcode/animatorTest/animatorTest_Prefix.pch b/ide/xcode/animatorTest/animatorTest_Prefix.pch
deleted file mode 100644
index 39aee7e..0000000
--- a/ide/xcode/animatorTest/animatorTest_Prefix.pch
+++ /dev/null
@@ -1,5 +0,0 @@
-//
-// Prefix header for all source files of the 'animatorTest' target in the 'animatorTest' project.
-//
-
-#include <Carbon/Carbon.h>
diff --git a/ide/xcode/chipmunk.xcodeproj/project.pbxproj b/ide/xcode/chipmunk.xcodeproj/project.pbxproj
deleted file mode 100644
index d30ddcd..0000000
--- a/ide/xcode/chipmunk.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,258 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		FE16E1510CE26D84006BB7E0 /* chipmunk.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1270CE26C3D006BB7E0 /* chipmunk.c */; };
-		FE16E1520CE26D86006BB7E0 /* cpArbiter.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E12A0CE26C3D006BB7E0 /* cpArbiter.c */; };
-		FE16E1530CE26D87006BB7E0 /* cpArray.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E12C0CE26C3D006BB7E0 /* cpArray.c */; };
-		FE16E1540CE26D88006BB7E0 /* cpBB.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E12E0CE26C3D006BB7E0 /* cpBB.c */; };
-		FE16E1550CE26D8A006BB7E0 /* cpBody.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1300CE26C3D006BB7E0 /* cpBody.c */; };
-		FE16E1560CE26D8B006BB7E0 /* cpCollision.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1320CE26C3D006BB7E0 /* cpCollision.c */; };
-		FE16E1570CE26D8C006BB7E0 /* cpHashSet.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1340CE26C3D006BB7E0 /* cpHashSet.c */; };
-		FE16E1580CE26D8F006BB7E0 /* cpJoint.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1360CE26C3D006BB7E0 /* cpJoint.c */; };
-		FE16E1590CE26D91006BB7E0 /* cpPolyShape.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1380CE26C3D006BB7E0 /* cpPolyShape.c */; };
-		FE16E15E0CE26D9E006BB7E0 /* cpShape.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E13A0CE26C3D006BB7E0 /* cpShape.c */; };
-		FE16E15F0CE26D9F006BB7E0 /* cpSpace.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E13C0CE26C3D006BB7E0 /* cpSpace.c */; };
-		FE16E1600CE26DA0006BB7E0 /* cpSpaceHash.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E13E0CE26C3D006BB7E0 /* cpSpaceHash.c */; };
-		FE16E1610CE26DA1006BB7E0 /* cpVect.c in Sources */ = {isa = PBXBuildFile; fileRef = FE16E1400CE26C3D006BB7E0 /* cpVect.c */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		FE16E1270CE26C3D006BB7E0 /* chipmunk.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = chipmunk.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/chipmunk.c"; sourceTree = "<absolute>"; };
-		FE16E1280CE26C3D006BB7E0 /* chipmunk.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = chipmunk.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/chipmunk.h"; sourceTree = "<absolute>"; };
-		FE16E1290CE26C3D006BB7E0 /* CMakeLists.txt */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text; name = CMakeLists.txt; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/CMakeLists.txt"; sourceTree = "<absolute>"; };
-		FE16E12A0CE26C3D006BB7E0 /* cpArbiter.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpArbiter.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpArbiter.c"; sourceTree = "<absolute>"; };
-		FE16E12B0CE26C3D006BB7E0 /* cpArbiter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpArbiter.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpArbiter.h"; sourceTree = "<absolute>"; };
-		FE16E12C0CE26C3D006BB7E0 /* cpArray.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpArray.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpArray.c"; sourceTree = "<absolute>"; };
-		FE16E12D0CE26C3D006BB7E0 /* cpArray.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpArray.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpArray.h"; sourceTree = "<absolute>"; };
-		FE16E12E0CE26C3D006BB7E0 /* cpBB.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpBB.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpBB.c"; sourceTree = "<absolute>"; };
-		FE16E12F0CE26C3D006BB7E0 /* cpBB.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpBB.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpBB.h"; sourceTree = "<absolute>"; };
-		FE16E1300CE26C3D006BB7E0 /* cpBody.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpBody.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpBody.c"; sourceTree = "<absolute>"; };
-		FE16E1310CE26C3D006BB7E0 /* cpBody.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpBody.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpBody.h"; sourceTree = "<absolute>"; };
-		FE16E1320CE26C3D006BB7E0 /* cpCollision.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpCollision.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpCollision.c"; sourceTree = "<absolute>"; };
-		FE16E1330CE26C3D006BB7E0 /* cpCollision.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpCollision.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpCollision.h"; sourceTree = "<absolute>"; };
-		FE16E1340CE26C3D006BB7E0 /* cpHashSet.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpHashSet.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpHashSet.c"; sourceTree = "<absolute>"; };
-		FE16E1350CE26C3D006BB7E0 /* cpHashSet.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpHashSet.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpHashSet.h"; sourceTree = "<absolute>"; };
-		FE16E1360CE26C3D006BB7E0 /* cpJoint.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpJoint.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpJoint.c"; sourceTree = "<absolute>"; };
-		FE16E1370CE26C3D006BB7E0 /* cpJoint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpJoint.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpJoint.h"; sourceTree = "<absolute>"; };
-		FE16E1380CE26C3D006BB7E0 /* cpPolyShape.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpPolyShape.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpPolyShape.c"; sourceTree = "<absolute>"; };
-		FE16E1390CE26C3D006BB7E0 /* cpPolyShape.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpPolyShape.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpPolyShape.h"; sourceTree = "<absolute>"; };
-		FE16E13A0CE26C3D006BB7E0 /* cpShape.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpShape.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpShape.c"; sourceTree = "<absolute>"; };
-		FE16E13B0CE26C3D006BB7E0 /* cpShape.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpShape.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpShape.h"; sourceTree = "<absolute>"; };
-		FE16E13C0CE26C3D006BB7E0 /* cpSpace.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpSpace.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpSpace.c"; sourceTree = "<absolute>"; };
-		FE16E13D0CE26C3D006BB7E0 /* cpSpace.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpSpace.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpSpace.h"; sourceTree = "<absolute>"; };
-		FE16E13E0CE26C3D006BB7E0 /* cpSpaceHash.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpSpaceHash.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpSpaceHash.c"; sourceTree = "<absolute>"; };
-		FE16E13F0CE26C3D006BB7E0 /* cpSpaceHash.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpSpaceHash.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpSpaceHash.h"; sourceTree = "<absolute>"; };
-		FE16E1400CE26C3D006BB7E0 /* cpVect.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = cpVect.c; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpVect.c"; sourceTree = "<absolute>"; };
-		FE16E1410CE26C3D006BB7E0 /* cpVect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = cpVect.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/cpVect.h"; sourceTree = "<absolute>"; };
-		FE16E1420CE26C3D006BB7E0 /* prime.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = prime.h; path = "/Users/caryclark/Desktop/Chipmunk-4.0.2/src/prime.h"; sourceTree = "<absolute>"; };
-		FE16E14C0CE26D61006BB7E0 /* libchipmunk.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libchipmunk.a; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		FE16E14A0CE26D61006BB7E0 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		FE16E11A0CE26B5D006BB7E0 = {
-			isa = PBXGroup;
-			children = (
-				FE16E1250CE26B6A006BB7E0 /* Sources */,
-				FE16E14D0CE26D61006BB7E0 /* Products */,
-			);
-			sourceTree = "<group>";
-		};
-		FE16E1250CE26B6A006BB7E0 /* Sources */ = {
-			isa = PBXGroup;
-			children = (
-				FE16E1270CE26C3D006BB7E0 /* chipmunk.c */,
-				FE16E1280CE26C3D006BB7E0 /* chipmunk.h */,
-				FE16E1290CE26C3D006BB7E0 /* CMakeLists.txt */,
-				FE16E12A0CE26C3D006BB7E0 /* cpArbiter.c */,
-				FE16E12B0CE26C3D006BB7E0 /* cpArbiter.h */,
-				FE16E12C0CE26C3D006BB7E0 /* cpArray.c */,
-				FE16E12D0CE26C3D006BB7E0 /* cpArray.h */,
-				FE16E12E0CE26C3D006BB7E0 /* cpBB.c */,
-				FE16E12F0CE26C3D006BB7E0 /* cpBB.h */,
-				FE16E1300CE26C3D006BB7E0 /* cpBody.c */,
-				FE16E1310CE26C3D006BB7E0 /* cpBody.h */,
-				FE16E1320CE26C3D006BB7E0 /* cpCollision.c */,
-				FE16E1330CE26C3D006BB7E0 /* cpCollision.h */,
-				FE16E1340CE26C3D006BB7E0 /* cpHashSet.c */,
-				FE16E1350CE26C3D006BB7E0 /* cpHashSet.h */,
-				FE16E1360CE26C3D006BB7E0 /* cpJoint.c */,
-				FE16E1370CE26C3D006BB7E0 /* cpJoint.h */,
-				FE16E1380CE26C3D006BB7E0 /* cpPolyShape.c */,
-				FE16E1390CE26C3D006BB7E0 /* cpPolyShape.h */,
-				FE16E13A0CE26C3D006BB7E0 /* cpShape.c */,
-				FE16E13B0CE26C3D006BB7E0 /* cpShape.h */,
-				FE16E13C0CE26C3D006BB7E0 /* cpSpace.c */,
-				FE16E13D0CE26C3D006BB7E0 /* cpSpace.h */,
-				FE16E13E0CE26C3D006BB7E0 /* cpSpaceHash.c */,
-				FE16E13F0CE26C3D006BB7E0 /* cpSpaceHash.h */,
-				FE16E1400CE26C3D006BB7E0 /* cpVect.c */,
-				FE16E1410CE26C3D006BB7E0 /* cpVect.h */,
-				FE16E1420CE26C3D006BB7E0 /* prime.h */,
-			);
-			name = Sources;
-			sourceTree = "<group>";
-		};
-		FE16E14D0CE26D61006BB7E0 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				FE16E14C0CE26D61006BB7E0 /* libchipmunk.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		FE16E1480CE26D61006BB7E0 /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		FE16E14B0CE26D61006BB7E0 /* chipmunk */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = FE16E14E0CE26D61006BB7E0 /* Build configuration list for PBXNativeTarget "chipmunk" */;
-			buildPhases = (
-				FE16E1480CE26D61006BB7E0 /* Headers */,
-				FE16E1490CE26D61006BB7E0 /* Sources */,
-				FE16E14A0CE26D61006BB7E0 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = chipmunk;
-			productName = chipmunk;
-			productReference = FE16E14C0CE26D61006BB7E0 /* libchipmunk.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		FE16E11C0CE26B5D006BB7E0 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = FE16E11D0CE26B5D006BB7E0 /* Build configuration list for PBXProject "chipmunk" */;
-			hasScannedForEncodings = 0;
-			mainGroup = FE16E11A0CE26B5D006BB7E0;
-			productRefGroup = FE16E14D0CE26D61006BB7E0 /* Products */;
-			projectDirPath = "";
-			targets = (
-				FE16E14B0CE26D61006BB7E0 /* chipmunk */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		FE16E1490CE26D61006BB7E0 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE16E1510CE26D84006BB7E0 /* chipmunk.c in Sources */,
-				FE16E1520CE26D86006BB7E0 /* cpArbiter.c in Sources */,
-				FE16E1530CE26D87006BB7E0 /* cpArray.c in Sources */,
-				FE16E1540CE26D88006BB7E0 /* cpBB.c in Sources */,
-				FE16E1550CE26D8A006BB7E0 /* cpBody.c in Sources */,
-				FE16E1560CE26D8B006BB7E0 /* cpCollision.c in Sources */,
-				FE16E1570CE26D8C006BB7E0 /* cpHashSet.c in Sources */,
-				FE16E1580CE26D8F006BB7E0 /* cpJoint.c in Sources */,
-				FE16E1590CE26D91006BB7E0 /* cpPolyShape.c in Sources */,
-				FE16E15E0CE26D9E006BB7E0 /* cpShape.c in Sources */,
-				FE16E15F0CE26D9F006BB7E0 /* cpSpace.c in Sources */,
-				FE16E1600CE26DA0006BB7E0 /* cpSpaceHash.c in Sources */,
-				FE16E1610CE26DA1006BB7E0 /* cpVect.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		FE16E11E0CE26B5D006BB7E0 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-			};
-			name = Debug;
-		};
-		FE16E11F0CE26B5D006BB7E0 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-			};
-			name = Release;
-		};
-		FE16E14F0CE26D61006BB7E0 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PREBINDING = NO;
-				PRODUCT_NAME = chipmunk;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		FE16E1500CE26D61006BB7E0 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PREBINDING = NO;
-				PRODUCT_NAME = chipmunk;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		FE16E11D0CE26B5D006BB7E0 /* Build configuration list for PBXProject "chipmunk" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE16E11E0CE26B5D006BB7E0 /* Debug */,
-				FE16E11F0CE26B5D006BB7E0 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		FE16E14E0CE26D61006BB7E0 /* Build configuration list for PBXNativeTarget "chipmunk" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE16E14F0CE26D61006BB7E0 /* Debug */,
-				FE16E1500CE26D61006BB7E0 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = FE16E11C0CE26B5D006BB7E0 /* Project object */;
-}
diff --git a/ide/xcode/corecg.xcodeproj/project.pbxproj b/ide/xcode/corecg.xcodeproj/project.pbxproj
deleted file mode 100644
index c4ac10e..0000000
--- a/ide/xcode/corecg.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,396 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		0026CE6809DC5A9E00D5B6BE /* SkBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0026CE6709DC5A9E00D5B6BE /* SkBuffer.cpp */; };
-		0026CE8E09DC5B1F00D5B6BE /* Sk64.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE7B09DC5B1F00D5B6BE /* Sk64.h */; };
-		0026CE8F09DC5B1F00D5B6BE /* SkBuffer.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE7C09DC5B1F00D5B6BE /* SkBuffer.h */; };
-		0026CE9009DC5B1F00D5B6BE /* SkEndian.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE7D09DC5B1F00D5B6BE /* SkEndian.h */; };
-		0026CE9109DC5B1F00D5B6BE /* SkFDot6.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE7E09DC5B1F00D5B6BE /* SkFDot6.h */; };
-		0026CE9209DC5B1F00D5B6BE /* SkFixed.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE7F09DC5B1F00D5B6BE /* SkFixed.h */; };
-		0026CE9309DC5B1F00D5B6BE /* SkFloatingPoint.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8009DC5B1F00D5B6BE /* SkFloatingPoint.h */; };
-		0026CE9409DC5B1F00D5B6BE /* SkMath.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8109DC5B1F00D5B6BE /* SkMath.h */; };
-		0026CE9509DC5B1F00D5B6BE /* SkMatrix.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8209DC5B1F00D5B6BE /* SkMatrix.h */; };
-		0026CE9609DC5B1F00D5B6BE /* SkPoint.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8309DC5B1F00D5B6BE /* SkPoint.h */; };
-		0026CE9709DC5B1F00D5B6BE /* SkPostConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8409DC5B1F00D5B6BE /* SkPostConfig.h */; };
-		0026CE9809DC5B1F00D5B6BE /* SkPreConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8509DC5B1F00D5B6BE /* SkPreConfig.h */; };
-		0026CE9909DC5B1F00D5B6BE /* SkRandom.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8609DC5B1F00D5B6BE /* SkRandom.h */; };
-		0026CE9A09DC5B1F00D5B6BE /* SkRect.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8709DC5B1F00D5B6BE /* SkRect.h */; };
-		0026CE9B09DC5B1F00D5B6BE /* SkRegion.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8809DC5B1F00D5B6BE /* SkRegion.h */; };
-		0026CE9C09DC5B1F00D5B6BE /* SkScalar.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8909DC5B1F00D5B6BE /* SkScalar.h */; };
-		0026CE9D09DC5B1F00D5B6BE /* SkTemplates.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8A09DC5B1F00D5B6BE /* SkTemplates.h */; };
-		0026CE9E09DC5B1F00D5B6BE /* SkThread.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8B09DC5B1F00D5B6BE /* SkThread.h */; };
-		0026CE9F09DC5B1F00D5B6BE /* SkTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8C09DC5B1F00D5B6BE /* SkTypes.h */; };
-		0026CEA009DC5B1F00D5B6BE /* SkUserConfig.h in Headers */ = {isa = PBXBuildFile; fileRef = 0026CE8D09DC5B1F00D5B6BE /* SkUserConfig.h */; };
-		0038A95509DD931A00A82F6E /* SkChunkAlloc.h in Headers */ = {isa = PBXBuildFile; fileRef = 0038A95409DD931A00A82F6E /* SkChunkAlloc.h */; };
-		0038A95709DD932D00A82F6E /* SkChunkAlloc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0038A95609DD932D00A82F6E /* SkChunkAlloc.cpp */; };
-		003BA8560AD69605002B4C6C /* SkPerspIter.h in Headers */ = {isa = PBXBuildFile; fileRef = 003BA8550AD69605002B4C6C /* SkPerspIter.h */; };
-		005017980DF5D77400A63A26 /* SkFloatBits.h in Headers */ = {isa = PBXBuildFile; fileRef = 005017970DF5D77400A63A26 /* SkFloatBits.h */; };
-		0050180A0DF61B8E00A63A26 /* SkFloatBits.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005018090DF61B8E00A63A26 /* SkFloatBits.cpp */; };
-		00927DBE0ADF13FD000A366E /* SkInterpolator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00927DBD0ADF13FD000A366E /* SkInterpolator.cpp */; };
-		00927DC00ADF1411000A366E /* SkInterpolator.h in Headers */ = {isa = PBXBuildFile; fileRef = 00927DBF0ADF1411000A366E /* SkInterpolator.h */; };
-		00927DC30ADF1426000A366E /* SkThread_platform.h in Headers */ = {isa = PBXBuildFile; fileRef = 00927DC10ADF1426000A366E /* SkThread_platform.h */; };
-		00927DC40ADF1426000A366E /* SkTSearch.h in Headers */ = {isa = PBXBuildFile; fileRef = 00927DC20ADF1426000A366E /* SkTSearch.h */; };
-		FE61321509B60E66004BB4B8 /* Sk64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61320809B60E66004BB4B8 /* Sk64.cpp */; };
-		FE61321609B60E66004BB4B8 /* SkCordic.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61320909B60E66004BB4B8 /* SkCordic.cpp */; };
-		FE61321709B60E66004BB4B8 /* SkCordic.h in Headers */ = {isa = PBXBuildFile; fileRef = FE61320A09B60E66004BB4B8 /* SkCordic.h */; };
-		FE61321809B60E66004BB4B8 /* SkFloat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61320B09B60E66004BB4B8 /* SkFloat.cpp */; };
-		FE61321909B60E66004BB4B8 /* SkFloat.h in Headers */ = {isa = PBXBuildFile; fileRef = FE61320C09B60E66004BB4B8 /* SkFloat.h */; };
-		FE61321B09B60E66004BB4B8 /* SkMath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61320E09B60E66004BB4B8 /* SkMath.cpp */; };
-		FE61321C09B60E66004BB4B8 /* SkMatrix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61320F09B60E66004BB4B8 /* SkMatrix.cpp */; };
-		FE61321D09B60E66004BB4B8 /* SkPoint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61321009B60E66004BB4B8 /* SkPoint.cpp */; };
-		FE61321E09B60E66004BB4B8 /* SkRect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61321109B60E66004BB4B8 /* SkRect.cpp */; };
-		FE61321F09B60E66004BB4B8 /* SkRegion.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE61321209B60E66004BB4B8 /* SkRegion.cpp */; };
-		FE61322009B60E66004BB4B8 /* SkSinTable.h in Headers */ = {isa = PBXBuildFile; fileRef = FE61321309B60E66004BB4B8 /* SkSinTable.h */; };
-		FE61322109B60E66004BB4B8 /* SkTSort.h in Headers */ = {isa = PBXBuildFile; fileRef = FE61321409B60E66004BB4B8 /* SkTSort.h */; };
-		FEACF21E09E460DF00D0C2E2 /* SkDebug_stdio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEACF21A09E460DF00D0C2E2 /* SkDebug_stdio.cpp */; };
-		FEACF21F09E460DF00D0C2E2 /* SkDebug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEACF21B09E460DF00D0C2E2 /* SkDebug.cpp */; };
-		FEACF22009E460DF00D0C2E2 /* SkMemory_stdlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEACF21C09E460DF00D0C2E2 /* SkMemory_stdlib.cpp */; };
-		FEACF22109E460DF00D0C2E2 /* SkRegionPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = FEACF21D09E460DF00D0C2E2 /* SkRegionPriv.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		0026CE6709DC5A9E00D5B6BE /* SkBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBuffer.cpp; path = ../../libs/corecg/SkBuffer.cpp; sourceTree = SOURCE_ROOT; };
-		0026CE7B09DC5B1F00D5B6BE /* Sk64.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = Sk64.h; path = ../../include/corecg/Sk64.h; sourceTree = SOURCE_ROOT; };
-		0026CE7C09DC5B1F00D5B6BE /* SkBuffer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBuffer.h; path = ../../include/corecg/SkBuffer.h; sourceTree = SOURCE_ROOT; };
-		0026CE7D09DC5B1F00D5B6BE /* SkEndian.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkEndian.h; path = ../../include/corecg/SkEndian.h; sourceTree = SOURCE_ROOT; };
-		0026CE7E09DC5B1F00D5B6BE /* SkFDot6.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFDot6.h; path = ../../include/corecg/SkFDot6.h; sourceTree = SOURCE_ROOT; };
-		0026CE7F09DC5B1F00D5B6BE /* SkFixed.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFixed.h; path = ../../include/corecg/SkFixed.h; sourceTree = SOURCE_ROOT; };
-		0026CE8009DC5B1F00D5B6BE /* SkFloatingPoint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFloatingPoint.h; path = ../../include/corecg/SkFloatingPoint.h; sourceTree = SOURCE_ROOT; };
-		0026CE8109DC5B1F00D5B6BE /* SkMath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkMath.h; path = ../../include/corecg/SkMath.h; sourceTree = SOURCE_ROOT; };
-		0026CE8209DC5B1F00D5B6BE /* SkMatrix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkMatrix.h; path = ../../include/corecg/SkMatrix.h; sourceTree = SOURCE_ROOT; };
-		0026CE8309DC5B1F00D5B6BE /* SkPoint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPoint.h; path = ../../include/corecg/SkPoint.h; sourceTree = SOURCE_ROOT; };
-		0026CE8409DC5B1F00D5B6BE /* SkPostConfig.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPostConfig.h; path = ../../include/corecg/SkPostConfig.h; sourceTree = SOURCE_ROOT; };
-		0026CE8509DC5B1F00D5B6BE /* SkPreConfig.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPreConfig.h; path = ../../include/corecg/SkPreConfig.h; sourceTree = SOURCE_ROOT; };
-		0026CE8609DC5B1F00D5B6BE /* SkRandom.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRandom.h; path = ../../include/corecg/SkRandom.h; sourceTree = SOURCE_ROOT; };
-		0026CE8709DC5B1F00D5B6BE /* SkRect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRect.h; path = ../../include/corecg/SkRect.h; sourceTree = SOURCE_ROOT; };
-		0026CE8809DC5B1F00D5B6BE /* SkRegion.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRegion.h; path = ../../include/corecg/SkRegion.h; sourceTree = SOURCE_ROOT; };
-		0026CE8909DC5B1F00D5B6BE /* SkScalar.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScalar.h; path = ../../include/corecg/SkScalar.h; sourceTree = SOURCE_ROOT; };
-		0026CE8A09DC5B1F00D5B6BE /* SkTemplates.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTemplates.h; path = ../../include/corecg/SkTemplates.h; sourceTree = SOURCE_ROOT; };
-		0026CE8B09DC5B1F00D5B6BE /* SkThread.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkThread.h; path = ../../include/corecg/SkThread.h; sourceTree = SOURCE_ROOT; };
-		0026CE8C09DC5B1F00D5B6BE /* SkTypes.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTypes.h; path = ../../include/corecg/SkTypes.h; sourceTree = SOURCE_ROOT; };
-		0026CE8D09DC5B1F00D5B6BE /* SkUserConfig.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkUserConfig.h; path = ../../include/corecg/SkUserConfig.h; sourceTree = SOURCE_ROOT; };
-		0038A95409DD931A00A82F6E /* SkChunkAlloc.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkChunkAlloc.h; path = ../../include/corecg/SkChunkAlloc.h; sourceTree = SOURCE_ROOT; };
-		0038A95609DD932D00A82F6E /* SkChunkAlloc.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkChunkAlloc.cpp; path = ../../libs/corecg/SkChunkAlloc.cpp; sourceTree = SOURCE_ROOT; };
-		003BA8550AD69605002B4C6C /* SkPerspIter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkPerspIter.h; path = ../../include/corecg/SkPerspIter.h; sourceTree = SOURCE_ROOT; };
-		005017970DF5D77400A63A26 /* SkFloatBits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkFloatBits.h; path = ../../include/corecg/SkFloatBits.h; sourceTree = SOURCE_ROOT; };
-		005018090DF61B8E00A63A26 /* SkFloatBits.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkFloatBits.cpp; path = ../../libs/corecg/SkFloatBits.cpp; sourceTree = SOURCE_ROOT; };
-		00927DBD0ADF13FD000A366E /* SkInterpolator.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkInterpolator.cpp; path = ../../libs/corecg/SkInterpolator.cpp; sourceTree = SOURCE_ROOT; };
-		00927DBF0ADF1411000A366E /* SkInterpolator.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkInterpolator.h; path = ../../include/corecg/SkInterpolator.h; sourceTree = SOURCE_ROOT; };
-		00927DC10ADF1426000A366E /* SkThread_platform.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkThread_platform.h; path = ../../include/corecg/SkThread_platform.h; sourceTree = SOURCE_ROOT; };
-		00927DC20ADF1426000A366E /* SkTSearch.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTSearch.h; path = ../../include/corecg/SkTSearch.h; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libcorecg.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libcorecg.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE61320809B60E66004BB4B8 /* Sk64.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = Sk64.cpp; path = ../../libs/corecg/Sk64.cpp; sourceTree = SOURCE_ROOT; };
-		FE61320909B60E66004BB4B8 /* SkCordic.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkCordic.cpp; path = ../../libs/corecg/SkCordic.cpp; sourceTree = SOURCE_ROOT; };
-		FE61320A09B60E66004BB4B8 /* SkCordic.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkCordic.h; path = ../../libs/corecg/SkCordic.h; sourceTree = SOURCE_ROOT; };
-		FE61320B09B60E66004BB4B8 /* SkFloat.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFloat.cpp; path = ../../libs/corecg/SkFloat.cpp; sourceTree = SOURCE_ROOT; };
-		FE61320C09B60E66004BB4B8 /* SkFloat.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFloat.h; path = ../../libs/corecg/SkFloat.h; sourceTree = SOURCE_ROOT; };
-		FE61320E09B60E66004BB4B8 /* SkMath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMath.cpp; path = ../../libs/corecg/SkMath.cpp; sourceTree = SOURCE_ROOT; };
-		FE61320F09B60E66004BB4B8 /* SkMatrix.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMatrix.cpp; path = ../../libs/corecg/SkMatrix.cpp; sourceTree = SOURCE_ROOT; };
-		FE61321009B60E66004BB4B8 /* SkPoint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPoint.cpp; path = ../../libs/corecg/SkPoint.cpp; sourceTree = SOURCE_ROOT; };
-		FE61321109B60E66004BB4B8 /* SkRect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkRect.cpp; path = ../../libs/corecg/SkRect.cpp; sourceTree = SOURCE_ROOT; };
-		FE61321209B60E66004BB4B8 /* SkRegion.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkRegion.cpp; path = ../../libs/corecg/SkRegion.cpp; sourceTree = SOURCE_ROOT; };
-		FE61321309B60E66004BB4B8 /* SkSinTable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkSinTable.h; path = ../../libs/corecg/SkSinTable.h; sourceTree = SOURCE_ROOT; };
-		FE61321409B60E66004BB4B8 /* SkTSort.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTSort.h; path = ../../libs/corecg/SkTSort.h; sourceTree = SOURCE_ROOT; };
-		FEACF21A09E460DF00D0C2E2 /* SkDebug_stdio.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDebug_stdio.cpp; path = ../../libs/corecg/SkDebug_stdio.cpp; sourceTree = SOURCE_ROOT; };
-		FEACF21B09E460DF00D0C2E2 /* SkDebug.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDebug.cpp; path = ../../libs/corecg/SkDebug.cpp; sourceTree = SOURCE_ROOT; };
-		FEACF21C09E460DF00D0C2E2 /* SkMemory_stdlib.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMemory_stdlib.cpp; path = ../../libs/corecg/SkMemory_stdlib.cpp; sourceTree = SOURCE_ROOT; };
-		FEACF21D09E460DF00D0C2E2 /* SkRegionPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRegionPriv.h; path = ../../libs/corecg/SkRegionPriv.h; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		0026CE7A09DC5B0600D5B6BE /* Include */ = {
-			isa = PBXGroup;
-			children = (
-				005017970DF5D77400A63A26 /* SkFloatBits.h */,
-				00927DC10ADF1426000A366E /* SkThread_platform.h */,
-				00927DC20ADF1426000A366E /* SkTSearch.h */,
-				00927DBF0ADF1411000A366E /* SkInterpolator.h */,
-				003BA8550AD69605002B4C6C /* SkPerspIter.h */,
-				0038A95409DD931A00A82F6E /* SkChunkAlloc.h */,
-				0026CE7B09DC5B1F00D5B6BE /* Sk64.h */,
-				0026CE7C09DC5B1F00D5B6BE /* SkBuffer.h */,
-				FE61320A09B60E66004BB4B8 /* SkCordic.h */,
-				0026CE7D09DC5B1F00D5B6BE /* SkEndian.h */,
-				0026CE7E09DC5B1F00D5B6BE /* SkFDot6.h */,
-				0026CE7F09DC5B1F00D5B6BE /* SkFixed.h */,
-				FE61320C09B60E66004BB4B8 /* SkFloat.h */,
-				0026CE8009DC5B1F00D5B6BE /* SkFloatingPoint.h */,
-				0026CE8109DC5B1F00D5B6BE /* SkMath.h */,
-				0026CE8209DC5B1F00D5B6BE /* SkMatrix.h */,
-				0026CE8309DC5B1F00D5B6BE /* SkPoint.h */,
-				0026CE8409DC5B1F00D5B6BE /* SkPostConfig.h */,
-				0026CE8509DC5B1F00D5B6BE /* SkPreConfig.h */,
-				0026CE8609DC5B1F00D5B6BE /* SkRandom.h */,
-				0026CE8709DC5B1F00D5B6BE /* SkRect.h */,
-				0026CE8809DC5B1F00D5B6BE /* SkRegion.h */,
-				FEACF21D09E460DF00D0C2E2 /* SkRegionPriv.h */,
-				0026CE8909DC5B1F00D5B6BE /* SkScalar.h */,
-				FE61321309B60E66004BB4B8 /* SkSinTable.h */,
-				FE61321409B60E66004BB4B8 /* SkTSort.h */,
-				0026CE8A09DC5B1F00D5B6BE /* SkTemplates.h */,
-				0026CE8B09DC5B1F00D5B6BE /* SkThread.h */,
-				0026CE8C09DC5B1F00D5B6BE /* SkTypes.h */,
-				0026CE8D09DC5B1F00D5B6BE /* SkUserConfig.h */,
-			);
-			name = Include;
-			sourceTree = "<group>";
-		};
-		08FB7794FE84155DC02AAC07 /* corecg */ = {
-			isa = PBXGroup;
-			children = (
-				0026CE7A09DC5B0600D5B6BE /* Include */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = corecg;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				005018090DF61B8E00A63A26 /* SkFloatBits.cpp */,
-				00927DBD0ADF13FD000A366E /* SkInterpolator.cpp */,
-				FE61320809B60E66004BB4B8 /* Sk64.cpp */,
-				0026CE6709DC5A9E00D5B6BE /* SkBuffer.cpp */,
-				0038A95609DD932D00A82F6E /* SkChunkAlloc.cpp */,
-				FE61320909B60E66004BB4B8 /* SkCordic.cpp */,
-				FEACF21A09E460DF00D0C2E2 /* SkDebug_stdio.cpp */,
-				FEACF21B09E460DF00D0C2E2 /* SkDebug.cpp */,
-				FE61320B09B60E66004BB4B8 /* SkFloat.cpp */,
-				FE61320E09B60E66004BB4B8 /* SkMath.cpp */,
-				FE61320F09B60E66004BB4B8 /* SkMatrix.cpp */,
-				FEACF21C09E460DF00D0C2E2 /* SkMemory_stdlib.cpp */,
-				FE61321009B60E66004BB4B8 /* SkPoint.cpp */,
-				FE61321109B60E66004BB4B8 /* SkRect.cpp */,
-				FE61321209B60E66004BB4B8 /* SkRegion.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libcorecg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE61321709B60E66004BB4B8 /* SkCordic.h in Headers */,
-				FE61321909B60E66004BB4B8 /* SkFloat.h in Headers */,
-				FE61322009B60E66004BB4B8 /* SkSinTable.h in Headers */,
-				FE61322109B60E66004BB4B8 /* SkTSort.h in Headers */,
-				0026CE8E09DC5B1F00D5B6BE /* Sk64.h in Headers */,
-				0026CE8F09DC5B1F00D5B6BE /* SkBuffer.h in Headers */,
-				0026CE9009DC5B1F00D5B6BE /* SkEndian.h in Headers */,
-				0026CE9109DC5B1F00D5B6BE /* SkFDot6.h in Headers */,
-				0026CE9209DC5B1F00D5B6BE /* SkFixed.h in Headers */,
-				0026CE9309DC5B1F00D5B6BE /* SkFloatingPoint.h in Headers */,
-				0026CE9409DC5B1F00D5B6BE /* SkMath.h in Headers */,
-				0026CE9509DC5B1F00D5B6BE /* SkMatrix.h in Headers */,
-				0026CE9609DC5B1F00D5B6BE /* SkPoint.h in Headers */,
-				0026CE9709DC5B1F00D5B6BE /* SkPostConfig.h in Headers */,
-				0026CE9809DC5B1F00D5B6BE /* SkPreConfig.h in Headers */,
-				0026CE9909DC5B1F00D5B6BE /* SkRandom.h in Headers */,
-				0026CE9A09DC5B1F00D5B6BE /* SkRect.h in Headers */,
-				0026CE9B09DC5B1F00D5B6BE /* SkRegion.h in Headers */,
-				0026CE9C09DC5B1F00D5B6BE /* SkScalar.h in Headers */,
-				0026CE9D09DC5B1F00D5B6BE /* SkTemplates.h in Headers */,
-				0026CE9E09DC5B1F00D5B6BE /* SkThread.h in Headers */,
-				0026CE9F09DC5B1F00D5B6BE /* SkTypes.h in Headers */,
-				0026CEA009DC5B1F00D5B6BE /* SkUserConfig.h in Headers */,
-				0038A95509DD931A00A82F6E /* SkChunkAlloc.h in Headers */,
-				FEACF22109E460DF00D0C2E2 /* SkRegionPriv.h in Headers */,
-				003BA8560AD69605002B4C6C /* SkPerspIter.h in Headers */,
-				00927DC00ADF1411000A366E /* SkInterpolator.h in Headers */,
-				00927DC30ADF1426000A366E /* SkThread_platform.h in Headers */,
-				00927DC40ADF1426000A366E /* SkTSearch.h in Headers */,
-				005017980DF5D77400A63A26 /* SkFloatBits.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* corecg */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "corecg" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = corecg;
-			productName = corecg;
-			productReference = D2AAC046055464E500DB518D /* libcorecg.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "corecg" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* corecg */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC045055464E500DB518D /* corecg */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE61321509B60E66004BB4B8 /* Sk64.cpp in Sources */,
-				FE61321609B60E66004BB4B8 /* SkCordic.cpp in Sources */,
-				FE61321809B60E66004BB4B8 /* SkFloat.cpp in Sources */,
-				FE61321B09B60E66004BB4B8 /* SkMath.cpp in Sources */,
-				FE61321C09B60E66004BB4B8 /* SkMatrix.cpp in Sources */,
-				FE61321D09B60E66004BB4B8 /* SkPoint.cpp in Sources */,
-				FE61321E09B60E66004BB4B8 /* SkRect.cpp in Sources */,
-				FE61321F09B60E66004BB4B8 /* SkRegion.cpp in Sources */,
-				0026CE6809DC5A9E00D5B6BE /* SkBuffer.cpp in Sources */,
-				0038A95709DD932D00A82F6E /* SkChunkAlloc.cpp in Sources */,
-				FEACF21E09E460DF00D0C2E2 /* SkDebug_stdio.cpp in Sources */,
-				FEACF21F09E460DF00D0C2E2 /* SkDebug.cpp in Sources */,
-				FEACF22009E460DF00D0C2E2 /* SkMemory_stdlib.cpp in Sources */,
-				00927DBE0ADF13FD000A366E /* SkInterpolator.cpp in Sources */,
-				0050180A0DF61B8E00A63A26 /* SkFloatBits.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = corecg;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = corecg;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/skia ";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/skia ";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "corecg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "corecg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/expat.xcodeproj/project.pbxproj b/ide/xcode/expat.xcodeproj/project.pbxproj
deleted file mode 100644
index afc3d85..0000000
--- a/ide/xcode/expat.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,256 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		0002E9ED0BCE7EA3000C5903 /* SkXMLPullParser_expat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0002E9EC0BCE7EA3000C5903 /* SkXMLPullParser_expat.cpp */; };
-		00AA4D270BD3A78900B9D27D /* SkXMLPullParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00AA4D260BD3A78900B9D27D /* SkXMLPullParser.cpp */; };
-		FE33C881094DE14B00C4A640 /* SkXMLParser_expat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE33C880094DE14B00C4A640 /* SkXMLParser_expat.cpp */; };
-		FEDCE3DD09CEF35D0042D964 /* xmlparse.c in Sources */ = {isa = PBXBuildFile; fileRef = FEDCE3DA09CEF35D0042D964 /* xmlparse.c */; };
-		FEDCE3DE09CEF35D0042D964 /* xmlrole.c in Sources */ = {isa = PBXBuildFile; fileRef = FEDCE3DB09CEF35D0042D964 /* xmlrole.c */; };
-		FEDCE3DF09CEF35D0042D964 /* xmlrole.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDCE3DC09CEF35D0042D964 /* xmlrole.h */; };
-		FEDCE3E309CEF3830042D964 /* xmltok.c in Sources */ = {isa = PBXBuildFile; fileRef = FEDCE3E109CEF3830042D964 /* xmltok.c */; };
-		FEDCE3E409CEF3830042D964 /* xmltok.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDCE3E209CEF3830042D964 /* xmltok.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		0002E9EC0BCE7EA3000C5903 /* SkXMLPullParser_expat.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLPullParser_expat.cpp; path = ../../libs/graphics/ports/SkXMLPullParser_expat.cpp; sourceTree = SOURCE_ROOT; };
-		00AA4D260BD3A78900B9D27D /* SkXMLPullParser.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLPullParser.cpp; path = ../../libs/graphics/xml/SkXMLPullParser.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libexpat.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libexpat.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE33C880094DE14B00C4A640 /* SkXMLParser_expat.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLParser_expat.cpp; path = ../../libs/graphics/ports/SkXMLParser_expat.cpp; sourceTree = SOURCE_ROOT; };
-		FEDCE3DA09CEF35D0042D964 /* xmlparse.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = xmlparse.c; path = "../../extlibs/expat-2.0.0/lib/xmlparse.c"; sourceTree = SOURCE_ROOT; };
-		FEDCE3DB09CEF35D0042D964 /* xmlrole.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = xmlrole.c; path = "../../extlibs/expat-2.0.0/lib/xmlrole.c"; sourceTree = SOURCE_ROOT; };
-		FEDCE3DC09CEF35D0042D964 /* xmlrole.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = xmlrole.h; path = "../../extlibs/expat-2.0.0/lib/xmlrole.h"; sourceTree = SOURCE_ROOT; };
-		FEDCE3E109CEF3830042D964 /* xmltok.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = xmltok.c; path = "../../extlibs/expat-2.0.0/lib/xmltok.c"; sourceTree = SOURCE_ROOT; };
-		FEDCE3E209CEF3830042D964 /* xmltok.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = xmltok.h; path = "../../extlibs/expat-2.0.0/lib/xmltok.h"; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* expat */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = expat;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				00AA4D260BD3A78900B9D27D /* SkXMLPullParser.cpp */,
-				0002E9EC0BCE7EA3000C5903 /* SkXMLPullParser_expat.cpp */,
-				FEDCE3E109CEF3830042D964 /* xmltok.c */,
-				FEDCE3DA09CEF35D0042D964 /* xmlparse.c */,
-				FEDCE3E209CEF3830042D964 /* xmltok.h */,
-				FEDCE3DC09CEF35D0042D964 /* xmlrole.h */,
-				FEDCE3DB09CEF35D0042D964 /* xmlrole.c */,
-				FE33C880094DE14B00C4A640 /* SkXMLParser_expat.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libexpat.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FEDCE3DF09CEF35D0042D964 /* xmlrole.h in Headers */,
-				FEDCE3E409CEF3830042D964 /* xmltok.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* expat */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "expat" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = expat;
-			productName = expat;
-			productReference = D2AAC046055464E500DB518D /* libexpat.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "expat" */;
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* expat */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* expat */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE33C881094DE14B00C4A640 /* SkXMLParser_expat.cpp in Sources */,
-				FEDCE3DD09CEF35D0042D964 /* xmlparse.c in Sources */,
-				FEDCE3DE09CEF35D0042D964 /* xmlrole.c in Sources */,
-				FEDCE3E309CEF3830042D964 /* xmltok.c in Sources */,
-				0002E9ED0BCE7EA3000C5903 /* SkXMLPullParser_expat.cpp in Sources */,
-				00AA4D270BD3A78900B9D27D /* SkXMLPullParser.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = expat;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					MACOS_CLASSIC,
-					XML_STATIC,
-					SK_RELEASE,
-				);
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = expat;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					MACOS_CLASSIC,
-					XML_STATIC,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../extlibs/expat-2.0.0/lib ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					MACOS_CLASSIC,
-					XML_STATIC,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../extlibs/expat-2.0.0/lib ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "expat" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "expat" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/freetype2.xcodeproj/project.pbxproj b/ide/xcode/freetype2.xcodeproj/project.pbxproj
deleted file mode 100644
index 6635d72..0000000
--- a/ide/xcode/freetype2.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,454 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		003A0F710E0BE7DF00136848 /* ftadvanc.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F560E0BE7DF00136848 /* ftadvanc.c */; };
-		003A0F720E0BE7DF00136848 /* ftapi.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F570E0BE7DF00136848 /* ftapi.c */; };
-		003A0F730E0BE7DF00136848 /* ftbase.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F580E0BE7DF00136848 /* ftbase.c */; };
-		003A0F740E0BE7DF00136848 /* ftbbox.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F590E0BE7DF00136848 /* ftbbox.c */; };
-		003A0F750E0BE7DF00136848 /* ftbitmap.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5A0E0BE7DF00136848 /* ftbitmap.c */; };
-		003A0F760E0BE7DF00136848 /* ftcalc.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5B0E0BE7DF00136848 /* ftcalc.c */; };
-		003A0F770E0BE7DF00136848 /* ftdbgmem.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5C0E0BE7DF00136848 /* ftdbgmem.c */; };
-		003A0F780E0BE7DF00136848 /* ftdebug.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5D0E0BE7DF00136848 /* ftdebug.c */; };
-		003A0F790E0BE7DF00136848 /* ftgasp.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5E0E0BE7DF00136848 /* ftgasp.c */; };
-		003A0F7A0E0BE7DF00136848 /* ftgloadr.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F5F0E0BE7DF00136848 /* ftgloadr.c */; };
-		003A0F7B0E0BE7DF00136848 /* ftglyph.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F600E0BE7DF00136848 /* ftglyph.c */; };
-		003A0F7C0E0BE7DF00136848 /* ftinit.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F610E0BE7DF00136848 /* ftinit.c */; };
-		003A0F7D0E0BE7DF00136848 /* ftlcdfil.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F620E0BE7DF00136848 /* ftlcdfil.c */; };
-		003A0F7E0E0BE7DF00136848 /* ftmm.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F630E0BE7DF00136848 /* ftmm.c */; };
-		003A0F7F0E0BE7DF00136848 /* ftnames.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F640E0BE7DF00136848 /* ftnames.c */; };
-		003A0F800E0BE7DF00136848 /* ftobjs.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F650E0BE7DF00136848 /* ftobjs.c */; };
-		003A0F810E0BE7DF00136848 /* ftoutln.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F660E0BE7DF00136848 /* ftoutln.c */; };
-		003A0F820E0BE7DF00136848 /* ftpatent.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F670E0BE7DF00136848 /* ftpatent.c */; };
-		003A0F830E0BE7DF00136848 /* ftrfork.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F680E0BE7DF00136848 /* ftrfork.c */; };
-		003A0F840E0BE7DF00136848 /* ftstream.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F690E0BE7DF00136848 /* ftstream.c */; };
-		003A0F850E0BE7DF00136848 /* ftstroke.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6A0E0BE7DF00136848 /* ftstroke.c */; };
-		003A0F860E0BE7DF00136848 /* ftsynth.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6B0E0BE7DF00136848 /* ftsynth.c */; };
-		003A0F870E0BE7DF00136848 /* ftsystem.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6C0E0BE7DF00136848 /* ftsystem.c */; };
-		003A0F880E0BE7DF00136848 /* fttrigon.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6D0E0BE7DF00136848 /* fttrigon.c */; };
-		003A0F890E0BE7DF00136848 /* ftutil.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6E0E0BE7DF00136848 /* ftutil.c */; };
-		003A0F8A0E0BE7DF00136848 /* ftwinfnt.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F6F0E0BE7DF00136848 /* ftwinfnt.c */; };
-		003A0F8B0E0BE7DF00136848 /* ftxf86.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F700E0BE7DF00136848 /* ftxf86.c */; };
-		003A0F8D0E0BE80000136848 /* raster.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F8C0E0BE80000136848 /* raster.c */; };
-		003A0F8F0E0BE81800136848 /* sfnt.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F8E0E0BE81800136848 /* sfnt.c */; };
-		003A0F910E0BE83C00136848 /* smooth.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F900E0BE83C00136848 /* smooth.c */; };
-		003A0F930E0BE85600136848 /* autofit.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F920E0BE85600136848 /* autofit.c */; };
-		003A0F950E0BE86E00136848 /* truetype.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F940E0BE86E00136848 /* truetype.c */; };
-		003A0F970E0BE88300136848 /* cff.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F960E0BE88300136848 /* cff.c */; };
-		003A0F990E0BE89B00136848 /* psaux.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F980E0BE89B00136848 /* psaux.c */; };
-		003A0F9B0E0BE8B400136848 /* psnames.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0F9A0E0BE8B400136848 /* psnames.c */; };
-		003A0FAB0E0BE8C700136848 /* pshinter.c in Sources */ = {isa = PBXBuildFile; fileRef = 003A0FA10E0BE8C700136848 /* pshinter.c */; };
-		FE6C75540944ED8500568256 /* SkFontHost_FreeType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE6C75530944ED8500568256 /* SkFontHost_FreeType.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		003A0F560E0BE7DF00136848 /* ftadvanc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftadvanc.c; path = "../../extlibs/freetype-2.3.6/src/base/ftadvanc.c"; sourceTree = SOURCE_ROOT; };
-		003A0F570E0BE7DF00136848 /* ftapi.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftapi.c; path = "../../extlibs/freetype-2.3.6/src/base/ftapi.c"; sourceTree = SOURCE_ROOT; };
-		003A0F580E0BE7DF00136848 /* ftbase.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftbase.c; path = "../../extlibs/freetype-2.3.6/src/base/ftbase.c"; sourceTree = SOURCE_ROOT; };
-		003A0F590E0BE7DF00136848 /* ftbbox.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftbbox.c; path = "../../extlibs/freetype-2.3.6/src/base/ftbbox.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5A0E0BE7DF00136848 /* ftbitmap.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftbitmap.c; path = "../../extlibs/freetype-2.3.6/src/base/ftbitmap.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5B0E0BE7DF00136848 /* ftcalc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftcalc.c; path = "../../extlibs/freetype-2.3.6/src/base/ftcalc.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5C0E0BE7DF00136848 /* ftdbgmem.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftdbgmem.c; path = "../../extlibs/freetype-2.3.6/src/base/ftdbgmem.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5D0E0BE7DF00136848 /* ftdebug.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftdebug.c; path = "../../extlibs/freetype-2.3.6/src/base/ftdebug.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5E0E0BE7DF00136848 /* ftgasp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftgasp.c; path = "../../extlibs/freetype-2.3.6/src/base/ftgasp.c"; sourceTree = SOURCE_ROOT; };
-		003A0F5F0E0BE7DF00136848 /* ftgloadr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftgloadr.c; path = "../../extlibs/freetype-2.3.6/src/base/ftgloadr.c"; sourceTree = SOURCE_ROOT; };
-		003A0F600E0BE7DF00136848 /* ftglyph.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftglyph.c; path = "../../extlibs/freetype-2.3.6/src/base/ftglyph.c"; sourceTree = SOURCE_ROOT; };
-		003A0F610E0BE7DF00136848 /* ftinit.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftinit.c; path = "../../extlibs/freetype-2.3.6/src/base/ftinit.c"; sourceTree = SOURCE_ROOT; };
-		003A0F620E0BE7DF00136848 /* ftlcdfil.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftlcdfil.c; path = "../../extlibs/freetype-2.3.6/src/base/ftlcdfil.c"; sourceTree = SOURCE_ROOT; };
-		003A0F630E0BE7DF00136848 /* ftmm.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftmm.c; path = "../../extlibs/freetype-2.3.6/src/base/ftmm.c"; sourceTree = SOURCE_ROOT; };
-		003A0F640E0BE7DF00136848 /* ftnames.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftnames.c; path = "../../extlibs/freetype-2.3.6/src/base/ftnames.c"; sourceTree = SOURCE_ROOT; };
-		003A0F650E0BE7DF00136848 /* ftobjs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftobjs.c; path = "../../extlibs/freetype-2.3.6/src/base/ftobjs.c"; sourceTree = SOURCE_ROOT; };
-		003A0F660E0BE7DF00136848 /* ftoutln.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftoutln.c; path = "../../extlibs/freetype-2.3.6/src/base/ftoutln.c"; sourceTree = SOURCE_ROOT; };
-		003A0F670E0BE7DF00136848 /* ftpatent.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftpatent.c; path = "../../extlibs/freetype-2.3.6/src/base/ftpatent.c"; sourceTree = SOURCE_ROOT; };
-		003A0F680E0BE7DF00136848 /* ftrfork.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftrfork.c; path = "../../extlibs/freetype-2.3.6/src/base/ftrfork.c"; sourceTree = SOURCE_ROOT; };
-		003A0F690E0BE7DF00136848 /* ftstream.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftstream.c; path = "../../extlibs/freetype-2.3.6/src/base/ftstream.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6A0E0BE7DF00136848 /* ftstroke.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftstroke.c; path = "../../extlibs/freetype-2.3.6/src/base/ftstroke.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6B0E0BE7DF00136848 /* ftsynth.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftsynth.c; path = "../../extlibs/freetype-2.3.6/src/base/ftsynth.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6C0E0BE7DF00136848 /* ftsystem.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftsystem.c; path = "../../extlibs/freetype-2.3.6/src/base/ftsystem.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6D0E0BE7DF00136848 /* fttrigon.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fttrigon.c; path = "../../extlibs/freetype-2.3.6/src/base/fttrigon.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6E0E0BE7DF00136848 /* ftutil.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftutil.c; path = "../../extlibs/freetype-2.3.6/src/base/ftutil.c"; sourceTree = SOURCE_ROOT; };
-		003A0F6F0E0BE7DF00136848 /* ftwinfnt.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftwinfnt.c; path = "../../extlibs/freetype-2.3.6/src/base/ftwinfnt.c"; sourceTree = SOURCE_ROOT; };
-		003A0F700E0BE7DF00136848 /* ftxf86.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ftxf86.c; path = "../../extlibs/freetype-2.3.6/src/base/ftxf86.c"; sourceTree = SOURCE_ROOT; };
-		003A0F8C0E0BE80000136848 /* raster.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = raster.c; path = "../../extlibs/freetype-2.3.6/src/raster/raster.c"; sourceTree = SOURCE_ROOT; };
-		003A0F8E0E0BE81800136848 /* sfnt.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = sfnt.c; path = "../../extlibs/freetype-2.3.6/src/sfnt/sfnt.c"; sourceTree = SOURCE_ROOT; };
-		003A0F900E0BE83C00136848 /* smooth.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = smooth.c; path = "../../extlibs/freetype-2.3.6/src/smooth/smooth.c"; sourceTree = SOURCE_ROOT; };
-		003A0F920E0BE85600136848 /* autofit.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = autofit.c; path = "../../extlibs/freetype-2.3.6/src/autofit/autofit.c"; sourceTree = SOURCE_ROOT; };
-		003A0F940E0BE86E00136848 /* truetype.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = truetype.c; path = "../../extlibs/freetype-2.3.6/src/truetype/truetype.c"; sourceTree = SOURCE_ROOT; };
-		003A0F960E0BE88300136848 /* cff.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = cff.c; path = "../../extlibs/freetype-2.3.6/src/cff/cff.c"; sourceTree = SOURCE_ROOT; };
-		003A0F980E0BE89B00136848 /* psaux.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = psaux.c; path = "../../extlibs/freetype-2.3.6/src/psaux/psaux.c"; sourceTree = SOURCE_ROOT; };
-		003A0F9A0E0BE8B400136848 /* psnames.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = psnames.c; path = "../../extlibs/freetype-2.3.6/src/psnames/psnames.c"; sourceTree = SOURCE_ROOT; };
-		003A0FA10E0BE8C700136848 /* pshinter.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pshinter.c; path = "../../extlibs/freetype-2.3.6/src/pshinter/pshinter.c"; sourceTree = "<group>"; };
-		D2AAC046055464E500DB518D /* libfreetype.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libfreetype.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE6C75530944ED8500568256 /* SkFontHost_FreeType.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_FreeType.cpp; path = ../../libs/graphics/ports/SkFontHost_FreeType.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* freetype */ = {
-			isa = PBXGroup;
-			children = (
-				FE33C98F094E104700C4A640 /* base */,
-				FE33C990094E105100C4A640 /* raster */,
-				FE33C997094E109300C4A640 /* snft */,
-				FE33C998094E109D00C4A640 /* smooth */,
-				FE33C999094E10B000C4A640 /* autohint */,
-				FE33C99A094E10BD00C4A640 /* truetype */,
-				FE33C99B094E10C600C4A640 /* cff */,
-				FE33C99E094E10E100C4A640 /* psaux */,
-				FE33C99F094E10EB00C4A640 /* psnames */,
-				FE33C9A0094E10F400C4A640 /* pshinter */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = freetype;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				FE6C75530944ED8500568256 /* SkFontHost_FreeType.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libfreetype.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-		FE33C98F094E104700C4A640 /* base */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F560E0BE7DF00136848 /* ftadvanc.c */,
-				003A0F570E0BE7DF00136848 /* ftapi.c */,
-				003A0F580E0BE7DF00136848 /* ftbase.c */,
-				003A0F590E0BE7DF00136848 /* ftbbox.c */,
-				003A0F5A0E0BE7DF00136848 /* ftbitmap.c */,
-				003A0F5B0E0BE7DF00136848 /* ftcalc.c */,
-				003A0F5C0E0BE7DF00136848 /* ftdbgmem.c */,
-				003A0F5D0E0BE7DF00136848 /* ftdebug.c */,
-				003A0F5E0E0BE7DF00136848 /* ftgasp.c */,
-				003A0F5F0E0BE7DF00136848 /* ftgloadr.c */,
-				003A0F600E0BE7DF00136848 /* ftglyph.c */,
-				003A0F610E0BE7DF00136848 /* ftinit.c */,
-				003A0F620E0BE7DF00136848 /* ftlcdfil.c */,
-				003A0F630E0BE7DF00136848 /* ftmm.c */,
-				003A0F640E0BE7DF00136848 /* ftnames.c */,
-				003A0F650E0BE7DF00136848 /* ftobjs.c */,
-				003A0F660E0BE7DF00136848 /* ftoutln.c */,
-				003A0F670E0BE7DF00136848 /* ftpatent.c */,
-				003A0F680E0BE7DF00136848 /* ftrfork.c */,
-				003A0F690E0BE7DF00136848 /* ftstream.c */,
-				003A0F6A0E0BE7DF00136848 /* ftstroke.c */,
-				003A0F6B0E0BE7DF00136848 /* ftsynth.c */,
-				003A0F6C0E0BE7DF00136848 /* ftsystem.c */,
-				003A0F6D0E0BE7DF00136848 /* fttrigon.c */,
-				003A0F6E0E0BE7DF00136848 /* ftutil.c */,
-				003A0F6F0E0BE7DF00136848 /* ftwinfnt.c */,
-				003A0F700E0BE7DF00136848 /* ftxf86.c */,
-			);
-			name = base;
-			sourceTree = "<group>";
-		};
-		FE33C990094E105100C4A640 /* raster */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F8C0E0BE80000136848 /* raster.c */,
-			);
-			name = raster;
-			sourceTree = "<group>";
-		};
-		FE33C997094E109300C4A640 /* snft */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F8E0E0BE81800136848 /* sfnt.c */,
-			);
-			name = snft;
-			sourceTree = "<group>";
-		};
-		FE33C998094E109D00C4A640 /* smooth */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F900E0BE83C00136848 /* smooth.c */,
-			);
-			name = smooth;
-			sourceTree = "<group>";
-		};
-		FE33C999094E10B000C4A640 /* autohint */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F920E0BE85600136848 /* autofit.c */,
-			);
-			name = autohint;
-			sourceTree = "<group>";
-		};
-		FE33C99A094E10BD00C4A640 /* truetype */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F940E0BE86E00136848 /* truetype.c */,
-			);
-			name = truetype;
-			sourceTree = "<group>";
-		};
-		FE33C99B094E10C600C4A640 /* cff */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F960E0BE88300136848 /* cff.c */,
-			);
-			name = cff;
-			sourceTree = "<group>";
-		};
-		FE33C99E094E10E100C4A640 /* psaux */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F980E0BE89B00136848 /* psaux.c */,
-			);
-			name = psaux;
-			sourceTree = "<group>";
-		};
-		FE33C99F094E10EB00C4A640 /* psnames */ = {
-			isa = PBXGroup;
-			children = (
-				003A0F9A0E0BE8B400136848 /* psnames.c */,
-			);
-			name = psnames;
-			sourceTree = "<group>";
-		};
-		FE33C9A0094E10F400C4A640 /* pshinter */ = {
-			isa = PBXGroup;
-			children = (
-				003A0FA10E0BE8C700136848 /* pshinter.c */,
-			);
-			name = pshinter;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* freetype */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "freetype" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = freetype;
-			productName = freetype;
-			productReference = D2AAC046055464E500DB518D /* libfreetype.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "freetype2" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* freetype */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC045055464E500DB518D /* freetype */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE6C75540944ED8500568256 /* SkFontHost_FreeType.cpp in Sources */,
-				003A0F710E0BE7DF00136848 /* ftadvanc.c in Sources */,
-				003A0F720E0BE7DF00136848 /* ftapi.c in Sources */,
-				003A0F730E0BE7DF00136848 /* ftbase.c in Sources */,
-				003A0F740E0BE7DF00136848 /* ftbbox.c in Sources */,
-				003A0F750E0BE7DF00136848 /* ftbitmap.c in Sources */,
-				003A0F760E0BE7DF00136848 /* ftcalc.c in Sources */,
-				003A0F770E0BE7DF00136848 /* ftdbgmem.c in Sources */,
-				003A0F780E0BE7DF00136848 /* ftdebug.c in Sources */,
-				003A0F790E0BE7DF00136848 /* ftgasp.c in Sources */,
-				003A0F7A0E0BE7DF00136848 /* ftgloadr.c in Sources */,
-				003A0F7B0E0BE7DF00136848 /* ftglyph.c in Sources */,
-				003A0F7C0E0BE7DF00136848 /* ftinit.c in Sources */,
-				003A0F7D0E0BE7DF00136848 /* ftlcdfil.c in Sources */,
-				003A0F7E0E0BE7DF00136848 /* ftmm.c in Sources */,
-				003A0F7F0E0BE7DF00136848 /* ftnames.c in Sources */,
-				003A0F800E0BE7DF00136848 /* ftobjs.c in Sources */,
-				003A0F810E0BE7DF00136848 /* ftoutln.c in Sources */,
-				003A0F820E0BE7DF00136848 /* ftpatent.c in Sources */,
-				003A0F830E0BE7DF00136848 /* ftrfork.c in Sources */,
-				003A0F840E0BE7DF00136848 /* ftstream.c in Sources */,
-				003A0F850E0BE7DF00136848 /* ftstroke.c in Sources */,
-				003A0F860E0BE7DF00136848 /* ftsynth.c in Sources */,
-				003A0F870E0BE7DF00136848 /* ftsystem.c in Sources */,
-				003A0F880E0BE7DF00136848 /* fttrigon.c in Sources */,
-				003A0F890E0BE7DF00136848 /* ftutil.c in Sources */,
-				003A0F8A0E0BE7DF00136848 /* ftwinfnt.c in Sources */,
-				003A0F8B0E0BE7DF00136848 /* ftxf86.c in Sources */,
-				003A0F8D0E0BE80000136848 /* raster.c in Sources */,
-				003A0F8F0E0BE81800136848 /* sfnt.c in Sources */,
-				003A0F910E0BE83C00136848 /* smooth.c in Sources */,
-				003A0F930E0BE85600136848 /* autofit.c in Sources */,
-				003A0F950E0BE86E00136848 /* truetype.c in Sources */,
-				003A0F970E0BE88300136848 /* cff.c in Sources */,
-				003A0F990E0BE89B00136848 /* psaux.c in Sources */,
-				003A0F9B0E0BE8B400136848 /* psnames.c in Sources */,
-				003A0FAB0E0BE8C700136848 /* pshinter.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = freetype;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = freetype;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = YES;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					TT_CONFIG_OPTION_BYTECODE_INTERPRETER,
-					FT2_BUILD_LIBRARY,
-					DARWIN_NO_CARBON,
-					SK_DEBUG,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../extlibs/freetype-2.3.6/include ../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = YES;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					TT_CONFIG_OPTION_BYTECODE_INTERPRETER,
-					FT2_BUILD_LIBRARY,
-					DARWIN_NO_CARBON,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../extlibs/freetype-2.3.6/include ../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "freetype" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "freetype2" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/gif.xcodeproj/project.pbxproj b/ide/xcode/gif.xcodeproj/project.pbxproj
deleted file mode 100644
index 0645a35..0000000
--- a/ide/xcode/gif.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,264 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		008CFC4D0C04B77E00FB4126 /* SkMovie_gif.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 008CFC4C0C04B77E00FB4126 /* SkMovie_gif.cpp */; };
-		00B13BE30C0C6EFA0033F013 /* SkMovie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00B13BE20C0C6EFA0033F013 /* SkMovie.cpp */; };
-		FE08AB3F0945EFBE0057213F /* gif_lib_private.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AB3D0945EFBE0057213F /* gif_lib_private.h */; };
-		FE08AB400945EFBE0057213F /* gif_lib.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AB3E0945EFBE0057213F /* gif_lib.h */; };
-		FE08AB440945EFEF0057213F /* dgif_lib.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AB410945EFEF0057213F /* dgif_lib.c */; };
-		FE08AB450945EFEF0057213F /* gif_err.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AB420945EFEF0057213F /* gif_err.c */; };
-		FE08AB460945EFEF0057213F /* gifalloc.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AB430945EFEF0057213F /* gifalloc.c */; };
-		FE7B86240948E6A1001B952C /* SkImageDecoder_libgif.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE7B86230948E6A1001B952C /* SkImageDecoder_libgif.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		008CFC4C0C04B77E00FB4126 /* SkMovie_gif.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMovie_gif.cpp; path = ../../libs/graphics/images/SkMovie_gif.cpp; sourceTree = SOURCE_ROOT; };
-		00B13BE20C0C6EFA0033F013 /* SkMovie.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMovie.cpp; path = ../../libs/graphics/images/SkMovie.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libgif.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libgif.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE08AB3D0945EFBE0057213F /* gif_lib_private.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = gif_lib_private.h; path = "../../extlibs/libgif-4.0/gif_lib_private.h"; sourceTree = SOURCE_ROOT; };
-		FE08AB3E0945EFBE0057213F /* gif_lib.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = gif_lib.h; path = "../../extlibs/libgif-4.0/gif_lib.h"; sourceTree = SOURCE_ROOT; };
-		FE08AB410945EFEF0057213F /* dgif_lib.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = dgif_lib.c; path = "../../extlibs/libgif-4.0/dgif_lib.c"; sourceTree = SOURCE_ROOT; };
-		FE08AB420945EFEF0057213F /* gif_err.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = gif_err.c; path = "../../extlibs/libgif-4.0/gif_err.c"; sourceTree = SOURCE_ROOT; };
-		FE08AB430945EFEF0057213F /* gifalloc.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = gifalloc.c; path = "../../extlibs/libgif-4.0/gifalloc.c"; sourceTree = SOURCE_ROOT; };
-		FE7B86230948E6A1001B952C /* SkImageDecoder_libgif.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libgif.cpp; path = ../../libs/graphics/images/SkImageDecoder_libgif.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* gif */ = {
-			isa = PBXGroup;
-			children = (
-				00B13BE20C0C6EFA0033F013 /* SkMovie.cpp */,
-				FE08AB3C0945EF830057213F /* Include */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = gif;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				008CFC4C0C04B77E00FB4126 /* SkMovie_gif.cpp */,
-				FE7B86230948E6A1001B952C /* SkImageDecoder_libgif.cpp */,
-				FE08AB410945EFEF0057213F /* dgif_lib.c */,
-				FE08AB420945EFEF0057213F /* gif_err.c */,
-				FE08AB430945EFEF0057213F /* gifalloc.c */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libgif.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-		FE08AB3C0945EF830057213F /* Include */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AB3D0945EFBE0057213F /* gif_lib_private.h */,
-				FE08AB3E0945EFBE0057213F /* gif_lib.h */,
-			);
-			name = Include;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AB3F0945EFBE0057213F /* gif_lib_private.h in Headers */,
-				FE08AB400945EFBE0057213F /* gif_lib.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* gif */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = FE5F47EB094782A50095980F /* Build configuration list for PBXNativeTarget "gif" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = gif;
-			productName = gif;
-			productReference = D2AAC046055464E500DB518D /* libgif.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = FE5F47EF094782A50095980F /* Build configuration list for PBXProject "gif" */;
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* gif */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* gif */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AB440945EFEF0057213F /* dgif_lib.c in Sources */,
-				FE08AB450945EFEF0057213F /* gif_err.c in Sources */,
-				FE08AB460945EFEF0057213F /* gifalloc.c in Sources */,
-				FE7B86240948E6A1001B952C /* SkImageDecoder_libgif.cpp in Sources */,
-				008CFC4D0C04B77E00FB4126 /* SkMovie_gif.cpp in Sources */,
-				00B13BE30C0C6EFA0033F013 /* SkMovie.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		FE5F47EC094782A50095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					_LIB,
-					SK_FORCE_SCALARFIXED,
-				);
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = ../../include/graphics;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = gif;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		FE5F47ED094782A50095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = gif;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		FE5F47F0094782A50095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		FE5F47F1094782A50095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		FE5F47EB094782A50095980F /* Build configuration list for PBXNativeTarget "gif" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F47EC094782A50095980F /* Debug */,
-				FE5F47ED094782A50095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-		FE5F47EF094782A50095980F /* Build configuration list for PBXProject "gif" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F47F0094782A50095980F /* Debug */,
-				FE5F47F1094782A50095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/giflib.xcodeproj/project.pbxproj b/ide/xcode/giflib.xcodeproj/project.pbxproj
deleted file mode 100644
index 679bb71..0000000
--- a/ide/xcode/giflib.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,251 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 44;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		0008AE7D0DABECB600477EFB /* SkImageDecoder_libgif.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0008AE7A0DABECB600477EFB /* SkImageDecoder_libgif.cpp */; };
-		0008AE7E0DABECB600477EFB /* SkMovie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0008AE7B0DABECB600477EFB /* SkMovie.cpp */; };
-		0008AE7F0DABECB600477EFB /* SkMovie_gif.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0008AE7C0DABECB600477EFB /* SkMovie_gif.cpp */; };
-		003E41DF0DB3941900A9222D /* config.h in Headers */ = {isa = PBXBuildFile; fileRef = 003E41D80DB3941900A9222D /* config.h */; };
-		003E41E00DB3941900A9222D /* dgif_lib.c in Sources */ = {isa = PBXBuildFile; fileRef = 003E41D90DB3941900A9222D /* dgif_lib.c */; };
-		003E41E10DB3941900A9222D /* gif_err.c in Sources */ = {isa = PBXBuildFile; fileRef = 003E41DA0DB3941900A9222D /* gif_err.c */; };
-		003E41E20DB3941900A9222D /* gif_hash.h in Headers */ = {isa = PBXBuildFile; fileRef = 003E41DB0DB3941900A9222D /* gif_hash.h */; };
-		003E41E30DB3941900A9222D /* gif_lib.h in Headers */ = {isa = PBXBuildFile; fileRef = 003E41DC0DB3941900A9222D /* gif_lib.h */; };
-		003E41E40DB3941900A9222D /* gif_lib_private.h in Headers */ = {isa = PBXBuildFile; fileRef = 003E41DD0DB3941900A9222D /* gif_lib_private.h */; };
-		003E41E50DB3941900A9222D /* gifalloc.c in Sources */ = {isa = PBXBuildFile; fileRef = 003E41DE0DB3941900A9222D /* gifalloc.c */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		0008AE7A0DABECB600477EFB /* SkImageDecoder_libgif.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libgif.cpp; path = ../../libs/graphics/images/SkImageDecoder_libgif.cpp; sourceTree = SOURCE_ROOT; };
-		0008AE7B0DABECB600477EFB /* SkMovie.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkMovie.cpp; path = ../../libs/graphics/images/SkMovie.cpp; sourceTree = SOURCE_ROOT; };
-		0008AE7C0DABECB600477EFB /* SkMovie_gif.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkMovie_gif.cpp; path = ../../libs/graphics/images/SkMovie_gif.cpp; sourceTree = SOURCE_ROOT; };
-		003E41D80DB3941900A9222D /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = config.h; path = "../../extlibs/giflib-4.1.6/config.h"; sourceTree = SOURCE_ROOT; };
-		003E41D90DB3941900A9222D /* dgif_lib.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dgif_lib.c; path = "../../extlibs/giflib-4.1.6/dgif_lib.c"; sourceTree = SOURCE_ROOT; };
-		003E41DA0DB3941900A9222D /* gif_err.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = gif_err.c; path = "../../extlibs/giflib-4.1.6/gif_err.c"; sourceTree = SOURCE_ROOT; };
-		003E41DB0DB3941900A9222D /* gif_hash.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = gif_hash.h; path = "../../extlibs/giflib-4.1.6/gif_hash.h"; sourceTree = SOURCE_ROOT; };
-		003E41DC0DB3941900A9222D /* gif_lib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = gif_lib.h; path = "../../extlibs/giflib-4.1.6/gif_lib.h"; sourceTree = SOURCE_ROOT; };
-		003E41DD0DB3941900A9222D /* gif_lib_private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = gif_lib_private.h; path = "../../extlibs/giflib-4.1.6/gif_lib_private.h"; sourceTree = SOURCE_ROOT; };
-		003E41DE0DB3941900A9222D /* gifalloc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = gifalloc.c; path = "../../extlibs/giflib-4.1.6/gifalloc.c"; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libgiflib.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libgiflib.a; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* giflib */ = {
-			isa = PBXGroup;
-			children = (
-				0008AE7A0DABECB600477EFB /* SkImageDecoder_libgif.cpp */,
-				0008AE7B0DABECB600477EFB /* SkMovie.cpp */,
-				0008AE7C0DABECB600477EFB /* SkMovie_gif.cpp */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = giflib;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				003E41D80DB3941900A9222D /* config.h */,
-				003E41D90DB3941900A9222D /* dgif_lib.c */,
-				003E41DA0DB3941900A9222D /* gif_err.c */,
-				003E41DB0DB3941900A9222D /* gif_hash.h */,
-				003E41DC0DB3941900A9222D /* gif_lib.h */,
-				003E41DD0DB3941900A9222D /* gif_lib_private.h */,
-				003E41DE0DB3941900A9222D /* gifalloc.c */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libgiflib.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				003E41DF0DB3941900A9222D /* config.h in Headers */,
-				003E41E20DB3941900A9222D /* gif_hash.h in Headers */,
-				003E41E30DB3941900A9222D /* gif_lib.h in Headers */,
-				003E41E40DB3941900A9222D /* gif_lib_private.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* giflib */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "giflib" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = giflib;
-			productName = giflib;
-			productReference = D2AAC046055464E500DB518D /* libgiflib.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "giflib" */;
-			compatibilityVersion = "Xcode 3.0";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* giflib */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				D2AAC045055464E500DB518D /* giflib */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				0008AE7D0DABECB600477EFB /* SkImageDecoder_libgif.cpp in Sources */,
-				0008AE7E0DABECB600477EFB /* SkMovie.cpp in Sources */,
-				0008AE7F0DABECB600477EFB /* SkMovie_gif.cpp in Sources */,
-				003E41E00DB3941900A9222D /* dgif_lib.c in Sources */,
-				003E41E10DB3941900A9222D /* gif_err.c in Sources */,
-				003E41E50DB3941900A9222D /* gifalloc.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = giflib;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = giflib;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_OBJC_EXCEPTIONS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					HAVE_CONFIG_H,
-					SK_DEBUG,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_OBJC_EXCEPTIONS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					HAVE_CONFIG_H,
-					SK_RELEASE,
-				);
-				GCC_THREADSAFE_STATICS = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "giflib" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "giflib" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/graphics.xcodeproj/project.pbxproj b/ide/xcode/graphics.xcodeproj/project.pbxproj
deleted file mode 100644
index 0eabe53..0000000
--- a/ide/xcode/graphics.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,1220 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 44;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		00081FDE0A67CEF400A37923 /* SkRasterizer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00081FDC0A67CEF400A37923 /* SkRasterizer.cpp */; };
-		00081FE40A67CF1800A37923 /* SkColorFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = 00081FE00A67CF1800A37923 /* SkColorFilter.h */; };
-		00081FE50A67CF1800A37923 /* SkRasterizer.h in Headers */ = {isa = PBXBuildFile; fileRef = 00081FE10A67CF1800A37923 /* SkRasterizer.h */; };
-		00081FE70A67CF1800A37923 /* SkTypeface.h in Headers */ = {isa = PBXBuildFile; fileRef = 00081FE30A67CF1800A37923 /* SkTypeface.h */; };
-		000C28720AA50FFE005A479B /* SkColorFilters.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000C28700AA50FFE005A479B /* SkColorFilters.cpp */; };
-		000C28730AA50FFF005A479B /* SkCullPoints.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000C28710AA50FFE005A479B /* SkCullPoints.cpp */; };
-		000C28790AA51077005A479B /* SkColorFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000C28780AA51077005A479B /* SkColorFilter.cpp */; };
-		001142D60DCA3EE90070D0A3 /* SkPicturePlayback.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001142D20DCA3EE90070D0A3 /* SkPicturePlayback.cpp */; };
-		001142D70DCA3EE90070D0A3 /* SkPicturePlayback.h in Headers */ = {isa = PBXBuildFile; fileRef = 001142D30DCA3EE90070D0A3 /* SkPicturePlayback.h */; };
-		001142D80DCA3EE90070D0A3 /* SkPictureRecord.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001142D40DCA3EE90070D0A3 /* SkPictureRecord.cpp */; };
-		001142D90DCA3EE90070D0A3 /* SkPictureRecord.h in Headers */ = {isa = PBXBuildFile; fileRef = 001142D50DCA3EE90070D0A3 /* SkPictureRecord.h */; };
-		0011430B0DCA458A0070D0A3 /* SkPictureFlat.h in Headers */ = {isa = PBXBuildFile; fileRef = 0011430A0DCA458A0070D0A3 /* SkPictureFlat.h */; };
-		0011430D0DCA45990070D0A3 /* SkPictureFlat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0011430C0DCA45990070D0A3 /* SkPictureFlat.cpp */; };
-		0019627D0EACB91200447A07 /* SkPageFlipper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0019627C0EACB91200447A07 /* SkPageFlipper.cpp */; };
-		0019627F0EACB92A00447A07 /* SkFlipPixelRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0019627E0EACB92A00447A07 /* SkFlipPixelRef.cpp */; };
-		001962810EACB94400447A07 /* SkPathHeap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001962800EACB94400447A07 /* SkPathHeap.cpp */; };
-		001FFBBD0CD8D9ED000CDF07 /* SkImageRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 001FFBBC0CD8D9ED000CDF07 /* SkImageRef.cpp */; };
-		0027DCD00B24CA3900076079 /* SkDevice.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0027DCCF0B24CA3900076079 /* SkDevice.cpp */; };
-		0027DCD20B24CA4E00076079 /* SkDevice.h in Headers */ = {isa = PBXBuildFile; fileRef = 0027DCD10B24CA4E00076079 /* SkDevice.h */; };
-		002B774F0A1BB054003B067F /* SkShaderExtras.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002B774E0A1BB054003B067F /* SkShaderExtras.cpp */; };
-		002B77550A1BB07A003B067F /* SkCornerPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = 002B77500A1BB07A003B067F /* SkCornerPathEffect.h */; };
-		002B77560A1BB07A003B067F /* SkDeque.h in Headers */ = {isa = PBXBuildFile; fileRef = 002B77510A1BB07A003B067F /* SkDeque.h */; };
-		002B77570A1BB07A003B067F /* SkPaint.h in Headers */ = {isa = PBXBuildFile; fileRef = 002B77520A1BB07A003B067F /* SkPaint.h */; };
-		002B77580A1BB07A003B067F /* SkPorterDuff.h in Headers */ = {isa = PBXBuildFile; fileRef = 002B77530A1BB07A003B067F /* SkPorterDuff.h */; };
-		002B77590A1BB07A003B067F /* SkShaderExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = 002B77540A1BB07A003B067F /* SkShaderExtras.h */; };
-		002C8E6E0A0A515000FFB8EC /* SkDeque.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002C8E6D0A0A515000FFB8EC /* SkDeque.cpp */; };
-		003091FA0C19BE04009F515A /* SkBitmapProcShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003091F30C19BE04009F515A /* SkBitmapProcShader.cpp */; };
-		003091FB0C19BE04009F515A /* SkBitmapProcShader.h in Headers */ = {isa = PBXBuildFile; fileRef = 003091F40C19BE04009F515A /* SkBitmapProcShader.h */; };
-		003091FD0C19BE04009F515A /* SkBitmapProcState_matrixProcs.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003091F60C19BE04009F515A /* SkBitmapProcState_matrixProcs.cpp */; };
-		003091FF0C19BE04009F515A /* SkBitmapProcState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003091F80C19BE04009F515A /* SkBitmapProcState.cpp */; };
-		003092000C19BE04009F515A /* SkBitmapProcState.h in Headers */ = {isa = PBXBuildFile; fileRef = 003091F90C19BE04009F515A /* SkBitmapProcState.h */; };
-		003538200C85BDCE007289C0 /* SkPixelXorXfermode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0035381F0C85BDCE007289C0 /* SkPixelXorXfermode.cpp */; };
-		003538590C85BF0D007289C0 /* SkColorShader.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538530C85BF0D007289C0 /* SkColorShader.h */; };
-		0035385A0C85BF0D007289C0 /* SkDrawFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538540C85BF0D007289C0 /* SkDrawFilter.h */; };
-		0035385B0C85BF0D007289C0 /* SkDrawLooper.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538550C85BF0D007289C0 /* SkDrawLooper.h */; };
-		0035385C0C85BF0D007289C0 /* SkKernel33MaskFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538560C85BF0D007289C0 /* SkKernel33MaskFilter.h */; };
-		0035385D0C85BF0D007289C0 /* SkPackBits.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538570C85BF0D007289C0 /* SkPackBits.h */; };
-		0035385E0C85BF0D007289C0 /* SkPicture.h in Headers */ = {isa = PBXBuildFile; fileRef = 003538580C85BF0D007289C0 /* SkPicture.h */; };
-		003E6EFE0D09EF84005435C0 /* SkColorMatrix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003E6EFC0D09EF84005435C0 /* SkColorMatrix.cpp */; };
-		003E6EFF0D09EF84005435C0 /* SkColorMatrixFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003E6EFD0D09EF84005435C0 /* SkColorMatrixFilter.cpp */; };
-		003FF1680DAE9C0F00601F6B /* SkImageRef_GlobalPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 003FF1670DAE9C0F00601F6B /* SkImageRef_GlobalPool.cpp */; };
-		0043B2DB0D75C840004A0E2A /* SkScaledBitmapSampler.h in Headers */ = {isa = PBXBuildFile; fileRef = 0043B2D80D75C840004A0E2A /* SkScaledBitmapSampler.h */; };
-		00523E950C7B335D00D53402 /* Sk1DPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E840C7B335D00D53402 /* Sk1DPathEffect.cpp */; };
-		00523E960C7B335D00D53402 /* Sk2DPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E850C7B335D00D53402 /* Sk2DPathEffect.cpp */; };
-		00523E970C7B335D00D53402 /* SkBlurMask.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E860C7B335D00D53402 /* SkBlurMask.cpp */; };
-		00523E980C7B335D00D53402 /* SkBlurMask.h in Headers */ = {isa = PBXBuildFile; fileRef = 00523E870C7B335D00D53402 /* SkBlurMask.h */; };
-		00523E990C7B335D00D53402 /* SkBlurMaskFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E880C7B335D00D53402 /* SkBlurMaskFilter.cpp */; };
-		00523E9A0C7B335D00D53402 /* SkCamera.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E890C7B335D00D53402 /* SkCamera.cpp */; };
-		00523E9B0C7B335D00D53402 /* SkDashPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E8A0C7B335D00D53402 /* SkDashPathEffect.cpp */; };
-		00523E9C0C7B335D00D53402 /* SkDiscretePathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E8B0C7B335D00D53402 /* SkDiscretePathEffect.cpp */; };
-		00523E9D0C7B335D00D53402 /* SkEmbossMask_Table.h in Headers */ = {isa = PBXBuildFile; fileRef = 00523E8C0C7B335D00D53402 /* SkEmbossMask_Table.h */; };
-		00523E9E0C7B335D00D53402 /* SkEmbossMask.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E8D0C7B335D00D53402 /* SkEmbossMask.cpp */; };
-		00523E9F0C7B335D00D53402 /* SkEmbossMask.h in Headers */ = {isa = PBXBuildFile; fileRef = 00523E8E0C7B335D00D53402 /* SkEmbossMask.h */; };
-		00523EA00C7B335D00D53402 /* SkEmbossMaskFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E8F0C7B335D00D53402 /* SkEmbossMaskFilter.cpp */; };
-		00523EA10C7B335D00D53402 /* SkGradientShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E900C7B335D00D53402 /* SkGradientShader.cpp */; };
-		00523EA30C7B335D00D53402 /* SkRadialGradient_Table.h in Headers */ = {isa = PBXBuildFile; fileRef = 00523E920C7B335D00D53402 /* SkRadialGradient_Table.h */; };
-		00523EA40C7B335D00D53402 /* SkTransparentShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E930C7B335D00D53402 /* SkTransparentShader.cpp */; };
-		00523EA50C7B335D00D53402 /* SkUnitMappers.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523E940C7B335D00D53402 /* SkUnitMappers.cpp */; };
-		00523EA90C7B33B100D53402 /* SkUnitMappers.h in Headers */ = {isa = PBXBuildFile; fileRef = 00523EA80C7B33B100D53402 /* SkUnitMappers.h */; };
-		00523F420C7B3C1400D53402 /* SkFlattenable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00523F410C7B3C1400D53402 /* SkFlattenable.cpp */; };
-		0053B0EE0D3557960016606F /* SkPaintFlagsDrawFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0053B0ED0D3557960016606F /* SkPaintFlagsDrawFilter.cpp */; };
-		0053B0F00D3557AD0016606F /* SkTypeface.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0053B0EF0D3557AD0016606F /* SkTypeface.cpp */; };
-		006B542E0C42B355008E512D /* SkBlurDrawLooper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 006B542D0C42B355008E512D /* SkBlurDrawLooper.cpp */; };
-		006B54390C42B3B0008E512D /* SkBlurDrawLooper.h in Headers */ = {isa = PBXBuildFile; fileRef = 006B54380C42B3B0008E512D /* SkBlurDrawLooper.h */; };
-		006D3B5F0CE0CAE700CE1224 /* SkWriter32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 006D3B5E0CE0CAE700CE1224 /* SkWriter32.cpp */; };
-		007336190DDC859F00A0DB2A /* SkPtrRecorder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007336180DDC859F00A0DB2A /* SkPtrRecorder.cpp */; };
-		008180E70D92D57300A2E56D /* SkScaledBitmapSampler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 008180E60D92D57300A2E56D /* SkScaledBitmapSampler.cpp */; };
-		0084BECB0A67EB6F003713D0 /* SkLayerRasterizer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0084BECA0A67EB6F003713D0 /* SkLayerRasterizer.cpp */; };
-		0084BECD0A67EB98003713D0 /* SkLayerRasterizer.h in Headers */ = {isa = PBXBuildFile; fileRef = 0084BECC0A67EB98003713D0 /* SkLayerRasterizer.h */; };
-		008618740D46CC75007F0674 /* SkBlitRow_D4444.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 008618720D46CC75007F0674 /* SkBlitRow_D4444.cpp */; };
-		008618750D46CC75007F0674 /* SkBlitter_4444.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 008618730D46CC75007F0674 /* SkBlitter_4444.cpp */; };
-		009306CC0AD3F8520068227B /* SkCornerPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009306CB0AD3F8520068227B /* SkCornerPathEffect.cpp */; };
-		009866480ACD95EF00B69A0B /* SkAvoidXfermode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009866470ACD95EF00B69A0B /* SkAvoidXfermode.cpp */; };
-		009907F10D53A06200AD25AA /* SkBitmap_scroll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009907F00D53A06200AD25AA /* SkBitmap_scroll.cpp */; };
-		009A39630DAE52FA00EB3A73 /* SkImageRefPool.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A39620DAE52FA00EB3A73 /* SkImageRefPool.cpp */; };
-		009A75E80DA1DF5D00876C03 /* SkDrawProcs.h in Headers */ = {isa = PBXBuildFile; fileRef = 009A75E60DA1DF5D00876C03 /* SkDrawProcs.h */; };
-		009A75EA0DA1DF8400876C03 /* SkNinePatch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009A75E90DA1DF8400876C03 /* SkNinePatch.cpp */; };
-		009B1EAE0DD224CF00EDFFF4 /* SkPixelRef.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 009B1EAD0DD224CF00EDFFF4 /* SkPixelRef.cpp */; };
-		00A159D00C469A1200DB6CED /* SkBlitRow_D16.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00A159CC0C469A1200DB6CED /* SkBlitRow_D16.cpp */; };
-		00A159D10C469A1200DB6CED /* SkBlitRow.h in Headers */ = {isa = PBXBuildFile; fileRef = 00A159CD0C469A1200DB6CED /* SkBlitRow.h */; };
-		00A159D20C469A1200DB6CED /* SkDither.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00A159CE0C469A1200DB6CED /* SkDither.cpp */; };
-		00A2188A0B652EEC0056CB69 /* SkMask.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00A218890B652EEC0056CB69 /* SkMask.cpp */; };
-		00B4AC4F0E9BF59400A184BF /* SkPicture.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00B4AC4E0E9BF59400A184BF /* SkPicture.cpp */; };
-		00B5022D09DB127D00A01CD6 /* SkRegionPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = 00B5022C09DB127D00A01CD6 /* SkRegionPriv.h */; };
-		00B8EC940EB6A319003C2F6F /* SkLayerDrawLooper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00B8EC930EB6A319003C2F6F /* SkLayerDrawLooper.cpp */; };
-		00C88FEF0D89B7920015D427 /* SkUnPreMultiply.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00C88FEE0D89B7920015D427 /* SkUnPreMultiply.cpp */; };
-		FE20DF0C0C7F154F00AAC91E /* SkKernel33MaskFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF0B0C7F154F00AAC91E /* SkKernel33MaskFilter.cpp */; };
-		FE20DF200C7F157B00AAC91E /* SkMovie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF160C7F157B00AAC91E /* SkMovie.cpp */; };
-		FE20DF660C7F15D200AAC91E /* ARGB32_Clamp_Bilinear_BitmapShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF210C7F15D200AAC91E /* ARGB32_Clamp_Bilinear_BitmapShader.h */; };
-		FE20DF670C7F15D200AAC91E /* SkAlphaRuns.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF220C7F15D200AAC91E /* SkAlphaRuns.cpp */; };
-		FE20DF680C7F15D200AAC91E /* SkAntiRun.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF230C7F15D200AAC91E /* SkAntiRun.h */; };
-		FE20DF690C7F15D200AAC91E /* SkAutoKern.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF240C7F15D200AAC91E /* SkAutoKern.h */; };
-		FE20DF6A0C7F15D200AAC91E /* SkBitmap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF250C7F15D200AAC91E /* SkBitmap.cpp */; };
-		FE20DF6B0C7F15D200AAC91E /* SkBitmapProcState_matrix.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF260C7F15D200AAC91E /* SkBitmapProcState_matrix.h */; };
-		FE20DF6C0C7F15D200AAC91E /* SkBitmapProcState_sample.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF270C7F15D200AAC91E /* SkBitmapProcState_sample.h */; };
-		FE20DF6D0C7F15D200AAC91E /* SkBitmapSampler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF280C7F15D200AAC91E /* SkBitmapSampler.cpp */; };
-		FE20DF6E0C7F15D200AAC91E /* SkBitmapSampler.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF290C7F15D200AAC91E /* SkBitmapSampler.h */; };
-		FE20DF6F0C7F15D200AAC91E /* SkBitmapSamplerTemplate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF2A0C7F15D200AAC91E /* SkBitmapSamplerTemplate.h */; };
-		FE20DF700C7F15D200AAC91E /* SkBitmapShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF2B0C7F15D200AAC91E /* SkBitmapShader.cpp */; };
-		FE20DF710C7F15D200AAC91E /* SkBitmapShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF2C0C7F15D200AAC91E /* SkBitmapShader.h */; };
-		FE20DF720C7F15D200AAC91E /* SkBitmapShader16BilerpTemplate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF2D0C7F15D200AAC91E /* SkBitmapShader16BilerpTemplate.h */; };
-		FE20DF730C7F15D200AAC91E /* SkBitmapShaderTemplate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF2E0C7F15D200AAC91E /* SkBitmapShaderTemplate.h */; };
-		FE20DF740C7F15D200AAC91E /* SkBlitBWMaskTemplate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF2F0C7F15D200AAC91E /* SkBlitBWMaskTemplate.h */; };
-		FE20DF750C7F15D200AAC91E /* SkBlitter_A1.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF300C7F15D200AAC91E /* SkBlitter_A1.cpp */; };
-		FE20DF760C7F15D200AAC91E /* SkBlitter_A8.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF310C7F15D200AAC91E /* SkBlitter_A8.cpp */; };
-		FE20DF770C7F15D200AAC91E /* SkBlitter_ARGB32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF320C7F15D200AAC91E /* SkBlitter_ARGB32.cpp */; };
-		FE20DF780C7F15D200AAC91E /* SkBlitter_RGB16.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF330C7F15D200AAC91E /* SkBlitter_RGB16.cpp */; };
-		FE20DF790C7F15D200AAC91E /* SkBlitter_Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF340C7F15D200AAC91E /* SkBlitter_Sprite.cpp */; };
-		FE20DF7A0C7F15D200AAC91E /* SkBlitter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF350C7F15D200AAC91E /* SkBlitter.cpp */; };
-		FE20DF7B0C7F15D200AAC91E /* SkBlitter.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF360C7F15D200AAC91E /* SkBlitter.h */; };
-		FE20DF7C0C7F15D200AAC91E /* SkCanvas.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF370C7F15D200AAC91E /* SkCanvas.cpp */; };
-		FE20DF7D0C7F15D200AAC91E /* SkColor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF380C7F15D200AAC91E /* SkColor.cpp */; };
-		FE20DF7E0C7F15D200AAC91E /* SkColorTable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF390C7F15D200AAC91E /* SkColorTable.cpp */; };
-		FE20DF7F0C7F15D200AAC91E /* SkCoreBlitters.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF3A0C7F15D200AAC91E /* SkCoreBlitters.h */; };
-		FE20DF800C7F15D200AAC91E /* SkDraw.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF3B0C7F15D200AAC91E /* SkDraw.cpp */; };
-		FE20DF810C7F15D200AAC91E /* SkEdge.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF3C0C7F15D200AAC91E /* SkEdge.cpp */; };
-		FE20DF820C7F15D200AAC91E /* SkEdge.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF3D0C7F15D200AAC91E /* SkEdge.h */; };
-		FE20DF830C7F15D200AAC91E /* SkFilterProc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF3E0C7F15D200AAC91E /* SkFilterProc.cpp */; };
-		FE20DF840C7F15D200AAC91E /* SkFilterProc.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF3F0C7F15D200AAC91E /* SkFilterProc.h */; };
-		FE20DF850C7F15D200AAC91E /* SkFP.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF400C7F15D200AAC91E /* SkFP.h */; };
-		FE20DF860C7F15D200AAC91E /* SkGeometry.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF410C7F15D200AAC91E /* SkGeometry.cpp */; };
-		FE20DF870C7F15D200AAC91E /* SkGeometry.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF420C7F15D200AAC91E /* SkGeometry.h */; };
-		FE20DF880C7F15D200AAC91E /* SkGlobals.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF430C7F15D200AAC91E /* SkGlobals.cpp */; };
-		FE20DF890C7F15D200AAC91E /* SkGlyphCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF440C7F15D200AAC91E /* SkGlyphCache.cpp */; };
-		FE20DF8A0C7F15D200AAC91E /* SkGlyphCache.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF450C7F15D200AAC91E /* SkGlyphCache.h */; };
-		FE20DF8B0C7F15D200AAC91E /* SkGraphics.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF460C7F15D200AAC91E /* SkGraphics.cpp */; };
-		FE20DF8C0C7F15D200AAC91E /* SkMaskFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF470C7F15D200AAC91E /* SkMaskFilter.cpp */; };
-		FE20DF8D0C7F15D200AAC91E /* SkPackBits.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF480C7F15D200AAC91E /* SkPackBits.cpp */; };
-		FE20DF8E0C7F15D200AAC91E /* SkPaint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF490C7F15D200AAC91E /* SkPaint.cpp */; };
-		FE20DF8F0C7F15D200AAC91E /* SkPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4A0C7F15D200AAC91E /* SkPath.cpp */; };
-		FE20DF900C7F15D200AAC91E /* SkPathEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4B0C7F15D200AAC91E /* SkPathEffect.cpp */; };
-		FE20DF910C7F15D200AAC91E /* SkPathMeasure.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4C0C7F15D200AAC91E /* SkPathMeasure.cpp */; };
-		FE20DF920C7F15D200AAC91E /* SkProcSpriteBlitter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4D0C7F15D200AAC91E /* SkProcSpriteBlitter.cpp */; };
-		FE20DF930C7F15D200AAC91E /* SkRefCnt.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4E0C7F15D200AAC91E /* SkRefCnt.cpp */; };
-		FE20DF940C7F15D200AAC91E /* SkRegion_path.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF4F0C7F15D200AAC91E /* SkRegion_path.cpp */; };
-		FE20DF950C7F15D200AAC91E /* SkScalerContext.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF500C7F15D200AAC91E /* SkScalerContext.cpp */; };
-		FE20DF960C7F15D200AAC91E /* SkScan_Antihair.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF510C7F15D200AAC91E /* SkScan_Antihair.cpp */; };
-		FE20DF970C7F15D200AAC91E /* SkScan_AntiPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF520C7F15D200AAC91E /* SkScan_AntiPath.cpp */; };
-		FE20DF980C7F15D200AAC91E /* SkScan_Hairline.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF530C7F15D200AAC91E /* SkScan_Hairline.cpp */; };
-		FE20DF990C7F15D200AAC91E /* SkScan_Path.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF540C7F15D200AAC91E /* SkScan_Path.cpp */; };
-		FE20DF9A0C7F15D200AAC91E /* SkScan.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF550C7F15D200AAC91E /* SkScan.cpp */; };
-		FE20DF9B0C7F15D200AAC91E /* SkScan.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF560C7F15D200AAC91E /* SkScan.h */; };
-		FE20DF9C0C7F15D200AAC91E /* SkScanPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF570C7F15D200AAC91E /* SkScanPriv.h */; };
-		FE20DF9D0C7F15D200AAC91E /* SkShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF580C7F15D200AAC91E /* SkShader.cpp */; };
-		FE20DF9E0C7F15D200AAC91E /* SkSpriteBlitter_ARGB32.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF590C7F15D200AAC91E /* SkSpriteBlitter_ARGB32.cpp */; };
-		FE20DF9F0C7F15D200AAC91E /* SkSpriteBlitter_RGB16.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF5A0C7F15D200AAC91E /* SkSpriteBlitter_RGB16.cpp */; };
-		FE20DFA00C7F15D200AAC91E /* SkSpriteBlitter.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF5B0C7F15D200AAC91E /* SkSpriteBlitter.h */; };
-		FE20DFA10C7F15D200AAC91E /* SkSpriteBlitterTemplate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF5C0C7F15D200AAC91E /* SkSpriteBlitterTemplate.h */; };
-		FE20DFA20C7F15D200AAC91E /* SkString.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF5D0C7F15D200AAC91E /* SkString.cpp */; };
-		FE20DFA30C7F15D200AAC91E /* SkStroke.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF5E0C7F15D200AAC91E /* SkStroke.cpp */; };
-		FE20DFA40C7F15D200AAC91E /* SkStrokerPriv.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF5F0C7F15D200AAC91E /* SkStrokerPriv.cpp */; };
-		FE20DFA50C7F15D200AAC91E /* SkStrokerPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF600C7F15D200AAC91E /* SkStrokerPriv.h */; };
-		FE20DFA60C7F15D200AAC91E /* SkTemplatesPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF610C7F15D200AAC91E /* SkTemplatesPriv.h */; };
-		FE20DFA70C7F15D200AAC91E /* SkTSearch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF620C7F15D200AAC91E /* SkTSearch.cpp */; };
-		FE20DFA80C7F15D200AAC91E /* SkTSort.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20DF630C7F15D200AAC91E /* SkTSort.h */; };
-		FE20DFA90C7F15D200AAC91E /* SkUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF640C7F15D200AAC91E /* SkUtils.cpp */; };
-		FE20DFAA0C7F15D200AAC91E /* SkXfermode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE20DF650C7F15D200AAC91E /* SkXfermode.cpp */; };
-		FE5F486E094788030095980F /* SkImageDecoder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F486B094788030095980F /* SkImageDecoder.cpp */; };
-		FE5F486F094788030095980F /* SkStream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F486C094788030095980F /* SkStream.cpp */; };
-		FE5F48BC094797D00095980F /* SkBML_Verbs.h in Headers */ = {isa = PBXBuildFile; fileRef = FE5F48B3094797D00095980F /* SkBML_Verbs.h */; };
-		FE5F48BD094797D00095980F /* SkBML_XMLParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48B4094797D00095980F /* SkBML_XMLParser.cpp */; };
-		FE5F48BE094797D00095980F /* SkDOM.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48B5094797D00095980F /* SkDOM.cpp */; };
-		FE5F48C1094797D00095980F /* SkParse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48B8094797D00095980F /* SkParse.cpp */; };
-		FE5F48C2094797D00095980F /* SkParseColor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48B9094797D00095980F /* SkParseColor.cpp */; };
-		FE5F48C3094797D00095980F /* SkXMLParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48BA094797D00095980F /* SkXMLParser.cpp */; };
-		FE5F48C4094797D00095980F /* SkXMLWriter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE5F48BB094797D00095980F /* SkXMLWriter.cpp */; };
-		FEDCE31809C9CEC70042D964 /* SkDebug.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEDCE31709C9CEC70042D964 /* SkDebug.cpp */; };
-		FEEBB826094213B900C371A7 /* Sk1DPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7BE094213B900C371A7 /* Sk1DPathEffect.h */; };
-		FEEBB827094213B900C371A7 /* Sk2DPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7BF094213B900C371A7 /* Sk2DPathEffect.h */; };
-		FEEBB829094213B900C371A7 /* SkAnimator.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C1094213B900C371A7 /* SkAnimator.h */; };
-		FEEBB82A094213B900C371A7 /* SkAnimatorView.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C2094213B900C371A7 /* SkAnimatorView.h */; };
-		FEEBB82B094213B900C371A7 /* SkBGViewArtist.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C3094213B900C371A7 /* SkBGViewArtist.h */; };
-		FEEBB82C094213B900C371A7 /* SkBitmap.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C4094213B900C371A7 /* SkBitmap.h */; };
-		FEEBB82E094213B900C371A7 /* SkBlurMaskFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C6094213B900C371A7 /* SkBlurMaskFilter.h */; };
-		FEEBB82F094213B900C371A7 /* SkBML_WXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C7094213B900C371A7 /* SkBML_WXMLParser.h */; };
-		FEEBB830094213B900C371A7 /* SkBML_XMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C8094213B900C371A7 /* SkBML_XMLParser.h */; };
-		FEEBB831094213B900C371A7 /* SkBounder.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7C9094213B900C371A7 /* SkBounder.h */; };
-		FEEBB833094213B900C371A7 /* SkCamera.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7CB094213B900C371A7 /* SkCamera.h */; };
-		FEEBB834094213B900C371A7 /* SkCanvas.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7CC094213B900C371A7 /* SkCanvas.h */; };
-		FEEBB835094213B900C371A7 /* SkColor.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7CD094213B900C371A7 /* SkColor.h */; };
-		FEEBB836094213B900C371A7 /* SkColorPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7CE094213B900C371A7 /* SkColorPriv.h */; };
-		FEEBB837094213B900C371A7 /* SkDashPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7CF094213B900C371A7 /* SkDashPathEffect.h */; };
-		FEEBB838094213B900C371A7 /* SkDescriptor.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D0094213B900C371A7 /* SkDescriptor.h */; };
-		FEEBB839094213B900C371A7 /* SkDiscretePathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D1094213B900C371A7 /* SkDiscretePathEffect.h */; };
-		FEEBB83A094213B900C371A7 /* SkDOM.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D2094213B900C371A7 /* SkDOM.h */; };
-		FEEBB83B094213B900C371A7 /* SkEmbossMaskFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D3094213B900C371A7 /* SkEmbossMaskFilter.h */; };
-		FEEBB83D094213B900C371A7 /* SkEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D5094213B900C371A7 /* SkEvent.h */; };
-		FEEBB83E094213B900C371A7 /* SkEventSink.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D6094213B900C371A7 /* SkEventSink.h */; };
-		FEEBB841094213B900C371A7 /* SkFlattenable.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7D9094213B900C371A7 /* SkFlattenable.h */; };
-		FEEBB843094213B900C371A7 /* SkFontCodec.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7DB094213B900C371A7 /* SkFontCodec.h */; };
-		FEEBB844094213B900C371A7 /* SkFontHost.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7DC094213B900C371A7 /* SkFontHost.h */; };
-		FEEBB846094213B900C371A7 /* SkGlobals.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7DE094213B900C371A7 /* SkGlobals.h */; };
-		FEEBB847094213B900C371A7 /* SkGradientShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7DF094213B900C371A7 /* SkGradientShader.h */; };
-		FEEBB848094213B900C371A7 /* SkGraphics.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E0094213B900C371A7 /* SkGraphics.h */; };
-		FEEBB849094213B900C371A7 /* SkImageDecoder.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E1094213B900C371A7 /* SkImageDecoder.h */; };
-		FEEBB84C094213B900C371A7 /* SkJS.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E4094213B900C371A7 /* SkJS.h */; };
-		FEEBB84D094213B900C371A7 /* SkKey.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E5094213B900C371A7 /* SkKey.h */; };
-		FEEBB850094213B900C371A7 /* SkMask.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E8094213B900C371A7 /* SkMask.h */; };
-		FEEBB851094213B900C371A7 /* SkMaskFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7E9094213B900C371A7 /* SkMaskFilter.h */; };
-		FEEBB854094213B900C371A7 /* SkMetaData.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7EC094213B900C371A7 /* SkMetaData.h */; };
-		FEEBB855094213B900C371A7 /* SkOSFile.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7ED094213B900C371A7 /* SkOSFile.h */; };
-		FEEBB856094213B900C371A7 /* SkOSMenu.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7EE094213B900C371A7 /* SkOSMenu.h */; };
-		FEEBB857094213B900C371A7 /* SkOSSound.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7EF094213B900C371A7 /* SkOSSound.h */; };
-		FEEBB858094213B900C371A7 /* SkOSWindow_Mac.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F0094213B900C371A7 /* SkOSWindow_Mac.h */; };
-		FEEBB859094213B900C371A7 /* SkOSWindow_Unix.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F1094213B900C371A7 /* SkOSWindow_Unix.h */; };
-		FEEBB85A094213B900C371A7 /* SkOSWindow_Win.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F2094213B900C371A7 /* SkOSWindow_Win.h */; };
-		FEEBB85C094213B900C371A7 /* SkParse.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F4094213B900C371A7 /* SkParse.h */; };
-		FEEBB85D094213B900C371A7 /* SkParsePaint.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F5094213B900C371A7 /* SkParsePaint.h */; };
-		FEEBB85E094213B900C371A7 /* SkPath.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F6094213B900C371A7 /* SkPath.h */; };
-		FEEBB85F094213B900C371A7 /* SkPathEffect.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F7094213B900C371A7 /* SkPathEffect.h */; };
-		FEEBB860094213B900C371A7 /* SkPathMeasure.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB7F8094213B900C371A7 /* SkPathMeasure.h */; };
-		FEEBB869094213B900C371A7 /* SkRefCnt.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB801094213B900C371A7 /* SkRefCnt.h */; };
-		FEEBB86C094213B900C371A7 /* SkScalerContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB804094213B900C371A7 /* SkScalerContext.h */; };
-		FEEBB86D094213B900C371A7 /* SkShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB805094213B900C371A7 /* SkShader.h */; };
-		FEEBB86E094213B900C371A7 /* SkStackViewLayout.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB806094213B900C371A7 /* SkStackViewLayout.h */; };
-		FEEBB870094213B900C371A7 /* SkStream.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB808094213B900C371A7 /* SkStream.h */; };
-		FEEBB871094213B900C371A7 /* SkStream_Win.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB809094213B900C371A7 /* SkStream_Win.h */; };
-		FEEBB872094213B900C371A7 /* SkString.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80A094213B900C371A7 /* SkString.h */; };
-		FEEBB873094213B900C371A7 /* SkStroke.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80B094213B900C371A7 /* SkStroke.h */; };
-		FEEBB874094213B900C371A7 /* SkSVGAttribute.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80C094213B900C371A7 /* SkSVGAttribute.h */; };
-		FEEBB875094213B900C371A7 /* SkSVGBase.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80D094213B900C371A7 /* SkSVGBase.h */; };
-		FEEBB876094213B900C371A7 /* SkSVGPaintState.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80E094213B900C371A7 /* SkSVGPaintState.h */; };
-		FEEBB877094213B900C371A7 /* SkSVGParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB80F094213B900C371A7 /* SkSVGParser.h */; };
-		FEEBB878094213B900C371A7 /* SkSVGTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB810094213B900C371A7 /* SkSVGTypes.h */; };
-		FEEBB879094213B900C371A7 /* SkSystemEventTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB811094213B900C371A7 /* SkSystemEventTypes.h */; };
-		FEEBB87A094213B900C371A7 /* SkTDArray.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB812094213B900C371A7 /* SkTDArray.h */; };
-		FEEBB87B094213B900C371A7 /* SkTDict.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB813094213B900C371A7 /* SkTDict.h */; };
-		FEEBB87C094213B900C371A7 /* SkTDStack.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB814094213B900C371A7 /* SkTDStack.h */; };
-		FEEBB87E094213B900C371A7 /* SkTextBox.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB816094213B900C371A7 /* SkTextBox.h */; };
-		FEEBB880094213B900C371A7 /* SkTime.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB818094213B900C371A7 /* SkTime.h */; };
-		FEEBB881094213B900C371A7 /* SkTransparentShader.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB819094213B900C371A7 /* SkTransparentShader.h */; };
-		FEEBB884094213B900C371A7 /* SkUnitMapper.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB81C094213B900C371A7 /* SkUnitMapper.h */; };
-		FEEBB885094213B900C371A7 /* SkUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB81D094213B900C371A7 /* SkUtils.h */; };
-		FEEBB886094213B900C371A7 /* SkView.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB81E094213B900C371A7 /* SkView.h */; };
-		FEEBB887094213B900C371A7 /* SkViewInflate.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB81F094213B900C371A7 /* SkViewInflate.h */; };
-		FEEBB888094213B900C371A7 /* SkWidget.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB820094213B900C371A7 /* SkWidget.h */; };
-		FEEBB889094213B900C371A7 /* SkWindow.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB821094213B900C371A7 /* SkWindow.h */; };
-		FEEBB88A094213B900C371A7 /* SkXfermode.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB822094213B900C371A7 /* SkXfermode.h */; };
-		FEEBB88B094213B900C371A7 /* SkXMLParser.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB823094213B900C371A7 /* SkXMLParser.h */; };
-		FEEBB88C094213B900C371A7 /* SkXMLWriter.h in Headers */ = {isa = PBXBuildFile; fileRef = FEEBB824094213B900C371A7 /* SkXMLWriter.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		00081FDC0A67CEF400A37923 /* SkRasterizer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkRasterizer.cpp; path = ../../libs/graphics/sgl/SkRasterizer.cpp; sourceTree = SOURCE_ROOT; };
-		00081FE00A67CF1800A37923 /* SkColorFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkColorFilter.h; sourceTree = "<group>"; };
-		00081FE10A67CF1800A37923 /* SkRasterizer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkRasterizer.h; sourceTree = "<group>"; };
-		00081FE30A67CF1800A37923 /* SkTypeface.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTypeface.h; sourceTree = "<group>"; };
-		000C28700AA50FFE005A479B /* SkColorFilters.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColorFilters.cpp; path = ../../libs/graphics/effects/SkColorFilters.cpp; sourceTree = SOURCE_ROOT; };
-		000C28710AA50FFE005A479B /* SkCullPoints.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkCullPoints.cpp; path = ../../libs/graphics/effects/SkCullPoints.cpp; sourceTree = SOURCE_ROOT; };
-		000C28780AA51077005A479B /* SkColorFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColorFilter.cpp; path = ../../libs/graphics/sgl/SkColorFilter.cpp; sourceTree = SOURCE_ROOT; };
-		001142D20DCA3EE90070D0A3 /* SkPicturePlayback.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPicturePlayback.cpp; path = ../../libs/graphics/picture/SkPicturePlayback.cpp; sourceTree = SOURCE_ROOT; };
-		001142D30DCA3EE90070D0A3 /* SkPicturePlayback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkPicturePlayback.h; path = ../../libs/graphics/picture/SkPicturePlayback.h; sourceTree = SOURCE_ROOT; };
-		001142D40DCA3EE90070D0A3 /* SkPictureRecord.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPictureRecord.cpp; path = ../../libs/graphics/picture/SkPictureRecord.cpp; sourceTree = SOURCE_ROOT; };
-		001142D50DCA3EE90070D0A3 /* SkPictureRecord.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkPictureRecord.h; path = ../../libs/graphics/picture/SkPictureRecord.h; sourceTree = SOURCE_ROOT; };
-		0011430A0DCA458A0070D0A3 /* SkPictureFlat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkPictureFlat.h; path = ../../libs/graphics/picture/SkPictureFlat.h; sourceTree = SOURCE_ROOT; };
-		0011430C0DCA45990070D0A3 /* SkPictureFlat.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPictureFlat.cpp; path = ../../libs/graphics/picture/SkPictureFlat.cpp; sourceTree = SOURCE_ROOT; };
-		0019627C0EACB91200447A07 /* SkPageFlipper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPageFlipper.cpp; path = ../../libs/corecg/SkPageFlipper.cpp; sourceTree = SOURCE_ROOT; };
-		0019627E0EACB92A00447A07 /* SkFlipPixelRef.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkFlipPixelRef.cpp; path = ../../libs/graphics/images/SkFlipPixelRef.cpp; sourceTree = SOURCE_ROOT; };
-		001962800EACB94400447A07 /* SkPathHeap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPathHeap.cpp; path = ../../libs/graphics/picture/SkPathHeap.cpp; sourceTree = SOURCE_ROOT; };
-		001FFBBC0CD8D9ED000CDF07 /* SkImageRef.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageRef.cpp; path = ../../libs/graphics/images/SkImageRef.cpp; sourceTree = SOURCE_ROOT; };
-		0027DCCF0B24CA3900076079 /* SkDevice.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDevice.cpp; path = ../../libs/graphics/sgl/SkDevice.cpp; sourceTree = SOURCE_ROOT; };
-		0027DCD10B24CA4E00076079 /* SkDevice.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDevice.h; sourceTree = "<group>"; };
-		002B774E0A1BB054003B067F /* SkShaderExtras.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkShaderExtras.cpp; path = ../../libs/graphics/effects/SkShaderExtras.cpp; sourceTree = SOURCE_ROOT; };
-		002B77500A1BB07A003B067F /* SkCornerPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkCornerPathEffect.h; sourceTree = "<group>"; };
-		002B77510A1BB07A003B067F /* SkDeque.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDeque.h; sourceTree = "<group>"; };
-		002B77520A1BB07A003B067F /* SkPaint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPaint.h; sourceTree = "<group>"; };
-		002B77530A1BB07A003B067F /* SkPorterDuff.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPorterDuff.h; sourceTree = "<group>"; };
-		002B77540A1BB07A003B067F /* SkShaderExtras.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkShaderExtras.h; sourceTree = "<group>"; };
-		002C8E6D0A0A515000FFB8EC /* SkDeque.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDeque.cpp; path = ../../libs/graphics/sgl/SkDeque.cpp; sourceTree = SOURCE_ROOT; };
-		003091F30C19BE04009F515A /* SkBitmapProcShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapProcShader.cpp; path = ../../libs/graphics/sgl/SkBitmapProcShader.cpp; sourceTree = SOURCE_ROOT; };
-		003091F40C19BE04009F515A /* SkBitmapProcShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapProcShader.h; path = ../../libs/graphics/sgl/SkBitmapProcShader.h; sourceTree = SOURCE_ROOT; };
-		003091F60C19BE04009F515A /* SkBitmapProcState_matrixProcs.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapProcState_matrixProcs.cpp; path = ../../libs/graphics/sgl/SkBitmapProcState_matrixProcs.cpp; sourceTree = SOURCE_ROOT; };
-		003091F80C19BE04009F515A /* SkBitmapProcState.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapProcState.cpp; path = ../../libs/graphics/sgl/SkBitmapProcState.cpp; sourceTree = SOURCE_ROOT; };
-		003091F90C19BE04009F515A /* SkBitmapProcState.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapProcState.h; path = ../../libs/graphics/sgl/SkBitmapProcState.h; sourceTree = SOURCE_ROOT; };
-		0035381F0C85BDCE007289C0 /* SkPixelXorXfermode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPixelXorXfermode.cpp; path = ../../libs/graphics/effects/SkPixelXorXfermode.cpp; sourceTree = SOURCE_ROOT; };
-		003538530C85BF0D007289C0 /* SkColorShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkColorShader.h; sourceTree = "<group>"; };
-		003538540C85BF0D007289C0 /* SkDrawFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDrawFilter.h; sourceTree = "<group>"; };
-		003538550C85BF0D007289C0 /* SkDrawLooper.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDrawLooper.h; sourceTree = "<group>"; };
-		003538560C85BF0D007289C0 /* SkKernel33MaskFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkKernel33MaskFilter.h; sourceTree = "<group>"; };
-		003538570C85BF0D007289C0 /* SkPackBits.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPackBits.h; sourceTree = "<group>"; };
-		003538580C85BF0D007289C0 /* SkPicture.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPicture.h; sourceTree = "<group>"; };
-		003E6EFC0D09EF84005435C0 /* SkColorMatrix.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColorMatrix.cpp; path = ../../libs/graphics/effects/SkColorMatrix.cpp; sourceTree = SOURCE_ROOT; };
-		003E6EFD0D09EF84005435C0 /* SkColorMatrixFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColorMatrixFilter.cpp; path = ../../libs/graphics/effects/SkColorMatrixFilter.cpp; sourceTree = SOURCE_ROOT; };
-		003FF1670DAE9C0F00601F6B /* SkImageRef_GlobalPool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageRef_GlobalPool.cpp; path = ../../libs/graphics/images/SkImageRef_GlobalPool.cpp; sourceTree = SOURCE_ROOT; };
-		0043B2D80D75C840004A0E2A /* SkScaledBitmapSampler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkScaledBitmapSampler.h; path = ../../libs/graphics/images/SkScaledBitmapSampler.h; sourceTree = SOURCE_ROOT; };
-		00523E840C7B335D00D53402 /* Sk1DPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = Sk1DPathEffect.cpp; path = ../../libs/graphics/effects/Sk1DPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		00523E850C7B335D00D53402 /* Sk2DPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = Sk2DPathEffect.cpp; path = ../../libs/graphics/effects/Sk2DPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		00523E860C7B335D00D53402 /* SkBlurMask.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlurMask.cpp; path = ../../libs/graphics/effects/SkBlurMask.cpp; sourceTree = SOURCE_ROOT; };
-		00523E870C7B335D00D53402 /* SkBlurMask.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBlurMask.h; path = ../../libs/graphics/effects/SkBlurMask.h; sourceTree = SOURCE_ROOT; };
-		00523E880C7B335D00D53402 /* SkBlurMaskFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlurMaskFilter.cpp; path = ../../libs/graphics/effects/SkBlurMaskFilter.cpp; sourceTree = SOURCE_ROOT; };
-		00523E890C7B335D00D53402 /* SkCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkCamera.cpp; path = ../../libs/graphics/effects/SkCamera.cpp; sourceTree = SOURCE_ROOT; };
-		00523E8A0C7B335D00D53402 /* SkDashPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDashPathEffect.cpp; path = ../../libs/graphics/effects/SkDashPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		00523E8B0C7B335D00D53402 /* SkDiscretePathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDiscretePathEffect.cpp; path = ../../libs/graphics/effects/SkDiscretePathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		00523E8C0C7B335D00D53402 /* SkEmbossMask_Table.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkEmbossMask_Table.h; path = ../../libs/graphics/effects/SkEmbossMask_Table.h; sourceTree = SOURCE_ROOT; };
-		00523E8D0C7B335D00D53402 /* SkEmbossMask.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkEmbossMask.cpp; path = ../../libs/graphics/effects/SkEmbossMask.cpp; sourceTree = SOURCE_ROOT; };
-		00523E8E0C7B335D00D53402 /* SkEmbossMask.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkEmbossMask.h; path = ../../libs/graphics/effects/SkEmbossMask.h; sourceTree = SOURCE_ROOT; };
-		00523E8F0C7B335D00D53402 /* SkEmbossMaskFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkEmbossMaskFilter.cpp; path = ../../libs/graphics/effects/SkEmbossMaskFilter.cpp; sourceTree = SOURCE_ROOT; };
-		00523E900C7B335D00D53402 /* SkGradientShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGradientShader.cpp; path = ../../libs/graphics/effects/SkGradientShader.cpp; sourceTree = SOURCE_ROOT; };
-		00523E920C7B335D00D53402 /* SkRadialGradient_Table.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRadialGradient_Table.h; path = ../../libs/graphics/effects/SkRadialGradient_Table.h; sourceTree = SOURCE_ROOT; };
-		00523E930C7B335D00D53402 /* SkTransparentShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTransparentShader.cpp; path = ../../libs/graphics/effects/SkTransparentShader.cpp; sourceTree = SOURCE_ROOT; };
-		00523E940C7B335D00D53402 /* SkUnitMappers.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkUnitMappers.cpp; path = ../../libs/graphics/effects/SkUnitMappers.cpp; sourceTree = SOURCE_ROOT; };
-		00523EA80C7B33B100D53402 /* SkUnitMappers.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkUnitMappers.h; sourceTree = "<group>"; };
-		00523F410C7B3C1400D53402 /* SkFlattenable.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFlattenable.cpp; path = ../../libs/graphics/sgl/SkFlattenable.cpp; sourceTree = SOURCE_ROOT; };
-		0053B0ED0D3557960016606F /* SkPaintFlagsDrawFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPaintFlagsDrawFilter.cpp; path = ../../libs/graphics/effects/SkPaintFlagsDrawFilter.cpp; sourceTree = SOURCE_ROOT; };
-		0053B0EF0D3557AD0016606F /* SkTypeface.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTypeface.cpp; path = ../../libs/graphics/sgl/SkTypeface.cpp; sourceTree = SOURCE_ROOT; };
-		006B542D0C42B355008E512D /* SkBlurDrawLooper.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlurDrawLooper.cpp; path = ../../libs/graphics/effects/SkBlurDrawLooper.cpp; sourceTree = SOURCE_ROOT; };
-		006B54380C42B3B0008E512D /* SkBlurDrawLooper.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBlurDrawLooper.h; sourceTree = "<group>"; };
-		006D3B5E0CE0CAE700CE1224 /* SkWriter32.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkWriter32.cpp; path = ../../libs/graphics/sgl/SkWriter32.cpp; sourceTree = SOURCE_ROOT; };
-		007336180DDC859F00A0DB2A /* SkPtrRecorder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPtrRecorder.cpp; path = ../../libs/graphics/sgl/SkPtrRecorder.cpp; sourceTree = SOURCE_ROOT; };
-		008180E60D92D57300A2E56D /* SkScaledBitmapSampler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkScaledBitmapSampler.cpp; path = ../../libs/graphics/images/SkScaledBitmapSampler.cpp; sourceTree = SOURCE_ROOT; };
-		0084BECA0A67EB6F003713D0 /* SkLayerRasterizer.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkLayerRasterizer.cpp; path = ../../libs/graphics/effects/SkLayerRasterizer.cpp; sourceTree = SOURCE_ROOT; };
-		0084BECC0A67EB98003713D0 /* SkLayerRasterizer.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkLayerRasterizer.h; sourceTree = "<group>"; };
-		008618720D46CC75007F0674 /* SkBlitRow_D4444.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitRow_D4444.cpp; path = ../../libs/graphics/sgl/SkBlitRow_D4444.cpp; sourceTree = SOURCE_ROOT; };
-		008618730D46CC75007F0674 /* SkBlitter_4444.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_4444.cpp; path = ../../libs/graphics/sgl/SkBlitter_4444.cpp; sourceTree = SOURCE_ROOT; };
-		009306CB0AD3F8520068227B /* SkCornerPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkCornerPathEffect.cpp; path = ../../libs/graphics/effects/SkCornerPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		009866470ACD95EF00B69A0B /* SkAvoidXfermode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAvoidXfermode.cpp; path = ../../libs/graphics/effects/SkAvoidXfermode.cpp; sourceTree = SOURCE_ROOT; };
-		009907F00D53A06200AD25AA /* SkBitmap_scroll.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmap_scroll.cpp; path = ../../libs/graphics/sgl/SkBitmap_scroll.cpp; sourceTree = SOURCE_ROOT; };
-		009A39620DAE52FA00EB3A73 /* SkImageRefPool.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageRefPool.cpp; path = ../../libs/graphics/images/SkImageRefPool.cpp; sourceTree = SOURCE_ROOT; };
-		009A75E60DA1DF5D00876C03 /* SkDrawProcs.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkDrawProcs.h; path = ../../libs/graphics/sgl/SkDrawProcs.h; sourceTree = SOURCE_ROOT; };
-		009A75E90DA1DF8400876C03 /* SkNinePatch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkNinePatch.cpp; path = ../../libs/graphics/effects/SkNinePatch.cpp; sourceTree = SOURCE_ROOT; };
-		009B1EAD0DD224CF00EDFFF4 /* SkPixelRef.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPixelRef.cpp; path = ../../libs/graphics/sgl/SkPixelRef.cpp; sourceTree = SOURCE_ROOT; };
-		00A159CC0C469A1200DB6CED /* SkBlitRow_D16.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitRow_D16.cpp; path = ../../libs/graphics/sgl/SkBlitRow_D16.cpp; sourceTree = SOURCE_ROOT; };
-		00A159CD0C469A1200DB6CED /* SkBlitRow.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBlitRow.h; path = ../../libs/graphics/sgl/SkBlitRow.h; sourceTree = SOURCE_ROOT; };
-		00A159CE0C469A1200DB6CED /* SkDither.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDither.cpp; path = ../../libs/graphics/sgl/SkDither.cpp; sourceTree = SOURCE_ROOT; };
-		00A218890B652EEC0056CB69 /* SkMask.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMask.cpp; path = ../../libs/graphics/sgl/SkMask.cpp; sourceTree = SOURCE_ROOT; };
-		00B4AC4E0E9BF59400A184BF /* SkPicture.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkPicture.cpp; path = ../../libs/graphics/picture/SkPicture.cpp; sourceTree = SOURCE_ROOT; };
-		00B5022C09DB127D00A01CD6 /* SkRegionPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkRegionPriv.h; path = ../../libs/corecg/SkRegionPriv.h; sourceTree = SOURCE_ROOT; };
-		00B8EC930EB6A319003C2F6F /* SkLayerDrawLooper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkLayerDrawLooper.cpp; path = ../../libs/graphics/effects/SkLayerDrawLooper.cpp; sourceTree = SOURCE_ROOT; };
-		00C88FEE0D89B7920015D427 /* SkUnPreMultiply.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkUnPreMultiply.cpp; path = ../../libs/graphics/sgl/SkUnPreMultiply.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC06F0554671400DB518D /* libgraphics.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libgraphics.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE20DF0B0C7F154F00AAC91E /* SkKernel33MaskFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkKernel33MaskFilter.cpp; path = ../../libs/graphics/effects/SkKernel33MaskFilter.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF160C7F157B00AAC91E /* SkMovie.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMovie.cpp; path = ../../libs/graphics/images/SkMovie.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF210C7F15D200AAC91E /* ARGB32_Clamp_Bilinear_BitmapShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = ARGB32_Clamp_Bilinear_BitmapShader.h; path = ../../libs/graphics/sgl/ARGB32_Clamp_Bilinear_BitmapShader.h; sourceTree = SOURCE_ROOT; };
-		FE20DF220C7F15D200AAC91E /* SkAlphaRuns.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkAlphaRuns.cpp; path = ../../libs/graphics/sgl/SkAlphaRuns.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF230C7F15D200AAC91E /* SkAntiRun.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAntiRun.h; path = ../../libs/graphics/sgl/SkAntiRun.h; sourceTree = SOURCE_ROOT; };
-		FE20DF240C7F15D200AAC91E /* SkAutoKern.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkAutoKern.h; path = ../../libs/graphics/sgl/SkAutoKern.h; sourceTree = SOURCE_ROOT; };
-		FE20DF250C7F15D200AAC91E /* SkBitmap.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmap.cpp; path = ../../libs/graphics/sgl/SkBitmap.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF260C7F15D200AAC91E /* SkBitmapProcState_matrix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapProcState_matrix.h; path = ../../libs/graphics/sgl/SkBitmapProcState_matrix.h; sourceTree = SOURCE_ROOT; };
-		FE20DF270C7F15D200AAC91E /* SkBitmapProcState_sample.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapProcState_sample.h; path = ../../libs/graphics/sgl/SkBitmapProcState_sample.h; sourceTree = SOURCE_ROOT; };
-		FE20DF280C7F15D200AAC91E /* SkBitmapSampler.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapSampler.cpp; path = ../../libs/graphics/sgl/SkBitmapSampler.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF290C7F15D200AAC91E /* SkBitmapSampler.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapSampler.h; path = ../../libs/graphics/sgl/SkBitmapSampler.h; sourceTree = SOURCE_ROOT; };
-		FE20DF2A0C7F15D200AAC91E /* SkBitmapSamplerTemplate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapSamplerTemplate.h; path = ../../libs/graphics/sgl/SkBitmapSamplerTemplate.h; sourceTree = SOURCE_ROOT; };
-		FE20DF2B0C7F15D200AAC91E /* SkBitmapShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmapShader.cpp; path = ../../libs/graphics/sgl/SkBitmapShader.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF2C0C7F15D200AAC91E /* SkBitmapShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapShader.h; path = ../../libs/graphics/sgl/SkBitmapShader.h; sourceTree = SOURCE_ROOT; };
-		FE20DF2D0C7F15D200AAC91E /* SkBitmapShader16BilerpTemplate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapShader16BilerpTemplate.h; path = ../../libs/graphics/sgl/SkBitmapShader16BilerpTemplate.h; sourceTree = SOURCE_ROOT; };
-		FE20DF2E0C7F15D200AAC91E /* SkBitmapShaderTemplate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBitmapShaderTemplate.h; path = ../../libs/graphics/sgl/SkBitmapShaderTemplate.h; sourceTree = SOURCE_ROOT; };
-		FE20DF2F0C7F15D200AAC91E /* SkBlitBWMaskTemplate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBlitBWMaskTemplate.h; path = ../../libs/graphics/sgl/SkBlitBWMaskTemplate.h; sourceTree = SOURCE_ROOT; };
-		FE20DF300C7F15D200AAC91E /* SkBlitter_A1.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_A1.cpp; path = ../../libs/graphics/sgl/SkBlitter_A1.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF310C7F15D200AAC91E /* SkBlitter_A8.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_A8.cpp; path = ../../libs/graphics/sgl/SkBlitter_A8.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF320C7F15D200AAC91E /* SkBlitter_ARGB32.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_ARGB32.cpp; path = ../../libs/graphics/sgl/SkBlitter_ARGB32.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF330C7F15D200AAC91E /* SkBlitter_RGB16.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_RGB16.cpp; path = ../../libs/graphics/sgl/SkBlitter_RGB16.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF340C7F15D200AAC91E /* SkBlitter_Sprite.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter_Sprite.cpp; path = ../../libs/graphics/sgl/SkBlitter_Sprite.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF350C7F15D200AAC91E /* SkBlitter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBlitter.cpp; path = ../../libs/graphics/sgl/SkBlitter.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF360C7F15D200AAC91E /* SkBlitter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBlitter.h; path = ../../libs/graphics/sgl/SkBlitter.h; sourceTree = SOURCE_ROOT; };
-		FE20DF370C7F15D200AAC91E /* SkCanvas.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkCanvas.cpp; path = ../../libs/graphics/sgl/SkCanvas.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF380C7F15D200AAC91E /* SkColor.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColor.cpp; path = ../../libs/graphics/sgl/SkColor.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF390C7F15D200AAC91E /* SkColorTable.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkColorTable.cpp; path = ../../libs/graphics/sgl/SkColorTable.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF3A0C7F15D200AAC91E /* SkCoreBlitters.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkCoreBlitters.h; path = ../../libs/graphics/sgl/SkCoreBlitters.h; sourceTree = SOURCE_ROOT; };
-		FE20DF3B0C7F15D200AAC91E /* SkDraw.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDraw.cpp; path = ../../libs/graphics/sgl/SkDraw.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF3C0C7F15D200AAC91E /* SkEdge.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkEdge.cpp; path = ../../libs/graphics/sgl/SkEdge.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF3D0C7F15D200AAC91E /* SkEdge.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkEdge.h; path = ../../libs/graphics/sgl/SkEdge.h; sourceTree = SOURCE_ROOT; };
-		FE20DF3E0C7F15D200AAC91E /* SkFilterProc.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFilterProc.cpp; path = ../../libs/graphics/sgl/SkFilterProc.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF3F0C7F15D200AAC91E /* SkFilterProc.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFilterProc.h; path = ../../libs/graphics/sgl/SkFilterProc.h; sourceTree = SOURCE_ROOT; };
-		FE20DF400C7F15D200AAC91E /* SkFP.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkFP.h; path = ../../libs/graphics/sgl/SkFP.h; sourceTree = SOURCE_ROOT; };
-		FE20DF410C7F15D200AAC91E /* SkGeometry.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGeometry.cpp; path = ../../libs/graphics/sgl/SkGeometry.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF420C7F15D200AAC91E /* SkGeometry.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkGeometry.h; path = ../../libs/graphics/sgl/SkGeometry.h; sourceTree = SOURCE_ROOT; };
-		FE20DF430C7F15D200AAC91E /* SkGlobals.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGlobals.cpp; path = ../../libs/graphics/sgl/SkGlobals.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF440C7F15D200AAC91E /* SkGlyphCache.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGlyphCache.cpp; path = ../../libs/graphics/sgl/SkGlyphCache.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF450C7F15D200AAC91E /* SkGlyphCache.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkGlyphCache.h; path = ../../libs/graphics/sgl/SkGlyphCache.h; sourceTree = SOURCE_ROOT; };
-		FE20DF460C7F15D200AAC91E /* SkGraphics.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGraphics.cpp; path = ../../libs/graphics/sgl/SkGraphics.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF470C7F15D200AAC91E /* SkMaskFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMaskFilter.cpp; path = ../../libs/graphics/sgl/SkMaskFilter.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF480C7F15D200AAC91E /* SkPackBits.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPackBits.cpp; path = ../../libs/graphics/sgl/SkPackBits.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF490C7F15D200AAC91E /* SkPaint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPaint.cpp; path = ../../libs/graphics/sgl/SkPaint.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4A0C7F15D200AAC91E /* SkPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPath.cpp; path = ../../libs/graphics/sgl/SkPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4B0C7F15D200AAC91E /* SkPathEffect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPathEffect.cpp; path = ../../libs/graphics/sgl/SkPathEffect.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4C0C7F15D200AAC91E /* SkPathMeasure.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkPathMeasure.cpp; path = ../../libs/graphics/sgl/SkPathMeasure.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4D0C7F15D200AAC91E /* SkProcSpriteBlitter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkProcSpriteBlitter.cpp; path = ../../libs/graphics/sgl/SkProcSpriteBlitter.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4E0C7F15D200AAC91E /* SkRefCnt.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkRefCnt.cpp; path = ../../libs/graphics/sgl/SkRefCnt.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF4F0C7F15D200AAC91E /* SkRegion_path.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkRegion_path.cpp; path = ../../libs/graphics/sgl/SkRegion_path.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF500C7F15D200AAC91E /* SkScalerContext.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScalerContext.cpp; path = ../../libs/graphics/sgl/SkScalerContext.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF510C7F15D200AAC91E /* SkScan_Antihair.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScan_Antihair.cpp; path = ../../libs/graphics/sgl/SkScan_Antihair.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF520C7F15D200AAC91E /* SkScan_AntiPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScan_AntiPath.cpp; path = ../../libs/graphics/sgl/SkScan_AntiPath.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF530C7F15D200AAC91E /* SkScan_Hairline.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScan_Hairline.cpp; path = ../../libs/graphics/sgl/SkScan_Hairline.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF540C7F15D200AAC91E /* SkScan_Path.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScan_Path.cpp; path = ../../libs/graphics/sgl/SkScan_Path.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF550C7F15D200AAC91E /* SkScan.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScan.cpp; path = ../../libs/graphics/sgl/SkScan.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF560C7F15D200AAC91E /* SkScan.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScan.h; path = ../../libs/graphics/sgl/SkScan.h; sourceTree = SOURCE_ROOT; };
-		FE20DF570C7F15D200AAC91E /* SkScanPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkScanPriv.h; path = ../../libs/graphics/sgl/SkScanPriv.h; sourceTree = SOURCE_ROOT; };
-		FE20DF580C7F15D200AAC91E /* SkShader.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkShader.cpp; path = ../../libs/graphics/sgl/SkShader.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF590C7F15D200AAC91E /* SkSpriteBlitter_ARGB32.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkSpriteBlitter_ARGB32.cpp; path = ../../libs/graphics/sgl/SkSpriteBlitter_ARGB32.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF5A0C7F15D200AAC91E /* SkSpriteBlitter_RGB16.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkSpriteBlitter_RGB16.cpp; path = ../../libs/graphics/sgl/SkSpriteBlitter_RGB16.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF5B0C7F15D200AAC91E /* SkSpriteBlitter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkSpriteBlitter.h; path = ../../libs/graphics/sgl/SkSpriteBlitter.h; sourceTree = SOURCE_ROOT; };
-		FE20DF5C0C7F15D200AAC91E /* SkSpriteBlitterTemplate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkSpriteBlitterTemplate.h; path = ../../libs/graphics/sgl/SkSpriteBlitterTemplate.h; sourceTree = SOURCE_ROOT; };
-		FE20DF5D0C7F15D200AAC91E /* SkString.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkString.cpp; path = ../../libs/graphics/sgl/SkString.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF5E0C7F15D200AAC91E /* SkStroke.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkStroke.cpp; path = ../../libs/graphics/sgl/SkStroke.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF5F0C7F15D200AAC91E /* SkStrokerPriv.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkStrokerPriv.cpp; path = ../../libs/graphics/sgl/SkStrokerPriv.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF600C7F15D200AAC91E /* SkStrokerPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkStrokerPriv.h; path = ../../libs/graphics/sgl/SkStrokerPriv.h; sourceTree = SOURCE_ROOT; };
-		FE20DF610C7F15D200AAC91E /* SkTemplatesPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTemplatesPriv.h; path = ../../libs/graphics/sgl/SkTemplatesPriv.h; sourceTree = SOURCE_ROOT; };
-		FE20DF620C7F15D200AAC91E /* SkTSearch.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTSearch.cpp; path = ../../libs/graphics/sgl/SkTSearch.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF630C7F15D200AAC91E /* SkTSort.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTSort.h; path = ../../libs/graphics/sgl/SkTSort.h; sourceTree = SOURCE_ROOT; };
-		FE20DF640C7F15D200AAC91E /* SkUtils.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkUtils.cpp; path = ../../libs/graphics/sgl/SkUtils.cpp; sourceTree = SOURCE_ROOT; };
-		FE20DF650C7F15D200AAC91E /* SkXfermode.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXfermode.cpp; path = ../../libs/graphics/sgl/SkXfermode.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F486B094788030095980F /* SkImageDecoder.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder.cpp; path = ../../libs/graphics/images/SkImageDecoder.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F486C094788030095980F /* SkStream.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkStream.cpp; path = ../../libs/graphics/images/SkStream.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48B3094797D00095980F /* SkBML_Verbs.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkBML_Verbs.h; path = ../../libs/graphics/xml/SkBML_Verbs.h; sourceTree = SOURCE_ROOT; };
-		FE5F48B4094797D00095980F /* SkBML_XMLParser.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBML_XMLParser.cpp; path = ../../libs/graphics/xml/SkBML_XMLParser.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48B5094797D00095980F /* SkDOM.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDOM.cpp; path = ../../libs/graphics/xml/SkDOM.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48B8094797D00095980F /* SkParse.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkParse.cpp; path = ../../libs/graphics/xml/SkParse.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48B9094797D00095980F /* SkParseColor.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkParseColor.cpp; path = ../../libs/graphics/xml/SkParseColor.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48BA094797D00095980F /* SkXMLParser.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLParser.cpp; path = ../../libs/graphics/xml/SkXMLParser.cpp; sourceTree = SOURCE_ROOT; };
-		FE5F48BB094797D00095980F /* SkXMLWriter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkXMLWriter.cpp; path = ../../libs/graphics/xml/SkXMLWriter.cpp; sourceTree = SOURCE_ROOT; };
-		FEDCE31709C9CEC70042D964 /* SkDebug.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDebug.cpp; path = ../../libs/corecg/SkDebug.cpp; sourceTree = SOURCE_ROOT; };
-		FEEBB7BE094213B900C371A7 /* Sk1DPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Sk1DPathEffect.h; sourceTree = "<group>"; };
-		FEEBB7BF094213B900C371A7 /* Sk2DPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Sk2DPathEffect.h; sourceTree = "<group>"; };
-		FEEBB7C1094213B900C371A7 /* SkAnimator.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkAnimator.h; sourceTree = "<group>"; };
-		FEEBB7C2094213B900C371A7 /* SkAnimatorView.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkAnimatorView.h; sourceTree = "<group>"; };
-		FEEBB7C3094213B900C371A7 /* SkBGViewArtist.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBGViewArtist.h; sourceTree = "<group>"; };
-		FEEBB7C4094213B900C371A7 /* SkBitmap.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBitmap.h; sourceTree = "<group>"; };
-		FEEBB7C6094213B900C371A7 /* SkBlurMaskFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBlurMaskFilter.h; sourceTree = "<group>"; };
-		FEEBB7C7094213B900C371A7 /* SkBML_WXMLParser.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBML_WXMLParser.h; sourceTree = "<group>"; };
-		FEEBB7C8094213B900C371A7 /* SkBML_XMLParser.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBML_XMLParser.h; sourceTree = "<group>"; };
-		FEEBB7C9094213B900C371A7 /* SkBounder.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkBounder.h; sourceTree = "<group>"; };
-		FEEBB7CB094213B900C371A7 /* SkCamera.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkCamera.h; sourceTree = "<group>"; };
-		FEEBB7CC094213B900C371A7 /* SkCanvas.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkCanvas.h; sourceTree = "<group>"; };
-		FEEBB7CD094213B900C371A7 /* SkColor.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkColor.h; sourceTree = "<group>"; };
-		FEEBB7CE094213B900C371A7 /* SkColorPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkColorPriv.h; sourceTree = "<group>"; };
-		FEEBB7CF094213B900C371A7 /* SkDashPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDashPathEffect.h; sourceTree = "<group>"; };
-		FEEBB7D0094213B900C371A7 /* SkDescriptor.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDescriptor.h; sourceTree = "<group>"; };
-		FEEBB7D1094213B900C371A7 /* SkDiscretePathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDiscretePathEffect.h; sourceTree = "<group>"; };
-		FEEBB7D2094213B900C371A7 /* SkDOM.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkDOM.h; sourceTree = "<group>"; };
-		FEEBB7D3094213B900C371A7 /* SkEmbossMaskFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkEmbossMaskFilter.h; sourceTree = "<group>"; };
-		FEEBB7D5094213B900C371A7 /* SkEvent.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkEvent.h; sourceTree = "<group>"; };
-		FEEBB7D6094213B900C371A7 /* SkEventSink.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkEventSink.h; sourceTree = "<group>"; };
-		FEEBB7D9094213B900C371A7 /* SkFlattenable.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkFlattenable.h; sourceTree = "<group>"; };
-		FEEBB7DB094213B900C371A7 /* SkFontCodec.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkFontCodec.h; sourceTree = "<group>"; };
-		FEEBB7DC094213B900C371A7 /* SkFontHost.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkFontHost.h; sourceTree = "<group>"; };
-		FEEBB7DE094213B900C371A7 /* SkGlobals.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkGlobals.h; sourceTree = "<group>"; };
-		FEEBB7DF094213B900C371A7 /* SkGradientShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkGradientShader.h; sourceTree = "<group>"; };
-		FEEBB7E0094213B900C371A7 /* SkGraphics.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkGraphics.h; sourceTree = "<group>"; };
-		FEEBB7E1094213B900C371A7 /* SkImageDecoder.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkImageDecoder.h; sourceTree = "<group>"; };
-		FEEBB7E4094213B900C371A7 /* SkJS.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkJS.h; sourceTree = "<group>"; };
-		FEEBB7E5094213B900C371A7 /* SkKey.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkKey.h; sourceTree = "<group>"; };
-		FEEBB7E8094213B900C371A7 /* SkMask.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkMask.h; sourceTree = "<group>"; };
-		FEEBB7E9094213B900C371A7 /* SkMaskFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkMaskFilter.h; sourceTree = "<group>"; };
-		FEEBB7EC094213B900C371A7 /* SkMetaData.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkMetaData.h; sourceTree = "<group>"; };
-		FEEBB7ED094213B900C371A7 /* SkOSFile.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSFile.h; sourceTree = "<group>"; };
-		FEEBB7EE094213B900C371A7 /* SkOSMenu.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSMenu.h; sourceTree = "<group>"; };
-		FEEBB7EF094213B900C371A7 /* SkOSSound.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSSound.h; sourceTree = "<group>"; };
-		FEEBB7F0094213B900C371A7 /* SkOSWindow_Mac.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSWindow_Mac.h; sourceTree = "<group>"; };
-		FEEBB7F1094213B900C371A7 /* SkOSWindow_Unix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSWindow_Unix.h; sourceTree = "<group>"; };
-		FEEBB7F2094213B900C371A7 /* SkOSWindow_Win.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkOSWindow_Win.h; sourceTree = "<group>"; };
-		FEEBB7F4094213B900C371A7 /* SkParse.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkParse.h; sourceTree = "<group>"; };
-		FEEBB7F5094213B900C371A7 /* SkParsePaint.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkParsePaint.h; sourceTree = "<group>"; };
-		FEEBB7F6094213B900C371A7 /* SkPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPath.h; sourceTree = "<group>"; };
-		FEEBB7F7094213B900C371A7 /* SkPathEffect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPathEffect.h; sourceTree = "<group>"; };
-		FEEBB7F8094213B900C371A7 /* SkPathMeasure.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkPathMeasure.h; sourceTree = "<group>"; };
-		FEEBB801094213B900C371A7 /* SkRefCnt.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkRefCnt.h; sourceTree = "<group>"; };
-		FEEBB804094213B900C371A7 /* SkScalerContext.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkScalerContext.h; sourceTree = "<group>"; };
-		FEEBB805094213B900C371A7 /* SkShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkShader.h; sourceTree = "<group>"; };
-		FEEBB806094213B900C371A7 /* SkStackViewLayout.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkStackViewLayout.h; sourceTree = "<group>"; };
-		FEEBB808094213B900C371A7 /* SkStream.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkStream.h; sourceTree = "<group>"; };
-		FEEBB809094213B900C371A7 /* SkStream_Win.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkStream_Win.h; sourceTree = "<group>"; };
-		FEEBB80A094213B900C371A7 /* SkString.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkString.h; sourceTree = "<group>"; };
-		FEEBB80B094213B900C371A7 /* SkStroke.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkStroke.h; sourceTree = "<group>"; };
-		FEEBB80C094213B900C371A7 /* SkSVGAttribute.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGAttribute.h; sourceTree = "<group>"; };
-		FEEBB80D094213B900C371A7 /* SkSVGBase.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGBase.h; sourceTree = "<group>"; };
-		FEEBB80E094213B900C371A7 /* SkSVGPaintState.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGPaintState.h; sourceTree = "<group>"; };
-		FEEBB80F094213B900C371A7 /* SkSVGParser.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGParser.h; sourceTree = "<group>"; };
-		FEEBB810094213B900C371A7 /* SkSVGTypes.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGTypes.h; sourceTree = "<group>"; };
-		FEEBB811094213B900C371A7 /* SkSystemEventTypes.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSystemEventTypes.h; sourceTree = "<group>"; };
-		FEEBB812094213B900C371A7 /* SkTDArray.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTDArray.h; sourceTree = "<group>"; };
-		FEEBB813094213B900C371A7 /* SkTDict.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTDict.h; sourceTree = "<group>"; };
-		FEEBB814094213B900C371A7 /* SkTDStack.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTDStack.h; sourceTree = "<group>"; };
-		FEEBB816094213B900C371A7 /* SkTextBox.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTextBox.h; sourceTree = "<group>"; };
-		FEEBB818094213B900C371A7 /* SkTime.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTime.h; sourceTree = "<group>"; };
-		FEEBB819094213B900C371A7 /* SkTransparentShader.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkTransparentShader.h; sourceTree = "<group>"; };
-		FEEBB81C094213B900C371A7 /* SkUnitMapper.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkUnitMapper.h; sourceTree = "<group>"; };
-		FEEBB81D094213B900C371A7 /* SkUtils.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkUtils.h; sourceTree = "<group>"; };
-		FEEBB81E094213B900C371A7 /* SkView.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkView.h; sourceTree = "<group>"; };
-		FEEBB81F094213B900C371A7 /* SkViewInflate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkViewInflate.h; sourceTree = "<group>"; };
-		FEEBB820094213B900C371A7 /* SkWidget.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkWidget.h; sourceTree = "<group>"; };
-		FEEBB821094213B900C371A7 /* SkWindow.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkWindow.h; sourceTree = "<group>"; };
-		FEEBB822094213B900C371A7 /* SkXfermode.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkXfermode.h; sourceTree = "<group>"; };
-		FEEBB823094213B900C371A7 /* SkXMLParser.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkXMLParser.h; sourceTree = "<group>"; };
-		FEEBB824094213B900C371A7 /* SkXMLWriter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkXMLWriter.h; sourceTree = "<group>"; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D2AAC06D0554671400DB518D /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		001142D10DCA3ED10070D0A3 /* picture */ = {
-			isa = PBXGroup;
-			children = (
-				001962800EACB94400447A07 /* SkPathHeap.cpp */,
-				00B4AC4E0E9BF59400A184BF /* SkPicture.cpp */,
-				001142D20DCA3EE90070D0A3 /* SkPicturePlayback.cpp */,
-				001142D30DCA3EE90070D0A3 /* SkPicturePlayback.h */,
-				001142D40DCA3EE90070D0A3 /* SkPictureRecord.cpp */,
-				001142D50DCA3EE90070D0A3 /* SkPictureRecord.h */,
-				0011430A0DCA458A0070D0A3 /* SkPictureFlat.h */,
-				0011430C0DCA45990070D0A3 /* SkPictureFlat.cpp */,
-			);
-			name = picture;
-			sourceTree = "<group>";
-		};
-		034768DDFF38A45A11DB9C8B /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC06F0554671400DB518D /* libgraphics.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		0867D691FE84028FC02AAC07 /* graphics */ = {
-			isa = PBXGroup;
-			children = (
-				001142D10DCA3ED10070D0A3 /* picture */,
-				FE5F48C8094798660095980F /* effects */,
-				FE5F48C5094797E90095980F /* images */,
-				FE5F48B2094797A80095980F /* xml */,
-				FEEBB7BA094213B900C371A7 /* include */,
-				08FB77ACFE841707C02AAC07 /* Source */,
-				034768DDFF38A45A11DB9C8B /* Products */,
-			);
-			name = graphics;
-			sourceTree = "<group>";
-		};
-		08FB77ACFE841707C02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				007336180DDC859F00A0DB2A /* SkPtrRecorder.cpp */,
-				009B1EAD0DD224CF00EDFFF4 /* SkPixelRef.cpp */,
-				009A75E60DA1DF5D00876C03 /* SkDrawProcs.h */,
-				00C88FEE0D89B7920015D427 /* SkUnPreMultiply.cpp */,
-				009907F00D53A06200AD25AA /* SkBitmap_scroll.cpp */,
-				008618720D46CC75007F0674 /* SkBlitRow_D4444.cpp */,
-				008618730D46CC75007F0674 /* SkBlitter_4444.cpp */,
-				0053B0EF0D3557AD0016606F /* SkTypeface.cpp */,
-				006D3B5E0CE0CAE700CE1224 /* SkWriter32.cpp */,
-				FE20DF210C7F15D200AAC91E /* ARGB32_Clamp_Bilinear_BitmapShader.h */,
-				FE20DF220C7F15D200AAC91E /* SkAlphaRuns.cpp */,
-				FE20DF230C7F15D200AAC91E /* SkAntiRun.h */,
-				FE20DF240C7F15D200AAC91E /* SkAutoKern.h */,
-				FE20DF250C7F15D200AAC91E /* SkBitmap.cpp */,
-				FE20DF260C7F15D200AAC91E /* SkBitmapProcState_matrix.h */,
-				FE20DF270C7F15D200AAC91E /* SkBitmapProcState_sample.h */,
-				FE20DF280C7F15D200AAC91E /* SkBitmapSampler.cpp */,
-				FE20DF290C7F15D200AAC91E /* SkBitmapSampler.h */,
-				FE20DF2A0C7F15D200AAC91E /* SkBitmapSamplerTemplate.h */,
-				FE20DF2B0C7F15D200AAC91E /* SkBitmapShader.cpp */,
-				FE20DF2C0C7F15D200AAC91E /* SkBitmapShader.h */,
-				FE20DF2D0C7F15D200AAC91E /* SkBitmapShader16BilerpTemplate.h */,
-				FE20DF2E0C7F15D200AAC91E /* SkBitmapShaderTemplate.h */,
-				FE20DF2F0C7F15D200AAC91E /* SkBlitBWMaskTemplate.h */,
-				FE20DF300C7F15D200AAC91E /* SkBlitter_A1.cpp */,
-				FE20DF310C7F15D200AAC91E /* SkBlitter_A8.cpp */,
-				FE20DF320C7F15D200AAC91E /* SkBlitter_ARGB32.cpp */,
-				FE20DF330C7F15D200AAC91E /* SkBlitter_RGB16.cpp */,
-				FE20DF340C7F15D200AAC91E /* SkBlitter_Sprite.cpp */,
-				FE20DF350C7F15D200AAC91E /* SkBlitter.cpp */,
-				FE20DF360C7F15D200AAC91E /* SkBlitter.h */,
-				FE20DF370C7F15D200AAC91E /* SkCanvas.cpp */,
-				FE20DF380C7F15D200AAC91E /* SkColor.cpp */,
-				FE20DF390C7F15D200AAC91E /* SkColorTable.cpp */,
-				FE20DF3A0C7F15D200AAC91E /* SkCoreBlitters.h */,
-				FE20DF3B0C7F15D200AAC91E /* SkDraw.cpp */,
-				FE20DF3C0C7F15D200AAC91E /* SkEdge.cpp */,
-				FE20DF3D0C7F15D200AAC91E /* SkEdge.h */,
-				FE20DF3E0C7F15D200AAC91E /* SkFilterProc.cpp */,
-				FE20DF3F0C7F15D200AAC91E /* SkFilterProc.h */,
-				FE20DF400C7F15D200AAC91E /* SkFP.h */,
-				FE20DF410C7F15D200AAC91E /* SkGeometry.cpp */,
-				FE20DF420C7F15D200AAC91E /* SkGeometry.h */,
-				FE20DF430C7F15D200AAC91E /* SkGlobals.cpp */,
-				FE20DF440C7F15D200AAC91E /* SkGlyphCache.cpp */,
-				FE20DF450C7F15D200AAC91E /* SkGlyphCache.h */,
-				FE20DF460C7F15D200AAC91E /* SkGraphics.cpp */,
-				FE20DF470C7F15D200AAC91E /* SkMaskFilter.cpp */,
-				FE20DF480C7F15D200AAC91E /* SkPackBits.cpp */,
-				FE20DF490C7F15D200AAC91E /* SkPaint.cpp */,
-				FE20DF4A0C7F15D200AAC91E /* SkPath.cpp */,
-				FE20DF4B0C7F15D200AAC91E /* SkPathEffect.cpp */,
-				FE20DF4C0C7F15D200AAC91E /* SkPathMeasure.cpp */,
-				FE20DF4D0C7F15D200AAC91E /* SkProcSpriteBlitter.cpp */,
-				FE20DF4E0C7F15D200AAC91E /* SkRefCnt.cpp */,
-				FE20DF4F0C7F15D200AAC91E /* SkRegion_path.cpp */,
-				FE20DF500C7F15D200AAC91E /* SkScalerContext.cpp */,
-				FE20DF510C7F15D200AAC91E /* SkScan_Antihair.cpp */,
-				FE20DF520C7F15D200AAC91E /* SkScan_AntiPath.cpp */,
-				FE20DF530C7F15D200AAC91E /* SkScan_Hairline.cpp */,
-				FE20DF540C7F15D200AAC91E /* SkScan_Path.cpp */,
-				FE20DF550C7F15D200AAC91E /* SkScan.cpp */,
-				FE20DF560C7F15D200AAC91E /* SkScan.h */,
-				FE20DF570C7F15D200AAC91E /* SkScanPriv.h */,
-				FE20DF580C7F15D200AAC91E /* SkShader.cpp */,
-				FE20DF590C7F15D200AAC91E /* SkSpriteBlitter_ARGB32.cpp */,
-				FE20DF5A0C7F15D200AAC91E /* SkSpriteBlitter_RGB16.cpp */,
-				FE20DF5B0C7F15D200AAC91E /* SkSpriteBlitter.h */,
-				FE20DF5C0C7F15D200AAC91E /* SkSpriteBlitterTemplate.h */,
-				FE20DF5D0C7F15D200AAC91E /* SkString.cpp */,
-				FE20DF5E0C7F15D200AAC91E /* SkStroke.cpp */,
-				FE20DF5F0C7F15D200AAC91E /* SkStrokerPriv.cpp */,
-				FE20DF600C7F15D200AAC91E /* SkStrokerPriv.h */,
-				FE20DF610C7F15D200AAC91E /* SkTemplatesPriv.h */,
-				FE20DF620C7F15D200AAC91E /* SkTSearch.cpp */,
-				FE20DF630C7F15D200AAC91E /* SkTSort.h */,
-				FE20DF640C7F15D200AAC91E /* SkUtils.cpp */,
-				FE20DF650C7F15D200AAC91E /* SkXfermode.cpp */,
-				FE20DF160C7F157B00AAC91E /* SkMovie.cpp */,
-				FE20DF0B0C7F154F00AAC91E /* SkKernel33MaskFilter.cpp */,
-				00523F410C7B3C1400D53402 /* SkFlattenable.cpp */,
-				00A159CC0C469A1200DB6CED /* SkBlitRow_D16.cpp */,
-				00A159CD0C469A1200DB6CED /* SkBlitRow.h */,
-				00A159CE0C469A1200DB6CED /* SkDither.cpp */,
-				003091F30C19BE04009F515A /* SkBitmapProcShader.cpp */,
-				003091F40C19BE04009F515A /* SkBitmapProcShader.h */,
-				003091F60C19BE04009F515A /* SkBitmapProcState_matrixProcs.cpp */,
-				003091F80C19BE04009F515A /* SkBitmapProcState.cpp */,
-				003091F90C19BE04009F515A /* SkBitmapProcState.h */,
-				00A218890B652EEC0056CB69 /* SkMask.cpp */,
-				0027DCCF0B24CA3900076079 /* SkDevice.cpp */,
-				000C28780AA51077005A479B /* SkColorFilter.cpp */,
-				00081FDC0A67CEF400A37923 /* SkRasterizer.cpp */,
-				002C8E6D0A0A515000FFB8EC /* SkDeque.cpp */,
-				FEDCE31709C9CEC70042D964 /* SkDebug.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		FE5F48B2094797A80095980F /* xml */ = {
-			isa = PBXGroup;
-			children = (
-				FE5F48B3094797D00095980F /* SkBML_Verbs.h */,
-				FE5F48B4094797D00095980F /* SkBML_XMLParser.cpp */,
-				FE5F48B5094797D00095980F /* SkDOM.cpp */,
-				FE5F48B8094797D00095980F /* SkParse.cpp */,
-				FE5F48B9094797D00095980F /* SkParseColor.cpp */,
-				FE5F48BA094797D00095980F /* SkXMLParser.cpp */,
-				FE5F48BB094797D00095980F /* SkXMLWriter.cpp */,
-			);
-			name = xml;
-			sourceTree = "<group>";
-		};
-		FE5F48C5094797E90095980F /* images */ = {
-			isa = PBXGroup;
-			children = (
-				0019627E0EACB92A00447A07 /* SkFlipPixelRef.cpp */,
-				0019627C0EACB91200447A07 /* SkPageFlipper.cpp */,
-				003FF1670DAE9C0F00601F6B /* SkImageRef_GlobalPool.cpp */,
-				009A39620DAE52FA00EB3A73 /* SkImageRefPool.cpp */,
-				008180E60D92D57300A2E56D /* SkScaledBitmapSampler.cpp */,
-				0043B2D80D75C840004A0E2A /* SkScaledBitmapSampler.h */,
-				001FFBBC0CD8D9ED000CDF07 /* SkImageRef.cpp */,
-				FE5F486B094788030095980F /* SkImageDecoder.cpp */,
-				FE5F486C094788030095980F /* SkStream.cpp */,
-			);
-			name = images;
-			sourceTree = "<group>";
-		};
-		FE5F48C8094798660095980F /* effects */ = {
-			isa = PBXGroup;
-			children = (
-				00B8EC930EB6A319003C2F6F /* SkLayerDrawLooper.cpp */,
-				009A75E90DA1DF8400876C03 /* SkNinePatch.cpp */,
-				0053B0ED0D3557960016606F /* SkPaintFlagsDrawFilter.cpp */,
-				003E6EFC0D09EF84005435C0 /* SkColorMatrix.cpp */,
-				003E6EFD0D09EF84005435C0 /* SkColorMatrixFilter.cpp */,
-				0035381F0C85BDCE007289C0 /* SkPixelXorXfermode.cpp */,
-				00523E840C7B335D00D53402 /* Sk1DPathEffect.cpp */,
-				00523E850C7B335D00D53402 /* Sk2DPathEffect.cpp */,
-				00523E860C7B335D00D53402 /* SkBlurMask.cpp */,
-				00523E870C7B335D00D53402 /* SkBlurMask.h */,
-				00523E880C7B335D00D53402 /* SkBlurMaskFilter.cpp */,
-				00523E890C7B335D00D53402 /* SkCamera.cpp */,
-				00523E8A0C7B335D00D53402 /* SkDashPathEffect.cpp */,
-				00523E8B0C7B335D00D53402 /* SkDiscretePathEffect.cpp */,
-				00523E8C0C7B335D00D53402 /* SkEmbossMask_Table.h */,
-				00523E8D0C7B335D00D53402 /* SkEmbossMask.cpp */,
-				00523E8E0C7B335D00D53402 /* SkEmbossMask.h */,
-				00523E8F0C7B335D00D53402 /* SkEmbossMaskFilter.cpp */,
-				00523E900C7B335D00D53402 /* SkGradientShader.cpp */,
-				00523E920C7B335D00D53402 /* SkRadialGradient_Table.h */,
-				00523E930C7B335D00D53402 /* SkTransparentShader.cpp */,
-				00523E940C7B335D00D53402 /* SkUnitMappers.cpp */,
-				009306CB0AD3F8520068227B /* SkCornerPathEffect.cpp */,
-				009866470ACD95EF00B69A0B /* SkAvoidXfermode.cpp */,
-				000C28700AA50FFE005A479B /* SkColorFilters.cpp */,
-				000C28710AA50FFE005A479B /* SkCullPoints.cpp */,
-				0084BECA0A67EB6F003713D0 /* SkLayerRasterizer.cpp */,
-				002B774E0A1BB054003B067F /* SkShaderExtras.cpp */,
-				006B542D0C42B355008E512D /* SkBlurDrawLooper.cpp */,
-			);
-			name = effects;
-			sourceTree = "<group>";
-		};
-		FEEBB7BA094213B900C371A7 /* include */ = {
-			isa = PBXGroup;
-			children = (
-				003538530C85BF0D007289C0 /* SkColorShader.h */,
-				003538540C85BF0D007289C0 /* SkDrawFilter.h */,
-				003538550C85BF0D007289C0 /* SkDrawLooper.h */,
-				003538560C85BF0D007289C0 /* SkKernel33MaskFilter.h */,
-				003538570C85BF0D007289C0 /* SkPackBits.h */,
-				003538580C85BF0D007289C0 /* SkPicture.h */,
-				00523EA80C7B33B100D53402 /* SkUnitMappers.h */,
-				006B54380C42B3B0008E512D /* SkBlurDrawLooper.h */,
-				0027DCD10B24CA4E00076079 /* SkDevice.h */,
-				0084BECC0A67EB98003713D0 /* SkLayerRasterizer.h */,
-				00081FE00A67CF1800A37923 /* SkColorFilter.h */,
-				00081FE10A67CF1800A37923 /* SkRasterizer.h */,
-				00081FE30A67CF1800A37923 /* SkTypeface.h */,
-				002B77500A1BB07A003B067F /* SkCornerPathEffect.h */,
-				002B77510A1BB07A003B067F /* SkDeque.h */,
-				002B77520A1BB07A003B067F /* SkPaint.h */,
-				002B77530A1BB07A003B067F /* SkPorterDuff.h */,
-				002B77540A1BB07A003B067F /* SkShaderExtras.h */,
-				00B5022C09DB127D00A01CD6 /* SkRegionPriv.h */,
-				FEEBB7BE094213B900C371A7 /* Sk1DPathEffect.h */,
-				FEEBB7BF094213B900C371A7 /* Sk2DPathEffect.h */,
-				FEEBB7C1094213B900C371A7 /* SkAnimator.h */,
-				FEEBB7C2094213B900C371A7 /* SkAnimatorView.h */,
-				FEEBB7C3094213B900C371A7 /* SkBGViewArtist.h */,
-				FEEBB7C4094213B900C371A7 /* SkBitmap.h */,
-				FEEBB7C6094213B900C371A7 /* SkBlurMaskFilter.h */,
-				FEEBB7C7094213B900C371A7 /* SkBML_WXMLParser.h */,
-				FEEBB7C8094213B900C371A7 /* SkBML_XMLParser.h */,
-				FEEBB7C9094213B900C371A7 /* SkBounder.h */,
-				FEEBB7CB094213B900C371A7 /* SkCamera.h */,
-				FEEBB7CC094213B900C371A7 /* SkCanvas.h */,
-				FEEBB7CD094213B900C371A7 /* SkColor.h */,
-				FEEBB7CE094213B900C371A7 /* SkColorPriv.h */,
-				FEEBB7CF094213B900C371A7 /* SkDashPathEffect.h */,
-				FEEBB7D0094213B900C371A7 /* SkDescriptor.h */,
-				FEEBB7D1094213B900C371A7 /* SkDiscretePathEffect.h */,
-				FEEBB7D2094213B900C371A7 /* SkDOM.h */,
-				FEEBB7D3094213B900C371A7 /* SkEmbossMaskFilter.h */,
-				FEEBB7D5094213B900C371A7 /* SkEvent.h */,
-				FEEBB7D6094213B900C371A7 /* SkEventSink.h */,
-				FEEBB7D9094213B900C371A7 /* SkFlattenable.h */,
-				FEEBB7DB094213B900C371A7 /* SkFontCodec.h */,
-				FEEBB7DC094213B900C371A7 /* SkFontHost.h */,
-				FEEBB7DE094213B900C371A7 /* SkGlobals.h */,
-				FEEBB7DF094213B900C371A7 /* SkGradientShader.h */,
-				FEEBB7E0094213B900C371A7 /* SkGraphics.h */,
-				FEEBB7E1094213B900C371A7 /* SkImageDecoder.h */,
-				FEEBB7E4094213B900C371A7 /* SkJS.h */,
-				FEEBB7E5094213B900C371A7 /* SkKey.h */,
-				FEEBB7E8094213B900C371A7 /* SkMask.h */,
-				FEEBB7E9094213B900C371A7 /* SkMaskFilter.h */,
-				FEEBB7EC094213B900C371A7 /* SkMetaData.h */,
-				FEEBB7ED094213B900C371A7 /* SkOSFile.h */,
-				FEEBB7EE094213B900C371A7 /* SkOSMenu.h */,
-				FEEBB7EF094213B900C371A7 /* SkOSSound.h */,
-				FEEBB7F0094213B900C371A7 /* SkOSWindow_Mac.h */,
-				FEEBB7F1094213B900C371A7 /* SkOSWindow_Unix.h */,
-				FEEBB7F2094213B900C371A7 /* SkOSWindow_Win.h */,
-				FEEBB7F4094213B900C371A7 /* SkParse.h */,
-				FEEBB7F5094213B900C371A7 /* SkParsePaint.h */,
-				FEEBB7F6094213B900C371A7 /* SkPath.h */,
-				FEEBB7F7094213B900C371A7 /* SkPathEffect.h */,
-				FEEBB7F8094213B900C371A7 /* SkPathMeasure.h */,
-				FEEBB801094213B900C371A7 /* SkRefCnt.h */,
-				FEEBB804094213B900C371A7 /* SkScalerContext.h */,
-				FEEBB805094213B900C371A7 /* SkShader.h */,
-				FEEBB806094213B900C371A7 /* SkStackViewLayout.h */,
-				FEEBB808094213B900C371A7 /* SkStream.h */,
-				FEEBB809094213B900C371A7 /* SkStream_Win.h */,
-				FEEBB80A094213B900C371A7 /* SkString.h */,
-				FEEBB80B094213B900C371A7 /* SkStroke.h */,
-				FEEBB80C094213B900C371A7 /* SkSVGAttribute.h */,
-				FEEBB80D094213B900C371A7 /* SkSVGBase.h */,
-				FEEBB80E094213B900C371A7 /* SkSVGPaintState.h */,
-				FEEBB80F094213B900C371A7 /* SkSVGParser.h */,
-				FEEBB810094213B900C371A7 /* SkSVGTypes.h */,
-				FEEBB811094213B900C371A7 /* SkSystemEventTypes.h */,
-				FEEBB812094213B900C371A7 /* SkTDArray.h */,
-				FEEBB813094213B900C371A7 /* SkTDict.h */,
-				FEEBB814094213B900C371A7 /* SkTDStack.h */,
-				FEEBB816094213B900C371A7 /* SkTextBox.h */,
-				FEEBB818094213B900C371A7 /* SkTime.h */,
-				FEEBB819094213B900C371A7 /* SkTransparentShader.h */,
-				FEEBB81C094213B900C371A7 /* SkUnitMapper.h */,
-				FEEBB81D094213B900C371A7 /* SkUtils.h */,
-				FEEBB81E094213B900C371A7 /* SkView.h */,
-				FEEBB81F094213B900C371A7 /* SkViewInflate.h */,
-				FEEBB820094213B900C371A7 /* SkWidget.h */,
-				FEEBB821094213B900C371A7 /* SkWindow.h */,
-				FEEBB822094213B900C371A7 /* SkXfermode.h */,
-				FEEBB823094213B900C371A7 /* SkXMLParser.h */,
-				FEEBB824094213B900C371A7 /* SkXMLWriter.h */,
-			);
-			name = include;
-			path = ../../include/graphics;
-			sourceTree = SOURCE_ROOT;
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC06B0554671400DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FEEBB826094213B900C371A7 /* Sk1DPathEffect.h in Headers */,
-				FEEBB827094213B900C371A7 /* Sk2DPathEffect.h in Headers */,
-				FEEBB829094213B900C371A7 /* SkAnimator.h in Headers */,
-				FEEBB82A094213B900C371A7 /* SkAnimatorView.h in Headers */,
-				FEEBB82B094213B900C371A7 /* SkBGViewArtist.h in Headers */,
-				FEEBB82C094213B900C371A7 /* SkBitmap.h in Headers */,
-				FEEBB82E094213B900C371A7 /* SkBlurMaskFilter.h in Headers */,
-				FEEBB82F094213B900C371A7 /* SkBML_WXMLParser.h in Headers */,
-				FEEBB830094213B900C371A7 /* SkBML_XMLParser.h in Headers */,
-				FEEBB831094213B900C371A7 /* SkBounder.h in Headers */,
-				FEEBB833094213B900C371A7 /* SkCamera.h in Headers */,
-				FEEBB834094213B900C371A7 /* SkCanvas.h in Headers */,
-				FEEBB835094213B900C371A7 /* SkColor.h in Headers */,
-				FEEBB836094213B900C371A7 /* SkColorPriv.h in Headers */,
-				FEEBB837094213B900C371A7 /* SkDashPathEffect.h in Headers */,
-				FEEBB838094213B900C371A7 /* SkDescriptor.h in Headers */,
-				FEEBB839094213B900C371A7 /* SkDiscretePathEffect.h in Headers */,
-				FEEBB83A094213B900C371A7 /* SkDOM.h in Headers */,
-				FEEBB83B094213B900C371A7 /* SkEmbossMaskFilter.h in Headers */,
-				FEEBB83D094213B900C371A7 /* SkEvent.h in Headers */,
-				FEEBB83E094213B900C371A7 /* SkEventSink.h in Headers */,
-				FEEBB841094213B900C371A7 /* SkFlattenable.h in Headers */,
-				FEEBB843094213B900C371A7 /* SkFontCodec.h in Headers */,
-				FEEBB844094213B900C371A7 /* SkFontHost.h in Headers */,
-				FEEBB846094213B900C371A7 /* SkGlobals.h in Headers */,
-				FEEBB847094213B900C371A7 /* SkGradientShader.h in Headers */,
-				FEEBB848094213B900C371A7 /* SkGraphics.h in Headers */,
-				FEEBB849094213B900C371A7 /* SkImageDecoder.h in Headers */,
-				FEEBB84C094213B900C371A7 /* SkJS.h in Headers */,
-				FEEBB84D094213B900C371A7 /* SkKey.h in Headers */,
-				FEEBB850094213B900C371A7 /* SkMask.h in Headers */,
-				FEEBB851094213B900C371A7 /* SkMaskFilter.h in Headers */,
-				FEEBB854094213B900C371A7 /* SkMetaData.h in Headers */,
-				FEEBB855094213B900C371A7 /* SkOSFile.h in Headers */,
-				FEEBB856094213B900C371A7 /* SkOSMenu.h in Headers */,
-				FEEBB857094213B900C371A7 /* SkOSSound.h in Headers */,
-				FEEBB858094213B900C371A7 /* SkOSWindow_Mac.h in Headers */,
-				FEEBB859094213B900C371A7 /* SkOSWindow_Unix.h in Headers */,
-				FEEBB85A094213B900C371A7 /* SkOSWindow_Win.h in Headers */,
-				FEEBB85C094213B900C371A7 /* SkParse.h in Headers */,
-				FEEBB85D094213B900C371A7 /* SkParsePaint.h in Headers */,
-				FEEBB85E094213B900C371A7 /* SkPath.h in Headers */,
-				FEEBB85F094213B900C371A7 /* SkPathEffect.h in Headers */,
-				FEEBB860094213B900C371A7 /* SkPathMeasure.h in Headers */,
-				FEEBB869094213B900C371A7 /* SkRefCnt.h in Headers */,
-				FEEBB86C094213B900C371A7 /* SkScalerContext.h in Headers */,
-				FEEBB86D094213B900C371A7 /* SkShader.h in Headers */,
-				FEEBB86E094213B900C371A7 /* SkStackViewLayout.h in Headers */,
-				FEEBB870094213B900C371A7 /* SkStream.h in Headers */,
-				FEEBB871094213B900C371A7 /* SkStream_Win.h in Headers */,
-				FEEBB872094213B900C371A7 /* SkString.h in Headers */,
-				FEEBB873094213B900C371A7 /* SkStroke.h in Headers */,
-				FEEBB874094213B900C371A7 /* SkSVGAttribute.h in Headers */,
-				FEEBB875094213B900C371A7 /* SkSVGBase.h in Headers */,
-				FEEBB876094213B900C371A7 /* SkSVGPaintState.h in Headers */,
-				FEEBB877094213B900C371A7 /* SkSVGParser.h in Headers */,
-				FEEBB878094213B900C371A7 /* SkSVGTypes.h in Headers */,
-				FEEBB879094213B900C371A7 /* SkSystemEventTypes.h in Headers */,
-				FEEBB87A094213B900C371A7 /* SkTDArray.h in Headers */,
-				FEEBB87B094213B900C371A7 /* SkTDict.h in Headers */,
-				FEEBB87C094213B900C371A7 /* SkTDStack.h in Headers */,
-				FEEBB87E094213B900C371A7 /* SkTextBox.h in Headers */,
-				FEEBB880094213B900C371A7 /* SkTime.h in Headers */,
-				FEEBB881094213B900C371A7 /* SkTransparentShader.h in Headers */,
-				FEEBB884094213B900C371A7 /* SkUnitMapper.h in Headers */,
-				FEEBB885094213B900C371A7 /* SkUtils.h in Headers */,
-				FEEBB886094213B900C371A7 /* SkView.h in Headers */,
-				FEEBB887094213B900C371A7 /* SkViewInflate.h in Headers */,
-				FEEBB888094213B900C371A7 /* SkWidget.h in Headers */,
-				FEEBB889094213B900C371A7 /* SkWindow.h in Headers */,
-				FEEBB88A094213B900C371A7 /* SkXfermode.h in Headers */,
-				FEEBB88B094213B900C371A7 /* SkXMLParser.h in Headers */,
-				FEEBB88C094213B900C371A7 /* SkXMLWriter.h in Headers */,
-				FE5F48BC094797D00095980F /* SkBML_Verbs.h in Headers */,
-				00B5022D09DB127D00A01CD6 /* SkRegionPriv.h in Headers */,
-				002B77550A1BB07A003B067F /* SkCornerPathEffect.h in Headers */,
-				002B77560A1BB07A003B067F /* SkDeque.h in Headers */,
-				002B77570A1BB07A003B067F /* SkPaint.h in Headers */,
-				002B77580A1BB07A003B067F /* SkPorterDuff.h in Headers */,
-				002B77590A1BB07A003B067F /* SkShaderExtras.h in Headers */,
-				00081FE40A67CF1800A37923 /* SkColorFilter.h in Headers */,
-				00081FE50A67CF1800A37923 /* SkRasterizer.h in Headers */,
-				00081FE70A67CF1800A37923 /* SkTypeface.h in Headers */,
-				0084BECD0A67EB98003713D0 /* SkLayerRasterizer.h in Headers */,
-				0027DCD20B24CA4E00076079 /* SkDevice.h in Headers */,
-				003091FB0C19BE04009F515A /* SkBitmapProcShader.h in Headers */,
-				003092000C19BE04009F515A /* SkBitmapProcState.h in Headers */,
-				006B54390C42B3B0008E512D /* SkBlurDrawLooper.h in Headers */,
-				00A159D10C469A1200DB6CED /* SkBlitRow.h in Headers */,
-				00523E980C7B335D00D53402 /* SkBlurMask.h in Headers */,
-				00523E9D0C7B335D00D53402 /* SkEmbossMask_Table.h in Headers */,
-				00523E9F0C7B335D00D53402 /* SkEmbossMask.h in Headers */,
-				00523EA30C7B335D00D53402 /* SkRadialGradient_Table.h in Headers */,
-				00523EA90C7B33B100D53402 /* SkUnitMappers.h in Headers */,
-				FE20DF660C7F15D200AAC91E /* ARGB32_Clamp_Bilinear_BitmapShader.h in Headers */,
-				FE20DF680C7F15D200AAC91E /* SkAntiRun.h in Headers */,
-				FE20DF690C7F15D200AAC91E /* SkAutoKern.h in Headers */,
-				FE20DF6B0C7F15D200AAC91E /* SkBitmapProcState_matrix.h in Headers */,
-				FE20DF6C0C7F15D200AAC91E /* SkBitmapProcState_sample.h in Headers */,
-				FE20DF6E0C7F15D200AAC91E /* SkBitmapSampler.h in Headers */,
-				FE20DF6F0C7F15D200AAC91E /* SkBitmapSamplerTemplate.h in Headers */,
-				FE20DF710C7F15D200AAC91E /* SkBitmapShader.h in Headers */,
-				FE20DF720C7F15D200AAC91E /* SkBitmapShader16BilerpTemplate.h in Headers */,
-				FE20DF730C7F15D200AAC91E /* SkBitmapShaderTemplate.h in Headers */,
-				FE20DF740C7F15D200AAC91E /* SkBlitBWMaskTemplate.h in Headers */,
-				FE20DF7B0C7F15D200AAC91E /* SkBlitter.h in Headers */,
-				FE20DF7F0C7F15D200AAC91E /* SkCoreBlitters.h in Headers */,
-				FE20DF820C7F15D200AAC91E /* SkEdge.h in Headers */,
-				FE20DF840C7F15D200AAC91E /* SkFilterProc.h in Headers */,
-				FE20DF850C7F15D200AAC91E /* SkFP.h in Headers */,
-				FE20DF870C7F15D200AAC91E /* SkGeometry.h in Headers */,
-				FE20DF8A0C7F15D200AAC91E /* SkGlyphCache.h in Headers */,
-				FE20DF9B0C7F15D200AAC91E /* SkScan.h in Headers */,
-				FE20DF9C0C7F15D200AAC91E /* SkScanPriv.h in Headers */,
-				FE20DFA00C7F15D200AAC91E /* SkSpriteBlitter.h in Headers */,
-				FE20DFA10C7F15D200AAC91E /* SkSpriteBlitterTemplate.h in Headers */,
-				FE20DFA50C7F15D200AAC91E /* SkStrokerPriv.h in Headers */,
-				FE20DFA60C7F15D200AAC91E /* SkTemplatesPriv.h in Headers */,
-				FE20DFA80C7F15D200AAC91E /* SkTSort.h in Headers */,
-				003538590C85BF0D007289C0 /* SkColorShader.h in Headers */,
-				0035385A0C85BF0D007289C0 /* SkDrawFilter.h in Headers */,
-				0035385B0C85BF0D007289C0 /* SkDrawLooper.h in Headers */,
-				0035385C0C85BF0D007289C0 /* SkKernel33MaskFilter.h in Headers */,
-				0035385D0C85BF0D007289C0 /* SkPackBits.h in Headers */,
-				0035385E0C85BF0D007289C0 /* SkPicture.h in Headers */,
-				0043B2DB0D75C840004A0E2A /* SkScaledBitmapSampler.h in Headers */,
-				009A75E80DA1DF5D00876C03 /* SkDrawProcs.h in Headers */,
-				001142D70DCA3EE90070D0A3 /* SkPicturePlayback.h in Headers */,
-				001142D90DCA3EE90070D0A3 /* SkPictureRecord.h in Headers */,
-				0011430B0DCA458A0070D0A3 /* SkPictureFlat.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC06E0554671400DB518D /* graphics */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB920108733DBB0010E9CD /* Build configuration list for PBXNativeTarget "graphics" */;
-			buildPhases = (
-				D2AAC06B0554671400DB518D /* Headers */,
-				D2AAC06C0554671400DB518D /* Sources */,
-				D2AAC06D0554671400DB518D /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = graphics;
-			productName = graphics;
-			productReference = D2AAC06F0554671400DB518D /* libgraphics.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		0867D690FE84028FC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB920508733DBB0010E9CD /* Build configuration list for PBXProject "graphics" */;
-			compatibilityVersion = "Xcode 3.0";
-			hasScannedForEncodings = 1;
-			mainGroup = 0867D691FE84028FC02AAC07 /* graphics */;
-			productRefGroup = 034768DDFF38A45A11DB9C8B /* Products */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC06E0554671400DB518D /* graphics */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC06C0554671400DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE5F486E094788030095980F /* SkImageDecoder.cpp in Sources */,
-				FE5F486F094788030095980F /* SkStream.cpp in Sources */,
-				FE5F48BD094797D00095980F /* SkBML_XMLParser.cpp in Sources */,
-				FE5F48BE094797D00095980F /* SkDOM.cpp in Sources */,
-				FE5F48C1094797D00095980F /* SkParse.cpp in Sources */,
-				FE5F48C2094797D00095980F /* SkParseColor.cpp in Sources */,
-				FE5F48C3094797D00095980F /* SkXMLParser.cpp in Sources */,
-				FE5F48C4094797D00095980F /* SkXMLWriter.cpp in Sources */,
-				FEDCE31809C9CEC70042D964 /* SkDebug.cpp in Sources */,
-				002C8E6E0A0A515000FFB8EC /* SkDeque.cpp in Sources */,
-				002B774F0A1BB054003B067F /* SkShaderExtras.cpp in Sources */,
-				00081FDE0A67CEF400A37923 /* SkRasterizer.cpp in Sources */,
-				0084BECB0A67EB6F003713D0 /* SkLayerRasterizer.cpp in Sources */,
-				000C28720AA50FFE005A479B /* SkColorFilters.cpp in Sources */,
-				000C28730AA50FFF005A479B /* SkCullPoints.cpp in Sources */,
-				000C28790AA51077005A479B /* SkColorFilter.cpp in Sources */,
-				009866480ACD95EF00B69A0B /* SkAvoidXfermode.cpp in Sources */,
-				009306CC0AD3F8520068227B /* SkCornerPathEffect.cpp in Sources */,
-				0027DCD00B24CA3900076079 /* SkDevice.cpp in Sources */,
-				00A2188A0B652EEC0056CB69 /* SkMask.cpp in Sources */,
-				003091FA0C19BE04009F515A /* SkBitmapProcShader.cpp in Sources */,
-				003091FD0C19BE04009F515A /* SkBitmapProcState_matrixProcs.cpp in Sources */,
-				003091FF0C19BE04009F515A /* SkBitmapProcState.cpp in Sources */,
-				006B542E0C42B355008E512D /* SkBlurDrawLooper.cpp in Sources */,
-				00A159D00C469A1200DB6CED /* SkBlitRow_D16.cpp in Sources */,
-				00A159D20C469A1200DB6CED /* SkDither.cpp in Sources */,
-				00523E950C7B335D00D53402 /* Sk1DPathEffect.cpp in Sources */,
-				00523E960C7B335D00D53402 /* Sk2DPathEffect.cpp in Sources */,
-				00523E970C7B335D00D53402 /* SkBlurMask.cpp in Sources */,
-				00523E990C7B335D00D53402 /* SkBlurMaskFilter.cpp in Sources */,
-				00523E9A0C7B335D00D53402 /* SkCamera.cpp in Sources */,
-				00523E9B0C7B335D00D53402 /* SkDashPathEffect.cpp in Sources */,
-				00523E9C0C7B335D00D53402 /* SkDiscretePathEffect.cpp in Sources */,
-				00523E9E0C7B335D00D53402 /* SkEmbossMask.cpp in Sources */,
-				00523EA00C7B335D00D53402 /* SkEmbossMaskFilter.cpp in Sources */,
-				00523EA10C7B335D00D53402 /* SkGradientShader.cpp in Sources */,
-				00523EA40C7B335D00D53402 /* SkTransparentShader.cpp in Sources */,
-				00523EA50C7B335D00D53402 /* SkUnitMappers.cpp in Sources */,
-				00523F420C7B3C1400D53402 /* SkFlattenable.cpp in Sources */,
-				FE20DF0C0C7F154F00AAC91E /* SkKernel33MaskFilter.cpp in Sources */,
-				FE20DF200C7F157B00AAC91E /* SkMovie.cpp in Sources */,
-				FE20DF670C7F15D200AAC91E /* SkAlphaRuns.cpp in Sources */,
-				FE20DF6A0C7F15D200AAC91E /* SkBitmap.cpp in Sources */,
-				FE20DF6D0C7F15D200AAC91E /* SkBitmapSampler.cpp in Sources */,
-				FE20DF700C7F15D200AAC91E /* SkBitmapShader.cpp in Sources */,
-				FE20DF750C7F15D200AAC91E /* SkBlitter_A1.cpp in Sources */,
-				FE20DF760C7F15D200AAC91E /* SkBlitter_A8.cpp in Sources */,
-				FE20DF770C7F15D200AAC91E /* SkBlitter_ARGB32.cpp in Sources */,
-				FE20DF780C7F15D200AAC91E /* SkBlitter_RGB16.cpp in Sources */,
-				FE20DF790C7F15D200AAC91E /* SkBlitter_Sprite.cpp in Sources */,
-				FE20DF7A0C7F15D200AAC91E /* SkBlitter.cpp in Sources */,
-				FE20DF7C0C7F15D200AAC91E /* SkCanvas.cpp in Sources */,
-				FE20DF7D0C7F15D200AAC91E /* SkColor.cpp in Sources */,
-				FE20DF7E0C7F15D200AAC91E /* SkColorTable.cpp in Sources */,
-				FE20DF800C7F15D200AAC91E /* SkDraw.cpp in Sources */,
-				FE20DF810C7F15D200AAC91E /* SkEdge.cpp in Sources */,
-				FE20DF830C7F15D200AAC91E /* SkFilterProc.cpp in Sources */,
-				FE20DF860C7F15D200AAC91E /* SkGeometry.cpp in Sources */,
-				FE20DF880C7F15D200AAC91E /* SkGlobals.cpp in Sources */,
-				FE20DF890C7F15D200AAC91E /* SkGlyphCache.cpp in Sources */,
-				FE20DF8B0C7F15D200AAC91E /* SkGraphics.cpp in Sources */,
-				FE20DF8C0C7F15D200AAC91E /* SkMaskFilter.cpp in Sources */,
-				FE20DF8D0C7F15D200AAC91E /* SkPackBits.cpp in Sources */,
-				FE20DF8E0C7F15D200AAC91E /* SkPaint.cpp in Sources */,
-				FE20DF8F0C7F15D200AAC91E /* SkPath.cpp in Sources */,
-				FE20DF900C7F15D200AAC91E /* SkPathEffect.cpp in Sources */,
-				FE20DF910C7F15D200AAC91E /* SkPathMeasure.cpp in Sources */,
-				FE20DF920C7F15D200AAC91E /* SkProcSpriteBlitter.cpp in Sources */,
-				FE20DF930C7F15D200AAC91E /* SkRefCnt.cpp in Sources */,
-				FE20DF940C7F15D200AAC91E /* SkRegion_path.cpp in Sources */,
-				FE20DF950C7F15D200AAC91E /* SkScalerContext.cpp in Sources */,
-				FE20DF960C7F15D200AAC91E /* SkScan_Antihair.cpp in Sources */,
-				FE20DF970C7F15D200AAC91E /* SkScan_AntiPath.cpp in Sources */,
-				FE20DF980C7F15D200AAC91E /* SkScan_Hairline.cpp in Sources */,
-				FE20DF990C7F15D200AAC91E /* SkScan_Path.cpp in Sources */,
-				FE20DF9A0C7F15D200AAC91E /* SkScan.cpp in Sources */,
-				FE20DF9D0C7F15D200AAC91E /* SkShader.cpp in Sources */,
-				FE20DF9E0C7F15D200AAC91E /* SkSpriteBlitter_ARGB32.cpp in Sources */,
-				FE20DF9F0C7F15D200AAC91E /* SkSpriteBlitter_RGB16.cpp in Sources */,
-				FE20DFA20C7F15D200AAC91E /* SkString.cpp in Sources */,
-				FE20DFA30C7F15D200AAC91E /* SkStroke.cpp in Sources */,
-				FE20DFA40C7F15D200AAC91E /* SkStrokerPriv.cpp in Sources */,
-				FE20DFA70C7F15D200AAC91E /* SkTSearch.cpp in Sources */,
-				FE20DFA90C7F15D200AAC91E /* SkUtils.cpp in Sources */,
-				FE20DFAA0C7F15D200AAC91E /* SkXfermode.cpp in Sources */,
-				003538200C85BDCE007289C0 /* SkPixelXorXfermode.cpp in Sources */,
-				001FFBBD0CD8D9ED000CDF07 /* SkImageRef.cpp in Sources */,
-				006D3B5F0CE0CAE700CE1224 /* SkWriter32.cpp in Sources */,
-				003E6EFE0D09EF84005435C0 /* SkColorMatrix.cpp in Sources */,
-				003E6EFF0D09EF84005435C0 /* SkColorMatrixFilter.cpp in Sources */,
-				0053B0EE0D3557960016606F /* SkPaintFlagsDrawFilter.cpp in Sources */,
-				0053B0F00D3557AD0016606F /* SkTypeface.cpp in Sources */,
-				008618740D46CC75007F0674 /* SkBlitRow_D4444.cpp in Sources */,
-				008618750D46CC75007F0674 /* SkBlitter_4444.cpp in Sources */,
-				009907F10D53A06200AD25AA /* SkBitmap_scroll.cpp in Sources */,
-				00C88FEF0D89B7920015D427 /* SkUnPreMultiply.cpp in Sources */,
-				008180E70D92D57300A2E56D /* SkScaledBitmapSampler.cpp in Sources */,
-				009A75EA0DA1DF8400876C03 /* SkNinePatch.cpp in Sources */,
-				009A39630DAE52FA00EB3A73 /* SkImageRefPool.cpp in Sources */,
-				003FF1680DAE9C0F00601F6B /* SkImageRef_GlobalPool.cpp in Sources */,
-				001142D60DCA3EE90070D0A3 /* SkPicturePlayback.cpp in Sources */,
-				001142D80DCA3EE90070D0A3 /* SkPictureRecord.cpp in Sources */,
-				0011430D0DCA45990070D0A3 /* SkPictureFlat.cpp in Sources */,
-				009B1EAE0DD224CF00EDFFF4 /* SkPixelRef.cpp in Sources */,
-				007336190DDC859F00A0DB2A /* SkPtrRecorder.cpp in Sources */,
-				00B4AC4F0E9BF59400A184BF /* SkPicture.cpp in Sources */,
-				0019627D0EACB91200447A07 /* SkPageFlipper.cpp in Sources */,
-				0019627F0EACB92A00447A07 /* SkFlipPixelRef.cpp in Sources */,
-				001962810EACB94400447A07 /* SkPathHeap.cpp in Sources */,
-				00B8EC940EB6A319003C2F6F /* SkLayerDrawLooper.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB920208733DBB0010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = graphics_Prefix.pch;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = graphics;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB920308733DBB0010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = graphics_Prefix.pch;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = graphics;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB920608733DBB0010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_DEBUGGING_SYMBOLS = full;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PFE_FILE_C_DIALECTS = "";
-				GCC_PREPROCESSOR_DEFINITIONS = SK_DEBUG;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../libs/corecg ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB920708733DBB0010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_DEBUGGING_SYMBOLS = full;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PFE_FILE_C_DIALECTS = "";
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../libs/corecg ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB920108733DBB0010E9CD /* Build configuration list for PBXNativeTarget "graphics" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB920208733DBB0010E9CD /* Debug */,
-				1DEB920308733DBB0010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB920508733DBB0010E9CD /* Build configuration list for PBXProject "graphics" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB920608733DBB0010E9CD /* Debug */,
-				1DEB920708733DBB0010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/jpeg.xcodeproj/project.pbxproj b/ide/xcode/jpeg.xcodeproj/project.pbxproj
deleted file mode 100644
index a169c20..0000000
--- a/ide/xcode/jpeg.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,440 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		00B06C3D0E3E2D7200FAA74F /* jerror.h in Headers */ = {isa = PBXBuildFile; fileRef = 00B06C3C0E3E2D7200FAA74F /* jerror.h */; };
-		FE08AA410945D5BF0057213F /* jconfig.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA3F0945D5BF0057213F /* jconfig.h */; };
-		FE08AA420945D5BF0057213F /* jpeglib.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA400945D5BF0057213F /* jpeglib.h */; };
-		FE08AA760945DA0C0057213F /* jcapimin.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA430945DA0C0057213F /* jcapimin.c */; };
-		FE08AA770945DA0C0057213F /* jcapistd.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA440945DA0C0057213F /* jcapistd.c */; };
-		FE08AA780945DA0C0057213F /* jccoefct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA450945DA0C0057213F /* jccoefct.c */; };
-		FE08AA790945DA0C0057213F /* jccolor.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA460945DA0C0057213F /* jccolor.c */; };
-		FE08AA7A0945DA0C0057213F /* jcdctmgr.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA470945DA0C0057213F /* jcdctmgr.c */; };
-		FE08AA7B0945DA0C0057213F /* jchuff.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA480945DA0C0057213F /* jchuff.c */; };
-		FE08AA7C0945DA0C0057213F /* jcinit.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA490945DA0C0057213F /* jcinit.c */; };
-		FE08AA7D0945DA0C0057213F /* jcmainct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4A0945DA0C0057213F /* jcmainct.c */; };
-		FE08AA7E0945DA0C0057213F /* jcmarker.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4B0945DA0C0057213F /* jcmarker.c */; };
-		FE08AA7F0945DA0C0057213F /* jcmaster.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4C0945DA0C0057213F /* jcmaster.c */; };
-		FE08AA800945DA0C0057213F /* jcomapi.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4D0945DA0C0057213F /* jcomapi.c */; };
-		FE08AA810945DA0C0057213F /* jcparam.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4E0945DA0C0057213F /* jcparam.c */; };
-		FE08AA820945DA0C0057213F /* jcphuff.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA4F0945DA0C0057213F /* jcphuff.c */; };
-		FE08AA830945DA0C0057213F /* jcprepct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA500945DA0C0057213F /* jcprepct.c */; };
-		FE08AA840945DA0C0057213F /* jcsample.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA510945DA0C0057213F /* jcsample.c */; };
-		FE08AA850945DA0C0057213F /* jctrans.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA520945DA0C0057213F /* jctrans.c */; };
-		FE08AA860945DA0C0057213F /* jdapimin.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA530945DA0C0057213F /* jdapimin.c */; };
-		FE08AA870945DA0C0057213F /* jdapistd.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA540945DA0C0057213F /* jdapistd.c */; };
-		FE08AA880945DA0C0057213F /* jdatadst.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA550945DA0C0057213F /* jdatadst.c */; };
-		FE08AA890945DA0C0057213F /* jdatasrc.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA560945DA0C0057213F /* jdatasrc.c */; };
-		FE08AA8A0945DA0C0057213F /* jdcoefct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA570945DA0C0057213F /* jdcoefct.c */; };
-		FE08AA8B0945DA0C0057213F /* jdcolor.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA580945DA0C0057213F /* jdcolor.c */; };
-		FE08AA8C0945DA0C0057213F /* jddctmgr.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA590945DA0C0057213F /* jddctmgr.c */; };
-		FE08AA8D0945DA0C0057213F /* jdhuff.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5A0945DA0C0057213F /* jdhuff.c */; };
-		FE08AA8E0945DA0C0057213F /* jdinput.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5B0945DA0C0057213F /* jdinput.c */; };
-		FE08AA8F0945DA0C0057213F /* jdmainct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5C0945DA0C0057213F /* jdmainct.c */; };
-		FE08AA900945DA0C0057213F /* jdmarker.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5D0945DA0C0057213F /* jdmarker.c */; };
-		FE08AA910945DA0C0057213F /* jdmaster.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5E0945DA0C0057213F /* jdmaster.c */; };
-		FE08AA920945DA0C0057213F /* jdmerge.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA5F0945DA0C0057213F /* jdmerge.c */; };
-		FE08AA930945DA0C0057213F /* jdphuff.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA600945DA0C0057213F /* jdphuff.c */; };
-		FE08AA940945DA0C0057213F /* jdpostct.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA610945DA0C0057213F /* jdpostct.c */; };
-		FE08AA950945DA0C0057213F /* jdsample.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA620945DA0C0057213F /* jdsample.c */; };
-		FE08AA960945DA0C0057213F /* jdtrans.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA630945DA0C0057213F /* jdtrans.c */; };
-		FE08AA970945DA0C0057213F /* jerror.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA640945DA0C0057213F /* jerror.c */; };
-		FE08AA980945DA0C0057213F /* jfdctflt.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA650945DA0C0057213F /* jfdctflt.c */; };
-		FE08AA990945DA0C0057213F /* jfdctfst.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA660945DA0C0057213F /* jfdctfst.c */; };
-		FE08AA9A0945DA0C0057213F /* jfdctint.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA670945DA0C0057213F /* jfdctint.c */; };
-		FE08AA9B0945DA0C0057213F /* jidctflt.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA680945DA0C0057213F /* jidctflt.c */; };
-		FE08AA9C0945DA0C0057213F /* jidctfst.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA690945DA0C0057213F /* jidctfst.c */; };
-		FE08AA9D0945DA0C0057213F /* jidctint.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA6A0945DA0C0057213F /* jidctint.c */; };
-		FE08AA9E0945DA0C0057213F /* jidctred.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA6B0945DA0C0057213F /* jidctred.c */; };
-		FE08AA9F0945DA0C0057213F /* jmemansi.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA6C0945DA0C0057213F /* jmemansi.c */; };
-		FE08AAA20945DA0C0057213F /* jmemmgr.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA6F0945DA0C0057213F /* jmemmgr.c */; };
-		FE08AAA60945DA0C0057213F /* jquant1.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA730945DA0C0057213F /* jquant1.c */; };
-		FE08AAA70945DA0C0057213F /* jquant2.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA740945DA0C0057213F /* jquant2.c */; };
-		FE08AAA80945DA0C0057213F /* jutils.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA750945DA0C0057213F /* jutils.c */; };
-		FE08ABBB0946182C0057213F /* jchuff.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08ABBA0946182C0057213F /* jchuff.h */; };
-		FE7B86310948E853001B952C /* SkImageDecoder_libjpeg.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE7B86300948E853001B952C /* SkImageDecoder_libjpeg.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		00B06C3C0E3E2D7200FAA74F /* jerror.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = jerror.h; path = "../../extlibs/jpeg-6b/jerror.h"; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libjpeg.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libjpeg.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE08AA3F0945D5BF0057213F /* jconfig.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jconfig.h; path = "../../extlibs/jpeg-6b/jconfig.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA400945D5BF0057213F /* jpeglib.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jpeglib.h; path = "../../extlibs/jpeg-6b/jpeglib.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA430945DA0C0057213F /* jcapimin.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcapimin.c; path = "../../extlibs/jpeg-6b/jcapimin.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA440945DA0C0057213F /* jcapistd.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcapistd.c; path = "../../extlibs/jpeg-6b/jcapistd.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA450945DA0C0057213F /* jccoefct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jccoefct.c; path = "../../extlibs/jpeg-6b/jccoefct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA460945DA0C0057213F /* jccolor.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jccolor.c; path = "../../extlibs/jpeg-6b/jccolor.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA470945DA0C0057213F /* jcdctmgr.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcdctmgr.c; path = "../../extlibs/jpeg-6b/jcdctmgr.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA480945DA0C0057213F /* jchuff.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jchuff.c; path = "../../extlibs/jpeg-6b/jchuff.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA490945DA0C0057213F /* jcinit.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcinit.c; path = "../../extlibs/jpeg-6b/jcinit.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4A0945DA0C0057213F /* jcmainct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcmainct.c; path = "../../extlibs/jpeg-6b/jcmainct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4B0945DA0C0057213F /* jcmarker.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcmarker.c; path = "../../extlibs/jpeg-6b/jcmarker.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4C0945DA0C0057213F /* jcmaster.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcmaster.c; path = "../../extlibs/jpeg-6b/jcmaster.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4D0945DA0C0057213F /* jcomapi.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcomapi.c; path = "../../extlibs/jpeg-6b/jcomapi.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4E0945DA0C0057213F /* jcparam.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcparam.c; path = "../../extlibs/jpeg-6b/jcparam.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA4F0945DA0C0057213F /* jcphuff.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcphuff.c; path = "../../extlibs/jpeg-6b/jcphuff.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA500945DA0C0057213F /* jcprepct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcprepct.c; path = "../../extlibs/jpeg-6b/jcprepct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA510945DA0C0057213F /* jcsample.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jcsample.c; path = "../../extlibs/jpeg-6b/jcsample.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA520945DA0C0057213F /* jctrans.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jctrans.c; path = "../../extlibs/jpeg-6b/jctrans.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA530945DA0C0057213F /* jdapimin.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdapimin.c; path = "../../extlibs/jpeg-6b/jdapimin.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA540945DA0C0057213F /* jdapistd.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdapistd.c; path = "../../extlibs/jpeg-6b/jdapistd.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA550945DA0C0057213F /* jdatadst.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdatadst.c; path = "../../extlibs/jpeg-6b/jdatadst.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA560945DA0C0057213F /* jdatasrc.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdatasrc.c; path = "../../extlibs/jpeg-6b/jdatasrc.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA570945DA0C0057213F /* jdcoefct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdcoefct.c; path = "../../extlibs/jpeg-6b/jdcoefct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA580945DA0C0057213F /* jdcolor.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdcolor.c; path = "../../extlibs/jpeg-6b/jdcolor.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA590945DA0C0057213F /* jddctmgr.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jddctmgr.c; path = "../../extlibs/jpeg-6b/jddctmgr.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5A0945DA0C0057213F /* jdhuff.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdhuff.c; path = "../../extlibs/jpeg-6b/jdhuff.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5B0945DA0C0057213F /* jdinput.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdinput.c; path = "../../extlibs/jpeg-6b/jdinput.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5C0945DA0C0057213F /* jdmainct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdmainct.c; path = "../../extlibs/jpeg-6b/jdmainct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5D0945DA0C0057213F /* jdmarker.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdmarker.c; path = "../../extlibs/jpeg-6b/jdmarker.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5E0945DA0C0057213F /* jdmaster.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdmaster.c; path = "../../extlibs/jpeg-6b/jdmaster.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA5F0945DA0C0057213F /* jdmerge.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdmerge.c; path = "../../extlibs/jpeg-6b/jdmerge.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA600945DA0C0057213F /* jdphuff.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdphuff.c; path = "../../extlibs/jpeg-6b/jdphuff.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA610945DA0C0057213F /* jdpostct.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdpostct.c; path = "../../extlibs/jpeg-6b/jdpostct.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA620945DA0C0057213F /* jdsample.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdsample.c; path = "../../extlibs/jpeg-6b/jdsample.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA630945DA0C0057213F /* jdtrans.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jdtrans.c; path = "../../extlibs/jpeg-6b/jdtrans.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA640945DA0C0057213F /* jerror.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jerror.c; path = "../../extlibs/jpeg-6b/jerror.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA650945DA0C0057213F /* jfdctflt.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jfdctflt.c; path = "../../extlibs/jpeg-6b/jfdctflt.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA660945DA0C0057213F /* jfdctfst.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jfdctfst.c; path = "../../extlibs/jpeg-6b/jfdctfst.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA670945DA0C0057213F /* jfdctint.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jfdctint.c; path = "../../extlibs/jpeg-6b/jfdctint.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA680945DA0C0057213F /* jidctflt.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jidctflt.c; path = "../../extlibs/jpeg-6b/jidctflt.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA690945DA0C0057213F /* jidctfst.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jidctfst.c; path = "../../extlibs/jpeg-6b/jidctfst.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA6A0945DA0C0057213F /* jidctint.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jidctint.c; path = "../../extlibs/jpeg-6b/jidctint.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA6B0945DA0C0057213F /* jidctred.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jidctred.c; path = "../../extlibs/jpeg-6b/jidctred.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA6C0945DA0C0057213F /* jmemansi.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jmemansi.c; path = "../../extlibs/jpeg-6b/jmemansi.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA6F0945DA0C0057213F /* jmemmgr.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jmemmgr.c; path = "../../extlibs/jpeg-6b/jmemmgr.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA730945DA0C0057213F /* jquant1.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jquant1.c; path = "../../extlibs/jpeg-6b/jquant1.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA740945DA0C0057213F /* jquant2.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jquant2.c; path = "../../extlibs/jpeg-6b/jquant2.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA750945DA0C0057213F /* jutils.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = jutils.c; path = "../../extlibs/jpeg-6b/jutils.c"; sourceTree = SOURCE_ROOT; };
-		FE08ABBA0946182C0057213F /* jchuff.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = jchuff.h; path = "../../extlibs/jpeg-6b/jchuff.h"; sourceTree = SOURCE_ROOT; };
-		FE7B86300948E853001B952C /* SkImageDecoder_libjpeg.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libjpeg.cpp; path = ../../libs/graphics/images/SkImageDecoder_libjpeg.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* jpeg */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AA3E0945D5620057213F /* Include */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = jpeg;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				FE7B86300948E853001B952C /* SkImageDecoder_libjpeg.cpp */,
-				FE08AA430945DA0C0057213F /* jcapimin.c */,
-				FE08AA440945DA0C0057213F /* jcapistd.c */,
-				FE08AA450945DA0C0057213F /* jccoefct.c */,
-				FE08AA460945DA0C0057213F /* jccolor.c */,
-				FE08AA470945DA0C0057213F /* jcdctmgr.c */,
-				FE08AA480945DA0C0057213F /* jchuff.c */,
-				FE08AA490945DA0C0057213F /* jcinit.c */,
-				FE08AA4A0945DA0C0057213F /* jcmainct.c */,
-				FE08AA4B0945DA0C0057213F /* jcmarker.c */,
-				FE08AA4C0945DA0C0057213F /* jcmaster.c */,
-				FE08AA4D0945DA0C0057213F /* jcomapi.c */,
-				FE08AA4E0945DA0C0057213F /* jcparam.c */,
-				FE08AA4F0945DA0C0057213F /* jcphuff.c */,
-				FE08AA500945DA0C0057213F /* jcprepct.c */,
-				FE08AA510945DA0C0057213F /* jcsample.c */,
-				FE08AA520945DA0C0057213F /* jctrans.c */,
-				FE08AA530945DA0C0057213F /* jdapimin.c */,
-				FE08AA540945DA0C0057213F /* jdapistd.c */,
-				FE08AA550945DA0C0057213F /* jdatadst.c */,
-				FE08AA560945DA0C0057213F /* jdatasrc.c */,
-				FE08AA570945DA0C0057213F /* jdcoefct.c */,
-				FE08AA580945DA0C0057213F /* jdcolor.c */,
-				FE08AA590945DA0C0057213F /* jddctmgr.c */,
-				FE08AA5A0945DA0C0057213F /* jdhuff.c */,
-				FE08AA5B0945DA0C0057213F /* jdinput.c */,
-				FE08AA5C0945DA0C0057213F /* jdmainct.c */,
-				FE08AA5D0945DA0C0057213F /* jdmarker.c */,
-				FE08AA5E0945DA0C0057213F /* jdmaster.c */,
-				FE08AA5F0945DA0C0057213F /* jdmerge.c */,
-				FE08AA600945DA0C0057213F /* jdphuff.c */,
-				FE08AA610945DA0C0057213F /* jdpostct.c */,
-				FE08AA620945DA0C0057213F /* jdsample.c */,
-				FE08AA630945DA0C0057213F /* jdtrans.c */,
-				FE08AA640945DA0C0057213F /* jerror.c */,
-				FE08AA650945DA0C0057213F /* jfdctflt.c */,
-				FE08AA660945DA0C0057213F /* jfdctfst.c */,
-				FE08AA670945DA0C0057213F /* jfdctint.c */,
-				FE08AA680945DA0C0057213F /* jidctflt.c */,
-				FE08AA690945DA0C0057213F /* jidctfst.c */,
-				FE08AA6A0945DA0C0057213F /* jidctint.c */,
-				FE08AA6B0945DA0C0057213F /* jidctred.c */,
-				FE08AA6C0945DA0C0057213F /* jmemansi.c */,
-				FE08AA6F0945DA0C0057213F /* jmemmgr.c */,
-				FE08AA730945DA0C0057213F /* jquant1.c */,
-				FE08AA740945DA0C0057213F /* jquant2.c */,
-				FE08AA750945DA0C0057213F /* jutils.c */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libjpeg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-		FE08AA3E0945D5620057213F /* Include */ = {
-			isa = PBXGroup;
-			children = (
-				00B06C3C0E3E2D7200FAA74F /* jerror.h */,
-				FE08ABBA0946182C0057213F /* jchuff.h */,
-				FE08AA3F0945D5BF0057213F /* jconfig.h */,
-				FE08AA400945D5BF0057213F /* jpeglib.h */,
-			);
-			name = Include;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AA410945D5BF0057213F /* jconfig.h in Headers */,
-				FE08AA420945D5BF0057213F /* jpeglib.h in Headers */,
-				FE08ABBB0946182C0057213F /* jchuff.h in Headers */,
-				00B06C3D0E3E2D7200FAA74F /* jerror.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* jpeg */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = FE5F48080947840B0095980F /* Build configuration list for PBXNativeTarget "jpeg" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = jpeg;
-			productName = jpeg;
-			productReference = D2AAC046055464E500DB518D /* libjpeg.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = FE5F480C0947840B0095980F /* Build configuration list for PBXProject "jpeg" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* jpeg */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC045055464E500DB518D /* jpeg */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AA760945DA0C0057213F /* jcapimin.c in Sources */,
-				FE08AA770945DA0C0057213F /* jcapistd.c in Sources */,
-				FE08AA780945DA0C0057213F /* jccoefct.c in Sources */,
-				FE08AA790945DA0C0057213F /* jccolor.c in Sources */,
-				FE08AA7A0945DA0C0057213F /* jcdctmgr.c in Sources */,
-				FE08AA7B0945DA0C0057213F /* jchuff.c in Sources */,
-				FE08AA7C0945DA0C0057213F /* jcinit.c in Sources */,
-				FE08AA7D0945DA0C0057213F /* jcmainct.c in Sources */,
-				FE08AA7E0945DA0C0057213F /* jcmarker.c in Sources */,
-				FE08AA7F0945DA0C0057213F /* jcmaster.c in Sources */,
-				FE08AA800945DA0C0057213F /* jcomapi.c in Sources */,
-				FE08AA810945DA0C0057213F /* jcparam.c in Sources */,
-				FE08AA820945DA0C0057213F /* jcphuff.c in Sources */,
-				FE08AA830945DA0C0057213F /* jcprepct.c in Sources */,
-				FE08AA840945DA0C0057213F /* jcsample.c in Sources */,
-				FE08AA850945DA0C0057213F /* jctrans.c in Sources */,
-				FE08AA860945DA0C0057213F /* jdapimin.c in Sources */,
-				FE08AA870945DA0C0057213F /* jdapistd.c in Sources */,
-				FE08AA880945DA0C0057213F /* jdatadst.c in Sources */,
-				FE08AA890945DA0C0057213F /* jdatasrc.c in Sources */,
-				FE08AA8A0945DA0C0057213F /* jdcoefct.c in Sources */,
-				FE08AA8B0945DA0C0057213F /* jdcolor.c in Sources */,
-				FE08AA8C0945DA0C0057213F /* jddctmgr.c in Sources */,
-				FE08AA8D0945DA0C0057213F /* jdhuff.c in Sources */,
-				FE08AA8E0945DA0C0057213F /* jdinput.c in Sources */,
-				FE08AA8F0945DA0C0057213F /* jdmainct.c in Sources */,
-				FE08AA900945DA0C0057213F /* jdmarker.c in Sources */,
-				FE08AA910945DA0C0057213F /* jdmaster.c in Sources */,
-				FE08AA920945DA0C0057213F /* jdmerge.c in Sources */,
-				FE08AA930945DA0C0057213F /* jdphuff.c in Sources */,
-				FE08AA940945DA0C0057213F /* jdpostct.c in Sources */,
-				FE08AA950945DA0C0057213F /* jdsample.c in Sources */,
-				FE08AA960945DA0C0057213F /* jdtrans.c in Sources */,
-				FE08AA970945DA0C0057213F /* jerror.c in Sources */,
-				FE08AA980945DA0C0057213F /* jfdctflt.c in Sources */,
-				FE08AA990945DA0C0057213F /* jfdctfst.c in Sources */,
-				FE08AA9A0945DA0C0057213F /* jfdctint.c in Sources */,
-				FE08AA9B0945DA0C0057213F /* jidctflt.c in Sources */,
-				FE08AA9C0945DA0C0057213F /* jidctfst.c in Sources */,
-				FE08AA9D0945DA0C0057213F /* jidctint.c in Sources */,
-				FE08AA9E0945DA0C0057213F /* jidctred.c in Sources */,
-				FE08AA9F0945DA0C0057213F /* jmemansi.c in Sources */,
-				FE08AAA20945DA0C0057213F /* jmemmgr.c in Sources */,
-				FE08AAA60945DA0C0057213F /* jquant1.c in Sources */,
-				FE08AAA70945DA0C0057213F /* jquant2.c in Sources */,
-				FE08AAA80945DA0C0057213F /* jutils.c in Sources */,
-				FE7B86310948E853001B952C /* SkImageDecoder_libjpeg.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		FE5F48090947840B0095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = jpeg;
-				PUBLIC_HEADERS_FOLDER_PATH = "";
-				REZ_PREPROCESSOR_DEFINITIONS = "_LIB SK_FORCE_SCALARFIXED";
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		FE5F480A0947840B0095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = jpeg;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		FE5F480D0947840B0095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		FE5F480E0947840B0095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		FE5F48080947840B0095980F /* Build configuration list for PBXNativeTarget "jpeg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F48090947840B0095980F /* Debug */,
-				FE5F480A0947840B0095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-		FE5F480C0947840B0095980F /* Build configuration list for PBXProject "jpeg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F480D0947840B0095980F /* Debug */,
-				FE5F480E0947840B0095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/libpng.xcodeproj/project.pbxproj b/ide/xcode/libpng.xcodeproj/project.pbxproj
deleted file mode 100644
index 08ae603..0000000
--- a/ide/xcode/libpng.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,307 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		00133B080E1413E1003D4A50 /* png.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AEF0E1413E1003D4A50 /* png.c */; };
-		00133B0B0E1413E1003D4A50 /* pngerror.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AF40E1413E1003D4A50 /* pngerror.c */; };
-		00133B0C0E1413E1003D4A50 /* pnggccrd.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AF50E1413E1003D4A50 /* pnggccrd.c */; };
-		00133B0D0E1413E1003D4A50 /* pngget.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AF60E1413E1003D4A50 /* pngget.c */; };
-		00133B0E0E1413E1003D4A50 /* pngmem.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AF70E1413E1003D4A50 /* pngmem.c */; };
-		00133B0F0E1413E1003D4A50 /* pngpread.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AF90E1413E1003D4A50 /* pngpread.c */; };
-		00133B100E1413E1003D4A50 /* pngread.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AFA0E1413E1003D4A50 /* pngread.c */; };
-		00133B110E1413E1003D4A50 /* pngrio.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AFB0E1413E1003D4A50 /* pngrio.c */; };
-		00133B120E1413E1003D4A50 /* pngrtran.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AFC0E1413E1003D4A50 /* pngrtran.c */; };
-		00133B130E1413E1003D4A50 /* pngrutil.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AFD0E1413E1003D4A50 /* pngrutil.c */; };
-		00133B140E1413E1003D4A50 /* pngset.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133AFE0E1413E1003D4A50 /* pngset.c */; };
-		00133B160E1413E1003D4A50 /* pngtrans.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B010E1413E1003D4A50 /* pngtrans.c */; };
-		00133B180E1413E1003D4A50 /* pngvcrd.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B030E1413E1003D4A50 /* pngvcrd.c */; };
-		00133B190E1413E1003D4A50 /* pngwio.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B040E1413E1003D4A50 /* pngwio.c */; };
-		00133B1A0E1413E1003D4A50 /* pngwrite.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B050E1413E1003D4A50 /* pngwrite.c */; };
-		00133B1B0E1413E1003D4A50 /* pngwtran.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B060E1413E1003D4A50 /* pngwtran.c */; };
-		00133B1C0E1413E1003D4A50 /* pngwutil.c in Sources */ = {isa = PBXBuildFile; fileRef = 00133B070E1413E1003D4A50 /* pngwutil.c */; };
-		FE7B862C0948E805001B952C /* SkImageDecoder_libpng.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE7B862B0948E805001B952C /* SkImageDecoder_libpng.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		00133AEF0E1413E1003D4A50 /* png.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = png.c; path = "../../extlibs/libpng-1.2.29/png.c"; sourceTree = SOURCE_ROOT; };
-		00133AF40E1413E1003D4A50 /* pngerror.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngerror.c; path = "../../extlibs/libpng-1.2.29/pngerror.c"; sourceTree = SOURCE_ROOT; };
-		00133AF50E1413E1003D4A50 /* pnggccrd.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pnggccrd.c; path = "../../extlibs/libpng-1.2.29/pnggccrd.c"; sourceTree = SOURCE_ROOT; };
-		00133AF60E1413E1003D4A50 /* pngget.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngget.c; path = "../../extlibs/libpng-1.2.29/pngget.c"; sourceTree = SOURCE_ROOT; };
-		00133AF70E1413E1003D4A50 /* pngmem.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngmem.c; path = "../../extlibs/libpng-1.2.29/pngmem.c"; sourceTree = SOURCE_ROOT; };
-		00133AF90E1413E1003D4A50 /* pngpread.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngpread.c; path = "../../extlibs/libpng-1.2.29/pngpread.c"; sourceTree = SOURCE_ROOT; };
-		00133AFA0E1413E1003D4A50 /* pngread.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngread.c; path = "../../extlibs/libpng-1.2.29/pngread.c"; sourceTree = SOURCE_ROOT; };
-		00133AFB0E1413E1003D4A50 /* pngrio.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngrio.c; path = "../../extlibs/libpng-1.2.29/pngrio.c"; sourceTree = SOURCE_ROOT; };
-		00133AFC0E1413E1003D4A50 /* pngrtran.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngrtran.c; path = "../../extlibs/libpng-1.2.29/pngrtran.c"; sourceTree = SOURCE_ROOT; };
-		00133AFD0E1413E1003D4A50 /* pngrutil.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngrutil.c; path = "../../extlibs/libpng-1.2.29/pngrutil.c"; sourceTree = SOURCE_ROOT; };
-		00133AFE0E1413E1003D4A50 /* pngset.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngset.c; path = "../../extlibs/libpng-1.2.29/pngset.c"; sourceTree = SOURCE_ROOT; };
-		00133B010E1413E1003D4A50 /* pngtrans.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngtrans.c; path = "../../extlibs/libpng-1.2.29/pngtrans.c"; sourceTree = SOURCE_ROOT; };
-		00133B030E1413E1003D4A50 /* pngvcrd.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngvcrd.c; path = "../../extlibs/libpng-1.2.29/pngvcrd.c"; sourceTree = SOURCE_ROOT; };
-		00133B040E1413E1003D4A50 /* pngwio.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngwio.c; path = "../../extlibs/libpng-1.2.29/pngwio.c"; sourceTree = SOURCE_ROOT; };
-		00133B050E1413E1003D4A50 /* pngwrite.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngwrite.c; path = "../../extlibs/libpng-1.2.29/pngwrite.c"; sourceTree = SOURCE_ROOT; };
-		00133B060E1413E1003D4A50 /* pngwtran.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngwtran.c; path = "../../extlibs/libpng-1.2.29/pngwtran.c"; sourceTree = SOURCE_ROOT; };
-		00133B070E1413E1003D4A50 /* pngwutil.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = pngwutil.c; path = "../../extlibs/libpng-1.2.29/pngwutil.c"; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* liblibpng.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = liblibpng.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE7B862B0948E805001B952C /* SkImageDecoder_libpng.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libpng.cpp; path = ../../libs/graphics/images/SkImageDecoder_libpng.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* libpng */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AB7509460CE10057213F /* Include */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = libpng;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				00133AEF0E1413E1003D4A50 /* png.c */,
-				00133AF40E1413E1003D4A50 /* pngerror.c */,
-				00133AF50E1413E1003D4A50 /* pnggccrd.c */,
-				00133AF60E1413E1003D4A50 /* pngget.c */,
-				00133AF70E1413E1003D4A50 /* pngmem.c */,
-				00133AF90E1413E1003D4A50 /* pngpread.c */,
-				00133AFA0E1413E1003D4A50 /* pngread.c */,
-				00133AFB0E1413E1003D4A50 /* pngrio.c */,
-				00133AFC0E1413E1003D4A50 /* pngrtran.c */,
-				00133AFD0E1413E1003D4A50 /* pngrutil.c */,
-				00133AFE0E1413E1003D4A50 /* pngset.c */,
-				00133B010E1413E1003D4A50 /* pngtrans.c */,
-				00133B030E1413E1003D4A50 /* pngvcrd.c */,
-				00133B040E1413E1003D4A50 /* pngwio.c */,
-				00133B050E1413E1003D4A50 /* pngwrite.c */,
-				00133B060E1413E1003D4A50 /* pngwtran.c */,
-				00133B070E1413E1003D4A50 /* pngwutil.c */,
-				FE7B862B0948E805001B952C /* SkImageDecoder_libpng.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* liblibpng.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-		FE08AB7509460CE10057213F /* Include */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Include;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* libpng */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = FE5F4815094784400095980F /* Build configuration list for PBXNativeTarget "libpng" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = libpng;
-			productName = libpng;
-			productReference = D2AAC046055464E500DB518D /* liblibpng.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = FE5F4819094784400095980F /* Build configuration list for PBXProject "libpng" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* libpng */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC045055464E500DB518D /* libpng */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE7B862C0948E805001B952C /* SkImageDecoder_libpng.cpp in Sources */,
-				00133B080E1413E1003D4A50 /* png.c in Sources */,
-				00133B0B0E1413E1003D4A50 /* pngerror.c in Sources */,
-				00133B0C0E1413E1003D4A50 /* pnggccrd.c in Sources */,
-				00133B0D0E1413E1003D4A50 /* pngget.c in Sources */,
-				00133B0E0E1413E1003D4A50 /* pngmem.c in Sources */,
-				00133B0F0E1413E1003D4A50 /* pngpread.c in Sources */,
-				00133B100E1413E1003D4A50 /* pngread.c in Sources */,
-				00133B110E1413E1003D4A50 /* pngrio.c in Sources */,
-				00133B120E1413E1003D4A50 /* pngrtran.c in Sources */,
-				00133B130E1413E1003D4A50 /* pngrutil.c in Sources */,
-				00133B140E1413E1003D4A50 /* pngset.c in Sources */,
-				00133B160E1413E1003D4A50 /* pngtrans.c in Sources */,
-				00133B180E1413E1003D4A50 /* pngvcrd.c in Sources */,
-				00133B190E1413E1003D4A50 /* pngwio.c in Sources */,
-				00133B1A0E1413E1003D4A50 /* pngwrite.c in Sources */,
-				00133B1B0E1413E1003D4A50 /* pngwtran.c in Sources */,
-				00133B1C0E1413E1003D4A50 /* pngwutil.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		FE5F4816094784400095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = (
-					../../include/graphics,
-					../../extlibs/png,
-					../../extlibs/zlib,
-				);
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = libpng;
-				REZ_PREPROCESSOR_DEFINITIONS = "_LIB PNG_USER_CONFIG SK_FORCE_SCALARFIXED";
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		FE5F4817094784400095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = libpng;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		FE5F481A094784400095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		FE5F481B094784400095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		FE5F4815094784400095980F /* Build configuration list for PBXNativeTarget "libpng" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F4816094784400095980F /* Debug */,
-				FE5F4817094784400095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-		FE5F4819094784400095980F /* Build configuration list for PBXProject "libpng" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F481A094784400095980F /* Debug */,
-				FE5F481B094784400095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/ports-mac.xcodeproj/project.pbxproj b/ide/xcode/ports-mac.xcodeproj/project.pbxproj
deleted file mode 100644
index 5a81cc9..0000000
--- a/ide/xcode/ports-mac.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,252 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		00540DC209D04AD500307DCB /* SkTime_Unix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00540DC109D04AD500307DCB /* SkTime_Unix.cpp */; };
-		00E6E3520CCD19A900F102DB /* SkThread_pthread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00E6E3510CCD19A900F102DB /* SkThread_pthread.cpp */; };
-		00FC59C20D09F1ED0069A803 /* SkImageDecoder_libbmp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00FC59C10D09F1ED0069A803 /* SkImageDecoder_libbmp.cpp */; };
-		FE33C956094E031400C4A640 /* SkBitmap_Mac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE33C954094E031400C4A640 /* SkBitmap_Mac.cpp */; };
-		FE33C957094E031400C4A640 /* SkOSWindow_Mac.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FE33C955094E031400C4A640 /* SkOSWindow_Mac.cpp */; };
-		FE33C959094E041D00C4A640 /* skia_mac.cp in Sources */ = {isa = PBXBuildFile; fileRef = FE33C958094E041D00C4A640 /* skia_mac.cp */; };
-		FE3487430952101C003F0C3F /* SkApplication.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3487420952101C003F0C3F /* SkApplication.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		00540DC109D04AD500307DCB /* SkTime_Unix.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTime_Unix.cpp; path = ../../libs/graphics/ports/SkTime_Unix.cpp; sourceTree = SOURCE_ROOT; };
-		00B502C909DB191900A01CD6 /* SkThread_none.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkThread_none.cpp; path = ../../libs/graphics/ports/SkThread_none.cpp; sourceTree = SOURCE_ROOT; };
-		00E6E3510CCD19A900F102DB /* SkThread_pthread.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkThread_pthread.cpp; path = ../../libs/graphics/ports/SkThread_pthread.cpp; sourceTree = SOURCE_ROOT; };
-		00FC59C10D09F1ED0069A803 /* SkImageDecoder_libbmp.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libbmp.cpp; path = ../../libs/graphics/images/SkImageDecoder_libbmp.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libports-mac.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libports-mac.a"; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE33C954094E031400C4A640 /* SkBitmap_Mac.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBitmap_Mac.cpp; path = ports/SkBitmap_Mac.cpp; sourceTree = "<group>"; };
-		FE33C955094E031400C4A640 /* SkOSWindow_Mac.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOSWindow_Mac.cpp; path = ports/SkOSWindow_Mac.cpp; sourceTree = "<group>"; };
-		FE33C958094E041D00C4A640 /* skia_mac.cp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = skia_mac.cp; path = ports/skia_mac.cp; sourceTree = "<group>"; };
-		FE3487420952101C003F0C3F /* SkApplication.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SkApplication.h; path = ../../include/graphics/SkApplication.h; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* ports-mac */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = "ports-mac";
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				00FC59C10D09F1ED0069A803 /* SkImageDecoder_libbmp.cpp */,
-				00E6E3510CCD19A900F102DB /* SkThread_pthread.cpp */,
-				00B502C909DB191900A01CD6 /* SkThread_none.cpp */,
-				00540DC109D04AD500307DCB /* SkTime_Unix.cpp */,
-				FE3487420952101C003F0C3F /* SkApplication.h */,
-				FE33C958094E041D00C4A640 /* skia_mac.cp */,
-				FE33C954094E031400C4A640 /* SkBitmap_Mac.cpp */,
-				FE33C955094E031400C4A640 /* SkOSWindow_Mac.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libports-mac.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE3487430952101C003F0C3F /* SkApplication.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* ports-mac */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "ports-mac" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = "ports-mac";
-			productName = "ports-mac";
-			productReference = D2AAC046055464E500DB518D /* libports-mac.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "ports-mac" */;
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* ports-mac */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* ports-mac */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE33C956094E031400C4A640 /* SkBitmap_Mac.cpp in Sources */,
-				FE33C957094E031400C4A640 /* SkOSWindow_Mac.cpp in Sources */,
-				FE33C959094E041D00C4A640 /* skia_mac.cp in Sources */,
-				00540DC209D04AD500307DCB /* SkTime_Unix.cpp in Sources */,
-				00E6E3520CCD19A900F102DB /* SkThread_pthread.cpp in Sources */,
-				00FC59C20D09F1ED0069A803 /* SkImageDecoder_libbmp.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_BUILD_FOR_MAC;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = "ports-mac";
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = "ports-mac";
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_BUILD_FOR_MAC;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk;
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "ports-mac" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "ports-mac" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/ports.xcodeproj/project.pbxproj b/ide/xcode/ports.xcodeproj/project.pbxproj
deleted file mode 100644
index d618305..0000000
--- a/ide/xcode/ports.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,277 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		000F96970D340E3000AAF056 /* SkFontHost_gamma.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 000F96960D340E3000AAF056 /* SkFontHost_gamma.cpp */; };
-		00199D6A0AD6C5F000B087EA /* SkImageDecoder_libico.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00199D690AD6C5F000B087EA /* SkImageDecoder_libico.cpp */; };
-		0043B2A10D75B800004A0E2A /* bmpdecoderhelper.h in Headers */ = {isa = PBXBuildFile; fileRef = 0043B29F0D75B800004A0E2A /* bmpdecoderhelper.h */; };
-		0043B2DE0D75C86D004A0E2A /* SkImageDecoder_libbmp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0043B2DD0D75C86D004A0E2A /* SkImageDecoder_libbmp.cpp */; };
-		004E32230D0F288E007F9B40 /* SkMMapStream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 004E32220D0F288D007F9B40 /* SkMMapStream.cpp */; };
-		0064A06A0AE5283700F758EE /* SkFontHost_android.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0064A0690AE5283700F758EE /* SkFontHost_android.cpp */; };
-		008CFCBD0C04C10100FB4126 /* SkImageDecoder_wbmp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 008CFCBC0C04C10100FB4126 /* SkImageDecoder_wbmp.cpp */; };
-		00AC70770D0DAB9400413F47 /* SkThread_pthread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00AC70760D0DAB9400413F47 /* SkThread_pthread.cpp */; };
-		00FA424D0D7601CE00D3F086 /* bmpdecoderhelper.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00FA424C0D7601CE00D3F086 /* bmpdecoderhelper.cpp */; };
-		FEDCDF8D09C1DB5B0042D964 /* SkMemory_stdlib.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEDCDF8C09C1DB5B0042D964 /* SkMemory_stdlib.cpp */; };
-		FEDCDF9109C1DBC10042D964 /* SkDebug_stdio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEDCDF9009C1DBC10042D964 /* SkDebug_stdio.cpp */; };
-		FEEBB91809421FDD00C371A7 /* SkGlobals_global.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEEBB90E09421FDD00C371A7 /* SkGlobals_global.cpp */; };
-		FEEBB91909421FDD00C371A7 /* SkImageDecoder_Factory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEEBB90F09421FDD00C371A7 /* SkImageDecoder_Factory.cpp */; };
-		FEEBB91A09421FDD00C371A7 /* SkOSFile_stdio.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEEBB91009421FDD00C371A7 /* SkOSFile_stdio.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		000F96960D340E3000AAF056 /* SkFontHost_gamma.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_gamma.cpp; path = ../../libs/graphics/ports/SkFontHost_gamma.cpp; sourceTree = SOURCE_ROOT; };
-		00199D690AD6C5F000B087EA /* SkImageDecoder_libico.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libico.cpp; path = ../../libs/graphics/images/SkImageDecoder_libico.cpp; sourceTree = SOURCE_ROOT; };
-		0043B29F0D75B800004A0E2A /* bmpdecoderhelper.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = bmpdecoderhelper.h; path = ../../libs/graphics/images/bmpdecoderhelper.h; sourceTree = SOURCE_ROOT; };
-		0043B2DD0D75C86D004A0E2A /* SkImageDecoder_libbmp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libbmp.cpp; path = ../../libs/graphics/images/SkImageDecoder_libbmp.cpp; sourceTree = SOURCE_ROOT; };
-		004E32220D0F288D007F9B40 /* SkMMapStream.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMMapStream.cpp; path = ../../libs/graphics/images/SkMMapStream.cpp; sourceTree = SOURCE_ROOT; };
-		0064A0690AE5283700F758EE /* SkFontHost_android.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkFontHost_android.cpp; path = ../../libs/graphics/ports/SkFontHost_android.cpp; sourceTree = SOURCE_ROOT; };
-		008CFCBC0C04C10100FB4126 /* SkImageDecoder_wbmp.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_wbmp.cpp; path = ../../libs/graphics/images/SkImageDecoder_wbmp.cpp; sourceTree = SOURCE_ROOT; };
-		00AC70760D0DAB9400413F47 /* SkThread_pthread.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkThread_pthread.cpp; path = ../../libs/graphics/ports/SkThread_pthread.cpp; sourceTree = SOURCE_ROOT; };
-		00FA424C0D7601CE00D3F086 /* bmpdecoderhelper.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = bmpdecoderhelper.cpp; path = ../../libs/graphics/images/bmpdecoderhelper.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libports.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libports.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE5F473C0947737F0095980F /* SkThread_none.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkThread_none.cpp; path = ../../libs/graphics/ports/SkThread_none.cpp; sourceTree = SOURCE_ROOT; };
-		FEDCDF8C09C1DB5B0042D964 /* SkMemory_stdlib.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMemory_stdlib.cpp; path = ../../libs/corecg/SkMemory_stdlib.cpp; sourceTree = SOURCE_ROOT; };
-		FEDCDF9009C1DBC10042D964 /* SkDebug_stdio.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkDebug_stdio.cpp; path = ../../libs/corecg/SkDebug_stdio.cpp; sourceTree = SOURCE_ROOT; };
-		FEEBB90E09421FDD00C371A7 /* SkGlobals_global.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkGlobals_global.cpp; path = ../../libs/graphics/ports/SkGlobals_global.cpp; sourceTree = SOURCE_ROOT; };
-		FEEBB90F09421FDD00C371A7 /* SkImageDecoder_Factory.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_Factory.cpp; path = ../../libs/graphics/ports/SkImageDecoder_Factory.cpp; sourceTree = SOURCE_ROOT; };
-		FEEBB91009421FDD00C371A7 /* SkOSFile_stdio.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOSFile_stdio.cpp; path = ../../libs/graphics/ports/SkOSFile_stdio.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* ports */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = ports;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				00FA424C0D7601CE00D3F086 /* bmpdecoderhelper.cpp */,
-				0043B2DD0D75C86D004A0E2A /* SkImageDecoder_libbmp.cpp */,
-				0043B29F0D75B800004A0E2A /* bmpdecoderhelper.h */,
-				000F96960D340E3000AAF056 /* SkFontHost_gamma.cpp */,
-				004E32220D0F288D007F9B40 /* SkMMapStream.cpp */,
-				00AC70760D0DAB9400413F47 /* SkThread_pthread.cpp */,
-				008CFCBC0C04C10100FB4126 /* SkImageDecoder_wbmp.cpp */,
-				0064A0690AE5283700F758EE /* SkFontHost_android.cpp */,
-				00199D690AD6C5F000B087EA /* SkImageDecoder_libico.cpp */,
-				FEDCDF9009C1DBC10042D964 /* SkDebug_stdio.cpp */,
-				FEDCDF8C09C1DB5B0042D964 /* SkMemory_stdlib.cpp */,
-				FE5F473C0947737F0095980F /* SkThread_none.cpp */,
-				FEEBB90E09421FDD00C371A7 /* SkGlobals_global.cpp */,
-				FEEBB90F09421FDD00C371A7 /* SkImageDecoder_Factory.cpp */,
-				FEEBB91009421FDD00C371A7 /* SkOSFile_stdio.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libports.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				0043B2A10D75B800004A0E2A /* bmpdecoderhelper.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* ports */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "ports" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = ports;
-			productName = ports;
-			productReference = D2AAC046055464E500DB518D /* libports.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "ports" */;
-			compatibilityVersion = "Xcode 2.4";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* ports */;
-			projectDirPath = "";
-			projectRoot = ../..;
-			targets = (
-				D2AAC045055464E500DB518D /* ports */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FEEBB91809421FDD00C371A7 /* SkGlobals_global.cpp in Sources */,
-				FEEBB91909421FDD00C371A7 /* SkImageDecoder_Factory.cpp in Sources */,
-				FEEBB91A09421FDD00C371A7 /* SkOSFile_stdio.cpp in Sources */,
-				FEDCDF8D09C1DB5B0042D964 /* SkMemory_stdlib.cpp in Sources */,
-				FEDCDF9109C1DBC10042D964 /* SkDebug_stdio.cpp in Sources */,
-				00199D6A0AD6C5F000B087EA /* SkImageDecoder_libico.cpp in Sources */,
-				0064A06A0AE5283700F758EE /* SkFontHost_android.cpp in Sources */,
-				008CFCBD0C04C10100FB4126 /* SkImageDecoder_wbmp.cpp in Sources */,
-				00AC70770D0DAB9400413F47 /* SkThread_pthread.cpp in Sources */,
-				004E32230D0F288E007F9B40 /* SkMMapStream.cpp in Sources */,
-				000F96970D340E3000AAF056 /* SkFontHost_gamma.cpp in Sources */,
-				0043B2DE0D75C86D004A0E2A /* SkImageDecoder_libbmp.cpp in Sources */,
-				00FA424D0D7601CE00D3F086 /* bmpdecoderhelper.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = ports;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = ports;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_BUILD_FOR_MAC;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					SK_BUILD_FOR_MAC,
-					SK_RELEASE,
-				);
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "ports" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "ports" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/ports/SkBitmap_Mac.cpp b/ide/xcode/ports/SkBitmap_Mac.cpp
deleted file mode 100644
index 06c2b27..0000000
--- a/ide/xcode/ports/SkBitmap_Mac.cpp
+++ /dev/null
@@ -1,142 +0,0 @@
-#include "SkBitmap.h"
-#include "SkColorPriv.h"
-#include "SkMath.h"
-
-#if defined(SK_BUILD_FOR_MAC) && !defined(SK_USE_WXWIDGETS)
-
-#include <ApplicationServices/ApplicationServices.h>
-
-#ifndef __ppc__
-    #define SWAP_16BIT
-#endif
-
-static void convertGL32_to_Mac32(uint32_t dst[], const SkBitmap& bm) {
-    memcpy(dst, bm.getPixels(), bm.getSize());
-    return;
-    
-    uint32_t* stop = dst + (bm.getSize() >> 2);
-    const uint8_t* src = (const uint8_t*)bm.getPixels();
-    while (dst < stop) {
-        *dst++ = src[2] << 24 | src[1] << 16 | src[0] << 8 | src[3] << 0;
-        src += sizeof(uint32_t);
-    }
-}
-
-static void convert565_to_32(uint32_t dst[], const SkBitmap& bm) {
-    for (int y = 0; y < bm.height(); y++) {
-        const uint16_t* src = bm.getAddr16(0, y);
-        const uint16_t* stop = src + bm.width();
-        while (src < stop) {
-            unsigned c = *src++;
-            unsigned r = SkPacked16ToR32(c);
-            unsigned g = SkPacked16ToG32(c);
-            unsigned b = SkPacked16ToB32(c);
-        
-            *dst++ = (b << 24) | (g << 16) | (r << 8) | 0xFF;
-        }
-    }
-}
-
-static void convert4444_to_555(uint16_t dst[], const uint16_t src[], int count)
-{
-    const uint16_t* stop = src + count;
-    
-    while (src < stop)
-    {
-        unsigned c = *src++;
-        
-        unsigned r = SkGetPackedR4444(c);
-        unsigned g = SkGetPackedG4444(c);
-        unsigned b = SkGetPackedB4444(c);
-        // convert to 5 bits
-        r = (r << 1) | (r >> 3);
-        g = (g << 1) | (g >> 3);
-        b = (b << 1) | (b >> 3);
-        // build the 555
-        c = (r << 10) | (g << 5) | b;
-        
-#ifdef SWAP_16BIT
-        c = (c >> 8) | (c << 8);
-#endif
-        *dst++ = c;
-    }
-}
-
-#include "SkTemplates.h"
-
-static CGImageRef bitmap2imageref(const SkBitmap& bm) {
-    size_t  bitsPerComp;
-    size_t  bitsPerPixel;
-    CGBitmapInfo info;
-    CGColorSpaceRef cs = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB);
-    CGDataProviderRef data = CGDataProviderCreateWithData(NULL,
-                                                           bm.getPixels(),
-                                                           bm.getSize(),
-                                                           NULL);
-    SkAutoTCallVProc<CGDataProvider, CGDataProviderRelease> acp(data);
-    SkAutoTCallVProc<CGColorSpace, CGColorSpaceRelease> acp2(cs);
-
-    switch (bm.config()) {
-        case SkBitmap::kARGB_8888_Config:
-            bitsPerComp = 8;
-            bitsPerPixel = 32;
-            info = kCGImageAlphaPremultipliedLast;
-            break;
-        case SkBitmap::kARGB_4444_Config:
-            bitsPerComp = 4;
-            bitsPerPixel = 16;
-            info = kCGImageAlphaPremultipliedLast |  kCGBitmapByteOrder16Little;
-            break;
-#if 0   // not supported by quartz !!!
-        case SkBitmap::kRGB_565_Config:
-            bitsPerComp = 5;
-            bitsPerPixel = 16;
-            info = kCGImageAlphaNone | kCGBitmapByteOrder16Little;
-            break;
-#endif
-        default:
-            return NULL;
-    }
-
-    return CGImageCreate(bm.width(), bm.height(), bitsPerComp, bitsPerPixel,
-                         bm.rowBytes(), cs, info, data,
-                         NULL, false, kCGRenderingIntentDefault);
-}
-
-void SkBitmap::drawToPort(WindowRef wind, CGContextRef cg) const {
-	if (fPixels == NULL || fWidth == 0 || fHeight == 0) {
-		return;
-    }
-    
-    bool useQD = false;
-    if (NULL == cg) {
-        SetPortWindowPort(wind);
-        QDBeginCGContext(GetWindowPort(wind), &cg);
-        useQD = true;
-    }
-
-    SkBitmap bm;
-    if (this->config() == kRGB_565_Config) {
-        this->copyTo(&bm, kARGB_8888_Config);
-    } else {
-        bm = *this;
-    }
-    bm.lockPixels();
-
-    CGImageRef image = bitmap2imageref(bm);
-    if (image) {
-        CGRect rect;
-        rect.origin.x = rect.origin.y = 0;
-        rect.size.width = bm.width();
-        rect.size.height = bm.height();
-        
-        CGContextDrawImage(cg, rect, image);
-        CGImageRelease(image);
-    }
-
-    if (useQD) {
-        QDEndCGContext(GetWindowPort(wind), &cg);
-    }
-}
-
-#endif
diff --git a/ide/xcode/ports/SkOSWindow_Mac.cpp b/ide/xcode/ports/SkOSWindow_Mac.cpp
deleted file mode 100644
index 5184da5..0000000
--- a/ide/xcode/ports/SkOSWindow_Mac.cpp
+++ /dev/null
@@ -1,328 +0,0 @@
-#if defined(SK_BUILD_FOR_MAC) && !defined(SK_USE_WXWIDGETS)
-
-#include "SkWindow.h"
-#include "SkCanvas.h"
-#include "SkOSMenu.h"
-#include "SkTime.h"
-
-#include "SkGraphics.h"
-#include <new.h>
-
-static void (*gPrevNewHandler)();
-
-extern "C" {
-	static void sk_new_handler()
-	{
-		if (SkGraphics::SetFontCacheUsed(0))
-			return;
-		if (gPrevNewHandler)
-			gPrevNewHandler();
-		else
-			sk_throw();
-	}
-}
-
-static SkOSWindow* gCurrOSWin;
-static EventTargetRef gEventTarget;
-static EventQueueRef gCurrEventQ;
-
-#define SK_MacEventClass			FOUR_CHAR_CODE('SKec')
-#define SK_MacEventKind				FOUR_CHAR_CODE('SKek')
-#define SK_MacEventParamName		FOUR_CHAR_CODE('SKev')
-#define SK_MacEventSinkIDParamName	FOUR_CHAR_CODE('SKes')
-
-SkOSWindow::SkOSWindow(void* hWnd) : fHWND(hWnd)
-{	
-	static const EventTypeSpec  gTypes[] = {
-		{ kEventClassKeyboard,  kEventRawKeyDown			},
-        { kEventClassKeyboard,  kEventRawKeyUp              },
-		{ kEventClassMouse,		kEventMouseDown				},
-		{ kEventClassMouse,		kEventMouseDragged			},
-		{ kEventClassMouse,		kEventMouseUp				},
-		{ kEventClassTextInput, kEventTextInputUnicodeForKeyEvent   },
-		{ kEventClassWindow,	kEventWindowBoundsChanged	},
-		{ kEventClassWindow,	kEventWindowDrawContent		},
-		{ SK_MacEventClass,		SK_MacEventKind				}
-	};
-
-	EventHandlerUPP handlerUPP = NewEventHandlerUPP(SkOSWindow::EventHandler);
-	int				count = SK_ARRAY_COUNT(gTypes);
-	OSStatus		result;
-
-	result = InstallEventHandler(GetWindowEventTarget((WindowRef)hWnd), handlerUPP,
-						count, gTypes, this, nil);
-	SkASSERT(result == noErr);
-
-	gCurrOSWin = this;
-	gCurrEventQ = GetCurrentEventQueue();
-	gEventTarget = GetWindowEventTarget((WindowRef)hWnd);
-
-	static bool gOnce = true;
-	if (gOnce) {
-		gOnce = false;
-		gPrevNewHandler = set_new_handler(sk_new_handler);
-	}
-}
-
-void SkOSWindow::doPaint(void* ctx)
-{
-	this->update(NULL);
-
-	this->getBitmap().drawToPort((WindowRef)fHWND, (CGContextRef)ctx);
-}
-
-void SkOSWindow::updateSize()
-{
-	Rect	r;
-	
-	GetWindowBounds((WindowRef)fHWND, kWindowContentRgn, &r);
-	this->resize(r.right - r.left, r.bottom - r.top);
-}
-
-void SkOSWindow::onHandleInval(const SkIRect& r)
-{
-	Rect	rect;
-	
-	rect.left   = r.fLeft;
-	rect.top	= r.fTop;
-	rect.right  = r.fRight;
-	rect.bottom = r.fBottom;
-	InvalWindowRect((WindowRef)fHWND, &rect);
-}
-
-void SkOSWindow::onSetTitle(const char title[])
-{
-    CFStringRef str = CFStringCreateWithCString(NULL, title, kCFStringEncodingUTF8);
-    SetWindowTitleWithCFString((WindowRef)fHWND, str);
-    CFRelease(str);
-}
-
-void SkOSWindow::onAddMenu(const SkOSMenu* sk_menu)
-{
-}
-
-static void getparam(EventRef inEvent, OSType name, OSType type, UInt32 size, void* data)
-{
-	EventParamType  actualType;
-	UInt32			actualSize;
-	OSStatus		status;
-
-	status = GetEventParameter(inEvent, name, type, &actualType, size, &actualSize, data);
-	SkASSERT(status == noErr);
-	SkASSERT(actualType == type);
-	SkASSERT(actualSize == size);
-}
-
-enum {
-	SK_MacReturnKey		= 36,
-	SK_MacDeleteKey		= 51,
-	SK_MacEndKey		= 119,
-	SK_MacLeftKey		= 123,
-	SK_MacRightKey		= 124,
-	SK_MacDownKey		= 125,
-	SK_MacUpKey			= 126,
-    
-    SK_Mac0Key          = 0x52,
-    SK_Mac1Key          = 0x53,
-    SK_Mac2Key          = 0x54,
-    SK_Mac3Key          = 0x55,
-    SK_Mac4Key          = 0x56,
-    SK_Mac5Key          = 0x57,
-    SK_Mac6Key          = 0x58,
-    SK_Mac7Key          = 0x59,
-    SK_Mac8Key          = 0x5b,
-    SK_Mac9Key          = 0x5c
-};
-	
-static SkKey raw2key(UInt32 raw)
-{
-	static const struct {
-		UInt32  fRaw;
-		SkKey   fKey;
-	} gKeys[] = {
-		{ SK_MacUpKey,		kUp_SkKey		},
-		{ SK_MacDownKey,	kDown_SkKey		},
-		{ SK_MacLeftKey,	kLeft_SkKey		},
-		{ SK_MacRightKey,   kRight_SkKey	},
-		{ SK_MacReturnKey,  kOK_SkKey		},
-		{ SK_MacDeleteKey,  kBack_SkKey		},
-		{ SK_MacEndKey,		kEnd_SkKey		},
-        { SK_Mac0Key,       k0_SkKey        },
-        { SK_Mac1Key,       k1_SkKey        },
-        { SK_Mac2Key,       k2_SkKey        },
-        { SK_Mac3Key,       k3_SkKey        },
-        { SK_Mac4Key,       k4_SkKey        },
-        { SK_Mac5Key,       k5_SkKey        },
-        { SK_Mac6Key,       k6_SkKey        },
-        { SK_Mac7Key,       k7_SkKey        },
-        { SK_Mac8Key,       k8_SkKey        },
-        { SK_Mac9Key,       k9_SkKey        }
-	};
-	
-	for (unsigned i = 0; i < SK_ARRAY_COUNT(gKeys); i++)
-		if (gKeys[i].fRaw == raw)
-			return gKeys[i].fKey;
-	return kNONE_SkKey;
-}
-
-static void post_skmacevent()
-{
-	EventRef	ref;
-	OSStatus	status = CreateEvent(nil, SK_MacEventClass, SK_MacEventKind, 0, 0, &ref);
-	SkASSERT(status == noErr);
-	
-#if 0
-	status = SetEventParameter(ref, SK_MacEventParamName, SK_MacEventParamName, sizeof(evt), &evt);
-	SkASSERT(status == noErr);
-	status = SetEventParameter(ref, SK_MacEventSinkIDParamName, SK_MacEventSinkIDParamName, sizeof(sinkID), &sinkID);
-	SkASSERT(status == noErr);
-#endif
-	
-	EventTargetRef target = gEventTarget;
-	SetEventParameter(ref, kEventParamPostTarget, typeEventTargetRef, sizeof(target), &target);
-	SkASSERT(status == noErr);
-	
-	status = PostEventToQueue(gCurrEventQ, ref, kEventPriorityStandard);
-	SkASSERT(status == noErr);
-
-	ReleaseEvent(ref);
-}
-
-pascal OSStatus SkOSWindow::EventHandler( EventHandlerCallRef inHandler, EventRef inEvent, void* userData )
-{
-	SkOSWindow* win = (SkOSWindow*)userData;
-	OSStatus	result = eventNotHandledErr;
-	UInt32		wClass = GetEventClass(inEvent);
-	UInt32		wKind = GetEventKind(inEvent);
-
-	gCurrOSWin = win;	// will need to be in TLS. Set this so PostEvent will work
-
-	switch (wClass) {
-        case kEventClassMouse: {
-			Point   pt;
-			getparam(inEvent, kEventParamMouseLocation, typeQDPoint, sizeof(pt), &pt);
-			SetPortWindowPort((WindowRef)win->getHWND());
-			GlobalToLocal(&pt);
-
-			switch (wKind) {
-			case kEventMouseDown:
-				(void)win->handleClick(pt.h, pt.v, Click::kDown_State);
-				break;
-			case kEventMouseDragged:
-				(void)win->handleClick(pt.h, pt.v, Click::kMoved_State);
-				break;
-			case kEventMouseUp:
-				(void)win->handleClick(pt.h, pt.v, Click::kUp_State);
-				break;
-			default:
-				break;
-			}
-            break;
-		}
-        case kEventClassKeyboard:
-            if (wKind == kEventRawKeyDown) {
-                UInt32  raw;
-                getparam(inEvent, kEventParamKeyCode, typeUInt32, sizeof(raw), &raw);
-                SkKey key = raw2key(raw);
-                if (key != kNONE_SkKey)
-                    (void)win->handleKey(key);
-            } else if (wKind == kEventRawKeyUp) {
-                UInt32 raw;
-                getparam(inEvent, kEventParamKeyCode, typeUInt32, sizeof(raw), &raw);
-                SkKey key = raw2key(raw);
-                if (key != kNONE_SkKey)
-                    (void)win->handleKeyUp(key);
-            }
-            break;
-        case kEventClassTextInput:
-            if (wKind == kEventTextInputUnicodeForKeyEvent) {
-                UInt16  uni;
-                getparam(inEvent, kEventParamTextInputSendText, typeUnicodeText, sizeof(uni), &uni);
-                win->handleChar(uni);
-            }
-            break;
-        case kEventClassWindow:
-            switch (wKind) {
-                case kEventWindowBoundsChanged:
-                    win->updateSize();
-                    break;
-                case kEventWindowDrawContent: {
-                    CGContextRef cg;
-                    result = GetEventParameter(inEvent,
-                                               kEventParamCGContextRef,
-                                               typeCGContextRef,
-                                               NULL,
-                                               sizeof (CGContextRef),
-                                               NULL,
-                                               &cg);
-                    if (result != 0) {
-                        cg = NULL;
-                    }
-                    win->doPaint(cg);
-                    break;
-                }
-                default:
-                    break;
-            }
-            break;
-        case SK_MacEventClass: {
-            SkASSERT(wKind == SK_MacEventKind);
-            if (SkEvent::ProcessEvent()) {
-                    post_skmacevent();
-            }
-    #if 0
-            SkEvent*		evt;
-            SkEventSinkID	sinkID;
-            getparam(inEvent, SK_MacEventParamName, SK_MacEventParamName, sizeof(evt), &evt);
-            getparam(inEvent, SK_MacEventSinkIDParamName, SK_MacEventSinkIDParamName, sizeof(sinkID), &sinkID);
-    #endif
-            result = noErr;
-            break;
-        }
-        default:
-            break;
-	}
-	if (result == eventNotHandledErr) {
-		result = CallNextEventHandler(inHandler, inEvent);
-    }
-	return result;
-}
-
-///////////////////////////////////////////////////////////////////////////////////////
-
-void SkEvent::SignalNonEmptyQueue()
-{
-	post_skmacevent();
-//	SkDebugf("signal nonempty\n");
-}
-
-static TMTask	gTMTaskRec;
-static TMTask*	gTMTaskPtr;
-
-static void sk_timer_proc(TMTask* rec)
-{
-	SkEvent::ServiceQueueTimer();
-//	SkDebugf("timer task fired\n");
-}
-
-void SkEvent::SignalQueueTimer(SkMSec delay)
-{
-	if (gTMTaskPtr)
-	{
-		RemoveTimeTask((QElem*)gTMTaskPtr);
-		DisposeTimerUPP(gTMTaskPtr->tmAddr);
-		gTMTaskPtr = nil;
-	}
-	if (delay)
-	{
-		gTMTaskPtr = &gTMTaskRec;
-		memset(gTMTaskPtr, 0, sizeof(gTMTaskRec));
-		gTMTaskPtr->tmAddr = NewTimerUPP(sk_timer_proc);
-		OSErr err = InstallTimeTask((QElem*)gTMTaskPtr);
-//		SkDebugf("installtimetask of %d returned %d\n", delay, err);
-		PrimeTimeTask((QElem*)gTMTaskPtr, delay);
-	}
-}
-
-#endif
-
diff --git a/ide/xcode/ports/skia_mac.cp b/ide/xcode/ports/skia_mac.cp
deleted file mode 100644
index e6638d4..0000000
--- a/ide/xcode/ports/skia_mac.cp
+++ /dev/null
@@ -1,96 +0,0 @@
-#if defined(SK_BUILD_FOR_MAC) && !defined(SK_USE_WXWIDGETS)
-#include <Carbon/Carbon.h>
-#include <unistd.h>
-#include <cerrno>
-#include "SkApplication.h"
-#include "SkTypes.h"
-
-extern void get_preferred_size(int*, int*, int*, int* );
-
-int main(int argc, char* argv[])
-{
-    
-#if 0
-{
-	FILE* f = ::fopen("/whereami.txt", "w");
-	for (int i = 0; i < argc; i++)
-		fprintf(f, "[%d] %s\n", i, argv[i]);
-	::fclose(f);
-}
-#else
-// argv[0] is set to the execution path of the application, e.g. 
-// /Users/caryclark/android/device/build/ide/xcode/animatorTest/build/Debug/animatorTest.app/Contents/MacOS/animatorTest
-// the desired directory path is :
-// /Users/caryclark/android/device/jsapps
-// the variable (client-specific) part is :
-// /Users/caryclark/android/
-// since different applications share this library, they only have in common:
-// {client}/device/build/ide/xcode/{application}
-{
-	const char* applicationPath = argv[0];
-	const char* common = strstr(applicationPath, "build/ide/xcode/");
-	const char systemParent[] = "apps/"; 
-	if (common != 0) {
-		size_t prefixLength = common - applicationPath;
-		char* workingDirectory = new char[prefixLength + sizeof(systemParent)];
-		strncpy(workingDirectory, applicationPath, prefixLength);
-		strcpy(&workingDirectory[prefixLength], systemParent);
-		int error = chdir(workingDirectory);
-		if (error != 0) {
-			error = errno;
-			SkASSERT(error != ENOENT);
-			SkASSERT(error != ENOTDIR);
-			SkASSERT(error != EACCES);
-			SkASSERT(error != EIO);
-			SkASSERT(0);
-		}
-		delete workingDirectory;
-	}
-}
-#endif
-	IBNibRef 		nibRef;
-    WindowRef 		window;
-    
-    OSStatus		err;
-
-    // Create a Nib reference passing the name of the nib file (without the .nib extension)
-    // CreateNibReference only searches into the application bundle.
-    err = CreateNibReference(CFSTR("main"), &nibRef);
-    require_noerr( err, CantGetNibRef );
-    
-    // Once the nib reference is created, set the menu bar. "MainMenu" is the name of the menu bar
-    // object. This name is set in InterfaceBuilder when the nib is created.
-    err = SetMenuBarFromNib(nibRef, CFSTR("MenuBar"));
-    require_noerr( err, CantSetMenuBar );
-    
-    // Then create a window. "MainWindow" is the name of the window object. This name is set in 
-    // InterfaceBuilder when the nib is created.
-    err = CreateWindowFromNib(nibRef, CFSTR("MainWindow"), &window);
-    require_noerr( err, CantCreateWindow );
-
-    // We don't need the nib reference anymore.
-    DisposeNibReference(nibRef);
-    {
-	// if we get here, we can start our normal Skia sequence
-	application_init();
-	(void)create_sk_window(window);
-        int x =0, y =0, width =640, height=480;
-        get_preferred_size(&x, &y, &width, &height);
-        MoveWindow(window, x, y, false);
-        SizeWindow(window, width, height, false);
-    }
-    // The window was created hidden so show it.
-    ShowWindow( window );
-
-    // Call the event loop
-    RunApplicationEventLoop();
-	
-	application_term();
-
-CantCreateWindow:
-CantSetMenuBar:
-CantGetNibRef:
-	return err;
-}
-
-#endif
\ No newline at end of file
diff --git a/ide/xcode/pvjpeg.xcodeproj/project.pbxproj b/ide/xcode/pvjpeg.xcodeproj/project.pbxproj
deleted file mode 100644
index 5d09e2d..0000000
--- a/ide/xcode/pvjpeg.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,261 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 44;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		007ECA0E0DA67F7B0086775A /* jpgdec_bitstream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA010DA67F7B0086775A /* jpgdec_bitstream.cpp */; };
-		007ECA0F0DA67F7B0086775A /* jpgdec_cint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA020DA67F7B0086775A /* jpgdec_cint.cpp */; };
-		007ECA100DA67F7B0086775A /* jpgdec_colorconv.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA030DA67F7B0086775A /* jpgdec_colorconv.cpp */; };
-		007ECA110DA67F7B0086775A /* jpgdec_ct.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA040DA67F7B0086775A /* jpgdec_ct.cpp */; };
-		007ECA120DA67F7B0086775A /* jpgdec_decoder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA050DA67F7B0086775A /* jpgdec_decoder.cpp */; };
-		007ECA130DA67F7B0086775A /* jpgdec_header.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA060DA67F7B0086775A /* jpgdec_header.cpp */; };
-		007ECA140DA67F7B0086775A /* jpgdec_huffman.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA070DA67F7B0086775A /* jpgdec_huffman.cpp */; };
-		007ECA150DA67F7B0086775A /* jpgdec_idctp.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA080DA67F7B0086775A /* jpgdec_idctp.cpp */; };
-		007ECA160DA67F7B0086775A /* jpgdec_idcts.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA090DA67F7B0086775A /* jpgdec_idcts.cpp */; };
-		007ECA170DA67F7B0086775A /* jpgdec_scan.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA0A0DA67F7B0086775A /* jpgdec_scan.cpp */; };
-		007ECA180DA67F7B0086775A /* jpgdec_table.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA0B0DA67F7B0086775A /* jpgdec_table.cpp */; };
-		007ECA190DA67F7B0086775A /* jpgdec_utils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA0C0DA67F7B0086775A /* jpgdec_utils.cpp */; };
-		007ECA1A0DA67F7B0086775A /* pvjpgdecoder_factory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA0D0DA67F7B0086775A /* pvjpgdecoder_factory.cpp */; };
-		007ECA500DA683160086775A /* SkImageDecoder_libpvjpeg.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 007ECA4F0DA683160086775A /* SkImageDecoder_libpvjpeg.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		007ECA010DA67F7B0086775A /* jpgdec_bitstream.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_bitstream.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_bitstream.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA020DA67F7B0086775A /* jpgdec_cint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_cint.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_cint.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA030DA67F7B0086775A /* jpgdec_colorconv.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_colorconv.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_colorconv.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA040DA67F7B0086775A /* jpgdec_ct.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_ct.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_ct.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA050DA67F7B0086775A /* jpgdec_decoder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_decoder.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_decoder.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA060DA67F7B0086775A /* jpgdec_header.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_header.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_header.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA070DA67F7B0086775A /* jpgdec_huffman.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_huffman.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_huffman.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA080DA67F7B0086775A /* jpgdec_idctp.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_idctp.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_idctp.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA090DA67F7B0086775A /* jpgdec_idcts.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_idcts.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_idcts.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA0A0DA67F7B0086775A /* jpgdec_scan.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_scan.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_scan.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA0B0DA67F7B0086775A /* jpgdec_table.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_table.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_table.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA0C0DA67F7B0086775A /* jpgdec_utils.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = jpgdec_utils.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/jpgdec_utils.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA0D0DA67F7B0086775A /* pvjpgdecoder_factory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = pvjpgdecoder_factory.cpp; path = ../../extlibs/pv/codecs_v2/image/jpeg/dec/src/pvjpgdecoder_factory.cpp; sourceTree = SOURCE_ROOT; };
-		007ECA4F0DA683160086775A /* SkImageDecoder_libpvjpeg.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageDecoder_libpvjpeg.cpp; path = ../../libs/graphics/images/SkImageDecoder_libpvjpeg.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libpvjpeg.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libpvjpeg.a; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* pvjpeg */ = {
-			isa = PBXGroup;
-			children = (
-				007ECA4F0DA683160086775A /* SkImageDecoder_libpvjpeg.cpp */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = pvjpeg;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				007ECA010DA67F7B0086775A /* jpgdec_bitstream.cpp */,
-				007ECA020DA67F7B0086775A /* jpgdec_cint.cpp */,
-				007ECA030DA67F7B0086775A /* jpgdec_colorconv.cpp */,
-				007ECA040DA67F7B0086775A /* jpgdec_ct.cpp */,
-				007ECA050DA67F7B0086775A /* jpgdec_decoder.cpp */,
-				007ECA060DA67F7B0086775A /* jpgdec_header.cpp */,
-				007ECA070DA67F7B0086775A /* jpgdec_huffman.cpp */,
-				007ECA080DA67F7B0086775A /* jpgdec_idctp.cpp */,
-				007ECA090DA67F7B0086775A /* jpgdec_idcts.cpp */,
-				007ECA0A0DA67F7B0086775A /* jpgdec_scan.cpp */,
-				007ECA0B0DA67F7B0086775A /* jpgdec_table.cpp */,
-				007ECA0C0DA67F7B0086775A /* jpgdec_utils.cpp */,
-				007ECA0D0DA67F7B0086775A /* pvjpgdecoder_factory.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libpvjpeg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* pvjpeg */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "pvjpeg" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = pvjpeg;
-			productName = pvjpeg;
-			productReference = D2AAC046055464E500DB518D /* libpvjpeg.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "pvjpeg" */;
-			compatibilityVersion = "Xcode 3.0";
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* pvjpeg */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				D2AAC045055464E500DB518D /* pvjpeg */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				007ECA0E0DA67F7B0086775A /* jpgdec_bitstream.cpp in Sources */,
-				007ECA0F0DA67F7B0086775A /* jpgdec_cint.cpp in Sources */,
-				007ECA100DA67F7B0086775A /* jpgdec_colorconv.cpp in Sources */,
-				007ECA110DA67F7B0086775A /* jpgdec_ct.cpp in Sources */,
-				007ECA120DA67F7B0086775A /* jpgdec_decoder.cpp in Sources */,
-				007ECA130DA67F7B0086775A /* jpgdec_header.cpp in Sources */,
-				007ECA140DA67F7B0086775A /* jpgdec_huffman.cpp in Sources */,
-				007ECA150DA67F7B0086775A /* jpgdec_idctp.cpp in Sources */,
-				007ECA160DA67F7B0086775A /* jpgdec_idcts.cpp in Sources */,
-				007ECA170DA67F7B0086775A /* jpgdec_scan.cpp in Sources */,
-				007ECA180DA67F7B0086775A /* jpgdec_table.cpp in Sources */,
-				007ECA190DA67F7B0086775A /* jpgdec_utils.cpp in Sources */,
-				007ECA1A0DA67F7B0086775A /* pvjpgdecoder_factory.cpp in Sources */,
-				007ECA500DA683160086775A /* SkImageDecoder_libpvjpeg.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = pvjpeg;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = pvjpeg;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_OBJC_EXCEPTIONS = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = "USE_PV_OSCL_LIB=0";
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../extlibs/pv/** ../../include/corecg ../../include/graphics";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_ENABLE_CPP_EXCEPTIONS = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_OBJC_EXCEPTIONS = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = "USE_PV_OSCL_LIB=0";
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				PREBINDING = NO;
-				SDKROOT = "$(DEVELOPER_SDK_DIR)/MacOSX10.5.sdk";
-				USER_HEADER_SEARCH_PATHS = "../../extlibs/pv/** ../../include/corecg ../../include/graphics";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "pvjpeg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "pvjpeg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/svg.xcodeproj/project.pbxproj b/ide/xcode/svg.xcodeproj/project.pbxproj
deleted file mode 100644
index c4374eb..0000000
--- a/ide/xcode/svg.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,435 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		002843AB09DDC030002E9CB0 /* SkSVGCircle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028437609DDC02F002E9CB0 /* SkSVGCircle.cpp */; };
-		002843AC09DDC030002E9CB0 /* SkSVGCircle.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028437709DDC02F002E9CB0 /* SkSVGCircle.h */; };
-		002843AD09DDC030002E9CB0 /* SkSVGClipPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028437809DDC02F002E9CB0 /* SkSVGClipPath.cpp */; };
-		002843AE09DDC030002E9CB0 /* SkSVGClipPath.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028437909DDC02F002E9CB0 /* SkSVGClipPath.h */; };
-		002843AF09DDC030002E9CB0 /* SkSVGDefs.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028437A09DDC02F002E9CB0 /* SkSVGDefs.cpp */; };
-		002843B009DDC030002E9CB0 /* SkSVGDefs.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028437B09DDC02F002E9CB0 /* SkSVGDefs.h */; };
-		002843B109DDC030002E9CB0 /* SkSVGElements.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028437C09DDC02F002E9CB0 /* SkSVGElements.cpp */; };
-		002843B209DDC030002E9CB0 /* SkSVGElements.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028437D09DDC02F002E9CB0 /* SkSVGElements.h */; };
-		002843B309DDC030002E9CB0 /* SkSVGEllipse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028437E09DDC02F002E9CB0 /* SkSVGEllipse.cpp */; };
-		002843B409DDC030002E9CB0 /* SkSVGEllipse.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028437F09DDC02F002E9CB0 /* SkSVGEllipse.h */; };
-		002843B509DDC030002E9CB0 /* SkSVGFeColorMatrix.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438009DDC02F002E9CB0 /* SkSVGFeColorMatrix.cpp */; };
-		002843B609DDC030002E9CB0 /* SkSVGFeColorMatrix.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438109DDC02F002E9CB0 /* SkSVGFeColorMatrix.h */; };
-		002843B709DDC030002E9CB0 /* SkSVGFilter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438209DDC02F002E9CB0 /* SkSVGFilter.cpp */; };
-		002843B809DDC030002E9CB0 /* SkSVGFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438309DDC02F002E9CB0 /* SkSVGFilter.h */; };
-		002843B909DDC030002E9CB0 /* SkSVGG.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438409DDC02F002E9CB0 /* SkSVGG.cpp */; };
-		002843BA09DDC030002E9CB0 /* SkSVGG.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438509DDC02F002E9CB0 /* SkSVGG.h */; };
-		002843BB09DDC030002E9CB0 /* SkSVGGradient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438609DDC02F002E9CB0 /* SkSVGGradient.cpp */; };
-		002843BC09DDC030002E9CB0 /* SkSVGGradient.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438709DDC02F002E9CB0 /* SkSVGGradient.h */; };
-		002843BD09DDC030002E9CB0 /* SkSVGGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438809DDC02F002E9CB0 /* SkSVGGroup.cpp */; };
-		002843BE09DDC030002E9CB0 /* SkSVGGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438909DDC02F002E9CB0 /* SkSVGGroup.h */; };
-		002843BF09DDC030002E9CB0 /* SkSVGImage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438A09DDC02F002E9CB0 /* SkSVGImage.cpp */; };
-		002843C009DDC030002E9CB0 /* SkSVGImage.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438B09DDC02F002E9CB0 /* SkSVGImage.h */; };
-		002843C109DDC030002E9CB0 /* SkSVGLine.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438C09DDC02F002E9CB0 /* SkSVGLine.cpp */; };
-		002843C209DDC030002E9CB0 /* SkSVGLine.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438D09DDC02F002E9CB0 /* SkSVGLine.h */; };
-		002843C309DDC030002E9CB0 /* SkSVGLinearGradient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028438E09DDC02F002E9CB0 /* SkSVGLinearGradient.cpp */; };
-		002843C409DDC030002E9CB0 /* SkSVGLinearGradient.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028438F09DDC02F002E9CB0 /* SkSVGLinearGradient.h */; };
-		002843C509DDC030002E9CB0 /* SkSVGMask.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439009DDC02F002E9CB0 /* SkSVGMask.cpp */; };
-		002843C609DDC030002E9CB0 /* SkSVGMask.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439109DDC02F002E9CB0 /* SkSVGMask.h */; };
-		002843C709DDC030002E9CB0 /* SkSVGMetadata.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439209DDC02F002E9CB0 /* SkSVGMetadata.cpp */; };
-		002843C809DDC030002E9CB0 /* SkSVGMetadata.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439309DDC02F002E9CB0 /* SkSVGMetadata.h */; };
-		002843C909DDC030002E9CB0 /* SkSVGPaintState.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439409DDC02F002E9CB0 /* SkSVGPaintState.cpp */; };
-		002843CA09DDC030002E9CB0 /* SkSVGParser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439509DDC02F002E9CB0 /* SkSVGParser.cpp */; };
-		002843CB09DDC030002E9CB0 /* SkSVGPath.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439609DDC02F002E9CB0 /* SkSVGPath.cpp */; };
-		002843CC09DDC030002E9CB0 /* SkSVGPath.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439709DDC02F002E9CB0 /* SkSVGPath.h */; };
-		002843CD09DDC030002E9CB0 /* SkSVGPolygon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439809DDC02F002E9CB0 /* SkSVGPolygon.cpp */; };
-		002843CE09DDC030002E9CB0 /* SkSVGPolygon.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439909DDC02F002E9CB0 /* SkSVGPolygon.h */; };
-		002843CF09DDC030002E9CB0 /* SkSVGPolyline.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439A09DDC02F002E9CB0 /* SkSVGPolyline.cpp */; };
-		002843D009DDC030002E9CB0 /* SkSVGPolyline.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439B09DDC02F002E9CB0 /* SkSVGPolyline.h */; };
-		002843D109DDC030002E9CB0 /* SkSVGRadialGradient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439C09DDC02F002E9CB0 /* SkSVGRadialGradient.cpp */; };
-		002843D209DDC030002E9CB0 /* SkSVGRadialGradient.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439D09DDC02F002E9CB0 /* SkSVGRadialGradient.h */; };
-		002843D309DDC030002E9CB0 /* SkSVGRect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0028439E09DDC02F002E9CB0 /* SkSVGRect.cpp */; };
-		002843D409DDC030002E9CB0 /* SkSVGRect.h in Headers */ = {isa = PBXBuildFile; fileRef = 0028439F09DDC02F002E9CB0 /* SkSVGRect.h */; };
-		002843D509DDC030002E9CB0 /* SkSVGStop.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002843A009DDC02F002E9CB0 /* SkSVGStop.cpp */; };
-		002843D609DDC030002E9CB0 /* SkSVGStop.h in Headers */ = {isa = PBXBuildFile; fileRef = 002843A109DDC02F002E9CB0 /* SkSVGStop.h */; };
-		002843D709DDC030002E9CB0 /* SkSVGSVG.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002843A209DDC02F002E9CB0 /* SkSVGSVG.cpp */; };
-		002843D809DDC030002E9CB0 /* SkSVGSVG.h in Headers */ = {isa = PBXBuildFile; fileRef = 002843A309DDC02F002E9CB0 /* SkSVGSVG.h */; };
-		002843D909DDC030002E9CB0 /* SkSVGSymbol.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002843A409DDC02F002E9CB0 /* SkSVGSymbol.cpp */; };
-		002843DA09DDC030002E9CB0 /* SkSVGSymbol.h in Headers */ = {isa = PBXBuildFile; fileRef = 002843A509DDC02F002E9CB0 /* SkSVGSymbol.h */; };
-		002843DB09DDC030002E9CB0 /* SkSVGText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002843A609DDC02F002E9CB0 /* SkSVGText.cpp */; };
-		002843DC09DDC030002E9CB0 /* SkSVGText.h in Headers */ = {isa = PBXBuildFile; fileRef = 002843A709DDC02F002E9CB0 /* SkSVGText.h */; };
-		002843DD09DDC030002E9CB0 /* SkSVGUse.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 002843A809DDC02F002E9CB0 /* SkSVGUse.cpp */; };
-		002843DE09DDC030002E9CB0 /* SkSVGUse.h in Headers */ = {isa = PBXBuildFile; fileRef = 002843A909DDC02F002E9CB0 /* SkSVGUse.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXBuildStyle section */
-		014CEA520018CE5811CA2923 /* Debug */ = {
-			isa = PBXBuildStyle;
-			buildSettings = {
-			};
-			name = Debug;
-		};
-		014CEA530018CE5811CA2923 /* Release */ = {
-			isa = PBXBuildStyle;
-			buildSettings = {
-			};
-			name = Release;
-		};
-/* End PBXBuildStyle section */
-
-/* Begin PBXFileReference section */
-		0028437609DDC02F002E9CB0 /* SkSVGCircle.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGCircle.cpp; sourceTree = "<group>"; };
-		0028437709DDC02F002E9CB0 /* SkSVGCircle.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGCircle.h; sourceTree = "<group>"; };
-		0028437809DDC02F002E9CB0 /* SkSVGClipPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGClipPath.cpp; sourceTree = "<group>"; };
-		0028437909DDC02F002E9CB0 /* SkSVGClipPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGClipPath.h; sourceTree = "<group>"; };
-		0028437A09DDC02F002E9CB0 /* SkSVGDefs.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGDefs.cpp; sourceTree = "<group>"; };
-		0028437B09DDC02F002E9CB0 /* SkSVGDefs.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGDefs.h; sourceTree = "<group>"; };
-		0028437C09DDC02F002E9CB0 /* SkSVGElements.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGElements.cpp; sourceTree = "<group>"; };
-		0028437D09DDC02F002E9CB0 /* SkSVGElements.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGElements.h; sourceTree = "<group>"; };
-		0028437E09DDC02F002E9CB0 /* SkSVGEllipse.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGEllipse.cpp; sourceTree = "<group>"; };
-		0028437F09DDC02F002E9CB0 /* SkSVGEllipse.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGEllipse.h; sourceTree = "<group>"; };
-		0028438009DDC02F002E9CB0 /* SkSVGFeColorMatrix.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGFeColorMatrix.cpp; sourceTree = "<group>"; };
-		0028438109DDC02F002E9CB0 /* SkSVGFeColorMatrix.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGFeColorMatrix.h; sourceTree = "<group>"; };
-		0028438209DDC02F002E9CB0 /* SkSVGFilter.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGFilter.cpp; sourceTree = "<group>"; };
-		0028438309DDC02F002E9CB0 /* SkSVGFilter.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGFilter.h; sourceTree = "<group>"; };
-		0028438409DDC02F002E9CB0 /* SkSVGG.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGG.cpp; sourceTree = "<group>"; };
-		0028438509DDC02F002E9CB0 /* SkSVGG.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGG.h; sourceTree = "<group>"; };
-		0028438609DDC02F002E9CB0 /* SkSVGGradient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGGradient.cpp; sourceTree = "<group>"; };
-		0028438709DDC02F002E9CB0 /* SkSVGGradient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGGradient.h; sourceTree = "<group>"; };
-		0028438809DDC02F002E9CB0 /* SkSVGGroup.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGGroup.cpp; sourceTree = "<group>"; };
-		0028438909DDC02F002E9CB0 /* SkSVGGroup.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGGroup.h; sourceTree = "<group>"; };
-		0028438A09DDC02F002E9CB0 /* SkSVGImage.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGImage.cpp; sourceTree = "<group>"; };
-		0028438B09DDC02F002E9CB0 /* SkSVGImage.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGImage.h; sourceTree = "<group>"; };
-		0028438C09DDC02F002E9CB0 /* SkSVGLine.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGLine.cpp; sourceTree = "<group>"; };
-		0028438D09DDC02F002E9CB0 /* SkSVGLine.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGLine.h; sourceTree = "<group>"; };
-		0028438E09DDC02F002E9CB0 /* SkSVGLinearGradient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGLinearGradient.cpp; sourceTree = "<group>"; };
-		0028438F09DDC02F002E9CB0 /* SkSVGLinearGradient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGLinearGradient.h; sourceTree = "<group>"; };
-		0028439009DDC02F002E9CB0 /* SkSVGMask.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGMask.cpp; sourceTree = "<group>"; };
-		0028439109DDC02F002E9CB0 /* SkSVGMask.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGMask.h; sourceTree = "<group>"; };
-		0028439209DDC02F002E9CB0 /* SkSVGMetadata.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGMetadata.cpp; sourceTree = "<group>"; };
-		0028439309DDC02F002E9CB0 /* SkSVGMetadata.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGMetadata.h; sourceTree = "<group>"; };
-		0028439409DDC02F002E9CB0 /* SkSVGPaintState.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGPaintState.cpp; sourceTree = "<group>"; };
-		0028439509DDC02F002E9CB0 /* SkSVGParser.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGParser.cpp; sourceTree = "<group>"; };
-		0028439609DDC02F002E9CB0 /* SkSVGPath.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGPath.cpp; sourceTree = "<group>"; };
-		0028439709DDC02F002E9CB0 /* SkSVGPath.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGPath.h; sourceTree = "<group>"; };
-		0028439809DDC02F002E9CB0 /* SkSVGPolygon.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGPolygon.cpp; sourceTree = "<group>"; };
-		0028439909DDC02F002E9CB0 /* SkSVGPolygon.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGPolygon.h; sourceTree = "<group>"; };
-		0028439A09DDC02F002E9CB0 /* SkSVGPolyline.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGPolyline.cpp; sourceTree = "<group>"; };
-		0028439B09DDC02F002E9CB0 /* SkSVGPolyline.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGPolyline.h; sourceTree = "<group>"; };
-		0028439C09DDC02F002E9CB0 /* SkSVGRadialGradient.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGRadialGradient.cpp; sourceTree = "<group>"; };
-		0028439D09DDC02F002E9CB0 /* SkSVGRadialGradient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGRadialGradient.h; sourceTree = "<group>"; };
-		0028439E09DDC02F002E9CB0 /* SkSVGRect.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGRect.cpp; sourceTree = "<group>"; };
-		0028439F09DDC02F002E9CB0 /* SkSVGRect.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGRect.h; sourceTree = "<group>"; };
-		002843A009DDC02F002E9CB0 /* SkSVGStop.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGStop.cpp; sourceTree = "<group>"; };
-		002843A109DDC02F002E9CB0 /* SkSVGStop.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGStop.h; sourceTree = "<group>"; };
-		002843A209DDC02F002E9CB0 /* SkSVGSVG.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGSVG.cpp; sourceTree = "<group>"; };
-		002843A309DDC02F002E9CB0 /* SkSVGSVG.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGSVG.h; sourceTree = "<group>"; };
-		002843A409DDC02F002E9CB0 /* SkSVGSymbol.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGSymbol.cpp; sourceTree = "<group>"; };
-		002843A509DDC02F002E9CB0 /* SkSVGSymbol.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGSymbol.h; sourceTree = "<group>"; };
-		002843A609DDC02F002E9CB0 /* SkSVGText.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGText.cpp; sourceTree = "<group>"; };
-		002843A709DDC02F002E9CB0 /* SkSVGText.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGText.h; sourceTree = "<group>"; };
-		002843A809DDC02F002E9CB0 /* SkSVGUse.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = SkSVGUse.cpp; sourceTree = "<group>"; };
-		002843A909DDC02F002E9CB0 /* SkSVGUse.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = SkSVGUse.h; sourceTree = "<group>"; };
-		D2AAC046055464E500DB518D /* libsvg.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libsvg.a; sourceTree = BUILT_PRODUCTS_DIR; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		0028437409DDC02F002E9CB0 /* svg */ = {
-			isa = PBXGroup;
-			children = (
-				0028437609DDC02F002E9CB0 /* SkSVGCircle.cpp */,
-				0028437709DDC02F002E9CB0 /* SkSVGCircle.h */,
-				0028437809DDC02F002E9CB0 /* SkSVGClipPath.cpp */,
-				0028437909DDC02F002E9CB0 /* SkSVGClipPath.h */,
-				0028437A09DDC02F002E9CB0 /* SkSVGDefs.cpp */,
-				0028437B09DDC02F002E9CB0 /* SkSVGDefs.h */,
-				0028437C09DDC02F002E9CB0 /* SkSVGElements.cpp */,
-				0028437D09DDC02F002E9CB0 /* SkSVGElements.h */,
-				0028437E09DDC02F002E9CB0 /* SkSVGEllipse.cpp */,
-				0028437F09DDC02F002E9CB0 /* SkSVGEllipse.h */,
-				0028438009DDC02F002E9CB0 /* SkSVGFeColorMatrix.cpp */,
-				0028438109DDC02F002E9CB0 /* SkSVGFeColorMatrix.h */,
-				0028438209DDC02F002E9CB0 /* SkSVGFilter.cpp */,
-				0028438309DDC02F002E9CB0 /* SkSVGFilter.h */,
-				0028438409DDC02F002E9CB0 /* SkSVGG.cpp */,
-				0028438509DDC02F002E9CB0 /* SkSVGG.h */,
-				0028438609DDC02F002E9CB0 /* SkSVGGradient.cpp */,
-				0028438709DDC02F002E9CB0 /* SkSVGGradient.h */,
-				0028438809DDC02F002E9CB0 /* SkSVGGroup.cpp */,
-				0028438909DDC02F002E9CB0 /* SkSVGGroup.h */,
-				0028438A09DDC02F002E9CB0 /* SkSVGImage.cpp */,
-				0028438B09DDC02F002E9CB0 /* SkSVGImage.h */,
-				0028438C09DDC02F002E9CB0 /* SkSVGLine.cpp */,
-				0028438D09DDC02F002E9CB0 /* SkSVGLine.h */,
-				0028438E09DDC02F002E9CB0 /* SkSVGLinearGradient.cpp */,
-				0028438F09DDC02F002E9CB0 /* SkSVGLinearGradient.h */,
-				0028439009DDC02F002E9CB0 /* SkSVGMask.cpp */,
-				0028439109DDC02F002E9CB0 /* SkSVGMask.h */,
-				0028439209DDC02F002E9CB0 /* SkSVGMetadata.cpp */,
-				0028439309DDC02F002E9CB0 /* SkSVGMetadata.h */,
-				0028439409DDC02F002E9CB0 /* SkSVGPaintState.cpp */,
-				0028439509DDC02F002E9CB0 /* SkSVGParser.cpp */,
-				0028439609DDC02F002E9CB0 /* SkSVGPath.cpp */,
-				0028439709DDC02F002E9CB0 /* SkSVGPath.h */,
-				0028439809DDC02F002E9CB0 /* SkSVGPolygon.cpp */,
-				0028439909DDC02F002E9CB0 /* SkSVGPolygon.h */,
-				0028439A09DDC02F002E9CB0 /* SkSVGPolyline.cpp */,
-				0028439B09DDC02F002E9CB0 /* SkSVGPolyline.h */,
-				0028439C09DDC02F002E9CB0 /* SkSVGRadialGradient.cpp */,
-				0028439D09DDC02F002E9CB0 /* SkSVGRadialGradient.h */,
-				0028439E09DDC02F002E9CB0 /* SkSVGRect.cpp */,
-				0028439F09DDC02F002E9CB0 /* SkSVGRect.h */,
-				002843A009DDC02F002E9CB0 /* SkSVGStop.cpp */,
-				002843A109DDC02F002E9CB0 /* SkSVGStop.h */,
-				002843A209DDC02F002E9CB0 /* SkSVGSVG.cpp */,
-				002843A309DDC02F002E9CB0 /* SkSVGSVG.h */,
-				002843A409DDC02F002E9CB0 /* SkSVGSymbol.cpp */,
-				002843A509DDC02F002E9CB0 /* SkSVGSymbol.h */,
-				002843A609DDC02F002E9CB0 /* SkSVGText.cpp */,
-				002843A709DDC02F002E9CB0 /* SkSVGText.h */,
-				002843A809DDC02F002E9CB0 /* SkSVGUse.cpp */,
-				002843A909DDC02F002E9CB0 /* SkSVGUse.h */,
-			);
-			name = svg;
-			path = ../../libs/graphics/svg;
-			sourceTree = SOURCE_ROOT;
-		};
-		08FB7794FE84155DC02AAC07 /* svg */ = {
-			isa = PBXGroup;
-			children = (
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = svg;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				0028437409DDC02F002E9CB0 /* svg */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libsvg.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				002843AC09DDC030002E9CB0 /* SkSVGCircle.h in Headers */,
-				002843AE09DDC030002E9CB0 /* SkSVGClipPath.h in Headers */,
-				002843B009DDC030002E9CB0 /* SkSVGDefs.h in Headers */,
-				002843B209DDC030002E9CB0 /* SkSVGElements.h in Headers */,
-				002843B409DDC030002E9CB0 /* SkSVGEllipse.h in Headers */,
-				002843B609DDC030002E9CB0 /* SkSVGFeColorMatrix.h in Headers */,
-				002843B809DDC030002E9CB0 /* SkSVGFilter.h in Headers */,
-				002843BA09DDC030002E9CB0 /* SkSVGG.h in Headers */,
-				002843BC09DDC030002E9CB0 /* SkSVGGradient.h in Headers */,
-				002843BE09DDC030002E9CB0 /* SkSVGGroup.h in Headers */,
-				002843C009DDC030002E9CB0 /* SkSVGImage.h in Headers */,
-				002843C209DDC030002E9CB0 /* SkSVGLine.h in Headers */,
-				002843C409DDC030002E9CB0 /* SkSVGLinearGradient.h in Headers */,
-				002843C609DDC030002E9CB0 /* SkSVGMask.h in Headers */,
-				002843C809DDC030002E9CB0 /* SkSVGMetadata.h in Headers */,
-				002843CC09DDC030002E9CB0 /* SkSVGPath.h in Headers */,
-				002843CE09DDC030002E9CB0 /* SkSVGPolygon.h in Headers */,
-				002843D009DDC030002E9CB0 /* SkSVGPolyline.h in Headers */,
-				002843D209DDC030002E9CB0 /* SkSVGRadialGradient.h in Headers */,
-				002843D409DDC030002E9CB0 /* SkSVGRect.h in Headers */,
-				002843D609DDC030002E9CB0 /* SkSVGStop.h in Headers */,
-				002843D809DDC030002E9CB0 /* SkSVGSVG.h in Headers */,
-				002843DA09DDC030002E9CB0 /* SkSVGSymbol.h in Headers */,
-				002843DC09DDC030002E9CB0 /* SkSVGText.h in Headers */,
-				002843DE09DDC030002E9CB0 /* SkSVGUse.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* svg */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "svg" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			buildSettings = {
-			};
-			dependencies = (
-			);
-			name = svg;
-			productName = svg;
-			productReference = D2AAC046055464E500DB518D /* libsvg.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "svg" */;
-			buildSettings = {
-			};
-			buildStyles = (
-				014CEA520018CE5811CA2923 /* Debug */,
-				014CEA530018CE5811CA2923 /* Release */,
-			);
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* svg */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* svg */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				002843AB09DDC030002E9CB0 /* SkSVGCircle.cpp in Sources */,
-				002843AD09DDC030002E9CB0 /* SkSVGClipPath.cpp in Sources */,
-				002843AF09DDC030002E9CB0 /* SkSVGDefs.cpp in Sources */,
-				002843B109DDC030002E9CB0 /* SkSVGElements.cpp in Sources */,
-				002843B309DDC030002E9CB0 /* SkSVGEllipse.cpp in Sources */,
-				002843B509DDC030002E9CB0 /* SkSVGFeColorMatrix.cpp in Sources */,
-				002843B709DDC030002E9CB0 /* SkSVGFilter.cpp in Sources */,
-				002843B909DDC030002E9CB0 /* SkSVGG.cpp in Sources */,
-				002843BB09DDC030002E9CB0 /* SkSVGGradient.cpp in Sources */,
-				002843BD09DDC030002E9CB0 /* SkSVGGroup.cpp in Sources */,
-				002843BF09DDC030002E9CB0 /* SkSVGImage.cpp in Sources */,
-				002843C109DDC030002E9CB0 /* SkSVGLine.cpp in Sources */,
-				002843C309DDC030002E9CB0 /* SkSVGLinearGradient.cpp in Sources */,
-				002843C509DDC030002E9CB0 /* SkSVGMask.cpp in Sources */,
-				002843C709DDC030002E9CB0 /* SkSVGMetadata.cpp in Sources */,
-				002843C909DDC030002E9CB0 /* SkSVGPaintState.cpp in Sources */,
-				002843CA09DDC030002E9CB0 /* SkSVGParser.cpp in Sources */,
-				002843CB09DDC030002E9CB0 /* SkSVGPath.cpp in Sources */,
-				002843CD09DDC030002E9CB0 /* SkSVGPolygon.cpp in Sources */,
-				002843CF09DDC030002E9CB0 /* SkSVGPolyline.cpp in Sources */,
-				002843D109DDC030002E9CB0 /* SkSVGRadialGradient.cpp in Sources */,
-				002843D309DDC030002E9CB0 /* SkSVGRect.cpp in Sources */,
-				002843D509DDC030002E9CB0 /* SkSVGStop.cpp in Sources */,
-				002843D709DDC030002E9CB0 /* SkSVGSVG.cpp in Sources */,
-				002843D909DDC030002E9CB0 /* SkSVGSymbol.cpp in Sources */,
-				002843DB09DDC030002E9CB0 /* SkSVGText.cpp in Sources */,
-				002843DD09DDC030002E9CB0 /* SkSVGUse.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = svg;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = svg;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "svg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "svg" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/views.xcodeproj/project.pbxproj b/ide/xcode/views.xcodeproj/project.pbxproj
deleted file mode 100644
index 05de569..0000000
--- a/ide/xcode/views.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,330 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		005FA5B00B52AB9000896055 /* SkBGViewArtist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA59B0B52AB9000896055 /* SkBGViewArtist.cpp */; };
-		005FA5B10B52AB9000896055 /* SkBorderView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA59C0B52AB9000896055 /* SkBorderView.cpp */; };
-		005FA5B20B52AB9000896055 /* SkImageView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA59D0B52AB9000896055 /* SkImageView.cpp */; };
-		005FA5B30B52AB9000896055 /* SkListView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA59E0B52AB9000896055 /* SkListView.cpp */; };
-		005FA5B40B52AB9000896055 /* SkListWidget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA59F0B52AB9000896055 /* SkListWidget.cpp */; };
-		005FA5B50B52AB9000896055 /* SkOSFile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A00B52AB9000896055 /* SkOSFile.cpp */; };
-		005FA5B60B52AB9000896055 /* SkOSMenu.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A10B52AB9000896055 /* SkOSMenu.cpp */; };
-		005FA5B70B52AB9000896055 /* SkOSSound.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A20B52AB9000896055 /* SkOSSound.cpp */; };
-		005FA5B80B52AB9000896055 /* SkParsePaint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A30B52AB9000896055 /* SkParsePaint.cpp */; };
-		005FA5B90B52AB9000896055 /* SkProgressBarView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A40B52AB9000896055 /* SkProgressBarView.cpp */; };
-		005FA5BA0B52AB9000896055 /* SkProgressView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A50B52AB9000896055 /* SkProgressView.cpp */; };
-		005FA5BB0B52AB9000896055 /* SkScrollBarView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A60B52AB9000896055 /* SkScrollBarView.cpp */; };
-		005FA5BC0B52AB9000896055 /* SkStackViewLayout.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A70B52AB9000896055 /* SkStackViewLayout.cpp */; };
-		005FA5BD0B52AB9000896055 /* SkView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A80B52AB9000896055 /* SkView.cpp */; };
-		005FA5BE0B52AB9000896055 /* SkViewInflate.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5A90B52AB9000896055 /* SkViewInflate.cpp */; };
-		005FA5BF0B52AB9000896055 /* SkViewPriv.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5AA0B52AB9000896055 /* SkViewPriv.cpp */; };
-		005FA5C00B52AB9000896055 /* SkViewPriv.h in Headers */ = {isa = PBXBuildFile; fileRef = 005FA5AB0B52AB9000896055 /* SkViewPriv.h */; };
-		005FA5C10B52AB9000896055 /* SkWidget.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5AC0B52AB9000896055 /* SkWidget.cpp */; };
-		005FA5C20B52AB9000896055 /* SkWidgets.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5AD0B52AB9000896055 /* SkWidgets.cpp */; };
-		005FA5C30B52AB9000896055 /* SkWidgetViews.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5AE0B52AB9000896055 /* SkWidgetViews.cpp */; };
-		005FA5C40B52AB9000896055 /* SkWindow.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 005FA5AF0B52AB9000896055 /* SkWindow.cpp */; };
-		FECBEAA00C60D34E00DB1DDA /* SkEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECBEA9A0C60D34E00DB1DDA /* SkEvent.cpp */; };
-		FECBEAA10C60D34E00DB1DDA /* SkEventSink.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECBEA9B0C60D34E00DB1DDA /* SkEventSink.cpp */; };
-		FECBEAA20C60D34E00DB1DDA /* SkMetaData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECBEA9C0C60D34E00DB1DDA /* SkMetaData.cpp */; };
-		FECBEAA30C60D34E00DB1DDA /* SkTagList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECBEA9D0C60D34E00DB1DDA /* SkTagList.cpp */; };
-		FECBEAA40C60D34E00DB1DDA /* SkTagList.h in Headers */ = {isa = PBXBuildFile; fileRef = FECBEA9E0C60D34E00DB1DDA /* SkTagList.h */; };
-		FECBEAA50C60D34E00DB1DDA /* SkTextBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FECBEA9F0C60D34E00DB1DDA /* SkTextBox.cpp */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		005FA59B0B52AB9000896055 /* SkBGViewArtist.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBGViewArtist.cpp; path = ../../tests/skia/views/SkBGViewArtist.cpp; sourceTree = SOURCE_ROOT; };
-		005FA59C0B52AB9000896055 /* SkBorderView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkBorderView.cpp; path = ../../tests/skia/views/SkBorderView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA59D0B52AB9000896055 /* SkImageView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkImageView.cpp; path = ../../tests/skia/views/SkImageView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA59E0B52AB9000896055 /* SkListView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkListView.cpp; path = ../../tests/skia/views/SkListView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA59F0B52AB9000896055 /* SkListWidget.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkListWidget.cpp; path = ../../tests/skia/views/SkListWidget.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A00B52AB9000896055 /* SkOSFile.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOSFile.cpp; path = ../../tests/skia/views/SkOSFile.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A10B52AB9000896055 /* SkOSMenu.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOSMenu.cpp; path = ../../tests/skia/views/SkOSMenu.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A20B52AB9000896055 /* SkOSSound.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkOSSound.cpp; path = ../../tests/skia/views/SkOSSound.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A30B52AB9000896055 /* SkParsePaint.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkParsePaint.cpp; path = ../../tests/skia/views/SkParsePaint.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A40B52AB9000896055 /* SkProgressBarView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkProgressBarView.cpp; path = ../../tests/skia/views/SkProgressBarView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A50B52AB9000896055 /* SkProgressView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkProgressView.cpp; path = ../../tests/skia/views/SkProgressView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A60B52AB9000896055 /* SkScrollBarView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkScrollBarView.cpp; path = ../../tests/skia/views/SkScrollBarView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A70B52AB9000896055 /* SkStackViewLayout.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkStackViewLayout.cpp; path = ../../tests/skia/views/SkStackViewLayout.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A80B52AB9000896055 /* SkView.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkView.cpp; path = ../../tests/skia/views/SkView.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5A90B52AB9000896055 /* SkViewInflate.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkViewInflate.cpp; path = ../../tests/skia/views/SkViewInflate.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5AA0B52AB9000896055 /* SkViewPriv.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkViewPriv.cpp; path = ../../tests/skia/views/SkViewPriv.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5AB0B52AB9000896055 /* SkViewPriv.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkViewPriv.h; path = ../../tests/skia/views/SkViewPriv.h; sourceTree = SOURCE_ROOT; };
-		005FA5AC0B52AB9000896055 /* SkWidget.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkWidget.cpp; path = ../../tests/skia/views/SkWidget.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5AD0B52AB9000896055 /* SkWidgets.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkWidgets.cpp; path = ../../tests/skia/views/SkWidgets.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5AE0B52AB9000896055 /* SkWidgetViews.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkWidgetViews.cpp; path = ../../tests/skia/views/SkWidgetViews.cpp; sourceTree = SOURCE_ROOT; };
-		005FA5AF0B52AB9000896055 /* SkWindow.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkWindow.cpp; path = ../../tests/skia/views/SkWindow.cpp; sourceTree = SOURCE_ROOT; };
-		D2AAC046055464E500DB518D /* libviews.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libviews.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FECBEA9A0C60D34E00DB1DDA /* SkEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkEvent.cpp; path = ../../libs/graphics/views/SkEvent.cpp; sourceTree = SOURCE_ROOT; };
-		FECBEA9B0C60D34E00DB1DDA /* SkEventSink.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkEventSink.cpp; path = ../../libs/graphics/views/SkEventSink.cpp; sourceTree = SOURCE_ROOT; };
-		FECBEA9C0C60D34E00DB1DDA /* SkMetaData.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkMetaData.cpp; path = ../../libs/graphics/views/SkMetaData.cpp; sourceTree = SOURCE_ROOT; };
-		FECBEA9D0C60D34E00DB1DDA /* SkTagList.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTagList.cpp; path = ../../libs/graphics/views/SkTagList.cpp; sourceTree = SOURCE_ROOT; };
-		FECBEA9E0C60D34E00DB1DDA /* SkTagList.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = SkTagList.h; path = ../../libs/graphics/views/SkTagList.h; sourceTree = SOURCE_ROOT; };
-		FECBEA9F0C60D34E00DB1DDA /* SkTextBox.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = SkTextBox.cpp; path = ../../libs/graphics/views/SkTextBox.cpp; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		00797CCD0A88F0D50017AF55 /* Views */ = {
-			isa = PBXGroup;
-			children = (
-				005FA59B0B52AB9000896055 /* SkBGViewArtist.cpp */,
-				005FA59C0B52AB9000896055 /* SkBorderView.cpp */,
-				005FA59D0B52AB9000896055 /* SkImageView.cpp */,
-				005FA59E0B52AB9000896055 /* SkListView.cpp */,
-				005FA59F0B52AB9000896055 /* SkListWidget.cpp */,
-				005FA5A00B52AB9000896055 /* SkOSFile.cpp */,
-				005FA5A10B52AB9000896055 /* SkOSMenu.cpp */,
-				005FA5A20B52AB9000896055 /* SkOSSound.cpp */,
-				005FA5A30B52AB9000896055 /* SkParsePaint.cpp */,
-				005FA5A40B52AB9000896055 /* SkProgressBarView.cpp */,
-				005FA5A50B52AB9000896055 /* SkProgressView.cpp */,
-				005FA5A60B52AB9000896055 /* SkScrollBarView.cpp */,
-				005FA5A70B52AB9000896055 /* SkStackViewLayout.cpp */,
-				005FA5A80B52AB9000896055 /* SkView.cpp */,
-				005FA5A90B52AB9000896055 /* SkViewInflate.cpp */,
-				005FA5AA0B52AB9000896055 /* SkViewPriv.cpp */,
-				005FA5AB0B52AB9000896055 /* SkViewPriv.h */,
-				005FA5AC0B52AB9000896055 /* SkWidget.cpp */,
-				005FA5AD0B52AB9000896055 /* SkWidgets.cpp */,
-				005FA5AE0B52AB9000896055 /* SkWidgetViews.cpp */,
-				005FA5AF0B52AB9000896055 /* SkWindow.cpp */,
-			);
-			name = Views;
-			sourceTree = "<group>";
-		};
-		08FB7794FE84155DC02AAC07 /* views */ = {
-			isa = PBXGroup;
-			children = (
-				00797CCD0A88F0D50017AF55 /* Views */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = views;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				FECBEA9A0C60D34E00DB1DDA /* SkEvent.cpp */,
-				FECBEA9B0C60D34E00DB1DDA /* SkEventSink.cpp */,
-				FECBEA9C0C60D34E00DB1DDA /* SkMetaData.cpp */,
-				FECBEA9D0C60D34E00DB1DDA /* SkTagList.cpp */,
-				FECBEA9E0C60D34E00DB1DDA /* SkTagList.h */,
-				FECBEA9F0C60D34E00DB1DDA /* SkTextBox.cpp */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libviews.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				005FA5C00B52AB9000896055 /* SkViewPriv.h in Headers */,
-				FECBEAA40C60D34E00DB1DDA /* SkTagList.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* views */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "views" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = views;
-			productName = views;
-			productReference = D2AAC046055464E500DB518D /* libviews.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "views" */;
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* views */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* views */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				005FA5B00B52AB9000896055 /* SkBGViewArtist.cpp in Sources */,
-				005FA5B10B52AB9000896055 /* SkBorderView.cpp in Sources */,
-				005FA5B20B52AB9000896055 /* SkImageView.cpp in Sources */,
-				005FA5B30B52AB9000896055 /* SkListView.cpp in Sources */,
-				005FA5B40B52AB9000896055 /* SkListWidget.cpp in Sources */,
-				005FA5B50B52AB9000896055 /* SkOSFile.cpp in Sources */,
-				005FA5B60B52AB9000896055 /* SkOSMenu.cpp in Sources */,
-				005FA5B70B52AB9000896055 /* SkOSSound.cpp in Sources */,
-				005FA5B80B52AB9000896055 /* SkParsePaint.cpp in Sources */,
-				005FA5B90B52AB9000896055 /* SkProgressBarView.cpp in Sources */,
-				005FA5BA0B52AB9000896055 /* SkProgressView.cpp in Sources */,
-				005FA5BB0B52AB9000896055 /* SkScrollBarView.cpp in Sources */,
-				005FA5BC0B52AB9000896055 /* SkStackViewLayout.cpp in Sources */,
-				005FA5BD0B52AB9000896055 /* SkView.cpp in Sources */,
-				005FA5BE0B52AB9000896055 /* SkViewInflate.cpp in Sources */,
-				005FA5BF0B52AB9000896055 /* SkViewPriv.cpp in Sources */,
-				005FA5C10B52AB9000896055 /* SkWidget.cpp in Sources */,
-				005FA5C20B52AB9000896055 /* SkWidgets.cpp in Sources */,
-				005FA5C30B52AB9000896055 /* SkWidgetViews.cpp in Sources */,
-				005FA5C40B52AB9000896055 /* SkWindow.cpp in Sources */,
-				FECBEAA00C60D34E00DB1DDA /* SkEvent.cpp in Sources */,
-				FECBEAA10C60D34E00DB1DDA /* SkEventSink.cpp in Sources */,
-				FECBEAA20C60D34E00DB1DDA /* SkMetaData.cpp in Sources */,
-				FECBEAA30C60D34E00DB1DDA /* SkTagList.cpp in Sources */,
-				FECBEAA50C60D34E00DB1DDA /* SkTextBox.cpp in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		1DEB91EC08733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = views;
-				ZERO_LINK = NO;
-			};
-			name = Debug;
-		};
-		1DEB91ED08733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ARCHS = "$(NATIVE_ARCH)";
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				INSTALL_PATH = /usr/local/lib;
-				PRODUCT_NAME = views;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		1DEB91F008733DB70010E9CD /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = YES;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = "";
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg ../../libs/graphics/sgl";
-			};
-			name = Debug;
-		};
-		1DEB91F108733DB70010E9CD /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = YES;
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				HEADER_SEARCH_PATHS = "$(HEADER_SEARCH_PATHS)";
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				SDKROOT = "";
-				SHARED_PRECOMPS_DIR = "";
-				STRIP_INSTALLED_PRODUCT = NO;
-				USER_HEADER_SEARCH_PATHS = "../../include/graphics ../../include/corecg ../../libs/graphics/sgl";
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		1DEB91EB08733DB70010E9CD /* Build configuration list for PBXNativeTarget "views" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91EC08733DB70010E9CD /* Debug */,
-				1DEB91ED08733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "views" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				1DEB91F008733DB70010E9CD /* Debug */,
-				1DEB91F108733DB70010E9CD /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/ide/xcode/zlib.xcodeproj/project.pbxproj b/ide/xcode/zlib.xcodeproj/project.pbxproj
deleted file mode 100644
index dad1a97..0000000
--- a/ide/xcode/zlib.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,350 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 42;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		FE08AA0D0944F1E40057213F /* adler32.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA020944F1E40057213F /* adler32.c */; };
-		FE08AA0E0944F1E40057213F /* compress.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA030944F1E40057213F /* compress.c */; };
-		FE08AA0F0944F1E40057213F /* crc32.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA040944F1E40057213F /* crc32.c */; };
-		FE08AA100944F1E40057213F /* deflate.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA050944F1E40057213F /* deflate.c */; };
-		FE08AA110944F1E40057213F /* infback.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA060944F1E40057213F /* infback.c */; };
-		FE08AA120944F1E40057213F /* inffast.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA070944F1E40057213F /* inffast.c */; };
-		FE08AA130944F1E40057213F /* inflate.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA080944F1E40057213F /* inflate.c */; };
-		FE08AA140944F1E40057213F /* inftrees.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA090944F1E40057213F /* inftrees.c */; };
-		FE08AA150944F1E40057213F /* trees.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA0A0944F1E40057213F /* trees.c */; };
-		FE08AA160944F1E40057213F /* uncompr.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA0B0944F1E40057213F /* uncompr.c */; };
-		FE08AA170944F1E40057213F /* zutil.c in Sources */ = {isa = PBXBuildFile; fileRef = FE08AA0C0944F1E40057213F /* zutil.c */; };
-		FE08AA260944F2710057213F /* crc32.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA1B0944F2710057213F /* crc32.h */; };
-		FE08AA270944F2710057213F /* deflate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA1C0944F2710057213F /* deflate.h */; };
-		FE08AA280944F2710057213F /* inffast.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA1D0944F2710057213F /* inffast.h */; };
-		FE08AA290944F2710057213F /* inffixed.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA1E0944F2710057213F /* inffixed.h */; };
-		FE08AA2A0944F2710057213F /* inflate.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA1F0944F2710057213F /* inflate.h */; };
-		FE08AA2B0944F2710057213F /* inftrees.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA200944F2710057213F /* inftrees.h */; };
-		FE08AA2C0944F2710057213F /* trees.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA210944F2710057213F /* trees.h */; };
-		FE08AA2D0944F2710057213F /* zconf.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA220944F2710057213F /* zconf.h */; };
-		FE08AA2E0944F2710057213F /* zconf.in.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA230944F2710057213F /* zconf.in.h */; };
-		FE08AA2F0944F2710057213F /* zlib.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA240944F2710057213F /* zlib.h */; };
-		FE08AA300944F2710057213F /* zutil.h in Headers */ = {isa = PBXBuildFile; fileRef = FE08AA250944F2710057213F /* zutil.h */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXBuildStyle section */
-		014CEA520018CE5811CA2923 /* Development */ = {
-			isa = PBXBuildStyle;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				ZERO_LINK = YES;
-			};
-			name = Development;
-		};
-		014CEA530018CE5811CA2923 /* Deployment */ = {
-			isa = PBXBuildStyle;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				ZERO_LINK = NO;
-			};
-			name = Deployment;
-		};
-/* End PBXBuildStyle section */
-
-/* Begin PBXFileReference section */
-		D2AAC046055464E500DB518D /* libzlib.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libzlib.a; sourceTree = BUILT_PRODUCTS_DIR; };
-		FE08AA020944F1E40057213F /* adler32.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = adler32.c; path = "../../extlibs/zlib-1.2.3/adler32.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA030944F1E40057213F /* compress.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = compress.c; path = "../../extlibs/zlib-1.2.3/compress.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA040944F1E40057213F /* crc32.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = crc32.c; path = "../../extlibs/zlib-1.2.3/crc32.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA050944F1E40057213F /* deflate.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = deflate.c; path = "../../extlibs/zlib-1.2.3/deflate.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA060944F1E40057213F /* infback.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = infback.c; path = "../../extlibs/zlib-1.2.3/infback.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA070944F1E40057213F /* inffast.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = inffast.c; path = "../../extlibs/zlib-1.2.3/inffast.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA080944F1E40057213F /* inflate.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = inflate.c; path = "../../extlibs/zlib-1.2.3/inflate.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA090944F1E40057213F /* inftrees.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = inftrees.c; path = "../../extlibs/zlib-1.2.3/inftrees.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA0A0944F1E40057213F /* trees.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = trees.c; path = "../../extlibs/zlib-1.2.3/trees.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA0B0944F1E40057213F /* uncompr.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = uncompr.c; path = "../../extlibs/zlib-1.2.3/uncompr.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA0C0944F1E40057213F /* zutil.c */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.c; name = zutil.c; path = "../../extlibs/zlib-1.2.3/zutil.c"; sourceTree = SOURCE_ROOT; };
-		FE08AA1B0944F2710057213F /* crc32.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = crc32.h; path = "../../extlibs/zlib-1.2.3/crc32.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA1C0944F2710057213F /* deflate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = deflate.h; path = "../../extlibs/zlib-1.2.3/deflate.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA1D0944F2710057213F /* inffast.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = inffast.h; path = "../../extlibs/zlib-1.2.3/inffast.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA1E0944F2710057213F /* inffixed.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = inffixed.h; path = "../../extlibs/zlib-1.2.3/inffixed.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA1F0944F2710057213F /* inflate.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = inflate.h; path = "../../extlibs/zlib-1.2.3/inflate.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA200944F2710057213F /* inftrees.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = inftrees.h; path = "../../extlibs/zlib-1.2.3/inftrees.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA210944F2710057213F /* trees.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = trees.h; path = "../../extlibs/zlib-1.2.3/trees.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA220944F2710057213F /* zconf.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = zconf.h; path = "../../extlibs/zlib-1.2.3/zconf.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA230944F2710057213F /* zconf.in.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = zconf.in.h; path = "../../extlibs/zlib-1.2.3/zconf.in.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA240944F2710057213F /* zlib.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = zlib.h; path = "../../extlibs/zlib-1.2.3/zlib.h"; sourceTree = SOURCE_ROOT; };
-		FE08AA250944F2710057213F /* zutil.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; name = zutil.h; path = "../../extlibs/zlib-1.2.3/zutil.h"; sourceTree = SOURCE_ROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		D289987405E68DCB004EDB86 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		08FB7794FE84155DC02AAC07 /* zlib */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AA1A0944F1FE0057213F /* Include */,
-				08FB7795FE84155DC02AAC07 /* Source */,
-				C6A0FF2B0290797F04C91782 /* Documentation */,
-				1AB674ADFE9D54B511CA2CBB /* Products */,
-			);
-			name = zlib;
-			sourceTree = "<group>";
-		};
-		08FB7795FE84155DC02AAC07 /* Source */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AA020944F1E40057213F /* adler32.c */,
-				FE08AA030944F1E40057213F /* compress.c */,
-				FE08AA040944F1E40057213F /* crc32.c */,
-				FE08AA050944F1E40057213F /* deflate.c */,
-				FE08AA060944F1E40057213F /* infback.c */,
-				FE08AA070944F1E40057213F /* inffast.c */,
-				FE08AA080944F1E40057213F /* inflate.c */,
-				FE08AA090944F1E40057213F /* inftrees.c */,
-				FE08AA0A0944F1E40057213F /* trees.c */,
-				FE08AA0B0944F1E40057213F /* uncompr.c */,
-				FE08AA0C0944F1E40057213F /* zutil.c */,
-			);
-			name = Source;
-			sourceTree = "<group>";
-		};
-		1AB674ADFE9D54B511CA2CBB /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				D2AAC046055464E500DB518D /* libzlib.a */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		C6A0FF2B0290797F04C91782 /* Documentation */ = {
-			isa = PBXGroup;
-			children = (
-			);
-			name = Documentation;
-			sourceTree = "<group>";
-		};
-		FE08AA1A0944F1FE0057213F /* Include */ = {
-			isa = PBXGroup;
-			children = (
-				FE08AA1B0944F2710057213F /* crc32.h */,
-				FE08AA1C0944F2710057213F /* deflate.h */,
-				FE08AA1D0944F2710057213F /* inffast.h */,
-				FE08AA1E0944F2710057213F /* inffixed.h */,
-				FE08AA1F0944F2710057213F /* inflate.h */,
-				FE08AA200944F2710057213F /* inftrees.h */,
-				FE08AA210944F2710057213F /* trees.h */,
-				FE08AA220944F2710057213F /* zconf.h */,
-				FE08AA230944F2710057213F /* zconf.in.h */,
-				FE08AA240944F2710057213F /* zlib.h */,
-				FE08AA250944F2710057213F /* zutil.h */,
-			);
-			name = Include;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXHeadersBuildPhase section */
-		D2AAC043055464E500DB518D /* Headers */ = {
-			isa = PBXHeadersBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AA260944F2710057213F /* crc32.h in Headers */,
-				FE08AA270944F2710057213F /* deflate.h in Headers */,
-				FE08AA280944F2710057213F /* inffast.h in Headers */,
-				FE08AA290944F2710057213F /* inffixed.h in Headers */,
-				FE08AA2A0944F2710057213F /* inflate.h in Headers */,
-				FE08AA2B0944F2710057213F /* inftrees.h in Headers */,
-				FE08AA2C0944F2710057213F /* trees.h in Headers */,
-				FE08AA2D0944F2710057213F /* zconf.h in Headers */,
-				FE08AA2E0944F2710057213F /* zconf.in.h in Headers */,
-				FE08AA2F0944F2710057213F /* zlib.h in Headers */,
-				FE08AA300944F2710057213F /* zutil.h in Headers */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXHeadersBuildPhase section */
-
-/* Begin PBXNativeTarget section */
-		D2AAC045055464E500DB518D /* zlib */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = FE5F4830094784880095980F /* Build configuration list for PBXNativeTarget "zlib" */;
-			buildPhases = (
-				D2AAC043055464E500DB518D /* Headers */,
-				D2AAC044055464E500DB518D /* Sources */,
-				D289987405E68DCB004EDB86 /* Frameworks */,
-			);
-			buildRules = (
-			);
-			buildSettings = {
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = zlib;
-			};
-			dependencies = (
-			);
-			name = zlib;
-			productName = zlib;
-			productReference = D2AAC046055464E500DB518D /* libzlib.a */;
-			productType = "com.apple.product-type.library.static";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		08FB7793FE84155DC02AAC07 /* Project object */ = {
-			isa = PBXProject;
-			buildConfigurationList = FE5F4834094784880095980F /* Build configuration list for PBXProject "zlib" */;
-			buildSettings = {
-			};
-			buildStyles = (
-				014CEA520018CE5811CA2923 /* Development */,
-				014CEA530018CE5811CA2923 /* Deployment */,
-			);
-			hasScannedForEncodings = 1;
-			mainGroup = 08FB7794FE84155DC02AAC07 /* zlib */;
-			projectDirPath = "";
-			targets = (
-				D2AAC045055464E500DB518D /* zlib */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXSourcesBuildPhase section */
-		D2AAC044055464E500DB518D /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				FE08AA0D0944F1E40057213F /* adler32.c in Sources */,
-				FE08AA0E0944F1E40057213F /* compress.c in Sources */,
-				FE08AA0F0944F1E40057213F /* crc32.c in Sources */,
-				FE08AA100944F1E40057213F /* deflate.c in Sources */,
-				FE08AA110944F1E40057213F /* infback.c in Sources */,
-				FE08AA120944F1E40057213F /* inffast.c in Sources */,
-				FE08AA130944F1E40057213F /* inflate.c in Sources */,
-				FE08AA140944F1E40057213F /* inftrees.c in Sources */,
-				FE08AA150944F1E40057213F /* trees.c in Sources */,
-				FE08AA160944F1E40057213F /* uncompr.c in Sources */,
-				FE08AA170944F1E40057213F /* zutil.c in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin XCBuildConfiguration section */
-		FE5F4831094784880095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_MODEL_TUNING = G5;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = zlib;
-				ZERO_LINK = YES;
-			};
-			name = Debug;
-		};
-		FE5F4832094784880095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_MODEL_TUNING = G5;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				INSTALL_PATH = /usr/local/lib;
-				LIBRARY_STYLE = STATIC;
-				PREBINDING = NO;
-				PRODUCT_NAME = zlib;
-				ZERO_LINK = NO;
-			};
-			name = Release;
-		};
-		FE5F4835094784880095980F /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				STRIP_INSTALLED_PRODUCT = NO;
-			};
-			name = Debug;
-		};
-		FE5F4836094784880095980F /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				GCC_CW_ASM_SYNTAX = NO;
-				GCC_ENABLE_CPP_RTTI = NO;
-				GCC_ENABLE_PASCAL_STRINGS = NO;
-				GCC_ENABLE_SYMBOL_SEPARATION = NO;
-				GCC_PREPROCESSOR_DEFINITIONS = SK_RELEASE;
-				GCC_USE_GCC3_PFE_SUPPORT = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				LINK_WITH_STANDARD_LIBRARIES = NO;
-				PREBINDING = NO;
-				PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = NO;
-				STRIP_INSTALLED_PRODUCT = NO;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		FE5F4830094784880095980F /* Build configuration list for PBXNativeTarget "zlib" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F4831094784880095980F /* Debug */,
-				FE5F4832094784880095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-		FE5F4834094784880095980F /* Build configuration list for PBXProject "zlib" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				FE5F4835094784880095980F /* Debug */,
-				FE5F4836094784880095980F /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Debug;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 08FB7793FE84155DC02AAC07 /* Project object */;
-}
diff --git a/pdk/Pdk.mk b/pdk/Pdk.mk
deleted file mode 100644
index abe9491..0000000
--- a/pdk/Pdk.mk
+++ /dev/null
@@ -1,206 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# Assemble the Platform Development Kit (PDK)
-# (TODO) Figure out why $(ACP) builds with target ndk but not pdk_docs
-# (TODO) Build doxygen (depend on latest version)
-
-pdk:
-	@echo "Package: $@ has targets ndk, pdk_docs and pdk_all"
-
-pdk_all: ndk pdk_docs
-	@echo "Package: $^"
-
-LOCAL_PATH := $(call my-dir)
-
-#-------------------------------------------------------------------------------
-# Make the Native Development Kit (Code examples)
-#   Allows vendors to build shared libraries without entire source tree.
-# This include adds /ndk to LOCAL_PATH, so can't use it afterwards...
-include $(LOCAL_PATH)/ndk/Ndk.mk
-
-
-#-------------------------------------------------------------------------------
-# Make the Plaftorm Development Kit Documentation.
-#   Doxygenize the header files to create html docs in the generatedDocs dir.
-#   Copy the appengine files, the template files and the generated html 
-#   to the docs dir and zip everything up to the distribution directory.
-
-
-# Workspace directory
-pdk_docs_intermediates := $(call intermediates-dir-for,PACKAGING,pdkdocs)
-
-# Source directories for appengine, templates, config & header files
-pdk_hosting_dir := development/pdk/hosting
-pdk_templates_dir := development/pdk/docs
-pdk_config_dir := development/pdk/doxygen_config
-pdk_docsfile_dir := $(pdk_config_dir)/docsfiles
-pdk_legacy_hardware_dir := hardware/libhardware_legacy/include/hardware_legacy
-pdk_camera_dir := frameworks/base/include/ui
-
-# Destination directory for docs (templates + doxygenated headers)
-pdk_docs_dest_dir := $(pdk_docs_intermediates)/docs
-
-# Working directory for source to be doxygenated
-pdk_doxy_source_dir := $(pdk_docs_intermediates)/sources
-
-# Working directory for html, et al. after doxygination
-pdk_generated_source_dir := $(pdk_docs_intermediates)/generatedDocs/html
-
-# Working directory for .dox files
-pdk_doxy_docsfiles_dir := $(pdk_docs_intermediates)/docsfiles
-
-# Doxygen version to use, so we can override it on the command line
-# doxygen 1.4.6 working, the latest version get-apt installable on goobuntu.
-# (TODO) doxygen 1.5.6 generated source files not displayable
-# doxygen_version='~pubengdocs/shared/doxy/doxygen.1.5.6.kcc'
-#   for latest version of doxygen on linux
-doxygen_version = doxygen
-
-#------------------------------------------------------------------------------- 
-# Header files to doxygenize. 
-#   Add new header files to document here, also adjust the templates to have 
-#   descriptions for the new headers and point to the new doxygen created html.
-pdk_headers := \
-    $(pdk_legacy_hardware_dir)/AudioHardwareInterface.h \
-    $(pdk_legacy_hardware_dir)/gps.h \
-    $(pdk_legacy_hardware_dir)/wifi.h \
-    $(pdk_camera_dir)/CameraHardwareInterface.h
-
-# Create a rule to copy the list of PDK headers to be doxyginated.
-# copy-one-header defines the actual rule.
-$(foreach header,$(pdk_headers), \
-  $(eval _chFrom := $(header)) \
-  $(eval _chTo :=  $(pdk_doxy_source_dir)/$(notdir $(header))) \
-  $(eval $(call copy-one-header,$(_chFrom),$(_chTo))) \
-  $(eval all_copied_pdk_headers: $(_chTo)) \
- )
-_chFrom :=
-_chTo :=
-
-
-#-------------------------------------------------------------------------------
-# Assemble all the necessary doxygen config files and the sources into the
-#   working directories
-
-pdk_templates := $(shell find $(pdk_templates_dir) -type f)
-
-# Create a rule to copy the list of PDK doc templates.
-# copy-one-file defines the actual rule.
-$(foreach template,$(pdk_templates), \
-  $(eval _chFrom := $(template)) \
-  $(eval _chTo :=  $(pdk_docs_dest_dir)/$(notdir $(template))) \
-  $(eval $(call copy-one-header,$(_chFrom),$(_chTo))) \
-  $(eval all_copied_pdk_templates: $(_chTo)) \
- )
-_chFrom :=
-_chTo :=
-
-# Copy newer doxygen config file (basic configs, should not change very often.)
-pdk_doxygen_config_file := $(pdk_docs_intermediates)/pdk_config.conf
-$(pdk_doxygen_config_file): $(pdk_config_dir)/pdk_config.conf
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-# Copy newer doxygen override config file (may change these more often.)
-pdk_doxygen_config_override_file := $(pdk_docs_intermediates)/overrideconfig.conf
-$(pdk_doxygen_config_override_file): $(pdk_config_dir)/overrideconfig.conf
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-# (TODO) Get the latest templates
-# Copy newer doxygen html files.
-$(pdk_docs_intermediates)/header.html: $(pdk_config_dir)/header.html
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-$(pdk_docs_intermediates)/footer.html: $(pdk_config_dir)/footer.html
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-# Copy newer doxygen .dox files
-$(pdk_doxy_docsfiles_dir)/groups.dox: $(pdk_docsfile_dir)/groups.dox
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-$(pdk_doxy_docsfiles_dir)/main.dox: $(pdk_docsfile_dir)/main.dox
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-# Copy appengine server files
-$(pdk_docs_intermediates)/app.yaml: $(pdk_hosting_dir)/app.yaml
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-$(pdk_docs_intermediates)/pdk.py: $(pdk_hosting_dir)/pdk.py
-	@echo "PDK: $@"
-	$(copy-file-to-target-with-cp)
-
-
-# Run doxygen and copy all output and templates to the final destination
-# We replace index.html with a template file so don't use the generated one
-pdk_doxygen: all_copied_pdk_headers $(pdk_doxygen_config_override_file) \
-    $(pdk_doxygen_config_file) $(pdk_docs_intermediates)/header.html \
-    $(pdk_docs_intermediates)/footer.html $(pdk_doxy_docsfiles_dir)/groups.dox \
-    $(pdk_doxy_docsfiles_dir)/main.dox
-	@echo "Files for Doxygination: $^"
-	@mkdir -p $(pdk_generated_source_dir)
-	@rm -f $(pdk_generated_source_dir)/*
-	@cd $(pdk_docs_intermediates) && $(doxygen_version) pdk_config.conf
-	@mkdir -p $(pdk_docs_dest_dir)
-	@cd $(pdk_generated_source_dir) && chmod ug+rx *
-	@rm -f $(pdk_generated_source_dir)/index.html
-	@cp -fp $(pdk_generated_source_dir)/* $(pdk_docs_dest_dir)
-  
-# Name the tar files
-name := android_pdk_docs-$(REQUESTED_PRODUCT)
-ifeq ($(TARGET_BUILD_TYPE),debug)
-  name := $(name)_debug
-endif
-name := $(name)-$(BUILD_NUMBER)
-pdk_docs_tarfile := $(pdk_docs_intermediates)/$(name).tar
-pdk_docs_tarfile_zipped := $(pdk_docs_tarfile).gz
-
-.PHONY: pdk pdk_docs pdk_doxygen all_copied_pdk_headers all_copied_pdk_templates
-
-pdk_docs: $(pdk_docs_tarfile_zipped)
-	@echo "PDK: Docs tarred and zipped"
-
-# Put the pdk_docs zip files in the distribution directory
-$(call dist-for-goals,pdk_docs,$(pdk_docs_tarfile_zipped))
-
-# zip up tar files
-%.tar.gz: %.tar
-	@echo "PDK: zipped $<"
-	$(hide) gzip -cf $< > $@
-
-# tar up all the files to make the pdk docs.
-$(pdk_docs_tarfile): pdk_doxygen all_copied_pdk_templates \
-    $(pdk_docs_intermediates)/pdk.py $(pdk_docs_intermediates)/app.yaml
-	@echo "PDK: $@"
-	@mkdir -p $(dir $@)
-	@rm -f $@
-	$(hide) tar rf $@ -C $(pdk_docs_intermediates) docs pdk.py app.yaml
-
-# Debugging reporting can go here, add it as a target to get output.
-pdk_debug:
-	@echo "You are here: $@"
-	@echo "pdk headers copied: $(all_copied_pdk_headers)"
-	@echo "pdk headers: $(pdk_headers)"
-	@echo "pdk docs dest: $(pdk_docs_dest_dir)"
-	@echo "config dest: $(pdk_doxygen_config_file)"
-	@echo "config src: $(pdk_config_dir)/pdk_config.conf"
-	@echo "pdk templates: $(pdk_templates_dir)"
diff --git a/pdk/README b/pdk/README
deleted file mode 100644
index 03af4e8..0000000
--- a/pdk/README
+++ /dev/null
@@ -1,78 +0,0 @@
-Building the pdk (platform development kit)
-
-1) get a cupcake source tree
-
-2) from the root
-  . build/envsetup.sh
-
-3) run choosecombo
-  Build for the simulator or the device?
-       1. Device
-       2. Simulator
-
-  Which would you like? [1] 1
-
-
-  Build type choices are:
-       1. release
-       2. debug
-
-  Which would you like? [1] 1
-
-
-  Product choices are:
-       0. emulator
-       1. generic
-       2. sim
-       3. surf
-  You can also type the name of a product if you know it.
-  Which would you like? [generic] 1
-
-
-  Variant choices are:
-       1. user
-       2. userdebug
-       3. eng
-  Which would you like? [eng] 3
-
-  ============================================
-  TARGET_PRODUCT=generic
-  TARGET_BUILD_VARIANT=eng
-  TARGET_SIMULATOR=false
-  TARGET_BUILD_TYPE=release
-  TARGET_ARCH=arm
-  HOST_ARCH=x86
-  HOST_OS=linux
-  HOST_BUILD_TYPE=release
-  BUILD_ID=
-  ============================================
-
-4) mkdir dist
-   mkdir logs
-   mkpdkcupcake.sh
-
-(which contains: 
-
-DT=`date +%y%m%d-%H%M%S`
-time make -j4 pdk pdk_all dist DIST_DIR=dist 2>&1 | tee logs/$DT
-
-so you can see the results of the build in the logs directory.)
-
-5) the pdk tar file is put in the dist directory.
-
-
-The build target 'pdk' brings in the pdk/ndk make files into the build system.
- Then there are three targets:
-  pdk_docs - which builds the pdk documentation
-  ndk - which builds the native development kit (native compiler, linker, etc.)
-  pdk_all - which builds the above two targets
-
-for doxygen version changing you can pass in the variable:
-doxygen_version='<path/name_of_doxygen_executable>'
-on the make line.
-
---------------------------------------------------------------------------------
-To host the pdk docs on appengine run:
-/home/build/static/projects/apphosting/devtools/appcfg.py update pdk/
-where the pdk directory contains: pdk.py, app.yaml, and the docs directory,
-all of which are tarred up by the Pdk.mk file when using the targer pdk_docs.
diff --git a/pdk/docs/CHANGE_HISTORY.TXT b/pdk/docs/CHANGE_HISTORY.TXT
deleted file mode 100755
index 04d5880..0000000
--- a/pdk/docs/CHANGE_HISTORY.TXT
+++ /dev/null
@@ -1,18 +0,0 @@
-V 0.3 - June 9, 2008

-####################

-

-* Architectural diagrams now include a legend that describes the difference 

-  between solid and dashed elements

-

-* Removed Puppetmaster document

-

-* Removed external link to Android Architecture from the left navigation bar

-

-* small changes to Radio Layer Interface

-

-* Updated Host System Setup (source_setup_guide.html) to include mention of Linux 8.04 and Cygwin.

-

-* Updated Build System (build_system.html): Switched Device code options 1 & 2 to emphasize that 

-  the new first option yields more consistent results. 

-

-* Updated Bring Up (bring_up.html): removed "hotplugd" from step 7.
\ No newline at end of file
diff --git a/pdk/docs/androidBluetooth.gif b/pdk/docs/androidBluetooth.gif
deleted file mode 100755
index e62f5a8..0000000
--- a/pdk/docs/androidBluetooth.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/androidBluetoothProcessDiagram.jpg b/pdk/docs/androidBluetoothProcessDiagram.jpg
deleted file mode 100755
index 6872180..0000000
--- a/pdk/docs/androidBluetoothProcessDiagram.jpg
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/androidCameraArchitecture.gif b/pdk/docs/androidCameraArchitecture.gif
deleted file mode 100755
index 2679b43..0000000
--- a/pdk/docs/androidCameraArchitecture.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/androidPMArchitecture.gif b/pdk/docs/androidPMArchitecture.gif
deleted file mode 100755
index 1aa48db..0000000
--- a/pdk/docs/androidPMArchitecture.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/android_audio_architecture.gif b/pdk/docs/android_audio_architecture.gif
deleted file mode 100755
index 79854a3..0000000
--- a/pdk/docs/android_audio_architecture.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/audio_sub_system.html b/pdk/docs/audio_sub_system.html
deleted file mode 100755
index 8639cf0..0000000
--- a/pdk/docs/audio_sub_system.html
+++ /dev/null
@@ -1,261 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20audio_sub_system.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidAudioSubSystemTitle"></a><h1>Audio</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidAudioSubSystemIntroduction">Introduction</a><br/>
-<a href="#androidAudioBuildingDriver">Building an Audio Library</a><br/>
-<a href="#androidAudioInterface">Interface</a><br/></div></font></div>
-
-<a name="androidAudioSubSystemIntroduction"></a><h2>Introduction</h2>
-
-<p>AudioHardwareInterface serves as the glue between proprietary audio drivers and the Android AudioFlinger service, the core audio service that handles all audio-related requests from applications.</p>
-<p><img src="android_audio_architecture.gif"></p>
-
-Solid elements represent Android blocks and dashed elements represent partner-specific blocks.
-
-
-
-<a name="androidAudioBuildingDriver"></a><h2>Building an Audio Library</h2>
-
-<p>To implement an audio driver, create a shared library that implements the interface defined in <code>AudioHardwareInterface.h</code>. You must name your shared library <code>libaudio.so</code> so that it will get loaded from <code>/system/lib</code> at runtime.  Place libaudio sources and <code>Android.mk</code> in <code>partner/acme/chipset_or_board/libaudio/</code>.</p>
-<p>The following stub <code>Android.mk</code> file ensures that <code>libaudio</code> compiles and links to the appropriate libraries:</p>
-
-<pre class="prettify">
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := libaudio
-
-LOCAL_SHARED_LIBRARIES := \
-    libcutils \
-    libutils \
-    libmedia \
-    libhardware
-
-LOCAL_SRC_FILES += MyAudioHardware.cpp
-
-LOCAL_CFLAGS +=
-
-LOCAL_C_INCLUDES +=
-
-LOCAL_STATIC_LIBRARIES += libaudiointerface
-
-include $(BUILD_SHARED_LIBRARY)
-</pre>
-
-
-<a name="androidAudioInterface"></a><h2>Interface</h2>
-
-
-
-<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="audio_sub_system.html">click here</a>.</p>
-
-
-<iframe onLoad="resizeHeight();" src="AudioHardwareInterface_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/bluetooth.html b/pdk/docs/bluetooth.html
deleted file mode 100755
index edd3c26..0000000
--- a/pdk/docs/bluetooth.html
+++ /dev/null
@@ -1,276 +0,0 @@
-
-<p><span class="lh2"><a name="androidHeader"></a></span>
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20bluetooth.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidBluetoothTitle"></a><h1>Bluetooth</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidBluetoothIntro">Introduction</a><br/>
-<a href="#androidBluetoothPorting">Porting</a><br/><div style="padding-left:40px">
-
-<a href="#androidBluetoothPortingDriver">UART Driver</a><br/>
-<a href="#androidBluetoothPortingPowerOnOff">Bluetooth Power On / Off</a><br/></div>
-<a href="#androidBluetoothTools">Tools</a><br/></div></font></div>
-
-<a name="androidBluetoothIntro"></a><h2>Introduction</h2>
-
-<p>Android's Bluetooth stack uses BlueZ version 3.36 for GAP, SDP, and RFCOMM profiles, and is a SIG-qualified Bluetooth 2.0 host stack.</p>
-
-<p>Bluez is GPL licensed, so the Android framework interacts with userspace bluez code through D-BUS IPC to avoid proprietary code.</p>
-
-<p>Headset and Handsfree (v1.5) profiles are implemented in the Android framework and are both tightly coupled with the Phone App. These profiles are also SIG qualified.</p>
-
-<p>The diagram below offers a library-oriented view of the Bluetooth stack. Click <a href="bluetooth_process.html">Bluetooth Process Diagram</a> for a process-oriented view.</p>
-
-<p><img src="androidBluetooth.gif"></p>
-
-Solid elements represent Android blocks and dashed elements represent partner-specific blocks.
-
-
-
-<a name="androidBluetoothPorting"></a><h2>Porting</h2>
-
-<p>BlueZ is Bluetooth 2.0 compatible and should work with any 2.0 chipset. There are two integration points:</p>
-<p><ul>
-<li>UART driver</li>
-<li>Bluetooth Power On / Off</li>
-</ul>
-</p>
-
-
-<a name="androidBluetoothPortingDriver"></a><h3>UART Driver</h3>
-
-<p>The BlueZ kernel sub-system attaches to your hardware-specific UART driver using the <code>hciattach</code> daemon.</p>
-<p>For example, for MSM7201A, this is <code>drivers/serial/msm_serial.c</code>. You may also need to edit command line options to <code>hciattach</code> via <code>init.rc</code>.</p>
-
-
-<a name="androidBluetoothPortingPowerOnOff"></a><h3>Bluetooth Power On / Off</h3>
-
-<p>The method for powering on and off your bluetooth chip varies from Android V 1.0 to post 1.0.</p>
-
-<p><ul>
-<li><b>1.0</b>: Android framework writes a 0 or 1 to <code>/sys/modules/board_[PLATFORM]/parameters/bluetooth_power_on</code>.</li>
-
-<li><b>Post 1.0</b>: Android framework uses the linux <code>rfkill</code> API. See <code>arch/arm/mach-msm/board-trout-rfkill.c</code> for an example.</li>
-</ul>
-</p>
-
-
-<a name="androidBluetoothTools"></a><h2>Tools</h2>
-
-<p>BlueZ provides a rich set of command line tools for debugging and interacting with the Bluetooth sub-system, including:</p>
-<p><ul>
-<li><code>hciconfig</code></li>
-<li><code>hcitool</code></li>
-<li><code>hcidump</code></li>
-<li><code>sdptool</code></li>
-<li><code>dbus-send</code></li>
-<li><code>dbus-monitor</code></li>
-</ul>
-</p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/bring_up.html b/pdk/docs/bring_up.html
deleted file mode 100755
index b70a35d..0000000
--- a/pdk/docs/bring_up.html
+++ /dev/null
@@ -1,561 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20bring_up.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidOHDPortingDeviceBringup"></a><h1>Bring Up</h1>
-
-<p>Once your code is built and you have verified that all necessary directories exist, power on and test your device with basic bring up, as described below. Bring up tests are typically designed to stress certain aspects of your system and allow you to characterize the device's behavior. </p>
-<p>&nbsp;</p>
-<h3>1. Confirm a Clean Installation of a Basic Linux Kernel </h3>
-<p>Before considering Android-specific modifications to the Linux kernel, verify that you can build, deploy, and boot a core Linux kernel on your target hardware. </p>
-<p>&nbsp;</p>
-<h3>2. Modify Your Kernel Configuration to Accommodate Android Drivers</h3>
-<p>Your kernel configuration file should include the following:</p>
-<pre class="prettyprint">
-#
-# Android
-#
-# CONFIG_ANDROID_GADGET is not set
-# CONFIG_ANDROID_RAM_CONSOLE is not set
-CONFIG_ANDROID_POWER=y
-CONFIG_ANDROID_POWER_STAT=y
-CONFIG_ANDROID_LOGGER=y
-# CONFIG_ANDROID_TIMED_GPIO is not set
-CONFIG_ANDROID_BINDER_IPC=y
-</pre>
-<h3>3. Write Drivers</h3>
-<p>Android ships with default drivers for all basic functionality but you'll likely want to write your own drivers (or at least customize the default drivers) for your own device depending on your hardware configuration. See the following topics for examples of how to write your own drivers. </p>
-<ul>
-  <li><a href="audio_subsystem.html">Audio</a></li>
-  <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-  <li><a href="display_drivers.html">Display</a></li>
-</ul>
-<p>&nbsp;</p>
-<h3>4. Burn Images to Flash</h3>
-<p>An image represents the state of a system or part of a system  stored in non-volatile memory. The build process should produce the following system images:</p>
-<ul>
-  <li><strong>bootloader</strong>: The bootloader is a small program responsible for initiating loading of the operating system. </li>
-  <li><strong>boot</strong>: </li>
-  <li><strong>recovery</strong>: </li>
-  <li><strong>system</strong>: The system image stores a snapshot of the Android operating system.</li>
-  <li><strong>data</strong>: The data image stores user data. Anything not saved to the <code>device/data</code> directory will be lost on reboot.</li>
-</ul>
-<ul>
-  <li><strong>kernel</strong>: The kernel represents the most basic element of an operating system. Android's Linux kernel is responsible for managing the system's resources and acts as an abstraction layer between hardware and a system's applications. </li>
-  <li><strong>ramdisk</strong>: RAMdisk defines a portion of Random Access Memory (RAM) that gets used as if it were a hard drive. </li>
-</ul>
-<p>&nbsp;</p>
-<p>Configure the bootloader to load the kernel 	and RAMdisk into RAM and pass the RAMdisk address to the kernel on 	startup. </p>
-<p>&nbsp;</p>
-<h3>5. Boot the kernel and mount the RAMdisk.</h3>
-<p>&nbsp;</p>
-<h3>6. Debug Android-specific init programs on RAMdisk</h3>
-<p>Android-specific init programs are found in <code>device/system/init</code>. Add LOG messages to help you debug potential problems with the LOG macro defined in <code>device/system/init/init.c</code>.</p>
-<p> The init program directly mounts all filesystems and devices using either hard-coded file names or device names generated by probing the sysfs filesystem (thereby eliminating the need for a <code>/etc/fstab</code> file in Android).  After <code>device/system</code> files are mounted, init  reads <code>/etc/init.rc</code> and invokes the programs listed there (one of the first of which is the 	console shell).</p>
-<p>&nbsp;</p>
-<h3>7. Verify that applications have started </h3>
-<p>Once the shell becomes available, execute <code>% ps</code> to confirm that the following applications are running:</p>
-<ul>
-    <li><code>/system/bin/logd</code></li>
-    <li><code>/sbin/adbd</code></li>
-    <li><code>/system/bin/usbd</code></li>
-    <li><code>/system/bin/debuggerd</code></li>
-    <li><code>/system/bin/rild</code></li>
-    <li><code>/system/bin/app_process</code></li>
-    <li><code>/system/bin/runtime</code></li>
-    <li><code>/system/bin/dbus-daemon</code></li>
-    <li><code>system_server</code></li>
-</ul>
-<p>Each of these applications is embedded Linux C/C++ and you can use any standard Linux debugging tool to troubleshoot applications that aren't running. Execute <code>% make showcommands</code> to determine precise build commands. <code>gdbserver</code> (the GNU debugger) is available in the <code>bin</code> directory of the system partition (please see <a href="http://sourceware.org/gdb/">http://sourceware.org/gdb/</a> for more information).  </p>
-<p>&nbsp;</p>
-<h3>8. Pulling it all together </h3>
-<p>If bring up was successful, you should see the following Java applications (with icons) visible on the LCD panel:</p>
-<ul>
-    <li>com.google.android.phone: The Android contact application. </li>
-    <li>com.google.android.home</li>
-    <li>android.process.google.content</li>
-</ul>
-<p>If they are not visible or unresponsive to keypad control, run the <code>framebuffer/keypad</code> tests.</p>
-
-
-<a name="androidInitLanguage"></a><h1>Android Init Language</h1>
-
-
-<p>The Android Init Language consists of four broad classes of statements:</p>
-<ul>
-  <li>Actionn</li>
-  <li>Commands</li>
-  <li>Services</li>
-  <li>Options</li>
-</ul>
-<p>The language syntax includes the following conventions: </p>
-<ul>
-  <li>All classes are line-oriented and consist of tokens separated by whitespace. c-style backslash escapes may be used to insert whitespace into a token. &nbsp;Double quotes may also be used to prevent whitespace from breaking text into multiple tokens. A backslash <br />
-  appearing as the last character on a line is used for line-folding.</li>
-  <li> Lines that start with a # (leading whitespace allowed) are comments.</li>
-  <li>Actions and Services implicitly declare new sections. All commands
-    or options belong to the section most recently declared. &nbsp;Commands
-    or options before the first section are ignored.  </li>
-  <li>Actions and Services have unique names. &nbsp;If a second Action or Service is declared with the same name as an existing one, it is ignored as an error.</li>
-</ul>
-<p>  Actions</p>
-<p> Actions are named sequences of commands. Actions have a trigger used to determine when the action should occur. When an event
-  occurs which matches an action's trigger, that action is added to
-  the tail of a to-be-executed queue (unless it is already on the
-  queue).<br />
-  <br />
-  Each action in the queue is dequeued in sequence. Each command in
-  an action is executed in sequence.&nbsp;Init handles other activities
-  (such as, device creation/destruction, property setting, process restarting) &quot;between&quot; the execution of the commands in activities.
-<p>Actions take the form of:</p>
-<pre class="prettify">
-on &lt;trigger&gt;
-&nbsp; &lt;command&gt;
-&nbsp; &lt;command&gt;
-&nbsp; &lt;command&gt;
-</pre>
-<p>Services</p>
-<p>Services are programs that init launches and (optionally) restarts
-when they exit. </p>
-<p>Services take the form of:</p>
-<pre class="prettify">
-  service &lt;name&gt; &lt;pathname&gt; [ &lt;argument&gt; ]*
-&nbsp; &lt;option&gt;
-&nbsp; &lt;option&gt;
-&nbsp; ...
-</pre>
-<p>Options</p>
-  <p> Options are modifiers to services that affect how and when init
-runs a service. Options are described in the table below:</p>
-<table>
-  <tr>
-    <th scope="col">Option</th><th scope="col">Description</th></tr>
-  <tr>
-    <td><code>disabled</code></td>
-    <td>This service will not automatically start with its class. It must be explicitly started by name.</td>
-  </tr>
-  <tr>
-    <td><code>socket &lt;type&gt; &lt;name&gt; &lt;perm&gt; [ &lt;user&gt; [ &lt;group&gt; ] ]</code></td>
-    <td> Create a unix domain socket named <code>/dev/socket/&lt;name&gt;</code> and pass its fd to the launched process. Valid <code>&lt;type&gt;</code> values include <code>dgram</code> and <code>stream</code>. <code>user</code> and <code>group</code> default to 0.</td>
-  </tr>
-  <tr>
-    <td><code>user &lt;username&gt;</code></td>
-    <td>Change to username before exec'ing this service. Currently defaults to root.</td>
-  </tr>
-  <tr>
-    <td><code>group &lt;groupname&gt; [ &lt;groupname&gt; ]*</code></td>
-    <td> Change to groupname before exec'ing this service. &nbsp;Additional&nbsp; groupnames beyond the first, which is required, are used to set additional groups of the process (with <code>setgroups()</code>). Currently defaults to root.</td>
-  </tr>
-  <tr>
-    <td><code>capability [ &lt;capability&gt; ]+</code></td>
-    <td>Set linux capability before exec'ing this service</td>
-  </tr>
-  <tr>
-    <td><code>oneshot</code></td>
-    <td>Do not restart the service when it exits.</td>
-  </tr>
-  <tr>
-    <td><code>class &lt;name&gt;</code></td>
-    <td>Specify a class name for the service. &nbsp;All services in a named class must start and stop together. A service is considered of class &quot;default&quot; if one is not specified via the class option.</td>
-  </tr>
-</table>
-  <p>  Triggers</p>
-  <p>Triggers are strings used to match certain kinds of events that cause an action to occur.  </p>
-  <table>
-    <tr>
-      <th scope="col">Trigger</th>
-      <th scope="col">Description</th>
-    </tr>
-    <tr>
-      <td><code>boot</code></td>
-      <td>This is the first trigger that occurs when init starts (after <code>/init.conf</code> is loaded).</td>
-    </tr>
-    <tr>
-      <td><code>&lt;name&gt;=&lt;value&gt;</code></td>
-      <td>Triggers of this form occur when the property <code>&lt;name&gt;</code> is set to the specific value <code>&lt;value&gt;</code>.</td>
-    </tr>
-    <tr>
-      <td><code>device-added-&lt;path&gt;<br />
-  device-removed-&lt;path&gt;</code></td>
-      <td>Triggers of these forms occur when a device node is added or removed.</td>
-    </tr>
-    <tr>
-      <td><code> service-exited-&lt;name&gt;</code></td>
-      <td>Triggers of this form occur when the specified service exits.</td>
-    </tr>
-  </table>
-  <p><br />
-  Commands</p>
-  <table>
-    <tr>
-      <th scope="col">Command</th>
-      <th scope="col">Description</th>
-    </tr>
-    <tr>
-      <td><code>exec &lt;path&gt; [ &lt;argument&gt; ]*</code></td>
-      <td>Fork and execute a program (<code>&lt;path&gt;</code>). This will block until the program completes execution. Try to avoid exec. Unlike the <code>builtin</code> commands, it runs the risk of getting init &quot;stuck&quot;.</td>
-    </tr>
-    <tr>
-      <td><code>export &lt;name&gt; &lt;value&gt;</code></td>
-      <td>Set the environment variable <code>&lt;name&gt;</code> equal to <code>&lt;value&gt;</code> in the global environment (which will be inherited by all processes started after this command is executed).</td>
-    </tr>
-    <tr>
-      <td><code>ifup &lt;interface&gt;</code></td>
-      <td>Bring the network interface <code>&lt;interface&gt;</code> online.</td>
-    </tr>
-    <tr>
-      <td><code>import &lt;filename&gt;</code></td>
-      <td> Parse an init config file, extending the current configuration.</td>
-    </tr>
-    <tr>
-      <td><code>hostname &lt;name&gt;</code></td>
-      <td>Set the host name.</td>
-    </tr>
-    <tr>
-      <td><code>class_start &lt;serviceclass&gt;</code></td>
-      <td>Start all services of the specified class if they are not already running.</td>
-    </tr>
-    <tr>
-      <td><code>class_stop &lt;serviceclass&gt;</code></td>
-      <td>Stop all services of the specified class if they are currently running.</td>
-    </tr>
-    <tr>
-      <td><code>domainname &lt;name&gt;</code></td>
-      <td>Set the domain name.</td>
-    </tr>
-    <tr>
-      <td><code>insmod &lt;path&gt;</code></td>
-      <td>Install the module at <code>&lt;path&gt;</code>.</td>
-    </tr>
-    <tr>
-      <td><code>mkdir &lt;path&gt;</code></td>
-      <td>Make a directory at <code>&lt;path&gt;</code>.</td>
-    </tr>
-    <tr>
-      <td><code>mount &lt;type&gt; &lt;device&gt; &lt;dir&gt; [ &lt;mountoption&gt; ]*</code></td>
-      <td>Attempt to mount the named device at the directory <code>&lt;dir&gt;</code>         <code>&lt;device&gt;</code>. This may be of the form mtd@name to specify a mtd block device by name.</td>
-    </tr>
-    <tr>
-      <td><code>setkey</code></td>
-      <td>- currenlty undefined - </td>
-    </tr>
-    <tr>
-      <td><code>setprop &lt;name&gt; &lt;value&gt;</code></td>
-      <td>Set system property <code>&lt;name&gt;</code> to <code>&lt;value&gt;</code>.</td>
-    </tr>
-    <tr>
-      <td><code> setrlimit &lt;resource&gt; &lt;cur&gt; &lt;max&gt;</code></td>
-      <td>Set the rlimit for a resource.</td>
-    </tr>
-    <tr>
-      <td><code>start &lt;service&gt;</code></td>
-      <td>Start a service running if it is not already running.</td>
-    </tr>
-    <tr>
-      <td><code> stop &lt;service&gt;</code></td>
-      <td>Stop a service from running if it is currently running.</td>
-    </tr>
-    <tr>
-      <td><code>symlink &lt;target&gt; &lt;path&gt;</code></td>
-      <td>Create a symbolic link at <code>&lt;path&gt;</code> with the value <code>&lt;target&gt;</code>.</td>
-    </tr>
-    <tr>
-      <td><code>write &lt;path&gt; &lt;string&gt; [ &lt;string&gt; ]*</code></td>
-      <td>Open the file at <code>&lt;path&gt;</code> and write one or more strings to it with write(2).</td>
-    </tr>
-  </table>
-  <p>    Properties</p>
-    Init updates some system properties to provide some insight into<br />
-    what it's doing:</p>
-  <table>
-    <tr>
-      <th scope="col">Property</th>
-      <th scope="col">Description</th>
-    </tr>
-    <tr>
-      <td><code>init.action</code></td>
-      <td>Equal to the name of the action currently being executed or &quot;&quot; if none.</td>
-    </tr>
-    <tr>
-      <td><code>init.command</code></td>
-      <td>Equal to the command being executed or &quot;&quot; if none.</td>
-    </tr>
-    <tr>
-      <td><code>init.svc.&lt;name&gt;</code></td>
-      <td>State of a named service (&quot;stopped&quot;, &quot;running&quot;, or &quot;restarting&quot;).</td>
-    </tr>
-  </table>
-  <p>Example init.conf</p>
-  <p>The following snippet is an incomplete example of the <code>init.conf</code> file, simply meant to give you an idea of what a proper configuration resembles.</p>
-  <pre class="prettify">
-on boot
-  export PATH /sbin:/system/sbin:/system/bin
-  export LD_LIBRARY_PATH /system/lib
-
-  mkdir /dev
-  mkdir /proc
-  mkdir /sys
-
-
-  mount tmpfs tmpfs /dev
-  mkdir /dev/pts
-  mkdir /dev/socket
-  mount devpts devpts /dev/pts
-  mount proc proc /proc
-  mount sysfs sysfs /sys
-
-
-  write /proc/cpu/alignment 4
-
-
-  ifup lo
-
-
-  hostname localhost
-  domainname localhost
-
-
-  mount yaffs2 mtd@system /system
-  mount yaffs2 mtd@userdata /data
-
-
-  import /system/etc/init.conf
-
-
-  class_start default
-
-
-service adbd /sbin/adbd
-  user adb
-  group adb
-
-
-service usbd /system/bin/usbd -r
-  user usbd
-  group usbd
-  socket usbd 666
-
-
-service zygote /system/bin/app_process -Xzygote /system/bin --zygote
-  socket zygote 666
-
-
-service runtime /system/bin/runtime
-  user system
-  group system
-
-
-on device-added-/dev/compass
-  start akmd
-
-
-on device-removed-/dev/compass
-  stop akmd
-
-
-service akmd /sbin/akmd
-  disabled
-  user akmd
-  group akmd
-</pre>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/build_new_device.html b/pdk/docs/build_new_device.html
deleted file mode 100755
index cbf9ed7..0000000
--- a/pdk/docs/build_new_device.html
+++ /dev/null
@@ -1,333 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20build_new_device.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidBuildNewTitle"></a><h1>Building Android for a new Mobile Device</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidOHDPortingDeviceBuildingProcess">Detailed Instructions</a><br/>
-<a href="#androidBuildNewFileTree">New Product File Tree</a><br/></div></font></div>
-
-<a name="androidOHDPortingDeviceBuildingProcess"></a><h2>Detailed Instructions</h2>
-
-<p>The directions below describe how to configure make files for new mobile devices and products.</p>
-<ol>
-  <li>Create a company directory in <code>//device/partner</code>.<br/>
-  <pre class="prettyprint">
-  mkdir device/partner/&lt;company_name&gt;</pre></li>
-  <li>Create a <code>products</code> directory beneath the company directory you created in step 1.<BR>
-  <pre class="prettyprint">
-  mkdir device/partner/&lt;company_name&gt;/products/</pre></li>
-  <li>Create a product-specific make file, called <code>device/partner/&lt;company_name&gt;/products/&lt;first_product_name&gt;.mk</code>, that includes the following code:<BR>
-    <pre class="prettyprint">
-  $(call inherit-product, target/product/generic.mk)
-  #
-  # Overrides
-  PRODUCT_NAME := &lt;first_product_name&gt;
-  PRODUCT_DEVICE := &lt;board_name&gt;</pre></li>  
-  <li>In the <code>products</code> directory, create an <code>AndroidProducts.mk</code> file that point to (and is responsible for finding) the individual product make files.<BR>
-  <pre class="prettypring">
-  #
-  # This file should set PRODUCT_MAKEFILES to a list of product makefiles
-  # to expose to the build system.  LOCAL_DIR will already be set to
-  # the directory containing this file. 
-  #
-  # This file may not rely on the value of any variable other than
-  # LOCAL_DIR; do not use any conditionals, and do not look up the
-  # value of any variable that isn't set in this file or in a file that
-  # it includes.
-  #
-  
-  PRODUCT_MAKEFILES := \
-    $(LOCAL_DIR)/first_product_name.mk \</pre></li>
-  <li>Create a board-specific directory beneath your company directory that matches the <code>PRODUCT_DEVICE</code> variable <code>&lt;board_name&gt;</code> referenced in the product-specific make file above. This will include a make file that gets accessed by any product using this board.<BR>
-  <pre class="prettyprint">
-  mkdir device/partner/&lt;company_name&gt;/&lt;board_name&gt;</pre></li>
-    <li>Create a <code>product_config.mk</code> file in the directory created in the previous step (<code>device/partner/&lt;company_name&gt;/&lt;board_name&gt;</code>). If this directory does not include a <code>product_config.mk</code> file, the build will fail.<BR>
-  <pre class="prettyprint">
-  # These definitions override the defaults in config/config.make for &lt;board_name&gt;
-  #
-  # TARGET_NO_BOOTLOADER := false
-  # TARGET_HARDWARE_3D := false 
-  #
-  TARGET_USE_GENERIC_AUDIO := true</pre></li>  
-  <li>If you wish to modify system properties, create a <code>system.prop</code> file in your <code>&lt;board_name&gt;</code> directory(<code>device/partner/&lt;company_name&gt;/&lt;board_name&gt;</code>).<BR>
-  <pre class="prettyprint">
-  # system.prop for <board_name>
-  # This overrides settings in the products/generic/system.prop file
-  #
-  # rild.libpath=/system/lib/libreference-ril.so
-  # rild.libargs=-d /dev/ttyS0</pre></li>   
-  <li>Add a pointer to <code>&lt;second_product_name&gt;.mk</code> within <code>products/AndroidProducts.mk</code>.<BR>
-  <pre class="prettypring">
-  PRODUCT_MAKEFILES := \
-    $(LOCAL_DIR)/first_product_name.mk \
-    $(LOCAL_DIR)/second_product_name.mk</pre></li>
-  <li><code>device/partner/&lt;company_name&gt;/&lt;board_name&gt;</code> must include an <code>Android.mk</code> file with at least the following code:<BR><BR>
-  <pre class="prettyprint">
-  # make file for new hardware <board_name> from <company_name>
-  #
-  LOCAL_PATH := $(call my-dir)
-  #
-  # this is here to use the pre-built kernel
-  ifeq ($(TARGET_PREBUILT_KERNEL),)
-  TARGET_PREBUILT_KERNEL := $(LOCAL_PATH)/kernel
-  endif
-  #
-  file := $(INSTALLED_KERNEL_TARGET)
-  ALL_PREBUILT += $(file)
-  $(file): $(TARGET_PREBUILT_KERNEL) | $(ACP)
-		$(transform-prebuilt-to-target)
-  #
-  # no boot loader, so we don't need any of that stuff..  
-  #
-  LOCAL_PATH := partner/&lt;company_name&gt;/&lt;board_name&gt;
-  #
-  include $(CLEAR_VARS)
-  #
-  # include more board specific stuff here? Such as Audio parameters.      
-  #</pre></li>
-<li>To create a second product for the same board, create a second product-specific make file called <code>device/partner/company_name/products/&lt;second_product_name&gt;.mk</code> that includes:<BR>
-<pre class="prettyprint">
-  $(call inherit-product, partner/google/products/generic.mk)
-  #
-  # Overrides
-  PRODUCT_NAME := &lt;second_product_name&gt;
-  PRODUCT_DEVICE := &lt;board_name&gt;</pre></li>   	
-</ol>
-<p>By now, you should have two new products, called <code>&lt;first_product_name&gt;</code> and <code>&lt;second_product_name&gt;</code> associated with <code>&lt;company_name&gt;</code>. To verify that a product is properly configured (<code>&lt;first_product_name&gt;</code>, for example), execute the following:<BR>
-<pre class="prettyprint">
-  cd device
-  . ./envsetup.sh
-  partner_setup &lt;first_product_name&gt;
-  make PRODUCT-&lt;first_product_name&gt;-user
-</pre>
-<p>You should find new build binaries located in <code>device/out/target/product/&lt;board_name&gt;</code>.
-
-
-<a name="androidBuildNewFileTree"></a><h2>New Product File Tree</h2>
-
-<p>The file tree below illustrates what your own system should look like after completing the steps above.</p>
-<p>
-<ul>
-  <li><code>&lt;company_name&gt;</code></li>
-  <ul>
-    <li><code>&lt;board_name&gt;</code></li>
-    <ul>
-      <li><code>Android.mk</code></li>
-      <li><code>product_config.mk</code></li>
-      <li><code>system.prop</code></li>
-    </ul>
-    <li><code>products</code></li>
-    <ul>
-      <li><code>AndroidProducts.mk</code></li>
-      <li><code>&lt;first_product_name&gt;.mk</code></li>
-      <li><code>&lt;second_product_name&gt;.mk</code></li>
-    </ul>
-  </ul>
-</ul>
-</p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/build_system.html b/pdk/docs/build_system.html
deleted file mode 100755
index 4286e71..0000000
--- a/pdk/docs/build_system.html
+++ /dev/null
@@ -1,458 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20build_system.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidBuildSystemTitle"></a><h1>Android Build System</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidBuildSystemIntroduction">Introduction</a><br/>
-<a href="#androidBuildSystemUnderstanding">Understanding Android's Build System</a><br/><div style="padding-left:40px">
-
-<a href="#androidBuildSystemOverview">Understanding the makefile</a><br/>
-<a href="#androidBuildSystemLayers">Layers</a><br/>
-<a href="#androidBuildSystemProductDefFiles">Product Definition Files</a><br/></div>
-<a href="#androidSourceSetupBuildingCodeBase">Building the Android Platform</a><br/><div style="padding-left:40px">
-
-<a href="#androidSourceSetupBuildingDeviceCodeBase">Device Code</a><br/>
-<a href="#androidBuildingCleaning">Cleaning Up</a><br/>
-<a href="#androidBuildingSpeeding">Speeding Up Rebuilds</a><br/>
-<a href="#androidBuildingTroubleshooting">Troubleshooting</a><br/></div>
-<a href="#androidSourceSetupBuildingKernel">Building the Android Kernel</a><br/><div style="padding-left:40px">
-
-<a href="#androidSourceSetupBuildingKernelCheckingBranch">Checking Out a Branch</a><br/>
-<a href="#androidSourceSetupBuildingKernelBranchLocation">Verifying Location</a><br/>
-<a href="#androidSourceSetupBuildingKernelBuild">Building the Kernel</a><br/></div></div></font></div>
-
-<a name="androidBuildSystemIntroduction"></a><h2>Introduction</h2>
-
-<p>Android uses a custom build system to generate tools, binaries, and documentation. This document provides an overview of Android's build system and instructions for doing a simple build. </p>
-<p>Android's build system is make based and requires a recent version of GNU Make (note that Android uses advanced features of GNU Make that may not yet appear on the GNU Make web site). Before continuing, check your version of make by running <code>% make -v</code>. If you don't have version 3.80 or greater, you need to <a href="http://www.gnu.org/software/make/">upgrade your version of make</a>. </p>
-
-
-<a name="androidBuildSystemUnderstanding"></a><h2>Understanding Android's Build System</h2>
-
-
-
-<a name="androidBuildSystemOverview"></a><h3>Understanding the makefile</h3>
-
-<p>A makefile defines how to build a particular application. Makefiles typically include all of the following elements:</p>
-<ol>
-  <li>Name: Give your build a name (<code>LOCAL_MODULE := &lt;build_name&gt;</code>).</li>
-  <li>Local Variables: Clear local variables with CLEAR_VARS  (<code>include $(CLEAR_VARS)</code>).</li>
-  <li>Files: Determine which files your application depends upon (<code>LOCAL_SRC_FILES := main.c</code>).</li>
-  <li>Tags: Define tags, as necessary (<code>LOCAL_MODULE_TAGS := eng development</code>).</li>
-  <li>Libraries: Define whether your application links with other libraries (<code>LOCAL_SHARED_LIBRARIES := cutils</code>).</li>
-  <li>Template file: Include a template file to define underlining make tools for a particular target (<code>include $(BUILD_EXECUTABLE)</code>).</li>
-</ol>
-
-<p>The following snippet illustrates a typical makefile.</p>
-<pre class="prettyprint">
-LOCAL_PATH := $(my-dir)
-include $(CLEAR_VARS)
-LOCAL_MODULE := &lt;buil_name&gt;
-LOCAL_SRC_FILES := main.c
-LOCAL_MODULE_TAGS := eng development
-LOCAL_SHARED_LIBRARIES := cutils
-include $(BUILD_EXECUTABLE)
-(HOST_)EXECUTABLE, (HOST_)JAVA_LIBRARY, (HOST_)PREBUILT, (HOST_)SHARED_LIBRARY,
-  (HOST_)STATIC_LIBRARY, PACKAGE, JAVADOC, RAW_EXECUTABLE, RAW_STATIC_LIBRARY,
-  COPY_HEADERS, KEY_CHAR_MAP
-</pre>
-<p>The snippet above includes artificial line breaks to maintain a print-friendly document.</p>
-
-
-<a name="androidBuildSystemLayers"></a><h3>Layers</h3>
-
-<p>The build hierarchy includes the abstraction layers described in the table below.</p>
-
-<p>Each layer relates to the one above it in a one-to-many relationship. For example, an arch can have more than one board and each board can have more than one device. You may define an element in a given layer as a specialization of an element in the same layer, thus eliminating copying and simplifying maintenance.</p>
- 
-<table border=1 cellpadding=2 cellspacing=0>
- <tbody><tr>
-  <th scope="col">Layer</th>
-  <th  scope="col">Example</th>
-  <th  scope="col">Description</th>
- </tr>
-  <tr>
-    <td valign="top">Product</td>
-    <td valign="top">myProduct, myProduct_eu, myProduct_eu_fr, j2, sdk</td>
-    <td valign="top">The product layer defines a complete specification of a shipping product, defining which modules to build and how to configure them. You might offer a device in several different versions based on locale, for example, or on features such as a camera. </td>
-  </tr>
-  <tr>
-    <td valign="top">Device</td>
-    <td valign="top">myDevice, myDevice_eu, myDevice_eu_lite</td>
-    <td valign="top">The device layer represents the physical layer of plastic on the device. For example, North American devices probably include QWERTY keyboards whereas devices sold in France probably include AZERTY keyboards. Peripherals typically connect to the device layer. </td>
-  </tr>
-  <tr>
-    <td valign="top">Board</td>
-    <td valign="top">sardine, trout, goldfish </td>
-    <td valign="top">The board layer represents the bare schematics of a product. You may still connect peripherals to the board layer. </td>
-  </tr>
-  <tr>
-    <td valign="top">Arch</td>
-    <td valign="top">arm (arm5te) (arm6), x86, 68k </td>
-    <td valign="top">The arch layer describes the processor running on your board. </td>
-  </tr>
-</table>
-
-
-<a name="androidBuildSystemProductDefFiles"></a><h3>Product Definition Files</h3>
-
-<p>Product-specific variables are defined in product definition files. A product definition file can inherit from other product definition files, thus reducing the need to copy and simplifying maintenance.</p>
-<p>Variables maintained in a product definition files include:</p>
-<p><ul>
-<li><code>PRODUCT_DEVICE</code></LI>
-<LI><code>LOCALES</code></LI>
-<LI><code>BRANDING_PARTNER</code></LI>
-<LI><code>PROPERTY_OVERRIDES</code></LI>
-</UL>
-</P>
-<p>The snippet below illustrates a typical product definition file.</p>
-<PRE class="prettyprint">
-//device/target/product/core.mk
-PRODUCT_PACKAGES := Home SettingsProvider ...
-//device/target/product/generic.mk
-PRODUCT_PACKAGES := Calendar Camera SyncProvider ...
-$(call inherit-product, target/product/core.mk)
-PRODUCT_NAME := generic
-//device/partner/google/products/core.mk
-PRODUCT_PACKAGES := Maps GoogleAppsProvider ...
-$(call inherit-product, target/product/core.mk)
-//device/partner/google/products/generic.mk
-PRODUCT_PACKAGES := Gmail GmailProvider ...
-$(call inherit-product, partner/google/products/core.mk)
-$(call inherit-product, target/product/generic.mk)
-PRODUCT_NAME := google_generic
-
-</pre>
-
-
-<a name="androidSourceSetupBuildingCodeBase"></a><h2>Building the Android Platform</h2>
-
-<p>This section describes how to build the default version of Android. Once you are comfortable with a generic build, then you can begin to modify Android for your own target device.</p>
-
-
-<a name="androidSourceSetupBuildingDeviceCodeBase"></a><h3>Device Code</h3>
-
-<p>Of the two options below, the first tends to yield more consistent results.</p>
-
-
-<a name="androidSourceSetupBuildingDeviceCodeBaseOption2"></a><h4>Option 1</h4>
-
-<p>Create a local version of buildspec.mk. The easiest way to do so is to change to your device directory and execute the following:</p>
-<pre class="prettyprint">% cp buildspec.mk.default buildspec.mk ; chmod u=rw buildspec.mk</pre>
-<p>The default <code>buildspec.mk</code>. file is written so that all options appear commented. In order to establish a personal configuration environment, edit <code>buildspec.mk</code> as desired.</p>
-<p>Once you have established your configuration environment, you can build the device code base by executing make in order to build the Android binaries. This may take a long time the first time you issue this command. On a dual-core machine, consider using '-j2' (or even '-j4') to speed up the build.</p>
-<pre class="prettyprint">% make -j2</pre>
-
-
-<a name="androidSourceSetupBuildingDeviceCodeBaseOption1"></a><h4>Option 2</h4>
-
-<p>To do a generic build of android, source <code>//device/envsetup.sh</code>, which contains necessary variable and function definitions, as described below.</p>
-<pre class="prettyprint">
-% cd $TOP
-
-% . envsetup.sh
-
-% partner_setup generic
-   //select generic as the product
-
-% make -j4 PRODUCT-generic-user
-</pre>
-<p>You can also replace user with eng for a debug engineering build:</p>
-
-<pre class="prettyprint">
-% make -j4 PRODUCT-generic-eng
-</pre>
-
-
-<a name="androidBuildingCleaning"></a><h3>Cleaning Up</h3>
-
-<p>Execute <code>% m clean</code> to clean up the binaries you just created. You can also execute <code>% m clobber</code> to get rid of the binaries of all combos. <code>% m clobber</code> is equivalent to removing the <code>//device/out/</code> directory where all generated files are stored.</p>
-
-
-<a name="androidBuildingSpeeding"></a><h3>Speeding Up Rebuilds</h3>
-
-<p> The binaries of each combo are stored as distinct sub-directories of <code>//device/out/</code>, making it possible to quickly switch between combos without having to recompile all sources each time. </p>
-<p> However, performing a clean rebuild is necessary if the build system doesn't catch changes to environment variables or makefiles. If this happens often, you should define the <code>USE_CCACHE</code> environment variable as shown below: </p>
-<pre class="prettyprint">
-% export USE_CCACHE=1
-</pre>
-<p>Doing so will force the build system to use the ccache compiler cache tool, which reduces recompiling all sources.</p>
-
-<p><code>ccache</code> binaries are provided in <code>//device/prebuilt/...</code> and don't need to get installed on your system.</p>
-
-
-<a name="androidBuildingTroubleshooting"></a><h3>Troubleshooting</h3>
-
-<p>The following error is likely caused by running an outdated version of Java.</p>
-<pre class="prettyprint">
-device Dex: core  UNEXPECTED TOP-LEVEL ERROR:
-java.lang.NoSuchMethodError: method java.util.Arrays.hashCode with
-signature ([Ljava.lang.Object;)I was not found.
-  at com.google.util.FixedSizeList.hashCode(FixedSizeList.java:66)
-  at com.google.rop.code.Rop.hashCode(Rop.java:245)
-  at java.util.HashMap.hash(libgcj.so.7)
-[...]
-</pre>
-<p><code>dx</code> is a Java program that uses facilities first made available in Java version 1.5. Check your version of Java by executing <code>% java -version</code> in the shell you use to build. You should see something like:</p>
-<pre class="prettyprint">
-java version "1.5.0_07"
-Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_07-164)
-Java HotSpot(TM) Client VM (build 1.5.0_07-87, mixed mode, sharing)
-</pre>
-<p>If you do have Java 1.5 or later and your receive this error, verify that you have properly updated your <code>PATH</code> variable.</p>
-
-
-<a name="androidSourceSetupBuildingKernel"></a><h2>Building the Android Kernel</h2>
-
-<p>This section describes how to build Android's default kernel. Once you are comfortable with a generic build, then you can begin to modify Android drivers for your own target device.</p>
-
-
-<p>To build the kernel base, switch to the device directory (<code>/home/joe/android/device</code>) in order to establish variables and run:
-<pre class="prettyprint">
-% . envsetup.sh
-% partner_setup generic
-</pre>
-<p>Then switch to the kernel directory <code>/home/joe/android/kernel</code>.
-
-
-<a name="androidSourceSetupBuildingKernelCheckingBranch"></a><h3>Checking Out a Branch</h3>
-
-<p>The default branch is always <code>android</code>. To check out a different branch, execute the following:</p>
-
-<pre class="prettyprint">
-% git checkout --track -b android-mydevice origin/android-mydevice
-  //Branch android-mydevice set up to track remote branch
-% refs/remotes/origin/android-mydevice.
-  //Switched to a new branch "android-mydevice"
-</pre>
-
-<p>To simplify code management, give your local branch the same name as the remote branch it is tracking (as illustrated in the snippet above). Switch between branches by executing <code>% git checkout &lt;branchname&gt;</code>.</p>
-
-
-<a name="androidSourceSetupBuildingKernelBranchLocation"></a><h3>Verifying Location</h3>
-
-<p>Find out which branches exist (both locally and remotely) and which one is active (marked with an asterisk) by executing the following:</p>
-<pre class="prettyprint">
-% git branch -a
-  android
-* android-mydevice
-  origin/HEAD
-  origin/android
-  origin/android-mydevice
-  origin/android-mychipset
-</pre>
-<p>To only see local branches, omit the <code>-a</code> flag.</p> 
-
-
-<a name="androidSourceSetupBuildingKernelBuild"></a><h3>Building the Kernel</h3>
-
-<p>To build the kernel, execute:</p>
-<pre class="prettyprint">
-% make -j4
-</pre>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/camera.html b/pdk/docs/camera.html
deleted file mode 100755
index 1b65659..0000000
--- a/pdk/docs/camera.html
+++ /dev/null
@@ -1,280 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20camera.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidCameraTitle"></a><h1>Camera Subsystem</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidCameraIntroduction">Introduction</a><br/>
-<a href="#androidCameraBuildingDriver">Building a Camera Library</a><br/>
-<a href="#androidCameraSequenceDiagrams">Sequence Diagrams</a><br/><div style="padding-left:40px">
-
-<a href="#androidCameraSequenceDiagramsPreview">Preview</a><br/>
-<a href="#androidCameraSequenceDiagramsTakePic">Taking a Picture</a><br/></div>
-<a href="#androidCameraInterfaceIntro">Interface</a><br/></div></font></div>
-
-<a name="androidCameraIntroduction"></a><h2>Introduction</h2>
-
-<p>Android's camera subsystem connects the camera application to the application framework and user space libraries, which in turn communicate with the camera hardware layer that operates the physical camera.</p>
-<p>The diagram below illustrates the structure of the camera subsystem.</p>
-<p><img src="androidCameraArchitecture.gif"></p>
-
-
-<a name="androidCameraBuildingDriver"></a><h2>Building a Camera Library</h2>
-
-<p>To implement a camera driver, create a shared library that implements the interface defined in <code>CameraHardwareInterface.h</code>. You must name your shared library <code>libcamera.so</code> so that it will get loaded from <code>/system/lib</code> at runtime.  Place libcamera sources and <code>Android.mk</code> in <code>partner/acme/chipset_or_board/libcamera/</code>.</p>
-<p>The following stub <code>Android.mk</code> file ensures that <code>libcamera</code> compiles and links to the appropriate libraries:</p>
-<pre class="prettify">
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := libcamera
-
-LOCAL_SHARED_LIBRARIES := \
-    libutils \
-    librpc \
-    liblog
-
-LOCAL_SRC_FILES += MyCameraHardware.cpp
-
-LOCAL_CFLAGS +=
-
-LOCAL_C_INCLUDES +=
-
-LOCAL_STATIC_LIBRARIES += \
-    libcamera-common \
-    libclock-rpc \
-    libcommondefs-rpc
-
-include $(BUILD_SHARED_LIBRARY)
-</pre>
-
-
-<a name="androidCameraSequenceDiagrams"></a><h2>Sequence Diagrams</h2>
-
-
-
-<a name="androidCameraSequenceDiagramsPreview"></a><h3>Preview</h3>
-
-<p>The following diagram illustrates the sequence of function calls and actions necessary for your camera to preview.</p>
-<img src="cameraPreview.jpg">
-
-
-<a name="androidCameraSequenceDiagramsTakePic"></a><h3>Taking a Picture</h3>
-
-<p>The following diagram illustrates the sequence of function calls and actions necessary for your camera to take a picture.</p>
-<img src="cameraTakePicture.jpg">
-
-
-<a name="androidCameraInterfaceIntro"></a><h2>Interface</h2>
-
-
-
-<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="camera.html">click here</a>.</p>
-
-
-<iframe onLoad="resizeHeight();" src="CameraHardwareInterface_8h.html " scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/cameraPreview.jpg b/pdk/docs/cameraPreview.jpg
deleted file mode 100755
index 3dea011..0000000
--- a/pdk/docs/cameraPreview.jpg
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/cameraTakePicture.jpg b/pdk/docs/cameraTakePicture.jpg
deleted file mode 100755
index 4ac6d95..0000000
--- a/pdk/docs/cameraTakePicture.jpg
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/display_drivers.html b/pdk/docs/display_drivers.html
deleted file mode 100755
index c20afe5..0000000
--- a/pdk/docs/display_drivers.html
+++ /dev/null
@@ -1,544 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20display_drivers.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidDisplayDriversTitle"></a><h1>Display Drivers</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidDisplayDriverIntroduction">Introduction</a><br/>
-<a href="#androidDisplayDriverFunctionality">Functionality</a><br/>
-<a href="#androidDisplayDriversSourceTemplate">Implementing Your Own Driver (Driver Template)</a><br/>
-<a href="#androidDisplayDriversTroubleshooting">Troubleshooting</a><br/></div></font></div>
-
-<a name="androidDisplayDriverIntroduction"></a><h2>Introduction</h2>
-
-<p>This section describes how the display driver functions and offers a functional template designed to help you build your own device-specific driver.</p>
-<p>Android relies on the standard frame buffer device (<code>/dev/fb0</code> or <code>/dev/graphics/fb0</code>) and driver as described in the <code>linux/fb.h</code> kernel header file. For more information regarding the standard Linux frame buffer, please see <a href="http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.24.y.git;a=blob;f=Documentation/fb/framebuffer.txt">The Frame Buffer Device</a> at <a href="http://kernel.org">http://kernel.org</a>.
-
-
-<a name="androidDisplayDriverFunctionality"></a><h2>Functionality</h2>
-
-<p>In Android, every window gets implemented with an underlying Surface object, an object that gets placed on the framebuffer by SurfaceFlinger, the system-wide screen composer. Each Surface is double-buffered. The back buffer is where drawing takes place and the front buffer is used for composition. </p>
-<p> When <code>unlockCanvas()</code> is called, the back buffer is posted, which 
-  means that it gets displayed and &nbsp;becomes available again. Android flips the front and back buffers, ensuring a minimal amount of buffer copying and that there is always a buffer for SurfaceFlinger to use for composition (which ensures that the screen never flickers or shows artifacts).</p>
-<p>Android makes two requirements of the driver: a linear address space of mappable memory that it can write to directly and support for the rgb_565 pixel format. A typical frame display includes:</p>
-<ul>
-  <li>accessing the driver by calling open on <code>/dev/fb0</code></li>
-  <li>using the <code>FBIOGET_FSCREENINFO</code> and <code>FBIOGET_VSCREENINFO</code> Input / Output Control (ioctl) calls to retrieve information about the screen</li>
-  <li>using <code>FBIOPUT_VSCREENINFO</code> ioctl to attempt to create a virtual display twice the size of the physical screen and to set the pixel format to rgb_565. If this succeeds, double buffering is accomplished with video memory. </li>
-</ul>
-<p>When a page flip is required, Android makes another <code>FBIOPUT_VSCREENINFO</code> ioctl call with a new y-offset pointing to the other buffer in video memory.  This ioctl, in turn, invokes the driver's <code>.fb_pan_display</code> function in order to do the actual flip. If there isn't sufficient video memory, regular memory is used and is just copied into the video memory when it is time do the flip. After allocating the video memory and setting the pixel format, Android  uses <code>mmap()</code> to map the memory into the process's address space.  All writes to the frame buffer are done through this mmaped memory.</p>
-<p>To maintain adequate performance, framebuffer memory should be cacheable. If you use write-back, flush the cache before the frame buffer is written from DMA to the LCD. If that isn't possible, you may use write-through. As a last resort, you can also use uncached memory with the write-bugger enabled, but performance will suffer.</p>
-
-
-<a name="androidDisplayDriversSourceTemplate"></a><h2>Implementing Your Own Driver (Driver Template)</h2>
-
-<p>The following sample driver offers a functional example to help you build your own display driver. Modify <code>PGUIDE_FB...</code> macros as desired to match the requirements of your own device hardware.</p>
-<pre class="prettyprint">
-/*
- *  pguidefb.c
- * 
- *  Copyright 2007, Google Inc.
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License version 2 as
- *  published by the Free Software Foundation.
- */
-
-
-/*
- * ANDROID PORTING GUIDE: FRAME BUFFER DRIVER TEMPLATE
- *
- * This template is designed to provide the minimum frame buffer
- * functionality necessary for Android to display properly on a new
- * device.  The PGUIDE_FB macros are meant as pointers indicating
- * where to implement the hardware specific code necessary for the new
- * device.  The existence of the macros is not meant to trivialize the
- * work required, just as an indication of where the work needs to be
- * done.
- */
-
-#include &lt;linux/module.h&gt;
-#include &lt;linux/kernel.h&gt;
-#include &lt;linux/errno.h&gt;
-#include &lt;linux/string.h&gt;
-#include &lt;linux/slab.h&gt;
-#include &lt;linux/delay.h&gt;
-#include &lt;linux/mm.h&gt;
-#include &lt;linux/fb.h&gt;
-#include &lt;linux/init.h&gt;
-#include &lt;linux/platform_device.h&gt;
-
-
-/* Android currently only uses rgb565 in the hardware framebuffer */
-#define ANDROID_BYTES_PER_PIXEL 2
-
-/* Android will use double buffer in video if there is enough */
-#define ANDROID_NUMBER_OF_BUFFERS 2
-
-/* Modify these macros to suit the hardware */
-
-#define PGUIDE_FB_ROTATE 
-	/* Do what is necessary to cause the rotation */
-
-#define PGUIDE_FB_PAN 
-	/* Do what is necessary to cause the panning */
-
-#define PGUIDE_FB_PROBE_FIRST 
-	/* Do any early hardware initialization */
-
-#define PGUIDE_FB_PROBE_SECOND
-	/* Do any later hardware initialization */
-
-#define PGUIDE_FB_WIDTH 320
-	/* Return the width of the screen */
-
-#define PGUIDE_FB_HEIGHT 240
-	/* Return the heighth of the screen */
-
-#define PGUIDE_FB_SCREEN_BASE 0
-	/* Return the virtual address of the start of fb memory */
-
-#define PGUIDE_FB_SMEM_START PGUIDE_FB_SCREEN_BASE
-	/* Return the physical address of the start of fb memory */
-
-#define PGUIDE_FB_REMOVE 
-	/* Do any hardware shutdown */
-
-
-
-
-
-struct pguide_fb {
-	int rotation;
-	struct fb_info fb;
-	u32			cmap[16];
-};
-
-static inline u32 convert_bitfield(int val, struct fb_bitfield *bf)
-{
-	unsigned int mask = (1 << bf->length) - 1;
-
-	return (val >> (16 - bf->length) & mask) << bf->offset;
-}
-
-
-/* set the software color map.  Probably doesn't need modifying. */
-static int
-pguide_fb_setcolreg(unsigned int regno, unsigned int red, unsigned int green,
-		 unsigned int blue, unsigned int transp, struct fb_info *info)
-{
-        struct pguide_fb  *fb = container_of(info, struct pguide_fb, fb);
-
-	if (regno < 16) {
-		fb->cmap[regno] = convert_bitfield(transp, &fb->fb.var.transp) |
-				  convert_bitfield(blue, &fb->fb.var.blue) |
-				  convert_bitfield(green, &fb->fb.var.green) |
-				  convert_bitfield(red, &fb->fb.var.red);
-		return 0;
-	}
-	else {
-		return 1;
-	}
-}
-
-/* check var to see if supported by this device.  Probably doesn't
- * need modifying.
- */
-static int pguide_fb_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
-{
-	if((var->rotate & 1) != (info->var.rotate & 1)) {
-		if((var->xres != info->var.yres) ||
-		   (var->yres != info->var.xres) ||
-		   (var->xres_virtual != info->var.yres) ||
-		   (var->yres_virtual > 
-		    info->var.xres * ANDROID_NUMBER_OF_BUFFERS) ||
-		   (var->yres_virtual < info->var.xres )) {
-			return -EINVAL;
-		}
-	}
-	else {
-		if((var->xres != info->var.xres) ||
-		   (var->yres != info->var.yres) ||
-		   (var->xres_virtual != info->var.xres) ||
-		   (var->yres_virtual > 
-		    info->var.yres * ANDROID_NUMBER_OF_BUFFERS) ||
-		   (var->yres_virtual < info->var.yres )) {
-			return -EINVAL;
-		}
-	}
-	if((var->xoffset != info->var.xoffset) ||
-	   (var->bits_per_pixel != info->var.bits_per_pixel) ||
-	   (var->grayscale != info->var.grayscale)) {
-		return -EINVAL;
-	}
-	return 0;
-}
-
-
-/* Handles screen rotation if device supports it. */
-static int pguide_fb_set_par(struct fb_info *info)
-{
-	struct pguide_fb *fb = container_of(info, struct pguide_fb, fb);
-	if(fb->rotation != fb->fb.var.rotate) {
-		info->fix.line_length = 
-		  info->var.xres * ANDROID_BYTES_PER_PIXEL;
-		fb->rotation = fb->fb.var.rotate;
-		PGUIDE_FB_ROTATE;
-	}
-	return 0;
-}
-
-
-/* Pan the display if device supports it. */
-static int pguide_fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *info)
-{
-	struct pguide_fb *fb    __attribute__ ((unused)) 
-	    = container_of(info, struct pguide_fb, fb);
-
-	/* Set the frame buffer base to something like:
-	   fb->fb.fix.smem_start + fb->fb.var.xres * 
-	   ANDROID_BYTES_PER_PIXEL * var->yoffset
-	*/
-	PGUIDE_FB_PAN;
-
-	return 0;
-}
-
-
-static struct fb_ops pguide_fb_ops = {
-	.owner          = THIS_MODULE,
-	.fb_check_var   = pguide_fb_check_var,
-	.fb_set_par     = pguide_fb_set_par,
-	.fb_setcolreg   = pguide_fb_setcolreg,
-	.fb_pan_display = pguide_fb_pan_display,
-
-	/* These are generic software based fb functions */
-	.fb_fillrect    = cfb_fillrect,
-	.fb_copyarea    = cfb_copyarea,
-	.fb_imageblit   = cfb_imageblit,
-};
-
-
-static int pguide_fb_probe(struct platform_device *pdev)
-{
-	int ret;
-	struct pguide_fb *fb;
-	size_t framesize;
-	uint32_t width, height;
-
-	fb = kzalloc(sizeof(*fb), GFP_KERNEL);
-	if(fb == NULL) {
-		ret = -ENOMEM;
-		goto err_fb_alloc_failed;
-	}
-	platform_set_drvdata(pdev, fb);
-
-	PGUIDE_FB_PROBE_FIRST;
-	width = PGUIDE_FB_WIDTH;
-	height = PGUIDE_FB_HEIGHT;
-
-
-	fb->fb.fbops		= &pguide_fb_ops;
-
-	/* These modes are the ones currently required by Android */
-
-	fb->fb.flags		= FBINFO_FLAG_DEFAULT;
-	fb->fb.pseudo_palette	= fb->cmap;
-	fb->fb.fix.type		= FB_TYPE_PACKED_PIXELS;
-	fb->fb.fix.visual = FB_VISUAL_TRUECOLOR;
-	fb->fb.fix.line_length = width * ANDROID_BYTES_PER_PIXEL;
-	fb->fb.fix.accel	= FB_ACCEL_NONE;
-	fb->fb.fix.ypanstep = 1;
-
-	fb->fb.var.xres		= width;
-	fb->fb.var.yres		= height;
-	fb->fb.var.xres_virtual	= width;
-	fb->fb.var.yres_virtual	= height * ANDROID_NUMBER_OF_BUFFERS;
-	fb->fb.var.bits_per_pixel = 16;
-	fb->fb.var.activate	= FB_ACTIVATE_NOW;
-	fb->fb.var.height	= height;
-	fb->fb.var.width	= width;
-
-	fb->fb.var.red.offset = 11;
-	fb->fb.var.red.length = 5;
-	fb->fb.var.green.offset = 5;
-	fb->fb.var.green.length = 6;
-	fb->fb.var.blue.offset = 0;
-	fb->fb.var.blue.length = 5;
-
-	framesize = width * height * 
-	  ANDROID_BYTES_PER_PIXEL * ANDROID_NUMBER_OF_BUFFERS;
-	fb->fb.screen_base = PGUIDE_FB_SCREEN_BASE;
-	fb->fb.fix.smem_start = PGUIDE_FB_SMEM_START;
-	fb->fb.fix.smem_len = framesize;
-
-	ret = fb_set_var(&fb->fb, &fb->fb.var);
-	if(ret)
-		goto err_fb_set_var_failed;
-
-	PGUIDE_FB_PROBE_SECOND;
-
-	ret = register_framebuffer(&fb->fb);
-	if(ret)
-		goto err_register_framebuffer_failed;
-
-	return 0;
-
-
-err_register_framebuffer_failed:
-err_fb_set_var_failed:
-	kfree(fb);
-err_fb_alloc_failed:
-	return ret;
-}
-
-static int pguide_fb_remove(struct platform_device *pdev)
-{
-	struct pguide_fb *fb = platform_get_drvdata(pdev);
-
-	PGUIDE_FB_REMOVE;
-
-	kfree(fb);
-	return 0;
-}
-
-
-static struct platform_driver pguide_fb_driver = {
-	.probe		= pguide_fb_probe,
-	.remove		= pguide_fb_remove,
-	.driver = {
-		.name = "pguide_fb"
-	}
-};
-
-static int __init pguide_fb_init(void)
-{
-	return platform_driver_register(&pguide_fb_driver);
-}
-
-static void __exit pguide_fb_exit(void)
-{
-	platform_driver_unregister(&pguide_fb_driver);
-}
-
-module_init(pguide_fb_init);
-module_exit(pguide_fb_exit);
-
-MODULE_LICENSE("GPL");
-</pre>
-
-
-<a name="androidDisplayDriversTroubleshooting"></a><h2>Troubleshooting</h2>
-
-<p>Both of the following problems have a similar cause:</p>
-<ul>
-  <li><strong>Number keys</strong>: In the dialer application, when a number key is pressed to dial a phone number, the number doesn't display on the screen until after the next number has been pressed. </li>
-  <li><strong>Arrow keys</strong>: When an arrow key is pressed, the desired icon doesn't get highlighted. For example, if you browse through icons in the Applications menu, you might notice that icons aren't highlighted as expected when you use the arrow key to navigate between options.</li>
-</ul>
-<p>Both problems are caused by an incorrect implementation of the frame buffer's page flipping. Key events are captured, but the graphical interface appears to drop every other frame. </p>
-<p>Android relies on a double buffer to smoothly render page flips (please see <a href="androidDisplayDriverFunctionality">Functionality</a> for details).
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/getting_source_code.html b/pdk/docs/getting_source_code.html
deleted file mode 100755
index ad0cddb..0000000
--- a/pdk/docs/getting_source_code.html
+++ /dev/null
@@ -1,335 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20index.html%20v0.5%20-%2025%20September%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="source_setup_guide.html">Host System Setup</a></li>
-
-            <li><a href="getting_source_code.html">Getting Source Code</a></li>
-            <li> <a href="intro_source_code.html">Source Code Overview</a></li>			
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio Subsystem</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidGettingSourceCodeTitle"></a><h1>Getting Source Code</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidSourceSetupBuildGitSetup">Introduction</a><br/>
-<a href="#androidSourceSetupBuildGitSetupInstall">Installing and Configuring Git</a><br/>
-<a href="#androidSourceSetupBuildGitSetupServer">Establishing Server Access</a><br/><div style="padding-left:40px">
-
-<a href="#androidSourceSetupBuildGitSetupServerRSAKeys">Generating RSA Keys</a><br/>
-<a href="#androidSourceSetupBuildGitSetupServerVerifyConnection">Verifying a Connection to the Git Server</a><br/></div>
-<a href="#androidSourceSetupGetCode">Downloading Code</a><br/>
-<a href="#androidSourceSetupExtractingPatch">Extracting an Android Patch</a><br/></div></font></div>
-
-<a name="androidSourceSetupBuildGitSetup"></a><h2>Introduction</h2>
-
-<p>Android relies on Git, a version control system, to install the Android platform. You will need to install Git 1.5.2 or greater in order to access the source tree. Please visit <a href="http://git.or.cz/">http://git.or.cz/</a> for more information regarding Git.</p>
-<p>Git permits you to control access to working directories, and we recommend that you use it to limit Android repository access to only a few people within your organization (please refer to your Google NDA for potential contractual restraints on sharing Android source access). </p>
-<p>You may clone Google's repository to a local copy for sharing internally (see Git documentation for details).</p>
-
-
-<a name="androidSourceSetupBuildGitSetupInstall"></a><h2>Installing and Configuring Git</h2>
-
-<p>To install the Git package, execute:</p>
-<pre class="prettyprint">
-% sudo apt-get install git-core
-</pre>
-
-
-<a name="androidSourceSetupBuildGitSetupServer"></a><h2>Establishing Server Access</h2>
-
-<p>Once Git is cleanly installed, you need to establish a connection with Google's Git server, a connection that requires an RSA key in order to authenticate requests.</p>
-
-
-<a name="androidSourceSetupBuildGitSetupServerRSAKeys"></a><h3>Generating RSA Keys</h3>
-
-<p>Each developer must have a unique RSA key in order to access Android source code. To generate an RSA key: </p>
-<p>
-<ol>
-<li>Type:<br/>
-<pre class="prettyprint">% ssh-keygen -t rsa -C  email@domain.com</pre><br/>
-You must use a valid email address to create your key.</li>
-<li>When prompted, indicate the file to which you wish to write your key (<code>id_rsa</code> in this example).</li>
-<li>When prompted, associate a passphrase with your key.</li>
-<li>Upon success, you should have two files saved to the designated directory:  </li>
-<ul>
-  <li><code>id_rsa</code>: This file contains the private half of your RSA key. You shouldn't share this file with anyone. </li>
-  <li><code>id_rsa.pub</code>: This is the public half or your RSA key and you should send it to your Google technical account manager.</li>
-  </ul>
-</ol>
-</p>
-<p>Send your Google Account Manager your public key file in order to establish Git server access. </p>
-
-
-<a name="androidSourceSetupBuildGitSetupServerVerifyConnection"></a><h3>Verifying a Connection to the Git Server</h3>
-
-<p>Once you have generated an RSA key and shared the public file with Google, you can test your connection with the Git server with the following command:</p>
-<pre class="prettyprint">
-% ssh  android-git.ext.google.com
-</pre>
-
-<p>You should receive one of the following results:</p>
-
-<table border=1 cellpadding=2 cellspacing=0>
- <tbody><tr>
-  <th scope="col">Result</th>
-  <th scope="col">Cause</th>
-  <th  scope="col">Action</th>
- </tr>
-  <tr>
-    <td>
-<code>fatal: What do you think I am? A shell?<BR>
-Connection to android-git closed.</code>
-</pre>	</td>
-    <td>Success</td>
-    <td>None. You successfully connected to the Git server. (You should not have shell access and it's expected to receive this error.)</td>
-  </tr>
-  <tr>
-    <td>ssh hangs and eventually times out. </td>
-    <td>Your setup is failing to locate and establish a basic connection. </td>
-    <td>Google needs to debug network settings. </td>
-  </tr>
-  <tr>
-    <td>Error: Permission denied &lt;public key&gt; </td>
-    <td>Either you are not using the matching username or the RSA private key does not match the public key. </td>
-    <td>Try executing:<BR> 
-	<code>
-% ssh $USER@android-
-  git.ext.google.com
-</code></td>
-  </tr>
-</table>
-
-
-<a name="androidSourceSetupGetCode"></a><h2>Downloading Code</h2>
-
-<p>Android source code is maintained in two repositories: <code>device</code> and <code>kernel</code>. The <code>device</code> repository includes the Android framework (things like the Activity Manager, Window Manager, Telephony Manager, View System, etc.). The <code>kernel</code> repository includes the core code necessary to run the operating system (things like the Display Driver, Camera Driver, Keypad Driver, Power Management, etc.). (Please see <a href="http://code.google.com/android/what-is-android.html">What is Android?</a> for details.)</p>
-
-<p>Save device and kernel code at the same directory level, for example:</p>
-<p>
-<ul><li><code>/home/joe/android/device</code></li>
-<li><code>/home/joe/android/kernel</code></li>
-</ul></p>
-<p><b>Device Code</b></p>
-<p>To download device code, you need your username and a unique <code>&lt;path&gt;</code> string supplied by Google to execute the following:</p>
-<pre class="prettyprint">
-% git-clone $USER@android-git.ext.google.com:&lt;path&gt;/device.git
-</pre>
-
-<p><b>Kernel Code</b></p>
-<p>To download kernel code, you need your username and a unique <code>&lt;path&gt;</code> string supplied by Google to execute the following:</p>
-<pre class="prettyprint">
-% git-clone $USER@android-git.ext.google.com:&lt;path&gt;/kernel.git
-</pre>
- 
-
-
-<a name="androidSourceSetupExtractingPatch"></a><h2>Extracting an Android Patch</h2>
-
-<p>You likely already have Linux running on your platform and only need to integrate Android-specific changes. The following directions describe how to extract an Android patch.</p>
-<ol>
-  <li>Download a generic version  of the Linux kernel that matches the Linux version downloaded with the Android Kernel code.</li>
-  <li>Run <code>diff</code> on the two kernel packages to get Android-specific changes.</li>
-  <li>Apply the patch to your target kernel and build.</li>
-</ol>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.5 - 25 September 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/gps.html b/pdk/docs/gps.html
deleted file mode 100755
index eb5473f..0000000
--- a/pdk/docs/gps.html
+++ /dev/null
@@ -1,259 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20gps.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidGpsTitle"></a><h1>GPS</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidGpsIntroduction">Introduction</a><br/>
-<a href="#androidGPSBuildingDriver">Building a GPS Library</a><br/>
-<a href="#androidGPSInterface">Interface</a><br/></div></font></div>
-
-<a name="androidGpsIntroduction"></a><h2>Introduction</h2>
-
-<p>Android defines a user space C abstraction interface for GPS hardware. The interface header is defined in <code>include/hardware/gps.h</code>. In order to integate GPS with Android, you need to build a shared library that implements this interface. </p>
-
-
-<a name="androidGPSBuildingDriver"></a><h2>Building a GPS Library</h2>
-
-<p>To implement a GPS driver, create a shared library that implements the interface defined in <code>gps.h</code>. You must name your shared library <code>libgps.so</code> so that it will get loaded from <code>/system/lib</code> at runtime. Place GPS sources and Android.mk in <code>partner/acme/chipset_or_board/gps/</code> (where "acme" is your product name and "chipset_or_board" is your hardware target).</p>
-
-<p>The following stub <code>Android.mk</code> file ensures that <code>libgps</code> compiles and links to the appropriate libraries:</p>
-
-<pre class="prettify">
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := libgps
-
-LOCAL_STATIC_LIBRARIES:= \
-# include any static library dependencies
-
-LOCAL_SHARED_LIBRARIES := \
-# include any shared library dependencies
-
-LOCAL_SRC_FILES += \
-# include your source files.  eg. MyGpsLibrary.cpp
-
-LOCAL_CFLAGS += \
-# include any needed compile flags
-
-LOCAL_C_INCLUDES:= \
-# include any needed local header files
-
-include $(BUILD_SHARED_LIBRARY)
-</pre>
-
-
-<a name="androidGPSInterface"></a><h2>Interface</h2>
-
-
-
-<p><span class="lh2"><a name="androidDoxygenNote"></a></span>
-
-<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="gps.html">click here</a>.</p>
-
-
-<iframe onLoad="resizeHeight();" src="gps_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
-
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/group__memory.html b/pdk/docs/group__memory.html
deleted file mode 100755
index 44d0782..0000000
--- a/pdk/docs/group__memory.html
+++ /dev/null
@@ -1,37 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
-<title>Doxygen-Generated Content</title>
-<link href="doxygen.css" rel="stylesheet" type="text/css" />
-<style type="text/css">
-<!--
-.navigation {
-	display: none;
-}
--->
-</style>
-</head>
-<body>
-<!-- Generated by Doxygen 1.5.6 -->
-<div class="navigation" id="top">
-  <div class="tabs">
-    <ul>
-      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
-      <li><a href="modules.html"><span>Modules</span></a></li>
-      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
-      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
-      <li><a href="files.html"><span>Files</span></a></li>
-    </ul>
-  </div>
-</div>
-<div class="contents">
-<h1>Porividng Heap Memory<br>
-<small>
-[<a class="el" href="group__networking.html">Neworking Support</a>]</small>
-</h1><table border="0" cellpadding="0" cellspacing="0">
-<tr><td></td></tr>
-</table>
-This is the text in the "Providing Heap Memory" subgroup </div>
-</body>
-</html>
diff --git a/pdk/docs/group__networking.html b/pdk/docs/group__networking.html
deleted file mode 100755
index 6a8e1b8..0000000
--- a/pdk/docs/group__networking.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
-<title>Doxygen-Generated Content</title>
-<link href="doxygen.css" rel="stylesheet" type="text/css" />
-<style type="text/css">
-<!--
-.navigation {
-	display: none;
-}
--->
-</style>
-</head>
-<body>
-<!-- Generated by Doxygen 1.5.6 -->
-<div class="navigation" id="top">
-  <div class="tabs">
-    <ul>
-      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
-      <li><a href="modules.html"><span>Modules</span></a></li>
-      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
-      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
-      <li><a href="files.html"><span>Files</span></a></li>
-    </ul>
-  </div>
-</div>
-<div class="contents">
-<h1>Neworking Support</h1><table border="0" cellpadding="0" cellspacing="0">
-<tr><td></td></tr>
-<tr><td colspan="2"><br><h2>Modules</h2></td></tr>
-<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memory.html">Porividng Heap Memory</a></td></tr>
-
-</table>
-<hr><a name="_details"></a><h2>Detailed Description</h2>
-This is a text for the Networking Support Group </div>
-</body>
-</html>
diff --git a/pdk/docs/index.html b/pdk/docs/index.html
deleted file mode 100755
index 6eac80b..0000000
--- a/pdk/docs/index.html
+++ /dev/null
@@ -1,248 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20index.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidPortingGuideTitle"></a><h1>Welcome to the Android Porting Guide</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidWelcomeIntendedAudience">Intended Audience</a><br/>
-<a href="#androidWelcomeGettingStarted">Getting Started with Android</a><br/>
-<a href="#androidWelcomePorting">Porting Android to Your Device</a><br/></div></font></div>
-
-<p>The Open Handset Distribution (OHD) is a software distribution  for mobile devices, often referred to as Android, developed by members of the <a href="http://www.openhandsetalliance.com">Open Handset Alliance</a>. &nbsp;Android includes an operating system, middleware, and key applications typically required for a mobile device.</p>
-  
-<p>This porting guide describes the steps necessary to port Android to a new mobile device. &nbsp;Android is designed as a highly-portable, hardware-independent platform based on Linux, and porting the platform to new devices requires little more than porting the Linux kernel and developing the Linux drivers necessary for your device.</p>
-  
-<p>The current version of this guide describes bringing Android up to "PDA-level" functionality; functionality sufficient to support non-multimedia apps that run on unconnected mobile devices through the standard user interface devices such as keypad and display. &nbsp;Future versions of this guide will cover complete telephony, multi-media and peripheral integration to create a complete mobile device.</p>
-
-
-<a name="androidWelcomeIntendedAudience"></a><h2>Intended Audience</h2>
-
-<p>This porting guide is intended for engineers proficient with running (and writing drivers for) Linux on embedded devices. 
-<p>The guide also assumes you have a target hardware that matches <a href="system_requirements.html">Device Requirements</a> and that you 
-can boot and run a recent (2.6.x) version of the Linux kernel
-with at least keypad and display drivers properly installed.</p>
-
-
-<a name="androidWelcomeGettingStarted"></a><h2>Getting Started with Android</h2>
-
-<p>To get started with Android, start with the publicly-available documentation at <a href="http://code.google.com/android/documentation.html">http://code.google.com/android/documentation.html</a>, paying particular attention to <a href="http://code.google.com/android/what-is-android.html">What is Android?</a> and <a href="http://code.google.com/android/intro/index.html">Getting Started with Android</a>.</p>
-
-
-<a name="androidWelcomePorting"></a><h2>Porting Android to Your Device</h2>
-
-<p>Start with the following sections in order to port Android to your target hardware.</p>
-<dl>
-    <dt><a href="system_requirements.html">Device Requirements</a></dt>
-    <dd>What must your device support in order to successfully port Android to it?  </dd>
-    <dt><a href="source_setup_guide.html">Setting up a Development Environment </a></dt>
-
-    <dd>Install necessary packages and retrieve source code through a Git server. <a href="build_system.html">Build System</a> offers a conceptual overview of Android's build system and instructions to affect a simple build.</dd>
-    <dt><a href="bring_up.html">Basic Bring up </a></dt>
-    <dd>Establish core components necessary to your device, such as keymaps / keyboard input and display drivers. </dd>
-    <dt>&nbsp;</dt>
-</dl>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/instrumentation_framework.html b/pdk/docs/instrumentation_framework.html
deleted file mode 100755
index 306cbc6..0000000
--- a/pdk/docs/instrumentation_framework.html
+++ /dev/null
@@ -1,316 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Instrumentation Framework</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20instrumentation_framework.html%20v0.3%20-%209%20June%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="source_setup_guide.html">Host System Setup</a></li>
-            <li><a href="getting_source_code.html">Getting Source Code</a></li>
-            <li> <a href="intro_source_code.html">Source Code Overview</a></li>			
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio Subsystem</a></li>
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_framework.html">Instrumentation Framework</a></li>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidTitleInstrumentationFramework"></a><h1>Instrumentation Framework</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidInstrumentationFrameworkIntro">Introduction</a><br/>
-<a href="#androidInstrumentationFrameworkamCommand">Understanding the am Command</a><br/>
-<a href="#androidInstrumentationFrameworkWritingRunning">Writing and Running Test Cases</a><br/>
-<a href="#androidInstrumentationFrameworkTestCase">Exploring a Test Case</a><br/>
-<a href="#androidInstrumentationFrameworkTroubleshooting">Troubleshooting</a><br/></div></font></div>
-
-<a name="androidInstrumentationFrameworkIntro"></a><h2>Introduction</h2>
-
-<p>This document describes how to use the Instrumentation Framework to write test cases. You should have a working knowledge of the following:</p>
-<ul>
-  <li> Android Application Framework </li>
-  <li> Using <code>adb</code>, <code>am</code> and various logging functionality </li>
-  <li> A brief understanding of the application of interest, that is, he names of the classes which handle the intents etc. </li>
-  <li> Junit testing. </li>
-</ul>
-<p> Each Android application runs in its own process. Instrumentation kills the application process and  restarts the process with Instrumentation. Instrumentation gives a handle to the application context used to poke around the application to validate test assertions, allowing you to write test cases to test applications at a much lower level than UI screen shot tests. Note that Instrumentation cannot catch UI bugs. </p>
-
-
-<a name="androidInstrumentationFrameworkamCommand"></a><h2>Understanding the am Command</h2>
-
-<p><code>am</code> is used to start and instrument activities using the adb shell command, as shown in the snippet below:</p>
-<pre class="prettify">
-&gt; adb shell am
-usage: am [start|instrument]
-       am start [-a &lt;ACTION&gt;] [-d &lt;DATA_URI&gt;] [-t &lt;MIME_TYPE&gt;]
-                [-c &lt;CATEGORY&gt; [-c &lt;CATEGORY&gt;] ...]
-                [-e &lt;EXTRA_KEY&gt; &lt;EXTRA_VALUE&gt; [-e &lt;EXTRA_KEY&gt; &lt;EXTRA_VALUE&gt; ...]
-                [-n &lt;COMPONENT&gt;] [-D] [&lt;URI&gt;]
-       am instrument [-e &lt;ARG_NAME&gt; &lt;ARG_VALUE&gt;] [-p &lt;PROF_FILE&gt;]
-                [-w] &lt;COMPONENT&gt;
-For example, to start the Contacts application you can use
-&gt; adb shell am start -n com.google.android.contacts/.ContactsActivity
-</pre>
-
-
-<a name="androidInstrumentationFrameworkWritingRunning"></a><h2>Writing and Running Test Cases</h2>
-
-<p>Each instrumentation test case is similar to an Android application with the distinction that it starts another application. For example, have a look in the <code>tests/Contacts</code> directory. </p>
-<ul>
-  <li> There should be a Makefile and an Android Manifest file. </li>
-  <li> Tests are located in <code>tests/Contacts/src/com/google/android/contactstests</code>. </li>
-  <li> The Instrumentation Test Runner is located at <code>tests/Contacts/src/com/google/android/contactstests/functional/ContactsInstrumentationTestRunner.java</code>.</li>
-</ul>
-<p>Suppose you have a makefile with <code>Contactstests</code> as the target. </p>
-<ul>
-  <li> <code>make Contactstests</code>: Compiles the test cases. </li>
-  <li> <code>adb install Contactstests.apk</code>: Installs the apk on the device. </li>
-  <li> Use the adb shell <code>am</code> command to run them. </li>
-</ul>
-<p> For options and other details, please see <a href="instrumentation_testing.html" target="_top">Instrumentation Testing</a>.</p>
-
-
-<a name="androidInstrumentationFrameworkTestCase"></a><h2>Exploring a Test Case</h2>
-
-<p> The test case described in this section adds and tests a new Contact. Note that you can send intents, register intent receivers, etc. </p>
-<p><code>Instrumentation.java</code> has helper functions that send key events and string, for example: </p>
-<ul>
-  <li><code>getInstrumentation()</code>: Returns the handle to the instrumentation </li>
-  <li><code>sendCharacterSync</code>: Sends a character. </li>
-  <li><code>sendStringSync</code>: Sends a string to an input box. </li>
-  <li><code>sendKeyDownUpSync</code>: Sends a specific keyevent. </li>
-  <li><code>sendTrackballEventSync</code>: Send a trackball event.</li>
-</ul>
-<p> You can find the test case below at <code>device/tests/Contacts.</code></p>
-<pre class="prettify">
-private void addNewContact(String name, int star, int phoneType, String number, String label,
-		String email, int emailType){
-	ContentValues values = new ContentValues();
-	Uri phoneUri = null;
-	Uri emailUri = null;
-
-	values.put(Contacts.People.NAME, name);
-	values.put(Contacts.People.STARRED, star);
-
-	//Add Phone Numbers
-	Uri uri = mActivity.getContentResolver().insert(Contacts.People.CONTENT_URI, values);
-	phoneUri = Uri.withAppendedPath(uri, Contacts.People.Phones.CONTENT_DIRECTORY);
-
-	values.clear();
-	values.put(Contacts.Phones.TYPE, phoneType);
-	values.put(Contacts.Phones.NUMBER, number);
-	values.put(Contacts.Phones.LABEL, label);
-	mActivity.getContentResolver().insert(phoneUri, values);
-
-	//Add Email
-	emailUri = Uri.withAppendedPath(uri, ContactMethods.CONTENT_DIRECTORY);
-
-	values.clear();
-	values.put(ContactMethods.KIND, Contacts.KIND_EMAIL);
-	values.put(ContactMethods.DATA, email);
-	values.put(ContactMethods.LABEL, "");
-	values.put(ContactMethods.TYPE, emailType);
-	mActivity.getContentResolver().insert(emailUri, values);
-}
-
-
- public void testAddSaveSingleContact(){
-	int previousCount = mActivity.getListView().getCount();
-	String message;
-
-	addNewContact(INPUT_NAME_1 + "1", "5435754532", "1" + INPUT_EMAIL_1, CONFIRM_OPTION);
-
-	message = "Added 1 to initial length=" + previousCount + ", but resulted with a count=" +
-		mActivity.getListView().getCount();
-	assertEquals(message, ++previousCount, mActivity.getListView().getCount());
-
-	// Check Content; Name; Num; Starred
-	assertEquals(INPUT_NAME_1 + "1", getTextFromView(0, android.R.id.text1));
-	assertEquals("5435754532", getTextFromView(0, android.R.id.text2));
-
-	//Check email is saved
-	//cursor = returnEmailCursorAtId("1");
-	Uri uri = Uri.parse("content://contacts/people/1");
-	uri = Uri.withAppendedPath(uri, ContactMethods.CONTENT_DIRECTORY);
-	Cursor cursor = mActivity.getContentResolver().query(uri, CONTACTS_COLUMNS, null, null, null);
-	assertTrue("returnEmailCursorAtId: Moving cursor to first row has failed", cursor.first());
-
-	int dataIndex = cursor.getColumnIndexOrThrow("data");
-	assertEquals("1" + INPUT_EMAIL_1, cursor.getString(dataIndex));
-	cursor.deactivate();
-}
-	</pre>
-
-
-<a name="androidInstrumentationFrameworkTroubleshooting"></a><h2>Troubleshooting</h2>
-
-<p>If you run your test cases and nothing appears to happen, have a look at <code>adb logcat</code>. The following is a common problem:</p>
-<pre class="prettify">
-I/dalvikvm(  688): threadid=11: attached from native, name=Binder Thread #1
-I/dalvikvm(  688): threadid=13: attached from native, name=Binder Thread #2
-W/ActivityManager(  469): Unable to find instrumentation info for: ComponentInfo{com.google.android.browser_instrumentation/com.google.android.browser_instrumentation.BrowserWebkitLayoutInstrumentation}
-D/AndroidRuntime(  688): Shutting down VM
-E/AndroidRuntime(  688): ERROR: thread attach failed
-</pre>		
-<p>It's possible that the instrumentation apk isn't installed on your device or that the package name is incorrect in the Manifest file. </p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.3 - 9 June 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/instrumentation_testing.html b/pdk/docs/instrumentation_testing.html
deleted file mode 100755
index 931fd77..0000000
--- a/pdk/docs/instrumentation_testing.html
+++ /dev/null
@@ -1,719 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20instrumentation_framework.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidTitleInstrumentationFramework"></a><h1>Instrumentation Testing</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidInstrumentationFrameworkIntro">Introduction</a><br/>
-<a href="#androidInstrumentationTestingFramework">Instrumentation Framework</a><br/><div style="padding-left:40px">
-
-<a href="#androidInstrumentationTestingClasses">Classes</a><br/>
-<a href="#androidInstrumentationFrameworkamCommand">Understanding the am Command</a><br/></div>
-<a href="#androidInstrumentationFrameworkPlatform">Platform Test Suites</a><br/><div style="padding-left:40px">
-
-<a href="#androidTestingPlatformFramework">Framework Tests</a><br/>
-<a href="#androidTestingPlatformCoreLibrary">Core Library</a><br/></div>
-<a href="#androidInstrumentationFrameworkWritingRunning">Running Tests</a><br/><div style="padding-left:40px">
-
-<a href="#androidInstrumentationTestingRunningAll">All Tests with Default TestRunner behavior</a><br/>
-<a href="#androidTestingTestSinglePakcage">Running all Tests Under Single Package</a><br/>
-<a href="#androidTestingSingleTestSuite">Running a Single Test Suite</a><br/>
-<a href="#androidInstrumentationTestingRunningSingleTestCase">A Single Test Case</a><br/>
-<a href="#androidInstrumentationTestingRunningSingleTest">A Single Test</a><br/>
-<a href="#androidTestingDebugging">Attaching a debugger to your test</a><br/></div>
-<a href="#androidInstrumentationTestingCreating">Writing Tests</a><br/><div style="padding-left:40px">
-
-<a href="#androidTestingLocationFiles">Location of Files</a><br/>
-<a href="#androidTestingContentMakefile">Contents of makefile</a><br/>
-<a href="#androidTestingContentManifest">Content of Manifest</a><br/>
-<a href="#androidInstrumentationTestingCreatingTestRunner">New InstrumentationTestRunner</a><br/>
-<a href="#androidInstrumentationTestingCreatingTestCase">New InstrumentationTestCase</a><br/>
-<a href="#androidInstrumentationFrameworkTestCase">Exploring a Test Case</a><br/>
-<a href="#androidTestingKindsofTests">Deciding Kinds of Tests to Write</a><br/></div>
-<a href="#androidInstrumentationFrameworkTroubleshooting">Troubleshooting</a><br/></div></font></div>
-
-<a name="androidInstrumentationFrameworkIntro"></a><h2>Introduction</h2>
-
-<p>This document describes how to use the Instrumentation Framework to write test cases. Instrumentation testing allows you to verify a particular feature or behavior with an automated JUnit TestCase. You can launch activities and providers within an application, send key events, and make assertions about various UI elements. </p>
-<p>You should have a working knowledge of the following:</p>
-<ul>
-  <li> Android Application Framework</li>
-  <li> Using <code>adb</code>, <code>am</code> and various logging functionality </li>
-  <li> A brief understanding of the application of interest, that is, the names of the classes which handle the intents etc. </li>
-  <li> JUnit testing.</li>
-</ul>
-<p> Each Android application runs in its own process. Instrumentation kills the application process and  restarts the process with Instrumentation. Instrumentation gives a handle to the application context used to poke around the application to validate test assertions, allowing you to write test cases to test applications at a much lower level than UI screen shot tests. Note that Instrumentation cannot catch UI bugs. </p>
-
-
-<a name="androidInstrumentationTestingFramework"></a><h2>Instrumentation Framework</h2>
-
-
-
-<a name="androidInstrumentationTestingClasses"></a><h3>Classes</h3>
-
-<p> The following classes help glue together <code>Instrumentation</code> with JUnit testing. </p>
-<table>
-  <tr>
-    <th scope="col">Class</th>
-    <th scope="col">Description</th></tr>
-  <tr>
-    <td valign="top"><code>InstrumentationTestCase</code></td>
-    <td valign="top">
-	<p>This extends the standard JUnit <code>TestCase</code> and offers access to an <code>Instrumentation</code> class. Write tests inside your instrumentation class any way you see fit. For example, your test might launch activities and send key events. For this to work properly, the instrumentation needs to be injected into the test case.</p>	</td>
-  </tr>
-  <tr>
-    <td valign="top"><code>InstrumentationTestRunner</code></td>
-    <td valign="top">The instrumentation test runner is an instrumentation that runs instrumentation test cases and injects itself into each test case. Instrumentation test cases need to be grouped together with an instrumentation test runner with the appropriate target package.</td>
-  </tr>
-  <tr>
-    <td valign="top"><code>InstrumentationTestSuite</code></td>
-    <td valign="top">The instrumentation test suite is a simple extension of the standard JUnit <code>TestSuite</code> that keeps a member <code>Instrumentation</code> variable on hand to inject into each <code>TestCase</code> before running them.  It is used by <code>InstrumentationTestRunner</code>.</td>
-  </tr>
-</table>
-<p> Three additional base classes extend <code>InstrumentationTestCase</code> to allow you to test <code>Activity</code> and <code>Provider</code> classes:</p>
-<table>
-  <tr>
-    <th scope="col">Class</th>
-    <th scope="col">Description</th>
-  </tr>
-  <tr>
-    <td valign="top"><code>ActivityTestCase</code></td>
-    <td valign="top"><p>This class can be used to write tests for a specific activity.  An activity is launched in its <code>setUp()</code> method and finished with <code>tearDown</code>.  If you write a test case that extends <code>ActivityTestCase</code>, you can write tests that access the activity using <code>getActivity()</code> and assume it has been set up properly.</p></td>
-  </tr>
-  <tr>
-    <td valign="top"><code>ServiceTestCase</code></td>
-    <td valign="top">This test case provides a framework in which you can test Service classes in a controlled environment.  It provides basic support for the lifecycle of a Service, and hooks by which you can inject various dependencies and control the environment in which your Service is tested.</td>
-  </tr>
-  <tr>
-    <td valign="top"><code>SingleLaunchActivityTestCase</code></td>
-    <td valign="top">This class is similar to <code>ActivityTestCase</code> except that the activity is launched once per class instead of every time the test case calls setup. </td>
-  </tr>
-  <tr>
-    <td valign="top"><code>ProviderTestCase</code></td>
-    <td valign="top">This class is similar to <code>ActivityTestCase</code> except that it will setup, tear down, and provide access to the <code>Provider</code> of your choice.</td>
-  </tr>
-</table>
-
-
-<a name="androidInstrumentationFrameworkamCommand"></a><h3>Understanding the am Command</h3>
-
-<p>The am command is a command-line interface to the ActivityManager (see <a href="http://code.google.com/android/reference/android/app/ActivityManager.html">http://code.google.com/android/reference/android/app/ActivityManager.html</a> for details). <code>am</code> is used to start and instrument activities using the adb shell command, as shown in the snippet below:</p>
-<pre class="prettify">
-&gt; adb shell am
-usage: am [start|instrument]
-       am start [-a &lt;ACTION&gt;] [-d &lt;DATA_URI&gt;] [-t &lt;MIME_TYPE&gt;]
-                [-c &lt;CATEGORY&gt; [-c &lt;CATEGORY&gt;] ...]
-                [-e &lt;EXTRA_KEY&gt; &lt;EXTRA_VALUE&gt; [-e &lt;EXTRA_KEY&gt; &lt;EXTRA_VALUE&gt; ...]
-                [-n &lt;COMPONENT&gt;] [-D] [&lt;URI&gt;]
-       am instrument [-e &lt;ARG_NAME&gt; &lt;ARG_VALUE&gt;] [-p &lt;PROF_FILE&gt;]
-                [-w] &lt;COMPONENT&gt;
-For example, to start the Contacts application you can use
-&gt; adb shell am start -n com.google.android.contacts/.ContactsActivity
-</pre>
-
-
-<a name="androidInstrumentationFrameworkPlatform"></a><h2>Platform Test Suites</h2>
-
-<p>This section provides an overview for various unit and functional test cases that can be executed through the instrumentation framework.</p>
-
-
-<a name="androidTestingPlatformFramework"></a><h3>Framework Tests</h3>
-
-<p>Framework test cases test the Android application framework or specific Android application functionality that requires an Android runtime context.  These tests can be found in <code>//device/tests</code> and <code>//device/apps/AndroidTests</code>.</p>
-
-
-<a name="androidTestingPlatformCoreLibrary"></a><h3>Core Library</h3>
-
-<p>Core library test cases test the Android library functionality that does not require an Android runtime context.  These tests are split into Android library (android.* package space) tests at <code>//device/java/tests</code> and Java library (java.*, javax.*, etc. packages) tests at <code>//device/dalvik/libcore/.../tests</code>.</p>
-
-
-<a name="androidInstrumentationFrameworkWritingRunning"></a><h2>Running Tests</h2>
-
-<p>Each instrumentation test case is similar to an Android application with the distinction that it starts another application. For example, have a look in the <code>tests/Contacts</code> directory. </p>
-<ul>
-  <li> There should be a Makefile and an Android Manifest file. </li>
-  <li> Tests are located in <code>tests/Contacts/src/com/google/android/contactstests</code>. </li>
-  <li> The Instrumentation Test Runner is located at <code>tests/Contacts/src/com/google/android/contactstests/functional/ContactsInstrumentationTestRunner.java</code>.</li>
-</ul>
-<p>Suppose you have a makefile with <code>Contactstests</code> as the target. </p>
-<ul>
-  <li> <code>make Contactstests</code>: Compiles the test cases. </li>
-  <li> <code>adb install Contactstests.apk</code>: Installs the apk on the device. </li>
-  <li> Use the adb shell <code>am</code> command to run them. </li>
-</ul>
-<p> To run your tests, use the <code>am instrument</code> command with your <code>InstrumentationTestRunner</code> as its argument. Results are printed as a result of the instrumentation. For example, the following snippet displays the output after running the framework tests with one test failing (note the unusual syntax caused by how instrumentations are run via <code>am</code>):</p>
-<pre class="prettify">
-$ adb shell am instrument -w com.google.android.frameworktest/.tests.FrameworkInstrumentationTestRunner
-INSTRUMENTATION_RESULT: test results:=.......F.......
-Time: 6.837
-There was 1 failure:
-1) testSetUpConditions(com.google.android.frameworktest.tests.focus.RequestFocusTest)junit.framework.AssertionFailedError: requestFocus() should work from onCreate.
-        at com.google.android.frameworktest.tests.focus.RequestFocusTest.testSetUpConditions(RequestFocusTest.java:66)
-        at java.lang.reflect.Method.invokeNative(Native Method)
-        at android.test.InstrumentationTestSuite.runTest(InstrumentationTestSuite.java:73)
-        at android.test.InstrumentationTestSuite.runTest(InstrumentationTestSuite.java:73)
-        at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:151)
-        at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1088)
-
-FAILURES!!!
-Tests run: 14,  Failures: 1,  Errors: 0
-
-&lt;RETURN&gt; to continue
-
-INSTRUMENTATION_CODE: -1
-$ 
-</pre>
-
-
-<a name="androidInstrumentationTestingRunningAll"></a><h3>All Tests with Default TestRunner behavior</h3>
-
-<p>If no class or package is passed in to run, InstrumentationTestRunner will automatically find and run all tests under the package of the test application (as defined by the <code>android:targetPackage</code> attribute of the instrumentation defined in its manifest file).
-</p> 
-<pre> 
-$ adb shell am instrument -w \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
- 
-INSTRUMENTATION_RESULT: Test results for InstrumentationTestRunner=..........
-Time: 2.317
- 
-OK (10 tests)
- 
- 
-INSTRUMENTATION_CODE: -1
-</pre>
-
-
-<a name="androidTestingTestSinglePakcage"></a><h3>Running all Tests Under Single Package</h3>
-
-<p>If you have many tests under one package, use the <code>-e package &lt;packagename&gt;</code> option to run all tests under that package without having to manually create a test suite.</p> 
-<pre> 
-$ adb shell am instrument -w \
-  -e package com.android.samples.view \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
-INSTRUMENTATION_RESULT: Test results for InstrumentationTestRunner=........
-Time: 1.587
- 
-OK (8 tests)
-</pre>  
-
-
-<a name="androidTestingSingleTestSuite"></a><h3>Running a Single Test Suite</h3>
-
-<p>If you prefer to explicitly state which tests comprise all of your tests, you can define a test suite and run that directly. By convention, all test packages in your system should have at least one suite called <code>AllTests</code> (see <code>AllTests.java</code>).  To run all of the tests using the <code>AllTests</code> suite for the api demos test app:</p>
-
-<pre> 
-$ adb shell am instrument -w \
-  -e class com.android.samples.AllTests \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
- 
-INSTRUMENTATION_RESULT: Test results for AllTests=..........
-Time: 2.286
- 
-OK (10 tests)
- 
- 
-INSTRUMENTATION_CODE: -1
-</pre> 
-
-
-<a name="androidInstrumentationTestingRunningSingleTestCase"></a><h3>A Single Test Case</h3>
-
-<pre> 
-$ adb shell am instrument -w \
-  -e class com.android.samples.view.Focus2ActivityTest \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
- 
-INSTRUMENTATION_RESULT: Test results for Focus2ActivityTest=....
-Time: 1.359
- 
-OK (4 tests)
- 
- 
-INSTRUMENTATION_CODE: -1
-</pre> 
-
-
-<a name="androidInstrumentationTestingRunningSingleTest"></a><h3>A Single Test</h3>
-
-<pre> 
-$ adb shell am instrument -w \
-  -e class com.android.samples.view.Focus2ActivityTest#testGoingLeftFromRightButtonGoesToCenter \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
- 
-INSTRUMENTATION_RESULT: Test results for Focus2ActivityTest=.
-Time: 0.51
- 
-OK (1 test)
- 
- 
-INSTRUMENTATION_CODE: -1
-</pre> 
-
-
-<a name="androidTestingDebugging"></a><h3>Attaching a debugger to your test</h3>
-
-<p>In order to debug your test code, instruct the controller to stop and wait for the debugger by adding <code>-e debug true</code> to your
-command line.  This causes the test runner to stop and wait for the debugger just before calling your <code>setUp()</code> method.  For example,</p> 
-
-<pre> 
-$ adb shell am instrument -w \
-  -e debug true \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
-</pre> 
-
-
-<a name="androidInstrumentationTestingCreating"></a><h2>Writing Tests</h2>
-
-<p>When writing tests, refer to the ApiDemos tests as models (located at <code>//device/samples/ApiDemos</code>). This section provides an overview of the test structure with ApiDemos.</p>
-
-
-<a name="androidTestingLocationFiles"></a><h3>Location of Files</h3>
-
-<p>Test packages should use the following structure and include <code>Android.mk</code>, <code>AndroidManifest.xml</code>, <code>AllTests.java</code>, and a src directory that mirrors the src directory of the tested application.</p> 
-<p>Files are located within a <code>tests</code> directory found in the root directory:</p> 
-<pre> 
-$ find samples/ApiDemos/tests
-samples/ApiDemos/tests
-samples/ApiDemos/tests/Android.mk
-samples/ApiDemos/tests/AndroidManifest.xml
-samples/ApiDemos/tests/src
-samples/ApiDemos/tests/src/com
-samples/ApiDemos/tests/src/com/google
-samples/ApiDemos/tests/src/com/google/android
-samples/ApiDemos/tests/src/com/google/android/samples
-samples/ApiDemos/tests/src/com/google/android/samples/AllTests.java
-samples/ApiDemos/tests/src/com/google/android/samples/ApiDemosTest.java
-samples/ApiDemos/tests/src/com/google/android/samples/os
-samples/ApiDemos/tests/src/com/google/android/samples/os/MorseCodeConverterTest.java
-samples/ApiDemos/tests/src/com/google/android/samples/view
-samples/ApiDemos/tests/src/com/google/android/samples/view/Focus2ActivityTest.java
-samples/ApiDemos/tests/src/com/google/android/samples/view/Focus2AndroidTest.java
-</pre>
-
-
-<a name="androidTestingContentMakefile"></a><h3>Contents of makefile</h3>
-
-<p>The contents of the makefile are similar to a normal application with the addition of a <code>LOCAL_INSTRUMENTATION_FOR</code> declaration.<p /> 
-<pre> 
-# Add appropriate copyright banner here
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
- 
-# We only want this apk build for tests.
-LOCAL_MODULE_TAGS := tests
- 
-# Include all test java files.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
- 
-# Notice that we don't have to include the src files of ApiDemos because, by
-# running the tests using an instrumentation targeting ApiDemos, we
-# automatically get all of its classes loaded into our environment.
- 
-LOCAL_PACKAGE_NAME := ApiDemosTests
- 
-LOCAL_INSTRUMENTATION_FOR := ApiDemos
- 
-include $(BUILD_PACKAGE)
-</pre>
-
-
-<a name="androidTestingContentManifest"></a><h3>Content of Manifest</h3>
-
-<p>Use the following example to create an <code>AndroidManifest.xml</code> file that declares the instrumentation. Specify that the framework supplied InstrumentationTestRunner targets the package of your application, allowing the tests that are run with the instrumentation to get access to all of the classes of your application without having to build the source into the test app. The name of the test application is typically the same as your target application with <code>.tests</code> appended. </p>
-<pre> 
-# Add appropriate copyright banner here
-&lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.apis.tests"&gt;
-
-    &lt;!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->
-    &lt;application>
-        &lt;uses-library android:name="android.test.runner" />
-    &lt;/application>
-
-    &lt;!--
-    This declares that this app uses the instrumentation test runner targeting
-    the package of com.example.android.apis.  To run the tests use the command:
-    "adb shell am instrument -w com.example.android.apis.tests/android.test.InstrumentationTestRunner"
-    -->
-    &lt;instrumentation android:name="android.test.InstrumentationTestRunner"
-                     android:targetPackage="com.example.android.apis"
-                     android:label="Tests for Api Demos."/>
-
-&lt;/manifest&gt;
-</pre> 
-<p>&nbsp;</p> 
-<p>The following snippet will prefix the <code>/android.test.InstrumentationTestRunner</code> when running tests from the command line:</p>
-<pre> 
-$ adb shell am instrument -w \
-  com.android.samples.tests/android.test.InstrumentationTestRunner
-</pre> 
-
-
-<a name="androidInstrumentationTestingCreatingTestRunner"></a><h3>New InstrumentationTestRunner</h3>
-
-<p>Create a class that derives from this class. You must override two abstract methods; one that returns the class loader of the target package, and another that defines all of the tests within the package. For example, the snippet below displays the test runner for the framework tests.</p>
-<pre class="prettify">
-public class FrameworkInstrumentationTestRunner extends InstrumentationTestRunner {
-
-    @Override
-    public TestSuite getAllTests() {
-        InstrumentationTestSuite suite = new InstrumentationTestSuite(this);
-
-        suite.addTestSuite(FocusAfterRemovalTest.class);
-        suite.addTestSuite(RequestFocusTest.class);
-        suite.addTestSuite(RequestRectangleVisibleTest.class);
-        return suite;
-    }
-
-    @Override
-    public ClassLoader getLoader() {
-        return FrameworkInstrumentationTestRunner.class.getClassLoader();
-    }
-}
-</pre>
-<p> Next, in an appropriate <code>AndroidManifest.xml</code>, define the instrumentation for the derived class with the appropriate <code>android:targetPackage</code> set.  For example, the snippet below defines the instrumentation runner for the framework tests.</p>
-<pre class="prettify">
-&lt;instrumentation android:name="android.tests.FrameworkInstrumentationTestRunner"
-                 android:targetPackage="com.google.android.frameworktest"
-                 android:label="framework instrumentation test runner" /&gt;
-</pre>		
-
-
-<a name="androidInstrumentationTestingCreatingTestCase"></a><h3>New InstrumentationTestCase</h3>
-
-<p> To create a new test case, write a class that extends <code>InstrumentationTestCase</code> in the same application as your test runner.  The following snippet illustrates an example <code>ActivityTestCase</code> that tests an activity named <code>MyActivity</code>.</p>
-<pre class="prettify">
-public class ButtonPressTest extends ActivityTestCase&lt;MyActivity&gt; {
-
-    Button mLeftButton;
-
-    public ButtonPressTest() {
-        super("com.example", MyActivity.class);
-    }
-
-    @Override
-    public void setUp() throws Exception {
-      super.setUp();
-      mLeftButton = (Button) getActivity().findViewById(R.id.leftButton);
-    }
-
-    public void testFocusMovesToRight() throws Exception {
-        assertTrue(mLeftButton.hasFocus());
-        getInstrumentation().sendCharacterSync(KeyEvent.KEYCODE_DPAD_RIGHT);
-
-        Button rightButton = (Button) getActivity().findViewById(R.id.rightButton);
-        assertTrue(rightButton.hasFocus());
-    }
-
-    // could have several more tests...
-}
-</pre>
-
-
-<a name="androidInstrumentationFrameworkTestCase"></a><h3>Exploring a Test Case</h3>
-
-<p> The test case described in this section adds and tests a new Contact. Note that you can send intents, register intent receivers, etc. </p>
-<p><code>Instrumentation.java</code> has helper functions that send key events and strings, for example: </p>
-<ul>
-  <li><code>getInstrumentation()</code>: Returns the handle to the instrumentation </li>
-  <li><code>sendCharacterSync</code>: Sends a character. </li>
-  <li><code>sendStringSync</code>: Sends a string to an input box. </li>
-  <li><code>sendKeyDownUpSync</code>: Sends a specific keyevent. </li>
-  <li><code>sendTrackballEventSync</code>: Sends a trackball event.</li>
-</ul>
-<p> You can find the test case below at <code>device/tests/Contacts.</code></p>
-<pre class="prettify">
-private void addNewContact(String name, int star, int phoneType, String number, String label,
-		String email, int emailType){
-	ContentValues values = new ContentValues();
-	Uri phoneUri = null;
-	Uri emailUri = null;
-
-	values.put(Contacts.People.NAME, name);
-	values.put(Contacts.People.STARRED, star);
-
-	//Add Phone Numbers
-	Uri uri = mActivity.getContentResolver().insert(Contacts.People.CONTENT_URI, values);
-	phoneUri = Uri.withAppendedPath(uri, Contacts.People.Phones.CONTENT_DIRECTORY);
-
-	values.clear();
-	values.put(Contacts.Phones.TYPE, phoneType);
-	values.put(Contacts.Phones.NUMBER, number);
-	values.put(Contacts.Phones.LABEL, label);
-	mActivity.getContentResolver().insert(phoneUri, values);
-
-	//Add Email
-	emailUri = Uri.withAppendedPath(uri, ContactMethods.CONTENT_DIRECTORY);
-
-	values.clear();
-	values.put(ContactMethods.KIND, Contacts.KIND_EMAIL);
-	values.put(ContactMethods.DATA, email);
-	values.put(ContactMethods.LABEL, "");
-	values.put(ContactMethods.TYPE, emailType);
-	mActivity.getContentResolver().insert(emailUri, values);
-}
-
-
- public void testAddSaveSingleContact(){
-	int previousCount = mActivity.getListView().getCount();
-	String message;
-
-	addNewContact(INPUT_NAME_1 + "1", "5435754532", "1" + INPUT_EMAIL_1, CONFIRM_OPTION);
-
-	message = "Added 1 to initial length=" + previousCount + ", but resulted with a count=" +
-		mActivity.getListView().getCount();
-	assertEquals(message, ++previousCount, mActivity.getListView().getCount());
-
-	// Check Content; Name; Num; Starred
-	assertEquals(INPUT_NAME_1 + "1", getTextFromView(0, android.R.id.text1));
-	assertEquals("5435754532", getTextFromView(0, android.R.id.text2));
-
-	//Check email is saved
-	//cursor = returnEmailCursorAtId("1");
-	Uri uri = Uri.parse("content://contacts/people/1");
-	uri = Uri.withAppendedPath(uri, ContactMethods.CONTENT_DIRECTORY);
-	Cursor cursor = mActivity.getContentResolver().query(uri, CONTACTS_COLUMNS, null, null, null);
-	assertTrue("returnEmailCursorAtId: Moving cursor to first row has failed", cursor.first());
-
-	int dataIndex = cursor.getColumnIndexOrThrow("data");
-	assertEquals("1" + INPUT_EMAIL_1, cursor.getString(dataIndex));
-	cursor.deactivate();
-}
-	</pre>
-
-
-<a name="androidTestingKindsofTests"></a><h3>Deciding Kinds of Tests to Write</h3>
-
-<p>Once you are bootstrapped with your test application, you can start writing tests.  There are three of types of tests you may wish to write:</p> 
-<p><ul> 
-<li> <strong>TestCase</strong>: The standard junit test case.
-</li> 
-<li> <strong>AndroidTestCase</strong>: A test case with access to a Context object that is injected for you by the instrumentation test runner.
-</li> 
-<li> <strong>InstrumentationTestCase</strong>: A test case with access to an Instrumentation, which can be used to launch activities, content providers, send key events, etc.
-</li> 
-</ul> 
-</p> 
-<p>The API Demos test suite includes examples of all three styles and can be used as a guideline for writing each type of test.</p>
-<p>There are two utility classes available for the most common uses of InstrumentationTestCase: ActivityTestCase and ProviderTestCase.  See their javadoc for more information.
-</p>
-
-
-<a name="androidInstrumentationFrameworkTroubleshooting"></a><h2>Troubleshooting</h2>
-
-<p>If you run your test cases and nothing appears to happen, have a look at <code>adb logcat</code>. The following is a common problem:</p>
-<pre class="prettify">
-I/dalvikvm(  688): threadid=11: attached from native, name=Binder Thread #1
-I/dalvikvm(  688): threadid=13: attached from native, name=Binder Thread #2
-W/ActivityManager(  469): Unable to find instrumentation info for: ComponentInfo{com.google.android.browser_instrumentation/com.google.android.browser_instrumentation.BrowserWebkitLayoutInstrumentation}
-D/AndroidRuntime(  688): Shutting down VM
-E/AndroidRuntime(  688): ERROR: thread attach failed
-</pre>		
-<p>It's possible that the instrumentation apk isn't installed on your device or that the package name is incorrect in the Manifest file. </p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/intro_source_code.html b/pdk/docs/intro_source_code.html
deleted file mode 100755
index f86b568..0000000
--- a/pdk/docs/intro_source_code.html
+++ /dev/null
@@ -1,378 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20index.html%20v0.5%20-%2025%20September%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="source_setup_guide.html">Host System Setup</a></li>
-
-            <li><a href="getting_source_code.html">Getting Source Code</a></li>
-            <li> <a href="intro_source_code.html">Source Code Overview</a></li>			
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio Subsystem</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidIntroSourceCodeTitle"></a><h1>Source Code Overview</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidSourceCodeDirectories">Introduction</a><br/>
-<a href="#Android_Source">Android Source</a><br/><div style="padding-left:40px">
-
-<a href="#androidSourceCodeDirectoriesKernel">Linux Kernel</a><br/>
-<a href="#androidSourceCodeDirectoriesDevice">Android Platform and Applications</a><br/></div>
-<a href="#androidSourceGuidelines">Adding Source Code</a><br/></div></font></div>
-
-<a name="androidSourceCodeDirectories"></a><h2>Introduction</h2>
-
-<p>Android source code is maintained in two code bases: the Android Linux kernel (<code>kernel</code> directory) and Android platform and applications (<code>device</code> directory). This document provides a high-level introduction to the source code organization and an overview of the major components of each primary directory.</p>
-
-<a name="Android_Source"></a><h2>Android Source</h2>
-
-
-<a name="androidSourceCodeDirectoriesKernel"></a><h3>Linux Kernel</h3>
-
-<p>The Android Linux kernel includes enhancements to the Linux 2.6 kernel that provide additional drivers to support the Android platform, including:</p>
-<ul>
-  <li>Binder: an OpenBinder-based driver to facilitate inter-process communication (IPC) in the Android platform.</li>
-  <li>Android Power Management: a light weight power management driver built on top of standard Linux power management but optimized for embedded systems.</li>
-  <li>Low Memory Killer: Based on hints from the userspace, the low memory killer can kill off processes to free up memory as necessary. It is designed to provide more flexibility than the Out Of Memory (OOM) killer in the standard kernel.</li>
-  <li>Logger: A light weight logging device used to capture system, radio, logdata, etc.</li>
-  <li>USB Gadget: Uses the USB function framework.</li>
-  <li>Android/PMEM: The PMEM (physical memory) driver is used to provide contiguous physical memory regions to userspace libraries that interact with the digital signal processor (DSP) and other hardware that cannot cope with scatter-gather.</li>
-  <li>Android Alarm: A driver which provides timers that can wake the device up from sleep and a monotonic timebase that runs while the device is asleep.</li>
-</ul>
-<p>Look for Android-specific enhancements in the following directories:</p>
-<p><ul>
-<li><code>/drivers/android</code></li>
-<li><code>/drivers/misc</code></li>
-<li><code>/include/linux</code></li>
-</ul>
-</p>
-
-
-<a name="androidSourceCodeDirectoriesDevice"></a><h3>Android Platform and Applications</h3>
-
-<p>The following list outlines the directory structure found within the <code>device</code> branch of Android source code:</p>
-
-
-<p><span class="lh2"><a name="gmapiMobileTagsListStart"></a></span>
-
-<ul>
-
-
-<li>apps
-Core Android applications such as Phone, Camera, and Calendar.
-</li>
-
-
-<li>boot
-Reference Android bootloader and other boot-related source code.
-</li>
-
-
-<li>commands
-Common Android commands, the most important of which is the runtime command, which does much of the initialization of the system.
-</li>
-
-
-<li>config
-System-wide makefiles and linker scripts.
-</li>
-
-
-<li>content
-Standard Android ContentProvider modules.
-</li>
-
-
-<li>dalvik
-Android runtime Virtual Machine (VM).
-</li>
-
-
-<li>data
-Fonts, keymaps, sounds, timezone information, etc.
-</li>
-
-
-<li>docs
-Full set of Android documentation.
-</li>
-
-
-<li>extlibs
-Non-Android libraries. This directory is intended to host unmodified external code. None of the libraries included within this directory rely on Android headers or libraries.
-</li>
-
-
-<li>ide
-Tools for support of the IDE's used to write Android applications.
-</li>
-
-
-<li>include
-Android system headers for inclusion.
-</li>
-
-
-<li>java
-Android core APIs, as well as some external libraries.
-</li>
-
-
-<li>libs
-Android-specific C++ based libraries.
-</li>
-
-
-<li>partner
-Project-specific source code for various proprietary components.
-</li>
-
-
-<li>prebuilt
-Prebuilt tools, like the toolchains and emulator binary.
-</li>
-
-
-<li>product
-Device-specific configuration files. This directory will include a subdirectory for each new device.
-</li>
-
-
-<li>samples
-Sample applications.
-</li>
-
-
-<li>servers
-C++ based system servers.
-</li>
-
-
-<li>system
-Core of the embedded Linux platform at the heart of Android. These essential bits are required for basic booting, operation, and debugging.
-</li>
-
-
-<li>tests
-Platform and application test cases.
-</li>
-
-
-<li>tools
-Tools for building and debugging Android (of particular interest for porting are "adb" and "emulator").
-</li>
-
-
-
-<p><span class="lh2"><a name="gmapiMobileTagsListEnd"></a></span>
-
-</ul>
-
-
-<a name="androidSourceGuidelines"></a><h2>Adding Source Code</h2>
-
-<p>You can develop Android applications with the same standard tools you use to develop any Java application. The Android core libraries provide the functionality needed to build rich mobile applications and the Android development tools are designed to simplify running, debugging, and testing your applications.</p>
-
-<p>Add project-specific source code to the Android source tree under the <code>partner</code> directory in a directory specific to the application or service you are building. For example, all Google-specific applications would be placed under <code>device/partner/google/</code>.  A Google search application would be placed under <code>device/partner/google/apps/Search</code>.
-<p>See <a href="build_new_device.html">Building Android for a new Mobile Device</a> for detailed instructions.</p>
-
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.5 - 25 September 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/keymaps_keyboard_input.html b/pdk/docs/keymaps_keyboard_input.html
deleted file mode 100755
index 9a1a66a..0000000
--- a/pdk/docs/keymaps_keyboard_input.html
+++ /dev/null
@@ -1,713 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20eymaps_keyboard_input.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidKeymapTitle"></a><h1>Keymaps and Keyboard Input</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidKeymapIntro">Introduction</a><br/>
-<a href="#androidKeymapFunctionality">Functionality</a><br/>
-<a href="#androidKeymapKeyLayoutMapTitle">Key Layout Map</a><br/><div style="padding-left:40px">
-
-<a href="#androidKeymapKeyLayoutMapSelection">Selection of a Key Layout Map</a><br/>
-<a href="#androidKeymapKeyLayoutMapFileFormat">File Format</a><br/>
-<a href="#androidKeymapKeyLayoutMapExample">Example of a Key Layout Map File</a><br/></div>
-<a href="#androidKeymapKeyCharMap">Key Character Map</a><br/><div style="padding-left:40px">
-
-<a href="#androidKeymapKeyCharMapSelection">Selection of a Key Character Map</a><br/>
-<a href="#androidKeymapKeyCharMapFileFormat">File Format</a><br/>
-<a href="#androidKeymapKeyCharMapExample">Example of a Key Character Map File</a><br/>
-<a href="#androidKeymapKeyCharMapResourceBinaryFileFormat">Resource Binary File Format</a><br/></div>
-<a href="#androidKeymapDriverTemplate">Implementing Your Own Driver (Driver Template)</a><br/>
-<a href="#androidKeymapKeyCharMapSampleImplementation">Sample Implementation</a><br/></div></font></div>
-
-<a name="androidKeymapIntro"></a><h2>Introduction</h2>
-
-<p>This document describes how keyboard input gets translated into Android actions and how you can customize key layout and key character maps to match the needs of your own device. </p>
-<p>Android uses the standard Linux input event device (<code>/dev/event0</code>) and driver as described in the <code>linux/input.h</code> kernel header file. For more information regarding standard Linux input drivers, please see <a href="http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.24.y.git;a=blob;f=Documentation/input/input.txt">Linux Input drivers</a> at <a href="http://kernel.org">http://kernel.org</a>.</p>
-
-
-
-
-<a name="androidKeymapFunctionality"></a><h2>Functionality</h2>
-
-<p>Android's input event device is structured around an interrupt or polling routine that captures the device-specific scancode and converts it to a standard form acceptable to Linux (as defined in <code>input.h</code>) before passing it to the kernel with <code>input_event()</code>.</p>
-<p>The keymap driver's other primary function is to establish a probe function that sets up the interrupt or polling function, handles hardware initialization, and attaches the driver to the input subsystem with <code>input_register_device()</code>.</p>
-<p>The table below describes the steps required to translate from keyboard input to application action: </p>
-<table border=1>
-    <tbody><tr>
-      <th scope="col">Step</th>
-        <th scope="col">Action</th>
-        <th scope="col">Explanation</th>
-    </tr>
-	<tr>
-	  <td>1.</td>
-	  <td>Window manager reads key event from Linux keyboard driver. </td>
-	  <td>Events are typically positional. For example, the top-left position on a keypad returns 16 regardless of whether that key is printed with a Q (as on a QWERTY keypad) or an A (as on an AZERTY keypads). This first conversion by the Linux Keyboard Driver yields a scancode (for example, 16).</td>
-	</tr>
-	<tr>
-	  <td>2. </td>
-	  <td>Window manager maps scancode to keycode.</td>
-	  <td>When the window manager reads a key event out of the driver, it maps the scancode to a keycode using a key layout map file. Typically, the keycode is the primary symbol screen-printed on a key. For example, <code>KEYCODE_DPAD_CENTER</code> is the center button on the five-way navigation control. Even though ALT + G generates a &quot;?&quot; character, <code>KEYCODE_G</code> is the keycode.</td>
-	  </tr>
-	<tr>
-	  <td>3. </td>
-	  <td>Window manager  sends both the scancode and the keycode to the application.</td>
-	  <td>Both the scancode and keycode are handled by the view with focus. 
-  How the application interprets both depend on the application.</td>
-	  </tr>
-</tbody>
-</table>
-
-
-<a name="androidKeymapKeyLayoutMapTitle"></a><h2>Key Layout Map</h2>
-
-
-
-<a name="androidKeymapKeyLayoutMapSelection"></a><h3>Selection of a Key Layout Map</h3>
-
-<p>Key layout maps are installed in <code>/system/usr/keylayout</code> and <code>/data/usr/keylayout</code>.</p>
-<p>For each keyboard device xxx, set the <code>android.keylayout.xxx</code> system property (see <a href="build_new_device.html">Building New Device</a> for help setting system properties). If you don't specify a keylayout file, Android will default to <code>/system/usr/keylayout/qwerty.kl</code>.</p>
-
-
-<a name="androidKeymapKeyLayoutMapFileFormat"></a><h3>File Format</h3>
-
-<p>Key layout maps are stored on the device as UTF-8 text files and have the following characteristics:</p>
-<p><ul>
-<li>Comments: The pound symbol (#) denotes a comment and everything after the pound symbol on a line is ignored.</li>
-<li>Whitespace: All empty lines are ignored.</li>
-<li>Key definitions: Key definitions follow the syntax <code>key SCANCODE KEYCODE [FLAGS...]</code>, where <code>SCANCODE</code> is a number, <code>KEYCODE</code> is defined in your specific keylayout file (<code>android.keylayout.xxx</code>), and potential <code>FLAGS</code> are defined as follows:
-<ul><li>SHIFT: While pressed, the shift key modifier is set</li>
-<li>ALT: While pressed, the alt key modifier is set</li>
-<li>CAPS: While pressed, the caps lock key modifier is set</li>
-<li>WAKE: When this key is pressed while the device is asleep, the device will wake up and the key event gets sent to the app.</li>
-<li>WAKE_DROPPED: When this key is pressed while the device is asleep, the device will wake up and the key event does not get sent to the app.</li>
-</ul>
-</li>
-</ul>
-</p>
-
-
-<a name="androidKeymapKeyLayoutMapExample"></a><h3>Example of a Key Layout Map File</h3>
-
-<p>The following code comes from  <code>android/src/device/product/generic/tuttle2.kl</code> and is an example of a complete key layout file:</p>
-<pre class="prettify">
-# Copyright 2007 Google Inc.
-
-key 2     1
-key 3     2
-key 4     3
-key 5     4
-key 6     5
-key 7     6
-key 8     7
-key 9     8
-key 10    9
-key 11    0
-key 158   BACK              WAKE_DROPPED
-key 230   SOFT_RIGHT        WAKE
-key 60    SOFT_RIGHT        WAKE
-key 107   ENDCALL           WAKE_DROPPED
-key 62    ENDCALL           WAKE_DROPPED
-key 229   MENU         WAKE_DROPPED
-key 59    MENU         WAKE_DROPPED
-key 228   POUND
-key 227   STAR
-key 231   CALL              WAKE_DROPPED
-key 61    CALL              WAKE_DROPPED
-key 232   DPAD_CENTER       WAKE_DROPPED
-key 108   DPAD_DOWN         WAKE_DROPPED
-key 103   DPAD_UP           WAKE_DROPPED
-key 102   HOME              WAKE
-key 105   DPAD_LEFT         WAKE_DROPPED
-key 106   DPAD_RIGHT        WAKE_DROPPED
-key 115   VOLUME_UP
-key 114   VOLUME_DOWN
-key 116   POWER             WAKE
-key 212   SLASH
-
-key 16    Q
-key 17    W
-key 18    E
-key 19    R
-key 20    T
-key 21    Y
-key 22    U
-key 23    I
-key 24    O
-key 25    P
-
-key 30    A
-key 31    S
-key 32    D
-key 33    F
-key 34    G
-key 35    H
-key 36    J
-key 37    K
-key 38    L
-key 14    DEL
-        
-key 44    Z
-key 45    X
-key 46    C
-key 47    V
-key 48    B
-key 49    N
-key 50    M
-key 51    COMMA
-key 52    PERIOD
-key 28    NEWLINE
-        
-key 56    ALT_LEFT
-key 42    SHIFT_LEFT
-key 215   AT
-key 57    SPACE
-key 53    SLASH
-key 127   SYM
-key 100   ALT_LEFT
-
-key 399   GRAVE
-</pre>
-
-
-<a name="androidKeymapKeyCharMap"></a><h2>Key Character Map</h2>
-
-
-
-<a name="androidKeymapKeyCharMapSelection"></a><h3>Selection of a Key Character Map</h3>
-
-<p>Key character maps are installed in <code>/system/usr/keychars</code> and <code>/data/usr/keychars</code>.</p>
-<p>For each keyboard device xxx, set the <code>android.keychar.xxx</code> system property to the full path of the desired keychar file. If you don't specify a keychar file, Android will default to <code>/system/usr/keychar/qwerty.kl</code>.
-
-
-<a name="androidKeymapKeyCharMapFileFormat"></a><h3>File Format</h3>
-
-<p>Key character maps are stored on the device as binary resources in order to reduce loading time. Key character maps have the following characteristics:</p>
-<p><ul>
-
-<li>Comments: The pound symbol (#) denotes a comment and everything after the pound symbol on a line is ignored.</li>
-<li>Whitespace: All empty lines are ignored.</li>
-<li>Column definitions: Column definitions follow the syntax <code>columns MODIFIERS [...]</code>, where <code>MODIFIERS</code> are defined as follows:
-<table border=1 cellpadding=2 cellspacing=0>
-    <tbody><tr>
-        <th scope="col">Character in MODIFIERS</th>
-        <th scope="col">Corresponding bit in the modifiers</th>
-    </tr>
-    <tr>
-        <td>O</td>
-        <td>no modifiers</td>
-    </tr>
-    <tr>
-        <td>S</td>
-        <td>MODIFIER_SHIFT</td>
-    </tr>
-    <tr>
-        <td>C</td>
-        <td>MODIFIER_CONTROL</td>
-    </tr>
-    <tr>
-        <td>L</td>
-        <td>MODIFIER_CAPS_LOCK</td>
-    </tr>
-    <tr>
-        <td>A</td>
-        <td>MODIFIER_ALT</td>
-    </tr>
-</table>
-</li>
-<li>Key definitions: Key definitions have the syntax <code>key SCANCODE CHARACTER [...]</code> where <code>SCANCODE</code> is a number and <code>CHARACTER</code> values are either UTF-8 characters in quotation marks (for example, "a") or a numeric value that <code>strtol</code> can parse.</li>
-</ul></p>
-
-
-<a name="androidKeymapKeyCharMapExample"></a><h3>Example of a Key Character Map File</h3>
-
-<p>The following code comes from <code>android/src/device/product/generic/tuttle2.kcm</code> and represents a complete key character file:</p>
-<p>The type line indicates what kind of keyboard your device implements. Possible types include:</p>
-<p><ul>
-<li><b>NUMERIC</b>: A numeric (12-key) keyboard.</li>
-<li><b>Q14</b>: A keyboard that includes all letters but multiple letters per key.</li>
-<li><b>QWERTY</b>: A keyboard with all letters and possibly numbers. This option applies to all full keyboard configurations, such as AZERTY.</li>
-</ul>
-</p>
-<pre class="prettify">
-# Copyright 2007 Google Inc.
-
-[type=QWERTY]
-
-# keycode   base    caps    fn      caps_fn number  display_label
-
-A           'a'     'A'     '%'     0x00    '%'     'A'
-B           'b'     'B'     '='     0x00    '='     'B'
-C           'c'     'C'     '8'     0x00E7  '8'     'C'
-D           'd'     'D'     '5'     0x00    '5'     'D'
-E           'e'     'E'     '2'     0x0301  '2'     'E'
-F           'f'     'F'     '6'     0x00A5  '6'     'F'
-G           'g'     'G'     '-'     '_'     '-'     'G'
-H           'h'     'H'     '['     '{'     '['     'H'
-I           'i'     'I'     '$'     0x0302  '$'     'I'
-J           'j'     'J'     ']'     '}'     ']'     'J'
-K           'k'     'K'     '"'     '~'     '"'     'K'
-L           'l'     'L'     '''     '`'     '''     'L'
-M           'm'     'M'     '>'     0x00    '>'     'M'
-N           'n'     'N'     '<'     0x0303  '<'     'N'
-O           'o'     'O'     '('     0x00    '('     'O'
-P           'p'     'P'     ')'     0x00    ')'     'P'
-Q           'q'     'Q'     '*'     0x0300  '*'     'Q'
-R           'r'     'R'     '3'     0x20AC  '3'     'R'
-S           's'     'S'     '4'     0x00DF  '4'     'S'
-T           't'     'T'     '+'     0x00A3  '+'     'T'
-U           'u'     'U'     '&'     0x0308  '&'     'U'
-V           'v'     'V'     '9'     '^'     '9'     'V'
-W           'w'     'W'     '1'     0x00    '1'     'W'
-X           'x'     'X'     '7'     0xEF00  '7'     'X'
-Y           'y'     'Y'     '!'     0x00A1  '!'     'Y'
-Z           'z'     'Z'     '#'     0x00    '#'     'Z'
-
-COMMA       ','     ';'     ';'     '|'     ','     ','
-PERIOD      '.'     ':'     ':'     0x2026  '.'     '.'
-AT          '@'     '0'     '0'     0x2022  '0'     '@'
-SLASH       '/'     '?'     '?'     '\'     '/'     '/'
-
-SPACE       0x20    0x20    0x9     0x9     0x20    0x20
-NEWLINE     0xa     0xa     0xa     0xa     0xa     0xa
-
-# on pc keyboards
-TAB         0x9     0x9     0x9     0x9     0x9     0x9
-0           '0'     ')'     ')'     ')'     '0'     '0'
-1           '1'     '!'     '!'     '!'     '1'     '1'
-2           '2'     '@'     '@'     '@'     '2'     '2'
-3           '3'     '#'     '#'     '#'     '3'     '3'
-4           '4'     '$'     '$'     '$'     '4'     '4'
-5           '5'     '%'     '%'     '%'     '5'     '5'
-6           '6'     '^'     '^'     '^'     '6'     '6'
-7           '7'     '&'     '&'     '&'     '7'     '7'
-8           '8'     '*'     '*'     '*'     '8'     '8'
-9           '9'     '('     '('     '('     '9'     '9'
-
-GRAVE         '`'     '~'     '`'     '~'     '`'     '`'
-MINUS         '-'     '_'     '-'     '_'     '-'     '-'
-EQUALS        '='     '+'     '='     '+'     '='     '='
-LEFT_BRACKET  '['     '{'     '['     '{'     '['     '['
-RIGHT_BRACKET ']'     '}'     ']'     '}'     ']'     ']'
-BACKSLASH     '\'     '|'     '\'     '|'     '\'     '\'
-SEMICOLON     ';'     ':'     ';'     ':'     ';'     ';'
-APOSTROPHE    '''     '"'     '''     '"'     '''     '''
-STAR          '*'     '*'     '*'     '*'     '*'     '*'
-POUND         '#'     '#'     '#'     '#'     '#'     '#'
-PLUS          '+'     '+'     '+'     '+'     '+'     '+'
-</pre>
-
-
-<a name="androidKeymapKeyCharMapResourceBinaryFileFormat"></a><h3>Resource Binary File Format</h3>
-
-<p>The file snippet above gets converted to the following by the <code>makekcharmap</code> tool as part of the build process. You can <code>mmap</code> this file in and share the approximately 4k of memory that it uses between processes to minimize load time.</p>
-<table>
-    <tbody><tr>
-        <th scope="col">Offset</th>
-
-        <th scope="col">Size (bytes)</th>
-        <th scope="col">Description</th>
-    </tr>
-    <tr>
-        <td>0x00-0x0b</td>
-        <td></td>
-        <td>The ascii value "keycharmap1" including the null character</td>
-
-    </tr>
-    <tr>
-        <td>0x0c-0x0f</td>
-        <td></td>
-        <td>padding</td>
-    </tr>
-    <tr>
-        <td>0x10-0x13</td>
-
-        <td></td>
-        <td>The number of entries in the modifiers table (COLS)</td>
-    </tr>
-    <tr>
-        <td>0x14-0x17</td>
-        <td></td>
-        <td>The number of entries in the characters table (ROWS)</td>
-
-    </tr>
-    <tr>
-        <td>0x18-0x1f</td>
-        <td></td>
-        <td>padding</td>
-    </tr>
-    <tr>
-        <td></td>
-
-        <td>4*COLS</td>
-        <td>Modifiers table.  The modifier mask values that each of the 
-            columns in the characters table correspond to.</td>
-    </tr>
-    <tr>
-        <td></td>
-        <td></td>
-        <td>padding to the next 16 byte boundary</td>
-
-    </tr>
-    <tr>
-        <td></td>
-        <td>4*COLS*ROWS</td>
-        <td>Characters table.  The modifier mask values that each of the
-            columns correspond to.</td>
-    </tr>
-</tbody></table>
-
-
-<a name="androidKeymapDriverTemplate"></a><h2>Implementing Your Own Driver (Driver Template)</h2>
-
-<p>The following file, <code>pguide_events.c</code>, illustrates how to implement an Android keymap driver.</p>
-<pre class="prettyprint">
-/*
- * pguide_events.c
- *
- * ANDROID PORTING GUIDE: INPUT EVENTS DRIVER TEMPLATE
- *
- * This template is designed to an example of the functionality
- * necessary for Android to recieve input events.  The PGUIDE_EVENT
- * macros are meant as pointers indicating where to implement the
- * hardware specific code necessary for the new device.  The existence
- * of the macros is not meant to trivialize the work required, just as
- * an indication of where the work needs to be done.
- * 
- * Copyright 2007, Google Inc.
- * Based on goldfish-events.c
- *
- */
-
-#include <linux/module.h>
-#include <linux/init.h>
-#include <linux/interrupt.h>
-#include <linux/types.h>
-#include <linux/input.h>
-#include <linux/kernel.h>
-#include <linux/platform_device.h>
-
-
-#include <asm/irq.h>
-#include <asm/io.h>
-
-
-
-#define PGUIDE_EVENTS_INTERRUPT do{} while(0)
-#define PGUIDE_EVENTS_PROBE do{} while(0)
-
-struct event_dev {
-    struct input_dev *input;
-    int irq;
-};
-
-static irqreturn_t pguide_events_interrupt(int irq, void *dev_id)
-{
-    struct event_dev *edev = dev_id;
-    unsigned type=0, code=0, value=0;
-
-    /* Set up type, code, and value per input.h
-     */
-    PGUIDE_EVENTS_INTERRUPT;
-
-    input_event(edev->input, type, code, value);
-    return IRQ_HANDLED;
-}
-
-static int pguide_events_probe(struct platform_device *pdev)
-{
-    struct input_dev *input_dev;
-    struct event_dev *edev;
-    
-    printk("*** pguide events probe ***\n");
-
-    edev = kzalloc(sizeof(struct event_dev), GFP_KERNEL);
-    input_dev = input_allocate_device();
-
-    /* Setup edev->irq and do any hardware init */
-    PGUIDE_EVENTS_PROBE;
-
-    if(request_irq(edev->irq, pguide_events_interrupt, 0,
-                   "pguide_events", edev) < 0) {
-        goto fail;
-    }
-    
-        /* indicate that we generate key events */
-    set_bit(EV_KEY, input_dev->evbit);
-    set_bit(EV_REL, input_dev->evbit);
-    set_bit(EV_ABS, input_dev->evbit);
-
-    /* indicate that we generate *any* key event */
-
-    bitmap_fill(input_dev->keybit, KEY_MAX);
-    bitmap_fill(input_dev->relbit, REL_MAX);
-    bitmap_fill(input_dev->absbit, ABS_MAX);
-    
-    platform_set_drvdata(pdev, edev);
-
-    input_dev->name = "pguide_events";
-    input_dev->private = edev;
-    input_dev->cdev.dev = &pdev->dev;
-    
-    input_register_device(input_dev);
-    return 0;
-
-fail:
-    kfree(edev);
-    input_free_device(input_dev);
-    
-    return -EINVAL;
-}
-
-static struct platform_driver pguide_events_driver = {
-    .probe = pguide_events_probe,
-    .driver = {
-        .name = "pguide_events",
-    },
-};
-
-static int __devinit pguide_events_init(void)
-{
-    return platform_driver_register(&pguide_events_driver);
-}
-
-
-static void __exit pguide_events_exit(void)
-{
-}
-
-module_init(pguide_events_init);
-module_exit(pguide_events_exit);
-
-MODULE_DESCRIPTION("Pguide Event Device");
-MODULE_LICENSE("GPL");
-</pre>
-
-
-<a name="androidKeymapKeyCharMapSampleImplementation"></a><h2>Sample Implementation</h2>
-
-<p>Assume the following for the setup of a new keypad device:</p>
-<pre class="prettify">
-android.keylayout.partnerxx_keypad = /system/usr/keylayout/partnerxx_keypad.kl
-android.keychar.partnerxx_keypad = /system/usr/keychars/partnerxx.kcm
-</pre>
-<p>The following example log file indicates that you have correctly registered the new keypad:</p>
-<pre class="prettify">
-I/EventHub( 1548): New device: path=/dev/input/event0 name=partnerxx_keypad id=0x10000 (of 0x1) index=1 fd=30
-I/EventHub( 1548): new keyboard input device added, name = partnerxx_keypad
-D/WindowManager( 1548): Starting input thread.
-D/WindowManager( 1548): Startup complete!
-I/EventHub( 1548): New keyboard: name=partnerxx_keypad 
-  keymap=partnerxx_keypad.kl 
-  keymapPath=/system/usr/keychars/partnerxx_keypad.kcm.bin
-I/ServiceManager( 1535): ServiceManager: addService(window, 0x13610)
-I/EventHub( 1548): Reporting device opened: id=0x10000, name=/dev/input/event0
-I/KeyInputQueue( 1548): Device added: id=0x10000, name=partnerxx_keypad, classes=1
-I/KeyInputQueue( 1548):   Keymap: partnerxx_keypad.kl
-</pre>
-<p>The snippet above contains artificial line breaks to maintain a print-friendly document.</p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/modules.html b/pdk/docs/modules.html
deleted file mode 100755
index ea2a07a..0000000
--- a/pdk/docs/modules.html
+++ /dev/null
@@ -1,37 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
-<title>Doxygen-Generated Content</title>
-<link href="doxygen.css" rel="stylesheet" type="text/css" />
-<style type="text/css">
-<!--
-.navigation {
-	display: none;
-}
--->
-</style>
-</head>
-<body>
-<!-- Generated by Doxygen 1.5.6 -->
-<div class="navigation" id="top">
-  <div class="tabs">
-    <ul>
-      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
-      <li class="current"><a href="modules.html"><span>Modules</span></a></li>
-      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
-      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
-      <li><a href="files.html"><span>Files</span></a></li>
-    </ul>
-  </div>
-</div>
-<div class="contents">
-<h1>Modules</h1>Here is a list of all modules:<ul>
-<li><a class="el" href="group__networking.html">Neworking Support</a>
-<ul>
-<li><a class="el" href="group__memory.html">Porividng Heap Memory</a>
-</ul>
-</ul>
-</div>
-</body>
-</html>
diff --git a/pdk/docs/power_management.html b/pdk/docs/power_management.html
deleted file mode 100755
index eb510dd..0000000
--- a/pdk/docs/power_management.html
+++ /dev/null
@@ -1,311 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20power_management.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidPowerTitle"></a><h1>Power Management</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidPowerIntro">Introduction</a><br/>
-<a href="#androidPowerWakeLocks">Wake Locks</a><br/><div style="padding-left:40px">
-
-<a href="#androidPowerWakeLocksDefinitions">Types of Wake Locks</a><br/>
-<a href="#androidPowerWakeLockExample">Exploring a Wake Lock Example</a><br/></div>
-<a href="#androidPowerPowerManagerClass">PowerManager class</a><br/>
-<a href="#androidPowerKernelRegistration">Registering Drivers with the PM Driver</a><br/></div></font></div>
-
-<a name="androidPowerIntro"></a><h2>Introduction</h2>
-
-<p>Android supports its own Power Management (on top of the standard Linux Power Management) designed with the premise that the CPU shouldn't consume power if no applications or services require power. For more information regarding standard Linux power management, please see <a href="http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.24.y.git;a=blob;f=Documentation/pm.txt">Linux Power Management Support</a> at <a href="http://kernel.org">http://kernel.org</a>.</p>
-<p>Android requires that applications and services request CPU resources with &quot;wake locks&quot; through the Android application framework and native Linux libraries. If there are no active wake locks, Android will shut down the CPU. </p>
-<p>The image below illustrates the Android power management architecture. </p>
-<p><img src='androidPMArchitecture.gif'></p>
-
-Solid elements represent Android blocks and dashed elements represent partner-specific blocks.
-
-
-
-<a name="androidPowerWakeLocks"></a><h2>Wake Locks</h2>
-
-<p>Wake locks are used by applications and services to request CPU resources.</p>
-
-
-<a name="androidPowerWakeLocksDefinitions"></a><h3>Types of Wake Locks</h3>
-
-<table border=1 cellpadding=2 cellspacing=0>
-    <tbody><tr>
-        <th scope="col">Wake Lock </th>
-        <th scope="col">Description</th>
-    </tr>
-    <tr>
-      <td>ACQUIRE_CAUSES_WAKEUP<br/></td>
-        <td>Normally wake locks don't actually wake the device, they just cause it to remain on once it's already on. Think of the video player app as the normal behavior. Notifications that pop up and want the device to be on are the exception; use this flag to be like them.</td>
-    </tr>
-    <tr>
-      <td>FULL_WAKE_LOCK</td>
-      <td>Wake lock that ensures that the screen and keyboard are on at full brightness. </td>
-    </tr>
-    <tr>
-      <td>ON_AFTER_RELEASE</td>
-      <td>When this wake lock is released, poke the user activity timer so the screen stays on for a little longer.</td>
-    </tr>
-    <tr>
-      <td>PARTIAL_WAKE_LOCK</td>
-      <td>Wake lock that ensures that the CPU is running. The screen might not be on.</td>
-    </tr>
-    <tr>
-      <td>SCREEN_BRIGHT_WAKE_LOCK</td>
-      <td>Wake lock that ensures that the screen is on at full brightness; the keyboard backlight will be allowed to go off.</td>
-    </tr>
-    <tr>
-      <td>SCREEN_DIM_WAKE_LOCK</td>
-      <td>Wake lock that ensures that the screen is on, but the keyboard backlight will be allowed to go off, and the screen backlight will be allowed to go dim.</td>
-    </tr>
-</table>
-
-
-<a name="androidPowerWakeLockExample"></a><h3>Exploring a Wake Lock Example</h3>
-
-<p>All power management calls follow the same basic format:</p>
-<p><ol><li>Acquire handle to the <code>PowerManager</code> service.</li>
-<li>Create a wake lock and specify the power management flags for screen, timeout, etc.</li>
-<li>Acquire wake lock.</li>
-<li>Perform operation (play MP3, open HTML page, etc.).</li>
-<li>Release wake lock.</li>
-</ol>
-</p>
-<p>The snippet below illustrates this process.</p>
-<pre class="prettify">
-PowerManager pm = (PowerManager)mContext.getSystemService(
-                                          Context.POWER_SERVICE);
-PowerManager.WakeLock wl = pm.newWakeLock(
-                                      PowerManager.SCREEN_DIM_WAKE_LOCK
-                                      | PowerManager.ON_AFTER_RELEASE,
-                                      TAG);
-wl.acquire();
- // ...
-wl.release();
-</pre>
-
-
-<a name="androidPowerPowerManagerClass"></a><h2>PowerManager class</h2>
-
-<p>The Android Framework exposes power management to services and applications through the <code>PowerManager</code> class.</p>
-<p>User space native libraries (any hardware function in <code>//device/lib/hardware/</code> meant to serve as supporting libraries for Android runtime) should never call into Android Power Management directly (see the image above). Bypassing the power management policy in the Android runtime will destabilize the system.</p>
-<p>All calls into Power Management should go through the Android runtime PowerManager APIs.</p>
-<p> Please visit 
-<a href="http://code.google.com/android/reference/android/os/PowerManager.html">http://code.google.com/android/reference/android/os/PowerManager.html</a> for a description of the API and examples.</p>
-
-
-<a name="androidPowerKernelRegistration"></a><h2>Registering Drivers with the PM Driver</h2>
-
-<p>You can register Kernel-level drivers with the Android Power Manager driver so that they're notified immediately before power down or after power up. For example, you might set a display driver to completely power down when a request comes in to power down from the user space (see the Android MSM MDDI display driver for a sample implementation).</p>
-<p>To register drivers with the Android PM driver, implement call-back handlers and register them with the Android PM, as illustrated in the snippet below:</p>
-<pre class="prettify">
-android_register_early_suspend(android_early_suspend_t *handler)
-android_register_early_resume(android_early_resume_t *handler)
-</pre>
-<p>It is critical in a drive to return immediately and not wait for anything to happen in the call back.</p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/source_setup_guide.html b/pdk/docs/source_setup_guide.html
deleted file mode 100755
index 1588b29..0000000
--- a/pdk/docs/source_setup_guide.html
+++ /dev/null
@@ -1,323 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20index.html%20v0.5%20-%2025%20September%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="source_setup_guide.html">Host System Setup</a></li>
-
-            <li><a href="getting_source_code.html">Getting Source Code</a></li>
-            <li> <a href="intro_source_code.html">Source Code Overview</a></li>			
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio Subsystem</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidSourceAccessSetupGuideTitle"></a><h1>Host System Setup</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidSourceSetupIntro">Introduction</a><br/>
-<a href="#androidSourceSetupBuildSystemSetupPackages">Installing Packages</a><br/><div style="padding-left:40px">
-
-<a href="#androidSourceSetupBuildSystemSetupRequiredPackages">Required Packages</a><br/>
-<a href="#androidSourceSetupUbuntu606Intro">Ubuntu 6.06 (Dapper)</a><br/>
-<a href="#androidSourceSetupUbuntu710Intro">Ubuntu 7.10</a><br/>
-<a href="#androidSourceSetupUbuntu804Intro">Ubuntu 8.04</a><br/></div>
-<a href="#androidSourceSetupBuildSystemSetupJavaIntro">Installing Java</a><br/></div></font></div>
-
-<a name="androidSourceSetupIntro"></a><h2>Introduction</h2>
-
-<p>This section provides instructions on how to configure your host system to build Android for mobile devices. While Android is designed as host-environment agnostic, it has been tested and is known to work on the following Linux operating system; Ubuntu 6.06 (Dapper), 7.10 (Gutsy), and 8.04. Cygwin is not recommended. </p>
-
-
-<a name="androidSourceSetupBuildSystemSetupPackages"></a><h2>Installing Packages</h2>
-
-
-
-<a name="androidSourceSetupBuildSystemSetupRequiredPackages"></a><h3>Required Packages</h3>
-
-<p>Android requires the following system packages:</p>
-<p><ul>
-<li>flex: This lexical analyzer generator is used to read a given input file for a description of a scanner to generate.</li>
-<li>bison: This is a general-purpose parser generator.</li>
-<li>gperf: This is a perfect hash function generator.</li>
-<li>libesd0-dev: This enlightened sound daemon (dev files) is used to mix digitized audio streams for playback by a single device.</li>
-<li>libwxgtk2.6-dev: This package provides GUI components and other facilities for many different platforms.</li>
-<li>build-essential: This package contains a list of packages considered fundamental to building Debian packages.</li>
-</ul></p>
-
-
-<a name="androidSourceSetupUbuntu606Intro"></a><h3>Ubuntu 6.06 (Dapper)</h3>
-
-<p>On a clean Dapper system, type the following:</p>
-<pre class="prettyprint">
-% sudo apt-get install flex bison gperf libesd0-dev libwxgtk2.6-dev zlib1g-dev 
-   build-essential
-</pre>
-<p>This snippet includes an artificial line break to maintain a print-friendly document.</p>
-
-
-<a name="androidSourceSetupUbuntu710Intro"></a><h3>Ubuntu 7.10</h3>
-
-<ol><li>The libwxgtk2.6-dev package will only work if the following code is included in your  /etc/apt/source file.
-<p><pre class="prettyprint">
-## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
-## team, and may not be under a free license. Please satisfy yourself as to
-## your rights to use the software. Also, please note that software in
-## universe WILL NOT receive any review or updates from the Ubuntu security
-## team.
-# Line commented out by installer because it failed to verify:
-deb http://us.archive.ubuntu.com/ubuntu/ gutsy universe
-# Line commented out by installer because it failed to verify:
-deb-src http://us.archive.ubuntu.com/ubuntu/ gutsy universe
-# Line commented out by installer because it failed to verify:
-deb http://us.archive.ubuntu.com/ubuntu/ gutsy-updates universe
-# Line commented out by installer because it failed to verify:
-deb-src http://us.archive.ubuntu.com/ubuntu/ gutsy-updates universe
-</pre></p></li>
-<li>Install required packages with the following command:
-<p><pre class="prettyprint">
-% sudo apt-get install flex bison gperf libesd0-dev libwxgtk2.6-dev zlib1g-dev
-   build-essential
-</pre></p>
-This snippet includes an artificial line break to maintain a print-friendly document.
-</li>
-<li>
-<p>Install the X11 development environment with the following commands:</p>
-<p><pre class="prettyprint">
-% sudo apt-get install x-dev
-% sudo apt-get install libx11-dev
-% sudo apt-get install libncurses5-dev
-</pre></p>
-</li>
-</ol>
-
-
-<a name="androidSourceSetupUbuntu804Intro"></a><h3>Ubuntu 8.04</h3>
-
-<p>On a clean system, type the following:</p>
-<pre class="prettify">
-% sudo apt-get install flex bison gperf libesd0-dev libwxgtk2.6-dev
-zlib1g-dev build-essential
-% sudo apt-get install x-dev
-% sudo apt-get install libx11-dev
-% sudo apt-get install libncurses5-dev
-% sudo apt-get install sun-java5-jdk
-</pre>
-
-
-<a name="androidSourceSetupBuildSystemSetupJavaIntro"></a><h2>Installing Java</h2>
-
-<p>Android source code includes a hard dependency on the Java Developer Kit (JDK) 5.0 Update 12 or greater. The specific file name of the Update 12 package is <code>jdk-1_5_0_12-linux-i586.bin</code>. To download this version of the Java JDK:</p>
-<p><ol>
-<li>Navigate to: <a href="http://java.sun.com/products/archive/">http://java.sun.com/products/archive/</a>.</li>
-<li>Select '5.0 Update 12' from the 'Java 2 Platform Standard Edition (J2SE)' -> 'JDK/JRE - 5.0' field and click 'Go.'</li>
-<li>Click 'Download JDK.'</li>
-<li>In the 'Linux Platform' section, click 'Linux self-extracting file' associated with the jdk-1_5_0_12-linux-i586.bin package.</li>
-<li>Follow the installation instructions.</li>
-</ol>
-</p>
-
-<p>Once you have cleanly installed the JDK, modify your PATH environment variable to include <code>&lt;jdk-install-dir&gt;/jdk1.5.0_12/bin</code> at its beginning so that Dapper will use the correct installation. </p>
-<p><b>Ubuntu 7.10</b></p>
-<p>An alternative method to quickly install Java is to enable multiverse repo in <code>/etc/apt/sources.list</code> and then execute:</p>
-<pre class="prettyprint">
-% sudo apt-get install sun-java5-jdk
-</pre>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.5 - 25 September 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/system_requirements.html b/pdk/docs/system_requirements.html
deleted file mode 100755
index 2f236cf..0000000
--- a/pdk/docs/system_requirements.html
+++ /dev/null
@@ -1,262 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20system_requirements.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidOHDPortingDeviceRequirements"></a><h1>Device Requirements</h1>
-
-<p>While Android is designed to support a wide variety of hardware platforms and configurations, this section provides recommended minimum device requirements.</p>
-<table border=1 cellpadding=2 cellspacing=0>
-    <tbody><tr>
-      <th scope="col">Feature</th>
-        <th scope="col">Minimum Requirement</th>
-        <th scope="col">Notes</th>
-    </tr>
-	<tr>
-	  <td>Chipset</td>
-	  <td>ARM-based</td>
-	  <td>For the first release, Android is primarily targeted towards mobile handsets and portions of the platform, such as Dalvik VM graphics processing, currently assume an ARM architecture.</td>
-	</tr>
-	<tr>
-	  <td>Memory</td>
-	  <td>128 MB RAM; 256 MB Flash External</td>
-	  <td>Android can boot and run in configurations with less memory, but it isn't recommended.</td>
-	  </tr>
-	<tr>
-	  <td>Storage</td>
-	  <td>Mini or Micro SD </td>
-	  <td>Not necessary for basic bring up, but recommended.</td>
-	  </tr>
-	<tr>
-	  <td>Primary Display </td>
-	  <td>HVGA required</td>
-	  <td>The current Android interface targets a touch-based HVGA resolution display with a touch-interface no smaller than 2.8 inches in size. However, smaller displays will suffice for initial porting.</td>
-	  </tr>
-	<tr>
-	  <td>Navigation Keys </td>
-	  <td>5-way navigation with 5 application keys, power, camera and volume controls</td>
-	  <td>&nbsp;</td>
-	  </tr>
-	<tr>
-	  <td>Camera</td>
-	  <td>2MP CMOS</td>
-	  <td>Not required for basic bring up. </td>
-	  </tr>
-	<tr>
-	  <td>USB</td>
-	  <td>Standard mini-B USB interface</td>
-	  <td>Android uses the USB interface for flashing the device system images and debugging a running device.</td>
-	  </tr>
-	<tr>
-	  <td>Bluetooth</td>
-	  <td>1.2 or 2.0 </td>
-	  <td>Not required for initial bring up.</td>
-	  </tr>
-</tbody>
-</table>
-<p>If available, your Android device can also benefit from the following optional device characteristics:</p>
-<ul>
-  <li>QWERTY keyboard</li>
-  <li>WiFi</li>
-  <li>GPS</li>
-</ul>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/telephony.gif b/pdk/docs/telephony.gif
deleted file mode 100755
index 8515730..0000000
--- a/pdk/docs/telephony.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/telephony.html b/pdk/docs/telephony.html
deleted file mode 100755
index d4826f6..0000000
--- a/pdk/docs/telephony.html
+++ /dev/null
@@ -1,429 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20telephony.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidPowerTelephony"></a><h1>Radio Layer Interface</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidTelephonyIntro">Introduction</a><br/>
-<a href="#androidTelephonyRILInitialization">RIL Initialization</a><br/>
-<a href="#androidTelephonyRILIntro">RIL Interaction</a><br/><div style="padding-left:40px">
-
-<a href="#androidTelephonyRILSolicited">Solicited</a><br/>
-<a href="#androidTelephonyRILUnsolicited">Unsolicited</a><br/></div>
-<a href="#androidTelephonyRILImplementing">Implementing the RIL</a><br/><div style="padding-left:40px">
-
-<a href="#androidTelephonyRILInit">RIL_Init</a><br/></div>
-<a href="#androidTelephonyRILFunctions">RIL Functions</a><br/><div style="padding-left:40px">
-
-<a href="#androidRilFunctionsSolicited">RIL Solicited Command Requests</a><br/>
-<a href="#androidRilFunctionsUnsolicited">RIL Unsolicited Commands</a><br/></div></div></font></div>
-
-<a name="androidTelephonyIntro"></a><h2>Introduction</h2>
-
-<p>Android's Radio Interface Layer (RIL) provides an abstraction layer between Android telephony services (<a href="http://code.google.com/android/reference/android/telephony/package-descr.html">android.telephony</a>) and radio hardware. The RIL is radio agnostic, and includes support for Global System for Mobile communication (GSM)-based radios.&nbsp;</P>
-
-
-<p>The diagram below illustrates the RIL in the context of Android's Telephony system architecture.</p>
-<p><img src="telephony.gif"></p>
-
-Solid elements represent Android blocks and dashed elements represent partner-specific blocks.
-
-<p>The RIL consists of two primary components:</p>
-<p><ul>
-<li><b>RIL Daemon</b>: The RIL daemon initializes the Vendor RIL, processes all communication from Android telephony services, and dispatches calls to the Vendor RIL as solicited commands.</li>
-<li><b>Vendor RIL</b>: The radio-specific Vendor RIL of <code>ril.h</code> that processes all communication with radio hardware and dispatches calls to the RIL Daemon (<code>rild</code>) through unsolicited commands.</li>
-</ul>
-</p>
-
-
-<a name="androidTelephonyRILInitialization"></a><h2>RIL Initialization</h2>
-
-<p>Android initializes the telephony stack and the Vendor RIL at startup as described in the sequence below:</p>
-<p><ol>
-<li>RIL daemon reads <code>rild.lib</code> path and <code>rild.libargs</code> system properties to determine the Vendor RIL library to use and any initialization arguments to provide to the Vendor RIL</li>
-<li>RIL daemon loads the Vendor RIL library and calls <code>RIL_Init</code> to initialize the RIL and obtain a reference to RIL functions</li>
-<li>RIL daemon calls <code>RIL_register</code> on the Android telephony stack, providing a reference to the Vendor RIL functions</li></ol>
-</p>
-<p>See the RIL Daemon source code at <code>//device/commands/rild/rild.c</code> for details.</p>
-
-
-<a name="androidTelephonyRILIntro"></a><h2>RIL Interaction</h2>
-
-<p>There are two forms of communication that the RIL handles:</p>
-<ul>
-  <li>Solicited commands: Solicited commands originated by RIL lib, such as <code>DIAL</code> and <code>HANGUP</code>.</li>
-  <li>Unsolicited responses: Unsolicited responses that originate from the baseband, such as <code>CALL_STATE_CHANGED</code> and <code>NEW_SMS</code>.</li>
-</ul>
-
-
-<a name="androidTelephonyRILSolicited"></a><h3>Solicited</h3>
-
-<p>The following snippet illustrates the interface for solicited commands:</p>
-<pre class="prettify">
-void OnRequest (int request_id, void *data, size_t datalen, RIL_Token t);&#13;
-void OnRequestComplete (RIL_Token t, RIL_Error e, void *response, size_t responselen);&#13;
-</pre>
-<p>There are over sixty solicited commands grouped by the following families:</p>
-<p>
-<ul>
-  <li>SIM PIN, IO, and IMSI/IMEI (11)</li>
-  <li>Call status and handling (dial, answer, mute&hellip;) (16)</li>
-  <li>Network status query (4)</li>
-  <li>Network setting (barring, forwarding, selection&hellip;) (12)</li>
-  <li>SMS (3)</li>
-  <li>PDP connection (4)</li>
-  <li>Power and reset (2)</li>
-  <li>Supplementary Services (5)</li>
-  <li>Vendor defined and support (4)<br/>
-                    </li>
-</ul>
-</p>
-<p>The following diagram illustrates a solicited call in Android.</p>
-<p><img src="telephony_solicted_example.gif"></p>
-
-
-<a name="androidTelephonyRILUnsolicited"></a><h3>Unsolicited</h3>
-
-<p>The following snippet illustrates the interface for unsolicited commands:</p>
-<pre class="prettify">
-void OnUnsolicitedResponse (int unsolResponse, void *data, size_t datalen);
-</pre>
-<p>There are over ten unsolicited commands grouped by the following families:</p>
-<p>
-<ul>
-<li>Network status changed (4)</li>
-<li>New SMS notify (3)</li>
-<li>New USSD notify (2)</li>
-<li>Signal strength or time changed (2)</li>
-</ul>
-</p>
-<p>The following diagram illustrates an unsolicited call in Android.</p>
-<p><img src="telephony_unsolicted_example.gif"></p>
-
-
-<a name="androidTelephonyRILImplementing"></a><h2>Implementing the RIL</h2>
-
-<p>To implement a radio-specific RIL, create a shared library that implements a set of functions required by Android to process radio requests. The required functions are defined in the RIL header (<code>/include/telephony/ril.h</code>).</p>
-<p>The Android radio interface is radio-agnostic and the Vendor RIL can use any protocol to communicate with the radio.&nbsp;Android provides a reference Vendor RIL, using the Hayes AT command set, that you can use as a quick start for telephony testing and a guide for commercial vendor RILs. The source code for the reference RIL is found at <code>/commands/reference-ril/</code>.</p>
-<p>Compile your Vendor RIL as a shared library using the convention <code>libril-&lt;companyname&gt;-&lt;RIL version&gt;.so</code>, for example, libril-acme-124.so, where:</p>
-<p><ul>
-<li><b>libril</b>: all vendor RIL implementations start with 'libril'</li>
-<li><b>&lt;companyname&gt;</b>: a company-specific abbreviation</li>
-<li><b>&lt;RIL version&gt;</b>: RIL version number</li>
-<li><b>so</b>: file extension</li>
-</ul>
-</p>
-
-
-<a name="androidTelephonyRILInit"></a><h3>RIL_Init</h3>
-
-<p>Your Vendor RIL must define a RIL_Init function that provides a handle to the functions which will process all radio requests.  RIL_Init will be called by the Android RIL Daemon at boot time to initialize the RIL.</p>
-
-<pre class="prettify">
-RIL_RadioFunctions *RIL_Init (RIL_Env* env, int argc, char **argv);
-</pre>
-
-<p>RIL_Init should return a RIL_RadioFunctions structure containing the handles to the radio functions:</p>
-<pre class="prettify">
-type structure {
-	int RIL_version;
-	RIL_RequestFunc onRequest;
-	RIL_RadioStateRequest onStateRequest;      
-	RIL_Supports supports;
-	RIL_Cancel onCancel;
-	RIL_GetVersion getVersion;
-} 
-RIL_RadioFunctions;
-</pre>
-
-
-<a name="androidTelephonyRILFunctions"></a><h2>RIL Functions</h2>
-
-<p><code>ril.h</code> defines RIL states and variables, such as <code>RIL_UNSOL_STK_CALL_SETUP</code>, <code>RIL_SIM_READY</code>, <code>RIL_SIM_NOT_READY</code>, as well as the functions described in the tables below. Skim the header file (<code>/device/include/telephony/ril.h</code>) for details.</p>
-
-
-<a name="androidRilFunctionsSolicited"></a><h3>RIL Solicited Command Requests</h3>
-
-<p>The vendor RIL must provide the functions described in the table below to handle solicited commands. The RIL solicited command request types are defined in <code>ril.h</code> with the <code>RIL_REQUEST_</code> prefix. Check the header file for details.</p>
-<p><table>
-  <tr><th scope="col">Name</th><th scope="col">Description</th></tr>
-  <tr>
-    <td valign="top"><code> void (*RIL_RequestFunc) (int request, void *data, size_t datalen, RIL_Token t);</code></td>
-    <td valign="top">
-	<p>This is the RIL entry point for solicited commands and must be able to handle the various RIL solicited request types defined in <code>ril.h</code> with the <code>RIL_REQUEST_</code> prefix.</p>
-	<ul>
-        <li><code>request</code> is one of <code>RIL_REQUEST_*</code></li>
-        <li><code>data</code> is pointer to data defined for that <code>RIL_REQUEST_*</code></l>
-        <li><code>t</code> should be used in subsequent call to <code>RIL_onResponse</code></li>
-        <li><code>datalen</code> is owned by caller, and should not be modified or freed by callee</li>
-      </ul>
-	<p>Must be completed with a call to <code>RIL_onRequestComplete()</code>. &nbsp;<code>RIL_onRequestComplete()</code> may be called from any thread before or after this function returns. This will &nbsp;always be called from the same thread, so returning here implies that the radio is ready to process another command (whether or not the previous command has completed).</p></td>
-  </tr>
-  <tr>
-    <td valign="top"><code> RIL_RadioState (*RIL_RadioStateRequest)();</code></td>
-    <td valign="top">This function should return the current radio state synchronously.</td>
-  </tr>
-  <tr>
-    <td valign="top"><code> int (*RIL_Supports)(int requestCode);</code></td>
-    <td valign="top">This function returns "1" if the specified <code>RIL_REQUEST</code> code is supported and 0 if it is not.</td>
-  </tr>
-  <tr>
-    <td valign="top"><code> void (*RIL_Cancel)(RIL_Token t);</code></td>
-    <td valign="top"><p>This function is used to indicate that a pending request should be canceled. This function is called from a separate thread--not the thread that calls <code>RIL_RequestFunc</code>.</p>
-      <p>On cancel, the callee should do its best to abandon the request and call <code>RIL_onRequestComplete</code> with <code>RIL_Errno CANCELLED</code> at some later point.</p>
-      <p>Subsequent calls to <code>RIL_onRequestComplete</code> for this request with other results will be tolerated but ignored (that is, it is valid to ignore the cancellation request).</p>
-    <p><code>RIL_Cancel</code> calls should return immediately and not wait for cancellation.</p></td>
-  </tr>
-  <tr>
-    <td valign="top"><code> const char * (*RIL_GetVersion) (void);</code></td>
-    <td valign="top">Return a version string for your Vendor RIL</td>
-  </tr>
-</table>
-
-
-<p>The vendor RIL uses the following callback methods to communicate back to the Android RIL daemon.</p>
-<p>
-<table>
-  <tr>
-    <th scope="col">Name</th>
-    <th scope="col">Description</th>
-  </tr>
-  <tr>
-    <td><code>void RIL_onRequestComplete(RIL_Token t, RIL_Errno e, void *response, size_t responselen);</code></td>
-    <td><ul>
-      <li><code>t</code> is parameter passed in on previous call to <code>RIL_Notification</code> routine.</li>
-      <li>If <code>e</code> != SUCCESS, then response can be null and is ignored</li>
-      <li><code>response</code> is owned by caller, and should not be modified or freed by callee</li>
-      <li><code>RIL_onRequestComplete</code> will return as soon as possible</li>
-    </ul></td>
-  </tr>
-  <tr>
-    <td><code>void RIL_requestTimedCallback (RIL_TimedCallback callback, void *param, const struct timeval *relativeTime);</code></td>
-    <td>Call user-specified callback function on the same thread that <code>RIL_RequestFunc</code> is called. If <code>relativeTime</code> is specified, then it specifies a relative time value at which the callback is invoked. If <code>relativeTime</code> is NULL or points to a 0-filled structure, the callback will be invoked as soon as possible.</td>
-  </tr>
-</table></p>
-
-
-<a name="androidRilFunctionsUnsolicited"></a><h3>RIL Unsolicited Commands</h3>
-
-<p>The functions listed in the table below are call-back functions used by the Vendor RIL to invoke unsolicited commands on the Android platform. See <code>ril.h</code> for details. </p>
-<p>
-<table>
-  <tr>
-    <th scope="col">Name</th>
-    <th scope="col">Description</th>
-  </tr>
-  <tr>
-    <td><code>void RIL_onUnsolicitedResponse(int unsolResponse, const void *data, size_t datalen);</code></td>
-    <td><ul>
-      <li><code>unsolResponse</code> is one of <code>RIL_UNSOL_RESPONSE_*</code></li>
-      <li><code>data</code> is pointer to data defined for that <code>RIL_UNSOL_RESPONSE_*</code></li>
-      <li><code>data</code> is owned by caller, and should not be modified or freed by callee</li>
-    </ul></td>
-  </tr>
-</table></p>
-
-
-<p><span class="lh2"><a name="androidFooter"></a></span>
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/docs/telephony_solicted_example.gif b/pdk/docs/telephony_solicted_example.gif
deleted file mode 100755
index 352ca98..0000000
--- a/pdk/docs/telephony_solicted_example.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/telephony_unsolicted_example.gif b/pdk/docs/telephony_unsolicted_example.gif
deleted file mode 100755
index e51c4d6..0000000
--- a/pdk/docs/telephony_unsolicted_example.gif
+++ /dev/null
Binary files differ
diff --git a/pdk/docs/wifi.html b/pdk/docs/wifi.html
deleted file mode 100755
index df40fb0..0000000
--- a/pdk/docs/wifi.html
+++ /dev/null
@@ -1,250 +0,0 @@
-
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
-<title>Android - Porting Guide</title>
-<script src="http://www.google.com/uds/api?file=uds.js&amp;v=1.0&amp;key=internal-codesite" type="text/javascript"></script>
-<script src="http://code.google.com/js/jquery.js" type="text/javascript"></script>
-<script type="text/javascript">var _tocPath_ = 'http://code.google.com/android/_toc.ezt';</script>
-<script src="http://code.google.com/js/codesite.pack.01312008.js" type="text/javascript"></script>
-<script language="JavaScript">
-function resizeHeight() {
-	if(document.getElementById && !(document.all)) {
-		height= document.getElementById('doxygen').contentDocument.body.scrollHeight + 20;
-		document.getElementById('doxygen').style.height = height;
-	}
-	else if(document.all) {
-		height= document.frames('doxygen').document.body.scrollHeight + 20;
-		document.all.doxygen.style.height = height;
-	}
-}
-</script>
-<link href="http://code.google.com/css/codesite.pack.01312008.css" type="text/css" rel="stylesheet">
-</link>
-
-<!--[if IE]><link rel="stylesheet" type="text/css" href="/css/iehacks.css" /><![endif]-->
-<script src="http://code.google.com/android/assets/search_autocomplete.js"></script>
-<link rel="stylesheet" type="text/css" href="http://code.google.com/css/semantic_headers.css" />
-<link rel="stylesheet" type="text/css" href="http://code.google.com/android/assets/style.css" />
-<script>
-    jQuery(document).ready(function() {
-            jQuery("pre").addClass("prettyprint");
-        });
-    </script>
-<style type="text/css">
-<!--
-h1,h2,h3 {
-	color: #000000;
-}
--->
-</style>
-</head>
-<body class="gc-documentation">
-<div id="gc-container">
-<a name="top"></a>
-<div id="skipto"> </div>
-<div id="langpref">
-  <!--<a class="dropdown" href="/">English</a> <span>|</span> <a href="/more/">Site Directory</a> -->
-
-</div>
-<div id="gc-header">
-  <div id="logo"><a href="http://code.google.com/android/index.html"><img src="http://code.google.com/android/images/logo_android.gif" alt="Android"/></a></div>
-  <div id="search" style="inline">
-    <div id="searchForm" class="searchForm" style="height: 44px;">
-      <!--previously form was here-->
-    </div>
-    <!-- end searchForm -->
-    <noscript>
-    <style type="text/css">
-      .searchForm {
-        display : none !important;
-      }
-      .searchForm2 {
-        display : inline !important;
-      }
-      </style>
-    </noscript>
-
-    <div id="searchForm2" class="searchForm2" style="display:none">
-      <form id="searchbox_001456098540849067467:6whlsytkdqg" action="http://www.google.com/cse">
-        <input type="hidden" name="cx" value="001456098540849067467:6whlsytkdqg" />
-        <input type="hidden" name="cof" value="FORID:0" />
-        <input type="text" name="q" maxlength="2048" size="41" autocomplete="off" title="Google Code Search"/>
-        <input type="submit" name="sa" value="Search" title="Search"/>
-        <br/>
-        <div class="greytext">e.g. "ajax apis" or "open source"</div>
-
-      </form>
-    </div>
-    <!-- end searchForm2 -->
-  </div>
-  <!-- end search -->
-</div>
-<!-- end gc-header -->
-<div id="searchControl" class="search-control"></div>
-<!--[if IE]><iframe id="backiFrame" name="backiFrame" src='/dummy.html' style="display:none"></iframe><![endif]-->
-<div id="codesiteContent">
-<a name="gc-topnav-anchor"></a>
-<div id="gc-topnav">
-
-  <h1>Android Platform Development Kit</h1>
-  <ul class="gc-topnav-tabs">
-    <li id="sdk_link"> <a href="http://code.google.com/android/index.html" title="Android Software Development Kit">SDK</a> </li>
-    <li id="docs_link"> <a href="index.html" title="Official Android documentation">Docs</a> </li>
-    <li id="faq_link"> <a href="http://code.google.com/android/kb/index.html" title="Answers to frequently asked questions about Android">FAQ</a> </li>
-
-    <li> <a href="http://android-developers.blogspot.com/" title="Official Android blog">Blog</a> </li>
-    <li> <a href="http://code.google.com/android/groups.html" title="Android developer forum">Group</a> </li>
-    <li> <a href="http://code.google.com/android/terms.html" title="Android terms of service">Terms</a> </li>
-    <li> <a href="mailto:android-pdk-feedback@google.com?subject=PDK%20Feedback&body=(filed%20from:%20wifi.html%20v0.6%20-%2025%20November%202008)%0D%0A%0D%0ASUMMARY:%0D%0A%0D%0A%0D%0A%0D%0ASTEPS%20TO%20REPRODUCE:%0D%0A%0D%0A%0D%0A%0D%0AADDITIONAL%20NOTES:">Report a Problem</a> </li>
-
-  </ul>
-</div>
-<!-- end gc-topnav -->
-<div class="g-section g-tpl-180">
-<a name="gc-toc"></a>
-<div class="g-unit g-first" id="gc-toc">
-  <ul>
-    <li>
-      <h1><a href="index.html">Documentation</a></h1>
-      <ul>
-        <li> <strong>Introduction</strong>
-
-          <ul>
-            <li><a href="system_requirements.html">Device Requirements</a></li>            
-          </ul>
-        </li>
-        <li> <strong>Dev Environment Setup</strong>
-          <ul>
-            <li><a href="build_system.html">Build System</a></li>
-          </ul>
-        </li>
-        <li> <strong>Basic Bring up</strong>
-
-          <ul>
-            <li><a href="build_new_device.html">Building New Device</a></li>
-            <li><a href="bring_up.html">Bring up</a></li>
-            <li><a href="keymaps_keyboard_input.html">Keymaps and Keyboard</a></li>
-            <li><a href="display_drivers.html">Display Drivers</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Multimedia</strong>
-          <ul>
-            <li><a href="audio_sub_system.html">Audio</a></li>
-            <li><a href="camera.html">Camera</a></li>			
-          </ul>
-        </li>
-        <li> <strong>Power Management</strong>
-
-          <ul>
-            <li><a href="power_management.html">Power Management</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Networking</strong>
-          <ul>
-            <li><a href="wifi.html">Wi-Fi</a></li>
-            <li><a href="gps.html">GPS</a></li>
-            <li><a href="bluetooth.html">Bluetooth</a></li>
-          </ul>
-        </li>
-
-        <li> <strong>Telephony</strong>
-          <ul>
-            <li><a href="telephony.html">Radio Interface Layer</a></li>
-
-          </ul>
-        </li>
-        <li> <strong>Testing</strong>
-          <ul>
-            <li><a href="instrumentation_testing.html">Instrumentation Testing</a></li>
-          </ul>
-
-        </li>
-      </ul>
-    </li>
-  </ul>
-</div>
-<a name="gc-pagecontent"></a>
-<div class="g-unit" id="gc-pagecontent">
-<div id="jd-content">
-<div class="jd-descr">
-
-
-<a name="androidWifiTitle"></a><h1>Wi-Fi</h1>
-
-
-
-<a name="toc"/>
-<div style="padding:10px">
-<a href="#androidWifiIntroduction">Introduction</a><br/>
-<a href="#androidWifiBuildingDriver">Building a Wi-Fi Library</a><br/>
-<a href="#androidWifiInterface">Interface</a><br/></div></font></div>
-
-<a name="androidWifiIntroduction"></a><h2>Introduction</h2>
-
-<p>Android uses wpa_supplicant as the platform interface to the Wi-Fi device. Your Wi-Fi driver must be compatible with the standard wpa_supplicant in addition to extensions added to the supplicant (specifically, the "DRIVER" commands described in <code>wifi.h/wifi_command()</code>).</p>
-
-
-<a name="androidWifiBuildingDriver"></a><h2>Building a Wi-Fi Library</h2>
-
-<p>To create a Wi-Fi driver for Android:</p>
-<p><ul>
-<li>create a shared library that implements the interface defined in <code>include/hardware/wifi.h</code>, which also defines the Wi-Fi supplicant.</li>
-<li>Follow the instructions posted at <a href="http://hostap.epitest.fi/wpa_supplicant/">http://hostap.epitest.fi/wpa_supplicant/</a>.</li>
-<li>Place your driver in <code>libs/hardware/wifi/</code></li>
-<li>Test your driver using the command line <code>wpa_cli</code> utilities.</li>
-</ul>
-
-<p>You can find the default implementation in <code>libs/hardware/wifi/wifi.c</code>. If you need to make changes, create a new source file similar to <code>wifi.c</code>, for example, <code>wifi_mywifi.c</code>. </p>
-
-<p>Update the default <code>Android.mk</code> file (<code>libs/hardware/wifi/Android.mk</code>) as shown below.</p>
-<pre class="prettify">
-LOCAL_SHARED_LIBRARIES += libnetutils
-
-ifeq ($(TARGET_DEVICE),acme)
-LOCAL_SRC_FILES += wifi/wifi_mywifi.c
-else
-LOCAL_SRC_FILES += wifi/wifi.c
-endif
-</pre>
-
-
-<a name="androidWifiInterface"></a><h2>Interface</h2>
-
-
-
-<p class="note"><strong>Note</strong>: This document relies on some Doxygen-generated content that appears in an iFrame below. To return to the Doxygen default content for this page, <a href="wifi.html">click here</a>.</p>
-
-
-<iframe onLoad="resizeHeight();" src="wifi_8h.html" scrolling="no" scroll="no" id="doxygen" marginwidth="0" marginheight="0" frameborder="0" style="width:100%;"></iframe>
-
-
-        </div>
-      </div>
-      <!-- end gc-pagecontent -->
-    </div>
-    <!-- end gooey wrapper -->
-  </div>
-  <!-- end codesearchresults -->
-  <div id="gc-footer" dir="ltr">
-    <div class="text"> &copy;2008 Google<!-- - <a href="/">Code Home</a> - <a href="http://www.google.com/accounts/TOS">Site Terms of Service</a> - <a href="http://www.google.com/privacy.html">Privacy Policy</a> - <a href="/more">Site Directory</a> --></div>
-  </div>
-  <!-- end gc-footer -->
-</div>
-<!-- end gc-containter -->
-<script src="http://www.google-analytics.com/ga.js" type="text/javascript">
-</script>
-<script type="text/javascript">
-  try {
-    var pageTracker = _gat._getTracker("UA-18071-1");
-    pageTracker._setAllowAnchor(true);
-    pageTracker._initData();
-    pageTracker._trackPageview(); 
-  } catch(e) {}
-</script>
-<div id="jd-build-id"> v0.6 - 25 November 2008</div>
-</div></div></div></body>
-</html>
-
diff --git a/pdk/doxygen_config/docsfiles/groups.dox b/pdk/doxygen_config/docsfiles/groups.dox
deleted file mode 100644
index 79f9d3f..0000000
--- a/pdk/doxygen_config/docsfiles/groups.dox
+++ /dev/null
@@ -1,3 +0,0 @@
-

-/*!

-*/

diff --git a/pdk/doxygen_config/docsfiles/main.dox b/pdk/doxygen_config/docsfiles/main.dox
deleted file mode 100644
index 069c1a2..0000000
--- a/pdk/doxygen_config/docsfiles/main.dox
+++ /dev/null
@@ -1,5 +0,0 @@
-/*! \mainpage Google Client Location Library (CLL): location Interface

- *  <p>This documentation is part of Google's Client Location Library (CLL) Getting Started Guide.</p>

- *  <p>In most cases, this Doxygen-generated content opens in a new window (or tab), so look for this window's parent to return to the Getting Started guide. If you maintained 

- *  the original directory structure when you unzipped the documentation, you may also return to the Getting Started guide by clicking <a href="../cll_getting_started.html">Client Location Library (CLL) Getting Started Guide</a>.</p>

- */
\ No newline at end of file
diff --git a/pdk/doxygen_config/footer.html b/pdk/doxygen_config/footer.html
deleted file mode 100644
index 691287b..0000000
--- a/pdk/doxygen_config/footer.html
+++ /dev/null
@@ -1,2 +0,0 @@
-</body>
-</html>
\ No newline at end of file
diff --git a/pdk/doxygen_config/header.html b/pdk/doxygen_config/header.html
deleted file mode 100644
index b26c303..0000000
--- a/pdk/doxygen_config/header.html
+++ /dev/null
@@ -1,15 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
-<title>Doxygen-Generated Content</title>
-<link href="doxygen.css" rel="stylesheet" type="text/css" />
-<style type="text/css">
-<!--
-.navigation {
-	display: none;
-}
--->
-</style>
-</head>
-<body>
\ No newline at end of file
diff --git a/pdk/doxygen_config/overrideconfig.conf b/pdk/doxygen_config/overrideconfig.conf
deleted file mode 100644
index f1e3819..0000000
--- a/pdk/doxygen_config/overrideconfig.conf
+++ /dev/null
@@ -1,50 +0,0 @@
-

-#---------------------------------------------------------------------------

-# Project related configuration options

-#---------------------------------------------------------------------------

-DOXYFILE_ENCODING      = UTF-8

-PROJECT_NAME           = pdk

-PROJECT_NUMBER         = 

-

-INPUT                  = sources \

-                         docsfiles

-

-OUTPUT_DIRECTORY       = generatedDocs

-HTML_HEADER            = header.html

-HTML_FOOTER            = footer.html

-# FILL IN PATH TO HEADER BLOB WANTED IN EVERY FILE

-# RELATIVE PATH TO WHER ERUNNING DOXYGEN FROM

-HTML_STYLESHEET        =

-# PATH TO STYLE SHEET\

-

-BRIEF_MEMBER_DESC      = YES 

-REPEAT_BRIEF           = YES

-

-OPTIMIZE_OUTPUT_FOR_C  = YES

-

-ALWAYS_DETAILED_SEC    = YES

-INLINE_INHERITED_MEMB  = NO

-FULL_PATH_NAMES        = NO

-STRIP_FROM_PATH        = 

-STRIP_FROM_INC_PATH    = 

-SHORT_NAMES            = NO

-JAVADOC_AUTOBRIEF      = YES

-QT_AUTOBRIEF           = NO

-MULTILINE_CPP_IS_BRIEF = NO

-DETAILS_AT_TOP         = NO

-INHERIT_DOCS           = YES

-SEPARATE_MEMBER_PAGES  = NO

-

-QUIET                  = NO

-WARNINGS               = YES

-

-

-

-SOURCE_BROWSER         = YES

-

-GENERATE_HTML          = YES

-ENABLE_PREPROCESSING   = NO

-

-# ADDED JULY 08 TO TRY TO FIGURE OUT DOCUMENING C FILES

-EXTRACT_ALL            = YES

-STRIP_CODE_COMMENTS    = NO 
diff --git a/pdk/doxygen_config/pdk_config.conf b/pdk/doxygen_config/pdk_config.conf
deleted file mode 100644
index 1f1f349..0000000
--- a/pdk/doxygen_config/pdk_config.conf
+++ /dev/null
@@ -1,273 +0,0 @@
-# Doxyfile 1.5.6

-

-#---------------------------------------------------------------------------

-# Project related configuration options

-#---------------------------------------------------------------------------

-DOXYFILE_ENCODING      = UTF-8

-PROJECT_NAME           = pdk

-PROJECT_NUMBER         = 

-OUTPUT_DIRECTORY       = 

-CREATE_SUBDIRS         = NO

-OUTPUT_LANGUAGE        = English

-BRIEF_MEMBER_DESC      = YES 

-REPEAT_BRIEF           = YES

-ABBREVIATE_BRIEF       = "The $name class" \

-                         "The $name widget" \

-                         "The $name file" \

-                         is \

-                         provides \

-                         specifies \

-                         contains \

-                         represents \

-                         a \

-                         an \

-                         the

-ALWAYS_DETAILED_SEC    = YES

-INLINE_INHERITED_MEMB  = NO

-FULL_PATH_NAMES        = NO

-STRIP_FROM_PATH        = 

-STRIP_FROM_INC_PATH    = 

-SHORT_NAMES            = NO

-JAVADOC_AUTOBRIEF      = YES

-QT_AUTOBRIEF           = NO

-MULTILINE_CPP_IS_BRIEF = NO

-DETAILS_AT_TOP         = NO

-INHERIT_DOCS           = YES

-SEPARATE_MEMBER_PAGES  = NO

-TAB_SIZE               = 8

-ALIASES                = 

-OPTIMIZE_OUTPUT_FOR_C  = NO

-OPTIMIZE_OUTPUT_JAVA   = NO

-OPTIMIZE_FOR_FORTRAN   = NO

-OPTIMIZE_OUTPUT_VHDL   = NO

-BUILTIN_STL_SUPPORT    = NO

-CPP_CLI_SUPPORT        = NO

-SIP_SUPPORT            = NO

-IDL_PROPERTY_SUPPORT   = YES

-DISTRIBUTE_GROUP_DOC   = NO

-SUBGROUPING            = YES

-TYPEDEF_HIDES_STRUCT   = NO

-#---------------------------------------------------------------------------

-# Build related configuration options

-#---------------------------------------------------------------------------

-EXTRACT_ALL            = YES

-EXTRACT_PRIVATE        = NO

-EXTRACT_STATIC         = NO

-EXTRACT_LOCAL_CLASSES  = NO

-EXTRACT_LOCAL_METHODS  = NO

-EXTRACT_ANON_NSPACES   = YES

-HIDE_UNDOC_MEMBERS     = NO

-HIDE_UNDOC_CLASSES     = NO

-HIDE_FRIEND_COMPOUNDS  = NO

-HIDE_IN_BODY_DOCS      = NO

-INTERNAL_DOCS          = NO

-CASE_SENSE_NAMES       = YES

-HIDE_SCOPE_NAMES       = NO

-SHOW_INCLUDE_FILES     = NO

-# MIGHT WANT TO TWEAK LEATER

-INLINE_INFO            = YES

-SORT_MEMBER_DOCS       = YES

-SORT_BRIEF_DOCS        = YES

-SORT_GROUP_NAMES       = NO

-SORT_BY_SCOPE_NAME     = NO

-GENERATE_TODOLIST      = NO

-GENERATE_TESTLIST      = NO

-GENERATE_BUGLIST       = NO

-GENERATE_DEPRECATEDLIST= YES

-ENABLED_SECTIONS       = 

-MAX_INITIALIZER_LINES  = 30

-SHOW_USED_FILES        = NO

-SHOW_DIRECTORIES       = NO

-SHOW_FILES             = YES

-SHOW_NAMESPACES        = YES

-FILE_VERSION_FILTER    = 

-#---------------------------------------------------------------------------

-# configuration options related to warning and progress messages

-#---------------------------------------------------------------------------

-QUIET                  = NO

-WARNINGS               = YES

-WARN_IF_UNDOCUMENTED   = YES

-WARN_IF_DOC_ERROR      = YES

-WARN_NO_PARAMDOC       = NO

-WARN_FORMAT            = "$file:$line: $text"

-WARN_LOGFILE           = 

-#---------------------------------------------------------------------------

-# configuration options related to the input files

-#---------------------------------------------------------------------------

-INPUT                  = 

-INPUT_ENCODING         = UTF-8

-FILE_PATTERNS          = *.c \

-                	 *.cpp \

-                         *.dox \

-                         *.h \

-                         *.htm \

-                         *.html

-RECURSIVE              = YES

-EXCLUDE                = 

-# ecxlude entire directories or files

-EXCLUDE_SYMLINKS       = NO

-EXCLUDE_PATTERNS       = 

-EXCLUDE_SYMBOLS        = 

-EXAMPLE_PATH           = 

-EXAMPLE_PATTERNS       = *

-EXAMPLE_RECURSIVE      = NO

-IMAGE_PATH             = 

-INPUT_FILTER           = 

-FILTER_PATTERNS        = 

-FILTER_SOURCE_FILES    = NO

-#---------------------------------------------------------------------------

-# configuration options related to source browsing

-#---------------------------------------------------------------------------

-SOURCE_BROWSER         = YES

-INLINE_SOURCES         = NO

-STRIP_CODE_COMMENTS    = YES

-REFERENCED_BY_RELATION = NO

-REFERENCES_RELATION    = YES

-REFERENCES_LINK_SOURCE = NO

-USE_HTAGS              = NO

-VERBATIM_HEADERS       = NO

-#---------------------------------------------------------------------------

-# configuration options related to the alphabetical class index

-#---------------------------------------------------------------------------

-ALPHABETICAL_INDEX     = NO

-COLS_IN_ALPHA_INDEX    = 1

-IGNORE_PREFIX          = 

-#---------------------------------------------------------------------------

-# configuration options related to the HTML output

-#---------------------------------------------------------------------------

-GENERATE_HTML          = YES

-HTML_OUTPUT            = html

-HTML_FILE_EXTENSION    = .html

-HTML_HEADER            = 

-# FILL IN PATH TO HEADER BLOB WANTED IN EVERY FILE

-# RELATIVE PATH TO WHER ERUNNING DOXYGEN FROM

-HTML_FOOTER            = 

-HTML_STYLESHEET        =

-# PATH TO STYLE SHEET

-HTML_ALIGN_MEMBERS     = YES

-GENERATE_HTMLHELP      = NO

-GENERATE_DOCSET        = NO

-DOCSET_FEEDNAME        = "Doxygen generated docs"

-DOCSET_BUNDLE_ID       = org.doxygen.Project

-HTML_DYNAMIC_SECTIONS  = NO

-CHM_FILE               = 

-HHC_LOCATION           = 

-GENERATE_CHI           = NO

-CHM_INDEX_ENCODING     = 

-BINARY_TOC             = NO

-TOC_EXPAND             = NO

-DISABLE_INDEX          = NO

-ENUM_VALUES_PER_LINE   = 4

-GENERATE_TREEVIEW      = NONE

-TREEVIEW_WIDTH         = 250

-FORMULA_FONTSIZE       = 10

-#---------------------------------------------------------------------------

-# configuration options related to the LaTeX output

-#---------------------------------------------------------------------------

-GENERATE_LATEX         = NO

-LATEX_OUTPUT           = latex

-LATEX_CMD_NAME         = latex

-MAKEINDEX_CMD_NAME     = makeindex

-COMPACT_LATEX          = NO

-PAPER_TYPE             = a4wide

-EXTRA_PACKAGES         = 

-LATEX_HEADER           = 

-PDF_HYPERLINKS         = YES

-USE_PDFLATEX           = YES

-LATEX_BATCHMODE        = NO

-LATEX_HIDE_INDICES     = NO

-#---------------------------------------------------------------------------

-# configuration options related to the RTF output

-#---------------------------------------------------------------------------

-GENERATE_RTF           = NO

-RTF_OUTPUT             = rtf

-COMPACT_RTF            = NO

-RTF_HYPERLINKS         = NO

-RTF_STYLESHEET_FILE    = 

-RTF_EXTENSIONS_FILE    = 

-#---------------------------------------------------------------------------

-# configuration options related to the man page output

-#---------------------------------------------------------------------------

-GENERATE_MAN           = NO

-MAN_OUTPUT             = man

-MAN_EXTENSION          = .3

-MAN_LINKS              = NO

-#---------------------------------------------------------------------------

-# configuration options related to the XML output

-#---------------------------------------------------------------------------

-GENERATE_XML           = NO

-XML_OUTPUT             = xml

-XML_SCHEMA             = 

-XML_DTD                = 

-XML_PROGRAMLISTING     = YES

-#---------------------------------------------------------------------------

-# configuration options for the AutoGen Definitions output

-#---------------------------------------------------------------------------

-GENERATE_AUTOGEN_DEF   = NO

-#---------------------------------------------------------------------------

-# configuration options related to the Perl module output

-#---------------------------------------------------------------------------

-GENERATE_PERLMOD       = NO

-PERLMOD_LATEX          = NO

-PERLMOD_PRETTY         = YES

-PERLMOD_MAKEVAR_PREFIX = 

-#---------------------------------------------------------------------------

-# Configuration options related to the preprocessor   

-#---------------------------------------------------------------------------

-ENABLE_PREPROCESSING   = NO

-# KEY CONSIDERATION TWEAK BACK AND FORTH. function in an # if/def preprocessor directive. Processor evalutes whether true. Should doxygen follow compiles behavior or document everything?

-# usually have optional things that people may want to tweak. 

-MACRO_EXPANSION        = YES

-EXPAND_ONLY_PREDEF     = YES

-SEARCH_INCLUDES        = NO

-INCLUDE_PATH           = 

-INCLUDE_FILE_PATTERNS  = 

-PREDEFINED             = 

-#to mimic preprocessor behaviors.

-EXPAND_AS_DEFINED      = 

-SKIP_FUNCTION_MACROS   = YES

-#---------------------------------------------------------------------------

-# Configuration::additions related to external references   

-#---------------------------------------------------------------------------

-TAGFILES               = 

-GENERATE_TAGFILE       = 

-ALLEXTERNALS           = NO

-EXTERNAL_GROUPS        = NO

-PERL_PATH              = 

-#---------------------------------------------------------------------------

-# Configuration options related to the dot tool   

-#---------------------------------------------------------------------------

-CLASS_DIAGRAMS         = NO

-#CHANGE WHEN HAVE DIAGRAMS

-MSCGEN_PATH            = YES

-HIDE_UNDOC_RELATIONS   = YES

-HAVE_DOT               = NO

-DOT_FONTNAME           = FreeSans

-DOT_FONTPATH           = 

-CLASS_GRAPH            = YES

-COLLABORATION_GRAPH    = YES

-GROUP_GRAPHS           = YES

-UML_LOOK               = NO

-TEMPLATE_RELATIONS     = NO

-INCLUDE_GRAPH          = YES

-INCLUDED_BY_GRAPH      = YES

-CALL_GRAPH             = NO

-CALLER_GRAPH           = NO

-GRAPHICAL_HIERARCHY    = YES

-DIRECTORY_GRAPH        = YES

-DOT_IMAGE_FORMAT       = png

-DOT_PATH               = 

-DOTFILE_DIRS           = 

-DOT_GRAPH_MAX_NODES    = 50

-MAX_DOT_GRAPH_DEPTH    = 1000

-DOT_TRANSPARENT        = YES

-DOT_MULTI_TARGETS      = NO

-GENERATE_LEGEND        = YES

-DOT_CLEANUP            = YES

-#---------------------------------------------------------------------------

-# Configuration::additions related to the search engine   

-#---------------------------------------------------------------------------

-SEARCHENGINE           = NO

-@INCLUDE = overrideconfig.conf

-# relative to where running doxygen from

-# @INCLUDE = $(PROJECTCONF)
diff --git a/pdk/hosting/app.yaml b/pdk/hosting/app.yaml
deleted file mode 100644
index 407cbb0..0000000
--- a/pdk/hosting/app.yaml
+++ /dev/null
@@ -1,11 +0,0 @@
-application: pdk-docs
-version: 1
-runtime: python
-api_version: 1
-
-handlers:
-- url: /docs
-  static_dir: docs
-
-- url: /
-  script: pdk.py
diff --git a/pdk/hosting/pdk.py b/pdk/hosting/pdk.py
deleted file mode 100644
index e88f826..0000000
--- a/pdk/hosting/pdk.py
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/bin/python2.5
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""Serve static pages for the pdk on appengine
-"""
-
-import os
-
-from google.appengine.ext import webapp
-from google.appengine.ext.webapp.util import run_wsgi_app
-
-
-class MainPage(webapp.RequestHandler):
-  def get(self):
-    self.redirect('docs/index.html')
-
-application = webapp.WSGIApplication(
-                                     [('/', MainPage)],
-                                     debug=True)
-
-def main():
-  run_wsgi_app(application)
-
-if __name__ == "__main__":
-  main()
-  
-# To upload this application:
-# /home/build/static/projects/apphosting/devtools/appcfg.py update pdk/
-# where the pdk directory contains: pdk.py, app.yaml, and the docs directory.
-# where the docs are made from the Pdk.mk file.
diff --git a/pdk/ndk/Android_NDK_README.html b/pdk/ndk/Android_NDK_README.html
deleted file mode 100644
index d4c307b..0000000
--- a/pdk/ndk/Android_NDK_README.html
+++ /dev/null
@@ -1,741 +0,0 @@
-
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-
-<html>
-
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-
-<base target="_top">
-
-<style type="text/css">
-  
-
-/* default css */
-
-table {
-  font-size: 1em;
-  line-height: inherit;
-}
-
-
-tr {
-  
-  text-align: left;
-  
-}
-
-
-div, address, ol, ul, li, option, select {
-  margin-top: 0px;
-  margin-bottom: 0px;
-}
-
-p {
-  margin: 0px;
-}
-
-body {
-  margin: 6px;
-  padding: 0px;
-  font-family: Verdana, sans-serif;
-  font-size: 10pt;
-  background-color: #ffffff;
-}
-
-
-img {
-  -moz-force-broken-image-icon: 1;
-}
-
-@media screen {
-  html.pageview {
-    background-color: #f3f3f3 !important;
-  }
-
-  
-
-  body {
-    min-height: 1100px;
-    
-    counter-reset: __goog_page__;
-  }
-  * html body {
-    height: 1100px;
-  }
-  .pageview body {
-    border-top: 1px solid #ccc;
-    border-left: 1px solid #ccc;
-    border-right: 2px solid #bbb;
-    border-bottom: 2px solid #bbb;
-    width: 648px !important;
-    margin: 15px auto 25px;
-    padding: 40px 50px;
-  }
-  /* IE6 */
-  * html {
-    overflow-y: scroll;
-  }
-  * html.pageview body {
-    overflow-x: auto;
-  }
-  /* Prevent repaint errors when scrolling in Safari. This "Star-7" css hack
-     targets Safari 3.1, but not WebKit nightlies and presumably Safari 4.
-     That's OK because this bug is fixed in WebKit nightlies/Safari 4 :-). */
-  html*#wys_frame::before {
-    content: '\A0';
-    position: fixed;
-    overflow: hidden;
-    width: 0;
-    height: 0;
-    top: 0;
-    left: 0;
-  }
-  
-  
-
-  
-    .writely-callout-data {
-      display: none;
-      *display: inline-block;
-      *width: 0;
-      *height: 0;
-      *overflow: hidden;
-    }
-    .writely-footnote-marker {
-      background-image: url('MISSING');
-      background-color: transparent;
-      background-repeat: no-repeat;
-      width: 7px;
-      overflow: hidden;
-      height: 16px;
-      vertical-align: top;
-
-      
-      -moz-user-select: none;
-    }
-    .editor .writely-footnote-marker {
-      cursor: move;
-    }
-    .writely-footnote-marker-highlight {
-      background-position: -15px 0;
-      -moz-user-select: text;
-    }
-    .writely-footnote-hide-selection ::-moz-selection, .writely-footnote-hide-selection::-moz-selection {
-      background: transparent;
-    }
-    .writely-footnote-hide-selection ::selection, .writely-footnote-hide-selection::selection {
-      background: transparent;
-    }
-    .writely-footnote-hide-selection {
-      cursor: move;
-    }
-
-    
-    .editor .writely-comment-yellow {
-      background-color: #FF9;
-      background-position: -240px 0;
-    }
-    .editor .writely-comment-yellow-hover {
-      background-color: #FF0;
-      background-position: -224px 0;
-    }
-    .editor .writely-comment-blue {
-      background-color: #C0D3FF;
-      background-position: -16px 0;
-    }
-    .editor .writely-comment-blue-hover {
-      background-color: #6292FE;
-      background-position: 0 0;
-    }
-    .editor .writely-comment-orange {
-      background-color: #FFDEAD;
-      background-position: -80px 0;
-    }
-    .editor .writely-comment-orange-hover {
-      background-color: #F90;
-      background-position: -64px 0;
-    }
-    .editor .writely-comment-green {
-      background-color: #99FBB3;
-      background-position: -48px 0;
-    }
-    .editor .writely-comment-green-hover {
-      background-color: #00F442;
-      background-position: -32px 0;
-    }
-    .editor .writely-comment-cyan {
-      background-color: #CFF;
-      background-position: -208px 0;
-    }
-    .editor .writely-comment-cyan-hover {
-      background-color: #0FF;
-      background-position: -192px 0;
-    }
-    .editor .writely-comment-purple {
-      background-color: #EBCCFF;
-      background-position: -144px 0;
-    }
-    .editor .writely-comment-purple-hover {
-      background-color: #90F;
-      background-position: -128px 0;
-    }
-    .editor .writely-comment-magenta {
-      background-color: #FCF;
-      background-position: -112px 0;
-    }
-    .editor .writely-comment-magenta-hover {
-      background-color: #F0F;
-      background-position: -96px 0;
-    }
-    .editor .writely-comment-red {
-      background-color: #FFCACA;
-      background-position: -176px 0;
-    }
-    .editor .writely-comment-red-hover {
-      background-color: #FF7A7A;
-      background-position: -160px 0;
-    }
-
-    .editor .writely-comment-marker {
-      background-image: url('MISSING');
-      background-color: transparent;
-      padding-right: 11px;
-      background-repeat: no-repeat;
-      width: 16px;
-      height: 16px;
-      -moz-user-select: none;
-    }
-
-    .editor .writely-comment-hidden {
-      padding: 0;
-      background: none;
-    }
-    .editor .writely-comment-marker-hidden {
-      background: none;
-      padding: 0;
-      width: 0;
-    }
-    .editor .writely-comment-none {
-      opacity: .2;
-      filter:progid:DXImageTransform.Microsoft.Alpha(opacity=20);
-      -moz-opacity: .2;
-    }
-    .editor .writely-comment-none-hover {
-      opacity: .2;
-      filter:progid:DXImageTransform.Microsoft.Alpha(opacity=20);
-      -moz-opacity: .2;
-    }
-  
-
-
-  
-  .br_fix br:not(:-moz-last-node):not(:-moz-first-node) {
-    
-    position:relative;
-    
-    left: -1ex
-    
-  }
-  
-  .br_fix br+br {
-    position: static !important
-  }
-}
-
-h6 { font-size: 8pt }
-h5 { font-size: 8pt }
-h4 { font-size: 10pt }
-h3 { font-size: 12pt }
-h2 { font-size: 14pt }
-h1 { font-size: 18pt }
-
-blockquote {padding: 10px; border: 1px #DDD dashed }
-
-a img {border: 0}
-
-.pb {
-  border-width: 0;
-  page-break-after: always;
-  /* We don't want this to be resizeable, so enforce a width and height
-     using !important */
-  height: 1px !important;
-  width: 100% !important;
-}
-
-.editor .pb {
-  border-top: 1px dashed #C0C0C0;
-  border-bottom: 1px dashed #C0C0C0;
-}
-
-div.google_header, div.google_footer {
-  position: relative;
-  margin-top: 1em;
-  margin-bottom: 1em;
-}
-
-
-/* Table of contents */
-.editor div.writely-toc {
-  background-color: #f3f3f3;
-  border: 1px solid #ccc;
-}
-.writely-toc > ol {
-  padding-left: 3em;
-  font-weight: bold;
-}
-ol.writely-toc-subheading {
-  padding-left: 1em;
-  font-weight: normal;
-}
-/* IE6 only */
-* html writely-toc ol {
-  list-style-position: inside;
-}
-.writely-toc-none {
-  list-style-type: none;
-}
-.writely-toc-decimal {
-  list-style-type: decimal;
-}
-.writely-toc-upper-alpha {
-  list-style-type: upper-alpha;
-}
-.writely-toc-lower-alpha {
-  list-style-type: lower-alpha;
-}
-.writely-toc-upper-roman {
-  list-style-type: upper-roman;
-}
-.writely-toc-lower-roman {
-  list-style-type: lower-roman;
-}
-.writely-toc-disc {
-  list-style-type: disc;
-}
-
-/* end default css */
-
-
-  /* default print css */
-  
-  @media print {
-    body {
-      padding: 0;
-      margin: 0;
-    }
-
-    div.google_header, div.google_footer {
-      display: block;
-      min-height: 0;
-      border: none;
-    }
-
-    div.google_header {
-      flow: static(header);
-    }
-
-    /* used to insert page numbers */
-    div.google_header::before, div.google_footer::before {
-      position: absolute;
-      top: 0;
-    }
-
-    div.google_footer {
-      flow: static(footer);
-    }
-
-    /* always consider this element at the start of the doc */
-    div#google_footer {
-      flow: static(footer, start);
-    }
-
-    span.google_pagenumber {
-      content: counter(page);
-    }
-
-    span.google_pagecount {
-      content: counter(pages);
-    }
-
-
-    callout.google_footnote {
-      
-      display: prince-footnote;
-      footnote-style-position: inside;
-      /* These styles keep the footnote from taking on the style of the text
-         surrounding the footnote marker. They can be overridden in the
-         document CSS. */
-      color: #000;
-      font-family: Verdana;
-      font-size: 10.0pt;
-      font-weight: normal;
-    }
-
-    /* Table of contents */
-    #WritelyTableOfContents a::after {
-      content: leader('.') target-counter(attr(href), page);
-    }
-
-    #WritelyTableOfContents a {
-      text-decoration: none;
-      color: black;
-    }
-  }
-
-  @page {
-    @top {
-      content: flow(header);
-    }
-    @bottom {
-      content: flow(footer);
-    }
-    @footnotes {
-      border-top: solid black thin;
-      padding-top: 8pt;
-    }
-  }
-  /* end default print css */
-
-
-/* custom css */
-
-
-/* end custom css */
-
-
-
-  /* ui edited css */
-  
-  body {
-    font-family: Verdana;
-    
-    font-size: 10.0pt;
-    line-height: normal;
-    background-color: #ffffff;
-  }
-  /* end ui edited css */
-
-
-
-/* editor CSS */
-.editor a:visited {color: #551A8B}
-.editor table.zeroBorder {border: 1px dotted gray}
-.editor table.zeroBorder td {border: 1px dotted gray}
-.editor table.zeroBorder th {border: 1px dotted gray}
-
-
-.editor div.google_header, .editor div.google_footer {
-  border: 2px #DDDDDD dashed;
-  position: static;
-  width: 100%;
-  min-height: 2em;
-}
-
-.editor .misspell {background-color: yellow}
-
-.editor .writely-comment {
-  font-size: 9pt;
-  line-height: 1.4;
-  padding: 1px;
-  border: 1px dashed #C0C0C0
-}
-
-
-/* end editor CSS */
-
-</style>
-
-</head>
-
-<body onload="DoPageLoad();"
-    
-    revision="cfnx2f69_111dp3jzfgb:107">
-
-    
-    
-    
-<h1>

-  Using the Android Native Development Kit (NDK)

-</h1>

-version 1.3<br>

-<br>

-<h2>

-  Introduction

-</h2>

-The Android Native Development Kit enables developers to write shared libraries

-in C or C++ and call them from Java code. The native shared libraries can be

-packaged into apk files along with a normal Android application written in Java,

-so that the resulting Android application can be downloaded and installed on an

-Android phone.<br>

-<br>

-The Native Development Kit consists of:<br>

-<ul>

-  <li>

-    C/C++ headers for native APIs<br>

-  </li>

-  <li>

-    C/C++ libraries for native APIs<br>

-  </li>

-  <li>

-    Documentation

-  </li>

-  <li>

-    Sample Code

-  </li>

-</ul>

-<br>

-The Native Development Kit is designed to be used with the Android SDK:<br>

-<ul>

-  <li>

-    The NDK is used to create a shared library containing native code.

-  </li>

-  <li>

-    The SDK is used to create an Android application written in Java that calls

-    into the native code shared library.

-  </li>

-</ul>

-<h1>

-</h1>

-<h2>

-  Setting up your machine<br>

-</h2>

-The Native Development Kit may be installed on either Linux or OS X. Developing

-under Windows is not yet supported.<br>

-<div>

-  <h3>

-    Linux Installation

-  </h3>

-  The

-  Android&nbsp;build&nbsp;is&nbsp;routinely&nbsp;tested&nbsp;on&nbsp;recent&nbsp;versions&nbsp;of&nbsp;Ubuntu&nbsp;(6.06&nbsp;and&nbsp;later),&nbsp;but

-  may work on other distributions as well.<br>

-  <h4>

-    <a name=TOC-Ubuntu-Linux-i386-></a><span style=FONT-FAMILY:Verdana>Ubuntu

-    Linux (i386)</span>

-  </h4>

-  <div style=FONT-FAMILY:Verdana>

-    To set up your Linux development environment, make sure you have the

-    following:<span style="WORD-SPACING:0px; FONT-STYLE:normal; FONT-VARIANT:normal; FONT-WEIGHT:normal; font-size-adjust:none; font-stretch:normal; TEXT-TRANSFORM:none; COLOR:#000000; WHITE-SPACE:normal; LETTER-SPACING:normal; border-collapse:separate"><font size=2>

-    </font></span>

-  </div>

-  <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px; FONT-FAMILY:Verdana">

-    <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px">

-      <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px">

-        <ul style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px">

-          <li style="MARGIN-TOP:8px; MARGIN-BOTTOM:8px">

-            Git 1.5.4 or

-            newer<span style="FONT-WEIGHT:normal; WORD-SPACING:0px; TEXT-TRANSFORM:none; COLOR:#000000; FONT-STYLE:normal; WHITE-SPACE:normal; LETTER-SPACING:normal; border-collapse:separate; FONT-VARIANT:normal"><font size=2>.&nbsp;</font></span>

-          </li>

-        </ul>

-      </div>

-    </div>

-  </div>

-  <blockquote style="BORDER:medium none ; MARGIN:0pt 0pt 0pt 40px; PADDING:0px">

-    <span style=FONT-FAMILY:arial><span style="FONT-WEIGHT:normal; WORD-SPACING:0px; TEXT-TRANSFORM:none; COLOR:#000000; FONT-STYLE:normal; WHITE-SPACE:normal; LETTER-SPACING:normal; border-collapse:separate; FONT-VARIANT:normal"><span style="FONT-FAMILY:courier new,monospace">$

-    </span></span><span style="FONT-FAMILY:courier new,monospace">sudo apt-get

-    install git-core<br>

-    </span></span>

-  </blockquote>

-  <div>

-    <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px">

-      <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px; FONT-FAMILY:arial,sans-serif">

-        <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px">

-          <h4>

-            <a name=TOC-Ubuntu-Linux-amd64-></a><span style=FONT-FAMILY:Verdana>Ubuntu

-            Linux (amd64)</span>

-          </h4>

-          <span style=FONT-FAMILY:Verdana>This has not been as well

-          tested.</span>

-        </div>

-        <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px; FONT-FAMILY:Verdana">

-          <br>

-        </div>

-        <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px; FONT-FAMILY:Verdana">

-          The Android build requires a 32-bit build environment:

-        </div>

-        <div style="MARGIN-TOP:0px; MARGIN-BOTTOM:0px; FONT-FAMILY:Verdana">

-          <ul>

-            <li>

-              Get the packages as listed above in the i386

-              instructions:<span style="FONT-WEIGHT:normal; WORD-SPACING:0px; TEXT-TRANSFORM:none; COLOR:#000000; FONT-STYLE:normal; WHITE-SPACE:normal; LETTER-SPACING:normal; border-collapse:separate; FONT-VARIANT:normal">&nbsp;&nbsp;&nbsp;</span>

-            </li>

-          </ul>

-        </div>

-      </div>

-    </div>

-  </div>

-  <blockquote style="BORDER:medium none ; MARGIN:0pt 0pt 0pt 40px; PADDING:0px">

-    <span style=FONT-FAMILY:arial><span style="FONT-WEIGHT:normal; WORD-SPACING:0px; TEXT-TRANSFORM:none; COLOR:#000000; FONT-STYLE:normal; WHITE-SPACE:normal; LETTER-SPACING:normal; border-collapse:separate; FONT-VARIANT:normal"><span style="FONT-FAMILY:courier new,monospace">$&nbsp;</span></span><span style="FONT-FAMILY:courier new,monospace">sudo

-    apt-get install git-core<br>

-    </span></span>

-  </blockquote>

-  <h4>

-    <a name=TOC-Other-Linux></a>Other Linux

-  </h4>

-  <p>

-    There's

-    no&nbsp;reason&nbsp;why&nbsp;Android&nbsp;cannot&nbsp;be&nbsp;built&nbsp;on&nbsp;non-Ubuntu&nbsp;systems<span style=FONT-WEIGHT:normal><font size=2>.&nbsp;In&nbsp;general&nbsp;you&nbsp;will&nbsp;need:</font></span>

-  </p>

-  <ul>

-    <li>

-      Git&nbsp;1.5.4&nbsp;or&nbsp;newer.&nbsp;You&nbsp;can&nbsp;find&nbsp;it&nbsp;at&nbsp;<a href=http://git.or.cz/ rel=nofollow>http://git.or.cz/</a><span style=FONT-FAMILY:arial></span>

-    </li>

-  </ul>

-  <div>

-    <h3>

-      Mac OS Installation

-    </h3>

-    <ul>

-      <li>

-        <span style=FONT-FAMILY:arial,sans-serif>To build the Android files in a

-        Mac OS environment, you need an Intel/x86 machine. The Android build

-        system and tools do not support the older PowerPC architecture.</span>

-      </li>

-      <li>

-        <span style=FONT-FAMILY:arial,sans-serif>Android must be built on a

-        case-sensitive file system.<br>

-        </span>

-      </li>

-      <ul>

-        <li>

-          We recommend that you build Android on a partition that has been

-          formatted with the "Case-sensitive Journaled HFS+" file system:

-        </li>

-        <ul>

-          <li>

-            A case-sensitive file system is required because the sources contain

-            files that differ only in case.

-          </li>

-          <li>

-            Journaled systems are more robust. (This is optional, but

-            recommended.)

-          </li>

-          <li>

-            HFS+ is required to successfully build Mac OS applications such as

-            the Android Emulator for OS X.

-          </li>

-        </ul>

-        <li>

-          If you want to avoid partitioning/formatting your hard drive, you can

-          use a case-sensitive disk image instead.

-        </li>

-        <ul>

-          <li>

-            To create the image:<br>

-            <ul>

-              <li>

-                launch /Applications/Utilities/Disk Utility

-              </li>

-              <li>

-                select "New Image"

-              </li>

-              <li>

-                size: 8 GB (this will work, but you can choose more if you want

-                to)

-              </li>

-              <li>

-                volume format: case sensitive, journaled

-              </li>

-            </ul>

-          </li>

-          <li>

-            This will create a .dmg file which, once mounted, acts as a drive

-            with the required formatting for Android development. For a disk

-            image named "android.dmg" stored in your home directory, you can add

-            the following to your ~/.bash_profile to mount the image when you

-            execute "mountAndroid":<br>

-            <br>

-            <div style=MARGIN-LEFT:40px>

-              <span style="FONT-FAMILY:courier new,monospace"># command to mount

-              the android file

-              image</span><br style="FONT-FAMILY:courier new,monospace">

-              <span style="FONT-FAMILY:courier new,monospace">function

-              mountAndroid&nbsp; { hdiutil attach ~/android.dmg&nbsp;

-              -mountpoint /Volumes/android; }</span><br>

-            </div>

-            <br>

-            Once mounted, you'll do all your work in the "android" volume. You

-            can eject it (unmount it) just like you would with an external

-            drive.

-          </li>

-        </ul>

-      </ul>

-    </ul>

-    <div>

-      <br>

-      <ul>

-        <li>

-          Install git 1.5.4 or newer. You can find it at

-          <a href=http://git.or.cz/ rel=nofollow>http://git.or.cz/</a>

-        </li>

-      </ul>

-      <h2>

-        Installing the Android SDK

-      </h2>

-      The Android NDK uses the Android SDK.&nbsp;You can find the Android SDK at

-      <a href=http://code.google.com/android/download.html id=a.-o title=http://code.google.com/android/download.html>http://code.google.com/android/download.html</a><br>

-      This version of the Android NDK requires the Cupcake version of the

-      Android SDK.<br>

-      <br>

-      <h2>

-        Installing the Prebuilt Native Toolchain<br>

-      </h2>

-      The NDK uses the prebuilt native toolchain from the Android Open Source

-      git repository.<br>

-      <br>

-      To download the prebuilt native toolchain to your working directory,

-      execute the following commands:<br>

-      <br>

-      <span style="FONT-FAMILY:Courier New"></span>

-      <div style=MARGIN-LEFT:40px>

-        <span style="FONT-FAMILY:Courier New">git clone

-        git://android.git.kernel.org/platform/prebuilt.git</span><br>

-        <span style="FONT-FAMILY:Courier New">cd prebuilt</span><br>

-        <span style="FONT-FAMILY:Courier New">git checkout -b cupcake -t

-        origin/cupcake</span><br>

-      </div>

-      <div style=MARGIN-LEFT:40px>

-        <span style="FONT-FAMILY:Courier New"></span>

-      </div>

-      <br>

-      <h2>

-        Setting Environment Variables

-      </h2>

-      The NDK requires that you set two environment variables:<br>

-      <ul>

-        <li>

-          PREBUILT must be set to the directory that contains the prebuilt

-          toolchain. Include the "prebuilt" directory in the path. Example:

-          /Volumes/android/prebuilt<br>

-        </li>

-        <li>

-          ANDROID_SDK_BASE must be set to the directory that contains the

-          Android SDK. Example: ~/AndroidSDK<br>

-        </li>

-      </ul>

-      <br>

-      <h2>

-        <span style=FONT-FAMILY:Verdana>Unpacking the NDK</span>

-      </h2>

-      Unpack the android_ndk.tar.gz into your working directory<br>

-      <br>

-      <div style=MARGIN-LEFT:40px>

-        <span style="FONT-FAMILY:Courier New">tar -zxvf

-        android_ndk.tar.gz</span><br>

-      </div>

-      <br>

-      This will create a directory called ndk. It should contain a README.html

-      file (this file) and the following directories: config, include, lib, and

-      sample.<br>

-      <br>

-      Look in the "samples" directory for samples showing how to use the NDK.<br>

-      <br>

-      <br>

-    </div>

-    <br>

-  </div>

-  <br>

-</div>

-<br></body>
-</html>
\ No newline at end of file
diff --git a/pdk/ndk/Ndk.mk b/pdk/ndk/Ndk.mk
deleted file mode 100644
index 0ec3b94..0000000
--- a/pdk/ndk/Ndk.mk
+++ /dev/null
@@ -1,232 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# Assemble the Native Development Kit
-# Assembled using the generic build by default.
-# (set in device/config/product_config.make)
-
-# A macro to make rules to copy all newer files in a directory tree matching an
-# optional find filter and add the files to a list variable for dependencies.
-# Designed after copy_headers.make: Create a rule to copy each file;
-# copy-one-file defines the actual rule.
-# $(1): source directory tree root
-# $(2): destination directory tree root
-# $(3): list variable to append destination files to
-# $(4): optional find(1) arguments
-define define-tree-copy-rules
-  $(eval _src_files := $(shell find $(1) -type f $(4))) \
-  $(foreach _src, $(_src_files), \
-    $(eval _dest := $(patsubst $(1)%,$(2)%,$(_src))) \
-    $(eval $(3) := $($(3)) $(_dest)) \
-    $(eval $(call copy-one-file,$(_src),$(_dest))) \
-   )
-endef
-
-#-------------------------------------------------------------------------------
-# Install all the files needed to build the ndk.
-#   We build three versions of the NDK
-#       (1) The full version, with source.
-#       (2) The full version, without source.
-#       (3) A JNI-only version, with source.
-#
-#   We make five sets of trees:
-#		(A) Common files used in all versions of the NDK
-#   (B) Common files used in the full versions of the NDK
-#		(C) Files used in the standard ndk (no source files included)
-#		(D) Files used in both the JNI-only and full-with-source version
-#		(E) Files used in just the full-with-source version
-#
-#   Each NDK version is created by combining the appropriate trees:
-#
-#            (A)   (B)  (C)  (D)  (E)
-#       (1)  yes   yes       yes  yes
-#       (2)  yes   yes  yes
-#       (3)  yes             yes
-#
-# Source is provided for partners who want to recompile our libraries for optimization.
-# The JNI-only version is provided for partners that want to create shared
-# libraries that can be packaged with APK files and called from Java code.
-
-LOCAL_PATH := $(call my-dir)
-
-# Source trees for the ndk
-samples_src_dir := $(LOCAL_PATH)/samples
-sample_src_dir := $(samples_src_dir)/sample
-samplejni_src_dir := $(samples_src_dir)/samplejni
-config_src_dir := $(LOCAL_PATH)/config
-kernel_common_src_dir := $(KERNEL_HEADERS_COMMON)
-kernel_arch_src_dir := $(KERNEL_HEADERS_ARCH)
-bionic_src_dir := bionic
-jni_src_dir := $(JNI_H_INCLUDE)
-
-# Workspace directory
-ndk_intermediates := $(call intermediates-dir-for,PACKAGING,ndk)
-
-# Common destination trees for the ndk
-ndk_common_tree := $(ndk_intermediates)/common
-ndk_common_dest_dir := $(ndk_common_tree)/ndk
-samplejni_dest_dir := $(ndk_common_dest_dir)/samples/samplejni
-config_dest_dir := $(ndk_common_dest_dir)/config
-kernel_dest_dir := $(ndk_common_dest_dir)/include/kernel/include
-gcc_dest_dir := $(ndk_common_dest_dir)/toolchain
-jni_dest_dir := $(ndk_common_dest_dir)/include/nativehelper
-
-# Common-full destination trees for the ndk
-ndk_common_full_tree := $(ndk_intermediates)/common_full
-ndk_common_full_dest_dir := $(ndk_common_full_tree)/ndk
-sample_dest_dir := $(ndk_common_full_dest_dir)/samples/sample
-
-# Destination trees without source for the standard ndk (without source)
-ndk_no_src_tree := $(ndk_intermediates)/no_src
-ndk_no_src_dest_dir := $(ndk_no_src_tree)/ndk
-bionic_no_src_dest_dir := $(ndk_no_src_dest_dir)/include/bionic
-
-# Destination trees including source for the ndk with source
-ndk_src_tree := $(ndk_intermediates)/with_src
-ndk_src_dest_dir := $(ndk_src_tree)/ndk
-bionic_src_dest_dir := $(ndk_src_dest_dir)/include/bionic
-
-# Destinations of all common files (not picked up by tree rules below)
-ndk_common_dest_files := $(ndk_common_dest_dir)/Android_NDK_README.html \
-		$(ndk_common_dest_dir)/config/armelf.x \
-		$(ndk_common_dest_dir)/config/armelflib.x \
-		$(ndk_common_dest_dir)/lib/crtbegin_dynamic.o \
-		$(ndk_common_dest_dir)/lib/crtend_android.o \
-		$(ndk_common_dest_dir)/lib/libc.so \
-		$(ndk_common_dest_dir)/lib/libm.so 
-    
-# Destinations of files used by the full, non-jni-only configurations
-ndk_common_full_dest_files := \
-		$(ndk_common_full_dest_dir)/lib/libdl.so \
-		$(ndk_common_full_dest_dir)/lib/libstdc++.so
-
-# Install common files outside common trees
-$(ndk_common_dest_dir)/Android_NDK_README.html: $(LOCAL_PATH)/Android_NDK_README.html | $(ACP)
-	@echo "NDK Android_NDK_README.html: from $? to $@"
-	$(copy-file-to-target)
-
-$(ndk_common_dest_dir)/config/armelf.x: $(BUILD_SYSTEM)/armelf.x | $(ACP)
-	@echo "NDK config: $@"
-	$(copy-file-to-target)
-
-$(ndk_common_dest_dir)/config/armelflib.x: $(BUILD_SYSTEM)/armelflib.x | $(ACP)
-	@echo "NDK config: $@"
-	$(copy-file-to-target)
-
-$(ndk_common_dest_dir)/lib/%: $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/% | $(ACP)
-	@echo "NDK lib: $@"
-	$(copy-file-to-target)
-
-# Install common_full files outside common trees
-$(ndk_common_full_dest_dir)/lib/%: $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/% | $(ACP)
-	@echo "NDK lib full: $@"
-	$(copy-file-to-target)
-
-# Install files in common trees
-listvar := ndk_common_dest_files
-$(call define-tree-copy-rules,$(samplejni_src_dir),$(samplejni_dest_dir),$(listvar))
-$(call define-tree-copy-rules,$(config_src_dir),$(config_dest_dir),$(listvar))
-$(call define-tree-copy-rules,$(kernel_common_src_dir),$(kernel_dest_dir),$(listvar))
-$(call define-tree-copy-rules,$(kernel_arch_src_dir),$(kernel_dest_dir),$(listvar))
-$(call define-tree-copy-rules,$(jni_src_dir),$(jni_dest_dir),$(listvar), -name jni.h)
-
-# Install files common to the full builds but not the JNI build
-listvar := ndk_common_full_dest_files
-$(call define-tree-copy-rules,$(sample_src_dir),$(sample_dest_dir),$(listvar))
-
-# Install files without sources
-listvar := ndk_no_src_dest_files
-$(call define-tree-copy-rules,$(bionic_src_dir),$(bionic_no_src_dest_dir),$(listvar),-name '*.h')
-
-# Install files including sources
-listvar := ndk_with_src_dest_files
-$(call define-tree-copy-rules,$(bionic_src_dir),$(bionic_src_dest_dir),$(listvar))
-
-
-#-------------------------------------------------------------------------------
-# Create the multiple versions of the ndk:
-# ndk_no_src           all files without source
-# ndk_with_source      all files with source
-# ndk_jni_with_source  just files for building JNI shared libraries with source.
-
-# Name the tar files
-name := android_ndk-$(TARGET_PRODUCT)
-ifeq ($(TARGET_BUILD_TYPE),debug)
-  name := $(name)_debug
-endif
-name := $(name)-$(BUILD_NUMBER)
-ndk_tarfile := $(ndk_intermediates)/$(name).tar
-ndk_tarfile_zipped := $(ndk_tarfile).gz
-ndk_with_src_tarfile := $(ndk_intermediates)/$(name)-src.tar
-ndk_with_src_tarfile_zipped := $(ndk_with_src_tarfile).gz
-ndk_jni_with_src_tarfile := $(ndk_intermediates)/$(name)-jni-src.tar
-ndk_jni_with_src_tarfile_zipped := $(ndk_jni_with_src_tarfile).gz
-
-.PHONY: ndk ndk_with_src ndk_no_src ndk_jni_with_src ndk_debug
-
-ndk: ndk_no_src ndk_with_src ndk_jni_with_src
-ndk_no_src: $(ndk_tarfile_zipped)
-ndk_with_src: $(ndk_with_src_tarfile_zipped)
-ndk_jni_with_src: $(ndk_jni_with_src_tarfile_zipped)
-
-# Put the ndk zip files in the distribution directory
-$(call dist-for-goals,ndk,$(ndk_tarfile_zipped))
-$(call dist-for-goals,ndk,$(ndk_with_src_tarfile_zipped))
-$(call dist-for-goals,ndk,$(ndk_jni_with_src_tarfile_zipped))
-
-# zip up tar files
-%.tar.gz: %.tar
-	@echo "NDK: zipped $<"
-	$(hide) gzip -cf $< > $@
-
-# tar up the files without our sources to make the ndk.
-$(ndk_tarfile): $(ndk_common_dest_files) $(ndk_common_full_dest_files) $(ndk_no_src_dest_files)
-	@echo "NDK: $@"
-	@mkdir -p $(dir $@)
-	@rm -f $@
-	$(hide) tar rf $@ -C $(ndk_common_tree) ndk
-	$(hide) tar rf $@ -C $(ndk_common_full_tree) ndk
-	$(hide) tar rf $@ -C $(ndk_no_src_tree) ndk
-
-# tar up the full sources to make the ndk with sources.
-$(ndk_with_src_tarfile): $(ndk_common_dest_files) $(ndk_common_full_dest_files) $(ndk_with_src_dest_files) $(ndk_full_with_src_dest_files)
-	@echo "NDK: $@"
-	@mkdir -p $(dir $@)
-	@rm -f $@
-	$(hide) tar rf $@ -C $(ndk_common_tree) ndk
-	$(hide) tar rf $@ -C $(ndk_common_full_tree) ndk
-	$(hide) tar rf $@ -C $(ndk_src_tree) ndk
-	
-# tar up the sources to make the ndk with JNI support.
-$(ndk_jni_with_src_tarfile): $(ndk_common_dest_files) $(ndk_with_src_dest_files)
-	@echo "NDK: $@"
-	@mkdir -p $(dir $@)
-	@rm -f $@
-	$(hide) tar rf $@ -C $(ndk_common_tree) ndk
-	$(hide) tar rf $@ -C $(ndk_src_tree) ndk
-
-# Debugging reporting can go here, add it as a target to get output.
-ndk_debug: ndk
-	@echo "You are here: $@"
-	@echo "ndk tar file:          $(ndk_tarfile_zipped)"
-	@echo "ndk_with_src tar file: $(ndk_with_src_tarfile_zipped)"
-	@echo "ndk_jni_with_src tar file: $(ndk_jni_with_src_tarfile_zipped)"
-	@echo "ndk_files:             $(ndk_no_src_dest_files)"
-	@echo "ndk_with_src files:    $(ndk_with_src_dest_files)"
-	@echo "ndk_full_with_src files:    $(ndk_full_with_src_dest_files)"
-	@echo "ndk_common_files:      $(ndk_common_dest_files)"
-	@echo "ndk_common_full_dest_files:      $(ndk_common_full_dest_files)"
-
diff --git a/pdk/ndk/config/config.mk b/pdk/ndk/config/config.mk
deleted file mode 100644
index a6972b1..0000000
--- a/pdk/ndk/config/config.mk
+++ /dev/null
@@ -1,29 +0,0 @@
-# Assumes PREBUILT is defined to point to the correct flavor of the prebuilt 
-# directory in the Android source tree
-
-CC  := $(PREBUILT)/toolchain/arm-eabi-4.2.1/bin/arm-eabi-gcc
-AR  := $(PREBUILT)/toolchain/arm-eabi-4.2.1/bin/arm-eabi-ar
-
-INC   := -I$(NDK_BASE)/include/bionic/libc/arch-arm/include \
-         -I$(NDK_BASE)/include/kernel/include \
-         -I$(NDK_BASE)/include/bionic/libm/include \
-         -I$(NDK_BASE)/include/bionic/libm/include/arm \
-         -I$(NDK_BASE)/include/bionic/libc/include \
-         -I$(NDK_BASE)/include/bionic/libstdc++/include
-
-LINK       := -nostdlib -Bdynamic \
-     -Wl,-T,$(NDK_BASE)/config/armelf.x \
-     -Wl,-dynamic-linker,/system/bin/linker \
-     -Wl,-z,nocopyreloc \
-     -L$(NDK_BASE)/lib \
-     -Wl,-rpath-link=$(NDK_BASE)/lib \
-    $(NDK_BASE)/lib/crtbegin_dynamic.o
-
-POSTLINK := $(NDK_BASE)/lib/crtend_android.o
-
-%.o: %.cpp
-	$(CC) $(CFLAGS) -fno-exceptions -fno-rtti $(INC) -o $@ -c $< 
-  
-%.o: %.c
-	$(CC) $(CFLAGS) $(INC) -o $@ -c $< 
-  
diff --git a/pdk/ndk/samples/sample/Makefile b/pdk/ndk/samples/sample/Makefile
deleted file mode 100644
index a66ae86..0000000
--- a/pdk/ndk/samples/sample/Makefile
+++ /dev/null
@@ -1,21 +0,0 @@
-
-NDK_BASE   := ../..
-
-include $(NDK_BASE)/config/config.mk
-
-EXECUTABLE := hello
-SOURCES    := hello.c
-OBJECTS    := $(SOURCES:.c=.o)
-LIBS       := -lc -lm
-
-all: $(EXECUTABLE)
-
-# need $(LINK) before all objects and $(POSTLINK) after all objects for 
-# android runtime setup.
-
-hello: $(OBJECTS)
-	$(CC) $(LINK) -o $@ $(OBJECTS) $(LIBS) $(POSTLINK)
-
-clean:
-	rm -rf *.o hello
-
diff --git a/pdk/ndk/samples/sample/Makefile.hello_cpp b/pdk/ndk/samples/sample/Makefile.hello_cpp
deleted file mode 100644
index 5d82b66..0000000
--- a/pdk/ndk/samples/sample/Makefile.hello_cpp
+++ /dev/null
@@ -1,21 +0,0 @@
-
-NDK_BASE   := ../..
-
-include $(NDK_BASE)/config/config.mk
-
-EXECUTABLE := hello_cpp
-SOURCES    := hello_cpp.cpp
-OBJECTS    := $(SOURCES:.cpp=.o)
-LIBS       := -lc -lm -lstdc++
-
-all: $(EXECUTABLE)
-
-# need $(LINK) before all objects and $(POSTLINK) after all objects for 
-# android runtime setup.
-
-hello_cpp: $(OBJECTS)
-	$(CC) $(LINK) -o $@ $(OBJECTS) $(LIBS) $(POSTLINK)
-
-clean:
-	rm -rf *.o hello_cpp
-
diff --git a/pdk/ndk/samples/sample/Makefile.lib b/pdk/ndk/samples/sample/Makefile.lib
deleted file mode 100644
index fbb5a14..0000000
--- a/pdk/ndk/samples/sample/Makefile.lib
+++ /dev/null
@@ -1,31 +0,0 @@
-
-NDK_BASE   := ../..
-
-include $(NDK_BASE)/config/config.mk
-
-# Assumes PREBUILT is defined to point to the correct flavor of the prebuilt 
-# directory in the Android source tree
-
-SOURCES    := hellolibrary.c
-OBJECTS    := $(SOURCES:.c=.o)
-LIBS       := -lc -lm
-ALIB       := $(PREBUILT)/toolchain/arm-eabi-4.2.1/lib/gcc/arm-eabi/4.2.1/interwork/libgcc.a
-
-all: sharedlib staticlib
-
-# Using shared and static suffixes as these are going in the same directory;
-# typically you would not do this as you would make only one version,
-# but if we don't we'll screw up the linking because of linker defaults.
-
-staticlib: $(OBJECTS)
-	$(AR) -cr libhello-static.a $(OBJECTS) 
-	
-sharedlib: hellolibrary-shared.o
-	$(CC) -nostdlib -Wl,-soname,libhello-shared.so -Wl,-shared,-Bsymbolic -L$(NDK_BASE)/lib $^ $(LIBS) -o libhello-shared.so -Wl,--no-undefined $(ALIB)
-	
-hellolibrary-shared.o: hellolibrary.c
-	$(CC) -c -fpic $(INC) -o $@ $^ 
-
-clean:
-	rm -rf *.o libhello-static.a libhello-shared.so
-					                                            
diff --git a/pdk/ndk/samples/sample/Makefile.uselib b/pdk/ndk/samples/sample/Makefile.uselib
deleted file mode 100644
index b44eae2e..0000000
--- a/pdk/ndk/samples/sample/Makefile.uselib
+++ /dev/null
@@ -1,23 +0,0 @@
-
-NDK_BASE   := ../..
-
-include $(NDK_BASE)/config/config.mk
-
-SOURCES    := use_hellolibrary.c
-OBJECTS    := $(SOURCES:.c=.o)
-LIBS       := -lc -lm 
-
-all: use_hellolibrary-a use_hellolibrary-so
-
-# need $(LINK) before all objects and $(POSTLINK) after all objects for 
-# android runtime setup.
-
-use_hellolibrary-a: $(OBJECTS)
-	$(CC) $(LINK) -o $@ $(OBJECTS) $(LIBS) -L. -lhello-static $(POSTLINK)
-
-use_hellolibrary-so: $(OBJECTS)
-	$(CC) $(LINK) -o $@ $(OBJECTS) $(LIBS) -L. -lhello-shared $(POSTLINK)
-
-clean:
-	rm -rf *.o use_hellolibrary-a use_hellolibrary-so
-
diff --git a/pdk/ndk/samples/sample/README b/pdk/ndk/samples/sample/README
deleted file mode 100644
index 64e99de..0000000
--- a/pdk/ndk/samples/sample/README
+++ /dev/null
@@ -1,135 +0,0 @@
-Building native code applications and libraries
-
-STEP 1
-Building an application.
---------
-
-0) set the environment variable PREBUILT to point to the Android prebuilt directory
-  export PREBUILT=<path_to_android_src>/prebuilt/<platform>
-
-where you type in the actual path to the android source in place of <path_to_android_src>
-and the platform you are using instead of <platform>: either linux-x86 or darwin-x86
-
-1) Test the ndk install by building the hello world sample application:
-
-  cd <your_ndk_base>/samples/sample
-  make clean
-  make
-
-The sample application uses hello.c to construct the hello binary,  which you 
-can load and run on the ARM device. To achieve proper runtime behavior, verify
-that:
-  * crtbegin_dynamic.o is the first linked object file
-  * crtend_android.o is last linked object.
-Both are set by the config.mk file in ndk/config.
-
-2) Test that this works correctly by attaching your ARM-based device to the USB 
-port and installing the application (hello) you just made by (in the commands
-below # is the ARM device's shell prompt):
-
-NOTE: need a development build so remount opens system permissions
-
-  adb remount
-  adb push hello system/app
-  adb shell
-  # cd system/app
-  # ./hello
-  Hello from the NDK; no user libraries.
-  # exit
-
-3) You may also build the c++ binary hello_cpp.cpp into an application:
-
-  make -f Makefile.hello_cpp clean
-  make -f Makefile.hello_cpp hello_cpp
-
-This uses the hello_cpp.cpp and hello_cpp.h files to construct the hello_cpp 
-binary application, which you can load and run on the ARM device.  Note that
-we do not provide for C++ exceptions thus you must use the -fno-exceptions flag
-when compiling.
-
-  adb push hello_cpp system/app
-  adb shell
-  # cd system/app
-  # ./hello_cpp
-  C++ example printing message: Hello world!
-  # exit
-
-
-STEP 2
-Building and using a library 
--------
-
-Makefile.lib in ndk/sample shows how to make either a shared library or a 
-static library from the hellolibrary.c source.  The example makes the libraries
-libhello-shared.so and libhello-static.a .
-
-Makefile.uselib then shows how to make an application that links against either
-a shared or a static library.  They examples shows how to build the two
-applications use_hellolibrary-so and use-hellolibrary-a from the source
-use_hellolibrary.c.
-
-1) To make a shared library and an application that uses it:
-
-  make -f Makefile.lib clean
-  make -f Makefile.lib sharedlib
-  make -f Makefile.uselib clean
-  make -f Makefile.uselib use_hellolibrary-so
-
-2) Copy the shared library libhello-shared.so to /system/lib (or the location 
-in which shared libraries are found by the kernel on your ARM-based device.) 
-
-  adb push libhello-shared.so system/lib
- 
-You would not typically use the -shared or -static extensions in the filename, 
-but the distinction is important in the case where a static and shared library 
-are made in the same directory. Giving the files different names allows you to 
-override the link defaults that default to a static library of the same name.
-
-3) The application, use_hellolibrary-so, can now be tested by loading and 
-running on the ARM device. 
-
-  adb push use_hellolibrary-so /system/app
-  adb shell
-  # cd system/app
-  # ./use_hellolibrary-so
-  Library printing message: Hello from the NDK.
-  # exit
-
-4) To make a static library:
-
-  make -f Makefile.lib clean
-  make -f Makefile.lib staticlib
-  make -f Makefile.uselib clean
-  make -f Makefile.uselib use_hellolibrary-a
-
-5) Test the application use_hellolibrary-a by loading and running it on the ARM
-device.
-
-  adb push use_hellolibrary-a system/app
-  adb shell
-  # cd system/app
-  # ./use_hellolibrary-a
-  Library printing message: Hello from the NDK.
-  # exit
-
-
-SUMMARY:
----------
-
-To make everything execute the following:
-
-make clean
-make
-make -f Makefile.lib clean
-make -f Makefile.lib
-make -f Makefile.uselib clean
-make -f Makefile.uselib
-make -f Makefile.hello_cpp clean
-make -f Makefile.hello_cpp hello_cpp
-
-
-You should have:
-	* The libraries libhello-static.a and libhello-shared.so built, the latter
-			ready for installation,
-	* The applications hello, use_hellolibrary-a, and use_hellolibrary-so 
-			available for installation on the ARM device.
diff --git a/pdk/ndk/samples/sample/hello.c b/pdk/ndk/samples/sample/hello.c
deleted file mode 100644
index b7d750f..0000000
--- a/pdk/ndk/samples/sample/hello.c
+++ /dev/null
@@ -1,7 +0,0 @@
-#include <stdio.h>
-
-int main(int argc, char *argv[])
-{
-  printf("Hello from the NDK; no user libraries.\n");
-  return 0;
-}
diff --git a/pdk/ndk/samples/sample/hello_cpp.cpp b/pdk/ndk/samples/sample/hello_cpp.cpp
deleted file mode 100644
index c0a157a..0000000
--- a/pdk/ndk/samples/sample/hello_cpp.cpp
+++ /dev/null
@@ -1,22 +0,0 @@
-#include <stdio.h>
-#include "hello_cpp.h"
-
-Hello::Hello()
-{
-}
-
-Hello::~Hello()
-{
-}
-
-void Hello::printMessage(char* msg)
-{
-  printf("C++ example printing message: %s", msg);
-}
-
-int main(void)
-{
-  Hello hello_obj;
-  hello_obj.printMessage("Hello world!\n");
-  return 0;
-}
diff --git a/pdk/ndk/samples/sample/hello_cpp.h b/pdk/ndk/samples/sample/hello_cpp.h
deleted file mode 100644
index b98ae7f..0000000
--- a/pdk/ndk/samples/sample/hello_cpp.h
+++ /dev/null
@@ -1,12 +0,0 @@
-#ifndef HELLO_CPP_H
-#define HELLO_CPP_H
-
-class Hello
-{
-public:
-    Hello();
-    ~Hello();
-    void printMessage(char* msg);
-};
-
-#endif
diff --git a/pdk/ndk/samples/sample/hellolibrary.c b/pdk/ndk/samples/sample/hellolibrary.c
deleted file mode 100644
index 90f98fa..0000000
--- a/pdk/ndk/samples/sample/hellolibrary.c
+++ /dev/null
@@ -1,10 +0,0 @@
-/* hellolibrary.c - demonstrate library use with the NDK. 
- * This will be the library that gets called as wither a static or shared lib.*/
-
-#include <stdio.h>
-
-int hellolibrary(char *msg)
-{
-  printf("Library printing message: %s", msg);
-  return 0;
-}
diff --git a/pdk/ndk/samples/sample/use_hellolibrary.c b/pdk/ndk/samples/sample/use_hellolibrary.c
deleted file mode 100644
index e32a364..0000000
--- a/pdk/ndk/samples/sample/use_hellolibrary.c
+++ /dev/null
@@ -1,9 +0,0 @@
-/* use_hellolibrary.c -- used to show how to link to the hellolibrary */
-
-int hellolibrary(char *msg);
-
-int main()
-{
-  hellolibrary("Hello from the NDK.\n");
-  return 0;
-}
diff --git a/pdk/ndk/samples/samplejni/AndroidManifest.xml b/pdk/ndk/samples/samplejni/AndroidManifest.xml
deleted file mode 100644
index 450eb0b..0000000
--- a/pdk/ndk/samples/samplejni/AndroidManifest.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-      package="com.example.jniexample"
-      android:versionCode="1"
-      android:versionName="1.0.0">
-    <application android:icon="@drawable/icon" android:label="@string/app_name">
-        <activity android:name=".JNIExample"
-                  android:label="@string/app_name">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest> 
\ No newline at end of file
diff --git a/pdk/ndk/samples/samplejni/Makefile b/pdk/ndk/samples/samplejni/Makefile
deleted file mode 100644
index 18e97df..0000000
--- a/pdk/ndk/samples/samplejni/Makefile
+++ /dev/null
@@ -1,45 +0,0 @@
-# Package a shared library into an APK
-
-NDK_BASE   := ../..
-
-# Assume ANDROID_SDK_BASE is defined to point to the base of the Android SDK
-# Assumes PREBUILT is defined to point to the prebuilt directory of the Android source
-
-include $(NDK_BASE)/config/config.mk
-
-SOURCES    := native.cpp
-OBJECTS    := $(SOURCES:.cpp=.o)
-LIBS       := -lc -lm
-ALIB       := $(PREBUILT)/toolchain/arm-eabi-4.2.1/lib/gcc/arm-eabi/4.2.1/interwork/libgcc.a
-
-APKBUILDER := $(ANDROID_SDK_BASE)/tools/apkbuilder
-
-APK_INPUT_DIR := bin
-APK_OUTPUT_DIR := bin/full
-
-APK_NAME   := JNIExample.apk
-INPUT_APK  := $(APK_INPUT_DIR)/$(APK_NAME)
-OUTPUT_APK := $(APK_OUTPUT_DIR)/$(APK_NAME)
-APK_STAGE  := $(APK_OUTPUT_DIR)/temp
-
-JNI_LIBS := libnative.so
-
-all: $(OUTPUT_APK)
-
-$(OUTPUT_APK) : $(INPUT_APK) $(JNI_LIBS)
-	rm -rf $(APK_STAGE)
-	mkdir -p $(APK_STAGE)
-	unzip $(INPUT_APK) -d $(APK_STAGE)
-	mkdir -p $(APK_STAGE)/lib/armeabi
-	cp $(JNI_LIBS) $(APK_STAGE)/lib/armeabi
-	$(APKBUILDER) $(OUTPUT_APK) -v -rf $(APK_STAGE)
-	rm -rf $(APK_STAGE)
-
-libnative.so: native.o
-	$(CC) -nostdlib -Wl,-soname,libhello-shared.so -Wl,-shared,-Bsymbolic -L$(NDK_BASE)/lib $^ $(LIBS) -o $@ -Wl,--no-undefined $(ALIB)
-	
-native.o: native.cpp
-	$(CC) -c -fpic $(INC) -I$(NDK_BASE)/include/nativehelper -o $@ $^ 
-
-clean:
-	rm -rf *.o libnative.so $(APK_OUTPUT_DIR)
diff --git a/pdk/ndk/samples/samplejni/README b/pdk/ndk/samples/samplejni/README
deleted file mode 100644
index a821b7b..0000000
--- a/pdk/ndk/samples/samplejni/README
+++ /dev/null
@@ -1,43 +0,0 @@
-JNI Example
-
-This sample shows how to build a native code library, package it into an APK, and call it using JNI.
-
-Prerequesites
-
-You must install the Android SDK in order to build the Java APK. The Android SDK can be downloaded
-from
-
-http://code.google.com/android/download.html
-
-Build Steps:
-
-1) Create an Eclipse project to for the Java code.
-
-	Launch Eclipse
-	Choose File : New : Project...
-	Choose Android : Android Project
-	Choose Next
-	Enter "JNIExample" into the Project name: field.
-	Choose "Create project from existing source"
-	Click the Browse button and browse to the ndk/samplejni directory
-	
-	Click Finish
-
-2) Build the Eclipse Project
-
-	Select the JNIExample project in the Package Explorer
-	Make sure that the menu item Project:Build Automatically is not checked.
-	Choose Project:Build
-
-    The resulting apk file ends up in bin/full/JNIExample.apk
-
-2) Build the shared library, insert the shared library into the APK file and resign the
-    shared library.
-
-    ANDROID_SDK_BASE=<directory where SDK is installed> make
-
-Install the APK on the device:
-
-	adb install -r bin/full/JNIExample.apk
-
-Once the application is installed, you can run it by tapping on the "JNI Example" icon.
diff --git a/pdk/ndk/samples/samplejni/native.cpp b/pdk/ndk/samples/samplejni/native.cpp
deleted file mode 100644
index 2e5fa4d..0000000
--- a/pdk/ndk/samples/samplejni/native.cpp
+++ /dev/null
@@ -1,85 +0,0 @@
-#include <jni.h>
-#include <stdio.h>
-
-static jint
-add(JNIEnv *env, jobject thiz, jint a, jint b) {
-int result = a + b;
-    printf("%d + %d = %d", a, b, result);
-    return result;
-}
-
-static const char *classPathName = "com/example/jniexample/Native";
-
-static JNINativeMethod methods[] = {
-  {"add", "(II)I", (void*)add },
-};
-
-/*
- * Register several native methods for one class.
- */
-static int registerNativeMethods(JNIEnv* env, const char* className,
-    JNINativeMethod* gMethods, int numMethods)
-{
-    jclass clazz;
-
-    clazz = env->FindClass(className);
-    if (clazz == NULL) {
-        fprintf(stderr, "Native registration unable to find class '%s'", className);
-        return JNI_FALSE;
-    }
-    if (env->RegisterNatives(clazz, gMethods, numMethods) < 0) {
-        fprintf(stderr, "RegisterNatives failed for '%s'", className);
-        return JNI_FALSE;
-    }
-
-    return JNI_TRUE;
-}
-
-/*
- * Register native methods for all classes we know about.
- */
-static int registerNatives(JNIEnv* env)
-{
-  if (!registerNativeMethods(env, classPathName,
-                 methods, sizeof(methods) / sizeof(methods[0]))) {
-    return JNI_FALSE;
-  }
-
-  return JNI_TRUE;
-}
-
-/*
- * Set some test stuff up.
- *
- * Returns the JNI version on success, -1 on failure.
- */
-
-typedef union {
-    JNIEnv* env;
-    void* venv;
-} UnionJNIEnvToVoid;
-
-jint JNI_OnLoad(JavaVM* vm, void* reserved)
-{
-    UnionJNIEnvToVoid uenv;
-    uenv.venv = NULL;
-    jint result = -1;
-    JNIEnv* env = NULL;
-    
-    printf("JNI_OnLoad");
-
-    if (vm->GetEnv(&uenv.venv, JNI_VERSION_1_4) != JNI_OK) {
-        fprintf(stderr, "GetEnv failed");
-        goto bail;
-    }
-    env = uenv.env;
-
-    if (!registerNatives(env)) {
-        fprintf(stderr, "registerNatives failed");
-    }
-    
-    result = JNI_VERSION_1_4;
-    
-bail:
-    return result;
-}
diff --git a/pdk/ndk/samples/samplejni/res/drawable/icon.png b/pdk/ndk/samples/samplejni/res/drawable/icon.png
deleted file mode 100644
index 7502484..0000000
--- a/pdk/ndk/samples/samplejni/res/drawable/icon.png
+++ /dev/null
Binary files differ
diff --git a/pdk/ndk/samples/samplejni/res/values/strings.xml b/pdk/ndk/samples/samplejni/res/values/strings.xml
deleted file mode 100644
index a647beb..0000000
--- a/pdk/ndk/samples/samplejni/res/values/strings.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
-    <string name="app_name">JNI Example</string>
-</resources>
diff --git a/pdk/ndk/samples/samplejni/src/com/example/jniexample/JNIExample.java b/pdk/ndk/samples/samplejni/src/com/example/jniexample/JNIExample.java
deleted file mode 100644
index 315ee21..0000000
--- a/pdk/ndk/samples/samplejni/src/com/example/jniexample/JNIExample.java
+++ /dev/null
@@ -1,25 +0,0 @@
-package com.example.jniexample;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.TextView;
-
-public class JNIExample extends Activity {
-    /** Called when the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        TextView tv = new TextView(this);
-        int sum = Native.add(2, 3);
-        tv.setText("Native Code test: 2 + 3 = " + Integer.toString(sum));
-        setContentView(tv);
-    }
-}
-
-class Native {
-    static {
-        System.loadLibrary("native");
-    }
-
-    static native int add(int a, int b);
-}
diff --git a/pdk/sample/partner/company/mychipset/libaudio/Android.mk.stub b/pdk/sample/partner/company/mychipset/libaudio/Android.mk.stub
deleted file mode 100644
index d7c7524..0000000
--- a/pdk/sample/partner/company/mychipset/libaudio/Android.mk.stub
+++ /dev/null
@@ -1,20 +0,0 @@
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := libaudio
-
-LOCAL_SHARED_LIBRARIES := \
-    libcutils \
-    libutils \
-    libmedia \
-    libhardware
-
-LOCAL_SRC_FILES += MyAudioHardware.cpp
-
-LOCAL_CFLAGS +=
-
-LOCAL_C_INCLUDES +=
-
-LOCAL_STATIC_LIBRARIES += libaudiointerface
-
-include $(BUILD_SHARED_LIBRARY)
diff --git a/pdk/sample/partner/company/mychipset/libcamera/Android.mk.stub b/pdk/sample/partner/company/mychipset/libcamera/Android.mk.stub
deleted file mode 100755
index 29ec868..0000000
--- a/pdk/sample/partner/company/mychipset/libcamera/Android.mk.stub
+++ /dev/null
@@ -1,15 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES:= MyCameraHardware.cpp
-
-LOCAL_STATIC_LIBRARIES:= \
-	libcamera-common
- 
-LOCAL_SHARED_LIBRARIES:= libutils liblog
-
-LOCAL_MODULE:= libcamera
-
-include $(BUILD_SHARED_LIBRARY)
-
diff --git a/pdk/sample/partner/wifi_company/mychipset/Android.mk.stub b/pdk/sample/partner/wifi_company/mychipset/Android.mk.stub
deleted file mode 100644
index 2964d28..0000000
--- a/pdk/sample/partner/wifi_company/mychipset/Android.mk.stub
+++ /dev/null
@@ -1,53 +0,0 @@
-# Install firmware file for WiFi
-#
-#
-# where to install the file on the device
-#
-
-local_target_dir := $(TARGET_OUT_ETC)/wifi
-
-########################
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := MyFirmwareFile.bin
-
-LOCAL_MODULE_TAGS := user development
-
-LOCAL_MODULE_CLASS := ETC
-LOCAL_MODULE_PATH := $(local_target_dir)
-
-LOCAL_SRC_FILES := $(LOCAL_MODULE)
-
-include $(BUILD_PREBUILT)
-
-########################
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := MyFirmwareConfigFile.ini
-
-LOCAL_MODULE_TAGS := user development
-
-LOCAL_MODULE_CLASS := ETC
-LOCAL_MODULE_PATH := $(local_target_dir)
-
-LOCAL_SRC_FILES := $(LOCAL_MODULE)
-
-include $(BUILD_PREBUILT)
-
-########################
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := wlan.ko
-
-LOCAL_MODULE_TAGS := user development
-
-LOCAL_MODULE_CLASS := ETC
-LOCAL_MODULE_PATH := $(TARGET_OUT)/lib/modules
-
-LOCAL_SRC_FILES := $(LOCAL_MODULE)
-
-include $(BUILD_PREBUILT)
-
-########################
-
diff --git a/samples/AliasActivity/Android.mk b/samples/AliasActivity/Android.mk
deleted file mode 100644
index a34e1bf..0000000
--- a/samples/AliasActivity/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := AliasActivity
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
diff --git a/samples/AliasActivity/AndroidManifest.xml b/samples/AliasActivity/AndroidManifest.xml
deleted file mode 100644
index 33ad326..0000000
--- a/samples/AliasActivity/AndroidManifest.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.aliasactivity">
-    <application android:hasCode="false">
-        <activity android:name="android.app.AliasActivity" android:label="@string/app_label">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.LAUNCHER"/>
-            </intent-filter>
-            <meta-data android:name="android.app.alias"
-                    android:resource="@xml/alias" />
-        </activity>
-    </application>
-</manifest>
diff --git a/samples/AliasActivity/res/values/strings.xml b/samples/AliasActivity/res/values/strings.xml
deleted file mode 100644
index dd746e3..0000000
--- a/samples/AliasActivity/res/values/strings.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <string name="app_label">An Alias</string>
-</resources>
diff --git a/samples/AliasActivity/res/xml/alias.xml b/samples/AliasActivity/res/xml/alias.xml
deleted file mode 100644
index 3946333..0000000
--- a/samples/AliasActivity/res/xml/alias.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alias xmlns:android="http://schemas.android.com/apk/res/android">
-    <intent android:action="android.intent.action.VIEW"
-        android:data="http://www.google.com/">
-    </intent>
-</alias>
diff --git a/samples/ApiDemos/Android.mk b/samples/ApiDemos/Android.mk
deleted file mode 100644
index 5019c2f..0000000
--- a/samples/ApiDemos/Android.mk
+++ /dev/null
@@ -1,20 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples development
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-LOCAL_SRC_FILES += \
-        src/com/example/android/apis/app/IRemoteService.aidl \
-        src/com/example/android/apis/app/IRemoteServiceCallback.aidl \
-        src/com/example/android/apis/app/ISecondary.aidl \
-
-LOCAL_PACKAGE_NAME := ApiDemos
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the folloing include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/ApiDemos/AndroidManifest.xml b/samples/ApiDemos/AndroidManifest.xml
deleted file mode 100644
index afcfbc8..0000000
--- a/samples/ApiDemos/AndroidManifest.xml
+++ /dev/null
@@ -1,1705 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.apis">
-
-    <uses-permission android:name="android.permission.READ_CONTACTS" />
-    <uses-permission android:name="android.permission.WRITE_CONTACTS" />
-    <uses-permission android:name="android.permission.CAMERA" />
-    <uses-permission android:name="android.permission.VIBRATE" />
-    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
-    <uses-permission android:name="android.permission.INTERNET" />
-
-    <application android:name="ApiDemosApplication"
-            android:label="@string/activity_sample_code"
-            android:icon="@drawable/app_sample_code" >
-
-        <uses-library android:name="com.google.android.maps" />
-
-        <activity android:name="ApiDemos">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--      APPLICATION PACKAGE SAMPLES      -->
-        <!-- ************************************* -->
-
-        <!-- Activity Samples -->
-
-        <activity android:name=".app.HelloWorld" android:label="@string/activity_hello_world">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.DialogActivity"
-                android:label="@string/activity_dialog"
-                android:theme="@android:style/Theme.Dialog">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.CustomDialogActivity"
-                android:label="@string/activity_custom_dialog"
-                android:theme="@style/Theme.CustomDialog">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.TranslucentActivity"
-                android:label="@string/activity_translucent"
-                android:theme="@style/Theme.Translucent">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.TranslucentBlurActivity"
-                android:label="@string/activity_translucent_blur"
-                android:theme="@style/Theme.Transparent">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.SaveRestoreState"
-                android:label="@string/activity_save_restore"
-                android:windowSoftInputMode="stateVisible|adjustResize">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.PersistentState"
-                android:label="@string/activity_persistent"
-                android:windowSoftInputMode="stateVisible|adjustResize">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.ReceiveResult" android:label="@string/activity_receive_result">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.SendResult">
-        </activity>
-
-        <activity android:name=".app.Forwarding" android:label="@string/activity_forwarding">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.ForwardTarget">
-        </activity>
-
-        <activity android:name=".app.RedirectEnter" android:label="@string/activity_redirect">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.RedirectMain">
-        </activity>
-
-        <activity android:name=".app.RedirectGetter">
-        </activity>
-
-        <activity android:name=".app.CustomTitle"
-                android:label="@string/activity_custom_title"
-                android:windowSoftInputMode="stateVisible|adjustPan">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.ReorderOnLaunch"
-                android:label="@string/activity_reorder">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".app.ReorderTwo" />
-        <activity android:name=".app.ReorderThree" />
-        <activity android:name=".app.ReorderFour" />
-        
-        <!-- Intent Samples -->
-
-        <activity android:name=".app.Intents" android:label="@string/activity_intents">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Service Samples -->
-
-        <service android:name=".app.LocalService" />
-
-        <activity android:name=".app.LocalServiceController" android:label="@string/activity_local_service_controller">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.LocalServiceBinding" android:label="@string/activity_local_service_binding">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <service android:name=".app.RemoteService" android:process=":remote">
-            <intent-filter>
-                <!-- These are the interfaces supported by the service, which
-                     you can bind to. -->
-                <action android:name="com.example.android.apis.app.IRemoteService" />
-                <action android:name="com.example.android.apis.app.ISecondary" />
-                <!-- This is an action code you can use to select the service
-                     without explicitly supplying the implementation class. -->
-                <action android:name="com.example.android.apis.app.REMOTE_SERVICE" />
-            </intent-filter>
-        </service>
-
-        <activity android:name=".app.RemoteServiceController" android:label="@string/activity_remote_service_controller">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.RemoteServiceBinding" android:label="@string/activity_remote_service_binding">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <service android:name=".app.ServiceStartArguments" />
-
-        <activity android:name=".app.ServiceStartArgumentsController" android:label="@string/activity_service_start_arguments_controller">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Alarm Samples -->
-
-        <receiver android:name=".app.OneShotAlarm" android:process=":remote" />
-
-        <receiver android:name=".app.RepeatingAlarm" android:process=":remote" />
-
-        <activity android:name=".app.AlarmController" android:label="@string/activity_alarm_controller">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <service android:name=".app.AlarmService_Service" android:process=":remote" />
-
-        <activity android:name=".app.AlarmService" android:label="@string/activity_alarm_service">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Instrumentation Samples -->
-
-        <activity android:name=".app.LocalSample" android:label="@string/activity_local_sample">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <!-- category android:name="android.intent.category.SAMPLE_CODE" /-->
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.ContactsFilter" android:label="@string/activity_contacts_filter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <!-- category android:name="android.intent.category.SAMPLE_CODE" /-->
-            </intent-filter>
-        </activity>
-
-
-        <!-- Notifications samples -->
-
-        <activity android:name=".app.NotifyWithText" android:label="App/Notification/NotifyWithText">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.IncomingMessage" android:label="App/Notification/IncomingMessage">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.IncomingMessageView" android:label="App/Notification/IncomingMessageView">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.EMBED" />
-            </intent-filter>
-        </activity>
-
-        <!-- This is used to display a notification selected by the user
-             from StatusBarNotifications.  Note the configuration here so
-             that the activity layers on top of whatever the user is doing,
-             allowing them to press back to return. -->
-        <activity android:name=".app.NotificationDisplay"
-                android:theme="@style/Theme.Transparent"
-                android:taskAffinity=""
-                android:excludeFromRecents="true"
-                android:noHistory="true">
-        </activity>
-
-        <activity android:name=".app.StatusBarNotifications"
-                android:label="App/Notification/Status Bar"
-                android:launchMode="singleTop">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <service android:name=".app.NotifyingService" />
-
-        <activity android:name=".app.NotifyingController" android:label="App/Notification/Notifying Service Controller">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Dialog samples -->
-        <activity android:name=".app.AlertDialogSamples" android:label="@string/activity_alert_dialog">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Search Samples -->
-
-        <!-- This activity represents a "typical" activity in your application from which the -->
-        <!-- user would be allowed to invoke a search function.  As noted below, the definition -->
-        <!-- of android.app.default_searchable is more typically handled at the application -->
-        <!-- level, where it can serve as a default for all of your activities. -->
-
-        <activity android:name=".app.SearchInvoke"
-                  android:label="@string/search_invoke">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-
-            <!-- This metadata entry causes .app.SearchQueryResults to be the default context -->
-            <!-- whenever the user invokes search while in this Activity. -->
-            <meta-data android:name="android.app.default_searchable"
-                       android:value=".app.SearchQueryResults" />
-            
-            <!-- This is not the typical way to define android.app.default_searchable, -->
-            <!-- and we show it here only because we wish to confine the search demo to this -->
-            <!-- section of the ApiDemos application. -->
-            
-            <!-- For typical applications, it's simpler to define android.app.default_searchable -->
-            <!-- just once, at the application level, where it serves as a default for all of -->
-            <!-- the Activities in your package. -->
-        </activity>
-
-        <!-- This activity represents the "search" activity in your application, in which -->
-        <!-- search results are gathered and displayed. -->
-
-        <activity android:name=".app.SearchQueryResults"
-                  android:label="@string/search_query_results">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-            
-            <!-- This intent-filter identifies this activity as "searchable" -->
-            
-            <intent-filter>
-                <action android:name="android.intent.action.SEARCH" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-            
-            <!-- This metadata entry provides further configuration details for searches -->
-            <!-- that are handled by this activity. -->
-            
-            <meta-data android:name="android.app.searchable"
-                       android:resource="@xml/searchable" />
-        </activity>
-
-        <!-- This provider declaration informs the Search Manager that you have a provider of -->
-        <!-- Search suggestions, and provides information about how to access it. -->
-        
-        <provider android:name=".app.SearchSuggestionSampleProvider"
-                  android:authorities="com.example.android.apis.SuggestionProvider" />
-
-        <!-- Shortcuts Samples -->
-
-        <!-- This section of sample code shows how your application can add shortcuts to -->
-        <!-- the launcher (home screen).  Shortcuts have a three step life cycle. -->
-        
-        <!-- 1.  Your application offers to provide shortcuts to the launcher.  When -->
-        <!--     the user installs a shortcut, an activity within your application -->
-        <!--     generates the actual shortcut and returns it to the launcher, where it -->
-        <!--     is shown to the user as an icon. -->
-        
-        <!-- 2.  Any time the user clicks on an installed shortcut, an intent is sent. -->
-        <!--     Typically this would then be handled as necessary by an activity within -->
-        <!--     your application. -->
-
-        <!-- 3.  The shortcut is deleted.  There is no notification to your application. -->
-
-        <!-- In order provide shortcuts from your application, you provide three things: -->
-
-        <!-- 1.  An intent-filter declaring your ability to provide shortcuts -->
-        <!-- 2.  Code within the activity to provide the shortcuts as requested -->
-        <!-- 3.  Code elsewhere within your activity, if appropriate, to receive -->
-        <!--     intents from the shortcut itself. -->
-
-        <activity android:name=".app.LauncherShortcuts"
-                  android:label="@string/shortcuts">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-
-        </activity>
-
-        <!-- It is recommended that you use an activity-alias to provide the "CREATE_SHORTCUT" -->
-        <!-- intent-filter.  This gives you a way to set the text (and optionally the -->
-        <!-- icon) that will be seen in the launcher's create-shortcut user interface. -->
-
-        <activity-alias android:name=".app.CreateShortcuts"
-            android:targetActivity=".app.LauncherShortcuts"
-            android:label="@string/sample_shortcuts">
-
-            <!--  This intent-filter allows your shortcuts to be created in the launcher. -->
-            <intent-filter>
-                <action android:name="android.intent.action.CREATE_SHORTCUT" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-
-        </activity-alias>
-
-        <!-- Menu Samples -->
-
-        <activity android:name=".app.MenuInflateFromXml" android:label="@string/menu_from_xml_title">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- Preferences Samples -->
-
-        <activity android:name=".app.PreferencesFromXml" android:label="@string/preferences_from_xml">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.PreferencesFromCode" android:label="@string/preferences_from_code">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.AdvancedPreferences" android:label="@string/advanced_preferences">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.LaunchingPreferences" android:label="@string/launching_preferences">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.PreferenceDependencies" android:label="@string/preference_dependencies">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".app.DefaultValues" android:label="@string/default_values">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-
-        <!-- Voice Recognition Samples -->
-
-        <activity android:name=".app.VoiceRecognition" android:label="@string/voice_recognition">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--        CONTENT PACKAGE SAMPLES        -->
-        <!-- ************************************* -->
-
-        <activity android:name=".content.StyledText" android:label="@string/activity_styled_text">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-                <category android:name="android.intent.category.EMBED" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".content.ReadAsset" android:label="@string/activity_read_asset">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-                <category android:name="android.intent.category.EMBED" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".content.ResourcesSample" android:label="@string/activity_resources">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--     OS PACKAGE SAMPLES                -->
-        <!-- ************************************* -->
-
-        <activity android:name=".os.MorseCode" android:label="OS/Morse Code">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".os.Sensors" android:label="OS/Sensors">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--     ANIMATION PACKAGE SAMPLES         -->
-        <!-- ************************************* -->
-
-        <activity android:name=".animation.Transition3d" android:label="Views/Animation/3D Transition">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--      VIEW/WIDGET PACKAGE SAMPLES      -->
-        <!-- ************************************* -->
-
-        <activity android:name=".view.ChronometerDemo" android:label="Views/Chronometer">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        <activity android:name=".view.WebView1" android:label="Views/WebView">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.RelativeLayout1" android:label="Views/Layouts/RelativeLayout/1. Vertical">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.RelativeLayout2" android:label="Views/Layouts/RelativeLayout/2. Simple Form">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout1" android:label="Views/Layouts/LinearLayout/1. Vertical">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout2" android:label="Views/Layouts/LinearLayout/2. Vertical (Fill Screen)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout3" android:label="Views/Layouts/LinearLayout/3. Vertical (Padded)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout4" android:label="Views/Layouts/LinearLayout/4. Horizontal">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout5" android:label="Views/Layouts/LinearLayout/5. Simple Form">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout6" android:label="Views/Layouts/LinearLayout/6. Uniform Size">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout7" android:label="Views/Layouts/LinearLayout/7. Fill Parent">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout8" android:label="Views/Layouts/LinearLayout/8. Gravity">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout9" android:label="Views/Layouts/LinearLayout/9. Layout Weight">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LinearLayout10" android:label="Views/Layouts/LinearLayout/10. Background Image">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-
-        <activity android:name=".view.RadioGroup1" android:label="Views/Radio Group">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ScrollView1" android:label="Views/Layouts/ScrollView/1. Short">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ScrollView2" android:label="Views/Layouts/ScrollView/2. Long">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs1" android:label="Views/Tabs/Content By Id">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs2" android:label="Views/Tabs/Content By Factory">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs3" android:label="Views/Tabs/Content By Intent">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.InternalSelectionScroll" android:label="Views/Layouts/ScrollView/3. Internal Selection">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout1" android:label="Views/Layouts/TableLayout/01. Basic">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout2" android:label="Views/Layouts/TableLayout/02. Empty Cells">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout3" android:label="Views/Layouts/TableLayout/03. Long Content">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout4" android:label="Views/Layouts/TableLayout/04. Stretchable">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout5" android:label="Views/Layouts/TableLayout/05. Spanning and Stretchable">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout6" android:label="Views/Layouts/TableLayout/06. More Spanning and Stretchable">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout7" android:label="Views/Layouts/TableLayout/07. Column Collapse">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout8" android:label="Views/Layouts/TableLayout/08. Toggle Stretch">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout9" android:label="Views/Layouts/TableLayout/09. Toggle Shrink">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout10" android:label="Views/Layouts/TableLayout/10. Simple Form">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout11" android:label="Views/Layouts/TableLayout/11. Gravity">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TableLayout12" android:label="Views/Layouts/TableLayout/12. Cell Spanning">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs1" android:label="Views/Tabs/Content By Id">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs2" android:label="Views/Tabs/Content By Factory">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Tabs3" android:label="Views/Tabs/Content By Intent">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.SAMPLE_CODE"/>
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline1" android:label="Views/Layouts/Baseline/1. Top">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline2" android:label="Views/Layouts/Baseline/2. Bottom">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline3" android:label="Views/Layouts/Baseline/3. Center">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline4" android:label="Views/Layouts/Baseline/4. Everywhere">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline6" android:label="Views/Layouts/Baseline/5. Multi-line">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Baseline7" android:label="Views/Layouts/Baseline/6. Relative">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.BaselineNested1" android:label="Views/Layouts/Baseline/Nested Example 1">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.BaselineNested2" android:label="Views/Layouts/Baseline/Nested Example 2">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.BaselineNested3" android:label="Views/Layouts/Baseline/Nested Example 3">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ScrollBar1" android:label="Views/ScrollBars/1. Basic">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ScrollBar2" android:label="Views/ScrollBars/2. Fancy">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ScrollBar3" android:label="Views/ScrollBars/3. Style">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Visibility1" android:label="Views/Visibility">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List1" android:label="Views/Lists/1. Array">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List2" android:label="Views/Lists/2. Cursor (People)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List3" android:label="Views/Lists/3. Cursor (Phones)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List4" android:label="Views/Lists/4. ListAdapter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List5" android:label="Views/Lists/5. Separators">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List6" android:label="Views/Lists/6. ListAdapter Collapsed">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List7" android:label="Views/Lists/7. Cursor (Phones)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List8" android:label="Views/Lists/8. Photos">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List9" android:label="Views/Lists/9. Array (Overlay)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List10" android:label="Views/Lists/10. Single choice list">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List11" android:label="Views/Lists/11. Multiple choice list">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List12" android:label="Views/Lists/12. Transcript">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List13" android:label="Views/Lists/13. Slow Adapter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.List14" android:label="Views/Lists/14. Efficient Adapter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ExpandableList1" android:label="Views/Expandable Lists/1. Custom Adapter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ExpandableList2" android:label="Views/Expandable Lists/2. Cursor (People)">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ExpandableList3" android:label="Views/Expandable Lists/3. Simple Adapter">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.CustomView1"
-                android:label="Views/Custom"
-                android:theme="@android:style/Theme.Light">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Gallery1" android:label="Views/Gallery/1. Photos">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Gallery2" android:label="Views/Gallery/2. People">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Spinner1" android:label="Views/Spinner">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Grid1" android:label="Views/Grid/1. Icon Grid">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Grid2" android:label="Views/Grid/2. Photo Grid">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ImageView1"
-                android:label="Views/ImageView">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ImageSwitcher1"
-                android:label="Views/ImageSwitcher">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.TextSwitcher1"
-                android:label="Views/TextSwitcher">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ImageButton1"
-                android:label="Views/ImageButton">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Animation1" android:label="Views/Animation/Shake">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Animation2" android:label="Views/Animation/Push">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation1" android:label="Views/Layout Animation/1. Grid Fade">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation2" android:label="Views/Layout Animation/2. List Cascade">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation3" android:label="Views/Layout Animation/3. Reverse Order">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation4" android:label="Views/Layout Animation/4. Randomize">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation5" android:label="Views/Layout Animation/5. Grid Direction">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation6" android:label="Views/Layout Animation/6. Wave Scale">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.LayoutAnimation7" android:label="Views/Layout Animation/7. Nested Animations">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Controls1"
-                android:label="Views/Controls/1. Light Theme"
-                android:theme="@android:style/Theme.Light">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Controls2" android:label="Views/Controls/2. Default Theme">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Buttons1"
-                android:label="Views/Buttons">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete1" android:label="Views/Auto Complete/1. Screen Top">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete2" android:label="Views/Auto Complete/2. Screen Bottom">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete3" android:label="Views/Auto Complete/3. Scroll">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete4" android:label="Views/Auto Complete/4. Contacts">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete5" android:label="Views/Auto Complete/5. Contacts with Hint">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.AutoComplete6" android:label="Views/Auto Complete/6. Multiple items">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ProgressBar1" android:label="Views/Progress Bar/1. Incremental">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ProgressBar2" android:label="Views/Progress Bar/2. Smooth">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ProgressBar3" android:label="Views/Progress Bar/3. Dialogs">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.ProgressBar4" android:label="Views/Progress Bar/4. In Title Bar">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.SeekBar1" android:label="Views/Seek Bar">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.RatingBar1" android:label="Views/Rating Bar">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Focus1" android:label="Views/Focus/1. Vertical">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Focus2" android:label="Views/Focus/2. Horizontal">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.Focus3" android:label="Views/Focus/3. Circular">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.InternalSelectionFocus" android:label="Views/Focus/4. Internal Selection">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.DateWidgets1" android:label="Views/Date Widgets/1. Dialog">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.DateWidgets2" android:label="Views/Date Widgets/2. Inline">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.MapViewDemo" android:label="Views/MapView">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".view.MapViewCompassDemo" android:label="Views/MapView and Compass">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--           GRAPHICS SAMPLES            -->
-        <!-- ************************************* -->
-
-        <activity android:name=".graphics.kube.Kube" android:label="Graphics/OpenGL ES/Kube"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Compass" android:label="Graphics/Compass">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.CameraPreview" android:label="Graphics/CameraPreview" android:screenOrientation="landscape">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.GLSurfaceViewActivity"
-                android:label="Graphics/OpenGL ES/GLSurfaceView"
-                android:theme="@android:style/Theme.NoTitleBar"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.TranslucentGLSurfaceViewActivity"
-                android:label="Graphics/OpenGL ES/Translucent GLSurfaceView"
-                android:theme="@style/Theme.Translucent"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".graphics.TriangleActivity"
-                android:label="Graphics/OpenGL ES/Textured Triangle"
-                android:theme="@android:style/Theme.NoTitleBar"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".graphics.spritetext.SpriteTextActivity"
-                android:label="Graphics/OpenGL ES/Sprite Text"
-                android:theme="@android:style/Theme.NoTitleBar"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".graphics.TouchRotateActivity"
-                android:label="Graphics/OpenGL ES/Touch Rotate"
-                android:theme="@android:style/Theme.NoTitleBar"
-                android:configChanges="orientation|keyboardHidden">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".graphics.PolyToPoly" android:label="Graphics/PolyToPoly">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.ScaleToFit" android:label="Graphics/ScaleToFit">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.RoundRects" android:label="Graphics/RoundRects">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.ShapeDrawable1" android:label="Graphics/Drawable/ShapeDrawable">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.SurfaceViewOverlay"
-                android:label="Graphics/SurfaceView Overlay">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.TextAlign" android:label="Graphics/Text Align">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Arcs" android:label="Graphics/Arcs">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Patterns" android:label="Graphics/Patterns">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Clipping" android:label="Graphics/Clipping">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Layers" android:label="Graphics/Layers">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.UnicodeChart" android:label="Graphics/UnicodeChart">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.PathFillTypes" android:label="Graphics/PathFillTypes">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Pictures" android:label="Graphics/Pictures">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Vertices" android:label="Graphics/Vertices">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.AnimateDrawables" android:label="Graphics/AnimateDrawables">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.SensorTest" android:label="Graphics/SensorTest">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.AlphaBitmap" android:label="Graphics/AlphaBitmap">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Regions" android:label="Graphics/Regions">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Sweep" android:label="Graphics/Sweep">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.BitmapMesh" android:label="Graphics/BitmapMesh">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.MeasureText" android:label="Graphics/MeasureText">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Typefaces" android:label="Graphics/Typefaces">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.FingerPaint" android:label="Graphics/FingerPaint">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.ColorMatrixSample" android:label="Graphics/ColorMatrix">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.BitmapDecode" android:label="Graphics/BitmapDecode">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.CreateBitmap" android:label="Graphics/CreateBitmap">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.DrawPoints" android:label="Graphics/Points">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.TouchPaint" android:label="Graphics/Touch Paint"
-                android:theme="@style/Theme.Black"
-                android:configChanges="keyboard|keyboardHidden|navigation|orientation">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.BitmapPixels" android:label="Graphics/BitmapPixels">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.Xfermodes" android:label="Graphics/Xfermodes">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.PathEffects" android:label="Graphics/PathEffects">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".graphics.GradientDrawable1" android:label="Graphics/Drawable/GradientDrawable">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--             MEDIA SAMPLES             -->
-        <!-- ************************************* -->
-
-        <activity android:name=".media.MediaPlayerDemo" android:label="Media/MediaPlayer">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".media.MediaPlayerDemo_Audio" android:label="Media/MediaPlayer">
-            <intent-filter>
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".media.MediaPlayerDemo_Video" android:label="Media/MediaPlayer">
-            <intent-filter>
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".media.VideoViewDemo" android:label="Media/VideoView">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <!-- ************************************* -->
-        <!--      GADGET PACKAGE SAMPLES           -->
-        <!-- ************************************* -->
-
-        <receiver android:name=".gadget.ExampleGadgetProvider">
-            <meta-data android:name="android.gadget.provider"
-                    android:resource="@xml/gadget_provider" />
-            <intent-filter>
-                <action android:name="android.gadget.action.GADGET_UPDATE" />
-            </intent-filter>
-        </receiver>
-
-        <receiver android:name=".gadget.ExampleBroadcastReceiver" android:enabled="false">
-            <intent-filter>
-                <action android:name="android.intent.ACTION_TIMEZONE_CHANGED" />
-                <action android:name="android.intent.ACTION_TIME" />
-            </intent-filter>
-        </receiver>
-
-        <!-- ************************************* -->
-        <!--             OTHER SAMPLES             -->
-        <!-- ************************************* -->
-
-        <activity android:name=".text.Link" android:label="Text/Linkify">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name=".text.Marquee" android:label="Text/Marquee">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name=".text.LogTextBox1" android:label="Text/LogTextBox">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.SAMPLE_CODE" />
-            </intent-filter>
-        </activity>
-
-    </application>
-
-    <instrumentation android:name=".app.LocalSampleInstrumentation"
-        android:targetPackage="com.example.android.apis"
-        android:label="Local Sample" />
-
-</manifest>
diff --git a/samples/ApiDemos/_index.html b/samples/ApiDemos/_index.html
deleted file mode 100755
index b0d1c7b..0000000
--- a/samples/ApiDemos/_index.html
+++ /dev/null
@@ -1,19 +0,0 @@
-<p>The API Demos include sample code for many aspects of the Android APIs, from screen layout to Intent resolution.
-</p>
-
-<dl>
-    <dt><a href="src/com/example/android/apis/app/index.html">App</a></dt>
-    <dd></dd>
-
-    <dt><a href="src/com/example/android/apis/content/index.html">Content</a></dt>
-    <dd></dd>
-    
-    <dt><a href="src/com/example/android/apis/view/index.html">View</a></dt>
-    <dd></dd>
-    
-    <dt><a href="src/com/example/android/apis/graphics/index.html">Graphics</a></dt>
-    <dd></dd>
-
-    <dt><a href="src/com/example/android/apis/text/index.html">Text</a></dt>
-    <dd></dd>
-</dl>
diff --git a/samples/ApiDemos/assets/fonts/samplefont.ttf b/samples/ApiDemos/assets/fonts/samplefont.ttf
deleted file mode 100644
index 49f1c62..0000000
--- a/samples/ApiDemos/assets/fonts/samplefont.ttf
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/assets/read_asset.txt b/samples/ApiDemos/assets/read_asset.txt
deleted file mode 100644
index ff9c023..0000000
--- a/samples/ApiDemos/assets/read_asset.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-This text is stored in a raw Asset.
-
-It was read and placed into the TextView here.
diff --git a/samples/ApiDemos/res/anim/cycle_7.xml b/samples/ApiDemos/res/anim/cycle_7.xml
deleted file mode 100644
index 02fb699..0000000
--- a/samples/ApiDemos/res/anim/cycle_7.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<cycleInterpolator xmlns:android="http://schemas.android.com/apk/res/android" android:cycles="7" />
diff --git a/samples/ApiDemos/res/anim/fade.xml b/samples/ApiDemos/res/anim/fade.xml
deleted file mode 100644
index 78b193d..0000000
--- a/samples/ApiDemos/res/anim/fade.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alpha xmlns:android="http://schemas.android.com/apk/res/android"
-       android:interpolator="@android:anim/accelerate_interpolator"
-       android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="100" />
diff --git a/samples/ApiDemos/res/anim/hyperspace_in.xml b/samples/ApiDemos/res/anim/hyperspace_in.xml
deleted file mode 100644
index 8d0cc56..0000000
--- a/samples/ApiDemos/res/anim/hyperspace_in.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alpha xmlns:android="http://schemas.android.com/apk/res/android" android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="300" android:startOffset="1200" />
diff --git a/samples/ApiDemos/res/anim/hyperspace_out.xml b/samples/ApiDemos/res/anim/hyperspace_out.xml
deleted file mode 100644
index 83fef33..0000000
--- a/samples/ApiDemos/res/anim/hyperspace_out.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" android:shareInterpolator="false">
-
-	<scale 
-		android:interpolator="@android:anim/accelerate_decelerate_interpolator"
-		android:fromXScale="1.0" 
-		android:toXScale="1.4" 
-		android:fromYScale="1.0" 
-		android:toYScale="0.6" 
-		android:pivotX="50%"
-		android:pivotY="50%"
-		android:fillAfter="false"
-		android:duration="700" />
-
-
-	<set 
-		android:interpolator="@android:anim/accelerate_interpolator"
-                android:startOffset="700">
-		
-		<scale
-			android:fromXScale="1.4" 
-			android:toXScale="0.0"
-		        android:fromYScale="0.6"
-	 		android:toYScale="0.0" 
-	 		android:pivotX="50%" 
-	 		android:pivotY="50%" 
-	 		android:duration="400" />
- 		
-		<rotate 
-			android:fromDegrees="0" 
-			android:toDegrees="-45"
-	 		android:toYScale="0.0" 
-	 		android:pivotX="50%" 
-	 		android:pivotY="50%"
-	 		android:duration="400" />
-	</set>
-
-</set>
-
diff --git a/samples/ApiDemos/res/anim/layout_animation_row_left_slide.xml b/samples/ApiDemos/res/anim/layout_animation_row_left_slide.xml
deleted file mode 100644
index 9c6a459..0000000
--- a/samples/ApiDemos/res/anim/layout_animation_row_left_slide.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:delay="10%"
-        android:animation="@anim/slide_left" />
diff --git a/samples/ApiDemos/res/anim/layout_animation_row_right_slide.xml b/samples/ApiDemos/res/anim/layout_animation_row_right_slide.xml
deleted file mode 100644
index 156f09a..0000000
--- a/samples/ApiDemos/res/anim/layout_animation_row_right_slide.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:delay="10%"
-        android:animationOrder="reverse"
-        android:animation="@anim/slide_right" />
diff --git a/samples/ApiDemos/res/anim/layout_animation_table.xml b/samples/ApiDemos/res/anim/layout_animation_table.xml
deleted file mode 100644
index efebe84..0000000
--- a/samples/ApiDemos/res/anim/layout_animation_table.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:delay="50%"
-        android:animation="@anim/slide_top_to_bottom" />
diff --git a/samples/ApiDemos/res/anim/layout_bottom_to_top_slide.xml b/samples/ApiDemos/res/anim/layout_bottom_to_top_slide.xml
deleted file mode 100644
index e7cb4bd..0000000
--- a/samples/ApiDemos/res/anim/layout_bottom_to_top_slide.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:delay="30%"
-        android:animationOrder="reverse"
-        android:animation="@anim/slide_right" />
diff --git a/samples/ApiDemos/res/anim/layout_grid_fade.xml b/samples/ApiDemos/res/anim/layout_grid_fade.xml
deleted file mode 100644
index 00d3584..0000000
--- a/samples/ApiDemos/res/anim/layout_grid_fade.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gridLayoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:rowDelay="50%"
-        android:directionPriority="column"
-        android:animation="@anim/fade" />
diff --git a/samples/ApiDemos/res/anim/layout_grid_inverse_fade.xml b/samples/ApiDemos/res/anim/layout_grid_inverse_fade.xml
deleted file mode 100644
index 0a68437..0000000
--- a/samples/ApiDemos/res/anim/layout_grid_inverse_fade.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gridLayoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:columnDelay="0.5"
-        android:directionPriority="row"
-        android:direction="right_to_left|bottom_to_top"
-        android:animation="@anim/fade" />
diff --git a/samples/ApiDemos/res/anim/layout_random_fade.xml b/samples/ApiDemos/res/anim/layout_random_fade.xml
deleted file mode 100644
index 0034676..0000000
--- a/samples/ApiDemos/res/anim/layout_random_fade.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:delay="0.5"
-        android:animationOrder="random"
-        android:animation="@anim/fade" />
diff --git a/samples/ApiDemos/res/anim/layout_wave_scale.xml b/samples/ApiDemos/res/anim/layout_wave_scale.xml
deleted file mode 100644
index 2cdd19d..0000000
--- a/samples/ApiDemos/res/anim/layout_wave_scale.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gridLayoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:rowDelay="75%"
-        android:columnDelay="0%"
-        android:directionPriority="none"
-        android:animation="@anim/wave_scale" />
diff --git a/samples/ApiDemos/res/anim/push_left_in.xml b/samples/ApiDemos/res/anim/push_left_in.xml
deleted file mode 100644
index 894d222..0000000
--- a/samples/ApiDemos/res/anim/push_left_in.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android">
-	<translate android:fromXDelta="100%p" android:toXDelta="0" android:duration="300"/>
-	<alpha android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="300" />
-</set>
diff --git a/samples/ApiDemos/res/anim/push_left_out.xml b/samples/ApiDemos/res/anim/push_left_out.xml
deleted file mode 100644
index 28802d2..0000000
--- a/samples/ApiDemos/res/anim/push_left_out.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android">
-	<translate android:fromXDelta="0" android:toXDelta="-100%p" android:duration="300"/>
-	<alpha android:fromAlpha="1.0" android:toAlpha="0.0" android:duration="300" />
-</set>
diff --git a/samples/ApiDemos/res/anim/push_up_in.xml b/samples/ApiDemos/res/anim/push_up_in.xml
deleted file mode 100644
index a2f47e9..0000000
--- a/samples/ApiDemos/res/anim/push_up_in.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android">
-	<translate android:fromYDelta="100%p" android:toYDelta="0" android:duration="300"/>
-	<alpha android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="300" />
-</set>
diff --git a/samples/ApiDemos/res/anim/push_up_out.xml b/samples/ApiDemos/res/anim/push_up_out.xml
deleted file mode 100644
index 2803435..0000000
--- a/samples/ApiDemos/res/anim/push_up_out.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android">
-	<translate android:fromYDelta="0" android:toYDelta="-100%p" android:duration="300"/>
-	<alpha android:fromAlpha="1.0" android:toAlpha="0.0" android:duration="300" />
-</set>
diff --git a/samples/ApiDemos/res/anim/shake.xml b/samples/ApiDemos/res/anim/shake.xml
deleted file mode 100644
index 80eb451..0000000
--- a/samples/ApiDemos/res/anim/shake.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<translate xmlns:android="http://schemas.android.com/apk/res/android" android:fromXDelta="0" android:toXDelta="10" android:duration="1000" android:interpolator="@anim/cycle_7" />
diff --git a/samples/ApiDemos/res/anim/slide_left.xml b/samples/ApiDemos/res/anim/slide_left.xml
deleted file mode 100644
index 8760491..0000000
--- a/samples/ApiDemos/res/anim/slide_left.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator">
-    <translate android:fromXDelta="100%p" android:toXDelta="0" android:duration="150" />
-</set>
diff --git a/samples/ApiDemos/res/anim/slide_right.xml b/samples/ApiDemos/res/anim/slide_right.xml
deleted file mode 100644
index 7aaacdb..0000000
--- a/samples/ApiDemos/res/anim/slide_right.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator">
-    <translate android:fromXDelta="-100%p" android:toXDelta="0" android:duration="150" />
-</set>
diff --git a/samples/ApiDemos/res/anim/slide_top_to_bottom.xml b/samples/ApiDemos/res/anim/slide_top_to_bottom.xml
deleted file mode 100644
index a548181..0000000
--- a/samples/ApiDemos/res/anim/slide_top_to_bottom.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator">
-    <translate android:fromYDelta="-100%" android:toXDelta="0" android:duration="100" />
-    <alpha android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="50" />
-</set>
diff --git a/samples/ApiDemos/res/anim/wave_scale.xml b/samples/ApiDemos/res/anim/wave_scale.xml
deleted file mode 100644
index ea4eaf2..0000000
--- a/samples/ApiDemos/res/anim/wave_scale.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator">
-    <alpha
-        android:fromAlpha="0.0"
-        android:toAlpha="1.0"
-        android:duration="100" />
-    <scale
-        android:fromXScale="0.5" android:toXScale="1.5"
-        android:fromYScale="0.5" android:toYScale="1.5"
-        android:pivotX="50%" android:pivotY="50%"
-        android:duration="200" />
-    <scale 
-        android:fromXScale="1.5" android:toXScale="1.0"
-        android:fromYScale="1.5" android:toYScale="1.0"
-        android:pivotX="50%" android:pivotY="50%"
-        android:startOffset="200"
-        android:duration="100" />
-</set>
diff --git a/samples/ApiDemos/res/drawable/alert_dialog_icon.png b/samples/ApiDemos/res/drawable/alert_dialog_icon.png
deleted file mode 100644
index 0a7de04..0000000
--- a/samples/ApiDemos/res/drawable/alert_dialog_icon.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/animated_gif.gif b/samples/ApiDemos/res/drawable/animated_gif.gif
deleted file mode 100644
index 51baf15..0000000
--- a/samples/ApiDemos/res/drawable/animated_gif.gif
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/app_sample_code.png b/samples/ApiDemos/res/drawable/app_sample_code.png
deleted file mode 100644
index 5ae7701..0000000
--- a/samples/ApiDemos/res/drawable/app_sample_code.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/arrow_down_float.png b/samples/ApiDemos/res/drawable/arrow_down_float.png
deleted file mode 100644
index bfe0ce6..0000000
--- a/samples/ApiDemos/res/drawable/arrow_down_float.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/arrow_up_float.png b/samples/ApiDemos/res/drawable/arrow_up_float.png
deleted file mode 100644
index 77673ef..0000000
--- a/samples/ApiDemos/res/drawable/arrow_up_float.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/balloons.jpg b/samples/ApiDemos/res/drawable/balloons.jpg
deleted file mode 100644
index 6a90b92..0000000
--- a/samples/ApiDemos/res/drawable/balloons.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/beach.jpg b/samples/ApiDemos/res/drawable/beach.jpg
deleted file mode 100644
index ae9794f..0000000
--- a/samples/ApiDemos/res/drawable/beach.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/black_box.xml b/samples/ApiDemos/res/drawable/black_box.xml
deleted file mode 100644
index 7772d56..0000000
--- a/samples/ApiDemos/res/drawable/black_box.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#1e000000"/>
-    <padding android:left="1dp" android:top="1dp"
-            android:right="1dp" android:bottom="1dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/black_opaque_box.xml b/samples/ApiDemos/res/drawable/black_opaque_box.xml
deleted file mode 100644
index ba43f01..0000000
--- a/samples/ApiDemos/res/drawable/black_opaque_box.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#56000000"/>
-    <padding android:left="1dp" android:top="1dp"
-            android:right="1dp" android:bottom="1dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/box.xml b/samples/ApiDemos/res/drawable/box.xml
deleted file mode 100644
index 825de84..0000000
--- a/samples/ApiDemos/res/drawable/box.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#00000000"/>
-    <stroke android:width="1dp" color="#ff000000"/>
-    <padding android:left="1dp" android:top="1dp"
-        android:right="1dp" android:bottom="1dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/button.9.png b/samples/ApiDemos/res/drawable/button.9.png
deleted file mode 100644
index f6da7e5..0000000
--- a/samples/ApiDemos/res/drawable/button.9.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/circular_progress.xml b/samples/ApiDemos/res/drawable/circular_progress.xml
deleted file mode 100644
index 1d76f57..0000000
--- a/samples/ApiDemos/res/drawable/circular_progress.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
-    <item
-        android:drawable="@drawable/progress_circular_background" />
-
-    <item><rotate
-        android:pivotX="50%"
-        android:pivotY="50%"
-        android:fromDegrees="0"
-        android:toDegrees="360"
-        android:drawable="@drawable/progress_particle" />
-    </item>
-</layer-list>
-
diff --git a/samples/ApiDemos/res/drawable/filled_box.xml b/samples/ApiDemos/res/drawable/filled_box.xml
deleted file mode 100644
index 75d15a0..0000000
--- a/samples/ApiDemos/res/drawable/filled_box.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#f0600000"/>
-    <stroke android:width="3dp" color="#ffff8080"/>
-    <corners android:radius="3dp" />
-    <padding android:left="10dp" android:top="10dp"
-        android:right="10dp" android:bottom="10dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/frog.gif b/samples/ApiDemos/res/drawable/frog.gif
deleted file mode 100644
index 9c20748..0000000
--- a/samples/ApiDemos/res/drawable/frog.gif
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_background_1.xml b/samples/ApiDemos/res/drawable/gallery_background_1.xml
deleted file mode 100644
index a82794e..0000000
--- a/samples/ApiDemos/res/drawable/gallery_background_1.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_pressed="true" android:drawable="@drawable/black_opaque_box" />
-    <item android:drawable="@drawable/black_box" />
-</selector>
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_1.jpg b/samples/ApiDemos/res/drawable/gallery_photo_1.jpg
deleted file mode 100644
index a2581fe..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_1.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_2.jpg b/samples/ApiDemos/res/drawable/gallery_photo_2.jpg
deleted file mode 100644
index 82ba3a8..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_2.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_3.jpg b/samples/ApiDemos/res/drawable/gallery_photo_3.jpg
deleted file mode 100644
index 2a83021..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_3.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_4.jpg b/samples/ApiDemos/res/drawable/gallery_photo_4.jpg
deleted file mode 100644
index 70a1c55..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_4.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_5.jpg b/samples/ApiDemos/res/drawable/gallery_photo_5.jpg
deleted file mode 100644
index dc3f677..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_5.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_6.jpg b/samples/ApiDemos/res/drawable/gallery_photo_6.jpg
deleted file mode 100644
index 2e113a0..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_6.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_7.jpg b/samples/ApiDemos/res/drawable/gallery_photo_7.jpg
deleted file mode 100644
index bc30297..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_7.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/gallery_photo_8.jpg b/samples/ApiDemos/res/drawable/gallery_photo_8.jpg
deleted file mode 100644
index dc3aa85..0000000
--- a/samples/ApiDemos/res/drawable/gallery_photo_8.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/ic_popup_reminder.png b/samples/ApiDemos/res/drawable/ic_popup_reminder.png
deleted file mode 100755
index 4f2b82c..0000000
--- a/samples/ApiDemos/res/drawable/ic_popup_reminder.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/icon48x48_1.png b/samples/ApiDemos/res/drawable/icon48x48_1.png
deleted file mode 100644
index d3b8125..0000000
--- a/samples/ApiDemos/res/drawable/icon48x48_1.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/icon48x48_2.png b/samples/ApiDemos/res/drawable/icon48x48_2.png
deleted file mode 100755
index 84af2a2..0000000
--- a/samples/ApiDemos/res/drawable/icon48x48_2.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/line.xml b/samples/ApiDemos/res/drawable/line.xml
deleted file mode 100644
index b3707ff..0000000
--- a/samples/ApiDemos/res/drawable/line.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="line">
-    <stroke android:width="1dp" android:color="#FF000000"
-            android:dashWidth="1dp" android:dashGap="2dp" />
-    <size android:height="5dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/photo1.jpg b/samples/ApiDemos/res/drawable/photo1.jpg
deleted file mode 100644
index 825682b..0000000
--- a/samples/ApiDemos/res/drawable/photo1.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/photo2.jpg b/samples/ApiDemos/res/drawable/photo2.jpg
deleted file mode 100644
index a1c8b55..0000000
--- a/samples/ApiDemos/res/drawable/photo2.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/photo3.jpg b/samples/ApiDemos/res/drawable/photo3.jpg
deleted file mode 100644
index 44b671e..0000000
--- a/samples/ApiDemos/res/drawable/photo3.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/photo4.jpg b/samples/ApiDemos/res/drawable/photo4.jpg
deleted file mode 100644
index 2483bb9..0000000
--- a/samples/ApiDemos/res/drawable/photo4.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/photo5.jpg b/samples/ApiDemos/res/drawable/photo5.jpg
deleted file mode 100644
index 250b085..0000000
--- a/samples/ApiDemos/res/drawable/photo5.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/photo6.jpg b/samples/ApiDemos/res/drawable/photo6.jpg
deleted file mode 100644
index 6c3c956..0000000
--- a/samples/ApiDemos/res/drawable/photo6.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/picture_frame.png b/samples/ApiDemos/res/drawable/picture_frame.png
deleted file mode 100644
index ba71570..0000000
--- a/samples/ApiDemos/res/drawable/picture_frame.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/progress_circular_background.png b/samples/ApiDemos/res/drawable/progress_circular_background.png
deleted file mode 100644
index 7c637fd..0000000
--- a/samples/ApiDemos/res/drawable/progress_circular_background.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/progress_particle.png b/samples/ApiDemos/res/drawable/progress_particle.png
deleted file mode 100644
index 9160108..0000000
--- a/samples/ApiDemos/res/drawable/progress_particle.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/robot.png b/samples/ApiDemos/res/drawable/robot.png
deleted file mode 100644
index 8a9e698..0000000
--- a/samples/ApiDemos/res/drawable/robot.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_0.jpg b/samples/ApiDemos/res/drawable/sample_0.jpg
deleted file mode 100644
index 9dd3bce..0000000
--- a/samples/ApiDemos/res/drawable/sample_0.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_1.jpg b/samples/ApiDemos/res/drawable/sample_1.jpg
deleted file mode 100644
index 46d06e0..0000000
--- a/samples/ApiDemos/res/drawable/sample_1.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_2.jpg b/samples/ApiDemos/res/drawable/sample_2.jpg
deleted file mode 100644
index c23dd63..0000000
--- a/samples/ApiDemos/res/drawable/sample_2.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_3.jpg b/samples/ApiDemos/res/drawable/sample_3.jpg
deleted file mode 100644
index 0f0d5b5..0000000
--- a/samples/ApiDemos/res/drawable/sample_3.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_4.jpg b/samples/ApiDemos/res/drawable/sample_4.jpg
deleted file mode 100644
index d28ce6f..0000000
--- a/samples/ApiDemos/res/drawable/sample_4.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_5.jpg b/samples/ApiDemos/res/drawable/sample_5.jpg
deleted file mode 100644
index 2348c7d..0000000
--- a/samples/ApiDemos/res/drawable/sample_5.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_6.jpg b/samples/ApiDemos/res/drawable/sample_6.jpg
deleted file mode 100644
index a35fc0c..0000000
--- a/samples/ApiDemos/res/drawable/sample_6.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_7.jpg b/samples/ApiDemos/res/drawable/sample_7.jpg
deleted file mode 100644
index 96a4879..0000000
--- a/samples/ApiDemos/res/drawable/sample_7.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_0.jpg b/samples/ApiDemos/res/drawable/sample_thumb_0.jpg
deleted file mode 100644
index 5b641e8..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_0.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_1.jpg b/samples/ApiDemos/res/drawable/sample_thumb_1.jpg
deleted file mode 100644
index 630c3c5..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_1.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_2.jpg b/samples/ApiDemos/res/drawable/sample_thumb_2.jpg
deleted file mode 100644
index fad840a..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_2.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_3.jpg b/samples/ApiDemos/res/drawable/sample_thumb_3.jpg
deleted file mode 100644
index 27e0359..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_3.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_4.jpg b/samples/ApiDemos/res/drawable/sample_thumb_4.jpg
deleted file mode 100644
index 4934f02..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_4.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_5.jpg b/samples/ApiDemos/res/drawable/sample_thumb_5.jpg
deleted file mode 100644
index c9c7380..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_5.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_6.jpg b/samples/ApiDemos/res/drawable/sample_thumb_6.jpg
deleted file mode 100644
index 0e2f3e4..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_6.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/sample_thumb_7.jpg b/samples/ApiDemos/res/drawable/sample_thumb_7.jpg
deleted file mode 100644
index bf82c5d..0000000
--- a/samples/ApiDemos/res/drawable/sample_thumb_7.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/scrollbar_state2.png b/samples/ApiDemos/res/drawable/scrollbar_state2.png
deleted file mode 100755
index 012f737..0000000
--- a/samples/ApiDemos/res/drawable/scrollbar_state2.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/scrollbar_vertical_thumb.xml b/samples/ApiDemos/res/drawable/scrollbar_vertical_thumb.xml
deleted file mode 100644
index 4d80454..0000000
--- a/samples/ApiDemos/res/drawable/scrollbar_vertical_thumb.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <gradient android:startColor="#3333FF" android:endColor="#8080FF"
-            android:angle="0"/>
-    <corners android:radius="6dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/scrollbar_vertical_track.xml b/samples/ApiDemos/res/drawable/scrollbar_vertical_track.xml
deleted file mode 100644
index b3ad842..0000000
--- a/samples/ApiDemos/res/drawable/scrollbar_vertical_track.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <gradient android:startColor="#505050" android:endColor="#C0C0C0"
-            android:angle="0"/>
-    <corners android:radius="0dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/shape_1.xml b/samples/ApiDemos/res/drawable/shape_1.xml
deleted file mode 100644
index ea30bcf..0000000
--- a/samples/ApiDemos/res/drawable/shape_1.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#00000000"/>
-    <stroke android:width="2dp" android:color="#ff000000"/>
-    <padding android:left="1dp" android:top="1dp"
-            android:right="1dp" android:bottom="1dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/shape_2.xml b/samples/ApiDemos/res/drawable/shape_2.xml
deleted file mode 100644
index 23bcb36..0000000
--- a/samples/ApiDemos/res/drawable/shape_2.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="#FF0000FF"/>
-    <stroke android:width="4dp" android:color="#FFFFFFFF"
-            android:dashWidth="1dp" android:dashGap="2dp" />
-    <padding android:left="7dp" android:top="7dp"
-            android:right="7dp" android:bottom="7dp" />
-    <corners android:radius="4dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/shape_3.xml b/samples/ApiDemos/res/drawable/shape_3.xml
deleted file mode 100644
index 6822037..0000000
--- a/samples/ApiDemos/res/drawable/shape_3.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval">
-    <solid android:color="#00000000"/>
-    <stroke android:width="4dp" android:color="#99000000"
-            android:dashWidth="4dp" android:dashGap="2dp" />
-    <padding android:left="7dp" android:top="7dp"
-            android:right="7dp" android:bottom="7dp" />
-    <corners android:radius="4dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/shape_4.xml b/samples/ApiDemos/res/drawable/shape_4.xml
deleted file mode 100644
index 0deb0d1..0000000
--- a/samples/ApiDemos/res/drawable/shape_4.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="line">
-    <stroke android:width="1dp" android:color="#FF000000"
-            android:dashWidth="1dp" android:dashGap="2dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/shape_5.xml b/samples/ApiDemos/res/drawable/shape_5.xml
deleted file mode 100644
index edd1d6f..0000000
--- a/samples/ApiDemos/res/drawable/shape_5.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
-    <gradient android:startColor="#FFFF0000" android:endColor="#80FF00FF"
-            android:angle="270"/>
-    <padding android:left="7dp" android:top="7dp"
-            android:right="7dp" android:bottom="7dp" />
-    <corners android:radius="8dp" />
-</shape>
diff --git a/samples/ApiDemos/res/drawable/star_big_on.png b/samples/ApiDemos/res/drawable/star_big_on.png
deleted file mode 100644
index 510c8b2..0000000
--- a/samples/ApiDemos/res/drawable/star_big_on.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/stat_happy.png b/samples/ApiDemos/res/drawable/stat_happy.png
deleted file mode 100644
index 3a8791b..0000000
--- a/samples/ApiDemos/res/drawable/stat_happy.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/stat_neutral.png b/samples/ApiDemos/res/drawable/stat_neutral.png
deleted file mode 100644
index 1dc0594..0000000
--- a/samples/ApiDemos/res/drawable/stat_neutral.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/stat_sad.png b/samples/ApiDemos/res/drawable/stat_sad.png
deleted file mode 100644
index 17d26de..0000000
--- a/samples/ApiDemos/res/drawable/stat_sad.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/drawable/stat_sample.png b/samples/ApiDemos/res/drawable/stat_sample.png
deleted file mode 100644
index 1733042..0000000
--- a/samples/ApiDemos/res/drawable/stat_sample.png
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/layout/alarm_controller.xml b/samples/ApiDemos/res/layout/alarm_controller.xml
deleted file mode 100644
index 9ce4d72..0000000
--- a/samples/ApiDemos/res/layout/alarm_controller.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/alarm_controller"/>
-
-    <Button android:id="@+id/one_shot"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/one_shot_alarm">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/start_repeating"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start_repeating_alarm" />
-
-    <Button android:id="@+id/stop_repeating"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/stop_repeating_alarm" />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/alarm_service.xml b/samples/ApiDemos/res/layout/alarm_service.xml
deleted file mode 100644
index e24369c..0000000
--- a/samples/ApiDemos/res/layout/alarm_service.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/alarm_service"/>
-
-    <Button android:id="@+id/start_alarm"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start_alarm_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/stop_alarm"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/stop_alarm_service" />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/alert_dialog.xml b/samples/ApiDemos/res/layout/alert_dialog.xml
deleted file mode 100644
index ddd5cb6..0000000
--- a/samples/ApiDemos/res/layout/alert_dialog.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates different uses of the android.app.AlertDialog.
-     See corresponding Java code com.example.android.apis.app.AlertDialogSamples.java. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/screen"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-    <LinearLayout
-        android:layout_width="fill_parent" android:layout_height="fill_parent"
-        android:orientation="vertical">
-        <Button android:id="@+id/two_buttons"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_two_buttons"/>
-        <Button android:id="@+id/two_buttons2"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_two_buttons2"/>
-        <Button android:id="@+id/select_button"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_select_button"/>
-        <Button android:id="@+id/progress_button"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_progress_button"/>
-        <Button android:id="@+id/radio_button"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_single_choice"/>
-        <Button android:id="@+id/checkbox_button"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_multi_choice"/>
-        <Button android:id="@+id/text_entry_button"
-            android:layout_width="fill_parent" android:layout_height="wrap_content"
-            android:text="@string/alert_dialog_text_entry"/>
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/alert_dialog_text_entry.xml b/samples/ApiDemos/res/layout/alert_dialog_text_entry.xml
deleted file mode 100644
index adec305..0000000
--- a/samples/ApiDemos/res/layout/alert_dialog_text_entry.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:orientation="vertical">
-
-    <TextView 
-        android:id="@+id/username_view"
-        android:layout_height="wrap_content"
-        android:layout_width="wrap_content"
-        android:layout_marginLeft="20dip"
-        android:layout_marginRight="20dip"
-        android:text="@string/alert_dialog_username"
-        android:gravity="left"
-        android:textAppearance="?android:attr/textAppearanceMedium" />
-            
-    <EditText
-        android:id="@+id/username_edit"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent"
-        android:layout_marginLeft="20dip"
-        android:layout_marginRight="20dip"
-        android:scrollHorizontally="true"
-        android:autoText="false"
-        android:capitalize="none"
-        android:gravity="fill_horizontal"
-        android:textAppearance="?android:attr/textAppearanceMedium" />
-
-    <TextView
-        android:id="@+id/password_view"
-        android:layout_height="wrap_content"
-        android:layout_width="wrap_content"
-        android:layout_marginLeft="20dip"
-        android:layout_marginRight="20dip"
-        android:text="@string/alert_dialog_password"
-        android:gravity="left"
-        android:textAppearance="?android:attr/textAppearanceMedium" />
-            
-    <EditText
-        android:id="@+id/password_edit"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent"
-        android:layout_marginLeft="20dip"
-        android:layout_marginRight="20dip"
-        android:scrollHorizontally="true"
-        android:autoText="false"
-        android:capitalize="none"
-        android:gravity="fill_horizontal"
-        android:password="true"
-        android:textAppearance="?android:attr/textAppearanceMedium" />
-        
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/animation_1.xml b/samples/ApiDemos/res/layout/animation_1.xml
deleted file mode 100644
index cd25e04..0000000
--- a/samples/ApiDemos/res/layout/animation_1.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:padding="10dip"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-    
-    <TextView 
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginBottom="10dip"
-        android:text="@string/animation_1_instructions"
-    />
-    
-    <EditText android:id="@+id/pw"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:clickable="true"
-        android:singleLine="true"
-        android:password="true"
-    />
-
-    <Button android:id="@+id/login"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/googlelogin_login"
-    />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/animation_2.xml b/samples/ApiDemos/res/layout/animation_2.xml
deleted file mode 100644
index 9f37920..0000000
--- a/samples/ApiDemos/res/layout/animation_2.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-        android:orientation="vertical"
-        android:padding="10dip"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-    <ViewFlipper android:id="@+id/flipper"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:flipInterval="2000"
-                android:layout_marginBottom="20dip" >
-                <TextView
-                        android:layout_width="fill_parent"
-                        android:layout_height="wrap_content"
-                        android:gravity="center_horizontal"
-                        android:textSize="26sp"
-                        android:text="@string/animation_2_text_1"/>
-                <TextView
-                        android:layout_width="fill_parent"
-                        android:layout_height="wrap_content"
-                        android:gravity="center_horizontal"
-                        android:textSize="26sp"
-                        android:text="@string/animation_2_text_2"/>
-                <TextView
-                        android:layout_width="fill_parent"
-                        android:layout_height="wrap_content"
-                        android:gravity="center_horizontal"
-                        android:textSize="26sp"
-                        android:text="@string/animation_2_text_3"/>
-                <TextView
-                        android:layout_width="fill_parent"
-                        android:layout_height="wrap_content"
-                        android:gravity="center_horizontal"
-                        android:textSize="26sp"
-                        android:text="@string/animation_2_text_4"/>
-    </ViewFlipper>
-
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginBottom="5dip"
-        android:text="@string/animation_2_instructions"
-    />
-
-    <Spinner android:id="@+id/spinner"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-    />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/animations_main_screen.xml b/samples/ApiDemos/res/layout/animations_main_screen.xml
deleted file mode 100644
index ee9e339..0000000
--- a/samples/ApiDemos/res/layout/animations_main_screen.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/container"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <ListView
-        android:id="@android:id/list"
-        android:persistentDrawingCache="animation|scrolling"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:layoutAnimation="@anim/layout_bottom_to_top_slide" />
-
-    <ImageView
-        android:id="@+id/picture"
-        android:scaleType="fitCenter"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:visibility="gone" />
-
-</FrameLayout>
diff --git a/samples/ApiDemos/res/layout/autocomplete_1.xml b/samples/ApiDemos/res/layout/autocomplete_1.xml
deleted file mode 100644
index 3c41926..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_1.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_1_instructions" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_1_country" />
-
-        <AutoCompleteTextView android:id="@+id/edit"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-    </LinearLayout>
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_1_focus" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/autocomplete_2.xml b/samples/ApiDemos/res/layout/autocomplete_2.xml
deleted file mode 100644
index 6d4ee75..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_2.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-    android:gravity="bottom">
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_2_focus" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_2_country" />
-
-        <AutoCompleteTextView android:id="@+id/edit"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/autocomplete_3.xml b/samples/ApiDemos/res/layout/autocomplete_3.xml
deleted file mode 100644
index e97535a..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_3.xml
+++ /dev/null
@@ -1,165 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_1" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_2" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_3" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_4" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_5" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_6" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_7" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_8" />
-
-         <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_1" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_2" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_3" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_4" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_5" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_6" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_7" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button_8" />
-
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/autocomplete_3_country" />
-
-            <AutoCompleteTextView android:id="@+id/edit"
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content" />
-
-        </LinearLayout>
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_3_button" />
-
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/autocomplete_3_country" />
-
-            <AutoCompleteTextView android:id="@+id/edit2"
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content" />
-
-        </LinearLayout>
-
-    </LinearLayout>
-
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/autocomplete_4.xml b/samples/ApiDemos/res/layout/autocomplete_4.xml
deleted file mode 100644
index 97e5eb9..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_4.xml
+++ /dev/null
@@ -1,49 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_4_instructions" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_4_name" />
-
-        <AutoCompleteTextView android:id="@+id/edit"
-            android:completionThreshold="1"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-    </LinearLayout>
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_4_message" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/autocomplete_5.xml b/samples/ApiDemos/res/layout/autocomplete_5.xml
deleted file mode 100644
index 34f68c6..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_5.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_5_instructions" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_5_name" />
-
-        <AutoCompleteTextView android:id="@+id/edit"
-            android:completionThreshold="1"
-            android:completionHint="@string/autocomplete_5_hint"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/autocomplete_6.xml b/samples/ApiDemos/res/layout/autocomplete_6.xml
deleted file mode 100644
index 24fbda1..0000000
--- a/samples/ApiDemos/res/layout/autocomplete_6.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_7_instructions" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/autocomplete_7_country" />
-
-        <MultiAutoCompleteTextView android:id="@+id/edit"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-
-    </LinearLayout>
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/autocomplete_7_focus" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_1.xml b/samples/ApiDemos/res/layout/baseline_1.xml
deleted file mode 100644
index 0f1c9f6..0000000
--- a/samples/ApiDemos/res/layout/baseline_1.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/baseline_1_label" />
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/baseline_1_button" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:textSize="20sp"
-        android:text="@string/baseline_1_bigger" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_2.xml b/samples/ApiDemos/res/layout/baseline_2.xml
deleted file mode 100644
index 8e323b6..0000000
--- a/samples/ApiDemos/res/layout/baseline_2.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="bottom"
-        android:text="@string/baseline_2_label" />
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="bottom"
-        android:text="@string/baseline_2_button" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="bottom"
-        android:textSize="20sp"
-        android:text="@string/baseline_2_bigger" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_3.xml b/samples/ApiDemos/res/layout/baseline_3.xml
deleted file mode 100644
index c251703..0000000
--- a/samples/ApiDemos/res/layout/baseline_3.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/baseline_3_explanation" />
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_weight="1.0"
-        android:layout_height="0dip">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="3dip"
-            android:layout_gravity="center_vertical"
-            android:text="@string/baseline_3_label" />
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="3dip"
-            android:layout_gravity="center_vertical"
-            android:text="@string/baseline_3_button" />
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical"
-            android:textSize="20sp"
-            android:text="@string/baseline_3_bigger" />
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_4.xml b/samples/ApiDemos/res/layout/baseline_4.xml
deleted file mode 100644
index 5faa9da..0000000
--- a/samples/ApiDemos/res/layout/baseline_4.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/baseline_4_label" />
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_4_button" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="bottom"
-        android:textSize="20sp"
-        android:text="@string/baseline_4_bigger" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/baseline_4_label_2" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="bottom"
-        android:text="@string/baseline_4_label_3" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_6.xml b/samples/ApiDemos/res/layout/baseline_6.xml
deleted file mode 100644
index 5418afb..0000000
--- a/samples/ApiDemos/res/layout/baseline_6.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <EditText android:id="@+id/anchor"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:textSize="20sp"
-        android:text="@string/baseline_6_multi_line" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignBaseline="@id/anchor"
-        android:layout_alignRight="@id/anchor"
-        android:text="@string/baseline_6_baseline" />
-
-</RelativeLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_7.xml b/samples/ApiDemos/res/layout/baseline_7.xml
deleted file mode 100644
index 2dc9439..0000000
--- a/samples/ApiDemos/res/layout/baseline_7.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView android:id="@+id/anchor"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentTop="true"
-        android:layout_alignParentLeft="true"
-        android:textStyle="bold"
-        android:text="@string/baseline_7_fat" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_alignParentRight="true"
-        android:layout_alignBaseline="@id/anchor"
-        android:layout_height="wrap_content"
-        android:text="@string/baseline_7_lean" />
-    
-</RelativeLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_nested_1.xml b/samples/ApiDemos/res/layout/baseline_nested_1.xml
deleted file mode 100644
index b940239..0000000
--- a/samples/ApiDemos/res/layout/baseline_nested_1.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-    <!-- We want the middle textview of this vertical linear layout to
-      be baseline aligned with the others.-->
-    <LinearLayout
-            android:orientation="vertical"
-            android:baselineAlignedChildIndex="1"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="5dip"
-            android:text="@string/baseline_nested_1_label" />
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_down_float"/>
-    </LinearLayout>
-
-
-    <!-- We want the third index textview of this vertical linear layout to
-      be baseline aligned with the others.-->
-    <LinearLayout
-            android:orientation="vertical"
-            android:baselineAlignedChildIndex="2"
-            android:layout_width="wrap_content"
-            android:layout_gravity="center_vertical"
-            android:layout_height="wrap_content">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="5dip"
-            android:text="@string/baseline_nested_1_label" />
-    </LinearLayout>
-
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:textSize="20sp"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_nested_2.xml b/samples/ApiDemos/res/layout/baseline_nested_2.xml
deleted file mode 100644
index 5bc8361..0000000
--- a/samples/ApiDemos/res/layout/baseline_nested_2.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-    <!-- We want the middle textview of this vertical linear layout to
-      be baseline aligned with the others.-->
-    <LinearLayout
-            android:orientation="vertical"
-            android:baselineAlignedChildIndex="1"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="5dip"
-            android:text="@string/baseline_nested_1_label" />
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_down_float"/>
-    </LinearLayout>
-
-
-    <!-- We want the third index textview of this vertical linear layout to
-      be baseline aligned with the others.-->
-    <LinearLayout
-            android:orientation="horizontal"
-            android:baselineAlignedChildIndex="2"
-            android:layout_width="wrap_content"
-            android:layout_gravity="center_vertical"
-            android:layout_height="wrap_content">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="5dip"
-            android:text="@string/baseline_nested_1_label" />
-    </LinearLayout>
-
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:textSize="20sp"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/baseline_nested_3.xml b/samples/ApiDemos/res/layout/baseline_nested_3.xml
deleted file mode 100644
index c01c947..0000000
--- a/samples/ApiDemos/res/layout/baseline_nested_3.xml
+++ /dev/null
@@ -1,96 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-    <!-- We want the middle textview of this vertical linear layout to
-      be baseline aligned with the others.-->
-    <LinearLayout
-            android:orientation="vertical"
-            android:baselineAlignedChildIndex="1"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginRight="5dip"
-            android:text="@string/baseline_nested_1_label" />
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_down_float"/>
-    </LinearLayout>
-
-
-    <!-- We'll point to the linear layout to baseline align by, which
-      in turn will point to a text view inside of it -->
-    <LinearLayout
-        android:orientation="vertical"
-                android:baselineAlignedChildIndex="1"
-                android:layout_width="wrap_content"
-                android:layout_gravity="center_vertical"
-                android:layout_height="wrap_content">
-        <ImageView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:src="@drawable/arrow_up_float"/>
-        <LinearLayout
-                android:orientation="vertical"
-                android:baselineAlignedChildIndex="2"
-                android:layout_width="wrap_content"
-                android:layout_gravity="center_vertical"
-                android:layout_height="wrap_content">
-            <ImageView
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:src="@drawable/arrow_up_float"/>
-            <ImageView
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:src="@drawable/arrow_up_float"/>
-            <TextView
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_marginRight="5dip"
-                    android:text="@string/baseline_nested_1_label"/>
-        </LinearLayout>
-    </LinearLayout>
-
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:textSize="20sp"
-        android:layout_gravity="center_vertical"
-        android:text="@string/baseline_nested_1_label" />
-
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/buttons_1.xml b/samples/ApiDemos/res/layout/buttons_1.xml
deleted file mode 100644
index dc657ef..0000000
--- a/samples/ApiDemos/res/layout/buttons_1.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Lots of buttons = need scrolling -->
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    
-    <LinearLayout
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:orientation="vertical">
-        
-        <!-- Regular sized buttons -->
-        <Button android:id="@+id/button_normal"
-            android:text="@string/buttons_1_normal"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-
-        <!-- Small buttons -->
-        <Button android:id="@+id/button_small"
-            style="?android:attr/buttonStyleSmall"
-            android:text="@string/buttons_1_small"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-
-        <ToggleButton android:id="@+id/button_toggle"
-            android:text="@string/buttons_1_toggle"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-    </LinearLayout>
-    
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/chronometer.xml b/samples/ApiDemos/res/layout/chronometer.xml
deleted file mode 100644
index b38c2b6..0000000
--- a/samples/ApiDemos/res/layout/chronometer.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <Chronometer android:id="@+id/chronometer"
-        android:format="@string/chronometer_initial_format"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="30dip"
-        android:paddingTop="30dip"
-        />
-
-    <Button android:id="@+id/start"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/chronometer_start">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/stop"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/chronometer_stop">
-    </Button>
-
-    <Button android:id="@+id/reset"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/chronometer_reset">
-    </Button>
-
-    <Button android:id="@+id/set_format"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/chronometer_set_format">
-    </Button>
-
-    <Button android:id="@+id/clear_format"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/chronometer_clear_format">
-    </Button>
-
-</LinearLayout>
-
-
diff --git a/samples/ApiDemos/res/layout/contacts_filter.xml b/samples/ApiDemos/res/layout/contacts_filter.xml
deleted file mode 100644
index e8d1615..0000000
--- a/samples/ApiDemos/res/layout/contacts_filter.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Front-end for running application instrumentation demonstration.
-     See corresponding Java code com.android.sdk.app.ContactsFilter.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/contacts_filter"/>
-
-    <Button android:id="@+id/go"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/go">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/controls_1.xml b/samples/ApiDemos/res/layout/controls_1.xml
deleted file mode 100644
index 29658d7..0000000
--- a/samples/ApiDemos/res/layout/controls_1.xml
+++ /dev/null
@@ -1,122 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-    
-        <Button android:id="@+id/button"
-            android:text="@string/controls_1_save"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"/>
-    
-        <EditText android:id="@+id/edit"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"/>
-            
-        <CheckBox android:id="@+id/check1"
-            android:paddingBottom="24sp"
-	        android:paddingTop="24sp"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/controls_1_checkbox_1" />
-    
-        <CheckBox android:id="@+id/check2"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/controls_1_checkbox_2" />
-    
-        <RadioGroup
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:orientation="vertical">
-    
-            <RadioButton android:id="@+id/radio1"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/controls_1_radiobutton_1" />
-    
-            <RadioButton android:id="@+id/radio2"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/controls_1_radiobutton_2" />
-    
-        </RadioGroup>
-    
-        <CheckBox android:id="@+id/star"
-            style="?android:attr/starStyle"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/controls_1_star" />
-                            
-        <ToggleButton android:id="@+id/toggle1"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-   
-        <ToggleButton android:id="@+id/toggle2"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-             
-        <Spinner android:id="@+id/spinner1"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:drawSelectorOnTop="true"
-        />
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="5dip"
-            android:text="@string/textColorPrimary"
-            android:textAppearance="?android:attr/textAppearanceLarge"
-            android:focusable="true"
-        />
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="5dip"
-            android:text="@string/textColorSecondary"
-            android:textAppearance="?android:attr/textAppearanceLarge"
-            android:textColor="?android:attr/textColorSecondary"
-            android:focusable="true"
-        />
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="5dip"
-            android:text="@string/textColorTertiary"
-            android:textAppearance="?android:attr/textAppearanceLarge"
-            android:textColor="?android:attr/textColorTertiary"
-            android:focusable="true"
-        />
-
-        <TextView
-            style="?android:attr/listSeparatorTextViewStyle"
-            android:text="@string/listSeparatorTextViewStyle"
-            android:layout_marginTop="5dip"
-        />
-        
-    </LinearLayout>
-
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/custom_dialog_activity.xml b/samples/ApiDemos/res/layout/custom_dialog_activity.xml
deleted file mode 100644
index d706018..0000000
--- a/samples/ApiDemos/res/layout/custom_dialog_activity.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates an activity with a custom dialog theme.
-     See corresponding Java code com.android.sdk.app.CustomDialogActivity.java. -->
-
-<!-- This screen consists of a single text field that displays some text. -->
-<TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:gravity="center_vertical|center_horizontal"
-    android:text="@string/custom_dialog_activity_text"/>
diff --git a/samples/ApiDemos/res/layout/custom_title.xml b/samples/ApiDemos/res/layout/custom_title.xml
deleted file mode 100644
index dbe8cb6..0000000
--- a/samples/ApiDemos/res/layout/custom_title.xml
+++ /dev/null
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates how to use a custom title.
-     See corresponding Java code com.example.android.apis.app.CustomTitle.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:id="@+id/screen"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    <LinearLayout android:layout_width="fill_parent" 
-        android:layout_height="wrap_content"
-        android:baselineAligned="false">
-        <EditText android:id="@+id/left_text_edit"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:maxEms="10"
-            android:minEms="10"
-            android:layout_gravity="center_vertical"
-            android:text="@string/custom_title_left" />
-        <Button android:id="@+id/left_text_button"
-            android:layout_width="wrap_content" 
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical"
-            android:text="@string/custom_title_left_button"/>
-    </LinearLayout>
-    <LinearLayout android:layout_width="fill_parent" 
-        android:layout_height="wrap_content"
-        android:baselineAligned="false">
-        <EditText android:id="@+id/right_text_edit"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:maxEms="10"
-            android:minEms="10"
-            android:layout_gravity="center_vertical"
-            android:text="@string/custom_title_right" />
-        <Button android:id="@+id/right_text_button"
-            android:layout_width="wrap_content" 
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical"
-            android:text="@string/custom_title_right_button"/>
-    </LinearLayout>
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/custom_title_1.xml b/samples/ApiDemos/res/layout/custom_title_1.xml
deleted file mode 100644
index f794332..0000000
--- a/samples/ApiDemos/res/layout/custom_title_1.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates how to use a custom title.
-     See corresponding Java code com.example.android.apis.app.CustomTitle.java. -->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/screen"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-    <TextView android:id="@+id/left_text"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentLeft="true"
-        android:text="@string/custom_title_left" />
-    <TextView android:id="@+id/right_text"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentRight="true"
-        android:text="@string/custom_title_right" />
-</RelativeLayout>
diff --git a/samples/ApiDemos/res/layout/custom_view_1.xml b/samples/ApiDemos/res/layout/custom_view_1.xml
deleted file mode 100644
index cac91ad..0000000
--- a/samples/ApiDemos/res/layout/custom_view_1.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates defining custom views in a layout file. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-        xmlns:app="http://schemas.android.com/apk/res/com.example.android.apis"
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-    
-    <com.example.android.apis.view.LabelView
-            android:background="@drawable/red"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content" 
-            app:text="Red"/>
-    
-    <com.example.android.apis.view.LabelView
-            android:background="@drawable/blue"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content" 
-            app:text="Blue" app:textSize="20dp"/>
-    
-    <com.example.android.apis.view.LabelView
-            android:background="@drawable/green"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content" 
-            app:text="Green" app:textColor="#ffffffff" />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/date_widgets_example_1.xml b/samples/ApiDemos/res/layout/date_widgets_example_1.xml
deleted file mode 100644
index b9db6a0..0000000
--- a/samples/ApiDemos/res/layout/date_widgets_example_1.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:orientation="vertical">
-
-    <LinearLayout android:layout_width="wrap_content"
-            android:layout_height="wrap_content">
-        <TextView android:id="@+id/dateDisplay"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/date_widgets_example_dateDisplay_text"/>
-    </LinearLayout>
-
-    <Button android:id="@+id/pickDate"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/date_widgets_example_pickDate_text"/>
-
-    <Button android:id="@+id/pickTime"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/date_widgets_example_pickTime_text"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/date_widgets_example_2.xml b/samples/ApiDemos/res/layout/date_widgets_example_2.xml
deleted file mode 100644
index 50b182d..0000000
--- a/samples/ApiDemos/res/layout/date_widgets_example_2.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- example of using the time changed callback, with now visible 'set' button-->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:orientation="horizontal">
-
-    <TimePicker android:id="@+id/timePicker"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent"/>
-
-    <TextView android:id="@+id/dateDisplay"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:paddingLeft="4dip"
-            android:text="@string/date_widgets_example_dateDisplay_text"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/dialog_activity.xml b/samples/ApiDemos/res/layout/dialog_activity.xml
deleted file mode 100644
index 88c4b07..0000000
--- a/samples/ApiDemos/res/layout/dialog_activity.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates an activity with a dialog theme.
-     See corresponding Java code com.android.sdk.app.DialogActivity.java. -->
-
-<!-- This screen consists of a single text field that displays some text. -->
-<TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:gravity="center_vertical|center_horizontal"
-    android:text="@string/dialog_activity_text"/>
diff --git a/samples/ApiDemos/res/layout/focus_1.xml b/samples/ApiDemos/res/layout/focus_1.xml
deleted file mode 100644
index 12af0a9..0000000
--- a/samples/ApiDemos/res/layout/focus_1.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_height="wrap_content"
-    android:layout_width="fill_parent"
-    android:orientation="vertical">
-
-    <TextView android:id="@+id/txtStatus"
-        android:text="@string/focus_1_message"
-        android:layout_height="wrap_content"
-        android:layout_width="wrap_content" />
-
-    <ListView android:id="@+id/rssListView"
-        android:background="#7700CC00"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent" />
-
-   <WebView android:id="@+id/rssWebView"
-        android:background="#77CC0000"
-        android:layout_height="50dip"
-        android:layout_width="fill_parent"
-        android:focusable="false" />
-
-    <Button android:layout_height="wrap_content"
-        android:layout_width="wrap_content"
-        android:text="@string/focus_1_placeholder" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/focus_2.xml b/samples/ApiDemos/res/layout/focus_2.xml
deleted file mode 100644
index 6351de2..0000000
--- a/samples/ApiDemos/res/layout/focus_2.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_height="wrap_content"
-    android:layout_width="fill_parent"
-    android:orientation="horizontal">
-
-    <Button android:id="@+id/leftButton"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/focus_2_left"
-        android:nextFocusRight="@+id/rightButton"/>  <!-- jump over middle! -->
-
-    <Button android:id="@+id/centerButton"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/focus_2_jump" />
-
-    <Button android:id="@+id/rightButton"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="3dip"
-        android:text="@string/focus_2_right"/>
-    
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/focus_3.xml b/samples/ApiDemos/res/layout/focus_3.xml
deleted file mode 100644
index f08c3f8..0000000
--- a/samples/ApiDemos/res/layout/focus_3.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using nextLeft, nextRight, nextUp and nextDown to get
-     focus behavior that would be difficult with default focus calculation alg.-->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:padding="10dip">
-
-    <Button android:id="@+id/top"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentTop="true"
-        android:layout_centerHorizontal="true"
-        android:nextFocusDown="@+id/bottom"
-        android:text="@string/focus_3_top"/>
-
-    <Button android:id="@+id/right"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentRight="true"
-        android:layout_centerVertical="true"
-        android:nextFocusLeft="@+id/left"
-        android:text="@string/focus_3_right"/>
-
-    <Button android:id="@+id/bottom"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentBottom="true"
-        android:layout_centerHorizontal="true"
-        android:nextFocusUp="@+id/top"
-        android:text="@string/focus_3_bottom"/>
-
-    <Button android:id="@+id/left"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentLeft="true"
-        android:layout_centerVertical="true"
-        android:nextFocusRight="@+id/right"
-        android:text="@string/focus_3_left"/>
-
-</RelativeLayout>
-
-
-
-
-
-
-
diff --git a/samples/ApiDemos/res/layout/forward_target.xml b/samples/ApiDemos/res/layout/forward_target.xml
deleted file mode 100644
index 6d56ae2..0000000
--- a/samples/ApiDemos/res/layout/forward_target.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates receiving activity results.
-     See corresponding Java code com.android.sdk.app.ReceiveResult.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:text="@string/forward_target"/>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/forwarding.xml b/samples/ApiDemos/res/layout/forwarding.xml
deleted file mode 100644
index a860d88..0000000
--- a/samples/ApiDemos/res/layout/forwarding.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates receiving activity results.
-     See corresponding Java code com.android.sdk.app.ReceiveResult.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/forwarding"/>
-
-    <Button android:id="@+id/go"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/go">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/gadget_configure.xml b/samples/ApiDemos/res/layout/gadget_configure.xml
deleted file mode 100644
index bc9f40d..0000000
--- a/samples/ApiDemos/res/layout/gadget_configure.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:orientation="vertical"
-    >
-
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/gadget_configure_instructions"
-    />
-
-    <EditText
-        android:id="@+id/gadget_prefix"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-    />
-
-    <Button
-        android:id="@+id/save_button"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@android:string/ok"
-    />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/gadget_provider.xml b/samples/ApiDemos/res/layout/gadget_provider.xml
deleted file mode 100644
index 49cf42f..0000000
--- a/samples/ApiDemos/res/layout/gadget_provider.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/gadget_text"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:textColor="#ff000000"
-/>
-
diff --git a/samples/ApiDemos/res/layout/gallery_1.xml b/samples/ApiDemos/res/layout/gallery_1.xml
deleted file mode 100644
index 40f3443..0000000
--- a/samples/ApiDemos/res/layout/gallery_1.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<Gallery xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/gallery"
-	android:layout_width="fill_parent"
-	android:layout_height="wrap_content"
-/>
-       
diff --git a/samples/ApiDemos/res/layout/gallery_2.xml b/samples/ApiDemos/res/layout/gallery_2.xml
deleted file mode 100644
index 37e5d11..0000000
--- a/samples/ApiDemos/res/layout/gallery_2.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="center_vertical"
-        android:layout_marginBottom="10dip"
-        android:text="@string/gallery_2_text"
-    />
-
-    <Gallery android:id="@+id/gallery"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:gravity="center_vertical"
-        android:spacing="16dp"
-    />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/google_login.xml b/samples/ApiDemos/res/layout/google_login.xml
deleted file mode 100644
index 9ab2f62..0000000
--- a/samples/ApiDemos/res/layout/google_login.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates styled string resources.
-     See corresponding Java code com.android.sdk.content.StyledText -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <Button
-        android:id="@+id/login"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/googlelogin_login"
-        />
-
-    <Button
-        android:id="@+id/bad_login"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/googlelogin_bad_login"
-        />
-
-    <Button
-        android:id="@+id/clear"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/googlelogin_clear"
-        />
-
-    <TextView
-        android:id="@+id/username_label"
-        android:visibility="gone"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/googlelogin_user"/>
-
-    <TextView
-        android:id="@+id/username"
-        android:visibility="gone"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/google_login_username_text"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/grid_1.xml b/samples/ApiDemos/res/layout/grid_1.xml
deleted file mode 100644
index ca60320..0000000
--- a/samples/ApiDemos/res/layout/grid_1.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/myGrid"
-	android:layout_width="fill_parent" 
-	android:layout_height="fill_parent"
-    android:padding="10dp"
-    android:verticalSpacing="10dp"
-    
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-    
-    android:gravity="center"
-    />
diff --git a/samples/ApiDemos/res/layout/grid_2.xml b/samples/ApiDemos/res/layout/grid_2.xml
deleted file mode 100644
index 4640ab6..0000000
--- a/samples/ApiDemos/res/layout/grid_2.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:id="@+id/myGrid"
-	android:layout_width="fill_parent" 
-	android:layout_height="fill_parent"
-    android:padding="10dp"
-    android:verticalSpacing="10dp"
-    
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-    
-    android:gravity="center"
-    />
diff --git a/samples/ApiDemos/res/layout/hello_world.xml b/samples/ApiDemos/res/layout/hello_world.xml
deleted file mode 100644
index 364a83a..0000000
--- a/samples/ApiDemos/res/layout/hello_world.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates basic application screen.
-     See corresponding Java code com.android.sdk.app.HelloWorld.java. -->
-
-<!-- This screen consists of a single text field that
-     displays our "Hello, World!" text. -->
-<TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:gravity="center_vertical|center_horizontal"
-    android:text="@string/hello_world"/>
diff --git a/samples/ApiDemos/res/layout/image_button_1.xml b/samples/ApiDemos/res/layout/image_button_1.xml
deleted file mode 100644
index 114163e..0000000
--- a/samples/ApiDemos/res/layout/image_button_1.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <ImageButton
-    	android:layout_width="100dip"
-    	android:layout_height="50dip"
-    	android:src="@android:drawable/sym_action_call" />
-    	
-   	<ImageButton
-    	android:layout_width="wrap_content"
-    	android:layout_height="wrap_content"
-    	android:src="@android:drawable/sym_action_chat" />	
-    	
-   	<ImageButton
-    	android:layout_width="wrap_content"
-    	android:layout_height="wrap_content"
-    	android:src="@android:drawable/sym_action_email" />	
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/image_switcher_1.xml b/samples/ApiDemos/res/layout/image_switcher_1.xml
deleted file mode 100644
index d9cd080..0000000
--- a/samples/ApiDemos/res/layout/image_switcher_1.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"> 
-    
-    <ImageSwitcher android:id="@+id/switcher"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:layout_alignParentTop="true"
-        android:layout_alignParentLeft="true"
-    />
-    
-    <Gallery android:id="@+id/gallery"
-        android:background="#55000000"
-        android:layout_width="fill_parent"
-        android:layout_height="60dp"
-        android:layout_alignParentBottom="true"
-        android:layout_alignParentLeft="true"
-        
-        android:gravity="center_vertical"
-        android:spacing="16dp"
-    />
-
-</RelativeLayout>
-   
diff --git a/samples/ApiDemos/res/layout/image_view_1.xml b/samples/ApiDemos/res/layout/image_view_1.xml
deleted file mode 100644
index 36b926d..0000000
--- a/samples/ApiDemos/res/layout/image_view_1.xml
+++ /dev/null
@@ -1,144 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:orientation="vertical">
-        
-        <!-- The following four examples use a large image -->
-        <!-- 1. Non-scaled view, for reference -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_large_normal"/>
-        <ImageView
-            android:src="@drawable/sample_1"
-            android:adjustViewBounds="true"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-        <!-- 2. Limit to at most 50x50 -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_large_at_most"/>
-        <ImageView
-            android:src="@drawable/sample_1"
-            android:adjustViewBounds="true"
-            android:maxWidth="50dip"
-            android:maxHeight="50dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-
-       <!-- 3. Limit to at most 70x70, with 10 pixels of padding all around -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_large_at_most_padded"/>
-       <ImageView
-            android:src="@drawable/sample_1"
-            android:background="#66FFFFFF"
-            android:adjustViewBounds="true"
-            android:maxWidth="70dip"
-            android:maxHeight="70dip"
-            android:padding="10dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-        <!-- 4. Limit to exactly 70x70, with 10 pixels of padding all around -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_large_exactly_padded"/>
-        <ImageView
-            android:src="@drawable/sample_1"
-            android:background="#66FFFFFF"
-            android:scaleType="centerInside"
-            android:padding="10dip"
-            android:layout_width="70dip"
-            android:layout_height="70dip" />
-
-        <!-- Repeating the previous four examples with small image -->
-        <!-- 1. Non-scaled view, for reference -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_small_normal"/>
-        <ImageView
-            android:src="@drawable/stat_happy"
-            android:background="#FFFFFFFF"
-            android:adjustViewBounds="true"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-        <!-- 2. Limit to at most 50x50 -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_small_at_most"/>
-        <ImageView
-            android:src="@drawable/stat_happy"
-            android:background="#FFFFFFFF"
-            android:adjustViewBounds="true"
-            android:maxWidth="50dip"
-            android:maxHeight="50dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-
-       <!-- 3. Limit to at most 70x70, with 10 pixels of padding all around -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_small_at_most_padded"/>
-        <ImageView
-            android:src="@drawable/stat_happy"
-            android:background="#FFFFFFFF"
-            android:adjustViewBounds="true"
-            android:maxWidth="70dip"
-            android:maxHeight="70dip"
-            android:padding="10dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-        <!-- 4. Limit to exactly 70x70, with 10 pixels of padding all around -->
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="10dip"
-            android:text="@string/image_view_small_exactly_padded"/>
-        <ImageView
-            android:src="@drawable/stat_happy"
-            android:background="#FFFFFFFF"
-            android:scaleType="centerInside"
-            android:padding="10dip"
-            android:layout_width="70dip"
-            android:layout_height="70dip" />
-
- 
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/incoming_message.xml b/samples/ApiDemos/res/layout/incoming_message.xml
deleted file mode 100644
index 01ea04a..0000000
--- a/samples/ApiDemos/res/layout/incoming_message.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <Button
-        android:id="@+id/notify"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/incoming_message_notify_text" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/incoming_message_info.xml b/samples/ApiDemos/res/layout/incoming_message_info.xml
deleted file mode 100644
index 723a4da..0000000
--- a/samples/ApiDemos/res/layout/incoming_message_info.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-		<ImageView
-			android:layout_width="wrap_content"
-			android:layout_height="wrap_content"
-			android:src="@drawable/sample_thumb_2"
-            />
-
-        <TextView
-            android:id="@+id/message"
-            android:layout_gravity="center_vertical"
-			android:layout_width="wrap_content"
-			android:layout_height="wrap_content"
-            android:paddingLeft="6dip"
-            android:text="@string/incoming_message_info_message_text"
-            />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/incoming_message_panel.xml b/samples/ApiDemos/res/layout/incoming_message_panel.xml
deleted file mode 100644
index 3120e4e..0000000
--- a/samples/ApiDemos/res/layout/incoming_message_panel.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:background="@android:drawable/toast_frame">
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-            <ImageView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:src="@drawable/sample_thumb_2"
-                />
-
-            <TextView
-                android:id="@+id/message"
-                android:layout_gravity="center_vertical"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:paddingLeft="6dip"
-                />
-
-    </LinearLayout>
-</FrameLayout>
diff --git a/samples/ApiDemos/res/layout/incoming_message_view.xml b/samples/ApiDemos/res/layout/incoming_message_view.xml
deleted file mode 100644
index b286e6e..0000000
--- a/samples/ApiDemos/res/layout/incoming_message_view.xml
+++ /dev/null
@@ -1,59 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:paddingLeft="4dip"
-    android:paddingRight="4dip"
-    android:paddingTop="4dip"
-    >
-
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            >
-
-                <ImageView
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:src="@drawable/sample_thumb_2"
-                    />
-
-                <TextView
-                    android:id="@+id/message"
-                    android:layout_gravity="center_vertical"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:paddingLeft="6dip"
-                    android:text="@string/incoming_message_view_message_text"
-                    />
-
-        </LinearLayout>
-
-        <TextView
-            android:id="@+id/message"
-            android:layout_gravity="center_vertical"
-			android:layout_width="wrap_content"
-			android:layout_height="wrap_content"
-            android:paddingTop="12dip"
-            android:text="@string/imcoming_message_view_message2_text"
-            />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/intents.xml b/samples/ApiDemos/res/layout/intents.xml
deleted file mode 100644
index 023e4e8..0000000
--- a/samples/ApiDemos/res/layout/intents.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates launching various intents.
-     See corresponding Java code com.example.android.apis.app.Intents.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/intents"/>
-
-    <Button android:id="@+id/get_music"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/get_music">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/launcher_shortcuts.xml b/samples/ApiDemos/res/layout/launcher_shortcuts.xml
deleted file mode 100644
index c8fbb2a..0000000
--- a/samples/ApiDemos/res/layout/launcher_shortcuts.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This activity provides information about launcher shortcuts -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <!--  Section: Information -->
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingBottom="4dip"
-        android:text="@string/msg_launcher_shortcuts" />
-    
-    <!--  Section: The intent that launched this Activity -->
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/label_intent" />
-    <TextView android:id="@+id/txt_shortcut_intent"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" />
-
- </LinearLayout>
diff --git a/samples/ApiDemos/res/layout/layout_animation_1.xml b/samples/ApiDemos/res/layout/layout_animation_1.xml
deleted file mode 100644
index 2b25485..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_1.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/grid"
-    android:layoutAnimation="@anim/layout_grid_fade"
-
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:padding="10dp"
-    android:verticalSpacing="10dp"
-
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-
-    android:gravity="center" />
diff --git a/samples/ApiDemos/res/layout/layout_animation_3.xml b/samples/ApiDemos/res/layout/layout_animation_3.xml
deleted file mode 100644
index 051fa8e..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_3.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ListView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@android:id/list"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:layoutAnimation="@anim/layout_bottom_to_top_slide" />
diff --git a/samples/ApiDemos/res/layout/layout_animation_4.xml b/samples/ApiDemos/res/layout/layout_animation_4.xml
deleted file mode 100644
index 73b99b0..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_4.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/grid"
-    android:layoutAnimation="@anim/layout_random_fade"
-
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:padding="10dp"
-    android:verticalSpacing="10dp"
-
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-
-    android:gravity="center" />
diff --git a/samples/ApiDemos/res/layout/layout_animation_5.xml b/samples/ApiDemos/res/layout/layout_animation_5.xml
deleted file mode 100644
index 602fb18..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_5.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/grid"
-    android:layoutAnimation="@anim/layout_grid_inverse_fade"
-
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:padding="10dp"
-    android:verticalSpacing="10dp"
-
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-
-    android:gravity="center" />
diff --git a/samples/ApiDemos/res/layout/layout_animation_6.xml b/samples/ApiDemos/res/layout/layout_animation_6.xml
deleted file mode 100644
index 026797e..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_6.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<GridView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/grid"
-    android:layoutAnimation="@anim/layout_wave_scale"
-
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:verticalSpacing="10dp"
-
-    android:horizontalSpacing="10dp"
-    android:numColumns="auto_fit"
-    android:columnWidth="60dp"
-    android:stretchMode="columnWidth"
-
-    android:gravity="center" />
diff --git a/samples/ApiDemos/res/layout/layout_animation_7.xml b/samples/ApiDemos/res/layout/layout_animation_7.xml
deleted file mode 100644
index 38260c7..0000000
--- a/samples/ApiDemos/res/layout/layout_animation_7.xml
+++ /dev/null
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layoutAnimation="@anim/layout_animation_table"
-    android:animationCache="false"
-    android:clipToPadding="false"
-    android:padding="12dp"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:stretchColumns="1">
-
-    <TableRow
-        android:layoutAnimation="@anim/layout_animation_row_right_slide">
-        <TextView
-            android:gravity="right"
-            android:text="@string/layout_animation_name" />
-        <EditText />
-    </TableRow>
-
-    <TableRow
-        android:layoutAnimation="@anim/layout_animation_row_left_slide">
-        <TextView
-            android:gravity="right"
-            android:text="@string/layout_animation_lastname" />
-        <EditText />
-    </TableRow>
-
-    <TableRow
-        android:layoutAnimation="@anim/layout_animation_row_right_slide">
-        <TextView
-            android:gravity="right"
-            android:text="@string/layout_animation_phone" />
-        <EditText />
-    </TableRow>
-
-    <TableRow
-        android:layoutAnimation="@anim/layout_animation_row_left_slide">
-        <TextView
-            android:gravity="right"
-            android:text="@string/layout_animation_address" />
-        <EditText android:lines="3" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_1.xml b/samples/ApiDemos/res/layout/linear_layout_1.xml
deleted file mode 100644
index ef01ced..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_1.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates a simple linear layout. The height of the layout is the sum of its children. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:background="@drawable/blue"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <!-- view1 goes on top -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_1_top"/>
-
-    <!-- view2 goes in the middle -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_1_middle"/>
-
-    <!-- view3 goes on the bottom -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_1_bottom"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_10.xml b/samples/ApiDemos/res/layout/linear_layout_10.xml
deleted file mode 100644
index eb793fd..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_10.xml
+++ /dev/null
@@ -1,122 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using a LinearLayout background to group related
-     TextViews, EditTexts, and Buttons. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:orientation="vertical">
-
-    <!-- Top label/button text field. -->
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:addStatesFromChildren="true"
-        android:gravity="center_vertical"
-        android:paddingRight="0dip"
-        android:background="@android:drawable/edit_text">
-
-        <!--
-            TextView label goes at the left.
-        -->
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/linear_layout_10_from"
-            android:textColor="?android:attr/textColorSecondary"
-            android:textAppearance="?android:attr/textAppearanceLargeInverse"
-        />
-
-        <!--
-            EditText goes in between.
-        -->
-        <EditText
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            android:singleLine="true"
-            android:background="@null"
-        />
-
-        <!--
-            The button goes at the right.
-        -->
-        <ImageButton
-            style="@android:style/Widget.Button.Inset"
-            android:src="@android:drawable/star_big_on"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="2dip"
-            android:layout_marginRight="2dip"
-            android:layout_marginBottom="2dip"
-            android:padding="10dip"
-        />
-
-    </LinearLayout>
-
-    <!-- Bottom label/button text field.  (Identical to the top one
-         except for the label.)  -->
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:addStatesFromChildren="true"
-        android:gravity="center_vertical"
-        android:paddingRight="0dip"
-        android:background="@android:drawable/edit_text">
-
-        <!--
-            TextView label goes at the left.
-        -->
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/linear_layout_10_to"
-            android:textColor="?android:attr/textColorSecondary"
-            android:textAppearance="?android:attr/textAppearanceLargeInverse"
-        />
-
-        <!--
-            EditText goes in between.
-        -->
-        <EditText
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            android:singleLine="true"
-            android:background="@null"
-        />
-
-        <!--
-            The button goes at the right.
-        -->
-        <ImageButton
-            style="@android:style/Widget.Button.Inset"
-            android:src="@android:drawable/star_big_on"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="2dip"
-            android:layout_marginRight="2dip"
-            android:layout_marginBottom="2dip"
-            android:padding="10dip"
-        />
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_2.xml b/samples/ApiDemos/res/layout/linear_layout_2.xml
deleted file mode 100644
index 3cacccc..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_2.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates a simple linear layout. The layout fills the screen, with the children stacked from the top. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:background="@drawable/blue"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <!-- view1 goes on top -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_2_top"/>
-
-    <!-- view2 goes in the middle -->
-    <TextView
-       android:background="@drawable/box"
-       android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_2_middle"/>
-
-    <!-- view3 goes on the bottom -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_2_bottom"/>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/linear_layout_3.xml b/samples/ApiDemos/res/layout/linear_layout_3.xml
deleted file mode 100644
index 2b9b327..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_3.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a simple linear layout. The layout fills the screen, with the
-    children stacked from the top. The middle child gets allocated any extra
-    space.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:background="@drawable/blue"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <!-- view1 goes on top -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_3_top"/>
-
-    <!-- view2 goes in the middle -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:text="@string/linear_layout_3_middle"/>
-
-    <!-- view3 goes on the bottom -->
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_3_bottom"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_4.xml b/samples/ApiDemos/res/layout/linear_layout_4.xml
deleted file mode 100644
index 139fb57..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_4.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a horizontal linear layout with equally sized columns
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:background="@drawable/red"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"/>
-
-    <TextView
-        android:background="@drawable/green"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"/>
-
-    <TextView
-        android:background="@drawable/blue"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"/>
-
-    <TextView
-        android:background="@drawable/yellow"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_5.xml b/samples/ApiDemos/res/layout/linear_layout_5.xml
deleted file mode 100644
index 832a103..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_5.xml
+++ /dev/null
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a nesting layouts to make a form
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:background="@drawable/blue"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:padding="10dip">
-
-    <!--
-        TextView goes on top...
-    -->
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_5_instructions"/>
-
-    <!--
-        Followed by the EditText field...
-
-        Also give it a standard background (the "android:"
-        part in @android:drawable/editbox_background
-        means it is system resource rather than
-        an application resource.
-    -->
-    <EditText
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:background="@android:drawable/editbox_background"/>
-
-    <!--
-        Use a horizontal layout to hold the two buttons.
-        This item has layout_gravity="right". This means the whole
-        horizontal LinearLayout is right aligned, not the individual
-        items within it. The horizontal LinearLayout's width is set to
-        wrap_content. (If it was fill_parent it would not have any
-        room to slide to the right.)
-    -->
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="right" >
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/linear_layout_5_cancel"/>
-
-        <Button
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginLeft="10dip"
-            android:text="@string/linear_layout_5_ok" />
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_6.xml b/samples/ApiDemos/res/layout/linear_layout_6.xml
deleted file mode 100644
index f4bb6a7..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_6.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    LinearLayout which uses a combination of wrap_content on itself and
-    fill_parent on its children to get every item to be the same width.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:background="@drawable/blue"
-    android:padding="20dip"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_6_one"/>
-
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_6_two"/>
-
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_6_three"/>
-
-    <TextView
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_6_four"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_7.xml b/samples/ApiDemos/res/layout/linear_layout_7.xml
deleted file mode 100644
index 19b22e5..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_7.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a horizontal linear layout with equally sized columns.
-    Some columns force their height to match the parent.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:background="@drawable/red"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"
-        android:text="@string/linear_layout_7_small"/>
-
-    <TextView
-        android:background="@drawable/green"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"
-        android:text="@string/linear_layout_7_big"/>
-
-    <TextView
-        android:background="@drawable/blue"
-        android:layout_width="0dip"
-        android:layout_height="fill_parent"
-        android:layout_weight="1"
-        android:text="@string/linear_layout_7_small" />
-
-    <TextView
-        android:background="@drawable/yellow"
-        android:layout_width="0dip"
-        android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:text="@string/linear_layout_7_wrap"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_8.xml b/samples/ApiDemos/res/layout/linear_layout_8.xml
deleted file mode 100644
index f226043..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_8.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a simple linear layout. The layout fills the screen, with the
-    children stacked from the top.
-    -->
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:padding="30dip">
-  <LinearLayout
-      android:id="@+id/layout"
-      android:orientation="vertical"
-      android:background="@drawable/blue"
-      android:layout_width="fill_parent"
-      android:layout_height="fill_parent"
-      android:padding="30dip">
-
-    <TextView
-	android:background="@drawable/box"
-	android:layout_width="wrap_content"
-	android:layout_height="wrap_content"
-	android:text="@string/linear_layout_8_c"/>
-
-    <TextView
-	android:background="@drawable/box"
-	android:layout_width="wrap_content"
-	android:layout_height="wrap_content"
-	android:text="@string/linear_layout_8_b"/>
-
-    <TextView
-	android:background="@drawable/box"
-	android:layout_width="wrap_content"
-	android:layout_height="wrap_content"
-	android:text="@string/linear_layout_8_c"/>
-
-  </LinearLayout>
-
-</FrameLayout>
diff --git a/samples/ApiDemos/res/layout/linear_layout_9.xml b/samples/ApiDemos/res/layout/linear_layout_9.xml
deleted file mode 100644
index eb91147..0000000
--- a/samples/ApiDemos/res/layout/linear_layout_9.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates a simple linear layout. The layout fills the screen, with the
-    children stacked from the top.
-    -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <ListView android:id="@+id/list"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_weight="1.0" />
-
-    <Button
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/linear_layout_9_button" />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/link.xml b/samples/ApiDemos/res/layout/link.xml
deleted file mode 100644
index a65d000..0000000
--- a/samples/ApiDemos/res/layout/link.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:orientation="vertical"
-              android:layout_width="fill_parent"
-              android:layout_height="wrap_content">
-
-  <!-- Four TextView widgets, each one displaying text containing links. -->
-
-  <!-- text1 automatically linkifies things like URLs and phone numbers. -->
-  <TextView xmlns:android="http://schemas.android.com/apk/res/android"
-            android:id="@+id/text1"
-            android:layout_width="fill_parent"
-            android:layout_height="fill_parent"
-            android:autoLink="all"
-            android:text="@string/link_text_auto"
-            />
-
-  <!-- text2 uses a string resource containing explicit <a> tags to
-       specify links. -->
-  <TextView xmlns:android="http://schemas.android.com/apk/res/android"
-            android:id="@+id/text2"
-            android:layout_width="fill_parent"
-            android:layout_height="fill_parent"
-            android:text="@string/link_text_manual"
-            />
-
-  <!-- text3 builds the text in the Java code using HTML. -->
-  <TextView xmlns:android="http://schemas.android.com/apk/res/android"
-            android:id="@+id/text3"
-            android:layout_width="fill_parent"
-            android:layout_height="fill_parent"
-            />
-
-  <!-- text4 builds the text in the Java code without using HTML. -->
-  <TextView xmlns:android="http://schemas.android.com/apk/res/android"
-            android:id="@+id/text4"
-            android:layout_width="fill_parent"
-            android:layout_height="fill_parent"
-            />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_12.xml b/samples/ApiDemos/res/layout/list_12.xml
deleted file mode 100644
index 7f19b58..0000000
--- a/samples/ApiDemos/res/layout/list_12.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-    android:paddingLeft="8dip"
-    android:paddingRight="8dip">
-    
-    <ListView android:id="@android:id/list"
-        android:layout_width="fill_parent" 
-        android:layout_height="0dip"
-        android:layout_weight="1"
-        android:stackFromBottom="true"
-        android:transcriptMode="normal"/>
-        
-    <EditText android:id="@+id/userText"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content" />
-        
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_13.xml b/samples/ApiDemos/res/layout/list_13.xml
deleted file mode 100644
index 681b46e..0000000
--- a/samples/ApiDemos/res/layout/list_13.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent">
-    
-    <ListView android:id="@android:id/list"
-        android:layout_width="fill_parent" 
-        android:layout_height="0dip"
-        android:layout_weight="1"
-        android:drawSelectorOnTop="false"/>
-        
-    <TextView android:id="@+id/status"
-        android:layout_width="fill_parent" 
-        android:layout_height="wrap_content"
-        android:paddingLeft="8dip"
-        android:paddingRight="8dip"/>
-        
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_7.xml b/samples/ApiDemos/res/layout/list_7.xml
deleted file mode 100644
index 2dc7777..0000000
--- a/samples/ApiDemos/res/layout/list_7.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-	android:orientation="vertical"
-	android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-	android:paddingLeft="8dip"
-	android:paddingRight="8dip">
-	
-	<ListView android:id="@android:id/list"
-	    android:layout_width="fill_parent" 
-	    android:layout_height="0dip"
-	    android:layout_weight="1"
-	    android:drawSelectorOnTop="false"/>
-	    
-    <TextView android:id="@+id/phone"
-    	android:layout_width="fill_parent" 
-    	android:layout_height="wrap_content"
-    	android:background="@drawable/blue"/>
-    	
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_8.xml b/samples/ApiDemos/res/layout/list_8.xml
deleted file mode 100644
index a88b67c..0000000
--- a/samples/ApiDemos/res/layout/list_8.xml
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent">
-    
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent" 
-        android:layout_height="wrap_content">
-        
-        <Button android:id="@+id/add"
-            android:layout_width="wrap_content" 
-            android:layout_height="wrap_content"
-            android:text="@string/list_8_new_photo"/>
-            
-        <Button android:id="@+id/clear"
-            android:layout_width="wrap_content" 
-            android:layout_height="wrap_content"
-            android:text="@string/list_8_clear_photos"/>
-            
-    </LinearLayout>
-    
-    <!-- The frame layout is here since we will be showing either
-    the empty view or the list view.  -->
-    <FrameLayout
-        android:layout_width="fill_parent" 
-        android:layout_height="0dip"
-        android:layout_weight="1" >
-        <!-- Here is the list. Since we are using a ListActivity, we
-             have to call it "@android:id/list" so ListActivity will
-             find it -->
-        <ListView android:id="@android:id/list"
-            android:layout_width="fill_parent" 
-            android:layout_height="fill_parent"
-            android:drawSelectorOnTop="false"/>
-        
-        <!-- Here is the view to show if the list is emtpy -->
-        <TextView android:id="@+id/empty"
-            android:layout_width="fill_parent" 
-            android:layout_height="fill_parent"
-            android:text="@string/list_8_no_photos"/>
-            
-    </FrameLayout>
-        
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_item_checkbox.xml b/samples/ApiDemos/res/layout/list_item_checkbox.xml
deleted file mode 100644
index fa1d2d8..0000000
--- a/samples/ApiDemos/res/layout/list_item_checkbox.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<CheckBox xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@android:id/text1"
-    android:layout_width="fill_parent"
-    android:layout_height="?android:attr/listPreferredItemHeight"
-    android:textAppearance="?android:attr/textAppearanceLarge"
-/>
diff --git a/samples/ApiDemos/res/layout/list_item_icon_text.xml b/samples/ApiDemos/res/layout/list_item_icon_text.xml
deleted file mode 100644
index 7206c04..0000000
--- a/samples/ApiDemos/res/layout/list_item_icon_text.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <ImageView android:id="@+id/icon"
-        android:layout_width="48dip"
-        android:layout_height="48dip" />
-
-    <TextView android:id="@+id/text"
-        android:layout_gravity="center_vertical"
-        android:layout_width="0dip"
-        android:layout_weight="1.0"
-        android:layout_height="wrap_content" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/list_position.xml b/samples/ApiDemos/res/layout/list_position.xml
deleted file mode 100644
index a82f6bc..0000000
--- a/samples/ApiDemos/res/layout/list_position.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:textSize="50sp"
-    android:textColor="#99FFFFFF"
-    android:background="#BB000000"
-    android:minWidth="70dip"
-    android:maxWidth="70dip"
-    android:padding="10dip"
-    android:gravity="center"
-/>
diff --git a/samples/ApiDemos/res/layout/local_sample.xml b/samples/ApiDemos/res/layout/local_sample.xml
deleted file mode 100644
index e662921..0000000
--- a/samples/ApiDemos/res/layout/local_sample.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Front-end for running application instrumentation demonstration.
-     See corresponding Java code com.android.sdk.app.LocalSample.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/local_sample"/>
-
-    <Button android:id="@+id/go"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/go">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/local_service_binding.xml b/samples/ApiDemos/res/layout/local_service_binding.xml
deleted file mode 100644
index 775b8fb..0000000
--- a/samples/ApiDemos/res/layout/local_service_binding.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/local_service_binding"/>
-
-    <Button android:id="@+id/bind"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/bind_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/unbind"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/unbind_service">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/local_service_controller.xml b/samples/ApiDemos/res/layout/local_service_controller.xml
deleted file mode 100644
index 7bb02ca..0000000
--- a/samples/ApiDemos/res/layout/local_service_controller.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/local_service_controller"/>
-
-    <Button android:id="@+id/start"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/stop"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/stop_service">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/log_text_box_1.xml b/samples/ApiDemos/res/layout/log_text_box_1.xml
deleted file mode 100644
index f06619d..0000000
--- a/samples/ApiDemos/res/layout/log_text_box_1.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout
-    xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <Button
-        android:id="@+id/add"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/log_text_box_1_add_text"/>
-
-    <com.example.android.apis.text.LogTextBox
-        android:id="@+id/text"
-        android:background="@drawable/box"
-        android:layout_width="fill_parent"
-        android:layout_height="0dip"
-        android:layout_weight="1"
-        android:scrollbars="vertical"/>
-
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/log_text_box_1_do_nothing_text"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/mapview.xml b/samples/ApiDemos/res/layout/mapview.xml
deleted file mode 100644
index 97ef7ff..0000000
--- a/samples/ApiDemos/res/layout/mapview.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates use of the com.google.android.maps.MapView.
-     See corresponding Java code com.example.android.apis.view.MapViewDemo.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/main"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent">
-    <com.google.android.maps.MapView
-        android:layout_width="fill_parent" 
-        android:layout_height="fill_parent"
-        android:enabled="true"
-        android:clickable="true"
-        android:apiKey="apisamples"
-        />
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/marquee.xml b/samples/ApiDemos/res/layout/marquee.xml
deleted file mode 100644
index 6d40c84..0000000
--- a/samples/ApiDemos/res/layout/marquee.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 
- * Copyright (C) 2008 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent">
-    
-    <Button
-        android:layout_width="150dip" 
-        android:layout_height="wrap_content"
-        android:text="@string/marquee_default"
-        android:singleLine="true"
-        android:ellipsize="marquee"/>
-        
-    <Button
-        android:layout_width="150dip" 
-        android:layout_height="wrap_content"
-        android:text="@string/marquee_once"
-        android:singleLine="true"
-        android:ellipsize="marquee"
-        android:marqueeRepeatLimit="1"/>
-        
-    <Button
-        android:layout_width="150dip" 
-        android:layout_height="wrap_content"
-        android:text="@string/marquee_forever"
-        android:singleLine="true"
-        android:ellipsize="marquee"
-        android:marqueeRepeatLimit="marquee_forever"/>  
-           
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/mediaplayer_1.xml b/samples/ApiDemos/res/layout/mediaplayer_1.xml
deleted file mode 100644
index 16ae61b..0000000
--- a/samples/ApiDemos/res/layout/mediaplayer_1.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    >
-    <Button android:id="@+id/localvideo"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent" 
-        android:text="@string/local_video" 
-    />
-    
-    <Button android:id="@+id/streamvideo"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent" 
-        android:text="@string/stream_video" 
-    />
-    
-    <Button android:id="@+id/localaudio"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent" 
-        android:text="@string/local_audio" 
-    />
-    
-    <Button android:id="@+id/resourcesaudio"
-        android:layout_height="wrap_content"
-        android:layout_width="fill_parent" 
-        android:text="@string/res_audio" 
-    />
-    
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/mediaplayer_2.xml b/samples/ApiDemos/res/layout/mediaplayer_2.xml
deleted file mode 100644
index e1e49dd..0000000
--- a/samples/ApiDemos/res/layout/mediaplayer_2.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <SurfaceView android:id="@+id/surface"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="center">
-    </SurfaceView>
-  
-</LinearLayout>
\ No newline at end of file
diff --git a/samples/ApiDemos/res/layout/morse_code.xml b/samples/ApiDemos/res/layout/morse_code.xml
deleted file mode 100644
index f536da2..0000000
--- a/samples/ApiDemos/res/layout/morse_code.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This activity exercises search invocation options -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <EditText
-        android:id="@+id/text"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingBottom="4dip"
-        />
-    
-    <Button
-        android:id="@+id/button"
-        android:text="@string/vibrate"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/notify_with_text.xml b/samples/ApiDemos/res/layout/notify_with_text.xml
deleted file mode 100644
index 6cba90d..0000000
--- a/samples/ApiDemos/res/layout/notify_with_text.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <Button
-        android:id="@+id/short_notify"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/notify_with_text_short_notify_text" />
-
-    <Button
-        android:id="@+id/long_notify"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/notify_with_text_long_notify_text" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/notifying_controller.xml b/samples/ApiDemos/res/layout/notifying_controller.xml
deleted file mode 100644
index 54cef17..0000000
--- a/samples/ApiDemos/res/layout/notifying_controller.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/notifying_service_controller"/>
-
-    <Button android:id="@+id/notifyStart"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/notifyStop"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/stop_service">
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/preference_widget_mypreference.xml b/samples/ApiDemos/res/layout/preference_widget_mypreference.xml
deleted file mode 100644
index 20c0d56..0000000
--- a/samples/ApiDemos/res/layout/preference_widget_mypreference.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Custom preference type using a text view. -->
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/mypreference_widget" 
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:layout_gravity="center_vertical"
-    android:layout_marginRight="6sp"
-    android:focusable="false"
-    android:clickable="false" />
diff --git a/samples/ApiDemos/res/layout/progressbar_1.xml b/samples/ApiDemos/res/layout/progressbar_1.xml
deleted file mode 100644
index 0383de9..0000000
--- a/samples/ApiDemos/res/layout/progressbar_1.xml
+++ /dev/null
@@ -1,74 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <ProgressBar android:id="@+id/progress_horizontal"
-        style="?android:attr/progressBarStyleHorizontal"
-        android:layout_width="200dip"
-        android:layout_height="wrap_content"
-        android:max="100"
-        android:progress="50"
-        android:secondaryProgress="75" />
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/progressbar_1_default_progress" />        
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <Button android:id="@+id/decrease"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/progressbar_1_minus" />
-
-        <Button android:id="@+id/increase"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/progressbar_1_plus" />
-
-    </LinearLayout>
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/progressbar_1_secondary_progress" />        
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <Button android:id="@+id/decrease_secondary"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/progressbar_1_minus" />
-
-        <Button android:id="@+id/increase_secondary"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/progressbar_1_plus" />
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/progressbar_2.xml b/samples/ApiDemos/res/layout/progressbar_2.xml
deleted file mode 100644
index 2d43622..0000000
--- a/samples/ApiDemos/res/layout/progressbar_2.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <ProgressBar android:id="@+android:id/progress_large"
-        style="?android:attr/progressBarStyleLarge"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" />
-
-    <ProgressBar android:id="@+android:id/progress"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" />
-
-    <ProgressBar android:id="@+android:id/progress_small"
-        style="?android:attr/progressBarStyleSmall"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" />
-
-    <ProgressBar android:id="@+android:id/progress_small_title"
-        style="?android:attr/progressBarStyleSmallTitle"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/progressbar_3.xml b/samples/ApiDemos/res/layout/progressbar_3.xml
deleted file mode 100644
index ac10a30..0000000
--- a/samples/ApiDemos/res/layout/progressbar_3.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <Button android:id="@+id/showIndeterminate"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/progressbar_3_indeterminate" />
-
-    <Button android:id="@+id/showIndeterminateNoTitle"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/progressbar_3_indeterminate_no_title" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/progressbar_4.xml b/samples/ApiDemos/res/layout/progressbar_4.xml
deleted file mode 100644
index 5e577a0..0000000
--- a/samples/ApiDemos/res/layout/progressbar_4.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:orientation="vertical"
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content">
-
-    <Button android:id="@+id/toggle"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/progressbar_4_toggle" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/radio_group_1.xml b/samples/ApiDemos/res/layout/radio_group_1.xml
deleted file mode 100644
index 3029207..0000000
--- a/samples/ApiDemos/res/layout/radio_group_1.xml
+++ /dev/null
@@ -1,49 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    <RadioGroup
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="vertical"
-        android:checkedButton="@+id/lunch"
-        android:id="@+id/menu">
-        <RadioButton
-            android:text="@string/radio_group_1_breakfast"
-            android:id="@+id/breakfast"
-            />
-        <RadioButton
-            android:text="@string/radio_group_1_lunch"
-            android:id="@id/lunch" />
-        <RadioButton
-            android:text="@string/radio_group_1_dinner"
-            android:id="@+id/dinner" />
-        <RadioButton
-            android:text="@string/radio_group_1_all"
-            android:id="@+id/all" />
-        <TextView
-            android:text="@string/radio_group_1_selection"
-            android:id="@+id/choice" />
-    </RadioGroup>
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/radio_group_1_clear"
-        android:id="@+id/clear" />
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/ratingbar_1.xml b/samples/ApiDemos/res/layout/ratingbar_1.xml
deleted file mode 100644
index 3256d3c..0000000
--- a/samples/ApiDemos/res/layout/ratingbar_1.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:paddingLeft="10dip"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <RatingBar android:id="@+id/ratingbar1"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:numStars="3"
-        android:rating="2.5" />
-
-    <RatingBar android:id="@+id/ratingbar2"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:numStars="5"
-        android:rating="2.25" />
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="10dip">
-        
-        <TextView android:id="@+id/rating"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-            
-        <RatingBar android:id="@+id/small_ratingbar"
-            style="?android:attr/ratingBarStyleSmall"
-            android:layout_marginLeft="5dip"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical" />
-            
-    </LinearLayout>
-
-    <RatingBar android:id="@+id/indicator_ratingbar"
-        style="?android:attr/ratingBarStyleIndicator"
-        android:layout_marginLeft="5dip"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="center_vertical" />
-            
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/read_asset.xml b/samples/ApiDemos/res/layout/read_asset.xml
deleted file mode 100644
index 79b8bb6..0000000
--- a/samples/ApiDemos/res/layout/read_asset.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates styled string resources.
-     See corresponding Java code com.android.sdk.content.StyledText -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <TextView android:id="@+id/text"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"/>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/receive_result.xml b/samples/ApiDemos/res/layout/receive_result.xml
deleted file mode 100644
index 461be6c..0000000
--- a/samples/ApiDemos/res/layout/receive_result.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates receiving activity results.
-    See corresponding Java code com.android.sdk.app.ReceiveResult.java.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/receive_result_instructions"/>
-
-    <TextView android:id="@+id/results"
-        android:layout_width="fill_parent" android:layout_height="10dip"
-        android:layout_weight="1"
-        android:paddingBottom="4dip"
-        android:background="@drawable/green">
-    </TextView>
-
-    <Button android:id="@+id/get"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:layout_weight="0"
-        android:text="@string/receive_result_result">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/redirect_enter.xml b/samples/ApiDemos/res/layout/redirect_enter.xml
deleted file mode 100644
index f73d999..0000000
--- a/samples/ApiDemos/res/layout/redirect_enter.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates redirection between activities.
-     See corresponding Java code com.android.sdk.app.RedirectEnter.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/redirect_enter"/>
-
-    <Button android:id="@+id/go"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/go">
-        <requestFocus />
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/redirect_getter.xml b/samples/ApiDemos/res/layout/redirect_getter.xml
deleted file mode 100644
index 9879b78..0000000
--- a/samples/ApiDemos/res/layout/redirect_getter.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates redirection between activities.
-     See corresponding Java code com.android.sdk.app.RedirectEnter.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/redirect_getter"/>
-
-    <EditText android:id="@+id/text"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip">
-        <requestFocus />
-    </EditText>
-
-    <Button android:id="@+id/apply"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/apply" />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/redirect_main.xml b/samples/ApiDemos/res/layout/redirect_main.xml
deleted file mode 100644
index 74de502..0000000
--- a/samples/ApiDemos/res/layout/redirect_main.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates redirection between activities.
-     See corresponding Java code com.android.sdk.app.RedirectEnter.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/redirect_main"/>
-
-    <TextView android:id="@+id/text"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip" />
-
-    <Button android:id="@+id/clear"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/clear_text">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/newView"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/new_text">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/relative_layout_1.xml b/samples/ApiDemos/res/layout/relative_layout_1.xml
deleted file mode 100644
index 122e718..0000000
--- a/samples/ApiDemos/res/layout/relative_layout_1.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates stretching a view to fill the space between two other views
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <!-- view1 goes on top -->
-    <TextView
-        android:id="@+id/view1"
-        android:background="@drawable/red"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_alignParentTop="true"
-        android:text="@string/relative_layout_1_top"/>
-
-    <!-- view2 goes on the bottom -->
-    <TextView
-        android:id="@+id/view2"
-        android:background="@drawable/green"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_alignParentBottom="true"
-        android:text="@string/relative_layout_1_bottom"/>
-
-    <!-- view3 stretches betweeen view1 and view2 -->
-    <TextView
-        android:id="@+id/view3"
-        android:background="@drawable/yellow"
-        android:layout_width="fill_parent"
-        android:layout_height="0dip"
-        android:layout_above="@id/view2"
-        android:layout_below="@id/view1"
-        android:text="@string/relative_layout_1_center"/>
-
-</RelativeLayout>
-
diff --git a/samples/ApiDemos/res/layout/relative_layout_2.xml b/samples/ApiDemos/res/layout/relative_layout_2.xml
deleted file mode 100644
index dc613e6..0000000
--- a/samples/ApiDemos/res/layout/relative_layout_2.xml
+++ /dev/null
@@ -1,78 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using a relative layout to create a form -->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:background="@drawable/blue"
-    android:padding="10dip">
-
-    <!--
-        TextView goes at the top left by default .
-    -->
-    <TextView
-        android:id="@+id/label"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/relative_layout_2_instructions"/>
-
-    <!--
-        Put the EditText field under the TextView
-        Also give it a standard background (the "android:"
-        part in @android:drawable/editbox_background
-        means it is system resource rather than
-        an application resource.
-    -->
-    <EditText
-        android:id="@+id/entry"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:background="@android:drawable/editbox_background"
-        android:layout_below="@id/label"/>
-
-    <!--
-        The OK button goes below the EditText field.
-        It is also aligned to the right edge of the parent
-        (respecting the parent's padding).
-        The OK button comes first so the Cancel button
-        can be specified relative to the OK button.
-    -->
-    <Button
-        android:id="@+id/ok"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_below="@id/entry"
-        android:layout_alignParentRight="true"
-        android:layout_marginLeft="10dip"
-        android:text="@string/relative_layout_2_ok" />
-
-    <!--
-        The Cancel button is aligned with the top of
-        the OK button and positioned to the left of it.
-        Since the OK button has a left margin of 10, there
-        is some space between the two buttons.
-    -->
-    <Button
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_toLeftOf="@id/ok"
-        android:layout_alignTop="@id/ok"
-        android:text="@string/relative_layout_2_cancel" />
-
-</RelativeLayout>
-
diff --git a/samples/ApiDemos/res/layout/remote_service_binding.xml b/samples/ApiDemos/res/layout/remote_service_binding.xml
deleted file mode 100644
index a353efb..0000000
--- a/samples/ApiDemos/res/layout/remote_service_binding.xml
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/remote_service_binding"/>
-
-    <Button android:id="@+id/bind"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/bind_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/unbind"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/unbind_service">
-    </Button>
-
-    <Button android:id="@+id/kill"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/kill_process">
-    </Button>
-
-    <TextView android:id="@+id/callback"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:gravity="center_horizontal" android:paddingTop="4dip"/>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/remote_service_controller.xml b/samples/ApiDemos/res/layout/remote_service_controller.xml
deleted file mode 100644
index 48e4c95..0000000
--- a/samples/ApiDemos/res/layout/remote_service_controller.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.LocalSerice.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/remote_service_controller"/>
-
-    <Button android:id="@+id/start"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/stop"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/stop_service">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/reorder_four.xml b/samples/ApiDemos/res/layout/reorder_four.xml
deleted file mode 100644
index 45f13a3..0000000
--- a/samples/ApiDemos/res/layout/reorder_four.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using Intent.FLAG_ACTIVITY_REORDER_TO_FRONT.
-     See corresponding Java code com.example.android.apis.app.ReorderOnLaunch.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/reorder_four_text"/>
-
-    <Button android:id="@+id/reorder_second_to_front"
-        android:layout_width="wrap_content" android:layout_height="wrap_content"
-        android:text="@string/reorder_second_to_front">
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/reorder_on_launch.xml b/samples/ApiDemos/res/layout/reorder_on_launch.xml
deleted file mode 100644
index 850a2f5..0000000
--- a/samples/ApiDemos/res/layout/reorder_on_launch.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using Intent.FLAG_ACTIVITY_REORDER_TO_FRONT.
-     See corresponding Java code com.android.sdk.app.ReorderOnLaunch.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/reorder_on_launch"/>
-
-    <Button android:id="@+id/reorder_launch_two"
-        android:layout_width="wrap_content" android:layout_height="wrap_content"
-        android:text="@string/reorder_launch_two">
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/reorder_three.xml b/samples/ApiDemos/res/layout/reorder_three.xml
deleted file mode 100644
index 30ef41b..0000000
--- a/samples/ApiDemos/res/layout/reorder_three.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using Intent.FLAG_ACTIVITY_REORDER_TO_FRONT.
-     See corresponding Java code com.example.android.apis.app.ReorderOnLaunch.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/reorder_three_text"/>
-
-    <Button android:id="@+id/reorder_launch_four"
-        android:layout_width="wrap_content" android:layout_height="wrap_content"
-        android:text="@string/reorder_launch_four">
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/reorder_two.xml b/samples/ApiDemos/res/layout/reorder_two.xml
deleted file mode 100644
index 7132561..0000000
--- a/samples/ApiDemos/res/layout/reorder_two.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates using Intent.FLAG_ACTIVITY_REORDER_TO_FRONT.
-     See corresponding Java code com.example.android.apis.app.ReorderOnLaunch.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/reorder_two_text"/>
-
-    <Button android:id="@+id/reorder_launch_three"
-        android:layout_width="wrap_content" android:layout_height="wrap_content"
-        android:text="@string/reorder_launch_three">
-    </Button>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/resources.xml b/samples/ApiDemos/res/layout/resources.xml
deleted file mode 100644
index 60ec581..0000000
--- a/samples/ApiDemos/res/layout/resources.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!--
-    Demonstrates resources.
-
-    See corresponding Java code:
-    com.example.android.apis.content.ResourcesSample
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <TextView
-        android:id="@+id/styled_text"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"
-        />
-
-    <TextView
-        android:id="@+id/plain_text"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"
-        />
-
-    <TextView
-        android:id="@+id/res1"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"
-        />
-
-</LinearLayout>
-
-
diff --git a/samples/ApiDemos/res/layout/save_restore_state.xml b/samples/ApiDemos/res/layout/save_restore_state.xml
deleted file mode 100644
index 4f3f8ee..0000000
--- a/samples/ApiDemos/res/layout/save_restore_state.xml
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates saving and restoring activity state.
-     See corresponding Java code com.android.sdk.app.SaveRestoreState.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView android:id="@+id/msg"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip" />
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/saves_state"/>
-
-    <EditText android:id="@+id/saved"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:background="@drawable/green"
-        android:text="@string/initial_text"
-        android:freezesText="true">
-        <requestFocus />
-    </EditText>
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingTop="8dip"
-        android:paddingBottom="4dip"
-        android:text="@string/no_saves_state"/>
-
-    <EditText 
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:background="@drawable/red"
-        android:text="@string/initial_text">
-    </EditText>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/scroll_view_1.xml b/samples/ApiDemos/res/layout/scroll_view_1.xml
deleted file mode 100644
index 0552807..0000000
--- a/samples/ApiDemos/res/layout/scroll_view_1.xml
+++ /dev/null
@@ -1,90 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:scrollbars="none">
-
-    <LinearLayout
-        android:id="@+id/layout"
-        android:orientation="vertical"
-        android:layout_width="fill_parent" android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_1"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_1"/>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_2"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_2"/>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_3"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_3"/>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_4"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_4"/>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_5"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_5"/>
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_text_6"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_1_button_6"/>
-
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/scroll_view_2.xml b/samples/ApiDemos/res/layout/scroll_view_2.xml
deleted file mode 100644
index 0107e46..0000000
--- a/samples/ApiDemos/res/layout/scroll_view_2.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:scrollbars="none">
-
-    <LinearLayout
-        android:id="@+id/layout"
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_2_text_1"/>
-
-        <Button
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scroll_view_2_button_1"/>
-
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/scrollbar1.xml b/samples/ApiDemos/res/layout/scrollbar1.xml
deleted file mode 100644
index 7221b3e..0000000
--- a/samples/ApiDemos/res/layout/scrollbar1.xml
+++ /dev/null
@@ -1,169 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_1_text"/>
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/scrollbar2.xml b/samples/ApiDemos/res/layout/scrollbar2.xml
deleted file mode 100644
index 4882a72..0000000
--- a/samples/ApiDemos/res/layout/scrollbar2.xml
+++ /dev/null
@@ -1,172 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:scrollbarTrackVertical="@drawable/scrollbar_vertical_track"
-    android:scrollbarThumbVertical="@drawable/scrollbar_vertical_thumb"
-    android:scrollbarSize="12dip">
-
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-        <TextView
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:text="@string/scrollbar_2_text"/>
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/scrollbar3.xml b/samples/ApiDemos/res/layout/scrollbar3.xml
deleted file mode 100644
index c272e45..0000000
--- a/samples/ApiDemos/res/layout/scrollbar3.xml
+++ /dev/null
@@ -1,136 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<LinearLayout
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <ScrollView
-            android:layout_width="100dip"
-            android:layout_height="120dip"
-            android:background="#FF0000">
-            <LinearLayout
-                android:orientation="vertical"
-                android:layout_width="fill_parent"
-                android:layout_height="fill_parent">
-
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-                <TextView
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:text="@string/scrollbar_2_text" />
-            </LinearLayout>
-        </ScrollView>
-
-        <ScrollView
-            android:layout_width="100dip"
-            android:layout_height="120dip"
-            android:background="#00FF00"
-            android:paddingRight="12dip">
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:text="@string/scrollbar_3_text"
-                android:textColor="#000000"
-                android:background="#60AA60" />
-        </ScrollView>
-
-        <ScrollView
-            android:id="@+id/view3"
-            android:layout_width="100dip"
-            android:layout_height="120dip"
-            android:background="@android:drawable/edit_text">
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:textColor="#000000"
-                android:text="@string/scrollbar_3_text" />
-        </ScrollView>
-    </LinearLayout>
-
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-        <ScrollView
-            android:id="@+id/view4"
-            android:layout_width="100dip"
-            android:layout_height="120dip"
-            android:scrollbarStyle="outsideOverlay"
-            android:background="@android:drawable/edit_text">
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:textColor="#000000"
-                android:text="@string/scrollbar_3_text" />
-        </ScrollView>
-        <ScrollView
-            android:id="@+id/view5"
-            android:layout_width="100dip"
-            android:layout_height="120dip"
-            android:scrollbarStyle="outsideInset"
-            android:background="@android:drawable/edit_text">
-            <TextView
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:textColor="#000000"
-                android:text="@string/scrollbar_3_text" />
-        </ScrollView>
-    </LinearLayout>
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/search_invoke.xml b/samples/ApiDemos/res/layout/search_invoke.xml
deleted file mode 100644
index b78a616..0000000
--- a/samples/ApiDemos/res/layout/search_invoke.xml
+++ /dev/null
@@ -1,96 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This activity exercises search invocation options -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <!--  Section: Information -->
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingBottom="4dip"
-        android:text="@string/msg_search" />
-    
-     <!--  Section: Invocation -->
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/search_sect_invocation" />
-
-    <Button android:id="@+id/btn_start_search"
-        android:text="@string/label_onsearchrequested"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"/>
-            
-    <Spinner android:id="@+id/spinner_menu_mode"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:drawSelectorOnTop="true" />
-            
-    <!--  Section: Options -->
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/search_sect_options" />
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <LinearLayout
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:gravity="center_horizontal"
-            android:orientation="horizontal">
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/label_search_query_prefill" />
-            <EditText android:id="@+id/txt_query_prefill"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:maxEms="10"
-                android:minEms="10" />
-        </LinearLayout>
-    </LinearLayout>
-    
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-        <LinearLayout
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content"
-            android:gravity="center_horizontal"
-            android:orientation="horizontal">
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/label_search_query_appdata" />
-            <EditText android:id="@+id/txt_query_appdata"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:maxEms="10"
-                android:minEms="10" />
-        </LinearLayout>
-    </LinearLayout>
-     
-     
- </LinearLayout>
diff --git a/samples/ApiDemos/res/layout/search_query_results.xml b/samples/ApiDemos/res/layout/search_query_results.xml
deleted file mode 100644
index 03f1ae6..0000000
--- a/samples/ApiDemos/res/layout/search_query_results.xml
+++ /dev/null
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This activity displays search queries and "results" -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <!--  Section: Information -->
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingBottom="4dip"
-        android:text="@string/msg_search_results" />
-    
-    <!--  Section: Search Query String -->
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/label_search_query" />
-        <TextView android:id="@+id/txt_query"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-    </LinearLayout>
-
-    <!--  Section: Search Query application context data -->
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/label_search_appdata" />
-        <TextView android:id="@+id/txt_appdata"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-    </LinearLayout>
-
-    <!--  Section: How the query was delivered -->
-    <LinearLayout
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:orientation="horizontal">
-
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/label_search_deliveredby" />
-        <TextView android:id="@+id/txt_deliveredby"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content" />
-    </LinearLayout>
-
- </LinearLayout>
diff --git a/samples/ApiDemos/res/layout/seekbar_1.xml b/samples/ApiDemos/res/layout/seekbar_1.xml
deleted file mode 100644
index 513114e..0000000
--- a/samples/ApiDemos/res/layout/seekbar_1.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <SeekBar android:id="@+id/seek"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:max="100"
-        android:progress="50"
-        android:secondaryProgress="75" />
-
-    <TextView android:id="@+id/progress"
-       	android:layout_width="fill_parent"
-        android:layout_height="wrap_content" />
-
-    <TextView android:id="@+id/tracking"
-       	android:layout_width="fill_parent"
-        android:layout_height="wrap_content" />
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/select_dialog.xml b/samples/ApiDemos/res/layout/select_dialog.xml
deleted file mode 100644
index ad826af..0000000
--- a/samples/ApiDemos/res/layout/select_dialog.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates different uses of the android.app.SelectDialog.
-     See corresponding Java code com.android.sdk.app.SelectDialogSamples.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/screen"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-    <Button android:id="@+id/show_dialog"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:text="@string/select_dialog_show"/>
-    <TextView android:id="@+id/message"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"/>
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/send_result.xml b/samples/ApiDemos/res/layout/send_result.xml
deleted file mode 100644
index 386c3fc..0000000
--- a/samples/ApiDemos/res/layout/send_result.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates receiving activity results.
-     See corresponding Java code com.android.sdk.app.ReceiveResult.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="8dip"
-        android:text="@string/pick_result"/>
-
-    <Button android:id="@+id/corky"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/corky">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/violet"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/violet">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/service_start_arguments_controller.xml b/samples/ApiDemos/res/layout/service_start_arguments_controller.xml
deleted file mode 100644
index f10a2c3..0000000
--- a/samples/ApiDemos/res/layout/service_start_arguments_controller.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates starting and stopping a local service.
-     See corresponding Java code com.android.sdk.app.ServiceStartArguments.java. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:padding="4dip"
-    android:gravity="center_horizontal"
-    android:layout_width="fill_parent" android:layout_height="fill_parent">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:layout_weight="0"
-        android:paddingBottom="4dip"
-        android:text="@string/service_start_arguments_controller"/>
-
-    <Button android:id="@+id/start1"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start1_service">
-        <requestFocus />
-    </Button>
-
-    <Button android:id="@+id/start2"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start2_service">
-    </Button>
-
-    <Button android:id="@+id/start3"
-        android:layout_width="wrap_content" android:layout_height="wrap_content" 
-        android:text="@string/start3_service">
-    </Button>
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/shape_drawable_1.xml b/samples/ApiDemos/res/layout/shape_drawable_1.xml
deleted file mode 100644
index 037e844..0000000
--- a/samples/ApiDemos/res/layout/shape_drawable_1.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates scrolling with a ScrollView. -->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" 
-	android:layout_width="fill_parent"
-	android:layout_height="wrap_content">
-	
-    <LinearLayout
-    	android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-        
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="50dip"
-			android:src="@drawable/shape_1" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="wrap_content"
-			android:src="@drawable/line" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="50dip"
-			android:src="@drawable/shape_2" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="wrap_content"
-			android:src="@drawable/line" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="50dip"
-			android:src="@drawable/shape_3" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="wrap_content"
-			android:src="@drawable/line" />
-					
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="50dip"
-			android:src="@drawable/shape_4" />
-			
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="wrap_content"
-			android:src="@drawable/line" />
-							
-		<ImageView
-			android:layout_width="fill_parent"
-			android:layout_height="50dip"
-			android:src="@drawable/shape_5" />
-	</LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/spinner_1.xml b/samples/ApiDemos/res/layout/spinner_1.xml
deleted file mode 100644
index 3d5f3c1..0000000
--- a/samples/ApiDemos/res/layout/spinner_1.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:padding="10dip"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/spinner_1_color"
-    />
-
-    <Spinner android:id="@+id/spinner1"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:drawSelectorOnTop="true"
-        android:prompt="@string/spinner_1_color_prompt"
-    />
-
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="10dip"
-        android:text="@string/spinner_1_planet"
-    />
-
-    <Spinner android:id="@+id/spinner2"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:drawSelectorOnTop="true"
-        android:prompt="@string/spinner_1_planet_prompt"
-    />
-
-</LinearLayout>
-
diff --git a/samples/ApiDemos/res/layout/status_bar_balloon.xml b/samples/ApiDemos/res/layout/status_bar_balloon.xml
deleted file mode 100644
index 58f1bbb..0000000
--- a/samples/ApiDemos/res/layout/status_bar_balloon.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="horizontal"
-    android:baselineAligned="false"
-    android:gravity="center_vertical"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content">
-
-   <ImageView android:id="@+id/icon"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginRight="10dip" />
-    <TextView android:id="@+id/text"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:textColor="#ffffffff" />    
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/status_bar_notifications.xml b/samples/ApiDemos/res/layout/status_bar_notifications.xml
deleted file mode 100644
index 11f3c96..0000000
--- a/samples/ApiDemos/res/layout/status_bar_notifications.xml
+++ /dev/null
@@ -1,157 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-    
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/status_bar_notifications_icons_only" />
-            
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-        
-            <Button
-                android:id="@+id/happy"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_happy" />
-        
-            <Button
-                android:id="@+id/neutral"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_ok" />
-                
-              <Button
-                android:id="@+id/sad"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_sad" />
-                
-        </LinearLayout>
-        
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dip"
-            android:text="@string/status_bar_notifications_icons_and_marquee" />
-            
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-        
-            <Button
-                android:id="@+id/happyMarquee"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_happy" />
-        
-            <Button
-                android:id="@+id/neutralMarquee"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_ok" />
-                
-              <Button
-                android:id="@+id/sadMarquee"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_sad" />
-                
-        </LinearLayout>
-        
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dip"
-            android:text="@string/status_bar_notifications_remote_views" />
-            
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-        
-            <Button
-                android:id="@+id/happyViews"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_happy" />
-        
-            <Button
-                android:id="@+id/neutralViews"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_ok" />
-                
-              <Button
-                android:id="@+id/sadViews"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_sad" />
-                
-        </LinearLayout>
-    
-        <TextView
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dip"
-            android:text="@string/status_bar_notifications_defaults" />
-
-        <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-        
-            <Button
-                android:id="@+id/defaultSound"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_default_sound" />
-        
-            <Button
-                android:id="@+id/defaultVibrate"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_default_vibrate" />
-                
-              <Button
-                android:id="@+id/defaultAll"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/status_bar_notifications_default_all" />
-                
-        </LinearLayout>
-    
-        <Button android:id="@+id/clear"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="20dip"
-            android:text="@string/status_bar_notifications_clear" />
-            
-    </LinearLayout>
-
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/styled_text.xml b/samples/ApiDemos/res/layout/styled_text.xml
deleted file mode 100644
index 610ea64..0000000
--- a/samples/ApiDemos/res/layout/styled_text.xml
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates styled string resources.
-     See corresponding Java code com.android.sdk.content.StyledText -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:text="@string/styled_text_rsrc"/>
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"
-        android:text="@string/styled_text"/>
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        />
-
-    <TextView
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:text="@string/styled_text_prog"/>
-
-    <TextView android:id="@+id/text"
-        android:layout_width="fill_parent" android:layout_height="wrap_content"
-        android:gravity="center_horizontal"
-        android:textStyle="normal"/>
-
-</LinearLayout>
-
-
diff --git a/samples/ApiDemos/res/layout/surface_view_overlay.xml b/samples/ApiDemos/res/layout/surface_view_overlay.xml
deleted file mode 100644
index a557e22..0000000
--- a/samples/ApiDemos/res/layout/surface_view_overlay.xml
+++ /dev/null
@@ -1,84 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates changing view visibility. See corresponding Java code. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent">
-
-    <!-- Here is where we put the SurfaceView, in a frame so that we can
-         stack other views on top of it. -->
-    <FrameLayout
-            android:layout_width="fill_parent"
-            android:layout_height="0px"
-            android:layout_weight="1">
-
-        <android.opengl.GLSurfaceView android:id="@+id/glsurfaceview"
-                android:layout_width="fill_parent"
-                android:layout_height="fill_parent" />
-
-        <LinearLayout android:id="@+id/hidecontainer"
-                android:orientation="vertical"
-                android:visibility="gone"
-                android:background="@drawable/translucent_background"
-                android:gravity="center"
-                android:layout_width="fill_parent"
-                android:layout_height="fill_parent">
-
-            <Button android:id="@+id/hideme1"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center"
-                    android:visibility="gone"
-                    android:text="@string/hide_me"/>
-            
-            <Button android:id="@+id/hideme2"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center"
-                    android:visibility="gone"
-                    android:text="@string/hide_me"/>
-                    
-        </LinearLayout>
-        
-    </FrameLayout>
-            
-    <LinearLayout
-            android:orientation="horizontal"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center">
-
-        <Button android:id="@+id/vis"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/visibility_1_vis"/>
-
-        <Button android:id="@+id/invis"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/visibility_1_invis"/>
-
-        <Button android:id="@+id/gone"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:text="@string/visibility_1_gone"/>
-
-    </LinearLayout>
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_1.xml b/samples/ApiDemos/res/layout/table_layout_1.xml
deleted file mode 100644
index 8d95e82..0000000
--- a/samples/ApiDemos/res/layout/table_layout_1.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TableRow>
-        <TextView
-          android:text="@string/table_layout_1_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_open_shortcut"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_1_triple_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_save"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_save_shortcut"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_1_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_quit"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_1_quit_shortcut"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_10.xml b/samples/ApiDemos/res/layout/table_layout_10.xml
deleted file mode 100644
index 6c558e7..0000000
--- a/samples/ApiDemos/res/layout/table_layout_10.xml
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-   android:layout_width="fill_parent"
-   android:layout_height="fill_parent"
-   android:stretchColumns="1">
-
-   <TableRow>
-       <TextView
-           android:text="@string/table_layout_10_user"
-           android:textStyle="bold"
-           android:gravity="right"
-           android:padding="3dip" />
-
-       <EditText android:id="@+id/username"
-           android:text="@string/table_layout_10_username_text"
-           android:padding="3dip"
-           android:scrollHorizontally="true" />
-   </TableRow>
-
-   <TableRow>
-       <TextView
-           android:text="@string/table_layout_10_password"
-           android:textStyle="bold"
-           android:gravity="right"
-           android:padding="3dip" />
-
-       <EditText android:id="@+id/password"
-           android:text="@string/table_layout_10_password_text"
-           android:password="true"
-           android:padding="3dip"
-           android:scrollHorizontally="true" />
-   </TableRow>
-
-   <TableRow
-       android:gravity="right">
-
-       <Button android:id="@+id/cancel"
-           android:text="@string/table_layout_10_cancel" />
-
-       <Button android:id="@+id/login"
-           android:text="@string/table_layout_10_login" />
-   </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_11.xml b/samples/ApiDemos/res/layout/table_layout_11.xml
deleted file mode 100644
index e40e28a..0000000
--- a/samples/ApiDemos/res/layout/table_layout_11.xml
+++ /dev/null
@@ -1,93 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:stretchColumns="1">
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_7_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_7_open_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_7_save"
-            android:background="#FF00FF00"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_7_save_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <!-- Horizontally centers the content of the cell -->
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_7_save_as"
-            android:background="#FFFF0000"
-            android:layout_gravity="center_horizontal"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_7_save_as_shortcut"
-            android:background="#FFFF00FF"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_7_x"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_7_import"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <View
-            android:layout_height="68dip"
-            android:background="#FF909090" />
-        <!-- Aligns the content of the cell to the bottom right -->
-        <TextView
-            android:text="@string/table_layout_7_export"
-            android:background="#FFFF0000"
-            android:layout_gravity="right|bottom"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_7_export_shortcut"
-            android:background="#FF00FFFF"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_12.xml b/samples/ApiDemos/res/layout/table_layout_12.xml
deleted file mode 100644
index 423e34e..0000000
--- a/samples/ApiDemos/res/layout/table_layout_12.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content">
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_12_a"
-            android:background="#FFFF0000"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_b"
-            android:background="#FF00FF00"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_c"
-            android:background="#FF0000FF"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_12_d"
-            android:layout_span="2"
-            android:gravity="center_horizontal"
-            android:background="#FF0000FF"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_e"
-            android:background="#FF00FF00"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_12_f"
-            android:background="#FFFF00FF"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_g"
-            android:background="#FF00FF00"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_h"
-            android:background="#FFFF0000"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_12_a"
-            android:background="#FF00FF00"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_12_b"
-            android:layout_span="2"
-            android:gravity="center_horizontal"
-            android:background="#FF0000FF"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_12_g"
-            android:layout_span="3"
-            android:gravity="center_horizontal"
-            android:background="#FFC0C0C0"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_2.xml b/samples/ApiDemos/res/layout/table_layout_2.xml
deleted file mode 100644
index c5134d3..0000000
--- a/samples/ApiDemos/res/layout/table_layout_2.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TableRow>
-        <Button
-            android:text="@string/table_layout_2_open" />
-        <TextView
-            android:text="@string/table_layout_2_path_1"
-            android:padding="3dip" />
-    </TableRow>
-    <TableRow>
-        <Button
-            android:text="@string/table_layout_2_save_all"/>
-    </TableRow>
-    <TableRow>
-        <Button
-            android:text="@string/table_layout_2_save"
-            android:visibility="invisible" />
-        <TextView
-            android:text="@string/table_layout_2_path_2"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_3.xml b/samples/ApiDemos/res/layout/table_layout_3.xml
deleted file mode 100644
index 44415fc..0000000
--- a/samples/ApiDemos/res/layout/table_layout_3.xml
+++ /dev/null
@@ -1,62 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:shrinkColumns="2, 3">
-
-    <!-- Rows have different number of columns and content doesn't fit on
-         screen: column 4 of row 2 shrinks all of the other columns -->
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_3_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_open_shortcut"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_3_triple_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_save"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_save_shortcut"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_too_long"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_3_star"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_quit"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_3_quit_shortcut"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_4.xml b/samples/ApiDemos/res/layout/table_layout_4.xml
deleted file mode 100644
index a9b7b42..0000000
--- a/samples/ApiDemos/res/layout/table_layout_4.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Stretch some columns -->
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:stretchColumns="1">
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_4_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_4_open_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_4_save"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_4_save_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_5.xml b/samples/ApiDemos/res/layout/table_layout_5.xml
deleted file mode 100644
index 773d729..0000000
--- a/samples/ApiDemos/res/layout/table_layout_5.xml
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Stretch some columns -->
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:stretchColumns="1">
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_5_open_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_save"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_5_save_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_save_as"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_5_save_as_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_import"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_export"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_5_export_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_5_quit"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_6.xml b/samples/ApiDemos/res/layout/table_layout_6.xml
deleted file mode 100644
index 9607f1c..0000000
--- a/samples/ApiDemos/res/layout/table_layout_6.xml
+++ /dev/null
@@ -1,92 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Stretch some columns -->
-<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:stretchColumns="1">
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_6_open"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_open_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_6_save"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_save_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_6_save_as"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_save_as_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_6_x"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_import"
-            android:padding="3dip" />
-    </TableRow>
-
-    <TableRow>
-        <TextView
-            android:text="@string/table_layout_6_x"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_export"
-            android:padding="3dip" />
-        <TextView
-            android:text="@string/table_layout_6_export_shortcut"
-            android:gravity="right"
-            android:padding="3dip" />
-    </TableRow>
-
-    <View
-        android:layout_height="2dip"
-        android:background="#FF909090" />
-
-    <TableRow>
-        <TextView
-            android:layout_column="1"
-            android:text="@string/table_layout_6_quit"
-            android:padding="3dip" />
-    </TableRow>
-</TableLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_7.xml b/samples/ApiDemos/res/layout/table_layout_7.xml
deleted file mode 100644
index 88c4910..0000000
--- a/samples/ApiDemos/res/layout/table_layout_7.xml
+++ /dev/null
@@ -1,106 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    <TableLayout
-        android:id="@+id/menu"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:stretchColumns="1"
-        android:collapseColumns="2">
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_7_open"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_open_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_7_save"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_save_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_7_save_as"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_save_as_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <View
-            android:layout_height="2dip"
-            android:background="#FF909090" />
-
-        <TableRow>
-            <TextView
-                android:text="@string/table_layout_7_x"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_import"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:text="@string/table_layout_7_x"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_export"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_7_export_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <View
-            android:layout_height="2dip"
-            android:background="#FF909090" />
-    </TableLayout>
-
-    <LinearLayout
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content">
-        <Button
-            android:id="@+id/toggle2"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/table_layout_7_toggle_checkmarks" />
-        <Button
-            android:id="@+id/toggle1"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/table_layout_7_toggle_shortcuts" />
-    </LinearLayout>
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_8.xml b/samples/ApiDemos/res/layout/table_layout_8.xml
deleted file mode 100644
index a63a8e8..0000000
--- a/samples/ApiDemos/res/layout/table_layout_8.xml
+++ /dev/null
@@ -1,87 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    <TableLayout
-        android:id="@+id/menu"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_8_open"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_open_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_8_save"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_save_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:layout_column="1"
-                android:text="@string/table_layout_8_save_as"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_save_as_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:text="@string/table_layout_8_x"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_import"
-                android:padding="3dip" />
-        </TableRow>
-
-        <TableRow>
-            <TextView
-                android:text="@string/table_layout_8_x"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_export"
-                android:padding="3dip" />
-            <TextView
-                android:text="@string/table_layout_8_export_shortcut"
-                android:gravity="right"
-                android:padding="3dip" />
-        </TableRow>
-    </TableLayout>
-
-    <Button
-        android:id="@+id/toggle"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="@string/table_layout_8_toggle_stretch" />
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/table_layout_9.xml b/samples/ApiDemos/res/layout/table_layout_9.xml
deleted file mode 100644
index a2d6564..0000000
--- a/samples/ApiDemos/res/layout/table_layout_9.xml
+++ /dev/null
@@ -1,92 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent">
-        <TableLayout
-            android:id="@+id/menu"
-            android:layout_width="fill_parent"
-            android:layout_height="wrap_content">
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_open"
-                    android:padding="3dip" />
-                <TextView
-                    android:text="@string/table_layout_9_open_shortcut"
-                    android:gravity="right"
-                    android:padding="3dip" />
-            </TableRow>
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_save"
-                    android:padding="3dip" />
-                <TextView
-                    android:text="@string/table_layout_9_save_shortcut"
-                    android:gravity="right"
-                    android:padding="3dip" />
-            </TableRow>
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_save_as"
-                    android:padding="3dip" />
-                <TextView
-                    android:text="@string/table_layout_9_save_as_shortcut"
-                    android:gravity="right"
-                    android:padding="3dip" />
-            </TableRow>
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_save_all"
-                    android:padding="3dip" />
-                <TextView
-                    android:text="@string/table_layout_9_save_all_shortcut"
-                    android:gravity="right"
-                    android:padding="3dip" />
-            </TableRow>
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_import"
-                    android:padding="3dip" />
-            </TableRow>
-
-            <TableRow>
-                <TextView
-                    android:text="@string/table_layout_9_export"
-                    android:padding="3dip" />
-                <TextView
-                    android:text="@string/table_layout_9_export_shortcut"
-                    android:gravity="right"
-                    android:padding="3dip" />
-            </TableRow>
-        </TableLayout>
-
-        <Button
-            android:id="@+id/toggle"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/table_layout_9_toggle_shrink" />
-    </LinearLayout>
-</ScrollView>
diff --git a/samples/ApiDemos/res/layout/tabs1.xml b/samples/ApiDemos/res/layout/tabs1.xml
deleted file mode 100644
index 5a17693..0000000
--- a/samples/ApiDemos/res/layout/tabs1.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <TextView android:id="@+id/view1"
-        android:background="@drawable/blue"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:text="@string/tabs_1_tab_1"/>
-
-    <TextView android:id="@+id/view2"
-        android:background="@drawable/red"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:text="@string/tabs_1_tab_2"/>
-
-    <TextView android:id="@+id/view3"
-        android:background="@drawable/green"
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent"
-        android:text="@string/tabs_1_tab_3"/>
-
-</FrameLayout>
diff --git a/samples/ApiDemos/res/layout/text_switcher_1.xml b/samples/ApiDemos/res/layout/text_switcher_1.xml
deleted file mode 100644
index d7be743..0000000
--- a/samples/ApiDemos/res/layout/text_switcher_1.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <Button android:id="@+id/next"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content" 
-        android:text="@string/text_switcher_1_next_text" />
-
-    <TextSwitcher android:id="@+id/switcher"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content" />
-
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/translucent_background.xml b/samples/ApiDemos/res/layout/translucent_background.xml
deleted file mode 100644
index 6b6e1cf..0000000
--- a/samples/ApiDemos/res/layout/translucent_background.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates an activity with a fancy translucent background.
-     See corresponding Java code com.android.sdk.app.TranslucentBackground.java. -->
-
-<!-- This screen consists of a single text field that displays some text. -->
-<TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:gravity="center_vertical|center_horizontal"
-    android:text="@string/translucent_background"/>
diff --git a/samples/ApiDemos/res/layout/videoview.xml b/samples/ApiDemos/res/layout/videoview.xml
deleted file mode 100644
index 4f35ace..0000000
--- a/samples/ApiDemos/res/layout/videoview.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    >
-    
-    <VideoView 
-        android:id="@+id/surface_view" 
-        android:layout_width="320px"
-        android:layout_height="240px"
-    />
-    
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/visibility_1.xml b/samples/ApiDemos/res/layout/visibility_1.xml
deleted file mode 100644
index ad94602..0000000
--- a/samples/ApiDemos/res/layout/visibility_1.xml
+++ /dev/null
@@ -1,71 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Demonstrates changing view visibility. See corresponding Java code. -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <LinearLayout
-      android:orientation="vertical"
-      android:background="@drawable/box"
-      android:layout_width="fill_parent"
-      android:layout_height="wrap_content">
-
-      <TextView
-          android:background="@drawable/red"
-          android:layout_width="fill_parent"
-          android:layout_height="wrap_content"
-          android:text="@string/visibility_1_view_1"/>
-
-      <TextView android:id="@+id/victim"
-          android:background="@drawable/green"
-          android:layout_width="fill_parent"
-          android:layout_height="wrap_content"
-          android:text="@string/visibility_1_view_2"/>
-
-      <TextView
-          android:background="@drawable/blue"
-          android:layout_width="fill_parent"
-          android:layout_height="wrap_content"
-          android:text="@string/visibility_1_view_3"/>
-
-    </LinearLayout>
-
-    <LinearLayout
-        android:orientation="horizontal"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content">
-
-        <Button android:id="@+id/vis"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/visibility_1_vis"/>
-
-        <Button android:id="@+id/invis"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/visibility_1_invis"/>
-
-        <Button android:id="@+id/gone"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:text="@string/visibility_1_gone"/>
-
-    </LinearLayout>
-</LinearLayout>
diff --git a/samples/ApiDemos/res/layout/voice_recognition.xml b/samples/ApiDemos/res/layout/voice_recognition.xml
deleted file mode 100644
index 2db4a72..0000000
--- a/samples/ApiDemos/res/layout/voice_recognition.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 
- * Copyright (C) 2008 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- -->
-
-<!-- This activity displays UI for launching voice recognition -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:orientation="vertical">
-    
-    <TextView
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:paddingBottom="4dip"
-        android:text="@string/voice_recognition_prompt" />
-        
-    <Button android:id="@+id/btn_speak"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:text="@string/speak_button" />
-        
-    <ListView android:id="@+id/list"
-        android:layout_width="fill_parent"
-        android:layout_height="0dip"
-        android:layout_weight="1" />
-
- </LinearLayout>
diff --git a/samples/ApiDemos/res/layout/webview_1.xml b/samples/ApiDemos/res/layout/webview_1.xml
deleted file mode 100644
index 91fca39..0000000
--- a/samples/ApiDemos/res/layout/webview_1.xml
+++ /dev/null
@@ -1,79 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content"
-    android:orientation="vertical">
-    
-    
-    <LinearLayout
-        android:orientation="vertical"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content">
-        
-        <WebView android:id="@+id/wv1"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv2"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv3"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv4"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv5"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv6"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-    
-        <WebView android:id="@+id/wv7"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv8"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv9"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-            
-        <WebView android:id="@+id/wv10"
-            android:layout_height="wrap_content"
-            android:layout_width="fill_parent"
-            />
-    </LinearLayout>
-        
- </ScrollView>        
diff --git a/samples/ApiDemos/res/menu/category_order.xml b/samples/ApiDemos/res/menu/category_order.xml
deleted file mode 100644
index cb2dde9..0000000
--- a/samples/ApiDemos/res/menu/category_order.xml
+++ /dev/null
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <!-- This group uses the default category. -->
-    <group android:id="@+id/most_used_items">
-    
-        <item android:id="@+id/last_most_item"
-            android:orderInCategory="10"
-            android:title="@string/last_most_often" />
-    
-        <item android:id="@+id/middle_most_item"
-            android:orderInCategory="7"
-            android:title="@string/middle_most_often" />
-    
-        <item android:id="@+id/first_most_item"
-            android:orderInCategory="4"
-            android:title="@string/first_most_often" />
-    
-    </group>
-    
-    <!-- This group uses the secondary category, which is used for less oftenly used items.
-         Notice these items will show up after the above items.
-         (Furthermore, notice how the orders in each category are independent from the other
-         category.) -->
-    <group android:id="@+id/least_used_items"
-        android:menuCategory="secondary">
-        
-        <item android:id="@+id/last_least_item"
-            android:orderInCategory="3"
-            android:title="@string/last_least_often" />
-    
-        <item android:id="@+id/middle_least_item"
-            android:orderInCategory="2"
-            android:title="@string/middle_least_often" />
-    
-        <item android:id="@+id/first_least_item"
-            android:orderInCategory="0"
-            android:title="@string/first_least_often" />
-    
-    </group>
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/checkable.xml b/samples/ApiDemos/res/menu/checkable.xml
deleted file mode 100644
index 17fae65..0000000
--- a/samples/ApiDemos/res/menu/checkable.xml
+++ /dev/null
@@ -1,91 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <!-- Checkable items appear only in submenus or context menus. -->
-
-    <!-- Carefully look at the attribute name checkableBehavior on groups, but
-         the attribute name checkable on items. The checkableBehavior encompasses
-         the number of items that will be checkable within that group. -->
-
-    <item android:title="None">
-        <menu>
-            <!-- The none checkableBehavior is default, but we explicitly show it here. -->
-            <group android:id="@+id/noncheckable_group"
-                    android:checkableBehavior="none">
-                <!-- Notice how these items inherit from the group. -->
-                <item android:id="@+id/noncheckable_item_1"
-                        android:title="@string/item_1" />
-                <item android:id="@+id/noncheckable_item_2"
-                        android:title="@string/item_2" />
-                <item android:id="@+id/noncheckable_item_3"
-                        android:title="@string/item_3" />
-            </group>
-        </menu>
-    </item>
-
-    <item android:title="All">
-        <menu>
-            <group android:id="@+id/checkable_group"
-                    android:checkableBehavior="all">
-                <!-- Notice how these items inherit from the group. -->
-                <item android:id="@+id/checkable_item_1"
-                        android:title="@string/item_1" />
-                <item android:id="@+id/checkable_item_2"
-                        android:title="@string/item_2"
-                        android:checked="true" />
-                <item android:id="@+id/checkable_item_3"
-                        android:title="@string/item_3"
-                        android:checked="true" />
-            </group>
-        </menu>
-    </item>
-
-    <item android:title="Single">
-        <menu>
-            <group android:id="@+id/exclusive_checkable_group"
-                    android:checkableBehavior="single">
-                <!-- Notice how these items inherit from the group. -->
-                <item android:id="@+id/exclusive_checkable_item_1"
-                        android:title="@string/item_1" />
-                <item android:id="@+id/exclusive_checkable_item_2"
-                        android:title="@string/item_2" />
-                <item android:id="@+id/exclusive_checkable_item_3"
-                        android:title="@string/item_3"
-                        android:checked="true" />
-            </group>
-        </menu>
-    </item>
-
-    <item android:title="All without group">
-        <menu>
-            <!-- Notice how these items have each set. -->
-            <item android:id="@+id/nongroup_checkable_item_1"
-                    android:title="@string/item_1"
-                    android:checkable="true" />
-            <item android:id="@+id/nongroup_checkable_item_2"
-                    android:title="@string/item_2"
-                    android:checkable="true"
-                    android:checked="true" />
-            <item android:id="@+id/nongroup_checkable_item_3"
-                    android:title="@string/item_3"
-                    android:checkable="true"
-                    android:checked="true" />
-        </menu>
-    </item>
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/disabled.xml b/samples/ApiDemos/res/menu/disabled.xml
deleted file mode 100644
index 647ec2e..0000000
--- a/samples/ApiDemos/res/menu/disabled.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/enabled_item"
-        android:title="Enabled"
-        android:icon="@drawable/stat_happy" />
-
-    <item android:id="@+id/disabled_item"
-        android:title="Disabled"
-        android:enabled="false"
-        android:icon="@drawable/stat_sad" />
-
-    <item android:id="@+id/enabled_item_2"
-        android:title="Enabled"
-        android:icon="@drawable/stat_happy" />
-
-    <item android:id="@+id/disabled_item_2"
-        android:title="Disabled"
-        android:enabled="false"
-        android:icon="@drawable/stat_sad" />
-
-    <item android:id="@+id/enabled_item_3"
-        android:title="Enabled"
-        android:icon="@drawable/stat_happy" />
-
-    <item android:id="@+id/disabled_item_3"
-        android:title="Disabled"
-        android:enabled="false"
-        android:icon="@drawable/stat_sad" />
-
-    <item android:id="@+id/enabled_item_4"
-        android:title="Enabled"
-        android:icon="@drawable/stat_happy" />
-
-    <item android:id="@+id/disabled_item_4"
-        android:title="Disabled"
-        android:enabled="false"
-        android:icon="@drawable/stat_sad" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/groups.xml b/samples/ApiDemos/res/menu/groups.xml
deleted file mode 100644
index 46c04f5..0000000
--- a/samples/ApiDemos/res/menu/groups.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/browser_visibility"
-        android:title="@string/browser_visibility" />
-
-    <group android:id="@+id/browser">
-    
-        <item android:id="@+id/refresh"
-            android:title="@string/browser_refresh" />
-    
-        <item android:id="@+id/bookmark"
-            android:title="@string/browser_bookmark" />
-    
-    </group>
-
-    <item android:id="@+id/email_visibility"
-        android:title="@string/email_visibility" />
-
-    <group android:id="@+id/email">
-    
-        <item android:id="@+id/reply"
-            android:title="@string/email_reply" />
-    
-        <item android:id="@+id/forward"
-            android:title="@string/email_forward" />
-    
-    </group>
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/order.xml b/samples/ApiDemos/res/menu/order.xml
deleted file mode 100644
index c73121f..0000000
--- a/samples/ApiDemos/res/menu/order.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <!-- These are in reverse order in this resource, but the orderInCategory attribute will
-         order them for the menu (they all have the same default category). -->
-
-    <item android:id="@+id/fourth_item"
-        android:orderInCategory="3"
-        android:title="Fourth" />
-
-    <item android:id="@+id/third_item"
-        android:orderInCategory="2"
-        android:title="Third" />
-
-    <item android:id="@+id/second_item"
-        android:orderInCategory="1"
-        android:title="Second" />
-
-    <item android:id="@+id/first_item"
-        android:orderInCategory="0"
-        android:title="First" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/shortcuts.xml b/samples/ApiDemos/res/menu/shortcuts.xml
deleted file mode 100644
index b5e938a..0000000
--- a/samples/ApiDemos/res/menu/shortcuts.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/invisible_item"
-        android:visible="false"
-        android:alphabeticShortcut="i"
-        android:title="Invisible item" />
-
-    <item android:id="@+id/a_item"
-        android:alphabeticShortcut="a"
-        android:title="Alvin" />
-
-    <item android:id="@+id/b_item"
-        android:alphabeticShortcut="b"
-        android:title="Bart" />
-
-    <item android:id="@+id/c_item"
-        android:alphabeticShortcut="c"
-        android:title="Chris" />
-
-    <item android:id="@+id/d_item"
-        android:alphabeticShortcut="d"
-        android:title="David" />
-
-    <item android:id="@+id/e_item"
-        android:alphabeticShortcut="e"
-        android:title="Eric" />
-
-    <item android:id="@+id/f_item"
-        android:alphabeticShortcut="f"
-        android:title="Frank" />
-
-    <item android:id="@+id/g_item"
-        android:alphabeticShortcut="g"
-        android:title="Gary" />
-
-    <item android:id="@+id/h_item"
-        android:alphabeticShortcut="h"
-        android:title="Henry" />
-
-    <item android:id="@+id/excl_item"
-        android:alphabeticShortcut="!"
-        android:title="Exclamation" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/submenu.xml b/samples/ApiDemos/res/menu/submenu.xml
deleted file mode 100644
index 24eff76..0000000
--- a/samples/ApiDemos/res/menu/submenu.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:title="Normal 1" />
-
-    <item android:id="@+id/submenu"
-        android:title="Emotions">
-
-        <menu>        
-
-            <item android:id="@+id/happy"
-                android:title="Happy"
-                android:icon="@drawable/stat_happy" />
-        
-            <item android:id="@+id/neutral"
-                android:title="Neutral"
-                android:icon="@drawable/stat_neutral" />
-        
-            <item android:id="@+id/sad"
-                android:title="Sad"
-                android:icon="@drawable/stat_sad" />
-        
-        </menu>
-    
-    </item>
-
-    <item android:title="Normal 2" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/title_icon.xml b/samples/ApiDemos/res/menu/title_icon.xml
deleted file mode 100644
index 72030a9..0000000
--- a/samples/ApiDemos/res/menu/title_icon.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/happy"
-        android:title="Happy"
-        android:icon="@drawable/stat_happy" />
-
-    <item android:id="@+id/neutral"
-        android:title="Neutral"
-        android:icon="@drawable/stat_neutral" />
-
-    <item android:id="@+id/sad"
-        android:title="Sad"
-        android:icon="@drawable/stat_sad" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/title_only.xml b/samples/ApiDemos/res/menu/title_only.xml
deleted file mode 100644
index 44162b1..0000000
--- a/samples/ApiDemos/res/menu/title_only.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/jump"
-        android:title="@string/jump" />
-
-    <item android:id="@+id/dive"
-        android:title="@string/dive" />
-
-</menu>
diff --git a/samples/ApiDemos/res/menu/visible.xml b/samples/ApiDemos/res/menu/visible.xml
deleted file mode 100644
index b41698d..0000000
--- a/samples/ApiDemos/res/menu/visible.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<menu xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <item android:id="@+id/visible_item"
-        android:title="Visible"
-        android:alphabeticShortcut="a" />
-
-    <item android:id="@+id/hidden_item"
-        android:title="Hidden"
-        android:visible="false"
-        android:alphabeticShortcut="b" />
-
-    <group android:id="@+id/hidden_group"
-        android:visible="false">
-    
-        <item android:id="@+id/hidden_by_group"
-            android:title="Hidden by group"
-            android:alphabeticShortcut="c" />
-    
-    </group>
-
-</menu>
diff --git a/samples/ApiDemos/res/raw/test_cbr.mp3 b/samples/ApiDemos/res/raw/test_cbr.mp3
deleted file mode 100755
index 7204d27..0000000
--- a/samples/ApiDemos/res/raw/test_cbr.mp3
+++ /dev/null
Binary files differ
diff --git a/samples/ApiDemos/res/values/arrays.xml b/samples/ApiDemos/res/values/arrays.xml
deleted file mode 100644
index ca3003f..0000000
--- a/samples/ApiDemos/res/values/arrays.xml
+++ /dev/null
@@ -1,88 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- Used in View/Spinner1.java -->
-    <string-array name="colors">
-        <item>red</item>
-        <item>orange</item>
-        <item>yellow</item>
-        <item>green</item>
-        <item>blue</item>
-        <item>violet</item>
-    </string-array>
-    
-    <!-- Used in View/Spinner1.java -->
-    <string-array name="planets">
-        <item>Mercury</item>
-        <item>Venus</item>
-        <item>Earth</item>
-        <item>Mars</item>
-        <item>Jupiter</item>
-        <item>Saturn</item>
-        <item>Uranus</item>
-        <item>Neptune</item>
-        <item>Pluto</item>
-    </string-array>
-
-    <!-- Used in App/SearchInvoke.java -->
-    <string-array name="search_menuModes">
-        <item>Search Key</item>
-        <item>Menu Item</item>
-        <item>Type-To-Search</item>
-        <item>Disabled</item>
-    </string-array>
-    
-    <!-- Used in app/dialog examples -->
-    <string-array name="select_dialog_items">
-        <item>Command one</item>
-        <item>Command two</item>
-        <item>Command three</item>
-        <item>Command four</item>
-    </string-array>
-    
-    <string-array name="select_dialog_items2">
-        <item>Map</item>
-        <item>Satellite</item>
-        <item>Traffic</item>
-        <item>Street view</item>
-    </string-array>
-    
-    <string-array name="select_dialog_items3">
-        <item>Every Monday</item>
-        <item>Every Tuesday</item>
-        <item>Every Wednesday</item>
-        <item>Every Thursday</item>
-        <item>Every Friday</item>
-        <item>Every Saturday</item>
-        <item>Every Sunday</item>
-    </string-array>
-    
-    <!-- Used in app/menu examples -->
-    <string-array name="entries_list_preference">
-        <item>Alpha Option 01</item>
-        <item>Beta Option 02</item>
-        <item>Charlie Option 03</item>  
-    </string-array>
-
-    <!-- Used in app/menu examples -->
-    <string-array name="entryvalues_list_preference">
-        <item>alpha</item>
-        <item>beta</item>
-        <item>charlie</item>  
-    </string-array>
-    
-</resources>
diff --git a/samples/ApiDemos/res/values/attrs.xml b/samples/ApiDemos/res/values/attrs.xml
deleted file mode 100644
index 53f0034..0000000
--- a/samples/ApiDemos/res/values/attrs.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- These are the attributes that we want to retrieve from the theme
-         in app/PreferencesFromCode.java -->
-    <declare-styleable name="TogglePrefAttrs">
-        <attr name="android:preferenceLayoutChild" />
-    </declare-styleable>
-    
-    <!-- These are the attributes that we want to retrieve from the theme
-         in view/Gallery1.java -->
-    <declare-styleable name="Gallery1">
-        <attr name="android:galleryItemBackground" />
-    </declare-styleable>
-    
-     <declare-styleable name="LabelView">
-        <attr name="text" format="string" />
-        <attr name="textColor" format="color" />
-        <attr name="textSize" format="dimension" />
-    </declare-styleable>
-</resources>
diff --git a/samples/ApiDemos/res/values/colors.xml b/samples/ApiDemos/res/values/colors.xml
deleted file mode 100644
index f2534d1..0000000
--- a/samples/ApiDemos/res/values/colors.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <drawable name="red">#7f00</drawable>
-    <drawable name="blue">#770000ff</drawable>
-    <drawable name="green">#7700ff00</drawable>
-	<drawable name="yellow">#77ffff00</drawable>
-	
-	<drawable name="screen_background_black">#ff000000</drawable>
-    <drawable name="translucent_background">#e0000000</drawable>
-    <drawable name="transparent_background">#00000000</drawable>
-
-    <color name="solid_red">#f00</color>
-    <color name="solid_blue">#0000ff</color>
-    <color name="solid_green">#f0f0</color>
-    <color name="solid_yellow">#ffffff00</color>
-
-</resources>
diff --git a/samples/ApiDemos/res/values/ids.xml b/samples/ApiDemos/res/values/ids.xml
deleted file mode 100644
index 17a3895..0000000
--- a/samples/ApiDemos/res/values/ids.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-  <item type="id" name="snack" />
-</resources>
diff --git a/samples/ApiDemos/res/values/strings.xml b/samples/ApiDemos/res/values/strings.xml
deleted file mode 100644
index bd1b0a3..0000000
--- a/samples/ApiDemos/res/values/strings.xml
+++ /dev/null
@@ -1,824 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="activity_sample_code">API Demos</string>
-
-    <!-- =============================== -->
-    <!--  app/activity examples strings  -->
-    <!-- =============================== -->
-
-    <string name="tabs_1_tab_1">tab1</string>
-    <string name="tabs_1_tab_2">tab2</string>
-    <string name="tabs_1_tab_3">tab3</string>
-
-    <string name="activity_hello_world">App/Activity/<b>Hello <i>World</i></b></string>
-    <string name="hello_world"><b>Hello, <i>World!</i></b></string>
-
-    <string name="activity_dialog">App/Activity/Dialog</string>
-    <string name="dialog_activity_text">Example of how you can use the
-            Theme.Dialog theme to make an activity that looks like a
-            dialog.</string>
-
-    <string name="activity_custom_dialog">App/Activity/Custom Dialog</string>
-    <string name="custom_dialog_activity_text">Example of how you can use a
-            custom Theme.Dialog theme to make an activity that looks like a
-            customized dialog, here with an ugly frame.</string>
-
-    <string name="activity_translucent">App/Activity/Translucent</string>
-    <string name="translucent_background">Example of how you can make an
-            activity have a translucent background, compositing over
-            whatever is behind it.</string>
-
-    <string name="activity_translucent_blur">App/Activity/Translucent Blur</string>
-
-    <string name="activity_save_restore">App/Activity/Save &amp; Restore State</string>
-    <string name="save_restore_msg">Demonstration of saving and restoring activity state in onSaveInstanceState() and onCreate().</string>
-    <string name="saves_state">This text field saves its state:</string>
-    <string name="no_saves_state">This text field does not save its state:</string>
-    <string name="initial_text">Initial text.</string>
-
-    <string name="activity_persistent">App/Activity/Persistent State</string>
-    <string name="persistent_msg">Demonstration of persistent activity state with getPreferences(0).edit() and getPreferences(0).</string>
-
-    <string name="activity_receive_result">App/Activity/Receive Result</string>
-    <string name="pick_result">Pick a result to send, or BACK to cancel.</string>
-    <string name="corky">Corky</string>
-    <string name="violet">Violet</string>
-
-    <string name="activity_forwarding">App/Activity/Forwarding</string>
-    <string name="forwarding">Press the button to go forward to the next activity.  This activity will stop, so you will no longer see it when going back.</string>
-    <string name="go">Go</string>
-    <string name="forward_target">Press back button and notice we don\'t see the previous activity.</string>
-
-    <string name="activity_redirect">App/Activity/Redirection</string>
-    <string name="redirect_enter">Press the button to start the example.  The next activity will conditionally redirect to another activity to collect data from the user.</string>
-    <string name="redirect_main">You now see the main activity running normally because the user text has been set to:</string>
-    <string name="clear_text">Clear and Exit</string>
-    <string name="new_text">New Text</string>
-    <string name="redirect_getter">Enter the text that will be used by the main activity.  Press back to cancel.</string>
-    <string name="apply">Apply</string>
-
-    <string name="activity_menu">App/Activity/Menu</string>
-    <string name="open_menu">Open menu</string>
-    <string name="close_menu">Close menu</string>
-    <string name="toggle_scenery">Toggle scenery</string>
-    <string name="toggle_dogs">Toggle dogs</string>
-    <string name="long_click_for_context_menu">Long click for context menu</string>
-
-    <string name="local_service_started">Local service has started</string>
-    <string name="local_service_stopped">Local service has stopped</string>
-    <string name="local_service_label">Sample Local Service</string>
-
-    <string name="activity_local_service_controller">App/Service/Local Service Controller</string>
-    <string name="local_service_controller">This demonstrates how you can implement persistent services that
-        may be started and stopped as desired.</string>
-    <string name="start_service">Start Service</string>
-    <string name="stop_service">Stop Service</string>
-
-    <string name="activity_local_service_binding">App/Service/Local Service Binding</string>
-    <string name="local_service_binding">This demonstrates how you can connect with a persistent
-        service.  Notice how it automatically starts for you, and play around with the
-        interaction between this and Local Service Controller.</string>
-    <string name="bind_service">Bind Service</string>
-    <string name="unbind_service">Unbind Service</string>
-    <string name="local_service_connected">Connected to local service</string>
-    <string name="local_service_disconnected">Disconnected from local service</string>
-
-    <string name="remote_service_started">Remote service has started</string>
-    <string name="remote_service_stopped">Remote service has stopped</string>
-    <string name="remote_service_label">Sample Remote Service</string>
-
-    <string name="activity_remote_service_controller">App/Service/Remote Service Controller</string>
-    <string name="remote_service_controller">This demonstrates how you can implement persistent services
-        running in a separate process that may be started and stopped as desired.</string>
-
-    <string name="activity_remote_service_binding">App/Service/Remote Service Binding</string>
-    <string name="remote_service_binding">This demonstrates how you can connect with a persistent
-        service running in another process.  Use the kill button to see what happens when
-        the process crashes.</string>
-    <string name="kill_process">Kill Process</string>
-    <string name="remote_service_connected">Connected to remote service</string>
-    <string name="remote_service_disconnected">Disconnected from remote service</string>
-    <string name="remote_call_failed">Failure calling remote service</string>
-
-    <string name="service_arguments_started">"Started with arguments: "</string>
-    <string name="service_arguments_stopped">Finished arguments,
-        stopping.</string>
-    <string name="service_start_arguments_label">Sample Service Start Arguments
-    </string>
-
-    <string name="activity_service_start_arguments_controller">App/Service/Service
-        Start Arguments Controller
-    </string>
-    <string name="service_start_arguments_controller">This demonstrates how
-        service can be started with arguments, and run until all arguments are
-        processed.
-    </string>
-    <string name="start1_service">Start with \"One\"</string>
-    <string name="start2_service">Start with \"Two\"</string>
-    <string name="start3_service">Start with \"Three\"</string>
-
-    <string name="one_shot_received">The one-shot alarm has gone off</string>
-    <string name="repeating_received">The repeating alarm has gone off</string>
-
-    <string name="activity_alarm_controller">App/Alarm/Alarm Controller</string>
-    <string name="alarm_controller">This demonstrates how to schedule and handle
-        one-shot and repeating alarms.</string>
-    <string name="one_shot_alarm">One Shot Alarm</string>
-    <string name="start_repeating_alarm">Start Repeating Alarm</string>
-    <string name="stop_repeating_alarm">Stop Repeating Alarm</string>
-    <string name="one_shot_scheduled">One-shot alarm will go off in 30 seconds based on
-        the real time clock.  Try changing the current time before then!</string>
-    <string name="repeating_scheduled">Repeating alarm will go off in 15 seconds and
-        every 15 seconds after based on the elapsed realtime clock</string>
-    <string name="repeating_unscheduled">Repeating alarm has been unscheduled</string>
-
-    <string name="alarm_service_started">The alarm service has started running</string>
-    <string name="alarm_service_finished">The alarm service has finished running</string>
-    <string name="alarm_service_label">Sample Alarm Service</string>
-
-    <string name="activity_alarm_service">App/Alarm/Alarm Service</string>
-    <string name="alarm_service">This demonstrates how to schedule a repeating
-        alarm that will initiate a long-lived operation through a service.</string>
-    <string name="start_alarm_service">Start Alarm Service</string>
-    <string name="stop_alarm_service">Stop Alarm Service</string>
-    <string name="alarm_service_scheduled">Alarm service will run now, and then every
-        30 seconds for 15 seconds</string>
-    <string name="alarm_service_unscheduled">Alarm service has been unscheduled</string>
-
-    <string name="activity_local_sample">App/Instrumentation/Local Sample</string>
-    <string name="local_sample">This demonstrates an Instrumentation that runs against
-        one of our own classes.  Note that this activity will be killed as
-        a side-effect of starting instrumentation on its own application.</string>
-
-    <string name="activity_contacts_filter">App/Instrumentation/Contacts Filter</string>
-    <string name="contacts_filter">This demonstrates an Instrumentation package that
-        launches the contacts list and simulates user events to filter it.</string>
-
-    <string name="pick_image_label">App/Activity/PickImage</string>
-    <string name="pick_image">Pick Image</string>
-
-    <string name="short_notification_text">Short notification</string>
-    <string name="long_notification_text">This is a long notification.  See, you might need a second more to read it.</string>
-    <string name="status_bar_notification_title">Sample Notification</string>
-
-    <string name="notifying_service_controller">This service will update a status bar notification
-                  every 5 seconds for a minute</string>
-
-    <string name="activity_custom_title">App/Activity/Custom Title</string>
-    <string name="custom_title_left">Left is best</string>
-    <string name="custom_title_right">Right is always right</string>
-    <string name="custom_title_left_button">Change Left</string>
-    <string name="custom_title_right_button">Change Right</string>
-
-    <string name="activity_reorder">App/Activity/Reorder Activities</string>
-    <string name="reorder_on_launch">This is the first of a sequence of four Activities.  A button on the fourth will use the Intent.FLAG_ACTIVITY_REORDER_TO_FRONT flag to bring the second of the activities to the front of the history stack. After that, proceeding back through the history should begin with the newly-frontmost second reorder activity, then the fourth, the third, and finally the first.</string>
-    <string name="reorder_launch_two">Go to the second</string>
-    <string name="reorder_two_text">This is the second in a sequence of four Activities.</string>
-    <string name="reorder_launch_three">Go to the third</string>
-    <string name="reorder_three_text">This is the third of a sequence of four Activities.</string>
-    <string name="reorder_launch_four">Go to the fourth</string>
-    <string name="reorder_four_text">This is the last in a sequence of four Activities.</string>
-    <string name="reorder_second_to_front">Bring the second in front</string>
-
-    <string name="menu_from_xml_title">App/Menu/Inflate from XML</string>
-    <string name="menu_from_xml_instructions_press_menu">Select a menu resource and press the menu key.</string>
-    <string name="menu_from_xml_instructions_go_back">If you want to choose another menu resource, go back and re-run this activity.</string>
-
-    <string name="voice_recognition">App/Voice Recognition</string>
-
-    <!-- ============================== -->
-    <!--  app/content examples strings  -->
-    <!-- ============================== -->
-
-    <string name="activity_styled_text">Content/Resources/<i>Styled</i> <b>Text</b></string>
-    <string name="styled_text_rsrc">Initialized from a resource:</string>
-    <string name="styled_text">Plain, <b>bold</b>, <i>italic</i>, <b><i>bold-italic</i></b></string>
-    <string name="styled_text_prog">Assigned programmatically:</string>
-
-    <string name="activity_read_asset">Content/Assets/Read Asset</string>
-
-    <string name="activity_themes">Content/Resources/Themes</string>
-    <string name="activity_resources">Content/Resources/Resources</string>
-
-    <!-- ============================== -->
-    <!--  app/intents examples strings     -->
-    <!-- ============================== -->
-    
-    <string name="activity_intents">App/Intents</string>
-    <string name="intents">Example of launching various Intents.</string>
-    <string name="get_music">Get Music</string>
-        
-    <!-- =================================== -->
-    <!--  app/notification examples strings  -->
-    <!-- =================================== -->
-
-    <string name="short_notification">Short notification.</string>
-    <string name="long_notification">Long notification.</string>
-    <string name="short_top_notification">Short top.</string>
-    <string name="short_bottom_notification">Short bottom.</string>
-    <string name="short_center_notification">Short center.</string>
-    <string name="short_left_notification">Short left.</string>
-    <string name="short_right_notification">Short right.</string>
-    <string name="custom_notification">Custom Notification:</string>
-    <string name="custom_notification_button">With a Button</string>
-
-    <string name="status_bar_notifications_icons_only">Icons only</string>
-    <string name="status_bar_notifications_icons_and_marquee">Icons and marquee</string>
-    <string name="status_bar_notifications_remote_views">Use remote views in balloon</string>
-    <string name="status_bar_notifications_defaults">Use default values where applicable</string>
-    <string name="status_bar_notifications_happy">:-)</string>
-    <string name="status_bar_notifications_ok">:-|</string>
-    <string name="status_bar_notifications_sad">:-(</string>
-    <string name="status_bar_notifications_happy_message">I am happy</string>
-    <string name="status_bar_notifications_ok_message">I am ok</string>
-    <string name="status_bar_notifications_sad_message">I am sad</string>
-    <string name="status_bar_notifications_clear">Clear notification</string>
-    <string name="status_bar_notifications_mood_title">Mood ring</string>
-    <string name="status_bar_notifications_default_sound">Sound</string>
-    <string name="status_bar_notifications_default_vibrate">Vibrate</string>
-    <string name="status_bar_notifications_default_all">All</string>
-
-    <!-- ============================== -->
-    <!--  app/dialog examples strings  -->
-    <!-- ============================== -->
-
-    <string name="activity_alert_dialog">App/Dialog</string>
-    <string name="alert_dialog_two_buttons">OK Cancel dialog with a message</string>
-    <string name="alert_dialog_two_buttons2">OK Cancel dialog with a long message</string>
-    <string name="alert_dialog_select_button">List dialog</string>
-    <string name="alert_dialog_single_choice">Single choice list</string>
-    <string name="alert_dialog_multi_choice">Repeat alarm</string>
-    <string name="alert_dialog_progress_button">Progress dialog</string>
-    <string name="alert_dialog_text_entry">Text Entry dialog</string>
-    <string name="alert_dialog_username">Name:</string>
-    <string name="alert_dialog_password">Password:</string>
-    <string name="alert_dialog_two_buttons_title">
-        Lorem ipsum dolor sit aie consectetur adipiscing\nPlloaso mako nuto
-        siwuf cakso dodtos anr koop.
-    </string>
-    <string name="alert_dialog_two_buttons_msg">Header title</string>
-    <string name="alert_dialog_two_buttons2_msg">
-        Plloaso mako nuto siwuf cakso dodtos anr koop a
-        cupy uf cak vux noaw yerw phuno. Whag schengos, uf efed, quiel
-        ba mada su otrenzr.\n\nSwipontgwook proudgs hus yag su ba dagarmidad.
-        Plasa maku noga wipont trenzsa schengos ent kaap zux comy.\n\nWipont trenz
-        kipg naar mixent phona. Cak pwico siructiun
-        ruous nust apoply tyu cak Uhex sisulutiun munityuw uw dseg
-    </string>
-    <string name="alert_dialog_ok">OK</string>
-    <string name="alert_dialog_hide">Hide</string>
-    <string name="alert_dialog_something">Something</string>
-    <string name="alert_dialog_cancel">Cancel</string>
-    <string name="alert_dialog_progress_text1">34<xliff:g id="percent">%</xliff:g></string>
-    <string name="alert_dialog_progress_text2">145/305 KB</string>
-
-    <string name="select_dialog">Header title</string>
-    <string name="select_dialog_show">List dialog</string>
-
-    <!-- ============================== -->
-    <!--  app/menu examples strings     -->
-    <!-- ============================== -->
-
-    <string name="last_most_often">Last most often</string>
-    <string name="middle_most_often">Middle most often</string>
-    <string name="first_most_often">First most often</string>
-    <string name="last_least_often">Last least often</string>
-    <string name="middle_least_often">Middle least often</string>
-    <string name="first_least_often">First least often</string>
-    <string name="item_1">Item 1</string>
-    <string name="item_2">Item 2</string>
-    <string name="item_3">Item 3</string>
-    <string name="browser_visibility">Browser visibility</string>
-    <string name="browser_refresh">Refresh</string>
-    <string name="browser_bookmark">Bookmark</string>
-    <string name="email_visibility">Email visibility</string>
-    <string name="email_reply">Reply</string>
-    <string name="email_forward">Forward</string>
-    <string name="jump">Jump</string>
-    <string name="dive">Dive</string>
-
-    <!-- ============================== -->
-    <!--  app/menu examples strings     -->
-    <!-- ============================== -->
-
-    <string name="preferences_from_xml">App/Preferences/1. Preferences from XML</string>
-    <string name="launching_preferences">App/Preferences/2. Launching preferences</string>
-    <string name="preference_dependencies">App/Preferences/3. Preference dependencies</string>
-    <string name="default_values">App/Preferences/4. Default values</string>
-    <string name="preferences_from_code">App/Preferences/5. Preferences from code</string>
-    <string name="advanced_preferences">App/Preferences/6. Advanced preferences</string>
-
-    <string name="launch_preference_activity">Launch PreferenceActivity</string>
-    <string name="counter_value_is">The counter value is</string>
-
-    <string name="inline_preferences">In-line preferences</string>
-    <string name="dialog_based_preferences">Dialog-based preferences</string>
-    <string name="launch_preferences">Launch preferences</string>
-    <string name="preference_attributes">Preference attributes</string>
-
-    <string name="title_toggle_preference">Toggle preference</string>
-    <string name="summary_toggle_preference">This is a toggle button</string>
-
-    <string name="title_checkbox_preference">Checkbox preference</string>
-    <string name="summary_checkbox_preference">This is a checkbox</string>
-
-    <string name="title_yesno_preference">Yes or no preference</string>
-    <string name="summary_yesno_preference">An example that uses a yes/no dialog</string>
-    <string name="dialog_title_yesno_preference">Do you like bananas?</string>
-
-    <string name="title_edittext_preference">Edit text preference</string>
-    <string name="summary_edittext_preference">An example that uses an edit text dialog</string>
-    <string name="dialog_title_edittext_preference">Enter your favorite animal</string>
-
-    <string name="title_list_preference">List preference</string>
-    <string name="summary_list_preference">An example that uses a list dialog</string>
-    <string name="dialog_title_list_preference">Choose one</string>
-
-    <string name="title_screen_preference">Screen preference</string>
-    <string name="summary_screen_preference">Shows another screen of preferences</string>
-
-    <string name="title_next_screen_toggle_preference">Toggle preference</string>
-    <string name="summary_next_screen_toggle_preference">Preference that is on the next screen but same hierarchy</string>
-
-    <string name="title_intent_preference">Intent preference</string>
-    <string name="summary_intent_preference">Launches an Activity from an Intent</string>
-
-    <string name="title_my_preference">My preference</string>
-    <string name="summary_my_preference">This is a custom counter preference</string>
-
-    <string name="title_advanced_toggle_preference">Haunted preference</string>
-    <string name="summary_on_advanced_toggle_preference">I'm on! :)</string>
-    <string name="summary_off_advanced_toggle_preference">I'm off! :(</string>
-
-    <string name="title_parent_preference">Parent toggle</string>
-    <string name="summary_parent_preference">This is visually a parent</string>
-    <string name="title_child_preference">Child toggle</string>
-    <string name="summary_child_preference">This is visually a child</string>
-
-    <string name="example_preference_dependency">Example preference dependency</string>
-    <string name="title_wifi">WiFi</string>
-    <string name="title_wifi_settings">WiFi settings</string>
-
-    <string name="default_value_list_preference">beta</string>
-    <string name="default_value_edittext_preference">Default value</string>
-
-    <!-- ============================== -->
-    <!--  app/search examples strings  -->
-    <!-- ============================== -->
-
-    <string name="search_invoke">App/Search/Invoke Search</string>
-    <string name="msg_search">This activity shows a few different ways to invoke search, and inserts context-specific data for use by the search activity.</string>
-    <string name="search_sect_invocation">Ways to invoke search</string>
-    <string name="label_onsearchrequested">onSearchRequested()</string>
-    <string name="search_sect_options">Optional search parameters</string>
-    <string name="label_search_query_prefill">"Prefill query: "</string>
-    <string name="label_search_query_appdata">"App Data: "</string>
-
-    <string name="search_query_results">App/Search/Query Search Results</string>
-    <string name="msg_search_results">This activity accepts query strings via the ACTION_SEARCH intent.  In a full implementation, you would use the query string to select results from your data source, and present a list of those results to the user.</string>
-    <string name="label_search_query">"Query String: "</string>
-    <string name="label_search_appdata">"Query App Data: "</string>
-    <string name="label_search_deliveredby">"Activity Method: "</string>
-
-    <string name="search_label">Search Demo</string>
-    <string name="search_hint">Search Demo Hint</string>
-
-    <!-- ================================ -->
-    <!--  app/shortcuts examples strings  -->
-    <!-- ================================ -->
-
-    <string name="shortcuts">App/Launcher Shortcuts</string>
-    <string name="sample_shortcuts">ApiDemos</string>
-    <string name="shortcut_name">Sample</string>
-
-    <string name="msg_launcher_shortcuts">This activity creates shortcuts for the launcher (home screen), and receives intents from those shortcuts.  To try it, return to the launcher and long-press to create a shortcut.</string>
-    <string name="label_intent">Intent:</string>
-    
-    <!-- ============================== -->
-    <!--  app/voice recognition examples strings  -->
-    <!-- ============================== -->
-
-    <string name="voice_recognition_prompt">This activity demonstrates the voice recognition APIs.</string>
-    <string name="speak_button">Speak!</string>
-    <string name="voice_recognition_results">Results:</string>
-    
-    <!-- ============================ -->
-    <!--  graphics examples strings  -->
-    <!-- ============================ -->
-
-    <string name="hide_me">Hide Me!</string>
-
-    <!-- ============================ -->
-    <!--  media examples strings  -->
-    <!-- ============================ -->
-
-    <string name="local_video">Play Video from Local File</string>
-    <string name="stream_video">Play Streaming Video</string>
-    <string name="local_audio">Play Audio from Local File</string>
-    <string name="res_audio">Play Audio from Resources</string>
-
-    <!-- ============================ -->
-    <!--  views examples strings  -->
-    <!-- ============================ -->
-
-    <string name="linear_layout_8_vertical">Vertical</string>
-    <string name="linear_layout_8_horizontal">Horizontal</string>
-    <string name="linear_layout_8_top">Top</string>
-    <string name="linear_layout_8_middle">Middle</string>
-    <string name="linear_layout_8_bottom">Bottom</string>
-    <string name="linear_layout_8_left">Left</string>
-    <string name="linear_layout_8_center">Center</string>
-    <string name="linear_layout_8_right">Right</string>
-    <string name="linear_layout_10_from">From:</string>
-    <string name="linear_layout_10_to">To:</string>
-    <string name="list_7_nothing">Nothing\u2026</string>
-    <string name="radio_group_snack">Snack</string>
-    <string name="radio_group_selection">"You have selected: "</string>
-    <string name="radio_group_none">(none)</string>
-    <string name="table_layout_7_quit">Quit</string>
-    <string name="table_layout_7_ctrlq">Ctrl-Q</string>
-    <string name="table_layout_8_quit">Quit</string>
-    <string name="table_layout_8_ctrlq">Ctrl-Q</string>
-
-    <string name="seekbar_tracking_on">Tracking on</string>
-    <string name="seekbar_tracking_off">Tracking off</string>
-    <string name="seekbar_from_touch">from touch</string>
-
-    <string name="ratingbar_rating">Rating:</string>
-
-    <!-- ============================== -->
-    <!--  GoogleLogin examples strings  -->
-    <!-- ============================== -->
-    <string name="googlelogin_err">Use a better username and password, please.</string>
-
-
-    <!-- ================================== -->
-    <!--  initial strings for layout files  -->
-    <!-- ================================== -->
-    <string name="animation_1_instructions">Please enter your password:</string>
-    <string name="animation_2_text_1">Freedom</string>
-    <string name="animation_2_text_2">is nothing else but</string>
-    <string name="animation_2_text_3">a chance to be better.</string>
-    <string name="animation_2_text_4">— Albert Camus</string>
-    <string name="animation_2_instructions">Select an animation:</string>
-    <string name="autocomplete_1_instructions">Type in the text field for auto-completion.</string>
-    <string name="autocomplete_1_country">Country:</string>
-    <string name="autocomplete_1_focus">Give me Focus</string>
-    <string name="autocomplete_2_country">Country:</string>
-    <string name="autocomplete_2_focus">Give me Focus</string>
-    <string name="autocomplete_3_button_1">Scroll</string>
-    <string name="autocomplete_3_button_2">Down</string>
-    <string name="autocomplete_3_button_3">To</string>
-    <string name="autocomplete_3_button_4">See</string>
-    <string name="autocomplete_3_button_5">Auto</string>
-    <string name="autocomplete_3_button_6">Complete</string>
-    <string name="autocomplete_3_button_7">Text</string>
-    <string name="autocomplete_3_button_8">View</string>
-    <string name="autocomplete_3_button">Button</string>
-    <string name="autocomplete_3_country">Country:</string>
-    <string name="autocomplete_4_instructions">Type in the text field for auto-completion.</string>
-    <string name="autocomplete_4_name">Name:</string>
-    <string name="autocomplete_4_message">You must have contacts in your address book. Typing * will show all of your contacts.</string>
-    <string name="autocomplete_5_instructions">Type in the text field for auto-completion.</string>
-    <string name="autocomplete_5_hint">Typing * will show all of your contacts.</string>
-    <string name="autocomplete_5_name">Name:</string>
-    <string name="autocomplete_6_to">To:</string>
-    <string name="autocomplete_6_to_hint">To</string>
-    <string name="autocomplete_6_subject">Subject:</string>
-    <string name="autocomplete_7_instructions">Type in the text field for auto-completion by words.</string>
-    <string name="autocomplete_7_country">Country:</string>
-    <string name="autocomplete_7_focus">Give me Focus</string>
-    <string name="baseline_1_label">Label:</string>
-    <string name="baseline_1_button">Button</string>
-    <string name="baseline_1_bigger">Bigger</string>
-    <string name="baseline_2_label">Label:</string>
-    <string name="baseline_2_button">Button</string>
-    <string name="baseline_2_bigger">Bigger</string>
-    <string name="baseline_3_label">Label:</string>
-    <string name="baseline_3_button">Button</string>
-    <string name="baseline_3_bigger">Bigger</string>
-    <string name="baseline_3_explanation">This example shows that baseline alignment has no effect when the layout gravity is set to center_vertical.</string>
-    <string name="baseline_4_label">Label:</string>
-    <string name="baseline_4_button">Button</string>
-    <string name="baseline_4_bigger">Bigger</string>
-    <string name="baseline_4_label_2">Label Again</string>
-    <string name="baseline_4_label_3">Label Me</string>
-    <string name="baseline_6_multi_line">This is a\nmulti-line field.</string>
-    <string name="baseline_6_baseline">Baseline Aligned</string>
-    <string name="baseline_7_fat">Big and bold</string>
-    <string name="baseline_7_lean">Slim and slick.</string>
-    <string name="baseline_nested_1_label">label</string>
-    <string name="controls_1_save">Save</string>
-    <string name="controls_1_checkbox_1">Checkbox 1</string>
-    <string name="controls_1_checkbox_2">Checkbox 2</string>
-    <string name="controls_1_radiobutton_1">RadioButton 1</string>
-    <string name="controls_1_radiobutton_2">RadioButton 2</string>
-    <string name="controls_1_star">Star</string>
-    <string name="focus_1_message">Service not running</string>
-    <string name="focus_1_placeholder">placeholder</string>
-    <string name="focus_2_left">left</string>
-    <string name="focus_2_jump">jump over me from L to R</string>
-    <string name="focus_2_right">right</string>
-    <string name="focus_3_left">left</string>
-    <string name="focus_3_right">right</string>
-    <string name="focus_3_top">top</string>
-    <string name="focus_3_bottom">bottom</string>
-    <string name="gallery_2_text">Testing</string>
-    <string name="googlelogin_login">Login</string>
-    <string name="googlelogin_bad_login">Bad Login</string>
-    <string name="googlelogin_clear">Clear Credentials</string>
-    <string name="googlelogin_user">Username:</string>
-    <string name="layout_animation_name">Name:</string>
-    <string name="layout_animation_lastname">Last Name:</string>
-    <string name="layout_animation_phone">Phone:</string>
-    <string name="layout_animation_address">Address:</string>
-    <string name="linear_layout_1_top">This is the top view.</string>
-    <string name="linear_layout_1_middle">This is the middle view. It has more text in it than either the top view or the bottom view.</string>
-    <string name="linear_layout_1_bottom">This is the bottom view.</string>
-    <string name="linear_layout_2_top">This is the top view.</string>
-    <string name="linear_layout_2_middle">This is the middle view. It has more text in it than either the top view or the bottom view.</string>
-    <string name="linear_layout_2_bottom">This is the bottom view.</string>
-    <string name="linear_layout_3_top">This is the top view.</string>
-    <string name="linear_layout_3_middle">This is the middle view. It has more text in it than either the top view or the bottom view.</string>
-    <string name="linear_layout_3_bottom">This is the bottom view.</string>
-    <string name="linear_layout_5_instructions">Type Here:</string>
-    <string name="linear_layout_5_cancel">Cancel</string>
-    <string name="linear_layout_5_ok">OK</string>
-    <string name="linear_layout_6_one">One</string>
-    <string name="linear_layout_6_two">Two</string>
-    <string name="linear_layout_6_three">This is the third one</string>
-    <string name="linear_layout_6_four">Four</string>
-    <string name="linear_layout_7_small">Not much text</string>
-    <string name="linear_layout_7_big">A lot more text than any of the other columns. This column should set the height of the linear layout.</string>
-    <string name="linear_layout_7_wrap">wrap_content</string>
-    <string name="linear_layout_8_a">A</string>
-    <string name="linear_layout_8_b">B</string>
-    <string name="linear_layout_8_c">C</string>
-    <string name="linear_layout_9_button">Button</string>
-    <string name="link_text_auto"><b>text1:</b> This is some text.  In
-      this text are some things that are actionable.  For instance,
-      you can click on http://www.google.com and it will launch the
-      web browser.  You can click on google.com too.  And, if you
-      click on (415) 555-1212 it should dial the phone.
-    </string>
-    <string name="link_text_manual"><b>text2:</b> This is some other
-      text, with a <a href="http://www.google.com">link</a> specified
-      via an &lt;a&gt; tag.  Use a \"tel:\" URL
-      to <a href="tel:4155551212">dial a phone number</a>.
-    </string>
-    <string name="list_8_new_photo">New photo</string>
-    <string name="list_8_clear_photos">Clear photos</string>
-    <string name="list_8_no_photos">No photos</string>
-    <string name="progressbar_1_plus">+</string>
-    <string name="progressbar_1_minus">-</string>
-    <string name="progressbar_1_default_progress">Default progress:</string>
-    <string name="progressbar_1_secondary_progress">Secondary progress:</string>
-    <string name="progressbar_3_progress">Show Progress</string>
-    <string name="progressbar_3_indeterminate">Show Indeterminate</string>
-    <string name="progressbar_3_indeterminate_no_title">Show Indeterminate No Title</string>
-    <string name="progressbar_4_toggle">Toggle Indeterminate</string>
-    <string name="radio_group_1_breakfast">Breakfast</string>
-    <string name="radio_group_1_lunch">Lunch</string>
-    <string name="radio_group_1_dinner">Dinner</string>
-    <string name="radio_group_1_all">All of them</string>
-    <string name="radio_group_1_selection">You have selected: (none)</string>
-    <string name="radio_group_1_clear">Clear</string>
-    <string name="receive_result_instructions">Press the button to get an activity result, which will be displayed here:</string>
-    <string name="receive_result_result">Get Result</string>
-    <string name="relative_layout_1_top">Top</string>
-    <string name="relative_layout_1_bottom">Bottom</string>
-    <string name="relative_layout_1_center">center_vertical</string>
-    <string name="relative_layout_2_instructions">Type here:</string>
-    <string name="relative_layout_2_ok">Ok</string>
-    <string name="relative_layout_2_cancel">Cancel</string>
-    <string name="scroll_view_1_text_1">Text View 1</string>
-    <string name="scroll_view_1_button_1">Button 1</string>
-    <string name="scroll_view_1_text_2">Text View 2</string>
-    <string name="scroll_view_1_button_2">Button 2</string>
-    <string name="scroll_view_1_text_3">Text View 3</string>
-    <string name="scroll_view_1_button_3">Button 3</string>
-    <string name="scroll_view_1_text_4">Text View 4</string>
-    <string name="scroll_view_1_button_4">Button 4</string>
-    <string name="scroll_view_1_text_5">Text View 5</string>
-    <string name="scroll_view_1_button_5">Button 5</string>
-    <string name="scroll_view_1_text_6">Text View 6</string>
-    <string name="scroll_view_1_button_6">Button 6</string>
-    <string name="scroll_view_2_text_1">Text View 1</string>
-    <string name="scroll_view_2_button_1">Button 1</string>
-    <string name="scrollbar_1_text">Lorem ipsum dolor sit amet.</string>
-    <string name="scrollbar_2_text">Lorem ipsum dolor sit amet.</string>
-    <string name="scrollbar_3_text">
- The Android platform is a software stack for mobile devices including an
- operating system, middleware and key applications. Developers can create
- applications for the platform using the Android SDK. Applications are written
- using the Java programming language and run on Dalvik, a custom virtual
- machine designed for embedded use which runs on top of a Linux kernel.
-
- If you want to know how to develop applications for Android, you're in the
- right place. This site provides a variety of documentation that will help you
- learn about Android and develop mobile applications for the platform.
-
- An early look at the the Android SDK is also available. It includes sample
- projects with source code, development tools, an emulator, and of course all
- the libraries you'll need to build an Android application. What would it take
- to build a better mobile phone?
-    </string>
-    <string name="spinner_1_color">Color:</string>
-    <string name="spinner_1_planet">Planet:</string>
-    <string name="spinner_1_color_prompt">Choose a color</string>
-    <string name="spinner_1_planet_prompt">Choose a planet</string>
-    <string name="table_layout_1_star">*</string>
-    <string name="table_layout_1_triple_star">***</string>
-    <string name="table_layout_1_open">Open\u2026</string>
-    <string name="table_layout_1_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_1_save">Save As\u2026</string>
-    <string name="table_layout_1_save_shortcut">(Save Document)</string>
-    <string name="table_layout_1_quit">Quit Application</string>
-    <string name="table_layout_1_quit_shortcut">Ctrl-Shift-Q</string>
-    <string name="table_layout_2_path_1">~/path/to/file/to/open</string>
-    <string name="table_layout_2_path_2">~/.profile</string>
-    <string name="table_layout_2_open">Open</string>
-    <string name="table_layout_2_save">Save</string>
-    <string name="table_layout_2_save_all">Save All</string>
-    <string name="table_layout_3_star">*</string>
-    <string name="table_layout_3_triple_star">***</string>
-    <string name="table_layout_3_open">Open\u2026</string>
-    <string name="table_layout_3_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_3_save">Save As\u2026</string>
-    <string name="table_layout_3_save_shortcut">(Save Document)</string>
-    <string name="table_layout_3_too_long">Too Long</string>
-    <string name="table_layout_3_quit">Quit Application</string>
-    <string name="table_layout_3_quit_shortcut">Ctrl-Shift-Q</string>
-    <string name="table_layout_4_open">Open\u2026</string>
-    <string name="table_layout_4_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_4_save">Save As\u2026</string>
-    <string name="table_layout_4_save_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_5_open">Open\u2026</string>
-    <string name="table_layout_5_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_5_save">Save\u2026</string>
-    <string name="table_layout_5_save_shortcut">Ctrl-S</string>
-    <string name="table_layout_5_save_as">Save As\u2026</string>
-    <string name="table_layout_5_save_as_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_5_import">Import\u2026</string>
-    <string name="table_layout_5_export">Export\u2026</string>
-    <string name="table_layout_5_export_shortcut">Ctrl-E</string>
-    <string name="table_layout_5_quit">Quit\u2026</string>
-    <string name="table_layout_6_x">X</string>
-    <string name="table_layout_6_open">Open\u2026</string>
-    <string name="table_layout_6_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_6_save">Save\u2026</string>
-    <string name="table_layout_6_save_shortcut">Ctrl-S</string>
-    <string name="table_layout_6_save_as">Save As\u2026</string>
-    <string name="table_layout_6_save_as_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_6_import">Import\u2026</string>
-    <string name="table_layout_6_export">Export\u2026</string>
-    <string name="table_layout_6_export_shortcut">Ctrl-E</string>
-    <string name="table_layout_6_quit">Quit\u2026</string>
-    <string name="table_layout_7_x">X</string>
-    <string name="table_layout_7_open">Open\u2026</string>
-    <string name="table_layout_7_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_7_save">Save\u2026</string>
-    <string name="table_layout_7_save_shortcut">Ctrl-S</string>
-    <string name="table_layout_7_save_as">Save As\u2026</string>
-    <string name="table_layout_7_save_as_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_7_import">Import\u2026</string>
-    <string name="table_layout_7_export">Export\u2026</string>
-    <string name="table_layout_7_export_shortcut">Ctrl-E</string>
-    <string name="table_layout_7_toggle_checkmarks">Toggle Checkmarks</string>
-    <string name="table_layout_7_toggle_shortcuts">Toggle Shortcuts</string>
-    <string name="table_layout_8_x">X</string>
-    <string name="table_layout_8_open">Open\u2026</string>
-    <string name="table_layout_8_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_8_save">Save\u2026</string>
-    <string name="table_layout_8_save_shortcut">Ctrl-S</string>
-    <string name="table_layout_8_save_as">Save As\u2026</string>
-    <string name="table_layout_8_save_as_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_8_import">Import\u2026</string>
-    <string name="table_layout_8_export">Export\u2026</string>
-    <string name="table_layout_8_export_shortcut">Ctrl-E</string>
-    <string name="table_layout_8_toggle_stretch">Toggle Stretch</string>
-    <string name="table_layout_9_open">Open\u2026</string>
-    <string name="table_layout_9_open_shortcut">Ctrl-O</string>
-    <string name="table_layout_9_save">Save\u2026</string>
-    <string name="table_layout_9_save_shortcut">Ctrl-S</string>
-    <string name="table_layout_9_save_as">Save As\u2026</string>
-    <string name="table_layout_9_save_as_shortcut">Ctrl-Shift-S</string>
-    <string name="table_layout_9_save_all">Save All And Do A Lot Of Stuff Just To Be Too Long For This Screen Because It Is A Test After All</string>
-    <string name="table_layout_9_save_all_shortcut">Ctrl-E</string>
-    <string name="table_layout_9_import">Import\u2026</string>
-    <string name="table_layout_9_export">Export\u2026</string>
-    <string name="table_layout_9_export_shortcut">Ctrl-E</string>
-    <string name="table_layout_9_toggle_shrink">Toggle Shrink</string>
-    <string name="table_layout_10_user">User</string>
-    <string name="table_layout_10_password">Password</string>
-    <string name="table_layout_10_cancel">Cancel</string>
-    <string name="table_layout_10_login">Login</string>
-    <string name="table_layout_12_a">A</string>
-    <string name="table_layout_12_b">BB</string>
-    <string name="table_layout_12_c">CCCC</string>
-    <string name="table_layout_12_d">D</string>
-    <string name="table_layout_12_e">E</string>
-    <string name="table_layout_12_f">F</string>
-    <string name="table_layout_12_g">G</string>
-    <string name="table_layout_12_h">H</string>
-    <string name="visibility_1_view_1">View A</string>
-    <string name="visibility_1_view_2">View B</string>
-    <string name="visibility_1_view_3">View C</string>
-    <string name="visibility_1_vis">Vis</string>
-    <string name="visibility_1_invis">Invis</string>
-    <string name="visibility_1_gone">Gone</string>
-
-
-    <string name="google_login_username_text"></string>
-
-    <string name="incoming_message_notify_text">Show Notification</string>
-
-    <string name="incoming_message_info_message_text">this is the text of a previous message.\nkthx. meet u for dinner. cul8r</string>
-
-    <string name="incoming_message_view_message_text">this is the text of a previous message.\nkthx. meet u for dinner. cul8r</string>
-    <string name="imcoming_message_view_message2_text">Did you notice that the status bar icon disappeared?</string>
-    <string name="imcoming_message_ticker_text">New text message: <xliff:g id="text">%0$s</xliff:g></string>
-
-    <string name="log_text_box_1_do_nothing_text">Do nothing</string>
-    <string name="log_text_box_1_add_text">Add</string>
-
-    <string name="notify_with_text_long_notify_text">Show Long Notification</string>
-    <string name="notify_with_text_short_notify_text">Show Short Notification</string>
-
-    <string name="marquee_default">This use the default marquee animation limit of 3</string>
-    <string name="marquee_once">This will run the marquee animation once</string>
-    <string name="marquee_forever">This will run the marquee animation forever</string>
-
-    <string name="table_layout_10_password_text"></string>
-    <string name="table_layout_10_username_text"></string>
-
-    <string name="text_switcher_1_next_text">Next</string>
-
-    <string name="date_widgets_example_dateDisplay_text"></string>
-    <string name="date_widgets_example_pickTime_text">change the time</string>
-    <string name="date_widgets_example_pickDate_text">change the date</string>
-
-    <string name="buttons_1_normal">Normal</string>
-    <string name="buttons_1_right">Right</string>
-    <string name="buttons_1_small">Small</string>
-    <string name="buttons_1_small_right">S R</string>
-    <string name="buttons_1_small_left">S L</string>
-    <string name="buttons_1_small_up">S U</string>
-    <string name="buttons_1_small_down">S D</string>
-    <string name="buttons_1_toggle">Toggle</string>
-
-    <string name="expandable_list_sample_action">Sample action</string>
-
-    <string name="chronometer_start">Start</string>
-    <string name="chronometer_stop">Stop</string>
-    <string name="chronometer_reset">Reset</string>
-    <string name="chronometer_set_format">Set format string</string>
-    <string name="chronometer_clear_format">Clear format string</string>
-    <string name="chronometer_initial_format">Initial format: <xliff:g id="initial-format">%s</xliff:g></string>
-
-    <!-- ============================ -->
-    <!--  vibrator examples strings  -->
-    <!-- ============================ -->
-
-    <string name="vibrate">Vibrate</string>
-
-
-    <string name="image_view_large_normal">Large image at normal size</string>
-    <string name="image_view_large_at_most">Large image scaled to at most 50x50</string>
-    <string name="image_view_large_at_most_padded">Large image scaled to at most 70x70 with padding</string>
-    <string name="image_view_large_exactly_padded">Large image scaled to exactly 70x70 with padding</string>
-    <string name="image_view_small_normal">Small image at normal size</string>
-    <string name="image_view_small_at_most">Small image scaled to at most 50x50</string>
-    <string name="image_view_small_at_most_padded">Small image scaled to at most 70x70 with padding</string>
-    <string name="image_view_small_exactly_padded">Small image scaled to exactly 70x70 with padding</string>
-
-    <!-- Shouldn't be localized -->
-    <string name="textColorPrimary">textColorPrimary</string>
-    <string name="textColorSecondary">textColorSecondary</string>
-    <string name="textColorTertiary">textColorTertiary</string>
-    <string name="listSeparatorTextViewStyle">listSeparatorTextViewStyle</string>
-
-    <!-- ============================ -->
-    <!--  gadget examples strings     -->
-    <!-- ============================ -->
-
-    <string name="gadget_configure_instructions">This text will be shown before the date in our example gadget.</string>
-    <string name="gadget_prefix_default">Oh hai</string>
-    <string name="gadget_text_format"><xliff:g id="prefix">%1$s</xliff:g>: <xliff:g id="time">%2$s</xliff:g></string>
-</resources>
-
diff --git a/samples/ApiDemos/res/values/styles.xml b/samples/ApiDemos/res/values/styles.xml
deleted file mode 100644
index 40e934e..0000000
--- a/samples/ApiDemos/res/values/styles.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- Base application theme is the default theme. -->
-    <style name="Theme" parent="android:Theme">
-    </style>
-
-    <!-- Variation on our application theme that forces a plain
-        text style. -->
-    <style name="Theme.PlainText">
-        <item name="android:textAppearance">@style/TextAppearance.Theme.PlainText</item>
-    </style>
-
-    <!-- Variation on our application theme that has a black
-         background. -->
-    <style name="Theme.Black">
-        <item name="android:windowBackground">@drawable/screen_background_black</item>
-    </style>
-
-    <!-- A theme for a custom dialog appearance.  Here we use an ugly
-         custom frame. -->
-    <style name="Theme.CustomDialog" parent="android:style/Theme.Dialog">
-        <item name="android:windowBackground">@drawable/filled_box</item>
-    </style>
-
-    <!-- A theme that has a translucent background.  Here we explicitly specify
-         that this theme is to inherit from the system's translucent theme,
-         which sets up various attributes correctly.. -->
-    <style name="Theme.Translucent" parent="android:style/Theme.Translucent">
-        <item name="android:windowBackground">@drawable/translucent_background</item>
-        <item name="android:windowNoTitle">true</item>
-        <item name="android:colorForeground">#fff</item>
-    </style>
-
-    <!-- Variation on our application theme that has a transparent
-         background; this example completely removes the background,
-         allowing the activity to decide how to composite.  Also here we
-         force the translucency ourself rather than making use of the built-in
-         translucent theme. -->
-    <style name="Theme.Transparent">
-        <item name="android:windowIsTranslucent">true</item>
-        <item name="android:windowAnimationStyle">@android:style/Animation.Translucent</item>
-        <item name="android:windowBackground">@drawable/transparent_background</item>
-        <item name="android:windowNoTitle">true</item>
-        <item name="android:colorForeground">#fff</item>
-    </style>
-    
-    <style name="TextAppearance.Theme.PlainText" parent="android:TextAppearance.Theme">
-        <item name="android:textStyle">normal</item>
-    </style>
-
-</resources>
diff --git a/samples/ApiDemos/res/xml/advanced_preferences.xml b/samples/ApiDemos/res/xml/advanced_preferences.xml
deleted file mode 100644
index c362297..0000000
--- a/samples/ApiDemos/res/xml/advanced_preferences.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is an advanced example showing the custom preference types and manually handling
-     preference clicks. -->
-<PreferenceScreen
-        xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <!-- My custom preference type.  This just replaces the actual widget
-         portion of the preference, if the whole preference wanted to be
-         replaced we would use the layout attribute instead of the widgetLayout
-         attribute. -->
-    <com.example.android.apis.app.MyPreference
-            android:key="my_preference"
-            android:title="@string/title_my_preference"
-            android:summary="@string/summary_my_preference"
-            android:defaultValue="100" />
-
-    <CheckBoxPreference
-            android:key="advanced_checkbox_preference"
-            android:title="@string/title_advanced_toggle_preference"
-            android:summaryOn="@string/summary_on_advanced_toggle_preference" 
-            android:summaryOff="@string/summary_off_advanced_toggle_preference" />
-
-</PreferenceScreen>
diff --git a/samples/ApiDemos/res/xml/default_values.xml b/samples/ApiDemos/res/xml/default_values.xml
deleted file mode 100644
index da15a62..0000000
--- a/samples/ApiDemos/res/xml/default_values.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is a primitive example showing how to set default values for preferences.
-     See DefaultValues.java for more information. -->
-<PreferenceScreen
-        xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <CheckBoxPreference
-            android:key="default_toggle"
-            android:defaultValue="true"
-            android:title="@string/title_checkbox_preference"
-            android:summary="@string/summary_checkbox_preference" />
-
-    <EditTextPreference
-            android:key="default_edittext"
-            android:defaultValue="@string/default_value_edittext_preference"
-            android:title="@string/title_edittext_preference"
-            android:summary="@string/summary_edittext_preference"
-            android:dialogTitle="@string/dialog_title_edittext_preference" />
-            
-    <ListPreference
-            android:key="default_list"
-            android:defaultValue="@string/default_value_list_preference"
-            android:title="@string/title_list_preference"
-            android:summary="@string/summary_list_preference"
-            android:entries="@array/entries_list_preference"
-            android:entryValues="@array/entryvalues_list_preference"
-            android:dialogTitle="@string/dialog_title_list_preference" />
-
-</PreferenceScreen>
diff --git a/samples/ApiDemos/res/xml/gadget_provider.xml b/samples/ApiDemos/res/xml/gadget_provider.xml
deleted file mode 100644
index 9ad6845..0000000
--- a/samples/ApiDemos/res/xml/gadget_provider.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gadget-provider xmlns:android="http://schemas.android.com/apk/res/android"
-    android:minWidth="60dp"
-    android:minHeight="30dp"
-    android:updatePeriodMillis="86400000"
-    android:initialLayout="@layout/gadget_provider"
-    android:configure="com.example.android.apis.gadget.ExampleGadgetConfigure"
-    >
-</gadget-provider>
-
-<!-- 86400000 is the value of AlarmManager.INTERVAL_DAY - or once per day. -->
-
diff --git a/samples/ApiDemos/res/xml/preference_dependencies.xml b/samples/ApiDemos/res/xml/preference_dependencies.xml
deleted file mode 100644
index 5eae580..0000000
--- a/samples/ApiDemos/res/xml/preference_dependencies.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is a primitive example showing how some preferences can depend on other preferences. -->
-<PreferenceScreen
-        xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <PreferenceCategory
-            android:title="@string/example_preference_dependency">
-            
-        <CheckBoxPreference
-                android:key="wifi"
-                android:title="@string/title_wifi" />
-            
-        <EditTextPreference
-                android:layout="?android:attr/preferenceLayoutChild"
-                android:title="@string/title_wifi_settings"
-                android:dependency="wifi" />
-            
-    </PreferenceCategory>
-                
-</PreferenceScreen>
diff --git a/samples/ApiDemos/res/xml/preferences.xml b/samples/ApiDemos/res/xml/preferences.xml
deleted file mode 100644
index 59b23f1..0000000
--- a/samples/ApiDemos/res/xml/preferences.xml
+++ /dev/null
@@ -1,99 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is a primitive example showing the different types of preferences available. -->
-<PreferenceScreen
-        xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <PreferenceCategory
-            android:title="@string/inline_preferences">
-            
-        <CheckBoxPreference
-                android:key="checkbox_preference"
-                android:title="@string/title_toggle_preference"
-                android:summary="@string/summary_toggle_preference" />
-            
-    </PreferenceCategory>
-                
-    <PreferenceCategory
-            android:title="@string/dialog_based_preferences">
-
-        <EditTextPreference
-                android:key="edittext_preference"
-                android:title="@string/title_edittext_preference"
-                android:summary="@string/summary_edittext_preference"
-                android:dialogTitle="@string/dialog_title_edittext_preference" />
-                
-        <ListPreference
-                android:key="list_preference"
-                android:title="@string/title_list_preference"
-                android:summary="@string/summary_list_preference"
-                android:entries="@array/entries_list_preference"
-                android:entryValues="@array/entryvalues_list_preference"
-                android:dialogTitle="@string/dialog_title_list_preference" />
-
-    </PreferenceCategory>
-
-    <PreferenceCategory
-            android:title="@string/launch_preferences">
-
-        <!-- This PreferenceScreen tag serves as a screen break (similar to page break
-             in word processing). Like for other preference types, we assign a key
-             here so it is able to save and restore its instance state. -->
-        <PreferenceScreen
-                android:key="screen_preference"
-                android:title="@string/title_screen_preference"
-                android:summary="@string/summary_screen_preference">
-            
-            <!-- You can place more preferences here that will be shown on the next screen. -->
-                     
-            <CheckBoxPreference
-                    android:key="next_screen_checkbox_preference"
-                    android:title="@string/title_next_screen_toggle_preference"
-                    android:summary="@string/summary_next_screen_toggle_preference" />
-                
-        </PreferenceScreen>
-
-        <PreferenceScreen
-                android:title="@string/title_intent_preference"
-                android:summary="@string/summary_intent_preference">
-
-            <intent android:action="android.intent.action.VIEW"
-                    android:data="http://www.android.com" />
-
-        </PreferenceScreen>
-
-    </PreferenceCategory>
-    
-    <PreferenceCategory
-            android:title="@string/preference_attributes">
-    
-        <CheckBoxPreference
-                android:key="parent_checkbox_preference"
-                android:title="@string/title_parent_preference"
-                android:summary="@string/summary_parent_preference" />
-
-        <!-- The visual style of a child is defined by this styled theme attribute. -->
-        <CheckBoxPreference
-                android:key="child_checkbox_preference"
-                android:dependency="parent_checkbox_preference"
-                android:layout="?android:attr/preferenceLayoutChild"
-                android:title="@string/title_child_preference"
-                android:summary="@string/summary_child_preference" />
-            
-    </PreferenceCategory>
-    
-</PreferenceScreen>
diff --git a/samples/ApiDemos/res/xml/searchable.xml b/samples/ApiDemos/res/xml/searchable.xml
deleted file mode 100644
index df4ef7a..0000000
--- a/samples/ApiDemos/res/xml/searchable.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- The attributes in this XML file provide configuration information -->
-<!-- for the Search Manager. -->
-
-<searchable xmlns:android="http://schemas.android.com/apk/res/android"
-    android:label="@string/search_label"
-    android:hint="@string/search_hint" 
-    android:searchMode="showSearchLabelAsBadge"
-    
-    android:voiceSearchMode="showVoiceSearchButton|launchRecognizer"
-    android:voiceLanguageModel="free_form"
-    android:voicePromptText="@string/search_invoke"
-
-    android:searchSuggestAuthority="com.example.android.apis.SuggestionProvider"
-    android:searchSuggestSelection=" ? "
-/>
diff --git a/samples/ApiDemos/src/com/example/android/apis/ApiDemos.java b/samples/ApiDemos/src/com/example/android/apis/ApiDemos.java
deleted file mode 100644
index 78b1fd7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/ApiDemos.java
+++ /dev/null
@@ -1,146 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis;
-
-import android.app.ListActivity;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.ListView;
-import android.widget.SimpleAdapter;
-
-import java.text.Collator;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-public class ApiDemos extends ListActivity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        Intent intent = getIntent();
-        String path = intent.getStringExtra("com.example.android.apis.Path");
-        
-        if (path == null) {
-            path = "";
-        }
-
-        setListAdapter(new SimpleAdapter(this, getData(path),
-                android.R.layout.simple_list_item_1, new String[] { "title" },
-                new int[] { android.R.id.text1 }));
-        getListView().setTextFilterEnabled(true);
-    }
-
-    protected List getData(String prefix) {
-        List<Map> myData = new ArrayList<Map>();
-
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_SAMPLE_CODE);
-
-        PackageManager pm = getPackageManager();
-        List<ResolveInfo> list = pm.queryIntentActivities(mainIntent, 0);
-
-        if (null == list)
-            return myData;
-
-        String[] prefixPath;
-        
-        if (prefix.equals("")) {
-            prefixPath = null;
-        } else {
-            prefixPath = prefix.split("/");
-        }
-        
-        int len = list.size();
-        
-        Map<String, Boolean> entries = new HashMap<String, Boolean>();
-
-        for (int i = 0; i < len; i++) {
-            ResolveInfo info = list.get(i);
-            CharSequence labelSeq = info.loadLabel(pm);
-            String label = labelSeq != null
-                    ? labelSeq.toString()
-                    : info.activityInfo.name;
-            
-            if (prefix.length() == 0 || label.startsWith(prefix)) {
-                
-                String[] labelPath = label.split("/");
-
-                String nextLabel = prefixPath == null ? labelPath[0] : labelPath[prefixPath.length];
-
-                if ((prefixPath != null ? prefixPath.length : 0) == labelPath.length - 1) {
-                    addItem(myData, nextLabel, activityIntent(
-                            info.activityInfo.applicationInfo.packageName,
-                            info.activityInfo.name));
-                } else {
-                    if (entries.get(nextLabel) == null) {
-                        addItem(myData, nextLabel, browseIntent(prefix.equals("") ? nextLabel : prefix + "/" + nextLabel));
-                        entries.put(nextLabel, true);
-                    }
-                }
-            }
-        }
-
-        Collections.sort(myData, sDisplayNameComparator);
-        
-        return myData;
-    }
-
-    private final static Comparator<Map> sDisplayNameComparator = new Comparator<Map>() {
-        private final Collator   collator = Collator.getInstance();
-
-        public int compare(Map map1, Map map2) {
-            return collator.compare(map1.get("title"), map2.get("title"));
-        }
-    };
-
-    protected Intent activityIntent(String pkg, String componentName) {
-        Intent result = new Intent();
-        result.setClassName(pkg, componentName);
-        return result;
-    }
-    
-    protected Intent browseIntent(String path) {
-        Intent result = new Intent();
-        result.setClass(this, ApiDemos.class);
-        result.putExtra("com.example.android.apis.Path", path);
-        return result;
-    }
-
-    protected void addItem(List<Map> data, String name, Intent intent) {
-        Map<String, Object> temp = new HashMap<String, Object>();
-        temp.put("title", name);
-        temp.put("intent", intent);
-        data.add(temp);
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) {
-        Map map = (Map) l.getItemAtPosition(position);
-
-        Intent intent = (Intent) map.get("intent");
-        startActivity(intent);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/ApiDemosApplication.java b/samples/ApiDemos/src/com/example/android/apis/ApiDemosApplication.java
deleted file mode 100644
index 92460e5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/ApiDemosApplication.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis;
-
-import com.example.android.apis.app.DefaultValues;
-
-import android.app.Application;
-import android.preference.PreferenceManager;
-
-/**
- * This is an example of a {@link android.app.Application} class.  Ordinarily you would use
- * a class like this as a central repository for information that might be shared between multiple
- * activities.
- * 
- * In this case, we have not defined any specific work for this Application.
- * 
- * See samples/ApiDemos/tests/src/com.example.android.apis/ApiDemosApplicationTests for an example
- * of how to perform unit tests on an Application object.
- */
-public class ApiDemosApplication extends Application {
-
-    public void onCreate() {
-        /*
-         * This populates the default values from the preferences XML file. See
-         * {@link DefaultValues} for more details.
-         */
-        PreferenceManager.setDefaultValues(this, R.xml.default_values, false);
-    }
-
-    public void onTerminate() {
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/_package.html b/samples/ApiDemos/src/com/example/android/apis/_package.html
deleted file mode 100644
index 307c136..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/_package.html
+++ /dev/null
@@ -1,26 +0,0 @@
-<html>
-<head>
-<link rel="stylesheet" type="text/css" href="assets/style.css" />
-<script type="text/javascript" src="http://www.corp.google.com/style/prettify.js"></script>
-<script src="http://www.corp.google.com/eng/techpubs/include/navbar.js" type="text/javascript"></script>
-
-
-
-</head>
-
-<body>
-
-<p>
-Examples of how to use the android platform APIs.  See:
-
-<ol>
-	<li> <a href="com.android.sdk.app">sdk.app</a> for examples
-		of using the android.app APIs.
-	<li> <a href="com.android.sdk.view">sdk.view</a> for examples
-		of using the android.view APIs.
-</ol>
-</p>
-
-
-</body>
-</html>
diff --git a/samples/ApiDemos/src/com/example/android/apis/animation/Rotate3dAnimation.java b/samples/ApiDemos/src/com/example/android/apis/animation/Rotate3dAnimation.java
deleted file mode 100644
index 61ee828..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/animation/Rotate3dAnimation.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.animation;
-
-import android.view.animation.Animation;
-import android.view.animation.Transformation;
-import android.graphics.Camera;
-import android.graphics.Matrix;
-
-/**
- * An animation that rotates the view on the Y axis between two specified angles.
- * This animation also adds a translation on the Z axis (depth) to improve the effect.
- */
-public class Rotate3dAnimation extends Animation {
-    private final float mFromDegrees;
-    private final float mToDegrees;
-    private final float mCenterX;
-    private final float mCenterY;
-    private final float mDepthZ;
-    private final boolean mReverse;
-    private Camera mCamera;
-
-    /**
-     * Creates a new 3D rotation on the Y axis. The rotation is defined by its
-     * start angle and its end angle. Both angles are in degrees. The rotation
-     * is performed around a center point on the 2D space, definied by a pair
-     * of X and Y coordinates, called centerX and centerY. When the animation
-     * starts, a translation on the Z axis (depth) is performed. The length
-     * of the translation can be specified, as well as whether the translation
-     * should be reversed in time.
-     *
-     * @param fromDegrees the start angle of the 3D rotation
-     * @param toDegrees the end angle of the 3D rotation
-     * @param centerX the X center of the 3D rotation
-     * @param centerY the Y center of the 3D rotation
-     * @param reverse true if the translation should be reversed, false otherwise
-     */
-    public Rotate3dAnimation(float fromDegrees, float toDegrees,
-            float centerX, float centerY, float depthZ, boolean reverse) {
-        mFromDegrees = fromDegrees;
-        mToDegrees = toDegrees;
-        mCenterX = centerX;
-        mCenterY = centerY;
-        mDepthZ = depthZ;
-        mReverse = reverse;
-    }
-
-    @Override
-    public void initialize(int width, int height, int parentWidth, int parentHeight) {
-        super.initialize(width, height, parentWidth, parentHeight);
-        mCamera = new Camera();
-    }
-
-    @Override
-    protected void applyTransformation(float interpolatedTime, Transformation t) {
-        final float fromDegrees = mFromDegrees;
-        float degrees = fromDegrees + ((mToDegrees - fromDegrees) * interpolatedTime);
-
-        final float centerX = mCenterX;
-        final float centerY = mCenterY;
-        final Camera camera = mCamera;
-
-        final Matrix matrix = t.getMatrix();
-
-        camera.save();
-        if (mReverse) {
-            camera.translate(0.0f, 0.0f, mDepthZ * interpolatedTime);
-        } else {
-            camera.translate(0.0f, 0.0f, mDepthZ * (1.0f - interpolatedTime));
-        }
-        camera.rotateY(degrees);
-        camera.getMatrix(matrix);
-        camera.restore();
-
-        matrix.preTranslate(-centerX, -centerY);
-        matrix.postTranslate(centerX, centerY);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/animation/Transition3d.java b/samples/ApiDemos/src/com/example/android/apis/animation/Transition3d.java
deleted file mode 100644
index 38e69d0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/animation/Transition3d.java
+++ /dev/null
@@ -1,175 +0,0 @@
-package com.example.android.apis.animation;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.ListView;
-import android.widget.ArrayAdapter;
-import android.widget.AdapterView;
-import android.widget.ImageView;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.animation.Animation;
-import android.view.animation.AccelerateInterpolator;
-import android.view.animation.DecelerateInterpolator;
-
-/**
- * This sample application shows how to use layout animation and various
- * transformations on views. The result is a 3D transition between a
- * ListView and an ImageView. When the user clicks the list, it flips to
- * show the picture. When the user clicks the picture, it flips to show the
- * list. The animation is made of two smaller animations: the first half
- * rotates the list by 90 degrees on the Y axis and the second half rotates
- * the picture by 90 degrees on the Y axis. When the first half finishes, the
- * list is made invisible and the picture is set visible.
- */
-public class Transition3d extends Activity implements
-        AdapterView.OnItemClickListener, View.OnClickListener {
-    private ListView mPhotosList;
-    private ViewGroup mContainer;
-    private ImageView mImageView;
-
-    // Names of the photos we show in the list
-    private static final String[] PHOTOS_NAMES = new String[] {
-            "Lyon",
-            "Livermore",
-            "Tahoe Pier",
-            "Lake Tahoe",
-            "Grand Canyon",
-            "Bodie"
-    };
-
-    // Resource identifiers for the photos we want to display
-    private static final int[] PHOTOS_RESOURCES = new int[] {
-            R.drawable.photo1,
-            R.drawable.photo2,
-            R.drawable.photo3,
-            R.drawable.photo4,
-            R.drawable.photo5,
-            R.drawable.photo6
-    };
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.animations_main_screen);
-
-        mPhotosList = (ListView) findViewById(android.R.id.list);
-        mImageView = (ImageView) findViewById(R.id.picture);
-        mContainer = (ViewGroup) findViewById(R.id.container);
-
-        // Prepare the ListView
-        final ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, PHOTOS_NAMES);
-
-        mPhotosList.setAdapter(adapter);
-        mPhotosList.setOnItemClickListener(this);
-
-        // Prepare the ImageView
-        mImageView.setClickable(true);
-        mImageView.setFocusable(true);
-        mImageView.setOnClickListener(this);
-
-        // Since we are caching large views, we want to keep their cache
-        // between each animation
-        mContainer.setPersistentDrawingCache(ViewGroup.PERSISTENT_ANIMATION_CACHE);
-    }
-
-    /**
-     * Setup a new 3D rotation on the container view.
-     *
-     * @param position the item that was clicked to show a picture, or -1 to show the list
-     * @param start the start angle at which the rotation must begin
-     * @param end the end angle of the rotation
-     */
-    private void applyRotation(int position, float start, float end) {
-        // Find the center of the container
-        final float centerX = mContainer.getWidth() / 2.0f;
-        final float centerY = mContainer.getHeight() / 2.0f;
-
-        // Create a new 3D rotation with the supplied parameter
-        // The animation listener is used to trigger the next animation
-        final Rotate3dAnimation rotation =
-                new Rotate3dAnimation(start, end, centerX, centerY, 310.0f, true);
-        rotation.setDuration(500);
-        rotation.setFillAfter(true);
-        rotation.setInterpolator(new AccelerateInterpolator());
-        rotation.setAnimationListener(new DisplayNextView(position));
-
-        mContainer.startAnimation(rotation);
-    }
-
-    public void onItemClick(AdapterView parent, View v, int position, long id) {
-        // Pre-load the image then start the animation
-        mImageView.setImageResource(PHOTOS_RESOURCES[position]);
-        applyRotation(position, 0, 90);
-    }
-
-    public void onClick(View v) {
-        applyRotation(-1, 180, 90);
-    }
-
-    /**
-     * This class listens for the end of the first half of the animation.
-     * It then posts a new action that effectively swaps the views when the container
-     * is rotated 90 degrees and thus invisible.
-     */
-    private final class DisplayNextView implements Animation.AnimationListener {
-        private final int mPosition;
-
-        private DisplayNextView(int position) {
-            mPosition = position;
-        }
-
-        public void onAnimationStart(Animation animation) {
-        }
-
-        public void onAnimationEnd(Animation animation) {
-            mContainer.post(new SwapViews(mPosition));
-        }
-
-        public void onAnimationRepeat(Animation animation) {
-        }
-    }
-
-    /**
-     * This class is responsible for swapping the views and start the second
-     * half of the animation.
-     */
-    private final class SwapViews implements Runnable {
-        private final int mPosition;
-
-        public SwapViews(int position) {
-            mPosition = position;
-        }
-
-        public void run() {
-            final float centerX = mContainer.getWidth() / 2.0f;
-            final float centerY = mContainer.getHeight() / 2.0f;
-            Rotate3dAnimation rotation;
-            
-            if (mPosition > -1) {
-                mPhotosList.setVisibility(View.GONE);
-                mImageView.setVisibility(View.VISIBLE);
-                mImageView.requestFocus();
-
-                rotation = new Rotate3dAnimation(90, 180, centerX, centerY, 310.0f, false);
-            } else {
-                mImageView.setVisibility(View.GONE);
-                mPhotosList.setVisibility(View.VISIBLE);
-                mPhotosList.requestFocus();
-
-                rotation = new Rotate3dAnimation(90, 0, centerX, centerY, 310.0f, false);
-            }
-
-            rotation.setDuration(500);
-            rotation.setFillAfter(true);
-            rotation.setInterpolator(new DecelerateInterpolator());
-
-            mContainer.startAnimation(rotation);
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/animation/_index.html b/samples/ApiDemos/src/com/example/android/apis/animation/_index.html
deleted file mode 100644
index cd2ea53..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/animation/_index.html
+++ /dev/null
@@ -1,48 +0,0 @@
-
-<h3>Drawable</h3>
-<dl>
-  <dt><a href="ShapeDrawable1.html">ShapeDrawable</a></dt>
-  <dd>Demonstrates creating Drawables in XML.</dd>
-</dl>
-
-<h3>OpenGL|ES</h3>
-<dl>
-  <dt><a href="CameraPreview.html">CameraPreview</a></dt>
-  <dd> Demonstrates capturing the image stream from the camera, drawing to a surface (extending SurfaceView) on a separate thread (extending Thread).</dd>
-
-  <dt><a href="GLSurfaceViewActivity.html">GL SurfaceView</a></dt>
-  <dd>Demonstrates how to perform OpenGL rendering in to a SurfaceView.
-  <dl>
-  <dt>Code:
-  <dd> <a href="GLSurfaceViewActivity.html">GLSurfaceViewActivity.java</a>,
-    <a href="GLSurfaceView.html">GLSurfaceView.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/hello_world.html">
-  hello_world.xml</a>
-  </dl>
-  </dd>
-
-  <dt><a href="PolyToPoly.html">PolyToPoly</a></dt>
-  <dd>Demonstrates calling the <a href="@{docRoot}reference/android/graphics/Matrix.html#setPolyToPoly(float[],%20int,%20float[],%20int,%20int)">Matrix.setPolyToPoly()</a> method to translate coordinates on a canvas to a new perspective (used to simulate perspective). </dd>
-
-  <dt><a href="DrawPoints.html">DrawPoints</a></dt>
-  <dd>Demonstrates using the <a href="android.graphics.Paint">Paint</a> and <a href="android.graphics.Canvas">Canvas</a> objects to draw random points on the screen, with different colors and strokes. </dd>
-
-  <dt><a href="PathEffects.html">PathEffects</a></dt>
-  <dd> Demonstrates the use of <a href="android.graphics.Path">Path</a> and various <a href="android.graphics.PathEffect">PathEffect</a> subclasses. </dd>
-
-  <dt><a href="SurfaceViewOverlay.html">SurfaceView Overlay</a></dt>
-  <dd>Shows how you can place overlays on top of a SurfaceView.
-  <dl>
-  <dt>Code:
-  <dd> <a href="SurfaceViewOverlay.html">SurfaceViewOverlay.java</a>,
-    <a href="GLSurfaceView.html">GLSurfaceView.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/surface_view_overlay.html">
-  surface_view_overlay.xml</a>
-  </dl>
-  </dd>
-
-  <dt><a href="TouchPaint.html">TouchPaint</a></dt>
-  <dd> Demonstrates the handling of touch screen events to implement a simple painting app. </dd>
-</dl>
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/AdvancedPreferences.java b/samples/ApiDemos/src/com/example/android/apis/app/AdvancedPreferences.java
deleted file mode 100644
index 2dbbc45..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/AdvancedPreferences.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.content.SharedPreferences;
-import android.content.SharedPreferences.OnSharedPreferenceChangeListener;
-import android.os.Bundle;
-import android.os.Handler;
-import android.preference.PreferenceActivity;
-import android.preference.CheckBoxPreference;
-import android.widget.Toast;
-
-/**
- * Example that shows finding a preference from the hierarchy and a custom preference type.
- */
-public class AdvancedPreferences extends PreferenceActivity implements OnSharedPreferenceChangeListener {
-    public static final String KEY_MY_PREFERENCE = "my_preference";
-    public static final String KEY_ADVANCED_CHECKBOX_PREFERENCE = "advanced_checkbox_preference";
-
-    private CheckBoxPreference mCheckBoxPreference;
-    private Handler mHandler = new Handler();
-    
-    /**
-     * This is a simple example of controlling a preference from code.
-     */
-    private Runnable mForceCheckBoxRunnable = new Runnable() {
-        public void run() {
-            if (mCheckBoxPreference != null) {
-                mCheckBoxPreference.setChecked(!mCheckBoxPreference.isChecked());
-            }
-            
-            // Force toggle again in a second
-            mHandler.postDelayed(this, 1000);
-        }
-    };
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Load the XML preferences file
-        addPreferencesFromResource(R.xml.advanced_preferences);
-        
-        // Get a reference to the checkbox preference
-        mCheckBoxPreference = (CheckBoxPreference)getPreferenceScreen().findPreference(
-                KEY_ADVANCED_CHECKBOX_PREFERENCE);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-
-        // Start the force toggle
-        mForceCheckBoxRunnable.run();
-        
-        // Set up a listener whenever a key changes
-        getPreferenceScreen().getSharedPreferences().registerOnSharedPreferenceChangeListener(this);
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-
-        // Unregister the listener whenever a key changes
-        getPreferenceScreen().getSharedPreferences().unregisterOnSharedPreferenceChangeListener(this);
-        
-        mHandler.removeCallbacks(mForceCheckBoxRunnable);
-    }
-
-    public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
-        // Let's do something when my counter preference value changes
-        if (key.equals(KEY_MY_PREFERENCE)) {
-            Toast.makeText(this, "Thanks! You increased my count to "
-                    + sharedPreferences.getInt(key, 0), Toast.LENGTH_SHORT).show();
-        }
-    }
-    
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/AlarmController.java b/samples/ApiDemos/src/com/example/android/apis/app/AlarmController.java
deleted file mode 100644
index 2ba5735..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/AlarmController.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.AlarmManager;
-import android.app.PendingIntent;
-import android.content.Intent;
-import android.os.SystemClock;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.Toast;
-
-import java.util.Calendar;
-
-/**
- * Example of scheduling one-shot and repeating alarms.  See
- * {@link OneShotAlarm} for the code run when the one-shot alarm goes off, and
- * {@link RepeatingAlarm} for the code run when the repeating alarm goes off.
- * <h4>Demo</h4>
-App/Service/Alarm Controller
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/AlarmController.java</td>
-            <td class="DescrColumn">The activity that lets you schedule alarms</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/OneShotAlarm.java</td>
-            <td class="DescrColumn">This is an intent receiver that executes when the
-                one-shot alarm goes off</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/RepeatingAlarm.java</td>
-            <td class="DescrColumn">This is an intent receiver that executes when the
-                repeating alarm goes off</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">/res/any/layout/alarm_controller.xml</td>
-            <td class="DescrColumn">Defines contents of the screen</td>
-        </tr>
-</table>
-
- */
-public class AlarmController extends Activity {
-    Toast mToast;
-
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.alarm_controller);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.one_shot);
-        button.setOnClickListener(mOneShotListener);
-        button = (Button)findViewById(R.id.start_repeating);
-        button.setOnClickListener(mStartRepeatingListener);
-        button = (Button)findViewById(R.id.stop_repeating);
-        button.setOnClickListener(mStopRepeatingListener);
-    }
-
-    private OnClickListener mOneShotListener = new OnClickListener() {
-        public void onClick(View v) {
-            // When the alarm goes off, we want to broadcast an Intent to our
-            // BroadcastReceiver.  Here we make an Intent with an explicit class
-            // name to have our own receiver (which has been published in
-            // AndroidManifest.xml) instantiated and called, and then create an
-            // IntentSender to have the intent executed as a broadcast.
-            Intent intent = new Intent(AlarmController.this, OneShotAlarm.class);
-            PendingIntent sender = PendingIntent.getBroadcast(AlarmController.this,
-                    0, intent, 0);
-
-            // We want the alarm to go off 30 seconds from now.
-            Calendar calendar = Calendar.getInstance();
-            calendar.setTimeInMillis(System.currentTimeMillis());
-            calendar.add(Calendar.SECOND, 30);
-
-            // Schedule the alarm!
-            AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
-            am.set(AlarmManager.RTC_WAKEUP, calendar.getTimeInMillis(), sender);
-
-            // Tell the user about what we did.
-            if (mToast != null) {
-                mToast.cancel();
-            }
-            mToast = Toast.makeText(AlarmController.this, R.string.one_shot_scheduled,
-                    Toast.LENGTH_LONG);
-            mToast.show();
-        }
-    };
-
-    private OnClickListener mStartRepeatingListener = new OnClickListener() {
-        public void onClick(View v) {
-            // When the alarm goes off, we want to broadcast an Intent to our
-            // BroadcastReceiver.  Here we make an Intent with an explicit class
-            // name to have our own receiver (which has been published in
-            // AndroidManifest.xml) instantiated and called, and then create an
-            // IntentSender to have the intent executed as a broadcast.
-            // Note that unlike above, this IntentSender is configured to
-            // allow itself to be sent multiple times.
-            Intent intent = new Intent(AlarmController.this, RepeatingAlarm.class);
-            PendingIntent sender = PendingIntent.getBroadcast(AlarmController.this,
-                    0, intent, 0);
-            
-            // We want the alarm to go off 30 seconds from now.
-            long firstTime = SystemClock.elapsedRealtime();
-            firstTime += 15*1000;
-
-            // Schedule the alarm!
-            AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
-            am.setRepeating(AlarmManager.ELAPSED_REALTIME_WAKEUP,
-                            firstTime, 15*1000, sender);
-
-            // Tell the user about what we did.
-            if (mToast != null) {
-                mToast.cancel();
-            }
-            mToast = Toast.makeText(AlarmController.this, R.string.repeating_scheduled,
-                    Toast.LENGTH_LONG);
-            mToast.show();
-        }
-    };
-
-    private OnClickListener mStopRepeatingListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Create the same intent, and thus a matching IntentSender, for
-            // the one that was scheduled.
-            Intent intent = new Intent(AlarmController.this, RepeatingAlarm.class);
-            PendingIntent sender = PendingIntent.getBroadcast(AlarmController.this,
-                    0, intent, 0);
-            
-            // And cancel the alarm.
-            AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
-            am.cancel(sender);
-
-            // Tell the user about what we did.
-            if (mToast != null) {
-                mToast.cancel();
-            }
-            mToast = Toast.makeText(AlarmController.this, R.string.repeating_unscheduled,
-                    Toast.LENGTH_LONG);
-            mToast.show();
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/AlarmService.java b/samples/ApiDemos/src/com/example/android/apis/app/AlarmService.java
deleted file mode 100644
index 151838a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/AlarmService.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.AlarmManager;
-import android.app.PendingIntent;
-import android.content.Intent;
-import android.os.SystemClock;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.Toast;
-
-
-/**
- * This demonstrates how you can schedule an alarm that causes a service to
- * be started.  This is useful when you want to schedule alarms that initiate
- * long-running operations, such as retrieving recent e-mails.
- */
-public class AlarmService extends Activity {
-    private PendingIntent mAlarmSender;
-    
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Create an IntentSender that will launch our service, to be scheduled
-        // with the alarm manager.
-        mAlarmSender = PendingIntent.getService(AlarmService.this,
-                0, new Intent(AlarmService.this, AlarmService_Service.class), 0);
-        
-        setContentView(R.layout.alarm_service);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.start_alarm);
-        button.setOnClickListener(mStartAlarmListener);
-        button = (Button)findViewById(R.id.stop_alarm);
-        button.setOnClickListener(mStopAlarmListener);
-    }
-
-    private OnClickListener mStartAlarmListener = new OnClickListener() {
-        public void onClick(View v) {
-            // We want the alarm to go off 30 seconds from now.
-            long firstTime = SystemClock.elapsedRealtime();
-
-            // Schedule the alarm!
-            AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
-            am.setRepeating(AlarmManager.ELAPSED_REALTIME_WAKEUP,
-                            firstTime, 30*1000, mAlarmSender);
-
-            // Tell the user about what we did.
-            Toast.makeText(AlarmService.this, R.string.repeating_scheduled,
-                    Toast.LENGTH_LONG).show();
-        }
-    };
-
-    private OnClickListener mStopAlarmListener = new OnClickListener() {
-        public void onClick(View v) {
-            // And cancel the alarm.
-            AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE);
-            am.cancel(mAlarmSender);
-
-            // Tell the user about what we did.
-            Toast.makeText(AlarmService.this, R.string.repeating_unscheduled,
-                    Toast.LENGTH_LONG).show();
-
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/AlarmService_Service.java b/samples/ApiDemos/src/com/example/android/apis/app/AlarmService_Service.java
deleted file mode 100644
index 6762ba9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/AlarmService_Service.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.Binder;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.os.RemoteException;
-import android.widget.Toast;
-
-/**
- * This is an example of implementing an application service that will run in
- * response to an alarm, allowing us to move long duration work out of an
- * intent receiver.
- * 
- * @see AlarmService
- * @see AlarmService_Alarm
- */
-public class AlarmService_Service extends Service {
-    NotificationManager mNM;
-
-    @Override
-    public void onCreate() {
-        mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
-
-        // show the icon in the status bar
-        showNotification();
-
-        // Start up the thread running the service.  Note that we create a
-        // separate thread because the service normally runs in the process's
-        // main thread, which we don't want to block.
-        Thread thr = new Thread(null, mTask, "AlarmService_Service");
-        thr.start();
-    }
-
-    @Override
-    public void onDestroy() {
-        // Cancel the notification -- we use the same ID that we had used to start it
-        mNM.cancel(R.string.alarm_service_started);
-
-        // Tell the user we stopped.
-        Toast.makeText(this, R.string.alarm_service_finished, Toast.LENGTH_SHORT).show();
-    }
-
-    /**
-     * The function that runs in our worker thread
-     */
-    Runnable mTask = new Runnable() {
-        public void run() {
-            // Normally we would do some work here...  for our sample, we will
-            // just sleep for 30 seconds.
-            long endTime = System.currentTimeMillis() + 15*1000;
-            while (System.currentTimeMillis() < endTime) {
-                synchronized (mBinder) {
-                    try {
-                        mBinder.wait(endTime - System.currentTimeMillis());
-                    } catch (Exception e) {
-                    }
-                }
-            }
-
-            // Done with our work...  stop the service!
-            AlarmService_Service.this.stopSelf();
-        }
-    };
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        return mBinder;
-    }
-
-    /**
-     * Show a notification while this service is running.
-     */
-    private void showNotification() {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(R.string.alarm_service_started);
-
-        // Set the icon, scrolling text and timestamp
-        Notification notification = new Notification(R.drawable.stat_sample, text,
-                System.currentTimeMillis());
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, AlarmService.class), 0);
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.alarm_service_label),
-                       text, contentIntent);
-
-        // Send the notification.
-        // We use a layout id because it is a unique number.  We use it later to cancel.
-        mNM.notify(R.string.alarm_service_started, notification);
-    }
-
-    /**
-     * This is the object that receives interactions from clients.  See RemoteService
-     * for a more complete example.
-     */
-    private final IBinder mBinder = new Binder() {
-        @Override
-		protected boolean onTransact(int code, Parcel data, Parcel reply,
-		        int flags) throws RemoteException {
-            return super.onTransact(code, data, reply, flags);
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/AlertDialogSamples.java b/samples/ApiDemos/src/com/example/android/apis/app/AlertDialogSamples.java
deleted file mode 100644
index fabdfc1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/AlertDialogSamples.java
+++ /dev/null
@@ -1,306 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.app.AlertDialog;
-import android.app.Dialog;
-import android.app.ProgressDialog;
-import android.content.DialogInterface;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-import com.example.android.apis.R;
-
-/**
- * Example of how to use an {@link android.app.AlertDialog}.
- * <h3>AlertDialogSamples</h3>
-
-<p>This demonstrates the different ways the AlertDialog can be used.</p>
-
-<h4>Demo</h4>
-App/Dialog/Alert Dialog
- 
-<h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td >src/com.example.android.apis/app/AlertDialogSamples.java</td>
- *             <td >The Alert Dialog Samples implementation</td>
- *         </tr>
- *         <tr>
- *             <td >/res/any/layout/alert_dialog.xml</td>
- *             <td >Defines contents of the screen</td>
- *         </tr>
- * </table> 
- */
-public class AlertDialogSamples extends Activity {
-    private static final int DIALOG_YES_NO_MESSAGE = 1;
-    private static final int DIALOG_YES_NO_LONG_MESSAGE = 2;
-    private static final int DIALOG_LIST = 3;
-    private static final int DIALOG_PROGRESS = 4;
-    private static final int DIALOG_SINGLE_CHOICE = 5;
-    private static final int DIALOG_MULTIPLE_CHOICE = 6;
-    private static final int DIALOG_TEXT_ENTRY = 7;
-
-    private static final int MAX_PROGRESS = 100;
-    
-    private ProgressDialog mProgressDialog;
-    private int mProgress;
-    private Handler mProgressHandler;
-
-    @Override
-    protected Dialog onCreateDialog(int id) {
-        switch (id) {
-        case DIALOG_YES_NO_MESSAGE:
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setIcon(R.drawable.alert_dialog_icon)
-                .setTitle(R.string.alert_dialog_two_buttons_title)
-                .setPositiveButton(R.string.alert_dialog_ok, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked OK so do some stuff */
-                    }
-                })
-                .setNegativeButton(R.string.alert_dialog_cancel, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked Cancel so do some stuff */
-                    }
-                })
-                .create();
-        case DIALOG_YES_NO_LONG_MESSAGE:
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setIcon(R.drawable.alert_dialog_icon)
-                .setTitle(R.string.alert_dialog_two_buttons_msg)
-                .setMessage(R.string.alert_dialog_two_buttons2_msg)
-                .setPositiveButton(R.string.alert_dialog_ok, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-    
-                        /* User clicked OK so do some stuff */
-                    }
-                })
-                .setNeutralButton(R.string.alert_dialog_something, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked Something so do some stuff */
-                    }
-                })
-                .setNegativeButton(R.string.alert_dialog_cancel, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked Cancel so do some stuff */
-                    }
-                })
-                .create();
-        case DIALOG_LIST:
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setTitle(R.string.select_dialog)
-                .setItems(R.array.select_dialog_items, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int which) {
-
-                        /* User clicked so do some stuff */
-                        String[] items = getResources().getStringArray(R.array.select_dialog_items);
-                        new AlertDialog.Builder(AlertDialogSamples.this)
-                                .setMessage("You selected: " + which + " , " + items[which])
-                                .show();
-                    }
-                })
-                .create();
-        case DIALOG_PROGRESS:
-            mProgressDialog = new ProgressDialog(AlertDialogSamples.this);
-            mProgressDialog.setIcon(R.drawable.alert_dialog_icon);
-            mProgressDialog.setTitle(R.string.select_dialog);
-            mProgressDialog.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
-            mProgressDialog.setMax(MAX_PROGRESS);
-            mProgressDialog.setButton(getText(R.string.alert_dialog_hide), new DialogInterface.OnClickListener() {
-                public void onClick(DialogInterface dialog, int whichButton) {
-
-                    /* User clicked Yes so do some stuff */
-                }
-            });
-            mProgressDialog.setButton2(getText(R.string.alert_dialog_cancel), new DialogInterface.OnClickListener() {
-                public void onClick(DialogInterface dialog, int whichButton) {
-
-                    /* User clicked No so do some stuff */
-                }
-            });
-            return mProgressDialog;
-        case DIALOG_SINGLE_CHOICE:
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setIcon(R.drawable.alert_dialog_icon)
-                .setTitle(R.string.alert_dialog_single_choice)
-                .setSingleChoiceItems(R.array.select_dialog_items2, 0, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked on a radio button do some stuff */
-                    }
-                })
-                .setPositiveButton(R.string.alert_dialog_ok, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked Yes so do some stuff */
-                    }
-                })
-                .setNegativeButton(R.string.alert_dialog_cancel, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked No so do some stuff */
-                    }
-                })
-               .create();
-        case DIALOG_MULTIPLE_CHOICE:
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setIcon(R.drawable.ic_popup_reminder)
-                .setTitle(R.string.alert_dialog_multi_choice)
-                .setMultiChoiceItems(R.array.select_dialog_items3,
-                        new boolean[]{false, true, false, true, false, false, false},
-                        new DialogInterface.OnMultiChoiceClickListener() {
-                            public void onClick(DialogInterface dialog, int whichButton,
-                                    boolean isChecked) {
-
-                                /* User clicked on a check box do some stuff */
-                            }
-                        })
-                .setPositiveButton(R.string.alert_dialog_ok, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked Yes so do some stuff */
-                    }
-                })
-                .setNegativeButton(R.string.alert_dialog_cancel, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked No so do some stuff */
-                    }
-                })
-               .create();
-        case DIALOG_TEXT_ENTRY:
-            // This example shows how to add a custom layout to an AlertDialog
-            LayoutInflater factory = LayoutInflater.from(this);
-            final View textEntryView = factory.inflate(R.layout.alert_dialog_text_entry, null);
-            return new AlertDialog.Builder(AlertDialogSamples.this)
-                .setIcon(R.drawable.alert_dialog_icon)
-                .setTitle(R.string.alert_dialog_text_entry)
-                .setView(textEntryView)
-                .setPositiveButton(R.string.alert_dialog_ok, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-    
-                        /* User clicked OK so do some stuff */
-                    }
-                })
-                .setNegativeButton(R.string.alert_dialog_cancel, new DialogInterface.OnClickListener() {
-                    public void onClick(DialogInterface dialog, int whichButton) {
-
-                        /* User clicked cancel so do some stuff */
-                    }
-                })
-                .create();
-        }
-        return null;
-    }
-
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView(int)} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.alert_dialog);
-                
-        /* Display a text message with yes/no buttons and handle each message as well as the cancel action */
-        Button twoButtonsTitle = (Button) findViewById(R.id.two_buttons);
-        twoButtonsTitle.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_YES_NO_MESSAGE);
-            }
-        });
-        
-        /* Display a long text message with yes/no buttons and handle each message as well as the cancel action */
-        Button twoButtons2Title = (Button) findViewById(R.id.two_buttons2);
-        twoButtons2Title.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_YES_NO_LONG_MESSAGE);
-            }
-        });
-        
-        
-        /* Display a list of items */
-        Button selectButton = (Button) findViewById(R.id.select_button);
-        selectButton.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_LIST);
-            }
-        });
-        
-        /* Display a custom progress bar */
-        Button progressButton = (Button) findViewById(R.id.progress_button);
-        progressButton.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_PROGRESS);
-                mProgress = 0;
-                mProgressDialog.setProgress(0);
-                mProgressHandler.sendEmptyMessage(0);
-            }
-        });
-        
-        /* Display a radio button group */
-        Button radioButton = (Button) findViewById(R.id.radio_button);
-        radioButton.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_SINGLE_CHOICE);
-            }
-        });
-        
-        /* Display a list of checkboxes */
-        Button checkBox = (Button) findViewById(R.id.checkbox_button);
-        checkBox.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_MULTIPLE_CHOICE);
-            }
-        });
-        
-        /* Display a text entry dialog */
-        Button textEntry = (Button) findViewById(R.id.text_entry_button);
-        textEntry.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG_TEXT_ENTRY);
-            }
-        });
-        
-        mProgressHandler = new Handler() {
-            @Override
-            public void handleMessage(Message msg) {
-                super.handleMessage(msg);
-                if (mProgress >= MAX_PROGRESS) {
-                    mProgressDialog.dismiss();
-                } else {
-                    mProgress++;
-                    mProgressDialog.incrementProgressBy(1);
-                    mProgressHandler.sendEmptyMessageDelayed(0, 100);
-                }
-            }
-        };
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilter.java b/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilter.java
deleted file mode 100644
index bb843e5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilter.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.os.RemoteException;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-import com.example.android.apis.R;
-
-
-/**
- * Front-end for launching {@link ContactsFilterInstrumentation} example
- * instrumentation class.
- */
-public class ContactsFilter extends Activity {
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.contacts_filter);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.go);
-        button.setOnClickListener(mGoListener);
-    }
-
-    private OnClickListener mGoListener = new OnClickListener() {
-        public void onClick(View v) {
-            startInstrumentation(new ComponentName(ContactsFilter.this,
-                            ContactsFilterInstrumentation.class), null, null);
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilterInstrumentation.java b/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilterInstrumentation.java
deleted file mode 100644
index 04bb671..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ContactsFilterInstrumentation.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.app.Instrumentation;
-import android.content.Intent;
-import android.view.KeyEvent;
-import android.os.Bundle;
-import android.util.Log;
-
-import java.util.Map;
-
-/**
- * This is an example implementation of the {@link android.app.Instrumentation}
- * class, allowing you to run tests against application code.  The
- * instrumentation implementation here is loaded into the application's
- * process, for controlling and monitoring what it does.
- */
-public class ContactsFilterInstrumentation extends Instrumentation {
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        // When this instrumentation is created, we simply want to start
-        // its test code off in a separate thread, which will call back
-        // to us in onStart().
-        start();
-    }
-
-    @Override
-    public void onStart() {
-        super.onStart();
-        // First start the activity we are instrumenting -- the contacts
-        // list.
-        Intent intent = new Intent(Intent.ACTION_MAIN);
-        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-        intent.setClassName(getTargetContext(),
-                "com.android.phone.Dialer");
-        Activity activity = startActivitySync(intent);
-
-        // This is the Activity object that was started, to do with as we want.
-        Log.i("ContactsFilterInstrumentation", "Started: " + activity);
-
-        // We are going to enqueue a couple key events to simulate the user
-        // filtering the list.  This is the low-level API so we must send both
-        // down and up events.
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_M));
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_M));
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_A));
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_A));
-
-        // Wait for the activity to finish all of its processing.
-        waitForIdleSync();
-
-        // And we are done!
-        Log.i("ContactsFilterInstrumentation", "Done!");
-        finish(Activity.RESULT_OK, null);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ContactsSelectInstrumentation.java b/samples/ApiDemos/src/com/example/android/apis/app/ContactsSelectInstrumentation.java
deleted file mode 100644
index dcb8b83..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ContactsSelectInstrumentation.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.app.Instrumentation;
-import android.content.Intent;
-import android.content.IntentFilter;
-import android.os.IBinder;
-import android.view.KeyEvent;
-import android.provider.Contacts;
-import android.os.Bundle;
-import android.util.Log;
-
-import java.util.Map;
-
-/**
- * This is an example implementation of the {@link android.app.Instrumentation}
- * class, allowing you to run tests against application code.  The
- * instrumentation implementation here is loaded into the application's
- * process, for controlling and monitoring what it does.
- */
-public class ContactsSelectInstrumentation extends Instrumentation {
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        // When this instrumentation is created, we simply want to start
-        // its test code off in a separate thread, which will call back
-        // to us in onStart().
-        start();
-    }
-
-    @Override
-    public void onStart() {
-        super.onStart();
-        // First start the activity we are instrumenting -- the contacts
-        // list.
-        Intent intent = new Intent(Intent.ACTION_MAIN);
-        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-        intent.setClassName(getTargetContext(),
-                "com.android.phone.Dialer");
-        Activity activity = startActivitySync(intent);
-
-        // This is the Activity object that was started, to do with as we want.
-        Log.i("ContactsSelectInstrumentation", "Started: " + activity);
-
-        // Monitor for the expected start activity call.
-        ActivityMonitor am = addMonitor(IntentFilter.create(
-            Intent.ACTION_VIEW, Contacts.People.CONTENT_ITEM_TYPE), null, true);
-
-        // We are going to enqueue a couple key events to simulate the user
-        // selecting an item in the list.
-        sendKeySync(new KeyEvent(
-            KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_DOWN));
-        sendKeySync(new KeyEvent(
-            KeyEvent.ACTION_UP, KeyEvent.KEYCODE_DPAD_DOWN));
-        sendKeySync(new KeyEvent(
-            KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_CENTER));
-        sendKeySync(new KeyEvent(
-            KeyEvent.ACTION_UP, KeyEvent.KEYCODE_DPAD_CENTER));
-
-        // Was the expected activity started?
-        if (checkMonitorHit(am, 1)) {
-            Log.i("ContactsSelectInstrumentation", "Activity started!");
-        } else {
-            Log.i("ContactsSelectInstrumentation", "*** ACTIVITY NOT STARTED!");
-        }
-
-        // And we are done!
-        Log.i("ContactsSelectInstrumentation", "Done!");
-        finish(Activity.RESULT_OK, null);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/CustomDialogActivity.java b/samples/ApiDemos/src/com/example/android/apis/app/CustomDialogActivity.java
deleted file mode 100644
index 62f0ae1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/CustomDialogActivity.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-/**
- * <h3>Dialog Activity</h3>
- * 
- * <p>This demonstrates the how to write an activity that looks like 
- * a pop-up dialog with a custom theme using a different text color.</p>
- */
-public class CustomDialogActivity extends Activity {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-        
-        // See assets/res/any/layout/dialog_activity.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.custom_dialog_activity);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/CustomTitle.java b/samples/ApiDemos/src/com/example/android/apis/app/CustomTitle.java
deleted file mode 100644
index e22a5cc..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/CustomTitle.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.view.Window;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.EditText;
-import android.widget.TextView;
-
-import com.example.android.apis.R;
-
-
-/**
- * Example of how to use a custom title {@link android.view.Window#FEATURE_CUSTOM_TITLE}.
- * <h3>CustomTitle</h3>
-
-<p>This demonstrates how a custom title can be used.</p>
-
-<h4>Demo</h4>
-App/Title/Custom Title
- 
-<h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td >src/com.example.android.apis/app/CustomTitle.java</td>
- *             <td >The Custom Title implementation</td>
- *         </tr>
- *         <tr>
- *             <td >/res/any/layout/custom_title.xml</td>
- *             <td >Defines contents of the screen</td>
- *         </tr>
- * </table> 
- */
-public class CustomTitle extends Activity {
-    
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView(int)} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
-        setContentView(R.layout.custom_title);
-        getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title_1);
-        
-        final TextView leftText = (TextView) findViewById(R.id.left_text);
-        final TextView rightText = (TextView) findViewById(R.id.right_text);
-        final EditText leftTextEdit = (EditText) findViewById(R.id.left_text_edit);
-        final EditText rightTextEdit = (EditText) findViewById(R.id.right_text_edit);
-        Button leftButton = (Button) findViewById(R.id.left_text_button);
-        Button rightButton = (Button) findViewById(R.id.right_text_button);
-        
-        leftButton.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                leftText.setText(leftTextEdit.getText());
-            }
-        });
-        rightButton.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                rightText.setText(rightTextEdit.getText());
-            }
-        });
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/DefaultValues.java b/samples/ApiDemos/src/com/example/android/apis/app/DefaultValues.java
deleted file mode 100644
index 35bdf13..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/DefaultValues.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.ApiDemosApplication;
-import com.example.android.apis.R;
-
-import android.app.Application;
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.preference.PreferenceActivity;
-import android.preference.PreferenceManager;
-
-/**
- * This activity is an example of a simple settings screen that has default
- * values.
- * <p>
- * In order for the default values to be populated into the
- * {@link SharedPreferences} (from the preferences XML file), the client must
- * call
- * {@link PreferenceManager#setDefaultValues(android.content.Context, int, boolean)}.
- * <p>
- * This should be called early, typically when the application is first created.
- * This ensures any of the application's activities, services, etc. will have
- * the default values present, even if the user has not wandered into the
- * application's settings. For ApiDemos, this is {@link ApiDemosApplication},
- * and you can find the call to
- * {@link PreferenceManager#setDefaultValues(android.content.Context, int, boolean)}
- * in its {@link ApiDemosApplication#onCreate() onCreate}.
- */
-public class DefaultValues extends PreferenceActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        addPreferencesFromResource(R.xml.default_values);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/DialogActivity.java b/samples/ApiDemos/src/com/example/android/apis/app/DialogActivity.java
deleted file mode 100644
index 7441b75..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/DialogActivity.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Window;
-
-import com.example.android.apis.R;
-
-/**
- * <h3>Dialog Activity</h3>
- * 
- * <p>This demonstrates the how to write an activity that looks like 
- * a pop-up dialog.</p>
- */
-public class DialogActivity extends Activity {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-        
-        requestWindowFeature(Window.FEATURE_LEFT_ICON);
-        
-        // See assets/res/any/layout/dialog_activity.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.dialog_activity);
-        
-        getWindow().setFeatureDrawableResource(Window.FEATURE_LEFT_ICON, 
-                android.R.drawable.ic_dialog_alert);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ForwardTarget.java b/samples/ApiDemos/src/com/example/android/apis/app/ForwardTarget.java
deleted file mode 100644
index ee699aa..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ForwardTarget.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Example of removing yourself from the history stack after forwarding to
- * another activity.
- */
-public class ForwardTarget extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.forward_target);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/Forwarding.java b/samples/ApiDemos/src/com/example/android/apis/app/Forwarding.java
deleted file mode 100644
index ef082bf..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/Forwarding.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * <p>Example of removing yourself from the history stack after forwarding to
- * another activity. This can be useful, for example, to implement
-    a confirmation dialog before the user goes on to another activity -- once the
-    user has confirmed this operation, they should not see the dialog again if they
-go back from it.</p>
-
-<p>Note that another way to implement a confirmation dialog would be as
-an activity that returns a result to its caller.  Either approach can be
-useful depending on how it makes sense to structure the application.</p>
-
-<h4>Demo</h4>
-App/Activity/Receive Result
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/Forwarding.java</td>
-            <td class="DescrColumn">Forwards the user to another activity when its button is pressed</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">/res/any/layout/forwarding.xml</td>
-            <td class="DescrColumn">Defines contents of the Forwarding screen</td>
-        </tr>
-</table>
- */
-public class Forwarding extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.forwarding);
-
-        // Watch for button clicks.
-        Button goButton = (Button)findViewById(R.id.go);
-        goButton.setOnClickListener(mGoListener);
-    }
-
-    private OnClickListener mGoListener = new OnClickListener()
-    {
-        public void onClick(View v)
-        {
-            // Here we start the next activity, and then call finish()
-            // so that our own will stop running and be removed from the
-            // history stack.
-            Intent intent = new Intent();
-            intent.setClass(Forwarding.this, ForwardTarget.class);
-            startActivity(intent);
-            finish();
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/HelloWorld.java b/samples/ApiDemos/src/com/example/android/apis/app/HelloWorld.java
deleted file mode 100644
index 1a7f698..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/HelloWorld.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Simple example of writing an application Activity.
- * Hello World</a></h3>
-
-<p>This demonstrates the basic code needed to write a Screen activity.</p>
-
-<h4>Demo</h4>
-App/Activity/Hello World
- 
-<h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td >src/com.example.android.apis/app/HelloWorld.java</td>
- *             <td >The Hello World Screen implementation</td>
- *         </tr>
- *         <tr>
- *             <td >/res/any/layout/hello_world.xml</td>
- *             <td >Defines contents of the screen</td>
- *         </tr>
- * </table> 
- */
-public class HelloWorld extends Activity
-{
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/hello_world.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.hello_world);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/IRemoteService.aidl b/samples/ApiDemos/src/com/example/android/apis/app/IRemoteService.aidl
deleted file mode 100644
index 046e3f6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/IRemoteService.aidl
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.app.IRemoteServiceCallback;
-
-/**
- * Example of defining an interface for calling on to a remote service
- * (running in another process).
- */
-interface IRemoteService {
-    /**
-     * Often you want to allow a service to call back to its clients.
-     * This shows how to do so, by registering a callback interface with
-     * the service.
-     */
-    void registerCallback(IRemoteServiceCallback cb);
-    
-    /**
-     * Remove a previously registered callback interface.
-     */
-    void unregisterCallback(IRemoteServiceCallback cb);
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/IRemoteServiceCallback.aidl b/samples/ApiDemos/src/com/example/android/apis/app/IRemoteServiceCallback.aidl
deleted file mode 100644
index 4fed807..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/IRemoteServiceCallback.aidl
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-/**
- * Example of a callback interface used by IRemoteService to send
- * synchronous notifications back to its clients.  Note that this is a
- * one-way interface so the server does not block waiting for the client.
- */
-oneway interface IRemoteServiceCallback {
-    /**
-     * Called when the service has a new value for you.
-     */
-    void valueChanged(int value);
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ISecondary.aidl b/samples/ApiDemos/src/com/example/android/apis/app/ISecondary.aidl
deleted file mode 100644
index 98e2823..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ISecondary.aidl
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-/**
- * Example of a secondary interface associated with a service.  (Note that
- * the interface itself doesn't impact, it is just a matter of how you
- * retrieve it from the service.)
- */
-interface ISecondary {
-    /**
-     * Request the PID of this service, to do evil things with it.
-     */
-    int getPid();
-    
-    /**
-     * This demonstrates the basic types that you can use as parameters
-     * and return values in AIDL.
-     */
-    void basicTypes(int anInt, long aLong, boolean aBoolean, float aFloat,
-            double aDouble, String aString);
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessage.java b/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessage.java
deleted file mode 100644
index d44c008..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessage.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.content.Context;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.widget.Button;
-import android.widget.TextView;
-import android.widget.Toast;
-
-public class IncomingMessage extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.incoming_message);
-
-        Button button = (Button) findViewById(R.id.notify);
-        button.setOnClickListener(new Button.OnClickListener() {
-                public void onClick(View v) {
-                    showToast();
-                    showNotification();
-                }
-            });
-    }
-
-    /**
-     * The toast pops up a quick message to the user showing what could be
-     * the text of an incoming message.  It uses a custom view to do so.
-     */
-    protected void showToast() {
-        // create the view
-        View view = inflateView(R.layout.incoming_message_panel);
-
-        // set the text in the view
-        TextView tv = (TextView)view.findViewById(R.id.message);
-        tv.setText("khtx. meet u for dinner. cul8r");
-
-        // show the toast
-        Toast toast = new Toast(this);
-        toast.setView(view);
-        toast.setDuration(Toast.LENGTH_LONG);
-        toast.show();
-    }
-
-    private View inflateView(int resource) {
-        LayoutInflater vi = (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        return vi.inflate(resource, null);
-    }
-
-    /**
-     * The notification is the icon and associated expanded entry in the
-     * status bar.
-     */
-    protected void showNotification() {
-        // look up the notification manager service
-        NotificationManager nm = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
-
-        // The details of our fake message
-        CharSequence from = "Joe";
-        CharSequence message = "kthx. meet u for dinner. cul8r";
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, IncomingMessageView.class), 0);
-
-        // The ticker text, this uses a formatted string so our message could be localized
-        String tickerText = getString(R.string.imcoming_message_ticker_text, message);
-
-        // construct the Notification object.
-        Notification notif = new Notification(R.drawable.stat_sample, tickerText,
-                System.currentTimeMillis());
-
-        // Set the info for the views that show in the notification panel.
-        notif.setLatestEventInfo(this, from, message, contentIntent);
-
-        // after a 100ms delay, vibrate for 250ms, pause for 100 ms and
-        // then vibrate for 500ms.
-        notif.vibrate = new long[] { 100, 250, 100, 500};
-
-        // Note that we use R.layout.incoming_message_panel as the ID for
-        // the notification.  It could be any integer you want, but we use
-        // the convention of using a resource id for a string related to
-        // the notification.  It will always be a unique number within your
-        // application.
-        nm.notify(R.string.imcoming_message_ticker_text, notif);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessageView.java b/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessageView.java
deleted file mode 100644
index c3bead0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/IncomingMessageView.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.NotificationManager;
-import android.os.Bundle;
-
-import java.util.Map;
-
-/**
- * This activity is run as the click activity for {@link IncomingMessage}.
- * When it comes up, it also clears the notification, because the "message"
- * has been "read."
- */
-public class IncomingMessageView extends Activity {
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.incoming_message_view);
-
-        // look up the notification manager service
-        NotificationManager nm = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
-
-        // cancel the notification that we started in IncomingMessage
-        nm.cancel(R.string.imcoming_message_ticker_text);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/Intents.java b/samples/ApiDemos/src/com/example/android/apis/app/Intents.java
deleted file mode 100644
index 8f02b83..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/Intents.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class Intents extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.intents);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.get_music);
-        button.setOnClickListener(mGetMusicListener);
-    }
-
-    private OnClickListener mGetMusicListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
-            intent.setType("audio/*");
-            startActivity(Intent.createChooser(intent, "Select music"));
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LauncherShortcuts.java b/samples/ApiDemos/src/com/example/android/apis/app/LauncherShortcuts.java
deleted file mode 100644
index f28deab..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LauncherShortcuts.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.os.Parcelable;
-import android.widget.TextView;
-
-import com.example.android.apis.R;
-
-/**
- * This Activity actually handles two stages of a launcher shortcut's life cycle.
- * 
- * 1. Your application offers to provide shortcuts to the launcher.  When
- *    the user installs a shortcut, an activity within your application
- *    generates the actual shortcut and returns it to the launcher, where it
- *    is shown to the user as an icon.
- *
- * 2. Any time the user clicks on an installed shortcut, an intent is sent.
- *    Typically this would then be handled as necessary by an activity within
- *    your application.
- *    
- * We handle stage 1 (creating a shortcut) by simply sending back the information (in the form
- * of an {@link android.content.Intent} that the launcher will use to create the shortcut.
- * 
- * You can also implement this in an interactive way, by having your activity actually present
- * UI for the user to select the specific nature of the shortcut, such as a contact, picture, URL,
- * media item, or action.
- * 
- * We handle stage 2 (responding to a shortcut) in this sample by simply displaying the contents
- * of the incoming {@link android.content.Intent}.
- * 
- * In a real application, you would probably use the shortcut intent to display specific content
- * or start a particular operation.
- */
-public class LauncherShortcuts extends Activity {
-
-    private static final String EXTRA_KEY = "com.example.android.apis.app.LauncherShortcuts";
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        // Resolve the intent
-
-        final Intent intent = getIntent();
-        final String action = intent.getAction();
-
-        // If the intent is a request to create a shortcut, we'll do that and exit
-
-        if (Intent.ACTION_CREATE_SHORTCUT.equals(action)) {
-            setupShortcut();
-            finish();
-            return;
-        }
-
-        // If we weren't launched with a CREATE_SHORTCUT intent, simply put up an informative
-        // display.
-
-        // Inflate our UI from its XML layout description.
-
-        setContentView(R.layout.launcher_shortcuts);
-
-        // Provide a lightweight view of the Intent that launched us
-
-        TextView intentInfo = (TextView) findViewById(R.id.txt_shortcut_intent);
-        String info = intent.toString();
-        String extra = intent.getStringExtra(EXTRA_KEY);
-        if (extra != null) {
-            info = info + " " + extra;
-        }
-        intentInfo.setText(info);
-    }
-
-    /**
-     * This function creates a shortcut and returns it to the caller.  There are actually two 
-     * intents that you will send back.
-     * 
-     * The first intent serves as a container for the shortcut and is returned to the launcher by 
-     * setResult().  This intent must contain three fields:
-     * 
-     * <ul>
-     * <li>{@link android.content.Intent#EXTRA_SHORTCUT_INTENT} The shortcut intent.</li>
-     * <li>{@link android.content.Intent#EXTRA_SHORTCUT_NAME} The text that will be displayed with
-     * the shortcut.</li>
-     * <li>{@link android.content.Intent#EXTRA_SHORTCUT_ICON} The shortcut's icon, if provided as a
-     * bitmap, <i>or</i> {@link android.content.Intent#EXTRA_SHORTCUT_ICON_RESOURCE} if provided as
-     * a drawable resource.</li>
-     * </ul>
-     * 
-     * If you use a simple drawable resource, note that you must wrapper it using
-     * {@link android.content.Intent.ShortcutIconResource}, as shown below.  This is required so
-     * that the launcher can access resources that are stored in your application's .apk file.  If 
-     * you return a bitmap, such as a thumbnail, you can simply put the bitmap into the extras 
-     * bundle using {@link android.content.Intent#EXTRA_SHORTCUT_ICON}.
-     * 
-     * The shortcut intent can be any intent that you wish the launcher to send, when the user 
-     * clicks on the shortcut.  Typically this will be {@link android.content.Intent#ACTION_VIEW} 
-     * with an appropriate Uri for your content, but any Intent will work here as long as it 
-     * triggers the desired action within your Activity.
-     */
-    private void setupShortcut() {
-        // First, set up the shortcut intent.  For this example, we simply create an intent that
-        // will bring us directly back to this activity.  A more typical implementation would use a 
-        // data Uri in order to display a more specific result, or a custom action in order to 
-        // launch a specific operation.
-
-        Intent shortcutIntent = new Intent(Intent.ACTION_MAIN);
-        shortcutIntent.setClassName(this, this.getClass().getName());
-        shortcutIntent.putExtra(EXTRA_KEY, "ApiDemos Provided This Shortcut");
-
-        // Then, set up the container intent (the response to the caller)
-
-        Intent intent = new Intent();
-        intent.putExtra(Intent.EXTRA_SHORTCUT_INTENT, shortcutIntent);
-        intent.putExtra(Intent.EXTRA_SHORTCUT_NAME, getString(R.string.shortcut_name));
-        Parcelable iconResource = Intent.ShortcutIconResource.fromContext(
-                this,  R.drawable.app_sample_code);
-        intent.putExtra(Intent.EXTRA_SHORTCUT_ICON_RESOURCE, iconResource);
-
-        // Now, return the result to the launcher
-
-        setResult(RESULT_OK, intent);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LaunchingPreferences.java b/samples/ApiDemos/src/com/example/android/apis/app/LaunchingPreferences.java
deleted file mode 100644
index aa151fe..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LaunchingPreferences.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.preference.PreferenceManager;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-import android.widget.Toast;
-import android.widget.LinearLayout.LayoutParams;
-
-/**
- * Demonstrates launching a PreferenceActivity and grabbing a value it saved.
- */
-public class LaunchingPreferences extends Activity implements OnClickListener {
-
-    private static final int REQUEST_CODE_PREFERENCES = 1;
-    
-    private TextView mCounterText;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        /*
-         * If this were my app's main activity, I would load the default values
-         * so they're set even if the user does not go into the preferences
-         * screen. Another good place to call this method would be from a
-         * subclass of Application, so your default values would be loaded
-         * regardless of entry into your application (for example, a service or
-         * activity).
-         */  
-        PreferenceManager.setDefaultValues(this, R.xml.advanced_preferences, false);
-        
-        // Simple layout
-        LinearLayout layout = new LinearLayout(this);
-        layout.setOrientation(LinearLayout.VERTICAL);
-        setContentView(layout);
-        
-        // Create a simple button that will launch the preferences
-        Button launchPreferences = new Button(this);
-        launchPreferences.setText(getString(R.string.launch_preference_activity));
-        launchPreferences.setOnClickListener(this);
-        layout.addView(launchPreferences, new LayoutParams(LayoutParams.FILL_PARENT,
-                LayoutParams.WRAP_CONTENT));
-        
-        mCounterText = new TextView(this);
-        layout.addView(mCounterText, new LayoutParams(LayoutParams.FILL_PARENT,
-                LayoutParams.WRAP_CONTENT));
-        
-        updateCounterText();
-    }
-
-    public void onClick(View v) {
-        
-        // When the button is clicked, launch an activity through this intent
-        Intent launchPreferencesIntent = new Intent().setClass(this, AdvancedPreferences.class);
-        
-        // Make it a subactivity so we know when it returns
-        startActivityForResult(launchPreferencesIntent, REQUEST_CODE_PREFERENCES);
-    }
-
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
-        super.onActivityResult(requestCode, resultCode, data);
-        
-        // The preferences returned if the request code is what we had given
-        // earlier in startSubActivity
-        if (requestCode == REQUEST_CODE_PREFERENCES) {
-            // Read a sample value they have set
-            updateCounterText();
-        }
-    }
-
-    private void updateCounterText() {
-        // Since we're in the same package, we can use this context to get
-        // the default shared preferences
-        SharedPreferences sharedPref = PreferenceManager.getDefaultSharedPreferences(this);
-        final int counter = sharedPref.getInt(AdvancedPreferences.KEY_MY_PREFERENCE, 0);
-        mCounterText.setText(getString(R.string.counter_value_is) + " " + counter);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LocalSample.java b/samples/ApiDemos/src/com/example/android/apis/app/LocalSample.java
deleted file mode 100644
index 1bb26e9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LocalSample.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.os.RemoteException;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-import com.example.android.apis.R;
-
-
-/**
- * Front-end for launching {@link LocalSampleInstrumentation} example
- * instrumentation class.
- */
-public class LocalSample extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.local_sample);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.go);
-        button.setOnClickListener(mGoListener);
-    }
-
-    private OnClickListener mGoListener = new OnClickListener() {
-        public void onClick(View v) {
-            startInstrumentation(new ComponentName(LocalSample.this,
-                    LocalSampleInstrumentation.class), null, null);
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LocalSampleInstrumentation.java b/samples/ApiDemos/src/com/example/android/apis/app/LocalSampleInstrumentation.java
deleted file mode 100644
index e0f6163..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LocalSampleInstrumentation.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.app.Instrumentation;
-import android.content.Intent;
-import android.view.KeyEvent;
-import android.os.Bundle;
-import android.util.Log;
-
-import java.util.Map;
-
-/**
- * This is an example implementation of the {@link android.app.Instrumentation}
- * class demonstrating instrumentation against one of this application's sample
- * activities.
- */
-public class LocalSampleInstrumentation extends Instrumentation {
-    public abstract static class ActivityRunnable implements Runnable {
-        public final Activity activity;
-        public ActivityRunnable(Activity _activity) {
-            activity = _activity;
-        }
-    }
-
-    @Override
-    public void onCreate(Bundle arguments) {
-        super.onCreate(arguments);
-
-        // When this instrumentation is created, we simply want to start
-        // its test code off in a separate thread, which will call back
-        // to us in onStart().
-        start();
-    }
-
-    @Override
-    public void onStart() {
-        super.onStart();
-        // First start the activity we are instrumenting -- the save/restore
-        // state sample, which has a nice edit text into which we can write
-        // text.
-        Intent intent = new Intent(Intent.ACTION_MAIN);
-        intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-        intent.setClass(getTargetContext(), SaveRestoreState.class);
-        SaveRestoreState activity = (SaveRestoreState)startActivitySync(intent);
-
-        // This is the Activity object that was started, to do with as we want.
-        Log.i("LocalSampleInstrumentation",
-              "Initial text: " + activity.getSavedText());
-
-        // Clear the text so we start fresh.
-        runOnMainSync(new ActivityRunnable(activity) {
-            public void run() {
-                ((SaveRestoreState)activity).setSavedText("");
-            }
-        });
-
-        // Act like the user is typing some text.
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_SHIFT_LEFT));
-        sendCharacterSync(KeyEvent.KEYCODE_H);
-        sendKeySync(new KeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_SHIFT_LEFT));
-        sendCharacterSync(KeyEvent.KEYCODE_E);
-        sendCharacterSync(KeyEvent.KEYCODE_L);
-        sendCharacterSync(KeyEvent.KEYCODE_L);
-        sendCharacterSync(KeyEvent.KEYCODE_O);
-
-        // Wait for the activity to finish all of its processing.
-        waitForIdleSync();
-
-        // Retrieve the text we should have written...
-        Log.i("LocalSampleInstrumentation",
-              "Final text: " + activity.getSavedText());
-
-        // And we are done!
-        Log.i("ContactsFilterInstrumentation", "Done!");
-        finish(Activity.RESULT_OK, null);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LocalService.java b/samples/ApiDemos/src/com/example/android/apis/app/LocalService.java
deleted file mode 100644
index 8791578..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LocalService.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.Binder;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.widget.Toast;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * This is an example of implementing an application service that runs locally
- * in the same process as the application.  The {@link LocalServiceController}
- * and {@link LocalServiceBinding} classes show how to interact with the
- * service.
- *
- * <p>Notice the use of the {@link NotificationManager} when interesting things
- * happen in the service.  This is generally how background services should
- * interact with the user, rather than doing something more disruptive such as
- * calling startActivity().
- */
-public class LocalService extends Service {
-    private NotificationManager mNM;
-
-    /**
-     * Class for clients to access.  Because we know this service always
-     * runs in the same process as its clients, we don't need to deal with
-     * IPC.
-     */
-    public class LocalBinder extends Binder {
-        LocalService getService() {
-            return LocalService.this;
-        }
-    }
-    
-    @Override
-    public void onCreate() {
-        mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
-
-        // Display a notification about us starting.  We put an icon in the status bar.
-        showNotification();
-    }
-
-    @Override
-    public void onDestroy() {
-        // Cancel the persistent notification.
-        mNM.cancel(R.string.local_service_started);
-
-        // Tell the user we stopped.
-        Toast.makeText(this, R.string.local_service_stopped, Toast.LENGTH_SHORT).show();
-    }
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        return mBinder;
-    }
-
-    // This is the object that receives interactions from clients.  See
-    // RemoteService for a more complete example.
-    private final IBinder mBinder = new LocalBinder();
-
-    /**
-     * Show a notification while this service is running.
-     */
-    private void showNotification() {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(R.string.local_service_started);
-
-        // Set the icon, scrolling text and timestamp
-        Notification notification = new Notification(R.drawable.stat_sample, text,
-                System.currentTimeMillis());
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, LocalServiceController.class), 0);
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.local_service_label),
-                       text, contentIntent);
-
-        // Send the notification.
-        // We use a layout id because it is a unique number.  We use it later to cancel.
-        mNM.notify(R.string.local_service_started, notification);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceBinding.java b/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceBinding.java
deleted file mode 100644
index ddcfad5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceBinding.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.content.ServiceConnection;
-import android.os.Bundle;
-import android.os.IBinder;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.Toast;
-
-
-/**
- * <p>Example of binding and unbinding to the {@link LocalService}.
- * This demonstrates the implementation of a service which the client will
- * bind to, receiving an object through which it can communicate with the service.</p>
- */
-public class LocalServiceBinding extends Activity {
-    private boolean mIsBound;
-    private LocalService mBoundService;
-
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.local_service_binding);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.bind);
-        button.setOnClickListener(mBindListener);
-        button = (Button)findViewById(R.id.unbind);
-        button.setOnClickListener(mUnbindListener);
-    }
-
-    private ServiceConnection mConnection = new ServiceConnection() {
-        public void onServiceConnected(ComponentName className, IBinder service) {
-            // This is called when the connection with the service has been
-            // established, giving us the service object we can use to
-            // interact with the service.  Because we have bound to a explicit
-            // service that we know is running in our own process, we can
-            // cast its IBinder to a concrete class and directly access it.
-            mBoundService = ((LocalService.LocalBinder)service).getService();
-            
-            // Tell the user about this for our demo.
-            Toast.makeText(LocalServiceBinding.this, R.string.local_service_connected,
-                    Toast.LENGTH_SHORT).show();
-        }
-
-        public void onServiceDisconnected(ComponentName className) {
-            // This is called when the connection with the service has been
-            // unexpectedly disconnected -- that is, its process crashed.
-            // Because it is running in our same process, we should never
-            // see this happen.
-            mBoundService = null;
-            Toast.makeText(LocalServiceBinding.this, R.string.local_service_disconnected,
-                    Toast.LENGTH_SHORT).show();
-        }
-    };
-
-    private OnClickListener mBindListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Establish a connection with the service.  We use an explicit
-            // class name because we want a specific service implementation that
-            // we know will be running in our own process (and thus won't be
-            // supporting component replacement by other applications).
-            bindService(new Intent(LocalServiceBinding.this, 
-                    LocalService.class), mConnection, Context.BIND_AUTO_CREATE);
-            mIsBound = true;
-        }
-    };
-
-    private OnClickListener mUnbindListener = new OnClickListener() {
-        public void onClick(View v) {
-            if (mIsBound) {
-                // Detach our existing connection.
-                unbindService(mConnection);
-                mIsBound = false;
-            }
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceController.java b/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceController.java
deleted file mode 100644
index 6041249..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/LocalServiceController.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * <p>Example of explicitly starting and stopping the {@link LocalService}.
- * This demonstrates the implementation of a service that runs in the same
- * process as the rest of the application, which is explicitly started and stopped
- * as desired.</p>
- */
-public class LocalServiceController extends Activity {
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.local_service_controller);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.start);
-        button.setOnClickListener(mStartListener);
-        button = (Button)findViewById(R.id.stop);
-        button.setOnClickListener(mStopListener);
-    }
-
-    private OnClickListener mStartListener = new OnClickListener() {
-        public void onClick(View v)
-        {
-            // Make sure the service is started.  It will continue running
-            // until someone calls stopService().  The Intent we use to find
-            // the service explicitly specifies our service component, because
-            // we want it running in our own process and don't want other
-            // applications to replace it.
-            startService(new Intent(LocalServiceController.this,
-                    LocalService.class));
-        }
-    };
-
-    private OnClickListener mStopListener = new OnClickListener() {
-        public void onClick(View v)
-        {
-            // Cancel a previous call to startService().  Note that the
-            // service will not actually stop at this point if there are
-            // still bound clients.
-            stopService(new Intent(LocalServiceController.this,
-                    LocalService.class));
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/MenuInflateFromXml.java b/samples/ApiDemos/src/com/example/android/apis/app/MenuInflateFromXml.java
deleted file mode 100644
index f51b3b8..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/MenuInflateFromXml.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.NotificationManager;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.MenuInflater;
-import android.view.MenuItem;
-import android.widget.ArrayAdapter;
-import android.widget.FrameLayout;
-import android.widget.LinearLayout;
-import android.widget.Spinner;
-import android.widget.TextView;
-import android.widget.Toast;
-
-/**
- * Demonstrates inflating menus from XML. There are different menu XML resources
- * that the user can choose to inflate. First, select an example resource from
- * the spinner, and then hit the menu button. To choose another, back out of the
- * activity and start over.
- */
-public class MenuInflateFromXml extends Activity {
-    /**
-     * Different example menu resources.
-     */
-    private static final int sMenuExampleResources[] = {
-        R.menu.title_only, R.menu.title_icon, R.menu.submenu, R.menu.groups,
-        R.menu.checkable, R.menu.shortcuts, R.menu.order, R.menu.category_order,
-        R.menu.visible, R.menu.disabled
-    };
-    
-    /**
-     * Names corresponding to the different example menu resources.
-     */
-    private static final String sMenuExampleNames[] = {
-        "Title only", "Title and Icon", "Submenu", "Groups",
-        "Checkable", "Shortcuts", "Order", "Category and Order",
-        "Visible", "Disabled"
-    };
-   
-    /**
-     * Lets the user choose a menu resource.
-     */
-    private Spinner mSpinner;
-
-    /**
-     * Shown as instructions.
-     */
-    private TextView mInstructionsText;
-    
-    /**
-     * Safe to hold on to this.
-     */
-    private Menu mMenu;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Create a simple layout
-        LinearLayout layout = new LinearLayout(this);
-        layout.setOrientation(LinearLayout.VERTICAL);
-        
-        // Create the spinner to allow the user to choose a menu XML
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_spinner_item, sMenuExampleNames); 
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        mSpinner = new Spinner(this);
-        // When programmatically creating views, make sure to set an ID
-        // so it will automatically save its instance state
-        mSpinner.setId(R.id.spinner);
-        mSpinner.setAdapter(adapter);
-        
-        // Add the spinner
-        layout.addView(mSpinner,
-                new LinearLayout.LayoutParams(
-                        LinearLayout.LayoutParams.FILL_PARENT,
-                        LinearLayout.LayoutParams.WRAP_CONTENT));
-
-        // Create help text
-        mInstructionsText = new TextView(this);
-        mInstructionsText.setText(getResources().getString(
-                R.string.menu_from_xml_instructions_press_menu));
-        
-        // Add the help, make it look decent
-        LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(
-                LinearLayout.LayoutParams.FILL_PARENT,
-                LinearLayout.LayoutParams.WRAP_CONTENT);
-        lp.setMargins(10, 10, 10, 10);
-        layout.addView(mInstructionsText, lp);
-        
-        // Set the layout as our content view
-        setContentView(layout);
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        // Hold on to this
-        mMenu = menu;
-        
-        // Inflate the currently selected menu XML resource.
-        MenuInflater inflater = getMenuInflater();
-        inflater.inflate(sMenuExampleResources[mSpinner.getSelectedItemPosition()], menu);
-        
-        // Disable the spinner since we've already created the menu and the user
-        // can no longer pick a different menu XML.
-        mSpinner.setEnabled(false);
-        
-        // Change instructions
-        mInstructionsText.setText(getResources().getString(
-                R.string.menu_from_xml_instructions_go_back));
-        
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-            // For "Title only": Examples of matching an ID with one assigned in
-            //                   the XML
-            case R.id.jump:
-                Toast.makeText(this, "Jump up in the air!", Toast.LENGTH_SHORT).show();
-                return true;
-
-            case R.id.dive:
-                Toast.makeText(this, "Dive into the water!", Toast.LENGTH_SHORT).show();
-                return true;
-
-            // For "Groups": Toggle visibility of grouped menu items with
-            //               nongrouped menu items
-            case R.id.browser_visibility:
-                // The refresh item is part of the browser group
-                final boolean shouldShowBrowser = !mMenu.findItem(R.id.refresh).isVisible();
-                mMenu.setGroupVisible(R.id.browser, shouldShowBrowser);
-                break;
-                
-            case R.id.email_visibility:
-                // The reply item is part of the email group
-                final boolean shouldShowEmail = !mMenu.findItem(R.id.reply).isVisible();
-                mMenu.setGroupVisible(R.id.email, shouldShowEmail);
-                break;
-                
-            // Generic catch all for all the other menu resources
-            default:
-                // Don't toast text when a submenu is clicked
-                if (!item.hasSubMenu()) {
-                    Toast.makeText(this, item.getTitle(), Toast.LENGTH_SHORT).show();
-                    return true;
-                }
-                break;
-        }
-        
-        return false;
-    }
-    
-    
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/MyPreference.java b/samples/ApiDemos/src/com/example/android/apis/app/MyPreference.java
deleted file mode 100644
index 967c181..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/MyPreference.java
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.preference.Preference;
-import android.util.AttributeSet;
-import android.view.View;
-import android.widget.TextView;
-
-/**
- * This is an example of a custom preference type. The preference counts the
- * number of clicks it has received and stores/retrieves it from the storage.
- */
-public class MyPreference extends Preference {
-    private int mClickCounter;
-    
-    // This is the constructor called by the inflater
-    public MyPreference(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        
-        setWidgetLayoutResource(R.layout.preference_widget_mypreference);        
-    }
-
-    @Override
-    protected void onBindView(View view) {
-        super.onBindView(view);
-        
-        // Set our custom views inside the layout
-        final TextView myTextView = (TextView) view.findViewById(R.id.mypreference_widget);
-        if (myTextView != null) {
-            myTextView.setText(String.valueOf(mClickCounter));
-        }
-    }
-
-    @Override
-    protected void onClick() {
-        int newValue = mClickCounter + 1;
-        // Give the client a chance to ignore this change if they deem it
-        // invalid
-        if (!callChangeListener(newValue)) {
-            // They don't want the value to be set
-            return;
-        }
-        
-        // Increment counter
-        mClickCounter = newValue;
-        
-        // Save to persistent storage (this method will make sure this
-        // preference should be persistent, along with other useful checks)
-        persistInt(mClickCounter);
-        
-        // Data has changed, notify so UI can be refreshed!
-        notifyChanged();
-    }
-
-    @Override
-    protected Object onGetDefaultValue(TypedArray a, int index) {
-        // This preference type's value type is Integer, so we read the default
-        // value from the attributes as an Integer.
-        return a.getInteger(index, 0);
-    }
-
-    @Override
-    protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
-        if (restoreValue) {
-            // Restore state
-            mClickCounter = getPersistedInt(mClickCounter);
-        } else {
-            // Set state
-            int value = (Integer) defaultValue;
-            mClickCounter = value;
-            persistInt(value);
-        }
-    }
-
-    @Override
-    protected Parcelable onSaveInstanceState() {
-        /*
-         * Suppose a client uses this preference type without persisting. We
-         * must save the instance state so it is able to, for example, survive
-         * orientation changes.
-         */
-        
-        final Parcelable superState = super.onSaveInstanceState();
-        if (isPersistent()) {
-            // No need to save instance state since it's persistent
-            return superState;
-        }
-
-        // Save the instance state
-        final SavedState myState = new SavedState(superState);
-        myState.clickCounter = mClickCounter;
-        return myState;
-    }
-
-    @Override
-    protected void onRestoreInstanceState(Parcelable state) {
-        if (!state.getClass().equals(SavedState.class)) {
-            // Didn't save state for us in onSaveInstanceState
-            super.onRestoreInstanceState(state);
-            return;
-        }
-     
-        // Restore the instance state
-        SavedState myState = (SavedState) state;
-        super.onRestoreInstanceState(myState.getSuperState());
-        mClickCounter = myState.clickCounter;
-        notifyChanged();
-    }
-    
-    /**
-     * SavedState, a subclass of {@link BaseSavedState}, will store the state
-     * of MyPreference, a subclass of Preference.
-     * <p>
-     * It is important to always call through to super methods.
-     */
-    private static class SavedState extends BaseSavedState {
-        int clickCounter;
-        
-        public SavedState(Parcel source) {
-            super(source);
-            
-            // Restore the click counter
-            clickCounter = source.readInt();
-        }
-
-        @Override
-        public void writeToParcel(Parcel dest, int flags) {
-            super.writeToParcel(dest, flags);
-            
-            // Save the click counter
-            dest.writeInt(clickCounter);
-        }
-
-        public SavedState(Parcelable superState) {
-            super(superState);
-        }
-
-        public static final Parcelable.Creator<SavedState> CREATOR =
-                new Parcelable.Creator<SavedState>() {
-            public SavedState createFromParcel(Parcel in) {
-                return new SavedState(in);
-            }
-
-            public SavedState[] newArray(int size) {
-                return new SavedState[size];
-            }
-        };
-    }
-    
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/NotificationDisplay.java b/samples/ApiDemos/src/com/example/android/apis/app/NotificationDisplay.java
deleted file mode 100644
index a6c20ea..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/NotificationDisplay.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.NotificationManager;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.Gravity;
-import android.view.View;
-import android.view.WindowManager;
-import android.widget.ImageButton;
-import android.widget.LinearLayout;
-import android.widget.RelativeLayout;
-
-
-/**
- * Activity used by StatusBarNotification to show the notification to the user.
- */
-public class NotificationDisplay extends Activity implements View.OnClickListener {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-    protected void onCreate(Bundle icicle) {
-        // Be sure to call the super class.
-        super.onCreate(icicle);
-
-        // Have the system blur any windows behind this one.
-        getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND,
-                WindowManager.LayoutParams.FLAG_BLUR_BEHIND);
-        
-        RelativeLayout container = new RelativeLayout(this);
-        
-        ImageButton button = new ImageButton(this);
-        button.setImageResource(getIntent().getIntExtra("moodimg", 0));
-        button.setOnClickListener(this);
-        
-        RelativeLayout.LayoutParams lp = new RelativeLayout.LayoutParams(
-                RelativeLayout.LayoutParams.WRAP_CONTENT,
-                RelativeLayout.LayoutParams.WRAP_CONTENT);
-        lp.addRule(RelativeLayout.CENTER_IN_PARENT);
-        
-        container.addView(button, lp);
-        
-        setContentView(container);
-    }
-
-    public void onClick(View v) {
-        // The user has confirmed this notification, so remove it.
-        ((NotificationManager) getSystemService(NOTIFICATION_SERVICE))
-                .cancel(R.layout.status_bar_notifications);
-        
-        // Pressing on the button brings the user back to our mood ring,
-        // as part of the api demos app.  Note the use of NEW_TASK here,
-        // since the notification display activity is run as a separate task.
-        Intent intent = new Intent(this, StatusBarNotifications.class);
-        intent.setAction(Intent.ACTION_MAIN);
-        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-        startActivity(intent);
-        
-        // We're done.
-        finish();
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/NotifyWithText.java b/samples/ApiDemos/src/com/example/android/apis/app/NotifyWithText.java
deleted file mode 100644
index 950ded9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/NotifyWithText.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.Button;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Toast;
-
-/**
- * When you push the button on this Activity, it creates a {@link Toast} object and
- * using the Toast method.
- * @see Toast
- * @see Toast#makeText(android.content.Context,int,int)
- * @see Toast#makeText(android.content.Context,java.lang.CharSequence,int)
- * @see Toast#LENGTH_SHORT
- * @see Toast#LENGTH_LONG
- */
-public class NotifyWithText extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.notify_with_text);
-
-        Button button;
-
-        // short notification
-        button = (Button) findViewById(R.id.short_notify);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                // Note that we create the Toast object and call the show() method
-                // on it all on one line.  Most uses look like this, but there
-                // are other methods on Toast that you can call to configure how
-                // it appears.
-                //
-                // Note also that we use the version of makeText that takes a
-                // resource id (R.string.short_notification_text).  There is also
-                // a version that takes a CharSequence if you must construct
-                // the text yourself.
-                Toast.makeText(NotifyWithText.this, R.string.short_notification_text,
-                    Toast.LENGTH_SHORT).show();
-            }
-        });
-
-        // long notification
-        // The only difference here is that the notification stays up longer.
-        // You might want to use this if there is more text that they're going
-        // to read.
-        button = (Button) findViewById(R.id.long_notify);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                Toast.makeText(NotifyWithText.this, R.string.long_notification_text,
-                    Toast.LENGTH_LONG).show();
-            }
-        });
-
-
-
-
-
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/NotifyingController.java b/samples/ApiDemos/src/com/example/android/apis/app/NotifyingController.java
deleted file mode 100644
index a0de699..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/NotifyingController.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * Controller to start and stop a service. The serivce will update a status bar
- * notification every 5 seconds for a minute.
- */
-public class NotifyingController extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.notifying_controller);
-
-        Button button = (Button) findViewById(R.id.notifyStart);
-        button.setOnClickListener(mStartListener);
-        button = (Button) findViewById(R.id.notifyStop);
-        button.setOnClickListener(mStopListener);
-    }
-
-    private OnClickListener mStartListener = new OnClickListener() {
-        public void onClick(View v) {
-            startService(new Intent(NotifyingController.this, 
-                    NotifyingService.class));
-        }
-    };
-
-    private OnClickListener mStopListener = new OnClickListener() {
-        public void onClick(View v) {
-            stopService(new Intent(NotifyingController.this, 
-                    NotifyingService.class));
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/NotifyingService.java b/samples/ApiDemos/src/com/example/android/apis/app/NotifyingService.java
deleted file mode 100644
index e580978..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/NotifyingService.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.Binder;
-import android.os.ConditionVariable;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.os.RemoteException;
-import android.widget.RemoteViews;
-
-/**
- * This is an example of service that will update its status bar balloon 
- * every 5 seconds for a minute.
- * 
- */
-public class NotifyingService extends Service {
-    
-    // Use a layout id for a unique identifier
-    private static int MOOD_NOTIFICATIONS = R.layout.status_bar_notifications;
-
-    // variable which controls the notification thread 
-    private ConditionVariable mCondition;
- 
-    @Override
-    public void onCreate() {
-        mNM = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
-
-        // Start up the thread running the service.  Note that we create a
-        // separate thread because the service normally runs in the process's
-        // main thread, which we don't want to block.
-        Thread notifyingThread = new Thread(null, mTask, "NotifyingService");
-        mCondition = new ConditionVariable(false);
-        notifyingThread.start();
-    }
-
-    @Override
-    public void onDestroy() {
-        // Cancel the persistent notification.
-        mNM.cancel(MOOD_NOTIFICATIONS);
-        // Stop the thread from generating further notifications
-        mCondition.open();
-    }
-
-    private Runnable mTask = new Runnable() {
-        public void run() {
-            for (int i = 0; i < 4; ++i) {
-                showNotification(R.drawable.stat_happy,
-                        R.string.status_bar_notifications_happy_message);
-                if (mCondition.block(5 * 1000)) 
-                    break;
-                showNotification(R.drawable.stat_neutral,
-                        R.string.status_bar_notifications_ok_message);
-                if (mCondition.block(5 * 1000)) 
-                    break;
-                showNotification(R.drawable.stat_sad,
-                        R.string.status_bar_notifications_sad_message);
-                if (mCondition.block(5 * 1000)) 
-                    break;
-            }
-            // Done with our work...  stop the service!
-            NotifyingService.this.stopSelf();
-        }
-    };
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        return mBinder;
-    }
-    
-    private void showNotification(int moodId, int textId) {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(textId);
-
-        // Set the icon, scrolling text and timestamp.
-        // Note that in this example, we pass null for tickerText.  We update the icon enough that
-        // it is distracting to show the ticker text every time it changes.  We strongly suggest
-        // that you do this as well.  (Think of of the "New hardware found" or "Network connection
-        // changed" messages that always pop up)
-        Notification notification = new Notification(moodId, null, System.currentTimeMillis());
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, NotifyingController.class), 0);
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.status_bar_notifications_mood_title),
-                       text, contentIntent);
-
-        // Send the notification.
-        // We use a layout id because it is a unique number.  We use it later to cancel.
-        mNM.notify(MOOD_NOTIFICATIONS, notification);
-    }
-
-    // This is the object that receives interactions from clients.  See
-    // RemoteService for a more complete example.
-    private final IBinder mBinder = new Binder() {
-        @Override
-        protected boolean onTransact(int code, Parcel data, Parcel reply,
-                int flags) throws RemoteException {
-            return super.onTransact(code, data, reply, flags);
-        }
-    };
-
-    private NotificationManager mNM;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/OneShotAlarm.java b/samples/ApiDemos/src/com/example/android/apis/app/OneShotAlarm.java
deleted file mode 100644
index ec7e074..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/OneShotAlarm.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.content.Context;
-import android.content.Intent;
-import android.content.BroadcastReceiver;
-import android.widget.Toast;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * This is an example of implement an {@link BroadcastReceiver} for an alarm that
- * should occur once.
- * <p>
- * When the alarm goes off, we show a <i>Toast</i>, a quick message.
- */
-public class OneShotAlarm extends BroadcastReceiver
-{
-    @Override
-    public void onReceive(Context context, Intent intent)
-    {
-        Toast.makeText(context, R.string.one_shot_received, Toast.LENGTH_SHORT).show();
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/PersistentState.java b/samples/ApiDemos/src/com/example/android/apis/app/PersistentState.java
deleted file mode 100644
index 618a692..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/PersistentState.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.widget.EditText;
-import android.widget.TextView;
-
-/**
- * Simple example of using persistent preferences to retain a screen's state.
- * <p>This can be used as an alternative to the normal
- * <code>onSaveInstanceState()</code> mechanism, if you
- * wish the state to persist even after an activity is finished.</p>
- *
- * <p>Note that using this approach requires more care, since you are sharing
- * the persistent state potentially across multiple instances of the activity.
- * In particular, if you allow a new instance of the activity to be launched
- * directly on top of the existing instance, the state can get out of sync
- * because the new instance is resumed before the old one is paused.</p>
- *
- * <p>For any persistent state that is not simplistic, a content
- * provider is often a better choice.</p>
- *
- * <p>In this example we are currently saving and restoring the state of the
- * top text editor, but not of the bottom text editor.  You can see the difference
- * by editing the two text fields, then going back from the activity and
- * starting it again.</p>
- *
- * <h4>Demo</h4>
- * App/Activity/Save &amp; Restore State
- *
- * <h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td class="LinkColumn">src/com.example.android.apis/app/PersistentState.java</td>
- *             <td class="DescrColumn">The Save/Restore Screen implementation</td>
- *         </tr>
- *         <tr>
- *             <td class="LinkColumn">/res/any/layout/save_restore_state.xml</td>
- *             <td class="DescrColumn">Defines contents of the screen</td>
- *         </tr>
- * </table>
- *
- */
-public class PersistentState extends Activity
-{
-    /**
-     * Initialization of the Activity after it is first created.  Here we use
-     * {@link android.app.Activity#setContentView setContentView()} to set up
-     * the Activity's content, and retrieve the EditText widget whose state we
-     * will persistent.
-     */
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/save_restore_state.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.save_restore_state);
-
-        // Set message to be appropriate for this screen.
-        ((TextView)findViewById(R.id.msg)).setText(R.string.persistent_msg);
-
-        // Retrieve the EditText widget whose state we will save.
-        mSaved = (EditText)findViewById(R.id.saved);
-    }
-
-    /**
-     * Upon being resumed we can retrieve the current state.  This allows us
-     * to update the state if it was changed at any time while paused.
-     */
-    @Override
-    protected void onResume() {
-        super.onResume();
-
-        SharedPreferences prefs = getPreferences(0); 
-        String restoredText = prefs.getString("text", null);
-        if (restoredText != null) {
-            mSaved.setText(restoredText, TextView.BufferType.EDITABLE);
-
-            int selectionStart = prefs.getInt("selection-start", -1);
-            int selectionEnd = prefs.getInt("selection-end", -1);
-            if (selectionStart != -1 && selectionEnd != -1) {
-                mSaved.setSelection(selectionStart, selectionEnd);
-            }
-        }
-    }
-
-    /**
-     * Any time we are paused we need to save away the current state, so it
-     * will be restored correctly when we are resumed.
-     */
-    @Override
-    protected void onPause() {
-        super.onPause();
-
-        SharedPreferences.Editor editor = getPreferences(0).edit();
-        editor.putString("text", mSaved.getText().toString());
-        editor.putInt("selection-start", mSaved.getSelectionStart());
-        editor.putInt("selection-end", mSaved.getSelectionEnd());
-        editor.commit();
-    }
-
-    private EditText mSaved;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/PreferenceDependencies.java b/samples/ApiDemos/src/com/example/android/apis/app/PreferenceDependencies.java
deleted file mode 100644
index 27c22de..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/PreferenceDependencies.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.os.Bundle;
-import android.preference.PreferenceActivity;
-
-public class PreferenceDependencies extends PreferenceActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        addPreferencesFromResource(R.xml.preference_dependencies);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromCode.java b/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromCode.java
deleted file mode 100644
index be22b49..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromCode.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.content.Intent;
-import android.content.res.TypedArray;
-import android.net.Uri;
-import android.os.Bundle;
-import android.preference.CheckBoxPreference;
-import android.preference.EditTextPreference;
-import android.preference.ListPreference;
-import android.preference.PreferenceActivity;
-import android.preference.PreferenceCategory;
-import android.preference.PreferenceScreen;
-
-import com.example.android.apis.R;
-
-public class PreferencesFromCode extends PreferenceActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        setPreferenceScreen(createPreferenceHierarchy());
-    }
-
-    private PreferenceScreen createPreferenceHierarchy() {
-        // Root
-        PreferenceScreen root = getPreferenceManager().createPreferenceScreen(this);
-        
-        // Inline preferences 
-        PreferenceCategory inlinePrefCat = new PreferenceCategory(this);
-        inlinePrefCat.setTitle(R.string.inline_preferences);
-        root.addPreference(inlinePrefCat);
-        
-        // Toggle preference
-        CheckBoxPreference togglePref = new CheckBoxPreference(this);
-        togglePref.setKey("toggle_preference");
-        togglePref.setTitle(R.string.title_toggle_preference);
-        togglePref.setSummary(R.string.summary_toggle_preference);
-        inlinePrefCat.addPreference(togglePref);
-                
-        // Dialog based preferences
-        PreferenceCategory dialogBasedPrefCat = new PreferenceCategory(this);
-        dialogBasedPrefCat.setTitle(R.string.dialog_based_preferences);
-        root.addPreference(dialogBasedPrefCat);
-
-        // Edit text preference
-        EditTextPreference editTextPref = new EditTextPreference(this);
-        editTextPref.setDialogTitle(R.string.dialog_title_edittext_preference);
-        editTextPref.setKey("edittext_preference");
-        editTextPref.setTitle(R.string.title_edittext_preference);
-        editTextPref.setSummary(R.string.summary_edittext_preference);
-        dialogBasedPrefCat.addPreference(editTextPref);
-        
-        // List preference
-        ListPreference listPref = new ListPreference(this);
-        listPref.setEntries(R.array.entries_list_preference);
-        listPref.setEntryValues(R.array.entryvalues_list_preference);
-        listPref.setDialogTitle(R.string.dialog_title_list_preference);
-        listPref.setKey("list_preference");
-        listPref.setTitle(R.string.title_list_preference);
-        listPref.setSummary(R.string.summary_list_preference);
-        dialogBasedPrefCat.addPreference(listPref);
-        
-        // Launch preferences
-        PreferenceCategory launchPrefCat = new PreferenceCategory(this);
-        launchPrefCat.setTitle(R.string.launch_preferences);
-        root.addPreference(launchPrefCat);
-
-        /*
-         * The Preferences screenPref serves as a screen break (similar to page
-         * break in word processing). Like for other preference types, we assign
-         * a key here so that it is able to save and restore its instance state.
-         */
-        // Screen preference
-        PreferenceScreen screenPref = getPreferenceManager().createPreferenceScreen(this);
-        screenPref.setKey("screen_preference");
-        screenPref.setTitle(R.string.title_screen_preference);
-        screenPref.setSummary(R.string.summary_screen_preference);
-        launchPrefCat.addPreference(screenPref);
-        
-        /*
-         * You can add more preferences to screenPref that will be shown on the
-         * next screen.
-         */
-        
-        // Example of next screen toggle preference
-        CheckBoxPreference nextScreenCheckBoxPref = new CheckBoxPreference(this);
-        nextScreenCheckBoxPref.setKey("next_screen_toggle_preference");
-        nextScreenCheckBoxPref.setTitle(R.string.title_next_screen_toggle_preference);
-        nextScreenCheckBoxPref.setSummary(R.string.summary_next_screen_toggle_preference);
-        screenPref.addPreference(nextScreenCheckBoxPref);
-        
-        // Intent preference
-        PreferenceScreen intentPref = getPreferenceManager().createPreferenceScreen(this);
-        intentPref.setIntent(new Intent().setAction(Intent.ACTION_VIEW)
-                .setData(Uri.parse("http://www.android.com")));
-        intentPref.setTitle(R.string.title_intent_preference);
-        intentPref.setSummary(R.string.summary_intent_preference);
-        launchPrefCat.addPreference(intentPref);
-        
-        // Preference attributes
-        PreferenceCategory prefAttrsCat = new PreferenceCategory(this);
-        prefAttrsCat.setTitle(R.string.preference_attributes);
-        root.addPreference(prefAttrsCat);
-        
-        // Visual parent toggle preference
-        CheckBoxPreference parentCheckBoxPref = new CheckBoxPreference(this);
-        parentCheckBoxPref.setTitle(R.string.title_parent_preference);
-        parentCheckBoxPref.setSummary(R.string.summary_parent_preference);
-        prefAttrsCat.addPreference(parentCheckBoxPref);
-        
-        // Visual child toggle preference
-        // See res/values/attrs.xml for the <declare-styleable> that defines
-        // TogglePrefAttrs.
-        TypedArray a = obtainStyledAttributes(R.styleable.TogglePrefAttrs);
-        CheckBoxPreference childCheckBoxPref = new CheckBoxPreference(this);
-        childCheckBoxPref.setTitle(R.string.title_child_preference);
-        childCheckBoxPref.setSummary(R.string.summary_child_preference);
-        childCheckBoxPref.setLayoutResource(
-                a.getResourceId(R.styleable.TogglePrefAttrs_android_preferenceLayoutChild,
-                        0));
-        prefAttrsCat.addPreference(childCheckBoxPref);
-        a.recycle();
-        
-        return root;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromXml.java b/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromXml.java
deleted file mode 100644
index 23461c6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/PreferencesFromXml.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.preference.Preference;
-import android.preference.PreferenceActivity;
-
-public class PreferencesFromXml extends PreferenceActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Load the preferences from an XML resource
-        addPreferencesFromResource(R.xml.preferences);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ReceiveResult.java b/samples/ApiDemos/src/com/example/android/apis/app/ReceiveResult.java
deleted file mode 100644
index 4e248b9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ReceiveResult.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import java.util.Map;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.text.Editable;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.TextView;
-
-import java.util.Map;
-
-/**
- * Shows how an activity can send data to its launching activity when done.y.
- * <p>This can be used, for example, to implement a dialog alowing the user to
-pick an e-mail address or image -- the picking activity sends the selected
-data back to the originating activity when done.</p>
-
-<p>The example here is composed of two activities: ReceiveResult launches
-the picking activity and receives its results; SendResult allows the user
-to pick something and sends the selection back to its caller.  Implementing
-this functionality involves the
-{@link android.app.Activity#setResult setResult()} method for sending a
-result and
-{@link android.app.Activity#onActivityResult onActivityResult()} to
-receive it.</p>
-
-<h4>Demo</h4>
-App/Activity/Receive Result
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/ReceiveResult.java</td>
-            <td class="DescrColumn">Launches pick activity and receives its result</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/SendResult.java</td>
-            <td class="DescrColumn">Allows user to pick an option and sends it back to its caller</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">/res/any/layout/receive_result.xml</td>
-            <td class="DescrColumn">Defines contents of the ReceiveResult screen</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">/res/any/layout/send_result.xml</td>
-            <td class="DescrColumn">Defines contents of the SendResult screen</td>
-        </tr>
-</table>
-
- */
-public class ReceiveResult extends Activity {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/hello_world.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.receive_result);
-
-        // Retrieve the TextView widget that will display results.
-        mResults = (TextView)findViewById(R.id.results);
-
-        // This allows us to later extend the text buffer.
-        mResults.setText(mResults.getText(), TextView.BufferType.EDITABLE);
-
-        // Watch for button clicks.
-        Button getButton = (Button)findViewById(R.id.get);
-        getButton.setOnClickListener(mGetListener);
-    }
-
-    /**
-     * This method is called when the sending activity has finished, with the
-     * result it supplied.
-     * 
-     * @param requestCode The original request code as given to
-     *                    startActivity().
-     * @param resultCode From sending activity as per setResult().
-     * @param data From sending activity as per setResult().
-     */
-    @Override
-	protected void onActivityResult(int requestCode, int resultCode,
-		Intent data) {
-        // You can use the requestCode to select between multiple child
-        // activities you may have started.  Here there is only one thing
-        // we launch.
-        if (requestCode == GET_CODE) {
-
-            // We will be adding to our text.
-            Editable text = (Editable)mResults.getText();
-
-            // This is a standard resultCode that is sent back if the
-            // activity doesn't supply an explicit result.  It will also
-            // be returned if the activity failed to launch.
-            if (resultCode == RESULT_CANCELED) {
-                text.append("(cancelled)");
-
-            // Our protocol with the sending activity is that it will send
-            // text in 'data' as its result.
-            } else {
-                text.append("(okay ");
-                text.append(Integer.toString(resultCode));
-                text.append(") ");
-                if (data != null) {
-                    text.append(data.getAction());
-                }
-            }
-
-            text.append("\n");
-        }
-    }
-
-    // Definition of the one requestCode we use for receiving resuls.
-    static final private int GET_CODE = 0;
-
-    private OnClickListener mGetListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Start the activity whose result we want to retrieve.  The
-            // result will come back with request code GET_CODE.
-            Intent intent = new Intent(ReceiveResult.this, SendResult.class);
-            startActivityForResult(intent, GET_CODE);
-        }
-    };
-
-    private TextView mResults;
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RedirectEnter.java b/samples/ApiDemos/src/com/example/android/apis/app/RedirectEnter.java
deleted file mode 100644
index 3a3e6f2..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RedirectEnter.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * Entry into our redirection example, describing what will happen.
- */
-public class RedirectEnter extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.redirect_enter);
-
-        // Watch for button clicks.
-        Button goButton = (Button)findViewById(R.id.go);
-        goButton.setOnClickListener(mGoListener);
-    }
-
-    private OnClickListener mGoListener = new OnClickListener()
-    {
-        public void onClick(View v)
-        {
-            // Here we start up the main entry point of our redirection
-            // example.
-            Intent intent = new Intent(RedirectEnter.this, RedirectMain.class);
-            startActivity(intent);
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RedirectGetter.java b/samples/ApiDemos/src/com/example/android/apis/app/RedirectGetter.java
deleted file mode 100644
index 982317c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RedirectGetter.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.TextView;
-
-/**
- * Sub-activity that is executed by the redirection example when input is needed
- * from the user.
- */
-public class RedirectGetter extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.redirect_getter);
-
-        // Watch for button clicks.
-        Button applyButton = (Button)findViewById(R.id.apply);
-        applyButton.setOnClickListener(mApplyListener);
-
-        // The text being set.
-        mText = (TextView)findViewById(R.id.text);
-    }
-
-    private final boolean loadPrefs()
-    {
-        // Retrieve the current redirect values.
-        // NOTE: because this preference is shared between multiple
-        // activities, you must be careful about when you read or write
-        // it in order to keep from stepping on yourself.
-        SharedPreferences preferences = getSharedPreferences("RedirectData", 0);
-
-        mTextPref = preferences.getString("text", null);
-        if (mTextPref != null) {
-            mText.setText(mTextPref);
-            return true;
-        }
-
-        return false;
-    }
-
-    private OnClickListener mApplyListener = new OnClickListener()
-    {
-        public void onClick(View v)
-        {
-            SharedPreferences preferences = getSharedPreferences("RedirectData", 0);
-            SharedPreferences.Editor editor = preferences.edit();
-            editor.putString("text", mText.getText().toString());
-
-            if (editor.commit()) {
-                setResult(RESULT_OK);
-            }
-
-            finish();
-        }
-    };
-
-    private String mTextPref;
-    TextView mText;
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RedirectMain.java b/samples/ApiDemos/src/com/example/android/apis/app/RedirectMain.java
deleted file mode 100644
index 6d01ff0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RedirectMain.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.TextView;
-
-/**
- * Entry into our redirection example, describing what will happen.
- */
-public class RedirectMain extends Activity {
-    static final int INIT_TEXT_REQUEST = 0;
-    static final int NEW_TEXT_REQUEST = 1;
-
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.redirect_main);
-
-        // Watch for button clicks.
-        Button clearButton = (Button)findViewById(R.id.clear);
-        clearButton.setOnClickListener(mClearListener);
-        Button newButton = (Button)findViewById(R.id.newView);
-        newButton.setOnClickListener(mNewListener);
-
-        // Retrieve the current text preference.  If there is no text
-        // preference set, we need to get it from the user by invoking the
-        // activity that retrieves it.  To do this cleanly, we will
-        // temporarily hide our own activity so it is not displayed until the
-        // result is returned.
-        if (!loadPrefs()) {
-            Intent intent = new Intent(this, RedirectGetter.class);
-            startActivityForResult(intent, INIT_TEXT_REQUEST);
-        }
-    }
-
-    @Override
-	protected void onActivityResult(int requestCode, int resultCode,
-		Intent data) {
-        if (requestCode == INIT_TEXT_REQUEST) {
-
-            // If the request was cancelled, then we are cancelled as well.
-            if (resultCode == RESULT_CANCELED) {
-                finish();
-
-            // Otherwise, there now should be text...  reload the prefs,
-            // and show our UI.  (Optionally we could verify that the text
-            // is now set and exit if it isn't.)
-            } else {
-                loadPrefs();
-            }
-
-        } else if (requestCode == NEW_TEXT_REQUEST) {
-
-            // In this case we are just changing the text, so if it was
-            // cancelled then we can leave things as-is.
-            if (resultCode != RESULT_CANCELED) {
-                loadPrefs();
-            }
-
-        }
-    }
-
-    private final boolean loadPrefs() {
-        // Retrieve the current redirect values.
-        // NOTE: because this preference is shared between multiple
-        // activities, you must be careful about when you read or write
-        // it in order to keep from stepping on yourself.
-        SharedPreferences preferences = getSharedPreferences("RedirectData", 0);
-
-        mTextPref = preferences.getString("text", null);
-        if (mTextPref != null) {
-            TextView text = (TextView)findViewById(R.id.text);
-            text.setText(mTextPref);
-            return true;
-        }
-
-        return false;
-    }
-
-    private OnClickListener mClearListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Erase the preferences and exit!
-            SharedPreferences preferences = getSharedPreferences("RedirectData", 0);
-            preferences.edit().remove("text").commit();
-            finish();
-        }
-    };
-
-    private OnClickListener mNewListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Retrieve new text preferences.
-            Intent intent = new Intent(RedirectMain.this, RedirectGetter.class);
-            startActivityForResult(intent, NEW_TEXT_REQUEST);
-        }
-    };
-
-    private String mTextPref;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RemoteService.java b/samples/ApiDemos/src/com/example/android/apis/app/RemoteService.java
deleted file mode 100644
index c0debbc..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RemoteService.java
+++ /dev/null
@@ -1,185 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.RemoteException;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Message;
-import android.os.Process;
-import android.os.RemoteCallbackList;
-import android.widget.Toast;
-
-import java.util.HashMap;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * This is an example of implementing an application service that runs in a
- * different process than the application.  Because it can be in another
- * process, we must use IPC to interact with it.  The
- * {@link RemoteServiceController} and {@link RemoteServiceBinding} classes
- * show how to interact with the service.
- */
-public class RemoteService extends Service {
-    /**
-     * This is a list of callbacks that have been registered with the
-     * service.  Note that this is package scoped (instead of private) so
-     * that it can be accessed more efficiently from inner classes.
-     */
-    final RemoteCallbackList<IRemoteServiceCallback> mCallbacks
-            = new RemoteCallbackList<IRemoteServiceCallback>();
-    
-    int mValue = 0;
-    NotificationManager mNM;
-    
-    @Override
-    public void onCreate() {
-        mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
-
-        // Display a notification about us starting.
-        showNotification();
-        
-        // While this service is running, it will continually increment a
-        // number.  Send the first message that is used to perform the
-        // increment.
-        mHandler.sendEmptyMessage(REPORT_MSG);
-    }
-
-    @Override
-    public void onDestroy() {
-        // Cancel the persistent notification.
-        mNM.cancel(R.string.remote_service_started);
-
-        // Tell the user we stopped.
-        Toast.makeText(this, R.string.remote_service_stopped, Toast.LENGTH_SHORT).show();
-        
-        // Unregister all callbacks.
-        mCallbacks.kill();
-        
-        // Remove the next pending message to increment the counter, stopping
-        // the increment loop.
-        mHandler.removeMessages(REPORT_MSG);
-    }
-    
-// BEGIN_INCLUDE(exposing_a_service)
-    @Override
-    public IBinder onBind(Intent intent) {
-        // Select the interface to return.  If your service only implements
-        // a single interface, you can just return it here without checking
-        // the Intent.
-        if (IRemoteService.class.getName().equals(intent.getAction())) {
-            return mBinder;
-        }
-        if (ISecondary.class.getName().equals(intent.getAction())) {
-            return mSecondaryBinder;
-        }
-        return null;
-    }
-
-    /**
-     * The IRemoteInterface is defined through IDL
-     */
-    private final IRemoteService.Stub mBinder = new IRemoteService.Stub() {
-        public void registerCallback(IRemoteServiceCallback cb) {
-            if (cb != null) mCallbacks.register(cb);
-        }
-        public void unregisterCallback(IRemoteServiceCallback cb) {
-            if (cb != null) mCallbacks.unregister(cb);
-        }
-    };
-
-    /**
-     * A secondary interface to the service.
-     */
-    private final ISecondary.Stub mSecondaryBinder = new ISecondary.Stub() {
-        public int getPid() {
-            return Process.myPid();
-        }
-        public void basicTypes(int anInt, long aLong, boolean aBoolean,
-                float aFloat, double aDouble, String aString) {
-        }
-    };
-// END_INCLUDE(exposing_a_service)
-    
-    private static final int REPORT_MSG = 1;
-    
-    /**
-     * Our Handler used to execute operations on the main thread.  This is used
-     * to schedule increments of our value.
-     */
-    private final Handler mHandler = new Handler() {
-        @Override public void handleMessage(Message msg) {
-            switch (msg.what) {
-                
-                // It is time to bump the value!
-                case REPORT_MSG: {
-                    // Up it goes.
-                    int value = ++mValue;
-                    
-                    // Broadcast to all clients the new value.
-                    final int N = mCallbacks.beginBroadcast();
-                    for (int i=0; i<N; i++) {
-                        try {
-                            mCallbacks.getBroadcastItem(i).valueChanged(value);
-                        } catch (RemoteException e) {
-                            // The RemoteCallbackList will take care of removing
-                            // the dead object for us.
-                        }
-                    }
-                    mCallbacks.finishBroadcast();
-                    
-                    // Repeat every 1 second.
-                    sendMessageDelayed(obtainMessage(REPORT_MSG), 1*1000);
-                } break;
-                default:
-                    super.handleMessage(msg);
-            }
-        }
-    };
-
-    /**
-     * Show a notification while this service is running.
-     */
-    private void showNotification() {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(R.string.remote_service_started);
-
-        // Set the icon, scrolling text and timestamp
-        Notification notification = new Notification(R.drawable.stat_sample, text,
-                System.currentTimeMillis());
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, LocalServiceController.class), 0);
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.remote_service_label),
-                       text, contentIntent);
-
-        // Send the notification.
-        // We use a string id because it is a unique number.  We use it later to cancel.
-        mNM.notify(R.string.remote_service_started, notification);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceBinding.java b/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceBinding.java
deleted file mode 100644
index f9ad4e5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceBinding.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.content.ServiceConnection;
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Message;
-import android.os.Process;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.TextView;
-import android.widget.Toast;
-
-// BEGIN_INCLUDE(exposing_a_service)
-public class RemoteServiceBinding extends Activity {
-    /** The primary interface we will be calling on the service. */
-    IRemoteService mService = null;
-    /** Another interface we use on the service. */
-    ISecondary mSecondaryService = null;
-    
-    Button mKillButton;
-    TextView mCallbackText;
-
-    private boolean mIsBound;
-
-    /**
-     * Standard initialization of this activity.  Set up the UI, then wait
-     * for the user to poke it before doing anything.
-     */
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.remote_service_binding);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.bind);
-        button.setOnClickListener(mBindListener);
-        button = (Button)findViewById(R.id.unbind);
-        button.setOnClickListener(mUnbindListener);
-        mKillButton = (Button)findViewById(R.id.kill);
-        mKillButton.setOnClickListener(mKillListener);
-        mKillButton.setEnabled(false);
-        
-        mCallbackText = (TextView)findViewById(R.id.callback);
-        mCallbackText.setText("Not attached.");
-    }
-
-    /**
-     * Class for interacting with the main interface of the service.
-     */
-    private ServiceConnection mConnection = new ServiceConnection() {
-        public void onServiceConnected(ComponentName className,
-                IBinder service) {
-            // This is called when the connection with the service has been
-            // established, giving us the service object we can use to
-            // interact with the service.  We are communicating with our
-            // service through an IDL interface, so get a client-side
-            // representation of that from the raw service object.
-            mService = IRemoteService.Stub.asInterface(service);
-            mKillButton.setEnabled(true);
-            mCallbackText.setText("Attached.");
-
-            // We want to monitor the service for as long as we are
-            // connected to it.
-            try {
-                mService.registerCallback(mCallback);
-            } catch (RemoteException e) {
-                // In this case the service has crashed before we could even
-                // do anything with it; we can count on soon being
-                // disconnected (and then reconnected if it can be restarted)
-                // so there is no need to do anything here.
-            }
-            
-            // As part of the sample, tell the user what happened.
-            Toast.makeText(RemoteServiceBinding.this, R.string.remote_service_connected,
-                    Toast.LENGTH_SHORT).show();
-        }
-
-        public void onServiceDisconnected(ComponentName className) {
-            // This is called when the connection with the service has been
-            // unexpectedly disconnected -- that is, its process crashed.
-            mService = null;
-            mKillButton.setEnabled(false);
-            mCallbackText.setText("Disconnected.");
-
-            // As part of the sample, tell the user what happened.
-            Toast.makeText(RemoteServiceBinding.this, R.string.remote_service_disconnected,
-                    Toast.LENGTH_SHORT).show();
-        }
-    };
-
-    /**
-     * Class for interacting with the secondary interface of the service.
-     */
-    private ServiceConnection mSecondaryConnection = new ServiceConnection() {
-        public void onServiceConnected(ComponentName className,
-                IBinder service) {
-            // Connecting to a secondary interface is the same as any
-            // other interface.
-            mSecondaryService = ISecondary.Stub.asInterface(service);
-            mKillButton.setEnabled(true);
-        }
-
-        public void onServiceDisconnected(ComponentName className) {
-            mSecondaryService = null;
-            mKillButton.setEnabled(false);
-        }
-    };
-
-    private OnClickListener mBindListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Establish a couple connections with the service, binding
-            // by interface names.  This allows other applications to be
-            // installed that replace the remote service by implementing
-            // the same interface.
-            bindService(new Intent(IRemoteService.class.getName()),
-                    mConnection, Context.BIND_AUTO_CREATE);
-            bindService(new Intent(ISecondary.class.getName()),
-                    mSecondaryConnection, Context.BIND_AUTO_CREATE);
-            mIsBound = true;
-            mCallbackText.setText("Binding.");
-        }
-    };
-
-    private OnClickListener mUnbindListener = new OnClickListener() {
-        public void onClick(View v) {
-            if (mIsBound) {
-                // If we have received the service, and hence registered with
-                // it, then now is the time to unregister.
-                if (mService != null) {
-                    try {
-                        mService.unregisterCallback(mCallback);
-                    } catch (RemoteException e) {
-                        // There is nothing special we need to do if the service
-                        // has crashed.
-                    }
-                }
-                
-                // Detach our existing connection.
-                unbindService(mConnection);
-                unbindService(mSecondaryConnection);
-                mKillButton.setEnabled(false);
-                mIsBound = false;
-                mCallbackText.setText("Unbinding.");
-            }
-        }
-    };
-
-    private OnClickListener mKillListener = new OnClickListener() {
-        public void onClick(View v) {
-            // To kill the process hosting our service, we need to know its
-            // PID.  Conveniently our service has a call that will return
-            // to us that information.
-            if (mSecondaryService != null) {
-                try {
-                    int pid = mSecondaryService.getPid();
-                    // Note that, though this API allows us to request to
-                    // kill any process based on its PID, the kernel will
-                    // still impose standard restrictions on which PIDs you
-                    // are actually able to kill.  Typically this means only
-                    // the process running your application and any additional
-                    // processes created by that app as shown here; packages
-                    // sharing a common UID will also be able to kill each
-                    // other's processes.
-                    Process.killProcess(pid);
-                    mCallbackText.setText("Killed service process.");
-                } catch (RemoteException ex) {
-                    // Recover gracefully from the process hosting the
-                    // server dying.
-                    // Just for purposes of the sample, put up a notification.
-                    Toast.makeText(RemoteServiceBinding.this,
-                            R.string.remote_call_failed,
-                            Toast.LENGTH_SHORT).show();
-                }
-            }
-        }
-    };
-    
-    // ----------------------------------------------------------------------
-    // Code showing how to deal with callbacks.
-    // ----------------------------------------------------------------------
-    
-    /**
-     * This implementation is used to receive callbacks from the remote
-     * service.
-     */
-    private IRemoteServiceCallback mCallback = new IRemoteServiceCallback.Stub() {
-        /**
-         * This is called by the remote service regularly to tell us about
-         * new values.  Note that IPC calls are dispatched through a thread
-         * pool running in each process, so the code executing here will
-         * NOT be running in our main thread like most other things -- so,
-         * to update the UI, we need to use a Handler to hop over there.
-         */
-        public void valueChanged(int value) {
-            mHandler.sendMessage(mHandler.obtainMessage(BUMP_MSG, value, 0));
-        }
-    };
-    
-    private static final int BUMP_MSG = 1;
-    
-    private Handler mHandler = new Handler() {
-        @Override public void handleMessage(Message msg) {
-            switch (msg.what) {
-                case BUMP_MSG:
-                    mCallbackText.setText("Received from service: " + msg.arg1);
-                    break;
-                default:
-                    super.handleMessage(msg);
-            }
-        }
-        
-    };
-}
-// END_INCLUDE(exposing_a_service)
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceController.java b/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceController.java
deleted file mode 100644
index 681d411..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RemoteServiceController.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class RemoteServiceController extends Activity {
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.remote_service_controller);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.start);
-        button.setOnClickListener(mStartListener);
-        button = (Button)findViewById(R.id.stop);
-        button.setOnClickListener(mStopListener);
-    }
-
-    private OnClickListener mStartListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Make sure the service is started.  It will continue running
-            // until someone calls stopService().
-            // We use an action code here, instead of explictly supplying
-            // the component name, so that other packages can replace
-            // the service.
-            startService(new Intent(
-                    "com.example.android.apis.app.REMOTE_SERVICE"));
-        }
-    };
-
-    private OnClickListener mStopListener = new OnClickListener() {
-        public void onClick(View v) {
-            // Cancel a previous call to startService().  Note that the
-            // service will not actually stop at this point if there are
-            // still bound clients.
-            stopService(new Intent(
-                    "com.example.android.apis.app.REMOTE_SERVICE"));
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ReorderFour.java b/samples/ApiDemos/src/com/example/android/apis/app/ReorderFour.java
deleted file mode 100644
index cdff538..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ReorderFour.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class ReorderFour extends Activity {
-    @Override
-    protected void onCreate(Bundle savedState) {
-        super.onCreate(savedState);
-        
-        setContentView(R.layout.reorder_four);
-        
-        Button twoButton = (Button) findViewById(R.id.reorder_second_to_front);
-        twoButton.setOnClickListener(mClickListener);
-    }
-
-    private final OnClickListener mClickListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent = new Intent(ReorderFour.this, ReorderTwo.class);
-            intent.addFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT);
-            startActivity(intent);
-        }
-    };
-}
\ No newline at end of file
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ReorderOnLaunch.java b/samples/ApiDemos/src/com/example/android/apis/app/ReorderOnLaunch.java
deleted file mode 100644
index 5856184..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ReorderOnLaunch.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class ReorderOnLaunch extends Activity {
-    @Override
-    protected void onCreate(Bundle savedState) {
-        super.onCreate(savedState);
-        
-        setContentView(R.layout.reorder_on_launch);
-        
-        Button twoButton = (Button) findViewById(R.id.reorder_launch_two);
-        twoButton.setOnClickListener(mClickListener);
-    }
-
-    private final OnClickListener mClickListener = new OnClickListener() {
-        public void onClick(View v) {
-            startActivity(new Intent(ReorderOnLaunch.this, ReorderTwo.class));
-        }
-    };
-}
\ No newline at end of file
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ReorderThree.java b/samples/ApiDemos/src/com/example/android/apis/app/ReorderThree.java
deleted file mode 100644
index 7f725a6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ReorderThree.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class ReorderThree extends Activity {
-    @Override
-    protected void onCreate(Bundle savedState) {
-        super.onCreate(savedState);
-        
-        setContentView(R.layout.reorder_three);
-        
-        Button twoButton = (Button) findViewById(R.id.reorder_launch_four);
-        twoButton.setOnClickListener(mClickListener);
-    }
-
-    private final OnClickListener mClickListener = new OnClickListener() {
-        public void onClick(View v) {
-            startActivity(new Intent(ReorderThree.this, ReorderFour.class));
-        }
-    };
-}
\ No newline at end of file
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ReorderTwo.java b/samples/ApiDemos/src/com/example/android/apis/app/ReorderTwo.java
deleted file mode 100644
index a1521d0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ReorderTwo.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class ReorderTwo extends Activity {
-    @Override
-    protected void onCreate(Bundle savedState) {
-        super.onCreate(savedState);
-        
-        setContentView(R.layout.reorder_two);
-        
-        Button twoButton = (Button) findViewById(R.id.reorder_launch_three);
-        twoButton.setOnClickListener(mClickListener);
-    }
-
-    private final OnClickListener mClickListener = new OnClickListener() {
-        public void onClick(View v) {
-            startActivity(new Intent(ReorderTwo.this, ReorderThree.class));
-        }
-    };
-}
\ No newline at end of file
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/RepeatingAlarm.java b/samples/ApiDemos/src/com/example/android/apis/app/RepeatingAlarm.java
deleted file mode 100644
index 0027983..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/RepeatingAlarm.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.content.Context;
-import android.content.Intent;
-import android.content.BroadcastReceiver;
-import android.widget.Toast;
-
-/**
- * This is an example of implement an {@link BroadcastReceiver} for an alarm that
- * should occur once.
- */
-public class RepeatingAlarm extends BroadcastReceiver
-{
-    @Override
-    public void onReceive(Context context, Intent intent)
-    {
-        Toast.makeText(context, R.string.repeating_received, Toast.LENGTH_SHORT).show();
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/SaveRestoreState.java b/samples/ApiDemos/src/com/example/android/apis/app/SaveRestoreState.java
deleted file mode 100644
index bddedf3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/SaveRestoreState.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.EditText;
-import android.widget.TextView;
-
-/**
- * <p>Demonstrates required behavior of saving and restoring dynamic activity
- * state, so that an activity will restart with the correct state if it is
- * stopped by the system.</p>
- *
- * <p>In general, any activity that has been paused may be stopped by the system
- * at any time if it needs more resources for the currently running activity.
- * To handle this, before being paused the
- * {@link android.app.Activity#onSaveInstanceState onSaveInstanceState()} method is called before
- * an activity is paused, allowing it to supply its current state.  If that
- * activity then needs to be stopped, upon restarting it will receive its
- * last saved state in
- * {@link android.app.Activity#onCreate}.</p>
- * <p>In this example we are currently saving and restoring the state of the
- * top text editor, but not of the bottom text editor.  You can see the difference
- * by editing the two text fields, then going to a couple different
- * applications while the demo is running and then returning back to it.  The
- * system takes care of saving a view's state as long as an id has been
- * assigned to the view, so we assign an ID to the view being saved but not
- * one to the view that isn't being saved.</p>
- * <h4>Demo</h4>
- * App/Activity/Save &amp; Restore State
- * <h4>Source files</h4>
- * <table class="LinkTable">
-        <tr>
-            <td class="LinkColumn">src/com.example.android.apis/app/SaveRestoreState.java</td>
-            <td class="DescrColumn">The Save/Restore Screen implementation</td>
-        </tr>
-        <tr>
-            <td class="LinkColumn">/res/any/layout/save_restore_state.xml</td>
-            <td class="DescrColumn">Defines contents of the screen</td>
-        </tr>
-</table>
- */
-public class SaveRestoreState extends Activity
-{
-    /**
-     * Initialization of the Activity after it is first created.  Here we use
-     * {@link android.app.Activity#setContentView setContentView()} to set up
-     * the Activity's content, and retrieve the EditText widget whose state we
-     * will save/restore.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/save_restore_state.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.save_restore_state);
-
-        // Set message to be appropriate for this screen.
-        ((TextView)findViewById(R.id.msg)).setText(R.string.save_restore_msg);
-    }
-
-    /**
-     * Retrieve the text that is currently in the "saved" editor.
-     */
-    CharSequence getSavedText() {
-        return ((EditText)findViewById(R.id.saved)).getText();
-    }
-
-    /**
-     * Change the text that is currently in the "saved" editor.
-     */
-    void setSavedText(CharSequence text) {
-        ((EditText)findViewById(R.id.saved)).setText(text);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/SearchInvoke.java b/samples/ApiDemos/src/com/example/android/apis/app/SearchInvoke.java
deleted file mode 100644
index a8d350c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/SearchInvoke.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.AlertDialog;
-import android.app.SearchManager;
-import android.os.Bundle;
-import android.provider.SearchRecentSuggestions;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.AdapterView;
-import android.widget.ArrayAdapter;
-import android.widget.Button;
-import android.widget.EditText;
-import android.widget.Spinner;
-import android.widget.AdapterView.OnItemSelectedListener;
-
-public class SearchInvoke extends Activity
-{  
-        // UI elements
-    Button mStartSearch;
-    Spinner mMenuMode;
-    EditText mQueryPrefill;
-    EditText mQueryAppData;
-    
-        // Menu mode spinner choices
-        // This list must match the list found in samples/ApiDemos/res/values/arrays.xml
-    final static int MENUMODE_SEARCH_KEY = 0;
-    final static int MENUMODE_MENU_ITEM = 1;
-    final static int MENUMODE_TYPE_TO_SEARCH = 2;
-    final static int MENUMODE_DISABLED = 3;
-    
-    /** 
-     * Called with the activity is first created.
-     * 
-     *  We aren't doing anything special in this implementation, other than
-     *  the usual activity setup code. 
-     */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.search_invoke);
-        
-        // Get display items for later interaction
-        mStartSearch = (Button) findViewById(R.id.btn_start_search);
-        mMenuMode = (Spinner) findViewById(R.id.spinner_menu_mode);
-        mQueryPrefill = (EditText) findViewById(R.id.txt_query_prefill);
-        mQueryAppData = (EditText) findViewById(R.id.txt_query_appdata);
-        
-        // Populate items
-        ArrayAdapter<CharSequence> adapter = ArrayAdapter.createFromResource(
-                            this, R.array.search_menuModes, android.R.layout.simple_spinner_item);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        mMenuMode.setAdapter(adapter);
-        
-        // Create listener for the menu mode dropdown.  We use this to demonstrate control
-        // of the default keys handler in every Activity.  More typically, you will simply set
-        // the default key mode in your activity's onCreate() handler.
-        mMenuMode.setOnItemSelectedListener(
-            new OnItemSelectedListener() {
-                public void onItemSelected(
-                        AdapterView<?> parent, View view, int position, long id) {
-                    if (position == MENUMODE_TYPE_TO_SEARCH) {
-                        setDefaultKeyMode(DEFAULT_KEYS_SEARCH_LOCAL);
-                    } else {
-                        setDefaultKeyMode(DEFAULT_KEYS_DISABLE);
-                    }
-                }
-
-                public void onNothingSelected(AdapterView<?> parent) {
-                    setDefaultKeyMode(DEFAULT_KEYS_DISABLE);
-                }
-            });
-        
-        // Attach actions to buttons
-        mStartSearch.setOnClickListener(
-            new OnClickListener() {
-                public void onClick(View v) {
-                    onSearchRequested();
-                }
-            });
-    }
-    
-    /** 
-     * Called when your activity's options menu needs to be updated. 
-     */
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-        MenuItem item;
-        
-            // first, get rid of our menus (if any)
-        menu.removeItem(0);
-        menu.removeItem(1);
-        
-            // next, add back item(s) based on current menu mode
-        switch (mMenuMode.getSelectedItemPosition())
-        {
-        case MENUMODE_SEARCH_KEY:
-            item = menu.add( 0, 0, 0, "(Search Key)");
-            break;
-            
-        case MENUMODE_MENU_ITEM:
-            item = menu.add( 0, 0, 0, "Search");
-            item.setAlphabeticShortcut(SearchManager.MENU_KEY);
-            break;
-            
-        case MENUMODE_TYPE_TO_SEARCH:
-            item = menu.add( 0, 0, 0, "(Type-To-Search)");
-            break;
-            
-        case MENUMODE_DISABLED:
-            item = menu.add( 0, 0, 0, "(Disabled)");
-            break;
-        }
-        
-        item = menu.add(0, 1, 0, "Clear History");
-        return true;
-    }
-    
-    /** Handle the menu item selections */
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-        case 0:
-            switch (mMenuMode.getSelectedItemPosition()) {
-            case MENUMODE_SEARCH_KEY:
-                new AlertDialog.Builder(this)
-                    .setMessage("To invoke search, dismiss this dialog and press the search key" +
-                                " (F5 on the simulator).")
-                    .setPositiveButton("OK", null)
-                    .show();
-                break;
-                
-            case MENUMODE_MENU_ITEM:
-                onSearchRequested();
-                break;
-                
-            case MENUMODE_TYPE_TO_SEARCH:
-                new AlertDialog.Builder(this)
-                    .setMessage("To invoke search, dismiss this dialog and start typing.")
-                    .setPositiveButton("OK", null)
-                    .show();
-                break;
-                
-            case MENUMODE_DISABLED:
-                new AlertDialog.Builder(this)
-                    .setMessage("You have disabled search.")
-                    .setPositiveButton("OK", null)
-                    .show();
-                break;
-            }
-            break;
-        case 1:
-            clearSearchHistory();
-            break;
-        }
-    
-         return super.onOptionsItemSelected(item);
-    }
-    
-    /**
-     * This hook is called when the user signals the desire to start a search.
-     * 
-     * By overriding this hook we can insert local or context-specific data.
-     * 
-     * @return Returns true if search launched, false if activity blocks it
-     */
-    @Override
-    public boolean onSearchRequested() {
-        // If your application absolutely must disable search, do it here.
-        if (mMenuMode.getSelectedItemPosition() == MENUMODE_DISABLED) {
-            return false;
-        }
-        
-        // It's possible to prefill the query string before launching the search
-        // UI.  For this demo, we simply copy it from the user input field.
-        // For most applications, you can simply pass null to startSearch() to
-        // open the UI with an empty query string.
-        final String queryPrefill = mQueryPrefill.getText().toString();
-        
-        // Next, set up a bundle to send context-specific search data (if any)
-        // The bundle can contain any number of elements, using any number of keys;
-        // For this Api Demo we copy a string from the user input field, and store
-        // it in the bundle as a string with the key "demo_key".
-        // For most applications, you can simply pass null to startSearch().
-        Bundle appDataBundle = null;
-        final String queryAppDataString = mQueryAppData.getText().toString();
-        if (queryAppDataString != null) {
-            appDataBundle = new Bundle();
-            appDataBundle.putString("demo_key", queryAppDataString);
-        }
-        
-        // Now call the Activity member function that invokes the Search Manager UI.
-        startSearch(queryPrefill, false, appDataBundle, false); 
-        
-        // Returning true indicates that we did launch the search, instead of blocking it.
-        return true;
-    }
-    
-    /**
-     * Any application that implements search suggestions based on previous actions (such as
-     * recent queries, page/items viewed, etc.) should provide a way for the user to clear the
-     * history.  This gives the user a measure of privacy, if they do not wish for their recent
-     * searches to be replayed by other users of the device (via suggestions).
-     * 
-     * This example shows how to clear the search history for apps that use 
-     * android.provider.SearchRecentSuggestions.  If you have developed a custom suggestions
-     * provider, you'll need to provide a similar API for clearing history.
-     * 
-     * In this sample app we call this method from a "Clear History" menu item.  You could also 
-     * implement the UI in your preferences, or any other logical place in your UI.
-     */
-    private void clearSearchHistory() {
-        SearchRecentSuggestions suggestions = new SearchRecentSuggestions(this, 
-                SearchSuggestionSampleProvider.AUTHORITY, SearchSuggestionSampleProvider.MODE);
-        suggestions.clearHistory();
-    }
-    
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/SearchQueryResults.java b/samples/ApiDemos/src/com/example/android/apis/app/SearchQueryResults.java
deleted file mode 100644
index 668ad57..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/SearchQueryResults.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.SearchManager;
-import android.content.Intent;
-import android.os.Bundle;
-import android.provider.SearchRecentSuggestions;
-import android.widget.TextView;
-
-public class SearchQueryResults extends Activity
-{  
-        // UI elements
-    TextView mQueryText;
-    TextView mAppDataText;
-    TextView mDeliveredByText;
-    
-    /** Called with the activity is first created.
-    * 
-    *  After the typical activity setup code, we check to see if we were launched
-    *  with the ACTION_SEARCH intent, and if so, we handle it.
-    */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.search_query_results);
-        
-        // Get active display items for later updates
-        mQueryText = (TextView) findViewById(R.id.txt_query);
-        mAppDataText = (TextView) findViewById(R.id.txt_appdata);
-        mDeliveredByText = (TextView) findViewById(R.id.txt_deliveredby);
-        
-        // get and process search query here
-        final Intent queryIntent = getIntent();
-        final String queryAction = queryIntent.getAction();
-        if (Intent.ACTION_SEARCH.equals(queryAction)) {
-            doSearchQuery(queryIntent, "onCreate()");
-        }
-        else {
-            mDeliveredByText.setText("onCreate(), but no ACTION_SEARCH intent");
-        }
-    }
-    
-    /** 
-     * Called when new intent is delivered.
-     *
-     * This is where we check the incoming intent for a query string.
-     * 
-     * @param newIntent The intent used to restart this activity
-     */
-    @Override
-    public void onNewIntent(final Intent newIntent) {
-        super.onNewIntent(newIntent);
-        
-        // get and process search query here
-        final Intent queryIntent = getIntent();
-        final String queryAction = queryIntent.getAction();
-        if (Intent.ACTION_SEARCH.equals(queryAction)) {
-            doSearchQuery(queryIntent, "onNewIntent()");
-        }
-        else {
-            mDeliveredByText.setText("onNewIntent(), but no ACTION_SEARCH intent");
-        }
-    }
-    
-    /**
-     * Generic search handler.
-     * 
-     * In a "real" application, you would use the query string to select results from
-     * your data source, and present a list of those results to the user.
-     */
-    private void doSearchQuery(final Intent queryIntent, final String entryPoint) {
-        
-        // The search query is provided as an "extra" string in the query intent
-        final String queryString = queryIntent.getStringExtra(SearchManager.QUERY);
-        mQueryText.setText(queryString);
-        
-        // Record the query string in the recent queries suggestions provider.
-        SearchRecentSuggestions suggestions = new SearchRecentSuggestions(this, 
-                SearchSuggestionSampleProvider.AUTHORITY, SearchSuggestionSampleProvider.MODE);
-        suggestions.saveRecentQuery(queryString, null);
-        
-        // If your application provides context data for its searches, 
-        // you will receive it as an "extra" bundle in the query intent. 
-        // The bundle can contain any number of elements, using any number of keys;
-        // For this Api Demo we're just using a single string, stored using "demo key".
-        final Bundle appData = queryIntent.getBundleExtra(SearchManager.APP_DATA);
-        if (appData == null) {
-            mAppDataText.setText("<no app data bundle>");
-        }
-        if (appData != null) {
-            String testStr = appData.getString("demo_key");
-            mAppDataText.setText((testStr == null) ? "<no app data>" : testStr);
-        }
-        
-        // Report the method by which we were called.
-        mDeliveredByText.setText(entryPoint);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/SearchSuggestionSampleProvider.java b/samples/ApiDemos/src/com/example/android/apis/app/SearchSuggestionSampleProvider.java
deleted file mode 100644
index 4baccd0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/SearchSuggestionSampleProvider.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.content.SearchRecentSuggestionsProvider;
-
-/**
- * To create a search suggestions provider using the built-in recent queries mode, 
- * simply extend SearchRecentSuggestionsProvider as shown here, and configure with
- * a unique authority and the mode you with to use.  For more information, see
- * {@link android.content.SearchRecentSuggestionsProvider}.
- */
-public class SearchSuggestionSampleProvider extends SearchRecentSuggestionsProvider {
-    
-    /**
-     * This is the provider authority identifier.  The same string must appear in your
-     * Manifest file, and any time you instantiate a 
-     * {@link android.provider.SearchRecentSuggestions} helper class. 
-     */
-    final static String AUTHORITY = "com.example.android.apis.SuggestionProvider";
-    /**
-     * These flags determine the operating mode of the suggestions provider.  This value should 
-     * not change from run to run, because when it does change, your suggestions database may 
-     * be wiped.
-     */
-    final static int MODE = DATABASE_MODE_QUERIES;
-    
-    /**
-     * The main job of the constructor is to call {@link #setupSuggestions(String, int)} with the
-     * appropriate configuration values.
-     */
-    public SearchSuggestionSampleProvider() {
-        super();
-        setupSuggestions(AUTHORITY, MODE);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/SendResult.java b/samples/ApiDemos/src/com/example/android/apis/app/SendResult.java
deleted file mode 100644
index 1171eea..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/SendResult.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * Example of receiving a result from another activity.
- */
-public class SendResult extends Activity
-{
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/hello_world.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.send_result);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.corky);
-        button.setOnClickListener(mCorkyListener);
-        button = (Button)findViewById(R.id.violet);
-        button.setOnClickListener(mVioletListener);
-    }
-
-    private OnClickListener mCorkyListener = new OnClickListener()
-    {
-        public void onClick(View v)
-        {
-            // To send a result, simply call setResult() before your
-            // activity is finished.
-            setResult(RESULT_OK, (new Intent()).setAction("Corky!"));
-            finish();
-        }
-    };
-
-    private OnClickListener mVioletListener = new OnClickListener()
-    {
-        public void onClick(View v)
-        {
-            // To send a result, simply call setResult() before your
-            // activity is finished.
-            setResult(RESULT_OK, (new Intent()).setAction("Violet!"));
-            finish();
-        }
-    };
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArguments.java b/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArguments.java
deleted file mode 100644
index 5e16158..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArguments.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.HandlerThread;
-import android.os.IBinder;
-import android.os.Looper;
-import android.os.Message;
-import android.util.Log;
-import android.widget.Toast;
-
-import com.example.android.apis.R;
-
-/**
- * This is an example of implementing an application service that runs locally
- * in the same process as the application.  The {@link ServiceStartArgumentsController}
- * class shows how to interact with the service. 
- *
- * <p>Notice the use of the {@link NotificationManager} when interesting things
- * happen in the service.  This is generally how background services should
- * interact with the user, rather than doing something more disruptive such as
- * calling startActivity().
- */
-public class ServiceStartArguments extends Service
-{
-    private NotificationManager mNM;
-    private Intent mInvokeIntent;
-    private volatile Looper mServiceLooper;
-    private volatile ServiceHandler mServiceHandler;
-    
-    private final class ServiceHandler extends Handler {
-        public ServiceHandler(Looper looper) {
-            super(looper);
-        }
-        
-        @Override
-        public void handleMessage(Message msg)
-        {
-            Bundle arguments = (Bundle)msg.obj;
-            String txt = getResources()
-                    .getString(R.string.service_arguments_started);
-            txt = txt + arguments.getString("name");
-        
-            Log.i("ServiceStartArguments", "Message: " + msg + ", " + txt);
-        
-            showNotification();
-        
-        // Normally we would do some work here...  for our sample, we will
-        // just sleep for 10 seconds.
-            long endTime = System.currentTimeMillis() + 5*1000;
-            while (System.currentTimeMillis() < endTime) {
-                synchronized (this) {
-                    try {
-                        wait(endTime - System.currentTimeMillis());
-                    } catch (Exception e) {
-                    }
-                }
-            }
-        
-            Log.i("ServiceStartArguments", "Done with #" + msg.arg1);
-            stopSelf(msg.arg1);
-        }
-
-    };
-    
-    @Override
-    public void onCreate() {
-        mNM = (NotificationManager)getSystemService(NOTIFICATION_SERVICE);
-
-        // This is who should be launched if the user selects our persistent
-        // notification.
-        mInvokeIntent = new Intent(this, ServiceStartArgumentsController.class);
-
-        // Start up the thread running the service.  Note that we create a
-        // separate thread because the service normally runs in the process's
-        // main thread, which we don't want to block.
-        HandlerThread thread = new HandlerThread("ServiceStartArguments");
-        thread.start();
-        
-        mServiceLooper = thread.getLooper();
-        mServiceHandler = new ServiceHandler(mServiceLooper);
-    }
-
-    @Override
-    public void onStart(Intent intent, int startId) {
-        Log.i("ServiceStartArguments",
-                "Starting #" + startId + ": " + intent.getExtras());
-        Message msg = mServiceHandler.obtainMessage();
-        msg.arg1 = startId;
-        msg.obj = intent.getExtras();
-        mServiceHandler.sendMessage(msg);
-        Log.i("ServiceStartArguments", "Sending: " + msg);
-    }
-
-    @Override
-    public void onDestroy() {
-        mServiceLooper.quit();
-
-        // Cancel the persistent notification.
-        mNM.cancel(R.string.service_arguments_started);
-
-        // Tell the user we stopped.
-        Toast.makeText(ServiceStartArguments.this, R.string.service_arguments_stopped,
-                Toast.LENGTH_SHORT).show();
-    }
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        return null;
-    }
-
-    /**
-     * Show a notification while this service is running.
-     */
-    private void showNotification() {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(R.string.service_arguments_started);
-
-        // Set the icon, scrolling text and timestamp
-        Notification notification = new Notification(R.drawable.stat_sample, text,
-                System.currentTimeMillis());
-
-        // The PendingIntent to launch our activity if the user selects this notification
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, AlarmService.class), 0);
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.service_start_arguments_label),
-                       text, contentIntent);
-
-        // Send the notification.
-        // We use a string id because it is a unique number.  We use it later to cancel.
-        mNM.notify(R.string.service_arguments_started, notification);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArgumentsController.java b/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArgumentsController.java
deleted file mode 100644
index 2c53ff4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/ServiceStartArgumentsController.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-import com.example.android.apis.R;
-
-import java.util.HashMap;
-
-/**
- * Example of explicitly starting the {@link ServiceStartArguments}.
- */
-public class ServiceStartArgumentsController extends Activity {
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.service_start_arguments_controller);
-
-        // Watch for button clicks.
-        Button button = (Button)findViewById(R.id.start1);
-        button.setOnClickListener(mStart1Listener);
-        button = (Button)findViewById(R.id.start2);
-        button.setOnClickListener(mStart2Listener);
-        button = (Button)findViewById(R.id.start3);
-        button.setOnClickListener(mStart3Listener);
-    }
-
-    private OnClickListener mStart1Listener = new OnClickListener() {
-        public void onClick(View v) {
-            startService(new Intent(ServiceStartArgumentsController.this,
-                    ServiceStartArguments.class).putExtra("name", "One"));
-        }
-    };
-
-    private OnClickListener mStart2Listener = new OnClickListener() {
-        public void onClick(View v) {
-            startService(new Intent(ServiceStartArgumentsController.this,
-                    ServiceStartArguments.class).putExtra("name", "Two"));
-        }
-    };
-
-    private OnClickListener mStart3Listener = new OnClickListener() {
-        public void onClick(View v) {
-            startService(new Intent(ServiceStartArgumentsController.this,
-                    ServiceStartArguments.class).putExtra("name", "Three"));
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/StatusBarNotifications.java b/samples/ApiDemos/src/com/example/android/apis/app/StatusBarNotifications.java
deleted file mode 100644
index 97f6199..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/StatusBarNotifications.java
+++ /dev/null
@@ -1,238 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-import android.widget.RemoteViews;
-
-/**
- * Demonstrates adding notifications to the status bar
- */
-public class StatusBarNotifications extends Activity {
-
-    private NotificationManager mNotificationManager;
-
-    // Use our layout id for a unique identifier
-    private static int MOOD_NOTIFICATIONS = R.layout.status_bar_notifications;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.status_bar_notifications);
-
-        Button button;
-
-        // Get the notification manager serivce.
-        mNotificationManager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
-
-        button = (Button) findViewById(R.id.happy);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_happy, R.string.status_bar_notifications_happy_message,
-                        false);
-            }
-        });
-
-        button = (Button) findViewById(R.id.neutral);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_neutral, R.string.status_bar_notifications_ok_message,
-                        false);
-            }
-        });
-
-        button = (Button) findViewById(R.id.sad);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_sad, R.string.status_bar_notifications_sad_message, false);
-            }
-        });
-
-        button = (Button) findViewById(R.id.happyMarquee);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_happy, R.string.status_bar_notifications_happy_message,
-                        true);
-            }
-        });
-
-        button = (Button) findViewById(R.id.neutralMarquee);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_neutral, R.string.status_bar_notifications_ok_message, true);
-            }
-        });
-
-        button = (Button) findViewById(R.id.sadMarquee);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMood(R.drawable.stat_sad, R.string.status_bar_notifications_sad_message, true);
-            }
-        });
-
-        button = (Button) findViewById(R.id.happyViews);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMoodView(R.drawable.stat_happy, R.string.status_bar_notifications_happy_message);
-            }
-        });
-
-        button = (Button) findViewById(R.id.neutralViews);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMoodView(R.drawable.stat_neutral, R.string.status_bar_notifications_ok_message);
-            }
-        });
-
-        button = (Button) findViewById(R.id.sadViews);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setMoodView(R.drawable.stat_sad, R.string.status_bar_notifications_sad_message);
-            }
-        });
-        
-        button = (Button) findViewById(R.id.defaultSound);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setDefault(Notification.DEFAULT_SOUND);
-            }
-        });
-        
-        button = (Button) findViewById(R.id.defaultVibrate);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setDefault(Notification.DEFAULT_VIBRATE);
-            }
-        });
-        
-        button = (Button) findViewById(R.id.defaultAll);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                setDefault(Notification.DEFAULT_ALL);
-            }
-        });
-        
-        button = (Button) findViewById(R.id.clear);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mNotificationManager.cancel(R.layout.status_bar_notifications);
-            }
-        });
-    }
-
-    private PendingIntent makeMoodIntent(int moodId) {
-        // The PendingIntent to launch our activity if the user selects this
-        // notification.  Note the use of FLAG_UPDATE_CURRENT so that if there
-        // is already an active matching pending intent, we will update its
-        // extras to be the ones passed in here.
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, NotificationDisplay.class)
-                        .setFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
-                        .putExtra("moodimg", moodId),
-                PendingIntent.FLAG_UPDATE_CURRENT);
-        return contentIntent;
-    }
-    
-    private void setMood(int moodId, int textId, boolean showTicker) {
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(textId);
-
-        // choose the ticker text
-        String tickerText = showTicker ? getString(textId) : null;
-
-        // Set the icon, scrolling text and timestamp
-        Notification notification = new Notification(moodId, tickerText,
-                System.currentTimeMillis());
-
-        // Set the info for the views that show in the notification panel.
-        notification.setLatestEventInfo(this, getText(R.string.status_bar_notifications_mood_title),
-                       text, makeMoodIntent(moodId));
-
-        // Send the notification.
-        // We use a layout id because it is a unique number.  We use it later to cancel.
-        mNotificationManager.notify(R.layout.status_bar_notifications, notification);
-    }
-
-    private void setMoodView(int moodId, int textId) {
-        // Instead of the normal constructor, we're going to use the one with no args and fill
-        // in all of the data ourselves.  The normal one uses the default layout for notifications.
-        // You probably want that in most cases, but if you want to do something custom, you
-        // can set the contentView field to your own RemoteViews object.
-        Notification notif = new Notification();
-
-        // This is who should be launched if the user selects our notification.
-        notif.contentIntent = makeMoodIntent(moodId);
-
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(textId);
-        notif.tickerText = text;
-
-        // the icon for the status bar
-        notif.icon = moodId;
-
-        // our custom view
-        RemoteViews contentView = new RemoteViews(getPackageName(), R.layout.status_bar_balloon);
-        contentView.setTextViewText(R.id.text, text);
-        contentView.setImageViewResource(R.id.icon, moodId);
-        notif.contentView = contentView;
-
-        // we use a string id because is a unique number.  we use it later to cancel the
-        // notification
-        mNotificationManager.notify(R.layout.status_bar_notifications, notif);
-    }
-    
-    private void setDefault(int defaults) {
-        
-        // This method sets the defaults on the notification before posting it.
-        
-        // This is who should be launched if the user selects our notification.
-        PendingIntent contentIntent = PendingIntent.getActivity(this, 0,
-                new Intent(this, StatusBarNotifications.class), 0);
-
-        // In this sample, we'll use the same text for the ticker and the expanded notification
-        CharSequence text = getText(R.string.status_bar_notifications_happy_message);
-
-        final Notification notification = new Notification(
-                R.drawable.stat_happy,       // the icon for the status bar
-                text,                        // the text to display in the ticker
-                System.currentTimeMillis()); // the timestamp for the notification
-
-        notification.setLatestEventInfo(
-                this,                        // the context to use
-                getText(R.string.status_bar_notifications_mood_title),
-                                             // the title for the notification
-                text,                        // the details to display in the notification
-                contentIntent);              // the contentIntent (see above)
-
-        notification.defaults = defaults;
-        
-        mNotificationManager.notify(
-                   R.layout.status_bar_notifications, // we use a string id because it is a unique
-                                                      // number.  we use it later to cancel the
-                   notification);                     // notification
-    }    
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/TranslucentActivity.java b/samples/ApiDemos/src/com/example/android/apis/app/TranslucentActivity.java
deleted file mode 100644
index 522fe13..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/TranslucentActivity.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-/**
- * <h3>Translucent Activity</h3>
- * 
- * <p>This demonstrates the how to write an activity that is translucent,
- * allowing windows underneath to show through.</p>
- */
-public class TranslucentActivity extends Activity {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-        
-        // See assets/res/any/layout/translucent_background.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.translucent_background);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/TranslucentBlurActivity.java b/samples/ApiDemos/src/com/example/android/apis/app/TranslucentBlurActivity.java
deleted file mode 100644
index dd88227..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/TranslucentBlurActivity.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.WindowManager;
-
-
-/**
- * <h3>Fancy Blur Activity</h3>
- * 
- * <p>This demonstrates the how to write an activity that is translucent,
- * allowing windows underneath to show through, with a fancy blur
- * compositing effect.</p>
- */
-public class TranslucentBlurActivity extends Activity {
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-    protected void onCreate(Bundle icicle) {
-        // Be sure to call the super class.
-        super.onCreate(icicle);
-
-        // Have the system blur any windows behind this one.
-        getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND,
-                WindowManager.LayoutParams.FLAG_BLUR_BEHIND);
-        
-        // See assets/res/any/layout/translucent_background.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.translucent_background);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/VoiceRecognition.java b/samples/ApiDemos/src/com/example/android/apis/app/VoiceRecognition.java
deleted file mode 100644
index a784e15..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/VoiceRecognition.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/* 
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.ArrayAdapter;
-import android.widget.Button;
-import android.widget.ListView;
-
-import com.example.android.apis.R;
-
-import java.util.ArrayList;
-
-/**
- * Sample code that invokes the speech recognition intent API.
- */
-public class VoiceRecognition extends Activity implements OnClickListener {
-    
-    private static final int VOICE_RECOGNITION_REQUEST_CODE = 1234;
-    
-    private ListView mList;
-
-    /**
-     * Called with the activity is first created.
-     */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.voice_recognition);
-
-        // Get display items for later interaction
-        Button speakButton = (Button) findViewById(R.id.btn_speak);
-        
-        mList = (ListView) findViewById(R.id.list);
-
-        // Attach actions to buttons
-        speakButton.setOnClickListener(this);
-    }
-
-    /**
-     * Handle the click on the start recognition button.
-     */
-    public void onClick(View v) {
-        if (v.getId() == R.id.btn_speak) {
-            startVoiceRecognitionActivity();
-        }
-    }
-
-    /**
-     * Fire an intent to start the speech recognition activity.
-     */
-    private void startVoiceRecognitionActivity() {
-        //TODO Get these values from constants
-        Intent intent = new Intent("android.speech.action.RECOGNIZE_SPEECH");
-        intent.putExtra("language_model", "free_form");
-        intent.putExtra("prompt", "Speech recognition demo");
-        startActivityForResult(intent, VOICE_RECOGNITION_REQUEST_CODE);
-    }
-
-    /**
-     * Handle the results from the recognition activity.
-     */
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
-        if (requestCode == VOICE_RECOGNITION_REQUEST_CODE && resultCode == RESULT_OK) {
-            //TODO get the value from a constant
-            ArrayList<String>matches = data.getStringArrayListExtra("results");
-            mList.setAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1,
-                    matches));
-        }
-
-        super.onActivityResult(requestCode, resultCode, data);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/_index.html b/samples/ApiDemos/src/com/example/android/apis/app/_index.html
deleted file mode 100644
index 8a768bb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/_index.html
+++ /dev/null
@@ -1,145 +0,0 @@
-
-<h3>Activity</h3>
-<dl>
-  <dt><a href="HelloWorld.html">Hello World</a></dt>
-  <dd>Demonstrates a basic screen activity.
-  <dl>
-  <dt>Code:
-  <dd> <a href="HelloWorld.html">HelloWorld.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/hello_world.html">
-  hello_world.xml</a>
-  </dl>
-  </dd>
-  <dt><a href="SaveRestoreState.html">Save &amp; Restore State</a></dt>
-  <dd>Demonstrates how an activity should save state when it is paused.</dd>
-
-  <dt><a href="PersistentState.html">Persistent State</a></dt>
-  <dd>Demonstrates how you can save and restore preferences, which are stored
-  even after the user closes the application. </dd>
-
-  <dt><a href="ReceiveResult.html">Receive Result</a></dt>
-  <dd>Demonstrates how an activity screen can return a result to the
-  activity that opened it. </dd>
-
-  <dt><a href="Forwarding.html">Forwarding</a></dt>
-  <dd>Demonstrates opening a new activity and removing the current activity
-  from the history stack, so that when the user later presses BACK they will
-  not see the intermediate activity.</dd>
-
-  <dt><a href="RedirectEnter.html">Redirection</a></dt>
-  <dd>Demonstrates how to save data to preferences and use it to determine
-  which activity to open next.</dd>
-
-  <dt><a href="TranslucentActivity.html">Translucent</a></dt>
-  <dd>Demonstrates how to make an activity with a transparent background. </dd>
-
-  <dt><a href="TranslucentFancyActivity.html">TranslucentFancy</a></dt>
-  <dd>Demonstrates how to make an activity with a transparent background with
-  a special effect (blur). </dd>
-</dl>
-
-<h3>Service</h3>
-<dl>
-  <dt><a href="LocalServiceController.html">Local Service Controller</a></dt>
-  <dd>Starts and stops the service class
-  <a href="LocalService.html">LocalService</a> that runs in the same
-  process as the activity, to demonstrate a service's
-  lifecycle when using {@link android.content.Context#startService
-  Context.startService} and {@link android.content.Context#stopService
-  Context.stopService}.</dd>
-
-  <dt><a href="LocalServiceBinding.html">Local Service Binding</a></dt>
-  <dd>Demonstrates binding to a service class
-  <a href="LocalService.html">LocalService</a> that runs in the same
-  process as the activity, to demonstrate using the
-  {@link android.content.Context#bindService Context.bindService} and
-  {@link android.content.Context#unbindService Context.unindService}
-  methods with a service.  This also shows how you can simplify working
-  with a service when you know it will only run in your own process.</dd>
-
-  <dt><a href="RemoteServiceController.html">Remote Service Controller</a></dt>
-  <dd>Demonstrates starting a service in a separate process, by assigning
-  <code>android:process=&quot;:remote&quot;</code> to the service in the
-  AndroidManifest.xml file. </dd>
-
-  <dt><a href="RemoteServiceBinding.html">Remote Service Binding</a></dt>
-  <dd>Demonstrates binding to a remote service, similar to the Local Service
-  Binding sample, but illustrating the additional work (defining aidl
-  interfaces) needed to interact with a service in another process.  Also
-  shows how a service can publish multiple interfaces and implement
-  callbacks to its clients.</dd>
-
-  <dt><a href="ServiceStartArgumentsController.html">Service Start Arguments Controller</a></dt>
-  <dd>Demonstrates how you can use a Service as a job queue, where you 
-  submit jobs to it with {@link android.content.Context#startService
-  Context.startService} instead of binding to the service.  Such a service
-  automatically stops itself once all jobs have been processed.  This can be
-  a very convenient way to interact with a service when you do not need
-  a result back from it.
-  <dl>
-  <dt>Code:
-  <dd> <a href="ServiceStartArgumentsController.html">ServiceStartArgumentsController.java</a>
-  <dd> <a href="ServiceStartArguments.html">ServiceStartArguments.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/service_start_arguments_controller.html">
-  service_start_arguments_controller.xml</a>
-  </dl>
-  </dd>
-</dl>
-
-<h3>Alarm</h3>
-<dl>
-  <dt><a href="AlarmController.html">Alarm Controller</a></dt>
-  <dd>Demonstrates two ways you can schedule alarms: a one-shot alarm that
-  will happen once at a given time, and a repeating alarm that will happen
-  first at a given time and then continually trigger at regular intervals
-  after that.
-  <dl>
-  <dt>Code:
-  <dd> <a href="AlarmController.html">AlarmController.java</a>
-  <dd> <a href="OneShotAlarm.html">OneShotAlarm.java</a>
-  <dd> <a href="RepeatingAlarm.html">RepeatingAlarm.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/alarm_controller.html">
-  alarm_controller.xml</a>
-  </dl>
-  </dd>
-
-  <dt><a href="AlarmService.html">Alarm Service</a></dt>
-  <dd>Demonstrates how you can schedule an alarm that causes a service to
-    be started.  This is useful when you want to schedule alarms that initiate
-    long-running operations, such as retrieving recent e-mails.
-  <dl>
-  <dt>Code:
-  <dd> <a href="AlarmService.html">AlarmService.java</a>
-  <dd> <a href="AlarmService_Service.html">AlarmService_Service.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/alarm_service.html">
-  alarm_service.xml</a>
-  </dl>
-  </dd>
-</dl>
-
-<h3>Notification</h3>
-<dl>
-  <dt><a href="NotifyWithText.html">NotifyWithText</a></dt>
-  <dd>Demonstrates popup notifications of varying length.</dd>
-
-  <dt><a href="IncomingMessage.html">IncomingMessage</a></dt>
-  <dd> Demonstrates sending persistent and transient notifications, with a View object in the notification. It also demonstrated inflating a View object from an XML layout resource. </dd>
-</dl>
-
-<h3>Search</h3>
-<dl>
-  <dt><a href="SearchInvoke.html">SearchInvoke</a></dt>
-  <dd>Demonstrates various ways in which activities can launch the Search UI.</dd>
-  
-  <dt><a href="SearchQueryResults.html">SearchQueryResults</a></dt>
-  <dd>Demonstrates an activity that receives Search intents and handles them.</dd>
-  
-  <dt><a href="SearchSuggestionSampleProvider.html">SearchSuggestionSampleProvider</a></dt>
-  <dd>Demonstrates how to configure and use the built-in "recent queries" suggestion provider.</dd>  
-</dl>
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/app/_package.html b/samples/ApiDemos/src/com/example/android/apis/app/_package.html
deleted file mode 100644
index 7f99501..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/app/_package.html
+++ /dev/null
@@ -1,48 +0,0 @@
-<html>
-<head>
-<link rel="stylesheet" type="text/css" href="assets/style.css" />
-<script type="text/javascript" src="http://www.corp.google.com/style/prettify.js"></script>
-<script src="http://www.corp.google.com/eng/techpubs/include/navbar.js" type="text/javascript"></script>
-
-
-
-</head>
-
-<body>
-
-<p>
-Examples of how to use the android.app APIs.
-
-<ol>
-	<li> Activities
-        - These examples show various ways you can use activities to implement an
-application's user interface.
-            <ol>
-			<li> {@link com.android.samples.app.HelloWorld Hello World}
-			<li> {@link com.android.samples.app.SaveRestoreState Save &amp; Restore State}
-			<li>{@link com.android.samples.app.PersistentState Persistent State}
-			<li>{@link com.android.samples.app.ReceiveResult Receive Result}
-			<li>{@link com.android.samples.app.Forwarding Forwarding}
-			</ol>
-	<li> Services
-        - These examples show how you can implement application services, which
-give you a way to run code in the background outside of the normal UI flow.
-            <ol>
-			<li>{@link com.android.samples.app.LocalServiceController Local Service
-			    Controller}
-			<li>{@link com.android.samples.app.LocalServiceBinding Local Service Binding}
-			<li>{@link com.android.samples.app.RemoteServiceController Remote Service
-			    Controller}
-			<li>{@link com.android.samples.app.RemoteServiceBinding Remote Service
-			    Binding}
-			</ol>
-	<li> Alarms
-        - These examples show how you can use alarms to schedule background
-events.
-            <ol>
-			<li>{@link com.android.samples.app.AlarmController Alarm Controller}
-			<li>{@link com.android.samples.app.AlarmService Alarm Service}
-			</ol>
-</ol>
-</body>
-</html>
diff --git a/samples/ApiDemos/src/com/example/android/apis/content/ReadAsset.java b/samples/ApiDemos/src/com/example/android/apis/content/ReadAsset.java
deleted file mode 100644
index 47503c4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/content/ReadAsset.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.content;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.TextView;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-
-/**
- * Demonstration of styled text resources.
- */
-public class ReadAsset extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/styled_text.xml for this
-        // view layout definition.
-        setContentView(R.layout.read_asset);
-
-        // Programmatically load text from an asset and place it into the
-        // text view.  Note that the text we are loading is ASCII, so we
-        // need to convert it to UTF-16.
-        try {
-            InputStream is = getAssets().open("read_asset.txt");
-            
-            // We guarantee that the available method returns the total
-            // size of the asset...  of course, this does mean that a single
-            // asset can't be more than 2 gigs.
-            int size = is.available();
-            
-            // Read the entire asset into a local byte buffer.
-            byte[] buffer = new byte[size];
-            is.read(buffer);
-            is.close();
-            
-            // Convert the buffer into a string.
-            String text = new String(buffer);
-            
-            // Finally stick the string into the text view.
-            TextView tv = (TextView)findViewById(R.id.text);
-            tv.setText(text);
-        } catch (IOException e) {
-            // Should never happen!
-            throw new RuntimeException(e);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/content/ResourcesSample.java b/samples/ApiDemos/src/com/example/android/apis/content/ResourcesSample.java
deleted file mode 100755
index f38be0f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/content/ResourcesSample.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.content;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.res.Resources;
-import android.os.Bundle;
-import android.widget.TextView;
-
-
-/**
- * Demonstration of loading resources.
- * 
- * <p>
- * Each context has a resources object that you can access.  Additionally,
- * the Context class (an Activity is a Context) has a getString convenience
- * method getString() that looks up a string resource.
- *
- * @see StyledText for more depth about using styled text, both with getString()
- *                 and in the layout xml files.
- */
-public class ResourcesSample extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        // See res/any/layout/resources.xml for this view layout definition.
-        setContentView(R.layout.resources);
-
-        TextView tv;
-        CharSequence cs;
-        String str;
-
-        // ====== Using the Context.getString() convenience method ===========
-
-        // Using the getString() conevenience method, retrieve a string
-        // resource that hapepns to have style information.  Note the use of
-        // CharSequence instead of String so we don't lose the style info.
-        cs = getText(R.string.styled_text);
-        tv = (TextView)findViewById(R.id.styled_text);
-        tv.setText(cs);
-
-        // Use the same resource, but convert it to a string, which causes it
-        // to lose the style information.
-        str = getString(R.string.styled_text);
-        tv = (TextView)findViewById(R.id.plain_text);
-        tv.setText(str);
-
-        // ====== Using the Resources object =================================
-        
-        // You might need to do this if your code is not in an activity.
-        // For example View has a protected mContext field you can use.
-        // In this case it's just 'this' since Activity is a context.
-        Context context = this;
-
-        // Get the Resources object from our context
-        Resources res = context.getResources();
-
-        // Get the string resource, like above.
-        cs = res.getText(R.string.styled_text);
-        tv = (TextView)findViewById(R.id.res1);
-        tv.setText(cs);
-
-        // Note that the Resources class has methods like getColor(),
-        // getDimen(), getDrawable() because themes are stored in resources.
-        // You can use them, but you might want to take a look at the view
-        // examples to see how to make custom widgets.
-
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/content/StyledText.java b/samples/ApiDemos/src/com/example/android/apis/content/StyledText.java
deleted file mode 100644
index b158929..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/content/StyledText.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.content;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.TextView;
-
-
-/**
- * Demonstration of styled text resources.
- */
-public class StyledText extends Activity
-{
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/styled_text.xml for this
-        // view layout definition.
-        setContentView(R.layout.styled_text);
-
-        // Programmatically retrieve a string resource with style
-        // information and apply it to the second text view.  Note the
-        // use of CharSequence instead of String so we don't lose
-        // the style info.
-        CharSequence str = getText(R.string.styled_text);
-        TextView tv = (TextView)findViewById(R.id.text);
-        tv.setText(str);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/content/_index.html b/samples/ApiDemos/src/com/example/android/apis/content/_index.html
deleted file mode 100644
index 1aa52b3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/content/_index.html
+++ /dev/null
@@ -1,8 +0,0 @@
-<h3>Resources</h3>
-<dl>
-  <dt><a href="StyledText.html">Styled Text</a></dt>
-  <dd>Demonstrates loading styled text (bold, italic) defined in a resource file. </dd>
-
-  <dt><a href="ResourcesSample.html">Resources</a></dt>
-  <dd>Demonstrates loading styled strings from a resource file, and extracting the raw text. </dd>
-</dl>
diff --git a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleBroadcastReceiver.java b/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleBroadcastReceiver.java
deleted file mode 100644
index eec10b2..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleBroadcastReceiver.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.gadget;
-
-import android.content.BroadcastReceiver;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.gadget.GadgetManager;
-import android.gadget.GadgetProvider;
-import android.os.SystemClock;
-import android.util.Log;
-import android.widget.RemoteViews;
-
-import java.util.ArrayList;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * A BroadcastReceiver that listens for updates for the ExampleGadgetProvider.  This
- * BroadcastReceiver starts off disabled, and we only enable it when there is a gadget
- * instance created, in order to only receive notifications when we need them.
- */
-public class ExampleBroadcastReceiver extends BroadcastReceiver {
-
-    public void onReceive(Context context, Intent intent) {
-        Log.d("ExmampleBroadcastReceiver", "intent=" + intent);
-
-        // For our example, we'll also update all of the gadgets when the timezone
-        // changes, or the user or network sets the time.
-        String action = intent.getAction();
-        if (action.equals(Intent.ACTION_TIMEZONE_CHANGED)
-                || action.equals(Intent.ACTION_TIME_CHANGED)) {
-            GadgetManager gm = GadgetManager.getInstance(context);
-            ArrayList<Integer> gadgetIds = new ArrayList();
-            ArrayList<String> texts = new ArrayList();
-
-            ExampleGadgetConfigure.loadAllTitlePrefs(context, gadgetIds, texts);
-
-            final int N = gadgetIds.size();
-            for (int i=0; i<N; i++) {
-                ExampleGadgetProvider.updateGadget(context, gm, gadgetIds.get(i), texts.get(i));
-            }
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetConfigure.java b/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetConfigure.java
deleted file mode 100644
index 03e7bb4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetConfigure.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.gadget;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.gadget.GadgetManager;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.View;
-import android.widget.EditText;
-
-import java.util.ArrayList;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * The configuration screen for the ExampleGadgetProvider gadget sample.
- */
-public class ExampleGadgetConfigure extends Activity {
-    static final String TAG = "ExampleGadgetConfigure";
-
-    private static final String PREFS_NAME
-            = "com.example.android.apis.gadget.ExampleGadgetProvider";
-    private static final String PREF_PREFIX_KEY = "prefix_";
-
-    int mGadgetId = GadgetManager.INVALID_GADGET_ID;
-    EditText mGadgetPrefix;
-
-    public ExampleGadgetConfigure() {
-        super();
-    }
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        // Set the result to CANCELED.  This will cause the gadget host to cancel
-        // out of the gadget placement if they press the back button.
-        setResult(RESULT_CANCELED);
-
-        // Set the view layout resource to use.
-        setContentView(R.layout.gadget_configure);
-
-        // Find the EditText
-        mGadgetPrefix = (EditText)findViewById(R.id.gadget_prefix);
-
-        // Bind the action for the save button.
-        findViewById(R.id.save_button).setOnClickListener(mOnClickListener);
-
-        // Find the gadget id from the intent. 
-        Intent intent = getIntent();
-        Bundle extras = intent.getExtras();
-        if (extras != null) {
-            mGadgetId = extras.getInt(
-                    GadgetManager.EXTRA_GADGET_ID, GadgetManager.INVALID_GADGET_ID);
-        }
-
-        // If they gave us an intent without the gadget id, just bail.
-        if (mGadgetId == GadgetManager.INVALID_GADGET_ID) {
-            finish();
-        }
-
-        mGadgetPrefix.setText(loadTitlePref(ExampleGadgetConfigure.this, mGadgetId));
-    }
-
-    View.OnClickListener mOnClickListener = new View.OnClickListener() {
-        public void onClick(View v) {
-            // When the button is clicked, save the string in our prefs and return that they
-            // clicked OK.
-            saveTitlePref(ExampleGadgetConfigure.this, mGadgetId,
-                    mGadgetPrefix.getText().toString());
-
-            setResult(RESULT_OK);
-            finish();
-        }
-    };
-
-    // Write the prefix to the SharedPreferences object for this gadget
-    static void saveTitlePref(Context context, int gadgetId, String text) {
-        SharedPreferences.Editor prefs = context.getSharedPreferences(PREFS_NAME, 0).edit();
-        prefs.putString(PREF_PREFIX_KEY + gadgetId, text);
-        prefs.commit();
-    }
-
-    // Read the prefix from the SharedPreferences object for this gadget.
-    // If there is no preference saved, get the default from a resource
-    static String loadTitlePref(Context context, int gadgetId) {
-        SharedPreferences prefs = context.getSharedPreferences(PREFS_NAME, 0);
-        String prefix = prefs.getString(PREF_PREFIX_KEY, null);
-        if (prefix != null) {
-            return prefix;
-        } else {
-            return context.getString(R.string.gadget_prefix_default);
-        }
-    }
-
-    static void deleteTitlePref(Context context, int gadgetId) {
-    }
-
-    static void loadAllTitlePrefs(Context context, ArrayList<Integer> gadgetIds,
-            ArrayList<String> texts) {
-    }
-}
-
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetProvider.java b/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetProvider.java
deleted file mode 100644
index eb1dab3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/gadget/ExampleGadgetProvider.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.gadget;
-
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.gadget.GadgetManager;
-import android.gadget.GadgetProvider;
-import android.os.SystemClock;
-import android.util.Log;
-import android.widget.RemoteViews;
-
-import java.util.ArrayList;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * A gadget provider.  We have a string that we pull from a preference in order to show
- * the configuration settings and the current time when the gadget was updated.  We also
- * register a BroadcastReceiver for time-changed and timezone-changed broadcasts, and
- * update then too.
- *
- * <p>See also the following files:
- * <ul>
- *   <li>ExampleGadgetConfigure.java</li>
- *   <li>ExampleBroadcastReceiver.java</li>
- *   <li>res/layout/gadget_configure.xml</li>
- *   <li>res/layout/gadget_provider.xml</li>
- *   <li>res/xml/gadget_provider.xml</li>
- * </ul>
- */
-public class ExampleGadgetProvider extends GadgetProvider {
-    // log tag
-    private static final String TAG = "ExampleGadgetProvider";
-
-    public void onUpdate(Context context, GadgetManager gadgetManager, int[] gadgetIds) {
-        Log.d(TAG, "onUpdate");
-        // For each gadget that needs an update, get the text that we should display:
-        //   - Create a RemoteViews object for it
-        //   - Set the text in the RemoteViews object
-        //   - Tell the GadgetManager to show that views object for the gadget.
-        final int N = gadgetIds.length;
-        for (int i=0; i<N; i++) {
-            int gadgetId = gadgetIds[i];
-            String titlePrefix = ExampleGadgetConfigure.loadTitlePref(context, gadgetId);
-            updateGadget(context, gadgetManager, gadgetId, titlePrefix);
-        }
-    }
-    
-    public void onDeleted(Context context, int[] gadgetIds) {
-        Log.d(TAG, "onDeleted");
-        // When the user deletes the gadget, delete the preference associated with it.
-        final int N = gadgetIds.length;
-        for (int i=0; i<N; i++) {
-            ExampleGadgetConfigure.deleteTitlePref(context, gadgetIds[i]);
-        }
-    }
-
-    public void onEnabled(Context context) {
-        Log.d(TAG, "onEnabled");
-        // When the first gadget is created, register for the TIMEZONE_CHANGED and TIME_CHANGED
-        // broadcasts.  We don't want to be listening for these if nobody has our gadget active.
-        // This setting is sticky across reboots, but that doesn't matter, because this will
-        // be called after boot if there is a gadget instance for this provider.
-        PackageManager pm = context.getPackageManager();
-        pm.setComponentEnabledSetting(
-                new ComponentName("com.example.android.apis", ".gadget.ExampleBroadcastReceiver"),
-                PackageManager.COMPONENT_ENABLED_STATE_ENABLED,
-                PackageManager.DONT_KILL_APP);
-    }
-
-    public void onDisabled(Context context) {
-        // When the first gadget is created, stop listening for the TIMEZONE_CHANGED and
-        // TIME_CHANGED broadcasts.
-        Log.d(TAG, "onDisabled");
-        Class clazz = ExampleBroadcastReceiver.class;
-        PackageManager pm = context.getPackageManager();
-        pm.setComponentEnabledSetting(
-                new ComponentName("com.example.android.apis", ".gadget.ExampleBroadcastReceiver"),
-                PackageManager.COMPONENT_ENABLED_STATE_ENABLED,
-                PackageManager.DONT_KILL_APP);
-    }
-
-    static void updateGadget(Context context, GadgetManager gadgetManager,
-            int gadgetId, String titlePrefix) {
-        Log.d(TAG, "updateGadget gadgetId=" + gadgetId + " titlePrefix=" + titlePrefix);
-        // Getting the string this way allows the string to be localized.  The format
-        // string is filled in using java.util.Formatter-style format strings.
-        CharSequence text = context.getString(R.string.gadget_text_format,
-                ExampleGadgetConfigure.loadTitlePref(context, gadgetId),
-                "0x" + Long.toHexString(SystemClock.elapsedRealtime()));
-
-        // Construct the RemoteViews object.  It takes the package name (in our case, it's our
-        // package, but it needs this because on the other side it's the gadget host inflating
-        // the layout from our package).
-        RemoteViews views = new RemoteViews(context.getPackageName(), R.layout.gadget_provider);
-        views.setTextViewText(R.id.gadget_text, text);
-
-        // Tell the gadget manager
-        gadgetManager.updateGadget(gadgetId, views);
-    }
-}
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/AlphaBitmap.java b/samples/ApiDemos/src/com/example/android/apis/graphics/AlphaBitmap.java
deleted file mode 100644
index 8fff231..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/AlphaBitmap.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-import java.io.InputStream;
-import java.io.ByteArrayOutputStream;
-
-public class AlphaBitmap extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Bitmap mBitmap;
-        private Bitmap mBitmap2;
-        private Bitmap mBitmap3;
-        private Shader mShader;
-        
-        private static void drawIntoBitmap(Bitmap bm) {
-            float x = bm.getWidth();
-            float y = bm.getHeight();
-            Canvas c = new Canvas(bm);
-            Paint p = new Paint();
-            p.setAntiAlias(true);
-            
-            p.setAlpha(0x80);
-            c.drawCircle(x/2, y/2, x/2, p);
-            
-            p.setAlpha(0x30);
-            p.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC));
-            p.setTextSize(60);
-            p.setTextAlign(Paint.Align.CENTER);
-            Paint.FontMetrics fm = p.getFontMetrics();
-            c.drawText("Alpha", x/2, (y-fm.ascent)/2, p);
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            InputStream is = context.getResources().openRawResource(R.drawable.app_sample_code);
-            mBitmap = BitmapFactory.decodeStream(is);
-            mBitmap2 = mBitmap.extractAlpha();
-            mBitmap3 = Bitmap.createBitmap(200, 200, Bitmap.Config.ALPHA_8);
-            drawIntoBitmap(mBitmap3);
-            
-            mShader = new LinearGradient(0, 0, 100, 70, new int[] {
-                                         Color.RED, Color.GREEN, Color.BLUE },
-                                         null, Shader.TileMode.MIRROR);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            Paint p = new Paint();
-            float y = 10;
-            
-            p.setColor(Color.RED);
-            canvas.drawBitmap(mBitmap, 10, y, p);
-            y += mBitmap.getHeight() + 10;
-            canvas.drawBitmap(mBitmap2, 10, y, p);
-            y += mBitmap2.getHeight() + 10;
-            p.setShader(mShader);
-            canvas.drawBitmap(mBitmap3, 10, y, p);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawable.java b/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawable.java
deleted file mode 100644
index 279b588..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawable.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.graphics.Canvas;
-import android.graphics.drawable.Drawable;
-import android.view.animation.Animation;
-import android.view.animation.AnimationUtils;
-import android.view.animation.Transformation;
-
-public class AnimateDrawable extends ProxyDrawable {
-    
-    private Animation mAnimation;
-    private Transformation mTransformation = new Transformation();
-
-    public AnimateDrawable(Drawable target) {
-        super(target);
-    }
-    
-    public AnimateDrawable(Drawable target, Animation animation) {
-        super(target);
-        mAnimation = animation;
-    }
-    
-    public Animation getAnimation() {
-        return mAnimation;
-    }
-    
-    public void setAnimation(Animation anim) {
-        mAnimation = anim;
-    }
-
-    public boolean hasStarted() {
-        return mAnimation != null && mAnimation.hasStarted();
-    }
-    
-    public boolean hasEnded() {
-        return mAnimation == null || mAnimation.hasEnded();
-    }
-    
-    @Override
-    public void draw(Canvas canvas) {
-        Drawable dr = getProxy();
-        if (dr != null) {
-            int sc = canvas.save();
-            Animation anim = mAnimation;
-            if (anim != null) {
-                anim.getTransformation(
-                                    AnimationUtils.currentAnimationTimeMillis(),
-                                    mTransformation);
-                canvas.concat(mTransformation.getMatrix());
-            }
-            dr.draw(canvas);
-            canvas.restoreToCount(sc);
-        }
-    }
-}
-    
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawables.java b/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawables.java
deleted file mode 100644
index 7c9473d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/AnimateDrawables.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.*;
-import android.view.animation.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-public class AnimateDrawables extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private AnimateDrawable mDrawable;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            Drawable dr = context.getResources().getDrawable(R.drawable.beach);
-            dr.setBounds(0, 0, dr.getIntrinsicWidth(), dr.getIntrinsicHeight());
-            
-            Animation an = new TranslateAnimation(0, 100, 0, 200);
-            an.setDuration(2000);
-            an.setRepeatCount(-1);
-            an.initialize(10, 10, 10, 10);
-            
-            mDrawable = new AnimateDrawable(dr, an);
-            an.startNow();
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            mDrawable.draw(canvas);
-            invalidate();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Arcs.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Arcs.java
deleted file mode 100644
index ff8b38b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Arcs.java
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-//import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class Arcs extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint[] mPaints;
-        private Paint mFramePaint;
-        private boolean[] mUseCenters;
-        private RectF[] mOvals;
-        private RectF mBigOval;
-        private float mStart;
-        private float mSweep;
-        private int mBigIndex;
-        
-        private static final float SWEEP_INC = 2;
-        private static final float START_INC = 15;
-        
-        public SampleView(Context context) {
-            super(context);
-            
-            mPaints = new Paint[4];
-            mUseCenters = new boolean[4];
-            mOvals = new RectF[4];
-    
-            mPaints[0] = new Paint();
-            mPaints[0].setAntiAlias(true);
-            mPaints[0].setStyle(Paint.Style.FILL);
-            mPaints[0].setColor(0x88FF0000);
-            mUseCenters[0] = false;
-            
-            mPaints[1] = new Paint(mPaints[0]);
-            mPaints[1].setColor(0x8800FF00);
-            mUseCenters[1] = true;
-            
-            mPaints[2] = new Paint(mPaints[0]);
-            mPaints[2].setStyle(Paint.Style.STROKE);
-            mPaints[2].setStrokeWidth(4);
-            mPaints[2].setColor(0x880000FF);
-            mUseCenters[2] = false;
-
-            mPaints[3] = new Paint(mPaints[2]);
-            mPaints[3].setColor(0x88888888);
-            mUseCenters[3] = true;
-            
-            mBigOval = new RectF(40, 10, 280, 250);
-            
-            mOvals[0] = new RectF( 10, 270,  70, 330);
-            mOvals[1] = new RectF( 90, 270, 150, 330);
-            mOvals[2] = new RectF(170, 270, 230, 330);
-            mOvals[3] = new RectF(250, 270, 310, 330);
-            
-            mFramePaint = new Paint();
-            mFramePaint.setAntiAlias(true);
-            mFramePaint.setStyle(Paint.Style.STROKE);
-            mFramePaint.setStrokeWidth(0);
-        }
-        
-        private void drawArcs(Canvas canvas, RectF oval, boolean useCenter,
-                              Paint paint) {
-            canvas.drawRect(oval, mFramePaint);
-            canvas.drawArc(oval, mStart, mSweep, useCenter, paint);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-            
-            drawArcs(canvas, mBigOval, mUseCenters[mBigIndex],
-                     mPaints[mBigIndex]);
-            
-            for (int i = 0; i < 4; i++) {
-                drawArcs(canvas, mOvals[i], mUseCenters[i], mPaints[i]);
-            }
-            
-            mSweep += SWEEP_INC;
-            if (mSweep > 360) {
-                mSweep -= 360;
-                mStart += START_INC;
-                if (mStart >= 360) {
-                    mStart -= 360;
-                }
-                mBigIndex = (mBigIndex + 1) % mOvals.length;
-            }
-            invalidate();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapDecode.java b/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapDecode.java
deleted file mode 100644
index 88f0c1d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapDecode.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ByteArrayOutputStream;
-
-public class BitmapDecode extends GraphicsActivity {
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Bitmap mBitmap;
-        private Bitmap mBitmap2;
-        private Bitmap mBitmap3;
-        private Bitmap mBitmap4;
-        private Drawable mDrawable;
-        
-        private Movie mMovie;
-        private long mMovieStart;
-        
-        private static byte[] streamToBytes(InputStream is) {
-            ByteArrayOutputStream os = new ByteArrayOutputStream(1024);
-            byte[] buffer = new byte[1024];
-            int len;
-            try {
-                while ((len = is.read(buffer)) >= 0) {
-                    os.write(buffer, 0, len);
-                }
-            } catch (java.io.IOException e) {
-            }
-            return os.toByteArray();
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            java.io.InputStream is;
-            is = context.getResources().openRawResource(R.drawable.beach);
-            
-            BitmapFactory.Options opts = new BitmapFactory.Options();
-            Bitmap bm;
-            
-            opts.inJustDecodeBounds = true;
-            bm = BitmapFactory.decodeStream(is, null, opts);
-            
-            // now opts.outWidth and opts.outHeight are the dimension of the
-            // bitmap, even though bm is null
-            
-            opts.inJustDecodeBounds = false;    // this will request the bm
-            opts.inSampleSize = 4;             // scaled down by 4
-            bm = BitmapFactory.decodeStream(is, null, opts);
-            
-            mBitmap = bm;
-            
-            // decode an image with transparency
-            is = context.getResources().openRawResource(R.drawable.frog);
-            mBitmap2 = BitmapFactory.decodeStream(is);
-            
-            // create a deep copy of it using getPixels() into different configs
-            int w = mBitmap2.getWidth();
-            int h = mBitmap2.getHeight();
-            int[] pixels = new int[w*h];
-            mBitmap2.getPixels(pixels, 0, w, 0, 0, w, h);
-            mBitmap3 = Bitmap.createBitmap(pixels, 0, w, w, h,
-                                           Bitmap.Config.ARGB_8888);
-            mBitmap4 = Bitmap.createBitmap(pixels, 0, w, w, h,
-                                           Bitmap.Config.ARGB_4444);
-            
-            mDrawable = context.getResources().getDrawable(R.drawable.button);
-            mDrawable.setBounds(150, 20, 300, 100);
-            
-            is = context.getResources().openRawResource(R.drawable.animated_gif);
-            if (true) {
-                mMovie = Movie.decodeStream(is);
-            } else {
-                byte[] array = streamToBytes(is);
-                mMovie = Movie.decodeByteArray(array, 0, array.length);
-            }
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(0xFFCCCCCC);            
-            
-            Paint p = new Paint();
-            p.setAntiAlias(true);
-            
-            canvas.drawBitmap(mBitmap, 10, 10, null);
-            canvas.drawBitmap(mBitmap2, 10, 170, null);
-            canvas.drawBitmap(mBitmap3, 110, 170, null);
-            canvas.drawBitmap(mBitmap4, 210, 170, null);
-            
-            mDrawable.draw(canvas);
-            
-            long now = android.os.SystemClock.uptimeMillis();
-            if (mMovieStart == 0) {   // first time
-                mMovieStart = now;
-            }
-            if (mMovie != null) {
-                int dur = mMovie.duration();
-                if (dur == 0) {
-                    dur = 1000;
-                }
-                int relTime = (int)((now - mMovieStart) % dur);
-                mMovie.setTime(relTime);
-                mMovie.draw(canvas, getWidth() - mMovie.width(),
-                            getHeight() - mMovie.height());
-                invalidate();
-            }
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapMesh.java b/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapMesh.java
deleted file mode 100644
index 4d48a1e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapMesh.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.*;
-import android.util.FloatMath;
-
-public class BitmapMesh extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private static final int WIDTH = 20;
-        private static final int HEIGHT = 20;
-        private static final int COUNT = (WIDTH + 1) * (HEIGHT + 1);
-        
-        private final Bitmap mBitmap;
-        private final float[] mVerts = new float[COUNT*2];
-        private final float[] mOrig = new float[COUNT*2];
-        
-        private final Matrix mMatrix = new Matrix();
-        private final Matrix mInverse = new Matrix();
-
-        private static void setXY(float[] array, int index, float x, float y) {
-            array[index*2 + 0] = x;
-            array[index*2 + 1] = y;
-        }
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-
-            mBitmap = BitmapFactory.decodeResource(getResources(),
-                                                     R.drawable.beach);
-            
-            float w = mBitmap.getWidth();
-            float h = mBitmap.getHeight();
-            // construct our mesh
-            int index = 0;
-            for (int y = 0; y <= HEIGHT; y++) {
-                float fy = h * y / HEIGHT;
-                for (int x = 0; x <= WIDTH; x++) {
-                    float fx = w * x / WIDTH;                    
-                    setXY(mVerts, index, fx, fy);
-                    setXY(mOrig, index, fx, fy);
-                    index += 1;
-                }
-            }
-            
-            mMatrix.setTranslate(10, 10);
-            mMatrix.invert(mInverse);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(0xFFCCCCCC);
-
-            canvas.concat(mMatrix);
-            canvas.drawBitmapMesh(mBitmap, WIDTH, HEIGHT, mVerts, 0,
-                                  null, 0, null);
-        }
-        
-        private void warp(float cx, float cy) {
-            final float K = 10000;
-            float[] src = mOrig;
-            float[] dst = mVerts;
-            for (int i = 0; i < COUNT*2; i += 2) {
-                float x = src[i+0];
-                float y = src[i+1];
-                float dx = cx - x;
-                float dy = cy - y;
-                float dd = dx*dx + dy*dy;
-                float d = FloatMath.sqrt(dd);
-                float pull = K / (dd + 0.000001f);
-                
-                pull /= (d + 0.000001f);
-             //   android.util.Log.d("skia", "index " + i + " dist=" + d + " pull=" + pull);
-
-                if (pull >= 1) {
-                    dst[i+0] = cx;
-                    dst[i+1] = cy;
-                } else {
-                    dst[i+0] = x + dx * pull;
-                    dst[i+1] = y + dy * pull;
-                }
-            }
-        }
-
-        private int mLastWarpX = -9999; // don't match a touch coordinate
-        private int mLastWarpY;
-
-        @Override public boolean onTouchEvent(MotionEvent event) {
-            float[] pt = { event.getX(), event.getY() };
-            mInverse.mapPoints(pt);
-            
-            int x = (int)pt[0];
-            int y = (int)pt[1];
-            if (mLastWarpX != x || mLastWarpY != y) {
-                mLastWarpX = x;
-                mLastWarpY = y;
-                warp(pt[0], pt[1]);
-                invalidate();
-            }
-            return true;
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapPixels.java b/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapPixels.java
deleted file mode 100644
index 88717bc..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/BitmapPixels.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-import java.nio.IntBuffer;
-import java.nio.ShortBuffer;
-
-public class BitmapPixels extends GraphicsActivity {
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Bitmap mBitmap1;
-        private Bitmap mBitmap2;
-        private Bitmap mBitmap3;
-        private Bitmap mBitmap4;
-
-        // access the red component from a premultiplied color
-        private static int getR32(int c) { return (c >>  0) & 0xFF; }
-        // access the red component from a premultiplied color
-        private static int getG32(int c) { return (c >>  8) & 0xFF; }
-        // access the red component from a premultiplied color
-        private static int getB32(int c) { return (c >> 16) & 0xFF; }
-        // access the red component from a premultiplied color
-        private static int getA32(int c) { return (c >> 24) & 0xFF; }
-
-        /**
-         * This takes components that are already in premultiplied form, and
-         * packs them into an int in the correct device order.
-         */
-        private static int pack8888(int r, int g, int b, int a) {
-            return (r << 0) | ( g << 8) | (b << 16) | (a << 24);
-        }
-
-        private static short pack565(int r, int g, int b) {
-            return (short)((r << 11) | ( g << 5) | (b << 0));
-        }
-
-        private static short pack4444(int r, int g, int b, int a) {
-            return (short)((a << 0) | ( b << 4) | (g << 8) | (r << 12));
-        }
-        
-        private static int mul255(int c, int a) {
-            int prod = c * a + 128;
-            return (prod + (prod >> 8)) >> 8;
-        }
-
-        /**
-         * Turn a color int into a premultiplied device color
-         */
-        private static int premultiplyColor(int c) {
-            int r = Color.red(c);
-            int g = Color.green(c);
-            int b = Color.blue(c);
-            int a = Color.alpha(c);
-            // now apply the alpha to r, g, b
-            r = mul255(r, a);
-            g = mul255(g, a);
-            b = mul255(b, a);
-            // now pack it in the correct order
-            return pack8888(r, g, b, a);
-        }
-        
-        private static void makeRamp(int from, int to, int n,
-                                     int[] ramp8888, short[] ramp565,
-                                     short[] ramp4444) {
-            int r = getR32(from) << 23;
-            int g = getG32(from) << 23;
-            int b = getB32(from) << 23;
-            int a = getA32(from) << 23;
-            // now compute our step amounts per componenet (biased by 23 bits)
-            int dr = ((getR32(to) << 23) - r) / (n - 1);
-            int dg = ((getG32(to) << 23) - g) / (n - 1);
-            int db = ((getB32(to) << 23) - b) / (n - 1);
-            int da = ((getA32(to) << 23) - a) / (n - 1);
-
-            for (int i = 0; i < n; i++) {
-                ramp8888[i] = pack8888(r >> 23, g >> 23, b >> 23, a >> 23);
-                ramp565[i] = pack565(r >> (23+3), g >> (23+2), b >> (23+3));
-                ramp4444[i] = pack4444(r >> (23+4), g >> (23+4), b >> (23+4),
-                                       a >> (23+4));
-                r += dr;
-                g += dg;
-                b += db;
-                a += da;
-            }
-        }
-        
-        private static IntBuffer makeBuffer(int[] src, int n) {
-            IntBuffer dst = IntBuffer.allocate(n*n);
-            for (int i = 0; i < n; i++) {
-                dst.put(src);
-            }
-            dst.rewind();
-            return dst;
-        }
-        
-        private static ShortBuffer makeBuffer(short[] src, int n) {
-            ShortBuffer dst = ShortBuffer.allocate(n*n);
-            for (int i = 0; i < n; i++) {
-                dst.put(src);
-            }
-            dst.rewind();
-            return dst;
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            final int N = 100;
-            int[] data8888 = new int[N];
-            short[] data565 = new short[N];
-            short[] data4444 = new short[N];
-            
-            makeRamp(premultiplyColor(Color.RED), premultiplyColor(Color.GREEN),
-                     N, data8888, data565, data4444);
-            
-            mBitmap1 = Bitmap.createBitmap(N, N, Bitmap.Config.ARGB_8888);
-            mBitmap2 = Bitmap.createBitmap(N, N, Bitmap.Config.RGB_565);
-            mBitmap3 = Bitmap.createBitmap(N, N, Bitmap.Config.ARGB_4444);
-            
-            mBitmap1.copyPixelsFromBuffer(makeBuffer(data8888, N));
-            mBitmap2.copyPixelsFromBuffer(makeBuffer(data565, N));
-            mBitmap3.copyPixelsFromBuffer(makeBuffer(data4444, N));
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(0xFFCCCCCC);            
-            
-            int y = 10;
-            canvas.drawBitmap(mBitmap1, 10, y, null);
-            y += mBitmap1.getHeight() + 10;
-            canvas.drawBitmap(mBitmap2, 10, y, null);
-            y += mBitmap2.getHeight() + 10;
-            canvas.drawBitmap(mBitmap3, 10, y, null);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/CameraPreview.java b/samples/ApiDemos/src/com/example/android/apis/graphics/CameraPreview.java
deleted file mode 100644
index ceff150..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/CameraPreview.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.hardware.Camera;
-import android.os.Bundle;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-import android.view.Window;
-import java.io.IOException;
-
-// ----------------------------------------------------------------------
-
-public class CameraPreview extends Activity {    
-    private Preview mPreview;
-    
-    @Override
-	protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Hide the window title.
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-    
-        // Create our Preview view and set it as the content of our activity.
-        mPreview = new Preview(this);
-        setContentView(mPreview);
-    }
-
-}
-
-// ----------------------------------------------------------------------
-
-class Preview extends SurfaceView implements SurfaceHolder.Callback {
-    SurfaceHolder mHolder;
-    Camera mCamera;
-    
-    Preview(Context context) {
-        super(context);
-        
-        // Install a SurfaceHolder.Callback so we get notified when the
-        // underlying surface is created and destroyed.
-        mHolder = getHolder();
-        mHolder.addCallback(this);
-        mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS);
-    }
-
-    public void surfaceCreated(SurfaceHolder holder) {
-        // The Surface has been created, acquire the camera and tell it where
-        // to draw.
-        mCamera = Camera.open();
-        try {
-           mCamera.setPreviewDisplay(holder);
-        } catch (IOException exception) {
-            mCamera.release();
-            mCamera = null;
-            // TODO: add more exception handling logic here
-        }
-    }
-
-    public void surfaceDestroyed(SurfaceHolder holder) {
-        // Surface will be destroyed when we return, so stop the preview.
-        // Because the CameraDevice object is not a shared resource, it's very
-        // important to release it when the activity is paused.
-        mCamera.stopPreview();
-        mCamera = null;
-    }
-
-    public void surfaceChanged(SurfaceHolder holder, int format, int w, int h) {
-        // Now that the size is known, set up the camera parameters and begin
-        // the preview.
-        Camera.Parameters parameters = mCamera.getParameters();
-        parameters.setPreviewSize(w, h);
-        mCamera.setParameters(parameters);
-        mCamera.startPreview();
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Clipping.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Clipping.java
deleted file mode 100644
index cf83597..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Clipping.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class Clipping extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mPaint;
-        private Path mPath;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-            mPaint.setStrokeWidth(6);
-            mPaint.setTextSize(16);
-            mPaint.setTextAlign(Paint.Align.RIGHT);
-            
-            mPath = new Path();
-        }
-        
-        private void drawScene(Canvas canvas) {
-            canvas.clipRect(0, 0, 100, 100);
-            
-            canvas.drawColor(Color.WHITE);
-            
-            mPaint.setColor(Color.RED);
-            canvas.drawLine(0, 0, 100, 100, mPaint);
-            
-            mPaint.setColor(Color.GREEN);
-            canvas.drawCircle(30, 70, 30, mPaint);
-            
-            mPaint.setColor(Color.BLUE);
-            canvas.drawText("Clipping", 100, 30, mPaint);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.GRAY);            
-
-            canvas.save();
-            canvas.translate(10, 10);
-            drawScene(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 10);
-            canvas.clipRect(10, 10, 90, 90);
-            canvas.clipRect(30, 30, 70, 70, Region.Op.DIFFERENCE);
-            drawScene(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(10, 160);
-            mPath.reset();
-            canvas.clipPath(mPath); // makes the clip empty
-            mPath.addCircle(50, 50, 50, Path.Direction.CCW);
-            canvas.clipPath(mPath, Region.Op.REPLACE);
-            drawScene(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 160);
-            canvas.clipRect(0, 0, 60, 60);
-            canvas.clipRect(40, 40, 100, 100, Region.Op.UNION);
-            drawScene(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(10, 310);
-            canvas.clipRect(0, 0, 60, 60);
-            canvas.clipRect(40, 40, 100, 100, Region.Op.XOR);
-            drawScene(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 310);
-            canvas.clipRect(0, 0, 60, 60);
-            canvas.clipRect(40, 40, 100, 100, Region.Op.REVERSE_DIFFERENCE);
-            drawScene(canvas);
-            canvas.restore();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/ColorMatrixSample.java b/samples/ApiDemos/src/com/example/android/apis/graphics/ColorMatrixSample.java
deleted file mode 100644
index 19a0f7f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/ColorMatrixSample.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-public class ColorMatrixSample extends GraphicsActivity {
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private ColorMatrix mCM = new ColorMatrix();
-        private Bitmap mBitmap;
-        private float mSaturation;
-        private float mAngle;
-        
-        public SampleView(Context context) {
-            super(context);
-            
-            mBitmap = BitmapFactory.decodeResource(context.getResources(),
-                                                   R.drawable.balloons);
-        }
-        
-        private static void setTranslate(ColorMatrix cm, float dr, float dg,
-                                         float db, float da) {
-            cm.set(new float[] {
-                   2, 0, 0, 0, dr,
-                   0, 2, 0, 0, dg,
-                   0, 0, 2, 0, db,
-                   0, 0, 0, 1, da });
-        }
-        
-        private static void setContrast(ColorMatrix cm, float contrast) {
-            float scale = contrast + 1.f;
-               float translate = (-.5f * scale + .5f) * 255.f;
-            cm.set(new float[] {
-                   scale, 0, 0, 0, translate,
-                   0, scale, 0, 0, translate,
-                   0, 0, scale, 0, translate,
-                   0, 0, 0, 1, 0 });
-        }
-        
-        private static void setContrastTranslateOnly(ColorMatrix cm, float contrast) {
-            float scale = contrast + 1.f;
-               float translate = (-.5f * scale + .5f) * 255.f;
-            cm.set(new float[] {
-                   1, 0, 0, 0, translate,
-                   0, 1, 0, 0, translate,
-                   0, 0, 1, 0, translate,
-                   0, 0, 0, 1, 0 });
-        }
-        
-        private static void setContrastScaleOnly(ColorMatrix cm, float contrast) {
-            float scale = contrast + 1.f;
-               float translate = (-.5f * scale + .5f) * 255.f;
-            cm.set(new float[] {
-                   scale, 0, 0, 0, 0,
-                   0, scale, 0, 0, 0,
-                   0, 0, scale, 0, 0,
-                   0, 0, 0, 1, 0 });
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-            float x = 20;
-            float y = 20;
-            
-            canvas.drawColor(Color.WHITE);
-            
-            paint.setColorFilter(null);
-            canvas.drawBitmap(mBitmap, x, y, paint);
-            
-            ColorMatrix cm = new ColorMatrix();
-            
-            mAngle += 2;
-            if (mAngle > 180) {
-                mAngle = 0;
-            }
-            
-            //convert our animated angle [-180...180] to a contrast value of [-1..1]
-            float contrast = mAngle / 180.f;
-            
-            setContrast(cm, contrast);
-            paint.setColorFilter(new ColorMatrixColorFilter(cm));
-            canvas.drawBitmap(mBitmap, x + mBitmap.getWidth() + 10, y, paint);
-            
-            setContrastScaleOnly(cm, contrast);
-            paint.setColorFilter(new ColorMatrixColorFilter(cm));
-            canvas.drawBitmap(mBitmap, x, y + mBitmap.getHeight() + 10, paint);
-            
-            setContrastTranslateOnly(cm, contrast);
-            paint.setColorFilter(new ColorMatrixColorFilter(cm));
-            canvas.drawBitmap(mBitmap, x, y + 2*(mBitmap.getHeight() + 10),
-                              paint);
-            
-            invalidate();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/ColorPickerDialog.java b/samples/ApiDemos/src/com/example/android/apis/graphics/ColorPickerDialog.java
deleted file mode 100644
index cc4a0d4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/ColorPickerDialog.java
+++ /dev/null
@@ -1,234 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.R;
-import android.os.Bundle;
-import android.app.Dialog;
-import android.content.Context;
-import android.graphics.*;
-import android.view.MotionEvent;
-import android.view.View;
-
-public class ColorPickerDialog extends Dialog {
-
-    public interface OnColorChangedListener {
-        void colorChanged(int color);
-    }
-
-    private OnColorChangedListener mListener;
-    private int mInitialColor;
-
-    private static class ColorPickerView extends View {
-        private Paint mPaint;
-        private Paint mCenterPaint;
-        private final int[] mColors;
-        private OnColorChangedListener mListener;
-        
-        ColorPickerView(Context c, OnColorChangedListener l, int color) {
-            super(c);
-            mListener = l;
-            mColors = new int[] {
-                0xFFFF0000, 0xFFFF00FF, 0xFF0000FF, 0xFF00FFFF, 0xFF00FF00,
-                0xFFFFFF00, 0xFFFF0000
-            };
-            Shader s = new SweepGradient(0, 0, mColors, null);
-            
-            mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mPaint.setShader(s);
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setStrokeWidth(32);
-            
-            mCenterPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mCenterPaint.setColor(color);
-            mCenterPaint.setStrokeWidth(5);
-        }
-        
-        private boolean mTrackingCenter;
-        private boolean mHighlightCenter;
-
-        @Override 
-        protected void onDraw(Canvas canvas) {
-            float r = CENTER_X - mPaint.getStrokeWidth()*0.5f;
-            
-            canvas.translate(CENTER_X, CENTER_X);
-            
-            canvas.drawOval(new RectF(-r, -r, r, r), mPaint);            
-            canvas.drawCircle(0, 0, CENTER_RADIUS, mCenterPaint);
-            
-            if (mTrackingCenter) {
-                int c = mCenterPaint.getColor();
-                mCenterPaint.setStyle(Paint.Style.STROKE);
-                
-                if (mHighlightCenter) {
-                    mCenterPaint.setAlpha(0xFF);
-                } else {
-                    mCenterPaint.setAlpha(0x80);
-                }
-                canvas.drawCircle(0, 0,
-                                  CENTER_RADIUS + mCenterPaint.getStrokeWidth(),
-                                  mCenterPaint);
-                
-                mCenterPaint.setStyle(Paint.Style.FILL);
-                mCenterPaint.setColor(c);
-            }
-        }
-        
-        @Override
-        protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-            setMeasuredDimension(CENTER_X*2, CENTER_Y*2);
-        }
-        
-        private static final int CENTER_X = 100;
-        private static final int CENTER_Y = 100;
-        private static final int CENTER_RADIUS = 32;
-
-        private int floatToByte(float x) {
-            int n = java.lang.Math.round(x);
-            return n;
-        }
-        private int pinToByte(int n) {
-            if (n < 0) {
-                n = 0;
-            } else if (n > 255) {
-                n = 255;
-            }
-            return n;
-        }
-        
-        private int ave(int s, int d, float p) {
-            return s + java.lang.Math.round(p * (d - s));
-        }
-        
-        private int interpColor(int colors[], float unit) {
-            if (unit <= 0) {
-                return colors[0];
-            }
-            if (unit >= 1) {
-                return colors[colors.length - 1];
-            }
-            
-            float p = unit * (colors.length - 1);
-            int i = (int)p;
-            p -= i;
-
-            // now p is just the fractional part [0...1) and i is the index
-            int c0 = colors[i];
-            int c1 = colors[i+1];
-            int a = ave(Color.alpha(c0), Color.alpha(c1), p);
-            int r = ave(Color.red(c0), Color.red(c1), p);
-            int g = ave(Color.green(c0), Color.green(c1), p);
-            int b = ave(Color.blue(c0), Color.blue(c1), p);
-            
-            return Color.argb(a, r, g, b);
-        }
-        
-        private int rotateColor(int color, float rad) {
-            float deg = rad * 180 / 3.1415927f;
-            int r = Color.red(color);
-            int g = Color.green(color);
-            int b = Color.blue(color);
-            
-            ColorMatrix cm = new ColorMatrix();
-            ColorMatrix tmp = new ColorMatrix();
-
-            cm.setRGB2YUV();
-            tmp.setRotate(0, deg);
-            cm.postConcat(tmp);
-            tmp.setYUV2RGB();
-            cm.postConcat(tmp);
-            
-            final float[] a = cm.getArray();
-
-            int ir = floatToByte(a[0] * r +  a[1] * g +  a[2] * b);
-            int ig = floatToByte(a[5] * r +  a[6] * g +  a[7] * b);
-            int ib = floatToByte(a[10] * r + a[11] * g + a[12] * b);
-            
-            return Color.argb(Color.alpha(color), pinToByte(ir),
-                              pinToByte(ig), pinToByte(ib));
-        }
-        
-        private static final float PI = 3.1415926f;
-
-        @Override
-        public boolean onTouchEvent(MotionEvent event) {
-            float x = event.getX() - CENTER_X;
-            float y = event.getY() - CENTER_Y;
-            boolean inCenter = java.lang.Math.sqrt(x*x + y*y) <= CENTER_RADIUS;
-            
-            switch (event.getAction()) {
-                case MotionEvent.ACTION_DOWN:
-                    mTrackingCenter = inCenter;
-                    if (inCenter) {
-                        mHighlightCenter = true;
-                        invalidate();
-                        break;
-                    }
-                case MotionEvent.ACTION_MOVE:
-                    if (mTrackingCenter) {
-                        if (mHighlightCenter != inCenter) {
-                            mHighlightCenter = inCenter;
-                            invalidate();
-                        }
-                    } else {
-                        float angle = (float)java.lang.Math.atan2(y, x);
-                        // need to turn angle [-PI ... PI] into unit [0....1]
-                        float unit = angle/(2*PI);
-                        if (unit < 0) {
-                            unit += 1;
-                        }
-                        mCenterPaint.setColor(interpColor(mColors, unit));
-                        invalidate();
-                    }
-                    break;
-                case MotionEvent.ACTION_UP:
-                    if (mTrackingCenter) {
-                        if (inCenter) {
-                            mListener.colorChanged(mCenterPaint.getColor());
-                        }
-                        mTrackingCenter = false;    // so we draw w/o halo
-                        invalidate();
-                    }
-                    break;
-            }
-            return true;
-        }
-    }
-
-    public ColorPickerDialog(Context context,
-                             OnColorChangedListener listener,
-                             int initialColor) {
-        super(context);
-        
-        mListener = listener;
-        mInitialColor = initialColor;
-    }
-
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        OnColorChangedListener l = new OnColorChangedListener() {
-            public void colorChanged(int color) {
-                mListener.colorChanged(color);
-                dismiss();
-            }
-        };
-
-        setContentView(new ColorPickerView(getContext(), l, mInitialColor));
-        setTitle("Pick a Color");
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Compass.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Compass.java
deleted file mode 100644
index d2a9907..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Compass.java
+++ /dev/null
@@ -1,133 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.hardware.SensorListener;
-import android.hardware.SensorManager;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.os.SystemClock;
-import android.util.Config;
-import android.util.Log;
-import android.view.View;
-
-public class Compass extends GraphicsActivity {
-
-    private static final String TAG = "Compass";
-
-	private SensorManager mSensorManager;
-    private SampleView mView;
-    private float[] mValues;
-    
-    private final SensorListener mListener = new SensorListener() {
-    
-        public void onSensorChanged(int sensor, float[] values) {
-            if (Config.LOGD) Log.d(TAG, "sensorChanged (" + values[0] + ", " + values[1] + ", " + values[2] + ")");
-            mValues = values;
-            if (mView != null) {
-                mView.invalidate();
-            }
-        }
-
-        public void onAccuracyChanged(int sensor, int accuracy) {
-            // TODO Auto-generated method stub
-            
-        }
-    };
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        mSensorManager = (SensorManager)getSystemService(Context.SENSOR_SERVICE);
-        mView = new SampleView(this);
-        setContentView(mView);
-    }
-
-    @Override
-    protected void onResume()
-    {
-        if (Config.LOGD) Log.d(TAG, "onResume");
-        super.onResume();
-        mSensorManager.registerListener(mListener, 
-        		SensorManager.SENSOR_ORIENTATION,
-        		SensorManager.SENSOR_DELAY_GAME);
-    }
-    
-    @Override
-    protected void onStop()
-    {
-        if (Config.LOGD) Log.d(TAG, "onStop");
-        mSensorManager.unregisterListener(mListener);
-        super.onStop();
-    }
-
-    private class SampleView extends View {
-        private Paint   mPaint = new Paint();
-        private Path    mPath = new Path();
-        private boolean mAnimate;
-        private long    mNextTime;
-
-        public SampleView(Context context) {
-            super(context);
-
-            // Construct a wedge-shaped path
-            mPath.moveTo(0, -50);
-            mPath.lineTo(-20, 60);
-            mPath.lineTo(0, 50);
-            mPath.lineTo(20, 60);
-            mPath.close();
-        }
-    
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-
-            canvas.drawColor(Color.WHITE);
-            
-            paint.setAntiAlias(true);
-            paint.setColor(Color.BLACK);
-            paint.setStyle(Paint.Style.FILL);
-
-            int w = canvas.getWidth();
-            int h = canvas.getHeight();
-            int cx = w / 2;
-            int cy = h / 2;
-
-            canvas.translate(cx, cy);
-            if (mValues != null) {            
-                canvas.rotate(-mValues[0]);
-            }
-            canvas.drawPath(mPath, mPaint);
-        }
-    
-        @Override
-        protected void onAttachedToWindow() {
-            mAnimate = true;
-            super.onAttachedToWindow();
-        }
-        
-        @Override
-        protected void onDetachedFromWindow() {
-            mAnimate = false;
-            super.onDetachedFromWindow();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/CreateBitmap.java b/samples/ApiDemos/src/com/example/android/apis/graphics/CreateBitmap.java
deleted file mode 100644
index e3e5d9a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/CreateBitmap.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-import java.io.ByteArrayOutputStream;
-
-public class CreateBitmap extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static final int WIDTH = 50;
-    private static final int HEIGHT = 50;
-    private static final int STRIDE = 64;   // must be >= WIDTH
-    
-    private static int[] createColors() {
-        int[] colors = new int[STRIDE * HEIGHT];
-        for (int y = 0; y < HEIGHT; y++) {
-            for (int x = 0; x < WIDTH; x++) {
-                int r = x * 255 / (WIDTH - 1);
-                int g = y * 255 / (HEIGHT - 1);
-                int b = 255 - Math.min(r, g);
-                int a = Math.max(r, g);
-                colors[y * STRIDE + x] = (a << 24) | (r << 16) | (g << 8) | b;
-            }
-        }
-        return colors;
-    }
-        
-    private static class SampleView extends View {
-        private Bitmap[] mBitmaps;
-        private Bitmap[] mJPEG;
-        private Bitmap[] mPNG;
-        private int[]    mColors;
-        private Paint    mPaint;
-        
-        private static Bitmap codec(Bitmap src, Bitmap.CompressFormat format,
-                                    int quality) {
-            ByteArrayOutputStream os = new ByteArrayOutputStream();
-            src.compress(format, quality, os);            
-
-            byte[] array = os.toByteArray();
-            return BitmapFactory.decodeByteArray(array, 0, array.length);
-        }
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mColors = createColors();
-            int[] colors = mColors;
-
-            mBitmaps = new Bitmap[6];
-            // these three are initialized with colors[]
-            mBitmaps[0] = Bitmap.createBitmap(colors, 0, STRIDE, WIDTH, HEIGHT,
-                                              Bitmap.Config.ARGB_8888);
-            mBitmaps[1] = Bitmap.createBitmap(colors, 0, STRIDE, WIDTH, HEIGHT,
-                                              Bitmap.Config.RGB_565);
-            mBitmaps[2] = Bitmap.createBitmap(colors, 0, STRIDE, WIDTH, HEIGHT,
-                                              Bitmap.Config.ARGB_4444);
-            
-            // these three will have their colors set later
-            mBitmaps[3] = Bitmap.createBitmap(WIDTH, HEIGHT,
-                                              Bitmap.Config.ARGB_8888);
-            mBitmaps[4] = Bitmap.createBitmap(WIDTH, HEIGHT,
-                                              Bitmap.Config.RGB_565);
-            mBitmaps[5] = Bitmap.createBitmap(WIDTH, HEIGHT,
-                                              Bitmap.Config.ARGB_4444);
-            for (int i = 3; i <= 5; i++) {
-                mBitmaps[i].setPixels(colors, 0, STRIDE, 0, 0, WIDTH, HEIGHT);
-            }
-            
-            mPaint = new Paint();
-            mPaint.setDither(true);
-            
-            // now encode/decode using JPEG and PNG
-            mJPEG = new Bitmap[mBitmaps.length];
-            mPNG = new Bitmap[mBitmaps.length];
-            for (int i = 0; i < mBitmaps.length; i++) {
-                mJPEG[i] = codec(mBitmaps[i], Bitmap.CompressFormat.JPEG, 80);
-                mPNG[i] = codec(mBitmaps[i], Bitmap.CompressFormat.PNG, 0);
-            }
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            for (int i = 0; i < mBitmaps.length; i++) {
-                canvas.drawBitmap(mBitmaps[i], 0, 0, null);
-                canvas.drawBitmap(mJPEG[i], 80, 0, null);
-                canvas.drawBitmap(mPNG[i], 160, 0, null);
-                canvas.translate(0, mBitmaps[i].getHeight());
-            }
-            
-            // draw the color array directly, w/o craeting a bitmap object
-            canvas.drawBitmap(mColors, 0, STRIDE, 0, 0, WIDTH, HEIGHT,
-                              true, null);
-            canvas.translate(0, HEIGHT);
-            canvas.drawBitmap(mColors, 0, STRIDE, 0, 0, WIDTH, HEIGHT,
-                              false, mPaint);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Cube.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Cube.java
deleted file mode 100644
index bb154eb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Cube.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.IntBuffer;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * A vertex shaded cube.
- */
-class Cube
-{
-    public Cube()
-    {
-        int one = 0x10000;
-        int vertices[] = {
-                -one, -one, -one,
-                one, -one, -one,
-                one,  one, -one,
-                -one,  one, -one,
-                -one, -one,  one,
-                one, -one,  one,
-                one,  one,  one,
-                -one,  one,  one,
-        };
-
-        int colors[] = {
-                0,    0,    0,  one,
-                one,    0,    0,  one,
-                one,  one,    0,  one,
-                0,  one,    0,  one,
-                0,    0,  one,  one,
-                one,    0,  one,  one,
-                one,  one,  one,  one,
-                0,  one,  one,  one,
-        };
-
-        byte indices[] = {
-                0, 4, 5,    0, 5, 1,
-                1, 5, 6,    1, 6, 2,
-                2, 6, 7,    2, 7, 3,
-                3, 7, 4,    3, 4, 0,
-                4, 7, 6,    4, 6, 5,
-                3, 0, 1,    3, 1, 2
-        };
-
-        // Buffers to be passed to gl*Pointer() functions
-        // must be direct, i.e., they must be placed on the
-        // native heap where the garbage collector cannot
-        // move them.
-        //
-        // Buffers with multi-byte datatypes (e.g., short, int, float)
-        // must have their byte order set to native order
-
-        ByteBuffer vbb = ByteBuffer.allocateDirect(vertices.length*4);
-        vbb.order(ByteOrder.nativeOrder());
-        mVertexBuffer = vbb.asIntBuffer();
-        mVertexBuffer.put(vertices);
-        mVertexBuffer.position(0);
-
-        ByteBuffer cbb = ByteBuffer.allocateDirect(colors.length*4);
-        cbb.order(ByteOrder.nativeOrder());
-        mColorBuffer = cbb.asIntBuffer();
-        mColorBuffer.put(colors);
-        mColorBuffer.position(0);
-
-        mIndexBuffer = ByteBuffer.allocateDirect(indices.length);
-        mIndexBuffer.put(indices);
-        mIndexBuffer.position(0);
-    }
-
-    public void draw(GL10 gl)
-    {
-        gl.glFrontFace(gl.GL_CW);
-        gl.glVertexPointer(3, gl.GL_FIXED, 0, mVertexBuffer);
-        gl.glColorPointer(4, gl.GL_FIXED, 0, mColorBuffer);
-        gl.glDrawElements(gl.GL_TRIANGLES, 36, gl.GL_UNSIGNED_BYTE, mIndexBuffer);
-    }
-
-    private IntBuffer   mVertexBuffer;
-    private IntBuffer   mColorBuffer;
-    private ByteBuffer  mIndexBuffer;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/CubeRenderer.java b/samples/ApiDemos/src/com/example/android/apis/graphics/CubeRenderer.java
deleted file mode 100644
index 527e2bc..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/CubeRenderer.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-import android.opengl.GLSurfaceView;
-
-/**
- * Render a pair of tumbling cubes.
- */
-
-class CubeRenderer implements GLSurfaceView.Renderer {
-    public CubeRenderer(boolean useTranslucentBackground) {
-        mTranslucentBackground = useTranslucentBackground;
-        mCube = new Cube();
-    }
-
-    public void onDrawFrame(GL10 gl) {
-        /*
-         * Usually, the first thing one might want to do is to clear
-         * the screen. The most efficient way of doing this is to use
-         * glClear().
-         */
-
-        gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-        /*
-         * Now we're ready to draw some 3D objects
-         */
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-        gl.glTranslatef(0, 0, -3.0f);
-        gl.glRotatef(mAngle,        0, 1, 0);
-        gl.glRotatef(mAngle*0.25f,  1, 0, 0);
-
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-        gl.glEnableClientState(GL10.GL_COLOR_ARRAY);
-
-        mCube.draw(gl);
-
-        gl.glRotatef(mAngle*2.0f, 0, 1, 1);
-        gl.glTranslatef(0.5f, 0.5f, 0.5f);
-
-        mCube.draw(gl);
-
-        mAngle += 1.2f;
-    }
-
-    public int[] getConfigSpec() {
-        if (mTranslucentBackground) {
-                // We want a depth buffer and an alpha buffer
-                int[] configSpec = {
-                        EGL10.EGL_RED_SIZE,      8,
-                        EGL10.EGL_GREEN_SIZE,    8,
-                        EGL10.EGL_BLUE_SIZE,     8,
-                        EGL10.EGL_ALPHA_SIZE,    8,
-                        EGL10.EGL_DEPTH_SIZE,   16,
-                        EGL10.EGL_NONE
-                };
-                return configSpec;
-            } else {
-                // We want a depth buffer, don't care about the
-                // details of the color buffer.
-                int[] configSpec = {
-                        EGL10.EGL_DEPTH_SIZE,   16,
-                        EGL10.EGL_NONE
-                };
-                return configSpec;
-            }
-    }
-
-    public void onSurfaceChanged(GL10 gl, int width, int height) {
-         gl.glViewport(0, 0, width, height);
-
-         /*
-          * Set our projection matrix. This doesn't have to be done
-          * each time we draw, but usually a new projection needs to
-          * be set when the viewport is resized.
-          */
-
-         float ratio = (float) width / height;
-         gl.glMatrixMode(GL10.GL_PROJECTION);
-         gl.glLoadIdentity();
-         gl.glFrustumf(-ratio, ratio, -1, 1, 1, 10);
-    }
-
-    public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        /*
-         * Some one-time OpenGL initialization can be made here
-         * probably based on features of this particular context
-         */
-         gl.glHint(GL10.GL_PERSPECTIVE_CORRECTION_HINT,
-                 GL10.GL_FASTEST);
-
-         if (mTranslucentBackground) {
-             gl.glClearColor(0,0,0,0);
-         } else {
-             gl.glClearColor(1,1,1,1);
-         }
-         gl.glEnable(GL10.GL_CULL_FACE);
-         gl.glShadeModel(GL10.GL_SMOOTH);
-         gl.glEnable(GL10.GL_DEPTH_TEST);
-    }
-    private boolean mTranslucentBackground;
-    private Cube mCube;
-    private float mAngle;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/DrawPoints.java b/samples/ApiDemos/src/com/example/android/apis/graphics/DrawPoints.java
deleted file mode 100644
index cbe6373..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/DrawPoints.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class DrawPoints extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint   mPaint = new Paint();
-        private float[] mPts;
-
-        private static final float SIZE = 300;
-        private static final int SEGS = 32;
-        private static final int X = 0;
-        private static final int Y = 1;
-        
-        private void buildPoints() {
-            final int ptCount = (SEGS + 1) * 2;
-            mPts = new float[ptCount * 2];
-            
-            float value = 0;
-            final float delta = SIZE / SEGS;
-            for (int i = 0; i <= SEGS; i++) {
-                mPts[i*4 + X] = SIZE - value;
-                mPts[i*4 + Y] = 0;
-                mPts[i*4 + X + 2] = 0;
-                mPts[i*4 + Y + 2] = value;
-                value += delta;
-            }
-        }
-    
-        public SampleView(Context context) {
-            super(context);
-            
-            buildPoints();
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-            
-            canvas.translate(10, 10);
-
-            canvas.drawColor(Color.WHITE);
-
-            paint.setColor(Color.RED);
-            paint.setStrokeWidth(0);
-            canvas.drawLines(mPts, paint);
-            
-            paint.setColor(Color.BLUE);
-            paint.setStrokeWidth(3);
-            canvas.drawPoints(mPts, paint);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/FingerPaint.java b/samples/ApiDemos/src/com/example/android/apis/graphics/FingerPaint.java
deleted file mode 100644
index 867da4c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/FingerPaint.java
+++ /dev/null
@@ -1,209 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.MotionEvent;
-import android.view.View;
-
-public class FingerPaint extends GraphicsActivity
-        implements ColorPickerDialog.OnColorChangedListener {    
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new MyView(this));
-
-        mPaint = new Paint();
-        mPaint.setAntiAlias(true);
-        mPaint.setDither(true);
-        mPaint.setColor(0xFFFF0000);
-        mPaint.setStyle(Paint.Style.STROKE);
-        mPaint.setStrokeJoin(Paint.Join.ROUND);
-        mPaint.setStrokeCap(Paint.Cap.ROUND);
-        mPaint.setStrokeWidth(12);
-        
-        mEmboss = new EmbossMaskFilter(new float[] { 1, 1, 1 },
-                                       0.4f, 6, 3.5f);
-
-        mBlur = new BlurMaskFilter(8, BlurMaskFilter.Blur.NORMAL);
-    }
-    
-    private Paint       mPaint;
-    private MaskFilter  mEmboss;
-    private MaskFilter  mBlur;
-    
-    public void colorChanged(int color) {
-        mPaint.setColor(color);
-    }
-
-    public class MyView extends View {
-        
-        private static final float MINP = 0.25f;
-        private static final float MAXP = 0.75f;
-        
-        private Bitmap  mBitmap;
-        private Canvas  mCanvas;
-        private Path    mPath;
-        private Paint   mBitmapPaint;
-        
-        public MyView(Context c) {
-            super(c);
-            
-            mBitmap = Bitmap.createBitmap(320, 480, Bitmap.Config.ARGB_8888);
-            mCanvas = new Canvas(mBitmap);
-            mPath = new Path();
-            mBitmapPaint = new Paint(Paint.DITHER_FLAG);
-        }
-
-        @Override
-        protected void onSizeChanged(int w, int h, int oldw, int oldh) {
-            super.onSizeChanged(w, h, oldw, oldh);
-        }
-        
-        @Override
-        protected void onDraw(Canvas canvas) {
-            canvas.drawColor(0xFFAAAAAA);
-            
-            canvas.drawBitmap(mBitmap, 0, 0, mBitmapPaint);
-            
-            canvas.drawPath(mPath, mPaint);
-        }
-        
-        private float mX, mY;
-        private static final float TOUCH_TOLERANCE = 4;
-        
-        private void touch_start(float x, float y) {
-            mPath.reset();
-            mPath.moveTo(x, y);
-            mX = x;
-            mY = y;
-        }
-        private void touch_move(float x, float y) {
-            float dx = Math.abs(x - mX);
-            float dy = Math.abs(y - mY);
-            if (dx >= TOUCH_TOLERANCE || dy >= TOUCH_TOLERANCE) {
-                mPath.quadTo(mX, mY, (x + mX)/2, (y + mY)/2);
-                mX = x;
-                mY = y;
-            }
-        }
-        private void touch_up() {
-            mPath.lineTo(mX, mY);
-            // commit the path to our offscreen
-            mCanvas.drawPath(mPath, mPaint);
-            // kill this so we don't double draw
-            mPath.reset();
-        }
-        
-        @Override
-        public boolean onTouchEvent(MotionEvent event) {
-            float x = event.getX();
-            float y = event.getY();
-            
-            switch (event.getAction()) {
-                case MotionEvent.ACTION_DOWN:
-                    touch_start(x, y);
-                    invalidate();
-                    break;
-                case MotionEvent.ACTION_MOVE:
-                    touch_move(x, y);
-                    invalidate();
-                    break;
-                case MotionEvent.ACTION_UP:
-                    touch_up();
-                    invalidate();
-                    break;
-            }
-            return true;
-        }
-    }
-    
-    private static final int COLOR_MENU_ID = Menu.FIRST;
-    private static final int EMBOSS_MENU_ID = Menu.FIRST + 1;
-    private static final int BLUR_MENU_ID = Menu.FIRST + 2;
-    private static final int ERASE_MENU_ID = Menu.FIRST + 3;
-    private static final int SRCATOP_MENU_ID = Menu.FIRST + 4;
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, COLOR_MENU_ID, 0, "Color").setShortcut('3', 'c');
-        menu.add(0, EMBOSS_MENU_ID, 0, "Emboss").setShortcut('4', 's');
-        menu.add(0, BLUR_MENU_ID, 0, "Blur").setShortcut('5', 'z');
-        menu.add(0, ERASE_MENU_ID, 0, "Erase").setShortcut('5', 'z');
-        menu.add(0, SRCATOP_MENU_ID, 0, "SrcATop").setShortcut('5', 'z');
-
-        /****   Is this the mechanism to extend with filter effects?
-        Intent intent = new Intent(null, getIntent().getData());
-        intent.addCategory(Intent.CATEGORY_ALTERNATIVE);
-        menu.addIntentOptions(
-                              Menu.ALTERNATIVE, 0,
-                              new ComponentName(this, NotesList.class),
-                              null, intent, 0, null);
-        *****/
-        return true;
-    }
-    
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-        return true;
-    }
-    
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        mPaint.setXfermode(null);
-        mPaint.setAlpha(0xFF);
-
-        switch (item.getItemId()) {
-            case COLOR_MENU_ID:
-                new ColorPickerDialog(this, this, mPaint.getColor()).show();
-                return true;
-            case EMBOSS_MENU_ID:
-                if (mPaint.getMaskFilter() != mEmboss) {
-                    mPaint.setMaskFilter(mEmboss);
-                } else {
-                    mPaint.setMaskFilter(null);
-                }
-                return true;
-            case BLUR_MENU_ID:
-                if (mPaint.getMaskFilter() != mBlur) {
-                    mPaint.setMaskFilter(mBlur);
-                } else {
-                    mPaint.setMaskFilter(null);
-                }
-                return true;
-            case ERASE_MENU_ID:
-                mPaint.setXfermode(new PorterDuffXfermode(
-                                                        PorterDuff.Mode.CLEAR));
-                return true;
-            case SRCATOP_MENU_ID:
-                mPaint.setXfermode(new PorterDuffXfermode(
-                                                    PorterDuff.Mode.SRC_ATOP));
-                mPaint.setAlpha(0x80);
-                return true;
-        }
-        return super.onOptionsItemSelected(item);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/GLSurfaceViewActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/GLSurfaceViewActivity.java
deleted file mode 100644
index f852186..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/GLSurfaceViewActivity.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-
-/**
- * Wrapper activity demonstrating the use of {@link GLSurfaceView}, a view
- * that uses OpenGL drawing into a dedicated surface.
- */
-public class GLSurfaceViewActivity extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Create our Preview view and set it as the content of our
-        // Activity
-        mGLSurfaceView = new GLSurfaceView(this);
-        mGLSurfaceView.setRenderer(new CubeRenderer(false));
-        setContentView(mGLSurfaceView);
-    }
-
-    @Override
-    protected void onResume() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onResume();
-        mGLSurfaceView.onResume();
-    }
-
-    @Override
-    protected void onPause() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onPause();
-        mGLSurfaceView.onPause();
-    }
-
-    private GLSurfaceView mGLSurfaceView;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/GradientDrawable1.java b/samples/ApiDemos/src/com/example/android/apis/graphics/GradientDrawable1.java
deleted file mode 100644
index eb6d47d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/GradientDrawable1.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class GradientDrawable1 extends GraphicsActivity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.shape_drawable_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/GraphicsActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/GraphicsActivity.java
deleted file mode 100644
index 023c0d7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/GraphicsActivity.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.Window;
-
-class GraphicsActivity extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-    }
-
-    @Override
-    public void setContentView(View view) {
-        if (false) { // set to true to test Picture
-            ViewGroup vg = new PictureLayout(this);
-            vg.addView(view);
-            view = vg;
-        }
-        
-        super.setContentView(view);
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Layers.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Layers.java
deleted file mode 100644
index d9f5db0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Layers.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.*;
-
-public class Layers extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private static final int LAYER_FLAGS = Canvas.MATRIX_SAVE_FLAG |
-                                            Canvas.CLIP_SAVE_FLAG |
-                                            Canvas.HAS_ALPHA_LAYER_SAVE_FLAG |
-                                            Canvas.FULL_COLOR_LAYER_SAVE_FLAG |
-                                            Canvas.CLIP_TO_LAYER_SAVE_FLAG;
-
-        private Paint mPaint;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);            
-            
-            canvas.translate(10, 10);
-            
-            canvas.saveLayerAlpha(0, 0, 200, 200, 0x88, LAYER_FLAGS);
-            
-            mPaint.setColor(Color.RED);
-            canvas.drawCircle(75, 75, 75, mPaint);
-            mPaint.setColor(Color.BLUE);
-            canvas.drawCircle(125, 125, 75, mPaint);
-            
-            canvas.restore();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/MeasureText.java b/samples/ApiDemos/src/com/example/android/apis/graphics/MeasureText.java
deleted file mode 100644
index e159efe..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/MeasureText.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-public class MeasureText extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static final int WIDTH = 50;
-    private static final int HEIGHT = 50;
-    private static final int STRIDE = 64;   // must be >= WIDTH
-    
-    private static int[] createColors() {
-        int[] colors = new int[STRIDE * HEIGHT];
-        for (int y = 0; y < HEIGHT; y++) {
-            for (int x = 0; x < WIDTH; x++) {
-                int r = x * 255 / (WIDTH - 1);
-                int g = y * 255 / (HEIGHT - 1);
-                int b = 255 - Math.min(r, g);
-                int a = Math.max(r, g);
-                colors[y * STRIDE + x] = (a << 24) | (r << 16) | (g << 8) | b;
-            }
-        }
-        return colors;
-    }
-    
-    private static class SampleView extends View {
-        private Paint   mPaint;
-        private float   mOriginX = 10;
-        private float   mOriginY = 80;
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-            mPaint.setStrokeWidth(5);
-            mPaint.setStrokeCap(Paint.Cap.ROUND);
-            mPaint.setTextSize(64);
-            mPaint.setTypeface(Typeface.create(Typeface.SERIF,
-                                               Typeface.ITALIC));
-        }
-        
-        private void showText(Canvas canvas, String text, Paint.Align align) {
-         //   mPaint.setTextAlign(align);
-            
-            Rect    bounds = new Rect();
-            float[] widths = new float[text.length()];
-
-            int count = mPaint.getTextWidths(text, 0, text.length(), widths);
-            float w = mPaint.measureText(text, 0, text.length());
-            mPaint.getTextBounds(text, 0, text.length(), bounds);
-            
-            mPaint.setColor(0xFF88FF88);
-            canvas.drawRect(bounds, mPaint);
-            mPaint.setColor(Color.BLACK);
-            canvas.drawText(text, 0, 0, mPaint);
-            
-            float[] pts = new float[2 + count*2];
-            float x = 0;
-            float y = 0;
-            pts[0] = x;
-            pts[1] = y;
-            for (int i = 0; i < count; i++) {
-                x += widths[i];
-                pts[2 + i*2] = x;
-                pts[2 + i*2 + 1] = y;
-            }
-            mPaint.setColor(Color.RED);
-            mPaint.setStrokeWidth(0);
-            canvas.drawLine(0, 0, w, 0, mPaint);
-            mPaint.setStrokeWidth(5);
-            canvas.drawPoints(pts, 0, (count + 1) << 1, mPaint);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-            
-            canvas.translate(mOriginX, mOriginY);
-            
-            showText(canvas, "Measure", Paint.Align.LEFT);
-            canvas.translate(0, 80);
-            showText(canvas, "wiggy!", Paint.Align.CENTER);
-            canvas.translate(0, 80);
-            showText(canvas, "Text", Paint.Align.RIGHT);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/PathEffects.java b/samples/ApiDemos/src/com/example/android/apis/graphics/PathEffects.java
deleted file mode 100644
index 80ddf38..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/PathEffects.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-public class PathEffects extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mPaint;
-        private Path mPath;
-        private PathEffect[] mEffects;
-        private int[] mColors;
-        private float mPhase;
-
-        private static PathEffect makeDash(float phase) {
-            return new DashPathEffect(new float[] { 15, 5, 8, 5 }, phase);
-        }
-        
-        private static void makeEffects(PathEffect[] e, float phase) {
-            e[0] = null;     // no effect
-            e[1] = new CornerPathEffect(10);
-            e[2] = new DashPathEffect(new float[] {10, 5, 5, 5}, phase);
-            e[3] = new PathDashPathEffect(makePathDash(), 12, phase,
-                                          PathDashPathEffect.Style.ROTATE);
-            e[4] = new ComposePathEffect(e[2], e[1]);
-            e[5] = new ComposePathEffect(e[3], e[1]);
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setStrokeWidth(6);
-            
-            mPath = makeFollowPath();
-            
-            mEffects = new PathEffect[6];
-            
-            mColors = new int[] { Color.BLACK, Color.RED, Color.BLUE,
-                                  Color.GREEN, Color.MAGENTA, Color.BLACK
-                                };
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-            
-            RectF bounds = new RectF();
-            mPath.computeBounds(bounds, false);
-            canvas.translate(10 - bounds.left, 10 - bounds.top);
-            
-            makeEffects(mEffects, mPhase);
-            mPhase += 1;
-            invalidate();
-
-            for (int i = 0; i < mEffects.length; i++) {
-                mPaint.setPathEffect(mEffects[i]);
-                mPaint.setColor(mColors[i]);
-                canvas.drawPath(mPath, mPaint);
-                canvas.translate(0, 28);
-            }
-        }
-        
-        @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-            switch (keyCode) {
-                case KeyEvent.KEYCODE_DPAD_CENTER:
-                    mPath = makeFollowPath();
-                    return true;
-            }
-            return super.onKeyDown(keyCode, event);
-        }
-
-        private static Path makeFollowPath() {
-            Path p = new Path();
-            p.moveTo(0, 0);
-            for (int i = 1; i <= 15; i++) {
-                p.lineTo(i*20, (float)Math.random() * 35);
-            }
-            return p;
-        }
-        
-        private static Path makePathDash() {
-            Path p = new Path();
-            p.moveTo(4, 0);
-            p.lineTo(0, -4);
-            p.lineTo(8, -4);
-            p.lineTo(12, 0);
-            p.lineTo(8, 4);
-            p.lineTo(0, 4);
-            return p;
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/PathFillTypes.java b/samples/ApiDemos/src/com/example/android/apis/graphics/PathFillTypes.java
deleted file mode 100644
index 78dba26..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/PathFillTypes.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-//import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-public class PathFillTypes extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private Path mPath;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            mPath = new Path();
-            mPath.addCircle(40, 40, 45, Path.Direction.CCW);
-            mPath.addCircle(80, 80, 45, Path.Direction.CCW);
-        }
-        
-        private void showPath(Canvas canvas, int x, int y, Path.FillType ft,
-                              Paint paint) {
-            canvas.save();
-            canvas.translate(x, y);
-            canvas.clipRect(0, 0, 120, 120);
-            canvas.drawColor(Color.WHITE);
-            mPath.setFillType(ft);
-            canvas.drawPath(mPath, paint);
-            canvas.restore();
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-
-            canvas.drawColor(0xFFCCCCCC);
-            
-            canvas.translate(20, 20);
-            
-            paint.setAntiAlias(true);
-
-            showPath(canvas, 0, 0, Path.FillType.WINDING, paint);
-            showPath(canvas, 160, 0, Path.FillType.EVEN_ODD, paint);
-            showPath(canvas, 0, 160, Path.FillType.INVERSE_WINDING, paint);
-            showPath(canvas, 160, 160, Path.FillType.INVERSE_EVEN_ODD, paint);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Patterns.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Patterns.java
deleted file mode 100644
index d2a51ff..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Patterns.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.MotionEvent;
-import android.view.*;
-
-public class Patterns extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static Bitmap makeBitmap1() {
-        Bitmap bm = Bitmap.createBitmap(40, 40, Bitmap.Config.RGB_565);
-        Canvas c = new Canvas(bm);
-        c.drawColor(Color.RED);
-        Paint p = new Paint();
-        p.setColor(Color.BLUE);
-        c.drawRect(5, 5, 35, 35, p);
-        return bm;
-    }
-    
-    private static Bitmap makeBitmap2() {
-        Bitmap bm = Bitmap.createBitmap(64, 64, Bitmap.Config.ARGB_8888);
-        Canvas c = new Canvas(bm);
-        Paint p = new Paint(Paint.ANTI_ALIAS_FLAG);
-        p.setColor(Color.GREEN);
-        p.setAlpha(0xCC);
-        c.drawCircle(32, 32, 27, p);
-        return bm;
-    }
-    
-    private static class SampleView extends View {
-        private final Shader mShader1;
-        private final Shader mShader2;
-        private final Paint mPaint;
-        private final DrawFilter mFastDF;
-        
-        private float mTouchStartX;
-        private float mTouchStartY;
-        private float mTouchCurrX;
-        private float mTouchCurrY;
-        private DrawFilter mDF;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            mFastDF = new PaintFlagsDrawFilter(Paint.FILTER_BITMAP_FLAG |
-                                               Paint.DITHER_FLAG,
-                                               0);
-    
-            mShader1 = new BitmapShader(makeBitmap1(), Shader.TileMode.REPEAT,
-                                        Shader.TileMode.REPEAT);
-            mShader2 = new BitmapShader(makeBitmap2(), Shader.TileMode.REPEAT,
-                                        Shader.TileMode.REPEAT);
-            
-            Matrix m = new Matrix();
-            m.setRotate(30);
-            mShader2.setLocalMatrix(m);
-            
-            mPaint = new Paint(Paint.FILTER_BITMAP_FLAG);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.setDrawFilter(mDF);
-
-            mPaint.setShader(mShader1);
-            canvas.drawPaint(mPaint);
-            
-            canvas.translate(mTouchCurrX - mTouchStartX,
-                             mTouchCurrY - mTouchStartY);
-
-            mPaint.setShader(mShader2);
-            canvas.drawPaint(mPaint);
-        }
-
-        @Override
-        public boolean onTouchEvent(MotionEvent event) {
-            float x = event.getX();
-            float y = event.getY();
-            
-            switch (event.getAction()) {
-                case MotionEvent.ACTION_DOWN:
-                    mTouchStartX = mTouchCurrX = x;
-                    mTouchStartY = mTouchCurrY = y;
-                    mDF = mFastDF;
-                    invalidate();
-                    break;
-                case MotionEvent.ACTION_MOVE:
-                    mTouchCurrX = x;
-                    mTouchCurrY = y;
-                    invalidate();
-                    break;
-                case MotionEvent.ACTION_UP:
-                    mDF = null;
-                    invalidate();
-                    break;
-            }
-            return true;
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/PictureLayout.java b/samples/ApiDemos/src/com/example/android/apis/graphics/PictureLayout.java
deleted file mode 100644
index 9bdb49a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/PictureLayout.java
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.content.Context;
-import android.graphics.Canvas;
-import android.graphics.Picture;
-import android.graphics.Rect;
-import android.graphics.drawable.Drawable;
-import android.util.AttributeSet;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.ViewParent;
-
-
-public class PictureLayout extends ViewGroup {
-    private final Picture mPicture = new Picture();
-
-    public PictureLayout(Context context) {
-        super(context);
-    }
-
-    public PictureLayout(Context context, AttributeSet attrs) {
-        super(context, attrs);
-    }    
-
-    @Override
-    public void addView(View child) {
-        if (getChildCount() > 1) {
-            throw new IllegalStateException("PictureLayout can host only one direct child");
-        }
-
-        super.addView(child);
-    }
-
-    @Override
-    public void addView(View child, int index) {
-        if (getChildCount() > 1) {
-            throw new IllegalStateException("PictureLayout can host only one direct child");
-        }
-
-        super.addView(child, index);
-    }
-
-    @Override
-    public void addView(View child, LayoutParams params) {
-        if (getChildCount() > 1) {
-            throw new IllegalStateException("PictureLayout can host only one direct child");
-        }
-
-        super.addView(child, params);
-    }
-
-    @Override
-    public void addView(View child, int index, LayoutParams params) {
-        if (getChildCount() > 1) {
-            throw new IllegalStateException("PictureLayout can host only one direct child");
-        }
-
-        super.addView(child, index, params);
-    }
-
-    @Override
-    protected LayoutParams generateDefaultLayoutParams() {
-        return new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
-    }
-
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        final int count = getChildCount();
-
-        int maxHeight = 0;
-        int maxWidth = 0;
-
-        for (int i = 0; i < count; i++) {
-            final View child = getChildAt(i);
-            if (child.getVisibility() != GONE) {
-                measureChild(child, widthMeasureSpec, heightMeasureSpec);
-            }
-        }
-
-        maxWidth += getPaddingLeft() + getPaddingRight();
-        maxHeight += getPaddingTop() + getPaddingBottom();
-
-        Drawable drawable = getBackground();
-        if (drawable != null) {
-            maxHeight = Math.max(maxHeight, drawable.getMinimumHeight());
-            maxWidth = Math.max(maxWidth, drawable.getMinimumWidth());
-        }
-
-        setMeasuredDimension(resolveSize(maxWidth, widthMeasureSpec),
-                resolveSize(maxHeight, heightMeasureSpec));
-    }
-    
-    private void drawPict(Canvas canvas, int x, int y, int w, int h,
-                          float sx, float sy) {
-        canvas.save();
-        canvas.translate(x, y);
-        canvas.clipRect(0, 0, w, h);
-        canvas.scale(0.5f, 0.5f);
-        canvas.scale(sx, sy, w, h);
-        canvas.drawPicture(mPicture);
-        canvas.restore();
-    }
-
-    @Override
-    protected void dispatchDraw(Canvas canvas) {
-        super.dispatchDraw(mPicture.beginRecording(getWidth(), getHeight()));
-        mPicture.endRecording();
-        
-        int x = getWidth()/2;
-        int y = getHeight()/2;
-        
-        if (false) {
-            canvas.drawPicture(mPicture);
-        } else {
-            drawPict(canvas, 0, 0, x, y,  1,  1);
-            drawPict(canvas, x, 0, x, y, -1,  1);
-            drawPict(canvas, 0, y, x, y,  1, -1);
-            drawPict(canvas, x, y, x, y, -1, -1);
-        }
-    }
-
-    @Override
-    public ViewParent invalidateChildInParent(int[] location, Rect dirty) {
-        location[0] = getLeft();
-        location[1] = getTop();
-        dirty.set(0, 0, getWidth(), getHeight());
-        return getParent();
-    }
-
-    @Override
-    protected void onLayout(boolean changed, int l, int t, int r, int b) {
-        final int count = super.getChildCount();
-
-        for (int i = 0; i < count; i++) {
-            final View child = getChildAt(i);
-            if (child.getVisibility() != GONE) {
-                final int childLeft = getPaddingLeft();
-                final int childTop = getPaddingTop();
-                child.layout(childLeft, childTop,
-                        childLeft + child.getMeasuredWidth(),
-                        childTop + child.getMeasuredHeight());
-
-            }
-        }
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Pictures.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Pictures.java
deleted file mode 100644
index 1bd0a8c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Pictures.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.Drawable;
-import android.graphics.drawable.PictureDrawable;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-import java.io.*;
-
-public class Pictures extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Picture mPicture;
-        private Drawable mDrawable;
-
-        static void drawSomething(Canvas canvas) {
-            Paint p = new Paint(Paint.ANTI_ALIAS_FLAG);
-            
-            p.setColor(0x88FF0000);
-            canvas.drawCircle(50, 50, 40, p);
-            
-            p.setColor(Color.GREEN);
-            p.setTextSize(30);
-            canvas.drawText("Pictures", 60, 60, p);
-        }
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            mPicture = new Picture();
-            drawSomething(mPicture.beginRecording(200, 100));
-            mPicture.endRecording();
-            
-            mDrawable = new PictureDrawable(mPicture);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            canvas.drawPicture(mPicture);
-            
-            canvas.drawPicture(mPicture, new RectF(0, 100, getWidth(), 200));
-            
-            mDrawable.setBounds(0, 200, getWidth(), 300);
-            mDrawable.draw(canvas);
-            
-            ByteArrayOutputStream os = new ByteArrayOutputStream();
-            mPicture.writeToStream(os);
-            InputStream is = new ByteArrayInputStream(os.toByteArray());
-            canvas.translate(0, 300);
-            canvas.drawPicture(Picture.createFromStream(is));
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/PolyToPoly.java b/samples/ApiDemos/src/com/example/android/apis/graphics/PolyToPoly.java
deleted file mode 100644
index 15d92de..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/PolyToPoly.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-//import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class PolyToPoly extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint   mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private Matrix  mMatrix = new Matrix();
-        private Paint.FontMetrics mFontMetrics;
-
-        private void doDraw(Canvas canvas, float src[], float dst[]) {
-            canvas.save();
-            mMatrix.setPolyToPoly(src, 0, dst, 0, src.length >> 1);
-            canvas.concat(mMatrix);
-            
-            mPaint.setColor(Color.GRAY);
-            mPaint.setStyle(Paint.Style.STROKE);
-            canvas.drawRect(0, 0, 64, 64, mPaint);
-            canvas.drawLine(0, 0, 64, 64, mPaint);
-            canvas.drawLine(0, 64, 64, 0, mPaint);
-            
-            mPaint.setColor(Color.RED);
-            mPaint.setStyle(Paint.Style.FILL);
-            // how to draw the text center on our square
-            // centering in X is easy... use alignment (and X at midpoint)
-            float x = 64/2;
-            // centering in Y, we need to measure ascent/descent first
-            float y = 64/2 - (mFontMetrics.ascent + mFontMetrics.descent)/2;
-            canvas.drawText(src.length/2 + "", x, y, mPaint);
-            
-            canvas.restore();
-        }
-
-        public SampleView(Context context) {
-            super(context);
-
-            // for when the style is STROKE
-            mPaint.setStrokeWidth(4);
-            // for when we draw text
-            mPaint.setTextSize(40);
-            mPaint.setTextAlign(Paint.Align.CENTER);
-            mFontMetrics = mPaint.getFontMetrics();
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-
-            canvas.drawColor(Color.WHITE);
-
-            canvas.save();
-            canvas.translate(10, 10);
-            // translate (1 point)
-            doDraw(canvas, new float[] { 0, 0 }, new float[] { 5, 5 });
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 10);
-            // rotate/uniform-scale (2 points)
-            doDraw(canvas, new float[] { 32, 32, 64, 32 },
-                           new float[] { 32, 32, 64, 48 });
-            canvas.restore();
-
-            canvas.save();
-            canvas.translate(10, 110);
-            // rotate/skew (3 points)
-            doDraw(canvas, new float[] { 0, 0, 64, 0, 0, 64 },
-                           new float[] { 0, 0, 96, 0, 24, 64 });
-            canvas.restore();
-
-            canvas.save();
-            canvas.translate(160, 110);
-            // perspective (4 points)
-            doDraw(canvas, new float[] { 0, 0, 64, 0, 64, 64, 0, 64 },
-                           new float[] { 0, 0, 96, 0, 64, 96, 0, 64 });
-            canvas.restore();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/ProxyDrawable.java b/samples/ApiDemos/src/com/example/android/apis/graphics/ProxyDrawable.java
deleted file mode 100644
index d264134..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/ProxyDrawable.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.graphics.Canvas;
-import android.graphics.ColorFilter;
-import android.graphics.PixelFormat;
-import android.graphics.drawable.Drawable;
-
-public class ProxyDrawable extends Drawable {
-    
-    private Drawable mProxy;
-    private boolean mMutated;
-
-    public ProxyDrawable(Drawable target) {
-        mProxy = target;
-    }
-    
-    public Drawable getProxy() {
-        return mProxy;
-    }
-    
-    public void setProxy(Drawable proxy) {
-        if (proxy != this) {
-            mProxy = proxy;
-        }
-    }
-
-    @Override
-    public void draw(Canvas canvas) {
-        if (mProxy != null) {
-            mProxy.draw(canvas);
-        }
-    }
-    
-    @Override
-    public int getIntrinsicWidth() {
-        return mProxy != null ? mProxy.getIntrinsicWidth() : -1;
-    }
-    
-    @Override
-    public int getIntrinsicHeight() {
-        return mProxy != null ? mProxy.getIntrinsicHeight() : -1;
-    }
-    
-    @Override
-    public int getOpacity() {
-        return mProxy != null ? mProxy.getOpacity() : PixelFormat.TRANSPARENT;
-    }
-    
-    @Override
-    public void setFilterBitmap(boolean filter) {
-        if (mProxy != null) {
-            mProxy.setFilterBitmap(filter);
-        }
-    }
-    
-    @Override
-    public void setDither(boolean dither) {
-        if (mProxy != null) {
-            mProxy.setDither(dither);
-        }
-    }
-    
-    @Override
-    public void setColorFilter(ColorFilter colorFilter) {
-        if (mProxy != null) {
-            mProxy.setColorFilter(colorFilter);
-        }
-    }
-    
-    @Override
-    public void setAlpha(int alpha) {
-        if (mProxy != null) {
-            mProxy.setAlpha(alpha);
-        }
-    }
-
-    @Override
-    public Drawable mutate() {
-        if (mProxy != null && !mMutated && super.mutate() == this) {
-            mProxy.mutate();
-            mMutated = true;
-        }
-        return this;
-    }
-}
-    
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Regions.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Regions.java
deleted file mode 100644
index 833274b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Regions.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class Regions extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private final Paint mPaint = new Paint();
-        private final Rect  mRect1 = new Rect();
-        private final Rect  mRect2 = new Rect();
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mPaint.setAntiAlias(true);
-            mPaint.setTextSize(16);
-            mPaint.setTextAlign(Paint.Align.CENTER);
-            
-            mRect1.set(10, 10, 100, 80);
-            mRect2.set(50, 50, 130, 110);
-        }
-
-        private void drawOriginalRects(Canvas canvas, int alpha) {
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setColor(Color.RED);
-            mPaint.setAlpha(alpha);
-            drawCentered(canvas, mRect1, mPaint);
-            mPaint.setColor(Color.BLUE);
-            mPaint.setAlpha(alpha);
-            drawCentered(canvas, mRect2, mPaint);
-            
-            // restore style
-            mPaint.setStyle(Paint.Style.FILL);
-        }
-        
-        private void drawRgn(Canvas canvas, int color, String str, Region.Op op) {
-            if (str != null) {
-                mPaint.setColor(Color.BLACK);
-                canvas.drawText(str, 80, 24, mPaint);
-            }
-            
-            Region rgn = new Region();
-            rgn.set(mRect1);
-            rgn.op(mRect2, op);
-            
-            mPaint.setColor(color);
-            RegionIterator iter = new RegionIterator(rgn);
-            Rect r = new Rect();
-            
-            canvas.translate(0, 30);
-            mPaint.setColor(color);
-            while (iter.next(r)) {
-                canvas.drawRect(r, mPaint);
-            }
-            drawOriginalRects(canvas, 0x80);
-        }
-        
-        private static void drawCentered(Canvas c, Rect r, Paint p) {
-            float inset = p.getStrokeWidth() * 0.5f;
-            if (inset == 0) {   // catch hairlines
-                inset = 0.5f;
-            }
-            c.drawRect(r.left + inset, r.top + inset,
-                       r.right - inset, r.bottom - inset, p);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.GRAY);            
-
-            canvas.save();
-            canvas.translate(80, 5);
-            drawOriginalRects(canvas, 0xFF);
-            canvas.restore();
-            
-            mPaint.setStyle(Paint.Style.FILL);
-            
-            canvas.save();
-            canvas.translate(0, 140);
-            drawRgn(canvas, Color.RED, "Union", Region.Op.UNION);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(0, 280);
-            drawRgn(canvas, Color.BLUE, "Xor", Region.Op.XOR);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 140);
-            drawRgn(canvas, Color.GREEN, "Difference", Region.Op.DIFFERENCE);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(160, 280);
-            drawRgn(canvas, Color.WHITE, "Intersect", Region.Op.INTERSECT);
-            canvas.restore();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/RoundRects.java b/samples/ApiDemos/src/com/example/android/apis/graphics/RoundRects.java
deleted file mode 100644
index b0ff0359..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/RoundRects.java
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-public class RoundRects extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Path    mPath;
-        private Paint   mPaint;
-        private Rect    mRect;
-        private GradientDrawable mDrawable;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-
-            mPath = new Path();
-            mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mRect = new Rect(0, 0, 120, 120);
-            
-            mDrawable = new GradientDrawable(GradientDrawable.Orientation.TL_BR,
-                                             new int[] { 0xFFFF0000, 0xFF00FF00,
-                                                 0xFF0000FF });
-            mDrawable.setShape(GradientDrawable.RECTANGLE);
-            mDrawable.setGradientRadius((float)(Math.sqrt(2) * 60));
-        }
-        
-        static void setCornerRadii(GradientDrawable drawable, float r0,
-                                   float r1, float r2, float r3) {
-            drawable.setCornerRadii(new float[] { r0, r0, r1, r1,
-                                                  r2, r2, r3, r3 });
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            
-            mDrawable.setBounds(mRect);
-
-            float r = 16;
-            
-            canvas.save();
-            canvas.translate(10, 10);
-            mDrawable.setGradientType(GradientDrawable.LINEAR_GRADIENT);
-            setCornerRadii(mDrawable, r, r, 0, 0);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(10 + mRect.width() + 10, 10);
-            mDrawable.setGradientType(GradientDrawable.RADIAL_GRADIENT);
-            setCornerRadii(mDrawable, 0, 0, r, r);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-            canvas.translate(0, mRect.height() + 10);
-    
-            canvas.save();
-            canvas.translate(10, 10);
-            mDrawable.setGradientType(GradientDrawable.SWEEP_GRADIENT);
-            setCornerRadii(mDrawable, 0, r, r, 0);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(10 + mRect.width() + 10, 10);
-            mDrawable.setGradientType(GradientDrawable.LINEAR_GRADIENT);
-            setCornerRadii(mDrawable, r, 0, 0, r);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-            canvas.translate(0, mRect.height() + 10);
-            
-            canvas.save();
-            canvas.translate(10, 10);
-            mDrawable.setGradientType(GradientDrawable.RADIAL_GRADIENT);
-            setCornerRadii(mDrawable, r, 0, r, 0);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-            canvas.save();
-            canvas.translate(10 + mRect.width() + 10, 10);
-            mDrawable.setGradientType(GradientDrawable.SWEEP_GRADIENT);
-            setCornerRadii(mDrawable, 0, r, 0, r);
-            mDrawable.draw(canvas);
-            canvas.restore();
-            
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/ScaleToFit.java b/samples/ApiDemos/src/com/example/android/apis/graphics/ScaleToFit.java
deleted file mode 100644
index f55e55b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/ScaleToFit.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class ScaleToFit extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private final Paint   mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private final Paint   mHairPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private final Paint   mLabelPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private final Matrix  mMatrix = new Matrix();
-        private final RectF   mSrcR = new RectF();
-        
-        private static final Matrix.ScaleToFit[] sFits =
-                new Matrix.ScaleToFit[] {
-            Matrix.ScaleToFit.FILL,
-            Matrix.ScaleToFit.START,
-            Matrix.ScaleToFit.CENTER,
-            Matrix.ScaleToFit.END
-        };
-        
-        private static final String[] sFitLabels = new String[] {
-            "FILL", "START", "CENTER", "END"
-        };
-        
-        private static final int[] sSrcData = new int[] {
-            80, 40, Color.RED,
-            40, 80, Color.GREEN,
-            30, 30, Color.BLUE,
-            80, 80, Color.BLACK
-        };
-        private static final int N = 4;
-        
-        private static final int WIDTH = 52;
-        private static final int HEIGHT = 52;
-        private final RectF mDstR = new RectF(0, 0, WIDTH, HEIGHT);
-
-        public SampleView(Context context) {
-            super(context);
-
-            mHairPaint.setStyle(Paint.Style.STROKE);
-            mLabelPaint.setTextSize(16);
-        }
-        
-        private void setSrcR(int index) {
-            int w = sSrcData[index*3 + 0];
-            int h = sSrcData[index*3 + 1];
-            mSrcR.set(0, 0, w, h);
-        }
-        
-        private void drawSrcR(Canvas canvas, int index) {
-            mPaint.setColor(sSrcData[index*3 + 2]);
-            canvas.drawOval(mSrcR, mPaint);
-        }
-        
-        private void drawFit(Canvas canvas, int index, Matrix.ScaleToFit stf) {
-            canvas.save();
-            
-            setSrcR(index);
-            mMatrix.setRectToRect(mSrcR, mDstR, stf);
-            canvas.concat(mMatrix);
-            drawSrcR(canvas, index);
-            
-            canvas.restore();
-            
-            canvas.drawRect(mDstR, mHairPaint);
-        }
-
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-
-            canvas.drawColor(Color.WHITE);
-
-            canvas.translate(10, 10);
-
-            canvas.save();
-            for (int i = 0; i < N; i++) {
-                setSrcR(i);
-                drawSrcR(canvas, i);
-                canvas.translate(mSrcR.width() + 15, 0);
-            }
-            canvas.restore();
-            
-            canvas.translate(0, 100);
-            for (int j = 0; j < sFits.length; j++) {
-                canvas.save();
-                for (int i = 0; i < N; i++) {
-                    drawFit(canvas, i, sFits[j]);
-                    canvas.translate(mDstR.width() + 8, 0);
-                }
-                canvas.drawText(sFitLabels[j], 0, HEIGHT*2/3, mLabelPaint);
-                canvas.restore();
-                canvas.translate(0, 80);
-            }
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/SensorTest.java b/samples/ApiDemos/src/com/example/android/apis/graphics/SensorTest.java
deleted file mode 100644
index ed5b5ae..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/SensorTest.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.hardware.SensorListener;
-import android.hardware.SensorManager;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.os.SystemClock;
-import android.util.Config;
-import android.util.Log;
-import android.view.View;
-
-public class SensorTest extends GraphicsActivity {
-
-	private SensorManager mSensorManager;
-    private SampleView mView;
-    private float[] mValues;
-    
-    private static class RunAve {
-        private final float[] mWeights;
-        private final float mWeightScale;
-        private final float[] mSamples;
-        private final int mDepth;
-        private int mCurr;
-
-        public RunAve(float[] weights) {
-            mWeights = weights;
-            
-            float sum = 0;
-            for (int i = 0; i < weights.length; i++) {
-                sum += weights[i];
-            }
-            mWeightScale = 1 / sum;
-
-            mDepth = weights.length;
-            mSamples = new float[mDepth];
-            mCurr = 0;
-        }
-        
-        public void addSample(float value) {
-            mSamples[mCurr] = value;
-            mCurr = (mCurr + 1) % mDepth;
-        }
-        
-        public float computeAve() {
-            final int depth = mDepth;
-            int index = mCurr;
-            float sum = 0;
-            for (int i = 0; i < depth; i++) {
-                sum += mWeights[i] * mSamples[index];
-                index -= 1;
-                if (index < 0) {
-                    index = depth - 1;
-                }
-            }
-            return sum * mWeightScale;
-        }
-    };
-
-    private final SensorListener mListener = new SensorListener() {
-
-        private final float[] mScale = new float[] { 2, 2.5f, 0.5f };   // accel
-
-        private float[] mPrev = new float[3];
-            
-        public void onSensorChanged(int sensor, float[] values) {
-            boolean show = false;
-            float[] diff = new float[3];
-
-            for (int i = 0; i < 3; i++) {
-                diff[i] = Math.round(mScale[i] * (values[i] - mPrev[i]) * 0.45f);
-                if (Math.abs(diff[i]) > 0) {
-                    show = true;
-                }
-                mPrev[i] = values[i];
-            }
-            
-            if (show) {
-                // only shows if we think the delta is big enough, in an attempt
-                // to detect "serious" moves left/right or up/down
-                android.util.Log.e("test", "sensorChanged " + sensor + " (" + values[0] + ", " + values[1] + ", " + values[2] + ")"
-                                   + " diff(" + diff[0] + " " + diff[1] + " " + diff[2] + ")");
-            }
-            
-            long now = android.os.SystemClock.uptimeMillis();
-            if (now - mLastGestureTime > 1000) {
-                mLastGestureTime = 0;
-                
-                float x = diff[0];
-                float y = diff[1];
-                boolean gestX = Math.abs(x) > 3;
-                boolean gestY = Math.abs(y) > 3;
-
-                if ((gestX || gestY) && !(gestX && gestY)) {
-                    if (gestX) {
-                        if (x < 0) {
-                            android.util.Log.e("test", "<<<<<<<< LEFT <<<<<<<<<<<<");
-                        } else {
-                            android.util.Log.e("test", ">>>>>>>>> RITE >>>>>>>>>>>");
-                        }
-                    } else {
-                        if (y < -2) {
-                            android.util.Log.e("test", "<<<<<<<< UP <<<<<<<<<<<<");
-                        } else {
-                            android.util.Log.e("test", ">>>>>>>>> DOWN >>>>>>>>>>>");
-                        }
-                    }
-                    mLastGestureTime = now;
-                }
-            }
-        }
-        
-        private long mLastGestureTime;
-
-        public void onAccuracyChanged(int sensor, int accuracy) {
-            // TODO Auto-generated method stub
-            
-        }
-    };
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        mSensorManager = (SensorManager)getSystemService(Context.SENSOR_SERVICE);
-        mView = new SampleView(this);
-        setContentView(mView);
-//        android.util.Log.d("skia", "create " + mSensorManager);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        
-        int mask = 0;
-//        mask |= SensorManager.SENSOR_ORIENTATION;
-        mask |= SensorManager.SENSOR_ACCELEROMETER;
-        
-        mSensorManager.registerListener(mListener, mask, SensorManager.SENSOR_DELAY_FASTEST);
-//        android.util.Log.d("skia", "resume " + mSensorManager);
-    }
-    
-    @Override
-    protected void onStop() {
-        mSensorManager.unregisterListener(mListener);
-        super.onStop();
-//        android.util.Log.d("skia", "stop " + mSensorManager);
-    }
-
-    private class SampleView extends View {
-        private Paint   mPaint = new Paint();
-        private Path    mPath = new Path();
-        private boolean mAnimate;
-        private long    mNextTime;
-
-        public SampleView(Context context) {
-            super(context);
-
-            // Construct a wedge-shaped path
-            mPath.moveTo(0, -50);
-            mPath.lineTo(-20, 60);
-            mPath.lineTo(0, 50);
-            mPath.lineTo(20, 60);
-            mPath.close();
-        }
-    
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-
-            canvas.drawColor(Color.WHITE);
-            
-            paint.setAntiAlias(true);
-            paint.setColor(Color.BLACK);
-            paint.setStyle(Paint.Style.FILL);
-
-            int w = canvas.getWidth();
-            int h = canvas.getHeight();
-            int cx = w / 2;
-            int cy = h / 2;
-
-            canvas.translate(cx, cy);
-            if (mValues != null) {            
-                canvas.rotate(-mValues[0]);
-            }
-            canvas.drawPath(mPath, mPaint);
-        }
-    
-        @Override
-        protected void onAttachedToWindow() {
-            mAnimate = true;
-            super.onAttachedToWindow();
-        }
-        
-        @Override
-        protected void onDetachedFromWindow() {
-            mAnimate = false;
-            super.onDetachedFromWindow();
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/ShapeDrawable1.java b/samples/ApiDemos/src/com/example/android/apis/graphics/ShapeDrawable1.java
deleted file mode 100644
index 6d450bb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/ShapeDrawable1.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.Drawable;
-import android.graphics.drawable.ShapeDrawable;
-import android.graphics.drawable.shapes.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-public class ShapeDrawable1 extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private ShapeDrawable[] mDrawables;
-        
-        private static Shader makeSweep() {
-            return new SweepGradient(150, 25,
-                new int[] { 0xFFFF0000, 0xFF00FF00, 0xFF0000FF, 0xFFFF0000 },
-                null);
-        }
-        
-        private static Shader makeLinear() {
-            return new LinearGradient(0, 0, 50, 50,
-                              new int[] { 0xFFFF0000, 0xFF00FF00, 0xFF0000FF },
-                              null, Shader.TileMode.MIRROR);
-        }
-        
-        private static Shader makeTiling() {
-            int[] pixels = new int[] { 0xFFFF0000, 0xFF00FF00, 0xFF0000FF, 0};
-            Bitmap bm = Bitmap.createBitmap(pixels, 2, 2,
-                                            Bitmap.Config.ARGB_8888);
-            
-            return new BitmapShader(bm, Shader.TileMode.REPEAT,
-                                        Shader.TileMode.REPEAT);
-        }
-        
-        private static class MyShapeDrawable extends ShapeDrawable {
-            private Paint mStrokePaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            
-            public MyShapeDrawable(Shape s) {
-                super(s);
-                mStrokePaint.setStyle(Paint.Style.STROKE);
-            }
-            
-            public Paint getStrokePaint() {
-                return mStrokePaint;
-            }
-            
-            @Override protected void onDraw(Shape s, Canvas c, Paint p) {
-                s.draw(c, p);
-                s.draw(c, mStrokePaint);
-            }
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-
-            float[] outerR = new float[] { 12, 12, 12, 12, 0, 0, 0, 0 };
-            RectF   inset = new RectF(6, 6, 6, 6);
-            float[] innerR = new float[] { 12, 12, 0, 0, 12, 12, 0, 0 };
-            
-            Path path = new Path();
-            path.moveTo(50, 0);
-            path.lineTo(0, 50);
-            path.lineTo(50, 100);
-            path.lineTo(100, 50);
-            path.close();
-            
-            mDrawables = new ShapeDrawable[7];
-            mDrawables[0] = new ShapeDrawable(new RectShape());
-            mDrawables[1] = new ShapeDrawable(new OvalShape());
-            mDrawables[2] = new ShapeDrawable(new RoundRectShape(outerR, null,
-                                                                 null));
-            mDrawables[3] = new ShapeDrawable(new RoundRectShape(outerR, inset,
-                                                                 null));
-            mDrawables[4] = new ShapeDrawable(new RoundRectShape(outerR, inset,
-                                                                 innerR));
-            mDrawables[5] = new ShapeDrawable(new PathShape(path, 100, 100));
-            mDrawables[6] = new MyShapeDrawable(new ArcShape(45, -270));
-            
-            mDrawables[0].getPaint().setColor(0xFFFF0000);
-            mDrawables[1].getPaint().setColor(0xFF00FF00);
-            mDrawables[2].getPaint().setColor(0xFF0000FF);
-            mDrawables[3].getPaint().setShader(makeSweep());
-            mDrawables[4].getPaint().setShader(makeLinear());
-            mDrawables[5].getPaint().setShader(makeTiling());
-            mDrawables[6].getPaint().setColor(0x88FF8844);
-            
-            PathEffect pe = new DiscretePathEffect(10, 4);
-            PathEffect pe2 = new CornerPathEffect(4);
-            mDrawables[3].getPaint().setPathEffect(
-                                                new ComposePathEffect(pe2, pe));
-        
-            MyShapeDrawable msd = (MyShapeDrawable)mDrawables[6];
-            msd.getStrokePaint().setStrokeWidth(4);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            
-            int x = 10;
-            int y = 10;
-            int width = 300;
-            int height = 50;
-            
-            for (Drawable dr : mDrawables) {
-                dr.setBounds(x, y, x + width, y + height);
-                dr.draw(canvas);                
-                y += height + 5;
-            }
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/SurfaceViewOverlay.java b/samples/ApiDemos/src/com/example/android/apis/graphics/SurfaceViewOverlay.java
deleted file mode 100644
index 45e5d60..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/SurfaceViewOverlay.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-//Need the following import to get access to the app resources, since this
-//class is in a sub-package.
-import com.example.android.apis.R;
-
-/**
- * Demonstration of overlays placed on top of a SurfaceView.
- */
-public class SurfaceViewOverlay extends Activity {
-    View mVictimContainer;
-    View mVictim1;
-    View mVictim2;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.surface_view_overlay);
-
-        GLSurfaceView glSurfaceView =
-            (GLSurfaceView) findViewById(R.id.glsurfaceview);
-        glSurfaceView.setRenderer(new CubeRenderer(false));
-
-        // Find the views whose visibility will change
-        mVictimContainer = findViewById(R.id.hidecontainer);
-        mVictim1 = findViewById(R.id.hideme1);
-        mVictim1.setOnClickListener(new HideMeListener(mVictim1));
-        mVictim2 = findViewById(R.id.hideme2);
-        mVictim2.setOnClickListener(new HideMeListener(mVictim2));
-
-        // Find our buttons
-        Button visibleButton = (Button) findViewById(R.id.vis);
-        Button invisibleButton = (Button) findViewById(R.id.invis);
-        Button goneButton = (Button) findViewById(R.id.gone);
-
-        // Wire each button to a click listener
-        visibleButton.setOnClickListener(mVisibleListener);
-        invisibleButton.setOnClickListener(mInvisibleListener);
-        goneButton.setOnClickListener(mGoneListener);
-    }
-
-    @Override
-    protected void onResume() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onResume();
-    }
-
-    @Override
-    protected void onPause() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onPause();
-    }
-
-    class HideMeListener implements OnClickListener {
-        final View mTarget;
-
-        HideMeListener(View target) {
-            mTarget = target;
-        }
-
-        public void onClick(View v) {
-            mTarget.setVisibility(View.INVISIBLE);
-        }
-
-    }
-
-    OnClickListener mVisibleListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim1.setVisibility(View.VISIBLE);
-            mVictim2.setVisibility(View.VISIBLE);
-            mVictimContainer.setVisibility(View.VISIBLE);
-        }
-    };
-
-    OnClickListener mInvisibleListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim1.setVisibility(View.INVISIBLE);
-            mVictim2.setVisibility(View.INVISIBLE);
-            mVictimContainer.setVisibility(View.INVISIBLE);
-        }
-    };
-
-    OnClickListener mGoneListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim1.setVisibility(View.GONE);
-            mVictim2.setVisibility(View.GONE);
-            mVictimContainer.setVisibility(View.GONE);
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Sweep.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Sweep.java
deleted file mode 100644
index dc127fd..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Sweep.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-//import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-
-public class Sweep extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private float mRotate;
-        private Matrix mMatrix = new Matrix();
-        private Shader mShader;
-        private boolean mDoTiming;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-
-            float x = 160;
-            float y = 100;
-            mShader = new SweepGradient(x, y, new int[] { Color.GREEN,
-                                                  Color.RED,
-                                                  Color.BLUE,
-                                                  Color.GREEN }, null);
-            mPaint.setShader(mShader);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            Paint paint = mPaint;
-            float x = 160;
-            float y = 100;
-
-            canvas.drawColor(Color.WHITE);
-
-            mMatrix.setRotate(mRotate, x, y);
-            mShader.setLocalMatrix(mMatrix);
-            mRotate += 3;
-            if (mRotate >= 360) {
-                mRotate = 0;
-            }
-            invalidate();
-
-            if (mDoTiming) {
-                long now = System.currentTimeMillis();
-                for (int i = 0; i < 20; i++) {
-                    canvas.drawCircle(x, y, 80, paint);
-                }
-                now = System.currentTimeMillis() - now;
-                android.util.Log.d("skia", "sweep ms = " + (now/20.));
-            }
-            else {
-                canvas.drawCircle(x, y, 80, paint);
-            }
-        }
-
-        @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-            switch (keyCode) {
-                case KeyEvent.KEYCODE_D:
-                    mPaint.setDither(!mPaint.isDither());
-                    invalidate();
-                    return true;
-                case KeyEvent.KEYCODE_T:
-                    mDoTiming = !mDoTiming;
-                    invalidate();
-                    return true;
-            }
-            return super.onKeyDown(keyCode, event);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TextAlign.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TextAlign.java
deleted file mode 100644
index 0576a7c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TextAlign.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-public class TextAlign extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint   mPaint;
-        private float   mX;
-        private float[] mPos;
-        
-        private Path    mPath;
-        private Paint   mPathPaint;
-        
-        private static final int DY = 30;
-        private static final String TEXT_L = "Left";
-        private static final String TEXT_C = "Center";
-        private static final String TEXT_R = "Right";
-        private static final String POSTEXT = "Positioned";
-        private static final String TEXTONPATH = "Along a path";
-        
-        private static void makePath(Path p) {
-            p.moveTo(10, 0);
-            p.cubicTo(100, -50, 200, 50, 300, 0);
-        }
-        
-        private float[] buildTextPositions(String text, float y, Paint paint) {
-            float[] widths = new float[text.length()];
-            // initially get the widths for each char
-            int n = paint.getTextWidths(text, widths);
-            // now popuplate the array, interleaving spaces for the Y values
-            float[] pos = new float[n * 2];
-            float accumulatedX = 0;
-            for (int i = 0; i < n; i++) {
-                pos[i*2 + 0] = accumulatedX;
-                pos[i*2 + 1] = y;
-                accumulatedX += widths[i];
-            }
-            return pos;
-        }
-        
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-            mPaint.setTextSize(30);
-            mPaint.setTypeface(Typeface.SERIF);
-            
-            mPos = buildTextPositions(POSTEXT, 0, mPaint);
-            
-            mPath = new Path();
-            makePath(mPath);
-
-            mPathPaint = new Paint();
-            mPathPaint.setAntiAlias(true);
-            mPathPaint.setColor(0x800000FF);
-            mPathPaint.setStyle(Paint.Style.STROKE);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            Paint p = mPaint;
-            float x = mX;
-            float y = 0;
-            float[] pos = mPos;
-            
-            // draw the normal strings
-
-            p.setColor(0x80FF0000);
-            canvas.drawLine(x, y, x, y+DY*3, p);
-            p.setColor(Color.BLACK);
-            
-            canvas.translate(0, DY);
-            p.setTextAlign(Paint.Align.LEFT);
-            canvas.drawText(TEXT_L, x, y, p);
-
-            canvas.translate(0, DY);
-            p.setTextAlign(Paint.Align.CENTER);
-            canvas.drawText(TEXT_C, x, y, p);
-
-            canvas.translate(0, DY);
-            p.setTextAlign(Paint.Align.RIGHT);
-            canvas.drawText(TEXT_R, x, y, p);
-            
-            canvas.translate(100, DY*2);
-
-            // now draw the positioned strings
-    
-            p.setColor(0xBB00FF00);
-            for (int i = 0; i < pos.length/2; i++) {
-                canvas.drawLine(pos[i*2+0], pos[i*2+1]-DY,
-                                pos[i*2+0], pos[i*2+1]+DY*2, p);
-            }
-            p.setColor(Color.BLACK);
-
-            p.setTextAlign(Paint.Align.LEFT);
-            canvas.drawPosText(POSTEXT, pos, p);
-            
-            canvas.translate(0, DY);
-            p.setTextAlign(Paint.Align.CENTER);
-            canvas.drawPosText(POSTEXT, pos, p);
-            
-            canvas.translate(0, DY);
-            p.setTextAlign(Paint.Align.RIGHT);
-            canvas.drawPosText(POSTEXT, pos, p);
-            
-            // now draw the text on path
-            
-            canvas.translate(-100, DY*2);
-
-            canvas.drawPath(mPath, mPathPaint);
-            p.setTextAlign(Paint.Align.LEFT);
-            canvas.drawTextOnPath(TEXTONPATH, mPath, 0, 0, p);
-
-            canvas.translate(0, DY*1.5f);
-            canvas.drawPath(mPath, mPathPaint);
-            p.setTextAlign(Paint.Align.CENTER);
-            canvas.drawTextOnPath(TEXTONPATH, mPath, 0, 0, p);
-            
-            canvas.translate(0, DY*1.5f);
-            canvas.drawPath(mPath, mPathPaint);
-            p.setTextAlign(Paint.Align.RIGHT);
-            canvas.drawTextOnPath(TEXTONPATH, mPath, 0, 0, p);
-        }
-
-        @Override
-        protected void onSizeChanged(int w, int h, int ow, int oh) {
-            super.onSizeChanged(w, h, ow, oh);
-            mX = w * 0.5f;  // remember the center of the screen
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TouchPaint.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TouchPaint.java
deleted file mode 100644
index 0942852..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TouchPaint.java
+++ /dev/null
@@ -1,292 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.MotionEvent;
-import android.view.View;
-
-//Need the following import to get access to the app resources, since this
-//class is in a sub-package.
-
-
-/**
- * Demonstrates the handling of touch screen and trackball events to
- * implement a simple painting app.
- */
-public class TouchPaint extends GraphicsActivity {
-    /** Used as a pulse to gradually fade the contents of the window. */
-    private static final int FADE_MSG = 1;
-    
-    /** Menu ID for the command to clear the window. */
-    private static final int CLEAR_ID = Menu.FIRST;
-    /** Menu ID for the command to toggle fading. */
-    private static final int FADE_ID = Menu.FIRST+1;
-    
-    /** How often to fade the contents of the window (in ms). */
-    private static final int FADE_DELAY = 100;
-    
-    /** The view responsible for drawing the window. */
-    MyView mView;
-    /** Is fading mode enabled? */
-    boolean mFading;
-    
-    @Override protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        // Create and attach the view that is responsible for painting.
-        mView = new MyView(this);
-        setContentView(mView);
-        mView.requestFocus();
-        
-        // Restore the fading option if we are being thawed from a
-        // previously saved state.  Note that we are not currently remembering
-        // the contents of the bitmap.
-        mFading = savedInstanceState != null ? savedInstanceState.getBoolean("fading", true) : true;
-    }
-    
-    @Override public boolean onCreateOptionsMenu(Menu menu) {
-        menu.add(0, CLEAR_ID, 0, "Clear");
-        menu.add(0, FADE_ID, 0, "Fade").setCheckable(true);
-        return super.onCreateOptionsMenu(menu);
-    }
-
-    @Override public boolean onPrepareOptionsMenu(Menu menu) {
-        menu.findItem(FADE_ID).setChecked(mFading);
-        return super.onPrepareOptionsMenu(menu);
-    }
-
-    @Override public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-            case CLEAR_ID:
-                mView.clear();
-                return true;
-            case FADE_ID:
-                mFading = !mFading;
-                if (mFading) {
-                    startFading();
-                } else {
-                    stopFading();
-                }
-                return true;
-            default:
-                return super.onOptionsItemSelected(item);
-        }
-    }
-
-    @Override protected void onResume() {
-        super.onResume();
-        // If fading mode is enabled, then as long as we are resumed we want
-        // to run pulse to fade the contents.
-        if (mFading) {
-            startFading();
-        }
-    }
-
-    @Override protected void onSaveInstanceState(Bundle outState) {
-        super.onSaveInstanceState(outState);
-        // Save away the fading state to restore if needed later.  Note that
-        // we do not currently save the contents of the display.
-        outState.putBoolean("fading", mFading);
-    }
-
-    @Override protected void onPause() {
-        super.onPause();
-        // Make sure to never run the fading pulse while we are paused or
-        // stopped.
-        stopFading();
-    }
-
-    /**
-     * Start up the pulse to fade the screen, clearing any existing pulse to
-     * ensure that we don't have multiple pulses running at a time.
-     */
-    void startFading() {
-        mHandler.removeMessages(FADE_MSG);
-        mHandler.sendMessageDelayed(
-                mHandler.obtainMessage(FADE_MSG), FADE_DELAY);
-    }
-    
-    /**
-     * Stop the pulse to fade the screen.
-     */
-    void stopFading() {
-        mHandler.removeMessages(FADE_MSG);
-    }
-    
-    private Handler mHandler = new Handler() {
-        @Override public void handleMessage(Message msg) {
-            switch (msg.what) {
-                // Upon receiving the fade pulse, we have the view perform a
-                // fade and then enqueue a new message to pulse at the desired
-                // next time.
-                case FADE_MSG: {
-                    mView.fade();
-                    mHandler.sendMessageDelayed(
-                            mHandler.obtainMessage(FADE_MSG), FADE_DELAY);
-                    break;
-                }
-                default:
-                    super.handleMessage(msg);
-            }
-        }
-    };
-    
-    public class MyView extends View {
-        private static final int FADE_ALPHA = 0x06;
-        private static final int MAX_FADE_STEPS = 256/FADE_ALPHA + 4;
-        private Bitmap mBitmap;
-        private Canvas mCanvas;
-        private final Rect mRect = new Rect();
-        private final Paint mPaint;
-        private final Paint mFadePaint;
-        private boolean mCurDown;
-        private int mCurX;
-        private int mCurY;
-        private float mCurPressure;
-        private float mCurSize;
-        private int mCurWidth;
-        private int mFadeSteps = MAX_FADE_STEPS;
-        
-        public MyView(Context c) {
-            super(c);
-            mPaint = new Paint();
-            mPaint.setAntiAlias(true);
-            mPaint.setARGB(255, 255, 255, 255);
-            mFadePaint = new Paint();
-            mFadePaint.setDither(true);
-            mFadePaint.setARGB(FADE_ALPHA, 0, 0, 0);
-        }
-
-        public void clear() {
-            if (mCanvas != null) {
-                mPaint.setARGB(0xff, 0, 0, 0);
-                mCanvas.drawPaint(mPaint);
-                invalidate();
-                mFadeSteps = MAX_FADE_STEPS;
-            }
-        }
-        
-        public void fade() {
-            if (mCanvas != null && mFadeSteps < MAX_FADE_STEPS) {
-                mCanvas.drawPaint(mFadePaint);
-                invalidate();
-                mFadeSteps++;
-            }
-        }
-        
-        @Override protected void onSizeChanged(int w, int h, int oldw,
-                int oldh) {
-            int curW = mBitmap != null ? mBitmap.getWidth() : 0;
-            int curH = mBitmap != null ? mBitmap.getHeight() : 0;
-            if (curW >= w && curH >= h) {
-                return;
-            }
-            
-            if (curW < w) curW = w;
-            if (curH < h) curH = h;
-            
-            Bitmap newBitmap = Bitmap.createBitmap(curW, curH,
-                                                   Bitmap.Config.RGB_565);
-            Canvas newCanvas = new Canvas();
-            newCanvas.setBitmap(newBitmap);
-            if (mBitmap != null) {
-                newCanvas.drawBitmap(mBitmap, 0, 0, null);
-            }
-            mBitmap = newBitmap;
-            mCanvas = newCanvas;
-            mFadeSteps = MAX_FADE_STEPS;
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            if (mBitmap != null) {
-                canvas.drawBitmap(mBitmap, 0, 0, null);
-            }
-        }
-
-        @Override public boolean onTrackballEvent(MotionEvent event) {
-            boolean oldDown = mCurDown;
-            mCurDown = true;
-            int N = event.getHistorySize();
-            int baseX = mCurX;
-            int baseY = mCurY;
-            final float scaleX = event.getXPrecision();
-            final float scaleY = event.getYPrecision();
-            for (int i=0; i<N; i++) {
-                //Log.i("TouchPaint", "Intermediate trackball #" + i
-                //        + ": x=" + event.getHistoricalX(i)
-                //        + ", y=" + event.getHistoricalY(i));
-                drawPoint(baseX+event.getHistoricalX(i)*scaleX,
-                        baseY+event.getHistoricalY(i)*scaleY,
-                        event.getHistoricalPressure(i),
-                        event.getHistoricalSize(i));
-            }
-            //Log.i("TouchPaint", "Trackball: x=" + event.getX()
-            //        + ", y=" + event.getY());
-            drawPoint(baseX+event.getX()*scaleX, baseY+event.getY()*scaleY,
-                    event.getPressure(), event.getSize());
-            mCurDown = oldDown;
-            return true;
-        }
-        
-        @Override public boolean onTouchEvent(MotionEvent event) {
-            int action = event.getAction();
-            mCurDown = action == MotionEvent.ACTION_DOWN
-                    || action == MotionEvent.ACTION_MOVE;
-            int N = event.getHistorySize();
-            for (int i=0; i<N; i++) {
-                //Log.i("TouchPaint", "Intermediate pointer #" + i);
-                drawPoint(event.getHistoricalX(i), event.getHistoricalY(i),
-                        event.getHistoricalPressure(i),
-                        event.getHistoricalSize(i));
-            }
-            drawPoint(event.getX(), event.getY(), event.getPressure(),
-                    event.getSize());
-            return true;
-        }
-        
-        private void drawPoint(float x, float y, float pressure, float size) {
-            //Log.i("TouchPaint", "Drawing: " + x + "x" + y + " p="
-            //        + pressure + " s=" + size);
-            mCurX = (int)x;
-            mCurY = (int)y;
-            mCurPressure = pressure;
-            mCurSize = size;
-            mCurWidth = (int)(mCurSize*(getWidth()/3));
-            if (mCurWidth < 1) mCurWidth = 1;
-            if (mCurDown && mBitmap != null) {
-                int pressureLevel = (int)(mCurPressure*255);
-                mPaint.setARGB(pressureLevel, 255, 255, 255);
-                mCanvas.drawCircle(mCurX, mCurY, mCurWidth, mPaint);
-                mRect.set(mCurX-mCurWidth-2, mCurY-mCurWidth-2,
-                        mCurX+mCurWidth+2, mCurY+mCurWidth+2);
-                invalidate(mRect);
-            }
-            mFadeSteps = 0;
-        }
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TouchRotateActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TouchRotateActivity.java
deleted file mode 100644
index 09d3694..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TouchRotateActivity.java
+++ /dev/null
@@ -1,195 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-import android.app.Activity;
-import android.content.Context;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-import android.view.MotionEvent;
-
-/**
- * Wrapper activity demonstrating the use of {@link GLSurfaceView}, a view
- * that uses OpenGL drawing into a dedicated surface.
- *
- * Shows:
- * + How to redraw in response to user input.
- */
-public class TouchRotateActivity extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Create our Preview view and set it as the content of our
-        // Activity
-        mGLSurfaceView = new TouchSurfaceView(this);
-        setContentView(mGLSurfaceView);
-        mGLSurfaceView.requestFocus();
-        mGLSurfaceView.setFocusableInTouchMode(true);
-    }
-
-    @Override
-    protected void onResume() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onResume();
-        mGLSurfaceView.onResume();
-    }
-
-    @Override
-    protected void onPause() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onPause();
-        mGLSurfaceView.onPause();
-    }
-
-    private GLSurfaceView mGLSurfaceView;
-}
-
-/**
- * Implement a simple rotation control.
- *
- */
-class TouchSurfaceView extends GLSurfaceView {
-
-    public TouchSurfaceView(Context context) {
-        super(context);
-        mRenderer = new CubeRenderer();
-        setRenderer(mRenderer);
-        setRenderMode(GLSurfaceView.RENDERMODE_WHEN_DIRTY);
-    }
-
-    @Override public boolean onTrackballEvent(MotionEvent e) {
-        mRenderer.mAngleX += e.getX() * TRACKBALL_SCALE_FACTOR;
-        mRenderer.mAngleY += e.getY() * TRACKBALL_SCALE_FACTOR;
-        requestRender();
-        return true;
-    }
-
-    @Override public boolean onTouchEvent(MotionEvent e) {
-        float x = e.getX();
-        float y = e.getY();
-        switch (e.getAction()) {
-        case MotionEvent.ACTION_MOVE:
-            float dx = x - mPreviousX;
-            float dy = y - mPreviousY;
-            mRenderer.mAngleX += dx * TOUCH_SCALE_FACTOR;
-            mRenderer.mAngleY += dy * TOUCH_SCALE_FACTOR;
-            requestRender();
-        }
-        mPreviousX = x;
-        mPreviousY = y;
-        return true;
-    }
-
-    /**
-     * Render a cube.
-     */
-    private class CubeRenderer implements GLSurfaceView.Renderer {
-        public CubeRenderer() {
-            mCube = new Cube();
-        }
-
-        public void onDrawFrame(GL10 gl) {
-            /*
-             * Usually, the first thing one might want to do is to clear
-             * the screen. The most efficient way of doing this is to use
-             * glClear().
-             */
-
-            gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-            /*
-             * Now we're ready to draw some 3D objects
-             */
-
-            gl.glMatrixMode(GL10.GL_MODELVIEW);
-            gl.glLoadIdentity();
-            gl.glTranslatef(0, 0, -3.0f);
-            gl.glRotatef(mAngleX, 0, 1, 0);
-            gl.glRotatef(mAngleY, 1, 0, 0);
-
-            gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-            gl.glEnableClientState(GL10.GL_COLOR_ARRAY);
-
-            mCube.draw(gl);
-        }
-
-        public int[] getConfigSpec() {
-            // We want a depth buffer, don't care about the
-            // details of the color buffer.
-            int[] configSpec = {
-                    EGL10.EGL_DEPTH_SIZE,   16,
-                    EGL10.EGL_NONE
-            };
-            return configSpec;
-        }
-
-        public void onSurfaceChanged(GL10 gl, int width, int height) {
-             gl.glViewport(0, 0, width, height);
-
-             /*
-              * Set our projection matrix. This doesn't have to be done
-              * each time we draw, but usually a new projection needs to
-              * be set when the viewport is resized.
-              */
-
-             float ratio = (float) width / height;
-             gl.glMatrixMode(GL10.GL_PROJECTION);
-             gl.glLoadIdentity();
-             gl.glFrustumf(-ratio, ratio, -1, 1, 1, 10);
-        }
-
-        public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-            /*
-             * By default, OpenGL enables features that improve quality
-             * but reduce performance. One might want to tweak that
-             * especially on software renderer.
-             */
-            gl.glDisable(GL10.GL_DITHER);
-
-            /*
-             * Some one-time OpenGL initialization can be made here
-             * probably based on features of this particular context
-             */
-             gl.glHint(GL10.GL_PERSPECTIVE_CORRECTION_HINT,
-                     GL10.GL_FASTEST);
-
-
-             gl.glClearColor(1,1,1,1);
-             gl.glEnable(GL10.GL_CULL_FACE);
-             gl.glShadeModel(GL10.GL_SMOOTH);
-             gl.glEnable(GL10.GL_DEPTH_TEST);
-        }
-        private Cube mCube;
-        public float mAngleX;
-        public float mAngleY;
-    }
-
-    private final float TOUCH_SCALE_FACTOR = 180.0f / 320;
-    private final float TRACKBALL_SCALE_FACTOR = 36.0f;
-    private CubeRenderer mRenderer;
-    private float mPreviousX;
-    private float mPreviousY;
-}
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TranslucentGLSurfaceViewActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TranslucentGLSurfaceViewActivity.java
deleted file mode 100644
index 750a47b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TranslucentGLSurfaceViewActivity.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.graphics.PixelFormat;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-
-
-/**
- * Wrapper activity demonstrating the use of {@link GLSurfaceView} to
- * display translucent 3D graphics.
- */
-public class TranslucentGLSurfaceViewActivity extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Create our Preview view and set it as the content of our
-        // Activity
-        mGLSurfaceView = new GLSurfaceView(this);
-        // Tell the cube renderer that we want to render a translucent version
-        // of the cube:
-        mGLSurfaceView.setRenderer(new CubeRenderer(true));
-        // Use a surface format with an Alpha channel:
-        mGLSurfaceView.getHolder().setFormat(PixelFormat.TRANSLUCENT);
-        setContentView(mGLSurfaceView);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mGLSurfaceView.onResume();
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-        mGLSurfaceView.onPause();
-    }
-
-    private GLSurfaceView mGLSurfaceView;
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleActivity.java
deleted file mode 100644
index 59f3c6c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleActivity.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-
-public class TriangleActivity extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        mGLView = new GLSurfaceView(this);
-        mGLView.setRenderer(new TriangleRenderer(this));
-        setContentView(mGLView);
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-        mGLView.onPause();
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mGLView.onResume();
-    }
-
-    private GLSurfaceView mGLView;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleRenderer.java b/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleRenderer.java
deleted file mode 100644
index 451b927..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/TriangleRenderer.java
+++ /dev/null
@@ -1,252 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.FloatBuffer;
-import java.nio.ShortBuffer;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-import android.content.Context;
-import android.graphics.Bitmap;
-import android.graphics.BitmapFactory;
-import android.opengl.GLSurfaceView;
-import android.opengl.GLU;
-import android.opengl.GLUtils;
-import android.os.SystemClock;
-
-import com.example.android.apis.R;
-
-public class TriangleRenderer implements GLSurfaceView.Renderer{
-
-    public TriangleRenderer(Context context) {
-        mContext = context;
-        mTriangle = new Triangle();
-    }
-
-    public int[] getConfigSpec() {
-        // We don't need a depth buffer, and don't care about our
-        // color depth.
-        int[] configSpec = {
-                EGL10.EGL_DEPTH_SIZE, 0,
-                EGL10.EGL_NONE
-        };
-        return configSpec;
-    }
-
-    public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        /*
-         * Some one-time OpenGL initialization can be made here
-         * probably based on features of this particular context
-         */
-        gl.glHint(GL10.GL_PERSPECTIVE_CORRECTION_HINT,
-                GL10.GL_FASTEST);
-
-        gl.glClearColor(.5f, .5f, .5f, 1);
-        gl.glShadeModel(GL10.GL_SMOOTH);
-        gl.glEnable(GL10.GL_DEPTH_TEST);
-        gl.glEnable(GL10.GL_TEXTURE_2D);
-
-        /*
-         * Create our texture. This has to be done each time the
-         * surface is created.
-         */
-
-        int[] textures = new int[1];
-        gl.glGenTextures(1, textures, 0);
-
-        mTextureID = textures[0];
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MIN_FILTER,
-                GL10.GL_NEAREST);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D,
-                GL10.GL_TEXTURE_MAG_FILTER,
-                GL10.GL_LINEAR);
-
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S,
-                GL10.GL_CLAMP_TO_EDGE);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T,
-                GL10.GL_CLAMP_TO_EDGE);
-
-        gl.glTexEnvf(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE,
-                GL10.GL_REPLACE);
-
-        InputStream is = mContext.getResources()
-                .openRawResource(R.drawable.robot);
-        Bitmap bitmap;
-        try {
-            bitmap = BitmapFactory.decodeStream(is);
-        } finally {
-            try {
-                is.close();
-            } catch(IOException e) {
-                // Ignore.
-            }
-        }
-
-        GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0);
-        bitmap.recycle();
-    }
-
-    public void onDrawFrame(GL10 gl) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        gl.glTexEnvx(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE,
-                GL10.GL_MODULATE);
-
-        /*
-         * Usually, the first thing one might want to do is to clear
-         * the screen. The most efficient way of doing this is to use
-         * glClear().
-         */
-
-        gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-        /*
-         * Now we're ready to draw some 3D objects
-         */
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-
-        GLU.gluLookAt(gl, 0, 0, -5, 0f, 0f, 0f, 0f, 1.0f, 0.0f);
-
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-        gl.glEnableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-
-        gl.glActiveTexture(GL10.GL_TEXTURE0);
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-        gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S,
-                GL10.GL_REPEAT);
-        gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T,
-                GL10.GL_REPEAT);
-
-        long time = SystemClock.uptimeMillis() % 4000L;
-        float angle = 0.090f * ((int) time);
-
-        gl.glRotatef(angle, 0, 0, 1.0f);
-
-        mTriangle.draw(gl);
-    }
-
-    public void onSurfaceChanged(GL10 gl, int w, int h) {
-        gl.glViewport(0, 0, w, h);
-
-        /*
-        * Set our projection matrix. This doesn't have to be done
-        * each time we draw, but usually a new projection needs to
-        * be set when the viewport is resized.
-        */
-
-        float ratio = (float) w / h;
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glLoadIdentity();
-        gl.glFrustumf(-ratio, ratio, -1, 1, 3, 7);
-
-    }
-
-    private Context mContext;
-    private Triangle mTriangle;
-    private int mTextureID;
-}
-
-class Triangle {
-    public Triangle() {
-
-        // Buffers to be passed to gl*Pointer() functions
-        // must be direct, i.e., they must be placed on the
-        // native heap where the garbage collector cannot
-        // move them.
-        //
-        // Buffers with multi-byte datatypes (e.g., short, int, float)
-        // must have their byte order set to native order
-
-        ByteBuffer vbb = ByteBuffer.allocateDirect(VERTS * 3 * 4);
-        vbb.order(ByteOrder.nativeOrder());
-        mFVertexBuffer = vbb.asFloatBuffer();
-
-        ByteBuffer tbb = ByteBuffer.allocateDirect(VERTS * 2 * 4);
-        tbb.order(ByteOrder.nativeOrder());
-        mTexBuffer = tbb.asFloatBuffer();
-
-        ByteBuffer ibb = ByteBuffer.allocateDirect(VERTS * 2);
-        ibb.order(ByteOrder.nativeOrder());
-        mIndexBuffer = ibb.asShortBuffer();
-
-        // A unit-sided equalateral triangle centered on the origin.
-        float[] coords = {
-                // X, Y, Z
-                -0.5f, -0.25f, 0,
-                 0.5f, -0.25f, 0,
-                 0.0f,  0.559016994f, 0
-        };
-
-        for (int i = 0; i < VERTS; i++) {
-            for(int j = 0; j < 3; j++) {
-                mFVertexBuffer.put(coords[i*3+j] * 2.0f);
-            }
-        }
-
-        for (int i = 0; i < VERTS; i++) {
-            for(int j = 0; j < 2; j++) {
-                mTexBuffer.put(coords[i*3+j] * 2.0f + 0.5f);
-            }
-        }
-
-        for(int i = 0; i < VERTS; i++) {
-            mIndexBuffer.put((short) i);
-        }
-
-        mFVertexBuffer.position(0);
-        mTexBuffer.position(0);
-        mIndexBuffer.position(0);
-    }
-
-    public void draw(GL10 gl) {
-        gl.glFrontFace(GL10.GL_CCW);
-        gl.glVertexPointer(3, GL10.GL_FLOAT, 0, mFVertexBuffer);
-        gl.glEnable(GL10.GL_TEXTURE_2D);
-        gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, mTexBuffer);
-        gl.glDrawElements(GL10.GL_TRIANGLE_STRIP, VERTS,
-                GL10.GL_UNSIGNED_SHORT, mIndexBuffer);
-    }
-
-    private final static int VERTS = 3;
-
-    private FloatBuffer mFVertexBuffer;
-    private FloatBuffer mTexBuffer;
-    private ShortBuffer mIndexBuffer;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Typefaces.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Typefaces.java
deleted file mode 100644
index aefc311..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Typefaces.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.View;
-
-public class Typefaces extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint    mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-        private Typeface mFace;
-        
-        public SampleView(Context context) {
-            super(context);
-
-            mFace = Typeface.createFromAsset(getContext().getAssets(),
-                                             "fonts/samplefont.ttf");
-            
-            mPaint.setTextSize(64);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-
-            mPaint.setTypeface(null);
-            canvas.drawText("Default", 10, 100, mPaint);
-            mPaint.setTypeface(mFace);
-            canvas.drawText("Custom", 10, 200, mPaint);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/UnicodeChart.java b/samples/ApiDemos/src/com/example/android/apis/graphics/UnicodeChart.java
deleted file mode 100644
index 7ee99d0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/UnicodeChart.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-import android.view.Window;
-
-public class UnicodeChart extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-        
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private Paint mBigCharPaint;
-        private Paint mLabelPaint;
-        private final char[] mChars = new char[256];
-        private final float[] mPos = new float[512];
-        
-        private int mBase;
-        
-        private static final int XMUL = 20;
-        private static final int YMUL = 28;
-        private static final int YBASE = 18;
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-            setFocusableInTouchMode(true);
-            
-            mBigCharPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mBigCharPaint.setTextSize(15);
-            mBigCharPaint.setTextAlign(Paint.Align.CENTER);
-            
-            mLabelPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
-            mLabelPaint.setTextSize(8);
-            mLabelPaint.setTextAlign(Paint.Align.CENTER);
-            
-            // the position array is the same for all charts
-            float[] pos = mPos;
-            int index = 0;
-            for (int col = 0; col < 16; col++) {
-                final float x = col * 20 + 10;
-                for (int row = 0; row < 16; row++) {
-                    pos[index++] = x;
-                    pos[index++] = row * YMUL + YBASE;
-                }
-            }
-        }
-        
-        private float computeX(int index) {
-            return (index >> 4) * 20 + 10;
-        }
-
-        private float computeY(int index) {
-            return (index & 0xF) * YMUL + YMUL;
-        }
-        
-        private void drawChart(Canvas canvas, int base) {
-            char[] chars = mChars;
-            for (int i = 0; i < 256; i++) {
-                int unichar = base + i;
-                chars[i] = (char)unichar;
-                
-                canvas.drawText(Integer.toHexString(unichar),
-                                computeX(i), computeY(i), mLabelPaint);
-            }
-            canvas.drawPosText(chars, 0, 256, mPos, mBigCharPaint);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);            
-
-            canvas.translate(0, 1);
-            drawChart(canvas, mBase * 256);
-        }
-
-        @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-            switch (keyCode) {
-                case KeyEvent.KEYCODE_DPAD_LEFT:
-                    if (mBase > 0) {
-                        mBase -= 1;
-                        invalidate();
-                    }
-                    return true;
-                case KeyEvent.KEYCODE_DPAD_RIGHT:
-                    mBase += 1;
-                    invalidate();
-                    return true;
-                default:
-                    break;
-            }
-            return super.onKeyDown(keyCode, event);
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Vertices.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Vertices.java
deleted file mode 100644
index 1e61906..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Vertices.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.*;
-import android.graphics.drawable.*;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.*;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-public class Vertices extends GraphicsActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private final Paint mPaint = new Paint();
-        private final float[] mVerts = new float[10];
-        private final float[] mTexs = new float[10];
-        private final int[] mColors = new int[10];
-        private final short[] mIndices = { 0, 1, 2, 3, 4, 1 };
-        
-        private final Matrix mMatrix = new Matrix();
-        private final Matrix mInverse = new Matrix();
-
-        private static void setXY(float[] array, int index, float x, float y) {
-            array[index*2 + 0] = x;
-            array[index*2 + 1] = y;
-        }
-
-        public SampleView(Context context) {
-            super(context);
-            setFocusable(true);
-
-            Bitmap bm = BitmapFactory.decodeResource(getResources(),
-                                                     R.drawable.beach);
-            Shader s = new BitmapShader(bm, Shader.TileMode.CLAMP,
-                                        Shader.TileMode.CLAMP);
-            mPaint.setShader(s);
-            
-            float w = bm.getWidth();
-            float h = bm.getHeight();
-            // construct our mesh
-            setXY(mTexs, 0, w/2, h/2);
-            setXY(mTexs, 1, 0, 0);
-            setXY(mTexs, 2, w, 0);
-            setXY(mTexs, 3, w, h);
-            setXY(mTexs, 4, 0, h);
-            
-            setXY(mVerts, 0, w/2, h/2);
-            setXY(mVerts, 1, 0, 0);
-            setXY(mVerts, 2, w, 0);
-            setXY(mVerts, 3, w, h);
-            setXY(mVerts, 4, 0, h);
-            
-            mMatrix.setScale(0.8f, 0.8f);
-            mMatrix.preTranslate(20, 20);
-            mMatrix.invert(mInverse);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(0xFFCCCCCC);
-            canvas.save();
-            canvas.concat(mMatrix);
-
-            canvas.drawVertices(Canvas.VertexMode.TRIANGLE_FAN, 10, mVerts, 0,
-                                mTexs, 0, null, 0, null, 0, 0, mPaint);
-
-            canvas.translate(0, 240);
-            canvas.drawVertices(Canvas.VertexMode.TRIANGLE_FAN, 10, mVerts, 0,
-                                mTexs, 0, null, 0, mIndices, 0, 6, mPaint);
-
-            canvas.restore();
-        }
-
-        @Override public boolean onTouchEvent(MotionEvent event) {
-            float[] pt = { event.getX(), event.getY() };
-            mInverse.mapPoints(pt);
-            setXY(mVerts, 0, pt[0], pt[1]);
-            invalidate();
-            return true;
-        }
-        
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/Xfermodes.java b/samples/ApiDemos/src/com/example/android/apis/graphics/Xfermodes.java
deleted file mode 100644
index b9f8424..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/Xfermodes.java
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.Bitmap;
-import android.graphics.BitmapShader;
-import android.graphics.Canvas;
-import android.graphics.Color;
-import android.graphics.Matrix;
-import android.graphics.Paint;
-import android.graphics.PorterDuff;
-import android.graphics.PorterDuffXfermode;
-import android.graphics.RectF;
-import android.graphics.Shader;
-import android.graphics.Xfermode;
-import android.os.Bundle;
-import android.view.View;
-
-public class Xfermodes extends GraphicsActivity {
-    
-    // create a bitmap with a circle, used for the "dst" image
-    static Bitmap makeDst(int w, int h) {
-        Bitmap bm = Bitmap.createBitmap(w, h, Bitmap.Config.ARGB_8888);
-        Canvas c = new Canvas(bm);
-        Paint p = new Paint(Paint.ANTI_ALIAS_FLAG);
-        
-        p.setColor(0xFFFFCC44);    
-        c.drawOval(new RectF(0, 0, w*3/4, h*3/4), p);
-        return bm;
-    }
-    
-    // create a bitmap with a rect, used for the "src" image
-    static Bitmap makeSrc(int w, int h) {
-        Bitmap bm = Bitmap.createBitmap(w, h, Bitmap.Config.ARGB_8888);
-        Canvas c = new Canvas(bm);
-        Paint p = new Paint(Paint.ANTI_ALIAS_FLAG);
-        
-        p.setColor(0xFF66AAFF);
-        c.drawRect(w/3, h/3, w*19/20, h*19/20, p);
-        return bm;
-    }
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(new SampleView(this));
-    }
-    
-    private static class SampleView extends View {
-        private static final int W = 64;
-        private static final int H = 64;
-        private static final int ROW_MAX = 4;   // number of samples per row
-
-        private Bitmap mSrcB;
-        private Bitmap mDstB;
-        private Shader mBG;     // background checker-board pattern
-        
-        private static final Xfermode[] sModes = {
-            new PorterDuffXfermode(PorterDuff.Mode.CLEAR),
-            new PorterDuffXfermode(PorterDuff.Mode.SRC),
-            new PorterDuffXfermode(PorterDuff.Mode.DST),
-            new PorterDuffXfermode(PorterDuff.Mode.SRC_OVER),
-            new PorterDuffXfermode(PorterDuff.Mode.DST_OVER),
-            new PorterDuffXfermode(PorterDuff.Mode.SRC_IN),
-            new PorterDuffXfermode(PorterDuff.Mode.DST_IN),
-            new PorterDuffXfermode(PorterDuff.Mode.SRC_OUT),
-            new PorterDuffXfermode(PorterDuff.Mode.DST_OUT),
-            new PorterDuffXfermode(PorterDuff.Mode.SRC_ATOP),
-            new PorterDuffXfermode(PorterDuff.Mode.DST_ATOP),
-            new PorterDuffXfermode(PorterDuff.Mode.XOR),
-            new PorterDuffXfermode(PorterDuff.Mode.DARKEN),
-            new PorterDuffXfermode(PorterDuff.Mode.LIGHTEN),
-            new PorterDuffXfermode(PorterDuff.Mode.MULTIPLY),
-            new PorterDuffXfermode(PorterDuff.Mode.SCREEN)
-        };
-        
-        private static final String[] sLabels = {
-            "Clear", "Src", "Dst", "SrcOver",
-            "DstOver", "SrcIn", "DstIn", "SrcOut",
-            "DstOut", "SrcATop", "DstATop", "Xor",
-            "Darken", "Lighten", "Multiply", "Screen"
-        };
-        
-        public SampleView(Context context) {
-            super(context);
-            
-            mSrcB = makeSrc(W, H);
-            mDstB = makeDst(W, H);
-            
-            // make a ckeckerboard pattern
-            Bitmap bm = Bitmap.createBitmap(new int[] { 0xFFFFFFFF, 0xFFCCCCCC,
-                                            0xFFCCCCCC, 0xFFFFFFFF }, 2, 2,
-                                            Bitmap.Config.RGB_565);
-            mBG = new BitmapShader(bm,
-                                   Shader.TileMode.REPEAT,
-                                   Shader.TileMode.REPEAT);
-            Matrix m = new Matrix();
-            m.setScale(6, 6);
-            mBG.setLocalMatrix(m);
-        }
-        
-        @Override protected void onDraw(Canvas canvas) {
-            canvas.drawColor(Color.WHITE);
-            
-            Paint labelP = new Paint(Paint.ANTI_ALIAS_FLAG);
-            labelP.setTextAlign(Paint.Align.CENTER);
-            
-            Paint paint = new Paint();
-            paint.setFilterBitmap(false);
-            
-            canvas.translate(15, 35);
-            
-            int x = 0;
-            int y = 0;
-            for (int i = 0; i < sModes.length; i++) {
-                // draw the border
-                paint.setStyle(Paint.Style.STROKE);
-                paint.setShader(null);
-                canvas.drawRect(x - 0.5f, y - 0.5f,
-                                x + W + 0.5f, y + H + 0.5f, paint);
-                
-                // draw the checker-board pattern
-                paint.setStyle(Paint.Style.FILL);
-                paint.setShader(mBG);
-                canvas.drawRect(x, y, x + W, y + H, paint);
-                
-                // draw the src/dst example into our offscreen bitmap
-                int sc = canvas.saveLayer(x, y, x + W, y + H, null,
-                                          Canvas.MATRIX_SAVE_FLAG |
-                                          Canvas.CLIP_SAVE_FLAG |
-                                          Canvas.HAS_ALPHA_LAYER_SAVE_FLAG |
-                                          Canvas.FULL_COLOR_LAYER_SAVE_FLAG |
-                                          Canvas.CLIP_TO_LAYER_SAVE_FLAG);
-                canvas.translate(x, y);
-                canvas.drawBitmap(mDstB, 0, 0, paint);
-                paint.setXfermode(sModes[i]);
-                canvas.drawBitmap(mSrcB, 0, 0, paint);
-                paint.setXfermode(null);
-                canvas.restoreToCount(sc);
-                
-                // draw the label
-                canvas.drawText(sLabels[i],
-                                x + W/2, y - labelP.getTextSize()/2, labelP);
-                
-                x += W + 10;
-                
-                // wrap around when we've drawn enough for one row
-                if ((i % ROW_MAX) == ROW_MAX - 1) {
-                    x = 0;
-                    y += H + 30;
-                }
-            }
-        }
-    }
-}
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/_index.html b/samples/ApiDemos/src/com/example/android/apis/graphics/_index.html
deleted file mode 100644
index cd2ea53..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/_index.html
+++ /dev/null
@@ -1,48 +0,0 @@
-
-<h3>Drawable</h3>
-<dl>
-  <dt><a href="ShapeDrawable1.html">ShapeDrawable</a></dt>
-  <dd>Demonstrates creating Drawables in XML.</dd>
-</dl>
-
-<h3>OpenGL|ES</h3>
-<dl>
-  <dt><a href="CameraPreview.html">CameraPreview</a></dt>
-  <dd> Demonstrates capturing the image stream from the camera, drawing to a surface (extending SurfaceView) on a separate thread (extending Thread).</dd>
-
-  <dt><a href="GLSurfaceViewActivity.html">GL SurfaceView</a></dt>
-  <dd>Demonstrates how to perform OpenGL rendering in to a SurfaceView.
-  <dl>
-  <dt>Code:
-  <dd> <a href="GLSurfaceViewActivity.html">GLSurfaceViewActivity.java</a>,
-    <a href="GLSurfaceView.html">GLSurfaceView.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/hello_world.html">
-  hello_world.xml</a>
-  </dl>
-  </dd>
-
-  <dt><a href="PolyToPoly.html">PolyToPoly</a></dt>
-  <dd>Demonstrates calling the <a href="@{docRoot}reference/android/graphics/Matrix.html#setPolyToPoly(float[],%20int,%20float[],%20int,%20int)">Matrix.setPolyToPoly()</a> method to translate coordinates on a canvas to a new perspective (used to simulate perspective). </dd>
-
-  <dt><a href="DrawPoints.html">DrawPoints</a></dt>
-  <dd>Demonstrates using the <a href="android.graphics.Paint">Paint</a> and <a href="android.graphics.Canvas">Canvas</a> objects to draw random points on the screen, with different colors and strokes. </dd>
-
-  <dt><a href="PathEffects.html">PathEffects</a></dt>
-  <dd> Demonstrates the use of <a href="android.graphics.Path">Path</a> and various <a href="android.graphics.PathEffect">PathEffect</a> subclasses. </dd>
-
-  <dt><a href="SurfaceViewOverlay.html">SurfaceView Overlay</a></dt>
-  <dd>Shows how you can place overlays on top of a SurfaceView.
-  <dl>
-  <dt>Code:
-  <dd> <a href="SurfaceViewOverlay.html">SurfaceViewOverlay.java</a>,
-    <a href="GLSurfaceView.html">GLSurfaceView.java</a>
-  <dt>Layout:
-  <dd> <a href="{@docRoot}samples/ApiDemos/res/layout/surface_view_overlay.html">
-  surface_view_overlay.xml</a>
-  </dl>
-  </dd>
-
-  <dt><a href="TouchPaint.html">TouchPaint</a></dt>
-  <dd> Demonstrates the handling of touch screen events to implement a simple painting app. </dd>
-</dl>
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Cube.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Cube.java
deleted file mode 100644
index 015e19e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Cube.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-
-public class Cube extends GLShape {
-
-	public Cube(GLWorld world, float left, float bottom, float back, float right, float top, float front) {
-		super(world);
-       	GLVertex leftBottomBack = addVertex(left, bottom, back);
-       GLVertex rightBottomBack = addVertex(right, bottom, back);
-       	GLVertex leftTopBack = addVertex(left, top, back);
-        GLVertex rightTopBack = addVertex(right, top, back);
-       	GLVertex leftBottomFront = addVertex(left, bottom, front);
-        GLVertex rightBottomFront = addVertex(right, bottom, front);
-       	GLVertex leftTopFront = addVertex(left, top, front);
-        GLVertex rightTopFront = addVertex(right, top, front);
-
-        // vertices are added in a clockwise orientation (when viewed from the outside)
-        // bottom
-        addFace(new GLFace(leftBottomBack, leftBottomFront, rightBottomFront, rightBottomBack));
-        // front
-        addFace(new GLFace(leftBottomFront, leftTopFront, rightTopFront, rightBottomFront));
-        // left
-        addFace(new GLFace(leftBottomBack, leftTopBack, leftTopFront, leftBottomFront));
-        // right
-        addFace(new GLFace(rightBottomBack, rightBottomFront, rightTopFront, rightTopBack));
-        // back
-        addFace(new GLFace(leftBottomBack, rightBottomBack, rightTopBack, leftTopBack));
-        // top
-        addFace(new GLFace(leftTopBack, rightTopBack, rightTopFront, leftTopFront));
-		
-	}
-	
-    public static final int kBottom = 0;
-    public static final int kFront = 1;
-    public static final int kLeft = 2;
-    public static final int kRight = 3;
-    public static final int kBack = 4;
-    public static final int kTop = 5;
-
-	
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLColor.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLColor.java
deleted file mode 100644
index 7d4c7c1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLColor.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-public class GLColor {
-
-	public final int red;
-	public final int green;
-	public final int blue;
-	public final int alpha;
-	
-	public GLColor(int red, int green, int blue, int alpha) {
-		this.red = red;
-		this.green = green;
-		this.blue = blue;
-		this.alpha = alpha;
-	}
-
-	public GLColor(int red, int green, int blue) {
-		this.red = red;
-		this.green = green;
-		this.blue = blue;
-		this.alpha = 0x10000;
-	}
-	
-	public boolean equals(Object other) {
-		if (other instanceof GLColor) {
-			GLColor color = (GLColor)other;
-			return (red == color.red && green == color.green &&
-					blue == color.blue && alpha == color.alpha);
-		}
-		return false;
-	}
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLFace.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLFace.java
deleted file mode 100644
index d6e6754..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLFace.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import android.util.Log;
-
-import java.nio.ShortBuffer;
-import java.util.ArrayList;
-
-public class GLFace {
-
-	public GLFace() {
-		
-	}
-	
-	// for triangles
-	public GLFace(GLVertex v1, GLVertex v2, GLVertex v3) {
-		addVertex(v1);
-		addVertex(v2);
-		addVertex(v3);
-	}	
-	// for quadrilaterals
-	public GLFace(GLVertex v1, GLVertex v2, GLVertex v3, GLVertex v4) {
-		addVertex(v1);
-		addVertex(v2);
-		addVertex(v3);
-		addVertex(v4);
-	}
-		
-	public void addVertex(GLVertex v) {
-		mVertexList.add(v);
-	}
-	
-	// must be called after all vertices are added
-	public void setColor(GLColor c) {
-		
-		int last = mVertexList.size() - 1;
-		if (last < 2) {
-			Log.e("GLFace", "not enough vertices in setColor()");
-		} else {
-			GLVertex vertex = mVertexList.get(last);
-			
-			// only need to do this if the color has never been set
-			if (mColor == null) {
-				while (vertex.color != null) {
-					mVertexList.add(0, vertex);
-					mVertexList.remove(last + 1);
-					vertex = mVertexList.get(last);
-				}
-			}
-			
-			vertex.color = c;
-		}
-
-		mColor = c;
-	}
-	
-	public int getIndexCount() {
-		return (mVertexList.size() - 2) * 3;
-	}
-	
-	public void putIndices(ShortBuffer buffer) {
-		int last = mVertexList.size() - 1;
-
-		GLVertex v0 = mVertexList.get(0);
-		GLVertex vn = mVertexList.get(last);
-		
-		// push triangles into the buffer
-		for (int i = 1; i < last; i++) {
-			GLVertex v1 = mVertexList.get(i);
-			buffer.put(v0.index);
-			buffer.put(v1.index);
-			buffer.put(vn.index);
-			v0 = v1;
-		}
-	}
-	
-	private ArrayList<GLVertex> mVertexList = new ArrayList<GLVertex>();
-	private GLColor mColor;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLShape.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLShape.java
deleted file mode 100644
index 2b6a824..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLShape.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import java.nio.ShortBuffer;
-import java.util.ArrayList;
-import java.util.Iterator;
-
-public class GLShape {
-
-	public GLShape(GLWorld world) {
-		mWorld = world;
-	}
-	
-	public void addFace(GLFace face) {
-		mFaceList.add(face);
-	}
-	
-	public void setFaceColor(int face, GLColor color) {
-		mFaceList.get(face).setColor(color);
-	}
-			
-	public void putIndices(ShortBuffer buffer) {
-		Iterator<GLFace> iter = mFaceList.iterator();
-		while (iter.hasNext()) {
-			GLFace face = iter.next();
-			face.putIndices(buffer);
-		}		
-	}
-	
-	public int getIndexCount() {
-		int count = 0;
-		Iterator<GLFace> iter = mFaceList.iterator();
-		while (iter.hasNext()) {
-			GLFace face = iter.next();
-			count += face.getIndexCount();
-		}		
-		return count;
-	}
-
-	public GLVertex addVertex(float x, float y, float z) {
-		
-		// look for an existing GLVertex first
-		Iterator<GLVertex> iter = mVertexList.iterator();
-		while (iter.hasNext()) {
-			GLVertex vertex = iter.next();
-			if (vertex.x == x && vertex.y == y && vertex.z == z) {
-				return vertex;
-			}
-		}
-		
-		// doesn't exist, so create new vertex
-		GLVertex vertex = mWorld.addVertex(x, y, z);
-		mVertexList.add(vertex);
-		return vertex;
-	}
-
-	public void animateTransform(M4 transform) {
-		mAnimateTransform = transform;
-		
-		if (mTransform != null)
-			transform = mTransform.multiply(transform);
-
-		Iterator<GLVertex> iter = mVertexList.iterator();
-		while (iter.hasNext()) {
-			GLVertex vertex = iter.next();
-			mWorld.transformVertex(vertex, transform);
-		}
-	}
-	
-	public void startAnimation() {
-	}
-
-	public void endAnimation() {
-		if (mTransform == null) {
-			mTransform = new M4(mAnimateTransform);
-		} else {
-			mTransform = mTransform.multiply(mAnimateTransform);
-		}
-	}
-
-	public M4						mTransform;
-	public M4						mAnimateTransform;
-	protected ArrayList<GLFace>		mFaceList = new ArrayList<GLFace>();
-	protected ArrayList<GLVertex>	mVertexList = new ArrayList<GLVertex>();
-	protected ArrayList<Integer>	mIndexList = new ArrayList<Integer>();	// make more efficient?
-	protected GLWorld mWorld;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLVertex.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLVertex.java
deleted file mode 100644
index b5cd873..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLVertex.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import java.nio.IntBuffer;
-
-public class GLVertex {
-	
-	public float x;
-	public float y;
-	public float z;
-	final short index;	// index in vertex table
-	GLColor color;
-	
-	GLVertex() {
-		this.x = 0;
-		this.y = 0;
-		this.z = 0;
-		this.index = -1;
-	}
-
-	GLVertex(float x, float y, float z, int index) {
-		this.x = x;
-		this.y = y;
-		this.z = z;
-		this.index = (short)index;
-	}
-
-	public boolean equals(Object other) {
-		if (other instanceof GLVertex) {
-			GLVertex v = (GLVertex)other;
-			return (x == v.x && y == v.y && z == v.z);
-		}
-		return false;
-	}
-
-    static public int toFixed(float x) {
-    	return (int)(x*65536.0f);
-    }
-
-	public void put(IntBuffer vertexBuffer, IntBuffer colorBuffer) {
-		vertexBuffer.put(toFixed(x));
-		vertexBuffer.put(toFixed(y));
-		vertexBuffer.put(toFixed(z));
-		if (color == null) {
-			colorBuffer.put(0);
-			colorBuffer.put(0);
-			colorBuffer.put(0);
-			colorBuffer.put(0);
-		} else {
-			colorBuffer.put(color.red);
-			colorBuffer.put(color.green);
-			colorBuffer.put(color.blue);
-			colorBuffer.put(color.alpha);
-		}
-	}
-	
-	public void update(IntBuffer vertexBuffer, M4 transform) {
-		// skip to location of vertex in mVertex buffer
-		vertexBuffer.position(index * 3);
-	
-		if (transform == null) {
-			vertexBuffer.put(toFixed(x));
-			vertexBuffer.put(toFixed(y));
-			vertexBuffer.put(toFixed(z));			
-		} else {
-			GLVertex temp = new GLVertex();
-			transform.multiply(this, temp);
-			vertexBuffer.put(toFixed(temp.x));
-			vertexBuffer.put(toFixed(temp.y));
-			vertexBuffer.put(toFixed(temp.z));
-		}
-	}
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLWorld.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLWorld.java
deleted file mode 100644
index dd73174..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/GLWorld.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.IntBuffer;
-import java.nio.ShortBuffer;
-import java.util.Iterator;
-import java.util.ArrayList;
-
-import javax.microedition.khronos.opengles.GL10;
-
-public class GLWorld {
-
-	public void addShape(GLShape shape) {
-		mShapeList.add(shape);
-		mIndexCount += shape.getIndexCount();
-	}
-	
-	public void generate() {		
-	    ByteBuffer bb = ByteBuffer.allocateDirect(mVertexList.size()*4*4);
-	    bb.order(ByteOrder.nativeOrder());
-		mColorBuffer = bb.asIntBuffer();
-
-	    bb = ByteBuffer.allocateDirect(mVertexList.size()*4*3);
-	    bb.order(ByteOrder.nativeOrder());
-	    mVertexBuffer = bb.asIntBuffer();
-
-	    bb = ByteBuffer.allocateDirect(mIndexCount*2);
-	    bb.order(ByteOrder.nativeOrder());
-	    mIndexBuffer = bb.asShortBuffer();
-
-		Iterator<GLVertex> iter2 = mVertexList.iterator();
-		while (iter2.hasNext()) {
-			GLVertex vertex = iter2.next();
-			vertex.put(mVertexBuffer, mColorBuffer);
-		}
-
-		Iterator<GLShape> iter3 = mShapeList.iterator();
-		while (iter3.hasNext()) {
-			GLShape shape = iter3.next();
-			shape.putIndices(mIndexBuffer);
-		}
-	}
-	
-	public GLVertex addVertex(float x, float y, float z) {
-		GLVertex vertex = new GLVertex(x, y, z, mVertexList.size());
-		mVertexList.add(vertex);
-		return vertex;
-	}
-	
-	public void transformVertex(GLVertex vertex, M4 transform) {
-		vertex.update(mVertexBuffer, transform);
-	}
-
-	int count = 0;
-    public void draw(GL10 gl)
-    {
-		mColorBuffer.position(0);
-		mVertexBuffer.position(0);
-		mIndexBuffer.position(0);
-
-		gl.glFrontFace(GL10.GL_CW);
-        gl.glShadeModel(GL10.GL_FLAT);
-        gl.glVertexPointer(3, GL10.GL_FIXED, 0, mVertexBuffer);
-        gl.glColorPointer(4, GL10.GL_FIXED, 0, mColorBuffer);
-        gl.glDrawElements(GL10.GL_TRIANGLES, mIndexCount, GL10.GL_UNSIGNED_SHORT, mIndexBuffer);
-        count++;
-    }
-   
-    static public float toFloat(int x) {
-    	return x/65536.0f;
-    }
-
-	private ArrayList<GLShape>	mShapeList = new ArrayList<GLShape>();	
-	private ArrayList<GLVertex>	mVertexList = new ArrayList<GLVertex>();
-	
-	private int mIndexCount = 0;
-
-    private IntBuffer   mVertexBuffer;
-    private IntBuffer   mColorBuffer;
-    private ShortBuffer mIndexBuffer;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Kube.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Kube.java
deleted file mode 100644
index 9332941..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Kube.java
+++ /dev/null
@@ -1,342 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Window;
-
-import android.opengl.GLSurfaceView;
-
-import java.util.Random;
-
-public class Kube extends Activity implements KubeRenderer.AnimationCallback {
-
-    private GLWorld makeGLWorld()
-    {
-        GLWorld world = new GLWorld();
-
-        int one = 0x10000;
-        int half = 0x08000;
-        GLColor red = new GLColor(one, 0, 0);
-        GLColor green = new GLColor(0, one, 0);
-        GLColor blue = new GLColor(0, 0, one);
-        GLColor yellow = new GLColor(one, one, 0);
-        GLColor orange = new GLColor(one, half, 0);
-        GLColor white = new GLColor(one, one, one);
-        GLColor black = new GLColor(0, 0, 0);
-
-        // coordinates for our cubes
-        float c0 = -1.0f;
-        float c1 = -0.38f;
-        float c2 = -0.32f;
-        float c3 = 0.32f;
-        float c4 = 0.38f;
-        float c5 = 1.0f;
-
-        // top back, left to right
-        mCubes[0]  = new Cube(world, c0, c4, c0, c1, c5, c1);
-        mCubes[1]  = new Cube(world, c2, c4, c0, c3, c5, c1);
-        mCubes[2]  = new Cube(world, c4, c4, c0, c5, c5, c1);
-        // top middle, left to right
-        mCubes[3]  = new Cube(world, c0, c4, c2, c1, c5, c3);
-        mCubes[4]  = new Cube(world, c2, c4, c2, c3, c5, c3);
-        mCubes[5]  = new Cube(world, c4, c4, c2, c5, c5, c3);
-        // top front, left to right
-        mCubes[6]  = new Cube(world, c0, c4, c4, c1, c5, c5);
-        mCubes[7]  = new Cube(world, c2, c4, c4, c3, c5, c5);
-        mCubes[8]  = new Cube(world, c4, c4, c4, c5, c5, c5);
-        // middle back, left to right
-        mCubes[9]  = new Cube(world, c0, c2, c0, c1, c3, c1);
-        mCubes[10] = new Cube(world, c2, c2, c0, c3, c3, c1);
-        mCubes[11] = new Cube(world, c4, c2, c0, c5, c3, c1);
-        // middle middle, left to right
-        mCubes[12] = new Cube(world, c0, c2, c2, c1, c3, c3);
-        mCubes[13] = null;
-        mCubes[14] = new Cube(world, c4, c2, c2, c5, c3, c3);
-        // middle front, left to right
-        mCubes[15] = new Cube(world, c0, c2, c4, c1, c3, c5);
-        mCubes[16] = new Cube(world, c2, c2, c4, c3, c3, c5);
-        mCubes[17] = new Cube(world, c4, c2, c4, c5, c3, c5);
-        // bottom back, left to right
-        mCubes[18] = new Cube(world, c0, c0, c0, c1, c1, c1);
-        mCubes[19] = new Cube(world, c2, c0, c0, c3, c1, c1);
-        mCubes[20] = new Cube(world, c4, c0, c0, c5, c1, c1);
-        // bottom middle, left to right
-        mCubes[21] = new Cube(world, c0, c0, c2, c1, c1, c3);
-        mCubes[22] = new Cube(world, c2, c0, c2, c3, c1, c3);
-        mCubes[23] = new Cube(world, c4, c0, c2, c5, c1, c3);
-        // bottom front, left to right
-        mCubes[24] = new Cube(world, c0, c0, c4, c1, c1, c5);
-        mCubes[25] = new Cube(world, c2, c0, c4, c3, c1, c5);
-        mCubes[26] = new Cube(world, c4, c0, c4, c5, c1, c5);
-
-        // paint the sides
-        int i, j;
-        // set all faces black by default
-        for (i = 0; i < 27; i++) {
-            Cube cube = mCubes[i];
-            if (cube != null) {
-                for (j = 0; j < 6; j++)
-                    cube.setFaceColor(j, black);
-            }
-        }
-
-        // paint top
-        for (i = 0; i < 9; i++)
-            mCubes[i].setFaceColor(Cube.kTop, orange);
-        // paint bottom
-        for (i = 18; i < 27; i++)
-            mCubes[i].setFaceColor(Cube.kBottom, red);
-        // paint left
-        for (i = 0; i < 27; i += 3)
-            mCubes[i].setFaceColor(Cube.kLeft, yellow);
-        // paint right
-        for (i = 2; i < 27; i += 3)
-            mCubes[i].setFaceColor(Cube.kRight, white);
-        // paint back
-        for (i = 0; i < 27; i += 9)
-            for (j = 0; j < 3; j++)
-                mCubes[i + j].setFaceColor(Cube.kBack, blue);
-        // paint front
-        for (i = 6; i < 27; i += 9)
-            for (j = 0; j < 3; j++)
-                mCubes[i + j].setFaceColor(Cube.kFront, green);
-
-        for (i = 0; i < 27; i++)
-            if (mCubes[i] != null)
-                world.addShape(mCubes[i]);
-
-        // initialize our permutation to solved position
-        mPermutation = new int[27];
-        for (i = 0; i < mPermutation.length; i++)
-            mPermutation[i] = i;
-
-        createLayers();
-        updateLayers();
-
-        world.generate();
-
-        return world;
-    }
-
-    private void createLayers() {
-        mLayers[kUp] = new Layer(Layer.kAxisY);
-        mLayers[kDown] = new Layer(Layer.kAxisY);
-        mLayers[kLeft] = new Layer(Layer.kAxisX);
-        mLayers[kRight] = new Layer(Layer.kAxisX);
-        mLayers[kFront] = new Layer(Layer.kAxisZ);
-        mLayers[kBack] = new Layer(Layer.kAxisZ);
-        mLayers[kMiddle] = new Layer(Layer.kAxisX);
-        mLayers[kEquator] = new Layer(Layer.kAxisY);
-        mLayers[kSide] = new Layer(Layer.kAxisZ);
-    }
-
-    private void updateLayers() {
-        Layer layer;
-        GLShape[] shapes;
-        int i, j, k;
-
-        // up layer
-        layer = mLayers[kUp];
-        shapes = layer.mShapes;
-        for (i = 0; i < 9; i++)
-            shapes[i] = mCubes[mPermutation[i]];
-
-        // down layer
-        layer = mLayers[kDown];
-        shapes = layer.mShapes;
-        for (i = 18, k = 0; i < 27; i++)
-            shapes[k++] = mCubes[mPermutation[i]];
-
-        // left layer
-        layer = mLayers[kLeft];
-        shapes = layer.mShapes;
-        for (i = 0, k = 0; i < 27; i += 9)
-            for (j = 0; j < 9; j += 3)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-
-        // right layer
-        layer = mLayers[kRight];
-        shapes = layer.mShapes;
-        for (i = 2, k = 0; i < 27; i += 9)
-            for (j = 0; j < 9; j += 3)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-
-        // front layer
-        layer = mLayers[kFront];
-        shapes = layer.mShapes;
-        for (i = 6, k = 0; i < 27; i += 9)
-            for (j = 0; j < 3; j++)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-
-        // back layer
-        layer = mLayers[kBack];
-        shapes = layer.mShapes;
-        for (i = 0, k = 0; i < 27; i += 9)
-            for (j = 0; j < 3; j++)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-
-        // middle layer
-        layer = mLayers[kMiddle];
-        shapes = layer.mShapes;
-        for (i = 1, k = 0; i < 27; i += 9)
-            for (j = 0; j < 9; j += 3)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-
-        // equator layer
-        layer = mLayers[kEquator];
-        shapes = layer.mShapes;
-        for (i = 9, k = 0; i < 18; i++)
-            shapes[k++] = mCubes[mPermutation[i]];
-
-        // side layer
-        layer = mLayers[kSide];
-        shapes = layer.mShapes;
-        for (i = 3, k = 0; i < 27; i += 9)
-            for (j = 0; j < 3; j++)
-                shapes[k++] = mCubes[mPermutation[i + j]];
-    }
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-
-        // We don't need a title either.
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-
-        mView = new GLSurfaceView(getApplication());
-        mRenderer = new KubeRenderer(makeGLWorld(), this);
-        mView.setRenderer(mRenderer);
-        setContentView(mView);
-    }
-
-    @Override
-    protected void onResume()
-    {
-        super.onResume();
-        mView.onResume();
-    }
-
-    @Override
-    protected void onPause()
-    {
-        super.onPause();
-        mView.onPause();
-    }
-
-    public void animate() {
-        // change our angle of view
-        mRenderer.setAngle(mRenderer.getAngle() + 1.2f);
-
-        if (mCurrentLayer == null) {
-            int layerID = mRandom.nextInt(9);
-            mCurrentLayer = mLayers[layerID];
-            mCurrentLayerPermutation = mLayerPermutations[layerID];
-            mCurrentLayer.startAnimation();
-            boolean direction = mRandom.nextBoolean();
-            int count = mRandom.nextInt(3) + 1;
-
-            count = 1;
-            direction = false;
-            mCurrentAngle = 0;
-             if (direction) {
-                mAngleIncrement = (float)Math.PI / 50;
-                   mEndAngle = mCurrentAngle + ((float)Math.PI * count) / 2f;
-               } else {
-                mAngleIncrement = -(float)Math.PI / 50;
-                   mEndAngle = mCurrentAngle - ((float)Math.PI * count) / 2f;
-            }
-        }
-
-         mCurrentAngle += mAngleIncrement;
-
-         if ((mAngleIncrement > 0f && mCurrentAngle >= mEndAngle) ||
-                 (mAngleIncrement < 0f && mCurrentAngle <= mEndAngle)) {
-             mCurrentLayer.setAngle(mEndAngle);
-             mCurrentLayer.endAnimation();
-             mCurrentLayer = null;
-
-             // adjust mPermutation based on the completed layer rotation
-             int[] newPermutation = new int[27];
-             for (int i = 0; i < 27; i++) {
-                newPermutation[i] = mPermutation[mCurrentLayerPermutation[i]];
- //    			newPermutation[i] = mCurrentLayerPermutation[mPermutation[i]];
-             }
-             mPermutation = newPermutation;
-             updateLayers();
-
-         } else {
-             mCurrentLayer.setAngle(mCurrentAngle);
-         }
-    }
-
-    GLSurfaceView mView;
-    KubeRenderer mRenderer;
-    Cube[] mCubes = new Cube[27];
-    // a Layer for each possible move
-    Layer[] mLayers = new Layer[9];
-    // permutations corresponding to a pi/2 rotation of each layer about its axis
-    static int[][] mLayerPermutations = {
-            // permutation for UP layer
-            { 2, 5, 8, 1, 4, 7, 0, 3, 6, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26 },
-            // permutation for DOWN layer
-            { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 20, 23, 26, 19, 22, 25, 18, 21, 24 },
-            // permutation for LEFT layer
-            { 6, 1, 2, 15, 4, 5, 24, 7, 8, 3, 10, 11, 12, 13, 14, 21, 16, 17, 0, 19, 20, 9, 22, 23, 18, 25, 26 },
-            // permutation for RIGHT layer
-            { 0, 1, 8, 3, 4, 17, 6, 7, 26, 9, 10, 5, 12, 13, 14, 15, 16, 23, 18, 19, 2, 21, 22, 11, 24, 25, 20 },
-            // permutation for FRONT layer
-            { 0, 1, 2, 3, 4, 5, 24, 15, 6, 9, 10, 11, 12, 13, 14, 25, 16, 7, 18, 19, 20, 21, 22, 23, 26, 17, 8 },
-            // permutation for BACK layer
-            { 18, 9, 0, 3, 4, 5, 6, 7, 8, 19, 10, 1, 12, 13, 14, 15, 16, 17, 20, 11, 2, 21, 22, 23, 24, 25, 26 },
-            // permutation for MIDDLE layer
-            { 0, 7, 2, 3, 16, 5, 6, 25, 8, 9, 4, 11, 12, 13, 14, 15, 22, 17, 18, 1, 20, 21, 10, 23, 24, 19, 26 },
-            // permutation for EQUATOR layer
-            { 0, 1, 2, 3, 4, 5, 6, 7, 8, 11, 14, 17, 10, 13, 16, 9, 12, 15, 18, 19, 20, 21, 22, 23, 24, 25, 26 },
-            // permutation for SIDE layer
-            { 0, 1, 2, 21, 12, 3, 6, 7, 8, 9, 10, 11, 22, 13, 4, 15, 16, 17, 18, 19, 20, 23, 14, 5, 24, 25, 26 }
-    };
-
-
-
-    // current permutation of starting position
-    int[] mPermutation;
-
-    // for random cube movements
-    Random mRandom = new Random(System.currentTimeMillis());
-    // currently turning layer
-    Layer mCurrentLayer = null;
-    // current and final angle for current Layer animation
-    float mCurrentAngle, mEndAngle;
-    // amount to increment angle
-    float mAngleIncrement;
-    int[] mCurrentLayerPermutation;
-
-    // names for our 9 layers (based on notation from http://www.cubefreak.net/notation.html)
-    static final int kUp = 0;
-    static final int kDown = 1;
-    static final int kLeft = 2;
-    static final int kRight = 3;
-    static final int kFront = 4;
-    static final int kBack = 5;
-    static final int kMiddle = 6;
-    static final int kEquator = 7;
-    static final int kSide = 8;
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/KubeRenderer.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/KubeRenderer.java
deleted file mode 100644
index 252f566..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/KubeRenderer.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-import android.opengl.GLSurfaceView;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-
-/**
- * Example of how to use OpenGL|ES in a custom view
- *
- */
-class KubeRenderer implements GLSurfaceView.Renderer {
-    public interface AnimationCallback {
-        void animate();
-    }
-
-    public KubeRenderer(GLWorld world, AnimationCallback callback) {
-        mWorld = world;
-        mCallback = callback;
-    }
-
-    public void onDrawFrame(GL10 gl) {
-         if (mCallback != null) {
-             mCallback.animate();
-         }
-
-        /*
-         * Usually, the first thing one might want to do is to clear
-         * the screen. The most efficient way of doing this is to use
-         * glClear(). However we must make sure to set the scissor
-         * correctly first. The scissor is always specified in window
-         * coordinates:
-         */
-
-        gl.glClearColor(0.5f,0.5f,0.5f,1);
-        gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-        /*
-         * Now we're ready to draw some 3D object
-         */
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-        gl.glTranslatef(0, 0, -3.0f);
-        gl.glScalef(0.5f, 0.5f, 0.5f);
-        gl.glRotatef(mAngle,        0, 1, 0);
-        gl.glRotatef(mAngle*0.25f,  1, 0, 0);
-
-        gl.glColor4f(0.7f, 0.7f, 0.7f, 1.0f);
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-        gl.glEnableClientState(GL10.GL_COLOR_ARRAY);
-        gl.glEnable(GL10.GL_CULL_FACE);
-        gl.glShadeModel(GL10.GL_SMOOTH);
-        gl.glEnable(GL10.GL_DEPTH_TEST);
-
-        mWorld.draw(gl);
-    }
-
-    public int[] getConfigSpec() {
-        // Need a depth buffer, don't care about color depth.
-        int[] configSpec = {
-                EGL10.EGL_DEPTH_SIZE,   16,
-                EGL10.EGL_NONE
-        };
-        return configSpec;
-    }
-
-    public void onSurfaceChanged(GL10 gl, int width, int height) {
-        gl.glViewport(0, 0, width, height);
-
-        /*
-         * Set our projection matrix. This doesn't have to be done
-         * each time we draw, but usually a new projection needs to be set
-         * when the viewport is resized.
-         */
-
-        float ratio = (float)width / height;
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glLoadIdentity();
-        gl.glFrustumf(-ratio, ratio, -1, 1, 2, 12);
-
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-        gl.glActiveTexture(GL10.GL_TEXTURE0);
-    }
-
-    public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-        // Nothing special, don't have any textures we need to recreate.
-    }
-
-    public void setAngle(float angle) {
-        mAngle = angle;
-    }
-
-    public float getAngle() {
-        return mAngle;
-    }
-
-    private GLWorld mWorld;
-    private AnimationCallback mCallback;
-    private float mAngle;
-}
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Layer.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Layer.java
deleted file mode 100644
index 5e27296..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/Layer.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-public class Layer {
-	
-	public Layer(int axis) {
-		// start with identity matrix for transformation
-		mAxis = axis;
-		mTransform.setIdentity();
-	}
-	
-	public void startAnimation() {
-		for (int i = 0; i < mShapes.length; i++) {
-			GLShape shape = mShapes[i];
-			if (shape != null) {
-				shape.startAnimation();
-			}	
-		}
-	}
-
-	public void endAnimation() {
-		for (int i = 0; i < mShapes.length; i++) {
-			GLShape shape = mShapes[i];
-			if (shape != null) {
-				shape.endAnimation();
-			}	
-		}
-	}
-	
-	public void setAngle(float angle) {
-		// normalize the angle
-		float twopi = (float)Math.PI *2f;
-		while (angle >= twopi) angle -= twopi;
-		while (angle < 0f) angle += twopi;
-//		mAngle = angle;
-		
-		float sin = (float)Math.sin(angle);
-		float cos = (float)Math.cos(angle);
-		
-		float[][] m = mTransform.m;
-		switch (mAxis) {
-			case kAxisX:
-				m[1][1] = cos;
-				m[1][2] = sin;
-				m[2][1] = -sin;
-				m[2][2] = cos;
-				m[0][0] = 1f;
-				m[0][1] = m[0][2] = m[1][0] = m[2][0] = 0f;
-				break;
-			case kAxisY:
-				m[0][0] = cos;
-				m[0][2] = sin;
-				m[2][0] = -sin;
-				m[2][2] = cos;
-				m[1][1] = 1f;
-				m[0][1] = m[1][0] = m[1][2] = m[2][1] = 0f;
-				break;
-			case kAxisZ:
-				m[0][0] = cos;
-				m[0][1] = sin;
-				m[1][0] = -sin;
-				m[1][1] = cos;
-				m[2][2] = 1f;
-				m[2][0] = m[2][1] = m[0][2] = m[1][2] = 0f;
-				break;
-		}
-		
-		for (int i = 0; i < mShapes.length; i++) {
-			GLShape shape = mShapes[i];
-			if (shape != null) {
-				shape.animateTransform(mTransform);
-			}
-		}
-	}
-	
-	GLShape[] mShapes = new GLShape[9];
-	M4 mTransform = new M4();
-//	float mAngle;
-
-	// which axis do we rotate around?
-	// 0 for X, 1 for Y, 2 for Z
-	int mAxis;
-	static public final int kAxisX = 0;
-	static public final int kAxisY = 1;
-	static public final int kAxisZ = 2;	
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/M4.java b/samples/ApiDemos/src/com/example/android/apis/graphics/kube/M4.java
deleted file mode 100644
index b6cc2fe..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/kube/M4.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.kube;
-
-/** 
- * 
- * A 4x4 float matrix
- *
- */
-public class M4 {
-	public float[][] m = new float[4][4];
-	
-	public M4() {
-	}
-	
-	public M4(M4 other) {
-		for (int i = 0; i < 4; i++) {
-			for (int j = 0; j < 4; j++) {
-				m[i][j] = other.m[i][j];
-			}
-		}		
-	}
-
-	public void multiply(GLVertex src, GLVertex dest) {
-		dest.x = src.x * m[0][0] + src.y * m[1][0] + src.z * m[2][0] + m[3][0];
-		dest.y = src.x * m[0][1] + src.y * m[1][1] + src.z * m[2][1] + m[3][1];
-		dest.z = src.x * m[0][2] + src.y * m[1][2] + src.z * m[2][2] + m[3][2];
-	}
-	
-	public M4 multiply(M4 other) {
-		M4 result = new M4();
-		float[][] m1 = m;
-		float[][] m2 = other.m;
-		
-		for (int i = 0; i < 4; i++) {
-			for (int j = 0; j < 4; j++) {
-				result.m[i][j] = m1[i][0]*m2[0][j] + m1[i][1]*m2[1][j] + m1[i][2]*m2[2][j] + m1[i][3]*m2[3][j];
-			}
-		}
-		
-		return result;
-	}
-	
-	public void setIdentity() {
-		for (int i = 0; i < 4; i++) {
-			for (int j = 0; j < 4; j++) {
-				m[i][j] = (i == j ? 1f : 0f);
-			}
-		}
-	}
-	
-	@Override
-	public String toString() {
-		StringBuilder builder = new StringBuilder("[ ");
-		for (int i = 0; i < 4; i++) {
-			for (int j = 0; j < 4; j++) {
-				builder.append(m[i][j]);
-				builder.append(" ");
-			}
-			if (i < 2)
-				builder.append("\n  ");
-		}
-		builder.append(" ]");
-		return builder.toString();
-	}
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Grid.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Grid.java
deleted file mode 100644
index 81863a0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Grid.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import java.nio.CharBuffer;
-import java.nio.FloatBuffer;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * A 2D rectangular mesh. Can be drawn textured or untextured.
- *
- */
-class Grid {
-
-	public Grid(int w, int h) {
-		if (w < 0 || w >= 65536) {
-			throw new IllegalArgumentException("w");
-		}
-		if (h < 0 || h >= 65536) {
-			throw new IllegalArgumentException("h");
-		}
-		if (w * h >= 65536) {
-			throw new IllegalArgumentException("w * h >= 65536");
-		}
-
-		mW = w;
-		mH = h;
-		int size = w * h;
-		mVertexArray = new float[size * 3];
-		mVertexBuffer = FloatBuffer.wrap(mVertexArray);
-
-		mTexCoordArray = new float[size * 2];
-		mTexCoordBuffer = FloatBuffer.wrap(mTexCoordArray);
-
-		int quadW = mW - 1;
-		int quadH = mH - 1;
-		int quadCount = quadW * quadH;
-		int indexCount = quadCount * 6;
-		mIndexCount = indexCount;
-		char[] indexArray = new char[indexCount];
-
-		/*
-		 * Initialize triangle list mesh.
-		 *
-		 *     [0]-----[  1] ...
-		 *      |    /   |
-		 *      |   /    |
-		 *      |  /     |
-		 *     [w]-----[w+1] ...
-		 *      |       |
-		 *
-		 */
-
-		{
-			int i = 0;
-			for (int y = 0; y < quadH; y++) {
-				for (int x = 0; x < quadW; x++) {
-					char a = (char) (y * mW + x);
-					char b = (char) (y * mW + x + 1);
-					char c = (char) ((y + 1) * mW + x);
-					char d = (char) ((y + 1) * mW + x + 1);
-
-					indexArray[i++] = a;
-					indexArray[i++] = b;
-					indexArray[i++] = c;
-
-					indexArray[i++] = b;
-					indexArray[i++] = c;
-					indexArray[i++] = d;
-				}
-			}
-		}
-
-		mIndexBuffer = CharBuffer.wrap(indexArray);
-	}
-
-	void set(int i, int j, float x, float y, float z, float u, float v) {
-		if (i < 0 || i >= mW) {
-			throw new IllegalArgumentException("i");
-		}
-		if (j < 0 || j >= mH) {
-			throw new IllegalArgumentException("j");
-		}
-
-		int index = mW * j + i;
-
-		int posIndex = index * 3;
-		mVertexArray[posIndex] = x;
-		mVertexArray[posIndex + 1] = y;
-		mVertexArray[posIndex + 2] = z;
-
-		int texIndex = index * 2;
-		mTexCoordArray[texIndex] = u;
-		mTexCoordArray[texIndex + 1] = v;
-	}
-
-	public void draw(GL10 gl, boolean useTexture) {
-		gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-		gl.glVertexPointer(3, GL10.GL_FLOAT, 0, mVertexBuffer);
-
-		if (useTexture) {
-			gl.glEnableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-			gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, mTexCoordBuffer);
-			gl.glEnable(GL10.GL_TEXTURE_2D);
-		} else {
-			gl.glDisableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-			gl.glDisable(GL10.GL_TEXTURE_2D);
-		}
-
-		gl.glDrawElements(GL10.GL_TRIANGLES, mIndexCount,
-				GL10.GL_UNSIGNED_SHORT, mIndexBuffer);
-        gl.glDisableClientState(GL10.GL_VERTEX_ARRAY);
-	}
-
-	private FloatBuffer mVertexBuffer;
-	private float[] mVertexArray;
-
-	private FloatBuffer mTexCoordBuffer;
-	private float[] mTexCoordArray;
-
-	private CharBuffer mIndexBuffer;
-
-	private int mW;
-	private int mH;
-	private int mIndexCount;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/LabelMaker.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/LabelMaker.java
deleted file mode 100644
index 4bf87f7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/LabelMaker.java
+++ /dev/null
@@ -1,431 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.graphics.Paint.Style;
-import android.graphics.drawable.Drawable;
-import android.opengl.GLUtils;
-
-import java.util.ArrayList;
-
-import javax.microedition.khronos.opengles.GL10;
-import javax.microedition.khronos.opengles.GL11;
-import javax.microedition.khronos.opengles.GL11Ext;
-
-/**
- * An OpenGL text label maker.
- *
- *
- * OpenGL labels are implemented by creating a Bitmap, drawing all the labels
- * into the Bitmap, converting the Bitmap into an Alpha texture, and creating a
- * mesh for each label
- *
- * The benefits of this approach are that the labels are drawn using the high
- * quality anti-aliased font rasterizer, full character set support, and all the
- * text labels are stored on a single texture, which makes it faster to use.
- *
- * The drawbacks are that you can only have as many labels as will fit onto one
- * texture, and you have to recreate the whole texture if any label text
- * changes.
- *
- */
-public class LabelMaker {
-    /**
-     * Create a label maker
-     * or maximum compatibility with various OpenGL ES implementations,
-     * the strike width and height must be powers of two,
-     * We want the strike width to be at least as wide as the widest window.
-     *
-     * @param fullColor true if we want a full color backing store (4444),
-     * otherwise we generate a grey L8 backing store.
-     * @param strikeWidth width of strike
-     * @param strikeHeight height of strike
-     */
-    public LabelMaker(boolean fullColor, int strikeWidth, int strikeHeight) {
-        mFullColor = fullColor;
-        mStrikeWidth = strikeWidth;
-        mStrikeHeight = strikeHeight;
-        mTexelWidth = (float) (1.0 / mStrikeWidth);
-        mTexelHeight = (float) (1.0 / mStrikeHeight);
-        mClearPaint = new Paint();
-        mClearPaint.setARGB(0, 0, 0, 0);
-        mClearPaint.setStyle(Style.FILL);
-        mState = STATE_NEW;
-    }
-
-    /**
-     * Call to initialize the class.
-     * Call whenever the surface has been created.
-     *
-     * @param gl
-     */
-    public void initialize(GL10 gl) {
-        mState = STATE_INITIALIZED;
-        int[] textures = new int[1];
-        gl.glGenTextures(1, textures, 0);
-        mTextureID = textures[0];
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-
-        // Use Nearest for performance.
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MIN_FILTER,
-                GL10.GL_NEAREST);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MAG_FILTER,
-                GL10.GL_NEAREST);
-
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S,
-                GL10.GL_CLAMP_TO_EDGE);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T,
-                GL10.GL_CLAMP_TO_EDGE);
-
-        gl.glTexEnvf(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE,
-                GL10.GL_REPLACE);
-    }
-
-    /**
-     * Call when the surface has been destroyed
-     */
-    public void shutdown(GL10 gl) {
-        if ( gl != null) {
-            if (mState > STATE_NEW) {
-                int[] textures = new int[1];
-                textures[0] = mTextureID;
-                gl.glDeleteTextures(1, textures, 0);
-                mState = STATE_NEW;
-            }
-        }
-    }
-
-    /**
-     * Call before adding labels. Clears out any existing labels.
-     *
-     * @param gl
-     */
-    public void beginAdding(GL10 gl) {
-        checkState(STATE_INITIALIZED, STATE_ADDING);
-        mLabels.clear();
-        mU = 0;
-        mV = 0;
-        mLineHeight = 0;
-        Bitmap.Config config = mFullColor ?
-                Bitmap.Config.ARGB_4444 : Bitmap.Config.ALPHA_8;
-        mBitmap = Bitmap.createBitmap(mStrikeWidth, mStrikeHeight, config);
-        mCanvas = new Canvas(mBitmap);
-        mBitmap.eraseColor(0);
-    }
-
-    /**
-     * Call to add a label
-     *
-     * @param gl
-     * @param text the text of the label
-     * @param textPaint the paint of the label
-     * @return the id of the label, used to measure and draw the label
-     */
-    public int add(GL10 gl, String text, Paint textPaint) {
-        return add(gl, null, text, textPaint);
-    }
-
-    /**
-     * Call to add a label
-     *
-     * @param gl
-     * @param text the text of the label
-     * @param textPaint the paint of the label
-     * @return the id of the label, used to measure and draw the label
-     */
-    public int add(GL10 gl, Drawable background, String text, Paint textPaint) {
-        return add(gl, background, text, textPaint, 0, 0);
-    }
-
-    /**
-     * Call to add a label
-     * @return the id of the label, used to measure and draw the label
-     */
-    public int add(GL10 gl, Drawable drawable, int minWidth, int minHeight) {
-        return add(gl, drawable, null, null, minWidth, minHeight);
-    }
-
-    /**
-     * Call to add a label
-     *
-     * @param gl
-     * @param text the text of the label
-     * @param textPaint the paint of the label
-     * @return the id of the label, used to measure and draw the label
-     */
-    public int add(GL10 gl, Drawable background, String text, Paint textPaint,
-            int minWidth, int minHeight) {
-        checkState(STATE_ADDING, STATE_ADDING);
-        boolean drawBackground = background != null;
-        boolean drawText = (text != null) && (textPaint != null);
-
-        Rect padding = new Rect();
-        if (drawBackground) {
-            background.getPadding(padding);
-            minWidth = Math.max(minWidth, background.getMinimumWidth());
-            minHeight = Math.max(minHeight, background.getMinimumHeight());
-        }
-
-        int ascent = 0;
-        int descent = 0;
-        int measuredTextWidth = 0;
-        if (drawText) {
-            // Paint.ascent is negative, so negate it.
-            ascent = (int) Math.ceil(-textPaint.ascent());
-            descent = (int) Math.ceil(textPaint.descent());
-            measuredTextWidth = (int) Math.ceil(textPaint.measureText(text));
-        }
-        int textHeight = ascent + descent;
-        int textWidth = Math.min(mStrikeWidth,measuredTextWidth);
-
-        int padHeight = padding.top + padding.bottom;
-        int padWidth = padding.left + padding.right;
-        int height = Math.max(minHeight, textHeight + padHeight);
-        int width = Math.max(minWidth, textWidth + padWidth);
-        int effectiveTextHeight = height - padHeight;
-        int effectiveTextWidth = width - padWidth;
-
-        int centerOffsetHeight = (effectiveTextHeight - textHeight) / 2;
-        int centerOffsetWidth = (effectiveTextWidth - textWidth) / 2;
-
-        // Make changes to the local variables, only commit them
-        // to the member variables after we've decided not to throw
-        // any exceptions.
-
-        int u = mU;
-        int v = mV;
-        int lineHeight = mLineHeight;
-
-        if (width > mStrikeWidth) {
-            width = mStrikeWidth;
-        }
-
-        // Is there room for this string on the current line?
-        if (u + width > mStrikeWidth) {
-            // No room, go to the next line:
-            u = 0;
-            v += lineHeight;
-            lineHeight = 0;
-        }
-        lineHeight = Math.max(lineHeight, height);
-        if (v + lineHeight > mStrikeHeight) {
-            throw new IllegalArgumentException("Out of texture space.");
-        }
-
-        int u2 = u + width;
-        int vBase = v + ascent;
-        int v2 = v + height;
-
-        if (drawBackground) {
-            background.setBounds(u, v, u + width, v + height);
-            background.draw(mCanvas);
-        }
-
-        if (drawText) {
-            mCanvas.drawText(text,
-                    u + padding.left + centerOffsetWidth,
-                    vBase + padding.top + centerOffsetHeight,
-                    textPaint);
-        }
-
-        Grid grid = new Grid(2, 2);
-        // Grid.set arguments: i, j, x, y, z, u, v
-
-        float texU = u * mTexelWidth;
-        float texU2 = u2 * mTexelWidth;
-        float texV = 1.0f - v * mTexelHeight;
-        float texV2 = 1.0f - v2 * mTexelHeight;
-
-        grid.set(0, 0,   0.0f,   0.0f, 0.0f, texU , texV2);
-        grid.set(1, 0,  width,   0.0f, 0.0f, texU2, texV2);
-        grid.set(0, 1,   0.0f, height, 0.0f, texU , texV );
-        grid.set(1, 1,  width, height, 0.0f, texU2, texV );
-
-        // We know there's enough space, so update the member variables
-        mU = u + width;
-        mV = v;
-        mLineHeight = lineHeight;
-        mLabels.add(new Label(grid, width, height, ascent,
-                u, v + height, width, -height));
-        return mLabels.size() - 1;
-    }
-
-    /**
-     * Call to end adding labels. Must be called before drawing starts.
-     *
-     * @param gl
-     */
-    public void endAdding(GL10 gl) {
-        checkState(STATE_ADDING, STATE_INITIALIZED);
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-        GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, mBitmap, 0);
-        // Reclaim storage used by bitmap and canvas.
-        mBitmap.recycle();
-        mBitmap = null;
-        mCanvas = null;
-    }
-
-    /**
-     * Get the width in pixels of a given label.
-     *
-     * @param labelID
-     * @return the width in pixels
-     */
-    public float getWidth(int labelID) {
-        return mLabels.get(labelID).width;
-    }
-
-    /**
-     * Get the height in pixels of a given label.
-     *
-     * @param labelID
-     * @return the height in pixels
-     */
-    public float getHeight(int labelID) {
-        return mLabels.get(labelID).height;
-    }
-
-    /**
-     * Get the baseline of a given label. That's how many pixels from the top of
-     * the label to the text baseline. (This is equivalent to the negative of
-     * the label's paint's ascent.)
-     *
-     * @param labelID
-     * @return the baseline in pixels.
-     */
-    public float getBaseline(int labelID) {
-        return mLabels.get(labelID).baseline;
-    }
-
-    /**
-     * Begin drawing labels. Sets the OpenGL state for rapid drawing.
-     *
-     * @param gl
-     * @param viewWidth
-     * @param viewHeight
-     */
-    public void beginDrawing(GL10 gl, float viewWidth, float viewHeight) {
-        checkState(STATE_INITIALIZED, STATE_DRAWING);
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-        gl.glShadeModel(GL10.GL_FLAT);
-        gl.glEnable(GL10.GL_BLEND);
-        gl.glBlendFunc(GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA);
-        gl.glColor4x(0x10000, 0x10000, 0x10000, 0x10000);
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glPushMatrix();
-        gl.glLoadIdentity();
-        gl.glOrthof(0.0f, viewWidth, 0.0f, viewHeight, 0.0f, 1.0f);
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glPushMatrix();
-        gl.glLoadIdentity();
-        // Magic offsets to promote consistent rasterization.
-        gl.glTranslatef(0.375f, 0.375f, 0.0f);
-    }
-
-    /**
-     * Draw a given label at a given x,y position, expressed in pixels, with the
-     * lower-left-hand-corner of the view being (0,0).
-     *
-     * @param gl
-     * @param x
-     * @param y
-     * @param labelID
-     */
-    public void draw(GL10 gl, float x, float y, int labelID) {
-        checkState(STATE_DRAWING, STATE_DRAWING);
-        gl.glPushMatrix();
-        float snappedX = (float) Math.floor(x);
-        float snappedY = (float) Math.floor(y);
-        gl.glTranslatef(snappedX, snappedY, 0.0f);
-        Label label = mLabels.get(labelID);
-        gl.glEnable(GL10.GL_TEXTURE_2D);
-        ((GL11)gl).glTexParameteriv(GL10.GL_TEXTURE_2D,
-                GL11Ext.GL_TEXTURE_CROP_RECT_OES, label.mCrop, 0);
-        ((GL11Ext)gl).glDrawTexiOES((int) snappedX, (int) snappedY, 0,
-                (int) label.width, (int) label.height);
-        gl.glPopMatrix();
-    }
-
-    /**
-     * Ends the drawing and restores the OpenGL state.
-     *
-     * @param gl
-     */
-    public void endDrawing(GL10 gl) {
-        checkState(STATE_DRAWING, STATE_INITIALIZED);
-        gl.glDisable(GL10.GL_BLEND);
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glPopMatrix();
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glPopMatrix();
-    }
-
-    private void checkState(int oldState, int newState) {
-        if (mState != oldState) {
-            throw new IllegalArgumentException("Can't call this method now.");
-        }
-        mState = newState;
-    }
-
-    private static class Label {
-        public Label(Grid grid, float width, float height, float baseLine,
-                int cropU, int cropV, int cropW, int cropH) {
-            this.grid = grid;
-            this.width = width;
-            this.height = height;
-            this.baseline = baseLine;
-            int[] crop = new int[4];
-            crop[0] = cropU;
-            crop[1] = cropV;
-            crop[2] = cropW;
-            crop[3] = cropH;
-            mCrop = crop;
-        }
-
-        public Grid grid;
-        public float width;
-        public float height;
-        public float baseline;
-        public int[] mCrop;
-    }
-
-    private int mStrikeWidth;
-    private int mStrikeHeight;
-    private boolean mFullColor;
-    private Bitmap mBitmap;
-    private Canvas mCanvas;
-    private Paint mClearPaint;
-
-    private int mTextureID;
-
-    private float mTexelWidth;  // Convert texel to U
-    private float mTexelHeight; // Convert texel to V
-    private int mU;
-    private int mV;
-    private int mLineHeight;
-    private ArrayList<Label> mLabels = new ArrayList<Label>();
-
-    private static final int STATE_NEW = 0;
-    private static final int STATE_INITIALIZED = 1;
-    private static final int STATE_ADDING = 2;
-    private static final int STATE_DRAWING = 3;
-    private int mState;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixGrabber.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixGrabber.java
deleted file mode 100644
index 87c9076..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixGrabber.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import javax.microedition.khronos.opengles.GL10;
-
-class MatrixGrabber {
-    public MatrixGrabber() {
-        mModelView = new float[16];
-        mProjection = new float[16];
-    }
-
-    /**
-     * Record the current modelView and projection matrix state.
-     * Has the side effect of setting the current matrix state to GL_MODELVIEW
-     * @param gl
-     */
-    public void getCurrentState(GL10 gl) {
-        getCurrentProjection(gl);
-        getCurrentModelView(gl);
-    }
-
-    /**
-     * Record the current modelView matrix state. Has the side effect of
-     * setting the current matrix state to GL_MODELVIEW
-     * @param gl
-     */
-    public void getCurrentModelView(GL10 gl) {
-        getMatrix(gl, GL10.GL_MODELVIEW, mModelView);
-    }
-
-    /**
-     * Record the current projection matrix state. Has the side effect of
-     * setting the current matrix state to GL_PROJECTION
-     * @param gl
-     */
-    public void getCurrentProjection(GL10 gl) {
-        getMatrix(gl, GL10.GL_PROJECTION, mProjection);
-    }
-
-    private void getMatrix(GL10 gl, int mode, float[] mat) {
-        MatrixTrackingGL gl2 = (MatrixTrackingGL) gl;
-        gl2.glMatrixMode(mode);
-        gl2.getMatrix(mat, 0);
-    }
-
-    public float[] mModelView;
-    public float[] mProjection;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixStack.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixStack.java
deleted file mode 100644
index a07f614..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixStack.java
+++ /dev/null
@@ -1,179 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import android.opengl.Matrix;
-
-import java.nio.FloatBuffer;
-import java.nio.IntBuffer;
-
-/**
- * A matrix stack, similar to OpenGL ES's internal matrix stack.
- */
-public class MatrixStack {
-    public MatrixStack() {
-        commonInit(DEFAULT_MAX_DEPTH);
-    }
-
-    public MatrixStack(int maxDepth) {
-        commonInit(maxDepth);
-    }
-
-    private void commonInit(int maxDepth) {
-        mMatrix = new float[maxDepth * MATRIX_SIZE];
-        mTemp = new float[MATRIX_SIZE * 2];
-        glLoadIdentity();
-    }
-
-    public void glFrustumf(float left, float right, float bottom, float top,
-            float near, float far) {
-        Matrix.frustumM(mMatrix, mTop, left, right, bottom, top, near, far);
-    }
-
-    public void glFrustumx(int left, int right, int bottom, int top, int near,
-            int far) {
-        glFrustumf(fixedToFloat(left),fixedToFloat(right),
-                fixedToFloat(bottom), fixedToFloat(top),
-                fixedToFloat(near), fixedToFloat(far));
-    }
-
-    public void glLoadIdentity() {
-        Matrix.setIdentityM(mMatrix, mTop);
-    }
-
-    public void glLoadMatrixf(float[] m, int offset) {
-        System.arraycopy(m, offset, mMatrix, mTop, MATRIX_SIZE);
-    }
-
-    public void glLoadMatrixf(FloatBuffer m) {
-        m.get(mMatrix, mTop, MATRIX_SIZE);
-    }
-
-    public void glLoadMatrixx(int[] m, int offset) {
-        for(int i = 0; i < MATRIX_SIZE; i++) {
-            mMatrix[mTop + i] = fixedToFloat(m[offset + i]);
-        }
-    }
-
-    public void glLoadMatrixx(IntBuffer m) {
-        for(int i = 0; i < MATRIX_SIZE; i++) {
-            mMatrix[mTop + i] = fixedToFloat(m.get());
-        }
-    }
-
-    public void glMultMatrixf(float[] m, int offset) {
-        System.arraycopy(mMatrix, mTop, mTemp, 0, MATRIX_SIZE);
-        Matrix.multiplyMM(mMatrix, mTop, mTemp, 0, m, offset);
-    }
-
-    public void glMultMatrixf(FloatBuffer m) {
-        m.get(mTemp, MATRIX_SIZE, MATRIX_SIZE);
-        glMultMatrixf(mTemp, MATRIX_SIZE);
-    }
-
-    public void glMultMatrixx(int[] m, int offset) {
-        for(int i = 0; i < MATRIX_SIZE; i++) {
-            mTemp[MATRIX_SIZE + i] = fixedToFloat(m[offset + i]);
-        }
-        glMultMatrixf(mTemp, MATRIX_SIZE);
-    }
-
-    public void glMultMatrixx(IntBuffer m) {
-        for(int i = 0; i < MATRIX_SIZE; i++) {
-            mTemp[MATRIX_SIZE + i] = fixedToFloat(m.get());
-        }
-        glMultMatrixf(mTemp, MATRIX_SIZE);
-    }
-
-    public void glOrthof(float left, float right, float bottom, float top,
-            float near, float far) {
-        Matrix.orthoM(mMatrix, mTop, left, right, bottom, top, near, far);
-    }
-
-    public void glOrthox(int left, int right, int bottom, int top, int near,
-            int far) {
-        glOrthof(fixedToFloat(left), fixedToFloat(right),
-                fixedToFloat(bottom), fixedToFloat(top),
-                fixedToFloat(near), fixedToFloat(far));
-    }
-
-    public void glPopMatrix() {
-        preflight_adjust(-1);
-        adjust(-1);
-    }
-
-    public void glPushMatrix() {
-        preflight_adjust(1);
-        System.arraycopy(mMatrix, mTop, mMatrix, mTop + MATRIX_SIZE,
-                MATRIX_SIZE);
-        adjust(1);
-    }
-
-    public void glRotatef(float angle, float x, float y, float z) {
-        Matrix.setRotateM(mTemp, 0, angle, x, y, z);
-        System.arraycopy(mMatrix, mTop, mTemp, MATRIX_SIZE, MATRIX_SIZE);
-        Matrix.multiplyMM(mMatrix, mTop, mTemp, MATRIX_SIZE, mTemp, 0);
-    }
-
-    public void glRotatex(int angle, int x, int y, int z) {
-        glRotatef(angle, fixedToFloat(x), fixedToFloat(y), fixedToFloat(z));
-    }
-
-    public void glScalef(float x, float y, float z) {
-        Matrix.scaleM(mMatrix, mTop, x, y, z);
-    }
-
-    public void glScalex(int x, int y, int z) {
-        glScalef(fixedToFloat(x), fixedToFloat(y), fixedToFloat(z));
-    }
-
-    public void glTranslatef(float x, float y, float z) {
-        Matrix.translateM(mMatrix, mTop, x, y, z);
-    }
-
-    public void glTranslatex(int x, int y, int z) {
-        glTranslatef(fixedToFloat(x), fixedToFloat(y), fixedToFloat(z));
-    }
-
-    public void getMatrix(float[] dest, int offset) {
-        System.arraycopy(mMatrix, mTop, dest, offset, MATRIX_SIZE);
-    }
-
-    private float fixedToFloat(int x) {
-        return x * (1.0f / 65536.0f);
-    }
-
-    private void preflight_adjust(int dir) {
-        int newTop = mTop + dir * MATRIX_SIZE;
-        if (newTop < 0) {
-            throw new IllegalArgumentException("stack underflow");
-        }
-        if (newTop + MATRIX_SIZE > mMatrix.length) {
-            throw new IllegalArgumentException("stack overflow");
-        }
-    }
-
-    private void adjust(int dir) {
-        mTop += dir * MATRIX_SIZE;
-    }
-
-    private final static int DEFAULT_MAX_DEPTH = 32;
-    private final static int MATRIX_SIZE = 16;
-    private float[] mMatrix;
-    private int mTop;
-    private float[] mTemp;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixTrackingGL.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixTrackingGL.java
deleted file mode 100644
index a02761d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/MatrixTrackingGL.java
+++ /dev/null
@@ -1,1086 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import android.util.Log;
-
-import java.nio.Buffer;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.FloatBuffer;
-import java.nio.IntBuffer;
-import java.nio.ShortBuffer;
-
-import javax.microedition.khronos.opengles.GL;
-import javax.microedition.khronos.opengles.GL10;
-import javax.microedition.khronos.opengles.GL10Ext;
-import javax.microedition.khronos.opengles.GL11;
-import javax.microedition.khronos.opengles.GL11Ext;
-
-/**
- * Allows retrieving the current matrix even if the current OpenGL ES
- * driver does not support retrieving the current matrix.
- *
- * Note: the actual matrix may differ from the retrieved matrix, due
- * to differences in the way the math is implemented by GLMatrixWrapper
- * as compared to the way the math is implemented by the OpenGL ES
- * driver.
- */
-class MatrixTrackingGL implements GL, GL10, GL10Ext, GL11, GL11Ext {
-    private GL10 mgl;
-    private GL10Ext mgl10Ext;
-    private GL11 mgl11;
-    private GL11Ext mgl11Ext;
-    private int mMatrixMode;
-    private MatrixStack mCurrent;
-    private MatrixStack mModelView;
-    private MatrixStack mTexture;
-    private MatrixStack mProjection;
-
-    private final static boolean _check = false;
-    ByteBuffer mByteBuffer;
-    FloatBuffer mFloatBuffer;
-    float[] mCheckA;
-    float[] mCheckB;
-
-    public MatrixTrackingGL(GL gl) {
-        mgl = (GL10) gl;
-        if (gl instanceof GL10Ext) {
-            mgl10Ext = (GL10Ext) gl;
-        }
-        if (gl instanceof GL11) {
-            mgl11 = (GL11) gl;
-        }
-        if (gl instanceof GL11Ext) {
-            mgl11Ext = (GL11Ext) gl;
-        }
-        mModelView = new MatrixStack();
-        mProjection = new MatrixStack();
-        mTexture = new MatrixStack();
-        mCurrent = mModelView;
-        mMatrixMode = GL10.GL_MODELVIEW;
-    }
-
-    // ---------------------------------------------------------------------
-    // GL10 methods:
-
-    public void glActiveTexture(int texture) {
-        mgl.glActiveTexture(texture);
-    }
-
-    public void glAlphaFunc(int func, float ref) {
-        mgl.glAlphaFunc(func, ref);
-    }
-
-    public void glAlphaFuncx(int func, int ref) {
-        mgl.glAlphaFuncx(func, ref);
-    }
-
-    public void glBindTexture(int target, int texture) {
-        mgl.glBindTexture(target, texture);
-    }
-
-    public void glBlendFunc(int sfactor, int dfactor) {
-        mgl.glBlendFunc(sfactor, dfactor);
-    }
-
-    public void glClear(int mask) {
-        mgl.glClear(mask);
-    }
-
-    public void glClearColor(float red, float green, float blue, float alpha) {
-        mgl.glClearColor(red, green, blue, alpha);
-    }
-
-    public void glClearColorx(int red, int green, int blue, int alpha) {
-        mgl.glClearColorx(red, green, blue, alpha);
-    }
-
-    public void glClearDepthf(float depth) {
-        mgl.glClearDepthf(depth);
-    }
-
-    public void glClearDepthx(int depth) {
-        mgl.glClearDepthx(depth);
-    }
-
-    public void glClearStencil(int s) {
-        mgl.glClearStencil(s);
-    }
-
-    public void glClientActiveTexture(int texture) {
-        mgl.glClientActiveTexture(texture);
-    }
-
-    public void glColor4f(float red, float green, float blue, float alpha) {
-        mgl.glColor4f(red, green, blue, alpha);
-    }
-
-    public void glColor4x(int red, int green, int blue, int alpha) {
-        mgl.glColor4x(red, green, blue, alpha);
-    }
-
-    public void glColorMask(boolean red, boolean green, boolean blue,
-            boolean alpha) {
-        mgl.glColorMask(red, green, blue, alpha);
-    }
-
-    public void glColorPointer(int size, int type, int stride, Buffer pointer) {
-        mgl.glColorPointer(size, type, stride, pointer);
-    }
-
-    public void glCompressedTexImage2D(int target, int level,
-            int internalformat, int width, int height, int border,
-            int imageSize, Buffer data) {
-        mgl.glCompressedTexImage2D(target, level, internalformat, width,
-                height, border, imageSize, data);
-    }
-
-    public void glCompressedTexSubImage2D(int target, int level, int xoffset,
-            int yoffset, int width, int height, int format, int imageSize,
-            Buffer data) {
-        mgl.glCompressedTexSubImage2D(target, level, xoffset, yoffset, width,
-                height, format, imageSize, data);
-    }
-
-    public void glCopyTexImage2D(int target, int level, int internalformat,
-            int x, int y, int width, int height, int border) {
-        mgl.glCopyTexImage2D(target, level, internalformat, x, y, width,
-                height, border);
-    }
-
-    public void glCopyTexSubImage2D(int target, int level, int xoffset,
-            int yoffset, int x, int y, int width, int height) {
-        mgl.glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width,
-                height);
-    }
-
-    public void glCullFace(int mode) {
-        mgl.glCullFace(mode);
-    }
-
-    public void glDeleteTextures(int n, int[] textures, int offset) {
-        mgl.glDeleteTextures(n, textures, offset);
-    }
-
-    public void glDeleteTextures(int n, IntBuffer textures) {
-        mgl.glDeleteTextures(n, textures);
-    }
-
-    public void glDepthFunc(int func) {
-        mgl.glDepthFunc(func);
-    }
-
-    public void glDepthMask(boolean flag) {
-        mgl.glDepthMask(flag);
-    }
-
-    public void glDepthRangef(float near, float far) {
-        mgl.glDepthRangef(near, far);
-    }
-
-    public void glDepthRangex(int near, int far) {
-        mgl.glDepthRangex(near, far);
-    }
-
-    public void glDisable(int cap) {
-        mgl.glDisable(cap);
-    }
-
-    public void glDisableClientState(int array) {
-        mgl.glDisableClientState(array);
-    }
-
-    public void glDrawArrays(int mode, int first, int count) {
-        mgl.glDrawArrays(mode, first, count);
-    }
-
-    public void glDrawElements(int mode, int count, int type, Buffer indices) {
-        mgl.glDrawElements(mode, count, type, indices);
-    }
-
-    public void glEnable(int cap) {
-        mgl.glEnable(cap);
-    }
-
-    public void glEnableClientState(int array) {
-        mgl.glEnableClientState(array);
-    }
-
-    public void glFinish() {
-        mgl.glFinish();
-    }
-
-    public void glFlush() {
-        mgl.glFlush();
-    }
-
-    public void glFogf(int pname, float param) {
-        mgl.glFogf(pname, param);
-    }
-
-    public void glFogfv(int pname, float[] params, int offset) {
-        mgl.glFogfv(pname, params, offset);
-    }
-
-    public void glFogfv(int pname, FloatBuffer params) {
-        mgl.glFogfv(pname, params);
-    }
-
-    public void glFogx(int pname, int param) {
-        mgl.glFogx(pname, param);
-    }
-
-    public void glFogxv(int pname, int[] params, int offset) {
-        mgl.glFogxv(pname, params, offset);
-    }
-
-    public void glFogxv(int pname, IntBuffer params) {
-        mgl.glFogxv(pname, params);
-    }
-
-    public void glFrontFace(int mode) {
-        mgl.glFrontFace(mode);
-    }
-
-    public void glFrustumf(float left, float right, float bottom, float top,
-            float near, float far) {
-        mCurrent.glFrustumf(left, right, bottom, top, near, far);
-        mgl.glFrustumf(left, right, bottom, top, near, far);
-        if ( _check) check();
-    }
-
-    public void glFrustumx(int left, int right, int bottom, int top, int near,
-            int far) {
-        mCurrent.glFrustumx(left, right, bottom, top, near, far);
-        mgl.glFrustumx(left, right, bottom, top, near, far);
-        if ( _check) check();
-    }
-
-    public void glGenTextures(int n, int[] textures, int offset) {
-        mgl.glGenTextures(n, textures, offset);
-    }
-
-    public void glGenTextures(int n, IntBuffer textures) {
-        mgl.glGenTextures(n, textures);
-    }
-
-    public int glGetError() {
-        int result = mgl.glGetError();
-        return result;
-    }
-
-    public void glGetIntegerv(int pname, int[] params, int offset) {
-        mgl.glGetIntegerv(pname, params, offset);
-    }
-
-    public void glGetIntegerv(int pname, IntBuffer params) {
-        mgl.glGetIntegerv(pname, params);
-    }
-
-    public String glGetString(int name) {
-        String result = mgl.glGetString(name);
-        return result;
-    }
-
-    public void glHint(int target, int mode) {
-        mgl.glHint(target, mode);
-    }
-
-    public void glLightModelf(int pname, float param) {
-        mgl.glLightModelf(pname, param);
-    }
-
-    public void glLightModelfv(int pname, float[] params, int offset) {
-        mgl.glLightModelfv(pname, params, offset);
-    }
-
-    public void glLightModelfv(int pname, FloatBuffer params) {
-        mgl.glLightModelfv(pname, params);
-    }
-
-    public void glLightModelx(int pname, int param) {
-        mgl.glLightModelx(pname, param);
-    }
-
-    public void glLightModelxv(int pname, int[] params, int offset) {
-        mgl.glLightModelxv(pname, params, offset);
-    }
-
-    public void glLightModelxv(int pname, IntBuffer params) {
-        mgl.glLightModelxv(pname, params);
-    }
-
-    public void glLightf(int light, int pname, float param) {
-        mgl.glLightf(light, pname, param);
-    }
-
-    public void glLightfv(int light, int pname, float[] params, int offset) {
-        mgl.glLightfv(light, pname, params, offset);
-    }
-
-    public void glLightfv(int light, int pname, FloatBuffer params) {
-        mgl.glLightfv(light, pname, params);
-    }
-
-    public void glLightx(int light, int pname, int param) {
-        mgl.glLightx(light, pname, param);
-    }
-
-    public void glLightxv(int light, int pname, int[] params, int offset) {
-        mgl.glLightxv(light, pname, params, offset);
-    }
-
-    public void glLightxv(int light, int pname, IntBuffer params) {
-        mgl.glLightxv(light, pname, params);
-    }
-
-    public void glLineWidth(float width) {
-        mgl.glLineWidth(width);
-    }
-
-    public void glLineWidthx(int width) {
-        mgl.glLineWidthx(width);
-    }
-
-    public void glLoadIdentity() {
-        mCurrent.glLoadIdentity();
-        mgl.glLoadIdentity();
-        if ( _check) check();
-    }
-
-    public void glLoadMatrixf(float[] m, int offset) {
-        mCurrent.glLoadMatrixf(m, offset);
-        mgl.glLoadMatrixf(m, offset);
-        if ( _check) check();
-    }
-
-    public void glLoadMatrixf(FloatBuffer m) {
-        int position = m.position();
-        mCurrent.glLoadMatrixf(m);
-        m.position(position);
-        mgl.glLoadMatrixf(m);
-        if ( _check) check();
-    }
-
-    public void glLoadMatrixx(int[] m, int offset) {
-        mCurrent.glLoadMatrixx(m, offset);
-        mgl.glLoadMatrixx(m, offset);
-        if ( _check) check();
-    }
-
-    public void glLoadMatrixx(IntBuffer m) {
-        int position = m.position();
-        mCurrent.glLoadMatrixx(m);
-        m.position(position);
-        mgl.glLoadMatrixx(m);
-        if ( _check) check();
-    }
-
-    public void glLogicOp(int opcode) {
-        mgl.glLogicOp(opcode);
-    }
-
-    public void glMaterialf(int face, int pname, float param) {
-        mgl.glMaterialf(face, pname, param);
-    }
-
-    public void glMaterialfv(int face, int pname, float[] params, int offset) {
-        mgl.glMaterialfv(face, pname, params, offset);
-    }
-
-    public void glMaterialfv(int face, int pname, FloatBuffer params) {
-        mgl.glMaterialfv(face, pname, params);
-    }
-
-    public void glMaterialx(int face, int pname, int param) {
-        mgl.glMaterialx(face, pname, param);
-    }
-
-    public void glMaterialxv(int face, int pname, int[] params, int offset) {
-        mgl.glMaterialxv(face, pname, params, offset);
-    }
-
-    public void glMaterialxv(int face, int pname, IntBuffer params) {
-        mgl.glMaterialxv(face, pname, params);
-    }
-
-    public void glMatrixMode(int mode) {
-        switch (mode) {
-        case GL10.GL_MODELVIEW:
-            mCurrent = mModelView;
-            break;
-        case GL10.GL_TEXTURE:
-            mCurrent = mTexture;
-            break;
-        case GL10.GL_PROJECTION:
-            mCurrent = mProjection;
-            break;
-        default:
-            throw new IllegalArgumentException("Unknown matrix mode: " + mode);
-        }
-        mgl.glMatrixMode(mode);
-        mMatrixMode = mode;
-        if ( _check) check();
-    }
-
-    public void glMultMatrixf(float[] m, int offset) {
-        mCurrent.glMultMatrixf(m, offset);
-        mgl.glMultMatrixf(m, offset);
-        if ( _check) check();
-    }
-
-    public void glMultMatrixf(FloatBuffer m) {
-        int position = m.position();
-        mCurrent.glMultMatrixf(m);
-        m.position(position);
-        mgl.glMultMatrixf(m);
-        if ( _check) check();
-    }
-
-    public void glMultMatrixx(int[] m, int offset) {
-        mCurrent.glMultMatrixx(m, offset);
-        mgl.glMultMatrixx(m, offset);
-        if ( _check) check();
-    }
-
-    public void glMultMatrixx(IntBuffer m) {
-        int position = m.position();
-        mCurrent.glMultMatrixx(m);
-        m.position(position);
-        mgl.glMultMatrixx(m);
-        if ( _check) check();
-    }
-
-    public void glMultiTexCoord4f(int target,
-            float s, float t, float r, float q) {
-        mgl.glMultiTexCoord4f(target, s, t, r, q);
-    }
-
-    public void glMultiTexCoord4x(int target, int s, int t, int r, int q) {
-        mgl.glMultiTexCoord4x(target, s, t, r, q);
-    }
-
-    public void glNormal3f(float nx, float ny, float nz) {
-        mgl.glNormal3f(nx, ny, nz);
-    }
-
-    public void glNormal3x(int nx, int ny, int nz) {
-        mgl.glNormal3x(nx, ny, nz);
-    }
-
-    public void glNormalPointer(int type, int stride, Buffer pointer) {
-        mgl.glNormalPointer(type, stride, pointer);
-    }
-
-    public void glOrthof(float left, float right, float bottom, float top,
-            float near, float far) {
-        mCurrent.glOrthof(left, right, bottom, top, near, far);
-        mgl.glOrthof(left, right, bottom, top, near, far);
-        if ( _check) check();
-    }
-
-    public void glOrthox(int left, int right, int bottom, int top, int near,
-            int far) {
-        mCurrent.glOrthox(left, right, bottom, top, near, far);
-        mgl.glOrthox(left, right, bottom, top, near, far);
-        if ( _check) check();
-    }
-
-    public void glPixelStorei(int pname, int param) {
-        mgl.glPixelStorei(pname, param);
-    }
-
-    public void glPointSize(float size) {
-        mgl.glPointSize(size);
-    }
-
-    public void glPointSizex(int size) {
-        mgl.glPointSizex(size);
-    }
-
-    public void glPolygonOffset(float factor, float units) {
-        mgl.glPolygonOffset(factor, units);
-    }
-
-    public void glPolygonOffsetx(int factor, int units) {
-        mgl.glPolygonOffsetx(factor, units);
-    }
-
-    public void glPopMatrix() {
-        mCurrent.glPopMatrix();
-        mgl.glPopMatrix();
-        if ( _check) check();
-    }
-
-    public void glPushMatrix() {
-        mCurrent.glPushMatrix();
-        mgl.glPushMatrix();
-        if ( _check) check();
-    }
-
-    public void glReadPixels(int x, int y, int width, int height, int format,
-            int type, Buffer pixels) {
-        mgl.glReadPixels(x, y, width, height, format, type, pixels);
-    }
-
-    public void glRotatef(float angle, float x, float y, float z) {
-        mCurrent.glRotatef(angle, x, y, z);
-        mgl.glRotatef(angle, x, y, z);
-        if ( _check) check();
-    }
-
-    public void glRotatex(int angle, int x, int y, int z) {
-        mCurrent.glRotatex(angle, x, y, z);
-        mgl.glRotatex(angle, x, y, z);
-        if ( _check) check();
-    }
-
-    public void glSampleCoverage(float value, boolean invert) {
-        mgl.glSampleCoverage(value, invert);
-    }
-
-    public void glSampleCoveragex(int value, boolean invert) {
-        mgl.glSampleCoveragex(value, invert);
-    }
-
-    public void glScalef(float x, float y, float z) {
-        mCurrent.glScalef(x, y, z);
-        mgl.glScalef(x, y, z);
-        if ( _check) check();
-    }
-
-    public void glScalex(int x, int y, int z) {
-        mCurrent.glScalex(x, y, z);
-        mgl.glScalex(x, y, z);
-        if ( _check) check();
-    }
-
-    public void glScissor(int x, int y, int width, int height) {
-        mgl.glScissor(x, y, width, height);
-    }
-
-    public void glShadeModel(int mode) {
-        mgl.glShadeModel(mode);
-    }
-
-    public void glStencilFunc(int func, int ref, int mask) {
-        mgl.glStencilFunc(func, ref, mask);
-    }
-
-    public void glStencilMask(int mask) {
-        mgl.glStencilMask(mask);
-    }
-
-    public void glStencilOp(int fail, int zfail, int zpass) {
-        mgl.glStencilOp(fail, zfail, zpass);
-    }
-
-    public void glTexCoordPointer(int size, int type,
-            int stride, Buffer pointer) {
-        mgl.glTexCoordPointer(size, type, stride, pointer);
-    }
-
-    public void glTexEnvf(int target, int pname, float param) {
-        mgl.glTexEnvf(target, pname, param);
-    }
-
-    public void glTexEnvfv(int target, int pname, float[] params, int offset) {
-        mgl.glTexEnvfv(target, pname, params, offset);
-    }
-
-    public void glTexEnvfv(int target, int pname, FloatBuffer params) {
-        mgl.glTexEnvfv(target, pname, params);
-    }
-
-    public void glTexEnvx(int target, int pname, int param) {
-        mgl.glTexEnvx(target, pname, param);
-    }
-
-    public void glTexEnvxv(int target, int pname, int[] params, int offset) {
-        mgl.glTexEnvxv(target, pname, params, offset);
-    }
-
-    public void glTexEnvxv(int target, int pname, IntBuffer params) {
-        mgl.glTexEnvxv(target, pname, params);
-    }
-
-    public void glTexImage2D(int target, int level, int internalformat,
-            int width, int height, int border, int format, int type,
-            Buffer pixels) {
-        mgl.glTexImage2D(target, level, internalformat, width, height, border,
-                format, type, pixels);
-    }
-
-    public void glTexParameterf(int target, int pname, float param) {
-        mgl.glTexParameterf(target, pname, param);
-    }
-
-    public void glTexParameterx(int target, int pname, int param) {
-        mgl.glTexParameterx(target, pname, param);
-    }
-
-    public void glTexParameteriv(int target, int pname, int[] params, int offset) {
-        mgl11.glTexParameteriv(target, pname, params, offset);
-    }
-
-    public void glTexParameteriv(int target, int pname, IntBuffer params) {
-        mgl11.glTexParameteriv(target, pname, params);
-    }
-
-    public void glTexSubImage2D(int target, int level, int xoffset,
-            int yoffset, int width, int height, int format, int type,
-            Buffer pixels) {
-        mgl.glTexSubImage2D(target, level, xoffset, yoffset, width, height,
-                format, type, pixels);
-    }
-
-    public void glTranslatef(float x, float y, float z) {
-        mCurrent.glTranslatef(x, y, z);
-        mgl.glTranslatef(x, y, z);
-        if ( _check) check();
-    }
-
-    public void glTranslatex(int x, int y, int z) {
-        mCurrent.glTranslatex(x, y, z);
-        mgl.glTranslatex(x, y, z);
-        if ( _check) check();
-    }
-
-    public void glVertexPointer(int size, int type,
-            int stride, Buffer pointer) {
-        mgl.glVertexPointer(size, type, stride, pointer);
-    }
-
-    public void glViewport(int x, int y, int width, int height) {
-        mgl.glViewport(x, y, width, height);
-    }
-
-    public void glClipPlanef(int plane, float[] equation, int offset) {
-        mgl11.glClipPlanef(plane, equation, offset);
-    }
-
-    public void glClipPlanef(int plane, FloatBuffer equation) {
-        mgl11.glClipPlanef(plane, equation);
-    }
-
-    public void glClipPlanex(int plane, int[] equation, int offset) {
-        mgl11.glClipPlanex(plane, equation, offset);
-    }
-
-    public void glClipPlanex(int plane, IntBuffer equation) {
-        mgl11.glClipPlanex(plane, equation);
-    }
-
-    // Draw Texture Extension
-
-    public void glDrawTexfOES(float x, float y, float z,
-        float width, float height) {
-        mgl11Ext.glDrawTexfOES(x, y, z, width, height);
-    }
-
-    public void glDrawTexfvOES(float[] coords, int offset) {
-        mgl11Ext.glDrawTexfvOES(coords, offset);
-    }
-
-    public void glDrawTexfvOES(FloatBuffer coords) {
-        mgl11Ext.glDrawTexfvOES(coords);
-    }
-
-    public void glDrawTexiOES(int x, int y, int z, int width, int height) {
-        mgl11Ext.glDrawTexiOES(x, y, z, width, height);
-    }
-
-    public void glDrawTexivOES(int[] coords, int offset) {
-        mgl11Ext.glDrawTexivOES(coords, offset);
-    }
-
-    public void glDrawTexivOES(IntBuffer coords) {
-        mgl11Ext.glDrawTexivOES(coords);
-    }
-
-    public void glDrawTexsOES(short x, short y, short z,
-        short width, short height) {
-        mgl11Ext.glDrawTexsOES(x, y, z, width, height);
-    }
-
-    public void glDrawTexsvOES(short[] coords, int offset) {
-        mgl11Ext.glDrawTexsvOES(coords, offset);
-    }
-
-    public void glDrawTexsvOES(ShortBuffer coords) {
-        mgl11Ext.glDrawTexsvOES(coords);
-    }
-
-    public void glDrawTexxOES(int x, int y, int z, int width, int height) {
-        mgl11Ext.glDrawTexxOES(x, y, z, width, height);
-    }
-
-    public void glDrawTexxvOES(int[] coords, int offset) {
-        mgl11Ext.glDrawTexxvOES(coords, offset);
-    }
-
-    public void glDrawTexxvOES(IntBuffer coords) {
-        mgl11Ext.glDrawTexxvOES(coords);
-    }
-
-    public int glQueryMatrixxOES(int[] mantissa, int mantissaOffset,
-        int[] exponent, int exponentOffset) {
-        return mgl10Ext.glQueryMatrixxOES(mantissa, mantissaOffset,
-            exponent, exponentOffset);
-    }
-
-    public int glQueryMatrixxOES(IntBuffer mantissa, IntBuffer exponent) {
-        return mgl10Ext.glQueryMatrixxOES(mantissa, exponent);
-    }
-
-    // Unsupported GL11 methods
-
-    public void glBindBuffer(int target, int buffer) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glBufferData(int target, int size, Buffer data, int usage) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glBufferSubData(int target, int offset, int size, Buffer data) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glColor4ub(byte red, byte green, byte blue, byte alpha) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glDeleteBuffers(int n, int[] buffers, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glDeleteBuffers(int n, IntBuffer buffers) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGenBuffers(int n, int[] buffers, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGenBuffers(int n, IntBuffer buffers) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetBooleanv(int pname, boolean[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetBooleanv(int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetBufferParameteriv(int target, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetBufferParameteriv(int target, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetClipPlanef(int pname, float[] eqn, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetClipPlanef(int pname, FloatBuffer eqn) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetClipPlanex(int pname, int[] eqn, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetClipPlanex(int pname, IntBuffer eqn) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetFixedv(int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetFixedv(int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetFloatv(int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetFloatv(int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetLightfv(int light, int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetLightfv(int light, int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetLightxv(int light, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetLightxv(int light, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetMaterialfv(int face, int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetMaterialfv(int face, int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetMaterialxv(int face, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetMaterialxv(int face, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexEnviv(int env, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexEnviv(int env, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexEnvxv(int env, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexEnvxv(int env, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameterfv(int target, int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameterfv(int target, int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameteriv(int target, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameteriv(int target, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameterxv(int target, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetTexParameterxv(int target, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public boolean glIsBuffer(int buffer) {
-        throw new UnsupportedOperationException();
-    }
-
-    public boolean glIsEnabled(int cap) {
-        throw new UnsupportedOperationException();
-    }
-
-    public boolean glIsTexture(int texture) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterf(int pname, float param) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterfv(int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterfv(int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterx(int pname, int param) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterxv(int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointParameterxv(int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glPointSizePointerOES(int type, int stride, Buffer pointer) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexEnvi(int target, int pname, int param) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexEnviv(int target, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexEnviv(int target, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexParameterfv(int target, int pname, float[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexParameterfv(int target, int pname, FloatBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexParameteri(int target, int pname, int param) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexParameterxv(int target, int pname, int[] params, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexParameterxv(int target, int pname, IntBuffer params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glColorPointer(int size, int type, int stride, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glDrawElements(int mode, int count, int type, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glGetPointerv(int pname, Buffer[] params) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glNormalPointer(int type, int stride, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glTexCoordPointer(int size, int type, int stride, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glVertexPointer(int size, int type, int stride, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glCurrentPaletteMatrixOES(int matrixpaletteindex) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glLoadPaletteFromModelViewMatrixOES() {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glMatrixIndexPointerOES(int size, int type, int stride,
-            Buffer pointer) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glMatrixIndexPointerOES(int size, int type, int stride,
-            int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glWeightPointerOES(int size, int type, int stride,
-            Buffer pointer) {
-        throw new UnsupportedOperationException();
-    }
-
-    public void glWeightPointerOES(int size, int type, int stride, int offset) {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * Get the current matrix
-     */
-
-    public void getMatrix(float[] m, int offset) {
-        mCurrent.getMatrix(m, offset);
-    }
-
-    /**
-     * Get the current matrix mode
-     */
-
-    public int getMatrixMode() {
-        return mMatrixMode;
-    }
-
-    private void check() {
-        int oesMode;
-        switch (mMatrixMode) {
-        case GL_MODELVIEW:
-            oesMode = GL11.GL_MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES;
-            break;
-        case GL_PROJECTION:
-            oesMode = GL11.GL_PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES;
-            break;
-        case GL_TEXTURE:
-            oesMode = GL11.GL_TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES;
-            break;
-        default:
-            throw new IllegalArgumentException("Unknown matrix mode");
-        }
-
-        if ( mByteBuffer == null) {
-            mCheckA = new float[16];
-            mCheckB = new float[16];
-            mByteBuffer = ByteBuffer.allocateDirect(64);
-            mByteBuffer.order(ByteOrder.nativeOrder());
-            mFloatBuffer = mByteBuffer.asFloatBuffer();
-        }
-        mgl.glGetIntegerv(oesMode, mByteBuffer.asIntBuffer());
-        for(int i = 0; i < 16; i++) {
-            mCheckB[i] = mFloatBuffer.get(i);
-        }
-        mCurrent.getMatrix(mCheckA, 0);
-
-        boolean fail = false;
-        for(int i = 0; i < 16; i++) {
-            if (mCheckA[i] != mCheckB[i]) {
-                Log.d("GLMatWrap", "i:" + i + " a:" + mCheckA[i]
-                + " a:" + mCheckB[i]);
-                fail = true;
-            }
-        }
-        if (fail) {
-            throw new IllegalArgumentException("Matrix math difference.");
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/NumericSprite.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/NumericSprite.java
deleted file mode 100644
index e70dfda..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/NumericSprite.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import javax.microedition.khronos.opengles.GL10;
-
-import android.graphics.Paint;
-
-public class NumericSprite {
-    public NumericSprite() {
-        mText = "";
-        mLabelMaker = null;
-    }
-
-    public void initialize(GL10 gl, Paint paint) {
-        int height = roundUpPower2((int) paint.getFontSpacing());
-        final float interDigitGaps = 9 * 1.0f;
-        int width = roundUpPower2((int) (interDigitGaps + paint.measureText(sStrike)));
-        mLabelMaker = new LabelMaker(true, width, height);
-        mLabelMaker.initialize(gl);
-        mLabelMaker.beginAdding(gl);
-        for (int i = 0; i < 10; i++) {
-            String digit = sStrike.substring(i, i+1);
-            mLabelId[i] = mLabelMaker.add(gl, digit, paint);
-            mWidth[i] = (int) Math.ceil(mLabelMaker.getWidth(i));
-        }
-        mLabelMaker.endAdding(gl);
-    }
-
-    public void shutdown(GL10 gl) {
-        mLabelMaker.shutdown(gl);
-        mLabelMaker = null;
-    }
-
-    /**
-     * Find the smallest power of two >= the input value.
-     * (Doesn't work for negative numbers.)
-     */
-    private int roundUpPower2(int x) {
-        x = x - 1;
-        x = x | (x >> 1);
-        x = x | (x >> 2);
-        x = x | (x >> 4);
-        x = x | (x >> 8);
-        x = x | (x >>16);
-        return x + 1;
-    }
-
-    public void setValue(int value) {
-        mText = format(value);
-    }
-
-    public void draw(GL10 gl, float x, float y,
-            float viewWidth, float viewHeight) {
-        int length = mText.length();
-        mLabelMaker.beginDrawing(gl, viewWidth, viewHeight);
-        for(int i = 0; i < length; i++) {
-            char c = mText.charAt(i);
-            int digit = c - '0';
-            mLabelMaker.draw(gl, x, y, mLabelId[digit]);
-            x += mWidth[digit];
-        }
-        mLabelMaker.endDrawing(gl);
-    }
-
-    public float width() {
-        float width = 0.0f;
-        int length = mText.length();
-        for(int i = 0; i < length; i++) {
-            char c = mText.charAt(i);
-            width += mWidth[c - '0'];
-        }
-        return width;
-    }
-
-    private String format(int value) {
-        return Integer.toString(value);
-    }
-
-    private LabelMaker mLabelMaker;
-    private String mText;
-    private int[] mWidth = new int[10];
-    private int[] mLabelId = new int[10];
-    private final static String sStrike = "0123456789";
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Projector.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Projector.java
deleted file mode 100644
index b52fa3e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/Projector.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import android.opengl.Matrix;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * A utility that projects
- *
- */
-class Projector {
-    public Projector() {
-        mMVP = new float[16];
-        mV = new float[4];
-        mGrabber = new MatrixGrabber();
-    }
-
-    public void setCurrentView(int x, int y, int width, int height) {
-        mX = x;
-        mY = y;
-        mViewWidth = width;
-        mViewHeight = height;
-    }
-
-    public void project(float[] obj, int objOffset, float[] win, int winOffset) {
-        if (!mMVPComputed) {
-            Matrix.multiplyMM(mMVP, 0, mGrabber.mProjection, 0, mGrabber.mModelView, 0);
-            mMVPComputed = true;
-        }
-
-        Matrix.multiplyMV(mV, 0, mMVP, 0, obj, objOffset);
-
-        float rw = 1.0f / mV[3];
-
-        win[winOffset] = mX + mViewWidth * (mV[0] * rw + 1.0f) * 0.5f;
-        win[winOffset + 1] = mY + mViewHeight * (mV[1] * rw + 1.0f) * 0.5f;
-        win[winOffset + 2] = (mV[2] * rw + 1.0f) * 0.5f;
-    }
-
-    /**
-     * Get the current projection matrix. Has the side-effect of
-     * setting current matrix mode to GL_PROJECTION
-     * @param gl
-     */
-    public void getCurrentProjection(GL10 gl) {
-        mGrabber.getCurrentProjection(gl);
-        mMVPComputed = false;
-    }
-
-    /**
-     * Get the current model view matrix. Has the side-effect of
-     * setting current matrix mode to GL_MODELVIEW
-     * @param gl
-     */
-    public void getCurrentModelView(GL10 gl) {
-        mGrabber.getCurrentModelView(gl);
-        mMVPComputed = false;
-    }
-
-    private MatrixGrabber mGrabber;
-    private boolean mMVPComputed;
-    private float[] mMVP;
-    private float[] mV;
-    private int mX;
-    private int mY;
-    private int mViewWidth;
-    private int mViewHeight;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextActivity.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextActivity.java
deleted file mode 100644
index 1e58dae..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextActivity.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import javax.microedition.khronos.opengles.GL;
-
-import android.app.Activity;
-import android.opengl.GLSurfaceView;
-import android.os.Bundle;
-
-public class SpriteTextActivity extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        mGLSurfaceView = new GLSurfaceView(this);
-        mGLSurfaceView.setGLWrapper(new GLSurfaceView.GLWrapper() {
-            public GL wrap(GL gl) {
-                return new MatrixTrackingGL(gl);
-            }});
-        mGLSurfaceView.setRenderer(new SpriteTextRenderer(this));
-        setContentView(mGLSurfaceView);
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-        mGLSurfaceView.onPause();
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mGLSurfaceView.onResume();
-    }
-
-    private GLSurfaceView mGLSurfaceView;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextRenderer.java b/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextRenderer.java
deleted file mode 100644
index b9369cd..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/graphics/spritetext/SpriteTextRenderer.java
+++ /dev/null
@@ -1,354 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.graphics.spritetext;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.FloatBuffer;
-import java.nio.ShortBuffer;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-
-import android.content.Context;
-import android.graphics.Bitmap;
-import android.graphics.BitmapFactory;
-import android.graphics.Paint;
-import android.opengl.GLSurfaceView;
-import android.opengl.GLU;
-import android.opengl.GLUtils;
-import android.os.SystemClock;
-
-import com.example.android.apis.R;
-
-public class SpriteTextRenderer implements GLSurfaceView.Renderer{
-
-    public SpriteTextRenderer(Context context) {
-        mContext = context;
-        mTriangle = new Triangle();
-        mProjector = new Projector();
-        mLabelPaint = new Paint();
-        mLabelPaint.setTextSize(32);
-        mLabelPaint.setAntiAlias(true);
-        mLabelPaint.setARGB(0xff, 0x00, 0x00, 0x00);
-    }
-
-    public int[] getConfigSpec() {
-        // We don't need a depth buffer, and don't care about our
-        // color depth.
-        int[] configSpec = {
-                EGL10.EGL_DEPTH_SIZE, 0,
-                EGL10.EGL_NONE
-        };
-        return configSpec;
-    }
-
-    public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        /*
-         * Some one-time OpenGL initialization can be made here
-         * probably based on features of this particular context
-         */
-        gl.glHint(GL10.GL_PERSPECTIVE_CORRECTION_HINT,
-                GL10.GL_FASTEST);
-
-        gl.glClearColor(.5f, .5f, .5f, 1);
-        gl.glShadeModel(GL10.GL_SMOOTH);
-        gl.glEnable(GL10.GL_DEPTH_TEST);
-        gl.glEnable(GL10.GL_TEXTURE_2D);
-
-        /*
-         * Create our texture. This has to be done each time the
-         * surface is created.
-         */
-
-        int[] textures = new int[1];
-        gl.glGenTextures(1, textures, 0);
-
-        mTextureID = textures[0];
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MIN_FILTER,
-                GL10.GL_NEAREST);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D,
-                GL10.GL_TEXTURE_MAG_FILTER,
-                GL10.GL_LINEAR);
-
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S,
-                GL10.GL_CLAMP_TO_EDGE);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T,
-                GL10.GL_CLAMP_TO_EDGE);
-
-        gl.glTexEnvf(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE,
-                GL10.GL_REPLACE);
-
-        InputStream is = mContext.getResources()
-                .openRawResource(R.drawable.robot);
-        Bitmap bitmap;
-        try {
-            bitmap = BitmapFactory.decodeStream(is);
-        } finally {
-            try {
-                is.close();
-            } catch(IOException e) {
-                // Ignore.
-            }
-        }
-
-        GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0);
-        bitmap.recycle();
-
-        if (mLabels != null) {
-            mLabels.shutdown(gl);
-        } else {
-            mLabels = new LabelMaker(true, 256, 64);
-        }
-        mLabels.initialize(gl);
-        mLabels.beginAdding(gl);
-        mLabelA = mLabels.add(gl, "A", mLabelPaint);
-        mLabelB = mLabels.add(gl, "B", mLabelPaint);
-        mLabelC = mLabels.add(gl, "C", mLabelPaint);
-        mLabelMsPF = mLabels.add(gl, "ms/f", mLabelPaint);
-        mLabels.endAdding(gl);
-
-        if (mNumericSprite != null) {
-            mNumericSprite.shutdown(gl);
-        } else {
-            mNumericSprite = new NumericSprite();
-        }
-        mNumericSprite.initialize(gl, mLabelPaint);
-    }
-
-    public void onDrawFrame(GL10 gl) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        gl.glTexEnvx(GL10.GL_TEXTURE_ENV, GL10.GL_TEXTURE_ENV_MODE,
-                GL10.GL_MODULATE);
-
-        /*
-         * Usually, the first thing one might want to do is to clear
-         * the screen. The most efficient way of doing this is to use
-         * glClear().
-         */
-
-        gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-        /*
-         * Now we're ready to draw some 3D objects
-         */
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-
-        GLU.gluLookAt(gl, 0.0f, 0.0f, -2.5f,
-                0.0f, 0.0f, 0.0f,
-                0.0f, 1.0f, 0.0f);
-
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-        gl.glEnableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-
-        gl.glActiveTexture(GL10.GL_TEXTURE0);
-        gl.glBindTexture(GL10.GL_TEXTURE_2D, mTextureID);
-        gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S,
-                GL10.GL_REPEAT);
-        gl.glTexParameterx(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T,
-                GL10.GL_REPEAT);
-
-        long time = SystemClock.uptimeMillis() % 4000L;
-        float angle = 0.090f * ((int) time);
-
-        gl.glRotatef(angle, 0, 0, 1.0f);
-        gl.glScalef(2.0f, 2.0f, 2.0f);
-
-        mTriangle.draw(gl);
-
-        mProjector.getCurrentModelView(gl);
-        mLabels.beginDrawing(gl, mWidth, mHeight);
-        drawLabel(gl, 0, mLabelA);
-        drawLabel(gl, 1, mLabelB);
-        drawLabel(gl, 2, mLabelC);
-        float msPFX = mWidth - mLabels.getWidth(mLabelMsPF) - 1;
-        mLabels.draw(gl, msPFX, 0, mLabelMsPF);
-        mLabels.endDrawing(gl);
-
-        drawMsPF(gl, msPFX);
-    }
-
-    private void drawMsPF(GL10 gl, float rightMargin) {
-        long time = SystemClock.uptimeMillis();
-        if (mStartTime == 0) {
-            mStartTime = time;
-        }
-        if (mFrames++ == SAMPLE_PERIOD_FRAMES) {
-            mFrames = 0;
-            long delta = time - mStartTime;
-            mStartTime = time;
-            mMsPerFrame = (int) (delta * SAMPLE_FACTOR);
-        }
-        if (mMsPerFrame > 0) {
-            mNumericSprite.setValue(mMsPerFrame);
-            float numWidth = mNumericSprite.width();
-            float x = rightMargin - numWidth;
-            mNumericSprite.draw(gl, x, 0, mWidth, mHeight);
-        }
-    }
-
-    private void drawLabel(GL10 gl, int triangleVertex, int labelId) {
-        float x = mTriangle.getX(triangleVertex);
-        float y = mTriangle.getY(triangleVertex);
-        mScratch[0] = x;
-        mScratch[1] = y;
-        mScratch[2] = 0.0f;
-        mScratch[3] = 1.0f;
-        mProjector.project(mScratch, 0, mScratch, 4);
-        float sx = mScratch[4];
-        float sy = mScratch[5];
-        float height = mLabels.getHeight(labelId);
-        float width = mLabels.getWidth(labelId);
-        float tx = sx - width * 0.5f;
-        float ty = sy - height * 0.5f;
-        mLabels.draw(gl, tx, ty, labelId);
-    }
-
-    public void onSurfaceChanged(GL10 gl, int w, int h) {
-        mWidth = w;
-        mHeight = h;
-        gl.glViewport(0, 0, w, h);
-        mProjector.setCurrentView(0, 0, w, h);
-
-        /*
-        * Set our projection matrix. This doesn't have to be done
-        * each time we draw, but usually a new projection needs to
-        * be set when the viewport is resized.
-        */
-
-        float ratio = (float) w / h;
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glLoadIdentity();
-        gl.glFrustumf(-ratio, ratio, -1, 1, 1, 10);
-        mProjector.getCurrentProjection(gl);
-    }
-
-    private int mWidth;
-    private int mHeight;
-    private Context mContext;
-    private Triangle mTriangle;
-    private int mTextureID;
-    private int mFrames;
-    private int mMsPerFrame;
-    private final static int SAMPLE_PERIOD_FRAMES = 12;
-    private final static float SAMPLE_FACTOR = 1.0f / SAMPLE_PERIOD_FRAMES;
-    private long mStartTime;
-    private LabelMaker mLabels;
-    private Paint mLabelPaint;
-    private int mLabelA;
-    private int mLabelB;
-    private int mLabelC;
-    private int mLabelMsPF;
-    private Projector mProjector;
-    private NumericSprite mNumericSprite;
-    private float[] mScratch = new float[8];
-}
-
-class Triangle {
-    public Triangle() {
-
-        // Buffers to be passed to gl*Pointer() functions
-        // must be direct, i.e., they must be placed on the
-        // native heap where the garbage collector cannot
-        // move them.
-        //
-        // Buffers with multi-byte datatypes (e.g., short, int, float)
-        // must have their byte order set to native order
-
-        ByteBuffer vbb = ByteBuffer.allocateDirect(VERTS * 3 * 4);
-        vbb.order(ByteOrder.nativeOrder());
-        mFVertexBuffer = vbb.asFloatBuffer();
-
-        ByteBuffer tbb = ByteBuffer.allocateDirect(VERTS * 2 * 4);
-        tbb.order(ByteOrder.nativeOrder());
-        mTexBuffer = tbb.asFloatBuffer();
-
-        ByteBuffer ibb = ByteBuffer.allocateDirect(VERTS * 2);
-        ibb.order(ByteOrder.nativeOrder());
-        mIndexBuffer = ibb.asShortBuffer();
-
-        for (int i = 0; i < VERTS; i++) {
-            for(int j = 0; j < 3; j++) {
-                mFVertexBuffer.put(sCoords[i*3+j]);
-            }
-        }
-
-        for (int i = 0; i < VERTS; i++) {
-            for(int j = 0; j < 2; j++) {
-                mTexBuffer.put(sCoords[i*3+j] * 2.0f + 0.5f);
-            }
-        }
-
-        for(int i = 0; i < VERTS; i++) {
-            mIndexBuffer.put((short) i);
-        }
-
-        mFVertexBuffer.position(0);
-        mTexBuffer.position(0);
-        mIndexBuffer.position(0);
-    }
-
-    public void draw(GL10 gl) {
-        gl.glFrontFace(GL10.GL_CCW);
-        gl.glVertexPointer(3, GL10.GL_FLOAT, 0, mFVertexBuffer);
-        gl.glEnable(GL10.GL_TEXTURE_2D);
-        gl.glTexCoordPointer(2, GL10.GL_FLOAT, 0, mTexBuffer);
-        gl.glDrawElements(GL10.GL_TRIANGLE_STRIP, VERTS,
-                GL10.GL_UNSIGNED_SHORT, mIndexBuffer);
-    }
-
-    public float getX(int vertex) {
-        return sCoords[3*vertex];
-    }
-
-    public float getY(int vertex) {
-        return sCoords[3*vertex+1];
-    }
-
-    private final static int VERTS = 3;
-
-    private FloatBuffer mFVertexBuffer;
-    private FloatBuffer mTexBuffer;
-    private ShortBuffer mIndexBuffer;
-    // A unit-sided equalateral triangle centered on the origin.
-    private final static float[] sCoords = {
-            // X, Y, Z
-            -0.5f, -0.25f, 0,
-             0.5f, -0.25f, 0,
-             0.0f,  0.559016994f, 0
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo.java b/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo.java
deleted file mode 100644
index 4b89167..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo.java
+++ /dev/null
@@ -1,86 +0,0 @@
-package com.example.android.apis.media;
-
-import com.example.android.apis.R;
-import android.app.Activity;
-import android.content.Intent;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-public class MediaPlayerDemo extends Activity {
-    private Button mlocalvideo;
-    private Button mresourcesvideo;
-    private Button mstreamvideo;
-    private Button mlocalaudio;
-    private Button mresourcesaudio;
-    private Button mstreamaudio;
-    private static final String MEDIA = "media";
-    private static final int LOCAL_AUDIO = 1;
-    private static final int STREAM_AUDIO = 2;
-    private static final int RESOURCES_AUDIO = 3;
-    private static final int LOCAL_VIDEO = 4;
-    private static final int STREAM_VIDEO = 5;
-    private static final int RESOURCES_VIDEO = 6;
-
-    @Override
-    protected void onCreate(Bundle icicle) {
-        // TODO Auto-generated method stub
-        super.onCreate(icicle);
-        setContentView(R.layout.mediaplayer_1);
-        mlocalaudio = (Button) findViewById(R.id.localaudio);
-        mlocalaudio.setOnClickListener(mLocalAudioListener);
-        mresourcesaudio = (Button) findViewById(R.id.resourcesaudio);
-        mresourcesaudio.setOnClickListener(mResourcesAudioListener);
-
-        mlocalvideo = (Button) findViewById(R.id.localvideo);
-        mlocalvideo.setOnClickListener(mLocalVideoListener);
-        mstreamvideo = (Button) findViewById(R.id.streamvideo);
-        mstreamvideo.setOnClickListener(mStreamVideoListener);
-    }
-
-    private OnClickListener mLocalAudioListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent =
-                    new Intent(MediaPlayerDemo.this.getApplication(),
-                            MediaPlayerDemo_Audio.class);
-            intent.putExtra(MEDIA, LOCAL_AUDIO);
-            startActivity(intent);
-
-        }
-    };
-    private OnClickListener mResourcesAudioListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent =
-                    new Intent(MediaPlayerDemo.this.getApplication(),
-                            MediaPlayerDemo_Audio.class);
-            intent.putExtra(MEDIA, RESOURCES_AUDIO);
-            startActivity(intent);
-
-        }
-    };
-
-    private OnClickListener mLocalVideoListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent =
-                    new Intent(MediaPlayerDemo.this,
-                            MediaPlayerDemo_Video.class);
-            intent.putExtra(MEDIA, LOCAL_VIDEO);
-            startActivity(intent);
-
-        }
-    };
-    private OnClickListener mStreamVideoListener = new OnClickListener() {
-        public void onClick(View v) {
-            Intent intent =
-                    new Intent(MediaPlayerDemo.this,
-                            MediaPlayerDemo_Video.class);
-            intent.putExtra(MEDIA, STREAM_VIDEO);
-            startActivity(intent);
-
-        }
-    };
-
-
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Audio.java b/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Audio.java
deleted file mode 100644
index 39930f6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Audio.java
+++ /dev/null
@@ -1,85 +0,0 @@
-package com.example.android.apis.media;
-
-import android.app.Activity;
-import android.media.MediaPlayer;
-import android.os.Bundle;
-import android.util.Log;
-import android.widget.TextView;
-import android.widget.Toast;
-
-import com.example.android.apis.R;
-
-public class MediaPlayerDemo_Audio extends Activity {
-
-    private static final String TAG = "MediaPlayerDemo";
-    private MediaPlayer mMediaPlayer;
-    private static final String MEDIA = "media";
-    private static final int LOCAL_AUDIO = 1;
-    private static final int STREAM_AUDIO = 2;
-    private static final int RESOURCES_AUDIO = 3;
-    private static final int LOCAL_VIDEO = 4;
-    private static final int STREAM_VIDEO = 5;
-    private String path;
-
-    private TextView tx;
-
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        tx = new TextView(this);
-        setContentView(tx);
-        Bundle extras = getIntent().getExtras();
-        playAudio(extras.getInt(MEDIA));
-    }
-
-    private void playAudio(Integer media) {
-        try {
-            switch (media) {
-                case LOCAL_AUDIO:
-                    /**
-                     * TODO: Set the path variable to a local audio file path.
-                     */
-                    path = "";
-                    if (path == "") {
-                        // Tell the user to provide an audio file URL.
-                        Toast
-                                .makeText(
-                                        MediaPlayerDemo_Audio.this,
-                                        "Please edit MediaPlayer_Audio Activity, "
-                                                + "and set the path variable to your audio file path."
-                                                + " Your audio file must be stored on sdcard.",
-                                        Toast.LENGTH_LONG).show();
-
-                    }
-                    mMediaPlayer = new MediaPlayer();
-                    mMediaPlayer.setDataSource(path);
-                    mMediaPlayer.prepare();
-                    mMediaPlayer.start();
-                    break;
-                case RESOURCES_AUDIO:
-                    /**
-                     * TODO: Upload a audio file to res/raw folder and provide
-                     * its resid in MediaPlayer.create() method.
-                     */
-                    mMediaPlayer = MediaPlayer.create(this, R.raw.test_cbr);
-                    mMediaPlayer.start();
-
-            }
-            tx.setText("Playing audio...");
-
-        } catch (Exception e) {
-            Log.e(TAG, "error: " + e.getMessage(), e);
-        }
-
-    }
-
-    @Override
-    protected void onDestroy() {
-        super.onDestroy();
-        // TODO Auto-generated method stub
-        if (mMediaPlayer != null) {
-            mMediaPlayer.release();
-            mMediaPlayer = null;
-        }
-
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Video.java b/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Video.java
deleted file mode 100644
index fd3c486..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/media/MediaPlayerDemo_Video.java
+++ /dev/null
@@ -1,169 +0,0 @@
-package com.example.android.apis.media;
-
-import com.example.android.apis.R;
-import com.example.android.apis.app.AlarmController;
-
-import android.app.Activity;
-import android.graphics.PixelFormat;
-import android.media.AudioManager;
-import android.media.MediaPlayer;
-import android.media.MediaPlayer.OnBufferingUpdateListener;
-import android.media.MediaPlayer.OnCompletionListener;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.Toast;
-
-
-public class MediaPlayerDemo_Video extends Activity implements
-        OnBufferingUpdateListener, OnCompletionListener,
-        MediaPlayer.OnPreparedListener, SurfaceHolder.Callback {
-
-    private static final String TAG = "MediaPlayerDemo";
-    private int mVideoWidth;
-    private int mVideoHeight;
-    private MediaPlayer mMediaPlayer;
-    private SurfaceView mPreview;
-    private SurfaceHolder holder;
-    private String path;
-    private Bundle extras;
-    private static final String MEDIA = "media";
-    private static final int LOCAL_AUDIO = 1;
-    private static final int STREAM_AUDIO = 2;
-    private static final int RESOURCES_AUDIO = 3;
-    private static final int LOCAL_VIDEO = 4;
-    private static final int STREAM_VIDEO = 5;
-
-    /**
-     * 
-     * Called when the activity is first created.
-     */
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.mediaplayer_2);
-        mPreview = (SurfaceView) findViewById(R.id.surface);
-        holder = mPreview.getHolder();
-        holder.addCallback(this);
-        holder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS);
-        extras = getIntent().getExtras();
-
-    }
-
-    private void playVideo(Integer Media) {
-        try {
-
-            switch (Media) {
-                case LOCAL_VIDEO:
-                    /*
-                     * TODO: Set the path variable to a local media file path.
-                     */
-                    path = "";
-                    if (path == "") {
-                        // Tell the user to provide a media file URL.
-                        Toast
-                                .makeText(
-                                        MediaPlayerDemo_Video.this,
-                                        "Please edit MediaPlayerDemo_Video Activity, "
-                                                + "and set the path variable to your media file path."
-                                                + " Your media file must be stored on sdcard.",
-                                        Toast.LENGTH_LONG).show();
-
-                    }
-                    break;
-                case STREAM_VIDEO:
-                    /*
-                     * TODO: Set path variable to progressive streamable mp4 or
-                     * 3gpp format URL. Http protocol should be used.
-                     * Mediaplayer can only play "progressive streamable
-                     * contents" which basically means: 1. the movie atom has to
-                     * precede all the media data atoms. 2. The clip has to be
-                     * reasonably interleaved.
-                     * 
-                     */
-                    path = "";
-                    if (path == "") {
-                        // Tell the user to provide a media file URL.
-                        Toast
-                                .makeText(
-                                        MediaPlayerDemo_Video.this,
-                                        "Please edit MediaPlayerDemo_Video Activity,"
-                                                + " and set the path variable to your media file URL.",
-                                        Toast.LENGTH_LONG).show();
-
-                    }
-
-                    break;
-
-
-            }
-
-            // Create a new media player and set the listeners
-            mMediaPlayer = new MediaPlayer();
-            mMediaPlayer.setDataSource(path);
-            mMediaPlayer.setDisplay(holder);
-            mMediaPlayer.prepare();
-            mMediaPlayer.setOnBufferingUpdateListener(this);
-            mMediaPlayer.setOnCompletionListener(this);
-            mMediaPlayer.setOnPreparedListener(this);
-            mMediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);
-
-
-        } catch (Exception e) {
-            Log.e(TAG, "error: " + e.getMessage(), e);
-        }
-    }
-
-    public void onBufferingUpdate(MediaPlayer arg0, int percent) {
-        Log.d(TAG, "onBufferingUpdate percent:" + percent);
-
-    }
-
-    public void onCompletion(MediaPlayer arg0) {
-        Log.d(TAG, "onCompletion called");
-    }
-
-    public void onPrepared(MediaPlayer mediaplayer) {
-        Log.d(TAG, "onPrepared called");
-        mVideoWidth = mMediaPlayer.getVideoWidth();
-        mVideoHeight = mMediaPlayer.getVideoHeight();
-        if (mVideoWidth != 0 && mVideoHeight != 0) {
-            holder.setFixedSize(mVideoWidth, mVideoHeight);
-            mMediaPlayer.start();
-        }
-
-    }
-
-    public void surfaceChanged(SurfaceHolder surfaceholder, int i, int j, int k) {
-        Log.d(TAG, "surfaceChanged called");
-
-    }
-
-    public void surfaceDestroyed(SurfaceHolder surfaceholder) {
-        Log.d(TAG, "surfaceDestroyed called");
-    }
-
-
-    public void surfaceCreated(SurfaceHolder holder) {
-        // TODO Auto-generated method stub
-        Log.d(TAG, "surfaceCreated called");
-        playVideo(extras.getInt(MEDIA));
-
-
-    }
-
-    @Override
-    protected void onDestroy() {
-        super.onDestroy();
-        // TODO Auto-generated method stub
-        if (mMediaPlayer != null) {
-            mMediaPlayer.release();
-            mMediaPlayer = null;
-        }
-
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/media/VideoViewDemo.java b/samples/ApiDemos/src/com/example/android/apis/media/VideoViewDemo.java
deleted file mode 100644
index a4fcf5f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/media/VideoViewDemo.java
+++ /dev/null
@@ -1,48 +0,0 @@
-package com.example.android.apis.media;
-
-import com.example.android.apis.R;
-import android.app.Activity;
-import android.graphics.PixelFormat;
-import android.net.Uri;
-import android.os.Bundle;
-import android.util.Log;
-import android.widget.MediaController;
-import android.widget.Toast;
-import android.widget.VideoView;
-
-public class VideoViewDemo extends Activity {
-
-    /**
-     * TODO: Set the path variable to a streaming video URL or a local media
-     * file path.
-     */
-    private String path = "";
-    private VideoView mVideoView;
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        setContentView(R.layout.videoview);
-        mVideoView = (VideoView) findViewById(R.id.surface_view);
-
-        if (path == "") {
-            // Tell the user to provide a media file URL/path.
-            Toast.makeText(
-                    VideoViewDemo.this,
-                    "Please edit VideoViewDemo Activity, and set path"
-                            + " variable to your media file URL/path",
-                    Toast.LENGTH_LONG).show();
-
-        } else {
-
-            /*
-             * Alternatively,for streaming media you can use
-             * mVideoView.setVideoURI(Uri.parse(URLstring));
-             */
-            mVideoView.setVideoPath(path);
-            mVideoView.setMediaController(new MediaController(this));
-            mVideoView.requestFocus();
-
-        }
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/os/MorseCode.java b/samples/ApiDemos/src/com/example/android/apis/os/MorseCode.java
deleted file mode 100644
index dafa192..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/os/MorseCode.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.os;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-
-import android.app.Activity;
-import android.content.Context;
-import android.os.Bundle;
-import android.os.Vibrator;
-import android.view.View;
-import android.widget.TextView;
-import com.example.android.apis.R;
-
-/**
- * <h3>App that vibrates the vibrator with the Morse Code for a string.</h3>
-
-<p>This demonstrates the {@link android.os.Vibrator android.os.Vibrator} class.
-
-<h4>Demo</h4>
-OS / Morse Code Vibrator
- 
-<h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td >src/com.example.android.apis/os/MorseCode.java</td>
- *             <td >The Morse Code Vibrator</td>
- *         </tr>
- *         <tr>
- *             <td >res/any/layout/morse_code.xml</td>
- *             <td >Defines contents of the screen</td>
- *         </tr>
- * </table> 
- */
-public class MorseCode extends Activity
-{
-    /** Tag string for our debug logs */
-    private static final String TAG = "MorseCode";
-
-    /** Our text view */
-    private TextView mTextView;
-
-    ;
-
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-	protected void onCreate(Bundle savedInstanceState)
-    {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        // See assets/res/any/layout/hello_world.xml for this
-        // view layout definition, which is being set here as
-        // the content of our screen.
-        setContentView(R.layout.morse_code);
-
-        // Set the OnClickListener for the button so we see when it's pressed.
-        findViewById(R.id.button).setOnClickListener(mClickListener);
-
-        // Save the text view so we don't have to look it up each time
-        mTextView = (TextView)findViewById(R.id.text);
-    }
-
-    /** Called when the button is pushed */
-    View.OnClickListener mClickListener = new View.OnClickListener() {
-        public void onClick(View v) {
-            // Get the text out of the view
-            String text = mTextView.getText().toString();
-
-            // convert it using the function defined above.  See the docs for
-            // android.os.Vibrator for more info about the format of this array
-            long[] pattern = MorseCodeConverter.pattern(text);
-
-            // Start the vibration
-            Vibrator vibrator = (Vibrator)getSystemService(Context.VIBRATOR_SERVICE);
-            vibrator.vibrate(pattern, -1);
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/os/MorseCodeConverter.java b/samples/ApiDemos/src/com/example/android/apis/os/MorseCodeConverter.java
deleted file mode 100644
index c68fab9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/os/MorseCodeConverter.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.os;
-
-/** Class that implements the text to morse code coversion */
-class MorseCodeConverter {
-    private static final long SPEED_BASE = 100;
-    static final long DOT = SPEED_BASE;
-    static final long DASH = SPEED_BASE * 3;
-    static final long GAP = SPEED_BASE;
-    static final long LETTER_GAP = SPEED_BASE * 3;
-    static final long WORD_GAP = SPEED_BASE * 7;
-
-    /** The characters from 'A' to 'Z' */
-    private static final long[][] LETTERS = new long[][] {
-        /* A */ new long[] { DOT, GAP, DASH },
-        /* B */ new long[] { DASH, GAP, DOT, GAP, DOT, GAP, DOT },
-        /* C */ new long[] { DASH, GAP, DOT, GAP, DASH, GAP, DOT },
-        /* D */ new long[] { DASH, GAP, DOT, GAP, DOT },
-        /* E */ new long[] { DOT },
-        /* F */ new long[] { DOT, GAP, DOT, GAP, DASH, GAP, DOT },
-        /* G */ new long[] { DASH, GAP, DASH, GAP, DOT },
-        /* H */ new long[] { DOT, GAP, DOT, GAP, DOT, GAP, DOT },
-        /* I */ new long[] { DOT, GAP, DOT },
-        /* J */ new long[] { DOT, GAP, DASH, GAP, DASH, GAP, DASH },
-        /* K */ new long[] { DASH, GAP, DOT, GAP, DASH },
-        /* L */ new long[] { DOT, GAP, DASH, GAP, DOT, GAP, DOT },
-        /* M */ new long[] { DASH, GAP, DASH },
-        /* N */ new long[] { DASH, GAP, DOT },
-        /* O */ new long[] { DASH, GAP, DASH, GAP, DASH },
-        /* P */ new long[] { DOT, GAP, DASH, GAP, DASH, GAP, DOT },
-        /* Q */ new long[] { DASH, GAP, DASH, GAP, DOT, GAP, DASH },
-        /* R */ new long[] { DOT, GAP, DASH, GAP, DOT },
-        /* S */ new long[] { DOT, GAP, DOT, GAP, DOT },
-        /* T */ new long[] { DASH },
-        /* U */ new long[] { DOT, GAP, DOT, GAP, DASH },
-        /* V */ new long[] { DOT, GAP, DOT, GAP, DASH },
-        /* W */ new long[] { DOT, GAP, DASH, GAP, DASH },
-        /* X */ new long[] { DASH, GAP, DOT, GAP, DOT, GAP, DASH },
-        /* Y */ new long[] { DASH, GAP, DOT, GAP, DASH, GAP, DASH },
-        /* Z */ new long[] { DASH, GAP, DASH, GAP, DOT, GAP, DOT },
-    };
-
-    /** The characters from '0' to '9' */
-    private static final long[][] NUMBERS = new long[][] {
-        /* 0 */ new long[] { DASH, GAP, DASH, GAP, DASH, GAP, DASH, GAP, DASH },
-        /* 1 */ new long[] { DOT, GAP, DASH, GAP, DASH, GAP, DASH, GAP, DASH },
-        /* 2 */ new long[] { DOT, GAP, DOT, GAP, DASH, GAP, DASH, GAP, DASH },
-        /* 3 */ new long[] { DOT, GAP, DOT, GAP, DOT, GAP, DASH, GAP, DASH },
-        /* 4 */ new long[] { DOT, GAP, DOT, GAP, DOT, GAP, DOT, GAP, DASH },
-        /* 5 */ new long[] { DOT, GAP, DOT, GAP, DOT, GAP, DOT, GAP, DOT },
-        /* 6 */ new long[] { DASH, GAP, DOT, GAP, DOT, GAP, DOT, GAP, DOT },
-        /* 7 */ new long[] { DASH, GAP, DASH, GAP, DOT, GAP, DOT, GAP, DOT },
-        /* 8 */ new long[] { DASH, GAP, DASH, GAP, DASH, GAP, DOT, GAP, DOT },
-        /* 9 */ new long[] { DASH, GAP, DASH, GAP, DASH, GAP, DASH, GAP, DOT },
-    };
-
-    private static final long[] ERROR_GAP = new long[] { GAP };
-
-    /** Return the pattern data for a given character */
-    static long[] pattern(char c) {
-        if (c >= 'A' && c <= 'Z') {
-            return LETTERS[c - 'A'];
-        }
-        if (c >= 'a' && c <= 'z') {
-            return LETTERS[c - 'a'];
-        }
-        else if (c >= '0' && c <= '9') {
-            return NUMBERS[c - '0'];
-        }
-        else {
-            return ERROR_GAP;
-        }
-    }
-
-    static long[] pattern(String str) {
-        boolean lastWasWhitespace;
-        int strlen = str.length();
-
-        // Calculate how long our array needs to be.
-        int len = 1;
-        lastWasWhitespace = true;
-        for (int i=0; i<strlen; i++) {
-            char c = str.charAt(i);
-            if (Character.isWhitespace(c)) {
-                if (!lastWasWhitespace) {
-                    len++;
-                    lastWasWhitespace = true;
-                }
-            } else {
-                if (!lastWasWhitespace) {
-                    len++;
-                }
-                lastWasWhitespace = false;
-                len += pattern(c).length;
-            }
-        }
-
-        // Generate the pattern array.  Note that we put an extra element of 0
-        // in at the beginning, because the pattern always starts with the pause,
-        // not with the vibration.
-        long[] result = new long[len+1];
-        result[0] = 0;
-        int pos = 1;
-        lastWasWhitespace = true;
-        for (int i=0; i<strlen; i++) {
-            char c = str.charAt(i);
-            if (Character.isWhitespace(c)) {
-                if (!lastWasWhitespace) {
-                    result[pos] = WORD_GAP;
-                    pos++;
-                    lastWasWhitespace = true;
-                }
-            } else {
-                if (!lastWasWhitespace) {
-                    result[pos] = LETTER_GAP;
-                    pos++;
-                }
-                lastWasWhitespace = false;
-                long[] letter = pattern(c);
-                System.arraycopy(letter, 0, result, pos, letter.length);
-                pos += letter.length;
-            }
-        }
-        return result;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/os/Sensors.java b/samples/ApiDemos/src/com/example/android/apis/os/Sensors.java
deleted file mode 100644
index 910961d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/os/Sensors.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.os;
-
-import android.app.Activity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.hardware.SensorManager;
-import android.hardware.SensorListener;
-import android.util.Log;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Color;
-import android.graphics.Paint;
-import android.graphics.Path;
-import android.graphics.RectF;
-
-/**
- * <h3>Application that displays the values of the acceleration sensor graphically.</h3>
-
-<p>This demonstrates the {@link android.hardware.SensorManager android.hardware.SensorManager} class.
-
-<h4>Demo</h4>
-OS / Sensors
- 
-<h4>Source files</h4>
- * <table class="LinkTable">
- *         <tr>
- *             <td >src/com.example.android.apis/os/Sensors.java</td>
- *             <td >Sensors</td>
- *         </tr>
- * </table> 
- */
-public class Sensors extends Activity {
-    /** Tag string for our debug logs */
-    private static final String TAG = "Sensors";
-
-    private SensorManager mSensorManager;
-    private GraphView mGraphView;
-
-    private class GraphView extends View implements SensorListener
-    {
-        private Bitmap  mBitmap;
-        private Paint   mPaint = new Paint();
-        private Canvas  mCanvas = new Canvas();
-        private Path    mPath = new Path();
-        private RectF   mRect = new RectF();
-        private float   mLastValues[] = new float[3*2];
-        private float   mOrientationValues[] = new float[3];
-        private int     mColors[] = new int[3*2];
-        private float   mLastX;
-        private float   mScale[] = new float[2];
-        private float   mYOffset;
-        private float   mMaxX;
-        private float   mSpeed = 1.0f;
-        private float   mWidth;
-        private float   mHeight;
-        
-        public GraphView(Context context) {
-            super(context);
-            mColors[0] = Color.argb(192, 255, 64, 64);
-            mColors[1] = Color.argb(192, 64, 128, 64);
-            mColors[2] = Color.argb(192, 64, 64, 255);
-            mColors[3] = Color.argb(192, 64, 255, 255);
-            mColors[4] = Color.argb(192, 128, 64, 128);
-            mColors[5] = Color.argb(192, 255, 255, 64);
-
-            mPaint.setFlags(Paint.ANTI_ALIAS_FLAG);
-            mRect.set(-0.5f, -0.5f, 0.5f, 0.5f);
-            mPath.arcTo(mRect, 0, 180);
-        }
-        
-        @Override
-        protected void onSizeChanged(int w, int h, int oldw, int oldh) {
-            mBitmap = Bitmap.createBitmap(w, h, Bitmap.Config.RGB_565);
-            mCanvas.setBitmap(mBitmap);
-            mCanvas.drawColor(0xFFFFFFFF);
-            mYOffset = h * 0.5f;
-            mScale[0] = - (h * 0.5f * (1.0f / (SensorManager.STANDARD_GRAVITY * 2)));
-            mScale[1] = - (h * 0.5f * (1.0f / (SensorManager.MAGNETIC_FIELD_EARTH_MAX)));
-            mWidth = w;
-            mHeight = h;
-            if (mWidth < mHeight) {
-                mMaxX = w;
-            } else {
-                mMaxX = w-50;
-            }
-            mLastX = mMaxX;
-            super.onSizeChanged(w, h, oldw, oldh);
-        }
-
-        @Override
-        protected void onDraw(Canvas canvas) {
-            synchronized (this) {
-                if (mBitmap != null) {
-                    final Paint paint = mPaint;
-                    final Path path = mPath;
-                    final int outer = 0xFFC0C0C0;
-                    final int inner = 0xFFff7010;
-
-                    if (mLastX >= mMaxX) {
-                        mLastX = 0;
-                        final Canvas cavas = mCanvas;
-                        final float yoffset = mYOffset;
-                        final float maxx = mMaxX;
-                        final float oneG = SensorManager.STANDARD_GRAVITY * mScale[0];
-                        paint.setColor(0xFFAAAAAA);
-                        cavas.drawColor(0xFFFFFFFF);
-                        cavas.drawLine(0, yoffset,      maxx, yoffset,      paint);
-                        cavas.drawLine(0, yoffset+oneG, maxx, yoffset+oneG, paint);
-                        cavas.drawLine(0, yoffset-oneG, maxx, yoffset-oneG, paint);
-                    }
-                    canvas.drawBitmap(mBitmap, 0, 0, null);
-
-                    float[] values = mOrientationValues;
-                    if (mWidth < mHeight) {
-                        float w0 = mWidth * 0.333333f;
-                        float w  = w0 - 32;
-                        float x = w0*0.5f;
-                        for (int i=0 ; i<3 ; i++) {
-                            canvas.save(Canvas.MATRIX_SAVE_FLAG);
-                            canvas.translate(x, w*0.5f + 4.0f);
-                            canvas.save(Canvas.MATRIX_SAVE_FLAG);
-                            paint.setColor(outer);
-                            canvas.scale(w, w);
-                            canvas.drawOval(mRect, paint);
-                            canvas.restore();
-                            canvas.scale(w-5, w-5);
-                            paint.setColor(inner);
-                            canvas.rotate(-values[i]);
-                            canvas.drawPath(path, paint);
-                            canvas.restore();
-                            x += w0;
-                        }
-                    } else {
-                        float h0 = mHeight * 0.333333f;
-                        float h  = h0 - 32;
-                        float y = h0*0.5f;
-                        for (int i=0 ; i<3 ; i++) {
-                            canvas.save(Canvas.MATRIX_SAVE_FLAG);
-                            canvas.translate(mWidth - (h*0.5f + 4.0f), y);
-                            canvas.save(Canvas.MATRIX_SAVE_FLAG);
-                            paint.setColor(outer);
-                            canvas.scale(h, h);
-                            canvas.drawOval(mRect, paint);
-                            canvas.restore();
-                            canvas.scale(h-5, h-5);
-                            paint.setColor(inner);
-                            canvas.rotate(-values[i]);
-                            canvas.drawPath(path, paint);
-                            canvas.restore();
-                            y += h0;
-                        }
-                    }
-
-                }
-            }
-        }
-
-        public void onSensorChanged(int sensor, float[] values) {
-            //Log.d(TAG, "sensor: " + sensor + ", x: " + values[0] + ", y: " + values[1] + ", z: " + values[2]);
-            synchronized (this) {
-                if (mBitmap != null) {
-                    final Canvas canvas = mCanvas;
-                    final Paint paint = mPaint;
-                    if (sensor == SensorManager.SENSOR_ORIENTATION) {
-                        for (int i=0 ; i<3 ; i++) {
-                            mOrientationValues[i] = values[i];
-                        }
-                    } else {
-                        float deltaX = mSpeed;
-                        float newX = mLastX + deltaX;
-
-                        int j = (sensor == SensorManager.SENSOR_MAGNETIC_FIELD) ? 1 : 0;
-                        for (int i=0 ; i<3 ; i++) {
-                            int k = i+j*3;
-                            final float v = mYOffset + values[i] * mScale[j];
-                            paint.setColor(mColors[k]);
-                            canvas.drawLine(mLastX, mLastValues[k], newX, v, paint);
-                            mLastValues[k] = v;
-                        }
-                        if (sensor == SensorManager.SENSOR_MAGNETIC_FIELD)
-                            mLastX += mSpeed;
-                    }
-                    invalidate();
-                }
-            }
-        }
-
-        public void onAccuracyChanged(int sensor, int accuracy) {
-            // TODO Auto-generated method stub
-            
-        }
-    }
-    
-    /**
-     * Initialization of the Activity after it is first created.  Must at least
-     * call {@link android.app.Activity#setContentView setContentView()} to
-     * describe what is to be displayed in the screen.
-     */
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        // Be sure to call the super class.
-        super.onCreate(savedInstanceState);
-
-        mSensorManager = (SensorManager) getSystemService(SENSOR_SERVICE);
-        mGraphView = new GraphView(this);
-        setContentView(mGraphView);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mSensorManager.registerListener(mGraphView, 
-                SensorManager.SENSOR_ACCELEROMETER | 
-                SensorManager.SENSOR_MAGNETIC_FIELD | 
-                SensorManager.SENSOR_ORIENTATION,
-                SensorManager.SENSOR_DELAY_FASTEST);
-    }
-    
-    @Override
-    protected void onStop() {
-        mSensorManager.unregisterListener(mGraphView);
-        super.onStop();
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/text/Link.java b/samples/ApiDemos/src/com/example/android/apis/text/Link.java
deleted file mode 100644
index b569d19..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/text/Link.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.text;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.graphics.Typeface;
-import android.os.Bundle;
-import android.text.Html;
-import android.text.SpannableString;
-import android.text.Spanned;
-import android.text.method.LinkMovementMethod;
-import android.text.style.StyleSpan;
-import android.text.style.URLSpan;
-import android.widget.TextView;
-
-public class Link extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.link);
-
-        // text1 shows the android:autoLink property, which
-        // automatically linkifies things like URLs and phone numbers
-        // found in the text.  No java code is needed to make this
-        // work.
-
-        // text2 has links specified by putting <a> tags in the string
-        // resource.  By default these links will appear but not
-        // respond to user input.  To make them active, you need to
-        // call setMovementMethod() on the TextView object.
-
-        TextView t2 = (TextView) findViewById(R.id.text2);
-        t2.setMovementMethod(LinkMovementMethod.getInstance());
-
-        // text3 shows creating text with links from HTML in the Java
-        // code, rather than from a string resource.  Note that for a
-        // fixed string, using a (localizable) resource as shown above
-        // is usually a better way to go; this example is intended to
-        // illustrate how you might display text that came from a
-        // dynamic source (eg, the network).
-
-        TextView t3 = (TextView) findViewById(R.id.text3);
-        t3.setText(
-            Html.fromHtml(
-                "<b>text3:</b>  Text with a " +
-                "<a href=\"http://www.google.com\">link</a> " +
-                "created in the Java source code using HTML."));
-        t3.setMovementMethod(LinkMovementMethod.getInstance());
-
-        // text4 illustrates constructing a styled string containing a
-        // link without using HTML at all.  Again, for a fixed string
-        // you should probably be using a string resource, not a
-        // hardcoded value.
-
-        SpannableString ss = new SpannableString(
-            "text4: Click here to dial the phone.");
-
-        ss.setSpan(new StyleSpan(Typeface.BOLD), 0, 6,
-                   Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
-        ss.setSpan(new URLSpan("tel:4155551212"), 13, 17,
-                   Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
-
-        TextView t4 = (TextView) findViewById(R.id.text4);
-        t4.setText(ss);
-        t4.setMovementMethod(LinkMovementMethod.getInstance());
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox.java b/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox.java
deleted file mode 100644
index c78b54b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.text;
-
-import android.widget.TextView;
-import android.content.Context;
-import android.text.method.ScrollingMovementMethod;
-import android.text.method.MovementMethod;
-import android.text.method.KeyListener;
-import android.text.method.TransformationMethod;
-import android.text.Editable;
-import android.util.AttributeSet;
-
-import java.util.Map;
-
-/**
- * This is a TextView that is Editable and by default scrollable,
- * like EditText without a cursor.
- *
- * <p>
- * <b>XML attributes</b>
- * <p>
- * See
- * {@link android.R.styleable#TextView TextView Attributes},
- * {@link android.R.styleable#View View Attributes}
- */
-public class LogTextBox extends TextView {
-    public LogTextBox(Context context) {
-        this(context, null);
-    }
-
-    public LogTextBox(Context context, AttributeSet attrs) {
-        this(context, attrs, android.R.attr.textViewStyle);
-    }
-
-    public LogTextBox(Context context, AttributeSet attrs, int defStyle) {
-        super(context, attrs, defStyle);
-    }
-
-    @Override
-    protected MovementMethod getDefaultMovementMethod() {
-        return ScrollingMovementMethod.getInstance();
-    }
-
-    @Override
-    public Editable getText() {
-        return (Editable) super.getText();
-    }
-
-    @Override
-    public void setText(CharSequence text, BufferType type) {
-        super.setText(text, BufferType.EDITABLE);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox1.java b/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox1.java
deleted file mode 100644
index 1813629..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/text/LogTextBox1.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.text;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-
-/**
- * Using a LogTextBox to display a scrollable text area
- * to which text is appended.
- *
- */
-public class LogTextBox1 extends Activity {
-    
-    private LogTextBox mText;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        setContentView(R.layout.log_text_box_1);
-        
-        mText = (LogTextBox) findViewById(R.id.text);
-        
-        Button addButton = (Button) findViewById(R.id.add);
-        addButton.setOnClickListener(new View.OnClickListener() {
-
-            public void onClick(View v) {
-                mText.append("This is a test\n");
-            } });
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/text/Marquee.java b/samples/ApiDemos/src/com/example/android/apis/text/Marquee.java
deleted file mode 100644
index ba82ed6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/text/Marquee.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/* 
- * Copyright (C) 2007 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.text;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class Marquee extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        setContentView(R.layout.marquee);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/text/_index.html b/samples/ApiDemos/src/com/example/android/apis/text/_index.html
deleted file mode 100644
index ee1020b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/text/_index.html
+++ /dev/null
@@ -1,6 +0,0 @@
-<dl>
-  <dt><a href="Link.html">Linkify</a></dt>
-  <dd>Demonstrates the {@link android.text.util.Linkify Linkify} class, which converts URLs in a block of text into hyperlinks. </dd>
-</dl>
-
-
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Animation1.java b/samples/ApiDemos/src/com/example/android/apis/view/Animation1.java
deleted file mode 100644
index 73563f3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Animation1.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.view.animation.Animation;
-import android.view.animation.AnimationUtils;
-
-public class Animation1 extends Activity implements View.OnClickListener {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.animation_1);
-
-        View loginButton = findViewById(R.id.login);
-        loginButton.setOnClickListener(this);
-    }
-
-    public void onClick(View v) {
-        Animation shake = AnimationUtils.loadAnimation(this, R.anim.shake);
-        findViewById(R.id.pw).startAnimation(shake);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Animation2.java b/samples/ApiDemos/src/com/example/android/apis/view/Animation2.java
deleted file mode 100644
index b2236aa..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Animation2.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.view.animation.AnimationUtils;
-import android.widget.AdapterView;
-import android.widget.ArrayAdapter;
-import android.widget.Spinner;
-import android.widget.ViewFlipper;
-
-
-public class Animation2 extends Activity implements
-        AdapterView.OnItemSelectedListener {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.animation_2);
-
-        mFlipper = ((ViewFlipper) this.findViewById(R.id.flipper));
-        mFlipper.startFlipping();
-
-        Spinner s = (Spinner) findViewById(R.id.spinner);
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_spinner_item, mStrings);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        s.setAdapter(adapter);
-        s.setOnItemSelectedListener(this);
-    }
-
-    public void onItemSelected(AdapterView parent, View v, int position, long id) {
-        switch (position) {
-
-        case 0:
-            mFlipper.setInAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.push_up_in));
-            mFlipper.setOutAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.push_up_out));
-            break;
-        case 1:
-            mFlipper.setInAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.push_left_in));
-            mFlipper.setOutAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.push_left_out));
-            break;
-        case 2:
-            mFlipper.setInAnimation(AnimationUtils.loadAnimation(this,
-                    android.R.anim.fade_in));
-            mFlipper.setOutAnimation(AnimationUtils.loadAnimation(this,
-                    android.R.anim.fade_out));
-            break;
-        default:
-            mFlipper.setInAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.hyperspace_in));
-            mFlipper.setOutAnimation(AnimationUtils.loadAnimation(this,
-                    R.anim.hyperspace_out));
-            break;
-        }
-    }
-
-    public void onNothingSelected(AdapterView parent) {
-    }
-
-    private String[] mStrings = {
-            "Push up", "Push left", "Cross fade", "Hyperspace"};
-
-    private ViewFlipper mFlipper;
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete1.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete1.java
deleted file mode 100644
index f4274e5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete1.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.Spinner;
-import android.widget.ArrayAdapter;
-import android.widget.AutoCompleteTextView;
-import android.os.Bundle;
-import android.view.View;
-
-
-public class AutoComplete1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_1);
-
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_dropdown_item_1line, COUNTRIES);
-        AutoCompleteTextView textView = (AutoCompleteTextView) findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-    }
-
-    static final String[] COUNTRIES = new String[] {
-	"Afghanistan", "Albania", "Algeria", "American Samoa", "Andorra",
-	"Angola", "Anguilla", "Antarctica", "Antigua and Barbuda", "Argentina",
-	"Armenia", "Aruba", "Australia", "Austria", "Azerbaijan",
-	"Bahrain", "Bangladesh", "Barbados", "Belarus", "Belgium",
-	"Belize", "Benin", "Bermuda", "Bhutan", "Bolivia",
-	"Bosnia and Herzegovina", "Botswana", "Bouvet Island", "Brazil", "British Indian Ocean Territory",
-	"British Virgin Islands", "Brunei", "Bulgaria", "Burkina Faso", "Burundi",
-	"Cote d'Ivoire", "Cambodia", "Cameroon", "Canada", "Cape Verde",
-	"Cayman Islands", "Central African Republic", "Chad", "Chile", "China",
-	"Christmas Island", "Cocos (Keeling) Islands", "Colombia", "Comoros", "Congo",
-	"Cook Islands", "Costa Rica", "Croatia", "Cuba", "Cyprus", "Czech Republic",
-	"Democratic Republic of the Congo", "Denmark", "Djibouti", "Dominica", "Dominican Republic",
-	"East Timor", "Ecuador", "Egypt", "El Salvador", "Equatorial Guinea", "Eritrea",
-	"Estonia", "Ethiopia", "Faeroe Islands", "Falkland Islands", "Fiji", "Finland",
-	"Former Yugoslav Republic of Macedonia", "France", "French Guiana", "French Polynesia",
-	"French Southern Territories", "Gabon", "Georgia", "Germany", "Ghana", "Gibraltar",
-	"Greece", "Greenland", "Grenada", "Guadeloupe", "Guam", "Guatemala", "Guinea", "Guinea-Bissau",
-	"Guyana", "Haiti", "Heard Island and McDonald Islands", "Honduras", "Hong Kong", "Hungary",
-	"Iceland", "India", "Indonesia", "Iran", "Iraq", "Ireland", "Israel", "Italy", "Jamaica",
-	"Japan", "Jordan", "Kazakhstan", "Kenya", "Kiribati", "Kuwait", "Kyrgyzstan", "Laos",
-	"Latvia", "Lebanon", "Lesotho", "Liberia", "Libya", "Liechtenstein", "Lithuania", "Luxembourg",
-	"Macau", "Madagascar", "Malawi", "Malaysia", "Maldives", "Mali", "Malta", "Marshall Islands",
-	"Martinique", "Mauritania", "Mauritius", "Mayotte", "Mexico", "Micronesia", "Moldova",
-	"Monaco", "Mongolia", "Montserrat", "Morocco", "Mozambique", "Myanmar", "Namibia",
-	"Nauru", "Nepal", "Netherlands", "Netherlands Antilles", "New Caledonia", "New Zealand",
-	"Nicaragua", "Niger", "Nigeria", "Niue", "Norfolk Island", "North Korea", "Northern Marianas",
-	"Norway", "Oman", "Pakistan", "Palau", "Panama", "Papua New Guinea", "Paraguay", "Peru",
-	"Philippines", "Pitcairn Islands", "Poland", "Portugal", "Puerto Rico", "Qatar",
-	"Reunion", "Romania", "Russia", "Rwanda", "Sqo Tome and Principe", "Saint Helena",
-	"Saint Kitts and Nevis", "Saint Lucia", "Saint Pierre and Miquelon",
-	"Saint Vincent and the Grenadines", "Samoa", "San Marino", "Saudi Arabia", "Senegal",
-	"Seychelles", "Sierra Leone", "Singapore", "Slovakia", "Slovenia", "Solomon Islands",
-	"Somalia", "South Africa", "South Georgia and the South Sandwich Islands", "South Korea",
-	"Spain", "Sri Lanka", "Sudan", "Suriname", "Svalbard and Jan Mayen", "Swaziland", "Sweden",
-	"Switzerland", "Syria", "Taiwan", "Tajikistan", "Tanzania", "Thailand", "The Bahamas",
-	"The Gambia", "Togo", "Tokelau", "Tonga", "Trinidad and Tobago", "Tunisia", "Turkey",
-	"Turkmenistan", "Turks and Caicos Islands", "Tuvalu", "Virgin Islands", "Uganda",
-	"Ukraine", "United Arab Emirates", "United Kingdom",
-	"United States", "United States Minor Outlying Islands", "Uruguay", "Uzbekistan",
-	"Vanuatu", "Vatican City", "Venezuela", "Vietnam", "Wallis and Futuna", "Western Sahara",
-	"Yemen", "Yugoslavia", "Zambia", "Zimbabwe"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete2.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete2.java
deleted file mode 100644
index 2dcfc12..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete2.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.AutoCompleteTextView;
-
-
-public class AutoComplete2 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_2);
-
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_dropdown_item_1line,
-                AutoComplete1.COUNTRIES);
-        AutoCompleteTextView textView = (AutoCompleteTextView)
-                findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete3.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete3.java
deleted file mode 100644
index bb9408f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete3.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.AutoCompleteTextView;
-
-
-public class AutoComplete3 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_3);
-
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_dropdown_item_1line,
-                AutoComplete1.COUNTRIES);
-        AutoCompleteTextView textView = (AutoCompleteTextView)
-                findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-        textView = (AutoCompleteTextView) findViewById(R.id.edit2);
-        textView.setAdapter(adapter);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete4.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete4.java
deleted file mode 100644
index c6fa08b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete4.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ContentResolver;
-import android.content.Context;
-import android.database.Cursor;
-import android.os.Bundle;
-import android.provider.Contacts;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.AutoCompleteTextView;
-import android.widget.CursorAdapter;
-import android.widget.Filterable;
-import android.widget.TextView;
-
-public class AutoComplete4 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_4);
-
-        ContentResolver content = getContentResolver();
-        Cursor cursor = content.query(Contacts.People.CONTENT_URI,
-                PEOPLE_PROJECTION, null, null, Contacts.People.DEFAULT_SORT_ORDER);
-        ContactListAdapter adapter = new ContactListAdapter(this, cursor);
-
-        AutoCompleteTextView textView = (AutoCompleteTextView)
-                findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-    }
-
-    // XXX compiler bug in javac 1.5.0_07-164, we need to implement Filterable
-    // to make compilation work
-    public static class ContactListAdapter extends CursorAdapter implements Filterable {
-        public ContactListAdapter(Context context, Cursor c) {
-            super(context, c);
-            mContent = context.getContentResolver();
-        }
-
-        @Override
-        public View newView(Context context, Cursor cursor, ViewGroup parent) {
-            final LayoutInflater inflater = LayoutInflater.from(context);
-            final TextView view = (TextView) inflater.inflate(
-                    android.R.layout.simple_dropdown_item_1line, parent, false);
-            view.setText(cursor.getString(5));
-            return view;
-        }
-
-        @Override
-        public void bindView(View view, Context context, Cursor cursor) {
-            ((TextView) view).setText(cursor.getString(5));
-        }
-
-        @Override
-        public String convertToString(Cursor cursor) {
-            return cursor.getString(5);
-        }
-
-        @Override
-        public Cursor runQueryOnBackgroundThread(CharSequence constraint) {
-            if (getFilterQueryProvider() != null) {
-                return getFilterQueryProvider().runQuery(constraint);
-            }
-
-            StringBuilder buffer = null;
-            String[] args = null;
-            if (constraint != null) {
-                buffer = new StringBuilder();
-                buffer.append("UPPER(");
-                buffer.append(Contacts.ContactMethods.NAME);
-                buffer.append(") GLOB ?");
-                args = new String[] { constraint.toString().toUpperCase() + "*" };
-            }
-
-            return mContent.query(Contacts.People.CONTENT_URI, PEOPLE_PROJECTION,
-                    buffer == null ? null : buffer.toString(), args,
-                    Contacts.People.DEFAULT_SORT_ORDER);
-        }
-
-        private ContentResolver mContent;        
-    }
-
-    private static final String[] PEOPLE_PROJECTION = new String[] {
-        Contacts.People._ID,
-        Contacts.People.PRIMARY_PHONE_ID,
-        Contacts.People.TYPE,
-        Contacts.People.NUMBER,
-        Contacts.People.LABEL,
-        Contacts.People.NAME,
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete5.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete5.java
deleted file mode 100644
index 7406da4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete5.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.ContentResolver;
-import android.database.Cursor;
-import android.os.Bundle;
-import android.provider.Contacts;
-import android.widget.AutoCompleteTextView;
-
-public class AutoComplete5 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_5);
-
-        ContentResolver content = getContentResolver();
-        Cursor cursor = content.query(Contacts.People.CONTENT_URI,
-                PEOPLE_PROJECTION, null, null, Contacts.People.DEFAULT_SORT_ORDER);
-        AutoComplete4.ContactListAdapter adapter =
-                new AutoComplete4.ContactListAdapter(this, cursor);
-
-        AutoCompleteTextView textView = (AutoCompleteTextView)
-                findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-    }
-
-    private static final String[] PEOPLE_PROJECTION = new String[] {
-        Contacts.People._ID,
-        Contacts.People.PRIMARY_PHONE_ID,
-        Contacts.People.TYPE,
-        Contacts.People.NUMBER,
-        Contacts.People.LABEL,
-        Contacts.People.NAME
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete6.java b/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete6.java
deleted file mode 100644
index 3573bfb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/AutoComplete6.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.Spinner;
-import android.widget.ArrayAdapter;
-import android.widget.MultiAutoCompleteTextView;
-import android.os.Bundle;
-import android.view.View;
-
-
-public class AutoComplete6 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.autocomplete_6);
-
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_dropdown_item_1line, COUNTRIES);
-        MultiAutoCompleteTextView textView = (MultiAutoCompleteTextView) findViewById(R.id.edit);
-        textView.setAdapter(adapter);
-        textView.setTokenizer(new MultiAutoCompleteTextView.CommaTokenizer());
-    }
-
-    static final String[] COUNTRIES = new String[] {
-    "Afghanistan", "Albania", "Algeria", "American Samoa", "Andorra",
-    "Angola", "Anguilla", "Antarctica", "Antigua and Barbuda", "Argentina",
-    "Armenia", "Aruba", "Australia", "Austria", "Azerbaijan",
-    "Bahrain", "Bangladesh", "Barbados", "Belarus", "Belgium",
-    "Belize", "Benin", "Bermuda", "Bhutan", "Bolivia",
-    "Bosnia and Herzegovina", "Botswana", "Bouvet Island", "Brazil", "British Indian Ocean Territory",
-    "British Virgin Islands", "Brunei", "Bulgaria", "Burkina Faso", "Burundi",
-    "Cote d'Ivoire", "Cambodia", "Cameroon", "Canada", "Cape Verde",
-    "Cayman Islands", "Central African Republic", "Chad", "Chile", "China",
-    "Christmas Island", "Cocos (Keeling) Islands", "Colombia", "Comoros", "Congo",
-    "Cook Islands", "Costa Rica", "Croatia", "Cuba", "Cyprus", "Czech Republic",
-    "Democratic Republic of the Congo", "Denmark", "Djibouti", "Dominica", "Dominican Republic",
-    "East Timor", "Ecuador", "Egypt", "El Salvador", "Equatorial Guinea", "Eritrea",
-    "Estonia", "Ethiopia", "Faeroe Islands", "Falkland Islands", "Fiji", "Finland",
-    "Former Yugoslav Republic of Macedonia", "France", "French Guiana", "French Polynesia",
-    "French Southern Territories", "Gabon", "Georgia", "Germany", "Ghana", "Gibraltar",
-    "Greece", "Greenland", "Grenada", "Guadeloupe", "Guam", "Guatemala", "Guinea", "Guinea-Bissau",
-    "Guyana", "Haiti", "Heard Island and McDonald Islands", "Honduras", "Hong Kong", "Hungary",
-    "Iceland", "India", "Indonesia", "Iran", "Iraq", "Ireland", "Israel", "Italy", "Jamaica",
-    "Japan", "Jordan", "Kazakhstan", "Kenya", "Kiribati", "Kuwait", "Kyrgyzstan", "Laos",
-    "Latvia", "Lebanon", "Lesotho", "Liberia", "Libya", "Liechtenstein", "Lithuania", "Luxembourg",
-    "Macau", "Madagascar", "Malawi", "Malaysia", "Maldives", "Mali", "Malta", "Marshall Islands",
-    "Martinique", "Mauritania", "Mauritius", "Mayotte", "Mexico", "Micronesia", "Moldova",
-    "Monaco", "Mongolia", "Montserrat", "Morocco", "Mozambique", "Myanmar", "Namibia",
-    "Nauru", "Nepal", "Netherlands", "Netherlands Antilles", "New Caledonia", "New Zealand",
-    "Nicaragua", "Niger", "Nigeria", "Niue", "Norfolk Island", "North Korea", "Northern Marianas",
-    "Norway", "Oman", "Pakistan", "Palau", "Panama", "Papua New Guinea", "Paraguay", "Peru",
-    "Philippines", "Pitcairn Islands", "Poland", "Portugal", "Puerto Rico", "Qatar",
-    "Reunion", "Romania", "Russia", "Rwanda", "Sqo Tome and Principe", "Saint Helena",
-    "Saint Kitts and Nevis", "Saint Lucia", "Saint Pierre and Miquelon",
-    "Saint Vincent and the Grenadines", "Samoa", "San Marino", "Saudi Arabia", "Senegal",
-    "Seychelles", "Sierra Leone", "Singapore", "Slovakia", "Slovenia", "Solomon Islands",
-    "Somalia", "South Africa", "South Georgia and the South Sandwich Islands", "South Korea",
-    "Spain", "Sri Lanka", "Sudan", "Suriname", "Svalbard and Jan Mayen", "Swaziland", "Sweden",
-    "Switzerland", "Syria", "Taiwan", "Tajikistan", "Tanzania", "Thailand", "The Bahamas",
-    "The Gambia", "Togo", "Tokelau", "Tonga", "Trinidad and Tobago", "Tunisia", "Turkey",
-    "Turkmenistan", "Turks and Caicos Islands", "Tuvalu", "Virgin Islands", "Uganda",
-    "Ukraine", "United Arab Emirates", "United Kingdom",
-    "United States", "United States Minor Outlying Islands", "Uruguay", "Uzbekistan",
-    "Vanuatu", "Vatican City", "Venezuela", "Vietnam", "Wallis and Futuna", "Western Sahara",
-    "Yemen", "Yugoslavia", "Zambia", "Zimbabwe"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline1.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline1.java
deleted file mode 100644
index c77b71f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline1.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignment in LinearLayout.
- */
-public class Baseline1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline2.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline2.java
deleted file mode 100644
index 7189fe8..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline2.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignment in LinearLayout with a BOTTOM gravity.
- */
-public class Baseline2 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline3.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline3.java
deleted file mode 100644
index 9261c5c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline3.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignement in LinearLayout with a center_vertical gravity. This sample shows that
- * using a center_vertical gravity disables baseline alignment.
- */
-public class Baseline3 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_3);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline4.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline4.java
deleted file mode 100644
index bedfde7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline4.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignment in LinearLayout with mixed gravities.
- */
-public class Baseline4 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_4);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline6.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline6.java
deleted file mode 100644
index e96e10a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline6.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignment in RelativeLayout.
- */
-public class Baseline6 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_6);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Baseline7.java b/samples/ApiDemos/src/com/example/android/apis/view/Baseline7.java
deleted file mode 100644
index 1795e7d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Baseline7.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Baseline alignment in RelativeLayout with various font weights.
- */
-public class Baseline7 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.baseline_7);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested1.java b/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested1.java
deleted file mode 100644
index d60e702..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested1.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-/**
- * Baseline alignment includes elements within nested vertical
- * {@link android.widget.LinearLayout}s.
- */
-public class BaselineNested1 extends Activity {
-
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.baseline_nested_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested2.java b/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested2.java
deleted file mode 100644
index 32574d7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested2.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-/**
- * Baseline alignment includes an element within a nested horizontal
- * {@link android.widget.LinearLayout}.
- */
-public class BaselineNested2 extends Activity {
-
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.baseline_nested_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested3.java b/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested3.java
deleted file mode 100644
index 3377041..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/BaselineNested3.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-/**
- * Baseline alignment includes a {@link android.widget.LinearLayout}
- * within another {@link android.widget.LinearLayout}.
- */
-public class BaselineNested3 extends Activity {
-
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.baseline_nested_3);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Buttons1.java b/samples/ApiDemos/src/com/example/android/apis/view/Buttons1.java
deleted file mode 100644
index e2f8cc8..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Buttons1.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.Spinner;
-import android.widget.ArrayAdapter;
-
-
-/**
- * A gallery of the different styles of buttons.
- */
-public class Buttons1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.buttons_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ChronometerDemo.java b/samples/ApiDemos/src/com/example/android/apis/view/ChronometerDemo.java
deleted file mode 100644
index 752adc6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ChronometerDemo.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.os.SystemClock;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.Chronometer;
-
-public class ChronometerDemo extends Activity {
-    Chronometer mChronometer;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.chronometer);
-
-        Button button;
-
-        mChronometer = (Chronometer) findViewById(R.id.chronometer);
-
-        // Watch for button clicks.
-        button = (Button) findViewById(R.id.start);
-        button.setOnClickListener(mStartListener);
-
-        button = (Button) findViewById(R.id.stop);
-        button.setOnClickListener(mStopListener);
-
-        button = (Button) findViewById(R.id.reset);
-        button.setOnClickListener(mResetListener);
-
-        button = (Button) findViewById(R.id.set_format);
-        button.setOnClickListener(mSetFormatListener);
-
-        button = (Button) findViewById(R.id.clear_format);
-        button.setOnClickListener(mClearFormatListener);
-    }
-
-    View.OnClickListener mStartListener = new OnClickListener() {
-        public void onClick(View v) {
-            mChronometer.start();
-        }
-    };
-
-    View.OnClickListener mStopListener = new OnClickListener() {
-        public void onClick(View v) {
-            mChronometer.stop();
-        }
-    };
-
-    View.OnClickListener mResetListener = new OnClickListener() {
-        public void onClick(View v) {
-            mChronometer.setBase(SystemClock.elapsedRealtime());
-        }
-    };
-
-    View.OnClickListener mSetFormatListener = new OnClickListener() {
-        public void onClick(View v) {
-            mChronometer.setFormat("Formatted time (%s)");
-        }
-    };
-
-    View.OnClickListener mClearFormatListener = new OnClickListener() {
-        public void onClick(View v) {
-            mChronometer.setFormat(null);
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Controls1.java b/samples/ApiDemos/src/com/example/android/apis/view/Controls1.java
deleted file mode 100644
index e2d348f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Controls1.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.Spinner;
-import android.widget.ArrayAdapter;
-
-
-/**
- * A gallery of basic controls: Button, EditText, RadioButton, Checkbox,
- * Spinner. This example uses the light theme.
- */
-public class Controls1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.controls_1);
-
-        Spinner s1 = (Spinner) findViewById(R.id.spinner1);
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_spinner_item, mStrings);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        s1.setAdapter(adapter);
-    }
-
-    private static final String[] mStrings = {
-        "Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Controls2.java b/samples/ApiDemos/src/com/example/android/apis/view/Controls2.java
deleted file mode 100644
index 4f4024b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Controls2.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.Spinner;
-import android.widget.ArrayAdapter;
-
-
-/**
- * A gallery of basic controls: Button, EditText, RadioButton, Checkbox,
- * Spinner. This example uses the default theme.
- */
-public class Controls2 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.controls_1);
-
-        Spinner s1 = (Spinner) findViewById(R.id.spinner1);
-        ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
-                android.R.layout.simple_spinner_item, mStrings);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        s1.setAdapter(adapter);
-    }
-
-    private static final String[] mStrings = {
-	    "Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/CustomView1.java b/samples/ApiDemos/src/com/example/android/apis/view/CustomView1.java
deleted file mode 100644
index 314738e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/CustomView1.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates creating a Screen that uses custom views. This example uses
- * {@link com.example.android.apis.view.LabelView}, which is defined in
- * SDK/src/com/example/android/apis/view/LabelView.java.
- * 
- */
-public class CustomView1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.custom_view_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets1.java b/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets1.java
deleted file mode 100644
index f0b1d22..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets1.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.DatePickerDialog;
-import android.app.TimePickerDialog;
-import android.app.Dialog;
-import android.os.Bundle;
-import android.widget.TextView;
-import android.widget.Button;
-import android.widget.DatePicker;
-import android.widget.TimePicker;
-import android.view.View;
-
-import java.util.Calendar;
-
-/**
- * Basic example of using date and time widgets, including
- * {@link android.app.TimePickerDialog} and {@link android.widget.DatePicker}.
- *
- * Also provides a good example of using {@link Activity#onCreateDialog},
- * {@link Activity#onPrepareDialog} and {@link Activity#showDialog} to have the
- * activity automatically save and restore the state of the dialogs.
- */
-public class DateWidgets1 extends Activity {
-
-    // where we display the selected date and time
-    private TextView mDateDisplay;
-
-    // date and time
-    private int mYear;
-    private int mMonth;
-    private int mDay;
-    private int mHour;
-    private int mMinute;
-
-    static final int TIME_DIALOG_ID = 0;
-    static final int DATE_DIALOG_ID = 1;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.date_widgets_example_1);
-
-        mDateDisplay = (TextView) findViewById(R.id.dateDisplay);
-
-        Button pickDate = (Button) findViewById(R.id.pickDate);
-        pickDate.setOnClickListener(new View.OnClickListener() {
-
-            public void onClick(View v) {
-                showDialog(DATE_DIALOG_ID);
-            }
-        });
-
-        Button pickTime = (Button) findViewById(R.id.pickTime);
-        pickTime.setOnClickListener(new View.OnClickListener() {
-
-            public void onClick(View v) {
-                showDialog(TIME_DIALOG_ID);
-            }
-        });
-
-        final Calendar c = Calendar.getInstance();
-        mYear = c.get(Calendar.YEAR);
-        mMonth = c.get(Calendar.MONTH);
-        mDay = c.get(Calendar.DAY_OF_MONTH);
-        mHour = c.get(Calendar.HOUR_OF_DAY);
-        mMinute = c.get(Calendar.MINUTE);
-
-        updateDisplay();
-    }
-
-    @Override
-    protected Dialog onCreateDialog(int id) {
-        switch (id) {
-            case TIME_DIALOG_ID:
-                return new TimePickerDialog(this,
-                        mTimeSetListener, mHour, mMinute, false);
-            case DATE_DIALOG_ID:
-                return new DatePickerDialog(this,
-                            mDateSetListener,
-                            mYear, mMonth, mDay);
-        }
-        return null;
-    }
-
-    @Override
-    protected void onPrepareDialog(int id, Dialog dialog) {
-        switch (id) {
-            case TIME_DIALOG_ID:
-                ((TimePickerDialog) dialog).updateTime(mHour, mMinute);
-                break;
-            case DATE_DIALOG_ID:
-                ((DatePickerDialog) dialog).updateDate(mYear, mMonth, mDay);
-                break;
-        }
-    }    
-
-    private void updateDisplay() {
-        mDateDisplay.setText(
-            new StringBuilder()
-                    // Month is 0 based so add 1
-                    .append(mMonth + 1).append("-")
-                    .append(mDay).append("-")
-                    .append(mYear).append(" ")
-                    .append(pad(mHour)).append(":")
-                    .append(pad(mMinute)));
-    }
-
-    private DatePickerDialog.OnDateSetListener mDateSetListener =
-            new DatePickerDialog.OnDateSetListener() {
-
-                public void onDateSet(DatePicker view, int year, int monthOfYear,
-                        int dayOfMonth) {
-                    mYear = year;
-                    mMonth = monthOfYear;
-                    mDay = dayOfMonth;
-                    updateDisplay();
-                }
-            };
-
-    private TimePickerDialog.OnTimeSetListener mTimeSetListener =
-            new TimePickerDialog.OnTimeSetListener() {
-
-                public void onTimeSet(TimePicker view, int hourOfDay, int minute) {
-                    mHour = hourOfDay;
-                    mMinute = minute;
-                    updateDisplay();
-                }
-            };
-
-    private static String pad(int c) {
-        if (c >= 10)
-            return String.valueOf(c);
-        else
-            return "0" + String.valueOf(c);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets2.java b/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets2.java
deleted file mode 100644
index 15123a8..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/DateWidgets2.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.TextView;
-import android.widget.TimePicker;
-import android.os.Bundle;
-
-public class DateWidgets2 extends Activity {
-
-    // where we display the selected date and time
-    private TextView mTimeDisplay;
-
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.date_widgets_example_2);
-
-        TimePicker timePicker = (TimePicker) findViewById(R.id.timePicker);
-        timePicker.setCurrentHour(12);
-        timePicker.setCurrentMinute(15);
-
-        mTimeDisplay = (TextView) findViewById(R.id.dateDisplay);
-
-        updateDisplay(12, 15);
-
-        timePicker.setOnTimeChangedListener(new TimePicker.OnTimeChangedListener() {
-
-            public void onTimeChanged(TimePicker view, int hourOfDay, int minute) {
-                updateDisplay(hourOfDay, minute);
-            }
-        });
-    }
-
-    private void updateDisplay(int hourOfDay, int minute) {
-        mTimeDisplay.setText(
-                    new StringBuilder()
-                    .append(pad(hourOfDay)).append(":")
-                    .append(pad(minute)));
-    }
-
-    private static String pad(int c) {
-        if (c >= 10)
-            return String.valueOf(c);
-        else
-            return "0" + String.valueOf(c);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList1.java b/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList1.java
deleted file mode 100644
index 944db64..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList1.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ExpandableListActivity;
-import android.os.Bundle;
-import android.view.ContextMenu;
-import android.view.Gravity;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.ContextMenu.ContextMenuInfo;
-import android.view.ViewGroup.MarginLayoutParams;
-import android.widget.AbsListView;
-import android.widget.BaseExpandableListAdapter;
-import android.widget.ExpandableListAdapter;
-import android.widget.ExpandableListView;
-import android.widget.TextView;
-import android.widget.Toast;
-import android.widget.ExpandableListView.ExpandableListContextMenuInfo;
-
-import com.example.android.apis.R;
-
-/**
- * Demonstrates expandable lists using a custom {@link ExpandableListAdapter}
- * from {@link BaseExpandableListAdapter}.
- */
-public class ExpandableList1 extends ExpandableListActivity {
-
-    ExpandableListAdapter mAdapter;
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Set up our adapter
-        mAdapter = new MyExpandableListAdapter();
-        setListAdapter(mAdapter);
-        registerForContextMenu(getExpandableListView());
-    }
-
-    @Override
-    public void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo) {
-        menu.setHeaderTitle("Sample menu");
-        menu.add(0, 0, 0, R.string.expandable_list_sample_action);
-    }
-    
-    @Override
-    public boolean onContextItemSelected(MenuItem item) {
-        ExpandableListContextMenuInfo info = (ExpandableListContextMenuInfo) item.getMenuInfo();
-
-        String title = ((TextView) info.targetView).getText().toString();
-        
-        int type = ExpandableListView.getPackedPositionType(info.packedPosition);
-        if (type == ExpandableListView.PACKED_POSITION_TYPE_CHILD) {
-            int groupPos = ExpandableListView.getPackedPositionGroup(info.packedPosition); 
-            int childPos = ExpandableListView.getPackedPositionChild(info.packedPosition); 
-            Toast.makeText(this, title + ": Child " + childPos + " clicked in group " + groupPos,
-                    Toast.LENGTH_SHORT).show();
-            return true;
-        } else if (type == ExpandableListView.PACKED_POSITION_TYPE_GROUP) {
-            int groupPos = ExpandableListView.getPackedPositionGroup(info.packedPosition); 
-            Toast.makeText(this, title + ": Group " + groupPos + " clicked", Toast.LENGTH_SHORT).show();
-            return true;
-        }
-        
-        return false;
-    }
-
-    /**
-     * A simple adapter which maintains an ArrayList of photo resource Ids. 
-     * Each photo is displayed as an image. This adapter supports clearing the
-     * list of photos and adding a new photo.
-     *
-     */
-    public class MyExpandableListAdapter extends BaseExpandableListAdapter {
-        // Sample data set.  children[i] contains the children (String[]) for groups[i].
-        private String[] groups = { "People Names", "Dog Names", "Cat Names", "Fish Names" };
-        private String[][] children = {
-                { "Arnold", "Barry", "Chuck", "David" },
-                { "Ace", "Bandit", "Cha-Cha", "Deuce" },
-                { "Fluffy", "Snuggles" },
-                { "Goldy", "Bubbles" }
-        };
-        
-        public Object getChild(int groupPosition, int childPosition) {
-            return children[groupPosition][childPosition];
-        }
-
-        public long getChildId(int groupPosition, int childPosition) {
-            return childPosition;
-        }
-
-        public int getChildrenCount(int groupPosition) {
-            return children[groupPosition].length;
-        }
-
-        public TextView getGenericView() {
-            // Layout parameters for the ExpandableListView
-            AbsListView.LayoutParams lp = new AbsListView.LayoutParams(
-                    ViewGroup.LayoutParams.FILL_PARENT, 64);
-
-            TextView textView = new TextView(ExpandableList1.this);
-            textView.setLayoutParams(lp);
-            // Center the text vertically
-            textView.setGravity(Gravity.CENTER_VERTICAL | Gravity.LEFT);
-            // Set the text starting position
-            textView.setPadding(36, 0, 0, 0);
-            return textView;
-        }
-        
-        public View getChildView(int groupPosition, int childPosition, boolean isLastChild,
-                View convertView, ViewGroup parent) {
-            TextView textView = getGenericView();
-            textView.setText(getChild(groupPosition, childPosition).toString());
-            return textView;
-        }
-
-        public Object getGroup(int groupPosition) {
-            return groups[groupPosition];
-        }
-
-        public int getGroupCount() {
-            return groups.length;
-        }
-
-        public long getGroupId(int groupPosition) {
-            return groupPosition;
-        }
-
-        public View getGroupView(int groupPosition, boolean isExpanded, View convertView,
-                ViewGroup parent) {
-            TextView textView = getGenericView();
-            textView.setText(getGroup(groupPosition).toString());
-            return textView;
-        }
-
-        public boolean isChildSelectable(int groupPosition, int childPosition) {
-            return true;
-        }
-
-        public boolean hasStableIds() {
-            return true;
-        }
-
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList2.java b/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList2.java
deleted file mode 100644
index 5784122..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList2.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ExpandableListActivity;
-import android.content.ContentUris;
-import android.content.Context;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.Bundle;
-import android.provider.Contacts.People;
-import android.widget.ExpandableListAdapter;
-import android.widget.SimpleCursorTreeAdapter;
-
-
-/**
- * Demonstrates expandable lists backed by Cursors
- */
-public class ExpandableList2 extends ExpandableListActivity {
-    private int mGroupIdColumnIndex; 
-    
-    private String mPhoneNumberProjection[] = new String[] {
-            People.Phones._ID, People.Phones.NUMBER
-    };
-
-    
-    private ExpandableListAdapter mAdapter;
-    
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Query for people
-        Cursor groupCursor = managedQuery(People.CONTENT_URI,
-                new String[] {People._ID, People.NAME}, null, null, null);
-
-        // Cache the ID column index
-        mGroupIdColumnIndex = groupCursor.getColumnIndexOrThrow(People._ID);
-
-        // Set up our adapter
-        mAdapter = new MyExpandableListAdapter(groupCursor,
-                this,
-                android.R.layout.simple_expandable_list_item_1,
-                android.R.layout.simple_expandable_list_item_1,
-                new String[] {People.NAME}, // Name for group layouts
-                new int[] {android.R.id.text1},
-                new String[] {People.NUMBER}, // Number for child layouts
-                new int[] {android.R.id.text1});
-        setListAdapter(mAdapter);
-    }
-
-    public class MyExpandableListAdapter extends SimpleCursorTreeAdapter {
-
-        public MyExpandableListAdapter(Cursor cursor, Context context, int groupLayout,
-                int childLayout, String[] groupFrom, int[] groupTo, String[] childrenFrom,
-                int[] childrenTo) {
-            super(context, cursor, groupLayout, groupFrom, groupTo, childLayout, childrenFrom,
-                    childrenTo);
-        }
-
-        @Override
-        protected Cursor getChildrenCursor(Cursor groupCursor) {
-            // Given the group, we return a cursor for all the children within that group 
-
-            // Return a cursor that points to this contact's phone numbers
-            Uri.Builder builder = People.CONTENT_URI.buildUpon();
-            ContentUris.appendId(builder, groupCursor.getLong(mGroupIdColumnIndex));
-            builder.appendEncodedPath(People.Phones.CONTENT_DIRECTORY);
-            Uri phoneNumbersUri = builder.build();
-
-            // The returned Cursor MUST be managed by us, so we use Activity's helper
-            // functionality to manage it for us.
-            return managedQuery(phoneNumbersUri, mPhoneNumberProjection, null, null, null);
-        }
-
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList3.java b/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList3.java
deleted file mode 100644
index 3a298b3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ExpandableList3.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ExpandableListActivity;
-import android.os.Bundle;
-import android.widget.ExpandableListAdapter;
-import android.widget.SimpleExpandableListAdapter;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * Demonstrates expandable lists backed by a Simple Map-based adapter
- */
-public class ExpandableList3 extends ExpandableListActivity {
-    private static final String NAME = "NAME";
-    private static final String IS_EVEN = "IS_EVEN";
-    
-    private ExpandableListAdapter mAdapter;
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        List<Map<String, String>> groupData = new ArrayList<Map<String, String>>();
-        List<List<Map<String, String>>> childData = new ArrayList<List<Map<String, String>>>();
-        for (int i = 0; i < 20; i++) {
-            Map<String, String> curGroupMap = new HashMap<String, String>();
-            groupData.add(curGroupMap);
-            curGroupMap.put(NAME, "Group " + i);
-            curGroupMap.put(IS_EVEN, (i % 2 == 0) ? "This group is even" : "This group is odd");
-            
-            List<Map<String, String>> children = new ArrayList<Map<String, String>>();
-            for (int j = 0; j < 15; j++) {
-                Map<String, String> curChildMap = new HashMap<String, String>();
-                children.add(curChildMap);
-                curChildMap.put(NAME, "Child " + j);
-                curChildMap.put(IS_EVEN, (j % 2 == 0) ? "This child is even" : "This child is odd");
-            }
-            childData.add(children);
-        }
-        
-        // Set up our adapter
-        mAdapter = new SimpleExpandableListAdapter(
-                this,
-                groupData,
-                android.R.layout.simple_expandable_list_item_1,
-                new String[] { NAME, IS_EVEN },
-                new int[] { android.R.id.text1, android.R.id.text2 },
-                childData,
-                android.R.layout.simple_expandable_list_item_2,
-                new String[] { NAME, IS_EVEN },
-                new int[] { android.R.id.text1, android.R.id.text2 }
-                );
-        setListAdapter(mAdapter);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Focus1.java b/samples/ApiDemos/src/com/example/android/apis/view/Focus1.java
deleted file mode 100644
index 86f6ee7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Focus1.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.webkit.WebView;
-import android.widget.ListView;
-import android.widget.ArrayAdapter;
-
-
-/**
- * Demonstrates the use of non-focusable views.
- */
-public class Focus1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.focus_1);
-
-        WebView webView = (WebView) findViewById(R.id.rssWebView);
-        webView.loadData(
-                        "<html><body>Can I focus?<br /><a href=\"#\">No I cannot!</a>.</body></html>",
-                        "text/html", "utf-8");
-
-        ListView listView = (ListView) findViewById(R.id.rssListView);
-        listView.setAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, 
-                new String[] {"Ars Technica", "Slashdot", "GameKult"}));
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Focus2.java b/samples/ApiDemos/src/com/example/android/apis/view/Focus2.java
deleted file mode 100644
index 77bf8e0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Focus2.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class Focus2 extends Activity {
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.focus_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Focus3.java b/samples/ApiDemos/src/com/example/android/apis/view/Focus3.java
deleted file mode 100644
index fc3f6df..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Focus3.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.Button;
-import com.example.android.apis.R;
-
-public class Focus3 extends Activity {
-    private Button mTopButton;
-    private Button mBottomButton;
-
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.focus_3);
-
-        mTopButton = (Button) findViewById(R.id.top);
-        mBottomButton = (Button) findViewById(R.id.bottom);
-    }
-
-    public Button getTopButton() {
-        return mTopButton;
-    }
-
-    public Button getBottomButton() {
-        return mBottomButton;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Gallery1.java b/samples/ApiDemos/src/com/example/android/apis/view/Gallery1.java
deleted file mode 100644
index a539a5b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Gallery1.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.os.Bundle;
-import android.view.ContextMenu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.ContextMenu.ContextMenuInfo;
-import android.widget.AdapterView;
-import android.widget.BaseAdapter;
-import android.widget.Gallery;
-import android.widget.ImageView;
-import android.widget.Toast;
-import android.widget.AdapterView.AdapterContextMenuInfo;
-import android.widget.AdapterView.OnItemClickListener;
-
-public class Gallery1 extends Activity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.gallery_1);
-
-        // Reference the Gallery view
-        Gallery g = (Gallery) findViewById(R.id.gallery);
-        // Set the adapter to our custom adapter (below)
-        g.setAdapter(new ImageAdapter(this));
-        
-        // Set a item click listener, and just Toast the clicked position
-        g.setOnItemClickListener(new OnItemClickListener() {
-            public void onItemClick(AdapterView parent, View v, int position, long id) {
-                Toast.makeText(Gallery1.this, "" + position, Toast.LENGTH_SHORT).show();
-            }
-        });
-        
-        // We also want to show context menu for longpressed items in the gallery
-        registerForContextMenu(g);
-    }
-
-    @Override
-    public void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo) {
-        menu.add(R.string.gallery_2_text);
-    }
-    
-    @Override
-    public boolean onContextItemSelected(MenuItem item) {
-        AdapterContextMenuInfo info = (AdapterContextMenuInfo) item.getMenuInfo();
-        Toast.makeText(this, "Longpress: " + info.position, Toast.LENGTH_SHORT).show();
-        return true;
-    }
-
-    public class ImageAdapter extends BaseAdapter {
-        int mGalleryItemBackground;
-        
-        public ImageAdapter(Context c) {
-            mContext = c;
-            // See res/values/attrs.xml for the <declare-styleable> that defines
-            // Gallery1.
-            TypedArray a = obtainStyledAttributes(R.styleable.Gallery1);
-            mGalleryItemBackground = a.getResourceId(
-                    R.styleable.Gallery1_android_galleryItemBackground, 0);
-            a.recycle();
-        }
-
-        public int getCount() {
-            return mImageIds.length;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(mContext);
-
-            i.setImageResource(mImageIds[position]);
-            i.setScaleType(ImageView.ScaleType.FIT_XY);
-            i.setLayoutParams(new Gallery.LayoutParams(136, 88));
-            
-            // The preferred Gallery item background
-            i.setBackgroundResource(mGalleryItemBackground);
-            
-            return i;
-        }
-
-        private Context mContext;
-
-        private Integer[] mImageIds = {
-                R.drawable.gallery_photo_1,
-                R.drawable.gallery_photo_2,
-                R.drawable.gallery_photo_3,
-                R.drawable.gallery_photo_4,
-                R.drawable.gallery_photo_5,
-                R.drawable.gallery_photo_6,
-                R.drawable.gallery_photo_7,
-                R.drawable.gallery_photo_8
-        };
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Gallery2.java b/samples/ApiDemos/src/com/example/android/apis/view/Gallery2.java
deleted file mode 100644
index 2eea1ff..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Gallery2.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.content.Context;
-import android.database.Cursor;
-import android.provider.Contacts.People;
-import android.os.Bundle;
-import android.widget.Gallery;
-import android.widget.SimpleCursorAdapter;
-import android.widget.SpinnerAdapter;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-public class Gallery2 extends Activity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.gallery_2);
-
-        // Get a cursor with all people
-        Cursor c = getContentResolver().query(People.CONTENT_URI, null, null, null, null);
-        startManagingCursor(c);
-        
-        SpinnerAdapter adapter = new SimpleCursorAdapter(this,
-        // Use a template that displays a text view
-                android.R.layout.simple_gallery_item,
-                // Give the cursor to the list adatper
-                c,
-                // Map the NAME column in the people database to...
-                new String[] {People.NAME},
-                // The "text1" view defined in the XML template
-                new int[] { android.R.id.text1 });
-
-        Gallery g = (Gallery) findViewById(R.id.gallery);
-        g.setAdapter(adapter);
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Grid1.java b/samples/ApiDemos/src/com/example/android/apis/view/Grid1.java
deleted file mode 100644
index d52d4f5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Grid1.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-//Need the following import to get access to the app resources, since this
-//class is in a sub-package.
-import com.example.android.apis.R;
-
-
-public class Grid1 extends Activity {
-
-    GridView mGrid;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        loadApps(); // do this in onresume?
-
-        setContentView(R.layout.grid_1);
-        mGrid = (GridView) findViewById(R.id.myGrid);
-        mGrid.setAdapter(new AppsAdapter());
-    }
-
-    private List<ResolveInfo> mApps;
-
-    private void loadApps() {
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        mApps = getPackageManager().queryIntentActivities(mainIntent, 0);
-    }
-
-    public class AppsAdapter extends BaseAdapter {
-        public AppsAdapter() {
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i;
-
-            if (convertView == null) {
-                i = new ImageView(Grid1.this);
-                i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-                i.setLayoutParams(new GridView.LayoutParams(50, 50));
-            } else {
-                i = (ImageView) convertView;
-            }
-
-            ResolveInfo info = mApps.get(position);
-            i.setImageDrawable(info.activityInfo.loadIcon(getPackageManager()));
-
-            return i;
-        }
-
-
-        public final int getCount() {
-            return mApps.size();
-        }
-
-        public final Object getItem(int position) {
-            return mApps.get(position);
-        }
-
-        public final long getItemId(int position) {
-            return position;
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Grid2.java b/samples/ApiDemos/src/com/example/android/apis/view/Grid2.java
deleted file mode 100644
index 916eccb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Grid2.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-/**
- * A grid that displays a set of framed photos.
- *
- */
-public class Grid2 extends Activity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.grid_2);
-
-        GridView g = (GridView) findViewById(R.id.myGrid);
-        g.setAdapter(new ImageAdapter(this));
-    }
-
-    public class ImageAdapter extends BaseAdapter {
-        public ImageAdapter(Context c) {
-            mContext = c;
-        }
-
-        public int getCount() {
-            return mThumbIds.length;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView imageView;
-            if (convertView == null) {
-                imageView = new ImageView(mContext);
-                imageView.setLayoutParams(new GridView.LayoutParams(45, 45));
-                imageView.setAdjustViewBounds(false);
-                imageView.setScaleType(ImageView.ScaleType.CENTER_CROP);
-                imageView.setPadding(8, 8, 8, 8);
-            } else {
-                imageView = (ImageView) convertView;
-            }
-
-            imageView.setImageResource(mThumbIds[position]);
-
-            return imageView;
-        }
-
-        private Context mContext;
-
-        private Integer[] mThumbIds = {
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-                R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-                R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7,
-        };
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ImageButton1.java b/samples/ApiDemos/src/com/example/android/apis/view/ImageButton1.java
deleted file mode 100644
index 5d1fb19..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ImageButton1.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-import com.example.android.apis.R;
-
-
-public class ImageButton1 extends Activity {
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.image_button_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ImageSwitcher1.java b/samples/ApiDemos/src/com/example/android/apis/view/ImageSwitcher1.java
deleted file mode 100644
index f72b623..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ImageSwitcher1.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.Window;
-import android.view.animation.AnimationUtils;
-import android.widget.AdapterView;
-import android.widget.BaseAdapter;
-import android.widget.Gallery;
-import android.widget.Gallery.LayoutParams;
-import android.widget.ImageSwitcher;
-import android.widget.ImageView;
-import android.widget.ViewSwitcher;
-
-
-public class ImageSwitcher1 extends Activity implements
-        AdapterView.OnItemSelectedListener, ViewSwitcher.ViewFactory {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-
-        setContentView(R.layout.image_switcher_1);
-
-        mSwitcher = (ImageSwitcher) findViewById(R.id.switcher);
-        mSwitcher.setFactory(this);
-        mSwitcher.setInAnimation(AnimationUtils.loadAnimation(this,
-                android.R.anim.fade_in));
-        mSwitcher.setOutAnimation(AnimationUtils.loadAnimation(this,
-                android.R.anim.fade_out));
-
-        Gallery g = (Gallery) findViewById(R.id.gallery);
-        g.setAdapter(new ImageAdapter(this));
-        g.setOnItemSelectedListener(this);
-    }
-
-    public void onItemSelected(AdapterView parent, View v, int position, long id) {
-        mSwitcher.setImageResource(mImageIds[position]);
-    }
-
-    public void onNothingSelected(AdapterView parent) {
-    }
-
-    public View makeView() {
-        ImageView i = new ImageView(this);
-        i.setBackgroundColor(0xFF000000);
-        i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-        i.setLayoutParams(new ImageSwitcher.LayoutParams(LayoutParams.FILL_PARENT,
-                LayoutParams.FILL_PARENT));
-        return i;
-    }
-
-    private ImageSwitcher mSwitcher;
-
-    public class ImageAdapter extends BaseAdapter {
-        public ImageAdapter(Context c) {
-            mContext = c;
-        }
-
-        public int getCount() {
-            return mThumbIds.length;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(mContext);
-
-            i.setImageResource(mThumbIds[position]);
-            i.setAdjustViewBounds(true);
-            i.setLayoutParams(new Gallery.LayoutParams(
-                    LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
-            i.setBackgroundResource(R.drawable.picture_frame);
-            return i;
-        }
-
-        private Context mContext;
-
-    }
-
-    private Integer[] mThumbIds = {
-            R.drawable.sample_thumb_0, R.drawable.sample_thumb_1,
-            R.drawable.sample_thumb_2, R.drawable.sample_thumb_3,
-            R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-            R.drawable.sample_thumb_6, R.drawable.sample_thumb_7};
-
-    private Integer[] mImageIds = {
-            R.drawable.sample_0, R.drawable.sample_1, R.drawable.sample_2,
-            R.drawable.sample_3, R.drawable.sample_4, R.drawable.sample_5,
-            R.drawable.sample_6, R.drawable.sample_7};
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ImageView1.java b/samples/ApiDemos/src/com/example/android/apis/view/ImageView1.java
deleted file mode 100644
index f63b01a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ImageView1.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-import com.example.android.apis.R;
-
-
-/**
- * Demonstrates setting size constraints on {@link android.widget.ImageView}
- *
- */
-public class ImageView1 extends Activity {
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.image_view_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionFocus.java b/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionFocus.java
deleted file mode 100644
index a664ab9..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionFocus.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.ViewGroup;
-import android.widget.LinearLayout;
-
-/**
- * {@link android.view.View#requestFocus(int, android.graphics.Rect)}
- * and
- * {@link android.view.View#onFocusChanged(boolean, int, android.graphics.Rect)}
- * work together to give a newly focused item a hint about the most interesting
- * rectangle of the previously focused view.  The view taking focus can use this
- * to set an internal selection more appropriate using this rect.
- *
- * This Activity excercises that behavior using three adjacent {@link InternalSelectionView}
- * that report interesting rects when giving up focus, and use interesting rects
- * when taking focus to best select the internal row to show as selected.
- *
- * Were {@link InternalSelectionView} not to override {@link android.view.View#getFocusedRect}, or
- * {@link android.view.View#onFocusChanged(boolean, int, android.graphics.Rect)}, the focus would
- * jump to some default internal selection (the top) and not allow for the smooth handoff.
- */
-public class InternalSelectionFocus extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        final LinearLayout layout = new LinearLayout(this);
-        layout.setOrientation(LinearLayout.HORIZONTAL);
-        layout.setLayoutParams(new ViewGroup.LayoutParams(
-                ViewGroup.LayoutParams.FILL_PARENT,
-                ViewGroup.LayoutParams.FILL_PARENT));
-
-        LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(0,
-                ViewGroup.LayoutParams.FILL_PARENT, 1);
-
-        final InternalSelectionView leftColumn = new InternalSelectionView(this, 5, "left column");
-        leftColumn.setLayoutParams(params);
-        leftColumn.setPadding(10, 10, 10, 10);
-        layout.addView(leftColumn);
-
-        final InternalSelectionView middleColumn = new InternalSelectionView(this, 5, "middle column");
-        middleColumn.setLayoutParams(params);
-        middleColumn.setPadding(10, 10, 10, 10);
-        layout.addView(middleColumn);
-
-        final InternalSelectionView rightColumn = new InternalSelectionView(this, 5, "right column");
-        rightColumn.setLayoutParams(params);
-        rightColumn.setPadding(10, 10, 10, 10);
-        layout.addView(rightColumn);
-
-        setContentView(layout);
-    }
-
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionScroll.java b/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionScroll.java
deleted file mode 100644
index fe607e2..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionScroll.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.ViewGroup;
-import android.widget.LinearLayout;
-import android.widget.ScrollView;
-
-/**
- * Demonstrates how a well behaved view with internal selection
- * ({@link InternalSelectionView}) can cause its parent {@link android.widget.ScrollView}
- * to scroll to keep the internally interesting rectangle on the screen.
- *
- * {@link InternalSelectionView} achieves this by calling {@link android.view.View#requestRectangleOnScreen}
- * each time its internal selection changes.
- *
- * {@link android.widget.ScrollView}, in turn, implements {@link android.view.View#requestRectangleOnScreen}
- * thereby acheiving the result.  Note that {@link android.widget.ListView} also implements the
- * method, so views that call {@link android.view.View#requestRectangleOnScreen} that are embedded
- * within either {@link android.widget.ScrollView}s or {@link android.widget.ListView}s can
- * expect to keep their internal interesting rectangle visible.
- */
-public class InternalSelectionScroll extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        ScrollView sv = new ScrollView(this);
-        ViewGroup.LayoutParams svLp = new ScrollView.LayoutParams(
-                ViewGroup.LayoutParams.FILL_PARENT,
-                ViewGroup.LayoutParams.WRAP_CONTENT);
-
-        LinearLayout ll = new LinearLayout(this);
-        ll.setLayoutParams(svLp);
-        sv.addView(ll);
-
-        InternalSelectionView isv = new InternalSelectionView(this, 10);
-        int screenHeight = getWindowManager().getDefaultDisplay().getHeight();
-        LinearLayout.LayoutParams llLp = new LinearLayout.LayoutParams(
-                ViewGroup.LayoutParams.FILL_PARENT,
-                2 * screenHeight);  // 2x screen height to ensure scrolling
-        isv.setLayoutParams(llLp);
-        ll.addView(isv);
-        
-        setContentView(sv);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionView.java b/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionView.java
deleted file mode 100644
index 3ef8403..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/InternalSelectionView.java
+++ /dev/null
@@ -1,271 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.content.Context;
-import android.graphics.Canvas;
-import android.graphics.Color;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.util.AttributeSet;
-import android.view.KeyEvent;
-import android.view.View;
-
-
-
-/**
- * A view that has a known number of selectable rows, and maintains a notion of which
- * row is selected. The rows take up the
- * entire width of the view.  The height of the view is divided evenly among
- * the rows.
- *
- * Notice what this view does to be a good citizen w.r.t its internal selection:
- * 1) calls {@link View#requestRectangleOnScreen} each time the selection changes due to
- *    internal navigation.
- * 2) overrides {@link View#getFocusedRect} by filling in the rectangle of the currently
- *    selected row
- * 3) overrides {@link View#onFocusChanged} and sets selection appropriately according to
- *    the previously focused rectangle.
- */
-public class InternalSelectionView extends View {
-
-    private Paint mPainter = new Paint();
-    private Paint mTextPaint = new Paint();
-    private Rect mTempRect = new Rect();
-
-    private int mNumRows = 5;
-    private int mSelectedRow = 0;
-    private final int mEstimatedPixelHeight = 10;
-
-    private Integer mDesiredHeight = null;
-    private String mLabel = null;
-
-
-    public InternalSelectionView(Context context, int numRows) {
-        this(context, numRows, "");
-    }
-    
-    public InternalSelectionView(Context context, int numRows, String label) {
-        super(context);
-        mNumRows = numRows;
-        mLabel = label;
-        init();
-    }
-
-    public InternalSelectionView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        init();
-    }
-
-    private void init() {
-        setFocusable(true);
-        mTextPaint.setAntiAlias(true);
-        mTextPaint.setTextSize(10);
-        mTextPaint.setColor(Color.WHITE);
-    }
-
-    public int getNumRows() {
-        return mNumRows;
-    }
-
-    public int getSelectedRow() {
-        return mSelectedRow;
-    }
-
-    public void setDesiredHeight(int desiredHeight) {
-        mDesiredHeight = desiredHeight;
-    }
-
-    public String getLabel() {
-        return mLabel;
-    }
-
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        setMeasuredDimension(
-            measureWidth(widthMeasureSpec),
-            measureHeight(heightMeasureSpec));
-    }
-
-    private int measureWidth(int measureSpec) {
-        int specMode = MeasureSpec.getMode(measureSpec);
-        int specSize = MeasureSpec.getSize(measureSpec);
-
-        int desiredWidth = 300 + getPaddingLeft() + getPaddingRight();
-        if (specMode == MeasureSpec.EXACTLY) {
-            // We were told how big to be
-            return specSize;
-        } else if (specMode == MeasureSpec.AT_MOST) {
-            return desiredWidth < specSize ? desiredWidth : specSize;
-        } else {
-            return desiredWidth;
-        }
-    }
-
-    private int measureHeight(int measureSpec) {
-        int specMode = MeasureSpec.getMode(measureSpec);
-        int specSize = MeasureSpec.getSize(measureSpec);
-
-        int desiredHeight = mDesiredHeight != null ?
-                mDesiredHeight :
-                mNumRows * mEstimatedPixelHeight + getPaddingTop() + getPaddingBottom();
-        if (specMode == MeasureSpec.EXACTLY) {
-            // We were told how big to be
-            return specSize;
-        } else if (specMode == MeasureSpec.AT_MOST) {
-            return desiredHeight < specSize ? desiredHeight : specSize;
-        } else {
-            return desiredHeight;
-        }
-    }
-
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-
-        int rowHeight = getRowHeight();
-
-        int rectTop = getPaddingTop();
-        int rectLeft = getPaddingLeft();
-        int rectRight = getWidth() - getPaddingRight();
-        for (int i = 0; i < mNumRows; i++) {
-
-            mPainter.setColor(Color.BLACK);
-            mPainter.setAlpha(0x20);
-
-            // draw background rect
-            mTempRect.set(rectLeft, rectTop, rectRight, rectTop + rowHeight);
-            canvas.drawRect(mTempRect, mPainter);
-
-            // draw forground rect
-            if (i == mSelectedRow && hasFocus()) {
-                mPainter.setColor(Color.RED);
-                mPainter.setAlpha(0xF0);
-                mTextPaint.setAlpha(0xFF);
-            } else {
-                mPainter.setColor(Color.BLACK);
-                mPainter.setAlpha(0x40);
-                mTextPaint.setAlpha(0xF0);
-            }
-            mTempRect.set(rectLeft + 2, rectTop + 2,
-                    rectRight - 2, rectTop + rowHeight - 2);
-            canvas.drawRect(mTempRect, mPainter);
-
-            // draw text to help when visually inspecting
-            canvas.drawText(
-                    Integer.toString(i),
-                    rectLeft + 2,
-                    rectTop + 2 - (int) mTextPaint.ascent(),
-                    mTextPaint);
-
-            rectTop += rowHeight;
-        }
-    }
-
-    private int getRowHeight() {
-        return (getHeight() - getPaddingTop() - getPaddingBottom()) / mNumRows;
-    }
-
-    public void getRectForRow(Rect rect, int row) {
-        final int rowHeight = getRowHeight();
-        final int top = getPaddingTop() + row * rowHeight;
-        rect.set(getPaddingLeft(),
-                top,
-                getWidth() - getPaddingRight(),
-                top + rowHeight);
-    }
-
-
-    void ensureRectVisible() {
-        getRectForRow(mTempRect, mSelectedRow);
-        requestRectangleOnScreen(mTempRect);
-    }
-
-
-    /* (non-Javadoc)
-    * @see android.view.KeyEvent.Callback#onKeyDown(int, android.view.KeyEvent)
-    */
-    public boolean onKeyDown(int keyCode, KeyEvent event) {
-        switch(event.getKeyCode()) {
-            case KeyEvent.KEYCODE_DPAD_UP:
-                if (mSelectedRow > 0) {
-                    mSelectedRow--;
-                    invalidate();
-                    ensureRectVisible();
-                    return true;
-                }
-                break;
-            case KeyEvent.KEYCODE_DPAD_DOWN:
-                if (mSelectedRow < (mNumRows - 1)) {
-                    mSelectedRow++;
-                    invalidate();
-                    ensureRectVisible();
-                    return true;
-                }
-                break;
-        }
-        return false;
-    }
-
-
-    @Override
-    public void getFocusedRect(Rect r) {
-        getRectForRow(r, mSelectedRow);
-    }
-
-    @Override
-    protected void onFocusChanged(boolean focused, int direction,
-            Rect previouslyFocusedRect) {
-        super.onFocusChanged(focused, direction, previouslyFocusedRect);
-
-        if (focused) {
-            switch (direction) {
-                case View.FOCUS_DOWN:
-                    mSelectedRow = 0;
-                    break;
-                case View.FOCUS_UP:
-                    mSelectedRow = mNumRows - 1;
-                    break;
-                case View.FOCUS_LEFT:  // fall through
-                case View.FOCUS_RIGHT:
-                    // set the row that is closest to the rect
-                    if (previouslyFocusedRect != null) {
-                        int y = previouslyFocusedRect.top
-                                + (previouslyFocusedRect.height() / 2);
-                        int yPerRow = getHeight() / mNumRows;
-                        mSelectedRow = y / yPerRow;
-                    } else {
-                        mSelectedRow = 0;
-                    }
-                    break;
-                default:
-                    // can't gleam any useful information about what internal
-                    // selection should be...
-                    return;
-            }
-            invalidate();
-        }
-    }
-
-    @Override
-    public String toString() {
-        if (mLabel != null) {
-            return mLabel;
-        }
-        return super.toString();
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LabelView.java b/samples/ApiDemos/src/com/example/android/apis/view/LabelView.java
deleted file mode 100644
index b98a5b5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LabelView.java
+++ /dev/null
@@ -1,192 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.util.AttributeSet;
-import android.view.View;
-
-import com.example.android.apis.R;
-
-
-/**
- * Example of how to write a custom subclass of View. LabelView
- * is used to draw simple text views. Note that it does not handle
- * styled text or right-to-left writing systems.
- *
- */
-public class LabelView extends View {
-    private Paint mTextPaint;
-    private String mText;
-    private int mAscent;
-    
-    /**
-     * Constructor.  This version is only needed if you will be instantiating
-     * the object manually (not from a layout XML file).
-     * @param context
-     */
-    public LabelView(Context context) {
-        super(context);
-        initLabelView();
-    }
-
-    /**
-     * Construct object, initializing with any attributes we understand from a
-     * layout file. These attributes are defined in
-     * SDK/assets/res/any/classes.xml.
-     * 
-     * @see android.view.View#View(android.content.Context, android.util.AttributeSet)
-     */
-    public LabelView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        initLabelView();
-
-        TypedArray a = context.obtainStyledAttributes(attrs,
-                R.styleable.LabelView);
-
-        CharSequence s = a.getString(R.styleable.LabelView_text);
-        if (s != null) {
-            setText(s.toString());
-        }
-
-        // Retrieve the color(s) to be used for this view and apply them.
-        // Note, if you only care about supporting a single color, that you
-        // can instead call a.getColor() and pass that to setTextColor().
-        setTextColor(a.getColor(R.styleable.LabelView_textColor, 0xFF000000));
-
-        int textSize = a.getDimensionPixelOffset(R.styleable.LabelView_textSize, 0);
-        if (textSize > 0) {
-            setTextSize(textSize);
-        }
-
-        a.recycle();
-    }
-
-    private final void initLabelView() {
-        mTextPaint = new Paint();
-        mTextPaint.setAntiAlias(true);
-        mTextPaint.setTextSize(16);
-        mTextPaint.setColor(0xFF000000);
-        setPadding(3, 3, 3, 3);
-    }
-
-    /**
-     * Sets the text to display in this label
-     * @param text The text to display. This will be drawn as one line.
-     */
-    public void setText(String text) {
-        mText = text;
-        requestLayout();
-        invalidate();
-    }
-
-    /**
-     * Sets the text size for this label
-     * @param size Font size
-     */
-    public void setTextSize(int size) {
-        mTextPaint.setTextSize(size);
-        requestLayout();
-        invalidate();
-    }
-
-    /**
-     * Sets the text color for this label.
-     * @param color ARGB value for the text
-     */
-    public void setTextColor(int color) {
-        mTextPaint.setColor(color);
-        invalidate();
-    }
-
-    /**
-     * @see android.view.View#measure(int, int)
-     */
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        setMeasuredDimension(measureWidth(widthMeasureSpec),
-                measureHeight(heightMeasureSpec));
-    }
-
-    /**
-     * Determines the width of this view
-     * @param measureSpec A measureSpec packed into an int
-     * @return The width of the view, honoring constraints from measureSpec
-     */
-    private int measureWidth(int measureSpec) {
-        int result = 0;
-        int specMode = MeasureSpec.getMode(measureSpec);
-        int specSize = MeasureSpec.getSize(measureSpec);
-
-        if (specMode == MeasureSpec.EXACTLY) {
-            // We were told how big to be
-            result = specSize;
-        } else {
-            // Measure the text
-            result = (int) mTextPaint.measureText(mText) + getPaddingLeft()
-                    + getPaddingRight();
-            if (specMode == MeasureSpec.AT_MOST) {
-                // Respect AT_MOST value if that was what is called for by measureSpec
-                result = Math.min(result, specSize);
-            }
-        }
-
-        return result;
-    }
-
-    /**
-     * Determines the height of this view
-     * @param measureSpec A measureSpec packed into an int
-     * @return The height of the view, honoring constraints from measureSpec
-     */
-    private int measureHeight(int measureSpec) {
-        int result = 0;
-        int specMode = MeasureSpec.getMode(measureSpec);
-        int specSize = MeasureSpec.getSize(measureSpec);
-
-        mAscent = (int) mTextPaint.ascent();
-        if (specMode == MeasureSpec.EXACTLY) {
-            // We were told how big to be
-            result = specSize;
-        } else {
-            // Measure the text (beware: ascent is a negative number)
-            result = (int) (-mAscent + mTextPaint.descent()) + getPaddingTop()
-                    + getPaddingBottom();
-            if (specMode == MeasureSpec.AT_MOST) {
-                // Respect AT_MOST value if that was what is called for by measureSpec
-                result = Math.min(result, specSize);
-            }
-        }
-        return result;
-    }
-
-    /**
-     * Render the text
-     * 
-     * @see android.view.View#onDraw(android.graphics.Canvas)
-     */
-    @Override
-    protected void onDraw(Canvas canvas) {
-        super.onDraw(canvas);
-        canvas.drawText(mText, getPaddingLeft(), getPaddingTop() - mAscent, mTextPaint);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation1.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation1.java
deleted file mode 100644
index 19e1834..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation1.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-public class LayoutAnimation1 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        loadApps();
-
-        setContentView(R.layout.layout_animation_1);
-        GridView grid = (GridView) findViewById(R.id.grid);
-        grid.setAdapter(new LayoutAnimation1.AppsAdapter());
-    }
-
-    private List<ResolveInfo> mApps;
-
-    private void loadApps() {
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        mApps = getPackageManager().queryIntentActivities(mainIntent, 0);
-    }
-
-    public class AppsAdapter extends BaseAdapter {
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(LayoutAnimation1.this);
-
-            ResolveInfo info = mApps.get(position % mApps.size());
-
-            i.setImageDrawable(info.activityInfo.loadIcon(getPackageManager()));
-            i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-            i.setLayoutParams(new GridView.LayoutParams(36, 36));
-            return i;
-        }
-
-
-        public final int getCount() {
-            return Math.min(32, mApps.size());
-        }
-
-        public final Object getItem(int position) {
-            return mApps.get(position % mApps.size());
-        }
-
-        public final long getItemId(int position) {
-            return position;
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation2.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation2.java
deleted file mode 100644
index 1c00145..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation2.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.animation.AlphaAnimation;
-import android.view.animation.Animation;
-import android.view.animation.AnimationSet;
-import android.view.animation.LayoutAnimationController;
-import android.view.animation.TranslateAnimation;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-
-public class LayoutAnimation2 extends ListActivity {
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, mStrings));
-
-        AnimationSet set = new AnimationSet(true);
-
-        Animation animation = new AlphaAnimation(0.0f, 1.0f);
-        animation.setDuration(50);
-        set.addAnimation(animation);
-
-        animation = new TranslateAnimation(
-            Animation.RELATIVE_TO_SELF, 0.0f,Animation.RELATIVE_TO_SELF, 0.0f,
-            Animation.RELATIVE_TO_SELF, -1.0f,Animation.RELATIVE_TO_SELF, 0.0f
-        );
-        animation.setDuration(100);
-        set.addAnimation(animation);
-
-        LayoutAnimationController controller =
-                new LayoutAnimationController(set, 0.5f);
-        ListView listView = getListView();        
-        listView.setLayoutAnimation(controller);
-    }
-
-    private String[] mStrings = {
-        "Bordeaux",
-        "Lyon",
-        "Marseille",
-        "Nancy",
-        "Paris",
-        "Toulouse",
-        "Strasbourg"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation3.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation3.java
deleted file mode 100644
index edc2926..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation3.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.ListActivity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-import android.view.View;
-
-public class LayoutAnimation3 extends ListActivity {
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.layout_animation_3);
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, mStrings));
-    }
-
-    private String[] mStrings = {
-        "Bordeaux",
-        "Lyon",
-        "Marseille",
-        "Nancy",
-        "Paris",
-        "Toulouse",
-        "Strasbourg"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation4.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation4.java
deleted file mode 100644
index 73b338b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation4.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-public class LayoutAnimation4 extends Activity {
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        loadApps();
-
-        setContentView(R.layout.layout_animation_4);
-        GridView grid = (GridView) findViewById(R.id.grid);
-        grid.setAdapter(new AppsAdapter());
-
-    }
-
-    private List<ResolveInfo> mApps;
-
-    private void loadApps() {
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        mApps = getPackageManager().queryIntentActivities(mainIntent, 0);
-    }
-
-    public class AppsAdapter extends BaseAdapter {
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(LayoutAnimation4.this);
-
-            ResolveInfo info = mApps.get(position % mApps.size());
-
-            i.setImageDrawable(info.activityInfo.loadIcon(getPackageManager()));
-            i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-            i.setLayoutParams(new GridView.LayoutParams(36, 36));
-            return i;
-        }
-
-
-        public final int getCount() {
-            return Math.min(32, mApps.size());
-        }
-
-        public final Object getItem(int position) {
-            return mApps.get(position % mApps.size());
-        }
-
-        public final long getItemId(int position) {
-            return position;
-        }
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation5.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation5.java
deleted file mode 100644
index 8ed8a36..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation5.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.Gallery;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-public class LayoutAnimation5 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        loadApps();
-
-        setContentView(R.layout.layout_animation_5);
-        GridView grid = (GridView) findViewById(R.id.grid);
-        grid.setAdapter(new AppsAdapter());
-    }
-
-    private List<ResolveInfo> mApps;
-
-    private void loadApps() {
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        mApps = getPackageManager().queryIntentActivities(mainIntent, 0);
-    }
-
-    public class AppsAdapter extends BaseAdapter {
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(LayoutAnimation5.this);
-
-            ResolveInfo info = mApps.get(position % mApps.size());
-
-            i.setImageDrawable(info.activityInfo.loadIcon(getPackageManager()));
-            i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-            i.setLayoutParams(new GridView.LayoutParams(36, 36));
-            return i;
-        }
-
-
-        public final int getCount() {
-            return Math.min(32, mApps.size());
-        }
-
-        public final Object getItem(int position) {
-            return mApps.get(position % mApps.size());
-        }
-
-        public final long getItemId(int position) {
-            return position;
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation6.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation6.java
deleted file mode 100644
index ef7917e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation6.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.ResolveInfo;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-public class LayoutAnimation6 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        loadApps();
-
-        setContentView(R.layout.layout_animation_6);
-        GridView grid = (GridView) findViewById(R.id.grid);
-        grid.setAdapter(new AppsAdapter());
-    }
-
-    private List<ResolveInfo> mApps;
-
-    private void loadApps() {
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        mApps = getPackageManager().queryIntentActivities(mainIntent, 0);
-    }
-
-    public class AppsAdapter extends BaseAdapter {
-        public View getView(int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(LayoutAnimation6.this);
-
-            ResolveInfo info = mApps.get(position % mApps.size());
-
-            i.setImageDrawable(info.activityInfo.loadIcon(getPackageManager()));
-            i.setScaleType(ImageView.ScaleType.FIT_CENTER);
-            i.setLayoutParams(new GridView.LayoutParams(36, 36));
-            return i;
-        }
-
-
-        public final int getCount() {
-            return Math.min(32, mApps.size());
-        }
-
-        public final Object getItem(int position) {
-            return mApps.get(position % mApps.size());
-        }
-
-        public final long getItemId(int position) {
-            return position;
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation7.java b/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation7.java
deleted file mode 100644
index 6eeb429..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LayoutAnimation7.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.animation.AlphaAnimation;
-import android.view.animation.Animation;
-import android.view.animation.GridLayoutAnimationController;
-import android.widget.BaseAdapter;
-import android.widget.Gallery;
-import android.widget.GridView;
-import android.widget.ImageView;
-
-import java.util.List;
-
-public class LayoutAnimation7 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.layout_animation_7);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout1.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout1.java
deleted file mode 100644
index fcf4924..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout1.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * A simple linear layout where the height of the layout is the sum of its children.
- */
-public class LinearLayout1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout10.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout10.java
deleted file mode 100644
index eb22d9a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout10.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates the use of LinearLayout backgrounds to group labels,
- * EditTexts, and buttons,
- */
-public class LinearLayout10 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_10);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout2.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout2.java
deleted file mode 100644
index 044f2b6..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout2.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * A simple linear layout that fills the screen vertically, but the children are not padded.
- */
-public class LinearLayout2 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout3.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout3.java
deleted file mode 100644
index 2468dcd..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout3.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * A simple linear layout that fills the screen vertically, and the middle child is padded with extra space.
- */
-public class LinearLayout3 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_3);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout4.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout4.java
deleted file mode 100644
index f3d1d1b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout4.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates a horizontal linear layout with equally sized columns.
- *
- */
-public class LinearLayout4 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_4);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout5.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout5.java
deleted file mode 100644
index d3b2a25..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout5.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates building a simple form with nested LinearLayouts.
- *
- */
-public class LinearLayout5 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_5);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout6.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout6.java
deleted file mode 100644
index 88745fb..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout6.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates using the uniformSize attribute
- *
- */
-public class LinearLayout6 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_6);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout7.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout7.java
deleted file mode 100644
index 32c787f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout7.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates using fill_parent within a linear layout whose size is not fixed.
- *
- */
-public class LinearLayout7 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_7);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout8.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout8.java
deleted file mode 100644
index 5896782..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout8.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-//Need the following import to get access to the app resources, since this
-//class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.Gravity;
-import android.view.MenuItem;
-import android.widget.LinearLayout;
-
-
-/**
- * Demonstrates horizontal and vertical gravity
- */
-public class LinearLayout8 extends Activity {
-
-    private LinearLayout mLinearLayout;
-
-    // Menu item Ids
-    public static final int VERTICAL_ID = Menu.FIRST;
-    public static final int HORIZONTAL_ID = Menu.FIRST + 1;
-
-    public static final int TOP_ID = Menu.FIRST + 2;
-    public static final int MIDDLE_ID = Menu.FIRST + 3;
-    public static final int BOTTOM_ID = Menu.FIRST + 4;
-
-    public static final int LEFT_ID = Menu.FIRST + 5;
-    public static final int CENTER_ID = Menu.FIRST + 6;
-    public static final int RIGHT_ID = Menu.FIRST + 7;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_8);
-        mLinearLayout = (LinearLayout)findViewById(R.id.layout);
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-        menu.add(0, VERTICAL_ID, 0, R.string.linear_layout_8_vertical);
-        menu.add(0, HORIZONTAL_ID, 0, R.string.linear_layout_8_horizontal);
-        menu.add(0, TOP_ID, 0, R.string.linear_layout_8_top);
-        menu.add(0, MIDDLE_ID, 0, R.string.linear_layout_8_middle);
-        menu.add(0, BOTTOM_ID, 0, R.string.linear_layout_8_bottom);
-        menu.add(0, LEFT_ID, 0, R.string.linear_layout_8_left);
-        menu.add(0, CENTER_ID, 0, R.string.linear_layout_8_center);
-        menu.add(0, RIGHT_ID, 0, R.string.linear_layout_8_right);
-
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-
-        case VERTICAL_ID:
-            mLinearLayout.setOrientation(LinearLayout.VERTICAL);
-            return true;
-        case HORIZONTAL_ID:
-            mLinearLayout.setOrientation(LinearLayout.HORIZONTAL);
-            return true;
-
-        case TOP_ID:
-            mLinearLayout.setVerticalGravity(Gravity.TOP);
-            return true;
-        case MIDDLE_ID:
-            mLinearLayout.setVerticalGravity(Gravity.CENTER_VERTICAL);
-            return true;
-        case BOTTOM_ID:
-            mLinearLayout.setVerticalGravity(Gravity.BOTTOM);
-            return true;
-
-        case LEFT_ID:
-            mLinearLayout.setHorizontalGravity(Gravity.LEFT);
-            return true;
-        case CENTER_ID:
-            mLinearLayout.setHorizontalGravity(Gravity.CENTER_HORIZONTAL);
-            return true;
-        case RIGHT_ID:
-            mLinearLayout.setHorizontalGravity(Gravity.RIGHT);
-            return true;
-
-        }
-        return super.onOptionsItemSelected(item);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout9.java b/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout9.java
deleted file mode 100644
index d120b1e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/LinearLayout9.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.ListView;
-import android.widget.ArrayAdapter;
-
-/**
- * Demonstrates how the layout_weight attribute can shrink an element too big
- * to fit on screen.
- */
-public class LinearLayout9 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.linear_layout_9);
-        ListView list = (ListView) findViewById(R.id.list);
-        list.setAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, AutoComplete1.COUNTRIES));
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List1.java b/samples/ApiDemos/src/com/example/android/apis/view/List1.java
deleted file mode 100644
index 5861923..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List1.java
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-
-
-/**
- * A list view example where the 
- * data for the list comes from an array of strings.
- */
-public class List1 extends ListActivity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Use an existing ListAdapter that will map an array
-        // of strings to TextViews
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, mStrings));
-        getListView().setTextFilterEnabled(true);
-    }
-
-    private String[] mStrings = {
-            "Abbaye de Belloc", "Abbaye du Mont des Cats", "Abertam", "Abondance", "Ackawi",
-            "Acorn", "Adelost", "Affidelice au Chablis", "Afuega'l Pitu", "Airag", "Airedale",
-            "Aisy Cendre", "Allgauer Emmentaler", "Alverca", "Ambert", "American Cheese",
-            "Ami du Chambertin", "Anejo Enchilado", "Anneau du Vic-Bilh", "Anthoriro", "Appenzell",
-            "Aragon", "Ardi Gasna", "Ardrahan", "Armenian String", "Aromes au Gene de Marc",
-            "Asadero", "Asiago", "Aubisque Pyrenees", "Autun", "Avaxtskyr", "Baby Swiss",
-            "Babybel", "Baguette Laonnaise", "Bakers", "Baladi", "Balaton", "Bandal", "Banon",
-            "Barry's Bay Cheddar", "Basing", "Basket Cheese", "Bath Cheese", "Bavarian Bergkase",
-            "Baylough", "Beaufort", "Beauvoorde", "Beenleigh Blue", "Beer Cheese", "Bel Paese",
-            "Bergader", "Bergere Bleue", "Berkswell", "Beyaz Peynir", "Bierkase", "Bishop Kennedy",
-            "Blarney", "Bleu d'Auvergne", "Bleu de Gex", "Bleu de Laqueuille",
-            "Bleu de Septmoncel", "Bleu Des Causses", "Blue", "Blue Castello", "Blue Rathgore",
-            "Blue Vein (Australian)", "Blue Vein Cheeses", "Bocconcini", "Bocconcini (Australian)",
-            "Boeren Leidenkaas", "Bonchester", "Bosworth", "Bougon", "Boule Du Roves",
-            "Boulette d'Avesnes", "Boursault", "Boursin", "Bouyssou", "Bra", "Braudostur",
-            "Breakfast Cheese", "Brebis du Lavort", "Brebis du Lochois", "Brebis du Puyfaucon",
-            "Bresse Bleu", "Brick", "Brie", "Brie de Meaux", "Brie de Melun", "Brillat-Savarin",
-            "Brin", "Brin d' Amour", "Brin d'Amour", "Brinza (Burduf Brinza)",
-            "Briquette de Brebis", "Briquette du Forez", "Broccio", "Broccio Demi-Affine",
-            "Brousse du Rove", "Bruder Basil", "Brusselae Kaas (Fromage de Bruxelles)", "Bryndza",
-            "Buchette d'Anjou", "Buffalo", "Burgos", "Butte", "Butterkase", "Button (Innes)",
-            "Buxton Blue", "Cabecou", "Caboc", "Cabrales", "Cachaille", "Caciocavallo", "Caciotta",
-            "Caerphilly", "Cairnsmore", "Calenzana", "Cambazola", "Camembert de Normandie",
-            "Canadian Cheddar", "Canestrato", "Cantal", "Caprice des Dieux", "Capricorn Goat",
-            "Capriole Banon", "Carre de l'Est", "Casciotta di Urbino", "Cashel Blue", "Castellano",
-            "Castelleno", "Castelmagno", "Castelo Branco", "Castigliano", "Cathelain",
-            "Celtic Promise", "Cendre d'Olivet", "Cerney", "Chabichou", "Chabichou du Poitou",
-            "Chabis de Gatine", "Chaource", "Charolais", "Chaumes", "Cheddar",
-            "Cheddar Clothbound", "Cheshire", "Chevres", "Chevrotin des Aravis", "Chontaleno",
-            "Civray", "Coeur de Camembert au Calvados", "Coeur de Chevre", "Colby", "Cold Pack",
-            "Comte", "Coolea", "Cooleney", "Coquetdale", "Corleggy", "Cornish Pepper",
-            "Cotherstone", "Cotija", "Cottage Cheese", "Cottage Cheese (Australian)",
-            "Cougar Gold", "Coulommiers", "Coverdale", "Crayeux de Roncq", "Cream Cheese",
-            "Cream Havarti", "Crema Agria", "Crema Mexicana", "Creme Fraiche", "Crescenza",
-            "Croghan", "Crottin de Chavignol", "Crottin du Chavignol", "Crowdie", "Crowley",
-            "Cuajada", "Curd", "Cure Nantais", "Curworthy", "Cwmtawe Pecorino",
-            "Cypress Grove Chevre", "Danablu (Danish Blue)", "Danbo", "Danish Fontina",
-            "Daralagjazsky", "Dauphin", "Delice des Fiouves", "Denhany Dorset Drum", "Derby",
-            "Dessertnyj Belyj", "Devon Blue", "Devon Garland", "Dolcelatte", "Doolin",
-            "Doppelrhamstufel", "Dorset Blue Vinney", "Double Gloucester", "Double Worcester",
-            "Dreux a la Feuille", "Dry Jack", "Duddleswell", "Dunbarra", "Dunlop", "Dunsyre Blue",
-            "Duroblando", "Durrus", "Dutch Mimolette (Commissiekaas)", "Edam", "Edelpilz",
-            "Emental Grand Cru", "Emlett", "Emmental", "Epoisses de Bourgogne", "Esbareich",
-            "Esrom", "Etorki", "Evansdale Farmhouse Brie", "Evora De L'Alentejo", "Exmoor Blue",
-            "Explorateur", "Feta", "Feta (Australian)", "Figue", "Filetta", "Fin-de-Siecle",
-            "Finlandia Swiss", "Finn", "Fiore Sardo", "Fleur du Maquis", "Flor de Guia",
-            "Flower Marie", "Folded", "Folded cheese with mint", "Fondant de Brebis",
-            "Fontainebleau", "Fontal", "Fontina Val d'Aosta", "Formaggio di capra", "Fougerus",
-            "Four Herb Gouda", "Fourme d' Ambert", "Fourme de Haute Loire", "Fourme de Montbrison",
-            "Fresh Jack", "Fresh Mozzarella", "Fresh Ricotta", "Fresh Truffles", "Fribourgeois",
-            "Friesekaas", "Friesian", "Friesla", "Frinault", "Fromage a Raclette", "Fromage Corse",
-            "Fromage de Montagne de Savoie", "Fromage Frais", "Fruit Cream Cheese",
-            "Frying Cheese", "Fynbo", "Gabriel", "Galette du Paludier", "Galette Lyonnaise",
-            "Galloway Goat's Milk Gems", "Gammelost", "Gaperon a l'Ail", "Garrotxa", "Gastanberra",
-            "Geitost", "Gippsland Blue", "Gjetost", "Gloucester", "Golden Cross", "Gorgonzola",
-            "Gornyaltajski", "Gospel Green", "Gouda", "Goutu", "Gowrie", "Grabetto", "Graddost",
-            "Grafton Village Cheddar", "Grana", "Grana Padano", "Grand Vatel",
-            "Grataron d' Areches", "Gratte-Paille", "Graviera", "Greuilh", "Greve",
-            "Gris de Lille", "Gruyere", "Gubbeen", "Guerbigny", "Halloumi",
-            "Halloumy (Australian)", "Haloumi-Style Cheese", "Harbourne Blue", "Havarti",
-            "Heidi Gruyere", "Hereford Hop", "Herrgardsost", "Herriot Farmhouse", "Herve",
-            "Hipi Iti", "Hubbardston Blue Cow", "Hushallsost", "Iberico", "Idaho Goatster",
-            "Idiazabal", "Il Boschetto al Tartufo", "Ile d'Yeu", "Isle of Mull", "Jarlsberg",
-            "Jermi Tortes", "Jibneh Arabieh", "Jindi Brie", "Jubilee Blue", "Juustoleipa",
-            "Kadchgall", "Kaseri", "Kashta", "Kefalotyri", "Kenafa", "Kernhem", "Kervella Affine",
-            "Kikorangi", "King Island Cape Wickham Brie", "King River Gold", "Klosterkaese",
-            "Knockalara", "Kugelkase", "L'Aveyronnais", "L'Ecir de l'Aubrac", "La Taupiniere",
-            "La Vache Qui Rit", "Laguiole", "Lairobell", "Lajta", "Lanark Blue", "Lancashire",
-            "Langres", "Lappi", "Laruns", "Lavistown", "Le Brin", "Le Fium Orbo", "Le Lacandou",
-            "Le Roule", "Leafield", "Lebbene", "Leerdammer", "Leicester", "Leyden", "Limburger",
-            "Lincolnshire Poacher", "Lingot Saint Bousquet d'Orb", "Liptauer", "Little Rydings",
-            "Livarot", "Llanboidy", "Llanglofan Farmhouse", "Loch Arthur Farmhouse",
-            "Loddiswell Avondale", "Longhorn", "Lou Palou", "Lou Pevre", "Lyonnais", "Maasdam",
-            "Macconais", "Mahoe Aged Gouda", "Mahon", "Malvern", "Mamirolle", "Manchego",
-            "Manouri", "Manur", "Marble Cheddar", "Marbled Cheeses", "Maredsous", "Margotin",
-            "Maribo", "Maroilles", "Mascares", "Mascarpone", "Mascarpone (Australian)",
-            "Mascarpone Torta", "Matocq", "Maytag Blue", "Meira", "Menallack Farmhouse",
-            "Menonita", "Meredith Blue", "Mesost", "Metton (Cancoillotte)", "Meyer Vintage Gouda",
-            "Mihalic Peynir", "Milleens", "Mimolette", "Mine-Gabhar", "Mini Baby Bells", "Mixte",
-            "Molbo", "Monastery Cheeses", "Mondseer", "Mont D'or Lyonnais", "Montasio",
-            "Monterey Jack", "Monterey Jack Dry", "Morbier", "Morbier Cru de Montagne",
-            "Mothais a la Feuille", "Mozzarella", "Mozzarella (Australian)",
-            "Mozzarella di Bufala", "Mozzarella Fresh, in water", "Mozzarella Rolls", "Munster",
-            "Murol", "Mycella", "Myzithra", "Naboulsi", "Nantais", "Neufchatel",
-            "Neufchatel (Australian)", "Niolo", "Nokkelost", "Northumberland", "Oaxaca",
-            "Olde York", "Olivet au Foin", "Olivet Bleu", "Olivet Cendre",
-            "Orkney Extra Mature Cheddar", "Orla", "Oschtjepka", "Ossau Fermier", "Ossau-Iraty",
-            "Oszczypek", "Oxford Blue", "P'tit Berrichon", "Palet de Babligny", "Paneer", "Panela",
-            "Pannerone", "Pant ys Gawn", "Parmesan (Parmigiano)", "Parmigiano Reggiano",
-            "Pas de l'Escalette", "Passendale", "Pasteurized Processed", "Pate de Fromage",
-            "Patefine Fort", "Pave d'Affinois", "Pave d'Auge", "Pave de Chirac", "Pave du Berry",
-            "Pecorino", "Pecorino in Walnut Leaves", "Pecorino Romano", "Peekskill Pyramid",
-            "Pelardon des Cevennes", "Pelardon des Corbieres", "Penamellera", "Penbryn",
-            "Pencarreg", "Perail de Brebis", "Petit Morin", "Petit Pardou", "Petit-Suisse",
-            "Picodon de Chevre", "Picos de Europa", "Piora", "Pithtviers au Foin",
-            "Plateau de Herve", "Plymouth Cheese", "Podhalanski", "Poivre d'Ane", "Polkolbin",
-            "Pont l'Eveque", "Port Nicholson", "Port-Salut", "Postel", "Pouligny-Saint-Pierre",
-            "Pourly", "Prastost", "Pressato", "Prince-Jean", "Processed Cheddar", "Provolone",
-            "Provolone (Australian)", "Pyengana Cheddar", "Pyramide", "Quark",
-            "Quark (Australian)", "Quartirolo Lombardo", "Quatre-Vents", "Quercy Petit",
-            "Queso Blanco", "Queso Blanco con Frutas --Pina y Mango", "Queso de Murcia",
-            "Queso del Montsec", "Queso del Tietar", "Queso Fresco", "Queso Fresco (Adobera)",
-            "Queso Iberico", "Queso Jalapeno", "Queso Majorero", "Queso Media Luna",
-            "Queso Para Frier", "Queso Quesadilla", "Rabacal", "Raclette", "Ragusano", "Raschera",
-            "Reblochon", "Red Leicester", "Regal de la Dombes", "Reggianito", "Remedou",
-            "Requeson", "Richelieu", "Ricotta", "Ricotta (Australian)", "Ricotta Salata", "Ridder",
-            "Rigotte", "Rocamadour", "Rollot", "Romano", "Romans Part Dieu", "Roncal", "Roquefort",
-            "Roule", "Rouleau De Beaulieu", "Royalp Tilsit", "Rubens", "Rustinu", "Saaland Pfarr",
-            "Saanenkaese", "Saga", "Sage Derby", "Sainte Maure", "Saint-Marcellin",
-            "Saint-Nectaire", "Saint-Paulin", "Salers", "Samso", "San Simon", "Sancerre",
-            "Sap Sago", "Sardo", "Sardo Egyptian", "Sbrinz", "Scamorza", "Schabzieger", "Schloss",
-            "Selles sur Cher", "Selva", "Serat", "Seriously Strong Cheddar", "Serra da Estrela",
-            "Sharpam", "Shelburne Cheddar", "Shropshire Blue", "Siraz", "Sirene", "Smoked Gouda",
-            "Somerset Brie", "Sonoma Jack", "Sottocenare al Tartufo", "Soumaintrain",
-            "Sourire Lozerien", "Spenwood", "Sraffordshire Organic", "St. Agur Blue Cheese",
-            "Stilton", "Stinking Bishop", "String", "Sussex Slipcote", "Sveciaost", "Swaledale",
-            "Sweet Style Swiss", "Swiss", "Syrian (Armenian String)", "Tala", "Taleggio", "Tamie",
-            "Tasmania Highland Chevre Log", "Taupiniere", "Teifi", "Telemea", "Testouri",
-            "Tete de Moine", "Tetilla", "Texas Goat Cheese", "Tibet", "Tillamook Cheddar",
-            "Tilsit", "Timboon Brie", "Toma", "Tomme Brulee", "Tomme d'Abondance",
-            "Tomme de Chevre", "Tomme de Romans", "Tomme de Savoie", "Tomme des Chouans", "Tommes",
-            "Torta del Casar", "Toscanello", "Touree de L'Aubier", "Tourmalet",
-            "Trappe (Veritable)", "Trois Cornes De Vendee", "Tronchon", "Trou du Cru", "Truffe",
-            "Tupi", "Turunmaa", "Tymsboro", "Tyn Grug", "Tyning", "Ubriaco", "Ulloa",
-            "Vacherin-Fribourgeois", "Valencay", "Vasterbottenost", "Venaco", "Vendomois",
-            "Vieux Corse", "Vignotte", "Vulscombe", "Waimata Farmhouse Blue",
-            "Washed Rind Cheese (Australian)", "Waterloo", "Weichkaese", "Wellington",
-            "Wensleydale", "White Stilton", "Whitestone Farmhouse", "Wigmore", "Woodside Cabecou",
-            "Xanadu", "Xynotyro", "Yarg Cornish", "Yarra Valley Pyramid", "Yorkshire Blue",
-            "Zamorano", "Zanetti Grana Padano", "Zanetti Parmigiano Reggiano"};
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List10.java b/samples/ApiDemos/src/com/example/android/apis/view/List10.java
deleted file mode 100644
index 57e0bb1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List10.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-
-/**
- * This example shows how to use choice mode on a list. This list is 
- * in CHOICE_MODE_SINGLE mode, which means the items behave like
- * checkboxes.
- */
-public class List10 extends ListActivity {
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_single_choice, GENRES));
-        
-        final ListView listView = getListView();
-
-        listView.setItemsCanFocus(false);
-        listView.setChoiceMode(ListView.CHOICE_MODE_SINGLE);
-    }
-
-
-    private static final String[] GENRES = new String[] {
-        "Action", "Adventure", "Animation", "Children", "Comedy", "Documentary", "Drama",
-        "Foreign", "History", "Independent", "Romance", "Sci-Fi", "Television", "Thriller"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List11.java b/samples/ApiDemos/src/com/example/android/apis/view/List11.java
deleted file mode 100644
index 71d77e5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List11.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-
-/**
- * This example shows how to use choice mode on a list. This list is 
- * in CHOICE_MODE_MULTIPLE mode, which means the items behave like
- * checkboxes.
- */
-public class List11 extends ListActivity {
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_multiple_choice, GENRES));
-        
-        final ListView listView = getListView();
-
-        listView.setItemsCanFocus(false);
-        listView.setChoiceMode(ListView.CHOICE_MODE_MULTIPLE);
-    }
-
-
-    private static final String[] GENRES = new String[] {
-        "Action", "Adventure", "Animation", "Children", "Comedy", "Documentary", "Drama",
-        "Foreign", "History", "Independent", "Romance", "Sci-Fi", "Television", "Thriller"
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List12.java b/samples/ApiDemos/src/com/example/android/apis/view/List12.java
deleted file mode 100644
index 0867fc5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List12.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.view.View.OnKeyListener;
-import android.widget.ArrayAdapter;
-import android.widget.EditText;
-
-import com.example.android.apis.R;
-
-import java.util.ArrayList;
-
-/**
- * Demonstrates the using a list view in transcript mode
- *
- */
-public class List12 extends ListActivity implements OnClickListener, OnKeyListener {
-
-    private EditText mUserText;
-    
-    private ArrayAdapter<String> mAdapter;
-    
-    private ArrayList<String> mStrings = new ArrayList<String>();
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        setContentView(R.layout.list_12);
-        
-        mAdapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, mStrings);
-        
-        setListAdapter(mAdapter);
-        
-        mUserText = (EditText) findViewById(R.id.userText);
-
-        mUserText.setOnClickListener(this);
-        mUserText.setOnKeyListener(this);
-    }
-
-    public void onClick(View v) {
-        sendText();
-    }
-
-    private void sendText() {
-        String text = mUserText.getText().toString();
-        mAdapter.add(text);
-        mUserText.setText(null);
-    }
-
-    public boolean onKey(View v, int keyCode, KeyEvent event) {
-        if (event.getAction() == KeyEvent.ACTION_DOWN) {
-            switch (keyCode) {
-                case KeyEvent.KEYCODE_DPAD_CENTER:
-                case KeyEvent.KEYCODE_ENTER:
-                    sendText();
-                    return true;
-            }
-        }
-        return false;
-    }
-    
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List13.java b/samples/ApiDemos/src/com/example/android/apis/view/List13.java
deleted file mode 100644
index b3087be..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List13.java
+++ /dev/null
@@ -1,347 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.AbsListView;
-import android.widget.BaseAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-import android.widget.AbsListView.OnScrollListener;
-
-import com.example.android.apis.R;
-
-
-/**
- * Demonstrates how a list can avoid expensive operations during scrolls or flings. In this
- * case, we pretend that binding a view to its data is slow (even though it really isn't). When
- * a scroll/fling is happening, the adapter binds the view to temporary data. After the scroll/fling
- * has finished, the temporary data is replace with the actual data.
- *
- */
-public class List13 extends ListActivity implements ListView.OnScrollListener {
-
-    private TextView mStatus;
-    
-    private boolean mBusy = false;
-    
-    /**
-     * Will not bind views while the list is scrolling
-     * 
-     */
-    private class SlowAdapter extends BaseAdapter {
-        private LayoutInflater mInflater;
-        
-        public SlowAdapter(Context context) {
-            mContext = context;
-            mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        }
-
-        /**
-         * The number of items in the list is determined by the number of speeches
-         * in our array.
-         * 
-         * @see android.widget.ListAdapter#getCount()
-         */
-        public int getCount() {
-            return mStrings.length;
-        }
-
-        /**
-         * Since the data comes from an array, just returning the index is
-         * sufficent to get at the data. If we were using a more complex data
-         * structure, we would return whatever object represents one row in the
-         * list.
-         * 
-         * @see android.widget.ListAdapter#getItem(int)
-         */
-        public Object getItem(int position) {
-            return position;
-        }
-
-        /**
-         * Use the array index as a unique id.
-         * 
-         * @see android.widget.ListAdapter#getItemId(int)
-         */
-        public long getItemId(int position) {
-            return position;
-        }
-
-        /**
-         * Make a view to hold each row.
-         * 
-         * @see android.widget.ListAdapter#getView(int, android.view.View,
-         *      android.view.ViewGroup)
-         */
-        public View getView(int position, View convertView, ViewGroup parent) {
-            TextView text;
-            
-            if (convertView == null) {
-                text = (TextView)mInflater.inflate(android.R.layout.simple_list_item_1, parent, false);
-            } else {
-                text = (TextView)convertView;
-            }
-
-            if (!mBusy) {
-                text.setText(mStrings[position]);
-                // Null tag means the view has the correct data
-                text.setTag(null);
-            } else {
-                text.setText("Loading...");
-                // Non-null tag means the view still needs to load it's data
-                text.setTag(this);
-            }
-
-            return text;
-        }
-
-        /**
-         * Remember our context so we can use it when constructing views.
-         */
-        private Context mContext;
-    }
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.list_13);
-        mStatus = (TextView) findViewById(R.id.status);
-        mStatus.setText("Idle");
-        
-        // Use an existing ListAdapter that will map an array
-        // of strings to TextViews
-        setListAdapter(new SlowAdapter(this));
-        
-        getListView().setOnScrollListener(this);
-    }
-    
-    
-    public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount,
-            int totalItemCount) {
-    }
-    
-
-    public void onScrollStateChanged(AbsListView view, int scrollState) {
-        switch (scrollState) {
-        case OnScrollListener.SCROLL_STATE_IDLE:
-            mBusy = false;
-            
-            int first = view.getFirstVisiblePosition();
-            int count = view.getChildCount();
-            for (int i=0; i<count; i++) {
-                TextView t = (TextView)view.getChildAt(i);
-                if (t.getTag() != null) {
-                    t.setText(mStrings[first + i]);
-                    t.setTag(null);
-                }
-            }
-            
-            mStatus.setText("Idle");
-            break;
-        case OnScrollListener.SCROLL_STATE_TOUCH_SCROLL:
-            mBusy = true;
-            mStatus.setText("Touch scroll");
-            break;
-        case OnScrollListener.SCROLL_STATE_FLING:
-            mBusy = true;
-            mStatus.setText("Fling");
-            break;
-        }
-    }
-
-    private String[] mStrings = {
-            "Abbaye de Belloc", "Abbaye du Mont des Cats", "Abertam",
-            "Abondance", "Ackawi", "Acorn", "Adelost", "Affidelice au Chablis",
-            "Afuega'l Pitu", "Airag", "Airedale", "Aisy Cendre",
-            "Allgauer Emmentaler", "Alverca", "Ambert", "American Cheese",
-            "Ami du Chambertin", "Anejo Enchilado", "Anneau du Vic-Bilh",
-            "Anthoriro", "Appenzell", "Aragon", "Ardi Gasna", "Ardrahan",
-            "Armenian String", "Aromes au Gene de Marc", "Asadero", "Asiago",
-            "Aubisque Pyrenees", "Autun", "Avaxtskyr", "Baby Swiss", "Babybel",
-            "Baguette Laonnaise", "Bakers", "Baladi", "Balaton", "Bandal",
-            "Banon", "Barry's Bay Cheddar", "Basing", "Basket Cheese",
-            "Bath Cheese", "Bavarian Bergkase", "Baylough", "Beaufort",
-            "Beauvoorde", "Beenleigh Blue", "Beer Cheese", "Bel Paese",
-            "Bergader", "Bergere Bleue", "Berkswell", "Beyaz Peynir",
-            "Bierkase", "Bishop Kennedy", "Blarney", "Bleu d'Auvergne",
-            "Bleu de Gex", "Bleu de Laqueuille", "Bleu de Septmoncel",
-            "Bleu Des Causses", "Blue", "Blue Castello", "Blue Rathgore",
-            "Blue Vein (Australian)", "Blue Vein Cheeses", "Bocconcini",
-            "Bocconcini (Australian)", "Boeren Leidenkaas", "Bonchester",
-            "Bosworth", "Bougon", "Boule Du Roves", "Boulette d'Avesnes",
-            "Boursault", "Boursin", "Bouyssou", "Bra", "Braudostur",
-            "Breakfast Cheese", "Brebis du Lavort", "Brebis du Lochois",
-            "Brebis du Puyfaucon", "Bresse Bleu", "Brick", "Brie",
-            "Brie de Meaux", "Brie de Melun", "Brillat-Savarin", "Brin",
-            "Brin d' Amour", "Brin d'Amour", "Brinza (Burduf Brinza)",
-            "Briquette de Brebis", "Briquette du Forez", "Broccio",
-            "Broccio Demi-Affine", "Brousse du Rove", "Bruder Basil",
-            "Brusselae Kaas (Fromage de Bruxelles)", "Bryndza",
-            "Buchette d'Anjou", "Buffalo", "Burgos", "Butte", "Butterkase",
-            "Button (Innes)", "Buxton Blue", "Cabecou", "Caboc", "Cabrales",
-            "Cachaille", "Caciocavallo", "Caciotta", "Caerphilly",
-            "Cairnsmore", "Calenzana", "Cambazola", "Camembert de Normandie",
-            "Canadian Cheddar", "Canestrato", "Cantal", "Caprice des Dieux",
-            "Capricorn Goat", "Capriole Banon", "Carre de l'Est",
-            "Casciotta di Urbino", "Cashel Blue", "Castellano", "Castelleno",
-            "Castelmagno", "Castelo Branco", "Castigliano", "Cathelain",
-            "Celtic Promise", "Cendre d'Olivet", "Cerney", "Chabichou",
-            "Chabichou du Poitou", "Chabis de Gatine", "Chaource", "Charolais",
-            "Chaumes", "Cheddar", "Cheddar Clothbound", "Cheshire", "Chevres",
-            "Chevrotin des Aravis", "Chontaleno", "Civray",
-            "Coeur de Camembert au Calvados", "Coeur de Chevre", "Colby",
-            "Cold Pack", "Comte", "Coolea", "Cooleney", "Coquetdale",
-            "Corleggy", "Cornish Pepper", "Cotherstone", "Cotija",
-            "Cottage Cheese", "Cottage Cheese (Australian)", "Cougar Gold",
-            "Coulommiers", "Coverdale", "Crayeux de Roncq", "Cream Cheese",
-            "Cream Havarti", "Crema Agria", "Crema Mexicana", "Creme Fraiche",
-            "Crescenza", "Croghan", "Crottin de Chavignol",
-            "Crottin du Chavignol", "Crowdie", "Crowley", "Cuajada", "Curd",
-            "Cure Nantais", "Curworthy", "Cwmtawe Pecorino",
-            "Cypress Grove Chevre", "Danablu (Danish Blue)", "Danbo",
-            "Danish Fontina", "Daralagjazsky", "Dauphin", "Delice des Fiouves",
-            "Denhany Dorset Drum", "Derby", "Dessertnyj Belyj", "Devon Blue",
-            "Devon Garland", "Dolcelatte", "Doolin", "Doppelrhamstufel",
-            "Dorset Blue Vinney", "Double Gloucester", "Double Worcester",
-            "Dreux a la Feuille", "Dry Jack", "Duddleswell", "Dunbarra",
-            "Dunlop", "Dunsyre Blue", "Duroblando", "Durrus",
-            "Dutch Mimolette (Commissiekaas)", "Edam", "Edelpilz",
-            "Emental Grand Cru", "Emlett", "Emmental", "Epoisses de Bourgogne",
-            "Esbareich", "Esrom", "Etorki", "Evansdale Farmhouse Brie",
-            "Evora De L'Alentejo", "Exmoor Blue", "Explorateur", "Feta",
-            "Feta (Australian)", "Figue", "Filetta", "Fin-de-Siecle",
-            "Finlandia Swiss", "Finn", "Fiore Sardo", "Fleur du Maquis",
-            "Flor de Guia", "Flower Marie", "Folded",
-            "Folded cheese with mint", "Fondant de Brebis", "Fontainebleau",
-            "Fontal", "Fontina Val d'Aosta", "Formaggio di capra", "Fougerus",
-            "Four Herb Gouda", "Fourme d' Ambert", "Fourme de Haute Loire",
-            "Fourme de Montbrison", "Fresh Jack", "Fresh Mozzarella",
-            "Fresh Ricotta", "Fresh Truffles", "Fribourgeois", "Friesekaas",
-            "Friesian", "Friesla", "Frinault", "Fromage a Raclette",
-            "Fromage Corse", "Fromage de Montagne de Savoie", "Fromage Frais",
-            "Fruit Cream Cheese", "Frying Cheese", "Fynbo", "Gabriel",
-            "Galette du Paludier", "Galette Lyonnaise",
-            "Galloway Goat's Milk Gems", "Gammelost", "Gaperon a l'Ail",
-            "Garrotxa", "Gastanberra", "Geitost", "Gippsland Blue", "Gjetost",
-            "Gloucester", "Golden Cross", "Gorgonzola", "Gornyaltajski",
-            "Gospel Green", "Gouda", "Goutu", "Gowrie", "Grabetto", "Graddost",
-            "Grafton Village Cheddar", "Grana", "Grana Padano", "Grand Vatel",
-            "Grataron d' Areches", "Gratte-Paille", "Graviera", "Greuilh",
-            "Greve", "Gris de Lille", "Gruyere", "Gubbeen", "Guerbigny",
-            "Halloumi", "Halloumy (Australian)", "Haloumi-Style Cheese",
-            "Harbourne Blue", "Havarti", "Heidi Gruyere", "Hereford Hop",
-            "Herrgardsost", "Herriot Farmhouse", "Herve", "Hipi Iti",
-            "Hubbardston Blue Cow", "Hushallsost", "Iberico", "Idaho Goatster",
-            "Idiazabal", "Il Boschetto al Tartufo", "Ile d'Yeu",
-            "Isle of Mull", "Jarlsberg", "Jermi Tortes", "Jibneh Arabieh",
-            "Jindi Brie", "Jubilee Blue", "Juustoleipa", "Kadchgall", "Kaseri",
-            "Kashta", "Kefalotyri", "Kenafa", "Kernhem", "Kervella Affine",
-            "Kikorangi", "King Island Cape Wickham Brie", "King River Gold",
-            "Klosterkaese", "Knockalara", "Kugelkase", "L'Aveyronnais",
-            "L'Ecir de l'Aubrac", "La Taupiniere", "La Vache Qui Rit",
-            "Laguiole", "Lairobell", "Lajta", "Lanark Blue", "Lancashire",
-            "Langres", "Lappi", "Laruns", "Lavistown", "Le Brin",
-            "Le Fium Orbo", "Le Lacandou", "Le Roule", "Leafield", "Lebbene",
-            "Leerdammer", "Leicester", "Leyden", "Limburger",
-            "Lincolnshire Poacher", "Lingot Saint Bousquet d'Orb", "Liptauer",
-            "Little Rydings", "Livarot", "Llanboidy", "Llanglofan Farmhouse",
-            "Loch Arthur Farmhouse", "Loddiswell Avondale", "Longhorn",
-            "Lou Palou", "Lou Pevre", "Lyonnais", "Maasdam", "Macconais",
-            "Mahoe Aged Gouda", "Mahon", "Malvern", "Mamirolle", "Manchego",
-            "Manouri", "Manur", "Marble Cheddar", "Marbled Cheeses",
-            "Maredsous", "Margotin", "Maribo", "Maroilles", "Mascares",
-            "Mascarpone", "Mascarpone (Australian)", "Mascarpone Torta",
-            "Matocq", "Maytag Blue", "Meira", "Menallack Farmhouse",
-            "Menonita", "Meredith Blue", "Mesost", "Metton (Cancoillotte)",
-            "Meyer Vintage Gouda", "Mihalic Peynir", "Milleens", "Mimolette",
-            "Mine-Gabhar", "Mini Baby Bells", "Mixte", "Molbo",
-            "Monastery Cheeses", "Mondseer", "Mont D'or Lyonnais", "Montasio",
-            "Monterey Jack", "Monterey Jack Dry", "Morbier",
-            "Morbier Cru de Montagne", "Mothais a la Feuille", "Mozzarella",
-            "Mozzarella (Australian)", "Mozzarella di Bufala",
-            "Mozzarella Fresh, in water", "Mozzarella Rolls", "Munster",
-            "Murol", "Mycella", "Myzithra", "Naboulsi", "Nantais",
-            "Neufchatel", "Neufchatel (Australian)", "Niolo", "Nokkelost",
-            "Northumberland", "Oaxaca", "Olde York", "Olivet au Foin",
-            "Olivet Bleu", "Olivet Cendre", "Orkney Extra Mature Cheddar",
-            "Orla", "Oschtjepka", "Ossau Fermier", "Ossau-Iraty", "Oszczypek",
-            "Oxford Blue", "P'tit Berrichon", "Palet de Babligny", "Paneer",
-            "Panela", "Pannerone", "Pant ys Gawn", "Parmesan (Parmigiano)",
-            "Parmigiano Reggiano", "Pas de l'Escalette", "Passendale",
-            "Pasteurized Processed", "Pate de Fromage", "Patefine Fort",
-            "Pave d'Affinois", "Pave d'Auge", "Pave de Chirac",
-            "Pave du Berry", "Pecorino", "Pecorino in Walnut Leaves",
-            "Pecorino Romano", "Peekskill Pyramid", "Pelardon des Cevennes",
-            "Pelardon des Corbieres", "Penamellera", "Penbryn", "Pencarreg",
-            "Perail de Brebis", "Petit Morin", "Petit Pardou", "Petit-Suisse",
-            "Picodon de Chevre", "Picos de Europa", "Piora",
-            "Pithtviers au Foin", "Plateau de Herve", "Plymouth Cheese",
-            "Podhalanski", "Poivre d'Ane", "Polkolbin", "Pont l'Eveque",
-            "Port Nicholson", "Port-Salut", "Postel", "Pouligny-Saint-Pierre",
-            "Pourly", "Prastost", "Pressato", "Prince-Jean",
-            "Processed Cheddar", "Provolone", "Provolone (Australian)",
-            "Pyengana Cheddar", "Pyramide", "Quark", "Quark (Australian)",
-            "Quartirolo Lombardo", "Quatre-Vents", "Quercy Petit",
-            "Queso Blanco", "Queso Blanco con Frutas --Pina y Mango",
-            "Queso de Murcia", "Queso del Montsec", "Queso del Tietar",
-            "Queso Fresco", "Queso Fresco (Adobera)", "Queso Iberico",
-            "Queso Jalapeno", "Queso Majorero", "Queso Media Luna",
-            "Queso Para Frier", "Queso Quesadilla", "Rabacal", "Raclette",
-            "Ragusano", "Raschera", "Reblochon", "Red Leicester",
-            "Regal de la Dombes", "Reggianito", "Remedou", "Requeson",
-            "Richelieu", "Ricotta", "Ricotta (Australian)", "Ricotta Salata",
-            "Ridder", "Rigotte", "Rocamadour", "Rollot", "Romano",
-            "Romans Part Dieu", "Roncal", "Roquefort", "Roule",
-            "Rouleau De Beaulieu", "Royalp Tilsit", "Rubens", "Rustinu",
-            "Saaland Pfarr", "Saanenkaese", "Saga", "Sage Derby",
-            "Sainte Maure", "Saint-Marcellin", "Saint-Nectaire",
-            "Saint-Paulin", "Salers", "Samso", "San Simon", "Sancerre",
-            "Sap Sago", "Sardo", "Sardo Egyptian", "Sbrinz", "Scamorza",
-            "Schabzieger", "Schloss", "Selles sur Cher", "Selva", "Serat",
-            "Seriously Strong Cheddar", "Serra da Estrela", "Sharpam",
-            "Shelburne Cheddar", "Shropshire Blue", "Siraz", "Sirene",
-            "Smoked Gouda", "Somerset Brie", "Sonoma Jack",
-            "Sottocenare al Tartufo", "Soumaintrain", "Sourire Lozerien",
-            "Spenwood", "Sraffordshire Organic", "St. Agur Blue Cheese",
-            "Stilton", "Stinking Bishop", "String", "Sussex Slipcote",
-            "Sveciaost", "Swaledale", "Sweet Style Swiss", "Swiss",
-            "Syrian (Armenian String)", "Tala", "Taleggio", "Tamie",
-            "Tasmania Highland Chevre Log", "Taupiniere", "Teifi", "Telemea",
-            "Testouri", "Tete de Moine", "Tetilla", "Texas Goat Cheese",
-            "Tibet", "Tillamook Cheddar", "Tilsit", "Timboon Brie", "Toma",
-            "Tomme Brulee", "Tomme d'Abondance", "Tomme de Chevre",
-            "Tomme de Romans", "Tomme de Savoie", "Tomme des Chouans",
-            "Tommes", "Torta del Casar", "Toscanello", "Touree de L'Aubier",
-            "Tourmalet", "Trappe (Veritable)", "Trois Cornes De Vendee",
-            "Tronchon", "Trou du Cru", "Truffe", "Tupi", "Turunmaa",
-            "Tymsboro", "Tyn Grug", "Tyning", "Ubriaco", "Ulloa",
-            "Vacherin-Fribourgeois", "Valencay", "Vasterbottenost", "Venaco",
-            "Vendomois", "Vieux Corse", "Vignotte", "Vulscombe",
-            "Waimata Farmhouse Blue", "Washed Rind Cheese (Australian)",
-            "Waterloo", "Weichkaese", "Wellington", "Wensleydale",
-            "White Stilton", "Whitestone Farmhouse", "Wigmore",
-            "Woodside Cabecou", "Xanadu", "Xynotyro", "Yarg Cornish",
-            "Yarra Valley Pyramid", "Yorkshire Blue", "Zamorano",
-            "Zanetti Grana Padano", "Zanetti Parmigiano Reggiano"};
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List14.java b/samples/ApiDemos/src/com/example/android/apis/view/List14.java
deleted file mode 100644
index 41eb481..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List14.java
+++ /dev/null
@@ -1,314 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.TextView;
-import android.widget.ImageView;
-import android.graphics.BitmapFactory;
-import android.graphics.Bitmap;
-import com.example.android.apis.R;
-
-/**
- * Demonstrates how to write an efficient list adapter. The adapter used in this example binds
- * to an ImageView and to a TextView for each row in the list.
- *
- * To work efficiently the adapter implemented here uses two techniques:
- * - It reuses the convertView passed to getView() to avoid inflating View when it is not necessary
- * - It uses the ViewHolder pattern to avoid calling findViewById() when it is not necessary
- *
- * The ViewHolder pattern consists in storing a data structure in the tag of the view returned by
- * getView(). This data structures contains references to the views we want to bind data to, thus
- * avoiding calls to findViewById() every time getView() is invoked.
- */
-public class List14 extends ListActivity {
-
-    private static class EfficientAdapter extends BaseAdapter {
-        private LayoutInflater mInflater;
-        private Bitmap mIcon1;
-        private Bitmap mIcon2;
-
-        public EfficientAdapter(Context context) {
-            // Cache the LayoutInflate to avoid asking for a new one each time.
-            mInflater = LayoutInflater.from(context);
-
-            // Icons bound to the rows.
-            mIcon1 = BitmapFactory.decodeResource(context.getResources(), R.drawable.icon48x48_1);
-            mIcon2 = BitmapFactory.decodeResource(context.getResources(), R.drawable.icon48x48_2);
-        }
-
-        /**
-         * The number of items in the list is determined by the number of speeches
-         * in our array.
-         *
-         * @see android.widget.ListAdapter#getCount()
-         */
-        public int getCount() {
-            return DATA.length;
-        }
-
-        /**
-         * Since the data comes from an array, just returning the index is
-         * sufficent to get at the data. If we were using a more complex data
-         * structure, we would return whatever object represents one row in the
-         * list.
-         *
-         * @see android.widget.ListAdapter#getItem(int)
-         */
-        public Object getItem(int position) {
-            return position;
-        }
-
-        /**
-         * Use the array index as a unique id.
-         *
-         * @see android.widget.ListAdapter#getItemId(int)
-         */
-        public long getItemId(int position) {
-            return position;
-        }
-
-        /**
-         * Make a view to hold each row.
-         *
-         * @see android.widget.ListAdapter#getView(int, android.view.View,
-         *      android.view.ViewGroup)
-         */
-        public View getView(int position, View convertView, ViewGroup parent) {
-            // A ViewHolder keeps references to children views to avoid unneccessary calls
-            // to findViewById() on each row.
-            ViewHolder holder;
-
-            // When convertView is not null, we can reuse it directly, there is no need
-            // to reinflate it. We only inflate a new View when the convertView supplied
-            // by ListView is null.
-            if (convertView == null) {
-                convertView = mInflater.inflate(R.layout.list_item_icon_text, null);
-
-                // Creates a ViewHolder and store references to the two children views
-                // we want to bind data to.
-                holder = new ViewHolder();
-                holder.text = (TextView) convertView.findViewById(R.id.text);
-                holder.icon = (ImageView) convertView.findViewById(R.id.icon);
-
-                convertView.setTag(holder);
-            } else {
-                // Get the ViewHolder back to get fast access to the TextView
-                // and the ImageView.
-                holder = (ViewHolder) convertView.getTag();
-            }
-
-            // Bind the data efficiently with the holder.
-            holder.text.setText(DATA[position]);
-            holder.icon.setImageBitmap((position & 1) == 1 ? mIcon1 : mIcon2);
-
-            return convertView;
-        }
-
-        static class ViewHolder {
-            TextView text;
-            ImageView icon;
-        }
-    }
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setListAdapter(new EfficientAdapter(this));
-    }
-
-    private static final String[] DATA = {
-            "Abbaye de Belloc", "Abbaye du Mont des Cats", "Abertam",
-            "Abondance", "Ackawi", "Acorn", "Adelost", "Affidelice au Chablis",
-            "Afuega'l Pitu", "Airag", "Airedale", "Aisy Cendre",
-            "Allgauer Emmentaler", "Alverca", "Ambert", "American Cheese",
-            "Ami du Chambertin", "Anejo Enchilado", "Anneau du Vic-Bilh",
-            "Anthoriro", "Appenzell", "Aragon", "Ardi Gasna", "Ardrahan",
-            "Armenian String", "Aromes au Gene de Marc", "Asadero", "Asiago",
-            "Aubisque Pyrenees", "Autun", "Avaxtskyr", "Baby Swiss", "Babybel",
-            "Baguette Laonnaise", "Bakers", "Baladi", "Balaton", "Bandal",
-            "Banon", "Barry's Bay Cheddar", "Basing", "Basket Cheese",
-            "Bath Cheese", "Bavarian Bergkase", "Baylough", "Beaufort",
-            "Beauvoorde", "Beenleigh Blue", "Beer Cheese", "Bel Paese",
-            "Bergader", "Bergere Bleue", "Berkswell", "Beyaz Peynir",
-            "Bierkase", "Bishop Kennedy", "Blarney", "Bleu d'Auvergne",
-            "Bleu de Gex", "Bleu de Laqueuille", "Bleu de Septmoncel",
-            "Bleu Des Causses", "Blue", "Blue Castello", "Blue Rathgore",
-            "Blue Vein (Australian)", "Blue Vein Cheeses", "Bocconcini",
-            "Bocconcini (Australian)", "Boeren Leidenkaas", "Bonchester",
-            "Bosworth", "Bougon", "Boule Du Roves", "Boulette d'Avesnes",
-            "Boursault", "Boursin", "Bouyssou", "Bra", "Braudostur",
-            "Breakfast Cheese", "Brebis du Lavort", "Brebis du Lochois",
-            "Brebis du Puyfaucon", "Bresse Bleu", "Brick", "Brie",
-            "Brie de Meaux", "Brie de Melun", "Brillat-Savarin", "Brin",
-            "Brin d' Amour", "Brin d'Amour", "Brinza (Burduf Brinza)",
-            "Briquette de Brebis", "Briquette du Forez", "Broccio",
-            "Broccio Demi-Affine", "Brousse du Rove", "Bruder Basil",
-            "Brusselae Kaas (Fromage de Bruxelles)", "Bryndza",
-            "Buchette d'Anjou", "Buffalo", "Burgos", "Butte", "Butterkase",
-            "Button (Innes)", "Buxton Blue", "Cabecou", "Caboc", "Cabrales",
-            "Cachaille", "Caciocavallo", "Caciotta", "Caerphilly",
-            "Cairnsmore", "Calenzana", "Cambazola", "Camembert de Normandie",
-            "Canadian Cheddar", "Canestrato", "Cantal", "Caprice des Dieux",
-            "Capricorn Goat", "Capriole Banon", "Carre de l'Est",
-            "Casciotta di Urbino", "Cashel Blue", "Castellano", "Castelleno",
-            "Castelmagno", "Castelo Branco", "Castigliano", "Cathelain",
-            "Celtic Promise", "Cendre d'Olivet", "Cerney", "Chabichou",
-            "Chabichou du Poitou", "Chabis de Gatine", "Chaource", "Charolais",
-            "Chaumes", "Cheddar", "Cheddar Clothbound", "Cheshire", "Chevres",
-            "Chevrotin des Aravis", "Chontaleno", "Civray",
-            "Coeur de Camembert au Calvados", "Coeur de Chevre", "Colby",
-            "Cold Pack", "Comte", "Coolea", "Cooleney", "Coquetdale",
-            "Corleggy", "Cornish Pepper", "Cotherstone", "Cotija",
-            "Cottage Cheese", "Cottage Cheese (Australian)", "Cougar Gold",
-            "Coulommiers", "Coverdale", "Crayeux de Roncq", "Cream Cheese",
-            "Cream Havarti", "Crema Agria", "Crema Mexicana", "Creme Fraiche",
-            "Crescenza", "Croghan", "Crottin de Chavignol",
-            "Crottin du Chavignol", "Crowdie", "Crowley", "Cuajada", "Curd",
-            "Cure Nantais", "Curworthy", "Cwmtawe Pecorino",
-            "Cypress Grove Chevre", "Danablu (Danish Blue)", "Danbo",
-            "Danish Fontina", "Daralagjazsky", "Dauphin", "Delice des Fiouves",
-            "Denhany Dorset Drum", "Derby", "Dessertnyj Belyj", "Devon Blue",
-            "Devon Garland", "Dolcelatte", "Doolin", "Doppelrhamstufel",
-            "Dorset Blue Vinney", "Double Gloucester", "Double Worcester",
-            "Dreux a la Feuille", "Dry Jack", "Duddleswell", "Dunbarra",
-            "Dunlop", "Dunsyre Blue", "Duroblando", "Durrus",
-            "Dutch Mimolette (Commissiekaas)", "Edam", "Edelpilz",
-            "Emental Grand Cru", "Emlett", "Emmental", "Epoisses de Bourgogne",
-            "Esbareich", "Esrom", "Etorki", "Evansdale Farmhouse Brie",
-            "Evora De L'Alentejo", "Exmoor Blue", "Explorateur", "Feta",
-            "Feta (Australian)", "Figue", "Filetta", "Fin-de-Siecle",
-            "Finlandia Swiss", "Finn", "Fiore Sardo", "Fleur du Maquis",
-            "Flor de Guia", "Flower Marie", "Folded",
-            "Folded cheese with mint", "Fondant de Brebis", "Fontainebleau",
-            "Fontal", "Fontina Val d'Aosta", "Formaggio di capra", "Fougerus",
-            "Four Herb Gouda", "Fourme d' Ambert", "Fourme de Haute Loire",
-            "Fourme de Montbrison", "Fresh Jack", "Fresh Mozzarella",
-            "Fresh Ricotta", "Fresh Truffles", "Fribourgeois", "Friesekaas",
-            "Friesian", "Friesla", "Frinault", "Fromage a Raclette",
-            "Fromage Corse", "Fromage de Montagne de Savoie", "Fromage Frais",
-            "Fruit Cream Cheese", "Frying Cheese", "Fynbo", "Gabriel",
-            "Galette du Paludier", "Galette Lyonnaise",
-            "Galloway Goat's Milk Gems", "Gammelost", "Gaperon a l'Ail",
-            "Garrotxa", "Gastanberra", "Geitost", "Gippsland Blue", "Gjetost",
-            "Gloucester", "Golden Cross", "Gorgonzola", "Gornyaltajski",
-            "Gospel Green", "Gouda", "Goutu", "Gowrie", "Grabetto", "Graddost",
-            "Grafton Village Cheddar", "Grana", "Grana Padano", "Grand Vatel",
-            "Grataron d' Areches", "Gratte-Paille", "Graviera", "Greuilh",
-            "Greve", "Gris de Lille", "Gruyere", "Gubbeen", "Guerbigny",
-            "Halloumi", "Halloumy (Australian)", "Haloumi-Style Cheese",
-            "Harbourne Blue", "Havarti", "Heidi Gruyere", "Hereford Hop",
-            "Herrgardsost", "Herriot Farmhouse", "Herve", "Hipi Iti",
-            "Hubbardston Blue Cow", "Hushallsost", "Iberico", "Idaho Goatster",
-            "Idiazabal", "Il Boschetto al Tartufo", "Ile d'Yeu",
-            "Isle of Mull", "Jarlsberg", "Jermi Tortes", "Jibneh Arabieh",
-            "Jindi Brie", "Jubilee Blue", "Juustoleipa", "Kadchgall", "Kaseri",
-            "Kashta", "Kefalotyri", "Kenafa", "Kernhem", "Kervella Affine",
-            "Kikorangi", "King Island Cape Wickham Brie", "King River Gold",
-            "Klosterkaese", "Knockalara", "Kugelkase", "L'Aveyronnais",
-            "L'Ecir de l'Aubrac", "La Taupiniere", "La Vache Qui Rit",
-            "Laguiole", "Lairobell", "Lajta", "Lanark Blue", "Lancashire",
-            "Langres", "Lappi", "Laruns", "Lavistown", "Le Brin",
-            "Le Fium Orbo", "Le Lacandou", "Le Roule", "Leafield", "Lebbene",
-            "Leerdammer", "Leicester", "Leyden", "Limburger",
-            "Lincolnshire Poacher", "Lingot Saint Bousquet d'Orb", "Liptauer",
-            "Little Rydings", "Livarot", "Llanboidy", "Llanglofan Farmhouse",
-            "Loch Arthur Farmhouse", "Loddiswell Avondale", "Longhorn",
-            "Lou Palou", "Lou Pevre", "Lyonnais", "Maasdam", "Macconais",
-            "Mahoe Aged Gouda", "Mahon", "Malvern", "Mamirolle", "Manchego",
-            "Manouri", "Manur", "Marble Cheddar", "Marbled Cheeses",
-            "Maredsous", "Margotin", "Maribo", "Maroilles", "Mascares",
-            "Mascarpone", "Mascarpone (Australian)", "Mascarpone Torta",
-            "Matocq", "Maytag Blue", "Meira", "Menallack Farmhouse",
-            "Menonita", "Meredith Blue", "Mesost", "Metton (Cancoillotte)",
-            "Meyer Vintage Gouda", "Mihalic Peynir", "Milleens", "Mimolette",
-            "Mine-Gabhar", "Mini Baby Bells", "Mixte", "Molbo",
-            "Monastery Cheeses", "Mondseer", "Mont D'or Lyonnais", "Montasio",
-            "Monterey Jack", "Monterey Jack Dry", "Morbier",
-            "Morbier Cru de Montagne", "Mothais a la Feuille", "Mozzarella",
-            "Mozzarella (Australian)", "Mozzarella di Bufala",
-            "Mozzarella Fresh, in water", "Mozzarella Rolls", "Munster",
-            "Murol", "Mycella", "Myzithra", "Naboulsi", "Nantais",
-            "Neufchatel", "Neufchatel (Australian)", "Niolo", "Nokkelost",
-            "Northumberland", "Oaxaca", "Olde York", "Olivet au Foin",
-            "Olivet Bleu", "Olivet Cendre", "Orkney Extra Mature Cheddar",
-            "Orla", "Oschtjepka", "Ossau Fermier", "Ossau-Iraty", "Oszczypek",
-            "Oxford Blue", "P'tit Berrichon", "Palet de Babligny", "Paneer",
-            "Panela", "Pannerone", "Pant ys Gawn", "Parmesan (Parmigiano)",
-            "Parmigiano Reggiano", "Pas de l'Escalette", "Passendale",
-            "Pasteurized Processed", "Pate de Fromage", "Patefine Fort",
-            "Pave d'Affinois", "Pave d'Auge", "Pave de Chirac",
-            "Pave du Berry", "Pecorino", "Pecorino in Walnut Leaves",
-            "Pecorino Romano", "Peekskill Pyramid", "Pelardon des Cevennes",
-            "Pelardon des Corbieres", "Penamellera", "Penbryn", "Pencarreg",
-            "Perail de Brebis", "Petit Morin", "Petit Pardou", "Petit-Suisse",
-            "Picodon de Chevre", "Picos de Europa", "Piora",
-            "Pithtviers au Foin", "Plateau de Herve", "Plymouth Cheese",
-            "Podhalanski", "Poivre d'Ane", "Polkolbin", "Pont l'Eveque",
-            "Port Nicholson", "Port-Salut", "Postel", "Pouligny-Saint-Pierre",
-            "Pourly", "Prastost", "Pressato", "Prince-Jean",
-            "Processed Cheddar", "Provolone", "Provolone (Australian)",
-            "Pyengana Cheddar", "Pyramide", "Quark", "Quark (Australian)",
-            "Quartirolo Lombardo", "Quatre-Vents", "Quercy Petit",
-            "Queso Blanco", "Queso Blanco con Frutas --Pina y Mango",
-            "Queso de Murcia", "Queso del Montsec", "Queso del Tietar",
-            "Queso Fresco", "Queso Fresco (Adobera)", "Queso Iberico",
-            "Queso Jalapeno", "Queso Majorero", "Queso Media Luna",
-            "Queso Para Frier", "Queso Quesadilla", "Rabacal", "Raclette",
-            "Ragusano", "Raschera", "Reblochon", "Red Leicester",
-            "Regal de la Dombes", "Reggianito", "Remedou", "Requeson",
-            "Richelieu", "Ricotta", "Ricotta (Australian)", "Ricotta Salata",
-            "Ridder", "Rigotte", "Rocamadour", "Rollot", "Romano",
-            "Romans Part Dieu", "Roncal", "Roquefort", "Roule",
-            "Rouleau De Beaulieu", "Royalp Tilsit", "Rubens", "Rustinu",
-            "Saaland Pfarr", "Saanenkaese", "Saga", "Sage Derby",
-            "Sainte Maure", "Saint-Marcellin", "Saint-Nectaire",
-            "Saint-Paulin", "Salers", "Samso", "San Simon", "Sancerre",
-            "Sap Sago", "Sardo", "Sardo Egyptian", "Sbrinz", "Scamorza",
-            "Schabzieger", "Schloss", "Selles sur Cher", "Selva", "Serat",
-            "Seriously Strong Cheddar", "Serra da Estrela", "Sharpam",
-            "Shelburne Cheddar", "Shropshire Blue", "Siraz", "Sirene",
-            "Smoked Gouda", "Somerset Brie", "Sonoma Jack",
-            "Sottocenare al Tartufo", "Soumaintrain", "Sourire Lozerien",
-            "Spenwood", "Sraffordshire Organic", "St. Agur Blue Cheese",
-            "Stilton", "Stinking Bishop", "String", "Sussex Slipcote",
-            "Sveciaost", "Swaledale", "Sweet Style Swiss", "Swiss",
-            "Syrian (Armenian String)", "Tala", "Taleggio", "Tamie",
-            "Tasmania Highland Chevre Log", "Taupiniere", "Teifi", "Telemea",
-            "Testouri", "Tete de Moine", "Tetilla", "Texas Goat Cheese",
-            "Tibet", "Tillamook Cheddar", "Tilsit", "Timboon Brie", "Toma",
-            "Tomme Brulee", "Tomme d'Abondance", "Tomme de Chevre",
-            "Tomme de Romans", "Tomme de Savoie", "Tomme des Chouans",
-            "Tommes", "Torta del Casar", "Toscanello", "Touree de L'Aubier",
-            "Tourmalet", "Trappe (Veritable)", "Trois Cornes De Vendee",
-            "Tronchon", "Trou du Cru", "Truffe", "Tupi", "Turunmaa",
-            "Tymsboro", "Tyn Grug", "Tyning", "Ubriaco", "Ulloa",
-            "Vacherin-Fribourgeois", "Valencay", "Vasterbottenost", "Venaco",
-            "Vendomois", "Vieux Corse", "Vignotte", "Vulscombe",
-            "Waimata Farmhouse Blue", "Washed Rind Cheese (Australian)",
-            "Waterloo", "Weichkaese", "Wellington", "Wensleydale",
-            "White Stilton", "Whitestone Farmhouse", "Wigmore",
-            "Woodside Cabecou", "Xanadu", "Xynotyro", "Yarg Cornish",
-            "Yarra Valley Pyramid", "Yorkshire Blue", "Zamorano",
-            "Zanetti Grana Padano", "Zanetti Parmigiano Reggiano"};
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List2.java b/samples/ApiDemos/src/com/example/android/apis/view/List2.java
deleted file mode 100644
index 4f37dd8..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List2.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.database.Cursor;
-import android.provider.Contacts.People;
-import android.os.Bundle;
-import android.widget.ListAdapter;
-import android.widget.SimpleCursorAdapter;
-
-/**
- * A list view example where the 
- * data comes from a cursor.
- */
-public class List2 extends ListActivity {
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Get a cursor with all people
-        Cursor c = getContentResolver().query(People.CONTENT_URI, null, null, null, null);
-        startManagingCursor(c);
-
-        ListAdapter adapter = new SimpleCursorAdapter(this, 
-                // Use a template that displays a text view
-                android.R.layout.simple_list_item_1, 
-                // Give the cursor to the list adatper
-                c, 
-                // Map the NAME column in the people database to...
-                new String[] {People.NAME} ,
-                // The "text1" view defined in the XML template
-                new int[] {android.R.id.text1}); 
-        setListAdapter(adapter);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List3.java b/samples/ApiDemos/src/com/example/android/apis/view/List3.java
deleted file mode 100644
index 17e59f1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List3.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-
-import android.app.ListActivity;
-import android.database.Cursor;
-import android.os.Bundle;
-import android.provider.Contacts.Phones;
-import android.widget.ListAdapter;
-import android.widget.SimpleCursorAdapter;
-
- /**
- * A list view example where the 
- * data comes from a cursor, and a
- * SimpleCursorListAdapter is used to map each item to a two-line
- * display.
- */
-public class List3 extends ListActivity {
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Get a cursor with all phones
-        Cursor c = getContentResolver().query(Phones.CONTENT_URI, null, null, null, null);
-        startManagingCursor(c);
-        
-        // Map Cursor columns to views defined in simple_list_item_2.xml
-        ListAdapter adapter = new SimpleCursorAdapter(this,
-                android.R.layout.simple_list_item_2, c, 
-                        new String[] { Phones.NAME, Phones.NUMBER }, 
-                        new int[] { android.R.id.text1, android.R.id.text2 });
-        setListAdapter(adapter);
-    }
-  
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List4.java b/samples/ApiDemos/src/com/example/android/apis/view/List4.java
deleted file mode 100644
index 2bd589d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List4.java
+++ /dev/null
@@ -1,374 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-//Need the following import to get access to the app resources, since this
-//class is in a sub-package.
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-
-
-/**
- * A list view example where the data comes from a custom ListAdapter
- */
-public class List4 extends ListActivity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Use our own list adapter
-        setListAdapter(new SpeechListAdapter(this));
-    }
-
-
-    /**
-     * A sample ListAdapter that presents content from arrays of speeches and
-     * text.
-     * 
-     */
-    private class SpeechListAdapter extends BaseAdapter {
-        public SpeechListAdapter(Context context) {
-            mContext = context;
-        }
-
-        /**
-         * The number of items in the list is determined by the number of speeches
-         * in our array.
-         * 
-         * @see android.widget.ListAdapter#getCount()
-         */
-        public int getCount() {
-            return mTitles.length;
-        }
-
-        /**
-         * Since the data comes from an array, just returning the index is
-         * sufficent to get at the data. If we were using a more complex data
-         * structure, we would return whatever object represents one row in the
-         * list.
-         * 
-         * @see android.widget.ListAdapter#getItem(int)
-         */
-        public Object getItem(int position) {
-            return position;
-        }
-
-        /**
-         * Use the array index as a unique id.
-         * 
-         * @see android.widget.ListAdapter#getItemId(int)
-         */
-        public long getItemId(int position) {
-            return position;
-        }
-
-        /**
-         * Make a SpeechView to hold each row.
-         * 
-         * @see android.widget.ListAdapter#getView(int, android.view.View,
-         *      android.view.ViewGroup)
-         */
-        public View getView(int position, View convertView, ViewGroup parent) {
-            SpeechView sv;
-            if (convertView == null) {
-                sv = new SpeechView(mContext, mTitles[position],
-                        mDialogue[position]);
-            } else {
-                sv = (SpeechView) convertView;
-                sv.setTitle(mTitles[position]);
-                sv.setDialogue(mDialogue[position]);
-            }
-
-            return sv;
-        }
-
-        /**
-         * Remember our context so we can use it when constructing views.
-         */
-        private Context mContext;
-        
-        /**
-         * Our data, part 1.
-         */
-        private String[] mTitles = 
-        {
-                "Henry IV (1)",   
-                "Henry V",
-                "Henry VIII",       
-                "Richard II",
-                "Richard III",
-                "Merchant of Venice",  
-                "Othello",
-                "King Lear"
-        };
-        
-        /**
-         * Our data, part 2.
-         */
-        private String[] mDialogue = 
-        {
-                "So shaken as we are, so wan with care," +
-                "Find we a time for frighted peace to pant," +
-                "And breathe short-winded accents of new broils" +
-                "To be commenced in strands afar remote." +
-                "No more the thirsty entrance of this soil" +
-                "Shall daub her lips with her own children's blood;" +
-                "Nor more shall trenching war channel her fields," +
-                "Nor bruise her flowerets with the armed hoofs" +
-                "Of hostile paces: those opposed eyes," +
-                "Which, like the meteors of a troubled heaven," +
-                "All of one nature, of one substance bred," +
-                "Did lately meet in the intestine shock" +
-                "And furious close of civil butchery" +
-                "Shall now, in mutual well-beseeming ranks," +
-                "March all one way and be no more opposed" +
-                "Against acquaintance, kindred and allies:" +
-                "The edge of war, like an ill-sheathed knife," +
-                "No more shall cut his master. Therefore, friends," +
-                "As far as to the sepulchre of Christ," +
-                "Whose soldier now, under whose blessed cross" +
-                "We are impressed and engaged to fight," +
-                "Forthwith a power of English shall we levy;" +
-                "Whose arms were moulded in their mothers' womb" +
-                "To chase these pagans in those holy fields" +
-                "Over whose acres walk'd those blessed feet" +
-                "Which fourteen hundred years ago were nail'd" +
-                "For our advantage on the bitter cross." +
-                "But this our purpose now is twelve month old," +
-                "And bootless 'tis to tell you we will go:" +
-                "Therefore we meet not now. Then let me hear" +
-                "Of you, my gentle cousin Westmoreland," +
-                "What yesternight our council did decree" +
-                "In forwarding this dear expedience.",
-                
-                "Hear him but reason in divinity," + 
-                "And all-admiring with an inward wish" + 
-                "You would desire the king were made a prelate:" + 
-                "Hear him debate of commonwealth affairs," + 
-                "You would say it hath been all in all his study:" + 
-                "List his discourse of war, and you shall hear" + 
-                "A fearful battle render'd you in music:" + 
-                "Turn him to any cause of policy," + 
-                "The Gordian knot of it he will unloose," + 
-                "Familiar as his garter: that, when he speaks," + 
-                "The air, a charter'd libertine, is still," + 
-                "And the mute wonder lurketh in men's ears," + 
-                "To steal his sweet and honey'd sentences;" + 
-                "So that the art and practic part of life" + 
-                "Must be the mistress to this theoric:" + 
-                "Which is a wonder how his grace should glean it," + 
-                "Since his addiction was to courses vain," + 
-                "His companies unletter'd, rude and shallow," + 
-                "His hours fill'd up with riots, banquets, sports," + 
-                "And never noted in him any study," + 
-                "Any retirement, any sequestration" + 
-                "From open haunts and popularity.",
-
-                "I come no more to make you laugh: things now," +
-                "That bear a weighty and a serious brow," +
-                "Sad, high, and working, full of state and woe," +
-                "Such noble scenes as draw the eye to flow," +
-                "We now present. Those that can pity, here" +
-                "May, if they think it well, let fall a tear;" +
-                "The subject will deserve it. Such as give" +
-                "Their money out of hope they may believe," +
-                "May here find truth too. Those that come to see" +
-                "Only a show or two, and so agree" +
-                "The play may pass, if they be still and willing," +
-                "I'll undertake may see away their shilling" +
-                "Richly in two short hours. Only they" +
-                "That come to hear a merry bawdy play," +
-                "A noise of targets, or to see a fellow" +
-                "In a long motley coat guarded with yellow," +
-                "Will be deceived; for, gentle hearers, know," +
-                "To rank our chosen truth with such a show" +
-                "As fool and fight is, beside forfeiting" +
-                "Our own brains, and the opinion that we bring," +
-                "To make that only true we now intend," +
-                "Will leave us never an understanding friend." +
-                "Therefore, for goodness' sake, and as you are known" +
-                "The first and happiest hearers of the town," +
-                "Be sad, as we would make ye: think ye see" +
-                "The very persons of our noble story" +
-                "As they were living; think you see them great," +
-                "And follow'd with the general throng and sweat" +
-                "Of thousand friends; then in a moment, see" +
-                "How soon this mightiness meets misery:" +
-                "And, if you can be merry then, I'll say" +
-                "A man may weep upon his wedding-day.",
-                
-                "First, heaven be the record to my speech!" + 
-                "In the devotion of a subject's love," + 
-                "Tendering the precious safety of my prince," + 
-                "And free from other misbegotten hate," + 
-                "Come I appellant to this princely presence." + 
-                "Now, Thomas Mowbray, do I turn to thee," + 
-                "And mark my greeting well; for what I speak" + 
-                "My body shall make good upon this earth," + 
-                "Or my divine soul answer it in heaven." + 
-                "Thou art a traitor and a miscreant," + 
-                "Too good to be so and too bad to live," + 
-                "Since the more fair and crystal is the sky," + 
-                "The uglier seem the clouds that in it fly." + 
-                "Once more, the more to aggravate the note," + 
-                "With a foul traitor's name stuff I thy throat;" + 
-                "And wish, so please my sovereign, ere I move," + 
-                "What my tongue speaks my right drawn sword may prove.",
-                
-                "Now is the winter of our discontent" + 
-                "Made glorious summer by this sun of York;" + 
-                "And all the clouds that lour'd upon our house" + 
-                "In the deep bosom of the ocean buried." + 
-                "Now are our brows bound with victorious wreaths;" + 
-                "Our bruised arms hung up for monuments;" + 
-                "Our stern alarums changed to merry meetings," + 
-                "Our dreadful marches to delightful measures." + 
-                "Grim-visaged war hath smooth'd his wrinkled front;" + 
-                "And now, instead of mounting barded steeds" + 
-                "To fright the souls of fearful adversaries," + 
-                "He capers nimbly in a lady's chamber" + 
-                "To the lascivious pleasing of a lute." + 
-                "But I, that am not shaped for sportive tricks," + 
-                "Nor made to court an amorous looking-glass;" + 
-                "I, that am rudely stamp'd, and want love's majesty" + 
-                "To strut before a wanton ambling nymph;" + 
-                "I, that am curtail'd of this fair proportion," + 
-                "Cheated of feature by dissembling nature," + 
-                "Deformed, unfinish'd, sent before my time" + 
-                "Into this breathing world, scarce half made up," + 
-                "And that so lamely and unfashionable" + 
-                "That dogs bark at me as I halt by them;" + 
-                "Why, I, in this weak piping time of peace," + 
-                "Have no delight to pass away the time," + 
-                "Unless to spy my shadow in the sun" + 
-                "And descant on mine own deformity:" + 
-                "And therefore, since I cannot prove a lover," + 
-                "To entertain these fair well-spoken days," + 
-                "I am determined to prove a villain" + 
-                "And hate the idle pleasures of these days." + 
-                "Plots have I laid, inductions dangerous," + 
-                "By drunken prophecies, libels and dreams," + 
-                "To set my brother Clarence and the king" + 
-                "In deadly hate the one against the other:" + 
-                "And if King Edward be as true and just" + 
-                "As I am subtle, false and treacherous," + 
-                "This day should Clarence closely be mew'd up," + 
-                "About a prophecy, which says that 'G'" + 
-                "Of Edward's heirs the murderer shall be." + 
-                "Dive, thoughts, down to my soul: here" + 
-                "Clarence comes.",
-                
-                "To bait fish withal: if it will feed nothing else," + 
-                "it will feed my revenge. He hath disgraced me, and" + 
-                "hindered me half a million; laughed at my losses," + 
-                "mocked at my gains, scorned my nation, thwarted my" + 
-                "bargains, cooled my friends, heated mine" + 
-                "enemies; and what's his reason? I am a Jew. Hath" + 
-                "not a Jew eyes? hath not a Jew hands, organs," + 
-                "dimensions, senses, affections, passions? fed with" + 
-                "the same food, hurt with the same weapons, subject" + 
-                "to the same diseases, healed by the same means," + 
-                "warmed and cooled by the same winter and summer, as" + 
-                "a Christian is? If you prick us, do we not bleed?" + 
-                "if you tickle us, do we not laugh? if you poison" + 
-                "us, do we not die? and if you wrong us, shall we not" + 
-                "revenge? If we are like you in the rest, we will" + 
-                "resemble you in that. If a Jew wrong a Christian," + 
-                "what is his humility? Revenge. If a Christian" + 
-                "wrong a Jew, what should his sufferance be by" + 
-                "Christian example? Why, revenge. The villany you" + 
-                "teach me, I will execute, and it shall go hard but I" + 
-                "will better the instruction.",
-                
-                "Virtue! a fig! 'tis in ourselves that we are thus" + 
-                "or thus. Our bodies are our gardens, to the which" + 
-                "our wills are gardeners: so that if we will plant" + 
-                "nettles, or sow lettuce, set hyssop and weed up" + 
-                "thyme, supply it with one gender of herbs, or" + 
-                "distract it with many, either to have it sterile" + 
-                "with idleness, or manured with industry, why, the" + 
-                "power and corrigible authority of this lies in our" + 
-                "wills. If the balance of our lives had not one" + 
-                "scale of reason to poise another of sensuality, the" + 
-                "blood and baseness of our natures would conduct us" + 
-                "to most preposterous conclusions: but we have" + 
-                "reason to cool our raging motions, our carnal" + 
-                "stings, our unbitted lusts, whereof I take this that" + 
-                "you call love to be a sect or scion.",
-
-                "Blow, winds, and crack your cheeks! rage! blow!" + 
-                "You cataracts and hurricanoes, spout" + 
-                "Till you have drench'd our steeples, drown'd the cocks!" + 
-                "You sulphurous and thought-executing fires," + 
-                "Vaunt-couriers to oak-cleaving thunderbolts," + 
-                "Singe my white head! And thou, all-shaking thunder," + 
-                "Smite flat the thick rotundity o' the world!" + 
-                "Crack nature's moulds, an germens spill at once," + 
-                "That make ingrateful man!"
-        };
-    }
-    
-    /**
-     * We will use a SpeechView to display each speech. It's just a LinearLayout
-     * with two text fields.
-     *
-     */
-    private class SpeechView extends LinearLayout {
-        public SpeechView(Context context, String title, String words) {
-            super(context);
-
-            this.setOrientation(VERTICAL);
-
-            // Here we build the child views in code. They could also have
-            // been specified in an XML file.
-
-            mTitle = new TextView(context);
-            mTitle.setText(title);
-            addView(mTitle, new LinearLayout.LayoutParams(
-                    LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
-
-            mDialogue = new TextView(context);
-            mDialogue.setText(words);
-            addView(mDialogue, new LinearLayout.LayoutParams(
-                    LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
-        }
-
-        /**
-         * Convenience method to set the title of a SpeechView
-         */
-        public void setTitle(String title) {
-            mTitle.setText(title);
-        }
-
-        /**
-         * Convenience method to set the dialogue of a SpeechView
-         */
-        public void setDialogue(String words) {
-            mDialogue.setText(words);
-        }
-
-        private TextView mTitle;
-        private TextView mDialogue;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List5.java b/samples/ApiDemos/src/com/example/android/apis/view/List5.java
deleted file mode 100644
index 72a8b82..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List5.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.BaseAdapter;
-import android.widget.TextView;
-
-
-/**
- * A list view example with separators.
- */
-public class List5 extends ListActivity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setListAdapter(new MyListAdapter(this));
-    }
-
-    private class MyListAdapter extends BaseAdapter {
-        public MyListAdapter(Context context) {
-            mContext = context;
-        }
-
-        public int getCount() {
-            return mStrings.length;
-        }
-
-        public boolean areAllItemsEnabled() {
-            return false;
-        }
-
-        public boolean isEnabled(int position) {
-            return !mStrings[position].startsWith("-");
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            TextView tv;
-            if (convertView == null) {
-                tv = (TextView) LayoutInflater.from(mContext).inflate(
-                        android.R.layout.simple_expandable_list_item_1, parent, false);
-            } else {
-                tv = (TextView) convertView;
-            }
-            tv.setText(mStrings[position]);
-            return tv;
-        }
-
-        private Context mContext;
-    }
-    
-    private String[] mStrings = {
-            "----------",
-            "----------",
-            "Abbaye de Belloc",
-            "Abbaye du Mont des Cats",
-            "Abertam",
-            "----------",
-            "Abondance",
-            "----------",
-            "Ackawi",
-            "Acorn",
-            "Adelost",
-            "Affidelice au Chablis",
-            "Afuega'l Pitu",
-            "Airag",
-            "----------",
-            "Airedale",
-            "Aisy Cendre",
-            "----------",
-            "Allgauer Emmentaler",
-            "Alverca",
-            "Ambert",
-            "American Cheese",
-            "Ami du Chambertin",
-            "----------",
-            "----------",
-            "Anejo Enchilado",
-            "Anneau du Vic-Bilh",
-            "Anthoriro",
-            "----------",
-            "----------"
-    };
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List6.java b/samples/ApiDemos/src/com/example/android/apis/view/List6.java
deleted file mode 100644
index 9bb5b14..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List6.java
+++ /dev/null
@@ -1,410 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.LinearLayout;
-import android.widget.ListView;
-import android.widget.TextView;
-
-
-/**
- * A list view example where the 
- * data comes from a custom
- * ListAdapter
- */
-public class List6 extends ListActivity 
-{
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-        
-        // Use our own list adapter
-        setListAdapter(new SpeechListAdapter(this));
-    }
-        
-    
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) 
-    {    
-       ((SpeechListAdapter)getListAdapter()).toggle(position);
-    }
-    
-    /**
-     * A sample ListAdapter that presents content
-     * from arrays of speeches and text.
-     *
-     */
-    private class SpeechListAdapter extends BaseAdapter {
-        public SpeechListAdapter(Context context)
-        {
-            mContext = context;
-        }
-
-        
-        /**
-         * The number of items in the list is determined by the number of speeches
-         * in our array.
-         * 
-         * @see android.widget.ListAdapter#getCount()
-         */
-        public int getCount() {
-            return mTitles.length;
-        }
-
-        /**
-         * Since the data comes from an array, just returning
-         * the index is sufficent to get at the data. If we
-         * were using a more complex data structure, we
-         * would return whatever object represents one 
-         * row in the list.
-         * 
-         * @see android.widget.ListAdapter#getItem(int)
-         */
-        public Object getItem(int position) {
-            return position;
-        }
-
-        /**
-         * Use the array index as a unique id.
-         * @see android.widget.ListAdapter#getItemId(int)
-         */
-        public long getItemId(int position) {
-            return position;
-        }
-
-        /**
-         * Make a SpeechView to hold each row.
-         * @see android.widget.ListAdapter#getView(int, android.view.View, android.view.ViewGroup)
-         */
-        public View getView(int position, View convertView, ViewGroup parent) {
-            SpeechView sv;
-            if (convertView == null) {
-                sv = new SpeechView(mContext, mTitles[position], mDialogue[position], mExpanded[position]);
-            } else {
-                sv = (SpeechView)convertView;
-                sv.setTitle(mTitles[position]);
-                sv.setDialogue(mDialogue[position]);
-                sv.setExpanded(mExpanded[position]);
-            }
-            
-            return sv;
-        }
-
-        public void toggle(int position) {
-            mExpanded[position] = !mExpanded[position];
-            notifyDataSetChanged();
-        }
-        
-        /**
-         * Remember our context so we can use it when constructing views.
-         */
-        private Context mContext;
-        
-        /**
-         * Our data, part 1.
-         */
-        private String[] mTitles = 
-        {
-                "Henry IV (1)",   
-                "Henry V",
-                "Henry VIII",       
-                "Richard II",
-                "Richard III",
-                "Merchant of Venice",  
-                "Othello",
-                "King Lear"
-        };
-        
-        /**
-         * Our data, part 2.
-         */
-        private String[] mDialogue = 
-        {
-                "So shaken as we are, so wan with care," +
-                "Find we a time for frighted peace to pant," +
-                "And breathe short-winded accents of new broils" +
-                "To be commenced in strands afar remote." +
-                "No more the thirsty entrance of this soil" +
-                "Shall daub her lips with her own children's blood;" +
-                "Nor more shall trenching war channel her fields," +
-                "Nor bruise her flowerets with the armed hoofs" +
-                "Of hostile paces: those opposed eyes," +
-                "Which, like the meteors of a troubled heaven," +
-                "All of one nature, of one substance bred," +
-                "Did lately meet in the intestine shock" +
-                "And furious close of civil butchery" +
-                "Shall now, in mutual well-beseeming ranks," +
-                "March all one way and be no more opposed" +
-                "Against acquaintance, kindred and allies:" +
-                "The edge of war, like an ill-sheathed knife," +
-                "No more shall cut his master. Therefore, friends," +
-                "As far as to the sepulchre of Christ," +
-                "Whose soldier now, under whose blessed cross" +
-                "We are impressed and engaged to fight," +
-                "Forthwith a power of English shall we levy;" +
-                "Whose arms were moulded in their mothers' womb" +
-                "To chase these pagans in those holy fields" +
-                "Over whose acres walk'd those blessed feet" +
-                "Which fourteen hundred years ago were nail'd" +
-                "For our advantage on the bitter cross." +
-                "But this our purpose now is twelve month old," +
-                "And bootless 'tis to tell you we will go:" +
-                "Therefore we meet not now. Then let me hear" +
-                "Of you, my gentle cousin Westmoreland," +
-                "What yesternight our council did decree" +
-                "In forwarding this dear expedience.",
-                
-                "Hear him but reason in divinity," + 
-                "And all-admiring with an inward wish" + 
-                "You would desire the king were made a prelate:" + 
-                "Hear him debate of commonwealth affairs," + 
-                "You would say it hath been all in all his study:" + 
-                "List his discourse of war, and you shall hear" + 
-                "A fearful battle render'd you in music:" + 
-                "Turn him to any cause of policy," + 
-                "The Gordian knot of it he will unloose," + 
-                "Familiar as his garter: that, when he speaks," + 
-                "The air, a charter'd libertine, is still," + 
-                "And the mute wonder lurketh in men's ears," + 
-                "To steal his sweet and honey'd sentences;" + 
-                "So that the art and practic part of life" + 
-                "Must be the mistress to this theoric:" + 
-                "Which is a wonder how his grace should glean it," + 
-                "Since his addiction was to courses vain," + 
-                "His companies unletter'd, rude and shallow," + 
-                "His hours fill'd up with riots, banquets, sports," + 
-                "And never noted in him any study," + 
-                "Any retirement, any sequestration" + 
-                "From open haunts and popularity.",
-
-                "I come no more to make you laugh: things now," +
-                "That bear a weighty and a serious brow," +
-                "Sad, high, and working, full of state and woe," +
-                "Such noble scenes as draw the eye to flow," +
-                "We now present. Those that can pity, here" +
-                "May, if they think it well, let fall a tear;" +
-                "The subject will deserve it. Such as give" +
-                "Their money out of hope they may believe," +
-                "May here find truth too. Those that come to see" +
-                "Only a show or two, and so agree" +
-                "The play may pass, if they be still and willing," +
-                "I'll undertake may see away their shilling" +
-                "Richly in two short hours. Only they" +
-                "That come to hear a merry bawdy play," +
-                "A noise of targets, or to see a fellow" +
-                "In a long motley coat guarded with yellow," +
-                "Will be deceived; for, gentle hearers, know," +
-                "To rank our chosen truth with such a show" +
-                "As fool and fight is, beside forfeiting" +
-                "Our own brains, and the opinion that we bring," +
-                "To make that only true we now intend," +
-                "Will leave us never an understanding friend." +
-                "Therefore, for goodness' sake, and as you are known" +
-                "The first and happiest hearers of the town," +
-                "Be sad, as we would make ye: think ye see" +
-                "The very persons of our noble story" +
-                "As they were living; think you see them great," +
-                "And follow'd with the general throng and sweat" +
-                "Of thousand friends; then in a moment, see" +
-                "How soon this mightiness meets misery:" +
-                "And, if you can be merry then, I'll say" +
-                "A man may weep upon his wedding-day.",
-                
-                "First, heaven be the record to my speech!" + 
-                "In the devotion of a subject's love," + 
-                "Tendering the precious safety of my prince," + 
-                "And free from other misbegotten hate," + 
-                "Come I appellant to this princely presence." + 
-                "Now, Thomas Mowbray, do I turn to thee," + 
-                "And mark my greeting well; for what I speak" + 
-                "My body shall make good upon this earth," + 
-                "Or my divine soul answer it in heaven." + 
-                "Thou art a traitor and a miscreant," + 
-                "Too good to be so and too bad to live," + 
-                "Since the more fair and crystal is the sky," + 
-                "The uglier seem the clouds that in it fly." + 
-                "Once more, the more to aggravate the note," + 
-                "With a foul traitor's name stuff I thy throat;" + 
-                "And wish, so please my sovereign, ere I move," + 
-                "What my tongue speaks my right drawn sword may prove.",
-                
-                "Now is the winter of our discontent" + 
-                "Made glorious summer by this sun of York;" + 
-                "And all the clouds that lour'd upon our house" + 
-                "In the deep bosom of the ocean buried." + 
-                "Now are our brows bound with victorious wreaths;" + 
-                "Our bruised arms hung up for monuments;" + 
-                "Our stern alarums changed to merry meetings," + 
-                "Our dreadful marches to delightful measures." + 
-                "Grim-visaged war hath smooth'd his wrinkled front;" + 
-                "And now, instead of mounting barded steeds" + 
-                "To fright the souls of fearful adversaries," + 
-                "He capers nimbly in a lady's chamber" + 
-                "To the lascivious pleasing of a lute." + 
-                "But I, that am not shaped for sportive tricks," + 
-                "Nor made to court an amorous looking-glass;" + 
-                "I, that am rudely stamp'd, and want love's majesty" + 
-                "To strut before a wanton ambling nymph;" + 
-                "I, that am curtail'd of this fair proportion," + 
-                "Cheated of feature by dissembling nature," + 
-                "Deformed, unfinish'd, sent before my time" + 
-                "Into this breathing world, scarce half made up," + 
-                "And that so lamely and unfashionable" + 
-                "That dogs bark at me as I halt by them;" + 
-                "Why, I, in this weak piping time of peace," + 
-                "Have no delight to pass away the time," + 
-                "Unless to spy my shadow in the sun" + 
-                "And descant on mine own deformity:" + 
-                "And therefore, since I cannot prove a lover," + 
-                "To entertain these fair well-spoken days," + 
-                "I am determined to prove a villain" + 
-                "And hate the idle pleasures of these days." + 
-                "Plots have I laid, inductions dangerous," + 
-                "By drunken prophecies, libels and dreams," + 
-                "To set my brother Clarence and the king" + 
-                "In deadly hate the one against the other:" + 
-                "And if King Edward be as true and just" + 
-                "As I am subtle, false and treacherous," + 
-                "This day should Clarence closely be mew'd up," + 
-                "About a prophecy, which says that 'G'" + 
-                "Of Edward's heirs the murderer shall be." + 
-                "Dive, thoughts, down to my soul: here" + 
-                "Clarence comes.",
-                
-                "To bait fish withal: if it will feed nothing else," + 
-                "it will feed my revenge. He hath disgraced me, and" + 
-                "hindered me half a million; laughed at my losses," + 
-                "mocked at my gains, scorned my nation, thwarted my" + 
-                "bargains, cooled my friends, heated mine" + 
-                "enemies; and what's his reason? I am a Jew. Hath" + 
-                "not a Jew eyes? hath not a Jew hands, organs," + 
-                "dimensions, senses, affections, passions? fed with" + 
-                "the same food, hurt with the same weapons, subject" + 
-                "to the same diseases, healed by the same means," + 
-                "warmed and cooled by the same winter and summer, as" + 
-                "a Christian is? If you prick us, do we not bleed?" + 
-                "if you tickle us, do we not laugh? if you poison" + 
-                "us, do we not die? and if you wrong us, shall we not" + 
-                "revenge? If we are like you in the rest, we will" + 
-                "resemble you in that. If a Jew wrong a Christian," + 
-                "what is his humility? Revenge. If a Christian" + 
-                "wrong a Jew, what should his sufferance be by" + 
-                "Christian example? Why, revenge. The villany you" + 
-                "teach me, I will execute, and it shall go hard but I" + 
-                "will better the instruction.",
-                
-                "Virtue! a fig! 'tis in ourselves that we are thus" + 
-                "or thus. Our bodies are our gardens, to the which" + 
-                "our wills are gardeners: so that if we will plant" + 
-                "nettles, or sow lettuce, set hyssop and weed up" + 
-                "thyme, supply it with one gender of herbs, or" + 
-                "distract it with many, either to have it sterile" + 
-                "with idleness, or manured with industry, why, the" + 
-                "power and corrigible authority of this lies in our" + 
-                "wills. If the balance of our lives had not one" + 
-                "scale of reason to poise another of sensuality, the" + 
-                "blood and baseness of our natures would conduct us" + 
-                "to most preposterous conclusions: but we have" + 
-                "reason to cool our raging motions, our carnal" + 
-                "stings, our unbitted lusts, whereof I take this that" + 
-                "you call love to be a sect or scion.",
-
-                "Blow, winds, and crack your cheeks! rage! blow!" + 
-                "You cataracts and hurricanoes, spout" + 
-                "Till you have drench'd our steeples, drown'd the cocks!" + 
-                "You sulphurous and thought-executing fires," + 
-                "Vaunt-couriers to oak-cleaving thunderbolts," + 
-                "Singe my white head! And thou, all-shaking thunder," + 
-                "Smite flat the thick rotundity o' the world!" + 
-                "Crack nature's moulds, an germens spill at once," + 
-                "That make ingrateful man!"
-        };
-        
-        /**
-         * Our data, part 3.
-         */
-        private boolean[] mExpanded = 
-        {
-                false,
-                false,
-                false,
-                false,
-                false,
-                false,
-                false,
-                false   
-        };
-    }
-    
-    /**
-     * We will use a SpeechView to display each speech. It's just a LinearLayout
-     * with two text fields.
-     *
-     */
-    private class SpeechView extends LinearLayout {
-        public SpeechView(Context context, String title, String dialogue, boolean expanded) {
-            super(context);
-            
-            this.setOrientation(VERTICAL);
-            
-            // Here we build the child views in code. They could also have
-            // been specified in an XML file.
-            
-            mTitle = new TextView(context);
-            mTitle.setText(title);
-            addView(mTitle, new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
-            
-            mDialogue = new TextView(context);
-            mDialogue.setText(dialogue);
-            addView(mDialogue, new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
-            
-            mDialogue.setVisibility(expanded ? VISIBLE : GONE);
-        }
-        
-        /**
-         * Convenience method to set the title of a SpeechView
-         */
-        public void setTitle(String title) {
-            mTitle.setText(title);
-        }
-        
-        /**
-         * Convenience method to set the dialogue of a SpeechView
-         */
-        public void setDialogue(String words) {
-            mDialogue.setText(words);
-        }
-        
-        /**
-         * Convenience method to expand or hide the dialogue
-         */
-        public void setExpanded(boolean expanded) {
-            mDialogue.setVisibility(expanded ? VISIBLE : GONE);
-        }
-        
-        private TextView mTitle;
-        private TextView mDialogue;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List7.java b/samples/ApiDemos/src/com/example/android/apis/view/List7.java
deleted file mode 100644
index d44ed56..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List7.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-
-import android.app.ListActivity;
-import android.database.Cursor;
-import android.provider.Contacts.People;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.AdapterView;
-import android.widget.AdapterView.OnItemSelectedListener;
-import android.widget.ListAdapter;
-import android.widget.SimpleCursorAdapter;
-import android.widget.TextView;
-
-/**
- * A list view example where the data comes from a cursor.
- */
-public class List7 extends ListActivity implements OnItemSelectedListener {
-    private static String[] PROJECTION = new String[] {
-        People._ID, People.NAME, People.NUMBER
-    };
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.list_7);
-        mPhone = (TextView) findViewById(R.id.phone);
-        getListView().setOnItemSelectedListener(this);
-
-        // Get a cursor with all people
-        Cursor c = getContentResolver().query(People.CONTENT_URI, PROJECTION, null, null, null);
-        startManagingCursor(c);
-        mPhoneColumnIndex = c.getColumnIndex(People.NUMBER);
-
-        ListAdapter adapter = new SimpleCursorAdapter(this,
-                android.R.layout.simple_list_item_1, // Use a template
-                                                        // that displays a
-                                                        // text view
-                c, // Give the cursor to the list adatper
-                new String[] {People.NAME}, // Map the NAME column in the
-                                            // people database to...
-                new int[] {android.R.id.text1}); // The "text1" view defined in
-                                            // the XML template
-        setListAdapter(adapter);
-    }
-
-    public void onItemSelected(AdapterView parent, View v, int position, long id) {
-        if (position >= 0) {
-            Cursor c = (Cursor) parent.getItemAtPosition(position);
-            mPhone.setText(c.getString(mPhoneColumnIndex));
-        }
-    }
-
-    public void onNothingSelected(AdapterView parent) {
-        mPhone.setText(R.string.list_7_nothing);
-
-    }
-
-    private int mPhoneColumnIndex;
-    private TextView mPhone;
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List8.java b/samples/ApiDemos/src/com/example/android/apis/view/List8.java
deleted file mode 100644
index 1a54aa7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List8.java
+++ /dev/null
@@ -1,133 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.os.Bundle;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.ViewGroup.LayoutParams;
-import android.widget.BaseAdapter;
-import android.widget.Button;
-import android.widget.ImageView;
-import android.widget.AbsListView;
-
-import java.util.ArrayList;
-
-
-/**
- * A list view that demonstrates the use of setEmptyView. This example alos uses
- * a custom layout file that adds some extra buttons to the screen.
- */
-public class List8 extends ListActivity {
-
-    PhotoAdapter mAdapter;
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Use a custom layout file
-        setContentView(R.layout.list_8);
-        
-        // Tell the list view which view to display when the list is empty
-        getListView().setEmptyView(findViewById(R.id.empty));
-        
-        // Set up our adapter
-        mAdapter = new PhotoAdapter(this);
-        setListAdapter(mAdapter);
-        
-        // Wire up the clear button to remove all photos
-        Button clear = (Button) findViewById(R.id.clear);
-        clear.setOnClickListener(new View.OnClickListener() {
-
-            public void onClick(View v) {
-                mAdapter.clearPhotos();
-            } });
-        
-        // Wire up the add button to add a new photo
-        Button add = (Button) findViewById(R.id.add);
-        add.setOnClickListener(new View.OnClickListener() {
-
-            public void onClick(View v) {
-                mAdapter.addPhotos();
-            } });
-    }
-
-    /**
-     * A simple adapter which maintains an ArrayList of photo resource Ids. 
-     * Each photo is displayed as an image. This adapter supports clearing the
-     * list of photos and adding a new photo.
-     *
-     */
-    public class PhotoAdapter extends BaseAdapter {
-
-        private Integer[] mPhotoPool = {
-                R.drawable.sample_thumb_0, R.drawable.sample_thumb_1, R.drawable.sample_thumb_2,
-                R.drawable.sample_thumb_3, R.drawable.sample_thumb_4, R.drawable.sample_thumb_5,
-                R.drawable.sample_thumb_6, R.drawable.sample_thumb_7};
-
-        private ArrayList<Integer> mPhotos = new ArrayList<Integer>();
-        
-        public PhotoAdapter(Context c) {
-            mContext = c;
-        }
-
-        public int getCount() {
-            return mPhotos.size();
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(int position, View convertView, ViewGroup parent) {
-            // Make an ImageView to show a photo
-            ImageView i = new ImageView(mContext);
-
-            i.setImageResource(mPhotos.get(position));
-            i.setAdjustViewBounds(true);
-            i.setLayoutParams(new AbsListView.LayoutParams(LayoutParams.WRAP_CONTENT,
-                    LayoutParams.WRAP_CONTENT));
-            // Give it a nice background
-            i.setBackgroundResource(R.drawable.picture_frame);
-            return i;
-        }
-
-        private Context mContext;
-
-        public void clearPhotos() {
-            mPhotos.clear();
-            notifyDataSetChanged();
-        }
-        
-        public void addPhotos() {
-            int whichPhoto = (int)Math.round(Math.random() * (mPhotoPool.length - 1));
-            int newPhoto = mPhotoPool[whichPhoto];
-            mPhotos.add(newPhoto);
-            notifyDataSetChanged();
-        }
-
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/List9.java b/samples/ApiDemos/src/com/example/android/apis/view/List9.java
deleted file mode 100644
index 15b3cc1..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/List9.java
+++ /dev/null
@@ -1,320 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.graphics.PixelFormat;
-import android.os.Bundle;
-import android.os.Handler;
-import android.view.View;
-import android.view.LayoutInflater;
-import android.view.WindowManager;
-import android.view.WindowManager.LayoutParams;
-import android.widget.AbsListView;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-
-
-/**
- * Another variation of the list of cheeses. In this case, we use
- * {@link AbsListView#setOnScrollListener(AbsListView.OnScrollListener) 
- * AbsListView#setOnItemScrollListener(AbsListView.OnItemScrollListener)} to display the
- * first letter of the visible range of cheeses.
- */
-public class List9 extends ListActivity implements ListView.OnScrollListener {
-
-    private final class RemoveWindow implements Runnable {
-        public void run() {
-            removeWindow();
-        }
-    }
-
-    private RemoveWindow mRemoveWindow = new RemoveWindow();
-    Handler mHandler = new Handler();
-    private WindowManager mWindowManager;
-    private TextView mDialogText;
-    private boolean mShowing;
-    private boolean mReady;
-    private char mPrevLetter = Character.MIN_VALUE;
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        mWindowManager = (WindowManager)getSystemService(Context.WINDOW_SERVICE);
-        
-        // Use an existing ListAdapter that will map an array
-        // of strings to TextViews
-        setListAdapter(new ArrayAdapter<String>(this,
-                android.R.layout.simple_list_item_1, mStrings));
-        
-        getListView().setOnScrollListener(this);
-        
-        LayoutInflater inflate = (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        
-        mDialogText = (TextView) inflate.inflate(R.layout.list_position, null);
-        mDialogText.setVisibility(View.INVISIBLE);
-        
-        mHandler.post(new Runnable() {
-
-            public void run() {
-                mReady = true;
-                WindowManager.LayoutParams lp = new WindowManager.LayoutParams(
-                        LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT,
-                        WindowManager.LayoutParams.TYPE_APPLICATION,
-                        WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE
-                                | WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE,
-                        PixelFormat.TRANSLUCENT);
-                mWindowManager.addView(mDialogText, lp);
-            }});
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mReady = true;
-    }
-
-    
-    @Override
-    protected void onPause() {
-        super.onPause();
-        removeWindow();
-        mReady = false;
-    }
-
-    @Override
-    protected void onDestroy() {
-        super.onDestroy();
-        mWindowManager.removeView(mDialogText);
-        mReady = false;
-    }
-
-    
-   
-    
-    public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount) {
-        int lastItem = firstVisibleItem + visibleItemCount - 1;
-        if (mReady) {
-            char firstLetter = mStrings[firstVisibleItem].charAt(0);
-            
-            if (!mShowing && firstLetter != mPrevLetter) {
-
-                mShowing = true;
-                mDialogText.setVisibility(View.VISIBLE);
-               
-
-            }
-            mDialogText.setText(((Character)firstLetter).toString());
-            mHandler.removeCallbacks(mRemoveWindow);
-            mHandler.postDelayed(mRemoveWindow, 3000);
-            mPrevLetter = firstLetter;
-        }
-    }
-    
-
-    public void onScrollStateChanged(AbsListView view, int scrollState) {
-    }
-    
-    
-    private void removeWindow() {
-        if (mShowing) {
-            mShowing = false;
-            mDialogText.setVisibility(View.INVISIBLE);
-        }
-    }
-
-    private String[] mStrings = {
-            "Abbaye de Belloc", "Abbaye du Mont des Cats", "Abertam",
-            "Abondance", "Ackawi", "Acorn", "Adelost", "Affidelice au Chablis",
-            "Afuega'l Pitu", "Airag", "Airedale", "Aisy Cendre",
-            "Allgauer Emmentaler", "Alverca", "Ambert", "American Cheese",
-            "Ami du Chambertin", "Anejo Enchilado", "Anneau du Vic-Bilh",
-            "Anthoriro", "Appenzell", "Aragon", "Ardi Gasna", "Ardrahan",
-            "Armenian String", "Aromes au Gene de Marc", "Asadero", "Asiago",
-            "Aubisque Pyrenees", "Autun", "Avaxtskyr", "Baby Swiss", "Babybel",
-            "Baguette Laonnaise", "Bakers", "Baladi", "Balaton", "Bandal",
-            "Banon", "Barry's Bay Cheddar", "Basing", "Basket Cheese",
-            "Bath Cheese", "Bavarian Bergkase", "Baylough", "Beaufort",
-            "Beauvoorde", "Beenleigh Blue", "Beer Cheese", "Bel Paese",
-            "Bergader", "Bergere Bleue", "Berkswell", "Beyaz Peynir",
-            "Bierkase", "Bishop Kennedy", "Blarney", "Bleu d'Auvergne",
-            "Bleu de Gex", "Bleu de Laqueuille", "Bleu de Septmoncel",
-            "Bleu Des Causses", "Blue", "Blue Castello", "Blue Rathgore",
-            "Blue Vein (Australian)", "Blue Vein Cheeses", "Bocconcini",
-            "Bocconcini (Australian)", "Boeren Leidenkaas", "Bonchester",
-            "Bosworth", "Bougon", "Boule Du Roves", "Boulette d'Avesnes",
-            "Boursault", "Boursin", "Bouyssou", "Bra", "Braudostur",
-            "Breakfast Cheese", "Brebis du Lavort", "Brebis du Lochois",
-            "Brebis du Puyfaucon", "Bresse Bleu", "Brick", "Brie",
-            "Brie de Meaux", "Brie de Melun", "Brillat-Savarin", "Brin",
-            "Brin d' Amour", "Brin d'Amour", "Brinza (Burduf Brinza)",
-            "Briquette de Brebis", "Briquette du Forez", "Broccio",
-            "Broccio Demi-Affine", "Brousse du Rove", "Bruder Basil",
-            "Brusselae Kaas (Fromage de Bruxelles)", "Bryndza",
-            "Buchette d'Anjou", "Buffalo", "Burgos", "Butte", "Butterkase",
-            "Button (Innes)", "Buxton Blue", "Cabecou", "Caboc", "Cabrales",
-            "Cachaille", "Caciocavallo", "Caciotta", "Caerphilly",
-            "Cairnsmore", "Calenzana", "Cambazola", "Camembert de Normandie",
-            "Canadian Cheddar", "Canestrato", "Cantal", "Caprice des Dieux",
-            "Capricorn Goat", "Capriole Banon", "Carre de l'Est",
-            "Casciotta di Urbino", "Cashel Blue", "Castellano", "Castelleno",
-            "Castelmagno", "Castelo Branco", "Castigliano", "Cathelain",
-            "Celtic Promise", "Cendre d'Olivet", "Cerney", "Chabichou",
-            "Chabichou du Poitou", "Chabis de Gatine", "Chaource", "Charolais",
-            "Chaumes", "Cheddar", "Cheddar Clothbound", "Cheshire", "Chevres",
-            "Chevrotin des Aravis", "Chontaleno", "Civray",
-            "Coeur de Camembert au Calvados", "Coeur de Chevre", "Colby",
-            "Cold Pack", "Comte", "Coolea", "Cooleney", "Coquetdale",
-            "Corleggy", "Cornish Pepper", "Cotherstone", "Cotija",
-            "Cottage Cheese", "Cottage Cheese (Australian)", "Cougar Gold",
-            "Coulommiers", "Coverdale", "Crayeux de Roncq", "Cream Cheese",
-            "Cream Havarti", "Crema Agria", "Crema Mexicana", "Creme Fraiche",
-            "Crescenza", "Croghan", "Crottin de Chavignol",
-            "Crottin du Chavignol", "Crowdie", "Crowley", "Cuajada", "Curd",
-            "Cure Nantais", "Curworthy", "Cwmtawe Pecorino",
-            "Cypress Grove Chevre", "Danablu (Danish Blue)", "Danbo",
-            "Danish Fontina", "Daralagjazsky", "Dauphin", "Delice des Fiouves",
-            "Denhany Dorset Drum", "Derby", "Dessertnyj Belyj", "Devon Blue",
-            "Devon Garland", "Dolcelatte", "Doolin", "Doppelrhamstufel",
-            "Dorset Blue Vinney", "Double Gloucester", "Double Worcester",
-            "Dreux a la Feuille", "Dry Jack", "Duddleswell", "Dunbarra",
-            "Dunlop", "Dunsyre Blue", "Duroblando", "Durrus",
-            "Dutch Mimolette (Commissiekaas)", "Edam", "Edelpilz",
-            "Emental Grand Cru", "Emlett", "Emmental", "Epoisses de Bourgogne",
-            "Esbareich", "Esrom", "Etorki", "Evansdale Farmhouse Brie",
-            "Evora De L'Alentejo", "Exmoor Blue", "Explorateur", "Feta",
-            "Feta (Australian)", "Figue", "Filetta", "Fin-de-Siecle",
-            "Finlandia Swiss", "Finn", "Fiore Sardo", "Fleur du Maquis",
-            "Flor de Guia", "Flower Marie", "Folded",
-            "Folded cheese with mint", "Fondant de Brebis", "Fontainebleau",
-            "Fontal", "Fontina Val d'Aosta", "Formaggio di capra", "Fougerus",
-            "Four Herb Gouda", "Fourme d' Ambert", "Fourme de Haute Loire",
-            "Fourme de Montbrison", "Fresh Jack", "Fresh Mozzarella",
-            "Fresh Ricotta", "Fresh Truffles", "Fribourgeois", "Friesekaas",
-            "Friesian", "Friesla", "Frinault", "Fromage a Raclette",
-            "Fromage Corse", "Fromage de Montagne de Savoie", "Fromage Frais",
-            "Fruit Cream Cheese", "Frying Cheese", "Fynbo", "Gabriel",
-            "Galette du Paludier", "Galette Lyonnaise",
-            "Galloway Goat's Milk Gems", "Gammelost", "Gaperon a l'Ail",
-            "Garrotxa", "Gastanberra", "Geitost", "Gippsland Blue", "Gjetost",
-            "Gloucester", "Golden Cross", "Gorgonzola", "Gornyaltajski",
-            "Gospel Green", "Gouda", "Goutu", "Gowrie", "Grabetto", "Graddost",
-            "Grafton Village Cheddar", "Grana", "Grana Padano", "Grand Vatel",
-            "Grataron d' Areches", "Gratte-Paille", "Graviera", "Greuilh",
-            "Greve", "Gris de Lille", "Gruyere", "Gubbeen", "Guerbigny",
-            "Halloumi", "Halloumy (Australian)", "Haloumi-Style Cheese",
-            "Harbourne Blue", "Havarti", "Heidi Gruyere", "Hereford Hop",
-            "Herrgardsost", "Herriot Farmhouse", "Herve", "Hipi Iti",
-            "Hubbardston Blue Cow", "Hushallsost", "Iberico", "Idaho Goatster",
-            "Idiazabal", "Il Boschetto al Tartufo", "Ile d'Yeu",
-            "Isle of Mull", "Jarlsberg", "Jermi Tortes", "Jibneh Arabieh",
-            "Jindi Brie", "Jubilee Blue", "Juustoleipa", "Kadchgall", "Kaseri",
-            "Kashta", "Kefalotyri", "Kenafa", "Kernhem", "Kervella Affine",
-            "Kikorangi", "King Island Cape Wickham Brie", "King River Gold",
-            "Klosterkaese", "Knockalara", "Kugelkase", "L'Aveyronnais",
-            "L'Ecir de l'Aubrac", "La Taupiniere", "La Vache Qui Rit",
-            "Laguiole", "Lairobell", "Lajta", "Lanark Blue", "Lancashire",
-            "Langres", "Lappi", "Laruns", "Lavistown", "Le Brin",
-            "Le Fium Orbo", "Le Lacandou", "Le Roule", "Leafield", "Lebbene",
-            "Leerdammer", "Leicester", "Leyden", "Limburger",
-            "Lincolnshire Poacher", "Lingot Saint Bousquet d'Orb", "Liptauer",
-            "Little Rydings", "Livarot", "Llanboidy", "Llanglofan Farmhouse",
-            "Loch Arthur Farmhouse", "Loddiswell Avondale", "Longhorn",
-            "Lou Palou", "Lou Pevre", "Lyonnais", "Maasdam", "Macconais",
-            "Mahoe Aged Gouda", "Mahon", "Malvern", "Mamirolle", "Manchego",
-            "Manouri", "Manur", "Marble Cheddar", "Marbled Cheeses",
-            "Maredsous", "Margotin", "Maribo", "Maroilles", "Mascares",
-            "Mascarpone", "Mascarpone (Australian)", "Mascarpone Torta",
-            "Matocq", "Maytag Blue", "Meira", "Menallack Farmhouse",
-            "Menonita", "Meredith Blue", "Mesost", "Metton (Cancoillotte)",
-            "Meyer Vintage Gouda", "Mihalic Peynir", "Milleens", "Mimolette",
-            "Mine-Gabhar", "Mini Baby Bells", "Mixte", "Molbo",
-            "Monastery Cheeses", "Mondseer", "Mont D'or Lyonnais", "Montasio",
-            "Monterey Jack", "Monterey Jack Dry", "Morbier",
-            "Morbier Cru de Montagne", "Mothais a la Feuille", "Mozzarella",
-            "Mozzarella (Australian)", "Mozzarella di Bufala",
-            "Mozzarella Fresh, in water", "Mozzarella Rolls", "Munster",
-            "Murol", "Mycella", "Myzithra", "Naboulsi", "Nantais",
-            "Neufchatel", "Neufchatel (Australian)", "Niolo", "Nokkelost",
-            "Northumberland", "Oaxaca", "Olde York", "Olivet au Foin",
-            "Olivet Bleu", "Olivet Cendre", "Orkney Extra Mature Cheddar",
-            "Orla", "Oschtjepka", "Ossau Fermier", "Ossau-Iraty", "Oszczypek",
-            "Oxford Blue", "P'tit Berrichon", "Palet de Babligny", "Paneer",
-            "Panela", "Pannerone", "Pant ys Gawn", "Parmesan (Parmigiano)",
-            "Parmigiano Reggiano", "Pas de l'Escalette", "Passendale",
-            "Pasteurized Processed", "Pate de Fromage", "Patefine Fort",
-            "Pave d'Affinois", "Pave d'Auge", "Pave de Chirac",
-            "Pave du Berry", "Pecorino", "Pecorino in Walnut Leaves",
-            "Pecorino Romano", "Peekskill Pyramid", "Pelardon des Cevennes",
-            "Pelardon des Corbieres", "Penamellera", "Penbryn", "Pencarreg",
-            "Perail de Brebis", "Petit Morin", "Petit Pardou", "Petit-Suisse",
-            "Picodon de Chevre", "Picos de Europa", "Piora",
-            "Pithtviers au Foin", "Plateau de Herve", "Plymouth Cheese",
-            "Podhalanski", "Poivre d'Ane", "Polkolbin", "Pont l'Eveque",
-            "Port Nicholson", "Port-Salut", "Postel", "Pouligny-Saint-Pierre",
-            "Pourly", "Prastost", "Pressato", "Prince-Jean",
-            "Processed Cheddar", "Provolone", "Provolone (Australian)",
-            "Pyengana Cheddar", "Pyramide", "Quark", "Quark (Australian)",
-            "Quartirolo Lombardo", "Quatre-Vents", "Quercy Petit",
-            "Queso Blanco", "Queso Blanco con Frutas --Pina y Mango",
-            "Queso de Murcia", "Queso del Montsec", "Queso del Tietar",
-            "Queso Fresco", "Queso Fresco (Adobera)", "Queso Iberico",
-            "Queso Jalapeno", "Queso Majorero", "Queso Media Luna",
-            "Queso Para Frier", "Queso Quesadilla", "Rabacal", "Raclette",
-            "Ragusano", "Raschera", "Reblochon", "Red Leicester",
-            "Regal de la Dombes", "Reggianito", "Remedou", "Requeson",
-            "Richelieu", "Ricotta", "Ricotta (Australian)", "Ricotta Salata",
-            "Ridder", "Rigotte", "Rocamadour", "Rollot", "Romano",
-            "Romans Part Dieu", "Roncal", "Roquefort", "Roule",
-            "Rouleau De Beaulieu", "Royalp Tilsit", "Rubens", "Rustinu",
-            "Saaland Pfarr", "Saanenkaese", "Saga", "Sage Derby",
-            "Sainte Maure", "Saint-Marcellin", "Saint-Nectaire",
-            "Saint-Paulin", "Salers", "Samso", "San Simon", "Sancerre",
-            "Sap Sago", "Sardo", "Sardo Egyptian", "Sbrinz", "Scamorza",
-            "Schabzieger", "Schloss", "Selles sur Cher", "Selva", "Serat",
-            "Seriously Strong Cheddar", "Serra da Estrela", "Sharpam",
-            "Shelburne Cheddar", "Shropshire Blue", "Siraz", "Sirene",
-            "Smoked Gouda", "Somerset Brie", "Sonoma Jack",
-            "Sottocenare al Tartufo", "Soumaintrain", "Sourire Lozerien",
-            "Spenwood", "Sraffordshire Organic", "St. Agur Blue Cheese",
-            "Stilton", "Stinking Bishop", "String", "Sussex Slipcote",
-            "Sveciaost", "Swaledale", "Sweet Style Swiss", "Swiss",
-            "Syrian (Armenian String)", "Tala", "Taleggio", "Tamie",
-            "Tasmania Highland Chevre Log", "Taupiniere", "Teifi", "Telemea",
-            "Testouri", "Tete de Moine", "Tetilla", "Texas Goat Cheese",
-            "Tibet", "Tillamook Cheddar", "Tilsit", "Timboon Brie", "Toma",
-            "Tomme Brulee", "Tomme d'Abondance", "Tomme de Chevre",
-            "Tomme de Romans", "Tomme de Savoie", "Tomme des Chouans",
-            "Tommes", "Torta del Casar", "Toscanello", "Touree de L'Aubier",
-            "Tourmalet", "Trappe (Veritable)", "Trois Cornes De Vendee",
-            "Tronchon", "Trou du Cru", "Truffe", "Tupi", "Turunmaa",
-            "Tymsboro", "Tyn Grug", "Tyning", "Ubriaco", "Ulloa",
-            "Vacherin-Fribourgeois", "Valencay", "Vasterbottenost", "Venaco",
-            "Vendomois", "Vieux Corse", "Vignotte", "Vulscombe",
-            "Waimata Farmhouse Blue", "Washed Rind Cheese (Australian)",
-            "Waterloo", "Weichkaese", "Wellington", "Wensleydale",
-            "White Stilton", "Whitestone Farmhouse", "Wigmore",
-            "Woodside Cabecou", "Xanadu", "Xynotyro", "Yarg Cornish",
-            "Yarra Valley Pyramid", "Yorkshire Blue", "Zamorano",
-            "Zanetti Grana Padano", "Zanetti Parmigiano Reggiano"};
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar1.java b/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar1.java
deleted file mode 100644
index d9bf360..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar1.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.Button;
-import android.widget.ProgressBar;
-import android.os.Bundle;
-import android.view.View;
-import android.view.Window;
-
-
-/**
- * Demonstrates how to use progress bars as widgets and in the title bar.  The progress bar
- * in the title will be shown until the progress is complete, at which point it fades away.
- */
-public class ProgressBar1 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Request the progress bar to be shown in the title
-        requestWindowFeature(Window.FEATURE_PROGRESS);
-        setContentView(R.layout.progressbar_1);
-        setProgressBarVisibility(true);
-        
-        final ProgressBar progressHorizontal = (ProgressBar) findViewById(R.id.progress_horizontal);
-        setProgress(progressHorizontal.getProgress() * 100);
-        setSecondaryProgress(progressHorizontal.getSecondaryProgress() * 100);
-        
-        Button button = (Button) findViewById(R.id.increase);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                progressHorizontal.incrementProgressBy(1);
-                // Title progress is in range 0..10000
-                setProgress(100 * progressHorizontal.getProgress());
-            }
-        });
-
-        button = (Button) findViewById(R.id.decrease);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                progressHorizontal.incrementProgressBy(-1);
-                // Title progress is in range 0..10000
-                setProgress(100 * progressHorizontal.getProgress());
-            }
-        });
-
-        button = (Button) findViewById(R.id.increase_secondary);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                progressHorizontal.incrementSecondaryProgressBy(1);
-                // Title progress is in range 0..10000
-                setSecondaryProgress(100 * progressHorizontal.getSecondaryProgress());
-            }
-        });
-
-        button = (Button) findViewById(R.id.decrease_secondary);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                progressHorizontal.incrementSecondaryProgressBy(-1);
-                // Title progress is in range 0..10000
-                setSecondaryProgress(100 * progressHorizontal.getSecondaryProgress());
-            }
-        });
-        
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar2.java b/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar2.java
deleted file mode 100644
index 1c41b78..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar2.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Window;
-
-
-/**
- * Demonstrates the use of indeterminate progress bars as widgets and in the
- * window's title bar. The widgets show the 3 different sizes of circular
- * progress bars that can be used.
- */
-public class ProgressBar2 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Request for the progress bar to be shown in the title
-        requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
-        
-        setContentView(R.layout.progressbar_2);
-        
-        // Make sure the progress bar is visible
-        setProgressBarVisibility(true);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar3.java b/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar3.java
deleted file mode 100644
index 285f07b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar3.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.app.Dialog;
-import android.app.ProgressDialog;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-
-/**
- * Demonstrates the use of progress dialogs.  Uses {@link Activity#onCreateDialog}
- * and {@link Activity#showDialog} to ensure the dialogs will be properly saved
- * and restored.
- */
-public class ProgressBar3 extends Activity {
-
-    ProgressDialog mDialog1;
-    ProgressDialog mDialog2;
-
-    private static final int DIALOG1_KEY = 0;
-    private static final int DIALOG2_KEY = 1;
-
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.progressbar_3);
-
-        Button button = (Button) findViewById(R.id.showIndeterminate);
-        button.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG1_KEY);
-            }
-        });
-
-        button = (Button) findViewById(R.id.showIndeterminateNoTitle);
-        button.setOnClickListener(new View.OnClickListener() {
-            public void onClick(View v) {
-                showDialog(DIALOG2_KEY);
-            }
-        });
-    }
-
-    @Override
-    protected Dialog onCreateDialog(int id) {
-        switch (id) {
-            case DIALOG1_KEY: {
-                ProgressDialog dialog = new ProgressDialog(this);
-                dialog.setTitle("Indeterminate");
-                dialog.setMessage("Please wait while loading...");
-                dialog.setIndeterminate(true);
-                dialog.setCancelable(true);
-                return dialog;
-            }
-            case DIALOG2_KEY: {
-                ProgressDialog dialog = new ProgressDialog(this);
-                dialog.setMessage("Please wait while loading...");
-                dialog.setIndeterminate(true);
-                dialog.setCancelable(true);
-                return dialog;
-            }
-        }
-        return null;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar4.java b/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar4.java
deleted file mode 100644
index ee396b3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ProgressBar4.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Window;
-import android.view.View;
-import android.widget.Button;
-
-
-/**
- * Demonstrates how to use an indetermiate progress indicator in the window's title bar.
- */
-public class ProgressBar4 extends Activity {
-    private boolean mToggleIndeterminate = false;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Request progress bar
-        requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
-        setContentView(R.layout.progressbar_4);
-        setProgressBarIndeterminateVisibility(mToggleIndeterminate);
-        
-        Button button = (Button) findViewById(R.id.toggle);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mToggleIndeterminate = !mToggleIndeterminate;
-                setProgressBarIndeterminateVisibility(mToggleIndeterminate);
-            }
-        });
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/RadioGroup1.java b/samples/ApiDemos/src/com/example/android/apis/view/RadioGroup1.java
deleted file mode 100644
index 4d91192..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/RadioGroup1.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.TextView;
-import android.widget.RadioGroup;
-import android.widget.Button;
-import android.widget.RadioButton;
-import android.widget.LinearLayout;
-
-
-public class RadioGroup1 extends Activity implements RadioGroup.OnCheckedChangeListener,
-        View.OnClickListener {
-
-    private TextView mChoice;
-    private RadioGroup mRadioGroup;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.radio_group_1);
-        mRadioGroup = (RadioGroup) findViewById(R.id.menu);
-
-        // test adding a radio button programmatically
-        RadioButton newRadioButton = new RadioButton(this);
-        newRadioButton.setText(R.string.radio_group_snack);
-        newRadioButton.setId(R.id.snack);
-        LinearLayout.LayoutParams layoutParams = new RadioGroup.LayoutParams(
-                RadioGroup.LayoutParams.WRAP_CONTENT,
-                RadioGroup.LayoutParams.WRAP_CONTENT);
-        mRadioGroup.addView(newRadioButton, 0, layoutParams);
-
-        // test listening to checked change events
-        String selection = getString(R.string.radio_group_selection);
-        mRadioGroup.setOnCheckedChangeListener(this);
-        mChoice = (TextView) findViewById(R.id.choice);
-        mChoice.setText(selection + mRadioGroup.getCheckedRadioButtonId());
-
-        // test clearing the selection
-        Button clearButton = (Button) findViewById(R.id.clear);
-        clearButton.setOnClickListener(this);
-    }
-
-    public void onCheckedChanged(RadioGroup group, int checkedId) {
-        String selection = getString(R.string.radio_group_selection);
-        String none = getString(R.string.radio_group_none);
-        mChoice.setText(selection +
-                (checkedId == View.NO_ID ? none : checkedId));
-    }
-
-    public void onClick(View v) {
-        mRadioGroup.clearCheck();
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/RatingBar1.java b/samples/ApiDemos/src/com/example/android/apis/view/RatingBar1.java
deleted file mode 100644
index 97416d4..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/RatingBar1.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.RatingBar;
-import android.widget.SeekBar;
-import android.widget.TextView;
-
-import com.example.android.apis.R;
-
-/**
- * Demonstrates how to use a rating bar
- */
-public class RatingBar1 extends Activity implements RatingBar.OnRatingBarChangeListener {
-    RatingBar mSmallRatingBar;
-    RatingBar mIndicatorRatingBar;
-    TextView mRatingText;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.ratingbar_1);
-        
-        mRatingText = (TextView) findViewById(R.id.rating);
-
-        // We copy the most recently changed rating on to these indicator-only
-        // rating bars
-        mIndicatorRatingBar = (RatingBar) findViewById(R.id.indicator_ratingbar);
-        mSmallRatingBar = (RatingBar) findViewById(R.id.small_ratingbar);
-        
-        // The different rating bars in the layout. Assign the listener to us.
-        ((RatingBar)findViewById(R.id.ratingbar1)).setOnRatingBarChangeListener(this);
-        ((RatingBar)findViewById(R.id.ratingbar2)).setOnRatingBarChangeListener(this);
-    }
-
-    public void onRatingChanged(RatingBar ratingBar, float rating, boolean fromTouch) {
-        final int numStars = ratingBar.getNumStars();
-        mRatingText.setText( 
-                getString(R.string.ratingbar_rating) + " " + rating + "/" + numStars);
-
-        // Since this rating bar is updated to reflect any of the other rating
-        // bars, we should update it to the current values.
-        if (mIndicatorRatingBar.getNumStars() != numStars) {
-            mIndicatorRatingBar.setNumStars(numStars);
-            mSmallRatingBar.setNumStars(numStars);
-        }
-        if (mIndicatorRatingBar.getRating() != rating) {
-            mIndicatorRatingBar.setRating(rating);
-            mSmallRatingBar.setRating(rating);
-        }
-        final float ratingBarStepSize = ratingBar.getStepSize();
-        if (mIndicatorRatingBar.getStepSize() != ratingBarStepSize) {
-            mIndicatorRatingBar.setStepSize(ratingBarStepSize);
-            mSmallRatingBar.setStepSize(ratingBarStepSize);
-        }
-    }
-
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout1.java b/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout1.java
deleted file mode 100644
index 1c9f824..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout1.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * A simple layout which demonstrates stretching a view to fill the space between two other views.
- */
-public class RelativeLayout1 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.relative_layout_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout2.java b/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout2.java
deleted file mode 100644
index 635d9f3..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/RelativeLayout2.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Builds building a simple form using a RelativeLayout
- * 
- */
-public class RelativeLayout2 extends Activity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.relative_layout_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar1.java b/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar1.java
deleted file mode 100644
index 0b3c19a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar1.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class ScrollBar1 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.scrollbar1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar2.java b/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar2.java
deleted file mode 100644
index 09a8bb0..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar2.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class ScrollBar2 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.scrollbar2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar3.java b/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar3.java
deleted file mode 100644
index 74c5876..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ScrollBar3.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-
-import com.example.android.apis.R;
-
-
-public class ScrollBar3 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.scrollbar3);
-        
-        findViewById(R.id.view3).setScrollBarStyle(View.SCROLLBARS_INSIDE_INSET);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ScrollView1.java b/samples/ApiDemos/src/com/example/android/apis/view/ScrollView1.java
deleted file mode 100644
index b3a903a..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ScrollView1.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * Demonstrates wrapping a layout in a ScrollView.
- *
- */
-public class ScrollView1 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.scroll_view_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/ScrollView2.java b/samples/ApiDemos/src/com/example/android/apis/view/ScrollView2.java
deleted file mode 100644
index 89e4003..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/ScrollView2.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.LinearLayout;
-import android.widget.TextView;
-import android.widget.Button;
-
-
-/**
- * Demonstrates wrapping a layout in a ScrollView.
- *
- */
-public class ScrollView2 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.scroll_view_2);
-
-        LinearLayout layout = (LinearLayout) findViewById(R.id.layout);
-        for (int i = 2; i < 64; i++) {
-            TextView textView = new TextView(this);
-            textView.setText("Text View " + i);
-            LinearLayout.LayoutParams p = new LinearLayout.LayoutParams(
-                    LinearLayout.LayoutParams.FILL_PARENT,
-                    LinearLayout.LayoutParams.WRAP_CONTENT
-            );
-            layout.addView(textView, p);
-
-            Button buttonView = new Button(this);
-            buttonView.setText("Button " + i);
-            layout.addView(buttonView, p);
-        }
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/SeekBar1.java b/samples/ApiDemos/src/com/example/android/apis/view/SeekBar1.java
deleted file mode 100644
index 15bb013..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/SeekBar1.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.SeekBar;
-import android.widget.TextView;
-
-import com.example.android.apis.R;
-
-
-/**
- * Demonstrates how to use a seek bar
- */
-public class SeekBar1 extends Activity implements SeekBar.OnSeekBarChangeListener {
-    
-    SeekBar mSeekBar;
-    TextView mProgressText;
-    TextView mTrackingText;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.seekbar_1);
-        
-        mSeekBar = (SeekBar)findViewById(R.id.seek);
-        mSeekBar.setOnSeekBarChangeListener(this);
-        mProgressText = (TextView)findViewById(R.id.progress);
-        mTrackingText = (TextView)findViewById(R.id.tracking);
-    }
-
-    public void onProgressChanged(SeekBar seekBar, int progress, boolean fromTouch) {
-        mProgressText.setText(progress + " " + 
-                getString(R.string.seekbar_from_touch) + "=" + fromTouch);
-    }
-
-    public void onStartTrackingTouch(SeekBar seekBar) {
-        mTrackingText.setText(getString(R.string.seekbar_tracking_on));
-    }
-
-    public void onStopTrackingTouch(SeekBar seekBar) {
-        mTrackingText.setText(getString(R.string.seekbar_tracking_off));
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Spinner1.java b/samples/ApiDemos/src/com/example/android/apis/view/Spinner1.java
deleted file mode 100644
index a35a909..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Spinner1.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.ArrayAdapter;
-import android.widget.Spinner;
-
-
-public class Spinner1 extends Activity {
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.spinner_1);
-
-        Spinner s1 = (Spinner) findViewById(R.id.spinner1);
-        ArrayAdapter<CharSequence> adapter = ArrayAdapter.createFromResource(
-                this, R.array.colors, android.R.layout.simple_spinner_item);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        s1.setAdapter(adapter);
-
-        Spinner s2 = (Spinner) findViewById(R.id.spinner2);
-        adapter = ArrayAdapter.createFromResource(this, R.array.planets,
-                android.R.layout.simple_spinner_item);
-        adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
-        s2.setAdapter(adapter);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout1.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout1.java
deleted file mode 100644
index 98f6b31..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout1.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout1 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_1);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout10.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout10.java
deleted file mode 100644
index f1f8f24..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout10.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.TableLayout;
-import android.widget.Button;
-import android.os.Bundle;
-import android.view.View;
-
-
-public class TableLayout10 extends Activity {
-    private boolean mShrink;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_10);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout11.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout11.java
deleted file mode 100644
index 770238f..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout11.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-/**
- * <p>This example shows how to use horizontal gravity in a table layout.</p>
- */
-public class TableLayout11 extends Activity {
-    private boolean mShrink;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_11);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout12.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout12.java
deleted file mode 100644
index 14cbd0d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout12.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-/**
- * <p>This example shows how to use cell spanning in a table layout.</p>
- */
-public class TableLayout12 extends Activity {
-    private boolean mShrink;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_12);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout2.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout2.java
deleted file mode 100644
index 3e60563..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout2.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout2 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_2);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout3.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout3.java
deleted file mode 100644
index 82a545c..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout3.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout3 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_3);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout4.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout4.java
deleted file mode 100644
index 53a1055..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout4.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout4 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_4);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout5.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout5.java
deleted file mode 100644
index 9422218..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout5.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout5 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_5);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout6.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout6.java
deleted file mode 100644
index b6a9125..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout6.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-public class TableLayout6 extends Activity {
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_6);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout7.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout7.java
deleted file mode 100644
index 22fc4a5..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout7.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Gravity;
-import android.view.View;
-import android.widget.Button;
-import android.widget.TableLayout;
-import android.widget.TableRow;
-import android.widget.TextView;
-
-
-public class TableLayout7 extends Activity {
-    private boolean mShortcutsCollapsed;
-    private boolean mCheckmarksCollapsed;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_7);
-
-        final TableLayout table = (TableLayout) findViewById(R.id.menu);
-        Button button = (Button) findViewById(R.id.toggle1);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mShortcutsCollapsed = !mShortcutsCollapsed;
-                table.setColumnCollapsed(2, mShortcutsCollapsed);
-            }
-        });
-        button = (Button) findViewById(R.id.toggle2);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mCheckmarksCollapsed = !mCheckmarksCollapsed;
-                table.setColumnCollapsed(0, mCheckmarksCollapsed);
-            }
-        });
-
-        mCheckmarksCollapsed = table.isColumnCollapsed(0);
-        mShortcutsCollapsed = table.isColumnCollapsed(2);
-
-        appendRow(table);
-    }
-
-    private void appendRow(TableLayout table) {
-        TableRow row = new TableRow(this);
-
-        TextView label = new TextView(this);
-        label.setText(R.string.table_layout_7_quit);
-        label.setPadding(3, 3, 3, 3);
-
-        TextView shortcut = new TextView(this);
-        shortcut.setText(R.string.table_layout_7_ctrlq);
-        shortcut.setPadding(3, 3, 3, 3);
-        shortcut.setGravity(Gravity.RIGHT | Gravity.TOP);
-
-        row.addView(label, new TableRow.LayoutParams(1));
-        row.addView(shortcut, new TableRow.LayoutParams());
-
-        table.addView(row, new TableLayout.LayoutParams());
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout8.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout8.java
deleted file mode 100644
index 99ca4ac..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout8.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.TableLayout;
-import android.widget.Button;
-import android.widget.TableRow;
-import android.widget.TextView;
-import android.os.Bundle;
-import android.view.Gravity;
-import android.view.View;
-
-
-public class TableLayout8 extends Activity {
-    private boolean mStretch;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_8);
-
-        final TableLayout table = (TableLayout) findViewById(R.id.menu);
-        Button button = (Button) findViewById(R.id.toggle);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mStretch = !mStretch;
-                table.setColumnStretchable(1, mStretch);
-            }
-        });
-
-        mStretch = table.isColumnStretchable(1);
-
-        appendRow(table);
-    }
-
-    private void appendRow(TableLayout table) {
-        TableRow row = new TableRow(this);
-
-        TextView label = new TextView(this);
-        label.setText(R.string.table_layout_8_quit);
-        label.setPadding(3, 3, 3, 3);
-
-        TextView shortcut = new TextView(this);
-        shortcut.setText(R.string.table_layout_8_ctrlq);
-        shortcut.setPadding(3, 3, 3, 3);
-        shortcut.setGravity(Gravity.RIGHT | Gravity.TOP);
-
-        row.addView(label, new TableRow.LayoutParams(1));
-        row.addView(shortcut, new TableRow.LayoutParams());
-
-        table.addView(row, new TableLayout.LayoutParams());
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout9.java b/samples/ApiDemos/src/com/example/android/apis/view/TableLayout9.java
deleted file mode 100644
index f99111d..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TableLayout9.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.widget.TableLayout;
-import android.widget.Button;
-import android.os.Bundle;
-import android.view.View;
-
-
-public class TableLayout9 extends Activity {
-    private boolean mShrink;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.table_layout_9);
-
-        final TableLayout table = (TableLayout) findViewById(R.id.menu);
-        Button button = (Button) findViewById(R.id.toggle);
-        button.setOnClickListener(new Button.OnClickListener() {
-            public void onClick(View v) {
-                mShrink = !mShrink;
-                table.setColumnShrinkable(0, mShrink);
-            }
-        });
-
-        mShrink = table.isColumnShrinkable(0);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Tabs1.java b/samples/ApiDemos/src/com/example/android/apis/view/Tabs1.java
deleted file mode 100644
index 455969e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Tabs1.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.TabActivity;
-import android.os.Bundle;
-import android.widget.TabHost;
-import android.widget.TabHost.TabSpec;
-import android.view.LayoutInflater;
-import android.view.View;
-
-import com.example.android.apis.R;
-
-/**
- * An example of tabs that uses labels ({@link TabSpec#setIndicator(CharSequence)})
- * for its indicators and views by id from a layout file ({@link TabSpec#setContent(int)}).
- */
-public class Tabs1 extends TabActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        TabHost tabHost = getTabHost();
-        
-        LayoutInflater.from(this).inflate(R.layout.tabs1, tabHost.getTabContentView(), true);
-
-        tabHost.addTab(tabHost.newTabSpec("tab1")
-                .setIndicator("tab1")
-                .setContent(R.id.view1));
-        tabHost.addTab(tabHost.newTabSpec("tab3")
-                .setIndicator("tab2")
-                .setContent(R.id.view2));
-        tabHost.addTab(tabHost.newTabSpec("tab3")
-                .setIndicator("tab3")
-                .setContent(R.id.view3));
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Tabs2.java b/samples/ApiDemos/src/com/example/android/apis/view/Tabs2.java
deleted file mode 100644
index 795a86b..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Tabs2.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.TabActivity;
-import android.os.Bundle;
-import android.widget.TabHost;
-import android.widget.TextView;
-import android.view.View;
-import com.example.android.apis.R;
-
-/**
- * Example of using a tab content factory for the content via {@link TabHost.TabSpec#setContent(android.widget.TabHost.TabContentFactory)}
- *
- * It also demonstrates using an icon on one of the tabs via {@link TabHost.TabSpec#setIndicator(CharSequence, android.graphics.drawable.Drawable)}
- *
- */
-public class Tabs2 extends TabActivity implements TabHost.TabContentFactory {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        final TabHost tabHost = getTabHost();
-        tabHost.addTab(tabHost.newTabSpec("tab1")
-                .setIndicator("tab1", getResources().getDrawable(R.drawable.star_big_on))
-                .setContent(this));
-        tabHost.addTab(tabHost.newTabSpec("tab2")
-                .setIndicator("tab2")
-                .setContent(this));
-        tabHost.addTab(tabHost.newTabSpec("tab3")
-                .setIndicator("tab3")
-                .setContent(this));
-    }
-
-    /** {@inheritDoc} */
-    public View createTabContent(String tag) {
-        final TextView tv = new TextView(this);
-        tv.setText("Content for tab with tag " + tag);
-        return tv;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Tabs3.java b/samples/ApiDemos/src/com/example/android/apis/view/Tabs3.java
deleted file mode 100644
index e09f041..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Tabs3.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.TabActivity;
-import android.os.Bundle;
-import android.widget.TabHost;
-import android.content.Intent;
-
-/**
- * An example of tab content that launches an activity via {@link android.widget.TabHost.TabSpec#setContent(android.content.Intent)}
- */
-public class Tabs3 extends TabActivity {
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        final TabHost tabHost = getTabHost();
-
-        tabHost.addTab(tabHost.newTabSpec("tab1")
-                .setIndicator("list")
-                .setContent(new Intent(this, List1.class)));
-
-        tabHost.addTab(tabHost.newTabSpec("tab2")
-                .setIndicator("photo list")
-                .setContent(new Intent(this, List8.class)));
-        
-        // This tab sets the intent flag so that it is recreated each time
-        // the tab is clicked.
-        tabHost.addTab(tabHost.newTabSpec("tab3")
-                .setIndicator("destroy")
-                .setContent(new Intent(this, Controls2.class)
-                        .addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP)));
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/TextSwitcher1.java b/samples/ApiDemos/src/com/example/android/apis/view/TextSwitcher1.java
deleted file mode 100644
index b964512..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/TextSwitcher1.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Gravity;
-import android.view.View;
-import android.view.animation.Animation;
-import android.view.animation.AnimationUtils;
-import android.widget.Button;
-import android.widget.TextSwitcher;
-import android.widget.TextView;
-import android.widget.ViewSwitcher;
-
-/**
- * Uses a TextSwitcher.
- */
-public class TextSwitcher1 extends Activity implements ViewSwitcher.ViewFactory,
-        View.OnClickListener {
-
-    private TextSwitcher mSwitcher;
-
-    private int mCounter = 0;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.text_switcher_1);
-
-        mSwitcher = (TextSwitcher) findViewById(R.id.switcher);
-        mSwitcher.setFactory(this);
-
-        Animation in = AnimationUtils.loadAnimation(this,
-                android.R.anim.fade_in);
-        Animation out = AnimationUtils.loadAnimation(this,
-                android.R.anim.fade_out);
-        mSwitcher.setInAnimation(in);
-        mSwitcher.setOutAnimation(out);
-
-        Button nextButton = (Button) findViewById(R.id.next);
-        nextButton.setOnClickListener(this);
-
-        updateCounter();
-    }
-
-    public void onClick(View v) {
-        mCounter++;
-        updateCounter();
-    }
-
-    private void updateCounter() {
-        mSwitcher.setText(String.valueOf(mCounter));
-    }
-
-    public View makeView() {
-        TextView t = new TextView(this);
-        t.setGravity(Gravity.TOP | Gravity.CENTER_HORIZONTAL);
-        t.setTextSize(36);
-        return t;
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/Visibility1.java b/samples/ApiDemos/src/com/example/android/apis/view/Visibility1.java
deleted file mode 100644
index 243eba7..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/Visibility1.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-// Need the following import to get access to the app resources, since this
-// class is in a sub-package.
-import com.example.android.apis.R;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-
-
-/**
- * Demonstrates making a view VISIBLE, INVISIBLE and GONE
- *
- */
-public class Visibility1 extends Activity {
-
-    private View mVictim;
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.visibility_1);
-
-        // Find the view whose visibility will change
-        mVictim = findViewById(R.id.victim);
-
-        // Find our buttons
-        Button visibleButton = (Button) findViewById(R.id.vis);
-        Button invisibleButton = (Button) findViewById(R.id.invis);
-        Button goneButton = (Button) findViewById(R.id.gone);
-
-        // Wire each button to a click listener
-        visibleButton.setOnClickListener(mVisibleListener);
-        invisibleButton.setOnClickListener(mInvisibleListener);
-        goneButton.setOnClickListener(mGoneListener);
-    }
-
-    OnClickListener mVisibleListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim.setVisibility(View.VISIBLE);
-        }
-    };
-
-    OnClickListener mInvisibleListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim.setVisibility(View.INVISIBLE);
-        }
-    };
-
-    OnClickListener mGoneListener = new OnClickListener() {
-        public void onClick(View v) {
-            mVictim.setVisibility(View.GONE);
-        }
-    };
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/WebView1.java b/samples/ApiDemos/src/com/example/android/apis/view/WebView1.java
deleted file mode 100644
index 1cef034..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/WebView1.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.webkit.WebView;
-
-import com.example.android.apis.R;
-
-
-/**
- * Sample creating 10 webviews.
- */
-public class WebView1 extends Activity {
-    
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        
-        setContentView(R.layout.webview_1);
-        
-        final String mimeType = "text/html";
-        final String encoding = "utf-8";
-        
-        WebView wv;
-        
-        wv = (WebView) findViewById(R.id.wv1);
-        wv.loadData("<a href='x'>Hello World! - 1</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv2);
-        wv.loadData("<a href='x'>Hello World! - 2</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv3);
-        wv.loadData("<a href='x'>Hello World! - 3</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv4);
-        wv.loadData("<a href='x'>Hello World! - 4</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv5);
-        wv.loadData("<a href='x'>Hello World! - 5</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv6);
-        wv.loadData("<a href='x'>Hello World! - 6</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv7);
-        wv.loadData("<a href='x'>Hello World! - 7</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv8);
-        wv.loadData("<a href='x'>Hello World! - 8</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv9);
-        wv.loadData("<a href='x'>Hello World! - 9</a>", mimeType, encoding);
-        
-        wv = (WebView) findViewById(R.id.wv10);
-        wv.loadData("<a href='x'>Hello World! - 10</a>", mimeType, encoding);
-    }
-}
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/_index.html b/samples/ApiDemos/src/com/example/android/apis/view/_index.html
deleted file mode 100644
index 9497f8e..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/_index.html
+++ /dev/null
@@ -1,298 +0,0 @@
-<h3>RelativeLayout</h3>
-<dl>
-  <dt><a href="RelativeLayout1.html">1. Vertical</a></dt>
-  <dd>Demonstrates a simple relative layout.</dd>
-
-  <dt><a href="RelativeLayout2.html">2. Simple Form</a></dt>
-  <dd>Demonstrates a more complex relative layout to create a form. </dd>
-</dl>
-
-<h3>LinearLayout</h3>
-<dl>
-  <dt><a href="LinearLayout1.html">1. Vertical</a></dt>
-  <dd>Demonstrates a simple LinearLayout, with child width set to WRAP_CONTENT. </dd>
-
-  <dt><a href="LinearLayout2.html">2. Vertical (Fill Screen)</a></dt>
-  <dd>Demonstrates a simple LinearLayout, with child width set to FILL_PARENT.</dd>
-
-  <dt><a href="LinearLayout3.html">3. Vertical (Padded)</a></dt>
-  <dd>Demonstrates a LinearLayout where one of the elements can expand to fill any remaining screen space (weight=1). </dd>
-
-  <dt><a href="LinearLayout4.html">4. Horizontal</a></dt>
-  <dd>Demonstrates a horizontal LinearLayout, plus an expanding column. </dd>
-
-  <dt><a href="LinearLayout5.html">5. Simple Form</a></dt>
-  <dd>Demonstrates nested layouts to create a user form.</dd>
-
-  <dt><a href="LinearLayout6.html">6. Uniform Size</a></dt>
-  <dd>LinearLayout which uses a combination of wrap_content on itself and fill_parent on its children to get every item to be the same width.</dd>
-
-  <dt><a href="LinearLayout7.html">7. Fill Parent</a></dt>
-  <dd>Demonstrates a horizontal linear layout with equally sized columns. Some columns force their height to match the parent.</dd>
-
-  <dt><a href="LinearLayout8.html">8. Gravity</a></dt>
-  <dd>Demonstrates a simple linear layout with menu options demonstrating horizontal and vertical gravity options.</dd>
-
-  <dt><a href="LinearLayout9.html">9. Layout Weight</a></dt>
-  <dd> Demonstrates how the layout_weight attribute can shrink an element too big to fit on screen.</dd>
-
-</dl>
-
-<h3>ScrollView</h3>
-<dl>
-  <dt><a href="ScrollView1.html">1. Short</a></dt>
-  <dd>Demonstrates scrolling screen with buttons altermating with a text view. </dd>
-
-  <dt><a href="ScrollView2.html">2. Long</a></dt>
-  <dd>Demonstrates a longer scrolling screen similar to ScrollView1. </dd>
-</dl>
-
-<h3>TableLayout</h3>
-<dl>
-  <dt><a href="TableLayout1.html">1. Basic</a></dt>
-  <dd>Demonstrates a basic TableLayout with identical children. </dd>
-  
-  <dt><a href="TableLayout2.html">2. Empty Cells</a></dt>
-  <dd>Demonstrates a TableLayout with column-spanning rows and different child objects. </dd>
-  
-  <dt><a href="TableLayout3.html">3. Long Content</a></dt>
-  <dd>Rows have different number of columns and content doesn't fit on screen: column 4 of row 2 shrinks all of the other columns </dd>
-  
-  <dt><a href="TableLayout4.html">4. Stretchable</a></dt>
-  <dd>Demonstrates a TableLayout with a stretchable column. </dd>
-
-  <dt><a href="TableLayout5.html">5. Spanning and Stretchable</a></dt>
-  <dd>Demonstrates a complex TableLayout with spanning columns and stretchable columns to create a menu-like layout. </dd>
-
-  <dt><a href="TableLayout6.html">6. More Spanning and Stretchable</a></dt>
-  <dd>Similar to example 5, but with an additional &quot;checked&quot; column. </dd>
-
-  <dt><a href="TableLayout7.html">7. Column Collapse</a></dt>
-  <dd>Similar to example 6, but now with buttons on the bottom of the screen that enable you dynamically hide or show columns. </dd>
-
-  <dt><a href="TableLayout8.html">8. Toggle Stretch</a></dt>
-  <dd>Demonstrates toggling the &quot;stretch&quot; value on a column to fill the screen width. </dd>
-
-  <dt><a href="TableLayout9.html">9. Toggle Shrink</a></dt>
-  <dd>Demonstrates toggling the &quot;shrink&quot; value on a column to make an over-wide table shrink to fit the screen size. </dd>
-
-  <dt><a href="TableLayout10.html">10. Simple Form</a></dt>
-  <dd>Demonstrates using a table to design a user form. </dd>
-
-  <dt><a href="TableLayout11.html">11. Gravity</a></dt>
-  <dd>Demonstrates the use of advanced gravity attributes, such as <em>center_horizontal</em> and <em>right|bottom</em>                to align cell contents in a table. </dd>
-
-  <dt><a href="TableLayout12.html">12. Various Widths</a></dt>
-  <dd>Demonstrates the use of elements of various widths in a table. </dd>
-</dl>
-
-<h3>Baseline</h3>
-<p>Demonstrates the use of the <em>android:layout_alignBaseline</em> XML attribute in various page layouts.</p>
-<dl>
-  <dt><a href="Baseline1.html">1. Top</a></dt>
-  <dd>Demonstrates the default baseline alignment in a simple LinearLayout with items at the top of the screen. </dd>
-
-  <dt><a href="Baseline2.html">2. Bottom</a></dt>
-  <dd>Demonstrates the default baseline alignment in a simple LinearLayout with items at the bottom of the screen.</dd>
-
-  <dt><a href="Baseline3.html">3. Center</a></dt>
-  <dd>Demonstrates the default baseline alignment in a simple LinearLayout with items in the center of the screen.</dd>
-
-  <dt><a href="Baseline4.html">4. Everywhere</a></dt>
-  <dd>Demonstrates the default baseline alignment in a complex LinearLayout.</dd>
-  
-  <dt><a href="Baseline5.html">5. Everywhere</a></dt>
-  <dd>Demonstrates turning off baseline alignment in a LinearLayout. </dd>
-
-  <dt><a href="Baseline6.html">6. Multi-line</a></dt>
-  <dd>Demonstrates a baseline alignment with a multiline field. </dd>
-
-  <dt><a href="Baseline7.html">7. Relative</a></dt>
-  <dd>Demonstrates baseline alignment in a RelativeLayout. </dd>
-
-  <dt><a href="BaselineNested1.html">BaselineNested1</a></dt>
-  <dd>Demonstrates baseline aligning specific elements in three parallel vertical LinearLayout objects.</dd>
-
-  <dt><a href="BaselineNested2.html">BaselineNested2</a></dt>
-  <dd>Demonstrates baseline aligning specific elements in three mixed vertical and horizontal LinearLayout objects.</dd>
-  
-  <dt><a href="BaselineNested3.html">BaselineNested3</a></dt>
-  <dd>Demonstrates baseline alignment within nested LinearLayout objects. </dd>
-</dl>
-
-<h3>Radio Group</h3>
-<dl>
-  <dt><a href="RadioGroup1.html">Radio Group</a></dt>
-  <dd>Demonstrates using radio buttons and capturing the selected item. </dd>
-</dl>
-
-<h3>ScrollBars</h3>
-<dl>
-  <dt><a href="ScrollBar1.html">1. Basic</a></dt>
-  <dd>Demonstrates a scrollable LinearLayout object. </dd>
-
-  <dt><a href="ScrollBar2.html">2. Fancy</a></dt>
-  <dd>Demonstrates a scrollable LinearLayout object with a custom thumb slider image. </dd>
-</dl>
-
-<h3>Visibility</h3>
-<dl>
-  <dt><a href="Visibility1.html">Visibility</a></dt>
-  <dd>Demonstrates toggling the visibility of a View object between visible, invisible, and gone. </dd>
-</dl>
-
-<h3>Lists</h3>
-<dl>
-  <dt><a href="List1.html">1. Array</a></dt>
-  <dd> Demonstrates binding a ListAdapter to a string array as a data source, and displaying the elements on the screen. </dd>
-  
-  <dt><a href="List2.html">2. Cursor (People)</a></dt>
-  <dd> Demonstrates binding results from a database query to a field in a template. </dd>
-  
-  <dt><a href="List3.html">3. Cursor (Phones)</a></dt>
-  <dd> Demonstrates binding multiple columns from a database query to fields in a template. </dd>
-  
-  <dt><a href="List4.html">4. ListAdapter</a></dt>
-  <dd> Demonstrates implementing a custom ListAdapter to return View objects laid out in a custom manner. </dd>
-  
-  <dt><a href="List5.html">5. Separators</a></dt>
-  <dd> Demonstrates implementing a custom ListAdapter that includes separators between some items. </dd>
-  
-  <dt><a href="List6.html">6. ListAdapter Collapsed</a></dt>
-  <dd>Demonstrates another custom list adapter with that returns expandible items. </dd>
-  
-  <dt><a href="List7.html">7. Cursor (Phones)</a></dt>
-  <dd> Demonstrates a list adapter where data comes from a Cursor object. </dd>
-  
-  <dt><a href="List8.html">8. Photos</a></dt>
-  <dd> Demonstrates a list activity that uses a custom ListAdapter, setting the view for an empty item, and also how to customize the layout of a ListActivity. </dd>
-</dl>
-
-
-
-<h3>Custom</h3>
-<dl>
-  <dt><a href="CustomView1.html">CustomView</a></dt>
-  <dd>Demonstrates implementing a custom view subclass. </dd>
-</dl>
-
-<h3>ImageButton</h3>
-<dl>
-  <dt><a href="ImageButton1.html">ImageButton</a></dt>
-  <dd>Demonstrates an ImageButton: a button with an arbitrary graphic on it. </dd>
-</dl>
-
-<h3>Date Widgets</h3>
-<dl>
-  <dt><a href="DateWidgets1.html">1. Dialog</a></dt>
-  <dd>Demonstrates the DatePickerDialog and TimePickerDialog picker dialogs.</dd>
-
-  <dt><a href="DateWidgets2.html">2. Inline</a></dt>
-  <dd>Demonstrates using a TimePicker directly in a layout without using a confirmation button or dialog.</dd>
-</dl>
-
-<h3>Gallery</h3>
-<dl>
-  <dt><a href="Gallery1.html">1. Icons</a></dt>
-  <dd> Demonstrates implementing a Gallery widget and extending GalleryAdapter to create a custom class to serve out source images to the widget. </dd>
-  
-  <dt><a href="Gallery2.html">2. People</a></dt>
-  <dd>Demonstrates populating a Gallery with images from the contacts photos. </dd>
-</dl>
-
-<h3>Spinner</h3>
-<dl>
-  <dt><a href="Spinner1.html">Spinner</a></dt>
-  <dd> Demonstrates populating two Spinner widgets with values. </dd>
-</dl>
-
-<h3>Grid</h3>
-<dl>
-  <dt><a href="Grid1.html">1. Icon Grid</a></dt>
-  <dd> Demonstrates populating a GridView widget with a list of applications using a custom ListAdapter object.</dd>
-
-  <dt><a href="Grid2.html">2. Photo Grid</a></dt>
-  <dd> Demonstrates populating a GridView widget with images using a custom ListAdapter object. </dd>
-</dl>
-
-<h3>Ticker</h3>
-<dl>
-  <dt><a href="Ticker1.html">Ticker</a></dt>
-  <dd> Demonstrates a Ticker widget, which scrolls text across the screen.</dd>
-</dl>
-
-<h3>ImageSwitcher</h3>
-<dl>
-  <dt><a href="ImageSwitcher1.html">ImageSwitcher</a></dt>
-  <dd>Demonstrates using the ImageSwitcher widget with a custom Adapter.</dd>
-</dl>
-
-<h3>TextSwitcher</h3>
-<dl>
-  <dt><a href="TextSwitcher1.html">TextSwitcher</a></dt>
-  <dd>Demonstrates using the TextSwitcher widget. </dd>
-</dl>
-
-<h3>Animation</h3>
-<dl>
-  <dt><a href="Animation1.html">1. Shake</a></dt>
-  <dd>Demonstrates a simple tweened animation (android.view.animation.Animation). </dd>
-
-  <dt><a href="Animation2.html">2. Push</a></dt>
-  <dd>Demonstrates a variety of transformations (android.view.animation.Animation), including fading, motion, and rotation. </dd>
-</dl>
-
-<h3>Controls</h3>
-<dl>
-  <dt><a href="Controls1.html">1. Theme White</a></dt>
-  <dd>Demonstrates a variety of common form type widgets, such as check boxes and radio buttons using the white theme. </dd>
-</dl>
-<dl>
-  <dt><a href="Controls2.html">2. Theme Dark</a></dt>
-  <dd>Demonstrates a variety of common form type widgets, such as check boxes and radio buttons using the dark theme. </dd>
-</dl>
-
-<h3>Auto Complete</h3>
-<dl>
-  <dt><a href="AutoComplete1.html">1. Screen Top</a></dt>
-  <dd>Demonstrates the use of AutoCompleteTextView, an autocomplete dropdown box below a text box, with data taken from an array. </dd>
-
-  <dt><a href="AutoComplete2.html">2. Screen Bottom</a></dt>
-  <dd>Demonstrates an autocomplete box above a text box.</dd>
-
-  <dt><a href="AutoComplete3.html">3. Scroll</a></dt>
-  <dd>Demonstrates an autocomplete text box in the midst of a vertical list. </dd>
-
-  <dt><a href="AutoComplete4.html">4. Contacts</a></dt>
-  <dd>Demonstrates an autocomplete text box that gets its content from a database query. </dd>
-  
-  <dt><a href="AutoComplete5.html">5. Contacts with Hint</a></dt>
-  <dd>Demonstates an autocomplete text box that understands the * wildcard. </dd>
-</dl>
-
-<h3>Progress Bar</h3>
-<dl>
-  <dt><a href="ProgressBar1.html">1. Incremental</a></dt>
-  <dd>Demonstrates large and small rotating progress indicators that can be incremented or decremented in units. </dd>
-
-  <dt><a href="ProgressBar2.html">2. Smooth</a></dt>
-  <dd>Demonstrates large and small continuously rotating progress indicators used to indicate a generic &quot;busy&quot; message. </dd>
-
-  <dt><a href="ProgressBar3.html">3. Dialogs</a></dt>
-  <dd>Demonstrates a ProgressDialog, a popup dialog that hosts a progress bar. This example demonstrates both determinate and indeterminate progress indicators. </dd>
-
-  <dt><a href="ProgressBar4.html">4. In Title Bar</a></dt>
-  <dd>Demonstrates an Activity screen with a progress indicator loaded by setting the WindowPolicy's progress indicator feature. </dd>
-</dl>
-
-<h3>Focus</h3>
-<dl>
-  <dt><a href="Focus1.html">1. Vertical</a></dt>
-  <dd>Demonstrates how to block selection of a specific screen element. </dd>
-
-  <dt><a href="Focus2.html">2. Horizontal</a></dt>
-  <dd>Demonstrates how to change the order of which screen element is selected when the user presses arrow keys. </dd>
-  
-  <dt><a href="Focus3.html">3. Circular</a></dt>
-  <dd>Another version of Focus2. </dd>
-</dl>
diff --git a/samples/ApiDemos/src/com/example/android/apis/view/_package.html b/samples/ApiDemos/src/com/example/android/apis/view/_package.html
deleted file mode 100644
index 3217336..0000000
--- a/samples/ApiDemos/src/com/example/android/apis/view/_package.html
+++ /dev/null
@@ -1,589 +0,0 @@
-<html>
-<head>
-<link rel="stylesheet" type="text/css" href="assets/style.css" />
-<script type="text/javascript" src="http://www.corp.google.com/style/prettify.js"></script>
-<script src="http://www.corp.google.com/eng/techpubs/include/navbar.js" type="text/javascript"></script>
-
-
-
-</head>
-
-<body>
-
-<p>
-Examples of how to use the android.view and android.widget platform APIs.
-
-For information about view and widget objects, see the topic &quot;Designing
-the UI for an Android application&quot; in the SDK documentation.
-<ol>
-    <li>Layouts
-        <ol>
-            <li>RelativeLayout
-                <ol>
-                    <li>{@link com.android.samples.view.RelativeLayout1
-                        Example 1}</li>
-                    <li>{@link com.android.samples.view.RelativeLayout2
-                        Example 2}</li>
-                </ol>
-            </li>
-            <li>LinearLayout
-                <ol>
-                    <li>{@link com.android.samples.view.LinearLayout1
-                        Example 1}</li>
-                    <li>{@link com.android.samples.view.LinearLayout2 Example
-                        2}</li>
-                    <li>{@link com.android.samples.view.LinearLayout3 Example
-                        3}</li>
-                    <li>{@link com.android.samples.view.LinearLayout4 Example
-                        4}</li>
-                    <li>{@link com.android.samples.view.LinearLayout5 Example
-                        5}</li>
-                    <li>{@link com.android.samples.view.LinearLayout6 Example
-                        6}</li>
-                    <li>{@link com.android.samples.view.LinearLayout7 Example
-                        7}</li>
-                    <li>{@link com.android.samples.view.LinearLayout8 Example
-                        8}</li>
-                </ol>
-            </li>
-            <li>ScrollView
-                <ol>
-                    <li>{@link com.android.samples.view.ScrollView1
-                        Example 1} </li>
-                    <li>{@link com.android.samples.view.ScrollView2 Example
-                        2} </li>
-                </ol>
-            </li>
-            <li>TableLayout
-                <ol>
-                    <li>{@link com.android.samples.view.TableLayout1
-                        Example 1}</li>
-                    <li>{@link com.android.samples.view.TableLayout2 Example
-                        2}</li>
-                    <li>{@link com.android.samples.view.TableLayout3 Example
-                        3}</li>
-                    <li>{@link com.android.samples.view.TableLayout4 Example
-                        4}</li>
-                    <li>{@link com.android.samples.view.TableLayout5 Example
-                        5}</li>
-                    <li>{@link com.android.samples.view.TableLayout6 Example
-                        6}</li>
-                    <li>{@link com.android.samples.view.TableLayout7 Example
-                        7}</li>
-                    <li>{@link com.android.samples.view.TableLayout8 Example
-                        8}</li>
-                    <li>{@link com.android.samples.view.TableLayout9 Example
-                        9}</li>
-                    <li>{@link com.android.samples.view.TableLayout10 Example
-                        10}</li>
-                </ol>
-            </li>
-        </ol>
-    </li>
-    <li>Radio Group
-        <ol>
-            <li>{@link com.android.samples.view.RadioGroup1 Example 1}</li>
-        </ol>
-    </li>
-    <li>ScrollBars
-        <ol>
-            <li>{@link com.android.samples.view.ScrollBar1 Example 1}</li>
-            <li>{@link com.android.samples.view.ScrollBar2 Example 2}</li>
-        </ol>
-    </li>
-    <li>Visibility
-        <ol>
-            <li>{@link com.android.samples.view.Visibility1 Example 1}</li>
-        </ol>
-    </li>
-    <li>Lists
-        <ol>
-            <li>{@link com.android.samples.view.List1 Example 1} </li>
-            <li>{@link com.android.samples.view.List2 Example 2}</li>
-            <li>{@link com.android.samples.view.List3 Example 3}</li>
-            <li>{@link com.android.samples.view.List4 Example 4}</li>
-            <li>{@link com.android.samples.view.List5 Example 5}</li>
-            <li>{@link com.android.samples.view.List6 Example 6}</li>
-            <li>{@link com.android.samples.view.List7 Example 7}</li>
-        </ol>
-    </li>
-    <li>Custom
-        <ol>
-            <li>{@link com.android.samples.view.CustomView1 Example 1}</li>
-        </ol>
-    </li>
-    <li>Gallery
-        <ol>
-            <li>{@link com.android.samples.view.Gallery1 Example 1}</li>
-            <li>{@link com.android.samples.view.Gallery2 Example 2}</li>
-        </ol>
-    </li>
-    <li>Spinner
-        <ol>
-            <li>{@link com.android.samples.view.Spinner1 Example 1}</li>
-        </ol>
-    </li>
-    <li>Grid
-        <ol>
-            <li>{@link com.android.samples.view.Grid1 Example 1}</li>
-        </ol>
-    </li>
-    <li>ImageSwitcher
-        <ol>
-            <li>{@link com.android.samples.view.ImageSwitcher1 Example
-                1}</li>
-        </ol>
-    </li>
-    <li>Animation
-        <ol>
-            <li>{@link com.android.samples.view.Animation1 Example 1}</li>
-            <li>{@link com.android.samples.view.Animation2 Example 1}</li>
-        </ol>
-    </li>
-    <li>Controls
-        <ol>
-            <li>{@link com.android.samples.view.Controls1 Example 1}</li>
-        </ol>
-    </li>
-</ol>
-<p></p>
-
-<h3>LinearLayout Example 1: Stacking Views</h3>
-This example shows a simple use of a LinearLayout. The LinearLayout's height is set to
-<code>android:layout_height="wrap-content"</code>,
-as is the height of each child. Each text view is as tall as it needs
-to be, and the height of the LinearLayout itself is the sum of the height of its children.
-
-<h4>Demo</h4>
-Views/Layouts/LinearLayout/Example 1
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LinearLayout1.java</a></td>
-            <td class="DescrColumn">Loads the linear_layout_1 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/linear_layout_1.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-
-<h3>LinearLayout Example 2: Stacking Views Again</h3>
-In this example, the LinearLayout's height is set
-to <code>android:layout_height="fill-parent"</code>, 
-so the LinearLayout fills the screen. Each text view is as tall as it needs
-to be, so the LinearLayout just stacks them from top to bottom.
-
-<h4>Demo</h4>
-Views/Layouts/LinearLayout/Example 2
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LinearLayout2.java</a></td>
-            <td class="DescrColumn">Loads the linear_layout_2 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/linear_layout_2.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-
-<h3>LinearLayout Example 3: Distributing Extra Space</h3>
-In this example, the LinearLayout's height is set
-to "fill-parent", so the LinearLayout fills the screen. Each text view is as tall as it needs
-to be. However, the middle text view has set <code>android:layout_weight="1"</code>. This means that it
-will get all of the extra space left over after the LinearLayout has sized all of its children.
-
-<h4>Demo</h4>
-Views/Layouts/LinearLayout/Example 3
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LinearLayout3.java</a></td>
-            <td class="DescrColumn">Loads the linear_layout_3 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/linear_layout_3.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-
-<h3>LinearLayout Example 4: Columns</h3>
-This time, the orientation of the LinearLayout is set to horizontal.
-Each of the four child text views has set <code>android:layout_weight="1"</code>
-and <code>android:layout_width="0"</code>.
-This means that each child is initially given a width of 0, and then all of the
-remaining space (the width of the screen) is divided equally among the four
-views.
-
-<h4>Demo</h4>
-Views/Layouts/LinearLayout/Example 4
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LinearLayout4.java</a></td>
-            <td class="DescrColumn">Loads the linear_layout_4 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/linear_layout_4.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-   		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-
-<h3>LinearLayout Example 5: A Simple Form</h3>
-This is a more complete example. It shows:
-<ul>
-	<li>Using nested LinearLayouts (a horizontal layout inside a vertical layout)
-	<li>Using padding on the outer layout
-	<li>Using the <code>layout_gravity</code> attribute to position the horizontal layout
-		on the right side of the screen
-	<li>Using a margin to put some space between buttons
-</ul>
-
-<h4>Demo</h4>
-Views/Layouts/LinearLayout/Example 5
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LinearLayout5.java</a></td>
-            <td class="DescrColumn">Loads the linear_layout_5 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/linear_layout_5.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-   		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-<h3>RelativeLayout Example 1: Stretching</h3>
-There are three views in this example. The first view (view1) is pinned to the top of the screen through the use of this
-attribute: <code>android:layout_alignParentTop="true"</code>. 
-The second view (view2) is pinned to the bottom of the screen: <code>android:layout_alignParentBottom="true"</code>.
-This demonstrates how views can be positioned relative to the RelativeLayout itself.
-
-<p>Views can also be positioned relative to each other as well. In this example, view3 is below view1 and above
-view2: <code>android:layout_above="view2" android:layout_below="view1"</code>. This has the effect of making 
-view3 stretch between view1 and view2.</p> 
-
-<p>Note that since view3 depends on the positions of both view1 and view2, it is defined after them in the layout
-file.</p> 
-
-<h4>Demo</h4>
-Views/Layouts/RelativeLayout/Example 1
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/RelativeLayout1.java</a></td>
-            <td class="DescrColumn">Loads the relative_layout_1 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/relative_layout_1.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-<h3>RelativeLayout Example 2: A Simple Form Revisited</h3>
-The form created in LinearLayout Example 5 is recreated using a RelativeLayout. This example demonstrates:
-
-<ul>
-	<li>Using padding on the outer layout
-	<li>Positioning views realtive to one another using the <code>android:layout_below</code> and 
-	<code>android:layout_below</code> and <code>android:layout_toLeft<code> attributes.
-	<li>Aligning the top edges of the buttons with the <code>android:layout_alignTop<code> attribute
-	<li>Right-aligning the OK button with <code>android:layout_alignParentRight</code>
-	<li>Using a margin to put some space between buttons
-</ul>
-
-<h4>Demo</h4>
-Views/Layouts/RelativeLayout/Example 2
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/RelativeLayout2.java</a></td>
-            <td class="DescrColumn">Loads the relative_layout_2 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/relative_layout_2.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-<h3>Scrolling Example 1</h3>
-All of the layout classes discussed above do not scroll. 
-They simply arrange their children within whatever space is made available to them.
-
-<p>The ScrollView is used to implement vertical scrolling. It does not display any
-content of its own. Instead, it assumes it has one child and pans up and down to keep
-the interesting area of its child in view.</p>
-
-<p>In this example, a ScrollView is used to wrap a LinearLayout. The LinearLayout
-in turn contains a stack of TextViews and Buttons. The ScrollView is as wide as 
-the screen (<code>android:layout_width="fill-parent"</code>) and tall enough to 
-wrap the LinearLayout (<code>android:layout_height="wrap-content"</code>). The 
-LinearLayout uses the same parameters, so it is also as wide as the screen and is as
-tall as the sum of the heigts of all of its children.</p>
-
-<h4>Demo</h4>
-Views/Layouts/ScrollView/Example 1
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/ScrollView1.java</a></td>
-            <td class="DescrColumn">Loads the scroll_view_1 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/scroll_view_1.xml</a></td>
-            <td class="DescrColumn">Defines the layout</td>
-        </tr>
- 		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>       
-</table>
-<h2><a name="Lists">Lists</a></h2>
-<h3>ListView Example 1: A "Hello World" List</h3>
-
-ListViews are used to display vertically scrolling list of information. Unlike the ScrollView, which pans up and 
-down through a set of views that have already been built, the ListView is "virtualized", meaning that views are 
-created only as necessary in order to display what is actually on the screen. ListViews can thus be used to 
-efficiently display very large sets of data. (In this example, the list displays over 600 kinds of cheese.) 
-
-<p>ListViews are highly customizable: you can change where the underlying data comes from, the internal
-representation of the data, and the Views that are used to display the data on the screen. All of this is 
-done with a ListAdapter class. The Android platform includes some ListAdapters that are ready to use, or 
-you can make your own to display custom information. (See ListView Example 4 and ListView Example 5.)</p>
-
-<p>This example uses an existing ListAdapter called ArrayListAdapter. This adapter uses generics to map
-an array of objects to TextViews. In this case we are using an array of Strings.</p>
-
-<p>Note that this example does not have a layout file. This is because the List1 class derives from 
-ListScreen, which will provide a default layout if your activity does not provide an override.</p>
-
-<h4>Demo</h4>
-Views/Lists/Example 1
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/List1.java</a></td>
-            <td class="DescrColumn">Contains code for the List1 class</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-<h3>ListView Example 2: Displaying Data from a Cursor </h3>
-
-It is very common to display data from a database in a ListView. The easiest way to do this is to use a 
-SimpleCursorListAdapter. This is a class that will get data from a Cursor and display the data in 
-each row in Views defined in an XML template.
-
-<p>In this example, the SimpleCursorListAdapter is provided with a cursor that contains a list of all 
-people. Each row will be displayed using the Views defined in this XL file: 
-<a href="" onClick="findCode(this)">//device/apps/common/assets/res/any/layout/simple_list_item_1.xml</a>.
-</p>
-
-<p>When creating a SimpleCursorListAdapter, you also provide a mapping from column names in the 
-Cursor to view ids in the template file. In this case we are mapping the People.NAME column to the
-"text1" TextView.
-</p>
-
-<h4>Demo</h4>
-Views/Lists/Example 2
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/List2.java</a></td>
-            <td class="DescrColumn">Contains code for the List2 class</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/apps/common/assets/res/any/layout/simple_list_item_1.xml</a></td>
-            <td class="DescrColumn">Defines the XML template used for each row. 
-            (Note that this file is provided as part of the Android platform.)</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-<h3>ListView Example 3: Displaying Data from a Cursor, Fancier Version </h3>
-
-This example extends the idea presented in Example 2. Instead of just presenting a list of names, though,
-it shows two lines of information for the selected item (name and phone number). It shows just the name for unselected items. 
-
-<p>
-This example still uses a SimpleCursorListAdapter, but changes the following:</p>
-
-<ul>
-	<li>The Cursor now contains all phone numbers
-	<li>It uses a different template for each row: <a href="" onClick="findCode(this)">//device/apps/common/assets/res/any/layout/simple_list_item_2.xml</a>
-	<li>Since simple_list_item_2.xml contains two views, were mapping two columns 
-	<code>{ Phones.NAME, Phones.NUMBER }</code> to the two views 
-	<code>{ "text1", "text2"}</code>
-	<li>The simple_list_item_2.xml uses a TwoLineListItem view, which is a subclass of LinearLayout that knows to only show
-	the second item when it is selected.
-</ul>
-
-<h4>Demo</h4>
-Views/Lists/Example 3
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/List3.java</a></td>
-            <td class="DescrColumn">Contains code for the List3 class</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/apps/common/assets/res/any/layout/simple_list_item_2.xml</a></td>
-            <td class="DescrColumn">Defines the XML template used for each row. 
-            (Note that this file is provided as part of the Android platform.)</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-<h3>ListView Example 4: Writing a Custom ListAdapter </h3>
-
-The previous examples all used standard ListAdapters. It is also possible to write your own ListAdapters 
-to access data from custom sources.
-
-<p>
-This example introduces a SongListAdapter, which gets its data from an array of titles and an array of lyrics. 
-The SongListAdapter then produces a SongView which is capable of displaying this data.
-</p>  
-
-<p>
-This example also shows how the ListView handles scrolling large items.
-
-<h4>Demo</h4>
-Views/Lists/Example 4
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/List4.java</a></td>
-            <td class="DescrColumn">Contains code for the List4 class, along with a custom ListAdapter and custom View to display the data.</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-
-
-<h3>ListView Example 5: List Separators </h3>
-
-ListView supports the concept of non-selectable "separators" between items. The ListView delegated to its ListAdapter the
-task of deciding whether a given position in the list is a separator or selectable data.
-
-<p><i>This example needs some cleanup.</i></p>
-
-<h4>Demo</h4>
-Views/Lists/Example 5
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/List5.java</a></td>
-            <td class="DescrColumn">Contains code for the List5 class, along with a custom ListAdapter.</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-
-<h2><a name="Working">Working with Views</a></h2>
-
-<h3>Custom View Example 1: LabelView</h3>
-
-
-
-<p>
-Note: This example does not support multi-line or right-to-left text. It is sample code only
-and should not be used in place of the TextView.
-</p>
-
-
-<h4>Demo</h4>
-Views/Custom/Example 1
- 
-<h4>Source files</h4>
-<table class="LinkTable">
-        <tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/CustomView1.java</a></td>
-            <td class="DescrColumn">Loads the custom_view_3 layout resource</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/src/com/android/sdk/view/LabelView.java</a></td>
-            <td class="DescrColumn">Implementation of the custom view</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/assets/res/any/layout/custom_view_1.xml</a></td>
-            <td class="DescrColumn">Defines a layout that uses LabelViews</td>
-        </tr>
-		<tr>
-            <td class="LinkColumn"><a href="" onClick="findCode(this)">//device/samples/SampleCode/AndroidManifest.xml</a></td>
-            <td class="DescrColumn">Defines the activity</td>
-        </tr>
-</table>
-</body>
-</html>
diff --git a/samples/ApiDemos/tests/Android.mk b/samples/ApiDemos/tests/Android.mk
deleted file mode 100644
index f975662..0000000
--- a/samples/ApiDemos/tests/Android.mk
+++ /dev/null
@@ -1,23 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-# We only want this apk build for tests.
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-# Include all test java files.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-# Notice that we don't have to include the src files of ApiDemos because, by
-# running the tests using an instrumentation targeting ApiDemos, we
-# automatically get all of its classes loaded into our environment.
-
-LOCAL_PACKAGE_NAME := ApiDemosTests
-
-LOCAL_INSTRUMENTATION_FOR := ApiDemos
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
diff --git a/samples/ApiDemos/tests/AndroidManifest.xml b/samples/ApiDemos/tests/AndroidManifest.xml
deleted file mode 100644
index 084c88d..0000000
--- a/samples/ApiDemos/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- package name must be unique so suffix with "tests" so package loader doesn't ignore us -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.apis.tests">
-
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-    <!--
-    This declares that this app uses the instrumentation test runner targeting
-    the package of com.example.android.apis.  To run the tests use the command:
-    "adb shell am instrument -w com.example.android.apis.tests/android.test.InstrumentationTestRunner"
-    -->
-    <instrumentation android:name="android.test.InstrumentationTestRunner"
-                     android:targetPackage="com.example.android.apis"
-                     android:label="Tests for Api Demos."/>
-
-</manifest>
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/AllTests.java b/samples/ApiDemos/tests/src/com/example/android/apis/AllTests.java
deleted file mode 100644
index edacb47..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/AllTests.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import android.test.suitebuilder.TestSuiteBuilder;
-
-/**
- * A test suite containing all tests for ApiDemos.
- *
- * To run all suites found in this apk:
- * $ adb shell am instrument -w \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- *
- * To run just this suite from the command line:
- * $ adb shell am instrument -w \
- *   -e class com.example.android.apis.AllTests \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- *
- * To run an individual test case, e.g. {@link com.example.android.apis.os.MorseCodeConverterTest}:
- * $ adb shell am instrument -w \
- *   -e class com.example.android.apis.os.MorseCodeConverterTest \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- *
- * To run an individual test, e.g. {@link com.example.android.apis.os.MorseCodeConverterTest#testCharacterS()}:
- * $ adb shell am instrument -w \
- *   -e class com.example.android.apis.os.MorseCodeConverterTest#testCharacterS \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- */
-public class AllTests extends TestSuite {
-
-    public static Test suite() {
-        return new TestSuiteBuilder(AllTests.class)
-                .includeAllPackagesUnderHere()
-                .build();
-    }
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosApplicationTests.java b/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosApplicationTests.java
deleted file mode 100644
index 3074ca6..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosApplicationTests.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis;
-
-import android.test.ApplicationTestCase;
-import android.test.suitebuilder.annotation.MediumTest;
-import android.test.suitebuilder.annotation.SmallTest;
-
-/**
- * This is a simple framework for a test of an Application.  See 
- * {@link android.test.ApplicationTestCase ApplicationTestCase} for more information on 
- * how to write and extend Application tests.
- * 
- * To run this test, you can type:
- * adb shell am instrument -w \
- *   -e class com.example.android.apis.ApiDemosApplicationTests \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- */
-public class ApiDemosApplicationTests extends ApplicationTestCase<ApiDemosApplication> {
-
-    public ApiDemosApplicationTests() {
-        super(ApiDemosApplication.class);
-      }
-
-      @Override
-      protected void setUp() throws Exception {
-          super.setUp();
-      }
-
-      /**
-       * The name 'test preconditions' is a convention to signal that if this
-       * test doesn't pass, the test case was not set up properly and it might
-       * explain any and all failures in other tests.  This is not guaranteed
-       * to run before other tests, as junit uses reflection to find the tests.
-       */
-      @SmallTest
-      public void testPreconditions() {
-      }
-      
-      /**
-       * Test basic startup/shutdown of Application
-       */
-      @MediumTest
-      public void testSimpleCreate() {
-          createApplication(); 
-      }
-      
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosTest.java
deleted file mode 100644
index 0103da8..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/ApiDemosTest.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis;
-
-import android.test.ActivityInstrumentationTestCase;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityInstrumentationTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class ApiDemosTest extends ActivityInstrumentationTestCase<ApiDemos> {
-
-    public ApiDemosTest() {
-        super("com.example.android.apis", ApiDemos.class);
-    }
-
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/app/ForwardingTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/app/ForwardingTest.java
deleted file mode 100644
index 340bedb..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/app/ForwardingTest.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import com.example.android.apis.R;
-import com.example.android.apis.view.Focus2ActivityTest;
-
-import android.content.Context;
-import android.content.Intent;
-import android.test.ActivityUnitTestCase;
-import android.test.suitebuilder.annotation.MediumTest;
-import android.widget.Button;
-
-/**
- * This demonstrates completely isolated "unit test" of an Activity class.
- *
- * <p>This model for testing creates the entire Activity (like {@link Focus2ActivityTest}) but does
- * not attach it to the system (for example, it cannot launch another Activity).  It allows you to
- * inject additional behaviors via the 
- * {@link android.test.ActivityUnitTestCase#setActivityContext(Context)} and 
- * {@link android.test.ActivityUnitTestCase#setApplication(android.app.Application)} methods.  
- * It also allows you to more carefully test your Activity's performance 
- * Writing unit tests in this manner requires more care and attention, but allows you to test
- * very specific behaviors, and can also be an easier way to test error conditions.
- * 
- * <p>Because ActivityUnitTestCase creates the Activity under test completely outside of
- * the usual system, tests of layout and point-click UI interaction are much less useful
- * in this configuration.  It's more useful here to concentrate on tests that involve the 
- * underlying data model, internal business logic, or exercising your Activity's life cycle.
- *
- * <p>See {@link com.example.android.apis.AllTests} for documentation on running
- * all tests and individual tests in this application.
- */
-public class ForwardingTest extends ActivityUnitTestCase<Forwarding> {
-
-    private Intent mStartIntent;
-    private Button mButton;
-
-    public ForwardingTest() {
-        super(Forwarding.class);
-      }
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-
-        // In setUp, you can create any shared test data, or set up mock components to inject
-        // into your Activity.  But do not call startActivity() until the actual test methods.
-        mStartIntent = new Intent(Intent.ACTION_MAIN);
-    }
-
-    /**
-     * The name 'test preconditions' is a convention to signal that if this
-     * test doesn't pass, the test case was not set up properly and it might
-     * explain any and all failures in other tests.  This is not guaranteed
-     * to run before other tests, as junit uses reflection to find the tests.
-     */
-    @MediumTest
-    public void testPreconditions() {
-        startActivity(mStartIntent, null, null);
-        mButton = (Button) getActivity().findViewById(R.id.go);
-        
-        assertNotNull(getActivity());
-        assertNotNull(mButton);
-    }
-    
-    /**
-     * This test demonstrates examining the way that activity calls startActivity() to launch 
-     * other activities.
-     */
-    @MediumTest
-    public void testSubLaunch() {
-        Forwarding activity = startActivity(mStartIntent, null, null);
-        mButton = (Button) activity.findViewById(R.id.go);
-        
-        // This test confirms that when you click the button, the activity attempts to open
-        // another activity (by calling startActivity) and close itself (by calling finish()).
-        mButton.performClick();
-        
-        assertNotNull(getStartedActivityIntent());
-        assertTrue(isFinishCalled());
-    }
-    
-    /**
-     * This test demonstrates ways to exercise the Activity's life cycle.
-     */
-    @MediumTest
-    public void testLifeCycleCreate() {
-        Forwarding activity = startActivity(mStartIntent, null, null);
-        
-        // At this point, onCreate() has been called, but nothing else
-        // Complete the startup of the activity
-        getInstrumentation().callActivityOnStart(activity);
-        getInstrumentation().callActivityOnResume(activity);
-        
-        // At this point you could test for various configuration aspects, or you could 
-        // use a Mock Context to confirm that your activity has made certain calls to the system
-        // and set itself up properly.
-        
-        getInstrumentation().callActivityOnPause(activity);
-        
-        // At this point you could confirm that the activity has paused properly, as if it is
-        // no longer the topmost activity on screen.
-        
-        getInstrumentation().callActivityOnStop(activity);
-        
-        // At this point, you could confirm that the activity has shut itself down appropriately,
-        // or you could use a Mock Context to confirm that your activity has released any system
-        // resources it should no longer be holding.
-
-        // ActivityUnitTestCase.tearDown(), which is always automatically called, will take care
-        // of calling onDestroy().
-    }
-
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/app/LocalServiceTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/app/LocalServiceTest.java
deleted file mode 100644
index 78fee41..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/app/LocalServiceTest.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.app;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.content.Context;
-import android.content.Intent;
-import android.os.Handler;
-import android.os.IBinder;
-import android.test.MoreAsserts;
-import android.test.ServiceTestCase;
-import android.test.suitebuilder.annotation.MediumTest;
-import android.test.suitebuilder.annotation.SmallTest;
-
-/**
- * This is a simple framework for a test of a Service.  See {@link android.test.ServiceTestCase
- * ServiceTestCase} for more information on how to write and extend service tests.
- * 
- * To run this test, you can type:
- * adb shell am instrument -w \
- *   -e class com.example.android.apis.app.LocalServiceTest \
- *   com.example.android.apis.tests/android.test.InstrumentationTestRunner
- */
-public class LocalServiceTest extends ServiceTestCase<LocalService> {
-
-    public LocalServiceTest() {
-      super(LocalService.class);
-    }
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-    }
-
-    /**
-     * The name 'test preconditions' is a convention to signal that if this
-     * test doesn't pass, the test case was not set up properly and it might
-     * explain any and all failures in other tests.  This is not guaranteed
-     * to run before other tests, as junit uses reflection to find the tests.
-     */
-    @SmallTest
-    public void testPreconditions() {
-    }
-    
-    /**
-     * Test basic startup/shutdown of Service
-     */
-    @SmallTest
-    public void testStartable() {
-        Intent startIntent = new Intent();
-        startIntent.setClass(getContext(), LocalService.class);
-        startService(startIntent); 
-    }
-    
-    /**
-     * Test binding to service
-     */
-    @MediumTest
-    public void testBindable() {
-        Intent startIntent = new Intent();
-        startIntent.setClass(getContext(), LocalService.class);
-        IBinder service = bindService(startIntent); 
-    }
-    
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/os/MorseCodeConverterTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/os/MorseCodeConverterTest.java
deleted file mode 100644
index 7cf0395..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/os/MorseCodeConverterTest.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.os;
-
-import junit.framework.TestCase;
-import android.test.suitebuilder.annotation.SmallTest;
-
-/**
- * An example of a true unit test that tests the utility class {@link MorseCodeConverter}.
- * Since this test doesn't need a {@link android.content.Context}, or any other
- * dependencies injected, it simply extends the standard {@link TestCase}.
- *
- * See {@link com.example.android.apis.AllTests} for documentation on running
- * all tests and individual tests in this application.
- */
-public class MorseCodeConverterTest extends TestCase {
-
-    @SmallTest
-    public void testCharacterS() throws Exception {
-
-        long[] expectedBeeps = {
-                MorseCodeConverter.DOT,
-                MorseCodeConverter.DOT,
-                MorseCodeConverter.DOT,
-                MorseCodeConverter.DOT,
-                MorseCodeConverter.DOT};
-        long[] beeps = MorseCodeConverter.pattern('s');
-
-        assertArraysEqual(expectedBeeps, beeps);
-    }
-
-    private void assertArraysEqual(long[] expected, long[] actual) {
-        assertEquals("Unexpected array length.", expected.length, actual.length);
-        for (int i = 0; i < expected.length; i++) {
-            long expectedLong = expected[i];
-            long actualLong = actual[i];
-            assertEquals("Unexpected long at index: " + i, expectedLong, actualLong);
-        }
-    }
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2ActivityTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2ActivityTest.java
deleted file mode 100644
index 91f712f..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2ActivityTest.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.test.ActivityInstrumentationTestCase;
-import android.test.suitebuilder.annotation.MediumTest;
-import android.view.KeyEvent;
-import android.widget.Button;
-
-/**
- * An example of an {@link ActivityInstrumentationTestCase} of a specific activity {@link Focus2}.
- * By virtue of extending {@link ActivityInstrumentationTestCase}, the target activity is automatically
- * launched and finished before and after each test.  This also extends
- * {@link android.test.InstrumentationTestCase}, which provides
- * access to methods for sending events to the target activity, such as key and
- * touch events.  See {@link #sendKeys}.
- *
- * In general, {@link android.test.InstrumentationTestCase}s and {@link ActivityInstrumentationTestCase}s
- * are heavier weight functional tests available for end to end testing of your
- * user interface.  When run via a {@link android.test.InstrumentationTestRunner},
- * the necessary {@link android.app.Instrumentation} will be injected for you to
- * user via {@link #getInstrumentation} in your tests.
- *
- * See {@link com.example.android.apis.app.ForwardingTest} for an example of an Activity unit test.
- *
- * See {@link com.example.android.apis.AllTests} for documentation on running
- * all tests and individual tests in this application.
- */
-public class Focus2ActivityTest extends ActivityInstrumentationTestCase<Focus2> {
-
-    private Button mLeftButton;
-    private Button mCenterButton;
-    private Button mRightButton;
-
-
-    public Focus2ActivityTest() {
-        super("com.example.android.apis", Focus2.class);
-    }
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        final Focus2 a = getActivity();
-        mLeftButton = (Button) a.findViewById(R.id.leftButton);
-        mCenterButton = (Button) a.findViewById(R.id.centerButton);
-        mRightButton = (Button) a.findViewById(R.id.rightButton);
-    }
-
-    /**
-     * The name 'test preconditions' is a convention to signal that if this
-     * test doesn't pass, the test case was not set up properly and it might
-     * explain any and all failures in other tests.  This is not guaranteed
-     * to run before other tests, as junit uses reflection to find the tests.
-     */
-    @MediumTest
-    public void testPreconditions() {
-        assertTrue("center button should be right of left button",
-                mLeftButton.getRight() < mCenterButton.getLeft());
-        assertTrue("right button should be right of center button",
-                mCenterButton.getRight() < mRightButton.getLeft());
-        assertTrue("left button should be focused", mLeftButton.isFocused());
-    }
-
-    @MediumTest
-    public void testGoingRightFromLeftButtonJumpsOverCenterToRight() {
-        sendKeys(KeyEvent.KEYCODE_DPAD_RIGHT);
-        assertTrue("right button should be focused", mRightButton.isFocused());
-    }
-
-    @MediumTest
-    public void testGoingLeftFromRightButtonGoesToCenter()  {
-        // Give right button focus by having it request focus.  We post it
-        // to the UI thread because we are not running on the same thread, and
-        // any direct api calls that change state must be made from the UI thread.
-        // This is in contrast to instrumentation calls that send events that are
-        // processed through the framework and eventually find their way to
-        // affecting the ui thread.
-        getActivity().runOnUiThread(new Runnable() {
-            public void run() {
-                mRightButton.requestFocus();
-            }
-        });
-        // wait for the request to go through
-        getInstrumentation().waitForIdleSync();
-
-        assertTrue(mRightButton.isFocused());
-
-        sendKeys(KeyEvent.KEYCODE_DPAD_LEFT);
-        assertTrue("center button should be focused", mCenterButton.isFocused());
-    }
-}
diff --git a/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2AndroidTest.java b/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2AndroidTest.java
deleted file mode 100644
index b52e4b8..0000000
--- a/samples/ApiDemos/tests/src/com/example/android/apis/view/Focus2AndroidTest.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.apis.view;
-
-import com.example.android.apis.R;
-
-import android.content.Context;
-import android.test.AndroidTestCase;
-import android.test.suitebuilder.annotation.SmallTest;
-import android.view.FocusFinder;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.Button;
-
-/**
- * This exercises the same logic as {@link Focus2ActivityTest} but in a lighter
- * weight manner; it doesn't need to launch the activity, and it can test the
- * focus behavior by calling {@link FocusFinder} methods directly.
- *
- * {@link Focus2ActivityTest} is still useful to verify that, at an end to end
- * level, key events actually translate to focus transitioning in the way we expect.
- * A good complementary way to use both types of tests might be to have more exhaustive
- * coverage in the lighter weight test case, and a few end to end scenarios in the
- * functional {@link android.test.ActivityInstrumentationTestCase}.  This would provide reasonable
- * assurance that the end to end system is working, while avoiding the overhead of
- * having every corner case exercised in the slower, heavier weight way.
- *
- * Even as a lighter weight test, this test still needs access to a {@link Context}
- * to inflate the file, which is why it extends {@link AndroidTestCase}.
- * 
- * If you ever need a context to do your work in tests, you can extend
- * {@link AndroidTestCase}, and when run via an {@link android.test.InstrumentationTestRunner},
- * the context will be injected for you.
- * 
- * See {@link com.example.android.apis.app.ForwardingTest} for an example of an Activity unit test.
- *
- * See {@link com.example.android.apis.AllTests} for documentation on running
- * all tests and individual tests in this application.
- */
-public class Focus2AndroidTest extends AndroidTestCase {
-
-    private FocusFinder mFocusFinder;
-
-    private ViewGroup mRoot;
-
-    private Button mLeftButton;
-    private Button mCenterButton;
-    private Button mRightButton;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-
-        mFocusFinder = FocusFinder.getInstance();
-
-        // inflate the layout
-        final Context context = getContext();
-        final LayoutInflater inflater = LayoutInflater.from(context);
-        mRoot = (ViewGroup) inflater.inflate(R.layout.focus_2, null);
-
-        // manually measure it, and lay it out
-        mRoot.measure(500, 500);
-        mRoot.layout(0, 0, 500, 500);
-
-        mLeftButton = (Button) mRoot.findViewById(R.id.leftButton);
-        mCenterButton = (Button) mRoot.findViewById(R.id.centerButton);
-        mRightButton = (Button) mRoot.findViewById(R.id.rightButton);
-    }
-
-    /**
-     * The name 'test preconditions' is a convention to signal that if this
-     * test doesn't pass, the test case was not set up properly and it might
-     * explain any and all failures in other tests.  This is not guaranteed
-     * to run before other tests, as junit uses reflection to find the tests.
-     */
-    @SmallTest
-    public void testPreconditions() {
-        assertNotNull(mLeftButton);
-        assertTrue("center button should be right of left button",
-                mLeftButton.getRight() < mCenterButton.getLeft());
-        assertTrue("right button should be right of center button",
-                mCenterButton.getRight() < mRightButton.getLeft());
-    }
-
-    @SmallTest
-    public void testGoingRightFromLeftButtonJumpsOverCenterToRight() {
-        assertEquals("right should be next focus from left",
-                mRightButton,
-                mFocusFinder.findNextFocus(mRoot, mLeftButton, View.FOCUS_RIGHT));
-    }
-
-    @SmallTest
-    public void testGoingLeftFromRightButtonGoesToCenter() {
-        assertEquals("center should be next focus from right",
-                mCenterButton,
-                mFocusFinder.findNextFocus(mRoot, mRightButton, View.FOCUS_LEFT));
-    }
-}
diff --git a/samples/Compass/Android.mk b/samples/Compass/Android.mk
deleted file mode 100644
index 9434582..0000000
--- a/samples/Compass/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := Compass
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/Compass/AndroidManifest.xml b/samples/Compass/AndroidManifest.xml
deleted file mode 100644
index 9aa5636..0000000
--- a/samples/Compass/AndroidManifest.xml
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file describes the code in the Compass package, which is
-     used by the system to determine how to start your application and
-     integrate it with the rest of the system.  -->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.compass">
-
-    <!-- This package contains an application...  The 'label' is the name
-         to display to the user for the overall application, and provides
-         a default label for all following components.  The syntax here is a
-         reference to one of our string resources.-->
-    <application android:label="@string/compass_app">
-
-        <!-- An Activity in the application - this is something the user
-             can launch and interact with.  The "name" attribute is the
-             name of the class within your package that implements this
-             activity. -->
-        <activity android:name="CompassActivity">
-
-            <!-- An IntentFilter tells the system when it should use your
-                 activity.  This allows the user to get to your activity
-                 without someone having to explicitly know to launch your
-                 class "com.example.android.compass_app.CompassActivity". -->
-            <intent-filter>
-                <!-- The MAIN action describes a main entry point into an
-                     activity, without any associated data. -->
-                <action android:name="android.intent.action.MAIN" />
-
-                <!-- This places this activity into the main app list. -->
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-
-        </activity>
-
-    </application>
-
-</manifest>
diff --git a/samples/Compass/res/values/strings.xml b/samples/Compass/res/values/strings.xml
deleted file mode 100644
index 7cf3da4..0000000
--- a/samples/Compass/res/values/strings.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file contains resource definitions for displayed strings, allowing
-     them to be changed based on the locale and options. -->
-
-<resources>
-    <!-- Simple strings. -->
-    <string name="compass_app">Compass</string>
-</resources>
-
diff --git a/samples/Compass/src/com/example/android/compass/CompassActivity.java b/samples/Compass/src/com/example/android/compass/CompassActivity.java
deleted file mode 100644
index c4b9566..0000000
--- a/samples/Compass/src/com/example/android/compass/CompassActivity.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.compass;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.FloatBuffer;
-
-import javax.microedition.khronos.egl.EGL10;
-import javax.microedition.khronos.egl.EGLConfig;
-import javax.microedition.khronos.opengles.GL10;
-import static javax.microedition.khronos.opengles.GL10.*;
-
-import android.app.Activity;
-import android.content.Context;
-import android.hardware.Sensor;
-import android.hardware.SensorEvent;
-import android.hardware.SensorEventListener;
-import android.hardware.SensorManager;
-import android.opengl.GLSurfaceView;
-import android.opengl.GLSurfaceView.Renderer;
-import android.os.Bundle;
-import android.util.Log;
-
-/**
- * This class provides a basic demonstration of how to use the
- * {@link android.hardware.SensorManager SensorManager} API to draw
- * a 3D compass.
- */
-public class CompassActivity extends Activity implements Renderer, SensorEventListener {
-    private GLSurfaceView mGLSurfaceView;
-    private SensorManager mSensorManager;
-    private float[] mGData = new float[3];
-    private float[] mMData = new float[3];
-    private float[] mR = new float[16];
-    private float[] mI = new float[16];
-    private FloatBuffer mVertexBuffer;
-    private FloatBuffer mColorBuffer;
-    private ByteBuffer mIndexBuffer;
-    private float[] mOrientation = new float[3];
-    private int mCount;
-
-    public CompassActivity() {
-    }
-
-    /** Called with the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        mSensorManager = (SensorManager)getSystemService(Context.SENSOR_SERVICE);
-        mGLSurfaceView = new GLSurfaceView(this);
-        mGLSurfaceView.setRenderer(this);
-        setContentView(mGLSurfaceView);
-    }
-
-    @Override
-    protected void onResume() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onResume();
-        mGLSurfaceView.onResume();
-        Sensor gsensor = mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);
-        Sensor msensor = mSensorManager.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD);
-        mSensorManager.registerListener(this, gsensor, SensorManager.SENSOR_DELAY_GAME);
-        mSensorManager.registerListener(this, msensor, SensorManager.SENSOR_DELAY_GAME);
-    }
-
-    @Override
-    protected void onPause() {
-        // Ideally a game should implement onResume() and onPause()
-        // to take appropriate action when the activity looses focus
-        super.onPause();
-        mGLSurfaceView.onPause();
-        mSensorManager.unregisterListener(this);
-    }
-
-    public int[] getConfigSpec() {
-        // We want a depth buffer, don't care about the
-        // details of the color buffer.
-        int[] configSpec = {
-                EGL10.EGL_DEPTH_SIZE,   16,
-                EGL10.EGL_NONE
-        };
-        return configSpec;
-    }
-
-    public void onDrawFrame(GL10 gl) {
-        /*
-         * Usually, the first thing one might want to do is to clear
-         * the screen. The most efficient way of doing this is to use
-         * glClear().
-         */
-
-        gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-
-        /*
-         * Now we're ready to draw some 3D objects
-         */
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-        gl.glTranslatef(0, 0, -2);
-
-        /*
-         * All the magic happens here. The rotation matrix mR reported by
-         * SensorManager.getRotationMatrix() is a 4x4 row-major matrix.
-         * We need to use its inverse for rendering. The inverse is
-         * simply calculated by taking the matrix' transpose. However, since
-         * glMultMatrixf() expects a column-major matrix, we can use mR
-         * directly!
-         */
-        gl.glMultMatrixf(mR, 0);
-        // some test code which will be used/cleaned up before we ship this.
-        //gl.glMultMatrixf(mI, 0);
-
-        gl.glVertexPointer(3, GL_FLOAT, 0, mVertexBuffer);
-        gl.glColorPointer(4, GL_FLOAT, 0, mColorBuffer);
-        gl.glDrawElements(GL_LINES, 6, GL_UNSIGNED_BYTE, mIndexBuffer);
-    }
-
-    public void onSurfaceChanged(GL10 gl, int width, int height) {
-        gl.glViewport(0, 0, width, height);
-
-        /*
-         * Set our projection matrix. This doesn't have to be done
-         * each time we draw, but usually a new projection needs to
-         * be set when the viewport is resized.
-         */
-
-        float ratio = (float) width / height;
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glLoadIdentity();
-        gl.glFrustumf(-ratio, ratio, -1, 1, 1, 10);
-    }
-
-    public void onSurfaceCreated(GL10 gl, EGLConfig config) {
-        /*
-         * By default, OpenGL enables features that improve quality
-         * but reduce performance. One might want to tweak that
-         * especially on software renderer.
-         */
-        gl.glDisable(GL10.GL_DITHER);
-
-        /*
-         * Some one-time OpenGL initialization can be made here
-         * probably based on features of this particular context
-         */
-        gl.glClearColor(1,1,1,1);
-        gl.glEnable(GL10.GL_CULL_FACE);
-        gl.glShadeModel(GL10.GL_SMOOTH);
-        gl.glEnable(GL10.GL_DEPTH_TEST);
-
-        /*
-         * create / load the our 3D models here
-         */
-
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-        gl.glEnableClientState(GL10.GL_COLOR_ARRAY);
-
-        float vertices[] = {
-                0,0,0,
-                1,0,0,
-                0,1,0,
-                0,0,1
-        };
-        float colors[] = {
-                0,0,0,0,
-                1,0,0,1,
-                0,1,0,1,
-                0,0,1,1
-        };
-        byte indices[] = { 0, 1, 0, 2, 0, 3 };
-
-        // Buffers to be passed to gl*Pointer() functions
-        // must be direct, i.e., they must be placed on the
-        // native heap where the garbage collector cannot
-        // move them.
-        //
-        // Buffers with multi-byte datatypes (e.g., short, int, float)
-        // must have their byte order set to native order
-
-        ByteBuffer vbb;
-        vbb = ByteBuffer.allocateDirect(vertices.length*4);
-        vbb.order(ByteOrder.nativeOrder());
-        mVertexBuffer = vbb.asFloatBuffer();
-        mVertexBuffer.put(vertices);
-        mVertexBuffer.position(0);
-
-        vbb = ByteBuffer.allocateDirect(colors.length*4);
-        vbb.order(ByteOrder.nativeOrder());
-        mColorBuffer = vbb.asFloatBuffer();
-        mColorBuffer.put(colors);
-        mColorBuffer.position(0);
-
-        mIndexBuffer = ByteBuffer.allocateDirect(indices.length);
-        mIndexBuffer.put(indices);
-        mIndexBuffer.position(0);
-    }
-
-    public void onAccuracyChanged(Sensor sensor, int accuracy) {
-    }
-
-    public void onSensorChanged(SensorEvent event) {
-        int type = event.sensor.getType();
-        float[] data;
-        if (type == Sensor.TYPE_ACCELEROMETER) {
-            data = mGData;
-        } else if (type == Sensor.TYPE_MAGNETIC_FIELD) {
-            data = mMData;
-        } else {
-            // we should not be here.
-            return;
-        }
-        for (int i=0 ; i<3 ; i++)
-            data[i] = event.values[i];
-
-        SensorManager.getRotationMatrix(mR, mI, mGData, mMData);
-// some test code which will be used/cleaned up before we ship this.
-//        SensorManager.remapCoordinateSystem(mR,
-//                SensorManager.AXIS_X, SensorManager.AXIS_Z, mR);
-//        SensorManager.remapCoordinateSystem(mR,
-//                SensorManager.AXIS_Y, SensorManager.AXIS_MINUS_X, mR);
-        SensorManager.getOrientation(mR, mOrientation);
-        float incl = SensorManager.getInclination(mI);
-
-        if (mCount++ > 50) {
-            final float rad2deg = (float)(180.0f/Math.PI);
-            mCount = 0;
-            Log.d("Compass", "yaw: " + (int)(mOrientation[0]*rad2deg) +
-                    "  pitch: " + (int)(mOrientation[1]*rad2deg) +
-                    "  roll: " + (int)(mOrientation[2]*rad2deg) +
-                    "  incl: " + (int)(incl*rad2deg)
-                    );
-        }
-    }
-}
diff --git a/samples/GlobalTime/Android.mk b/samples/GlobalTime/Android.mk
deleted file mode 100644
index deb82f5..0000000
--- a/samples/GlobalTime/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := optional
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := GlobalTime
-
-include $(BUILD_PACKAGE)
diff --git a/samples/GlobalTime/AndroidManifest.xml b/samples/GlobalTime/AndroidManifest.xml
deleted file mode 100644
index 7aee91b..0000000
--- a/samples/GlobalTime/AndroidManifest.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.globaltime">
-    <application android:icon="@drawable/app_global_time"
-            android:label="Global Time">
-        <activity android:name="GlobalTime"
-                android:theme="@style/Theme">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />                                            
-            </intent-filter>
-        </activity>
-    </application>
-</manifest>
diff --git a/samples/GlobalTime/MODULE_LICENSE_APACHE2 b/samples/GlobalTime/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/samples/GlobalTime/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/samples/GlobalTime/NOTICE b/samples/GlobalTime/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/samples/GlobalTime/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/samples/GlobalTime/assets/cities_en.dat b/samples/GlobalTime/assets/cities_en.dat
deleted file mode 100644
index c982ef4..0000000
--- a/samples/GlobalTime/assets/cities_en.dat
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/assets/earth.raw b/samples/GlobalTime/assets/earth.raw
deleted file mode 100644
index f884e75..0000000
--- a/samples/GlobalTime/assets/earth.raw
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/assets/lights.dat b/samples/GlobalTime/assets/lights.dat
deleted file mode 100644
index 14d4f36..0000000
--- a/samples/GlobalTime/assets/lights.dat
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/assets/tz512.raw b/samples/GlobalTime/assets/tz512.raw
deleted file mode 100644
index 3ce1d5c..0000000
--- a/samples/GlobalTime/assets/tz512.raw
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/assets/world.gles b/samples/GlobalTime/assets/world.gles
deleted file mode 100644
index 815db1e..0000000
--- a/samples/GlobalTime/assets/world.gles
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/res/drawable/app_global_time.png b/samples/GlobalTime/res/drawable/app_global_time.png
deleted file mode 100644
index 914977d..0000000
--- a/samples/GlobalTime/res/drawable/app_global_time.png
+++ /dev/null
Binary files differ
diff --git a/samples/GlobalTime/res/layout/global_time.xml b/samples/GlobalTime/res/layout/global_time.xml
deleted file mode 100644
index 237207f..0000000
--- a/samples/GlobalTime/res/layout/global_time.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<EditText xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:textSize="18sp"
-    android:text="@string/global_time_text_text" />
-
-
diff --git a/samples/GlobalTime/res/values/strings.xml b/samples/GlobalTime/res/values/strings.xml
deleted file mode 100644
index d35c059..0000000
--- a/samples/GlobalTime/res/values/strings.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-* Copyright (C) 2007 The Android Open Source Project
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-*      http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
--->
-
-<resources>
-
-    <string name="global_time_text_text">Global Time</string>
-
-</resources>
diff --git a/samples/GlobalTime/res/values/styles.xml b/samples/GlobalTime/res/values/styles.xml
deleted file mode 100644
index 6051f0f..0000000
--- a/samples/GlobalTime/res/values/styles.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Calendar/assets/res/any/styles.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-<resources>
-    <style name="Theme" parent="android:Theme.Black">
-        <item name="android:windowNoTitle">true</item>
-        <item name="android:windowBackground">@null</item>
-        <!-- <item name="android:windowFrame">@null</item> -->
-    </style>
-</resources>
diff --git a/samples/GlobalTime/src/com/android/globaltime/Annulus.java b/samples/GlobalTime/src/com/android/globaltime/Annulus.java
deleted file mode 100644
index b811d88..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/Annulus.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * A class that draws a ring with a given center and inner and outer radii.
- * The inner and outer rings each have a color and the remaining pixels are
- * colored by interpolation.  GlobalTime uses this class to simulate an
- * "atmosphere" around the earth.
- */
-public class Annulus extends Shape {
-
-    /**
-     * Constructs an annulus.
-     * 
-     * @param centerX the X coordinate of the center point
-     * @param centerY the Y coordinate of the center point
-     * @param Z the fixed Z for the entire ring
-     * @param innerRadius the inner radius
-     * @param outerRadius the outer radius
-     * @param rInner the red channel of the color of the inner ring
-     * @param gInner the green channel of the color of the inner ring
-     * @param bInner the blue channel of the color of the inner ring
-     * @param aInner the alpha channel of the color of the inner ring
-     * @param rOuter the red channel of the color of the outer ring
-     * @param gOuter the green channel of the color of the outer ring
-     * @param bOuter the blue channel of the color of the outer ring
-     * @param aOuter the alpha channel of the color of the outer ring
-     * @param sectors the number of sectors used to approximate curvature
-     */
-    public Annulus(float centerX, float centerY, float Z,
-        float innerRadius, float outerRadius,
-        float rInner, float gInner, float bInner, float aInner,
-        float rOuter, float gOuter, float bOuter, float aOuter,
-        int sectors) {
-        super(GL10.GL_TRIANGLES, GL10.GL_UNSIGNED_SHORT,
-              false, false, true);
-
-        int radii = sectors + 1;
-
-        int[] vertices = new int[2 * 3 * radii];
-        int[] colors = new int[2 * 4 * radii];
-        short[] indices = new short[2 * 3 * radii];
-
-        int vidx = 0;
-        int cidx = 0;
-        int iidx = 0;
-
-        for (int i = 0; i < radii; i++) {
-            float theta = (i * TWO_PI) / (radii - 1);
-            float cosTheta = (float) Math.cos(theta);
-            float sinTheta = (float) Math.sin(theta);
-
-            vertices[vidx++] = toFixed(centerX + innerRadius * cosTheta);
-            vertices[vidx++] = toFixed(centerY + innerRadius * sinTheta);
-            vertices[vidx++] = toFixed(Z);
-
-            vertices[vidx++] = toFixed(centerX + outerRadius * cosTheta);
-            vertices[vidx++] = toFixed(centerY + outerRadius * sinTheta);
-            vertices[vidx++] = toFixed(Z);
-        
-            colors[cidx++] = toFixed(rInner);
-            colors[cidx++] = toFixed(gInner);
-            colors[cidx++] = toFixed(bInner);
-            colors[cidx++] = toFixed(aInner);
-
-            colors[cidx++] = toFixed(rOuter);
-            colors[cidx++] = toFixed(gOuter);
-            colors[cidx++] = toFixed(bOuter);
-            colors[cidx++] = toFixed(aOuter);
-        }
-
-        for (int i = 0; i < sectors; i++) {
-            indices[iidx++] = (short) (2 * i);
-            indices[iidx++] = (short) (2 * i + 1);
-            indices[iidx++] = (short) (2 * i + 2);
-
-            indices[iidx++] = (short) (2 * i + 1);
-            indices[iidx++] = (short) (2 * i + 3);
-            indices[iidx++] = (short) (2 * i + 2);
-        }
-        
-        allocateBuffers(vertices, null, null, colors, indices);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/City.java b/samples/GlobalTime/src/com/android/globaltime/City.java
deleted file mode 100644
index 0b4cb84..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/City.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.TimeZone;
-
-/**
- * A class representing a city, with an associated position, time zone name,
- * and raw offset from UTC.
- */
-public  class City implements Comparable<City> {
-
-    private static Map<String,City> cities = new HashMap<String,City>();
-    private static City[] citiesByRawOffset;
-
-    private String name;
-    private String timeZoneID;
-    private TimeZone timeZone = null;
-    private int rawOffset;
-    private float latitude, longitude;
-    private float x, y, z;
-    
-    /**
-     * Loads the city database.  The cities must be stored in order by raw
-     * offset from UTC.
-     */
-    public static void loadCities(InputStream is) throws IOException {
-        DataInputStream dis = new DataInputStream(is);
-        int numCities = dis.readInt();
-        citiesByRawOffset = new City[numCities];
-
-        byte[] buf = new byte[24];
-        for (int i = 0; i < numCities; i++) {
-            String name = dis.readUTF();
-            String tzid = dis.readUTF();
-            dis.read(buf);
-  
-//          The code below is a faster version of:            
-//          int rawOffset = dis.readInt();
-//          float latitude = dis.readFloat();
-//          float longitude = dis.readFloat();
-//          float cx = dis.readFloat();
-//          float cy = dis.readFloat();
-//          float cz = dis.readFloat();
-
-            int rawOffset =
-                       (buf[ 0] << 24) |       ((buf[ 1] & 0xff) << 16) |
-                      ((buf[ 2] & 0xff) << 8) | (buf[ 3] & 0xff);
-            int ilat = (buf[ 4] << 24) |       ((buf[ 5] & 0xff) << 16) |
-                      ((buf[ 6] & 0xff) << 8) | (buf[ 7] & 0xff);
-            int ilon = (buf[ 8] << 24) |       ((buf[ 9] & 0xff) << 16) |
-                      ((buf[10] & 0xff) << 8) | (buf[11] & 0xff);
-            int icx =  (buf[12] << 24) |       ((buf[13] & 0xff) << 16) |
-                      ((buf[14] & 0xff) << 8) | (buf[15] & 0xff);
-            int icy =  (buf[16] << 24) |       ((buf[17] & 0xff) << 16) |
-                      ((buf[18] & 0xff) << 8) | (buf[19] & 0xff);
-            int icz =  (buf[20] << 24) |       ((buf[21] & 0xff) << 16) |
-                      ((buf[22] & 0xff) << 8) | (buf[23] & 0xff);
-            float latitude = Float.intBitsToFloat(ilat);
-            float longitude = Float.intBitsToFloat(ilon);
-            float cx = Float.intBitsToFloat(icx);
-            float cy = Float.intBitsToFloat(icy);
-            float cz = Float.intBitsToFloat(icz);
-
-            City city = new City(name, tzid, rawOffset,
-                                 latitude, longitude, cx, cy, cz);
-
-            cities.put(name, city);
-            citiesByRawOffset[i] = city;
-        }
-    }
-    
-    /**
-     * Returns the cities, ordered by name.
-     */
-    public static City[] getCitiesByName() {
-        City[] ocities = new City[cities.size()];
-        Iterator<City> iter = cities.values().iterator();
-        int idx = 0;
-        while (iter.hasNext()) {
-            ocities[idx++] = iter.next();
-        }
-        Arrays.sort(ocities);
-        return ocities;
-    }
-    
-    /**
-     * Returns the cities, ordered by offset, accounting for summer/daylight
-     * savings time.  This requires reading the entire time zone database
-     * behind the scenes.
-     */
-    public static City[] getCitiesByOffset() {
-        City[] ocities = new City[cities.size()];
-        Iterator<City> iter = cities.values().iterator();
-        int idx = 0;
-        while (iter.hasNext()) {
-            ocities[idx++] = iter.next();
-        }
-        Arrays.sort(ocities, new Comparator() {
-                public int compare(Object o1, Object o2) {
-                    long now = System.currentTimeMillis();
-                    City c1 = (City)o1;
-                    City c2 = (City)o2;
-                    TimeZone tz1 = c1.getTimeZone();
-                    TimeZone tz2 = c2.getTimeZone();
-                    int off1 = tz1.getOffset(now);
-                    int off2 = tz2.getOffset(now);
-                    if (off1 == off2) {
-                        float dlat = c2.getLatitude() - c1.getLatitude();
-                        if (dlat < 0.0f) return -1;
-                        if (dlat > 0.0f) return 1;
-                        return 0;
-                    }
-                    return off1 - off2;
-                }
-            });
-        return ocities;
-    }
-    
-    
-    /**
-     * Returns the cities, ordered by offset, accounting for summer/daylight
-     * savings time.  This does not require reading the time zone database
-     * since the cities are pre-sorted.
-     */
-    public static City[] getCitiesByRawOffset() {
-        return citiesByRawOffset;
-    }
-    
-    /**
-     * Returns an Iterator over all cities, in raw offset order.
-     */
-    public static Iterator<City> iterator() {
-        return cities.values().iterator();
-    }
-    
-    /**
-     * Returns the total number of cities.
-     */
-    public static int numCities() {
-        return cities.size();
-    }
-    
-    /**
-     * Constructs a city with the given name, time zone name, raw offset,
-     * latitude, longitude, and 3D (X, Y, Z) coordinate.
-     */
-    public City(String name, String timeZoneID,
-                int rawOffset,
-                float latitude, float longitude,
-                float x, float y, float z) {
-        this.name = name;
-        this.timeZoneID = timeZoneID;
-        this.rawOffset = rawOffset;
-        this.latitude = latitude;
-        this.longitude = longitude;
-        this.x = x;
-        this.y = y;
-        this.z = z;
-    }
-    
-    public String getName() {
-        return name;
-    }
-    
-    public TimeZone getTimeZone() {
-        if (timeZone == null) {
-            timeZone = TimeZone.getTimeZone(timeZoneID);
-        }
-        return timeZone;
-    }
-    
-    public float getLongitude() {
-        return longitude;
-    }
-    
-    public float getLatitude() {
-        return latitude;
-    }
-    
-    public float getX() {
-        return x;
-    }
-    
-    public float getY() {
-        return y;
-    }
-    
-    public float getZ() {
-        return z;
-    }
-    
-    public float getRawOffset() {
-        return rawOffset / 3600000.0f;
-    }
-
-    public int getRawOffsetMillis() {
-        return rawOffset;
-    }
-    
-    /**
-     * Returns this city's offset from UTC, taking summer/daylight savigns
-     * time into account.
-     */
-    public float getOffset() {
-        long now = System.currentTimeMillis();
-        if (timeZone == null) {
-            timeZone = TimeZone.getTimeZone(timeZoneID);
-        }
-        return timeZone.getOffset(now) / 3600000.0f;
-    }
-    
-    /**
-     * Compares this city to another by name.
-     */
-    public int compareTo(City o) {
-        return name.compareTo(o.name);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/Clock.java b/samples/GlobalTime/src/com/android/globaltime/Clock.java
deleted file mode 100644
index 9aad71a..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/Clock.java
+++ /dev/null
@@ -1,332 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.util.Calendar;
-import java.util.Date;
-import java.util.TimeZone;
-
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Path;
-import android.graphics.RectF;
-import android.text.format.DateUtils;
-import android.view.animation.AccelerateDecelerateInterpolator;
-import android.view.animation.Interpolator;
-
-/**
- * A class that draws an analog clock face with information about the current
- * time in a given city.
- */
-public class Clock {
-
-    static final int MILLISECONDS_PER_MINUTE = 60 * 1000;
-    static final int MILLISECONDS_PER_HOUR = 60 * 60 * 1000;
-
-    private City mCity = null;
-    private long mCitySwitchTime;
-    private long mTime;
-
-    private float mColorRed = 1.0f;
-    private float mColorGreen = 1.0f;
-    private float mColorBlue = 1.0f;
-
-    private long mOldOffset;
-
-    private Interpolator mClockHandInterpolator =
-        new AccelerateDecelerateInterpolator();
-
-    public Clock() {
-        // Empty constructor
-    }
-
-    /**
-     * Adds a line to the given Path.  The line extends from
-     * radius r0 to radius r1 about the center point (cx, cy),
-     * at an angle given by pos.
-     * 
-     * @param path the Path to draw to
-     * @param radius the radius of the outer rim of the clock
-     * @param pos the angle, with 0 and 1 at 12:00
-     * @param cx the X coordinate of the clock center
-     * @param cy the Y coordinate of the clock center
-     * @param r0 the starting radius for the line
-     * @param r1 the ending radius for the line
-     */
-    private static void drawLine(Path path,
-        float radius, float pos, float cx, float cy, float r0, float r1) {
-        float theta = pos * Shape.TWO_PI - Shape.PI_OVER_TWO;
-        float dx = (float) Math.cos(theta);
-        float dy = (float) Math.sin(theta);
-        float p0x = cx + dx * r0;
-        float p0y = cy + dy * r0;
-        float p1x = cx + dx * r1;
-        float p1y = cy + dy * r1;
-
-        float ox =  (p1y - p0y);
-        float oy = -(p1x - p0x);
-
-        float norm = (radius / 2.0f) / (float) Math.sqrt(ox * ox + oy * oy);
-        ox *= norm;
-        oy *= norm;
-
-        path.moveTo(p0x - ox, p0y - oy);
-        path.lineTo(p1x - ox, p1y - oy);
-        path.lineTo(p1x + ox, p1y + oy);
-        path.lineTo(p0x + ox, p0y + oy);
-        path.close();
-    }
-
-    /**
-     * Adds a vertical arrow to the given Path.
-     * 
-     * @param path the Path to draw to
-     */
-    private static void drawVArrow(Path path,
-        float cx, float cy, float width, float height) {
-        path.moveTo(cx - width / 2.0f, cy);
-        path.lineTo(cx, cy + height);
-        path.lineTo(cx + width / 2.0f, cy);
-        path.close();
-    }
-
-    /**
-     * Adds a horizontal arrow to the given Path.
-     * 
-     * @param path the Path to draw to
-     */
-    private static void drawHArrow(Path path,
-        float cx, float cy, float width, float height) {
-        path.moveTo(cx, cy - height / 2.0f);
-        path.lineTo(cx + width, cy);
-        path.lineTo(cx, cy + height / 2.0f);
-        path.close();
-    }
-
-    /**
-     * Returns an offset in milliseconds to be subtracted from the current time
-     * in order to obtain an smooth interpolation between the previously
-     * displayed time and the current time.
-     */
-    private long getOffset(float lerp) {
-        long doffset = (long) (mCity.getOffset() *
-            (float) MILLISECONDS_PER_HOUR - mOldOffset);
-        int sign;
-        if (doffset < 0) {
-            doffset = -doffset;
-            sign = -1;
-        } else {
-            sign = 1;
-        }
-
-        while (doffset > 12L * MILLISECONDS_PER_HOUR) {
-            doffset -= 12L * MILLISECONDS_PER_HOUR;
-        }
-        if (doffset > 6L * MILLISECONDS_PER_HOUR) {
-            doffset = 12L * MILLISECONDS_PER_HOUR - doffset;
-            sign = -sign;
-        }
-
-        // Interpolate doffset towards 0
-        doffset = (long)((1.0f - lerp)*doffset);
-
-        // Keep the same seconds count
-        long dh = doffset / (MILLISECONDS_PER_HOUR);
-        doffset -= dh * MILLISECONDS_PER_HOUR;
-        long dm = doffset / MILLISECONDS_PER_MINUTE;
-        doffset = sign * (60 * dh + dm) * MILLISECONDS_PER_MINUTE;
-    
-        return doffset;
-    }
-
-    /**
-     * Set the city to be displayed.  setCity(null) resets things so the clock
-     * hand animation won't occur next time.
-     */
-    public void setCity(City city) {
-        if (mCity != city) {
-            if (mCity != null) {
-                mOldOffset =
-                    (long) (mCity.getOffset() * (float) MILLISECONDS_PER_HOUR);
-            } else if (city != null) {
-                mOldOffset =
-                    (long) (city.getOffset() * (float) MILLISECONDS_PER_HOUR);
-            } else {
-                mOldOffset = 0L; // this will never be used
-            }
-            this.mCitySwitchTime = System.currentTimeMillis();
-            this.mCity = city;
-        }
-    }
-
-    public void setTime(long time) {
-        this.mTime = time;
-    }
-
-    /**
-     * Draws the clock face.
-     * 
-     * @param canvas the Canvas to draw to
-     * @param cx the X coordinate of the clock center
-     * @param cy the Y coordinate of the clock center
-     * @param radius the radius of the clock face
-     * @param alpha the translucency of the clock face
-     * @param textAlpha the translucency of the text
-     * @param showCityName if true, display the city name
-     * @param showTime if true, display the time digitally
-     * @param showUpArrow if true, display an up arrow
-     * @param showDownArrow if true, display a down arrow
-     * @param showLeftRightArrows if true, display left and right arrows
-     * @param prefixChars number of characters of the city name to draw in bold
-     */
-    public void drawClock(Canvas canvas,
-        float cx, float cy, float radius, float alpha, float textAlpha,
-        boolean showCityName, boolean showTime,
-        boolean showUpArrow,  boolean showDownArrow, boolean showLeftRightArrows,
-        int prefixChars) {
-        Paint paint = new Paint();
-        paint.setAntiAlias(true);
-
-        int iradius = (int)radius;
-
-        TimeZone tz = mCity.getTimeZone();
-
-        // Compute an interpolated time to animate between the previously
-        // displayed time and the current time
-        float lerp = Math.min(1.0f,
-            (System.currentTimeMillis() - mCitySwitchTime) / 500.0f);
-        lerp = mClockHandInterpolator.getInterpolation(lerp);
-        long doffset = lerp < 1.0f ? getOffset(lerp) : 0L;
-    
-        // Determine the interpolated time for the given time zone
-        Calendar cal = Calendar.getInstance(tz);
-        cal.setTimeInMillis(mTime - doffset);
-        int hour = cal.get(Calendar.HOUR_OF_DAY);
-        int minute = cal.get(Calendar.MINUTE);
-        int second = cal.get(Calendar.SECOND);
-        int milli = cal.get(Calendar.MILLISECOND);
-
-        float offset = tz.getRawOffset() / (float) MILLISECONDS_PER_HOUR;
-        float daylightOffset = tz.inDaylightTime(new Date(mTime)) ?
-            tz.getDSTSavings() / (float) MILLISECONDS_PER_HOUR : 0.0f;
-
-        float absOffset = offset < 0 ? -offset : offset;
-        int offsetH = (int) absOffset;
-        int offsetM = (int) (60.0f * (absOffset - offsetH));
-        hour %= 12;
-
-        // Get the city name and digital time strings
-        String cityName = mCity.getName();
-        cal.setTimeInMillis(mTime);
-        String time = DateUtils.timeString(cal.getTimeInMillis()) + " "  +
-            DateUtils.getDayOfWeekString(cal.get(Calendar.DAY_OF_WEEK),
-                    DateUtils.LENGTH_SHORT) + " " +
-            " (UTC" +
-            (offset >= 0 ? "+" : "-") +
-            offsetH +
-            (offsetM == 0 ? "" : ":" + offsetM) +
-            (daylightOffset == 0 ? "" : "+" + daylightOffset) +
-            ")";
-
-        float th = paint.getTextSize();
-        float tw;
-
-        // Set the text color
-        paint.setARGB((int) (textAlpha * 255.0f),
-                      (int) (mColorRed * 255.0f),
-                      (int) (mColorGreen * 255.0f),
-                      (int) (mColorBlue * 255.0f));
-
-        tw = paint.measureText(cityName);
-        if (showCityName) {
-            // Increment prefixChars to include any spaces
-            for (int i = 0; i < prefixChars; i++) {
-                if (cityName.charAt(i) == ' ') {
-                    ++prefixChars;
-                }
-            }
-
-            // Draw the city name
-            canvas.drawText(cityName, cx - tw / 2, cy - radius - th, paint);
-            // Overstrike the first 'prefixChars' characters
-            canvas.drawText(cityName.substring(0, prefixChars),
-                            cx - tw / 2 + 1, cy - radius - th, paint);
-        }
-        tw = paint.measureText(time);
-        if (showTime) {
-            canvas.drawText(time, cx - tw / 2, cy + radius + th + 5, paint);
-        }
-
-        paint.setARGB((int)(alpha * 255.0f),
-                      (int)(mColorRed * 255.0f),
-                      (int)(mColorGreen * 255.0f),
-                      (int)(mColorBlue * 255.0f));
-
-        paint.setStyle(Paint.Style.FILL);
-        canvas.drawOval(new RectF(cx - 2, cy - 2, cx + 2, cy + 2), paint);
-
-        paint.setStyle(Paint.Style.STROKE);
-        paint.setStrokeWidth(radius * 0.12f);
-
-        canvas.drawOval(new RectF(cx - iradius, cy - iradius,
-                                  cx + iradius, cy + iradius),
-                        paint);
-
-        float r0 = radius * 0.1f;
-        float r1 = radius * 0.4f;
-        float r2 = radius * 0.6f;
-        float r3 = radius * 0.65f;
-        float r4 = radius * 0.7f;
-        float r5 = radius * 0.9f;
-
-        Path path = new Path();
-
-        float ss = second + milli / 1000.0f;
-        float mm = minute + ss / 60.0f;
-        float hh = hour + mm / 60.0f;
-
-        // Tics for the hours
-        for (int i = 0; i < 12; i++) {
-            drawLine(path, radius * 0.12f, i / 12.0f, cx, cy, r4, r5);
-        }
-
-        // Hour hand
-        drawLine(path, radius * 0.12f, hh / 12.0f, cx, cy, r0, r1); 
-        // Minute hand
-        drawLine(path, radius * 0.12f, mm / 60.0f, cx, cy, r0, r2); 
-        // Second hand
-        drawLine(path, radius * 0.036f, ss / 60.0f, cx, cy, r0, r3); 
-
-        if (showUpArrow) {
-            drawVArrow(path, cx + radius * 1.13f, cy - radius,
-                radius * 0.15f, -radius * 0.1f);
-        }
-        if (showDownArrow) {
-            drawVArrow(path, cx + radius * 1.13f, cy + radius,
-                radius * 0.15f, radius * 0.1f);
-        }
-        if (showLeftRightArrows) {
-            drawHArrow(path, cx - radius * 1.3f, cy, -radius * 0.1f,
-                radius * 0.15f);
-            drawHArrow(path, cx + radius * 1.3f, cy,  radius * 0.1f,
-                radius * 0.15f);
-        }
-
-        paint.setStyle(Paint.Style.FILL);
-        canvas.drawPath(path, paint);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/GLView.java b/samples/GlobalTime/src/com/android/globaltime/GLView.java
deleted file mode 100644
index 4253717..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/GLView.java
+++ /dev/null
@@ -1,927 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.HashMap;
-import javax.microedition.khronos.opengles.GL10;
-
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.view.KeyEvent;
-
-class Message {
-
-    private String mText;
-    private long mExpirationTime;
-
-    public Message(String text, long expirationTime) {
-        this.mText = text;
-        this.mExpirationTime = expirationTime;
-    }
-
-    public String getText() {
-        return mText;
-    }
-
-    public long getExpirationTime() {
-        return mExpirationTime;
-    }
-}
-
-/**
- * A helper class to simplify writing an Activity that renders using
- * OpenGL ES.
- *
- * <p> A GLView object stores common elements of GL state and allows
- * them to be modified interactively.  This is particularly useful for
- * determining the proper settings of parameters such as the view
- * frustum and light intensities during application development.
- *
- * <p> A GLView is not an actual View; instead, it is meant to be
- * called from within a View to perform event processing on behalf of the
- * actual View.
- *
- * <p> By passing key events to the GLView object from the View,
- * the application can automatically allow certain parameters to
- * be user-controlled from the keyboard.  Key events may be passed as
- * shown below:
- *
- * <pre>
- * GLView mGlView = new GLView();
- *
- * public boolean onKeyDown(int keyCode, KeyEvent event) {
- *     // Hand the key to the GLView object first
- *     if (mGlView.processKey(keyCode)) {
- *         return;
- *     }
- *  
- *     switch (keyCode) {
- *     case KeyEvent.KEY_CODE_X:
- *         // perform app processing
- *         break;
- *     
- *     default:
- *         super.onKeyDown(keyCode, event);
- *         break;
- *     }
- * }
- * </pre>
- *
- * <p> During drawing of a frame, the GLView object should be given the
- * opportunity to manage GL parameters as shown below:
- * 
- * OpenGLContext mGLContext; // initialization not shown
- * int mNumTrianglesDrawn = 0;
- * 
- * protected void onDraw(Canvas canvas) {
- *     int w = getWidth();
- *     int h = getHeight();
- *         
- *     float ratio = (float) w / h;
- *     mGLView.setAspectRatio(ratio);
- *
- *     GL10 gl = (GL10) mGLContext.getGL();
- *     mGLContext.waitNative(canvas, this);
- *     
- *     // Enable a light for the GLView to manipulate
- *     gl.glEnable(GL10.GL_LIGHTING);
- *     gl.glEnable(GL10.GL_LIGHT0);
- *         
- *     // Allow the GLView to set GL parameters
- *     mGLView.setTextureParameters(gl);
- *     mGLView.setProjection(gl);
- *     mGLView.setView(gl);
- *     mGLView.setLights(gl, GL10.GL_LIGHT0);
- *         
- *     // Draw some stuff (not shown)
- *     mNumTrianglesDrawn += <num triangles just drawn>;
- *     
- *     // Wait for GL drawing to complete
- *     mGLContext.waitGL();
- *     
- *     // Inform the GLView of what was drawn, and ask it to display statistics
- *     mGLView.setNumTriangles(mNumTrianglesDrawn);
- *     mGLView.showMessages(canvas);
- *     mGLView.showStatistics(canvas, w);
- * }      
- * </pre>
- *
- * <p> At the end of each frame, following the call to
- * GLContext.waitGL, the showStatistics and showMessages methods
- * will cause additional information to be displayed.
- *
- * <p> To enter the interactive command mode, the 'tab' key must be
- * pressed twice in succession.  A subsequent press of the 'tab' key
- * exits the interactive command mode.  Entering a multi-letter code
- * sets the parameter to be modified. The 'newline' key erases the
- * current code, and the 'del' key deletes the last letter of
- * the code. The parameter value may be modified by pressing the
- * keypad left or up to decrement the value and right or down to
- * increment the value.  The current value will be displayed as an
- * overlay above the GL rendered content.
- * 
- * <p> The supported keyboard commands are as follows:
- *
- * <ul>
- * <li>     h - display a list of commands
- * <li>    fn - near frustum 
- * <li>    ff - far frustum 
- * <li>    tx - translate x
- * <li>    ty - translate y
- * <li>    tz - translate z
- * <li>     z - zoom (frustum size)
- * <li>    la - ambient light (all RGB channels)
- * <li>   lar - ambient light red channel
- * <li>   lag - ambient light green channel
- * <li>   lab - ambient light blue channel
- * <li>    ld - diffuse light (all RGB channels)
- * <li>   ldr - diffuse light red channel
- * <li>   ldg - diffuse light green channel
- * <li>   ldb - diffuse light blue channel
- * <li>    ls - specular light (all RGB channels)
- * <li>   lsr - specular light red channel
- * <li>   lsg - specular light green channel
- * <li>   lsb - specular light blue channel
- * <li>   lma - light model ambient (all RGB channels)
- * <li>  lmar - light model ambient light red channel
- * <li>  lmag - light model ambient green channel
- * <li>  lmab - light model ambient blue channel
- * <li>  tmin - texture min filter
- * <li>  tmag - texture mag filter
- * <li>  tper - texture perspective correction
- * </ul>
- * 
- * {@hide}
- */
-public class GLView {
-
-    private static final int DEFAULT_DURATION_MILLIS = 1000;
-    private static final int STATE_KEY = KeyEvent.KEYCODE_TAB;
-    private static final int HAVE_NONE = 0;
-    private static final int HAVE_ONE = 1;
-    private static final int HAVE_TWO = 2;
-
-    private static final float MESSAGE_Y_SPACING = 12.0f;
-
-    private int mState = HAVE_NONE;
-
-    private static final int NEAR_FRUSTUM  = 0;
-    private static final int FAR_FRUSTUM   = 1;
-    private static final int TRANSLATE_X   = 2;
-    private static final int TRANSLATE_Y   = 3;
-    private static final int TRANSLATE_Z   = 4;
-    private static final int ZOOM_EXPONENT = 5;
-
-    private static final int AMBIENT_INTENSITY = 6;
-    private static final int AMBIENT_RED = 7;
-    private static final int AMBIENT_GREEN = 8;
-    private static final int AMBIENT_BLUE = 9;
-
-    private static final int DIFFUSE_INTENSITY = 10;
-    private static final int DIFFUSE_RED = 11;
-    private static final int DIFFUSE_GREEN = 12;
-    private static final int DIFFUSE_BLUE = 13;
-
-    private static final int SPECULAR_INTENSITY = 14;
-    private static final int SPECULAR_RED = 15;
-    private static final int SPECULAR_GREEN = 16;
-    private static final int SPECULAR_BLUE = 17;
-
-    private static final int LIGHT_MODEL_AMBIENT_INTENSITY = 18;
-    private static final int LIGHT_MODEL_AMBIENT_RED = 19;
-    private static final int LIGHT_MODEL_AMBIENT_GREEN = 20;
-    private static final int LIGHT_MODEL_AMBIENT_BLUE = 21;
-
-    private static final int TEXTURE_MIN_FILTER = 22;
-    private static final int TEXTURE_MAG_FILTER = 23;
-    private static final int TEXTURE_PERSPECTIVE_CORRECTION = 24;
-
-    private static final String[] commands = { 
-        "fn",
-        "ff",
-        "tx",
-        "ty",
-        "tz",
-        "z",
-        "la", "lar", "lag", "lab",
-        "ld", "ldr", "ldg", "ldb",
-        "ls", "lsr", "lsg", "lsb",
-        "lma", "lmar", "lmag", "lmab",
-        "tmin", "tmag", "tper"
-   };
-
-    private static final String[] labels = {
-        "Near Frustum",
-        "Far Frustum",
-        "Translate X",
-        "Translate Y",
-        "Translate Z",
-        "Zoom",
-        "Ambient Intensity",
-        "Ambient Red",
-        "Ambient Green",
-        "Ambient Blue",
-        "Diffuse Intensity",
-        "Diffuse Red",
-        "Diffuse Green",
-        "Diffuse Blue",
-        "Specular Intenstity",
-        "Specular Red",
-        "Specular Green",
-        "Specular Blue",
-        "Light Model Ambient Intensity",
-        "Light Model Ambient Red",
-        "Light Model Ambient Green",
-        "Light Model Ambient Blue",
-        "Texture Min Filter",
-        "Texture Mag Filter",
-        "Texture Perspective Correction",
-    };
-
-    private static final float[] defaults = {
-        5.0f, 100.0f,
-        0.0f, 0.0f, -50.0f,
-        0,
-        0.125f,	1.0f, 1.0f, 1.0f,
-        0.125f,	1.0f, 1.0f, 1.0f,
-        0.125f,	1.0f, 1.0f, 1.0f,
-        0.125f,	1.0f, 1.0f, 1.0f,
-        GL10.GL_NEAREST, GL10.GL_NEAREST,
-        GL10.GL_FASTEST
-    };
-
-    private static final float[] increments = {
-        0.01f, 0.5f,
-        0.125f, 0.125f, 0.125f,
-        1.0f,
-        0.03125f, 0.1f, 0.1f, 0.1f,
-        0.03125f, 0.1f, 0.1f, 0.1f,
-        0.03125f, 0.1f, 0.1f, 0.1f,
-        0.03125f, 0.1f, 0.1f, 0.1f,
-        0, 0, 0
-    };
-
-    private float[] params = new float[commands.length];
-
-    private static final float mZoomScale = 0.109f;
-    private static final float mZoomBase  = 1.01f;
-
-    private int             mParam = -1;
-    private float           mIncr = 0;
-
-    private Paint           mPaint = new Paint();
-
-    private float           mAspectRatio = 1.0f;
-
-    private float           mZoom;
-
-    // private boolean         mPerspectiveCorrection = false;
-    // private int             mTextureMinFilter = GL10.GL_NEAREST;
-    // private int             mTextureMagFilter = GL10.GL_NEAREST;
-
-    // Counters for FPS calculation
-    private boolean         mDisplayFPS = false;
-    private boolean         mDisplayCounts = false;
-    private int             mFramesFPS = 10;
-    private long[]          mTimes = new long[mFramesFPS];
-    private int             mTimesIdx = 0;
-
-    private Map<String,Message> mMessages = new HashMap<String,Message>();
-
-    /**
-     * Constructs a new GLView.
-     */
-    public GLView() {
-        mPaint.setColor(0xffffffff);
-        reset();
-    }
-
-    /**
-     * Sets the aspect ratio (width/height) of the screen.
-     *
-     * @param aspectRatio the screen width divided by the screen height
-     */
-    public void setAspectRatio(float aspectRatio) {
-        this.mAspectRatio = aspectRatio;
-    }
-    
-    /**
-     * Sets the overall ambient light intensity.  This intensity will
-     * be used to modify the ambient light value for each of the red,
-     * green, and blue channels passed to glLightfv(...GL_AMBIENT...).
-     * The default value is 0.125f.
-     *
-     * @param intensity a floating-point value controlling the overall
-     * ambient light intensity.
-     */
-    public void setAmbientIntensity(float intensity) {
-        params[AMBIENT_INTENSITY] = intensity;
-    }
-
-    /**
-     * Sets the light model ambient intensity.  This intensity will be
-     * used to modify the ambient light value for each of the red,
-     * green, and blue channels passed to
-     * glLightModelfv(GL_LIGHT_MODEL_AMBIENT...).  The default value
-     * is 0.125f.
-     *
-     * @param intensity a floating-point value controlling the overall
-     * light model ambient intensity.
-     */
-    public void setLightModelAmbientIntensity(float intensity) {
-        params[LIGHT_MODEL_AMBIENT_INTENSITY] = intensity;
-    }
-
-    /**
-     * Sets the ambient color for the red, green, and blue channels
-     * that will be multiplied by the value of setAmbientIntensity and
-     * passed to glLightfv(...GL_AMBIENT...).  The default values are
-     * {1, 1, 1}.
-     *
-     * @param ambient an arry of three floats containing ambient
-     * red, green, and blue intensity values.
-     */
-    public void setAmbientColor(float[] ambient) {
-        params[AMBIENT_RED]   = ambient[0];
-        params[AMBIENT_GREEN] = ambient[1];
-        params[AMBIENT_BLUE]  = ambient[2];
-    }
-
-    /**
-     * Sets the overall diffuse light intensity.  This intensity will
-     * be used to modify the diffuse light value for each of the red,
-     * green, and blue channels passed to glLightfv(...GL_DIFFUSE...).
-     * The default value is 0.125f.
-     *
-     * @param intensity a floating-point value controlling the overall
-     * ambient light intensity.
-     */
-    public void setDiffuseIntensity(float intensity) {
-        params[DIFFUSE_INTENSITY] = intensity;
-    }
-
-    /**
-     * Sets the diffuse color for the red, green, and blue channels
-     * that will be multiplied by the value of setDiffuseIntensity and
-     * passed to glLightfv(...GL_DIFFUSE...).  The default values are
-     * {1, 1, 1}.
-     *
-     * @param diffuse an array of three floats containing diffuse
-     * red, green, and blue intensity values.
-     */
-    public void setDiffuseColor(float[] diffuse) {
-        params[DIFFUSE_RED]   = diffuse[0];
-        params[DIFFUSE_GREEN] = diffuse[1];
-        params[DIFFUSE_BLUE]  = diffuse[2];
-    }
-
-    /**
-     * Sets the overall specular light intensity.  This intensity will
-     * be used to modify the diffuse light value for each of the red,
-     * green, and blue channels passed to glLightfv(...GL_SPECULAR...).
-     * The default value is 0.125f.
-     *
-     * @param intensity a floating-point value controlling the overall
-     * ambient light intensity.
-     */
-    public void setSpecularIntensity(float intensity) {
-        params[SPECULAR_INTENSITY] = intensity;
-    }
-
-    /**
-     * Sets the specular color for the red, green, and blue channels
-     * that will be multiplied by the value of setSpecularIntensity and
-     * passed to glLightfv(...GL_SPECULAR...).  The default values are
-     * {1, 1, 1}.
-     *
-     * @param specular an array of three floats containing specular
-     * red, green, and blue intensity values.
-     */
-    public void setSpecularColor(float[] specular) {
-        params[SPECULAR_RED]   = specular[0];
-        params[SPECULAR_GREEN] = specular[1];
-        params[SPECULAR_BLUE]  = specular[2];
-    }
-
-    /**
-     * Returns the current X translation of the modelview
-     * transformation as passed to glTranslatef.  The default value is
-     * 0.0f.
-     *
-     * @return the X modelview translation as a float.
-     */
-    public float getTranslateX() {
-        return params[TRANSLATE_X];
-    }
-
-    /**
-     * Returns the current Y translation of the modelview
-     * transformation as passed to glTranslatef.  The default value is
-     * 0.0f.
-     *
-     * @return the Y modelview translation as a float.
-     */
-    public float getTranslateY() {
-        return params[TRANSLATE_Y];
-    }
-
-    /**
-     * Returns the current Z translation of the modelview
-     * transformation as passed to glTranslatef.  The default value is
-     * -50.0f.
-     *
-     * @return the Z modelview translation as a float.
-     */
-    public float getTranslateZ() {
-        return params[TRANSLATE_Z];
-    }
-
-    /**
-     * Sets the position of the near frustum clipping plane as passed
-     * to glFrustumf.  The default value is 5.0f;
-     *
-     * @param nearFrustum the near frustum clipping plane distance as
-     * a float.
-     */
-    public void setNearFrustum(float nearFrustum) {
-        params[NEAR_FRUSTUM] = nearFrustum;
-    }
-
-    /**
-     * Sets the position of the far frustum clipping plane as passed
-     * to glFrustumf.  The default value is 100.0f;
-     *
-     * @param farFrustum the far frustum clipping plane distance as a
-     * float.
-     */
-    public void setFarFrustum(float farFrustum) {
-        params[FAR_FRUSTUM] = farFrustum;
-    }
-
-    private void computeZoom() {
-        mZoom = mZoomScale*(float)Math.pow(mZoomBase, -params[ZOOM_EXPONENT]);
-    }
-
-    /**
-     * Resets all parameters to their default values.
-     */
-    public void reset() {
-        for (int i = 0; i < params.length; i++) {
-            params[i] = defaults[i];
-        }
-        computeZoom();
-    }
-
-    private void removeExpiredMessages() {
-        long now = System.currentTimeMillis();
-
-        List<String> toBeRemoved = new ArrayList<String>();
-
-        Iterator<String> keyIter = mMessages.keySet().iterator();
-        while (keyIter.hasNext()) {
-            String key = keyIter.next();
-            Message msg = mMessages.get(key);
-            if (msg.getExpirationTime() < now) {
-                toBeRemoved.add(key);
-            }
-        }
-
-        Iterator<String> tbrIter = toBeRemoved.iterator();
-        while (tbrIter.hasNext()) {
-            String key = tbrIter.next();
-            mMessages.remove(key);
-        }
-    }
-    
-    /**
-     * Displays the message overlay on the given Canvas.  The
-     * GLContext.waitGL method should be called prior to calling this
-     * method.  The interactive command display is drawn by this
-     * method.
-     *
-     * @param canvas the Canvas on which messages are to appear.
-     */
-    public void showMessages(Canvas canvas) {
-        removeExpiredMessages();
-
-        float y = 10.0f;
-
-        List<String> l = new ArrayList<String>();
-        l.addAll(mMessages.keySet());
-        Collections.sort(l);
-
-        Iterator<String> iter = l.iterator();
-        while (iter.hasNext()) {
-            String key = iter.next();
-            String text = mMessages.get(key).getText();
-            canvas.drawText(text, 10.0f, y, mPaint);
-            y += MESSAGE_Y_SPACING;
-        }
-    }
-
-    private int mTriangles;
-
-    /**
-     * Sets the number of triangles drawn in the previous frame for
-     * display by the showStatistics method.  The number of triangles
-     * is not computed by GLView but must be supplied by the
-     * calling Activity.
-     *
-     * @param triangles an Activity-supplied estimate of the number of 
-     * triangles drawn in the previous frame.
-     */
-    public void setNumTriangles(int triangles) {
-        this.mTriangles = triangles;
-    }
-
-    /**
-     * Displays statistics on frames and triangles per second. The
-     * GLContext.waitGL method should be called prior to calling this
-     * method.
-     *
-     * @param canvas the Canvas on which statistics are to appear.
-     * @param width the width of the Canvas.
-     */
-    public void showStatistics(Canvas canvas, int width) {	
-        long endTime = mTimes[mTimesIdx] = System.currentTimeMillis();
-        mTimesIdx = (mTimesIdx + 1) % mFramesFPS;
-
-        float th = mPaint.getTextSize();
-
-        if (mDisplayFPS) {
-            // Use end time from mFramesFPS frames ago
-            long startTime = mTimes[mTimesIdx];
-            String fps = "" + (1000.0f*mFramesFPS/(endTime - startTime));
-
-            // Normalize fps to XX.XX format
-            if (fps.indexOf(".") == 1) {
-                fps = " " + fps;
-            }
-            int len = fps.length();
-            if (len == 2) {
-                fps += ".00";
-            } else if (len == 4) {
-                fps += "0";
-            } else if (len > 5) {
-                fps = fps.substring(0, 5);
-            }
-
-            canvas.drawText(fps + " fps", width - 60.0f, 10.0f, mPaint);
-        }
-
-        if (mDisplayCounts) {
-            canvas.drawText(mTriangles + " triangles",
-                            width - 100.0f, 10.0f + th + 5, mPaint);
-        }
-    }
-
-    private void addMessage(String key, String text, int durationMillis) {
-        long expirationTime = System.currentTimeMillis() + durationMillis;
-
-        mMessages.put(key, new Message(text, expirationTime));
-    }
-
-    private void addMessage(String key, String text) {
-        addMessage(key, text, DEFAULT_DURATION_MILLIS);
-    }
-
-    private void addMessage(String text) {
-        addMessage(text, text, DEFAULT_DURATION_MILLIS);
-    }
-
-    private void clearMessages() {
-        mMessages.clear();
-    }
-
-    String command = "";
-
-    private void toggleFilter() {
-        if (params[mParam] == GL10.GL_NEAREST) {
-            params[mParam] = GL10.GL_LINEAR;
-        } else {
-            params[mParam] = GL10.GL_NEAREST;
-        }
-        addMessage(commands[mParam],
-                   "Texture " + 
-                   (mParam == TEXTURE_MIN_FILTER ? "min" : "mag") +
-                   " filter = " +
-                   (params[mParam] == GL10.GL_NEAREST ?
-                    "nearest" : "linear"));
-    }
-
-    private void togglePerspectiveCorrection() {
-        if (params[mParam] == GL10.GL_NICEST) {
-            params[mParam] = GL10.GL_FASTEST;
-        } else {
-            params[mParam] = GL10.GL_NICEST;
-        }
-        addMessage(commands[mParam],
-                   "Texture perspective correction = " +
-                   (params[mParam] == GL10.GL_FASTEST ?
-                    "fastest" : "nicest"));
-    }
-
-    private String valueString() {
-        if (mParam == TEXTURE_MIN_FILTER ||
-            mParam == TEXTURE_MAG_FILTER) {
-            if (params[mParam] == GL10.GL_NEAREST) {
-                return "nearest";
-            }
-            if (params[mParam] == GL10.GL_LINEAR) {
-                return "linear";
-            }
-        }
-        if (mParam == TEXTURE_PERSPECTIVE_CORRECTION) {
-            if (params[mParam] == GL10.GL_FASTEST) {
-                return "fastest";
-            }
-            if (params[mParam] == GL10.GL_NICEST) {
-                return "nicest";
-            }
-        }
-        return "" + params[mParam];
-    }
-
-    /**
-     * 
-     * @return true if the view 
-     */
-    public boolean hasMessages() {
-        return mState == HAVE_TWO || mDisplayFPS || mDisplayCounts;
-    }
-    
-    /**
-     * Process a key stroke.  The calling Activity should pass all
-     * keys from its onKeyDown method to this method.  If the key is
-     * part of a GLView command, true is returned and the calling
-     * Activity should ignore the key event.  Otherwise, false is
-     * returned and the calling Activity may process the key event
-     * normally.
-     *
-     * @param keyCode the key code as passed to Activity.onKeyDown.
-     *
-     * @return true if the key is part of a GLView command sequence,
-     * false otherwise.
-     */
-    public boolean processKey(int keyCode) {
-        // Pressing the state key twice enters the UI
-        // Pressing it again exits the UI
-        if ((keyCode == STATE_KEY) || 
-            (keyCode == KeyEvent.KEYCODE_SLASH) || 
-            (keyCode == KeyEvent.KEYCODE_PERIOD))
-        {
-            mState = (mState + 1) % 3;
-            if (mState == HAVE_NONE) {
-                clearMessages();
-            }
-            if (mState == HAVE_TWO) {
-                clearMessages();
-                addMessage("aaaa", "GL", Integer.MAX_VALUE);
-                addMessage("aaab", "", Integer.MAX_VALUE);
-                command = "";
-            }
-            return true;
-        } else {
-            if (mState == HAVE_ONE) {
-                mState = HAVE_NONE;
-                return false;
-            }
-        }
-
-        // If we're not in the UI, exit without handling the key
-        if (mState != HAVE_TWO) {
-            return false;
-        }
-
-        if (keyCode == KeyEvent.KEYCODE_ENTER) {
-            command = "";
-        } else if (keyCode == KeyEvent.KEYCODE_DEL) {
-            if (command.length() > 0) {
-                command = command.substring(0, command.length() - 1);
-            }
-
-        } else if (keyCode >= KeyEvent.KEYCODE_A &&
-                   keyCode <= KeyEvent.KEYCODE_Z) {
-            command += "" + (char)(keyCode - KeyEvent.KEYCODE_A + 'a');
-        }
-
-        addMessage("aaaa", "GL " + command, Integer.MAX_VALUE);
-
-        if (command.equals("h")) {
-            addMessage("aaaa", "GL", Integer.MAX_VALUE);
-            addMessage("h - help");
-            addMessage("fn/ff - frustum near/far clip Z");
-            addMessage("la/lar/lag/lab - abmient intensity/r/g/b");
-            addMessage("ld/ldr/ldg/ldb - diffuse intensity/r/g/b");
-            addMessage("ls/lsr/lsg/lsb - specular intensity/r/g/b");
-            addMessage("s - toggle statistics display");
-            addMessage("tmin/tmag - texture min/mag filter");
-            addMessage("tpersp - texture perspective correction");
-            addMessage("tx/ty/tz - view translate x/y/z");
-            addMessage("z - zoom");
-            command = "";
-            return true;
-        } else if (command.equals("s")) {
-            mDisplayCounts = !mDisplayCounts;
-            mDisplayFPS = !mDisplayFPS;
-            command = "";
-            return true;
-        }
-
-        mParam = -1;
-        for (int i = 0; i < commands.length; i++) {
-            if (command.equals(commands[i])) {
-                mParam = i;
-                mIncr = increments[i];
-            }
-        }
-        if (mParam == -1) {
-            return true;
-        }
-
-        boolean addMessage = true;
-
-        // Increment or decrement
-        if (keyCode == KeyEvent.KEYCODE_DPAD_RIGHT ||
-            keyCode == KeyEvent.KEYCODE_DPAD_DOWN) {
-            if (mParam == ZOOM_EXPONENT) {
-                params[mParam] += mIncr;
-                computeZoom();
-            } else if ((mParam == TEXTURE_MIN_FILTER) ||
-                       (mParam == TEXTURE_MAG_FILTER)) {
-                toggleFilter();
-            } else if (mParam == TEXTURE_PERSPECTIVE_CORRECTION) {
-                togglePerspectiveCorrection();
-            } else {
-                params[mParam] += mIncr;
-            }
-        } else if (keyCode == KeyEvent.KEYCODE_DPAD_UP ||
-                   keyCode == KeyEvent.KEYCODE_DPAD_LEFT) {
-            if (mParam == ZOOM_EXPONENT) {
-                params[mParam] -= mIncr;
-                computeZoom();
-            } else if ((mParam == TEXTURE_MIN_FILTER) ||
-                       (mParam == TEXTURE_MAG_FILTER)) {
-                toggleFilter();
-            } else if (mParam == TEXTURE_PERSPECTIVE_CORRECTION) {
-                togglePerspectiveCorrection();
-            } else {
-                params[mParam] -= mIncr;
-            }
-        }
-	
-        if (addMessage) {
-            addMessage(commands[mParam],
-                       labels[mParam] + ": " + valueString());
-        }
-
-        return true;
-    }
-
-    /**
-     * Zoom in by a given number of steps.  A negative value of steps
-     * zooms out.  Each step zooms in by 1%.
-     *
-     * @param steps the number of steps to zoom by.
-     */
-    public void zoom(int steps) {
-        params[ZOOM_EXPONENT] += steps;
-        computeZoom();
-    }
-		
-    /**
-     * Set the projection matrix using glFrustumf.  The left and right
-     * clipping planes are set at -+(aspectRatio*zoom), the bottom and
-     * top clipping planes are set at -+zoom, and the near and far
-     * clipping planes are set to the values set by setNearFrustum and
-     * setFarFrustum or interactively.
-     *
-     * <p> GL side effects:
-     * <ul>
-     *    <li>overwrites the matrix mode</li>
-     *    <li>overwrites the projection matrix</li>
-     * </ul>
-     *
-     * @param gl a GL10 instance whose projection matrix is to be modified.
-     */
-    public void setProjection(GL10 gl) {
-        gl.glMatrixMode(GL10.GL_PROJECTION);
-        gl.glLoadIdentity();
-
-        if (mAspectRatio >= 1.0f) {
-            gl.glFrustumf(-mAspectRatio*mZoom, mAspectRatio*mZoom,
-                          -mZoom, mZoom,
-                          params[NEAR_FRUSTUM], params[FAR_FRUSTUM]);
-        } else {
-            gl.glFrustumf(-mZoom, mZoom,
-                          -mZoom / mAspectRatio, mZoom / mAspectRatio,
-                          params[NEAR_FRUSTUM], params[FAR_FRUSTUM]);
-        }
-    }
-
-    /**
-     * Set the modelview matrix using glLoadIdentity and glTranslatef.
-     * The translation values are set interactively.
-     *
-     * <p> GL side effects:
-     * <ul>
-     * <li>overwrites the matrix mode</li>
-     * <li>overwrites the modelview matrix</li>
-     * </ul>
-     *
-     * @param gl a GL10 instance whose modelview matrix is to be modified.
-     */
-    public void setView(GL10 gl) {
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-
-        // Move the viewpoint backwards
-        gl.glTranslatef(params[TRANSLATE_X],
-                        params[TRANSLATE_Y],
-                        params[TRANSLATE_Z]);
-    }
-
-    /**
-     * Sets texture parameters.
-     *
-     * <p> GL side effects:
-     * <ul>
-     * <li>sets the GL_PERSPECTIVE_CORRECTION_HINT</li>
-     * <li>sets the GL_TEXTURE_MIN_FILTER texture parameter</li>
-     * <li>sets the GL_TEXTURE_MAX_FILTER texture parameter</li>
-     * </ul>
-     *
-     * @param gl a GL10 instance whose texture parameters are to be modified.
-     */
-    public void setTextureParameters(GL10 gl) {
-        gl.glHint(GL10.GL_PERSPECTIVE_CORRECTION_HINT,
-                  (int)params[TEXTURE_PERSPECTIVE_CORRECTION]);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D,
-                           GL10.GL_TEXTURE_MIN_FILTER,
-                           params[TEXTURE_MIN_FILTER]);
-        gl.glTexParameterf(GL10.GL_TEXTURE_2D,
-                           GL10.GL_TEXTURE_MAG_FILTER,
-                           params[TEXTURE_MAG_FILTER]);
-    }
-
-    /**
-     * Sets the lighting parameters for the given light.
-     *
-     * <p> GL side effects:
-     * <ul>
-     * <li>sets the GL_LIGHT_MODEL_AMBIENT intensities
-     * <li>sets the GL_AMBIENT intensities for the given light</li>
-     * <li>sets the GL_DIFFUSE intensities for the given light</li>
-     * <li>sets the GL_SPECULAR intensities for the given light</li>
-     * </ul>
-     *
-     * @param gl a GL10 instance whose texture parameters are to be modified.
-     */
-    public void setLights(GL10 gl, int lightNum) {
-        float[] light = new float[4];
-        light[3] = 1.0f;
-
-        float lmi = params[LIGHT_MODEL_AMBIENT_INTENSITY];
-        light[0] = params[LIGHT_MODEL_AMBIENT_RED]*lmi;
-        light[1] = params[LIGHT_MODEL_AMBIENT_GREEN]*lmi;
-        light[2] = params[LIGHT_MODEL_AMBIENT_BLUE]*lmi;
-        gl.glLightModelfv(GL10.GL_LIGHT_MODEL_AMBIENT, light, 0);
-	
-        float ai = params[AMBIENT_INTENSITY];
-        light[0] = params[AMBIENT_RED]*ai;
-        light[1] = params[AMBIENT_GREEN]*ai;
-        light[2] = params[AMBIENT_BLUE]*ai;
-        gl.glLightfv(lightNum, GL10.GL_AMBIENT, light, 0);
-
-        float di = params[DIFFUSE_INTENSITY];
-        light[0] = params[DIFFUSE_RED]*di;
-        light[1] = params[DIFFUSE_GREEN]*di;
-        light[2] = params[DIFFUSE_BLUE]*di;
-        gl.glLightfv(lightNum, GL10.GL_DIFFUSE, light, 0);
-
-        float si = params[SPECULAR_INTENSITY];
-        light[0] = params[SPECULAR_RED]*si;
-        light[1] = params[SPECULAR_GREEN]*si;
-        light[2] = params[SPECULAR_BLUE]*si;
-        gl.glLightfv(lightNum, GL10.GL_SPECULAR, light, 0);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/GlobalTime.java b/samples/GlobalTime/src/com/android/globaltime/GlobalTime.java
deleted file mode 100644
index d96b644..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/GlobalTime.java
+++ /dev/null
@@ -1,1488 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.io.ByteArrayInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.List;
-import java.util.Locale;
-import java.util.TimeZone;
-
-import javax.microedition.khronos.egl.*;
-import javax.microedition.khronos.opengles.*;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.res.AssetManager;
-import android.graphics.Canvas;
-import android.opengl.Object3D;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Looper;
-import android.os.Message;
-import android.os.MessageQueue;
-import android.util.Log;
-import android.view.KeyEvent;
-import android.view.MotionEvent;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-import android.view.animation.AccelerateDecelerateInterpolator;
-import android.view.animation.DecelerateInterpolator;
-import android.view.animation.Interpolator;
-
-/**
- * The main View of the GlobalTime Activity.
- */
-class GTView extends SurfaceView implements SurfaceHolder.Callback {
-
-    /**
-     * A TimeZone object used to compute the current UTC time.
-     */
-    private static final TimeZone UTC_TIME_ZONE = TimeZone.getTimeZone("utc");
-
-    /**
-     * The Sun's color is close to that of a 5780K blackbody.
-     */
-    private static final float[] SUNLIGHT_COLOR = {
-        1.0f, 0.9375f, 0.91015625f, 1.0f
-    };
-
-    /**
-     * The inclination of the earth relative to the plane of the ecliptic
-     * is 23.45 degrees.
-     */
-    private static final float EARTH_INCLINATION = 23.45f * Shape.PI / 180.0f;
-
-    /** Seconds in a day */
-    private static final int SECONDS_PER_DAY = 24 * 60 * 60;
-
-    /** Flag for the depth test */
-    private static final boolean PERFORM_DEPTH_TEST= false;
-
-    /** Use raw time zone offsets, disregarding "summer time."  If false,
-     * current offsets will be used, which requires a much longer startup time
-     * in order to sort the city database.
-     */
-    private static final boolean USE_RAW_OFFSETS = true;
-
-    /**
-     * The earth's atmosphere.
-     */
-    private static final Annulus ATMOSPHERE =
-        new Annulus(0.0f, 0.0f, 1.75f, 0.9f, 1.08f, 0.4f, 0.4f, 0.8f, 0.0f,
-            0.0f, 0.0f, 0.0f, 1.0f, 50);
-
-    /**
-     * The tesselation of the earth by latitude.
-     */
-    private static final int SPHERE_LATITUDES = 25;
-
-    /**
-     * The tesselation of the earth by longitude.
-     */
-    private static int SPHERE_LONGITUDES = 25;
-
-    /**
-     * A flattened version of the earth.  The normals are computed identically
-     * to those of the round earth, allowing the day/night lighting to be
-     * applied to the flattened surface.
-     */
-    private static Sphere worldFlat = new LatLongSphere(0.0f, 0.0f, 0.0f, 1.0f,
-        SPHERE_LATITUDES, SPHERE_LONGITUDES,
-        0.0f, 360.0f, true, true, false, true);
-
-    /**
-     * The earth.
-     */
-    private Object3D mWorld;
-
-    /**
-     * Geometry of the city lights
-     */
-    private PointCloud mLights;
-
-    /**
-     * True if the activiy has been initialized.
-     */
-    boolean mInitialized = false;
-
-    /**
-     * True if we're in alphabetic entry mode.
-     */
-    private boolean mAlphaKeySet = false;
-
-    private EGLContext mEGLContext;
-    private EGLSurface mEGLSurface;
-    private EGLDisplay mEGLDisplay;
-    private EGLConfig  mEGLConfig;
-    GLView  mGLView;
-
-    // Rotation and tilt of the Earth
-    private float mRotAngle = 0.0f;
-    private float mTiltAngle = 0.0f;
-
-    // Rotational velocity of the orbiting viewer
-    private float mRotVelocity = 1.0f;
-
-    // Rotation of the flat view
-    private float mWrapX =  0.0f;
-    private float  mWrapVelocity =  0.0f;
-    private float mWrapVelocityFactor =  0.01f;
-
-    // Toggle switches
-    private boolean mDisplayAtmosphere = true;
-    private boolean mDisplayClock = false;
-    private boolean mClockShowing = false;
-    private boolean mDisplayLights = false;
-    private boolean mDisplayWorld = true;
-    private boolean mDisplayWorldFlat = false;
-    private boolean mSmoothShading = true;
-
-    // City search string
-    private String mCityName = "";
-
-    // List of all cities
-    private List<City> mClockCities;
-
-    // List of cities matching a user-supplied prefix
-    private List<City> mCityNameMatches = new ArrayList<City>();
-
-    private List<City> mCities;
-
-    // Start time for clock fade animation
-    private long mClockFadeTime;
-
-    // Interpolator for clock fade animation
-    private Interpolator mClockSizeInterpolator =
-        new DecelerateInterpolator(1.0f);
-
-    // Index of current clock
-    private int mCityIndex;
-
-    // Current clock
-    private Clock mClock;
-
-    // City-to-city flight animation parameters
-    private boolean mFlyToCity = false;
-    private long mCityFlyStartTime;
-    private float mCityFlightTime;
-    private float mRotAngleStart, mRotAngleDest;
-    private float mTiltAngleStart, mTiltAngleDest;
-
-    // Interpolator for flight motion animation
-    private Interpolator mFlyToCityInterpolator =
-        new AccelerateDecelerateInterpolator();
-
-    private static int sNumLights;
-    private static int[] sLightCoords;
-
-    //     static Map<Float,int[]> cityCoords = new HashMap<Float,int[]>();
-
-    // Arrays for GL calls
-    private float[] mClipPlaneEquation = new float[4];
-    private float[] mLightDir = new float[4];
-
-    // Calendar for computing the Sun's position
-    Calendar mSunCal = Calendar.getInstance(UTC_TIME_ZONE);
-
-    // Triangles drawn per frame
-    private int mNumTriangles;
-
-    private long startTime;
-
-    private static final int MOTION_NONE = 0;
-    private static final int MOTION_X = 1;
-    private static final int MOTION_Y = 2;
-
-    private static final int MIN_MANHATTAN_DISTANCE = 20;
-    private static final float ROTATION_FACTOR = 1.0f / 30.0f;
-    private static final float TILT_FACTOR = 0.35f;
-
-    // Touchscreen support
-    private float mMotionStartX;
-    private float mMotionStartY;
-    private float mMotionStartRotVelocity;
-    private float mMotionStartTiltAngle;
-    private int mMotionDirection;
-    
-    private boolean mPaused = true;
-    private boolean mHaveSurface = false;
-    private boolean mStartAnimating = false;
-    
-    public void surfaceCreated(SurfaceHolder holder) {
-        mHaveSurface = true;
-        startEGL();
-    }
-
-    public void surfaceDestroyed(SurfaceHolder holder) {
-        mHaveSurface = false;
-        stopEGL();
-    }
-
-    public void surfaceChanged(SurfaceHolder holder, int format, int w, int h) {
-        // nothing to do
-    }
-
-    /**
-     * Set up the view.
-     *
-     * @param context the Context
-     * @param am an AssetManager to retrieve the city database from
-     */
-    public GTView(Context context) {
-        super(context);
-
-        getHolder().addCallback(this);
-        getHolder().setType(SurfaceHolder.SURFACE_TYPE_GPU);
-
-        startTime = System.currentTimeMillis();
-
-        mClock = new Clock();
-
-        startEGL();
-        
-        setFocusable(true);
-        setFocusableInTouchMode(true);
-        requestFocus();
-    }
-
-    /**
-     * Creates an egl context. If the state of the activity is right, also
-     * creates the egl surface. Otherwise the surface will be created in a
-     * future call to createEGLSurface().
-     */
-    private void startEGL() {
-        EGL10 egl = (EGL10)EGLContext.getEGL();
-
-        if (mEGLContext == null) {
-            EGLDisplay dpy = egl.eglGetDisplay(EGL10.EGL_DEFAULT_DISPLAY);
-            int[] version = new int[2];
-            egl.eglInitialize(dpy, version);
-            int[] configSpec = {
-                    EGL10.EGL_DEPTH_SIZE,   16,
-                    EGL10.EGL_NONE
-            };
-            EGLConfig[] configs = new EGLConfig[1];
-            int[] num_config = new int[1];
-            egl.eglChooseConfig(dpy, configSpec, configs, 1, num_config);
-            mEGLConfig = configs[0];
-
-            mEGLContext = egl.eglCreateContext(dpy, mEGLConfig, 
-                    EGL10.EGL_NO_CONTEXT, null);
-            mEGLDisplay = dpy;
-            
-            AssetManager am = mContext.getAssets();
-            try {
-                loadAssets(am);
-            } catch (IOException ioe) {
-                ioe.printStackTrace();
-                throw new RuntimeException(ioe);
-            } catch (ArrayIndexOutOfBoundsException aioobe) {
-                aioobe.printStackTrace();
-                throw new RuntimeException(aioobe);
-            }
-        }
-        
-        if (mEGLSurface == null && !mPaused && mHaveSurface) {
-            mEGLSurface = egl.eglCreateWindowSurface(mEGLDisplay, mEGLConfig, 
-                    this, null);
-            egl.eglMakeCurrent(mEGLDisplay, mEGLSurface, mEGLSurface, 
-                    mEGLContext);
-            mInitialized = false;
-            if (mStartAnimating) {
-                startAnimating();
-                mStartAnimating = false;
-            }
-        }
-    }
-    
-    /**
-     * Destroys the egl context. If an egl surface has been created, it is
-     * destroyed as well.
-     */
-    private void stopEGL() {
-        EGL10 egl = (EGL10)EGLContext.getEGL();
-        if (mEGLSurface != null) {
-            egl.eglMakeCurrent(mEGLDisplay, 
-                    egl.EGL_NO_SURFACE, egl.EGL_NO_SURFACE, egl.EGL_NO_CONTEXT);
-            egl.eglDestroySurface(mEGLDisplay, mEGLSurface);
-            mEGLSurface = null;
-        }
-
-        if (mEGLContext != null) {
-            egl.eglDestroyContext(mEGLDisplay, mEGLContext);
-            egl.eglTerminate(mEGLDisplay);
-            mEGLContext = null;
-            mEGLDisplay = null;
-            mEGLConfig = null;
-        }
-    }
-    
-    public void onPause() {
-        mPaused = true;
-        stopAnimating();
-        stopEGL();
-    }
-    
-    public void onResume() {
-        mPaused = false;
-        startEGL();
-    }
-    
-    public void destroy() {
-        stopAnimating();
-        stopEGL();
-    }
-
-    /**
-     * Begin animation.
-     */
-    public void startAnimating() {
-        if (mEGLSurface == null) {
-            mStartAnimating = true; // will start when egl surface is created
-        } else {
-            mHandler.sendEmptyMessage(INVALIDATE);
-        }
-    }
-
-    /**
-     * Quit animation.
-     */
-    public void stopAnimating() {
-        mHandler.removeMessages(INVALIDATE);
-    }
-
-    /**
-     * Read a two-byte integer from the input stream.
-     */
-    private int readInt16(InputStream is) throws IOException {
-        int lo = is.read();
-        int hi = is.read();
-        return (hi << 8) | lo;
-    }
-
-    /**
-     * Returns the offset from UTC for the given city.  If USE_RAW_OFFSETS
-     * is true, summer/daylight savings is ignored.
-     */
-    private static float getOffset(City c) {
-        return USE_RAW_OFFSETS ? c.getRawOffset() : c.getOffset();
-    }
-
-    private InputStream cache(InputStream is) throws IOException {
-        int nbytes = is.available();
-        byte[] data = new byte[nbytes];
-        int nread = 0;
-        while (nread < nbytes) {
-            nread += is.read(data, nread, nbytes - nread);
-        }
-        return new ByteArrayInputStream(data);
-    }
-
-    /**
-     * Load the city and lights databases.
-     *
-     * @param am the AssetManager to load from.
-     */
-    private void loadAssets(final AssetManager am) throws IOException {
-        Locale locale = Locale.getDefault();
-        String language = locale.getLanguage();
-        String country = locale.getCountry();
-
-        InputStream cis = null;
-        try {
-            // Look for (e.g.) cities_fr_FR.dat or cities_fr_CA.dat
-            cis = am.open("cities_" + language + "_" + country + ".dat");
-        } catch (FileNotFoundException e1) {
-            try {
-                // Look for (e.g.) cities_fr.dat or cities_fr.dat
-                cis = am.open("cities_" + language + ".dat");
-            } catch (FileNotFoundException e2) {
-                try {
-                    // Use English city names by default
-                    cis = am.open("cities_en.dat");
-                } catch (FileNotFoundException e3) {
-                    throw e3;
-                }
-            }
-        }
-
-        cis = cache(cis);
-        City.loadCities(cis);
-        City[] cities;
-        if (USE_RAW_OFFSETS) {
-            cities = City.getCitiesByRawOffset();
-        } else {
-            cities = City.getCitiesByOffset();
-        }
-
-        mClockCities = new ArrayList<City>(cities.length);
-        for (int i = 0; i < cities.length; i++) {
-            mClockCities.add(cities[i]);
-        }
-        mCities = mClockCities;
-        mCityIndex = 0;
-
-        this.mWorld = new Object3D() {
-                @Override
-                public InputStream readFile(String filename)
-                    throws IOException {
-                    return cache(am.open(filename));
-                }
-            };
-
-        mWorld.load("world.gles");
-
-        // lights.dat has the following format.  All integers
-        // are 16 bits, low byte first.
-        //
-        // width
-        // height
-        // N [# of lights]
-        // light 0 X [in the range 0 to (width - 1)]
-        // light 0 Y ]in the range 0 to (height - 1)]
-        // light 1 X [in the range 0 to (width - 1)]
-        // light 1 Y ]in the range 0 to (height - 1)]
-        // ...
-        // light (N - 1) X [in the range 0 to (width - 1)]
-        // light (N - 1) Y ]in the range 0 to (height - 1)]
-        //
-        // For a larger number of lights, it could make more
-        // sense to store the light positions in a bitmap
-        // and extract them manually
-        InputStream lis = am.open("lights.dat");
-        lis = cache(lis);
-
-        int lightWidth = readInt16(lis);
-        int lightHeight = readInt16(lis);
-        sNumLights = readInt16(lis);
-        sLightCoords = new int[3 * sNumLights];
-
-        int lidx = 0;
-        float lightRadius = 1.009f;
-        float lightScale = 65536.0f * lightRadius;
-
-        float[] cosTheta = new float[lightWidth];
-        float[] sinTheta = new float[lightWidth];
-        float twoPi = (float) (2.0 * Math.PI);
-        float scaleW = twoPi / lightWidth;
-        for (int i = 0; i < lightWidth; i++) {
-            float theta = twoPi - i * scaleW;
-            cosTheta[i] = (float)Math.cos(theta);
-            sinTheta[i] = (float)Math.sin(theta);
-        }
-
-        float[] cosPhi = new float[lightHeight];
-        float[] sinPhi = new float[lightHeight];
-        float scaleH = (float) (Math.PI / lightHeight);
-        for (int j = 0; j < lightHeight; j++) {
-            float phi = j * scaleH;
-            cosPhi[j] = (float)Math.cos(phi);
-            sinPhi[j] = (float)Math.sin(phi);
-        }
-
-        int nbytes = 4 * sNumLights;
-        byte[] ilights = new byte[nbytes];
-        int nread = 0;
-        while (nread < nbytes) {
-            nread += lis.read(ilights, nread, nbytes - nread);
-        }
-
-        int idx = 0;
-        for (int i = 0; i < sNumLights; i++) {
-            int lx = (((ilights[idx + 1] & 0xff) << 8) |
-                       (ilights[idx    ] & 0xff));
-            int ly = (((ilights[idx + 3] & 0xff) << 8) |
-                       (ilights[idx + 2] & 0xff));
-            idx += 4;
-
-            float sin = sinPhi[ly];
-            float x = cosTheta[lx]*sin;
-            float y = cosPhi[ly];
-            float z = sinTheta[lx]*sin;
-
-            sLightCoords[lidx++] = (int) (x * lightScale);
-            sLightCoords[lidx++] = (int) (y * lightScale);
-            sLightCoords[lidx++] = (int) (z * lightScale);
-        }
-        mLights = new PointCloud(sLightCoords);
-    }
-
-    /**
-     * Returns true if two time zone offsets are equal.  We assume distinct
-     * time zone offsets will differ by at least a few minutes.
-     */
-    private boolean tzEqual(float o1, float o2) {
-        return Math.abs(o1 - o2) < 0.001;
-    }
-
-    /**
-     * Move to a different time zone.
-     *
-     * @param incr The increment between the current and future time zones.
-     */
-    private void shiftTimeZone(int incr) {
-        // If only 1 city in the current set, there's nowhere to go
-        if (mCities.size() <= 1) {
-            return;
-        }
-
-        float offset = getOffset(mCities.get(mCityIndex));
-        do {
-            mCityIndex = (mCityIndex + mCities.size() + incr) % mCities.size();
-        } while (tzEqual(getOffset(mCities.get(mCityIndex)), offset));
-
-        offset = getOffset(mCities.get(mCityIndex));
-        locateCity(true, offset);
-        goToCity();
-    }
-
-    /**
-     * Returns true if there is another city within the current time zone
-     * that is the given increment away from the current city.
-     *
-     * @param incr the increment, +1 or -1
-     * @return
-     */
-    private boolean atEndOfTimeZone(int incr) {
-        if (mCities.size() <= 1) {
-            return true;
-        }
-
-        float offset = getOffset(mCities.get(mCityIndex));
-        int nindex = (mCityIndex + mCities.size() + incr) % mCities.size();
-        if (tzEqual(getOffset(mCities.get(nindex)), offset)) {
-            return false;
-        }
-        return true;
-    }
-
-    /**
-     * Shifts cities within the current time zone.
-     *
-     * @param incr the increment, +1 or -1
-     */
-    private void shiftWithinTimeZone(int incr) {
-        float offset = getOffset(mCities.get(mCityIndex));
-        int nindex = (mCityIndex + mCities.size() + incr) % mCities.size();
-        if (tzEqual(getOffset(mCities.get(nindex)), offset)) {
-            mCityIndex = nindex;
-            goToCity();
-        }
-    }
-
-    /**
-     * Returns true if the city name matches the given prefix, ignoring spaces.
-     */
-    private boolean nameMatches(City city, String prefix) {
-        String cityName = city.getName().replaceAll("[ ]", "");
-        return prefix.regionMatches(true, 0,
-                                    cityName, 0,
-                                    prefix.length());
-    }
-
-    /**
-     * Returns true if there are cities matching the given name prefix.
-     */
-    private boolean hasMatches(String prefix) {
-        for (int i = 0; i < mClockCities.size(); i++) {
-            City city = mClockCities.get(i);
-            if (nameMatches(city, prefix)) {
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Shifts to the nearest city that matches the new prefix.
-     */
-    private void shiftByName() {
-        // Attempt to keep current city if it matches
-        City finalCity = null;
-        City currCity = mCities.get(mCityIndex);
-        if (nameMatches(currCity, mCityName)) {
-            finalCity = currCity;
-        }
-
-        mCityNameMatches.clear();
-        for (int i = 0; i < mClockCities.size(); i++) {
-            City city = mClockCities.get(i);
-            if (nameMatches(city, mCityName)) {
-                mCityNameMatches.add(city);
-            }
-        }
-
-        mCities = mCityNameMatches;
-
-        if (finalCity != null) {
-            for (int i = 0; i < mCityNameMatches.size(); i++) {
-                if (mCityNameMatches.get(i) == finalCity) {
-                    mCityIndex = i;
-                    break;
-                }
-            }
-        } else {
-            // Find the closest matching city
-            locateCity(false, 0.0f);
-        }
-        goToCity();
-    }
-
-    /**
-     * Increases or decreases the rotational speed of the earth.
-     */
-    private void incrementRotationalVelocity(float incr) {
-        if (mDisplayWorldFlat) {
-            mWrapVelocity -= incr;
-        } else {
-            mRotVelocity -= incr;
-        }
-    }
-
-    /**
-     * Clears the current matching prefix, while keeping the focus on
-     * the current city.
-     */
-    private void clearCityMatches() {
-        // Determine the global city index that matches the current city
-        if (mCityNameMatches.size() > 0) {
-            City city = mCityNameMatches.get(mCityIndex);
-            for (int i = 0; i < mClockCities.size(); i++) {
-                City ncity = mClockCities.get(i);
-                if (city.equals(ncity)) {
-                    mCityIndex = i;
-                    break;
-                }
-            }
-        }
-
-        mCityName = "";
-        mCityNameMatches.clear();
-        mCities = mClockCities;
-        goToCity();
-    }
-
-    /**
-     * Fade the clock in or out.
-     */
-    private void enableClock(boolean enabled) {
-        mClockFadeTime = System.currentTimeMillis();
-        mDisplayClock = enabled;
-        mClockShowing = true;
-        mAlphaKeySet = enabled;
-        if (enabled) {
-            // Find the closest matching city
-            locateCity(false, 0.0f);
-        }
-        clearCityMatches();
-    }
-
-    /**
-     * Use the touchscreen to alter the rotational velocity or the
-     * tilt of the earth.
-     */
-    @Override public boolean onTouchEvent(MotionEvent event) {
-        switch (event.getAction()) {
-            case MotionEvent.ACTION_DOWN:
-                mMotionStartX = event.getX();
-                mMotionStartY = event.getY();
-                mMotionStartRotVelocity = mDisplayWorldFlat ?
-                    mWrapVelocity : mRotVelocity;
-                mMotionStartTiltAngle = mTiltAngle;
-
-                // Stop the rotation
-                if (mDisplayWorldFlat) {
-                    mWrapVelocity = 0.0f;
-                } else {
-                    mRotVelocity = 0.0f;
-                }
-                mMotionDirection = MOTION_NONE;
-                break;
-
-            case MotionEvent.ACTION_MOVE:
-                // Disregard motion events when the clock is displayed
-                float dx = event.getX() - mMotionStartX;
-                float dy = event.getY() - mMotionStartY;
-                float delx = Math.abs(dx);
-                float dely = Math.abs(dy);
-
-                // Determine the direction of motion (major axis)
-                // Once if has been determined, it's locked in until
-                // we receive ACTION_UP or ACTION_CANCEL
-                if ((mMotionDirection == MOTION_NONE) &&
-                    (delx + dely > MIN_MANHATTAN_DISTANCE)) {
-                    if (delx > dely) {
-                        mMotionDirection = MOTION_X;
-                    } else {
-                        mMotionDirection = MOTION_Y;
-                    }
-                }
-
-                // If the clock is displayed, don't actually rotate or tilt;
-                // just use mMotionDirection to record whether motion occurred
-                if (!mDisplayClock) {
-                    if (mMotionDirection == MOTION_X) {
-                        if (mDisplayWorldFlat) {
-                            mWrapVelocity = mMotionStartRotVelocity +
-                                dx * ROTATION_FACTOR;
-                        } else {
-                            mRotVelocity = mMotionStartRotVelocity +
-                                dx * ROTATION_FACTOR;
-                        }
-                        mClock.setCity(null);
-                    } else if (mMotionDirection == MOTION_Y &&
-                        !mDisplayWorldFlat) {
-                        mTiltAngle = mMotionStartTiltAngle + dy * TILT_FACTOR;
-                        if (mTiltAngle < -90.0f) {
-                            mTiltAngle = -90.0f;
-                        }
-                        if (mTiltAngle > 90.0f) {
-                            mTiltAngle = 90.0f;
-                        }
-                        mClock.setCity(null);
-                    }
-                }
-                break;
-
-            case MotionEvent.ACTION_UP:
-                mMotionDirection = MOTION_NONE;
-                break;
-
-            case MotionEvent.ACTION_CANCEL:
-                mTiltAngle = mMotionStartTiltAngle;
-                if (mDisplayWorldFlat) {
-                    mWrapVelocity = mMotionStartRotVelocity;
-                } else {
-                    mRotVelocity = mMotionStartRotVelocity;
-                }
-                mMotionDirection = MOTION_NONE;
-                break;
-        }
-        return true;
-    }
-
-    @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-        if (mInitialized && mGLView.processKey(keyCode)) {
-            boolean drawing = (mClockShowing || mGLView.hasMessages());
-            this.setWillNotDraw(!drawing);
-            return true;
-        }
-
-        boolean handled = false;
-
-        // If we're not in alphabetical entry mode, convert letters
-        // to their digit equivalents
-        if (!mAlphaKeySet) {
-            char numChar = event.getNumber();
-            if (numChar >= '0' && numChar <= '9') {
-                keyCode = KeyEvent.KEYCODE_0 + (numChar - '0');
-            }
-        }
-
-        switch (keyCode) {
-        // The 'space' key toggles the clock
-        case KeyEvent.KEYCODE_SPACE:
-            mAlphaKeySet = !mAlphaKeySet;
-            enableClock(mAlphaKeySet);
-            handled = true;
-            break;
-
-        // The 'left' and 'right' buttons shift time zones if the clock is
-        // displayed, otherwise they alters the rotational speed of the earthh
-        case KeyEvent.KEYCODE_DPAD_LEFT:
-            if (mDisplayClock) {
-                shiftTimeZone(-1);
-            } else {
-                mClock.setCity(null);
-                incrementRotationalVelocity(1.0f);
-            }
-            handled = true;
-            break;
-
-        case KeyEvent.KEYCODE_DPAD_RIGHT:
-            if (mDisplayClock) {
-                shiftTimeZone(1);
-            } else {
-                mClock.setCity(null);
-                incrementRotationalVelocity(-1.0f);
-            }
-            handled = true;
-            break;
-
-        // The 'up' and 'down' buttons shift cities within a time zone if the
-        // clock is displayed, otherwise they tilt the earth
-        case KeyEvent.KEYCODE_DPAD_UP:
-            if (mDisplayClock) {
-                shiftWithinTimeZone(-1);
-            } else {
-                mClock.setCity(null);
-                if (!mDisplayWorldFlat) {
-                    mTiltAngle += 360.0f / 48.0f;
-                }
-            }
-            handled = true;
-            break;
-
-        case KeyEvent.KEYCODE_DPAD_DOWN:
-            if (mDisplayClock) {
-                shiftWithinTimeZone(1);
-            } else {
-                mClock.setCity(null);
-                if (!mDisplayWorldFlat) {
-                    mTiltAngle -= 360.0f / 48.0f;
-                }
-            }
-            handled = true;
-            break;
-
-        // The center key stops the earth's rotation, then toggles between the
-        // round and flat views of the earth
-        case KeyEvent.KEYCODE_DPAD_CENTER:
-            if ((!mDisplayWorldFlat && mRotVelocity == 0.0f) ||
-                (mDisplayWorldFlat && mWrapVelocity == 0.0f)) {
-                mDisplayWorldFlat = !mDisplayWorldFlat;
-            } else {
-                if (mDisplayWorldFlat) {
-                    mWrapVelocity = 0.0f;
-                } else {
-                    mRotVelocity = 0.0f;
-                }
-            }
-            handled = true;
-            break;
-
-        // The 'L' key toggles the city lights
-        case KeyEvent.KEYCODE_L:
-            if (!mAlphaKeySet && !mDisplayWorldFlat) {
-                mDisplayLights = !mDisplayLights;
-                handled = true;
-            }
-            break;
-
-
-        // The 'W' key toggles the earth (just for fun)
-        case KeyEvent.KEYCODE_W:
-            if (!mAlphaKeySet && !mDisplayWorldFlat) {
-                mDisplayWorld = !mDisplayWorld;
-                handled = true;
-            }
-            break;
-
-        // The 'A' key toggles the atmosphere
-        case KeyEvent.KEYCODE_A:
-            if (!mAlphaKeySet && !mDisplayWorldFlat) {
-                mDisplayAtmosphere = !mDisplayAtmosphere;
-                handled = true;
-            }
-            break;
-
-        // The '2' key zooms out
-        case KeyEvent.KEYCODE_2:
-            if (!mAlphaKeySet && !mDisplayWorldFlat) {
-                mGLView.zoom(-2);
-                handled = true;
-            }
-            break;
-
-        // The '8' key zooms in
-        case KeyEvent.KEYCODE_8:
-            if (!mAlphaKeySet && !mDisplayWorldFlat) {
-                mGLView.zoom(2);
-                handled = true;
-            }
-            break;
-        }
-
-        // Handle letters in city names
-        if (!handled && mAlphaKeySet) {
-            switch (keyCode) {
-            // Add a letter to the city name prefix
-            case KeyEvent.KEYCODE_A:
-            case KeyEvent.KEYCODE_B:
-            case KeyEvent.KEYCODE_C:
-            case KeyEvent.KEYCODE_D:
-            case KeyEvent.KEYCODE_E:
-            case KeyEvent.KEYCODE_F:
-            case KeyEvent.KEYCODE_G:
-            case KeyEvent.KEYCODE_H:
-            case KeyEvent.KEYCODE_I:
-            case KeyEvent.KEYCODE_J:
-            case KeyEvent.KEYCODE_K:
-            case KeyEvent.KEYCODE_L:
-            case KeyEvent.KEYCODE_M:
-            case KeyEvent.KEYCODE_N:
-            case KeyEvent.KEYCODE_O:
-            case KeyEvent.KEYCODE_P:
-            case KeyEvent.KEYCODE_Q:
-            case KeyEvent.KEYCODE_R:
-            case KeyEvent.KEYCODE_S:
-            case KeyEvent.KEYCODE_T:
-            case KeyEvent.KEYCODE_U:
-            case KeyEvent.KEYCODE_V:
-            case KeyEvent.KEYCODE_W:
-            case KeyEvent.KEYCODE_X:
-            case KeyEvent.KEYCODE_Y:
-            case KeyEvent.KEYCODE_Z:
-                char c = (char)(keyCode - KeyEvent.KEYCODE_A + 'A');
-                if (hasMatches(mCityName + c)) {
-                    mCityName += c;
-                    shiftByName();
-                }
-                handled = true;
-                break;
-
-            // Remove a letter from the city name prefix
-            case KeyEvent.KEYCODE_DEL:
-                if (mCityName.length() > 0) {
-                    mCityName = mCityName.substring(0, mCityName.length() - 1);
-                    shiftByName();
-                } else {
-                    clearCityMatches();
-                }
-                handled = true;
-                break;
-
-            // Clear the city name prefix
-            case KeyEvent.KEYCODE_ENTER:
-                clearCityMatches();
-                handled = true;
-                break;
-            }
-        }
-
-        boolean drawing = (mClockShowing ||
-            ((mGLView != null) && (mGLView.hasMessages())));
-        this.setWillNotDraw(!drawing);
-
-        // Let the system handle other keypresses
-        if (!handled) {
-            return super.onKeyDown(keyCode, event);
-        }
-        return true;
-    }
-
-    /**
-     * Initialize OpenGL ES drawing.
-     */
-    private synchronized void init(GL10 gl) {
-        mGLView = new GLView();
-        mGLView.setNearFrustum(5.0f);
-        mGLView.setFarFrustum(50.0f);
-        mGLView.setLightModelAmbientIntensity(0.225f);
-        mGLView.setAmbientIntensity(0.0f);
-        mGLView.setDiffuseIntensity(1.5f);
-        mGLView.setDiffuseColor(SUNLIGHT_COLOR);
-        mGLView.setSpecularIntensity(0.0f);
-        mGLView.setSpecularColor(SUNLIGHT_COLOR);
-
-        if (PERFORM_DEPTH_TEST) {
-            gl.glEnable(GL10.GL_DEPTH_TEST);
-        }
-        gl.glDisable(GL10.GL_SCISSOR_TEST);
-        gl.glClearColor(0, 0, 0, 1);
-        gl.glHint(GL10.GL_POINT_SMOOTH_HINT, GL10.GL_NICEST);
-
-        mInitialized = true;
-    }
-
-    /**
-     * Computes the vector from the center of the earth to the sun for a
-     * particular moment in time.
-     */
-    private void computeSunDirection() {
-        mSunCal.setTimeInMillis(System.currentTimeMillis());
-        int day = mSunCal.get(Calendar.DAY_OF_YEAR);
-        int seconds = 3600 * mSunCal.get(Calendar.HOUR_OF_DAY) +
-            60 * mSunCal.get(Calendar.MINUTE) + mSunCal.get(Calendar.SECOND);
-        day += (float) seconds / SECONDS_PER_DAY;
-
-        // Approximate declination of the sun, changes sinusoidally
-        // during the year.  The winter solstice occurs 10 days before
-        // the start of the year.
-        float decl = (float) (EARTH_INCLINATION *
-            Math.cos(Shape.TWO_PI * (day + 10) / 365.0));
-
-        // Subsolar latitude, convert from (-PI/2, PI/2) -> (0, PI) form
-        float phi = decl + Shape.PI_OVER_TWO;
-        // Subsolar longitude
-        float theta = Shape.TWO_PI * seconds / SECONDS_PER_DAY;
-
-        float sinPhi = (float) Math.sin(phi);
-        float cosPhi = (float) Math.cos(phi);
-        float sinTheta = (float) Math.sin(theta);
-        float cosTheta = (float) Math.cos(theta);
-
-        // Convert from polar to rectangular coordinates
-        float x = cosTheta * sinPhi;
-        float y = cosPhi;
-        float z = sinTheta * sinPhi;
-
-        // Directional light -> w == 0
-        mLightDir[0] = x;
-        mLightDir[1] = y;
-        mLightDir[2] = z;
-        mLightDir[3] = 0.0f;
-    }
-
-    /**
-     * Computes the approximate spherical distance between two
-     * (latitude, longitude) coordinates.
-     */
-    private float distance(float lat1, float lon1,
-                           float lat2, float lon2) {
-        lat1 *= Shape.DEGREES_TO_RADIANS;
-        lat2 *= Shape.DEGREES_TO_RADIANS;
-        lon1 *= Shape.DEGREES_TO_RADIANS;
-        lon2 *= Shape.DEGREES_TO_RADIANS;
-
-        float r = 6371.0f; // Earth's radius in km
-        float dlat = lat2 - lat1;
-        float dlon = lon2 - lon1;
-        double sinlat2 = Math.sin(dlat / 2.0f);
-        sinlat2 *= sinlat2;
-        double sinlon2 = Math.sin(dlon / 2.0f);
-        sinlon2 *= sinlon2;
-
-        double a = sinlat2 + Math.cos(lat1) * Math.cos(lat2) * sinlon2;
-        double c = 2.0 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
-        return (float) (r * c);
-    }
-
-    /**
-     * Locates the closest city to the currently displayed center point,
-     * optionally restricting the search to cities within a given time zone.
-     */
-    private void locateCity(boolean useOffset, float offset) {
-        float mindist = Float.MAX_VALUE;
-        int minidx = -1;
-        for (int i = 0; i < mCities.size(); i++) {
-            City city = mCities.get(i);
-            if (useOffset && !tzEqual(getOffset(city), offset)) {
-                continue;
-            }
-            float dist = distance(city.getLatitude(), city.getLongitude(),
-                mTiltAngle, mRotAngle - 90.0f);
-            if (dist < mindist) {
-                mindist = dist;
-                minidx = i;
-            }
-        }
-
-        mCityIndex = minidx;
-    }
-
-    /**
-     * Animates the earth to be centered at the current city.
-     */
-    private void goToCity() {
-        City city = mCities.get(mCityIndex);
-        float dist = distance(city.getLatitude(), city.getLongitude(),
-            mTiltAngle, mRotAngle - 90.0f);
-
-        mFlyToCity = true;
-        mCityFlyStartTime = System.currentTimeMillis();
-        mCityFlightTime = dist / 5.0f; // 5000 km/sec
-        mRotAngleStart = mRotAngle;
-        mRotAngleDest = city.getLongitude() + 90;
-
-        if (mRotAngleDest - mRotAngleStart > 180.0f) {
-            mRotAngleDest -= 360.0f;
-        } else if (mRotAngleStart - mRotAngleDest > 180.0f) {
-            mRotAngleDest += 360.0f;
-        }
-
-        mTiltAngleStart = mTiltAngle;
-        mTiltAngleDest = city.getLatitude();
-        mRotVelocity = 0.0f;
-    }
-
-    /**
-     * Returns a linearly interpolated value between two values.
-     */
-    private float lerp(float a, float b, float lerp) {
-        return a + (b - a)*lerp;
-    }
-
-    /**
-     * Draws the city lights, using a clip plane to restrict the lights
-     * to the night side of the earth.
-     */
-    private void drawCityLights(GL10 gl, float brightness) {
-        gl.glEnable(GL10.GL_POINT_SMOOTH);
-        gl.glDisable(GL10.GL_DEPTH_TEST);
-        gl.glDisable(GL10.GL_LIGHTING);
-        gl.glDisable(GL10.GL_DITHER);
-        gl.glShadeModel(GL10.GL_FLAT);
-        gl.glEnable(GL10.GL_BLEND);
-        gl.glBlendFunc(GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA);
-        gl.glPointSize(1.0f);
-
-        float ls = lerp(0.8f, 0.3f, brightness);
-        gl.glColor4f(ls * 1.0f, ls * 1.0f, ls * 0.8f, 1.0f);
-
-        if (mDisplayWorld) {
-            mClipPlaneEquation[0] = -mLightDir[0];
-            mClipPlaneEquation[1] = -mLightDir[1];
-            mClipPlaneEquation[2] = -mLightDir[2];
-            mClipPlaneEquation[3] = 0.0f;
-            // Assume we have glClipPlanef() from OpenGL ES 1.1
-            ((GL11) gl).glClipPlanef(GL11.GL_CLIP_PLANE0,
-                mClipPlaneEquation, 0);
-            gl.glEnable(GL11.GL_CLIP_PLANE0);
-        }
-        mLights.draw(gl);
-        if (mDisplayWorld) {
-            gl.glDisable(GL11.GL_CLIP_PLANE0);
-        }
-
-        mNumTriangles += mLights.getNumTriangles()*2;
-    }
-
-    /**
-     * Draws the atmosphere.
-     */
-    private void drawAtmosphere(GL10 gl) {
-        gl.glDisable(GL10.GL_LIGHTING);
-        gl.glDisable(GL10.GL_CULL_FACE);
-        gl.glDisable(GL10.GL_DITHER);
-        gl.glDisable(GL10.GL_DEPTH_TEST);
-        gl.glShadeModel(mSmoothShading ? GL10.GL_SMOOTH : GL10.GL_FLAT);
-
-        // Draw the atmospheric layer
-        float tx = mGLView.getTranslateX();
-        float ty = mGLView.getTranslateY();
-        float tz = mGLView.getTranslateZ();
-
-        gl.glMatrixMode(GL10.GL_MODELVIEW);
-        gl.glLoadIdentity();
-        gl.glTranslatef(tx, ty, tz);
-
-        // Blend in the atmosphere a bit
-        gl.glEnable(GL10.GL_BLEND);
-        gl.glBlendFunc(GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA);
-        ATMOSPHERE.draw(gl);
-
-        mNumTriangles += ATMOSPHERE.getNumTriangles();
-    }
-
-    /**
-     * Draws the world in a 2D map view.
-     */
-    private void drawWorldFlat(GL10 gl) {
-        gl.glDisable(GL10.GL_BLEND);
-        gl.glEnable(GL10.GL_DITHER);
-        gl.glShadeModel(mSmoothShading ? GL10.GL_SMOOTH : GL10.GL_FLAT);
-
-        gl.glTranslatef(mWrapX - 2, 0.0f, 0.0f);
-        worldFlat.draw(gl);
-        gl.glTranslatef(2.0f, 0.0f, 0.0f);
-        worldFlat.draw(gl);
-        mNumTriangles += worldFlat.getNumTriangles() * 2;
-
-        mWrapX += mWrapVelocity * mWrapVelocityFactor;
-        while (mWrapX < 0.0f) {
-            mWrapX += 2.0f;
-        }
-        while (mWrapX > 2.0f) {
-            mWrapX -= 2.0f;
-        }
-    }
-
-    /**
-     * Draws the world in a 2D round view.
-     */
-    private void drawWorldRound(GL10 gl) {
-        gl.glDisable(GL10.GL_BLEND);
-        gl.glEnable(GL10.GL_DITHER);
-        gl.glShadeModel(mSmoothShading ? GL10.GL_SMOOTH : GL10.GL_FLAT);
-
-        mWorld.draw(gl);
-        mNumTriangles += mWorld.getNumTriangles();
-    }
-
-    /**
-     * Draws the clock.
-     *
-     * @param canvas the Canvas to draw to
-     * @param now the current time
-     * @param w the width of the screen
-     * @param h the height of the screen
-     * @param lerp controls the animation, between 0.0 and 1.0
-     */
-    private void drawClock(Canvas canvas,
-                           long now,
-                           int w, int h,
-                           float lerp) {
-        float clockAlpha = lerp(0.0f, 0.8f, lerp);
-        mClockShowing = clockAlpha > 0.0f;
-        if (clockAlpha > 0.0f) {
-            City city = mCities.get(mCityIndex);
-            mClock.setCity(city);
-            mClock.setTime(now);
-
-            float cx = w / 2.0f;
-            float cy = h / 2.0f;
-            float smallRadius = 18.0f;
-            float bigRadius = 0.75f * 0.5f * Math.min(w, h);
-            float radius = lerp(smallRadius, bigRadius, lerp);
-
-            // Only display left/right arrows if we are in a name search
-            boolean scrollingByName =
-                (mCityName.length() > 0) && (mCities.size() > 1);
-            mClock.drawClock(canvas, cx, cy, radius,
-                             clockAlpha,
-                             1.0f,
-                             lerp == 1.0f, lerp == 1.0f,
-                             !atEndOfTimeZone(-1),
-                             !atEndOfTimeZone(1),
-                             scrollingByName,
-                             mCityName.length());
-        }
-    }
-
-    /**
-     * Draws the 2D layer.
-     */
-    @Override protected void onDraw(Canvas canvas) {
-        long now = System.currentTimeMillis();
-        if (startTime != -1) {
-            startTime = -1;
-        }
-
-        int w = getWidth();
-        int h = getHeight();
-
-        // Interpolator for clock size, clock alpha, night lights intensity
-        float lerp = Math.min((now - mClockFadeTime)/1000.0f, 1.0f);
-        if (!mDisplayClock) {
-            // Clock is receding
-            lerp = 1.0f - lerp;
-        }
-        lerp = mClockSizeInterpolator.getInterpolation(lerp);
-
-        // we don't need to make sure OpenGL rendering is done because
-        // we're drawing in to a different surface
-
-        drawClock(canvas, now, w, h, lerp);
-
-        mGLView.showMessages(canvas);
-        mGLView.showStatistics(canvas, w);
-    }
-
-    /**
-     * Draws the 3D layer.
-     */
-    protected void drawOpenGLScene() {
-        long now = System.currentTimeMillis();
-        mNumTriangles = 0;
-
-        EGL10 egl = (EGL10)EGLContext.getEGL();
-        GL10 gl = (GL10)mEGLContext.getGL();
-
-        if (!mInitialized) {
-            init(gl);
-        }
-
-        int w = getWidth();
-        int h = getHeight();
-        gl.glViewport(0, 0, w, h);
-
-        gl.glEnable(GL10.GL_LIGHTING);
-        gl.glEnable(GL10.GL_LIGHT0);
-        gl.glEnable(GL10.GL_CULL_FACE);
-        gl.glFrontFace(GL10.GL_CCW);
-
-        float ratio = (float) w / h;
-        mGLView.setAspectRatio(ratio);
-
-        mGLView.setTextureParameters(gl);
-
-        if (PERFORM_DEPTH_TEST) {
-            gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT);
-        } else {
-            gl.glClear(GL10.GL_COLOR_BUFFER_BIT);
-        }
-
-        if (mDisplayWorldFlat) {
-            gl.glMatrixMode(GL10.GL_PROJECTION);
-            gl.glLoadIdentity();
-            gl.glFrustumf(-1.0f, 1.0f, -1.0f / ratio, 1.0f / ratio, 1.0f, 2.0f);
-            gl.glMatrixMode(GL10.GL_MODELVIEW);
-            gl.glLoadIdentity();
-            gl.glTranslatef(0.0f, 0.0f, -1.0f);
-        } else {
-            mGLView.setProjection(gl);
-            mGLView.setView(gl);
-        }
-
-        if (!mDisplayWorldFlat) {
-            if (mFlyToCity) {
-                float lerp = (now - mCityFlyStartTime)/mCityFlightTime;
-                if (lerp >= 1.0f) {
-                    mFlyToCity = false;
-                }
-                lerp = Math.min(lerp, 1.0f);
-                lerp = mFlyToCityInterpolator.getInterpolation(lerp);
-                mRotAngle = lerp(mRotAngleStart, mRotAngleDest, lerp);
-                mTiltAngle = lerp(mTiltAngleStart, mTiltAngleDest, lerp);
-            }
-
-            // Rotate the viewpoint around the earth
-            gl.glMatrixMode(GL10.GL_MODELVIEW);
-            gl.glRotatef(mTiltAngle, 1, 0, 0);
-            gl.glRotatef(mRotAngle, 0, 1, 0);
-
-            // Increment the rotation angle
-            mRotAngle += mRotVelocity;
-            if (mRotAngle < 0.0f) {
-                mRotAngle += 360.0f;
-            }
-            if (mRotAngle > 360.0f) {
-                mRotAngle -= 360.0f;
-            }
-        }
-
-        // Draw the world with lighting
-        gl.glLightfv(GL10.GL_LIGHT0, GL10.GL_POSITION, mLightDir, 0);
-        mGLView.setLights(gl, GL10.GL_LIGHT0);
-
-        if (mDisplayWorldFlat) {
-            drawWorldFlat(gl);
-        } else if (mDisplayWorld) {
-            drawWorldRound(gl);
-        }
-
-        if (mDisplayLights && !mDisplayWorldFlat) {
-            // Interpolator for clock size, clock alpha, night lights intensity
-            float lerp = Math.min((now - mClockFadeTime)/1000.0f, 1.0f);
-            if (!mDisplayClock) {
-                // Clock is receding
-                lerp = 1.0f - lerp;
-            }
-            lerp = mClockSizeInterpolator.getInterpolation(lerp);
-            drawCityLights(gl, lerp);
-        }
-
-        if (mDisplayAtmosphere && !mDisplayWorldFlat) {
-            drawAtmosphere(gl);
-        }
-        mGLView.setNumTriangles(mNumTriangles);
-        egl.eglSwapBuffers(mEGLDisplay, mEGLSurface);
-
-        if (egl.eglGetError() == EGL11.EGL_CONTEXT_LOST) {
-            // we lost the gpu, quit immediately
-            Context c = getContext();
-            if (c instanceof Activity) {
-                ((Activity)c).finish();
-            }
-        }
-    }
-
-
-    private static final int INVALIDATE = 1;
-    private static final int ONE_MINUTE = 60000;
-
-    /**
-     * Controls the animation using the message queue.  Every time we receive
-     * an INVALIDATE message, we redraw and place another message in the queue.
-     */
-    private final Handler mHandler = new Handler() {
-        private long mLastSunPositionTime = 0;
-
-        @Override public void handleMessage(Message msg) {
-            if (msg.what == INVALIDATE) {
-
-                // Use the message's time, it's good enough and
-                // allows us to avoid a system call.
-                if ((msg.getWhen() - mLastSunPositionTime) >= ONE_MINUTE) {
-                    // Recompute the sun's position once per minute
-                    // Place the light at the Sun's direction
-                    computeSunDirection();
-                    mLastSunPositionTime = msg.getWhen();
-                }
-
-                // Draw the GL scene
-                drawOpenGLScene();
-
-                // Send an update for the 2D overlay if needed
-                if (mInitialized &&
-                                (mClockShowing || mGLView.hasMessages())) {
-                    invalidate();
-                }
-
-                // Just send another message immediately. This works because
-                // drawOpenGLScene() does the timing for us -- it will
-                // block until the last frame has been processed.
-                // The invalidate message we're posting here will be
-                // interleaved properly with motion/key events which
-                // guarantee a prompt reaction to the user input.
-                sendEmptyMessage(INVALIDATE);
-            }
-        }
-    };
-}
-
-/**
- * The main activity class for GlobalTime.
- */
-public class GlobalTime extends Activity {
-
-    GTView gtView = null;
-
-    @Override protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        gtView = new GTView(this);
-        setContentView(gtView);
-    }
-
-    @Override protected void onResume() {
-        super.onResume();
-        gtView.onResume();
-        Looper.myQueue().addIdleHandler(new Idler());
-    }
-
-    @Override protected void onPause() {
-        super.onPause();
-        gtView.onPause();
-    }
-
-    @Override protected void onStop() {
-        super.onStop();
-        gtView.destroy();
-        gtView = null;
-    }
-
-    // Allow the activity to go idle before its animation starts
-    class Idler implements MessageQueue.IdleHandler {
-        public Idler() {
-            super();
-        }
-
-        public final boolean queueIdle() {
-            if (gtView != null) {
-                gtView.startAnimating();
-            }
-            return false;
-        }
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/LatLongSphere.java b/samples/GlobalTime/src/com/android/globaltime/LatLongSphere.java
deleted file mode 100644
index b455d41..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/LatLongSphere.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-public class LatLongSphere extends Sphere {
-
-    public LatLongSphere(float centerX, float centerY, float centerZ,
-        float radius, int lats, int longs,
-        float minLongitude, float maxLongitude,
-        boolean emitTextureCoordinates,
-        boolean emitNormals,
-        boolean emitColors,
-        boolean flatten) {
-        super(emitTextureCoordinates, emitNormals, emitColors);
-
-        int tris = 2 * (lats - 1) * (longs - 1);
-        int[] vertices = new int[3 * lats * longs];
-        int[] texcoords = new int[2 * lats * longs];
-        int[] colors = new int[4 * lats * longs];
-        int[] normals = new int[3 * lats * longs];
-        short[] indices = new short[3 * tris];
-
-        int vidx = 0;
-        int tidx = 0;
-        int nidx = 0;
-        int cidx = 0;
-        int iidx = 0;
-
-        minLongitude *= DEGREES_TO_RADIANS;
-        maxLongitude *= DEGREES_TO_RADIANS;
-
-        for (int i = 0; i < longs; i++) {
-            float fi = (float) i / (longs - 1);
-            // theta is the longitude
-            float theta =
-                (maxLongitude - minLongitude) * (1.0f - fi) + minLongitude;
-            float sinTheta = (float) Math.sin(theta);
-            float cosTheta = (float) Math.cos(theta);
-
-            for (int j = 0; j < lats; j++) {
-                float fj = (float) j / (lats - 1);
-                // phi is the latitude
-                float phi = PI * fj;
-                float sinPhi = (float) Math.sin(phi);
-                float cosPhi = (float) Math.cos(phi);
-                float x = cosTheta * sinPhi;
-                float y = cosPhi;
-                float z = sinTheta * sinPhi;
-
-                if (flatten) {
-                    // Place vertices onto a flat projection
-                    vertices[vidx++] = toFixed(2.0f * fi - 1.0f);
-                    vertices[vidx++] = toFixed(0.5f - fj);
-                    vertices[vidx++] = toFixed(0.0f);
-                } else {
-                    // Place vertices onto the surface of a sphere
-                    // with the given center and radius
-                    vertices[vidx++] = toFixed(x * radius + centerX);
-                    vertices[vidx++] = toFixed(y * radius + centerY);
-                    vertices[vidx++] = toFixed(z * radius + centerZ);
-                }
-
-                if (emitTextureCoordinates) {
-                    texcoords[tidx++] = toFixed(1.0f - (theta / (TWO_PI)));
-                    texcoords[tidx++] = toFixed(fj);
-                }
-
-                if (emitNormals) {
-                    float norm = 1.0f / Shape.length(x, y, z);
-                    normals[nidx++] = toFixed(x * norm);
-                    normals[nidx++] = toFixed(y * norm);
-                    normals[nidx++] = toFixed(z * norm);
-                }
-
-                // 0 == black, 65536 == white
-                if (emitColors) {
-                    colors[cidx++] = (i % 2) * 65536;
-                    colors[cidx++] = 0;
-                    colors[cidx++] = (j % 2) * 65536;
-                    colors[cidx++] = 65536;
-                }
-            }
-        }
-
-        for (int i = 0; i < longs - 1; i++) {
-            for (int j = 0; j < lats - 1; j++) {
-                int base = i * lats + j;
-
-                // Ensure both triangles have the same final vertex
-                // since this vertex carries the color for flat
-                // shading
-                indices[iidx++] = (short) (base);
-                indices[iidx++] = (short) (base + 1);
-                indices[iidx++] = (short) (base + lats + 1);
-
-                indices[iidx++] = (short) (base + lats);
-                indices[iidx++] = (short) (base);
-                indices[iidx++] = (short) (base + lats + 1);
-            }
-        }
-        
-        allocateBuffers(vertices, texcoords, normals, colors, indices);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/PointCloud.java b/samples/GlobalTime/src/com/android/globaltime/PointCloud.java
deleted file mode 100644
index 6f4fd55..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/PointCloud.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * A class representing a set of GL_POINT objects.  GlobalTime uses this class
- * to draw city lights on the night side of the earth.
- */
-public class PointCloud extends Shape {
-
-    /**
-     * Constructs a PointCloud with a point at each of the given vertex
-     * (x, y, z) positions.
-     * @param vertices an array of (x, y, z) positions given in fixed-point.
-     */
-    public PointCloud(int[] vertices) {
-        this(vertices, 0, vertices.length);
-    }
-
-    /**
-     * Constructs a PointCloud with a point at each of the given vertex
-     * (x, y, z) positions.
-     * @param vertices an array of (x, y, z) positions given in fixed-point.
-     * @param off the starting offset of the vertices array
-     * @param len the number of elements of the vertices array to use
-     */
-    public PointCloud(int[] vertices, int off, int len) {
-        super(GL10.GL_POINTS, GL10.GL_UNSIGNED_SHORT,
-              false, false, false);
-
-        int numPoints = len / 3;
-        short[] indices = new short[numPoints];
-        for (int i = 0; i < numPoints; i++) {
-            indices[i] = (short)i;
-        }
-        
-        allocateBuffers(vertices, null, null, null, indices);
-        this.mNumIndices = mIndexBuffer.capacity();
-    }
-
-    @Override public int getNumTriangles() {
-        return mNumIndices * 2;
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/Shape.java b/samples/GlobalTime/src/com/android/globaltime/Shape.java
deleted file mode 100644
index 6c296ce..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/Shape.java
+++ /dev/null
@@ -1,270 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.nio.Buffer;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.IntBuffer;
-import java.nio.ShortBuffer;
-
-import javax.microedition.khronos.opengles.GL10;
-
-/**
- * An abstract superclass for various three-dimensional objects to be drawn
- * using OpenGL ES.  Each subclass is responsible for setting up NIO buffers
- * containing vertices, texture coordinates, colors, normals, and indices.
- * The {@link #draw(GL10)} method draws the object to the given OpenGL context.
- */
-public abstract class Shape {
-
-    public static final int INT_BYTES = 4;
-    public static final int SHORT_BYTES = 2;
-
-    public static final float DEGREES_TO_RADIANS = (float) Math.PI / 180.0f;
-    public static final float PI = (float) Math.PI;
-    public static final float TWO_PI = (float) (2.0 * Math.PI);
-    public static final float PI_OVER_TWO = (float) (Math.PI / 2.0);
-
-    protected int mPrimitive;
-    protected int mIndexDatatype;
-
-    protected boolean mEmitTextureCoordinates;
-    protected boolean mEmitNormals;
-    protected boolean mEmitColors;
-
-    protected IntBuffer mVertexBuffer;
-    protected IntBuffer mTexcoordBuffer;
-    protected IntBuffer mColorBuffer;
-    protected IntBuffer mNormalBuffer;
-    protected Buffer mIndexBuffer;
-    protected int mNumIndices = -1;
-
-    /**
-     * Constructs a Shape.
-     * 
-     * @param primitive a GL primitive type understood by glDrawElements,
-     * such as GL10.GL_TRIANGLES
-     * @param indexDatatype the GL datatype for the  index buffer, such as
-     * GL10.GL_UNSIGNED_SHORT
-     * @param emitTextureCoordinates true to enable use of the texture
-     * coordinate buffer
-     * @param emitNormals true to enable use of the normal buffer
-     * @param emitColors true to enable use of the color buffer
-     */
-    protected Shape(int primitive,
-        int indexDatatype,
-        boolean emitTextureCoordinates,
-        boolean emitNormals,
-        boolean emitColors) {
-        mPrimitive = primitive;
-        mIndexDatatype = indexDatatype;
-        mEmitTextureCoordinates = emitTextureCoordinates;
-        mEmitNormals = emitNormals;
-        mEmitColors = emitColors;
-    }
-
-    /**
-     * Converts the given floating-point value to fixed-point.
-     */
-    public static int toFixed(float x) {
-        return (int) (x * 65536.0);
-    }
-
-    /**
-     * Converts the given fixed-point value to floating-point.
-     */
-    public static float toFloat(int x) {
-        return (float) (x / 65536.0);
-    }
-
-    /**
-     * Computes the cross-product of two vectors p and q and places
-     * the result in out. 
-     */
-    public static void cross(float[] p, float[] q, float[] out) {
-        out[0] = p[1] * q[2] - p[2] * q[1];
-        out[1] = p[2] * q[0] - p[0] * q[2];
-        out[2] = p[0] * q[1] - p[1] * q[0];
-    }
-
-    /**
-     * Returns the length of a vector, given as three floats.
-     */
-    public static float length(float vx, float vy, float vz) {
-        return (float) Math.sqrt(vx * vx + vy * vy + vz * vz);
-    }
-
-    /**
-     * Returns the length of a vector, given as an array of three floats.
-     */
-    public static float length(float[] v) { 
-        return length(v[0], v[1], v[2]);
-    }
-
-    /**
-     * Normalizes the given vector of three floats to have length == 1.0.
-     * Vectors with length zero are unaffected.
-     */
-    public static void normalize(float[] v) {
-        float length = length(v);
-        if (length != 0.0f) {
-            float norm = 1.0f / length;
-            v[0] *= norm;
-            v[1] *= norm;
-            v[2] *= norm;
-        }
-    }
-
-    /**
-     * Returns the number of triangles associated with this shape.
-     */
-    public int getNumTriangles() {
-        if (mPrimitive == GL10.GL_TRIANGLES) {
-            return mIndexBuffer.capacity() / 3;
-        } else if (mPrimitive == GL10.GL_TRIANGLE_STRIP) {
-            return mIndexBuffer.capacity() - 2;
-        }
-        return 0;
-    }
-    
-    /**
-     * Copies the given data into the instance
-     * variables mVertexBuffer, mTexcoordBuffer, mNormalBuffer, mColorBuffer,
-     * and mIndexBuffer.
-     * 
-     * @param vertices an array of fixed-point vertex coordinates
-     * @param texcoords an array of fixed-point texture coordinates
-     * @param normals an array of fixed-point normal vector coordinates
-     * @param colors an array of fixed-point color channel values
-     * @param indices an array of short indices
-     */
-    public void allocateBuffers(int[] vertices, int[] texcoords, int[] normals,
-        int[] colors, short[] indices) {
-        allocate(vertices, texcoords, normals, colors);
-        
-        ByteBuffer ibb =
-            ByteBuffer.allocateDirect(indices.length * SHORT_BYTES);
-        ibb.order(ByteOrder.nativeOrder());
-        ShortBuffer shortIndexBuffer = ibb.asShortBuffer();
-        shortIndexBuffer.put(indices);
-        shortIndexBuffer.position(0);
-        this.mIndexBuffer = shortIndexBuffer;
-    }
-    
-    /**
-     * Copies the given data into the instance
-     * variables mVertexBuffer, mTexcoordBuffer, mNormalBuffer, mColorBuffer,
-     * and mIndexBuffer.
-     * 
-     * @param vertices an array of fixed-point vertex coordinates
-     * @param texcoords an array of fixed-point texture coordinates
-     * @param normals an array of fixed-point normal vector coordinates
-     * @param colors an array of fixed-point color channel values
-     * @param indices an array of int indices
-     */
-    public void allocateBuffers(int[] vertices, int[] texcoords, int[] normals,
-        int[] colors, int[] indices) {
-        allocate(vertices, texcoords, normals, colors);
-        
-        ByteBuffer ibb =
-            ByteBuffer.allocateDirect(indices.length * INT_BYTES);
-        ibb.order(ByteOrder.nativeOrder());
-        IntBuffer intIndexBuffer = ibb.asIntBuffer();
-        intIndexBuffer.put(indices);
-        intIndexBuffer.position(0);
-        this.mIndexBuffer = intIndexBuffer;
-    }
-    
-    /**
-     * Allocate the vertex, texture coordinate, normal, and color buffer.
-     */
-    private void allocate(int[] vertices, int[] texcoords, int[] normals,
-        int[] colors) {
-        ByteBuffer vbb =
-            ByteBuffer.allocateDirect(vertices.length * INT_BYTES);
-        vbb.order(ByteOrder.nativeOrder());
-        mVertexBuffer = vbb.asIntBuffer();
-        mVertexBuffer.put(vertices);
-        mVertexBuffer.position(0);
-
-        if ((texcoords != null) && mEmitTextureCoordinates) {
-            ByteBuffer tbb =
-                ByteBuffer.allocateDirect(texcoords.length * INT_BYTES);
-            tbb.order(ByteOrder.nativeOrder());
-            mTexcoordBuffer = tbb.asIntBuffer();
-            mTexcoordBuffer.put(texcoords);
-            mTexcoordBuffer.position(0);
-        }
-
-        if ((normals != null) && mEmitNormals) {
-            ByteBuffer nbb =
-                ByteBuffer.allocateDirect(normals.length * INT_BYTES);
-            nbb.order(ByteOrder.nativeOrder());
-            mNormalBuffer = nbb.asIntBuffer();
-            mNormalBuffer.put(normals);
-            mNormalBuffer.position(0);
-        }
-
-        if ((colors != null) && mEmitColors) {
-            ByteBuffer cbb =
-                ByteBuffer.allocateDirect(colors.length * INT_BYTES);
-            cbb.order(ByteOrder.nativeOrder());
-            mColorBuffer = cbb.asIntBuffer();
-            mColorBuffer.put(colors);
-            mColorBuffer.position(0);
-        }
-    }
-
-    /**
-     * Draws the shape to the given OpenGL ES 1.0 context.  Texture coordinates,
-     * normals, and colors are emitted according the the preferences set for
-     * this shape.
-     */
-    public void draw(GL10 gl) {
-        gl.glVertexPointer(3, GL10.GL_FIXED, 0, mVertexBuffer);
-        gl.glEnableClientState(GL10.GL_VERTEX_ARRAY);
-
-        if (mEmitTextureCoordinates) {
-            gl.glEnableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-            gl.glTexCoordPointer(2, GL10.GL_FIXED, 0, mTexcoordBuffer);
-            gl.glEnable(GL10.GL_TEXTURE_2D);
-        } else {
-            gl.glDisableClientState(GL10.GL_TEXTURE_COORD_ARRAY);
-            gl.glDisable(GL10.GL_TEXTURE_2D);
-        }
-
-        if (mEmitNormals) {
-            gl.glEnableClientState(GL10.GL_NORMAL_ARRAY);
-            gl.glNormalPointer(GL10.GL_FIXED, 0, mNormalBuffer);
-        } else {
-            gl.glDisableClientState(GL10.GL_NORMAL_ARRAY);
-        }
-
-        if (mEmitColors) {
-            gl.glEnableClientState(GL10.GL_COLOR_ARRAY);
-            gl.glColorPointer(4, GL10.GL_FIXED, 0, mColorBuffer);
-        } else {
-            gl.glDisableClientState(GL10.GL_COLOR_ARRAY);
-        }
-
-        gl.glDrawElements(mPrimitive,
-                          mNumIndices > 0 ? mNumIndices : mIndexBuffer.capacity(),
-                          mIndexDatatype,
-                          mIndexBuffer);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/Sphere.java b/samples/GlobalTime/src/com/android/globaltime/Sphere.java
deleted file mode 100644
index 4dff05d..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/Sphere.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import javax.microedition.khronos.opengles.GL10;
-
-public class Sphere extends Shape {
-
-    public Sphere(boolean emitTextureCoordinates,
-        boolean emitNormals, boolean emitColors) {
-        super(GL10.GL_TRIANGLES, GL10.GL_UNSIGNED_SHORT,
-              emitTextureCoordinates, emitNormals, emitColors);
-    }
-}
diff --git a/samples/GlobalTime/src/com/android/globaltime/Texture.java b/samples/GlobalTime/src/com/android/globaltime/Texture.java
deleted file mode 100644
index ee3af00..0000000
--- a/samples/GlobalTime/src/com/android/globaltime/Texture.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.globaltime;
-
-import java.nio.ByteBuffer;
-
-public class Texture {
-
-    private ByteBuffer data;
-    private int width, height;
-
-    public Texture(ByteBuffer data, int width, int height) {
-        this.data = data;
-        this.width = width;
-        this.height = height;
-    }
-
-    public ByteBuffer getData() {
-        return data;
-    }
-
-    public int getWidth() {
-        return width;
-    }
-
-    public int getHeight() {
-        return height;
-    }
-}
diff --git a/samples/HelloActivity/Android.mk b/samples/HelloActivity/Android.mk
deleted file mode 100644
index 7f54bdb..0000000
--- a/samples/HelloActivity/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := HelloActivity
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/HelloActivity/AndroidManifest.xml b/samples/HelloActivity/AndroidManifest.xml
deleted file mode 100644
index 9551e54..0000000
--- a/samples/HelloActivity/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.helloactivity">
-    <application android:label="Hello, Activity!">
-        <activity android:name="HelloActivity">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.LAUNCHER"/>
-            </intent-filter>
-        </activity>
-    </application>
-</manifest>
diff --git a/samples/HelloActivity/res/layout/hello_activity.xml b/samples/HelloActivity/res/layout/hello_activity.xml
deleted file mode 100644
index 2a4d2de..0000000
--- a/samples/HelloActivity/res/layout/hello_activity.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<EditText xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:textSize="18sp"
-    android:autoText="true"
-    android:capitalize="sentences"
-    android:text="@string/hello_activity_text_text" />
-
diff --git a/samples/HelloActivity/res/values/strings.xml b/samples/HelloActivity/res/values/strings.xml
deleted file mode 100644
index 7eab42c..0000000
--- a/samples/HelloActivity/res/values/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-
-    <string name="hello_activity_text_text">Hello, World!</string>
-
-</resources>
diff --git a/samples/HelloActivity/src/com/example/android/helloactivity/HelloActivity.java b/samples/HelloActivity/src/com/example/android/helloactivity/HelloActivity.java
deleted file mode 100644
index 62bf5ca..0000000
--- a/samples/HelloActivity/src/com/example/android/helloactivity/HelloActivity.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.helloactivity;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-
-/**
- * A minimal "Hello, World!" application.
- */
-public class HelloActivity extends Activity {
-    public HelloActivity() {
-    }
-
-    /**
-     * Called with the activity is first created.
-     */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Set the layout for this activity.  You can find it
-        // in res/layout/hello_activity.xml
-        setContentView(R.layout.hello_activity);
-    }
-}
-
diff --git a/samples/HelloActivity/tests/Android.mk b/samples/HelloActivity/tests/Android.mk
deleted file mode 100644
index abd9a8e..0000000
--- a/samples/HelloActivity/tests/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := HelloActivityTests
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_INSTRUMENTATION_FOR := HelloActivity
-
-include $(BUILD_PACKAGE)
diff --git a/samples/HelloActivity/tests/AndroidManifest.xml b/samples/HelloActivity/tests/AndroidManifest.xml
deleted file mode 100644
index 5294d07..0000000
--- a/samples/HelloActivity/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-      package="com.example.android.helloactivity.tests">
-
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-  <instrumentation android:name="android.test.InstrumentationTestRunner"
-      android:targetPackage="com.example.android.helloactivity"
-      android:label="HelloActivity sample tests">
-  </instrumentation>  
-  
-</manifest>
diff --git a/samples/HelloActivity/tests/src/com/example/android/helloactivity/HelloActivityTest.java b/samples/HelloActivity/tests/src/com/example/android/helloactivity/HelloActivityTest.java
deleted file mode 100644
index 6e032da..0000000
--- a/samples/HelloActivity/tests/src/com/example/android/helloactivity/HelloActivityTest.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.helloactivity;
-
-import android.test.ActivityInstrumentationTestCase;
-
-import com.example.android.helloactivity.HelloActivity;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class HelloActivityTest extends ActivityInstrumentationTestCase<HelloActivity> {
-
-  public HelloActivityTest() {
-      super("com.example.android.helloactivity", HelloActivity.class);
-  }
-  
-}
diff --git a/samples/Home/Android.mk b/samples/Home/Android.mk
deleted file mode 100644
index ddc1851..0000000
--- a/samples/Home/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := Home
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
diff --git a/samples/Home/AndroidManifest.xml b/samples/Home/AndroidManifest.xml
deleted file mode 100644
index 229171f..0000000
--- a/samples/Home/AndroidManifest.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/Home/AndroidManifest.xml
-**
-** Copyright 2006, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-		package="com.example.android.home">
-    <uses-permission android:name="android.permission.CALL_PHONE"/>
-    <uses-permission android:name="android.permission.GET_TASKS"/>
-    <uses-permission android:name="android.permission.READ_CONTACTS"/>
-    <uses-permission android:name="android.permission.SET_WALLPAPER" />
-    <uses-permission android:name="android.permission.INTERNET" />
-    <uses-permission android:name="android.permission.EXPAND_STATUS_BAR"/>
-
-    <application android:persistent="true"
-          android:label="@string/home_title"
-          android:icon="@drawable/ic_launcher_home">
-
-        <activity android:name="Home"
-                android:theme="@style/Theme"
-                android:launchMode="singleInstance"
-                android:stateNotNeeded="true">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.HOME"/>
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-        </activity>
-
-        <activity android:name="Wallpaper"
-                android:label="Wallpaper"
-                android:icon="@drawable/bg_android_icon">
-            <intent-filter>
-                <action android:name="android.intent.action.SET_WALLPAPER" />
-                <category android:name="android.intent.category.DEFAULT" />
-            </intent-filter>
-        </activity>
-
-    </application>
-</manifest>
diff --git a/samples/Home/MODULE_LICENSE_APACHE2 b/samples/Home/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/samples/Home/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/samples/Home/NOTICE b/samples/Home/NOTICE
deleted file mode 100644
index c5b1efa..0000000
--- a/samples/Home/NOTICE
+++ /dev/null
@@ -1,190 +0,0 @@
-
-   Copyright (c) 2005-2008, The Android Open Source Project
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
diff --git a/samples/Home/res/anim/fade_in.xml b/samples/Home/res/anim/fade_in.xml
deleted file mode 100644
index fe38ab1..0000000
--- a/samples/Home/res/anim/fade_in.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alpha xmlns:android="http://schemas.android.com/apk/res/android"
-    android:interpolator="@android:anim/accelerate_interpolator"
-    android:fromAlpha="0.0" android:toAlpha="1.0" android:duration="50" />
diff --git a/samples/Home/res/anim/fade_out.xml b/samples/Home/res/anim/fade_out.xml
deleted file mode 100644
index 64ac4f9..0000000
--- a/samples/Home/res/anim/fade_out.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alpha xmlns:android="http://schemas.android.com/apk/res/android"
-    android:interpolator="@android:anim/accelerate_interpolator"
-    android:fromAlpha="1.0" android:toAlpha="0.0" android:duration="50" />
diff --git a/samples/Home/res/anim/grid_entry.xml b/samples/Home/res/anim/grid_entry.xml
deleted file mode 100644
index 330c07d..0000000
--- a/samples/Home/res/anim/grid_entry.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/anim/fade_in.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<set xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:interpolator="@android:anim/decelerate_interpolator">
-    <scale android:fromXScale="0.8" android:toXScale="1.0"
-           android:fromYScale="0.9" android:toYScale="1.0"
-           android:pivotX="100%" android:pivotY="100%" android:duration="200" />
-    <alpha android:fromAlpha="0.5" android:toAlpha="1.0" android:duration="200" />
-</set>
diff --git a/samples/Home/res/anim/grid_exit.xml b/samples/Home/res/anim/grid_exit.xml
deleted file mode 100644
index c9baf2a..0000000
--- a/samples/Home/res/anim/grid_exit.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<alpha xmlns:android="http://schemas.android.com/apk/res/android"
-    android:interpolator="@android:anim/accelerate_interpolator"
-    android:fromAlpha="1.0" android:toAlpha="0.0" android:duration="200" />
diff --git a/samples/Home/res/anim/hide_applications.xml b/samples/Home/res/anim/hide_applications.xml
deleted file mode 100644
index 93039a8..0000000
--- a/samples/Home/res/anim/hide_applications.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gridLayoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:rowDelay="25%"
-        android:directionPriority="column"
-        android:animation="@anim/fade_out" />
diff --git a/samples/Home/res/anim/show_applications.xml b/samples/Home/res/anim/show_applications.xml
deleted file mode 100644
index a97c99c..0000000
--- a/samples/Home/res/anim/show_applications.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<gridLayoutAnimation xmlns:android="http://schemas.android.com/apk/res/android"
-        android:rowDelay="25%"
-        android:directionPriority="column"
-        android:direction="right_to_left|bottom_to_top"
-        android:animation="@anim/fade_in" />
diff --git a/samples/Home/res/color/bright_text_dark_focused.xml b/samples/Home/res/color/bright_text_dark_focused.xml
deleted file mode 100644
index 3b54573..0000000
--- a/samples/Home/res/color/bright_text_dark_focused.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_selected="true" android:color="#000" />
-    <item android:state_focused="true" android:color="#000" />
-    <item android:state_pressed="true" android:color="#000" />
-    <item android:color="#FFF" />
-</selector>
-
diff --git a/samples/Home/res/drawable-land/bg_android.jpg b/samples/Home/res/drawable-land/bg_android.jpg
deleted file mode 100644
index 0bd005f..0000000
--- a/samples/Home/res/drawable-land/bg_android.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-land/bg_android_icon.jpg b/samples/Home/res/drawable-land/bg_android_icon.jpg
deleted file mode 100644
index 2619ef9..0000000
--- a/samples/Home/res/drawable-land/bg_android_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-land/bg_sunrise.jpg b/samples/Home/res/drawable-land/bg_sunrise.jpg
deleted file mode 100644
index aa5a7d1..0000000
--- a/samples/Home/res/drawable-land/bg_sunrise.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-land/bg_sunrise_icon.jpg b/samples/Home/res/drawable-land/bg_sunrise_icon.jpg
deleted file mode 100644
index 4972d8d..0000000
--- a/samples/Home/res/drawable-land/bg_sunrise_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-land/bg_sunset.jpg b/samples/Home/res/drawable-land/bg_sunset.jpg
deleted file mode 100644
index 0fc885b..0000000
--- a/samples/Home/res/drawable-land/bg_sunset.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-land/bg_sunset_icon.jpg b/samples/Home/res/drawable-land/bg_sunset_icon.jpg
deleted file mode 100644
index 939edf7..0000000
--- a/samples/Home/res/drawable-land/bg_sunset_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_android.jpg b/samples/Home/res/drawable-port/bg_android.jpg
deleted file mode 100644
index cbbf3b9..0000000
--- a/samples/Home/res/drawable-port/bg_android.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_android_icon.jpg b/samples/Home/res/drawable-port/bg_android_icon.jpg
deleted file mode 100644
index d5742b6..0000000
--- a/samples/Home/res/drawable-port/bg_android_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_sunrise.jpg b/samples/Home/res/drawable-port/bg_sunrise.jpg
deleted file mode 100644
index a69d5da..0000000
--- a/samples/Home/res/drawable-port/bg_sunrise.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_sunrise_icon.jpg b/samples/Home/res/drawable-port/bg_sunrise_icon.jpg
deleted file mode 100644
index 96968bc..0000000
--- a/samples/Home/res/drawable-port/bg_sunrise_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_sunset.jpg b/samples/Home/res/drawable-port/bg_sunset.jpg
deleted file mode 100644
index 7135bd3..0000000
--- a/samples/Home/res/drawable-port/bg_sunset.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable-port/bg_sunset_icon.jpg b/samples/Home/res/drawable-port/bg_sunset_icon.jpg
deleted file mode 100644
index 4ced6a9..0000000
--- a/samples/Home/res/drawable-port/bg_sunset_icon.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/all_applications.xml b/samples/Home/res/drawable/all_applications.xml
deleted file mode 100644
index 5703c68..0000000
--- a/samples/Home/res/drawable/all_applications.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/drawable/checkbox.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_checked="false" android:drawable="@drawable/ic_launcher_allshow" />
-    <item android:state_checked="true" android:drawable="@drawable/ic_launcher_allhide" />
-</selector>
-
diff --git a/samples/Home/res/drawable/all_applications_background.xml b/samples/Home/res/drawable/all_applications_background.xml
deleted file mode 100644
index 69f5114..0000000
--- a/samples/Home/res/drawable/all_applications_background.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/drawable/checkbox_background.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:drawable="@drawable/all_applications_label_background" />
-</selector>
diff --git a/samples/Home/res/drawable/all_applications_button_background.xml b/samples/Home/res/drawable/all_applications_button_background.xml
deleted file mode 100644
index d7bdbd8..0000000
--- a/samples/Home/res/drawable/all_applications_button_background.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/drawable/checkbox.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_focused="true" android:state_pressed="true" android:drawable="@drawable/pressed_application_background_static" />
-    <item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/pressed_application_background_static" />
-    <item android:state_focused="true" android:drawable="@drawable/focused_application_background_static" />
-    <item android:state_focused="false" android:drawable="@drawable/application_background_static" />
-</selector>
-
diff --git a/samples/Home/res/drawable/all_applications_label_background.9.png b/samples/Home/res/drawable/all_applications_label_background.9.png
deleted file mode 100644
index b1bf466..0000000
--- a/samples/Home/res/drawable/all_applications_label_background.9.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/application_background.9.png b/samples/Home/res/drawable/application_background.9.png
deleted file mode 100644
index 29ae09a..0000000
--- a/samples/Home/res/drawable/application_background.9.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/application_background_static.png b/samples/Home/res/drawable/application_background_static.png
deleted file mode 100644
index 9af6983..0000000
--- a/samples/Home/res/drawable/application_background_static.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/favorite_background.xml b/samples/Home/res/drawable/favorite_background.xml
deleted file mode 100644
index 6d6a69c..0000000
--- a/samples/Home/res/drawable/favorite_background.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/res/drawable/checkbox.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_focused="true" android:state_pressed="true" android:drawable="@drawable/pressed_application_background_static" />
-    <item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/pressed_application_background_static" />
-    <item android:state_focused="true" android:drawable="@drawable/focused_application_background_static" />
-    <item android:state_focused="false" android:drawable="@android:color/transparent" />
-</selector>
diff --git a/samples/Home/res/drawable/focused_application_background_static.png b/samples/Home/res/drawable/focused_application_background_static.png
deleted file mode 100644
index 3a6d47c..0000000
--- a/samples/Home/res/drawable/focused_application_background_static.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/grid_selector.xml b/samples/Home/res/drawable/grid_selector.xml
deleted file mode 100644
index 1116d35..0000000
--- a/samples/Home/res/drawable/grid_selector.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_pressed="true" android:drawable="@drawable/pressed_application_background_static" />
-    <item android:state_window_focused="false" android:drawable="@drawable/focused_application_background_static" />
-    <item android:state_window_focused="true" android:drawable="@drawable/focused_application_background_static" />
-</selector>
diff --git a/samples/Home/res/drawable/hide_all_applications.png b/samples/Home/res/drawable/hide_all_applications.png
deleted file mode 100644
index a67cf78..0000000
--- a/samples/Home/res/drawable/hide_all_applications.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/ic_launcher_allhide.png b/samples/Home/res/drawable/ic_launcher_allhide.png
deleted file mode 100755
index 38e125d..0000000
--- a/samples/Home/res/drawable/ic_launcher_allhide.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/ic_launcher_allshow.png b/samples/Home/res/drawable/ic_launcher_allshow.png
deleted file mode 100755
index 5803d32..0000000
--- a/samples/Home/res/drawable/ic_launcher_allshow.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/ic_launcher_home.png b/samples/Home/res/drawable/ic_launcher_home.png
deleted file mode 100755
index 84af2a2..0000000
--- a/samples/Home/res/drawable/ic_launcher_home.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/pressed_application_background_static.png b/samples/Home/res/drawable/pressed_application_background_static.png
deleted file mode 100644
index b086a3f..0000000
--- a/samples/Home/res/drawable/pressed_application_background_static.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/drawable/show_all_applications.png b/samples/Home/res/drawable/show_all_applications.png
deleted file mode 100644
index ed581e1..0000000
--- a/samples/Home/res/drawable/show_all_applications.png
+++ /dev/null
Binary files differ
diff --git a/samples/Home/res/layout-land/home.xml b/samples/Home/res/layout-land/home.xml
deleted file mode 100644
index d723c69..0000000
--- a/samples/Home/res/layout-land/home.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:home="http://schemas.android.com/apk/res/com.example.android.home"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <!-- All applications on the top side of the screen -->
-    <GridView android:id="@+id/all_apps"
-        android:background="@drawable/application_background"
-        android:persistentDrawingCache="animation|scrolling"
-        android:alwaysDrawnWithCache="true"
-        android:scrollbars="none"
-        android:drawSelectorOnTop="false"
-        android:listSelector="@drawable/grid_selector"
-        android:numColumns="auto_fit"
-        android:columnWidth="78dp"
-        android:stretchMode="spacingWidth"
-        android:layout_weight="1.0"
-        android:layout_height="0dip"
-        android:layout_width="fill_parent"
-        android:stackFromBottom="true"
-        android:visibility="invisible" />
-
-    <!-- Favorites and Recents -->
-    <com.example.android.home.ApplicationsStackLayout android:id="@+id/faves_and_recents"
-        home:stackOrientation="horizontal"
-        home:marginLeft="1dip"
-        home:marginRight="1dip"
-        android:layout_marginTop="0dip"
-        android:layout_width="fill_parent"
-        android:layout_height="65dip"
-        android:background="@drawable/application_background" />
-
-</LinearLayout>
diff --git a/samples/Home/res/layout-port/home.xml b/samples/Home/res/layout-port/home.xml
deleted file mode 100644
index d723c69..0000000
--- a/samples/Home/res/layout-port/home.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:home="http://schemas.android.com/apk/res/com.example.android.home"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-
-    <!-- All applications on the top side of the screen -->
-    <GridView android:id="@+id/all_apps"
-        android:background="@drawable/application_background"
-        android:persistentDrawingCache="animation|scrolling"
-        android:alwaysDrawnWithCache="true"
-        android:scrollbars="none"
-        android:drawSelectorOnTop="false"
-        android:listSelector="@drawable/grid_selector"
-        android:numColumns="auto_fit"
-        android:columnWidth="78dp"
-        android:stretchMode="spacingWidth"
-        android:layout_weight="1.0"
-        android:layout_height="0dip"
-        android:layout_width="fill_parent"
-        android:stackFromBottom="true"
-        android:visibility="invisible" />
-
-    <!-- Favorites and Recents -->
-    <com.example.android.home.ApplicationsStackLayout android:id="@+id/faves_and_recents"
-        home:stackOrientation="horizontal"
-        home:marginLeft="1dip"
-        home:marginRight="1dip"
-        android:layout_marginTop="0dip"
-        android:layout_width="fill_parent"
-        android:layout_height="65dip"
-        android:background="@drawable/application_background" />
-
-</LinearLayout>
diff --git a/samples/Home/res/layout/all_applications_button.xml b/samples/Home/res/layout/all_applications_button.xml
deleted file mode 100644
index 88430b3..0000000
--- a/samples/Home/res/layout/all_applications_button.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/show_all_apps"
-    android:layout_width="78dip"
-    android:layout_height="65dip"
-    android:orientation="vertical"
-    android:gravity="center_vertical"
-    android:clickable="true"
-    android:focusable="true"    
-    android:background="@drawable/all_applications_button_background">
-
-    <CheckBox
-        android:id="@+id/show_all_apps_check"
-        android:focusable="false"
-        android:clickable="false"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        android:background="@drawable/all_applications_background"
-        android:button="@drawable/all_applications"
-        android:text="@string/show_all_apps"
-        android:textSize="12dip"
-        android:maxLines="1"
-        android:duplicateParentState="true"            
-        android:textColor="@color/bright_text_dark_focused"
-        android:gravity="center_horizontal" />
-
-</LinearLayout>
diff --git a/samples/Home/res/layout/application.xml b/samples/Home/res/layout/application.xml
deleted file mode 100644
index 4ddc96e..0000000
--- a/samples/Home/res/layout/application.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/label"
-    android:layout_width="78dip"
-    android:layout_height="65dip"
-    android:paddingTop="4dip"
-    android:textSize="12dip"
-    android:singleLine="true"
-    android:ellipsize="end"
-    android:textColor="@color/bright_text_dark_focused"
-    android:gravity="center_horizontal|center_vertical" />
diff --git a/samples/Home/res/layout/favorite.xml b/samples/Home/res/layout/favorite.xml
deleted file mode 100644
index e100a43..0000000
--- a/samples/Home/res/layout/favorite.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="78dip"
-    android:layout_height="65dip"
-    android:paddingTop="3dip"
-    android:paddingBottom="3dip"
-    android:clickable="true"
-    android:focusable="true"
-    android:background="@drawable/favorite_background"
-    android:textSize="12dip"
-    android:maxLines="1"
-    android:ellipsize="end"
-    android:textColor="@color/bright_text_dark_focused"
-    android:gravity="center_horizontal|bottom" />
diff --git a/samples/Home/res/layout/wallpaper.xml b/samples/Home/res/layout/wallpaper.xml
deleted file mode 100644
index 92dc65e..0000000
--- a/samples/Home/res/layout/wallpaper.xml
+++ /dev/null
@@ -1,46 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/samples/SampleCode/res/layout/image_switcher_1.xml
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"> 
-    
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:padding="5dip"
-        android:background="#70000000"
-        android:text="@string/wallpaper_instructions"
-        android:layout_alignParentTop="true"
-        android:layout_centerHorizontal="true"
-    />
-    
-    <Gallery android:id="@+id/gallery"
-        android:background="#70000000"
-        android:layout_width="fill_parent"
-        android:layout_height="60dip"
-        android:layout_alignParentBottom="true"
-        android:layout_alignParentLeft="true"
-        android:gravity="center_vertical"
-        android:spacing="16dp"
-    />
-
-</RelativeLayout>
-   
diff --git a/samples/Home/res/values-cs/strings.xml b/samples/Home/res/values-cs/strings.xml
deleted file mode 100644
index 2830534..0000000
--- a/samples/Home/res/values-cs/strings.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="home_title">"Domů"</string>
-    <string name="show_all_apps">"Vše"</string>
-    <string name="menu_wallpaper">"Tapeta"</string>
-    <string name="menu_search">"Hledat"</string>
-    <!-- no translation found for menu_settings (1769059051084007158) -->
-    <skip />
-    <string name="wallpaper_instructions">"Klepnutím na obrázek nastavíte tapetu portrétu"</string>
-</resources>
diff --git a/samples/Home/res/values-de-rDE/strings.xml b/samples/Home/res/values-de-rDE/strings.xml
deleted file mode 100644
index 28a1b7c..0000000
--- a/samples/Home/res/values-de-rDE/strings.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="home_title">"Startseite"</string>
-    <string name="show_all_apps">"Alle"</string>
-    <string name="menu_wallpaper">"Bildschirmhintergrund"</string>
-    <string name="menu_search">"Suchen"</string>
-    <!-- no translation found for menu_settings (1769059051084007158) -->
-    <skip />
-    <string name="wallpaper_instructions">"Tippen Sie auf Bild, um Porträt-Bildschirmhintergrund einzustellen"</string>
-</resources>
diff --git a/samples/Home/res/values-es-rUS/strings.xml b/samples/Home/res/values-es-rUS/strings.xml
deleted file mode 100644
index 63252cc..0000000
--- a/samples/Home/res/values-es-rUS/strings.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="home_title">"Casa"</string>
-    <string name="show_all_apps">"Todo"</string>
-    <string name="menu_wallpaper">"Papel tapiz"</string>
-    <string name="menu_search">"Búsqueda"</string>
-    <!-- no translation found for menu_settings (1769059051084007158) -->
-    <skip />
-    <string name="wallpaper_instructions">"Puntee en la imagen para establecer papel tapiz vertical"</string>
-</resources>
diff --git a/samples/Home/res/values-land/strings.xml b/samples/Home/res/values-land/strings.xml
deleted file mode 100644
index a435f41..0000000
--- a/samples/Home/res/values-land/strings.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- Wallpaper -->
-    <string name="wallpaper_instructions">Tap image to set landscape wallpaper</string>
-</resources>
-
diff --git a/samples/Home/res/values-nl-rNL/strings.xml b/samples/Home/res/values-nl-rNL/strings.xml
deleted file mode 100644
index 4a5ae4f..0000000
--- a/samples/Home/res/values-nl-rNL/strings.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="home_title">"Start"</string>
-    <string name="show_all_apps">"Alles"</string>
-    <string name="menu_wallpaper">"Achtergrond"</string>
-    <string name="menu_search">"Zoeken"</string>
-    <!-- no translation found for menu_settings (1769059051084007158) -->
-    <skip />
-    <string name="wallpaper_instructions">"Tik op afbeelding om portretachtergrond in te stellen"</string>
-</resources>
diff --git a/samples/Home/res/values/attrs.xml b/samples/Home/res/values/attrs.xml
deleted file mode 100644
index d14e4fe..0000000
--- a/samples/Home/res/values/attrs.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-
-<resources>
-    <declare-styleable name="ApplicationsStackLayout">
-        <attr name="stackOrientation">
-            <enum name="horizontal" value="0" />
-            <enum name="vertical" value="1" />
-        </attr>
-        <attr name="marginLeft" format="dimension"  />
-        <attr name="marginTop" format="dimension"  />
-        <attr name="marginRight" format="dimension"  />
-        <attr name="marginBottom" format="dimension"  />
-    </declare-styleable>
-</resources>
diff --git a/samples/Home/res/values/strings.xml b/samples/Home/res/values/strings.xml
deleted file mode 100644
index f173434..0000000
--- a/samples/Home/res/values/strings.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <!-- Home -->
-    <string name="home_title">Home Sample</string>
-    <string name="show_all_apps">All</string>
-
-    <!-- Home Menus -->
-    <string name="menu_wallpaper">Wallpaper</string>
-    <string name="menu_search">Search</string>
-    <string name="menu_settings">Settings</string>
-
-    <!-- Wallpaper -->
-    <string name="wallpaper_instructions">Tap picture to set portrait wallpaper</string>
-</resources>
-
diff --git a/samples/Home/res/values/styles.xml b/samples/Home/res/values/styles.xml
deleted file mode 100644
index e87aa58..0000000
--- a/samples/Home/res/values/styles.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<resources>
-    <style name="Theme" parent="android:Theme">
-        <item name="android:windowNoTitle">true</item>		
-    </style>
-</resources>
diff --git a/samples/Home/src/com/example/android/home/ApplicationInfo.java b/samples/Home/src/com/example/android/home/ApplicationInfo.java
deleted file mode 100644
index 79f6234..0000000
--- a/samples/Home/src/com/example/android/home/ApplicationInfo.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.home;
-
-import android.content.ComponentName;
-import android.content.Intent;
-import android.graphics.drawable.Drawable;
-
-/**
- * Represents a launchable application. An application is made of a name (or title), an intent
- * and an icon.
- */
-class ApplicationInfo {
-    /**
-     * The application name.
-     */
-    CharSequence title;
-
-    /**
-     * The intent used to start the application.
-     */
-    Intent intent;
-
-    /**
-     * The application icon.
-     */
-    Drawable icon;
-
-    /**
-     * When set to true, indicates that the icon has been resized.
-     */
-    boolean filtered;
-
-    /**
-     * Creates the application intent based on a component name and various launch flags.
-     *
-     * @param className the class name of the component representing the intent
-     * @param launchFlags the launch flags
-     */
-    final void setActivity(ComponentName className, int launchFlags) {
-        intent = new Intent(Intent.ACTION_MAIN);
-        intent.addCategory(Intent.CATEGORY_LAUNCHER);
-        intent.setComponent(className);
-        intent.setFlags(launchFlags);
-    }
-
-    @Override
-    public boolean equals(Object o) {
-        if (this == o) {
-            return true;
-        }
-        if (!(o instanceof ApplicationInfo)) {
-            return false;
-        }
-
-        ApplicationInfo that = (ApplicationInfo) o;
-        return title.equals(that.title) &&
-                intent.getComponent().getClassName().equals(
-                        that.intent.getComponent().getClassName());
-    }
-
-    @Override
-    public int hashCode() {
-        int result;
-        result = (title != null ? title.hashCode() : 0);
-        final String name = intent.getComponent().getClassName();
-        result = 31 * result + (name != null ? name.hashCode() : 0);
-        return result;
-    }
-}
diff --git a/samples/Home/src/com/example/android/home/ApplicationsStackLayout.java b/samples/Home/src/com/example/android/home/ApplicationsStackLayout.java
deleted file mode 100644
index a2073fa..0000000
--- a/samples/Home/src/com/example/android/home/ApplicationsStackLayout.java
+++ /dev/null
@@ -1,342 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.home;
-
-import android.content.Context;
-import android.content.Intent;
-import android.content.res.TypedArray;
-import android.graphics.Canvas;
-import android.graphics.Rect;
-import android.graphics.drawable.Drawable;
-import android.util.AttributeSet;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.TextView;
-import android.*;
-
-import java.util.List;
-import java.util.Map;
-
-/**
- * The ApplicationsStackLayout is a specialized layout used for the purpose of the home screen
- * only. This layout stacks various icons in three distinct areas: the recents, the favorites
- * (or faves) and the button.
- *
- * This layout supports two different orientations: vertical and horizontal. When horizontal,
- * the areas are laid out this way:
- *
- * [RECENTS][FAVES][BUTTON]
- *
- * When vertical, the layout is the following:
- *
- * [RECENTS]
- * [FAVES]
- * [BUTTON]
- *
- * The layout operates from the "bottom up" (or from right to left.) This means that the button
- * area will first be laid out, then the faves area, then the recents. When there are too many
- * favorites, the recents area is not displayed.
- *
- * The following attributes can be set in XML:
- * 
- * orientation: horizontal or vertical
- * marginLeft: the left margin of each element in the stack
- * marginTop: the top margin of each element in the stack
- * marginRight: the right margin of each element in the stack
- * marginBottom: the bottom margin of each element in the stack
- */
-public class ApplicationsStackLayout extends ViewGroup implements View.OnClickListener {
-    public static final int HORIZONTAL = 0;
-    public static final int VERTICAL = 1;
-
-    private View mButton;
-    private LayoutInflater mInflater;
-
-    private int mFavoritesEnd;
-    private int mFavoritesStart;
-
-    private List<ApplicationInfo> mFavorites;
-    private List<ApplicationInfo> mRecents;
-
-    private int mOrientation = VERTICAL;
-
-    private int mMarginLeft;
-    private int mMarginTop;
-    private int mMarginRight;
-    private int mMarginBottom;
-
-    private Rect mDrawRect = new Rect();
-
-    private Drawable mBackground;
-    private int mIconSize;
-
-    public ApplicationsStackLayout(Context context) {
-        super(context);
-        initLayout();
-    }
-
-    public ApplicationsStackLayout(Context context, AttributeSet attrs) {
-        super(context, attrs);
-
-        TypedArray a =
-                context.obtainStyledAttributes(attrs, R.styleable.ApplicationsStackLayout);
-
-        mOrientation = a.getInt(R.styleable.ApplicationsStackLayout_stackOrientation, VERTICAL);
-
-        mMarginLeft = a.getDimensionPixelSize(R.styleable.ApplicationsStackLayout_marginLeft, 0);
-        mMarginTop = a.getDimensionPixelSize(R.styleable.ApplicationsStackLayout_marginTop, 0);
-        mMarginRight = a.getDimensionPixelSize(R.styleable.ApplicationsStackLayout_marginRight, 0);
-        mMarginBottom = a.getDimensionPixelSize(R.styleable.ApplicationsStackLayout_marginBottom, 0);
-
-        a.recycle();
-
-        mIconSize = (int) getResources().getDimension(android.R.dimen.app_icon_size);
-
-        initLayout();
-    }
-
-    private void initLayout() {
-        mInflater = LayoutInflater.from(getContext());
-        mButton = mInflater.inflate(R.layout.all_applications_button, this, false);
-        addView(mButton);
-
-        mBackground = getBackground();
-        setBackgroundDrawable(null);
-        setWillNotDraw(false);
-    }
-
-    /**
-     * Return the current orientation, either VERTICAL (default) or HORIZONTAL.
-     * 
-     * @return the stack orientation
-     */
-    public int getOrientation() {
-        return mOrientation;
-    }
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-        final Drawable background = mBackground;
-
-        final int right = getWidth();
-        final int bottom = getHeight();
-
-        // Draw behind recents
-        if (mOrientation == VERTICAL) {
-            mDrawRect.set(0, 0, right, mFavoritesStart);
-        } else {
-            mDrawRect.set(0, 0, mFavoritesStart, bottom);
-        }
-        background.setBounds(mDrawRect);
-        background.draw(canvas);
-
-        // Draw behind favorites
-        if (mFavoritesStart > -1) {
-            if (mOrientation == VERTICAL) {
-                mDrawRect.set(0, mFavoritesStart, right, mFavoritesEnd);
-            } else {
-                mDrawRect.set(mFavoritesStart, 0, mFavoritesEnd, bottom);
-            }
-            background.setBounds(mDrawRect);
-            background.draw(canvas);
-        }
-
-        super.onDraw(canvas);
-    }
-
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        super.onMeasure(widthMeasureSpec, heightMeasureSpec);
-
-        final int widthMode = MeasureSpec.getMode(widthMeasureSpec);
-        final int widthSize = MeasureSpec.getSize(widthMeasureSpec);
-
-        final int heightMode = MeasureSpec.getMode(heightMeasureSpec);
-        final int heightSize = MeasureSpec.getSize(heightMeasureSpec);
-
-        if (widthMode != MeasureSpec.EXACTLY || heightMode != MeasureSpec.EXACTLY) {
-            throw new IllegalStateException("ApplicationsStackLayout can only be used with "
-                    + "measure spec mode=EXACTLY");
-        }
-
-        setMeasuredDimension(widthSize, heightSize);
-    }
-
-    @Override
-    protected void onLayout(boolean changed, int l, int t, int r, int b) {
-        removeAllApplications();
-
-        LayoutParams layoutParams = mButton.getLayoutParams();
-        final int widthSpec = MeasureSpec.makeMeasureSpec(layoutParams.width, MeasureSpec.EXACTLY);
-        final int heightSpec = MeasureSpec.makeMeasureSpec(layoutParams.height, MeasureSpec.EXACTLY);
-        mButton.measure(widthSpec, heightSpec);
-
-        if (mOrientation == VERTICAL) {
-            layoutVertical();
-        } else {
-            layoutHorizontal();
-        }
-    }
-
-    private void layoutVertical() {
-        int childLeft = 0;
-        int childTop = getHeight();
-
-        int childWidth = mButton.getMeasuredWidth();
-        int childHeight = mButton.getMeasuredHeight();
-
-        childTop -= childHeight + mMarginBottom;
-        mButton.layout(childLeft, childTop, childLeft + childWidth, childTop + childHeight);
-        childTop -= mMarginTop;
-        mFavoritesEnd = childTop - mMarginBottom;
-
-        int oldChildTop = childTop;
-        childTop = stackApplications(mFavorites, childLeft, childTop);
-        if (childTop != oldChildTop) {
-            mFavoritesStart = childTop + mMarginTop;
-        } else {
-            mFavoritesStart = -1;
-        }
-
-        stackApplications(mRecents, childLeft, childTop);
-    }
-
-    private void layoutHorizontal() {
-        int childLeft = getWidth();
-        int childTop = 0;
-
-        int childWidth = mButton.getMeasuredWidth();
-        int childHeight = mButton.getMeasuredHeight();
-
-        childLeft -= childWidth;
-        mButton.layout(childLeft, childTop, childLeft + childWidth, childTop + childHeight);
-        childLeft -= mMarginLeft;
-        mFavoritesEnd = childLeft - mMarginRight;
-
-        int oldChildLeft = childLeft;
-        childLeft = stackApplications(mFavorites, childLeft, childTop);
-        if (childLeft != oldChildLeft) {
-            mFavoritesStart = childLeft + mMarginLeft;
-        } else {
-            mFavoritesStart = -1;
-        }
-
-        stackApplications(mRecents, childLeft, childTop);
-    }
-
-    private int stackApplications(List<ApplicationInfo> applications, int childLeft, int childTop) {
-        LayoutParams layoutParams;
-        int widthSpec;
-        int heightSpec;
-        int childWidth;
-        int childHeight;
-
-        final boolean isVertical = mOrientation == VERTICAL;
-
-        final int count = applications.size();
-        for (int i = count - 1; i >= 0; i--) {
-            final ApplicationInfo info = applications.get(i);
-            final View view = createApplicationIcon(mInflater, this, info);
-
-            layoutParams = view.getLayoutParams();
-            widthSpec = MeasureSpec.makeMeasureSpec(layoutParams.width, MeasureSpec.EXACTLY);
-            heightSpec = MeasureSpec.makeMeasureSpec(layoutParams.height, MeasureSpec.EXACTLY);
-            view.measure(widthSpec, heightSpec);
-
-            childWidth = view.getMeasuredWidth();
-            childHeight = view.getMeasuredHeight();
-
-            if (isVertical) {
-                childTop -= childHeight + mMarginBottom;
-
-                if (childTop < 0) {
-                    childTop += childHeight + mMarginBottom;
-                    break;
-                }
-            } else {
-                childLeft -= childWidth + mMarginRight;
-
-                if (childLeft < 0) {
-                    childLeft += childWidth + mMarginRight;
-                    break;
-                }
-            }
-
-            addViewInLayout(view, -1, layoutParams);
-
-            view.layout(childLeft, childTop, childLeft + childWidth, childTop + childHeight);
-
-            if (isVertical) {
-                childTop -= mMarginTop;
-            } else {
-                childLeft -= mMarginLeft;
-            }
-        }
-
-        return isVertical ? childTop : childLeft;
-    }
-
-    private void removeAllApplications() {
-        final int count = getChildCount();
-        for (int i = count - 1; i >= 0; i--) {
-            final View view = getChildAt(i);
-            if (view != mButton) {
-                removeViewAt(i);
-            }
-        }
-    }
-
-    private View createApplicationIcon(LayoutInflater inflater,
-            ViewGroup group, ApplicationInfo info) {
-
-        TextView textView = (TextView) inflater.inflate(R.layout.favorite, group, false);
-
-        info.icon.setBounds(0, 0, mIconSize, mIconSize);
-        textView.setCompoundDrawables(null, info.icon, null, null);
-        textView.setText(info.title);
-
-        textView.setTag(info.intent);
-        textView.setOnClickListener(this);
-
-        return textView;
-    }
-
-    /**
-     * Sets the list of favorites.
-     *
-     * @param applications the applications to put in the favorites area
-     */
-    public void setFavorites(List<ApplicationInfo> applications) {
-        mFavorites = applications;
-        requestLayout();
-    }
-
-    /**
-     * Sets the list of recents.
-     *
-     * @param applications the applications to put in the recents area
-     */
-    public void setRecents(List<ApplicationInfo> applications) {
-        mRecents = applications;
-        requestLayout();
-    }
-
-    public void onClick(View v) {
-        getContext().startActivity((Intent) v.getTag());
-    }
-}
diff --git a/samples/Home/src/com/example/android/home/Home.java b/samples/Home/src/com/example/android/home/Home.java
deleted file mode 100644
index de67ef4..0000000
--- a/samples/Home/src/com/example/android/home/Home.java
+++ /dev/null
@@ -1,690 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.home;
-
-import android.app.Activity;
-import android.app.ActivityManager;
-import android.app.SearchManager;
-import android.content.BroadcastReceiver;
-import android.content.ComponentName;
-import android.content.ContentResolver;
-import android.content.Context;
-import android.content.Intent;
-import android.content.IntentFilter;
-import android.content.pm.ActivityInfo;
-import android.content.pm.PackageManager;
-import android.content.pm.ResolveInfo;
-import android.content.res.Resources;
-import android.database.ContentObserver;
-import android.database.Cursor;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.PaintFlagsDrawFilter;
-import android.graphics.PixelFormat;
-import android.graphics.Rect;
-import android.graphics.drawable.BitmapDrawable;
-import android.graphics.drawable.Drawable;
-import android.graphics.drawable.PaintDrawable;
-import android.os.Bundle;
-import android.os.Handler;
-import android.util.Log;
-import android.view.KeyEvent;
-import android.view.LayoutInflater;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.animation.Animation;
-import android.view.animation.AnimationUtils;
-import android.view.animation.LayoutAnimationController;
-import android.widget.AdapterView;
-import android.widget.ArrayAdapter;
-import android.widget.CheckBox;
-import android.widget.GridView;
-import android.widget.TextView;
-import android.net.Uri;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.LinkedList;
-import java.util.List;
-
-public class Home extends Activity {
-    /**
-     * Tag used for logging errors.
-     */
-    private static final String LOG_TAG = "Home";
-
-    /**
-     * Keys during freeze/thaw.
-     */
-    private static final String KEY_SAVE_GRID_OPENED = "grid.opened";
-
-    // Identifiers for option menu items
-    private static final int MENU_WALLPAPER_SETTINGS = Menu.FIRST + 1;
-    private static final int MENU_SEARCH = MENU_WALLPAPER_SETTINGS + 1;
-    private static final int MENU_SETTINGS = MENU_SEARCH + 1;
-
-    /**
-     * Maximum number of recent tasks to query.
-     */
-    private static final int MAX_RECENT_TASKS = 20;
-
-    private static boolean mWallpaperChecked;
-    private static ArrayList<ApplicationInfo> mApplications;
-    private static LinkedList<ApplicationInfo> mFavorites;
-
-    private Handler mHandler = new Handler();
-
-    private final BroadcastReceiver mWallpaperReceiver = new WallpaperIntentReceiver();
-    private final BroadcastReceiver mApplicationsReceiver = new ApplicationsIntentReceiver();
-    private final ContentObserver mObserver = new FavoritesChangeObserver();
-
-    private GridView mGrid;
-
-    private LayoutAnimationController mShowLayoutAnimation;
-    private LayoutAnimationController mHideLayoutAnimation;
-
-    private boolean mBlockAnimation;
-
-    private View mShowApplications;
-    private CheckBox mShowApplicationsCheck;
-
-    private ApplicationsStackLayout mApplicationsStack;
-
-    private Animation mGridEntry;
-    private Animation mGridExit;
-    
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-
-        setDefaultKeyMode(DEFAULT_KEYS_SEARCH_LOCAL);
-
-        setContentView(R.layout.home);
-
-        registerIntentReceivers();
-        registerContentObservers();
-
-        setDefaultWallpaper();
-
-        loadApplications(true);
-
-        bindApplications();
-        bindFavorites(true);
-        bindRecents();
-        bindButtons();
-
-        mGridEntry = AnimationUtils.loadAnimation(this, R.anim.grid_entry);
-        mGridExit = AnimationUtils.loadAnimation(this, R.anim.grid_exit);
-    }
-
-    @Override
-    protected void onNewIntent(Intent intent) {
-        super.onNewIntent(intent);
-
-        // Close the menu
-        if (Intent.ACTION_MAIN.equals(intent.getAction())) {
-            getWindow().closeAllPanels();
-        }
-    }
-
-    @Override
-    public void onDestroy() {
-        super.onDestroy();
-
-        // Remove the callback for the cached drawables or we leak
-        // the previous Home screen on orientation change
-        final int count = mApplications.size();
-        for (int i = 0; i < count; i++) {
-            mApplications.get(i).icon.setCallback(null);
-        }
-
-        getContentResolver().unregisterContentObserver(mObserver);
-        unregisterReceiver(mWallpaperReceiver);
-        unregisterReceiver(mApplicationsReceiver);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        bindRecents();
-    }
-    
-    @Override
-    protected void onRestoreInstanceState(Bundle state) {
-        super.onRestoreInstanceState(state);
-        final boolean opened = state.getBoolean(KEY_SAVE_GRID_OPENED, false);
-        if (opened) {
-            showApplications(false);
-        }
-    }
-
-    @Override
-    protected void onSaveInstanceState(Bundle outState) {
-        super.onSaveInstanceState(outState);
-        outState.putBoolean(KEY_SAVE_GRID_OPENED, mGrid.getVisibility() == View.VISIBLE);
-    }
-
-    /**
-     * Registers various intent receivers. The current implementation registers
-     * only a wallpaper intent receiver to let other applications change the
-     * wallpaper.
-     */
-    private void registerIntentReceivers() {
-        IntentFilter filter = new IntentFilter(Intent.ACTION_WALLPAPER_CHANGED);
-        registerReceiver(mWallpaperReceiver, filter);
-
-        filter = new IntentFilter(Intent.ACTION_PACKAGE_ADDED);
-        filter.addAction(Intent.ACTION_PACKAGE_REMOVED);
-        filter.addAction(Intent.ACTION_PACKAGE_CHANGED);
-        filter.addDataScheme("package");
-        registerReceiver(mApplicationsReceiver, filter);
-    }
-
-    /**
-     * Registers various content observers. The current implementation registers
-     * only a favorites observer to keep track of the favorites applications.
-     */
-    private void registerContentObservers() {
-        ContentResolver resolver = getContentResolver();
-        resolver.registerContentObserver(Uri.parse("content://" +
-                android.provider.Settings.AUTHORITY + "/favorites?notify=true"), true, mObserver);
-    }
-
-    /**
-     * Creates a new appplications adapter for the grid view and registers it.
-     */
-    private void bindApplications() {
-        if (mGrid == null) {
-            mGrid = (GridView) findViewById(R.id.all_apps);
-        }
-        mGrid.setAdapter(new ApplicationsAdapter(this, mApplications));
-        mGrid.setSelection(0);
-
-        if (mApplicationsStack == null) {
-            mApplicationsStack = (ApplicationsStackLayout) findViewById(R.id.faves_and_recents);
-        }
-    }
-
-    /**
-     * Binds actions to the various buttons.
-     */
-    private void bindButtons() {
-        mShowApplications = findViewById(R.id.show_all_apps);
-        mShowApplications.setOnClickListener(new ShowApplications());
-        mShowApplicationsCheck = (CheckBox) findViewById(R.id.show_all_apps_check);
-
-        mGrid.setOnItemClickListener(new ApplicationLauncher());
-    }
-
-    /**
-     * When no wallpaper was manually set, a default wallpaper is used instead.
-     */
-    private void setDefaultWallpaper() {
-        if (!mWallpaperChecked) {
-            Drawable wallpaper = peekWallpaper();
-            if (wallpaper == null) {
-                try {
-                    clearWallpaper();
-                } catch (IOException e) {
-                    Log.e(LOG_TAG, "Failed to clear wallpaper " + e);
-                }
-            } else {
-                getWindow().setBackgroundDrawable(wallpaper);
-            }
-            mWallpaperChecked = true;
-        }
-    }
-
-    /**
-     * Refreshes the favorite applications stacked over the all apps button.
-     * The number of favorites depends on the user.
-     */
-    private void bindFavorites(boolean isLaunching) {
-        if (!isLaunching || mFavorites == null) {
-            final Cursor c = getContentResolver().query(Uri.parse("content://" +
-                android.provider.Settings.AUTHORITY + "/favorites?notify=true"),
-                    null, null, null, "cellX");
-
-            final int intentIndex = c.getColumnIndexOrThrow("intent");
-            final int titleIndex = c.getColumnIndexOrThrow("title");
-            final int typeIndex = c.getColumnIndexOrThrow("itemType");
-
-            final PackageManager manager = getPackageManager();
-
-            ApplicationInfo info;
-            String intentDescription;
-
-            if (mFavorites == null) {
-                mFavorites = new LinkedList<ApplicationInfo>();
-            } else {
-                mFavorites.clear();
-            }
-
-            while (c.moveToNext()) {
-                final int itemType = c.getInt(typeIndex);
-
-                if (itemType == 0 || // 0 == application
-                    itemType == 1) { // 1 == shortcut
-
-                    intentDescription = c.getString(intentIndex);
-                    if (intentDescription == null) {
-                        continue;
-                    }
-
-                    Intent intent;
-                    try {
-                        intent = Intent.getIntent(intentDescription);
-                    } catch (java.net.URISyntaxException e) {
-                        continue;
-                    }
-                    info = getApplicationInfo(manager, intent);
-                    if (info != null) {
-                        info.title = c.getString(titleIndex);
-                        info.intent = intent;
-                        mFavorites.addFirst(info);
-                    }
-                }
-            }
-
-            c.close();
-        }
-
-        mApplicationsStack.setFavorites(mFavorites);
-    }
-
-    /**
-     * Refreshes the recently launched applications stacked over the favorites. The number
-     * of recents depends on how many favorites are present.
-     */
-    private void bindRecents() {
-        final PackageManager manager = getPackageManager();
-        final ActivityManager tasksManager = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
-        final List<ActivityManager.RecentTaskInfo> recentTasks = tasksManager.getRecentTasks(
-                MAX_RECENT_TASKS, 0);
-
-        final int count = recentTasks.size();
-        final ArrayList<ApplicationInfo> recents = new ArrayList<ApplicationInfo>();
-
-        for (int i = count - 1; i >= 0; i--) {
-            final Intent intent = recentTasks.get(i).baseIntent;
-
-            if (Intent.ACTION_MAIN.equals(intent.getAction()) &&
-                    !intent.hasCategory(Intent.CATEGORY_HOME)) {
-
-                ApplicationInfo info = getApplicationInfo(manager, intent);
-                if (info != null) {
-                    info.intent = intent;
-                    if (!mFavorites.contains(info)) {
-                        recents.add(info);
-                    }
-                }
-            }
-        }
-
-        mApplicationsStack.setRecents(recents);
-    }
-
-    private static ApplicationInfo getApplicationInfo(PackageManager manager, Intent intent) {
-        final ResolveInfo resolveInfo = manager.resolveActivity(intent, 0);
-
-        if (resolveInfo == null) {
-            return null;
-        }
-
-        final ApplicationInfo info = new ApplicationInfo();
-        final ActivityInfo activityInfo = resolveInfo.activityInfo;
-        info.icon = activityInfo.loadIcon(manager);
-        if (info.title == null || info.title.length() == 0) {
-            info.title = activityInfo.loadLabel(manager);
-        }
-        if (info.title == null) {
-            info.title = "";
-        }
-        return info;
-    }
-
-    /**
-     * When the notification that favorites have changed is received, requests
-     * a favorites list refresh.
-     */
-    private void onFavoritesChanged() {
-        bindFavorites(false);
-    }
-
-    @Override
-    public boolean dispatchKeyEvent(KeyEvent event) {
-        if (event.getAction() == KeyEvent.ACTION_DOWN) {
-            switch (event.getKeyCode()) {
-                case KeyEvent.KEYCODE_BACK:
-                    return true;
-                case KeyEvent.KEYCODE_HOME:
-                    return true;
-            }
-        }
-
-        return super.dispatchKeyEvent(event);
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        menu.add(0, MENU_WALLPAPER_SETTINGS, 0, R.string.menu_wallpaper)
-                 .setIcon(android.R.drawable.ic_menu_gallery)
-                 .setAlphabeticShortcut('W');
-        menu.add(0, MENU_SEARCH, 0, R.string.menu_search)
-                .setIcon(android.R.drawable.ic_search_category_default)
-                .setAlphabeticShortcut(SearchManager.MENU_KEY);
-        menu.add(0, MENU_SETTINGS, 0, R.string.menu_settings)
-                .setIcon(android.R.drawable.ic_menu_preferences)
-                .setIntent(new Intent(android.provider.Settings.ACTION_SETTINGS));
-
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-            case MENU_WALLPAPER_SETTINGS:
-                startWallpaper();
-                return true;
-            case MENU_SEARCH:
-                onSearchRequested();
-                return true;
-        }
-
-        return super.onOptionsItemSelected(item);
-    }
-
-    private void startWallpaper() {
-        final Intent pickWallpaper = new Intent(Intent.ACTION_SET_WALLPAPER);
-        startActivity(Intent.createChooser(pickWallpaper, getString(R.string.menu_wallpaper)));
-    }
-
-    /**
-     * Loads the list of installed applications in mApplications.
-     */
-    private void loadApplications(boolean isLaunching) {
-        if (isLaunching && mApplications != null) {
-            return;
-        }
-
-        PackageManager manager = getPackageManager();
-
-        Intent mainIntent = new Intent(Intent.ACTION_MAIN, null);
-        mainIntent.addCategory(Intent.CATEGORY_LAUNCHER);
-
-        final List<ResolveInfo> apps = manager.queryIntentActivities(mainIntent, 0);
-        Collections.sort(apps, new ResolveInfo.DisplayNameComparator(manager));
-
-        if (apps != null) {
-            final int count = apps.size();
-
-            if (mApplications == null) {
-                mApplications = new ArrayList<ApplicationInfo>(count);
-            }
-            mApplications.clear();
-
-            for (int i = 0; i < count; i++) {
-                ApplicationInfo application = new ApplicationInfo();
-                ResolveInfo info = apps.get(i);
-
-                application.title = info.loadLabel(manager);
-                application.setActivity(new ComponentName(
-                        info.activityInfo.applicationInfo.packageName,
-                        info.activityInfo.name),
-                        Intent.FLAG_ACTIVITY_NEW_TASK
-                        | Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED);
-                application.icon = info.activityInfo.loadIcon(manager);
-
-                mApplications.add(application);
-            }
-        }
-    }
-
-    /**
-     * Shows all of the applications by playing an animation on the grid.
-     */
-    private void showApplications(boolean animate) {
-        if (mBlockAnimation) {
-            return;
-        }
-        mBlockAnimation = true;
-
-        mShowApplicationsCheck.toggle();
-
-        if (mShowLayoutAnimation == null) {
-            mShowLayoutAnimation = AnimationUtils.loadLayoutAnimation(
-                    this, R.anim.show_applications);
-        }
-
-        // This enables a layout animation; if you uncomment this code, you need to
-        // comment the line mGrid.startAnimation() below
-//        mGrid.setLayoutAnimationListener(new ShowGrid());
-//        mGrid.setLayoutAnimation(mShowLayoutAnimation);
-//        mGrid.startLayoutAnimation();
-
-        if (animate) {
-            mGridEntry.setAnimationListener(new ShowGrid());
-            mGrid.startAnimation(mGridEntry);
-        }
-
-        mGrid.setVisibility(View.VISIBLE);
-
-        if (!animate) {
-            mBlockAnimation = false;
-        }
-
-        // ViewDebug.startHierarchyTracing("Home", mGrid);
-    }
-
-    /**
-     * Hides all of the applications by playing an animation on the grid.
-     */
-    private void hideApplications() {
-        if (mBlockAnimation) {
-            return;
-        }
-        mBlockAnimation = true;
-
-        mShowApplicationsCheck.toggle();
-
-        if (mHideLayoutAnimation == null) {
-            mHideLayoutAnimation = AnimationUtils.loadLayoutAnimation(
-                    this, R.anim.hide_applications);
-        }
-
-        mGridExit.setAnimationListener(new HideGrid());
-        mGrid.startAnimation(mGridExit);
-        mGrid.setVisibility(View.INVISIBLE);
-        mShowApplications.requestFocus();
-
-        // This enables a layout animation; if you uncomment this code, you need to
-        // comment the line mGrid.startAnimation() above
-//        mGrid.setLayoutAnimationListener(new HideGrid());
-//        mGrid.setLayoutAnimation(mHideLayoutAnimation);
-//        mGrid.startLayoutAnimation();
-    }
-
-    /**
-     * Receives intents from other applications to change the wallpaper.
-     */
-    private class WallpaperIntentReceiver extends BroadcastReceiver {
-        @Override
-        public void onReceive(Context context, Intent intent) {
-            getWindow().setBackgroundDrawable(getWallpaper());
-        }
-    }
-
-    /**
-     * Receives notifications when applications are added/removed.
-     */
-    private class ApplicationsIntentReceiver extends BroadcastReceiver {
-        @Override
-        public void onReceive(Context context, Intent intent) {
-            loadApplications(false);
-            bindApplications();
-            bindRecents();
-            bindFavorites(false);
-        }
-    }
-
-    /**
-     * Receives notifications whenever the user favorites have changed.
-     */
-    private class FavoritesChangeObserver extends ContentObserver {
-        public FavoritesChangeObserver() {
-            super(mHandler);
-        }
-
-        @Override
-        public void onChange(boolean selfChange) {
-            onFavoritesChanged();
-        }
-    }
-
-    /**
-     * GridView adapter to show the list of all installed applications.
-     */
-    private class ApplicationsAdapter extends ArrayAdapter<ApplicationInfo> {
-        private Rect mOldBounds = new Rect();
-
-        public ApplicationsAdapter(Context context, ArrayList<ApplicationInfo> apps) {
-            super(context, 0, apps);
-        }
-
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent) {
-            final ApplicationInfo info = mApplications.get(position);
-
-            if (convertView == null) {
-                final LayoutInflater inflater = getLayoutInflater();
-                convertView = inflater.inflate(R.layout.application, parent, false);
-            }
-
-            //final ImageView imageView = (ImageView) convertView.findViewById(R.id.icon);
-            Drawable icon = info.icon;
-
-            if (!info.filtered) {
-                final Resources resources = getContext().getResources();
-                int width = (int) resources.getDimension(android.R.dimen.app_icon_size);
-                int height = (int) resources.getDimension(android.R.dimen.app_icon_size);
-
-                final int iconWidth = icon.getIntrinsicWidth();
-                final int iconHeight = icon.getIntrinsicHeight();
-
-                if (icon instanceof PaintDrawable) {
-                    PaintDrawable painter = (PaintDrawable) icon;
-                    painter.setIntrinsicWidth(width);
-                    painter.setIntrinsicHeight(height);
-                }
-
-                if (width > 0 && height > 0 && (width < iconWidth || height < iconHeight)) {
-                    final float ratio = (float) iconWidth / iconHeight;
-
-                    if (iconWidth > iconHeight) {
-                        height = (int) (width / ratio);
-                    } else if (iconHeight > iconWidth) {
-                        width = (int) (height * ratio);
-                    }
-
-                    final Bitmap.Config c =
-                            icon.getOpacity() != PixelFormat.OPAQUE ?
-                                Bitmap.Config.ARGB_8888 : Bitmap.Config.RGB_565;
-                    final Bitmap thumb = Bitmap.createBitmap(width, height, c);
-                    final Canvas canvas = new Canvas(thumb);
-                    canvas.setDrawFilter(new PaintFlagsDrawFilter(Paint.DITHER_FLAG, 0));
-                    // Copy the old bounds to restore them later
-                    // If we were to do oldBounds = icon.getBounds(),
-                    // the call to setBounds() that follows would
-                    // change the same instance and we would lose the
-                    // old bounds
-                    mOldBounds.set(icon.getBounds());
-                    icon.setBounds(0, 0, width, height);
-                    icon.draw(canvas);
-                    icon.setBounds(mOldBounds);
-                    icon = info.icon = new BitmapDrawable(thumb);
-                    info.filtered = true;
-                }
-            }
-
-            final TextView textView = (TextView) convertView.findViewById(R.id.label);
-            textView.setCompoundDrawablesWithIntrinsicBounds(null, icon, null, null);
-            textView.setText(info.title);
-
-            return convertView;
-        }
-    }
-
-    /**
-     * Shows and hides the applications grid view.
-     */
-    private class ShowApplications implements View.OnClickListener {
-        public void onClick(View v) {
-            if (mGrid.getVisibility() != View.VISIBLE) {
-                showApplications(true);
-            } else {
-                hideApplications();
-            }
-        }
-    }
-
-    /**
-     * Hides the applications grid when the layout animation is over.
-     */
-    private class HideGrid implements Animation.AnimationListener {
-        public void onAnimationStart(Animation animation) {
-        }
-
-        public void onAnimationEnd(Animation animation) {
-            mBlockAnimation = false;
-        }
-
-        public void onAnimationRepeat(Animation animation) {
-        }
-    }
-
-    /**
-     * Shows the applications grid when the layout animation is over.
-     */
-    private class ShowGrid implements Animation.AnimationListener {
-        public void onAnimationStart(Animation animation) {
-        }
-
-        public void onAnimationEnd(Animation animation) {
-            mBlockAnimation = false;
-            // ViewDebug.stopHierarchyTracing();
-        }
-
-        public void onAnimationRepeat(Animation animation) {
-        }
-    }
-
-    /**
-     * Starts the selected activity/application in the grid view.
-     */
-    private class ApplicationLauncher implements AdapterView.OnItemClickListener {
-        public void onItemClick(AdapterView parent, View v, int position, long id) {
-            ApplicationInfo app = (ApplicationInfo) parent.getItemAtPosition(position);
-            startActivity(app.intent);
-        }
-    }
-}
diff --git a/samples/Home/src/com/example/android/home/Wallpaper.java b/samples/Home/src/com/example/android/home/Wallpaper.java
deleted file mode 100644
index 3401c49..0000000
--- a/samples/Home/src/com/example/android/home/Wallpaper.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.home;
-
-import android.app.Activity;
-import android.content.Context;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.MotionEvent;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.Window;
-import android.widget.AdapterView;
-import android.widget.BaseAdapter;
-import android.widget.Gallery;
-import android.widget.ImageView;
-import android.widget.Gallery.LayoutParams;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-/**
- * Wallpaper picker for the Home application. User can choose from
- * a gallery of stock photos.
- */
-public class Wallpaper extends Activity implements
-        AdapterView.OnItemSelectedListener, AdapterView.OnItemClickListener {
-    
-    private static final String LOG_TAG = "Home";
-
-    private static final Integer[] THUMB_IDS = {
-            R.drawable.bg_android_icon,
-            R.drawable.bg_sunrise_icon,
-            R.drawable.bg_sunset_icon,
-    };
-
-    private static final Integer[] IMAGE_IDS = {
-            R.drawable.bg_android,
-            R.drawable.bg_sunrise,
-            R.drawable.bg_sunset,
-    };
-
-    private Gallery mGallery;
-    private boolean mIsWallpaperSet;
-        
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-
-        setContentView(R.layout.wallpaper);
-
-        mGallery = (Gallery) findViewById(R.id.gallery);
-        mGallery.setAdapter(new ImageAdapter(this));
-        mGallery.setOnItemSelectedListener(this);
-        mGallery.setOnItemClickListener(this);
-    }
-    
-    @Override
-    protected void onResume() {
-        super.onResume();
-        mIsWallpaperSet = false;
-    }
-
-    public void onItemSelected(AdapterView parent, View v, int position, long id) {
-        getWindow().setBackgroundDrawableResource(IMAGE_IDS[position]);
-    }
-    
-    public void onItemClick(AdapterView parent, View v, int position, long id) {
-        selectWallpaper(position);
-    }
-
-    /*
-     * When using touch if you tap an image it triggers both the onItemClick and
-     * the onTouchEvent causing the wallpaper to be set twice. Synchronize this
-     * method and ensure we only set the wallpaper once.
-     */
-    private synchronized void selectWallpaper(int position) {
-        if (mIsWallpaperSet) {
-            return;
-        }
-        mIsWallpaperSet = true;
-        try {
-            InputStream stream = getResources().openRawResource(IMAGE_IDS[position]);
-            setWallpaper(stream);
-            setResult(RESULT_OK);
-            finish();
-        } catch (IOException e) {
-            Log.e(LOG_TAG, "Failed to set wallpaper " + e);
-        }
-    }
-
-    public void onNothingSelected(AdapterView parent) {
-    }
-    
-    @Override
-    public boolean onTouchEvent(MotionEvent event) {
-        selectWallpaper(mGallery.getSelectedItemPosition());
-        return true;
-    }
-
-    public class ImageAdapter extends BaseAdapter {
-
-        private Context mContext;
-        
-        public ImageAdapter(Context c) {
-            mContext = c;
-        }
-
-        public int getCount() {
-            return THUMB_IDS.length;
-        }
-
-        public Object getItem(int position) {
-            return position;
-        }
-
-        public long getItemId(int position) {
-            return position;
-        }
-
-        public View getView(final int position, View convertView, ViewGroup parent) {
-            ImageView i = new ImageView(mContext);
-
-            i.setImageResource(THUMB_IDS[position]);
-            i.setAdjustViewBounds(true);
-            i.setLayoutParams(new Gallery.LayoutParams(
-                    LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
-            i.setBackgroundResource(android.R.drawable.picture_frame);
-            return i;
-        }
-
-    }
-
-}
-
-    
diff --git a/samples/LunarLander/Android.mk b/samples/LunarLander/Android.mk
deleted file mode 100644
index 8aa11c8..0000000
--- a/samples/LunarLander/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := LunarLander
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/LunarLander/AndroidManifest.xml b/samples/LunarLander/AndroidManifest.xml
deleted file mode 100644
index 7fdc572..0000000
--- a/samples/LunarLander/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.lunarlander">
-    <application android:icon="@drawable/app_lunar_lander" android:label="@string/app_name">
-        <activity android:name="LunarLander">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-		</activity>
-    </application>
-</manifest>
diff --git a/samples/LunarLander/_index.html b/samples/LunarLander/_index.html
deleted file mode 100644
index 02daeef..0000000
--- a/samples/LunarLander/_index.html
+++ /dev/null
@@ -1,12 +0,0 @@
-<p>A sample game.  Your objective: to land on the moon.
-It demonstrates...
-<ul> 
-<li>loading and drawing resources
-<li>taking keystrokes
-<li>animating by calling invalidate() from draw()
-<li>handling onPause() in an animation
-<li>and many other goodies...
-</ul>
-</p>
-
-<img height="220px" width="320px" alt="Lunar Lander Example" class="gallery"  src="sample_lunarlander.png" >
\ No newline at end of file
diff --git a/samples/LunarLander/res/drawable-land/earthrise.png b/samples/LunarLander/res/drawable-land/earthrise.png
deleted file mode 100644
index e2ecdc5..0000000
--- a/samples/LunarLander/res/drawable-land/earthrise.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/drawable-port/earthrise.png b/samples/LunarLander/res/drawable-port/earthrise.png
deleted file mode 100644
index a13836c..0000000
--- a/samples/LunarLander/res/drawable-port/earthrise.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/drawable/app_lunar_lander.png b/samples/LunarLander/res/drawable/app_lunar_lander.png
deleted file mode 100644
index 7557b8c..0000000
--- a/samples/LunarLander/res/drawable/app_lunar_lander.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/drawable/lander_crashed.png b/samples/LunarLander/res/drawable/lander_crashed.png
deleted file mode 100644
index a73c015..0000000
--- a/samples/LunarLander/res/drawable/lander_crashed.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/drawable/lander_firing.png b/samples/LunarLander/res/drawable/lander_firing.png
deleted file mode 100644
index 91378de..0000000
--- a/samples/LunarLander/res/drawable/lander_firing.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/drawable/lander_plain.png b/samples/LunarLander/res/drawable/lander_plain.png
deleted file mode 100644
index da448e4..0000000
--- a/samples/LunarLander/res/drawable/lander_plain.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/res/layout/lunar_layout.xml b/samples/LunarLander/res/layout/lunar_layout.xml
deleted file mode 100644
index 9ad0536..0000000
--- a/samples/LunarLander/res/layout/lunar_layout.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
-    
-    <com.example.android.lunarlander.LunarView
-      android:id="@+id/lunar"
-      android:layout_width="fill_parent"
-      android:layout_height="fill_parent"/>
-    
-    <RelativeLayout
-        android:layout_width="fill_parent"
-        android:layout_height="fill_parent" >
-        <TextView
-          android:id="@+id/text"
-		  android:text="@string/lunar_layout_text_text"
-		  android:visibility="visible"
-          android:layout_width="wrap_content"
-          android:layout_height="wrap_content"
-          android:layout_centerInParent="true"
-          android:gravity="center_horizontal"
-          android:textColor="#88ffffff"
-          android:textSize="24sp"/>
-     </RelativeLayout>
-         
-</FrameLayout>
diff --git a/samples/LunarLander/res/values/strings.xml b/samples/LunarLander/res/values/strings.xml
deleted file mode 100644
index ac81847..0000000
--- a/samples/LunarLander/res/values/strings.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-	<string name="app_name">Lunar Lander</string>
-	
-    <string name="menu_start">Start</string>
-    <string name="menu_stop">Stop</string>
-    <string name="menu_pause">Pause</string>
-    <string name="menu_resume">Resume</string>
-    <string name="menu_easy">Easy</string>
-    <string name="menu_medium">Medium</string>
-    <string name="menu_hard">Hard</string>
-    
-    <string name="mode_ready">Lunar Lander\nPress Up To Play</string>
-	<string name="mode_pause">Paused\nPress Up To Resume</string>
-	<string name="mode_lose">Game Over\nPress Up To Play</string>
-	<string name="mode_win_prefix">Success!\n</string> 
-	<string name="mode_win_suffix">in a row\nPress Up to Play</string> 
-	
-	<string name="message_stopped">Stopped</string>
-	<string name="message_off_pad">Off Landing Pad</string> 
-	<string name="message_too_fast">Too Fast</string> 
-	<string name="message_bad_angle">Bad Angle</string> 
-
-    <string name="lunar_layout_text_text"></string>
-</resources>
diff --git a/samples/LunarLander/sample_lunarlander.png b/samples/LunarLander/sample_lunarlander.png
deleted file mode 100644
index ea1ef14..0000000
--- a/samples/LunarLander/sample_lunarlander.png
+++ /dev/null
Binary files differ
diff --git a/samples/LunarLander/src/com/example/android/lunarlander/LunarLander.java b/samples/LunarLander/src/com/example/android/lunarlander/LunarLander.java
deleted file mode 100644
index 7f54ff6..0000000
--- a/samples/LunarLander/src/com/example/android/lunarlander/LunarLander.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.lunarlander;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.Window;
-import android.widget.TextView;
-
-import com.example.android.lunarlander.LunarView.LunarThread;
-
-/**
- * This is a simple LunarLander activity that houses a single LunarView. It
- * demonstrates...
- * <ul>
- * <li>animating by calling invalidate() from draw()
- * <li>loading and drawing resources
- * <li>handling onPause() in an animation
- * </ul>
- */
-public class LunarLander extends Activity {
-    private static final int MENU_EASY = 1;
-
-    private static final int MENU_HARD = 2;
-
-    private static final int MENU_MEDIUM = 3;
-
-    private static final int MENU_PAUSE = 4;
-
-    private static final int MENU_RESUME = 5;
-
-    private static final int MENU_START = 6;
-
-    private static final int MENU_STOP = 7;
-
-    /** A handle to the thread that's actually running the animation. */
-    private LunarThread mLunarThread;
-
-    /** A handle to the View in which the game is running. */
-    private LunarView mLunarView;
-
-    /**
-     * Invoked during init to give the Activity a chance to set up its Menu.
-     * 
-     * @param menu the Menu to which entries may be added
-     * @return true
-     */
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        menu.add(0, MENU_START, 0, R.string.menu_start);
-        menu.add(0, MENU_STOP, 0, R.string.menu_stop);
-        menu.add(0, MENU_PAUSE, 0, R.string.menu_pause);
-        menu.add(0, MENU_RESUME, 0, R.string.menu_resume);
-        menu.add(0, MENU_EASY, 0, R.string.menu_easy);
-        menu.add(0, MENU_MEDIUM, 0, R.string.menu_medium);
-        menu.add(0, MENU_HARD, 0, R.string.menu_hard);
-
-        return true;
-    }
-
-    /**
-     * Invoked when the user selects an item from the Menu.
-     * 
-     * @param item the Menu entry which was selected
-     * @return true if the Menu item was legit (and we consumed it), false
-     *         otherwise
-     */
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-            case MENU_START:
-                mLunarThread.doStart();
-                return true;
-            case MENU_STOP:
-                mLunarThread.setState(LunarThread.STATE_LOSE,
-                        getText(R.string.message_stopped));
-                return true;
-            case MENU_PAUSE:
-                mLunarThread.pause();
-                return true;
-            case MENU_RESUME:
-                mLunarThread.unpause();
-                return true;
-            case MENU_EASY:
-                mLunarThread.setDifficulty(LunarThread.DIFFICULTY_EASY);
-                return true;
-            case MENU_MEDIUM:
-                mLunarThread.setDifficulty(LunarThread.DIFFICULTY_MEDIUM);
-                return true;
-            case MENU_HARD:
-                mLunarThread.setDifficulty(LunarThread.DIFFICULTY_HARD);
-                return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * Invoked when the Activity is created.
-     * 
-     * @param savedInstanceState a Bundle containing state saved from a previous
-     *        execution, or null if this is a new execution
-     */
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // turn off the window's title bar
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-
-        // tell system to use the layout defined in our XML file
-        setContentView(R.layout.lunar_layout);
-
-        // get handles to the LunarView from XML, and its LunarThread
-        mLunarView = (LunarView) findViewById(R.id.lunar);
-        mLunarThread = mLunarView.getThread();
-
-        // give the LunarView a handle to the TextView used for messages
-        mLunarView.setTextView((TextView) findViewById(R.id.text));
-
-        if (savedInstanceState == null) {
-            // we were just launched: set up a new game
-            mLunarThread.setState(LunarThread.STATE_READY);
-            Log.w(this.getClass().getName(), "SIS is null");
-        } else {
-            // we are being restored: resume a previous game
-            mLunarThread.restoreState(savedInstanceState);
-            Log.w(this.getClass().getName(), "SIS is nonnull");
-        }
-    }
-
-    /**
-     * Invoked when the Activity loses user focus.
-     */
-    @Override
-    protected void onPause() {
-        super.onPause();
-        mLunarView.getThread().pause(); // pause game when Activity pauses
-    }
-
-    /**
-     * Notification that something is about to happen, to give the Activity a
-     * chance to save state.
-     * 
-     * @param outState a Bundle into which this Activity should save its state
-     */
-    @Override
-    protected void onSaveInstanceState(Bundle outState) {
-        // just have the View's thread save its state into our Bundle
-        super.onSaveInstanceState(outState);
-        mLunarThread.saveState(outState);
-        Log.w(this.getClass().getName(), "SIS called");
-    }
-}
diff --git a/samples/LunarLander/src/com/example/android/lunarlander/LunarView.java b/samples/LunarLander/src/com/example/android/lunarlander/LunarView.java
deleted file mode 100644
index c52c7ab..0000000
--- a/samples/LunarLander/src/com/example/android/lunarlander/LunarView.java
+++ /dev/null
@@ -1,885 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.lunarlander;
-
-import android.content.Context;
-import android.content.res.Resources;
-import android.graphics.Bitmap;
-import android.graphics.BitmapFactory;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.RectF;
-import android.graphics.drawable.Drawable;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
-import android.util.AttributeSet;
-import android.view.KeyEvent;
-import android.view.SurfaceHolder;
-import android.view.SurfaceView;
-import android.view.View;
-import android.widget.TextView;
-
-
-/**
- * View that draws, takes keystrokes, etc. for a simple LunarLander game.
- * 
- * Has a mode which RUNNING, PAUSED, etc. Has a x, y, dx, dy, ... capturing the
- * current ship physics. All x/y etc. are measured with (0,0) at the lower left.
- * updatePhysics() advances the physics based on realtime. draw() renders the
- * ship, and does an invalidate() to prompt another draw() as soon as possible
- * by the system.
- */
-class LunarView extends SurfaceView implements SurfaceHolder.Callback {
-    class LunarThread extends Thread {
-        /*
-         * Difficulty setting constants
-         */
-        public static final int DIFFICULTY_EASY = 0;
-        public static final int DIFFICULTY_HARD = 1;
-        public static final int DIFFICULTY_MEDIUM = 2;
-        /*
-         * Physics constants
-         */
-        public static final int PHYS_DOWN_ACCEL_SEC = 35;
-        public static final int PHYS_FIRE_ACCEL_SEC = 80;
-        public static final int PHYS_FUEL_INIT = 60;
-        public static final int PHYS_FUEL_MAX = 100;
-        public static final int PHYS_FUEL_SEC = 10;
-        public static final int PHYS_SLEW_SEC = 120; // degrees/second rotate
-        public static final int PHYS_SPEED_HYPERSPACE = 180;
-        public static final int PHYS_SPEED_INIT = 30;
-        public static final int PHYS_SPEED_MAX = 120;
-        /*
-         * State-tracking constants
-         */
-        public static final int STATE_LOSE = 1;
-        public static final int STATE_PAUSE = 2;
-        public static final int STATE_READY = 3;
-        public static final int STATE_RUNNING = 4;
-        public static final int STATE_WIN = 5;
-
-        /*
-         * Goal condition constants
-         */
-        public static final int TARGET_ANGLE = 18; // > this angle means crash
-        public static final int TARGET_BOTTOM_PADDING = 17; // px below gear
-        public static final int TARGET_PAD_HEIGHT = 8; // how high above ground
-        public static final int TARGET_SPEED = 28; // > this speed means crash
-        public static final double TARGET_WIDTH = 1.6; // width of target
-        /*
-         * UI constants (i.e. the speed & fuel bars)
-         */
-        public static final int UI_BAR = 100; // width of the bar(s)
-        public static final int UI_BAR_HEIGHT = 10; // height of the bar(s)
-        private static final String KEY_DIFFICULTY = "mDifficulty";
-        private static final String KEY_DX = "mDX";
-
-        private static final String KEY_DY = "mDY";
-        private static final String KEY_FUEL = "mFuel";
-        private static final String KEY_GOAL_ANGLE = "mGoalAngle";
-        private static final String KEY_GOAL_SPEED = "mGoalSpeed";
-        private static final String KEY_GOAL_WIDTH = "mGoalWidth";
-
-        private static final String KEY_GOAL_X = "mGoalX";
-        private static final String KEY_HEADING = "mHeading";
-        private static final String KEY_LANDER_HEIGHT = "mLanderHeight";
-        private static final String KEY_LANDER_WIDTH = "mLanderWidth";
-        private static final String KEY_WINS = "mWinsInARow";
-
-        private static final String KEY_X = "mX";
-        private static final String KEY_Y = "mY";
-
-        /*
-         * Member (state) fields
-         */
-        /** The drawable to use as the background of the animation canvas */
-        private Bitmap mBackgroundImage;
-
-        /**
-         * Current height of the surface/canvas.
-         * 
-         * @see #setSurfaceSize
-         */
-        private int mCanvasHeight = 1;
-
-        /**
-         * Current width of the surface/canvas.
-         * 
-         * @see #setSurfaceSize
-         */
-        private int mCanvasWidth = 1;
-
-        /** What to draw for the Lander when it has crashed */
-        private Drawable mCrashedImage;
-
-        /**
-         * Current difficulty -- amount of fuel, allowed angle, etc. Default is
-         * MEDIUM.
-         */
-        private int mDifficulty;
-
-        /** Velocity dx. */
-        private double mDX;
-
-        /** Velocity dy. */
-        private double mDY;
-
-        /** Is the engine burning? */
-        private boolean mEngineFiring;
-
-        /** What to draw for the Lander when the engine is firing */
-        private Drawable mFiringImage;
-
-        /** Fuel remaining */
-        private double mFuel;
-
-        /** Allowed angle. */
-        private int mGoalAngle;
-
-        /** Allowed speed. */
-        private int mGoalSpeed;
-
-        /** Width of the landing pad. */
-        private int mGoalWidth;
-
-        /** X of the landing pad. */
-        private int mGoalX;
-
-        /** Message handler used by thread to interact with TextView */
-        private Handler mHandler;
-
-        /**
-         * Lander heading in degrees, with 0 up, 90 right. Kept in the range
-         * 0..360.
-         */
-        private double mHeading;
-
-        /** Pixel height of lander image. */
-        private int mLanderHeight;
-
-        /** What to draw for the Lander in its normal state */
-        private Drawable mLanderImage;
-
-        /** Pixel width of lander image. */
-        private int mLanderWidth;
-
-        /** Used to figure out elapsed time between frames */
-        private long mLastTime;
-
-        /** Paint to draw the lines on screen. */
-        private Paint mLinePaint;
-
-        /** "Bad" speed-too-high variant of the line color. */
-        private Paint mLinePaintBad;
-
-        /** The state of the game. One of READY, RUNNING, PAUSE, LOSE, or WIN */
-        private int mMode;
-
-        /** Currently rotating, -1 left, 0 none, 1 right. */
-        private int mRotating;
-
-        /** Indicate whether the surface has been created & is ready to draw */
-        private boolean mRun = false;
-
-        /** Scratch rect object. */
-        private RectF mScratchRect;
-
-        /** Handle to the surface manager object we interact with */
-        private SurfaceHolder mSurfaceHolder;
-
-        /** Number of wins in a row. */
-        private int mWinsInARow;
-
-        /** X of lander center. */
-        private double mX;
-
-        /** Y of lander center. */
-        private double mY;
-
-        public LunarThread(SurfaceHolder surfaceHolder, Context context,
-                Handler handler) {
-            // get handles to some important objects
-            mSurfaceHolder = surfaceHolder;
-            mHandler = handler;
-            mContext = context;
-
-            Resources res = context.getResources();
-            // cache handles to our key sprites & other drawables
-            mLanderImage = context.getResources().getDrawable(
-                    R.drawable.lander_plain);
-            mFiringImage = context.getResources().getDrawable(
-                    R.drawable.lander_firing);
-            mCrashedImage = context.getResources().getDrawable(
-                    R.drawable.lander_crashed);
-
-            // load background image as a Bitmap instead of a Drawable b/c
-            // we don't need to transform it and it's faster to draw this way
-            mBackgroundImage = BitmapFactory.decodeResource(res,
-                    R.drawable.earthrise);
-
-            // Use the regular lander image as the model size for all sprites
-            mLanderWidth = mLanderImage.getIntrinsicWidth();
-            mLanderHeight = mLanderImage.getIntrinsicHeight();
-
-            // Initialize paints for speedometer
-            mLinePaint = new Paint();
-            mLinePaint.setAntiAlias(true);
-            mLinePaint.setARGB(255, 0, 255, 0);
-
-            mLinePaintBad = new Paint();
-            mLinePaintBad.setAntiAlias(true);
-            mLinePaintBad.setARGB(255, 120, 180, 0);
-
-            mScratchRect = new RectF(0, 0, 0, 0);
-
-            mWinsInARow = 0;
-            mDifficulty = DIFFICULTY_MEDIUM;
-
-            // initial show-up of lander (not yet playing)
-            mX = mLanderWidth;
-            mY = mLanderHeight * 2;
-            mFuel = PHYS_FUEL_INIT;
-            mDX = 0;
-            mDY = 0;
-            mHeading = 0;
-            mEngineFiring = true;
-        }
-
-        /**
-         * Starts the game, setting parameters for the current difficulty.
-         */
-        public void doStart() {
-            synchronized (mSurfaceHolder) {
-                // First set the game for Medium difficulty
-                mFuel = PHYS_FUEL_INIT;
-                mEngineFiring = false;
-                mGoalWidth = (int) (mLanderWidth * TARGET_WIDTH);
-                mGoalSpeed = TARGET_SPEED;
-                mGoalAngle = TARGET_ANGLE;
-                int speedInit = PHYS_SPEED_INIT;
-
-                // Adjust difficulty params for EASY/HARD
-                if (mDifficulty == DIFFICULTY_EASY) {
-                    mFuel = mFuel * 3 / 2;
-                    mGoalWidth = mGoalWidth * 4 / 3;
-                    mGoalSpeed = mGoalSpeed * 3 / 2;
-                    mGoalAngle = mGoalAngle * 4 / 3;
-                    speedInit = speedInit * 3 / 4;
-                } else if (mDifficulty == DIFFICULTY_HARD) {
-                    mFuel = mFuel * 7 / 8;
-                    mGoalWidth = mGoalWidth * 3 / 4;
-                    mGoalSpeed = mGoalSpeed * 7 / 8;
-                    speedInit = speedInit * 4 / 3;
-                }
-
-                // pick a convenient initial location for the lander sprite
-                mX = mCanvasWidth / 2;
-                mY = mCanvasHeight - mLanderHeight / 2;
-
-                // start with a little random motion
-                mDY = Math.random() * -speedInit;
-                mDX = Math.random() * 2 * speedInit - speedInit;
-                mHeading = 0;
-
-                // Figure initial spot for landing, not too near center
-                while (true) {
-                    mGoalX = (int) (Math.random() * (mCanvasWidth - mGoalWidth));
-                    if (Math.abs(mGoalX - (mX - mLanderWidth / 2)) > mCanvasHeight / 6)
-                        break;
-                }
-
-                mLastTime = System.currentTimeMillis() + 100;
-                setState(STATE_RUNNING);
-            }
-        }
-
-        /**
-         * Pauses the physics update & animation.
-         */
-        public void pause() {
-            synchronized (mSurfaceHolder) {
-                if (mMode == STATE_RUNNING) setState(STATE_PAUSE);
-            }
-        }
-
-        /**
-         * Restores game state from the indicated Bundle. Typically called when
-         * the Activity is being restored after having been previously
-         * destroyed.
-         * 
-         * @param savedState Bundle containing the game state
-         */
-        public synchronized void restoreState(Bundle savedState) {
-            synchronized (mSurfaceHolder) {
-                setState(STATE_PAUSE);
-                mRotating = 0;
-                mEngineFiring = false;
-
-                mDifficulty = savedState.getInt(KEY_DIFFICULTY);
-                mX = savedState.getDouble(KEY_X);
-                mY = savedState.getDouble(KEY_Y);
-                mDX = savedState.getDouble(KEY_DX);
-                mDY = savedState.getDouble(KEY_DY);
-                mHeading = savedState.getDouble(KEY_HEADING);
-
-                mLanderWidth = savedState.getInt(KEY_LANDER_WIDTH);
-                mLanderHeight = savedState.getInt(KEY_LANDER_HEIGHT);
-                mGoalX = savedState.getInt(KEY_GOAL_X);
-                mGoalSpeed = savedState.getInt(KEY_GOAL_SPEED);
-                mGoalAngle = savedState.getInt(KEY_GOAL_ANGLE);
-                mGoalWidth = savedState.getInt(KEY_GOAL_WIDTH);
-                mWinsInARow = savedState.getInt(KEY_WINS);
-                mFuel = savedState.getDouble(KEY_FUEL);
-            }
-        }
-
-        @Override
-        public void run() {
-            while (mRun) {
-                Canvas c = null;
-                try {
-                    c = mSurfaceHolder.lockCanvas(null);
-                    synchronized (mSurfaceHolder) {
-                        if (mMode == STATE_RUNNING) updatePhysics();
-                        doDraw(c);
-                    }
-                } finally {
-                    // do this in a finally so that if an exception is thrown
-                    // during the above, we don't leave the Surface in an
-                    // inconsistent state
-                    if (c != null) {
-                        mSurfaceHolder.unlockCanvasAndPost(c);
-                    }
-                }
-            }
-        }
-
-        /**
-         * Dump game state to the provided Bundle. Typically called when the
-         * Activity is being suspended.
-         * 
-         * @return Bundle with this view's state
-         */
-        public Bundle saveState(Bundle map) {
-            synchronized (mSurfaceHolder) {
-                if (map != null) {
-                    map.putInt(KEY_DIFFICULTY, Integer.valueOf(mDifficulty));
-                    map.putDouble(KEY_X, Double.valueOf(mX));
-                    map.putDouble(KEY_Y, Double.valueOf(mY));
-                    map.putDouble(KEY_DX, Double.valueOf(mDX));
-                    map.putDouble(KEY_DY, Double.valueOf(mDY));
-                    map.putDouble(KEY_HEADING, Double.valueOf(mHeading));
-                    map.putInt(KEY_LANDER_WIDTH, Integer.valueOf(mLanderWidth));
-                    map.putInt(KEY_LANDER_HEIGHT, Integer
-                            .valueOf(mLanderHeight));
-                    map.putInt(KEY_GOAL_X, Integer.valueOf(mGoalX));
-                    map.putInt(KEY_GOAL_SPEED, Integer.valueOf(mGoalSpeed));
-                    map.putInt(KEY_GOAL_ANGLE, Integer.valueOf(mGoalAngle));
-                    map.putInt(KEY_GOAL_WIDTH, Integer.valueOf(mGoalWidth));
-                    map.putInt(KEY_WINS, Integer.valueOf(mWinsInARow));
-                    map.putDouble(KEY_FUEL, Double.valueOf(mFuel));
-                }
-            }
-            return map;
-        }
-
-        /**
-         * Sets the current difficulty.
-         * 
-         * @param difficulty
-         */
-        public void setDifficulty(int difficulty) {
-            synchronized (mSurfaceHolder) {
-                mDifficulty = difficulty;
-            }
-        }
-
-        /**
-         * Sets if the engine is currently firing.
-         */
-        public void setFiring(boolean firing) {
-            synchronized (mSurfaceHolder) {
-                mEngineFiring = firing;
-            }
-        }
-
-        /**
-         * Used to signal the thread whether it should be running or not.
-         * Passing true allows the thread to run; passing false will shut it
-         * down if it's already running. Calling start() after this was most
-         * recently called with false will result in an immediate shutdown.
-         * 
-         * @param b true to run, false to shut down
-         */
-        public void setRunning(boolean b) {
-            mRun = b;
-        }
-
-        /**
-         * Sets the game mode. That is, whether we are running, paused, in the
-         * failure state, in the victory state, etc.
-         * 
-         * @see #setState(int, CharSequence)
-         * @param mode one of the STATE_* constants
-         */
-        public void setState(int mode) {
-            synchronized (mSurfaceHolder) {
-                setState(mode, null);
-            }
-        }
-
-        /**
-         * Sets the game mode. That is, whether we are running, paused, in the
-         * failure state, in the victory state, etc.
-         * 
-         * @param mode one of the STATE_* constants
-         * @param message string to add to screen or null
-         */
-        public void setState(int mode, CharSequence message) {
-            /*
-             * This method optionally can cause a text message to be displayed
-             * to the user when the mode changes. Since the View that actually
-             * renders that text is part of the main View hierarchy and not
-             * owned by this thread, we can't touch the state of that View.
-             * Instead we use a Message + Handler to relay commands to the main
-             * thread, which updates the user-text View.
-             */
-            synchronized (mSurfaceHolder) {
-                mMode = mode;
-
-                if (mMode == STATE_RUNNING) {
-                    Message msg = mHandler.obtainMessage();
-                    Bundle b = new Bundle();
-                    b.putString("text", "");
-                    b.putInt("viz", View.INVISIBLE);
-                    msg.setData(b);
-                    mHandler.sendMessage(msg);
-                } else {
-                    mRotating = 0;
-                    mEngineFiring = false;
-                    Resources res = mContext.getResources();
-                    CharSequence str = "";
-                    if (mMode == STATE_READY)
-                        str = res.getText(R.string.mode_ready);
-                    else if (mMode == STATE_PAUSE)
-                        str = res.getText(R.string.mode_pause);
-                    else if (mMode == STATE_LOSE)
-                        str = res.getText(R.string.mode_lose);
-                    else if (mMode == STATE_WIN)
-                        str = res.getString(R.string.mode_win_prefix)
-                                + mWinsInARow + " "
-                                + res.getString(R.string.mode_win_suffix);
-
-                    if (message != null) {
-                        str = message + "\n" + str;
-                    }
-
-                    if (mMode == STATE_LOSE) mWinsInARow = 0;
-
-                    Message msg = mHandler.obtainMessage();
-                    Bundle b = new Bundle();
-                    b.putString("text", str.toString());
-                    b.putInt("viz", View.VISIBLE);
-                    msg.setData(b);
-                    mHandler.sendMessage(msg);
-                }
-            }
-        }
-
-        /* Callback invoked when the surface dimensions change. */
-        public void setSurfaceSize(int width, int height) {
-            // synchronized to make sure these all change atomically
-            synchronized (mSurfaceHolder) {
-                mCanvasWidth = width;
-                mCanvasHeight = height;
-
-                // don't forget to resize the background image
-                mBackgroundImage = mBackgroundImage.createScaledBitmap(
-                        mBackgroundImage, width, height, true);
-            }
-        }
-
-        /**
-         * Resumes from a pause.
-         */
-        public void unpause() {
-            // Move the real time clock up to now
-            synchronized (mSurfaceHolder) {
-                mLastTime = System.currentTimeMillis() + 100;
-            }
-            setState(STATE_RUNNING);
-        }
-
-        /**
-         * Handles a key-down event.
-         * 
-         * @param keyCode the key that was pressed
-         * @param msg the original event object
-         * @return true
-         */
-        boolean doKeyDown(int keyCode, KeyEvent msg) {
-            synchronized (mSurfaceHolder) {
-                boolean okStart = false;
-                if (keyCode == KeyEvent.KEYCODE_DPAD_UP) okStart = true;
-                if (keyCode == KeyEvent.KEYCODE_DPAD_DOWN) okStart = true;
-                if (keyCode == KeyEvent.KEYCODE_S) okStart = true;
-
-                boolean center = (keyCode == KeyEvent.KEYCODE_DPAD_UP);
-
-                if (okStart
-                        && (mMode == STATE_READY || mMode == STATE_LOSE || mMode == STATE_WIN)) {
-                    // ready-to-start -> start
-                    doStart();
-                    return true;
-                } else if (mMode == STATE_PAUSE && okStart) {
-                    // paused -> running
-                    unpause();
-                    return true;
-                } else if (mMode == STATE_RUNNING) {
-                    // center/space -> fire
-                    if (keyCode == KeyEvent.KEYCODE_DPAD_CENTER
-                            || keyCode == KeyEvent.KEYCODE_SPACE) {
-                        setFiring(true);
-                        return true;
-                        // left/q -> left
-                    } else if (keyCode == KeyEvent.KEYCODE_DPAD_LEFT
-                            || keyCode == KeyEvent.KEYCODE_Q) {
-                        mRotating = -1;
-                        return true;
-                        // right/w -> right
-                    } else if (keyCode == KeyEvent.KEYCODE_DPAD_RIGHT
-                            || keyCode == KeyEvent.KEYCODE_W) {
-                        mRotating = 1;
-                        return true;
-                        // up -> pause
-                    } else if (keyCode == KeyEvent.KEYCODE_DPAD_UP) {
-                        pause();
-                        return true;
-                    }
-                }
-
-                return false;
-            }
-        }
-
-        /**
-         * Handles a key-up event.
-         * 
-         * @param keyCode the key that was pressed
-         * @param msg the original event object
-         * @return true if the key was handled and consumed, or else false
-         */
-        boolean doKeyUp(int keyCode, KeyEvent msg) {
-            boolean handled = false;
-
-            synchronized (mSurfaceHolder) {
-                if (mMode == STATE_RUNNING) {
-                    if (keyCode == KeyEvent.KEYCODE_DPAD_CENTER
-                            || keyCode == KeyEvent.KEYCODE_SPACE) {
-                        setFiring(false);
-                        handled = true;
-                    } else if (keyCode == KeyEvent.KEYCODE_DPAD_LEFT
-                            || keyCode == KeyEvent.KEYCODE_Q
-                            || keyCode == KeyEvent.KEYCODE_DPAD_RIGHT
-                            || keyCode == KeyEvent.KEYCODE_W) {
-                        mRotating = 0;
-                        handled = true;
-                    }
-                }
-            }
-
-            return handled;
-        }
-
-        /**
-         * Draws the ship, fuel/speed bars, and background to the provided
-         * Canvas.
-         */
-        private void doDraw(Canvas canvas) {
-            // Draw the background image. Operations on the Canvas accumulate
-            // so this is like clearing the screen.
-            canvas.drawBitmap(mBackgroundImage, 0, 0, null);
-
-            int yTop = mCanvasHeight - ((int) mY + mLanderHeight / 2);
-            int xLeft = (int) mX - mLanderWidth / 2;
-
-            // Draw the fuel gauge
-            int fuelWidth = (int) (UI_BAR * mFuel / PHYS_FUEL_MAX);
-            mScratchRect.set(4, 4, 4 + fuelWidth, 4 + UI_BAR_HEIGHT);
-            canvas.drawRect(mScratchRect, mLinePaint);
-
-            // Draw the speed gauge, with a two-tone effect
-            double speed = Math.sqrt(mDX * mDX + mDY * mDY);
-            int speedWidth = (int) (UI_BAR * speed / PHYS_SPEED_MAX);
-
-            if (speed <= mGoalSpeed) {
-                mScratchRect.set(4 + UI_BAR + 4, 4,
-                        4 + UI_BAR + 4 + speedWidth, 4 + UI_BAR_HEIGHT);
-                canvas.drawRect(mScratchRect, mLinePaint);
-            } else {
-                // Draw the bad color in back, with the good color in front of
-                // it
-                mScratchRect.set(4 + UI_BAR + 4, 4,
-                        4 + UI_BAR + 4 + speedWidth, 4 + UI_BAR_HEIGHT);
-                canvas.drawRect(mScratchRect, mLinePaintBad);
-                int goalWidth = (UI_BAR * mGoalSpeed / PHYS_SPEED_MAX);
-                mScratchRect.set(4 + UI_BAR + 4, 4, 4 + UI_BAR + 4 + goalWidth,
-                        4 + UI_BAR_HEIGHT);
-                canvas.drawRect(mScratchRect, mLinePaint);
-            }
-
-            // Draw the landing pad
-            canvas.drawLine(mGoalX, 1 + mCanvasHeight - TARGET_PAD_HEIGHT,
-                    mGoalX + mGoalWidth, 1 + mCanvasHeight - TARGET_PAD_HEIGHT,
-                    mLinePaint);
-
-
-            // Draw the ship with its current rotation
-            canvas.save();
-            canvas.rotate((float) mHeading, (float) mX, mCanvasHeight
-                    - (float) mY);
-            if (mMode == STATE_LOSE) {
-                mCrashedImage.setBounds(xLeft, yTop, xLeft + mLanderWidth, yTop
-                        + mLanderHeight);
-                mCrashedImage.draw(canvas);
-            } else if (mEngineFiring) {
-                mFiringImage.setBounds(xLeft, yTop, xLeft + mLanderWidth, yTop
-                        + mLanderHeight);
-                mFiringImage.draw(canvas);
-            } else {
-                mLanderImage.setBounds(xLeft, yTop, xLeft + mLanderWidth, yTop
-                        + mLanderHeight);
-                mLanderImage.draw(canvas);
-            }
-            canvas.restore();
-        }
-
-        /**
-         * Figures the lander state (x, y, fuel, ...) based on the passage of
-         * realtime. Does not invalidate(). Called at the start of draw().
-         * Detects the end-of-game and sets the UI to the next state.
-         */
-        private void updatePhysics() {
-            long now = System.currentTimeMillis();
-
-            // Do nothing if mLastTime is in the future.
-            // This allows the game-start to delay the start of the physics
-            // by 100ms or whatever.
-            if (mLastTime > now) return;
-
-            double elapsed = (now - mLastTime) / 1000.0;
-
-            // mRotating -- update heading
-            if (mRotating != 0) {
-                mHeading += mRotating * (PHYS_SLEW_SEC * elapsed);
-
-                // Bring things back into the range 0..360
-                if (mHeading < 0)
-                    mHeading += 360;
-                else if (mHeading >= 360) mHeading -= 360;
-            }
-
-            // Base accelerations -- 0 for x, gravity for y
-            double ddx = 0.0;
-            double ddy = -PHYS_DOWN_ACCEL_SEC * elapsed;
-
-            if (mEngineFiring) {
-                // taking 0 as up, 90 as to the right
-                // cos(deg) is ddy component, sin(deg) is ddx component
-                double elapsedFiring = elapsed;
-                double fuelUsed = elapsedFiring * PHYS_FUEL_SEC;
-
-                // tricky case where we run out of fuel partway through the
-                // elapsed
-                if (fuelUsed > mFuel) {
-                    elapsedFiring = mFuel / fuelUsed * elapsed;
-                    fuelUsed = mFuel;
-
-                    // Oddball case where we adjust the "control" from here
-                    mEngineFiring = false;
-                }
-
-                mFuel -= fuelUsed;
-
-                // have this much acceleration from the engine
-                double accel = PHYS_FIRE_ACCEL_SEC * elapsedFiring;
-
-                double radians = 2 * Math.PI * mHeading / 360;
-                ddx = Math.sin(radians) * accel;
-                ddy += Math.cos(radians) * accel;
-            }
-
-            double dxOld = mDX;
-            double dyOld = mDY;
-
-            // figure speeds for the end of the period
-            mDX += ddx;
-            mDY += ddy;
-
-            // figure position based on average speed during the period
-            mX += elapsed * (mDX + dxOld) / 2;
-            mY += elapsed * (mDY + dyOld) / 2;
-
-            mLastTime = now;
-
-            // Evaluate if we have landed ... stop the game
-            double yLowerBound = TARGET_PAD_HEIGHT + mLanderHeight / 2
-                    - TARGET_BOTTOM_PADDING;
-            if (mY <= yLowerBound) {
-                mY = yLowerBound;
-
-                int result = STATE_LOSE;
-                CharSequence message = "";
-                Resources res = mContext.getResources();
-                double speed = Math.sqrt(mDX * mDX + mDY * mDY);
-                boolean onGoal = (mGoalX <= mX - mLanderWidth / 2 && mX
-                        + mLanderWidth / 2 <= mGoalX + mGoalWidth);
-
-                // "Hyperspace" win -- upside down, going fast,
-                // puts you back at the top.
-                if (onGoal && Math.abs(mHeading - 180) < mGoalAngle
-                        && speed > PHYS_SPEED_HYPERSPACE) {
-                    result = STATE_WIN;
-                    mWinsInARow++;
-                    doStart();
-
-                    return;
-                    // Oddball case: this case does a return, all other cases
-                    // fall through to setMode() below.
-                } else if (!onGoal) {
-                    message = res.getText(R.string.message_off_pad);
-                } else if (!(mHeading <= mGoalAngle || mHeading >= 360 - mGoalAngle)) {
-                    message = res.getText(R.string.message_bad_angle);
-                } else if (speed > mGoalSpeed) {
-                    message = res.getText(R.string.message_too_fast);
-                } else {
-                    result = STATE_WIN;
-                    mWinsInARow++;
-                }
-
-                setState(result, message);
-            }
-        }
-    }
-
-    /** Handle to the application context, used to e.g. fetch Drawables. */
-    private Context mContext;
-
-    /** Pointer to the text view to display "Paused.." etc. */
-    private TextView mStatusText;
-
-    /** The thread that actually draws the animation */
-    private LunarThread thread;
-
-    public LunarView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-
-        // register our interest in hearing about changes to our surface
-        SurfaceHolder holder = getHolder();
-        holder.addCallback(this);
-
-        // create thread only; it's started in surfaceCreated()
-        thread = new LunarThread(holder, context, new Handler() {
-            @Override
-            public void handleMessage(Message m) {
-                mStatusText.setVisibility(m.getData().getInt("viz"));
-                mStatusText.setText(m.getData().getString("text"));
-            }
-        });
-
-        setFocusable(true); // make sure we get key events
-    }
-
-    /**
-     * Fetches the animation thread corresponding to this LunarView.
-     * 
-     * @return the animation thread
-     */
-    public LunarThread getThread() {
-        return thread;
-    }
-
-    /**
-     * Standard override to get key-press events.
-     */
-    @Override
-    public boolean onKeyDown(int keyCode, KeyEvent msg) {
-        return thread.doKeyDown(keyCode, msg);
-    }
-
-    /**
-     * Standard override for key-up. We actually care about these, so we can
-     * turn off the engine or stop rotating.
-     */
-    @Override
-    public boolean onKeyUp(int keyCode, KeyEvent msg) {
-        return thread.doKeyUp(keyCode, msg);
-    }
-
-    /**
-     * Standard window-focus override. Notice focus lost so we can pause on
-     * focus lost. e.g. user switches to take a call.
-     */
-    @Override
-    public void onWindowFocusChanged(boolean hasWindowFocus) {
-        if (!hasWindowFocus) thread.pause();
-    }
-
-    /**
-     * Installs a pointer to the text view used for messages.
-     */
-    public void setTextView(TextView textView) {
-        mStatusText = textView;
-    }
-
-    /* Callback invoked when the surface dimensions change. */
-    public void surfaceChanged(SurfaceHolder holder, int format, int width,
-            int height) {
-        thread.setSurfaceSize(width, height);
-    }
-
-    /*
-     * Callback invoked when the Surface has been created and is ready to be
-     * used.
-     */
-    public void surfaceCreated(SurfaceHolder holder) {
-        // start the thread here so that we don't busy-wait in run()
-        // waiting for the surface to be created
-        thread.setRunning(true);
-        thread.start();
-    }
-
-    /*
-     * Callback invoked when the Surface has been destroyed and must no longer
-     * be touched. WARNING: after this method returns, the Surface/Canvas must
-     * never be touched again!
-     */
-    public void surfaceDestroyed(SurfaceHolder holder) {
-        // we have to tell thread to shut down & wait for it to finish, or else
-        // it might touch the Surface after we return and explode
-        boolean retry = true;
-        thread.setRunning(false);
-        while (retry) {
-            try {
-                thread.join();
-                retry = false;
-            } catch (InterruptedException e) {
-            }
-        }
-    }
-}
diff --git a/samples/LunarLander/tests/Android.mk b/samples/LunarLander/tests/Android.mk
deleted file mode 100644
index 60208cf..0000000
--- a/samples/LunarLander/tests/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := LunarLanderTests
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_INSTRUMENTATION_FOR := LunarLander
-
-include $(BUILD_PACKAGE)
diff --git a/samples/LunarLander/tests/AndroidManifest.xml b/samples/LunarLander/tests/AndroidManifest.xml
deleted file mode 100644
index 1bc8364..0000000
--- a/samples/LunarLander/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-      package="com.example.android.lunarlander.tests">
-    
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-  <instrumentation android:name="android.test.InstrumentationTestRunner"
-      android:targetPackage="com.example.android.lunarlander"
-      android:label="LunarLander sample tests">
-  </instrumentation>  
-  
-</manifest>
diff --git a/samples/LunarLander/tests/src/com/example/android/lunarlander/LunarLanderTest.java b/samples/LunarLander/tests/src/com/example/android/lunarlander/LunarLanderTest.java
deleted file mode 100644
index fae02da..0000000
--- a/samples/LunarLander/tests/src/com/example/android/lunarlander/LunarLanderTest.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.lunarlander;
-
-import android.test.ActivityInstrumentationTestCase;
-
-import com.example.android.lunarlander.LunarLander;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class LunarLanderTest extends ActivityInstrumentationTestCase<LunarLander> {
-
-  public LunarLanderTest() {
-      super("com.example.android.lunarlander", LunarLander.class);
-  }
-  
-}
diff --git a/samples/MailSync/res/values/ids.xml b/samples/MailSync/res/values/ids.xml
deleted file mode 100644
index ee736a6..0000000
--- a/samples/MailSync/res/values/ids.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <item type="id" name="from" />
-    <item type="id" name="snippet" />
-    <item type="id" name="subject" />
-</resources>
diff --git a/samples/MySampleRss/Android.mk b/samples/MySampleRss/Android.mk
deleted file mode 100644
index fea9729..0000000
--- a/samples/MySampleRss/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := MyRSSReader
-
-LOCAL_SDK_VERSION := current
-
-##include $(BUILD_PACKAGE)
diff --git a/samples/MySampleRss/AndroidManifest.xml b/samples/MySampleRss/AndroidManifest.xml
deleted file mode 100755
index 575c81e..0000000
--- a/samples/MySampleRss/AndroidManifest.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-          package="com.example.codelab.rssexample">
-    <application android:name="MyRssReader" android:label="My Rss Reader">
-        <activity>
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-        <activity android:name="MyRssReader2" android:label="My Rss Reader V2">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-       </activity>
-       <activity android:name="MyRssReader3" android:label="@string/reader_3_label">
-           <intent-filter>
-               <action android:name="android.intent.action.MAIN" /> 
-               <category android:name="android.intent.category.DEFAULT" />
-               <category android:name="android.intent.category.LAUNCHER" />
-           </intent-filter>
-       </activity>
-       <activity android:name="MyRssReader4" android:label="@string/reader_4_label">
-           <intent-filter>
-               <action android:name="android.intent.action.MAIN" />
-               <category android:name="android.intent.category.DEFAULT" />
-               <category android:name="android.intent.category.LAUNCHER" />
-           </intent-filter>
-       </activity>
-       <activity android:name="MyRssReader5" android:label="@string/reader_5_label">
-           <intent-filter>
-               <action android:name="android.intent.action.MAIN" />
-               <category android:name="android.intent.category.DEFAULT" />
-               <category android:name="android.intent.category.LAUNCHER" />
-           </intent-filter>
-       </activity> 
-       <activity android:name="AddRssItem" android:label="@string/add_item_label" android:theme="@android:style/Theme.Dialog"/>
-       <provider android:name="RssContentProvider" android:authorities="my_rss_item" android:multiprocess="true" />
-       <service android:name="RssService" android:process=":myrss"/>
-    </application>
-</manifest> 
-
-
diff --git a/samples/MySampleRss/res/drawable/rss_icon.PNG b/samples/MySampleRss/res/drawable/rss_icon.PNG
deleted file mode 100755
index 214a38d..0000000
--- a/samples/MySampleRss/res/drawable/rss_icon.PNG
+++ /dev/null
Binary files differ
diff --git a/samples/MySampleRss/res/layout/add_item.xml b/samples/MySampleRss/res/layout/add_item.xml
deleted file mode 100644
index 8191bf5..0000000
--- a/samples/MySampleRss/res/layout/add_item.xml
+++ /dev/null
@@ -1,59 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-                android:layout_height="fill_parent"
-                android:layout_width="fill_parent">
-                
-                <TextView android:id="@+id/title_label"
-                          android:layout_height="wrap_content"
-                          android:layout_width="wrap_content"
-                          android:layout_alignParentTop="true"
-                          android:layout_alignParentLeft="true"
-                          android:text="@string/add_item_title"/>
-                <EditText android:id="@+id/title_textbox"
-                          android:layout_height="wrap_content"
-                          android:layout_width="fill_parent"
-                          android:layout_toRightOf="@id/title_label"/>
-                <EditText android:id="@+id/url_textbox"
-                          android:layout_height="wrap_content"
-                          android:layout_width="fill_parent"
-                          android:layout_below="@id/title_textbox"
-                          android:layout_alignLeft="@id/title_textbox"/>
-                          
-                <!-- Note that we declare url_label *after* url_textbox in this file
-                because it references url_textbox, and a resource file is
-                evaluated sequentially. -->                           
-                <TextView android:id="@+id/url_label"
-                          android:layout_height="wrap_content"
-                          android:layout_width="wrap_content"
-                          android:layout_toRightOf="url_textbox"
-                          android:layout_alignTop="@id/url_textbox"
-                          android:text="@string/add_item_url"/>
-                <Button android:id="@+id/submit"
-                        android:layout_height="wrap_content"
-                        android:layout_width="wrap_content"
-                        android:layout_alignParentRight="true"
-                        android:layout_alignParentBottom="true"
-                        android:text="@string/submit"/>            
-                <Button android:id="@+id/cancel"
-                        android:layout_height="wrap_content"
-                        android:layout_width="wrap_content"
-                        android:layout_toLeftOf="@id/submit"
-                        android:layout_alignTop="@id/submit"
-                        android:text="@string/cancel"/>                         
-</RelativeLayout>
-                
diff --git a/samples/MySampleRss/res/layout/list_element.xml b/samples/MySampleRss/res/layout/list_element.xml
deleted file mode 100644
index 4255d86..0000000
--- a/samples/MySampleRss/res/layout/list_element.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-  <TextView xmlns:android="http://schemas.android.com/apk/res/android"
-            android:id="@+id/list_item"
-            android:layout_height="wrap_content"
-            android:layout_width="wrap_content"/>
diff --git a/samples/MySampleRss/res/layout/main_screen.xml b/samples/MySampleRss/res/layout/main_screen.xml
deleted file mode 100755
index 5292bb2..0000000
--- a/samples/MySampleRss/res/layout/main_screen.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:layout_height="fill_parent"
-              android:layout_width="fill_parent"
-              android:orientation="vertical"
-              android:scrollbars="vertical">
-                  
-        <ListView android:id="@+id/rssListView"
-                  android:layout_height="0px"
-                  android:layout_width="fill_parent"
-                  android:layout_weight="1"
-                  android:background="#00CC00"/>
-                  
-				<WebView android:id="@+id/rssWebView"
-			             android:background="#77CC0000"
-				         android:layout_height="0px"
-				         android:layout_width="fill_parent"
-				         android:layout_weight="1"/>
-
-</LinearLayout>
diff --git a/samples/MySampleRss/res/layout/main_screen2.xml b/samples/MySampleRss/res/layout/main_screen2.xml
deleted file mode 100644
index 36b0af4..0000000
--- a/samples/MySampleRss/res/layout/main_screen2.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:layout_height="fill_parent" 
-              android:layout_width="fill_parent"
-              android:orientation="vertical"
-              android:scrollbars="vertical">
-	                 
-	       <ListView android:id="@+id/rssListView" 
-	                 android:layout_height="0px"
-	                 android:layout_width="fill_parent"
-	                 android:layout_weight="1"
-	                 android:background="#9900FF00"/>
-                  
-				<WebView android:id="@+id/rssWebView"
-				         android:layout_height="0px"
-				         android:layout_width="fill_parent"
-				         android:layout_weight="2"/>
-</LinearLayout>
diff --git a/samples/MySampleRss/res/values/strings.xml b/samples/MySampleRss/res/values/strings.xml
deleted file mode 100644
index 8655995..0000000
--- a/samples/MySampleRss/res/values/strings.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources>
-    <string name="menu_option_start">Start RSS Service</string>
-    <string name="menu_option_stop">Stop RSS Service</string>
-    <string name="menu_option_add">Add New Feed</string>
-    <string name="menu_option_delete">Delete Feed</string>
-    <string name="menu_option_update">Update All Feeds</string>
-    <string name="add_item_title">Title</string>
-    <string name="add_item_url">URL</string>
-    <string name="submit">Submit</string>
-    <string name="cancel">Cancel</string>
-    <string name="reader_3_label">MyRssReader3</string>
-    <string name="reader_4_label">MyRssReader4</string>
-    <string name="reader_5_label">MyRssReader5</string>
-    <string name="add_item_label">Add a new Feed</string>
-</resources>
\ No newline at end of file
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/AddRssItem.java b/samples/MySampleRss/src/com/example/codelab/rssexample/AddRssItem.java
deleted file mode 100644
index 980eec6..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/AddRssItem.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.content.Intent;
-import android.view.View.OnClickListener;
-import android.view.View;
-import android.widget.Button;
-import android.widget.TextView;
-import android.text.TextUtils;
-import android.os.Bundle;
-
-/*** Form to add a new RSS feed.
- It is a dialog form,**/ 
-public class AddRssItem extends Activity {
-    
-    // Button handler for Submit/Cancel.
-    // It is a dialog style form because it's declared as such
-    // in the manifest.
-    private OnClickListener mClickListener = new OnClickListener(){
-        public void onClick(View v){
-            if(v.getId() == R.id.submit){
-                String title = ((TextView) findViewById(R.id.title_textbox)).getText().toString();
-                String url = ((TextView) findViewById(R.id.url_textbox)).getText().toString();
-                if(TextUtils.isEmpty(title) || TextUtils.isEmpty(url)){
-                    showAlert("Missing Values", 
-                              "You must specify both a title and a URL value", 
-                              "OK", 
-                              null, false, null);
-                    return;
-                }
-                Intent res = new Intent("Accepted");
-                res.putExtra(RssContentProvider.TITLE, title);
-                res.putExtra(RssContentProvider.URL, url);
-                res.putExtra(RssContentProvider.LAST_UPDATED, 0);
-                res.putExtra(RssContentProvider.CONTENT, "<html><body><h2>Not updated yet.</h2></body></html>");
-                setResult(RESULT_OK, res);
-            }
-            else
-                setResult(RESULT_CANCELED, (new Intent()).setAction("Canceled" + v.getId()));
-            
-            finish();
-            
-        }
-    };
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState){
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.add_item);
-        setTitle(getString(R.string.add_item_label));
-        
-        Button btn = (Button) findViewById(R.id.cancel);
-        btn.setOnClickListener(mClickListener);
-        
-        btn = (Button) findViewById(R.id.submit);
-        btn.setOnClickListener(mClickListener);       
-    }
-
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader.java b/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader.java
deleted file mode 100644
index d306554..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Menu;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-
-//BEGIN_INCLUDE(1_1)  
-public class MyRssReader extends Activity {
-    /** Called with the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState){
-        super.onCreate(savedInstanceState);
-        
-        // Load screen layout.
-        setContentView(R.layout.main_screen);
-
-//END_INCLUDE(1_1)
-//BEGIN_INCLUDE(1_2)        
-        // Load some simple values into the ListView
-        mRssList = (ListView) findViewById(R.id.rssListView);
-        mRssList.setAdapter(
-                new ArrayAdapter<String>(
-                        this, 
-                        R.layout.list_element, 
-                        new String[] { "Scientific American", "BBC", "The Onion", "Engadget" }));
-//END_INCLUDE(1_2)
-}
-    
-    // Store our state before we are potentially bumped from memory.
-    // We'd like to store the current ListView selection.
-    @Override
-    protected void onSaveInstanceState(Bundle outState){
-        int index = mRssList.getSelectedItemIndex();
-        if(index > -1){
-            outState.putInteger("lastIndexItem", index);
-        }
-    }
-
-    // Add our initial menu options. We will tweak this menu when it's loaded swap out 
-    // "start service" or "stop service", depending on whether the service is currently running.
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu){
-        // Always call the superclass implementation to 
-        // provide standard items.
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, 0, "Start RSS Service", null);
-        menu.add(0, 1, "Stop RSS Service", null);
-        menu.add(0, 2, "Add New Feed", null);
-        menu.add(0, 3, "Delete Feed", null);
-        menu.add(0, 4, "Update All Feeds", null);
-        
-        return true;
-    }  
-     
-    // Toggle out start service/stop service depending on whether the service is running.
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu){
-        return true;
-    }
-    
-    // Handle our menu clicks.
-    @Override
-    public boolean onOptionsItemSelected(Menu.Item item){
-        switch (item.getId()) {
-            case 0:
-                showAlert(null, "You clicked 'start'!", "ok", null, false, null);
-                break;
-            case 1:
-                showAlert(null, "You clicked stop!", "ok", null, false, null);
-                break;
-            case 2:
-                showAlert(null, "You clicked 'Add'!", "ok", null, false, null);
-                break;
-            case 3:
-                showAlert(null, "You clicked 'Delete'!", "ok", null, false, null);
-                break;
-            case 4:
-                showAlert(null, "You clicked 'Update'!", "ok", null, false, null);
-                break;
-            default:
-                showAlert(null, "I have no idea what you clicked!", "ok", null, false, null);
-                break;
-        }
-        return true;
-    }
-
-    ListView mRssList;
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader2.java b/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader2.java
deleted file mode 100644
index 352167a..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader2.java
+++ /dev/null
@@ -1,181 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.content.Context;
-import android.graphics.Typeface;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Logger;
-public class MyRssReader2 extends Activity{
-    private ArrayList<RssItem> mFeeds = null;
-    ListView mRssList = null;
-    private Logger mLogger = Logger.getLogger("com.example.codelab.rssexample");
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState){
-        super.onCreate(savedInstanceState);
-
-        // Load screen layout.
-        setContentView(R.layout.main_screen2);
-        
-       // Populate our list
-        mFeeds = initializeList();
-        mLogger.info("MyRssReader.onCreate-1  mFeeds value:" + mFeeds.size());
-// BEGIN_INCLUDE(2_2)       
-        // Populate ArrayAdapter and bind it to ListView
-        mRssList = (ListView)findViewById(R.id.rssListView);
-        if(mRssList == null){
-            // Note: Calling showAlert() would fail here because dialogs opened
-            // in onCreate won't be displayed properly, if at all.
-            mLogger.warning("MyRssReader.onCreate-2 -- Couldn't instantiate a ListView!");
-        }
-        RssDataAdapter<RssItem> adap = new RssDataAdapter<RssItem>(this, R.layout.add_item, mFeeds);
-        if(adap == null){
-            mLogger.warning("MyRssReader.onCreate-3 -- Couldn't instantiate RssDataAdapter!");
-        }
-        if(mFeeds == null){
-            mLogger.warning("MyRssReader.onCreate-4 -- Couldn't instantiate a ListView!");
-        }
-        mRssList.setAdapter(adap);   
-// END_INCLUDE(2_2)
-       
-        mLogger.info("MyRssReader.onCreate-5 -- Loading preferences.");
-        // Set the last selected item.
-        // (icicle is only set if this is being restarted).
-        if(savedInstanceState != null && savedInstanceState.containsKey("lastIndexItem"))
-        {
-            Integer selectedItem = savedInstanceState.getInteger("lastIndexItem");
-            if(selectedItem >= 0 && selectedItem < mRssList.getChildCount()){
-                mRssList.setSelection(savedInstanceState.getInteger("lastIndexItem"));
-            }
-            mLogger.info("MyRssReader.onCreate-6 -- Last selected item:" + selectedItem);
-        }
-    }
-    
-    // Store our state before we are potentially bumped from memory.
-    // We'd like to store the current ListView selection.
-    @Override
-    protected void onSaveInstanceState(Bundle outState){
-        int index = mRssList.getSelectedItemIndex();
-        if(index > -1){
-            outState.putInteger("lastIndexItem", index);
-        }
-    }
-    
-    
-   
-    // Add our initial menu options. We will tweak this menu when it's loaded swap out 
-    // "start service" or "stop service", depending on whether the service is currently running.
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu){
-        // Always call the superclass implementation to 
-        // provide standard items.
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, 0, "Start RSS Service", null);
-        menu.add(0, 1, "Stop RSS Service", null);
-        menu.add(0, 2, "Add New Feed", null);
-        menu.add(0, 3, "Delete Feed", null);
-        menu.add(0, 4, "Update All Feeds", null);
-        
-        return true;
-    }
-    
-    // Toggle out start service/stop service depending on whether the service is running.
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu){
-        return true;
-    }
-    
-    // Handle our menu clicks.
-    @Override
-    public boolean onOptionsItemSelected(Menu.Item item){
-        switch (item.getId()){
-            case 0:
-              showAlert(null, "You clicked 'start'!", "ok", null, false, null);
-              break;
-            case 1:
-              showAlert(null, "You clicked stop!", "ok", null, false, null);
-              break;
-            case 2:
-                showAlert(null, "You clicked 'Add'!", "ok", null, false, null);
-                break;
-            case 3:
-                showAlert(null, "You clicked 'Delete'!", "ok", null, false, null);
-                break;
-            case 4:
-                showAlert(null, "You clicked 'Update'!", "ok", null, false, null);
-                break;
-            default:
-                showAlert(null, "I have no idea what you clicked!", "ok", null, false, null);
-                break;
-            }
-        return true;
-    }
-    
-    
-    // Our private ArrayAdapter implementation that returns a bold TextView for 
-    // RSS items that are unread, or a normal TextView for items that have been read.
-// BEGIN_INCLUDE(2_3)    
-    private class RssDataAdapter<T> extends ArrayAdapter<T> {
-        public RssDataAdapter(Context context, int resource, List objects) {
-            super(context, resource, objects);
-        }
-// END_INCLUDE(2_3)       
-        // Here's our only important override--returning the list item.
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent){
-            TextView view = null;
-            // Get the item from the underlying array,
-            // Create a TextView wrapper, and change the typeface, if necessary.
-            RssItem item = (RssItem)this.getItem(position);
-            if(item != null)
-            {
-                view = new TextView(parent.getContext());
-                view.setText(item.toString());
-                
-                if(! item.hasBeenRead){
-                    Typeface type = view.getTypeface();
-                    view.setTypeface(Typeface.create(type, Typeface.BOLD_ITALIC));
-                }
-            }
-            return view;    
-        }
-     }
-
-//BEGIN_INCLUDE(2_1) 
-    // Method to initialize our list of RSS items.
-    private ArrayList<RssItem> initializeList(){
-        ArrayList<RssItem> list = new ArrayList<RssItem>();
-        list.add(new RssItem("http://www.sciam.com/xml/sciam.xml", "Scientific American"));
-        list.add(new RssItem("http://newsrss.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml", "BBC"));
-        list.add(new RssItem("http://www.theonion.com/content/feeds/daily.", "The Onion"));
-        list.add(new RssItem("http://feeds.engadget.com/weblogsinc/engadget", "Engadget"));
-        return list;
-    }
-//END_INCLUDE(2_1)     
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader3.java b/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader3.java
deleted file mode 100644
index 1ffe33e..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader3.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.content.Context;
-import android.content.Intent;
-import android.graphics.Typeface;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.ArrayAdapter;
-import android.widget.ListView;
-import android.widget.TextView;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class MyRssReader3 extends Activity{
-
-    private ArrayList<RssItem> mFeeds;
-    ListView mRssList;
-    ArrayAdapter mAdap;
-    private static final int ADD_ELEMENT_REQUEST = 1;
-
-    @Override
-    public void onCreate(Bundle savedInstanceState){
-        super.onCreate(savedInstanceState);
-        
-        // Load screen layout.
-        setContentView(R.layout.main_screen2);
-        
-       // Populate our list
-        mFeeds = initializeList();
-        
-         // Populate ArrayAdapter and bind it to ListView
-        mRssList = (ListView)findViewById(R.id.rssListView);
-        mAdap = new RssDataAdapter<RssItem>(this, R.layout.list_element, mFeeds);
-        mRssList.setAdapter(mAdap);   
-        
-        // Set the last selected item.
-        // (icicle is only set if this is being restarted).
-        if(savedInstanceState != null && savedInstanceState.containsKey("lastIndexItem"))
-            mRssList.setSelection(savedInstanceState.getInteger("lastIndexItem"));
-    }
-    
-    // Store our state before we are potentially bumped from memory.
-    // We'd like to store the current ListView selection.
-    @Override
-    protected void onSaveInstanceState(Bundle outState){
-        int index = mRssList.getSelectedItemIndex();
-        if(index > -1){
-            outState.putInteger("lastIndexItem", index);     
-        }
-    }
-    
-   
-    // Add our initial menu options. We will tweak this menu when it's loaded swap out 
-    // "start service" or "stop service", depending on whether the service is currently running.
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu)
-    {
-        // Always call the superclass implementation to 
-        // provide standard items.
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, 0, R.string.menu_option_start, null);
-        menu.add(0, 1, R.string.menu_option_stop, null);
-        menu.add(0, 2, R.string.menu_option_add, null);
-        menu.add(0, 3, R.string.menu_option_delete, null);
-        menu.add(0, 4, R.string.menu_option_update, null);
-        
-        return true;
-    }
-    
-    // Toggle out start service/stop service depending on whether the service is running.
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu){
-        return true;
-    }
-    
-    // Handle our menu clicks.
-    @Override
-    public boolean onOptionsItemSelected(Menu.Item item){
-        super.onOptionsItemSelected(item);
-        
-        switch (item.getId()){
-            case 0:     // Start service
-                showAlert(null, "You clicked 'start'!", "ok", null, false, null);
-                break;
-            case 1:    // Stop service
-                showAlert(null, "You clicked stop!", "ok", null, false, null);
-                break;
-            case 2:     // Add Item
-                Intent addIntent = new Intent(AddRssItem.class);
-
-                // Use an ID so that if we create a "remove item" form we
-                // can tell which form is returning a value.
-                startActivityForResult(addIntent, ADD_ELEMENT_REQUEST);
-                break;
-            case 3:     // Delete item.
-                if(mRssList.hasFocus()){
-                    Object selectedItem = mRssList.getSelectedItem();
-                    mAdap.removeObject(mRssList.getSelectedItem());
-                }
-                break;
-            case 4:    // Update all
-                showAlert(null, "You clicked 'Update'!", "ok", null, false, null);
-                break;
-            default:
-                showAlert(null, "I have no idea what you clicked!", "ok", null, false, null);
-                break;
-        }
-        return true;
-    }
-    
-    // Called by the "Add RSS Item" floating screen when it closes.
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data){
-        if(resultCode == RESULT_OK){
-            switch (requestCode){
-                case ADD_ELEMENT_REQUEST:
-                    RssItem newIt = new RssItem(
-                            data.getStringExtra("url").toString(), 
-                            data.getStringExtra("title").toString());
-                    mAdap.addObject(newIt);
-                    mRssList.setSelection(mRssList.getCount() - 1);
-                break;
-                default:
-                    break;
-            }
-        }
-    }
-    
-    // Our private ArrayAdapter implementation that returns a bold TextView for 
-    // RSS items that are unread, or a normal TextView for items that have been read.
-    private class RssDataAdapter<T> extends ArrayAdapter<T> {
-        public RssDataAdapter(Context context, int resource, List objects) {
-            super(context, resource, objects);
-        }
-        
-        // Here's our only important override--returning the list item.
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent){
-            
-            // Get the item from the underlying array,
-            // Create a TextView wrapper, and change the typeface, if necessary.
-            RssItem item = (RssItem)this.getItem(position);
-            TextView view = new TextView(parent.getContext());
-            view.setText(item.toString());
-            
-            if(! item.hasBeenRead){
-                Typeface type = view.getTypeface();
-                view.setTypeface(Typeface.create(type, Typeface.BOLD_ITALIC));
-            }
-            return view;
-        }
-    }
-
-    // Method to initialize our list of RSS items.
-    private ArrayList<RssItem> initializeList(){
-      ArrayList<RssItem> list = new ArrayList<RssItem>();
-      list.add(new RssItem("http://www.sciam.com/xml/sciam.xml", "Scientific American"));
-      list.add(new RssItem("http://newsrss.bbc.co.uk/rss/newsonline_world_edition/front_page/rss.xml", "BBC"));
-      list.add(new RssItem("http://feeds.theonion.com/theonion/daily", "The Onion"));
-      list.add(new RssItem("http://feeds.engadget.com/weblogsinc/engadget", "Engadget"));
-      return list;
-    }
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader4.java b/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader4.java
deleted file mode 100644
index bc37786..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader4.java
+++ /dev/null
@@ -1,197 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.Intent;
-import android.graphics.Typeface;
-import android.view.Menu;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.ListView;
-import android.widget.TextView;
-import android.widget.SimpleCursorAdapter;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.Bundle;
-
-
-public class MyRssReader4 extends Activity {
-
-    ListView mRssList;
-    Cursor mCur;
-    RssCursorAdapter mAdap;
-    private static final int ADD_ELEMENT_REQUEST = 1;
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState){
-        super.onCreate(savedInstanceState);
-        
-        // Load screen layout.
-        setContentView(R.layout.main_screen2);
-       
-         // Populate ArrayAdapter and bind it to ListView
-        mRssList = (ListView)findViewById(R.id.rssListView);
-        
-        mCur = managedQuery(RssContentProvider.CONTENT_URI, // Query for all items.
-                            null, 
-                            null, 
-                            RssContentProvider.DEFAULT_SORT_ORDER);
-// BEGIN_INCLUDE(4_1)                           
-        mAdap = new RssCursorAdapter(
-                this,
-                R.layout.list_element,                  // Our layout resource.
-                mCur, 
-                new String[]{RssContentProvider.TITLE}, // Columns to retrieve.
-                new int[]{R.id.list_item});             // IDs of widgets to display
-        mRssList.setAdapter(mAdap);                     //    the corresponding column.
-// END_INCLUDE(4_1)
-        
-        // Set the last selected item.
-        // (icicle is only set if this is being restarted).
-        if(savedInstanceState != null && savedInstanceState.containsKey("lastIndexItem")){
-            mRssList.setSelection(savedInstanceState.getInteger("lastIndexItem"));
-        }
-    }
-   
-    // Store our state before we are potentially bumped from memory.
-    // We'd like to store the current ListView selection.
-    @Override
-    protected void onSaveInstanceState(Bundle outState){
-        int index = mRssList.getSelectedItemIndex();
-        if(index > -1){
-            outState.putInteger("lastIndexItem", index);
-        }
-    }
-    
-    
-    // Add our initial menu options. We will tweak this menu when it's loaded swap out 
-    // "start service" or "stop service", depending on whether the service is currently running.
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu){
-        // Always call the superclass implementation to 
-        // provide standard items.
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, 0, R.string.menu_option_start, null);
-        menu.add(0, 1, R.string.menu_option_stop, null);
-        menu.add(0, 2, R.string.menu_option_add, null);
-        menu.add(0, 3, R.string.menu_option_delete, null);
-        menu.add(0, 4, R.string.menu_option_update, null);
-        
-        return true;
-    }
-    
-    // Toggle out start service/stop service depending on whether the service is running.
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu){
-        return true;
-    }
-    
-    // Handle our menu clicks.
-    @Override
-    public boolean onOptionsItemSelected(Menu.Item item){
-        super.onOptionsItemSelected(item);
-        
-        switch (item.getId()){
-            case 0:     // Start service
-                showAlert(null, "You clicked 'start'!", "ok", null, false, null);
-                break;
-            case 1:    // Stop service
-              showAlert(null, "You clicked stop!", "ok", null, false, null);
-              break;                    
-            case 2:     // Add Item
-                Intent addIntent = new Intent(AddRssItem.class);
-
-                // Use an ID so that if we create a "remove item" form we
-                // can tell which form is returning a value.
-                startActivityForResult(addIntent, ADD_ELEMENT_REQUEST); 
-                break; 
-            case 3:     // Delete item.
-                if(mRssList.hasFocus()){
-                  int currentSelectionIndex = mRssList.getSelectedItemIndex();
-
-                  // Create our content URI by adding the ID of the currently selected item using a 
-                  // convenience method.
-                  Long itemID = mAdap.getItemId(currentSelectionIndex);
-                  getContentResolver().delete(RssContentProvider.CONTENT_URI.addId(itemID), null);
-                }
-                break;
-            case 4:    // Update all
-                showAlert(null, "You clicked 'Update'!", "ok", null, false, null);
-                break;
-            default:
-                showAlert(null, "I have no idea what you clicked!", "ok", null, false, null);
-                break;
-        }
-        return true;
-    }
-    
-    // Called by the "Add RSS Item" floating screen when it closes.
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data){
-        if(resultCode == RESULT_OK){
-            switch (requestCode){
-                case ADD_ELEMENT_REQUEST:
-                    ContentValues vals = new ContentValues(4);
-                    vals.put(RssContentProvider.TITLE, data.getStringExtra(RssContentProvider.TITLE));
-                    vals.put(RssContentProvider.URL, data.getStringExtra(RssContentProvider.URL));
-                    vals.put(RssContentProvider.CONTENT, data.getStringExtra(RssContentProvider.CONTENT));
-                    vals.put(RssContentProvider.LAST_UPDATED, data.getIntExtra(RssContentProvider.LAST_UPDATED, 0));
-                    Uri uri = getContentResolver().insert(
-                            RssContentProvider.CONTENT_URI, 
-                            vals);
-                        if(uri != null){
-                            mRssList.setSelection(mRssList.getCount() - 1);
-                        }
-                    break;
-                default:
-                    break;
-            }
-        }
-    }
-    
-    // Our private ArrayAdapter implementation that returns a bold TextView for 
-    // RSS items that are unread, or a normal TextView for items that have been read.
-    private class RssCursorAdapter extends SimpleCursorAdapter {
-        public RssCursorAdapter(Context context, int layout, Cursor c, String[] from, int[] to){
-            super(context, layout, c, from, to);
-        }
-        
-        // Here's our only important override--returning the list item.
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent){
-            TextView view = (TextView)super.getView(position, convertView, parent);
-            
-            if(view != null){
-                
-                // Now get the hasBeenRead value to determine the font.
-                int hasBeenReadColumnIndex = getCursor().getColumnIndex(
-                        RssContentProvider.HAS_BEEN_READ);
-                boolean hasBeenRead = (getCursor().getInt(hasBeenReadColumnIndex) == 1 ? true : false);
-                if(! hasBeenRead){
-                    Typeface type = view.getTypeface();
-                    view.setTypeface(Typeface.create(type, Typeface.BOLD_ITALIC));
-                }
-            }
-            return view;
-        } 
-    }
-}
-
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader5.java b/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader5.java
deleted file mode 100644
index 0d59bfd..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/MyRssReader5.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Activity;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.Intent;
-import android.database.Cursor;
-import android.graphics.Typeface;
-import android.net.Uri;
-import android.os.Bundle;
-import android.view.Menu;
-import android.view.View;
-import android.view.ViewGroup;
-import android.webkit.WebView;
-import android.widget.AdapterView;
-import android.widget.ListView;
-import android.widget.SimpleCursorAdapter;
-import android.widget.TextView;
-import android.widget.AdapterView.OnItemSelectedListener;
-
-import java.util.logging.Logger;
-
-public class MyRssReader5 extends Activity implements OnItemSelectedListener {
-    
-    private ListView mRssList;
-    private Cursor mCur;
-    private RssCursorAdapter mAdap;
-    private WebView mWebView;
-    private static final int ADD_ELEMENT_REQUEST = 1;
-    private Logger mLogger = Logger.getLogger(this.getPackageName());
-    
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-                                                                                                    //
-        // Load screen layout.
-        setContentView(R.layout.main_screen2);
-       
-        // Populate ArrayAdapter and bind it to ListView
-        mRssList = (ListView)findViewById(R.id.rssListView);
-        mRssList.setOnItemSelectedListener(this);
-        
-        mWebView = (WebView)findViewById(R.id.rssWebView);
-        
-        mCur = managedQuery(RssContentProvider.CONTENT_URI, // Query for all items.
-                       null, 
-                       null, 
-                       RssContentProvider.DEFAULT_SORT_ORDER);
-               
-        mAdap = new RssCursorAdapter(
-                this,
-                R.layout.list_element,                  // Our layout resource.
-                mCur, 
-                new String[]{RssContentProvider.TITLE}, // Columns to retrieve.
-                new int[]{R.id.list_item});             // IDs of widgets to display 
-        mRssList.setAdapter(mAdap);                    //      the corresponding column.
-        
-        // Set the last selected item.
-        // (icicle is only set if this is being restarted).
-        if(savedInstanceState != null && savedInstanceState.containsKey("lastIndexItem")){
-            mRssList.setSelection(savedInstanceState.getInteger("lastIndexItem"));
-        }
-    }
-
-//BEGIN_INCLUDE(5_4)
-    // Listener to listen for list selection changes, and send the new text to
-    // the web view.
-    public void onItemSelected(AdapterView parent, View v, int position, long id){
-        // Need to nest this in a try block because we get called sometimes
-        // with the index of a recently deleted item.
-        String content = "";
-        try{
-            content = mCur.getString(mCur.getColumnIndex(RssContentProvider.CONTENT));
-            mLogger.info("MyRssReader5 content string:" + content);
-        }
-        catch (Exception e){
-            // This method is sometimes called after a backing data item
-            // is deleted. In that case, we don't want to throw an error.
-            mLogger.warning("MyRssReader5.onItemSelected() couldn't get the content" +
-                            "from the cursor " + e.getMessage()); 
-        }
-        mWebView.loadData(content, "text/html", "utf-8");
-    }
-//END_INCLUDE(5_4)
-    
-    public void onNothingSelected(AdapterView parent){
-        mWebView.loadData("<html><body><p>No selection chosen</p></body></html>", "text/html", "utf-8");   
-    }
-   
-    // Store our state before we are potentially bumped from memory.
-    // We'd like to store the current ListView selection.
-    @Override
-    protected void onSaveInstanceState(Bundle outState){
-        int index = mRssList.getSelectedItemIndex();
-        if(index > -1){
-            outState.putInteger("lastIndexItem", index);
-        }
-    }
-  
-    // Add our initial menu options. We will tweak this menu when it's loaded swap out 
-    // "start service" or "stop service", depending on whether the service is currently running.
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu){
-        // Always call the superclass implementation to 
-        // provide standard items.
-        super.onCreateOptionsMenu(menu);
-        
-        menu.add(0, 0, R.string.menu_option_start, null);
-        menu.add(0, 1, R.string.menu_option_stop, null);
-        menu.add(0, 2, R.string.menu_option_add, null);
-        menu.add(0, 3, R.string.menu_option_delete, null);
-        menu.add(0, 4, R.string.menu_option_update, null);
-        
-        return true;
-    }
-    
-    // Toggle out start service/stop service depending on whether the service is running.
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu){
-        return true;
-    }
-    
-    // Handle our menu clicks.
-    @Override
-    public boolean onOptionsItemSelected(Menu.Item item){
-        super.onOptionsItemSelected(item);
-        
-        switch (item.getId()){
-            case 0:     // Start service
-                Intent basicStartIntent = new Intent(RssService.class);
-                startService(basicStartIntent);
-                break;
-            case 1:    // Stop service
-                Intent stopIntent = new Intent(RssService.class);
-                stopService(stopIntent);
-                break;
-            case 2:     // Add Item
-                Intent addIntent = new Intent(AddRssItem.class);
-                // Use an ID so that if we create a "remove item" form we
-                // can tell which form is returning a value.
-                startActivityForResult(addIntent, ADD_ELEMENT_REQUEST); 
-                break;                       
-            case 3:     // Delete item.
-                if(mRssList.hasFocus()){
-                    int currentSelectionIndex = mRssList.getSelectedItemIndex();
-                    mLogger.info("MyRssReader5.onOptionsItemSelected(): Deleting list member:" + 
-                            mRssList.getSelectedItemIndex());
-                    // Create our content URI by adding the ID of the currently selected item using a 
-                    // convenience method.
-                    Long itemID = mAdap.getItemId(currentSelectionIndex);
-                    getContentResolver().delete(RssContentProvider.CONTENT_URI.addId(itemID), null);
-                }
-                break;
-            case 4:     // Requery all
-                Bundle startupVals = new Bundle(1);
-                startupVals.putBoolean(RssService.REQUERY_KEY, true);
-                Intent requeryIntent = new Intent(RssService.class);
-                startService(requeryIntent, startupVals);
-                break;
-            default:
-                showAlert(null, "I have no idea what you clicked!", "ok", null, false, null);
-                break;
-        }
-        return true;
-    }
-    
-    // Called by the "Add RSS Item" floating screen when it closes.
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data){
-        if(resultCode == RESULT_OK){
-            switch (requestCode){
-                case ADD_ELEMENT_REQUEST:
-                      ContentValues vals = new ContentValues(5);
-                      vals.put(RssContentProvider.TITLE, data.getStringExtra(RssContentProvider.TITLE));
-                      vals.put(RssContentProvider.URL, data.getStringExtra(RssContentProvider.URL));
-                      vals.put(RssContentProvider.CONTENT, data.getStringExtra(RssContentProvider.CONTENT));
-                      vals.put(RssContentProvider.LAST_UPDATED, data.getIntExtra(RssContentProvider.LAST_UPDATED, 0));
-                      Uri uri = getContentResolver().insert(
-                              RssContentProvider.CONTENT_URI, 
-                              vals);
-                      if(uri != null){
-                          // Tell the service to requery the service, then set
-                          // it as the active selection.
-                          Bundle startupVals = new Bundle(1);
-                          startupVals.putString(RssService.RSS_URL, data.getStringExtra("URL"));
-                          Intent startIntent = new Intent(RssService.class);
-                          startIntent.putExtras(startupVals);
-                          startService(startIntent);
-                          mRssList.setSelection(mRssList.getCount() - 1);
-                      }
-                    break;
-                default:
-                    break;
-            }
-        }
-    }
-    
-    // Our private ArrayAdapter implementation that returns a bold TextView for 
-    // RSS items that are unread, or a normal TextView for items that have been read.
-    private class RssCursorAdapter extends SimpleCursorAdapter {
-        public RssCursorAdapter(Context context, int layout, Cursor c, String[] from, int[] to) {
-            super(context, layout, c, from, to);
-        }
-        
-        // Here's our only important override--returning the list item.
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent){
-            TextView view = (TextView)super.getView(position, convertView, parent);
-            
-            if(view != null){
-                
-                // Now get the hasBeenRead value to determine the font.
-                int hasBeenReadColumnIndex = getCursor().getColumnIndex(RssContentProvider.HAS_BEEN_READ);
-                boolean hasBeenRead = (getCursor().getInt(hasBeenReadColumnIndex) == 1 ? true : false);
-                if(! hasBeenRead){
-                    Typeface type = view.getTypeface();
-                    view.setTypeface(Typeface.create(type, Typeface.BOLD_ITALIC));
-                }
-            }
-            return view;
-        } 
-    }
-
-}
-
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/RssContentProvider.java b/samples/MySampleRss/src/com/example/codelab/rssexample/RssContentProvider.java
deleted file mode 100644
index 5d523dc..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/RssContentProvider.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.content.ContentProvider;
-import android.content.ContentProviderDatabaseHelper;
-import android.content.UriMatcher;
-import android.content.Context;
-import android.database.Cursor;
-import android.database.SQLException;
-import android.database.sqlite.SQLiteDatabase;
-import android.database.sqlite.SQLiteQueryBuilder;
-import android.net.Uri;
-import android.content.ContentValues;
-import android.text.TextUtils;
-
-import java.util.logging.Logger;
-
-// Content Provider for RSS feed information. Each row describes a single
-// RSS feed. See the public static constants at the end of this class
-// to learn what each record contains.
-public class RssContentProvider extends ContentProvider {
-    private Logger mLogger = Logger.getLogger("com.example.codelab.rssexample");
-    private SQLiteDatabase mDb;
-    private DatabaseHelper mDbHelper = new DatabaseHelper();
-    private static final String DATABASE_NAME = "rssitems.db";
-    private static final String DATABASE_TABLE_NAME = "rssItems";
-    private static final int DB_VERSION = 1;
-    private static final int ALL_MESSAGES = 1;
-    private static final int SPECIFIC_MESSAGE = 2;
-
-    // Set up our URL matchers to help us determine what an
-    // incoming URI parameter is.
-    private static final UriMatcher URI_MATCHER;
-    static{
-        URI_MATCHER = new UriMatcher(UriMatcher.NO_MATCH);
-        URI_MATCHER.addURI("my_rss_item", "rssitem", ALL_MESSAGES);
-        URI_MATCHER.addURI("my_rss_item", "rssitem/#", SPECIFIC_MESSAGE);
-    }
-
-    // Here's the public URI used to query for RSS items.
-    public static final Uri CONTENT_URI = Uri.parse( "content://my_rss_item/rssitem");
-
-    // Here are our column name constants, used to query for field values.
-    public static final String ID = "_id";
-    public static final String URL = "url";
-    public static final String TITLE = "title";
-    public static final String HAS_BEEN_READ = "hasbeenread";
-    public static final String CONTENT = "rawcontent";
-    public static final String LAST_UPDATED = "lastupdated";
-    public static final String DEFAULT_SORT_ORDER = TITLE + " DESC";
-
-    // Database creation/version management helper.
-    // Create it statically because we don't need to have customized instances.
-    private static class DatabaseHelper extends ContentProviderDatabaseHelper{
-
-        @Override
-        public void onCreate(SQLiteDatabase db){
-            try{
-                String sql = "CREATE TABLE " + DATABASE_TABLE_NAME + "(" +
-                ID + " INTEGER PRIMARY KEY AUTOINCREMENT, " +
-                URL + " TEXT," +
-                TITLE + " TEXT," +
-                HAS_BEEN_READ + " BOOLEAN DEFAULT 0," +
-                CONTENT + " TEXT," +
-                LAST_UPDATED + " INTEGER DEFAULT 0);";
-                Logger.getLogger("com.example.codelab.rssexample").info("DatabaseHelper.onCreate(): SQL statement: " + sql);
-                db.execSQL(sql);
-                Logger.getLogger("com.example.codelab.rssexample").info("DatabaseHelper.onCreate(): Created a database");
-            } catch (SQLException e) {
-                Logger.getLogger("com.example.codelab.rssexample").warning("DatabaseHelper.onCreate(): Couldn't create a database!");
-            }
-        }
-
-        @Override
-        public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion){
-            // Don't have any upgrades yet, so if this gets called for some reason we'll
-            // just drop the existing table, and recreate the database with the
-            // standard method.
-            db.execSQL("DROP TABLE IF EXISTS " + DATABASE_TABLE_NAME + ";");
-
-        }
-    }
-
-    @Override
-    public boolean onCreate() {
-        // First we need to open the database. If this is our first time,
-        // the attempt to retrieve a database will throw
-        // FileNotFoundException, and we will then create the database.
-        final Context con = getContext();
-        try{
-            mDb = mDbHelper.openDatabase(getContext(), DATABASE_NAME, null, DB_VERSION);
-            mLogger.info("RssContentProvider.onCreate(): Opened a database");
-        } catch (Exception ex) {
-              return false;
-        }
-        if(mDb == null){
-            return false;
-        } else {
-            return true;
-        }
-    }
-
-    // Convert the URI into a custom MIME type.
-    // Our UriMatcher will parse the URI to decide whether the
-    // URI is for a single item or a list.
-    @Override
-    public String getType(Uri uri) {
-        switch (URI_MATCHER.match(uri)){
-            case ALL_MESSAGES:
-                return "vnd.android.cursor.dir/rssitem"; // List of items.
-            case SPECIFIC_MESSAGE:
-                return "vnd.android.cursor.item/rssitem";     // Specific item.
-            default:
-                return null;
-        }
-    }
-
-    @Override
-    public Cursor query(Uri uri, String[] projection, String selection,
-            String[] selectionArgs, String groupBy, String having, String sortOrder) {
-        // We won't bother checking the validity of params here, but you should!
-
-        // SQLiteQueryBuilder is the helper class that creates the
-        // proper SQL syntax for us.
-        SQLiteQueryBuilder qBuilder = new SQLiteQueryBuilder();
-
-        // Set the table we're querying.
-        qBuilder.setTables(DATABASE_TABLE_NAME);
-
-        // If the query ends in a specific record number, we're
-        // being asked for a specific record, so set the
-        // WHERE clause in our query.
-        if((URI_MATCHER.match(uri)) == SPECIFIC_MESSAGE){
-            qBuilder.appendWhere("_id=" + uri.getPathLeafId());
-        }
-
-        // Set sort order. If none specified, use default.
-        if(TextUtils.isEmpty(sortOrder)){
-            sortOrder = DEFAULT_SORT_ORDER;
-        }
-
-        // Make the query.
-        Cursor c = qBuilder.query(mDb,
-                projection,
-                selection,
-                selectionArgs,
-                groupBy,
-                having,
-                sortOrder);
-        c.setNotificationUri(getContext().getContentResolver(), uri);
-        return c;
-    }
-
-    @Override
-    public int update(Uri uri, ContentValues values, String whereClause) {
-        // NOTE Argument checking code omitted. Check your parameters!
-        int updateCount = mDb.update(DATABASE_TABLE_NAME, values, whereClause);
-
-        // Notify any listeners and return the updated row count.
-        getContext().getContentResolver().notifyUpdate(uri, null);
-        return updateCount;
-    }
-
-    @Override
-    public Uri insert(Uri requestUri, ContentValues initialValues) {
-        // NOTE Argument checking code omitted. Check your parameters! Check that
-        // your row addition request succeeded!
-
-       long rowId = -1;
-       rowId = mDb.insert(DATABASE_TABLE_NAME, "rawcontent", initialValues);
-       Uri newUri = CONTENT_URI.addId(rowId);
-
-       // Notify any listeners and return the URI of the new row.
-       getContext().getContentResolver().notifyInsert(CONTENT_URI, null);
-       return newUri;
-    }
-
-    @Override
-    public int delete(Uri uri, String where) {
-        // NOTE Argument checking code omitted. Check your parameters!
-        int rowCount = mDb.delete(DATABASE_TABLE_NAME, ID + " = " + uri.getPathLeafId());
-
-        // Notify any listeners and return the deleted row count.
-        getContext().getContentResolver().notifyDelete(uri, null);
-        return rowCount;
-    }
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/RssItem.java b/samples/MySampleRss/src/com/example/codelab/rssexample/RssItem.java
deleted file mode 100644
index f13357d..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/RssItem.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import java.util.Date;
-
-// Custom class to hold an RSS item.
-public class RssItem{
-    public String url;
-    public String title;
-    public boolean hasBeenRead = false;
-    public String content;
-    public Date lastUpdated;
-    
-    public RssItem(String url, String title){
-        this.url = url;
-        this.title = title;
-    }
-    
-    @Override public String toString(){
-        return title;
-    }
-}
diff --git a/samples/MySampleRss/src/com/example/codelab/rssexample/RssService.java b/samples/MySampleRss/src/com/example/codelab/rssexample/RssService.java
deleted file mode 100644
index e84f89d..0000000
--- a/samples/MySampleRss/src/com/example/codelab/rssexample/RssService.java
+++ /dev/null
@@ -1,263 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.codelab.rssexample;
-
-import android.app.Notification;
-import android.app.NotificationManager;
-import android.app.Service;
-import android.content.Intent;
-import android.content.SharedPreferences;
-import android.os.Binder;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.os.Bundle;
-import android.database.Cursor;
-import android.content.ContentResolver;
-import android.os.Handler;
-import android.text.TextUtils;
-import java.io.BufferedReader;
-import java.net.URL;
-import java.net.MalformedURLException;
-import java.lang.StringBuilder;
-import java.io.InputStreamReader;
-import java.io.IOException;
-import java.util.GregorianCalendar;
-import java.text.SimpleDateFormat;
-import java.util.logging.Logger;
-import java.util.regex.Pattern;
-import java.util.regex.Matcher;
-import java.text.ParseException;
-    
-public class RssService extends Service implements Runnable{
-    private Logger mLogger = Logger.getLogger(this.getPackageName());
-    public static final String REQUERY_KEY = "Requery_All"; // Sent to tell us force a requery.
-    public static final String RSS_URL = "RSS_URL"; // Sent to tell us to requery a specific item.
-    private NotificationManager mNM;
-    private Cursor mCur;                        // RSS content provider cursor.
-    private GregorianCalendar mLastCheckedTime; // Time we last checked our feeds.
-    private final String LAST_CHECKED_PREFERENCE = "last_checked";
-    static final int UPDATE_FREQUENCY_IN_MINUTES = 60;
-    private Handler mHandler;           // Handler to trap our update reminders.
-    private final int NOTIFY_ID = 1;    // Identifies our service icon in the icon tray.
-    
-    @Override
-    protected void onCreate(){
-        // Display an icon to show that the service is running.
-        mNM = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
-        Intent clickIntent = new Intent(Intent.ACTION_MAIN);
-        clickIntent.setClassName(MyRssReader5.class.getName());
-        Notification note = new Notification(this, R.drawable.rss_icon, "RSS Service",
-                clickIntent, null);
-        mNM.notify(NOTIFY_ID, note);
-        mHandler = new Handler();
-
-        // Create the intent that will be launched if the user clicks the 
-        // icon on the status bar. This will launch our RSS Reader app.
-        Intent intent = new Intent(MyRssReader.class);
-        
-        // Get a cursor over the RSS items.
-        ContentResolver rslv = getContentResolver();
-        mCur = rslv.query(RssContentProvider.CONTENT_URI, null, null, null, null);
-        
-        // Load last updated value.
-        // We store last updated value in preferences.
-        SharedPreferences pref = getSharedPreferences("", 0);
-        mLastCheckedTime = new GregorianCalendar();
-        mLastCheckedTime.setTimeInMillis(pref.getLong(LAST_CHECKED_PREFERENCE, 0));
-
-//BEGIN_INCLUDE(5_1)
-        // Need to run ourselves on a new thread, because 
-        // we will be making resource-intensive HTTP calls.
-        // Our run() method will check whether we need to requery
-        // our sources.
-        Thread thr = new Thread(null, this, "rss_service_thread");
-        thr.start();
-//END_INCLUDE(5_1)        
-        mLogger.info("RssService created");
-    }
-    
-//BEGIN_INCLUDE(5_3)
-    // A cheap way to pass a message to tell the service to requery.
-    @Override
-    protected void onStart(Intent intent, int startId){
-        super.onStart(startId, arguments);
-        Bundle arguments = intent.getExtras();
-        if(arguments != null) {
-            if(arguments.containsKey(REQUERY_KEY)) {
-                queryRssItems();
-            }
-            if(arguments.containsKey(RSS_URL)) {
-                // Typically called after adding a new RSS feed to the list.
-                queryItem(arguments.getString(RSS_URL));
-            }
-        }    
-    }
-//END_INCLUDE(5_3)
-    
-    // When the service is destroyed, get rid of our persistent icon.
-    @Override
-    protected void onDestroy(){
-      mNM.cancel(NOTIFY_ID);
-    }
-    
-    // Determines whether the next scheduled check time has passed.
-    // Loads this value from a stored preference. If it has (or if no
-    // previous value has been stored), it will requery all RSS feeds;
-    // otherwise, it will post a delayed reminder to check again after
-    // now - next_check_time milliseconds.
-    public void queryIfPeriodicRefreshRequired() {
-        GregorianCalendar nextCheckTime = new GregorianCalendar();
-        nextCheckTime = (GregorianCalendar) mLastCheckedTime.clone();
-        nextCheckTime.add(GregorianCalendar.MINUTE, UPDATE_FREQUENCY_IN_MINUTES);
-        mLogger.info("last checked time:" + mLastCheckedTime.toString() + "  Next checked time: " + nextCheckTime.toString());
-        
-        if(mLastCheckedTime.before(nextCheckTime)) {
-            queryRssItems();
-        } else {
-            // Post a message to query again when we get to the next check time.
-            long timeTillNextUpdate = mLastCheckedTime.getTimeInMillis() - GregorianCalendar.getInstance().getTimeInMillis();
-            mHandler.postDelayed(this, 1000 * 60 * UPDATE_FREQUENCY_IN_MINUTES);
-        }
-          
-    }
-
-    // Query all feeds. If the new feed has a newer pubDate than the previous,
-    // then update it.
-    void queryRssItems(){
-        mLogger.info("Querying Rss feeds...");
- 
-        // The cursor might have gone stale. Requery to be sure.
-        // We need to call next() after a requery to get to the 
-        // first record.
-        mCur.requery();
-        while (mCur.next()){
-             // Get the URL for the feed from the cursor.
-             int urlColumnIndex = mCur.getColumnIndex(RssContentProvider.URL);
-             String url = mCur.getString(urlColumnIndex);
-             queryItem(url);
-        }
-        // Reset the global "last checked" time
-        mLastCheckedTime.setTimeInMillis(System.currentTimeMillis());
-      
-        // Post a message to query again in [update_frequency] minutes
-        mHandler.postDelayed(this, 1000 * 60 * UPDATE_FREQUENCY_IN_MINUTES);
-    }
-    
-    
-    // Query an individual RSS feed. Returns true if successful, false otherwise.
-    private boolean queryItem(String url) {
-        try {
-            URL wrappedUrl = new URL(url);
-            String rssFeed = readRss(wrappedUrl);
-            mLogger.info("RSS Feed " + url + ":\n " + rssFeed);
-            if(TextUtils.isEmpty(rssFeed)) {
-                return false;
-            }
-              
-            // Parse out the feed update date, and compare to the current version.
-            // If feed update time is newer, or zero (if never updated, for new 
-            // items), then update the content, date, and hasBeenRead fields.
-            // lastUpdated = <rss><channel><pubDate>value</pubDate></channel></rss>.
-            // If that value doesn't exist, the current date is used.
-            GregorianCalendar feedPubDate = parseRssDocPubDate(rssFeed);
-            GregorianCalendar lastUpdated = new GregorianCalendar();
-            int lastUpdatedColumnIndex = mCur.getColumnIndex(RssContentProvider.LAST_UPDATED);
-            lastUpdated.setTimeInMillis(mCur.getLong(lastUpdatedColumnIndex));
-            if(lastUpdated.getTimeInMillis() == 0 ||
-                lastUpdated.before(feedPubDate) && !TextUtils.isEmpty(rssFeed)) {
-                // Get column indices.
-                int contentColumnIndex = mCur.getColumnIndex(RssContentProvider.CONTENT);
-                int updatedColumnIndex = mCur.getColumnIndex(RssContentProvider.HAS_BEEN_READ);
-                 
-                // Update values.
-                mCur.updateString(contentColumnIndex, rssFeed);
-                mCur.updateLong(lastUpdatedColumnIndex, feedPubDate.getTimeInMillis());
-                mCur.updateInt(updatedColumnIndex, 0);
-                mCur.commitUpdates();
-            }
-        } catch (MalformedURLException ex) {
-              mLogger.warning("Error in queryItem: Bad url");
-              return false;
-        }
-        return true;
-    }  
- 
- // BEGIN_INCLUDE(5_2)    
-    // Get the <pubDate> content from a feed and return a 
-    // GregorianCalendar version of the date.
-    // If the element doesn't exist or otherwise can't be
-    // found, return a date of 0 to force a refresh.
-    private GregorianCalendar parseRssDocPubDate(String xml){
-        GregorianCalendar cal = new GregorianCalendar();
-        cal.setTimeInMillis(0);
-        String patt ="<[\\s]*pubDate[\\s]*>(.+?)</pubDate[\\s]*>";
-        Pattern p = Pattern.compile(patt);
-        Matcher m = p.matcher(xml);
-        try {
-            if(m.find()) {
-                mLogger.info("pubDate: " + m.group());
-                SimpleDateFormat pubDate = new SimpleDateFormat();
-                cal.setTime(pubDate.parse(m.group(1)));
-            }
-       } catch(ParseException ex) {
-            mLogger.warning("parseRssDocPubDate couldn't find a <pubDate> tag. Returning default value.");
-       }
-        return cal;
-    }    
-    
-    // Read the submitted RSS page.
-    String readRss(URL url){
-      String html = "<html><body><h2>No data</h2></body></html>";
-      try {
-          mLogger.info("URL is:" + url.toString());
-          BufferedReader inStream =
-              new BufferedReader(new InputStreamReader(url.openStream()),
-                      1024);
-          String line;
-          StringBuilder rssFeed = new StringBuilder();
-          while ((line = inStream.readLine()) != null){
-              rssFeed.append(line);
-          }
-          html = rssFeed.toString();
-      } catch(IOException ex) {
-          mLogger.warning("Couldn't open an RSS stream");
-      }
-      return html;
-    }
-//END_INCLUDE(5_2)
-
-    // Callback we send to ourself to requery all feeds.
-    public void run() {
-        queryIfPeriodicRefreshRequired();
-    }
-    
-    // Required by Service. We won't implement it here, but need to 
-    // include this basic code.
-    @Override
-    public IBinder onBind(Intent intent){
-        return mBinder;
-    }
-
-    // This is the object that receives RPC calls from clients.See
-    // RemoteService for a more complete example.
-    private final IBinder mBinder = new Binder()  {
-        @Override
-        protected boolean onTransact(int code, Parcel data, Parcel reply, int flags) {
-            return super.onTransact(code, data, reply, flags);
-        }
-    };
-}
diff --git a/samples/NotePad/Android.mk b/samples/NotePad/Android.mk
deleted file mode 100644
index 7939212..0000000
--- a/samples/NotePad/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := NotePad
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/NotePad/AndroidManifest.xml b/samples/NotePad/AndroidManifest.xml
deleted file mode 100644
index 5c56daf..0000000
--- a/samples/NotePad/AndroidManifest.xml
+++ /dev/null
@@ -1,104 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.notepad"
->
-    <application android:icon="@drawable/app_notes"
-        android:label="@string/app_name"
-    >
-        <provider android:name="NotePadProvider"
-            android:authorities="com.google.provider.NotePad"
-        />
-
-        <activity android:name="NotesList" android:label="@string/title_notes_list">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-            <intent-filter>
-                <action android:name="android.intent.action.VIEW" />
-                <action android:name="android.intent.action.EDIT" />
-                <action android:name="android.intent.action.PICK" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <data android:mimeType="vnd.android.cursor.dir/vnd.google.note" />
-            </intent-filter>
-            <intent-filter>
-                <action android:name="android.intent.action.GET_CONTENT" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <data android:mimeType="vnd.android.cursor.item/vnd.google.note" />
-            </intent-filter>
-        </activity>
-        
-        <activity android:name="NoteEditor"
-            android:theme="@android:style/Theme.Light"
-            android:label="@string/title_note"
-            android:screenOrientation="sensor"
-            android:configChanges="keyboardHidden|orientation"
-        >
-            <!-- This filter says that we can view or edit the data of
-                 a single note -->
-            <intent-filter android:label="@string/resolve_edit">
-                <action android:name="android.intent.action.VIEW" />
-                <action android:name="android.intent.action.EDIT" />
-                <action android:name="com.android.notepad.action.EDIT_NOTE" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <data android:mimeType="vnd.android.cursor.item/vnd.google.note" />
-            </intent-filter>
-
-            <!-- This filter says that we can create a new note inside
-                 of a directory of notes. -->
-            <intent-filter>
-                <action android:name="android.intent.action.INSERT" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <data android:mimeType="vnd.android.cursor.dir/vnd.google.note" />
-            </intent-filter>
-
-        </activity>
-        
-		<activity android:name="TitleEditor" android:label="@string/title_edit_title"
-				android:theme="@android:style/Theme.Dialog"
-                android:windowSoftInputMode="stateVisible">
-            <!-- This activity implements an alternative action that can be
-                 performed on notes: editing their title.  It can be used as
-                 a default operation if the user invokes this action, and is
-                 available as an alternative action for any note data. -->
-            <intent-filter android:label="@string/resolve_title">
-                <!-- This is the action we perform.  It is a custom action we
-                     define for our application, not a generic VIEW or EDIT
-                     action since we are not a general note viewer/editor. -->
-                <action android:name="com.android.notepad.action.EDIT_TITLE" />
-                <!-- DEFAULT: execute if being directly invoked. -->
-                <category android:name="android.intent.category.DEFAULT" />
-                <!-- ALTERNATIVE: show as an alternative action when the user is
-                     working with this type of data. -->
-                <category android:name="android.intent.category.ALTERNATIVE" />
-                <!-- SELECTED_ALTERNATIVE: show as an alternative action the user
-                     can perform when selecting this type of data. -->
-                <category android:name="android.intent.category.SELECTED_ALTERNATIVE" />
-                <!-- This is the data type we operate on. -->
-                <data android:mimeType="vnd.android.cursor.item/vnd.google.note" />
-            </intent-filter>
-        </activity>
-        
-    </application>
-</manifest>
-
diff --git a/samples/NotePad/_index.html b/samples/NotePad/_index.html
deleted file mode 100644
index 2a18969..0000000
--- a/samples/NotePad/_index.html
+++ /dev/null
@@ -1,12 +0,0 @@
-<p>A simple note pad application.
-It demonstrates...
-<ul> 
-<li>using views
-<li>accessing a database
-<li>using an intent to open a new window
-<li>managing activity lifecycle
-<li>and many other goodies...
-</ul>
-</p>
-<img alt="Note Pad Example" class="gallery"  src="sample_notepad.png" >
-<img alt="Note Pad Example" class="gallery"  src="sample_note.png"  >
diff --git a/samples/NotePad/res/drawable/app_notes.png b/samples/NotePad/res/drawable/app_notes.png
deleted file mode 100644
index 0479138..0000000
--- a/samples/NotePad/res/drawable/app_notes.png
+++ /dev/null
Binary files differ
diff --git a/samples/NotePad/res/layout/note_editor.xml b/samples/NotePad/res/layout/note_editor.xml
deleted file mode 100644
index c54a963..0000000
--- a/samples/NotePad/res/layout/note_editor.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<view xmlns:android="http://schemas.android.com/apk/res/android"
-    class="com.example.android.notepad.NoteEditor$LinedEditText"
-    android:id="@+id/note"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    android:background="@android:color/transparent"
-    android:padding="5dip"
-    android:scrollbars="vertical"
-    android:fadingEdge="vertical"
-    android:gravity="top"
-    android:textSize="22sp"
-    android:capitalize="sentences"
-/>
diff --git a/samples/NotePad/res/layout/noteslist_item.xml b/samples/NotePad/res/layout/noteslist_item.xml
deleted file mode 100644
index b167734..0000000
--- a/samples/NotePad/res/layout/noteslist_item.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2006 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<TextView xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@android:id/text1"
-    android:layout_width="fill_parent"
-    android:layout_height="?android:attr/listPreferredItemHeight"
-    android:textAppearance="?android:attr/textAppearanceLarge"
-    android:gravity="center_vertical"
-    android:paddingLeft="5dip"
-    android:singleLine="true"
-/>
diff --git a/samples/NotePad/res/layout/title_editor.xml b/samples/NotePad/res/layout/title_editor.xml
deleted file mode 100644
index 3593ec6..0000000
--- a/samples/NotePad/res/layout/title_editor.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-  	android:layout_width="wrap_content" 
-    android:layout_height="wrap_content"
-    android:orientation="vertical"
-    android:paddingLeft="6dip"
-    android:paddingRight="6dip"
-    android:paddingBottom="3dip">
-   					  
-    <EditText android:id="@+id/title" 
-        android:maxLines="1" 
-        android:layout_marginTop="2dip"
-        android:layout_width="wrap_content"
-      	android:ems="25"
-        android:layout_height="wrap_content" 
-        android:autoText="true"
-        android:capitalize="sentences"
-        android:scrollHorizontally="true" />
-   		
-    <Button android:id="@+id/ok"
-        android:layout_width="wrap_content" 
-        android:layout_height="wrap_content" 
-        android:layout_gravity="right"
-        android:text="@string/button_ok" />
-   		
-</LinearLayout>
diff --git a/samples/NotePad/res/values/strings.xml b/samples/NotePad/res/values/strings.xml
deleted file mode 100644
index b4bf671..0000000
--- a/samples/NotePad/res/values/strings.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <string name="menu_delete">Delete</string>
-    <string name="menu_insert">Add note</string>
-    <string name="menu_revert">Revert</string>
-    <string name="menu_discard">Discard</string>
-
-    <string name="resolve_edit">Edit note</string>
-    <string name="resolve_title">Edit title</string>  
-
-    <string name="title_create">Create note</string>
-    <string name="title_edit">Edit note</string>
-	<string name="title_notes_list">Note pad</string>   
-	<string name="title_note">Note</string>  
-	<string name="title_edit_title">Note title:</string>  
-	
-	<string name="app_name">Note Pad</string>  
-	
-	<string name="button_ok">OK</string>  
-	
-	<string name="error_title">Error</string>
-	<string name="error_message">Error loading note</string>
-</resources>
diff --git a/samples/NotePad/sample_note.png b/samples/NotePad/sample_note.png
deleted file mode 100644
index cea1a08..0000000
--- a/samples/NotePad/sample_note.png
+++ /dev/null
Binary files differ
diff --git a/samples/NotePad/sample_notepad.png b/samples/NotePad/sample_notepad.png
deleted file mode 100644
index c498847..0000000
--- a/samples/NotePad/sample_notepad.png
+++ /dev/null
Binary files differ
diff --git a/samples/NotePad/src/com/example/android/notepad/NoteEditor.java b/samples/NotePad/src/com/example/android/notepad/NoteEditor.java
deleted file mode 100644
index e45efd8..0000000
--- a/samples/NotePad/src/com/example/android/notepad/NoteEditor.java
+++ /dev/null
@@ -1,347 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import com.example.android.notepad.NotePad.Notes;
-
-import android.app.Activity;
-import android.content.ComponentName;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.Intent;
-import android.database.Cursor;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.net.Uri;
-import android.os.Bundle;
-import android.util.AttributeSet;
-import android.util.Log;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.widget.EditText;
-
-/**
- * A generic activity for editing a note in a database.  This can be used
- * either to simply view a note {@link Intent#ACTION_VIEW}, view and edit a note
- * {@link Intent#ACTION_EDIT}, or create a new note {@link Intent#ACTION_INSERT}.  
- */
-public class NoteEditor extends Activity {
-    private static final String TAG = "Notes";
-
-    /**
-     * Standard projection for the interesting columns of a normal note.
-     */
-    private static final String[] PROJECTION = new String[] {
-            Notes._ID, // 0
-            Notes.NOTE, // 1
-    };
-    /** The index of the note column */
-    private static final int COLUMN_INDEX_NOTE = 1;
-    
-    // This is our state data that is stored when freezing.
-    private static final String ORIGINAL_CONTENT = "origContent";
-
-    // Identifiers for our menu items.
-    private static final int REVERT_ID = Menu.FIRST;
-    private static final int DISCARD_ID = Menu.FIRST + 1;
-    private static final int DELETE_ID = Menu.FIRST + 2;
-
-    // The different distinct states the activity can be run in.
-    private static final int STATE_EDIT = 0;
-    private static final int STATE_INSERT = 1;
-
-    private int mState;
-    private boolean mNoteOnly = false;
-    private Uri mUri;
-    private Cursor mCursor;
-    private EditText mText;
-    private String mOriginalContent;
-
-    /**
-     * A custom EditText that draws lines between each line of text that is displayed.
-     */
-    public static class LinedEditText extends EditText {
-        private Rect mRect;
-        private Paint mPaint;
-
-        // we need this constructor for LayoutInflater
-        public LinedEditText(Context context, AttributeSet attrs) {
-            super(context, attrs);
-            
-            mRect = new Rect();
-            mPaint = new Paint();
-            mPaint.setStyle(Paint.Style.STROKE);
-            mPaint.setColor(0x800000FF);
-        }
-        
-        @Override
-        protected void onDraw(Canvas canvas) {
-            int count = getLineCount();
-            Rect r = mRect;
-            Paint paint = mPaint;
-
-            for (int i = 0; i < count; i++) {
-                int baseline = getLineBounds(i, r);
-
-                canvas.drawLine(r.left, baseline + 1, r.right, baseline + 1, paint);
-            }
-
-            super.onDraw(canvas);
-        }
-    }
-
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        final Intent intent = getIntent();
-
-        // Do some setup based on the action being performed.
-
-        final String action = intent.getAction();
-        if (Intent.ACTION_EDIT.equals(action)) {
-            // Requested to edit: set that state, and the data being edited.
-            mState = STATE_EDIT;
-            mUri = intent.getData();
-        } else if (Intent.ACTION_INSERT.equals(action)) {
-            // Requested to insert: set that state, and create a new entry
-            // in the container.
-            mState = STATE_INSERT;
-            mUri = getContentResolver().insert(intent.getData(), null);
-
-            // If we were unable to create a new note, then just finish
-            // this activity.  A RESULT_CANCELED will be sent back to the
-            // original activity if they requested a result.
-            if (mUri == null) {
-                Log.e(TAG, "Failed to insert new note into " + getIntent().getData());
-                finish();
-                return;
-            }
-
-            // The new entry was created, so assume all will end well and
-            // set the result to be returned.
-            setResult(RESULT_OK, (new Intent()).setAction(mUri.toString()));
-
-        } else {
-            // Whoops, unknown action!  Bail.
-            Log.e(TAG, "Unknown action, exiting");
-            finish();
-            return;
-        }
-
-        // Set the layout for this activity.  You can find it in res/layout/note_editor.xml
-        setContentView(R.layout.note_editor);
-        
-        // The text view for our note, identified by its ID in the XML file.
-        mText = (EditText) findViewById(R.id.note);
-
-        // Get the note!
-        mCursor = managedQuery(mUri, PROJECTION, null, null, null);
-
-        // If an instance of this activity had previously stopped, we can
-        // get the original text it started with.
-        if (savedInstanceState != null) {
-            mOriginalContent = savedInstanceState.getString(ORIGINAL_CONTENT);
-        }
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-
-        // If we didn't have any trouble retrieving the data, it is now
-        // time to get at the stuff.
-        if (mCursor != null) {
-            // Make sure we are at the one and only row in the cursor.
-            mCursor.moveToFirst();
-
-            // Modify our overall title depending on the mode we are running in.
-            if (mState == STATE_EDIT) {
-                setTitle(getText(R.string.title_edit));
-            } else if (mState == STATE_INSERT) {
-                setTitle(getText(R.string.title_create));
-            }
-
-            // This is a little tricky: we may be resumed after previously being
-            // paused/stopped.  We want to put the new text in the text view,
-            // but leave the user where they were (retain the cursor position
-            // etc).  This version of setText does that for us.
-            String note = mCursor.getString(COLUMN_INDEX_NOTE);
-            mText.setTextKeepState(note);
-            
-            // If we hadn't previously retrieved the original text, do so
-            // now.  This allows the user to revert their changes.
-            if (mOriginalContent == null) {
-                mOriginalContent = note;
-            }
-
-        } else {
-            setTitle(getText(R.string.error_title));
-            mText.setText(getText(R.string.error_message));
-        }
-    }
-
-    @Override
-    protected void onSaveInstanceState(Bundle outState) {
-        // Save away the original text, so we still have it if the activity
-        // needs to be killed while paused.
-        outState.putString(ORIGINAL_CONTENT, mOriginalContent);
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-
-        // The user is going somewhere else, so make sure their current
-        // changes are safely saved away in the provider.  We don't need
-        // to do this if only editing.
-        if (mCursor != null) {
-            String text = mText.getText().toString();
-            int length = text.length();
-
-            // If this activity is finished, and there is no text, then we
-            // do something a little special: simply delete the note entry.
-            // Note that we do this both for editing and inserting...  it
-            // would be reasonable to only do it when inserting.
-            if (isFinishing() && (length == 0) && !mNoteOnly) {
-                setResult(RESULT_CANCELED);
-                deleteNote();
-
-            // Get out updates into the provider.
-            } else {
-                ContentValues values = new ContentValues();
-
-                // This stuff is only done when working with a full-fledged note.
-                if (!mNoteOnly) {
-                    // Bump the modification time to now.
-                    values.put(Notes.MODIFIED_DATE, System.currentTimeMillis());
-
-                    // If we are creating a new note, then we want to also create
-                    // an initial title for it.
-                    if (mState == STATE_INSERT) {
-                        String title = text.substring(0, Math.min(30, length));
-                        if (length > 30) {
-                            int lastSpace = title.lastIndexOf(' ');
-                            if (lastSpace > 0) {
-                                title = title.substring(0, lastSpace);
-                            }
-                        }
-                        values.put(Notes.TITLE, title);
-                    }
-                }
-
-                // Write our text back into the provider.
-                values.put(Notes.NOTE, text);
-
-                // Commit all of our changes to persistent storage. When the update completes
-                // the content provider will notify the cursor of the change, which will
-                // cause the UI to be updated.
-                getContentResolver().update(mUri, values, null, null);
-            }
-        }
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        // Build the menus that are shown when editing.
-        if (mState == STATE_EDIT) {
-            menu.add(0, REVERT_ID, 0, R.string.menu_revert)
-                    .setShortcut('0', 'r')
-                    .setIcon(android.R.drawable.ic_menu_revert);
-            if (!mNoteOnly) {
-                menu.add(0, DELETE_ID, 0, R.string.menu_delete)
-                        .setShortcut('1', 'd')
-                        .setIcon(android.R.drawable.ic_menu_delete);
-            }
-
-        // Build the menus that are shown when inserting.
-        } else {
-            menu.add(0, DISCARD_ID, 0, R.string.menu_discard)
-                    .setShortcut('0', 'd')
-                    .setIcon(android.R.drawable.ic_menu_delete);
-        }
-
-        // If we are working on a full note, then append to the
-        // menu items for any other activities that can do stuff with it
-        // as well.  This does a query on the system for any activities that
-        // implement the ALTERNATIVE_ACTION for our data, adding a menu item
-        // for each one that is found.
-        if (!mNoteOnly) {
-            Intent intent = new Intent(null, getIntent().getData());
-            intent.addCategory(Intent.CATEGORY_ALTERNATIVE);
-            menu.addIntentOptions(Menu.CATEGORY_ALTERNATIVE, 0, 0,
-                    new ComponentName(this, NoteEditor.class), null, intent, 0, null);
-        }
-
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        // Handle all of the possible menu actions.
-        switch (item.getItemId()) {
-        case DELETE_ID:
-            deleteNote();
-            finish();
-            break;
-        case DISCARD_ID:
-            cancelNote();
-            break;
-        case REVERT_ID:
-            cancelNote();
-            break;
-        }
-        return super.onOptionsItemSelected(item);
-    }
-
-    /**
-     * Take care of canceling work on a note.  Deletes the note if we
-     * had created it, otherwise reverts to the original text.
-     */
-    private final void cancelNote() {
-        if (mCursor != null) {
-            if (mState == STATE_EDIT) {
-                // Put the original note text back into the database
-                mCursor.close();
-                mCursor = null;
-                ContentValues values = new ContentValues();
-                values.put(Notes.NOTE, mOriginalContent);
-                getContentResolver().update(mUri, values, null, null);
-            } else if (mState == STATE_INSERT) {
-                // We inserted an empty note, make sure to delete it
-                deleteNote();
-            }
-        }
-        setResult(RESULT_CANCELED);
-        finish();
-    }
-
-    /**
-     * Take care of deleting a note.  Simply deletes the entry.
-     */
-    private final void deleteNote() {
-        if (mCursor != null) {
-            mCursor.close();
-            mCursor = null;
-            getContentResolver().delete(mUri, null, null);
-            mText.setText("");
-        }
-    }
-}
diff --git a/samples/NotePad/src/com/example/android/notepad/NotePad.java b/samples/NotePad/src/com/example/android/notepad/NotePad.java
deleted file mode 100644
index 25be23e..0000000
--- a/samples/NotePad/src/com/example/android/notepad/NotePad.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import android.net.Uri;
-import android.provider.BaseColumns;
-
-/**
- * Convenience definitions for NotePadProvider
- */
-public final class NotePad {
-    public static final String AUTHORITY = "com.google.provider.NotePad";
-
-    // This class cannot be instantiated
-    private NotePad() {}
-    
-    /**
-     * Notes table
-     */
-    public static final class Notes implements BaseColumns {
-        // This class cannot be instantiated
-        private Notes() {}
-
-        /**
-         * The content:// style URL for this table
-         */
-        public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/notes");
-
-        /**
-         * The MIME type of {@link #CONTENT_URI} providing a directory of notes.
-         */
-        public static final String CONTENT_TYPE = "vnd.android.cursor.dir/vnd.google.note";
-
-        /**
-         * The MIME type of a {@link #CONTENT_URI} sub-directory of a single note.
-         */
-        public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.google.note";
-
-        /**
-         * The default sort order for this table
-         */
-        public static final String DEFAULT_SORT_ORDER = "modified DESC";
-
-        /**
-         * The title of the note
-         * <P>Type: TEXT</P>
-         */
-        public static final String TITLE = "title";
-
-        /**
-         * The note itself
-         * <P>Type: TEXT</P>
-         */
-        public static final String NOTE = "note";
-
-        /**
-         * The timestamp for when the note was created
-         * <P>Type: INTEGER (long from System.curentTimeMillis())</P>
-         */
-        public static final String CREATED_DATE = "created";
-
-        /**
-         * The timestamp for when the note was last modified
-         * <P>Type: INTEGER (long from System.curentTimeMillis())</P>
-         */
-        public static final String MODIFIED_DATE = "modified";
-    }
-}
diff --git a/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java b/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java
deleted file mode 100644
index f1d3fdc..0000000
--- a/samples/NotePad/src/com/example/android/notepad/NotePadProvider.java
+++ /dev/null
@@ -1,249 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import com.example.android.notepad.NotePad.Notes;
-
-import android.content.ContentProvider;
-import android.content.ContentUris;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.UriMatcher;
-import android.content.res.Resources;
-import android.database.Cursor;
-import android.database.SQLException;
-import android.database.sqlite.SQLiteDatabase;
-import android.database.sqlite.SQLiteOpenHelper;
-import android.database.sqlite.SQLiteQueryBuilder;
-import android.net.Uri;
-import android.text.TextUtils;
-import android.util.Log;
-
-import java.util.HashMap;
-
-/**
- * Provides access to a database of notes. Each note has a title, the note
- * itself, a creation date and a modified data.
- */
-public class NotePadProvider extends ContentProvider {
-
-    private static final String TAG = "NotePadProvider";
-
-    private static final String DATABASE_NAME = "note_pad.db";
-    private static final int DATABASE_VERSION = 2;
-    private static final String NOTES_TABLE_NAME = "notes";
-
-    private static HashMap<String, String> sNotesProjectionMap;
-
-    private static final int NOTES = 1;
-    private static final int NOTE_ID = 2;
-
-    private static final UriMatcher sUriMatcher;
-
-    /**
-     * This class helps open, create, and upgrade the database file.
-     */
-    private static class DatabaseHelper extends SQLiteOpenHelper {
-
-        DatabaseHelper(Context context) {
-            super(context, DATABASE_NAME, null, DATABASE_VERSION);
-        }
-
-        @Override
-        public void onCreate(SQLiteDatabase db) {
-            db.execSQL("CREATE TABLE " + NOTES_TABLE_NAME + " ("
-                    + Notes._ID + " INTEGER PRIMARY KEY,"
-                    + Notes.TITLE + " TEXT,"
-                    + Notes.NOTE + " TEXT,"
-                    + Notes.CREATED_DATE + " INTEGER,"
-                    + Notes.MODIFIED_DATE + " INTEGER"
-                    + ");");
-        }
-
-        @Override
-        public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
-            Log.w(TAG, "Upgrading database from version " + oldVersion + " to "
-                    + newVersion + ", which will destroy all old data");
-            db.execSQL("DROP TABLE IF EXISTS notes");
-            onCreate(db);
-        }
-    }
-
-    private DatabaseHelper mOpenHelper;
-
-    @Override
-    public boolean onCreate() {
-        mOpenHelper = new DatabaseHelper(getContext());
-        return true;
-    }
-
-    @Override
-    public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs,
-            String sortOrder) {
-        SQLiteQueryBuilder qb = new SQLiteQueryBuilder();
-
-        switch (sUriMatcher.match(uri)) {
-        case NOTES:
-            qb.setTables(NOTES_TABLE_NAME);
-            qb.setProjectionMap(sNotesProjectionMap);
-            break;
-
-        case NOTE_ID:
-            qb.setTables(NOTES_TABLE_NAME);
-            qb.setProjectionMap(sNotesProjectionMap);
-            qb.appendWhere(Notes._ID + "=" + uri.getPathSegments().get(1));
-            break;
-
-        default:
-            throw new IllegalArgumentException("Unknown URI " + uri);
-        }
-
-        // If no sort order is specified use the default
-        String orderBy;
-        if (TextUtils.isEmpty(sortOrder)) {
-            orderBy = NotePad.Notes.DEFAULT_SORT_ORDER;
-        } else {
-            orderBy = sortOrder;
-        }
-
-        // Get the database and run the query
-        SQLiteDatabase db = mOpenHelper.getReadableDatabase();
-        Cursor c = qb.query(db, projection, selection, selectionArgs, null, null, orderBy);
-
-        // Tell the cursor what uri to watch, so it knows when its source data changes
-        c.setNotificationUri(getContext().getContentResolver(), uri);
-        return c;
-    }
-
-    @Override
-    public String getType(Uri uri) {
-        switch (sUriMatcher.match(uri)) {
-        case NOTES:
-            return Notes.CONTENT_TYPE;
-
-        case NOTE_ID:
-            return Notes.CONTENT_ITEM_TYPE;
-
-        default:
-            throw new IllegalArgumentException("Unknown URI " + uri);
-        }
-    }
-
-    @Override
-    public Uri insert(Uri uri, ContentValues initialValues) {
-        // Validate the requested uri
-        if (sUriMatcher.match(uri) != NOTES) {
-            throw new IllegalArgumentException("Unknown URI " + uri);
-        }
-
-        ContentValues values;
-        if (initialValues != null) {
-            values = new ContentValues(initialValues);
-        } else {
-            values = new ContentValues();
-        }
-
-        Long now = Long.valueOf(System.currentTimeMillis());
-
-        // Make sure that the fields are all set
-        if (values.containsKey(NotePad.Notes.CREATED_DATE) == false) {
-            values.put(NotePad.Notes.CREATED_DATE, now);
-        }
-
-        if (values.containsKey(NotePad.Notes.MODIFIED_DATE) == false) {
-            values.put(NotePad.Notes.MODIFIED_DATE, now);
-        }
-
-        if (values.containsKey(NotePad.Notes.TITLE) == false) {
-            Resources r = Resources.getSystem();
-            values.put(NotePad.Notes.TITLE, r.getString(android.R.string.untitled));
-        }
-
-        if (values.containsKey(NotePad.Notes.NOTE) == false) {
-            values.put(NotePad.Notes.NOTE, "");
-        }
-
-        SQLiteDatabase db = mOpenHelper.getWritableDatabase();
-        long rowId = db.insert(NOTES_TABLE_NAME, Notes.NOTE, values);
-        if (rowId > 0) {
-            Uri noteUri = ContentUris.withAppendedId(NotePad.Notes.CONTENT_URI, rowId);
-            getContext().getContentResolver().notifyChange(noteUri, null);
-            return noteUri;
-        }
-
-        throw new SQLException("Failed to insert row into " + uri);
-    }
-
-    @Override
-    public int delete(Uri uri, String where, String[] whereArgs) {
-        SQLiteDatabase db = mOpenHelper.getWritableDatabase();
-        int count;
-        switch (sUriMatcher.match(uri)) {
-        case NOTES:
-            count = db.delete(NOTES_TABLE_NAME, where, whereArgs);
-            break;
-
-        case NOTE_ID:
-            String noteId = uri.getPathSegments().get(1);
-            count = db.delete(NOTES_TABLE_NAME, Notes._ID + "=" + noteId
-                    + (!TextUtils.isEmpty(where) ? " AND (" + where + ')' : ""), whereArgs);
-            break;
-
-        default:
-            throw new IllegalArgumentException("Unknown URI " + uri);
-        }
-
-        getContext().getContentResolver().notifyChange(uri, null);
-        return count;
-    }
-
-    @Override
-    public int update(Uri uri, ContentValues values, String where, String[] whereArgs) {
-        SQLiteDatabase db = mOpenHelper.getWritableDatabase();
-        int count;
-        switch (sUriMatcher.match(uri)) {
-        case NOTES:
-            count = db.update(NOTES_TABLE_NAME, values, where, whereArgs);
-            break;
-
-        case NOTE_ID:
-            String noteId = uri.getPathSegments().get(1);
-            count = db.update(NOTES_TABLE_NAME, values, Notes._ID + "=" + noteId
-                    + (!TextUtils.isEmpty(where) ? " AND (" + where + ')' : ""), whereArgs);
-            break;
-
-        default:
-            throw new IllegalArgumentException("Unknown URI " + uri);
-        }
-
-        getContext().getContentResolver().notifyChange(uri, null);
-        return count;
-    }
-
-    static {
-        sUriMatcher = new UriMatcher(UriMatcher.NO_MATCH);
-        sUriMatcher.addURI(NotePad.AUTHORITY, "notes", NOTES);
-        sUriMatcher.addURI(NotePad.AUTHORITY, "notes/#", NOTE_ID);
-
-        sNotesProjectionMap = new HashMap<String, String>();
-        sNotesProjectionMap.put(Notes._ID, Notes._ID);
-        sNotesProjectionMap.put(Notes.TITLE, Notes.TITLE);
-        sNotesProjectionMap.put(Notes.NOTE, Notes.NOTE);
-        sNotesProjectionMap.put(Notes.CREATED_DATE, Notes.CREATED_DATE);
-        sNotesProjectionMap.put(Notes.MODIFIED_DATE, Notes.MODIFIED_DATE);
-    }
-}
diff --git a/samples/NotePad/src/com/example/android/notepad/NotesList.java b/samples/NotePad/src/com/example/android/notepad/NotesList.java
deleted file mode 100644
index ceaaa3c..0000000
--- a/samples/NotePad/src/com/example/android/notepad/NotesList.java
+++ /dev/null
@@ -1,215 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import com.example.android.notepad.NotePad.Notes;
-
-import android.app.ListActivity;
-import android.content.ComponentName;
-import android.content.ContentUris;
-import android.content.Intent;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.ContextMenu;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.ContextMenu.ContextMenuInfo;
-import android.widget.AdapterView;
-import android.widget.ListView;
-import android.widget.SimpleCursorAdapter;
-
-/**
- * Displays a list of notes. Will display notes from the {@link Uri}
- * provided in the intent if there is one, otherwise defaults to displaying the
- * contents of the {@link NotePadProvider}
- */
-public class NotesList extends ListActivity {
-    private static final String TAG = "NotesList";
-
-    // Menu item ids
-    public static final int MENU_ITEM_DELETE = Menu.FIRST;
-    public static final int MENU_ITEM_INSERT = Menu.FIRST + 1;
-
-    /**
-     * The columns we are interested in from the database
-     */
-    private static final String[] PROJECTION = new String[] {
-            Notes._ID, // 0
-            Notes.TITLE, // 1
-    };
-
-    /** The index of the title column */
-    private static final int COLUMN_INDEX_TITLE = 1;
-    
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setDefaultKeyMode(DEFAULT_KEYS_SHORTCUT);
-
-        // If no data was given in the intent (because we were started
-        // as a MAIN activity), then use our default content provider.
-        Intent intent = getIntent();
-        if (intent.getData() == null) {
-            intent.setData(Notes.CONTENT_URI);
-        }
-
-        // Inform the list we provide context menus for items
-        getListView().setOnCreateContextMenuListener(this);
-        
-        // Perform a managed query. The Activity will handle closing and requerying the cursor
-        // when needed.
-        Cursor cursor = managedQuery(getIntent().getData(), PROJECTION, null, null,
-                Notes.DEFAULT_SORT_ORDER);
-
-        // Used to map notes entries from the database to views
-        SimpleCursorAdapter adapter = new SimpleCursorAdapter(this, R.layout.noteslist_item, cursor,
-                new String[] { Notes.TITLE }, new int[] { android.R.id.text1 });
-        setListAdapter(adapter);
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        // This is our one standard application action -- inserting a
-        // new note into the list.
-        menu.add(0, MENU_ITEM_INSERT, 0, R.string.menu_insert)
-                .setShortcut('3', 'a')
-                .setIcon(android.R.drawable.ic_menu_add);
-
-        // Generate any additional actions that can be performed on the
-        // overall list.  In a normal install, there are no additional
-        // actions found here, but this allows other applications to extend
-        // our menu with their own actions.
-        Intent intent = new Intent(null, getIntent().getData());
-        intent.addCategory(Intent.CATEGORY_ALTERNATIVE);
-        menu.addIntentOptions(Menu.CATEGORY_ALTERNATIVE, 0, 0,
-                new ComponentName(this, NotesList.class), null, intent, 0, null);
-
-        return true;
-    }
-
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-        final boolean haveItems = getListAdapter().getCount() > 0;
-
-        // If there are any notes in the list (which implies that one of
-        // them is selected), then we need to generate the actions that
-        // can be performed on the current selection.  This will be a combination
-        // of our own specific actions along with any extensions that can be
-        // found.
-        if (haveItems) {
-            // This is the selected item.
-            Uri uri = ContentUris.withAppendedId(getIntent().getData(), getSelectedItemId());
-
-            // Build menu...  always starts with the EDIT action...
-            Intent[] specifics = new Intent[1];
-            specifics[0] = new Intent(Intent.ACTION_EDIT, uri);
-            MenuItem[] items = new MenuItem[1];
-
-            // ... is followed by whatever other actions are available...
-            Intent intent = new Intent(null, uri);
-            intent.addCategory(Intent.CATEGORY_ALTERNATIVE);
-            menu.addIntentOptions(Menu.CATEGORY_ALTERNATIVE, 0, 0, null, specifics, intent, 0,
-                    items);
-
-            // Give a shortcut to the edit action.
-            if (items[0] != null) {
-                items[0].setShortcut('1', 'e');
-            }
-        } else {
-            menu.removeGroup(Menu.CATEGORY_ALTERNATIVE);
-        }
-
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-        case MENU_ITEM_INSERT:
-            // Launch activity to insert a new item
-            startActivity(new Intent(Intent.ACTION_INSERT, getIntent().getData()));
-            return true;
-        }
-        return super.onOptionsItemSelected(item);
-    }
-
-    @Override
-    public void onCreateContextMenu(ContextMenu menu, View view, ContextMenuInfo menuInfo) {
-        AdapterView.AdapterContextMenuInfo info;
-        try {
-             info = (AdapterView.AdapterContextMenuInfo) menuInfo;
-        } catch (ClassCastException e) {
-            Log.e(TAG, "bad menuInfo", e);
-            return;
-        }
-
-        Cursor cursor = (Cursor) getListAdapter().getItem(info.position);
-        if (cursor == null) {
-            // For some reason the requested item isn't available, do nothing
-            return;
-        }
-
-        // Setup the menu header
-        menu.setHeaderTitle(cursor.getString(COLUMN_INDEX_TITLE));
-
-        // Add a menu item to delete the note
-        menu.add(0, MENU_ITEM_DELETE, 0, R.string.menu_delete);
-    }
-        
-    @Override
-    public boolean onContextItemSelected(MenuItem item) {
-        AdapterView.AdapterContextMenuInfo info;
-        try {
-             info = (AdapterView.AdapterContextMenuInfo) item.getMenuInfo();
-        } catch (ClassCastException e) {
-            Log.e(TAG, "bad menuInfo", e);
-            return false;
-        }
-
-        switch (item.getItemId()) {
-            case MENU_ITEM_DELETE: {
-                // Delete the note that the context menu is for
-                Uri noteUri = ContentUris.withAppendedId(getIntent().getData(), info.id);
-                getContentResolver().delete(noteUri, null, null);
-                return true;
-            }
-        }
-        return false;
-    }
-
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) {
-        Uri uri = ContentUris.withAppendedId(getIntent().getData(), id);
-        
-        String action = getIntent().getAction();
-        if (Intent.ACTION_PICK.equals(action) || Intent.ACTION_GET_CONTENT.equals(action)) {
-            // The caller is waiting for us to return a note selected by
-            // the user.  The have clicked on one, so return it now.
-            setResult(RESULT_OK, new Intent().setData(uri));
-        } else {
-            // Launch activity to view/edit the currently selected item
-            startActivity(new Intent(Intent.ACTION_EDIT, uri));
-        }
-    }
-}
diff --git a/samples/NotePad/src/com/example/android/notepad/TitleEditor.java b/samples/NotePad/src/com/example/android/notepad/TitleEditor.java
deleted file mode 100644
index 50d38e5..0000000
--- a/samples/NotePad/src/com/example/android/notepad/TitleEditor.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import com.example.android.notepad.NotePad.Notes;
-
-import android.app.Activity;
-import android.content.ContentValues;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-import android.widget.EditText;
-
-/**
- * An activity that will edit the title of a note. Displays a floating
- * window with a text field.
- */
-public class TitleEditor extends Activity implements View.OnClickListener {
-
-    /**
-     * This is a special intent action that means "edit the title of a note".
-     */
-    public static final String EDIT_TITLE_ACTION = "com.android.notepad.action.EDIT_TITLE";
-
-    /**
-     * An array of the columns we are interested in.
-     */
-    private static final String[] PROJECTION = new String[] {
-            NotePad.Notes._ID, // 0
-            NotePad.Notes.TITLE, // 1
-    };
-    /** Index of the title column */
-    private static final int COLUMN_INDEX_TITLE = 1;
-
-    /**
-     * Cursor which will provide access to the note whose title we are editing.
-     */
-    private Cursor mCursor;
-
-    /**
-     * The EditText field from our UI. Keep track of this so we can extract the
-     * text when we are finished.
-     */
-    private EditText mText;
-
-    /**
-     * The content URI to the note that's being edited.
-     */
-    private Uri mUri;
-
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        setContentView(R.layout.title_editor);
-
-        // Get the uri of the note whose title we want to edit
-        mUri = getIntent().getData();
-
-        // Get a cursor to access the note
-        mCursor = managedQuery(mUri, PROJECTION, null, null, null);
-
-        // Set up click handlers for the text field and button
-        mText = (EditText) this.findViewById(R.id.title);
-        mText.setOnClickListener(this);
-        
-        Button b = (Button) findViewById(R.id.ok);
-        b.setOnClickListener(this);
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-
-        // Initialize the text with the title column from the cursor
-        if (mCursor != null) {
-            mCursor.moveToFirst();
-            mText.setText(mCursor.getString(COLUMN_INDEX_TITLE));
-        }
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-
-        if (mCursor != null) {
-            // Write the title back to the note 
-            ContentValues values = new ContentValues();
-            values.put(Notes.TITLE, mText.getText().toString());
-            getContentResolver().update(mUri, values, null, null);
-        }
-    }
-
-    public void onClick(View v) {
-        // When the user clicks, just finish this activity.
-        // onPause will be called, and we save our data there.
-        finish();
-    }
-}
diff --git a/samples/NotePad/src/com/google/provider/NotePad.java b/samples/NotePad/src/com/google/provider/NotePad.java
deleted file mode 100644
index f8de69b..0000000
--- a/samples/NotePad/src/com/google/provider/NotePad.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/* 
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.google.provider;
-
-import android.net.Uri;
-import android.provider.BaseColumns;
-
-/**
- * Convenience definitions for NotePadProvider
- */
-public final class NotePad {
-    /**
-     * Notes table
-     */
-    public static final class Notes implements BaseColumns {
-        /**
-         * The content:// style URL for this table
-         */
-        public static final Uri CONTENT_URI
-                = Uri.parse("content://com.google.provider.NotePad/notes");
-
-        /**
-         * The default sort order for this table
-         */
-        public static final String DEFAULT_SORT_ORDER = "modified DESC";
-
-        /**
-         * The title of the note
-         * <P>Type: TEXT</P>
-         */
-        public static final String TITLE = "title";
-
-        /**
-         * The note itself
-         * <P>Type: TEXT</P>
-         */
-        public static final String NOTE = "note";
-
-        /**
-         * The timestamp for when the note was created
-         * <P>Type: INTEGER (long)</P>
-         */
-        public static final String CREATED_DATE = "created";
-
-        /**
-         * The timestamp for when the note was last modified
-         * <P>Type: INTEGER (long)</P>
-         */
-        public static final String MODIFIED_DATE = "modified";
-    }
-}
diff --git a/samples/NotePad/tests/Android.mk b/samples/NotePad/tests/Android.mk
deleted file mode 100644
index 43efafc..0000000
--- a/samples/NotePad/tests/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := NotePadTests
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_INSTRUMENTATION_FOR := NotePad
-
-include $(BUILD_PACKAGE)
diff --git a/samples/NotePad/tests/AndroidManifest.xml b/samples/NotePad/tests/AndroidManifest.xml
deleted file mode 100644
index afd502b..0000000
--- a/samples/NotePad/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-      package="com.example.android.notepad.tests">
-    
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-  <instrumentation android:name="android.test.InstrumentationTestRunner"
-      android:targetPackage="com.example.android.notepad"
-      android:label="NotePad sample tests">
-  </instrumentation>  
-  
-</manifest>
diff --git a/samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java b/samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java
deleted file mode 100644
index 452c599..0000000
--- a/samples/NotePad/tests/src/com/example/android/notepad/NotePadTest.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.notepad;
-
-import android.test.ActivityInstrumentationTestCase;
-
-import com.example.android.notepad.NotesList;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class NotePadTest extends ActivityInstrumentationTestCase<NotesList> {
-
-  public NotePadTest() {
-      super("com.example.android.notepad", NotesList.class);
-  }
-
-}
diff --git a/samples/PlatformLibrary/Android.mk b/samples/PlatformLibrary/Android.mk
deleted file mode 100644
index afb54a2..0000000
--- a/samples/PlatformLibrary/Android.mk
+++ /dev/null
@@ -1,58 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# This makefile shows how to build your own shared library that can be
-# shipped on the system of a phone, and included additional examples of
-# including JNI code with the library and writing client applications against it.
-
-LOCAL_PATH := $(call my-dir)
-
-# the library
-# ============================================================
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# This is the target being built.
-LOCAL_MODULE:= com.example.android.platform_library
-
-# Only compile source java files for the platform library.
-LOCAL_SRC_FILES := $(call all-java-files-under, java)
-
-include $(BUILD_JAVA_LIBRARY)
-
-# ============================================================
-include $(CLEAR_VARS)
-
-LOCAL_MODULE := com.example.android.platform_library.xml
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_MODULE_CLASS := ETC
-
-# This will install the file in /system/etc/permissions
-#
-LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/permissions
-
-LOCAL_SRC_FILES := $(LOCAL_MODULE)
-
-include $(BUILD_PREBUILT)
-
-# ============================================================
-
-# Also build all of the sub-targets under this one: the library's
-# associated JNI code, and a sample client of the library.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/PlatformLibrary/README.txt b/samples/PlatformLibrary/README.txt
deleted file mode 100644
index 5ce9d2f..0000000
--- a/samples/PlatformLibrary/README.txt
+++ /dev/null
@@ -1,74 +0,0 @@
-Platform Library Example
-~~~~~~~~~~~~~~~~~~~~~~~~
-
-
-This directory contains a full example of writing your own Android platform
-shared library, without changing the Android framework.  It also shows how to
-write JNI code for incorporating native code into the library, and a client
-application that uses the library.
-
-This example is ONLY for people working with the open source platform to
-create a system image that will be delivered on a device which will include
-a custom library as shown here.  It can not be used to create a third party
-shared library, which is not currently supported in Android.
-
-To declare your library to the framework, you must place a file with a .xml
-extension in the /system/etc/permissions directory with the following contents:
-
-<?xml version="1.0" encoding="utf-8"?>
-<permissions>
-    <library name="com.example.android.platform_library"
-            file="/system/framework/com.example.android.platform_library.jar"/>
-</permissions>
-
-There are three major parts of this example, supplying three distinct
-build targets and corresponding build outputs:
-
-
-com.example.android.platform_library
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-The top-level Android.mk defines the rules to build the shared library itself,
-whose target is "com.example.android.platform_library".  The code for this
-library lives under java/.
-
-Note that the product for this library is a raw .jar file, NOT a .apk, which
-means there is no manifest or resources associated with the library.
-Unfortunately this means that if you need any resources for the library, such
-as drawables or layout files, you will need to add these to the core framework
-resources under frameworks/base/res.  Please make sure when doing this that
-you do not make any of these resources public, they should not become part of
-the Android API.  In the future we will allow shared libraries to have their
-own resources.
-
-Other than that, the library is very straight-forward, and you can write
-basically whatever code you want.  You can also put code in other Java
-namespaces -- the namespace given in the <library> tag above is just the
-public unique name by which clients will link to your library, but once this
-link happens all of the Java namespaces in that library will be available
-to the client.
-
-
-libplatform_library_jni
-~~~~~~~~~~~~~~~~~~~~~~~
-
-This is an optional example of how to write JNI code associated with a
-shared library.  This code lives under jni/.  The jni/Android.mk file defines
-the rules for building the final .so in which the code lives.  This example
-provides everything needed to hook up the native code with the Java library
-and call through to it, plus a very simple JNI call.
-
-
-PlatformLibraryClient
-~~~~~~~~~~~~~~~~~~~~~
-
-This shows an example of how you can write client applications for your new
-shared library.  This code lives under client/.  Note that the example is
-simply a regular Android .apk, like all of the other .apks created by the
-build system.  The only two special things needed to use your library are:
-
-- A LOCAL_JAVA_LIBRARIES line in the Android.mk to have the build system link
-against your shared library.
-
-- A <uses-library> line in the AndroidManifest.xml to have the runtime load
-your library into the application.
diff --git a/samples/PlatformLibrary/client/Android.mk b/samples/PlatformLibrary/client/Android.mk
deleted file mode 100644
index cfd5493..0000000
--- a/samples/PlatformLibrary/client/Android.mk
+++ /dev/null
@@ -1,37 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# This makefile is an example of writing an application that will link against
-# a custom shared library included with an Android system.
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# This is the target being built.
-LOCAL_PACKAGE_NAME := PlatformLibraryClient
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-# Link against the current Android SDK.
-LOCAL_SDK_VERSION := current
-
-# Also link against our own custom library.
-LOCAL_JAVA_LIBRARIES := com.example.android.platform_library
-
-include $(BUILD_PACKAGE)
diff --git a/samples/PlatformLibrary/client/AndroidManifest.xml b/samples/PlatformLibrary/client/AndroidManifest.xml
deleted file mode 100644
index be0d9a1..0000000
--- a/samples/PlatformLibrary/client/AndroidManifest.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is an example of writing a client application for a custom
-     platform library. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.platform_library.client">
-    
-    <application android:label="Platform Lib Client">
-    
-        <!-- This tells the system about the custom library used by the
-             application, so that it can be properly loaded and linked
-             to the app when the app is initialized. -->
-        <uses-library android:name="com.example.android.platform_library" />
-        
-        <activity android:name="Client">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN"/>
-                <category android:name="android.intent.category.LAUNCHER"/>
-            </intent-filter>
-        </activity>
-    </application>
-</manifest>
diff --git a/samples/PlatformLibrary/client/src/com/example/android/platform_library/client/Client.java b/samples/PlatformLibrary/client/src/com/example/android/platform_library/client/Client.java
deleted file mode 100644
index 8722c72..0000000
--- a/samples/PlatformLibrary/client/src/com/example/android/platform_library/client/Client.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.platform_library.client;
-
-import com.example.android.platform_library.PlatformLibrary;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.TextView;
-
-/**
- * Use a custom platform library.
- */
-public class Client extends Activity {
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Call an API on the library.
-        PlatformLibrary pl = new PlatformLibrary();
-        int res = pl.getInt(false);
-        
-        // We'll just make our own view to show the result.
-        TextView tv = new TextView(this);
-        tv.setText("Got from lib: " + res);
-        setContentView(tv);
-    }
-}
-
diff --git a/samples/PlatformLibrary/com.example.android.platform_library.xml b/samples/PlatformLibrary/com.example.android.platform_library.xml
deleted file mode 100644
index b9491d8..0000000
--- a/samples/PlatformLibrary/com.example.android.platform_library.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<permissions>
-    <library name="com.example.android.platform_library"
-            file="/system/framework/com.example.android.platform_library.jar"/>
-</permissions>
diff --git a/samples/PlatformLibrary/java/com/example/android/platform_library/PlatformLibrary.java b/samples/PlatformLibrary/java/com/example/android/platform_library/PlatformLibrary.java
deleted file mode 100644
index 68154ec..0000000
--- a/samples/PlatformLibrary/java/com/example/android/platform_library/PlatformLibrary.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.platform_library;
-
-import android.util.Config;
-import android.util.Log;
-
-public final class PlatformLibrary {    
-    static {
-        /*
-         * Load the library.  If it's already loaded, this does nothing.
-         */
-        System.loadLibrary("platform_library_jni");
-    }
-
-    private int mJniInt = -1;
-
-    public PlatformLibrary() {}
-
-    /*
-     * Test native methods.
-     */
-    public int getInt(boolean bad) {
-        /* this alters mJniInt */
-        int result = getJniInt(bad);
-
-        /* reverse a string, for no very good reason */
-        String reverse = reverseString("Android!");
-
-        Log.i("PlatformLibrary", "getInt: " + result + ", '" + reverse + "'");
-
-        return mJniInt;
-    }
-
-    /*
-     * Simple method, called from native code.
-     */
-    private static void yodel(String msg) {
-        Log.d("PlatformLibrary", "yodel: " + msg);
-    }
-
-    /*
-     * Trivial native method call.  If "bad" is true, this will throw an
-     * exception.
-     */
-    native private int getJniInt(boolean bad);
-
-    /*
-     * Native method that returns a new string that is the reverse of
-     * the original.  This also calls yodel().
-     */
-    native private static String reverseString(String str);
-}
diff --git a/samples/PlatformLibrary/jni/Android.mk b/samples/PlatformLibrary/jni/Android.mk
deleted file mode 100644
index 1bdefa1..0000000
--- a/samples/PlatformLibrary/jni/Android.mk
+++ /dev/null
@@ -1,53 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# This makefile supplies the rules for building a library of JNI code for
-# use by our example platform shared library.
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# This is the target being built.
-LOCAL_MODULE:= libplatform_library_jni
-
-# All of the source files that we will compile.
-LOCAL_SRC_FILES:= \
-	PlatformLibrary.cpp
-
-# All of the shared libraries we link against.
-LOCAL_SHARED_LIBRARIES := \
-	libandroid_runtime \
-	libnativehelper \
-	libcutils \
-	libutils
-
-# No static libraries.
-LOCAL_STATIC_LIBRARIES :=
-
-# Also need the JNI headers.
-LOCAL_C_INCLUDES += \
-	$(JNI_H_INCLUDE)
-
-# No specia compiler flags.
-LOCAL_CFLAGS +=
-
-# Don't prelink this library.  For more efficient code, you may want
-# to add this library to the prelink map and set this to true.
-LOCAL_PRELINK_MODULE := false
-
-include $(BUILD_SHARED_LIBRARY)
diff --git a/samples/PlatformLibrary/jni/PlatformLibrary.cpp b/samples/PlatformLibrary/jni/PlatformLibrary.cpp
deleted file mode 100644
index ad60002..0000000
--- a/samples/PlatformLibrary/jni/PlatformLibrary.cpp
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "PlatformLibrary"
-#include "utils/Log.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <assert.h>
-
-#include "jni.h"
-
-
-// ----------------------------------------------------------------------------
-
-/*
- * Field/method IDs and class object references.
- *
- * You should not need to store the JNIEnv pointer in here.  It is
- * thread-specific and will be passed back in on every call.
- */
-static struct {
-    jclass      platformLibraryClass;
-    jfieldID    jniInt;
-    jmethodID   yodel;
-} gCachedState;
-
-// ----------------------------------------------------------------------------
-
-/*
- * Helper function to throw an arbitrary exception.
- *
- * Takes the exception class name, a format string, and one optional integer
- * argument (useful for including an error code, perhaps from errno).
- */
-static void throwException(JNIEnv* env, const char* ex, const char* fmt,
-    int data) {
-
-    if (jclass cls = env->FindClass(ex)) {
-        if (fmt != NULL) {
-            char msg[1000];
-            snprintf(msg, sizeof(msg), fmt, data);
-            env->ThrowNew(cls, msg);
-        } else {
-            env->ThrowNew(cls, NULL);
-        }
-
-        /*
-         * This is usually not necessary -- local references are released
-         * automatically when the native code returns to the VM.  It's
-         * required if the code doesn't actually return, e.g. it's sitting
-         * in a native event loop.
-         */
-        env->DeleteLocalRef(cls);
-    }
-}
-
-/*
- * Trivial sample method.
- *
- * If "bad" is true, this throws an exception.  Otherwise, this sets the
- * "mJniInt" field to 42 and returns 24.
- */
-static jint PlatformLibrary_getJniInt(JNIEnv* env, jobject thiz, jboolean bad) {
-    if (bad) {
-        throwException(env, "java/lang/IllegalStateException",
-                "you are bad", 0);
-        return 0;       /* return value will be ignored */
-    }
-    env->SetIntField(thiz, gCachedState.jniInt, 42);
-    return (jint)24;
-}
-
-/*
- * A more complex sample method.
- *
- * This takes a String as an argument, and returns a new String with
- * characters in reverse order.  The new string is passed to another method.
- * This demonstrates basic String manipulation functions and method
- * invocation.
- *
- * This method is declared "static", so there's no "this" pointer; instead,
- * we get a pointer to the class object.
- */
-static jstring PlatformLibrary_reverseString(JNIEnv* env, jclass clazz,
-    jstring str) {
-
-    if (str == NULL) {
-        throwException(env, "java/lang/NullPointerException", NULL, 0);
-        return NULL;
-    }
-
-    /*
-     * Get a pointer to the string's UTF-16 character data.  The data
-     * may be a copy or a pointer to the original.  Since String data
-     * is immutable, we're not allowed to touch it.
-     */
-    const jchar* strChars = env->GetStringChars(str, NULL);
-    if (strChars == NULL) {
-        /* something went wrong */
-        LOGW("Couldn't get string chars\n");
-        return NULL;
-    }
-    jsize strLength = env->GetStringLength(str);
-
-    /*
-     * Write a progress message to the log.  Log messages are UTF-8, so
-     * we want to convert the string to show it.
-     */
-    const char* printable = env->GetStringUTFChars(str, NULL);
-    if (printable != NULL) {
-        LOGD("Reversing string '%s'\n", printable);
-        env->ReleaseStringUTFChars(str, printable);
-    }
-
-    /*
-     * Copy the characters to temporary storage, reversing as we go.
-     */
-    jchar tempChars[strLength];
-    for (int i = 0; i < strLength; i++) {
-        tempChars[i] = strChars[strLength -1 -i];
-    }
-
-    /*
-     * Release the original String.  That way, if something fails later on,
-     * we don't have to worry about this leading to a memory leak.
-     */
-    env->ReleaseStringChars(str, strChars);
-    strChars = NULL;            /* this pointer no longer valid */
-
-    /*
-     * Create a new String with the chars.
-     */
-    jstring result = env->NewString(tempChars, strLength);
-    if (result == NULL) {
-        LOGE("NewString failed\n");
-        return NULL;
-    }
-
-    /*
-     * Now let's do something with it.  We already have the methodID for
-     * "yodel", so we can invoke it directly.  It's in our class, so we
-     * can use the Class object reference that was passed in.
-     */
-    env->CallStaticVoidMethod(clazz, gCachedState.yodel, result);
-
-    return result;
-}
-
-
-// ----------------------------------------------------------------------------
-
-/*
- * Array of methods.
- *
- * Each entry has three fields: the name of the method, the method
- * signature, and a pointer to the native implementation.
- */
-static const JNINativeMethod gMethods[] = {
-    { "getJniInt",          "(Z)I",
-                        (void*)PlatformLibrary_getJniInt },
-    { "reverseString",      "(Ljava/lang/String;)Ljava/lang/String;",
-                        (void*)PlatformLibrary_reverseString },
-};
-
-/*
- * Do some (slow-ish) lookups now and save the results.
- *
- * Returns 0 on success.
- */
-static int cacheIds(JNIEnv* env, jclass clazz) {
-    /*
-     * Save the class in case we want to use it later.  Because this is a
-     * reference to the Class object, we need to convert it to a JNI global
-     * reference.
-     */
-    gCachedState.platformLibraryClass = (jclass) env->NewGlobalRef(clazz);
-    if (clazz == NULL) {
-        LOGE("Can't create new global ref\n");
-        return -1;
-    }
-
-    /*
-     * Cache field and method IDs.  IDs are not references, which means we
-     * don't need to call NewGlobalRef on them.
-     */
-    gCachedState.jniInt = env->GetFieldID(clazz, "mJniInt", "I");
-    if (gCachedState.jniInt == NULL) {
-        LOGE("Can't find PlatformLibrary.mJniInt\n");
-        return -1;
-    }
-
-    gCachedState.yodel = env->GetStaticMethodID(clazz, "yodel",
-        "(Ljava/lang/String;)V");
-    if (gCachedState.yodel == NULL) {
-        LOGE("Can't find PlatformLibrary.yodel\n");
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Explicitly register all methods for our class.
- *
- * While we're at it, cache some class references and method/field IDs.
- *
- * Returns 0 on success.
- */
-static int registerMethods(JNIEnv* env) {
-    static const char* const kClassName =
-        "com/example/android/platform_library/PlatformLibrary";
-    jclass clazz;
-
-    /* look up the class */
-    clazz = env->FindClass(kClassName);
-    if (clazz == NULL) {
-        LOGE("Can't find class %s\n", kClassName);
-        return -1;
-    }
-
-    /* register all the methods */
-    if (env->RegisterNatives(clazz, gMethods,
-            sizeof(gMethods) / sizeof(gMethods[0])) != JNI_OK)
-    {
-        LOGE("Failed registering methods for %s\n", kClassName);
-        return -1;
-    }
-
-    /* fill out the rest of the ID cache */
-    return cacheIds(env, clazz);
-}
-
-// ----------------------------------------------------------------------------
-
-/*
- * This is called by the VM when the shared library is first loaded.
- */
-jint JNI_OnLoad(JavaVM* vm, void* reserved) {
-    JNIEnv* env = NULL;
-    jint result = -1;
-
-    if (vm->GetEnv((void**) &env, JNI_VERSION_1_4) != JNI_OK) {
-        LOGE("ERROR: GetEnv failed\n");
-        goto bail;
-    }
-    assert(env != NULL);
-
-    if (registerMethods(env) != 0) {
-        LOGE("ERROR: PlatformLibrary native registration failed\n");
-        goto bail;
-    }
-
-    /* success -- return valid version number */
-    result = JNI_VERSION_1_4;
-
-bail:
-    return result;
-}
diff --git a/samples/RSSReader/Android.mk b/samples/RSSReader/Android.mk
deleted file mode 100644
index 6f95cb4..0000000
--- a/samples/RSSReader/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := RSSReader
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
diff --git a/samples/RSSReader/AndroidManifest.xml b/samples/RSSReader/AndroidManifest.xml
deleted file mode 100644
index c59411d..0000000
--- a/samples/RSSReader/AndroidManifest.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.rssreader">
-  <uses-permission android:name="android.permission.INTERNET" />
-  <application android:label="RSS Reader">
-        <activity android:name="RssReader">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.DEFAULT" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-		</activity>
-
-  </application>
-</manifest>
diff --git a/samples/RSSReader/res/layout/rss_layout.xml b/samples/RSSReader/res/layout/rss_layout.xml
deleted file mode 100644
index 842f4f7..0000000
--- a/samples/RSSReader/res/layout/rss_layout.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
-    android:layout_width="fill_parent" 
-    android:layout_height="fill_parent"
-    android:padding="10dip"
-    android:orientation="vertical">
-
-	<EditText android:id="@+id/urltext"
-	    android:layout_width="fill_parent"
-	    android:layout_height="wrap_content"
-	    android:textSize="12sp"
-	    android:autoText="false"
-	    android:capitalize="none"
-	    android:text="@string/rss_layout_urltext_text" />
-	
-	<Button android:id="@+id/download"
-	    android:layout_width="wrap_content"
-	    android:layout_height="wrap_content"
-		android:text="@string/rss_layout_download_text" />
-	
-	<TextView android:id="@+id/statustext"
-	    android:layout_width="fill_parent"
-	    android:layout_height="wrap_content"
-	    android:autoText="false"
-	    android:capitalize="none"
-	    android:textSize="12sp"
-	    android:text="@string/rss_layout_statustext_text" />
-	
-	<ListView android:id="@android:id/list"
-	    android:layout_width="fill_parent"
-	    android:layout_height="0dip"
-	    android:layout_weight="1"
-	    android:drawSelectorOnTop="false"/>
-    
-</LinearLayout>
diff --git a/samples/RSSReader/res/values/strings.xml b/samples/RSSReader/res/values/strings.xml
deleted file mode 100644
index 83b7efe..0000000
--- a/samples/RSSReader/res/values/strings.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-
-    <string name="rss_layout_urltext_text">http://rss.slashdot.org/Slashdot/slashdot</string>
-    <string name="rss_layout_statustext_text"></string>
-    <string name="rss_layout_download_text">Download</string>
-
-</resources>
diff --git a/samples/RSSReader/src/com/example/android/rssreader/RssItem.java b/samples/RSSReader/src/com/example/android/rssreader/RssItem.java
deleted file mode 100644
index e1e798a..0000000
--- a/samples/RSSReader/src/com/example/android/rssreader/RssItem.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.rssreader;
-
-/**
- * Simple struct class to hold the data for one rss item --
- * title, link, description.
- */
-public class RssItem  {
-    private CharSequence mTitle;
-    private CharSequence mLink;
-    private CharSequence mDescription;
-    
-    public RssItem() {
-        mTitle = "";
-        mLink = "";
-        mDescription = "";
-    }
-    
-    public RssItem(CharSequence title, CharSequence link, CharSequence description) {
-        mTitle = title;
-        mLink = link;
-        mDescription = description;
-    }
-
-    public CharSequence getDescription() {
-        return mDescription;
-    }
-
-    public void setDescription(CharSequence description) {
-        mDescription = description;
-    }
-
-    public CharSequence getLink() {
-        return mLink;
-    }
-
-    public void setLink(CharSequence link) {
-        mLink = link;
-    }
-
-    public CharSequence getTitle() {
-        return mTitle;
-    }
-
-    public void setTitle(CharSequence title) {
-        mTitle = title;
-    }
-     
-// If we made this class Parcelable, the code would look like...
-
-//    public void writeToParcel(Parcel parcel) {
-//        parcel.writeString(mTitle.toString());
-//        parcel.writeString(mLink.toString());
-//        parcel.writeString(mDescription.toString());
-//    }
-//    
-//    
-//    public static Object createFromParcel(Parcel parcel) {
-//        return new RssItem(
-//                parcel.readString(),
-//                parcel.readString(),
-//                parcel.readString());
-//    }
-}
-
diff --git a/samples/RSSReader/src/com/example/android/rssreader/RssReader.java b/samples/RSSReader/src/com/example/android/rssreader/RssReader.java
deleted file mode 100644
index 2f273c4..0000000
--- a/samples/RSSReader/src/com/example/android/rssreader/RssReader.java
+++ /dev/null
@@ -1,599 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.rssreader;
-
-import org.xmlpull.v1.XmlPullParser;
-import org.xmlpull.v1.XmlPullParserException;
-
-import android.app.ListActivity;
-import android.content.Context;
-import android.content.Intent;
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.Handler;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.view.ViewGroup;
-import android.view.LayoutInflater;
-import android.widget.ArrayAdapter;
-import android.widget.Button;
-import android.widget.EditText;
-import android.widget.ListView;
-import android.widget.TextView;
-import android.widget.TwoLineListItem;
-import android.util.Xml;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * The RssReader example demonstrates forking off a thread to download
- * rss data in the background and post the results to a ListView in the UI.
- * It also shows how to display custom data in a ListView
- * with a ArrayAdapter subclass.
- * 
- * <ul>
- * <li>We own a ListView
- * <li>The ListView uses our custom RSSListAdapter which 
- * <ul>
- * <li>The adapter feeds data to the ListView
- * <li>Override of getView() in the adapter provides the display view
- * used for selected list items
- * </ul>
- * <li>Override of onListItemClick() creates an intent to open the url for that
- * RssItem in the browser.
- * <li>Download = fork off a worker thread
- * <li>The worker thread opens a network connection for the rss data
- * <li>Uses XmlPullParser to extract the rss item data
- * <li>Uses mHandler.post() to send new RssItems to the UI
- * <li>Supports onSaveInstanceState()/onRestoreInstanceState() to save list/selection state on app
- * pause, so can resume seamlessly
- * </ul>
- */
-public class RssReader extends ListActivity {
-    /**
-     * Custom list adapter that fits our rss data into the list.
-     */
-    private RSSListAdapter mAdapter;
-    
-    /**
-     * Url edit text field.
-     */
-    private EditText mUrlText;
-
-    /**
-     * Status text field.
-     */
-    private TextView mStatusText;
-
-    /**
-     * Handler used to post runnables to the UI thread.
-     */
-    private Handler mHandler;
-
-    /**
-     * Currently running background network thread.
-     */
-    private RSSWorker mWorker;
-
-    // Take this many chars from the front of the description.
-    public static final int SNIPPET_LENGTH = 90;
-    
-    
-    // Keys used for data in the onSaveInstanceState() Map.
-    public static final String STRINGS_KEY = "strings";
-
-    public static final String SELECTION_KEY = "selection";
-
-    public static final String URL_KEY = "url";
-    
-    public static final String STATUS_KEY = "status";
-
-    /**
-     * Called when the activity starts up. Do activity initialization
-     * here, not in a constructor.
-     * 
-     * @see Activity#onCreate
-     */
-    @Override
-    protected void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        
-        setContentView(R.layout.rss_layout);
-        // The above layout contains a list id "android:list"
-        // which ListActivity adopts as its list -- we can
-        // access it with getListView().
-
-        // Install our custom RSSListAdapter.
-        List<RssItem> items = new ArrayList<RssItem>();
-        mAdapter = new RSSListAdapter(this, items);
-        getListView().setAdapter(mAdapter);
-
-        // Get pointers to the UI elements in the rss_layout
-        mUrlText = (EditText)findViewById(R.id.urltext);
-        mStatusText = (TextView)findViewById(R.id.statustext);
-        
-        Button download = (Button)findViewById(R.id.download);
-        download.setOnClickListener(new OnClickListener() {
-            public void onClick(View v) {
-                doRSS(mUrlText.getText());
-            }
-        });
-
-        // Need one of these to post things back to the UI thread.
-        mHandler = new Handler();
-        
-        // NOTE: this could use the icicle as done in
-        // onRestoreInstanceState().
-    }
-
-    /**
-     * ArrayAdapter encapsulates a java.util.List of T, for presentation in a
-     * ListView. This subclass specializes it to hold RssItems and display
-     * their title/description data in a TwoLineListItem.
-     */
-    private class RSSListAdapter extends ArrayAdapter<RssItem> {
-        private LayoutInflater mInflater;
-
-        public RSSListAdapter(Context context, List<RssItem> objects) {
-            super(context, 0, objects);
-
-            mInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        }
-
-        /**
-         * This is called to render a particular item for the on screen list.
-         * Uses an off-the-shelf TwoLineListItem view, which contains text1 and
-         * text2 TextViews. We pull data from the RssItem and set it into the
-         * view. The convertView is the view from a previous getView(), so
-         * we can re-use it.
-         * 
-         * @see ArrayAdapter#getView
-         */
-        @Override
-        public View getView(int position, View convertView, ViewGroup parent) {
-            TwoLineListItem view;
-
-            // Here view may be passed in for re-use, or we make a new one.
-            if (convertView == null) {
-                view = (TwoLineListItem) mInflater.inflate(android.R.layout.simple_list_item_2,
-                        null);
-            } else {
-                view = (TwoLineListItem) convertView;
-            }
-
-            RssItem item = this.getItem(position);
-
-            // Set the item title and description into the view.
-            // This example does not render real HTML, so as a hack to make
-            // the description look better, we strip out the
-            // tags and take just the first SNIPPET_LENGTH chars.
-            view.getText1().setText(item.getTitle());
-            String descr = item.getDescription().toString();
-            descr = removeTags(descr);
-            view.getText2().setText(descr.substring(0, Math.min(descr.length(), SNIPPET_LENGTH)));
-            return view;
-        }
-
-    }
-
-    /**
-     * Simple code to strip out <tag>s -- primitive way to sortof display HTML as
-     * plain text.
-     */
-    public String removeTags(String str) {
-        str = str.replaceAll("<.*?>", " ");
-        str = str.replaceAll("\\s+", " ");
-        return str;
-    }
-
-    /**
-     * Called when user clicks an item in the list. Starts an activity to
-     * open the url for that item.
-     */
-    @Override
-    protected void onListItemClick(ListView l, View v, int position, long id) {
-        RssItem item = mAdapter.getItem(position);
-
-        // Creates and starts an intent to open the item.link url.
-        Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(item.getLink().toString()));
-        startActivity(intent);
-    }
-
-    /**
-     * Resets the output UI -- list and status text empty.
-     */
-    public void resetUI() {
-        // Reset the list to be empty.
-        List<RssItem> items = new ArrayList<RssItem>();
-        mAdapter = new RSSListAdapter(this, items);
-        getListView().setAdapter(mAdapter);
-
-        mStatusText.setText("");
-        mUrlText.requestFocus();
-    }
-
-    /**
-     * Sets the currently active running worker. Interrupts any earlier worker,
-     * so we only have one at a time.
-     * 
-     * @param worker the new worker
-     */
-    public synchronized void setCurrentWorker(RSSWorker worker) {
-        if (mWorker != null) mWorker.interrupt();
-        mWorker = worker;
-    }
-
-    /**
-     * Is the given worker the currently active one.
-     * 
-     * @param worker
-     * @return
-     */
-    public synchronized boolean isCurrentWorker(RSSWorker worker) {
-        return (mWorker == worker);
-    }
-
-    /**
-     * Given an rss url string, starts the rss-download-thread going.
-     * 
-     * @param rssUrl
-     */
-    private void doRSS(CharSequence rssUrl) {
-        RSSWorker worker = new RSSWorker(rssUrl);
-        setCurrentWorker(worker);
-
-        resetUI();
-        mStatusText.setText("Downloading\u2026");
-
-        worker.start();
-    }
-
-    /**
-     * Runnable that the worker thread uses to post RssItems to the
-     * UI via mHandler.post
-     */
-    private class ItemAdder implements Runnable {
-        RssItem mItem;
-
-        ItemAdder(RssItem item) {
-            mItem = item;
-        }
-
-        public void run() {
-            mAdapter.add(mItem);
-        }
-
-        // NOTE: Performance idea -- would be more efficient to have he option
-        // to add multiple items at once, so you get less "update storm" in the UI
-        // compared to adding things one at a time.
-    }
-
-    /**
-     * Worker thread takes in an rss url string, downloads its data, parses
-     * out the rss items, and communicates them back to the UI as they are read.
-     */
-    private class RSSWorker extends Thread {
-        private CharSequence mUrl;
-
-        public RSSWorker(CharSequence url) {
-            mUrl = url;
-        }
-
-        @Override
-        public void run() {
-            String status = "";
-            try {
-                // Standard code to make an HTTP connection.
-                URL url = new URL(mUrl.toString());
-                URLConnection connection = url.openConnection();
-                connection.setConnectTimeout(10000);
-
-                connection.connect();
-                InputStream in = connection.getInputStream();
-
-                parseRSS(in, mAdapter);
-                status = "done";
-            } catch (Exception e) {
-                status = "failed:" + e.getMessage();
-            }
-
-            // Send status to UI (unless a newer worker has started)
-            // To communicate back to the UI from a worker thread,
-            // pass a Runnable to handler.post().
-            final String temp = status;
-            if (isCurrentWorker(this)) {
-                mHandler.post(new Runnable() {
-                    public void run() {
-                        mStatusText.setText(temp);
-                    }
-                });
-            }
-        }
-    }
-
-    /**
-     * Populates the menu.
-     */
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        menu.add(0, 0, 0, "Slashdot")
-            .setOnMenuItemClickListener(new RSSMenu("http://rss.slashdot.org/Slashdot/slashdot"));
-
-        menu.add(0, 0, 0, "Google News")
-            .setOnMenuItemClickListener(new RSSMenu("http://news.google.com/?output=rss"));
-        
-        menu.add(0, 0, 0, "News.com")
-            .setOnMenuItemClickListener(new RSSMenu("http://news.com.com/2547-1_3-0-20.xml"));
-
-        menu.add(0, 0, 0, "Bad Url")
-            .setOnMenuItemClickListener(new RSSMenu("http://nifty.stanford.edu:8080"));
-
-        menu.add(0, 0, 0, "Reset")
-                .setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
-            public boolean onMenuItemClick(MenuItem item) {
-                resetUI();
-                return true;
-            }
-        });
-
-        return true;
-    }
-
-    /**
-     * Puts text in the url text field and gives it focus. Used to make a Runnable
-     * for each menu item. This way, one inner class works for all items vs. an
-     * anonymous inner class for each menu item.
-     */
-    private class RSSMenu implements MenuItem.OnMenuItemClickListener {
-        private CharSequence mUrl;
-
-        RSSMenu(CharSequence url) {
-            mUrl = url;
-        }
-
-        public boolean onMenuItemClick(MenuItem item) {
-            mUrlText.setText(mUrl);
-            mUrlText.requestFocus();
-            return true;
-        }
-    }
-
-
-    /**
-     * Called for us to save out our current state before we are paused,
-     * such a for example if the user switches to another app and memory
-     * gets scarce. The given outState is a Bundle to which we can save
-     * objects, such as Strings, Integers or lists of Strings. In this case, we
-     * save out the list of currently downloaded rss data, (so we don't have to
-     * re-do all the networking just because the user goes back and forth
-     * between aps) which item is currently selected, and the data for the text views.
-     * In onRestoreInstanceState() we look at the map to reconstruct the run-state of the
-     * application, so returning to the activity looks seamlessly correct.
-     * TODO: the Activity javadoc should give more detail about what sort of
-     * data can go in the outState map.
-     * 
-     * @see android.app.Activity#onSaveInstanceState
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    protected void onSaveInstanceState(Bundle outState) {
-        super.onSaveInstanceState(outState);
-
-        // Make a List of all the RssItem data for saving
-        // NOTE: there may be a way to save the RSSItems directly,
-        // rather than their string data.
-        int count = mAdapter.getCount();
-
-        // Save out the items as a flat list of CharSequence objects --
-        // title0, link0, descr0, title1, link1, ...
-        ArrayList<CharSequence> strings = new ArrayList<CharSequence>();
-        for (int i = 0; i < count; i++) {
-            RssItem item = mAdapter.getItem(i);
-            strings.add(item.getTitle());
-            strings.add(item.getLink());
-            strings.add(item.getDescription());
-        }
-        outState.putSerializable(STRINGS_KEY, strings);
-
-        // Save current selection index (if focussed)
-        if (getListView().hasFocus()) {
-            outState.putInt(SELECTION_KEY, Integer.valueOf(getListView().getSelectedItemPosition()));
-        }
-
-        // Save url
-        outState.putString(URL_KEY, mUrlText.getText().toString());
-        
-        // Save status
-        outState.putCharSequence(STATUS_KEY, mStatusText.getText());
-    }
-
-    /**
-     * Called to "thaw" re-animate the app from a previous onSaveInstanceState().
-     * 
-     * @see android.app.Activity#onRestoreInstanceState
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    protected void onRestoreInstanceState(Bundle state) {
-        super.onRestoreInstanceState(state);
-
-        // Note: null is a legal value for onRestoreInstanceState.
-        if (state == null) return;
-
-        // Restore items from the big list of CharSequence objects
-        List<CharSequence> strings = (ArrayList<CharSequence>)state.getSerializable(STRINGS_KEY);
-        List<RssItem> items = new ArrayList<RssItem>();
-        for (int i = 0; i < strings.size(); i += 3) {
-            items.add(new RssItem(strings.get(i), strings.get(i + 1), strings.get(i + 2)));
-        }
-
-        // Reset the list view to show this data.
-        mAdapter = new RSSListAdapter(this, items);
-        getListView().setAdapter(mAdapter);
-
-        // Restore selection
-        if (state.containsKey(SELECTION_KEY)) {
-            getListView().requestFocus(View.FOCUS_FORWARD);
-            // todo: is above right? needed it to work
-            getListView().setSelection(state.getInt(SELECTION_KEY));
-        }
-        
-        // Restore url
-        mUrlText.setText(state.getCharSequence(URL_KEY));
-        
-        // Restore status
-        mStatusText.setText(state.getCharSequence(STATUS_KEY));
-    }
-
-    
-    
-    /**
-     * Does rudimentary RSS parsing on the given stream and posts rss items to
-     * the UI as they are found. Uses Android's XmlPullParser facility. This is
-     * not a production quality RSS parser -- it just does a basic job of it.
-     * 
-     * @param in stream to read
-     * @param adapter adapter for ui events
-     */
-    void parseRSS(InputStream in, RSSListAdapter adapter) throws IOException,
-            XmlPullParserException {
-        // TODO: switch to sax
-
-        XmlPullParser xpp = Xml.newPullParser();
-        xpp.setInput(in, null);  // null = parser figures out encoding
-
-        int eventType;
-        String title = "";
-        String link = "";
-        String description = "";
-        eventType = xpp.getEventType();
-        while (eventType != XmlPullParser.END_DOCUMENT) {
-            if (eventType == XmlPullParser.START_TAG) {
-                String tag = xpp.getName();
-                if (tag.equals("item")) {
-                    title = link = description = "";
-                } else if (tag.equals("title")) {
-                    xpp.next(); // Skip to next element -- assume text is directly inside the tag
-                    title = xpp.getText();
-                } else if (tag.equals("link")) {
-                    xpp.next();
-                    link = xpp.getText();
-                } else if (tag.equals("description")) {
-                    xpp.next();
-                    description = xpp.getText();
-                }
-            } else if (eventType == XmlPullParser.END_TAG) {
-                // We have a comlete item -- post it back to the UI
-                // using the mHandler (necessary because we are not
-                // running on the UI thread).
-                String tag = xpp.getName();
-                if (tag.equals("item")) {
-                    RssItem item = new RssItem(title, link, description);
-                    mHandler.post(new ItemAdder(item));
-                }
-            }
-            eventType = xpp.next();
-        }
-    }
-    
-    // SAX version of the code to do the parsing.
-    /*
-    private class RSSHandler extends DefaultHandler {
-        RSSListAdapter mAdapter;
-        
-        String mTitle;
-        String mLink;
-        String mDescription;
-        
-        StringBuilder mBuff;
-        
-        boolean mInItem;
-        
-        public RSSHandler(RSSListAdapter adapter) {
-            mAdapter = adapter;
-            mInItem = false;
-            mBuff = new StringBuilder();
-        }
-        
-        public void startElement(String uri,
-                String localName,
-                String qName,
-                Attributes atts)
-                throws SAXException {
-            String tag = localName;
-            if (tag.equals("")) tag = qName;
-            
-            // If inside <item>, clear out buff on each tag start
-            if (mInItem) {
-                mBuff.delete(0, mBuff.length());
-            }
-            
-            if (tag.equals("item")) {
-                mTitle = mLink = mDescription = "";
-                mInItem = true;
-            }
-        }
-        
-        public void characters(char[] ch,
-                      int start,
-                      int length)
-                      throws SAXException {
-            // Buffer up all the chars when inside <item>
-            if (mInItem) mBuff.append(ch, start, length);
-        }
-                      
-        public void endElement(String uri,
-                      String localName,
-                      String qName)
-                      throws SAXException {
-            String tag = localName;
-            if (tag.equals("")) tag = qName;
-            
-            // For each tag, copy buff chars to right variable
-            if (tag.equals("title")) mTitle = mBuff.toString();
-            else if (tag.equals("link")) mLink = mBuff.toString();
-            if (tag.equals("description")) mDescription = mBuff.toString();
-            
-            // Have all the data at this point .... post it to the UI.
-            if (tag.equals("item")) {
-                RssItem item = new RssItem(mTitle, mLink, mDescription);
-                mHandler.post(new ItemAdder(item));
-                mInItem = false;
-            }
-        }
-    }
-    */
-    
-    /*
-    public void parseRSS2(InputStream in, RSSListAdapter adapter) throws IOException {
-            SAXParser parser = SAXParserFactory.newInstance().newSAXParser();
-            DefaultHandler handler = new RSSHandler(adapter);
-            
-            parser.parse(in, handler);
-            // TODO: does the parser figure out the encoding right on its own?
-    }
-    */
-}
diff --git a/samples/SimpleJNI/Android.mk b/samples/SimpleJNI/Android.mk
deleted file mode 100644
index a45ada8..0000000
--- a/samples/SimpleJNI/Android.mk
+++ /dev/null
@@ -1,40 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# This makefile shows how to build a shared library and an activity that
-# bundles the shared library and calls it using JNI.
-
-TOP_LOCAL_PATH:= $(call my-dir)
-
-# Build activity
-
-LOCAL_PATH:= $(TOP_LOCAL_PATH)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_PACKAGE_NAME := SimpleJNI
-
-LOCAL_JNI_SHARED_LIBRARIES := libsimplejni
-
-include $(BUILD_PACKAGE)
-
-# ============================================================
-
-# Also build all of the sub-targets under this one: the shared library.
-include $(call all-makefiles-under,$(LOCAL_PATH))
\ No newline at end of file
diff --git a/samples/SimpleJNI/AndroidManifest.xml b/samples/SimpleJNI/AndroidManifest.xml
deleted file mode 100644
index b163d55..0000000
--- a/samples/SimpleJNI/AndroidManifest.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This is an example of writing an application that bundles a
-     native code library. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-      package="com.example.android.simplejni">
-    <application android:label="Simple JNI">
-        <activity android:name="SimpleJNI">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest> 
\ No newline at end of file
diff --git a/samples/SimpleJNI/jni/Android.mk b/samples/SimpleJNI/jni/Android.mk
deleted file mode 100644
index 528196b..0000000
--- a/samples/SimpleJNI/jni/Android.mk
+++ /dev/null
@@ -1,54 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# This makefile supplies the rules for building a library of JNI code for
-# use by our example of how to bundle a shared library with an APK.
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# This is the target being built.
-LOCAL_MODULE:= libsimplejni
-
-
-# All of the source files that we will compile.
-LOCAL_SRC_FILES:= \
-  native.cpp
-
-# All of the shared libraries we link against.
-LOCAL_SHARED_LIBRARIES := \
-	libutils
-
-# No static libraries.
-LOCAL_STATIC_LIBRARIES :=
-
-# Also need the JNI headers.
-LOCAL_C_INCLUDES += \
-	$(JNI_H_INCLUDE)
-
-# No special compiler flags.
-LOCAL_CFLAGS +=
-
-# Don't prelink this library.  For more efficient code, you may want
-# to add this library to the prelink map and set this to true. However,
-# it's difficult to do this for applications that are not supplied as
-# part of a system image.
-
-LOCAL_PRELINK_MODULE := false
-
-include $(BUILD_SHARED_LIBRARY)
diff --git a/samples/SimpleJNI/jni/native.cpp b/samples/SimpleJNI/jni/native.cpp
deleted file mode 100644
index 4d2e4e0..0000000
--- a/samples/SimpleJNI/jni/native.cpp
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#define LOG_TAG "simplejni native.cpp"
-#include <utils/Log.h>
-
-#include <stdio.h>
-
-#include "jni.h"
-
-static jint
-add(JNIEnv *env, jobject thiz, jint a, jint b) {
-int result = a + b;
-    LOGI("%d + %d = %d", a, b, result);
-    return result;
-}
-
-static const char *classPathName = "com/example/android/simplejni/Native";
-
-static JNINativeMethod methods[] = {
-  {"add", "(II)I", (void*)add },
-};
-
-/*
- * Register several native methods for one class.
- */
-static int registerNativeMethods(JNIEnv* env, const char* className,
-    JNINativeMethod* gMethods, int numMethods)
-{
-    jclass clazz;
-
-    clazz = env->FindClass(className);
-    if (clazz == NULL) {
-        LOGE("Native registration unable to find class '%s'", className);
-        return JNI_FALSE;
-    }
-    if (env->RegisterNatives(clazz, gMethods, numMethods) < 0) {
-        LOGE("RegisterNatives failed for '%s'", className);
-        return JNI_FALSE;
-    }
-
-    return JNI_TRUE;
-}
-
-/*
- * Register native methods for all classes we know about.
- *
- * returns JNI_TRUE on success.
- */
-static int registerNatives(JNIEnv* env)
-{
-  if (!registerNativeMethods(env, classPathName,
-                 methods, sizeof(methods) / sizeof(methods[0]))) {
-    return JNI_FALSE;
-  }
-
-  return JNI_TRUE;
-}
-
-
-// ----------------------------------------------------------------------------
-
-/*
- * This is called by the VM when the shared library is first loaded.
- */
- 
-typedef union {
-    JNIEnv* env;
-    void* venv;
-} UnionJNIEnvToVoid;
-
-jint JNI_OnLoad(JavaVM* vm, void* reserved)
-{
-    UnionJNIEnvToVoid uenv;
-    uenv.venv = NULL;
-    jint result = -1;
-    JNIEnv* env = NULL;
-    
-    LOGI("JNI_OnLoad");
-
-    if (vm->GetEnv(&uenv.venv, JNI_VERSION_1_4) != JNI_OK) {
-        LOGE("ERROR: GetEnv failed");
-        goto bail;
-    }
-    env = uenv.env;
-
-    if (registerNatives(env) != JNI_TRUE) {
-        LOGE("ERROR: registerNatives failed");
-        goto bail;
-    }
-    
-    result = JNI_VERSION_1_4;
-    
-bail:
-    return result;
-}
diff --git a/samples/SimpleJNI/src/com/example/android/simplejni/SimpleJNI.java b/samples/SimpleJNI/src/com/example/android/simplejni/SimpleJNI.java
deleted file mode 100644
index e83cd21..0000000
--- a/samples/SimpleJNI/src/com/example/android/simplejni/SimpleJNI.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.simplejni;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.widget.TextView;
-
-public class SimpleJNI extends Activity {
-    /** Called when the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        TextView tv = new TextView(this);
-        int sum = Native.add(2, 3);
-        tv.setText("2 + 3 = " + Integer.toString(sum));
-        setContentView(tv);
-    }
-}
-
-class Native {
-    static {
-    	// The runtime will add "lib" on the front and ".o" on the end of
-    	// the name supplied to loadLibrary.
-        System.loadLibrary("simplejni");
-    }
-
-    static native int add(int a, int b);
-}
diff --git a/samples/SkeletonApp/Android.mk b/samples/SkeletonApp/Android.mk
deleted file mode 100644
index 5bada02..0000000
--- a/samples/SkeletonApp/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := SkeletonApp
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/SkeletonApp/AndroidManifest.xml b/samples/SkeletonApp/AndroidManifest.xml
deleted file mode 100644
index b0b4ef2..0000000
--- a/samples/SkeletonApp/AndroidManifest.xml
+++ /dev/null
@@ -1,58 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file describes the code in the SkeletonApp package, which is
-     used by the system to determine how to start your application and
-     integrate it with the rest of the system.  -->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.skeletonapp">
-
-    <!-- This package contains an application...  The 'label' is the name
-         to display to the user for the overall application, and provides
-         a default label for all following components.  The syntax here is a
-         reference to one of our string resources.-->
-    <application android:label="@string/skeleton_app">
-
-        <!-- An Activity in the application - this is something the user
-             can launch and interact with.  The "name" attribute is the
-             name of the class within your package that implements this
-             activity. -->
-        <activity android:name="SkeletonActivity">
-
-            <!-- An IntentFilter tells the system when it should use your
-                 activity.  This allows the user to get to your activity
-                 without someone having to explicitly know to launch your
-                 class "com.examplel.android.skeletonapp.SkeletonActivity". -->
-            <intent-filter>
-                <!-- The MAIN action describes a main entry point into an
-                     activity, without any associated data. -->
-                <action android:name="android.intent.action.MAIN" />
-
-                <!-- This places this activity into the main app list. -->
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-
-        </activity>
-
-    </application>
-
-</manifest>
diff --git a/samples/SkeletonApp/readme.txt b/samples/SkeletonApp/readme.txt
deleted file mode 100644
index 1ebddbd..0000000
--- a/samples/SkeletonApp/readme.txt
+++ /dev/null
@@ -1,65 +0,0 @@
-Android Skeleton App
-~~~~~~~~~~~~~~~~~~~~
-
-
-This directory contains the full implementation of a basic application for
-the Android platform, demonstrating the basic facilities that applications
-will use.  You can run the application either directly from the "test"
-list in the app launcher (it is named Skeleton App) or by selecting it from
-the top list in the Sample Code app.
-
-The files contained here:
-
-
-AndroidManifest.xml
-
-This XML file describes to the Android platform what your application can do.
-It is a required file, and is the mechanism you use to show your application
-to the user (in the app launcher's list), handle data types, etc.
-
-
-src/*
-
-Under this directory is the Java source for for your application.
-
-
-src/com/android/skeletonapp/SkeletonActivity.java
-
-This is the implementation of the "activity" feature described in
-AndroidManifest.xml.  The path each class implementation is
-{src/PACKAGE/CLASS.java}, where PACKAGE comes from the name in the <package>
-tag and CLASS comes from the class in the <activity> tag.
-
-
-res/*
-
-Under this directory are the resources for your application.
-
-
-res/layout/skeleton_activity.xml
-
-The res/layout/ directory contains XML files describing user interface
-view hierarchies.  The skeleton_activity.xml file here is used by
-SkeletonActivity.java to construct its UI.  The base name of each file
-(all text before a '.' character) is taken as the resource name;
-it must be lower-case.
-
-
-res/drawable/violet.png
-
-The res/drawable/ directory contains images and other things that can be
-drawn to the screen.  These can be bitmaps (in .png or .jpeg format) or
-special XML files describing more complex drawings.  The violet.png file
-here is used as the image to display in one of the views in
-skeleton_activity.xml.  Like layout files, the base name is used for the
-resulting resource name.
-
-
-res/values/colors.xml
-res/values/strings.xml
-res/values/styles.xml
-
-These XML files describe additional resources included in the application.
-They all use the same syntax; all of these resources could be defined in one
-file, but we generally split them apart as shown here to keep things organized.
-
diff --git a/samples/SkeletonApp/res/drawable/violet.jpg b/samples/SkeletonApp/res/drawable/violet.jpg
deleted file mode 100644
index d892c40..0000000
--- a/samples/SkeletonApp/res/drawable/violet.jpg
+++ /dev/null
Binary files differ
diff --git a/samples/SkeletonApp/res/layout/skeleton_activity.xml b/samples/SkeletonApp/res/layout/skeleton_activity.xml
deleted file mode 100644
index b8dcac7..0000000
--- a/samples/SkeletonApp/res/layout/skeleton_activity.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file describes the layout of the main SkeletonApp activity
-     user interface.
- -->
-
-<!-- The top view is a layout manager that places its child views into
-     a row, here set to be vertical (so the first is at the top) -->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent" android:layout_height="fill_parent"
-    android:orientation="vertical">
-
-    <!-- First view is a text editor.  We want it to use all available
-         horizontal space, and stretch to fill whatever vertical space
-         is available to it.  Note the use of the "id" attribute, which
-         allows us to find this object from the Java code. -->
-    <EditText android:id="@+id/editor"
-        android:layout_width="fill_parent" android:layout_height="0dip"
-        android:autoText="true"
-        android:capitalize="sentences"
-        android:layout_weight="1"
-        android:freezesText="true" >
-        <requestFocus />
-    </EditText>
-
-    <!-- Next view is another linear layout manager, now horizontal.  We
-         give it a custom background; see colors.xml for the definition
-         of drawable/semi_black-->
-    <LinearLayout
-        android:layout_width="wrap_content" android:layout_height="wrap_content"
-        android:layout_gravity="center_vertical" android:gravity="center_horizontal"
-        android:orientation="horizontal"
-        android:background="@drawable/semi_black">
-
-        <!-- On the left: the "back" button.  See styles.xml for the
-             definition of style/ActionButton, which we use to hold
-             common attributes that are used for both this and the
-             clear button.  See strings.xml for the definition of
-             string/back. -->
-        <Button android:id="@+id/back" style="@style/ActionButton"
-            android:text="@string/back" />
-
-        <!-- In the middle: a custom image, -->
-        <ImageView android:id="@+id/image"
-            android:layout_width="wrap_content" android:layout_height="wrap_content"
-            android:paddingLeft="4dip" android_paddingRight="4dip"
-            android:src="@drawable/violet" />
-
-        <!-- On the right: another button, this time with its text color
-             changed to red.  Again, see colors.xml for the definition. -->
-        <Button android:id="@+id/clear" style="@style/ActionButton"
-            android:text="@string/clear" android:textColor="@color/red" />
-
-    </LinearLayout>
-
-</LinearLayout>
-
-
diff --git a/samples/SkeletonApp/res/values/colors.xml b/samples/SkeletonApp/res/values/colors.xml
deleted file mode 100644
index 1d985bc..0000000
--- a/samples/SkeletonApp/res/values/colors.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file contains resource definitions for solid colors.  In
-     addition to plain color resources (retrieved via Resources.getColor()
-     and friends), we are also using it to define drawables that are
-     a solid color. -->
-
-<resources>
-    <!-- Retrieved via Resources.getColor() and friends. -->
-    <color name="red">#f00</color>
-
-    <!-- Retrieved via Resources.getDrawable() and friends. -->
-    <drawable name="semi_black">#80000000</drawable>
-</resources>
diff --git a/samples/SkeletonApp/res/values/strings.xml b/samples/SkeletonApp/res/values/strings.xml
deleted file mode 100644
index 4dc998d..0000000
--- a/samples/SkeletonApp/res/values/strings.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file contains resource definitions for displayed strings, allowing
-     them to be changed based on the locale and options. -->
-
-<resources>
-    <!-- Simple strings. -->
-    <string name="skeleton_app">Skeleton App</string>
-    <string name="back">Back</string>
-    <string name="clear">Clear</string>
-
-    <!-- This is a complex string containing style runs. -->
-    <string name="main_label">Hello <u>th<ignore>e</ignore>re</u>, <i>you</i> <b>Activity</b>!</string>
-</resources>
-
diff --git a/samples/SkeletonApp/res/values/styles.xml b/samples/SkeletonApp/res/values/styles.xml
deleted file mode 100644
index 050514f..0000000
--- a/samples/SkeletonApp/res/values/styles.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- This file contains resource definitions for style.  A style is
-     a collection of named values that can be applied as a group.  Here,
-     we are using a style to define a common set of XML attributes that
-     will be used in multiple tags. -->
-
-<resources>
-    <style name="ActionButton">
-        <item name="android:layout_width">wrap_content</item>
-        <item name="android:layout_height">wrap_content</item>
-        <item name="android:textAppearance">@style/TextAppearance.ActionButton</item>
-    </style>
-
-    <style name="TextAppearance" parent="android:TextAppearance">
-    </style>
-
-    <style name="TextAppearance.ActionButton">
-        <item name="android:textStyle">italic</item>
-    </style>
-
-</resources>
-
diff --git a/samples/SkeletonApp/src/com/example/android/skeletonapp/SkeletonActivity.java b/samples/SkeletonApp/src/com/example/android/skeletonapp/SkeletonActivity.java
deleted file mode 100644
index 7abf3ae..0000000
--- a/samples/SkeletonApp/src/com/example/android/skeletonapp/SkeletonActivity.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.skeletonapp;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.KeyEvent;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.view.View.OnClickListener;
-import android.widget.Button;
-import android.widget.EditText;
-
-/**
- * This class provides a basic demonstration of how to write an Android
- * activity. Inside of its window, it places a single view: an EditText that
- * displays and edits some internal text.
- */
-public class SkeletonActivity extends Activity {
-    
-    static final private int BACK_ID = Menu.FIRST;
-    static final private int CLEAR_ID = Menu.FIRST + 1;
-
-    private EditText mEditor;
-    
-    public SkeletonActivity() {
-    }
-
-    /** Called with the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // Inflate our UI from its XML layout description.
-        setContentView(R.layout.skeleton_activity);
-
-        // Find the text editor view inside the layout, because we
-        // want to do various programmatic things with it.
-        mEditor = (EditText) findViewById(R.id.editor);
-
-        // Hook up button presses to the appropriate event handler.
-        ((Button) findViewById(R.id.back)).setOnClickListener(mBackListener);
-        ((Button) findViewById(R.id.clear)).setOnClickListener(mClearListener);
-        
-        mEditor.setText(getText(R.string.main_label));
-    }
-
-    /**
-     * Called when the activity is about to start interacting with the user.
-     */
-    @Override
-    protected void onResume() {
-        super.onResume();
-    }
-
-    /**
-     * Called when your activity's options menu needs to be created.
-     */
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-
-        // We are going to create two menus. Note that we assign them
-        // unique integer IDs, labels from our string resources, and
-        // given them shortcuts.
-        menu.add(0, BACK_ID, 0, R.string.back).setShortcut('0', 'b');
-        menu.add(0, CLEAR_ID, 0, R.string.clear).setShortcut('1', 'c');
-
-        return true;
-    }
-
-    /**
-     * Called right before your activity's option menu is displayed.
-     */
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-
-        // Before showing the menu, we need to decide whether the clear
-        // item is enabled depending on whether there is text to clear.
-        menu.findItem(CLEAR_ID).setVisible(mEditor.getText().length() > 0);
-
-        return true;
-    }
-
-    /**
-     * Called when a menu item is selected.
-     */
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-        case BACK_ID:
-            finish();
-            return true;
-        case CLEAR_ID:
-            mEditor.setText("");
-            return true;
-        }
-
-        return super.onOptionsItemSelected(item);
-    }
-
-    /**
-     * A call-back for when the user presses the back button.
-     */
-    OnClickListener mBackListener = new OnClickListener() {
-        public void onClick(View v) {
-            finish();
-        }
-    };
-
-    /**
-     * A call-back for when the user presses the clear button.
-     */
-    OnClickListener mClearListener = new OnClickListener() {
-        public void onClick(View v) {
-            mEditor.setText("");
-        }
-    };
-}
diff --git a/samples/SkeletonApp/tests/Android.mk b/samples/SkeletonApp/tests/Android.mk
deleted file mode 100644
index 7f26bfa..0000000
--- a/samples/SkeletonApp/tests/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := SkeletonAppTests
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_INSTRUMENTATION_FOR := SkeletonApp
-
-include $(BUILD_PACKAGE)
diff --git a/samples/SkeletonApp/tests/AndroidManifest.xml b/samples/SkeletonApp/tests/AndroidManifest.xml
deleted file mode 100644
index fac1f41..0000000
--- a/samples/SkeletonApp/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-      package="com.example.android.skeletonapp.tests">
-    
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-  <instrumentation android:name="android.test.InstrumentationTestRunner"
-      android:targetPackage="com.example.android.skeletonapp"
-      android:label="SkeletonApp sample tests">
-  </instrumentation>  
-  
-</manifest>
diff --git a/samples/SkeletonApp/tests/src/com/example/android/skeletonapp/SkeletonAppTest.java b/samples/SkeletonApp/tests/src/com/example/android/skeletonapp/SkeletonAppTest.java
deleted file mode 100644
index 3123348..0000000
--- a/samples/SkeletonApp/tests/src/com/example/android/skeletonapp/SkeletonAppTest.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.skeletonapp;
-
-import android.test.ActivityInstrumentationTestCase;
-
-import com.example.android.skeletonapp.SkeletonActivity;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class SkeletonAppTest extends ActivityInstrumentationTestCase<SkeletonActivity> {
-
-  public SkeletonAppTest() {
-      super("com.example.android.skeletonapp", SkeletonActivity.class);
-  }
-}
diff --git a/samples/Snake/Android.mk b/samples/Snake/Android.mk
deleted file mode 100644
index 56b642e..0000000
--- a/samples/Snake/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := Snake
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/samples/Snake/AndroidManifest.xml b/samples/Snake/AndroidManifest.xml
deleted file mode 100644
index 174e8b4..0000000
--- a/samples/Snake/AndroidManifest.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- Declare the contents of this Android application.  The namespace
-     attribute brings in the Android platform namespace, and the package
-     supplies a unique name for the application.  When writing your
-     own application, the package name must be changed from "com.example.*"
-     to come from a domain that you own or have control over. -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-    package="com.example.android.snake">
-    <application android:label="Snake on a Phone">
-      <activity android:name="Snake"
-        android:screenOrientation="portrait"
-        android:configChanges="keyboardHidden|orientation">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest> 
diff --git a/samples/Snake/MODULE_LICENSE_APACHE2 b/samples/Snake/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/samples/Snake/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/samples/Snake/res/drawable/greenstar.png b/samples/Snake/res/drawable/greenstar.png
deleted file mode 100644
index 26be5c8..0000000
--- a/samples/Snake/res/drawable/greenstar.png
+++ /dev/null
Binary files differ
diff --git a/samples/Snake/res/drawable/redstar.png b/samples/Snake/res/drawable/redstar.png
deleted file mode 100644
index e9c0947..0000000
--- a/samples/Snake/res/drawable/redstar.png
+++ /dev/null
Binary files differ
diff --git a/samples/Snake/res/drawable/yellowstar.png b/samples/Snake/res/drawable/yellowstar.png
deleted file mode 100644
index 134b234..0000000
--- a/samples/Snake/res/drawable/yellowstar.png
+++ /dev/null
Binary files differ
diff --git a/samples/Snake/res/layout/snake_layout.xml b/samples/Snake/res/layout/snake_layout.xml
deleted file mode 100644
index 583c0c4..0000000
--- a/samples/Snake/res/layout/snake_layout.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-	android:layout_width="fill_parent"
-	android:layout_height="fill_parent">
-	
-	<com.example.android.snake.SnakeView
-	 android:id="@+id/snake"
-		android:layout_width="fill_parent"
-                android:layout_height="fill_parent"
-                tileSize="24"
-                />
-	
-	<RelativeLayout
-		android:layout_width="fill_parent"
-		android:layout_height="fill_parent" >
-		
-		<TextView
-		 android:id="@+id/text"
-			android:text="@string/snake_layout_text_text"
-			android:visibility="visible"
-			android:layout_width="wrap_content"
-			android:layout_height="wrap_content"
-			android:layout_centerInParent="true"
-			android:gravity="center_horizontal"
-			android:textColor="#ff8888ff"
-			android:textSize="24sp"/>
-	</RelativeLayout>
-</FrameLayout>
diff --git a/samples/Snake/res/values/attrs.xml b/samples/Snake/res/values/attrs.xml
deleted file mode 100644
index c846864..0000000
--- a/samples/Snake/res/values/attrs.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-  <declare-styleable name="TileView">
-    <attr name="tileSize" format="integer" />
-  </declare-styleable>
-</resources>
-
diff --git a/samples/Snake/res/values/strings.xml b/samples/Snake/res/values/strings.xml
deleted file mode 100644
index 3c4a89d..0000000
--- a/samples/Snake/res/values/strings.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2007 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-  <string name="mode_ready">Snake\nPress Up To Play</string>
-  <string name="mode_pause">Paused\nPress Up To Resume</string>
-  <string name="mode_lose_prefix">Game Over\nScore: </string>
-  <string name="mode_lose_suffix">\nPress Up To Play</string>
-
-    <string name="snake_layout_text_text"></string>
-</resources>
diff --git a/samples/Snake/src/com/example/android/snake/Snake.java b/samples/Snake/src/com/example/android/snake/Snake.java
deleted file mode 100644
index 5fdc024..0000000
--- a/samples/Snake/src/com/example/android/snake/Snake.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.snake;
-
-import android.app.Activity;
-import android.os.Bundle;
-import android.view.Window;
-import android.widget.TextView;
-
-/**
- * Snake: a simple game that everyone can enjoy.
- * 
- * This is an implementation of the classic Game "Snake", in which you control a
- * serpent roaming around the garden looking for apples. Be careful, though,
- * because when you catch one, not only will you become longer, but you'll move
- * faster. Running into yourself or the walls will end the game.
- * 
- */
-public class Snake extends Activity {
-
-    private SnakeView mSnakeView;
-    
-    private static String ICICLE_KEY = "snake-view";
-
-    /**
-     * Called when Activity is first created. Turns off the title bar, sets up
-     * the content views, and fires up the SnakeView.
-     * 
-     */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-
-        // No Title bar
-        requestWindowFeature(Window.FEATURE_NO_TITLE);
-
-        setContentView(R.layout.snake_layout);
-
-        mSnakeView = (SnakeView) findViewById(R.id.snake);
-        mSnakeView.setTextView((TextView) findViewById(R.id.text));
-
-        if (savedInstanceState == null) {
-            // We were just launched -- set up a new game
-            mSnakeView.setMode(SnakeView.READY);
-        } else {
-            // We are being restored
-            Bundle map = savedInstanceState.getBundle(ICICLE_KEY);
-            if (map != null) {
-                mSnakeView.restoreState(map);
-            } else {
-                mSnakeView.setMode(SnakeView.PAUSE);
-            }
-        }
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-        // Pause the game along with the activity
-        mSnakeView.setMode(SnakeView.PAUSE);
-    }
-
-    @Override
-    public void onSaveInstanceState(Bundle outState) {
-        //Store the game state
-        outState.putBundle(ICICLE_KEY, mSnakeView.saveState());
-    }
-
-}
diff --git a/samples/Snake/src/com/example/android/snake/SnakeView.java b/samples/Snake/src/com/example/android/snake/SnakeView.java
deleted file mode 100644
index 8dd0232..0000000
--- a/samples/Snake/src/com/example/android/snake/SnakeView.java
+++ /dev/null
@@ -1,553 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.snake;
-
-import java.util.ArrayList;
-import java.util.Random;
-
-import android.content.Context;
-import android.content.res.Resources;
-import android.os.Handler;
-import android.os.Message;
-import android.util.AttributeSet;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.KeyEvent;
-import android.view.View;
-import android.widget.TextView;
-
-/**
- * SnakeView: implementation of a simple game of Snake
- * 
- * 
- */
-public class SnakeView extends TileView {
-
-    private static final String TAG = "SnakeView";
-
-    /**
-     * Current mode of application: READY to run, RUNNING, or you have already
-     * lost. static final ints are used instead of an enum for performance
-     * reasons.
-     */
-    private int mMode = READY;
-    public static final int PAUSE = 0;
-    public static final int READY = 1;
-    public static final int RUNNING = 2;
-    public static final int LOSE = 3;
-
-    /**
-     * Current direction the snake is headed.
-     */
-    private int mDirection = NORTH;
-    private int mNextDirection = NORTH;
-    private static final int NORTH = 1;
-    private static final int SOUTH = 2;
-    private static final int EAST = 3;
-    private static final int WEST = 4;
-
-    /**
-     * Labels for the drawables that will be loaded into the TileView class
-     */
-    private static final int RED_STAR = 1;
-    private static final int YELLOW_STAR = 2;
-    private static final int GREEN_STAR = 3;
-
-    /**
-     * mScore: used to track the number of apples captured mMoveDelay: number of
-     * milliseconds between snake movements. This will decrease as apples are
-     * captured.
-     */
-    private long mScore = 0;
-    private long mMoveDelay = 600;
-    /**
-     * mLastMove: tracks the absolute time when the snake last moved, and is used
-     * to determine if a move should be made based on mMoveDelay.
-     */
-    private long mLastMove;
-    
-    /**
-     * mStatusText: text shows to the user in some run states
-     */
-    private TextView mStatusText;
-
-    /**
-     * mSnakeTrail: a list of Coordinates that make up the snake's body
-     * mAppleList: the secret location of the juicy apples the snake craves.
-     */
-    private ArrayList<Coordinate> mSnakeTrail = new ArrayList<Coordinate>();
-    private ArrayList<Coordinate> mAppleList = new ArrayList<Coordinate>();
-
-    /**
-     * Everyone needs a little randomness in their life
-     */
-    private static final Random RNG = new Random();
-
-    /**
-     * Create a simple handler that we can use to cause animation to happen.  We
-     * set ourselves as a target and we can use the sleep()
-     * function to cause an update/invalidate to occur at a later date.
-     */
-    private RefreshHandler mRedrawHandler = new RefreshHandler();
-
-    class RefreshHandler extends Handler {
-
-        @Override
-        public void handleMessage(Message msg) {
-            SnakeView.this.update();
-            SnakeView.this.invalidate();
-        }
-
-        public void sleep(long delayMillis) {
-        	this.removeMessages(0);
-            sendMessageDelayed(obtainMessage(0), delayMillis);
-        }
-    };
-
-
-    /**
-     * Constructs a SnakeView based on inflation from XML
-     * 
-     * @param context
-     * @param attrs
-     */
-    public SnakeView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        initSnakeView();
-   }
-
-    public SnakeView(Context context, AttributeSet attrs, int defStyle) {
-    	super(context, attrs, defStyle);
-    	initSnakeView();
-    }
-
-    private void initSnakeView() {
-        setFocusable(true);
-
-        Resources r = this.getContext().getResources();
-        
-        resetTiles(4);
-        loadTile(RED_STAR, r.getDrawable(R.drawable.redstar));
-        loadTile(YELLOW_STAR, r.getDrawable(R.drawable.yellowstar));
-        loadTile(GREEN_STAR, r.getDrawable(R.drawable.greenstar));
-    	
-    }
-    
-
-    private void initNewGame() {
-        mSnakeTrail.clear();
-        mAppleList.clear();
-
-        // For now we're just going to load up a short default eastbound snake
-        // that's just turned north
-
-        
-        mSnakeTrail.add(new Coordinate(7, 7));
-        mSnakeTrail.add(new Coordinate(6, 7));
-        mSnakeTrail.add(new Coordinate(5, 7));
-        mSnakeTrail.add(new Coordinate(4, 7));
-        mSnakeTrail.add(new Coordinate(3, 7));
-        mSnakeTrail.add(new Coordinate(2, 7));
-        mNextDirection = NORTH;
-
-        // Two apples to start with
-        addRandomApple();
-        addRandomApple();
-
-        mMoveDelay = 600;
-        mScore = 0;
-    }
-
-
-    /**
-     * Given a ArrayList of coordinates, we need to flatten them into an array of
-     * ints before we can stuff them into a map for flattening and storage.
-     * 
-     * @param cvec : a ArrayList of Coordinate objects
-     * @return : a simple array containing the x/y values of the coordinates
-     * as [x1,y1,x2,y2,x3,y3...]
-     */
-    private int[] coordArrayListToArray(ArrayList<Coordinate> cvec) {
-        int count = cvec.size();
-        int[] rawArray = new int[count * 2];
-        for (int index = 0; index < count; index++) {
-            Coordinate c = cvec.get(index);
-            rawArray[2 * index] = c.x;
-            rawArray[2 * index + 1] = c.y;
-        }
-        return rawArray;
-    }
-
-    /**
-     * Save game state so that the user does not lose anything
-     * if the game process is killed while we are in the 
-     * background.
-     * 
-     * @return a Bundle with this view's state
-     */
-    public Bundle saveState() {
-        Bundle map = new Bundle();
-
-        map.putIntArray("mAppleList", coordArrayListToArray(mAppleList));
-        map.putInt("mDirection", Integer.valueOf(mDirection));
-        map.putInt("mNextDirection", Integer.valueOf(mNextDirection));
-        map.putLong("mMoveDelay", Long.valueOf(mMoveDelay));
-        map.putLong("mScore", Long.valueOf(mScore));
-        map.putIntArray("mSnakeTrail", coordArrayListToArray(mSnakeTrail));
-
-        return map;
-    }
-
-    /**
-     * Given a flattened array of ordinate pairs, we reconstitute them into a
-     * ArrayList of Coordinate objects
-     * 
-     * @param rawArray : [x1,y1,x2,y2,...]
-     * @return a ArrayList of Coordinates
-     */
-    private ArrayList<Coordinate> coordArrayToArrayList(int[] rawArray) {
-        ArrayList<Coordinate> coordArrayList = new ArrayList<Coordinate>();
-
-        int coordCount = rawArray.length;
-        for (int index = 0; index < coordCount; index += 2) {
-            Coordinate c = new Coordinate(rawArray[index], rawArray[index + 1]);
-            coordArrayList.add(c);
-        }
-        return coordArrayList;
-    }
-
-    /**
-     * Restore game state if our process is being relaunched
-     * 
-     * @param icicle a Bundle containing the game state
-     */
-    public void restoreState(Bundle icicle) {
-        setMode(PAUSE);
-
-        mAppleList = coordArrayToArrayList(icicle.getIntArray("mAppleList"));
-        mDirection = icicle.getInt("mDirection");
-        mNextDirection = icicle.getInt("mNextDirection");
-        mMoveDelay = icicle.getLong("mMoveDelay");
-        mScore = icicle.getLong("mScore");
-        mSnakeTrail = coordArrayToArrayList(icicle.getIntArray("mSnakeTrail"));
-    }
-
-    /*
-     * handles key events in the game. Update the direction our snake is traveling
-     * based on the DPAD. Ignore events that would cause the snake to immediately
-     * turn back on itself.
-     * 
-     * (non-Javadoc)
-     * 
-     * @see android.view.View#onKeyDown(int, android.os.KeyEvent)
-     */
-    @Override
-    public boolean onKeyDown(int keyCode, KeyEvent msg) {
-
-        if (keyCode == KeyEvent.KEYCODE_DPAD_UP) {
-            if (mMode == READY | mMode == LOSE) {
-                /*
-                 * At the beginning of the game, or the end of a previous one,
-                 * we should start a new game.
-                 */
-                initNewGame();
-                setMode(RUNNING);
-                update();
-                return (true);
-            }
-
-            if (mMode == PAUSE) {
-                /*
-                 * If the game is merely paused, we should just continue where
-                 * we left off.
-                 */
-                setMode(RUNNING);
-                update();
-                return (true);
-            }
-
-            if (mDirection != SOUTH) {
-                mNextDirection = NORTH;
-            }
-            return (true);
-        }
-
-        if (keyCode == KeyEvent.KEYCODE_DPAD_DOWN) {
-            if (mDirection != NORTH) {
-                mNextDirection = SOUTH;
-            }
-            return (true);
-        }
-
-        if (keyCode == KeyEvent.KEYCODE_DPAD_LEFT) {
-            if (mDirection != EAST) {
-                mNextDirection = WEST;
-            }
-            return (true);
-        }
-
-        if (keyCode == KeyEvent.KEYCODE_DPAD_RIGHT) {
-            if (mDirection != WEST) {
-                mNextDirection = EAST;
-            }
-            return (true);
-        }
-
-        return super.onKeyDown(keyCode, msg);
-    }
-
-    /**
-     * Sets the TextView that will be used to give information (such as "Game
-     * Over" to the user.
-     * 
-     * @param newView
-     */
-    public void setTextView(TextView newView) {
-        mStatusText = newView;
-    }
-
-    /**
-     * Updates the current mode of the application (RUNNING or PAUSED or the like)
-     * as well as sets the visibility of textview for notification
-     * 
-     * @param newMode
-     */
-    public void setMode(int newMode) {
-        int oldMode = mMode;
-        mMode = newMode;
-
-        if (newMode == RUNNING & oldMode != RUNNING) {
-            mStatusText.setVisibility(View.INVISIBLE);
-            update();
-            return;
-        }
-
-        Resources res = getContext().getResources();
-        CharSequence str = "";
-        if (newMode == PAUSE) {
-            str = res.getText(R.string.mode_pause);
-        }
-        if (newMode == READY) {
-            str = res.getText(R.string.mode_ready);
-        }
-        if (newMode == LOSE) {
-            str = res.getString(R.string.mode_lose_prefix) + mScore
-                  + res.getString(R.string.mode_lose_suffix);
-        }
-
-        mStatusText.setText(str);
-        mStatusText.setVisibility(View.VISIBLE);
-    }
-
-    /**
-     * Selects a random location within the garden that is not currently covered
-     * by the snake. Currently _could_ go into an infinite loop if the snake
-     * currently fills the garden, but we'll leave discovery of this prize to a
-     * truly excellent snake-player.
-     * 
-     */
-    private void addRandomApple() {
-        Coordinate newCoord = null;
-        boolean found = false;
-        while (!found) {
-            // Choose a new location for our apple
-            int newX = 1 + RNG.nextInt(mXTileCount - 2);
-            int newY = 1 + RNG.nextInt(mYTileCount - 2);
-            newCoord = new Coordinate(newX, newY);
-
-            // Make sure it's not already under the snake
-            boolean collision = false;
-            int snakelength = mSnakeTrail.size();
-            for (int index = 0; index < snakelength; index++) {
-                if (mSnakeTrail.get(index).equals(newCoord)) {
-                    collision = true;
-                }
-            }
-            // if we're here and there's been no collision, then we have
-            // a good location for an apple. Otherwise, we'll circle back
-            // and try again
-            found = !collision;
-        }
-        if (newCoord == null) {
-            Log.e(TAG, "Somehow ended up with a null newCoord!");
-        }
-        mAppleList.add(newCoord);
-    }
-
-
-    /**
-     * Handles the basic update loop, checking to see if we are in the running
-     * state, determining if a move should be made, updating the snake's location.
-     */
-    public void update() {
-        if (mMode == RUNNING) {
-            long now = System.currentTimeMillis();
-
-            if (now - mLastMove > mMoveDelay) {
-                clearTiles();
-                updateWalls();
-                updateSnake();
-                updateApples();
-                mLastMove = now;
-            }
-            mRedrawHandler.sleep(mMoveDelay);
-        }
-
-    }
-
-    /**
-     * Draws some walls.
-     * 
-     */
-    private void updateWalls() {
-        for (int x = 0; x < mXTileCount; x++) {
-            setTile(GREEN_STAR, x, 0);
-            setTile(GREEN_STAR, x, mYTileCount - 1);
-        }
-        for (int y = 1; y < mYTileCount - 1; y++) {
-            setTile(GREEN_STAR, 0, y);
-            setTile(GREEN_STAR, mXTileCount - 1, y);
-        }
-    }
-
-    /**
-     * Draws some apples.
-     * 
-     */
-    private void updateApples() {
-        for (Coordinate c : mAppleList) {
-            setTile(YELLOW_STAR, c.x, c.y);
-        }
-    }
-
-    /**
-     * Figure out which way the snake is going, see if he's run into anything (the
-     * walls, himself, or an apple). If he's not going to die, we then add to the
-     * front and subtract from the rear in order to simulate motion. If we want to
-     * grow him, we don't subtract from the rear.
-     * 
-     */
-    private void updateSnake() {
-        boolean growSnake = false;
-
-        // grab the snake by the head
-        Coordinate head = mSnakeTrail.get(0);
-        Coordinate newHead = new Coordinate(1, 1);
-
-        mDirection = mNextDirection;
-
-        switch (mDirection) {
-        case EAST: {
-            newHead = new Coordinate(head.x + 1, head.y);
-            break;
-        }
-        case WEST: {
-            newHead = new Coordinate(head.x - 1, head.y);
-            break;
-        }
-        case NORTH: {
-            newHead = new Coordinate(head.x, head.y - 1);
-            break;
-        }
-        case SOUTH: {
-            newHead = new Coordinate(head.x, head.y + 1);
-            break;
-        }
-        }
-
-        // Collision detection
-        // For now we have a 1-square wall around the entire arena
-        if ((newHead.x < 1) || (newHead.y < 1) || (newHead.x > mXTileCount - 2)
-                || (newHead.y > mYTileCount - 2)) {
-            setMode(LOSE);
-            return;
-
-        }
-
-        // Look for collisions with itself
-        int snakelength = mSnakeTrail.size();
-        for (int snakeindex = 0; snakeindex < snakelength; snakeindex++) {
-            Coordinate c = mSnakeTrail.get(snakeindex);
-            if (c.equals(newHead)) {
-                setMode(LOSE);
-                return;
-            }
-        }
-
-        // Look for apples
-        int applecount = mAppleList.size();
-        for (int appleindex = 0; appleindex < applecount; appleindex++) {
-            Coordinate c = mAppleList.get(appleindex);
-            if (c.equals(newHead)) {
-                mAppleList.remove(c);
-                addRandomApple();
-                
-                mScore++;
-                mMoveDelay *= 0.9;
-
-                growSnake = true;
-            }
-        }
-
-        // push a new head onto the ArrayList and pull off the tail
-        mSnakeTrail.add(0, newHead);
-        // except if we want the snake to grow
-        if (!growSnake) {
-            mSnakeTrail.remove(mSnakeTrail.size() - 1);
-        }
-
-        int index = 0;
-        for (Coordinate c : mSnakeTrail) {
-            if (index == 0) {
-                setTile(YELLOW_STAR, c.x, c.y);
-            } else {
-                setTile(RED_STAR, c.x, c.y);
-            }
-            index++;
-        }
-
-    }
-
-    /**
-     * Simple class containing two integer values and a comparison function.
-     * There's probably something I should use instead, but this was quick and
-     * easy to build.
-     * 
-     */
-    private class Coordinate {
-        public int x;
-        public int y;
-
-        public Coordinate(int newX, int newY) {
-            x = newX;
-            y = newY;
-        }
-
-        public boolean equals(Coordinate other) {
-            if (x == other.x && y == other.y) {
-                return true;
-            }
-            return false;
-        }
-
-        @Override
-        public String toString() {
-            return "Coordinate: [" + x + "," + y + "]";
-        }
-    }
-    
-}
diff --git a/samples/Snake/src/com/example/android/snake/TileView.java b/samples/Snake/src/com/example/android/snake/TileView.java
deleted file mode 100644
index a912c53..0000000
--- a/samples/Snake/src/com/example/android/snake/TileView.java
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.snake;
-
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.drawable.Drawable;
-import android.util.AttributeSet;
-import android.view.View;
-
-
-/**
- * TileView: a View-variant designed for handling arrays of "icons" or other
- * drawables.
- * 
- */
-public class TileView extends View {
-
-    /**
-     * Parameters controlling the size of the tiles and their range within view.
-     * Width/Height are in pixels, and Drawables will be scaled to fit to these
-     * dimensions. X/Y Tile Counts are the number of tiles that will be drawn.
-     */
-
-    protected static int mTileSize;
-
-    protected static int mXTileCount;
-    protected static int mYTileCount;
-
-    private static int mXOffset;
-    private static int mYOffset;
-
-
-    /**
-     * A hash that maps integer handles specified by the subclasser to the
-     * drawable that will be used for that reference
-     */
-    private Bitmap[] mTileArray; 
-
-    /**
-     * A two-dimensional array of integers in which the number represents the
-     * index of the tile that should be drawn at that locations
-     */
-    private int[][] mTileGrid;
-
-    private final Paint mPaint = new Paint();
-
-    public TileView(Context context, AttributeSet attrs, int defStyle) {
-        super(context, attrs, defStyle);
-
-        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.TileView);
-
-        mTileSize = a.getInt(R.styleable.TileView_tileSize, 12);
-        
-        a.recycle();
-    }
-
-    public TileView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-
-        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.TileView);
-
-        mTileSize = a.getInt(R.styleable.TileView_tileSize, 12);
-        
-        a.recycle();
-    }
-
-    
-    
-    /**
-     * Rests the internal array of Bitmaps used for drawing tiles, and
-     * sets the maximum index of tiles to be inserted
-     * 
-     * @param tilecount
-     */
-    
-    public void resetTiles(int tilecount) {
-    	mTileArray = new Bitmap[tilecount];
-    }
-
-
-    @Override
-    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
-        mXTileCount = (int) Math.floor(w / mTileSize);
-        mYTileCount = (int) Math.floor(h / mTileSize);
-
-        mXOffset = ((w - (mTileSize * mXTileCount)) / 2);
-        mYOffset = ((h - (mTileSize * mYTileCount)) / 2);
-
-        mTileGrid = new int[mXTileCount][mYTileCount];
-        clearTiles();
-    }
-
-    /**
-     * Function to set the specified Drawable as the tile for a particular
-     * integer key.
-     * 
-     * @param key
-     * @param tile
-     */
-    public void loadTile(int key, Drawable tile) {
-        Bitmap bitmap = Bitmap.createBitmap(mTileSize, mTileSize, Bitmap.Config.ARGB_8888);
-        Canvas canvas = new Canvas(bitmap);
-        tile.setBounds(0, 0, mTileSize, mTileSize);
-        tile.draw(canvas);
-        
-        mTileArray[key] = bitmap;
-    }
-
-    /**
-     * Resets all tiles to 0 (empty)
-     * 
-     */
-    public void clearTiles() {
-        for (int x = 0; x < mXTileCount; x++) {
-            for (int y = 0; y < mYTileCount; y++) {
-                setTile(0, x, y);
-            }
-        }
-    }
-
-    /**
-     * Used to indicate that a particular tile (set with loadTile and referenced
-     * by an integer) should be drawn at the given x/y coordinates during the
-     * next invalidate/draw cycle.
-     * 
-     * @param tileindex
-     * @param x
-     * @param y
-     */
-    public void setTile(int tileindex, int x, int y) {
-        mTileGrid[x][y] = tileindex;
-    }
-
-
-    @Override
-    public void onDraw(Canvas canvas) {
-        super.onDraw(canvas);
-        for (int x = 0; x < mXTileCount; x += 1) {
-            for (int y = 0; y < mYTileCount; y += 1) {
-                if (mTileGrid[x][y] > 0) {
-                    canvas.drawBitmap(mTileArray[mTileGrid[x][y]], 
-                    		mXOffset + x * mTileSize,
-                    		mYOffset + y * mTileSize,
-                    		mPaint);
-                }
-            }
-        }
-
-    }
-
-}
diff --git a/samples/Snake/tests/Android.mk b/samples/Snake/tests/Android.mk
deleted file mode 100644
index 3d16805..0000000
--- a/samples/Snake/tests/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := android.test.runner
-
-LOCAL_PACKAGE_NAME := SnakeTests
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_INSTRUMENTATION_FOR := Snake
-
-include $(BUILD_PACKAGE)
diff --git a/samples/Snake/tests/AndroidManifest.xml b/samples/Snake/tests/AndroidManifest.xml
deleted file mode 100644
index 382506c..0000000
--- a/samples/Snake/tests/AndroidManifest.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-  
-          http://www.apache.org/licenses/LICENSE-2.0
-  
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-      package="com.example.android.snake.tests">
-    
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->    
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-
-  <instrumentation android:name="android.test.InstrumentationTestRunner"
-      android:targetPackage="com.example.android.snake"
-      android:label="Snake sample tests">
-  </instrumentation>  
-  
-</manifest>
diff --git a/samples/Snake/tests/src/com/example/android/snake/SnakeTest.java b/samples/Snake/tests/src/com/example/android/snake/SnakeTest.java
deleted file mode 100644
index 35d1b12..0000000
--- a/samples/Snake/tests/src/com/example/android/snake/SnakeTest.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.example.android.snake;
-
-import android.test.ActivityInstrumentationTestCase;
-
-import com.example.android.snake.Snake;
-
-/**
- * Make sure that the main launcher activity opens up properly, which will be
- * verified by {@link ActivityTestCase#testActivityTestCaseSetUpProperly}.
- */
-public class SnakeTest extends ActivityInstrumentationTestCase<Snake> {
-  
-  public SnakeTest() {
-      super("com.example.android.snake", Snake.class);
-  }
-  
-}
diff --git a/samples/SoftKeyboard/Android.mk b/samples/SoftKeyboard/Android.mk
deleted file mode 100755
index 883bf2f..0000000
--- a/samples/SoftKeyboard/Android.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := samples
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_SDK_VERSION := current
-
-LOCAL_PACKAGE_NAME := SoftKeyboard
-
-include $(BUILD_PACKAGE)
diff --git a/samples/SoftKeyboard/AndroidManifest.xml b/samples/SoftKeyboard/AndroidManifest.xml
deleted file mode 100755
index 61b5131..0000000
--- a/samples/SoftKeyboard/AndroidManifest.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" 
-        package="com.example.android.softkeyboard">
-    <application android:label="@string/ime_name">
-        <service android:name="SoftKeyboard"
-                android:permission="android.permission.BIND_INPUT_METHOD">
-            <intent-filter>
-                <action android:name="android.view.InputMethod" />
-            </intent-filter>
-            <meta-data android:name="android.view.im" android:resource="@xml/method" />
-        </service>
-    </application>
-</manifest>
diff --git a/samples/SoftKeyboard/res/drawable/sym_keyboard_delete.png b/samples/SoftKeyboard/res/drawable/sym_keyboard_delete.png
deleted file mode 100644
index 6cee596..0000000
--- a/samples/SoftKeyboard/res/drawable/sym_keyboard_delete.png
+++ /dev/null
Binary files differ
diff --git a/samples/SoftKeyboard/res/drawable/sym_keyboard_done.png b/samples/SoftKeyboard/res/drawable/sym_keyboard_done.png
deleted file mode 100755
index c0d6d13..0000000
--- a/samples/SoftKeyboard/res/drawable/sym_keyboard_done.png
+++ /dev/null
Binary files differ
diff --git a/samples/SoftKeyboard/res/drawable/sym_keyboard_return.png b/samples/SoftKeyboard/res/drawable/sym_keyboard_return.png
deleted file mode 100644
index cbe2b15..0000000
--- a/samples/SoftKeyboard/res/drawable/sym_keyboard_return.png
+++ /dev/null
Binary files differ
diff --git a/samples/SoftKeyboard/res/drawable/sym_keyboard_shift.png b/samples/SoftKeyboard/res/drawable/sym_keyboard_shift.png
deleted file mode 100644
index d059628..0000000
--- a/samples/SoftKeyboard/res/drawable/sym_keyboard_shift.png
+++ /dev/null
Binary files differ
diff --git a/samples/SoftKeyboard/res/drawable/sym_keyboard_space.png b/samples/SoftKeyboard/res/drawable/sym_keyboard_space.png
deleted file mode 100644
index 09b94d9..0000000
--- a/samples/SoftKeyboard/res/drawable/sym_keyboard_space.png
+++ /dev/null
Binary files differ
diff --git a/samples/SoftKeyboard/res/layout/input.xml b/samples/SoftKeyboard/res/layout/input.xml
deleted file mode 100755
index 1b57468..0000000
--- a/samples/SoftKeyboard/res/layout/input.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<com.example.android.softkeyboard.LatinKeyboardView
-        xmlns:android="http://schemas.android.com/apk/res/android"
-        android:id="@+id/keyboard"
-        android:layout_alignParentBottom="true"
-        android:layout_width="fill_parent"
-        android:layout_height="wrap_content"
-        />
diff --git a/samples/SoftKeyboard/res/values-land/dimens.xml b/samples/SoftKeyboard/res/values-land/dimens.xml
deleted file mode 100644
index b5f3bc1..0000000
--- a/samples/SoftKeyboard/res/values-land/dimens.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<resources>
-    <dimen name="key_height">46dip</dimen>
-</resources>
diff --git a/samples/SoftKeyboard/res/values/colors.xml b/samples/SoftKeyboard/res/values/colors.xml
deleted file mode 100644
index 74d103a..0000000
--- a/samples/SoftKeyboard/res/values/colors.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-<resources>
-    <color name="candidate_normal">#FF000000</color>
-    <color name="candidate_recommended">#FFE35900</color>
-    <color name="candidate_other">#ff808080</color>
-    <color name="candidate_background">#bbffffff</color>
-</resources>
\ No newline at end of file
diff --git a/samples/SoftKeyboard/res/values/dimens.xml b/samples/SoftKeyboard/res/values/dimens.xml
deleted file mode 100644
index caf615c..0000000
--- a/samples/SoftKeyboard/res/values/dimens.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<resources>
-    <dimen name="key_height">50dip</dimen>
-    <dimen name="candidate_font_height">16sp</dimen>
-    <dimen name="candidate_vertical_padding">6sp</dimen>
-</resources>
\ No newline at end of file
diff --git a/samples/SoftKeyboard/res/values/strings.xml b/samples/SoftKeyboard/res/values/strings.xml
deleted file mode 100644
index c1e306d..0000000
--- a/samples/SoftKeyboard/res/values/strings.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
--->
-<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <!-- Title for Latin keyboard  -->
-    <string name="ime_name">Sample Soft Keyboard</string>
-
-    <!-- Symbols that are commonly considered word separators in this language -->
-    <string name="word_separators">\u0020.,;:!?\n()[]*&amp;@{}/&lt;&gt;_+=|&quot;</string>
-    
-    <!-- Labels on soft keys -->
-    <string name="label_done">Done</string>
-    <string name="label_search">Search</string>
-    <string name="label_enter">Enter</string>
-    <string name="label_next">Next</string>
-    <string name="label_previous">Previous</string>
-</resources>
diff --git a/samples/SoftKeyboard/res/xml/method.xml b/samples/SoftKeyboard/res/xml/method.xml
deleted file mode 100644
index d246624..0000000
--- a/samples/SoftKeyboard/res/xml/method.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/**
- * Copyright (c) 2008, The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); 
- * you may not use this file except in compliance with the License. 
- * You may obtain a copy of the License at 
- *
- *     http://www.apache.org/licenses/LICENSE-2.0 
- *
- * Unless required by applicable law or agreed to in writing, software 
- * distributed under the License is distributed on an "AS IS" BASIS, 
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
- * See the License for the specific language governing permissions and 
- * limitations under the License.
- */
--->
-
-<!-- The attributes in this XML file provide configuration information -->
-<!-- for the Search Manager. -->
-
-<input-method xmlns:android="http://schemas.android.com/apk/res/android" />
diff --git a/samples/SoftKeyboard/res/xml/qwerty.xml b/samples/SoftKeyboard/res/xml/qwerty.xml
deleted file mode 100755
index e81d9f1..0000000
--- a/samples/SoftKeyboard/res/xml/qwerty.xml
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<Keyboard xmlns:android="http://schemas.android.com/apk/res/android"
-    android:keyWidth="10%p"
-    android:horizontalGap="0px"
-    android:verticalGap="0px"
-    android:keyHeight="@dimen/key_height"
-    >
-
-    <Row>
-        <Key android:codes="113" android:keyLabel="q" android:keyEdgeFlags="left"/>
-        <Key android:codes="119" android:keyLabel="w"/>
-        <Key android:codes="101" android:keyLabel="e"/>
-        <Key android:codes="114" android:keyLabel="r"/>
-        <Key android:codes="116" android:keyLabel="t"/>
-        <Key android:codes="121" android:keyLabel="y"/>
-        <Key android:codes="117" android:keyLabel="u"/>
-        <Key android:codes="105" android:keyLabel="i"/>
-        <Key android:codes="111" android:keyLabel="o"/>
-        <Key android:codes="112" android:keyLabel="p" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="97" android:keyLabel="a" android:horizontalGap="5%p" 
-                android:keyEdgeFlags="left"/>
-        <Key android:codes="115" android:keyLabel="s"/>
-        <Key android:codes="100" android:keyLabel="d"/>
-        <Key android:codes="102" android:keyLabel="f"/>
-        <Key android:codes="103" android:keyLabel="g"/>
-        <Key android:codes="104" android:keyLabel="h"/>
-        <Key android:codes="106" android:keyLabel="j"/>
-        <Key android:codes="107" android:keyLabel="k"/>
-        <Key android:codes="108" android:keyLabel="l" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="-1" android:keyIcon="@drawable/sym_keyboard_shift" 
-                android:keyWidth="15%p" android:isModifier="true"
-                android:isSticky="true" android:keyEdgeFlags="left"/>
-        <Key android:codes="122" android:keyLabel="z"/>
-        <Key android:codes="120" android:keyLabel="x"/>
-        <Key android:codes="99" android:keyLabel="c"/>
-        <Key android:codes="118" android:keyLabel="v"/>
-        <Key android:codes="98" android:keyLabel="b"/>
-        <Key android:codes="110" android:keyLabel="n"/>
-        <Key android:codes="109" android:keyLabel="m"/>
-        <Key android:codes="-5" android:keyIcon="@drawable/sym_keyboard_delete" 
-                android:keyWidth="15%p" android:keyEdgeFlags="right"
-                android:isRepeatable="true"/>
-    </Row>
-    
-    <Row android:rowEdgeFlags="bottom">
-        <Key android:codes="-3" android:keyIcon="@drawable/sym_keyboard_done" 
-                android:keyWidth="20%p" android:keyEdgeFlags="left"/>
-        <Key android:codes="-2" android:keyLabel="123" android:keyWidth="15%p"/>
-        <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" 
-                android:keyWidth="30%p" android:isRepeatable="true"/>
-        <Key android:codes="46,44" android:keyLabel=". ,"
-                android:keyWidth="15%p"/>
-        <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return" 
-                android:keyWidth="20%p" android:keyEdgeFlags="right"/>
-    </Row>
-</Keyboard>
-    
\ No newline at end of file
diff --git a/samples/SoftKeyboard/res/xml/symbols.xml b/samples/SoftKeyboard/res/xml/symbols.xml
deleted file mode 100755
index a28d752..0000000
--- a/samples/SoftKeyboard/res/xml/symbols.xml
+++ /dev/null
@@ -1,81 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<Keyboard xmlns:android="http://schemas.android.com/apk/res/android"
-    android:keyWidth="10%p"
-    android:horizontalGap="0px"
-    android:verticalGap="0px"
-    android:keyHeight="@dimen/key_height"
-    >
-
-    <Row>
-        <Key android:codes="49" android:keyLabel="1" android:keyEdgeFlags="left"/>
-        <Key android:codes="50" android:keyLabel="2"/>
-        <Key android:codes="51" android:keyLabel="3"/>
-        <Key android:codes="52" android:keyLabel="4"/>
-        <Key android:codes="53" android:keyLabel="5"/>
-        <Key android:codes="54" android:keyLabel="6"/>
-        <Key android:codes="55" android:keyLabel="7"/>
-        <Key android:codes="56" android:keyLabel="8"/>
-        <Key android:codes="57" android:keyLabel="9"/>
-        <Key android:codes="48" android:keyLabel="0" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="64" android:keyLabel="\@" android:keyEdgeFlags="left"/>
-        <Key android:codes="35" android:keyLabel="\#"/>
-        <Key android:codes="36" android:keyLabel="$"/>
-        <Key android:codes="37" android:keyLabel="%"/>
-        <Key android:codes="38" android:keyLabel="&amp;"/>
-        <Key android:codes="42" android:keyLabel="*"/>
-        <Key android:codes="45" android:keyLabel="-"/>
-        <Key android:codes="61" android:keyLabel="="/>
-        <Key android:codes="40" android:keyLabel="("/>
-        <Key android:codes="41" android:keyLabel=")" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="-1" android:keyIcon="@drawable/sym_keyboard_shift"
-                android:keyWidth="15%p" android:isModifier="true"
-                android:isSticky="true" android:keyEdgeFlags="left"/>
-        <Key android:codes="33" android:keyLabel="!" />
-        <Key android:codes="34" android:keyLabel="&quot;"/>
-        <Key android:codes="39" android:keyLabel="\'"/>
-        <Key android:codes="58" android:keyLabel=":"/>
-        <Key android:codes="59" android:keyLabel=";"/>
-        <Key android:codes="47" android:keyLabel="/" />
-        <Key android:codes="63" android:keyLabel="\?"/>
-        <Key android:codes="-5" android:keyIcon="@drawable/sym_keyboard_delete"
-                android:keyWidth="15%p" android:keyEdgeFlags="right"
-                android:isRepeatable="true"/>
-    </Row>
-    
-    <Row  android:rowEdgeFlags="bottom">
-        <Key android:codes="-3" android:keyIcon="@drawable/sym_keyboard_done"
-                android:keyWidth="20%p" android:keyEdgeFlags="left" />
-        <Key android:codes="-2" android:keyLabel="ABC" android:keyWidth="15%p" />
-        <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" android:keyWidth="30%p" 
-                android:isRepeatable="true"/>
-        <Key android:codes="44" android:keyLabel="," android:keyWidth="15%p" />
-        <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
-                android:keyWidth="20%p" android:keyEdgeFlags="right"
-                />
-    </Row>
-</Keyboard>
\ No newline at end of file
diff --git a/samples/SoftKeyboard/res/xml/symbols_shift.xml b/samples/SoftKeyboard/res/xml/symbols_shift.xml
deleted file mode 100755
index d7139f3..0000000
--- a/samples/SoftKeyboard/res/xml/symbols_shift.xml
+++ /dev/null
@@ -1,80 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* 
-**
-** Copyright 2008, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License"); 
-** you may not use this file except in compliance with the License. 
-** You may obtain a copy of the License at 
-**
-**     http://www.apache.org/licenses/LICENSE-2.0 
-**
-** Unless required by applicable law or agreed to in writing, software 
-** distributed under the License is distributed on an "AS IS" BASIS, 
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-** See the License for the specific language governing permissions and 
-** limitations under the License.
-*/
--->
-
-<Keyboard xmlns:android="http://schemas.android.com/apk/res/android"
-    android:keyWidth="10%p"
-    android:horizontalGap="0px"
-    android:verticalGap="0px"
-    android:keyHeight="@dimen/key_height"
-    >
-
-    <Row>
-        <Key android:codes="126" android:keyLabel="~" android:keyEdgeFlags="left"/>
-        <Key android:codes="177" android:keyLabel="±"/>
-        <Key android:codes="215" android:keyLabel="×"/>
-        <Key android:codes="247" android:keyLabel="÷"/>
-        <Key android:codes="8226" android:keyLabel="•"/>
-        <Key android:codes="176" android:keyLabel="°"/>
-        <Key android:codes="96" android:keyLabel="`"/>
-        <Key android:codes="180" android:keyLabel="´"/>
-        <Key android:codes="123" android:keyLabel="{"/>
-        <Key android:codes="125" android:keyLabel="}" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="169" android:keyLabel="©" android:keyEdgeFlags="left"/>
-        <Key android:codes="163" android:keyLabel="£"/>
-        <Key android:codes="8364" android:keyLabel="€"/>
-        <Key android:codes="94" android:keyLabel="^"/>
-        <Key android:codes="174" android:keyLabel="®"/>
-        <Key android:codes="165" android:keyLabel="¥"/>
-        <Key android:codes="95" android:keyLabel="_"/>
-        <Key android:codes="43" android:keyLabel="+"/>
-        <Key android:codes="91" android:keyLabel="["/>
-        <Key android:codes="93" android:keyLabel="]" android:keyEdgeFlags="right"/>
-    </Row>
-    
-    <Row>
-        <Key android:codes="-1" android:keyIcon="@drawable/sym_keyboard_shift"
-                android:keyWidth="15%p" android:isModifier="true"
-                android:isSticky="true" android:keyEdgeFlags="left"/>
-        <Key android:codes="161" android:keyLabel="¡" />
-        <Key android:codes="60" android:keyLabel="&lt;"/>
-        <Key android:codes="62" android:keyLabel="&gt;"/>
-        <Key android:codes="162" android:keyLabel="¢"/>
-        <Key android:codes="124" android:keyLabel="|"/>
-        <Key android:codes="92" android:keyLabel="\\" />
-        <Key android:codes="191" android:keyLabel="¿"/>
-        <Key android:codes="-5" android:keyIcon="@drawable/sym_keyboard_delete"
-                android:keyWidth="15%p" android:keyEdgeFlags="right"
-                android:isRepeatable="true"/>
-    </Row>
-    
-    <Row android:rowEdgeFlags="bottom">
-        <Key android:codes="-3" android:keyIcon="@drawable/sym_keyboard_done" 
-                android:keyWidth="20%p" android:keyEdgeFlags="left" />
-        <Key android:codes="-2" android:keyLabel="ABC" android:keyWidth="15%p" />
-        <Key android:codes="32" android:keyIcon="@drawable/sym_keyboard_space" android:keyWidth="30%p" 
-                android:isRepeatable="true"/>
-        <Key android:codes="8230" android:keyLabel="…" android:keyWidth="15%p" />
-        <Key android:codes="10" android:keyIcon="@drawable/sym_keyboard_return"
-                android:keyWidth="20%p" android:keyEdgeFlags="right" />
-    </Row>
-</Keyboard>
diff --git a/samples/SoftKeyboard/src/com/example/android/softkeyboard/CandidateView.java b/samples/SoftKeyboard/src/com/example/android/softkeyboard/CandidateView.java
deleted file mode 100755
index 7cadead..0000000
--- a/samples/SoftKeyboard/src/com/example/android/softkeyboard/CandidateView.java
+++ /dev/null
@@ -1,321 +0,0 @@
-/*
- * Copyright (C) 2008-2009 Google Inc.
- * 
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not
- * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.example.android.softkeyboard;
-
-import android.content.Context;
-import android.content.res.Resources;
-import android.graphics.Canvas;
-import android.graphics.Paint;
-import android.graphics.Rect;
-import android.graphics.drawable.Drawable;
-import android.view.GestureDetector;
-import android.view.MotionEvent;
-import android.view.View;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class CandidateView extends View {
-
-    private static final int OUT_OF_BOUNDS = -1;
-
-    private SoftKeyboard mService;
-    private List<String> mSuggestions;
-    private int mSelectedIndex;
-    private int mTouchX = OUT_OF_BOUNDS;
-    private Drawable mSelectionHighlight;
-    private boolean mTypedWordValid;
-    
-    private Rect mBgPadding;
-
-    private static final int MAX_SUGGESTIONS = 32;
-    private static final int SCROLL_PIXELS = 20;
-    
-    private int[] mWordWidth = new int[MAX_SUGGESTIONS];
-    private int[] mWordX = new int[MAX_SUGGESTIONS];
-
-    private static final int X_GAP = 10;
-    
-    private static final List<String> EMPTY_LIST = new ArrayList<String>();
-
-    private int mColorNormal;
-    private int mColorRecommended;
-    private int mColorOther;
-    private int mVerticalPadding;
-    private Paint mPaint;
-    private boolean mScrolled;
-    private int mTargetScrollX;
-    
-    private int mTotalWidth;
-    
-    private GestureDetector mGestureDetector;
-
-    /**
-     * Construct a CandidateView for showing suggested words for completion.
-     * @param context
-     * @param attrs
-     */
-    public CandidateView(Context context) {
-        super(context);
-        mSelectionHighlight = context.getResources().getDrawable(
-                android.R.drawable.list_selector_background);
-        mSelectionHighlight.setState(new int[] {
-                android.R.attr.state_enabled,
-                android.R.attr.state_focused,
-                android.R.attr.state_window_focused,
-                android.R.attr.state_pressed
-        });
-
-        Resources r = context.getResources();
-        
-        setBackgroundColor(r.getColor(R.color.candidate_background));
-        
-        mColorNormal = r.getColor(R.color.candidate_normal);
-        mColorRecommended = r.getColor(R.color.candidate_recommended);
-        mColorOther = r.getColor(R.color.candidate_other);
-        mVerticalPadding = r.getDimensionPixelSize(R.dimen.candidate_vertical_padding);
-        
-        mPaint = new Paint();
-        mPaint.setColor(mColorNormal);
-        mPaint.setAntiAlias(true);
-        mPaint.setTextSize(r.getDimensionPixelSize(R.dimen.candidate_font_height));
-        mPaint.setStrokeWidth(0);
-        
-        mGestureDetector = new GestureDetector(new GestureDetector.SimpleOnGestureListener() {
-            @Override
-            public boolean onScroll(MotionEvent e1, MotionEvent e2,
-                    float distanceX, float distanceY) {
-                mScrolled = true;
-                int sx = getScrollX();
-                sx += distanceX;
-                if (sx < 0) {
-                    sx = 0;
-                }
-                if (sx + getWidth() > mTotalWidth) {                    
-                    sx -= distanceX;
-                }
-                mTargetScrollX = sx;
-                scrollTo(sx, getScrollY());
-                invalidate();
-                return true;
-            }
-        });
-        setHorizontalFadingEdgeEnabled(true);
-        setWillNotDraw(false);
-        setHorizontalScrollBarEnabled(false);
-        setVerticalScrollBarEnabled(false);
-    }
-    
-    /**
-     * A connection back to the service to communicate with the text field
-     * @param listener
-     */
-    public void setService(SoftKeyboard listener) {
-        mService = listener;
-    }
-    
-    @Override
-    public int computeHorizontalScrollRange() {
-        return mTotalWidth;
-    }
-
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        int measuredWidth = resolveSize(50, widthMeasureSpec);
-        
-        // Get the desired height of the icon menu view (last row of items does
-        // not have a divider below)
-        Rect padding = new Rect();
-        mSelectionHighlight.getPadding(padding);
-        final int desiredHeight = ((int)mPaint.getTextSize()) + mVerticalPadding
-                + padding.top + padding.bottom;
-        
-        // Maximum possible width and desired height
-        setMeasuredDimension(measuredWidth,
-                resolveSize(desiredHeight, heightMeasureSpec));
-    }
-
-    /**
-     * If the canvas is null, then only touch calculations are performed to pick the target
-     * candidate.
-     */
-    @Override
-    protected void onDraw(Canvas canvas) {
-        if (canvas != null) {
-            super.onDraw(canvas);
-        }
-        mTotalWidth = 0;
-        if (mSuggestions == null) return;
-        
-        if (mBgPadding == null) {
-            mBgPadding = new Rect(0, 0, 0, 0);
-            if (getBackground() != null) {
-                getBackground().getPadding(mBgPadding);
-            }
-        }
-        int x = 0;
-        final int count = mSuggestions.size(); 
-        final int height = getHeight();
-        final Rect bgPadding = mBgPadding;
-        final Paint paint = mPaint;
-        final int touchX = mTouchX;
-        final int scrollX = getScrollX();
-        final boolean scrolled = mScrolled;
-        final boolean typedWordValid = mTypedWordValid;
-        final int y = (int) (((height - mPaint.getTextSize()) / 2) - mPaint.ascent());
-
-        for (int i = 0; i < count; i++) {
-            String suggestion = mSuggestions.get(i);
-            float textWidth = paint.measureText(suggestion);
-            final int wordWidth = (int) textWidth + X_GAP * 2;
-
-            mWordX[i] = x;
-            mWordWidth[i] = wordWidth;
-            paint.setColor(mColorNormal);
-            if (touchX + scrollX >= x && touchX + scrollX < x + wordWidth && !scrolled) {
-                if (canvas != null) {
-                    canvas.translate(x, 0);
-                    mSelectionHighlight.setBounds(0, bgPadding.top, wordWidth, height);
-                    mSelectionHighlight.draw(canvas);
-                    canvas.translate(-x, 0);
-                }
-                mSelectedIndex = i;
-            }
-
-            if (canvas != null) {
-                if ((i == 1 && !typedWordValid) || (i == 0 && typedWordValid)) {
-                    paint.setFakeBoldText(true);
-                    paint.setColor(mColorRecommended);
-                } else if (i != 0) {
-                    paint.setColor(mColorOther);
-                }
-                canvas.drawText(suggestion, x + X_GAP, y, paint);
-                paint.setColor(mColorOther); 
-                canvas.drawLine(x + wordWidth + 0.5f, bgPadding.top, 
-                        x + wordWidth + 0.5f, height + 1, paint);
-                paint.setFakeBoldText(false);
-            }
-            x += wordWidth;
-        }
-        mTotalWidth = x;
-        if (mTargetScrollX != getScrollX()) {
-            scrollToTarget();
-        }
-    }
-    
-    private void scrollToTarget() {
-        int sx = getScrollX();
-        if (mTargetScrollX > sx) {
-            sx += SCROLL_PIXELS;
-            if (sx >= mTargetScrollX) {
-                sx = mTargetScrollX;
-                requestLayout();
-            }
-        } else {
-            sx -= SCROLL_PIXELS;
-            if (sx <= mTargetScrollX) {
-                sx = mTargetScrollX;
-                requestLayout();
-            }
-        }
-        scrollTo(sx, getScrollY());
-        invalidate();
-    }
-    
-    public void setSuggestions(List<String> suggestions, boolean completions,
-            boolean typedWordValid) {
-        clear();
-        if (suggestions != null) {
-            mSuggestions = new ArrayList<String>(suggestions);
-        }
-        mTypedWordValid = typedWordValid;
-        scrollTo(0, 0);
-        mTargetScrollX = 0;
-        // Compute the total width
-        onDraw(null);
-        invalidate();
-        requestLayout();
-    }
-
-    public void clear() {
-        mSuggestions = EMPTY_LIST;
-        mTouchX = OUT_OF_BOUNDS;
-        mSelectedIndex = -1;
-        invalidate();
-    }
-    
-    @Override
-    public boolean onTouchEvent(MotionEvent me) {
-
-        if (mGestureDetector.onTouchEvent(me)) {
-            return true;
-        }
-
-        int action = me.getAction();
-        int x = (int) me.getX();
-        int y = (int) me.getY();
-        mTouchX = x;
-
-        switch (action) {
-        case MotionEvent.ACTION_DOWN:
-            mScrolled = false;
-            invalidate();
-            break;
-        case MotionEvent.ACTION_MOVE:
-            if (y <= 0) {
-                // Fling up!?
-                if (mSelectedIndex >= 0) {
-                    mService.pickSuggestionManually(mSelectedIndex);
-                    mSelectedIndex = -1;
-                }
-            }
-            invalidate();
-            break;
-        case MotionEvent.ACTION_UP:
-            if (!mScrolled) {
-                if (mSelectedIndex >= 0) {
-                    mService.pickSuggestionManually(mSelectedIndex);
-                }
-            }
-            mSelectedIndex = -1;
-            removeHighlight();
-            requestLayout();
-            break;
-        }
-        return true;
-    }
-    
-    /**
-     * For flick through from keyboard, call this method with the x coordinate of the flick 
-     * gesture.
-     * @param x
-     */
-    public void takeSuggestionAt(float x) {
-        mTouchX = (int) x;
-        // To detect candidate
-        onDraw(null);
-        if (mSelectedIndex >= 0) {
-            mService.pickSuggestionManually(mSelectedIndex);
-        }
-        invalidate();
-    }
-
-    private void removeHighlight() {
-        mTouchX = OUT_OF_BOUNDS;
-        invalidate();
-    }
-}
diff --git a/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboard.java b/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboard.java
deleted file mode 100644
index 944cefb..0000000
--- a/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboard.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008-2009 Google Inc.
- * 
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not
- * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.example.android.softkeyboard;
-
-import android.content.Context;
-import android.content.res.Resources;
-import android.content.res.XmlResourceParser;
-import android.inputmethodservice.Keyboard;
-
-public class LatinKeyboard extends Keyboard {
-
-    public LatinKeyboard(Context context, int xmlLayoutResId) {
-        super(context, xmlLayoutResId);
-    }
-
-    public LatinKeyboard(Context context, int layoutTemplateResId, 
-            CharSequence characters, int columns, int horizontalPadding) {
-        super(context, layoutTemplateResId, characters, columns, horizontalPadding);
-    }
-
-    @Override
-    protected Key createKeyFromXml(Resources res, Row parent, int x, int y, 
-            XmlResourceParser parser) {
-        return new LatinKey(res, parent, x, y, parser);
-    }
-    
-    static class LatinKey extends Keyboard.Key {
-        
-        public LatinKey(Resources res, Keyboard.Row parent, int x, int y, XmlResourceParser parser) {
-            super(res, parent, x, y, parser);
-        }
-        
-        /**
-         * Overriding this method so that we can reduce the target area for the key that
-         * closes the keyboard. 
-         */
-        @Override
-        public boolean isInside(int x, int y) {
-            return super.isInside(x, codes[0] == KEYCODE_CANCEL ? y - 10 : y);
-        }
-    }
-
-}
diff --git a/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboardView.java b/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboardView.java
deleted file mode 100644
index 7464607..0000000
--- a/samples/SoftKeyboard/src/com/example/android/softkeyboard/LatinKeyboardView.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2008-2009 Google Inc.
- * 
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not
- * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.example.android.softkeyboard;
-
-import android.content.Context;
-import android.inputmethodservice.Keyboard;
-import android.inputmethodservice.KeyboardView;
-import android.inputmethodservice.Keyboard.Key;
-import android.util.AttributeSet;
-
-public class LatinKeyboardView extends KeyboardView {
-
-    static final int KEYCODE_OPTIONS = -100;
-
-    public LatinKeyboardView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-    }
-
-    public LatinKeyboardView(Context context, AttributeSet attrs, int defStyle) {
-        super(context, attrs, defStyle);
-    }
-
-    @Override
-    protected boolean onLongPress(Key key) {
-        if (key.codes[0] == Keyboard.KEYCODE_CANCEL) {
-            getOnKeyboardActionListener().onKey(KEYCODE_OPTIONS, null);
-            return true;
-        } else {
-            return super.onLongPress(key);
-        }
-    }
-}
diff --git a/samples/SoftKeyboard/src/com/example/android/softkeyboard/SoftKeyboard.java b/samples/SoftKeyboard/src/com/example/android/softkeyboard/SoftKeyboard.java
deleted file mode 100644
index 4df4853..0000000
--- a/samples/SoftKeyboard/src/com/example/android/softkeyboard/SoftKeyboard.java
+++ /dev/null
@@ -1,658 +0,0 @@
-/*
- * Copyright (C) 2008-2009 Google Inc.
- * 
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not
- * use this file except in compliance with the License. You may obtain a copy of
- * the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.example.android.softkeyboard;
-
-import android.inputmethodservice.InputMethodService;
-import android.inputmethodservice.Keyboard;
-import android.inputmethodservice.KeyboardView;
-import android.text.method.MetaKeyKeyListener;
-import android.util.Log;
-import android.view.KeyCharacterMap;
-import android.view.KeyEvent;
-import android.view.View;
-import android.view.inputmethod.CompletionInfo;
-import android.view.inputmethod.EditorInfo;
-import android.view.inputmethod.InputConnection;
-import android.view.inputmethod.InputMethodManager;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Example of writing an input method for a soft keyboard.  This code is
- * focused on simplicity over completeness, so it should in no way be considered
- * to be a complete soft keyboard implementation.  Its purpose is to provide
- * a basic example for how you would get started writing an input method, to
- * be fleshed out as appropriate.
- */
-public class SoftKeyboard extends InputMethodService 
-        implements KeyboardView.OnKeyboardActionListener {
-    static final boolean DEBUG = false;
-    
-    /**
-     * This boolean indicates the optional example code for performing
-     * processing of hard keys in addition to regular text generation
-     * from on-screen interaction.  It would be used for input methods that
-     * perform language translations (such as converting text entered on 
-     * a QWERTY keyboard to Chinese), but may not be used for input methods
-     * that are primarily intended to be used for on-screen text entry.
-     */
-    static final boolean PROCESS_HARD_KEYS = true;
-    
-    private KeyboardView mInputView;
-    private CandidateView mCandidateView;
-    private CompletionInfo[] mCompletions;
-    
-    private StringBuilder mComposing = new StringBuilder();
-    private boolean mPredictionOn;
-    private boolean mCompletionOn;
-    private int mLastDisplayWidth;
-    private boolean mCapsLock;
-    private long mLastShiftTime;
-    private long mMetaState;
-    
-    private Keyboard mSymbolsKeyboard;
-    private Keyboard mSymbolsShiftedKeyboard;
-    private Keyboard mQwertyKeyboard;
-    
-    private Keyboard mCurKeyboard;
-    
-    private String mWordSeparators;
-    
-    /**
-     * Main initialization of the input method component.  Be sure to call
-     * to super class.
-     */
-    @Override public void onCreate() {
-        super.onCreate();
-        mWordSeparators = getResources().getString(R.string.word_separators);
-    }
-    
-    /**
-     * This is the point where you can do all of your UI initialization.  It
-     * is called after creation and any configuration change.
-     */
-    @Override public void onInitializeInterface() {
-        if (mQwertyKeyboard != null) {
-            // Configuration changes can happen after the keyboard gets recreated,
-            // so we need to be able to re-build the keyboards if the available
-            // space has changed.
-            int displayWidth = getMaxWidth();
-            if (displayWidth == mLastDisplayWidth) return;
-            mLastDisplayWidth = displayWidth;
-        }
-        mQwertyKeyboard = new LatinKeyboard(this, R.xml.qwerty);
-        mSymbolsKeyboard = new LatinKeyboard(this, R.xml.symbols);
-        mSymbolsShiftedKeyboard = new LatinKeyboard(this, R.xml.symbols_shift);
-    }
-    
-    /**
-     * Called by the framework when your view for creating input needs to
-     * be generated.  This will be called the first time your input method
-     * is displayed, and every time it needs to be re-created such as due to
-     * a configuration change.
-     */
-    @Override public View onCreateInputView() {
-        mInputView = (KeyboardView) getLayoutInflater().inflate(
-                R.layout.input, null);
-        mInputView.setOnKeyboardActionListener(this);
-        mInputView.setKeyboard(mQwertyKeyboard);
-        return mInputView;
-    }
-
-    /**
-     * Called by the framework when your view for showing candidates needs to
-     * be generated, like {@link #onCreateInputView}.
-     */
-    @Override public View onCreateCandidatesView() {
-        mCandidateView = new CandidateView(this);
-        mCandidateView.setService(this);
-        return mCandidateView;
-    }
-
-    /**
-     * This is the main point where we do our initialization of the input method
-     * to begin operating on an application.  At this point we have been
-     * bound to the client, and are now receiving all of the detailed information
-     * about the target of our edits.
-     */
-    @Override public void onStartInput(EditorInfo attribute, boolean restarting) {
-        super.onStartInput(attribute, restarting);
-        
-        // Reset our state.  We want to do this even if restarting, because
-        // the underlying state of the text editor could have changed in any way.
-        mComposing.setLength(0);
-        updateCandidates();
-        
-        if (!restarting) {
-            // Clear shift states.
-            mMetaState = 0;
-        }
-        
-        mPredictionOn = false;
-        mCompletionOn = false;
-        mCompletions = null;
-        
-        // We are now going to initialize our state based on the type of
-        // text being edited.
-        switch (attribute.inputType&EditorInfo.TYPE_MASK_CLASS) {
-            case EditorInfo.TYPE_CLASS_NUMBER:
-            case EditorInfo.TYPE_CLASS_DATETIME:
-                // Numbers and dates default to the symbols keyboard, with
-                // no extra features.
-                mCurKeyboard = mSymbolsKeyboard;
-                break;
-                
-            case EditorInfo.TYPE_CLASS_PHONE:
-                // Phones will also default to the symbols keyboard, though
-                // often you will want to have a dedicated phone keyboard.
-                mCurKeyboard = mSymbolsKeyboard;
-                break;
-                
-            case EditorInfo.TYPE_CLASS_TEXT:
-                // This is general text editing.  We will default to the
-                // normal alphabetic keyboard, and assume that we should
-                // be doing predictive text (showing candidates as the
-                // user types).
-                mCurKeyboard = mQwertyKeyboard;
-                mPredictionOn = true;
-                
-                // We now look for a few special variations of text that will
-                // modify our behavior.
-                int variation = attribute.inputType &  EditorInfo.TYPE_MASK_VARIATION;
-                if (variation == EditorInfo.TYPE_TEXT_VARIATION_PASSWORD) {
-                    // Do not display predictions / what the user is typing
-                    // when they are entering a password.
-                    mPredictionOn = false;
-                }
-                
-                if (variation == EditorInfo.TYPE_TEXT_VARIATION_EMAIL_ADDRESS 
-                        || variation == EditorInfo.TYPE_TEXT_VARIATION_URI) {
-                    // Our predictions are not useful for e-mail addresses
-                    // or URIs.
-                    mPredictionOn = false;
-                }
-                
-                if ((attribute.inputType&EditorInfo.TYPE_TEXT_FLAG_AUTO_COMPLETE) != 0) {
-                    // If this is an auto-complete text view, then our predictions
-                    // will not be shown and instead we will allow the editor
-                    // to supply their own.  We only show the editor's
-                    // candidates when in fullscreen mode, otherwise relying
-                    // own it displaying its own UI.
-                    mPredictionOn = false;
-                    mCompletionOn = isFullscreenMode();
-                }
-                
-                // We also want to look at the current state of the editor
-                // to decide whether our alphabetic keyboard should start out
-                // shifted.
-                updateShiftKeyState(attribute);
-                break;
-                
-            default:
-                // For all unknown input types, default to the alphabetic
-                // keyboard with no special features.
-                mCurKeyboard = mQwertyKeyboard;
-        }
-    }
-
-    /**
-     * This is called when the user is done editing a field.  We can use
-     * this to reset our state.
-     */
-    @Override public void onFinishInput() {
-        super.onFinishInput();
-        
-        // Clear current composing text and candidates.
-        mComposing.setLength(0);
-        updateCandidates();
-        
-        // We only hide the candidates window when finishing input on
-        // a particular editor, to avoid popping the underlying application
-        // up and down if the user is entering text into the bottom of
-        // its window.
-        setCandidatesViewShown(false);
-        
-        mCurKeyboard = mQwertyKeyboard;
-        if (mInputView != null) {
-            mInputView.closing();
-        }
-    }
-    
-    @Override public void onStartInputView(EditorInfo attribute, boolean restarting) {
-        super.onStartInputView(attribute, restarting);
-        // Apply the selected keyboard to the input view.
-        mInputView.setKeyboard(mCurKeyboard);
-        mInputView.closing();
-    }
-    
-    /**
-     * Deal with the editor reporting movement of its cursor.
-     */
-    @Override public void onUpdateSelection(int oldSelStart, int oldSelEnd,
-            int newSelStart, int newSelEnd,
-            int candidatesStart, int candidatesEnd) {
-        
-        // If the current selection in the text view changes, we should
-        // clear whatever candidate text we have.
-        if (mComposing.length() > 0 && (newSelStart != candidatesEnd
-                || newSelEnd != candidatesEnd)) {
-            mComposing.setLength(0);
-            updateCandidates();
-            InputConnection ic = getCurrentInputConnection();
-            if (ic != null) {
-                ic.finishComposingText();
-            }
-        }
-    }
-
-    /**
-     * This tells us about completions that the editor has determined based
-     * on the current text in it.  We want to use this in fullscreen mode
-     * to show the completions ourself, since the editor can not be seen
-     * in that situation.
-     */
-    @Override public void onDisplayCompletions(CompletionInfo[] completions) {
-        if (mCompletionOn) {
-            mCompletions = completions;
-            if (completions == null) {
-                setSuggestions(null, false, false);
-                return;
-            }
-            
-            List<String> stringList = new ArrayList<String>();
-            for (int i=0; i<(completions != null ? completions.length : 0); i++) {
-                CompletionInfo ci = completions[i];
-                if (ci != null) stringList.add(ci.getText().toString());
-            }
-            setSuggestions(stringList, true, true);
-        }
-    }
-    
-    /**
-     * This translates incoming hard key events in to edit operations on an
-     * InputConnection.  It is only needed when using the
-     * PROCESS_HARD_KEYS option.
-     */
-    private boolean translateKeyDown(int keyCode, KeyEvent event) {
-        mMetaState = MetaKeyKeyListener.handleKeyDown(mMetaState,
-                keyCode, event);
-        int c = event.getUnicodeChar(MetaKeyKeyListener.getMetaState(mMetaState));
-        mMetaState = MetaKeyKeyListener.adjustMetaAfterKeypress(mMetaState);
-        InputConnection ic = getCurrentInputConnection();
-        if (c == 0 || ic == null) {
-            return false;
-        }
-        
-        boolean dead = false;
-
-        if ((c & KeyCharacterMap.COMBINING_ACCENT) != 0) {
-            dead = true;
-            c = c & KeyCharacterMap.COMBINING_ACCENT_MASK;
-        }
-        
-        if (mComposing.length() > 0) {
-            char accent = mComposing.charAt(mComposing.length() -1 );
-            int composed = KeyEvent.getDeadChar(accent, c);
-
-            if (composed != 0) {
-                c = composed;
-                mComposing.setLength(mComposing.length()-1);
-            }
-        }
-        
-        onKey(c, null);
-        
-        return true;
-    }
-    
-    /**
-     * Use this to monitor key events being delivered to the application.
-     * We get first crack at them, and can either resume them or let them
-     * continue to the app.
-     */
-    @Override public boolean onKeyDown(int keyCode, KeyEvent event) {
-        switch (keyCode) {
-            case KeyEvent.KEYCODE_BACK:
-                // The InputMethodService already takes care of the back
-                // key for us, to dismiss the input method if it is shown.
-                // However, our keyboard could be showing a pop-up window
-                // that back should dismiss, so we first allow it to do that.
-                if (event.getRepeatCount() == 0 && mInputView != null) {
-                    if (mInputView.handleBack()) {
-                        return true;
-                    }
-                }
-                break;
-                
-            case KeyEvent.KEYCODE_DEL:
-                // Special handling of the delete key: if we currently are
-                // composing text for the user, we want to modify that instead
-                // of let the application to the delete itself.
-                if (mComposing.length() > 0) {
-                    onKey(Keyboard.KEYCODE_DELETE, null);
-                    return true;
-                }
-                break;
-                
-            case KeyEvent.KEYCODE_ENTER:
-                // Let the underlying text editor always handle these.
-                return false;
-                
-            default:
-                // For all other keys, if we want to do transformations on
-                // text being entered with a hard keyboard, we need to process
-                // it and do the appropriate action.
-                if (PROCESS_HARD_KEYS) {
-                    if (keyCode == KeyEvent.KEYCODE_SPACE
-                            && (event.getMetaState()&KeyEvent.META_ALT_ON) != 0) {
-                        // A silly example: in our input method, Alt+Space
-                        // is a shortcut for 'android' in lower case.
-                        InputConnection ic = getCurrentInputConnection();
-                        if (ic != null) {
-                            // First, tell the editor that it is no longer in the
-                            // shift state, since we are consuming this.
-                            ic.clearMetaKeyStates(KeyEvent.META_ALT_ON);
-                            keyDownUp(KeyEvent.KEYCODE_A);
-                            keyDownUp(KeyEvent.KEYCODE_N);
-                            keyDownUp(KeyEvent.KEYCODE_D);
-                            keyDownUp(KeyEvent.KEYCODE_R);
-                            keyDownUp(KeyEvent.KEYCODE_O);
-                            keyDownUp(KeyEvent.KEYCODE_I);
-                            keyDownUp(KeyEvent.KEYCODE_D);
-                            // And we consume this event.
-                            return true;
-                        }
-                    }
-                    if (mPredictionOn && translateKeyDown(keyCode, event)) {
-                        return true;
-                    }
-                }
-        }
-        
-        return super.onKeyDown(keyCode, event);
-    }
-
-    /**
-     * Use this to monitor key events being delivered to the application.
-     * We get first crack at them, and can either resume them or let them
-     * continue to the app.
-     */
-    @Override public boolean onKeyUp(int keyCode, KeyEvent event) {
-        // If we want to do transformations on text being entered with a hard
-        // keyboard, we need to process the up events to update the meta key
-        // state we are tracking.
-        if (PROCESS_HARD_KEYS) {
-            if (mPredictionOn) {
-                mMetaState = MetaKeyKeyListener.handleKeyUp(mMetaState,
-                        keyCode, event);
-            }
-        }
-        
-        return super.onKeyUp(keyCode, event);
-    }
-
-    /**
-     * Helper function to commit any text being composed in to the editor.
-     */
-    private void commitTyped(InputConnection inputConnection) {
-        if (mComposing.length() > 0) {
-            inputConnection.commitText(mComposing, mComposing.length());
-            mComposing.setLength(0);
-            updateCandidates();
-        }
-    }
-
-    /**
-     * Helper to update the shift state of our keyboard based on the initial
-     * editor state.
-     */
-    private void updateShiftKeyState(EditorInfo attr) {
-        if (attr != null 
-                && mInputView != null && mQwertyKeyboard == mInputView.getKeyboard()) {
-            int caps = getCurrentInputConnection().getCursorCapsMode(attr.inputType);
-            mInputView.setShifted(mCapsLock || caps != 0);
-        }
-    }
-    
-    /**
-     * Helper to determine if a given character code is alphabetic.
-     */
-    private boolean isAlphabet(int code) {
-        if (Character.isLetter(code)) {
-            return true;
-        } else {
-            return false;
-        }
-    }
-    
-    /**
-     * Helper to send a key down / key up pair to the current editor.
-     */
-    private void keyDownUp(int keyEventCode) {
-        getCurrentInputConnection().sendKeyEvent(
-                new KeyEvent(KeyEvent.ACTION_DOWN, keyEventCode));
-        getCurrentInputConnection().sendKeyEvent(
-                new KeyEvent(KeyEvent.ACTION_UP, keyEventCode));
-    }
-    
-    /**
-     * Helper to send a character to the editor as raw key events.
-     */
-    private void sendKey(int keyCode) {
-        switch (keyCode) {
-            case '\n':
-                keyDownUp(KeyEvent.KEYCODE_ENTER);
-                break;
-            default:
-                if (keyCode >= '0' && keyCode <= '9') {
-                    keyDownUp(keyCode - '0' + KeyEvent.KEYCODE_0);
-                } else {
-                    getCurrentInputConnection().commitText(String.valueOf((char) keyCode), 1);
-                }
-                break;
-        }
-    }
-
-    // Implementation of KeyboardViewListener
-
-    public void onKey(int primaryCode, int[] keyCodes) {
-        if (isWordSeparator(primaryCode)) {
-            // Handle separator
-            if (mComposing.length() > 0) {
-                commitTyped(getCurrentInputConnection());
-            }
-            sendKey(primaryCode);
-            updateShiftKeyState(getCurrentInputEditorInfo());
-        } else if (primaryCode == Keyboard.KEYCODE_DELETE) {
-            handleBackspace();
-        } else if (primaryCode == Keyboard.KEYCODE_SHIFT) {
-            handleShift();
-        } else if (primaryCode == Keyboard.KEYCODE_CANCEL) {
-            handleClose();
-            return;
-        } else if (primaryCode == LatinKeyboardView.KEYCODE_OPTIONS) {
-            // Show a menu or somethin'
-        } else if (primaryCode == Keyboard.KEYCODE_MODE_CHANGE
-                && mInputView != null) {
-            Keyboard current = mInputView.getKeyboard();
-            if (current == mSymbolsKeyboard || current == mSymbolsShiftedKeyboard) {
-                current = mQwertyKeyboard;
-            } else {
-                current = mSymbolsKeyboard;
-            }
-            mInputView.setKeyboard(current);
-            if (current == mSymbolsKeyboard) {
-                current.setShifted(false);
-            }
-        } else {
-            handleCharacter(primaryCode, keyCodes);
-        }
-    }
-
-    /**
-     * Update the list of available candidates from the current composing
-     * text.  This will need to be filled in by however you are determining
-     * candidates.
-     */
-    private void updateCandidates() {
-        if (!mCompletionOn) {
-            if (mComposing.length() > 0) {
-                ArrayList<String> list = new ArrayList<String>();
-                list.add(mComposing.toString());
-                setSuggestions(list, true, true);
-            } else {
-                setSuggestions(null, false, false);
-            }
-        }
-    }
-    
-    public void setSuggestions(List<String> suggestions, boolean completions,
-            boolean typedWordValid) {
-        if (suggestions != null && suggestions.size() > 0) {
-            setCandidatesViewShown(true);
-        } else if (isFullscreenMode()) {
-            setCandidatesViewShown(true);
-        }
-        if (mCandidateView != null) {
-            mCandidateView.setSuggestions(suggestions, completions, typedWordValid);
-        }
-    }
-    
-    private void handleBackspace() {
-        final int length = mComposing.length();
-        if (length > 1) {
-            mComposing.delete(length - 1, length);
-            getCurrentInputConnection().setComposingText(mComposing, mComposing.length());
-            updateCandidates();
-        } else if (length > 0) {
-            mComposing.setLength(0);
-            getCurrentInputConnection().commitText("", 0);
-            updateCandidates();
-        } else {
-            keyDownUp(KeyEvent.KEYCODE_DEL);
-        }
-        updateShiftKeyState(getCurrentInputEditorInfo());
-    }
-
-    private void handleShift() {
-        if (mInputView == null) {
-            return;
-        }
-        
-        Keyboard currentKeyboard = mInputView.getKeyboard();
-        if (mQwertyKeyboard == currentKeyboard) {
-            // Alphabet keyboard
-            checkToggleCapsLock();
-            mInputView.setShifted(mCapsLock || !mInputView.isShifted());
-        } else if (currentKeyboard == mSymbolsKeyboard) {
-            mSymbolsKeyboard.setShifted(true);
-            mInputView.setKeyboard(mSymbolsShiftedKeyboard);
-            mSymbolsShiftedKeyboard.setShifted(true);
-        } else if (currentKeyboard == mSymbolsShiftedKeyboard) {
-            mSymbolsShiftedKeyboard.setShifted(false);
-            mInputView.setKeyboard(mSymbolsKeyboard);
-            mSymbolsKeyboard.setShifted(false);
-        }
-    }
-    
-    private void handleCharacter(int primaryCode, int[] keyCodes) {
-        if (isInputViewShown()) {
-            if (mInputView.isShifted()) {
-                primaryCode = Character.toUpperCase(primaryCode);
-            }
-        }
-        if (isAlphabet(primaryCode) && mPredictionOn) {
-            mComposing.append((char) primaryCode);
-            getCurrentInputConnection().setComposingText(mComposing, mComposing.length());
-            updateShiftKeyState(getCurrentInputEditorInfo());
-            updateCandidates();
-        } else {
-            getCurrentInputConnection().commitText(
-                    String.valueOf((char) primaryCode), 1);
-        }
-    }
-
-    private void handleClose() {
-        commitTyped(getCurrentInputConnection());
-        dismissSoftInput(0);
-        mInputView.closing();
-    }
-
-    private void checkToggleCapsLock() {
-        long now = System.currentTimeMillis();
-        if (mLastShiftTime + 800 > now) {
-            mCapsLock = !mCapsLock;
-            mLastShiftTime = 0;
-        } else {
-            mLastShiftTime = now;
-        }
-    }
-    
-    private String getWordSeparators() {
-        return mWordSeparators;
-    }
-    
-    public boolean isWordSeparator(int code) {
-        String separators = getWordSeparators();
-        return separators.contains(String.valueOf((char)code));
-    }
-
-    public void pickDefaultCandidate() {
-        pickSuggestionManually(0);
-    }
-    
-    public void pickSuggestionManually(int index) {
-        if (mCompletionOn && mCompletions != null && index >= 0
-                && index < mCompletions.length) {
-            CompletionInfo ci = mCompletions[index];
-            getCurrentInputConnection().commitCompletion(ci);
-            if (mCandidateView != null) {
-                mCandidateView.clear();
-            }
-            updateShiftKeyState(getCurrentInputEditorInfo());
-        } else if (mComposing.length() > 0) {
-            // If we were generating candidate suggestions for the current
-            // text, we would commit one of them here.  But for this sample,
-            // we will just commit the current text.
-            commitTyped(getCurrentInputConnection());
-        }
-    }
-    
-    public void swipeRight() {
-        if (mCompletionOn) {
-            pickDefaultCandidate();
-        }
-    }
-    
-    public void swipeLeft() {
-        handleBackspace();
-    }
-
-    public void swipeDown() {
-        handleClose();
-    }
-
-    public void swipeUp() {
-    }
-    
-    public void onPress(int primaryCode) {
-    }
-    
-    public void onRelease(int primaryCode) {
-    }
-}
diff --git a/simulator/app/Android.mk b/simulator/app/Android.mk
deleted file mode 100644
index c6e1d14..0000000
--- a/simulator/app/Android.mk
+++ /dev/null
@@ -1,130 +0,0 @@
-# Copyright 2005 The Android Open Source Project
-#
-
-ifeq ($(TARGET_SIMULATOR),true)
-
-LOCAL_PATH := $(call my-dir)
-
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := \
-	DeviceManager.cpp \
-	DeviceWindow.cpp \
-	ExternalRuntime.cpp \
-	LoadableImage.cpp \
-	LocalBiChannel.cpp \
-	LogMessage.cpp \
-	LogPool.cpp \
-	LogPrefsDialog.cpp \
-	LogWindow.cpp \
-	MainFrame.cpp \
-	MessageStream.cpp \
-	MyApp.cpp \
-	PhoneButton.cpp \
-	PhoneCollection.cpp \
-	PhoneData.cpp \
-	PhoneWindow.cpp \
-	Preferences.cpp \
-	PrefsDialog.cpp \
-	PropertyServer.cpp \
-	Semaphore.cpp \
-	Shmem.cpp \
-	UserEvent.cpp
-
-LOCAL_STATIC_LIBRARIES := \
-	libtinyxml
-LOCAL_WHOLE_STATIC_LIBRARIES := \
-	libutils\
-	libcutils
-LOCAL_MODULE := simulator
-
-LOCAL_LDLIBS += -lpthread
-
-LOCAL_CFLAGS := -UNDEBUG
-#LOCAL_LDFLAGS :=
-
-LOCAL_C_INCLUDES += \
-	external/tinyxml \
-	commands/runtime
-
-# wxWidgets defines
-LOCAL_C_INCLUDES += \
-	/usr/include/wx-2.6 \
-	/usr/lib/wx/include/gtk2-unicode-release-2.6
-
-ifeq ($(HOST_OS),linux)
-	# You can install wxWidgets with "sudo apt-get libwxgtk2.6-dev"
-	LOCAL_LDFLAGS += -lwx_baseu-2.6 \
-		-lwx_baseu_net-2.6 \
-		-lwx_baseu_xml-2.6 \
-		-lwx_gtk2u_adv-2.6 \
-		-lwx_gtk2u_core-2.6 \
-		-lwx_gtk2u_html-2.6 \
-		-lwx_gtk2u_qa-2.6 \
-		-lwx_gtk2u_xrc-2.6
-
-	# this next line makes the simulator able to find its shared libraries
-	# without us explicitly setting the LD_LIBRARY_PATH environment variable
-	LOCAL_LDLIBS += -Wl,-z,origin
-	LOCAL_CFLAGS += -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_FILE_OFFSET_BITS=64 \
-   					-D_LARGE_FILES -D_LARGEFILE_SOURCE=1 
-	LOCAL_LDLIBS += -lrt
-endif
-ifeq ($(HOST_OS),darwin)
-	# NOTE: OS X is no longer supported
-	LOCAL_C_INCLUDES += prebuilt/$(HOST_PREBUILT_TAG)/wxwidgets 
-	LOCAL_LDLIBS += \
-				-framework QuickTime \
-				-framework IOKit \
-				-framework Carbon \
-				-framework Cocoa \
-				-framework System \
-				-lwx_mac_xrc-2.6 \
-				-lwx_mac_qa-2.6 \
-				-lwx_mac_html-2.6 \
-				-lwx_mac_adv-2.6 \
-				-lwx_mac_core-2.6 \
-				-lwx_base_carbon_xml-2.6 \
-				-lwx_base_carbon_net-2.6 \
-				-lwx_base_carbon-2.6 \
-				-lwxexpat-2.6 \
-				-lwxtiff-2.6 \
-				-lwxjpeg-2.6 \
-				-lwxpng-2.6 \
-				-lz \
-				-lpthread \
-				-liconv
-	LOCAL_CFLAGS += \
-				-D__WXMAC__ \
-				-D_FILE_OFFSET_BITS=64 \
-				-D_LARGE_FILES \
-				-DNO_GCC_PRAGMA
-endif
-
-
-include $(BUILD_HOST_EXECUTABLE)
-
-ifeq ($(HOST_OS),darwin)
-# Add the carbon resources to the executable.
-$(LOCAL_BUILT_MODULE): PRIVATE_POST_PROCESS_COMMAND := \
-        /Developer/Tools/Rez -d __DARWIN__ -t APPL \
-        -d __WXMAC__ -o $(LOCAL_BUILT_MODULE) Carbon.r
-endif
-
-# also, we need to copy our assets.  We place these by hand now, because
-# I'd like to clean this up as part of some pdk cleanup I want to do.
-
-asset_files := $(addprefix $(LOCAL_PATH)/assets/,$(call find-subdir-assets,$(LOCAL_PATH)/assets))
-asset_target := $(HOST_COMMON_OUT_ROOT)/sim-assets/simulator$(COMMON_PACKAGE_SUFFIX)
-$(asset_target): PRIVATE_ASSET_ROOT := $(LOCAL_PATH)/assets
-
-$(asset_target) : $(asset_files) $(AAPT)
-	@echo host Package $@
-	$(hide) mkdir -p $(dir $@)
-	$(hide) $(AAPT) package -u -A $(PRIVATE_ASSET_ROOT) -F $@
-
-$(LOCAL_INSTALLED_MODULE): | $(asset_target)
-
-ALL_DEFAULT_INSTALLED_MODULES += $(asset_target)
-
-endif # $(TARGET_SIMULATOR) == true
diff --git a/simulator/app/AssetStream.h b/simulator/app/AssetStream.h
deleted file mode 100644
index 0ab2d12..0000000
--- a/simulator/app/AssetStream.h
+++ /dev/null
@@ -1,102 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Provide a wxInputStream subclass based on the Android Asset class.
-// This is necessary because some wxWidgets functions require either a
-// filename or a wxInputStream (e.g. wxImage).
-//
-#ifndef _SIM_ASSETSTREAM_H
-#define _SIM_ASSETSTREAM_H
-
-#include "wx/stream.h"
-#include <utils/Asset.h>
-
-/*
- * There is no sample code or concrete documentation about providing
- * input streams, but it seems straightforward.  The PNG loading code
- * uses the following:
- *  OnSysTell()
- *  OnSysSeek()
- *  Read()
- *
- * The AssetStream takes ownership of the Asset.
- */
-class AssetStream : public wxInputStream {
-public:
-    AssetStream(android::Asset* pAsset)
-        : mpAsset(pAsset)
-        {}
-    virtual ~AssetStream(void) {
-        delete mpAsset;
-    }
-
-    virtual wxFileOffset GetLength() const {
-        //printf("## GetLength --> %ld\n", (long) mpAsset->getLength());
-        return mpAsset->getLength();
-    }
-    virtual size_t GetSize() const {
-        //printf("## GetSize --> %ld\n", (long) mpAsset->getLength());
-        return mpAsset->getLength();
-    }
-    virtual bool IsSeekable() const { return true; }
-
-    virtual bool Eof() const {
-        //printf("## Eof\n");
-        return (mpAsset->seek(0, SEEK_CUR) == mpAsset->getLength());
-    }
-
-    virtual bool CanRead() const {
-        //printf("## CanRead\n");
-        return !Eof();
-    }
-
-    virtual wxInputStream& Read(void* buffer, size_t size) {
-        OnSysRead(buffer, size);
-
-        return *this;
-    }
-
-protected:
-    /* read data, return number of bytes or 0 if EOF reached */
-    virtual size_t OnSysRead(void* buffer, size_t size) {
-        ssize_t actual = mpAsset->read(buffer, size);
-        if (actual < 0) {
-            // TODO: flag error
-            actual = 0;
-        }
-        //printf("## OnSysRead(%p %u) --> %d\n", buffer, size, actual);
-        return actual;
-    }
-
-    /* seek, using wxWidgets-defined values for "whence" */
-    virtual wxFileOffset OnSysSeek(wxFileOffset seek, wxSeekMode mode) {
-        int whence;
-        off_t newPosn;
-
-        if (mode == wxFromStart)
-            whence = SEEK_SET;
-        else if (mode == wxFromEnd)
-            whence = SEEK_END;
-        else
-            whence = SEEK_CUR;
-        newPosn = mpAsset->seek(seek, whence);
-        //printf("## OnSysSeek(%ld %d) --> %ld\n",
-        //    (long) seek, mode, (long) newPosn);
-        if (newPosn == (off_t) -1)
-            return wxInvalidOffset;
-        else
-            return newPosn;
-    }
-
-    virtual wxFileOffset OnSysTell() const {
-        //printf("## OnSysTell() --> %ld\n", (long) mpAsset->seek(0, SEEK_CUR));
-        return mpAsset->seek(0, SEEK_CUR);
-    }
-
-private:
-    android::Asset*     mpAsset;
-
-    DECLARE_NO_COPY_CLASS(AssetStream);     // private copy-ctor and op=
-};
-
-#endif // _SIM_ASSETSTREAM_H
diff --git a/simulator/app/DeviceManager.cpp b/simulator/app/DeviceManager.cpp
deleted file mode 100644
index a859c63..0000000
--- a/simulator/app/DeviceManager.cpp
+++ /dev/null
@@ -1,1220 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Management of the simulated device.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"
-
-#include "DeviceManager.h"
-#include "MyApp.h"
-#include "DeviceWindow.h"
-#include "LogWindow.h"
-#include "UserEvent.h"
-#include "UserEventMessage.h"
-
-#include "SimRuntime.h"
-#include "utils.h"
-
-#include <unistd.h>
-#include <signal.h>
-#include <errno.h>
-
-#if !defined(SIGKILL)      // doesn't exist in MinGW
-# if defined(SIGBREAK)
-#  define SIGKILL   SIGBREAK        // intended for Ctrl-Break
-# else
-#  define SIGKILL   SIGABRT
-# endif
-#endif
-
-
-/*
- * Constructor.
- */
-DeviceManager::DeviceManager(void)
-    : mThread(NULL), mDisplay(NULL), mNumDisplays(0), mKeyMap(NULL),
-      mpStatusWindow(NULL)
-{
-    //printf("--- DeviceManager constructor\n");
-}
-
-/*
- * Destructor.  Snuff the thread if it's still kicking.
- */
-DeviceManager::~DeviceManager(void)
-{
-    //printf("--- DeviceManager destructor\n");
-
-    if (mThread != NULL && mThread->IsRunning()) {
-        mThread->KillChildProcesses();
-    }
-    if (mThread != NULL) {
-        wxThread::ExitCode code;
-
-        printf("Sim: Waiting for old runtime thread..."); fflush(stdout);
-        code = mThread->Wait();        // join the old thread
-        printf("done (code=%ld)\n", (long) code);
-    }
-    delete mThread;
-    mThread = NULL;
-
-    delete[] mDisplay;
-    free((void*)mKeyMap);
-}
-
-/*
- * Initialize the device configuration.
- *
- * "statusWindow" is where message boxes with failure messages go, usually
- * the main frame.
- */
-bool DeviceManager::Init(int numDisplays, wxWindow* statusWindow)
-{
-    //if (IsRunning()) {
-    //    fprintf(stderr, "ERROR: tried to Configure device while running\n");
-    //    return false;
-    //}
-    assert(mDisplay == NULL);
-    assert(numDisplays > 0);
-
-    //if (mDisplay != NULL)
-    //     delete[] mDisplay;
-
-    mDisplay = new Display[numDisplays];
-    mNumDisplays = numDisplays;
-
-    mpStatusWindow = statusWindow;
-
-    return true;
-}
-
-/*
- * Have we been initialized already?
- */
-bool DeviceManager::IsInitialized(void) const
-{
-    return (mDisplay != NULL);
-}
-
-#if 0
-/*
- * Return the Nth display.
- */
-int DeviceManager::GetShmemKey(int displayIndex)
-{
-    assert(displayIndex >= 0 && displayIndex < mNumDisplays);
-    return mDisplay[displayIndex].GetShmemKey();
-}
-#endif
-
-/*
- * Define mapping between the device's display and a wxWidgets window.
- */
-bool DeviceManager::SetDisplayConfig(int displayIndex, wxWindow* window,
-    int width, int height, android::PixelFormat format, int refresh)
-{
-    assert(displayIndex >= 0 && displayIndex < mNumDisplays);
-
-    if (!mDisplay[displayIndex].Create(displayIndex, window, width, height,
-        format, refresh))
-    {
-        fprintf(stderr, "Sim: ERROR: unable to configure display %d\n",
-            displayIndex);
-        return false;
-    } else {
-        printf("Sim: configured display %d (w=%d h=%d f=%d re=%d)\n",
-            displayIndex, width, height, format, refresh);
-        return true;
-    }
-}
-
-/*
- * Define the keyboard
- */
-bool DeviceManager::SetKeyboardConfig(const char *keymap) {
-    free((void*)mKeyMap);
-    mKeyMap = strdup(keymap);
-    return true;
-}
-
-/*
- * Called before the phone window dialog destroys itself.  The goal here
- * is to prevent the runtime thread from trying to draw after the phone
- * window has closed for business but before the device manager destructor
- * gets called.
- */
-void DeviceManager::WindowsClosing(void)
-{
-    int i;
-
-    for (i = 0; i < mNumDisplays; i++)
-        mDisplay[i].Uncreate();
-}
-
-/*
- * Launch a new runtime process.  If there is an existing device manager
- * thread, we assume that it is in the process of shutting down.
- */
-bool DeviceManager::StartRuntime(void)
-{
-    return DeviceManager::DeviceThread::LaunchProcess(mpStatusWindow);
-}
-
-/*
- * Start the runtime management thread when a runtime connects to us.  If
- * there is an existing thread, we assume that it is in the process of
- * shutting down.
- */
-bool DeviceManager::StartRuntime(android::Pipe* reader, android::Pipe* writer)
-{
-    if (mThread != NULL) {
-        wxThread::ExitCode code;
-
-        if (mThread->IsRunning()) {
-            fprintf(stderr,
-                "Sim: ERROR: start requested, but thread running\n");
-            return false;
-        }
-
-        // clean up old thread
-        printf("Sim: Waiting for old runtime thread..."); fflush(stdout);
-        code = mThread->Wait();        // join the old thread
-        printf("done (code=%ld)\n", (long) code);
-
-        delete mThread;
-        mThread = NULL;
-    }
-
-    assert(mpStatusWindow != NULL);
-    mThread = new DeviceThread(this, mpStatusWindow, reader, writer);
-    if (mThread->Create() != wxTHREAD_NO_ERROR) {
-        fprintf(stderr, "Sim: ERROR: can't create thread\n");
-        return false;
-    }
-    mThread->Run();
-
-    return true;
-}
-
-/*
- * Get the message stream.  Returns NULL if it doesn't exist.
- */
-android::MessageStream* DeviceManager::GetStream(void)
-{
-    if (!IsRunning()) {
-        fprintf(stderr, "Sim: ERROR: runtime thread not active\n");
-        return NULL;
-    }
-
-    assert(mThread != NULL);
-    android::MessageStream* pStream = mThread->GetStream();
-    assert(pStream != NULL);
-
-    if (!pStream->isReady()) {
-        fprintf(stderr, "Sim: NOTE: connection to runtime not ready\n");
-        return NULL;
-    }
-
-    return pStream;
-}
-
-/*
- * Stop the runtime, politely.
- *
- * We don't clean up the thread here, because it might not exit immediately.
- */
-bool DeviceManager::StopRuntime(void)
-{
-    android::MessageStream* pStream = GetStream();
-    if (pStream == NULL)
-        return false;
-
-    printf("Sim: Sending quit command\n");
-
-    android::Message msg;
-    msg.setCommand(android::Simulator::kCommandQuit, 0);
-    pStream->send(&msg);
-    return true;
-}
-
-/*
- * Kill the runtime as efficiently as possible.
- */
-void DeviceManager::KillRuntime(void)
-{
-    if (mThread != NULL && mThread->IsRunning())
-        mThread->KillChildProcesses();
-}
-
-#if 0
-/*
- * Check if the modified time is newer than mLastModified
- */
-bool DeviceManager::RefreshRuntime(void)
-{
-    return (IsRunning() && mThread->IsRuntimeNew());
-}
-
-/*
- * Tells the device manager that the user does not want to update
- * the runtime
- */
-void DeviceManager::UserCancelledRefresh(void)
-{
-    mThread->UpdateLastModified();
-}
-#endif
-
-/*
- * Send an event to the runtime.
- *
- * The events are defined in display_device.h.
- */
-void DeviceManager::SendKeyEvent(KeyCode keyCode, bool down)
-{
-    android::MessageStream* pStream = GetStream();
-    if (pStream == NULL)
-        return;
-
-    int event = down ? android::Simulator::kCommandKeyDown :
-                       android::Simulator::kCommandKeyUp;
-
-    //printf("Sim: sending key-%s %d\n", down ? "down" : "up", keyCode);
-
-    android::Message msg;
-    msg.setCommand(event, keyCode);
-    pStream->send(&msg);
-}
-
-/*
- * Send a "touch screen" event to the runtime.
- *
- * "mode" can be "down" (we're pressing), "up" (we're lifting our finger
- * off) or "drag".
- */
-void DeviceManager::SendTouchEvent(android::Simulator::TouchMode mode,
-    int x, int y)
-{
-    android::MessageStream* pStream = GetStream();
-    if (pStream == NULL)
-        return;
-
-    //printf("Sim: sending touch-%d x=%d y=%d\n", (int) mode, x, y);
-
-    android::Message msg;
-    msg.setCommandExt(android::Simulator::kCommandTouch, mode, x, y);
-    pStream->send(&msg);
-}
-
-/*
- * The runtime has sent us a new frame of stuff to display.
- *
- * NOTE: we're still in the runtime management thread.  We have to pass the
- * bitmap through AddPendingEvent to get it over to the main thread.
- *
- * We have to make a copy of the data from the runtime; the easiest
- * way to do that is to convert it to a bitmap here.  However, X11 gets
- * all worked up about calls being made from multiple threads, so we're
- * better off just copying it into a buffer.
- *
- * Because we're decoupled from the runtime, there is a chance that we
- * could drop frames.  Buffering them up is probably worse, since it
- * creates the possibility that we could stall and run out of memory.
- * We could save a copy by handing the runtime a pointer to our buffer,
- * but then we'd have to mutex the runtime against the simulator window
- * Paint function.
- */
-void DeviceManager::ShowFrame(int displayIndex)
-{
-    assert(displayIndex >= 0 && displayIndex < mNumDisplays);
-
-    // copy the data to local storage and convert
-    mDisplay[displayIndex].CopyFromShared();
-
-    // create a user event and send it to the window
-    UserEvent uev(0, (void*) displayIndex);
-
-    wxWindow* pEventWindow = mDisplay[displayIndex].GetWindow();
-    if (pEventWindow != NULL) {
-        //printf("runtime has image, passing up\n");
-        pEventWindow->AddPendingEvent(uev);
-    } else {
-        fprintf(stderr, "NOTE: runtime has image, display not available\n");
-    }
-}
-
-void DeviceManager::Vibrate(int vibrateOn)
-{
-	((MyApp*)wxTheApp)->Vibrate(vibrateOn);
-}
-
-/*
- * Get the display data from the specified display.
- */
-wxBitmap* DeviceManager::GetImageData(int displayIndex)
-{
-    assert(displayIndex >= 0 && displayIndex < mNumDisplays);
-    return mDisplay[displayIndex].GetImageData();
-}
-
-/*
- * Send an event to all device windows
- */
-void DeviceManager::BroadcastEvent(UserEvent& userEvent) {
-    int numDisplays = GetNumDisplays();
-    for (int i = 0; i < numDisplays; i++) {
-        wxWindow* pEventWindow = mDisplay[i].GetWindow();
-        if (pEventWindow != NULL) {
-            pEventWindow->AddPendingEvent(userEvent);
-        }
-    }
-}
-
-
-/*
- * ===========================================================================
- *      DeviceManager::Display
- * ===========================================================================
- */
-
-/*
- * Fill out the various interesting fields based on the parameters.
- */
-bool DeviceManager::Display::Create(int displayNum, wxWindow* window,
-    int width, int height, android::PixelFormat format, int refresh)
-{
-    //printf("DeviceManager::Display constructor\n");
-
-    assert(window != NULL);
-    if (mImageData != NULL) {
-        assert(false);              // no re-init
-        return false;
-    }
-
-    mDisplayNum = displayNum;
-    mDisplayWindow = window;
-    mWidth = width;
-    mHeight = height;
-    mFormat = format;
-    mRefresh = refresh;
-
-    // use a fixed key for now
-    mShmemKey = GenerateKey(displayNum);
-    // allocate 24bpp for now
-    mpShmem = new android::Shmem;
-    if (!mpShmem->create(mShmemKey, width * height * 3, true))
-        return false;
-    //printf("--- CREATED shmem, key=0x%08x addr=%p\n",
-    //    mShmemKey, mpShmem->getAddr());
-
-    mImageData = new unsigned char[width * height * 3];
-    if (mImageData == NULL)
-        return false;
-
-    return true;
-}
-
-/*
- * The UI components are starting to shut down.  We need to do away with
- * our wxWindow pointer so that the runtime management thread doesn't try
- * to send it display update events.
- *
- * We also need to let go of our side of the shared memory, because a
- * new DeviceManager may get started up before our destructor gets called,
- * and we may be re-using the key.
- */
-void DeviceManager::Display::Uncreate(void)
-{
-    wxMutexLocker locker(mImageDataLock);
-
-    //printf("--- Uncreate\n");
-
-    mDisplayWindow = NULL;
-
-    // the "locker" mutex keeps this from hosing CopyFromShared()
-    if (mpShmem != NULL) {
-        //printf("--- DELETING shmem, addr=%p\n", mpShmem->getAddr());
-        delete mpShmem;
-        mpShmem = NULL;
-    }
-}
-
-/*
- * Make a local copy of the image data.  The UI grabs this data from a
- * different thread, so we have to mutex it.
- */
-void DeviceManager::Display::CopyFromShared(void)
-{
-    wxMutexLocker locker(mImageDataLock);
-
-    if (mpShmem == NULL) {
-        //printf("Sim: SKIP CopyFromShared\n");
-        return;
-    }
-
-    //printf("Display %d: copying data from %p to %p\n",
-    //    mDisplayNum, mpShmem->getAddr(), mImageData);
-
-    /* data is always 24bpp RGB */
-    mpShmem->lock();        // avoid tearing
-    memcpy(mImageData, mpShmem->getAddr(), mWidth * mHeight * 3);
-    mpShmem->unlock();
-}
-
-/*
- * Get the image data in the form of a newly-allocated bitmap.
- *
- * This MUST be called from the UI thread.  Creating wxBitmaps in the
- * runtime management thread will cause X11 failures (e.g.
- * "Xlib: unexpected async reply").
- */
-wxBitmap* DeviceManager::Display::GetImageData(void)
-{
-    wxMutexLocker locker(mImageDataLock);
-
-    assert(mImageData != NULL);
-
-    //printf("HEY: creating tmpImage, w=%d h=%d data=%p\n",
-    //    mWidth, mHeight, mImageData);
-
-    /* create a temporary wxImage; it does not own the data */
-    wxImage tmpImage(mWidth, mHeight, (unsigned char*) mImageData, true);
-
-    /* return a new bitmap with the converted-for-display data */
-    return new wxBitmap(tmpImage);
-}
-
-
-/*
- * ===========================================================================
- *      DeviceManager::DeviceThread
- * ===========================================================================
- */
-
-/*
- * Some notes on process management under Linux/Mac OS X:
- *
- * We want to put the runtime into its own process group.  That way we
- * can send SIGKILL to the entire group to guarantee that we kill it and
- * all of its children.  Simply killing the sim's direct descendant doesn't
- * do what we want.  If it's a debugger, we will just orphan the runtime
- * without killing it.  Even if the runtime is our child, the children of
- * the runtime might outlive it.
- *
- * We want to be able to run the child under GDB or Valgrind, both
- * of which take input from the tty.  They need to be in the "foreground"
- * process group.  We might be debugging or valgrinding the simulator,
- * or operating in a command-line-only "headless" mode, so in that case
- * the sim front-end should actually be in the foreground group.
- *
- * Putting the runtime in the background group means it can't read input
- * from the tty (not an issue) and will generate SIGTTOU signals when it
- * writes output to the tty (easy to ignore).  The trick, then, is to
- * have the simulator and gdb/valgrind in the foreground pgrp while the
- * runtime itself is in a different group.  This group needs to be known
- * to the simulator so that it can send signals to the appropriate place.
- *
- * The solution is to have the runtime process change its process group
- * after it starts but before it creates any new processes, and then send
- * the process group ID back to the simulator.  The sim can then send
- * signals to the pgrp to ensure that we don't end up with zombies.  Any
- * "pre-launch" processes, like GDB, stay in the sim's pgrp.  This also
- * allows a consistent API for platforms that don't have fork/exec
- * (e.g. MinGW).
- *
- * This doesn't help us with interactive valgrind (e.g. --db-attach=yes),
- * because valgrind is an LD_PRELOAD shared library rather than a
- * separate process.  For that, we actually need to use termios(3) to
- * change the terminal's pgrp, or the interactive stuff just doesn't work.
- * We don't want to do that every time or attempting to debug the simulator
- * front-end will have difficulties.
- *
- * Making this even more entertaining is the fact that the simulator
- * front-end could itself be launched in the background.  It's essential
- * that we be careful about assigning a process group to the foreground,
- * and that we don't restore ourselves unless we were in the foreground to
- * begin with.
- *
- *
- * Some notes on process management under Windows (Cygwin, MinGW):
- *
- * Signals cannot be caught or ignored under MinGW.  All signals are fatal.
- *
- * Signals can be ignored under Cygwin, but not caught.
- *
- * Windows has some process group stuff (e.g. CREATE_NEW_PROCESS_GROUP flag
- * and GenerateConsoleCtrlEvent()).  Need to explore.
- *
- *
- * UPDATE: we've abandoned Mac OS and MinGW, so we now launch the runtime in
- * a separate xterm.  This avoids all tty work on our side.  We still need
- * to learn the pgrp from the child during the initial communication
- * handshake so we can do necessary cleanup.
- */
-
-
-/*
- * Convert a space-delimited string into an argument vector.
- *
- * "arg" is the current arg offset.
- */
-static int stringToArgv(char* mangle, const char** argv, int arg, int maxArgs)
-{
-    bool first = true;
-
-    while (*mangle != '\0') {
-        assert(arg < maxArgs);
-        if (first) {
-            argv[arg++] = mangle;
-            first = false;
-        }
-        if (*mangle == ' ') {
-            *mangle = '\0';
-            first = true;
-        }
-        mangle++;
-    }
-
-    return arg;
-}
-
-/*
- * Launch the runtime process in its own terminal window.  Start by setting
- * up the argument vector to the runtime process.
- *
- * The last entry in the vector will be a NULL pointer.
- *
- * This is awkward and annoying because the wxWidgets strings are current
- * configured for UNICODE.
- */
-/*static*/ bool DeviceManager::DeviceThread::LaunchProcess(wxWindow* statusWindow)
-{
-    static const char* kLaunchWrapper = "launch-wrapper";
-    const int kMaxArgs = 64;
-    Preferences* pPrefs;
-    wxString errMsg;
-    wxString runtimeExe;
-    wxString debuggerExe;
-	wxString debuggerScript;
-    wxString valgrinderExe;
-    wxString launchWrapperExe;
-    wxString launchWrapperArgs;
-    wxString javaAppName;
-    wxString termCmd;
-    wxString tmpStr;
-    char gammaVal[8];
-    //bool bval;
-    double dval;
-    bool result = false;
-    bool doDebug, doValgrind, doCheckJni, doEnableSound, doEnableFakeCamera;
-    const char** argv = NULL;
-    int arg;
-    wxCharBuffer runtimeExeTmp;
-    wxCharBuffer debuggerExeTmp;
-	wxCharBuffer debuggerScriptTmp;
-    wxCharBuffer javaAppNameTmp;
-    wxCharBuffer valgrinderExeTmp;
-    wxCharBuffer termCmdTmp;
-    wxCharBuffer launchWrapperExeTmp;
-    wxCharBuffer launchWrapperArgsTmp;
-    
-    pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    if (pPrefs == NULL) {
-        errMsg = wxT("Preferences were not loaded.");
-        goto bail;
-    }
-
-    /*
-     * Set environment variables.  This stuff should be passed through as
-     * arguments, but the runtime binary currently has a disconnect
-     * between main() and the VM initilization.
-     *
-     * TODO: remove this in favor of system properties
-     */
-#if 0
-    // TODO: restore this
-    doCheckJni = false;
-    pPrefs->GetBool("check-jni", &doCheckJni);
-#endif
-
-    tmpStr.Empty();
-    pPrefs->GetString("ld-assume-kernel", /*ref*/ tmpStr);
-    if (tmpStr.IsEmpty()) {
-        unsetenv("LD_ASSUME_KERNEL");
-    } else {
-        setenv("LD_ASSUME_KERNEL", tmpStr.ToAscii(), 1);
-    }
-
-    doEnableSound = false; 
-    pPrefs->GetBool("enable-sound", &doEnableSound);
-    if (doEnableSound)
-        setenv("ANDROIDSOUND", "1", 1);
-
-    doEnableFakeCamera = false; 
-    pPrefs->GetBool("enable-fake-camera", &doEnableFakeCamera);
-    if (doEnableFakeCamera)
-        setenv("ANDROIDFAKECAMERA", "1", 1);
-
-    /*
-     * Set the Dalvik bootstrap class path.  Normally this is set by "init".
-     */
-    setenv("BOOTCLASSPATH",
-        "/system/framework/core.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/android.policy.jar:/system/framework/services.jar",
-        1);
-
-    /*
-     * Figure out where the "runtime" binary lives.
-     */
-    runtimeExe = ((MyApp*)wxTheApp)->GetRuntimeExe();
-    assert(!runtimeExe.IsEmpty());
-
-    //UpdateLastModified();
-
-    /*
-     * Initialize argv.
-     */
-    argv = new const char*[kMaxArgs];
-    if (argv == NULL)
-        goto bail;
-    arg = 0;
-
-    /*
-     * We want to launch the runtime in its own terminal window so we don't
-     * have to fight over who gets access to the controlling tty.  We allow
-     * the user to specify the command they want to use to perform the
-     * launch.  Here we cut it into pieces for argv.
-     *
-     * To make life easier here, we require that the launch command be
-     * all one piece, i.e. it's not "xterm -e <stuff> -geom blah" with our
-     * stuff in the middle.
-     */
-    termCmd.Empty();
-    pPrefs->GetString("launch-command", /*ref*/ termCmd);
-    if (termCmd.IsEmpty()) {
-        fprintf(stderr, "Sim: WARNING: launch-command is empty\n");
-    } else {
-        termCmdTmp = termCmd.ToAscii();
-        char* mangle = strdup(termCmdTmp);
-        arg = stringToArgv(mangle, argv, arg, kMaxArgs);
-    }
-
-    /*
-     * The "launch-wrapper" binary lives in the same place as the runtime.
-     * This sets up LD_PRELOAD and some other environment variables.
-     */
-    int charIdx;
-
-    charIdx = runtimeExe.Find('/', true);
-    if (charIdx == -1) {
-        launchWrapperExe = wxString::FromAscii(kLaunchWrapper);
-    } else {
-        launchWrapperExe = runtimeExe.Mid(0, charIdx+1);
-        launchWrapperExe.Append(wxString::FromAscii(kLaunchWrapper));
-    }
-    printf("Sim launch wrapper: %s\n", (const char*)launchWrapperExe.ToAscii());
-
-    argv[arg++] = launchWrapperExeTmp = launchWrapperExe.ToAscii();
-
-    launchWrapperArgs.Empty();
-    pPrefs->GetString("launch-wrapper-args", /*ref*/ launchWrapperArgs);
-    if (!launchWrapperArgs.IsEmpty()) {
-        launchWrapperArgsTmp = launchWrapperArgs.ToAscii();
-        char* mangle = strdup(launchWrapperArgsTmp);
-        arg = stringToArgv(mangle, argv, arg, kMaxArgs);
-    }
-
-    /*
-     * If we're launching under GDB or valgrind, set that up.
-     */
-    doDebug = doValgrind = false;
-    pPrefs->GetBool("debug", &doDebug);
-    if (((MyApp*)wxTheApp)->GetDebuggerOption()) {
-        doDebug = true;
-    }
-	debuggerScript = ((MyApp*)wxTheApp)->GetDebuggerScript();
-
-    pPrefs->GetBool("valgrind", &doValgrind);
-    if (doDebug || doValgrind) {
-
-        pPrefs->GetString("debugger", /*ref*/ debuggerExe);
-        pPrefs->GetString("valgrinder", /*ref*/ valgrinderExe);
-
-        // check for empty or undefined preferences
-        if (doDebug && debuggerExe.IsEmpty()) {
-            errMsg = wxT("Debugger not defined.");
-            goto bail;
-        }
-        if (doValgrind && valgrinderExe.IsEmpty()) {
-            errMsg = wxT("Valgrinder not defined.");
-            goto bail;
-        }
-
-        if (doValgrind) {
-            argv[arg++] = valgrinderExeTmp = valgrinderExe.ToAscii();
-            //argv[arg++] = "--tool=callgrind";
-            argv[arg++] = "--tool=memcheck";
-            argv[arg++] = "--leak-check=yes";       // check for leaks too
-            argv[arg++] = "--leak-resolution=med";  // increase from 2 to 4
-            argv[arg++] = "--num-callers=8";        // reduce from 12 to 8
-            //argv[arg++] = "--show-reachable=yes";   // show still-reachable
-            if (doDebug) {
-                //mTerminalFollowsChild = true;   // interactive
-                argv[arg++] = "--db-attach=yes";
-            }
-            //mSlowExit = true;
-        } else /*doDebug*/ {
-            argv[arg++] = debuggerExeTmp = debuggerExe.ToAscii();
-			if (!debuggerScript.IsEmpty()) {
-				argv[arg++] = "-x";
-				argv[arg++] = debuggerScriptTmp = debuggerScript.ToAscii();
-			}
-            argv[arg++] = runtimeExeTmp = runtimeExe.ToAscii();
-            argv[arg++] = "--args";
-        }
-    }
-
-    /*
-     * Get runtime args.
-     */
-
-    argv[arg++] = runtimeExeTmp = (const char*) runtimeExe.ToAscii();
-
-    javaAppName = ((MyApp*)wxTheApp)->GetAutoRunApp();
-    if (javaAppName.IsEmpty()) {
-        if (!pPrefs->GetString("java-app-name", /*ref*/ javaAppName)) {
-            javaAppName = wxT("");
-        }
-    }
-
-    if (!javaAppName.IsEmpty())
-    {
-        argv[arg++] = "-j";
-        argv[arg++] = javaAppNameTmp = (const char*) javaAppName.ToAscii();
-    }
-
-    if (pPrefs->GetDouble("gamma", &dval) && dval != 1.0) {
-        snprintf(gammaVal, sizeof(gammaVal), "%.3f", dval);
-        argv[arg++] = "-g";
-        argv[arg++] = gammaVal;
-    }
-
-    /* finish arg set */
-    argv[arg++] = NULL;
-
-    assert(arg <= kMaxArgs);
-
-#if 1
-    printf("ARGS:\n");
-    for (int i = 0; i < arg; i++)
-        printf(" %d: '%s'\n", i, argv[i]);
-#endif
-
-    if (fork() == 0) {
-        execvp(argv[0], (char* const*) argv);
-        fprintf(stderr, "execvp '%s' failed: %s\n", argv[0], strerror(errno));
-        exit(1);
-    }
-
-    /*
-     * We assume success; if it didn't succeed we'll just sort of hang
-     * out waiting for a connection.  There are ways to fix this (create
-     * a non-close-on-exec pipe and watch to see if the other side closes),
-     * but at this stage it's not worthwhile.
-     */
-    result = true;
-
-    tmpStr = wxT("=== launched ");
-    tmpStr += runtimeExe;
-    LogWindow::PostLogMsg(tmpStr);
-
-    assert(errMsg.IsEmpty());
-
-bail:
-    if (!errMsg.IsEmpty()) {
-        assert(result == false);
-
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateErrorMessage(errMsg);
-
-        UserEvent uev(0, (void*) pUem);
-
-        assert(statusWindow != NULL);
-        statusWindow->AddPendingEvent(uev);
-    }
-    delete[] argv;
-    return result;
-}
-
-/*
- * This is the entry point for the device thread.  The thread launches the
- * runtime process and monitors it.  When the runtime exits, the thread
- * exits.
- *
- * Because this isn't running in the UI thread, any user interaction has
- * to be channeled through "user events" to the appropriate window.
- */
-void* DeviceManager::DeviceThread::Entry(void)
-{
-    //android::MessageStream stream;
-    android::Message msg;
-    wxString errMsg;
-    char statusBuf[64] = "(no status)";
-    int result = 1;
-
-    /* print this so we can make sense of log messages */
-    LOG(LOG_DEBUG, "", "Sim: device management thread starting (pid=%d)\n",
-        getpid());
-
-    assert(mReader != NULL && mWriter != NULL);
-
-    /*
-     * Tell the main thread that we're running.  If something fails here,
-     * we'll send them a "stopped running" immediately afterward.
-     */
-    {
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateRuntimeStarted();
-
-        UserEvent uev(0, (void*) pUem);
-
-        assert(mpStatusWindow != NULL);
-        mpStatusWindow->AddPendingEvent(uev);
-    }
-    LogWindow::PostLogMsg(
-            "==============================================================");
-    LogWindow::PostLogMsg("=== runtime starting");
-
-    /*
-     * Establish contact with runtime.
-     */
-    if (!mStream.init(mReader, mWriter, true)) {
-        errMsg = wxT("ERROR: Unable to establish communication with runtime.\n");
-        goto bail;
-    }
-
-    /*
-     * Tell the runtime to put itself into a new process group and set
-     * itself up as the foreground process.  The latter is only really
-     * necessary to make valgrind+gdb work.
-     */
-    msg.setCommand(android::Simulator::kCommandNewPGroup, true);
-    mStream.send(&msg);
-
-    printf("Sim: Sending hardware configuration\n");
-
-    /*
-     * Send display config.
-     *
-     * Right now we're just shipping a big binary blob over.
-     */
-    assert(android::Simulator::kValuesPerDisplay >= 5);
-    int buf[1 + 1 + mpDeviceManager->GetNumDisplays() *
-                    android::Simulator::kValuesPerDisplay];
-    buf[0] = android::Simulator::kDisplayConfigMagic;
-    buf[1] = mpDeviceManager->GetNumDisplays();
-    for (int i = 0; i < mpDeviceManager->GetNumDisplays(); i++) {
-        DeviceManager::Display* pDisplay = mpDeviceManager->GetDisplay(i);
-        int* pBuf = &buf[2 + android::Simulator::kValuesPerDisplay * i];
-
-        pBuf[0] = pDisplay->GetWidth();
-        pBuf[1] = pDisplay->GetHeight();
-        pBuf[2] = pDisplay->GetFormat();
-        pBuf[3] = pDisplay->GetRefresh();
-        pBuf[4] = pDisplay->GetShmemKey();
-    }
-    msg.setRaw((const unsigned char*)buf, sizeof(buf),
-        android::Message::kCleanupNoDelete);
-    mStream.send(&msg);
-
-    /*
-     * Send other hardware config.
-     *
-     * Examples:
-     * - Available input devices.
-     * - Set of buttons on device.
-     * - External devices (Bluetooth, etc).
-     * - Initial mode (e.g. "flipped open" vs. "flipped closed").
-     */
-
-    msg.setConfig("keycharmap", mpDeviceManager->GetKeyMap());
-    mStream.send(&msg);
-
-    /*
-     * Done with config.
-     */
-    msg.setCommand(android::Simulator::kCommandConfigDone, 0);
-    mStream.send(&msg);
-
-    /*
-     * Sit forever, waiting for messages from the runtime process.
-     */
-    while (1) {
-        if (!mStream.recv(&msg, true)) {
-            /*
-             * The read failed.  This usually means the child has died.
-             */
-            printf("Sim: runtime process has probably died\n");
-            break;
-        }
-
-        if (msg.getType() == android::Message::kTypeCommand) {
-            int cmd, arg;
-
-            if (!msg.getCommand(&cmd, &arg)) {
-                fprintf(stderr, "Sim: Warning: failed unpacking command\n");
-                /* keep going? */
-            } else {
-                switch (cmd) {
-                case android::Simulator::kCommandNewPGroupCreated:
-                    // runtime has moved into a separate process group
-                    // (not expected for external)
-                    printf("Sim: child says it's now in pgrp %d\n", arg);
-                    mRuntimeProcessGroup = arg;
-                    break;
-                case android::Simulator::kCommandRuntimeReady:
-                    // sim is up and running, do late init
-                    break;
-                case android::Simulator::kCommandUpdateDisplay:
-                    // new frame of graphics is ready
-                    //printf("RCVD display update %d\n", arg);
-                    mpDeviceManager->ShowFrame(arg);
-                    break;
-                case android::Simulator::kCommandVibrate:
-                    // vibrator on or off
-                    //printf("RCVD vibrator update %d\n", arg);
-                    mpDeviceManager->Vibrate(arg);
-                    break;
-                default:
-                    printf("Sim: got unknown command %d/%d\n", cmd, arg);
-                    break;
-                }
-            }
-        } else if (msg.getType() == android::Message::kTypeLogBundle) {
-            android_LogBundle bundle;
-
-            if (!msg.getLogBundle(&bundle)) {
-                fprintf(stderr, "Sim: Warning: failed unpacking logBundle\n");
-                /* keep going? */
-            } else {
-                LogWindow::PostLogMsg(&bundle);
-            }
-        } else {
-            printf("Sim: got unknown message type=%d\n", msg.getType());
-        }
-    }
-
-    result = 0;
-
-bail:
-    printf("Sim: DeviceManager thread preparing to exit\n");
-
-    /* kill the comm channel; should encourage runtime to die */
-    mStream.close();
-    delete mReader;
-    delete mWriter;
-    mReader = mWriter = NULL;
-
-    /*
-     * We never really did get a "friendly death" working, so just slam
-     * the thing if we have the process group.
-     */
-    if (mRuntimeProcessGroup != 0) {
-        /* kill the group, not our immediate child */
-        printf("Sim: killing pgrp %d\n", (int) mRuntimeProcessGroup);
-        kill(-mRuntimeProcessGroup, 9);
-    }
-
-    if (!errMsg.IsEmpty()) {
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateErrorMessage(errMsg);
-
-        UserEvent uev(0, (void*) pUem);
-        mpStatusWindow->AddPendingEvent(uev);
-    }
-
-    /* notify the main window that the runtime has stopped */
-    {
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateRuntimeStopped();
-
-        UserEvent uev(0, (void*) pUem);
-        mpStatusWindow->AddPendingEvent(uev);
-    }
-
-    /* show exit status in log file */
-    wxString exitMsg;
-    exitMsg.Printf(wxT("=== runtime exiting - %s"), statusBuf);
-    LogWindow::PostLogMsg(exitMsg);
-    LogWindow::PostLogMsg(
-        "==============================================================\n");
-
-    /*
-     * Reset system properties for future runs.
-     */
-    ResetProperties();
-
-    return (void*) result;
-}
-
-
-/*
- * Wait for a little bit to see if the thread will exit.
- *
- * "delay" is in 0.1s increments.
- */
-void DeviceManager::DeviceThread::WaitForDeath(int delay)
-{
-    const int kDelayUnit = 100000;
-    int i;
-
-    for (i = 0; i < delay; i++) {
-        if (!IsRunning())
-            return;
-        usleep(kDelayUnit);
-    }
-}
-
-
-/*
- * Kill the runtime process.  The goal is to cause our local runtime
- * management thread to exit.  If it doesn't, this will kill the thread
- * before it returns.
- */
-void DeviceManager::DeviceThread::KillChildProcesses(void)
-{
-    if (!this->IsRunning())
-        return;
-
-    /* clear "slow exit" flag -- we're forcefully killing this thing */
-    //this->mSlowExit = false;
-
-    /*
-     * Use the ChildProcess object in the thread to send signals.  There's
-     * a risk that the DeviceThread will exit and destroy the object while
-     * we're using it.  Using a mutex here gets a little awkward because
-     * we can't put it in DeviceThread.  It's easier to make a copy of
-     * ChildProcess and operate on the copy, but we have to do that very
-     * carefully to avoid interfering with the communcation pipes.
-     *
-     * For now, we just hope for the best.  FIX this someday.
-     *
-     * We broadcast to the process group, which will ordinarily kill
-     * everything.  If we're running with valgrind+GDB everything is in our
-     * pgrp and we can't do the broadcast; if GDB alone, then only GDB is
-     * in our pgrp, so the broadcast will hit everything except it.  We
-     * hit the group and then hit our child for good measure.
-     */
-    if (mRuntimeProcessGroup != 0) {
-        /* kill the group, not our immediate child */
-        printf("Sim: killing pgrp %d\n", (int) mRuntimeProcessGroup);
-        kill(-mRuntimeProcessGroup, 9);
-        WaitForDeath(15);
-    }
-
-    /*
-     * Close the communication channel.  This should cause our thread
-     * to snap out of its blocking read and the runtime thread to bail
-     * out the next time it tries to interact with us.  We should only
-     * get here if somebody other than our direct descendant has the
-     * comm channel open and our broadcast didn't work, which should
-     * no longer be possible.
-     */
-    if (this->IsRunning()) {
-        printf("Sim: killing comm channel\n");
-        mStream.close();
-        delete mReader;
-        delete mWriter;
-        mReader = mWriter = NULL;
-        WaitForDeath(15);
-    }
-
-    /*
-     * At this point it's possible that our DeviceThread is just wedged.
-     * Kill it.
-     *
-     * Using the thread Kill() function can orphan resources, including
-     * locks and semaphores.  There is some risk that the simulator will
-     * be hosed after this.
-     */
-    if (this->IsRunning()) {
-        fprintf(stderr, "Sim: WARNING: killing runtime thread (%ld)\n",
-            (long) GetId());
-        this->Kill();
-        WaitForDeath(15);
-    }
-
-    /*
-     * Now I'm scared.
-     */
-    if (this->IsRunning()) {
-        fprintf(stderr, "Sim: thread won't die!\n");
-    }
-}
-
-
-/*
- * Configure system properties for the simulated device.
- *
- * Property requests can arrive *before* the full connection to the
- * simulator is established, so we want to reset these during cleanup.
- */
-void DeviceManager::DeviceThread::ResetProperties(void)
-{
-	wxWindow* mainFrame = ((MyApp*)wxTheApp)->GetMainFrame();
-    PropertyServer* props = ((MainFrame*)mainFrame)->GetPropertyServer();
-
-    props->ClearProperties();
-    props->SetDefaultProperties();
-}
-
-
-#if 0
-/*
- * Return true if the executable found is newer than
- * what is currently running
- */
-bool DeviceManager::DeviceThread::IsRuntimeNew(void)
-{
-    if (mLastModified == 0) {
-        /*
-         * Haven't called UpdateLastModified yet, or called it but
-         * couldn't stat() the executable.
-         */
-        return false;
-    }
-
-    struct stat status;
-    if (stat(mRuntimeExe.ToAscii(), &status) == 0) {
-        return (status.st_mtime > mLastModified);
-    } else {
-        // doesn't exist, so it can't be newer
-        fprintf(stderr, "Sim: unable to stat '%s': %s\n",
-            (const char*) mRuntimeExe.ToAscii(), strerror(errno));
-        return false;
-    }
-}
-
-/*
- * Updates mLastModified to reflect the current executables mtime
- */
-void DeviceManager::DeviceThread::UpdateLastModified(void)
-{
-    struct stat status;
-    if (stat(mRuntimeExe.ToAscii(), &status) == 0) {
-        mLastModified = status.st_mtime;
-    } else {
-        fprintf(stderr, "Sim: unable to stat '%s': %s\n",
-            (const char*) mRuntimeExe.ToAscii(), strerror(errno));
-        mLastModified = 0;
-    }
-}
-#endif
-
diff --git a/simulator/app/DeviceManager.h b/simulator/app/DeviceManager.h
deleted file mode 100644
index bd4371e..0000000
--- a/simulator/app/DeviceManager.h
+++ /dev/null
@@ -1,284 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Class that manages the simulated device.
-//
-#ifndef _SIM_DEVICE_MANAGER_H
-#define _SIM_DEVICE_MANAGER_H
-
-#include "UserEvent.h"
-
-#include "Shmem.h"
-#include "MessageStream.h"
-#include "SimRuntime.h"
-
-#include "ui/PixelFormat.h"
-#include "ui/KeycodeLabels.h"
-
-#include <sys/stat.h>
-
-/*
- * Manage the simulated device.  This includes starting/stopping as well
- * as sending messages to it and receiving events from it.
- *
- * The object may span multiple invocations of a specific device.  If
- * the simulator is reconfigured to use a device with different
- * characteristics, the object should be destroyed and recreated (which
- * guarantees that the runtime is restarted).
- */
-class DeviceManager {
-public:
-    DeviceManager(void);
-    virtual ~DeviceManager(void);
-
-    /*
-     * Initialize the object.  Call this once.
-     *
-     * "numDisplays" is the number of displays that the simulated hardware
-     * supports.  The displays themselves are configured with separate calls.
-     *
-     * "statusWindow" should be the main frame.  Messages indicating runtime
-     * startup/shutdown are sent, as well as error messages that should be
-     * displayed in message boxes.
-     */
-    bool Init(int numDisplays, wxWindow* statusWindow);
-    bool IsInitialized(void) const;
-
-    /*
-     * Tell the device manager that the windows used to display its output
-     * are closing down.
-     */
-    void WindowsClosing(void);
-
-    /*
-     * "displayWindow" is the window to notify when a new frame of graphics
-     * data is available.  This can be set independently for each display.
-     */
-    bool SetDisplayConfig(int displayIndex, wxWindow* window,
-        int width, int height, android::PixelFormat format, int refresh);
-
-    /*
-     * set the key map
-     */
-    bool SetKeyboardConfig(const char *keymap);
-
-    /*
-     * Return the number of displays we're configured for.
-     */
-    int GetNumDisplays(void) const { return mNumDisplays; }
-
-    /*
-     * Return the shmem key for the Nth display.
-     */
-    //int GetShmemKey(int displayIndex);
-
-    /*
-     * Is the runtime process still running?
-     */
-    bool IsRunning(void) const {
-        if (mThread != NULL)
-            return mThread->IsRunning();
-        return false;
-    }
-    bool IsKillable(void) const {
-        return true;
-    }
-
-    // (Re-)configure the device, e.g. when #of displays changes because
-    // a different phone model has been selected.  Call this before doing
-    // any display-specific setup.  DO NOT call this if the runtime is active.
-//    void Configure(int numDisplays);
-
-    // start the runtime, acting as parent
-    bool StartRuntime(void);
-    // start the runtime, acting as peer
-    bool StartRuntime(android::Pipe* reader, android::Pipe* writer);
-    // politely ask the runtime to stop
-    bool StopRuntime(void);
-    // kill the runtime with extreme prejudice
-    void KillRuntime(void);
-
-#if 0
-    // Returns if the executable is new
-    bool RefreshRuntime(void);
-    // Update the time of the current runtime because the user cancelled a
-    // refresh
-    void UserCancelledRefresh(void);
-#endif
-
-    // send a key-up or key-down event to the runtime
-    void SendKeyEvent(KeyCode keyCode, bool down);
-    // send touch-screen events
-    void SendTouchEvent(android::Simulator::TouchMode mode, int x, int y);
-
-    wxBitmap* GetImageData(int displayIndex);
-    
-    void BroadcastEvent(UserEvent &userEvent);
-
-private:
-    /*
-     * Threads in wxWidgets use sub-classing to define interfaces and
-     * entry points.  We use this to create the thread that interacts
-     * with the runtime.
-     *
-     * The "reader" and "writer" arguments may be NULL.  If they are,
-     * we will launch the runtime ourselves.  If not, we will use them
-     * to speak with an externally-launched runtime process.  The thread
-     * will own the pipes, shutting them down when it exits.
-     */
-    class DeviceThread : public wxThread {
-    public:
-        DeviceThread(DeviceManager* pDM, wxWindow* pStatusWindow,
-            android::Pipe* reader, android::Pipe* writer)
-            : wxThread(wxTHREAD_JOINABLE), mpStatusWindow(pStatusWindow),
-              mReader(reader), mWriter(writer),
-              mpDeviceManager(pDM), /*mTerminalFollowsChild(false),
-              mSlowExit(false), mIsExternal(false), mLastModified(0),*/
-              mRuntimeProcessGroup(0)
-            {}
-        virtual ~DeviceThread(void) {
-            delete mReader;
-            delete mWriter;
-        }
-
-        /* thread entry point */
-        virtual void* Entry(void);
-
-        // wxThread class supplies an IsRunning() method
-
-        /*
-         * This kills the runtime process to force this thread to exit.
-         * If the thread doesn't exit after a short period of time, it
-         * is forcibly terminated.
-         */
-        void KillChildProcesses(void);
-
-#if 0
-        /*
-         * Return if the runtime executable is new
-         */
-        bool IsRuntimeNew(void);
-
-        void UpdateLastModified(void);
-#endif
-
-        android::MessageStream* GetStream(void) { return &mStream; }
-
-        static bool LaunchProcess(wxWindow* statusWindow);
-
-    private:
-        void WaitForDeath(int delay);
-        void ResetProperties(void);
-
-        android::MessageStream  mStream;
-        wxWindow*       mpStatusWindow;
-        android::Pipe*  mReader;
-        android::Pipe*  mWriter;
-        DeviceManager*  mpDeviceManager;
-        pid_t           mRuntimeProcessGroup;
-        //time_t          mLastModified;
-        wxString        mRuntimeExe;
-    };
-
-    friend class DeviceThread;
-
-    /*
-     * We need one of these for each display on the device.  Most devices
-     * only have one, but some flip phones have two.
-     */
-    class Display {
-    public:
-        Display(void)
-            : mDisplayWindow(NULL), mpShmem(NULL), mShmemKey(0),
-              mImageData(NULL), mDisplayNum(-1), mWidth(-1), mHeight(-1),
-              mFormat(android::PIXEL_FORMAT_UNKNOWN), mRefresh(0)
-            {}
-        ~Display() {
-            delete mpShmem;
-            delete[] mImageData;
-        }
-
-        /* initialize goodies */
-        bool Create(int displayNum, wxWindow* window, int width, int height,
-            android::PixelFormat format, int refresh);
-
-        /* call this if we're shutting down soon */
-        void Uncreate(void);
-
-        /* copy & convert data from shared memory */
-        void CopyFromShared(void);
-
-        /* get image data in the form of a 24bpp bitmap */
-        wxBitmap* GetImageData(void);
-
-        /* get a pointer to our display window */
-        wxWindow* GetWindow(void) const { return mDisplayWindow; }
-
-        /* get our shared memory key */
-        int GetShmemKey(void) const { return mShmemKey; }
-
-        int GetWidth(void) const { return mWidth; }
-        int GetHeight(void) const { return mHeight; }
-        android::PixelFormat GetFormat(void) const { return mFormat; }
-        int GetRefresh(void) const { return mRefresh; }
-
-    private:
-        int GenerateKey(int displayNum) {
-            return 0x41544d00 | displayNum;
-        }
-
-        // control access to image data shared between runtime mgr and UI
-        wxMutex         mImageDataLock;
-        // we send an event here when we get stuff to display
-        wxWindow*       mDisplayWindow;
-
-        // shared memory segment
-        android::Shmem* mpShmem;
-        int             mShmemKey;
-
-        // local copy of data from shared mem, converted to 24bpp
-        unsigned char*  mImageData;
-
-        // mainly for debugging -- which display are we?
-        int             mDisplayNum;
-
-        // display characteristics
-        int             mWidth;
-        int             mHeight;
-        android::PixelFormat mFormat;
-        int             mRefresh;       // fps
-    };
-
-    Display* GetDisplay(int dispNum) { return &mDisplay[dispNum]; }
-
-    const char* GetKeyMap() { return mKeyMap ? mKeyMap : "qwerty"; }
-
-    void ShowFrame(int displayIndex);
-
-    void Vibrate(int vibrateOn);
-
-    // get the message stream from the device thread
-    android::MessageStream* GetStream(void);
-
-    // send a request to set the visible layers
-    void SendSetVisibleLayers(void);
-
-    // points at the runtime's thread (while it's running)
-    DeviceThread*   mThread;
-
-    // array of Displays, one per display on the device
-    Display*        mDisplay;
-    int             mNumDisplays;
-
-    // the key map
-    const char * mKeyMap;
-
-    // which graphics layers are visible?
-    int             mVisibleLayers;
-
-    // where to send status messages
-    wxWindow*       mpStatusWindow;
-
-};
-
-#endif // _SIM_DEVICE_MANAGER_H
diff --git a/simulator/app/DeviceWindow.cpp b/simulator/app/DeviceWindow.cpp
deleted file mode 100644
index a15b03b..0000000
--- a/simulator/app/DeviceWindow.cpp
+++ /dev/null
@@ -1,264 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Displays output from the device.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-#include "wx/dcbuffer.h"
-
-#include "AssetStream.h"
-#include "DeviceWindow.h"
-#include "MyApp.h"
-#include "Preferences.h"
-
-BEGIN_EVENT_TABLE(DeviceWindow, wxWindow)
-    EVT_SIZE(DeviceWindow::OnSize)
-    EVT_ERASE_BACKGROUND(DeviceWindow::OnErase)
-    EVT_PAINT(DeviceWindow::OnPaint)
-    EVT_KEY_DOWN(DeviceWindow::OnKeyDown)
-    EVT_KEY_UP(DeviceWindow::OnKeyUp)
-
-    EVT_LEFT_DOWN(DeviceWindow::OnMouseLeftDown)
-    EVT_LEFT_DCLICK(DeviceWindow::OnMouseLeftDown)
-    EVT_LEFT_UP(DeviceWindow::OnMouseLeftUp)
-    EVT_RIGHT_DOWN(DeviceWindow::OnMouseRightDown)
-    EVT_RIGHT_DCLICK(DeviceWindow::OnMouseRightDown)
-    EVT_RIGHT_UP(DeviceWindow::OnMouseRightUp)
-    EVT_MOTION(DeviceWindow::OnMouseMotion)
-
-    EVT_USER_EVENT(DeviceWindow::OnUserEvent)
-END_EVENT_TABLE()
-
-
-/*
- * Create a new DeviceWindow.  This should be a child of PhoneWindow.
- *
- * Note the DeviceManager may not be fully initialized yet.
- */
-DeviceWindow::DeviceWindow(wxWindow* parent, DeviceManager* pDM)
-    : wxWindow(parent, wxID_ANY, wxDefaultPosition, wxDefaultSize,
-        wxNO_BORDER | wxWANTS_CHARS),
-      mpDeviceManager(pDM)
-{
-    //printf("DW: created (parent=%p DM=%p)\n", parent, pDM);
-
-    SetBackgroundStyle(wxBG_STYLE_CUSTOM);
-
-    // create a trivial bitmap so we have something allocated
-    mBitmap.Create(1, 1);
-
-}
-
-/*
- * Destructor.
- */
-DeviceWindow::~DeviceWindow(void)
-{
-}
-
-/*
- * We don't want to trap key or mouse events here.
- *
- * event.Skip() didn't seem to do the trick, so we call AddPendingEvent()
- * to add it to the parent's input queue.
- */
-void DeviceWindow::OnKeyDown(wxKeyEvent& event)
-{
-    //printf("DW: down: %d\n", event.GetKeyCode());
-    GetParent()->AddPendingEvent(event);
-}
-void DeviceWindow::OnKeyUp(wxKeyEvent& event)
-{
-    //printf("DW:   up: %d\n", event.GetKeyCode());
-    GetParent()->AddPendingEvent(event);
-}
-
-/*
- * Handle mouse events.  We want to pass these up to the PhoneWindow, since
- * that's where the "touch screen" code is.
- */
-void DeviceWindow::OnMouseLeftDown(wxMouseEvent& event)
-{
-    ClampMouse(&event);
-    GetParent()->AddPendingEvent(event);
-}
-void DeviceWindow::OnMouseLeftUp(wxMouseEvent& event)
-{
-    ClampMouse(&event);
-    GetParent()->AddPendingEvent(event);
-}
-void DeviceWindow::OnMouseRightDown(wxMouseEvent& event)
-{
-    ClampMouse(&event);
-    GetParent()->AddPendingEvent(event);
-}
-void DeviceWindow::OnMouseRightUp(wxMouseEvent& event)
-{
-    ClampMouse(&event);
-    GetParent()->AddPendingEvent(event);
-}
-void DeviceWindow::OnMouseMotion(wxMouseEvent& event)
-{
-    ClampMouse(&event);
-    GetParent()->AddPendingEvent(event);
-}
-
-/*
- * Clamp the mouse movement to the window bounds.
- */
-void DeviceWindow::ClampMouse(wxMouseEvent* pEvent)
-{
-    wxWindow* pEventWindow = (wxWindow*) pEvent->GetEventObject();
-    int width, height;
-
-    pEventWindow->GetSize(&width, &height);
-    if (pEvent->m_x < 0)
-        pEvent->m_x = 0;
-    else if (pEvent->m_x >= width)
-        pEvent->m_x = width-1;
-
-    if (pEvent->m_y < 0)
-        pEvent->m_y = 0;
-    else if (pEvent->m_y >= height)
-        pEvent->m_y = height-1;
-}
-
-
-/*
- * Handle a "user event".  We get these when the runtime wants us to
- * know that it has a new frame of graphics to display.
- * 
- */
-void DeviceWindow::OnUserEvent(UserEvent& event)
-{
-    wxBitmap* pBitmap;
-    long displayIndex;
-
-    displayIndex = (long) event.GetData();
-
-    //printf("GOT UAE %d\n", displayIndex);
-
-    // a displayIndex of -1 means just update the onion skin
-    if (displayIndex >= 0) {
-        /* get a newly-allocated bitmap with converted image data */
-        pBitmap = mpDeviceManager->GetImageData(displayIndex);
-    
-        /* do a ptr/refcount assignment to hold the data */
-        mBitmap = *pBitmap;
-        /* delete the temporary object; does not delete the bitmap storage */
-        delete pBitmap;
-    }
-    
-    if (displayIndex >= -1) {
-        mHasOnionSkinBitmap = false;
-        
-        Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-        assert(pPrefs != NULL);
-    
-        bool overlayOnionSkin;
-        char* onionSkinFileName = NULL;
-        
-        bool overlayOnionSkinExists = pPrefs->GetBool("overlay-onion-skin", &overlayOnionSkin);
-        if (overlayOnionSkinExists && overlayOnionSkin) {
-            bool fileNameExists = pPrefs->GetString("onion-skin-file-name", &onionSkinFileName);
-            if (fileNameExists && *onionSkinFileName) {
-                wxImage onionSkinImage(wxString::FromAscii(onionSkinFileName));
-                onionSkinImage.SetAlpha(NULL);
-                bool hasAlpha = onionSkinImage.HasAlpha();
-                int width = onionSkinImage.GetWidth();
-                int height = onionSkinImage.GetHeight();
-                if (hasAlpha) {
-                    unsigned char *alpha = onionSkinImage.GetAlpha();
-                    int alphaVal = 127;
-                    pPrefs->GetInt("onion-skin-alpha-value", &alphaVal);
-                    for (int i = (width * height) - 1; i >= 0; i--) {
-                        alpha[i] = alphaVal;
-                    } 
-                }
-                mOnionSkinBitmap = wxBitmap(onionSkinImage);
-                mHasOnionSkinBitmap = true;
-            }
-        }
-    }
-
-    /* induce an update */
-    Refresh();
-}
-
-/*
- * Window has been moved or resized.
- *
- * We get this when the model of phone is changed.
- *
- * FIX: in the future this only happens when the phone is rotated 90deg.
- */
-void DeviceWindow::OnSize(wxSizeEvent& WXUNUSED(event))
-{
-    int width, height;
-
-    GetClientSize(&width, &height);
-    printf("Sim: device window resize: %dx%d\n", width, height);
-
-    mBitmap.Create(width, height);
-
-    wxMemoryDC memDC;
-    memDC.SelectObject(mBitmap);
-
-    wxColour backColor(96, 122, 121);
-    memDC.SetBrush(wxBrush(backColor));
-    memDC.SetPen(wxPen(backColor, 1));
-    wxRect windowRect(wxPoint(0, 0), GetClientSize());
-    memDC.DrawRectangle(windowRect);
-}
-
-/*
- * No need to erase the background.
- */
-void DeviceWindow::OnErase(wxEraseEvent& WXUNUSED(event))
-{
-    //printf("erase device\n");
-}
-
-/*
- * Repaint the simulator output.
- */
-void DeviceWindow::OnPaint(wxPaintEvent& WXUNUSED(event))
-{
-    wxPaintDC dc(this);
-
-    /* draw background image */
-    dc.DrawBitmap(mBitmap, 0, 0, TRUE);
-
-    /* If necessary, draw onion skin image on top */
-    if (mHasOnionSkinBitmap) {
-        dc.DrawBitmap(mOnionSkinBitmap, 0, 0, TRUE);
-    }
-    
-#if 0
-    // debug - draw the corners
-    int xoff = 0;
-    int yoff = 0;
-    int width;
-    int height;
-    GetClientSize(&width, &height);
-
-    dc.SetPen(*wxGREEN_PEN);
-    dc.DrawLine(xoff,           yoff+9,         xoff,           yoff);
-    dc.DrawLine(xoff,           yoff,           xoff+10,        yoff);
-    dc.DrawLine(xoff+width-10,  yoff,           xoff+width,     yoff);
-    dc.DrawLine(xoff+width-1,   yoff,           xoff+width-1,   yoff+10);
-    dc.DrawLine(xoff,           yoff+height-10, xoff,           yoff+height);
-    dc.DrawLine(xoff,           yoff+height-1,  xoff+10,        yoff+height-1);
-    dc.DrawLine(xoff+width-1,   yoff+height-10, xoff+width-1,   yoff+height);
-    dc.DrawLine(xoff+width-1,   yoff+height-1,  xoff+width-11,  yoff+height-1);
-#endif
-}
-
diff --git a/simulator/app/DeviceWindow.h b/simulator/app/DeviceWindow.h
deleted file mode 100644
index 4548fc3..0000000
--- a/simulator/app/DeviceWindow.h
+++ /dev/null
@@ -1,70 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Window with simulated phone.
-//
-#ifndef _SIM_DEVICE_WINDOW_H
-#define _SIM_DEVICE_WINDOW_H
-
-#include "UserEvent.h"
-#include "DeviceManager.h"
-
-/*
- * This window displays the device output.
- */
-class DeviceWindow : public wxWindow {
-public:
-    DeviceWindow(wxWindow* parent, DeviceManager* pDM);
-    virtual ~DeviceWindow(void);
-
-#if 0       // can't work -- can't create bitmaps in other threads
-    /* this gets tucked into a user event */
-    class FrameData {
-    public:
-        FrameData(void)
-            : mDisplayIndex(-1), mpBitmap(NULL)
-            {}
-        ~FrameData(void) {
-            delete mpBitmap;
-        }
-
-        void Create(int displayIndex, wxBitmap* pBitmap) {
-            mDisplayIndex = displayIndex;
-            mpBitmap = pBitmap;
-        }
-
-        int GetDisplayIndex(void) const { return mDisplayIndex; }
-        wxBitmap* GetBitmap(void) const { return mpBitmap; }
-
-    private:
-        int         mDisplayIndex;
-        wxBitmap*   mpBitmap;
-    };
-#endif
-
-    void DeviceManagerClosing(void) { mpDeviceManager = NULL; }
-
-private:
-    void OnKeyDown(wxKeyEvent& event);
-    void OnKeyUp(wxKeyEvent& event);
-    void OnMouseLeftDown(wxMouseEvent& event);
-    void OnMouseLeftUp(wxMouseEvent& event);
-    void OnMouseRightDown(wxMouseEvent& event);
-    void OnMouseRightUp(wxMouseEvent& event);
-    void OnMouseMotion(wxMouseEvent& event);
-    void OnSize(wxSizeEvent& WXUNUSED(event));
-    void OnErase(wxEraseEvent& event);
-    void OnPaint(wxPaintEvent& WXUNUSED(event));
-    void OnUserEvent(UserEvent& event);
-
-    void ClampMouse(wxMouseEvent* pEvent);
-
-    DeviceManager*  mpDeviceManager;
-    wxBitmap    mBitmap;
-    wxBitmap	mOnionSkinBitmap;
-    bool        mHasOnionSkinBitmap;
-
-    DECLARE_EVENT_TABLE()
-};
-
-#endif // _SIM_DEVICE_WINDOW_H
diff --git a/simulator/app/ExternalRuntime.cpp b/simulator/app/ExternalRuntime.cpp
deleted file mode 100644
index 9f2cc5e..0000000
--- a/simulator/app/ExternalRuntime.cpp
+++ /dev/null
@@ -1,94 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//  
-// Management of the simulated device.
-//  
-    
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-    
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"
-    
-#include "ExternalRuntime.h"
-#include "MyApp.h"
-#include "UserEvent.h"
-#include "UserEventMessage.h"
-
-#include "SimRuntime.h"
-#include "LocalBiChannel.h"
-#include "utils.h"
-
-
-using namespace android;
-
-/*
- * Destructor.
- */
-ExternalRuntime::~ExternalRuntime(void)
-{
-    if (IsRunning()) {
-        // TODO: cause thread to stop, then Wait for it
-    }
-    printf("Sim: in ~ExternalRuntime()\n");
-}
-
-/*
- * Create and run the thread.
- */
-bool ExternalRuntime::StartThread(void)
-{
-    if (Create() != wxTHREAD_NO_ERROR) {
-        fprintf(stderr, "Sim: ERROR: can't create ExternalRuntime thread\n");
-        return false;
-    }
-
-    Run();
-    return true;
-}
-
-/*
- * Thread entry point.
- *
- * This just sits and waits for a new connection.  It hands it off to the
- * main thread and then goes back to waiting.
- *
- * There is currently no "polite" way to shut this down.
- */
-void* ExternalRuntime::Entry(void)
-{
-    LocalBiChannel lbic;
-    Pipe* reader;
-    Pipe* writer;
-
-    reader = writer = NULL;
-
-    if (!lbic.create(ANDROID_PIPE_NAME)) {
-        fprintf(stderr, "Sim: failed creating named pipe '%s'\n",
-            ANDROID_PIPE_NAME);
-        return NULL;
-    }
-
-    while (lbic.listen(&reader, &writer)) {
-        /*
-         * Throw it over the wall.
-         */
-        wxWindow* pMainFrame = ((MyApp*)wxTheApp)->GetMainFrame();
-
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateExternalRuntime(reader, writer);
-
-        UserEvent uev(0, (void*) pUem);
-        pMainFrame->AddPendingEvent(uev);
-
-        reader = writer = NULL;
-    }
-
-    printf("Sim: ExternalRuntime thread wants to bail\n");
-
-    return NULL;
-}
-
diff --git a/simulator/app/ExternalRuntime.h b/simulator/app/ExternalRuntime.h
deleted file mode 100644
index 774a2cd..0000000
--- a/simulator/app/ExternalRuntime.h
+++ /dev/null
@@ -1,26 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Class that manages the simulated device.
-//
-#ifndef _SIM_EXTERNAL_RUNTIME_H
-#define _SIM_EXTERNAL_RUNTIME_H
-
-/*
- * Define a thread that listens for the launch of an external runtime.
- * When we spot one we notify the main thread, which can choose to
- * accept or reject it.
- */
-class ExternalRuntime : public wxThread {
-public:
-    ExternalRuntime(void) {}
-    virtual ~ExternalRuntime(void);
-
-    /* start the thread running */
-    bool StartThread(void);
-
-    /* thread entry point */
-    virtual void* Entry(void);
-};
-
-#endif // _SIM_EXTERNAL_RUNTIME_H
diff --git a/simulator/app/LinuxKeys.h b/simulator/app/LinuxKeys.h
deleted file mode 100644
index 6382de9..0000000
--- a/simulator/app/LinuxKeys.h
+++ /dev/null
@@ -1,20 +0,0 @@
-#ifndef _SIM_LINUXKEYS_H
-#define _SIM_LINUXKEYS_H
-
-#include <linux/input.h>
-
-/* ubuntu has these, goobuntu doesn't */
-#ifndef KEY_SWITCHVIDEOMODE
-# define KEY_SWITCHVIDEOMODE 227
-#endif
-#ifndef KEY_KBDILLUMTOGGLE
-# define KEY_KBDILLUMTOGGLE 228
-#endif
-#ifndef KEY_KBDILLUMUP
-# define KEY_KBDILLUMUP     230
-#endif
-#ifndef KEY_REPLY
-# define KEY_REPLY          232
-#endif
-
-#endif /*_SIM_LINUXKEYS_H*/
diff --git a/simulator/app/LoadableImage.cpp b/simulator/app/LoadableImage.cpp
deleted file mode 100644
index e5bd0f3..0000000
--- a/simulator/app/LoadableImage.cpp
+++ /dev/null
@@ -1,100 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Simple class to hold an image that can be loaded and unloaded.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-
-#include "LoadableImage.h"
-#include "AssetStream.h"
-#include "MyApp.h"
-
-#include <utils.h>
-
-#include <stdio.h>
-
-
-/*
- * Load the image.
- */
-bool LoadableImage::Create(const char* fileName, int x, int y)
-{
-    if (fileName == NULL || x < 0 || y < 0) {
-        fprintf(stderr, "bad params to %s\n", __PRETTY_FUNCTION__);
-        return false;
-    }
-
-    delete[] mName;
-    mName = android::strdupNew(fileName);
-
-    mX = x;
-    mY = y;
-
-    return true;
-}
-
-/*
- * Load the bitmap.
- */
-bool LoadableImage::LoadResources(void)
-{
-    if (mName == NULL)
-        return false;
-
-    if (mpBitmap != NULL)       // already loaded?
-        return true;
-
-    //printf("LoadResources: '%s'\n", (const char*) mName);
-#ifdef BEFORE_ASSET
-    wxImage img(mName);
-#else
-    android::AssetManager* pAssetMgr = ((MyApp*)wxTheApp)->GetAssetManager();
-    android::Asset* pAsset;
-
-    pAsset = pAssetMgr->open(mName, android::Asset::ACCESS_RANDOM);
-    if (pAsset == NULL) {
-        fprintf(stderr, "ERROR: unable to load '%s'\n", mName);
-        return false;
-    } else {
-        //printf("--- opened asset '%s'\n",
-        //    (const char*) pAsset->getAssetSource());
-    }
-    AssetStream astr(pAsset);
-
-    wxImage img(astr);
-#endif
-
-    mWidth = img.GetWidth();
-    mHeight = img.GetHeight();
-    if (mWidth <= 0 || mHeight <= 0) {
-        /* image failed to load or decode */
-        fprintf(stderr, "ERROR: unable to load/decode '%s'\n", mName);
-        //delete img;
-        return false;
-    }
-
-    mpBitmap = new wxBitmap(img);
-
-    //delete img;
-
-    return true;
-}
-
-/*
- * Unload the bitmap.
- */
-bool LoadableImage::UnloadResources(void)
-{
-    delete mpBitmap;
-    mpBitmap = NULL;
-    return true;
-}
-
diff --git a/simulator/app/LoadableImage.h b/simulator/app/LoadableImage.h
deleted file mode 100644
index 368d520..0000000
--- a/simulator/app/LoadableImage.h
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Simulated device definition.
-//
-#ifndef _SIM_LOADABLE_IMAGE_H
-#define _SIM_LOADABLE_IMAGE_H
-
-#include "utils.h"
-
-/*
- * Holds an image that may or may not be loaded at present.  The image
- * has an (x,y) offset.
- */
-class LoadableImage {
-public:
-    LoadableImage(void)
-        : mName(NULL), mpBitmap(NULL), mX(-1), mY(-1), mWidth(-1), mHeight(-1)
-        {}
-    virtual ~LoadableImage(void) {
-        delete[] mName;
-        delete mpBitmap;
-    }
-    LoadableImage(const LoadableImage& src)
-        : mName(NULL), mpBitmap(NULL)
-    {
-        CopyMembers(src);
-    }
-    LoadableImage& operator=(const LoadableImage& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const LoadableImage& src) {
-        // Need to delete resources in case we're using operator= and
-        // assigning into an object that already holds some.
-        delete mName;
-        delete mpBitmap;
-        mName = android::strdupNew(src.mName);
-        if (src.mpBitmap == NULL)
-            mpBitmap = NULL;
-        else
-            mpBitmap = new wxBitmap(*(src.mpBitmap));
-        mX = src.mX;
-        mY = src.mY;
-        mWidth = src.mWidth;
-        mHeight = src.mHeight;
-    }
-
-    virtual bool Create(const char* fileName, int x, int y);
-
-    // load or unload the bitmap
-    bool LoadResources(void);
-    bool UnloadResources(void);
-
-    // accessors
-    int GetX(void) const { return mX; }
-    int GetY(void) const { return mY; }
-    int GetWidth(void) const { return mWidth; }
-    int GetHeight(void) const { return mHeight; }
-    wxBitmap* GetBitmap(void) const { return mpBitmap; }
-
-private:
-    char*       mName;
-    wxBitmap*   mpBitmap;
-
-    int         mX;         // position relative to phone image
-    int         mY;
-    int         mWidth;     // from image (cached values)
-    int         mHeight;
-};
-
-#endif // _SIM_LOADABLE_IMAGE_H
diff --git a/simulator/app/LocalBiChannel.cpp b/simulator/app/LocalBiChannel.cpp
deleted file mode 100644
index 93a997d..0000000
--- a/simulator/app/LocalBiChannel.cpp
+++ /dev/null
@@ -1,444 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Local named bi-directional communication channel.
-//
-#include "LocalBiChannel.h"
-#include "utils/Log.h"
-
-#if defined(HAVE_WIN32_IPC)
-# define _WIN32_WINNT 0x0500
-# include <windows.h>
-#else
-# include <sys/types.h>
-# include <sys/socket.h>
-# include <sys/stat.h>
-# include <sys/un.h>
-#endif
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <string.h>
-#include <errno.h>
-#include <assert.h>
-
-#ifndef SUN_LEN
-/*
- * Our current set of ARM header files don't define this.
- */
-# define SUN_LEN(ptr) ((size_t) (((struct sockaddr_un *) 0)->sun_path)        \
-                      + strlen ((ptr)->sun_path))
-#endif
-
-using namespace android;
-
-const unsigned long kInvalidHandle = (unsigned long) -1;
-
-/*
- * Initialize data fields.
- */
-LocalBiChannel::LocalBiChannel(void)
-    : mFileName(NULL), mIsListener(false), mHandle(kInvalidHandle)
-{
-}
-
-#if defined(HAVE_WIN32_IPC)
-/*
- * Implementation for Win32, using named pipes.
- *
- * Cygwin actually supports UNIX-domain sockets, but we want to stuff
- * the file handles into a Pipe, which uses HANDLE under Win32.
- */
-
-const int kPipeSize = 4096;
-
-/*
- * Destructor.  If we're the server side, we may need to clean up after
- * ourselves.
- */
-LocalBiChannel::~LocalBiChannel(void)
-{
-    if (mHandle != kInvalidHandle)
-        CloseHandle((HANDLE)mHandle);
-
-    delete[] mFileName;
-}
-
-/*
- * Construct the full path.  The caller must delete[] the return value.
- */
-static char* makeFilename(const char* name)
-{
-    static const char* kBasePath = "\\\\.\\pipe\\android-";
-    char* fileName;
-
-    assert(name != NULL && name[0] != '\0');
-
-    fileName = new char[strlen(kBasePath) + strlen(name) + 1];
-    strcpy(fileName, kBasePath);
-    strcat(fileName, name);
-
-    return fileName;
-}
-
-/*
- * Create a named pipe, so the client has something to connect to.
- */
-bool LocalBiChannel::create(const char* name)
-{
-    delete[] mFileName;
-    mFileName = makeFilename(name);
-
-#if 0
-    HANDLE hPipe;
-
-    hPipe = CreateNamedPipe(
-                    mFileName,              // unique pipe name
-                    PIPE_ACCESS_DUPLEX |    // open mode
-                        FILE_FLAG_FIRST_PIPE_INSTANCE,
-                    0,                      // pipe mode (byte, blocking)
-                    1,                      // max instances
-                    kPipeSize,              // output buffer
-                    kPipeSize,              // input buffer
-                    NMPWAIT_USE_DEFAULT_WAIT,   // client time-out
-                    NULL);                  // security
-
-    if (hPipe == 0) {
-        LOG(LOG_ERROR, "lbicomm",
-            "CreateNamedPipe failed (err=%ld)\n", GetLastError());
-        return false;
-    }
-
-    mHandle = (unsigned long) hPipe;
-#endif
-
-    return true;
-}
-
-/*
- * Attach to an existing named pipe.
- */
-bool LocalBiChannel::attach(const char* name, Pipe** ppReadPipe,
-    Pipe** ppWritePipe)
-{
-    HANDLE hPipe, dupHandle;
-
-    delete[] mFileName;
-    mFileName = makeFilename(name);
-
-    hPipe = CreateFile(
-                mFileName,                      // filename
-                GENERIC_READ | GENERIC_WRITE,   // access
-                0,                              // no sharing
-                NULL,                           // security
-                OPEN_EXISTING,                  // don't create
-                0,                              // attributes
-                NULL);                          // template
-    if (hPipe == INVALID_HANDLE_VALUE) {
-        LOG(LOG_ERROR, "lbicomm",
-            "CreateFile on pipe '%s' failed (err=%ld)\n", name, GetLastError());
-        return false;
-    }
-
-    assert(mHandle == kInvalidHandle);
-
-    /*
-     * Set up the pipes.  Use the new handle for one, and a duplicate
-     * of it for the other, in case we decide to only close one side.
-     */
-    *ppReadPipe = new Pipe();
-    (*ppReadPipe)->createReader((unsigned long) hPipe);
-
-    DuplicateHandle(
-            GetCurrentProcess(),
-            hPipe,
-            GetCurrentProcess(),
-            &dupHandle,
-            0,
-            FALSE,
-            DUPLICATE_SAME_ACCESS);
-    *ppWritePipe = new Pipe();
-    (*ppWritePipe)->createWriter((unsigned long) dupHandle);
-
-    return true;
-}
-
-/*
- * Listen for a new connection, discarding any existing connection.
- */
-bool LocalBiChannel::listen(Pipe** ppReadPipe, Pipe** ppWritePipe)
-{
-    BOOL connected;
-    HANDLE hPipe;
-
-    /*
-     * Create up to 3 instances of the named pipe:
-     * - currently active connection
-     * - connection currently being rejected because one is already active
-     * - a new listener to wait for the next round
-     */
-    hPipe = CreateNamedPipe(
-                    mFileName,              // unique pipe name
-                    PIPE_ACCESS_DUPLEX      // open mode
-                        /*| FILE_FLAG_FIRST_PIPE_INSTANCE*/,
-                    0,                      // pipe mode (byte, blocking)
-                    3,                      // max instances
-                    kPipeSize,              // output buffer
-                    kPipeSize,              // input buffer
-                    NMPWAIT_USE_DEFAULT_WAIT,   // client time-out
-                    NULL);                  // security
-
-    if (hPipe == 0) {
-        LOG(LOG_ERROR, "lbicomm",
-            "CreateNamedPipe failed (err=%ld)\n", GetLastError());
-        return false;
-    }
-
-    /*
-     * If a client is already connected to us, this fails with
-     * ERROR_PIPE_CONNECTED.  It returns success if we had to wait
-     * a little bit before the connection happens.
-     */
-    connected = ConnectNamedPipe(hPipe, NULL) ?
-        TRUE : (GetLastError() == ERROR_PIPE_CONNECTED);
-
-    if (connected) {
-        /*
-         * Create the pipes.  Give one a duplicated handle so that,
-         * when one closes, we don't lose both.
-         */
-        HANDLE dupHandle;
-
-        *ppReadPipe = new Pipe();
-        (*ppReadPipe)->createReader((unsigned long) hPipe);
-
-        DuplicateHandle(
-                GetCurrentProcess(),
-                hPipe,
-                GetCurrentProcess(),
-                &dupHandle,
-                0,
-                FALSE,
-                DUPLICATE_SAME_ACCESS);
-        *ppWritePipe = new Pipe();
-        (*ppWritePipe)->createWriter((unsigned long) dupHandle);
-
-        return true;
-    } else {
-        LOG(LOG_WARN, "lbicomm",
-            "ConnectNamedPipe failed (err=%ld)\n", GetLastError());
-#ifdef HAVE_WIN32_THREADS
-        Sleep(500); /* 500 ms */
-#else            
-        usleep(500000);     // DEBUG DEBUG
-#endif        
-        return false;
-    }
-}
-
-#else
-
-/*
- * Implementation for Linux and Darwin, using UNIX-domain sockets.
- */
-
-/*
- * Destructor.  If we're the server side, blow away the socket file.
- */
-LocalBiChannel::~LocalBiChannel(void)
-{
-    if (mHandle != kInvalidHandle)
-        close((int) mHandle);
-
-    if (mIsListener && mFileName != NULL) {
-        LOG(LOG_DEBUG, "lbicomm", "Removing '%s'\n", mFileName);
-        (void) unlink(mFileName);
-    }
-    delete[] mFileName;
-}
-
-/*
- * Construct the full path.  The caller must delete[] the return value.
- */
-static char* makeFilename(const char* name)
-{
-    static const char* kBasePath = "/tmp/android-";
-    char* fileName;
-
-    assert(name != NULL && name[0] != '\0');
-
-    fileName = new char[strlen(kBasePath) + strlen(name) + 1];
-    strcpy(fileName, kBasePath);
-    strcat(fileName, name);
-
-    return fileName;
-}
-
-/*
- * Create a UNIX domain socket, carefully removing it if it already
- * exists.
- */
-bool LocalBiChannel::create(const char* name)
-{
-    struct stat sb;
-    bool result = false;
-    int sock = -1;
-    int cc;
-
-    delete[] mFileName;
-    mFileName = makeFilename(name);
-
-    cc = stat(mFileName, &sb);
-    if (cc < 0) {
-        if (errno != ENOENT) {
-            LOG(LOG_ERROR, "lbicomm",
-                "Unable to stat '%s' (errno=%d)\n", mFileName, errno);
-            goto bail;
-        }
-    } else {
-        /* don't touch it if it's not a socket */
-        if (!(S_ISSOCK(sb.st_mode))) {
-            LOG(LOG_ERROR, "lbicomm",
-                "File '%s' exists and is not a socket\n", mFileName);
-            goto bail;
-        }
-
-        /* remove the cruft */
-        if (unlink(mFileName) < 0) {
-            LOG(LOG_ERROR, "lbicomm",
-                "Unable to remove '%s' (errno=%d)\n", mFileName, errno);
-            goto bail;
-        }
-    }
-
-    struct sockaddr_un addr;
-
-    sock = ::socket(AF_UNIX, SOCK_STREAM, 0);
-    if (sock < 0) {
-        LOG(LOG_ERROR, "lbicomm",
-            "UNIX domain socket create failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    /* bind the socket; this creates the file on disk */
-    strcpy(addr.sun_path, mFileName);    // max 108 bytes
-    addr.sun_family = AF_UNIX;
-    cc = ::bind(sock, (struct sockaddr*) &addr, SUN_LEN(&addr));
-    if (cc < 0) {
-        LOG(LOG_ERROR, "lbicomm",
-            "AF_UNIX bind failed for '%s' (errno=%d)\n", mFileName, errno);
-        goto bail;
-    }
-
-    mHandle = (unsigned long) sock;
-    sock = -1;
-    mIsListener = true;
-    result = true;
-
-bail:
-    if (sock >= 0)
-        close(sock);
-    return result;
-}
-
-/*
- * Attach to an existing UNIX domain socket.
- */
-bool LocalBiChannel::attach(const char* name, Pipe** ppReadPipe,
-    Pipe** ppWritePipe)
-{
-    bool result = false;
-    int sock = -1;
-    int cc;
-
-    assert(ppReadPipe != NULL);
-    assert(ppWritePipe != NULL);
-
-    delete[] mFileName;
-    mFileName = makeFilename(name);
-
-    struct sockaddr_un addr;
-
-    sock = ::socket(AF_UNIX, SOCK_STREAM, 0);
-    if (sock < 0) {
-        LOG(LOG_ERROR, "lbicomm",
-            "UNIX domain socket create failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    /* connect to socket; fails if file doesn't exist */
-    strcpy(addr.sun_path, mFileName);    // max 108 bytes
-    addr.sun_family = AF_UNIX;
-    cc = ::connect(sock, (struct sockaddr*) &addr, SUN_LEN(&addr));
-    if (cc < 0) {
-        // ENOENT means socket file doesn't exist
-        // ECONNREFUSED means socket exists but nobody is listening
-        LOG(LOG_ERROR, "lbicomm",
-            "AF_UNIX connect failed for '%s': %s\n", mFileName,strerror(errno));
-        goto bail;
-    }
-
-    /*
-     * Create the two halves.  We dup() the sock so that closing one side
-     * does not hose the other.
-     */
-    *ppReadPipe = new Pipe();
-    (*ppReadPipe)->createReader(sock);
-    *ppWritePipe = new Pipe();
-    (*ppWritePipe)->createWriter(dup(sock));
-
-    assert(mHandle == kInvalidHandle);
-    sock = -1;
-    mIsListener = false;
-
-    result = true;
-
-bail:
-    if (sock >= 0)
-        close(sock);
-    return result;
-}
-
-/*
- * Listen for a new connection.
- */
-bool LocalBiChannel::listen(Pipe** ppReadPipe, Pipe** ppWritePipe)
-{
-    bool result = false;
-    struct sockaddr_un from;
-    socklen_t fromlen;
-    int sock, lsock;
-    int cc;
-
-    assert(mHandle != kInvalidHandle);
-    lsock = (int) mHandle;
-
-    LOG(LOG_DEBUG, "lbicomm", "AF_UNIX listening\n");
-    cc = ::listen(lsock, 5);
-    if (cc < 0) {
-        LOG(LOG_ERROR, "lbicomm", "AF_UNIX listen failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    fromlen = sizeof(from);     // not SUN_LEN()
-    sock = ::accept(lsock, (struct sockaddr*) &from, &fromlen);
-    if (sock < 0) {
-        LOG(LOG_WARN, "lbicomm", "AF_UNIX accept failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    /*
-     * Create the two halves.  We dup() the sock so that closing one side
-     * does not hose the other.
-     */
-    *ppReadPipe = new Pipe();
-    (*ppReadPipe)->createReader(sock);
-    *ppWritePipe = new Pipe();
-    (*ppWritePipe)->createWriter(dup(sock));
-    result = true;
-
-bail:
-    return result;
-}
-
-#endif
diff --git a/simulator/app/LocalBiChannel.h b/simulator/app/LocalBiChannel.h
deleted file mode 100644
index ce04bc0..0000000
--- a/simulator/app/LocalBiChannel.h
+++ /dev/null
@@ -1,54 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Create or attach to a named bi-directional channel on the local machine.
-//
-#ifndef __LIBS_LOCALBICHANNEL_H
-#define __LIBS_LOCALBICHANNEL_H
-
-#ifdef HAVE_ANDROID_OS
-#error DO NOT USE THIS FILE IN THE DEVICE BUILD
-#endif
-
-#include <utils/Pipe.h>
-
-namespace android {
-
-/*
- * This is essentially a wrapper class for UNIX-domain sockets.  The
- * idea is to set one up with create() or attach to one with attach()
- * and then extract the unidirectional read/write Pipes.  These can
- * be used directly or stuffed into a MessageStream.
- *
- * The name for the pipe should be a short filename made up of alphanumeric
- * characters.  Depending on the implementation, we may create a file in
- * /tmp with the specified name, removing any existing copy.
- */
-class LocalBiChannel {
-public:
-    LocalBiChannel(void);
-    ~LocalBiChannel(void);
-
-    /* create the "listen" side */
-    bool create(const char* name);
-
-    /*
-     * Listen for a connection.  When we get one, we create unidirectional
-     * read/write pipes and return them.
-     */
-    bool listen(Pipe** ppReadPipe, Pipe** ppWritePipe);
-
-    /*
-     * Attach to a channel created by somebody else.  Returns pipes.
-     */
-    bool attach(const char* name, Pipe** ppReadPipe, Pipe** ppWritePipe);
-
-private:
-    char*       mFileName;
-    bool        mIsListener;
-    unsigned long mHandle;
-};
-
-}; // namespace android
-
-#endif // __LIBS_LOCALBICHANNEL_H
diff --git a/simulator/app/LogBundle.h b/simulator/app/LogBundle.h
deleted file mode 100644
index 2cba97b..0000000
--- a/simulator/app/LogBundle.h
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef _SIM_LOG_BUNDLE_H
-#define _SIM_LOG_BUNDLE_H
-
-#ifdef HAVE_PTHREADS
-#include <pthread.h>
-#endif
-#include <cutils/logd.h> // for android_LogPriority.
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef struct android_LogBundle {
-    time_t              when;
-    android_LogPriority priority;
-    pid_t               pid;
-#ifndef HAVE_PTHREADS
-    unsigned            tid;
-#else    
-    pthread_t           tid;
-#endif    
-    const char*         tag;
-    const struct iovec* msgVec;
-    size_t              msgCount;
-    int                 fd;
-} android_LogBundle;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // _SIM_LOG_BUNDLE_H
diff --git a/simulator/app/LogMessage.cpp b/simulator/app/LogMessage.cpp
deleted file mode 100644
index 63cb764..0000000
--- a/simulator/app/LogMessage.cpp
+++ /dev/null
@@ -1,98 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Hold a single log message.
-//
-#include "LogMessage.h"
-#include <assert.h>
-
-/*
- * Constructor.
- *
- * Initializers here aren't necessary, since we can only create one of
- * these through Create(), which touches every field.
- */
-LogMessage::LogMessage(void)
-{
-}
-
-/*
- * Destructor.
- */
-LogMessage::~LogMessage(void)
-{
-    delete[] mTag;
-    delete[] mMsg;
-}
-
-/*
- * Create a new LogMessage object, and populate it with the contents of
- * "*pBundle".
- */
-/*static*/ LogMessage* LogMessage::Create(const android_LogBundle* pBundle)
-{
-    LogMessage* newMsg = new LogMessage;
-
-    if (newMsg == NULL)
-        return NULL;
-    assert(pBundle != NULL);
-
-    newMsg->mWhen = pBundle->when;
-    newMsg->mPriority = pBundle->priority;
-    newMsg->mPid = pBundle->pid;
-    newMsg->mTag = android::strdupNew(pBundle->tag);
-
-    size_t len = 0;
-    size_t i;
-    for (i=0; i<pBundle->msgCount; i++) len += pBundle->msgVec[i].iov_len;
-    newMsg->mMsg = new char[len+1];
-    char* p = newMsg->mMsg;
-    for (i=0; i<pBundle->msgCount; i++) {
-        memcpy(p, pBundle->msgVec[i].iov_base, pBundle->msgVec[i].iov_len);
-        p += pBundle->msgVec[i].iov_len;
-    }
-    *p = 0;
-
-    newMsg->mRefCnt = 1;
-    newMsg->mInternal = false;
-    newMsg->mFootprint = 8 * sizeof(int) + strlen(newMsg->mTag) +
-        strlen(newMsg->mMsg) + 4;
-    newMsg->mTextCtrlLen = 0;
-    newMsg->mpPrev = NULL;
-    newMsg->mpNext = NULL;
-
-    return newMsg;
-}
-
-/*
- * Create a new LogMessage object, with a simple message in it.
- *
- * Sets "mInternal" so we display it appropriately.
- */
-/*static*/ LogMessage* LogMessage::Create(const char* msg)
-{
-    LogMessage* newMsg;
-    android_LogBundle bundle;
-
-    assert(msg != NULL);
-
-    memset(&bundle, 0, sizeof(bundle));
-    bundle.when = time(NULL);
-    bundle.priority = ANDROID_LOG_ERROR;
-    bundle.pid = getpid();
-    bundle.tag = "-";
-    iovec iov;
-    iov.iov_base = (void*)msg;
-    iov.iov_len = strlen(msg);
-    bundle.msgVec = &iov;
-    bundle.msgCount = 1;
-
-    newMsg = Create(&bundle);
-
-    if (newMsg != NULL) {
-        newMsg->mInternal = true;
-    }
-
-    return newMsg;
-}
-
diff --git a/simulator/app/LogMessage.h b/simulator/app/LogMessage.h
deleted file mode 100644
index fe77dc0..0000000
--- a/simulator/app/LogMessage.h
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Class to hold a single log message.  Not thread safe.
-//
-#ifndef _SIM_LOG_MESSAGE_H
-#define _SIM_LOG_MESSAGE_H
-
-#include "utils.h"
-#include "LogBundle.h"
-
-/*
- * Hold a single log message.
- *
- * To reduce malloc strain we could over-allocate the object and tuck the
- * message text into the object storage.  On this off chance this becomes
- * important, the implementation keeps its constructor private.
- */
-class LogMessage {
-public:
-    ~LogMessage(void);
-
-    static LogMessage* Create(const android_LogBundle* pBundle);
-    static LogMessage* Create(const char* msg);
-
-    /* the total length of text added to the text ctrl */
-    int GetTextCtrlLen(void) const { return mTextCtrlLen; }
-    void SetTextCtrlLen(int len) { mTextCtrlLen = len; }
-
-    /* log pool */
-    LogMessage* GetPrev(void) const { return mpPrev; }
-    void SetPrev(LogMessage* pPrev) { mpPrev = pPrev; }
-    LogMessage* GetNext(void) const { return mpNext; }
-    void SetNext(LogMessage* pNext) { mpNext = pNext; }
-    int GetFootprint(void) const { return mFootprint; }
-
-    /* message contents */
-    time_t GetWhen(void) const { return mWhen; }
-    android_LogPriority GetPriority(void) const { return mPriority; }
-    pid_t GetPid(void) const { return mPid; }
-    const char* GetTag(void) const { return mTag; }
-    const char* GetMsg(void) const { return mMsg; }
-
-    bool GetInternal(void) const { return mInternal; }
-
-    void Acquire(void) { mRefCnt++; }
-    void Release(void) {
-        if (!--mRefCnt)
-            delete this;
-    }
-
-private:
-    LogMessage(void);
-    LogMessage(const LogMessage& src);              // not implemented
-    LogMessage& operator=(const LogMessage& src);   // not implemented
-
-    /* log message contents */
-    time_t          mWhen;
-    android_LogPriority mPriority;
-    pid_t           mPid;
-    char*           mTag;
-    char*           mMsg;
-
-    /* additional goodies */
-    int             mRefCnt;        // reference count
-    bool            mInternal;      // message generated internally by us?
-    int             mFootprint;     // approx. size of this object in memory
-    int             mTextCtrlLen;   // #of characters req'd in text ctrl
-    LogMessage*     mpPrev;         // link to previous item in log pool
-    LogMessage*     mpNext;         // link to next item in log pool
-};
-
-#endif // _SIM_LOG_MESSAGE_H
diff --git a/simulator/app/LogPool.cpp b/simulator/app/LogPool.cpp
deleted file mode 100644
index 43bf4be..0000000
--- a/simulator/app/LogPool.cpp
+++ /dev/null
@@ -1,90 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Hold a collection of log messages, limiting ourselves to a certain
-// fixed maximum amount of memory.
-//
-#include "LogPool.h"
-#include <assert.h>
-
-
-/*
- * Add a message at the head of the pool.
- */
-void LogPool::Add(LogMessage* pLogMessage)
-{
-    pLogMessage->Acquire();     // bump up the ref count
-
-    assert(pLogMessage->GetPrev() == NULL);
-    assert(pLogMessage->GetNext() == NULL);
-
-    if (mpHead == NULL) {
-        assert(mpTail == NULL);
-        mpTail = mpHead = pLogMessage;
-    } else {
-        assert(mpHead->GetPrev() == NULL);
-        mpHead->SetPrev(pLogMessage);
-        pLogMessage->SetNext(mpHead);
-        mpHead = pLogMessage;
-    }
-
-    /* update the pool size, and remove old entries if necessary */
-    mCurrentSize += pLogMessage->GetFootprint();
-
-    while (mCurrentSize > mMaxSize)
-        RemoveOldest();
-}
-
-/*
- * Remove the oldest message (from the tail of the list).
- */
-void LogPool::RemoveOldest(void)
-{
-    LogMessage* pPrev;
-
-    if (mpTail == NULL) {
-        fprintf(stderr, "HEY: nothing left to remove (cur=%ld)\n",
-            mCurrentSize);
-        assert(false);
-        return;
-    }
-
-    if (mpTail == mpBookmark)
-        mpBookmark = NULL;
-
-    //printf("--- removing oldest, size %ld->%ld (%s)\n",
-    //    mCurrentSize, mCurrentSize - mpTail->GetFootprint(),mpTail->GetMsg());
-    mCurrentSize -= mpTail->GetFootprint();
-
-    pPrev = mpTail->GetPrev();
-    mpTail->Release();
-    mpTail = pPrev;
-    if (mpTail == NULL) {
-        //printf("--- pool is now empty (size=%ld)\n", mCurrentSize);
-        mpHead = NULL;
-    } else {
-        mpTail->SetNext(NULL);
-    }
-}
-
-/*
- * Resize the log pool.
- */
-void LogPool::Resize(long maxSize)
-{
-    assert(maxSize >= 0);
-
-    mMaxSize = maxSize;
-    while (mCurrentSize > mMaxSize)
-        RemoveOldest();
-}
-
-/*
- * Remove all entries.
- */
-void LogPool::Clear(void)
-{
-    while (mpTail != NULL)
-        RemoveOldest();
-}
-
diff --git a/simulator/app/LogPool.h b/simulator/app/LogPool.h
deleted file mode 100644
index b824fec..0000000
--- a/simulator/app/LogPool.h
+++ /dev/null
@@ -1,56 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Pool of log messages.  Not thread safe -- operations on the log pool
-// should only happen in the main UI thread.
-//
-#ifndef _SIM_LOG_POOL_H
-#define _SIM_LOG_POOL_H
-
-#include "LogMessage.h"
-
-/*
- * This contains the pool of log messages.  The messages themselves are
- * allocated individually and reference counted.  We add new messages to
- * the head and, when the total "footprint" exceeds our stated max, we
- * delete one or more from the tail.
- *
- * To support pause/resume, we allow a "bookmark" to be set.  This is
- * just a pointer to a message in the pool.  If the bookmarked message
- * is deleted, we discard the bookmark.
- */
-class LogPool {
-public:
-    LogPool(void)
-        : mpHead(NULL), mpTail(NULL), mpBookmark(NULL),
-          mCurrentSize(0), mMaxSize(10240)
-        {}
-    ~LogPool(void) { Clear(); }
-
-    void Clear(void);
-
-    /* add a new message to the pool */
-    void Add(LogMessage* pLogMessage);
-
-    /* resize the pool, removing excess messages */
-    void Resize(long maxSize);
-
-    /* return the current limit, in bytes */
-    long GetMaxSize(void) const { return mMaxSize; }
-
-    LogMessage* GetHead(void) const { return mpHead; }
-
-    void SetBookmark(void) { mpBookmark = mpHead; }
-    LogMessage* GetBookmark(void) const { return mpBookmark; }
-
-private:
-    void RemoveOldest(void);
-
-    LogMessage*     mpHead;
-    LogMessage*     mpTail;
-    LogMessage*     mpBookmark;
-    long            mCurrentSize;       // current size, in bytes
-    long            mMaxSize;           // maximum size, in bytes
-};
-
-#endif // _SIM_LOG_POOL_H
diff --git a/simulator/app/LogPrefsDialog.cpp b/simulator/app/LogPrefsDialog.cpp
deleted file mode 100644
index dc3e07c..0000000
--- a/simulator/app/LogPrefsDialog.cpp
+++ /dev/null
@@ -1,404 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Log preferences modal dialog.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-
-#include "LogPrefsDialog.h"
-#include "Preferences.h"
-#include "Resource.h"
-#include "utils.h"
-
-BEGIN_EVENT_TABLE(LogPrefsDialog, wxDialog)
-    EVT_CHECKBOX(IDC_LOG_PREFS_WRITE_FILE, LogPrefsDialog::OnWriteFile)
-END_EVENT_TABLE()
-
-static const wxString gSpacerChoices[] = { 
-    wxT("0"), wxT("1"), wxT("2") 
-};
-static const wxString gPointSizes[] = { 
-    wxT("4"), wxT("6"), wxT("8"), wxT("10"), wxT("12"), wxT("14"), wxT("16") 
-};
-
-
-/*
- * Constructor.
- */
-LogPrefsDialog::LogPrefsDialog(wxWindow* parent)
-    : wxDialog(parent, IDD_LOG_PREFS, wxT("Log Preferences"), wxDefaultPosition,
-        wxDefaultSize, wxDEFAULT_DIALOG_STYLE),
-      mHeaderFormat(kHFFull), mSingleLine(false), mExtraSpacing(0),
-      mUseColor(false), mFontMonospace(false), mDisplayMax(0), mPoolSizeKB(0)
-{
-    CreateControls();
-}
-
-
-/*
- * Destructor.  Not much to do.
- */
-LogPrefsDialog::~LogPrefsDialog(void)
-{
-}
-
-/*
- * Create all of the pages and add them to the notebook.
- */
-void LogPrefsDialog::CreateControls(void)
-{
-    wxBoxSizer* mainSizer = new wxBoxSizer(wxVERTICAL);
-    wxBoxSizer* okCancelSizer = new wxBoxSizer(wxHORIZONTAL);
-    mNotebook.Create(this, wxID_ANY);
-    wxPanel* page;
-
-    page = CreateFormatPage(&mNotebook);
-    mNotebook.AddPage(page, wxT("Format"), true);
-    page = CreateLimitsPage(&mNotebook);
-    mNotebook.AddPage(page, wxT("Limits"), false);
-    page = CreateFilesPage(&mNotebook);
-    mNotebook.AddPage(page, wxT("Files"), false);
-
-    // note to self: could use CreateButtonSizer here?
-    wxButton* cancel = new wxButton(this, wxID_CANCEL, wxT("&Cancel"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    okCancelSizer->Add(cancel, 0, wxALL, kInterSpacing);
-
-    wxButton* ok = new wxButton(this, wxID_OK, wxT("&OK"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    okCancelSizer->Add(ok, 0, wxALL, kInterSpacing);
-
-    mainSizer->Add(&mNotebook);
-    mainSizer->Add(okCancelSizer, 0, wxALIGN_RIGHT);
-
-    SetSizer(mainSizer);
-
-    mainSizer->Fit(this);           // shrink-to-fit
-    mainSizer->SetSizeHints(this);  // define minimum size
-}
-
-/*
- * Transfer data from our members to the window controls.
- */
-bool LogPrefsDialog::TransferDataToWindow(void)
-{
-    /*
-     * Do standard dialog setup.
-     */
-    wxRadioButton* fmtFull = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_FULL);
-    wxRadioButton* fmtBrief = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_BRIEF);
-    wxRadioButton* fmtMinimal = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_MINIMAL);
-    wxCheckBox* singleLine = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_SINGLE_LINE);
-    wxComboBox* extraSpacing = (wxComboBox*) FindWindow(IDC_LOG_PREFS_EXTRA_SPACING);
-    wxComboBox* pointSize = (wxComboBox*) FindWindow(IDC_LOG_PREFS_POINT_SIZE);
-    wxCheckBox* useColor = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_USE_COLOR);
-    wxCheckBox* fontMono = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_FONT_MONO);
-    // -
-    wxTextCtrl* displayMax = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_DISPLAY_MAX);
-    wxTextCtrl* poolSize = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_POOL_SIZE);
-    // -
-    wxCheckBox* writeFile = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_WRITE_FILE);
-    wxTextCtrl* fileName = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_FILENAME);
-    wxCheckBox* truncateOld = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_TRUNCATE_OLD);
-    // -
-
-    fmtFull->SetValue(mHeaderFormat == kHFFull);
-    fmtBrief->SetValue(mHeaderFormat == kHFBrief);
-    fmtMinimal->SetValue(mHeaderFormat == kHFMinimal);
-    singleLine->SetValue(mSingleLine);
-    if (mExtraSpacing < 0 || mExtraSpacing > NELEM(gSpacerChoices))
-        mExtraSpacing = 0;
-    extraSpacing->SetSelection(mExtraSpacing);
-
-    pointSize->SetSelection(0);
-    for (int i = 0; i < NELEM(gPointSizes); i++) {
-        if (atoi(gPointSizes[i].ToAscii()) == mPointSize) {
-            pointSize->SetSelection(i);
-            break;
-        }
-    }
-    useColor->SetValue(mUseColor);
-    fontMono->SetValue(mFontMonospace);
-
-    wxString tmpStr;
-    tmpStr.Printf(wxT("%d"), mDisplayMax);
-    displayMax->SetValue(tmpStr);
-    tmpStr.Printf(wxT("%d"), mPoolSizeKB);
-    poolSize->SetValue(tmpStr);
-
-    writeFile->SetValue(mWriteFile);
-    fileName->SetValue(mFileName);
-    truncateOld->SetValue(mTruncateOld);
-
-    EnableFileControls(mWriteFile);
-
-    return true;
-}
-
-/*
- * Convert a string to a number.  The number is expected to be unsigned.
- * Returns < 0 on failure.
- */
-static long ConvertUnsigned(const wxString& str)
-{
-    long val;
-    if (!str.ToLong(&val))
-        return -1;
-    return val;
-}
-
-/*
- * Transfer and validate data from the window controls.
- *
- * This doesn't get called if the user cancels out of the dialog.
- */
-bool LogPrefsDialog::TransferDataFromWindow(void)
-{
-    /*
-     * Do standard dialog export.
-     */
-    //wxRadioButton* fmtFull = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_FULL);
-    wxRadioButton* fmtBrief = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_BRIEF);
-    wxRadioButton* fmtMinimal = (wxRadioButton*) FindWindow(IDC_LOG_PREFS_FMT_MINIMAL);
-    wxCheckBox* singleLine = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_SINGLE_LINE);
-    wxComboBox* extraSpacing = (wxComboBox*) FindWindow(IDC_LOG_PREFS_EXTRA_SPACING);
-    wxComboBox* pointSize = (wxComboBox*) FindWindow(IDC_LOG_PREFS_POINT_SIZE);
-    wxCheckBox* useColor = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_USE_COLOR);
-    wxCheckBox* fontMono = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_FONT_MONO);
-    // -
-    wxTextCtrl* displayMax = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_DISPLAY_MAX);
-    wxTextCtrl* poolSize = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_POOL_SIZE);
-    // -
-    wxCheckBox* writeFile = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_WRITE_FILE);
-    wxTextCtrl* fileName = (wxTextCtrl*) FindWindow(IDC_LOG_PREFS_FILENAME);
-    wxCheckBox* truncateOld = (wxCheckBox*) FindWindow(IDC_LOG_PREFS_TRUNCATE_OLD);
-    // -
-
-    mHeaderFormat = kHFFull;
-    if (fmtBrief->GetValue())
-        mHeaderFormat = kHFBrief;
-    else if (fmtMinimal->GetValue())
-        mHeaderFormat = kHFMinimal;
-
-    wxString tmpStr;
-
-    mSingleLine = (singleLine->GetValue() != 0);
-    mExtraSpacing = extraSpacing->GetSelection();
-    mPointSize = ConvertUnsigned(pointSize->GetValue());
-    mUseColor = useColor->GetValue();
-    mFontMonospace = fontMono->GetValue();
-
-    tmpStr = displayMax->GetValue();
-    mDisplayMax = ConvertUnsigned(tmpStr);
-    if (mDisplayMax <= 0 || mDisplayMax > 1000 * 1000) {
-        wxMessageBox(wxT("Bad value for display max -- must be > 0 and <= 1,000,000"),
-            wxT("Hoser"), wxOK, this);
-        return false;
-    }
-
-    tmpStr = poolSize->GetValue();
-    mPoolSizeKB = ConvertUnsigned(tmpStr);
-    if (mDisplayMax <= 0 || mDisplayMax > 1048576) {
-        wxMessageBox(wxT("Bad value for pool size -- must be > 0 and <= 1048576"),
-            wxT("Hoser"), wxOK, this);
-        return false;
-    }
-
-    mWriteFile = (writeFile->GetValue() != 0);
-    mFileName = fileName->GetValue();
-    mTruncateOld = (truncateOld->GetValue() != 0);
-    if (mWriteFile && mFileName.IsEmpty()) {
-        wxMessageBox(wxT("Log filename may not be blank"),
-            wxT("Hoser"), wxOK, this);
-        return false;
-    }
-
-    return true;
-}
-
-
-/*
- * Create the log Format page.
- */
-wxPanel* LogPrefsDialog::CreateFormatPage(wxBookCtrlBase* parent)
-{
-    wxPanel* panel = new wxPanel(parent);
-
-    wxStaticBoxSizer* headerOpts = new wxStaticBoxSizer(wxVERTICAL, panel,
-        wxT("Header"));
-    headerOpts->Add(new wxRadioButton(panel, IDC_LOG_PREFS_FMT_FULL,
-            wxT("Full header"), wxDefaultPosition, wxDefaultSize,
-            wxRB_GROUP));
-    headerOpts->Add(new wxRadioButton(panel, IDC_LOG_PREFS_FMT_BRIEF,
-            wxT("Brief header")));
-    headerOpts->Add(new wxRadioButton(panel, IDC_LOG_PREFS_FMT_MINIMAL,
-            wxT("Minimal, integrated header")));
-
-    wxCheckBox* singleLine = new wxCheckBox(panel, IDC_LOG_PREFS_SINGLE_LINE,
-        wxT("Put headers and message on same line"));
-
-    wxStaticText* extraSpacingDescr = new wxStaticText(panel, wxID_STATIC,
-        wxT("Extra line spacing:"));
-    wxComboBox* extraSpacing = new wxComboBox(panel,
-        IDC_LOG_PREFS_EXTRA_SPACING, wxT("blah"),
-        wxDefaultPosition, wxDefaultSize, NELEM(gSpacerChoices),
-        gSpacerChoices, wxCB_READONLY);
-    wxBoxSizer* extraSpacingSizer = new wxBoxSizer(wxHORIZONTAL);
-    extraSpacingSizer->Add(extraSpacingDescr, 0, wxALIGN_CENTER_VERTICAL);
-    extraSpacingSizer->AddSpacer(kInterSpacing);
-    extraSpacingSizer->Add(extraSpacing);
-
-    wxStaticBoxSizer* textOpts = new wxStaticBoxSizer(wxVERTICAL, panel,
-        wxT("Text"));
-    textOpts->Add(
-            new wxStaticText(panel, wxID_STATIC, wxT("Point size:")) );
-    textOpts->AddSpacer(kInterSpacing);
-    textOpts->Add(
-        new wxComboBox(panel,
-            IDC_LOG_PREFS_POINT_SIZE, wxT("blah"),
-            wxDefaultPosition, wxDefaultSize, NELEM(gPointSizes),
-            gPointSizes, wxCB_READONLY) );
-    textOpts->AddSpacer(kInterSpacing);
-    textOpts->Add(
-            new wxCheckBox(panel, IDC_LOG_PREFS_USE_COLOR,
-                wxT("Colorful messages")) );
-    textOpts->AddSpacer(kInterSpacing);
-    textOpts->Add(
-            new wxCheckBox(panel, IDC_LOG_PREFS_FONT_MONO,
-                wxT("Use monospace font")) );
-
-
-    wxBoxSizer* sizerPanel = new wxBoxSizer(wxVERTICAL);
-    sizerPanel->Add(kMinWidth, kEdgeSpacing);       // forces minimum width
-    sizerPanel->Add(headerOpts);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(singleLine);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(extraSpacingSizer);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(textOpts);
-    sizerPanel->AddSpacer(kInterSpacing);
-
-    wxBoxSizer* horizIndent = new wxBoxSizer(wxHORIZONTAL);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    horizIndent->Add(sizerPanel);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    panel->SetSizer(horizIndent);
-
-    return panel;
-}
-
-/*
- * Create the log Limits page.
- */
-wxPanel* LogPrefsDialog::CreateLimitsPage(wxBookCtrlBase* parent)
-{
-    wxPanel* panel = new wxPanel(parent);
-
-    wxBoxSizer* displayMaxSizer = new wxBoxSizer(wxHORIZONTAL);
-    displayMaxSizer->Add(
-            new wxStaticText(panel, wxID_ANY,
-                wxT("Maximum entries in log window:"),
-                wxDefaultPosition, wxDefaultSize,
-                wxALIGN_LEFT),
-            0, wxALIGN_CENTER_VERTICAL);
-    displayMaxSizer->AddSpacer(kInterSpacing);
-    displayMaxSizer->Add(
-            new wxTextCtrl(panel, IDC_LOG_PREFS_DISPLAY_MAX));
-
-    wxBoxSizer* poolSizeSizer = new wxBoxSizer(wxHORIZONTAL);
-    poolSizeSizer->Add(
-            new wxStaticText(panel, wxID_ANY,
-                wxT("Size of the log pool (KB):"),
-                wxDefaultPosition, wxDefaultSize,
-                wxALIGN_LEFT),
-            0, wxALIGN_CENTER_VERTICAL);
-    poolSizeSizer->AddSpacer(kInterSpacing);
-    poolSizeSizer->Add(
-            new wxTextCtrl(panel, IDC_LOG_PREFS_POOL_SIZE));
-
-
-    wxBoxSizer* sizerPanel = new wxBoxSizer(wxVERTICAL);
-    sizerPanel->Add(kMinWidth, kEdgeSpacing);       // forces minimum width
-    sizerPanel->Add(displayMaxSizer);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(poolSizeSizer);
-    sizerPanel->AddSpacer(kInterSpacing);
-
-    wxBoxSizer* horizIndent = new wxBoxSizer(wxHORIZONTAL);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    horizIndent->Add(sizerPanel);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    panel->SetSizer(horizIndent);
-
-    return panel;
-}
-
-/*
- * Create the log Files page.
- */
-wxPanel* LogPrefsDialog::CreateFilesPage(wxBookCtrlBase* parent)
-{
-    wxPanel* panel = new wxPanel(parent);
-    wxStaticBoxSizer* logOpts = new wxStaticBoxSizer(wxVERTICAL, panel,
-        wxT("Log File"));
-
-    wxCheckBox* writeCopy =
-            new wxCheckBox(panel, IDC_LOG_PREFS_WRITE_FILE,
-                wxT("Write a copy of log output to a file"));
-
-    logOpts->AddSpacer(kInterSpacing);
-    logOpts->Add(
-            new wxStaticText(panel, wxID_ANY,
-                wxT("Filename:"),
-                wxDefaultPosition, wxDefaultSize,
-                wxALIGN_LEFT));
-    logOpts->AddSpacer(kInterSpacing);
-    logOpts->Add(
-            new wxTextCtrl(panel, IDC_LOG_PREFS_FILENAME), 0, wxEXPAND);
-    logOpts->AddSpacer(kInterSpacing);
-    logOpts->Add(
-            new wxCheckBox(panel, IDC_LOG_PREFS_TRUNCATE_OLD,
-                wxT("Truncate the file if more than 8 hours old ")) );
-
-
-    wxBoxSizer* sizerPanel = new wxBoxSizer(wxVERTICAL);
-    sizerPanel->Add(kMinWidth, kEdgeSpacing);       // forces minimum width
-    sizerPanel->Add(writeCopy);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(logOpts);
-    sizerPanel->AddSpacer(kInterSpacing);
-
-    wxBoxSizer* horizIndent = new wxBoxSizer(wxHORIZONTAL);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    horizIndent->Add(sizerPanel);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    panel->SetSizer(horizIndent);
-
-    return panel;
-}
-
-
-/*
- * Handle clicks on the "write file" checkbox.
- */
-void LogPrefsDialog::OnWriteFile(wxCommandEvent& event)
-{
-    EnableFileControls(event.GetInt());
-}
-
-/*
- * Enable or disable some of the controls on the "file" page.
- */
-void LogPrefsDialog::EnableFileControls(bool enable)
-{
-    FindWindow(IDC_LOG_PREFS_FILENAME)->Enable(enable);
-    FindWindow(IDC_LOG_PREFS_TRUNCATE_OLD)->Enable(enable);
-}
-
diff --git a/simulator/app/LogPrefsDialog.h b/simulator/app/LogPrefsDialog.h
deleted file mode 100644
index 17a73a3..0000000
--- a/simulator/app/LogPrefsDialog.h
+++ /dev/null
@@ -1,70 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Log preferences modal dialog.
-//
-#ifndef _SIM_LOG_PREFS_DIALOG_H
-#define _SIM_LOG_PREFS_DIALOG_H
-
-/*
- * Declaration of log preferences dialog.  This class defines the outer
- * wrapper as well as all of the pages.
- */
-class LogPrefsDialog : public wxDialog {
-    DECLARE_EVENT_TABLE()
-
-public:
-    LogPrefsDialog(wxWindow* parent);
-    virtual ~LogPrefsDialog(void);
-
-    void CreateControls(void);
-
-    /* these correspond to radio buttons */
-    typedef enum HeaderFormat {
-        kHFFull = 0,
-        kHFBrief,
-        kHFMinimal,
-        kHFInternal,        // special -- used for internally generated msgs
-    };
-
-    /*
-     * Values edited in the preference pages.  By Windows convention,
-     * these are public.
-     */
-    /* format options */
-    HeaderFormat mHeaderFormat;
-    bool        mSingleLine;        // put whole message on one line?
-    int         mExtraSpacing;      // double/triple-space messages?
-    int         mPointSize;         // text size
-    bool        mUseColor;          // colorful messages?
-    bool        mFontMonospace;     // use monospace font?
-
-    /* limit options */
-    int         mDisplayMax;
-    int         mPoolSizeKB;
-
-    /* file options */
-    bool        mWriteFile;
-    wxString    mFileName;
-    bool        mTruncateOld;
-
-private:
-    bool TransferDataToWindow(void);
-    bool TransferDataFromWindow(void);
-
-    wxPanel* CreateFormatPage(wxBookCtrlBase* parent);
-    wxPanel* CreateLimitsPage(wxBookCtrlBase* parent);
-    wxPanel* CreateFilesPage(wxBookCtrlBase* parent);
-
-    void OnWriteFile(wxCommandEvent& event);
-    void EnableFileControls(bool enable);
-
-    /* main notebook; for aesthetic reasons we may want a Choicebook */
-    wxNotebook    mNotebook;
-
-    enum {
-        kMinWidth = 300,        // minimum prefs dialog width, in pixels
-    };
-};
-
-#endif // _SIM_LOG_PREFS_DIALOG_H
diff --git a/simulator/app/LogWindow.cpp b/simulator/app/LogWindow.cpp
deleted file mode 100644
index b19debb..0000000
--- a/simulator/app/LogWindow.cpp
+++ /dev/null
@@ -1,1156 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Display runtime log output.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-#include "wx/dcbuffer.h"
-
-#include "LogWindow.h"
-#include "LogMessage.h"
-#include "LogPrefsDialog.h"
-#include "MyApp.h"
-#include "Preferences.h"
-#include "Resource.h"
-#include "UserEventMessage.h"
-
-#include <errno.h>
-
-static int android_snprintfBuffer(char** pBuf, int bufLen, const char* format, ...);
-static int android_vsnprintfBuffer(char** pBuf, int bufLen, const char* format, va_list args);
-
-
-using namespace android;
-
-#if 0   // experiment -- works on Win32, but not with GTK
-class MyTextCtrl : public wxTextCtrl {
-public:
-    MyTextCtrl(wxWindow* parent, wxWindowID id, const wxString& value,
-        const wxPoint& pos, const wxSize& size, int style = 0)
-        : wxTextCtrl(parent, id, value, pos, size, style)
-        {
-            printf("***************** MyTextCtrl!\n");
-        }
-
-    void OnScroll(wxScrollWinEvent& event);
-    void OnScrollBottom(wxScrollWinEvent& event);
-
-private:
-    DECLARE_EVENT_TABLE()
-};
-
-BEGIN_EVENT_TABLE(MyTextCtrl, wxTextCtrl)
-    EVT_SCROLLWIN(MyTextCtrl::OnScroll)
-    EVT_SCROLLWIN_BOTTOM(MyTextCtrl::OnScrollBottom)
-END_EVENT_TABLE()
-
-void MyTextCtrl::OnScroll(wxScrollWinEvent& event)
-{
-    printf("OnScroll!\n");
-}
-
-void MyTextCtrl::OnScrollBottom(wxScrollWinEvent& event)
-{
-    printf("OnScrollBottom!\n");
-}
-#endif
-
-
-BEGIN_EVENT_TABLE(LogWindow, wxDialog)
-    EVT_CLOSE(LogWindow::OnClose)
-    EVT_MOVE(LogWindow::OnMove)
-    EVT_COMBOBOX(IDC_LOG_LEVEL, LogWindow::OnLogLevel)
-    EVT_BUTTON(IDC_LOG_CLEAR, LogWindow::OnLogClear)
-    EVT_BUTTON(IDC_LOG_PAUSE, LogWindow::OnLogPause)
-    EVT_BUTTON(IDC_LOG_PREFS, LogWindow::OnLogPrefs)
-END_EVENT_TABLE()
-
-/*
- * Information about log levels.
- *
- * Each entry here corresponds to an entry in the combo box.  The first
- * letter of each name should be unique.
- */
-static const struct {
-    wxString    name;
-    android_LogPriority priority;
-} gLogLevels[] = {
-    { wxT("Verbose"),    ANDROID_LOG_VERBOSE },
-    { wxT("Debug"),      ANDROID_LOG_DEBUG },
-    { wxT("Info"),       ANDROID_LOG_INFO },
-    { wxT("Warn"),       ANDROID_LOG_WARN },
-    { wxT("Error"),      ANDROID_LOG_ERROR }
-};
-
-
-/*
- * Create a new LogWindow.  This should be a child of the main frame.
- */
-LogWindow::LogWindow(wxWindow* parent)
-    : wxDialog(parent, wxID_ANY, wxT("Log Output"), wxDefaultPosition,
-        wxDefaultSize,
-        wxCAPTION | wxSYSTEM_MENU | wxCLOSE_BOX | wxRESIZE_BORDER),
-      mDisplayArray(NULL), mMaxDisplayMsgs(0), mPaused(false),
-      mMinPriority(ANDROID_LOG_VERBOSE),
-      mHeaderFormat(LogPrefsDialog::kHFFull),
-      mSingleLine(false), mExtraSpacing(0), mPointSize(10), mUseColor(true),
-      mFontMonospace(true), mWriteFile(false), mTruncateOld(true), mLogFp(NULL),
-      mNewlyShown(false), mLastPosition(wxDefaultPosition), mVisible(false)
-{
-    ConstructControls();
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-    int poolSize = 10240;       // 10MB
-    pPrefs->GetInt("log-pool-size-kbytes", &poolSize);
-    assert(poolSize > 0);
-    mPool.Resize(poolSize * 1024);
-
-    mMaxDisplayMsgs = 1000;
-    pPrefs->GetInt("log-display-msg-count", &mMaxDisplayMsgs);
-    assert(mMaxDisplayMsgs > 0);
-    mDisplayArray = new LogMessage*[mMaxDisplayMsgs];
-    memset(mDisplayArray, 0, sizeof(LogMessage*) * mMaxDisplayMsgs);
-    mTopPtr = -1;
-    mNextPtr = 0;
-
-    int tmpInt = (int) mHeaderFormat;
-    pPrefs->GetInt("log-header-format", &tmpInt);
-    mHeaderFormat = (LogPrefsDialog::HeaderFormat) tmpInt;
-    pPrefs->GetBool("log-single-line", &mSingleLine);
-    pPrefs->GetInt("log-extra-spacing", &mExtraSpacing);
-    pPrefs->GetInt("log-point-size", &mPointSize);
-    pPrefs->GetBool("log-use-color", &mUseColor);
-    pPrefs->SetBool("log-font-monospace", &mFontMonospace);
-    SetTextStyle();
-
-    mFileName = wxT("/tmp/android-log.txt");
-    pPrefs->GetBool("log-write-file", &mWriteFile);
-    pPrefs->GetString("log-filename", /*ref*/mFileName);
-    pPrefs->GetBool("log-truncate-old", &mTruncateOld);
-
-    PrepareLogFile();
-}
-
-/*
- * Destroy everything we own.
- */
-LogWindow::~LogWindow(void)
-{
-    ClearDisplay();
-    delete[] mDisplayArray;
-
-    if (mLogFp != NULL)
-        fclose(mLogFp);
-}
-
-/*
- * Set the text style, based on our preferences.
- */
-void LogWindow::SetTextStyle(void)
-{
-    wxTextCtrl* pTextCtrl;
-    pTextCtrl = (wxTextCtrl*) FindWindow(IDC_LOG_TEXT);
-    wxTextAttr style;
-    style = pTextCtrl->GetDefaultStyle();
-
-    if (mFontMonospace) {
-        wxFont font(mPointSize, wxFONTFAMILY_MODERN, wxFONTSTYLE_NORMAL,
-            wxFONTWEIGHT_NORMAL);
-        style.SetFont(font);
-    } else {
-        wxFont font(mPointSize, wxFONTFAMILY_SWISS, wxFONTSTYLE_NORMAL,
-            wxFONTWEIGHT_NORMAL);
-        style.SetFont(font);
-    }
-
-    pTextCtrl->SetDefaultStyle(style);
-}
-
-/*
- * Set up the goodies in the window.
- *
- * Also initializes mMinPriority.
- */
-void LogWindow::ConstructControls(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    wxPanel* base = new wxPanel(this, wxID_ANY);
-    wxBoxSizer* masterSizer = new wxBoxSizer(wxVERTICAL);
-    wxBoxSizer* indentSizer = new wxBoxSizer(wxHORIZONTAL);
-    wxBoxSizer* configPrioritySizer = new wxBoxSizer(wxHORIZONTAL);
-    wxGridSizer* configSizer = new wxGridSizer(4, 1);
-
-    /*
-     * Configure log level combo box.
-     */
-    wxComboBox* logLevel;
-    int defaultLogLevel = 1;
-    pPrefs->GetInt("log-display-level", &defaultLogLevel);
-    logLevel = new wxComboBox(base, IDC_LOG_LEVEL, wxT(""),
-        wxDefaultPosition, wxDefaultSize, 0, NULL,
-        wxCB_READONLY /*| wxSUNKEN_BORDER*/);
-    for (int i = 0; i < NELEM(gLogLevels); i++) {
-        logLevel->Append(gLogLevels[i].name);
-        logLevel->SetClientData(i, (void*) gLogLevels[i].priority);
-    }
-    logLevel->SetSelection(defaultLogLevel);
-    mMinPriority = gLogLevels[defaultLogLevel].priority;
-
-    /*
-     * Set up stuff at the bottom, starting with the options
-     * at the bottom left.
-     */
-    configPrioritySizer->Add(new wxStaticText(base, wxID_ANY, wxT("Log level:"),
-            wxDefaultPosition, wxDefaultSize, wxALIGN_LEFT),
-        0, wxALIGN_CENTER_VERTICAL);
-    configPrioritySizer->AddSpacer(kInterSpacing);
-    configPrioritySizer->Add(logLevel);
-
-    wxButton* clear = new wxButton(base, IDC_LOG_CLEAR, wxT("&Clear"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    wxButton* pause = new wxButton(base, IDC_LOG_PAUSE, wxT("&Pause"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    wxButton* prefs = new wxButton(base, IDC_LOG_PREFS, wxT("C&onfigure"),
-        wxDefaultPosition, wxDefaultSize, 0);
-
-    configSizer->Add(configPrioritySizer, 0, wxALIGN_LEFT);
-    configSizer->Add(clear, 0, wxALIGN_CENTER);
-    configSizer->Add(pause, 0, wxALIGN_CENTER);
-    configSizer->Add(prefs, 0, wxALIGN_RIGHT);
-
-    /*
-     * Create text ctrl.
-     */
-    wxTextCtrl* pTextCtrl;
-    pTextCtrl = new wxTextCtrl(base, IDC_LOG_TEXT, wxT(""),
-        wxDefaultPosition, wxDefaultSize,
-        wxTE_MULTILINE | wxTE_READONLY | wxTE_RICH2 | wxTE_NOHIDESEL |
-            wxHSCROLL);
-
-    /*
-     * Add components to master sizer.
-     */
-    masterSizer->AddSpacer(kEdgeSpacing);
-    masterSizer->Add(pTextCtrl, 1, wxEXPAND);
-    masterSizer->AddSpacer(kInterSpacing);
-    masterSizer->Add(configSizer, 0, wxEXPAND);
-    masterSizer->AddSpacer(kEdgeSpacing);
-
-    /*
-     * Indent from sides.
-     */
-    indentSizer->AddSpacer(kEdgeSpacing);
-    indentSizer->Add(masterSizer, 1, wxEXPAND);
-    indentSizer->AddSpacer(kEdgeSpacing);
-
-    base->SetSizer(indentSizer);
-
-    indentSizer->Fit(this);             // shrink-to-fit
-    indentSizer->SetSizeHints(this);    // define minimum size
-}
-
-/*
- * In some cases, this means the user has clicked on our "close" button.
- * We don't really even want one, but both WinXP and KDE put one on our
- * window whether we want it or not.  So, we make it work as a "hide"
- * button instead.
- *
- * This also gets called when the app is shutting down, and we do want
- * to destroy ourselves then, saving various information about our state.
- */
-void LogWindow::OnClose(wxCloseEvent& event)
-{
-    /* just hide the window, unless we're shutting down */
-    if (event.CanVeto()) {
-        event.Veto();
-        Show(false);
-        return;
-    }
-
-    /*
-     * Save some preferences.
-     */
-    SaveWindowPrefs();
-
-    /* if we can't veto the Close(), destroy ourselves */
-    Destroy();
-}
-
-/*
- * Save all of our preferences to the config file.
- */
-void LogWindow::SaveWindowPrefs(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-    /*
-     * Save shown/hidden state.
-     */
-    pPrefs->SetBool("window-log-show", IsShown());
-
-    /*
-     * Limits and formatting prefs.
-     */
-    pPrefs->SetInt("log-display-msg-count", mMaxDisplayMsgs);
-    pPrefs->SetInt("log-pool-size-kbytes", mPool.GetMaxSize() / 1024);
-
-    pPrefs->SetInt("log-header-format", mHeaderFormat);
-    pPrefs->SetBool("log-single-line", mSingleLine);
-    pPrefs->SetInt("log-extra-spacing", mExtraSpacing);
-    pPrefs->SetInt("log-point-size", mPointSize);
-    pPrefs->SetBool("log-use-color", mUseColor);
-    pPrefs->SetBool("log-font-monospace", mFontMonospace);
-
-    pPrefs->SetBool("log-write-file", mWriteFile);
-    pPrefs->SetString("log-filename", mFileName.ToAscii());
-    pPrefs->SetBool("log-truncate-old", mTruncateOld);
-
-    /*
-     * Save window size and position.
-     */
-    wxPoint posn;
-    wxSize size;
-
-    assert(pPrefs != NULL);
-
-    posn = GetPosition();
-    size = GetSize();
-
-    pPrefs->SetInt("window-log-x", posn.x);
-    pPrefs->SetInt("window-log-y", posn.y);
-    pPrefs->SetInt("window-log-width", size.GetWidth());
-    pPrefs->SetInt("window-log-height", size.GetHeight());
-
-    /*
-     * Save current setting of debug level combo box.
-     */
-    wxComboBox* pCombo;
-    int selection;
-    pCombo = (wxComboBox*) FindWindow(IDC_LOG_LEVEL);
-    selection = pCombo->GetSelection();
-    pPrefs->SetInt("log-display-level", selection);
-}
-
-/*
- * Return the desired position and size.
- */
-/*static*/ wxRect LogWindow::GetPrefWindowRect(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    int x, y, width, height;
-
-    assert(pPrefs != NULL);
-
-    x = y = 10;
-    width = 500;
-    height = 200;
-
-    /* these don't modify the arg if the pref doesn't exist */
-    pPrefs->GetInt("window-log-x", &x);
-    pPrefs->GetInt("window-log-y", &y);
-    pPrefs->GetInt("window-log-width", &width);
-    pPrefs->GetInt("window-log-height", &height);
-
-    return wxRect(x, y, width, height);
-}
-
-/*
- * Under Linux+GTK, the first time you show the window, it appears where
- * it's supposed to.  If you then hide it and show it again, it gets
- * moved on top of the parent window.  After that, you can reposition it
- * and it remembers its position across hide/show.
- *
- * To counter this annoyance, we save the position when we hide, and
- * reset the position after a show.  The "newly shown" flag ensures that
- * we only reposition the window as the result of a Show(true) call.
- *
- * Sometimes, something helpful will shift the window over if it's
- * partially straddling a seam between two monitors.  I don't see an easy
- * way to block this, and I'm not sure I want to anyway.
- */
-void LogWindow::OnMove(wxMoveEvent& event)
-{
-    wxPoint point;
-    point = event.GetPosition();
-    //printf("Sim: log window is at (%d,%d) (new=%d)\n", point.x, point.y,
-    //    mNewlyShown);
-
-    if (mNewlyShown) {
-        if (mLastPosition == wxDefaultPosition) {
-            //printf("Sim: no last position established\n");
-        } else {
-            Move(mLastPosition);
-        }
-
-        mNewlyShown = false;
-    }
-}
-
-/*
- * Set the "newly shown" flag.
- */
-bool LogWindow::Show(bool show)
-{
-    if (show) {
-        mNewlyShown = true;
-        Redisplay();
-    } else {
-        mLastPosition = GetPosition();
-    }
-
-    mVisible = show;
-    return wxDialog::Show(show);
-}
-
-/*
- * User has adjusted the log level.  Update the display appropriately.
- *
- * This is a wxEVT_COMMAND_COMBOBOX_SELECTED event.
- */
-void LogWindow::OnLogLevel(wxCommandEvent& event)
-{
-    int selection;
-    android_LogPriority priority;
-
-    selection = event.GetInt();
-    wxComboBox* pCombo = (wxComboBox*) FindWindow(IDC_LOG_LEVEL);
-    priority = (android_LogPriority) (long)pCombo->GetClientData(event.GetInt());
-
-    printf("Sim: log level selected: %d (%s)\n", (int) priority,
-        (const char*) gLogLevels[selection].name.ToAscii());
-    mMinPriority = priority;
-    Redisplay();
-}
-
-/*
- * Clear out the log.
- */
-void LogWindow::OnLogClear(wxCommandEvent& event)
-{
-    ClearDisplay();
-    mPool.Clear();
-}
-
-/*
- * Handle the pause/resume button.
- *
- * If we're un-pausing, we need to get caught up.
- */
-void LogWindow::OnLogPause(wxCommandEvent& event)
-{
-    mPaused = !mPaused;
-
-    wxButton* pButton = (wxButton*) FindWindow(IDC_LOG_PAUSE);
-    if (mPaused) {
-        pButton->SetLabel(wxT("&Resume"));
-
-        mPool.SetBookmark();
-    } else {
-        pButton->SetLabel(wxT("&Pause"));
-
-        LogMessage* pMsg = mPool.GetBookmark();
-        if (pMsg == NULL) {
-            /* bookmarked item fell out of pool */
-            printf("--- bookmark was lost, redisplaying\n");
-            Redisplay();
-        } else {
-            /*
-             * The bookmark points to the last item added to the display.
-             * We want to chase its "prev" pointer to walk toward the head
-             * of the list, adding items from oldest to newest.
-             */
-            pMsg = pMsg->GetPrev();
-            while (pMsg != NULL) {
-                if (FilterMatches(pMsg))
-                    AddToDisplay(pMsg);
-                pMsg = pMsg->GetPrev();
-            }
-        }
-    }
-}
-
-/*
- * Open log preferences dialog.
- */
-void LogWindow::OnLogPrefs(wxCommandEvent& event)
-{
-    LogPrefsDialog dialog(this);
-
-    /*
-     * Set up the dialog.
-     */
-    dialog.mHeaderFormat = mHeaderFormat;
-    dialog.mSingleLine = mSingleLine;
-    dialog.mExtraSpacing = mExtraSpacing;
-    dialog.mPointSize = mPointSize;
-    dialog.mUseColor = mUseColor;
-    dialog.mFontMonospace = mFontMonospace;
-
-    dialog.mDisplayMax = mMaxDisplayMsgs;
-    dialog.mPoolSizeKB = mPool.GetMaxSize() / 1024;
-
-    dialog.mWriteFile = mWriteFile;
-    dialog.mFileName = mFileName;
-    dialog.mTruncateOld = mTruncateOld;
-
-    /*
-     * Show it.  If they hit "OK", copy the updated values out, and
-     * re-display the log output.
-     */
-    if (dialog.ShowModal() == wxID_OK) {
-        /* discard old display arra */
-        ClearDisplay();
-        delete[] mDisplayArray;
-
-        mHeaderFormat = dialog.mHeaderFormat;
-        mSingleLine = dialog.mSingleLine;
-        mExtraSpacing = dialog.mExtraSpacing;
-        mPointSize = dialog.mPointSize;
-        mUseColor = dialog.mUseColor;
-        mFontMonospace = dialog.mFontMonospace;
-
-        assert(dialog.mDisplayMax > 0);
-        assert(dialog.mPoolSizeKB > 0);
-        mMaxDisplayMsgs = dialog.mDisplayMax;
-        mPool.Resize(dialog.mPoolSizeKB * 1024);
-
-        mWriteFile = dialog.mWriteFile;
-        if (mLogFp != NULL && mFileName != dialog.mFileName) {
-            printf("--- log file name changed, closing\n");
-            fclose(mLogFp);
-            mLogFp = NULL;
-        }
-        mFileName = dialog.mFileName;
-        mTruncateOld = dialog.mTruncateOld;
-
-        mDisplayArray = new LogMessage*[mMaxDisplayMsgs];
-        memset(mDisplayArray, 0, sizeof(LogMessage*) * mMaxDisplayMsgs);
-        Redisplay();
-
-        PrepareLogFile();
-    }
-}
-
-/*
- * Handle a log message "user event".  This should only be called in
- * the main UI thread.
- *
- * We take ownership of "*pLogMessage".
- */
-void LogWindow::AddLogMessage(LogMessage* pLogMessage)
-{
-    mPool.Add(pLogMessage);
-
-    if (!mPaused && mVisible && FilterMatches(pLogMessage)) {
-        /*
-         * Thought: keep a reference to the previous message.  If it
-         * matches in most fields (all except timestamp?), hold it and
-         * increment a counter.  If we get a message that doesn't match,
-         * or a timer elapses, synthesize a "previous message repeated N
-         * times" string.
-         */
-        AddToDisplay(pLogMessage);
-    }
-
-    // release the initial ref caused by allocation
-    pLogMessage->Release();
-
-    if (mLogFp != NULL)
-        LogToFile(pLogMessage);
-}
-
-/*
- * Clear out the display, releasing any log messages held in the display
- * array.
- */
-void LogWindow::ClearDisplay(void)
-{
-    wxTextCtrl* pTextCtrl;
-    pTextCtrl = (wxTextCtrl*) FindWindow(IDC_LOG_TEXT);
-    pTextCtrl->Clear();
-
-    /*
-     * Just run through the entire array.
-     */
-    for (int i = 0; i < mMaxDisplayMsgs; i++) {
-        if (mDisplayArray[i] != NULL) {
-            mDisplayArray[i]->Release();
-            mDisplayArray[i] = NULL;
-        }
-    }
-    mTopPtr = -1;
-    mNextPtr = 0;
-}
-
-/*
- * Clear the current display and regenerate it from the log pool.  We need
- * to do this whenever we change filters or log message formatting.
- */
-void LogWindow::Redisplay(void)
-{
-    /*
-     * Freeze output rendering so it doesn't flash during update.  Doesn't
-     * seem to help for GTK, and it leaves garbage on the screen in WinXP,
-     * so I'm leaving it commented out.
-     */
-    //wxTextCtrl* pText = (wxTextCtrl*) FindWindow(IDC_LOG_TEXT);
-    //pText->Freeze();
-
-    //printf("--- redisplay\n");
-    ClearDisplay();
-
-    /*
-     * Set up the default wxWidgets text style stuff.
-     */
-    SetTextStyle();
-
-    /*
-     * Here's the plan:
-     * - Start at the head of the pool (where the most recently added
-     *   items are).
-     * - Check to see if the current item passes our filter.  If it does,
-     *   increment the "found count".
-     * - Continue in this manner until we run out of pool or have
-     *   sufficient items to fill the screen.
-     * - Starting from the current position, walk back toward the head,
-     *   adding the items that meet the current filter criteria.
-     *
-     * Don't forget that the log pool could be empty.
-     */
-    LogMessage* pMsg = mPool.GetHead();
-
-    if (pMsg != NULL) {
-        int foundCount = 0;
-
-        // note this stops before it runs off the end
-        while (pMsg->GetNext() != NULL && foundCount < mMaxDisplayMsgs) {
-            if (FilterMatches(pMsg))
-                foundCount++;
-            pMsg = pMsg->GetNext();
-        }
-
-        while (pMsg != NULL) {
-            if (FilterMatches(pMsg))
-                AddToDisplay(pMsg);
-            pMsg = pMsg->GetPrev();
-        }
-    }
-
-    //pText->Thaw();
-}
-
-
-/*
- * Returns "true" if the currently specified filters would allow this
- * message to be shown.
- */
-bool LogWindow::FilterMatches(const LogMessage* pLogMessage)
-{
-    if (pLogMessage->GetPriority() >= mMinPriority)
-        return true;
-    else
-        return false;
-}
-
-/*
- * Realloc the array of pointers, and remove anything from the display
- * that should no longer be there.
- */
-void LogWindow::SetMaxDisplayMsgs(int max)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-    pPrefs->SetInt("log-display-msg-count", max);
-}
-
-/*
- * Add the message to the display array and to the screen.
- */
-void LogWindow::AddToDisplay(LogMessage* pLogMessage)
-{
-    wxTextCtrl* pTextCtrl;
-    pTextCtrl = (wxTextCtrl*) FindWindow(IDC_LOG_TEXT);
-
-    if (mNextPtr == mTopPtr) {
-        /*
-         * The display array is full.
-         *
-         * We need to eliminate the topmost entry.  This requires removing
-         * it from the array and removing the text from the wxTextCtrl.
-         */
-        pTextCtrl->Remove(0, mDisplayArray[mTopPtr]->GetTextCtrlLen());
-        mDisplayArray[mTopPtr]->Release();
-        mTopPtr = (mTopPtr + 1) % mMaxDisplayMsgs;
-    }
-
-    /*
-     * Add formatted text to the text ctrl.  Track how much actual space
-     * is required.  The space may be different on Win32 (CRLF-based) vs.
-     * GTK (LF-based), so we need to measure it, not compute it from the
-     * text string.
-     */
-    long lastBefore, lastAfter;
-    //long insertBefore;
-    //insertBefore = pTextCtrl->GetInsertionPoint();
-    lastBefore = pTextCtrl->GetLastPosition();
-    FormatMessage(pLogMessage, pTextCtrl);
-    lastAfter = pTextCtrl->GetLastPosition();
-    pLogMessage->SetTextCtrlLen(lastAfter - lastBefore);
-
-    /*
-     * If we restore the old insertion point, we will be glued to where
-     * we were.  This is okay until we start deleting text from the top,
-     * at which point we need to adjust it to retain our position.
-     *
-     * If we set the insertion point to the bottom, we effectively
-     * implement "scroll to bottom on output".
-     *
-     * If we don't set it at all, we get slightly strange behavior out
-     * of GTK, which seems to be par for the course here.
-     */
-    //pTextCtrl->SetInsertionPoint(insertBefore);     // restore insertion pt
-    pTextCtrl->SetInsertionPoint(lastAfter);
-
-    /* add it to array, claim ownership */
-    mDisplayArray[mNextPtr] = pLogMessage;
-    pLogMessage->Acquire();
-
-    /* adjust pointers */
-    if (mTopPtr < 0)        // first time only
-        mTopPtr = 0;
-    mNextPtr = (mNextPtr + 1) % mMaxDisplayMsgs;
-}
-
-
-/*
- * Return a human-readable string for the priority level.  Always returns
- * a valid string.
- */
-static const wxCharBuffer GetPriorityString(android_LogPriority priority)
-{
-    int idx;
-
-    idx = (int) priority - (int) ANDROID_LOG_VERBOSE;
-    if (idx < 0 || idx >= NELEM(gLogLevels))
-        return "?unknown?";
-    return gLogLevels[idx].name.ToAscii();
-}
-
-/*
- * Format a message and write it to the text control.
- */
-void LogWindow::FormatMessage(const LogMessage* pLogMessage, 
-    wxTextCtrl* pTextCtrl)
-{
-#if defined(HAVE_LOCALTIME_R)
-    struct tm tmBuf;
-#endif
-    struct tm* ptm;
-    char timeBuf[32];
-    char msgBuf[256];
-    int msgLen = 0;
-    char* outBuf;
-    char priChar;
-    LogPrefsDialog::HeaderFormat headerFmt;
-
-    headerFmt = mHeaderFormat;
-    if (pLogMessage->GetInternal())
-        headerFmt = LogPrefsDialog::kHFInternal;
-
-    priChar = ((const char*)GetPriorityString(pLogMessage->GetPriority()))[0];
-
-    /*
-     * Get the current date/time in pretty form
-     *
-     * It's often useful when examining a log with "less" to jump to
-     * a specific point in the file by searching for the date/time stamp.
-     * For this reason it's very annoying to have regexp meta characters
-     * in the time stamp.  Don't use forward slashes, parenthesis,
-     * brackets, asterisks, or other special chars here.
-     */
-    time_t when = pLogMessage->GetWhen();
-    const char* fmt = NULL;
-#if defined(HAVE_LOCALTIME_R)
-    ptm = localtime_r(&when, &tmBuf);
-#else
-    ptm = localtime(&when);
-#endif
-    switch (headerFmt) {
-    case LogPrefsDialog::kHFFull:
-    case LogPrefsDialog::kHFInternal:
-        fmt = "%m-%d %H:%M:%S";
-        break;
-    case LogPrefsDialog::kHFBrief:
-    case LogPrefsDialog::kHFMinimal:
-        fmt = "%H:%M:%S";
-        break;
-    default:
-        break;
-    }
-    if (fmt != NULL)
-        strftime(timeBuf, sizeof(timeBuf), fmt, ptm);
-    else
-        strcpy(timeBuf, "-");
-
-    const int kMaxExtraNewlines = 2;
-    char hdrNewline[2];
-    char finalNewlines[kMaxExtraNewlines+1 +1];
-
-    if (mSingleLine)
-        hdrNewline[0] = ' ';
-    else
-        hdrNewline[0] = '\n';
-    hdrNewline[1] = '\0';
-
-    assert(mExtraSpacing <= kMaxExtraNewlines);
-    int i;
-    for (i = 0; i < mExtraSpacing+1; i++)
-        finalNewlines[i] = '\n';
-    finalNewlines[i] = '\0';
-
-    wxTextAttr msgColor;
-    switch (pLogMessage->GetPriority()) {
-    case ANDROID_LOG_WARN:
-        msgColor.SetTextColour(*wxBLUE);
-        break;
-    case ANDROID_LOG_ERROR:
-        msgColor.SetTextColour(*wxRED);
-        break;
-    case ANDROID_LOG_VERBOSE:
-    case ANDROID_LOG_DEBUG:
-    case ANDROID_LOG_INFO:
-    default:
-        msgColor.SetTextColour(*wxBLACK);
-        break;
-    }
-    if (pLogMessage->GetInternal())
-        msgColor.SetTextColour(*wxGREEN);
-
-    /*
-     * Construct a buffer containing the log header.
-     */
-    bool splitHeader = true;
-    outBuf = msgBuf;
-    switch (headerFmt) {
-    case LogPrefsDialog::kHFFull:
-        splitHeader = true;
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "[ %s %5d %c/%-6.6s]%s",
-                    timeBuf, pLogMessage->GetPid(), priChar,
-                    pLogMessage->GetTag(), hdrNewline);
-        break;
-    case LogPrefsDialog::kHFBrief:
-        splitHeader = true;
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "[%s %5d]%s",
-                    timeBuf, pLogMessage->GetPid(), hdrNewline);
-        break;
-    case LogPrefsDialog::kHFMinimal:
-        splitHeader = false;
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "%s %5d- %s",
-                    timeBuf, pLogMessage->GetPid(), pLogMessage->GetMsg());
-        break;
-    case LogPrefsDialog::kHFInternal:
-        splitHeader = false;
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "[%s] %s", timeBuf, pLogMessage->GetMsg());
-        break;
-    default:
-        fprintf(stderr, "Sim: unexpected header format %d\n", headerFmt);
-        assert(false);
-        break;
-    }
-
-    if (msgLen < 0) {
-        fprintf(stderr, "WHOOPS\n");
-        assert(outBuf == msgBuf);
-        return;
-    }
-
-    if (splitHeader) {
-        if (mUseColor)
-            pTextCtrl->SetDefaultStyle(wxTextAttr(*wxLIGHT_GREY));
-        pTextCtrl->AppendText(wxString::FromAscii(outBuf));
-        if (mUseColor)
-            pTextCtrl->SetDefaultStyle(msgColor);
-        pTextCtrl->AppendText(wxString::FromAscii(pLogMessage->GetMsg()));
-        if (mUseColor)
-            pTextCtrl->SetDefaultStyle(*wxBLACK);
-        pTextCtrl->AppendText(wxString::FromAscii(finalNewlines));
-    } else {
-        if (mUseColor)
-            pTextCtrl->SetDefaultStyle(msgColor);
-        pTextCtrl->AppendText(wxString::FromAscii(outBuf));
-        if (mUseColor)
-            pTextCtrl->SetDefaultStyle(*wxBLACK);
-        pTextCtrl->AppendText(wxString::FromAscii(finalNewlines));
-    }
-
-    /* if we allocated storage for this message, free it */
-    if (outBuf != msgBuf)
-        free(outBuf);
-}
-
-/*
- * Write the message to the log file.
- *
- * We can't just do this in FormatMessage(), because that re-writes all
- * messages on the display whenever the output format or filter changes.
- *
- * Use a one-log-per-line format here to make "grep" useful.
- */
-void LogWindow::LogToFile(const LogMessage* pLogMessage)
-{
-#if defined(HAVE_LOCALTIME_R)
-    struct tm tmBuf;
-#endif
-    struct tm* ptm;
-    char timeBuf[32];
-    char msgBuf[256];
-    int msgLen;
-    char* outBuf;
-    char priChar;
-
-    assert(mLogFp != NULL);
-
-    time_t when = pLogMessage->GetWhen();
-#if defined(HAVE_LOCALTIME_R)
-    ptm = localtime_r(&when, &tmBuf);
-#else
-    ptm = localtime(&when);
-#endif
-
-    strftime(timeBuf, sizeof(timeBuf), "%m-%d %H:%M:%S", ptm);
-    priChar = ((const char*)GetPriorityString(pLogMessage->GetPriority()))[0];
-
-    outBuf = msgBuf;
-    if (pLogMessage->GetInternal()) {
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "[%s %5d *] %s\n",
-                    timeBuf, pLogMessage->GetPid(), pLogMessage->GetMsg());
-    } else {
-        msgLen = android_snprintfBuffer(&outBuf, sizeof(msgBuf),
-                    "[%s %5d %c] %s)\n",
-                    timeBuf, pLogMessage->GetPid(), priChar,
-                    pLogMessage->GetMsg());
-    }
-    if (fwrite(outBuf, msgLen, 1, mLogFp) != 1)
-        fprintf(stderr, "Sim: WARNING: partial log write\n");
-    fflush(mLogFp);
-
-    /* if we allocated storage for this message, free it */
-    if (outBuf != msgBuf)
-        free(outBuf);
-}
-
-/*
- * Get the modification date of a file.
- */
-static bool GetFileModDate(const char* fileName, time_t* pModWhen)
-{
-    struct stat sb;
-
-    if (stat(fileName, &sb) < 0)
-        return false;
-
-    *pModWhen = sb.st_mtime;
-    return true;
-}
-
-/*
- * Open or close the log file as appropriate.
- */
-void LogWindow::PrepareLogFile(void)
-{
-    const int kLogFileMaxAge = 8 * 60 * 60;     // 8 hours
-
-    if (!mWriteFile && mLogFp != NULL) {
-        printf("Sim: closing log file\n");
-        fclose(mLogFp);
-        mLogFp = NULL;
-    } else if (mWriteFile && mLogFp == NULL) {
-        printf("Sim: opening log file '%s'\n", (const char*)mFileName.ToAscii());
-        time_t now, modWhen = 0;
-        const char* openFlags;
-
-        now = time(NULL);
-        if (!mTruncateOld ||
-            (GetFileModDate(mFileName.ToAscii(), &modWhen) &&
-             modWhen + kLogFileMaxAge > now))
-        {
-            if (modWhen != 0) {
-                printf("--- log file is %.3f hours old, appending\n",
-                    (now - modWhen) / 3600.0);
-            }
-            openFlags = "a";        // open for append (text mode)
-        } else {
-            if (modWhen != 0) {
-                printf("--- log file is %.3f hours old, truncating\n",
-                    (now - modWhen) / 3600.0);
-            }
-            openFlags = "w";        // open for writing, truncate (text mode)
-        }
-
-        mLogFp = fopen(mFileName.ToAscii(), openFlags);
-        if (mLogFp == NULL) {
-            fprintf(stderr, "Sim: failed opening log file '%s': %s\n",
-                (const char*) mFileName.ToAscii(), strerror(errno));
-        } else {
-            fprintf(mLogFp, "\n\n");
-            fflush(mLogFp);
-        }
-    }
-}
-
-/*
- * Add a new log message.
- *
- * This function can be called from any thread.  It makes a copy of the
- * stuff in "*pBundle" and sends it to the main UI thread.
- */
-/*static*/ void LogWindow::PostLogMsg(const android_LogBundle* pBundle)
-{
-    LogMessage* pNewMessage = LogMessage::Create(pBundle);
-
-    SendToWindow(pNewMessage);
-}
-
-/*
- * Post a simple string to the log.
- */
-/*static*/ void LogWindow::PostLogMsg(const char* msg)
-{
-    LogMessage* pNewMessage = LogMessage::Create(msg);
-
-    SendToWindow(pNewMessage);
-}
-
-/*
- * Post a simple wxString to the log.
- */
-/*static*/ void LogWindow::PostLogMsg(const wxString& msg)
-{
-    LogMessage* pNewMessage = LogMessage::Create(msg.ToAscii());
-
-    SendToWindow(pNewMessage);
-}
-
-/*
- * Send a log message to the log window.
- */
-/*static*/ void LogWindow::SendToWindow(LogMessage* pMessage)
-{
-    if (pMessage != NULL) {
-        wxWindow* pMainFrame = ((MyApp*)wxTheApp)->GetMainFrame();
-        UserEventMessage* pUem = new UserEventMessage;
-        pUem->CreateLogMessage(pMessage);
-
-        UserEvent uev(0, (void*) pUem);
-
-        pMainFrame->AddPendingEvent(uev);
-    } else {
-        fprintf(stderr, "Sim: failed to add new log message\n");
-    }
-}
-
-
-/*
- * This is a sanity check.  We need to stop somewhere to avoid trashing
- * the system on bad input.
- */
-#define kMaxLen 65536
-
-#define VSNPRINTF vsnprintf     // used to worry about _vsnprintf
-
-
-/*
- * Print a formatted message into a buffer.  Pass in a buffer to try to use.
- *
- * If the buffer isn't big enough to hold the message, allocate storage
- * with malloc() and return that instead.  The caller is responsible for
- * freeing the storage.
- *
- * Returns the length of the string, or -1 if the printf call failed.
- */
-static int android_vsnprintfBuffer(char** pBuf, int bufLen, const char* format, va_list args)
-{
-    int charsOut;
-    char* localBuf = NULL;
-
-    assert(pBuf != NULL && *pBuf != NULL);
-    assert(bufLen > 0);
-    assert(format != NULL);
-
-    while (1) {
-        /*
-         * In some versions of libc, vsnprintf only returns 0 or -1, where
-         * -1 indicates the the buffer wasn't big enough.  In glibc 2.1
-         * and later, it returns the actual size needed.
-         *
-         * MinGW is just returning -1, so we have to retry there.
-         */
-        char* newBuf;
-
-        charsOut = VSNPRINTF(*pBuf, bufLen, format, args);
-
-        if (charsOut >= 0 && charsOut < bufLen)
-            break;
-
-        //fprintf(stderr, "EXCEED: %d vs %d\n", charsOut, bufLen);
-        if (charsOut < 0) {
-            /* exact size not known, double previous size */
-            bufLen *= 2;
-            if (bufLen > kMaxLen)
-                goto fail;
-        } else {
-            /* exact size known, just use that */
-
-            bufLen = charsOut + 1;
-        }
-        //fprintf(stderr, "RETRY at %d\n", bufLen);
-
-        newBuf = (char*) realloc(localBuf, bufLen);
-        if (newBuf == NULL)
-            goto fail;
-        *pBuf = localBuf = newBuf;
-    }
-
-    // On platforms where snprintf() doesn't return the number of
-    // characters output, we would need to call strlen() here.
-
-    return charsOut;
-
-fail:
-    if (localBuf != NULL) {
-        free(localBuf);
-        *pBuf = NULL;
-    }
-    return -1;
-}
-
-/*
- * Variable-arg form of the above.
- */
-static int android_snprintfBuffer(char** pBuf, int bufLen, const char* format, ...)
-{
-    va_list args;
-    int result;
-
-    va_start(args, format);
-    result = android_vsnprintfBuffer(pBuf, bufLen, format, args);
-    va_end(args);
-
-    return result;
-}
-
-
diff --git a/simulator/app/LogWindow.h b/simulator/app/LogWindow.h
deleted file mode 100644
index ca9f133..0000000
--- a/simulator/app/LogWindow.h
+++ /dev/null
@@ -1,127 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Window with log output.
-//
-#ifndef _SIM_LOG_WINDOW_H
-#define _SIM_LOG_WINDOW_H
-
-#include "PhoneData.h"
-#include "UserEvent.h"
-#include "LogMessage.h"
-#include "LogPool.h"
-#include "LogPrefsDialog.h"
-
-
-/*
- * Display log output from runtime process.
- *
- * We receive the messages broken into components (date, log level, tag,
- * function name, etc.) and do the formatting ourselves.  We receive all
- * messages regardless of log level, and provide filter controls in the
- * window.
- *
- * Messages are stored in a "log pool", which has a fixed memory footprint.
- * The messages that are currently visible in the log output window are
- * also pointed at from a fixed-size display array.  Changes to output
- * format cause us to clear the display and re-show everything in the
- * display array, while changes to the output filter cause us to
- * re-evaluate the contents of the display pool.
- */
-class LogWindow : public wxDialog {
-public:
-    LogWindow(wxWindow* parent);
-    virtual ~LogWindow(void);
-
-    /* we override this, to cope with annoying GTK behavior */
-    virtual bool Show(bool show = true);
-
-    /* return preferred size and position */
-    static wxRect GetPrefWindowRect(void);
-
-    /* handle a log message "user event" */
-    void AddLogMessage(LogMessage* pLogMessage);
-
-    /* resize the display messages array */
-    void SetMaxDisplayMsgs(int max);
-
-    /* post a message to the log; may be called from non-main thread */
-    static void PostLogMsg(const android_LogBundle* pBundle);
-    static void PostLogMsg(const wxString& msg);
-    static void PostLogMsg(const char* msg);
-
-private:
-    void OnMove(wxMoveEvent& event);
-    void OnClose(wxCloseEvent& event);
-    void OnLogLevel(wxCommandEvent& event);
-    void OnLogClear(wxCommandEvent& event);
-    void OnLogPause(wxCommandEvent& event);
-    void OnLogPrefs(wxCommandEvent& event);
-
-    /* handle incoming log message */
-    void OnUserEvent(UserEvent& event);
-
-    void SaveWindowPrefs(void);
-    void ConstructControls(void);
-
-    void AddToDisplay(LogMessage* pLogMessage);
-    void ClearDisplay(void);
-    void Redisplay(void);
-    void SetTextStyle(void);
-
-    bool FilterMatches(const LogMessage* pLogMessage);
-
-    void FormatMessage(const LogMessage* pLogMessage, 
-        wxTextCtrl* pTextCtrl);
-
-    void LogToFile(const LogMessage* pLogMessage);
-    void PrepareLogFile(void);
-    static void SendToWindow(LogMessage* pMessage);
-
-    /*
-     * Message pool.
-     */
-    LogPool     mPool;
-
-    /*
-     * Display array.  This is a fixed-size circular array that holds
-     * pointers to the log messages currently displayed on screen.
-     */
-    LogMessage**    mDisplayArray;      // ptrs to messages currently displayed
-    int         mMaxDisplayMsgs;        // max #of messages
-    int         mTopPtr;                // index of top message
-    int         mNextPtr;               // index of next empty slot
-
-    bool        mPaused;                // is output paused for review?
-
-    /*
-     * Current filter.
-     */
-    android_LogPriority mMinPriority;   // messages at or above are shown
-
-    /* format options */
-    LogPrefsDialog::HeaderFormat mHeaderFormat;
-    bool        mSingleLine;            // put whole message on one line?
-    int         mExtraSpacing;          // double/triple-space messages?
-    int         mPointSize;             // text point size;
-    bool        mUseColor;              // colorful messages?
-    bool        mFontMonospace;         // use monospace font?
-
-    /* log file options */
-    bool        mWriteFile;
-    wxString    mFileName;
-    bool        mTruncateOld;
-
-    FILE*       mLogFp;
-
-    /*
-     * Window position stuff.
-     */
-    bool        mNewlyShown;
-    wxPoint     mLastPosition;
-    bool        mVisible;
-
-    DECLARE_EVENT_TABLE()
-};
-
-#endif // _SIM_LOG_WINDOW_H
diff --git a/simulator/app/MainFrame.cpp b/simulator/app/MainFrame.cpp
deleted file mode 100644
index b13caab..0000000
--- a/simulator/app/MainFrame.cpp
+++ /dev/null
@@ -1,1462 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Main window, menu bar, and associated goodies.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/button.h"
-#include "wx/help.h"
-#include "wx/filedlg.h"
-#include "wx/slider.h"
-#include "wx/textctrl.h"
-
-#include "MainFrame.h"
-#include "MyApp.h"
-#include "Resource.h"
-#include "PhoneCollection.h"
-#include "PhoneData.h"
-#include "PhoneWindow.h"
-#include "DeviceWindow.h"
-#include "UserEventMessage.h"
-#include "PrefsDialog.h"
-
-#include "SimRuntime.h"
-
-
-static wxString kStatusNotRunning = wxT("Idle");
-static wxString kStatusRunning = wxT("Run");
-
-static wxString kDeviceMenuString = wxT("&Device");
-
-static const wxString gStdJavaApps[] = {
-    wxT(""),
-    wxT("com.android.testharness.TestList"),
-    wxT("com.android.apps.contacts.ContactsList"),
-    wxT("mikeapp")
-};
-
-
-BEGIN_EVENT_TABLE(MainFrame::MainFrame, wxFrame)
-    EVT_CLOSE(MainFrame::OnClose)
-    EVT_TIMER(kHalfSecondTimerId, MainFrame::OnTimer)
-    //EVT_IDLE(MainFrame::OnIdle)
-  
-    EVT_ACTIVATE(MainFrame::OnActivate)
-    EVT_ACTIVATE_APP(MainFrame::OnActivate)
-    EVT_COMBOBOX(IDC_MODE_SELECT, MainFrame::OnComboBox)
-    EVT_COMBOBOX(IDC_JAVA_VM, MainFrame::OnComboBox)
-    EVT_CHECKBOX(IDC_USE_GDB, MainFrame::OnCheckBox)
-    EVT_CHECKBOX(IDC_USE_VALGRIND, MainFrame::OnCheckBox)
-    EVT_CHECKBOX(IDC_CHECK_JNI, MainFrame::OnCheckBox)
-    EVT_CHECKBOX(IDC_OVERLAY_ONION_SKIN, MainFrame::OnCheckBox)
-    EVT_TEXT(IDC_JAVA_APP_NAME, MainFrame::OnText)
-    EVT_TEXT_ENTER(IDC_ONION_SKIN_FILE_NAME, MainFrame::OnTextEnter)
-    EVT_BUTTON(IDC_ONION_SKIN_BUTTON, MainFrame::OnButton)
-    EVT_COMMAND_SCROLL(IDC_ONION_SKIN_ALPHA_VAL, MainFrame::OnSliderChange)
-
-    EVT_MENU(IDM_FILE_PREFERENCES, MainFrame::OnFilePreferences)
-    EVT_MENU(IDM_FILE_EXIT, MainFrame::OnFileExit)
-    EVT_MENU(IDM_RUNTIME_START, MainFrame::OnSimStart)
-    EVT_UPDATE_UI(IDM_RUNTIME_START, MainFrame::OnUpdateSimStart)
-    EVT_MENU(IDM_RUNTIME_STOP, MainFrame::OnSimStop)
-    EVT_UPDATE_UI(IDM_RUNTIME_STOP, MainFrame::OnUpdateSimStop)
-    EVT_MENU(IDM_RUNTIME_RESTART, MainFrame::OnSimRestart)
-    EVT_UPDATE_UI(IDM_RUNTIME_RESTART, MainFrame::OnUpdateSimRestart)
-    EVT_MENU(IDM_RUNTIME_KILL, MainFrame::OnSimKill)
-    EVT_UPDATE_UI(IDM_RUNTIME_KILL, MainFrame::OnUpdateSimKill)
-    EVT_MENU_RANGE(IDM_DEVICE_SEL0, IDM_DEVICE_SELN,
-        MainFrame::OnDeviceSelected)
-    EVT_MENU(IDM_DEVICE_RESCAN, MainFrame::OnDeviceRescan)
-    EVT_UPDATE_UI(IDM_DEBUG_SHOW_LOG, MainFrame::OnUpdateDebugShowLog)
-    EVT_MENU(IDM_DEBUG_SHOW_LOG, MainFrame::OnDebugShowLog)
-    EVT_MENU(IDM_HELP_CONTENTS, MainFrame::OnHelpContents)
-    EVT_MENU(IDM_HELP_ABOUT, MainFrame::OnHelpAbout)
-
-    EVT_USER_EVENT(MainFrame::OnUserEvent)
-END_EVENT_TABLE()
-
-
-/*
- * Main window constructor.
- *
- * Creates menus and status bar.
- */
-MainFrame::MainFrame(const wxString& title, const wxPoint& pos,
-    const wxSize& size, long style)
-    : wxFrame((wxFrame *)NULL, -1, title, pos, size, style),
-      mSimRunning(false),
-      mRestartRequested(false),
-      mpPhoneWindow(NULL),
-      mPhoneWindowPosn(wxDefaultPosition),
-      mTimer(this, kHalfSecondTimerId)
-{
-    mSimAssetPath = ((MyApp*)wxTheApp)->GetSimAssetPath();
-    mSimAssetPath += wxT("/simulator/default/default");
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    int val;
-
-    val = mPhoneWindowPosn.x;
-    pPrefs->GetInt("window-device-x", &val);
-    mPhoneWindowPosn.x = val;
-    val = mPhoneWindowPosn.y;
-    pPrefs->GetInt("window-device-y", &val);
-    mPhoneWindowPosn.y = val;
-
-    /*
-     * Create main menu.
-     */
-    ConstructMenu();
-
-    /*
-     * Create the status bar.
-     */
-    int widths[2] = { -1, 50 };
-    CreateStatusBar(2, wxFULL_REPAINT_ON_RESIZE);   // no wxST_SIZEGRIP
-    SetStatusWidths(2, widths);
-    SetStatusText(wxT("Ready"));
-    SetStatusText(kStatusNotRunning, 1);
-
-    /*
-     * Create main window controls.
-     */
-    ConstructControls();
-
-#if 0
-    /*
-     * Use the standard window color for the main frame (which usually
-     * has a darker color).  This has a dramatic effect under Windows.
-     */
-    wxColour color = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW);
-    SetOwnBackgroundColour(color);
-#endif
-
-    /*
-     * Create the log window.
-     */
-    wxRect layout = LogWindow::GetPrefWindowRect();
-    mpLogWindow = new LogWindow(this);
-    mpLogWindow->Move(layout.GetTopLeft());
-    mpLogWindow->SetSize(layout.GetSize());
-    bool showLogWindow = true;
-    pPrefs->GetBool("window-log-show", &showLogWindow);
-    if (showLogWindow)
-        mpLogWindow->Show();
-
-    /*
-     * Set up a frequent timer.  We use this to keep our "run/idle"
-     * display up to date.  (Ideally this will go away.)
-     */
-    mTimer.Start(400);      // arg is delay in ms
-
-    /*
-     * Handle auto-power-on by sending ourselves an event.  That way it
-     * gets handled after window initialization finishes.
-     */
-    bool autoPowerOn = false;
-    pPrefs->GetBool("auto-power-on", &autoPowerOn);
-    if (autoPowerOn) {
-        printf("Sim: Auto power-up\n");
-        wxCommandEvent startEvent(wxEVT_COMMAND_MENU_SELECTED, IDM_RUNTIME_START);
-        this->AddPendingEvent(startEvent);
-    }
-
-    /*
-     * wxThread wants these to be on the heap -- it will call delete on the
-     * object when the thread exits.
-     */
-    mExternalRuntimeThread = new ExternalRuntime();
-    mExternalRuntimeThread->StartThread();
-    mPropertyServerThread = new PropertyServer();
-    mPropertyServerThread->StartThread();
-}
-
-/*
- * Construct the main menu.  Called from the constructor.
- */
-void MainFrame::ConstructMenu(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-    /*
-     * Scan for available phones.
-     */
-    PhoneCollection* pCollection = PhoneCollection::GetInstance();
-    pCollection->ScanForPhones(mSimAssetPath.ToAscii());
-
-    /*
-     * Create the "File" menu.
-     */
-    wxMenu* menuFile = new wxMenu;
-
-    menuFile->Append(IDM_FILE_PREFERENCES, wxT("&Preferences..."),
-        wxT("Edit simulator preferences"));
-    menuFile->AppendSeparator();
-    menuFile->Append(IDM_FILE_EXIT, wxT("E&xit\tCtrl-Q"),
-        wxT("Stop simulator and exit"));
-
-    /*
-     * Create the "Runtime" menu.
-     */
-    wxMenu* menuRuntime = new wxMenu;
-    menuRuntime->Append(IDM_RUNTIME_START, wxT("&Power On\tCtrl-G"),
-        wxT("Start the device"));
-//    menuRuntime->Append(IDM_RUNTIME_STOP, wxT("Power &Off"),
-//        wxT("Stop the device"));
-    menuRuntime->AppendSeparator();
-//    menuRuntime->Append(IDM_RUNTIME_RESTART, wxT("&Restart"),
-//        wxT("Restart the device"));
-    menuRuntime->Append(IDM_RUNTIME_KILL, wxT("&Kill\tCtrl-K"),
-        wxT("Kill the runtime processes"));
-
-    /*
-     * Create "Device" menu.
-     */
-    wxString defaultDevice = wxT("Sooner");
-    pPrefs->GetString("default-device", /*ref*/ defaultDevice);
-    wxMenu* menuDevice = CreateDeviceMenu(defaultDevice.ToAscii());
-
-    /*
-     * Create "Debug" menu.
-     */
-    wxMenu* menuDebug = new wxMenu;
-    menuDebug->AppendCheckItem(IDM_DEBUG_SHOW_LOG, wxT("View &Log Output"),
-        wxT("View log output window"));
-
-    /*
-     * Create the "Help" menu.
-     */
-    wxMenu* menuHelp = new wxMenu;
-    menuHelp->Append(IDM_HELP_CONTENTS, wxT("&Contents...\tF1"),
-        wxT("Simulator help"));
-    menuHelp->AppendSeparator();
-    menuHelp->Append(IDM_HELP_ABOUT, wxT("&About..."),
-        wxT("See the fabulous 'about' box"));
-
-    /*
-     * Create the menu bar.
-     */
-    wxMenuBar *menuBar = new wxMenuBar;
-    menuBar->Append(menuFile, wxT("&File"));
-    menuBar->Append(menuDevice, kDeviceMenuString);
-    menuBar->Append(menuRuntime, wxT("&Runtime"));
-    menuBar->Append(menuDebug, wxT("&Debug"));
-    menuBar->Append(menuHelp, wxT("&Help"));
-
-    SetMenuBar(menuBar);
-
-}
-
-/*
- * Construct the "device" menu from our phone collection.
- */
-wxMenu* MainFrame::CreateDeviceMenu(const char* defaultItemName)
-{
-    wxMenu* menuDevice = new wxMenu;
-    PhoneCollection* pCollection = PhoneCollection::GetInstance();
-    int defaultModel = 0;
-
-    for (int i = 0; i < pCollection->GetPhoneCount(); i++) {
-        PhoneData* pPhoneData = pCollection->GetPhoneData(i);
-        assert(pPhoneData != NULL);
-
-        menuDevice->AppendRadioItem(IDM_DEVICE_SEL0 + i,
-            wxString::FromAscii(pPhoneData->GetTitle()));
-
-        // use this one as default if the string matches
-        if (strcasecmp(pPhoneData->GetName(), defaultItemName) == 0)
-            defaultModel = i;
-    }
-
-    menuDevice->Check(IDM_DEVICE_SEL0 + defaultModel, true);
-
-    menuDevice->AppendSeparator();
-    menuDevice->Append(IDM_DEVICE_RESCAN, wxT("Re-scan"));
-
-    return menuDevice;
-}
-
-/*
- * Create some controls in the main window.
- *
- * The main frame doesn't use the normal background color that you find
- * in dialog windows, so we create a "panel" and put all the controls
- * on that.
- */
-void MainFrame::ConstructControls(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    wxPanel* base = new wxPanel(this, wxID_ANY);
-    wxBoxSizer* masterSizer = new wxBoxSizer(wxVERTICAL);
-    wxBoxSizer* tmpSizer;
-    wxStaticBoxSizer* displayOptSizer;
-    wxStaticBoxSizer* runtimeOptSizer;
-    wxStaticBoxSizer* onionSkinOptSizer;
-    wxComboBox* pModeSelection;
-    wxCheckBox* pUseGDB;
-    wxCheckBox* pUseValgrind;
-    wxCheckBox* pCheckJni;
-    wxCheckBox* pOverlayOnionSkin;
-    
-    displayOptSizer = new wxStaticBoxSizer(wxHORIZONTAL, base,
-        wxT("Configuration"));
-    runtimeOptSizer = new wxStaticBoxSizer(wxVERTICAL, base,
-        wxT("Runtime Options"));
-    onionSkinOptSizer = new wxStaticBoxSizer(wxVERTICAL, base,
-        wxT("Onion Skin Options"));
-
-    /*
-     * Set up the configuration sizer (nee "display options").
-     */
-    tmpSizer = new wxBoxSizer(wxHORIZONTAL);
-    displayOptSizer->Add(tmpSizer);
-    tmpSizer->Add(
-            new wxStaticText(base, wxID_ANY, wxT("Device mode:"),
-            wxDefaultPosition, wxDefaultSize, wxALIGN_LEFT), 0, wxALIGN_CENTER_VERTICAL);
-    pModeSelection = new wxComboBox(base, IDC_MODE_SELECT, wxT(""),
-            wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY);
-    tmpSizer->AddSpacer(kInterSpacing);
-    tmpSizer->Add(pModeSelection);
-
-    displayOptSizer->AddSpacer(kInterSpacing);
-
-    /*
-     * Configure the runtime options sizer.
-     */
-    wxComboBox* pJavaAppName;
-    tmpSizer = new wxBoxSizer(wxHORIZONTAL);
-    pUseGDB = new wxCheckBox(base, IDC_USE_GDB, wxT("Use &debugger"));
-    tmpSizer->Add(pUseGDB);
-    tmpSizer->AddSpacer(kInterSpacing);
-    pUseValgrind = new wxCheckBox(base, IDC_USE_VALGRIND, wxT("Use &valgrind"));
-    tmpSizer->Add(pUseValgrind);
-    tmpSizer->AddSpacer(kInterSpacing);
-    pCheckJni = new wxCheckBox(base, IDC_CHECK_JNI, wxT("Check &JNI"));
-    tmpSizer->Add(pCheckJni);
-
-    pJavaAppName = new wxComboBox(base, IDC_JAVA_APP_NAME, wxT(""),
-        wxDefaultPosition, wxSize(320, -1), NELEM(gStdJavaApps), gStdJavaApps,
-        wxCB_DROPDOWN);
-    wxBoxSizer* javaAppSizer = new wxBoxSizer(wxHORIZONTAL);
-    javaAppSizer->Add(
-            new wxStaticText(base, wxID_ANY,
-                wxT("Java app:"),
-                wxDefaultPosition, wxDefaultSize,
-                wxALIGN_LEFT),
-            0, wxALIGN_CENTER_VERTICAL);
-    javaAppSizer->AddSpacer(kInterSpacing);
-    javaAppSizer->Add(pJavaAppName);
-
-    runtimeOptSizer->Add(tmpSizer);
-
-    runtimeOptSizer->AddSpacer(kInterSpacing);
-    runtimeOptSizer->Add(javaAppSizer);
-    runtimeOptSizer->AddSpacer(kInterSpacing);
-
-    wxString tmpStr;
-    SetCheckFromPref(pUseGDB, "debug", false);
-    SetCheckFromPref(pUseValgrind, "valgrind", false);
-    SetCheckFromPref(pCheckJni, "check-jni", false);
-    if (pPrefs->GetString("java-app-name", /*ref*/ tmpStr))
-        pJavaAppName->SetValue(tmpStr);
-
-    /*
-     * Configure the onion skin options sizer.
-     */
-    wxTextCtrl* pOnionSkinFileNameText;
-    wxButton* pOnionSkinFileButton;
-    wxSlider* pOnionSkinAlphaSlider;
-    tmpSizer = new wxBoxSizer(wxHORIZONTAL);
-    pOverlayOnionSkin = new wxCheckBox(base, 
-        IDC_OVERLAY_ONION_SKIN, wxT("Overlay &onion skin"));
-    tmpSizer->Add(pOverlayOnionSkin);
-
-    pOnionSkinFileNameText = new wxTextCtrl(base, 
-        IDC_ONION_SKIN_FILE_NAME, wxT(""),
-        wxDefaultPosition, wxSize(250, -1),
-        wxTE_PROCESS_ENTER);
-    pOnionSkinFileButton = new wxButton(base, IDC_ONION_SKIN_BUTTON,
-        wxT("Choose"));
-
-    wxBoxSizer* onionSkinFileNameSizer = new wxBoxSizer(wxHORIZONTAL);
-    onionSkinFileNameSizer->Add(
-        new wxStaticText(base, wxID_ANY,
-            wxT("Filename:"),
-            wxDefaultPosition, wxDefaultSize,
-            wxALIGN_LEFT),
-        0, wxALIGN_CENTER_VERTICAL);
-    onionSkinFileNameSizer->AddSpacer(kInterSpacing);
-    onionSkinFileNameSizer->Add(pOnionSkinFileNameText);
-    onionSkinFileNameSizer->Add(pOnionSkinFileButton);
-
-    wxBoxSizer * onionSkinAlphaSizer = new wxBoxSizer(wxHORIZONTAL);
-    int initialAlphaVal = 127;
-    pPrefs->GetInt("onion-skin-alpha-value", &initialAlphaVal);
-    pOnionSkinAlphaSlider = new wxSlider(base, IDC_ONION_SKIN_ALPHA_VAL,
-        initialAlphaVal, 0, 255, wxDefaultPosition, wxSize(150, 20));
-    onionSkinAlphaSizer->Add(
-        new wxStaticText(base, wxID_ANY,
-            wxT("Transparency:"),
-            wxDefaultPosition, wxDefaultSize,
-            wxALIGN_LEFT),
-        0, wxALIGN_CENTER_VERTICAL);
-    onionSkinAlphaSizer->AddSpacer(kInterSpacing);
-    onionSkinAlphaSizer->Add(pOnionSkinAlphaSlider, 1, wxCENTRE | wxALL, 5);
-
-    onionSkinOptSizer->Add(tmpSizer);
-    onionSkinOptSizer->AddSpacer(kInterSpacing);
-    onionSkinOptSizer->Add(onionSkinFileNameSizer);
-    onionSkinOptSizer->Add(onionSkinAlphaSizer);
-
-    wxString tmpStr2;
-    SetCheckFromPref(pOverlayOnionSkin, "overlay-onion-skin", false);
-    if (pPrefs->GetString("onion-skin-file-name", /*ref*/ tmpStr2))
-        pOnionSkinFileNameText->SetValue(tmpStr2);
-
-    /*
-     * Add the various components to the master sizer.
-     */
-    masterSizer->Add(displayOptSizer);
-    masterSizer->AddSpacer(kInterSpacing * 2);
-    masterSizer->Add(runtimeOptSizer);
-    masterSizer->AddSpacer(kInterSpacing * 2);
-    masterSizer->Add(onionSkinOptSizer);
-    //masterSizer->AddSpacer(kInterSpacing);
-
-    /*
-     * I don't see a way to guarantee that the window is wide enough to
-     * show the entire menu bar, so just throw some pixels at it.
-     */
-    wxBoxSizer* minWidthSizer = new wxBoxSizer(wxVERTICAL);
-    minWidthSizer->Add(300, kEdgeSpacing);       // forces minimum width
-    minWidthSizer->Add(masterSizer);
-    minWidthSizer->AddSpacer(kInterSpacing * 2);
-
-    /* move us a few pixels in from the left */
-    wxBoxSizer* indentSizer = new wxBoxSizer(wxHORIZONTAL);
-    indentSizer->AddSpacer(kEdgeSpacing);
-    indentSizer->Add(minWidthSizer);
-    indentSizer->AddSpacer(kEdgeSpacing);
-
-    base->SetSizer(indentSizer);
-
-    indentSizer->Fit(this);
-    indentSizer->SetSizeHints(this);
-}
-
-/*
- * Set the value of a checkbox based on a value from the config file.
- */
-void MainFrame::SetCheckFromPref(wxCheckBox* pControl, const char* prefStr,
-    bool defaultVal)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    bool val = defaultVal;
-    pPrefs->GetBool(prefStr, &val);
-
-    pControl->SetValue(val);
-}
-
-/*
- * Destructor.
- */
-MainFrame::~MainFrame(void)
-{
-    PhoneCollection::DestroyInstance();
-
-    delete mExternalRuntimeThread;
-    delete mPropertyServerThread;
-
-    // don't touch mpModeSelection -- child of window
-}
-
-/*
- * File->Quit or click on close box.
- *
- * If we want an "are you sure you want to quit" box, add it here.
- */
-void MainFrame::OnClose(wxCloseEvent& event)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-/*
-    if (event.CanVeto())
-        printf("Closing (can veto)\n");
-    else
-        printf("Closing (mandatory)\n");
-*/
-
-    /*
-     * Generally speaking, Close() is not guaranteed to close the window.
-     * However, we want to use it here because (a) our windows are
-     * guaranteed to close, and (b) it provides our windows an opportunity
-     * to tell others that they are about to vanish.
-     */
-    if (mpPhoneWindow != NULL)
-        mpPhoneWindow->Close(true);
-
-    /* save position of main window */
-    wxPoint pos = GetPosition();
-    pPrefs->SetInt("window-main-x", pos.x);
-    pPrefs->SetInt("window-main-y", pos.y);
-
-    /* save default device selection */
-    int idx = GetSelectedDeviceIndex();
-    if (idx >= 0) {
-        PhoneCollection* pCollection = PhoneCollection::GetInstance();
-        PhoneData* pPhoneData = pCollection->GetPhoneData(idx);
-        pPrefs->SetString("default-device", pPhoneData->GetName());
-    }
-
-    if (mpLogWindow != NULL)
-        mpLogWindow->Close(true);
-    Destroy();
-}
-
-/*
- * File->Preferences
- */
-void MainFrame::OnFilePreferences(wxCommandEvent& WXUNUSED(event))
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    PrefsDialog dialog(this);
-    int result;
-
-    result = dialog.ShowModal();
-    if (result == wxID_OK) {
-        /*
-         * The dialog handles writing changes to Preferences, so all we
-         * need to deal with here are changes that have an immediate
-         * impact on us. (which is currently nothing)
-         */
-    }
-}
-
-/*
- * File->Exit
- */
-void MainFrame::OnFileExit(wxCommandEvent& WXUNUSED(event))
-{
-    Close(FALSE);       // false means "allow veto"
-}
-
-/*
- * Decide whether Simulator->Start should be enabled.
- */
-void MainFrame::OnUpdateSimStart(wxUpdateUIEvent& event)
-{
-    if (IsRuntimeRunning())
-        event.Enable(FALSE);
-    else
-        event.Enable(TRUE);
-}
-
-/*
- * Simulator->Start
- */
-void MainFrame::OnSimStart(wxCommandEvent& WXUNUSED(event))
-{
-    // keyboard equivalents can still get here even if menu item disabled
-    if (IsRuntimeRunning())
-        return;
-
-    int id = GetSelectedDeviceIndex();
-    if (id < 0) {
-        fprintf(stderr, "Sim: could not identify currently selected device\n");
-        return;
-    }
-
-#if 0
-    static int foo = 0;
-    foo++;
-    if (foo == 2) {
-        Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-        pPrefs->SetBool("debug", true);
-    }
-#endif
-
-    SetupPhoneUI(id, NULL);
-    if (mpPhoneWindow != NULL)
-        mpPhoneWindow->GetDeviceManager()->StartRuntime();
-}
-
-/*
- * Decide whether Simulator->Stop should be enabled.
- */
-void MainFrame::OnUpdateSimStop(wxUpdateUIEvent& event)
-{
-    if (IsRuntimeRunning())
-        event.Enable(TRUE);
-    else
-        event.Enable(FALSE);
-}
-
-/*
- * Simulator->Stop
- */
-void MainFrame::OnSimStop(wxCommandEvent& WXUNUSED(event))
-{
-    if (!IsRuntimeRunning())
-        return;
-    assert(mpPhoneWindow != NULL);
-    mpPhoneWindow->GetDeviceManager()->StopRuntime();
-}
-
-/*
- * Decide whether Simulator->Restart should be enabled.
- */
-void MainFrame::OnUpdateSimRestart(wxUpdateUIEvent& event)
-{
-    if (IsRuntimeRunning())
-        event.Enable(TRUE);
-    else
-        event.Enable(FALSE);
-}
-
-/*
- * Simulator->Restart - stop then start the device runtime.
- */
-void MainFrame::OnSimRestart(wxCommandEvent& WXUNUSED(event))
-{
-    if (!IsRuntimeRunning())
-        return;
-
-    printf("Restart requested\n");
-    mpPhoneWindow->GetDeviceManager()->StopRuntime();
-
-    mRestartRequested = true;
-}
-
-/*
- * Decide whether Simulator->Kill should be enabled.
- */
-void MainFrame::OnUpdateSimKill(wxUpdateUIEvent& event)
-{
-    if (IsRuntimeKillable())
-        event.Enable(TRUE);
-    else
-        event.Enable(FALSE);
-}
-
-/*
- * Simulator->Kill
- */
-void MainFrame::OnSimKill(wxCommandEvent& WXUNUSED(event))
-{
-    if (!IsRuntimeKillable())
-        return;
-    assert(mpPhoneWindow != NULL);
-    mpPhoneWindow->GetDeviceManager()->KillRuntime();
-}
-
-
-/*
- * Device->[select]
- */
-void MainFrame::OnDeviceSelected(wxCommandEvent& event)
-{
-    wxBusyCursor busyc;
-    int id = event.GetId() - IDM_DEVICE_SEL0;
-
-    SetupPhoneUI(id, NULL);
-}
-
-/*
- * Device->Rescan
- */
-void MainFrame::OnDeviceRescan(wxCommandEvent& event)
-{
-    wxBusyCursor busyc;
-    wxMenuBar* pMenuBar;
-    PhoneCollection* pCollection;
-    wxMenu* pOldMenu;
-    wxMenu* pNewMenu;
-    const char* curDevName = NULL;
-    int idx;
-    
-    /* figure out the current device name */
-    pCollection = PhoneCollection::GetInstance();
-    idx = GetSelectedDeviceIndex();
-    if (idx >= 0) {
-        PhoneData* pPhoneData;
-
-        pPhoneData = pCollection->GetPhoneData(idx);
-        curDevName = pPhoneData->GetName();
-        printf("--- device name is '%s'\n", (const char*) curDevName);
-    }
-
-    /* reconstruct device menu with new data */
-#ifdef BEFORE_ASSET
-    pCollection->ScanForPhones(mSimAssetPath);
-#else
-    pCollection->ScanForPhones(NULL);
-#endif
-
-    pMenuBar = GetMenuBar();
-    idx = pMenuBar->FindMenu(kDeviceMenuString);
-    if (idx == wxNOT_FOUND) {
-        fprintf(stderr, "Sim: couldn't find %s menu\n", (const char*) kDeviceMenuString.ToAscii());
-        return;
-    }
-
-    pNewMenu = CreateDeviceMenu(curDevName);
-
-    pOldMenu = pMenuBar->Replace(idx, pNewMenu, kDeviceMenuString);
-    delete pOldMenu;
-
-    /* tell the PhoneWindow about it; may cause runtime to exit */
-    if (mpPhoneWindow != NULL)
-        mpPhoneWindow->DevicesRescanned();
-}
-
-/*
- * Set checkbox on menu item.
- */
-void MainFrame::OnUpdateDebugShowLog(wxUpdateUIEvent& event)
-{
-    if (mpLogWindow == NULL) {
-        event.Enable(false);
-    } else {
-        event.Enable(true);
-        event.Check(mpLogWindow->IsShown());
-    }
-}
-
-/*
- * Debug->ShowLog toggle.
- */
-void MainFrame::OnDebugShowLog(wxCommandEvent& WXUNUSED(event))
-{
-    mpLogWindow->Show(!mpLogWindow->IsShown());
-}
-
-/*
- * Help->Contents
- */
-void MainFrame::OnHelpContents(wxCommandEvent& WXUNUSED(event))
-{
-    ((MyApp*)wxTheApp)->GetHelpController()->DisplayContents();
-}
-
-/*
- * Help->About
- */
-void MainFrame::OnHelpAbout(wxCommandEvent& WXUNUSED(event))
-{
-    wxMessageBox(wxT("Android Simulator v0.1\n"
-                     "Copyright 2006 The Android Open Source Project"),
-        wxT("About..."), wxOK | wxICON_INFORMATION, this);
-}
-
-/*
- * Sent from phonewindow or when activated
- */
-void MainFrame::OnActivate(wxActivateEvent& event)
-{
-#if 0
-    if (event.GetActive())
-    {
-        if (mpPhoneWindow != NULL &&
-            mpPhoneWindow->GetDeviceManager()->RefreshRuntime())
-        {
-            wxString msg;
-            int sel;
-
-            msg = wxT("Newer runtime executable found. Would you like to reload the device?");
-
-            sel = wxMessageBox(msg, wxT("Android Safety Patrol"),
-                wxYES | wxNO | wxICON_QUESTION, mpPhoneWindow);
-            //printf("BUTTON was %d (yes=%d)\n", sel, wxYES);
-            if (sel == wxYES)
-            {
-                mpPhoneWindow->GetDeviceManager()->StopRuntime();
-                mpPhoneWindow->Close();
-                mpPhoneWindow = NULL;
-                mRestartRequested = true;
-            }
-            else
-            {
-                mpPhoneWindow->GetDeviceManager()->UserCancelledRefresh();
-            }
-        }
-    }
-#endif
-
-    // let wxWidgets do whatever it needs to do
-    event.Skip();
-}
-            
-
-/*
- * Device mode selection box.
- */
-void MainFrame::OnComboBox(wxCommandEvent& event)
-{
-    const char* pref;
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    if (IDC_MODE_SELECT == event.GetId())
-    {
-        int id = GetSelectedDeviceIndex();
-        if (id < 0)
-            return;
-        //printf("--- mode selected: '%s'\n", (const char*) event.GetString().ToAscii());
-
-        /*
-         * Call the phone window's setup function.  Don't call our SetupPhoneUI
-         * function from here -- updating the combo box from a combo box callback
-         * could cause problems.
-         */
-        if (mpPhoneWindow != NULL) {
-            mpPhoneWindow->SetCurrentMode(event.GetString());
-            mpPhoneWindow->Setup(id);
-        }
-    } else if (event.GetId() == IDC_JAVA_VM) {
-        wxComboBox* pBox = (wxComboBox*) FindWindow(IDC_JAVA_VM);
-        pPrefs->SetString("java-vm", pBox->GetValue().ToAscii());
-    }
-}
-
-/*
- * One of our option checkboxes has been changed.
- *
- * We update the prefs database so that the settings are retained when
- * the simulator is next used.
- */
-void MainFrame::OnCheckBox(wxCommandEvent& event)
-{
-    const char* pref;
-
-    switch (event.GetId()) {
-    case IDC_USE_GDB:               pref = "debug";                 break;
-    case IDC_USE_VALGRIND:          pref = "valgrind";              break;
-    case IDC_CHECK_JNI:             pref = "check-jni";             break;
-    case IDC_OVERLAY_ONION_SKIN:    pref = "overlay-onion-skin";    break; 
-    default:
-        printf("Sim: unrecognized checkbox %d in OnCheckBox\n", event.GetId());
-        return;
-    }
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    pPrefs->SetBool(pref, (bool) event.GetInt());
-    //printf("--- set pref '%s' to %d\n", pref, (bool) event.GetInt());
-    if (event.GetId() == IDC_OVERLAY_ONION_SKIN) {
-        BroadcastOnionSkinUpdate();
-    }
-    if (event.GetId() == IDC_CHECK_JNI) {
-        const char* val = "0";
-        if ((bool) event.GetInt())
-            val = "1";
-        mPropertyServerThread->SetProperty(PropertyServer::kPropCheckJni, val);
-
-    }
-}
-
-void MainFrame::BroadcastOnionSkinUpdate() {
-    if (mpPhoneWindow != NULL) {
-        // broadcast a user event indicating an onion skin update
-        UserEvent uev(0, (void*) -1);
-        mpPhoneWindow->GetDeviceManager()->BroadcastEvent(uev);
-    }
-}
-
-/*
- * A text control on the main page is being updated.
- *
- * The current implementation updates the preferences database on every
- * change, which is a bit silly but is easy to do.
- */
-void MainFrame::OnText(wxCommandEvent& event)
-{
-    const char* pref;
-
-    switch (event.GetId()) {
-    case IDC_JAVA_APP_NAME:     pref = "java-app-name"; break;
-    default:
-        printf("Sim: unrecognized textctrl %d in OnText\n", event.GetId());
-        return;
-    }
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    // event.GetString() does not work on Mac -- always blank
-    //pPrefs->SetString(pref, event.GetString());
-    assert(event.GetId() == IDC_JAVA_APP_NAME); // fix if we add more
-    wxComboBox* pBox;
-    pBox = (wxComboBox*) FindWindow(IDC_JAVA_APP_NAME);
-    pPrefs->SetString(pref, pBox->GetValue().ToAscii());
-    //printf("--- set pref '%s' to '%s'\n", pref,(const char*)pBox->GetValue());
-}
-
-/*
- * A user pressed enter in a text control on the main page.
- *
- * The current implementation updates the preferences database on every
- * change, which is a bit silly but is easy to do.
- */
-void MainFrame::OnTextEnter(wxCommandEvent& event)
-{
-    const char* pref;
-
-    switch (event.GetId()) {
-    case IDC_ONION_SKIN_FILE_NAME:
-        pref = "onion-skin-file-name";
-        break;
-    default:
-        printf("Sim: unrecognized textctrl %d in OnTextEnter\n", event.GetId());
-        return;
-    }
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    assert(event.GetId() == IDC_ONION_SKIN_FILE_NAME); // fix if we add more
-    wxTextCtrl* pTextCtrl;
-    pTextCtrl = (wxTextCtrl*) FindWindow(IDC_ONION_SKIN_FILE_NAME);
-    wxString onionSkinFileNameWxString = pTextCtrl->GetValue();
-    char* onionSkinFileName = "";
-    if (onionSkinFileNameWxString.Len() > 0) {
-        onionSkinFileName = android::strdupNew(onionSkinFileNameWxString.ToAscii());
-    }
-    pPrefs->SetString(pref, onionSkinFileName);
-    BroadcastOnionSkinUpdate();
-}
-
-/*
- * A user pressed a button on the main page
- * 
- */
- void MainFrame::OnButton(wxCommandEvent& event)
- {
-    wxWindow* base;
-    wxFileDialog* pOnionSkinFileChooser;
-    int retVal;
-    switch (event.GetId()) {
-    case IDC_ONION_SKIN_BUTTON:
-        base = FindWindow(IDC_ONION_SKIN_BUTTON)->GetParent();
-        pOnionSkinFileChooser = new wxFileDialog(base, 
-            wxT("Choose the onion skin image file."), 
-            wxT(""), wxT(""), wxT("*.*"),
-            wxOPEN | wxFILE_MUST_EXIST);
-        retVal = pOnionSkinFileChooser->ShowModal();
-        if (retVal == pOnionSkinFileChooser->GetAffirmativeId()) {
-            Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-            assert(pPrefs != NULL);
-            wxString fileNameWxString = pOnionSkinFileChooser->GetPath();
-            const char* fileName = android::strdupNew(fileNameWxString.ToAscii());
-            wxTextCtrl* fileTextCtrl = (wxTextCtrl*) FindWindow(IDC_ONION_SKIN_FILE_NAME);
-            fileTextCtrl->SetValue(fileNameWxString);
-            pPrefs->SetString("onion-skin-file-name", fileName);
-            BroadcastOnionSkinUpdate();
-        }
-        break;
-    default:
-        printf("Sim: unrecognized button %d in OnButton\n", event.GetId());
-        return;
-    }     
- }
- 
- /*
-  * The user moved a slider on the main page
-  */
- void MainFrame::OnSliderChange(wxScrollEvent& event)
- {
-    wxSlider* pSlider;
-    Preferences* pPrefs;
-    switch (event.GetId()) {
-    case IDC_ONION_SKIN_ALPHA_VAL:
-        pSlider = (wxSlider*) FindWindow(IDC_ONION_SKIN_ALPHA_VAL);
-        pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-        assert(pPrefs != NULL);
-        pPrefs->SetInt("onion-skin-alpha-value", pSlider->GetValue());
-        BroadcastOnionSkinUpdate();
-        break;
-    default:
-        printf("Sim: unrecognized scroller or slider %d in OnSliderChange\n", event.GetId());
-        return;
-    }     
- }
-
-#if 0
-/*
- * Idle processing.  Under wxWidgets this only called once after UI
- * activity unless you call event.RequestMore().
- */
-void MainFrame::OnIdle(wxIdleEvent& event)
-{
-    event.Skip();       // let base class handler do stuff
-}
-#endif
-
-/*
- * Handle the timer.
- *
- * This is being called in the main thread, so multithreading with the
- * rest of MainFrame isn't a concern here.
- */
-void MainFrame::OnTimer(wxTimerEvent& event)
-{
-    bool status;
-
-    /*
-     * Check to see if the runtime died without telling us.  This can only
-     * happen if we forcibly kill our thread.  We shouldn't really be
-     * doing that anymore, but keep this in for now just in case.
-     */
-    status = IsRuntimeRunning();
-
-    if (mSimRunning != status) {
-        if (!status) {
-            printf("Sim: fixed mSimRunning=%d actual=%d\n",
-                mSimRunning, status);
-            mSimRunning = status;
-
-            if (!status)
-                HandleRuntimeStop();
-        } else {
-            /*
-             * This was happening when we were shutting down but the
-             * device management thread hadn't completely gone away.  The
-             * simple IsRunning test passes, so we get a false positive.
-             * Ignore it.
-             */
-        }
-    }
-
-    if (gWantToKill) {
-        if (IsRuntimeRunning()) {
-            printf("Sim: handling kill request\n");
-            mpPhoneWindow->GetDeviceManager()->KillRuntime();
-        }
-        gWantToKill = false;
-
-        /* see if Ctrl-C should kill us too */
-        Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-        bool die = false;
-
-        pPrefs->GetBool("trap-sigint-suicide", &die);
-        if (die) {
-            printf("Sim: goodbye cruel world!\n");
-            exit(0);
-        }
-    }
-}
-
-/*
- * Determine whether or not the simulator is running.
- */
-bool MainFrame::IsRuntimeRunning(void)
-{
-    bool result;
-
-    if (mpPhoneWindow == NULL)
-        result = false;
-    else if (!mpPhoneWindow->IsReady())
-        result = false;
-    else
-        result = mpPhoneWindow->GetDeviceManager()->IsRunning();
-
-    return result;
-}
-
-/*
- * Determine whether or not the runtime can be killed.
- */
-bool MainFrame::IsRuntimeKillable(void)
-{
-    bool result;
-
-    result = IsRuntimeRunning();
-    if (result)
-        result = mpPhoneWindow->GetDeviceManager()->IsKillable();
-
-    return result;
-}
-
-/*
- * Determine whether two devices are sufficiently compatible.
- */
-bool MainFrame::CompatibleDevices(PhoneData* pData1, PhoneData* pData2)
-{
-    int displayCount;
-
-    displayCount = pData1->GetNumDisplays();
-    if (pData2->GetNumDisplays() != displayCount)
-        return false;
-
-    for (int i = 0; i < displayCount; i++) {
-        PhoneDisplay* pDisplay1 = pData1->GetPhoneDisplay(i);
-        PhoneDisplay* pDisplay2 = pData2->GetPhoneDisplay(i);
-
-        if (!PhoneDisplay::IsCompatible(pDisplay1, pDisplay2))
-            return false;
-    }
-
-    return true;
-}
-
-/*
- * (Re-)arrange the UI for the currently selected phone model.
- *
- * If the simulator is running, and the set of displays for the current
- * device are incompatible with the new device, we need to restart the
- * runtime.  We need to ask for permission first though.
- */
-void MainFrame::SetupPhoneUI(int idx, const char* defaultMode)
-{
-    PhoneCollection* pCollection;
-    PhoneData* pPhoneData;
-    wxString* choices = NULL;
-    int numChoices = 0;
-    int numKeyboards = 0;
-    bool haveDefaultMode = false;
-    wxCharBuffer currentMode;
-    int i;
-
-    pCollection = PhoneCollection::GetInstance();
-    pPhoneData = pCollection->GetPhoneData(idx);
-    if (pPhoneData == NULL) {
-        fprintf(stderr, "ERROR: device index %d not valid\n", idx);
-        goto bail;
-    }
-
-    /*
-     * We have a window up.  If the displays aren't compatible, we'll
-     * need to recreate it.
-     */
-    if (mpPhoneWindow != NULL) {
-        PhoneData* pCurData = mpPhoneWindow->GetPhoneData();
-
-        if (!CompatibleDevices(pCurData, pPhoneData)) {
-            /*
-             * We need to trash the window.  This will also kill the
-             * runtime.  If it's running, ask permission.
-             */
-            if (IsRuntimeRunning()) {
-                wxString msg;
-                int sel;
-
-                msg =  wxT("Switching to the new device requires restarting the");
-                msg += wxT(" runtime.  Continue?");
-
-                sel = wxMessageBox(msg, wxT("Android Safety Patrol"),
-                    wxOK | wxCANCEL | wxICON_QUESTION, this);
-                printf("BUTTON was %d (ok=%d)\n", sel, wxOK);
-                if (sel == wxCANCEL)
-                    goto bail;
-
-                /* shut it down (politely), ask for an eventual restart */
-                mpPhoneWindow->GetDeviceManager()->StopRuntime();
-                mpPhoneWindow->Close();
-                mpPhoneWindow = NULL;
-                mRestartRequested = true;
-                goto bail;
-            } else {
-                /* not running, just trash the window and continue */
-                mpPhoneWindow->Close();
-                mpPhoneWindow = NULL;
-            }
-        }
-    }
-
-    /*
-     * Figure out the set of available modes.
-     */
-
-    numChoices = pPhoneData->GetNumModes();
-    if (numChoices > 0) {
-        choices = new wxString[numChoices];
-        for (i = 0; i < numChoices; i++) {
-            PhoneMode* pPhoneMode;
-            pPhoneMode = pPhoneData->GetPhoneMode(i);
-            choices[i] = wxString::FromAscii(pPhoneMode->GetName());
-            if (defaultMode != NULL &&
-                strcmp(defaultMode, pPhoneMode->GetName()) == 0)
-            {
-                haveDefaultMode = true;
-            }
-        }
-    }
-
-    if (choices == NULL) {
-        /* had a failure earlier; configure UI with default stuff */
-        choices = new wxString[1];
-        choices[0] = wxT("(none)");
-    }
-
-    if (!haveDefaultMode) {
-        /*
-         * Default mode wasn't found.  If we specify it as the default
-         * in the wxComboBox create call it shows up in the combo box
-         * under Linux, even if it doesn't exist in the list.  So, we
-         * make sure that it doesn't get used if we can't find it.
-         */
-        if (defaultMode != NULL) {
-            printf("Sim: HEY: default mode '%s' not found in list\n",
-                defaultMode);
-        }
-        currentMode = choices[0].ToAscii();
-    } else {
-        currentMode = defaultMode;
-    }
-
-
-    /*
-     * Create the window if necessary.
-     */
-    if (mpPhoneWindow == NULL) {
-        // create, setup, and then show window
-        mpPhoneWindow = new PhoneWindow(this, mPhoneWindowPosn);
-        mpPhoneWindow->SetCurrentMode((const char*)currentMode);
-        if (!mpPhoneWindow->Setup(idx)) {
-            delete mpPhoneWindow;
-            mpPhoneWindow = NULL;
-        }
-        if (mpPhoneWindow != NULL) {
-            mpPhoneWindow->Show();
-            //mpPhoneWindow->CheckPlacement();
-        }
-    } else {
-        // just set up for new device
-        mpPhoneWindow->SetCurrentMode((const char*)currentMode);
-        if (!mpPhoneWindow->Setup(idx)) {
-            // it's in an uncertain state, blow it away
-            delete mpPhoneWindow;
-            mpPhoneWindow = NULL;
-        }
-    }
-
-    /*
-     * Reconfigure mode selection box.
-     */
-    wxComboBox* pModeSelection;
-    pModeSelection = (wxComboBox*)FindWindow(IDC_MODE_SELECT);
-    pModeSelection->Clear();
-    for (i = 0; i < numChoices; i++)
-        pModeSelection->Append(choices[i]);
-    pModeSelection->SetSelection(0);
-    pModeSelection->Enable(numChoices > 1);
-    
-    /*
-     * configure qwerty keyboard attribute
-     */
-    numKeyboards = pPhoneData->GetNumKeyboards();
-    if (numKeyboards > 0) {
-        // only use the first keyboard for now
-        PhoneKeyboard* pPhoneKeyboard;
-        pPhoneKeyboard = pPhoneData->GetPhoneKeyboard(0);
-        if (pPhoneKeyboard->getQwerty()) {
-            printf("Sim: set 'qwerty' env\n");
-            setenv("qwerty", "true", true);
-        }
-    }
-    
-bail:
-    delete[] choices;
-}
-
-/*
- * Figure out which device is currently selected.
- *
- * The easiest way to do this is just run down the list of possible IDs
- * and stop when something claims to be checked.
- *
- * Returns -1 if it can't find a checked item (which can happen if no
- * device layouts were found).
- */
-int MainFrame::GetSelectedDeviceIndex(void)
-{
-    wxMenuBar* pMenuBar;
-    wxMenu* pMenu;
-    int idx;
-    
-    pMenuBar = GetMenuBar();
-    idx = pMenuBar->FindMenu(kDeviceMenuString);
-    if (idx == wxNOT_FOUND) {
-        fprintf(stderr, "Sim: couldn't find %s menu\n", (const char*) kDeviceMenuString.ToAscii());
-        return -1;
-    }
-
-    pMenu = pMenuBar->GetMenu(idx);
-
-    //printf("Menu.MenuItemCount = %d\n", pMenu->GetMenuItemCount());
-    for (int j = pMenu->GetMenuItemCount() -1; j >= 0; j--) {
-        wxMenuItem* pItem;
-
-        pItem = pMenu->FindItemByPosition(j);
-        //printf("ITEM %d: %s\n", j, (const char*) pItem->GetLabel());
-        if (pItem->IsChecked()) {
-            printf("Sim: selected device is '%s'\n",
-                (const char*) pItem->GetLabel().ToAscii());
-            return j;
-        }
-    }
-
-    return -1;
-}
-
-/*
- * Receive a status message from the runtime thread.
- */
-void MainFrame::OnUserEvent(UserEvent& event)
-{
-    UserEventMessage* pUem;
-
-    pUem = (UserEventMessage*) event.GetData();
-    assert(pUem != NULL);
-
-    switch (pUem->GetType()) {
-    case UserEventMessage::kRuntimeStarted:
-        printf("Sim: runtime thread started!\n");
-        HandleRuntimeStart();
-        break;
-    case UserEventMessage::kRuntimeStopped:
-        printf("Sim: runtime thread stopped!\n");
-        HandleRuntimeStop();
-        break;
-    case UserEventMessage::kErrorMessage:
-        {
-            wxString msg = pUem->GetString();
-            wxMessageBox(msg, wxT("Android Runtime Error"),
-                wxOK | wxICON_WARNING, this);
-        }
-        break;
-    case UserEventMessage::kLogMessage:
-        mpLogWindow->AddLogMessage(pUem->GetLogMessage());
-        break;
-    case UserEventMessage::kExternalRuntime:
-        HandleExternalRuntime(pUem->GetReader(), pUem->GetWriter());
-        break;
-    default:
-        printf("Sim: MESSAGE: unknown UserEventMessage rcvd (type=%d)\n",
-            pUem->GetType());
-        break;
-    }
-
-    delete pUem;
-}
-
-/*
- * The device management thread is up, so the runtime should be fully
- * running shortly.
- */
-void MainFrame::HandleRuntimeStart(void)
-{
-    mSimRunning = true;
-
-    SetStatusText(kStatusRunning, 1);
-}
-
-/*
- * The device management thread is exiting, so the runtime must be dead.
- */
-void MainFrame::HandleRuntimeStop(void)
-{
-    mSimRunning = false;
-
-    SetStatusText(kStatusNotRunning, 1);
-
-    if (mRestartRequested) {
-        printf("Sim: restarting runtime\n");
-        mRestartRequested = false;
-        SetupPhoneUI(GetSelectedDeviceIndex(), NULL);
-        if (mpPhoneWindow != NULL)
-            mpPhoneWindow->GetDeviceManager()->StartRuntime();
-    }
-}
-
-/*
- * Handle a connection from an external runtime.
- */
-void MainFrame::HandleExternalRuntime(android::Pipe* reader,
-    android::Pipe* writer)
-{
-    android::MessageStream msgStream;
-    android::Message msg;
-
-    if (IsRuntimeRunning()) {
-        /*
-         * Tell the new guy to go away.
-         */
-        if (!msgStream.init(reader, writer, true)) {
-            fprintf(stderr, "Sim: WARNING: unable to talk to remote runtime\n");
-            goto bail;
-        }
-
-        printf("Sim: telling external runtime to go away\n");
-        msg.setCommand(android::Simulator::kCommandGoAway, 0);
-        msgStream.send(&msg);
-    } else {
-        printf("Sim: new external runtime wants to talk to us\n");
-
-        /*
-         * Launch the pieces necessary to talk to this guy.
-         */
-        int id = GetSelectedDeviceIndex();
-        if (id < 0) {
-            fprintf(stderr,
-                "Sim: could not identify currently selected device\n");
-            goto bail;
-        }
-
-        /* kill existing window, so it pops up and reclaims focus */
-        if (mpPhoneWindow != NULL) {
-            Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-            bool okay;
-
-            if (pPrefs->GetBool("refocus-on-restart", &okay) && okay) {
-                printf("Sim: inducing phone window refocus\n");
-                mpPhoneWindow->Close(TRUE);     // no veto
-                mpPhoneWindow = NULL;
-            }
-        }
-
-        SetupPhoneUI(id, NULL);
-        if (mpPhoneWindow != NULL) {
-            mpPhoneWindow->GetDeviceManager()->StartRuntime(reader, writer);
-        } else {
-            fprintf(stderr, "Sim: ERROR: unable to get runtime going\n");
-            goto bail;
-        }
-
-        // we don't own these anymore
-        reader = writer = NULL;
-    }
-
-bail:
-    delete reader;
-    delete writer;
-}
-
-/*
- * The phone window is about to destroy itself.  Get rid of our pointer
- * to it, and record its last position so we can create the new one in
- * the same place.
- */
-void MainFrame::PhoneWindowClosing(int x, int y)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-
-    mpPhoneWindow = NULL;
-
-    mPhoneWindowPosn.x = x;
-    mPhoneWindowPosn.y = y;
-
-    pPrefs->SetInt("window-device-x", x);
-    pPrefs->SetInt("window-device-y", y);
-}
-
diff --git a/simulator/app/MainFrame.h b/simulator/app/MainFrame.h
deleted file mode 100644
index 817a182..0000000
--- a/simulator/app/MainFrame.h
+++ /dev/null
@@ -1,115 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Main window declaration.
-//
-#ifndef _SIM_MAINFRAME_H
-#define _SIM_MAINFRAME_H
-
-#include "PhoneWindow.h"
-#include "DeviceWindow.h"
-#include "LogWindow.h"
-#include "ExternalRuntime.h"
-#include "PropertyServer.h"
-
-/*
- * Main window.
- */
-class MainFrame : public wxFrame {
-public:
-    /* define a constructor so we can set up menus */
-    MainFrame(const wxString& title, const wxPoint& pos, const wxSize& size,
-        long style);
-    virtual ~MainFrame(void);
-
-    /* called by modeless phone window dialog when it closes */
-    void PhoneWindowClosing(int x, int y);
-
-    void Vibrate(int vibrateOn) { mpPhoneWindow->Vibrate(vibrateOn); }
-
-    PropertyServer* GetPropertyServer(void) { return mPropertyServerThread; }
-
-private:
-    void ConstructMenu(void);
-    void ConstructControls(void);
-
-    void OnClose(wxCloseEvent& event);
-    void OnTimer(wxTimerEvent& event);
-    //void OnIdle(wxIdleEvent& event);
-    void OnActivate(wxActivateEvent& event);
-    void OnButton(wxCommandEvent& event);
-    void OnComboBox(wxCommandEvent& event);
-    void OnCheckBox(wxCommandEvent& event);
-    void OnText(wxCommandEvent& event);
-    void OnTextEnter(wxCommandEvent& event);
-    void OnUserEvent(UserEvent& event);
-    void OnSliderChange(wxScrollEvent& event);
-
-    void OnFilePreferences(wxCommandEvent& event);
-    void OnFileExit(wxCommandEvent& event);
-    void OnUpdateSimStart(wxUpdateUIEvent& event);
-    void OnSimStart(wxCommandEvent& event);
-    void OnUpdateSimStop(wxUpdateUIEvent& event);
-    void OnSimStop(wxCommandEvent& event);
-    void OnUpdateSimReload(wxUpdateUIEvent& event);
-    void OnSimReload(wxCommandEvent& event);
-    void OnUpdateSimRestart(wxUpdateUIEvent& event);
-    void OnSimRestart(wxCommandEvent& event);
-    void OnUpdateSimKill(wxUpdateUIEvent& event);
-    void OnSimKill(wxCommandEvent& event);
-    void OnDeviceSelected(wxCommandEvent& event);
-    void OnDeviceRescan(wxCommandEvent& event);
-    void OnUpdateDebugShowLog(wxUpdateUIEvent& event);
-    void OnDebugShowLog(wxCommandEvent& event);
-    void OnHelpContents(wxCommandEvent& event);
-    void OnHelpAbout(wxCommandEvent& event);
-
-    wxMenu* CreateDeviceMenu(const char* defaultItemName);
-    void SetCheckFromPref(wxCheckBox* pControl, const char* prefStr,
-        bool defaultVal);
-
-    void UpdateRuntimeExeStr(void);
-
-    /* prep the phone UI; "defaultMode" may be NULL */
-    void SetupPhoneUI(int idx, const char* defaultMode);
-
-    bool CompatibleDevices(PhoneData* pData1, PhoneData* pData2);
-
-    void HandleRuntimeStart(void);
-    void HandleRuntimeStop(void);
-    void HandleExternalRuntime(android::Pipe* reader, android::Pipe* writer);
-
-    int GetSelectedDeviceIndex(void);
-    bool IsRuntimeRunning(void);
-    bool IsRuntimeKillable(void);
-
-    void BroadcastOnionSkinUpdate(void);
-    
-    bool    mSimRunning;
-    bool    mRestartRequested;
-
-    enum { kHalfSecondTimerId = 1000 };
-
-    wxString        mSimAssetPath;
-
-    /* if we have a phone running, this points to its state */
-    PhoneWindow*    mpPhoneWindow;
-
-    /* phone window position */
-    wxPoint         mPhoneWindowPosn;
-
-    /* window that captures log output */
-    LogWindow*      mpLogWindow;
-
-    wxTimer         mTimer;
-
-    /* watches for connection from runtime */
-    ExternalRuntime* mExternalRuntimeThread;
-
-    /* serve up system properties */
-    PropertyServer*  mPropertyServerThread;
-
-    DECLARE_EVENT_TABLE()
-};
-
-#endif // _SIM_MAINFRAME_H
diff --git a/simulator/app/MessageStream.cpp b/simulator/app/MessageStream.cpp
deleted file mode 100644
index 2397c63..0000000
--- a/simulator/app/MessageStream.cpp
+++ /dev/null
@@ -1,402 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Message stream abstraction.
-//
-#include "MessageStream.h"
-#include "LogBundle.h"
-
-#include "utils/Log.h"
-
-#include <string.h>
-#include <assert.h>
-
-using namespace android;
-
-/*
- * ===========================================================================
- *      Message
- * ===========================================================================
- */
-
-/*
- * Send a blob of raw data.
- */
-void Message::setRaw(const unsigned char* data, int len, Cleanup cleanup)
-{
-    reset();
-
-    mData = const_cast<unsigned char*>(data);
-    mLength = len;
-    mCleanup = cleanup;
-    mType = kTypeRaw;
-}
-
-/*
- * Send a "name=value" config pair.
- */
-void Message::setConfig(const char* name, const char* value)
-{
-    reset();
-
-    assert(name != NULL && value != NULL);
-
-    int nlen = strlen(name) +1;
-    int vlen = strlen(value) +1;
-    mData = new unsigned char[nlen+vlen];
-    mCleanup = kCleanupDelete;
-    mLength = nlen + vlen;
-    mType = kTypeConfig;
-
-    memcpy(mData, name, nlen);
-    memcpy(mData + nlen, value, vlen);
-}
-
-/*
- * Try to return the contents of the message as if it were a name/value pair.
- */
-bool Message::getConfig(const char** pName, const char** pValue)
-{
-    if (mLength < 2)
-        return false;
-    assert(mData != NULL);
-
-    *pName = (const char*) mData;
-    *pValue = (const char*) (mData + strlen((char*)mData) +1);
-    return true;
-}
-
-/*
- * Send a command/arg pair.
- */
-void Message::setCommand(int cmd, int arg)
-{
-    reset();
-
-    mData = new unsigned char[sizeof(int) * 2];
-    mCleanup = kCleanupDelete;
-    mLength = sizeof(int) * 2;
-    mType = kTypeCommand;
-
-    int* pInt = (int*) mData;
-    pInt[0] = cmd;
-    pInt[1] = arg;
-}
-
-/*
- * Send a command with 3 args instead of just one.
- */
-void Message::setCommandExt(int cmd, int arg0, int arg1, int arg2)
-{
-    reset();
-
-    mData = new unsigned char[sizeof(int) * 4];
-    mCleanup = kCleanupDelete;
-    mLength = sizeof(int) * 4;
-    mType = kTypeCommandExt;
-
-    int* pInt = (int*) mData;
-    pInt[0] = cmd;
-    pInt[1] = arg0;
-    pInt[2] = arg1;
-    pInt[3] = arg2;
-}
-
-/*
- * Try to return the contents of the message as if it were a "command".
- */
-bool Message::getCommand(int* pCmd, int* pArg)
-{
-    if (mLength != sizeof(int) * 2) {
-        LOG(LOG_WARN, "", "type is %d, len is %d\n", mType, mLength);
-        return false;
-    }
-    assert(mData != NULL);
-
-    const int* pInt = (const int*) mData;
-    *pCmd = pInt[0];
-    *pArg = pInt[1];
-
-    return true;
-}
-
-/*
- * Serialize a log message.
- *
- * DO NOT call LOG() from here.
- */
-void Message::setLogBundle(const android_LogBundle* pBundle)
-{
-    reset();
-
-    /* get string lengths; we add one here to include the '\0' */
-    int tagLen, msgLen;
-    tagLen = strlen(pBundle->tag) + 1;
-    size_t i;
-    msgLen = 0;
-    for (i=0; i<pBundle->msgCount; i++) msgLen += pBundle->msgVec[i].iov_len;
-    msgLen += 1;
-
-    /* set up the structure */
-    mCleanup = kCleanupDelete;
-    mLength =   sizeof(pBundle->when) +
-                sizeof(pBundle->priority) +
-                sizeof(pBundle->pid) +
-                tagLen +
-                msgLen;
-    mData = new unsigned char[mLength];
-    mType = kTypeLogBundle;
-
-    unsigned char* pCur = mData;
-
-    /* copy the stuff over */
-    *((time_t*)pCur) = pBundle->when;
-    pCur += sizeof(pBundle->when);
-    *((android_LogPriority*)pCur) = pBundle->priority;
-    pCur += sizeof(pBundle->priority);
-    *((pid_t*)pCur) = pBundle->pid;
-    pCur += sizeof(pBundle->pid);
-    memcpy(pCur, pBundle->tag, tagLen);
-    pCur += tagLen;
-    for (i=0; i<pBundle->msgCount; i++) {
-        memcpy(pCur, pBundle->msgVec[i].iov_base, pBundle->msgVec[i].iov_len);
-        pCur += pBundle->msgVec[i].iov_len;
-    }
-    *pCur++ = 0;
-
-    assert(pCur - mData == mLength);
-}
-
-/*
- * Extract the components of a log bundle.
- *
- * We're just returning points inside the message buffer, so the caller
- * will need to copy them out before the next reset().
- */
-bool Message::getLogBundle(android_LogBundle* pBundle)
-{
-    if (mLength < (int)(sizeof(time_t) + sizeof(int)*2 + 4)) {
-        LOG(LOG_WARN, "", "type is %d, len is %d, too small\n",
-            mType, mLength);
-        return false;
-    }
-    assert(mData != NULL);
-
-    unsigned char* pCur = mData;
-
-    pBundle->when = *((time_t*) pCur);
-    pCur += sizeof(pBundle->when);
-    pBundle->priority = *((android_LogPriority*) pCur);
-    pCur += sizeof(pBundle->priority);
-    pBundle->pid = *((pid_t*) pCur);
-    pCur += sizeof(pBundle->pid);
-    pBundle->tag = (const char*) pCur;
-    pCur += strlen((const char*) pCur) +1;
-    mVec.iov_base = (char*) pCur;
-    mVec.iov_len = strlen((const char*) pCur);
-    pBundle->msgVec = &mVec;
-    pBundle->msgCount = 1;
-    pCur += mVec.iov_len +1;
-
-    if (pCur - mData != mLength) {
-        LOG(LOG_WARN, "", "log bundle rcvd %d, used %d\n", mLength,
-            (int) (pCur - mData));
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Read the next event from the pipe.
- *
- * This is not expected to work well when multiple threads are reading.
- */
-bool Message::read(Pipe* pPipe, bool wait)
-{
-    if (pPipe == NULL)
-        return false;
-    assert(pPipe->isCreated());
-
-    if (!wait) {
-        if (!pPipe->readReady())
-            return false;
-    }
-
-    reset();
-
-    unsigned char header[4];
-    if (pPipe->read(header, 4) != 4)
-        return false;
-
-    mType = (MessageType) header[2];
-    mLength = header[0] | header[1] << 8;
-    mLength -= 2;   // we already read two of them in the header
-
-    if (mLength > 0) {
-        int actual;
-
-        mData = new unsigned char[mLength];
-        if (mData == NULL) {
-            LOG(LOG_ERROR, "", "alloc failed\n");
-            return false;
-        }
-        mCleanup = kCleanupDelete;
-
-        actual = pPipe->read(mData, mLength);
-        if (actual != mLength) {
-            LOG(LOG_WARN, "", "failed reading message body (%d of %d bytes)\n",
-                actual, mLength);
-            return false;
-        }
-    }
-
-    return true;
-}
-
-/*
- * Write this event to a pipe.
- *
- * It would be easiest to write the header and message body with two
- * separate calls, but that will occasionally fail on multithreaded
- * systems when the writes are interleaved.  We have to allocate a
- * temporary buffer, copy the data, and write it all at once.  This
- * would be easier with writev(), but we can't rely on having that.
- *
- * DO NOT call LOG() from here, as we could be in the process of sending
- * a log message.
- */
-bool Message::write(Pipe* pPipe) const
-{
-    char tmpBuf[128];
-    char* writeBuf = tmpBuf;
-    bool result = false;
-    int kHeaderLen = 4;
-
-    if (pPipe == NULL)
-        return false;
-    assert(pPipe->isCreated());
-
-    if (mData == NULL || mLength < 0)
-        return false;
-
-    /* if it doesn't fit in stack buffer, allocate space */
-    if (mLength + kHeaderLen > (int) sizeof(tmpBuf)) {
-        writeBuf = new char[mLength + kHeaderLen];
-        if (writeBuf == NULL)
-            goto bail;
-    }
-
-    /*
-     * The current value of "mLength" does not include the 4-byte header.
-     * Two of the 4 header bytes are included in the length we output
-     * (the type byte and the pad byte), so we adjust mLength.
-     */
-    writeBuf[0] = (unsigned char) (mLength + kHeaderLen -2);
-    writeBuf[1] = (unsigned char) ((mLength + kHeaderLen -2) >> 8);
-    writeBuf[2] = (unsigned char) mType;
-    writeBuf[3] = 0;
-    if (mLength > 0)
-        memcpy(writeBuf + kHeaderLen, mData, mLength);
-
-    int actual;
-
-    actual = pPipe->write(writeBuf, mLength + kHeaderLen);
-    if (actual != mLength + kHeaderLen) {
-        fprintf(stderr,
-            "Message::write failed writing message body (%d of %d bytes)\n",
-            actual, mLength + kHeaderLen);
-        goto bail;
-    }
-
-    result = true;
-
-bail:
-    if (writeBuf != tmpBuf)
-        delete[] writeBuf;
-    return result;
-}
-
-
-/*
- * ===========================================================================
- *      MessageStream
- * ===========================================================================
- */
-
-/*
- * Get ready to go.
- */
-bool MessageStream::init(Pipe* readPipe, Pipe* writePipe, bool initiateHello)
-{
-    assert(mReadPipe == NULL && mWritePipe == NULL);    // only once
-
-    /*
-     * Swap "hello" messages.
-     *
-     * In a more robust implementation, this would include version numbers
-     * and capability flags.
-     */
-    if (initiateHello) {
-        long data = kHelloMsg;
-        Message msg;
-
-        /* send hello */
-        msg.setRaw((unsigned char*) &data, sizeof(data),
-            Message::kCleanupNoDelete);
-        if (!msg.write(writePipe)) {
-            LOG(LOG_WARN, "", "hello write failed in stream init\n");
-            return false;
-        }
-
-        LOG(LOG_DEBUG, "", "waiting for peer to ack my hello\n");
-
-        /* wait for the ack */
-        if (!msg.read(readPipe, true)) {
-            LOG(LOG_WARN, "", "hello ack read failed in stream init\n");
-            return false;
-        }
-
-        const long* pAck;
-        pAck = (const long*) msg.getData();
-        if (pAck == NULL || *pAck != kHelloAckMsg) {
-            LOG(LOG_WARN, "", "hello ack was bad\n");
-            return false;
-        }
-    } else {
-        long data = kHelloAckMsg;
-        Message msg;
-
-        LOG(LOG_DEBUG, "", "waiting for hello from peer\n");
-
-        /* wait for the hello */
-        if (!msg.read(readPipe, true)) {
-            LOG(LOG_WARN, "", "hello read failed in stream init\n");
-            return false;
-        }
-
-        const long* pAck;
-        pAck = (const long*) msg.getData();
-        if (pAck == NULL || *pAck != kHelloMsg) {
-            LOG(LOG_WARN, "", "hello was bad\n");
-            return false;
-        }
-
-        /* send hello ack */
-        msg.setRaw((unsigned char*) &data, sizeof(data),
-            Message::kCleanupNoDelete);
-        if (!msg.write(writePipe)) {
-            LOG(LOG_WARN, "", "hello ack write failed in stream init\n");
-            return false;
-        }
-    }
-
-    /* success, set up our local stuff */
-    mReadPipe = readPipe;
-    mWritePipe = writePipe;
-
-    //LOG(LOG_DEBUG, "", "init success\n");
-
-    return true;
-}
-
diff --git a/simulator/app/MessageStream.h b/simulator/app/MessageStream.h
deleted file mode 100644
index de9c398..0000000
--- a/simulator/app/MessageStream.h
+++ /dev/null
@@ -1,190 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// High-level message stream that sits on top of a pair of Pipes.  Useful
-// for inter-process communication, e.g. between "simulator" and "runtime".
-//
-// All messages are sent in packets:
-//  +00 16-bit length (of everything that follows), little-endian
-//  +02 8-bit message type
-//  +03 (reserved, must be zero)
-//  +04 message body
-//
-#ifndef _LIBS_UTILS_MESSAGE_STREAM_H
-#define _LIBS_UTILS_MESSAGE_STREAM_H
-
-#ifdef HAVE_ANDROID_OS
-#error DO NOT USE THIS FILE IN THE DEVICE BUILD
-#endif
-
-#include <utils/Pipe.h>
-#include <stdlib.h>
-#include <cutils/uio.h>
-
-// Defined in LogBundle.h.
-struct android_LogBundle;
-
-namespace android {
-
-/*
- * A single message, which can be filled out and sent, or filled with
- * received data.
- *
- * Message objects are reusable.
- */
-class Message {
-public:
-    Message(void)
-        : mCleanup(kCleanupUnknown)
-        { reset(); }
-    ~Message(void) { reset(); }
-
-    /* values for message type byte */
-    typedef enum MessageType {
-        kTypeUnknown = 0,
-        kTypeRaw,           // chunk of raw data
-        kTypeConfig,        // send a name=value pair to peer
-        kTypeCommand,       // simple command w/arg
-        kTypeCommandExt,    // slightly more complicated command
-        kTypeLogBundle,     // multi-part log message
-    } MessageType;
-
-    /* what to do with data when we're done */
-    typedef enum Cleanup {
-        kCleanupUnknown = 0,
-        kCleanupNoDelete,   // do not delete data when object destroyed
-        kCleanupDelete,     // delete with "delete[]"
-    } Cleanup;
-
-    /*
-     * Stuff raw data into the object.  The caller can use the "cleanup"
-     * parameter to decide whether or not the Message object owns the data.
-     */
-    void setRaw(const unsigned char* data, int len, Cleanup cleanup);
-
-    /*
-     * Send a "name=value" pair.
-     */
-    void setConfig(const char* name, const char* value);
-
-    /*
-     * Send a command/arg pair.
-     */
-    void setCommand(int cmd, int arg);
-    void setCommandExt(int cmd, int arg0, int arg1, int arg2);
-
-    /*
-     * Send a multi-part log message.
-     */
-    void setLogBundle(const android_LogBundle* pBundle);
-
-    /*
-     * Simple accessors.
-     */
-    MessageType getType(void) const { return mType; }
-    const unsigned char* getData(void) const { return mData; }
-    int getLength(void) const { return mLength; }
-
-    /*
-     * Not-so-simple accessors.  These coerce the raw data into an object.
-     *
-     * The data returned by these may not outlive the Message, so make
-     * copies if you plan to use them long-term.
-     */
-    bool getConfig(const char** pName, const char** pValue);
-    bool getCommand(int* pCmd, int* pArg);
-    bool getLogBundle(android_LogBundle* pBundle);
-
-    /*
-     * Read or write this message on the specified pipe.
-     *
-     * If "wait" is true, read() blocks until a message arrives.  Only
-     * one thread should be reading at a time.
-     */
-    bool read(Pipe* pPipe, bool wait);
-    bool write(Pipe* pPipe) const;
-
-private:
-    Message& operator=(const Message&);     // not defined
-    Message(const Message&);                // not defined
-
-    void reset(void) {
-        if (mCleanup == kCleanupDelete)
-            delete[] mData;
-
-        mType = kTypeUnknown;
-        mCleanup = kCleanupNoDelete;
-        mData = NULL;
-        mLength = -1;
-    }
-
-    MessageType     mType;
-    Cleanup         mCleanup;
-    unsigned char*  mData;
-    int             mLength;
-    struct iovec    mVec;
-};
-
-
-/*
- * Abstraction of higher-level communication channel.
- *
- * This may be used from multiple threads simultaneously.  Blocking on
- * the read pipe from multiple threads will have unpredictable behavior.
- *
- * Does not take ownership of the pipes passed in to init().
- */
-class MessageStream {
-public:
-    MessageStream(void)
-        : mReadPipe(NULL), mWritePipe(NULL)
-        {}
-    ~MessageStream(void) {}
-
-    /*
-     * Initialize object and exchange greetings.  "initateHello" determines
-     * whether we send "Hello" or block waiting for it to arrive.  Usually
-     * the "parent" initiates.
-     */
-    bool init(Pipe* readPipe, Pipe* writePipe, bool initiateHello);
-
-    bool isReady(void) const { return mReadPipe != NULL && mWritePipe != NULL; }
-
-    /*
-     * Send a message immediately.
-     */
-    bool send(const Message* pMsg) { return pMsg->write(mWritePipe); }
-
-    /*
-     * Receive a message.
-     */
-    bool recv(Message* pMsg, bool wait) { return pMsg->read(mReadPipe, wait); }
-
-    /*
-     * Close communication pipes.  Further attempts to send or receive
-     * will fail.  Note this doesn't actually "close" the pipes, because
-     * we don't own them.
-     */
-    void close(void) { mReadPipe = mWritePipe = NULL; }
-
-    /*
-     * Get our incoming traffic pipe.  This is useful on Linux systems
-     * because it allows access to the file descriptor which can be used
-     * in a select() call.
-     */
-    Pipe* getReadPipe(void) { return mReadPipe; }
-
-private:
-    enum {
-        kHelloMsg       = 0x4e303047,       // 'N00G'
-        kHelloAckMsg    = 0x31455221,       // '1ER!'
-    };
-
-    /* communication pipes; note we don't own these */
-    Pipe*   mReadPipe;
-    Pipe*   mWritePipe;
-};
-
-}; // namespace android
-
-#endif // _LIBS_UTILS_MESSAGE_STREAM_H
diff --git a/simulator/app/MyApp.cpp b/simulator/app/MyApp.cpp
deleted file mode 100644
index 313e44d..0000000
--- a/simulator/app/MyApp.cpp
+++ /dev/null
@@ -1,547 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Application entry point.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-#include "wx/fs_zip.h"
-
-#include "MainFrame.h"
-#include "MyApp.h"
-#include <utils/executablepath.h>
-
-#include <stdio.h>
-#include <unistd.h>
-#include <getopt.h>
-#include <signal.h>
-
-#if defined(HAVE_WINDOWS_PATHS)
-# include <windows.h>
-#endif
-
-
-/* the name of our config file */
-static wxString kConfigFileName = wxT(".android.cf");
-
-#ifdef HAVE_WINDOWS_PATHS
-static wxString kExeSuffix = wxT(".exe");
-#else
-static wxString kExeSuffix = wxT("");
-#endif
-
-/* do we want to kill the runtime? */
-bool gWantToKill = false;
-
-/*
- * Signal handler for Ctrl-C.  Under Linux we seem to get hit twice,
- * possibly once for each thread.
- *
- * Avoid using LOG here -- it's not reentrant.  Actually, just avoid doing
- * anything here.
- *
- * Cygwin will ignore the signal but doesn't seem to call the signal
- * handler.  MinGW just kills the process.
- */
-static void SignalHandler(int sigNum)
-{
-    printf("Sim: received signal %d (%s)\n", sigNum,
-        sigNum == SIGINT ? "SIGINT" : "???");
-    gWantToKill = true;
-}
-
-
-/* wxWidgets magic; creates appropriate main entry function */
-IMPLEMENT_APP(MyApp)
-
-/*
- * Application entry point.
- */
-bool MyApp::OnInit()
-{
-    static wxString helpFilePath = wxT("simulator/help/unnamed.htb");
-
-    /*
-     * Parse args.
-     */
-
-    SetDefaults();
-    
-    char** cargv = (char**)malloc(argc * sizeof(char*));
-    for (int i=0; i<argc; i++) {
-	wxCharBuffer tmp = wxString(argv[i]).ToAscii();
-        cargv[i] = tmp.release();
-    }
-    if (!ParseArgs(argc, cargv)) {
-	for (int i=0; i<argc; i++)
-	    free(cargv[i]);
-	free(cargv);
-        return FALSE;
-    }
-    for (int i=0; i<argc; i++)
-        free(cargv[i]);
-    free(cargv);
-    
-    if (!ProcessConfigFile())
-        return FALSE;
-
-    /*
-     * (Try to) catch SIGINT (Ctrl-C).
-     */
-    bool trapInt = false;
-    mPrefs.GetBool("trap-sigint", &trapInt);
-    if (trapInt) {
-        printf("Sim: catching SIGINT\n");
-        signal(SIGINT, SignalHandler);
-    }
-
-    signal(SIGPIPE, SIG_IGN);
-
-    /*
-     * Set stdout to unbuffered.  This is needed for MinGW/MSYS.
-     * Set stderr while we're at it.
-     */
-    setvbuf(stdout, NULL, _IONBF, 0);
-    setvbuf(stderr, NULL, _IONBF, 0);
-
-    /*
-     * Initialize asset manager.
-     */
-    mpAssetManager = NULL;
-    printf("Sim: looking in '%s' for my assets\n", (const char*) mSimAssetPath.ToAscii());
-    ChangeAssetDirectory(mSimAssetPath);
-
-    /*
-     * Add JPEG and PNG image handlers.
-     */
-    ::wxInitAllImageHandlers();
-
-    /*
-     * Set up the help file browser.  We're using wxHtmlHelpController
-     * because it seems to be the only "portable" version other than
-     * the "use external browser" version.
-     */
-    wxFileSystem::AddHandler(new wxZipFSHandler);
-    mHelpController = new wxHtmlHelpController;
-
-    wxString helpFileName;
-    helpFileName = mSimAssetPath;
-    helpFileName += '/';
-    helpFileName += helpFilePath;
-    mHelpController->Initialize(helpFileName);
-
-    /*
-     * Create the main window, which just holds some of our UI.
-     */
-    wxPoint pos(wxDefaultPosition);
-    mPrefs.GetInt("window-main-x", &pos.x);
-    mPrefs.GetInt("window-main-y", &pos.y);
-    mpMainFrame = new MainFrame(wxT("Android Simulator"), pos, wxDefaultSize,
-        wxDEFAULT_FRAME_STYLE);
-    mpMainFrame->Show(TRUE);
-    SetTopWindow(mpMainFrame);
-
-    return TRUE;
-}
-
-/*
- * Change our asset directory.  This requires deleting the existing
- * AssetManager and creating a new one.  Note that any open Assets will
- * still be valid.
- */
-void MyApp::ChangeAssetDirectory(const wxString& dir)
-{
-    delete mpAssetManager;
-    mpAssetManager = new android::AssetManager;
-    android::String8 path(dir.ToAscii());
-    path.appendPath("simulator.zip");
-    mpAssetManager->addAssetPath(path, NULL);
-    // mpAssetManager->setLocale(xxx);
-    mpAssetManager->setVendor("google");
-}
-
-
-/*
- * App is shutting down.  Save the config file.
- */
-int MyApp::OnExit(void)
-{
-    if (mPrefs.GetDirty()) {
-        printf("Sim: writing config file to '%s'\n",
-            (const char*) mConfigFile.ToAscii());
-        if (!mPrefs.Save(mConfigFile.ToAscii())) {
-            fprintf(stderr, "Sim: ERROR: prefs save to '%s' failed\n",
-                (const char*) mConfigFile.ToAscii());
-        }
-    }
-
-    return 0;
-}
-
-static ssize_t
-find_last_slash(const wxString& s)
-{
-    int slash = s.Last('/');
-    if (slash < 0) {
-        slash = s.Last('\\');
-    }
-    return slash;
-}
-
-
-/*
- * Set some default parameters
- */
-void MyApp::SetDefaults()
-{
-    mDebuggerOption = false;
-
-    /* Get the path to this executable, which should
-     * end in something like "/host/linux-x86/bin/simulator".
-     * (The full path may begin with something like "out"
-     * or "out/debug".)
-     */
-    char exepath[PATH_MAX];
-    executablepath(exepath);
-    wxString out = wxString::FromAscii(exepath);
-
-    /* Get the path to the root host directory;  e.g., "out/host".
-     * We can do this by removing the last three slashes
-     * and everything after/between them ("/linux-x86/bin/simulator").
-     */
-    for (int i = 0; i < 3; i++) {
-        int slash = find_last_slash(out);
-        assert(slash >= 0);
-        out.Truncate(slash);
-    }
-
-    /* Get the location of the assets directory; something like
-     * "out/host/common/sim-assets"
-     */
-    mSimAssetPath = out;
-    mSimAssetPath.Append(wxT("/common/sim-assets"));
-
-    /* Get the location of the simulated device filesystem.
-     * We can't reliably predict this based on the executable
-     * location, so try to get it from the environment.
-     */
-    char *envOut = getenv("ANDROID_PRODUCT_OUT");
-    if (envOut == NULL) {
-        fprintf(stderr,
-                "WARNING: $ANDROID_PRODUCT_OUT not set in environment\n");
-        envOut = "";
-    }
-
-    // the root of the android stuff
-    mAndroidRoot = wxString::FromAscii(envOut);
-    mAndroidRoot.Append(wxT("/system"));
-    
-    // where runtime is
-    mRuntimeExe = mAndroidRoot;
-    mRuntimeExe.Append(wxT("/bin/runtime"));
-    mRuntimeExe.Append(kExeSuffix);
-    
-    printf("mAndroidRoot='%s'\n", (const char*) mAndroidRoot.ToAscii());
-    printf("mSimAssetPath='%s'\n", (const char*) mSimAssetPath.ToAscii());
-}
-
-
-/*
- * Parse command-line arguments.
- *
- * Returns "false" if we have a parsing error.
- */
-bool MyApp::ParseArgs(int argc, char** argv)
-{
-    int ic;
-
-    opterr = 0;     // don't complain about unrecognized options
-
-    if (false) {
-        printf("MyApp args:\n");
-        for (int i = 0; i < argc; i++)
-            printf("  %2d: '%s'\n", i, (const char*) argv[i]);
-    }
-
-    while (1) {
-        ic = getopt(argc, argv, "tj:da:f:rx:");
-        if (ic < 0)
-            break;
-
-        switch (ic) {
-        case 'j':
-            mAutoRunApp = wxString::FromAscii(optarg);
-            break;
-        case 't':
-            mAutoRunApp = wxT("com.android.testharness.RunAll");
-            break;
-        case 'd':
-            mDebuggerOption = true;
-            break;
-        case 'x':
-            mDebuggerScript = wxString::FromAscii(optarg);
-            mDebuggerOption = true;     // force debug if a script is being used
-            break;
-        case 'a':       // simulator asset dir
-            mSimAssetPath = wxString::FromAscii(optarg);
-            break;
-        case 'f':       // simulator config file
-            mConfigFile = wxString::FromAscii(optarg);
-            break;
-        case 'r':       // reset path-based options to defaults
-            mResetPaths = true;
-            break;
-        default:
-            fprintf(stderr, "WARNING: unknown sim option '%c'\n", ic);
-            break;
-        }
-    }
-
-    return true;
-}
-
-
-/*
- * Convert a path to absolute form, if needed.
- *
- * String manipulation would be more efficient than system calls, but
- * less reliable.
- *
- * We need to use GetCurrentDirectory() under Windows because, under
- * Cygwin, some wxWidgets features require "C:" paths rather than
- * local-rooted paths.  Probably needed for stand-alone MinGW too.
- */
-void MyApp::AbsifyPath(wxString& dir)
-{
-    char oldDir[512], newDir[512];
-    wxString newDirStr;
-
-    // We still need to do this under Cygwin even if the path is
-    // already absolute.
-    //if (dir[0] == '/' || dir[0] == '\\')
-    //    return;
-
-    if (getcwd(oldDir, sizeof(oldDir)) == NULL) {
-        fprintf(stderr, "getcwd() failed\n");
-        return;
-    }
-
-    if (chdir(dir.ToAscii()) == 0) {
-#if defined(HAVE_WINDOWS_PATHS)
-        DWORD dwRet;
-        dwRet = GetCurrentDirectory(sizeof(newDir), newDir);
-        if (dwRet == 0 || dwRet > sizeof(newDir))
-            sprintf(newDir, "GET_DIR_FAILED %lu", dwRet);
-#else
-        if (getcwd(newDir, sizeof(newDir)) == NULL)
-            strcpy(newDir, "GET_DIR_FAILED");
-#endif
-        newDirStr = wxString::FromAscii(newDir);
-        chdir(oldDir);
-    } else {
-        fprintf(stderr, "WARNING: unable to chdir to '%s' from '%s'\n",
-            (const char*) dir.ToAscii(), oldDir);
-        newDirStr = dir;
-    }
-
-    //dir = "c:/dev/cygwin";
-    //dir += newDirStr;
-    dir = newDirStr;
-}
-
-
-/*
- * Load and process our configuration file.
- */
-bool MyApp::ProcessConfigFile(void)
-{
-    wxString homeConfig;
-    bool configLoaded = false;
-
-    if (getenv("HOME") != NULL) {
-        homeConfig = wxString::FromAscii(getenv("HOME"));
-        homeConfig += '/';
-        homeConfig += kConfigFileName;
-    } else {
-        homeConfig = wxT("./");
-        homeConfig += kConfigFileName;
-    }
-
-    /*
-     * Part 1: read the config file.
-     */
-
-    if (mConfigFile.Length() > 0) {
-        /*
-         * Read from specified config file.  We absolutify the path
-         * first so that we're guaranteed to be hitting the same file
-         * even if the cwd changes.
-         */
-        if (access(mConfigFile.ToAscii(), R_OK) != 0) {
-            fprintf(stderr, "ERROR: unable to open '%s'\n",
-                (const char*) mConfigFile.ToAscii());
-            return false;
-        }
-        if (!mPrefs.Load(mConfigFile.ToAscii())) {
-            fprintf(stderr, "Failed loading config file '%s'\n",
-                (const char*) mConfigFile.ToAscii());
-            return false;
-        } else {
-            configLoaded = true;
-        }
-    } else {
-        /*
-         * Try ./android.cf, then $HOME/android.cf.  If we find one and
-         * read it successfully, save the name in mConfigFile.
-         */
-        {
-            wxString fileName;
-
-            fileName = wxT(".");
-            AbsifyPath(fileName);
-            fileName += wxT("/");
-            fileName += kConfigFileName;
-
-            if (access(fileName.ToAscii(), R_OK) == 0) {
-                if (mPrefs.Load(fileName.ToAscii())) {
-                    mConfigFile = fileName;
-                    configLoaded = true;
-                } else {
-                    /* damaged config files are always fatal */
-                    fprintf(stderr, "Failed loading config file '%s'\n",
-                        (const char*) fileName.ToAscii());
-                    return false;
-                }
-            }
-        }
-        if (!configLoaded) {
-            if (homeConfig.Length() > 0) {
-                if (access(homeConfig.ToAscii(), R_OK) == 0) {
-                    if (mPrefs.Load(homeConfig.ToAscii())) {
-                        mConfigFile = homeConfig;
-                        configLoaded = true;
-                    } else {
-                        /* damaged config files are always fatal */
-                        fprintf(stderr, "Failed loading config file '%s'\n",
-                            (const char*) homeConfig.ToAscii());
-                        return false;
-                    }
-                }
-            }
-        }
-
-    }
-
-    /* if we couldn't find one to load, create a new one in $HOME */
-    if (!configLoaded) {
-        mConfigFile = homeConfig;
-        if (!mPrefs.Create()) {
-            fprintf(stderr, "prefs creation failed\n");
-            return false;
-        }
-    }
-
-    /*
-     * Part 2: reset some entries if requested.
-     *
-     * If you want to reset local items (like paths to binaries) without
-     * disrupting other options, specifying the "reset" flag will cause
-     * some entries to be removed, and new defaults generated below.
-     */
-
-    if (mResetPaths) {
-        if (mPrefs.RemovePref("debugger"))
-            printf("  removed pref 'debugger'\n");
-        if (mPrefs.RemovePref("valgrinder"))
-            printf("  removed pref 'valgrinder'\n");
-    }
-
-    /*
-     * Find GDB.
-     */
-    if (!mPrefs.Exists("debugger")) {
-        static wxString paths[] = {
-            wxT("/bin"), wxT("/usr/bin"), wxString()
-        };
-        wxString gdbPath;
-
-        FindExe(wxT("gdb"), paths, wxT("/usr/bin/gdb"), &gdbPath);
-        mPrefs.SetString("debugger", gdbPath.ToAscii());
-    }
-
-
-    /*
-     * Find Valgrind.  It currently only exists in Linux, and is installed
-     * in /usr/bin/valgrind by default on our systems.  The default version
-     * is old and sometimes fails, so look for a newer version.
-     */
-    if (!mPrefs.Exists("valgrinder")) {
-        static wxString paths[] = {
-            wxT("/home/fadden/local/bin"), wxT("/usr/bin"), wxString()
-        };
-        wxString valgrindPath;
-
-        FindExe(wxT("valgrind"), paths, wxT("/usr/bin/valgrind"), &valgrindPath);
-        mPrefs.SetString("valgrinder", valgrindPath.ToAscii());
-    }
-
-    /*
-     * Set misc options.
-     */
-    if (!mPrefs.Exists("auto-power-on"))
-        mPrefs.SetBool("auto-power-on", true);
-    if (!mPrefs.Exists("gamma"))
-        mPrefs.SetDouble("gamma", 1.0);
-
-    if (mPrefs.GetDirty()) {
-        printf("Sim: writing config file to '%s'\n",
-            (const char*) mConfigFile.ToAscii());
-        if (!mPrefs.Save(mConfigFile.ToAscii())) {
-            fprintf(stderr, "Sim: ERROR: prefs save to '%s' failed\n",
-                (const char*) mConfigFile.ToAscii());
-        }
-    }
-
-    return true;
-}
-
-/*
- * Find an executable by searching in several places.
- */
-/*static*/ void MyApp::FindExe(const wxString& exeName, const wxString paths[],
-    const wxString& defaultPath, wxString* pOut)
-{
-    wxString exePath;
-    wxString slashExe;
-
-    slashExe = wxT("/");
-    slashExe += exeName;
-    slashExe += kExeSuffix;
-
-    while (!(*paths).IsNull()) {
-        wxString tmp;
-
-        tmp = *paths;
-        tmp += slashExe;
-        if (access(tmp.ToAscii(), X_OK) == 0) {
-            printf("Sim: Found '%s' in '%s'\n", (const char*) exeName.ToAscii(), 
-                    (const char*) tmp.ToAscii());
-            *pOut = tmp;
-            return;
-        }
-
-        paths++;
-    }
-
-    printf("Sim: Couldn't find '%s', defaulting to '%s'\n",
-        (const char*) exeName.ToAscii(), (const char*) defaultPath.ToAscii());
-    *pOut = defaultPath;
-}
-
diff --git a/simulator/app/MyApp.h b/simulator/app/MyApp.h
deleted file mode 100644
index d18368d..0000000
--- a/simulator/app/MyApp.h
+++ /dev/null
@@ -1,93 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Application class.
-//
-#ifndef _SIM_APPMAIN_H
-#define _SIM_APPMAIN_H
-
-#include "wx/help.h"
-#include "wx/html/helpctrl.h"
-
-#include "MainFrame.h"
-#include "DeviceManager.h"
-#include "Preferences.h"
-
-#include <utils/AssetManager.h>
-
-/* flag set from signal handler */
-extern bool gWantToKill;
-
-/*
- * Class representing the application.
- */
-class MyApp : public wxApp {
-public:
-    MyApp(void)
-        : mHelpController(NULL), mpMainFrame(NULL), mpAssetManager(NULL),
-          mResetPaths(false)        // configurable; reset prefs with paths
-        {}
-    ~MyApp(void) 
-    { 
-        delete mpAssetManager;
-        delete mHelpController; 
-    }
-
-    virtual bool OnInit(void);
-    virtual int OnExit(void);
-
-    wxHtmlHelpController* GetHelpController(void) const {
-        return mHelpController;
-    }
-
-    Preferences* GetPrefs(void)                 { return &mPrefs; }
-
-    /* return a pointer to the main window */
-    wxWindow* GetMainFrame(void) { return mpMainFrame; }
-
-    /* get a pointer to our Asset Manager */
-    android::AssetManager* GetAssetManager(void) { return mpAssetManager; }
-
-    /* change the asset dir; requires re-creating Asset Manager */
-    void ChangeAssetDirectory(const wxString& dir);
-
-    const wxString& GetConfigFileName(void) const { return mConfigFile; }
-
-    wxString GetSimAssetPath()                  { return mSimAssetPath; }
-    wxString GetAndroidRoot()                   { return mAndroidRoot; }
-    wxString GetRuntimeExe()                    { return mRuntimeExe; }
-    bool GetDebuggerOption()                    { return mDebuggerOption; }
-    wxString GetDebuggerScript()                { return mDebuggerScript; }
-    wxString GetAutoRunApp()                    { return mAutoRunApp; }
-
-    void Vibrate(int vibrateOn)                 { ((MainFrame*)mpMainFrame)->Vibrate(vibrateOn); }
-
-private:
-    void SetDefaults();
-    bool ParseArgs(int argc, char** argv);
-    void AbsifyPath(wxString& dir);
-    bool ProcessConfigFile(void);
-    static void FindExe(const wxString& exeName, const wxString paths[],
-        const wxString& defaultPath, wxString* pOut);
-
-    wxHtmlHelpController*   mHelpController;
-
-    wxWindow*       mpMainFrame;
-
-    android::AssetManager*  mpAssetManager;
-
-    wxString        mAndroidRoot;
-    wxString        mSimAssetPath;
-    wxString        mRuntimeExe;
-
-    /* command-line options */
-    wxString        mConfigFile;
-    bool            mResetPaths;
-    bool            mDebuggerOption;
-	wxString		mDebuggerScript;
-    wxString        mAutoRunApp;
-
-    Preferences     mPrefs;
-};
-
-#endif // _SIM_APPMAIN_H
diff --git a/simulator/app/PhoneButton.cpp b/simulator/app/PhoneButton.cpp
deleted file mode 100644
index eca7ddc..0000000
--- a/simulator/app/PhoneButton.cpp
+++ /dev/null
@@ -1,180 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Simulated device data.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-
-#include "LinuxKeys.h"
-#include "PhoneButton.h"
-
-using namespace android;
-
-
-/*
- * Create a PhoneButton without a backing image.
- */
-bool PhoneButton::Create(const char* label)
-{
-    assert(!mHasImage);     // quick check for re-use
-
-    mKeyCode = LookupKeyCode(label);
-    if (mKeyCode == kKeyCodeUnknown) {
-        fprintf(stderr, "WARNING: key code '%s' not recognized\n", label);
-        // keep going
-    }
-
-    return true;
-}
-
-/*
- * Create a PhoneButton with an associated image.  Don't load the image yet.
- */
-bool PhoneButton::Create(const char* label, const char* imageFileName,
-    int x, int y)
-{
-    if (!Create(label))
-        return false;
-
-    if (mSelectedImage.Create(imageFileName, x, y))
-        mHasImage = true;
-    else
-        fprintf(stderr, "Warning: image create (%s, %d, %d) failed\n",
-            imageFileName, x, y);
-
-    return true;
-}
-
-/*
- * Load the image, if any.
- */
-bool PhoneButton::LoadResources(void)
-{
-    if (!mHasImage)
-        return true;        // no image associated with this button
-
-    bool result = mSelectedImage.LoadResources();
-    if (result)
-        CreateHighlightedBitmap();
-    return result;
-}
-
-/*
- * Unload the image if we loaded one.
- */
-bool PhoneButton::UnloadResources(void)
-{
-    if (!mHasImage)
-        return true;
-
-    return mSelectedImage.UnloadResources();
-}
-
-/* use an inline instead of macro so we don't evaluate args multiple times */
-static inline int MinVal(int a, int b) { return (a < b ? a : b); }
-
-/*
- * Create the "highlighted" bitmap from the "selected" image.
- */
-void PhoneButton::CreateHighlightedBitmap(void)
-{
-    wxBitmap* src = mSelectedImage.GetBitmap();
-    assert(src != NULL);
-    wxImage tmpImage = src->ConvertToImage();
-
-    unsigned char* pRGB = tmpImage.GetData();       // top-left RGBRGB...
-    int x, y;
-
-    /*
-     * Modify the color used for the "highlight" image.
-     */
-    for (y = tmpImage.GetHeight()-1; y >= 0; --y) {
-        for (x = tmpImage.GetWidth()-1; x >= 0; --x) {
-            *(pRGB)   = MinVal(*(pRGB)   + *(pRGB) / 8, 255);
-            *(pRGB+1) = MinVal(*(pRGB+1) + *(pRGB+1) / 8, 255);
-            *(pRGB+2) = *(pRGB+2) * 5 / 8;
-
-            pRGB += 3;
-        }
-    }
-
-    mHighlightedBitmap = wxBitmap(tmpImage);
-}
-
-/*
- * Check to see if the button "collides" with the specified point.
- *
- * This is currently a simple rectangle check, but could be modified
- * to take image transparency into account.
- */
-bool PhoneButton::CheckCollision(int x, int y) const
-{
-    if (!mHasImage)
-        return false;
-
-    return (x >= mSelectedImage.GetX() &&
-            x < mSelectedImage.GetX() + mSelectedImage.GetWidth() &&
-            y >= mSelectedImage.GetY() &&
-            y < mSelectedImage.GetY() + mSelectedImage.GetHeight());
-}
-
-/*
- * Look up a key code based on a string.
- *
- * Returns kKeyCodeUnknown if the label doesn't match anything.
- */
-KeyCode PhoneButton::LookupKeyCode(const char* label) const
-{
-    static const struct {
-        const char* label;
-        int keyCode;
-    } codeList[] = {
-        { "soft-left",      KEY_MENU },
-        { "soft-right",     KEY_KBDILLUMUP },
-        { "home",           KEY_HOME },
-        { "back",           KEY_BACK },
-        { "call",           KEY_F3 },
-        { "phone-dial",     KEY_F3 },
-        { "end-call",       KEY_F4 },
-        { "phone-hangup",   KEY_F4 },
-        { "0",              KEY_0 },
-        { "1",              KEY_1 },
-        { "2",              KEY_2 },
-        { "3",              KEY_3 },
-        { "4",              KEY_4 },
-        { "5",              KEY_5 },
-        { "6",              KEY_6 },
-        { "7",              KEY_7 },
-        { "8",              KEY_8 },
-        { "9",              KEY_9 },
-        { "star",           KEY_SWITCHVIDEOMODE },
-        { "pound",          KEY_KBDILLUMTOGGLE },
-        { "dpad-up",        KEY_UP },
-        { "dpad-down",      KEY_DOWN },
-        { "dpad-left",      KEY_LEFT },
-        { "dpad-right",     KEY_RIGHT },
-        { "dpad-center",    KEY_REPLY },
-        { "volume-up",      KEY_VOLUMEUP },
-        { "volume-down",    KEY_VOLUMEDOWN },
-        { "power",          KEY_POWER },
-        { "camera",         KEY_CAMERA },
-        //{ "clear",          kKeyCodeClear },
-    };
-    const int numCodes = sizeof(codeList) / sizeof(codeList[0]);
-
-    for (int i = 0; i < numCodes; i++) {
-        if (strcmp(label, codeList[i].label) == 0)
-            return (KeyCode) codeList[i].keyCode;
-    }
-
-    return kKeyCodeUnknown;
-};
-
diff --git a/simulator/app/PhoneButton.h b/simulator/app/PhoneButton.h
deleted file mode 100644
index 4bbaf56..0000000
--- a/simulator/app/PhoneButton.h
+++ /dev/null
@@ -1,80 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Phone button image holder.
-//
-#ifndef _SIM_PHONE_BUTTON_H
-#define _SIM_PHONE_BUTTON_H
-
-#include "LoadableImage.h"
-#include <ui/KeycodeLabels.h>
-
-/*
- * One button on a phone.  Position, size, and a highlight graphic.  The
- * coordinates are relative to the device graphic.
- *
- * We now have a "highlighted" graphic for mouse-overs and a "selected"
- * graphic for button presses.  We assume they have the same dimensions.
- * We currently assume that either both or neither exist, because we
- * generate one from the other.
- */
-class PhoneButton {
-public:
-    PhoneButton(void)
-        : mHasImage(false), mKeyCode(kKeyCodeUnknown)
-        {}
-    virtual ~PhoneButton(void) {}
-    PhoneButton(const PhoneButton& src)
-        : mHasImage(false), mKeyCode(kKeyCodeUnknown)
-    {
-        CopyMembers(src);
-    }
-    PhoneButton& operator=(const PhoneButton& src) {
-        if (this != &src) {
-            // Unload any resources in case we're using operator= to
-            // assign to an existing object.
-            mSelectedImage.UnloadResources();
-            // Copy fields.
-            CopyMembers(src);
-        }
-        return *this;
-    }
-    void CopyMembers(const PhoneButton& src) {
-        mSelectedImage = src.mSelectedImage;
-        mHighlightedBitmap = src.mHighlightedBitmap;
-        mHasImage = src.mHasImage;
-        mKeyCode = src.mKeyCode;
-    }
-
-    /* finish construction of PhoneButton, with or without an image */
-    bool Create(const char* label);
-    bool Create(const char* label, const char* imageFileName, int x, int y);
-
-    int GetX(void) const { return mSelectedImage.GetX(); }
-    int GetY(void) const { return mSelectedImage.GetY(); }
-    int GetWidth(void) const { return mSelectedImage.GetWidth(); }
-    int GetHeight(void) const { return mSelectedImage.GetHeight(); }
-    wxBitmap* GetHighlightedBitmap(void) { return &mHighlightedBitmap; }
-    wxBitmap* GetSelectedBitmap(void) const {
-        return mSelectedImage.GetBitmap();
-    }
-
-    bool CheckCollision(int x, int y) const;
-    KeyCode GetKeyCode(void) const { return mKeyCode; }
-
-    // load or unload the image bitmap, if any
-    bool LoadResources(void);
-    bool UnloadResources(void);
-
-private:
-    void CreateHighlightedBitmap(void);
-    KeyCode LookupKeyCode(const char* label) const;
-
-    LoadableImage       mSelectedImage;
-    wxBitmap            mHighlightedBitmap;
-    bool                mHasImage;          // both exist or neither exist
-
-    KeyCode    mKeyCode;
-};
-
-#endif // _SIM_PHONE_BUTTON_H
diff --git a/simulator/app/PhoneCollection.cpp b/simulator/app/PhoneCollection.cpp
deleted file mode 100644
index 5cddfa8..0000000
--- a/simulator/app/PhoneCollection.cpp
+++ /dev/null
@@ -1,174 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Our collection of devices.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-//#include "wx/image.h"   // needed for Windows build
-
-
-#include "PhoneCollection.h"
-#include "PhoneData.h"
-#include "MyApp.h"
-
-#include <utils.h>
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <stdio.h>
-#include <string.h>
-#include <sys/types.h>
-#include <dirent.h>
-#include <assert.h>
-
-using namespace android;
-
-/*static*/ PhoneCollection* PhoneCollection::mpInstance = NULL;
-
-/*static*/ const char* PhoneCollection::kLayoutFile = "layout.xml";
-
-
-/*
- * (Re-)scan the specified directory for phones.  We register a hit if we can
- * see a file called "<directory>/layout.xml".
- */
-void PhoneCollection::ScanForPhones(const char* directory)
-{
-    /*
-     * Scan through the directory and find everything that looks like it
-     * might hold phone data.
-     */
-    StringArray strArr;
-
-#ifdef BEFORE_ASSET
-    DIR* dirp;
-    struct dirent* entp;
-
-    dirp = opendir(directory);
-    if (dirp == NULL) {
-        char buf[512];
-        fprintf(stderr, "ERROR: unable to scan directory '%s' for phone data\n",
-            directory);
-        fprintf(stderr, "Current dir is %s\n", getcwd(buf, sizeof(buf)));
-        return;
-    }
-
-    while (1) {
-        wxString dirName;
-        wxString fileName;
-
-        entp = readdir(dirp);
-        if (entp == NULL)
-            break;              // done with scan
-        dirName = directory;
-        dirName += '/';
-        dirName += entp->d_name;
-        fileName = dirName;
-        fileName += '/';
-        fileName += kLayoutFile;
-
-        if (access(fileName, R_OK) == 0) {
-            strArr.push_back(dirName);
-            //printf("--- examining '%s'\n", (const char*) fileName);
-        }
-    }
-    closedir(dirp);
-#else
-    android::AssetManager* pAssetMgr = ((MyApp*)wxTheApp)->GetAssetManager();
-    android::AssetDir* pDir;
-    int i, count;
-
-    pDir = pAssetMgr->openDir("");
-    assert(pDir != NULL);
-    count = pDir->getFileCount();
-
-    for (i = 0; i < count; i++) {
-        android::String8 layoutPath;
-
-        if (pDir->getFileType(i) != kFileTypeDirectory)
-            continue;
-
-        layoutPath = pDir->getFileName(i);
-        layoutPath.appendPath(kLayoutFile);
-
-        if (pAssetMgr->getFileType(layoutPath.string()) == kFileTypeRegular) {
-            strArr.push_back(pDir->getFileName(i).string());
-            printf("--- examining '%s'\n", layoutPath.string());
-        }
-    }
-
-    delete pDir;
-#endif
-
-    if (strArr.size() == 0) {
-        fprintf(stderr, "ERROR: no phone data found in '%s'\n", directory);
-        return;
-    }
-
-    /*
-     * Found some candidates.  If they parse successfully, add them to
-     * our list.
-     *
-     * We sort them first, because it's nice when everybody's user
-     * interface looks the same.  Note we're sorting the directory name,
-     * so it's possible to define a sort order in the filesystem that
-     * doesn't require messing up the phone's title string.
-     */
-    mPhoneList.clear();
-    strArr.sort(StringArray::cmpAscendingAlpha);
-
-    for (int i = 0; i < strArr.size(); i++) {
-        PhoneData tmpPhone;
-
-        if (!tmpPhone.Create(strArr.getEntry(i))) {
-            fprintf(stderr, "Sim: Abandoning phone '%s'\n", strArr.getEntry(i));
-            //strArr.erase(i);
-            //i--;
-        } else {
-            if (GetPhoneData(tmpPhone.GetName()) != NULL) {
-                fprintf(stderr, "Sim: ERROR: duplicate name '%s' in '%s'\n",
-                    tmpPhone.GetName(), strArr.getEntry(i));
-            } else {
-                mPhoneList.push_back(tmpPhone);
-            }
-        }
-    }
-}
-
-
-/*
- * Return the Nth member of the phone data array.  (Replace w/Vector.)
- */
-PhoneData* PhoneCollection::GetPhoneData(int idx)
-{
-    typedef List<PhoneData>::iterator Iter;
-
-    for (Iter ii = mPhoneList.begin(); ii != mPhoneList.end(); ++ii) {
-        if (idx == 0)
-            return &(*ii);
-        --idx;
-    }
-    return NULL;
-}
-
-/*
- * Return the entry whose phone data name matches "name".
- */
-PhoneData* PhoneCollection::GetPhoneData(const char* name)
-{
-    typedef List<PhoneData>::iterator Iter;
-
-    for (Iter ii = mPhoneList.begin(); ii != mPhoneList.end(); ++ii) {
-        if (strcasecmp((*ii).GetName(), name) == 0)
-            return &(*ii);
-    }
-    return NULL;
-}
-
diff --git a/simulator/app/PhoneCollection.h b/simulator/app/PhoneCollection.h
deleted file mode 100644
index d16c4a0..0000000
--- a/simulator/app/PhoneCollection.h
+++ /dev/null
@@ -1,52 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Our collection of devices.
-//
-#ifndef _SIM_PHONE_COLLECTION_H
-#define _SIM_PHONE_COLLECTION_H
-
-#include <stdlib.h>
-#include "PhoneData.h"
-
-/*
- * Only one instance of this class exists.  It contains a list of all
- * known devices, and methods for scanning for devices.
- */
-class PhoneCollection {
-public:
-    /* get the global instance */
-    static PhoneCollection* GetInstance(void) {
-        if (mpInstance == NULL)
-            mpInstance = new PhoneCollection;
-        return mpInstance;
-    }
-    /* destroy the global instance when shutting down */
-    static void DestroyInstance(void) {
-        delete mpInstance;
-        mpInstance = NULL;
-    }
-
-    /* scan for phones in subdirectories of "directory" */
-    void ScanForPhones(const char* directory);
-
-    /* get phone data */
-    int GetPhoneCount(void) const { return mPhoneList.size(); } // slow
-    PhoneData* GetPhoneData(int idx);
-    PhoneData* GetPhoneData(const char* name);
-
-    /* layout.xml filename -- a string constant used in various places */
-    static const char* kLayoutFile;
-
-private:
-    PhoneCollection(void) {}
-    ~PhoneCollection(void) {}
-
-    /* the phone data; make this a Vector someday */
-    android::List<PhoneData>    mPhoneList;
-
-    /* storage for global instance pointer */
-    static PhoneCollection* mpInstance;
-};
-
-#endif // _SIM_PHONE_COLLECTION_H
diff --git a/simulator/app/PhoneData.cpp b/simulator/app/PhoneData.cpp
deleted file mode 100644
index 48614fd..0000000
--- a/simulator/app/PhoneData.cpp
+++ /dev/null
@@ -1,868 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Simulated device data.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-
-
-#include "PhoneData.h"
-#include "PhoneButton.h"
-#include "PhoneCollection.h"
-#include "MyApp.h"
-
-#include <utils.h>
-#include <utils/AssetManager.h>
-#include <utils/String8.h>
-
-#include "tinyxml.h"
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <stdio.h>
-#include <string.h>
-#include <assert.h>
-
-using namespace android;
-
-/* image relative path hack */
-static const char* kRelPathMagic = "::/";
-
-
-/*
- * ===========================================================================
- *      PhoneKeyboard
- * ===========================================================================
- */
-
-/*
- * Load a <keyboard> chunk.
- */
-bool PhoneKeyboard::ProcessAndValidate(TiXmlNode* pNode)
-{
-    //TiXmlNode* pChild;
-    TiXmlElement* pElem;
-    int qwerty = 0;
-    
-    assert(pNode->Type() == TiXmlNode::ELEMENT);
-
-    pElem = pNode->ToElement();
-    pElem->Attribute("qwerty", &qwerty);
-    const char *kmap = pElem->Attribute("keycharmap");
-
-    if (qwerty == 1) {
-        printf("############## PhoneKeyboard::ProcessAndValidate: qwerty = true!\n");
-        mQwerty = true;
-    }
-
-    if (kmap != NULL) {
-        printf("############## PhoneKeyboard::ProcessAndValidate: keycharmap = %s\n", kmap);
-        mKeyMap = strdup(kmap);
-    }
-    
-    return true;
-}
-
-
-/*
- * ===========================================================================
- *      PhoneDisplay
- * ===========================================================================
- */
-
-/*
- * Load a <display> chunk.
- */
-bool PhoneDisplay::ProcessAndValidate(TiXmlNode* pNode)
-{
-    //TiXmlNode* pChild;
-    TiXmlElement* pElem;
-    const char* name;
-    const char* format;
-
-    assert(pNode->Type() == TiXmlNode::ELEMENT);
-
-    /*
-     * Process attributes.  Right now they're all mandatory, but some of
-     * them could be defaulted (e.g. "rotate").
-     *
-     * [We should do some range-checking here.]
-     */
-    pElem = pNode->ToElement();
-    name = pElem->Attribute("name");
-    if (name == NULL)
-        goto missing;
-    if (pElem->Attribute("width", &mWidth) == NULL)
-        goto missing;
-    if (pElem->Attribute("height", &mHeight) == NULL)
-        goto missing;
-    if (pElem->Attribute("refresh", &mRefresh) == NULL)
-        goto missing;
-    format = pElem->Attribute("format");
-    if (format == NULL)
-        goto missing;
-
-    delete[] mName;
-    mName = strdupNew(name);
-
-    if (strcasecmp(format, "rgb565") == 0) {
-        mFormat = android::PIXEL_FORMAT_RGB_565;
-    } else {
-        fprintf(stderr, "SimCFG: unexpected value for display format\n");
-        return false;
-    }
-
-    return true;
-
-missing:
-    fprintf(stderr,
-        "SimCFG: <display> requires name/width/height/format/refresh\n");
-    return false;
-}
-
-
-/*
- * Returns "true" if the two displays are compatible, "false" if not.
- *
- * Compatibility means they have the same resolution, format, refresh
- * rate, and so on.  Anything transmitted to the runtime as part of the
- * initial configuration setup should be tested.
- */
-/*static*/ bool PhoneDisplay::IsCompatible(PhoneDisplay* pDisplay1,
-    PhoneDisplay* pDisplay2)
-{
-    return (pDisplay1->mWidth == pDisplay2->mWidth &&
-            pDisplay1->mHeight == pDisplay2->mHeight &&
-            pDisplay1->mFormat == pDisplay2->mFormat &&
-            pDisplay1->mRefresh == pDisplay2->mRefresh);
-}
-
-
-/*
- * ===========================================================================
- *      PhoneView
- * ===========================================================================
- */
-
-/*
- * Load a <view> chunk.
- */
-bool PhoneView::ProcessAndValidate(TiXmlNode* pNode, const char* directory)
-{
-    TiXmlNode* pChild;
-    TiXmlElement* pElem;
-    int rotate;
-    const char* displayName;
-
-    assert(pNode->Type() == TiXmlNode::ELEMENT);
-
-    /*
-     * Process attributes.  Right now they're all mandatory, but some of
-     * them could be defaulted (e.g. "rotate").
-     *
-     * [We should do some range-checking here.]
-     */
-    pElem = pNode->ToElement();
-    displayName = pElem->Attribute("display");
-    if (displayName == NULL)
-        goto missing;
-    if (pElem->Attribute("x", &mXOffset) == NULL)
-        goto missing;
-    if (pElem->Attribute("y", &mYOffset) == NULL)
-        goto missing;
-    if (pElem->Attribute("rotate", &rotate) == NULL)
-        goto missing;
-
-    switch (rotate) {
-    case 0:     mRotation = kRot0;      break;
-    case 90:    mRotation = kRot90;     break;
-    case 180:   mRotation = kRot180;    break;
-    case 270:   mRotation = kRot270;    break;
-    default:
-                fprintf(stderr, "SimCFG: unexpected value for rotation\n");
-                mRotation = kRotUnknown;
-                return false;
-    }
-
-    delete[] mDisplayName;
-    mDisplayName = android::strdupNew(displayName);
-
-    /*
-     * Process elements.
-     */
-    for (pChild = pNode->FirstChild(); pChild != NULL;
-        pChild = pChild->NextSibling())
-    {
-        if (pChild->Type() == TiXmlNode::COMMENT)
-            continue;
-
-        if (pChild->Type() == TiXmlNode::ELEMENT) {
-            if (strcasecmp(pChild->Value(), "image") == 0) {
-                if (!ProcessImage(pChild, directory))
-                    return false;
-            } else if (strcasecmp(pChild->Value(), "button") == 0) {
-                if (!ProcessButton(pChild, directory))
-                    return false;
-            } else {
-                fprintf(stderr,
-                    "SimCFG: Warning: unexpected elements in <display>\n");
-            }
-        } else {
-            fprintf(stderr, "SimCFG: Warning: unexpected stuff in <display>\n");
-        }
-    }
-
-    return true;
-
-missing:
-    fprintf(stderr,
-        "SimCFG: <view> requires display/x/y/rotate\n");
-    return false;
-}
-
-/*
- * Handle <image src="zzz" x="123" y="123"/>.
- */
-bool PhoneView::ProcessImage(TiXmlNode* pNode, const char* directory)
-{
-    TiXmlNode* pChild;
-    TiXmlElement* pElem;
-    int x, y;
-    const char* src;
-    LoadableImage tmpLimg;
-    android::String8 fileName;
-
-    pChild = pNode->FirstChild();
-    if (pChild != NULL) {
-        fprintf(stderr, "SimCFG: <image> is funky\n");
-        return false;
-    }
-
-    /*
-     * All attributes are mandatory.
-     */
-    pElem = pNode->ToElement();
-    src = pElem->Attribute("src");
-    if (src == NULL)
-        goto missing;
-    if (pElem->Attribute("x", &x) == NULL)
-        goto missing;
-    if (pElem->Attribute("y", &y) == NULL)
-        goto missing;
-
-    if (strncmp(src, kRelPathMagic, strlen(kRelPathMagic)) == 0) {
-        fileName = src + strlen(kRelPathMagic);
-    } else {
-        fileName = directory;
-        fileName += "/";
-        fileName += src;
-    }
-
-    tmpLimg.Create(fileName, x, y);
-    mImageList.push_back(tmpLimg);
-
-    return true;
-
-missing:
-    fprintf(stderr, "SimCFG: <image> requires src/x/y\n");
-    return false;
-}
-
-/*
- * Handle <button keyCode="zzz" src="zzz" x="123" y="123"/> and
- * <button keyCode="zzz"/>.
- */
-bool PhoneView::ProcessButton(TiXmlNode* pNode, const char* directory)
-{
-    TiXmlNode* pChild;
-    TiXmlElement* pElem;
-    int x, y;
-    const char* keyCode;
-    const char* src;
-    PhoneButton tmpButton;
-    android::String8 fileName;
-
-    pChild = pNode->FirstChild();
-    if (pChild != NULL) {
-        fprintf(stderr, "SimCFG: button is funky\n");
-        return false;
-    }
-
-    /*
-     * Only keyCode is mandatory.  If they specify "src", then "x" and "y"
-     * are also required.
-     */
-    pElem = pNode->ToElement();
-    keyCode = pElem->Attribute("keyCode");
-    if (keyCode == NULL)
-        goto missing;
-
-    src = pElem->Attribute("src");
-    if (src != NULL) {
-        if (pElem->Attribute("x", &x) == NULL)
-            goto missing;
-        if (pElem->Attribute("y", &y) == NULL)
-            goto missing;
-    }
-
-    if (src == NULL)
-        tmpButton.Create(keyCode);
-    else {
-        if (strncmp(src, kRelPathMagic, strlen(kRelPathMagic)) == 0) {
-            fileName = src + strlen(kRelPathMagic);
-        } else {
-            fileName = directory;
-            fileName += "/";
-            fileName += src;
-        }
-        tmpButton.Create(keyCode, fileName, x, y);
-    }
-
-    mButtonList.push_back(tmpButton);
-
-    return true;
-
-missing:
-    fprintf(stderr, "SimCFG: <button> requires keycode and may have src/x/y\n");
-    return false;
-}
-
-
-/*
- * Load all resources associated with the display.
- */
-bool PhoneView::LoadResources(void)
-{
-    typedef List<LoadableImage>::iterator LIter;
-    typedef List<PhoneButton>::iterator BIter;
-
-    for (LIter ii = mImageList.begin(); ii != mImageList.end(); ++ii)
-        (*ii).LoadResources();
-    for (BIter ii = mButtonList.begin(); ii != mButtonList.end(); ++ii)
-        (*ii).LoadResources();
-    return true;
-}
-
-/*
- * Unload all resources associated with the display.
- */
-bool PhoneView::UnloadResources(void)
-{
-    typedef List<LoadableImage>::iterator LIter;
-    typedef List<PhoneButton>::iterator BIter;
-
-    for (LIter ii = mImageList.begin(); ii != mImageList.end(); ++ii)
-        (*ii).UnloadResources();
-    for (BIter ii = mButtonList.begin(); ii != mButtonList.end(); ++ii)
-        (*ii).UnloadResources();
-    return true;
-}
-
-
-/*
- * Get the #of images.
- */
-int PhoneView::GetBkgImageCount(void) const
-{
-    return mImageList.size();
-}
-
-/*
- * Return the Nth entry.
- */
-const LoadableImage* PhoneView::GetBkgImage(int idx) const
-{
-    typedef List<LoadableImage>::const_iterator Iter;
-
-    for (Iter ii = mImageList.begin(); ii != mImageList.end(); ++ii) {
-        if (!idx)
-            return &(*ii);
-        --idx;
-    }
-
-    return NULL;
-}
-
-
-/*
- * Find the first button that covers the specified coordinates.
- *
- * The coordinates must be relative to the upper left corner of the
- * phone image.
- */
-PhoneButton* PhoneView::FindButtonHit(int x, int y)
-{
-    typedef List<PhoneButton>::iterator Iter;
-
-    for (Iter ii = mButtonList.begin(); ii != mButtonList.end(); ++ii) {
-        if ((*ii).CheckCollision(x, y))
-            return &(*ii);
-    }
-
-    return NULL;
-}
-
-/*
- * Find the first button with a matching key code.
- */
-PhoneButton* PhoneView::FindButtonByKey(KeyCode keyCode)
-{
-    typedef List<PhoneButton>::iterator Iter;
-
-    for (Iter ii = mButtonList.begin(); ii != mButtonList.end(); ++ii) {
-        if ((*ii).GetKeyCode() == keyCode)
-            return &(*ii);
-    }
-
-    return NULL;
-}
-
-
-/*
- * ===========================================================================
- *      PhoneMode
- * ===========================================================================
- */
-
-/*
- * Process a <mode name="zzz"> chunk.
- */
-bool PhoneMode::ProcessAndValidate(TiXmlNode* pNode, const char* directory)
-{
-    TiXmlNode* pChild;
-    const char* name;
-
-    assert(pNode->Type() == TiXmlNode::ELEMENT);
-
-    name = pNode->ToElement()->Attribute("name");
-    if (name == NULL) {
-        fprintf(stderr, "SimCFG: <mode> requires name attrib\n");
-        return false;
-    }
-    SetName(name);
-
-    for (pChild = pNode->FirstChild(); pChild != NULL;
-        pChild = pChild->NextSibling())
-    {
-        if (pChild->Type() == TiXmlNode::COMMENT)
-            continue;
-
-        if (pChild->Type() == TiXmlNode::ELEMENT &&
-            strcasecmp(pChild->Value(), "view") == 0)
-        {
-            PhoneView tmpDisplay;
-            bool result;
-
-            result = tmpDisplay.ProcessAndValidate(pChild, directory);
-            if (!result)
-                return false;
-
-            mViewList.push_back(tmpDisplay);
-        } else {
-            fprintf(stderr, "SimCFG: Warning: unexpected stuff in <mode>\n");
-        }
-    }
-
-    if (mViewList.size() == 0) {
-        fprintf(stderr, "SimCFG: no <view> entries found\n");
-        return false;
-    }
-
-    return true;
-}
-
-
-/*
- * Load all resources associated with the phone.
- */
-bool PhoneMode::LoadResources(void)
-{
-    typedef List<PhoneView>::iterator Iter;
-
-    for (Iter ii = mViewList.begin(); ii != mViewList.end(); ++ii)
-        (*ii).LoadResources();
-    return true;
-}
-
-/*
- * Unload all resources associated with the phone.
- */
-bool PhoneMode::UnloadResources(void)
-{
-    typedef List<PhoneView>::iterator Iter;
-
-    for (Iter ii = mViewList.begin(); ii != mViewList.end(); ++ii)
-        (*ii).UnloadResources();
-    return true;
-}
-
-
-/*
- * Return the Nth entry.  [make this a Vector?]
- */
-PhoneView* PhoneMode::GetPhoneView(int viewNum)
-{
-    typedef List<PhoneView>::iterator Iter;
-
-    for (Iter ii = mViewList.begin(); ii != mViewList.end(); ++ii) {
-        if (viewNum == 0)
-            return &(*ii);
-        --viewNum;
-    }
-    return NULL;
-}
-
-
-/*
- * ===========================================================================
- *      PhoneData
- * ===========================================================================
- */
-
-
-/*
- * Look for a "layout.xml" in the specified directory.  If found, parse
- * the contents out.
- *
- * Returns "true" on success, "false" on failure.
- */
-bool PhoneData::Create(const char* directory)
-{
-    android::String8 fileName;
-
-    SetDirectory(directory);
-
-    fileName = directory;
-    fileName += "/";
-    fileName += PhoneCollection::kLayoutFile;
-
-#ifdef BEFORE_ASSET
-    TiXmlDocument doc(fileName);
-    if (!doc.LoadFile())
-#else
-    android::AssetManager* pAssetMgr = ((MyApp*)wxTheApp)->GetAssetManager();
-    TiXmlDocument doc;
-    android::Asset* pAsset;
-    bool result;
-
-    pAsset = pAssetMgr->open(fileName, Asset::ACCESS_STREAMING);
-    if (pAsset == NULL) {
-        fprintf(stderr, "Unable to open asset '%s'\n", (const char*) fileName);
-        return false;
-    } else {
-        //printf("--- opened asset '%s'\n",
-        //    (const char*) pAsset->getAssetSource());
-    }
-
-    /* TinyXml insists that the buffer be NULL-terminated... ugh */
-    char* buf = new char[pAsset->getLength() +1];
-    pAsset->read(buf, pAsset->getLength());
-    buf[pAsset->getLength()] = '\0';
-
-    delete pAsset;
-    result = doc.Parse(buf);
-    delete[] buf;
-
-    if (!result)
-#endif
-    {
-        fprintf(stderr, "SimCFG: ERROR: failed parsing '%s'\n",
-            (const char*) fileName);
-        if (doc.ErrorRow() != 0)
-            fprintf(stderr, "    XML: %s (row=%d col=%d)\n",
-                doc.ErrorDesc(), doc.ErrorRow(), doc.ErrorCol());
-        else
-            fprintf(stderr, "    XML: %s\n", doc.ErrorDesc());
-        return false;
-    }
-
-    if (!ProcessAndValidate(&doc)) {
-        fprintf(stderr, "SimCFG: ERROR: failed analyzing '%s'\n",
-            (const char*) fileName);
-        return false;
-    }
-
-    printf("SimCFG: loaded data from '%s'\n", (const char*) fileName);
-
-    return true;
-}
-
-/*
- * TinyXml has loaded and parsed the XML document for us.  We need to
- * run through the DOM tree, pull out the interesting bits, and make
- * sure the stuff we need is present.
- *
- * Returns "true" on success, "false" on failure.
- */
-bool PhoneData::ProcessAndValidate(TiXmlDocument* pDoc)
-{
-    bool deviceFound = false;
-    TiXmlNode* pChild;
-
-    assert(pDoc->Type() == TiXmlNode::DOCUMENT);
-
-    for (pChild = pDoc->FirstChild(); pChild != NULL;
-        pChild = pChild->NextSibling())
-    {
-        /*
-         * Find the <device> entry.  There should be exactly one.
-         */
-        if (pChild->Type() == TiXmlNode::ELEMENT) {
-            if (strcasecmp(pChild->Value(), "device") != 0) {
-                fprintf(stderr,
-                    "SimCFG: Warning: unexpected element '%s' at top level\n",
-                    pChild->Value());
-                continue;
-            }
-            if (deviceFound) {
-                fprintf(stderr, "SimCFG: one <device> per customer\n");
-                return false;
-            }
-
-            bool result = ProcessDevice(pChild);
-            if (!result)
-                return false;
-            deviceFound = true;
-        }
-    }
-
-    if (!deviceFound) {
-        fprintf(stderr, "SimCFG: no <device> section found\n");
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Process a <device name="zzz"> chunk.
- */
-bool PhoneData::ProcessDevice(TiXmlNode* pNode)
-{
-    TiXmlNode* pChild;
-    const char* name;
-
-    assert(pNode->Type() == TiXmlNode::ELEMENT);
-
-    name = pNode->ToElement()->Attribute("name");
-    if (name == NULL) {
-        fprintf(stderr, "SimCFG: <device> requires name attrib\n");
-        return false;
-    }
-    SetName(name);
-
-    /*
-     * Walk through the children and find interesting stuff.
-     *
-     * Might be more correct to process all <display> entries and
-     * then process all <view> entries, since <view> has "pointers"
-     * to <display>.  We're deferring the lookup until later, though,
-     * so for now it doesn't really matter.
-     */
-    for (pChild = pNode->FirstChild(); pChild != NULL;
-        pChild = pChild->NextSibling())
-    {
-        bool result;
-
-        if (pChild->Type() == TiXmlNode::COMMENT)
-            continue;
-
-        if (pChild->Type() == TiXmlNode::ELEMENT &&
-            strcasecmp(pChild->Value(), "title") == 0)
-        {
-            result = ProcessTitle(pChild);
-            if (!result)
-                return false;
-        } else if (pChild->Type() == TiXmlNode::ELEMENT &&
-            strcasecmp(pChild->Value(), "display") == 0)
-        {
-            PhoneDisplay tmpDisplay;
-
-            result = tmpDisplay.ProcessAndValidate(pChild);
-            if (!result)
-                return false;
-
-            mDisplayList.push_back(tmpDisplay);
-        } else if (pChild->Type() == TiXmlNode::ELEMENT &&
-            strcasecmp(pChild->Value(), "keyboard") == 0)
-        {
-            PhoneKeyboard tmpKeyboard;
-            result = tmpKeyboard.ProcessAndValidate(pChild);
-            if (!result)
-                return false;
-                
-            mKeyboardList.push_back(tmpKeyboard);           
-        } else if (pChild->Type() == TiXmlNode::ELEMENT &&
-            strcasecmp(pChild->Value(), "mode") == 0)
-        {
-            PhoneMode tmpMode;
-
-            result = tmpMode.ProcessAndValidate(pChild, mDirectory);
-            if (!result)
-                return false;
-
-            mModeList.push_back(tmpMode);
-        } else {
-            fprintf(stderr, "SimCFG: Warning: unexpected stuff in <device>\n");
-        }
-    }
-
-    if (mDisplayList.size() == 0) {
-        fprintf(stderr, "SimCFG: no <display> entries found\n");
-        return false;
-    }
-    if (mModeList.size() == 0) {
-        fprintf(stderr, "SimCFG: no <mode> entries found\n");
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Handle <title>.
- */
-bool PhoneData::ProcessTitle(TiXmlNode* pNode)
-{
-    TiXmlNode* pChild;
-
-    pChild = pNode->FirstChild();
-    if (pChild->Type() != TiXmlNode::TEXT) {
-        fprintf(stderr, "SimCFG: title is funky\n");
-        return false;
-    }
-
-    SetTitle(pChild->Value());
-    return true;
-}
-
-
-/*
- * Load all resources associated with the phone.
- */
-bool PhoneData::LoadResources(void)
-{
-    typedef List<PhoneMode>::iterator Iter;
-
-    for (Iter ii = mModeList.begin(); ii != mModeList.end(); ++ii)
-        (*ii).LoadResources();
-    return true;
-}
-
-/*
- * Unload all resources associated with the phone.
- */
-bool PhoneData::UnloadResources(void)
-{
-    typedef List<PhoneMode>::iterator Iter;
-
-    for (Iter ii = mModeList.begin(); ii != mModeList.end(); ++ii)
-        (*ii).UnloadResources();
-    return true;
-}
-
-
-/*
- * Return the PhoneMode entry with the matching name.
- *
- * Returns NULL if no match was found.
- */
-PhoneMode* PhoneData::GetPhoneMode(const char* modeName)
-{
-    typedef List<PhoneMode>::iterator Iter;
-
-    for (Iter ii = mModeList.begin(); ii != mModeList.end(); ++ii) {
-        if (strcmp((*ii).GetName(), modeName) == 0)
-            return &(*ii);
-    }
-    return NULL;
-}
-
-/*
- * Return the Nth phone mode entry.
- */
-PhoneMode* PhoneData::GetPhoneMode(int idx)
-{
-    typedef List<PhoneMode>::iterator Iter;
-
-    for (Iter ii = mModeList.begin(); ii != mModeList.end(); ++ii) {
-        if (!idx)
-            return &(*ii);
-        --idx;
-    }
-    return NULL;
-}
-
-
-/*
- * Return the PhoneDisplay entry with the matching name.
- *
- * Returns NULL if no match was found.
- */
-PhoneDisplay* PhoneData::GetPhoneDisplay(const char* dispName)
-{
-    typedef List<PhoneDisplay>::iterator Iter;
-
-    for (Iter ii = mDisplayList.begin(); ii != mDisplayList.end(); ++ii) {
-        if (strcmp((*ii).GetName(), dispName) == 0)
-            return &(*ii);
-    }
-    return NULL;
-}
-
-/*
- * Return the Nth phone mode entry.
- */
-PhoneDisplay* PhoneData::GetPhoneDisplay(int idx)
-{
-    typedef List<PhoneDisplay>::iterator Iter;
-
-    for (Iter ii = mDisplayList.begin(); ii != mDisplayList.end(); ++ii) {
-        if (!idx)
-            return &(*ii);
-        --idx;
-    }
-    return NULL;
-}
-
-/*
- * Find the PhoneDisplay entry with the matching name, and return its index.
- *
- * Returns -1 if the entry wasn't found.
- */
-int PhoneData::GetPhoneDisplayIndex(const char* dispName)
-{
-    typedef List<PhoneDisplay>::iterator Iter;
-    int idx = 0;
-
-    for (Iter ii = mDisplayList.begin(); ii != mDisplayList.end(); ++ii) {
-        if (strcmp((*ii).GetName(), dispName) == 0)
-            return idx;
-        idx++;
-    }
-    return -1;
-}
-
-
-/*
- * Return the Nth phone keyboard entry.
- */
-PhoneKeyboard* PhoneData::GetPhoneKeyboard(int idx)
-{
-    typedef List<PhoneKeyboard>::iterator Iter;
-
-    for (Iter ii = mKeyboardList.begin(); ii != mKeyboardList.end(); ++ii) {
-        if (!idx)
-            return &(*ii);
-        --idx;
-    }
-    return NULL;
-}
diff --git a/simulator/app/PhoneData.h b/simulator/app/PhoneData.h
deleted file mode 100644
index c7f4732..0000000
--- a/simulator/app/PhoneData.h
+++ /dev/null
@@ -1,365 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Simulated device definition.
-//
-// The "root" of the data structures here is PhoneCollection, which may
-// discard the entire set if the user asks to re-scan the phone definitions.
-// These structures should be considered read-only.
-//
-// PhoneCollection (single global instance)
-//    -->PhoneData
-//       -->PhoneDisplay
-//       -->PhoneMode
-//          -->PhoneView
-//
-#ifndef _SIM_PHONE_DATA_H
-#define _SIM_PHONE_DATA_H
-
-#include <stdio.h>
-#include "tinyxml.h"
-
-#include "PhoneButton.h"
-#include "LoadableImage.h"
-#include <ui/PixelFormat.h>
-#include <utils.h>
-
-
-/*
- * This represents the keyboard type of the simulated device
- */
-class PhoneKeyboard {
-public:
-    PhoneKeyboard(void)
-        : mQwerty(false), mKeyMap(NULL)
-        {}       
-    ~PhoneKeyboard(void) {
-        free((void*)mKeyMap);
-    }    
- 
-    PhoneKeyboard(const PhoneKeyboard& src)
-        : mQwerty(false), mKeyMap(NULL)
-    {
-        CopyMembers(src);
-    }
-    PhoneKeyboard& operator=(const PhoneKeyboard& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const PhoneKeyboard& src) {
-        mQwerty = src.mQwerty;
-        mKeyMap = src.mKeyMap ? strdup(src.mKeyMap) : NULL;
-    }
-    
-    bool ProcessAndValidate(TiXmlNode* pNode);
-    
-    bool getQwerty() { return mQwerty; }    
-
-    const char *getKeyMap() { return mKeyMap; }
-private:
-    bool    mQwerty;
-    const char * mKeyMap;
-};
-
-/*
- * This represents a single display device, usually an LCD screen.
- * It also includes an optional surrounding graphic, usually a picture of
- * the device itself.
- */
-class PhoneDisplay {
-public:
-    PhoneDisplay(void)
-        : mName(NULL)
-        {}
-    ~PhoneDisplay(void) {
-        delete[] mName;
-    }
-
-    PhoneDisplay(const PhoneDisplay& src)
-        : mName(NULL)
-    {
-        CopyMembers(src);
-    }
-    PhoneDisplay& operator=(const PhoneDisplay& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const PhoneDisplay& src) {
-        // Can't memcpy and member-copy the container classes, because the
-        // containers have already been constructed, and for operator= they
-        // might even have stuff in them.
-        delete[] mName;
-        mName = android::strdupNew(src.mName);
-        mWidth = src.mWidth;
-        mHeight = src.mHeight;
-        mFormat = src.mFormat;
-        mRefresh = src.mRefresh;
-    }
-
-    bool ProcessAndValidate(TiXmlNode* pNode);
-
-    const char* GetName(void) const { return mName; }
-    int GetWidth(void) const { return mWidth; }
-    int GetHeight(void) const { return mHeight; }
-    android::PixelFormat GetFormat(void) const { return mFormat; }
-    int GetRefresh(void) const { return mRefresh; }
-
-    static bool IsCompatible(PhoneDisplay* pDisplay1, PhoneDisplay* pDisplay2);
-
-private:
-    char*           mName;
-
-    // display dimensions, in pixels
-    int             mWidth;
-    int             mHeight;
-
-    // frame buffer format
-    android::PixelFormat mFormat;
-
-    // display refresh rate, in fps
-    int             mRefresh;
-};
-
-/*
- * This is a "view" of a device, which includes the display, a background
- * image, and perhaps some clickable keys for input.
- *
- * Because the key graphics are associated with a particular display, we
- * hold a list of keys here.  (It also allows the possibility of handling
- * a situation where the same key shows up in multiple background images,
- * e.g. a flip phone with a "volume" key on the side.  If we include the
- * key in both places, we can highlight it on both displays.)
- */
-class PhoneView {
-public:
-    PhoneView(void)
-        : mDisplayName(NULL)
-        {}
-    ~PhoneView(void) {
-        delete[] mDisplayName;
-    }
-
-    PhoneView(const PhoneView& src) {
-        CopyMembers(src);
-    }
-    PhoneView& operator=(const PhoneView& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const PhoneView& src) {
-        // Can't memcpy and member-copy the container classes, because the
-        // containers have already been constructed, and for operator= they
-        // might even have stuff in them.
-        mImageList = src.mImageList;
-        mButtonList = src.mButtonList;
-        mDisplayName = android::strdupNew(src.mDisplayName);
-        mXOffset = src.mXOffset;
-        mYOffset = src.mYOffset;
-        mRotation = src.mRotation;
-    }
-
-    // load or unload resources, e.g. wxBitmaps from image files
-    bool LoadResources(void);
-    bool UnloadResources(void);
-
-    // simple accessors
-    int GetXOffset(void) const { return mXOffset; }
-    int GetYOffset(void) const { return mYOffset; }
-    const char* GetDisplayName(void) const { return mDisplayName; }
-
-    // image list access
-    int GetBkgImageCount(void) const;
-    const LoadableImage* GetBkgImage(int idx) const;
-
-    // find the first button that covers the specified coords
-    PhoneButton* FindButtonHit(int x, int y);
-
-    // find the first button with a matching key code
-    PhoneButton* FindButtonByKey(KeyCode keyCode);
-
-    bool ProcessAndValidate(TiXmlNode* pNode, const char* directory);
-    bool ProcessImage(TiXmlNode* pNode, const char* directory);
-    bool ProcessButton(TiXmlNode* pNode, const char* directory);
-
-private:
-    // background images for the phone picture that surrounds the display
-    android::List<LoadableImage> mImageList;
-
-    // list of accessible buttons, some of which have highlight graphics
-    android::List<PhoneButton>  mButtonList;
-
-    char*           mDisplayName;
-
-    // these determine where in the image the display output goes
-    int             mXOffset;
-    int             mYOffset;
-
-    // clockwise rotation of the output; sim must rotate in opposite direction
-    typedef enum Rotation {
-        kRotUnknown = 0,
-        kRot0,
-        kRot90,
-        kRot180,
-        kRot270,
-    } Rotation;
-    Rotation        mRotation;
-};
-
-/*
- * One mode of a phone.  Simple devices only have one mode.  Flip phones
- * have two (opened and closed).  Other devices might have more.  The
- * mode is communicated to the runtime because it may need to process
- * input events differently.
- */
-class PhoneMode {
-public:
-    PhoneMode(void)
-        : mName(NULL)
-        {}
-    ~PhoneMode(void) {
-        delete[] mName;
-    }
-
-    PhoneMode(const PhoneMode& src)
-        : mName(NULL)
-    {
-        CopyMembers(src);
-    }
-    PhoneMode& operator=(const PhoneMode& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const PhoneMode& src) {
-        delete[] mName;
-        mName = android::strdupNew(src.mName);
-        mViewList = src.mViewList;
-    }
-
-
-    // load or unload resources for this object and all members of mViewList
-    bool LoadResources(void);
-    bool UnloadResources(void);
-
-    // get the #of views
-    int GetNumViews(void) const { return mViewList.size(); }
-    // get the Nth display
-    PhoneView* GetPhoneView(int viewNum);
-
-    const char* GetName(void) const { return mName; }
-    void SetName(const char* name) {
-        delete[] mName;
-        mName = android::strdupNew(name);
-    }
-
-    // load the <mode> section from the config file
-    bool ProcessAndValidate(TiXmlNode* pNode, const char* directory);
-
-private:
-    char*           mName;
-
-    android::List<PhoneView> mViewList;
-};
-
-/*
- * This holds the data for one device.
- *
- * Each device may have multiple "modes", e.g. a flip-phone that can be
- * open or shut.  Each mode has different configurations for the visible
- * displays and active keys.
- */
-class PhoneData {
-public:
-    PhoneData(void) :
-        mName(NULL), mTitle(NULL), mDirectory(NULL)
-        {}
-    virtual ~PhoneData(void) {
-        delete[] mName;
-        delete[] mTitle;
-        delete[] mDirectory;
-    }
-
-    PhoneData(const PhoneData& src)
-        : mName(NULL), mTitle(NULL), mDirectory(NULL)
-    {
-        CopyMembers(src);
-    }
-    PhoneData& operator=(const PhoneData& src) {
-        if (this != &src)       // self-assignment
-            CopyMembers(src);
-        return *this;
-    }
-    void CopyMembers(const PhoneData& src) {
-        delete[] mName;
-        delete[] mTitle;
-        delete[] mDirectory;
-        mName = android::strdupNew(src.mName);
-        mTitle = android::strdupNew(src.mTitle);
-        mDirectory = android::strdupNew(src.mDirectory);
-        mModeList = src.mModeList;
-        mDisplayList = src.mDisplayList;
-        mKeyboardList = src.mKeyboardList;
-    }
-
-    // initialize the object with the phone data in the specified dir
-    bool Create(const char* directory);
-
-    // load or unload resources, e.g. wxBitmaps from image files
-    bool LoadResources(void);
-    bool UnloadResources(void);
-
-    // simple accessors
-    const char* GetName(void) const { return mName; }
-    void SetName(const char* name) {
-        delete[] mName;
-        mName = android::strdupNew(name);
-    }
-    const char* GetTitle(void) const { return mTitle; }
-    void SetTitle(const char* title) {
-        delete[] mTitle;
-        mTitle = android::strdupNew(title);
-    }
-    const char* GetDirectory(void) const { return mDirectory; }
-    void SetDirectory(const char* dir) {
-        delete[] mDirectory;
-        mDirectory = android::strdupNew(dir);
-    }
-
-    
-    // get number of modes
-    int GetNumModes(void) const { return mModeList.size(); }
-    // get the specified mode object
-    PhoneMode* GetPhoneMode(int idx);
-    PhoneMode* GetPhoneMode(const char* modeName);
-
-    // get number of displays
-    int GetNumDisplays(void) const { return mDisplayList.size(); }
-    // get the specified display object
-    PhoneDisplay* GetPhoneDisplay(int idx);
-    PhoneDisplay* GetPhoneDisplay(const char* displayName);
-    // get the index of the matching display
-    int GetPhoneDisplayIndex(const char* displayName);
-
-    // get number of keyboards
-    int GetNumKeyboards(void) const { return mKeyboardList.size(); }
-    // get the specified display object
-    PhoneKeyboard* GetPhoneKeyboard(int idx);
-    
-private:
-    bool ProcessAndValidate(TiXmlDocument* pDoc);
-    bool ProcessDevice(TiXmlNode* pNode);
-    bool ProcessTitle(TiXmlNode* pNode);
-
-    char*           mName;
-    char*           mTitle;
-    char*           mDirectory;
-
-    android::List<PhoneMode> mModeList;
-    android::List<PhoneDisplay> mDisplayList;
-    android::List<PhoneKeyboard> mKeyboardList;
-};
-
-#endif // _SIM_PHONE_DATA_H
diff --git a/simulator/app/PhoneWindow.cpp b/simulator/app/PhoneWindow.cpp
deleted file mode 100644
index 60a9809..0000000
--- a/simulator/app/PhoneWindow.cpp
+++ /dev/null
@@ -1,1051 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Displays the phone image and handles user input.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"   // needed for Windows build
-#include "wx/dcbuffer.h"
-
-#include "LinuxKeys.h"
-#include "PhoneWindow.h"
-#include "DeviceWindow.h"
-#include "PhoneData.h"
-#include "PhoneCollection.h"
-#include "MainFrame.h"
-#include "MyApp.h"
-
-using namespace android;
-
-BEGIN_EVENT_TABLE(PhoneWindow, wxWindow)    // NOT wxDialog
-    EVT_ACTIVATE(PhoneWindow::OnActivate)
-    //EVT_ACTIVATE_APP(PhoneWindow::OnActivate)
-    EVT_CLOSE(PhoneWindow::OnClose)
-    EVT_MOVE(PhoneWindow::OnMove)
-    EVT_ERASE_BACKGROUND(PhoneWindow::OnErase)
-    EVT_PAINT(PhoneWindow::OnPaint)
-
-    EVT_KEY_DOWN(PhoneWindow::OnKeyDown)
-    EVT_KEY_UP(PhoneWindow::OnKeyUp)
-    EVT_LEFT_DOWN(PhoneWindow::OnMouseLeftDown)
-    EVT_LEFT_DCLICK(PhoneWindow::OnMouseLeftDown)
-    EVT_LEFT_UP(PhoneWindow::OnMouseLeftUp)
-    EVT_RIGHT_DOWN(PhoneWindow::OnMouseRightDown)
-    EVT_RIGHT_DCLICK(PhoneWindow::OnMouseRightDown)
-    EVT_RIGHT_UP(PhoneWindow::OnMouseRightUp)
-    EVT_MOTION(PhoneWindow::OnMouseMotion)
-    EVT_LEAVE_WINDOW(PhoneWindow::OnMouseLeaveWindow)
-    EVT_TIMER(kVibrateTimerId, PhoneWindow::OnTimer)
-END_EVENT_TABLE()
-
-
-/*
- * Create a new PhoneWindow.  This should be a child of the main frame.
- */
-PhoneWindow::PhoneWindow(wxWindow* parent, const wxPoint& posn)
-    : wxDialog(parent, wxID_ANY, wxT("Device"), posn, wxDefaultSize,
-        wxDEFAULT_DIALOG_STYLE),
-      mpMOHViewIndex(-1),
-      mpMOHButton(NULL),
-      mMouseKeySent(kKeyCodeUnknown),
-      mpViewInfo(NULL),
-      mNumViewInfo(0),
-      mpDeviceWindow(NULL),
-      mNumDeviceWindows(0),
-      mPhoneModel(-1),
-      mCurrentMode(wxT("(unknown)")),
-      mPlacementChecked(false),
-      mpParent((MainFrame*)parent),
-      mTimer(this, kVibrateTimerId),
-      mTrackingTouch(false)
-{
-    SetBackgroundColour(*wxLIGHT_GREY);
-    SetBackgroundStyle(wxBG_STYLE_CUSTOM);
-
-    //SetCursor(wxCursor(wxCURSOR_HAND));     // a bit distracting (pg.276)
-}
-
-/*
- * Destroy everything we own.
- *
- * This might be called well after we've been closed and another
- * PhoneWindow has been created, because wxWidgets likes to defer things.
- */
-PhoneWindow::~PhoneWindow(void)
-{
-    //printf("--- ~PhoneWindow %p\n", this);
-    delete[] mpViewInfo;
-    if (mpDeviceWindow != NULL) {
-        for (int i = 0; i < mNumDeviceWindows; i++) {
-            /* make sure they don't try to use our member */
-            mpDeviceWindow[i]->DeviceManagerClosing();
-            /* make sure the child window gets destroyed -- not necessary? */
-            mpDeviceWindow[i]->Destroy();
-        }
-
-        /* delete our array of pointers */
-        delete[] mpDeviceWindow;
-    }
-}
-
-/*
- * Check for an updated runtime when window becomes active
- */
-void PhoneWindow::OnActivate(wxActivateEvent& event)
-{
-    /*
-     * DO NOT do this.  Under Windows, it causes the parent window to get
-     * an activate event, which causes our parent to get the focus.  With
-     * this bit of code active it is impossible for the phone window to
-     * receive user input.
-     */
-    //GetParent()->AddPendingEvent(event);
-
-    // If we are being deactivated, go ahead and send key up events so that the
-    // runtime doesn't think we are holding down the key. Issue #685750
-    if (!event.GetActive()) {
-        ListIter iter;
-        for (iter = mPressedKeys.begin(); iter != mPressedKeys.end(); ) {
-            KeyCode keyCode = (*iter).GetKeyCode();
-            GetDeviceManager()->SendKeyEvent(keyCode, false);
-            iter = mPressedKeys.erase(iter);
-        }
-    }
-}
-
-/*
- * Close the phone window.
- */
-void PhoneWindow::OnClose(wxCloseEvent& event)
-{
-    //printf("--- PhoneWindow::OnClose %p\n", this);
-#if 0
-    if (mDeviceManager.IsRunning() && !mDeviceManager.IsKillable()) {
-        printf("Sim: refusing to close window on external runtime\n");
-        event.Veto();
-        return;
-    }
-#endif
-
-    wxRect rect = GetRect();
-    printf("Sim: Closing phone window (posn=(%d,%d))\n", rect.x, rect.y);
-
-    /* notify others */
-    mpParent->PhoneWindowClosing(rect.x, rect.y);
-    mDeviceManager.WindowsClosing();
-
-    /* end it all */
-    Destroy();
-}
-
-/*
- * Prep the PhoneWindow to display a specific phone model.  Pass in the
- * model index.
- *
- * This gets called whenever the display changes.  This could be a new
- * device with identical characteristics, or a different mode for the same
- * device.
- *
- * The window can be re-used so long as the display characteristics are
- * the same.  If the display characteristics are different, we have to
- * restart the device.
- */
-bool PhoneWindow::Setup(int phoneIdx)
-{
-    wxString fileName;
-    PhoneCollection* pCollection = PhoneCollection::GetInstance();
-
-    if (phoneIdx < 0 || phoneIdx >= pCollection->GetPhoneCount()) {
-        fprintf(stderr, "Bogus phone index %d\n", phoneIdx);
-        return false;
-    }
-
-    /*
-     * Clear these out so that failure here is noticeable to caller.  We
-     * regenerate the ViewInfo array every time, because the set of Views
-     * is different for every Mode.
-     */
-    delete[] mpViewInfo;
-    mpViewInfo = NULL;
-    mNumViewInfo = -1;
-
-    PhoneData* pPhoneData;
-    PhoneMode* pPhoneMode;
-    PhoneView* pPhoneView;
-
-    pPhoneData = pCollection->GetPhoneData(phoneIdx);
-
-    pPhoneMode = pPhoneData->GetPhoneMode(GetCurrentMode().ToAscii());
-    if (pPhoneMode == NULL) {
-        fprintf(stderr, "current mode (%s) not known\n",
-            (const char*) GetCurrentMode().ToAscii());
-        return false;
-    }
-
-    int numViews = pPhoneMode->GetNumViews();
-    if (numViews == 0) {
-        fprintf(stderr, "Phone %d mode %s has no views\n",
-            phoneIdx, pPhoneMode->GetName());
-        return false;
-    }
-
-    const int kBorder = 2;
-    int i;
-    int maxHeight = 0;
-    int fullWidth = kBorder;
-    ViewInfo* pViewInfo;
-
-    pViewInfo = new ViewInfo[numViews];
-
-    /* figure out individual and overall dimensions */
-    for (i = 0; i < numViews; i++) {
-        pPhoneView = pPhoneMode->GetPhoneView(i);
-        if (pPhoneView == NULL) {
-            fprintf(stderr, "view %d not found\n", i);
-            return false;
-        }
-
-        if (!GetDimensions(pPhoneData, pPhoneView, &pViewInfo[i]))
-            return false;
-
-        if (maxHeight < pViewInfo[i].GetHeight())
-            maxHeight = pViewInfo[i].GetHeight();
-        fullWidth += pViewInfo[i].GetWidth() + kBorder;
-    }
-
-    /* create the device windows if we don't already have them */
-    if (mpDeviceWindow == NULL) {
-        mNumDeviceWindows = pPhoneData->GetNumDisplays();
-        mpDeviceWindow = new DeviceWindow*[mNumDeviceWindows];
-        if (mpDeviceWindow == NULL)
-            return false;
-
-        for (i = 0; i < mNumDeviceWindows; i++) {
-            mpDeviceWindow[i] = new DeviceWindow(this, &mDeviceManager);
-        }
-    } else {
-        assert(pPhoneData->GetNumDisplays() == mNumDeviceWindows);
-    }
-
-    /*
-     * Position device windows within their views, taking into account
-     * border areas.
-     */
-    int shift = kBorder;
-    for (i = 0; i < numViews; i++) {
-        int displayIdx;
-        PhoneDisplay* pPhoneDisplay;
-
-        displayIdx = pViewInfo[i].GetDisplayIndex();
-        pPhoneDisplay = pPhoneData->GetPhoneDisplay(displayIdx);
-        //printf("View %d: display %d\n", i, displayIdx);
-
-        pViewInfo[i].SetX(shift);
-        pViewInfo[i].SetY(kBorder);
-
-        mpDeviceWindow[displayIdx]->SetSize(
-            pViewInfo[i].GetX() + pViewInfo[i].GetDisplayX(),
-            pViewInfo[i].GetY() + pViewInfo[i].GetDisplayY(),
-            pPhoneDisplay->GetWidth(), pPhoneDisplay->GetHeight());
-
-        // incr by width of view
-        shift += pViewInfo[i].GetWidth() + kBorder;
-    }
-
-    /* configure the device manager if it's not already running */
-    if (!mDeviceManager.IsInitialized()) {
-        mDeviceManager.Init(pPhoneData->GetNumDisplays(), mpParent);
-
-        for (i = 0; i < pPhoneData->GetNumDisplays(); i++) {
-            PhoneDisplay* pPhoneDisplay;
-            bool res;
-
-            pPhoneDisplay = pPhoneData->GetPhoneDisplay(i);
-
-            res = mDeviceManager.SetDisplayConfig(i, mpDeviceWindow[i],
-                pPhoneDisplay->GetWidth(), pPhoneDisplay->GetHeight(),
-                pPhoneDisplay->GetFormat(), pPhoneDisplay->GetRefresh());
-            if (!res) {
-                fprintf(stderr, "Sim: ERROR: could not configure device mgr\n");
-                return false;
-            }
-        }
-        const char *kmap = pPhoneData->GetPhoneKeyboard(0)->getKeyMap();
-        mDeviceManager.SetKeyboardConfig(kmap);
-    } else {
-        assert(pPhoneData->GetNumDisplays() == mDeviceManager.GetNumDisplays());
-    }
-
-    /*
-     * Success.  Finish up.
-     */
-    mPhoneModel = phoneIdx;
-    mpViewInfo = pViewInfo;
-    mNumViewInfo = numViews;
-
-    /* set up our window */
-    SetClientSize(fullWidth, maxHeight + kBorder * 2);
-    SetBackgroundColour(*wxLIGHT_GREY);
-    //SetBackgroundColour(*wxBLUE);
-    SetTitle(wxString::FromAscii(pPhoneData->GetTitle()));
-
-    SetFocus();     // set keyboard input focus
-
-    return true;
-}
-
-/*
- * The device table has been reloaded.  We need to throw out any pointers
- * we had into it and possibly reload some stuff.
- */
-void PhoneWindow::DevicesRescanned(void)
-{
-    mpMOHButton = NULL;
-    mpMOHViewIndex = -1;
-
-    /*
-     * Re-evaluate phone definition.  There is an implicit assumption
-     * that the re-scanned version is compatible with the previous
-     * version (i.e. it still exists and has the same screen size).
-     *
-     * We're also currently assuming that no phone definitions have been
-     * added or removed, which is bad -- we should get the new index for
-     * for phone by searching for it by name.
-     *
-     * TODO: don't make these assumptions.
-     */
-    Setup(mPhoneModel);
-}
-
-/*
- * Check the initial placement of the window.  We get one of these messages
- * when the window is first placed, and every time it's moved thereafter.
- *
- * Right now we're just trying to make sure wxWidgets doesn't shove it off
- * the top of the screen under Linux.  Might want to change this to
- * remember the previous placement and put the window back.
- */
-void PhoneWindow::OnMove(wxMoveEvent& event)
-{
-    if (mPlacementChecked)
-        return;
-
-    wxPoint point;
-    point = event.GetPosition();
-    if (point.y < 0) {
-        printf("Sim: window is at (%d,%d), adjusting\n", point.x, point.y);
-        point.y = 0;
-        Move(point);
-    }
-
-    mPlacementChecked = true;
-}
-
-/*
- * Figure out the dimensions required to contain the specified view.
- *
- * This is usually the size of the background image, but if we can't
- * load it or it's too small just create a trivial window.
- */
-bool PhoneWindow::GetDimensions(PhoneData* pPhoneData, PhoneView* pPhoneView,
-    ViewInfo* pInfo)
-{
-    PhoneDisplay* pPhoneDisplay;
-    int xoff=0, yoff=0, width, height;
-    int displayIdx;
-
-    displayIdx = pPhoneData->GetPhoneDisplayIndex(pPhoneView->GetDisplayName());
-    if (displayIdx < 0)
-        return false;
-
-    pPhoneDisplay = pPhoneData->GetPhoneDisplay(displayIdx);
-    if (pPhoneDisplay == NULL) {
-        fprintf(stderr, "display '%s' not found in device '%s'\n",
-            pPhoneView->GetDisplayName(), pPhoneData->GetName());
-        return false;
-    }
-
-    // load images for this phone
-    (void) pPhoneView->LoadResources();
-
-    width = height = 0;
-
-    // by convention, the background bitmap is the first image in the list
-    if (pPhoneView->GetBkgImageCount() > 0) {
-        wxBitmap* pBitmap = pPhoneView->GetBkgImage(0)->GetBitmap();
-        if (pBitmap != NULL) {
-            // size window to match bitmap
-            xoff = pPhoneView->GetXOffset();
-            yoff = pPhoneView->GetYOffset();
-            width = pBitmap->GetWidth();
-            height = pBitmap->GetHeight();
-        }
-    }
-
-    // no bitmap, or bitmap is smaller than display
-    if (width < pPhoneDisplay->GetWidth() ||
-        height < pPhoneDisplay->GetHeight())
-    {
-        // create window to just hold display
-        xoff = yoff = 0;
-        width = pPhoneDisplay->GetWidth();
-        height = pPhoneDisplay->GetHeight();
-    }
-    if (width <= 0 || height <= 0) {
-        fprintf(stderr, "ERROR: couldn't determine display size\n");
-        return false;
-    }
-
-    pInfo->SetX(0);
-    pInfo->SetY(0);             // another function determines these
-    pInfo->SetDisplayX(xoff);
-    pInfo->SetDisplayY(yoff);
-    pInfo->SetWidth(width);
-    pInfo->SetHeight(height);
-    pInfo->SetDisplayIndex(displayIdx);
-
-    //printf("xoff=%d yoff=%d width=%d height=%d index=%d\n",
-    //    pInfo->GetDisplayX(), pInfo->GetDisplayY(),
-    //    pInfo->GetWidth(), pInfo->GetHeight(), pInfo->GetDisplayIndex());
-
-    return true;
-}
-
-/*
- * Return PhoneData pointer for the current phone model.
- */
-PhoneData* PhoneWindow::GetPhoneData(void) const
-{
-    PhoneCollection* pCollection = PhoneCollection::GetInstance();
-    return pCollection->GetPhoneData(mPhoneModel);
-}
-
-/*
- * Convert a wxWidgets key code into a device key code.
- *
- * Someday we may want to make this configurable.
- *
- * NOTE: we need to create a mapping between simulator key and desired
- * function.  The "return" key should always mean "select", whether
- * it's a "select" button or pressing in on the d-pad.  Ditto for
- * the arrow keys, whether we have a joystick, d-pad, or four buttons.
- * Each key here should have a set of things that it could possibly be,
- * and we match it up with the set of buttons actually defined for the
- * phone.  [for convenience, need to ensure that buttons need not have
- * an associated image]
- */
-int PhoneWindow::ConvertKeyCode(int wxKeyCode) const
-{
-    switch (wxKeyCode) {
-    case WXK_NUMPAD_INSERT:
-    case WXK_NUMPAD0:
-    case '0':                   return KEY_0;
-    case WXK_NUMPAD_HOME:
-    case WXK_NUMPAD1:
-    case '1':                   return KEY_1;
-    case WXK_NUMPAD_UP:
-    case WXK_NUMPAD2:
-    case '2':                   return KEY_2;
-    case WXK_NUMPAD_PRIOR:
-    case WXK_NUMPAD3:
-    case '3':                   return KEY_3;
-    case WXK_NUMPAD_LEFT:
-    case WXK_NUMPAD4:
-    case '4':                   return KEY_4;
-    case WXK_NUMPAD_BEGIN:
-    case WXK_NUMPAD5:
-    case '5':                   return KEY_5;
-    case WXK_NUMPAD_RIGHT:
-    case WXK_NUMPAD6:
-    case '6':                   return KEY_6;
-    case WXK_NUMPAD_END:
-    case WXK_NUMPAD7:
-    case '7':                   return KEY_7;
-    case WXK_NUMPAD_DOWN:
-    case WXK_NUMPAD8:
-    case '8':                   return KEY_8;
-    case WXK_NUMPAD_NEXT:
-    case WXK_NUMPAD9:
-    case '9':                   return KEY_9;
-    case WXK_NUMPAD_MULTIPLY:   return KEY_SWITCHVIDEOMODE; //kKeyCodeStar;
-    case WXK_LEFT:              return KEY_LEFT;
-    case WXK_RIGHT:             return KEY_RIGHT;
-    case WXK_UP:                return KEY_UP;
-    case WXK_DOWN:              return KEY_DOWN;
-    case WXK_NUMPAD_ENTER:      return KEY_REPLY; //kKeyCodeDpadCenter;
-    case WXK_HOME:              return KEY_HOME;
-    case WXK_PRIOR:
-    case WXK_PAGEUP:            return KEY_MENU; //kKeyCodeSoftLeft;
-    case WXK_NEXT:
-    case WXK_PAGEDOWN:          return KEY_KBDILLUMUP; //kKeyCodeSoftRight;
-    case WXK_DELETE:            
-    case WXK_BACK:              return KEY_BACKSPACE; //kKeyCodeDel;
-    case WXK_ESCAPE:
-    case WXK_END:               return KEY_BACK; //kKeyCodeBack;
-    case WXK_NUMPAD_DELETE:
-    case WXK_NUMPAD_DECIMAL:    return KEY_KBDILLUMTOGGLE; //kKeyCodePound;
-    case WXK_SPACE:             return KEY_SPACE; //kKeyCodeSpace;
-    case WXK_RETURN:            return KEY_ENTER; //kKeyCodeNewline;
-    case WXK_F3:                return KEY_F3; //kKeyCodeCall;
-    case WXK_F4:                return KEY_F4; //kKeyCodeEndCall;
-    case WXK_NUMPAD_ADD:
-    case WXK_F5:                return KEY_VOLUMEUP;
-    case WXK_NUMPAD_SUBTRACT:
-    case WXK_F6:                return KEY_VOLUMEDOWN;
-    case WXK_F7:                return KEY_POWER;
-    case WXK_F8:                return KEY_CAMERA;
-    case 'A':                   return KEY_A;
-    case 'B':                   return KEY_B;
-    case 'C':                   return KEY_C;
-    case 'D':                   return KEY_D;
-    case 'E':                   return KEY_E;
-    case 'F':                   return KEY_F;
-    case 'G':                   return KEY_G;
-    case 'H':                   return KEY_H;
-    case 'I':                   return KEY_I;
-    case 'J':                   return KEY_J;
-    case 'K':                   return KEY_K;
-    case 'L':                   return KEY_L;
-    case 'M':                   return KEY_M;
-    case 'N':                   return KEY_N;
-    case 'O':                   return KEY_O;
-    case 'P':                   return KEY_P;
-    case 'Q':                   return KEY_Q;
-    case 'R':                   return KEY_R;
-    case 'S':                   return KEY_S;
-    case 'T':                   return KEY_T;
-    case 'U':                   return KEY_U;
-    case 'V':                   return KEY_V;
-    case 'W':                   return KEY_W;
-    case 'X':                   return KEY_X;
-    case 'Y':                   return KEY_Y;
-    case 'Z':                   return KEY_Z;
-    case ',':                   return KEY_COMMA;
-    case '.':                   return KEY_DOT;
-    case '<':                   return KEY_COMMA;
-    case '>':                   return KEY_DOT;
-    case '`':                   return KEY_GREEN; /*KEY_GRAVE;*/
-    case '-':                   return KEY_MINUS;
-    case '=':                   return KEY_EQUAL;
-    case '[':                   return KEY_LEFTBRACE;
-    case ']':                   return KEY_RIGHTBRACE;
-    case '\\':                  return KEY_BACKSLASH;
-    case ';':                   return KEY_SEMICOLON;
-    case '\'':                  return KEY_APOSTROPHE;
-    case '/':                   return KEY_SLASH;
-    case WXK_SHIFT:             return KEY_LEFTSHIFT;
-    case WXK_CONTROL:
-    case WXK_ALT:               return KEY_LEFTALT;
-    case WXK_TAB:               return KEY_TAB;
-    // don't show "ignoring key" message for these
-    case WXK_MENU:
-        break;
-    default:
-        printf("(ignoring key %d)\n", wxKeyCode);
-        break;
-    }
-
-    return kKeyCodeUnknown;
-}
-
-
-/*
- * Keyboard handling.  These get converted into Android-defined key
- * constants here.
- *
- * NOTE: would be nice to handle menu keyboard accelerators here.
- * Simply stuffing the key events into MainFrame with AddPendingEvent
- * didn't seem to do the trick.
- */
-void PhoneWindow::OnKeyDown(wxKeyEvent& event)
-{
-    KeyCode keyCode;
-
-    keyCode = (KeyCode) ConvertKeyCode(event.GetKeyCode());
-    if (keyCode != kKeyCodeUnknown) {
-        if (!IsKeyPressed(keyCode)) {
-            //printf("PW: down: key %d\n", keyCode);
-            GetDeviceManager()->SendKeyEvent(keyCode, true);
-            AddPressedKey(keyCode);
-        }
-    } else {
-        //printf("PW: down: %d\n", event.GetKeyCode());
-        event.Skip();       // not handled by us
-    }
-}
-
-/*
- * Pass key-up events to runtime.
- */
-void PhoneWindow::OnKeyUp(wxKeyEvent& event)
-{
-    KeyCode keyCode;
-
-    keyCode = (KeyCode) ConvertKeyCode(event.GetKeyCode());
-    if (keyCode != kKeyCodeUnknown) {
-        // Send the key event if we already have this key pressed.
-        if (IsKeyPressed(keyCode)) {
-            //printf("PW:   up: key %d\n", keyCode);
-            GetDeviceManager()->SendKeyEvent(keyCode, false);
-            RemovePressedKey(keyCode);
-        }
-    } else {
-        //printf("PW:   up: %d\n", event.GetKeyCode());
-        event.Skip();       // not handled by us
-    }
-}
-
-/*
- * Mouse handling.
- *
- * Unlike more conventional button tracking, we highlight on mouse-over
- * and send the key on mouse-down.  This behavior may be confusing for
- * people expecting standard behavior, but it allows us to simulate the
- * effect of holding a key down.
- *
- * We want to catch both "down" and "double click" events; otherwise
- * fast clicking results in a lot of discarded events.
- */
-void PhoneWindow::OnMouseLeftDown(wxMouseEvent& event)
-{
-    if (mpMOHButton != NULL) {
-        //printf("PW: left down\n");
-        KeyCode keyCode = mpMOHButton->GetKeyCode();
-        GetDeviceManager()->SendKeyEvent(keyCode, true);
-        mMouseKeySent = keyCode;
-        AddPressedKey(keyCode);
-    } else {
-        int screenX, screenY;
-
-        if (GetTouchPosition(event, &screenX, &screenY)) {
-            //printf("TOUCH at %d,%d\n", screenX, screenY);
-            mTrackingTouch = true;
-            mTouchX = screenX;
-            mTouchY = screenY;
-            GetDeviceManager()->SendTouchEvent(Simulator::kTouchDown,
-                mTouchX, mTouchY);
-        } else {
-            //printf("(ignoring left click)\n");
-        }
-    }
-}
-
-/*
- * Left button has been released.  Do something clever.
- *
- * On some platforms we will lose this if the mouse leaves the window.
- */
-void PhoneWindow::OnMouseLeftUp(wxMouseEvent& WXUNUSED(event))
-{
-    if (mMouseKeySent != kKeyCodeUnknown) {
-        //printf("PW: left up\n");
-        GetDeviceManager()->SendKeyEvent(mMouseKeySent, false);
-        RemovePressedKey(mMouseKeySent);
-    } else {
-        if (mTrackingTouch) {
-            //printf("TOUCH release (last was %d,%d)\n", mTouchX, mTouchY);
-            mTrackingTouch = false;
-            GetDeviceManager()->SendTouchEvent(Simulator::kTouchUp,
-                mTouchX, mTouchY);
-        } else {
-            //printf("(ignoring left-up)\n");
-        }
-    }
-    mMouseKeySent = kKeyCodeUnknown;
-}
-
-void PhoneWindow::OnMouseRightDown(wxMouseEvent& event)
-{
-    //printf("(ignoring right-down)\n");
-}
-void PhoneWindow::OnMouseRightUp(wxMouseEvent& event)
-{
-    //printf("(ignoring right-up)\n");
-}
-
-/*
- * Track mouse motion so we can do mouse-over button highlighting.
- */
-void PhoneWindow::OnMouseMotion(wxMouseEvent& event)
-{
-    /*
-     * If the mouse motion event occurred inside the device window,
-     * we treat it differently than mouse movement over the picture of
-     * the device.
-     */
-    if (event.GetEventObject() == mpDeviceWindow[0]) {
-        if (mpMOHViewIndex >= 0) {
-            /* can happen if the mouse moves fast enough */
-            //printf("Mouse now in dev window, clearing button highlight\n");
-            mpMOHViewIndex = -1;
-            mpMOHButton = NULL;
-            Refresh();
-        }
-
-        if (!event.LeftIsDown() && event.RightIsDown()) {
-            /* right-button movement */
-            //printf("(ignoring right-drag)\n");
-            return;
-        }
-
-        //printf("moveto: %d,%d\n", event.m_x, event.m_y);
-
-        int screenX, screenY;
-        if (mTrackingTouch) {
-            if (GetTouchPosition(event, &screenX, &screenY)) {
-                //printf("TOUCH moved to %d,%d\n", screenX, screenY);
-                mTouchX = screenX;
-                mTouchY = screenY;
-                GetDeviceManager()->SendTouchEvent(Simulator::kTouchDrag,
-                    mTouchX, mTouchY);
-            } else {
-                //printf("TOUCH moved off screen\n");
-            }
-        }
-
-        return;
-    }
-
-    PhoneData* pPhoneData = GetPhoneData();
-    if (pPhoneData == NULL)
-        return;
-
-    /*
-     * Check to see if we're on top of a button.  If our "on top of
-     * something" state has changed, force a redraw.
-     *
-     * We have to run through the list of Views and check all of the
-     * buttons in each.
-     */
-    PhoneMode* pMode = pPhoneData->GetPhoneMode(GetCurrentMode().ToAscii());
-    if (pMode == NULL)
-        return;
-
-    int viewIndex = -1;
-    PhoneButton* pHighlight = NULL;
-    int i;
-
-    for (i = pMode->GetNumViews()-1; i >= 0; i--) {
-        PhoneView* pView = pMode->GetPhoneView(i);
-        assert(pView != NULL);
-
-        /* convert from window-relative to view-relative */
-        pHighlight = pView->FindButtonHit(event.m_x - mpViewInfo[i].GetX(),
-                                          event.m_y - mpViewInfo[i].GetY());
-        if (pHighlight != NULL) {
-            viewIndex = i;
-            break;
-        }
-    }
-
-    if (viewIndex == mpMOHViewIndex && pHighlight == mpMOHButton) {
-        /* still hovering over same button */
-    } else {
-        /* mouse has moved, possibly to a new button */
-
-        mpMOHViewIndex = viewIndex;
-        mpMOHButton = pHighlight;
-
-        /* force refresh */
-        Refresh();
-    }
-}
-
-/*
- * Mouse has left the building.  All keys and mouse buttons up.
- *
- * We get one of these if the mouse moves over a child window, such as
- * our DeviceWindow, so it is not the case that we no longer receive
- * key input after getting this event.
- */
-void PhoneWindow::OnMouseLeaveWindow(wxMouseEvent& WXUNUSED(event))
-{
-    //printf("--- mouse is GONE\n");
-    ClearPressedKeys();
-}
-
-/*
- * Determine device touch screen (x,y) based on window position.
- *
- * Returns "true" if the click corresponds to a location on the display.
- *
- * TODO: should return display index as well -- currently this only
- * supports touch on the main display.
- */
-bool PhoneWindow::GetTouchPosition(const wxMouseEvent& event, int* pScreenX,
-    int* pScreenY)
-{
-    /*
-     * If the click came from our device window, treat it as a touch.
-     */
-    if (event.GetEventObject() != mpDeviceWindow[0])
-        return false;
-
-    *pScreenX = event.m_x;
-    *pScreenY = event.m_y;
-    return true;
-}
-
-/*
- * We don't want to erase the background now, because it causes flicker
- * under Windows.
- */
-void PhoneWindow::OnErase(wxEraseEvent& WXUNUSED(event))
-{
-    //printf("erase\n");
-}
-
-/*
- * Paint the phone and any highlighted buttons.
- *
- * The device output is drawn by DeviceWindow.
- */
-void PhoneWindow::OnPaint(wxPaintEvent& WXUNUSED(event))
-{
-    int view;
-
-    /*
-     * Under Mac OS X, the parent window is redrawn every time the child
-     * window is redrawn.  This causes poor performance in the simulator.
-     * If we're being asked to update a region that corresponds exactly
-     * to one of the device output windows, skip the redraw.
-     */
-    assert(mpViewInfo != NULL);
-    for (view = 0; view < mNumViewInfo; view++) {
-        int displayIndex;
-
-        displayIndex = mpViewInfo[view].GetDisplayIndex();
-        assert(displayIndex >= 0);
-        DeviceWindow* pDeviceWindow = mpDeviceWindow[displayIndex];
-        assert(pDeviceWindow != NULL);
-
-        wxRect displayRect = pDeviceWindow->GetRect();
-        wxRect updateRect = GetUpdateClientRect();
-
-        if (displayRect == updateRect) {
-            //printf("(skipping redraw)\n");
-            return;
-        }
-    }
-
-    wxBufferedPaintDC dc(this);
-
-    /*
-     * Erase the background to the currently-specified background color.
-     */
-    wxColour backColor = GetBackgroundColour();
-    dc.SetBrush(wxBrush(backColor));
-    dc.SetPen(wxPen(backColor, 1));
-    wxRect windowRect(wxPoint(0, 0), GetClientSize());
-    dc.DrawRectangle(windowRect);
-
-    PhoneData* pPhoneData = GetPhoneData();
-    if (pPhoneData == NULL) {
-        fprintf(stderr, "OnPaint: no phone data\n");
-        return;
-    }
-
-    PhoneMode* pPhoneMode;
-    PhoneView* pPhoneView;
-    int numImages;
-
-    pPhoneMode = pPhoneData->GetPhoneMode(GetCurrentMode().ToAscii());
-    if (pPhoneMode == NULL) {
-        fprintf(stderr, "current mode (%s) not known\n",
-            (const char*) GetCurrentMode().ToAscii());
-        return;
-    }
-
-    for (view = 0; view < pPhoneMode->GetNumViews(); view++) {
-        pPhoneView = pPhoneMode->GetPhoneView(view);
-        if (pPhoneView == NULL) {
-            fprintf(stderr, "view %d not found\n", view);
-            return;
-        }
-
-        /* draw background image and "button patches" */
-        numImages = pPhoneView->GetBkgImageCount();
-        for (int i = 0; i < numImages; i++) {
-            const LoadableImage* pLimg = pPhoneView->GetBkgImage(i);
-            wxBitmap* pBitmap = pLimg->GetBitmap();
-            if (pBitmap != NULL)
-                dc.DrawBitmap(*pBitmap,
-                    mpViewInfo[view].GetX() + pLimg->GetX(),
-                    mpViewInfo[view].GetY() + pLimg->GetY(),
-                    TRUE);
-        }
-    }
-
-
-    /*
-     * Draw button mouse-over highlight.
-     *
-     * Currently we don't do anything different when the button is held down.
-     */
-    if (mpMOHViewIndex >= 0 && mpMOHButton != NULL) {
-        // button must have graphic, or hit-testing wouldn't have worked
-        assert(mpMOHButton->GetHighlightedBitmap() != NULL);
-        dc.DrawBitmap(*mpMOHButton->GetHighlightedBitmap(),
-            mpViewInfo[mpMOHViewIndex].GetX() + mpMOHButton->GetX(),
-            mpViewInfo[mpMOHViewIndex].GetY() + mpMOHButton->GetY(),
-            TRUE);
-    }
-
-    /*
-     * Highlight pressed keys.  We want to do this in all views, because
-     * some buttons on the side of the phone might be visible in more
-     * than one view.
-     */
-    for (view = 0; view < pPhoneMode->GetNumViews(); view++) {
-        pPhoneView = pPhoneMode->GetPhoneView(view);
-        assert(pPhoneView != NULL);
-
-        ListIter iter;
-        for (iter = mPressedKeys.begin(); iter != mPressedKeys.end(); ++iter) {
-            KeyCode keyCode;
-            PhoneButton* pButton;
-
-            keyCode = (*iter).GetKeyCode();
-            pButton = pPhoneView->FindButtonByKey(keyCode);
-            if (pButton != NULL) {
-                wxBitmap* pBitmap = pButton->GetSelectedBitmap();
-                if (pBitmap != NULL) {
-                    dc.DrawBitmap(*pBitmap,
-                        mpViewInfo[view].GetX() + pButton->GetX(),
-                        mpViewInfo[view].GetY() + pButton->GetY(),
-                        TRUE);
-                }
-            }
-        }
-    }
-}
-
-
-/*
- * Press a key on the device.
- *
- * Schedules a screen refresh if the set of held-down keys changes.
- */
-void PhoneWindow::AddPressedKey(KeyCode keyCode)
-{
-    /*
-     * See if the key is already down.  This usually means that the key
-     * repeat has kicked into gear.  It could also mean that we
-     * missed the key-up event, or the user has hit the same device
-     * key with both mouse and keyboard.  Either way, we don't add it
-     * a second time.  This way, if we did lose a key-up somehow, they
-     * can "clear" the stuck key by hitting it again.
-     */
-    if (keyCode == kKeyCodeUnknown) {
-        //printf("--- not adding kKeyCodeUnknown!\n");
-        return;
-    }
-
-    ListIter iter;
-    for (iter = mPressedKeys.begin(); iter != mPressedKeys.end(); ++iter) {
-        if ((*iter).GetKeyCode() == keyCode)
-            break;
-    }
-    if (iter == mPressedKeys.end()) {
-        KeyInfo newInfo;
-        newInfo.SetKeyCode(keyCode);
-        mPressedKeys.push_back(newInfo);
-        //printf("---  added down=%d\n", keyCode);
-        Refresh();      // redraw w/ highlight
-    } else {
-        //printf("---  already have down=%d\n", keyCode);
-    }
-}
-
-/*
- * Release a key on the device.
- *
- * Schedules a screen refresh if the set of held-down keys changes.
- */
-void PhoneWindow::RemovePressedKey(KeyCode keyCode)
-{
-    /*
-     * Release the key.  If it's not in the list, we either missed a
-     * key-down event, or the user used both mouse and keyboard and we
-     * removed the key when the first device went up.
-     */
-    ListIter iter;
-    for (iter = mPressedKeys.begin(); iter != mPressedKeys.end(); ++iter) {
-        if ((*iter).GetKeyCode() == keyCode) {
-            mPressedKeys.erase(iter);
-            //printf("---  removing down=%d\n", keyCode);
-            Refresh();      // redraw w/o highlight
-            break;
-        }
-    }
-    if (iter == mPressedKeys.end()) {
-        //printf("---  didn't find down=%d\n", keyCode);
-    }
-}
-
-/*
- * Clear the set of keys that we think are being held down.
- */
-void PhoneWindow::ClearPressedKeys(void)
-{
-    //printf("--- All keys up (count=%d)\n", mPressedKeys.size());
-
-    if (!mPressedKeys.empty()) {
-        ListIter iter = mPressedKeys.begin();
-        while (iter != mPressedKeys.end()) {
-            KeyCode keyCode = (*iter).GetKeyCode();
-            GetDeviceManager()->SendKeyEvent(keyCode, false);
-            iter = mPressedKeys.erase(iter);
-        }
-        Refresh();
-    }
-}
-
-/*
- * Returns "true" if the specified key is currently pressed.
- */
-bool PhoneWindow::IsKeyPressed(KeyCode keyCode)
-{
-    ListIter iter;
-    for (iter = mPressedKeys.begin(); iter != mPressedKeys.end(); ++iter) {
-        if ((*iter).GetKeyCode() == keyCode)
-            return true;
-    }
-    return false;
-}
-
-void PhoneWindow::Vibrate(int vibrateOn)
-{
-    wxRect rect = GetRect();
-    if(vibrateOn)
-    {
-        mVibrateX = 0;
-        mTimer.Start(25);      // arg is delay in ms
-        Move(rect.x-2,rect.y);
-    }
-    else if(mTimer.IsRunning())
-    {
-        mTimer.Stop();
-        if(mVibrateX&1)
-            Move(rect.x-2,rect.y);
-        else
-            Move(rect.x+2,rect.y);
-    }
-}
-
-void PhoneWindow::OnTimer(wxTimerEvent& event)
-{
-    wxRect rect = GetRect();
-    mVibrateX++;
-    if(mVibrateX&1)
-        Move(rect.x+4,rect.y);
-    else
-        Move(rect.x-4,rect.y);
-}
diff --git a/simulator/app/PhoneWindow.h b/simulator/app/PhoneWindow.h
deleted file mode 100644
index 5eb1800..0000000
--- a/simulator/app/PhoneWindow.h
+++ /dev/null
@@ -1,186 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Window with simulated phone.
-//
-#ifndef _SIM_PHONE_WINDOW_H
-#define _SIM_PHONE_WINDOW_H
-
-#include "PhoneData.h"
-#include "DeviceManager.h"
-#include "DeviceWindow.h"
-#include <ui/KeycodeLabels.h>
-
-class MainFrame;
-
-/*
- * This window displays the simulated phone views, and handles keyboard and
- * mouse input.
- *
- * If we switch to a different "mode", we may display different "views",
- * but the set of "displays" remains the same.  (Got that?)
- *
- * We can't just do these things in the main frame because we can't easily
- * grab the keyboard input.
- */
-class PhoneWindow : public wxDialog {
-public:
-    PhoneWindow(wxWindow* parent, const wxPoint& posn);
-    virtual ~PhoneWindow(void);
-
-    /* call this initially, and after a mode change */
-    bool Setup(int phoneIdx);
-
-    bool IsReady(void) const {
-        return (mNumViewInfo > 0 && mpViewInfo != NULL);
-    }
-
-    PhoneData* GetPhoneData(void) const;
-
-    const wxString& GetCurrentMode(void) const { return mCurrentMode; }
-    void SetCurrentMode(const wxString& mode) { mCurrentMode = mode; }
-    void SetCurrentMode(const char* mode) { mCurrentMode = wxString::FromAscii(mode); }
-
-    DeviceManager* GetDeviceManager(void) { return &mDeviceManager; }
-
-    /* this is called when the phone data is reloaded */
-    void DevicesRescanned(void);
-
-    void Vibrate(int vibrateOn);
-
-private:
-    /*
-     * Hold some information about the "views" being shown in our window.
-     */
-    class ViewInfo {
-    public:
-        ViewInfo(void)
-            : mX(-1), mY(-1), mDisplayX(-1), mDisplayY(-1),
-              mWidth(-1), mHeight(-1), mDisplayIndex(-1)
-        {}
-        ~ViewInfo(void) {}
-
-        int GetX(void) const { return mX; }
-        int GetY(void) const { return mY; }
-        int GetDisplayX(void) const { return mDisplayX; }
-        int GetDisplayY(void) const { return mDisplayY; }
-        int GetWidth(void) const { return mWidth; }
-        int GetHeight(void) const { return mHeight; }
-        int GetDisplayIndex(void) const { return mDisplayIndex; }
-
-        void SetX(int val) { mX = val; }
-        void SetY(int val) { mY = val; }
-        void SetDisplayX(int val) { mDisplayX = val; }
-        void SetDisplayY(int val) { mDisplayY = val; }
-        void SetWidth(int val) { mWidth = val; }
-        void SetHeight(int val) { mHeight = val; }
-        void SetDisplayIndex(int val) { mDisplayIndex = val; }
-
-    private:
-        int     mX, mY;                 // view offset within PhoneWindow
-        int     mDisplayX, mDisplayY;   // display offset within view
-        int     mWidth, mHeight;        // view dimensions
-
-        int     mDisplayIndex;          // index into mpDeviceWindow
-    };
-
-    /*
-     * Hold information about currently pressed keys.
-     */
-    class KeyInfo {
-    public:
-        KeyInfo(void) : mKeyCode(kKeyCodeUnknown) {}
-        KeyInfo(const KeyInfo& src) {
-            mKeyCode = src.mKeyCode;
-        }
-        ~KeyInfo(void) {}
-
-        KeyInfo& operator=(const KeyInfo& src) {
-            if (this != &src) {
-                mKeyCode = src.mKeyCode;
-            }
-            return *this;
-        }
-
-        KeyCode GetKeyCode(void) const { return mKeyCode; }
-        void SetKeyCode(KeyCode keyCode) { mKeyCode = keyCode; }
-
-        //PhoneButton* GetPhoneButton(void) const { return mpButton; }
-        //void SetPhoneButton(PhoneButton* pButton) { mpButton = pButton; }
-
-    private:
-        KeyCode    mKeyCode;
-        //PhoneButton*        mpButton;
-    };
-
-    void OnActivate(wxActivateEvent& event);
-    void OnMove(wxMoveEvent& event);
-    void OnClose(wxCloseEvent& event);
-    void OnTimer(wxTimerEvent& event);
-    void OnKeyDown(wxKeyEvent& event);
-    void OnKeyUp(wxKeyEvent& event);
-    void OnErase(wxEraseEvent& event);
-    void OnPaint(wxPaintEvent& WXUNUSED(event));
-    void OnMouseLeftDown(wxMouseEvent& event);
-    void OnMouseLeftUp(wxMouseEvent& event);
-    void OnMouseRightDown(wxMouseEvent& event);
-    void OnMouseRightUp(wxMouseEvent& event);
-    void OnMouseMotion(wxMouseEvent& event);
-    void OnMouseLeaveWindow(wxMouseEvent& WXUNUSED(event));
-    bool GetTouchPosition(const wxMouseEvent& event, int* pScreenX,
-        int* pScreenY);
-
-    bool GetDimensions(PhoneData* pPhoneData, PhoneView* pPhoneView,
-        ViewInfo* pDim);
-    int ConvertKeyCode(int wxKeyCode) const;
-
-    /* press a key on the device */
-    void AddPressedKey(KeyCode keyCode);
-    /* release a key on the device */
-    void RemovePressedKey(KeyCode keyCode);
-    /* "raise" all keys */
-    void ClearPressedKeys(void);
-    /* determine whether a key is down */
-    bool IsKeyPressed(KeyCode keyCode);
-
-    /* manage the device runtime */
-    DeviceManager   mDeviceManager;
-
-    /* button mouse-over highlight handling */
-    int             mpMOHViewIndex;     // mouse is in this view
-    PhoneButton*    mpMOHButton;        //   over this button
-    KeyCode         mMouseKeySent;     // to handle "key up" for mouse button
-
-    /* handle multiple simultaneous key presses */
-    android::List<KeyInfo>  mPressedKeys;
-    typedef android::List<KeyInfo>::iterator ListIter;
-
-    /* ViewInfos, 1:1 with PhoneView entries for the current mode */
-    ViewInfo*       mpViewInfo;         // array of view data
-    int             mNumViewInfo;       // #of elements in mpViewInfo
-
-    /* DeviceWindows, 1:1 with PhoneDisplay entries for this device */
-    DeviceWindow**  mpDeviceWindow;     // array of pointers to device windows
-    int             mNumDeviceWindows;  // #of device windows
-
-    /* state */
-    int             mPhoneModel;        // index into model list
-    wxString        mCurrentMode;
-
-    bool            mPlacementChecked;  // leave it offscreen if they want
-
-    MainFrame*      mpParent;           // retain pointer to parent window
-
-    enum { kVibrateTimerId = 1010 };
-    wxTimer         mTimer;
-    int             mVibrateX;
-
-    /* touchscreen simulation */
-    bool            mTrackingTouch;
-    int             mTouchX;
-    int             mTouchY;
-
-    DECLARE_EVENT_TABLE()
-};
-
-#endif // _SIM_PHONE_WINDOW_H
diff --git a/simulator/app/Preferences.cpp b/simulator/app/Preferences.cpp
deleted file mode 100644
index 039f1ff..0000000
--- a/simulator/app/Preferences.cpp
+++ /dev/null
@@ -1,475 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Preferences file access.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-//# include "wx/wx.h"
-# include "wx/string.h"
-#endif
-
-#include "Preferences.h"
-
-#include "utils.h"
-#include "tinyxml.h"
-
-static const char* kName = "name";
-static const char* kValue = "value";
-
-
-/*
- * Load from a file.
- */
-bool Preferences::Load(const char* fileName)
-{
-    assert(fileName != NULL);
-    printf("SimPref: reading preferences file '%s'\n", fileName);
-
-    // throw out any existing stuff
-    delete mpDoc;
-
-    mpDoc = new TiXmlDocument;
-    if (mpDoc == NULL)
-        return false;
-
-    if (!mpDoc->LoadFile(fileName)) {
-        fprintf(stderr, "SimPref: ERROR: failed loading '%s'\n", fileName);
-        if (mpDoc->ErrorRow() != 0)
-            fprintf(stderr, "    XML: %s (row=%d col=%d)\n",
-                mpDoc->ErrorDesc(), mpDoc->ErrorRow(), mpDoc->ErrorCol());
-        else
-            fprintf(stderr, "    XML: %s\n", mpDoc->ErrorDesc());
-        goto fail;
-    }
-
-    TiXmlNode* pPrefs;
-    pPrefs = mpDoc->FirstChild("prefs");
-    if (pPrefs == NULL) {
-        fprintf(stderr, "SimPref: ERROR: could not find <prefs> in '%s'\n",
-            fileName);
-        goto fail;
-    }
-
-    // set defaults for anything we haven't set explicitly
-    SetDefaults();
-
-    return true;
-
-fail:
-    delete mpDoc;
-    mpDoc = NULL;
-    return false;
-}
-
-/*
- * Save to a file.
- */
-bool Preferences::Save(const char* fileName)
-{
-    assert(fileName != NULL);
-
-    if (mpDoc == NULL)
-        return false;
-
-    if (!mpDoc->SaveFile(fileName)) {
-        fprintf(stderr, "SimPref: ERROR: failed saving '%s': %s\n",
-            fileName, mpDoc->ErrorDesc());
-        return false;
-    }
-
-    mDirty = false;
-
-    return true;
-}
-
-/*
- * Create an empty collection of preferences.
- */
-bool Preferences::Create(void)
-{
-    static const char* docBase =
-        "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n"
-        "<!-- Android device simulator preferences -->\n"
-        "<!-- This file is updated by the simulator -->\n"
-        "<prefs>\n"
-        "</prefs>\n";
-
-    // throw out any existing stuff
-    delete mpDoc;
-
-    // alloc and initialize
-    mpDoc = new TiXmlDocument;
-    if (mpDoc == NULL)
-        return false;
-
-    if (!mpDoc->Parse(docBase)) {
-        fprintf(stderr, "SimPref: bad docBase: %s\n", mpDoc->ErrorDesc());
-        return false;
-    }
-
-    SetDefaults();
-    mDirty = true;      // should already be, mbut make sure
-    return true;
-}
-
-/*
- * Add default values to XML doc.
- *
- * This isn't strictly necessary, because the functions that are interested
- * in the preferences can set appropriate defaults themselves when the
- * "get" function returns "false".  However, in some cases a preference
- * can be interesting to more than one function, and you either have to
- * cut & paste the default value or write a "get default for xxx" function.
- *
- * We want this to work even if they already have an older config file, so
- * this only sets values that don't already exist.
- */
-void Preferences::SetDefaults(void)
-{
-    /* table of default values */
-    static const struct {
-        const char* type;
-        const char* name;
-        const char* value;
-    } kDefault[] = {
-        { "pref",           "auto-power-on",        "true" },
-        { "pref",           "debug",                "false" },
-        { "pref",           "valgrind",             "false" },
-        { "pref",           "check-jni",            "true" },
-        { "pref",           "enable-sound",         "true" },
-        { "pref",           "enable-fake-camera",   "true" },
-        { "pref",           "java-vm",              "Dalvik" },
-        /* goobuntu dapper needed LD_ASSUME_KERNEL or gdb choked badly */
-        { "pref",           "ld-assume-kernel",     "" /*2.4.19*/ },
-        { "pref",           "launch-command",
-            "xterm -geom 80x60+10+10 -sb -title Simulator -e" },
-        { "pref",           "launch-wrapper-args",  "-wait" },
-    };
-    TiXmlNode* pPrefs;
-
-    assert(mpDoc != NULL);
-
-    pPrefs = mpDoc->FirstChild("prefs");
-
-    /*
-     * Look up the name.  If it doesn't exist, add it.
-     */
-    for (int i = 0; i < NELEM(kDefault); i++) {
-        TiXmlNode* pNode = _FindNode(kDefault[i].type, kDefault[i].name);
-
-        if (pNode == NULL) {
-            TiXmlElement elem(kDefault[i].type);
-            elem.SetAttribute(kName, kDefault[i].name);
-            elem.SetAttribute(kValue, kDefault[i].value);
-            pPrefs->InsertEndChild(elem);
-
-            printf("SimPref: added default <%s> '%s'='%s'\n",
-                kDefault[i].type, kDefault[i].name, kDefault[i].value);
-        } else {
-            printf("SimPref: found existing <%s> '%s'\n", 
-                kDefault[i].type, kDefault[i].name);
-        }
-    }
-}
-
-static TiXmlNode* get_next_node(TiXmlNode* pNode)
-{
-  if (!pNode->NoChildren())
-  {
-      pNode = pNode->FirstChild();
-  }
-  else if (pNode->NoChildren() && 
-           (pNode->NextSibling() == NULL))
-  {
-      pNode = pNode->Parent()->NextSibling();
-  }
-  else
-  {
-      pNode = pNode->NextSibling();
-  }
-  return pNode;
-}
-
-/*
- * Returns the node with element type and name specified
- *
- * WARNING: this searches through the tree and returns the first matching
- * node.
- */
-TiXmlNode* Preferences::_FindNode(const char* type, const char* str) const
-{
-    assert((type != NULL) && (str != NULL));
-    TiXmlNode* pRoot;
-    TiXmlNode* pNode;
-
-    pRoot = mpDoc->FirstChild("prefs");
-    assert(pRoot != NULL);
-
-    for (pNode = pRoot->FirstChild(); pNode != NULL;)
-    {
-        if (pNode->Type() != TiXmlNode::ELEMENT ||
-            strcasecmp(pNode->Value(), type) != 0)
-        {
-            pNode = get_next_node(pNode);
-            continue;
-        }
-
-        TiXmlElement* pElem = pNode->ToElement();
-        assert(pElem != NULL);
-
-        const char* name = pElem->Attribute(kName);
-
-        /* 1. If the name is blank, something is wrong with the config file
-         * 2. If the name matches the passed in string, we found the node
-         * 3. If the node has children, descend another level
-         * 4. If there are no children and no siblings of the node, go up a level
-         * 5. Otherwise, grab the next sibling
-         */
-        if (name == NULL)
-        {
-            fprintf(stderr, "WARNING: found <%s> without name\n", type);
-            continue;
-        }
-        else if (strcasecmp(name, str) == 0)
-        {
-            return pNode;
-        }
-        else 
-        {
-            pNode = get_next_node(pNode);
-        }
-    }
-
-    return NULL;
-}
-
-/*
- * Locate the specified preference.
- */
-TiXmlNode* Preferences::FindPref(const char* str) const
-{
-    TiXmlNode* pNode = _FindNode("pref", str);
-    return pNode;
-}
-
-/*
- * Like FindPref(), but returns a TiXmlElement.
- */
-TiXmlElement* Preferences::FindPrefElement(const char* str) const
-{
-    TiXmlNode* pNode;
-
-    pNode = FindPref(str);
-    if (pNode != NULL)
-        return pNode->ToElement();
-    return NULL;
-}
-
-/*
- * Add a new preference entry with a blank entry for value.  Returns a
- * pointer to the new element.
- */
-TiXmlElement* Preferences::AddPref(const char* str)
-{
-    assert(FindPref(str) == NULL);
-
-    TiXmlNode* pPrefs;
-
-    pPrefs = mpDoc->FirstChild("prefs");
-    assert(pPrefs != NULL);
-
-    TiXmlElement elem("pref");
-    elem.SetAttribute(kName, str);
-    elem.SetAttribute(kValue, "");
-    pPrefs->InsertEndChild(elem);
-
-    TiXmlNode* pNewPref = FindPref(str);
-    return pNewPref->ToElement();
-}
-
-/*
- * Remove a node from the tree
- */
-bool Preferences::_RemoveNode(TiXmlNode* pNode)
-{
-    if (pNode == NULL)
-        return false;
-
-    TiXmlNode* pParent = pNode->Parent();
-    if (pParent == NULL)
-        return false;
-
-    pParent->RemoveChild(pNode);
-    mDirty = true;
-    return true;
-}
-
-/*
- * Remove a preference entry.
- */
-bool Preferences::RemovePref(const char* delName)
-{
-    return _RemoveNode(FindPref(delName));
-}
-
-/*
- * Test for existence.
- */
-bool Preferences::Exists(const char* name) const
-{
-    TiXmlElement* pElem = FindPrefElement(name);
-    return (pElem != NULL);
-}
-
-/*
- * Internal implemenations for getting values 
- */
-bool Preferences::_GetBool(TiXmlElement* pElem, bool* pVal) const
-{
-    if (pElem != NULL) 
-    {
-        const char* str = pElem->Attribute(kValue);
-        if (str != NULL) 
-        {
-            if (strcasecmp(str, "true") == 0)
-                *pVal = true;
-            else if (strcasecmp(str, "false") == 0)
-                *pVal = false;
-            else 
-            {
-                printf("SimPref: evaluating as bool name='%s' val='%s'\n",
-                pElem->Attribute(kName), str);
-                return false;
-            }
-            return true;
-        }
-    }
-    return false;
-}
-
-bool Preferences::_GetInt(TiXmlElement* pElem, int* pInt) const
-{
-    int val;
-    if (pElem != NULL && pElem->Attribute(kValue, &val) != NULL) {
-        *pInt = val;
-        return true;
-    }
-    return false;
-}
-
-bool Preferences::_GetDouble(TiXmlElement* pElem, double* pDouble) const
-{
-    double val;
-    if (pElem != NULL && pElem->Attribute(kValue, &val) != NULL) {
-        *pDouble = val;
-        return true;
-    }
-    return false;
-}
-
-bool Preferences::_GetString(TiXmlElement* pElem, wxString& str) const
-{
-    const char* val;
-    if (pElem != NULL) {
-        val = pElem->Attribute(kValue);
-        if (val != NULL) {
-            str = wxString::FromAscii(val);
-            return true;
-        }
-    }
-    return false;
-}
-
-/*
- * Get a value.  Do not disturb "*pVal" unless we have something to return.
- */
-bool Preferences::GetBool(const char* name, bool* pVal) const
-{
-    return _GetBool(FindPrefElement(name), pVal);
-}
-
-bool Preferences::GetInt(const char* name, int* pInt) const
-{
-    return _GetInt(FindPrefElement(name), pInt);
-}
-
-bool Preferences::GetDouble(const char* name, double* pDouble) const
-{
-    return _GetDouble(FindPrefElement(name), pDouble);
-}
-
-bool Preferences::GetString(const char* name, char** pVal) const
-{
-    wxString str = wxString::FromAscii(*pVal);
-    if (_GetString(FindPrefElement(name), str))
-    {
-        *pVal = android::strdupNew(str.ToAscii());
-        return true;
-    }
-    return false;   
-}
-
-bool Preferences::GetString(const char* name, wxString& str) const
-{
-    return _GetString(FindPrefElement(name), str);
-}
-
-/*
- * Set a value.  If the preference already exists, and the value hasn't
- * changed, don't do anything.  This avoids setting the "dirty" flag
- * unnecessarily.
- */
-void Preferences::SetBool(const char* name, bool val)
-{
-    bool oldVal;
-    if (GetBool(name, &oldVal) && val == oldVal)
-        return;
-
-    SetString(name, val ? "true" : "false");
-    mDirty = true;
-}
-
-void Preferences::SetInt(const char* name, int val)
-{
-    int oldVal;
-    if (GetInt(name, &oldVal) && val == oldVal)
-        return;
-
-    TiXmlElement* pElem = FindPrefElement(name);
-    if (pElem == NULL)
-        pElem = AddPref(name);
-    pElem->SetAttribute(kValue, val);
-    mDirty = true;
-}
-
-void Preferences::SetDouble(const char* name, double val)
-{
-    double oldVal;
-    if (GetDouble(name, &oldVal) && val == oldVal)
-        return;
-
-    TiXmlElement* pElem = FindPrefElement(name);
-    if (pElem == NULL)
-        pElem = AddPref(name);
-    pElem->SetDoubleAttribute(kValue, val);
-    mDirty = true;
-}
-
-void Preferences::SetString(const char* name, const char* val)
-{
-    wxString oldVal;
-    if (GetString(name, /*ref*/oldVal) && strcmp(oldVal.ToAscii(), val) == 0)
-        return;
-
-    TiXmlElement* pElem = FindPrefElement(name);
-    if (pElem == NULL)
-        pElem = AddPref(name);
-    pElem->SetAttribute(kValue, val);
-    mDirty = true;
-}
-
-
diff --git a/simulator/app/Preferences.h b/simulator/app/Preferences.h
deleted file mode 100644
index 91c35de..0000000
--- a/simulator/app/Preferences.h
+++ /dev/null
@@ -1,104 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Preferences file access.
-//
-#ifndef _SIM_PREFERENCES_H
-#define _SIM_PREFERENCES_H
-
-#include "tinyxml.h"
-
-/*
- * This class provides access to a preferences file.  It's possible to
- * have more than one instance, though it's probably unwise to have multiple
- * objects for the same file on disk.
- *
- * All value are stored as strings.  The class doesn't really try to
- * enforce type safety, but it will complain if you try to do something
- * nonsensical (like convert "foo" to an integer).
- */
-class Preferences {
-public:
-    Preferences(void) :
-        mpDoc(NULL), mDirty(false)
-        {}
-    ~Preferences(void) {
-        delete mpDoc;
-    }
-
-    /* load all preferences from a file */
-    bool Load(const char* fileName);
-
-    /* save all preferences to a file */
-    bool Save(const char* fileName);
-
-    /* create new preferences set (use when file does not exist) */
-    bool Create(void);
-
-    /*
-     * Retrieve a value from the preferences database.
-     *
-     * These return "false" if the value was not found or could not be
-     * converted to the expected type.  The value pointed to be the second
-     * arg is guaranteed to be left undisturbed in this case.
-     *
-     * The value set by GetString(const char*, char**) will be set to
-     * newly-allocated storage that must be freed with "delete[]".  This
-     * is done instead of returning a const char* because it's unclear
-     * what guarantees TinyXml makes wrt string lifetime (especially in
-     * a multithreaded environment).
-     */
-    bool GetBool(const char* name, bool* pVal) const;
-    bool GetInt(const char* name, int* pInt) const;
-    bool GetDouble(const char* name, double* pDouble) const;
-    bool GetString(const char* name, char** pVal) const;
-    bool GetString(const char* name, wxString& str) const;
-
-    /*
-     * Set a value in the database.
-     */
-    void SetBool(const char* name, bool val);
-    void SetInt(const char* name, int val);
-    void SetDouble(const char* name, double val);
-    void SetString(const char* name, const char* val);
-
-    /*
-     * Just test for existence.
-     */
-    bool Exists(const char* name) const;
-    
-    /*
-     * Remove a <pref> from the config file.
-     */
-    bool RemovePref(const char* name);
-    
-    /*
-     * Get the value of the "dirty" flag.
-     */
-    bool GetDirty(void) const { return mDirty; }
-
-private:
-    /* Implementation of getters */
-    bool _GetBool(TiXmlElement* pElem, bool* pVal) const;
-    bool _GetInt(TiXmlElement* pElem, int* pInt) const;
-    bool _GetDouble(TiXmlElement* pElem, double* pDouble) const;
-    bool _GetString(TiXmlElement* pElem, wxString& str) const;
-    
-    /* this can be used to generate some defaults */
-    void SetDefaults(void);
-
-    /* locate the named preference */
-    TiXmlNode* _FindNode(const char* type, const char* name) const;
-    TiXmlNode* FindPref(const char* str) const;
-    /* like FindPref, but returns a TiXmlElement */
-    TiXmlElement* FindPrefElement(const char* str) const;
-    /* add a new preference entry */
-    TiXmlElement* AddPref(const char* str);
-    /* removes a node */
-    bool _RemoveNode(TiXmlNode* pNode);
-    
-    TiXmlDocument*  mpDoc;
-    bool            mDirty;
-};
-
-#endif // _SIM_PREFERENCES_H
diff --git a/simulator/app/PrefsDialog.cpp b/simulator/app/PrefsDialog.cpp
deleted file mode 100644
index e146a56..0000000
--- a/simulator/app/PrefsDialog.cpp
+++ /dev/null
@@ -1,292 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Preferences modal dialog.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-
-#include "PrefsDialog.h"
-#include "Preferences.h"
-#include "MyApp.h"
-#include "Resource.h"
-
-BEGIN_EVENT_TABLE(PrefsDialog, wxDialog)
-END_EVENT_TABLE()
-
-/*
- * Constructor.
- */
-PrefsDialog::PrefsDialog(wxWindow* parent)
-    : wxDialog(parent, IDD_PREFS, wxT("Preferences"), wxDefaultPosition,
-        wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER ),
-      mAutoPowerOn(false),
-      mGammaCorrection(1.0),
-      mEnableSound(true),
-      mEnableFakeCamera(true),
-      mLogLevel(0)
-{
-    LoadPreferences();   
-    CreateControls();
-}
-
-/*
- * Destructor.  Not much to do.
- */
-PrefsDialog::~PrefsDialog()
-{
-}
-
-/*
- * Create all of the pages and add them to the notebook.
- */
-void PrefsDialog::CreateControls(void)
-{
-    wxBoxSizer* mainSizer = new wxBoxSizer(wxVERTICAL);
-    wxBoxSizer* okCancelSizer = new wxBoxSizer(wxHORIZONTAL);
-    mNotebook.Create(this, wxID_ANY);
-    wxPanel* page;
-
-    /* pages added to notebook are owned by notebook */
-    page = CreateSimulatorPage(&mNotebook);
-    mNotebook.AddPage(page, wxT("Simulator"), true);       // selected page
-    page = CreateRuntimePage(&mNotebook);
-    mNotebook.AddPage(page, wxT("Runtime"), false);
-
-    wxButton* cancel = new wxButton(this, wxID_CANCEL, wxT("&Cancel"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    okCancelSizer->Add(cancel, 0, wxALL | wxALIGN_RIGHT, kInterSpacing);
-
-    wxButton* ok = new wxButton(this, wxID_OK, wxT("&OK"),
-        wxDefaultPosition, wxDefaultSize, 0);
-    okCancelSizer->Add(ok, 0, wxALL | wxALIGN_RIGHT, kInterSpacing);
-
-    mainSizer->Add(&mNotebook, 1, wxEXPAND);
-    mainSizer->Add(okCancelSizer, 0, wxALIGN_RIGHT);
-
-    SetSizer(mainSizer);
-
-    mainSizer->Fit(this);           // shrink-to-fit
-    mainSizer->SetSizeHints(this);  // define minimum size
-}
-
-/*
- * Load preferences from config file
- */
-void PrefsDialog::LoadPreferences(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    /*
-     * Load preferences.
-     */
-    mConfigFile = ((MyApp*)wxTheApp)->GetConfigFileName();
-
-    pPrefs->GetDouble("gamma", &mGammaCorrection);
-    pPrefs->GetString("debugger", /*ref*/ mDebugger);
-    pPrefs->GetString("valgrinder", /*ref*/ mValgrinder);
-    pPrefs->GetBool("auto-power-on", &mAutoPowerOn);
-    pPrefs->GetBool("enable-sound", &mEnableSound);
-    pPrefs->GetBool("enable-fake-camera", &mEnableFakeCamera);
-}
-
-/*
- * Transfer data from our members to the window controls.
- *
- * First we have to pull the data out of the preferences database.
- * Anything that hasn't already been added with a default value will
- * be given a default here, which may or may not match the default
- * behavior elsewhere.  The best solution to this is to define the
- * default when the preferences file is created or read, so that we're
- * never left guessing here.
- */
-bool PrefsDialog::TransferDataToWindow(void)
-{
-    /*
-     * Do standard dialog setup.
-     */
-    wxTextCtrl* configFileName = (wxTextCtrl*) FindWindow(IDC_SPREFS_CONFIG_NAME);
-    wxTextCtrl* debugger = (wxTextCtrl*) FindWindow(IDC_SPREFS_DEBUGGER);
-    wxTextCtrl* valgrinder = (wxTextCtrl*) FindWindow(IDC_SPREFS_VALGRINDER);
-    wxCheckBox* autoPowerOn = (wxCheckBox*) FindWindow(IDC_SPREFS_AUTO_POWER_ON);
-    wxCheckBox* enableSound = (wxCheckBox*) FindWindow(IDC_RPREFS_ENABLE_SOUND);
-    wxCheckBox* enableFakeCamera = (wxCheckBox*) FindWindow(IDC_RPREFS_ENABLE_FAKE_CAMERA);
-
-    wxTextCtrl* gamma = (wxTextCtrl*) FindWindow(IDC_RPREFS_GAMMA);
-
-    configFileName->SetValue(mConfigFile);
-    debugger->SetValue(mDebugger);
-    valgrinder->SetValue(mValgrinder);
-    autoPowerOn->SetValue(mAutoPowerOn);
-    enableSound->SetValue(mEnableSound);
-    enableFakeCamera->SetValue(mEnableFakeCamera);
-
-    wxString tmpStr;
-    tmpStr.Printf(wxT("%.3f"), mGammaCorrection);
-    gamma->SetValue(tmpStr);
-
-    return true;
-}
-
-/*
- * Transfer and validate data from the window controls.
- *
- * This doesn't get called if the user cancels out of the dialog.
- */
-bool PrefsDialog::TransferDataFromControls(void)
-{
-    /*
-     * Do standard dialog export.
-     *
-     * We should error-check all of these.
-     */
-    // configName is read-only, don't need it here
-    wxTextCtrl* debugger = (wxTextCtrl*) FindWindow(IDC_SPREFS_DEBUGGER);
-    wxTextCtrl* valgrinder = (wxTextCtrl*) FindWindow(IDC_SPREFS_VALGRINDER);
-    wxCheckBox* autoPowerOn = (wxCheckBox*) FindWindow(IDC_SPREFS_AUTO_POWER_ON);
-    wxCheckBox* enableSound = (wxCheckBox*) FindWindow(IDC_RPREFS_ENABLE_SOUND);
-    wxCheckBox* enableFakeCamera = (wxCheckBox*) FindWindow(IDC_RPREFS_ENABLE_FAKE_CAMERA);
-
-    wxTextCtrl* gamma = (wxTextCtrl*) FindWindow(IDC_RPREFS_GAMMA);
-
-    mDebugger = debugger->GetValue();
-    mValgrinder = valgrinder->GetValue();
-    mAutoPowerOn = autoPowerOn->GetValue();
-    mEnableSound = enableSound->GetValue();
-    mEnableFakeCamera = enableFakeCamera->GetValue();
-
-    wxString tmpStr;
-    tmpStr = gamma->GetValue();
-    bool toDouble = tmpStr.ToDouble(&mGammaCorrection);    // returns 0.0 on err; use strtof()?
-
-    if (!toDouble || mGammaCorrection <= 0.0 || mGammaCorrection > 2.0) {
-        wxMessageBox(wxT("Bad value for gamma -- must be > 0.0 and <= 2.0"),
-            wxT("Hoser"), wxOK, this);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Transfer preferences to config file
- */
-bool PrefsDialog::TransferDataFromWindow(void)
-{
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    assert(pPrefs != NULL);
-
-    /*
-     * Grab the information from the controls and save in member field
-     */
-
-    if (!TransferDataFromControls())
-        return false;
-
-    pPrefs->SetString("debugger", mDebugger.ToAscii());
-    pPrefs->SetString("valgrinder", mValgrinder.ToAscii());
-    pPrefs->SetBool("auto-power-on", mAutoPowerOn);
-    pPrefs->SetBool("enable-sound", mEnableSound);
-    pPrefs->SetBool("enable-fake-camera", mEnableFakeCamera);
-
-    pPrefs->SetDouble("gamma", mGammaCorrection);
-
-    return true;
-}
-
-
-/*
- * Create the Simulator Preferences page.
- */
-wxPanel* PrefsDialog::CreateSimulatorPage(wxBookCtrlBase* parent)
-{
-    wxPanel* panel = new wxPanel(parent);
-
-    wxStaticText* configNameDescr = new wxStaticText(panel, wxID_STATIC,
-        wxT("Config file:"));
-    wxTextCtrl* configName = new wxTextCtrl(panel, IDC_SPREFS_CONFIG_NAME,
-        wxT(""), wxDefaultPosition, wxDefaultSize, wxTE_READONLY);
-    // make it visibly different; unfortunately this kills scroll, copy&paste
-    configName->Enable(false);
-
-    wxStaticText* debuggerDescr = new wxStaticText(panel, wxID_STATIC,
-        wxT("Debugger:"));
-    wxTextCtrl* debugger = new wxTextCtrl(panel, IDC_SPREFS_DEBUGGER);
-
-    wxStaticText* valgrinderDescr = new wxStaticText(panel, wxID_STATIC,
-        wxT("Valgrind:"));
-    wxTextCtrl* valgrinder = new wxTextCtrl(panel, IDC_SPREFS_VALGRINDER);
-
-    wxCheckBox* autoPowerOn = new wxCheckBox(panel, IDC_SPREFS_AUTO_POWER_ON,
-        wxT("Boot runtime when simulator starts"));
-
-    wxBoxSizer* sizerPanel = new wxBoxSizer(wxVERTICAL);
-    sizerPanel->Add(kMinWidth, kEdgeSpacing);       // forces minimum width
-    sizerPanel->Add(configNameDescr);
-    sizerPanel->Add(configName, 0, wxEXPAND);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(debuggerDescr);
-    sizerPanel->Add(debugger, 0, wxEXPAND);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(valgrinderDescr);
-    sizerPanel->Add(valgrinder, 0, wxEXPAND);
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(autoPowerOn);
-    sizerPanel->AddSpacer(kInterSpacing);
-
-    wxBoxSizer* horizIndent = new wxBoxSizer(wxHORIZONTAL);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    horizIndent->Add(sizerPanel, wxSHAPED);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    panel->SetSizer(horizIndent);
-
-    return panel;
-}
-
-/*
- * Create the Runtime Preferences page.
- */
-wxPanel* PrefsDialog::CreateRuntimePage(wxBookCtrlBase* parent)
-{
-    wxPanel* panel = new wxPanel(parent);
-
-    wxStaticText* gammaStrDescr = new wxStaticText(panel, wxID_STATIC,
-        wxT("Gamma correction:"));
-    wxTextCtrl* gammaStr = new wxTextCtrl(panel, IDC_RPREFS_GAMMA);
-
-    wxBoxSizer* gammaSizer = new wxBoxSizer(wxHORIZONTAL);
-    gammaSizer->Add(gammaStrDescr, 0, wxALIGN_CENTER_VERTICAL);
-    gammaSizer->AddSpacer(kInterSpacing);
-    gammaSizer->Add(gammaStr);
-
-    wxBoxSizer* sizerPanel = new wxBoxSizer(wxVERTICAL);
-    sizerPanel->Add(kMinWidth, kEdgeSpacing);       // forces minimum width
-    sizerPanel->Add(gammaSizer);
-    sizerPanel->AddSpacer(kInterSpacing);
-
-    wxCheckBox* enableSound = new wxCheckBox(panel, IDC_RPREFS_ENABLE_SOUND,
-        wxT("Enable Sound"));
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(enableSound);
-
-    wxCheckBox* enableFakeCamera = new wxCheckBox(panel, IDC_RPREFS_ENABLE_FAKE_CAMERA,
-        wxT("Enable Fake Camera"));
-    sizerPanel->AddSpacer(kInterSpacing);
-    sizerPanel->Add(enableFakeCamera);
-
-    wxBoxSizer* horizIndent = new wxBoxSizer(wxHORIZONTAL);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    horizIndent->Add(sizerPanel, wxEXPAND);
-    horizIndent->AddSpacer(kEdgeSpacing);
-    panel->SetSizer(horizIndent);
-
-    return panel;
-}
-
diff --git a/simulator/app/PrefsDialog.h b/simulator/app/PrefsDialog.h
deleted file mode 100644
index 250f79e..0000000
--- a/simulator/app/PrefsDialog.h
+++ /dev/null
@@ -1,54 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Prefs modal dialog.
-//
-#ifndef _SIM_PREFS_DIALOG_H
-#define _SIM_PREFS_DIALOG_H
-
-/*
- * Declaration of preferences dialog.  This class defines the outer
- * wrapper as well as all of the pages.
- */
-class PrefsDialog : public wxDialog {
-    //DECLARE_CLASS(PrefsDialog)    // shown in book, but causes link problems
-    DECLARE_EVENT_TABLE()
-
-public:
-    PrefsDialog(wxWindow* parent);
-    virtual ~PrefsDialog();
-
-    void CreateControls(void);
-
-    wxString    mConfigFile;
-
-private:
-    bool TransferDataToWindow(void);
-    bool TransferDataFromWindow(void);
-    bool TransferDataFromControls(void);
-    void LoadPreferences(void);
-    
-    wxPanel* CreateSimulatorPage(wxBookCtrlBase* parent);
-    wxPanel* CreateRuntimePage(wxBookCtrlBase* parent);
-
-    /* main notebook; for aesthetic reasons we may want a Choicebook */
-    wxNotebook    mNotebook;
-
-    /* Global simulator options */
-    wxString    mDebugger;
-    wxString    mValgrinder;
-    bool        mAutoPowerOn;
-    // log window size?
-
-    /* Global runtime options */
-    double      mGammaCorrection;
-    bool        mEnableSound;
-    bool        mEnableFakeCamera;
-    int         mLogLevel;
-
-    enum {
-        kMinWidth = 300,        // minimum prefs dialog width, in pixels
-    };
-};
-
-#endif // _SIM_PREFS_DIALOG_H
diff --git a/simulator/app/PropertyServer.cpp b/simulator/app/PropertyServer.cpp
deleted file mode 100644
index 0d6054f..0000000
--- a/simulator/app/PropertyServer.cpp
+++ /dev/null
@@ -1,467 +0,0 @@
-//
-// Copyright 2007 The Android Open Source Project
-//
-// Property sever.  Mimics behavior provided on the device by init(8) and
-// some code built into libc.
-//
-    
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-    
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-#include "wx/image.h"
-    
-#include "PropertyServer.h"
-#include "MyApp.h"
-#include "Preferences.h"
-#include "MainFrame.h"
-#include "utils.h"
-
-#include <stdlib.h>
-#include <unistd.h>
-#include <string.h>
-#include <errno.h>
-#include <assert.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <sys/stat.h>
-#include <sys/un.h>
-
-
-using namespace android;
-
-const char* PropertyServer::kPropCheckJni = "ro.kernel.android.checkjni";
-
-/*
- * Destructor.
- */
-PropertyServer::~PropertyServer(void)
-{
-    if (IsRunning()) {
-        // TODO: cause thread to stop, then Wait for it
-    }
-    printf("Sim: in ~PropertyServer()\n");
-}
-
-/*
- * Create and run the thread.
- */
-bool PropertyServer::StartThread(void)
-{
-    if (Create() != wxTHREAD_NO_ERROR) {
-        fprintf(stderr, "Sim: ERROR: can't create PropertyServer thread\n");
-        return false;
-    }
-
-    Run();
-    return true;
-}
-
-
-/*
- * Clear out the list.
- */
-void PropertyServer::ClearProperties(void)
-{
-    typedef List<Property>::iterator PropIter;
-
-    for (PropIter pi = mPropList.begin(); pi != mPropList.end(); ++pi) {
-        pi = mPropList.erase(pi);
-    }
-}
-
-/*
- * Set default values for several properties.
- */
-void PropertyServer::SetDefaultProperties(void)
-{
-    static const struct {
-        const char* key;
-        const char* value;
-    } propList[] = {
-        { "net.bt.name", "Android" },
-        { "ro.kernel.mem", "60M" },
-        { "ro.kernel.board_sardine.version", "4" },
-        { "ro.kernel.console", "null" },
-        { "ro.build.id", "engineering" },
-        { "ro.build.date", "Wed Nov 28 07:44:14 PST 2007" },
-        { "ro.build.date.utc", "1196264654" },
-        { "ro.build.type", "eng" },
-        { "ro.product.device", "simulator" /*"sooner"*/ },
-        { "ro.product.brand", "generic" },
-        { "ro.build.user", "fadden" },
-        { "ro.build.host", "marathon" },
-        { "ro.config.nocheckin", "yes" },
-        { "ro.product.manufacturer", "" },
-        { "ro.radio.use-ppp", "no" },
-        { "ro.FOREGROUND_APP_ADJ", "0" },
-        { "ro.VISIBLE_APP_ADJ", "1" },
-        { "ro.SECONDARY_SERVER_ADJ", "2" },
-        { "ro.HIDDEN_APP_MIN_ADJ", "7" },
-        { "ro.CONTENT_PROVIDER_ADJ", "14" },
-        { "ro.EMPTY_APP_ADJ", "15" },
-        { "ro.FOREGROUND_APP_MEM", "1536" },
-        { "ro.VISIBLE_APP_MEM", "2048" },
-        { "ro.SECONDARY_SERVER_MEM", "4096" },
-        { "ro.HIDDEN_APP_MEM", "8192" },
-        { "ro.EMPTY_APP_MEM", "16384" },
-        //{ "init.svc.adbd", "running" },       // causes ADB-JDWP
-        { "init.svc.usbd", "running" },
-        { "init.svc.debuggerd", "running" },
-        { "init.svc.ril-daemon", "running" },
-        { "init.svc.zygote", "running" },
-        { "init.svc.runtime", "running" },
-        { "init.svc.dbus", "running" },
-        { "init.svc.pppd_gprs", "running" },
-        { "adb.connected", "0" },
-        //{ "use-adb-networking", "1" },
-        /*
-        { "status.battery.state", "Slow" },
-        { "status.battery.level", "5" },
-        { "status.battery.level_raw", "50" },
-        { "status.battery.level_scale", "9" },
-        */
-
-        /* disable the annoying setup wizard */
-        { "app.setupwizard.disable", "1" },
-
-        /* Dalvik options, set by AndroidRuntime */
-        { "dalvik.vm.stack-trace-file", "/data/anr/traces.txt" },
-        //{ "dalvik.vm.execution-mode", "int:portable" },
-        { "dalvik.vm.enableassertions", "all" },    // -ea
-        { "dalvik.vm.dexopt-flags", "" },           // e.g. "v=a,o=v,m=n"
-        { "dalvik.vm.deadlock-predict", "off" },    // -Xdeadlockpredict
-        //{ "dalvik.vm.jniopts", "forcecopy" },       // -Xjniopts
-        { "log.redirect-stdio", "false" },          // -Xlog-stdio
-
-        /* SurfaceFlinger options */
-        { "debug.sf.nobootanimation", "1" },
-        { "debug.sf.showupdates", "0" },
-        { "debug.sf.showcpu", "0" },
-        { "debug.sf.showbackground", "0" },
-        { "debug.sf.showfps", "0" },
-    };
-
-    for (int i = 0; i < NELEM(propList); i++)
-        SetProperty(propList[i].key, propList[i].value);
-
-    Preferences* pPrefs = ((MyApp*)wxTheApp)->GetPrefs();
-    bool doCheckJni = false;
-
-    pPrefs->GetBool("check-jni", &doCheckJni);
-    if (doCheckJni)
-        SetProperty(kPropCheckJni, "1");
-    else
-        SetProperty(kPropCheckJni, "0");
-}
-
-/*
- * Get the value of a property.
- *
- * "valueBuf" must hold at least PROPERTY_VALUE_MAX bytes.
- *
- * Returns "true" if the property was found.
- */
-bool PropertyServer::GetProperty(const char* key, char* valueBuf)
-{
-    typedef List<Property>::iterator PropIter;
-
-    assert(key != NULL);
-    assert(valueBuf != NULL);
-
-    for (PropIter pi = mPropList.begin(); pi != mPropList.end(); ++pi) {
-        Property& prop = *pi;
-        if (strcmp(prop.key, key) == 0) {
-            if (strlen(prop.value) >= PROPERTY_VALUE_MAX) {
-                fprintf(stderr,
-                    "GLITCH: properties table holds '%s' '%s' (len=%d)\n",
-                    prop.key, prop.value, strlen(prop.value));
-                abort();
-            }
-            assert(strlen(prop.value) < PROPERTY_VALUE_MAX);
-            strcpy(valueBuf, prop.value);
-            return true;
-        }
-    }
-
-    //printf("Prop: get [%s] not found\n", key);
-    return false;
-}
-
-/*
- * Set the value of a property, replacing it if it already exists.
- *
- * If "value" is NULL, the property is removed.
- *
- * If the property is immutable, this returns "false" without doing
- * anything.  (Not implemented.)
- */
-bool PropertyServer::SetProperty(const char* key, const char* value)
-{
-    typedef List<Property>::iterator PropIter;
-
-    assert(key != NULL);
-    assert(value != NULL);
-
-    for (PropIter pi = mPropList.begin(); pi != mPropList.end(); ++pi) {
-        Property& prop = *pi;
-        if (strcmp(prop.key, key) == 0) {
-            if (value != NULL) {
-                //printf("Prop: replacing [%s]: [%s] with [%s]\n",
-                //    prop.key, prop.value, value);
-                strcpy(prop.value, value);
-            } else {
-                //printf("Prop: removing [%s]\n", prop.key);
-                mPropList.erase(pi);
-            }
-            return true;
-        }
-    }
-
-    //printf("Prop: adding [%s]: [%s]\n", key, value);
-    Property tmp;
-    strcpy(tmp.key, key);
-    strcpy(tmp.value, value);
-    mPropList.push_back(tmp);
-    return true;
-}
-
-/*
- * Create a UNIX domain socket, carefully removing it if it already
- * exists.
- */
-bool PropertyServer::CreateSocket(const char* fileName)
-{
-    struct stat sb;
-    bool result = false;
-    int sock = -1;
-    int cc;
-
-    cc = stat(fileName, &sb);
-    if (cc < 0) {
-        if (errno != ENOENT) {
-            LOG(LOG_ERROR, "sim-prop",
-                "Unable to stat '%s' (errno=%d)\n", fileName, errno);
-            goto bail;
-        }
-    } else {
-        /* don't touch it if it's not a socket */
-        if (!(S_ISSOCK(sb.st_mode))) {
-            LOG(LOG_ERROR, "sim-prop",
-                "File '%s' exists and is not a socket\n", fileName);
-            goto bail;
-        }
-
-        /* remove the cruft */
-        if (unlink(fileName) < 0) {
-            LOG(LOG_ERROR, "sim-prop",
-                "Unable to remove '%s' (errno=%d)\n", fileName, errno);
-            goto bail;
-        }
-    }
-
-    struct sockaddr_un addr;
-
-    sock = ::socket(AF_UNIX, SOCK_STREAM, 0);
-    if (sock < 0) {
-        LOG(LOG_ERROR, "sim-prop",
-            "UNIX domain socket create failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    /* bind the socket; this creates the file on disk */
-    strcpy(addr.sun_path, fileName);    // max 108 bytes
-    addr.sun_family = AF_UNIX;
-    cc = ::bind(sock, (struct sockaddr*) &addr, SUN_LEN(&addr));
-    if (cc < 0) {
-        LOG(LOG_ERROR, "sim",
-            "AF_UNIX bind failed for '%s' (errno=%d)\n", fileName, errno);
-        goto bail;
-    }
-
-    cc = ::listen(sock, 5);
-    if (cc < 0) {
-        LOG(LOG_ERROR, "sim", "AF_UNIX listen failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    mListenSock = sock;
-    sock = -1;
-    result = true;
-
-bail:
-    if (sock >= 0)
-        close(sock);
-    return result;
-}
-
-/*
- * Handle a client request.
- *
- * Returns true on success, false if the fd should be closed.
- */
-bool PropertyServer::HandleRequest(int fd)
-{
-    char reqBuf[PROPERTY_KEY_MAX + PROPERTY_VALUE_MAX];
-    char valueBuf[1 + PROPERTY_VALUE_MAX];
-    ssize_t actual;
-
-    memset(valueBuf, 'x', sizeof(valueBuf));        // placate valgrind
-
-    /* read the command byte; this determines the message length */
-    actual = read(fd, reqBuf, 1);
-    if (actual <= 0)
-        return false;
-
-    if (reqBuf[0] == kSystemPropertyGet) {
-        actual = read(fd, reqBuf, PROPERTY_KEY_MAX);
-
-        if (actual != PROPERTY_KEY_MAX) {
-            fprintf(stderr, "Bad read on get: %d of %d\n",
-                actual, PROPERTY_KEY_MAX);
-            return false;
-        }
-        if (GetProperty(reqBuf, valueBuf+1))
-            valueBuf[0] = 1;
-        else
-            valueBuf[0] = 0;
-        //printf("GET property [%s]: (found=%d) [%s]\n",
-        //    reqBuf, valueBuf[0], valueBuf+1);
-        if (write(fd, valueBuf, sizeof(valueBuf)) != sizeof(valueBuf)) {
-            fprintf(stderr, "Bad write on get\n");
-            return false;
-        }
-    } else if (reqBuf[0] == kSystemPropertySet) {
-        actual = read(fd, reqBuf, PROPERTY_KEY_MAX + PROPERTY_VALUE_MAX);
-        if (actual != PROPERTY_KEY_MAX + PROPERTY_VALUE_MAX) {
-            fprintf(stderr, "Bad read on set: %d of %d\n",
-                actual, PROPERTY_KEY_MAX + PROPERTY_VALUE_MAX);
-            return false;
-        }
-        //printf("SET property '%s'\n", reqBuf);
-        if (SetProperty(reqBuf, reqBuf + PROPERTY_KEY_MAX))
-            valueBuf[0] = 1;
-        else
-            valueBuf[0] = 0;
-        if (write(fd, valueBuf, 1) != 1) {
-            fprintf(stderr, "Bad write on set\n");
-            return false;
-        }
-    } else if (reqBuf[0] == kSystemPropertyList) {
-        /* TODO */
-        assert(false);
-    } else {
-        fprintf(stderr, "Unexpected request %d from prop client\n", reqBuf[0]);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Serve up properties.
- */
-void PropertyServer::ServeProperties(void)
-{
-    typedef List<int>::iterator IntIter;
-    fd_set readfds;
-    int maxfd;
-
-    while (true) {
-        int cc;
-
-        FD_ZERO(&readfds);
-        FD_SET(mListenSock, &readfds);
-        maxfd = mListenSock;
-
-        for (IntIter ii = mClientList.begin(); ii != mClientList.end(); ++ii) {
-            int fd = (*ii);
-
-            FD_SET(fd, &readfds);
-            if (maxfd < fd)
-                maxfd = fd;
-        }
-
-        cc = select(maxfd+1, &readfds, NULL, NULL, NULL);
-        if (cc < 0) {
-            if (errno == EINTR) {
-                printf("hiccup!\n");
-                continue;
-            }
-            return;
-        }
-        if (FD_ISSET(mListenSock, &readfds)) {
-            struct sockaddr_un from;
-            socklen_t fromlen;
-            int newSock;
-
-            fromlen = sizeof(from);
-            newSock = ::accept(mListenSock, (struct sockaddr*) &from, &fromlen);
-            if (newSock < 0) {
-                LOG(LOG_WARN, "sim",
-                    "AF_UNIX accept failed (errno=%d)\n", errno);
-            } else {
-                //printf("new props connection on %d --> %d\n",
-                //    mListenSock, newSock);
-
-                mClientList.push_back(newSock);
-            }
-        }
-
-        for (IntIter ii = mClientList.begin(); ii != mClientList.end(); ) {
-            int fd = (*ii);
-            bool ok = true;
-
-            if (FD_ISSET(fd, &readfds)) {
-                //printf("--- activity on %d\n", fd);
-
-                ok = HandleRequest(fd);
-            }
-
-            if (ok) {
-                ++ii;
-            } else {
-                //printf("--- closing %d\n", fd);
-                close(fd);
-                ii = mClientList.erase(ii);
-            }
-        }
-    }
-}
-
-/*
- * Thread entry point.
- *
- * This just sits and waits for a new connection.  It hands it off to the
- * main thread and then goes back to waiting.
- *
- * There is currently no "polite" way to shut this down.
- */
-void* PropertyServer::Entry(void)
-{
-    if (CreateSocket(SYSTEM_PROPERTY_PIPE_NAME)) {
-        assert(mListenSock >= 0);
-        SetDefaultProperties();
-
-        /* loop until it's time to exit or we fail */
-        ServeProperties();
-
-        ClearProperties();
-
-        /*
-         * Close listen socket and all clients.
-         */
-        LOG(LOG_INFO, "sim", "Cleaning up socket list\n");
-        typedef List<int>::iterator IntIter;
-        for (IntIter ii = mClientList.begin(); ii != mClientList.end(); ++ii)
-            close((*ii));
-        close(mListenSock);
-    }
-
-    LOG(LOG_INFO, "sim", "PropertyServer thread exiting\n");
-    return NULL;
-}
-
diff --git a/simulator/app/PropertyServer.h b/simulator/app/PropertyServer.h
deleted file mode 100644
index 193dd70..0000000
--- a/simulator/app/PropertyServer.h
+++ /dev/null
@@ -1,68 +0,0 @@
-//
-// Copyright 2007 The Android Open Source Project
-//
-// Serve properties to the simulated runtime.
-//
-#ifndef _SIM_PROPERTY_SERVER_H
-#define _SIM_PROPERTY_SERVER_H
-
-#include "cutils/properties.h"
-#include "utils/List.h"
-
-/*
- * Define a thread that responds to requests from clients to get/set/list
- * system properties.
- */
-class PropertyServer : public wxThread {
-public:
-    PropertyServer(void) : mListenSock(-1) {}
-    virtual ~PropertyServer(void);
-
-    /* start the thread running */
-    bool StartThread(void);
-
-    /* thread entry point */
-    virtual void* Entry(void);
-
-    /* clear out all properties */
-    void ClearProperties(void);
-
-    /* add some default values */
-    void SetDefaultProperties(void);
-
-    /* copy a property into valueBuf; returns false if property not found */
-    bool GetProperty(const char* key, char* valueBuf);
-
-    /* set the property, replacing it if it already exists */
-    bool SetProperty(const char* key, const char* value);
-
-    /* property name constants */
-    static const char* kPropCheckJni;
-
-private:
-    /* one property entry */
-    typedef struct Property {
-        char    key[PROPERTY_KEY_MAX];
-        char    value[PROPERTY_VALUE_MAX];
-    } Property;
-
-    /* create the UNIX-domain socket we listen on */
-    bool CreateSocket(const char* fileName);
-
-    /* serve up properties */
-    void ServeProperties(void);
-
-    /* handle a client request */
-    bool HandleRequest(int fd);
-
-    /* listen here for new connections */
-    int     mListenSock;
-
-    /* list of connected fds to scan */
-    android::List<int>      mClientList;
-
-    /* set of known properties */
-    android::List<Property> mPropList;
-};
-
-#endif // PROPERTY_SERVER_H
diff --git a/simulator/app/README b/simulator/app/README
deleted file mode 100644
index 5a51f63..0000000
--- a/simulator/app/README
+++ /dev/null
@@ -1,74 +0,0 @@
-Android Simulator README
-Last updated: 14-Nov-2007
-
-See "docs/sim-layout-xml.txt" for a description of the layout.xml files
-in the device directories.
-
-The coding conventions here are generally aligned with wxWidgets' style,
-which is similar to standard Windows style.  The only significant shift
-from Android style is that function names are capitalized.  Note the
-simulator code is not part of the "android" namespace.
-
-
-===== Arguments =====
-
-The config file for the simulator, ".android.cf", can live in your
-$HOME directory or in $cwd.  The copy in $cwd takes priority.  If a
-config file does not exist, one will be created in your home directory.
-(Note that the current directory is set by "runsim.sh", so if you launch
-the simulator from the script it will look for the config file in your
-"install" directory.)
-
-The simulator takes the following optional arguments:
-
- -f <file> : specify the configuration file to use.
-
- -p <platform> : specify platform information.  This is usually
-    something like "Linux-release" or "CYGWIN_NT-5.1-debug".
-
- -r : reset paths.  This causes the simulator to regenerate the paths
-    based on defaults.  This is useful when copying your .android.cf from
-    a different system, because it updates all the local paths without
-    disturbing the other options.
-
-
-===== Preferences Quick Reference =====
-
-Path preferences.  These are reset by the "-r" flag:
-
-"debugger"            (str) Path to the debugger (usually /usr/bin/gdb).
-"valgrinder"          (str) Path to valgrind (usually /usr/bin/valgrind).
-
-Common prefs:
-
-"auto-power-on"       (bool) Automatically start runtime on simulator start.
-"debug"               (bool) Launch the runtime inside <debugger>.
-"valgrind"            (bool) Launch the runtime inside <valgrinder>.
-"log-*"               (various) Preferences for the log window.
-"window-*"            (int) Positions and sizes of windows.
-"default-device"      (str) Name of the device that opens initially.
-"ld-assume-kernel"    (str) Hack to make goobuntu GDB work; use "" to disable.
-
-Less-common prefs:
-
-"gamma"               (float) Gamma correction factor (default 1.0).
-"window-device-x"     (int) Position of device window.
-"window-device-y"     (int) Position of device window.
-"trap-sigint"         (bool) Catch Ctrl-C.  Kill the runtime when we do.
-"refocus-on-restart"  (bool) When runtime rstarts, give focus to phone window.
-"launch-command"      (str) Command to run, e.g. "xterm -e" (cmd is appended).
-"launch-wrapper-args" (str) Args to launch wrapper, e.g. "-wait -output foo".
-
-
-(If you prefer gnome-terminal to xterm, you can use something like
-"gnome-terminal --disable-factory -x".  The "disable-factory" arg is
-needed to ensure that it inherits the environment variables.)
-
-
-***** NOTE *****
-
-If you're using a non-goobuntu system, make sure "ld-assume-kernel" is ""
-in your .android.cf.  gdb works correctly on Ubuntu 7.04 (fiesty) and 7.10
-(gutsy), and the goobuntu workaround will cause shared library version
-failures on startup.
-
diff --git a/simulator/app/Resource.h b/simulator/app/Resource.h
deleted file mode 100644
index 1602428..0000000
--- a/simulator/app/Resource.h
+++ /dev/null
@@ -1,98 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Resource enumeration.
-//
-#ifndef _SIM_RESOURCE_H
-#define _SIM_RESOURCE_H
-
-/*
- * IDs for dialogs, controls, menu items, and whatever else comes along.
- *
- * Some standard defs are in "wx/defs.h".  They run from 5000 to 6000.
- */
-enum {
-    // common stuff
-    //ID_ANONYMOUS = -1,        // use wxID_ANY(-1) or wxID_STATIC(5105)
-
-
-    // Menu item IDs
-    IDM_FILE_PREFERENCES = 100,
-    IDM_FILE_EXIT,
-
-    IDM_RUNTIME_START,
-    IDM_RUNTIME_STOP,
-    IDM_RUNTIME_RESTART,
-    IDM_RUNTIME_KILL,
-
-    IDM_DEVICE,
-    IDM_DEVICE_SEL0,
-    // leave space; each phone model gets a menu item ID
-    IDM_DEVICE_SELN = IDM_DEVICE_SEL0 + 32,
-    IDM_DEVICE_RESCAN,
-
-    IDM_DEBUG_SHOW_LOG,
-
-    IDM_HELP_CONTENTS,
-    IDM_HELP_ABOUT,
-
-
-    // Dialog IDs
-    IDD_PREFS,
-    IDD_LOG_PREFS,
-
-    // Control IDs
-    IDC_MODE_SELECT,            // main - combobox
-    IDC_USE_GDB,                // main - checkbox
-    IDC_USE_VALGRIND,           // main - checkbox
-    IDC_CHECK_JNI,              // main - checkbox
-    IDC_JAVA_APP_NAME,          // main - combobox
-    IDC_JAVA_VM,                // main - combobox
-    IDC_OVERLAY_ONION_SKIN,		// main - combobox
-    IDC_ONION_SKIN_FILE_NAME,	// main - textctrl
-    IDC_ONION_SKIN_BUTTON,		// main - button
-    IDC_ONION_SKIN_ALPHA_VAL,	// main - slider
-	
-    IDC_SPREFS_CONFIG_NAME,     // sim prefs page - textctrl
-    IDC_SPREFS_DEBUGGER,        // sim prefs page - textctrl
-    IDC_SPREFS_VALGRINDER,      // sim prefs page - textctrl
-    IDC_SPREFS_AUTO_POWER_ON,   // sim prefs page - checkbox
-
-    IDC_RPREFS_GAMMA,           // runtime prefs page - textctrl
-    IDC_RPREFS_ENABLE_SOUND,    // runtime prefs page - checkbox
-    IDC_RPREFS_ENABLE_FAKE_CAMERA,// runtime prefs page - checkbox
-
-    IDC_LOG_TEXT,               // log window - textctrl
-    IDC_LOG_LEVEL,              // log window - combobox
-    IDC_LOG_CLEAR,              // log window - button
-    IDC_LOG_PAUSE,              // log window - button
-    IDC_LOG_PREFS,              // log window - button
-
-    IDC_LOG_PREFS_FMT_FULL,     // log prefs - radio button
-    IDC_LOG_PREFS_FMT_BRIEF,    // log prefs - radio button
-    IDC_LOG_PREFS_FMT_MINIMAL,  // log prefs - radio button
-    IDC_LOG_PREFS_SINGLE_LINE,  // log prefs - checkbox
-    IDC_LOG_PREFS_EXTRA_SPACING, // log prefs - combobox
-    IDC_LOG_PREFS_POINT_SIZE,   // log prefs - textctrl
-    IDC_LOG_PREFS_USE_COLOR,    // log prefs - checkbox
-    IDC_LOG_PREFS_FONT_MONO,    // log prefs - checkbox
-
-    IDC_LOG_PREFS_DISPLAY_MAX,  // log prefs - textctrl
-    IDC_LOG_PREFS_POOL_SIZE,    // log prefs - textctrl
-
-    IDC_LOG_PREFS_WRITE_FILE,   // log prefs - checkbox
-    IDC_LOG_PREFS_FILENAME,     // log prefs - textctrl
-    IDC_LOG_PREFS_TRUNCATE_OLD, // log prefs - textctrl
-};
-
-/*
- * Common definitions for control spacing.
- *
- * Doesn't really belong here, but it'll do.
- */
-enum {
-    kEdgeSpacing = 4,       // padding at edge of prefs pages, in pixels
-    kInterSpacing = 5,      // padding between controls, in pixels
-};
-
-#endif // _SIM_RESOURCE_H
diff --git a/simulator/app/Semaphore.cpp b/simulator/app/Semaphore.cpp
deleted file mode 100644
index 3b6ee7b..0000000
--- a/simulator/app/Semaphore.cpp
+++ /dev/null
@@ -1,516 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Inter-process semaphores.
-//
-#include "Semaphore.h"
-
-#if defined(HAVE_MACOSX_IPC)
-# include <semaphore.h>
-#elif defined(HAVE_SYSV_IPC)
-# include <sys/types.h>
-# include <sys/ipc.h>
-# include <sys/sem.h>
-#elif defined(HAVE_WIN32_IPC)
-# include <windows.h>
-#elif defined(HAVE_ANDROID_IPC)
-// not yet
-#else
-# error "unknown sem config"
-#endif
-
-#include <utils/Log.h>
-
-#include <errno.h>
-#include <assert.h>
-
-using namespace android;
-
-
-#if defined(HAVE_ANDROID_IPC) // ----------------------------------------------
-
-Semaphore::Semaphore(void)
-    : mHandle(0), mCreator(false), mKey(-1)
-{}
-
-Semaphore::~Semaphore(void)
-{}
-
-bool Semaphore::create(int key, int initialValue, bool deleteExisting)
-{
-    return false;
-}
-
-bool Semaphore::attach(int key)
-{
-    return false;
-}
-
-void Semaphore::acquire(void)
-{}
-
-void Semaphore::release(void)
-{}
-
-bool Semaphore::tryAcquire(void)
-{
-    return false;
-}
-
-#elif defined(HAVE_MACOSX_IPC) // ---------------------------------------------
-
-/*
- * The SysV semaphores don't work on all of our machines.  The POSIX
- * named semaphores seem to work better.
- */
-
-#define kInvalidHandle SEM_FAILED
-
-static const char* kSemStr = "/tmp/android-sem-";
-
-/*
- * Constructor.  Just init fields.
- */
-Semaphore::Semaphore(void)
-    : mHandle((unsigned long) kInvalidHandle), mCreator(false), mKey(-1)
-{
-}
-
-/*
- * Destructor.  If we created the semaphore, destroy it.
- */
-Semaphore::~Semaphore(void)
-{
-    LOG(LOG_VERBOSE, "sem", "~Semaphore(handle=%ld creator=%d)\n",
-        mHandle, mCreator);
-
-    if (mHandle != (unsigned long) kInvalidHandle) {
-        sem_close((sem_t*) mHandle);
-
-        if (mCreator) {
-            char nameBuf[64];
-            int cc;
-
-            snprintf(nameBuf, sizeof(nameBuf), "%s%d", kSemStr, mKey);
-
-            cc = sem_unlink(nameBuf);
-            if (cc != 0) {
-                LOG(LOG_ERROR, "sem",
-                    "Failed to remove sem '%s' (errno=%d)\n", nameBuf, errno);
-            }
-        }
-    }
-}
-
-/*
- * Create the semaphore.
- */
-bool Semaphore::create(int key, int initialValue, bool deleteExisting)
-{
-    int cc;
-    char nameBuf[64];
-
-    snprintf(nameBuf, sizeof(nameBuf), "%s%d", kSemStr, key);
-
-    if (deleteExisting) {
-        cc = sem_unlink(nameBuf);
-        if (cc != 0 && errno != ENOENT) {
-            LOG(LOG_WARN, "sem", "Warning: failed to remove sem '%s'\n",
-                nameBuf);
-            /* keep going? */
-        }
-    }
-
-    /* create and set initial value */
-    sem_t* semPtr;
-    semPtr = sem_open(nameBuf, O_CREAT | O_EXCL, 0666, 1);
-    if (semPtr == (sem_t*)SEM_FAILED) {
-        LOG(LOG_ERROR, "sem",
-            "ERROR: sem_open failed to create '%s' (errno=%d)\n",
-            nameBuf, errno);
-        return false;
-    }
-
-    mHandle = (unsigned long) semPtr;
-    mCreator = true;
-    mKey = key;
-
-    return true;
-}
-
-/*
- * Attach to an existing semaphore.
- */
-bool Semaphore::attach(int key)
-{
-    char nameBuf[64];
-
-    snprintf(nameBuf, sizeof(nameBuf), "%s%d", kSemStr, key);
-
-    sem_t* semPtr;
-    semPtr = sem_open(nameBuf, 0, 0666, 0);
-    if (semPtr == (sem_t*) SEM_FAILED) {
-        LOG(LOG_ERROR, "sem",
-            "ERROR: sem_open failed to attach to '%s' (errno=%d)\n",
-            nameBuf, errno);
-        return false;
-    }
-
-    mHandle = (unsigned long) semPtr;
-    assert(mCreator == false);
-    mKey = key;
-
-    return true;
-}
-
-/*
- * Acquire or release the semaphore.
- */
-void Semaphore::acquire(void)
-{
-    int cc = sem_wait((sem_t*) mHandle);
-    if (cc != 0)
-        LOG(LOG_WARN, "sem", "acquire failed (errno=%d)\n", errno);
-}
-void Semaphore::release(void)
-{
-    int cc = sem_post((sem_t*) mHandle);
-    if (cc != 0)
-        LOG(LOG_WARN, "sem", "release failed (errno=%d)\n", errno);
-}
-bool Semaphore::tryAcquire(void)
-{
-    int cc = sem_trywait((sem_t*) mHandle);
-    if (cc != 0) {
-        if (errno != EAGAIN)
-            LOG(LOG_WARN, "sem", "tryAcquire failed (errno=%d)\n", errno);
-        return false;
-    }
-    return true;
-}
-
-
-#elif defined(HAVE_SYSV_IPC) // -----------------------------------------------
-
-/*
- * Basic SysV semaphore stuff.
- */
-
-#define kInvalidHandle  ((unsigned long)-1)
-
-#if defined(_SEM_SEMUN_UNDEFINED)
-/* according to X/OPEN we have to define it ourselves */
-union semun {
-    int val;                  /* value for SETVAL */
-    struct semid_ds *buf;     /* buffer for IPC_STAT, IPC_SET */
-    unsigned short *array;    /* array for GETALL, SETALL */
-                              /* Linux specific part: */
-    struct seminfo *__buf;    /* buffer for IPC_INFO */
-};
-#endif
-
-/*
- * Constructor.  Just init fields.
- */
-Semaphore::Semaphore(void)
-    : mHandle(kInvalidHandle), mCreator(false)
-{
-}
-
-/*
- * Destructor.  If we created the semaphore, destroy it.
- */
-Semaphore::~Semaphore(void)
-{
-    LOG(LOG_VERBOSE, "sem", "~Semaphore(handle=%ld creator=%d)\n",
-        mHandle, mCreator);
-
-    if (mCreator && mHandle != kInvalidHandle) {
-        int cc;
-
-        cc = semctl((int) mHandle, 0, IPC_RMID);
-        if (cc != 0) {
-            LOG(LOG_WARN, "sem",
-                "Destructor failed to destroy key=%ld\n", mHandle);
-        }
-    }
-}
-
-/*
- * Create the semaphore.
- */
-bool Semaphore::create(int key, int initialValue, bool deleteExisting)
-{
-    int semid, cc;
-
-    if (deleteExisting) {
-        semid = semget(key, 1, 0);
-        if (semid != -1) {
-            LOG(LOG_DEBUG, "sem", "Key %d exists (semid=%d), removing\n",
-                key, semid);
-            cc = semctl(semid, 0, IPC_RMID);
-            if (cc != 0) {
-                LOG(LOG_ERROR, "sem", "Failed to remove key=%d semid=%d\n",
-                    key, semid);
-                return false;
-            } else {
-                LOG(LOG_DEBUG, "sem",
-                    "Removed previous semaphore with key=%d\n", key);
-            }
-        }
-    }
-
-    semid = semget(key, 1, 0600 | IPC_CREAT | IPC_EXCL);
-    if (semid == -1) {
-        LOG(LOG_ERROR, "sem", "Failed to create key=%d (errno=%d)\n",
-            key, errno);
-        return false;
-    }
-
-    mHandle = semid;
-    mCreator = true;
-    mKey = key;
-
-    /*
-     * Set initial value.
-     */
-    union semun init;
-    init.val = initialValue;
-    cc = semctl(semid, 0, SETVAL, init);
-    if (cc == -1) {
-        LOG(LOG_ERROR, "sem",
-            "Unable to initialize semaphore, key=%d iv=%d (errno=%d)\n",
-            key, initialValue, errno);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Attach to an existing semaphore.
- */
-bool Semaphore::attach(int key)
-{
-    int semid;
-
-    semid = semget(key, 0, 0);
-    if (semid == -1) {
-        LOG(LOG_ERROR, "sem", "Failed to find key=%d\n", key);
-        return false;
-    }
-
-    mHandle = semid;
-    assert(mCreator == false);
-    mKey = key;
-
-    return true;
-}
-
-/*
- * Acquire or release the semaphore.
- */
-void Semaphore::acquire(void)
-{
-    assert(mHandle != kInvalidHandle);
-    adjust(-1, true);
-}
-void Semaphore::release(void)
-{
-    assert(mHandle != kInvalidHandle);
-    adjust(1, true);
-}
-bool Semaphore::tryAcquire(void)
-{
-    assert(mHandle != kInvalidHandle);
-    return adjust(-1, false);
-}
-
-/*
- * Do the actual semaphore manipulation.
- *
- * The semaphore's value indicates the number of free resources.  Pass
- * in a negative value for "adj" to acquire resources, or a positive
- * value to free resources.
- *
- * Returns true on success, false on failure.
- */
-bool Semaphore::adjust(int adj, bool wait)
-{
-    struct sembuf op;
-    int cc;
-
-    op.sem_num = 0;
-    op.sem_op = adj;
-    op.sem_flg = SEM_UNDO;
-    if (!wait)
-        op.sem_flg |= IPC_NOWAIT;
-
-    cc = semop((int) mHandle, &op, 1);
-    if (cc != 0) {
-        if (wait || errno != EAGAIN) {
-            LOG(LOG_WARN, "sem",
-                "semaphore adjust by %d failed for semid=%ld (errno=%d)\n",
-                adj, mHandle, errno);
-        }
-        return false;
-    }
-
-    //LOG(LOG_VERBOSE, "sem",
-    //    "adjusted semaphore by %d (semid=%ld)\n", adj, mHandle);
-
-    return true;
-}
-
-
-#elif defined(HAVE_WIN32_IPC) // ----------------------------------------------
-
-/*
- * Win32 semaphore implementation.
- *
- * Pretty straightforward.
- */
-
-static const char* kSemStr = "android-sem-";
-
-/*
- * Constructor.  Just init fields.
- */
-Semaphore::Semaphore(void)
-    : mHandle((unsigned long) INVALID_HANDLE_VALUE), mCreator(false)
-{
-}
-
-/*
- * Destructor.  Just close the semaphore handle.
- */
-Semaphore::~Semaphore(void)
-{
-    LOG(LOG_DEBUG, "sem", "~Semaphore(handle=%ld creator=%d)\n",
-        mHandle, mCreator);
-
-    if (mHandle != (unsigned long) INVALID_HANDLE_VALUE)
-        CloseHandle((HANDLE) mHandle);
-}
-
-/*
- * Create the semaphore.
- */
-bool Semaphore::create(int key, int initialValue, bool deleteExisting)
-{
-    char keyBuf[64];
-    HANDLE hSem;
-    long max;
-
-    snprintf(keyBuf, sizeof(keyBuf), "%s%d", kSemStr, key);
-
-    if (initialValue == 0)
-        max = 1;
-    else
-        max = initialValue;
-
-    hSem = CreateSemaphore(
-            NULL,                       // security attributes
-            initialValue,               // initial count
-            max,                        // max count, must be >= initial
-            keyBuf);                    // object name
-    if (hSem == NULL) {
-        DWORD err = GetLastError();
-        if (err == ERROR_ALREADY_EXISTS) {
-            LOG(LOG_ERROR, "sem", "Semaphore '%s' already exists\n", keyBuf);
-        } else {
-            LOG(LOG_ERROR, "sem", "CreateSemaphore(%s) failed (err=%ld)\n",
-                keyBuf, err);
-        }
-        return false;
-    }
-
-    mHandle = (unsigned long) hSem;
-    mCreator = true;
-    mKey = key;
-
-    //LOG(LOG_DEBUG, "sem", "Semaphore '%s' created (handle=0x%08lx)\n",
-    //    keyBuf, mHandle);
-
-    return true;
-}
-
-/*
- * Attach to an existing semaphore.
- */
-bool Semaphore::attach(int key)
-{
-    char keyBuf[64];
-    HANDLE hSem;
-
-    snprintf(keyBuf, sizeof(keyBuf), "%s%d", kSemStr, key);
-
-    hSem = OpenSemaphore(
-            //SEMAPHORE_MODIFY_STATE,   // mostly-full access
-            SEMAPHORE_ALL_ACCESS,       // full access
-            FALSE,                      // don't let kids inherit handle
-            keyBuf);                    // object name
-    if (hSem == NULL) {
-        LOG(LOG_ERROR, "sem", "OpenSemaphore(%s) failed (err=%ld)\n",
-            keyBuf, GetLastError());
-        return false;
-    }
-
-    mHandle = (unsigned long) hSem;
-    assert(mCreator == false);
-    mKey = key;
-
-    return true;
-}
-
-/*
- * Acquire or release the semaphore.
- */
-void Semaphore::acquire(void)
-{
-    DWORD result;
-
-    assert(mHandle != (unsigned long) INVALID_HANDLE_VALUE);
-
-    result = WaitForSingleObject((HANDLE) mHandle, INFINITE);
-    if (result != WAIT_OBJECT_0) {
-        LOG(LOG_WARN, "sem",
-            "WaitForSingleObject(INF) on semaphore returned %ld (err=%ld)\n",
-            result, GetLastError());
-    }
-}
-void Semaphore::release(void)
-{
-    DWORD result;
-
-    assert(mHandle != (unsigned long) INVALID_HANDLE_VALUE);
-
-    result = ReleaseSemaphore((HANDLE) mHandle, 1, NULL);    // incr by 1
-    if (result == 0) {
-        LOG(LOG_WARN, "sem", "ReleaseSemaphore failed (err=%ld)\n",
-            GetLastError());
-    }
-}
-bool Semaphore::tryAcquire(void)
-{
-    DWORD result;
-
-    assert(mHandle != (unsigned long) INVALID_HANDLE_VALUE);
-    result = WaitForSingleObject((HANDLE) mHandle, 0);
-    if (result == WAIT_OBJECT_0)
-        return true;        // grabbed it
-    else if (result == WAIT_TIMEOUT)
-        return false;       // not available
-    else if (result == WAIT_FAILED) {
-        LOG(LOG_WARN, "sem", "WaitForSingleObject(0) on sem failed (err=%ld)\n",
-            GetLastError());
-        return false;
-    } else {
-        LOG(LOG_WARN, "sem",
-            "WaitForSingleObject(0) on sem returned %ld (err=%ld)\n",
-            result, GetLastError());
-        return false;
-    }
-}
-
-#endif // ---------------------------------------------------------------------
diff --git a/simulator/app/Semaphore.h b/simulator/app/Semaphore.h
deleted file mode 100644
index 3b834f3..0000000
--- a/simulator/app/Semaphore.h
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Inter-process semaphore.
-//
-// These are meant for IPC, not thread management.  The Mutex and Condition
-// classes are much lighter weight.
-//
-#ifndef __LIBS_SEMAPHORE_H
-#define __LIBS_SEMAPHORE_H
-
-#ifdef HAVE_ANDROID_OS
-#error DO NOT USE THIS FILE IN THE DEVICE BUILD
-#endif
-
-namespace android {
-
-/*
- * Platform-independent semaphore class.
- *
- * Each object holds a single semaphore.
- *
- * The "key" is usually the process ID of the process that created the
- * semaphore (following POSIX semantics).  See the comments in shmem.h.
- */
-class Semaphore {
-public:
-    Semaphore(void);
-    virtual ~Semaphore(void);
-
-    /*
-     * Create a new semaphore, with the specified initial value.  The
-     * value indicates the number of resources available.
-     */
-    bool create(int key, int initialValue, bool deleteExisting);
-
-    /*
-     * Attach to an existing semaphore.
-     */
-    bool attach(int key);
-
-    /*
-     * Acquire or release the semaphore.
-     */
-    void acquire(void);
-    void release(void);
-    bool tryAcquire(void);      // take a timeout?
-
-private:
-    bool adjust(int adj, bool wait);
-
-    unsigned long   mHandle;    // semid(int) or HANDLE
-    bool            mCreator;
-    int             mKey;
-};
-
-}; // namespace android
-
-#endif // __LIBS_SEMAPHORE_H
diff --git a/simulator/app/Shmem.cpp b/simulator/app/Shmem.cpp
deleted file mode 100644
index 4c619c2..0000000
--- a/simulator/app/Shmem.cpp
+++ /dev/null
@@ -1,558 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Shared memory interface.
-//
-#include "Shmem.h"
-#include "utils/Log.h"
-
-#if defined(HAVE_MACOSX_IPC) || defined(HAVE_ANDROID_IPC)
-#  include <sys/mman.h>
-#  include <fcntl.h>
-#  include <unistd.h>
-#elif defined(HAVE_SYSV_IPC)
-# include <sys/types.h>
-# include <sys/ipc.h>
-# include <sys/shm.h>
-#elif defined(HAVE_WIN32_IPC)
-# include <windows.h>
-#else
-# error "unknown shm config"
-#endif
-
-#include <errno.h>
-#include <assert.h>
-
-using namespace android;
-
-
-#if defined(HAVE_MACOSX_IPC) || defined(HAVE_ANDROID_IPC)
-
-/*
- * SysV IPC under Mac OS X seems to have problems.  It works fine on
- * some machines but totally fails on others.  We're working around it
- * here by using mmap().
- */
-
-#define kInvalidHandle  ((unsigned long)-1)
-
-static const char* kShmemFile = "/tmp/android-";
-
-/*
- * Constructor.  Just set up the fields.
- */
-Shmem::Shmem(void)
-    : mHandle(kInvalidHandle), mAddr(MAP_FAILED), mLength(-1), mCreator(false),
-      mKey(-1)
-{
-}
-
-/*
- * Destructor.  Detach and, if we created it, mark the segment for
- * destruction.
- */
-Shmem::~Shmem(void)
-{
-    if (mAddr != MAP_FAILED)
-        munmap(mAddr, mLength);
-    if ((long)mHandle >= 0) {
-        close(mHandle);
-
-        if (mCreator) {
-            char nameBuf[64];
-            int cc;
-
-            snprintf(nameBuf, sizeof(nameBuf), "%s%d", kShmemFile, mKey);
-            cc = unlink(nameBuf);
-            if (cc != 0) {
-                LOG(LOG_WARN, "shmem", "Couldn't clean up '%s'\n", nameBuf);
-                /* oh well */
-            }
-        }
-    }
-}
-
-/*
- * Create the segment and attach ourselves to it.
- */
-bool Shmem::create(int key, long size, bool deleteExisting)
-{
-    char nameBuf[64];
-    int fd, cc;
-
-    snprintf(nameBuf, sizeof(nameBuf), "%s%d", kShmemFile, key);
-
-    if (deleteExisting) {
-        cc = unlink(nameBuf);
-        if (cc != 0 && errno != ENOENT) {
-            LOG(LOG_ERROR, "shmem", "Failed to remove old map file '%s'\n",
-                nameBuf);
-            return false;
-        }
-    }
-
-    fd = open(nameBuf, O_CREAT|O_EXCL|O_RDWR, 0600);
-    if (fd < 0) {
-        LOG(LOG_ERROR, "shmem", "Unable to create map file '%s' (errno=%d)\n",
-            nameBuf, errno);
-        return false;
-    }
-
-    /*
-     * Set the file size by seeking and writing.
-     */
-    if (ftruncate(fd, size) == -1) {
-        LOG(LOG_ERROR, "shmem", "Unable to set file size in '%s' (errno=%d)\n",
-            nameBuf, errno);
-        close(fd);
-        return false;
-    }
-
-    mAddr = mmap(NULL, size, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0);
-    if (mAddr == MAP_FAILED) {
-        LOG(LOG_ERROR, "shmem", "mmap failed (errno=%d)\n", errno);
-        close(fd);
-        return false;
-    }
-
-    mHandle = fd;
-    mLength = size;
-    mCreator = true;
-    mKey = key;
-
-    /* done with shmem, create the associated semaphore */
-    if (!mSem.create(key, 1, true)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed creating semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Attach ourselves to an existing segment.
- */
-bool Shmem::attach(int key)
-{
-    char nameBuf[64];
-    int fd;
-
-    snprintf(nameBuf, sizeof(nameBuf), "%s%d", kShmemFile, key);
-    fd = open(nameBuf, O_RDWR, 0600);
-    if (fd < 0) {
-        LOG(LOG_ERROR, "shmem", "Unable to open map file '%s' (errno=%d)\n",
-            nameBuf, errno);
-        return false;
-    }
-
-    off_t len;
-    len = lseek(fd, 0, SEEK_END);
-    if (len == (off_t) -1) {
-        LOG(LOG_ERROR, "shmem",
-            "Could not determine file size of '%s' (errno=%d)\n",
-            nameBuf, errno);
-        close(fd);
-        return false;
-    }
-
-    mAddr = mmap(NULL, len, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0);
-    if (mAddr == MAP_FAILED) {
-        LOG(LOG_ERROR, "shmem", "mmap failed (errno=%d)\n", errno);
-        close(fd);
-        return false;
-    }
-
-    mHandle = fd;
-    mLength = len;
-    assert(mCreator == false);
-    mKey = key;
-
-    /* done with shmem, attach to associated semaphore */
-    if (!mSem.attach(key)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed to attach to semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Get address.
- */
-void* Shmem::getAddr(void)
-{
-    assert(mAddr != MAP_FAILED);
-    return mAddr;
-}
-
-/*
- * Return the length of the segment.
- *
- * Returns -1 on failure.
- */
-long Shmem::getLength(void)
-{
-    if (mLength >= 0)
-        return mLength;
-
-    // we should always have it by now
-    assert(false);
-    return -1;
-}
-
-
-#elif defined(HAVE_SYSV_IPC) // ----------------------------------------------
-
-/*
- * SysV-style IPC.  The SysV shared memory API is fairly annoying to
- * deal with, but it's present on many UNIX-like systems.
- */
-
-#define kInvalidHandle  ((unsigned long)-1)
-
-/*
- * Constructor.  Just set up the fields.
- */
-Shmem::Shmem(void)
-    : mHandle(kInvalidHandle), mAddr(NULL), mLength(-1), mCreator(false),
-      mKey(-1)
-{
-}
-
-/*
- * Destructor.  Detach and, if we created it, mark the segment for
- * destruction.
- */
-Shmem::~Shmem(void)
-{
-    int cc;
-
-    //LOG(LOG_DEBUG, "shmem", "~Shmem(handle=%ld creator=%d)",
-    //    mHandle, mCreator);
-
-    if (mAddr != NULL)
-        cc = shmdt(mAddr);
-
-    if (mCreator && mHandle != kInvalidHandle) {
-        cc = shmctl((int) mHandle, IPC_RMID, NULL);
-        if (cc != 0) {
-            LOG(LOG_WARN, "shmem",
-                "Destructor failed to remove shmid=%ld (errno=%d)\n",
-                mHandle, errno);
-        }
-    }
-}
-
-/*
- * Create the segment and attach ourselves to it.
- */
-bool Shmem::create(int key, long size, bool deleteExisting)
-{
-    int shmid, cc;
-
-    if (deleteExisting) {
-        shmid = shmget(key, size, 0);
-        if (shmid != -1) {
-            LOG(LOG_DEBUG, "shmem",
-                "Key %d exists (shmid=%d), marking for destroy", key, shmid);
-            cc = shmctl(shmid, IPC_RMID, NULL);
-            if (cc != 0) {
-                LOG(LOG_ERROR, "shmem",
-                    "Failed to remove key=%d shmid=%d (errno=%d)\n",
-                    key, shmid, errno);
-                return false;   // IPC_CREAT | IPC_EXCL will fail, so bail now
-            } else {
-                LOG(LOG_DEBUG, "shmem",
-                    "Removed previous segment with key=%d\n", key);
-            }
-        }
-    }
-
-    shmid = shmget(key, size, 0600 | IPC_CREAT | IPC_EXCL);
-    if (shmid == -1) {
-        LOG(LOG_ERROR, "shmem", "Failed to create key=%d (errno=%d)\n",
-            key, errno);
-        return false;
-    }
-
-    mHandle = shmid;
-    mCreator = true;
-    mKey = key;
-
-    void* addr = shmat(shmid, NULL, 0);
-    if (addr == (void*) -1) {
-        LOG(LOG_ERROR, "shmem",
-            "Could not attach to key=%d shmid=%d (errno=%d)\n",
-            key, shmid, errno);
-        return false;
-    }
-
-    mAddr = addr;
-    mLength = size;
-
-    /* done with shmem, create the associated semaphore */
-    if (!mSem.create(key, 1, true)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed creating semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Attach ourselves to an existing segment.
- */
-bool Shmem::attach(int key)
-{
-    int shmid;
-
-    shmid = shmget(key, 0, 0);
-    if (shmid == -1) {
-        LOG(LOG_ERROR, "shmem", "Failed to find key=%d\n", key);
-        return false;
-    }
-
-    mHandle = shmid;
-    assert(mCreator == false);
-    mKey = key;
-
-    void* addr = shmat(shmid, NULL, 0);
-    if (addr == (void*) -1) {
-        LOG(LOG_ERROR, "shmem", "Could not attach to key=%d shmid=%d\n",
-            key, shmid);
-        return false;
-    }
-
-    mAddr = addr;
-
-    /* done with shmem, attach to associated semaphore */
-    if (!mSem.attach(key)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed to attach to semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Get address.
- */
-void* Shmem::getAddr(void)
-{
-    assert(mAddr != NULL);
-    return mAddr;
-}
-
-/*
- * Return the length of the segment.
- *
- * Returns -1 on failure.
- */
-long Shmem::getLength(void)
-{
-    if (mLength >= 0)
-        return mLength;
-
-    assert(mHandle != kInvalidHandle);
-
-    struct shmid_ds shmids;
-    int cc;
-
-    cc = shmctl((int) mHandle, IPC_STAT, &shmids);
-    if (cc != 0) {
-        LOG(LOG_ERROR, "shmem", "Could not IPC_STAT shmid=%ld\n", mHandle);
-        return -1;
-    }
-    mLength = shmids.shm_segsz;     // save a copy to avoid future lookups
-
-    return mLength;
-}
-
-
-#elif defined(HAVE_WIN32_IPC) // ---------------------------------------------
-
-/*
- * Win32 shared memory implementation.
- *
- * Shared memory is implemented as an "anonymous" file mapping, using the
- * memory-mapped I/O interfaces.
- */
-
-static const char* kShmemStr = "android-shmem-";
-
-/*
- * Constructor.  Just set up the fields.
- */
-Shmem::Shmem(void)
-    : mHandle((unsigned long) INVALID_HANDLE_VALUE),
-      mAddr(NULL), mLength(-1), mCreator(false), mKey(-1)
-{
-}
-
-/*
- * Destructor.  The Win32 API doesn't require a distinction between
- * the "creator" and other mappers.
- */
-Shmem::~Shmem(void)
-{
-    LOG(LOG_DEBUG, "shmem", "~Shmem(handle=%ld creator=%d)",
-        mHandle, mCreator);
-
-    if (mAddr != NULL)
-        UnmapViewOfFile(mAddr);
-    if (mHandle != (unsigned long) INVALID_HANDLE_VALUE)
-        CloseHandle((HANDLE) mHandle);
-}
-
-/*
- * Create the segment and map it.
- */
-bool Shmem::create(int key, long size, bool deleteExisting)
-{
-    char keyBuf[64];
-    HANDLE hMapFile;
-
-    snprintf(keyBuf, sizeof(keyBuf), "%s%d", kShmemStr, key);
-
-    hMapFile = CreateFileMapping(
-                INVALID_HANDLE_VALUE,       // use paging file, not actual file
-                NULL,                       // default security
-                PAGE_READWRITE,             // read/write access
-                0,                          // max size; no need to cap
-                size,                       // min size
-                keyBuf);                    // mapping name
-    if (hMapFile == NULL || hMapFile == INVALID_HANDLE_VALUE) {
-        LOG(LOG_ERROR, "shmem",
-            "Could not create mapping object '%s' (err=%ld)\n",
-            keyBuf, GetLastError());
-        return false;
-    }
-
-    mHandle = (unsigned long) hMapFile;
-    mCreator = true;
-    mKey = key;
-
-    mAddr = MapViewOfFile(
-                hMapFile,                   // handle to map object
-                FILE_MAP_ALL_ACCESS,        // read/write
-                0,                          // offset (hi)
-                0,                          // offset (lo)
-                size);                      // #of bytes to map
-    if (mAddr == NULL) {
-        LOG(LOG_ERROR, "shmem", "Could not map shared area (err=%ld)\n",
-            GetLastError());
-        return false;
-    }
-    mLength = size;
-
-    /* done with shmem, create the associated semaphore */
-    if (!mSem.create(key, 1, true)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed creating semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Attach ourselves to an existing segment.
- */
-bool Shmem::attach(int key)
-{
-    char keyBuf[64];
-    HANDLE hMapFile;
-
-    snprintf(keyBuf, sizeof(keyBuf), "%s%d", kShmemStr, key);
-
-    hMapFile = OpenFileMapping(
-                FILE_MAP_ALL_ACCESS,        // read/write
-                FALSE,                      // don't let kids inherit handle
-                keyBuf);                    // mapping name
-    if (hMapFile == NULL) {
-        LOG(LOG_ERROR, "shmem",
-            "Could not open mapping object '%s' (err=%ld)\n",
-            keyBuf, GetLastError());
-        return false;
-    }
-
-    mHandle = (unsigned long) hMapFile;
-    assert(mCreator == false);
-    mKey = key;
-
-    mAddr = MapViewOfFile(
-                hMapFile,                   // handle to map object
-                FILE_MAP_ALL_ACCESS,        // read/write
-                0,                          // offset (hi)
-                0,                          // offset (lo)
-                0);                        // #of bytes to map
-    if (mAddr == NULL) {
-        LOG(LOG_ERROR, "shmem", "Could not map shared area (err=%ld)\n",
-            GetLastError());
-        return false;
-    }
-
-    /* done with shmem, attach to associated semaphore */
-    if (!mSem.attach(key)) {
-        LOG(LOG_ERROR, "shmem",
-            "Failed to attach to semaphore for Shmem (key=%d)\n", key);
-        return false;
-    }
-
-    return true;
-}
-
-/*
- * Get address.
- */
-void* Shmem::getAddr(void)
-{
-    assert(mAddr != NULL);
-    return mAddr;
-}
-
-/*
- * Get the length of the segment.
- */
-long Shmem::getLength(void)
-{
-    SIZE_T size;
-    MEMORY_BASIC_INFORMATION mbInfo;
-
-    if (mLength >= 0)
-        return mLength;
-
-    assert(mAddr != NULL);
-
-    size = VirtualQuery(mAddr, &mbInfo, sizeof(mbInfo));
-    if (size == 0) {
-        LOG(LOG_WARN, "shmem", "VirtualQuery returned no data\n");
-        return -1;
-    }
-
-    mLength = mbInfo.RegionSize;
-    return mLength;
-}
-
-#endif // --------------------------------------------------------------------
-
-/*
- * Semaphore operations.
- */
-void Shmem::lock(void)
-{
-    mSem.acquire();
-}
-void Shmem::unlock(void)
-{
-    mSem.release();
-}
-bool Shmem::tryLock(void)
-{
-    return mSem.tryAcquire();
-}
-
diff --git a/simulator/app/Shmem.h b/simulator/app/Shmem.h
deleted file mode 100644
index 3d53b58..0000000
--- a/simulator/app/Shmem.h
+++ /dev/null
@@ -1,95 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Inter-process shared memory.
-//
-#ifndef __LIBS_SHMEM_H
-#define __LIBS_SHMEM_H
-
-#ifdef HAVE_ANDROID_OS
-#error DO NOT USE THIS FILE IN THE DEVICE BUILD
-#endif
-
-#include "Semaphore.h"
-
-namespace android {
-
-/*
- * Platform-independent shared memory.  Each object can be used to
- * create a chunk of memory that is shared between processes.
- *
- * For convenience, a semaphore is associated with each segment.
- * (Whether this should have been done in a subclass is debatable.)
- *
- * The "key" is usually the process ID of the process that created the
- * segment.  The goal is to avoid clashing with other processes that are
- * trying to do the same thing.  It's a little awkward to use when you
- * want to have multiple shared segments created in one process.  In
- * SysV you can work around this by using a "private" key and sharing
- * the shmid with your friends, in Win32 you can use a string, but we're
- * in lowest-common-denominator mode here.  Assuming we have 16-bit PIDs,
- * the upper 16 bits can be used to serialize keys.
- *
- * When the object goes out of scope, the shared memory segment is
- * detached from the process.  If the object was responsible for creating
- * the segment, it is also marked for destruction on SysV systems.  This
- * will make it impossible for others to attach to.
- *
- * On some systems, the length returned by getLength() may be different
- * for parent and child due to page size rounding.
- */
-class Shmem {
-public:
-    Shmem(void);
-    virtual ~Shmem(void);
-
-    /*
-     * Create a new shared memory segment, with the specified size.  If
-     * "deleteExisting" is set, any existing segment will be deleted first
-     * (useful for SysV IPC).
-     *
-     * Returns "true" on success, "false" on failure.
-     */
-    bool create(int key, long size, bool deleteExisting);
-
-    /*
-     * Attach to a shared memory segment.  Use this from the process that
-     * didn't create the segment.
-     *
-     * Returns "true" on success, "false" on failure.
-     */
-    bool attach(int key);
-
-    /*
-     * Get the memory segment address and length.  These will not change
-     * for the lifetime of the object, so it's okay to cache the results.
-     *
-     * On failure, getAddr() returns NULL and getLength() returns -1.
-     */
-    void* getAddr(void);
-    long getLength(void);
-
-    /*
-     * Lock or unlock the shared memory segment.  This is useful if you
-     * are updating pieces of shared data.  The segment is initially
-     * "unlocked".
-     *
-     * This does *not* lock down the segment in the virtual paging system.
-     * It's just a mutex.
-     */
-    void lock(void);
-    void unlock(void);
-    bool tryLock(void);
-
-private:
-    Semaphore       mSem;       // uses the same value for "key"
-    unsigned long   mHandle;    // shmid(int) or HANDLE
-    void*           mAddr;      // address
-    long            mLength;    // length of segment (cached)
-    bool            mCreator;   // true if we created the segment
-    int             mKey;       // key passed in as arg
-};
-
-}; // namespace android
-
-#endif // __LIBS_SHMEM_H
diff --git a/simulator/app/SimRuntime.h b/simulator/app/SimRuntime.h
deleted file mode 100644
index 6dadfb2..0000000
--- a/simulator/app/SimRuntime.h
+++ /dev/null
@@ -1,124 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Miscellaneous definitions and declarations used for interaction
-// between the device and the simulator.
-//
-// This header is included on both sides, so try not to include
-// any other headers from here.
-//
-#ifndef _RUNTIME_SIMULATOR_H
-#define _RUNTIME_SIMULATOR_H
-
-#include "MessageStream.h"
-#include "Shmem.h"
-//#include "utils/RefBase.h"
-#include "utils/Log.h"
-
-namespace android {
-
-#define ANDROID_PIPE_NAME "runtime"
-
-/*
- * Hold simulator state.
- */
-class Simulator {
-public:
-    Simulator(void);
-    ~Simulator(void);
-
-    /*
-     * Commands exchanged between simulator and runtime.
-     */
-    typedef enum Command {
-        kCommandUnknown = 0,
-
-        /* sent from sim to runtime */
-        kCommandGoAway,             // sim says: go away, I'm busy
-        kCommandConfigDone,         // sim says: done sending config
-        kCommandQuit,               // quit nicely
-        kCommandNewPGroup,          // process group management
-        kCommandKeyDown,            // key has been pressed
-        kCommandKeyUp,              // key has been released
-        kCommandTouch,              // finger touched/lifted/dragged
-
-        /* sent from runtime to sim */
-        kCommandNewPGroupCreated,    // send process group as argument
-        kCommandRuntimeReady,       // we're initialized and about to start
-        kCommandUpdateDisplay,      // display has been updated
-        kCommandVibrate,            // vibrate on or off
-    } Command;
-
-    typedef enum TouchMode {
-        kTouchDown = 0,
-        kTouchUp = 1,
-        kTouchDrag = 2
-    } TouchMode;
-
-    /*
-     * Some parameters for config exchange.
-     */
-    enum {
-        kDisplayConfigMagic = 0x44495350,
-        kValuesPerDisplay = 5,
-    };
-
-    /*
-     * Set up communication with parent process.
-     */
-    //bool create(ParentProcess* pParent);
-
-    /*
-     * Set up communication with detached simulator.
-     */
-    bool create(Pipe* reader, Pipe* writer);
-
-    /*
-     * Tell simulator that we're ready to go.
-     */
-    void sendRuntimeReady(void);
-
-    /*
-     * Tell the simulator that a display has been refreshed.
-     */
-    void sendDisplayUpdate(int displayIndex);
-
-    /*
-     * Tell the simulator to turn the vibrator on or off
-     */
-    void sendVibrate(int vibrateOn);
-
-    /*
-     * Get a pointer to the shared memory for the Nth display.
-     */
-    Shmem* getGraphicsBuffer(int displayIndex);
-
-    /*
-     * Return a copy of our input pipe so the event system can monitor
-     * it for pending activity.
-     */
-    Pipe* getReadPipe(void) { return mStream.getReadPipe(); }
-
-    /*
-     * Retrieve the next command from the parent.  Returns NO_ERROR
-     * if all is okay, WOULD_BLOCK if blocking is false and there
-     * are no pending commands, or INVALID_OPERATION if the simulator
-     * has disappeared.
-     */
-    int getNextKey(int32_t* outKey, bool* outDown);
-
-    /*
-     * Log system callback function.
-     */
-    static void writeLogMsg(const android_LogBundle* pBundle);
-
-private:
-    bool finishCreate(void);
-    bool handleDisplayConfig(const long* pData, int length);
-
-    MessageStream   mStream;
-};
-
-}; // namespace android
-
-#endif // _RUNTIME_SIMULATOR_H
diff --git a/simulator/app/UserEvent.cpp b/simulator/app/UserEvent.cpp
deleted file mode 100644
index 01d3337..0000000
--- a/simulator/app/UserEvent.cpp
+++ /dev/null
@@ -1,20 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Some additional glue for "user event" type.
-//
-
-// For compilers that support precompilation, include "wx/wx.h".
-#include "wx/wxprec.h"
-
-// Otherwise, include all standard headers
-#ifndef WX_PRECOMP
-# include "wx/wx.h"
-#endif
-
-#include "UserEvent.h"
-
-DEFINE_EVENT_TYPE(wxEVT_USER_EVENT)
-
-IMPLEMENT_DYNAMIC_CLASS(UserEvent, wxEvent)
-
diff --git a/simulator/app/UserEvent.h b/simulator/app/UserEvent.h
deleted file mode 100644
index 76664e1..0000000
--- a/simulator/app/UserEvent.h
+++ /dev/null
@@ -1,54 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// A "user event" for wxWidgets.
-//
-#ifndef _SIM_USER_EVENT_H
-#define _SIM_USER_EVENT_H
-
-/*
- * Event declaration.  The book says to use DECLARE_EVENT_TYPE, but that
- * causes a compiler warning and a link failure with gcc under MinGW.
- *
- * It looks like the "magic number", in this case 12345, is just picked
- * by hand.  There may be a better mechanism in this version of
- * wxWidgets, but the documentation and sample code doesn't reflect it.
- */
-BEGIN_DECLARE_EVENT_TYPES()
-    DECLARE_LOCAL_EVENT_TYPE(wxEVT_USER_EVENT, 12345)
-END_DECLARE_EVENT_TYPES()
-
-/*
- * A "user event" class.  This can be used like any other wxWidgets
- * event, but we get to stuff anything we want to in it.
- */
-class UserEvent : public wxEvent {
-public:
-    UserEvent(int id = 0, void* data = (void*) 0)
-        : wxEvent(id, wxEVT_USER_EVENT), mData(data)
-        {}
-    UserEvent(const UserEvent& event)
-        : wxEvent(event), mData(event.mData)
-        {}
-
-    virtual wxEvent* Clone() const {
-        return new UserEvent(*this);
-    }
-
-    void* GetData(void) const { return mData; }
-
-    DECLARE_DYNAMIC_CLASS(UserEvent);
-
-private:
-    UserEvent& operator=(const UserEvent&);     // not implemented
-    void*   mData;
-};
-
-typedef void (wxEvtHandler::*UserEventFunction)(UserEvent&);
-
-#define EVT_USER_EVENT(fn) \
-        DECLARE_EVENT_TABLE_ENTRY(wxEVT_USER_EVENT, wxID_ANY, wxID_ANY, \
-            (wxObjectEventFunction)(wxEventFunction)(UserEventFunction)&fn, \
-            (wxObject*) NULL ),
-
-#endif // _SIM_USER_EVENT_H
diff --git a/simulator/app/UserEventMessage.h b/simulator/app/UserEventMessage.h
deleted file mode 100644
index 4a66cc2..0000000
--- a/simulator/app/UserEventMessage.h
+++ /dev/null
@@ -1,84 +0,0 @@
-//
-// Copyright 2005 The Android Open Source Project
-//
-// Contents of the "user event" sent from the device thread.
-//
-#ifndef _SIM_USER_EVENT_MESSAGE_H
-#define _SIM_USER_EVENT_MESSAGE_H
-
-#include <utils.h>
-#include "LogMessage.h"
-
-/*
- * This gets stuffed into a UserEvent, which is posted to the main thread
- * from a worker thread.
- *
- * The object does NOT own anything you stuff into it.  It's just a vehicle
- * for carting data from one thread to another in a wxWidgets-safe manner,
- * usually as pointers to data that can be shared between threads.
- */
-class UserEventMessage {
-public:
-    /*
-     * What type of message is this?
-     */
-    typedef enum UEMType {
-        kUnknown = 0,
-
-        kRuntimeStarted,
-        kRuntimeStopped,
-        kErrorMessage,      // message in mString
-        kLogMessage,        // ptr to heap-allocated LogMessage
-        kExternalRuntime,   // external runtime wants to party
-    } UEMType;
-
-    UserEventMessage(void)
-        : mType(kUnknown), mpLogMessage(NULL)
-        {}
-    ~UserEventMessage(void) {
-    }
-
-    /*
-     * Create one of our various messages.
-     */
-    void CreateRuntimeStarted(void) {
-        mType = kRuntimeStarted;
-    }
-    void CreateRuntimeStopped(void) {
-        mType = kRuntimeStopped;
-    }
-    void CreateErrorMessage(wxString& str) {
-        mType = kErrorMessage;
-        mString = str;
-    }
-    void CreateLogMessage(LogMessage* pLogMessage) {
-        mType = kLogMessage;
-        mpLogMessage = pLogMessage;
-    }
-    void CreateExternalRuntime(android::Pipe* reader, android::Pipe* writer) {
-        mType = kExternalRuntime;
-        mReader = reader;
-        mWriter = writer;
-    }
-
-    /*
-     * Accessors.
-     */
-    UEMType GetType(void) const { return mType; }
-    const wxString& GetString(void) const { return mString; }
-    LogMessage* GetLogMessage(void) const { return mpLogMessage; }
-    android::Pipe* GetReader(void) const { return mReader; }
-    android::Pipe* GetWriter(void) const { return mWriter; }
-
-private:
-    UserEventMessage& operator=(const UserEventMessage&);   // not implemented
-    UserEventMessage(const UserEventMessage&);              // not implemented
-
-    UEMType     mType;
-    wxString    mString;            // for kErrorMessage
-    LogMessage* mpLogMessage;       // for kLogMessage
-    android::Pipe*  mReader;        // for kExternalRuntime
-    android::Pipe*  mWriter;        // for kExternalRuntime
-};
-
-#endif // _SIM_USER_EVENT_MESSAGE_H
diff --git a/simulator/app/assets/android-dream/arrow_down.png b/simulator/app/assets/android-dream/arrow_down.png
deleted file mode 100644
index 19b3764..0000000
--- a/simulator/app/assets/android-dream/arrow_down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/arrow_left.png b/simulator/app/assets/android-dream/arrow_left.png
deleted file mode 100644
index 113e584..0000000
--- a/simulator/app/assets/android-dream/arrow_left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/arrow_right.png b/simulator/app/assets/android-dream/arrow_right.png
deleted file mode 100644
index ffe3356..0000000
--- a/simulator/app/assets/android-dream/arrow_right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/arrow_up.png b/simulator/app/assets/android-dream/arrow_up.png
deleted file mode 100644
index 81c54df..0000000
--- a/simulator/app/assets/android-dream/arrow_up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/back.png b/simulator/app/assets/android-dream/back.png
deleted file mode 100644
index 41034d9..0000000
--- a/simulator/app/assets/android-dream/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/background.png b/simulator/app/assets/android-dream/background.png
deleted file mode 100644
index bab8c6d..0000000
--- a/simulator/app/assets/android-dream/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/end.png b/simulator/app/assets/android-dream/end.png
deleted file mode 100644
index 6830a60..0000000
--- a/simulator/app/assets/android-dream/end.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/home.png b/simulator/app/assets/android-dream/home.png
deleted file mode 100644
index 7d02136..0000000
--- a/simulator/app/assets/android-dream/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/key.png b/simulator/app/assets/android-dream/key.png
deleted file mode 100644
index 7a3f563..0000000
--- a/simulator/app/assets/android-dream/key.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/layout.xml b/simulator/app/assets/android-dream/layout.xml
deleted file mode 100644
index 8a7c5f8..0000000
--- a/simulator/app/assets/android-dream/layout.xml
+++ /dev/null
@@ -1,356 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2006 The Android Open Source Project -->
-
-<device name="Dream">
-    <!-- title for menus -->
-    <title>Android Dream</title>
-
-    <display name="main" width="320" height="480" format="rgb565" refresh="30"/>
-
-    <keyboard qwerty="1" keycharmap="qwerty2" />
-    
-    <mode name="closed">
-        <view display="main" x="75" y="84" rotate="0">
-
-            <!-- surrounding device image and "patches", drawn in order -->
-            <image src="background.png" x="0" y="0"/>
-
-            <!-- buttons for which we have highlight images -->
-            <button keyCode="1"             src="key.png"           x="468" y="276"/>
-            <button keyCode="q"             src="key.png"           x="468" y="312"/>
-            <button keyCode="power"         src="power.png"         x="7"   y="66"/>
-            <button keyCode="volume-up"     src="volume_up.png"     x="407" y="274"/>
-            <button keyCode="volume-down"   src="volume_down.png"   x="407" y="324"/>
-
-            <button keyCode="home"          src="home.png"          x="93"  y="602"/>
-            <button keyCode="back"          src="back.png"          x="331" y="602"/>
-            <button keyCode="dpad-up"       src="arrow_up.png"      x="185" y="608"/>
-            <button keyCode="dpad-down"     src="arrow_down.png"    x="185" y="669"/>
-            <button keyCode="dpad-left"     src="arrow_left.png"    x="155" y="610"/>
-            <button keyCode="dpad-right"    src="arrow_right.png"   x="266" y="610"/>
-            <button keyCode="dpad-center"   src="select.png"        x="186" y="637"/>
-            <button keyCode="phone-dial"    src="send.png"          x="93"  y="658"/>
-            <button keyCode="phone-hangup"  src="end.png"           x="331" y="658"/>
-            <button keyCode="soft-left"     src="menu.png"          x="192" y="569"/>
-
-<!--
-            1 {
-               image  key.png
-               x  468
-               y  302
-            }
-            2 {
-               image  key.png
-               x 505
-               y 302
-            }
-            3 {
-               image  key.png
-               x 543
-               y 302
-            }
-            4 {
-               image  key.png
-               x 579
-               y 302
-            }
-            5 {
-               image  key.png
-               x 616
-               y 302
-            }
-            6 {
-               image  key.png
-               x 653
-               y 302
-            }
-            7 {
-               image  key.png
-               x 690
-               y 302
-            }
-            8 {
-               image  key.png
-               x 727
-               y 302
-            }
-            9 {
-               image  key.png
-               x 763
-               y 302
-            }
-            0 {
-               image  key.png
-               x 801
-               y 302
-            }
-
-            q {
-               image  key.png
-               x  468
-               y  338
-            }
-            w {
-               image  key.png
-               x 505
-               y 338
-            }
-            e {
-               image  key.png
-               x 543
-               y 338
-            }
-            r {
-               image  key.png
-               x 579
-               y 338
-            }
-            t {
-               image  key.png
-               x 616
-               y 338
-            }
-            y {
-               image  key.png
-               x 653
-               y 338
-            }
-            u {
-               image  key.png
-               x 690
-               y 338
-            }
-            i {
-               image  key.png
-               x 727
-               y 338
-            }
-            o {
-               image  key.png
-               x 763
-               y 338
-            }
-            p {
-               image  key.png
-               x 801
-               y 338
-            }
-
-            a {
-               image  key.png
-               x  468
-               y  374
-            }
-            s {
-               image  key.png
-               x 505
-               y 374
-            }
-            d {
-               image  key.png
-               x 543
-               y 374
-            }
-            f {
-               image  key.png
-               x 579
-               y 374
-            }
-            g {
-               image  key.png
-               x 616
-               y 374
-            }
-            h {
-               image  key.png
-               x 653
-               y 374
-            }
-            j {
-               image  key.png
-               x 690
-               y 374
-            }
-            k {
-               image  key.png
-               x 727
-               y 374
-            }
-            l {
-               image  key.png
-               x 763
-               y 374
-            }
-            DEL {
-               image  key.png
-               x 801
-               y 374
-            }
-
-            CAP {
-               image  key.png
-               x  468
-               y  410
-            }
-            z {
-               image  key.png
-               x 505
-               y 410
-            }
-            x {
-               image  key.png
-               x 543
-               y 410
-            }
-            c {
-               image  key.png
-               x 579
-               y 410
-            }
-            v {
-               image  key.png
-               x 616
-               y 410
-            }
-            b {
-               image  key.png
-               x 653
-               y 410
-            }
-            n {
-               image  key.png
-               x 690
-               y 410
-            }
-            m {
-               image  key.png
-               x 727
-               y 410
-            }
-            PERIOD {
-               image  key.png
-               x 763
-               y 410
-            }
-            ENTER {
-               image  key.png
-               x 801
-               y 410
-            }
-
-            ALT {
-               image  key.png
-               x  468
-               y  446
-            }
-            SYM {
-               image  key.png
-               x 505
-               y 446
-            }
-            AT {
-               image  key.png
-               x 543
-               y 446
-            }
-            SPACE {
-               image  spacebar.png
-               x 579
-               y 446
-            }
-            SLASH {
-               image  key.png
-               x 727
-               y 446
-            }
-            COMMA {
-               image  key.png
-               x 763
-               y 446
-            }
-            ALT2 {
-               image  key.png
-               x 801
-               y 446
-            }
-
-            soft-left {
-                image menu.png
-                x 192
-                y 623
-            }
-            home {
-                image home.png
-                x 93
-                y 656
-            }
-            back {
-                image back.png
-                x 331
-                y 656
-            }
-            dpad-up {
-                image arrow_up.png
-                x 185
-                y 662
-            }
-            dpad-down {
-                image arrow_down.png
-                x 185
-                y 723
-            }
-            dpad-left {
-                image arrow_left.png
-                x 155
-                y 664
-            }
-            dpad-right {
-                image arrow_right.png
-                x 266
-                y 664
-            }
-            dpad-center {
-                image select.png
-                x 186
-                y 691
-            }
-            phone-dial {
-                image send.png
-                x 93
-                y 712
-            }
-            phone-hangup {
-                image end.png
-                x 331
-                y 712
-            }
-
-            power {
-                image power.png
-                x 7
-                y 120
-            }
-
-            volume-up {
-                image volume_up.png
-                x 407
-                y 328
-            }
-
-            volume-down {
-                image volume_down.png
-                x 407
-                y 378
-            }
--->
-        </view>
-    </mode>
-
-<!--
-    <mode name="open">
-        <view display="main" x="0" y="0" rotate="90">
-        </view>
-    </mode>
--->
-
-</device>
diff --git a/simulator/app/assets/android-dream/menu.png b/simulator/app/assets/android-dream/menu.png
deleted file mode 100644
index e81d8ab..0000000
--- a/simulator/app/assets/android-dream/menu.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/power.png b/simulator/app/assets/android-dream/power.png
deleted file mode 100644
index 5894288..0000000
--- a/simulator/app/assets/android-dream/power.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/select.png b/simulator/app/assets/android-dream/select.png
deleted file mode 100644
index 803d493..0000000
--- a/simulator/app/assets/android-dream/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/send.png b/simulator/app/assets/android-dream/send.png
deleted file mode 100644
index f547c88..0000000
--- a/simulator/app/assets/android-dream/send.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/spacebar.png b/simulator/app/assets/android-dream/spacebar.png
deleted file mode 100644
index 19fe604..0000000
--- a/simulator/app/assets/android-dream/spacebar.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/volume_down.png b/simulator/app/assets/android-dream/volume_down.png
deleted file mode 100644
index f8a88de..0000000
--- a/simulator/app/assets/android-dream/volume_down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-dream/volume_up.png b/simulator/app/assets/android-dream/volume_up.png
deleted file mode 100644
index 940457f..0000000
--- a/simulator/app/assets/android-dream/volume_up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/back.png b/simulator/app/assets/android-sooner/back.png
deleted file mode 100644
index 5190939..0000000
--- a/simulator/app/assets/android-sooner/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/background.png b/simulator/app/assets/android-sooner/background.png
deleted file mode 100644
index 32534b9..0000000
--- a/simulator/app/assets/android-sooner/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/down.png b/simulator/app/assets/android-sooner/down.png
deleted file mode 100644
index 1d602b0..0000000
--- a/simulator/app/assets/android-sooner/down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/end.png b/simulator/app/assets/android-sooner/end.png
deleted file mode 100644
index 17d8cc7..0000000
--- a/simulator/app/assets/android-sooner/end.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/favorites.png b/simulator/app/assets/android-sooner/favorites.png
deleted file mode 100644
index ad85c5c..0000000
--- a/simulator/app/assets/android-sooner/favorites.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/home.png b/simulator/app/assets/android-sooner/home.png
deleted file mode 100644
index 04f9a21..0000000
--- a/simulator/app/assets/android-sooner/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/imap b/simulator/app/assets/android-sooner/imap
deleted file mode 100644
index 64c9aff..0000000
--- a/simulator/app/assets/android-sooner/imap
+++ /dev/null
@@ -1,15 +0,0 @@
-# awk '{print $1, $4-$2 "x" $5-$3 "+" $2 "+" $3}'
-
-BACKGROUND=background-alpha.png
-
-convert $BACKGROUND -crop 43x47+55+410 send.png
-convert $BACKGROUND -crop 43x47+338+411 end.png
-convert $BACKGROUND -crop 43x40+98+393 menu.png
-convert $BACKGROUND -crop 43x40+98+433 back.png
-convert $BACKGROUND -crop 47x40+291+393 favorites.png
-convert $BACKGROUND -crop 47x40+291+433 home.png
-convert $BACKGROUND -crop 81x24+177+422 select.png
-convert $BACKGROUND -crop 81x30+177+392 up.png
-convert $BACKGROUND -crop 81x30+177+446 down.png
-convert $BACKGROUND -crop 31x84+146+392 left.png
-convert $BACKGROUND -crop 31x84+258+392 right.png
diff --git a/simulator/app/assets/android-sooner/layout.xml b/simulator/app/assets/android-sooner/layout.xml
deleted file mode 100644
index d17b9d8..0000000
--- a/simulator/app/assets/android-sooner/layout.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2006 The Android Open Source Project -->
-
-<device name="Sooner">
-    <!-- title for menus -->
-    <title>Android Sooner</title>
-
-    <display name="main" width="320" height="240" format="rgb565" refresh="30"/>
-
-    <keyboard qwerty="1" keycharmap="qwerty" />
-    
-    <mode name="default">
-        <view display="main" x="53" y="95" rotate="0">
-
-            <!-- surrounding device image and "patches", drawn in order -->
-            <image src="background.png" x="0" y="0"/>
-
-            <!-- buttons for which we have highlight images -->
-            <button keyCode="soft-left"     src="menu.png"          x="93"  y="367"/>
-            <button keyCode="soft-right"    src="favorites.png"     x="286" y="367"/>
-            <button keyCode="home"          src="home.png"          x="286" y="407"/>
-            <button keyCode="back"          src="back.png"          x="93"  y="407"/>
-            <button keyCode="dpad-up"       src="up.png"            x="172" y="366"/>
-            <button keyCode="dpad-down"     src="down.png"          x="172" y="420"/>
-            <button keyCode="dpad-left"     src="left.png"          x="141" y="366"/>
-            <button keyCode="dpad-right"    src="right.png"         x="253" y="366"/>
-            <button keyCode="dpad-center"   src="select.png"        x="172" y="396"/>
-
-            <button keyCode="phone-dial"    src="send.png"          x="50"  y="384"/>
-            <button keyCode="phone-hangup"  src="end.png"           x="333" y="385"/>
-        </view>
-    </mode>
-
-</device>
diff --git a/simulator/app/assets/android-sooner/left.png b/simulator/app/assets/android-sooner/left.png
deleted file mode 100644
index f712f5c..0000000
--- a/simulator/app/assets/android-sooner/left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/menu.png b/simulator/app/assets/android-sooner/menu.png
deleted file mode 100644
index 4c7f15a..0000000
--- a/simulator/app/assets/android-sooner/menu.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/right.png b/simulator/app/assets/android-sooner/right.png
deleted file mode 100644
index b1aa1f9..0000000
--- a/simulator/app/assets/android-sooner/right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/select.png b/simulator/app/assets/android-sooner/select.png
deleted file mode 100644
index 79606d1..0000000
--- a/simulator/app/assets/android-sooner/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/send.png b/simulator/app/assets/android-sooner/send.png
deleted file mode 100644
index 9bf103d..0000000
--- a/simulator/app/assets/android-sooner/send.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/android-sooner/up.png b/simulator/app/assets/android-sooner/up.png
deleted file mode 100644
index 324d67e..0000000
--- a/simulator/app/assets/android-sooner/up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/chimera-2000/layout.xml b/simulator/app/assets/chimera-2000/layout.xml
deleted file mode 100644
index d808281..0000000
--- a/simulator/app/assets/chimera-2000/layout.xml
+++ /dev/null
@@ -1,194 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<!--
-This is a silly, contrived example of a dual-screen display device.
-The "front" and "back" are shown side-by-side.  I used the phone graphics
-from two phones, which are presented as if they were glued back-to-back.
-
-This also illustrates front and back views, which for our purposes just
-determines which phone is on the left.
-
-This used to use relative paths (../whatever) to get at the phone content,
-but relative paths aren't supported in the "AssetManager" world.  We now
-use "::/whatever", which is interpreted by the simulator.  (The change from
-'.' to ':' was done to make it obvious that we weren't using UNIX paths.)
--->
-
-
-<device name="Chimera2000">
-    <!-- title for menus -->
-    <title>Chimera WeirdPhone 2000</title>
-
-    <!-- primary display characteristics -->
-    <display name="top" width="176" height="220" format="rgb565" refresh="30"/>
-    <display name="bottom" width="176" height="220" format="rgb565" refresh="30"/>
-
-	<mode name="front">
-        <!-- the "top" device looks like a Samsung phone -->
-		<view display="top" x="49" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-            <image src="::/samsung-flip-2005/background-176x220.png" x="0" y="0"/>
-            <image src="::/samsung-flip-2005/home-background.png" x="22" y="426"/>
-            <image src="::/samsung-flip-2005/back-background.png" x="179" y="426"/>
-
-			<!-- buttons for which we have highlight images -->
-            <button keyCode="soft-left"     src="::/samsung-flip-2005/soft-left.png"     x="24" y="388"/>
-            <button keyCode="soft-right"    src="::/samsung-flip-2005/soft-right.png"    x="182" y="388"/>
-            <button keyCode="home"          src="::/samsung-flip-2005/home.png"          x="22" y="426"/>
-            <button keyCode="back"          src="::/samsung-flip-2005/back.png"          x="179" y="426"/>
-            <button keyCode="dpad-up"       src="::/samsung-flip-2005/arrow-up.png"      x="99" y="399"/>
-            <button keyCode="dpad-down"     src="::/samsung-flip-2005/arrow-down.png"    x="99" y="461"/>
-            <button keyCode="dpad-left"     src="::/samsung-flip-2005/arrow-left.png"    x="82" y="411"/>
-            <button keyCode="dpad-right"    src="::/samsung-flip-2005/arrow-right.png"   x="147" y="411"/>
-            <button keyCode="dpad-center"   src="::/samsung-flip-2005/select.png"        x="115" y="431"/>
-
-            <button keyCode="1"             src="::/samsung-flip-2005/1.png"             x="24" y="533"/>
-            <button keyCode="2"             src="::/samsung-flip-2005/2.png"             x="94" y="544"/>
-            <button keyCode="3"             src="::/samsung-flip-2005/3.png"             x="173" y="534"/>
-            <button keyCode="4"             src="::/samsung-flip-2005/4.png"             x="25" y="576"/>
-            <button keyCode="5"             src="::/samsung-flip-2005/5.png"             x="94" y="581"/>
-            <button keyCode="6"             src="::/samsung-flip-2005/6.png"             x="172" y="576"/>
-            <button keyCode="7"             src="::/samsung-flip-2005/7.png"             x="27" y="619"/>
-            <button keyCode="8"             src="::/samsung-flip-2005/8.png"             x="95" y="621"/>
-            <button keyCode="9"             src="::/samsung-flip-2005/9.png"             x="168" y="620"/>
-            <button keyCode="0"             src="::/samsung-flip-2005/0.png"             x="96" y="658"/>
-            <button keyCode="star"          src="::/samsung-flip-2005/star.png"          x="31" y="659"/>
-            <button keyCode="pound"         src="::/samsung-flip-2005/pound.png"         x="169" y="659"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-		</view>
-
-        <!-- the "bottom" device looks like an HTC phone -->
-		<view display="bottom" x="36" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-            <image src="::/htc-audiovox-5600/background.png" x="0" y="0"/>
-
-			<!-- buttons for which we have highlight images -->
-            <button keyCode="soft-left"     src="::/htc-audiovox-5600/soft-left.png"     x="40" y="312"/>
-            <button keyCode="soft-right"    src="::/htc-audiovox-5600/soft-right.png"    x="145" y="312"/>
-            <button keyCode="home"          src="::/htc-audiovox-5600/home.png"          x="57" y="331"/>
-            <button keyCode="back"          src="::/htc-audiovox-5600/back.png"          x="123" y="333"/>
-            <button keyCode="dpad-up"       src="::/htc-audiovox-5600/arrow-up.png"      x="59" y="364"/>
-            <button keyCode="dpad-down"     src="::/htc-audiovox-5600/arrow-down.png"    x="60" y="393"/>
-            <button keyCode="dpad-left"/>
-            <button keyCode="dpad-right"/>
-            <button keyCode="dpad-center"   src="::/htc-audiovox-5600/select.png"        x="103" y="381"/>
-
-            <button keyCode="1"             src="::/htc-audiovox-5600/1.png"             x="30" y="411"/>
-            <button keyCode="2"             src="::/htc-audiovox-5600/2.png"             x="90" y="409"/>
-            <button keyCode="3"             src="::/htc-audiovox-5600/3.png"             x="159" y="413"/>
-            <button keyCode="4"             src="::/htc-audiovox-5600/4.png"             x="32" y="445"/>
-            <button keyCode="5"             src="::/htc-audiovox-5600/5.png"             x="92" y="445"/>
-            <button keyCode="6"             src="::/htc-audiovox-5600/6.png"             x="157" y="444"/>
-            <button keyCode="7"             src="::/htc-audiovox-5600/7.png"             x="28" y="476"/>
-            <button keyCode="8"             src="::/htc-audiovox-5600/8.png"             x="94" y="480"/>
-            <button keyCode="9"             src="::/htc-audiovox-5600/9.png"             x="156" y="477"/>
-            <button keyCode="0"             src="::/htc-audiovox-5600/0.png"             x="97" y="513"/>
-            <button keyCode="star"          src="::/htc-audiovox-5600/star.png"          x="45" y="509"/>
-            <button keyCode="pound"         src="::/htc-audiovox-5600/pound.png"         x="155" y="511"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-	</mode>
-
-	<mode name="back">
-        <!-- show the back view first, then the front view -->
-		<view display="bottom" x="36" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-            <image src="::/htc-audiovox-5600/background.png" x="0" y="0"/>
-
-			<!-- buttons for which we have highlight images -->
-            <button keyCode="soft-left"     src="::/htc-audiovox-5600/soft-left.png"     x="40" y="312"/>
-            <button keyCode="soft-right"    src="::/htc-audiovox-5600/soft-right.png"    x="145" y="312"/>
-            <button keyCode="home"          src="::/htc-audiovox-5600/home.png"          x="57" y="331"/>
-            <button keyCode="back"          src="::/htc-audiovox-5600/back.png"          x="123" y="333"/>
-            <button keyCode="dpad-up"       src="::/htc-audiovox-5600/arrow-up.png"      x="59" y="364"/>
-            <button keyCode="dpad-down"     src="::/htc-audiovox-5600/arrow-down.png"    x="60" y="393"/>
-            <button keyCode="dpad-left"/>
-            <button keyCode="dpad-right"/>
-            <button keyCode="dpad-center"   src="::/htc-audiovox-5600/select.png"        x="103" y="381"/>
-
-            <button keyCode="1"             src="::/htc-audiovox-5600/1.png"             x="30" y="411"/>
-            <button keyCode="2"             src="::/htc-audiovox-5600/2.png"             x="90" y="409"/>
-            <button keyCode="3"             src="::/htc-audiovox-5600/3.png"             x="159" y="413"/>
-            <button keyCode="4"             src="::/htc-audiovox-5600/4.png"             x="32" y="445"/>
-            <button keyCode="5"             src="::/htc-audiovox-5600/5.png"             x="92" y="445"/>
-            <button keyCode="6"             src="::/htc-audiovox-5600/6.png"             x="157" y="444"/>
-            <button keyCode="7"             src="::/htc-audiovox-5600/7.png"             x="28" y="476"/>
-            <button keyCode="8"             src="::/htc-audiovox-5600/8.png"             x="94" y="480"/>
-            <button keyCode="9"             src="::/htc-audiovox-5600/9.png"             x="156" y="477"/>
-            <button keyCode="0"             src="::/htc-audiovox-5600/0.png"             x="97" y="513"/>
-            <button keyCode="star"          src="::/htc-audiovox-5600/star.png"          x="45" y="509"/>
-            <button keyCode="pound"         src="::/htc-audiovox-5600/pound.png"         x="155" y="511"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-
-        <!-- our view of the device that shows the main display -->
-		<view display="top" x="49" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-            <image src="::/samsung-flip-2005/background-176x220.png" x="0" y="0"/>
-            <image src="::/samsung-flip-2005/home-background.png" x="22" y="426"/>
-            <image src="::/samsung-flip-2005/back-background.png" x="179" y="426"/>
-
-			<!-- buttons for which we have highlight images -->
-            <button keyCode="soft-left"     src="::/samsung-flip-2005/soft-left.png"     x="24" y="388"/>
-            <button keyCode="soft-right"    src="::/samsung-flip-2005/soft-right.png"    x="182" y="388"/>
-            <button keyCode="home"          src="::/samsung-flip-2005/home.png"          x="22" y="426"/>
-            <button keyCode="back"          src="::/samsung-flip-2005/back.png"          x="179" y="426"/>
-            <button keyCode="dpad-up"       src="::/samsung-flip-2005/arrow-up.png"      x="99" y="399"/>
-            <button keyCode="dpad-down"     src="::/samsung-flip-2005/arrow-down.png"    x="99" y="461"/>
-            <button keyCode="dpad-left"     src="::/samsung-flip-2005/arrow-left.png"    x="82" y="411"/>
-            <button keyCode="dpad-right"    src="::/samsung-flip-2005/arrow-right.png"   x="147" y="411"/>
-            <button keyCode="dpad-center"   src="::/samsung-flip-2005/select.png"        x="115" y="431"/>
-
-            <button keyCode="1"             src="::/samsung-flip-2005/1.png"             x="24" y="533"/>
-            <button keyCode="2"             src="::/samsung-flip-2005/2.png"             x="94" y="544"/>
-            <button keyCode="3"             src="::/samsung-flip-2005/3.png"             x="173" y="534"/>
-            <button keyCode="4"             src="::/samsung-flip-2005/4.png"             x="25" y="576"/>
-            <button keyCode="5"             src="::/samsung-flip-2005/5.png"             x="94" y="581"/>
-            <button keyCode="6"             src="::/samsung-flip-2005/6.png"             x="172" y="576"/>
-            <button keyCode="7"             src="::/samsung-flip-2005/7.png"             x="27" y="619"/>
-            <button keyCode="8"             src="::/samsung-flip-2005/8.png"             x="95" y="621"/>
-            <button keyCode="9"             src="::/samsung-flip-2005/9.png"             x="168" y="620"/>
-            <button keyCode="0"             src="::/samsung-flip-2005/0.png"             x="96" y="658"/>
-            <button keyCode="star"          src="::/samsung-flip-2005/star.png"          x="31" y="659"/>
-            <button keyCode="pound"         src="::/samsung-flip-2005/pound.png"         x="169" y="659"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-		</view>
-
-	</mode>
-</device>
-
diff --git a/simulator/app/assets/danger-hiptop-m1/background-open.png b/simulator/app/assets/danger-hiptop-m1/background-open.png
deleted file mode 100644
index 62d2c29..0000000
--- a/simulator/app/assets/danger-hiptop-m1/background-open.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/danger-hiptop-m1/background.png b/simulator/app/assets/danger-hiptop-m1/background.png
deleted file mode 100644
index f8c58c7..0000000
--- a/simulator/app/assets/danger-hiptop-m1/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/danger-hiptop-m1/layout.xml b/simulator/app/assets/danger-hiptop-m1/layout.xml
deleted file mode 100644
index f8d7cba..0000000
--- a/simulator/app/assets/danger-hiptop-m1/layout.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<device name="DangerM1">
-    <!-- title for menus -->
-    <title>Danger hiptop M1</title>
-
-    <display name="main" width="240" height="160" format="rgb565" refresh="30"/>
-
-	<keyboard qwerty="1" />
-	
-    <mode name="closed">
-        <!-- hiptop when closed -->
-        <view display="main" x="160" y="69" rotate="0">
-
-            <!-- surrounding device image and "patches", drawn in order -->
-            <image src="background.png" x="0" y="0"/>
-
-        </view>
-    </mode>
-
-    <mode name="open">
-        <!-- hiptop when flipped open -->
-        <view display="main" x="172" y="60" rotate="180">
-
-            <image src="background-open.png" x="0" y="0"/>
-        </view>
-    </mode>
-
-</device>
-
diff --git a/simulator/app/assets/htc-audiovox-5600/0.png b/simulator/app/assets/htc-audiovox-5600/0.png
deleted file mode 100644
index 1fa4b72..0000000
--- a/simulator/app/assets/htc-audiovox-5600/0.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/1.png b/simulator/app/assets/htc-audiovox-5600/1.png
deleted file mode 100644
index f939334..0000000
--- a/simulator/app/assets/htc-audiovox-5600/1.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/2.png b/simulator/app/assets/htc-audiovox-5600/2.png
deleted file mode 100644
index 09be58b..0000000
--- a/simulator/app/assets/htc-audiovox-5600/2.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/3.png b/simulator/app/assets/htc-audiovox-5600/3.png
deleted file mode 100644
index 91c70c1..0000000
--- a/simulator/app/assets/htc-audiovox-5600/3.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/4.png b/simulator/app/assets/htc-audiovox-5600/4.png
deleted file mode 100644
index da930ff..0000000
--- a/simulator/app/assets/htc-audiovox-5600/4.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/5.png b/simulator/app/assets/htc-audiovox-5600/5.png
deleted file mode 100644
index 5c4625a..0000000
--- a/simulator/app/assets/htc-audiovox-5600/5.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/6.png b/simulator/app/assets/htc-audiovox-5600/6.png
deleted file mode 100644
index f309960..0000000
--- a/simulator/app/assets/htc-audiovox-5600/6.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/7.png b/simulator/app/assets/htc-audiovox-5600/7.png
deleted file mode 100644
index e09b08c..0000000
--- a/simulator/app/assets/htc-audiovox-5600/7.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/8.png b/simulator/app/assets/htc-audiovox-5600/8.png
deleted file mode 100644
index c8b3dcc..0000000
--- a/simulator/app/assets/htc-audiovox-5600/8.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/9.png b/simulator/app/assets/htc-audiovox-5600/9.png
deleted file mode 100644
index f284212..0000000
--- a/simulator/app/assets/htc-audiovox-5600/9.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/arrow-down.png b/simulator/app/assets/htc-audiovox-5600/arrow-down.png
deleted file mode 100644
index 08a17ea..0000000
--- a/simulator/app/assets/htc-audiovox-5600/arrow-down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/arrow-up.png b/simulator/app/assets/htc-audiovox-5600/arrow-up.png
deleted file mode 100644
index f2998b9..0000000
--- a/simulator/app/assets/htc-audiovox-5600/arrow-up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/back.png b/simulator/app/assets/htc-audiovox-5600/back.png
deleted file mode 100644
index 4110ec7..0000000
--- a/simulator/app/assets/htc-audiovox-5600/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/background-orange.png b/simulator/app/assets/htc-audiovox-5600/background-orange.png
deleted file mode 100644
index b147546..0000000
--- a/simulator/app/assets/htc-audiovox-5600/background-orange.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/background.png b/simulator/app/assets/htc-audiovox-5600/background.png
deleted file mode 100644
index 9ffd7f3..0000000
--- a/simulator/app/assets/htc-audiovox-5600/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/home.png b/simulator/app/assets/htc-audiovox-5600/home.png
deleted file mode 100644
index a10d293..0000000
--- a/simulator/app/assets/htc-audiovox-5600/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/layout.xml b/simulator/app/assets/htc-audiovox-5600/layout.xml
deleted file mode 100644
index 9e68c0f..0000000
--- a/simulator/app/assets/htc-audiovox-5600/layout.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<device name="HTC5600">
-    <!-- title for menus -->
-    <title>HTC AudioVox 5600</title>
-
-    <!-- primary display characteristics -->
-    <display name="main" width="176" height="220" format="rgb565" refresh="30"/>
-
-	<mode name="default">
-		<view display="main" x="36" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-			<image src="background.png" x="0" y="0"/>
-
-			<!-- buttons for which we have highlight images -->
-			<button keyCode="soft-left"     src="soft-left.png"     x="40" y="312"/>
-			<button keyCode="soft-right"    src="soft-right.png"    x="145" y="312"/>
-			<button keyCode="home"          src="home.png"          x="57" y="331"/>
-			<button keyCode="back"          src="back.png"          x="123" y="333"/>
-			<button keyCode="dpad-up"       src="arrow-up.png"      x="59" y="364"/>
-			<button keyCode="dpad-down"     src="arrow-down.png"    x="60" y="393"/>
-            <button keyCode="dpad-left"/>
-            <button keyCode="dpad-right"/>
-			<button keyCode="dpad-center"   src="select.png"        x="103" y="381"/>
-
-			<button keyCode="1"             src="1.png"             x="30" y="411"/>
-			<button keyCode="2"             src="2.png"             x="90" y="409"/>
-			<button keyCode="3"             src="3.png"             x="159" y="413"/>
-			<button keyCode="4"             src="4.png"             x="32" y="445"/>
-			<button keyCode="5"             src="5.png"             x="92" y="445"/>
-			<button keyCode="6"             src="6.png"             x="157" y="444"/>
-			<button keyCode="7"             src="7.png"             x="28" y="476"/>
-			<button keyCode="8"             src="8.png"             x="94" y="480"/>
-			<button keyCode="9"             src="9.png"             x="156" y="477"/>
-			<button keyCode="0"             src="0.png"             x="97" y="513"/>
-			<button keyCode="star"          src="star.png"          x="45" y="509"/>
-			<button keyCode="pound"         src="pound.png"         x="155" y="511"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-	</mode>
-
-</device>
-
diff --git a/simulator/app/assets/htc-audiovox-5600/pound.png b/simulator/app/assets/htc-audiovox-5600/pound.png
deleted file mode 100644
index 90df1fa..0000000
--- a/simulator/app/assets/htc-audiovox-5600/pound.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/select.png b/simulator/app/assets/htc-audiovox-5600/select.png
deleted file mode 100644
index 509082c..0000000
--- a/simulator/app/assets/htc-audiovox-5600/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/soft-left.png b/simulator/app/assets/htc-audiovox-5600/soft-left.png
deleted file mode 100644
index ce8cc5c..0000000
--- a/simulator/app/assets/htc-audiovox-5600/soft-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/soft-right.png b/simulator/app/assets/htc-audiovox-5600/soft-right.png
deleted file mode 100644
index f3c76c7..0000000
--- a/simulator/app/assets/htc-audiovox-5600/soft-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-audiovox-5600/star.png b/simulator/app/assets/htc-audiovox-5600/star.png
deleted file mode 100644
index 19aa057..0000000
--- a/simulator/app/assets/htc-audiovox-5600/star.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/0.png b/simulator/app/assets/htc-tornado/0.png
deleted file mode 100644
index a40e898..0000000
--- a/simulator/app/assets/htc-tornado/0.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/1.png b/simulator/app/assets/htc-tornado/1.png
deleted file mode 100644
index 92c6782..0000000
--- a/simulator/app/assets/htc-tornado/1.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/2.png b/simulator/app/assets/htc-tornado/2.png
deleted file mode 100644
index 42a79ec..0000000
--- a/simulator/app/assets/htc-tornado/2.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/3.png b/simulator/app/assets/htc-tornado/3.png
deleted file mode 100644
index 7e685a8..0000000
--- a/simulator/app/assets/htc-tornado/3.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/4.png b/simulator/app/assets/htc-tornado/4.png
deleted file mode 100644
index c1b8060..0000000
--- a/simulator/app/assets/htc-tornado/4.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/5.png b/simulator/app/assets/htc-tornado/5.png
deleted file mode 100644
index 29d2607..0000000
--- a/simulator/app/assets/htc-tornado/5.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/6.png b/simulator/app/assets/htc-tornado/6.png
deleted file mode 100644
index 509aae5..0000000
--- a/simulator/app/assets/htc-tornado/6.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/7.png b/simulator/app/assets/htc-tornado/7.png
deleted file mode 100644
index 1608777..0000000
--- a/simulator/app/assets/htc-tornado/7.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/8.png b/simulator/app/assets/htc-tornado/8.png
deleted file mode 100644
index 9fac3e6..0000000
--- a/simulator/app/assets/htc-tornado/8.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/9.png b/simulator/app/assets/htc-tornado/9.png
deleted file mode 100644
index 6a357cb..0000000
--- a/simulator/app/assets/htc-tornado/9.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/arrow-down.png b/simulator/app/assets/htc-tornado/arrow-down.png
deleted file mode 100644
index c00787f..0000000
--- a/simulator/app/assets/htc-tornado/arrow-down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/arrow-left.png b/simulator/app/assets/htc-tornado/arrow-left.png
deleted file mode 100644
index 1180a94..0000000
--- a/simulator/app/assets/htc-tornado/arrow-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/arrow-right.png b/simulator/app/assets/htc-tornado/arrow-right.png
deleted file mode 100644
index 6a511d2..0000000
--- a/simulator/app/assets/htc-tornado/arrow-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/arrow-up.png b/simulator/app/assets/htc-tornado/arrow-up.png
deleted file mode 100644
index da50871..0000000
--- a/simulator/app/assets/htc-tornado/arrow-up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/back.png b/simulator/app/assets/htc-tornado/back.png
deleted file mode 100644
index d12273d..0000000
--- a/simulator/app/assets/htc-tornado/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/background.png b/simulator/app/assets/htc-tornado/background.png
deleted file mode 100644
index 09169b8..0000000
--- a/simulator/app/assets/htc-tornado/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/home.png b/simulator/app/assets/htc-tornado/home.png
deleted file mode 100644
index 90775a8..0000000
--- a/simulator/app/assets/htc-tornado/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/internet.png b/simulator/app/assets/htc-tornado/internet.png
deleted file mode 100644
index 47f1bb4..0000000
--- a/simulator/app/assets/htc-tornado/internet.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/layout.xml b/simulator/app/assets/htc-tornado/layout.xml
deleted file mode 100644
index 55c1d65..0000000
--- a/simulator/app/assets/htc-tornado/layout.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<device name="HTC_Tornado">
-    <!-- title for menus -->
-    <title>HTC Tornado</title>
-
-    <!-- primary display characteristics -->
-    <display name="main" width="240" height="320" format="rgb565" refresh="30"/>
-
-    <!-- display is 33.84mm x 45.12mm -->
-
-	<mode name="default">
-		<view display="main" x="58" y="117" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-			<image src="background.png" x="0" y="0"/>
-
-			<!-- buttons for which we have highlight images -->
-			<button keyCode="soft-left"     src="soft-left.png"     x="49" y="450"/>
-			<button keyCode="soft-right"    src="soft-right.png"    x="249" y="450"/>
-			<button keyCode="home"          src="home.png"          x="115" y="450"/>
-			<button keyCode="back"          src="back.png"          x="182" y="450"/>
-			<button keyCode="dpad-up"       src="arrow-up.png"      x="159" y="542"/>
-			<button keyCode="dpad-down"     src="arrow-down.png"    x="160" y="573"/>
-			<button keyCode="dpad-left"       src="arrow-left.png"    x="152" y="549"/>
-			<button keyCode="dpad-right"     src="arrow-right.png"   x="183" y="549"/>
-			<button keyCode="dpad-center"   src="select.png"        x="167" y="556"/>
-
-			<button keyCode="1"             src="1.png"             x="51" y="595"/>
-			<button keyCode="2"             src="2.png"             x="133" y="595"/>
-			<button keyCode="3"             src="3.png"             x="221" y="595"/>
-			<button keyCode="4"             src="4.png"             x="51" y="633"/>
-			<button keyCode="5"             src="5.png"             x="133" y="633"/>
-			<button keyCode="6"             src="6.png"             x="221" y="633"/>
-			<button keyCode="7"             src="7.png"             x="51" y="666"/>
-			<button keyCode="8"             src="8.png"             x="133" y="666"/>
-			<button keyCode="9"             src="9.png"             x="221" y="666"/>
-			<button keyCode="0"             src="0.png"             x="133" y="699"/>
-			<button keyCode="star"          src="star.png"          x="51" y="699"/>
-			<button keyCode="pound"         src="pound.png"         x="221" y="699"/>
-
-			<button keyCode="phone-dial"	src="phone-dial.png"	x="51" y="547"/>
-			<button keyCode="phone-hangup"	src="phone-hangup.png"	x="221" y="547"/>
-
-			<button keyCode="internet"	src="internet.png"	x="52" y="490"/>
-			<button keyCode="skip-backward"	src="skip-backward.png"	x="121" y="490"/>
-			<button keyCode="pause-play"	src="pause-play.png"	x="191" y="490"/>
-			<button keyCode="skip-forward"	src="skip-forward.png"	x="260" y="490"/>
-
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-	</mode>
-
-</device>
-
diff --git a/simulator/app/assets/htc-tornado/pause-play.png b/simulator/app/assets/htc-tornado/pause-play.png
deleted file mode 100644
index ae74d9f..0000000
--- a/simulator/app/assets/htc-tornado/pause-play.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/phone-dial.png b/simulator/app/assets/htc-tornado/phone-dial.png
deleted file mode 100644
index 30bdf9e..0000000
--- a/simulator/app/assets/htc-tornado/phone-dial.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/phone-hangup.png b/simulator/app/assets/htc-tornado/phone-hangup.png
deleted file mode 100644
index 68fe47b..0000000
--- a/simulator/app/assets/htc-tornado/phone-hangup.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/pound.png b/simulator/app/assets/htc-tornado/pound.png
deleted file mode 100644
index 92e49cb..0000000
--- a/simulator/app/assets/htc-tornado/pound.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/select.png b/simulator/app/assets/htc-tornado/select.png
deleted file mode 100644
index a89db9a..0000000
--- a/simulator/app/assets/htc-tornado/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/skip-backward.png b/simulator/app/assets/htc-tornado/skip-backward.png
deleted file mode 100644
index 263b3d6..0000000
--- a/simulator/app/assets/htc-tornado/skip-backward.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/skip-forward.png b/simulator/app/assets/htc-tornado/skip-forward.png
deleted file mode 100644
index e069db1..0000000
--- a/simulator/app/assets/htc-tornado/skip-forward.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/soft-left.png b/simulator/app/assets/htc-tornado/soft-left.png
deleted file mode 100644
index ab6dff1..0000000
--- a/simulator/app/assets/htc-tornado/soft-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/soft-right.png b/simulator/app/assets/htc-tornado/soft-right.png
deleted file mode 100644
index 590982e..0000000
--- a/simulator/app/assets/htc-tornado/soft-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/htc-tornado/star.png b/simulator/app/assets/htc-tornado/star.png
deleted file mode 100644
index 9b7d79a..0000000
--- a/simulator/app/assets/htc-tornado/star.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/back.png b/simulator/app/assets/motorola-q/back.png
deleted file mode 100644
index 6be2512..0000000
--- a/simulator/app/assets/motorola-q/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/background.png b/simulator/app/assets/motorola-q/background.png
deleted file mode 100644
index d9b30ad..0000000
--- a/simulator/app/assets/motorola-q/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/down.png b/simulator/app/assets/motorola-q/down.png
deleted file mode 100644
index bbe3a18..0000000
--- a/simulator/app/assets/motorola-q/down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/end.png b/simulator/app/assets/motorola-q/end.png
deleted file mode 100644
index daff163..0000000
--- a/simulator/app/assets/motorola-q/end.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/home.png b/simulator/app/assets/motorola-q/home.png
deleted file mode 100644
index 4f65f91..0000000
--- a/simulator/app/assets/motorola-q/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/layout.xml b/simulator/app/assets/motorola-q/layout.xml
deleted file mode 100644
index c48bce6..0000000
--- a/simulator/app/assets/motorola-q/layout.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2006 The Android Open Source Project -->
-
-<device name="MotorolaQ">
-    <!-- title for menus -->
-    <title>Motorola Q</title>
-
-    <display name="main" width="320" height="240" format="rgb565" refresh="30"/>
-
-	<keyboard qwerty="1" />
-	
-    <mode name="default">
-        <!-- hiptop when closed -->
-        <view display="main" x="58" y="121" rotate="0">
-
-            <!-- surrounding device image and "patches", drawn in order -->
-            <image src="background.png" x="0" y="0"/>
-
-			<!-- buttons for which we have highlight images -->
-			<button keyCode="soft-left"     src="menu-left.png"     x="35"  y="385"/>
-			<button keyCode="soft-right"    src="menu-right.png"    x="270" y="385"/>
-			<button keyCode="home"          src="home.png"          x="92"  y="425"/>
-			<button keyCode="back"          src="back.png"          x="264" y="425"/>
- 			<button keyCode="dpad-up"       src="up.png"            x="166" y="400"/>
-			<button keyCode="dpad-down"     src="down.png"          x="166" y="444"/>
-			<button keyCode="dpad-left"     src="left.png"          x="158" y="406"/>
-			<button keyCode="dpad-right"    src="right.png"         x="224" y="406"/>
-			<button keyCode="dpad-center"   src="select.png"        x="194" y="419"/>
-
-			<button keyCode="phone-dial"	src="send.png"	        x="35"  y="421"/>
-			<button keyCode="phone-hangup"	src="end.png"	        x="333" y="422"/>
-        </view>
-    </mode>
-
-</device>
-
diff --git a/simulator/app/assets/motorola-q/left.png b/simulator/app/assets/motorola-q/left.png
deleted file mode 100644
index 3204f9b..0000000
--- a/simulator/app/assets/motorola-q/left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/menu-left.png b/simulator/app/assets/motorola-q/menu-left.png
deleted file mode 100644
index 4d1bc11..0000000
--- a/simulator/app/assets/motorola-q/menu-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/menu-right.png b/simulator/app/assets/motorola-q/menu-right.png
deleted file mode 100644
index 58f31c6..0000000
--- a/simulator/app/assets/motorola-q/menu-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/right.png b/simulator/app/assets/motorola-q/right.png
deleted file mode 100644
index b6190c9..0000000
--- a/simulator/app/assets/motorola-q/right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/select.png b/simulator/app/assets/motorola-q/select.png
deleted file mode 100644
index 343fb45..0000000
--- a/simulator/app/assets/motorola-q/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/send.png b/simulator/app/assets/motorola-q/send.png
deleted file mode 100644
index b3ebcd5..0000000
--- a/simulator/app/assets/motorola-q/send.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/motorola-q/up.png b/simulator/app/assets/motorola-q/up.png
deleted file mode 100644
index 7df6736..0000000
--- a/simulator/app/assets/motorola-q/up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/arrow-down.png b/simulator/app/assets/panasonic-x70/arrow-down.png
deleted file mode 100644
index 7ab16b4..0000000
--- a/simulator/app/assets/panasonic-x70/arrow-down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/arrow-up.png b/simulator/app/assets/panasonic-x70/arrow-up.png
deleted file mode 100644
index 6fb2454..0000000
--- a/simulator/app/assets/panasonic-x70/arrow-up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/back.png b/simulator/app/assets/panasonic-x70/back.png
deleted file mode 100644
index 04b91ef..0000000
--- a/simulator/app/assets/panasonic-x70/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/background.png b/simulator/app/assets/panasonic-x70/background.png
deleted file mode 100644
index 25bc3eb..0000000
--- a/simulator/app/assets/panasonic-x70/background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/home.png b/simulator/app/assets/panasonic-x70/home.png
deleted file mode 100644
index 12ac7bb..0000000
--- a/simulator/app/assets/panasonic-x70/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/layout.xml b/simulator/app/assets/panasonic-x70/layout.xml
deleted file mode 100644
index 0cb8bbd..0000000
--- a/simulator/app/assets/panasonic-x70/layout.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<device name="PanasonicX70">
-    <!-- title for menus -->
-    <title>Panasonic X70</title>
-
-    <display name="main" width="176" height="220" format="rgb565" refresh="30"/>
-
-	<mode name="default">
-		<!-- primary display characteristics -->
-		<view display="main" x="39" y="43" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-			<image src="background.png" x="0" y="0"/>
-
-			<button keyCode="soft-left"     src="soft-left.png"     x="45" y="324"/>
-			<button keyCode="soft-right"    src="soft-right.png"    x="146" y="324"/>
-			<button keyCode="home"          src="home.png"          x="21" y="345"/>
-			<button keyCode="back"          src="back.png"          x="180" y="347"/>
-			<button keyCode="dpad-up"       src="arrow-up.png"      x="88" y="348"/>
-			<button keyCode="dpad-down"     src="arrow-down.png"    x="95" y="414"/>
-            <button keyCode="dpad-left"/>
-            <button keyCode="dpad-right"/>
-			<button keyCode="dpad-center"   src="select.png"        x="101" y="377"/>
-
-            <button keyCode="1"/>
-            <button keyCode="2"/>
-            <button keyCode="3"/>
-            <button keyCode="4"/>
-            <button keyCode="5"/>
-            <button keyCode="6"/>
-            <button keyCode="7"/>
-            <button keyCode="8"/>
-            <button keyCode="9"/>
-            <button keyCode="0"/>
-            <button keyCode="star"/>
-            <button keyCode="pound"/>
-
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-	</mode>
-
-</device>
-
diff --git a/simulator/app/assets/panasonic-x70/select.png b/simulator/app/assets/panasonic-x70/select.png
deleted file mode 100644
index 993ecad..0000000
--- a/simulator/app/assets/panasonic-x70/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/soft-left.png b/simulator/app/assets/panasonic-x70/soft-left.png
deleted file mode 100644
index c384bb7..0000000
--- a/simulator/app/assets/panasonic-x70/soft-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/panasonic-x70/soft-right.png b/simulator/app/assets/panasonic-x70/soft-right.png
deleted file mode 100644
index 948e40f..0000000
--- a/simulator/app/assets/panasonic-x70/soft-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/0.png b/simulator/app/assets/samsung-flip-2005/0.png
deleted file mode 100644
index 839e6d1..0000000
--- a/simulator/app/assets/samsung-flip-2005/0.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/1.png b/simulator/app/assets/samsung-flip-2005/1.png
deleted file mode 100644
index 499cf6c..0000000
--- a/simulator/app/assets/samsung-flip-2005/1.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/2.png b/simulator/app/assets/samsung-flip-2005/2.png
deleted file mode 100644
index 93207cc..0000000
--- a/simulator/app/assets/samsung-flip-2005/2.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/3.png b/simulator/app/assets/samsung-flip-2005/3.png
deleted file mode 100644
index 499efdb..0000000
--- a/simulator/app/assets/samsung-flip-2005/3.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/4.png b/simulator/app/assets/samsung-flip-2005/4.png
deleted file mode 100644
index 775b15d..0000000
--- a/simulator/app/assets/samsung-flip-2005/4.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/5.png b/simulator/app/assets/samsung-flip-2005/5.png
deleted file mode 100644
index b8a5723..0000000
--- a/simulator/app/assets/samsung-flip-2005/5.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/6.png b/simulator/app/assets/samsung-flip-2005/6.png
deleted file mode 100644
index b6e0de9..0000000
--- a/simulator/app/assets/samsung-flip-2005/6.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/7.png b/simulator/app/assets/samsung-flip-2005/7.png
deleted file mode 100644
index 5416186..0000000
--- a/simulator/app/assets/samsung-flip-2005/7.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/8.png b/simulator/app/assets/samsung-flip-2005/8.png
deleted file mode 100644
index 2dfcae3..0000000
--- a/simulator/app/assets/samsung-flip-2005/8.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/9.png b/simulator/app/assets/samsung-flip-2005/9.png
deleted file mode 100644
index 6c11eed..0000000
--- a/simulator/app/assets/samsung-flip-2005/9.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/abc.png b/simulator/app/assets/samsung-flip-2005/abc.png
deleted file mode 100644
index 9f43afe..0000000
--- a/simulator/app/assets/samsung-flip-2005/abc.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/arrow-down.png b/simulator/app/assets/samsung-flip-2005/arrow-down.png
deleted file mode 100644
index 0f7ea7b..0000000
--- a/simulator/app/assets/samsung-flip-2005/arrow-down.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/arrow-left.png b/simulator/app/assets/samsung-flip-2005/arrow-left.png
deleted file mode 100644
index ad1982f..0000000
--- a/simulator/app/assets/samsung-flip-2005/arrow-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/arrow-right.png b/simulator/app/assets/samsung-flip-2005/arrow-right.png
deleted file mode 100644
index bf9cf48..0000000
--- a/simulator/app/assets/samsung-flip-2005/arrow-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/arrow-up.png b/simulator/app/assets/samsung-flip-2005/arrow-up.png
deleted file mode 100644
index ab62e33..0000000
--- a/simulator/app/assets/samsung-flip-2005/arrow-up.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/back-background.png b/simulator/app/assets/samsung-flip-2005/back-background.png
deleted file mode 100644
index 741db99..0000000
--- a/simulator/app/assets/samsung-flip-2005/back-background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/back.png b/simulator/app/assets/samsung-flip-2005/back.png
deleted file mode 100644
index 9eb9a17..0000000
--- a/simulator/app/assets/samsung-flip-2005/back.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/background-176_208.png b/simulator/app/assets/samsung-flip-2005/background-176_208.png
deleted file mode 100644
index 1ed1248..0000000
--- a/simulator/app/assets/samsung-flip-2005/background-176_208.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/background-176x220.png b/simulator/app/assets/samsung-flip-2005/background-176x220.png
deleted file mode 100644
index 361304e..0000000
--- a/simulator/app/assets/samsung-flip-2005/background-176x220.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/clear.png b/simulator/app/assets/samsung-flip-2005/clear.png
deleted file mode 100644
index f9c421c..0000000
--- a/simulator/app/assets/samsung-flip-2005/clear.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/end.png b/simulator/app/assets/samsung-flip-2005/end.png
deleted file mode 100644
index 5d0056c..0000000
--- a/simulator/app/assets/samsung-flip-2005/end.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/home-background.png b/simulator/app/assets/samsung-flip-2005/home-background.png
deleted file mode 100644
index 3ceee9c..0000000
--- a/simulator/app/assets/samsung-flip-2005/home-background.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/home.png b/simulator/app/assets/samsung-flip-2005/home.png
deleted file mode 100644
index 8510b7e..0000000
--- a/simulator/app/assets/samsung-flip-2005/home.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/layout.xml b/simulator/app/assets/samsung-flip-2005/layout.xml
deleted file mode 100644
index 3bc2ddd..0000000
--- a/simulator/app/assets/samsung-flip-2005/layout.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" ?>
-<!-- Copyright 2005 The Android Open Source Project -->
-
-<device name="Samsung1234">
-    <!-- title for menus -->
-    <title>Samsung Flip Phone</title>
-
-    <!-- primary display characteristics -->
-    <display name="main" width="176" height="220" format="rgb565" refresh="30"/>
-
-	<mode name="default">
-        <!-- our view of the device that shows the main display -->
-		<view display="main" x="49" y="73" rotate="0">
-
-			<!-- surrounding device image and "patches", drawn in order -->
-			<!-- (phone image is optional) -->
-			<image src="background-176x220.png" x="0" y="0"/>
-			<image src="home-background.png" x="22" y="426"/>
-			<image src="back-background.png" x="179" y="426"/>
-
-			<!-- buttons for which we have highlight images -->
-			<button keyCode="soft-left"     src="soft-left.png"     x="24" y="388"/>
-			<button keyCode="soft-right"    src="soft-right.png"    x="182" y="388"/>
-			<button keyCode="home"          src="home.png"          x="22" y="426"/>
-			<button keyCode="back"          src="back.png"          x="179" y="426"/>
-			<button keyCode="dpad-up"       src="arrow-up.png"      x="99" y="399"/>
-			<button keyCode="dpad-down"     src="arrow-down.png"    x="99" y="461"/>
-			<button keyCode="dpad-left"     src="arrow-left.png"    x="82" y="411"/>
-			<button keyCode="dpad-right"    src="arrow-right.png"   x="147" y="411"/>
-			<button keyCode="dpad-center"   src="select.png"        x="115" y="431"/>
-
-			<button keyCode="1"             src="1.png"             x="24" y="533"/>
-			<button keyCode="2"             src="2.png"             x="94" y="544"/>
-			<button keyCode="3"             src="3.png"             x="173" y="534"/>
-			<button keyCode="4"             src="4.png"             x="25" y="576"/>
-			<button keyCode="5"             src="5.png"             x="94" y="581"/>
-			<button keyCode="6"             src="6.png"             x="172" y="576"/>
-			<button keyCode="7"             src="7.png"             x="27" y="619"/>
-			<button keyCode="8"             src="8.png"             x="95" y="621"/>
-			<button keyCode="9"             src="9.png"             x="168" y="620"/>
-			<button keyCode="0"             src="0.png"             x="96" y="658"/>
-			<button keyCode="star"          src="star.png"          x="31" y="659"/>
-			<button keyCode="pound"         src="pound.png"         x="169" y="659"/>
-
-            <!-- buttons we haven't bothered to create highlight images for,
-                 or that aren't visible on-screen -->
-			<button keyCode="volume-up"/>
-			<button keyCode="volume-down"/>
-			<button keyCode="power"/>
-			<button keyCode="clear"/>
-
-		</view>
-	</mode>
-
-</device>
-
diff --git a/simulator/app/assets/samsung-flip-2005/menu.png b/simulator/app/assets/samsung-flip-2005/menu.png
deleted file mode 100644
index 7ac077c..0000000
--- a/simulator/app/assets/samsung-flip-2005/menu.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/pound.png b/simulator/app/assets/samsung-flip-2005/pound.png
deleted file mode 100644
index 22440bc..0000000
--- a/simulator/app/assets/samsung-flip-2005/pound.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/select.png b/simulator/app/assets/samsung-flip-2005/select.png
deleted file mode 100644
index 1c735f8..0000000
--- a/simulator/app/assets/samsung-flip-2005/select.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/send.png b/simulator/app/assets/samsung-flip-2005/send.png
deleted file mode 100644
index 23cea52..0000000
--- a/simulator/app/assets/samsung-flip-2005/send.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/soft-left.png b/simulator/app/assets/samsung-flip-2005/soft-left.png
deleted file mode 100644
index 224d281..0000000
--- a/simulator/app/assets/samsung-flip-2005/soft-left.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/soft-right.png b/simulator/app/assets/samsung-flip-2005/soft-right.png
deleted file mode 100644
index a8eec97..0000000
--- a/simulator/app/assets/samsung-flip-2005/soft-right.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/assets/samsung-flip-2005/star.png b/simulator/app/assets/samsung-flip-2005/star.png
deleted file mode 100644
index 457348d..0000000
--- a/simulator/app/assets/samsung-flip-2005/star.png
+++ /dev/null
Binary files differ
diff --git a/simulator/app/help/unnamed.htb b/simulator/app/help/unnamed.htb
deleted file mode 100644
index 3933e69..0000000
--- a/simulator/app/help/unnamed.htb
+++ /dev/null
Binary files differ
diff --git a/simulator/wrapsim/Android.mk b/simulator/wrapsim/Android.mk
deleted file mode 100644
index ca9a592..0000000
--- a/simulator/wrapsim/Android.mk
+++ /dev/null
@@ -1,58 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-
-#
-# Build instructions for simulator LD_PRELOAD wrapper.
-#
-ifneq ($(TARGET_ARCH),arm)
-ifeq ($(TARGET_SIMULATOR),true)
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := \
-	BitVector.c \
-	DevAudio.c \
-	DevConsoleTty.c \
-	DevEvent.c \
-	DevFb.c \
-	DevLog.c \
-	DevPower.c \
-	DevVibrator.c \
-	FakeDev.c \
-	Init.c \
-	Intercept.c \
-	Log.c \
-	SimMgr.c
-
-LOCAL_C_INCLUDES += prebuilt/common/esd
-
-LOCAL_MODULE := libwrapsim
-
-# Relying on other Android libraries is probably a bad idea, since any
-# library or system calls they make could lead to recursive behavior.
-LOCAL_LDLIBS += -lpthread -ldl
-
-ifeq ($(BUILD_SIM_WITHOUT_AUDIO),true)
-LOCAL_CFLAGS += -DBUILD_SIM_WITHOUT_AUDIO=1
-else
-LOCAL_LDLIBS += -lesd
-endif
-
-include $(BUILD_SHARED_LIBRARY)
-
-
-
-#
-# Build instructions for simulator runtime launch wrapper.
-#
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := \
-	LaunchWrapper.c
-
-LOCAL_MODULE := launch-wrapper
-include $(BUILD_EXECUTABLE)
-
-endif # ifeq ($(TARGET_SIMULATOR),true)
-endif
-# ifneq ($(TARGET_ARCH),arm)
diff --git a/simulator/wrapsim/BitVector.c b/simulator/wrapsim/BitVector.c
deleted file mode 100644
index aaa1408..0000000
--- a/simulator/wrapsim/BitVector.c
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Simple bit vector.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <stdint.h>
-#include <string.h>
-#include <assert.h>
-
-#define kBitVectorGrowth    4   /* increase by 4 uint32_t when limit hit */
-
-
-/*
- * Allocate a bit vector with enough space to hold at least the specified
- * number of bits.
- */
-BitVector* wsAllocBitVector(int startBits, int isExpandable)
-{
-    BitVector* bv;
-    int count;
-
-    assert(sizeof(bv->storage[0]) == 4);        /* assuming 32-bit units */
-    assert(startBits > 0);
-
-    bv = (BitVector*) malloc(sizeof(BitVector));
-
-    count = (startBits + 31) >> 5;
-
-    bv->storageSize = count;
-    bv->isExpandable = isExpandable;
-    bv->storage = (uint32_t*) malloc(count * sizeof(uint32_t));
-    memset(bv->storage, 0xff, count * sizeof(uint32_t));
-    return bv;
-}
-
-/*
- * Free a BitVector.
- */
-void wsFreeBitVector(BitVector* pBits)
-{
-    if (pBits == NULL)
-        return;
-
-    free(pBits->storage);
-    free(pBits);
-}
-
-/*
- * "Allocate" the first-available bit in the bitmap.
- *
- * This is not synchronized.  The caller is expected to hold some sort of
- * lock that prevents multiple threads from executing simultaneously in
- * dvmAllocBit/dvmFreeBit.
- *
- * The bitmap indicates which resources are free, so we use '1' to indicate
- * available and '0' to indicate allocated.
- */
-int wsAllocBit(BitVector* pBits)
-{
-    int word, bit;
-
-retry:
-    for (word = 0; word < pBits->storageSize; word++) {
-        if (pBits->storage[word] != 0) {
-            /*
-             * There are unallocated bits in this word.  Return the first.
-             */
-            bit = ffs(pBits->storage[word]) -1;
-            assert(bit >= 0 && bit < 32);
-            pBits->storage[word] &= ~(1 << bit);
-            return (word << 5) | bit;
-        }
-    }
-
-    /*
-     * Ran out of space, allocate more if we're allowed to.
-     */
-    if (!pBits->isExpandable)
-        return -1;
-
-    pBits->storage = realloc(pBits->storage,
-                    (pBits->storageSize + kBitVectorGrowth) * sizeof(uint32_t));
-    memset(&pBits->storage[pBits->storageSize], 0xff,
-        kBitVectorGrowth * sizeof(uint32_t));
-    pBits->storageSize += kBitVectorGrowth;
-    goto retry;
-}
-
-/*
- * Mark the specified bit as "free".
- */
-void wsFreeBit(BitVector* pBits, int num)
-{
-    assert(num >= 0 &&
-           num < (int) pBits->storageSize * (int)sizeof(uint32_t) * 8);
-
-    pBits->storage[num >> 5] |= 1 << (num & 0x1f);
-}
-
diff --git a/simulator/wrapsim/BitVector.h b/simulator/wrapsim/BitVector.h
deleted file mode 100644
index 048cf91..0000000
--- a/simulator/wrapsim/BitVector.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Simple bit vector.
- */
-#ifndef _WRAPSIM_BITVECTOR_H
-#define _WRAPSIM_BITVECTOR_H
-
-#include <stdint.h>
-
-/*
- * Expanding bitmap, used for tracking resources.  Bits are numbered starting
- * from zero.
- */
-typedef struct BitVector {
-    int         isExpandable;   /* expand bitmap if we run out? */
-    int         storageSize;    /* current size, in 32-bit words */
-    uint32_t*   storage;
-} BitVector;
-
-/* allocate a bit vector with enough space to hold "startBits" bits */
-BitVector* wsAllocBitVector(int startBits, int isExpandable);
-void wsFreeBitVector(BitVector* pBits);
-
-/*
- * Set/clear a single bit; assumes external synchronization.
- *
- * We always allocate the first possible bit.  If we run out of space in
- * the bitmap, and it's not marked expandable, dvmAllocBit returns -1.
- */
-int wsAllocBit(BitVector* pBits);
-void wsFreeBit(BitVector* pBits, int num);
-
-#endif /*_WRAPSIM_BITVECTOR_H*/
diff --git a/simulator/wrapsim/Common.h b/simulator/wrapsim/Common.h
deleted file mode 100644
index a9c3bb8..0000000
--- a/simulator/wrapsim/Common.h
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Common defines and includes.
- */
-#ifndef _WRAPSIM_COMMON_H
-#define _WRAPSIM_COMMON_H
-
-#include <unistd.h>
-#include <sys/types.h>
-
-#include "BitVector.h"
-#include "FakeDev.h"
-#include "Log.h"
-#include "SimMgr.h"
-#include "Globals.h"
-
-#endif /*_WRAPSIM_COMMON_H*/
diff --git a/simulator/wrapsim/DevAudio.c b/simulator/wrapsim/DevAudio.c
deleted file mode 100644
index 752ee65..0000000
--- a/simulator/wrapsim/DevAudio.c
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Audio output device.
- */
-#include "Common.h"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <esd.h>
-
-#include <fcntl.h>
-#include <sys/ioctl.h>
-#include <linux/input.h>
-
-
-/*
- * Input event device state.
- */
-typedef struct AudioState {
-    int fd;
-    int sourceId;
-    int esdVol;
-    int streamType;
-} AudioState;
-
-/*
- * Set some stuff up.
- */
-static int configureInitialState(const char* pathName, AudioState* audioState)
-{
-#if BUILD_SIM_WITHOUT_AUDIO
-    return 0;
-#else
-    esd_player_info_t *pi; 
-    audioState->fd = -1;
-    audioState->sourceId = -1;
-    audioState->esdVol = -1;
-    audioState->streamType = 0;
-
-    int format = ESD_BITS16 | ESD_STEREO | ESD_STREAM | ESD_PLAY;
-    char namestring[] = "Android Audio XXXXXXXX";
-    sprintf(namestring,"Android Audio %08x", (unsigned int)audioState);
-    int esd_fd = esd_play_stream_fallback(format, 44100, NULL, namestring);
-    if (esd_fd > 0) {
-        // find the source_id for this stream
-        int mix = esd_open_sound(NULL);
-        if (mix > 0) {
-            esd_info_t *info = esd_get_all_info(mix);
-
-            if (info) {
-                for(pi = info->player_list; pi; pi = pi->next) {
-                    if(strcmp(pi->name, namestring) == 0) {
-                        audioState->sourceId = pi->source_id;
-                        break;
-                    }
-                }
-                esd_free_all_info(info);
-            }
-            esd_close(mix);
-        }
-        audioState->fd = esd_fd;
-        return 0;
-    }
-    printf("Couldn't open audio device. Faking it.\n");
-    return 0;
-#endif
-}
-
-/*
- * Return the next available input event.
- *
- * We just pass this through to the real "write", since "fd" is real.
- */
-static ssize_t writeAudio(FakeDev* dev, int fd, const void* buf, size_t count)
-{
-#if BUILD_SIM_WITHOUT_AUDIO
-    return 0;
-#else
-    AudioState *state = (AudioState*)dev->state;
-    if (state->fd >= 0)
-        return _ws_write(state->fd, buf, count);
-
-    // fake timing
-    usleep(count * 10000 / 441 * 4);
-    return count;
-#endif
-}
-
-/*
- * Handle event ioctls.
- */
-static int ioctlAudio(FakeDev* dev, int fd, int request, void* argp)
-{
-    return -1;
-}
-
-/*
- * Free up our state before closing down the fake descriptor.
- */
-static int closeAudio(FakeDev* dev, int fd)
-{
-#if BUILD_SIM_WITHOUT_AUDIO
-    return 0;
-#else
-    AudioState *state = (AudioState*)dev->state;
-    close(state->fd);
-    free(state);
-    dev->state = NULL;
-    return 0;
-#endif
-}
-
-/*
- * Open an audio output device.
- */
-FakeDev* wsOpenDevAudio(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->write = writeAudio;
-        newDev->ioctl = ioctlAudio;
-        newDev->close = closeAudio;
-
-        AudioState* eventState = calloc(1, sizeof(AudioState));
-
-        if (configureInitialState(pathName, eventState) != 0) {
-            free(eventState);
-            return NULL;
-        }
-        newDev->state = eventState;
-    }
-
-    return newDev;
-}
diff --git a/simulator/wrapsim/DevConsoleTty.c b/simulator/wrapsim/DevConsoleTty.c
deleted file mode 100644
index 166d648..0000000
--- a/simulator/wrapsim/DevConsoleTty.c
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Console tty device.
- */
-#include "Common.h"
-
-#include <string.h>
-
-#include <sys/ioctl.h>
-#include <linux/vt.h>
-
-
-/*
- * Handle the various console ioctls, most of which we can just ignore.
- */
-static int ioctlConsoleTty(FakeDev* dev, int fd, int request, void* argp)
-{
-    wsLog("%s: ioctl(0x%x, %p)\n", dev->debugName, request, argp);
-    switch (request) {
-    case VT_GETSTATE:       // struct vt_stat*
-        /*
-         * Looks like they want vs.v_active.  This just gets fed back into
-         * another console ioctl, so we don't really need to do anything.
-         * We zero out the struct so the data will at least appear to be
-         * initialized.
-         */
-        memset(argp, 0, sizeof(struct vt_stat));
-        break;
-    case VT_OPENQRY:        // int*
-        /* they want the console number */
-        *(int*)argp = 123;
-        break;
-    default:
-        /* ignore anything we don't understand */
-        break;
-    }
-
-    return 0;
-}
-
-/*
- * Open the console TTY device, which responds to a collection of ioctl()s.
- */
-FakeDev* wsOpenDevConsoleTty(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->ioctl = ioctlConsoleTty;
-    }
-    return newDev;
-}
-
diff --git a/simulator/wrapsim/DevEvent.c b/simulator/wrapsim/DevEvent.c
deleted file mode 100644
index 692856e..0000000
--- a/simulator/wrapsim/DevEvent.c
+++ /dev/null
@@ -1,414 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Input event device.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-
-#include <fcntl.h>
-#include <sys/ioctl.h>
-#include <linux/input.h>
-
-
-/*
- * Input event device state.
- */
-typedef struct EventState {
-    struct input_id ident;
-
-    char*   name;
-    char*   location;
-    char*   idstr;
-    int     protoVersion;
-} EventState;
-
-/*
- * Key bit mask, for EVIOCGBIT(EV_KEY).
- *
- * (For now, just pretend to be a "goldfish" like the emulator.)
- */
-static const unsigned char gKeyBitMask[64] = {
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-    0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
-};
-
-/*
- * Set some stuff up.
- */
-static void configureInitialState(const char* pathName, EventState* eventState)
-{
-    /*
-     * Swim like a goldfish.
-     */
-    eventState->ident.bustype = 0;
-    eventState->ident.vendor = 0;
-    eventState->ident.product = 0;
-    eventState->ident.version = 0;
-
-    eventState->name = strdup(gWrapSim.keyMap);
-    eventState->location = strdup("");
-    eventState->idstr = strdup("");
-    eventState->protoVersion = 0x010000;
-}
-
-/*
- * Free up the state structure.
- */
-static void freeState(EventState* eventState)
-{
-    if (eventState != NULL) {
-        free(eventState->name);
-        free(eventState->location);
-        free(eventState->idstr);
-        free(eventState);
-    }
-}
-
-/*
- * Handle one of the EVIOCGABS requests.
- *
- * Currently not doing much here.
- */
-static void handleAbsGet(int reqIdx, void* argp)
-{
-    struct input_absinfo info;
-
-    switch (reqIdx) {
-    case ABS_X:
-        wsLog("  req for abs X\n");
-        break;
-    case ABS_Y:
-        wsLog("  req for abs Y\n");
-        break;
-    case ABS_PRESSURE:
-        wsLog("  req for abs PRESSURE\n");
-        break;
-    case ABS_TOOL_WIDTH:
-        wsLog("  req for abs TOOL_WIDTH\n");
-        break;
-    default:
-        wsLog("  req for unexpected event abs 0x%02x\n", reqIdx);
-        break;
-    }
-
-    memset(&info, 0, sizeof(info));
-    memcpy(argp, &info, sizeof(struct input_absinfo));
-}
-
-/*
- * Return the next available input event.
- *
- * We just pass this through to the real "read", since "fd" is real.
- */
-static ssize_t readEvent(FakeDev* dev, int fd, void* buf, size_t count)
-{
-    return _ws_read(fd, buf, count);
-}
-
-/*
- * Somebody is trying to write to the event pipe.  This can be used to set
- * the state of LED.
- */
-static ssize_t writeEvent(FakeDev* dev, int fd, const void* buf, size_t count)
-{
-    const struct input_event* piev;
-
-    if (count == sizeof(*piev)) {
-        piev = (const struct input_event*) buf;
-
-        if (piev->type == EV_LED) {
-            wsLog("%s: set LED code=%d value=%d\n",
-                dev->debugName, piev->code, piev->value);
-        } else {
-            wsLog("%s: writeEvent got %d bytes, type=%d\n",
-                dev->debugName, count, piev->type);
-        }
-    } else {
-        wsLog("%s: warning: writeEvent got %d bytes, not sure why\n",
-            dev->debugName, count);
-    }
-
-    return count;
-}
-
-/*
- * Handle event ioctls.
- */
-static int ioctlEvent(FakeDev* dev, int fd, int request, void* argp)
-{
-    EventState* state = (EventState*) dev->state;
-    unsigned int urequest = (unsigned int) request;
-
-    wsLog("%s: ioctl(0x%x, %p)\n", dev->debugName, urequest, argp);
-
-    if (_IOC_TYPE(urequest) != _IOC_TYPE(EVIOCGVERSION)) {
-        wsLog("%s: inappropriate ioctl 0x%08x\n", dev->debugName, urequest);
-        return -1;
-    }
-
-    if (urequest == EVIOCGVERSION) {
-        *(int*)argp = state->protoVersion;
-    } else if (urequest == EVIOCGID) {
-        memcpy(argp, &state->ident, sizeof(struct input_id));
-    } else if (_IOC_NR(urequest) == _IOC_NR(EVIOCGNAME(0))) {
-        int maxLen = _IOC_SIZE(urequest);
-        int strLen = (int) strlen(state->name);
-        if (strLen >= maxLen) {
-            errno = EINVAL;
-            return -1;
-        }
-        memcpy(argp, state->name, strLen+1);
-        return strLen;
-    } else if (_IOC_NR(urequest) == _IOC_NR(EVIOCGPHYS(0))) {
-        int maxLen = _IOC_SIZE(urequest);
-        int strLen = (int) strlen(state->location);
-        if (strLen >= maxLen) {
-            errno = EINVAL;
-            return -1;
-        }
-        memcpy(argp, state->location, strLen+1);
-        return strLen;
-    } else if (_IOC_NR(urequest) == _IOC_NR(EVIOCGUNIQ(0))) {
-        /* device doesn't seem to support this, neither will we */
-        return -1;
-    } else if (_IOC_NR(urequest) == _IOC_NR(EVIOCGBIT(EV_KEY,0))) {
-        /* keys */
-        int maxLen = _IOC_SIZE(urequest);
-        if (maxLen > (int) sizeof(gKeyBitMask))
-            maxLen = sizeof(gKeyBitMask);
-        memcpy(argp, gKeyBitMask, maxLen);
-    } else if (_IOC_NR(urequest) == _IOC_NR(EVIOCGBIT(EV_REL,0))) {
-        /* relative controllers (trackball) */
-        int maxLen = _IOC_SIZE(urequest);
-        memset(argp, 0xff, maxLen);
-    } else if (!getenv("NOTOUCH") && _IOC_NR(urequest) == _IOC_NR(EVIOCGBIT(EV_ABS,0))) {
-        // absolute controllers (touch screen)
-        int maxLen = _IOC_SIZE(urequest);
-        memset(argp, 0xff, maxLen);
-
-    } else if (_IOC_NR(urequest) >= _IOC_NR(EVIOCGABS(ABS_X)) &&
-               _IOC_NR(urequest) <= _IOC_NR(EVIOCGABS(ABS_MAX)))
-    {
-        /* get abs value / limits */
-        int reqIdx = _IOC_NR(urequest) - _IOC_NR(EVIOCGABS(ABS_X));
-        handleAbsGet(reqIdx, argp);
-    } else {
-        wsLog("GLITCH: UNKNOWN ioctl request 0x%x on %s\n",
-            urequest, dev->debugName);
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Free up our state before closing down the fake descriptor.
- */
-static int closeEvent(FakeDev* dev, int fd)
-{
-    freeState((EventState*)dev->state);
-    dev->state = NULL;
-    if (gWrapSim.keyInputDevice == dev) {
-        gWrapSim.keyInputDevice = NULL;
-        wsLog("Sim input device closed\n");
-    }
-    return 0;
-}
-
-/*
- * Open an input event device.
- */
-FakeDev* wsOpenDevEvent(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateRealFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->read = readEvent;
-        newDev->write = writeEvent;
-        newDev->ioctl = ioctlEvent;
-        newDev->close = closeEvent;
-
-        EventState* eventState = calloc(1, sizeof(EventState));
-
-        configureInitialState(pathName, eventState);
-        newDev->state = eventState;
-
-        /*
-         * First one opened becomes the place where we queue up input
-         * events from the simulator.  This approach will fail if the
-         * app opens the device, then opens it a second time for input,
-         * then closes the first.  The app doesn't currently do this (though
-         * it does do quick opens to fiddle with LEDs).
-         */
-        if (gWrapSim.keyInputDevice == NULL) {
-            gWrapSim.keyInputDevice = newDev;
-            wsLog("Device %p / %d will receive sim input events\n",
-                newDev, newDev->fd);
-        }
-    }
-
-    return newDev;
-}
-
-/*
- * Write a key event.
- */
-static int sendKeyEvent(FakeDev* dev, int code, int isDown)
-{
-    struct input_event iev;
-    ssize_t actual;
-
-    gettimeofday(&iev.time, NULL);
-    iev.type = EV_KEY;
-    iev.code = code;
-    iev.value = (isDown != 0) ? 1 : 0;
-
-    actual = _ws_write(dev->otherFd, &iev, sizeof(iev));
-    if (actual != (ssize_t) sizeof(iev)) {
-        wsLog("WARNING: send key event partial write (%d of %d)\n",
-            actual, sizeof(iev));
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Write an absolute (touch screen) event.
- */
-static int sendAbsButton(FakeDev* dev, int x, int y, int isDown)
-{
-    struct input_event iev;
-    ssize_t actual;
-
-    wsLog("absButton x=%d y=%d down=%d\n", x, y, isDown);
-
-    gettimeofday(&iev.time, NULL);
-    iev.type = EV_KEY;
-    iev.code = BTN_TOUCH;
-    iev.value = (isDown != 0) ? 1 : 0;
-
-    actual = _ws_write(dev->otherFd, &iev, sizeof(iev));
-    if (actual != (ssize_t) sizeof(iev)) {
-        wsLog("WARNING: send touch event partial write (%d of %d)\n",
-            actual, sizeof(iev));
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Write an absolute (touch screen) event.
- */
-static int sendAbsMovement(FakeDev* dev, int x, int y)
-{
-    struct input_event iev;
-    ssize_t actual;
-
-    wsLog("absMove x=%d y=%d\n", x, y);
-
-    gettimeofday(&iev.time, NULL);
-    iev.type = EV_ABS;
-    iev.code = ABS_X;
-    iev.value = x;
-
-    actual = _ws_write(dev->otherFd, &iev, sizeof(iev));
-    if (actual != (ssize_t) sizeof(iev)) {
-        wsLog("WARNING: send abs movement event partial X write (%d of %d)\n",
-            actual, sizeof(iev));
-        return -1;
-    }
-
-    iev.code = ABS_Y;
-    iev.value = y;
-
-    actual = _ws_write(dev->otherFd, &iev, sizeof(iev));
-    if (actual != (ssize_t) sizeof(iev)) {
-        wsLog("WARNING: send abs movement event partial Y write (%d of %d)\n",
-            actual, sizeof(iev));
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Not quite sure what this is for, but the emulator does it.
- */
-static int sendAbsSyn(FakeDev* dev)
-{
-    struct input_event iev;
-    ssize_t actual;
-
-    gettimeofday(&iev.time, NULL);
-    iev.type = EV_SYN;
-    iev.code = 0;
-    iev.value = 0;
-
-    actual = _ws_write(dev->otherFd, &iev, sizeof(iev));
-    if (actual != (ssize_t) sizeof(iev)) {
-        wsLog("WARNING: send abs movement syn (%d of %d)\n",
-            actual, sizeof(iev));
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Send a key event to the fake key event device.
- *
- * We have to translate the simulator key event into one or more device
- * key events.
- */
-void wsSendSimKeyEvent(int key, int isDown)
-{
-    FakeDev* dev;
-    EventState* state;
-
-    dev = gWrapSim.keyInputDevice;
-    if (dev == NULL)
-        return;
-
-    sendKeyEvent(dev, key, isDown);
-}
-
-/*
- * Send a touch-screen event to the fake key event device.
- *
- * We have to translate the simulator key event into one or more device
- * key events.
- */
-void wsSendSimTouchEvent(int action, int x, int y)
-{
-    FakeDev* dev;
-    EventState* state;
-
-    dev = gWrapSim.keyInputDevice;
-    if (dev == NULL)
-        return;
-
-    if (action == kTouchDown) {
-        sendAbsMovement(dev, x, y);
-        sendAbsButton(dev, x, y, 1);
-        sendAbsSyn(dev);
-    } else if (action == kTouchUp) {
-        sendAbsButton(dev, x, y, 0);
-        sendAbsSyn(dev);
-    } else if (action == kTouchDrag) {
-        sendAbsMovement(dev, x, y);
-        sendAbsSyn(dev);
-    } else {
-        wsLog("WARNING: unexpected sim touch action  %d\n", action);
-    }
-}
-
diff --git a/simulator/wrapsim/DevFb.c b/simulator/wrapsim/DevFb.c
deleted file mode 100644
index c54403e..0000000
--- a/simulator/wrapsim/DevFb.c
+++ /dev/null
@@ -1,267 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Fake device support.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <assert.h>
-
-#include <sys/mman.h>
-#include <sys/ioctl.h>
-#include <linux/fb.h>
-
-typedef struct FbState {
-    /* index into gWrapSim.display[] */
-    int     displayIdx;
-
-    /* VRAM address, set by mmap() call */
-    void*   vramAddr;
-
-    /* kernel data structures */
-    struct fb_var_screeninfo    vinfo;
-    struct fb_fix_screeninfo    finfo;
-} FbState;
-
-
-/*
- * Set up the initial values of the structs.
- *
- * The FbState struct is zeroed out initially, so we only need to set the
- * fields that don't default to zero.
- */
-static void configureInitialState(int displayIdx, FbState* fbState)
-{
-    int width, height;
-
-    assert(displayIdx >= 0 && displayIdx < gWrapSim.numDisplays);
-
-    width = gWrapSim.display[displayIdx].width;
-    height = gWrapSim.display[displayIdx].height;
-    wsLog("Configuring FbState for display %d (%dx%x key=0x%08x)\n",
-        displayIdx, width, height, gWrapSim.display[displayIdx].shmemKey);
-
-    /* fb_fix_screeninfo */
-    strcpy(fbState->finfo.id, "omapfb");
-    fbState->finfo.smem_len = (width * 2) * height * 2;
-    fbState->finfo.line_length = width * 2;
-
-    /* fb_var_screeninfo */
-    fbState->vinfo.xres = width;
-    fbState->vinfo.yres = height;
-    fbState->vinfo.xres_virtual = width;
-    fbState->vinfo.yres_virtual = height * 2;
-    fbState->vinfo.bits_per_pixel = 16;
-
-    fbState->vinfo.red.offset = 11;
-    fbState->vinfo.red.length = 5;
-    fbState->vinfo.green.offset = 5;
-    fbState->vinfo.green.length = 6;
-    fbState->vinfo.blue.offset = 0;
-    fbState->vinfo.blue.length = 5;
-
-    fbState->vinfo.width = 51;           // physical dimension, used for dpi
-    fbState->vinfo.height = 76;
-
-    fbState->vinfo.pixclock = 103092;    
-    fbState->vinfo.upper_margin = 3;
-    fbState->vinfo.lower_margin = 227;
-    fbState->vinfo.left_margin = 12;
-    fbState->vinfo.right_margin = 8;
-}
-
-/*
- * Free allocated state.
- */
-static void freeState(FbState* fbState)
-{
-    free(fbState);
-}
-
-/*
- * Wait for our synthetic vsync to happen.
- */
-static void waitForVsync(FbState* state)
-{
-    /* TODO: simulate a real interval */
-    usleep(1000000/60);
-}
-
-/*
- * Forward pixels to the simulator.
- */
-static void sendPixelsToSim(FbState* state)
-{
-    if (state->vramAddr == 0) {
-        wsLog("## not sending pixels (no addr yet)\n");
-        return;
-    }
-
-    //wsLog("+++ sending pixels to sim (disp=%d yoff=%d)\n",
-    //    state->displayIdx, state->vinfo.yoffset);
-
-    wsLockDisplay(state->displayIdx);
-
-    uint8_t* dst = gWrapSim.display[state->displayIdx].addr;
-
-    int l,t,r,b,w,h;
-    w = gWrapSim.display[state->displayIdx].width;
-    h = gWrapSim.display[state->displayIdx].height;
-
-#if 0
-    /*
-     * TODO: surfaceflinger encodes the dirty region in vinfo.reserved[].  We
-     * can use that to perform a partial update.
-     */
-    const Rect dirty(dirtyReg.bounds());
-    l = dirty.left  >=0 ? dirty.left : 0;
-    t = dirty.top   >=0 ? dirty.top  : 0;
-    r = dirty.right <=w ? dirty.right  : w;
-    b = dirty.bottom<=h ? dirty.bottom : h;
-#else
-    l = t = 0;
-    r = w;
-    b = h;
-#endif
-
-    /* find the right page */
-    int ypage = state->vinfo.yoffset;
-
-    int x, y;
-    for (y = t ; y < b ; y++) {
-        // no "stride" issues with this display
-        uint8_t* outPtr = dst + (y*w+l)*3;
-        const uint16_t* ptr16 = (uint16_t*)state->vramAddr + ((y+ypage)*w+l);
-        for (x = l; x < r; x++) {
-            uint16_t in = *ptr16++;
-            uint32_t R,G,B;
-            R = ((in>>8)&0xF8) | (in>>(8+5));
-            G = (in & 0x7E0)>>3;
-            G |= G>>6;
-            B = (in & 0x1F)<<3;
-            B |= B>>5;
-            *outPtr++ = R;
-            *outPtr++ = G;
-            *outPtr++ = B;
-        }
-    }
-
-    wsUnlockDisplay(state->displayIdx);
-
-    /* notify the simulator */
-    wsPostDisplayUpdate(state->displayIdx);
-}
-
-/*
- * Provide a memory-mapped region for framebuffer data.  We want to use a
- * real mmap() call, not fake it with a malloc, so that related calls
- * (munmap, madvise) will just work.
- */
-static void* mmapFb(FakeDev* dev, void* start, size_t length, int prot,
-    int flags, int fd, __off_t offset)
-{
-    FbState* state = (FbState*) dev->state;
-    void* map;
-
-    /* be reasonable */
-    if (length > (640*480*2)*4) {
-        errno = EINVAL;
-        return MAP_FAILED;
-    }
-
-    /* this is supposed to be VRAM, so just map a chunk */
-    map = mmap(start, length, prot, MAP_PRIVATE | MAP_ANON, -1, 0);
-
-    /* update our "VRAM address"; this feels a bit fragile */
-    if (state->vramAddr != NULL) {
-        wsLog("%s: NOTE: changing vram address from %p\n",
-            dev->debugName, state->vramAddr);
-    }
-    state->vramAddr = map;
-
-    wsLog("%s: mmap %u bytes --> %p\n", dev->debugName, length, map);
-    return map;
-}
-
-/*
- * Handle framebuffer ioctls.
- */
-static int ioctlFb(FakeDev* dev, int fd, int request, void* argp)
-{
-    FbState* state = (FbState*) dev->state;
-
-    wsLog("%s: ioctl(0x%x, %p)\n", dev->debugName, request, argp);
-
-    switch (request) {
-    case FBIOGET_FSCREENINFO:       // struct fb_fix_screeninfo*
-        memcpy(argp, &state->finfo, sizeof(struct fb_fix_screeninfo));
-        break;
-    case FBIOGET_VSCREENINFO:       // struct fb_var_screeninfo*
-        memcpy(argp, &state->vinfo, sizeof(struct fb_var_screeninfo));
-        break;
-    case FBIOPUT_VSCREENINFO:       // struct fb_var_screeninfo*
-        memcpy(&state->vinfo, argp, sizeof(struct fb_var_screeninfo));
-        if (state->vinfo.activate == FB_ACTIVATE_NOW) {
-            //wsLog("%s: activate now\n", dev->debugName);
-            sendPixelsToSim(state);
-        } else if (state->vinfo.activate == FB_ACTIVATE_VBL) {
-            //wsLog("%s: activate on VBL\n", dev->debugName);
-            sendPixelsToSim(state);
-            /* we wait *after* so other process gets scheduled to draw */
-            waitForVsync(state);
-        } else {
-            wsLog("%s: activate value is %d\n",
-                dev->debugName, state->vinfo.activate);
-        }
-        break;
-    case FBIOGET_VBLANK:            // struct fb_vblank*
-        /* the device doesn't actually implement this */
-        //memset(argp, 0, sizeof(struct fb_vblank));
-        errno = EINVAL;
-        return -1;
-    default:
-    /*case FBIO_WAITFORVSYNC:*/
-        wsLog("GLITCH: UNKNOWN ioctl request 0x%x on %s\n",
-            request, dev->debugName);
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Free up our state before closing down the fake descriptor.
- */
-static int closeFb(FakeDev* dev, int fd)
-{
-    freeState((FbState*)dev->state);
-    dev->state = NULL;
-    return 0;
-}
-
-/*
- * Open the console TTY device, which responds to a collection of ioctl()s.
- */
-FakeDev* wsOpenDevFb(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->mmap = mmapFb;
-        newDev->ioctl = ioctlFb;
-        newDev->close = closeFb;
-
-        FbState* fbState = calloc(1, sizeof(FbState));
-
-        /* establish a connection to the front-end if necessary */
-        /* (also gets display configuration) */
-        wsSimConnect();
-
-        configureInitialState(0, fbState);  // always use display 0 for now
-        newDev->state = fbState;
-    }
-
-    return newDev;
-}
-
diff --git a/simulator/wrapsim/DevLog.c b/simulator/wrapsim/DevLog.c
deleted file mode 100644
index fe1144d..0000000
--- a/simulator/wrapsim/DevLog.c
+++ /dev/null
@@ -1,485 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Log devices.  We want to filter and display messages, with separate
- * treatment for "debug" and "event" logs.
- *
- * All messages are just dumped to stderr.
- */
-#include "Common.h"
-
-#include "cutils/logd.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-
-#include <fcntl.h>
-
-#define kMaxTagLen  16      /* from utils/Log.cpp */
-
-#define kTagSetSize 16      /* arbitrary */
-
-/* from utils/Log.cpp */
-typedef enum {
-    FORMAT_OFF = 0,
-    FORMAT_BRIEF,
-    FORMAT_PROCESS,
-    FORMAT_TAG,
-    FORMAT_THREAD,
-    FORMAT_RAW,
-    FORMAT_TIME,
-    FORMAT_LONG
-} LogFormat;
-
-
-/*
- * Log driver state.
- */
-typedef struct LogState {
-    /* nonzero if this is a binary log */
-    int     isBinary;
-
-    /* global minimum priority */
-    int     globalMinPriority;
-
-    /* output format */
-    LogFormat outputFormat;
-
-    /* tags and priorities */
-    struct {
-        char    tag[kMaxTagLen];
-        int     minPriority;
-    } tagSet[kTagSetSize];
-} LogState;
-
-
-/*
- * Configure logging based on ANDROID_LOG_TAGS environment variable.  We
- * need to parse a string that looks like
- *
- *  '*:v jdwp:d dalvikvm:d dalvikvm-gc:i dalvikvmi:i
- *
- * The tag (or '*' for the global level) comes first, followed by a colon
- * and a letter indicating the minimum priority level we're expected to log.
- * This can be used to reveal or conceal logs with specific tags.
- *
- * We also want to check ANDROID_PRINTF_LOG to determine how the output
- * will look.
- */
-static void configureInitialState(const char* pathName, LogState* logState)
-{
-    static const int kDevLogLen = 9;    /* strlen("/dev/log/") */
-
-    /* identify binary logs */
-    if (strcmp(pathName + kDevLogLen, "events") == 0) {
-        logState->isBinary = 1;
-    }
-
-    /* global min priority defaults to "info" level */
-    logState->globalMinPriority = ANDROID_LOG_INFO;
-
-    /*
-     * This is based on the utils/Log.cpp code.
-     */
-    const char* tags = getenv("ANDROID_LOG_TAGS");
-    wsLog("Found ANDROID_LOG_TAGS='%s'\n", tags);
-    if (tags != NULL) {
-        int entry = 0;
-
-        while (*tags != '\0') {
-            char tagName[kMaxTagLen];
-            int i, minPrio;
-
-            while (isspace(*tags))
-                tags++;
-
-            i = 0;
-            while (*tags != '\0' && !isspace(*tags) && *tags != ':' &&
-                i < kMaxTagLen)
-            {
-                tagName[i++] = *tags++;
-            }
-            if (i == kMaxTagLen) {
-                wsLog("ERROR: env tag too long (%d chars max)\n", kMaxTagLen-1);
-                return;
-            }
-            tagName[i] = '\0';
-
-            /* default priority, if there's no ":" part; also zero out '*' */
-            minPrio = ANDROID_LOG_VERBOSE;
-            if (tagName[0] == '*' && tagName[1] == '\0') {
-                minPrio = ANDROID_LOG_DEBUG;
-                tagName[0] = '\0';
-            }
-
-            if (*tags == ':') {
-                tags++;
-                if (*tags >= '0' && *tags <= '9') {
-                    if (*tags >= ('0' + ANDROID_LOG_SILENT))
-                        minPrio = ANDROID_LOG_VERBOSE;
-                    else
-                        minPrio = *tags - '\0';
-                } else {
-                    switch (*tags) {
-                    case 'v':   minPrio = ANDROID_LOG_VERBOSE;  break;
-                    case 'd':   minPrio = ANDROID_LOG_DEBUG;    break;
-                    case 'i':   minPrio = ANDROID_LOG_INFO;     break;
-                    case 'w':   minPrio = ANDROID_LOG_WARN;     break;
-                    case 'e':   minPrio = ANDROID_LOG_ERROR;    break;
-                    case 'f':   minPrio = ANDROID_LOG_FATAL;    break;
-                    case 's':   minPrio = ANDROID_LOG_SILENT;   break;
-                    default:    minPrio = ANDROID_LOG_DEFAULT;  break;
-                    }
-                }
-
-                tags++;
-                if (*tags != '\0' && !isspace(*tags)) {
-                    wsLog("ERROR: garbage in tag env; expected whitespace\n");
-                    wsLog("       env='%s'\n", tags);
-                    return;
-                }
-            }
-
-            if (tagName[0] == 0) {
-                logState->globalMinPriority = minPrio;
-                wsLog("+++ global min prio %d\n", logState->globalMinPriority);
-            } else {
-                logState->tagSet[entry].minPriority = minPrio;
-                strcpy(logState->tagSet[entry].tag, tagName);
-                wsLog("+++ entry %d: %s:%d\n",
-                    entry,
-                    logState->tagSet[entry].tag,
-                    logState->tagSet[entry].minPriority);
-                entry++;
-            }
-        }
-    }
-
-
-    /*
-     * Taken from utils/Log.cpp
-     */
-    const char* fstr = getenv("ANDROID_PRINTF_LOG");
-    LogFormat format;
-    if (fstr == NULL) {
-        format = FORMAT_BRIEF;
-    } else {
-        if (strcmp(fstr, "brief") == 0)
-            format = FORMAT_BRIEF;
-        else if (strcmp(fstr, "process") == 0)
-            format = FORMAT_PROCESS;
-        else if (strcmp(fstr, "tag") == 0)
-            format = FORMAT_PROCESS;
-        else if (strcmp(fstr, "thread") == 0)
-            format = FORMAT_PROCESS;
-        else if (strcmp(fstr, "raw") == 0)
-            format = FORMAT_PROCESS;
-        else if (strcmp(fstr, "time") == 0)
-            format = FORMAT_PROCESS;
-        else if (strcmp(fstr, "long") == 0)
-            format = FORMAT_PROCESS;
-        else
-            format = (LogFormat) atoi(fstr);        // really?!
-    }
-
-    logState->outputFormat = format;
-}
-
-/*
- * Free up the state structure.
- */
-static void freeState(LogState* logState)
-{
-    free(logState);
-}
-
-/*
- * Return a human-readable string for the priority level.  Always returns
- * a valid string.
- */
-static const char* getPriorityString(int priority)
-{
-    /* the first character of each string should be unique */
-    static const char* priorityStrings[] = {
-        "Verbose", "Debug", "Info", "Warn", "Error", "Assert"
-    };
-    int idx;
-
-    idx = (int) priority - (int) ANDROID_LOG_VERBOSE;
-    if (idx < 0 ||
-        idx >= (int) (sizeof(priorityStrings) / sizeof(priorityStrings[0])))
-        return "?unknown?";
-    return priorityStrings[idx];
-}
-
-/*
- * Show a log message.  We write it to stderr and send a copy to the
- * simulator front-end for the log window.
- *
- * Taken from utils/Log.cpp.
- */
-static void showLog(FakeDev* dev, int logPrio, const char* tag, const char* msg)
-{
-    LogState* state = (LogState*) dev->state;
-
-#if defined(HAVE_LOCALTIME_R)
-    struct tm tmBuf;
-#endif
-    struct tm* ptm;
-    char timeBuf[32];
-    char prefixBuf[128], suffixBuf[128];
-    char priChar;
-    time_t when;
-    pid_t pid, tid;
-
-    //wsLog("LOG %d: %s %s", logPrio, tag, msg);
-    wsPostLogMessage(logPrio, tag, msg);
-
-    priChar = getPriorityString(logPrio)[0];
-    when = time(NULL);
-    pid = tid = getpid();       // find gettid()?
-
-    /*
-     * Get the current date/time in pretty form
-     *
-     * It's often useful when examining a log with "less" to jump to
-     * a specific point in the file by searching for the date/time stamp.
-     * For this reason it's very annoying to have regexp meta characters
-     * in the time stamp.  Don't use forward slashes, parenthesis,
-     * brackets, asterisks, or other special chars here.
-     */
-#if defined(HAVE_LOCALTIME_R)
-    ptm = localtime_r(&when, &tmBuf);
-#else
-    ptm = localtime(&when);
-#endif
-    //strftime(timeBuf, sizeof(timeBuf), "%Y-%m-%d %H:%M:%S", ptm);
-    strftime(timeBuf, sizeof(timeBuf), "%m-%d %H:%M:%S", ptm);
-
-    /*
-     * Construct a buffer containing the log header and log message.
-     */
-    size_t prefixLen, suffixLen;
-
-    switch (state->outputFormat) {
-    case FORMAT_TAG:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "%c/%-8s: ", priChar, tag);
-        strcpy(suffixBuf, "\n"); suffixLen = 1;
-        break;
-    case FORMAT_PROCESS:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "%c(%5d) ", priChar, pid);
-        suffixLen = snprintf(suffixBuf, sizeof(suffixBuf),
-            "  (%s)\n", tag);
-        break;
-    case FORMAT_THREAD:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "%c(%5d:%p) ", priChar, pid, (void*)tid);
-        strcpy(suffixBuf, "\n"); suffixLen = 1;
-        break;
-    case FORMAT_RAW:
-        prefixBuf[0] = 0; prefixLen = 0;
-        strcpy(suffixBuf, "\n"); suffixLen = 1;
-        break;
-    case FORMAT_TIME:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "%s %-8s\n\t", timeBuf, tag);
-        strcpy(suffixBuf, "\n"); suffixLen = 1;
-        break;
-    case FORMAT_LONG:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "[ %s %5d:%p %c/%-8s ]\n",
-            timeBuf, pid, (void*)tid, priChar, tag);
-        strcpy(suffixBuf, "\n\n"); suffixLen = 2;
-        break;
-    default:
-        prefixLen = snprintf(prefixBuf, sizeof(prefixBuf),
-            "%c/%-8s(%5d): ", priChar, tag, pid);
-        strcpy(suffixBuf, "\n"); suffixLen = 1;
-        break;
-     }
-
-    /*
-     * Figure out how many lines there will be.
-     */
-    const char* end = msg + strlen(msg);
-    size_t numLines = 0;
-    const char* p = msg;
-    while (p < end) {
-        if (*p++ == '\n') numLines++;
-    }
-    if (p > msg && *(p-1) != '\n') numLines++;
-    
-    /*
-     * Create an array of iovecs large enough to write all of
-     * the lines with a prefix and a suffix.
-     */
-    const size_t INLINE_VECS = 6;
-    struct iovec stackVec[INLINE_VECS];
-    struct iovec* vec = stackVec;
-    
-    numLines *= 3;  // 3 iovecs per line.
-    if (numLines > INLINE_VECS) {
-        vec = (struct iovec*)malloc(sizeof(struct iovec)*numLines);
-        if (vec == NULL) {
-            msg = "LOG: write failed, no memory";
-            numLines = 3;
-        }
-    }
-    
-    /*
-     * Fill in the iovec pointers.
-     */
-    p = msg;
-    struct iovec* v = vec;
-    int totalLen = 0;
-    while (p < end) {
-        if (prefixLen > 0) {
-            v->iov_base = prefixBuf;
-            v->iov_len = prefixLen;
-            totalLen += prefixLen;
-            v++;
-        }
-        const char* start = p;
-        while (p < end && *p != '\n') p++;
-        if ((p-start) > 0) {
-            v->iov_base = (void*)start;
-            v->iov_len = p-start;
-            totalLen += p-start;
-            v++;
-        }
-        if (*p == '\n') p++;
-        if (suffixLen > 0) {
-            v->iov_base = suffixBuf;
-            v->iov_len = suffixLen;
-            totalLen += suffixLen;
-            v++;
-        }
-    }
-    
-    /*
-     * Write the entire message to the log file with a single writev() call.
-     * We need to use this rather than a collection of printf()s on a FILE*
-     * because of multi-threading and multi-process issues.
-     *
-     * If the file was not opened with O_APPEND, this will produce interleaved
-     * output when called on the same file from multiple processes.
-     *
-     * If the file descriptor is actually a network socket, the writev()
-     * call may return with a partial write.  Putting the writev() call in
-     * a loop can result in interleaved data.  This can be alleviated
-     * somewhat by wrapping the writev call in the Mutex.
-     */
-
-    for(;;) {
-        int cc;
-
-        cc = writev(fileno(stderr), vec, v-vec);
-        if (cc == totalLen) break;
-        
-        if (cc < 0) {
-            if(errno == EINTR) continue;
-            
-                /* can't really log the failure; for now, throw out a stderr */
-            fprintf(stderr, "+++ LOG: write failed (errno=%d)\n", errno);
-            break;
-        } else {
-                /* shouldn't happen when writing to file or tty */
-            fprintf(stderr, "+++ LOG: write partial (%d of %d)\n", cc, totalLen);
-            break;
-        }
-    }
-
-    /* if we allocated storage for the iovecs, free it */
-    if (vec != stackVec)
-        free(vec);
-}
-
-
-/*
- * Receive a log message.  We happen to know that "vector" has three parts:
- *
- *  priority (1 byte)
- *  tag (N bytes -- null-terminated ASCII string)
- *  message (N bytes -- null-terminated ASCII string)
- */
-static ssize_t writevLog(FakeDev* dev, int fd, const struct iovec* vector,
-    int count)
-{
-    LogState* state = (LogState*) dev->state;
-    int ret = 0;
-
-    if (state->isBinary) {
-        wsLog("%s: ignoring binary log\n", dev->debugName);
-        goto bail;
-    }
-
-    if (count != 3) {
-        wsLog("%s: writevLog with count=%d not expected\n",
-            dev->debugName, count);
-        errno = EINVAL;
-        return -1;
-    }
-
-    /* pull out the three fields */
-    int logPrio = *(const char*)vector[0].iov_base;
-    const char* tag = (const char*) vector[1].iov_base;
-    const char* msg = (const char*) vector[2].iov_base;
-
-    /* see if this log tag is configured */
-    int i;
-    int minPrio = state->globalMinPriority;
-    for (i = 0; i < kTagSetSize; i++) {
-        if (state->tagSet[i].minPriority == ANDROID_LOG_UNKNOWN)
-            break;      /* reached end of configured values */
-
-        if (strcmp(state->tagSet[i].tag, tag) == 0) {
-            //wsLog("MATCH tag '%s'\n", tag);
-            minPrio = state->tagSet[i].minPriority;
-            break;
-        }
-    }
-
-    if (logPrio >= minPrio) {
-        showLog(dev, logPrio, tag, msg);
-    } else {
-        //wsLog("+++ NOLOG(%d): %s %s", logPrio, tag, msg);
-    }
-
-bail:
-    for (i = 0; i < count; i++)
-        ret += vector[i].iov_len;
-    return ret;
-}
-
-/*
- * Free up our state before closing down the fake descriptor.
- */
-static int closeLog(FakeDev* dev, int fd)
-{
-    freeState((LogState*)dev->state);
-    dev->state = NULL;
-    return 0;
-}
-
-/*
- * Open a log output device.
- */
-FakeDev* wsOpenDevLog(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->writev = writevLog;
-        newDev->close = closeLog;
-
-        LogState* logState = calloc(1, sizeof(LogState));
-
-        configureInitialState(pathName, logState);
-        newDev->state = logState;
-    }
-
-    return newDev;
-}
-
diff --git a/simulator/wrapsim/DevPower.c b/simulator/wrapsim/DevPower.c
deleted file mode 100644
index b44231b..0000000
--- a/simulator/wrapsim/DevPower.c
+++ /dev/null
@@ -1,175 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Magic entries in /sys/class/power_supply/.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-
-#include <fcntl.h>
-#include <sys/ioctl.h>
-
-/*
- * Map filename to device index.
- *
- * [ not using DeviceIndex -- would be useful if we need to return something
- * other than a static string ]
- */
-static const struct {
-    const char*     name;
-    //DeviceIndex     idx;
-    const char*     data;
-} gDeviceMap[] = {
-    { "ac/online",
-        "0\n" },
-
-    { "battery/batt_temp",
-        "281\n", },
-    { "battery/batt_vol",
-        "4170\n" },
-    { "battery/capacity",
-        "100\n" },
-    { "battery/health",
-        "Good\n" },
-    { "battery/present",
-        "0\n" },
-    { "battery/status",
-        "Full" },
-    { "battery/technology",
-        "Li-ion\n" },
-
-    { "usb/online",
-        "1\n" },
-};
-
-/*
- * Power driver state.
- *
- * Right now we just ignore everything written.
- */
-typedef struct PowerState {
-    int         which;
-} PowerState;
-
-
-/*
- * Figure out who we are, based on "pathName".
- */
-static void configureInitialState(const char* pathName, PowerState* powerState)
-{
-    const char* cp = pathName + strlen("/sys/class/power_supply/");
-    int i;
-
-    powerState->which = -1;
-    for (i = 0; i < (int) (sizeof(gDeviceMap) / sizeof(gDeviceMap[0])); i++) {
-        if (strcmp(cp, gDeviceMap[i].name) == 0) {
-            powerState->which = i;
-            break;
-        }
-    }
-
-    if (powerState->which == -1) {
-        wsLog("Warning: access to unknown power device '%s'\n", pathName);
-        return;
-    }
-}
-
-/*
- * Free up the state structure.
- */
-static void freeState(PowerState* powerState)
-{
-    free(powerState);
-}
-
-/*
- * Read data from the device.
- *
- * We don't try to keep track of how much was read -- existing clients just
- * try to read into a large buffer.
- */
-static ssize_t readPower(FakeDev* dev, int fd, void* buf, size_t count)
-{
-    PowerState* state = (PowerState*) dev->state;
-    int dataLen;
-
-    wsLog("%s: read %d\n", dev->debugName, count);
-
-    if (state->which < 0 ||
-        state->which >= (int) (sizeof(gDeviceMap)/sizeof(gDeviceMap[0])))
-    {
-        return 0;
-    }
-
-    const char* data = gDeviceMap[state->which].data;
-    size_t strLen = strlen(data);
-
-    while(strLen == 0)
-        sleep(10); // block forever
-
-    ssize_t copyCount = (strLen < count) ? strLen : count;
-    memcpy(buf, data, copyCount);
-    return copyCount;
-}
-
-/*
- * Ignore the request.
- */
-static ssize_t writePower(FakeDev* dev, int fd, const void* buf, size_t count)
-{
-    wsLog("%s: write %d bytes\n", dev->debugName, count);
-    return count;
-}
-
-/*
- * Our Java classes want to be able to do ioctl(FIONREAD) on files.  The
- * battery power manager is blowing up if we get an error other than
- * ENOTTY (meaning a device that doesn't understand buffering).
- */
-static int ioctlPower(FakeDev* dev, int fd, int request, void* argp)
-{
-    if (request == FIONREAD) {
-        wsLog("%s: ioctl(FIONREAD, %p)\n", dev->debugName, argp);
-        errno = ENOTTY;
-        return -1;
-    } else {
-        wsLog("%s: ioctl(0x%08x, %p) ??\n", dev->debugName, request, argp);
-        errno = EINVAL;
-        return -1;
-    }
-}
-
-/*
- * Free up our state before closing down the fake descriptor.
- */
-static int closePower(FakeDev* dev, int fd)
-{
-    freeState((PowerState*)dev->state);
-    dev->state = NULL;
-    return 0;
-}
-
-/*
- * Open a power device.
- */
-FakeDev* wsOpenDevPower(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->read = readPower;
-        newDev->write = writePower;
-        newDev->ioctl = ioctlPower;
-        newDev->close = closePower;
-
-        PowerState* powerState = calloc(1, sizeof(PowerState));
-
-        configureInitialState(pathName, powerState);
-        newDev->state = powerState;
-    }
-
-    return newDev;
-}
-
diff --git a/simulator/wrapsim/DevVibrator.c b/simulator/wrapsim/DevVibrator.c
deleted file mode 100644
index b736f75..0000000
--- a/simulator/wrapsim/DevVibrator.c
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Vibrating notification device.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-
-#include <unistd.h>
-
-
-/*
- * The user will write a decimal integer indicating the time, in milliseconds,
- * that the device should vibrate.  In current usage, this is either -1
- * (meaning vibrate forever) or 0 (don't vibrate).
- */
-static ssize_t writeVibrator(FakeDev* dev, int fd, const void* buf,
-    size_t count)
-{
-    if (count == 2 && memcmp(buf, "0\n", 2) == 0) {
-        wsEnableVibration(0);
-    } else if (count == 3 && memcmp(buf, "-1\n", 3) == 0) {
-        wsEnableVibration(1);
-    } else {
-        wsLog("%s: got %d bytes: '%*s'\n",
-            dev->debugName, count, count, (const char*) buf);
-    }
-
-    return count;
-}
-
-/*
- * Open the vibration control device.
- */
-FakeDev* wsOpenDevVibrator(const char* pathName, int flags)
-{
-    FakeDev* newDev = wsCreateFakeDev(pathName);
-    if (newDev != NULL) {
-        newDev->write = writeVibrator;
-    }
-
-    return newDev;
-}
-
diff --git a/simulator/wrapsim/FakeDev.c b/simulator/wrapsim/FakeDev.c
deleted file mode 100644
index 3e223d3..0000000
--- a/simulator/wrapsim/FakeDev.c
+++ /dev/null
@@ -1,311 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Fake device support.
- */
-/*
-Implementation notes:
-
-There are a couple of basic scenarios, exemplified by the "fb" and
-"events" devices.  The framebuffer driver is pretty simple, handling a
-few ioctl()s and managing a stretch of memory.  We can just intercept a
-few calls.  The input event driver can be used in a select() or poll()
-call with other file descriptors, which either requires us to do some
-fancy tricks with select() and poll(), or requires that we return a real
-file descriptor (perhaps based on a socketpair).
-
-We have three basic approaches to dealing with "fake" file descriptors:
-
-(1) Always use real fds.  We can dup() an open /dev/null to get a number
-    for the cases where we don't need a socketpair.
-(2) Always use fake fds with absurdly high numeric values.  Testing to see
-    if the fd is one we handle is trivial (range check).  This doesn't
-    work for select(), which uses fd bitmaps accessed through macros.
-(3) Use a mix of real and fake fds, in a high range (512-1023).  Because
-    it's in the "real" range, we can pass real fds around for things that
-    are handed to poll() and select(), but because of the high numeric
-    value we *should* be able to get away with a trivial range check.
-
-Approach (1) is the most portable and least likely to break, but the
-efficiencies gained in approach (2) make it more desirable.  There is
-a small risk of application fds wandering into our range, but we can
-minimize that by asserting on a "guard zone" and/or obstructing dup2().
-(We can also dup2(/dev/null) to "reserve" our fds, but that wastes
-resources.)
-*/
-
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <assert.h>
-#include <fnmatch.h>
-
-/*
- * Devices we intercept.
- *
- * Needed:
- *  /dev/alarm
- *  radio
- */
-typedef FakeDev* (*wsFileHook)(const char *path, int flags);
-
-typedef struct FakedPath {
-    const char *pathexpr;
-    wsFileHook hook;
-} FakedPath;
-
-FakedPath fakedpaths[] =
-{
-    { "/dev/graphics/fb0",      wsOpenDevFb },
-    { "/dev/hw3d",              NULL },
-    { "/dev/eac",               wsOpenDevAudio },
-    { "/dev/tty0",              wsOpenDevConsoleTty },
-    { "/dev/input/event0",      wsOpenDevEvent },
-    { "/dev/input/*",           NULL },
-    { "/dev/log/*",             wsOpenDevLog },
-    { "/sys/class/power_supply/*", wsOpenDevPower },
-    { "/sys/devices/platform/android-vibrator/enable",  wsOpenDevVibrator },
-    { "/sys/qemu_trace/*",      NULL },
-    { NULL,                     NULL }
-};
-
-
-/*
- * Generic drop-in for an unimplemented call.
- *
- * Returns -1, which conveniently is the same as MAP_FAILED for mmap.
- */
-static int notImplemented(FakeDev* dev, const char* callName)
-{
-    wsLog("WARNING: unimplemented %s() on '%s' %p\n",
-        callName, dev->debugName, dev->state);
-    errno = kNoHandlerError;
-    return -1;
-}
-
-/*
- * Default implementations.  We want to log as much information as we can
- * so that we can fill in the missing implementation.
- *
- * TODO: for some or all of these we will want to display the full arg list.
- */
-static int noClose(FakeDev* dev, ...)
-{
-    return 0;
-}
-static int noRead(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "read");
-}
-static int noReadv(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "readv");
-}
-static int noWrite(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "write");
-}
-static int noWritev(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "writev");
-}
-static int noMmap(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "mmap");
-}
-static int noIoctl(FakeDev* dev, ...)
-{
-    return notImplemented(dev, "ioctl");
-}
-
-
-/*
- * Create a new FakeDev entry.
- *
- * We mark the fd slot as "used" in the bitmap, but don't add it to the
- * table yet since the entry is not fully prepared.
- */
-FakeDev* wsCreateFakeDev(const char* debugName)
-{
-    FakeDev* newDev;
-    int cc;
-
-    assert(debugName != NULL);
-
-    newDev = (FakeDev*) calloc(1, sizeof(FakeDev));
-    if (newDev == NULL)
-        return NULL;
-
-    newDev->debugName = strdup(debugName);
-    newDev->state = NULL;
-
-    newDev->close = (Fake_close) noClose;
-    newDev->read = (Fake_read) noRead;
-    newDev->readv = (Fake_readv) noReadv;
-    newDev->write = (Fake_write) noWrite;
-    newDev->writev = (Fake_writev) noWritev;
-    newDev->mmap = (Fake_mmap) noMmap;
-    newDev->ioctl = (Fake_ioctl) noIoctl;
-
-    /*
-     * Allocate a new entry.  The bit vector map is really only used as a
-     * performance boost in the current implementation.
-     */
-    cc = pthread_mutex_lock(&gWrapSim.fakeFdLock); assert(cc == 0);
-    int newfd = wsAllocBit(gWrapSim.fakeFdMap);
-    cc = pthread_mutex_unlock(&gWrapSim.fakeFdLock); assert(cc == 0);
-
-    if (newfd < 0) {
-        wsLog("WARNING: ran out of 'fake' file descriptors\n");
-        free(newDev);
-        return NULL;
-    }
-    newDev->fd = newfd + kFakeFdBase;
-    newDev->otherFd = -1;
-    assert(gWrapSim.fakeFdList[newDev->fd - kFakeFdBase] == NULL);
-
-    return newDev;
-}
-
-/*
- * Create a new FakeDev entry, and open a file descriptor that actually
- * works.
- */
-FakeDev* wsCreateRealFakeDev(const char* debugName)
-{
-    FakeDev* newDev = wsCreateFakeDev(debugName);
-    if (newDev == NULL)
-        return newDev;
-    
-    int fds[2];
-
-    if (socketpair(AF_UNIX, SOCK_STREAM, 0, fds) < 0) {
-        wsLog("socketpair() failed: %s\n", strerror(errno));
-        wsFreeFakeDev(newDev);
-        return NULL;
-    }
-
-    if (dup2(fds[0], newDev->fd) < 0) {
-        wsLog("dup2(%d,%d) failed: %s\n",
-            fds[0], newDev->fd, strerror(errno));
-        wsFreeFakeDev(newDev);
-        return NULL;
-    }
-    close(fds[0]);
-
-    /* okay to leave this one in the "normal" range; not visible to app */
-    newDev->otherFd = fds[1];
-
-    return newDev;
-}
-
-/*
- * Free fake device entry.
- */
-void wsFreeFakeDev(FakeDev* dev)
-{
-    if (dev == NULL)
-        return;
-
-    wsLog("## closing/freeing '%s' (%d/%d)\n",
-        dev->debugName, dev->fd, dev->otherFd);
-
-    /*
-     * If we assigned a file descriptor slot, free it up.
-     */
-    if (dev->fd >= 0) {
-        int cc;
-
-        gWrapSim.fakeFdList[dev->fd - kFakeFdBase] = NULL;
-
-        cc = pthread_mutex_lock(&gWrapSim.fakeFdLock); assert(cc == 0);
-        wsFreeBit(gWrapSim.fakeFdMap, dev->fd - kFakeFdBase);
-        cc = pthread_mutex_unlock(&gWrapSim.fakeFdLock); assert(cc == 0);
-    }
-    if (dev->otherFd >= 0)
-        close(dev->otherFd);
-
-    if (dev->debugName) free(dev->debugName);
-    free(dev);
-}
-
-/*
- * Map a file descriptor to a fake device.
- *
- * Returns NULL if there's no corresponding entry.
- */
-FakeDev* wsFakeDevFromFd(int fd)
-{
-    /* quick range test */
-    if (fd < kFakeFdBase || fd >= kFakeFdBase + kMaxFakeFdCount)
-        return NULL;
-
-    return gWrapSim.fakeFdList[fd - kFakeFdBase];
-}
-
-
-/*
- * Check to see if we're opening a device that we want to fake out.
- *
- * We return a file descriptor >= 0 on success, -1 if we're not interested,
- * or -2 if we explicitly want to pretend that the device doesn't exist.
- */
-int wsInterceptDeviceOpen(const char* pathName, int flags)
-{
-    FakedPath* p = fakedpaths;
-
-    while (p->pathexpr) {
-        if (fnmatch(p->pathexpr, pathName, 0) == 0) {
-            if (p->hook != NULL) {
-                FakeDev* dev = p->hook(pathName, flags);
-                if (dev != NULL) {
-                    /*
-                     * Now that the device entry is ready, add it to the list.
-                     */
-                    wsLog("## created fake dev %d: '%s' %p\n",
-                        dev->fd, dev->debugName, dev->state);
-                    gWrapSim.fakeFdList[dev->fd - kFakeFdBase] = dev;
-                    return dev->fd;
-                }
-            } else {
-                wsLog("## rejecting attempt to open %s\n", pathName);
-                errno = ENOENT;
-                return -2;
-            }
-            break;
-        }
-        p++;
-    }
-    return -1;
-}
-
-/*
- * Check to see if we're accessing a device that we want to fake out.
- * Returns 0 if the device can be (fake) opened with the given mode,
- * -1 if it can't, -2 if it can't and we don't want to allow fallback
- * to the host-device either.
- * TODO: actually check the mode.
- */
-int wsInterceptDeviceAccess(const char *pathName, int mode)
-{
-    FakedPath *p = fakedpaths;
-
-    while (p->pathexpr) {
-        if (fnmatch(p->pathexpr, pathName, 0) == 0) {
-            if (p->hook) {
-                return 0;
-            } else {
-                wsLog("## rejecting attempt to open %s\n", pathName);
-                errno = ENOENT;
-                return -2;
-            }
-            break;
-        }
-        p++;
-    }
-    errno = ENOENT;
-    return -1;
-}
diff --git a/simulator/wrapsim/FakeDev.h b/simulator/wrapsim/FakeDev.h
deleted file mode 100644
index eacbbf5..0000000
--- a/simulator/wrapsim/FakeDev.h
+++ /dev/null
@@ -1,123 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Fake device support.
- */
-#ifndef _WRAPSIM_FAKEDEV_H
-#define _WRAPSIM_FAKEDEV_H
-
-#include <sys/types.h>
-#include <sys/uio.h>
-#include <errno.h>
-
-typedef struct FakeDev FakeDev;
-
-typedef int     (*Fake_close)(FakeDev* dev, int);
-typedef ssize_t (*Fake_read)(FakeDev* dev, int, void*, size_t);
-typedef ssize_t (*Fake_readv)(FakeDev* dev, int, const struct iovec*, int);
-typedef ssize_t (*Fake_write)(FakeDev* dev, int, const void*, size_t);
-typedef ssize_t (*Fake_writev)(FakeDev* dev, int, const struct iovec*, int);
-typedef void*   (*Fake_mmap)(FakeDev* dev, void*, size_t, int, int, int, __off_t);
-typedef int     (*Fake_ioctl)(FakeDev* dev, int, int, void*);
-
-/*
- * An open fake device entry.
- */
-struct FakeDev {
-    /* string, for debugging; usually orig. device name */
-    char*   debugName;
-
-    /* state bucket */
-    void*   state;
-
-    /* the file descriptor we're associated with */
-    int     fd;
-
-    /* in some cases we use a pair; this is the other one */
-    int     otherFd;
-
-    /*
-     * Device functions we provide.
-     *
-     * All other file descriptor operations should fail, usually with EBADF.
-     */
-    Fake_close  close;
-    Fake_read   read;
-    Fake_readv  readv;
-    Fake_write  write;
-    Fake_writev writev;
-    Fake_mmap   mmap;       // handles both mmap() and mmap64()
-    Fake_ioctl  ioctl;
-};
-
-/*
- * If a handler isn't defined for a syscall, we return EMLINK so that it's
- * obvious when the error is generated by us.
- */ 
-#define kNoHandlerError EMLINK
-
-/*
- * Fake file descriptors begin here.  This should be chosen such that no
- * real descriptor is ever at or above this value.
- */
-#define kFakeFdBase     512
-#define kMaxFakeFdCount 256
-
-/*
- * Create a new, completely fake device entry.
- */
-FakeDev* wsCreateFakeDev(const char* debugName);
-
-/*
- * Create a new, mostly fake device entry.
- */
-FakeDev* wsCreateRealFakeDev(const char* debugName);
-
-/*
- * Free a fake device entry.
- */
-void wsFreeFakeDev(FakeDev* dev);
-
-/*
- * Given a file descriptor, find the corresponding fake device.  Returns
- * NULL if the fd doesn't correspond to one of our entries.
- */
-FakeDev* wsFakeDevFromFd(int fd);
-
-/*
- * Check to see if this open() call is on a device we want to spoof.
- *
- * Returns a "fake" file descriptor on success, <0 on error.
- */
-int wsInterceptDeviceOpen(const char* pathName, int flags);
-
-/*
- * Check to see if this access() call is on a device we want to spoof.
- *
- * Returns 0 if the device can be fake-accessed, -1 if it can't, -2
- * if it can't and we don't want to allow fallback to the host-device.
- */
-int wsInterceptDeviceAccess(const char* pathName, int flags);
-
-/*
- * Devices.
- */
-FakeDev* wsOpenDevAudio(const char* pathName, int flags);
-FakeDev* wsOpenDevConsoleTty(const char* pathName, int flags);
-FakeDev* wsOpenDevEvent(const char* pathName, int flags);
-FakeDev* wsOpenDevFb(const char* pathName, int flags);
-FakeDev* wsOpenDevLog(const char* pathName, int flags);
-FakeDev* wsOpenDevPower(const char* pathName, int flags);
-FakeDev* wsOpenDevVibrator(const char* pathName, int flags);
-
-/*
- * Performs key remapping and sends the event to the global input event device.
- */
-void wsSendSimKeyEvent(int key, int isDown);
-
-/*
- * Send a touch event to the global input event device.
- */
-void wsSendSimTouchEvent(int action, int x, int y);
-
-#endif /*_WRAPSIM_FAKEDEV_H*/
diff --git a/simulator/wrapsim/Globals.h b/simulator/wrapsim/Globals.h
deleted file mode 100644
index 75c98d8..0000000
--- a/simulator/wrapsim/Globals.h
+++ /dev/null
@@ -1,208 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Sim wrapper global state.
- */
-#ifndef _WRAPSIM_GLOBALS_H
-#define _WRAPSIM_GLOBALS_H
-
-#include <stdio.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/uio.h>
-#include <sys/time.h>
-#include <sys/vfs.h>
-#include <utime.h>
-#include <fcntl.h>
-#include <dirent.h>
-#include <pthread.h>
-
-/*
- * Type declarations for the functions we're replacing.
- *
- * For syscalls this matches the syscall definition, not the libc definition,
- * e.g. no varargs for open() or ioctl().
- */
-typedef int     (*Func_access)(const char*, int);
-typedef int     (*Func_open)(const char*, int, mode_t);
-typedef int     (*Func_open64)(const char*, int, mode_t);
-
-typedef int     (*Func_close)(int);
-typedef ssize_t (*Func_read)(int, void*, size_t);
-typedef ssize_t (*Func_readv)(int, const struct iovec*, int);
-typedef ssize_t (*Func_write)(int, const void*, size_t);
-typedef ssize_t (*Func_writev)(int, const struct iovec*, int);
-typedef void*   (*Func_mmap)(void*, size_t, int, int, int, __off_t);
-typedef void*   (*Func_mmap64)(void*, size_t, int, int, int, __off64_t);
-typedef int     (*Func_ioctl)(int, int, void*);
-
-typedef int     (*Func_chdir)(const char*);
-typedef int     (*Func_chmod)(const char*, mode_t);
-typedef int     (*Func_chown)(const char*, uid_t, uid_t);
-typedef int     (*Func_creat)(const char*, mode_t);
-typedef int     (*Func_execve)(const char*, char* const[], char* const[]);
-typedef char*   (*Func_getcwd)(char* buf, size_t size);
-typedef int     (*Func_lchown)(const char*, uid_t, uid_t);
-typedef int     (*Func_link)(const char*, const char*);
-typedef int     (*Func_lstat)(const char*, struct stat*);
-typedef int     (*Func_lstat64)(const char*, struct stat*);
-typedef int     (*Func___lxstat)(int version, const char*, struct stat*);
-typedef int     (*Func___lxstat64)(int version, const char*, struct stat*);
-typedef int     (*Func_mkdir)(const char*, mode_t mode);
-typedef ssize_t (*Func_readlink)(const char*, char*, size_t);
-typedef int     (*Func_rename)(const char*, const char*);
-typedef int     (*Func_rmdir)(const char*);
-typedef int     (*Func_stat)(const char*, struct stat*);
-typedef int     (*Func_stat64)(const char*, struct stat*);
-typedef int     (*Func___xstat)(int version, const char*, struct stat*);
-typedef int     (*Func___xstat64)(int version, const char*, struct stat*);
-typedef int     (*Func_statfs)(const char*, struct statfs*);
-typedef int     (*Func_statfs64)(const char*, struct statfs*);
-typedef int     (*Func_symlink)(const char*, const char*);
-typedef int     (*Func_unlink)(const char*);
-typedef int     (*Func_utime)(const char*, const struct utimbuf*);
-typedef int     (*Func_utimes)(const char*, const struct timeval []);
-
-typedef int     (*Func_execl)(const char*, const char*, ...);
-typedef int     (*Func_execle)(const char*, const char*, ...);
-typedef int     (*Func_execlp)(const char*, const char*, ...);
-typedef int     (*Func_execv)(const char*, char* const []);
-typedef int     (*Func_execvp)(const char*, char* const []);
-typedef FILE*   (*Func_fopen)(const char*, const char*);
-typedef FILE*   (*Func_fopen64)(const char*, const char*);
-typedef FILE*   (*Func_freopen)(const char*, const char*, FILE*);
-typedef int     (*Func_ftw)(const char*,
-                    int (*fn) (const char*, const struct stat*, int),
-                    int);
-typedef DIR*    (*Func_opendir)(const char* path);
-typedef void*   (*Func_dlopen)(const char*, int);
-
-typedef int     (*Func_setpriority)(int, int, int);
-//typedef int     (*Func_pipe)(int [2]);
-
-
-/*
- * Pointers to the actual implementations.
- */
-#ifndef CREATE_FUNC_STORAGE
-# define EXTERN_FUNC extern
-#else
-# define EXTERN_FUNC
-#endif
-EXTERN_FUNC Func_access _ws_access;
-EXTERN_FUNC Func_open _ws_open;
-EXTERN_FUNC Func_open64 _ws_open64;
-
-EXTERN_FUNC Func_close _ws_close;
-EXTERN_FUNC Func_read _ws_read;
-EXTERN_FUNC Func_readv _ws_readv;
-EXTERN_FUNC Func_write _ws_write;
-EXTERN_FUNC Func_writev _ws_writev;
-EXTERN_FUNC Func_mmap _ws_mmap;
-EXTERN_FUNC Func_mmap64 _ws_mmap64;
-EXTERN_FUNC Func_ioctl _ws_ioctl;
-
-EXTERN_FUNC Func_chdir _ws_chdir;
-EXTERN_FUNC Func_chmod _ws_chmod;
-EXTERN_FUNC Func_chown _ws_chown;
-EXTERN_FUNC Func_creat _ws_creat;
-EXTERN_FUNC Func_execve _ws_execve;
-EXTERN_FUNC Func_getcwd _ws_getcwd;
-EXTERN_FUNC Func_lchown _ws_lchown;
-EXTERN_FUNC Func_link _ws_link;
-EXTERN_FUNC Func_lstat _ws_lstat;
-EXTERN_FUNC Func_lstat64 _ws_lstat64;
-EXTERN_FUNC Func___lxstat _ws___lxstat;
-EXTERN_FUNC Func___lxstat64 _ws___lxstat64;
-EXTERN_FUNC Func_mkdir _ws_mkdir;
-EXTERN_FUNC Func_readlink _ws_readlink;
-EXTERN_FUNC Func_rename _ws_rename;
-EXTERN_FUNC Func_rmdir _ws_rmdir;
-EXTERN_FUNC Func_stat _ws_stat;
-EXTERN_FUNC Func_stat64 _ws_stat64;
-EXTERN_FUNC Func___xstat _ws___xstat;
-EXTERN_FUNC Func___xstat64 _ws___xstat64;
-EXTERN_FUNC Func_statfs _ws_statfs;
-EXTERN_FUNC Func_statfs64 _ws_statfs64;
-EXTERN_FUNC Func_symlink _ws_symlink;
-EXTERN_FUNC Func_unlink _ws_unlink;
-EXTERN_FUNC Func_utime _ws_utime;
-EXTERN_FUNC Func_utimes _ws_utimes;
-
-EXTERN_FUNC Func_execl _ws_execl;
-EXTERN_FUNC Func_execle _ws_execle;
-EXTERN_FUNC Func_execlp _ws_execlp;
-EXTERN_FUNC Func_execv _ws_execv;
-EXTERN_FUNC Func_execvp _ws_execvp;
-EXTERN_FUNC Func_fopen _ws_fopen;
-EXTERN_FUNC Func_fopen64 _ws_fopen64;
-EXTERN_FUNC Func_freopen _ws_freopen;
-EXTERN_FUNC Func_ftw _ws_ftw;
-EXTERN_FUNC Func_opendir _ws_opendir;
-EXTERN_FUNC Func_dlopen _ws_dlopen;
-
-EXTERN_FUNC Func_setpriority _ws_setpriority;
-//EXTERN_FUNC Func_pipe _ws_pipe;
-
-#define kMaxDisplays 4
-
-/*
- * Global values.  Must be initialized in initGlobals(), which is executed
- * the first time somebody calls dlopen on the wrapper lib.
- */
-struct WrapSimGlobals {
-    volatile int    initialized;
-
-    /* descriptor where we write log messages */
-    int         logFd;
-
-    /* socket for communicating with simulator front-end */
-    int         simulatorFd;
-
-    /* coordinate thread startup */
-    pthread_mutex_t startLock;
-    pthread_cond_t  startCond;
-    int             startReady;
-    int             simulatorInitFailed;
-
-    /* base directory for filename remapping */
-    char*       remapBaseDir;
-    int         remapBaseDirLen;
-
-    /*
-     * Display characteristics.
-     *
-     * TODO: this is retrieved from the simulator during initial config.
-     * It needs to be visible to whatever process holds the surfaceflinger,
-     * which may or may not be the initial process in multi-process mode.
-     * We probably want to get the display config via a query, performed at
-     * intercepted-ioctl time, rather than a push from the sim at startup.
-     */
-    struct {
-        int     width;
-        int     height;
-
-        int     shmemKey;
-        int     shmid;
-        void*   addr;
-        long    length;
-        int     semid;
-    } display[kMaxDisplays];
-    int     numDisplays;
-
-    /*
-     * Input device.
-     */
-    FakeDev*    keyInputDevice;
-    const char *keyMap;
-
-    /* fake file descriptor allocation map */
-    pthread_mutex_t fakeFdLock;
-    BitVector*  fakeFdMap;
-    FakeDev*    fakeFdList[kMaxFakeFdCount];
-};
-
-extern struct WrapSimGlobals gWrapSim;
-
-#endif /*_WRAPSIM_GLOBALS_H*/
diff --git a/simulator/wrapsim/Init.c b/simulator/wrapsim/Init.c
deleted file mode 100644
index eed650b..0000000
--- a/simulator/wrapsim/Init.c
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Initialize the intercepts.
- */
-#include "Common.h"
-
-#define __USE_GNU       /* need RTLD_NEXT */
-#include <dlfcn.h>
-
-#include <stdlib.h>
-#include <pthread.h>
-#include <string.h>
-#include <errno.h>
-#include <assert.h>
-#include <sys/stat.h>
-#include <sys/types.h>
-
-
-/*
- * Global state.
- */
-struct WrapSimGlobals gWrapSim;
-pthread_once_t gWrapSimInitialized = PTHREAD_ONCE_INIT;
-
-/*
- * Initialize our global state.
- */
-static void initGlobals(void)
-{
-    memset(&gWrapSim, 0xdd, sizeof(gWrapSim));
-    gWrapSim.logFd = -1;
-    gWrapSim.keyMap = NULL;
-
-    /*
-     * Find the original version of functions we override.
-     */
-    _ws_access = dlsym(RTLD_NEXT, "access");
-    _ws_open = dlsym(RTLD_NEXT, "open");
-    _ws_open64 = dlsym(RTLD_NEXT, "open64");
-
-    _ws_close = dlsym(RTLD_NEXT, "close");
-    _ws_read = dlsym(RTLD_NEXT, "read");
-    _ws_readv = dlsym(RTLD_NEXT, "readv");
-    _ws_write = dlsym(RTLD_NEXT, "write");
-    _ws_writev = dlsym(RTLD_NEXT, "writev");
-    _ws_mmap = dlsym(RTLD_NEXT, "mmap");
-    _ws_mmap64 = dlsym(RTLD_NEXT, "mmap64");
-    _ws_ioctl = dlsym(RTLD_NEXT, "ioctl");
-
-    _ws_chdir = dlsym(RTLD_NEXT, "chdir");
-    _ws_chmod = dlsym(RTLD_NEXT, "chmod");
-    _ws_chown = dlsym(RTLD_NEXT, "chown");
-    _ws_creat = dlsym(RTLD_NEXT, "creat");
-    _ws_execve = dlsym(RTLD_NEXT, "execve");
-    _ws_getcwd = dlsym(RTLD_NEXT, "getcwd");
-    _ws_lchown = dlsym(RTLD_NEXT, "lchown");
-    _ws_link = dlsym(RTLD_NEXT, "link");
-    _ws_lstat = dlsym(RTLD_NEXT, "lstat");
-    _ws_lstat64 = dlsym(RTLD_NEXT, "lstat64");
-    _ws___lxstat = dlsym(RTLD_NEXT, "__lxstat");
-    _ws___lxstat64 = dlsym(RTLD_NEXT, "__lxstat64");
-    _ws_mkdir = dlsym(RTLD_NEXT, "mkdir");
-    _ws_readlink = dlsym(RTLD_NEXT, "readlink");
-    _ws_rename = dlsym(RTLD_NEXT, "rename");
-    _ws_rmdir = dlsym(RTLD_NEXT, "rmdir");
-    _ws_stat = dlsym(RTLD_NEXT, "stat");
-    _ws_stat64 = dlsym(RTLD_NEXT, "stat64");
-    _ws___xstat = dlsym(RTLD_NEXT, "__xstat");
-    _ws___xstat64 = dlsym(RTLD_NEXT, "__xstat64");
-    _ws_statfs = dlsym(RTLD_NEXT, "statfs");
-    _ws_statfs64 = dlsym(RTLD_NEXT, "statfs64");
-    _ws_symlink = dlsym(RTLD_NEXT, "symlink");
-    _ws_unlink = dlsym(RTLD_NEXT, "unlink");
-    _ws_utime = dlsym(RTLD_NEXT, "utime");
-    _ws_utimes = dlsym(RTLD_NEXT, "utimes");
-
-    _ws_execl = dlsym(RTLD_NEXT, "execl");
-    _ws_execle = dlsym(RTLD_NEXT, "execle");
-    _ws_execlp = dlsym(RTLD_NEXT, "execlp");
-    _ws_execv = dlsym(RTLD_NEXT, "execv");
-    _ws_execvp = dlsym(RTLD_NEXT, "execvp");
-    _ws_fopen = dlsym(RTLD_NEXT, "fopen");
-    _ws_fopen64 = dlsym(RTLD_NEXT, "fopen64");
-    _ws_freopen = dlsym(RTLD_NEXT, "freopen");
-    _ws_ftw = dlsym(RTLD_NEXT, "ftw");
-    _ws_opendir = dlsym(RTLD_NEXT, "opendir");
-    _ws_dlopen = dlsym(RTLD_NEXT, "dlopen");
-
-    _ws_setpriority = dlsym(RTLD_NEXT, "setpriority");
-    //_ws_pipe = dlsym(RTLD_NEXT, "pipe");
-
-    const char* logFileName = getenv("WRAPSIM_LOG");
-    if (logFileName != NULL ){
-        gWrapSim.logFd = _ws_open(logFileName, O_WRONLY|O_APPEND|O_CREAT, 0664);
-    }
-
-    /* log messages now work; say hello */
-    wsLog("--- initializing sim wrapper ---\n");
-
-    gWrapSim.simulatorFd = -1;
-
-    pthread_mutex_init(&gWrapSim.startLock, NULL);
-    pthread_cond_init(&gWrapSim.startCond, NULL);
-    gWrapSim.startReady = 0;
-
-    pthread_mutex_init(&gWrapSim.fakeFdLock, NULL);
-    gWrapSim.fakeFdMap = wsAllocBitVector(kMaxFakeFdCount, 0);
-    memset(gWrapSim.fakeFdList, 0, sizeof(gWrapSim.fakeFdList));
-
-    gWrapSim.numDisplays = 0;
-
-    gWrapSim.keyInputDevice = NULL;
-
-    /*
-     * Get target for remapped "/system" and "/data".
-     *
-     * The ANDROID_PRODUCT_OUT env var *must* be set for rewriting to work.
-     */
-    const char* outEnv = getenv("ANDROID_PRODUCT_OUT");
-    if (outEnv == NULL) {
-        gWrapSim.remapBaseDir = NULL;
-        wsLog("--- $ANDROID_PRODUCT_OUT not set, "
-                "filename remapping disabled\n");
-    } else {
-        /* grab string and append '/' -- note this never gets freed */
-        gWrapSim.remapBaseDirLen = strlen(outEnv);
-        gWrapSim.remapBaseDir = strdup(outEnv);
-        wsLog("--- name remap to %s\n", gWrapSim.remapBaseDir);
-    }
-
-    gWrapSim.initialized = 1;
-}
-
-/*
- * Creates a directory, or prints a log message if it fails.
- */
-static int createTargetDirectory(const char *path, mode_t mode)
-{
-    int ret;
-
-    ret = mkdir(path, mode);
-    if (ret == 0 || errno == EEXIST) {
-        return 0;
-    }
-    wsLog("--- could not create target directory %s: %s\n",
-            path, strerror(errno));
-    return ret;
-}
-
-/*
- * Any setup that would normally be done by init(8).
- * Note that since the syscall redirects have been installed
- * at this point, we are effectively operating within the
- * simulation context.
- */
-static void initGeneral(void)
-{
-    wsLog("--- preparing system\n");
-
-    /* Try to make sure that certain directories exist.
-     * If we fail to create them, the errors will show up in the log,
-     * but we keep going.
-     */
-    createTargetDirectory("/data", 0777);
-    createTargetDirectory("/data/dalvik-cache", 0777);
-}
-
-/*
- * Initialize all necessary state, and indicate that we're ready to go.
- */
-static void initOnce(void)
-{
-    initGlobals();
-    initGeneral();
-}
-
-/*
- * Shared object initializer.  glibc guarantees that this function is
- * called before dlopen() returns.  It may be called multiple times.
- */
-__attribute__((constructor))
-static void initialize(void)
-{
-    pthread_once(&gWrapSimInitialized, initOnce);
-}
-
-
diff --git a/simulator/wrapsim/Intercept.c b/simulator/wrapsim/Intercept.c
deleted file mode 100644
index 29b0e00..0000000
--- a/simulator/wrapsim/Intercept.c
+++ /dev/null
@@ -1,816 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Syscall and library intercepts.
- */
-
-/* don't remap open() to open64() */
-#undef _FILE_OFFSET_BITS
-
-#define CREATE_FUNC_STORAGE
-#include "Common.h"
-
-#include <stdlib.h>
-#include <string.h>
-#include <stdarg.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <sys/uio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/time.h>
-#include <sys/resource.h>
-#include <utime.h>
-#include <limits.h>
-#include <ftw.h>
-#include <assert.h>
-
-
-#if defined _FILE_OFFSET_BITS && _FILE_OFFSET_BITS == 64
-#warning "big"
-#endif
-
-//#define CALLTRACE(format, ...)   wsLog(format, ##__VA_ARGS__)
-#define CALLTRACE(format, ...)   ((void)0)
-
-//#define CALLTRACEV(format, ...)  wsLog(format, ##__VA_ARGS__)
-#define CALLTRACEV(format, ...)  ((void)0)
-
-/*
-When opening certain files, we need to simulate the contents.  For example,
-we can pretend to open the frame buffer, and respond to ioctl()s by
-returning fake data or telling the front-end to render new data.
-
-We want to intercept specific files in /dev.  In some cases we want to
-intercept and reject, e.g. to indicate that a standard Linux device does
-not exist.
-
-Some things we're not going to intercept:
-  /etc/... (e.g. /etc/timezone) -- std. Linux version should be okay
-  /proc/... (e.g. /proc/stat) -- we're showing real pid, so real proc will work
-
-For the device drivers we need to intercept:
-
-  close(), ioctl(), mmap(), open()/open64(), read(), readv(), write(),
-  writev()
-
-May also need stat().  We don't need all fd calls, e.g. fchdir() is
-not likely to succeed on a device driver.  The expected uses of mmap()
-shouldn't require intercepting related calls like madvise() -- we will
-provide an actual mapping of the requested size.  In some cases we will
-want to return a "real" fd so the app can poll() or select() on it.
-
-
-We also need to consider:
-  getuid/setuid + variations -- fake out multi-user-id stuff
-
-
-We also want to translate filenames, effectively performing a "chroot"
-without all the baggage that comes with it.  The mapping looks like:
-
-  /system/... --> $ANDROID_PRODUCT_OUT/system/...
-  /data/... --> $ANDROID_PRODUCT_OUT/data/...
-
-Translating pathnames requires interception of additional system calls,
-substituting a new path.  Calls include:
-
-  access(), chdir(), chmod(), chown(), creat(), execve(), getcwd(),
-  lchown(), link(), lstat()/lstat64(), mkdir(), open()/open64(),
-  readlink(), rename(), rmdir(), stat()/stat64(), statfs/statfs64(),
-  symlink(), unlink(), utimes(),
-
-Possibly also mknod(), mount(), umount().
-
-The "at" family, notably openat(), should just work since the root comes
-from an open directory fd.
-
-We also need these libc calls, because LD_LIBRARY_PATH substitutes at
-the libc link level, not the syscall layer:
-
-  execl(), execlp(), execle(), execv(), execvp(), fopen(), ftw(), getwd(),
-  opendir(), dlopen()
-
-It is possible for the cwd to leak out.  Some possible leaks:
-  - /proc/[self]/exe
-  - /proc/[self]/cwd
-  - LD_LIBRARY_PATH (which may be awkward to work around)
-
-
-To provide a replacement for the dirent functions -- only required if we
-want to show "fake" directory contents -- we would need:
-
-  closedir(), dirfd() readdir(), rewinddir(), scandir(), seekdir(),
-  telldir()
-
-
-*/
-
-
-/*
- * ===========================================================================
- *      Filename remapping
- * ===========================================================================
- */
-
-/*
- * If appropriate, rewrite the path to point to a different location.
- *
- * Returns either "pathBuf" or "origPath" depending on whether or not we
- * chose to rewrite the path.  "origPath" must be a buffer capable of
- * holding an extended pathname; for best results use PATH_MAX.
- */
-static const char* rewritePath(const char* func, char* pathBuf,
-    const char* origPath)
-{
-    /*
-     * Rewrite paths that start with "/system/" or "/data/"
-     */
-    if (origPath[0] != '/')
-        goto skip_rewrite;
-    if (memcmp(origPath+1, "system", 6) == 0 &&
-        (origPath[7] == '/' || origPath[7] == '\0'))
-            goto do_rewrite;
-    if (memcmp(origPath+1, "data", 4) == 0 &&
-        (origPath[5] == '/' || origPath[5] == '\0'))
-            goto do_rewrite;
-
-skip_rewrite:
-    /* check to see if something is side-stepping the rewrite */
-    if (memcmp(origPath, gWrapSim.remapBaseDir, gWrapSim.remapBaseDirLen) == 0)
-    {
-        wsLog("NOTE: full path used: %s(%s)\n", func, origPath);
-    }
-
-    CALLTRACE("rewrite %s('%s') --> (not rewritten)\n", func, origPath);
-    return origPath;
-
-do_rewrite:
-    memcpy(pathBuf, gWrapSim.remapBaseDir, gWrapSim.remapBaseDirLen);
-    strcpy(pathBuf + gWrapSim.remapBaseDirLen, origPath);
-    CALLTRACE("rewrite %s('%s') --> '%s'\n", func, origPath, pathBuf);
-    return pathBuf;
-}
-
-/*
- * This works if the pathname is the first argument to the function, and
- * the function returns "int".
- */
-#define PASS_THROUGH_DECL(_fname, _rtype, ...)                              \
-    _rtype _fname( __VA_ARGS__ )
-#define PASS_THROUGH_BODY(_fname, _patharg, ...)                            \
-    {                                                                       \
-        CALLTRACEV("%s\n", __FUNCTION__);                                   \
-        char pathBuf[PATH_MAX];                                             \
-        return _ws_##_fname(rewritePath(#_fname, pathBuf, _patharg),        \
-            ##__VA_ARGS__);                                                 \
-    }
-
-
-PASS_THROUGH_DECL(chdir, int, const char* path)
-PASS_THROUGH_BODY(chdir, path)
-
-PASS_THROUGH_DECL(chmod, int, const char* path, mode_t mode)
-PASS_THROUGH_BODY(chmod, path, mode)
-
-PASS_THROUGH_DECL(chown, int, const char* path, uid_t owner, gid_t group)
-PASS_THROUGH_BODY(chown, path, owner, group)
-
-PASS_THROUGH_DECL(creat, int, const char* path, mode_t mode)
-PASS_THROUGH_BODY(creat, path, mode)
-
-PASS_THROUGH_DECL(execve, int, const char* path, char* const argv[],
-    char* const envp[])
-PASS_THROUGH_BODY(execve, path, argv, envp)
-
-PASS_THROUGH_DECL(lchown, int, const char* path, uid_t owner, gid_t group)
-PASS_THROUGH_BODY(lchown, path, owner, group)
-
-PASS_THROUGH_DECL(lstat, int, const char* path, struct stat* buf)
-PASS_THROUGH_BODY(lstat, path, buf)
-
-PASS_THROUGH_DECL(lstat64, int, const char* path, struct stat* buf)
-PASS_THROUGH_BODY(lstat64, path, buf)
-
-PASS_THROUGH_DECL(mkdir, int, const char* path, mode_t mode)
-PASS_THROUGH_BODY(mkdir, path, mode)
-
-PASS_THROUGH_DECL(readlink, ssize_t, const char* path, char* buf, size_t bufsiz)
-PASS_THROUGH_BODY(readlink, path, buf, bufsiz)
-
-PASS_THROUGH_DECL(rmdir, int, const char* path)
-PASS_THROUGH_BODY(rmdir, path)
-
-PASS_THROUGH_DECL(stat, int, const char* path, struct stat* buf)
-PASS_THROUGH_BODY(stat, path, buf)
-
-PASS_THROUGH_DECL(stat64, int, const char* path, struct stat* buf)
-PASS_THROUGH_BODY(stat64, path, buf)
-
-PASS_THROUGH_DECL(statfs, int, const char* path, struct statfs* buf)
-PASS_THROUGH_BODY(statfs, path, buf)
-
-PASS_THROUGH_DECL(statfs64, int, const char* path, struct statfs* buf)
-PASS_THROUGH_BODY(statfs64, path, buf)
-
-PASS_THROUGH_DECL(unlink, int, const char* path)
-PASS_THROUGH_BODY(unlink, path)
-
-PASS_THROUGH_DECL(utime, int, const char* path, const struct utimbuf* buf)
-PASS_THROUGH_BODY(utime, path, buf)
-
-PASS_THROUGH_DECL(utimes, int, const char* path, const struct timeval times[2])
-PASS_THROUGH_BODY(utimes, path, times)
-
-
-PASS_THROUGH_DECL(fopen, FILE*, const char* path, const char* mode)
-PASS_THROUGH_BODY(fopen, path, mode)
-
-PASS_THROUGH_DECL(fopen64, FILE*, const char* path, const char* mode)
-PASS_THROUGH_BODY(fopen64, path, mode)
-
-PASS_THROUGH_DECL(freopen, FILE*, const char* path, const char* mode,
-    FILE* stream)
-PASS_THROUGH_BODY(freopen, path, mode, stream)
-
-PASS_THROUGH_DECL(ftw, int, const char* dirpath,
-          int (*fn) (const char* fpath, const struct stat* sb, int typeflag),
-          int nopenfd)
-PASS_THROUGH_BODY(ftw, dirpath, fn, nopenfd)
-
-PASS_THROUGH_DECL(opendir, DIR*, const char* path)
-PASS_THROUGH_BODY(opendir, path)
-
-PASS_THROUGH_DECL(dlopen, void*, const char* path, int flag)
-PASS_THROUGH_BODY(dlopen, path, flag)
-
-/*
- * Opposite of path translation -- remove prefix.
- *
- * It looks like BSD allows you to pass a NULL value for "buf" to inspire
- * getcwd to allocate storage with malloc() (as an extension to the POSIX
- * definition, which doesn't specify this).  getcwd() is a system call
- * under Linux, so this doesn't work, but that doesn't stop gdb from
- * trying to use it anyway.
- */
-char* getcwd(char* buf, size_t size)
-{
-    CALLTRACEV("%s %p %d\n", __FUNCTION__, buf, size);
-
-    char* result = _ws_getcwd(buf, size);
-    if (buf != NULL && result != NULL) {
-        if (memcmp(buf, gWrapSim.remapBaseDir,
-                    gWrapSim.remapBaseDirLen) == 0)
-        {
-            memmove(buf, buf + gWrapSim.remapBaseDirLen,
-                strlen(buf + gWrapSim.remapBaseDirLen)+1);
-            CALLTRACE("rewrite getcwd() -> %s\n", result);
-        } else {
-            CALLTRACE("not rewriting getcwd(%s)\n", result);
-        }
-    }
-    return result;
-}
-
-/*
- * Need to tweak both pathnames.
- */
-int link(const char* oldPath, const char* newPath)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf1[PATH_MAX];
-    char pathBuf2[PATH_MAX];
-    return _ws_link(rewritePath("link-1", pathBuf1, oldPath),
-                    rewritePath("link-2", pathBuf2, newPath));
-}
-
-/*
- * Need to tweak both pathnames.
- */
-int rename(const char* oldPath, const char* newPath)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf1[PATH_MAX];
-    char pathBuf2[PATH_MAX];
-    return _ws_rename(rewritePath("rename-1", pathBuf1, oldPath),
-                      rewritePath("rename-2", pathBuf2, newPath));
-}
-
-/*
- * Need to tweak both pathnames.
- */
-int symlink(const char* oldPath, const char* newPath)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf1[PATH_MAX];
-    char pathBuf2[PATH_MAX];
-    return _ws_symlink(rewritePath("symlink-1", pathBuf1, oldPath),
-                       rewritePath("symlink-2", pathBuf2, newPath));
-}
-
-/*
- * glibc stat turns into this (32-bit).
- */
-int __xstat(int version, const char* path, struct stat* sbuf)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-    char pathBuf[PATH_MAX];
-    return _ws___xstat(version, rewritePath("__xstat", pathBuf, path),
-        sbuf);
-}
-
-/*
- * glibc stat turns into this (64-bit).
- */
-int __xstat64(int version, const char* path, struct stat* sbuf)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-    char pathBuf[PATH_MAX];
-    return _ws___xstat64(version, rewritePath("__xstat64", pathBuf, path),
-        sbuf);
-}
-
-/*
- * glibc lstat turns into this (32-bit).
- */
-int __lxstat(int version, const char* path, struct stat* sbuf)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-    char pathBuf[PATH_MAX];
-    return _ws___lxstat(version, rewritePath("__lxstat", pathBuf, path),
-        sbuf);
-}
-
-/*
- * glibc lstat turns into this (64-bit).
- */
-int __lxstat64(int version, const char* path, struct stat* sbuf)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-    char pathBuf[PATH_MAX];
-    return _ws___lxstat64(version, rewritePath("__lxstat64", pathBuf, path),
-        sbuf);
-}
-
-/*
- * Copy the argument list out of varargs for execl/execlp/execle.  This
- * leaves the argc value in _argc, and a NULL-terminated array of character
- * pointers in _argv.  We stop at the first NULL argument, so we shouldn't
- * end up copying "envp" out.
- *
- * We could use gcc __builtin_apply_args to just pass stuff through,
- * but that may not get along with the path rewriting.  It's unclear
- * whether we want to rewrite the first argument (i.e. the string that
- * becomes argv[0]); it only makes sense if the exec'ed program is also
- * getting remapped.
- */
-#define COPY_EXEC_ARGLIST(_first, _argc, _argv)                             \
-    int _argc = 0;                                                          \
-    {                                                                       \
-        va_list vargs;                                                      \
-        va_start(vargs, _first);                                            \
-        while (1) {                                                         \
-            _argc++;                                                        \
-            const char* val = va_arg(vargs, const char*);                   \
-            if (val == NULL)                                                \
-                break;                                                      \
-        }                                                                   \
-        va_end(vargs);                                                      \
-    }                                                                       \
-    const char* _argv[_argc+1];                                             \
-    _argv[0] = _first;                                                      \
-    {                                                                       \
-        va_list vargs;                                                      \
-        int i;                                                              \
-        va_start(vargs, _first);                                            \
-        for (i = 1; i < _argc; i++) {                                       \
-            _argv[i] = va_arg(vargs, const char*);                          \
-        }                                                                   \
-        va_end(vargs);                                                      \
-    }                                                                       \
-    _argv[_argc] = NULL;
-
-/*
- * Debug dump.
- */
-static void dumpExecArgs(const char* callName, const char* path,
-    int argc, const char* argv[], char* const envp[])
-{
-    int i;
-
-    CALLTRACE("Calling %s '%s' (envp=%p)\n", callName, path, envp);
-    for (i = 0; i <= argc; i++)
-        CALLTRACE("  %d: %s\n", i, argv[i]);
-}
-
-/*
- * Extract varargs, convert paths, hand off to execv.
- */
-int execl(const char* path, const char* arg, ...)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf[PATH_MAX];
-
-    COPY_EXEC_ARGLIST(arg, argc, argv);
-    dumpExecArgs("execl", path, argc, argv, NULL);
-    path = rewritePath("execl", pathBuf, path);
-    return _ws_execv(path, (char* const*) argv);
-}
-
-/*
- * Extract varargs, convert paths, hand off to execve.
- *
- * The execle prototype in the man page isn't valid C -- it shows the
- * "envp" argument after the "...".  We have to pull it out with the rest
- * of the varargs.
- */
-int execle(const char* path, const char* arg, ...)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf[PATH_MAX];
-
-    COPY_EXEC_ARGLIST(arg, argc, argv);
-
-    /* run through again and find envp */
-    char* const* envp;
-
-    va_list vargs;
-    va_start(vargs, arg);
-    while (1) {
-        const char* val = va_arg(vargs, const char*);
-        if (val == NULL) {
-            envp = va_arg(vargs, char* const*);
-            break;
-        }
-    }
-    va_end(vargs);
-
-    dumpExecArgs("execle", path, argc, argv, envp);
-    path = rewritePath("execl", pathBuf, path);
-
-    return _ws_execve(path, (char* const*) argv, envp);
-}
-
-/*
- * Extract varargs, convert paths, hand off to execvp.
- */
-int execlp(const char* file, const char* arg, ...)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf[PATH_MAX];
-
-    COPY_EXEC_ARGLIST(arg, argc, argv);
-    dumpExecArgs("execlp", file, argc, argv, NULL);
-    file = rewritePath("execlp", pathBuf, file);
-    return _ws_execvp(file, (char* const*) argv);
-}
-
-/*
- * Update path, forward to execv.
- */
-int execv(const char* path, char* const argv[])
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf[PATH_MAX];
-
-    path = rewritePath("execv", pathBuf, path);
-    return _ws_execv(path, argv);
-}
-
-/*
- * Shouldn't need to do anything unless they specified a full path to execvp.
- */
-int execvp(const char* file, char* const argv[])
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    char pathBuf[PATH_MAX];
-
-    file = rewritePath("execvp", pathBuf, file);
-    return _ws_execvp(file, argv);
-}
-
-
-/*
- * ===========================================================================
- *      Device fakery
- * ===========================================================================
- */
-
-/*
- * Need to do filesystem translation and show fake devices.
- */
-int access(const char* pathName, int mode)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    int status = wsInterceptDeviceAccess(pathName, mode);
-    if (status == 0)
-        return 0;
-    else if (status == -2)
-        return -1;          // errno already set
-    else {
-        char pathBuf[PATH_MAX];
-        return _ws_access(rewritePath("access", pathBuf, pathName), mode);
-    }
-}
-
-/*
- * Common handler for open().
- */
-int openCommon(const char* pathName, int flags, mode_t mode)
-{
-    char pathBuf[PATH_MAX];
-    int fd;
-
-    assert(gWrapSim.initialized);
-
-    fd = wsInterceptDeviceOpen(pathName, flags);
-    if (fd >= 0) {
-        return fd;
-    } else if (fd == -2) {
-        /* errno should be set */
-        return -1;
-    }
-
-    if ((flags & O_CREAT) != 0) {
-        fd = _ws_open(rewritePath("open", pathBuf, pathName), flags, mode);
-        CALLTRACE("open(%s, 0x%x, 0%o) = %d\n", pathName, flags, mode, fd);
-    } else {
-        fd = _ws_open(rewritePath("open", pathBuf, pathName), flags, 0);
-        CALLTRACE("open(%s, 0x%x) = %d\n", pathName, flags, fd);
-    }
-    return fd;
-}
-
-/*
- * Replacement open() and variants.
- *
- * We have to use the vararg decl for the standard call so it matches
- * the definition in fcntl.h.
- */
-int open(const char* pathName, int flags, ...)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    mode_t mode = 0;
-    if ((flags & O_CREAT) != 0) {
-        va_list args;
-
-        va_start(args, flags);
-        mode = va_arg(args, mode_t);
-        va_end(args);
-    }
-
-    return openCommon(pathName, flags, mode);
-}
-int __open(const char* pathName, int flags, mode_t mode)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    return openCommon(pathName, flags, mode);
-}
-
-/*
- * Common handler for open64().
- */
-int open64Common(const char* pathName, int flags, mode_t mode)
-{
-    char pathBuf[PATH_MAX];
-    int fd;
-
-    assert(gWrapSim.initialized);
-
-    fd = wsInterceptDeviceOpen(pathName, flags);
-    if (fd >= 0) {
-        return fd;
-    }
-
-    if ((flags & O_CREAT) != 0) {
-        fd = _ws_open64(rewritePath("open64", pathBuf, pathName), flags, mode);
-        CALLTRACE("open64(%s, 0x%x, 0%o) = %d\n", pathName, flags, mode, fd);
-    } else {
-        fd = _ws_open64(rewritePath("open64", pathBuf, pathName), flags, 0);
-        CALLTRACE("open64(%s, 0x%x) = %d\n", pathName, flags, fd);
-    }
-    return fd;
-}
-
-/*
- * Replacement open64() and variants.
- *
- * We have to use the vararg decl for the standard call so it matches
- * the definition in fcntl.h.
- */
-int open64(const char* pathName, int flags, ...)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    mode_t mode = 0;
-    if ((flags & O_CREAT) != 0) {
-        va_list args;
-
-        va_start(args, flags);
-        mode = va_arg(args, mode_t);
-        va_end(args);
-    }
-    return open64Common(pathName, flags, mode);
-}
-int __open64(const char* pathName, int flags, mode_t mode)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    return open64Common(pathName, flags, mode);
-}
-
-
-/*
- * Close a file descriptor.
- */
-int close(int fd)
-{
-    CALLTRACEV("%s(%d)\n", __FUNCTION__, fd);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        int result = dev->close(dev, fd);
-        wsFreeFakeDev(dev);
-        return result;
-    } else {
-        CALLTRACE("close(%d)\n", fd);
-        return _ws_close(fd);
-    }
-}
-
-/*
- * Map a region.
- */
-void* mmap(void* start, size_t length, int prot, int flags, int fd,
-    __off_t offset)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->mmap(dev, start, length, prot, flags, fd, offset);
-    } else {
-        CALLTRACE("mmap(%p, %d, %d, %d, %d, %d)\n",
-            start, (int) length, prot, flags, fd, (int) offset);
-        return _ws_mmap(start, length, prot, flags, fd, offset);
-    }
-}
-
-/*
- * Map a region.
- */
-void* mmap64(void* start, size_t length, int prot, int flags, int fd,
-    __off64_t offset)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->mmap(dev, start, length, prot, flags, fd, (__off_t) offset);
-    } else {
-        CALLTRACE("mmap64(%p, %d, %d, %d, %d, %d)\n",
-            start, (int) length, prot, flags, fd, (int) offset);
-        return _ws_mmap(start, length, prot, flags, fd, offset);
-    }
-}
-
-/*
- * The Linux headers show this with a vararg header, but as far as I can
- * tell the kernel always expects 3 args.
- */
-int ioctl(int fd, int request, ...)
-{
-    CALLTRACEV("%s(%d, %d, ...)\n", __FUNCTION__, fd, request);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    va_list args;
-    void* argp;
-
-    /* extract argp from varargs */
-    va_start(args, request);
-    argp = va_arg(args, void*);
-    va_end(args);
-
-    if (dev != NULL) {
-        return dev->ioctl(dev, fd, request, argp);
-    } else {
-        CALLTRACE("ioctl(%d, 0x%x, %p)\n", fd, request, argp);
-        return _ws_ioctl(fd, request, argp);
-    }
-}
-
-/*
- * Read data.
- */
-ssize_t read(int fd, void* buf, size_t count)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->read(dev, fd, buf, count);
-    } else {
-        CALLTRACE("read(%d, %p, %u)\n", fd, buf, count);
-        return _ws_read(fd, buf, count);
-    }
-}
-
-/*
- * Write data.
- */
-ssize_t write(int fd, const void* buf, size_t count)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->write(dev, fd, buf, count);
-    } else {
-        CALLTRACE("write(%d, %p, %u)\n", fd, buf, count);
-        return _ws_write(fd, buf, count);
-    }
-}
-
-/*
- * Read a data vector.
- */
-ssize_t readv(int fd, const struct iovec* vector, int count)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->readv(dev, fd, vector, count);
-    } else {
-        CALLTRACE("readv(%d, %p, %u)\n", fd, vector, count);
-        return _ws_readv(fd, vector, count);
-    }
-}
-
-/*
- * Write a data vector.
- */
-ssize_t writev(int fd, const struct iovec* vector, int count)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    FakeDev* dev = wsFakeDevFromFd(fd);
-    if (dev != NULL) {
-        return dev->writev(dev, fd, vector, count);
-    } else {
-        CALLTRACE("writev(%d, %p, %u)\n", fd, vector, count);
-        return _ws_writev(fd, vector, count);
-    }
-}
-
-/*
- * Set the scheduling priority.  The sim doesn't run as root, so we have
- * to fake this out.
- *
- * For now, do some basic verification of the which and who parameters,
- * but otherwise return success.  In the future we may want to track
- * these so getpriority works.
- */
-int setpriority(__priority_which_t which, id_t who, int what)
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    if (which != PRIO_PROCESS &&
-        which != PRIO_PGRP &&
-        which != PRIO_USER) {
-        return EINVAL;
-    }
-
-    if ((int)who < 0) {
-        return ESRCH;
-    }
-
-    return 0;
-}
-
-#if 0
-/*
- * Create a pipe.  (Only needed for debugging an fd leak.)
- */
-int pipe(int filedes[2])
-{
-    CALLTRACEV("%s\n", __FUNCTION__);
-
-    int result = _ws_pipe(filedes);
-    if (result == 0)
-        CALLTRACE("pipe(%p) -> %d,%d\n", filedes, filedes[0], filedes[1]);
-    if (filedes[0] == 83)
-        abort();
-    return result;
-}
-#endif
diff --git a/simulator/wrapsim/LaunchWrapper.c b/simulator/wrapsim/LaunchWrapper.c
deleted file mode 100644
index c4f0efb..0000000
--- a/simulator/wrapsim/LaunchWrapper.c
+++ /dev/null
@@ -1,301 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Launch the specified program and, if "-wait" was specified, wait for it
- * to exit.
- *
- * When in "wait mode", print a message indicating the exit status, then
- * wait for Ctrl-C before we exit.  This is useful if we were launched
- * with "xterm -e", because it lets us see the output before the xterm bails.
- *
- * We want to ignore signals while waiting, so Ctrl-C kills the child rather
- * than us, but we need to configure the signals *after* the fork() so we
- * don't block them for the child too.
- */
-#include <stdlib.h>
-#include <stdio.h>
-#include <unistd.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-#include <limits.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <assert.h>
-
-/*
- * This is appended to $ANDROID_PRODUCT_OUT,
- * e.g. "/work/device/out/debug/host/linux-x8x/product/sim".
- */
-static const char* kWrapLib = "/system/lib/libwrapsim.so";
-
-
-/*
- * Configure LD_PRELOAD if possible.
- *
- * Returns newly-allocated storage with the preload path.
- */
-static char* configurePreload(void)
-{
-    const char* outEnv = getenv("ANDROID_PRODUCT_OUT");
-    const char* preloadEnv = getenv("LD_PRELOAD");
-    char* preload = NULL;
-
-    if (preloadEnv != NULL) {
-        /* TODO: append our stuff to existing LD_PRELOAD string */
-        fprintf(stderr,
-            "LW WARNING: LD_PRELOAD already set, not adding libwrapsim\n");
-    } else if (outEnv == NULL || *outEnv == '\0') {
-        fprintf(stderr, "LW WARNING: "
-            "$ANDROID_PRODUCT_OUT not in env, not setting LD_PRELOAD\n");
-    } else {
-        preload = (char*) malloc(strlen(outEnv) + strlen(kWrapLib) +1);
-        sprintf(preload, "%s%s", outEnv, kWrapLib);
-        setenv("LD_PRELOAD", preload, 1);
-        printf("LW: launching with LD_PRELOAD=%s\n", preload);
-    }
-
-    /* Let the process know that it's executing inside this LD_PRELOAD
-     * wrapper.
-     */
-    setenv("ANDROID_WRAPSIM", "1", 1);
-
-    return preload;
-}
-
-/*
- * Configure some environment variables that the runtime wants.
- *
- * Returns 0 if all goes well.
- */
-static int configureEnvironment()
-{
-    const char* outEnv = getenv("ANDROID_PRODUCT_OUT");
-    char pathBuf[PATH_MAX];
-    int outLen;
-
-    if (outEnv == NULL || *outEnv == '\0') {
-        fprintf(stderr, "LW WARNING: "
-            "$ANDROID_PRODUCT_OUT not in env, not configuring environment\n");
-        return 1;
-    }
-    outLen = strlen(outEnv);
-    assert(outLen + 64 < PATH_MAX);
-    memcpy(pathBuf, outEnv, outLen);
-    strcpy(pathBuf + outLen, "/system/lib");
-
-    /*
-     * Linux wants LD_LIBRARY_PATH
-     * Mac OS X wants DYLD_LIBRARY_PATH
-     * gdb under Mac OS X tramples on both of the above, so we added
-     * ANDROID_LIBRARY_PATH as a workaround.
-     *
-     * We're only supporting Linux now, so just set LD_LIBRARY_PATH.  Note
-     * this stomps the existing value, if any.
-     *
-     * If we only needed this for System.loadLibrary() we could do it later,
-     * but we need it to get the runtime started.
-     */
-    printf("LW: setting LD_LIBRARY_PATH=%s\n", pathBuf);
-    setenv("LD_LIBRARY_PATH", pathBuf, 1);
-
-    /*
-     * Trusted certificates are found, for some bizarre reason, through
-     * the JAVA_HOME environment variable.  We don't need to set this
-     * here, but it's convenient to do so.
-     */
-    strcpy(pathBuf /*+ outLen*/, "/system");
-    printf("LW: setting JAVA_HOME=%s\n", pathBuf);
-    setenv("JAVA_HOME", pathBuf, 1);
-
-    return 0;
-}
-
-/*
- * Redirect stdout/stderr to the specified file.  If "fileName" is NULL,
- * this returns successfully without doing anything.
- *
- * Returns 0 on success.
- */
-static int redirectStdio(const char* fileName)
-{
-    int fd;
-
-    if (fileName == NULL)
-        return 0;
-
-    printf("Redirecting stdio to append to '%s'\n", fileName);
-    fflush(stdout);
-    fflush(stderr);
-
-    fd = open(fileName, O_WRONLY | O_APPEND | O_CREAT, 0666);
-    if (fd < 0) {
-        fprintf(stderr, "ERROR: unable to open '%s' for writing\n",
-            fileName);
-        return 1;
-    }
-    dup2(fd, 1);
-    dup2(fd, 2);
-    close(fd);
-
-    return 0;
-}
-
-/*
- * Launch the requested process directly.
- *
- * On success this does not return (ever).
- */
-static int launch(char* argv[], const char* outputFile)
-{
-    (void) configurePreload();
-    (void) redirectStdio(outputFile);
-    execvp(argv[0], argv);
-    fprintf(stderr, "execvp %s failed: %s\n", argv[0], strerror(errno));
-    return 1;
-}
-
-/*
- * Launch in a sub-process and wait for it to finish.
- */
-static int launchWithWait(char* argv[], const char* outputFile)
-{
-    pid_t child;
-
-    child = fork();
-    if (child < 0) {
-        fprintf(stderr, "fork() failed: %s\n", strerror(errno));
-        return 1;
-    } else if (child == 0) {
-        /*
-         * This is the child, set up LD_PRELOAD if possible and launch.
-         */
-        (void) configurePreload();
-        (void) redirectStdio(outputFile);
-        execvp(argv[0], argv);
-        fprintf(stderr, "execvp %s failed: %s\n", argv[0], strerror(errno));
-        return 1;
-    } else {
-        pid_t result;
-        int status;
-
-        signal(SIGINT, SIG_IGN);
-        signal(SIGQUIT, SIG_IGN);
-
-        while (1) {
-            printf("LW: in pid %d (grp=%d), waiting on pid %d\n",
-                (int) getpid(), (int) getpgrp(), (int) child);
-            result = waitpid(child, &status, 0);
-            if (result < 0) {
-                if (errno == EINTR) {
-                    printf("Hiccup!\n");
-                    continue;
-                } else {
-                    fprintf(stderr, "waitpid failed: %s\n", strerror(errno));
-                    return 1;
-                }
-            } else if (result != child) {
-                fprintf(stderr, "bizarre: waitpid returned %d (wanted %d)\n",
-                    result, child);
-                return 1;
-            } else {
-                break;
-            }
-        }
-
-        printf("\n");
-        if (WIFEXITED(status)) {
-            printf("LW: process exited (status=%d)", WEXITSTATUS(status));
-        } else if (WIFSIGNALED(status)) {
-            printf("LW: process killed by signal %d", WTERMSIG(status));
-        } else {
-            printf("LW: process freaked out, status=0x%x\n", status);
-        }
-        if (WCOREDUMP(status)) {
-            printf(" (core dumped)");
-        }
-        printf("\n");
-
-        signal(SIGINT, SIG_DFL);
-        signal(SIGQUIT, SIG_DFL);
-
-        /*
-         * The underlying process may have changed process groups and pulled
-         * itself into the foreground.  Now that it's gone, pull ourselves
-         * back into the foreground.
-         */
-        signal(SIGTTOU, SIG_IGN);
-        if (tcsetpgrp(fileno(stdin), getpgrp()) != 0)
-            fprintf(stderr, "WARNING: tcsetpgrp failed\n");
-
-        printf("\nHit Ctrl-C or close window.\n");
-
-        while (1) {
-            sleep(10);
-        }
-
-        /* not reached */
-        return 0;
-    }
-}
-
-
-/*
- * All args are passed through.
- */
-int main(int argc, char** argv)
-{
-    int waitForChild = 0;
-    const char* outputFile = NULL;
-    int result;
-
-    /*
-     * Skip past the reference to ourselves, and check for args.
-     */
-    argv++;
-    argc--;
-    while (argc > 0) {
-        if (strcmp(argv[0], "-wait") == 0) {
-            waitForChild = 1;
-        } else if (strcmp(argv[0], "-output") == 0 && argc > 1) {
-            argv++;
-            argc--;
-            outputFile = argv[0];
-        } else {
-            /* no more args for us */
-            break;
-        }
-
-        argv++;
-        argc--;
-    }
-
-    if (argc == 0) {
-        fprintf(stderr,
-            "Usage: launch-wrapper [-wait] [-output filename] <cmd> [args...]\n");
-        result = 2;
-        goto bail;
-    }
-
-    /*
-     * Configure some environment variables.
-     */
-    if (configureEnvironment() != 0) {
-        result = 1;
-        goto bail;
-    }
-
-    /*
-     * Launch.
-     */
-    if (waitForChild)
-        result = launchWithWait(argv, outputFile);
-    else
-        result = launch(argv, outputFile);
-
-bail:
-    if (result != 0)
-        sleep(2);
-    return result;
-}
-
diff --git a/simulator/wrapsim/Log.c b/simulator/wrapsim/Log.c
deleted file mode 100644
index 7edb677..0000000
--- a/simulator/wrapsim/Log.c
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Debug-logging code.
- */
-#include "Common.h"
-
-#include <stdio.h>
-#include <stdarg.h>
-#include <time.h>
-
-/*
- * Write a message to our private log file.  This is a little awkward since
- * some or all of the system calls we want to use are being intercepted.
- */
-void wsLog(const char* format, ...)
-{
-#if defined(HAVE_LOCALTIME_R)
-    struct tm tmBuf;
-#endif
-    struct tm* ptm;
-    time_t now;
-    char timeBuf[32];
-    char prefixBuf[64];
-    int prefixLen;
-    char msgBuf[256];
-    int msgLen;
-
-    if (gWrapSim.logFd < 0)
-        return;
-
-    /*
-     * Create a prefix with a timestamp.
-     */
-    now = time(NULL);
-#if defined(HAVE_LOCALTIME_R)
-    ptm = localtime_r(&now, &tmBuf);
-#else
-    ptm = localtime(&now);
-#endif
-    //strftime(timeBuf, sizeof(timeBuf), "%m-%d %H:%M:%S", ptm);
-    strftime(timeBuf, sizeof(timeBuf), "%H:%M:%S", ptm);
-
-    prefixLen = snprintf(prefixBuf, sizeof(prefixBuf), "%s %5d ",
-        timeBuf, (int) getpid());
-
-    /*
-     * Format the message into a buffer.
-     */
-    va_list args;
-
-    va_start(args, format);
-    msgLen = vsnprintf(msgBuf, sizeof(msgBuf), format, args);
-    va_end(args);
-
-    /* if we overflowed, trim and annotate */
-    if (msgLen >= (int) sizeof(msgBuf)) {
-        msgBuf[sizeof(msgBuf)-2] = '!';
-        msgBuf[sizeof(msgBuf)-1] = '\n';
-        msgLen = sizeof(msgBuf);
-    }
-
-    /*
-     * Write the whole thing in one shot.  The log file was opened with
-     * O_APPEND so we don't have to worry about clashes.
-     */
-    struct iovec logVec[2];
-    logVec[0].iov_base = prefixBuf;
-    logVec[0].iov_len = prefixLen;
-    logVec[1].iov_base = msgBuf;
-    logVec[1].iov_len = msgLen;
-    (void) _ws_writev(gWrapSim.logFd, logVec, 2);
-}
-
diff --git a/simulator/wrapsim/Log.h b/simulator/wrapsim/Log.h
deleted file mode 100644
index 024ba44..0000000
--- a/simulator/wrapsim/Log.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Logging.
- */
-#ifndef _WRAPSIM_LOG_H
-#define _WRAPSIM_LOG_H
-
-
-/*
- * Log debug info.
- */
-void wsLog(const char* format, ...)
-    #if defined(__GNUC__)
-        __attribute__ ((format(printf, 1, 2)))
-    #endif
-    ;
-
-#endif /*_WRAPSIM_LOG_H*/
diff --git a/simulator/wrapsim/README.txt b/simulator/wrapsim/README.txt
deleted file mode 100644
index 358c06c..0000000
--- a/simulator/wrapsim/README.txt
+++ /dev/null
@@ -1,21 +0,0 @@
-This shared library is used with LD_PRELOAD to wrap the Android runtime
-when used with the desktop simulator.
-
-Because LD_PRELOAD is part of the environment when gdb and valgrind are
-invoked, the wrapper can "see" activity from both of these (more so gdb
-than valgrind).  For this reason it needs to be very careful about which
-"open" calls are intercepted.
-
-It's also important that none of the intercepted system or library calls
-are invoked directly, or infinite recursion could result.
-
-Avoid creating dependencies on other libraries.
-
-
-To debug wrapsim, set WRAPSIM_LOG to a log file before launching, e.g.
-
-% WRAPSIM_LOG=/tmp/wraplog.txt simulator
-
-For more verbose logging, you can enable the verbose forms of CALLTRACE
-and CALLTRACEV in Intercept.c.
-
diff --git a/simulator/wrapsim/SimMgr.c b/simulator/wrapsim/SimMgr.c
deleted file mode 100644
index a35c7c6..0000000
--- a/simulator/wrapsim/SimMgr.c
+++ /dev/null
@@ -1,988 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Simulator interactions.
- *
- * TODO: for multi-process we probably need to switch to a new process
- * group if we are the first process (could be runtime, could be gdb),
- * rather than wait for the simulator to tell us to switch.
- */
-#include "Common.h"
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <stdint.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <sys/ipc.h>
-#include <sys/shm.h>
-#include <sys/sem.h>
-#include <sys/un.h>
-#include <signal.h>
-#include <assert.h>
-
-// fwd
-static int connectToSim(void);
-static void listenToSim(void);
-
-/*
- * Env var to restrict who tries to talk to the front end.
- */
-#define kWrapSimConnectedEnv    "WRAP_SIM_CONNECTED"
-
-
-/*
- * Signal the main thread that we're ready to continue.
- */
-static void signalMainThread(void)
-{
-    int cc;
-
-    cc = pthread_mutex_lock(&gWrapSim.startLock);
-    assert(cc == 0);
-
-    gWrapSim.startReady = 1;
-
-    cc = pthread_cond_signal(&gWrapSim.startCond);
-    assert(cc == 0);
-
-    cc = pthread_mutex_unlock(&gWrapSim.startLock);
-    assert(cc == 0);
-}
-
-
-/*
- * Entry point for the sim management thread.
- *
- * Once we have established a connection to the simulator and are ready
- * for other threads to send messages, we signal the main thread.
- */
-static void* simThreadEntry(void* arg)
-{
-    wsLog("--- sim manager thread started\n");
-
-    /*
-     * Establish a connection to the simulator front-end.  If we can't do
-     * that, we have no access to input or output devices, and we might
-     * as well give up.
-     */
-    if (connectToSim() != 0) {
-        signalMainThread();
-        return NULL;
-    }
-
-    /* success! */
-    wsLog("--- sim manager thread ready\n");
-    gWrapSim.simulatorInitFailed = 0;
-    signalMainThread();
-
-    listenToSim();
-
-    wsLog("--- sim manager thread exiting\n");
-
-    return NULL;
-}
-
-/*
- * If we think we're not yet connected to the sim, do so now.  We only
- * want to do this once per process *group*, so we control access with
- * an environment variable.
- */
-int wsSimConnect(void)
-{
-    /*
-     * If the environment variable hasn't been set, assume we're the first
-     * to get here, and should attach to the simulator.  We set the env
-     * var here whether or not we succeed in connecting to the sim.
-     *
-     * (For correctness we should wrap the getenv/setenv in a semaphore.)
-     */
-    if (getenv(kWrapSimConnectedEnv) == NULL) {
-        pthread_attr_t threadAttr;
-        pthread_t threadHandle;
-        int cc;
-
-        gWrapSim.simulatorInitFailed = 1;
-        setenv(kWrapSimConnectedEnv, "1", 1);
-
-        cc = pthread_mutex_lock(&gWrapSim.startLock);
-        assert(cc == 0);
-
-        pthread_attr_init(&threadAttr);
-        pthread_attr_setdetachstate(&threadAttr, PTHREAD_CREATE_DETACHED);
-        cc = pthread_create(&threadHandle, &threadAttr, simThreadEntry, NULL);
-        if (cc != 0) {
-            wsLog("Unable to create new thread: %s\n", strerror(errno));
-            abort();
-        }
-
-        while (!gWrapSim.startReady) {
-            cc = pthread_cond_wait(&gWrapSim.startCond, &gWrapSim.startLock);
-            assert(cc == 0);
-        }
-
-        cc = pthread_mutex_unlock(&gWrapSim.startLock);
-        assert(cc == 0);
-
-        if (gWrapSim.simulatorInitFailed) {
-            wsLog("Simulator initialization failed, bailing\n");
-
-            /* this *should* be okay to do */
-            fprintf(stderr, "Fatal error:"
-                " unable to connect to sim front-end (not running?)\n");
-            abort();
-        }
-    }
-
-    wsLog("+++ continuing\n");
-    return 0;
-}
-
-
-/*
- * ===========================================================================
- *      Message / MessageStream
- * ===========================================================================
- */
-
-/*
- * This is a quick & dirty rewrite of the C++ Message and MessageStream
- * classes, ported to C, reduced in generality, with syscalls stubbed
- * where necessary.  I didn't fix the API to make it more sensible in C
- * (which lacks destructors), so some of this is a little fragile or
- * awkward.
- */
-
-/* values for message type byte; must match android::Message constants */
-typedef enum MessageType {
-    kTypeUnknown = 0,
-    kTypeRaw,           // chunk of raw data
-    kTypeConfig,        // send a name=value pair to peer
-    kTypeCommand,       // simple command w/arg
-    kTypeCommandExt,    // slightly more complicated command
-    kTypeLogBundle,     // multi-part log message
-} MessageType;
-
-/*
- * Reusable message object.
- */
-typedef struct Message {
-    MessageType     mType;
-    unsigned char*  mData;
-    int             mLength;
-} Message;
-
-/* magic init messages; must match android::MessageStream constants */
-enum {
-    kHelloMsg       = 0x4e303047,       // 'N00G'
-    kHelloAckMsg    = 0x31455221,       // '1ER!'
-};
-
-
-/*
- * Clear out a Message.
- */
-static void Message_clear(Message* msg)
-{
-    memset(msg, 0, sizeof(Message));
-}
-
-/*
- * Keep reading until we get all bytes or hit EOF/error.  "fd" is expected
- * to be in blocking mode.
- *
- * Returns 0 on success.
- */
-static int readAll(int fd, void* buf, size_t count)
-{
-    ssize_t actual;
-    ssize_t have;
-
-    have = 0;
-    while (have != (ssize_t) count) {
-        actual = _ws_read(fd, ((char*) buf) + have, count - have);
-        if (actual < 0) {
-            if (errno == EINTR)
-                continue;
-            wsLog("read %d failed: %s\n", fd, strerror(errno));
-        } else if (actual == 0) {
-            wsLog("early EOF on %d\n", fd);
-            return -1;
-        } else {
-            have += actual;
-        }
-
-        assert(have <= (ssize_t)count);
-    }
-
-    return 0;
-}
-
-#if 0
-/*
- * Keep writing until we put all bytes or hit an error.  "fd" is expected
- * to be in blocking mode.
- *
- * Returns 0 on success.
- */
-static int writeAll(int fd, const void* buf, size_t count)
-{
-    ssize_t actual;
-    ssize_t have;
-
-    have = 0;
-    while (have != count) {
-        actual = _ws_write(fd, ((const char*) buf) + have, count - have);
-        if (actual < 0) {
-            if (errno == EINTR)
-                continue;
-            wsLog("write %d failed: %s\n", fd, strerror(errno));
-        } else if (actual == 0) {
-            wsLog("wrote zero on %d\n", fd);
-            return -1;
-        } else {
-            have += actual;
-        }
-
-        assert(have <= count);
-    }
-
-    return 0;
-}
-#endif
-
-/*
- * Read a message from the specified file descriptor.
- *
- * The caller must Message_release(&msg).
- *
- * We guarantee 32-bit alignment for msg->mData.
- */
-static int Message_read(Message* msg, int fd)
-{
-    unsigned char header[4];
-
-    readAll(fd, header, 4);
-
-    msg->mType = (MessageType) header[2];
-    msg->mLength = header[0] | header[1] << 8;
-    msg->mLength -= 2;   // we already read two of them in the header
-
-    if (msg->mLength > 0) {
-        int actual;
-
-        /* Linux malloc guarantees at least 32-bit alignment */
-        msg->mData = (unsigned char*) malloc(msg->mLength);
-        if (msg->mData == NULL) {
-            wsLog("alloc %d failed\n", msg->mLength);
-            return -1;
-        }
-
-        if (readAll(fd, msg->mData, msg->mLength) != 0) {
-            wsLog("failed reading message body (wanted %d)\n", msg->mLength);
-            return -1;
-        }
-    } else {
-        msg->mData = NULL;
-    }
-
-    return 0;
-}
-
-/*
- * Write a message to the specified file descriptor.
- *
- * The caller must Message_release(&msg).
- */
-static int Message_write(Message* msg, int fd)
-{
-    struct iovec writeVec[2];
-    unsigned char header[4];
-    int len, numVecs;
-    ssize_t actual;
-
-    len = msg->mLength + 2;
-    header[0] = len & 0xff;
-    header[1] = (len >> 8) & 0xff;
-    header[2] = msg->mType;
-    header[3] = 0;
-    writeVec[0].iov_base = header;
-    writeVec[0].iov_len = 4;
-    numVecs = 1;
-
-    if (msg->mLength > 0) {
-        assert(msg->mData != NULL);
-        writeVec[1].iov_base = msg->mData;
-        writeVec[1].iov_len = msg->mLength;
-        numVecs++;
-    }
-
-    /* write it all in one shot; not worrying about partial writes for now */
-    actual = _ws_writev(fd, writeVec, numVecs);
-    if (actual != len+2) {
-        wsLog("failed writing message to fd %d: %d of %d %s\n",
-            fd, actual, len+2, strerror(errno));
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Release storage associated with a Message.
- */
-static void Message_release(Message* msg)
-{
-    free(msg->mData);
-    msg->mData = NULL;
-}
-
-/*
- * Extract a name/value pair from a message.
- */
-static int getConfig(const Message* msg, const char** name, const char** val)
-{
-    if (msg->mLength < 2) {
-        wsLog("message len (%d) is too short\n", msg->mLength);
-        return -1;
-    }
-    const char* ptr = (const char*) msg->mData;
-
-    *name = (const char*) ptr;
-    *val = (const char*) (ptr + strlen((char*)ptr) +1);
-    return 0;
-}
-
-/*
- * Extract a command from a message.
- */
-static int getCommand(const Message* msg, int* pCmd, int* pArg)
-{
-    if (msg->mLength != sizeof(int) * 2) {
-        wsLog("message len (%d) is wrong for cmd (%d)\n",
-            msg->mLength, sizeof(int) * 2);
-        return -1;
-    }
-
-    /* this assumes 32-bit alignment on mData */
-    const int* ptr = (const int*) msg->mData;
-
-    *pCmd = ptr[0];
-    *pArg = ptr[1];
-
-    return 0;
-}
-
-/*
- * Extract an extended command from a message.
- */
-static int getCommandExt(const Message* msg, int* pCmd, int* pArg0,
-    int* pArg1, int* pArg2)
-{
-    if (msg->mLength != sizeof(int) * 4) {
-        wsLog("message len (%d) is wrong for cmd (%d)\n",
-            msg->mLength, sizeof(int) * 4);
-        return -1;
-    }
-
-    /* this assumes 32-bit alignment on mData */
-    const int* ptr = (const int*) msg->mData;
-
-    *pCmd = ptr[0];
-    *pArg0 = ptr[1];
-    *pArg1 = ptr[2];
-    *pArg2 = ptr[3];
-
-    return 0;
-}
-
-/*
- * Attach 8 bytes of data with "cmd" and "arg" to "msg".
- *
- * "msg->mData" will need to be freed by the caller.  (This approach made
- * more sense when C++ destructors were available, but it's just not worth
- * reworking it.)
- */
-static int setCommand(Message* msg, int cmd, int arg)
-{
-    Message_clear(msg);
-
-    msg->mLength = 8;
-    msg->mData = malloc(msg->mLength);
-    msg->mType = kTypeCommand;
-
-    /* assumes 32-bit alignment on malloc blocks */
-    int* pInt = (int*) msg->mData;
-    pInt[0] = cmd;
-    pInt[1] = arg;
-
-    return 0;
-}
-
-/*
- * Construct the full path.  The caller must free() the return value.
- */
-static char* makeFilename(const char* name)
-{
-    static const char* kBasePath = "/tmp/android-";
-    char* fileName;
-
-    assert(name != NULL && name[0] != '\0');
-
-    fileName = (char*) malloc(strlen(kBasePath) + strlen(name) + 1);
-    strcpy(fileName, kBasePath);
-    strcat(fileName, name);
-
-    return fileName;
-}
-
-/*
- * Attach to a SysV shared memory segment.
- */
-static int attachToShmem(int key, int* pShmid, void** pAddr, long* pLength)
-{
-    int shmid;
-
-    shmid = shmget(key, 0, 0);
-    if (shmid == -1) {
-        wsLog("ERROR: failed to find shmem key=%d\n", key);
-        return -1;
-    }
-
-    void* addr = shmat(shmid, NULL, 0);
-    if (addr == (void*) -1) {
-        wsLog("ERROR: could not attach to key=%d shmid=%d\n", key, shmid);
-        return -1;
-    }
-
-    struct shmid_ds shmids;
-    int cc;
-
-    cc = shmctl(shmid, IPC_STAT, &shmids);
-    if (cc != 0) {
-        wsLog("ERROR: could not IPC_STAT shmid=%d\n", shmid);
-        return -1;
-    }
-    *pLength = shmids.shm_segsz;
-
-    *pAddr = addr;
-    *pShmid = shmid;
-    return 0;
-}
-
-/*
- * Attach to a SysV semaphore.
- */
-static int attachToSem(int key, int* pSemid)
-{
-    int semid;
-
-    semid = semget(key, 0, 0);
-    if (semid == -1) {
-        wsLog("ERROR: failed to attach to semaphore key=%d\n", key);
-        return -1;
-    }
-
-    *pSemid = semid;
-    return 0;
-}
-
-/*
- * "Adjust" a semaphore.
- */
-static int adjustSem(int semid, int adj)
-{
-    const int wait = 1;
-    struct sembuf op;
-    int cc;
-
-    op.sem_num = 0;
-    op.sem_op = adj;
-    op.sem_flg = SEM_UNDO;
-    if (!wait)
-        op.sem_flg |= IPC_NOWAIT;
-
-    cc = semop(semid, &op, 1);
-    if (cc != 0) {
-        if (wait || errno != EAGAIN) {
-            wsLog("Warning:"
-                " semaphore adjust by %d failed for semid=%d (errno=%d)\n",
-                adj, semid, errno);
-        }
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Acquire the semaphore associated with a display.
- */
-void wsLockDisplay(int displayIdx)
-{
-    assert(displayIdx >= 0 && displayIdx < gWrapSim.numDisplays);
-    int semid = gWrapSim.display[displayIdx].semid;
-
-    (void) adjustSem(semid, -1);
-}
-
-/*
- * Acquire the semaphore associated with a display.
- */
-void wsUnlockDisplay(int displayIdx)
-{
-    assert(displayIdx >= 0 && displayIdx < gWrapSim.numDisplays);
-    int semid = gWrapSim.display[displayIdx].semid;
-
-    (void) adjustSem(semid, 1);
-}
-
-/*
- * Process the display config from the simulator
- *
- * Right now this is a blob of raw data that looks like this:
- *  +00 magic number
- *  +04 #of displays
- *  +08 display 0:
- *      +00 width
- *      +04 height
- *      +08 format
- *      +0c refresh rate
- *      +10 shmem key
- *  +1c display 1...
- */
-static int handleDisplayConfig(const int* pData, int length)
-{
-    int numDisplays;
-
-    if (length < 8) {
-        wsLog("Bad display config: length is %d\n", length);
-        return -1;
-    }
-    assert(*pData == kDisplayConfigMagic);
-
-    /*
-     * Pull out the #of displays.  If it looks valid, configure the runtime.
-     */
-    pData++;        // skip over magic
-    numDisplays = *pData++;
-
-    if (numDisplays <= 0 || numDisplays > kMaxDisplays) {
-        wsLog("Bizarre display count %d\n", numDisplays);
-        return -1;
-    }
-    if (length != 8 + numDisplays * kValuesPerDisplay * (int)sizeof(int)) {
-        wsLog("Bad display config: length is %d (expected %d)\n",
-            length, 8 + numDisplays * kValuesPerDisplay * (int)sizeof(int));
-        return -1;
-    }
-
-    /*
-     * Extract the config values.
-     *
-     * The runtime doesn't support multiple devices, so we don't either.
-     */
-    int i;
-    for (i = 0; i < numDisplays; i++) {
-        gWrapSim.display[i].width = pData[0];
-        gWrapSim.display[i].height = pData[1];
-        gWrapSim.display[i].shmemKey = pData[4];
-        /* format/refresh no longer needed */
-
-        void* addr;
-        int shmid, semid;
-        long length;
-        if (attachToShmem(gWrapSim.display[i].shmemKey, &shmid, &addr,
-                &length) != 0)
-        {
-            wsLog("Unable to connect to shared memory\n");
-            return -1;
-        }
-
-        if (attachToSem(gWrapSim.display[i].shmemKey, &semid) != 0) {
-            wsLog("Unable to attach to sempahore\n");
-            return -1;
-        }
-
-        gWrapSim.display[i].shmid = shmid;
-        gWrapSim.display[i].addr = addr;
-        gWrapSim.display[i].length = length;
-        gWrapSim.display[i].semid = semid;
-
-        wsLog("Display %d: width=%d height=%d\n",
-            i,
-            gWrapSim.display[i].width,
-            gWrapSim.display[i].height);
-        wsLog("  shmem=0x%08x addr=%p len=%ld semid=%d\n",
-            gWrapSim.display[i].shmemKey,
-            gWrapSim.display[i].addr,
-            gWrapSim.display[i].length,
-            gWrapSim.display[i].semid);
-
-        pData += kValuesPerDisplay;
-    }
-    gWrapSim.numDisplays = numDisplays;
-
-    return 0;
-}
-
-
-/*
- * Initialize our connection to the simulator, which will be listening on
- * a UNIX domain socket.
- *
- * On success, this configures gWrapSim.simulatorFd and returns 0.
- */
-static int openSimConnection(const char* name)
-{
-    int result = -1;
-    char* fileName = NULL;
-    int sock = -1;
-    int cc;
-
-    assert(gWrapSim.simulatorFd == -1);
-
-    fileName = makeFilename(name);
-
-    struct sockaddr_un addr;
-    
-    sock = socket(AF_UNIX, SOCK_STREAM, 0);
-    if (sock < 0) {
-        wsLog("UNIX domain socket create failed (errno=%d)\n", errno);
-        goto bail;
-    }
-
-    /* connect to socket; fails if file doesn't exist */
-    strcpy(addr.sun_path, fileName);    // max 108 bytes
-    addr.sun_family = AF_UNIX;
-    cc = connect(sock, (struct sockaddr*) &addr, SUN_LEN(&addr));
-    if (cc < 0) {
-        // ENOENT means socket file doesn't exist
-        // ECONNREFUSED means socket exists but nobody is listening
-        wsLog("AF_UNIX connect failed for '%s': %s\n",
-            fileName, strerror(errno));
-        goto bail;
-    }
-
-    gWrapSim.simulatorFd = sock;
-    sock = -1;
-
-    result = 0;
-    wsLog("+++ connected to '%s'\n", fileName);
-
-bail:
-    if (sock >= 0)
-        _ws_close(sock);
-    free(fileName);
-    return result;
-}
-
-/*
- * Prepare communication with the front end.  We wait for a "hello" from
- * the other side, and respond in kind.
- */
-static int prepSimConnection(void)
-{
-    /* NOTE: this is endian-specific; we're x86 Linux only, so no problem */
-    static const unsigned int hello = kHelloMsg;
-    static const unsigned int helloAck = kHelloAckMsg;
-    Message msg;
-
-    if (Message_read(&msg, gWrapSim.simulatorFd) != 0) {
-        wsLog("hello read failed\n");
-        return -1;
-    }
-
-    if (memcmp(msg.mData, &hello, 4) != 0) {
-        wsLog("Got bad hello from peer\n");
-        return -1;
-    }
-
-    Message_release(&msg);
-
-    msg.mType = kTypeRaw;
-    msg.mData = (unsigned char*) &helloAck;
-    msg.mLength = 4;
-
-    if (Message_write(&msg, gWrapSim.simulatorFd) != 0) {
-        wsLog("hello ack write failed\n");
-        return -1;
-    }
-
-    return 0;
-}
-
-/*
- * Get the sim front-end configuration.  We loop here until the sim claims
- * to be done with us.
- */
-static int getSimConfig(void)
-{
-    Message msg;
-    int joinNewGroup, grabTerminal, done;
-    int result = -1;
-
-    joinNewGroup = grabTerminal = done = 0;
-    Message_clear(&msg);        // clear out msg->mData
-
-    wsLog("+++ awaiting hardware configuration\n");
-    while (!done) {
-        if (Message_read(&msg, gWrapSim.simulatorFd) != 0) {
-            wsLog("failed receiving config from parent\n");
-            goto bail;
-        }
-
-        if (msg.mType == kTypeCommand) {
-            int cmd, arg;
-
-            if (getCommand(&msg, &cmd, &arg) != 0)
-                goto bail;
-
-            switch (cmd) {
-            case kCommandGoAway:
-                wsLog("Simulator front-end is busy\n");
-                goto bail;
-            case kCommandNewPGroup:
-                joinNewGroup = 1;
-                grabTerminal = (arg != 0);
-                wsLog("Simulator wants us to be in a new pgrp (term=%d)\n",
-                    grabTerminal);
-                break;
-            case kCommandConfigDone:
-                done = 1;
-                break;
-            default:
-                wsLog("Got unexpected command %d/%d\n", cmd, arg);
-                break;
-            }
-        } else if (msg.mType == kTypeRaw) {
-            /* assumes 32-bit alignment and identical byte ordering */
-            int* pData = (int*) msg.mData;
-            if (msg.mLength >= 4 && *pData == kDisplayConfigMagic) {
-                if (handleDisplayConfig(pData, msg.mLength) != 0)
-                    goto bail;
-            }
-        } else if (msg.mType == kTypeConfig) {
-            const char *name;
-            const char *val;
-            getConfig(&msg, &name, &val);
-            if(strcmp(name, "keycharmap") == 0) {
-                free((void*)gWrapSim.keyMap);
-                gWrapSim.keyMap = strdup(val);
-            }
-        } else {
-            wsLog("Unexpected msg type %d during startup\n", msg.mType);
-            goto bail;
-        }
-
-        /* clear out the data field if necessary */
-        Message_release(&msg);
-    }
-
-    wsLog("Configuration received from simulator\n");
-
-    if (joinNewGroup) {
-        /* set pgid to pid */
-        pid_t pgid = getpid();
-        setpgid(0, pgid);
-
-        /*
-         * Put our pgrp in the foreground.
-         * tcsetpgrp() from background process causes us to get a SIGTTOU,
-         * which is mostly harmless but makes tcsetpgrp() fail with EINTR.
-         */
-        signal(SIGTTOU, SIG_IGN);
-        if (grabTerminal) {
-            if (tcsetpgrp(fileno(stdin), getpgrp()) != 0) {
-                wsLog("tcsetpgrp(%d, %d) failed (errno=%d)\n",
-                    fileno(stdin), getpgrp(), errno);
-            }
-            wsLog("Set pgrp %d as foreground\n", (int) getpgrp());
-        }
-    
-        /* tell the sim where we're at */
-        Message msg;
-        setCommand(&msg, kCommandNewPGroupCreated, pgid);
-        Message_write(&msg, gWrapSim.simulatorFd);
-        Message_release(&msg);
-    }
-
-    result = 0;
-
-bail:
-    /* make sure the data was freed */
-    Message_release(&msg);
-    //wsLog("bailing, result=%d\n", result);
-    return result;
-}
-
-/*
- * Connect to the simulator and exchange pleasantries.
- *
- * Returns 0 on success.
- */
-static int connectToSim(void)
-{
-    if (openSimConnection(kAndroidPipeName) != 0)
-        return -1;
-
-    if (prepSimConnection() != 0)
-        return -1;
-
-    if (getSimConfig() != 0)
-        return -1;
-
-    wsLog("+++ sim is ready to go\n");
-
-    return 0;
-}
-
-/*
- * Listen to the sim forever or until the front end shuts down, whichever
- * comes first.
- *
- * All we're really getting here are key events.
- */
-static void listenToSim(void)
-{
-    wsLog("--- listening for input events from front end\n");
-
-    while (1) {
-        Message msg;
-
-        Message_clear(&msg);
-        if (Message_read(&msg, gWrapSim.simulatorFd) != 0) {
-            wsLog("--- sim message read failed\n");
-            return;
-        }
-
-        if (msg.mType == kTypeCommand) {
-            int cmd, arg;
-
-            if (getCommand(&msg, &cmd, &arg) != 0) {
-                wsLog("bad command from sim?\n");
-                continue;
-            }
-
-            switch (cmd) {
-            case kCommandQuit:
-                wsLog("--- sim sent us a QUIT message\n");
-                return;
-            case kCommandKeyDown:
-                wsLog("KEY DOWN: %d\n", arg);
-                wsSendSimKeyEvent(arg, 1);
-                break;
-            case kCommandKeyUp:
-                wsLog("KEY UP: %d\n", arg);
-                wsSendSimKeyEvent(arg, 0);
-                break;
-            default:
-                wsLog("--- sim sent unrecognized command %d\n", cmd);
-                break;
-            }
-
-            Message_release(&msg);
-        } else if (msg.mType == kTypeCommandExt) {
-            int cmd, arg0, arg1, arg2;
-
-            if (getCommandExt(&msg, &cmd, &arg0, &arg1, &arg2) != 0) {
-                wsLog("bad ext-command from sim?\n");
-                continue;
-            }
-
-            switch (cmd) {
-            case kCommandTouch:
-                wsSendSimTouchEvent(arg0, arg1, arg2);
-                break;
-            }
-
-            Message_release(&msg);
-        } else {
-            wsLog("--- sim sent non-command message, type=%d\n", msg.mType);
-        }
-    }
-
-    assert(0);      // not reached
-}
-
-
-/*
- * Tell the simulator front-end that the display has been updated.
- */
-void wsPostDisplayUpdate(int displayIdx)
-{
-    if (gWrapSim.simulatorFd < 0) {
-        wsLog("Not posting display update -- sim not ready\n");
-        return;
-    }
-
-    Message msg;
-
-    setCommand(&msg, kCommandUpdateDisplay, displayIdx);
-    Message_write(&msg, gWrapSim.simulatorFd);
-    Message_release(&msg);
-}
-
-/*
- * Send a log message to the front-end.
- */
-void wsPostLogMessage(int logPrio, const char* tag, const char* message)
-{
-    if (gWrapSim.simulatorFd < 0) {
-        wsLog("Not posting log message -- sim not ready\n");
-        return;
-    }
-
-    time_t when = time(NULL);
-    int pid = (int) getpid();
-    int tagLen, messageLen, totalLen;
-
-    tagLen = strlen(tag) +1;
-    messageLen = strlen(message) +1;
-    totalLen = sizeof(int) * 3 + tagLen + messageLen;
-    unsigned char outBuf[totalLen];
-    unsigned char* cp = outBuf;
-
-    /* See Message::set/getLogBundle() in simulator/MessageStream.cpp. */
-    memcpy(cp, &when, sizeof(int));
-    cp += sizeof(int);
-    memcpy(cp, &logPrio, sizeof(int));
-    cp += sizeof(int);
-    memcpy(cp, &pid, sizeof(int));
-    cp += sizeof(int);
-    memcpy(cp, tag, tagLen);
-    cp += tagLen;
-    memcpy(cp, message, messageLen);
-    cp += messageLen;
-
-    assert(cp - outBuf == totalLen);
-
-    Message msg;
-    msg.mType = kTypeLogBundle;
-    msg.mData = outBuf;
-    msg.mLength = totalLen;
-    Message_write(&msg, gWrapSim.simulatorFd);
-
-    msg.mData = NULL;       // don't free
-    Message_release(&msg);
-}
-
-/*
- * Turn the vibrating notification device on or off.
- */
-void wsEnableVibration(int vibrateOn)
-{
-    if (gWrapSim.simulatorFd < 0) {
-        wsLog("Not posting vibrator update -- sim not ready\n");
-        return;
-    }
-
-    Message msg;
-
-    //wsLog("+++ sending vibrate:%d\n", vibrateOn);
-
-    setCommand(&msg, kCommandVibrate, vibrateOn);
-    Message_write(&msg, gWrapSim.simulatorFd);
-    Message_release(&msg);
-}
-
diff --git a/simulator/wrapsim/SimMgr.h b/simulator/wrapsim/SimMgr.h
deleted file mode 100644
index 378dfbc..0000000
--- a/simulator/wrapsim/SimMgr.h
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright 2007 The Android Open Source Project
- *
- * Simulator interactions.
- */
-#ifndef _WRAPSIM_SIMULATOR_H
-#define _WRAPSIM_SIMULATOR_H
-
-/*
- * Commands exchanged between simulator and runtime.
- *
- * NOTE: this is cloned from SimRuntime.h -- fix this.
- */
-typedef enum SimCommand {
-    kCommandUnknown = 0,
-
-    /* sent from sim to runtime */
-    kCommandGoAway,             // sim says: go away, I'm busy
-    kCommandConfigDone,         // sim says: done sending config
-    kCommandQuit,               // quit nicely
-    kCommandNewPGroup,          // process group management
-    kCommandKeyDown,            // key has been pressed
-    kCommandKeyUp,              // key has been released
-    kCommandTouch,              // finger touched/lifted/dragged
-
-    /* sent from runtime to sim */
-    kCommandNewPGroupCreated,   // send process group as argument
-    kCommandRuntimeReady,       // we're initialized and about to start
-    kCommandUpdateDisplay,      // display has been updated
-    kCommandVibrate,            // vibrate on or off
-} SimCommand;
-
-/*
- * Touch screen action; also clined from SimRuntime.h.
- */
-typedef enum TouchMode {
-    kTouchDown = 0,
-    kTouchUp = 1,
-    kTouchDrag = 2
-} TouchMode;
-
-
-/*
- * Some parameters for config exchange.
- */
-enum {
-    kDisplayConfigMagic = 0x44495350,
-    kValuesPerDisplay = 5,
-};
-
-/*
- * UNIX domain socket name.
- */
-#define kAndroidPipeName        "runtime"
-
-int wsSimConnect(void);
-
-/*
- * Display management.
- */
-void wsLockDisplay(int displayIdx);
-void wsUnlockDisplay(int displayIdx);
-void wsPostDisplayUpdate(int displayIdx);
-
-/*
- * Send a log message.
- */
-void wsPostLogMessage(int logPrio, const char* tag, const char* msg);
-
-/*
- * Change the state of the vibration device.
- */
-void wsEnableVibration(int vibrateOn);
-
-#endif /*_WRAPSIM_SIMULATOR_H*/
diff --git a/tools/androidprefs/.classpath b/tools/androidprefs/.classpath
deleted file mode 100644
index fb50116..0000000
--- a/tools/androidprefs/.classpath
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/androidprefs/.project b/tools/androidprefs/.project
deleted file mode 100644
index 6633bba..0000000
--- a/tools/androidprefs/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>AndroidPrefs</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/androidprefs/Android.mk b/tools/androidprefs/Android.mk
deleted file mode 100644
index 363b085..0000000
--- a/tools/androidprefs/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-JARUTILS_LOCAL_DIR := $(call my-dir)
-include $(JARUTILS_LOCAL_DIR)/src/Android.mk
diff --git a/tools/androidprefs/src/Android.mk b/tools/androidprefs/src/Android.mk
deleted file mode 100644
index ddc0aa6..0000000
--- a/tools/androidprefs/src/Android.mk
+++ /dev/null
@@ -1,24 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_MODULE := androidprefs
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/androidprefs/src/com/android/prefs/AndroidLocation.java b/tools/androidprefs/src/com/android/prefs/AndroidLocation.java
deleted file mode 100644
index cfd9f53..0000000
--- a/tools/androidprefs/src/com/android/prefs/AndroidLocation.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.prefs;
-
-import java.io.File;
-
-/**
- * Manages the location of the android files (including emulator files, ddms config, debug keystore)
- */
-public final class AndroidLocation {
-    /**
-     * Virtual Device folder inside the path returned by {@link #getFolder()}
-     */
-    public static final String FOLDER_AVD = "avd";
-
-    /**
-     * Throw when the location of the android folder couldn't be found.
-     */
-    public static final class AndroidLocationException extends Exception {
-        private static final long serialVersionUID = 1L;
-
-        public AndroidLocationException(String string) {
-            super(string);
-        }
-    }
-    
-    private static String sPrefsLocation = null;
-    
-    /**
-     * Returns the folder used to store android related files.
-     * @return an OS specific path, terminated by a separator.
-     * @throws AndroidLocationException 
-     */
-    public final static String getFolder() throws AndroidLocationException {
-        if (sPrefsLocation == null) {
-            String home = findValidPath("ANDROID_SDK_HOME", "user.home", "HOME");
-            
-            // if the above failed, we throw an exception.
-            if (home == null) {
-                throw new AndroidLocationException(
-                        "Unable to get the home directory. Make sure the user.home property is set up");
-            } else {
-                sPrefsLocation = home + File.separator + ".android" + File.separator;
-
-                // make sure the folder exists!
-                File f = new File(sPrefsLocation);
-                if (f.exists() == false) {
-                    f.mkdir();
-                } else if (f.isFile()) {
-                    throw new AndroidLocationException(sPrefsLocation +
-                            " is not a directory! This is required to run Android tools.");
-                }
-            }
-        }
-
-        return sPrefsLocation;
-    }
-
-    /**
-     * Checks a list of system properties and/or system environment variables for validity, and
-     * existing director, and returns the first one.
-     * @param names
-     * @return the content of the first property/variable.
-     */
-    private static String findValidPath(String... names) {
-        for (String name : names) {
-            String path;
-            if (name.indexOf('.') != -1) {
-                path = System.getProperty(name);
-            } else {
-                path = System.getenv(name);
-            }
-
-            if (path != null) {
-                File f = new File(path);
-                if (f.isDirectory()) {
-                    return path;
-                }
-            }
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/anttasks/.classpath b/tools/anttasks/.classpath
deleted file mode 100644
index d6ce15a..0000000
--- a/tools/anttasks/.classpath
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
-	<classpathentry kind="var" path="ANDROID_SRC/prebuilt/common/ant/ant.jar"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ApkBuilder"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/anttasks/.project b/tools/anttasks/.project
deleted file mode 100644
index aed1b61..0000000
--- a/tools/anttasks/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ant-tasks</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/anttasks/Android.mk b/tools/anttasks/Android.mk
deleted file mode 100644
index 15ee903..0000000
--- a/tools/anttasks/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-ANTTASKS_LOCAL_DIR := $(call my-dir)
-include $(ANTTASKS_LOCAL_DIR)/src/Android.mk
diff --git a/tools/anttasks/src/Android.mk b/tools/anttasks/src/Android.mk
deleted file mode 100644
index 94d6d3f..0000000
--- a/tools/anttasks/src/Android.mk
+++ /dev/null
@@ -1,29 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := \
-        sdklib \
-        apkbuilder \
-        ant
-
-LOCAL_MODULE := anttasks
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/anttasks/src/com/android/ant/AaptExecLoopTask.java b/tools/anttasks/src/com/android/ant/AaptExecLoopTask.java
deleted file mode 100644
index d2c7162..0000000
--- a/tools/anttasks/src/com/android/ant/AaptExecLoopTask.java
+++ /dev/null
@@ -1,218 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ant;
-
-import com.android.sdklib.project.ApkConfigurationHelper;
-import com.android.sdklib.project.ProjectProperties;
-import com.android.sdklib.project.ProjectProperties.PropertyType;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Project;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.taskdefs.ExecTask;
-import org.apache.tools.ant.types.Path;
-
-import java.io.File;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-/**
- * Task able to run an Exec task on aapt several times.
- * It does not follow the exec task format, instead it has its own parameters, which maps
- * directly to aapt.
- *
- */
-public final class AaptExecLoopTask extends Task {
-    
-    private String mExecutable;
-    private String mCommand;
-    private String mManifest;
-    private String mResources;
-    private String mAssets;
-    private String mAndroidJar;
-    private String mOutFolder;
-    private String mBaseName;
-
-    /**
-     * Sets the value of the "executable" attribute.
-     * @param executable the value.
-     */
-    public void setExecutable(String executable) {
-        mExecutable = executable;
-    }
-    
-    /**
-     * Sets the value of the "command" attribute.
-     * @param command the value.
-     */
-    public void setCommand(String command) {
-        mCommand = command;
-    }
-    
-    /**
-     * Sets the value of the "manifest" attribute.
-     * @param manifest the value.
-     */
-    public void setManifest(Path manifest) {
-        mManifest = manifest.toString();
-    }
-    
-    /**
-     * Sets the value of the "resources" attribute.
-     * @param resources the value.
-     */
-    public void setResources(Path resources) {
-        mResources = resources.toString();
-    }
-    
-    /**
-     * Sets the value of the "assets" attribute.
-     * @param assets the value.
-     */
-    public void setAssets(Path assets) {
-        mAssets = assets.toString();
-    }
-    
-    /**
-     * Sets the value of the "androidjar" attribute.
-     * @param androidJar the value.
-     */
-    public void setAndroidjar(Path androidJar) {
-        mAndroidJar = androidJar.toString();
-    }
-    
-    /**
-     * Sets the value of the "outfolder" attribute.
-     * @param outFolder the value.
-     */
-    public void setOutfolder(Path outFolder) {
-        mOutFolder = outFolder.toString();
-    }
-    
-    /**
-     * Sets the value of the "basename" attribute.
-     * @param baseName the value.
-     */
-    public void setBasename(String baseName) {
-        mBaseName = baseName;
-    }
-    
-    /*
-     * (non-Javadoc)
-     * 
-     * Executes the loop. Based on the values inside default.properties, this will
-     * create alternate temporary ap_ files.
-     * 
-     * @see org.apache.tools.ant.Task#execute()
-     */
-    @Override
-    public void execute() throws BuildException {
-        Project taskProject = getProject();
-        
-        // first do a full resource package
-        createPackage(null /*configName*/, null /*resourceFilter*/);
-
-        // now see if we need to create file with filtered resources.
-        // Get the project base directory.
-        File baseDir = taskProject.getBaseDir();
-        ProjectProperties properties = ProjectProperties.load(baseDir.getAbsolutePath(),
-                PropertyType.DEFAULT);
-        
-        Map<String, String> apkConfigs = ApkConfigurationHelper.getConfigs(properties);
-        if (apkConfigs.size() > 0) {
-            Set<Entry<String, String>> entrySet = apkConfigs.entrySet();
-            for (Entry<String, String> entry : entrySet) {
-                createPackage(entry.getKey(), entry.getValue());
-            }
-        }
-    }
-
-    /**
-     * Creates a resource package.
-     * @param configName the name of the filter config. Can be null in which case a full resource
-     * package will be generated.
-     * @param resourceFilter the resource configuration filter to pass to aapt (if configName is
-     * non null)
-     */
-    private void createPackage(String configName, String resourceFilter) {
-        Project taskProject = getProject();
-
-        if (configName == null || resourceFilter == null) {
-            System.out.println("Creating full resource package...");
-        } else {
-            System.out.println(String.format(
-                    "Creating resource package for config '%1$s' (%2$s)...",
-                    configName, resourceFilter));
-        }
-
-        // create a task for the default apk.
-        ExecTask task = new ExecTask();
-        task.setExecutable(mExecutable);
-        task.setFailonerror(true);
-        
-        // aapt command. Only "package" is supported at this time really.
-        task.createArg().setValue(mCommand);
-        
-        // filters if needed
-        if (configName != null && resourceFilter != null) {
-            task.createArg().setValue("-c");
-            task.createArg().setValue(resourceFilter);
-        }
-        
-        // force flag
-        task.createArg().setValue("-f");
-        
-        // manifest location
-        task.createArg().setValue("-M");
-        task.createArg().setValue(mManifest);
-
-        // resources location
-        task.createArg().setValue("-S");
-        task.createArg().setValue(mResources);
-        
-        // assets location. this may not exists, and aapt doesn't like it, so we check first.
-        File assets = new File(mAssets);
-        if (assets.isDirectory()) {
-            task.createArg().setValue("-A");
-            task.createArg().setValue(mAssets);
-        }
-        
-        // android.jar
-        task.createArg().setValue("-I");
-        task.createArg().setValue(mAndroidJar);
-        
-        // out file. This is based on the outFolder, baseName, and the configName (if applicable)
-        String filename;
-        if (configName != null && resourceFilter != null) {
-            filename = mBaseName + "-" + configName + ".ap_";
-        } else {
-            filename = mBaseName + ".ap_";
-        }
-        
-        File file = new File(mOutFolder, filename);
-        task.createArg().setValue("-F");
-        task.createArg().setValue(file.getAbsolutePath());
-        
-        // final setup of the task
-        task.setProject(taskProject);
-        task.setOwningTarget(getOwningTarget());
-        
-        // execute it.
-        task.execute();
-    }
-}
diff --git a/tools/anttasks/src/com/android/ant/ApkBuilderTask.java b/tools/anttasks/src/com/android/ant/ApkBuilderTask.java
deleted file mode 100644
index 22729ec..0000000
--- a/tools/anttasks/src/com/android/ant/ApkBuilderTask.java
+++ /dev/null
@@ -1,293 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ant;
-
-import com.android.apkbuilder.ApkBuilder;
-import com.android.apkbuilder.ApkBuilder.ApkFile;
-import com.android.sdklib.project.ApkConfigurationHelper;
-import com.android.sdklib.project.ProjectProperties;
-import com.android.sdklib.project.ProjectProperties.PropertyType;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Project;
-import org.apache.tools.ant.ProjectComponent;
-import org.apache.tools.ant.Task;
-import org.apache.tools.ant.types.Path;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-public class ApkBuilderTask extends Task {
-    
-    /**
-     * Class to represent nested elements. Since they all have only one attribute ('path'), the
-     * same class can be used for all the nested elements (zip, file, sourcefolder, jarfolder,
-     * nativefolder).
-     */
-    public final static class Value extends ProjectComponent {
-        String mPath;
-        
-        /**
-         * Sets the value of the "path" attribute.
-         * @param path the value.
-         */
-        public void setPath(Path path) {
-            mPath = path.toString();
-        }
-    }
-
-    private String mOutFolder;
-    private String mBaseName;
-    private boolean mVerbose = false;
-    private boolean mSigned = true;
-    
-    private final ArrayList<Value> mZipList = new ArrayList<Value>();
-    private final ArrayList<Value> mFileList = new ArrayList<Value>();
-    private final ArrayList<Value> mSourceList = new ArrayList<Value>();
-    private final ArrayList<Value> mJarList = new ArrayList<Value>();
-    private final ArrayList<Value> mNativeList = new ArrayList<Value>();
-
-    private final ArrayList<FileInputStream> mZipArchives = new ArrayList<FileInputStream>();
-    private final ArrayList<File> mArchiveFiles = new ArrayList<File>();
-    private final ArrayList<ApkFile> mJavaResources = new ArrayList<ApkFile>();
-    private final ArrayList<FileInputStream> mResourcesJars = new ArrayList<FileInputStream>();
-    private final ArrayList<ApkFile> mNativeLibraries = new ArrayList<ApkFile>();
-
-    /**
-     * Sets the value of the "outfolder" attribute.
-     * @param outFolder the value.
-     */
-    public void setOutfolder(Path outFolder) {
-        mOutFolder = outFolder.toString();
-    }
-    
-    /**
-     * Sets the value of the "basename" attribute.
-     * @param baseName the value.
-     */
-    public void setBasename(String baseName) {
-        mBaseName = baseName;
-    }
-    
-    /**
-     * Sets the value of the "verbose" attribute.
-     * @param verbose the value.
-     */
-    public void setVerbose(boolean verbose) {
-        mVerbose = verbose;
-    }
-    
-    /**
-     * Sets the value of the "signed" attribute.
-     * @param signed the value.
-     */
-    public void setSigned(boolean signed) {
-        mSigned = signed;
-    }
-    
-    /**
-     * Returns an object representing a nested <var>zip</var> element.
-     */
-    public Object createZip() {
-        Value zip = new Value();
-        mZipList.add(zip);
-        return zip;
-    }
-    
-    /**
-     * Returns an object representing a nested <var>file</var> element.
-     */
-    public Object createFile() {
-        Value file = new Value();
-        mFileList.add(file);
-        return file;
-    }
-
-    /**
-     * Returns an object representing a nested <var>sourcefolder</var> element.
-     */
-    public Object createSourcefolder() {
-        Value file = new Value();
-        mSourceList.add(file);
-        return file;
-    }
-
-    /**
-     * Returns an object representing a nested <var>jarfolder</var> element.
-     */
-    public Object createJarfolder() {
-        Value file = new Value();
-        mJarList.add(file);
-        return file;
-    }
-    
-    /**
-     * Returns an object representing a nested <var>nativefolder</var> element.
-     */
-    public Object createNativefolder() {
-        Value file = new Value();
-        mNativeList.add(file);
-        return file;
-    }
-    
-    @Override
-    public void execute() throws BuildException {
-        Project taskProject = getProject();
-        
-        ApkBuilder apkBuilder = new ApkBuilder();
-        apkBuilder.setVerbose(mVerbose);
-        apkBuilder.setSignedPackage(mSigned);
-        
-        try {
-            // setup the list of everything that needs to go in the archive.
-            
-            // go through the list of zip files to add. This will not include
-            // the resource package, which is handled separaly for each apk to create.
-            for (Value v : mZipList) {
-                FileInputStream input = new FileInputStream(v.mPath);
-                mZipArchives.add(input);
-            }
-            
-            // now go through the list of file to directly add the to the list.
-            for (Value v : mFileList) {
-                mArchiveFiles.add(ApkBuilder.getInputFile(v.mPath));
-            }
-            
-            // now go through the list of file to directly add the to the list.
-            for (Value v : mSourceList) {
-                ApkBuilder.processSourceFolderForResource(v.mPath, mJavaResources);
-            }
-            
-            // now go through the list of jar folders.
-            for (Value v : mJarList) {
-                ApkBuilder.processJarFolder(v.mPath, mResourcesJars);
-            }
-            
-            // now the native lib folder.
-            for (Value v : mNativeList) {
-                String parameter = v.mPath;
-                File f = new File(parameter);
-                
-                // compute the offset to get the relative path
-                int offset = parameter.length();
-                if (parameter.endsWith(File.separator) == false) {
-                    offset++;
-                }
-
-                ApkBuilder.processNativeFolder(offset, f, mNativeLibraries);
-            }
-
-            
-            // first do a full resource package
-            createApk(apkBuilder, null /*configName*/, null /*resourceFilter*/);
-    
-            // now see if we need to create file with filtered resources.
-            // Get the project base directory.
-            File baseDir = taskProject.getBaseDir();
-            ProjectProperties properties = ProjectProperties.load(baseDir.getAbsolutePath(),
-                    PropertyType.DEFAULT);
-            
-            Map<String, String> apkConfigs = ApkConfigurationHelper.getConfigs(properties);
-            if (apkConfigs.size() > 0) {
-                Set<Entry<String, String>> entrySet = apkConfigs.entrySet();
-                for (Entry<String, String> entry : entrySet) {
-                    createApk(apkBuilder, entry.getKey(), entry.getValue());
-                }
-            }
-        } catch (FileNotFoundException e) {
-            throw new BuildException(e);
-        } catch (IllegalArgumentException e) {
-            throw new BuildException(e);
-        }
-    }
-    
-    /**
-     * Creates an application package.
-     * @param apkBuilder 
-     * @param configName the name of the filter config. Can be null in which case a full resource
-     * package will be generated.
-     * @param resourceFilter the resource configuration filter to pass to aapt (if configName is
-     * non null)
-     * @throws FileNotFoundException 
-     */
-    private void createApk(ApkBuilder apkBuilder, String configName, String resourceFilter)
-            throws FileNotFoundException {
-        // All the files to be included in the archive have already been prep'ed up, except
-        // the resource package.
-        // figure out its name.
-        String filename;
-        if (configName != null && resourceFilter != null) {
-            filename = mBaseName + "-" + configName + ".ap_";
-        } else {
-            filename = mBaseName + ".ap_";
-        }
-        
-        // now we add it to the list of zip archive (it's just a zip file).
-        
-        // it's used as a zip archive input
-        FileInputStream resoucePackageZipFile = new FileInputStream(new File(mOutFolder, filename));
-        mZipArchives.add(resoucePackageZipFile);
-        
-        // prepare the filename to generate. Same thing as the resource file.
-        if (configName != null && resourceFilter != null) {
-            filename = mBaseName + "-" + configName;
-        } else {
-            filename = mBaseName;
-        }
-        
-        if (mSigned) {
-            filename = filename + "-debug.apk";
-        } else {
-            filename = filename + "-unsigned.apk";
-        }
-
-        if (configName == null || resourceFilter == null) {
-            if (mSigned) {
-                System.out.println(String.format(
-                        "Creating %s and signing it with a debug key...", filename));
-            } else {
-                System.out.println(String.format(
-                        "Creating %s for release...", filename));
-            }
-        } else {
-            if (mSigned) {
-                System.out.println(String.format(
-                        "Creating %1$s (with %2$s) and signing it with a debug key...",
-                        filename, resourceFilter));
-            } else {
-                System.out.println(String.format(
-                        "Creating %1$s (with %2$s) for release...",
-                        filename, resourceFilter));
-            }
-        }
-        
-        File f = new File(mOutFolder, filename);
-        
-        // and generate the apk
-        apkBuilder.createPackage(f.getAbsoluteFile(), mZipArchives,
-                mArchiveFiles, mJavaResources, mResourcesJars, mNativeLibraries);
-        
-        // we are done. We need to remove the resource package from the list of zip archives
-        // in case we have another apk to generate.
-        mZipArchives.remove(resoucePackageZipFile);
-    }
-}
diff --git a/tools/anttasks/src/com/android/ant/SetupTask.java b/tools/anttasks/src/com/android/ant/SetupTask.java
deleted file mode 100644
index d425a2f..0000000
--- a/tools/anttasks/src/com/android/ant/SetupTask.java
+++ /dev/null
@@ -1,208 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ant;
-
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkManager;
-import com.android.sdklib.IAndroidTarget.IOptionalLibrary;
-import com.android.sdklib.project.ProjectProperties;
-
-import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.Project;
-import org.apache.tools.ant.taskdefs.ImportTask;
-import org.apache.tools.ant.types.Path;
-import org.apache.tools.ant.types.Path.PathElement;
-
-import java.io.File;
-import java.util.ArrayList;
-import java.util.HashSet;
-
-/**
- * Setup/Import Ant task. This task accomplishes:
- * <ul>
- * <li>Gets the project target hash string from {@link ProjectProperties#PROPERTY_TARGET},
- * and resolves it to get the project's {@link IAndroidTarget}.</li>
- * <li>Sets up properties so that aapt can find the android.jar in the resolved target.</li>
- * <li>Sets up the boot classpath ref so that the <code>javac</code> task knows where to find
- * the libraries. This includes the default android.jar from the resolved target but also optional
- * libraries provided by the target (if any, when the target is an add-on).</li>
- * <li>Imports the build rules located in the resolved target so that the build actually does
- * something. This can be disabled with the attribute <var>import</var> set to <code>false</code>
- * </li></ul>
- * 
- * This is used in build.xml/template.
- *
- */
-public final class SetupTask extends ImportTask {
-    private final static String ANDROID_RULES = "android_rules.xml";
-    
-    // ant property with the path to the android.jar
-    private final static String PROPERTY_ANDROID_JAR = "android-jar";
-    // ant property with the path to the framework.jar
-    private final static String PROPERTY_ANDROID_AIDL = "android-aidl";
-    // ant property with the path to the aapt tool
-    private final static String PROPERTY_AAPT = "aapt";
-    // ant property with the path to the aidl tool
-    private final static String PROPERTY_AIDL = "aidl";
-    // ant property with the path to the dx tool
-    private final static String PROPERTY_DX = "dx";
-    // ref id to the <path> object containing all the boot classpaths.
-    private final static String REF_CLASSPATH = "android.target.classpath";
-    
-    private boolean mDoImport = true;
-
-    @Override
-    public void execute() throws BuildException {
-        Project antProject = getProject();
-        
-        // get the SDK location
-        String sdkLocation = antProject.getProperty(ProjectProperties.PROPERTY_SDK);
-        
-        // check if it's valid and exists
-        if (sdkLocation == null || sdkLocation.length() == 0) {
-            throw new BuildException("SDK Location is not set.");
-        }
-        
-        File sdk = new File(sdkLocation);
-        if (sdk.isDirectory() == false) {
-            throw new BuildException(String.format("SDK Location '%s' is not valid.", sdkLocation));
-        }
-
-        // get the target property value
-        String targetHashString = antProject.getProperty(ProjectProperties.PROPERTY_TARGET);
-        if (targetHashString == null) {
-            throw new BuildException("Android Target is not set.");
-        }
-
-        // load up the sdk targets.
-        final ArrayList<String> messages = new ArrayList<String>();
-        SdkManager manager = SdkManager.createManager(sdkLocation, new ISdkLog() {
-            public void error(Throwable t, String errorFormat, Object... args) {
-                if (errorFormat != null) {
-                    messages.add(String.format("Error: " + errorFormat, args));
-                }
-                if (t != null) {
-                    messages.add("Error: " + t.getMessage());
-                }
-            }
-
-            public void printf(String msgFormat, Object... args) {
-                messages.add(String.format(msgFormat, args));
-            }
-
-            public void warning(String warningFormat, Object... args) {
-                messages.add(String.format("Warning: " + warningFormat, args));
-            }
-        });
-
-        if (manager == null) {
-            // since we failed to parse the SDK, lets display the parsing output.
-            for (String msg : messages) {
-                System.out.println(msg);
-            }
-            throw new BuildException("Failed to parse SDK content.");
-        }
-
-        // resolve it
-        IAndroidTarget androidTarget = manager.getTargetFromHashString(targetHashString);
-        
-        if (androidTarget == null) {
-            throw new BuildException(String.format(
-                    "Unable to resolve target '%s'", targetHashString));
-        }
-        
-        // display it
-        System.out.println("Project Target: " + androidTarget.getName());
-        if (androidTarget.isPlatform() == false) {
-            System.out.println("Vendor: " + androidTarget.getVendor());
-            System.out.println("Platform Version: " + androidTarget.getApiVersionName());
-        }
-        System.out.println("API level: " + androidTarget.getApiVersionNumber());
-        
-        // sets up the properties to find android.jar/framework.aidl/target tools
-        String androidJar = androidTarget.getPath(IAndroidTarget.ANDROID_JAR);
-        antProject.setProperty(PROPERTY_ANDROID_JAR, androidJar);
-
-        antProject.setProperty(PROPERTY_ANDROID_AIDL,
-                androidTarget.getPath(IAndroidTarget.ANDROID_AIDL));
-        antProject.setProperty(PROPERTY_AAPT, androidTarget.getPath(IAndroidTarget.AAPT));
-        antProject.setProperty(PROPERTY_AIDL, androidTarget.getPath(IAndroidTarget.AIDL));
-        antProject.setProperty(PROPERTY_DX, androidTarget.getPath(IAndroidTarget.DX));
-
-        // sets up the boot classpath
-
-        // create the Path object
-        Path bootclasspath = new Path(antProject);
-
-        // create a PathElement for the framework jar
-        PathElement element = bootclasspath.createPathElement();
-        element.setPath(androidJar);
-        
-        // create PathElement for each optional library.
-        IOptionalLibrary[] libraries = androidTarget.getOptionalLibraries();
-        if (libraries != null) {
-            HashSet<String> visitedJars = new HashSet<String>();
-            for (IOptionalLibrary library : libraries) {
-                String jarPath = library.getJarPath();
-                if (visitedJars.contains(jarPath) == false) {
-                    visitedJars.add(jarPath);
-
-                    element = bootclasspath.createPathElement();
-                    element.setPath(library.getJarPath());
-                }
-            }
-        }
-        
-        // finally sets the path in the project with a reference
-        antProject.addReference(REF_CLASSPATH, bootclasspath);
-
-        // find the file to import, and import it.
-        String templateFolder = androidTarget.getPath(IAndroidTarget.TEMPLATES);
-        
-        // Now the import section. This is only executed if the task actually has to import a file.
-        if (mDoImport) {
-            // make sure the file exists.
-            File templates = new File(templateFolder);
-            if (templates.isDirectory() == false) {
-                throw new BuildException(String.format("Template directory '%s' is missing.",
-                        templateFolder));
-            }
-            
-            // now check the rules file exists.
-            File rules = new File(templateFolder, ANDROID_RULES);
-            if (rules.isFile() == false) {
-                throw new BuildException(String.format("Build rules file '%s' is missing.",
-                        templateFolder));
-           }
-            
-            // set the file location to import
-            setFile(rules.getAbsolutePath());
-            
-            // and import
-            super.execute();
-        }
-    }
-
-    /**
-     * Sets the value of the "import" attribute.
-     * @param value the value.
-     */
-    public void setImport(boolean value) {
-        mDoImport = value;
-    }
-}
diff --git a/tools/apkbuilder/.classpath b/tools/apkbuilder/.classpath
deleted file mode 100644
index f1768fc..0000000
--- a/tools/apkbuilder/.classpath
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/JarUtils"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/apkbuilder/.project b/tools/apkbuilder/.project
deleted file mode 100644
index cc97afc..0000000
--- a/tools/apkbuilder/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ApkBuilder</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/apkbuilder/Android.mk b/tools/apkbuilder/Android.mk
deleted file mode 100644
index bdfe5c8..0000000
--- a/tools/apkbuilder/Android.mk
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-APKBUILDER_LOCAL_DIR := $(call my-dir)
-include $(APKBUILDER_LOCAL_DIR)/etc/Android.mk
-include $(APKBUILDER_LOCAL_DIR)/src/Android.mk
diff --git a/tools/apkbuilder/etc/Android.mk b/tools/apkbuilder/etc/Android.mk
deleted file mode 100644
index d74db17..0000000
--- a/tools/apkbuilder/etc/Android.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := apkbuilder
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/apkbuilder/etc/apkbuilder b/tools/apkbuilder/etc/apkbuilder
deleted file mode 100755
index 3e7e822..0000000
--- a/tools/apkbuilder/etc/apkbuilder
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=apkbuilder.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-if [ debug = "$1" ]; then
-    # add this in for debugging
-    java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-else
-    java_debug=
-fi
-
-# Mac OS X needs an additional arg, or you get an "illegal thread" complaint.
-if [ `uname` = "Darwin" ]; then
-    os_opts="-XstartOnFirstThread"
-else
-    os_opts=
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Xmx128M $os_opts $java_debug -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -jar "$jarpath" "$@"
diff --git a/tools/apkbuilder/etc/apkbuilder.bat b/tools/apkbuilder/etc/apkbuilder.bat
deleted file mode 100755
index 7ab3e6c..0000000
--- a/tools/apkbuilder/etc/apkbuilder.bat
+++ /dev/null
@@ -1,43 +0,0 @@
-@echo off
-rem Copyright (C) 2007 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Change current directory to where ddms is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=apkbuilder.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-    set libdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-    set libdir=..\lib\
-
-:JarFileOk
-
-set jarpath=%frameworkdir%%jarfile%
-
-call java -Djava.ext.dirs=%frameworkdir% -Djava.library.path=%libdir% -jar %jarpath% %*
diff --git a/tools/apkbuilder/etc/manifest.txt b/tools/apkbuilder/etc/manifest.txt
deleted file mode 100644
index 6aafb16..0000000
--- a/tools/apkbuilder/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.apkbuilder.ApkBuilder
diff --git a/tools/apkbuilder/src/Android.mk b/tools/apkbuilder/src/Android.mk
deleted file mode 100644
index e403ca7..0000000
--- a/tools/apkbuilder/src/Android.mk
+++ /dev/null
@@ -1,29 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-        androidprefs \
-        jarutils
-
-LOCAL_MODULE := apkbuilder
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/apkbuilder/src/com/android/apkbuilder/ApkBuilder.java b/tools/apkbuilder/src/com/android/apkbuilder/ApkBuilder.java
deleted file mode 100644
index 40abff1..0000000
--- a/tools/apkbuilder/src/com/android/apkbuilder/ApkBuilder.java
+++ /dev/null
@@ -1,468 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.apkbuilder;
-
-import com.android.jarutils.DebugKeyProvider;
-import com.android.jarutils.JavaResourceFilter;
-import com.android.jarutils.SignedJarBuilder;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.FilenameFilter;
-import java.io.IOException;
-import java.security.PrivateKey;
-import java.security.cert.X509Certificate;
-import java.text.DateFormat;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.regex.Pattern;
-
-/**
- * Command line APK builder with signing support.
- */
-public final class ApkBuilder {
-    
-    private final static Pattern PATTERN_JAR_EXT = Pattern.compile("^.+\\.jar$",
-            Pattern.CASE_INSENSITIVE);
-    private final static Pattern PATTERN_NATIVELIB_EXT = Pattern.compile("^.+\\.so$",
-            Pattern.CASE_INSENSITIVE);
-    
-    private final static String NATIVE_LIB_ROOT = "lib/";
-
-    /**
-     * A File to be added to the APK archive.
-     * <p/>This includes the {@link File} representing the file and its path in the archive.
-     */
-    public final static class ApkFile {
-        String archivePath;
-        File file;
-
-        ApkFile(File file, String path) {
-            this.file = file;
-            this.archivePath = path;
-        }
-    }
-
-    private JavaResourceFilter mResourceFilter = new JavaResourceFilter();
-    private boolean mVerbose = false;
-    private boolean mSignedPackage = true;
-    /** the optional type of the debug keystore. If <code>null</code>, the default */
-    private String mStoreType = null;
-
-    /**
-     * @param args
-     */
-    public static void main(String[] args) {
-        new ApkBuilder().run(args);
-    }
-    
-    public void setVerbose(boolean verbose) {
-        mVerbose = verbose;
-    }
-    
-    public void setSignedPackage(boolean signedPackage) {
-        mSignedPackage = signedPackage;
-    }
-
-    private void run(String[] args) {
-        if (args.length < 1) {
-            printUsageAndQuit();
-        }
-
-        try {
-            // read the first args that should be a file path
-            File outFile = getOutFile(args[0]);
-    
-            ArrayList<FileInputStream> zipArchives = new ArrayList<FileInputStream>();
-            ArrayList<File> archiveFiles = new ArrayList<File>();
-            ArrayList<ApkFile> javaResources = new ArrayList<ApkFile>();
-            ArrayList<FileInputStream> resourcesJars = new ArrayList<FileInputStream>();
-            ArrayList<ApkFile> nativeLibraries = new ArrayList<ApkFile>();
-    
-            int index = 1;
-            do {
-                String argument = args[index++];
-    
-                if ("-v".equals(argument)) {
-                    mVerbose = true;
-                } else if ("-u".equals(argument)) {
-                    mSignedPackage = false;
-                } else if ("-z".equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-                    
-                    try {
-                        FileInputStream input = new FileInputStream(args[index++]);
-                        zipArchives.add(input);
-                    } catch (FileNotFoundException e) {
-                        printAndExit(e.getMessage());
-                    }
-                } else if ("-f". equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-    
-                    archiveFiles.add(getInputFile(args[index++]));
-                } else if ("-rf". equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-    
-                    processSourceFolderForResource(args[index++], javaResources);
-                } else if ("-rj". equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-                    
-                    processJarFolder(args[index++], resourcesJars);
-                } else if ("-nf".equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-                    
-                    String parameter = args[index++];
-                    File f = new File(parameter);
-    
-                    // compute the offset to get the relative path
-                    int offset = parameter.length();
-                    if (parameter.endsWith(File.separator) == false) {
-                        offset++;
-                    }
-    
-                    processNativeFolder(offset, f, nativeLibraries);
-                } else if ("-storetype".equals(argument)) {
-                    // quick check on the next argument.
-                    if (index == args.length) printUsageAndQuit();
-                    
-                    mStoreType  = args[index++];
-                } else {
-                    printAndExit("Unknown argument: " + argument);
-                }
-            } while (index < args.length);
-            
-            createPackage(outFile, zipArchives, archiveFiles, javaResources, resourcesJars,
-                    nativeLibraries);
-        } catch (IllegalArgumentException e) {
-            printAndExit(e.getMessage());
-        } catch (FileNotFoundException e) {
-            printAndExit(e.getMessage());
-        }
-    }
-
-
-    private File getOutFile(String filepath) {
-        File f = new File(filepath);
-        
-        if (f.isDirectory()) {
-            printAndExit(filepath + " is a directory!");
-        }
-        
-        if (f.exists()) { // will be a file in this case.
-            if (f.canWrite() == false) {
-                printAndExit("Cannot write " + filepath);
-            }
-        } else {
-            try {
-                if (f.createNewFile() == false) {
-                    printAndExit("Failed to create " + filepath);
-                }
-            } catch (IOException e) {
-                printAndExit("Failed to create '" + filepath + "' : " + e.getMessage());
-            }
-        }
-        
-        return f;
-    }
-
-    public static File getInputFile(String filepath) throws IllegalArgumentException {
-        File f = new File(filepath);
-        
-        if (f.isDirectory()) {
-            throw new IllegalArgumentException(filepath + " is a directory!");
-        }
-        
-        if (f.exists()) {
-            if (f.canRead() == false) {
-                throw new IllegalArgumentException("Cannot read " + filepath);
-            }
-        } else {
-            throw new IllegalArgumentException(filepath + " does not exists!");
-        }
-
-        return f;
-    }
-
-    /**
-     * Processes a source folder and adds its java resources to a given list of {@link ApkFile}.
-     * @param folderPath the path to the source folder.
-     * @param javaResources the list of {@link ApkFile} to fill.
-     */
-    public static void processSourceFolderForResource(String folderPath,
-            ArrayList<ApkFile> javaResources) {
-        
-        File folder = new File(folderPath);
-        
-        if (folder.isDirectory()) {
-            // file is a directory, process its content.
-            File[] files = folder.listFiles();
-            for (File file : files) {
-                processFileForResource(file, null, javaResources);
-            }
-        } else {
-            // not a directory? output error and quit.
-            if (folder.exists()) {
-                throw new IllegalArgumentException(folderPath + " is not a folder!");
-            } else {
-                throw new IllegalArgumentException(folderPath + " does not exist!");
-            }
-        }
-    }
-    
-    public static void processJarFolder(String parameter, ArrayList<FileInputStream> resourcesJars)
-            throws FileNotFoundException {
-        File f = new File(parameter);
-        if (f.isDirectory()) {
-            String[] files = f.list(new FilenameFilter() {
-                public boolean accept(File dir, String name) {
-                    return PATTERN_JAR_EXT.matcher(name).matches();
-                }
-            });
-
-            for (String file : files) {
-                String path = f.getAbsolutePath() + File.separator + file;
-                FileInputStream input = new FileInputStream(path);
-                resourcesJars.add(input);
-            }
-        } else {
-            FileInputStream input = new FileInputStream(parameter);
-            resourcesJars.add(input);
-        }
-    }
-
-    
-    /**
-     * Processes a {@link File} that could be a {@link ApkFile}, or a folder containing
-     * java resources.
-     * @param file the {@link File} to process.
-     * @param path the relative path of this file to the source folder. Can be <code>null</code> to
-     * identify a root file. 
-     * @param javaResources the list of {@link ApkFile} object to fill.
-     */
-    private static void processFileForResource(File file, String path,
-            ArrayList<ApkFile> javaResources) {
-        if (file.isDirectory()) {
-            // a directory? we check it
-            if (JavaResourceFilter.checkFolderForPackaging(file.getName())) {
-                // if it's valid, we append its name to the current path.
-                if (path == null) {
-                    path = file.getName();
-                } else {
-                    path = path + "/" + file.getName();
-                }
-
-                // and process its content.
-                File[] files = file.listFiles();
-                for (File contentFile : files) {
-                    processFileForResource(contentFile, path, javaResources);
-                }
-            }
-        } else {
-            // a file? we check it
-            if (JavaResourceFilter.checkFileForPackaging(file.getName())) {
-                // we append its name to the current path
-                if (path == null) {
-                    path = file.getName();
-                } else {
-                    path = path + "/" + file.getName();
-                }
-
-                // and add it to the list.
-                javaResources.add(new ApkFile(file, path));
-            }
-        }
-    }
-    
-    /**
-     * Process a {@link File} for native library inclusion.
-     * @param offset the length of the root folder (used to compute relative path)
-     * @param f the {@link File} to process
-     * @param nativeLibraries the array to add native libraries.
-     */
-    public static void processNativeFolder(int offset, File f, ArrayList<ApkFile> nativeLibraries) {
-        if (f.isDirectory()) {
-            File[] children = f.listFiles();
-            
-            if (children != null) {
-                for (File child : children) {
-                    processNativeFolder(offset, child, nativeLibraries);
-                }
-            }
-        } else if (f.isFile()) {
-            if (PATTERN_NATIVELIB_EXT.matcher(f.getName()).matches()) {
-                String path = NATIVE_LIB_ROOT + 
-                        f.getAbsolutePath().substring(offset).replace('\\', '/');
-                
-                nativeLibraries.add(new ApkFile(f, path));
-            }
-        }
-    }
-
-    /**
-     * Creates the application package
-     * @param outFile 
-     * @param zipArchives
-     * @param resourcesJars 
-     * @param files 
-     * @param javaResources 
-     * keystore type of the Java VM is used.
-     */
-    public void createPackage(File outFile, ArrayList<FileInputStream> zipArchives,
-            ArrayList<File> files, ArrayList<ApkFile> javaResources,
-            ArrayList<FileInputStream> resourcesJars, ArrayList<ApkFile> nativeLibraries) {
-        
-        // get the debug key
-        try {
-            SignedJarBuilder builder;
-
-            if (mSignedPackage) {
-                System.err.println(String.format("Using keystore: %s",
-                        DebugKeyProvider.getDefaultKeyStoreOsPath()));
-                
-                
-                DebugKeyProvider keyProvider = new DebugKeyProvider(
-                        null /* osKeyPath: use default */,
-                        mStoreType, null /* IKeyGenOutput */);
-                PrivateKey key = keyProvider.getDebugKey();
-                X509Certificate certificate = (X509Certificate)keyProvider.getCertificate();
-                
-                if (key == null) {
-                    throw new IllegalArgumentException("Unable to get debug signature key");
-                }
-                
-                // compare the certificate expiration date
-                if (certificate != null && certificate.getNotAfter().compareTo(new Date()) < 0) {
-                    // TODO, regenerate a new one.
-                    throw new IllegalArgumentException("Debug Certificate expired on " +
-                            DateFormat.getInstance().format(certificate.getNotAfter()));
-                }
-
-                builder = new SignedJarBuilder(
-                        new FileOutputStream(outFile.getAbsolutePath(), false /* append */), key,
-                        certificate);
-            } else {
-                builder = new SignedJarBuilder(
-                        new FileOutputStream(outFile.getAbsolutePath(), false /* append */),
-                        null /* key */, null /* certificate */);
-            }
-
-            // add the archives
-            for (FileInputStream input : zipArchives) {
-                builder.writeZip(input, null /* filter */);
-            }
-
-            // add the single files
-            for (File input : files) {
-                // always put the file at the root of the archive in this case
-                builder.writeFile(input, input.getName());
-                if (mVerbose) {
-                    System.err.println(String.format("%1$s => %2$s", input.getAbsolutePath(),
-                            input.getName()));
-                }
-            }
-            
-            // add the java resource from the source folders.
-            for (ApkFile resource : javaResources) {
-                builder.writeFile(resource.file, resource.archivePath);
-                if (mVerbose) {
-                    System.err.println(String.format("%1$s => %2$s",
-                            resource.file.getAbsolutePath(), resource.archivePath));
-                }
-            }
-
-            // add the java resource from jar files.
-            for (FileInputStream input : resourcesJars) {
-                builder.writeZip(input, mResourceFilter);
-            }
-            
-            // add the native files
-            for (ApkFile file : nativeLibraries) {
-                builder.writeFile(file.file, file.archivePath);
-                if (mVerbose) {
-                    System.err.println(String.format("%1$s => %2$s", file.file.getAbsolutePath(),
-                            file.archivePath));
-                }
-            }
-            
-            // close and sign the application package.
-            builder.close();
-        } catch (KeytoolException e) {
-            if (e.getJavaHome() == null) {
-                throw new IllegalArgumentException(e.getMessage() + 
-                        "\nJAVA_HOME seems undefined, setting it will help locating keytool automatically\n" +
-                        "You can also manually execute the following command\n:" +
-                        e.getCommandLine());
-            } else {
-                throw new IllegalArgumentException(e.getMessage() + 
-                        "\nJAVA_HOME is set to: " + e.getJavaHome() +
-                        "\nUpdate it if necessary, or manually execute the following command:\n" +
-                        e.getCommandLine());
-            }
-        } catch (AndroidLocationException e) {
-            throw new IllegalArgumentException(e);
-        } catch (Exception e) {
-            throw new IllegalArgumentException(e);
-        }
-    }
-
-    private void printUsageAndQuit() {
-        // 80 cols marker:  01234567890123456789012345678901234567890123456789012345678901234567890123456789
-        System.err.println("A command line tool to package an Android application from various sources.");
-        System.err.println("Usage: apkbuilder <out archive> [-v][-u][-storetype STORE_TYPE] [-z inputzip]");
-        System.err.println("            [-f inputfile] [-rf input-folder] [-rj -input-path]");
-        System.err.println("");
-        System.err.println("    -v      Verbose.");
-        System.err.println("    -u      Creates an unsigned package.");
-        System.err.println("    -storetype Forces the KeyStore type. If ommited the default is used.");
-        System.err.println("");
-        System.err.println("    -z      Followed by the path to a zip archive.");
-        System.err.println("            Adds the content of the application package.");
-        System.err.println("");
-        System.err.println("    -f      Followed by the path to a file.");
-        System.err.println("            Adds the file to the application package.");
-        System.err.println("");
-        System.err.println("    -rf     Followed by the path to a source folder.");
-        System.err.println("            Adds the java resources found in that folder to the application");
-        System.err.println("            package, while keeping their path relative to the source folder.");
-        System.err.println("");
-        System.err.println("    -rj     Followed by the path to a jar file or a folder containing");
-        System.err.println("            jar files.");
-        System.err.println("            Adds the java resources found in the jar file(s) to the application");
-        System.err.println("            package.");
-        System.err.println("");
-        System.err.println("    -nf     Followed by the root folder containing native libraries to");
-        System.err.println("            include in the application package.");
-        
-        System.exit(1);
-    }
-    
-    private void printAndExit(String... messages) {
-        for (String message : messages) {
-            System.err.println(message);
-        }
-        System.exit(1);
-    }
-}
diff --git a/tools/axl/README.txt b/tools/axl/README.txt
deleted file mode 100644
index 36f6811..0000000
--- a/tools/axl/README.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-TCP and HTTP tests
-
-axl: hostile web server.
diff --git a/tools/axl/axl.py b/tools/axl/axl.py
deleted file mode 100755
index f7b5410..0000000
--- a/tools/axl/axl.py
+++ /dev/null
@@ -1,253 +0,0 @@
-#!/usr/bin/env python
-
-#
-# Copyright 2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""
-  axl.py: HTTP Client torture tester
-
-"""
-
-import sys, time
-
-from twisted.internet import protocol, reactor, defer
-from twisted.internet.protocol import ServerFactory, Protocol
-
-import singletonmixin, log
-
-class BaseProtocol(Protocol):
-    def __init__(self):
-        self.log = log.Log.getInstance()
-
-    def write(self, data):
-        self.log("BaseProtocol.write()", len(data), data)
-        return self.transport.write(data)
-
-    def dataReceived(self, data):
-        self.log("BaseProtocol.dataReceived()", len(data), data)
-
-    def connectionMade(self):
-        self.log("BaseProtocol.connectionMade()")
-        self.transport.setTcpNoDelay(1)	# send immediately
-
-    def connectionLost(self, reason):
-        self.log("BaseProtocol.connectionLost():", reason)
-
-    def sendResponse(self, response):
-        self.write("HTTP/1.1 200 OK\r\n")
-        self.write("Content-Length: %d\r\n\r\n" % len(response))
-        if len(response) > 0:
-            self.write(response)
-
-
-# Tests
-# 8000: test driven by resource request
-
-class Drop(BaseProtocol):
-    """Drops connection immediately after connect"""
-    PORT = 8001
-    def connectionMade(self):
-        BaseProtocol.connectionMade(self)
-        self.transport.loseConnection()
-
-class ReadAndDrop(BaseProtocol):
-    """Read 1st line of request, then drop connection"""
-    PORT = 8002
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.transport.loseConnection()
-
-class GarbageStatus(BaseProtocol):
-    """Send garbage statusline"""
-    PORT = 8003
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("welcome to the jungle baby\r\n")
-
-class BadHeader(BaseProtocol):
-    """Drop connection after a header is half-sent"""
-    PORT = 8004
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 200 OK\r\n")
-        self.write("Cache-Contr")
-        time.sleep(1)
-        self.transport.loseConnection()
-
-class PauseHeader(BaseProtocol):
-    """Pause for a second in middle of a header"""
-    PORT = 8005
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 200 OK\r\n")
-        self.write("Cache-Contr")
-        time.sleep(1)
-        self.write("ol: private\r\n\r\nwe've got fun and games")
-        time.sleep(1)
-        self.transport.loseConnection()
-
-class Redirect(BaseProtocol):
-    PORT = 8006
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 302 Moved Temporarily\r\n")
-        self.write("Content-Length: 0\r\n")
-        self.write("Location: http://shopping.yahoo.com/p:Canon PowerShot SD630 Digital Camera:1993588104;_ylc=X3oDMTFhZXNmcjFjBF9TAzI3MTYxNDkEc2VjA2ZwLXB1bHNlBHNsawNyc3NfcHVsc2U0LmluYw--\r\n\r\n")
-        self.transport.loseConnection()
-
-class DataDrop(BaseProtocol):
-    """Drop connection in body"""
-    PORT = 8007
-    def dataReceived(self, data):
-        if data.find("favico") >= 0:
-            self.write("HTTP/1.1 404 Not Found\r\n\r\n")
-            self.transport.loseConnection()
-            return
-
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 200 OK\r\n")
-#        self.write("Content-Length: 100\r\n\r\n")
-        self.write("\r\n")
-#        self.write("Data cuts off < 100 here!")
-#        time.sleep(4)
-        self.transport.loseConnection()
-
-class DropOnce(BaseProtocol):
-    """Drop every other connection"""
-    PORT = 8008
-    COUNT = 0
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 200 OK\r\n")
-        self.write("Content-Length: 5\r\n\r\n")
-
-        if (not(DropOnce.COUNT & 1)):
-            self.write("HE")
-        else:
-            self.write("HELLO")
-        self.transport.loseConnection()
-
-        DropOnce.COUNT += 1
-
-class NoCR(BaseProtocol):
-    """Send headers without carriage returns"""
-    PORT = 8009
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 200 OK\n")
-        self.write("Content-Length: 5\n\n")
-
-        self.write("HELLO")
-        self.transport.loseConnection()
-
-class PipeDrop(BaseProtocol):
-    PORT = 8010
-    COUNT = 0
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        if not PipeDrop.COUNT % 3:
-            self.write("HTTP/1.1 200 OK\n")
-            self.write("Content-Length: 943\n\n")
-
-            self.write(open("./stfu.jpg").read())
-            PipeDrop.COUNT += 1
-
-        else:
-            self.transport.loseConnection()
-            PipeDrop.COUNT += 1
-
-class RedirectLoop(BaseProtocol):
-    """Redirect back to same resource"""
-    PORT = 8011
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.write("HTTP/1.1 302 Moved Temporarily\r\n")
-        self.write("Content-Length: 0\r\n")
-        self.write("Location: http://localhost:8011/\r\n")
-        self.write("\r\n")
-        self.transport.loseConnection()
-
-class ReadAll(BaseProtocol):
-    """Read entire request"""
-    PORT = 8012
-
-    def connectionMade(self):
-        self.count = 0
-
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        self.count += len(data)
-        if self.count == 190890:
-            self.transport.loseConnection()
-
-class Timeout(BaseProtocol):
-    """Timout sending body"""
-    PORT = 8013
-
-    def connectionMade(self):
-        self.count = 0
-
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        if self.count == 0: self.write("HTTP/1.1 200 OK\r\n\r\n")
-        self.count += 1
-
-class SlowResponse(BaseProtocol):
-    """Ensure client does not time out on slow writes"""
-    PORT = 8014
-
-    def connectionMade(self):
-        self.count = 0
-
-    def dataReceived(self, data):
-        BaseProtocol.dataReceived(self, data)
-        if self.count == 0: self.write("HTTP/1.1 200 OK\r\n\r\n")
-        self.sendPack(0)
-
-    def sendPack(self, count):
-        if count > 10:
-            self.transport.loseConnection()
-
-        self.write("all work and no play makes jack a dull boy %s\n" % count)
-        d = defer.Deferred()
-        d.addCallback(self.sendPack)
-        reactor.callLater(15, d.callback, count + 1)
-
-
-# HTTP/1.1 200 OK
-# Cache-Control: private
-# Content-Type: text/html
-# Set-Cookie: PREF=ID=10644de62c423aa5:TM=1155044293:LM=1155044293:S=0lHtymefQRs2j7nD; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; domain=.google.com
-# Server: GWS/2.1
-# Transfer-Encoding: chunked
-# Date: Tue, 08 Aug 2006 13:38:13 GMT
-
-def main():
-    # Initialize log
-    log.Log.getInstance(sys.stdout)
-
-    for protocol in Drop, ReadAndDrop, GarbageStatus, BadHeader, PauseHeader, \
-            Redirect, DataDrop, DropOnce, NoCR, PipeDrop, RedirectLoop, ReadAll, \
-            Timeout, SlowResponse:
-        factory = ServerFactory()
-        factory.protocol = protocol
-        reactor.listenTCP(protocol.PORT, factory)
-
-
-    reactor.run()
-
-if __name__ == '__main__':
-    main()
diff --git a/tools/axl/chewie.py b/tools/axl/chewie.py
deleted file mode 100755
index 7ed2ba6..0000000
--- a/tools/axl/chewie.py
+++ /dev/null
@@ -1,184 +0,0 @@
-#!/usr/bin/env python
-
-##
-## chewie.py
-## chews browser http log.  draws graph of connections
-## Be sure there is only one pageload in the log.
-##
-## you'll want to
-##   sudo apt-get install python-matplotlib
-## before running this
-##
-
-import sys, pylab
-
-# can't just use a dict, because there can be dups
-class Queue:
-    def __init__(self):
-        self.queue = []
-
-    def add(self, url, time):
-        self.queue.append([url, time])
-
-    def get(self, url):
-        for x in range(len(self.queue)):
-            rec = self.queue[x]
-            if rec[0] == url:
-                del self.queue[x]
-                return rec[1]
-
-## pull out request lag -- queue to start to done
-def lag():
-
-    font = {'color': '#909090', 'fontsize': 6}
-    extractMe = {
-        'RequestQueue.queueRequest': "Q",
-        'Connection.openHttpConnection()': "O",
-        'Request.sendRequest()': "S",
-        'Request.requestSent()': "T",
-        'processRequests()': 'R',
-        'Request.readResponse():': "D",         # done
-        'clearPipe()': 'U',	                    # unqueue
-        'Request.readResponse()': 'B',          # read data block
-        'Request.readResponseStatus():': 'HR',  # read http response line
-        'hdr': 'H',                             # http header
-        }
-    keys = extractMe.keys()
-
-    f = open(sys.argv[1], "r")
-
-    t0 = None
-
-    # thread, queued, opened, send, sent, reading, read, uri, server, y
-    # 0       1       2       3     4     5        6     7    8       9
-    vals = []
-
-    queued = Queue()
-    opened = {"http0": None,
-              "http1": None,
-              "http2": None,
-              "http3": None,
-              "http4": None,
-              "http5": None}
-    active = {"http0": [],
-              "http1": [],
-              "http2": [],
-              "http3": [],
-              "http4": [],
-              "http5": []}
-    connectionCount = 0
-    byteCount = 0
-    killed = [[], []]
-
-    while (True):
-        line = f.readline()
-        if len(line) == 0: break
-
-        splitup = line.split()
-
-        # http only
-        if splitup[0] != "V/http": continue
-
-        x = splitup[3:]
-
-        # filter to named lines
-        if x[2] not in keys: continue
-        x[2] = extractMe[x[2]]
-
-        # normalize time
-        if t0 == None: t0 = int(x[0])
-        x[0] = int(x[0]) - t0
-
-        thread, action = x[1], x[2]
-        if action == "Q":
-            time, url = x[0], x[3]
-            queued.add(url, time)
-        elif action == "O":
-            # save opened time and server for this thread, so we can stuff it in l8r
-            time, thread, host = x[0], x[1], x[4]
-            opened[thread] = [time, host, connectionCount]
-            connectionCount += 1
-        elif action == "S":
-            time, thread, url = x[0], x[1], x[3]
-            opentime, host, connection = opened[thread]
-            qtime = queued.get(url)
-            record = [thread, qtime, opentime, time, None, None, None, url, host, connection]
-            active[thread].append(record)
-        elif action == "T":
-            time, thread = x[0], x[1]
-            record = active[thread][-1]
-            record[4] = time
-        elif action == "R":
-            print x
-            if x[3] in ["sleep", "no", "wait"]: continue
-            time, thread, = x[0], x[1]
-            record = active[thread][0]
-            record[5] = time
-        elif action == 'U':
-            thread = x[1]
-            record = active[thread][0]
-            killed[0].append(record[9])
-            killed[1].append(x[0])
-            queued.add(record[7], record[1])
-            del active[thread][0]
-        elif action == "D":
-            time, thread = x[0], x[1]
-            record = active[thread][0]
-            record[6] = time
-            vals.append(record)
-            del active[thread][0]
-            print record
-            # print record[3] / 1000, record[6] / 1000, record[7]
-        elif action == "B":
-            byteCount += int(x[3])
-        elif action == "HR":
-            byteCount += int(x[2])
-
-    f.close()
-
-    rng = range(connectionCount)
-
-    opened = []
-    drawn = [False for x in rng]
-    for val in vals:
-        y= val[9]
-        if not drawn[y]:
-            drawn[y] = True
-            opened.append(val[2])
-            pylab.text(0, y - 0.25, "%s %s %s" % (val[9], val[0][4], val[8]), font)
-
-    # define limits
-    # pylab.plot([vals[-1][6]], rng)
-
-    print opened, rng
-    pylab.plot(opened, rng, 'ro')
-    pylab.plot(killed[1], killed[0], 'rx')
-
-    for val in vals:
-        thread, queued, opened, send, sent, reading, read, uri, server, y = val
-        # send arrow
-        arrow = pylab.Arrow(send, y, sent - send, 0)
-        arrow.set_facecolor("g")
-        ax = pylab.gca()
-        ax.add_patch(arrow)
-        # read arrow
-        arrow = pylab.Arrow(reading, y, read - reading, 0)
-        arrow.set_facecolor("r")
-        ax = pylab.gca()
-        ax.add_patch(arrow)
-
-    caption = \
-            "\nrequests: %s\n" % len(vals) + \
-            "byteCount: %s\n" % byteCount + \
-            "data rate: %s\n" % (1000 * byteCount / vals[-1][6])+ \
-            "connections: %s\n" % connectionCount
-
-    pylab.figtext(0.82, 0.30, caption, bbox=dict(facecolor='lightgrey', alpha=0.5))
-
-    # print lines, [[x, x] for x in range(len(vals))]
-    # pylab.plot(lines, [[x, x] for x in range(len(vals))], 'r-')
-
-    pylab.grid()
-    pylab.show()
-
-if __name__ == '__main__': lag()
diff --git a/tools/axl/chewperf.py b/tools/axl/chewperf.py
deleted file mode 100755
index 582bdb5..0000000
--- a/tools/axl/chewperf.py
+++ /dev/null
@@ -1,87 +0,0 @@
-#!/usr/bin/env python
-
-"""
-  chewperf.py: Chew an http perf log
-  bucketize
-
-"""
-
-import sys, time
-
-def resets():
-    f = open(sys.argv[1]).read()
-    rawLines = f.split('\n')
-
-    times = []
-    for x in range(len(rawLines)):
-        line = rawLines[x].split()
-        try:
-            if line[-1] == "SIGNAL_STRENGTH":
-                ts = int(rawLines[x - 1].split()[-1])
-                times.append(ts)
-        except:
-            pass
-
-    return times
-
-def augment():
-    f = open(sys.argv[1]).read()
-    rawLines = f.split('\r\n')
-
-    out = []
-    t0 = None
-    last = 0
-    for line in rawLines:
-        if "Pulled" in line:
-            chewed = [int(line.split()[5]), int(line.split()[7])]
-            if not t0: t0 = chewed[1]
-            tm = chewed[1] - t0
-            out.append("%s %d" % (line, (tm - last)))
-            last = tm
-        else:
-            out.append(line)
-    print "\n".join(out)
-
-def chew():
-    f = open(sys.argv[1]).read()
-    rawLines = f.split('\n')
-    lines = [x for x in rawLines if "Pulled" in x]
-
-    sidx = lines[0].split().index("Pulled")
-    print "sidx", sidx
-    chewed = [[int(x.split()[sidx + 2]), int(x.split()[sidx + 4])] for x in lines]
-
-    t0 = chewed[0][1]
-    tLast = chewed[-1][1]
-    chewed = [[x[1] - t0, x[0]] for x in chewed]
-
-    totalTime = tLast - t0
-    bytes = sum(x[1] for x in chewed)
-    print "total time", totalTime, "bytes", bytes, "rate", bytes * 1000 / totalTime
-
-    buckets = {}
-    for x in chewed:
-        bucket = x[0] / 1000
-        bytes = x[1]
-        if bucket in buckets:
-            buckets[bucket] += bytes
-        else:
-            buckets[bucket] = bytes
-
-    top = max(buckets.keys())
-    for x in range(top):
-        if x not in buckets.keys():
-            buckets[x] = 0
-
-    # smooth
-    window = [0 for x in range(5)]
-
-    for x in range(len(buckets.items())):
-        window[x % len(window)] = buckets.items()[x][1]
-        print "%s\t%s" % (buckets.items()[x][0], sum(window) / len(window))
-
-def main():
-    chew()
-
-if __name__ == '__main__':
-    main()
diff --git a/tools/axl/log.py b/tools/axl/log.py
deleted file mode 100644
index 7543270..0000000
--- a/tools/axl/log.py
+++ /dev/null
@@ -1,55 +0,0 @@
-#!/usr/bin/env python
-
-#
-# Copyright 2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License"); 
-# you may not use this file except in compliance with the License. 
-# You may obtain a copy of the License at 
-#
-#     http://www.apache.org/licenses/LICENSE-2.0 
-#
-# Unless required by applicable law or agreed to in writing, software 
-# distributed under the License is distributed on an "AS IS" BASIS, 
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
-# See the License for the specific language governing permissions and 
-# limitations under the License.
-#
-
-import time, sys
-import singletonmixin
-
-class Log(singletonmixin.Singleton):
-
-    def __init__(self, file):
-        """_file: filename or open file"""
-
-        if type(file) is str:
-            self._file = open(file, "a")
-        else:
-            self._file = file
-
-    def _getTime(self):
-        tm = time.time()
-        return "%s:%.2d" % (time.strftime('%m/%d/%Y %H:%M:%S',
-                                          time.localtime(tm)),
-                            int((tm - int(tm)) * 100))
-
-    def _log(self, *logstrs):
-        timeStr = self._getTime()
-        for ln in " ".join(map(str, logstrs)).split("\n"):
-            self._file.write("%s %s\n" % (timeStr, ln))
-        self._file.flush()
-
-    def debug(self, *logstrs):
-        self._log("D", *logstrs)
-    def info(self, *logstrs):
-        self._log("I", *logstrs)
-    def warn(self, *logstrs):
-        self._log("W", *logstrs)
-    def error(self, *logstrs):
-        self._log("E", *logstrs)
-
-    # default to info
-    log = info
-    __call__ = log
diff --git a/tools/axl/random.dat b/tools/axl/random.dat
deleted file mode 100644
index 48c5d48..0000000
--- a/tools/axl/random.dat
+++ /dev/null
Binary files differ
diff --git a/tools/axl/singletonmixin.py b/tools/axl/singletonmixin.py
deleted file mode 100644
index 7935d6d..0000000
--- a/tools/axl/singletonmixin.py
+++ /dev/null
@@ -1,220 +0,0 @@
-"""
-A Python Singleton mixin class that makes use of some of the ideas
-found at http://c2.com/cgi/wiki?PythonSingleton. Just inherit
-from it and you have a singleton. No code is required in
-subclasses to create singleton behavior -- inheritance from 
-Singleton is all that is needed.
-
-Assume S is a class that inherits from Singleton. Useful behaviors
-are:
-
-1) Getting the singleton:
-
-    S.getInstance() 
-    
-returns the instance of S. If none exists, it is created. 
-
-2) The usual idiom to construct an instance by calling the class, i.e.
-
-    S()
-    
-is disabled for the sake of clarity. If it were allowed, a programmer
-who didn't happen  notice the inheritance from Singleton might think he
-was creating a new instance. So it is felt that it is better to
-make that clearer by requiring the call of a class method that is defined in
-Singleton. An attempt to instantiate via S() will restult in an SingletonException
-being raised.
-
-3) If S.__init__(.) requires parameters, include them in the
-first call to S.getInstance(.). If subsequent calls have parameters,
-a SingletonException is raised.
-
-4) As an implementation detail, classes that inherit 
-from Singleton may not have their own __new__
-methods. To make sure this requirement is followed, 
-an exception is raised if a Singleton subclass includ
-es __new__. This happens at subclass instantiation
-time (by means of the MetaSingleton metaclass.
-
-By Gary Robinson, grobinson@transpose.com. No rights reserved -- 
-placed in the public domain -- which is only reasonable considering
-how much it owes to other people's version which are in the
-public domain. The idea of using a metaclass came from 
-a  comment on Gary's blog (see 
-http://www.garyrobinson.net/2004/03/python_singleto.html#comments). 
-Not guaranteed to be fit for any particular purpose. 
-"""
-
-class SingletonException(Exception):
-    pass
-
-class MetaSingleton(type):
-    def __new__(metaclass, strName, tupBases, dict):
-        if '__new__' in dict:
-            raise SingletonException, 'Can not override __new__ in a Singleton'
-        return super(MetaSingleton,metaclass).__new__(metaclass, strName, tupBases, dict)
-        
-    def __call__(cls, *lstArgs, **dictArgs):
-        raise SingletonException, 'Singletons may only be instantiated through getInstance()'
-        
-class Singleton(object):
-    __metaclass__ = MetaSingleton
-    
-    def getInstance(cls, *lstArgs):
-        """
-        Call this to instantiate an instance or retrieve the existing instance.
-        If the singleton requires args to be instantiated, include them the first
-        time you call getInstance.        
-        """
-        if cls._isInstantiated():
-            if len(lstArgs) != 0:
-                raise SingletonException, 'If no supplied args, singleton must already be instantiated, or __init__ must require no args'
-        else:
-            if len(lstArgs) != cls._getConstructionArgCountNotCountingSelf():
-                raise SingletonException, 'If the singleton requires __init__ args, supply them on first instantiation'
-            instance = cls.__new__(cls)
-            instance.__init__(*lstArgs)
-            cls.cInstance = instance
-        return cls.cInstance
-    getInstance = classmethod(getInstance)
-    
-    def _isInstantiated(cls):
-        return hasattr(cls, 'cInstance')
-    _isInstantiated = classmethod(_isInstantiated)
-
-    def _getConstructionArgCountNotCountingSelf(cls):
-        return cls.__init__.im_func.func_code.co_argcount - 1
-    _getConstructionArgCountNotCountingSelf = classmethod(_getConstructionArgCountNotCountingSelf)
-
-    def _forgetClassInstanceReferenceForTesting(cls):
-        """
-        This is designed for convenience in testing -- sometimes you 
-        want to get rid of a singleton during test code to see what
-        happens when you call getInstance() under a new situation.
-        
-        To really delete the object, all external references to it
-        also need to be deleted.
-        """
-        try:
-            delattr(cls,'cInstance')
-        except AttributeError:
-            # run up the chain of base classes until we find the one that has the instance
-            # and then delete it there
-            for baseClass in cls.__bases__: 
-                if issubclass(baseClass, Singleton):
-                    baseClass._forgetClassInstanceReferenceForTesting()
-    _forgetClassInstanceReferenceForTesting = classmethod(_forgetClassInstanceReferenceForTesting)
-
-
-if __name__ == '__main__':
-    import unittest
-    
-    class PublicInterfaceTest(unittest.TestCase):
-        def testReturnsSameObject(self):
-            """
-            Demonstrates normal use -- just call getInstance and it returns a singleton instance
-            """
-        
-            class A(Singleton): 
-                def __init__(self):
-                    super(A, self).__init__()
-                    
-            a1 = A.getInstance()
-            a2 = A.getInstance()
-            self.assertEquals(id(a1), id(a2))
-            
-        def testInstantiateWithMultiArgConstructor(self):
-            """
-            If the singleton needs args to construct, include them in the first
-            call to get instances.
-            """
-                    
-            class B(Singleton): 
-                    
-                def __init__(self, arg1, arg2):
-                    super(B, self).__init__()
-                    self.arg1 = arg1
-                    self.arg2 = arg2
-
-            b1 = B.getInstance('arg1 value', 'arg2 value')
-            b2 = B.getInstance()
-            self.assertEquals(b1.arg1, 'arg1 value')
-            self.assertEquals(b1.arg2, 'arg2 value')
-            self.assertEquals(id(b1), id(b2))
-            
-            
-        def testTryToInstantiateWithoutNeededArgs(self):
-            
-            class B(Singleton): 
-                    
-                def __init__(self, arg1, arg2):
-                    super(B, self).__init__()
-                    self.arg1 = arg1
-                    self.arg2 = arg2
-
-            self.assertRaises(SingletonException, B.getInstance)
-            
-        def testTryToInstantiateWithoutGetInstance(self):
-            """
-            Demonstrates that singletons can ONLY be instantiated through
-            getInstance, as long as they call Singleton.__init__ during construction.
-            
-            If this check is not required, you don't need to call Singleton.__init__().
-            """
-
-            class A(Singleton): 
-                def __init__(self):
-                    super(A, self).__init__()
-                    
-            self.assertRaises(SingletonException, A)
-            
-        def testDontAllowNew(self):
-        
-            def instantiatedAnIllegalClass():
-                class A(Singleton): 
-                    def __init__(self):
-                        super(A, self).__init__()
-                        
-                    def __new__(metaclass, strName, tupBases, dict):
-                        return super(MetaSingleton,metaclass).__new__(metaclass, strName, tupBases, dict)
-                                        
-            self.assertRaises(SingletonException, instantiatedAnIllegalClass)
-        
-        
-        def testDontAllowArgsAfterConstruction(self):
-            class B(Singleton): 
-                    
-                def __init__(self, arg1, arg2):
-                    super(B, self).__init__()
-                    self.arg1 = arg1
-                    self.arg2 = arg2
-
-            b1 = B.getInstance('arg1 value', 'arg2 value')
-            self.assertRaises(SingletonException, B, 'arg1 value', 'arg2 value')
-            
-        def test_forgetClassInstanceReferenceForTesting(self):
-            class A(Singleton): 
-                def __init__(self):
-                    super(A, self).__init__()
-            class B(A): 
-                def __init__(self):
-                    super(B, self).__init__()
-                    
-            # check that changing the class after forgetting the instance produces
-            # an instance of the new class
-            a = A.getInstance()
-            assert a.__class__.__name__ == 'A'
-            A._forgetClassInstanceReferenceForTesting()
-            b = B.getInstance()
-            assert b.__class__.__name__ == 'B'
-            
-            # check that invoking the 'forget' on a subclass still deletes the instance
-            B._forgetClassInstanceReferenceForTesting()
-            a = A.getInstance()
-            B._forgetClassInstanceReferenceForTesting()
-            b = B.getInstance()
-            assert b.__class__.__name__ == 'B'
-
-    unittest.main()
-
-    
diff --git a/tools/axl/stfu.jpg b/tools/axl/stfu.jpg
deleted file mode 100644
index 2cf38a5..0000000
--- a/tools/axl/stfu.jpg
+++ /dev/null
Binary files differ
diff --git a/tools/axl/udpEater.py b/tools/axl/udpEater.py
deleted file mode 100755
index 1440aad..0000000
--- a/tools/axl/udpEater.py
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/bin/env python
-
-#
-# Copyright 2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""
-  udpEater.py: receives UDP traffic
-
-"""
-
-import time, socket, string
-
-def main():
-    port = 9001
-
-    svrsocket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
-    svrsocket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
-    svrsocket.bind(('', port))
-
-    hostname = socket.gethostname()
-    ip = socket.gethostbyname(hostname)
-    print 'Server is at IP adress: ', ip
-    print 'Listening for requests on port %s ...' % port
-
-    count = 0
-    while count < 400:
-        data, address = svrsocket.recvfrom(8192)
-        print 'Received packet', count, data[:34]
-        count += 1
-
-if __name__ == "__main__":
-    main()
diff --git a/tools/axl/udpServer.py b/tools/axl/udpServer.py
deleted file mode 100755
index fc37ab8..0000000
--- a/tools/axl/udpServer.py
+++ /dev/null
@@ -1,29 +0,0 @@
-# UDP server example
-import time, socket, string
-
-def main():
-
-    port = 9001
-    buf = open("random.dat").read()
-
-    svrsocket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
-    svrsocket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
-    svrsocket.bind(('', port))
-
-    # hostname = socket.gethostname()
-    hostname = "localhost"
-    ip = socket.gethostbyname(hostname)
-    print 'Server is at IP adress: ', ip
-    print 'Listening for requests on port %s ...' % port
-
-    data, address = svrsocket.recvfrom(8192)
-
-    count = 0
-    while count < 500:
-        print 'Sending packet', count, 'to', address[0]
-        svrsocket.sendto("%3.3s%s" % (count, buf), address)
-        time.sleep(0.08)
-        count += 1
-        
-if __name__ == "__main__":
-    main()
diff --git a/tools/ddms/Android.mk b/tools/ddms/Android.mk
deleted file mode 100644
index 82c248e..0000000
--- a/tools/ddms/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DDMS_LOCAL_DIR := $(call my-dir)
-include $(DDMS_LOCAL_DIR)/libs/Android.mk
-include $(DDMS_LOCAL_DIR)/app/Android.mk
diff --git a/tools/ddms/MODULE_LICENSE_APACHE2 b/tools/ddms/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/tools/ddms/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/tools/ddms/app/.classpath b/tools/ddms/app/.classpath
deleted file mode 100644
index 2fa1fb7..0000000
--- a/tools/ddms/app/.classpath
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry excluding="Makefile|resources/" kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_SWT"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmlib"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmuilib"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkStatsService"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/ddms/app/.project b/tools/ddms/app/.project
deleted file mode 100644
index ffb19d7..0000000
--- a/tools/ddms/app/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ddms</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/ddms/app/Android.mk b/tools/ddms/app/Android.mk
deleted file mode 100644
index 3857706..0000000
--- a/tools/ddms/app/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DDMSAPP_LOCAL_DIR := $(call my-dir)
-include $(DDMSAPP_LOCAL_DIR)/etc/Android.mk
-include $(DDMSAPP_LOCAL_DIR)/src/Android.mk
diff --git a/tools/ddms/app/README b/tools/ddms/app/README
deleted file mode 100644
index cc55ddd..0000000
--- a/tools/ddms/app/README
+++ /dev/null
@@ -1,11 +0,0 @@
-Using the Eclipse projects for ddms.
-
-ddms requires SWT to compile.
-
-SWT is available in the depot under //device/prebuild/<platform>/swt
-
-Because the build path cannot contain relative path that are not inside the project directory,
-the .classpath file references a user library called ANDROID_SWT.
-
-In order to compile the project, make a user library called ANDROID_SWT containing the jar
-available at //device/prebuild/<platform>/swt.
\ No newline at end of file
diff --git a/tools/ddms/app/etc/Android.mk b/tools/ddms/app/etc/Android.mk
deleted file mode 100644
index 9d69971..0000000
--- a/tools/ddms/app/etc/Android.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := ddms
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/ddms/app/etc/ddms b/tools/ddms/app/etc/ddms
deleted file mode 100755
index d809cfc..0000000
--- a/tools/ddms/app/etc/ddms
+++ /dev/null
@@ -1,84 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=ddms.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-if [ debug = "$1" ]; then
-    # add this in for debugging
-    java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-else
-    java_debug=
-fi
-
-# Mac OS X needs an additional arg, or you get an "illegal thread" complaint.
-if [ `uname` = "Darwin" ]; then
-    os_opts="-XstartOnFirstThread"
-    #because Java 1.6 is 64 bits only and SWT doesn't support this, we force the usage of java 1.5
-    java_cmd="/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Commands/java"
-else
-    os_opts=
-    java_cmd="java"
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec "$java_cmd" -Xmx256M $os_opts $java_debug -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -Dcom.android.ddms.bindir="$progdir" -jar "$jarpath" "$@"
diff --git a/tools/ddms/app/etc/ddms.bat b/tools/ddms/app/etc/ddms.bat
deleted file mode 100755
index 8d941b9..0000000
--- a/tools/ddms/app/etc/ddms.bat
+++ /dev/null
@@ -1,48 +0,0 @@
-@echo off
-rem Copyright (C) 2007 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Change current directory to where ddms is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=ddms.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-    set libdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-    set libdir=..\lib\
-
-:JarFileOk
-
-if debug NEQ "%1" goto NoDebug
-    set java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-:NoDebug
-
-set jarpath=%frameworkdir%%jarfile%
-
-call java %java_debug% -Djava.ext.dirs=%frameworkdir% -Djava.library.path=%libdir% -Dcom.android.ddms.bindir= -jar %jarpath% %*
diff --git a/tools/ddms/app/etc/manifest.txt b/tools/ddms/app/etc/manifest.txt
deleted file mode 100644
index 84c8acd..0000000
--- a/tools/ddms/app/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.ddms.Main
diff --git a/tools/ddms/app/src/Android.mk b/tools/ddms/app/src/Android.mk
deleted file mode 100644
index a013fa6..0000000
--- a/tools/ddms/app/src/Android.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	androidprefs \
-	sdkstats \
-	ddmlib \
-	ddmuilib \
-	swt \
-	org.eclipse.jface_3.2.0.I20060605-1400 \
-	org.eclipse.equinox.common_3.2.0.v20060603 \
-	org.eclipse.core.commands_3.2.0.I20060605-1400
-LOCAL_MODULE := ddms
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/ddms/app/src/com/android/ddms/AboutDialog.java b/tools/ddms/app/src/com/android/ddms/AboutDialog.java
deleted file mode 100644
index 2910e5e..0000000
--- a/tools/ddms/app/src/com/android/ddms/AboutDialog.java
+++ /dev/null
@@ -1,153 +0,0 @@
-/* //device/tools/ddms/src/com/android/ddms/AboutDialog.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddms;
-
-import com.android.ddmlib.Log;
-import com.android.ddmuilib.ImageHelper;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.InputStream;
-
-/**
- * Our "about" box.
- */
-public class AboutDialog extends Dialog {
-
-    private Image logoImage;
-
-    /**
-     * Create with default style.
-     */
-    public AboutDialog(Shell parent) {
-        this(parent, SWT.DIALOG_TRIM | SWT.APPLICATION_MODAL);
-    }
-
-    /**
-     * Create with app-defined style.
-     */
-    public AboutDialog(Shell parent, int style) {
-        super(parent, style);
-    }
-
-    /**
-     * Prepare and display the dialog.
-     */
-    public void open() {
-        Shell parent = getParent();
-        Shell shell = new Shell(parent, getStyle());
-        shell.setText("About...");
-
-        logoImage = loadImage(shell, "ddms-logo.png"); // $NON-NLS-1$
-        createContents(shell);
-        shell.pack();
-
-        shell.open();
-        Display display = parent.getDisplay();
-        while (!shell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-        logoImage.dispose();
-    }
-
-    /*
-     * Load an image file from a resource.
-     *
-     * This depends on Display, so I'm not sure what the rules are for
-     * loading once and caching in a static class field.
-     */
-    private Image loadImage(Shell shell, String fileName) {
-        InputStream imageStream;
-        String pathName = "/images/" + fileName;  // $NON-NLS-1$
-
-        imageStream = this.getClass().getResourceAsStream(pathName);
-        if (imageStream == null) {
-            //throw new NullPointerException("couldn't find " + pathName);
-            Log.w("ddms", "Couldn't load " + pathName);
-            Display display = shell.getDisplay();
-            return ImageHelper.createPlaceHolderArt(display, 100, 50,
-                    display.getSystemColor(SWT.COLOR_BLUE));
-        }
-
-        Image img = new Image(shell.getDisplay(), imageStream);
-        if (img == null)
-            throw new NullPointerException("couldn't load " + pathName);
-        return img;
-    }
-
-    /*
-     * Create the about box contents.
-     */
-    private void createContents(final Shell shell) {
-        GridLayout layout;
-        GridData data;
-        Label label;
-
-        shell.setLayout(new GridLayout(2, false));
-
-        // Fancy logo
-        Label logo = new Label(shell, SWT.BORDER);
-        logo.setImage(logoImage);
-
-        // Text Area
-        Composite textArea = new Composite(shell, SWT.NONE);
-        layout = new GridLayout(1, true);
-        textArea.setLayout(layout);
-
-        // Text lines
-        label = new Label(textArea, SWT.NONE);
-        label.setText("Dalvik Debug Monitor v" + Main.VERSION);
-        label = new Label(textArea, SWT.NONE);
-        label.setText("Copyright 2007, The Android Open Source Project");
-        label = new Label(textArea, SWT.NONE);
-        label.setText("All Rights Reserved.");
-
-        // blank spot in grid
-        label = new Label(shell, SWT.NONE);
-
-        // "OK" button
-        Button ok = new Button(shell, SWT.PUSH);
-        ok.setText("OK");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_END);
-        data.widthHint = 80;
-        ok.setLayoutData(data);
-        ok.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                shell.close();
-            }
-        });
-
-        shell.pack();
-
-        shell.setDefaultButton(ok);
-    }
-}
diff --git a/tools/ddms/app/src/com/android/ddms/DebugPortProvider.java b/tools/ddms/app/src/com/android/ddms/DebugPortProvider.java
deleted file mode 100644
index 89cc190..0000000
--- a/tools/ddms/app/src/com/android/ddms/DebugPortProvider.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddms;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.DebugPortManager.IDebugPortProvider;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * DDMS implementation of the IDebugPortProvider interface.
- * This class handles saving/loading the list of static debug port from
- * the preference store and provides the port number to the Device Monitor.
- */
-public class DebugPortProvider implements IDebugPortProvider {
-
-    private static DebugPortProvider sThis  = new DebugPortProvider();
-
-    /** Preference name for the static port list. */
-    public static final String PREFS_STATIC_PORT_LIST = "android.staticPortList"; //$NON-NLS-1$
-
-    /**
-     * Mapping device serial numbers to maps. The embedded maps are mapping application names to
-     * debugger ports.
-     */
-    private Map<String, Map<String, Integer>> mMap;
-
-    public static DebugPortProvider getInstance() {
-        return sThis;
-    }
-
-    private DebugPortProvider() {
-        computePortList();
-    }
-
-    /**
-         * Returns a static debug port for the specified application running on the
-         * specified {@link Device}.
-         * @param device The device the application is running on.
-         * @param appName The application name, as defined in the
-         *  AndroidManifest.xml package attribute.
-         * @return The static debug port or {@link #NO_STATIC_PORT} if there is none setup.
-     *
-     * @see IDebugPortProvider#getPort(Device, String)
-     */
-    public int getPort(Device device, String appName) {
-        if (mMap != null) {
-            Map<String, Integer> deviceMap = mMap.get(device.getSerialNumber());
-            if (deviceMap != null) {
-                Integer i = deviceMap.get(appName);
-                if (i != null) {
-                    return i.intValue();
-                }
-            }
-        }
-        return IDebugPortProvider.NO_STATIC_PORT;
-    }
-
-    /**
-     * Returns the map of Static debugger ports. The map links device serial numbers to
-     * a map linking application name to debugger ports.
-     */
-    public Map<String, Map<String, Integer>> getPortList() {
-        return mMap;
-    }
-
-    /**
-     * Create the map member from the values contained in the Preference Store.
-     */
-    private void computePortList() {
-        mMap = new HashMap<String, Map<String, Integer>>();
-
-        // get the prefs store
-        IPreferenceStore store = PrefsDialog.getStore();
-        String value = store.getString(PREFS_STATIC_PORT_LIST);
-
-        if (value != null && value.length() > 0) {
-            // format is
-            // port1|port2|port3|...
-            // where port# is
-            // appPackageName:appPortNumber:device-serial-number
-            String[] portSegments = value.split("\\|");  //$NON-NLS-1$
-            for (String seg : portSegments) {
-                String[] entry = seg.split(":");  //$NON-NLS-1$
-
-                // backward compatibility support. if we have only 2 entry, we default
-                // to the first emulator.
-                String deviceName = null;
-                if (entry.length == 3) {
-                    deviceName = entry[2];
-                } else {
-                    deviceName = Device.FIRST_EMULATOR_SN;
-                }
-
-                // get the device map
-                Map<String, Integer> deviceMap = mMap.get(deviceName);
-                if (deviceMap == null) {
-                    deviceMap = new HashMap<String, Integer>();
-                    mMap.put(deviceName, deviceMap);
-                }
-
-                deviceMap.put(entry[0], Integer.valueOf(entry[1]));
-            }
-        }
-    }
-
-    /**
-     * Sets new [device, app, port] values.
-     * The values are also sync'ed in the preference store.
-     * @param map The map containing the new values.
-     */
-    public void setPortList(Map<String, Map<String,Integer>> map) {
-        // update the member map.
-        mMap.clear();
-        mMap.putAll(map);
-
-        // create the value to store in the preference store.
-        // see format definition in getPortList
-        StringBuilder sb = new StringBuilder();
-
-        Set<String> deviceKeys = map.keySet();
-        for (String deviceKey : deviceKeys) {
-            Map<String, Integer> deviceMap = map.get(deviceKey);
-            if (deviceMap != null) {
-                Set<String> appKeys = deviceMap.keySet();
-
-                for (String appKey : appKeys) {
-                    Integer port = deviceMap.get(appKey);
-                    if (port != null) {
-                        sb.append(appKey).append(':').append(port.intValue()).append(':').
-                            append(deviceKey).append('|');
-                    }
-                }
-            }
-        }
-
-        String value = sb.toString();
-
-        // get the prefs store.
-        IPreferenceStore store = PrefsDialog.getStore();
-
-        // and give it the new value.
-        store.setValue(PREFS_STATIC_PORT_LIST, value);
-    }
-}
diff --git a/tools/ddms/app/src/com/android/ddms/DeviceCommandDialog.java b/tools/ddms/app/src/com/android/ddms/DeviceCommandDialog.java
deleted file mode 100644
index 2a1342e..0000000
--- a/tools/ddms/app/src/com/android/ddms/DeviceCommandDialog.java
+++ /dev/null
@@ -1,423 +0,0 @@
-/* //device/tools/ddms/src/com/android/ddms/DeviceCommandDialog.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddms;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.IShellOutputReceiver;
-import com.android.ddmlib.Log;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.BufferedOutputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-
-
-/**
- * Execute a command on an ADB-attached device and save the output.
- *
- * There are several ways to do this.  One is to run a single command
- * and show the output.  Another is to have several possible commands and
- * let the user click a button next to the one (or ones) they want.  This
- * currently uses the simple 1:1 form.
- */
-public class DeviceCommandDialog extends Dialog {
-
-    public static final int DEVICE_STATE = 0;
-    public static final int APP_STATE = 1;
-    public static final int RADIO_STATE = 2;
-    public static final int LOGCAT = 3;
-
-    private String mCommand;
-    private String mFileName;
-
-    private Label mStatusLabel;
-    private Button mCancelDone;
-    private Button mSave;
-    private Text mText;
-    private Font mFont = null;
-    private boolean mCancel;
-    private boolean mFinished;
-
-
-    /**
-     * Create with default style.
-     */
-    public DeviceCommandDialog(String command, String fileName, Shell parent) {
-        // don't want a close button, but it seems hard to get rid of on GTK
-        // keep it on all platforms for consistency
-        this(command, fileName, parent,
-            SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL | SWT.RESIZE);
-    }
-
-    /**
-     * Create with app-defined style.
-     */
-    public DeviceCommandDialog(String command, String fileName, Shell parent,
-        int style)
-    {
-        super(parent, style);
-        mCommand = command;
-        mFileName = fileName;
-    }
-
-    /**
-     * Prepare and display the dialog.
-     * @param currentDevice
-     */
-    public void open(Device currentDevice) {
-        Shell parent = getParent();
-        Shell shell = new Shell(parent, getStyle());
-        shell.setText("Remote Command");
-
-        mFinished = false;
-        mFont = findFont(shell.getDisplay());
-        createContents(shell);
-
-        // Getting weird layout behavior under Linux when Text is added --
-        // looks like text widget has min width of 400 when FILL_HORIZONTAL
-        // is used, and layout gets tweaked to force this.  (Might be even
-        // more with the scroll bars in place -- it wigged out when the
-        // file save dialog was invoked.)
-        shell.setMinimumSize(500, 200);
-        shell.setSize(800, 600);
-        shell.open();
-
-        executeCommand(shell, currentDevice);
-
-        Display display = parent.getDisplay();
-        while (!shell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-        if (mFont != null)
-            mFont.dispose();
-    }
-
-    /*
-     * Create a text widget to show the output and some buttons to
-     * manage things.
-     */
-    private void createContents(final Shell shell) {
-        GridData data;
-
-        shell.setLayout(new GridLayout(2, true));
-
-        shell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-                if (!mFinished) {
-                    Log.i("ddms", "NOT closing - cancelling command");
-                    event.doit = false;
-                    mCancel = true;
-                }
-            }
-        });
-
-        mStatusLabel = new Label(shell, SWT.NONE);
-        mStatusLabel.setText("Executing '" + shortCommandString() + "'");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
-        data.horizontalSpan = 2;
-        mStatusLabel.setLayoutData(data);
-
-        mText = new Text(shell, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
-        mText.setEditable(false);
-        mText.setFont(mFont);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 2;
-        mText.setLayoutData(data);
-
-        // "save" button
-        mSave = new Button(shell, SWT.PUSH);
-        mSave.setText("Save");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.widthHint = 80;
-        mSave.setLayoutData(data);
-        mSave.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                saveText(shell);
-            }
-        });
-        mSave.setEnabled(false);
-
-        // "cancel/done" button
-        mCancelDone = new Button(shell, SWT.PUSH);
-        mCancelDone.setText("Cancel");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.widthHint = 80;
-        mCancelDone.setLayoutData(data);
-        mCancelDone.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (!mFinished)
-                    mCancel = true;
-                else
-                    shell.close();
-            }
-        });
-    }
-
-    /*
-     * Figure out what font to use.
-     *
-     * Returns "null" if we can't figure it out, which SWT understands to
-     * mean "use default system font".
-     */
-    private Font findFont(Display display) {
-        String fontStr = PrefsDialog.getStore().getString("textOutputFont");
-        if (fontStr != null) {
-            FontData fdat = new FontData(fontStr);
-            if (fdat != null)
-                return new Font(display, fdat);
-        }
-        return null;
-    }
-
-
-    /*
-     * Callback class for command execution.
-     */
-    class Gatherer extends Thread implements IShellOutputReceiver {
-        public static final int RESULT_UNKNOWN = 0;
-        public static final int RESULT_SUCCESS = 1;
-        public static final int RESULT_FAILURE = 2;
-        public static final int RESULT_CANCELLED = 3;
-
-        private Shell mShell;
-        private String mCommand;
-        private Text mText;
-        private int mResult;
-        private Device mDevice;
-
-        /**
-         * Constructor; pass in the text widget that will receive the output.
-         * @param device
-         */
-        public Gatherer(Shell shell, Device device, String command, Text text) {
-            mShell = shell;
-            mDevice = device;
-            mCommand = command;
-            mText = text;
-            mResult = RESULT_UNKNOWN;
-
-            // this is in outer class
-            mCancel = false;
-        }
-
-        /**
-         * Thread entry point.
-         */
-        @Override
-        public void run() {
-
-            if (mDevice == null) {
-                Log.w("ddms", "Cannot execute command: no device selected.");
-                mResult = RESULT_FAILURE;
-            } else {
-                try {
-                    mDevice.executeShellCommand(mCommand, this);
-                    if (mCancel)
-                        mResult = RESULT_CANCELLED;
-                    else
-                        mResult = RESULT_SUCCESS;
-                }
-                catch (IOException ioe) {
-                    Log.w("ddms", "Remote exec failed: " + ioe.getMessage());
-                    mResult = RESULT_FAILURE;
-                }
-            }
-
-            mShell.getDisplay().asyncExec(new Runnable() {
-                public void run() {
-                    updateForResult(mResult);
-                }
-            });
-        }
-
-        /**
-         * Called by executeRemoteCommand().
-         */
-        public void addOutput(byte[] data, int offset, int length) {
-
-            Log.v("ddms", "received " + length + " bytes");
-            try {
-                final String text;
-                text = new String(data, offset, length, "ISO-8859-1");
-
-                // add to text widget; must do in UI thread
-                mText.getDisplay().asyncExec(new Runnable() {
-                    public void run() {
-                        mText.append(text);
-                    }
-                });
-            }
-            catch (UnsupportedEncodingException uee) {
-                uee.printStackTrace();      // not expected
-            }
-        }
-
-        public void flush() {
-            // nothing to flush.
-        }
-
-        /**
-         * Called by executeRemoteCommand().
-         */
-        public boolean isCancelled() {
-            return mCancel;
-        }
-    };
-
-    /*
-     * Execute a remote command, add the output to the text widget, and
-     * update controls.
-     *
-     * We have to run the command in a thread so that the UI continues
-     * to work.
-     */
-    private void executeCommand(Shell shell, Device device) {
-        Gatherer gath = new Gatherer(shell, device, commandString(), mText);
-        gath.start();
-    }
-
-    /*
-     * Update the controls after the remote operation completes.  This
-     * must be called from the UI thread.
-     */
-    private void updateForResult(int result) {
-        if (result == Gatherer.RESULT_SUCCESS) {
-            mStatusLabel.setText("Successfully executed '"
-                + shortCommandString() + "'");
-            mSave.setEnabled(true);
-        } else if (result == Gatherer.RESULT_CANCELLED) {
-            mStatusLabel.setText("Execution cancelled; partial results below");
-            mSave.setEnabled(true);     // save partial
-        } else if (result == Gatherer.RESULT_FAILURE) {
-            mStatusLabel.setText("Failed");
-        }
-        mStatusLabel.pack();
-        mCancelDone.setText("Done");
-        mFinished = true;
-    }
-
-    /*
-     * Allow the user to save the contents of the text dialog.
-     */
-    private void saveText(Shell shell) {
-        FileDialog dlg = new FileDialog(shell, SWT.SAVE);
-        String fileName;
-
-        dlg.setText("Save output...");
-        dlg.setFileName(defaultFileName());
-        dlg.setFilterPath(PrefsDialog.getStore().getString("lastTextSaveDir"));
-        dlg.setFilterNames(new String[] {
-            "Text Files (*.txt)"
-        });
-        dlg.setFilterExtensions(new String[] {
-            "*.txt"
-        });
-
-        fileName = dlg.open();
-        if (fileName != null) {
-            PrefsDialog.getStore().setValue("lastTextSaveDir",
-                                            dlg.getFilterPath());
-
-            Log.i("ddms", "Saving output to " + fileName);
-
-            /*
-             * Convert to 8-bit characters.
-             */
-            String text = mText.getText();
-            byte[] ascii;
-            try {
-                ascii = text.getBytes("ISO-8859-1");
-            }
-            catch (UnsupportedEncodingException uee) {
-                uee.printStackTrace();
-                ascii = new byte[0];
-            }
-
-            /*
-             * Output data, converting CRLF to LF.
-             */
-            try {
-                int length = ascii.length;
-
-                FileOutputStream outFile = new FileOutputStream(fileName);
-                BufferedOutputStream out = new BufferedOutputStream(outFile);
-                for (int i = 0; i < length; i++) {
-                    if (i < length-1 &&
-                        ascii[i] == 0x0d && ascii[i+1] == 0x0a)
-                    {
-                        continue;
-                    }
-                    out.write(ascii[i]);
-                }
-                out.close();        // flush buffer, close file
-            }
-            catch (IOException ioe) {
-                Log.w("ddms", "Unable to save " + fileName + ": " + ioe);
-            }
-        }
-    }
-
-
-    /*
-     * Return the shell command we're going to use.
-     */
-    private String commandString() {
-        return mCommand;
-
-    }
-
-    /*
-     * Return a default filename for the "save" command.
-     */
-    private String defaultFileName() {
-        return mFileName;
-    }
-
-    /*
-     * Like commandString(), but length-limited.
-     */
-    private String shortCommandString() {
-        String str = commandString();
-        if (str.length() > 50)
-            return str.substring(0, 50) + "...";
-        else
-            return str;
-    }
-}
-
diff --git a/tools/ddms/app/src/com/android/ddms/DropdownSelectionListener.java b/tools/ddms/app/src/com/android/ddms/DropdownSelectionListener.java
deleted file mode 100644
index 99d63ce..0000000
--- a/tools/ddms/app/src/com/android/ddms/DropdownSelectionListener.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/* //device/tools/ddms/src/com/android/ddms/DropdownSelectionListener.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddms;
-
-import com.android.ddmlib.Log;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.MenuItem;
-import org.eclipse.swt.widgets.ToolItem;
-
-/**
- * Helper class for drop-down menus in toolbars.
- */
-public class DropdownSelectionListener extends SelectionAdapter {
-    private Menu mMenu;
-    private ToolItem mDropdown;
-
-    /**
-     * Basic constructor.  Creates an empty Menu to hold items.
-     */
-    public DropdownSelectionListener(ToolItem item) {
-        mDropdown = item;
-        mMenu = new Menu(item.getParent().getShell(), SWT.POP_UP);
-    }
-
-    /**
-     * Add an item to the dropdown menu.
-     */
-    public void add(String label) {
-        MenuItem item = new MenuItem(mMenu, SWT.NONE);
-        item.setText(label);
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // update the dropdown's text to match the selection
-                MenuItem sel = (MenuItem) e.widget;
-                mDropdown.setText(sel.getText());
-            }
-        });
-    }
-
-    /**
-     * Invoked when dropdown or neighboring arrow is clicked.
-     */
-    @Override
-    public void widgetSelected(SelectionEvent e) {
-        if (e.detail == SWT.ARROW) {
-            // arrow clicked, show menu
-            ToolItem item = (ToolItem) e.widget;
-            Rectangle rect = item.getBounds();
-            Point pt = item.getParent().toDisplay(new Point(rect.x, rect.y));
-            mMenu.setLocation(pt.x, pt.y + rect.height);
-            mMenu.setVisible(true);
-        } else {
-            // button clicked
-            Log.i("ddms", mDropdown.getText() + " Pressed");
-        }
-    }
-}
-
diff --git a/tools/ddms/app/src/com/android/ddms/Main.java b/tools/ddms/app/src/com/android/ddms/Main.java
deleted file mode 100644
index d63b884..0000000
--- a/tools/ddms/app/src/com/android/ddms/Main.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddms;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.DebugPortManager;
-import com.android.ddmlib.Log;
-import com.android.sdkstats.SdkStatsService;
-
-import java.io.PrintWriter;
-import java.io.StringWriter;
-import java.lang.management.ManagementFactory;
-import java.lang.management.RuntimeMXBean;
-
-
-/**
- * Start the UI and network.
- */
-public class Main {
-
-    /** User visible version number. */
-    public static final String VERSION = "0.8.1";
-
-    public Main() {
-    }
-
-    /*
-     * If a thread bails with an uncaught exception, bring the whole
-     * thing down.
-     */
-    private static class UncaughtHandler implements Thread.UncaughtExceptionHandler {
-        public void uncaughtException(Thread t, Throwable e) {
-            Log.e("ddms", "shutting down due to uncaught exception");
-
-            StringWriter sw = new StringWriter();
-            PrintWriter pw = new PrintWriter(sw);
-            e.printStackTrace(pw);
-            Log.e("ddms", sw.toString());
-
-            System.exit(1);
-        }
-    }
-
-    /**
-     * Parse args, start threads.
-     */
-    public static void main(String[] args) {
-        // In order to have the AWT/SWT bridge work on Leopard, we do this little hack.
-        String os = System.getProperty("os.name"); //$NON-NLS-1$
-        if (os.startsWith("Mac OS")) { //$NON-NLS-1$
-            RuntimeMXBean rt = ManagementFactory.getRuntimeMXBean();
-            System.setProperty(
-                    "JAVA_STARTED_ON_FIRST_THREAD_" + (rt.getName().split("@"))[0], //$NON-NLS-1$
-                    "1"); //$NON-NLS-1$
-        }
-        
-        Thread.setDefaultUncaughtExceptionHandler(new UncaughtHandler());
-
-        // load prefs and init the default values
-        PrefsDialog.init();
-
-        Log.d("ddms", "Initializing");
-
-        // the "ping" argument means to check in with the server and exit
-        // the application name and version number must also be supplied
-        if (args.length >= 3 && args[0].equals("ping")) {
-            SdkStatsService.ping(args[1], args[2]);
-            return;
-        } else if (args.length > 0) {
-            Log.e("ddms", "Unknown argument: " + args[0]);
-            System.exit(1);
-        }
-
-        // ddms itself is wanted: send a ping for ourselves
-        SdkStatsService.ping("ddms", VERSION);  //$NON-NLS-1$
-
-        DebugPortManager.setProvider(DebugPortProvider.getInstance());
-
-        // create the three main threads
-        UIThread ui = UIThread.getInstance();
-
-        try {
-            ui.runUI();
-        } finally {
-            PrefsDialog.save();
-    
-            AndroidDebugBridge.terminate();
-        }
-
-        Log.d("ddms", "Bye");
-        
-        // this is kinda bad, but on MacOS the shutdown doesn't seem to finish because of
-        // a thread called AWT-Shutdown. This will help while I track this down.
-        System.exit(0);
-    }
-}
diff --git a/tools/ddms/app/src/com/android/ddms/PrefsDialog.java b/tools/ddms/app/src/com/android/ddms/PrefsDialog.java
deleted file mode 100644
index 69c48b0..0000000
--- a/tools/ddms/app/src/com/android/ddms/PrefsDialog.java
+++ /dev/null
@@ -1,545 +0,0 @@
-/* //device/tools/ddms/src/com/android/ddms/PrefsDialog.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddms;
-
-import com.android.ddmlib.DdmPreferences;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.PortFieldEditor;
-import com.android.sdkstats.SdkStatsService;
-
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.DirectoryFieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.FontFieldEditor;
-import org.eclipse.jface.preference.IntegerFieldEditor;
-import org.eclipse.jface.preference.PreferenceDialog;
-import org.eclipse.jface.preference.PreferenceManager;
-import org.eclipse.jface.preference.PreferenceNode;
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jface.preference.PreferenceStore;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
-import org.eclipse.jface.util.IPropertyChangeListener;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Link;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.File;
-import java.io.IOException;
-
-/**
- * Preferences dialog.
- */
-public final class PrefsDialog {
-
-    // Preference store.
-    private static PreferenceStore mPrefStore;
-
-    // public const values for storage
-    public final static String SHELL_X = "shellX"; //$NON-NLS-1$
-    public final static String SHELL_Y = "shellY"; //$NON-NLS-1$
-    public final static String SHELL_WIDTH = "shellWidth"; //$NON-NLS-1$
-    public final static String SHELL_HEIGHT = "shellHeight"; //$NON-NLS-1$
-    public final static String EXPLORER_SHELL_X = "explorerShellX"; //$NON-NLS-1$
-    public final static String EXPLORER_SHELL_Y = "explorerShellY"; //$NON-NLS-1$
-    public final static String EXPLORER_SHELL_WIDTH = "explorerShellWidth"; //$NON-NLS-1$
-    public final static String EXPLORER_SHELL_HEIGHT = "explorerShellHeight"; //$NON-NLS-1$
-    public final static String SHOW_NATIVE_HEAP = "native"; //$NON-NLS-1$
-
-    public final static String LOGCAT_COLUMN_MODE = "ddmsLogColumnMode"; //$NON-NLS-1$
-    public final static String LOGCAT_FONT = "ddmsLogFont"; //$NON-NLS-1$
-
-    public final static String LOGCAT_COLUMN_MODE_AUTO = "auto"; //$NON-NLS-1$
-    public final static String LOGCAT_COLUMN_MODE_MANUAL = "manual"; //$NON-NLS-1$
-
-    private final static String PREFS_DEBUG_PORT_BASE = "adbDebugBasePort"; //$NON-NLS-1$
-    private final static String PREFS_SELECTED_DEBUG_PORT = "debugSelectedPort"; //$NON-NLS-1$
-    private final static String PREFS_DEFAULT_THREAD_UPDATE = "defaultThreadUpdateEnabled"; //$NON-NLS-1$
-    private final static String PREFS_DEFAULT_HEAP_UPDATE = "defaultHeapUpdateEnabled"; //$NON-NLS-1$
-
-    private final static String PREFS_THREAD_REFRESH_INTERVAL = "threadStatusInterval"; //$NON-NLS-1$
-
-    private final static String PREFS_LOG_LEVEL = "ddmsLogLevel"; //$NON-NLS-1$
-
-
-    /**
-     * Private constructor -- do not instantiate.
-     */
-    private PrefsDialog() {}
-
-    /**
-     * Return the PreferenceStore that holds our values.
-     */
-    public static PreferenceStore getStore() {
-        return mPrefStore;
-    }
-
-    /**
-     * Save the prefs to the config file.
-     */
-    public static void save() {
-        try {
-            mPrefStore.save();
-        }
-        catch (IOException ioe) {
-            Log.w("ddms", "Failed saving prefs file: " + ioe.getMessage());
-        }
-    }
-
-    /**
-     * Do some one-time prep.
-     *
-     * The original plan was to let the individual classes define their
-     * own defaults, which we would get and then override with the config
-     * file.  However, PreferencesStore.load() doesn't trigger the "changed"
-     * events, which means we have to pull the loaded config values out by
-     * hand.
-     *
-     * So, we set the defaults, load the values from the config file, and
-     * then run through and manually export the values.  Then we duplicate
-     * the second part later on for the "changed" events.
-     */
-    public static void init() {
-        assert mPrefStore == null;
-        
-        mPrefStore = SdkStatsService.getPreferenceStore();
-        
-        if (mPrefStore == null) {
-            // we have a serious issue here...
-            Log.e("ddms",
-                    "failed to access both the user HOME directory and the system wide temp folder. Quitting.");
-            System.exit(1);
-        }
-
-        // configure default values
-        setDefaults(System.getProperty("user.home")); //$NON-NLS-1$
-
-        // listen for changes
-        mPrefStore.addPropertyChangeListener(new ChangeListener());
-
-        // Now we initialize the value of the preference, from the values in the store.
-
-        // First the ddm lib.
-        DdmPreferences.setDebugPortBase(mPrefStore.getInt(PREFS_DEBUG_PORT_BASE));
-        DdmPreferences.setSelectedDebugPort(mPrefStore.getInt(PREFS_SELECTED_DEBUG_PORT));
-        DdmPreferences.setLogLevel(mPrefStore.getString(PREFS_LOG_LEVEL));
-        DdmPreferences.setInitialThreadUpdate(mPrefStore.getBoolean(PREFS_DEFAULT_THREAD_UPDATE));
-        DdmPreferences.setInitialHeapUpdate(mPrefStore.getBoolean(PREFS_DEFAULT_HEAP_UPDATE));
-
-        // some static values
-        String out = System.getenv("ANDROID_PRODUCT_OUT"); //$NON-NLS-1$
-        DdmUiPreferences.setSymbolsLocation(out + File.separator + "symbols"); //$NON-NLS-1$
-        DdmUiPreferences.setAddr2LineLocation("arm-eabi-addr2line"); //$NON-NLS-1$
-
-        String traceview = System.getProperty("com.android.ddms.bindir");  //$NON-NLS-1$
-        if (traceview != null && traceview.length() != 0) {
-            traceview += File.separator + "traceview"; //$NON-NLS-1$
-        } else {
-            traceview = "traceview"; //$NON-NLS-1$
-        }
-        DdmUiPreferences.setTraceviewLocation(traceview);
-
-        // Now the ddmui lib
-        DdmUiPreferences.setStore(mPrefStore);
-        DdmUiPreferences.setThreadRefreshInterval(mPrefStore.getInt(PREFS_THREAD_REFRESH_INTERVAL));
-    }
-
-    /*
-     * Set default values for all preferences.  These are either defined
-     * statically or are based on the values set by the class initializers
-     * in other classes.
-     *
-     * The other threads (e.g. VMWatcherThread) haven't been created yet,
-     * so we want to use static values rather than reading fields from
-     * class.getInstance().
-     */
-    private static void setDefaults(String homeDir) {
-        mPrefStore.setDefault(PREFS_DEBUG_PORT_BASE, DdmPreferences.DEFAULT_DEBUG_PORT_BASE);
-
-        mPrefStore.setDefault(PREFS_SELECTED_DEBUG_PORT,
-                DdmPreferences.DEFAULT_SELECTED_DEBUG_PORT);
-
-        mPrefStore.setDefault(PREFS_DEFAULT_THREAD_UPDATE, true);
-        mPrefStore.setDefault(PREFS_DEFAULT_HEAP_UPDATE, false);
-        mPrefStore.setDefault(PREFS_THREAD_REFRESH_INTERVAL,
-            DdmUiPreferences.DEFAULT_THREAD_REFRESH_INTERVAL);
-
-        mPrefStore.setDefault("textSaveDir", homeDir); //$NON-NLS-1$
-        mPrefStore.setDefault("imageSaveDir", homeDir); //$NON-NLS-1$
-
-        mPrefStore.setDefault(PREFS_LOG_LEVEL, "info"); //$NON-NLS-1$
-
-        // choose a default font for the text output
-        FontData fdat = new FontData("Courier", 10, SWT.NORMAL); //$NON-NLS-1$
-        mPrefStore.setDefault("textOutputFont", fdat.toString()); //$NON-NLS-1$
-
-        // layout information.
-        mPrefStore.setDefault(SHELL_X, 100);
-        mPrefStore.setDefault(SHELL_Y, 100);
-        mPrefStore.setDefault(SHELL_WIDTH, 800);
-        mPrefStore.setDefault(SHELL_HEIGHT, 600);
-
-        mPrefStore.setDefault(EXPLORER_SHELL_X, 50);
-        mPrefStore.setDefault(EXPLORER_SHELL_Y, 50);
-
-        mPrefStore.setDefault(SHOW_NATIVE_HEAP, false);
-    }
-
-
-    /*
-     * Create a "listener" to take action when preferences change.  These are
-     * required for ongoing activities that don't check prefs on each use.
-     *
-     * This is only invoked when something explicitly changes the value of
-     * a preference (e.g. not when the prefs file is loaded).
-     */
-    private static class ChangeListener implements IPropertyChangeListener {
-        public void propertyChange(PropertyChangeEvent event) {
-            String changed = event.getProperty();
-
-            if (changed.equals(PREFS_DEBUG_PORT_BASE)) {
-                DdmPreferences.setDebugPortBase(mPrefStore.getInt(PREFS_DEBUG_PORT_BASE));
-            } else if (changed.equals(PREFS_SELECTED_DEBUG_PORT)) {
-                DdmPreferences.setSelectedDebugPort(mPrefStore.getInt(PREFS_SELECTED_DEBUG_PORT));
-            } else if (changed.equals(PREFS_LOG_LEVEL)) {
-                DdmPreferences.setLogLevel((String)event.getNewValue());
-            } else if (changed.equals("textSaveDir")) {
-                mPrefStore.setValue("lastTextSaveDir",
-                    (String) event.getNewValue());
-            } else if (changed.equals("imageSaveDir")) {
-                mPrefStore.setValue("lastImageSaveDir",
-                    (String) event.getNewValue());
-
-            } else {
-                Log.v("ddms", "Preference change: " + event.getProperty()
-                    + ": '" + event.getOldValue()
-                    + "' --> '" + event.getNewValue() + "'");
-            }
-        }
-    }
-
-
-    /**
-     * Create and display the dialog.
-     */
-    public static void run(Shell shell) {
-        assert mPrefStore != null;
-
-        PreferenceManager prefMgr = new PreferenceManager();
-
-        PreferenceNode node, subNode;
-
-        // this didn't work -- got NPE, possibly from class lookup:
-        //PreferenceNode app = new PreferenceNode("app", "Application", null,
-        //    AppPrefs.class.getName());
-
-        node = new PreferenceNode("client", new ClientPrefs());
-        prefMgr.addToRoot(node);
-
-        subNode = new PreferenceNode("panel", new PanelPrefs());
-        //prefMgr.addTo(node.getId(), subNode);
-        prefMgr.addToRoot(subNode);
-
-        node = new PreferenceNode("device", new DevicePrefs());
-        prefMgr.addToRoot(node);
-
-        node = new PreferenceNode("LogCat", new LogCatPrefs());
-        prefMgr.addToRoot(node);
-
-        node = new PreferenceNode("app", new AppPrefs());
-        prefMgr.addToRoot(node);
-
-        node = new PreferenceNode("stats", new UsageStatsPrefs());
-        prefMgr.addToRoot(node);
-
-        PreferenceDialog dlg = new PreferenceDialog(shell, prefMgr);
-        dlg.setPreferenceStore(mPrefStore);
-
-        // run it
-        dlg.open();
-
-        // save prefs
-        try {
-            mPrefStore.save();
-        }
-        catch (IOException ioe) {
-        }
-
-        // discard the stuff we created
-        //prefMgr.dispose();
-        //dlg.dispose();
-    }
-
-    /**
-     * "Client Scan" prefs page.
-     */
-    private static class ClientPrefs extends FieldEditorPreferencePage {
-
-        /**
-         * Basic constructor.
-         */
-        public ClientPrefs() {
-            super(GRID);        // use "grid" layout so edit boxes line up
-            setTitle("Client Scan");
-        }
-
-         /**
-         * Create field editors.
-         */
-        @Override
-        protected void createFieldEditors() {
-            IntegerFieldEditor ife;
-
-            ife = new PortFieldEditor(PREFS_DEBUG_PORT_BASE,
-                "ADB debugger base:", getFieldEditorParent());
-            addField(ife);
-
-            ife = new PortFieldEditor(PREFS_SELECTED_DEBUG_PORT,
-                "Debug selected VM:", getFieldEditorParent());
-            addField(ife);
-        }
-    }
-
-    /**
-     * "Panel" prefs page.
-     */
-    private static class PanelPrefs extends FieldEditorPreferencePage {
-
-        /**
-         * Basic constructor.
-         */
-        public PanelPrefs() {
-            super(FLAT);        // use "flat" layout
-            setTitle("Info Panels");
-        }
-
-        /**
-         * Create field editors.
-         */
-        @Override
-        protected void createFieldEditors() {
-            BooleanFieldEditor bfe;
-            IntegerFieldEditor ife;
-
-            bfe = new BooleanFieldEditor(PREFS_DEFAULT_THREAD_UPDATE,
-                "Thread updates enabled by default", getFieldEditorParent());
-            addField(bfe);
-
-            bfe = new BooleanFieldEditor(PREFS_DEFAULT_HEAP_UPDATE,
-                "Heap updates enabled by default", getFieldEditorParent());
-            addField(bfe);
-
-            ife = new IntegerFieldEditor(PREFS_THREAD_REFRESH_INTERVAL,
-                "Thread status interval (seconds):", getFieldEditorParent());
-            ife.setValidRange(1, 60);
-            addField(ife);
-        }
-    }
-
-    /**
-     * "Device" prefs page.
-     */
-    private static class DevicePrefs extends FieldEditorPreferencePage {
-
-        /**
-         * Basic constructor.
-         */
-        public DevicePrefs() {
-            super(FLAT);        // use "flat" layout
-            setTitle("Device");
-        }
-
-        /**
-         * Create field editors.
-         */
-        @Override
-        protected void createFieldEditors() {
-            DirectoryFieldEditor dfe;
-            FontFieldEditor ffe;
-
-            dfe = new DirectoryFieldEditor("textSaveDir",
-                "Default text save dir:", getFieldEditorParent());
-            addField(dfe);
-
-            dfe = new DirectoryFieldEditor("imageSaveDir",
-                "Default image save dir:", getFieldEditorParent());
-            addField(dfe);
-
-            ffe = new FontFieldEditor("textOutputFont", "Text output font:",
-                getFieldEditorParent());
-            addField(ffe);
-        }
-    }
-
-    /**
-     * "logcat" prefs page.
-     */
-    private static class LogCatPrefs extends FieldEditorPreferencePage {
-
-        /**
-         * Basic constructor.
-         */
-        public LogCatPrefs() {
-            super(FLAT);        // use "flat" layout
-            setTitle("Logcat");
-        }
-
-        /**
-         * Create field editors.
-         */
-        @Override
-        protected void createFieldEditors() {
-            RadioGroupFieldEditor rgfe;
-
-            rgfe = new RadioGroupFieldEditor(PrefsDialog.LOGCAT_COLUMN_MODE,
-                "Message Column Resizing Mode", 1, new String[][] {
-                    { "Manual", PrefsDialog.LOGCAT_COLUMN_MODE_MANUAL },
-                    { "Automatic", PrefsDialog.LOGCAT_COLUMN_MODE_AUTO },
-                    },
-                getFieldEditorParent(), true);
-            addField(rgfe);
-
-            FontFieldEditor ffe = new FontFieldEditor(PrefsDialog.LOGCAT_FONT, "Text output font:",
-                    getFieldEditorParent());
-            addField(ffe);
-        }
-    }
-
-
-    /**
-     * "Application" prefs page.
-     */
-    private static class AppPrefs extends FieldEditorPreferencePage {
-
-        /**
-         * Basic constructor.
-         */
-        public AppPrefs() {
-            super(FLAT);        // use "flat" layout
-            setTitle("DDMS");
-        }
-
-        /**
-         * Create field editors.
-         */
-        @Override
-        protected void createFieldEditors() {
-            RadioGroupFieldEditor rgfe;
-
-            rgfe = new RadioGroupFieldEditor(PREFS_LOG_LEVEL,
-                "Logging Level", 1, new String[][] {
-                    { "Verbose", LogLevel.VERBOSE.getStringValue() },
-                    { "Debug", LogLevel.DEBUG.getStringValue() },
-                    { "Info", LogLevel.INFO.getStringValue() },
-                    { "Warning", LogLevel.WARN.getStringValue() },
-                    { "Error", LogLevel.ERROR.getStringValue() },
-                    { "Assert", LogLevel.ASSERT.getStringValue() },
-                    },
-                getFieldEditorParent(), true);
-            addField(rgfe);
-        }
-    }
-
-    /**
-     * "Device" prefs page.
-     */
-    private static class UsageStatsPrefs extends PreferencePage {
-
-        private BooleanFieldEditor mOptInCheckbox;
-        private Composite mTop;
-
-        /**
-         * Basic constructor.
-         */
-        public UsageStatsPrefs() {
-            setTitle("Usage Stats");
-        }
-
-        @Override
-        protected Control createContents(Composite parent) {
-            mTop = new Composite(parent, SWT.NONE);
-            mTop.setLayout(new GridLayout(1, false));
-            mTop.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            Link text = new Link(mTop, SWT.WRAP);
-            text.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            text.setText(SdkStatsService.BODY_TEXT);
-
-            text.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent event) {
-                    SdkStatsService.openUrl(event.text);
-                }
-            });
-
-            mOptInCheckbox = new BooleanFieldEditor(SdkStatsService.PING_OPT_IN,
-                    SdkStatsService.CHECKBOX_TEXT, mTop);
-            mOptInCheckbox.setPage(this);
-            mOptInCheckbox.setPreferenceStore(getPreferenceStore());
-            mOptInCheckbox.load();
-
-            return null;
-        }
-
-        @Override
-        protected Point doComputeSize() {
-            if (mTop != null) {
-                return mTop.computeSize(450, SWT.DEFAULT, true);
-            }
-
-            return super.doComputeSize();
-        }
-
-        @Override
-        protected void performDefaults() {
-            if (mOptInCheckbox != null) {
-                mOptInCheckbox.loadDefault();
-            }
-            super.performDefaults();
-        }
-
-        @Override
-        public void performApply() {
-            if (mOptInCheckbox != null) {
-                mOptInCheckbox.store();
-            }
-            super.performApply();
-        }
-
-        @Override
-        public boolean performOk() {
-            if (mOptInCheckbox != null) {
-                mOptInCheckbox.store();
-            }
-            return super.performOk();
-        }
-    }
-
-}
-
-
diff --git a/tools/ddms/app/src/com/android/ddms/StaticPortConfigDialog.java b/tools/ddms/app/src/com/android/ddms/StaticPortConfigDialog.java
deleted file mode 100644
index d00bc7f..0000000
--- a/tools/ddms/app/src/com/android/ddms/StaticPortConfigDialog.java
+++ /dev/null
@@ -1,394 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddms;
-
-import com.android.ddmuilib.TableHelper;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Dialog to configure the static debug ports.
- *
- */
-public class StaticPortConfigDialog extends Dialog {
-
-    /** Preference name for the 0th column width */
-    private static final String PREFS_DEVICE_COL = "spcd.deviceColumn"; //$NON-NLS-1$
-
-    /** Preference name for the 1st column width */
-    private static final String PREFS_APP_COL = "spcd.AppColumn"; //$NON-NLS-1$
-
-    /** Preference name for the 2nd column width */
-    private static final String PREFS_PORT_COL = "spcd.PortColumn"; //$NON-NLS-1$
-
-    private static final int COL_DEVICE = 0;
-    private static final int COL_APPLICATION = 1;
-    private static final int COL_PORT = 2;
-
-
-    private static final int DLG_WIDTH = 500;
-    private static final int DLG_HEIGHT = 300;
-
-    private Shell mShell;
-    private Shell mParent;
-
-    private Table mPortTable;
-
-    /**
-     * Array containing the list of already used static port to avoid
-     * duplication.
-     */
-    private ArrayList<Integer> mPorts = new ArrayList<Integer>();
-
-    /**
-     * Basic constructor.
-     * @param parent
-     */
-    public StaticPortConfigDialog(Shell parent) {
-        super(parent, SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL);
-    }
-
-    /**
-     * Open and display the dialog. This method returns only when the
-     * user closes the dialog somehow.
-     *
-     */
-    public void open() {
-        createUI();
-
-        if (mParent == null || mShell == null) {
-            return;
-        }
-
-        updateFromStore();
-
-        // Set the dialog size.
-        mShell.setMinimumSize(DLG_WIDTH, DLG_HEIGHT);
-        Rectangle r = mParent.getBounds();
-        // get the center new top left.
-        int cx = r.x + r.width/2;
-        int x = cx - DLG_WIDTH / 2;
-        int cy = r.y + r.height/2;
-        int y = cy - DLG_HEIGHT / 2;
-        mShell.setBounds(x, y, DLG_WIDTH, DLG_HEIGHT);
-
-        mShell.pack();
-
-        // actually open the dialog
-        mShell.open();
-
-        // event loop until the dialog is closed.
-        Display display = mParent.getDisplay();
-        while (!mShell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-    }
-
-    /**
-     * Creates the dialog ui.
-     */
-    private void createUI() {
-        mParent = getParent();
-        mShell = new Shell(mParent, getStyle());
-        mShell.setText("Static Port Configuration");
-
-        mShell.setLayout(new GridLayout(1, true));
-
-        mShell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-                event.doit = true;
-            }
-        });
-
-        // center part with the list on the left and the buttons
-        // on the right.
-        Composite main = new Composite(mShell, SWT.NONE);
-        main.setLayoutData(new GridData(GridData.FILL_BOTH));
-        main.setLayout(new GridLayout(2, false));
-
-        // left part: list view
-        mPortTable = new Table(main, SWT.SINGLE | SWT.FULL_SELECTION);
-        mPortTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mPortTable.setHeaderVisible(true);
-        mPortTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mPortTable, "Device Serial Number",
-                SWT.LEFT, "emulator-5554", //$NON-NLS-1$
-                PREFS_DEVICE_COL, PrefsDialog.getStore());
-
-        TableHelper.createTableColumn(mPortTable, "Application Package",
-                SWT.LEFT, "com.android.samples.phone", //$NON-NLS-1$
-                PREFS_APP_COL, PrefsDialog.getStore());
-
-        TableHelper.createTableColumn(mPortTable, "Debug Port",
-                SWT.RIGHT, "Debug Port", //$NON-NLS-1$
-                PREFS_PORT_COL, PrefsDialog.getStore());
-
-        // right part: buttons
-        Composite buttons = new Composite(main, SWT.NONE);
-        buttons.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-        buttons.setLayout(new GridLayout(1, true));
-
-        Button newButton = new Button(buttons, SWT.NONE);
-        newButton.setText("New...");
-        newButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                StaticPortEditDialog dlg = new StaticPortEditDialog(mShell,
-                        mPorts);
-                if (dlg.open()) {
-                    // get the text
-                    String device = dlg.getDeviceSN();
-                    String app = dlg.getAppName();
-                    int port = dlg.getPortNumber();
-
-                    // add it to the list
-                    addEntry(device, app, port);
-                }
-            }
-        });
-
-        final Button editButton = new Button(buttons, SWT.NONE);
-        editButton.setText("Edit...");
-        editButton.setEnabled(false);
-        editButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                int index = mPortTable.getSelectionIndex();
-                String oldDeviceName = getDeviceName(index);
-                String oldAppName = getAppName(index);
-                String oldPortNumber = getPortNumber(index);
-                StaticPortEditDialog dlg = new StaticPortEditDialog(mShell,
-                        mPorts, oldDeviceName, oldAppName, oldPortNumber);
-                if (dlg.open()) {
-                    // get the text
-                    String deviceName = dlg.getDeviceSN();
-                    String app = dlg.getAppName();
-                    int port = dlg.getPortNumber();
-
-                    // add it to the list
-                    replaceEntry(index, deviceName, app, port);
-                }
-            }
-        });
-
-        final Button deleteButton = new Button(buttons, SWT.NONE);
-        deleteButton.setText("Delete");
-        deleteButton.setEnabled(false);
-        deleteButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                int index = mPortTable.getSelectionIndex();
-                removeEntry(index);
-            }
-        });
-
-        // bottom part with the ok/cancel
-        Composite bottomComp = new Composite(mShell, SWT.NONE);
-        bottomComp.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_CENTER));
-        bottomComp.setLayout(new GridLayout(2, true));
-
-        Button okButton = new Button(bottomComp, SWT.NONE);
-        okButton.setText("OK");
-        okButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateStore();
-                mShell.close();
-            }
-        });
-
-        Button cancelButton = new Button(bottomComp, SWT.NONE);
-        cancelButton.setText("Cancel");
-        cancelButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mShell.close();
-            }
-        });
-
-        mPortTable.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get the selection index
-                int index = mPortTable.getSelectionIndex();
-
-                boolean enabled = index != -1;
-                editButton.setEnabled(enabled);
-                deleteButton.setEnabled(enabled);
-            }
-        });
-
-        mShell.pack();
-
-    }
-
-    /**
-     * Add a new entry in the list.
-     * @param deviceName the serial number of the device
-     * @param appName java package for the application
-     * @param portNumber port number
-     */
-    private void addEntry(String deviceName, String appName, int portNumber) {
-        // create a new item for the table
-        TableItem item = new TableItem(mPortTable, SWT.NONE);
-
-        item.setText(COL_DEVICE, deviceName);
-        item.setText(COL_APPLICATION, appName);
-        item.setText(COL_PORT, Integer.toString(portNumber));
-
-        // add the port to the list of port number used.
-        mPorts.add(portNumber);
-    }
-
-    /**
-     * Remove an entry from the list.
-     * @param index The index of the entry to be removed
-     */
-    private void removeEntry(int index) {
-        // remove from the ui
-        mPortTable.remove(index);
-
-        // and from the port list.
-        mPorts.remove(index);
-    }
-
-    /**
-     * Replace an entry in the list with new values.
-     * @param index The index of the item to be replaced
-     * @param deviceName the serial number of the device
-     * @param appName The new java package for the application
-     * @param portNumber The new port number.
-     */
-    private void replaceEntry(int index, String deviceName, String appName, int portNumber) {
-        // get the table item by index
-        TableItem item = mPortTable.getItem(index);
-
-        // set its new value
-        item.setText(COL_DEVICE, deviceName);
-        item.setText(COL_APPLICATION, appName);
-        item.setText(COL_PORT, Integer.toString(portNumber));
-
-        // and replace the port number in the port list.
-        mPorts.set(index, portNumber);
-    }
-
-
-    /**
-     * Returns the device name for a specific index
-     * @param index The index
-     * @return the java package name of the application
-     */
-    private String getDeviceName(int index) {
-        TableItem item = mPortTable.getItem(index);
-        return item.getText(COL_DEVICE);
-    }
-
-    /**
-     * Returns the application name for a specific index
-     * @param index The index
-     * @return the java package name of the application
-     */
-    private String getAppName(int index) {
-        TableItem item = mPortTable.getItem(index);
-        return item.getText(COL_APPLICATION);
-    }
-
-    /**
-     * Returns the port number for a specific index
-     * @param index The index
-     * @return the port number
-     */
-    private String getPortNumber(int index) {
-        TableItem item = mPortTable.getItem(index);
-        return item.getText(COL_PORT);
-    }
-
-    /**
-     * Updates the ui from the value in the preference store.
-     */
-    private void updateFromStore() {
-        // get the map from the debug port manager
-        DebugPortProvider provider = DebugPortProvider.getInstance();
-        Map<String, Map<String, Integer>> map = provider.getPortList();
-
-        // we're going to loop on the keys and fill the table.
-        Set<String> deviceKeys = map.keySet();
-
-        for (String deviceKey : deviceKeys) {
-            Map<String, Integer> deviceMap = map.get(deviceKey);
-            if (deviceMap != null) {
-                Set<String> appKeys = deviceMap.keySet();
-
-                for (String appKey : appKeys) {
-                    Integer port = deviceMap.get(appKey);
-                    if (port != null) {
-                        addEntry(deviceKey, appKey, port);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Update the store from the content of the ui.
-     */
-    private void updateStore() {
-        // create a new Map object and fill it.
-        HashMap<String, Map<String, Integer>> map = new HashMap<String, Map<String, Integer>>();
-
-        int count = mPortTable.getItemCount();
-
-        for (int i = 0 ; i < count ; i++) {
-            TableItem item = mPortTable.getItem(i);
-            String deviceName = item.getText(COL_DEVICE);
-
-            Map<String, Integer> deviceMap = map.get(deviceName);
-            if (deviceMap == null) {
-                deviceMap = new HashMap<String, Integer>();
-                map.put(deviceName, deviceMap);
-            }
-
-            deviceMap.put(item.getText(COL_APPLICATION), Integer.valueOf(item.getText(COL_PORT)));
-        }
-
-        // set it in the store through the debug port manager.
-        DebugPortProvider provider = DebugPortProvider.getInstance();
-        provider.setPortList(map);
-    }
-}
diff --git a/tools/ddms/app/src/com/android/ddms/StaticPortEditDialog.java b/tools/ddms/app/src/com/android/ddms/StaticPortEditDialog.java
deleted file mode 100644
index 6330126..0000000
--- a/tools/ddms/app/src/com/android/ddms/StaticPortEditDialog.java
+++ /dev/null
@@ -1,330 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddms;
-
-import com.android.ddmlib.Device;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.ArrayList;
-
-/**
- * Small dialog box to edit a static port number.
- */
-public class StaticPortEditDialog extends Dialog {
-
-    private static final int DLG_WIDTH = 400;
-    private static final int DLG_HEIGHT = 200;
-
-    private Shell mParent;
-
-    private Shell mShell;
-
-    private boolean mOk = false;
-
-    private String mAppName;
-
-    private String mPortNumber;
-
-    private Button mOkButton;
-
-    private Label mWarning;
-
-    /** List of ports already in use */
-    private ArrayList<Integer> mPorts;
-
-    /** This is the port being edited. */
-    private int mEditPort = -1;
-    private String mDeviceSn;
-
-    /**
-     * Creates a dialog with empty fields.
-     * @param parent The parent Shell
-     * @param ports The list of already used port numbers.
-     */
-    public StaticPortEditDialog(Shell parent, ArrayList<Integer> ports) {
-        super(parent, SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL);
-        mPorts = ports;
-        mDeviceSn = Device.FIRST_EMULATOR_SN;
-    }
-
-    /**
-     * Creates a dialog with predefined values.
-     * @param shell The parent shell
-     * @param ports The list of already used port numbers.
-     * @param oldDeviceSN the device serial number to display
-     * @param oldAppName The application name to display
-     * @param oldPortNumber The port number to display
-     */
-    public StaticPortEditDialog(Shell shell, ArrayList<Integer> ports,
-            String oldDeviceSN, String oldAppName, String oldPortNumber) {
-        this(shell, ports);
-
-        mDeviceSn = oldDeviceSN;
-        mAppName = oldAppName;
-        mPortNumber = oldPortNumber;
-        mEditPort = Integer.valueOf(mPortNumber);
-    }
-
-    /**
-     * Opens the dialog. The method will return when the user closes the dialog
-     * somehow.
-     *
-     * @return true if ok was pressed, false if cancelled.
-     */
-    public boolean open() {
-        createUI();
-
-        if (mParent == null || mShell == null) {
-            return false;
-        }
-
-        mShell.setMinimumSize(DLG_WIDTH, DLG_HEIGHT);
-        Rectangle r = mParent.getBounds();
-        // get the center new top left.
-        int cx = r.x + r.width/2;
-        int x = cx - DLG_WIDTH / 2;
-        int cy = r.y + r.height/2;
-        int y = cy - DLG_HEIGHT / 2;
-        mShell.setBounds(x, y, DLG_WIDTH, DLG_HEIGHT);
-
-        mShell.open();
-
-        Display display = mParent.getDisplay();
-        while (!mShell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-        return mOk;
-    }
-
-    public String getDeviceSN() {
-        return mDeviceSn;
-    }
-
-    public String getAppName() {
-        return mAppName;
-    }
-
-    public int getPortNumber() {
-        return Integer.valueOf(mPortNumber);
-    }
-
-    private void createUI() {
-        mParent = getParent();
-        mShell = new Shell(mParent, getStyle());
-        mShell.setText("Static Port");
-
-        mShell.setLayout(new GridLayout(1, false));
-
-        mShell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-            }
-        });
-
-        // center part with the edit field
-        Composite main = new Composite(mShell, SWT.NONE);
-        main.setLayoutData(new GridData(GridData.FILL_BOTH));
-        main.setLayout(new GridLayout(2, false));
-
-        Label l0 = new Label(main, SWT.NONE);
-        l0.setText("Device Name:");
-
-        final Text deviceSNText = new Text(main, SWT.SINGLE | SWT.BORDER);
-        deviceSNText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        if (mDeviceSn != null) {
-            deviceSNText.setText(mDeviceSn);
-        }
-        deviceSNText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mDeviceSn = deviceSNText.getText().trim();
-                validate();
-            }
-        });
-
-        Label l = new Label(main, SWT.NONE);
-        l.setText("Application Name:");
-
-        final Text appNameText = new Text(main, SWT.SINGLE | SWT.BORDER);
-        if (mAppName != null) {
-            appNameText.setText(mAppName);
-        }
-        appNameText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        appNameText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mAppName = appNameText.getText().trim();
-                validate();
-            }
-        });
-
-        Label l2 = new Label(main, SWT.NONE);
-        l2.setText("Debug Port:");
-
-        final Text debugPortText = new Text(main, SWT.SINGLE | SWT.BORDER);
-        if (mPortNumber != null) {
-            debugPortText.setText(mPortNumber);
-        }
-        debugPortText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        debugPortText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mPortNumber = debugPortText.getText().trim();
-                validate();
-            }
-        });
-
-        // warning label
-        Composite warningComp = new Composite(mShell, SWT.NONE);
-        warningComp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        warningComp.setLayout(new GridLayout(1, true));
-
-        mWarning = new Label(warningComp, SWT.NONE);
-        mWarning.setText("");
-        mWarning.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // bottom part with the ok/cancel
-        Composite bottomComp = new Composite(mShell, SWT.NONE);
-        bottomComp
-                .setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER));
-        bottomComp.setLayout(new GridLayout(2, true));
-
-        mOkButton = new Button(bottomComp, SWT.NONE);
-        mOkButton.setText("OK");
-        mOkButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mOk = true;
-                mShell.close();
-            }
-        });
-        mOkButton.setEnabled(false);
-        mShell.setDefaultButton(mOkButton);
-
-        Button cancelButton = new Button(bottomComp, SWT.NONE);
-        cancelButton.setText("Cancel");
-        cancelButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mShell.close();
-            }
-        });
-
-        validate();
-    }
-
-    /**
-     * Validates the content of the 2 text fields and enable/disable "ok", while
-     * setting up the warning/error message.
-     */
-    private void validate() {
-        // first we reset the warning dialog. This allows us to latter
-        // display warnings.
-        mWarning.setText(""); // $NON-NLS-1$
-
-        // check the device name field is not empty
-        if (mDeviceSn == null || mDeviceSn.length() == 0) {
-            mWarning.setText("Device name missing.");
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        // check the application name field is not empty
-        if (mAppName == null || mAppName.length() == 0) {
-            mWarning.setText("Application name missing.");
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        String packageError = "Application name must be a valid Java package name.";
-
-        // validate the package name as well. It must be a fully qualified
-        // java package.
-        String[] packageSegments = mAppName.split("\\."); // $NON-NLS-1$
-        for (String p : packageSegments) {
-            if (p.matches("^[a-zA-Z][a-zA-Z0-9]*") == false) { // $NON-NLS-1$
-                mWarning.setText(packageError);
-                mOkButton.setEnabled(false);
-                return;
-            }
-
-            // lets also display a warning if the package contains upper case
-            // letters.
-            if (p.matches("^[a-z][a-z0-9]*") == false) { // $NON-NLS-1$
-                mWarning.setText("Lower case is recommended for Java packages.");
-            }
-        }
-
-        // the split will not detect the last char being a '.'
-        // so we test it manually
-        if (mAppName.charAt(mAppName.length()-1) == '.') {
-            mWarning.setText(packageError);
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        // now we test the package name field is not empty.
-        if (mPortNumber == null || mPortNumber.length() == 0) {
-            mWarning.setText("Port Number missing.");
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        // then we check it only contains digits.
-        if (mPortNumber.matches("[0-9]*") == false) { // $NON-NLS-1$
-            mWarning.setText("Port Number invalid.");
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        // get the int from the port number to validate
-        long port = Long.valueOf(mPortNumber);
-        if (port >= 32767) {
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        // check if its in the list of already used ports
-        if (port != mEditPort) {
-            for (Integer i : mPorts) {
-                if (port == i.intValue()) {
-                    mWarning.setText("Port already in use.");
-                    mOkButton.setEnabled(false);
-                    return;
-                }
-            }
-        }
-
-        // at this point there's not error, so we enable the ok button.
-        mOkButton.setEnabled(true);
-    }
-}
diff --git a/tools/ddms/app/src/com/android/ddms/UIThread.java b/tools/ddms/app/src/com/android/ddms/UIThread.java
deleted file mode 100644
index ff89e2c..0000000
--- a/tools/ddms/app/src/com/android/ddms/UIThread.java
+++ /dev/null
@@ -1,1491 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddms;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.ILogOutput;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.AllocationPanel;
-import com.android.ddmuilib.DevicePanel;
-import com.android.ddmuilib.DevicePanel.IUiSelectionListener;
-import com.android.ddmuilib.EmulatorControlPanel;
-import com.android.ddmuilib.HeapPanel;
-import com.android.ddmuilib.ITableFocusListener;
-import com.android.ddmuilib.ImageHelper;
-import com.android.ddmuilib.ImageLoader;
-import com.android.ddmuilib.InfoPanel;
-import com.android.ddmuilib.NativeHeapPanel;
-import com.android.ddmuilib.ScreenShotDialog;
-import com.android.ddmuilib.SysinfoPanel;
-import com.android.ddmuilib.TablePanel;
-import com.android.ddmuilib.ThreadPanel;
-import com.android.ddmuilib.actions.ToolItemAction;
-import com.android.ddmuilib.explorer.DeviceExplorer;
-import com.android.ddmuilib.log.event.EventLogPanel;
-import com.android.ddmuilib.logcat.LogColors;
-import com.android.ddmuilib.logcat.LogFilter;
-import com.android.ddmuilib.logcat.LogPanel;
-import com.android.ddmuilib.logcat.LogPanel.ILogFilterStorageManager;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTError;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.events.MenuAdapter;
-import org.eclipse.swt.events.MenuEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.ShellEvent;
-import org.eclipse.swt.events.ShellListener;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.layout.FormLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.MenuItem;
-import org.eclipse.swt.widgets.MessageBox;
-import org.eclipse.swt.widgets.Sash;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-import org.eclipse.swt.widgets.ToolBar;
-import org.eclipse.swt.widgets.ToolItem;
-
-import java.io.File;
-import java.util.ArrayList;
-
-/**
- * This acts as the UI builder. This cannot be its own thread since this prevent using AWT in an
- * SWT application. So this class mainly builds the ui, and manages communication between the panels
- * when {@link Device} / {@link Client} selection changes.
- */
-public class UIThread implements IUiSelectionListener {
-    /*
-     * UI tab panel definitions. The constants here must match up with the array
-     * indices in mPanels. PANEL_CLIENT_LIST is a "virtual" panel representing
-     * the client list.
-     */
-    public static final int PANEL_CLIENT_LIST = -1;
-
-    public static final int PANEL_INFO = 0;
-
-    public static final int PANEL_THREAD = 1;
-
-    public static final int PANEL_HEAP = 2;
-
-    public static final int PANEL_NATIVE_HEAP = 3;
-
-    private static final int PANEL_ALLOCATIONS = 4;
-
-    private static final int PANEL_SYSINFO = 5;
-
-    private static final int PANEL_COUNT = 6;
-
-    /** Content is setup in the constructor */
-    private static TablePanel[] mPanels = new TablePanel[PANEL_COUNT];
-
-    private static final String[] mPanelNames = new String[] {
-            "Info", "Threads", "VM Heap", "Native Heap", "Allocation Tracker", "Sysinfo"
-    };
-
-    private static final String[] mPanelTips = new String[] {
-            "Client information", "Thread status", "VM heap status",
-            "Native heap status", "Allocation Tracker", "Sysinfo graphs"
-    };
-
-    private static final String PREFERENCE_LOGSASH =
-        "logSashLocation"; //$NON-NLS-1$
-    private static final String PREFERENCE_SASH =
-        "sashLocation"; //$NON-NLS-1$
-
-    private static final String PREFS_COL_TIME =
-        "logcat.time"; //$NON-NLS-1$
-    private static final String PREFS_COL_LEVEL =
-        "logcat.level"; //$NON-NLS-1$
-    private static final String PREFS_COL_PID =
-        "logcat.pid"; //$NON-NLS-1$
-    private static final String PREFS_COL_TAG =
-        "logcat.tag"; //$NON-NLS-1$
-    private static final String PREFS_COL_MESSAGE =
-        "logcat.message"; //$NON-NLS-1$
-
-    private static final String PREFS_FILTERS = "logcat.filter"; //$NON-NLS-1$
-
-    // singleton instance
-    private static UIThread mInstance = new UIThread();
-
-    // our display
-    private Display mDisplay;
-
-    // the table we show in the left-hand pane
-    private DevicePanel mDevicePanel;
-
-    private Device mCurrentDevice = null;
-    private Client mCurrentClient = null;
-
-    // status line at the bottom of the app window
-    private Label mStatusLine;
-
-    // some toolbar items we need to update
-    private ToolItem mTBShowThreadUpdates;
-    private ToolItem mTBShowHeapUpdates;
-    private ToolItem mTBHalt;
-    private ToolItem mTBCauseGc;
-
-    private ImageLoader mDdmsImageLoader;
-    private ImageLoader mDdmuiLibImageLoader; 
-
-    private final class FilterStorage implements ILogFilterStorageManager {
-
-        public LogFilter[] getFilterFromStore() {
-            String filterPrefs = PrefsDialog.getStore().getString(
-                    PREFS_FILTERS);
-
-            // split in a string per filter
-            String[] filters = filterPrefs.split("\\|"); //$NON-NLS-1$
-
-            ArrayList<LogFilter> list =
-                new ArrayList<LogFilter>(filters.length);
-
-            for (String f : filters) {
-                if (f.length() > 0) {
-                    LogFilter logFilter = new LogFilter();
-                    if (logFilter.loadFromString(f)) {
-                        list.add(logFilter);
-                    }
-                }
-            }
-
-            return list.toArray(new LogFilter[list.size()]);
-        }
-
-        public void saveFilters(LogFilter[] filters) {
-            StringBuilder sb = new StringBuilder();
-            for (LogFilter f : filters) {
-                String filterString = f.toString();
-                sb.append(filterString);
-                sb.append('|');
-            }
-
-            PrefsDialog.getStore().setValue(PREFS_FILTERS, sb.toString());
-        }
-
-        public boolean requiresDefaultFilter() {
-            return true;
-        }
-    }
-
-
-    private LogPanel mLogPanel;
-
-    private ToolItemAction mCreateFilterAction;
-    private ToolItemAction mDeleteFilterAction;
-    private ToolItemAction mEditFilterAction;
-    private ToolItemAction mExportAction;
-    private ToolItemAction mClearAction;
-
-    private ToolItemAction[] mLogLevelActions;
-    private String[] mLogLevelIcons = {
-            "v.png", //$NON-NLS-1S
-            "d.png", //$NON-NLS-1S
-            "i.png", //$NON-NLS-1S
-            "w.png", //$NON-NLS-1S
-            "e.png", //$NON-NLS-1S
-    };
-
-    protected Clipboard mClipboard;
-
-    private MenuItem mCopyMenuItem;
-
-    private MenuItem mSelectAllMenuItem;
-
-    private TableFocusListener mTableListener;
-
-    private DeviceExplorer mExplorer = null;
-    private Shell mExplorerShell = null;
-
-    private EmulatorControlPanel mEmulatorPanel;
-    
-    private EventLogPanel mEventLogPanel;
-
-    private class TableFocusListener implements ITableFocusListener {
-
-        private IFocusedTableActivator mCurrentActivator;
-
-        public void focusGained(IFocusedTableActivator activator) {
-            mCurrentActivator = activator;
-            if (mCopyMenuItem.isDisposed() == false) {
-                mCopyMenuItem.setEnabled(true);
-                mSelectAllMenuItem.setEnabled(true);
-            }
-        }
-
-        public void focusLost(IFocusedTableActivator activator) {
-            // if we move from one table to another, it's unclear
-            // if the old table lose its focus before the new
-            // one gets the focus, so we need to check.
-            if (activator == mCurrentActivator) {
-                activator = null;
-                if (mCopyMenuItem.isDisposed() == false) {
-                    mCopyMenuItem.setEnabled(false);
-                    mSelectAllMenuItem.setEnabled(false);
-                }
-            }
-        }
-
-        public void copy(Clipboard clipboard) {
-            if (mCurrentActivator != null) {
-                mCurrentActivator.copy(clipboard);
-            }
-        }
-
-        public void selectAll() {
-            if (mCurrentActivator != null) {
-                mCurrentActivator.selectAll();
-            }
-        }
-
-    }
-
-
-    /**
-     * Generic constructor.
-     */
-    private UIThread() {
-        mPanels[PANEL_INFO] = new InfoPanel();
-        mPanels[PANEL_THREAD] = new ThreadPanel();
-        mPanels[PANEL_HEAP] = new HeapPanel();
-        if (PrefsDialog.getStore().getBoolean(PrefsDialog.SHOW_NATIVE_HEAP)) {
-            mPanels[PANEL_NATIVE_HEAP] = new NativeHeapPanel();
-        } else {
-            mPanels[PANEL_NATIVE_HEAP] = null;
-        }
-        mPanels[PANEL_ALLOCATIONS] = new AllocationPanel();
-        mPanels[PANEL_SYSINFO] = new SysinfoPanel();
-    }
-
-    /**
-     * Get singleton instance of the UI thread.
-     */
-    public static UIThread getInstance() {
-        return mInstance;
-    }
-
-    /**
-     * Return the Display. Don't try this unless you're in the UI thread.
-     */
-    public Display getDisplay() {
-        return mDisplay;
-    }
-
-    public void asyncExec(Runnable r) {
-        if (mDisplay != null && mDisplay.isDisposed() == false) {
-            mDisplay.asyncExec(r);
-        }
-    }
-
-    /** returns the IPreferenceStore */
-    public IPreferenceStore getStore() {
-        return PrefsDialog.getStore();
-    }
-
-    /**
-     * Create SWT objects and drive the user interface event loop.
-     */
-    public void runUI() {
-        Display.setAppName("ddms");
-        mDisplay = new Display();
-        Shell shell = new Shell(mDisplay);
-
-        // create the image loaders for DDMS and DDMUILIB
-        mDdmsImageLoader = new ImageLoader(this.getClass());
-        mDdmuiLibImageLoader = new ImageLoader(DevicePanel.class);
-        
-        shell.setImage(ImageHelper.loadImage(mDdmsImageLoader, mDisplay,
-                "ddms-icon.png", //$NON-NLS-1$
-                100, 50, null));
-
-        Log.setLogOutput(new ILogOutput() {
-            public void printAndPromptLog(final LogLevel logLevel, final String tag,
-                    final String message) {
-                Log.printLog(logLevel, tag, message);
-                // dialog box only run in UI thread..
-                mDisplay.asyncExec(new Runnable() {
-                    public void run() {
-                        Shell shell = mDisplay.getActiveShell();
-                        if (logLevel == LogLevel.ERROR) {
-                            MessageDialog.openError(shell, tag, message);
-                        } else {
-                            MessageDialog.openWarning(shell, tag, message);
-                        }
-                    }
-                });
-            }
-
-            public void printLog(LogLevel logLevel, String tag, String message) {
-                Log.printLog(logLevel, tag, message);
-            }
-        });
-
-        // [try to] ensure ADB is running
-        String adbLocation = System.getProperty("com.android.ddms.bindir"); //$NON-NLS-1$
-        if (adbLocation != null && adbLocation.length() != 0) {
-            adbLocation += File.separator + "adb"; //$NON-NLS-1$
-        } else {
-            adbLocation = "adb"; //$NON-NLS-1$
-        }
-
-        AndroidDebugBridge.init(true /* debugger support */);
-        AndroidDebugBridge.createBridge(adbLocation, true /* forceNewBridge */);
-
-        shell.setText("Dalvik Debug Monitor");
-        setConfirmClose(shell);
-        createMenus(shell);
-        createWidgets(shell);
-
-        shell.pack();
-        setSizeAndPosition(shell);
-        shell.open();
-
-        Log.d("ddms", "UI is up");
-
-        while (!shell.isDisposed()) {
-            if (!mDisplay.readAndDispatch())
-                mDisplay.sleep();
-        }
-        mLogPanel.stopLogCat(true);
-
-        mDevicePanel.dispose();
-        for (TablePanel panel : mPanels) {
-            if (panel != null) {
-                panel.dispose();
-            }
-        }
-
-        mDisplay.dispose();
-        Log.d("ddms", "UI is down");
-    }
-
-    /**
-     * Set the size and position of the main window from the preference, and
-     * setup listeners for control events (resize/move of the window)
-     */
-    private void setSizeAndPosition(final Shell shell) {
-        shell.setMinimumSize(400, 200);
-
-        // get the x/y and w/h from the prefs
-        PreferenceStore prefs = PrefsDialog.getStore();
-        int x = prefs.getInt(PrefsDialog.SHELL_X);
-        int y = prefs.getInt(PrefsDialog.SHELL_Y);
-        int w = prefs.getInt(PrefsDialog.SHELL_WIDTH);
-        int h = prefs.getInt(PrefsDialog.SHELL_HEIGHT);
-
-        // check that we're not out of the display area
-        Rectangle rect = mDisplay.getClientArea();
-        // first check the width/height
-        if (w > rect.width) {
-            w = rect.width;
-            prefs.setValue(PrefsDialog.SHELL_WIDTH, rect.width);
-        }
-        if (h > rect.height) {
-            h = rect.height;
-            prefs.setValue(PrefsDialog.SHELL_HEIGHT, rect.height);
-        }
-        // then check x. Make sure the left corner is in the screen
-        if (x < rect.x) {
-            x = rect.x;
-            prefs.setValue(PrefsDialog.SHELL_X, rect.x);
-        } else if (x >= rect.x + rect.width) {
-            x = rect.x + rect.width - w;
-            prefs.setValue(PrefsDialog.SHELL_X, rect.x);
-        }
-        // then check y. Make sure the left corner is in the screen
-        if (y < rect.y) {
-            y = rect.y;
-            prefs.setValue(PrefsDialog.SHELL_Y, rect.y);
-        } else if (y >= rect.y + rect.height) {
-            y = rect.y + rect.height - h;
-            prefs.setValue(PrefsDialog.SHELL_Y, rect.y);
-        }
-
-        // now we can set the location/size
-        shell.setBounds(x, y, w, h);
-
-        // add listener for resize/move
-        shell.addControlListener(new ControlListener() {
-            public void controlMoved(ControlEvent e) {
-                // get the new x/y
-                Rectangle rect = shell.getBounds();
-                // store in pref file
-                PreferenceStore prefs = PrefsDialog.getStore();
-                prefs.setValue(PrefsDialog.SHELL_X, rect.x);
-                prefs.setValue(PrefsDialog.SHELL_Y, rect.y);
-            }
-
-            public void controlResized(ControlEvent e) {
-                // get the new w/h
-                Rectangle rect = shell.getBounds();
-                // store in pref file
-                PreferenceStore prefs = PrefsDialog.getStore();
-                prefs.setValue(PrefsDialog.SHELL_WIDTH, rect.width);
-                prefs.setValue(PrefsDialog.SHELL_HEIGHT, rect.height);
-            }
-        });
-    }
-
-    /**
-     * Set the size and position of the file explorer window from the
-     * preference, and setup listeners for control events (resize/move of
-     * the window)
-     */
-    private void setExplorerSizeAndPosition(final Shell shell) {
-        shell.setMinimumSize(400, 200);
-
-        // get the x/y and w/h from the prefs
-        PreferenceStore prefs = PrefsDialog.getStore();
-        int x = prefs.getInt(PrefsDialog.EXPLORER_SHELL_X);
-        int y = prefs.getInt(PrefsDialog.EXPLORER_SHELL_Y);
-        int w = prefs.getInt(PrefsDialog.EXPLORER_SHELL_WIDTH);
-        int h = prefs.getInt(PrefsDialog.EXPLORER_SHELL_HEIGHT);
-
-        // check that we're not out of the display area
-        Rectangle rect = mDisplay.getClientArea();
-        // first check the width/height
-        if (w > rect.width) {
-            w = rect.width;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_WIDTH, rect.width);
-        }
-        if (h > rect.height) {
-            h = rect.height;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_HEIGHT, rect.height);
-        }
-        // then check x. Make sure the left corner is in the screen
-        if (x < rect.x) {
-            x = rect.x;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_X, rect.x);
-        } else if (x >= rect.x + rect.width) {
-            x = rect.x + rect.width - w;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_X, rect.x);
-        }
-        // then check y. Make sure the left corner is in the screen
-        if (y < rect.y) {
-            y = rect.y;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_Y, rect.y);
-        } else if (y >= rect.y + rect.height) {
-            y = rect.y + rect.height - h;
-            prefs.setValue(PrefsDialog.EXPLORER_SHELL_Y, rect.y);
-        }
-
-        // now we can set the location/size
-        shell.setBounds(x, y, w, h);
-
-        // add listener for resize/move
-        shell.addControlListener(new ControlListener() {
-            public void controlMoved(ControlEvent e) {
-                // get the new x/y
-                Rectangle rect = shell.getBounds();
-                // store in pref file
-                PreferenceStore prefs = PrefsDialog.getStore();
-                prefs.setValue(PrefsDialog.EXPLORER_SHELL_X, rect.x);
-                prefs.setValue(PrefsDialog.EXPLORER_SHELL_Y, rect.y);
-            }
-
-            public void controlResized(ControlEvent e) {
-                // get the new w/h
-                Rectangle rect = shell.getBounds();
-                // store in pref file
-                PreferenceStore prefs = PrefsDialog.getStore();
-                prefs.setValue(PrefsDialog.EXPLORER_SHELL_WIDTH, rect.width);
-                prefs.setValue(PrefsDialog.EXPLORER_SHELL_HEIGHT, rect.height);
-            }
-        });
-    }
-
-    /*
-     * Set the confirm-before-close dialog. TODO: enable/disable in prefs. TODO:
-     * is there any point in having this?
-     */
-    private void setConfirmClose(final Shell shell) {
-        if (true)
-            return;
-
-        shell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-                int style = SWT.APPLICATION_MODAL | SWT.YES | SWT.NO;
-                MessageBox msgBox = new MessageBox(shell, style);
-                msgBox.setText("Confirm...");
-                msgBox.setMessage("Close DDM?");
-                event.doit = (msgBox.open() == SWT.YES);
-            }
-        });
-    }
-
-    /*
-     * Create the menu bar and items.
-     */
-    private void createMenus(final Shell shell) {
-        // create menu bar
-        Menu menuBar = new Menu(shell, SWT.BAR);
-
-        // create top-level items
-        MenuItem fileItem = new MenuItem(menuBar, SWT.CASCADE);
-        fileItem.setText("&File");
-        MenuItem editItem = new MenuItem(menuBar, SWT.CASCADE);
-        editItem.setText("&Edit");
-        MenuItem actionItem = new MenuItem(menuBar, SWT.CASCADE);
-        actionItem.setText("&Actions");
-        MenuItem deviceItem = new MenuItem(menuBar, SWT.CASCADE);
-        deviceItem.setText("&Device");
-        MenuItem helpItem = new MenuItem(menuBar, SWT.CASCADE);
-        helpItem.setText("&Help");
-
-        // create top-level menus
-        Menu fileMenu = new Menu(menuBar);
-        fileItem.setMenu(fileMenu);
-        Menu editMenu = new Menu(menuBar);
-        editItem.setMenu(editMenu);
-        Menu actionMenu = new Menu(menuBar);
-        actionItem.setMenu(actionMenu);
-        Menu deviceMenu = new Menu(menuBar);
-        deviceItem.setMenu(deviceMenu);
-        Menu helpMenu = new Menu(menuBar);
-        helpItem.setMenu(helpMenu);
-
-        MenuItem item;
-
-        // create File menu items
-        item = new MenuItem(fileMenu, SWT.NONE);
-        item.setText("&Preferences...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                PrefsDialog.run(shell);
-            }
-        });
-
-        item = new MenuItem(fileMenu, SWT.NONE);
-        item.setText("&Static Port Configuration...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                StaticPortConfigDialog dlg = new StaticPortConfigDialog(shell);
-                dlg.open();
-            }
-        });
-
-        new MenuItem(fileMenu, SWT.SEPARATOR);
-
-        item = new MenuItem(fileMenu, SWT.NONE);
-        item.setText("E&xit\tCtrl-Q");
-        item.setAccelerator('Q' | SWT.CONTROL);
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                shell.close();
-            }
-        });
-
-        // create edit menu items
-        mCopyMenuItem = new MenuItem(editMenu, SWT.NONE);
-        mCopyMenuItem.setText("&Copy\tCtrl-C");
-        mCopyMenuItem.setAccelerator('C' | SWT.COMMAND);
-        mCopyMenuItem.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mTableListener.copy(mClipboard);
-            }
-        });
-
-        new MenuItem(editMenu, SWT.SEPARATOR);
-
-        mSelectAllMenuItem = new MenuItem(editMenu, SWT.NONE);
-        mSelectAllMenuItem.setText("Select &All\tCtrl-A");
-        mSelectAllMenuItem.setAccelerator('A' | SWT.COMMAND);
-        mSelectAllMenuItem.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mTableListener.selectAll();
-            }
-        });
-
-        // create Action menu items
-        // TODO: this should come with a confirmation dialog
-        final MenuItem actionHaltItem = new MenuItem(actionMenu, SWT.NONE);
-        actionHaltItem.setText("&Halt VM");
-        actionHaltItem.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mDevicePanel.killSelectedClient();
-            }
-        });
-
-        final MenuItem actionCauseGcItem = new MenuItem(actionMenu, SWT.NONE);
-        actionCauseGcItem.setText("Cause &GC");
-        actionCauseGcItem.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mDevicePanel.forceGcOnSelectedClient();
-            }
-        });
-
-        // configure Action items based on current state
-        actionMenu.addMenuListener(new MenuAdapter() {
-            @Override
-            public void menuShown(MenuEvent e) {
-                actionHaltItem.setEnabled(mTBHalt.getEnabled());
-                actionCauseGcItem.setEnabled(mTBCauseGc.getEnabled());
-            }
-        });
-
-        // create Device menu items
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("&Screen capture...\tCTrl-S");
-        item.setAccelerator('S' | SWT.CONTROL);
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mCurrentDevice != null) {
-                    ScreenShotDialog dlg = new ScreenShotDialog(shell);
-                    dlg.open(mCurrentDevice);
-                }
-            }
-        });
-
-        new MenuItem(deviceMenu, SWT.SEPARATOR);
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("File Explorer...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                createFileExplorer();
-            }
-        });
-
-        new MenuItem(deviceMenu, SWT.SEPARATOR);
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("Show &process status...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                DeviceCommandDialog dlg;
-                dlg = new DeviceCommandDialog("ps -x", "ps-x.txt", shell);
-                dlg.open(mCurrentDevice);
-            }
-        });
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("Dump &device state...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                DeviceCommandDialog dlg;
-                dlg = new DeviceCommandDialog("/system/bin/dumpstate /proc/self/fd/0",
-                        "device-state.txt", shell);
-                dlg.open(mCurrentDevice);
-            }
-        });
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("Dump &app state...");
-        item.setEnabled(false);
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                DeviceCommandDialog dlg;
-                dlg = new DeviceCommandDialog("dumpsys", "app-state.txt", shell);
-                dlg.open(mCurrentDevice);
-            }
-        });
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("Dump &radio state...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                DeviceCommandDialog dlg;
-                dlg = new DeviceCommandDialog(
-                        "cat /data/logs/radio.4 /data/logs/radio.3"
-                        + " /data/logs/radio.2 /data/logs/radio.1"
-                        + " /data/logs/radio",
-                        "radio-state.txt", shell);
-                dlg.open(mCurrentDevice);
-            }
-        });
-
-        item = new MenuItem(deviceMenu, SWT.NONE);
-        item.setText("Run &logcat...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                DeviceCommandDialog dlg;
-                dlg = new DeviceCommandDialog("logcat '*:d jdwp:w'", "log.txt",
-                        shell);
-                dlg.open(mCurrentDevice);
-            }
-        });
-
-        // create Help menu items
-        item = new MenuItem(helpMenu, SWT.NONE);
-        item.setText("&Contents...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                int style = SWT.APPLICATION_MODAL | SWT.OK;
-                MessageBox msgBox = new MessageBox(shell, style);
-                msgBox.setText("Help!");
-                msgBox.setMessage("Help wanted.");
-                msgBox.open();
-            }
-        });
-
-        new MenuItem(helpMenu, SWT.SEPARATOR);
-
-        item = new MenuItem(helpMenu, SWT.NONE);
-        item.setText("&About...");
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                AboutDialog dlg = new AboutDialog(shell);
-                dlg.open();
-            }
-        });
-
-        // tell the shell to use this menu
-        shell.setMenuBar(menuBar);
-    }
-
-    /*
-     * Create the widgets in the main application window. The basic layout is a
-     * two-panel sash, with a scrolling list of VMs on the left and detailed
-     * output for a single VM on the right.
-     */
-    private void createWidgets(final Shell shell) {
-        Color darkGray = shell.getDisplay().getSystemColor(SWT.COLOR_DARK_GRAY);
-
-        /*
-         * Create three areas: tool bar, split panels, status line
-         */
-        shell.setLayout(new GridLayout(1, false));
-
-        // 1. panel area
-        final Composite panelArea = new Composite(shell, SWT.BORDER);
-
-        // make the panel area absorb all space
-        panelArea.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // 2. status line.
-        mStatusLine = new Label(shell, SWT.NONE);
-
-        // make status line extend all the way across
-        mStatusLine.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mStatusLine.setText("Initializing...");
-
-        /*
-         * Configure the split-panel area.
-         */
-        final PreferenceStore prefs = PrefsDialog.getStore();
-
-        Composite topPanel = new Composite(panelArea, SWT.NONE);
-        final Sash sash = new Sash(panelArea, SWT.HORIZONTAL);
-        sash.setBackground(darkGray);
-        Composite bottomPanel = new Composite(panelArea, SWT.NONE);
-
-        panelArea.setLayout(new FormLayout());
-
-        createTopPanel(topPanel, darkGray);
-        createBottomPanel(bottomPanel);
-
-        // form layout data
-        FormData data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(sash, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        topPanel.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        if (prefs != null && prefs.contains(PREFERENCE_LOGSASH)) {
-            sashData.top = new FormAttachment(0, prefs.getInt(
-                    PREFERENCE_LOGSASH));
-        } else {
-            sashData.top = new FormAttachment(50,0); // 50% across
-        }
-        sashData.left = new FormAttachment(0, 0);
-        sashData.right = new FormAttachment(100, 0);
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(sash, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        bottomPanel.setLayoutData(data);
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = panelArea.getClientArea();
-                int bottom = panelRect.height - sashRect.height - 100;
-                e.y = Math.max(Math.min(e.y, bottom), 100);
-                if (e.y != sashRect.y) {
-                    sashData.top = new FormAttachment(0, e.y);
-                    prefs.setValue(PREFERENCE_LOGSASH, e.y);
-                    panelArea.layout();
-                }
-            }
-        });
-
-        // add a global focus listener for all the tables
-        mTableListener = new TableFocusListener();
-
-        // now set up the listener in the various panels
-        mLogPanel.setTableFocusListener(mTableListener);
-        mEventLogPanel.setTableFocusListener(mTableListener);
-        for (TablePanel p : mPanels) {
-            if (p != null) {
-                p.setTableFocusListener(mTableListener);
-            }
-        }
-        
-        mStatusLine.setText("");
-    }
-
-    /*
-     * Populate the tool bar.
-     */
-    private void createDevicePanelToolBar(ToolBar toolBar) {
-        Display display = toolBar.getDisplay();
-        
-        // add "show thread updates" button
-        mTBShowThreadUpdates = new ToolItem(toolBar, SWT.CHECK);
-        mTBShowThreadUpdates.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, display,
-                DevicePanel.ICON_THREAD, DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mTBShowThreadUpdates.setToolTipText("Show thread updates");
-        mTBShowThreadUpdates.setEnabled(false);
-        mTBShowThreadUpdates.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mCurrentClient != null) {
-                    // boolean status = ((ToolItem)e.item).getSelection();
-                    // invert previous state
-                    boolean enable = !mCurrentClient.isThreadUpdateEnabled();
-
-                    mCurrentClient.setThreadUpdateEnabled(enable);
-                } else {
-                    e.doit = false; // this has no effect?
-                }
-            }
-        });
-
-        // add "show heap updates" button
-        mTBShowHeapUpdates = new ToolItem(toolBar, SWT.CHECK);
-        mTBShowHeapUpdates.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, display,
-                DevicePanel.ICON_HEAP, DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mTBShowHeapUpdates.setToolTipText("Show heap updates");
-        mTBShowHeapUpdates.setEnabled(false);
-        mTBShowHeapUpdates.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mCurrentClient != null) {
-                    // boolean status = ((ToolItem)e.item).getSelection();
-                    // invert previous state
-                    boolean enable = !mCurrentClient.isHeapUpdateEnabled();
-                    mCurrentClient.setHeapUpdateEnabled(enable);
-                } else {
-                    e.doit = false; // this has no effect?
-                }
-            }
-        });
-
-        new ToolItem(toolBar, SWT.SEPARATOR);
-
-        // add "kill VM" button; need to make this visually distinct from
-        // the status update buttons
-        mTBHalt = new ToolItem(toolBar, SWT.PUSH);
-        mTBHalt.setToolTipText("Halt the target VM");
-        mTBHalt.setEnabled(false);
-        mTBHalt.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, display,
-                DevicePanel.ICON_HALT, DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mTBHalt.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mDevicePanel.killSelectedClient();
-            }
-        });
-        
-        new ToolItem(toolBar, SWT.SEPARATOR);
-
-        // add "cause GC" button
-        mTBCauseGc = new ToolItem(toolBar, SWT.PUSH);
-        mTBCauseGc.setToolTipText("Cause an immediate GC in the target VM");
-        mTBCauseGc.setEnabled(false);
-        mTBCauseGc.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, display,
-                DevicePanel.ICON_GC, DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mTBCauseGc.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mDevicePanel.forceGcOnSelectedClient();
-            }
-        });
-
-       toolBar.pack();
-    }
-
-    private void createTopPanel(final Composite comp, Color darkGray) {
-        final PreferenceStore prefs = PrefsDialog.getStore();
-
-        comp.setLayout(new FormLayout());
-
-        Composite leftPanel = new Composite(comp, SWT.NONE);
-        final Sash sash = new Sash(comp, SWT.VERTICAL);
-        sash.setBackground(darkGray);
-        Composite rightPanel = new Composite(comp, SWT.NONE);
-
-        createLeftPanel(leftPanel);
-        createRightPanel(rightPanel);
-
-        FormData data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(sash, 0);
-        leftPanel.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        sashData.top = new FormAttachment(0, 0);
-        sashData.bottom = new FormAttachment(100, 0);
-        if (prefs != null && prefs.contains(PREFERENCE_SASH)) {
-            sashData.left = new FormAttachment(0, prefs.getInt(
-                    PREFERENCE_SASH));
-        } else {
-            // position the sash 380 from the right instead of x% (done by using
-            // FormAttachment(x, 0)) in order to keep the sash at the same
-            // position
-            // from the left when the window is resized.
-            // 380px is just enough to display the left table with no horizontal
-            // scrollbar with the default font.
-            sashData.left = new FormAttachment(0, 380);
-        }
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(sash, 0);
-        data.right = new FormAttachment(100, 0);
-        rightPanel.setLayoutData(data);
-
-        final int minPanelWidth = 60;
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = comp.getClientArea();
-                int right = panelRect.width - sashRect.width - minPanelWidth;
-                e.x = Math.max(Math.min(e.x, right), minPanelWidth);
-                if (e.x != sashRect.x) {
-                    sashData.left = new FormAttachment(0, e.x);
-                    prefs.setValue(PREFERENCE_SASH, e.x);
-                    comp.layout();
-                }
-            }
-        });
-    }
-
-    private void createBottomPanel(final Composite comp) {
-        final PreferenceStore prefs = PrefsDialog.getStore();
-
-        // create clipboard
-        Display display = comp.getDisplay();
-        mClipboard = new Clipboard(display);
-
-        LogColors colors = new LogColors();
-
-        colors.infoColor = new Color(display, 0, 127, 0);
-        colors.debugColor = new Color(display, 0, 0, 127);
-        colors.errorColor = new Color(display, 255, 0, 0);
-        colors.warningColor = new Color(display, 255, 127, 0);
-        colors.verboseColor = new Color(display, 0, 0, 0);
-
-        // set the preferences names
-        LogPanel.PREFS_TIME = PREFS_COL_TIME;
-        LogPanel.PREFS_LEVEL = PREFS_COL_LEVEL;
-        LogPanel.PREFS_PID = PREFS_COL_PID;
-        LogPanel.PREFS_TAG = PREFS_COL_TAG;
-        LogPanel.PREFS_MESSAGE = PREFS_COL_MESSAGE;
-
-        comp.setLayout(new GridLayout(1, false));
-
-        ToolBar toolBar = new ToolBar(comp, SWT.HORIZONTAL);
-
-        mCreateFilterAction = new ToolItemAction(toolBar, SWT.PUSH);
-        mCreateFilterAction.item.setToolTipText("Create Filter");
-        mCreateFilterAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                "add.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mCreateFilterAction.item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mLogPanel.addFilter();
-            }
-        });
-
-        mEditFilterAction = new ToolItemAction(toolBar, SWT.PUSH);
-        mEditFilterAction.item.setToolTipText("Edit Filter");
-        mEditFilterAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                "edit.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mEditFilterAction.item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mLogPanel.editFilter();
-            }
-        });
-
-        mDeleteFilterAction = new ToolItemAction(toolBar, SWT.PUSH);
-        mDeleteFilterAction.item.setToolTipText("Delete Filter");
-        mDeleteFilterAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                "delete.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mDeleteFilterAction.item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mLogPanel.deleteFilter();
-            }
-        });
-
-
-        new ToolItem(toolBar, SWT.SEPARATOR);
-
-        LogLevel[] levels = LogLevel.values();
-        mLogLevelActions = new ToolItemAction[mLogLevelIcons.length];
-        for (int i = 0 ; i < mLogLevelActions.length; i++) {
-            String name = levels[i].getStringValue();
-            final ToolItemAction newAction = new ToolItemAction(toolBar, SWT.CHECK);
-            mLogLevelActions[i] = newAction;
-            //newAction.item.setText(name);
-            newAction.item.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    // disable the other actions and record current index
-                    for (int i = 0 ; i < mLogLevelActions.length; i++) {
-                        ToolItemAction a = mLogLevelActions[i];
-                        if (a == newAction) {
-                            a.setChecked(true);
-
-                            // set the log level
-                            mLogPanel.setCurrentFilterLogLevel(i+2);
-                        } else {
-                            a.setChecked(false);
-                        }
-                    }
-                }
-            });
-
-            newAction.item.setToolTipText(name);
-            newAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                    mLogLevelIcons[i],
-                    DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        }
-
-        new ToolItem(toolBar, SWT.SEPARATOR);
-
-        mClearAction = new ToolItemAction(toolBar, SWT.PUSH);
-        mClearAction.item.setToolTipText("Clear Log");
-        
-        mClearAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                "clear.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mClearAction.item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mLogPanel.clear();
-            }
-        });
-
-        new ToolItem(toolBar, SWT.SEPARATOR);
-
-        mExportAction = new ToolItemAction(toolBar, SWT.PUSH);
-        mExportAction.item.setToolTipText("Export Selection As Text...");
-        mExportAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, mDisplay,
-                "save.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        mExportAction.item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mLogPanel.save();
-            }
-        });
-
-
-        toolBar.pack();
-
-        // now create the log view
-        mLogPanel = new LogPanel(new ImageLoader(LogPanel.class), colors, new FilterStorage(),
-                LogPanel.FILTER_MANUAL);
-
-        mLogPanel.setActions(mDeleteFilterAction, mEditFilterAction, mLogLevelActions);
-
-        String colMode = prefs.getString(PrefsDialog.LOGCAT_COLUMN_MODE);
-        if (PrefsDialog.LOGCAT_COLUMN_MODE_AUTO.equals(colMode)) {
-            mLogPanel.setColumnMode(LogPanel.COLUMN_MODE_AUTO);
-        }
-
-        String fontStr = PrefsDialog.getStore().getString(PrefsDialog.LOGCAT_FONT);
-        if (fontStr != null) {
-            try {
-                FontData fdat = new FontData(fontStr);
-                mLogPanel.setFont(new Font(display, fdat));
-            } catch (IllegalArgumentException e) {
-                // Looks like fontStr isn't a valid font representation.
-                // We do nothing in this case, the logcat view will use the default font.
-            } catch (SWTError e2) {
-                // Looks like the Font() constructor failed.
-                // We do nothing in this case, the logcat view will use the default font.
-            }
-        }
-
-        mLogPanel.createPanel(comp);
-
-        // and start the logcat
-        mLogPanel.startLogCat(mCurrentDevice);
-    }
-
-    /*
-     * Create the contents of the left panel: a table of VMs.
-     */
-    private void createLeftPanel(final Composite comp) {
-        comp.setLayout(new GridLayout(1, false));
-        ToolBar toolBar = new ToolBar(comp, SWT.HORIZONTAL | SWT.RIGHT | SWT.WRAP);
-        toolBar.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        createDevicePanelToolBar(toolBar);
-
-        Composite c = new Composite(comp, SWT.NONE);
-        c.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        mDevicePanel = new DevicePanel(new ImageLoader(DevicePanel.class), true /* showPorts */);
-        mDevicePanel.createPanel(c);
-
-        // add ourselves to the device panel selection listener
-        mDevicePanel.addSelectionListener(this);
-    }
-
-    /*
-     * Create the contents of the right panel: tabs with VM information.
-     */
-    private void createRightPanel(final Composite comp) {
-        TabItem item;
-        TabFolder tabFolder;
-
-        comp.setLayout(new FillLayout());
-
-        tabFolder = new TabFolder(comp, SWT.NONE);
-
-        for (int i = 0; i < mPanels.length; i++) {
-            if (mPanels[i] != null) {
-                item = new TabItem(tabFolder, SWT.NONE);
-                item.setText(mPanelNames[i]);
-                item.setToolTipText(mPanelTips[i]);
-                item.setControl(mPanels[i].createPanel(tabFolder));
-            }
-        }
-
-        // add the emulator control panel to the folders.
-        item = new TabItem(tabFolder, SWT.NONE);
-        item.setText("Emulator Control");
-        item.setToolTipText("Emulator Control Panel");
-        mEmulatorPanel = new EmulatorControlPanel(mDdmuiLibImageLoader);
-        item.setControl(mEmulatorPanel.createPanel(tabFolder));
-
-        // add the event log panel to the folders.
-        item = new TabItem(tabFolder, SWT.NONE);
-        item.setText("Event Log");
-        item.setToolTipText("Event Log");
-        
-        // create the composite that will hold the toolbar and the event log panel.
-        Composite eventLogTopComposite = new Composite(tabFolder, SWT.NONE);
-        item.setControl(eventLogTopComposite);
-        eventLogTopComposite.setLayout(new GridLayout(1, false));
-        
-        // create the toolbar and the actions
-        ToolBar toolbar = new ToolBar(eventLogTopComposite, SWT.HORIZONTAL);
-        toolbar.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        ToolItemAction optionsAction = new ToolItemAction(toolbar, SWT.PUSH);
-        optionsAction.item.setToolTipText("Opens the options panel");
-        optionsAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, comp.getDisplay(),
-                "edit.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-
-        ToolItemAction clearAction = new ToolItemAction(toolbar, SWT.PUSH);
-        clearAction.item.setToolTipText("Clears the event log");
-        clearAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, comp.getDisplay(),
-                "clear.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-        
-        new ToolItem(toolbar, SWT.SEPARATOR);
-
-        ToolItemAction saveAction = new ToolItemAction(toolbar, SWT.PUSH);
-        saveAction.item.setToolTipText("Saves the event log");
-        saveAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, comp.getDisplay(),
-                "save.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-
-        ToolItemAction loadAction = new ToolItemAction(toolbar, SWT.PUSH);
-        loadAction.item.setToolTipText("Loads an event log");
-        loadAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, comp.getDisplay(),
-                "load.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-
-        ToolItemAction importBugAction = new ToolItemAction(toolbar, SWT.PUSH);
-        importBugAction.item.setToolTipText("Imports a bug report");
-        importBugAction.item.setImage(ImageHelper.loadImage(mDdmuiLibImageLoader, comp.getDisplay(),
-                "importBug.png", //$NON-NLS-1$
-                DevicePanel.ICON_WIDTH, DevicePanel.ICON_WIDTH, null));
-
-        // create the event log panel
-        mEventLogPanel = new EventLogPanel(mDdmuiLibImageLoader);
-        
-        // set the external actions
-        mEventLogPanel.setActions(optionsAction, clearAction, saveAction, loadAction,
-                importBugAction);
-
-        // create the panel
-        mEventLogPanel.createPanel(eventLogTopComposite);
-    }
-
-    private void createFileExplorer() {
-        if (mExplorer == null) {
-            mExplorerShell = new Shell(mDisplay);
-
-            // create the ui
-            mExplorerShell.setLayout(new GridLayout(1, false));
-
-            // toolbar + action
-            ToolBar toolBar = new ToolBar(mExplorerShell, SWT.HORIZONTAL);
-            toolBar.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-            ToolItemAction pullAction = new ToolItemAction(toolBar, SWT.PUSH);
-            pullAction.item.setToolTipText("Pull File from Device");
-            pullAction.item.setImage(mDdmuiLibImageLoader.loadImage("pull.png", mDisplay)); //$NON-NLS-1$
-
-            ToolItemAction pushAction = new ToolItemAction(toolBar, SWT.PUSH);
-            pushAction.item.setToolTipText("Push file onto Device");
-            pushAction.item.setImage(mDdmuiLibImageLoader.loadImage("push.png", mDisplay)); //$NON-NLS-1$
-
-            ToolItemAction deleteAction = new ToolItemAction(toolBar, SWT.PUSH);
-            deleteAction.item.setToolTipText("Delete");
-            deleteAction.item.setImage(mDdmuiLibImageLoader.loadImage("delete.png", mDisplay)); //$NON-NLS-1$
-
-            // device explorer
-            mExplorer = new DeviceExplorer();
-
-            mExplorer.setImages(mDdmuiLibImageLoader.loadImage("file.png", mDisplay), //$NON-NLS-1$
-                    mDdmuiLibImageLoader.loadImage("folder.png", mDisplay), //$NON-NLS-1$
-                    mDdmuiLibImageLoader.loadImage("android.png", mDisplay), //$NON-NLS-1$
-                    null);
-            mExplorer.setActions(pushAction, pullAction, deleteAction);
-
-            pullAction.item.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    mExplorer.pullSelection();
-                }
-            });
-            pullAction.setEnabled(false);
-
-            pushAction.item.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    mExplorer.pushIntoSelection();
-                }
-            });
-            pushAction.setEnabled(false);
-
-            deleteAction.item.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    mExplorer.deleteSelection();
-                }
-            });
-            deleteAction.setEnabled(false);
-
-            Composite parent = new Composite(mExplorerShell, SWT.NONE);
-            parent.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            mExplorer.createPanel(parent);
-            mExplorer.switchDevice(mCurrentDevice);
-
-            mExplorerShell.addShellListener(new ShellListener() {
-                public void shellActivated(ShellEvent e) {
-                    // pass
-                }
-
-                public void shellClosed(ShellEvent e) {
-                    mExplorer = null;
-                    mExplorerShell = null;
-                }
-
-                public void shellDeactivated(ShellEvent e) {
-                    // pass
-                }
-
-                public void shellDeiconified(ShellEvent e) {
-                    // pass
-                }
-
-                public void shellIconified(ShellEvent e) {
-                    // pass
-                }
-            });
-
-            mExplorerShell.pack();
-            setExplorerSizeAndPosition(mExplorerShell);
-            mExplorerShell.open();
-        } else {
-            if (mExplorerShell != null) {
-                mExplorerShell.forceActive();
-            }
-        }
-    }
-
-    /**
-     * Set the status line. TODO: make this a stack, so we can safely have
-     * multiple things trying to set it all at once. Also specify an expiration?
-     */
-    public void setStatusLine(final String str) {
-        try {
-            mDisplay.asyncExec(new Runnable() {
-                public void run() {
-                    doSetStatusLine(str);
-                }
-            });
-        } catch (SWTException swte) {
-            if (!mDisplay.isDisposed())
-                throw swte;
-        }
-    }
-
-    private void doSetStatusLine(String str) {
-        if (mStatusLine.isDisposed())
-            return;
-
-        if (!mStatusLine.getText().equals(str)) {
-            mStatusLine.setText(str);
-
-            // try { Thread.sleep(100); }
-            // catch (InterruptedException ie) {}
-        }
-    }
-
-    public void displayError(final String msg) {
-        try {
-            mDisplay.syncExec(new Runnable() {
-                public void run() {
-                    MessageDialog.openError(mDisplay.getActiveShell(), "Error",
-                            msg);
-                }
-            });
-        } catch (SWTException swte) {
-            if (!mDisplay.isDisposed())
-                throw swte;
-        }
-    }
-
-    private void enableButtons() {
-        if (mCurrentClient != null) {
-            mTBShowThreadUpdates.setSelection(mCurrentClient.isThreadUpdateEnabled());
-            mTBShowThreadUpdates.setEnabled(true);
-            mTBShowHeapUpdates.setSelection(mCurrentClient.isHeapUpdateEnabled());
-            mTBShowHeapUpdates.setEnabled(true);
-            mTBHalt.setEnabled(true);
-            mTBCauseGc.setEnabled(true);
-        } else {
-            // list is empty, disable these
-            mTBShowThreadUpdates.setSelection(false);
-            mTBShowThreadUpdates.setEnabled(false);
-            mTBShowHeapUpdates.setSelection(false);
-            mTBShowHeapUpdates.setEnabled(false);
-            mTBHalt.setEnabled(false);
-            mTBCauseGc.setEnabled(false);
-        }
-    }
-
-    /**
-     * Sent when a new {@link Device} and {@link Client} are selected.
-     * @param selectedDevice the selected device. If null, no devices are selected.
-     * @param selectedClient The selected client. If null, no clients are selected.
-     *
-     * @see IUiSelectionListener
-     */
-    public void selectionChanged(Device selectedDevice, Client selectedClient) {
-        if (mCurrentDevice != selectedDevice) {
-            mCurrentDevice = selectedDevice;
-            for (TablePanel panel : mPanels) {
-                if (panel != null) {
-                    panel.deviceSelected(mCurrentDevice);
-                }
-            }
-
-            mEmulatorPanel.deviceSelected(mCurrentDevice);
-            mLogPanel.deviceSelected(mCurrentDevice);
-            if (mEventLogPanel != null) {
-                mEventLogPanel.deviceSelected(mCurrentDevice);
-            }
-
-            if (mExplorer != null) {
-                mExplorer.switchDevice(mCurrentDevice);
-            }
-        }
-
-        if (mCurrentClient != selectedClient) {
-            AndroidDebugBridge.getBridge().setSelectedClient(selectedClient);
-            mCurrentClient = selectedClient;
-            for (TablePanel panel : mPanels) {
-                if (panel != null) {
-                    panel.clientSelected(mCurrentClient);
-                }
-            }
-
-            enableButtons();
-        }
-    }
-}
diff --git a/tools/ddms/app/src/resources/images/ddms-icon.png b/tools/ddms/app/src/resources/images/ddms-icon.png
deleted file mode 100644
index 167a83b..0000000
--- a/tools/ddms/app/src/resources/images/ddms-icon.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/app/src/resources/images/ddms-logo.png b/tools/ddms/app/src/resources/images/ddms-logo.png
deleted file mode 100644
index b4708b4..0000000
--- a/tools/ddms/app/src/resources/images/ddms-logo.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/Android.mk b/tools/ddms/libs/Android.mk
deleted file mode 100644
index c62c6d0..0000000
--- a/tools/ddms/libs/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DDMSLIBS_LOCAL_DIR := $(call my-dir)
-include $(DDMSLIBS_LOCAL_DIR)/ddmlib/Android.mk
-include $(DDMSLIBS_LOCAL_DIR)/ddmuilib/Android.mk
diff --git a/tools/ddms/libs/ddmlib/.classpath b/tools/ddms/libs/ddmlib/.classpath
deleted file mode 100644
index fb50116..0000000
--- a/tools/ddms/libs/ddmlib/.classpath
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/ddms/libs/ddmlib/.project b/tools/ddms/libs/ddmlib/.project
deleted file mode 100644
index fea25c7..0000000
--- a/tools/ddms/libs/ddmlib/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ddmlib</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/ddms/libs/ddmlib/Android.mk b/tools/ddms/libs/ddmlib/Android.mk
deleted file mode 100644
index a49bdd2..0000000
--- a/tools/ddms/libs/ddmlib/Android.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DDMLIB_LOCAL_DIR := $(call my-dir)
-include $(DDMLIB_LOCAL_DIR)/src/Android.mk
diff --git a/tools/ddms/libs/ddmlib/src/Android.mk b/tools/ddms/libs/ddmlib/src/Android.mk
deleted file mode 100644
index da07f97..0000000
--- a/tools/ddms/libs/ddmlib/src/Android.mk
+++ /dev/null
@@ -1,11 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_MODULE := ddmlib
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AdbHelper.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AdbHelper.java
deleted file mode 100644
index 42022fe..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AdbHelper.java
+++ /dev/null
@@ -1,714 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmlib.log.LogReceiver;
-
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.InetSocketAddress;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.channels.SocketChannel;
-
-/**
- * Helper class to handle requests and connections to adb.
- * <p/>{@link DebugBridgeServer} is the public API to connection to adb, while {@link AdbHelper}
- * does the low level stuff. 
- * <p/>This currently uses spin-wait non-blocking I/O. A Selector would be more efficient,
- * but seems like overkill for what we're doing here.
- */
-final class AdbHelper {
-
-    // public static final long kOkay = 0x59414b4fL;
-    // public static final long kFail = 0x4c494146L;
-
-    static final int WAIT_TIME = 5; // spin-wait sleep, in ms
-
-    public static final int STD_TIMEOUT = 5000; // standard delay, in ms
-
-    static final String DEFAULT_ENCODING = "ISO-8859-1"; //$NON-NLS-1$
-
-    /** do not instantiate */
-    private AdbHelper() {
-    }
-
-    /**
-     * Response from ADB.
-     */
-    static class AdbResponse {
-        public AdbResponse() {
-            // ioSuccess = okay = timeout = false;
-            message = "";
-        }
-
-        public boolean ioSuccess; // read all expected data, no timeoutes
-
-        public boolean okay; // first 4 bytes in response were "OKAY"?
-
-        public boolean timeout; // TODO: implement
-
-        public String message; // diagnostic string
-    }
-
-    /**
-     * Create and connect a new pass-through socket, from the host to a port on
-     * the device.
-     *
-     * @param adbSockAddr
-     * @param device the device to connect to. Can be null in which case the connection will be
-     * to the first available device.
-     * @param devicePort the port we're opening
-     */
-    public static SocketChannel open(InetSocketAddress adbSockAddr,
-            Device device, int devicePort) throws IOException {
-
-        SocketChannel adbChan = SocketChannel.open(adbSockAddr);
-        try {
-            adbChan.socket().setTcpNoDelay(true);
-            adbChan.configureBlocking(false);
-
-            // if the device is not -1, then we first tell adb we're looking to
-            // talk to a specific device
-            setDevice(adbChan, device);
-
-            byte[] req = createAdbForwardRequest(null, devicePort);
-            // Log.hexDump(req);
-
-            if (write(adbChan, req) == false)
-                throw new IOException("failed submitting request to ADB"); //$NON-NLS-1$
-
-            AdbResponse resp = readAdbResponse(adbChan, false);
-            if (!resp.okay)
-                throw new IOException("connection request rejected"); //$NON-NLS-1$
-
-            adbChan.configureBlocking(true);
-        } catch (IOException ioe) {
-            adbChan.close();
-            throw ioe;
-        }
-
-        return adbChan;
-    }
-
-    /**
-     * Creates and connects a new pass-through socket, from the host to a port on
-     * the device.
-     *
-     * @param adbSockAddr
-     * @param device the device to connect to. Can be null in which case the connection will be
-     * to the first available device.
-     * @param pid the process pid to connect to.
-     */
-    public static SocketChannel createPassThroughConnection(InetSocketAddress adbSockAddr,
-            Device device, int pid) throws IOException {
-
-        SocketChannel adbChan = SocketChannel.open(adbSockAddr);
-        try {
-            adbChan.socket().setTcpNoDelay(true);
-            adbChan.configureBlocking(false);
-
-            // if the device is not -1, then we first tell adb we're looking to
-            // talk to a specific device
-            setDevice(adbChan, device);
-
-            byte[] req = createJdwpForwardRequest(pid);
-            // Log.hexDump(req);
-
-            if (write(adbChan, req) == false)
-                throw new IOException("failed submitting request to ADB"); //$NON-NLS-1$
-
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.okay)
-                throw new IOException("connection request rejected: " + resp.message); //$NON-NLS-1$
-
-            adbChan.configureBlocking(true);
-        } catch (IOException ioe) {
-            adbChan.close();
-            throw ioe;
-        }
-
-        return adbChan;
-    }
-
-    /**
-     * Creates a port forwarding request for adb. This returns an array
-     * containing "####tcp:{port}:{addStr}".
-     * @param addrStr the host. Can be null.
-     * @param port the port on the device. This does not need to be numeric.
-     */
-    private static byte[] createAdbForwardRequest(String addrStr, int port) {
-        String reqStr;
-
-        if (addrStr == null)
-            reqStr = "tcp:" + port;
-        else
-            reqStr = "tcp:" + port + ":" + addrStr;
-        return formAdbRequest(reqStr);
-    }
-
-    /**
-     * Creates a port forwarding request to a jdwp process. This returns an array
-     * containing "####jwdp:{pid}".
-     * @param pid the jdwp process pid on the device.
-     */
-    private static byte[] createJdwpForwardRequest(int pid) {
-        String reqStr = String.format("jdwp:%1$d", pid); //$NON-NLS-1$
-        return formAdbRequest(reqStr);
-    }
-
-    /**
-     * Create an ASCII string preceeded by four hex digits. The opening "####"
-     * is the length of the rest of the string, encoded as ASCII hex (case
-     * doesn't matter). "port" and "host" are what we want to forward to. If
-     * we're on the host side connecting into the device, "addrStr" should be
-     * null.
-     */
-    static byte[] formAdbRequest(String req) {
-        String resultStr = String.format("%04X%s", req.length(), req); //$NON-NLS-1$
-        byte[] result;
-        try {
-            result = resultStr.getBytes(DEFAULT_ENCODING);
-        } catch (UnsupportedEncodingException uee) {
-            uee.printStackTrace(); // not expected
-            return null;
-        }
-        assert result.length == req.length() + 4;
-        return result;
-    }
-
-    /**
-     * Reads the response from ADB after a command.
-     * @param chan The socket channel that is connected to adb.
-     * @param readDiagString If true, we're expecting an OKAY response to be
-     *      followed by a diagnostic string. Otherwise, we only expect the
-     *      diagnostic string to follow a FAIL.
-     */
-    static AdbResponse readAdbResponse(SocketChannel chan, boolean readDiagString)
-            throws IOException {
-
-        AdbResponse resp = new AdbResponse();
-
-        byte[] reply = new byte[4];
-        if (read(chan, reply) == false) {
-            return resp;
-        }
-        resp.ioSuccess = true;
-
-        if (isOkay(reply)) {
-            resp.okay = true;
-        } else {
-            readDiagString = true; // look for a reason after the FAIL
-            resp.okay = false;
-        }
-
-        // not a loop -- use "while" so we can use "break"
-        while (readDiagString) {
-            // length string is in next 4 bytes
-            byte[] lenBuf = new byte[4];
-            if (read(chan, lenBuf) == false) {
-                Log.w("ddms", "Expected diagnostic string not found");
-                break;
-            }
-
-            String lenStr = replyToString(lenBuf);
-
-            int len;
-            try {
-                len = Integer.parseInt(lenStr, 16);
-            } catch (NumberFormatException nfe) {
-                Log.w("ddms", "Expected digits, got '" + lenStr + "': "
-                        + lenBuf[0] + " " + lenBuf[1] + " " + lenBuf[2] + " "
-                        + lenBuf[3]);
-                Log.w("ddms", "reply was " + replyToString(reply));
-                break;
-            }
-
-            byte[] msg = new byte[len];
-            if (read(chan, msg) == false) {
-                Log.w("ddms", "Failed reading diagnostic string, len=" + len);
-                break;
-            }
-
-            resp.message = replyToString(msg);
-            Log.v("ddms", "Got reply '" + replyToString(reply) + "', diag='"
-                    + resp.message + "'");
-
-            break;
-        }
-
-        return resp;
-    }
-
-    /**
-     * Retrieve the frame buffer from the device.
-     */
-    public static RawImage getFrameBuffer(InetSocketAddress adbSockAddr, Device device)
-            throws IOException {
-
-        RawImage imageParams = new RawImage();
-        byte[] request = formAdbRequest("framebuffer:"); //$NON-NLS-1$
-        byte[] nudge = {
-            0
-        };
-        byte[] reply;
-
-        SocketChannel adbChan = null;
-        try {
-            adbChan = SocketChannel.open(adbSockAddr);
-            adbChan.configureBlocking(false);
-    
-            // if the device is not -1, then we first tell adb we're looking to talk
-            // to a specific device
-            setDevice(adbChan, device);
-    
-            if (write(adbChan, request) == false)
-                throw new IOException("failed asking for frame buffer");
-    
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.ioSuccess || !resp.okay) {
-                Log.w("ddms", "Got timeout or unhappy response from ADB fb req: "
-                        + resp.message);
-                adbChan.close();
-                return null;
-            }
-    
-            reply = new byte[16];
-            if (read(adbChan, reply) == false) {
-                Log.w("ddms", "got partial reply from ADB fb:");
-                Log.hexDump("ddms", LogLevel.WARN, reply, 0, reply.length);
-                adbChan.close();
-                return null;
-            }
-            ByteBuffer buf = ByteBuffer.wrap(reply);
-            buf.order(ByteOrder.LITTLE_ENDIAN);
-    
-            imageParams.bpp = buf.getInt();
-            imageParams.size = buf.getInt();
-            imageParams.width = buf.getInt();
-            imageParams.height = buf.getInt();
-    
-            Log.d("ddms", "image params: bpp=" + imageParams.bpp + ", size="
-                    + imageParams.size + ", width=" + imageParams.width
-                    + ", height=" + imageParams.height);
-    
-            if (write(adbChan, nudge) == false)
-                throw new IOException("failed nudging");
-    
-            reply = new byte[imageParams.size];
-            if (read(adbChan, reply) == false) {
-                Log.w("ddms", "got truncated reply from ADB fb data");
-                adbChan.close();
-                return null;
-            }
-            imageParams.data = reply;
-        } finally {
-            if (adbChan != null) {
-                adbChan.close();
-            }
-        }
-
-        return imageParams;
-    }
-
-    /**
-     * Execute a command on the device and retrieve the output. The output is
-     * handed to "rcvr" as it arrives.
-     */
-    public static void executeRemoteCommand(InetSocketAddress adbSockAddr,
-            String command, Device device, IShellOutputReceiver rcvr)
-            throws IOException {
-        Log.v("ddms", "execute: running " + command);
-
-        SocketChannel adbChan = null;
-        try {
-            adbChan = SocketChannel.open(adbSockAddr);
-            adbChan.configureBlocking(false);
-
-            // if the device is not -1, then we first tell adb we're looking to
-            // talk
-            // to a specific device
-            setDevice(adbChan, device);
-
-            byte[] request = formAdbRequest("shell:" + command); //$NON-NLS-1$
-            if (write(adbChan, request) == false)
-                throw new IOException("failed submitting shell command");
-
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.ioSuccess || !resp.okay) {
-                Log.e("ddms", "ADB rejected shell command (" + command + "): " + resp.message);
-                throw new IOException("sad result from adb: " + resp.message);
-            }
-
-            byte[] data = new byte[16384];
-            ByteBuffer buf = ByteBuffer.wrap(data);
-            while (true) {
-                int count;
-
-                if (rcvr != null && rcvr.isCancelled()) {
-                    Log.v("ddms", "execute: cancelled");
-                    break;
-                }
-
-                count = adbChan.read(buf);
-                if (count < 0) {
-                    // we're at the end, we flush the output
-                    rcvr.flush();
-                    Log.v("ddms", "execute '" + command + "' on '" + device + "' : EOF hit. Read: "
-                            + count);
-                    break;
-                } else if (count == 0) {
-                    try {
-                        Thread.sleep(WAIT_TIME * 5);
-                    } catch (InterruptedException ie) {
-                    }
-                } else {
-                    if (rcvr != null) {
-                        rcvr.addOutput(buf.array(), buf.arrayOffset(), buf.position());
-                    }
-                    buf.rewind();
-                }
-            }
-        } finally {
-            if (adbChan != null) {
-                adbChan.close();
-            }
-            Log.v("ddms", "execute: returning");
-        }
-    }
-
-    /**
-     * Runs the Event log service on the {@link Device}, and provides its output to the
-     * {@link LogReceiver}.
-     * @param adbSockAddr the socket address to connect to adb
-     * @param device the Device on which to run the service
-     * @param rcvr the {@link LogReceiver} to receive the log output
-     * @throws IOException
-     */
-    public static void runEventLogService(InetSocketAddress adbSockAddr, Device device,
-            LogReceiver rcvr) throws IOException {
-        runLogService(adbSockAddr, device, "events", rcvr); //$NON-NLS-1$
-    }
-
-    /**
-     * Runs a log service on the {@link Device}, and provides its output to the {@link LogReceiver}.
-     * @param adbSockAddr the socket address to connect to adb
-     * @param device the Device on which to run the service
-     * @param logName the name of the log file to output
-     * @param rcvr the {@link LogReceiver} to receive the log output
-     * @throws IOException
-     */
-    public static void runLogService(InetSocketAddress adbSockAddr, Device device, String logName,
-            LogReceiver rcvr) throws IOException {
-        SocketChannel adbChan = null;
-        
-        try {
-            adbChan = SocketChannel.open(adbSockAddr);
-            adbChan.configureBlocking(false);
-    
-            // if the device is not -1, then we first tell adb we're looking to talk
-            // to a specific device
-            setDevice(adbChan, device);
-    
-            byte[] request = formAdbRequest("log:" + logName);
-            if (write(adbChan, request) == false) {
-                throw new IOException("failed to submit the log command");
-            }
-    
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.ioSuccess || !resp.okay) {
-                throw new IOException("Device rejected log command: " + resp.message);
-            }
-    
-            byte[] data = new byte[16384];
-            ByteBuffer buf = ByteBuffer.wrap(data);
-            while (true) {
-                int count;
-    
-                if (rcvr != null && rcvr.isCancelled()) {
-                    break;
-                }
-    
-                count = adbChan.read(buf);
-                if (count < 0) {
-                    break;
-                } else if (count == 0) {
-                    try {
-                        Thread.sleep(WAIT_TIME * 5);
-                    } catch (InterruptedException ie) {
-                    }
-                } else {
-                    if (rcvr != null) {
-                        rcvr.parseNewData(buf.array(), buf.arrayOffset(), buf.position());
-                    }
-                    buf.rewind();
-                }
-            }
-        } finally {
-            if (adbChan != null) {
-                adbChan.close();
-            }
-        }
-    }
-    
-    /**
-     * Creates a port forwarding between a local and a remote port.
-     * @param adbSockAddr the socket address to connect to adb
-     * @param device the device on which to do the port fowarding
-     * @param localPort the local port to forward
-     * @param remotePort the remote port.
-     * @return <code>true</code> if success.
-     * @throws IOException 
-     */
-    public static boolean createForward(InetSocketAddress adbSockAddr, Device device, int localPort,
-            int remotePort) throws IOException {
-
-        SocketChannel adbChan = null;
-        try {
-            adbChan = SocketChannel.open(adbSockAddr);
-            adbChan.configureBlocking(false);
-    
-            byte[] request = formAdbRequest(String.format(
-                    "host-serial:%1$s:forward:tcp:%2$d;tcp:%3$d", //$NON-NLS-1$
-                    device.serialNumber, localPort, remotePort));
-    
-            if (write(adbChan, request) == false) {
-                throw new IOException("failed to submit the forward command.");
-            }
-            
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.ioSuccess || !resp.okay) {
-                throw new IOException("Device rejected command: " + resp.message);
-            }
-        } finally {
-            if (adbChan != null) {
-                adbChan.close();
-            }
-        }
-        
-        return true;
-    }
-
-    /**
-     * Remove a port forwarding between a local and a remote port.
-     * @param adbSockAddr the socket address to connect to adb
-     * @param device the device on which to remove the port fowarding
-     * @param localPort the local port of the forward
-     * @param remotePort the remote port.
-     * @return <code>true</code> if success.
-     * @throws IOException
-     */
-    public static boolean removeForward(InetSocketAddress adbSockAddr, Device device, int localPort,
-            int remotePort) throws IOException {
-
-        SocketChannel adbChan = null;
-        try {
-            adbChan = SocketChannel.open(adbSockAddr);
-            adbChan.configureBlocking(false);
-    
-            byte[] request = formAdbRequest(String.format(
-                    "host-serial:%1$s:killforward:tcp:%2$d;tcp:%3$d", //$NON-NLS-1$
-                    device.serialNumber, localPort, remotePort));
-    
-            if (!write(adbChan, request)) {
-                throw new IOException("failed to submit the remove forward command.");
-            }
-    
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.ioSuccess || !resp.okay) {
-                throw new IOException("Device rejected command: " + resp.message);
-            }
-        } finally {
-            if (adbChan != null) {
-                adbChan.close();
-            }
-        }
-
-        return true;
-    }
-
-    /**
-     * Checks to see if the first four bytes in "reply" are OKAY.
-     */
-    static boolean isOkay(byte[] reply) {
-        return reply[0] == (byte)'O' && reply[1] == (byte)'K'
-                && reply[2] == (byte)'A' && reply[3] == (byte)'Y';
-    }
-
-    /**
-     * Converts an ADB reply to a string.
-     */
-    static String replyToString(byte[] reply) {
-        String result;
-        try {
-            result = new String(reply, DEFAULT_ENCODING);
-        } catch (UnsupportedEncodingException uee) {
-            uee.printStackTrace(); // not expected
-            result = "";
-        }
-        return result;
-    }
-    
-    /**
-     * Reads from the socket until the array is filled, or no more data is coming (because
-     * the socket closed or the timeout expired).
-     *
-     * @param chan the opened socket to read from. It must be in non-blocking
-     *      mode for timeouts to work
-     * @param data the buffer to store the read data into.
-     * @return "true" if all data was read.
-     * @throws IOException 
-     */
-    static boolean read(SocketChannel chan, byte[] data) {
-       try {
-           read(chan, data, -1, STD_TIMEOUT);
-       } catch (IOException e) {
-           Log.d("ddms", "readAll: IOException: " + e.getMessage());
-           return false;
-       }
-       
-       return true;
-    }
-
-    /**
-     * Reads from the socket until the array is filled, the optional length
-     * is reached, or no more data is coming (because the socket closed or the
-     * timeout expired). After "timeout" milliseconds since the
-     * previous successful read, this will return whether or not new data has
-     * been found.
-     *
-     * @param chan the opened socket to read from. It must be in non-blocking
-     *      mode for timeouts to work
-     * @param data the buffer to store the read data into.
-     * @param length the length to read or -1 to fill the data buffer completely
-     * @param timeout The timeout value. A timeout of zero means "wait forever".
-     * @throws IOException 
-     */
-    static void read(SocketChannel chan, byte[] data, int length, int timeout) throws IOException {
-        ByteBuffer buf = ByteBuffer.wrap(data, 0, length != -1 ? length : data.length);
-        int numWaits = 0;
-
-        while (buf.position() != buf.limit()) {
-            int count;
-
-            count = chan.read(buf);
-            if (count < 0) {
-                Log.d("ddms", "read: channel EOF");
-                throw new IOException("EOF");
-            } else if (count == 0) {
-                // TODO: need more accurate timeout?
-                if (timeout != 0 && numWaits * WAIT_TIME > timeout) {
-                    Log.i("ddms", "read: timeout");
-                    throw new IOException("timeout");
-                }
-                // non-blocking spin
-                try {
-                    Thread.sleep(WAIT_TIME);
-                } catch (InterruptedException ie) {
-                }
-                numWaits++;
-            } else {
-                numWaits = 0;
-            }
-        }
-    }
-
-    /**
-     * Write until all data in "data" is written or the connection fails.
-     * @param chan the opened socket to write to.
-     * @param data the buffer to send.
-     * @return "true" if all data was written.
-     */
-    static boolean write(SocketChannel chan, byte[] data) {
-        try {
-            write(chan, data, -1, STD_TIMEOUT);
-        } catch (IOException e) {
-            Log.e("ddms", e);
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Write until all data in "data" is written, the optional length is reached,
-     * the timeout expires, or the connection fails. Returns "true" if all
-     * data was written.
-     * @param chan the opened socket to write to.
-     * @param data the buffer to send.
-     * @param length the length to write or -1 to send the whole buffer.
-     * @param timeout The timeout value. A timeout of zero means "wait forever".
-     * @throws IOException 
-     */
-    static void write(SocketChannel chan, byte[] data, int length, int timeout)
-            throws IOException {
-        ByteBuffer buf = ByteBuffer.wrap(data, 0, length != -1 ? length : data.length);
-        int numWaits = 0;
-
-        while (buf.position() != buf.limit()) {
-            int count;
-
-            count = chan.write(buf);
-            if (count < 0) {
-                Log.d("ddms", "write: channel EOF");
-                throw new IOException("channel EOF");
-            } else if (count == 0) {
-                // TODO: need more accurate timeout?
-                if (timeout != 0 && numWaits * WAIT_TIME > timeout) {
-                    Log.i("ddms", "write: timeout");
-                    throw new IOException("timeout");
-                }
-                // non-blocking spin
-                try {
-                    Thread.sleep(WAIT_TIME);
-                } catch (InterruptedException ie) {
-                }
-                numWaits++;
-            } else {
-                numWaits = 0;
-            }
-        }
-    }
-
-    /**
-     * tells adb to talk to a specific device
-     *
-     * @param adbChan the socket connection to adb
-     * @param device The device to talk to.
-     * @throws IOException
-     */
-    static void setDevice(SocketChannel adbChan, Device device)
-            throws IOException {
-        // if the device is not -1, then we first tell adb we're looking to talk
-        // to a specific device
-        if (device != null) {
-            String msg = "host:transport:" + device.serialNumber; //$NON-NLS-1$
-            byte[] device_query = formAdbRequest(msg);
-
-            if (write(adbChan, device_query) == false)
-                throw new IOException("failed submitting device (" + device +
-                        ") request to ADB");
-
-            AdbResponse resp = readAdbResponse(adbChan, false /* readDiagString */);
-            if (!resp.okay)
-                throw new IOException("device (" + device +
-                        ") request rejected: " + resp.message);
-        }
-
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AllocationInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AllocationInfo.java
deleted file mode 100644
index c6d4b50..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AllocationInfo.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Holds an Allocation information.
- */
-public class AllocationInfo implements Comparable<AllocationInfo>, IStackTraceInfo {
-    private String mAllocatedClass;
-    private int mAllocationSize;
-    private short mThreadId;
-    private StackTraceElement[] mStackTrace;
-
-    /*
-     * Simple constructor.
-     */
-    AllocationInfo(String allocatedClass, int allocationSize,
-        short threadId, StackTraceElement[] stackTrace) {
-        mAllocatedClass = allocatedClass;
-        mAllocationSize = allocationSize;
-        mThreadId = threadId;
-        mStackTrace = stackTrace;
-    }
-    
-    /**
-     * Returns the name of the allocated class.
-     */
-    public String getAllocatedClass() {
-        return mAllocatedClass;
-    }
-
-    /**
-     * Returns the size of the allocation.
-     */
-    public int getSize() {
-        return mAllocationSize;
-    }
-
-    /**
-     * Returns the id of the thread that performed the allocation.
-     */
-    public short getThreadId() {
-        return mThreadId;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IStackTraceInfo#getStackTrace()
-     */
-    public StackTraceElement[] getStackTrace() {
-        return mStackTrace;
-    }
-
-    public int compareTo(AllocationInfo otherAlloc) {
-        return otherAlloc.mAllocationSize - mAllocationSize;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AndroidDebugBridge.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AndroidDebugBridge.java
deleted file mode 100644
index 795bf88..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/AndroidDebugBridge.java
+++ /dev/null
@@ -1,1050 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Log.LogLevel;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.lang.Thread.State;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.net.UnknownHostException;
-import java.security.InvalidParameterException;
-import java.util.ArrayList;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * A connection to the host-side android debug bridge (adb)
- * <p/>This is the central point to communicate with any devices, emulators, or the applications
- * running on them.
- * <p/><b>{@link #init(boolean)} must be called before anything is done.</b>
- */
-public final class AndroidDebugBridge {
-    
-    /*
-     * Minimum and maximum version of adb supported. This correspond to
-     * ADB_SERVER_VERSION found in //device/tools/adb/adb.h
-     */
-
-    private final static int ADB_VERSION_MICRO_MIN = 20;
-    private final static int ADB_VERSION_MICRO_MAX = -1;
-
-    private final static Pattern sAdbVersion = Pattern.compile(
-            "^.*(\\d+)\\.(\\d+)\\.(\\d+)$"); //$NON-NLS-1$
-    
-    private final static String ADB = "adb"; //$NON-NLS-1$
-    private final static String DDMS = "ddms"; //$NON-NLS-1$
-
-    // Where to find the ADB bridge.
-    final static String ADB_HOST = "127.0.0.1"; //$NON-NLS-1$
-    final static int ADB_PORT = 5037;
-
-    static InetAddress sHostAddr;
-    static InetSocketAddress sSocketAddr;
-
-    static {
-        // built-in local address/port for ADB.
-        try {
-            sHostAddr = InetAddress.getByName(ADB_HOST);
-            sSocketAddr = new InetSocketAddress(sHostAddr, ADB_PORT);
-        } catch (UnknownHostException e) {
-
-        }
-    }
-
-    private static AndroidDebugBridge sThis;
-    private static boolean sClientSupport;
-
-    /** Full path to adb. */
-    private String mAdbOsLocation = null;
-
-    private boolean mVersionCheck;
-
-    private boolean mStarted = false;
-
-    private DeviceMonitor mDeviceMonitor;
-
-    private final static ArrayList<IDebugBridgeChangeListener> sBridgeListeners =
-        new ArrayList<IDebugBridgeChangeListener>();
-    private final static ArrayList<IDeviceChangeListener> sDeviceListeners =
-        new ArrayList<IDeviceChangeListener>();
-    private final static ArrayList<IClientChangeListener> sClientListeners =
-        new ArrayList<IClientChangeListener>();
-
-    // lock object for synchronization
-    private static final Object sLock = sBridgeListeners;
-
-    /**
-     * Classes which implement this interface provide a method that deals
-     * with {@link AndroidDebugBridge} changes.
-     */
-    public interface IDebugBridgeChangeListener {
-        /**
-         * Sent when a new {@link AndroidDebugBridge} is connected.
-         * <p/>
-         * This is sent from a non UI thread.
-         * @param bridge the new {@link AndroidDebugBridge} object.
-         */
-        public void bridgeChanged(AndroidDebugBridge bridge);
-    }
-
-    /**
-     * Classes which implement this interface provide methods that deal
-     * with {@link Device} addition, deletion, and changes.
-     */
-    public interface IDeviceChangeListener {
-        /**
-         * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-         * <p/>
-         * This is sent from a non UI thread.
-         * @param device the new device.
-         */
-        public void deviceConnected(Device device);
-
-        /**
-         * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-         * <p/>
-         * This is sent from a non UI thread.
-         * @param device the new device.
-         */
-        public void deviceDisconnected(Device device);
-
-        /**
-         * Sent when a device data changed, or when clients are started/terminated on the device.
-         * <p/>
-         * This is sent from a non UI thread.
-         * @param device the device that was updated.
-         * @param changeMask the mask describing what changed. It can contain any of the following
-         * values: {@link Device#CHANGE_BUILD_INFO}, {@link Device#CHANGE_STATE},
-         * {@link Device#CHANGE_CLIENT_LIST}
-         */
-        public void deviceChanged(Device device, int changeMask);
-    }
-
-    /**
-     * Classes which implement this interface provide methods that deal
-     * with {@link Client}  changes.
-     */
-    public interface IClientChangeListener {
-        /**
-         * Sent when an existing client information changed.
-         * <p/>
-         * This is sent from a non UI thread.
-         * @param client the updated client.
-         * @param changeMask the bit mask describing the changed properties. It can contain
-         * any of the following values: {@link Client#CHANGE_INFO},
-         * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-         * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-         * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-         */
-        public void clientChanged(Client client, int changeMask);
-    }
-
-    /**
-     * Initializes the <code>ddm</code> library.
-     * <p/>This must be called once <b>before</b> any call to
-     * {@link #createBridge(String, boolean)}.
-     * <p>The library can be initialized in 2 ways:
-     * <ul>
-     * <li>Mode 1: <var>clientSupport</var> == <code>true</code>.<br>The library monitors the
-     * devices and the applications running on them. It will connect to each application, as a
-     * debugger of sort, to be able to interact with them through JDWP packets.</li>
-     * <li>Mode 2: <var>clientSupport</var> == <code>false</code>.<br>The library only monitors
-     * devices. The applications are left untouched, letting other tools built on
-     * <code>ddmlib</code> to connect a debugger to them.</li>
-     * </ul>
-     * <p/><b>Only one tool can run in mode 1 at the same time.</b>
-     * <p/>Note that mode 1 does not prevent debugging of applications running on devices. Mode 1
-     * lets debuggers connect to <code>ddmlib</code> which acts as a proxy between the debuggers and
-     * the applications to debug. See {@link Client#getDebuggerListenPort()}.
-     * <p/>The preferences of <code>ddmlib</code> should also be initialized with whatever default
-     * values were changed from the default values.
-     * <p/>When the application quits, {@link #terminate()} should be called.
-     * @param clientSupport Indicates whether the library should enable the monitoring and
-     * interaction with applications running on the devices.
-     * @see AndroidDebugBridge#createBridge(String, boolean)
-     * @see DdmPreferences
-     */
-    public static void init(boolean clientSupport) {
-        sClientSupport = clientSupport;
-
-        MonitorThread monitorThread = MonitorThread.createInstance();
-        monitorThread.start();
-
-        HandleHello.register(monitorThread);
-        HandleAppName.register(monitorThread);
-        HandleTest.register(monitorThread);
-        HandleThread.register(monitorThread);
-        HandleHeap.register(monitorThread);
-        HandleWait.register(monitorThread);
-    }
-
-    /**
-     * Terminates the ddm library. This must be called upon application termination.
-     */
-    public static void terminate() {
-        // kill the monitoring services
-        if (sThis != null && sThis.mDeviceMonitor != null) {
-            sThis.mDeviceMonitor.stop();
-            sThis.mDeviceMonitor = null;
-        }
-
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (monitorThread != null) {
-            monitorThread.quit();
-        }
-    }
-    
-    /**
-     * Returns whether the ddmlib is setup to support monitoring and interacting with
-     * {@link Client}s running on the {@link Device}s.
-     */
-    static boolean getClientSupport() {
-        return sClientSupport;
-    }
-    
-    /**
-     * Creates a {@link AndroidDebugBridge} that is not linked to any particular executable.
-     * <p/>This bridge will expect adb to be running. It will not be able to start/stop/restart
-     * adb.
-     * <p/>If a bridge has already been started, it is directly returned with no changes (similar
-     * to calling {@link #getBridge()}).
-     * @return a connected bridge.
-     */
-    public static AndroidDebugBridge createBridge() {
-        synchronized (sLock) {
-            if (sThis != null) {
-                return sThis;
-            }
-
-            try {
-                sThis = new AndroidDebugBridge();
-                sThis.start();
-            } catch (InvalidParameterException e) {
-                sThis = null;
-            }
-
-            // because the listeners could remove themselves from the list while processing
-            // their event callback, we make a copy of the list and iterate on it instead of
-            // the main list.
-            // This mostly happens when the application quits.
-            IDebugBridgeChangeListener[] listenersCopy = sBridgeListeners.toArray(
-                    new IDebugBridgeChangeListener[sBridgeListeners.size()]);
-
-            // notify the listeners of the change
-            for (IDebugBridgeChangeListener listener : listenersCopy) {
-                // we attempt to catch any exception so that a bad listener doesn't kill our
-                // thread
-                try {
-                    listener.bridgeChanged(sThis);
-                } catch (Exception e) {
-                    Log.e(DDMS, e);
-                }
-            }
-
-            return sThis;
-        }
-    }
-
-
-    /**
-     * Creates a new debug bridge from the location of the command line tool.
-     * <p/>
-     * Any existing server will be disconnected, unless the location is the same and
-     * <code>forceNewBridge</code> is set to false.
-     * @param osLocation the location of the command line tool 'adb'
-     * @param forceNewBridge force creation of a new bridge even if one with the same location
-     * already exists.
-     * @return a connected bridge.
-     */
-    public static AndroidDebugBridge createBridge(String osLocation, boolean forceNewBridge) {
-        synchronized (sLock) {
-            if (sThis != null) {
-                if (sThis.mAdbOsLocation != null && sThis.mAdbOsLocation.equals(osLocation) &&
-                        forceNewBridge == false) {
-                    return sThis;
-                } else {
-                    // stop the current server
-                    sThis.stop();
-                }
-            }
-
-            try {
-                sThis = new AndroidDebugBridge(osLocation);
-                sThis.start();
-            } catch (InvalidParameterException e) {
-                sThis = null;
-            }
-
-            // because the listeners could remove themselves from the list while processing
-            // their event callback, we make a copy of the list and iterate on it instead of
-            // the main list.
-            // This mostly happens when the application quits.
-            IDebugBridgeChangeListener[] listenersCopy = sBridgeListeners.toArray(
-                    new IDebugBridgeChangeListener[sBridgeListeners.size()]);
-
-            // notify the listeners of the change
-            for (IDebugBridgeChangeListener listener : listenersCopy) {
-                // we attempt to catch any exception so that a bad listener doesn't kill our
-                // thread
-                try {
-                    listener.bridgeChanged(sThis);
-                } catch (Exception e) {
-                    Log.e(DDMS, e);
-                }
-            }
-
-            return sThis;
-        }
-    }
-
-    /**
-     * Returns the current debug bridge. Can be <code>null</code> if none were created.
-     */
-    public static AndroidDebugBridge getBridge() {
-        return sThis;
-    }
-
-    /**
-     * Disconnects the current debug bridge, and destroy the object.
-     * <p/>
-     * A new object will have to be created with {@link #createBridge(String, boolean)}.
-     */
-    public static void disconnectBridge() {
-        synchronized (sLock) {
-            if (sThis != null) {
-                sThis.stop();
-                sThis = null;
-
-                // because the listeners could remove themselves from the list while processing
-                // their event callback, we make a copy of the list and iterate on it instead of
-                // the main list.
-                // This mostly happens when the application quits.
-                IDebugBridgeChangeListener[] listenersCopy = sBridgeListeners.toArray(
-                        new IDebugBridgeChangeListener[sBridgeListeners.size()]);
-
-                // notify the listeners.
-                for (IDebugBridgeChangeListener listener : listenersCopy) {
-                    // we attempt to catch any exception so that a bad listener doesn't kill our
-                    // thread
-                    try {
-                        listener.bridgeChanged(sThis);
-                    } catch (Exception e) {
-                        Log.e(DDMS, e);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Adds the listener to the collection of listeners who will be notified when a new
-     * {@link AndroidDebugBridge} is connected, by sending it one of the messages defined
-     * in the {@link IDebugBridgeChangeListener} interface.
-     * @param listener The listener which should be notified.
-     */
-    public static void addDebugBridgeChangeListener(IDebugBridgeChangeListener listener) {
-        synchronized (sLock) {
-            if (sBridgeListeners.contains(listener) == false) {
-                sBridgeListeners.add(listener);
-                if (sThis != null) {
-                    // we attempt to catch any exception so that a bad listener doesn't kill our
-                    // thread
-                    try {
-                        listener.bridgeChanged(sThis);
-                    } catch (Exception e) {
-                        Log.e(DDMS, e);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Removes the listener from the collection of listeners who will be notified when a new
-     * {@link AndroidDebugBridge} is started.
-     * @param listener The listener which should no longer be notified.
-     */
-    public static void removeDebugBridgeChangeListener(IDebugBridgeChangeListener listener) {
-        synchronized (sLock) {
-            sBridgeListeners.remove(listener);
-        }
-    }
-
-    /**
-     * Adds the listener to the collection of listeners who will be notified when a {@link Device}
-     * is connected, disconnected, or when its properties or its {@link Client} list changed,
-     * by sending it one of the messages defined in the {@link IDeviceChangeListener} interface.
-     * @param listener The listener which should be notified.
-     */
-    public static void addDeviceChangeListener(IDeviceChangeListener listener) {
-        synchronized (sLock) {
-            if (sDeviceListeners.contains(listener) == false) {
-                sDeviceListeners.add(listener);
-            }
-        }
-    }
-
-    /**
-     * Removes the listener from the collection of listeners who will be notified when a
-     * {@link Device} is connected, disconnected, or when its properties or its {@link Client}
-     * list changed.
-     * @param listener The listener which should no longer be notified.
-     */
-    public static void removeDeviceChangeListener(IDeviceChangeListener listener) {
-        synchronized (sLock) {
-            sDeviceListeners.remove(listener);
-        }
-    }
-
-    /**
-     * Adds the listener to the collection of listeners who will be notified when a {@link Client}
-     * property changed, by sending it one of the messages defined in the
-     * {@link IClientChangeListener} interface.
-     * @param listener The listener which should be notified.
-     */
-    public static void addClientChangeListener(IClientChangeListener listener) {
-        synchronized (sLock) {
-            if (sClientListeners.contains(listener) == false) {
-                sClientListeners.add(listener);
-            }
-        }
-    }
-
-    /**
-     * Removes the listener from the collection of listeners who will be notified when a
-     * {@link Client} property changed.
-     * @param listener The listener which should no longer be notified.
-     */
-    public static void removeClientChangeListener(IClientChangeListener listener) {
-        synchronized (sLock) {
-            sClientListeners.remove(listener);
-        }
-    }
-
-
-    /**
-     * Returns the devices.
-     * @see #hasInitialDeviceList()
-     */
-    public Device[] getDevices() {
-        synchronized (sLock) {
-            if (mDeviceMonitor != null) {
-                return mDeviceMonitor.getDevices();
-            }
-        }
-
-        return new Device[0];
-    }
-    
-    /**
-     * Returns whether the bridge has acquired the initial list from adb after being created.
-     * <p/>Calling {@link #getDevices()} right after {@link #createBridge(String, boolean)} will
-     * generally result in an empty list. This is due to the internal asynchronous communication
-     * mechanism with <code>adb</code> that does not guarantee that the {@link Device} list has been
-     * built before the call to {@link #getDevices()}.
-     * <p/>The recommended way to get the list of {@link Device} objects is to create a 
-     * {@link IDeviceChangeListener} object.
-     */
-    public boolean hasInitialDeviceList() {
-        if (mDeviceMonitor != null) {
-            return mDeviceMonitor.hasInitialDeviceList();
-        }
-        
-        return false;
-    }
-
-    /**
-     * Sets the client to accept debugger connection on the custom "Selected debug port".
-     * @param selectedClient the client. Can be null.
-     */
-    public void setSelectedClient(Client selectedClient) {
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (monitorThread != null) {
-            monitorThread.setSelectedClient(selectedClient);
-        }
-    }
-
-    /**
-     * Returns whether the {@link AndroidDebugBridge} object is still connected to the adb daemon.
-     */
-    public boolean isConnected() {
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (mDeviceMonitor != null && monitorThread != null) {
-            return mDeviceMonitor.isMonitoring() && monitorThread.getState() != State.TERMINATED;
-        }
-        return false;
-    }
-
-    /**
-     * Returns the number of times the {@link AndroidDebugBridge} object attempted to connect
-     * to the adb daemon.
-     */
-    public int getConnectionAttemptCount() {
-        if (mDeviceMonitor != null) {
-            return mDeviceMonitor.getConnectionAttemptCount();
-        }
-        return -1;
-    }
-
-    /**
-     * Returns the number of times the {@link AndroidDebugBridge} object attempted to restart
-     * the adb daemon.
-     */
-    public int getRestartAttemptCount() {
-        if (mDeviceMonitor != null) {
-            return mDeviceMonitor.getRestartAttemptCount();
-        }
-        return -1;
-    }
-    
-    /**
-     * Creates a new bridge.
-     * @param osLocation the location of the command line tool
-     * @throws InvalidParameterException
-     */
-    private AndroidDebugBridge(String osLocation) throws InvalidParameterException {
-        if (osLocation == null || osLocation.length() == 0) {
-            throw new InvalidParameterException();
-        }
-        mAdbOsLocation = osLocation;
-
-        checkAdbVersion();
-    }
-    
-    /**
-     * Creates a new bridge not linked to any particular adb executable.
-     */
-    private AndroidDebugBridge() {
-    }
-
-    /**
-     * Queries adb for its version number and checks it against {@link #MIN_VERSION_NUMBER} and
-     * {@link #MAX_VERSION_NUMBER}
-     */
-    private void checkAdbVersion() {
-        // default is bad check
-        mVersionCheck = false;
-
-        if (mAdbOsLocation == null) {
-            return;
-        }
-
-        try {
-            String[] command = new String[2];
-            command[0] = mAdbOsLocation;
-            command[1] = "version"; //$NON-NLS-1$
-            Log.d(DDMS, String.format("Checking '%1$s version'", mAdbOsLocation)); //$NON-NLS-1$
-            Process process = Runtime.getRuntime().exec(command);
-
-            ArrayList<String> errorOutput = new ArrayList<String>();
-            ArrayList<String> stdOutput = new ArrayList<String>();
-            int status = grabProcessOutput(process, errorOutput, stdOutput,
-                    true /* waitForReaders */);
-
-            if (status != 0) {
-                StringBuilder builder = new StringBuilder("'adb version' failed!"); //$NON-NLS-1$
-                for (String error : errorOutput) {
-                    builder.append('\n');
-                    builder.append(error);
-                }
-                Log.logAndDisplay(LogLevel.ERROR, "adb", builder.toString());
-            }
-
-            // check both stdout and stderr
-            boolean versionFound = false;
-            for (String line : stdOutput) {
-                versionFound = scanVersionLine(line);
-                if (versionFound) {
-                    break;
-                }
-            }
-            if (!versionFound) {
-                for (String line : errorOutput) {
-                    versionFound = scanVersionLine(line);
-                    if (versionFound) {
-                        break;
-                    }
-                }
-            }
-
-            if (!versionFound) {
-                // if we get here, we failed to parse the output.
-                Log.logAndDisplay(LogLevel.ERROR, ADB,
-                        "Failed to parse the output of 'adb version'"); //$NON-NLS-1$
-            }
-            
-        } catch (IOException e) {
-            Log.logAndDisplay(LogLevel.ERROR, ADB,
-                    "Failed to get the adb version: " + e.getMessage()); //$NON-NLS-1$
-        } catch (InterruptedException e) {
-        } finally {
-
-        }
-    }
-
-    /**
-     * Scans a line resulting from 'adb version' for a potential version number.
-     * <p/>
-     * If a version number is found, it checks the version number against what is expected
-     * by this version of ddms.
-     * <p/>
-     * Returns true when a version number has been found so that we can stop scanning,
-     * whether the version number is in the acceptable range or not.
-     * 
-     * @param line The line to scan.
-     * @return True if a version number was found (whether it is acceptable or not).
-     */
-    private boolean scanVersionLine(String line) {
-        if (line != null) {
-            Matcher matcher = sAdbVersion.matcher(line);
-            if (matcher.matches()) {
-                int majorVersion = Integer.parseInt(matcher.group(1));
-                int minorVersion = Integer.parseInt(matcher.group(2));
-                int microVersion = Integer.parseInt(matcher.group(3));
-
-                // check only the micro version for now.
-                if (microVersion < ADB_VERSION_MICRO_MIN) {
-                    String message = String.format(
-                            "Required minimum version of adb: %1$d.%2$d.%3$d." //$NON-NLS-1$
-                            + "Current version is %1$d.%2$d.%4$d", //$NON-NLS-1$
-                            majorVersion, minorVersion, ADB_VERSION_MICRO_MIN,
-                            microVersion);
-                    Log.logAndDisplay(LogLevel.ERROR, ADB, message);
-                } else if (ADB_VERSION_MICRO_MAX != -1 &&
-                        microVersion > ADB_VERSION_MICRO_MAX) {
-                    String message = String.format(
-                            "Required maximum version of adb: %1$d.%2$d.%3$d." //$NON-NLS-1$
-                            + "Current version is %1$d.%2$d.%4$d", //$NON-NLS-1$
-                            majorVersion, minorVersion, ADB_VERSION_MICRO_MAX,
-                            microVersion);
-                    Log.logAndDisplay(LogLevel.ERROR, ADB, message);
-                } else {
-                    mVersionCheck = true;
-                }
-
-                return true;
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Starts the debug bridge.
-     * @return true if success.
-     */
-    boolean start() {
-        if (mAdbOsLocation != null && (mVersionCheck == false || startAdb() == false)) {
-            return false;
-        }
-
-        mStarted = true;
-
-        // now that the bridge is connected, we start the underlying services.
-        mDeviceMonitor = new DeviceMonitor(this);
-        mDeviceMonitor.start();
-
-        return true;
-    }
-
-   /**
-     * Kills the debug bridge.
-     * @return true if success
-     */
-    boolean stop() {
-        // if we haven't started we return false;
-        if (mStarted == false) {
-            return false;
-        }
-
-        // kill the monitoring services
-        mDeviceMonitor.stop();
-        mDeviceMonitor = null;
-
-        if (stopAdb() == false) {
-            return false;
-        }
-
-        mStarted = false;
-        return true;
-    }
-
-    /**
-     * Restarts adb, but not the services around it.
-     * @return true if success.
-     */
-    public boolean restart() {
-        if (mAdbOsLocation == null) {
-            Log.e(ADB,
-                    "Cannot restart adb when AndroidDebugBridge is created without the location of adb."); //$NON-NLS-1$
-            return false;
-        }
-
-        if (mVersionCheck == false) {
-            Log.logAndDisplay(LogLevel.ERROR, ADB,
-                    "Attempting to restart adb, but version check failed!"); //$NON-NLS-1$
-            return false;
-        }
-        synchronized (this) {
-            stopAdb();
-
-            boolean restart = startAdb();
-
-            if (restart && mDeviceMonitor == null) {
-                mDeviceMonitor = new DeviceMonitor(this);
-                mDeviceMonitor.start();
-            }
-
-            return restart;
-        }
-    }
-
-    /**
-     * Notify the listener of a new {@link Device}.
-     * <p/>
-     * The notification of the listeners is done in a synchronized block. It is important to
-     * expect the listeners to potentially access various methods of {@link Device} as well as
-     * {@link #getDevices()} which use internal locks.
-     * <p/>
-     * For this reason, any call to this method from a method of {@link DeviceMonitor},
-     * {@link Device} which is also inside a synchronized block, should first synchronize on
-     * the {@link AndroidDebugBridge} lock. Access to this lock is done through {@link #getLock()}.
-     * @param device the new <code>Device</code>.
-     * @see #getLock()
-     */
-    void deviceConnected(Device device) {
-        // because the listeners could remove themselves from the list while processing
-        // their event callback, we make a copy of the list and iterate on it instead of
-        // the main list.
-        // This mostly happens when the application quits.
-        IDeviceChangeListener[] listenersCopy = null;
-        synchronized (sLock) {
-            listenersCopy = sDeviceListeners.toArray(
-                    new IDeviceChangeListener[sDeviceListeners.size()]);
-        }
-        
-        // Notify the listeners
-        for (IDeviceChangeListener listener : listenersCopy) {
-            // we attempt to catch any exception so that a bad listener doesn't kill our
-            // thread
-            try {
-                listener.deviceConnected(device);
-            } catch (Exception e) {
-                Log.e(DDMS, e);
-            }
-        }
-    }
-
-    /**
-     * Notify the listener of a disconnected {@link Device}.
-     * <p/>
-     * The notification of the listeners is done in a synchronized block. It is important to
-     * expect the listeners to potentially access various methods of {@link Device} as well as
-     * {@link #getDevices()} which use internal locks.
-     * <p/>
-     * For this reason, any call to this method from a method of {@link DeviceMonitor},
-     * {@link Device} which is also inside a synchronized block, should first synchronize on
-     * the {@link AndroidDebugBridge} lock. Access to this lock is done through {@link #getLock()}.
-     * @param device the disconnected <code>Device</code>.
-     * @see #getLock()
-     */
-    void deviceDisconnected(Device device) {
-        // because the listeners could remove themselves from the list while processing
-        // their event callback, we make a copy of the list and iterate on it instead of
-        // the main list.
-        // This mostly happens when the application quits.
-        IDeviceChangeListener[] listenersCopy = null;
-        synchronized (sLock) {
-            listenersCopy = sDeviceListeners.toArray(
-                    new IDeviceChangeListener[sDeviceListeners.size()]);
-        }
-        
-        // Notify the listeners
-        for (IDeviceChangeListener listener : listenersCopy) {
-            // we attempt to catch any exception so that a bad listener doesn't kill our
-            // thread
-            try {
-                listener.deviceDisconnected(device);
-            } catch (Exception e) {
-                Log.e(DDMS, e);
-            }
-        }
-    }
-
-    /**
-     * Notify the listener of a modified {@link Device}.
-     * <p/>
-     * The notification of the listeners is done in a synchronized block. It is important to
-     * expect the listeners to potentially access various methods of {@link Device} as well as
-     * {@link #getDevices()} which use internal locks.
-     * <p/>
-     * For this reason, any call to this method from a method of {@link DeviceMonitor},
-     * {@link Device} which is also inside a synchronized block, should first synchronize on
-     * the {@link AndroidDebugBridge} lock. Access to this lock is done through {@link #getLock()}.
-     * @param device the modified <code>Device</code>.
-     * @see #getLock()
-     */
-    void deviceChanged(Device device, int changeMask) {
-        // because the listeners could remove themselves from the list while processing
-        // their event callback, we make a copy of the list and iterate on it instead of
-        // the main list.
-        // This mostly happens when the application quits.
-        IDeviceChangeListener[] listenersCopy = null;
-        synchronized (sLock) {
-            listenersCopy = sDeviceListeners.toArray(
-                    new IDeviceChangeListener[sDeviceListeners.size()]);
-        }
-        
-        // Notify the listeners
-        for (IDeviceChangeListener listener : listenersCopy) {
-            // we attempt to catch any exception so that a bad listener doesn't kill our
-            // thread
-            try {
-                listener.deviceChanged(device, changeMask);
-            } catch (Exception e) {
-                Log.e(DDMS, e);
-            }
-        }
-    }
-
-    /**
-     * Notify the listener of a modified {@link Client}.
-     * <p/>
-     * The notification of the listeners is done in a synchronized block. It is important to
-     * expect the listeners to potentially access various methods of {@link Device} as well as
-     * {@link #getDevices()} which use internal locks.
-     * <p/>
-     * For this reason, any call to this method from a method of {@link DeviceMonitor},
-     * {@link Device} which is also inside a synchronized block, should first synchronize on
-     * the {@link AndroidDebugBridge} lock. Access to this lock is done through {@link #getLock()}.
-     * @param device the modified <code>Client</code>.
-     * @param changeMask the mask indicating what changed in the <code>Client</code>
-     * @see #getLock()
-     */
-    void clientChanged(Client client, int changeMask) {
-        // because the listeners could remove themselves from the list while processing
-        // their event callback, we make a copy of the list and iterate on it instead of
-        // the main list.
-        // This mostly happens when the application quits.
-        IClientChangeListener[] listenersCopy = null;
-        synchronized (sLock) {
-            listenersCopy = sClientListeners.toArray(
-                    new IClientChangeListener[sClientListeners.size()]);
-            
-        }
-
-        // Notify the listeners
-        for (IClientChangeListener listener : listenersCopy) {
-            // we attempt to catch any exception so that a bad listener doesn't kill our
-            // thread
-            try {
-                listener.clientChanged(client, changeMask);
-            } catch (Exception e) {
-                Log.e(DDMS, e);
-            }
-        }
-    }
-
-    /**
-     * Returns the {@link DeviceMonitor} object.
-     */
-    DeviceMonitor getDeviceMonitor() {
-        return mDeviceMonitor;
-    }
-
-    /**
-     * Starts the adb host side server.
-     * @return true if success
-     */
-    synchronized boolean startAdb() {
-        if (mAdbOsLocation == null) {
-            Log.e(ADB,
-                "Cannot start adb when AndroidDebugBridge is created without the location of adb."); //$NON-NLS-1$
-            return false;
-        }
-
-        Process proc;
-        int status = -1;
-
-        try {
-            String[] command = new String[2];
-            command[0] = mAdbOsLocation;
-            command[1] = "start-server"; //$NON-NLS-1$
-            Log.d(DDMS,
-                    String.format("Launching '%1$s %2$s' to ensure ADB is running.", //$NON-NLS-1$
-                    mAdbOsLocation, command[1]));
-            proc = Runtime.getRuntime().exec(command);
-
-            ArrayList<String> errorOutput = new ArrayList<String>();
-            ArrayList<String> stdOutput = new ArrayList<String>();
-            status = grabProcessOutput(proc, errorOutput, stdOutput,
-                    false /* waitForReaders */);
-
-        } catch (IOException ioe) {
-            Log.d(DDMS, "Unable to run 'adb': " + ioe.getMessage()); //$NON-NLS-1$
-            // we'll return false;
-        } catch (InterruptedException ie) {
-            Log.d(DDMS, "Unable to run 'adb': " + ie.getMessage()); //$NON-NLS-1$
-            // we'll return false;
-        }
-
-        if (status != 0) {
-            Log.w(DDMS,
-                    "'adb start-server' failed -- run manually if necessary"); //$NON-NLS-1$
-            return false;
-        }
-
-        Log.d(DDMS, "'adb start-server' succeeded"); //$NON-NLS-1$
-
-        return true;
-    }
-
-    /**
-     * Stops the adb host side server.
-     * @return true if success
-     */
-    private synchronized boolean stopAdb() {
-        if (mAdbOsLocation == null) {
-            Log.e(ADB,
-                "Cannot stop adb when AndroidDebugBridge is created without the location of adb."); //$NON-NLS-1$
-            return false;
-        }
-
-        Process proc;
-        int status = -1;
-
-        try {
-            String[] command = new String[2];
-            command[0] = mAdbOsLocation;
-            command[1] = "kill-server"; //$NON-NLS-1$
-            proc = Runtime.getRuntime().exec(command);
-            status = proc.waitFor();
-        }
-        catch (IOException ioe) {
-            // we'll return false;
-        }
-        catch (InterruptedException ie) {
-            // we'll return false;
-        }
-
-        if (status != 0) {
-            Log.w(DDMS,
-                    "'adb kill-server' failed -- run manually if necessary"); //$NON-NLS-1$
-            return false;
-        }
-
-        Log.d(DDMS, "'adb kill-server' succeeded"); //$NON-NLS-1$
-        return true;
-    }
-
-    /**
-     * Get the stderr/stdout outputs of a process and return when the process is done.
-     * Both <b>must</b> be read or the process will block on windows.
-     * @param process The process to get the ouput from
-     * @param errorOutput The array to store the stderr output. cannot be null.
-     * @param stdOutput The array to store the stdout output. cannot be null.
-     * @param displayStdOut If true this will display stdout as well
-     * @param waitforReaders if true, this will wait for the reader threads. 
-     * @return the process return code.
-     * @throws InterruptedException
-     */
-    private int grabProcessOutput(final Process process, final ArrayList<String> errorOutput,
-            final ArrayList<String> stdOutput, boolean waitforReaders)
-            throws InterruptedException {
-        assert errorOutput != null;
-        assert stdOutput != null;
-        // read the lines as they come. if null is returned, it's
-        // because the process finished
-        Thread t1 = new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                // create a buffer to read the stderr output
-                InputStreamReader is = new InputStreamReader(process.getErrorStream());
-                BufferedReader errReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = errReader.readLine();
-                        if (line != null) {
-                            Log.e(ADB, line);
-                            errorOutput.add(line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        Thread t2 = new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                InputStreamReader is = new InputStreamReader(process.getInputStream());
-                BufferedReader outReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = outReader.readLine();
-                        if (line != null) {
-                            Log.d(ADB, line);
-                            stdOutput.add(line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        t1.start();
-        t2.start();
-
-        // it looks like on windows process#waitFor() can return
-        // before the thread have filled the arrays, so we wait for both threads and the
-        // process itself.
-        if (waitforReaders) {
-            try {
-                t1.join();
-            } catch (InterruptedException e) {
-            }
-            try {
-                t2.join();
-            } catch (InterruptedException e) {
-            }
-        }
-
-        // get the return code from the process
-        return process.waitFor();
-    }
-
-    /**
-     * Returns the singleton lock used by this class to protect any access to the listener.
-     * <p/>
-     * This includes adding/removing listeners, but also notifying listeners of new bridges,
-     * devices, and clients.
-     */
-    static Object getLock() {
-        return sLock;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/BadPacketException.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/BadPacketException.java
deleted file mode 100644
index 129b312..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/BadPacketException.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/* //device/tools/ddms/libs/ddmlib/src/com/android/ddmlib/BadPacketException.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddmlib;
-
-/**
- * Thrown if the contents of a packet are bad.
- */
-@SuppressWarnings("serial")
-class BadPacketException extends RuntimeException {
-    public BadPacketException()
-    {
-        super();
-    }
-
-    public BadPacketException(String msg)
-    {
-        super(msg);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ChunkHandler.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ChunkHandler.java
deleted file mode 100644
index 441b024..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ChunkHandler.java
+++ /dev/null
@@ -1,222 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.DebugPortManager.IDebugPortProvider;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Subclass this with a class that handles one or more chunk types.
- */
-abstract class ChunkHandler {
-
-    public static final int CHUNK_HEADER_LEN = 8;   // 4-byte type, 4-byte len
-    public static final ByteOrder CHUNK_ORDER = ByteOrder.BIG_ENDIAN;
-
-    public static final int CHUNK_FAIL = type("FAIL");
-
-    ChunkHandler() {}
-
-    /**
-     * Client is ready.  The monitor thread calls this method on all
-     * handlers when the client is determined to be DDM-aware (usually
-     * after receiving a HELO response.)
-     *
-     * The handler can use this opportunity to initialize client-side
-     * activity.  Because there's a fair chance we'll want to send a
-     * message to the client, this method can throw an IOException.
-     */
-    abstract void clientReady(Client client) throws IOException;
-
-    /**
-     * Client has gone away.  Can be used to clean up any resources
-     * associated with this client connection.
-     */
-    abstract void clientDisconnected(Client client);
-
-    /**
-     * Handle an incoming chunk.  The data, of chunk type "type", begins
-     * at the start of "data" and continues to data.limit().
-     *
-     * If "isReply" is set, then "msgId" will be the ID of the request
-     * we sent to the client.  Otherwise, it's the ID generated by the
-     * client for this event.  Note that it's possible to receive chunks
-     * in reply packets for which we are not registered.
-     *
-     * The handler may not modify the contents of "data".
-     */
-    abstract void handleChunk(Client client, int type,
-        ByteBuffer data, boolean isReply, int msgId);
-
-    /**
-     * Handle chunks not recognized by handlers.  The handleChunk() method
-     * in sub-classes should call this if the chunk type isn't recognized.
-     */
-    protected void handleUnknownChunk(Client client, int type,
-        ByteBuffer data, boolean isReply, int msgId) {
-        if (type == CHUNK_FAIL) {
-            int errorCode, msgLen;
-            String msg;
-
-            errorCode = data.getInt();
-            msgLen = data.getInt();
-            msg = getString(data, msgLen);
-            Log.w("ddms", "WARNING: failure code=" + errorCode + " msg=" + msg);
-        } else {
-            Log.w("ddms", "WARNING: received unknown chunk " + name(type)
-                + ": len=" + data.limit() + ", reply=" + isReply
-                + ", msgId=0x" + Integer.toHexString(msgId));
-        }
-        Log.w("ddms", "         client " + client + ", handler " + this);
-    }
-
-
-    /**
-     * Utility function to copy a String out of a ByteBuffer.
-     *
-     * This is here because multiple chunk handlers can make use of it,
-     * and there's nowhere better to put it.
-     */
-    static String getString(ByteBuffer buf, int len) {
-        char[] data = new char[len];
-        for (int i = 0; i < len; i++)
-            data[i] = buf.getChar();
-        return new String(data);
-    }
-
-    /**
-     * Utility function to copy a String into a ByteBuffer.
-     */
-    static void putString(ByteBuffer buf, String str) {
-        int len = str.length();
-        for (int i = 0; i < len; i++)
-            buf.putChar(str.charAt(i));
-    }
-
-    /**
-     * Convert a 4-character string to a 32-bit type.
-     */
-    static int type(String typeName) {
-        int val = 0;
-
-        if (typeName.length() != 4) {
-            Log.e("ddms", "Type name must be 4 letter long");
-            throw new RuntimeException("Type name must be 4 letter long");
-        }
-
-        for (int i = 0; i < 4; i++) {
-            val <<= 8;
-            val |= (byte) typeName.charAt(i);
-        }
-
-        return val;
-    }
-
-    /**
-     * Convert an integer type to a 4-character string.
-     */
-    static String name(int type) {
-        char[] ascii = new char[4];
-
-        ascii[0] = (char) ((type >> 24) & 0xff);
-        ascii[1] = (char) ((type >> 16) & 0xff);
-        ascii[2] = (char) ((type >> 8) & 0xff);
-        ascii[3] = (char) (type & 0xff);
-
-        return new String(ascii);
-    }
-
-    /**
-     * Allocate a ByteBuffer with enough space to hold the JDWP packet
-     * header and one chunk header in addition to the demands of the
-     * chunk being created.
-     *
-     * "maxChunkLen" indicates the size of the chunk contents only.
-     */
-    static ByteBuffer allocBuffer(int maxChunkLen) {
-        ByteBuffer buf =
-            ByteBuffer.allocate(JdwpPacket.JDWP_HEADER_LEN + 8 +maxChunkLen);
-        buf.order(CHUNK_ORDER);
-        return buf;
-    }
-
-    /**
-     * Return the slice of the JDWP packet buffer that holds just the
-     * chunk data.
-     */
-    static ByteBuffer getChunkDataBuf(ByteBuffer jdwpBuf) {
-        ByteBuffer slice;
-
-        assert jdwpBuf.position() == 0;
-
-        jdwpBuf.position(JdwpPacket.JDWP_HEADER_LEN + CHUNK_HEADER_LEN);
-        slice = jdwpBuf.slice();
-        slice.order(CHUNK_ORDER);
-        jdwpBuf.position(0);
-
-        return slice;
-    }
-
-    /**
-     * Write the chunk header at the start of the chunk.
-     *
-     * Pass in the byte buffer returned by JdwpPacket.getPayload().
-     */
-    static void finishChunkPacket(JdwpPacket packet, int type, int chunkLen) {
-        ByteBuffer buf = packet.getPayload();
-
-        buf.putInt(0x00, type);
-        buf.putInt(0x04, chunkLen);
-
-        packet.finishPacket(CHUNK_HEADER_LEN + chunkLen);
-    }
-
-    /**
-     * Check that the client is opened with the proper debugger port for the
-     * specified application name, and if not, reopen it.
-     * @param client
-     * @param uiThread
-     * @param appName
-     * @return
-     */
-    protected static Client checkDebuggerPortForAppName(Client client, String appName) {
-        IDebugPortProvider provider = DebugPortManager.getProvider();
-        if (provider != null) {
-            Device device = client.getDevice();
-            int newPort = provider.getPort(device, appName);
-
-            if (newPort != IDebugPortProvider.NO_STATIC_PORT &&
-                    newPort != client.getDebuggerListenPort()) {
-
-                AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-                if (bridge != null) {
-                    DeviceMonitor deviceMonitor = bridge.getDeviceMonitor();
-                    if (deviceMonitor != null) {
-                        deviceMonitor.addClientToDropAndReopen(client, newPort);
-                        client = null;
-                    }
-                }
-            }
-        }
-
-        return client;
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Client.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Client.java
deleted file mode 100644
index a4576aa..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Client.java
+++ /dev/null
@@ -1,768 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.DebugPortManager.IDebugPortProvider;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-
-import java.io.IOException;
-import java.nio.BufferOverflowException;
-import java.nio.ByteBuffer;
-import java.nio.channels.SelectionKey;
-import java.nio.channels.Selector;
-import java.nio.channels.SocketChannel;
-import java.util.HashMap;
-
-/**
- * This represents a single client, usually a DAlvik VM process.
- * <p/>This class gives access to basic client information, as well as methods to perform actions
- * on the client.
- * <p/>More detailed information, usually updated in real time, can be access through the
- * {@link ClientData} class. Each <code>Client</code> object has its own <code>ClientData</code>
- * accessed through {@link #getClientData()}.
- */
-public class Client {
-
-    private static final int SERVER_PROTOCOL_VERSION = 1;
-
-    /** Client change bit mask: application name change */
-    public static final int CHANGE_NAME = 0x0001;
-    /** Client change bit mask: debugger interest change */
-    public static final int CHANGE_DEBUGGER_INTEREST = 0x0002;
-    /** Client change bit mask: debugger port change */
-    public static final int CHANGE_PORT = 0x0004;
-    /** Client change bit mask: thread update flag change */
-    public static final int CHANGE_THREAD_MODE = 0x0008;
-    /** Client change bit mask: thread data updated */
-    public static final int CHANGE_THREAD_DATA = 0x0010;
-    /** Client change bit mask: heap update flag change */
-    public static final int CHANGE_HEAP_MODE = 0x0020;
-    /** Client change bit mask: head data updated */
-    public static final int CHANGE_HEAP_DATA = 0x0040;
-    /** Client change bit mask: native heap data updated */
-    public static final int CHANGE_NATIVE_HEAP_DATA = 0x0080;
-    /** Client change bit mask: thread stack trace updated */
-    public static final int CHANGE_THREAD_STACKTRACE = 0x0100;
-    /** Client change bit mask: allocation information updated */
-    public static final int CHANGE_HEAP_ALLOCATIONS = 0x0200;
-    /** Client change bit mask: allocation information updated */
-    public static final int CHANGE_HEAP_ALLOCATION_STATUS = 0x0400;
-
-    /** Client change bit mask: combination of {@link Client#CHANGE_NAME},
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, and {@link Client#CHANGE_PORT}.
-     */
-    public static final int CHANGE_INFO = CHANGE_NAME | CHANGE_DEBUGGER_INTEREST | CHANGE_PORT;
-
-    private SocketChannel mChan;
-
-    // debugger we're associated with, if any
-    private Debugger mDebugger;
-    private int mDebuggerListenPort;
-
-    // list of IDs for requests we have sent to the client
-    private HashMap<Integer,ChunkHandler> mOutstandingReqs;
-
-    // chunk handlers stash state data in here
-    private ClientData mClientData;
-
-    // User interface state.  Changing the value causes a message to be
-    // sent to the client.
-    private boolean mThreadUpdateEnabled;
-    private boolean mHeapUpdateEnabled;
-
-    /*
-     * Read/write buffers.  We can get large quantities of data from the
-     * client, e.g. the response to a "give me the list of all known classes"
-     * request from the debugger.  Requests from the debugger, and from us,
-     * are much smaller.
-     *
-     * Pass-through debugger traffic is sent without copying.  "mWriteBuffer"
-     * is only used for data generated within Client.
-     */
-    private static final int INITIAL_BUF_SIZE = 2*1024;
-    private static final int MAX_BUF_SIZE = 2*1024*1024;
-    private ByteBuffer mReadBuffer;
-
-    private static final int WRITE_BUF_SIZE = 256;
-    private ByteBuffer mWriteBuffer;
-
-    private Device mDevice;
-
-    private int mConnState;
-
-    private static final int ST_INIT         = 1;
-    private static final int ST_NOT_JDWP     = 2;
-    private static final int ST_AWAIT_SHAKE  = 10;
-    private static final int ST_NEED_DDM_PKT = 11;
-    private static final int ST_NOT_DDM      = 12;
-    private static final int ST_READY        = 13;
-    private static final int ST_ERROR        = 20;
-    private static final int ST_DISCONNECTED = 21;
-
-
-    /**
-     * Create an object for a new client connection.
-     *
-     * @param device the device this client belongs to
-     * @param chan the connected {@link SocketChannel}.
-     * @param pid the client pid.
-     */
-    Client(Device device, SocketChannel chan, int pid) {
-        mDevice = device;
-        mChan = chan;
-
-        mReadBuffer = ByteBuffer.allocate(INITIAL_BUF_SIZE);
-        mWriteBuffer = ByteBuffer.allocate(WRITE_BUF_SIZE);
-
-        mOutstandingReqs = new HashMap<Integer,ChunkHandler>();
-
-        mConnState = ST_INIT;
-
-        mClientData = new ClientData(pid);
-        
-        mThreadUpdateEnabled = DdmPreferences.getInitialThreadUpdate();
-        mHeapUpdateEnabled = DdmPreferences.getInitialHeapUpdate();
-    }
-
-    /**
-     * Returns a string representation of the {@link Client} object.
-     */
-    @Override
-    public String toString() {
-        return "[Client pid: " + mClientData.getPid() + "]";
-    }
-
-    /**
-     * Returns the {@link Device} on which this Client is running.
-     */
-    public Device getDevice() {
-        return mDevice;
-    }
-
-    /**
-     * Returns the debugger port for this client.
-     */
-    public int getDebuggerListenPort() {
-        return mDebuggerListenPort;
-    }
-
-    /**
-     * Returns <code>true</code> if the client VM is DDM-aware.
-     *
-     * Calling here is only allowed after the connection has been
-     * established.
-     */
-    public boolean isDdmAware() {
-        switch (mConnState) {
-            case ST_INIT:
-            case ST_NOT_JDWP:
-            case ST_AWAIT_SHAKE:
-            case ST_NEED_DDM_PKT:
-            case ST_NOT_DDM:
-            case ST_ERROR:
-            case ST_DISCONNECTED:
-                return false;
-            case ST_READY:
-                return true;
-            default:
-                assert false;
-                return false;
-        }
-    }
-
-    /**
-     * Returns <code>true</code> if a debugger is currently attached to the client.
-     */
-    public boolean isDebuggerAttached() {
-        return mDebugger.isDebuggerAttached();
-    }
-
-    /**
-     * Return the Debugger object associated with this client.
-     */
-    Debugger getDebugger() {
-        return mDebugger;
-    }
-
-    /**
-     * Returns the {@link ClientData} object containing this client information.
-     */
-    public ClientData getClientData() {
-        return mClientData;
-    }
-
-    /**
-     * Forces the client to execute its garbage collector.
-     */
-    public void executeGarbageCollector() {
-        try {
-            HandleHeap.sendHPGC(this);
-        } catch (IOException ioe) {
-            Log.w("ddms", "Send of HPGC message failed");
-            // ignore
-        }
-    }
-
-    /**
-     * Enables or disables the thread update.
-     * <p/>If <code>true</code> the VM will be able to send thread information. Thread information
-     * must be requested with {@link #requestThreadUpdate()}.
-     * @param enabled the enable flag.
-     */
-    public void setThreadUpdateEnabled(boolean enabled) {
-        mThreadUpdateEnabled = enabled;
-        if (enabled == false) {
-            mClientData.clearThreads();
-        }
-
-        try {
-            HandleThread.sendTHEN(this, enabled);
-        } catch (IOException ioe) {
-            // ignore it here; client will clean up shortly
-            ioe.printStackTrace();
-        }
-
-        update(CHANGE_THREAD_MODE);
-    }
-    
-    /**
-     * Returns whether the thread update is enabled.
-     */
-    public boolean isThreadUpdateEnabled() {
-        return mThreadUpdateEnabled;
-    }
-
-    /**
-     * Sends a thread update request. This is asynchronous.
-     * <p/>The thread info can be accessed by {@link ClientData#getThreads()}. The notification
-     * that the new data is available will be received through
-     * {@link IClientChangeListener#clientChanged(Client, int)} with a <code>changeMask</code>
-     * containing the mask {@link #CHANGE_THREAD_DATA}.
-     */
-    public void requestThreadUpdate() {
-        HandleThread.requestThreadUpdate(this);
-    }
-
-    /**
-     * Sends a thread stack trace update request. This is asynchronous.
-     * <p/>The thread info can be accessed by {@link ClientData#getThreads()} and
-     * {@link ThreadInfo#getStackTrace()}.
-     * <p/>The notification that the new data is available
-     * will be received through {@link IClientChangeListener#clientChanged(Client, int)}
-     * with a <code>changeMask</code> containing the mask {@link #CHANGE_THREAD_STACKTRACE}.
-     */
-    public void requestThreadStackTrace(int threadId) {
-        HandleThread.requestThreadStackCallRefresh(this, threadId);
-    }
-    
-    /**
-     * Enables or disables the heap update.
-     * <p/>If <code>true</code>, any GC will cause the client to send its heap information.
-     * <p/>The heap information can be accessed by {@link ClientData#getVmHeapData()}.
-     * <p/>The notification that the new data is available
-     * will be received through {@link IClientChangeListener#clientChanged(Client, int)}
-     * with a <code>changeMask</code> containing the value {@link #CHANGE_HEAP_DATA}.
-     * @param enabled the enable flag
-     */
-    public void setHeapUpdateEnabled(boolean enabled) {
-        mHeapUpdateEnabled = enabled;
-
-        try {
-            HandleHeap.sendHPIF(this,
-                    enabled ? HandleHeap.HPIF_WHEN_EVERY_GC : HandleHeap.HPIF_WHEN_NEVER);
-
-            HandleHeap.sendHPSG(this,
-                    enabled ? HandleHeap.WHEN_GC : HandleHeap.WHEN_DISABLE,
-                    HandleHeap.WHAT_MERGE);
-        } catch (IOException ioe) {
-            // ignore it here; client will clean up shortly
-        }
-
-        update(CHANGE_HEAP_MODE);
-    }
-
-    /**
-     * Returns whether the heap update is enabled.
-     * @see #setHeapUpdateEnabled(boolean)
-     */
-    public boolean isHeapUpdateEnabled() {
-        return mHeapUpdateEnabled;
-    }
-
-    /**
-     * Sends a native heap update request. this is asynchronous.
-     * <p/>The native heap info can be accessed by {@link ClientData#getNativeAllocationList()}.
-     * The notification that the new data is available will be received through
-     * {@link IClientChangeListener#clientChanged(Client, int)} with a <code>changeMask</code>
-     * containing the mask {@link #CHANGE_NATIVE_HEAP_DATA}.
-     */
-    public boolean requestNativeHeapInformation() {
-        try {
-            HandleNativeHeap.sendNHGT(this);
-            return true;
-        } catch (IOException e) {
-            Log.e("ddmlib", e);
-        }
-
-        return false;
-    }
-    
-    /**
-     * Enables or disables the Allocation tracker for this client.
-     * <p/>If enabled, the VM will start tracking allocation informations. A call to
-     * {@link #requestAllocationDetails()} will make the VM sends the information about all the
-     * allocations that happened between the enabling and the request.
-     * @param enable
-     * @see #requestAllocationDetails()
-     */
-    public void enableAllocationTracker(boolean enable) {
-        try {
-            HandleHeap.sendREAE(this, enable);
-        } catch (IOException e) {
-            Log.e("ddmlib", e);
-        }
-    }
-    
-    /**
-     * Sends a request to the VM to send the enable status of the allocation tracking.
-     * This is asynchronous.
-     * <p/>The allocation status can be accessed by {@link ClientData#getAllocationStatus()}.
-     * The notification that the new status is available will be received through
-     * {@link IClientChangeListener#clientChanged(Client, int)} with a <code>changeMask</code>
-     * containing the mask {@link #CHANGE_HEAP_ALLOCATION_STATUS}.
-     */
-    public void requestAllocationStatus() {
-        try {
-            HandleHeap.sendREAQ(this);
-        } catch (IOException e) {
-            Log.e("ddmlib", e);
-        }   
-    }
-    
-    /**
-     * Sends a request to the VM to send the information about all the allocations that have
-     * happened since the call to {@link #enableAllocationTracker(boolean)} with <var>enable</var>
-     * set to <code>null</code>. This is asynchronous.
-     * <p/>The allocation information can be accessed by {@link ClientData#getAllocations()}.
-     * The notification that the new data is available will be received through
-     * {@link IClientChangeListener#clientChanged(Client, int)} with a <code>changeMask</code>
-     * containing the mask {@link #CHANGE_HEAP_ALLOCATIONS}.
-     */
-    public void requestAllocationDetails() {
-        try {
-            HandleHeap.sendREAL(this);
-        } catch (IOException e) {
-            Log.e("ddmlib", e);
-        }
-    }
-
-    /**
-     * Sends a kill message to the VM.
-     */
-    public void kill() {
-        try {
-            HandleExit.sendEXIT(this, 1);
-        } catch (IOException ioe) {
-            Log.w("ddms", "Send of EXIT message failed");
-            // ignore
-        }
-    }
-
-    /**
-     * Registers the client with a Selector.
-     */
-    void register(Selector sel) throws IOException {
-        if (mChan != null) {
-            mChan.register(sel, SelectionKey.OP_READ, this);
-        }
-    }
-
-    /**
-     * Sets the client to accept debugger connection on the "selected debugger port".
-     *
-     * @see AndroidDebugBridge#setSelectedClient(Client)
-     * @see DdmPreferences#setSelectedDebugPort(int)
-     */
-    public void setAsSelectedClient() {
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (monitorThread != null) {
-            monitorThread.setSelectedClient(this);
-        }
-    }
-
-    /**
-     * Returns whether this client is the current selected client, accepting debugger connection
-     * on the "selected debugger port".
-     *
-     * @see #setAsSelectedClient()
-     * @see AndroidDebugBridge#setSelectedClient(Client)
-     * @see DdmPreferences#setSelectedDebugPort(int)
-     */
-    public boolean isSelectedClient() {
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (monitorThread != null) {
-            return monitorThread.getSelectedClient() == this;
-        }
-
-        return false;
-    }
-
-    /**
-     * Tell the client to open a server socket channel and listen for
-     * connections on the specified port.
-     */
-    void listenForDebugger(int listenPort) throws IOException {
-        mDebuggerListenPort = listenPort;
-        mDebugger = new Debugger(this, listenPort);
-    }
-
-    /**
-     * Initiate the JDWP handshake.
-     *
-     * On failure, closes the socket and returns false.
-     */
-    boolean sendHandshake() {
-        assert mWriteBuffer.position() == 0;
-
-        try {
-            // assume write buffer can hold 14 bytes
-            JdwpPacket.putHandshake(mWriteBuffer);
-            int expectedLen = mWriteBuffer.position();
-            mWriteBuffer.flip();
-            if (mChan.write(mWriteBuffer) != expectedLen)
-                throw new IOException("partial handshake write");
-        }
-        catch (IOException ioe) {
-            Log.e("ddms-client", "IO error during handshake: " + ioe.getMessage());
-            mConnState = ST_ERROR;
-            close(true /* notify */);
-            return false;
-        }
-        finally {
-            mWriteBuffer.clear();
-        }
-
-        mConnState = ST_AWAIT_SHAKE;
-        
-        return true;
-    }
-
-
-    /**
-     * Send a non-DDM packet to the client.
-     *
-     * Equivalent to sendAndConsume(packet, null).
-     */
-    void sendAndConsume(JdwpPacket packet) throws IOException {
-        sendAndConsume(packet, null);
-    }
-
-    /**
-     * Send a DDM packet to the client.
-     *
-     * Ideally, we can do this with a single channel write.  If that doesn't
-     * happen, we have to prevent anybody else from writing to the channel
-     * until this packet completes, so we synchronize on the channel.
-     *
-     * Another goal is to avoid unnecessary buffer copies, so we write
-     * directly out of the JdwpPacket's ByteBuffer.
-     */
-    void sendAndConsume(JdwpPacket packet, ChunkHandler replyHandler)
-        throws IOException {
-
-        if (mChan == null) {
-            // can happen for e.g. THST packets
-            Log.v("ddms", "Not sending packet -- client is closed");
-            return;
-        }
-
-        if (replyHandler != null) {
-            /*
-             * Add the ID to the list of outstanding requests.  We have to do
-             * this before sending the packet, in case the response comes back
-             * before our thread returns from the packet-send function.
-             */
-            addRequestId(packet.getId(), replyHandler);
-        }
-
-        synchronized (mChan) {
-            try {
-                packet.writeAndConsume(mChan);
-            }
-            catch (IOException ioe) {
-                removeRequestId(packet.getId());
-                throw ioe;
-            }
-        }
-    }
-
-    /**
-     * Forward the packet to the debugger (if still connected to one).
-     *
-     * Consumes the packet.
-     */
-    void forwardPacketToDebugger(JdwpPacket packet)
-        throws IOException {
-
-        Debugger dbg = mDebugger;
-
-        if (dbg == null) {
-            Log.i("ddms", "Discarding packet");
-            packet.consume();
-        } else {
-            dbg.sendAndConsume(packet);
-        }
-    }
-
-    /**
-     * Read data from our channel.
-     *
-     * This is called when data is known to be available, and we don't yet
-     * have a full packet in the buffer.  If the buffer is at capacity,
-     * expand it.
-     */
-    void read()
-        throws IOException, BufferOverflowException {
-
-        int count;
-
-        if (mReadBuffer.position() == mReadBuffer.capacity()) {
-            if (mReadBuffer.capacity() * 2 > MAX_BUF_SIZE) {
-                Log.e("ddms", "Exceeded MAX_BUF_SIZE!");
-                throw new BufferOverflowException();
-            }
-            Log.d("ddms", "Expanding read buffer to "
-                + mReadBuffer.capacity() * 2);
-
-            ByteBuffer newBuffer = ByteBuffer.allocate(mReadBuffer.capacity() * 2);
-
-            // copy entire buffer to new buffer
-            mReadBuffer.position(0);
-            newBuffer.put(mReadBuffer);  // leaves "position" at end of copied
-
-            mReadBuffer = newBuffer;
-        }
-
-        count = mChan.read(mReadBuffer);
-        if (count < 0)
-            throw new IOException("read failed");
-
-        if (Log.Config.LOGV) Log.v("ddms", "Read " + count + " bytes from " + this);
-        //Log.hexDump("ddms", Log.DEBUG, mReadBuffer.array(),
-        //    mReadBuffer.arrayOffset(), mReadBuffer.position());
-    }
-
-    /**
-     * Return information for the first full JDWP packet in the buffer.
-     *
-     * If we don't yet have a full packet, return null.
-     *
-     * If we haven't yet received the JDWP handshake, we watch for it here
-     * and consume it without admitting to have done so.  Upon receipt
-     * we send out the "HELO" message, which is why this can throw an
-     * IOException.
-     */
-    JdwpPacket getJdwpPacket() throws IOException {
-
-        /*
-         * On entry, the data starts at offset 0 and ends at "position".
-         * "limit" is set to the buffer capacity.
-         */
-        if (mConnState == ST_AWAIT_SHAKE) {
-            /*
-             * The first thing we get from the client is a response to our
-             * handshake.  It doesn't look like a packet, so we have to
-             * handle it specially.
-             */
-            int result;
-
-            result = JdwpPacket.findHandshake(mReadBuffer);
-            //Log.v("ddms", "findHand: " + result);
-            switch (result) {
-                case JdwpPacket.HANDSHAKE_GOOD:
-                    Log.i("ddms",
-                        "Good handshake from client, sending HELO to " + mClientData.getPid());
-                    JdwpPacket.consumeHandshake(mReadBuffer);
-                    mConnState = ST_NEED_DDM_PKT;
-                    HandleHello.sendHELO(this, SERVER_PROTOCOL_VERSION);
-                    // see if we have another packet in the buffer
-                    return getJdwpPacket();
-                case JdwpPacket.HANDSHAKE_BAD:
-                    Log.i("ddms", "Bad handshake from client");
-                    if (MonitorThread.getInstance().getRetryOnBadHandshake()) {
-                        // we should drop the client, but also attempt to reopen it.
-                        // This is done by the DeviceMonitor.
-                        mDevice.getMonitor().addClientToDropAndReopen(this,
-                                IDebugPortProvider.NO_STATIC_PORT);
-                    } else {
-                        // mark it as bad, close the socket, and don't retry
-                        mConnState = ST_NOT_JDWP;
-                        close(true /* notify */);
-                    }
-                    break;
-                case JdwpPacket.HANDSHAKE_NOTYET:
-                    Log.i("ddms", "No handshake from client yet.");
-                    break;
-                default:
-                    Log.e("ddms", "Unknown packet while waiting for client handshake");
-            }
-            return null;
-        } else if (mConnState == ST_NEED_DDM_PKT ||
-            mConnState == ST_NOT_DDM ||
-            mConnState == ST_READY) {
-            /*
-             * Normal packet traffic.
-             */
-            if (mReadBuffer.position() != 0) {
-                if (Log.Config.LOGV) Log.v("ddms",
-                    "Checking " + mReadBuffer.position() + " bytes");
-            }
-            return JdwpPacket.findPacket(mReadBuffer);
-        } else {
-            /*
-             * Not expecting data when in this state.
-             */
-            Log.e("ddms", "Receiving data in state = " + mConnState);
-        }
-        
-        return null;
-    }
-
-    /*
-     * Add the specified ID to the list of request IDs for which we await
-     * a response.
-     */
-    private void addRequestId(int id, ChunkHandler handler) {
-        synchronized (mOutstandingReqs) {
-            if (Log.Config.LOGV) Log.v("ddms",
-                "Adding req 0x" + Integer.toHexString(id) +" to set");
-            mOutstandingReqs.put(id, handler);
-        }
-    }
-
-    /*
-     * Remove the specified ID from the list, if present.
-     */
-    void removeRequestId(int id) {
-        synchronized (mOutstandingReqs) {
-            if (Log.Config.LOGV) Log.v("ddms",
-                "Removing req 0x" + Integer.toHexString(id) + " from set");
-            mOutstandingReqs.remove(id);
-        }
-
-        //Log.w("ddms", "Request " + Integer.toHexString(id)
-        //    + " could not be removed from " + this);
-    }
-
-    /**
-     * Determine whether this is a response to a request we sent earlier.
-     * If so, return the ChunkHandler responsible.
-     */
-    ChunkHandler isResponseToUs(int id) {
-
-        synchronized (mOutstandingReqs) {
-            ChunkHandler handler = mOutstandingReqs.get(id);
-            if (handler != null) {
-                if (Log.Config.LOGV) Log.v("ddms",
-                    "Found 0x" + Integer.toHexString(id)
-                    + " in request set - " + handler);
-                return handler;
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * An earlier request resulted in a failure.  This is the expected
-     * response to a HELO message when talking to a non-DDM client.
-     */
-    void packetFailed(JdwpPacket reply) {
-        if (mConnState == ST_NEED_DDM_PKT) {
-            Log.i("ddms", "Marking " + this + " as non-DDM client");
-            mConnState = ST_NOT_DDM;
-        } else if (mConnState != ST_NOT_DDM) {
-            Log.w("ddms", "WEIRD: got JDWP failure packet on DDM req");
-        }
-    }
-
-    /**
-     * The MonitorThread calls this when it sees a DDM request or reply.
-     * If we haven't seen a DDM packet before, we advance the state to
-     * ST_READY and return "false".  Otherwise, just return true.
-     *
-     * The idea is to let the MonitorThread know when we first see a DDM
-     * packet, so we can send a broadcast to the handlers when a client
-     * connection is made.  This method is synchronized so that we only
-     * send the broadcast once.
-     */
-    synchronized boolean ddmSeen() {
-        if (mConnState == ST_NEED_DDM_PKT) {
-            mConnState = ST_READY;
-            return false;
-        } else if (mConnState != ST_READY) {
-            Log.w("ddms", "WEIRD: in ddmSeen with state=" + mConnState);
-        }
-        return true;
-    }
-
-    /**
-     * Close the client socket channel.  If there is a debugger associated
-     * with us, close that too.
-     *
-     * Closing a channel automatically unregisters it from the selector.
-     * However, we have to iterate through the selector loop before it
-     * actually lets them go and allows the file descriptors to close.
-     * The caller is expected to manage that.
-     * @param notify Whether or not to notify the listeners of a change.
-     */
-    void close(boolean notify) {
-        Log.i("ddms", "Closing " + this.toString());
-
-        mOutstandingReqs.clear();
-
-        try {
-            if (mChan != null) {
-                mChan.close();
-                mChan = null;
-            }
-
-            if (mDebugger != null) {
-                mDebugger.close();
-                mDebugger = null;
-            }
-        }
-        catch (IOException ioe) {
-            Log.w("ddms", "failed to close " + this);
-            // swallow it -- not much else to do
-        }
-
-        mDevice.removeClient(this, notify);
-    }
-    
-    /**
-     * Returns whether this {@link Client} has a valid connection to the application VM.
-     */
-    public boolean isValid() {
-        return mChan != null;
-    }
-
-    void update(int changeMask) {
-        mDevice.update(this, changeMask);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ClientData.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ClientData.java
deleted file mode 100644
index 2b46b6f..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ClientData.java
+++ /dev/null
@@ -1,502 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.HeapSegment.HeapSegmentElement;
-
-import java.nio.BufferUnderflowException;
-import java.nio.ByteBuffer;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.TreeMap;
-import java.util.TreeSet;
-
-
-/**
- * Contains the data of a {@link Client}.
- */
-public class ClientData {
-    /* This is a place to stash data associated with a Client, such as thread
-    * states or heap data.  ClientData maps 1:1 to Client, but it's a little
-    * cleaner if we separate the data out.
-    *
-    * Message handlers are welcome to stash arbitrary data here.
-    *
-    * IMPORTANT: The data here is written by HandleFoo methods and read by
-    * FooPanel methods, which run in different threads.  All non-trivial
-    * access should be synchronized against the ClientData object.
-    */
-
-    
-    /** Temporary name of VM to be ignored. */
-    private final static String PRE_INITIALIZED = "<pre-initialized>"; //$NON-NLS-1$
-
-    /** Debugger connection status: not waiting on one, not connected to one, but accepting
-     * new connections. This is the default value. */
-    public static final int DEBUGGER_DEFAULT = 1;
-    /**
-     * Debugger connection status: the application's VM is paused, waiting for a debugger to
-     * connect to it before resuming. */
-    public static final int DEBUGGER_WAITING = 2;
-    /** Debugger connection status : Debugger is connected */
-    public static final int DEBUGGER_ATTACHED = 3;
-    /** Debugger connection status: The listening port for debugger connection failed to listen.
-     * No debugger will be able to connect. */
-    public static final int DEBUGGER_ERROR = 4;
-    
-    /**
-     * Allocation tracking status: unknown.
-     * <p/>This happens right after a {@link Client} is discovered
-     * by the {@link AndroidDebugBridge}, and before the {@link Client} answered the query regarding
-     * its allocation tracking status.
-     * @see Client#requestAllocationStatus()
-     */
-    public static final int ALLOCATION_TRACKING_UNKNOWN = -1;
-    /**
-     * Allocation tracking status: the {@link Client} is not tracking allocations. */
-    public static final int ALLOCATION_TRACKING_OFF = 0;
-    /**
-     * Allocation tracking status: the {@link Client} is tracking allocations. */
-    public static final int ALLOCATION_TRACKING_ON = 1;
-
-    /**
-     * Name of the value representing the max size of the heap, in the {@link Map} returned by
-     * {@link #getVmHeapInfo(int)}
-     */
-    public final static String HEAP_MAX_SIZE_BYTES = "maxSizeInBytes"; // $NON-NLS-1$
-    /**
-     * Name of the value representing the size of the heap, in the {@link Map} returned by
-     * {@link #getVmHeapInfo(int)}
-     */
-    public final static String HEAP_SIZE_BYTES = "sizeInBytes"; // $NON-NLS-1$
-    /**
-     * Name of the value representing the number of allocated bytes of the heap, in the
-     * {@link Map} returned by {@link #getVmHeapInfo(int)}
-     */
-    public final static String HEAP_BYTES_ALLOCATED = "bytesAllocated"; // $NON-NLS-1$
-    /**
-     * Name of the value representing the number of objects in the heap, in the {@link Map}
-     * returned by {@link #getVmHeapInfo(int)}
-     */
-    public final static String HEAP_OBJECTS_ALLOCATED = "objectsAllocated"; // $NON-NLS-1$
-
-    // is this a DDM-aware client?
-    private boolean mIsDdmAware;
-
-    // the client's process ID
-    private final int mPid;
-
-    // Java VM identification string
-    private String mVmIdentifier;
-
-    // client's self-description
-    private String mClientDescription;
-
-    // how interested are we in a debugger?
-    private int mDebuggerInterest;
-
-    // Thread tracking (THCR, THDE).
-    private TreeMap<Integer,ThreadInfo> mThreadMap;
-
-    /** VM Heap data */
-    private final HeapData mHeapData = new HeapData();
-    /** Native Heap data */
-    private final HeapData mNativeHeapData = new HeapData();
-
-    private HashMap<Integer, HashMap<String, Long>> mHeapInfoMap =
-            new HashMap<Integer, HashMap<String, Long>>();
-
-
-    /** library map info. Stored here since the backtrace data
-     * is computed on a need to display basis.
-     */
-    private ArrayList<NativeLibraryMapInfo> mNativeLibMapInfo =
-        new ArrayList<NativeLibraryMapInfo>();
-
-    /** Native Alloc info list */
-    private ArrayList<NativeAllocationInfo> mNativeAllocationList =
-        new ArrayList<NativeAllocationInfo>();
-    private int mNativeTotalMemory;
-
-    private AllocationInfo[] mAllocations;
-    private int mAllocationStatus = ALLOCATION_TRACKING_UNKNOWN;
-
-    /**
-     * Heap Information.
-     * <p/>The heap is composed of several {@link HeapSegment} objects.
-     * <p/>A call to {@link #isHeapDataComplete()} will indicate if the segments (available through
-     * {@link #getHeapSegments()}) represent the full heap.
-     */
-    public static class HeapData {
-        private TreeSet<HeapSegment> mHeapSegments = new TreeSet<HeapSegment>();
-        private boolean mHeapDataComplete = false;
-        private byte[] mProcessedHeapData;
-        private Map<Integer, ArrayList<HeapSegmentElement>> mProcessedHeapMap;
-
-        /**
-         * Abandon the current list of heap segments.
-         */
-        public synchronized void clearHeapData() {
-            /* Abandon the old segments instead of just calling .clear().
-             * This lets the user hold onto the old set if it wants to.
-             */
-            mHeapSegments = new TreeSet<HeapSegment>();
-            mHeapDataComplete = false;
-        }
-
-        /**
-         * Add raw HPSG chunk data to the list of heap segments.
-         *
-         * @param data The raw data from an HPSG chunk.
-         */
-        synchronized void addHeapData(ByteBuffer data) {
-            HeapSegment hs;
-
-            if (mHeapDataComplete) {
-                clearHeapData();
-            }
-
-            try {
-                hs = new HeapSegment(data);
-            } catch (BufferUnderflowException e) {
-                System.err.println("Discarding short HPSG data (length " + data.limit() + ")");
-                return;
-            }
-
-            mHeapSegments.add(hs);
-        }
-
-        /**
-         * Called when all heap data has arrived.
-         */
-        synchronized void sealHeapData() {
-            mHeapDataComplete = true;
-        }
-
-        /**
-         * Returns whether the heap data has been sealed.
-         */
-        public boolean isHeapDataComplete() {
-            return mHeapDataComplete;
-        }
-
-        /**
-         * Get the collected heap data, if sealed.
-         *
-         * @return The list of heap segments if the heap data has been sealed, or null if it hasn't.
-         */
-        public Collection<HeapSegment> getHeapSegments() {
-            if (isHeapDataComplete()) {
-                return mHeapSegments;
-            }
-            return null;
-        }
-
-        /**
-         * Sets the processed heap data.
-         *
-         * @param heapData The new heap data (can be null)
-         */
-        public void setProcessedHeapData(byte[] heapData) {
-            mProcessedHeapData = heapData;
-        }
-
-        /**
-         * Get the processed heap data, if present.
-         *
-         * @return the processed heap data, or null.
-         */
-        public byte[] getProcessedHeapData() {
-            return mProcessedHeapData;
-        }
-
-        public void setProcessedHeapMap(Map<Integer, ArrayList<HeapSegmentElement>> heapMap) {
-            mProcessedHeapMap = heapMap;
-        }
-        
-        public Map<Integer, ArrayList<HeapSegmentElement>> getProcessedHeapMap() {
-            return mProcessedHeapMap;
-        }
-        
-
-    }
-
-
-    /**
-     * Generic constructor.
-     */
-    ClientData(int pid) {
-        mPid = pid;
-
-        mDebuggerInterest = DEBUGGER_DEFAULT;
-        mThreadMap = new TreeMap<Integer,ThreadInfo>();
-    }
-    
-    /**
-     * Returns whether the process is DDM-aware.
-     */
-    public boolean isDdmAware() {
-        return mIsDdmAware;
-    }
-
-    /**
-     * Sets DDM-aware status.
-     */
-    void isDdmAware(boolean aware) {
-        mIsDdmAware = aware;
-    }
-
-    /**
-     * Returns the process ID.
-     */
-    public int getPid() {
-        return mPid;
-    }
-
-    /**
-     * Returns the Client's VM identifier.
-     */
-    public String getVmIdentifier() {
-        return mVmIdentifier;
-    }
-
-    /**
-     * Sets VM identifier.
-     */
-    void setVmIdentifier(String ident) {
-        mVmIdentifier = ident;
-    }
-
-    /**
-     * Returns the client description.
-     * <p/>This is generally the name of the package defined in the
-     * <code>AndroidManifest.xml</code>.
-     * 
-     * @return the client description or <code>null</code> if not the description was not yet
-     * sent by the client.
-     */
-    public String getClientDescription() {
-        return mClientDescription;
-    }
-
-    /**
-     * Sets client description.
-     *
-     * There may be a race between HELO and APNM.  Rather than try
-     * to enforce ordering on the device, we just don't allow an empty
-     * name to replace a specified one.
-     */
-    void setClientDescription(String description) {
-        if (mClientDescription == null && description.length() > 0) {
-            /*
-             * The application VM is first named <pre-initialized> before being assigned
-             * its real name.
-             * Depending on the timing, we can get an APNM chunk setting this name before
-             * another one setting the final actual name. So if we get a SetClientDescription
-             * with this value we ignore it.
-             */
-            if (PRE_INITIALIZED.equals(description) == false) {
-                mClientDescription = description;
-            }
-        }
-    }
-    
-    /**
-     * Returns the debugger connection status. Possible values are {@link #DEBUGGER_DEFAULT},
-     * {@link #DEBUGGER_WAITING}, {@link #DEBUGGER_ATTACHED}, and {@link #DEBUGGER_ERROR}.
-     */
-    public int getDebuggerConnectionStatus() {
-        return mDebuggerInterest;
-    }
-
-    /**
-     * Sets debugger connection status.
-     */
-    void setDebuggerConnectionStatus(int val) {
-        mDebuggerInterest = val;
-    }
-
-    /**
-     * Sets the current heap info values for the specified heap.
-     *
-     * @param heapId The heap whose info to update
-     * @param sizeInBytes The size of the heap, in bytes
-     * @param bytesAllocated The number of bytes currently allocated in the heap
-     * @param objectsAllocated The number of objects currently allocated in
-     *                         the heap
-     */
-    // TODO: keep track of timestamp, reason
-    synchronized void setHeapInfo(int heapId, long maxSizeInBytes,
-            long sizeInBytes, long bytesAllocated, long objectsAllocated) {
-        HashMap<String, Long> heapInfo = new HashMap<String, Long>();
-        heapInfo.put(HEAP_MAX_SIZE_BYTES, maxSizeInBytes);
-        heapInfo.put(HEAP_SIZE_BYTES, sizeInBytes);
-        heapInfo.put(HEAP_BYTES_ALLOCATED, bytesAllocated);
-        heapInfo.put(HEAP_OBJECTS_ALLOCATED, objectsAllocated);
-        mHeapInfoMap.put(heapId, heapInfo);
-    }
-
-    /**
-     * Returns the {@link HeapData} object for the VM.
-     */
-    public HeapData getVmHeapData() {
-        return mHeapData;
-    }
-
-    /**
-     * Returns the {@link HeapData} object for the native code.
-     */
-    HeapData getNativeHeapData() {
-        return mNativeHeapData;
-    }
-
-    /**
-     * Returns an iterator over the list of known VM heap ids.
-     * <p/>
-     * The caller must synchronize on the {@link ClientData} object while iterating.
-     *
-     * @return an iterator over the list of heap ids
-     */
-    public synchronized Iterator<Integer> getVmHeapIds() {
-        return mHeapInfoMap.keySet().iterator();
-    }
-
-    /**
-     * Returns the most-recent info values for the specified VM heap.
-     *
-     * @param heapId The heap whose info should be returned
-     * @return a map containing the info values for the specified heap.
-     *         Returns <code>null</code> if the heap ID is unknown.
-     */
-    public synchronized Map<String, Long> getVmHeapInfo(int heapId) {
-        return mHeapInfoMap.get(heapId);
-    }
-
-    /**
-     * Adds a new thread to the list.
-     */
-    synchronized void addThread(int threadId, String threadName) {
-        ThreadInfo attr = new ThreadInfo(threadId, threadName);
-        mThreadMap.put(threadId, attr);
-    }
-
-    /**
-     * Removes a thread from the list.
-     */
-    synchronized void removeThread(int threadId) {
-        mThreadMap.remove(threadId);
-    }
-
-    /**
-     * Returns the list of threads as {@link ThreadInfo} objects.
-     * <p/>The list is empty until a thread update was requested with
-     * {@link Client#requestThreadUpdate()}.
-     */
-    public synchronized ThreadInfo[] getThreads() {
-        Collection<ThreadInfo> threads = mThreadMap.values();
-        return threads.toArray(new ThreadInfo[threads.size()]);
-    }
-
-    /**
-     * Returns the {@link ThreadInfo} by thread id.
-     */
-    synchronized ThreadInfo getThread(int threadId) {
-        return mThreadMap.get(threadId);
-    }
-    
-    synchronized void clearThreads() {
-        mThreadMap.clear();
-    }
-
-    /**
-     * Returns the list of {@link NativeAllocationInfo}.
-     * @see Client#requestNativeHeapInformation()
-     */
-    public synchronized List<NativeAllocationInfo> getNativeAllocationList() {
-        return Collections.unmodifiableList(mNativeAllocationList);
-    }
-
-    /**
-     * adds a new {@link NativeAllocationInfo} to the {@link Client}
-     * @param allocInfo The {@link NativeAllocationInfo} to add.
-     */
-    synchronized void addNativeAllocation(NativeAllocationInfo allocInfo) {
-        mNativeAllocationList.add(allocInfo);
-    }
-
-    /**
-     * Clear the current malloc info.
-     */
-    synchronized void clearNativeAllocationInfo() {
-        mNativeAllocationList.clear();
-    }
-
-    /**
-     * Returns the total native memory.
-     * @see Client#requestNativeHeapInformation()
-     */
-    public synchronized int getTotalNativeMemory() {
-        return mNativeTotalMemory;
-    }
-
-    synchronized void setTotalNativeMemory(int totalMemory) {
-        mNativeTotalMemory = totalMemory;
-    }
-
-    synchronized void addNativeLibraryMapInfo(long startAddr, long endAddr, String library) {
-        mNativeLibMapInfo.add(new NativeLibraryMapInfo(startAddr, endAddr, library));
-    }
-
-    /**
-     * Returns an {@link Iterator} on {@link NativeLibraryMapInfo} objects.
-     * <p/>
-     * The caller must synchronize on the {@link ClientData} object while iterating.
-     */
-    public synchronized Iterator<NativeLibraryMapInfo> getNativeLibraryMapInfo() {
-        return mNativeLibMapInfo.iterator();
-    }
-    
-    synchronized void setAllocationStatus(boolean enabled) {
-        mAllocationStatus = enabled ? ALLOCATION_TRACKING_ON : ALLOCATION_TRACKING_OFF;
-    }
-
-    /**
-     * Returns the allocation tracking status.
-     * @see Client#requestAllocationStatus()
-     */
-    public synchronized int getAllocationStatus() {
-        return mAllocationStatus;
-    }
-    
-    synchronized void setAllocations(AllocationInfo[] allocs) {
-        mAllocations = allocs;
-    }
-    
-    /**
-     * Returns the list of tracked allocations.
-     * @see Client#requestAllocationDetails()
-     */
-    public synchronized AllocationInfo[] getAllocations() {
-        return mAllocations;
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DdmPreferences.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DdmPreferences.java
deleted file mode 100644
index c96d40d..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DdmPreferences.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Log.LogLevel;
-
-/**
- * Preferences for the ddm library.
- * <p/>This class does not handle storing the preferences. It is merely a central point for
- * applications using the ddmlib to override the default values.
- * <p/>Various components of the ddmlib query this class to get their values.
- * <p/>Calls to some <code>set##()</code> methods will update the components using the values
- * right away, while other methods will have no effect once {@link AndroidDebugBridge#init(boolean)}
- * has been called.
- * <p/>Check the documentation of each method.
- */
-public final class DdmPreferences {
-
-    /** Default value for thread update flag upon client connection. */
-    public final static boolean DEFAULT_INITIAL_THREAD_UPDATE = false;
-    /** Default value for heap update flag upon client connection. */
-    public final static boolean DEFAULT_INITIAL_HEAP_UPDATE = false;
-    /** Default value for the selected client debug port */
-    public final static int DEFAULT_SELECTED_DEBUG_PORT = 8700;
-    /** Default value for the debug port base */
-    public final static int DEFAULT_DEBUG_PORT_BASE = 8600;
-    /** Default value for the logcat {@link LogLevel} */
-    public final static LogLevel DEFAULT_LOG_LEVEL = LogLevel.ERROR;
-
-    private static boolean sThreadUpdate = DEFAULT_INITIAL_THREAD_UPDATE;
-    private static boolean sInitialHeapUpdate = DEFAULT_INITIAL_HEAP_UPDATE;
-
-    private static int sSelectedDebugPort = DEFAULT_SELECTED_DEBUG_PORT;
-    private static int sDebugPortBase = DEFAULT_DEBUG_PORT_BASE;
-    private static LogLevel sLogLevel = DEFAULT_LOG_LEVEL;
-
-    /**
-     * Returns the initial {@link Client} flag for thread updates.
-     * @see #setInitialThreadUpdate(boolean)
-     */
-    public static boolean getInitialThreadUpdate() {
-        return sThreadUpdate;
-    }
-
-    /**
-     * Sets the initial {@link Client} flag for thread updates.
-     * <p/>This change takes effect right away, for newly created {@link Client} objects.
-     */
-    public static void setInitialThreadUpdate(boolean state) {
-        sThreadUpdate = state;
-    }
-
-    /**
-     * Returns the initial {@link Client} flag for heap updates.
-     * @see #setInitialHeapUpdate(boolean)
-     */
-    public static boolean getInitialHeapUpdate() {
-        return sInitialHeapUpdate;
-    }
-
-    /**
-     * Sets the initial {@link Client} flag for heap updates.
-     * <p/>If <code>true</code>, the {@link ClientData} will automatically be updated with
-     * the VM heap information whenever a GC happens. 
-     * <p/>This change takes effect right away, for newly created {@link Client} objects.
-     */
-    public static void setInitialHeapUpdate(boolean state) {
-        sInitialHeapUpdate = state;
-    }
-
-    /**
-     * Returns the debug port used by the selected {@link Client}.
-     */
-    public static int getSelectedDebugPort() {
-        return sSelectedDebugPort;
-    }
-
-    /**
-     * Sets the debug port used by the selected {@link Client}.
-     * <p/>This change takes effect right away.
-     * @param port the new port to use.
-     */
-    public static void setSelectedDebugPort(int port) {
-        sSelectedDebugPort = port;
-
-        MonitorThread monitorThread = MonitorThread.getInstance();
-        if (monitorThread != null) {
-            monitorThread.setDebugSelectedPort(port);
-        }
-    }
-
-    /**
-     * Returns the debug port used by the first {@link Client}. Following clients, will use the
-     * next port.
-     */
-    public static int getDebugPortBase() {
-        return sDebugPortBase;
-    }
-
-    /**
-     * Sets the debug port used by the first {@link Client}.
-     * <p/>Once a port is used, the next Client will use port + 1. Quitting applications will
-     * release their debug port, and new clients will be able to reuse them.
-     * <p/>This must be called before {@link AndroidDebugBridge#init(boolean)}.
-     */
-    public static void setDebugPortBase(int port) {
-        sDebugPortBase = port;
-    }
-
-    /**
-     * Returns the minimum {@link LogLevel} being displayed.
-     */
-    public static LogLevel getLogLevel() {
-        return sLogLevel;
-    }
-
-    /**
-     * Sets the minimum {@link LogLevel} to display.
-     * <p/>This change takes effect right away.
-     */
-    public static void setLogLevel(String value) {
-        sLogLevel = LogLevel.getByString(value);
-
-        Log.setLevel(sLogLevel);
-    }
-    
-    /**
-     * Non accessible constructor.
-     */
-    private DdmPreferences() {
-        // pass, only static methods in the class.
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DebugPortManager.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DebugPortManager.java
deleted file mode 100644
index 9392127..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DebugPortManager.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Device;
-
-/**
- * Centralized point to provide a {@link IDebugPortProvider} to ddmlib. 
- * 
- * <p/>When {@link Client} objects are created, they start listening for debuggers on a specific
- * port. The default behavior is to start with {@link DdmPreferences#getDebugPortBase()} and 
- * increment this value for each new <code>Client</code>.
- * 
- * <p/>This {@link DebugPortManager} allows applications using ddmlib to provide a custom
- * port provider on a per-<code>Client</code> basis, depending on the device/emulator they are
- * running on, and/or their names.
- */
-public class DebugPortManager {
-
-    /**
-     * Classes which implement this interface provide a method that provides a non random
-     * debugger port for a newly created {@link Client}.
-     */
-    public interface IDebugPortProvider {
-
-        public static final int NO_STATIC_PORT = -1;
-
-        /**
-         * Returns a non-random debugger port for the specified application running on the
-         * specified {@link Device}.
-         * @param device The device the application is running on.
-         * @param appName The application name, as defined in the <code>AndroidManifest.xml</code>
-         * <var>package</var> attribute of the <var>manifest</var> node.
-         * @return The non-random debugger port or {@link #NO_STATIC_PORT} if the {@link Client}
-         * should use the automatic debugger port provider.
-         */
-        public int getPort(Device device, String appName);
-    }
-
-    private static IDebugPortProvider sProvider = null;
-
-    /**
-     * Sets the {@link IDebugPortProvider} that will be used when a new {@link Client} requests
-     * a debugger port.
-     * @param provider the <code>IDebugPortProvider</code> to use.
-     */
-    public static void setProvider(IDebugPortProvider provider) {
-        sProvider = provider;
-    }
-
-    /**
-     * Returns the 
-     * @return
-     */
-    static IDebugPortProvider getProvider() {
-        return sProvider;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Debugger.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Debugger.java
deleted file mode 100644
index f30509a..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Debugger.java
+++ /dev/null
@@ -1,351 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.nio.BufferOverflowException;
-import java.nio.ByteBuffer;
-import java.nio.channels.SelectionKey;
-import java.nio.channels.Selector;
-import java.nio.channels.ServerSocketChannel;
-import java.nio.channels.SocketChannel;
-
-/**
- * This represents a pending or established connection with a JDWP debugger.
- */
-class Debugger {
-
-    /*
-     * Messages from the debugger should be pretty small; may not even
-     * need an expanding-buffer implementation for this.
-     */
-    private static final int INITIAL_BUF_SIZE = 1 * 1024;
-    private static final int MAX_BUF_SIZE = 32 * 1024;
-    private ByteBuffer mReadBuffer;
-
-    private static final int PRE_DATA_BUF_SIZE = 256;
-    private ByteBuffer mPreDataBuffer;
-
-    /* connection state */
-    private int mConnState;
-    private static final int ST_NOT_CONNECTED = 1;
-    private static final int ST_AWAIT_SHAKE   = 2;
-    private static final int ST_READY         = 3;
-
-    /* peer */
-    private Client mClient;         // client we're forwarding to/from
-    private int mListenPort;        // listen to me
-    private ServerSocketChannel mListenChannel;
-
-    /* this goes up and down; synchronize methods that access the field */
-    private SocketChannel mChannel;
-
-    /**
-     * Create a new Debugger object, configured to listen for connections
-     * on a specific port.
-     */
-    Debugger(Client client, int listenPort) throws IOException {
-
-        mClient = client;
-        mListenPort = listenPort;
-
-        mListenChannel = ServerSocketChannel.open();
-        mListenChannel.configureBlocking(false);        // required for Selector
-
-        InetSocketAddress addr = new InetSocketAddress(
-                InetAddress.getByName("localhost"), // $NON-NLS-1$
-                listenPort);
-        mListenChannel.socket().setReuseAddress(true);  // enable SO_REUSEADDR
-        mListenChannel.socket().bind(addr);
-
-        mReadBuffer = ByteBuffer.allocate(INITIAL_BUF_SIZE);
-        mPreDataBuffer = ByteBuffer.allocate(PRE_DATA_BUF_SIZE);
-        mConnState = ST_NOT_CONNECTED;
-
-        Log.i("ddms", "Created: " + this.toString());
-    }
-
-    /**
-     * Returns "true" if a debugger is currently attached to us.
-     */
-    boolean isDebuggerAttached() {
-        return mChannel != null;
-    }
-
-    /**
-     * Represent the Debugger as a string.
-     */
-    @Override
-    public String toString() {
-        // mChannel != null means we have connection, ST_READY means it's going
-        return "[Debugger " + mListenPort + "-->" + mClient.getClientData().getPid()
-                + ((mConnState != ST_READY) ? " inactive]" : " active]");
-    }
-
-    /**
-     * Register the debugger's listen socket with the Selector.
-     */
-    void registerListener(Selector sel) throws IOException {
-        mListenChannel.register(sel, SelectionKey.OP_ACCEPT, this);
-    }
-
-    /**
-     * Return the Client being debugged.
-     */
-    Client getClient() {
-        return mClient;
-    }
-
-    /**
-     * Accept a new connection, but only if we don't already have one.
-     *
-     * Must be synchronized with other uses of mChannel and mPreBuffer.
-     *
-     * Returns "null" if we're already talking to somebody.
-     */
-    synchronized SocketChannel accept() throws IOException {
-        return accept(mListenChannel);
-    }
-
-    /**
-     * Accept a new connection from the specified listen channel.  This
-     * is so we can listen on a dedicated port for the "current" client,
-     * where "current" is constantly in flux.
-     *
-     * Must be synchronized with other uses of mChannel and mPreBuffer.
-     *
-     * Returns "null" if we're already talking to somebody.
-     */
-    synchronized SocketChannel accept(ServerSocketChannel listenChan)
-        throws IOException {
-
-        if (listenChan != null) {
-            SocketChannel newChan;
-    
-            newChan = listenChan.accept();
-            if (mChannel != null) {
-                Log.w("ddms", "debugger already talking to " + mClient
-                    + " on " + mListenPort);
-                newChan.close();
-                return null;
-            }
-            mChannel = newChan;
-            mChannel.configureBlocking(false);         // required for Selector
-            mConnState = ST_AWAIT_SHAKE;
-            return mChannel;
-        }
-        
-        return null;
-    }
-
-    /**
-     * Close the data connection only.
-     */
-    synchronized void closeData() {
-        try {
-            if (mChannel != null) {
-                mChannel.close();
-                mChannel = null;
-                mConnState = ST_NOT_CONNECTED;
-
-                ClientData cd = mClient.getClientData();
-                cd.setDebuggerConnectionStatus(ClientData.DEBUGGER_DEFAULT);
-                mClient.update(Client.CHANGE_DEBUGGER_INTEREST);
-            }
-        } catch (IOException ioe) {
-            Log.w("ddms", "Failed to close data " + this);
-        }
-    }
-
-    /**
-     * Close the socket that's listening for new connections and (if
-     * we're connected) the debugger data socket.
-     */
-    synchronized void close() {
-        try {
-            if (mListenChannel != null) {
-                mListenChannel.close();
-            }
-            mListenChannel = null;
-            closeData();
-        } catch (IOException ioe) {
-            Log.w("ddms", "Failed to close listener " + this);
-        }
-    }
-
-    // TODO: ?? add a finalizer that verifies the channel was closed
-
-    /**
-     * Read data from our channel.
-     *
-     * This is called when data is known to be available, and we don't yet
-     * have a full packet in the buffer.  If the buffer is at capacity,
-     * expand it.
-     */
-    void read() throws IOException {
-        int count;
-
-        if (mReadBuffer.position() == mReadBuffer.capacity()) {
-            if (mReadBuffer.capacity() * 2 > MAX_BUF_SIZE) {
-                throw new BufferOverflowException();
-            }
-            Log.d("ddms", "Expanding read buffer to "
-                + mReadBuffer.capacity() * 2);
-
-            ByteBuffer newBuffer =
-                    ByteBuffer.allocate(mReadBuffer.capacity() * 2);
-            mReadBuffer.position(0);
-            newBuffer.put(mReadBuffer);     // leaves "position" at end
-
-            mReadBuffer = newBuffer;
-        }
-
-        count = mChannel.read(mReadBuffer);
-        Log.v("ddms", "Read " + count + " bytes from " + this);
-        if (count < 0) throw new IOException("read failed");
-    }
-
-    /**
-     * Return information for the first full JDWP packet in the buffer.
-     *
-     * If we don't yet have a full packet, return null.
-     *
-     * If we haven't yet received the JDWP handshake, we watch for it here
-     * and consume it without admitting to have done so.  We also send
-     * the handshake response to the debugger, along with any pending
-     * pre-connection data, which is why this can throw an IOException.
-     */
-    JdwpPacket getJdwpPacket() throws IOException {
-        /*
-         * On entry, the data starts at offset 0 and ends at "position".
-         * "limit" is set to the buffer capacity.
-         */
-        if (mConnState == ST_AWAIT_SHAKE) {
-            int result;
-
-            result = JdwpPacket.findHandshake(mReadBuffer);
-            //Log.v("ddms", "findHand: " + result);
-            switch (result) {
-                case JdwpPacket.HANDSHAKE_GOOD:
-                    Log.i("ddms", "Good handshake from debugger");
-                    JdwpPacket.consumeHandshake(mReadBuffer);
-                    sendHandshake();
-                    mConnState = ST_READY;
-
-                    ClientData cd = mClient.getClientData();
-                    cd.setDebuggerConnectionStatus(ClientData.DEBUGGER_ATTACHED);
-                    mClient.update(Client.CHANGE_DEBUGGER_INTEREST);
-
-                    // see if we have another packet in the buffer
-                    return getJdwpPacket();
-                case JdwpPacket.HANDSHAKE_BAD:
-                    // not a debugger, throw an exception so we drop the line
-                    Log.i("ddms", "Bad handshake from debugger");
-                    throw new IOException("bad handshake");
-                case JdwpPacket.HANDSHAKE_NOTYET:
-                    break;
-                default:
-                    Log.e("ddms", "Unknown packet while waiting for client handshake");
-            }
-            return null;
-        } else if (mConnState == ST_READY) {
-            if (mReadBuffer.position() != 0) {
-                Log.v("ddms", "Checking " + mReadBuffer.position() + " bytes");
-            }
-            return JdwpPacket.findPacket(mReadBuffer);
-        } else {
-            Log.e("ddms", "Receiving data in state = " + mConnState);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Forward a packet to the client.
-     *
-     * "mClient" will never be null, though it's possible that the channel
-     * in the client has closed and our send attempt will fail.
-     *
-     * Consumes the packet.
-     */
-    void forwardPacketToClient(JdwpPacket packet) throws IOException {
-        mClient.sendAndConsume(packet);
-    }
-
-    /**
-     * Send the handshake to the debugger.  We also send along any packets
-     * we already received from the client (usually just a VM_START event,
-     * if anything at all).
-     */
-    private synchronized void sendHandshake() throws IOException {
-        ByteBuffer tempBuffer = ByteBuffer.allocate(JdwpPacket.HANDSHAKE_LEN);
-        JdwpPacket.putHandshake(tempBuffer);
-        int expectedLength = tempBuffer.position();
-        tempBuffer.flip();
-        if (mChannel.write(tempBuffer) != expectedLength) {
-            throw new IOException("partial handshake write");
-        }
-
-        expectedLength = mPreDataBuffer.position();
-        if (expectedLength > 0) {
-            Log.d("ddms", "Sending " + mPreDataBuffer.position()
-                    + " bytes of saved data");
-            mPreDataBuffer.flip();
-            if (mChannel.write(mPreDataBuffer) != expectedLength) {
-                throw new IOException("partial pre-data write");
-            }
-            mPreDataBuffer.clear();
-        }
-    }
-
-    /**
-     * Send a packet to the debugger.
-     *
-     * Ideally, we can do this with a single channel write.  If that doesn't
-     * happen, we have to prevent anybody else from writing to the channel
-     * until this packet completes, so we synchronize on the channel.
-     *
-     * Another goal is to avoid unnecessary buffer copies, so we write
-     * directly out of the JdwpPacket's ByteBuffer.
-     *
-     * We must synchronize on "mChannel" before writing to it.  We want to
-     * coordinate the buffered data with mChannel creation, so this whole
-     * method is synchronized.
-     */
-    synchronized void sendAndConsume(JdwpPacket packet)
-        throws IOException {
-
-        if (mChannel == null) {
-            /*
-             * Buffer this up so we can send it to the debugger when it
-             * finally does connect.  This is essential because the VM_START
-             * message might be telling the debugger that the VM is
-             * suspended.  The alternative approach would be for us to
-             * capture and interpret VM_START and send it later if we
-             * didn't choose to un-suspend the VM for our own purposes.
-             */
-            Log.d("ddms", "Saving packet 0x"
-                    + Integer.toHexString(packet.getId()));
-            packet.movePacket(mPreDataBuffer);
-        } else {
-            packet.writeAndConsume(mChannel);
-        }
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Device.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Device.java
deleted file mode 100644
index 34ef432..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Device.java
+++ /dev/null
@@ -1,376 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.log.LogReceiver;
-
-import java.io.IOException;
-import java.nio.channels.SocketChannel;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-
-/**
- * A Device. It can be a physical device or an emulator.
- * 
- * TODO: make this class package-protected, and shift all callers to use IDevice
- */
-public final class Device implements IDevice {
-    /**
-     * The state of a device.
-     */
-    public static enum DeviceState {
-        BOOTLOADER("bootloader"), //$NON-NLS-1$
-        OFFLINE("offline"), //$NON-NLS-1$
-        ONLINE("device"); //$NON-NLS-1$
-
-        private String mState;
-
-        DeviceState(String state) {
-            mState = state;
-        }
-
-        /**
-         * Returns a {@link DeviceState} from the string returned by <code>adb devices</code>.
-         * @param state the device state.
-         * @return a {@link DeviceState} object or <code>null</code> if the state is unknown.
-         */
-        public static DeviceState getState(String state) {
-            for (DeviceState deviceState : values()) {
-                if (deviceState.mState.equals(state)) {
-                    return deviceState;
-                }
-            }
-            return null;
-        }
-    }
-    
-    /** Emulator Serial Number regexp. */
-    final static String RE_EMULATOR_SN = "emulator-(\\d+)"; //$NON-NLS-1$
-    
-    /** Serial number of the device */
-    String serialNumber = null;
-
-    /** Name of the AVD */
-    String mAvdName = null;
-
-    /** State of the device. */
-    DeviceState state = null;
-    
-    /** Device properties. */
-    private final Map<String, String> mProperties = new HashMap<String, String>();
-
-    private final ArrayList<Client> mClients = new ArrayList<Client>();
-    private DeviceMonitor mMonitor;
-
-    /**
-     * Socket for the connection monitoring client connection/disconnection.
-     */
-    private SocketChannel mSocketChannel;
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getSerialNumber()
-     */
-    public String getSerialNumber() {
-        return serialNumber;
-    }
-    
-    public String getAvdName() {
-        return mAvdName;
-    }
-
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getState()
-     */
-    public DeviceState getState() {
-        return state;
-    }
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getProperties()
-     */
-    public Map<String, String> getProperties() {
-        return Collections.unmodifiableMap(mProperties);
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getPropertyCount()
-     */
-    public int getPropertyCount() {
-        return mProperties.size();
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getProperty(java.lang.String)
-     */
-    public String getProperty(String name) {
-        return mProperties.get(name);
-    }
-    
-
-    @Override
-    public String toString() {
-        return serialNumber;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#isOnline()
-     */
-    public boolean isOnline() {
-        return state == DeviceState.ONLINE;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#isEmulator()
-     */
-    public boolean isEmulator() {
-        return serialNumber.matches(RE_EMULATOR_SN);
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#isOffline()
-     */
-    public boolean isOffline() {
-        return state == DeviceState.OFFLINE;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#isBootLoader()
-     */
-    public boolean isBootLoader() {
-        return state == DeviceState.BOOTLOADER;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#hasClients()
-     */
-    public boolean hasClients() {
-        return mClients.size() > 0;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getClients()
-     */
-    public Client[] getClients() {
-        synchronized (mClients) {
-            return mClients.toArray(new Client[mClients.size()]);
-        }
-    }
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getClient(java.lang.String)
-     */
-    public Client getClient(String applicationName) {
-        synchronized (mClients) {
-            for (Client c : mClients) {
-                if (applicationName.equals(c.getClientData().getClientDescription())) {
-                    return c;
-                }
-            }
-
-        }
-
-        return null;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getSyncService()
-     */
-    public SyncService getSyncService() {
-        SyncService syncService = new SyncService(AndroidDebugBridge.sSocketAddr, this);
-        if (syncService.openSync()) {
-            return syncService;
-         }
-
-        return null;
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getFileListingService()
-     */
-    public FileListingService getFileListingService() {
-        return new FileListingService(this);
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getScreenshot()
-     */
-    public RawImage getScreenshot() throws IOException {
-        return AdbHelper.getFrameBuffer(AndroidDebugBridge.sSocketAddr, this);
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#executeShellCommand(java.lang.String, com.android.ddmlib.IShellOutputReceiver)
-     */
-    public void executeShellCommand(String command, IShellOutputReceiver receiver)
-            throws IOException {
-        AdbHelper.executeRemoteCommand(AndroidDebugBridge.sSocketAddr, command, this,
-                receiver);
-    }
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#runEventLogService(com.android.ddmlib.log.LogReceiver)
-     */
-    public void runEventLogService(LogReceiver receiver) throws IOException {
-        AdbHelper.runEventLogService(AndroidDebugBridge.sSocketAddr, this, receiver);
-    }
-    
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#createForward(int, int)
-     */
-    public boolean createForward(int localPort, int remotePort) {
-        try {
-            return AdbHelper.createForward(AndroidDebugBridge.sSocketAddr, this,
-                    localPort, remotePort);
-        } catch (IOException e) {
-            Log.e("adb-forward", e); //$NON-NLS-1$
-            return false;
-        }
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#removeForward(int, int)
-     */
-    public boolean removeForward(int localPort, int remotePort) {
-        try {
-            return AdbHelper.removeForward(AndroidDebugBridge.sSocketAddr, this,
-                    localPort, remotePort);
-        } catch (IOException e) {
-            Log.e("adb-remove-forward", e); //$NON-NLS-1$
-            return false;
-        }
-    }
-
-    /* 
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IDevice#getClientName(int)
-     */
-    public String getClientName(int pid) {
-        synchronized (mClients) {
-            for (Client c : mClients) {
-                if (c.getClientData().getPid() == pid) {
-                    return c.getClientData().getClientDescription();
-                }
-            }
-        }
-
-        return null;
-    }
-
-
-    Device(DeviceMonitor monitor) {
-        mMonitor = monitor;
-    }
-
-    DeviceMonitor getMonitor() {
-        return mMonitor;
-    }
-
-    void addClient(Client client) {
-        synchronized (mClients) {
-            mClients.add(client);
-        }
-    }
-
-    List<Client> getClientList() {
-        return mClients;
-    }
-
-    boolean hasClient(int pid) {
-        synchronized (mClients) {
-            for (Client client : mClients) {
-                if (client.getClientData().getPid() == pid) {
-                    return true;
-                }
-            }
-        }
-
-        return false;
-    }
-    
-    void clearClientList() {
-        synchronized (mClients) {
-            mClients.clear();
-        }
-    }
-
-    /**
-     * Sets the client monitoring socket.
-     * @param socketChannel the sockets
-     */
-    void setClientMonitoringSocket(SocketChannel socketChannel) {
-        mSocketChannel = socketChannel;
-    }
-
-    /**
-     * Returns the client monitoring socket.
-     */
-    SocketChannel getClientMonitoringSocket() {
-        return mSocketChannel;
-    }
-
-    /**
-     * Removes a {@link Client} from the list.
-     * @param client the client to remove.
-     * @param notify Whether or not to notify the listeners of a change.
-     */
-    void removeClient(Client client, boolean notify) {
-        mMonitor.addPortToAvailableList(client.getDebuggerListenPort());
-        synchronized (mClients) {
-            mClients.remove(client);
-        }
-        if (notify) {
-            mMonitor.getServer().deviceChanged(this, CHANGE_CLIENT_LIST);
-        }
-    }
-
-    void update(int changeMask) {
-        mMonitor.getServer().deviceChanged(this, changeMask);
-    }
-
-    void update(Client client, int changeMask) {
-        mMonitor.getServer().clientChanged(client, changeMask);
-    }
-
-    void addProperty(String label, String value) {
-        mProperties.put(label, value);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DeviceMonitor.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DeviceMonitor.java
deleted file mode 100644
index f9d0fa0..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/DeviceMonitor.java
+++ /dev/null
@@ -1,866 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.AdbHelper.AdbResponse;
-import com.android.ddmlib.DebugPortManager.IDebugPortProvider;
-import com.android.ddmlib.Device.DeviceState;
-
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.UnknownHostException;
-import java.nio.ByteBuffer;
-import java.nio.channels.AsynchronousCloseException;
-import java.nio.channels.SelectionKey;
-import java.nio.channels.Selector;
-import java.nio.channels.SocketChannel;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-/**
- * A Device monitor. This connects to the Android Debug Bridge and get device and
- * debuggable process information from it.
- */
-final class DeviceMonitor {
-    private byte[] mLengthBuffer = new byte[4];
-    private byte[] mLengthBuffer2 = new byte[4];
-
-    private boolean mQuit = false;
-
-    private AndroidDebugBridge mServer;
-
-    private SocketChannel mMainAdbConnection = null;
-    private boolean mMonitoring = false;
-    private int mConnectionAttempt = 0;
-    private int mRestartAttemptCount = 0;
-    private boolean mInitialDeviceListDone = false;
-
-    private Selector mSelector;
-
-    private final ArrayList<Device> mDevices = new ArrayList<Device>();
-
-    private final ArrayList<Integer> mDebuggerPorts = new ArrayList<Integer>();
-
-    private final HashMap<Client, Integer> mClientsToReopen = new HashMap<Client, Integer>();
-
-    /**
-     * Creates a new {@link DeviceMonitor} object and links it to the running
-     * {@link AndroidDebugBridge} object.
-     * @param server the running {@link AndroidDebugBridge}.
-     */
-    DeviceMonitor(AndroidDebugBridge server) {
-        mServer = server;
-
-        mDebuggerPorts.add(DdmPreferences.getDebugPortBase());
-    }
-
-    /**
-     * Starts the monitoring.
-     */
-    void start() {
-        new Thread("Device List Monitor") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                deviceMonitorLoop();
-            }
-        }.start();
-    }
-
-    /**
-     * Stops the monitoring.
-     */
-    void stop() {
-        mQuit = true;
-
-        // wakeup the main loop thread by closing the main connection to adb.
-        try {
-            if (mMainAdbConnection != null) {
-                mMainAdbConnection.close();
-            }
-        } catch (IOException e1) {
-        }
-
-        // wake up the secondary loop by closing the selector.
-        if (mSelector != null) {
-            mSelector.wakeup();
-        }
-    }
-
-
-
-    /**
-     * Returns if the monitor is currently connected to the debug bridge server.
-     * @return
-     */
-    boolean isMonitoring() {
-        return mMonitoring;
-    }
-    
-    int getConnectionAttemptCount() {
-        return mConnectionAttempt;
-    }
-    
-    int getRestartAttemptCount() {
-        return mRestartAttemptCount;
-    }
-
-    /**
-     * Returns the devices.
-     */
-    Device[] getDevices() {
-        synchronized (mDevices) {
-            return mDevices.toArray(new Device[mDevices.size()]);
-        }
-    }
-    
-    boolean hasInitialDeviceList() {
-        return mInitialDeviceListDone;
-    }
-
-    AndroidDebugBridge getServer() {
-        return mServer;
-    }
-
-    void addClientToDropAndReopen(Client client, int port) {
-        synchronized (mClientsToReopen) {
-            Log.d("DeviceMonitor",
-                    "Adding " + client + " to list of client to reopen (" + port +").");
-            if (mClientsToReopen.get(client) == null) {
-                mClientsToReopen.put(client, port);
-            }
-        }
-        mSelector.wakeup();
-    }
-
-    /**
-     * Monitors the devices. This connects to the Debug Bridge
-     */
-    private void deviceMonitorLoop() {
-        do {
-            try {
-                if (mMainAdbConnection == null) {
-                    Log.d("DeviceMonitor", "Opening adb connection");
-                    mMainAdbConnection = openAdbConnection();
-                    if (mMainAdbConnection == null) {
-                        mConnectionAttempt++;
-                        Log.e("DeviceMonitor", "Connection attempts: " + mConnectionAttempt);
-                        if (mConnectionAttempt > 10) {
-                            if (mServer.startAdb() == false) {
-                                mRestartAttemptCount++;
-                                Log.e("DeviceMonitor",
-                                        "adb restart attempts: " + mRestartAttemptCount);
-                            } else {
-                                mRestartAttemptCount = 0;
-                            }
-                        }
-                        waitABit();
-                    } else {
-                        Log.d("DeviceMonitor", "Connected to adb for device monitoring");
-                        mConnectionAttempt = 0;
-                    }
-                }
-
-                if (mMainAdbConnection != null && mMonitoring == false) {
-                    mMonitoring = sendDeviceListMonitoringRequest();
-                }
-
-                if (mMonitoring) {
-                    // read the length of the incoming message
-                    int length = readLength(mMainAdbConnection, mLengthBuffer);
-                    
-                    if (length >= 0) {
-                        // read the incoming message
-                        processIncomingDeviceData(length);
-                        
-                        // flag the fact that we have build the list at least once.
-                        mInitialDeviceListDone = true;
-                    }
-                }
-            } catch (AsynchronousCloseException ace) {
-                // this happens because of a call to Quit. We do nothing, and the loop will break.
-            } catch (IOException ioe) {
-                if (mQuit == false) {
-                    Log.e("DeviceMonitor", "Adb connection Error:" + ioe.getMessage());
-                    mMonitoring = false;
-                    if (mMainAdbConnection != null) {
-                        try {
-                            mMainAdbConnection.close();
-                        } catch (IOException ioe2) {
-                            // we can safely ignore that one.
-                        }
-                        mMainAdbConnection = null;
-                    }
-                }
-            }
-        } while (mQuit == false);
-    }
-
-    /**
-     * Sleeps for a little bit.
-     */
-    private void waitABit() {
-        try {
-            Thread.sleep(1000);
-        } catch (InterruptedException e1) {
-        }
-    }
-
-    /**
-     * Attempts to connect to the debug bridge server.
-     * @return a connect socket if success, null otherwise
-     */
-    private SocketChannel openAdbConnection() {
-        Log.d("DeviceMonitor", "Connecting to adb for Device List Monitoring...");
-
-        SocketChannel adbChannel = null;
-        try {
-            adbChannel = SocketChannel.open(AndroidDebugBridge.sSocketAddr);
-            adbChannel.socket().setTcpNoDelay(true);
-        } catch (IOException e) {
-        }
-
-        return adbChannel;
-    }
-
-    /**
-     *
-     * @return
-     * @throws IOException
-     */
-    private boolean sendDeviceListMonitoringRequest() throws IOException {
-        byte[] request = AdbHelper.formAdbRequest("host:track-devices"); //$NON-NLS-1$
-
-        if (AdbHelper.write(mMainAdbConnection, request) == false) {
-            Log.e("DeviceMonitor", "Sending Tracking request failed!");
-            mMainAdbConnection.close();
-            throw new IOException("Sending Tracking request failed!");
-        }
-
-        AdbResponse resp = AdbHelper.readAdbResponse(mMainAdbConnection,
-                false /* readDiagString */);
-
-        if (resp.ioSuccess == false) {
-            Log.e("DeviceMonitor", "Failed to read the adb response!");
-            mMainAdbConnection.close();
-            throw new IOException("Failed to read the adb response!");
-        }
-
-        if (resp.okay == false) {
-            // request was refused by adb!
-            Log.e("DeviceMonitor", "adb refused request: " + resp.message);
-        }
-
-        return resp.okay;
-    }
-
-    /**
-     * Processes an incoming device message from the socket
-     * @param socket
-     * @param length
-     * @throws IOException
-     */
-    private void processIncomingDeviceData(int length) throws IOException {
-        ArrayList<Device> list = new ArrayList<Device>();
-        
-        if (length > 0) {
-            byte[] buffer = new byte[length];
-            String result = read(mMainAdbConnection, buffer);
-            
-            String[] devices = result.split("\n"); // $NON-NLS-1$
-
-            for (String d : devices) {
-                String[] param = d.split("\t"); // $NON-NLS-1$
-                if (param.length == 2) {
-                    // new adb uses only serial numbers to identify devices
-                    Device device = new Device(this);
-                    device.serialNumber = param[0];
-                    device.state = DeviceState.getState(param[1]);
-
-                    //add the device to the list
-                    list.add(device);
-                }
-            }
-        }
-
-        // now merge the new devices with the old ones.
-        updateDevices(list);
-    }
-
-    /**
-     *  Updates the device list with the new items received from the monitoring service.
-     */
-    private void updateDevices(ArrayList<Device> newList) {
-        // because we are going to call mServer.deviceDisconnected which will acquire this lock
-        // we lock it first, so that the AndroidDebugBridge lock is always locked first.
-        synchronized (AndroidDebugBridge.getLock()) {
-            synchronized (mDevices) {
-                // For each device in the current list, we look for a matching the new list.
-                // * if we find it, we update the current object with whatever new information
-                //   there is
-                //   (mostly state change, if the device becomes ready, we query for build info).
-                //   We also remove the device from the new list to mark it as "processed"
-                // * if we do not find it, we remove it from the current list.
-                // Once this is done, the new list contains device we aren't monitoring yet, so we
-                // add them to the list, and start monitoring them.
-    
-                for (int d = 0 ; d < mDevices.size() ;) {
-                    Device device = mDevices.get(d);
-    
-                    // look for a similar device in the new list.
-                    int count = newList.size();
-                    boolean foundMatch = false;
-                    for (int dd = 0 ; dd < count ; dd++) {
-                        Device newDevice = newList.get(dd);
-                        // see if it matches in id and serial number.
-                        if (newDevice.serialNumber.equals(device.serialNumber)) {
-                            foundMatch = true;
-    
-                            // update the state if needed.
-                            if (device.state != newDevice.state) {
-                                device.state = newDevice.state;
-                                device.update(Device.CHANGE_STATE);
-    
-                                // if the device just got ready/online, we need to start
-                                // monitoring it.
-                                if (device.isOnline()) {
-                                    if (AndroidDebugBridge.getClientSupport() == true) {
-                                        if (startMonitoringDevice(device) == false) {
-                                            Log.e("DeviceMonitor",
-                                                    "Failed to start monitoring "
-                                                    + device.serialNumber);
-                                        }
-                                    }
-
-                                    if (device.getPropertyCount() == 0) {
-                                        queryNewDeviceForInfo(device);
-                                    }
-                                }
-                            }
-    
-                            // remove the new device from the list since it's been used
-                            newList.remove(dd);
-                            break;
-                        }
-                    }
-    
-                    if (foundMatch == false) {
-                        // the device is gone, we need to remove it, and keep current index
-                        // to process the next one.
-                        removeDevice(device);
-                        mServer.deviceDisconnected(device);
-                    } else {
-                        // process the next one
-                        d++;
-                    }
-                }
-    
-                // at this point we should still have some new devices in newList, so we
-                // process them.
-                for (Device newDevice : newList) {
-                    // add them to the list
-                    mDevices.add(newDevice);
-                    mServer.deviceConnected(newDevice);
-    
-                    // start monitoring them.
-                    if (AndroidDebugBridge.getClientSupport() == true) {
-                        if (newDevice.isOnline()) {
-                            startMonitoringDevice(newDevice);
-                        }
-                    }
-    
-                    // look for their build info.
-                    if (newDevice.isOnline()) {
-                        queryNewDeviceForInfo(newDevice);
-                    }
-                }
-            }
-        }
-        newList.clear();
-    }
-
-    private void removeDevice(Device device) {
-        device.clearClientList();
-        mDevices.remove(device);
-        
-        SocketChannel channel = device.getClientMonitoringSocket();
-        if (channel != null) {
-            try {
-                channel.close();
-            } catch (IOException e) {
-                // doesn't really matter if the close fails.
-            }
-        }
-    }
-
-    /**
-     * Queries a device for its build info.
-     * @param device the device to query.
-     */
-    private void queryNewDeviceForInfo(Device device) {
-        // TODO: do this in a separate thread.
-        try {
-            // first get the list of properties.
-            device.executeShellCommand(GetPropReceiver.GETPROP_COMMAND,
-                    new GetPropReceiver(device));
-            
-            // now get the emulator Virtual Device name (if applicable).
-            if (device.isEmulator()) {
-                EmulatorConsole console = EmulatorConsole.getConsole(device);
-                if (console != null) {
-                    device.mAvdName = console.getAvdName();
-                }
-            }
-        } catch (IOException e) {
-            // if we can't get the build info, it doesn't matter too much
-        }
-    }
-
-    /**
-     * Starts a monitoring service for a device.
-     * @param device the device to monitor.
-     * @return true if success.
-     */
-    private boolean startMonitoringDevice(Device device) {
-        SocketChannel socketChannel = openAdbConnection();
-
-        if (socketChannel != null) {
-            try {
-                boolean result = sendDeviceMonitoringRequest(socketChannel, device);
-                if (result) {
-
-                    if (mSelector == null) {
-                        startDeviceMonitorThread();
-                    }
-
-                    device.setClientMonitoringSocket(socketChannel);
-
-                    synchronized (mDevices) {
-                        // always wakeup before doing the register. The synchronized block
-                        // ensure that the selector won't select() before the end of this block.
-                        // @see deviceClientMonitorLoop
-                        mSelector.wakeup();
-
-                        socketChannel.configureBlocking(false);
-                        socketChannel.register(mSelector, SelectionKey.OP_READ, device);
-                    }
-
-                    return true;
-                }
-            } catch (IOException e) {
-                try {
-                    // attempt to close the socket if needed.
-                    socketChannel.close();
-                } catch (IOException e1) {
-                    // we can ignore that one. It may already have been closed.
-                }
-                Log.d("DeviceMonitor",
-                        "Connection Failure when starting to monitor device '"
-                        + device + "' : " + e.getMessage());
-            }
-        }
-
-        return false;
-    }
-
-    private void startDeviceMonitorThread() throws IOException {
-        mSelector = Selector.open();
-        new Thread("Device Client Monitor") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                deviceClientMonitorLoop();
-            }
-        }.start();
-    }
-
-    private void deviceClientMonitorLoop() {
-        do {
-            try {
-                // This synchronized block stops us from doing the select() if a new
-                // Device is being added.
-                // @see startMonitoringDevice()
-                synchronized (mDevices) {
-                }
-
-                int count = mSelector.select();
-
-                if (mQuit) {
-                    return;
-                }
-
-                synchronized (mClientsToReopen) {
-                    if (mClientsToReopen.size() > 0) {
-                        Set<Client> clients = mClientsToReopen.keySet();
-                        MonitorThread monitorThread = MonitorThread.getInstance();
-
-                        for (Client client : clients) {
-                            Device device = client.getDevice();
-                            int pid = client.getClientData().getPid();
-
-                            monitorThread.dropClient(client, false /* notify */);
-
-                            // This is kinda bad, but if we don't wait a bit, the client
-                            // will never answer the second handshake!
-                            waitABit();
-
-                            int port = mClientsToReopen.get(client);
-
-                            if (port == IDebugPortProvider.NO_STATIC_PORT) {
-                                port = getNextDebuggerPort();
-                            }
-                            Log.d("DeviceMonitor", "Reopening " + client);
-                            openClient(device, pid, port, monitorThread);
-                            device.update(Device.CHANGE_CLIENT_LIST);
-                        }
-
-                        mClientsToReopen.clear();
-                    }
-                }
-
-                if (count == 0) {
-                    continue;
-                }
-
-                Set<SelectionKey> keys = mSelector.selectedKeys();
-                Iterator<SelectionKey> iter = keys.iterator();
-
-                while (iter.hasNext()) {
-                    SelectionKey key = iter.next();
-                    iter.remove();
-
-                    if (key.isValid() && key.isReadable()) {
-                        Object attachment = key.attachment();
-
-                        if (attachment instanceof Device) {
-                            Device device = (Device)attachment;
-
-                            SocketChannel socket = device.getClientMonitoringSocket();
-
-                            if (socket != null) {
-                                try {
-                                    int length = readLength(socket, mLengthBuffer2);
-
-                                    processIncomingJdwpData(device, socket, length);
-                                } catch (IOException ioe) {
-                                    Log.d("DeviceMonitor",
-                                            "Error reading jdwp list: " + ioe.getMessage());
-                                    socket.close();
-
-                                    // restart the monitoring of that device
-                                    synchronized (mDevices) {
-                                        if (mDevices.contains(device)) {
-                                            Log.d("DeviceMonitor",
-                                                    "Restarting monitoring service for " + device);
-                                            startMonitoringDevice(device);
-                                        }
-                                    }
-                                }
-                            }
-                        }
-                    }
-                }
-            } catch (IOException e) {
-                if (mQuit == false) {
-
-                }
-            }
-
-        } while (mQuit == false);
-    }
-
-    private boolean sendDeviceMonitoringRequest(SocketChannel socket, Device device)
-            throws IOException {
-
-        AdbHelper.setDevice(socket, device);
-
-        byte[] request = AdbHelper.formAdbRequest("track-jdwp"); //$NON-NLS-1$
-
-        if (AdbHelper.write(socket, request) == false) {
-            Log.e("DeviceMonitor", "Sending jdwp tracking request failed!");
-            socket.close();
-            throw new IOException();
-        }
-
-        AdbResponse resp = AdbHelper.readAdbResponse(socket, false /* readDiagString */);
-
-        if (resp.ioSuccess == false) {
-            Log.e("DeviceMonitor", "Failed to read the adb response!");
-            socket.close();
-            throw new IOException();
-        }
-
-        if (resp.okay == false) {
-            // request was refused by adb!
-            Log.e("DeviceMonitor", "adb refused request: " + resp.message);
-        }
-
-        return resp.okay;
-    }
-
-    private void processIncomingJdwpData(Device device, SocketChannel monitorSocket, int length)
-            throws IOException {
-        if (length >= 0) {
-            // array for the current pids.
-            ArrayList<Integer> pidList = new ArrayList<Integer>();
-
-            // get the string data if there are any
-            if (length > 0) {
-                byte[] buffer = new byte[length];
-                String result = read(monitorSocket, buffer);
-    
-                // split each line in its own list and create an array of integer pid
-                String[] pids = result.split("\n"); //$NON-NLS-1$
-    
-                for (String pid : pids) {
-                    try {
-                        pidList.add(Integer.valueOf(pid));
-                    } catch (NumberFormatException nfe) {
-                        // looks like this pid is not really a number. Lets ignore it.
-                        continue;
-                    }
-                }
-            }
-
-            MonitorThread monitorThread = MonitorThread.getInstance();
-
-            // Now we merge the current list with the old one.
-            // this is the same mechanism as the merging of the device list.
-
-            // For each client in the current list, we look for a matching the pid in the new list.
-            // * if we find it, we do nothing, except removing the pid from its list,
-            //   to mark it as "processed"
-            // * if we do not find any match, we remove the client from the current list.
-            // Once this is done, the new list contains pids for which we don't have clients yet,
-            // so we create clients for them, add them to the list, and start monitoring them.
-
-            List<Client> clients = device.getClientList();
-
-            boolean changed = false;
-
-            // because MonitorThread#dropClient acquires first the monitorThread lock and then the
-            // Device client list lock (when removing the Client from the list), we have to make
-            // sure we acquire the locks in the same order, since another thread (MonitorThread),
-            // could call dropClient itself.
-            synchronized (monitorThread) {
-                synchronized (clients) {
-                    for (int c = 0 ; c < clients.size() ;) {
-                        Client client = clients.get(c);
-                        int pid = client.getClientData().getPid();
-        
-                        // look for a matching pid
-                        Integer match = null;
-                        for (Integer matchingPid : pidList) {
-                            if (pid == matchingPid.intValue()) {
-                                match = matchingPid;
-                                break;
-                            }
-                        }
-        
-                        if (match != null) {
-                            pidList.remove(match);
-                            c++; // move on to the next client.
-                        } else {
-                            // we need to drop the client. the client will remove itself from the
-                            // list of its device which is 'clients', so there's no need to
-                            // increment c.
-                            // We ask the monitor thread to not send notification, as we'll do
-                            // it once at the end.
-                            monitorThread.dropClient(client, false /* notify */);
-                            changed = true;
-                        }
-                    }
-                }
-            }
-
-            // at this point whatever pid is left in the list needs to be converted into Clients.
-            for (int newPid : pidList) {
-                openClient(device, newPid, getNextDebuggerPort(), monitorThread);
-                changed = true;
-            }
-
-            if (changed) {
-                mServer.deviceChanged(device, Device.CHANGE_CLIENT_LIST);
-            }
-        }
-    }
-
-    /**
-     * Opens and creates a new client.
-     * @return
-     */
-    private void openClient(Device device, int pid, int port, MonitorThread monitorThread) {
-        
-        SocketChannel clientSocket;
-        try {
-            clientSocket = AdbHelper.createPassThroughConnection(
-                    AndroidDebugBridge.sSocketAddr, device, pid);
-
-            // required for Selector
-            clientSocket.configureBlocking(false);
-        } catch (UnknownHostException uhe) {
-            Log.d("DeviceMonitor", "Unknown Jdwp pid: " + pid);
-            return;
-        } catch (IOException ioe) {
-            Log.w("DeviceMonitor",
-                    "Failed to connect to client '" + pid + "': " + ioe.getMessage());
-            return ;
-        }
-        
-        createClient(device, pid, clientSocket, port, monitorThread);
-    }
-
-    /**
-     * Creates a client and register it to the monitor thread
-     * @param device
-     * @param pid
-     * @param socket
-     * @param debuggerPort the debugger port.
-     * @param monitorThread the {@link MonitorThread} object.
-     */
-    private void createClient(Device device, int pid, SocketChannel socket, int debuggerPort,
-            MonitorThread monitorThread) {
-
-        /*
-         * Successfully connected to something. Create a Client object, add
-         * it to the list, and initiate the JDWP handshake.
-         */
-
-        Client client = new Client(device, socket, pid);
-
-        if (client.sendHandshake()) {
-            try {
-                if (AndroidDebugBridge.getClientSupport()) {
-                    client.listenForDebugger(debuggerPort);
-                }
-                client.requestAllocationStatus();
-            } catch (IOException ioe) {
-                client.getClientData().setDebuggerConnectionStatus(ClientData.DEBUGGER_ERROR);
-                Log.e("ddms", "Can't bind to local " + debuggerPort + " for debugger");
-                // oh well
-            }
-        } else {
-            Log.e("ddms", "Handshake with " + client + " failed!");
-            /*
-             * The handshake send failed. We could remove it now, but if the
-             * failure is "permanent" we'll just keep banging on it and
-             * getting the same result. Keep it in the list with its "error"
-             * state so we don't try to reopen it.
-             */
-        }
-
-        if (client.isValid()) {
-            device.addClient(client);
-            monitorThread.addClient(client);
-        } else {
-            client = null;
-        }
-    }
-
-    private int getNextDebuggerPort() {
-        // get the first port and remove it
-        synchronized (mDebuggerPorts) {
-            if (mDebuggerPorts.size() > 0) {
-                int port = mDebuggerPorts.get(0);
-
-                // remove it.
-                mDebuggerPorts.remove(0);
-
-                // if there's nothing left, add the next port to the list
-                if (mDebuggerPorts.size() == 0) {
-                    mDebuggerPorts.add(port+1);
-                }
-
-                return port;
-            }
-        }
-
-        return -1;
-    }
-
-    void addPortToAvailableList(int port) {
-        if (port > 0) {
-            synchronized (mDebuggerPorts) {
-                // because there could be case where clients are closed twice, we have to make
-                // sure the port number is not already in the list.
-                if (mDebuggerPorts.indexOf(port) == -1) {
-                    // add the port to the list while keeping it sorted. It's not like there's
-                    // going to be tons of objects so we do it linearly.
-                    int count = mDebuggerPorts.size();
-                    for (int i = 0 ; i < count ; i++) {
-                        if (port < mDebuggerPorts.get(i)) {
-                            mDebuggerPorts.add(i, port);
-                            break;
-                        }
-                    }
-                    // TODO: check if we can compact the end of the list.
-                }
-            }
-        }
-    }
-    
-    /**
-     * Reads the length of the next message from a socket.
-     * @param socket The {@link SocketChannel} to read from.
-     * @return the length, or 0 (zero) if no data is available from the socket.
-     * @throws IOException if the connection failed.
-     */
-    private int readLength(SocketChannel socket, byte[] buffer) throws IOException {
-        String msg = read(socket, buffer);
-
-        if (msg != null) {
-            try {
-                return Integer.parseInt(msg, 16);
-            } catch (NumberFormatException nfe) {
-                // we'll throw an exception below.
-            }
-       }
-
-        // we receive something we can't read. It's better to reset the connection at this point.
-        throw new IOException("Unable to read length");
-    }
-
-    /**
-     * Fills a buffer from a socket.
-     * @param socket
-     * @param buffer
-     * @return the content of the buffer as a string, or null if it failed to convert the buffer.
-     * @throws IOException
-     */
-    private String read(SocketChannel socket, byte[] buffer) throws IOException {
-        ByteBuffer buf = ByteBuffer.wrap(buffer, 0, buffer.length);
-
-        while (buf.position() != buf.limit()) {
-            int count;
-
-            count = socket.read(buf);
-            if (count < 0) {
-                throw new IOException("EOF");
-            }
-        }
-
-        try {
-            return new String(buffer, 0, buf.position(), AdbHelper.DEFAULT_ENCODING);
-        } catch (UnsupportedEncodingException e) {
-            // we'll return null below.
-        }
-
-        return null;
-    }
-
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/EmulatorConsole.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/EmulatorConsole.java
deleted file mode 100644
index f3986ed..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/EmulatorConsole.java
+++ /dev/null
@@ -1,751 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.net.UnknownHostException;
-import java.nio.ByteBuffer;
-import java.nio.channels.SocketChannel;
-import java.security.InvalidParameterException;
-import java.util.Calendar;
-import java.util.HashMap;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Provides control over emulated hardware of the Android emulator.
- * <p/>This is basically a wrapper around the command line console normally used with telnet.
- *<p/>
- * Regarding line termination handling:<br>
- * One of the issues is that the telnet protocol <b>requires</b> usage of <code>\r\n</code>. Most
- * implementations don't enforce it (the dos one does). In this particular case, this is mostly
- * irrelevant since we don't use telnet in Java, but that means we want to make
- * sure we use the same line termination than what the console expects. The console
- * code removes <code>\r</code> and waits for <code>\n</code>.
- * <p/>However this means you <i>may</i> receive <code>\r\n</code> when reading from the console.
- * <p/>
- * <b>This API will change in the near future.</b> 
- */
-public final class EmulatorConsole {
-
-    private final static String DEFAULT_ENCODING = "ISO-8859-1"; //$NON-NLS-1$
-
-    private final static int WAIT_TIME = 5; // spin-wait sleep, in ms
-
-    private final static int STD_TIMEOUT = 5000; // standard delay, in ms
-
-    private final static String HOST = "127.0.0.1";  //$NON-NLS-1$
-
-    private final static String COMMAND_PING = "help\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_AVD_NAME = "avd name\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_KILL = "kill\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GSM_STATUS = "gsm status\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GSM_CALL = "gsm call %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GSM_CANCEL_CALL = "gsm cancel %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GSM_DATA = "gsm data %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GSM_VOICE = "gsm voice %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_SMS_SEND = "sms send %1$s %2$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_NETWORK_STATUS = "network status\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_NETWORK_SPEED = "network speed %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_NETWORK_LATENCY = "network delay %1$s\r\n"; //$NON-NLS-1$
-    private final static String COMMAND_GPS = 
-        "geo nmea $GPGGA,%1$02d%2$02d%3$02d.%4$03d," + //$NON-NLS-1$
-        "%5$03d%6$09.6f,%7$c,%8$03d%9$09.6f,%10$c," + //$NON-NLS-1$
-        "1,10,0.0,0.0,0,0.0,0,0.0,0000\r\n"; //$NON-NLS-1$
-
-    private final static Pattern RE_KO = Pattern.compile("KO:\\s+(.*)"); //$NON-NLS-1$
-
-    /**
-     * Array of delay values: no delay, gprs, edge/egprs, umts/3d
-     */
-    public final static int[] MIN_LATENCIES = new int[] {
-        0,      // No delay
-        150,    // gprs
-        80,     // edge/egprs
-        35      // umts/3g
-    };
-
-    /**
-     * Array of download speeds: full speed, gsm, hscsd, gprs, edge/egprs, umts/3g, hsdpa.
-     */
-    public final int[] DOWNLOAD_SPEEDS = new int[] {
-        0,          // full speed
-        14400,      // gsm
-        43200,      // hscsd
-        80000,      // gprs
-        236800,     // edge/egprs
-        1920000,    // umts/3g
-        14400000    // hsdpa
-    };
-
-    /** Arrays of valid network speeds */
-    public final static String[] NETWORK_SPEEDS = new String[] {
-        "full", //$NON-NLS-1$
-        "gsm", //$NON-NLS-1$
-        "hscsd", //$NON-NLS-1$
-        "gprs", //$NON-NLS-1$
-        "edge", //$NON-NLS-1$
-        "umts", //$NON-NLS-1$
-        "hsdpa", //$NON-NLS-1$
-    };
-
-    /** Arrays of valid network latencies */
-    public final static String[] NETWORK_LATENCIES = new String[] {
-        "none", //$NON-NLS-1$
-        "gprs", //$NON-NLS-1$
-        "edge", //$NON-NLS-1$
-        "umts", //$NON-NLS-1$
-    };
-
-    /** Gsm Mode enum. */
-    public static enum GsmMode {
-        UNKNOWN((String)null),
-        UNREGISTERED(new String[] { "unregistered", "off" }),
-        HOME(new String[] { "home", "on" }),
-        ROAMING("roaming"),
-        SEARCHING("searching"),
-        DENIED("denied");
-
-        private final String[] tags;
-
-        GsmMode(String tag) {
-            if (tag != null) {
-                this.tags = new String[] { tag };
-            } else {
-                this.tags = new String[0];
-            }
-        }
-
-        GsmMode(String[] tags) {
-            this.tags = tags;
-        }
-
-        public static GsmMode getEnum(String tag) {
-            for (GsmMode mode : values()) {
-                for (String t : mode.tags) {
-                    if (t.equals(tag)) {
-                        return mode;
-                    }
-                }
-            }
-            return UNKNOWN;
-        }
-
-        /**
-         * Returns the first tag of the enum.
-         */
-        public String getTag() {
-            if (tags.length > 0) {
-                return tags[0];
-            }
-            return null;
-        }
-    }
-
-    public final static String RESULT_OK = null;
-
-    private final static Pattern sEmulatorRegexp = Pattern.compile(Device.RE_EMULATOR_SN);
-    private final static Pattern sVoiceStatusRegexp = Pattern.compile(
-            "gsm\\s+voice\\s+state:\\s*([a-z]+)", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
-    private final static Pattern sDataStatusRegexp = Pattern.compile(
-            "gsm\\s+data\\s+state:\\s*([a-z]+)", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
-    private final static Pattern sDownloadSpeedRegexp = Pattern.compile(
-            "\\s+download\\s+speed:\\s+(\\d+)\\s+bits.*", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
-    private final static Pattern sMinLatencyRegexp = Pattern.compile(
-            "\\s+minimum\\s+latency:\\s+(\\d+)\\s+ms", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
-
-    private final static HashMap<Integer, EmulatorConsole> sEmulators =
-        new HashMap<Integer, EmulatorConsole>();
-
-    /** Gsm Status class */
-    public static class GsmStatus {
-        /** Voice status. */
-        public GsmMode voice = GsmMode.UNKNOWN;
-        /** Data status. */
-        public GsmMode data = GsmMode.UNKNOWN;
-    }
-
-    /** Network Status class */
-    public static class NetworkStatus {
-        /** network speed status. This is an index in the {@link #DOWNLOAD_SPEEDS} array. */
-        public int speed = -1;
-        /** network latency status.  This is an index in the {@link #MIN_LATENCIES} array. */
-        public int latency = -1;
-    }
-
-    private int mPort;
-
-    private SocketChannel mSocketChannel;
-
-    private byte[] mBuffer = new byte[1024];
-
-    /**
-     * Returns an {@link EmulatorConsole} object for the given {@link Device}. This can
-     * be an already existing console, or a new one if it hadn't been created yet.
-     * @param d The device that the console links to.
-     * @return an <code>EmulatorConsole</code> object or <code>null</code> if the connection failed.
-     */
-    public static synchronized EmulatorConsole getConsole(Device d) {
-        // we need to make sure that the device is an emulator
-        Matcher m = sEmulatorRegexp.matcher(d.serialNumber);
-        if (m.matches()) {
-            // get the port number. This is the console port.
-            int port;
-            try {
-                port = Integer.parseInt(m.group(1));
-                if (port <= 0) {
-                    return null;
-                }
-            } catch (NumberFormatException e) {
-                // looks like we failed to get the port number. This is a bit strange since
-                // it's coming from a regexp that only accept digit, but we handle the case
-                // and return null.
-                return null;
-            }
-
-            EmulatorConsole console = sEmulators.get(port);
-
-            if (console != null) {
-                // if the console exist, we ping the emulator to check the connection.
-                if (console.ping() == false) {
-                    RemoveConsole(console.mPort);
-                    console = null;
-                }
-            }
-
-            if (console == null) {
-                // no console object exists for this port so we create one, and start
-                // the connection.
-                console = new EmulatorConsole(port);
-                if (console.start()) {
-                    sEmulators.put(port, console);
-                } else {
-                    console = null;
-                }
-            }
-
-            return console;
-        }
-
-        return null;
-    }
-
-    /**
-     * Removes the console object associated with a port from the map.
-     * @param port The port of the console to remove.
-     */
-    private static synchronized void RemoveConsole(int port) {
-        sEmulators.remove(port);
-    }
-
-    private EmulatorConsole(int port) {
-        super();
-        mPort = port;
-    }
-
-    /**
-     * Starts the connection of the console.
-     * @return true if success.
-     */
-    private boolean start() {
-
-        InetSocketAddress socketAddr;
-        try {
-            InetAddress hostAddr = InetAddress.getByName(HOST);
-            socketAddr = new InetSocketAddress(hostAddr, mPort);
-        } catch (UnknownHostException e) {
-            return false;
-        }
-
-        try {
-            mSocketChannel = SocketChannel.open(socketAddr);
-        } catch (IOException e1) {
-            return false;
-        }
-
-        // read some stuff from it
-        readLines();
-
-        return true;
-    }
-
-    /**
-     * Ping the emulator to check if the connection is still alive.
-     * @return true if the connection is alive.
-     */
-    private synchronized boolean ping() {
-        // it looks like we can send stuff, even when the emulator quit, but we can't read
-        // from the socket. So we check the return of readLines()
-        if (sendCommand(COMMAND_PING)) {
-            return readLines() != null;
-        }
-
-        return false;
-    }
-
-    /**
-     * Sends a KILL command to the emulator.
-     */
-    public synchronized void kill() {
-        if (sendCommand(COMMAND_KILL)) {
-            RemoveConsole(mPort);
-        }
-    }
-    
-    public synchronized String getAvdName() {
-        if (sendCommand(COMMAND_AVD_NAME)) {
-            String[] result = readLines();
-            if (result != null && result.length == 2) { // this should be the name on first line,
-                                                        // and ok on 2nd line
-                return result[0];
-            } else {
-                // try to see if there's a message after KO
-                Matcher m = RE_KO.matcher(result[result.length-1]);
-                if (m.matches()) {
-                    return m.group(1);
-                }
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Get the network status of the emulator.
-     * @return a {@link NetworkStatus} object containing the {@link GsmStatus}, or
-     * <code>null</code> if the query failed.
-     */
-    public synchronized NetworkStatus getNetworkStatus() {
-        if (sendCommand(COMMAND_NETWORK_STATUS)) {
-            /* Result is in the format
-                Current network status:
-                download speed:      14400 bits/s (1.8 KB/s)
-                upload speed:        14400 bits/s (1.8 KB/s)
-                minimum latency:  0 ms
-                maximum latency:  0 ms
-             */
-            String[] result = readLines();
-
-            if (isValid(result)) {
-                // we only compare agains the min latency and the download speed
-                // let's not rely on the order of the output, and simply loop through
-                // the line testing the regexp.
-                NetworkStatus status = new NetworkStatus();
-                for (String line : result) {
-                    Matcher m = sDownloadSpeedRegexp.matcher(line);
-                    if (m.matches()) {
-                        // get the string value
-                        String value = m.group(1);
-
-                        // get the index from the list
-                        status.speed = getSpeedIndex(value);
-
-                        // move on to next line.
-                        continue;
-                    }
-
-                    m = sMinLatencyRegexp.matcher(line);
-                    if (m.matches()) {
-                        // get the string value
-                        String value = m.group(1);
-
-                        // get the index from the list
-                        status.latency = getLatencyIndex(value);
-
-                        // move on to next line.
-                        continue;
-                    }
-                }
-
-                return status;
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Returns the current gsm status of the emulator
-     * @return a {@link GsmStatus} object containing the gms status, or <code>null</code>
-     * if the query failed.
-     */
-    public synchronized GsmStatus getGsmStatus() {
-        if (sendCommand(COMMAND_GSM_STATUS)) {
-            /*
-             * result is in the format:
-             * gsm status
-             * gsm voice state: home
-             * gsm data state:  home
-             */
-
-            String[] result = readLines();
-            if (isValid(result)) {
-
-                GsmStatus status = new GsmStatus();
-
-                // let's not rely on the order of the output, and simply loop through
-                // the line testing the regexp.
-                for (String line : result) {
-                    Matcher m = sVoiceStatusRegexp.matcher(line);
-                    if (m.matches()) {
-                        // get the string value
-                        String value = m.group(1);
-
-                        // get the index from the list
-                        status.voice = GsmMode.getEnum(value.toLowerCase());
-
-                        // move on to next line.
-                        continue;
-                    }
-
-                    m = sDataStatusRegexp.matcher(line);
-                    if (m.matches()) {
-                        // get the string value
-                        String value = m.group(1);
-
-                        // get the index from the list
-                        status.data = GsmMode.getEnum(value.toLowerCase());
-
-                        // move on to next line.
-                        continue;
-                    }
-                }
-
-                return status;
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Sets the GSM voice mode.
-     * @param mode the {@link GsmMode} value.
-     * @return RESULT_OK if success, an error String otherwise.
-     * @throws InvalidParameterException if mode is an invalid value.
-     */
-    public synchronized String setGsmVoiceMode(GsmMode mode) throws InvalidParameterException {
-        if (mode == GsmMode.UNKNOWN) {
-            throw new InvalidParameterException();
-        }
-
-        String command = String.format(COMMAND_GSM_VOICE, mode.getTag());
-        return processCommand(command);
-    }
-
-    /**
-     * Sets the GSM data mode.
-     * @param mode the {@link GsmMode} value
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     * @throws InvalidParameterException if mode is an invalid value.
-     */
-    public synchronized String setGsmDataMode(GsmMode mode) throws InvalidParameterException {
-        if (mode == GsmMode.UNKNOWN) {
-            throw new InvalidParameterException();
-        }
-
-        String command = String.format(COMMAND_GSM_DATA, mode.getTag());
-        return processCommand(command);
-    }
-
-    /**
-     * Initiate an incoming call on the emulator.
-     * @param number a string representing the calling number.
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     */
-    public synchronized String call(String number) {
-        String command = String.format(COMMAND_GSM_CALL, number);
-        return processCommand(command);
-    }
-
-    /**
-     * Cancels a current call.
-     * @param number the number of the call to cancel
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     */
-    public synchronized String cancelCall(String number) {
-        String command = String.format(COMMAND_GSM_CANCEL_CALL, number);
-        return processCommand(command);
-    }
-
-    /**
-     * Sends an SMS to the emulator
-     * @param number The sender phone number
-     * @param message The SMS message. \ characters must be escaped. The carriage return is
-     * the 2 character sequence  {'\', 'n' }
-     *
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     */
-    public synchronized String sendSms(String number, String message) {
-        String command = String.format(COMMAND_SMS_SEND, number, message);
-        return processCommand(command);
-    }
-
-    /**
-     * Sets the network speed.
-     * @param selectionIndex The index in the {@link #NETWORK_SPEEDS} table.
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     */
-    public synchronized String setNetworkSpeed(int selectionIndex) {
-        String command = String.format(COMMAND_NETWORK_SPEED, NETWORK_SPEEDS[selectionIndex]);
-        return processCommand(command);
-    }
-
-    /**
-     * Sets the network latency.
-     * @param selectionIndex The index in the {@link #NETWORK_LATENCIES} table.
-     * @return {@link #RESULT_OK} if success, an error String otherwise.
-     */
-    public synchronized String setNetworkLatency(int selectionIndex) {
-        String command = String.format(COMMAND_NETWORK_LATENCY, NETWORK_LATENCIES[selectionIndex]);
-        return processCommand(command);
-    }
-    
-    public synchronized String sendLocation(double longitude, double latitude, double elevation) {
-        
-        Calendar c = Calendar.getInstance();
-        
-        double absLong = Math.abs(longitude);
-        int longDegree = (int)Math.floor(absLong);
-        char longDirection = 'E';
-        if (longitude < 0) {
-            longDirection = 'W';
-        }
-        
-        double longMinute = (absLong - Math.floor(absLong)) * 60;
-
-        double absLat = Math.abs(latitude);
-        int latDegree = (int)Math.floor(absLat);
-        char latDirection = 'N';
-        if (latitude < 0) {
-            latDirection = 'S';
-        }
-        
-        double latMinute = (absLat - Math.floor(absLat)) * 60;
-        
-        String command = String.format(COMMAND_GPS,
-                c.get(Calendar.HOUR_OF_DAY), c.get(Calendar.MINUTE),
-                c.get(Calendar.SECOND), c.get(Calendar.MILLISECOND),
-                latDegree, latMinute, latDirection,
-                longDegree, longMinute, longDirection);
-        
-        return processCommand(command);
-    }
-
-    /**
-     * Sends a command to the emulator console.
-     * @param command The command string. <b>MUST BE TERMINATED BY \n</b>.
-     * @return true if success
-     */
-    private boolean sendCommand(String command) {
-        boolean result = false;
-        try {
-            byte[] bCommand;
-            try {
-                bCommand = command.getBytes(DEFAULT_ENCODING);
-            } catch (UnsupportedEncodingException e) {
-                // wrong encoding...
-                return result;
-            }
-
-            // write the command
-            AdbHelper.write(mSocketChannel, bCommand, bCommand.length, AdbHelper.STD_TIMEOUT);
-
-            result = true;
-        } catch (IOException e) {
-            return false;
-        } finally {
-            if (result == false) {
-                // FIXME connection failed somehow, we need to disconnect the console.
-                RemoveConsole(mPort);
-            }
-        }
-
-        return result;
-    }
-
-    /**
-     * Sends a command to the emulator and parses its answer.
-     * @param command the command to send.
-     * @return {@link #RESULT_OK} if success, an error message otherwise.
-     */
-    private String processCommand(String command) {
-        if (sendCommand(command)) {
-            String[] result = readLines();
-
-            if (result != null && result.length > 0) {
-                Matcher m = RE_KO.matcher(result[result.length-1]);
-                if (m.matches()) {
-                    return m.group(1);
-                }
-                return RESULT_OK;
-            }
-
-            return "Unable to communicate with the emulator";
-        }
-
-        return "Unable to send command to the emulator";
-    }
-
-    /**
-     * Reads line from the console socket. This call is blocking until we read the lines:
-     * <ul>
-     * <li>OK\r\n</li>
-     * <li>KO<msg>\r\n</li>
-     * </ul>
-     * @return the array of strings read from the emulator.
-     */
-    private String[] readLines() {
-        try {
-            ByteBuffer buf = ByteBuffer.wrap(mBuffer, 0, mBuffer.length);
-            int numWaits = 0;
-            boolean stop = false;
-            
-            while (buf.position() != buf.limit() && stop == false) {
-                int count;
-
-                count = mSocketChannel.read(buf);
-                if (count < 0) {
-                    return null;
-                } else if (count == 0) {
-                    if (numWaits * WAIT_TIME > STD_TIMEOUT) {
-                        return null;
-                    }
-                    // non-blocking spin
-                    try {
-                        Thread.sleep(WAIT_TIME);
-                    } catch (InterruptedException ie) {
-                    }
-                    numWaits++;
-                } else {
-                    numWaits = 0;
-                }
-
-                // check the last few char aren't OK. For a valid message to test
-                // we need at least 4 bytes (OK/KO + \r\n)
-                if (buf.position() >= 4) {
-                    int pos = buf.position();
-                    if (endsWithOK(pos) || lastLineIsKO(pos)) {
-                        stop = true;
-                    }
-                }
-            }
-
-            String msg = new String(mBuffer, 0, buf.position(), DEFAULT_ENCODING);
-            return msg.split("\r\n"); //$NON-NLS-1$
-        } catch (IOException e) {
-            return null;
-        }
-    }
-
-    /**
-     * Returns true if the 4 characters *before* the current position are "OK\r\n"
-     * @param currentPosition The current position
-     */
-    private boolean endsWithOK(int currentPosition) {
-        if (mBuffer[currentPosition-1] == '\n' &&
-                mBuffer[currentPosition-2] == '\r' &&
-                mBuffer[currentPosition-3] == 'K' &&
-                mBuffer[currentPosition-4] == 'O') {
-            return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * Returns true if the last line starts with KO and is also terminated by \r\n
-     * @param currentPosition the current position
-     */
-    private boolean lastLineIsKO(int currentPosition) {
-        // first check that the last 2 characters are CRLF
-        if (mBuffer[currentPosition-1] != '\n' ||
-                mBuffer[currentPosition-2] != '\r') {
-            return false;
-        }
-
-        // now loop backward looking for the previous CRLF, or the beginning of the buffer
-        int i = 0;
-        for (i = currentPosition-3 ; i >= 0; i--) {
-            if (mBuffer[i] == '\n') {
-                // found \n!
-                if (i > 0 && mBuffer[i-1] == '\r') {
-                    // found \r!
-                    break;
-                }
-            }
-        }
-
-        // here it is either -1 if we reached the start of the buffer without finding
-        // a CRLF, or the position of \n. So in both case we look at the characters at i+1 and i+2
-        if (mBuffer[i+1] == 'K' && mBuffer[i+2] == 'O') {
-            // found error!
-            return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * Returns true if the last line of the result does not start with KO
-     */
-    private boolean isValid(String[] result) {
-        if (result != null && result.length > 0) {
-            return !(RE_KO.matcher(result[result.length-1]).matches());
-        }
-        return false;
-    }
-
-    private int getLatencyIndex(String value) {
-        try {
-            // get the int value
-            int latency = Integer.parseInt(value);
-
-            // check for the speed from the index
-            for (int i = 0 ; i < MIN_LATENCIES.length; i++) {
-                if (MIN_LATENCIES[i] == latency) {
-                    return i;
-                }
-            }
-        } catch (NumberFormatException e) {
-            // Do nothing, we'll just return -1.
-        }
-
-        return -1;
-    }
-
-    private int getSpeedIndex(String value) {
-        try {
-            // get the int value
-            int speed = Integer.parseInt(value);
-
-            // check for the speed from the index
-            for (int i = 0 ; i < DOWNLOAD_SPEEDS.length; i++) {
-                if (DOWNLOAD_SPEEDS[i] == speed) {
-                    return i;
-                }
-            }
-        } catch (NumberFormatException e) {
-            // Do nothing, we'll just return -1.
-        }
-
-        return -1;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/FileListingService.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/FileListingService.java
deleted file mode 100644
index b50cf79..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/FileListingService.java
+++ /dev/null
@@ -1,767 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Provides {@link Device} side file listing service.
- * <p/>To get an instance for a known {@link Device}, call {@link Device#getFileListingService()}.
- */
-public final class FileListingService {
-
-    /** Pattern to find filenames that match "*.apk" */
-    private final static Pattern sApkPattern =
-        Pattern.compile(".*\\.apk", Pattern.CASE_INSENSITIVE); //$NON-NLS-1$
-
-    private final static String PM_FULL_LISTING = "pm list packages -f"; //$NON-NLS-1$
-
-    /** Pattern to parse the output of the 'pm -lf' command.<br>
-     * The output format looks like:<br>
-     * /data/app/myapp.apk=com.mypackage.myapp */
-    private final static Pattern sPmPattern = Pattern.compile("^package:(.+?)=(.+)$"); //$NON-NLS-1$
-
-    /** Top level data folder. */
-    public final static String DIRECTORY_DATA = "data"; //$NON-NLS-1$
-    /** Top level sdcard folder. */
-    public final static String DIRECTORY_SDCARD = "sdcard"; //$NON-NLS-1$
-    /** Top level system folder. */
-    public final static String DIRECTORY_SYSTEM = "system"; //$NON-NLS-1$
-    /** Top level temp folder. */
-    public final static String DIRECTORY_TEMP = "tmp"; //$NON-NLS-1$
-    /** Application folder. */
-    public final static String DIRECTORY_APP = "app"; //$NON-NLS-1$
-
-    private final static String[] sRootLevelApprovedItems = {
-        DIRECTORY_DATA,
-        DIRECTORY_SDCARD,
-        DIRECTORY_SYSTEM,
-        DIRECTORY_TEMP
-    };
-
-    public static final long REFRESH_RATE = 5000L;
-    /**
-     * Refresh test has to be slightly lower for precision issue.
-     */
-    static final long REFRESH_TEST = (long)(REFRESH_RATE * .8);
-
-    /** Entry type: File */
-    public static final int TYPE_FILE = 0;
-    /** Entry type: Directory */
-    public static final int TYPE_DIRECTORY = 1;
-    /** Entry type: Directory Link */
-    public static final int TYPE_DIRECTORY_LINK = 2;
-    /** Entry type: Block */
-    public static final int TYPE_BLOCK = 3;
-    /** Entry type: Character */
-    public static final int TYPE_CHARACTER = 4;
-    /** Entry type: Link */
-    public static final int TYPE_LINK = 5;
-    /** Entry type: Socket */
-    public static final int TYPE_SOCKET = 6;
-    /** Entry type: FIFO */
-    public static final int TYPE_FIFO = 7;
-    /** Entry type: Other */
-    public static final int TYPE_OTHER = 8;
-
-    /** Device side file separator. */
-    public static final String FILE_SEPARATOR = "/"; //$NON-NLS-1$
-
-    private static final String FILE_ROOT = "/"; //$NON-NLS-1$
-
-
-    /**
-     * Regexp pattern to parse the result from ls.
-     */
-    private static Pattern sLsPattern = Pattern.compile(
-        "^([bcdlsp-][-r][-w][-xsS][-r][-w][-xsS][-r][-w][-xstST])\\s+(\\S+)\\s+(\\S+)\\s+([\\d\\s,]*)\\s+(\\d{4}-\\d\\d-\\d\\d)\\s+(\\d\\d:\\d\\d)\\s+(.*)$"); //$NON-NLS-1$
-
-    private Device mDevice;
-    private FileEntry mRoot;
-
-    private ArrayList<Thread> mThreadList = new ArrayList<Thread>();
-
-    /**
-     * Represents an entry in a directory. This can be a file or a directory.
-     */
-    public final static class FileEntry {
-        /** Pattern to escape filenames for shell command consumption. */
-        private final static Pattern sEscapePattern = Pattern.compile(
-                "([\\\\()*+?\"'#/\\s])"); //$NON-NLS-1$
-
-        /**
-         * Comparator object for FileEntry
-         */
-        private static Comparator<FileEntry> sEntryComparator = new Comparator<FileEntry>() {
-            public int compare(FileEntry o1, FileEntry o2) {
-                if (o1 instanceof FileEntry && o2 instanceof FileEntry) {
-                    FileEntry fe1 = (FileEntry)o1;
-                    FileEntry fe2 = (FileEntry)o2;
-                    return fe1.name.compareTo(fe2.name);
-                }
-                return 0;
-            }
-        };
-
-        FileEntry parent;
-        String name;
-        String info;
-        String permissions;
-        String size;
-        String date;
-        String time;
-        String owner;
-        String group;
-        int type;
-        boolean isAppPackage;
-
-        boolean isRoot;
-
-        /**
-         * Indicates whether the entry content has been fetched yet, or not.
-         */
-        long fetchTime = 0;
-
-        final ArrayList<FileEntry> mChildren = new ArrayList<FileEntry>();
-
-        /**
-         * Creates a new file entry.
-         * @param parent parent entry or null if entry is root
-         * @param name name of the entry.
-         * @param type entry type. Can be one of the following: {@link FileListingService#TYPE_FILE},
-         * {@link FileListingService#TYPE_DIRECTORY}, {@link FileListingService#TYPE_OTHER}.
-         */
-        private FileEntry(FileEntry parent, String name, int type, boolean isRoot) {
-            this.parent = parent;
-            this.name = name;
-            this.type = type;
-            this.isRoot = isRoot;
-
-            checkAppPackageStatus();
-        }
-
-        /**
-         * Returns the name of the entry
-         */
-        public String getName() {
-            return name;
-        }
-
-        /**
-         * Returns the size string of the entry, as returned by <code>ls</code>.
-         */
-        public String getSize() {
-            return size;
-        }
-
-        /**
-         * Returns the size of the entry.
-         */
-        public int getSizeValue() {
-            return Integer.parseInt(size);
-        }
-
-        /**
-         * Returns the date string of the entry, as returned by <code>ls</code>.
-         */
-        public String getDate() {
-            return date;
-        }
-
-        /**
-         * Returns the time string of the entry, as returned by <code>ls</code>.
-         */
-        public String getTime() {
-            return time;
-        }
-
-        /**
-         * Returns the permission string of the entry, as returned by <code>ls</code>.
-         */
-        public String getPermissions() {
-            return permissions;
-        }
-
-        /**
-         * Returns the extra info for the entry.
-         * <p/>For a link, it will be a description of the link.
-         * <p/>For an application apk file it will be the application package as returned
-         * by the Package Manager.  
-         */
-        public String getInfo() {
-            return info;
-        }
-
-        /**
-         * Return the full path of the entry.
-         * @return a path string using {@link FileListingService#FILE_SEPARATOR} as separator.
-         */
-        public String getFullPath() {
-            if (isRoot) {
-                return FILE_ROOT;
-            }
-            StringBuilder pathBuilder = new StringBuilder();
-            fillPathBuilder(pathBuilder, false);
-
-            return pathBuilder.toString();
-        }
-
-        /**
-         * Return the fully escaped path of the entry. This path is safe to use in a
-         * shell command line.
-         * @return a path string using {@link FileListingService#FILE_SEPARATOR} as separator
-         */
-        public String getFullEscapedPath() {
-            StringBuilder pathBuilder = new StringBuilder();
-            fillPathBuilder(pathBuilder, true);
-
-            return pathBuilder.toString();
-        }
-
-        /**
-         * Returns the path as a list of segments.
-         */
-        public String[] getPathSegments() {
-            ArrayList<String> list = new ArrayList<String>();
-            fillPathSegments(list);
-
-            return list.toArray(new String[list.size()]);
-        }
-
-        /**
-         * Returns true if the entry is a directory, false otherwise;
-         */
-        public int getType() {
-            return type;
-        }
-
-        /**
-         * Returns if the entry is a folder or a link to a folder.
-         */
-        public boolean isDirectory() {
-            return type == TYPE_DIRECTORY || type == TYPE_DIRECTORY_LINK;
-        }
-
-        /**
-         * Returns the parent entry.
-         */
-        public FileEntry getParent() {
-            return parent;
-        }
-
-        /**
-         * Returns the cached children of the entry. This returns the cache created from calling
-         * <code>FileListingService.getChildren()</code>.
-         */
-        public FileEntry[] getCachedChildren() {
-            return mChildren.toArray(new FileEntry[mChildren.size()]);
-        }
-
-        /**
-         * Returns the child {@link FileEntry} matching the name.
-         * This uses the cached children list.
-         * @param name the name of the child to return.
-         * @return the FileEntry matching the name or null.
-         */
-        public FileEntry findChild(String name) {
-            for (FileEntry entry : mChildren) {
-                if (entry.name.equals(name)) {
-                    return entry;
-                }
-            }
-            return null;
-        }
-
-        /**
-         * Returns whether the entry is the root.
-         */
-        public boolean isRoot() {
-            return isRoot;
-        }
-
-        void addChild(FileEntry child) {
-            mChildren.add(child);
-        }
-
-        void setChildren(ArrayList<FileEntry> newChildren) {
-            mChildren.clear();
-            mChildren.addAll(newChildren);
-        }
-
-        boolean needFetch() {
-            if (fetchTime == 0) {
-                return true;
-            }
-            long current = System.currentTimeMillis();
-            if (current-fetchTime > REFRESH_TEST) {
-                return true;
-            }
-
-            return false;
-        }
-
-        /**
-         * Returns if the entry is a valid application package.
-         */
-        public boolean isApplicationPackage() {
-            return isAppPackage;
-        }
-
-        /**
-         * Returns if the file name is an application package name.
-         */
-        public boolean isAppFileName() {
-            Matcher m = sApkPattern.matcher(name);
-            return m.matches();
-        }
-
-        /**
-         * Recursively fills the pathBuilder with the full path
-         * @param pathBuilder a StringBuilder used to create the path.
-         * @param escapePath Whether the path need to be escaped for consumption by
-         * a shell command line.
-         */
-        protected void fillPathBuilder(StringBuilder pathBuilder, boolean escapePath) {
-            if (isRoot) {
-                return;
-            }
-
-            if (parent != null) {
-                parent.fillPathBuilder(pathBuilder, escapePath);
-            }
-            pathBuilder.append(FILE_SEPARATOR);
-            pathBuilder.append(escapePath ? escape(name) : name);
-        }
-
-        /**
-         * Recursively fills the segment list with the full path.
-         * @param list The list of segments to fill.
-         */
-        protected void fillPathSegments(ArrayList<String> list) {
-            if (isRoot) {
-                return;
-            }
-
-            if (parent != null) {
-                parent.fillPathSegments(list);
-            }
-
-            list.add(name);
-        }
-
-        /**
-         * Sets the internal app package status flag. This checks whether the entry is in an app
-         * directory like /data/app or /system/app
-         */
-        private void checkAppPackageStatus() {
-            isAppPackage = false;
-
-            String[] segments = getPathSegments();
-            if (type == TYPE_FILE && segments.length == 3 && isAppFileName()) {
-                isAppPackage = DIRECTORY_APP.equals(segments[1]) &&
-                    (DIRECTORY_SYSTEM.equals(segments[0]) || DIRECTORY_DATA.equals(segments[0]));
-            }
-        }
-
-        /**
-         * Returns an escaped version of the entry name.
-         * @param entryName
-         */
-        private String escape(String entryName) {
-            return sEscapePattern.matcher(entryName).replaceAll("\\\\$1"); //$NON-NLS-1$
-        }
-    }
-
-    private class LsReceiver extends MultiLineReceiver {
-
-        private ArrayList<FileEntry> mEntryList;
-        private ArrayList<String> mLinkList;
-        private FileEntry[] mCurrentChildren;
-        private FileEntry mParentEntry;
-
-        /**
-         * Create an ls receiver/parser.
-         * @param currentChildren The list of current children. To prevent
-         *      collapse during update, reusing the same FileEntry objects for
-         *      files that were already there is paramount.
-         * @param entryList the list of new children to be filled by the
-         *      receiver.
-         * @param linkList the list of link path to compute post ls, to figure
-         *      out if the link pointed to a file or to a directory.
-         */
-        public LsReceiver(FileEntry parentEntry, ArrayList<FileEntry> entryList,
-                ArrayList<String> linkList) {
-            mParentEntry = parentEntry;
-            mCurrentChildren = parentEntry.getCachedChildren();
-            mEntryList = entryList;
-            mLinkList = linkList;
-        }
-
-        @Override
-        public void processNewLines(String[] lines) {
-            for (String line : lines) {
-                // no need to handle empty lines.
-                if (line.length() == 0) {
-                    continue;
-                }
-
-                // run the line through the regexp
-                Matcher m = sLsPattern.matcher(line);
-                if (m.matches() == false) {
-                    continue;
-                }
-
-                // get the name
-                String name = m.group(7);
-
-                // if the parent is root, we only accept selected items
-                if (mParentEntry.isRoot()) {
-                    boolean found = false;
-                    for (String approved : sRootLevelApprovedItems) {
-                        if (approved.equals(name)) {
-                            found = true;
-                            break;
-                        }
-                    }
-
-                    // if it's not in the approved list we skip this entry.
-                    if (found == false) {
-                        continue;
-                    }
-                }
-
-                // get the rest of the groups
-                String permissions = m.group(1);
-                String owner = m.group(2);
-                String group = m.group(3);
-                String size = m.group(4);
-                String date = m.group(5);
-                String time = m.group(6);
-                String info = null;
-
-                // and the type
-                int objectType = TYPE_OTHER;
-                switch (permissions.charAt(0)) {
-                    case '-' :
-                        objectType = TYPE_FILE;
-                        break;
-                    case 'b' :
-                        objectType = TYPE_BLOCK;
-                        break;
-                    case 'c' :
-                        objectType = TYPE_CHARACTER;
-                        break;
-                    case 'd' :
-                        objectType = TYPE_DIRECTORY;
-                        break;
-                    case 'l' :
-                        objectType = TYPE_LINK;
-                        break;
-                    case 's' :
-                        objectType = TYPE_SOCKET;
-                        break;
-                    case 'p' :
-                        objectType = TYPE_FIFO;
-                        break;
-                }
-
-
-                // now check what we may be linking to
-                if (objectType == TYPE_LINK) {
-                    String[] segments = name.split("\\s->\\s"); //$NON-NLS-1$
-
-                    // we should have 2 segments
-                    if (segments.length == 2) {
-                        // update the entry name to not contain the link
-                        name = segments[0];
-
-                        // and the link name
-                        info = segments[1];
-
-                        // now get the path to the link
-                        String[] pathSegments = info.split(FILE_SEPARATOR);
-                        if (pathSegments.length == 1) {
-                            // the link is to something in the same directory,
-                            // unless the link is ..
-                            if ("..".equals(pathSegments[0])) { //$NON-NLS-1$
-                                // set the type and we're done.
-                                objectType = TYPE_DIRECTORY_LINK;
-                            } else {
-                                // either we found the object already
-                                // or we'll find it later.
-                            }
-                        }
-                    }
-
-                    // add an arrow in front to specify it's a link.
-                    info = "-> " + info; //$NON-NLS-1$;
-                }
-
-                // get the entry, either from an existing one, or a new one
-                FileEntry entry = getExistingEntry(name);
-                if (entry == null) {
-                    entry = new FileEntry(mParentEntry, name, objectType, false /* isRoot */);
-                }
-
-                // add some misc info
-                entry.permissions = permissions;
-                entry.size = size;
-                entry.date = date;
-                entry.time = time;
-                entry.owner = owner;
-                entry.group = group;
-                if (objectType == TYPE_LINK) {
-                    entry.info = info;
-                }
-
-                mEntryList.add(entry);
-            }
-        }
-
-        /**
-         * Queries for an already existing Entry per name
-         * @param name the name of the entry
-         * @return the existing FileEntry or null if no entry with a matching
-         * name exists.
-         */
-        private FileEntry getExistingEntry(String name) {
-            for (int i = 0 ; i < mCurrentChildren.length; i++) {
-                FileEntry e = mCurrentChildren[i];
-
-                // since we're going to "erase" the one we use, we need to
-                // check that the item is not null.
-                if (e != null) {
-                    // compare per name, case-sensitive.
-                    if (name.equals(e.name)) {
-                        // erase from the list
-                        mCurrentChildren[i] = null;
-
-                        // and return the object
-                        return e;
-                    }
-                }
-            }
-
-            // couldn't find any matching object, return null
-            return null;
-        }
-
-        public boolean isCancelled() {
-            return false;
-        }
-
-        public void finishLinks() {
-            // TODO Handle links in the listing service
-        }
-    }
-
-    /**
-     * Classes which implement this interface provide a method that deals with asynchronous
-     * result from <code>ls</code> command on the device.
-     *
-     * @see FileListingService#getChildren(com.android.ddmlib.FileListingService.FileEntry, boolean, com.android.ddmlib.FileListingService.IListingReceiver)
-     */
-    public interface IListingReceiver {
-        public void setChildren(FileEntry entry, FileEntry[] children);
-
-        public void refreshEntry(FileEntry entry);
-    }
-
-    /**
-     * Creates a File Listing Service for a specified {@link Device}.
-     * @param device The Device the service is connected to.
-     */
-    FileListingService(Device device) {
-        mDevice = device;
-    }
-
-    /**
-     * Returns the root element.
-     * @return the {@link FileEntry} object representing the root element or
-     * <code>null</code> if the device is invalid.
-     */
-    public FileEntry getRoot() {
-        if (mDevice != null) {
-            if (mRoot == null) {
-                mRoot = new FileEntry(null /* parent */, "" /* name */, TYPE_DIRECTORY,
-                        true /* isRoot */);
-            }
-
-            return mRoot;
-        }
-
-        return null;
-    }
-
-    /**
-     * Returns the children of a {@link FileEntry}.
-     * <p/>
-     * This method supports a cache mechanism and synchronous and asynchronous modes.
-     * <p/>
-     * If <var>receiver</var> is <code>null</code>, the device side <code>ls</code>
-     * command is done synchronously, and the method will return upon completion of the command.<br>
-     * If <var>receiver</var> is non <code>null</code>, the command is launched is a separate
-     * thread and upon completion, the receiver will be notified of the result.
-     * <p/>
-     * The result for each <code>ls</code> command is cached in the parent
-     * <code>FileEntry</code>. <var>useCache</var> allows usage of this cache, but only if the
-     * cache is valid. The cache is valid only for {@link FileListingService#REFRESH_RATE} ms.
-     * After that a new <code>ls</code> command is always executed.
-     * <p/>
-     * If the cache is valid and <code>useCache == true</code>, the method will always simply
-     * return the value of the cache, whether a {@link IListingReceiver} has been provided or not.
-     *
-     * @param entry The parent entry.
-     * @param useCache A flag to use the cache or to force a new ls command.
-     * @param receiver A receiver for asynchronous calls.
-     * @return The list of children or <code>null</code> for asynchronous calls.
-     *
-     * @see FileEntry#getCachedChildren()
-     */
-    public FileEntry[] getChildren(final FileEntry entry, boolean useCache,
-            final IListingReceiver receiver) {
-        // first thing we do is check the cache, and if we already have a recent
-        // enough children list, we just return that.
-        if (useCache && entry.needFetch() == false) {
-            return entry.getCachedChildren();
-        }
-
-        // if there's no receiver, then this is a synchronous call, and we
-        // return the result of ls
-        if (receiver == null) {
-            doLs(entry);
-            return entry.getCachedChildren();
-        }
-
-        // this is a asynchronous call.
-        // we launch a thread that will do ls and give the listing
-        // to the receiver
-        Thread t = new Thread("ls " + entry.getFullPath()) { //$NON-NLS-1$
-            @Override
-            public void run() {
-                doLs(entry);
-
-                receiver.setChildren(entry, entry.getCachedChildren());
-
-                final FileEntry[] children = entry.getCachedChildren();
-                if (children.length > 0 && children[0].isApplicationPackage()) {
-                    final HashMap<String, FileEntry> map = new HashMap<String, FileEntry>();
-
-                    for (FileEntry child : children) {
-                        String path = child.getFullPath();
-                        map.put(path, child);
-                    }
-
-                    // call pm.
-                    String command = PM_FULL_LISTING;
-                    try {
-                        mDevice.executeShellCommand(command, new MultiLineReceiver() {
-                            @Override
-                            public void processNewLines(String[] lines) {
-                                for (String line : lines) {
-                                    if (line.length() > 0) {
-                                        // get the filepath and package from the line
-                                        Matcher m = sPmPattern.matcher(line);
-                                        if (m.matches()) {
-                                            // get the children with that path
-                                            FileEntry entry = map.get(m.group(1));
-                                            if (entry != null) {
-                                                entry.info = m.group(2);
-                                                receiver.refreshEntry(entry);
-                                            }
-                                        }
-                                    }
-                                }
-                            }
-                            public boolean isCancelled() {
-                                return false;
-                            }
-                        });
-                    } catch (IOException e) {
-                        // adb failed somehow, we do nothing.
-                    }
-                }
-
-
-                // if another thread is pending, launch it
-                synchronized (mThreadList) {
-                    // first remove ourselves from the list
-                    mThreadList.remove(this);
-
-                    // then launch the next one if applicable.
-                    if (mThreadList.size() > 0) {
-                        Thread t = mThreadList.get(0);
-                        t.start();
-                    }
-                }
-            }
-        };
-
-        // we don't want to run multiple ls on the device at the same time, so we
-        // store the thread in a list and launch it only if there's no other thread running.
-        // the thread will launch the next one once it's done.
-        synchronized (mThreadList) {
-            // add to the list
-            mThreadList.add(t);
-
-            // if it's the only one, launch it.
-            if (mThreadList.size() == 1) {
-                t.start();
-            }
-        }
-
-        // and we return null.
-        return null;
-    }
-
-    private void doLs(FileEntry entry) {
-        // create a list that will receive the list of the entries
-        ArrayList<FileEntry> entryList = new ArrayList<FileEntry>();
-
-        // create a list that will receive the link to compute post ls;
-        ArrayList<String> linkList = new ArrayList<String>();
-
-        try {
-            // create the command
-            String command = "ls -l " + entry.getFullPath(); //$NON-NLS-1$
-
-            // create the receiver object that will parse the result from ls
-            LsReceiver receiver = new LsReceiver(entry, entryList, linkList);
-
-            // call ls.
-            mDevice.executeShellCommand(command, receiver);
-
-            // finish the process of the receiver to handle links
-            receiver.finishLinks();
-        } catch (IOException e) {
-        }
-
-
-        // at this point we need to refresh the viewer
-        entry.fetchTime = System.currentTimeMillis();
-
-        // sort the children and set them as the new children
-        Collections.sort(entryList, FileEntry.sEntryComparator);
-        entry.setChildren(entryList);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/GetPropReceiver.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/GetPropReceiver.java
deleted file mode 100644
index 9293379..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/GetPropReceiver.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * A receiver able to parse the result of the execution of 
- * {@link #GETPROP_COMMAND} on a device.
- */
-final class GetPropReceiver extends MultiLineReceiver {
-    final static String GETPROP_COMMAND = "getprop"; //$NON-NLS-1$
-    
-    private final static Pattern GETPROP_PATTERN = Pattern.compile("^\\[([^]]+)\\]\\:\\s*\\[(.*)\\]$"); //$NON-NLS-1$
-
-    /** indicates if we need to read the first */
-    private Device mDevice = null;
-
-    /**
-     * Creates the receiver with the device the receiver will modify.
-     * @param device The device to modify
-     */
-    public GetPropReceiver(Device device) {
-        mDevice = device;
-    }
-
-    @Override
-    public void processNewLines(String[] lines) {
-        // We receive an array of lines. We're expecting
-        // to have the build info in the first line, and the build
-        // date in the 2nd line. There seems to be an empty line
-        // after all that.
-
-        for (String line : lines) {
-            if (line.length() == 0 || line.startsWith("#")) {
-                continue;
-            }
-            
-            Matcher m = GETPROP_PATTERN.matcher(line);
-            if (m.matches()) {
-                String label = m.group(1);
-                String value = m.group(2);
-                
-                if (label.length() > 0) {
-                    mDevice.addProperty(label, value);
-                }
-            }
-        }
-    }
-    
-    public boolean isCancelled() {
-        return false;
-    }
-    
-    @Override
-    public void done() {
-        mDevice.update(Device.CHANGE_BUILD_INFO);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleAppName.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleAppName.java
deleted file mode 100644
index 99bd4d0..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleAppName.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Handle the "app name" chunk (APNM).
- */
-final class HandleAppName extends ChunkHandler {
-
-    public static final int CHUNK_APNM = ChunkHandler.type("APNM");
-
-    private static final HandleAppName mInst = new HandleAppName();
-
-
-    private HandleAppName() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_APNM, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {}
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data,
-            boolean isReply, int msgId) {
-
-        Log.d("ddm-appname", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_APNM) {
-            assert !isReply;
-            handleAPNM(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a reply to our APNM message.
-     */
-    private static void handleAPNM(Client client, ByteBuffer data) {
-        int appNameLen;
-        String appName;
-
-        appNameLen = data.getInt();
-        appName = getString(data, appNameLen);
-
-        Log.i("ddm-appname", "APNM: app='" + appName + "'");
-
-        ClientData cd = client.getClientData();
-        synchronized (cd) {
-            cd.setClientDescription(appName);
-        }
-
-        client = checkDebuggerPortForAppName(client, appName);
-
-        if (client != null) {
-            client.update(Client.CHANGE_NAME);
-        }
-    }
- }
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleExit.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleExit.java
deleted file mode 100644
index adeedbb..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleExit.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Submit an exit request.
- */
-final class HandleExit extends ChunkHandler {
-
-    public static final int CHUNK_EXIT = type("EXIT");
-
-    private static final HandleExit mInst = new HandleExit();
-
-
-    private HandleExit() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {}
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {}
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-        handleUnknownChunk(client, type, data, isReply, msgId);
-    }
-
-    /**
-     * Send an EXIT request to the client.
-     */
-    public static void sendEXIT(Client client, int status)
-        throws IOException
-    {
-        ByteBuffer rawBuf = allocBuffer(4);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.putInt(status);
-
-        finishChunkPacket(packet, CHUNK_EXIT, buf.position());
-        Log.d("ddm-exit", "Sending " + name(CHUNK_EXIT) + ": " + status);
-        client.sendAndConsume(packet, mInst);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHeap.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHeap.java
deleted file mode 100644
index 5752b86..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHeap.java
+++ /dev/null
@@ -1,497 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.BufferUnderflowException;
-import java.nio.ByteBuffer;
-import java.util.ArrayList;
-import java.util.Collections;
-
-/**
- * Handle heap status updates.
- */
-final class HandleHeap extends ChunkHandler {
-
-    public static final int CHUNK_HPIF = type("HPIF");
-    public static final int CHUNK_HPST = type("HPST");
-    public static final int CHUNK_HPEN = type("HPEN");
-    public static final int CHUNK_HPSG = type("HPSG");
-    public static final int CHUNK_HPGC = type("HPGC");
-    public static final int CHUNK_REAE = type("REAE");
-    public static final int CHUNK_REAQ = type("REAQ");
-    public static final int CHUNK_REAL = type("REAL");
-
-    // args to sendHPSG
-    public static final int WHEN_DISABLE = 0;
-    public static final int WHEN_GC = 1;
-    public static final int WHAT_MERGE = 0; // merge adjacent objects
-    public static final int WHAT_OBJ = 1;   // keep objects distinct
-
-    // args to sendHPIF
-    public static final int HPIF_WHEN_NEVER = 0;
-    public static final int HPIF_WHEN_NOW = 1;
-    public static final int HPIF_WHEN_NEXT_GC = 2;
-    public static final int HPIF_WHEN_EVERY_GC = 3;
-
-    private static final HandleHeap mInst = new HandleHeap();
-
-    private HandleHeap() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_HPIF, mInst);
-        mt.registerChunkHandler(CHUNK_HPST, mInst);
-        mt.registerChunkHandler(CHUNK_HPEN, mInst);
-        mt.registerChunkHandler(CHUNK_HPSG, mInst);
-        mt.registerChunkHandler(CHUNK_REAQ, mInst);
-        mt.registerChunkHandler(CHUNK_REAL, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {
-        if (client.isHeapUpdateEnabled()) {
-            //sendHPSG(client, WHEN_GC, WHAT_MERGE);
-            sendHPIF(client, HPIF_WHEN_EVERY_GC);
-        }
-    }
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-        Log.d("ddm-heap", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_HPIF) {
-            handleHPIF(client, data);
-            client.update(Client.CHANGE_HEAP_DATA);
-        } else if (type == CHUNK_HPST) {
-            handleHPST(client, data);
-        } else if (type == CHUNK_HPEN) {
-            handleHPEN(client, data);
-            client.update(Client.CHANGE_HEAP_DATA);
-        } else if (type == CHUNK_HPSG) {
-            handleHPSG(client, data);
-        } else if (type == CHUNK_REAQ) {
-            handleREAQ(client, data);
-            client.update(Client.CHANGE_HEAP_ALLOCATION_STATUS);
-        } else if (type == CHUNK_REAL) {
-            handleREAL(client, data);
-            client.update(Client.CHANGE_HEAP_ALLOCATIONS);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a heap info message.
-     */
-    private void handleHPIF(Client client, ByteBuffer data) {
-        Log.d("ddm-heap", "HPIF!");
-        try {
-            int numHeaps = data.getInt();
-
-            for (int i = 0; i < numHeaps; i++) {
-                int heapId = data.getInt();
-                @SuppressWarnings("unused")
-                long timeStamp = data.getLong();
-                @SuppressWarnings("unused")
-                byte reason = data.get();
-                long maxHeapSize = (long)data.getInt() & 0x00ffffffff;
-                long heapSize = (long)data.getInt() & 0x00ffffffff;
-                long bytesAllocated = (long)data.getInt() & 0x00ffffffff;
-                long objectsAllocated = (long)data.getInt() & 0x00ffffffff;
-
-                client.getClientData().setHeapInfo(heapId, maxHeapSize,
-                        heapSize, bytesAllocated, objectsAllocated);
-            }
-        } catch (BufferUnderflowException ex) {
-            Log.w("ddm-heap", "malformed HPIF chunk from client");
-        }
-    }
-
-    /**
-     * Send an HPIF (HeaP InFo) request to the client.
-     */
-    public static void sendHPIF(Client client, int when) throws IOException {
-        ByteBuffer rawBuf = allocBuffer(1);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.put((byte)when);
-
-        finishChunkPacket(packet, CHUNK_HPIF, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_HPIF) + ": when=" + when);
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /*
-     * Handle a heap segment series start message.
-     */
-    private void handleHPST(Client client, ByteBuffer data) {
-        /* Clear out any data that's sitting around to
-         * get ready for the chunks that are about to come.
-         */
-//xxx todo: only clear data that belongs to the heap mentioned in <data>.
-        client.getClientData().getVmHeapData().clearHeapData();
-    }
-
-    /*
-     * Handle a heap segment series end message.
-     */
-    private void handleHPEN(Client client, ByteBuffer data) {
-        /* Let the UI know that we've received all of the
-         * data for this heap.
-         */
-//xxx todo: only seal data that belongs to the heap mentioned in <data>.
-        client.getClientData().getVmHeapData().sealHeapData();
-    }
-
-    /*
-     * Handle a heap segment message.
-     */
-    private void handleHPSG(Client client, ByteBuffer data) {
-        byte dataCopy[] = new byte[data.limit()];
-        data.rewind();
-        data.get(dataCopy);
-        data = ByteBuffer.wrap(dataCopy);
-        client.getClientData().getVmHeapData().addHeapData(data);
-//xxx todo: add to the heap mentioned in <data>
-    }
-
-    /**
-     * Sends an HPSG (HeaP SeGment) request to the client.
-     */
-    public static void sendHPSG(Client client, int when, int what)
-        throws IOException {
-
-        ByteBuffer rawBuf = allocBuffer(2);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.put((byte)when);
-        buf.put((byte)what);
-
-        finishChunkPacket(packet, CHUNK_HPSG, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_HPSG) + ": when="
-            + when + ", what=" + what);
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /**
-     * Sends an HPGC request to the client.
-     */
-    public static void sendHPGC(Client client)
-        throws IOException {
-        ByteBuffer rawBuf = allocBuffer(0);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        // no data
-
-        finishChunkPacket(packet, CHUNK_HPGC, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_HPGC));
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /**
-     * Sends a REAE (REcent Allocation Enable) request to the client.
-     */
-    public static void sendREAE(Client client, boolean enable)
-        throws IOException {
-        ByteBuffer rawBuf = allocBuffer(1);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.put((byte) (enable ? 1 : 0));
-
-        finishChunkPacket(packet, CHUNK_REAE, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_REAE) + ": " + enable);
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /**
-     * Sends a REAQ (REcent Allocation Query) request to the client.
-     */
-    public static void sendREAQ(Client client)
-        throws IOException {
-        ByteBuffer rawBuf = allocBuffer(0);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        // no data
-
-        finishChunkPacket(packet, CHUNK_REAQ, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_REAQ));
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /**
-     * Sends a REAL (REcent ALlocation) request to the client.
-     */
-    public static void sendREAL(Client client)
-        throws IOException {
-        ByteBuffer rawBuf = allocBuffer(0);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        // no data
-
-        finishChunkPacket(packet, CHUNK_REAL, buf.position());
-        Log.d("ddm-heap", "Sending " + name(CHUNK_REAL));
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /*
-     * Handle the response from our REcent Allocation Query message.
-     */
-    private void handleREAQ(Client client, ByteBuffer data) {
-        boolean enabled;
-
-        enabled = (data.get() != 0);
-        Log.d("ddm-heap", "REAQ says: enabled=" + enabled);
-        
-        client.getClientData().setAllocationStatus(enabled);
-    }
-
-    /**
-     * Converts a VM class descriptor string ("Landroid/os/Debug;") to
-     * a dot-notation class name ("android.os.Debug").
-     */
-    private String descriptorToDot(String str) {
-        // count the number of arrays.
-        int array = 0;
-        while (str.startsWith("[")) {
-            str = str.substring(1);
-            array++;
-        }
-
-        int len = str.length();
-
-        /* strip off leading 'L' and trailing ';' if appropriate */
-        if (len >= 2 && str.charAt(0) == 'L' && str.charAt(len - 1) == ';') {
-            str = str.substring(1, len-1);
-            str = str.replace('/', '.');
-        } else {
-            // convert the basic types
-            if ("C".equals(str)) {
-                str = "char";
-            } else if ("B".equals(str)) {
-                str = "byte";
-            } else if ("Z".equals(str)) {
-                str = "boolean";
-            } else if ("S".equals(str)) {
-                str = "short";
-            } else if ("I".equals(str)) {
-                str = "int";
-            } else if ("J".equals(str)) {
-                str = "long";
-            } else if ("F".equals(str)) {
-                str = "float";
-            } else if ("D".equals(str)) {
-                str = "double";
-            }
-        }
-        
-        // now add the array part
-        for (int a = 0 ; a < array; a++) {
-            str = str + "[]";
-        }
-
-        return str;
-    }
-
-    /**
-     * Reads a string table out of "data".
-     *
-     * This is just a serial collection of strings, each of which is a
-     * four-byte length followed by UTF-16 data.
-     */
-    private void readStringTable(ByteBuffer data, String[] strings) {
-        int count = strings.length;
-        int i;
-
-        for (i = 0; i < count; i++) {
-            int nameLen = data.getInt();
-            String descriptor = getString(data, nameLen);
-            strings[i] = descriptorToDot(descriptor);
-        }
-    }
-
-    /*
-     * Handle a REcent ALlocation response.
-     *
-     * Message header (all values big-endian):
-     *   (1b) message header len (to allow future expansion); includes itself
-     *   (1b) entry header len
-     *   (1b) stack frame len
-     *   (2b) number of entries
-     *   (4b) offset to string table from start of message
-     *   (2b) number of class name strings
-     *   (2b) number of method name strings
-     *   (2b) number of source file name strings
-     *   For each entry:
-     *     (4b) total allocation size
-     *     (2b) threadId
-     *     (2b) allocated object's class name index
-     *     (1b) stack depth
-     *     For each stack frame:
-     *       (2b) method's class name
-     *       (2b) method name
-     *       (2b) method source file
-     *       (2b) line number, clipped to 32767; -2 if native; -1 if no source
-     *   (xb) class name strings
-     *   (xb) method name strings
-     *   (xb) source file strings
-     * 
-     *   As with other DDM traffic, strings are sent as a 4-byte length
-     *   followed by UTF-16 data.
-     */
-    private void handleREAL(Client client, ByteBuffer data) {
-        Log.e("ddm-heap", "*** Received " + name(CHUNK_REAL));
-        int messageHdrLen, entryHdrLen, stackFrameLen;
-        int numEntries, offsetToStrings;
-        int numClassNames, numMethodNames, numFileNames;
-
-        /*
-         * Read the header.
-         */
-        messageHdrLen = (data.get() & 0xff);
-        entryHdrLen = (data.get() & 0xff);
-        stackFrameLen = (data.get() & 0xff);
-        numEntries = (data.getShort() & 0xffff);
-        offsetToStrings = data.getInt();
-        numClassNames = (data.getShort() & 0xffff);
-        numMethodNames = (data.getShort() & 0xffff);
-        numFileNames = (data.getShort() & 0xffff);
-
-
-        /*
-         * Skip forward to the strings and read them.
-         */
-        data.position(offsetToStrings);
-
-        String[] classNames = new String[numClassNames];
-        String[] methodNames = new String[numMethodNames];
-        String[] fileNames = new String[numFileNames];
-
-        readStringTable(data, classNames);
-        readStringTable(data, methodNames);
-        //System.out.println("METHODS: "
-        //    + java.util.Arrays.deepToString(methodNames));
-        readStringTable(data, fileNames);
-
-        /*
-         * Skip back to a point just past the header and start reading
-         * entries.
-         */
-        data.position(messageHdrLen);
-
-        ArrayList<AllocationInfo> list = new ArrayList<AllocationInfo>(numEntries);
-        for (int i = 0; i < numEntries; i++) {
-            int totalSize;
-            int threadId, classNameIndex, stackDepth;
-
-            totalSize = data.getInt();
-            threadId = (data.getShort() & 0xffff);
-            classNameIndex = (data.getShort() & 0xffff);
-            stackDepth = (data.get() & 0xff);
-            /* we've consumed 9 bytes; gobble up any extra */
-            for (int skip = 9; skip < entryHdrLen; skip++)
-                data.get();
-
-            StackTraceElement[] steArray = new StackTraceElement[stackDepth];
-
-            /*
-             * Pull out the stack trace.
-             */
-            for (int sti = 0; sti < stackDepth; sti++) {
-                int methodClassNameIndex, methodNameIndex;
-                int methodSourceFileIndex;
-                short lineNumber;
-                String methodClassName, methodName, methodSourceFile;
-
-                methodClassNameIndex = (data.getShort() & 0xffff);
-                methodNameIndex = (data.getShort() & 0xffff);
-                methodSourceFileIndex = (data.getShort() & 0xffff);
-                lineNumber = data.getShort();
-
-                methodClassName = classNames[methodClassNameIndex];
-                methodName = methodNames[methodNameIndex];
-                methodSourceFile = fileNames[methodSourceFileIndex];
-
-                steArray[sti] = new StackTraceElement(methodClassName,
-                    methodName, methodSourceFile, lineNumber);
-
-                /* we've consumed 8 bytes; gobble up any extra */
-                for (int skip = 9; skip < stackFrameLen; skip++)
-                    data.get();
-            }
-
-            list.add(new AllocationInfo(classNames[classNameIndex],
-                totalSize, (short) threadId, steArray));
-        }
-        
-        // sort biggest allocations first.
-        Collections.sort(list);
-        
-        client.getClientData().setAllocations(list.toArray(new AllocationInfo[numEntries]));
-    }
-
-    /*
-     * For debugging: dump the contents of an AllocRecord array.
-     *
-     * The array starts with the oldest known allocation and ends with
-     * the most recent allocation.
-     */
-    @SuppressWarnings("unused")
-    private static void dumpRecords(AllocationInfo[] records) {
-        System.out.println("Found " + records.length + " records:");
-
-        for (AllocationInfo rec: records) {
-            System.out.println("tid=" + rec.getThreadId() + " "
-                + rec.getAllocatedClass() + " (" + rec.getSize() + " bytes)");
-
-            for (StackTraceElement ste: rec.getStackTrace()) {
-                if (ste.isNativeMethod()) {
-                    System.out.println("    " + ste.getClassName() 
-                        + "." + ste.getMethodName()
-                        + " (Native method)");
-                } else {
-                    System.out.println("    " + ste.getClassName() 
-                        + "." + ste.getMethodName()
-                        + " (" + ste.getFileName()
-                        + ":" + ste.getLineNumber() + ")");
-                }
-            }
-        }
-    }
-
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHello.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHello.java
deleted file mode 100644
index 5ba5aeb..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleHello.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Handle the "hello" chunk (HELO).
- */
-final class HandleHello extends ChunkHandler {
-
-    public static final int CHUNK_HELO = ChunkHandler.type("HELO");
-
-    private static final HandleHello mInst = new HandleHello();
-
-
-    private HandleHello() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_HELO, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {
-        Log.d("ddm-hello", "Now ready: " + client);
-    }
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {
-        Log.d("ddm-hello", "Now disconnected: " + client);
-    }
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-
-        Log.d("ddm-hello", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_HELO) {
-            assert isReply;
-            handleHELO(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a reply to our HELO message.
-     */
-    private static void handleHELO(Client client, ByteBuffer data) {
-        int version, pid, vmIdentLen, appNameLen;
-        String vmIdent, appName;
-
-        version = data.getInt();
-        pid = data.getInt();
-        vmIdentLen = data.getInt();
-        appNameLen = data.getInt();
-
-        vmIdent = getString(data, vmIdentLen);
-        appName = getString(data, appNameLen);
-        
-        Log.d("ddm-hello", "HELO: v=" + version + ", pid=" + pid
-            + ", vm='" + vmIdent + "', app='" + appName + "'");
-
-        ClientData cd = client.getClientData();
-        
-        synchronized (cd) {
-            if (cd.getPid() == pid) {
-                cd.setVmIdentifier(vmIdent);
-                cd.setClientDescription(appName);
-                cd.isDdmAware(true);
-            } else {
-                Log.e("ddm-hello", "Received pid (" + pid + ") does not match client pid ("
-                        + cd.getPid() + ")");
-            }
-        }
-
-        client = checkDebuggerPortForAppName(client, appName);
-
-        if (client != null) {
-            client.update(Client.CHANGE_NAME);
-        }
-    }
-
-
-    /**
-     * Send a HELO request to the client.
-     */
-    public static void sendHELO(Client client, int serverProtocolVersion)
-        throws IOException
-    {
-        ByteBuffer rawBuf = allocBuffer(4);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.putInt(serverProtocolVersion);
-
-        finishChunkPacket(packet, CHUNK_HELO, buf.position());
-        Log.d("ddm-hello", "Sending " + name(CHUNK_HELO)
-            + " ID=0x" + Integer.toHexString(packet.getId()));
-        client.sendAndConsume(packet, mInst);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleNativeHeap.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleNativeHeap.java
deleted file mode 100644
index ca26590..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleNativeHeap.java
+++ /dev/null
@@ -1,305 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.BufferedReader;
-import java.io.ByteArrayInputStream;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Handle thread status updates.
- */
-final class HandleNativeHeap extends ChunkHandler {
-
-    public static final int CHUNK_NHGT = type("NHGT"); // $NON-NLS-1$
-    public static final int CHUNK_NHSG = type("NHSG"); // $NON-NLS-1$
-    public static final int CHUNK_NHST = type("NHST"); // $NON-NLS-1$
-    public static final int CHUNK_NHEN = type("NHEN"); // $NON-NLS-1$
-
-    private static final HandleNativeHeap mInst = new HandleNativeHeap();
-
-    private HandleNativeHeap() {
-    }
-
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_NHGT, mInst);
-        mt.registerChunkHandler(CHUNK_NHSG, mInst);
-        mt.registerChunkHandler(CHUNK_NHST, mInst);
-        mt.registerChunkHandler(CHUNK_NHEN, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {}
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-
-        Log.d("ddm-nativeheap", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_NHGT) {
-            handleNHGT(client, data);
-        } else if (type == CHUNK_NHST) {
-            // start chunk before any NHSG chunk(s)
-            client.getClientData().getNativeHeapData().clearHeapData();
-        } else if (type == CHUNK_NHEN) {
-            // end chunk after NHSG chunk(s)
-            client.getClientData().getNativeHeapData().sealHeapData();
-        } else if (type == CHUNK_NHSG) {
-            handleNHSG(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-
-        client.update(Client.CHANGE_NATIVE_HEAP_DATA);
-    }
-
-    /**
-     * Send an NHGT (Native Thread GeT) request to the client.
-     */
-    public static void sendNHGT(Client client) throws IOException {
-
-        ByteBuffer rawBuf = allocBuffer(0);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        // no data in request message
-
-        finishChunkPacket(packet, CHUNK_NHGT, buf.position());
-        Log.d("ddm-nativeheap", "Sending " + name(CHUNK_NHGT));
-        client.sendAndConsume(packet, mInst);
-
-        rawBuf = allocBuffer(2);
-        packet = new JdwpPacket(rawBuf);
-        buf = getChunkDataBuf(rawBuf);
-
-        buf.put((byte)HandleHeap.WHEN_GC);
-        buf.put((byte)HandleHeap.WHAT_OBJ);
-
-        finishChunkPacket(packet, CHUNK_NHSG, buf.position());
-        Log.d("ddm-nativeheap", "Sending " + name(CHUNK_NHSG));
-        client.sendAndConsume(packet, mInst);
-    }
-
-    /*
-     * Handle our native heap data.
-     */
-    private void handleNHGT(Client client, ByteBuffer data) {
-        ClientData cd = client.getClientData();
-
-        Log.d("ddm-nativeheap", "NHGT: " + data.limit() + " bytes");
-
-        // TODO - process incoming data and save in "cd"
-        byte[] copy = new byte[data.limit()];
-        data.get(copy);
-
-        // clear the previous run
-        cd.clearNativeAllocationInfo();
-
-        ByteBuffer buffer = ByteBuffer.wrap(copy);
-        buffer.order(ByteOrder.LITTLE_ENDIAN);
-
-//        read the header
-//        typedef struct Header {
-//            uint32_t mapSize;
-//            uint32_t allocSize;
-//            uint32_t allocInfoSize;
-//            uint32_t totalMemory;
-//              uint32_t backtraceSize;
-//        };
-
-        int mapSize = buffer.getInt();
-        int allocSize = buffer.getInt();
-        int allocInfoSize = buffer.getInt();
-        int totalMemory = buffer.getInt();
-        int backtraceSize = buffer.getInt();
-
-        Log.d("ddms", "mapSize: " + mapSize);
-        Log.d("ddms", "allocSize: " + allocSize);
-        Log.d("ddms", "allocInfoSize: " + allocInfoSize);
-        Log.d("ddms", "totalMemory: " + totalMemory);
-
-        cd.setTotalNativeMemory(totalMemory);
-
-        // this means that updates aren't turned on.
-        if (allocInfoSize == 0)
-          return;
-
-        if (mapSize > 0) {
-            byte[] maps = new byte[mapSize];
-            buffer.get(maps, 0, mapSize);
-            parseMaps(cd, maps);
-        }
-
-        int iterations = allocSize / allocInfoSize;
-
-        for (int i = 0 ; i < iterations ; i++) {
-            NativeAllocationInfo info = new NativeAllocationInfo(
-                    buffer.getInt() /* size */,
-                    buffer.getInt() /* allocations */);
-
-            for (int j = 0 ; j < backtraceSize ; j++) {
-                long addr = ((long)buffer.getInt()) & 0x00000000ffffffffL;
-
-                info.addStackCallAddress(addr);;
-            }
-
-            cd.addNativeAllocation(info);
-        }
-    }
-
-    private void handleNHSG(Client client, ByteBuffer data) {
-        byte dataCopy[] = new byte[data.limit()];
-        data.rewind();
-        data.get(dataCopy);
-        data = ByteBuffer.wrap(dataCopy);
-        client.getClientData().getNativeHeapData().addHeapData(data);
-
-        if (true) {
-            return;
-        }
-
-        // WORK IN PROGRESS
-
-//        Log.e("ddm-nativeheap", "NHSG: ----------------------------------");
-//        Log.e("ddm-nativeheap", "NHSG: " + data.limit() + " bytes");
-
-        byte[] copy = new byte[data.limit()];
-        data.get(copy);
-
-        ByteBuffer buffer = ByteBuffer.wrap(copy);
-        buffer.order(ByteOrder.BIG_ENDIAN);
-
-        int id = buffer.getInt();
-        int unitsize = (int) buffer.get();
-        long startAddress = (long) buffer.getInt() & 0x00000000ffffffffL;
-        int offset = buffer.getInt();
-        int allocationUnitCount = buffer.getInt();
-
-//        Log.e("ddm-nativeheap", "id: " + id);
-//        Log.e("ddm-nativeheap", "unitsize: " + unitsize);
-//        Log.e("ddm-nativeheap", "startAddress: 0x" + Long.toHexString(startAddress));
-//        Log.e("ddm-nativeheap", "offset: " + offset);
-//        Log.e("ddm-nativeheap", "allocationUnitCount: " + allocationUnitCount);
-//        Log.e("ddm-nativeheap", "end: 0x" +
-//                Long.toHexString(startAddress + unitsize * allocationUnitCount));
-
-        // read the usage
-        while (buffer.position() < buffer.limit()) {
-            int eState = (int)buffer.get() & 0x000000ff;
-            int eLen = ((int)buffer.get() & 0x000000ff) + 1;
-            //Log.e("ddm-nativeheap", "solidity: " + (eState & 0x7) + " - kind: "
-            //        + ((eState >> 3) & 0x7) + " - len: " + eLen);
-        }
-
-
-//        count += unitsize * allocationUnitCount;
-//        Log.e("ddm-nativeheap", "count = " + count);
-
-    }
-
-    private void parseMaps(ClientData cd, byte[] maps) {
-        InputStreamReader input = new InputStreamReader(new ByteArrayInputStream(maps));
-        BufferedReader reader = new BufferedReader(input);
-
-        String line;
-
-        try {
-
-            // most libraries are defined on several lines, so we need to make sure we parse
-            // all the library lines and only add the library at the end
-            long startAddr = 0;
-            long endAddr = 0;
-            String library = null;
-
-            while ((line = reader.readLine()) != null) {
-                Log.d("ddms", "line: " + line);
-                if (line.length() < 16) {
-                    continue;
-                }
-
-                try {
-                    long tmpStart = Long.parseLong(line.substring(0, 8), 16);
-                    long tmpEnd = Long.parseLong(line.substring(9, 17), 16);
-
-                     /*
-                      * only check for library addresses as defined in
-                      * //device/config/prelink-linux-arm.map
-                      */
-                    if (tmpStart >= 0x0000000080000000L && tmpStart <= 0x00000000BFFFFFFFL) {
-
-                        int index = line.indexOf('/');
-
-                        if (index == -1)
-                            continue;
-
-                        String tmpLib = line.substring(index);
-
-                        if (library == null ||
-                                (library != null && tmpLib.equals(library) == false)) {
-
-                            if (library != null) {
-                                cd.addNativeLibraryMapInfo(startAddr, endAddr, library);
-                                Log.d("ddms", library + "(" + Long.toHexString(startAddr) +
-                                        " - " + Long.toHexString(endAddr) + ")");
-                            }
-
-                            // now init the new library
-                            library = tmpLib;
-                            startAddr = tmpStart;
-                            endAddr = tmpEnd;
-                        } else {
-                            // add the new end
-                            endAddr = tmpEnd;
-                        }
-                    }
-                } catch (NumberFormatException e) {
-                    e.printStackTrace();
-                }
-            }
-
-            if (library != null) {
-                cd.addNativeLibraryMapInfo(startAddr, endAddr, library);
-                Log.d("ddms", library + "(" + Long.toHexString(startAddr) +
-                        " - " + Long.toHexString(endAddr) + ")");
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-
-
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleTest.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleTest.java
deleted file mode 100644
index b9f3a74..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleTest.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Log.LogLevel;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Handle thread status updates.
- */
-final class HandleTest extends ChunkHandler {
-
-    public static final int CHUNK_TEST = type("TEST");
-
-    private static final HandleTest mInst = new HandleTest();
-
-
-    private HandleTest() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_TEST, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {}
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-
-        Log.d("ddm-test", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_TEST) {
-            handleTEST(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a thread creation message.
-     */
-    private void handleTEST(Client client, ByteBuffer data)
-    {
-        /*
-         * Can't call data.array() on a read-only ByteBuffer, so we make
-         * a copy.
-         */
-        byte[] copy = new byte[data.limit()];
-        data.get(copy);
-
-        Log.d("ddm-test", "Received:");
-        Log.hexDump("ddm-test", LogLevel.DEBUG, copy, 0, copy.length);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleThread.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleThread.java
deleted file mode 100644
index 572eed2..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleThread.java
+++ /dev/null
@@ -1,379 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Handle thread status updates.
- */
-final class HandleThread extends ChunkHandler {
-
-    public static final int CHUNK_THEN = type("THEN");
-    public static final int CHUNK_THCR = type("THCR");
-    public static final int CHUNK_THDE = type("THDE");
-    public static final int CHUNK_THST = type("THST");
-    public static final int CHUNK_THNM = type("THNM");
-    public static final int CHUNK_STKL = type("STKL");
-
-    private static final HandleThread mInst = new HandleThread();
-
-    // only read/written by requestThreadUpdates()
-    private static volatile boolean mThreadStatusReqRunning = false;
-    private static volatile boolean mThreadStackTraceReqRunning = false;
-
-    private HandleThread() {}
-
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_THCR, mInst);
-        mt.registerChunkHandler(CHUNK_THDE, mInst);
-        mt.registerChunkHandler(CHUNK_THST, mInst);
-        mt.registerChunkHandler(CHUNK_THNM, mInst);
-        mt.registerChunkHandler(CHUNK_STKL, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {
-        Log.d("ddm-thread", "Now ready: " + client);
-        if (client.isThreadUpdateEnabled())
-            sendTHEN(client, true);
-    }
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-
-        Log.d("ddm-thread", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_THCR) {
-            handleTHCR(client, data);
-        } else if (type == CHUNK_THDE) {
-            handleTHDE(client, data);
-        } else if (type == CHUNK_THST) {
-            handleTHST(client, data);
-        } else if (type == CHUNK_THNM) {
-            handleTHNM(client, data);
-        } else if (type == CHUNK_STKL) {
-            handleSTKL(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a thread creation message.
-     *
-     * We should be tolerant of receiving a duplicate create message.  (It
-     * shouldn't happen with the current implementation.)
-     */
-    private void handleTHCR(Client client, ByteBuffer data) {
-        int threadId, nameLen;
-        String name;
-
-        threadId = data.getInt();
-        nameLen = data.getInt();
-        name = getString(data, nameLen);
-
-        Log.v("ddm-thread", "THCR: " + threadId + " '" + name + "'");
-
-        client.getClientData().addThread(threadId, name);
-        client.update(Client.CHANGE_THREAD_DATA);
-    }
-
-    /*
-     * Handle a thread death message.
-     */
-    private void handleTHDE(Client client, ByteBuffer data) {
-        int threadId;
-
-        threadId = data.getInt();
-        Log.v("ddm-thread", "THDE: " + threadId);
-
-        client.getClientData().removeThread(threadId);
-        client.update(Client.CHANGE_THREAD_DATA);
-    }
-
-    /*
-     * Handle a thread status update message.
-     *
-     * Response has:
-     *  (1b) header len
-     *  (1b) bytes per entry
-     *  (2b) thread count
-     * Then, for each thread:
-     *  (4b) threadId (matches value from THCR)
-     *  (1b) thread status
-     *  (4b) tid
-     *  (4b) utime
-     *  (4b) stime
-     */
-    private void handleTHST(Client client, ByteBuffer data) {
-        int headerLen, bytesPerEntry, extraPerEntry;
-        int threadCount;
-
-        headerLen = (data.get() & 0xff);
-        bytesPerEntry = (data.get() & 0xff);
-        threadCount = data.getShort();
-
-        headerLen -= 4;     // we've read 4 bytes
-        while (headerLen-- > 0)
-            data.get();
-
-        extraPerEntry = bytesPerEntry - 18;     // we want 18 bytes
-
-        Log.v("ddm-thread", "THST: threadCount=" + threadCount);
-
-        /*
-         * For each thread, extract the data, find the appropriate
-         * client, and add it to the ClientData.
-         */
-        for (int i = 0; i < threadCount; i++) {
-            int threadId, status, tid, utime, stime;
-            boolean isDaemon = false;
-
-            threadId = data.getInt();
-            status = data.get();
-            tid = data.getInt();
-            utime = data.getInt();
-            stime = data.getInt();
-            if (bytesPerEntry >= 18)
-                isDaemon = (data.get() != 0);
-
-            Log.v("ddm-thread", "  id=" + threadId
-                + ", status=" + status + ", tid=" + tid
-                + ", utime=" + utime + ", stime=" + stime);
-
-            ClientData cd = client.getClientData();
-            ThreadInfo threadInfo = cd.getThread(threadId);
-            if (threadInfo != null)
-                threadInfo.updateThread(status, tid, utime, stime, isDaemon);
-            else
-                Log.i("ddms", "Thread with id=" + threadId + " not found");
-
-            // slurp up any extra
-            for (int slurp = extraPerEntry; slurp > 0; slurp--)
-                data.get();
-        }
-        
-        client.update(Client.CHANGE_THREAD_DATA);
-    }
-
-    /*
-     * Handle a THNM (THread NaMe) message.  We get one of these after
-     * somebody calls Thread.setName() on a running thread.
-     */
-    private void handleTHNM(Client client, ByteBuffer data) {
-        int threadId, nameLen;
-        String name;
-
-        threadId = data.getInt();
-        nameLen = data.getInt();
-        name = getString(data, nameLen);
-
-        Log.v("ddm-thread", "THNM: " + threadId + " '" + name + "'");
-
-        ThreadInfo threadInfo = client.getClientData().getThread(threadId);
-        if (threadInfo != null) {
-            threadInfo.setThreadName(name);
-            client.update(Client.CHANGE_THREAD_DATA);
-        } else {
-            Log.i("ddms", "Thread with id=" + threadId + " not found");
-        }
-    }
-
-
-    /**
-     * Parse an incoming STKL.
-     */
-    private void handleSTKL(Client client, ByteBuffer data) {
-        StackTraceElement[] trace;
-        int i, threadId, stackDepth;
-        @SuppressWarnings("unused")
-        int future;
-
-        future = data.getInt();
-        threadId = data.getInt();
-
-        Log.v("ddms", "STKL: " + threadId);
-
-        /* un-serialize the StackTraceElement[] */
-        stackDepth = data.getInt();
-        trace = new StackTraceElement[stackDepth];
-        for (i = 0; i < stackDepth; i++) {
-            String className, methodName, fileName;
-            int len, lineNumber;
-
-            len = data.getInt();
-            className = getString(data, len);
-            len = data.getInt();
-            methodName = getString(data, len);
-            len = data.getInt();
-            if (len == 0) {
-                fileName = null;
-            } else {
-                fileName = getString(data, len);
-            }
-            lineNumber = data.getInt();
-
-            trace[i] = new StackTraceElement(className, methodName, fileName,
-                        lineNumber);
-        }
-
-        ThreadInfo threadInfo = client.getClientData().getThread(threadId);
-        if (threadInfo != null) {
-            threadInfo.setStackCall(trace);
-            client.update(Client.CHANGE_THREAD_STACKTRACE);
-        } else {
-            Log.d("STKL", String.format(
-                    "Got stackcall for thread %1$d, which does not exists (anymore?).", //$NON-NLS-1$
-                    threadId));
-        }
-    }
-
-
-    /**
-     * Send a THEN (THread notification ENable) request to the client.
-     */
-    public static void sendTHEN(Client client, boolean enable)
-        throws IOException {
-
-        ByteBuffer rawBuf = allocBuffer(1);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        if (enable)
-            buf.put((byte)1);
-        else
-            buf.put((byte)0);
-
-        finishChunkPacket(packet, CHUNK_THEN, buf.position());
-        Log.d("ddm-thread", "Sending " + name(CHUNK_THEN) + ": " + enable);
-        client.sendAndConsume(packet, mInst);
-    }
-
-
-    /**
-     * Send a STKL (STacK List) request to the client.  The VM will suspend
-     * the target thread, obtain its stack, and return it.  If the thread
-     * is no longer running, a failure result will be returned.
-     */
-    public static void sendSTKL(Client client, int threadId)
-        throws IOException {
-
-        if (false) {
-            Log.i("ddm-thread", "would send STKL " + threadId);
-            return;
-        }
-
-        ByteBuffer rawBuf = allocBuffer(4);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        buf.putInt(threadId);
-
-        finishChunkPacket(packet, CHUNK_STKL, buf.position());
-        Log.d("ddm-thread", "Sending " + name(CHUNK_STKL) + ": " + threadId);
-        client.sendAndConsume(packet, mInst);
-    }
-
-
-    /**
-     * This is called periodically from the UI thread.  To avoid locking
-     * the UI while we request the updates, we create a new thread.
-     *
-     */
-    static void requestThreadUpdate(final Client client) {
-        if (client.isDdmAware() && client.isThreadUpdateEnabled()) {
-            if (mThreadStatusReqRunning) {
-                Log.w("ddms", "Waiting for previous thread update req to finish");
-                return;
-            }
-
-            new Thread("Thread Status Req") {
-                @Override
-                public void run() {
-                    mThreadStatusReqRunning = true;
-                    try {
-                        sendTHST(client);
-                    } catch (IOException ioe) {
-                        Log.i("ddms", "Unable to request thread updates from "
-                                + client + ": " + ioe.getMessage());
-                    } finally {
-                        mThreadStatusReqRunning = false;
-                    }
-                }
-            }.start();
-        }
-    }
-    
-    static void requestThreadStackCallRefresh(final Client client, final int threadId) {
-        if (client.isDdmAware() && client.isThreadUpdateEnabled()) {
-            if (mThreadStackTraceReqRunning ) {
-                Log.w("ddms", "Waiting for previous thread stack call req to finish");
-                return;
-            }
-
-            new Thread("Thread Status Req") {
-                @Override
-                public void run() {
-                    mThreadStackTraceReqRunning = true;
-                    try {
-                        sendSTKL(client, threadId);
-                    } catch (IOException ioe) {
-                        Log.i("ddms", "Unable to request thread stack call updates from "
-                                + client + ": " + ioe.getMessage());
-                    } finally {
-                        mThreadStackTraceReqRunning = false;
-                    }
-                }
-            }.start();
-        }
-        
-    }
-
-    /*
-     * Send a THST request to the specified client.
-     */
-    private static void sendTHST(Client client) throws IOException {
-        ByteBuffer rawBuf = allocBuffer(0);
-        JdwpPacket packet = new JdwpPacket(rawBuf);
-        ByteBuffer buf = getChunkDataBuf(rawBuf);
-
-        // nothing much to say
-
-        finishChunkPacket(packet, CHUNK_THST, buf.position());
-        Log.d("ddm-thread", "Sending " + name(CHUNK_THST));
-        client.sendAndConsume(packet, mInst);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleWait.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleWait.java
deleted file mode 100644
index d27e636..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HandleWait.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-/**
- * Handle the "wait" chunk (WAIT).  These are sent up when the client is
- * waiting for something, e.g. for a debugger to attach.
- */
-final class HandleWait extends ChunkHandler {
-
-    public static final int CHUNK_WAIT = ChunkHandler.type("WAIT");
-
-    private static final HandleWait mInst = new HandleWait();
-
-
-    private HandleWait() {}
-
-    /**
-     * Register for the packets we expect to get from the client.
-     */
-    public static void register(MonitorThread mt) {
-        mt.registerChunkHandler(CHUNK_WAIT, mInst);
-    }
-
-    /**
-     * Client is ready.
-     */
-    @Override
-    public void clientReady(Client client) throws IOException {}
-
-    /**
-     * Client went away.
-     */
-    @Override
-    public void clientDisconnected(Client client) {}
-
-    /**
-     * Chunk handler entry point.
-     */
-    @Override
-    public void handleChunk(Client client, int type, ByteBuffer data, boolean isReply, int msgId) {
-
-        Log.d("ddm-wait", "handling " + ChunkHandler.name(type));
-
-        if (type == CHUNK_WAIT) {
-            assert !isReply;
-            handleWAIT(client, data);
-        } else {
-            handleUnknownChunk(client, type, data, isReply, msgId);
-        }
-    }
-
-    /*
-     * Handle a reply to our WAIT message.
-     */
-    private static void handleWAIT(Client client, ByteBuffer data) {
-        byte reason;
-
-        reason = data.get();
-
-        Log.i("ddm-wait", "WAIT: reason=" + reason);
-
-
-        ClientData cd = client.getClientData();
-        synchronized (cd) {
-            cd.setDebuggerConnectionStatus(ClientData.DEBUGGER_WAITING);
-        }
-
-        client.update(Client.CHANGE_DEBUGGER_INTEREST);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HeapSegment.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HeapSegment.java
deleted file mode 100644
index 6a62e60..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/HeapSegment.java
+++ /dev/null
@@ -1,446 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.nio.BufferUnderflowException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.text.ParseException;
-
-/**
- * Describes the types and locations of objects in a segment of a heap.
- */
-public final class HeapSegment implements Comparable<HeapSegment> {
-
-    /**
-     * Describes an object/region encoded in the HPSG data.
-     */
-    public static class HeapSegmentElement implements Comparable<HeapSegmentElement> {
-
-        /*
-         * Solidity values, which must match the values in
-         * the HPSG data.
-         */
-
-        /** The element describes a free block. */
-        public static int SOLIDITY_FREE = 0;
-
-        /** The element is strongly-reachable. */
-        public static int SOLIDITY_HARD = 1;
-
-        /** The element is softly-reachable. */
-        public static int SOLIDITY_SOFT = 2;
-
-        /** The element is weakly-reachable. */
-        public static int SOLIDITY_WEAK = 3;
-
-        /** The element is phantom-reachable. */
-        public static int SOLIDITY_PHANTOM = 4;
-
-        /** The element is pending finalization. */
-        public static int SOLIDITY_FINALIZABLE = 5;
-
-        /** The element is not reachable, and is about to be swept/freed. */
-        public static int SOLIDITY_SWEEP = 6;
-
-        /** The reachability of the object is unknown. */
-        public static int SOLIDITY_INVALID = -1;
-
-
-        /*
-         * Kind values, which must match the values in
-         * the HPSG data.
-         */
-
-        /** The element describes a data object. */
-        public static int KIND_OBJECT = 0;
-
-        /** The element describes a class object. */
-        public static int KIND_CLASS_OBJECT = 1;
-
-        /** The element describes an array of 1-byte elements. */
-        public static int KIND_ARRAY_1 = 2;
-
-        /** The element describes an array of 2-byte elements. */
-        public static int KIND_ARRAY_2 = 3;
-
-        /** The element describes an array of 4-byte elements. */
-        public static int KIND_ARRAY_4 = 4;
-
-        /** The element describes an array of 8-byte elements. */
-        public static int KIND_ARRAY_8 = 5;
-
-        /** The element describes an unknown type of object. */
-        public static int KIND_UNKNOWN = 6;
-
-        /** The element describes a native object. */
-        public static int KIND_NATIVE = 7;
-
-        /** The object kind is unknown or unspecified. */
-        public static int KIND_INVALID = -1;
-
-
-        /**
-         * A bit in the HPSG data that indicates that an element should
-         * be combined with the element that follows, typically because
-         * an element is too large to be described by a single element.
-         */
-        private static int PARTIAL_MASK = 1 << 7;
-
-
-        /**
-         * Describes the reachability/solidity of the element.  Must
-         * be set to one of the SOLIDITY_* values.
-         */
-        private int mSolidity;
-
-        /**
-         * Describes the type/kind of the element.  Must be set to one
-         * of the KIND_* values.
-         */
-        private int mKind;
-
-        /**
-         * Describes the length of the element, in bytes.
-         */
-        private int mLength;
-
-
-        /**
-         * Creates an uninitialized element.
-         */
-        public HeapSegmentElement() {
-            setSolidity(SOLIDITY_INVALID);
-            setKind(KIND_INVALID);
-            setLength(-1);
-        }
-
-        /**
-         * Create an element describing the entry at the current
-         * position of hpsgData.
-         *
-         * @param hs The heap segment to pull the entry from.
-         * @throws BufferUnderflowException if there is not a whole entry
-         *                                  following the current position
-         *                                  of hpsgData.
-         * @throws ParseException           if the provided data is malformed.
-         */
-        public HeapSegmentElement(HeapSegment hs)
-                throws BufferUnderflowException, ParseException {
-            set(hs);
-        }
-
-        /**
-         * Replace the element with the entry at the current position of
-         * hpsgData.
-         *
-         * @param hs The heap segment to pull the entry from.
-         * @return this object.
-         * @throws BufferUnderflowException if there is not a whole entry
-         *                                  following the current position of
-         *                                  hpsgData.
-         * @throws ParseException           if the provided data is malformed.
-         */
-        public HeapSegmentElement set(HeapSegment hs)
-                throws BufferUnderflowException, ParseException {
-
-            /* TODO: Maybe keep track of the virtual address of each element
-             *       so that they can be examined independently.
-             */
-            ByteBuffer data = hs.mUsageData;
-            int eState = (int)data.get() & 0x000000ff;
-            int eLen = ((int)data.get() & 0x000000ff) + 1;
-
-            while ((eState & PARTIAL_MASK) != 0) {
-
-                /* If the partial bit was set, the next byte should describe
-                 * the same object as the current one.
-                 */
-                int nextState = (int)data.get() & 0x000000ff;
-                if ((nextState & ~PARTIAL_MASK) != (eState & ~PARTIAL_MASK)) {
-                    throw new ParseException("State mismatch", data.position());
-                }
-                eState = nextState;
-                eLen += ((int)data.get() & 0x000000ff) + 1;
-            }
-
-            setSolidity(eState & 0x7);
-            setKind((eState >> 3) & 0x7);
-            setLength(eLen * hs.mAllocationUnitSize);
-
-            return this;
-        }
-
-        public int getSolidity() {
-            return mSolidity;
-        }
-
-        public void setSolidity(int solidity) {
-            this.mSolidity = solidity;
-        }
-
-        public int getKind() {
-            return mKind;
-        }
-
-        public void setKind(int kind) {
-            this.mKind = kind;
-        }
-
-        public int getLength() {
-            return mLength;
-        }
-
-        public void setLength(int length) {
-            this.mLength = length;
-        }
-
-        public int compareTo(HeapSegmentElement other) {
-            if (mLength != other.mLength) {
-                return mLength < other.mLength ? -1 : 1;
-            }
-            return 0;
-        }
-    }
-
-    //* The ID of the heap that this segment belongs to.
-    protected int mHeapId;
-
-    //* The size of an allocation unit, in bytes. (e.g., 8 bytes)
-    protected int mAllocationUnitSize;
-
-    //* The virtual address of the start of this segment.
-    protected long mStartAddress;
-
-    //* The offset of this pices from mStartAddress, in bytes.
-    protected int mOffset;
-
-    //* The number of allocation units described in this segment.
-    protected int mAllocationUnitCount;
-
-    //* The raw data that describes the contents of this segment.
-    protected ByteBuffer mUsageData;
-
-    //* mStartAddress is set to this value when the segment becomes invalid.
-    private final static long INVALID_START_ADDRESS = -1;
-
-    /**
-     * Create a new HeapSegment based on the raw contents
-     * of an HPSG chunk.
-     *
-     * @param hpsgData The raw data from an HPSG chunk.
-     * @throws BufferUnderflowException if hpsgData is too small
-     *                                  to hold the HPSG chunk header data.
-     */
-    public HeapSegment(ByteBuffer hpsgData) throws BufferUnderflowException {
-        /* Read the HPSG chunk header.
-         * These get*() calls may throw a BufferUnderflowException
-         * if the underlying data isn't big enough.
-         */
-        hpsgData.order(ByteOrder.BIG_ENDIAN);
-        mHeapId = hpsgData.getInt();
-        mAllocationUnitSize = (int) hpsgData.get();
-        mStartAddress = (long) hpsgData.getInt() & 0x00000000ffffffffL;
-        mOffset = hpsgData.getInt();
-        mAllocationUnitCount = hpsgData.getInt();
-
-        // Hold onto the remainder of the data.
-        mUsageData = hpsgData.slice();
-        mUsageData.order(ByteOrder.BIG_ENDIAN);   // doesn't actually matter
-
-        // Validate the data.
-//xxx do it
-//xxx make sure the number of elements matches mAllocationUnitCount.
-//xxx make sure the last element doesn't have P set
-    }
-
-    /**
-     * See if this segment still contains data, and has not been
-     * appended to another segment.
-     *
-     * @return true if this segment has not been appended to
-     *         another segment.
-     */
-    public boolean isValid() {
-        return mStartAddress != INVALID_START_ADDRESS;
-    }
-
-    /**
-     * See if <code>other</code> comes immediately after this segment.
-     *
-     * @param other The HeapSegment to check.
-     * @return true if <code>other</code> comes immediately after this
-     *         segment.
-     */
-    public boolean canAppend(HeapSegment other) {
-        return isValid() && other.isValid() && mHeapId == other.mHeapId &&
-                mAllocationUnitSize == other.mAllocationUnitSize &&
-                getEndAddress() == other.getStartAddress();
-    }
-
-    /**
-     * Append the contents of <code>other</code> to this segment
-     * if it describes the segment immediately after this one.
-     *
-     * @param other The segment to append to this segment, if possible.
-     *              If appended, <code>other</code> will be invalid
-     *              when this method returns.
-     * @return true if <code>other</code> was successfully appended to
-     *         this segment.
-     */
-    public boolean append(HeapSegment other) {
-        if (canAppend(other)) {
-            /* Preserve the position.  The mark is not preserved,
-             * but we don't use it anyway.
-             */
-            int pos = mUsageData.position();
-
-            // Guarantee that we have enough room for the new data.
-            if (mUsageData.capacity() - mUsageData.limit() <
-                    other.mUsageData.limit()) {
-                /* Grow more than necessary in case another append()
-                 * is about to happen.
-                 */
-                int newSize = mUsageData.limit() + other.mUsageData.limit();
-                ByteBuffer newData = ByteBuffer.allocate(newSize * 2);
-
-                mUsageData.rewind();
-                newData.put(mUsageData);
-                mUsageData = newData;
-            }
-
-            // Copy the data from the other segment and restore the position.
-            other.mUsageData.rewind();
-            mUsageData.put(other.mUsageData);
-            mUsageData.position(pos);
-
-            // Fix this segment's header to cover the new data.
-            mAllocationUnitCount += other.mAllocationUnitCount;
-
-            // Mark the other segment as invalid.
-            other.mStartAddress = INVALID_START_ADDRESS;
-            other.mUsageData = null;
-
-            return true;
-        } else {
-            return false;
-        }
-    }
-
-    public long getStartAddress() {
-        return mStartAddress + mOffset;
-    }
-
-    public int getLength() {
-        return mAllocationUnitSize * mAllocationUnitCount;
-    }
-
-    public long getEndAddress() {
-        return getStartAddress() + getLength();
-    }
-
-    public void rewindElements() {
-        if (mUsageData != null) {
-            mUsageData.rewind();
-        }
-    }
-
-    public HeapSegmentElement getNextElement(HeapSegmentElement reuse) {
-        try {
-            if (reuse != null) {
-                return reuse.set(this);
-            } else {
-                return new HeapSegmentElement(this);
-            }
-        } catch (BufferUnderflowException ex) {
-            /* Normal "end of buffer" situation.
-             */
-        } catch (ParseException ex) {
-            /* Malformed data.
-             */
-//TODO: we should catch this in the constructor
-        }
-        return null;
-    }
-
-    /*
-     * Method overrides for Comparable
-     */
-    @Override
-    public boolean equals(Object o) {
-        if (o instanceof HeapSegment) {
-            return compareTo((HeapSegment) o) == 0;
-        }
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return mHeapId * 31 +
-                mAllocationUnitSize * 31 +
-                (int) mStartAddress * 31 +
-                mOffset * 31 +
-                mAllocationUnitCount * 31 +
-                mUsageData.hashCode();
-    }
-
-    @Override
-    public String toString() {
-        StringBuilder str = new StringBuilder();
-
-        str.append("HeapSegment { heap ").append(mHeapId)
-                .append(", start 0x")
-                .append(Integer.toHexString((int) getStartAddress()))
-                .append(", length ").append(getLength())
-                .append(" }");
-
-        return str.toString();
-    }
-
-    public int compareTo(HeapSegment other) {
-        if (mHeapId != other.mHeapId) {
-            return mHeapId < other.mHeapId ? -1 : 1;
-        }
-        if (getStartAddress() != other.getStartAddress()) {
-            return getStartAddress() < other.getStartAddress() ? -1 : 1;
-        }
-
-        /* If two segments have the same start address, the rest of
-         * the fields should be equal.  Go through the motions, though.
-         * Note that we re-check the components of getStartAddress()
-         * (mStartAddress and mOffset) to make sure that all fields in
-         * an equal segment are equal.
-         */
-
-        if (mAllocationUnitSize != other.mAllocationUnitSize) {
-            return mAllocationUnitSize < other.mAllocationUnitSize ? -1 : 1;
-        }
-        if (mStartAddress != other.mStartAddress) {
-            return mStartAddress < other.mStartAddress ? -1 : 1;
-        }
-        if (mOffset != other.mOffset) {
-            return mOffset < other.mOffset ? -1 : 1;
-        }
-        if (mAllocationUnitCount != other.mAllocationUnitCount) {
-            return mAllocationUnitCount < other.mAllocationUnitCount ? -1 : 1;
-        }
-        if (mUsageData != other.mUsageData) {
-            return mUsageData.compareTo(other.mUsageData);
-        }
-        return 0;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IDevice.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IDevice.java
deleted file mode 100755
index 664b0c9..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IDevice.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.Device.DeviceState;
-import com.android.ddmlib.log.LogReceiver;
-
-import java.io.IOException;
-import java.util.Map;
-
-
-/**
- *  A Device. It can be a physical device or an emulator.
- */
-public interface IDevice {
-
-    public final static String PROP_BUILD_VERSION = "ro.build.version.release";
-    public final static String PROP_BUILD_VERSION_NUMBER = "ro.build.version.sdk";
-    public final static String PROP_DEBUGGABLE = "ro.debuggable";
-    /** Serial number of the first connected emulator. */
-    public final static String FIRST_EMULATOR_SN = "emulator-5554"; //$NON-NLS-1$
-    /** Device change bit mask: {@link DeviceState} change. */
-    public static final int CHANGE_STATE = 0x0001;
-    /** Device change bit mask: {@link Client} list change. */
-    public static final int CHANGE_CLIENT_LIST = 0x0002;
-    /** Device change bit mask: build info change. */
-    public static final int CHANGE_BUILD_INFO = 0x0004;
-
-    /**
-     * Returns the serial number of the device.
-     */
-    public String getSerialNumber();
-    
-    /**
-     * Returns the name of the AVD the emulator is running.
-     * <p/>This is only valid if {@link #isEmulator()} returns true.
-     * <p/>If the emulator is not running any AVD (for instance it's running from an Android source
-     * tree build), this method will return "<code>&lt;build&gt;</code>".
-     * @return the name of the AVD or <code>null</code> if there isn't any.
-     */
-    public String getAvdName();
-
-    /**
-     * Returns the state of the device.
-     */
-    public DeviceState getState();
-
-    /**
-     * Returns the device properties. It contains the whole output of 'getprop'
-     */
-    public Map<String, String> getProperties();
-
-    /**
-     * Returns the number of property for this device.
-     */
-    public int getPropertyCount();
-
-    /**
-     * Returns a property value.
-     * @param name the name of the value to return.
-     * @return the value or <code>null</code> if the property does not exist.
-     */
-    public String getProperty(String name);
-
-    /**
-     * Returns if the device is ready.
-     * @return <code>true</code> if {@link #getState()} returns {@link DeviceState#ONLINE}.
-     */
-    public boolean isOnline();
-
-    /**
-     * Returns <code>true</code> if the device is an emulator.
-     */
-    public boolean isEmulator();
-
-    /**
-     * Returns if the device is offline.
-     * @return <code>true</code> if {@link #getState()} returns {@link DeviceState#OFFLINE}.
-     */
-    public boolean isOffline();
-
-    /**
-     * Returns if the device is in bootloader mode.
-     * @return <code>true</code> if {@link #getState()} returns {@link DeviceState#BOOTLOADER}.
-     */
-    public boolean isBootLoader();
-
-    /**
-     * Returns whether the {@link Device} has {@link Client}s.
-     */
-    public boolean hasClients();
-
-    /**
-     * Returns the array of clients.
-     */
-    public Client[] getClients();
-
-    /**
-     * Returns a {@link Client} by its application name.
-     * @param applicationName the name of the application
-     * @return the <code>Client</code> object or <code>null</code> if no match was found.
-     */
-    public Client getClient(String applicationName);
-
-    /**
-     * Returns a {@link SyncService} object to push / pull files to and from the device.
-     * @return <code>null</code> if the SyncService couldn't be created.
-     */
-    public SyncService getSyncService();
-
-    /**
-     * Returns a {@link FileListingService} for this device.
-     */
-    public FileListingService getFileListingService();
-
-    /**
-     * Takes a screen shot of the device and returns it as a {@link RawImage}.
-     * @return the screenshot as a <code>RawImage</code> or <code>null</code> if
-     * something went wrong.
-     * @throws IOException
-     */
-    public RawImage getScreenshot() throws IOException;
-
-    /**
-     * Executes a shell command on the device, and sends the result to a receiver.
-     * @param command The command to execute
-     * @param receiver The receiver object getting the result from the command.
-     * @throws IOException
-     */
-    public void executeShellCommand(String command,
-            IShellOutputReceiver receiver) throws IOException;
-
-    /**
-     * Runs the event log service and outputs the event log to the {@link LogReceiver}.
-     * @param receiver the receiver to receive the event log entries.
-     * @throws IOException
-     */
-    public void runEventLogService(LogReceiver receiver) throws IOException;
-
-    /**
-     * Creates a port forwarding between a local and a remote port.
-     * @param localPort the local port to forward
-     * @param remotePort the remote port.
-     * @return <code>true</code> if success.
-     */
-    public boolean createForward(int localPort, int remotePort);
-
-    /**
-     * Removes a port forwarding between a local and a remote port.
-     * @param localPort the local port to forward
-     * @param remotePort the remote port.
-     * @return <code>true</code> if success.
-     */
-    public boolean removeForward(int localPort, int remotePort);
-
-    /**
-     * Returns the name of the client by pid or <code>null</code> if pid is unknown
-     * @param pid the pid of the client.
-     */
-    public String getClientName(int pid);
-
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IShellOutputReceiver.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IShellOutputReceiver.java
deleted file mode 100644
index fb671bb..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IShellOutputReceiver.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Classes which implement this interface provide methods that deal with out from a remote shell
- * command on a device/emulator.
- */
-public interface IShellOutputReceiver {
-    /**
-     * Called every time some new data is available.
-     * @param data The new data.
-     * @param offset The offset at which the new data starts.
-     * @param length The length of the new data.
-     */
-    public void addOutput(byte[] data, int offset, int length);
-
-    /**
-     * Called at the end of the process execution (unless the process was
-     * canceled). This allows the receiver to terminate and flush whatever
-     * data was not yet processed.
-     */
-    public void flush();
-
-    /**
-     * Cancel method to stop the execution of the remote shell command.
-     * @return true to cancel the execution of the command.
-     */
-    public boolean isCancelled();
-};
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IStackTraceInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IStackTraceInfo.java
deleted file mode 100644
index 3b9d730..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/IStackTraceInfo.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Classes which implement this interface provide a method that returns a stack trace.
- */
-public interface IStackTraceInfo {
-
-    /**
-     * Returns the stack trace. This can be <code>null</code>.
-     */
-    public StackTraceElement[] getStackTrace();
-
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/JdwpPacket.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/JdwpPacket.java
deleted file mode 100644
index 92bbb82..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/JdwpPacket.java
+++ /dev/null
@@ -1,371 +0,0 @@
-/* //device/tools/ddms/libs/ddmlib/src/com/android/ddmlib/JdwpPacket.java
-**
-** Copyright 2007, The Android Open Source Project
-**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
-**
-**     http://www.apache.org/licenses/LICENSE-2.0
-**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
-** limitations under the License.
-*/
-
-package com.android.ddmlib;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.nio.channels.SocketChannel;
-
-/**
- * A JDWP packet, sitting at the start of a ByteBuffer somewhere.
- *
- * This allows us to wrap a "pointer" to the data with the results of
- * decoding the packet.
- *
- * None of the operations here are synchronized.  If multiple threads will
- * be accessing the same ByteBuffers, external sync will be required.
- *
- * Use the constructor to create an empty packet, or "findPacket()" to
- * wrap a JdwpPacket around existing data.
- */
-final class JdwpPacket {
-    // header len
-    public static final int JDWP_HEADER_LEN = 11;
-
-    // results from findHandshake
-    public static final int HANDSHAKE_GOOD = 1;
-    public static final int HANDSHAKE_NOTYET = 2;
-    public static final int HANDSHAKE_BAD = 3;
-
-    // our cmdSet/cmd
-    private static final int DDMS_CMD_SET = 0xc7;       // 'G' + 128
-    private static final int DDMS_CMD = 0x01;
-
-    // "flags" field
-    private static final int REPLY_PACKET = 0x80;
-
-    // this is sent and expected at the start of a JDWP connection
-    private static final byte[] mHandshake = {
-        'J', 'D', 'W', 'P', '-', 'H', 'a', 'n', 'd', 's', 'h', 'a', 'k', 'e'
-    };
-
-    public static final int HANDSHAKE_LEN = mHandshake.length;
-
-    private ByteBuffer mBuffer;
-    private int mLength, mId, mFlags, mCmdSet, mCmd, mErrCode;
-    private boolean mIsNew;
-
-    private static int mSerialId = 0x40000000;
-
-
-    /**
-     * Create a new, empty packet, in "buf".
-     */
-    JdwpPacket(ByteBuffer buf) {
-        mBuffer = buf;
-        mIsNew = true;
-    }
-
-    /**
-     * Finish a packet created with newPacket().
-     *
-     * This always creates a command packet, with the next serial number
-     * in sequence.
-     *
-     * We have to take "payloadLength" as an argument because we can't
-     * see the position in the "slice" returned by getPayload().  We could
-     * fish it out of the chunk header, but it's legal for there to be
-     * more than one chunk in a JDWP packet.
-     *
-     * On exit, "position" points to the end of the data.
-     */
-    void finishPacket(int payloadLength) {
-        assert mIsNew;
-
-        ByteOrder oldOrder = mBuffer.order();
-        mBuffer.order(ChunkHandler.CHUNK_ORDER);
-
-        mLength = JDWP_HEADER_LEN + payloadLength;
-        mId = getNextSerial();
-        mFlags = 0;
-        mCmdSet = DDMS_CMD_SET;
-        mCmd = DDMS_CMD;
-
-        mBuffer.putInt(0x00, mLength);
-        mBuffer.putInt(0x04, mId);
-        mBuffer.put(0x08, (byte) mFlags);
-        mBuffer.put(0x09, (byte) mCmdSet);
-        mBuffer.put(0x0a, (byte) mCmd);
-
-        mBuffer.order(oldOrder);
-        mBuffer.position(mLength);
-    }
-
-    /**
-     * Get the next serial number.  This creates a unique serial number
-     * across all connections, not just for the current connection.  This
-     * is a useful property when debugging, but isn't necessary.
-     *
-     * We can't synchronize on an int, so we use a sync method.
-     */
-    private static synchronized int getNextSerial() {
-        return mSerialId++;
-    }
-
-    /**
-     * Return a slice of the byte buffer, positioned past the JDWP header
-     * to the start of the chunk header.  The buffer's limit will be set
-     * to the size of the payload if the size is known; if this is a
-     * packet under construction the limit will be set to the end of the
-     * buffer.
-     *
-     * Doesn't examine the packet at all -- works on empty buffers.
-     */
-    ByteBuffer getPayload() {
-        ByteBuffer buf;
-        int oldPosn = mBuffer.position();
-
-        mBuffer.position(JDWP_HEADER_LEN);
-        buf = mBuffer.slice();     // goes from position to limit
-        mBuffer.position(oldPosn);
-
-        if (mLength > 0)
-            buf.limit(mLength - JDWP_HEADER_LEN);
-        else
-            assert mIsNew;
-        buf.order(ChunkHandler.CHUNK_ORDER);
-        return buf;
-    }
-
-    /**
-     * Returns "true" if this JDWP packet has a JDWP command type.
-     *
-     * This never returns "true" for reply packets.
-     */
-    boolean isDdmPacket() {
-        return (mFlags & REPLY_PACKET) == 0 &&
-               mCmdSet == DDMS_CMD_SET &&
-               mCmd == DDMS_CMD;
-    }
-
-    /**
-     * Returns "true" if this JDWP packet is tagged as a reply.
-     */
-    boolean isReply() {
-        return (mFlags & REPLY_PACKET) != 0;
-    }
-
-    /**
-     * Returns "true" if this JDWP packet is a reply with a nonzero
-     * error code.
-     */
-    boolean isError() {
-        return isReply() && mErrCode != 0;
-    }
-
-    /**
-     * Returns "true" if this JDWP packet has no data.
-     */
-    boolean isEmpty() {
-        return (mLength == JDWP_HEADER_LEN);
-    }
-
-    /**
-     * Return the packet's ID.  For a reply packet, this allows us to
-     * match the reply with the original request.
-     */
-    int getId() {
-        return mId;
-    }
-
-    /**
-     * Return the length of a packet.  This includes the header, so an
-     * empty packet is 11 bytes long.
-     */
-    int getLength() {
-        return mLength;
-    }
-
-    /**
-     * Write our packet to "chan".  Consumes the packet as part of the
-     * write.
-     *
-     * The JDWP packet starts at offset 0 and ends at mBuffer.position().
-     */
-    void writeAndConsume(SocketChannel chan) throws IOException {
-        int oldLimit;
-
-        //Log.i("ddms", "writeAndConsume: pos=" + mBuffer.position()
-        //    + ", limit=" + mBuffer.limit());
-
-        assert mLength > 0;
-
-        mBuffer.flip();         // limit<-posn, posn<-0
-        oldLimit = mBuffer.limit();
-        mBuffer.limit(mLength);
-        while (mBuffer.position() != mBuffer.limit()) {
-            chan.write(mBuffer);
-        }
-        // position should now be at end of packet
-        assert mBuffer.position() == mLength;
-
-        mBuffer.limit(oldLimit);
-        mBuffer.compact();      // shift posn...limit, posn<-pending data
-
-        //Log.i("ddms", "               : pos=" + mBuffer.position()
-        //    + ", limit=" + mBuffer.limit());
-    }
-
-    /**
-     * "Move" the packet data out of the buffer we're sitting on and into
-     * buf at the current position.
-     */
-    void movePacket(ByteBuffer buf) {
-        Log.v("ddms", "moving " + mLength + " bytes");
-        int oldPosn = mBuffer.position();
-
-        mBuffer.position(0);
-        mBuffer.limit(mLength);
-        buf.put(mBuffer);
-        mBuffer.position(mLength);
-        mBuffer.limit(oldPosn);
-        mBuffer.compact();      // shift posn...limit, posn<-pending data
-    }
-
-    /**
-     * Consume the JDWP packet.
-     *
-     * On entry and exit, "position" is the #of bytes in the buffer.
-     */
-    void consume()
-    {
-        //Log.d("ddms", "consuming " + mLength + " bytes");
-        //Log.d("ddms", "  posn=" + mBuffer.position()
-        //    + ", limit=" + mBuffer.limit());
-
-        /*
-         * The "flip" call sets "limit" equal to the position (usually the
-         * end of data) and "position" equal to zero.
-         *
-         * compact() copies everything from "position" and "limit" to the
-         * start of the buffer, sets "position" to the end of data, and
-         * sets "limit" to the capacity.
-         *
-         * On entry, "position" is set to the amount of data in the buffer
-         * and "limit" is set to the capacity.  We want to call flip()
-         * so that position..limit spans our data, advance "position" past
-         * the current packet, then compact.
-         */
-        mBuffer.flip();         // limit<-posn, posn<-0
-        mBuffer.position(mLength);
-        mBuffer.compact();      // shift posn...limit, posn<-pending data
-        mLength = 0;
-        //Log.d("ddms", "  after compact, posn=" + mBuffer.position()
-        //    + ", limit=" + mBuffer.limit());
-    }
-
-    /**
-     * Find the JDWP packet at the start of "buf".  The start is known,
-     * but the length has to be parsed out.
-     *
-     * On entry, the packet data in "buf" must start at offset 0 and end
-     * at "position".  "limit" should be set to the buffer capacity.  This
-     * method does not alter "buf"s attributes.
-     *
-     * Returns a new JdwpPacket if a full one is found in the buffer.  If
-     * not, returns null.  Throws an exception if the data doesn't look like
-     * a valid JDWP packet.
-     */
-    static JdwpPacket findPacket(ByteBuffer buf) {
-        int count = buf.position();
-        int length, id, flags, cmdSet, cmd;
-
-        if (count < JDWP_HEADER_LEN)
-            return null;
-
-        ByteOrder oldOrder = buf.order();
-        buf.order(ChunkHandler.CHUNK_ORDER);
-
-        length = buf.getInt(0x00);
-        id = buf.getInt(0x04);
-        flags = buf.get(0x08) & 0xff;
-        cmdSet = buf.get(0x09) & 0xff;
-        cmd = buf.get(0x0a) & 0xff;
-
-        buf.order(oldOrder);
-
-        if (length < JDWP_HEADER_LEN)
-            throw new BadPacketException();
-        if (count < length)
-            return null;
-
-        JdwpPacket pkt = new JdwpPacket(buf);
-        //pkt.mBuffer = buf;
-        pkt.mLength = length;
-        pkt.mId = id;
-        pkt.mFlags = flags;
-
-        if ((flags & REPLY_PACKET) == 0) {
-            pkt.mCmdSet = cmdSet;
-            pkt.mCmd = cmd;
-            pkt.mErrCode = -1;
-        } else {
-            pkt.mCmdSet = -1;
-            pkt.mCmd = -1;
-            pkt.mErrCode = cmdSet | (cmd << 8);
-        }
-
-        return pkt;
-    }
-
-    /**
-     * Like findPacket(), but when we're expecting the JDWP handshake.
-     *
-     * Returns one of:
-     *   HANDSHAKE_GOOD   - found handshake, looks good
-     *   HANDSHAKE_BAD    - found enough data, but it's wrong
-     *   HANDSHAKE_NOTYET - not enough data has been read yet
-     */
-    static int findHandshake(ByteBuffer buf) {
-        int count = buf.position();
-        int i;
-
-        if (count < mHandshake.length)
-            return HANDSHAKE_NOTYET;
-
-        for (i = mHandshake.length -1; i >= 0; --i) {
-            if (buf.get(i) != mHandshake[i])
-                return HANDSHAKE_BAD;
-        }
-
-        return HANDSHAKE_GOOD;
-    }
-
-    /**
-     * Remove the handshake string from the buffer.
-     *
-     * On entry and exit, "position" is the #of bytes in the buffer.
-     */
-    static void consumeHandshake(ByteBuffer buf) {
-        // in theory, nothing else can have arrived, so this is overkill
-        buf.flip();         // limit<-posn, posn<-0
-        buf.position(mHandshake.length);
-        buf.compact();      // shift posn...limit, posn<-pending data
-    }
-
-    /**
-     * Copy the handshake string into the output buffer.
-     *
-     * On exit, "buf"s position will be advanced.
-     */
-    static void putHandshake(ByteBuffer buf) {
-        buf.put(mHandshake);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Log.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Log.java
deleted file mode 100644
index ce95b04..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/Log.java
+++ /dev/null
@@ -1,351 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.PrintWriter;
-import java.io.StringWriter;
-
-/**
- * Log class that mirrors the API in main Android sources.
- * <p/>Default behavior outputs the log to {@link System#out}. Use
- * {@link #setLogOutput(com.android.ddmlib.Log.ILogOutput)} to redirect the log somewhere else.
- */
-public final class Log {
-
-    /**
-     * Log Level enum.
-     */
-    public enum LogLevel {
-        VERBOSE(2, "verbose", 'V'), //$NON-NLS-1$
-        DEBUG(3, "debug", 'D'), //$NON-NLS-1$
-        INFO(4, "info", 'I'), //$NON-NLS-1$
-        WARN(5, "warn", 'W'), //$NON-NLS-1$
-        ERROR(6, "error", 'E'), //$NON-NLS-1$
-        ASSERT(7, "assert", 'A'); //$NON-NLS-1$
-
-        private int mPriorityLevel;
-        private String mStringValue;
-        private char mPriorityLetter;
-
-        LogLevel(int intPriority, String stringValue, char priorityChar) {
-            mPriorityLevel = intPriority;
-            mStringValue = stringValue;
-            mPriorityLetter = priorityChar;
-        }
-
-        public static LogLevel getByString(String value) {
-            for (LogLevel mode : values()) {
-                if (mode.mStringValue.equals(value)) {
-                    return mode;
-                }
-            }
-
-            return null;
-        }
-        
-        /**
-         * Returns the {@link LogLevel} enum matching the specified letter.
-         * @param letter the letter matching a <code>LogLevel</code> enum
-         * @return a <code>LogLevel</code> object or <code>null</code> if no match were found.
-         */
-        public static LogLevel getByLetter(char letter) {
-            for (LogLevel mode : values()) {
-                if (mode.mPriorityLetter == letter) {
-                    return mode;
-                }
-            }
-
-            return null;
-        }
-
-        /**
-         * Returns the {@link LogLevel} enum matching the specified letter.
-         * <p/>
-         * The letter is passed as a {@link String} argument, but only the first character
-         * is used. 
-         * @param letter the letter matching a <code>LogLevel</code> enum
-         * @return a <code>LogLevel</code> object or <code>null</code> if no match were found.
-         */
-        public static LogLevel getByLetterString(String letter) {
-            if (letter.length() > 0) {
-                return getByLetter(letter.charAt(0));
-            }
-
-            return null;
-        }
-
-        /**
-         * Returns the letter identifying the priority of the {@link LogLevel}.
-         */
-        public char getPriorityLetter() {
-            return mPriorityLetter;
-        }
-
-        /**
-         * Returns the numerical value of the priority.
-         */
-        public int getPriority() {
-            return mPriorityLevel;
-        }
-
-        /**
-         * Returns a non translated string representing the LogLevel.
-         */
-        public String getStringValue() {
-            return mStringValue;
-        }
-    }
-    
-    /**
-     * Classes which implement this interface provides methods that deal with outputting log
-     * messages.
-     */
-    public interface ILogOutput {
-        /**
-         * Sent when a log message needs to be printed.
-         * @param logLevel The {@link LogLevel} enum representing the priority of the message.
-         * @param tag The tag associated with the message.
-         * @param message The message to display.
-         */
-        public void printLog(LogLevel logLevel, String tag, String message);
-
-        /**
-         * Sent when a log message needs to be printed, and, if possible, displayed to the user
-         * in a dialog box.
-         * @param logLevel The {@link LogLevel} enum representing the priority of the message.
-         * @param tag The tag associated with the message.
-         * @param message The message to display.
-         */
-        public void printAndPromptLog(LogLevel logLevel, String tag, String message);
-    }
-
-    private static LogLevel mLevel = DdmPreferences.getLogLevel();
-
-    private static ILogOutput sLogOutput;
-
-    private static final char[] mSpaceLine = new char[72];
-    private static final char[] mHexDigit = new char[]
-        { '0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f' };
-    static {
-        /* prep for hex dump */
-        int i = mSpaceLine.length-1;
-        while (i >= 0)
-            mSpaceLine[i--] = ' ';
-        mSpaceLine[0] = mSpaceLine[1] = mSpaceLine[2] = mSpaceLine[3] = '0';
-        mSpaceLine[4] = '-';
-    }
-
-    static final class Config {
-        static final boolean LOGV = true;
-        static final boolean LOGD = true;
-    };
-
-    private Log() {}
-
-    /**
-     * Outputs a {@link LogLevel#VERBOSE} level message.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void v(String tag, String message) {
-        println(LogLevel.VERBOSE, tag, message);
-    }
-
-    /**
-     * Outputs a {@link LogLevel#DEBUG} level message.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void d(String tag, String message) {
-        println(LogLevel.DEBUG, tag, message);
-    }
-
-    /**
-     * Outputs a {@link LogLevel#INFO} level message.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void i(String tag, String message) {
-        println(LogLevel.INFO, tag, message);
-    }
-
-    /**
-     * Outputs a {@link LogLevel#WARN} level message.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void w(String tag, String message) {
-        println(LogLevel.WARN, tag, message);
-    }
-
-    /**
-     * Outputs a {@link LogLevel#ERROR} level message.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void e(String tag, String message) {
-        println(LogLevel.ERROR, tag, message);
-    }
-
-    /**
-     * Outputs a log message and attempts to display it in a dialog.
-     * @param tag The tag associated with the message.
-     * @param message The message to output.
-     */
-    public static void logAndDisplay(LogLevel logLevel, String tag, String message) {
-        if (sLogOutput != null) {
-            sLogOutput.printAndPromptLog(logLevel, tag, message);
-        } else {
-            println(logLevel, tag, message);
-        }
-    }
-
-    /**
-     * Outputs a {@link LogLevel#ERROR} level {@link Throwable} information.
-     * @param tag The tag associated with the message.
-     * @param throwable The {@link Throwable} to output.
-     */
-    public static void e(String tag, Throwable throwable) {
-        if (throwable != null) {
-            StringWriter sw = new StringWriter();
-            PrintWriter pw = new PrintWriter(sw);
-
-            throwable.printStackTrace(pw);
-            println(LogLevel.ERROR, tag, throwable.getMessage() + '\n' + sw.toString());
-        }
-    }
-
-    static void setLevel(LogLevel logLevel) {
-        mLevel = logLevel;
-    }
-
-    /**
-     * Sets the {@link ILogOutput} to use to print the logs. If not set, {@link System#out}
-     * will be used.
-     * @param logOutput The {@link ILogOutput} to use to print the log.
-     */
-    public static void setLogOutput(ILogOutput logOutput) {
-        sLogOutput = logOutput;
-    }
-
-    /**
-     * Show hex dump.
-     * <p/>
-     * Local addition.  Output looks like:
-     * 1230- 00 11 22 33 44 55 66 77 88 99 aa bb cc dd ee ff  0123456789abcdef
-     * <p/>
-     * Uses no string concatenation; creates one String object per line.
-     */
-    static void hexDump(String tag, LogLevel level, byte[] data, int offset, int length) {
-
-        int kHexOffset = 6;
-        int kAscOffset = 55;
-        char[] line = new char[mSpaceLine.length];
-        int addr, baseAddr, count;
-        int i, ch;
-        boolean needErase = true;
-
-        //Log.w(tag, "HEX DUMP: off=" + offset + ", length=" + length);
-
-        baseAddr = 0;
-        while (length != 0) {
-            if (length > 16) {
-                // full line
-                count = 16;
-            } else {
-                // partial line; re-copy blanks to clear end
-                count = length;
-                needErase = true;
-            }
-
-            if (needErase) {
-                System.arraycopy(mSpaceLine, 0, line, 0, mSpaceLine.length);
-                needErase = false;
-            }
-
-            // output the address (currently limited to 4 hex digits)
-            addr = baseAddr;
-            addr &= 0xffff;
-            ch = 3;
-            while (addr != 0) {
-                line[ch] = mHexDigit[addr & 0x0f];
-                ch--;
-                addr >>>= 4;
-            }
-
-            // output hex digits and ASCII chars
-            ch = kHexOffset;
-            for (i = 0; i < count; i++) {
-                byte val = data[offset + i];
-
-                line[ch++] = mHexDigit[(val >>> 4) & 0x0f];
-                line[ch++] = mHexDigit[val & 0x0f];
-                ch++;
-
-                if (val >= 0x20 && val < 0x7f)
-                    line[kAscOffset + i] = (char) val;
-                else
-                    line[kAscOffset + i] = '.';
-            }
-
-            println(level, tag, new String(line));
-
-            // advance to next chunk of data
-            length -= count;
-            offset += count;
-            baseAddr += count;
-        }
-
-    }
-
-    /**
-     * Dump the entire contents of a byte array with DEBUG priority.
-     */
-    static void hexDump(byte[] data) {
-        hexDump("ddms", LogLevel.DEBUG, data, 0, data.length);
-    }
-
-    /* currently prints to stdout; could write to a log window */
-    private static void println(LogLevel logLevel, String tag, String message) {
-        if (logLevel.getPriority() >= mLevel.getPriority()) {
-            if (sLogOutput != null) {
-                sLogOutput.printLog(logLevel, tag, message);
-            } else {
-                printLog(logLevel, tag, message);
-            }
-        }
-    }
-    
-    /**
-     * Prints a log message.
-     * @param logLevel
-     * @param tag
-     * @param message
-     */
-    public static void printLog(LogLevel logLevel, String tag, String message) {
-        long msec;
-        
-        msec = System.currentTimeMillis();
-        String outMessage = String.format("%02d:%02d %c/%s: %s\n",
-                (msec / 60000) % 60, (msec / 1000) % 60,
-                logLevel.getPriorityLetter(), tag, message);
-        System.out.print(outMessage);
-    }
-
-}
-
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MonitorThread.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MonitorThread.java
deleted file mode 100644
index 79eb5bb..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MonitorThread.java
+++ /dev/null
@@ -1,780 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-
-import com.android.ddmlib.DebugPortManager.IDebugPortProvider;
-import com.android.ddmlib.Log.LogLevel;
-
-import java.io.IOException;
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.nio.BufferOverflowException;
-import java.nio.ByteBuffer;
-import java.nio.channels.CancelledKeyException;
-import java.nio.channels.NotYetBoundException;
-import java.nio.channels.SelectionKey;
-import java.nio.channels.Selector;
-import java.nio.channels.ServerSocketChannel;
-import java.nio.channels.SocketChannel;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Set;
-
-/**
- * Monitor open connections.
- */
-final class MonitorThread extends Thread {
-
-    // For broadcasts to message handlers
-    //private static final int CLIENT_CONNECTED = 1;
-
-    private static final int CLIENT_READY = 2;
-
-    private static final int CLIENT_DISCONNECTED = 3;
-
-    private volatile boolean mQuit = false;
-
-    // List of clients we're paying attention to
-    private ArrayList<Client> mClientList;
-
-    // The almighty mux
-    private Selector mSelector;
-
-    // Map chunk types to handlers
-    private HashMap<Integer, ChunkHandler> mHandlerMap;
-
-    // port for "debug selected"
-    private ServerSocketChannel mDebugSelectedChan;
-
-    private int mNewDebugSelectedPort;
-
-    private int mDebugSelectedPort = -1;
-
-    /**
-     * "Selected" client setup to answer debugging connection to the mNewDebugSelectedPort port.
-     */
-    private Client mSelectedClient = null;
-
-    // singleton
-    private static MonitorThread mInstance;
-
-    /**
-     * Generic constructor.
-     */
-    private MonitorThread() {
-        super("Monitor");
-        mClientList = new ArrayList<Client>();
-        mHandlerMap = new HashMap<Integer, ChunkHandler>();
-
-        mNewDebugSelectedPort = DdmPreferences.getSelectedDebugPort();
-    }
-
-    /**
-     * Creates and return the singleton instance of the client monitor thread.
-     */
-    static MonitorThread createInstance() {
-        return mInstance = new MonitorThread();
-    }
-
-    /**
-     * Get singleton instance of the client monitor thread.
-     */
-    static MonitorThread getInstance() {
-        return mInstance;
-    }
-
-
-    /**
-     * Sets or changes the port number for "debug selected". 
-     */
-    synchronized void setDebugSelectedPort(int port) throws IllegalStateException {
-        if (mInstance == null) {
-            return;
-        }
-
-        if (AndroidDebugBridge.getClientSupport() == false) {
-            return;
-        }
-
-        if (mDebugSelectedChan != null) {
-            Log.d("ddms", "Changing debug-selected port to " + port);
-            mNewDebugSelectedPort = port;
-            wakeup();
-        } else {
-            // we set mNewDebugSelectedPort instead of mDebugSelectedPort so that it's automatically
-            // opened on the first run loop.
-            mNewDebugSelectedPort = port;
-        }
-    }
-
-    /**
-     * Sets the client to accept debugger connection on the custom "Selected debug port".
-     * @param selectedClient the client. Can be null.
-     */
-    synchronized void setSelectedClient(Client selectedClient) {
-        if (mInstance == null) {
-            return;
-        }
-
-        if (mSelectedClient != selectedClient) {
-            Client oldClient = mSelectedClient;
-            mSelectedClient = selectedClient;
-
-            if (oldClient != null) {
-                oldClient.update(Client.CHANGE_PORT);
-            }
-
-            if (mSelectedClient != null) {
-                mSelectedClient.update(Client.CHANGE_PORT);
-            }
-        }
-    }
-
-    /**
-     * Returns the client accepting debugger connection on the custom "Selected debug port".
-     */
-    Client getSelectedClient() {
-        return mSelectedClient;
-    }
-
-
-    /**
-     * Returns "true" if we want to retry connections to clients if we get a bad
-     * JDWP handshake back, "false" if we want to just mark them as bad and
-     * leave them alone.
-     */
-    boolean getRetryOnBadHandshake() {
-        return true; // TODO? make configurable
-    }
-
-    /**
-     * Get an array of known clients.
-     */
-    Client[] getClients() {
-        synchronized (mClientList) {
-            return mClientList.toArray(new Client[0]);
-        }
-    }
-
-    /**
-     * Register "handler" as the handler for type "type".
-     */
-    synchronized void registerChunkHandler(int type, ChunkHandler handler) {
-        if (mInstance == null) {
-            return;
-        }
-
-        synchronized (mHandlerMap) {
-            if (mHandlerMap.get(type) == null) {
-                mHandlerMap.put(type, handler);
-            }
-        }
-    }
-
-    /**
-     * Watch for activity from clients and debuggers.
-     */
-    @Override
-    public void run() {
-        Log.d("ddms", "Monitor is up");
-
-        // create a selector
-        try {
-            mSelector = Selector.open();
-        } catch (IOException ioe) {
-            Log.logAndDisplay(LogLevel.ERROR, "ddms",
-                    "Failed to initialize Monitor Thread: " + ioe.getMessage());
-            return;
-        }
-
-        while (!mQuit) {
-            
-            try {
-                /*
-                 * sync with new registrations: we wait until addClient is done before going through
-                 * and doing mSelector.select() again.
-                 * @see {@link #addClient(Client)}
-                 */
-                synchronized (mClientList) {
-                }
-    
-                // (re-)open the "debug selected" port, if it's not opened yet or
-                // if the port changed.
-                try {
-                    if (AndroidDebugBridge.getClientSupport()) {
-                        if ((mDebugSelectedChan == null ||
-                                mNewDebugSelectedPort != mDebugSelectedPort) &&
-                                mNewDebugSelectedPort != -1) {
-                            if (reopenDebugSelectedPort()) {
-                                mDebugSelectedPort = mNewDebugSelectedPort;
-                            }
-                        }
-                    }
-                } catch (IOException ioe) {
-                    Log.e("ddms",
-                            "Failed to reopen debug port for Selected Client to: " + mNewDebugSelectedPort);
-                    Log.e("ddms", ioe);
-                    mNewDebugSelectedPort = mDebugSelectedPort; // no retry
-                }
-    
-                int count;
-                try {
-                    count = mSelector.select();
-                } catch (IOException ioe) {
-                    ioe.printStackTrace();
-                    continue;
-                } catch (CancelledKeyException cke) {
-                    continue;
-                }
-    
-                if (count == 0) {
-                    // somebody called wakeup() ?
-                    // Log.i("ddms", "selector looping");
-                    continue;
-                }
-    
-                Set<SelectionKey> keys = mSelector.selectedKeys();
-                Iterator<SelectionKey> iter = keys.iterator();
-    
-                while (iter.hasNext()) {
-                    SelectionKey key = iter.next();
-                    iter.remove();
-    
-                    try {
-                        if (key.attachment() instanceof Client) {
-                            processClientActivity(key);
-                        }
-                        else if (key.attachment() instanceof Debugger) {
-                            processDebuggerActivity(key);
-                        }
-                        else if (key.attachment() instanceof MonitorThread) {
-                            processDebugSelectedActivity(key);
-                        }
-                        else {
-                            Log.e("ddms", "unknown activity key");
-                        }
-                    } catch (Exception e) {
-                        // we don't want to have our thread be killed because of any uncaught
-                        // exception, so we intercept all here.
-                        Log.e("ddms", "Exception during activity from Selector.");
-                        Log.e("ddms", e);
-                    }
-                }
-            } catch (Exception e) {
-                // we don't want to have our thread be killed because of any uncaught
-                // exception, so we intercept all here.
-                Log.e("ddms", "Exception MonitorThread.run()");
-                Log.e("ddms", e);
-            }
-        }
-    }
-
-
-    /**
-     * Returns the port on which the selected client listen for debugger
-     */
-    int getDebugSelectedPort() {
-        return mDebugSelectedPort;
-    }
-
-    /*
-     * Something happened. Figure out what.
-     */
-    private void processClientActivity(SelectionKey key) {
-        Client client = (Client)key.attachment();
-        
-        try {
-            if (key.isReadable() == false || key.isValid() == false) {
-                Log.d("ddms", "Invalid key from " + client + ". Dropping client.");
-                dropClient(client, true /* notify */);
-                return;
-            }
-
-            client.read();
-
-            /*
-             * See if we have a full packet in the buffer. It's possible we have
-             * more than one packet, so we have to loop.
-             */
-            JdwpPacket packet = client.getJdwpPacket();
-            while (packet != null) {
-                if (packet.isDdmPacket()) {
-                    // unsolicited DDM request - hand it off
-                    assert !packet.isReply();
-                    callHandler(client, packet, null);
-                    packet.consume();
-                } else if (packet.isReply()
-                        && client.isResponseToUs(packet.getId()) != null) {
-                    // reply to earlier DDM request
-                    ChunkHandler handler = client
-                            .isResponseToUs(packet.getId());
-                    if (packet.isError())
-                        client.packetFailed(packet);
-                    else if (packet.isEmpty())
-                        Log.d("ddms", "Got empty reply for 0x"
-                                + Integer.toHexString(packet.getId())
-                                + " from " + client);
-                    else
-                        callHandler(client, packet, handler);
-                    packet.consume();
-                    client.removeRequestId(packet.getId());
-                } else {
-                    Log.v("ddms", "Forwarding client "
-                            + (packet.isReply() ? "reply" : "event") + " 0x"
-                            + Integer.toHexString(packet.getId()) + " to "
-                            + client.getDebugger());
-                    client.forwardPacketToDebugger(packet);
-                }
-
-                // find next
-                packet = client.getJdwpPacket();
-            }
-        } catch (CancelledKeyException e) {
-            // key was canceled probably due to a disconnected client before we could
-            // read stuff coming from the client, so we drop it.
-            dropClient(client, true /* notify */);
-        } catch (IOException ex) {
-            // something closed down, no need to print anything. The client is simply dropped.
-            dropClient(client, true /* notify */);
-        } catch (Exception ex) {
-            Log.e("ddms", ex);
-
-            /* close the client; automatically un-registers from selector */
-            dropClient(client, true /* notify */);
-
-            if (ex instanceof BufferOverflowException) {
-                Log.w("ddms",
-                        "Client data packet exceeded maximum buffer size "
-                                + client);
-            } else {
-                // don't know what this is, display it
-                Log.e("ddms", ex);
-            }
-        }
-    }
-
-    /*
-     * Process an incoming DDM packet. If this is a reply to an earlier request,
-     * "handler" will be set to the handler responsible for the original
-     * request. The spec allows a JDWP message to include multiple DDM chunks.
-     */
-    private void callHandler(Client client, JdwpPacket packet,
-            ChunkHandler handler) {
-
-        // on first DDM packet received, broadcast a "ready" message
-        if (!client.ddmSeen())
-            broadcast(CLIENT_READY, client);
-
-        ByteBuffer buf = packet.getPayload();
-        int type, length;
-        boolean reply = true;
-
-        type = buf.getInt();
-        length = buf.getInt();
-
-        if (handler == null) {
-            // not a reply, figure out who wants it
-            synchronized (mHandlerMap) {
-                handler = mHandlerMap.get(type);
-                reply = false;
-            }
-        }
-
-        if (handler == null) {
-            Log.w("ddms", "Received unsupported chunk type "
-                    + ChunkHandler.name(type) + " (len=" + length + ")");
-        } else {
-            Log.d("ddms", "Calling handler for " + ChunkHandler.name(type)
-                    + " [" + handler + "] (len=" + length + ")");
-            ByteBuffer ibuf = buf.slice();
-            ByteBuffer roBuf = ibuf.asReadOnlyBuffer(); // enforce R/O
-            roBuf.order(ChunkHandler.CHUNK_ORDER);
-            // do the handling of the chunk synchronized on the client list
-            // to be sure there's no concurrency issue when we look for HOME
-            // in hasApp()
-            synchronized (mClientList) {
-                handler.handleChunk(client, type, roBuf, reply, packet.getId());
-            }
-        }
-    }
-
-    /**
-     * Drops a client from the monitor.
-     * <p/>This will lock the {@link Client} list of the {@link Device} running <var>client</var>.
-     * @param client
-     * @param notify
-     */
-    synchronized void dropClient(Client client, boolean notify) {
-        if (mInstance == null) { 
-            return;
-        }
-
-        synchronized (mClientList) {
-            if (mClientList.remove(client) == false) {
-                return;
-            }
-        }
-        client.close(notify);
-        broadcast(CLIENT_DISCONNECTED, client);
-
-        /*
-         * http://forum.java.sun.com/thread.jspa?threadID=726715&start=0
-         * http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=5073504
-         */
-        wakeup();
-    }
-
-    /*
-     * Process activity from one of the debugger sockets. This could be a new
-     * connection or a data packet.
-     */
-    private void processDebuggerActivity(SelectionKey key) {
-        Debugger dbg = (Debugger)key.attachment();
-
-        try {
-            if (key.isAcceptable()) {
-                try {
-                    acceptNewDebugger(dbg, null);
-                } catch (IOException ioe) {
-                    Log.w("ddms", "debugger accept() failed");
-                    ioe.printStackTrace();
-                }
-            } else if (key.isReadable()) {
-                processDebuggerData(key);
-            } else {
-                Log.d("ddm-debugger", "key in unknown state");
-            }
-        } catch (CancelledKeyException cke) {
-            // key has been cancelled we can ignore that.
-        }
-    }
-
-    /*
-     * Accept a new connection from a debugger. If successful, register it with
-     * the Selector.
-     */
-    private void acceptNewDebugger(Debugger dbg, ServerSocketChannel acceptChan)
-            throws IOException {
-
-        synchronized (mClientList) {
-            SocketChannel chan;
-
-            if (acceptChan == null)
-                chan = dbg.accept();
-            else
-                chan = dbg.accept(acceptChan);
-
-            if (chan != null) {
-                chan.socket().setTcpNoDelay(true);
-
-                wakeup();
-
-                try {
-                    chan.register(mSelector, SelectionKey.OP_READ, dbg);
-                } catch (IOException ioe) {
-                    // failed, drop the connection
-                    dbg.closeData();
-                    throw ioe;
-                } catch (RuntimeException re) {
-                    // failed, drop the connection
-                    dbg.closeData();
-                    throw re;
-                }
-            } else {
-                Log.i("ddms", "ignoring duplicate debugger");
-                // new connection already closed
-            }
-        }
-    }
-
-    /*
-     * We have incoming data from the debugger. Forward it to the client.
-     */
-    private void processDebuggerData(SelectionKey key) {
-        Debugger dbg = (Debugger)key.attachment();
-
-        try {
-            /*
-             * Read pending data.
-             */
-            dbg.read();
-
-            /*
-             * See if we have a full packet in the buffer. It's possible we have
-             * more than one packet, so we have to loop.
-             */
-            JdwpPacket packet = dbg.getJdwpPacket();
-            while (packet != null) {
-                Log.v("ddms", "Forwarding dbg req 0x"
-                        + Integer.toHexString(packet.getId()) + " to "
-                        + dbg.getClient());
-
-                dbg.forwardPacketToClient(packet);
-
-                packet = dbg.getJdwpPacket();
-            }
-        } catch (IOException ioe) {
-            /*
-             * Close data connection; automatically un-registers dbg from
-             * selector. The failure could be caused by the debugger going away,
-             * or by the client going away and failing to accept our data.
-             * Either way, the debugger connection does not need to exist any
-             * longer. We also need to recycle the connection to the client, so
-             * that the VM sees the debugger disconnect. For a DDM-aware client
-             * this won't be necessary, and we can just send a "debugger
-             * disconnected" message.
-             */
-            Log.i("ddms", "Closing connection to debugger " + dbg);
-            dbg.closeData();
-            Client client = dbg.getClient();
-            if (client.isDdmAware()) {
-                // TODO: soft-disconnect DDM-aware clients
-                Log.i("ddms", " (recycling client connection as well)");
-
-                // we should drop the client, but also attempt to reopen it.
-                // This is done by the DeviceMonitor.
-                client.getDevice().getMonitor().addClientToDropAndReopen(client,
-                        IDebugPortProvider.NO_STATIC_PORT);
-            } else {
-                Log.i("ddms", " (recycling client connection as well)");
-                // we should drop the client, but also attempt to reopen it.
-                // This is done by the DeviceMonitor.
-                client.getDevice().getMonitor().addClientToDropAndReopen(client,
-                        IDebugPortProvider.NO_STATIC_PORT);
-            }
-        }
-    }
-
-    /*
-     * Tell the thread that something has changed.
-     */
-    private void wakeup() {
-        mSelector.wakeup();
-    }
-
-    /**
-     * Tell the thread to stop. Called from UI thread.
-     */
-    synchronized void quit() {
-        mQuit = true;
-        wakeup();
-        Log.d("ddms", "Waiting for Monitor thread");
-        try {
-            this.join();
-            // since we're quitting, lets drop all the client and disconnect
-            // the DebugSelectedPort
-            synchronized (mClientList) {
-                for (Client c : mClientList) {
-                    c.close(false /* notify */);
-                    broadcast(CLIENT_DISCONNECTED, c);
-                }
-                mClientList.clear();
-            }
-
-            if (mDebugSelectedChan != null) {
-                mDebugSelectedChan.close();
-                mDebugSelectedChan.socket().close();
-                mDebugSelectedChan = null;
-            }
-            mSelector.close();
-        } catch (InterruptedException ie) {
-            ie.printStackTrace();
-        } catch (IOException e) {
-            // TODO Auto-generated catch block
-            e.printStackTrace();
-        }
-
-        mInstance = null;
-    }
-
-    /**
-     * Add a new Client to the list of things we monitor. Also adds the client's
-     * channel and the client's debugger listener to the selection list. This
-     * should only be called from one thread (the VMWatcherThread) to avoid a
-     * race between "alreadyOpen" and Client creation.
-     */
-    synchronized void addClient(Client client) {
-        if (mInstance == null) {
-            return;
-        }
-
-        Log.d("ddms", "Adding new client " + client);
-
-        synchronized (mClientList) {
-            mClientList.add(client);
-
-            /*
-             * Register the Client's socket channel with the selector. We attach
-             * the Client to the SelectionKey. If you try to register a new
-             * channel with the Selector while it is waiting for I/O, you will
-             * block. The solution is to call wakeup() and then hold a lock to
-             * ensure that the registration happens before the Selector goes
-             * back to sleep.
-             */
-            try {
-                wakeup();
-
-                client.register(mSelector);
-
-                Debugger dbg = client.getDebugger();
-                if (dbg != null) {
-                    dbg.registerListener(mSelector);
-                }
-            } catch (IOException ioe) {
-                // not really expecting this to happen
-                ioe.printStackTrace();
-            }
-        }
-    }
-    
-    /*
-     * Broadcast an event to all message handlers.
-     */
-    private void broadcast(int event, Client client) {
-        Log.d("ddms", "broadcast " + event + ": " + client);
-
-        /*
-         * The handler objects appear once in mHandlerMap for each message they
-         * handle. We want to notify them once each, so we convert the HashMap
-         * to a HashSet before we iterate.
-         */
-        HashSet<ChunkHandler> set;
-        synchronized (mHandlerMap) {
-            Collection<ChunkHandler> values = mHandlerMap.values();
-            set = new HashSet<ChunkHandler>(values);
-        }
-
-        Iterator<ChunkHandler> iter = set.iterator();
-        while (iter.hasNext()) {
-            ChunkHandler handler = iter.next();
-            switch (event) {
-                case CLIENT_READY:
-                    try {
-                        handler.clientReady(client);
-                    } catch (IOException ioe) {
-                        // Something failed with the client. It should
-                        // fall out of the list the next time we try to
-                        // do something with it, so we discard the
-                        // exception here and assume cleanup will happen
-                        // later. May need to propagate farther. The
-                        // trouble is that not all values for "event" may
-                        // actually throw an exception.
-                        Log.w("ddms",
-                                "Got exception while broadcasting 'ready'");
-                        return;
-                    }
-                    break;
-                case CLIENT_DISCONNECTED:
-                    handler.clientDisconnected(client);
-                    break;
-                default:
-                    throw new UnsupportedOperationException();
-            }
-        }
-
-    }
-
-    /**
-     * Opens (or reopens) the "debug selected" port and listen for connections.
-     * @return true if the port was opened successfully.
-     * @throws IOException
-     */
-    private boolean reopenDebugSelectedPort() throws IOException {
-
-        Log.d("ddms", "reopen debug-selected port: " + mNewDebugSelectedPort);
-        if (mDebugSelectedChan != null) {
-            mDebugSelectedChan.close();
-        }
-
-        mDebugSelectedChan = ServerSocketChannel.open();
-        mDebugSelectedChan.configureBlocking(false); // required for Selector
-
-        InetSocketAddress addr = new InetSocketAddress(
-                InetAddress.getByName("localhost"), //$NON-NLS-1$
-                mNewDebugSelectedPort);
-        mDebugSelectedChan.socket().setReuseAddress(true); // enable SO_REUSEADDR
-
-        try {
-            mDebugSelectedChan.socket().bind(addr);
-            if (mSelectedClient != null) {
-                mSelectedClient.update(Client.CHANGE_PORT);
-            }
-
-            mDebugSelectedChan.register(mSelector, SelectionKey.OP_ACCEPT, this);
-            
-            return true;
-        } catch (java.net.BindException e) {
-            displayDebugSelectedBindError(mNewDebugSelectedPort);
-
-            // do not attempt to reopen it.
-            mDebugSelectedChan = null;
-            mNewDebugSelectedPort = -1;
-            
-            return false;
-        }
-    }
-
-    /*
-     * We have some activity on the "debug selected" port. Handle it.
-     */
-    private void processDebugSelectedActivity(SelectionKey key) {
-        assert key.isAcceptable();
-
-        ServerSocketChannel acceptChan = (ServerSocketChannel)key.channel();
-
-        /*
-         * Find the debugger associated with the currently-selected client.
-         */
-        if (mSelectedClient != null) {
-            Debugger dbg = mSelectedClient.getDebugger();
-
-            if (dbg != null) {
-                Log.i("ddms", "Accepting connection on 'debug selected' port");
-                try {
-                    acceptNewDebugger(dbg, acceptChan);
-                } catch (IOException ioe) {
-                    // client should be gone, keep going
-                }
-
-                return;
-            }
-        }
-
-        Log.w("ddms",
-                "Connection on 'debug selected' port, but none selected");
-        try {
-            SocketChannel chan = acceptChan.accept();
-            chan.close();
-        } catch (IOException ioe) {
-            // not expected; client should be gone, keep going
-        } catch (NotYetBoundException e) {
-            displayDebugSelectedBindError(mDebugSelectedPort);
-        }
-    }
-
-    private void displayDebugSelectedBindError(int port) {
-        String message = String.format(
-                "Could not open Selected VM debug port (%1$d). Make sure you do not have another instance of DDMS or of the eclipse plugin running. If it's being used by something else, choose a new port number in the preferences.",
-                port);
-
-        Log.logAndDisplay(LogLevel.ERROR, "ddms", message);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MultiLineReceiver.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MultiLineReceiver.java
deleted file mode 100644
index 24dbb05..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/MultiLineReceiver.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.io.UnsupportedEncodingException;
-import java.util.ArrayList;
-
-/**
- * Base implementation of {@link IShellOutputReceiver}, that takes the raw data coming from the
- * socket, and convert it into {@link String} objects.
- * <p/>Additionally, it splits the string by lines.
- * <p/>Classes extending it must implement {@link #processNewLines(String[])} which receives
- * new parsed lines as they become available.
- */
-public abstract class MultiLineReceiver implements IShellOutputReceiver {
-
-    private boolean mTrimLines = true;
-
-    /** unfinished message line, stored for next packet */
-    private String mUnfinishedLine = null;
-
-    private final ArrayList<String> mArray = new ArrayList<String>();
-
-    /**
-     * Set the trim lines flag.
-     * @param trim hether the lines are trimmed, or not.
-     */
-    public void setTrimLine(boolean trim) {
-        mTrimLines = trim;
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmlib.adb.IShellOutputReceiver#addOutput(
-     *      byte[], int, int)
-     */
-    public final void addOutput(byte[] data, int offset, int length) {
-        if (isCancelled() == false) {
-            String s = null;
-            try {
-                s = new String(data, offset, length, "ISO-8859-1"); //$NON-NLS-1$
-            } catch (UnsupportedEncodingException e) {
-                // normal encoding didn't work, try the default one
-                s = new String(data, offset,length);
-            }
-
-            // ok we've got a string
-            if (s != null) {
-                // if we had an unfinished line we add it.
-                if (mUnfinishedLine != null) {
-                    s = mUnfinishedLine + s;
-                    mUnfinishedLine = null;
-                }
-
-                // now we split the lines
-                mArray.clear();
-                int start = 0;
-                do {
-                    int index = s.indexOf("\r\n", start); //$NON-NLS-1$
-
-                    // if \r\n was not found, this is an unfinished line
-                    // and we store it to be processed for the next packet
-                    if (index == -1) {
-                        mUnfinishedLine = s.substring(start);
-                        break;
-                    }
-
-                    // so we found a \r\n;
-                    // extract the line
-                    String line = s.substring(start, index);
-                    if (mTrimLines) {
-                        line = line.trim();
-                    }
-                    mArray.add(line);
-
-                    // move start to after the \r\n we found
-                    start = index + 2;
-                } while (true);
-
-                if (mArray.size() > 0) {
-                    // at this point we've split all the lines.
-                    // make the array
-                    String[] lines = mArray.toArray(new String[mArray.size()]);
-
-                    // send it for final processing
-                    processNewLines(lines);
-                }
-            }
-        }
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmlib.adb.IShellOutputReceiver#flush()
-     */
-    public final void flush() {
-        if (mUnfinishedLine != null) {
-            processNewLines(new String[] { mUnfinishedLine });
-        }
-
-        done();
-    }
-
-    /**
-     * Terminates the process. This is called after the last lines have been through
-     * {@link #processNewLines(String[])}.
-     */
-    public void done() {
-        // do nothing.
-    }
-
-    /**
-     * Called when new lines are being received by the remote process.
-     * <p/>It is guaranteed that the lines are complete when they are given to this method.
-     * @param lines The array containing the new lines.
-     */
-    public abstract void processNewLines(String[] lines);
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeAllocationInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeAllocationInfo.java
deleted file mode 100644
index 956b004..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeAllocationInfo.java
+++ /dev/null
@@ -1,277 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * Stores native allocation information.
- * <p/>Contains number of allocations, their size and the stack trace.
- * <p/>Note: the ddmlib does not resolve the stack trace automatically. While this class provides
- * storage for resolved stack trace, this is merely for convenience.
- */
-public final class NativeAllocationInfo {
-    /* constants for flag bits */
-    private static final int FLAG_ZYGOTE_CHILD  = (1<<31);
-    private static final int FLAG_MASK          = (FLAG_ZYGOTE_CHILD);
-
-    /**
-     * list of alloc functions that are filtered out when attempting to display
-     * a relevant method responsible for an allocation
-     */
-    private static ArrayList<String> sAllocFunctionFilter;
-    static {
-        sAllocFunctionFilter = new ArrayList<String>();
-        sAllocFunctionFilter.add("malloc"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("calloc"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("realloc"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("get_backtrace"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("get_hash"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("??"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("internal_free"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("operator new"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("leak_free"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("chk_free"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("chk_memalign"); //$NON-NLS-1$
-        sAllocFunctionFilter.add("Malloc"); //$NON-NLS-1$
-    }
-
-    private final int mSize;
-
-    private final boolean mIsZygoteChild;
-
-    private final int mAllocations;
-
-    private final ArrayList<Long> mStackCallAddresses = new ArrayList<Long>();
-
-    private ArrayList<NativeStackCallInfo> mResolvedStackCall = null;
-
-    private boolean mIsStackCallResolved = false;
-
-    /**
-     * Constructs a new {@link NativeAllocationInfo}.
-     * @param size The size of the allocations.
-     * @param allocations the allocation count
-     */
-    NativeAllocationInfo(int size, int allocations) {
-        this.mSize = size & ~FLAG_MASK;
-        this.mIsZygoteChild = ((size & FLAG_ZYGOTE_CHILD) != 0);
-        this.mAllocations = allocations;
-    }
-    
-    /**
-     * Adds a stack call address for this allocation.
-     * @param address The address to add.
-     */
-    void addStackCallAddress(long address) {
-        mStackCallAddresses.add(address);
-    }
-    
-    /**
-     * Returns the total size of this allocation.
-     */
-    public int getSize() {
-        return mSize;
-    }
-
-    /**
-     * Returns whether the allocation happened in a child of the zygote
-     * process.
-     */
-    public boolean isZygoteChild() {
-        return mIsZygoteChild;
-    }
-
-    /**
-     * Returns the allocation count.
-     */
-    public int getAllocationCount() {
-        return mAllocations;
-    }
-    
-    /**
-     * Returns whether the stack call addresses have been resolved into
-     * {@link NativeStackCallInfo} objects.
-     */
-    public boolean isStackCallResolved() {
-        return mIsStackCallResolved;
-    }
-
-    /**
-     * Returns the stack call of this allocation as raw addresses.
-     * @return the list of addresses where the allocation happened.
-     */
-    public Long[] getStackCallAddresses() {
-        return mStackCallAddresses.toArray(new Long[mStackCallAddresses.size()]);
-    }
-    
-    /**
-     * Sets the resolved stack call for this allocation.
-     * <p/>
-     * If <code>resolvedStackCall</code> is non <code>null</code> then
-     * {@link #isStackCallResolved()} will return <code>true</code> after this call.
-     * @param resolvedStackCall The list of {@link NativeStackCallInfo}.
-     */
-    public synchronized void setResolvedStackCall(List<NativeStackCallInfo> resolvedStackCall) {
-        if (mResolvedStackCall == null) {
-            mResolvedStackCall = new ArrayList<NativeStackCallInfo>();
-        } else {
-            mResolvedStackCall.clear();
-        }
-        mResolvedStackCall.addAll(resolvedStackCall);
-        mIsStackCallResolved = mResolvedStackCall.size() != 0;
-    }
-
-    /**
-     * Returns the resolved stack call.
-     * @return An array of {@link NativeStackCallInfo} or <code>null</code> if the stack call
-     * was not resolved.
-     * @see #setResolvedStackCall(ArrayList)
-     * @see #isStackCallResolved()
-     */
-    public synchronized NativeStackCallInfo[] getResolvedStackCall() {
-        if (mIsStackCallResolved) {
-            return mResolvedStackCall.toArray(new NativeStackCallInfo[mResolvedStackCall.size()]);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Indicates whether some other object is "equal to" this one.
-     * @param obj the reference object with which to compare.
-     * @return <code>true</code> if this object is equal to the obj argument;
-     * <code>false</code> otherwise.
-     * @see java.lang.Object#equals(java.lang.Object)
-     */
-    @Override
-    public boolean equals(Object obj) {
-        if (obj == this)
-            return true;
-        if (obj instanceof NativeAllocationInfo) {
-            NativeAllocationInfo mi = (NativeAllocationInfo)obj;
-            // quick compare of size, alloc, and stackcall size
-            if (mSize != mi.mSize || mAllocations != mi.mAllocations ||
-                    mStackCallAddresses.size() != mi.mStackCallAddresses.size()) {
-                return false;
-            }
-            // compare the stack addresses
-            int count = mStackCallAddresses.size();
-            for (int i = 0 ; i < count ; i++) {
-                long a = mStackCallAddresses.get(i);
-                long b = mi.mStackCallAddresses.get(i);
-                if (a != b) {
-                    return false;
-                }
-            }
-
-            return true;
-        }
-        return false;
-    }
-
-    /**
-     * Returns a string representation of the object.
-     * @see java.lang.Object#toString()
-     */
-    @Override
-    public String toString() {
-        StringBuffer buffer = new StringBuffer();
-        buffer.append("Allocations: ");
-        buffer.append(mAllocations);
-        buffer.append("\n"); //$NON-NLS-1$
-
-        buffer.append("Size: ");
-        buffer.append(mSize);
-        buffer.append("\n"); //$NON-NLS-1$
-
-        buffer.append("Total Size: ");
-        buffer.append(mSize * mAllocations);
-        buffer.append("\n"); //$NON-NLS-1$
-
-        Iterator<Long> addrIterator = mStackCallAddresses.iterator();
-        Iterator<NativeStackCallInfo> sourceIterator = mResolvedStackCall.iterator();
-
-        while (sourceIterator.hasNext()) {
-            long addr = addrIterator.next();
-            NativeStackCallInfo source = sourceIterator.next();
-            if (addr == 0)
-                continue;
-
-            if (source.getLineNumber() != -1) {
-                buffer.append(String.format("\t%1$08x\t%2$s --- %3$s --- %4$s:%5$d\n", addr,
-                        source.getLibraryName(), source.getMethodName(),
-                        source.getSourceFile(), source.getLineNumber()));
-            } else {
-                buffer.append(String.format("\t%1$08x\t%2$s --- %3$s --- %4$s\n", addr,
-                        source.getLibraryName(), source.getMethodName(), source.getSourceFile()));
-            }
-        }
-
-        return buffer.toString();
-    }
-
-    /**
-     * Returns the first {@link NativeStackCallInfo} that is relevant.
-     * <p/>
-     * A relevant <code>NativeStackCallInfo</code> is a stack call that is not deep in the
-     * lower level of the libc, but the actual method that performed the allocation. 
-     * @return a <code>NativeStackCallInfo</code> or <code>null</code> if the stack call has not
-     * been processed from the raw addresses.
-     * @see #setResolvedStackCall(ArrayList)
-     * @see #isStackCallResolved()
-     */
-    public synchronized NativeStackCallInfo getRelevantStackCallInfo() {
-        if (mIsStackCallResolved && mResolvedStackCall != null) {
-            Iterator<NativeStackCallInfo> sourceIterator = mResolvedStackCall.iterator();
-            Iterator<Long> addrIterator = mStackCallAddresses.iterator();
-
-            while (sourceIterator.hasNext() && addrIterator.hasNext()) {
-                long addr = addrIterator.next();
-                NativeStackCallInfo info = sourceIterator.next();
-                if (addr != 0 && info != null) {
-                    if (isRelevant(info.getMethodName())) {
-                        return info;
-                    }
-                }
-            }
-
-            // couldnt find a relevant one, so we'll return the first one if it
-            // exists.
-            if (mResolvedStackCall.size() > 0)
-                return mResolvedStackCall.get(0);
-        }
-
-        return null;
-    }
-    
-    /**
-     * Returns true if the method name is relevant.
-     * @param methodName the method name to test.
-     */
-    private boolean isRelevant(String methodName) {
-        for (String filter : sAllocFunctionFilter) {
-            if (methodName.contains(filter)) {
-                return false;
-            }
-        }
-        
-        return true;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeLibraryMapInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeLibraryMapInfo.java
deleted file mode 100644
index 5a26317..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeLibraryMapInfo.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Memory address to library mapping for native libraries.
- * <p/>
- * Each instance represents a single native library and its start and end memory addresses. 
- */
-public final class NativeLibraryMapInfo {
-    private long mStartAddr;
-    private long mEndAddr;
-
-    private String mLibrary;
-
-    /**
-     * Constructs a new native library map info.
-     * @param startAddr The start address of the library.
-     * @param endAddr The end address of the library.
-     * @param library The name of the library.
-     */
-    NativeLibraryMapInfo(long startAddr, long endAddr, String library) {
-        this.mStartAddr = startAddr;
-        this.mEndAddr = endAddr;
-        this.mLibrary = library;
-    }
-    
-    /**
-     * Returns the name of the library.
-     */
-    public String getLibraryName() {
-        return mLibrary;
-    }
-    
-    /**
-     * Returns the start address of the library.
-     */
-    public long getStartAddress() {
-        return mStartAddr;
-    }
-    
-    /**
-     * Returns the end address of the library.
-     */
-    public long getEndAddress() {
-        return mEndAddr;
-    }
-
-    /**
-     * Returns whether the specified address is inside the library.
-     * @param address The address to test.
-     * @return <code>true</code> if the address is between the start and end address of the library.
-     * @see #getStartAddress()
-     * @see #getEndAddress()
-     */
-    public boolean isWithinLibrary(long address) {
-        return address >= mStartAddr && address <= mEndAddr;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeStackCallInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeStackCallInfo.java
deleted file mode 100644
index e54818d..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NativeStackCallInfo.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Represents a stack call. This is used to return all of the call
- * information as one object.
- */
-public final class NativeStackCallInfo {
-    private final static Pattern SOURCE_NAME_PATTERN = Pattern.compile("^(.+):(\\d+)$");
-    
-    /** name of the library */
-    private String mLibrary;
-
-    /** name of the method */
-    private String mMethod;
-
-    /**
-     * name of the source file + line number in the format<br>
-     * &lt;sourcefile&gt;:&lt;linenumber&gt;
-     */
-    private String mSourceFile;
-    
-    private int mLineNumber = -1; 
-
-    /**
-     * Basic constructor with library, method, and sourcefile information
-     *
-     * @param lib The name of the library
-     * @param method the name of the method
-     * @param sourceFile the name of the source file and the line number
-     * as "[sourcefile]:[fileNumber]"
-     */
-    public NativeStackCallInfo(String lib, String method, String sourceFile) {
-        mLibrary = lib;
-        mMethod = method;
-        
-        Matcher m = SOURCE_NAME_PATTERN.matcher(sourceFile);
-        if (m.matches()) {
-            mSourceFile = m.group(1);
-            try {
-                mLineNumber = Integer.parseInt(m.group(2));
-            } catch (NumberFormatException e) {
-                // do nothing, the line number will stay at -1
-            }
-        } else {
-            mSourceFile = sourceFile;
-        }
-    }
-    
-    /**
-     * Returns the name of the library name.
-     */
-    public String getLibraryName() {
-        return mLibrary;
-    }
-
-    /** 
-     * Returns the name of the method.
-     */
-    public String getMethodName() {
-        return mMethod;
-    }
-    
-    /**
-     * Returns the name of the source file.
-     */
-    public String getSourceFile() {
-        return mSourceFile;
-    }
-
-    /**
-     * Returns the line number, or -1 if unknown.
-     */
-    public int getLineNumber() {
-        return mLineNumber;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NullOutputReceiver.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NullOutputReceiver.java
deleted file mode 100644
index d2b5a1e..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/NullOutputReceiver.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Implementation of {@link IShellOutputReceiver} that does nothing.
- * <p/>This can be used to execute a remote shell command when the output is not needed.
- */
-public final class NullOutputReceiver implements IShellOutputReceiver {
-
-    private static NullOutputReceiver sReceiver = new NullOutputReceiver();
-
-    public static IShellOutputReceiver getReceiver() {
-        return sReceiver;
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmlib.adb.IShellOutputReceiver#addOutput(byte[], int, int)
-     */
-    public void addOutput(byte[] data, int offset, int length) {
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmlib.adb.IShellOutputReceiver#flush()
-     */
-    public void flush() {
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmlib.adb.IShellOutputReceiver#isCancelled()
-     */
-    public boolean isCancelled() {
-        return false;
-    }
-
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/RawImage.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/RawImage.java
deleted file mode 100644
index 610cb59..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/RawImage.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Data representing an image taken from a device frame buffer.
- */
-public final class RawImage {
-    /**
-     * bit-per-pixel value.
-     */
-    public int bpp;
-    public int size;
-    public int width;
-    public int height;
-
-    public byte[] data;
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/SyncService.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/SyncService.java
deleted file mode 100644
index 44df000..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/SyncService.java
+++ /dev/null
@@ -1,949 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-import com.android.ddmlib.AdbHelper.AdbResponse;
-import com.android.ddmlib.FileListingService.FileEntry;
-import com.android.ddmlib.utils.ArrayHelper;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.InetSocketAddress;
-import java.nio.channels.SocketChannel;
-import java.util.ArrayList;
-
-/**
- * Sync service class to push/pull to/from devices/emulators, through the debug bridge.
- * <p/>
- * To get a {@link SyncService} object, use {@link Device#getSyncService()}.
- */
-public final class SyncService {
-
-    private final static byte[] ID_OKAY = { 'O', 'K', 'A', 'Y' };
-    private final static byte[] ID_FAIL = { 'F', 'A', 'I', 'L' };
-    private final static byte[] ID_STAT = { 'S', 'T', 'A', 'T' };
-    private final static byte[] ID_RECV = { 'R', 'E', 'C', 'V' };
-    private final static byte[] ID_DATA = { 'D', 'A', 'T', 'A' };
-    private final static byte[] ID_DONE = { 'D', 'O', 'N', 'E' };
-    private final static byte[] ID_SEND = { 'S', 'E', 'N', 'D' };
-//    private final static byte[] ID_LIST = { 'L', 'I', 'S', 'T' };
-//    private final static byte[] ID_DENT = { 'D', 'E', 'N', 'T' };
-
-    private final static NullSyncProgresMonitor sNullSyncProgressMonitor =
-            new NullSyncProgresMonitor();
-
-    private final static int S_ISOCK = 0xC000; // type: symbolic link
-    private final static int S_IFLNK = 0xA000; // type: symbolic link
-    private final static int S_IFREG = 0x8000; // type: regular file
-    private final static int S_IFBLK = 0x6000; // type: block device
-    private final static int S_IFDIR = 0x4000; // type: directory
-    private final static int S_IFCHR = 0x2000; // type: character device
-    private final static int S_IFIFO = 0x1000; // type: fifo
-/*
-    private final static int S_ISUID = 0x0800; // set-uid bit
-    private final static int S_ISGID = 0x0400; // set-gid bit
-    private final static int S_ISVTX = 0x0200; // sticky bit
-    private final static int S_IRWXU = 0x01C0; // user permissions
-    private final static int S_IRUSR = 0x0100; // user: read
-    private final static int S_IWUSR = 0x0080; // user: write
-    private final static int S_IXUSR = 0x0040; // user: execute
-    private final static int S_IRWXG = 0x0038; // group permissions
-    private final static int S_IRGRP = 0x0020; // group: read
-    private final static int S_IWGRP = 0x0010; // group: write
-    private final static int S_IXGRP = 0x0008; // group: execute
-    private final static int S_IRWXO = 0x0007; // other permissions
-    private final static int S_IROTH = 0x0004; // other: read
-    private final static int S_IWOTH = 0x0002; // other: write
-    private final static int S_IXOTH = 0x0001; // other: execute
-*/
-
-    private final static int SYNC_DATA_MAX = 64*1024;
-    private final static int REMOTE_PATH_MAX_LENGTH = 1024;
-
-    /** Result code for transfer success. */
-    public static final int RESULT_OK = 0;
-    /** Result code for canceled transfer */
-    public static final int RESULT_CANCELED = 1;
-    /** Result code for unknown error */
-    public static final int RESULT_UNKNOWN_ERROR = 2;
-    /** Result code for network connection error */
-    public static final int RESULT_CONNECTION_ERROR = 3;
-    /** Result code for unknown remote object during a pull */
-    public static final int RESULT_NO_REMOTE_OBJECT = 4;
-    /** Result code when attempting to pull multiple files into a file */
-    public static final int RESULT_TARGET_IS_FILE = 5;
-    /** Result code when attempting to pull multiple into a directory that does not exist. */
-    public static final int RESULT_NO_DIR_TARGET = 6;
-    /** Result code for wrong encoding on the remote path. */
-    public static final int RESULT_REMOTE_PATH_ENCODING = 7;
-    /** Result code for remote path that is too long. */
-    public static final int RESULT_REMOTE_PATH_LENGTH = 8;
-    /** Result code for error while writing local file. */
-    public static final int RESULT_FILE_WRITE_ERROR = 9;
-    /** Result code for error while reading local file. */
-    public static final int RESULT_FILE_READ_ERROR = 10;
-    /** Result code for attempting to push a file that does not exist. */
-    public static final int RESULT_NO_LOCAL_FILE = 11;
-    /** Result code for attempting to push a directory. */
-    public static final int RESULT_LOCAL_IS_DIRECTORY = 12;
-    /** Result code for when the target path of a multi file push is a file. */
-    public static final int RESULT_REMOTE_IS_FILE = 13;
-    /** Result code for receiving too much data from the remove device at once */
-    public static final int RESULT_BUFFER_OVERRUN = 14;
-
-    /**
-     * A file transfer result.
-     * <p/>
-     * This contains a code, and an optional string
-     */
-    public static class SyncResult {
-        private int mCode;
-        private String mMessage;
-        SyncResult(int code, String message) {
-            mCode = code;
-            mMessage = message;
-        }
-
-        SyncResult(int code, Exception e) {
-            this(code, e.getMessage());
-        }
-
-        SyncResult(int code) {
-            this(code, errorCodeToString(code));
-        }
-
-        public int getCode() {
-            return mCode;
-        }
-
-        public String getMessage() {
-            return mMessage;
-        }
-    }
-
-    /**
-     * Classes which implement this interface provide methods that deal
-     * with displaying transfer progress.
-     */
-    public interface ISyncProgressMonitor {
-        /**
-         * Sent when the transfer starts
-         * @param totalWork the total amount of work.
-         */
-        public void start(int totalWork);
-        /**
-         * Sent when the transfer is finished or interrupted.
-         */
-        public void stop();
-        /**
-         * Sent to query for possible cancellation.
-         * @return true if the transfer should be stopped.
-         */
-        public boolean isCanceled();
-        /**
-         * Sent when a sub task is started.
-         * @param name the name of the sub task.
-         */
-        public void startSubTask(String name);
-        /**
-         * Sent when some progress have been made.
-         * @param work the amount of work done.
-         */
-        public void advance(int work);
-    }
-
-    /**
-     * A Sync progress monitor that does nothing
-     */
-    private static class NullSyncProgresMonitor implements ISyncProgressMonitor {
-        public void advance(int work) {
-        }
-        public boolean isCanceled() {
-            return false;
-        }
-
-        public void start(int totalWork) {
-        }
-        public void startSubTask(String name) {
-        }
-        public void stop() {
-        }
-    }
-
-    private InetSocketAddress mAddress;
-    private Device mDevice;
-    private SocketChannel mChannel;
-
-    /**
-     * Buffer used to send data. Allocated when needed and reused afterward.
-     */
-    private byte[] mBuffer;
-
-    /**
-     * Creates a Sync service object.
-     * @param address The address to connect to
-     * @param device the {@link Device} that the service connects to.
-     */
-    SyncService(InetSocketAddress address, Device device) {
-        mAddress = address;
-        mDevice = device;
-    }
-
-    /**
-     * Opens the sync connection. This must be called before any calls to push[File] / pull[File].
-     * @return true if the connection opened, false otherwise.
-     */
-    boolean openSync() {
-        try {
-            mChannel = SocketChannel.open(mAddress);
-            mChannel.configureBlocking(false);
-
-            // target a specific device
-            AdbHelper.setDevice(mChannel, mDevice);
-
-            byte[] request = AdbHelper.formAdbRequest("sync:"); // $NON-NLS-1$
-            AdbHelper.write(mChannel, request, -1, AdbHelper.STD_TIMEOUT);
-
-            AdbResponse resp = AdbHelper.readAdbResponse(mChannel, false /* readDiagString */);
-
-            if (!resp.ioSuccess || !resp.okay) {
-                Log.w("ddms",
-                        "Got timeout or unhappy response from ADB sync req: "
-                        + resp.message);
-                mChannel.close();
-                mChannel = null;
-                return false;
-            }
-        } catch (IOException e) {
-            if (mChannel != null) {
-                try {
-                    mChannel.close();
-                } catch (IOException e1) {
-                    // we do nothing, since we'll return false just below
-                }
-                mChannel = null;
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /**
-     * Closes the connection.
-     */
-    public void close() {
-        if (mChannel != null) {
-            try {
-                mChannel.close();
-            } catch (IOException e) {
-                // nothing to be done really...
-            }
-            mChannel = null;
-        }
-    }
-
-    /**
-     * Returns a sync progress monitor that does nothing. This allows background tasks that don't
-     * want/need to display ui, to pass a valid {@link ISyncProgressMonitor}.
-     * <p/>This object can be reused multiple times and can be used by concurrent threads.
-     */
-    public static ISyncProgressMonitor getNullProgressMonitor() {
-        return sNullSyncProgressMonitor;
-    }
-
-    /**
-     * Converts an error code into a non-localized string
-     * @param code the error code;
-     */
-    private static String errorCodeToString(int code) {
-        switch (code) {
-            case RESULT_OK:
-                return "Success.";
-            case RESULT_CANCELED:
-                return "Tranfert canceled by the user.";
-            case RESULT_UNKNOWN_ERROR:
-                return "Unknown Error.";
-            case RESULT_CONNECTION_ERROR:
-                return "Adb Connection Error.";
-            case RESULT_NO_REMOTE_OBJECT:
-                return "Remote object doesn't exist!";
-            case RESULT_TARGET_IS_FILE:
-                return "Target object is a file.";
-            case RESULT_NO_DIR_TARGET:
-                return "Target directory doesn't exist.";
-            case RESULT_REMOTE_PATH_ENCODING:
-                return "Remote Path encoding is not supported.";
-            case RESULT_REMOTE_PATH_LENGTH:
-                return "Remove path is too long.";
-            case RESULT_FILE_WRITE_ERROR:
-                return "Writing local file failed!";
-            case RESULT_FILE_READ_ERROR:
-                return "Reading local file failed!";
-            case RESULT_NO_LOCAL_FILE:
-                return "Local file doesn't exist.";
-            case RESULT_LOCAL_IS_DIRECTORY:
-                return "Local path is a directory.";
-            case RESULT_REMOTE_IS_FILE:
-                return "Remote path is a file.";
-            case RESULT_BUFFER_OVERRUN:
-                return "Receiving too much data.";
-        }
-
-        throw new RuntimeException();
-    }
-
-    /**
-     * Pulls file(s) or folder(s).
-     * @param entries the remote item(s) to pull
-     * @param localPath The local destination. If the entries count is > 1 or
-     *      if the unique entry is a folder, this should be a folder.
-     * @param monitor The progress monitor. Cannot be null.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     *
-     * @see FileListingService.FileEntry
-     * @see #getNullProgressMonitor()
-     */
-    public SyncResult pull(FileEntry[] entries, String localPath, ISyncProgressMonitor monitor) {
-
-        // first we check the destination is a directory and exists
-        File f = new File(localPath);
-        if (f.exists() == false) {
-            return new SyncResult(RESULT_NO_DIR_TARGET);
-        }
-        if (f.isDirectory() == false) {
-            return new SyncResult(RESULT_TARGET_IS_FILE);
-        }
-
-        // get a FileListingService object
-        FileListingService fls = new FileListingService(mDevice);
-
-        // compute the number of file to move
-        int total = getTotalRemoteFileSize(entries, fls);
-
-        // start the monitor
-        monitor.start(total);
-
-        SyncResult result = doPull(entries, localPath, fls, monitor);
-
-        monitor.stop();
-
-        return result;
-    }
-
-    /**
-     * Pulls a single file.
-     * @param remote the remote file
-     * @param localFilename The local destination.
-     * @param monitor The progress monitor. Cannot be null.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     *
-     * @see FileListingService.FileEntry
-     * @see #getNullProgressMonitor()
-     */
-    public SyncResult pullFile(FileEntry remote, String localFilename,
-            ISyncProgressMonitor monitor) {
-        int total = remote.getSizeValue();
-        monitor.start(total);
-
-        SyncResult result = doPullFile(remote.getFullPath(), localFilename, monitor);
-
-        monitor.stop();
-        return result;
-    }
-
-    /**
-     * Push several files.
-     * @param local An array of loca files to push
-     * @param remote the remote {@link FileEntry} representing a directory.
-     * @param monitor The progress monitor. Cannot be null.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    public SyncResult push(String[] local, FileEntry remote, ISyncProgressMonitor monitor) {
-        if (remote.isDirectory() == false) {
-            return new SyncResult(RESULT_REMOTE_IS_FILE);
-        }
-
-        // make a list of File from the list of String
-        ArrayList<File> files = new ArrayList<File>();
-        for (String path : local) {
-            files.add(new File(path));
-        }
-
-        // get the total count of the bytes to transfer
-        File[] fileArray = files.toArray(new File[files.size()]);
-        int total = getTotalLocalFileSize(fileArray);
-
-        monitor.start(total);
-
-        SyncResult result = doPush(fileArray, remote.getFullPath(), monitor);
-
-        monitor.stop();
-
-        return result;
-    }
-
-    /**
-     * Push a single file.
-     * @param local the local filepath.
-     * @param remote The remote filepath.
-     * @param monitor The progress monitor. Cannot be null.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    public SyncResult pushFile(String local, String remote, ISyncProgressMonitor monitor) {
-        File f = new File(local);
-        if (f.exists() == false) {
-            return new SyncResult(RESULT_NO_LOCAL_FILE);
-        }
-
-        if (f.isDirectory()) {
-            return new SyncResult(RESULT_LOCAL_IS_DIRECTORY);
-        }
-
-        monitor.start((int)f.length());
-
-        SyncResult result = doPushFile(local, remote, monitor);
-
-        monitor.stop();
-
-        return result;
-    }
-
-    /**
-     * compute the recursive file size of all the files in the list. Folder
-     * have a weight of 1.
-     * @param entries
-     * @param fls
-     * @return
-     */
-    private int getTotalRemoteFileSize(FileEntry[] entries, FileListingService fls) {
-        int count = 0;
-        for (FileEntry e : entries) {
-            int type = e.getType();
-            if (type == FileListingService.TYPE_DIRECTORY) {
-                // get the children
-                FileEntry[] children = fls.getChildren(e, false, null);
-                count += getTotalRemoteFileSize(children, fls) + 1;
-            } else if (type == FileListingService.TYPE_FILE) {
-                count += e.getSizeValue();
-            }
-        }
-
-        return count;
-    }
-
-    /**
-     * compute the recursive file size of all the files in the list. Folder
-     * have a weight of 1.
-     * This does not check for circular links.
-     * @param files
-     * @return
-     */
-    private int getTotalLocalFileSize(File[] files) {
-        int count = 0;
-
-        for (File f : files) {
-            if (f.exists()) {
-                if (f.isDirectory()) {
-                    return getTotalLocalFileSize(f.listFiles()) + 1;
-                } else if (f.isFile()) {
-                    count += f.length();
-                }
-            }
-        }
-
-        return count;
-    }
-
-    /**
-     * Pulls multiple files/folders recursively.
-     * @param entries The list of entry to pull
-     * @param localPath the localpath to a directory
-     * @param fileListingService a FileListingService object to browse through remote directories.
-     * @param monitor the progress monitor. Must be started already.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    private SyncResult doPull(FileEntry[] entries, String localPath,
-            FileListingService fileListingService,
-            ISyncProgressMonitor monitor) {
-
-        for (FileEntry e : entries) {
-            // check if we're cancelled
-            if (monitor.isCanceled() == true) {
-                return new SyncResult(RESULT_CANCELED);
-            }
-
-            // get type (we only pull directory and files for now)
-            int type = e.getType();
-            if (type == FileListingService.TYPE_DIRECTORY) {
-                monitor.startSubTask(e.getFullPath());
-                String dest = localPath + File.separator + e.getName();
-
-                // make the directory
-                File d = new File(dest);
-                d.mkdir();
-
-                // then recursively call the content. Since we did a ls command
-                // to get the number of files, we can use the cache
-                FileEntry[] children = fileListingService.getChildren(e, true, null);
-                SyncResult result = doPull(children, dest, fileListingService, monitor);
-                if (result.mCode != RESULT_OK) {
-                    return result;
-                }
-                monitor.advance(1);
-            } else if (type == FileListingService.TYPE_FILE) {
-                monitor.startSubTask(e.getFullPath());
-                String dest = localPath + File.separator + e.getName();
-                SyncResult result = doPullFile(e.getFullPath(), dest, monitor);
-                if (result.mCode != RESULT_OK) {
-                    return result;
-                }
-            }
-        }
-
-        return new SyncResult(RESULT_OK);
-    }
-
-    /**
-     * Pulls a remote file
-     * @param remotePath the remote file (length max is 1024)
-     * @param localPath the local destination
-     * @param monitor the monitor. The monitor must be started already.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    private SyncResult doPullFile(String remotePath, String localPath,
-            ISyncProgressMonitor monitor) {
-        byte[] msg = null;
-        byte[] pullResult = new byte[8];
-        try {
-            byte[] remotePathContent = remotePath.getBytes(AdbHelper.DEFAULT_ENCODING);
-
-            if (remotePathContent.length > REMOTE_PATH_MAX_LENGTH) {
-                return new SyncResult(RESULT_REMOTE_PATH_LENGTH);
-            }
-
-            // create the full request message
-            msg = createFileReq(ID_RECV, remotePathContent);
-
-            // and send it.
-            AdbHelper.write(mChannel, msg, -1, AdbHelper.STD_TIMEOUT);
-
-            // read the result, in a byte array containing 2 ints
-            // (id, size)
-            AdbHelper.read(mChannel, pullResult, -1, AdbHelper.STD_TIMEOUT);
-
-            // check we have the proper data back
-            if (checkResult(pullResult, ID_DATA) == false &&
-                    checkResult(pullResult, ID_DONE) == false) {
-                return new SyncResult(RESULT_CONNECTION_ERROR);
-            }
-        } catch (UnsupportedEncodingException e) {
-            return new SyncResult(RESULT_REMOTE_PATH_ENCODING, e);
-        } catch (IOException e) {
-            return new SyncResult(RESULT_CONNECTION_ERROR, e);
-        }
-
-        // access the destination file
-        File f = new File(localPath);
-
-        // create the stream to write in the file. We use a new try/catch block to differentiate
-        // between file and network io exceptions.
-        FileOutputStream fos = null;
-        try {
-            fos = new FileOutputStream(f);
-        } catch (FileNotFoundException e) {
-            return new SyncResult(RESULT_FILE_WRITE_ERROR, e);
-        }
-
-        // the buffer to read the data
-        byte[] data = new byte[SYNC_DATA_MAX];
-
-        // loop to get data until we're done.
-        while (true) {
-            // check if we're cancelled
-            if (monitor.isCanceled() == true) {
-                return new SyncResult(RESULT_CANCELED);
-            }
-
-            // if we're done, we stop the loop
-            if (checkResult(pullResult, ID_DONE)) {
-                break;
-            }
-            if (checkResult(pullResult, ID_DATA) == false) {
-                // hmm there's an error
-                return new SyncResult(RESULT_CONNECTION_ERROR);
-            }
-            int length = ArrayHelper.swap32bitFromArray(pullResult, 4);
-            if (length > SYNC_DATA_MAX) {
-                // buffer overrun!
-                // error and exit
-                return new SyncResult(RESULT_BUFFER_OVERRUN);
-            }
-
-            try {
-                // now read the length we received
-                AdbHelper.read(mChannel, data, length, AdbHelper.STD_TIMEOUT);
-
-                // get the header for the next packet.
-                AdbHelper.read(mChannel, pullResult, -1, AdbHelper.STD_TIMEOUT);
-            } catch (IOException e) {
-                return new SyncResult(RESULT_CONNECTION_ERROR, e);
-            }
-
-            // write the content in the file
-            try {
-                fos.write(data, 0, length);
-            } catch (IOException e) {
-                return new SyncResult(RESULT_FILE_WRITE_ERROR, e);
-            }
-
-            monitor.advance(length);
-        }
-
-        try {
-            fos.flush();
-        } catch (IOException e) {
-            return new SyncResult(RESULT_FILE_WRITE_ERROR, e);
-        }
-        return new SyncResult(RESULT_OK);
-    }
-
-
-    /**
-     * Push multiple files
-     * @param fileArray
-     * @param remotePath
-     * @param monitor
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    private SyncResult doPush(File[] fileArray, String remotePath, ISyncProgressMonitor monitor) {
-        for (File f : fileArray) {
-            // check if we're canceled
-            if (monitor.isCanceled() == true) {
-                return new SyncResult(RESULT_CANCELED);
-            }
-            if (f.exists()) {
-                if (f.isDirectory()) {
-                    // append the name of the directory to the remote path
-                    String dest = remotePath + "/" + f.getName(); // $NON-NLS-1S
-                    monitor.startSubTask(dest);
-                    SyncResult result = doPush(f.listFiles(), dest, monitor);
-
-                    if (result.mCode != RESULT_OK) {
-                        return result;
-                    }
-
-                    monitor.advance(1);
-                } else if (f.isFile()) {
-                    // append the name of the file to the remote path
-                    String remoteFile = remotePath + "/" + f.getName(); // $NON-NLS-1S
-                    monitor.startSubTask(remoteFile);
-                    SyncResult result = doPushFile(f.getAbsolutePath(), remoteFile, monitor);
-                    if (result.mCode != RESULT_OK) {
-                        return result;
-                    }
-                }
-            }
-        }
-
-        return new SyncResult(RESULT_OK);
-    }
-
-    /**
-     * Push a single file
-     * @param localPath the local file to push
-     * @param remotePath the remote file (length max is 1024)
-     * @param monitor the monitor. The monitor must be started already.
-     * @return a {@link SyncResult} object with a code and an optional message.
-     */
-    private SyncResult doPushFile(String localPath, String remotePath,
-            ISyncProgressMonitor monitor) {
-        FileInputStream fis = null;
-        byte[] msg;
-
-        try {
-            byte[] remotePathContent = remotePath.getBytes(AdbHelper.DEFAULT_ENCODING);
-
-            if (remotePathContent.length > REMOTE_PATH_MAX_LENGTH) {
-                return new SyncResult(RESULT_REMOTE_PATH_LENGTH);
-            }
-
-            File f = new File(localPath);
-
-            // this shouldn't happen but still...
-            if (f.exists() == false) {
-                return new SyncResult(RESULT_NO_LOCAL_FILE);
-            }
-
-            // create the stream to read the file
-            fis = new FileInputStream(f);
-
-            // create the header for the action
-            msg = createSendFileReq(ID_SEND, remotePathContent, 0644);
-        } catch (UnsupportedEncodingException e) {
-            return new SyncResult(RESULT_REMOTE_PATH_ENCODING, e);
-        } catch (FileNotFoundException e) {
-            return new SyncResult(RESULT_FILE_READ_ERROR, e);
-        }
-
-        // and send it. We use a custom try/catch block to make the difference between
-        // file and network IO exceptions.
-        try {
-            AdbHelper.write(mChannel, msg, -1, AdbHelper.STD_TIMEOUT);
-        } catch (IOException e) {
-            return new SyncResult(RESULT_CONNECTION_ERROR, e);
-        }
-
-        // create the buffer used to read.
-        // we read max SYNC_DATA_MAX, but we need 2 4 bytes at the beginning.
-        if (mBuffer == null) {
-            mBuffer = new byte[SYNC_DATA_MAX + 8];
-        }
-        System.arraycopy(ID_DATA, 0, mBuffer, 0, ID_DATA.length);
-
-        // look while there is something to read
-        while (true) {
-            // check if we're canceled
-            if (monitor.isCanceled() == true) {
-                return new SyncResult(RESULT_CANCELED);
-            }
-
-            // read up to SYNC_DATA_MAX
-            int readCount = 0;
-            try {
-                readCount = fis.read(mBuffer, 8, SYNC_DATA_MAX);
-            } catch (IOException e) {
-                return new SyncResult(RESULT_FILE_READ_ERROR, e);
-            }
-
-            if (readCount == -1) {
-                // we reached the end of the file
-                break;
-            }
-
-            // now send the data to the device
-            // first write the amount read
-            ArrayHelper.swap32bitsToArray(readCount, mBuffer, 4);
-
-            // now write it
-            try {
-                AdbHelper.write(mChannel, mBuffer, readCount+8, AdbHelper.STD_TIMEOUT);
-            } catch (IOException e) {
-                return new SyncResult(RESULT_CONNECTION_ERROR, e);
-            }
-
-            // and advance the monitor
-            monitor.advance(readCount);
-        }
-        // close the local file
-        try {
-            fis.close();
-        } catch (IOException e) {
-            return new SyncResult(RESULT_FILE_READ_ERROR, e);
-        }
-
-        try {
-            // create the DONE message
-            long time = System.currentTimeMillis() / 1000;
-            msg = createReq(ID_DONE, (int)time);
-
-            // and send it.
-            AdbHelper.write(mChannel, msg, -1, AdbHelper.STD_TIMEOUT);
-
-            // read the result, in a byte array containing 2 ints
-            // (id, size)
-            byte[] result = new byte[8];
-            AdbHelper.read(mChannel, result, -1 /* full length */, AdbHelper.STD_TIMEOUT);
-
-            if (checkResult(result, ID_OKAY) == false) {
-                if (checkResult(result, ID_FAIL)) {
-                    // read some error message...
-                    int len = ArrayHelper.swap32bitFromArray(result, 4);
-
-                    AdbHelper.read(mChannel, mBuffer, len, AdbHelper.STD_TIMEOUT);
-
-                    // output the result?
-                    String message = new String(mBuffer, 0, len);
-                    Log.e("ddms", "transfer error: " + message);
-                    return new SyncResult(RESULT_UNKNOWN_ERROR, message);
-                }
-
-                return new SyncResult(RESULT_UNKNOWN_ERROR);
-            }
-        } catch (IOException e) {
-            return new SyncResult(RESULT_CONNECTION_ERROR, e);
-        }
-
-        return new SyncResult(RESULT_OK);
-    }
-
-
-    /**
-     * Returns the mode of the remote file.
-     * @param path the remote file
-     * @return and Integer containing the mode if all went well or null
-     *      otherwise
-     */
-    private Integer readMode(String path) {
-        try {
-            // create the stat request message.
-            byte[] msg = createFileReq(ID_STAT, path);
-
-            AdbHelper.write(mChannel, msg, -1 /* full length */, AdbHelper.STD_TIMEOUT);
-
-            // read the result, in a byte array containing 4 ints
-            // (id, mode, size, time)
-            byte[] statResult = new byte[16];
-            AdbHelper.read(mChannel, statResult, -1 /* full length */, AdbHelper.STD_TIMEOUT);
-
-            // check we have the proper data back
-            if (checkResult(statResult, ID_STAT) == false) {
-                return null;
-            }
-
-            // we return the mode (2nd int in the array)
-            return ArrayHelper.swap32bitFromArray(statResult, 4);
-        } catch (IOException e) {
-            return null;
-        }
-    }
-
-    /**
-     * Create a command with a code and an int values
-     * @param command
-     * @param value
-     * @return
-     */
-    private static byte[] createReq(byte[] command, int value) {
-        byte[] array = new byte[8];
-
-        System.arraycopy(command, 0, array, 0, 4);
-        ArrayHelper.swap32bitsToArray(value, array, 4);
-
-        return array;
-    }
-
-    /**
-     * Creates the data array for a stat request.
-     * @param command the 4 byte command (ID_STAT, ID_RECV, ...)
-     * @param path The path of the remote file on which to execute the command
-     * @return the byte[] to send to the device through adb
-     */
-    private static byte[] createFileReq(byte[] command, String path) {
-        byte[] pathContent = null;
-        try {
-            pathContent = path.getBytes(AdbHelper.DEFAULT_ENCODING);
-        } catch (UnsupportedEncodingException e) {
-            return null;
-        }
-
-        return createFileReq(command, pathContent);
-    }
-
-    /**
-     * Creates the data array for a file request. This creates an array with a 4 byte command + the
-     * remote file name.
-     * @param command the 4 byte command (ID_STAT, ID_RECV, ...).
-     * @param path The path, as a byte array, of the remote file on which to
-     *      execute the command.
-     * @return the byte[] to send to the device through adb
-     */
-    private static byte[] createFileReq(byte[] command, byte[] path) {
-        byte[] array = new byte[8 + path.length];
-
-        System.arraycopy(command, 0, array, 0, 4);
-        ArrayHelper.swap32bitsToArray(path.length, array, 4);
-        System.arraycopy(path, 0, array, 8, path.length);
-
-        return array;
-    }
-
-    private static byte[] createSendFileReq(byte[] command, byte[] path, int mode) {
-        // make the mode into a string
-        String modeStr = "," + (mode & 0777); // $NON-NLS-1S
-        byte[] modeContent = null;
-        try {
-            modeContent = modeStr.getBytes(AdbHelper.DEFAULT_ENCODING);
-        } catch (UnsupportedEncodingException e) {
-            return null;
-        }
-
-        byte[] array = new byte[8 + path.length + modeContent.length];
-
-        System.arraycopy(command, 0, array, 0, 4);
-        ArrayHelper.swap32bitsToArray(path.length + modeContent.length, array, 4);
-        System.arraycopy(path, 0, array, 8, path.length);
-        System.arraycopy(modeContent, 0, array, 8 + path.length, modeContent.length);
-
-        return array;
-
-
-    }
-
-    /**
-     * Checks the result array starts with the provided code
-     * @param result The result array to check
-     * @param code The 4 byte code.
-     * @return true if the code matches.
-     */
-    private static boolean checkResult(byte[] result, byte[] code) {
-        if (result[0] != code[0] ||
-                result[1] != code[1] ||
-                result[2] != code[2] ||
-                result[3] != code[3]) {
-            return false;
-        }
-
-        return true;
-
-    }
-
-    private static int getFileType(int mode) {
-        if ((mode & S_ISOCK) == S_ISOCK) {
-            return FileListingService.TYPE_SOCKET;
-        }
-
-        if ((mode & S_IFLNK) == S_IFLNK) {
-            return FileListingService.TYPE_LINK;
-        }
-
-        if ((mode & S_IFREG) == S_IFREG) {
-            return FileListingService.TYPE_FILE;
-        }
-
-        if ((mode & S_IFBLK) == S_IFBLK) {
-            return FileListingService.TYPE_BLOCK;
-        }
-
-        if ((mode & S_IFDIR) == S_IFDIR) {
-            return FileListingService.TYPE_DIRECTORY;
-        }
-
-        if ((mode & S_IFCHR) == S_IFCHR) {
-            return FileListingService.TYPE_CHARACTER;
-        }
-
-        if ((mode & S_IFIFO) == S_IFIFO) {
-            return FileListingService.TYPE_FIFO;
-        }
-
-        return FileListingService.TYPE_OTHER;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ThreadInfo.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ThreadInfo.java
deleted file mode 100644
index 8f284f3..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/ThreadInfo.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib;
-
-/**
- * Holds a thread information.
- */
-public final class ThreadInfo implements IStackTraceInfo {
-    private int mThreadId;
-    private String mThreadName;
-    private int mStatus;
-    private int mTid;
-    private int mUtime;
-    private int mStime;
-    private boolean mIsDaemon;
-    private StackTraceElement[] mTrace;
-    private long mTraceTime;
-
-    // priority?
-    // total CPU used?
-    // method at top of stack?
-
-    /**
-     * Construct with basic identification.
-     */
-    ThreadInfo(int threadId, String threadName) {
-        mThreadId = threadId;
-        mThreadName = threadName;
-
-        mStatus = -1;
-        //mTid = mUtime = mStime = 0;
-        //mIsDaemon = false;
-    }
-
-    /**
-     * Set with the values we get from a THST chunk.
-     */
-    void updateThread(int status, int tid, int utime, int stime, boolean isDaemon) {
-
-        mStatus = status;
-        mTid = tid;
-        mUtime = utime;
-        mStime = stime;
-        mIsDaemon = isDaemon;
-    }
-    
-    /**
-     * Sets the stack call of the thread.
-     * @param trace stackcall information.
-     */
-    void setStackCall(StackTraceElement[] trace) {
-        mTrace = trace;
-        mTraceTime = System.currentTimeMillis();
-    }
-
-    /**
-     * Returns the thread's ID.
-     */
-    public int getThreadId() {
-        return mThreadId;
-    }
-
-    /**
-     * Returns the thread's name.
-     */
-    public String getThreadName() {
-        return mThreadName;
-    }
-    
-    void setThreadName(String name) {
-        mThreadName = name;
-    }
-
-    /**
-     * Returns the system tid.
-     */
-    public int getTid() {
-        return mTid;
-    }
-
-    /**
-     * Returns the VM thread status.
-     */
-    public int getStatus() {
-        return mStatus;
-    }
-
-    /**
-     * Returns the cumulative user time.
-     */
-    public int getUtime() {
-        return mUtime;
-    }
-
-    /**
-     * Returns the cumulative system time.
-     */
-    public int getStime() {
-        return mStime;
-    }
-
-    /**
-     * Returns whether this is a daemon thread.
-     */
-    public boolean isDaemon() {
-        return mIsDaemon;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ddmlib.IStackTraceInfo#getStackTrace()
-     */
-    public StackTraceElement[] getStackTrace() {
-        return mTrace;
-    }
-
-    /**
-     * Returns the approximate time of the stacktrace data.
-     * @see #getStackTrace()
-     */
-    public long getStackCallTime() {
-        return mTraceTime;
-    }
-}
-
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventContainer.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventContainer.java
deleted file mode 100644
index ec9186c..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventContainer.java
+++ /dev/null
@@ -1,461 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Represents an event and its data.
- */
-public class EventContainer {
-    
-    /**
-     * Comparison method for {@link EventContainer#testValue(int, Object, com.android.ddmlib.log.EventContainer.CompareMethod)}
-     *
-     */
-    public enum CompareMethod {
-        EQUAL_TO("equals", "=="),
-        LESSER_THAN("less than or equals to", "<="),
-        LESSER_THAN_STRICT("less than", "<"),
-        GREATER_THAN("greater than or equals to", ">="),
-        GREATER_THAN_STRICT("greater than", ">"),
-        BIT_CHECK("bit check", "&");
-        
-        private final String mName;
-        private final String mTestString;
-
-        private CompareMethod(String name, String testString) {
-            mName = name;
-            mTestString = testString;
-        }
-
-        /**
-         * Returns the display string.
-         */
-        @Override
-        public String toString() {
-            return mName;
-        }
-
-        /**
-         * Returns a short string representing the comparison.
-         */
-        public String testString() {
-            return mTestString;
-        }
-    }
-
-    
-    /**
-     * Type for event data.
-     */
-    public static enum EventValueType {
-        UNKNOWN(0),
-        INT(1),
-        LONG(2),
-        STRING(3),
-        LIST(4),
-        TREE(5);
-        
-        private final static Pattern STORAGE_PATTERN = Pattern.compile("^(\\d+)@(.*)$"); //$NON-NLS-1$
-        
-        private int mValue;
-        
-        /**
-         * Returns a {@link EventValueType} from an integer value, or <code>null</code> if no match
-         * was found.
-         * @param value the integer value.
-         */
-        static EventValueType getEventValueType(int value) {
-            for (EventValueType type : values()) {
-                if (type.mValue == value) {
-                    return type;
-                }
-            }
-            
-            return null;
-        }
-
-        /**
-         * Returns a storage string for an {@link Object} of type supported by
-         * {@link EventValueType}.
-         * <p/>
-         * Strings created by this method can be reloaded with
-         * {@link #getObjectFromStorageString(String)}.
-         * <p/>
-         * NOTE: for now, only {@link #STRING}, {@link #INT}, and {@link #LONG} are supported.
-         * @param object the object to "convert" into a storage string.
-         * @return a string storing the object and its type or null if the type was not recognized.
-         */
-        public static String getStorageString(Object object) {
-            if (object instanceof String) {
-                return STRING.mValue + "@" + (String)object; //$NON-NLS-1$ 
-            } else if (object instanceof Integer) {
-                return INT.mValue + "@" + object.toString(); //$NON-NLS-1$ 
-            } else if (object instanceof Long) {
-                return LONG.mValue + "@" + object.toString(); //$NON-NLS-1$ 
-            }
-            
-            return null;
-        }
-        
-        /**
-         * Creates an {@link Object} from a storage string created with
-         * {@link #getStorageString(Object)}.
-         * @param value the storage string
-         * @return an {@link Object} or null if the string or type were not recognized.
-         */
-        public static Object getObjectFromStorageString(String value) {
-            Matcher m = STORAGE_PATTERN.matcher(value);
-            if (m.matches()) {
-                try {
-                    EventValueType type = getEventValueType(Integer.parseInt(m.group(1)));
-
-                    if (type == null) {
-                        return null;
-                    }
-                    
-                    switch (type) {
-                        case STRING:
-                            return m.group(2);
-                        case INT:
-                            return Integer.valueOf(m.group(2));
-                        case LONG:
-                            return Long.valueOf(m.group(2));
-                    }
-                } catch (NumberFormatException nfe) {
-                    return null;
-                }
-            }
-            
-            return null;
-        }
-        
-        
-        /**
-         * Returns the integer value of the enum.
-         */
-        public int getValue() {
-            return mValue;
-        }
-
-        @Override
-        public String toString() {
-            return super.toString().toLowerCase();
-        }
-
-        private EventValueType(int value) {
-            mValue = value;
-        }
-    }
-
-    public int mTag;
-    public int pid;    /* generating process's pid */
-    public int tid;    /* generating process's tid */
-    public int sec;    /* seconds since Epoch */
-    public int nsec;   /* nanoseconds */
-
-    private Object mData; 
-
-    /**
-     * Creates an {@link EventContainer} from a {@link LogEntry}.
-     * @param entry  the LogEntry from which pid, tid, and time info is copied.
-     * @param tag the event tag value
-     * @param data the data of the EventContainer.
-     */
-    EventContainer(LogEntry entry, int tag, Object data) {
-        getType(data);
-        mTag = tag;
-        mData = data;
-
-        pid = entry.pid;
-        tid = entry.tid;
-        sec = entry.sec;
-        nsec = entry.nsec;
-    }
-    
-    /**
-     * Creates an {@link EventContainer} with raw data
-     */
-    EventContainer(int tag, int pid, int tid, int sec, int nsec, Object data) {
-        getType(data);
-        mTag = tag;
-        mData = data;
-        
-        this.pid = pid;
-        this.tid = tid;
-        this.sec = sec;
-        this.nsec = nsec;
-    }
-
-    /**
-     * Returns the data as an int.
-     * @throws InvalidTypeException if the data type is not {@link EventValueType#INT}.
-     * @see #getType()
-     */
-    public final Integer getInt() throws InvalidTypeException {
-        if (getType(mData) == EventValueType.INT) {
-            return (Integer)mData;
-        }
-
-        throw new InvalidTypeException();
-    }
-    
-    /**
-     * Returns the data as a long.
-     * @throws InvalidTypeException if the data type is not {@link EventValueType#LONG}. 
-     * @see #getType()
-     */
-    public final Long getLong() throws InvalidTypeException {
-        if (getType(mData) == EventValueType.LONG) {
-            return (Long)mData;
-        }
-
-        throw new InvalidTypeException();
-    }
-
-    /**
-     * Returns the data as a String.
-     * @throws InvalidTypeException if the data type is not {@link EventValueType#STRING}.
-     * @see #getType()
-     */
-    public final String getString() throws InvalidTypeException {
-        if (getType(mData) == EventValueType.STRING) {
-            return (String)mData;
-        }
-
-        throw new InvalidTypeException();
-    }
-    
-    /**
-     * Returns a value by index. The return type is defined by its type.
-     * @param valueIndex the index of the value. If the data is not a list, this is ignored.
-     */
-    public Object getValue(int valueIndex) {
-        return getValue(mData, valueIndex, true);
-    }
-
-    /**
-     * Returns a value by index as a double.
-     * @param valueIndex the index of the value. If the data is not a list, this is ignored.
-     * @throws InvalidTypeException if the data type is not {@link EventValueType#INT},
-     * {@link EventValueType#LONG}, {@link EventValueType#LIST}, or if the item in the
-     * list at index <code>valueIndex</code> is not of type {@link EventValueType#INT} or
-     * {@link EventValueType#LONG}.
-     * @see #getType()
-     */
-    public double getValueAsDouble(int valueIndex) throws InvalidTypeException {
-        return getValueAsDouble(mData, valueIndex, true);
-    }
-
-    /**
-     * Returns a value by index as a String.
-     * @param valueIndex the index of the value. If the data is not a list, this is ignored.
-     * @throws InvalidTypeException if the data type is not {@link EventValueType#INT},
-     * {@link EventValueType#LONG}, {@link EventValueType#STRING}, {@link EventValueType#LIST},
-     * or if the item in the list at index <code>valueIndex</code> is not of type
-     * {@link EventValueType#INT}, {@link EventValueType#LONG}, or {@link EventValueType#STRING}
-     * @see #getType()
-     */
-    public String getValueAsString(int valueIndex) throws InvalidTypeException {
-        return getValueAsString(mData, valueIndex, true);
-    }
-    
-    /**
-     * Returns the type of the data.
-     */
-    public EventValueType getType() {
-        return getType(mData);
-    }
-
-    /**
-     * Returns the type of an object.
-     */
-    public final EventValueType getType(Object data) {
-        if (data instanceof Integer) {
-            return EventValueType.INT;
-        } else if (data instanceof Long) {
-            return EventValueType.LONG;
-        } else if (data instanceof String) {
-            return EventValueType.STRING;
-        } else if (data instanceof Object[]) {
-            // loop through the list to see if we have another list
-            Object[] objects = (Object[])data;
-            for (Object obj : objects) {
-                EventValueType type = getType(obj);
-                if (type == EventValueType.LIST || type == EventValueType.TREE) {
-                    return EventValueType.TREE;
-                }
-            }
-            return EventValueType.LIST;
-        }
-
-        return EventValueType.UNKNOWN;
-    }
-    
-    /**
-     * Checks that the <code>index</code>-th value of this event against a provided value.
-     * @param index the index of the value to test
-     * @param value the value to test against
-     * @param compareMethod the method of testing
-     * @return true if the test passed.
-     * @throws InvalidTypeException in case of type mismatch between the value to test and the value
-     * to test against, or if the compare method is incompatible with the type of the values.
-     * @see CompareMethod
-     */
-    public boolean testValue(int index, Object value,
-            CompareMethod compareMethod) throws InvalidTypeException {
-        EventValueType type = getType(mData);
-        if (index > 0 && type != EventValueType.LIST) {
-            throw new InvalidTypeException();
-        }
-        
-        Object data = mData;
-        if (type == EventValueType.LIST) {
-            data = ((Object[])mData)[index];
-        }
-
-        if (data.getClass().equals(data.getClass()) == false) {
-            throw new InvalidTypeException();
-        }
-
-        switch (compareMethod) {
-            case EQUAL_TO:
-                return data.equals(value);
-            case LESSER_THAN:
-                if (data instanceof Integer) {
-                    return (((Integer)data).compareTo((Integer)value) <= 0);
-                } else if (data instanceof Long) {
-                    return (((Long)data).compareTo((Long)value) <= 0);
-                }
-
-                // other types can't use this compare method.
-                throw new InvalidTypeException();
-            case LESSER_THAN_STRICT:
-                if (data instanceof Integer) {
-                    return (((Integer)data).compareTo((Integer)value) < 0);
-                } else if (data instanceof Long) {
-                    return (((Long)data).compareTo((Long)value) < 0);
-                }
-
-                // other types can't use this compare method.
-                throw new InvalidTypeException();
-            case GREATER_THAN:
-                if (data instanceof Integer) {
-                    return (((Integer)data).compareTo((Integer)value) >= 0);
-                } else if (data instanceof Long) {
-                    return (((Long)data).compareTo((Long)value) >= 0);
-                }
-
-                // other types can't use this compare method.
-                throw new InvalidTypeException();
-            case GREATER_THAN_STRICT:
-                if (data instanceof Integer) {
-                    return (((Integer)data).compareTo((Integer)value) > 0);
-                } else if (data instanceof Long) {
-                    return (((Long)data).compareTo((Long)value) > 0);
-                }
-
-                // other types can't use this compare method.
-                throw new InvalidTypeException();
-            case BIT_CHECK:
-                if (data instanceof Integer) {
-                    return (((Integer)data).intValue() & ((Integer)value).intValue()) != 0;
-                } else if (data instanceof Long) {
-                    return (((Long)data).longValue() & ((Long)value).longValue()) != 0;
-                }
-
-                // other types can't use this compare method.
-                throw new InvalidTypeException();
-            default :
-                throw new InvalidTypeException();
-        }
-    }
-    
-    private final Object getValue(Object data, int valueIndex, boolean recursive) {
-        EventValueType type = getType(data);
-        
-        switch (type) {
-            case INT:
-            case LONG:
-            case STRING:
-                return data;
-            case LIST:
-                if (recursive) {
-                    Object[] list = (Object[]) data;
-                    if (valueIndex >= 0 && valueIndex < list.length) {
-                        return getValue(list[valueIndex], valueIndex, false);
-                    }
-                }
-        }
-        
-        return null;
-    }
-
-    private final double getValueAsDouble(Object data, int valueIndex, boolean recursive)
-            throws InvalidTypeException {
-        EventValueType type = getType(data);
-        
-        switch (type) {
-            case INT:
-                return ((Integer)data).doubleValue();
-            case LONG:
-                return ((Long)data).doubleValue();
-            case STRING:
-                throw new InvalidTypeException();
-            case LIST:
-                if (recursive) {
-                    Object[] list = (Object[]) data;
-                    if (valueIndex >= 0 && valueIndex < list.length) {
-                        return getValueAsDouble(list[valueIndex], valueIndex, false);
-                    }
-                }
-        }
-        
-        throw new InvalidTypeException();
-    }
-
-    private final String getValueAsString(Object data, int valueIndex, boolean recursive)
-            throws InvalidTypeException {
-        EventValueType type = getType(data);
-        
-        switch (type) {
-            case INT:
-                return ((Integer)data).toString();
-            case LONG:
-                return ((Long)data).toString();
-            case STRING:
-                return (String)data;
-            case LIST:
-                if (recursive) {
-                    Object[] list = (Object[]) data;
-                    if (valueIndex >= 0 && valueIndex < list.length) {
-                        return getValueAsString(list[valueIndex], valueIndex, false);
-                    }
-                } else {
-                    throw new InvalidTypeException(
-                            "getValueAsString() doesn't support EventValueType.TREE");
-                }
-        }
-
-        throw new InvalidTypeException(
-                "getValueAsString() unsupported type:" + type);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventLogParser.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventLogParser.java
deleted file mode 100644
index 85e99c1..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventLogParser.java
+++ /dev/null
@@ -1,577 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.MultiLineReceiver;
-import com.android.ddmlib.log.EventContainer.EventValueType;
-import com.android.ddmlib.log.EventValueDescription.ValueType;
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-import com.android.ddmlib.utils.ArrayHelper;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.FileReader;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.Map;
-import java.util.Set;
-import java.util.TreeMap;
-import java.util.Map.Entry;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Parser for the "event" log.
- */
-public final class EventLogParser {
-
-    /** Location of the tag map file on the device */
-    private final static String EVENT_TAG_MAP_FILE = "/system/etc/event-log-tags"; //$NON-NLS-1$
-
-    /**
-     * Event log entry types.  These must match up with the declarations in
-     * java/android/android/util/EventLog.java.
-     */
-    private final static int EVENT_TYPE_INT      = 0;
-    private final static int EVENT_TYPE_LONG     = 1;
-    private final static int EVENT_TYPE_STRING   = 2;
-    private final static int EVENT_TYPE_LIST     = 3;
-    
-    private final static Pattern PATTERN_SIMPLE_TAG = Pattern.compile(
-    "^(\\d+)\\s+([A-Za-z0-9_]+)\\s*$"); //$NON-NLS-1$
-    private final static Pattern PATTERN_TAG_WITH_DESC = Pattern.compile(
-            "^(\\d+)\\s+([A-Za-z0-9_]+)\\s*(.*)\\s*$"); //$NON-NLS-1$
-    private final static Pattern PATTERN_DESCRIPTION = Pattern.compile(
-            "\\(([A-Za-z0-9_\\s]+)\\|(\\d+)(\\|\\d+){0,1}\\)"); //$NON-NLS-1$
-
-    private final static Pattern TEXT_LOG_LINE = Pattern.compile(
-            "(\\d\\d)-(\\d\\d)\\s(\\d\\d):(\\d\\d):(\\d\\d).(\\d{3})\\s+I/([a-zA-Z0-9_]+)\\s*\\(\\s*(\\d+)\\):\\s+(.*)"); //$NON-NLS-1$
-
-    private final TreeMap<Integer, String> mTagMap = new TreeMap<Integer, String>();
-    
-    private final TreeMap<Integer, EventValueDescription[]> mValueDescriptionMap =
-        new TreeMap<Integer, EventValueDescription[]>(); 
-
-    public EventLogParser() {
-    }
-
-    /**
-     * Inits the parser for a specific Device.
-     * <p/>
-     * This methods reads the event-log-tags located on the device to find out
-     * what tags are being written to the event log and what their format is.
-     * @param device The device.
-     * @return <code>true</code> if success, <code>false</code> if failure or cancellation.
-     */
-    public boolean init(Device device) {
-        // read the event tag map file on the device.
-        try {
-            device.executeShellCommand("cat " + EVENT_TAG_MAP_FILE, //$NON-NLS-1$
-                    new MultiLineReceiver() {
-                @Override
-                public void processNewLines(String[] lines) {
-                    for (String line : lines) {
-                        processTagLine(line);
-                    }
-                }
-                public boolean isCancelled() {
-                    return false;
-                }
-            });
-        } catch (IOException e) {
-            return false;
-        }
-
-        return true;
-    }
-    
-    /**
-     * Inits the parser with the content of a tag file.
-     * @param tagFileContent the lines of a tag file.
-     * @return <code>true</code> if success, <code>false</code> if failure.
-     */
-    public boolean init(String[] tagFileContent) {
-        for (String line : tagFileContent) {
-            processTagLine(line);
-        }
-        return true;
-    }
-    
-    /**
-     * Inits the parser with a specified event-log-tags file.
-     * @param filePath
-     * @return <code>true</code> if success, <code>false</code> if failure.
-     */
-    public boolean init(String filePath)  {
-        try {
-            BufferedReader reader = new BufferedReader(new FileReader(filePath));
-            
-            String line = null;
-            do {
-                line = reader.readLine();
-                if (line != null) {
-                    processTagLine(line);
-                }
-            } while (line != null);
-            
-            return true;
-        } catch (IOException e) {
-            return false;
-        }
-    }
-    
-    /**
-     * Processes a line from the event-log-tags file.
-     * @param line the line to process
-     */
-    private void processTagLine(String line) {
-        // ignore empty lines and comment lines
-        if (line.length() > 0 && line.charAt(0) != '#') {
-            Matcher m = PATTERN_TAG_WITH_DESC.matcher(line);
-            if (m.matches()) {
-                try {
-                    int value = Integer.parseInt(m.group(1));
-                    String name = m.group(2);
-                    if (name != null && mTagMap.get(value) == null) {
-                        mTagMap.put(value, name);
-                    }
-                    
-                    // special case for the GC tag. We ignore what is in the file,
-                    // and take what the custom GcEventContainer class tells us.
-                    // This is due to the event encoding several values on 2 longs.
-                    // @see GcEventContainer
-                    if (value == GcEventContainer.GC_EVENT_TAG) {
-                        mValueDescriptionMap.put(value,
-                            GcEventContainer.getValueDescriptions());
-                    } else {
-                        
-                        String description = m.group(3);
-                        if (description != null && description.length() > 0) {
-                            EventValueDescription[] desc =
-                                processDescription(description);
-                            
-                            if (desc != null) {
-                                mValueDescriptionMap.put(value, desc);
-                            }
-                        }
-                    }
-                } catch (NumberFormatException e) {
-                    // failed to convert the number into a string. just ignore it.
-                }
-            } else {
-                m = PATTERN_SIMPLE_TAG.matcher(line);
-                if (m.matches()) {
-                    int value = Integer.parseInt(m.group(1));
-                    String name = m.group(2);
-                    if (name != null && mTagMap.get(value) == null) {
-                        mTagMap.put(value, name);
-                    }
-                }
-            }
-        }
-    }
-    
-    private EventValueDescription[] processDescription(String description) {
-        String[] descriptions = description.split("\\s*,\\s*"); //$NON-NLS-1$
-        
-        ArrayList<EventValueDescription> list = new ArrayList<EventValueDescription>();
-        
-        for (String desc : descriptions) {
-            Matcher m = PATTERN_DESCRIPTION.matcher(desc);
-            if (m.matches()) {
-                try {
-                    String name = m.group(1);
-
-                    String typeString = m.group(2);
-                    int typeValue = Integer.parseInt(typeString);
-                    EventValueType eventValueType = EventValueType.getEventValueType(typeValue);
-                    if (eventValueType == null) {
-                        // just ignore this description if the value is not recognized.
-                        // TODO: log the error.
-                    }
-                    
-                    typeString = m.group(3);
-                    if (typeString != null && typeString.length() > 0) {
-                        //skip the |
-                        typeString = typeString.substring(1);
-                        
-                        typeValue = Integer.parseInt(typeString);
-                        ValueType valueType = ValueType.getValueType(typeValue);
-                        
-                        list.add(new EventValueDescription(name, eventValueType, valueType));
-                    } else {
-                        list.add(new EventValueDescription(name, eventValueType));
-                    }
-                } catch (NumberFormatException nfe) {
-                    // just ignore this description if one number is malformed.
-                    // TODO: log the error.
-                } catch (InvalidValueTypeException e) {
-                    // just ignore this description if data type and data unit don't match
-                    // TODO: log the error.
-                }
-            } else {
-                Log.e("EventLogParser",  //$NON-NLS-1$
-                    String.format("Can't parse %1$s", description));  //$NON-NLS-1$
-            }
-        }
-        
-        if (list.size() == 0) {
-            return null;
-        }
-        
-        return list.toArray(new EventValueDescription[list.size()]);
-        
-    }
-    
-    public EventContainer parse(LogEntry entry) {
-        if (entry.len < 4) {
-            return null;
-        }
-
-        int inOffset = 0;
-
-        int tagValue = ArrayHelper.swap32bitFromArray(entry.data, inOffset);
-        inOffset += 4;
-        
-        String tag = mTagMap.get(tagValue);
-        if (tag == null) {
-            Log.e("EventLogParser", String.format("unknown tag number: %1$d", tagValue));
-        }
-
-        ArrayList<Object> list = new ArrayList<Object>();
-        if (parseBinaryEvent(entry.data, inOffset, list) == -1) {
-            return null;
-        }
-
-        Object data;
-        if (list.size() == 1) {
-            data = list.get(0);
-        } else{
-            data = list.toArray();
-        }
-
-        EventContainer event = null;
-        if (tagValue == GcEventContainer.GC_EVENT_TAG) {
-            event = new GcEventContainer(entry, tagValue, data);
-        } else {
-            event = new EventContainer(entry, tagValue, data);
-        }
-        
-        return event;
-    }
-    
-    public EventContainer parse(String textLogLine) {
-        // line will look like
-        // 04-29 23:16:16.691 I/dvm_gc_info(  427): <data>
-        // where <data> is either
-        // [value1,value2...]
-        // or
-        // value
-        if (textLogLine.length() == 0) {
-            return null;
-        }
-        
-        // parse the header first
-        Matcher m = TEXT_LOG_LINE.matcher(textLogLine);
-        if (m.matches()) {
-            try {
-                int month = Integer.parseInt(m.group(1));
-                int day = Integer.parseInt(m.group(2));
-                int hours = Integer.parseInt(m.group(3));
-                int minutes = Integer.parseInt(m.group(4));
-                int seconds = Integer.parseInt(m.group(5));
-                int milliseconds = Integer.parseInt(m.group(6));
-                
-                // convert into seconds since epoch and nano-seconds.
-                Calendar cal = Calendar.getInstance();
-                cal.set(cal.get(Calendar.YEAR), month-1, day, hours, minutes, seconds);
-                int sec = (int)Math.floor(cal.getTimeInMillis()/1000);
-                int nsec = milliseconds * 1000000;
-
-                String tag = m.group(7);
-                
-                // get the numerical tag value
-                int tagValue = -1;
-                Set<Entry<Integer, String>> tagSet = mTagMap.entrySet();
-                for (Entry<Integer, String> entry : tagSet) {
-                    if (tag.equals(entry.getValue())) {
-                        tagValue = entry.getKey();
-                        break;
-                    }
-                }
-                
-                if (tagValue == -1) {
-                    return null;
-                }
-                
-                int pid = Integer.parseInt(m.group(8));
-                
-                Object data = parseTextData(m.group(9), tagValue);
-                if (data == null) {
-                    return null;
-                }
-                
-                // now we can allocate and return the EventContainer
-                EventContainer event = null;
-                if (tagValue == GcEventContainer.GC_EVENT_TAG) {
-                    event = new GcEventContainer(tagValue, pid, -1 /* tid */, sec, nsec, data);
-                } else {
-                    event = new EventContainer(tagValue, pid, -1 /* tid */, sec, nsec, data);
-                }
-                
-                return event;
-            } catch (NumberFormatException e) {
-                return null;
-            }
-        }
-        
-        return null;
-    }
-    
-    public Map<Integer, String> getTagMap() {
-        return mTagMap;
-    }
-    
-    public Map<Integer, EventValueDescription[]> getEventInfoMap() {
-        return mValueDescriptionMap;
-    }
-
-    /**
-     * Recursively convert binary log data to printable form.
-     *
-     * This needs to be recursive because you can have lists of lists.
-     *
-     * If we run out of room, we stop processing immediately.  It's important
-     * for us to check for space on every output element to avoid producing
-     * garbled output.
-     *
-     * Returns the amount read on success, -1 on failure.
-     */
-    private static int parseBinaryEvent(byte[] eventData, int dataOffset, ArrayList<Object> list) {
-
-        if (eventData.length - dataOffset < 1)
-            return -1;
-        
-        int offset = dataOffset;
-
-        int type = eventData[offset++];
-
-        //fprintf(stderr, "--- type=%d (rem len=%d)\n", type, eventDataLen);
-
-        switch (type) {
-        case EVENT_TYPE_INT: { /* 32-bit signed int */
-                int ival;
-
-                if (eventData.length - offset < 4)
-                    return -1;
-                ival = ArrayHelper.swap32bitFromArray(eventData, offset);
-                offset += 4;
-                
-                list.add(new Integer(ival));
-            }
-            break;
-        case EVENT_TYPE_LONG: { /* 64-bit signed long */
-                long lval;
-
-                if (eventData.length - offset < 8)
-                    return -1;
-                lval = ArrayHelper.swap64bitFromArray(eventData, offset);
-                offset += 8;
-                
-                list.add(new Long(lval));
-            }
-            break;
-        case EVENT_TYPE_STRING: { /* UTF-8 chars, not NULL-terminated */
-                int strLen;
-
-                if (eventData.length - offset < 4)
-                    return -1;
-                strLen = ArrayHelper.swap32bitFromArray(eventData, offset);
-                offset += 4;
-
-                if (eventData.length - offset < strLen)
-                    return -1;
-                
-                // get the string
-                try {
-                    String str = new String(eventData, offset, strLen, "UTF-8"); //$NON-NLS-1$
-                    list.add(str);
-                } catch (UnsupportedEncodingException e) {
-                }
-                offset += strLen;
-                break;
-            }
-        case EVENT_TYPE_LIST: { /* N items, all different types */
-
-                if (eventData.length - offset < 1)
-                    return -1;
-
-                int count = eventData[offset++];
-
-                // make a new temp list
-                ArrayList<Object> subList = new ArrayList<Object>();
-                for (int i = 0; i < count; i++) {
-                    int result = parseBinaryEvent(eventData, offset, subList);
-                    if (result == -1) {
-                        return result;
-                    }
-                    
-                    offset += result;
-                }
-
-                list.add(subList.toArray());
-            }
-            break;
-        default:
-            Log.e("EventLogParser",  //$NON-NLS-1$
-                    String.format("Unknown binary event type %1$d", type));  //$NON-NLS-1$
-            return -1;
-        }
-        
-        return offset - dataOffset;
-    }
-    
-    private Object parseTextData(String data, int tagValue) {
-        // first, get the description of what we're supposed to parse
-        EventValueDescription[] desc = mValueDescriptionMap.get(tagValue);
-        
-        if (desc == null) {
-            // TODO parse and create string values.
-            return null;
-        }
-        
-        if (desc.length == 1) {
-            return getObjectFromString(data, desc[0].getEventValueType());
-        } else if (data.startsWith("[") && data.endsWith("]")) {
-            data = data.substring(1, data.length() - 1);
-            
-            // get each individual values as String
-            String[] values = data.split(",");
-            
-            if (tagValue == GcEventContainer.GC_EVENT_TAG) {
-                // special case for the GC event!
-                Object[] objects = new Object[2];
-                
-                objects[0] = getObjectFromString(values[0], EventValueType.LONG);
-                objects[1] = getObjectFromString(values[1], EventValueType.LONG);
-                
-                return objects;
-            } else {
-                // must be the same number as the number of descriptors.
-                if (values.length != desc.length) {
-                    return null;
-                }
-                
-                Object[] objects = new Object[values.length];
-                
-                for (int i = 0 ; i < desc.length ; i++) {
-                    Object obj = getObjectFromString(values[i], desc[i].getEventValueType());
-                    if (obj == null) {
-                        return null;
-                    }
-                    objects[i] = obj; 
-                }
-                
-                return objects;
-            }
-        }
-        
-        return null;
-    }
-
-    
-    private Object getObjectFromString(String value, EventValueType type) {
-        try {
-            switch (type) {
-                case INT:
-                    return Integer.valueOf(value);
-                case LONG:
-                    return Long.valueOf(value);
-                case STRING:
-                    return value;
-            }
-        } catch (NumberFormatException e) {
-            // do nothing, we'll return null.
-        }
-        
-        return null;
-    }
-
-    /**
-     * Recreates the event-log-tags at the specified file path. 
-     * @param filePath the file path to write the file.
-     * @throws IOException 
-     */
-    public void saveTags(String filePath) throws IOException {
-        File destFile = new File(filePath);
-        destFile.createNewFile();
-        FileOutputStream fos = null;
-
-        try {
-            
-            fos = new FileOutputStream(destFile);
-            
-            for (Integer key : mTagMap.keySet()) {
-                // get the tag name
-                String tagName = mTagMap.get(key);
-                
-                // get the value descriptions
-                EventValueDescription[] descriptors = mValueDescriptionMap.get(key);
-                
-                String line = null;
-                if (descriptors != null) {
-                    StringBuilder sb = new StringBuilder();
-                    sb.append(String.format("%1$d %2$s", key, tagName)); //$NON-NLS-1$
-                    boolean first = true;
-                    for (EventValueDescription evd : descriptors) {
-                        if (first) {
-                            sb.append(" ("); //$NON-NLS-1$
-                            first = false;
-                        } else {
-                            sb.append(",("); //$NON-NLS-1$
-                        }
-                        sb.append(evd.getName());
-                        sb.append("|"); //$NON-NLS-1$
-                        sb.append(evd.getEventValueType().getValue());
-                        sb.append("|"); //$NON-NLS-1$
-                        sb.append(evd.getValueType().getValue());
-                        sb.append("|)"); //$NON-NLS-1$
-                    }
-                    sb.append("\n"); //$NON-NLS-1$
-                    
-                    line = sb.toString();
-                } else {
-                    line = String.format("%1$d %2$s\n", key, tagName); //$NON-NLS-1$
-                }
-    
-                byte[] buffer = line.getBytes();
-                fos.write(buffer);
-            }
-        } finally {
-            if (fos != null) {
-                fos.close();
-            }
-        }
-    }
-
-
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventValueDescription.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventValueDescription.java
deleted file mode 100644
index b68b4e8..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/EventValueDescription.java
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import com.android.ddmlib.log.EventContainer.EventValueType;
-
-
-/**
- * Describes an {@link EventContainer} value.
- * <p/>
- * This is a stand-alone object, not linked to a particular Event. It describes the value, by
- * name, type ({@link EventValueType}), and (if needed) value unit ({@link ValueType}).
- * <p/>
- * The index of the value is not contained within this class, and is instead dependent on the
- * index of this particular object in the array of {@link EventValueDescription} returned by
- * {@link EventLogParser#getEventInfoMap()} when queried for a particular event tag.
- * 
- */
-public final class EventValueDescription {
-    
-    /**
-     * Represents the type of a numerical value. This is used to display values of vastly different
-     * type/range in graphs. 
-     */
-    public static enum ValueType {
-        NOT_APPLICABLE(0),
-        OBJECTS(1),
-        BYTES(2),
-        MILLISECONDS(3),
-        ALLOCATIONS(4),
-        ID(5),
-        PERCENT(6);
-
-        private int mValue;
-
-        /**
-         * Checks that the {@link EventValueType} is compatible with the {@link ValueType}.
-         * @param type the {@link EventValueType} to check.
-         * @throws InvalidValueTypeException if the types are not compatible.
-         */
-        public void checkType(EventValueType type) throws InvalidValueTypeException {
-            if ((type != EventValueType.INT && type != EventValueType.LONG)
-                    && this != NOT_APPLICABLE) {
-                throw new InvalidValueTypeException(
-                        String.format("%1$s doesn't support type %2$s", type, this));
-            }
-        }
-
-        /**
-         * Returns a {@link ValueType} from an integer value, or <code>null</code> if no match
-         * were found.
-         * @param value the integer value.
-         */
-        public static ValueType getValueType(int value) {
-            for (ValueType type : values()) {
-                if (type.mValue == value) {
-                    return type;
-                }
-            }
-            return null;
-        }
-
-        /**
-         * Returns the integer value of the enum.
-         */
-        public int getValue() {
-            return mValue;
-        }
-        
-        @Override
-        public String toString() {
-            return super.toString().toLowerCase();
-        }
-        
-        private ValueType(int value) {
-            mValue = value;
-        }
-    }
-    
-    private String mName;
-    private EventValueType mEventValueType;
-    private ValueType mValueType;
-    
-    /**
-     * Builds a {@link EventValueDescription} with a name and a type.
-     * <p/>
-     * If the type is {@link EventValueType#INT} or {@link EventValueType#LONG}, the
-     * {@link #mValueType} is set to {@link ValueType#BYTES} by default. It set to
-     * {@link ValueType#NOT_APPLICABLE} for all other {@link EventValueType} values.
-     * @param name
-     * @param type
-     */
-    EventValueDescription(String name, EventValueType type) {
-        mName = name;
-        mEventValueType = type;
-        if (mEventValueType == EventValueType.INT || mEventValueType == EventValueType.LONG) {
-            mValueType = ValueType.BYTES;
-        } else {
-            mValueType = ValueType.NOT_APPLICABLE;
-        }
-    }
-
-    /**
-     * Builds a {@link EventValueDescription} with a name and a type, and a {@link ValueType}.
-     * <p/>
-     * @param name
-     * @param type
-     * @param valueType
-     * @throws InvalidValueTypeException if type and valuetype are not compatible.
-     * 
-     */
-    EventValueDescription(String name, EventValueType type, ValueType valueType)
-            throws InvalidValueTypeException {
-        mName = name;
-        mEventValueType = type;
-        mValueType = valueType;
-        mValueType.checkType(mEventValueType);
-    }
-    
-    /**
-     * @return the Name.
-     */
-    public String getName() {
-        return mName;
-    }
-
-    /**
-     * @return the {@link EventValueType}.
-     */
-    public EventValueType getEventValueType() {
-        return mEventValueType;
-    }
-
-    /**
-     * @return the {@link ValueType}.
-     */
-    public ValueType getValueType() {
-        return mValueType;
-    }
-    
-    @Override
-    public String toString() {
-        if (mValueType != ValueType.NOT_APPLICABLE) {
-            return String.format("%1$s (%2$s, %3$s)", mName, mEventValueType.toString(),
-                    mValueType.toString());
-        }
-        
-        return String.format("%1$s (%2$s)", mName, mEventValueType.toString());
-    }
-
-    /**
-     * Checks if the value is of the proper type for this receiver.
-     * @param value the value to check.
-     * @return true if the value is of the proper type for this receiver.
-     */
-    public boolean checkForType(Object value) {
-        switch (mEventValueType) {
-            case INT:
-                return value instanceof Integer;
-            case LONG:
-                return value instanceof Long;
-            case STRING:
-                return value instanceof String;
-            case LIST:
-                return value instanceof Object[];
-        }
-        
-        return false;
-    }
-    
-    /**
-     * Returns an object of a valid type (based on the value returned by
-     * {@link #getEventValueType()}) from a String value.
-     * <p/>
-     * IMPORTANT {@link EventValueType#LIST} and {@link EventValueType#TREE} are not
-     * supported.
-     * @param value the value of the object expressed as a string.
-     * @return an object or null if the conversion could not be done.
-     */
-    public Object getObjectFromString(String value) {
-        switch (mEventValueType) {
-            case INT:
-                try {
-                    return Integer.valueOf(value);
-                } catch (NumberFormatException e) {
-                    return null;
-                }
-            case LONG:
-                try {
-                    return Long.valueOf(value);
-                } catch (NumberFormatException e) {
-                    return null;
-                }
-            case STRING:
-                return value;
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/GcEventContainer.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/GcEventContainer.java
deleted file mode 100644
index 7bae202..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/GcEventContainer.java
+++ /dev/null
@@ -1,347 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import com.android.ddmlib.log.EventValueDescription.ValueType;
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-
-/**
- * Custom Event Container for the Gc event since this event doesn't simply output data in
- * int or long format, but encodes several values on 4 longs.
- * <p/>
- * The array of {@link EventValueDescription}s parsed from the "event-log-tags" file must
- * be ignored, and instead, the array returned from {@link #getValueDescriptions()} must be used. 
- */
-final class GcEventContainer extends EventContainer {
-    
-    public final static int GC_EVENT_TAG = 20001;
-
-    private String processId;
-    private long gcTime;
-    private long bytesFreed;
-    private long objectsFreed;
-    private long actualSize;
-    private long allowedSize;
-    private long softLimit;
-    private long objectsAllocated;
-    private long bytesAllocated;
-    private long zActualSize;
-    private long zAllowedSize;
-    private long zObjectsAllocated;
-    private long zBytesAllocated;
-    private long dlmallocFootprint;
-    private long mallinfoTotalAllocatedSpace;
-    private long externalLimit;
-    private long externalBytesAllocated;
-
-    GcEventContainer(LogEntry entry, int tag, Object data) {
-        super(entry, tag, data);
-        init(data);
-    }
-
-    GcEventContainer(int tag, int pid, int tid, int sec, int nsec, Object data) {
-        super(tag, pid, tid, sec, nsec, data);
-        init(data);
-    }
-
-    /**
-     * @param data
-     */
-    private void init(Object data) {
-        if (data instanceof Object[]) {
-            Object[] values = (Object[])data;
-            for (int i = 0; i < values.length; i++) {
-                if (values[i] instanceof Long) {
-                    parseDvmHeapInfo((Long)values[i], i);
-                }
-            }
-        }
-    }
-    
-    @Override
-    public EventValueType getType() {
-        return EventValueType.LIST;
-    }
-
-    @Override
-    public boolean testValue(int index, Object value, CompareMethod compareMethod)
-            throws InvalidTypeException {
-        // do a quick easy check on the type.
-        if (index == 0) {
-            if ((value instanceof String) == false) {
-                throw new InvalidTypeException();
-            }
-        } else if ((value instanceof Long) == false) {
-            throw new InvalidTypeException();
-        }
-        
-        switch (compareMethod) {
-            case EQUAL_TO:
-                if (index == 0) {
-                    return processId.equals(value);
-                } else {
-                    return getValueAsLong(index) == ((Long)value).longValue();
-                }
-            case LESSER_THAN:
-                return getValueAsLong(index) <= ((Long)value).longValue();
-            case LESSER_THAN_STRICT:
-                return getValueAsLong(index) < ((Long)value).longValue();
-            case GREATER_THAN:
-                return getValueAsLong(index) >= ((Long)value).longValue();
-            case GREATER_THAN_STRICT:
-                return getValueAsLong(index) > ((Long)value).longValue();
-            case BIT_CHECK:
-                return (getValueAsLong(index) & ((Long)value).longValue()) != 0;
-        }
-
-        throw new ArrayIndexOutOfBoundsException();
-    }
-
-    @Override
-    public Object getValue(int valueIndex) {
-        if (valueIndex == 0) {
-            return processId;
-        }
-        
-        try {
-            return new Long(getValueAsLong(valueIndex));
-        } catch (InvalidTypeException e) {
-            // this would only happened if valueIndex was 0, which we test above.
-        }
-        
-        return null;
-    }
-
-    @Override
-    public double getValueAsDouble(int valueIndex) throws InvalidTypeException {
-        return (double)getValueAsLong(valueIndex);
-    }
-
-    @Override
-    public String getValueAsString(int valueIndex) {
-        switch (valueIndex) {
-            case 0:
-                return processId;
-            default:
-                try {
-                    return Long.toString(getValueAsLong(valueIndex));
-                } catch (InvalidTypeException e) {
-                    // we shouldn't stop there since we test, in this method first.
-                }
-        }
-
-        throw new ArrayIndexOutOfBoundsException();
-    }
-    
-    /**
-     * Returns a custom array of {@link EventValueDescription} since the actual content of this
-     * event (list of (long, long) does not match the values encoded into those longs.
-     */
-    static EventValueDescription[] getValueDescriptions() {
-        try {
-            return new EventValueDescription[] {
-                    new EventValueDescription("Process Name", EventValueType.STRING),
-                    new EventValueDescription("GC Time", EventValueType.LONG,
-                            ValueType.MILLISECONDS),
-                    new EventValueDescription("Freed Objects", EventValueType.LONG,
-                            ValueType.OBJECTS),
-                    new EventValueDescription("Freed Bytes", EventValueType.LONG, ValueType.BYTES),
-                    new EventValueDescription("Soft Limit", EventValueType.LONG, ValueType.BYTES),
-                    new EventValueDescription("Actual Size (aggregate)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Allowed Size (aggregate)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Allocated Objects (aggregate)",
-                            EventValueType.LONG, ValueType.OBJECTS),
-                    new EventValueDescription("Allocated Bytes (aggregate)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Actual Size", EventValueType.LONG, ValueType.BYTES),
-                    new EventValueDescription("Allowed Size", EventValueType.LONG, ValueType.BYTES),
-                    new EventValueDescription("Allocated Objects", EventValueType.LONG,
-                            ValueType.OBJECTS),
-                    new EventValueDescription("Allocated Bytes", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Actual Size (zygote)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Allowed Size (zygote)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Allocated Objects (zygote)", EventValueType.LONG,
-                            ValueType.OBJECTS),
-                    new EventValueDescription("Allocated Bytes (zygote)", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("External Allocation Limit", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("External Bytes Allocated", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("dlmalloc Footprint", EventValueType.LONG,
-                            ValueType.BYTES),
-                    new EventValueDescription("Malloc Info: Total Allocated Space",
-                            EventValueType.LONG, ValueType.BYTES),
-                  };
-        } catch (InvalidValueTypeException e) {
-            // this shouldn't happen since we control manual the EventValueType and the ValueType
-            // values. For development purpose, we assert if this happens.
-            assert false;
-        }
-
-        // this shouldn't happen, but the compiler complains otherwise.
-        return null;
-    }
-
-    private void parseDvmHeapInfo(long data, int index) {
-        switch (index) {
-            case 0:
-                //    [63   ] Must be zero
-                //    [62-24] ASCII process identifier
-                //    [23-12] GC time in ms
-                //    [11- 0] Bytes freed
-                
-                gcTime = float12ToInt((int)((data >> 12) & 0xFFFL));
-                bytesFreed = float12ToInt((int)(data & 0xFFFL));
-                
-                // convert the long into an array, in the proper order so that we can convert the
-                // first 5 char into a string.
-                byte[] dataArray = new byte[8];
-                put64bitsToArray(data, dataArray, 0);
-                
-                // get the name from the string
-                processId = new String(dataArray, 0, 5);
-                break;
-            case 1:
-                //    [63-62] 10
-                //    [61-60] Reserved; must be zero
-                //    [59-48] Objects freed
-                //    [47-36] Actual size (current footprint)
-                //    [35-24] Allowed size (current hard max)
-                //    [23-12] Objects allocated
-                //    [11- 0] Bytes allocated
-                objectsFreed = float12ToInt((int)((data >> 48) & 0xFFFL));
-                actualSize = float12ToInt((int)((data >> 36) & 0xFFFL));
-                allowedSize = float12ToInt((int)((data >> 24) & 0xFFFL));
-                objectsAllocated = float12ToInt((int)((data >> 12) & 0xFFFL));
-                bytesAllocated = float12ToInt((int)(data & 0xFFFL));
-                break;
-            case 2:
-                //    [63-62] 11
-                //    [61-60] Reserved; must be zero
-                //    [59-48] Soft limit (current soft max)
-                //    [47-36] Actual size (current footprint)
-                //    [35-24] Allowed size (current hard max)
-                //    [23-12] Objects allocated
-                //    [11- 0] Bytes allocated
-                softLimit = float12ToInt((int)((data >> 48) & 0xFFFL));
-                zActualSize = float12ToInt((int)((data >> 36) & 0xFFFL));
-                zAllowedSize = float12ToInt((int)((data >> 24) & 0xFFFL));
-                zObjectsAllocated = float12ToInt((int)((data >> 12) & 0xFFFL));
-                zBytesAllocated = float12ToInt((int)(data & 0xFFFL));
-                break;
-            case 3:
-                //    [63-48] Reserved; must be zero
-                //    [47-36] dlmallocFootprint
-                //    [35-24] mallinfo: total allocated space
-                //    [23-12] External byte limit
-                //    [11- 0] External bytes allocated
-                dlmallocFootprint = float12ToInt((int)((data >> 36) & 0xFFFL));
-                mallinfoTotalAllocatedSpace = float12ToInt((int)((data >> 24) & 0xFFFL));
-                externalLimit = float12ToInt((int)((data >> 12) & 0xFFFL));
-                externalBytesAllocated = float12ToInt((int)(data & 0xFFFL));
-                break;
-            default:
-                break;
-        }
-    }
-    
-    /**
-     * Converts a 12 bit float representation into an unsigned int (returned as a long)
-     * @param f12
-     */
-    private static long float12ToInt(int f12) {
-        return (f12 & 0x1FF) << ((f12 >>> 9) * 4);
-    }
-    
-    /**
-     * puts an unsigned value in an array.
-     * @param value The value to put.
-     * @param dest the destination array
-     * @param offset the offset in the array where to put the value.
-     *      Array length must be at least offset + 8
-     */
-    private static void put64bitsToArray(long value, byte[] dest, int offset) {
-        dest[offset + 7] = (byte)(value & 0x00000000000000FFL);
-        dest[offset + 6] = (byte)((value & 0x000000000000FF00L) >> 8);
-        dest[offset + 5] = (byte)((value & 0x0000000000FF0000L) >> 16);
-        dest[offset + 4] = (byte)((value & 0x00000000FF000000L) >> 24);
-        dest[offset + 3] = (byte)((value & 0x000000FF00000000L) >> 32);
-        dest[offset + 2] = (byte)((value & 0x0000FF0000000000L) >> 40);
-        dest[offset + 1] = (byte)((value & 0x00FF000000000000L) >> 48);
-        dest[offset + 0] = (byte)((value & 0xFF00000000000000L) >> 56);
-    }
-    
-    /**
-     * Returns the long value of the <code>valueIndex</code>-th value.
-     * @param valueIndex the index of the value.
-     * @throws InvalidTypeException if index is 0 as it is a string value.
-     */
-    private final long getValueAsLong(int valueIndex) throws InvalidTypeException {
-        switch (valueIndex) {
-            case 0:
-                throw new InvalidTypeException();
-            case 1:
-                return gcTime;
-            case 2:
-                return objectsFreed;
-            case 3:
-                return bytesFreed;
-            case 4:
-                return softLimit;
-            case 5:
-                return actualSize;
-            case 6:
-                return allowedSize;
-            case 7:
-                return objectsAllocated;
-            case 8:
-                return bytesAllocated;
-            case 9:
-                return actualSize - zActualSize;
-            case 10:
-                return allowedSize - zAllowedSize;
-            case 11:
-                return objectsAllocated - zObjectsAllocated;
-            case 12:
-                return bytesAllocated - zBytesAllocated;
-            case 13:
-               return zActualSize;
-            case 14:
-                return zAllowedSize;
-            case 15:
-                return zObjectsAllocated;
-            case 16:
-                return zBytesAllocated;
-            case 17:
-                return externalLimit;
-            case 18:
-                return externalBytesAllocated;
-            case 19:
-                return dlmallocFootprint;
-            case 20:
-                return mallinfoTotalAllocatedSpace;
-        }
-
-        throw new ArrayIndexOutOfBoundsException();
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidTypeException.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidTypeException.java
deleted file mode 100644
index 016f8aa..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidTypeException.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import java.io.Serializable;
-
-/**
- * Exception thrown when accessing an {@link EventContainer} value with the wrong type.
- */
-public final class InvalidTypeException extends Exception {
-
-    /**
-     * Needed by {@link Serializable}.
-     */
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * Constructs a new exception with the default detail message.
-     * @see java.lang.Exception
-     */
-    public InvalidTypeException() {
-        super("Invalid Type");
-    }
-
-    /**
-     * Constructs a new exception with the specified detail message.
-     * @param message the detail message. The detail message is saved for later retrieval
-     * by the {@link Throwable#getMessage()} method.
-     * @see java.lang.Exception
-     */
-    public InvalidTypeException(String message) {
-        super(message);
-    }
-
-    /**
-     * Constructs a new exception with the specified cause and a detail message of
-     * <code>(cause==null ? null : cause.toString())</code> (which typically contains
-     * the class and detail message of cause).
-     * @param cause the cause (which is saved for later retrieval by the
-     * {@link Throwable#getCause()} method). (A <code>null</code> value is permitted,
-     * and indicates that the cause is nonexistent or unknown.)
-     * @see java.lang.Exception
-     */
-    public InvalidTypeException(Throwable cause) {
-        super(cause);
-    }
-
-    /**
-     * Constructs a new exception with the specified detail message and cause.
-     * @param message the detail message. The detail message is saved for later retrieval
-     * by the {@link Throwable#getMessage()} method.
-     * @param cause the cause (which is saved for later retrieval by the
-     * {@link Throwable#getCause()} method). (A <code>null</code> value is permitted,
-     * and indicates that the cause is nonexistent or unknown.)
-     * @see java.lang.Exception
-     */
-    public InvalidTypeException(String message, Throwable cause) {
-        super(message, cause);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidValueTypeException.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidValueTypeException.java
deleted file mode 100644
index a3050c8..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/InvalidValueTypeException.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-import com.android.ddmlib.log.EventContainer.EventValueType;
-import com.android.ddmlib.log.EventValueDescription.ValueType;
-
-import java.io.Serializable;
-
-/**
- * Exception thrown when associating an {@link EventValueType} with an incompatible
- * {@link ValueType}.
- */
-public final class InvalidValueTypeException extends Exception {
-
-    /**
-     * Needed by {@link Serializable}.
-     */
-    private static final long serialVersionUID = 1L;
-
-    /**
-     * Constructs a new exception with the default detail message.
-     * @see java.lang.Exception
-     */
-    public InvalidValueTypeException() {
-        super("Invalid Type");
-    }
-
-    /**
-     * Constructs a new exception with the specified detail message.
-     * @param message the detail message. The detail message is saved for later retrieval
-     * by the {@link Throwable#getMessage()} method.
-     * @see java.lang.Exception
-     */
-    public InvalidValueTypeException(String message) {
-        super(message);
-    }
-
-    /**
-     * Constructs a new exception with the specified cause and a detail message of
-     * <code>(cause==null ? null : cause.toString())</code> (which typically contains
-     * the class and detail message of cause).
-     * @param cause the cause (which is saved for later retrieval by the
-     * {@link Throwable#getCause()} method). (A <code>null</code> value is permitted,
-     * and indicates that the cause is nonexistent or unknown.)
-     * @see java.lang.Exception
-     */
-    public InvalidValueTypeException(Throwable cause) {
-        super(cause);
-    }
-
-    /**
-     * Constructs a new exception with the specified detail message and cause.
-     * @param message the detail message. The detail message is saved for later retrieval
-     * by the {@link Throwable#getMessage()} method.
-     * @param cause the cause (which is saved for later retrieval by the
-     * {@link Throwable#getCause()} method). (A <code>null</code> value is permitted,
-     * and indicates that the cause is nonexistent or unknown.)
-     * @see java.lang.Exception
-     */
-    public InvalidValueTypeException(String message, Throwable cause) {
-        super(message, cause);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/LogReceiver.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/LogReceiver.java
deleted file mode 100644
index b49f025..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/log/LogReceiver.java
+++ /dev/null
@@ -1,247 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.log;
-
-
-import com.android.ddmlib.utils.ArrayHelper;
-
-import java.security.InvalidParameterException;
-
-/**
- * Receiver able to provide low level parsing for device-side log services.
- */
-public final class LogReceiver {
-
-    private final static int ENTRY_HEADER_SIZE = 20; // 2*2 + 4*4; see LogEntry.
-
-    /**
-     * Represents a log entry and its raw data.
-     */
-    public final static class LogEntry {
-        /*
-         * See //device/include/utils/logger.h
-         */
-        /** 16bit unsigned: length of the payload. */
-        public int  len; /* This is normally followed by a 16 bit padding */
-        /** pid of the process that generated this {@link LogEntry} */
-        public int   pid;
-        /** tid of the process that generated this {@link LogEntry} */
-        public int   tid;
-        /** Seconds since epoch. */
-        public int   sec;
-        /** nanoseconds. */
-        public int   nsec;
-        /** The entry's raw data. */
-        public byte[] data;
-    };
-
-    /**
-     * Classes which implement this interface provide a method that deals
-     * with {@link LogEntry} objects coming from log service through a {@link LogReceiver}.
-     * <p/>This interface provides two methods.
-     * <ul>
-     * <li>{@link #newEntry(com.android.ddmlib.log.LogReceiver.LogEntry)} provides a
-     * first level of parsing, extracting {@link LogEntry} objects out of the log service output.</li>
-     * <li>{@link #newData(byte[], int, int)} provides a way to receive the raw information
-     * coming directly from the log service.</li>
-     * </ul>
-     */
-    public interface ILogListener {
-        /**
-         * Sent when a new {@link LogEntry} has been parsed by the {@link LogReceiver}.
-         * @param entry the new log entry.
-         */
-        public void newEntry(LogEntry entry);
-        
-        /**
-         * Sent when new raw data is coming from the log service.
-         * @param data the raw data buffer.
-         * @param offset the offset into the buffer signaling the beginning of the new data.
-         * @param length the length of the new data.
-         */
-        public void newData(byte[] data, int offset, int length);
-    }
-
-    /** Current {@link LogEntry} being read, before sending it to the listener. */
-    private LogEntry mCurrentEntry;
-
-    /** Temp buffer to store partial entry headers. */
-    private byte[] mEntryHeaderBuffer = new byte[ENTRY_HEADER_SIZE];
-    /** Offset in the partial header buffer */
-    private int mEntryHeaderOffset = 0;
-    /** Offset in the partial entry data */
-    private int mEntryDataOffset = 0;
-    
-    /** Listener waiting for receive fully read {@link LogEntry} objects */
-    private ILogListener mListener;
-
-    private boolean mIsCancelled = false;
-    
-    /**
-     * Creates a {@link LogReceiver} with an {@link ILogListener}.
-     * <p/>
-     * The {@link ILogListener} will receive new log entries as they are parsed, in the form 
-     * of {@link LogEntry} objects.
-     * @param listener the listener to receive new log entries.
-     */
-    public LogReceiver(ILogListener listener) {
-        mListener = listener;
-    }
-    
-
-    /**
-     * Parses new data coming from the log service.
-     * @param data the data buffer
-     * @param offset the offset into the buffer signaling the beginning of the new data.
-     * @param length the length of the new data.
-     */
-    public void parseNewData(byte[] data, int offset, int length) {
-        // notify the listener of new raw data
-        if (mListener != null) {
-            mListener.newData(data, offset, length);
-        }
-
-        // loop while there is still data to be read and the receiver has not be cancelled.
-        while (length > 0 && mIsCancelled == false) {
-            // first check if we have no current entry.
-            if (mCurrentEntry == null) {
-                if (mEntryHeaderOffset + length < ENTRY_HEADER_SIZE) {
-                    // if we don't have enough data to finish the header, save
-                    // the data we have and return
-                    System.arraycopy(data, offset, mEntryHeaderBuffer, mEntryHeaderOffset, length);
-                    mEntryHeaderOffset += length;
-                    return;
-                } else {
-                    // we have enough to fill the header, let's do it.
-                    // did we store some part at the beginning of the header?
-                    if (mEntryHeaderOffset != 0) {
-                        // copy the rest of the entry header into the header buffer
-                        int size = ENTRY_HEADER_SIZE - mEntryHeaderOffset; 
-                        System.arraycopy(data, offset, mEntryHeaderBuffer, mEntryHeaderOffset,
-                                size);
-                        
-                        // create the entry from the header buffer
-                        mCurrentEntry = createEntry(mEntryHeaderBuffer, 0);
-    
-                        // since we used the whole entry header buffer, we reset  the offset
-                        mEntryHeaderOffset = 0;
-                        
-                        // adjust current offset and remaining length to the beginning
-                        // of the entry data
-                        offset += size;
-                        length -= size;
-                    } else {
-                        // create the entry directly from the data array
-                        mCurrentEntry = createEntry(data, offset);
-                        
-                        // adjust current offset and remaining length to the beginning
-                        // of the entry data
-                        offset += ENTRY_HEADER_SIZE;
-                        length -= ENTRY_HEADER_SIZE;
-                    }
-                }
-            }
-            
-            // at this point, we have an entry, and offset/length have been updated to skip
-            // the entry header.
-    
-            // if we have enough data for this entry or more, we'll need to end this entry
-            if (length >= mCurrentEntry.len - mEntryDataOffset) {
-                // compute and save the size of the data that we have to read for this entry,
-                // based on how much we may already have read.
-                int dataSize = mCurrentEntry.len - mEntryDataOffset;  
-    
-                // we only read what we need, and put it in the entry buffer.
-                System.arraycopy(data, offset, mCurrentEntry.data, mEntryDataOffset, dataSize);
-                
-                // notify the listener of a new entry
-                if (mListener != null) {
-                    mListener.newEntry(mCurrentEntry);
-                }
-    
-                // reset some flags: we have read 0 data of the current entry.
-                // and we have no current entry being read.
-                mEntryDataOffset = 0;
-                mCurrentEntry = null;
-                
-                // and update the data buffer info to the end of the current entry / start
-                // of the next one.
-                offset += dataSize;
-                length -= dataSize;
-            } else {
-                // we don't have enough data to fill this entry, so we store what we have
-                // in the entry itself.
-                System.arraycopy(data, offset, mCurrentEntry.data, mEntryDataOffset, length);
-                
-                // save the amount read for the data.
-                mEntryDataOffset += length;
-                return;
-            }
-        }
-    }
-
-    /**
-     * Returns whether this receiver is canceling the remote service.
-     */
-    public boolean isCancelled() {
-        return mIsCancelled;
-    }
-    
-    /**
-     * Cancels the current remote service.
-     */
-    public void cancel() {
-        mIsCancelled = true;
-    }
-    
-    /**
-     * Creates a {@link LogEntry} from the array of bytes. This expects the data buffer size
-     * to be at least <code>offset + {@link #ENTRY_HEADER_SIZE}</code>.
-     * @param data the data buffer the entry is read from.
-     * @param offset the offset of the first byte from the buffer representing the entry.
-     * @return a new {@link LogEntry} or <code>null</code> if some error happened.
-     */
-    private LogEntry createEntry(byte[] data, int offset) {
-        if (data.length < offset + ENTRY_HEADER_SIZE) {
-            throw new InvalidParameterException(
-                    "Buffer not big enough to hold full LoggerEntry header");
-        }
-
-        // create the new entry and fill it.
-        LogEntry entry = new LogEntry();
-        entry.len = ArrayHelper.swapU16bitFromArray(data, offset);
-        
-        // we've read only 16 bits, but since there's also a 16 bit padding,
-        // we can skip right over both.
-        offset += 4;
-        
-        entry.pid = ArrayHelper.swap32bitFromArray(data, offset);
-        offset += 4;
-        entry.tid = ArrayHelper.swap32bitFromArray(data, offset);
-        offset += 4;
-        entry.sec = ArrayHelper.swap32bitFromArray(data, offset);
-        offset += 4;
-        entry.nsec = ArrayHelper.swap32bitFromArray(data, offset);
-        offset += 4;
-        
-        // allocate the data
-        entry.data = new byte[entry.len];
-        
-        return entry;
-    }
-    
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/ITestRunListener.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/ITestRunListener.java
deleted file mode 100644
index 4c0d9de..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/ITestRunListener.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.testrunner;
-
-/**
- * Listener for instrumentation test runs
- * 
- * Modeled after junit.runner.TestRunListener
- */
-public interface ITestRunListener {
-    public static final int STATUS_ERROR = 1;
-    public static final int STATUS_FAILURE = 2;
-
-    /** 
-     * Reports the start of a test run 
-     * @param testCount - total number of tests in test run
-     * */
-    public void testRunStarted(int testCount);
-    
-    /**
-     * Reports end of test run
-     * @param elapsedTime - device reported elapsed time, in milliseconds
-     */
-    public void testRunEnded(long elapsedTime);
-
-    /**
-     * Reports test run stopped before completion
-     * @param elapsedTime - device reported elapsed time, in milliseconds
-     */
-    public void testRunStopped(long elapsedTime);
-
-    /**
-     * Reports the start of an individual test case
-     */
-    public void testStarted(String className, String testName);
-
-    /**
-     * Reports the execution end of an individual test case
-     * If no testFailed has been reported, this is a passed test
-     */
-    public void testEnded(String className, String testName);
-
-    /**
-     * Reports the failure of a individual test case
-     * Will be called between testStarted and testEnded
-     * 
-     * @param status - one of STATUS_ERROR, STATUS_FAILURE
-     * @param className - name of test class
-     * @param testName - name of test method
-     * @param trace - stack trace of failure
-     */
-    public void testFailed(int status, String className, String testName, String trace);
-    
-    /** 
-     * Reports test run failed to execute due to a fatal error 
-     */
-    public void testRunFailed(String errorMessage);
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/InstrumentationResultParser.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/InstrumentationResultParser.java
deleted file mode 100755
index d47bd56..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/InstrumentationResultParser.java
+++ /dev/null
@@ -1,327 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.testrunner;
-
-import com.android.ddmlib.IShellOutputReceiver;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.MultiLineReceiver;
-
-import java.util.Hashtable;
-import java.util.Map;
-
-/**
- * Parses the 'raw output mode' results of an instrument test run from shell, and informs a 
- * ITestRunListener of the results
- * 
- * Expects the following output:
- * 
- * If fatal error occurred when attempted to run the tests:
- * <i> INSTRUMENTATION_FAILED: </i>  
- * 
- * Otherwise, expect a series of test results, each one containing a set of status key/value
- * pairs, delimited by a start(1)/pass(0)/fail(-2)/error(-1) status code result. At end of test 
- * run, expects that the elapsed test time in seconds will be displayed  
- * 
- * i.e.
- * <i>
- * INSTRUMENTATION_STATUS_CODE: 1
- * INSTRUMENTATION_STATUS: class=com.foo.FooTest
- * INSTRUMENTATION_STATUS: test=testFoo
- * INSTRUMENTATION_STATUS: numtests=2
- * INSTRUMENTATION_STATUS: stack=com.foo.FooTest#testFoo:312
- *    com.foo.X
- * INSTRUMENTATION_STATUS_CODE: -2   
- * ... 
- * 
- * Time: X
- * </i>
- * 
- * Note that the "value" portion of the key-value pair may wrap over several text lines
- */
-public class InstrumentationResultParser extends MultiLineReceiver {
-    
-    // relevant test status keys
-    private static final String CODE_KEY = "code";
-    private static final String TEST_KEY = "test";
-    private static final String CLASS_KEY = "class";
-    private static final String STACK_KEY = "stack";
-    private static final String NUMTESTS_KEY = "numtests";
-    
-    // test result status codes
-    private static final int FAILURE_STATUS_CODE = -2;
-    private static final int START_STATUS_CODE = 1;
-    private static final int ERROR_STATUS_CODE = -1;
-    private static final int OK_STATUS_CODE = 0;
-
-    // recognized output patterns
-    private static final String STATUS_PREFIX = "INSTRUMENTATION_STATUS: ";
-    private static final String STATUS_PREFIX_CODE = "INSTRUMENTATION_STATUS_CODE: ";
-    private static final String STATUS_FAILED = "INSTRUMENTATION_FAILED: ";
-    private static final String TIME_REPORT = "Time: ";
-    
-    private final ITestRunListener mTestListener;
-    /** key-value map for current test */
-    private Map<String, String> mStatusValues;
-    /** stores the current "key" portion of the status key-value being parsed */
-    private String mCurrentKey;
-    /** stores the current "value" portion of the status key-value being parsed */
-    private StringBuilder mCurrentValue;
-    /** true if start of test has already been reported to listener */
-    private boolean mTestStartReported;
-    /** the elapsed time of the test run, in ms */
-    private long mTestTime;
-    /** true if current test run has been canceled by user */
-    private boolean mIsCancelled;
-    
-    private static final String LOG_TAG = "InstrumentationResultParser";
-    
-    /**
-     * Creates the InstrumentationResultParser
-     * @param listener - listener to report results to. will be informed of test results as the 
-     * tests are executing
-     */
-    public InstrumentationResultParser(ITestRunListener listener) {
-        mStatusValues = new Hashtable<String, String>();
-        mCurrentKey = null;
-        setTrimLine(false);
-        mTestListener = listener;
-        mTestStartReported = false;
-        mTestTime = 0;
-        mIsCancelled = false;
-    }
-    
-    /**
-     * Processes the instrumentation test output from shell
-     * @see MultiLineReceiver#processNewLines
-     */
-    @Override
-    public void processNewLines(String[] lines) {
-        for (String line : lines) {
-            parse(line);
-        }
-    }
-    
-    /**
-     * Parse an individual output line. Expects a line that either is:
-     * a) the start of a new status line (ie. starts with STATUS_PREFIX or STATUS_PREFIX_CODE), 
-     *    and thus there is a new key=value pair to parse, and the previous key-value pair is 
-     *    finished
-     * b) a continuation of the previous status (ie the "value" portion of the key has wrapped
-     *    to the next line. 
-     * c) a line reporting a fatal error in the test run (STATUS_FAILED)
-     * d) a line reporting the total elapsed time of the test run.  
-     *    
-     * @param line - text output line
-     */
-    private void parse(String line) {
-        if (line.startsWith(STATUS_PREFIX_CODE)) {
-            // Previous status key-value has been collected. Store it.
-            submitCurrentKeyValue();
-            parseStatusCode(line);
-        } else if (line.startsWith(STATUS_PREFIX)) {
-            // Previous status key-value has been collected. Store it.
-            submitCurrentKeyValue();
-            parseKey(line, STATUS_PREFIX.length());
-        } else if (line.startsWith(STATUS_FAILED)) {
-            Log.e(LOG_TAG, "test run failed " + line);
-            mTestListener.testRunFailed(line);
-        } else if (line.startsWith(TIME_REPORT)) {
-            parseTime(line, TIME_REPORT.length());
-        } else {
-            if (mCurrentValue != null) {
-                // this is a value that has wrapped to next line. 
-                mCurrentValue.append("\r\n");
-                mCurrentValue.append(line);
-            } else {
-                Log.w(LOG_TAG, "unrecognized line " + line);
-            }
-        }
-    }
-    
-    /**
-     * Stores the currently parsed key-value pair in the status map
-     */
-    private void submitCurrentKeyValue() {
-        if (mCurrentKey != null && mCurrentValue != null) {
-            mStatusValues.put(mCurrentKey, mCurrentValue.toString());
-            mCurrentKey = null;
-            mCurrentValue = null;
-        }
-    }
-    
-    /**
-     * Parses the key from the current line
-     * Expects format of "key=value",  
-     * @param line - full line of text to parse 
-     * @param keyStartPos - the starting position of the key in the given line
-     */
-    private void parseKey(String line, int keyStartPos) {
-        int endKeyPos = line.indexOf('=', keyStartPos);
-        if (endKeyPos != -1) {
-            mCurrentKey = line.substring(keyStartPos, endKeyPos).trim();
-            parseValue(line, endKeyPos+1);
-        }
-    }
-    
-    /**
-     * Parses the start of a key=value pair. 
-     * @param line - full line of text to parse 
-     * @param valueStartPos - the starting position of the value in the given line
-     */
-    private void parseValue(String line, int valueStartPos) {
-        mCurrentValue = new StringBuilder();
-        mCurrentValue.append(line.substring(valueStartPos));
-    }
-    
-    /**
-     * Parses out a status code result. For consistency, stores the result as a CODE entry in 
-     * key-value status map 
-     */
-    private void parseStatusCode(String line) {
-        String value = line.substring(STATUS_PREFIX_CODE.length()).trim();
-        mStatusValues.put(CODE_KEY, value);
-        
-        // this means we're done with current test result bundle
-        reportResult(mStatusValues);
-        mStatusValues.clear();
-    }
-    
-    /**
-     * Returns true if test run canceled
-     * 
-     * @see IShellOutputReceiver#isCancelled()
-     */
-    public boolean isCancelled() {
-        return mIsCancelled;
-    }
-    
-    /**
-     * Requests cancellation of test result parsing
-     */
-    public void cancel() {
-        mIsCancelled = true;
-    }
-    
-    /**
-     * Reports a test result to the test run listener. Must be called when a individual test
-     * result has been fully parsed. 
-     * @param statusMap - key-value status pairs of test result
-     */
-    private void reportResult(Map<String, String> statusMap) {
-        String className = statusMap.get(CLASS_KEY);
-        String testName = statusMap.get(TEST_KEY);
-        String statusCodeString = statusMap.get(CODE_KEY);
-        
-        if (className == null || testName == null || statusCodeString == null) {
-            Log.e(LOG_TAG, "invalid instrumentation status bundle " + statusMap.toString());
-            return;
-        }
-        className = className.trim();
-        testName = testName.trim();
-
-        reportTestStarted(statusMap);
-        
-        try {
-           int statusCode = Integer.parseInt(statusCodeString);
-           
-           switch (statusCode) {
-               case START_STATUS_CODE:
-                   mTestListener.testStarted(className, testName);
-                   break;
-               case FAILURE_STATUS_CODE:
-                   mTestListener.testFailed(ITestRunListener.STATUS_FAILURE, className, testName, 
-                           getTrace(statusMap));
-                   mTestListener.testEnded(className, testName);
-                   break;
-               case ERROR_STATUS_CODE:
-                   mTestListener.testFailed(ITestRunListener.STATUS_ERROR, className, testName, 
-                           getTrace(statusMap));
-                   mTestListener.testEnded(className, testName);
-                   break;
-               case OK_STATUS_CODE:
-                   mTestListener.testEnded(className, testName);
-                   break;
-               default:
-                   Log.e(LOG_TAG, "Expected status code, received: " + statusCodeString);
-                   mTestListener.testEnded(className, testName);
-                   break;
-           }
-        }
-        catch (NumberFormatException e) {
-           Log.e(LOG_TAG, "Expected integer status code, received: " + statusCodeString);    
-        }
-    }
-    
-    /**
-     * Reports the start of a test run, and the total test count, if it has not been previously 
-     * reported
-     * @param statusMap - key-value status pairs
-     */
-    private void reportTestStarted(Map<String, String> statusMap) {
-        // if start test run not reported yet
-        if (!mTestStartReported) {
-            String numTestsString = statusMap.get(NUMTESTS_KEY);
-            if (numTestsString != null) {
-                try {
-                    int numTests = Integer.parseInt(numTestsString);
-                    mTestListener.testRunStarted(numTests);
-                    mTestStartReported = true;
-                }
-                catch (NumberFormatException e) {
-                    Log.e(LOG_TAG, "Unexpected numTests format " + numTestsString);
-                }
-            }
-        }
-    }
-    
-    /**
-     * Returns the stack trace of the current failed test, from the provided key-value status map
-     */
-    private String getTrace(Map<String, String> statusMap) {
-        String stackTrace = statusMap.get(STACK_KEY);
-        if (stackTrace != null) {        
-            return stackTrace;    
-        }
-        else {
-            Log.e(LOG_TAG, "Could not find stack trace for failed test ");
-            return new Throwable("Unknown failure").toString();
-        }
-    }
-    
-    /**
-     * Parses out and store the elapsed time
-     */
-    private void parseTime(String line, int startPos) {
-        String timeString = line.substring(startPos);
-        try {
-            float timeSeconds = Float.parseFloat(timeString);
-            mTestTime = (long)(timeSeconds * 1000); 
-        }
-        catch (NumberFormatException e) {
-            Log.e(LOG_TAG, "Unexpected time format " + timeString);
-        }
-    }
-    
-    /**
-     * Called by parent when adb session is complete. 
-     */
-    @Override
-    public void done() {
-        super.done();
-        mTestListener.testRunEnded(mTestTime);
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunner.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunner.java
deleted file mode 100644
index 5de632e..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunner.java
+++ /dev/null
@@ -1,221 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.testrunner;
-
-
-import com.android.ddmlib.IDevice;
-import com.android.ddmlib.Log;
-
-import java.io.IOException;
-
-/**
- * Runs a Android test command remotely and reports results
- */
-public class RemoteAndroidTestRunner  {
-
-    private static final char CLASS_SEPARATOR = ',';
-    private static final char METHOD_SEPARATOR = '#';
-    private static final char RUNNER_SEPARATOR = '/';
-    private String mClassArg;
-    private final String mPackageName;
-    private final  String mRunnerName;
-    private String mExtraArgs;
-    private boolean mLogOnlyMode;
-    private IDevice mRemoteDevice;
-    private InstrumentationResultParser mParser;
-
-    private static final String LOG_TAG = "RemoteAndroidTest";
-    private static final String DEFAULT_RUNNER_NAME = 
-        "android.test.InstrumentationTestRunner";
-    
-    /**
-     * Creates a remote android test runner.
-     * @param packageName - the Android application package that contains the tests to run 
-     * @param runnerName - the instrumentation test runner to execute. If null, will use default
-     *   runner 
-     * @param remoteDevice - the Android device to execute tests on
-     */
-    public RemoteAndroidTestRunner(String packageName, 
-                                   String runnerName,
-                                   IDevice remoteDevice) {
-        
-        mPackageName = packageName;
-        mRunnerName = runnerName;
-        mRemoteDevice = remoteDevice;  
-        mClassArg = null;
-        mExtraArgs = "";
-        mLogOnlyMode = false;
-    }
-    
-    /**
-     * Alternate constructor. Uses default instrumentation runner
-     * @param packageName - the Android application package that contains the tests to run 
-     * @param remoteDevice - the Android device to execute tests on
-     */
-    public RemoteAndroidTestRunner(String packageName, 
-                                   IDevice remoteDevice) {
-        this(packageName, null, remoteDevice);
-    }
-    
-    /**
-     * Returns the application package name
-     */
-    public String getPackageName() {
-        return mPackageName;
-    }
-
-    /**
-     * Returns the runnerName
-     */
-    public String getRunnerName() {
-        if (mRunnerName == null) {
-            return DEFAULT_RUNNER_NAME;
-        }
-        return mRunnerName;
-    }
-    
-    /**
-     * Returns the complete instrumentation component path 
-     */
-    private String getRunnerPath() {
-        return getPackageName() + RUNNER_SEPARATOR + getRunnerName();
-    }
-    
-    /**
-     * Sets to run only tests in this class
-     * Must be called before 'run'
-     * @param className - fully qualified class name (eg x.y.z)
-     */
-    public void setClassName(String className) {
-        mClassArg = className;
-    }
-
-    /**
-     * Sets to run only tests in the provided classes
-     * Must be called before 'run'
-     * If providing more than one class, requires a InstrumentationTestRunner that supports 
-     * the multiple class argument syntax 
-     * @param classNames - array of fully qualified class name (eg x.y.z)
-     */
-    public void setClassNames(String[] classNames) {
-        StringBuilder classArgBuilder = new StringBuilder();
-        
-        for (int i=0; i < classNames.length; i++) {
-            if (i != 0) {
-                classArgBuilder.append(CLASS_SEPARATOR);
-            }
-            classArgBuilder.append(classNames[i]);
-        }
-        mClassArg = classArgBuilder.toString();
-    }
-    
-    /**
-     * Sets to run only specified test method
-     * Must be called before 'run'
-     * @param className - fully qualified class name (eg x.y.z)
-     * @param testName - method name
-     */
-    public void setMethodName(String className, String testName) {
-        mClassArg = className + METHOD_SEPARATOR + testName;
-    }
-    
-    /**
-     * Sets extra arguments to include in instrumentation command.
-     * Must be called before 'run'
-     * @param instrumentationArgs - must not be null
-     */
-    public void setExtraArgs(String instrumentationArgs) {
-        if (instrumentationArgs == null) {
-            throw new IllegalArgumentException("instrumentationArgs cannot be null");
-        }
-        mExtraArgs = instrumentationArgs;  
-    }
-    
-    /**
-     * Returns the extra instrumentation arguments
-     */
-    public String getExtraArgs() {
-        return mExtraArgs;
-    }
-    
-    /**
-     * Sets this test run to log only mode - skips test execution
-     */
-    public void setLogOnly(boolean logOnly) {
-        mLogOnlyMode = logOnly;
-    }
-    
-    /**
-     * Execute this test run
-     * 
-     * @param listener - listener to report results to
-     */
-    public void run(ITestRunListener listener) {
-        final String runCaseCommandStr = "am instrument -w -r "
-            + getClassCmd() + " " + getLogCmd() + " " + getExtraArgs() + " " + getRunnerPath();
-        Log.d(LOG_TAG, runCaseCommandStr);
-        mParser = new InstrumentationResultParser(listener);
-        
-        try {
-            mRemoteDevice.executeShellCommand(runCaseCommandStr, mParser);
-        } catch (IOException e) {
-            Log.e(LOG_TAG, e);
-            listener.testRunFailed(e.toString());
-        }
-    }
-    
-    /**
-     * Requests cancellation of this test run
-     */
-    public void cancel() {
-        if (mParser != null) {
-            mParser.cancel();
-        }
-    }
-    
-    /**
-     * Returns the test class argument
-     */
-    private String getClassArg() {
-        return mClassArg;
-    }
-    
-    /**
-     * Returns the full instrumentation command which specifies the test classes to execute. 
-     * Returns an empty string if no classes were specified
-     */
-    private String getClassCmd() {
-        String classArg = getClassArg();
-        if (classArg != null) {
-            return "-e class " + classArg;
-        }
-        return "";
-    }
-
-    /**
-     * Returns the full command to enable log only mode - if specified. Otherwise returns an 
-     * empty string
-     */
-    private String getLogCmd() {
-        if (mLogOnlyMode) {
-            return "-e log true";
-        }
-        else {
-            return "";
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/utils/ArrayHelper.java b/tools/ddms/libs/ddmlib/src/com/android/ddmlib/utils/ArrayHelper.java
deleted file mode 100644
index 8167e5d..0000000
--- a/tools/ddms/libs/ddmlib/src/com/android/ddmlib/utils/ArrayHelper.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.utils;
-
-/**
- * Utility class providing array to int/long conversion for data received from devices through adb. 
- */
-public final class ArrayHelper {
-
-    /**
-     * Swaps an unsigned value around, and puts the result in an array that can be sent to a device.
-     * @param value The value to swap.
-     * @param dest the destination array
-     * @param offset the offset in the array where to put the swapped value.
-     *      Array length must be at least offset + 4
-     */
-    public static void swap32bitsToArray(int value, byte[] dest, int offset) {
-        dest[offset] = (byte)(value & 0x000000FF);
-        dest[offset + 1] = (byte)((value & 0x0000FF00) >> 8);
-        dest[offset + 2] = (byte)((value & 0x00FF0000) >> 16);
-        dest[offset + 3] = (byte)((value & 0xFF000000) >> 24);
-    }
-
-    /**
-     * Reads a signed 32 bit integer from an array coming from a device.
-     * @param value the array containing the int
-     * @param offset the offset in the array at which the int starts
-     * @return the integer read from the array
-     */
-    public static int swap32bitFromArray(byte[] value, int offset) {
-        int v = 0;
-        v |= ((int)value[offset]) & 0x000000FF;
-        v |= (((int)value[offset + 1]) & 0x000000FF) << 8;
-        v |= (((int)value[offset + 2]) & 0x000000FF) << 16;
-        v |= (((int)value[offset + 3]) & 0x000000FF) << 24;
-
-        return v;
-    }
-    
-    /**
-     * Reads an unsigned 16 bit integer from an array coming from a device,
-     * and returns it as an 'int'
-     * @param value the array containing the 16 bit int (2 byte).
-     * @param offset the offset in the array at which the int starts
-     *      Array length must be at least offset + 2
-     * @return the integer read from the array.
-     */
-    public static int swapU16bitFromArray(byte[] value, int offset) {
-        int v = 0;
-        v |= ((int)value[offset]) & 0x000000FF;
-        v |= (((int)value[offset + 1]) & 0x000000FF) << 8;
-
-        return v;
-    }
-    
-    /**
-     * Reads a signed 64 bit integer from an array coming from a device.
-     * @param value the array containing the int
-     * @param offset the offset in the array at which the int starts
-     *      Array length must be at least offset + 8
-     * @return the integer read from the array
-     */
-    public static long swap64bitFromArray(byte[] value, int offset) {
-        long v = 0;
-        v |= ((long)value[offset]) & 0x00000000000000FFL;
-        v |= (((long)value[offset + 1]) & 0x00000000000000FFL) << 8;
-        v |= (((long)value[offset + 2]) & 0x00000000000000FFL) << 16;
-        v |= (((long)value[offset + 3]) & 0x00000000000000FFL) << 24;
-        v |= (((long)value[offset + 4]) & 0x00000000000000FFL) << 32;
-        v |= (((long)value[offset + 5]) & 0x00000000000000FFL) << 40;
-        v |= (((long)value[offset + 6]) & 0x00000000000000FFL) << 48;
-        v |= (((long)value[offset + 7]) & 0x00000000000000FFL) << 56;
-
-        return v;
-    }
-}
diff --git a/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/InstrumentationResultParserTest.java b/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/InstrumentationResultParserTest.java
deleted file mode 100644
index 67f6198..0000000
--- a/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/InstrumentationResultParserTest.java
+++ /dev/null
@@ -1,246 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.testrunner;
-
-import junit.framework.TestCase;
-
-
-/**
- * Tests InstrumentationResultParser
- */
-public class InstrumentationResultParserTest extends TestCase {
-
-    private InstrumentationResultParser mParser;
-    private VerifyingTestResult mTestResult;
-
-    // static dummy test names to use for validation
-    private static final String CLASS_NAME = "com.test.FooTest";
-    private static final String TEST_NAME = "testFoo";
-    private static final String STACK_TRACE = "java.lang.AssertionFailedException";
-
-    /**
-     * @param name - test name
-     */
-    public InstrumentationResultParserTest(String name) {
-        super(name);
-    }
-
-    /**
-     * @see junit.framework.TestCase#setUp()
-     */
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        mTestResult = new VerifyingTestResult();
-        mParser = new InstrumentationResultParser(mTestResult);
-    }
-
-    /**
-     * Tests that the test run started and test start events is sent on first
-     * bundle received
-     */
-    public void testTestStarted() {
-        StringBuilder output = buildCommonResult();
-        addStartCode(output);
-
-        injectTestString(output.toString());
-        assertCommonAttributes();
-        assertEquals(0, mTestResult.mNumTestsRun);
-    }
-
-    /**
-     * Tests that a single successful test execution
-     */
-    public void testTestSuccess() {
-        StringBuilder output = buildCommonResult();
-        addStartCode(output);
-        addCommonStatus(output);
-        addSuccessCode(output);
-
-        injectTestString(output.toString());
-        assertCommonAttributes();
-        assertEquals(1, mTestResult.mNumTestsRun);
-        assertEquals(0, mTestResult.mTestStatus);
-    }
-
-    /**
-     * Test basic parsing of failed test case
-     */
-    public void testTestFailed() {
-        StringBuilder output = buildCommonResult();
-        addStartCode(output);
-        addCommonStatus(output);
-        addStackTrace(output);
-        addFailureCode(output);
-
-        injectTestString(output.toString());
-        assertCommonAttributes();
-
-        assertEquals(1, mTestResult.mNumTestsRun);
-        assertEquals(ITestRunListener.STATUS_FAILURE, mTestResult.mTestStatus);
-        assertEquals(STACK_TRACE, mTestResult.mTrace);
-    }
-    
-    /**
-     * Test basic parsing and conversion of time from output
-     */
-    public void testTimeParsing() {
-        final String timeString = "Time: 4.9";
-        injectTestString(timeString);
-        assertEquals(4900, mTestResult.mTestTime);
-    }
-
-    /**
-     * builds a common test result using TEST_NAME and TEST_CLASS
-     */
-    private StringBuilder buildCommonResult() {
-        StringBuilder output = new StringBuilder();
-        // add test start bundle
-        addCommonStatus(output);
-        addStatusCode(output, "1");
-        // add end test bundle, without status
-        addCommonStatus(output);
-        return output;
-    }
-
-    /**
-     * Adds common status results to the provided output
-     */
-    private void addCommonStatus(StringBuilder output) {
-        addStatusKey(output, "stream", "\r\n" + CLASS_NAME);
-        addStatusKey(output, "test", TEST_NAME);
-        addStatusKey(output, "class", CLASS_NAME);
-        addStatusKey(output, "current", "1");
-        addStatusKey(output, "numtests", "1");
-        addStatusKey(output, "id", "InstrumentationTestRunner");
-    }
-
-    /**
-     * Adds a stack trace status bundle to output
-     */
-    private void addStackTrace(StringBuilder output) {
-        addStatusKey(output, "stack", STACK_TRACE);
-
-    }
-
-    /**
-     * Helper method to add a status key-value bundle
-     */
-    private void addStatusKey(StringBuilder outputBuilder, String key,
-            String value) {
-        outputBuilder.append("INSTRUMENTATION_STATUS: ");
-        outputBuilder.append(key);
-        outputBuilder.append('=');
-        outputBuilder.append(value);
-        outputBuilder.append("\r\n");
-    }
-
-    private void addStartCode(StringBuilder outputBuilder) {
-        addStatusCode(outputBuilder, "1");
-    }
-
-    private void addSuccessCode(StringBuilder outputBuilder) {
-        addStatusCode(outputBuilder, "0");
-    }
-
-    private void addFailureCode(StringBuilder outputBuilder) {
-        addStatusCode(outputBuilder, "-2");
-    }
-
-    private void addStatusCode(StringBuilder outputBuilder, String value) {
-        outputBuilder.append("INSTRUMENTATION_STATUS_CODE: ");
-        outputBuilder.append(value);
-        outputBuilder.append("\r\n");
-    }
-
-    /**
-     * inject a test string into the result parser
-     * 
-     * @param result
-     */
-    private void injectTestString(String result) {
-        byte[] data = result.getBytes();
-        mParser.addOutput(data, 0, data.length);
-        mParser.flush();
-    }
-
-    private void assertCommonAttributes() {
-        assertEquals(CLASS_NAME, mTestResult.mSuiteName);
-        assertEquals(1, mTestResult.mTestCount);
-        assertEquals(TEST_NAME, mTestResult.mTestName);
-    }
-
-    /**
-     * A specialized test listener that stores a single test events
-     */
-    private class VerifyingTestResult implements ITestRunListener {
-
-        String mSuiteName;
-        int mTestCount;
-        int mNumTestsRun;
-        String mTestName;
-        long mTestTime;
-        int mTestStatus;
-        String mTrace;
-        boolean mStopped;
-
-        VerifyingTestResult() {
-            mNumTestsRun = 0;
-            mTestStatus = 0;
-            mStopped = false;
-        }
-
-        public void testEnded(String className, String testName) {
-            mNumTestsRun++;
-            assertEquals("Unexpected class name", mSuiteName, className);
-            assertEquals("Unexpected test ended", mTestName, testName);
-
-        }
-
-        public void testFailed(int status, String className, String testName,
-                String trace) {
-            mTestStatus = status;
-            mTrace = trace;
-            assertEquals("Unexpected class name", mSuiteName, className);
-            assertEquals("Unexpected test ended", mTestName, testName);
-        }
-
-        public void testRunEnded(long elapsedTime) {
-            mTestTime = elapsedTime;
-
-        }
-
-        public void testRunStarted(int testCount) {
-            mTestCount = testCount;
-        }
-
-        public void testRunStopped(long elapsedTime) {
-            mTestTime = elapsedTime;
-            mStopped = true;
-        }
-
-        public void testStarted(String className, String testName) {
-            mSuiteName = className;
-            mTestName = testName;
-        }
-
-        public void testRunFailed(String errorMessage) {
-            // ignored
-        }
-    }
-
-}
diff --git a/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunnerTest.java b/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunnerTest.java
deleted file mode 100644
index 54ffae8..0000000
--- a/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib/testrunner/RemoteAndroidTestRunnerTest.java
+++ /dev/null
@@ -1,244 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmlib.testrunner;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.FileListingService;
-import com.android.ddmlib.IDevice;
-import com.android.ddmlib.IShellOutputReceiver;
-import com.android.ddmlib.RawImage;
-import com.android.ddmlib.SyncService;
-import com.android.ddmlib.Device.DeviceState;
-import com.android.ddmlib.log.LogReceiver;
-
-import junit.framework.TestCase;
-
-import java.io.IOException;
-import java.util.Map;
-
-/**
- * Test RemoteAndroidTestRunner. 
- */
-public class RemoteAndroidTestRunnerTest extends TestCase {
-
-    private RemoteAndroidTestRunner mRunner;
-    private MockDevice mMockDevice;
-    
-    private static final String TEST_PACKAGE = "com.test";
-    private static final String TEST_RUNNER = "com.test.InstrumentationTestRunner";
-    
-    /**
-     * @see junit.framework.TestCase#setUp()
-     */
-    @Override
-    protected void setUp() throws Exception {
-        mMockDevice = new MockDevice();
-        mRunner = new RemoteAndroidTestRunner(TEST_PACKAGE, TEST_RUNNER, mMockDevice);
-    }
-    
-    /**
-     * Test the basic case building of the instrumentation runner command with no arguments
-     */
-    public void testRun() {
-        mRunner.run(new EmptyListener());
-        assertStringsEquals(String.format("am instrument -w -r %s/%s", TEST_PACKAGE, TEST_RUNNER), 
-                mMockDevice.getLastShellCommand());
-    }
-
-    /**
-     * Test the building of the instrumentation runner command with log set
-     */
-    public void testRunWithLog() {
-        mRunner.setLogOnly(true);
-        mRunner.run(new EmptyListener());
-        assertStringsEquals(String.format("am instrument -w -r -e log true %s/%s", TEST_PACKAGE, 
-                TEST_RUNNER), mMockDevice.getLastShellCommand());
-    }
-
-    /**
-     * Test the building of the instrumentation runner command with method set
-     */
-    public void testRunWithMethod() {
-        final String className = "FooTest";
-        final String testName = "fooTest";
-        mRunner.setMethodName(className, testName);
-        mRunner.run(new EmptyListener());
-        assertStringsEquals(String.format("am instrument -w -r -e class %s#%s %s/%s", className, 
-                testName, TEST_PACKAGE, TEST_RUNNER), mMockDevice.getLastShellCommand());
-    }
-    
-    /**
-     * Test the building of the instrumentation runner command with extra args set
-     */
-    public void testRunWithExtraArgs() {
-        final String extraArgs = "blah";
-        mRunner.setExtraArgs(extraArgs);
-        mRunner.run(new EmptyListener());
-        assertStringsEquals(String.format("am instrument -w -r %s %s/%s", extraArgs,
-                TEST_PACKAGE, TEST_RUNNER), mMockDevice.getLastShellCommand());
-    }
-
-
-    /**
-     * Assert two strings are equal ignoring whitespace
-     */
-    private void assertStringsEquals(String str1, String str2) {
-        String strippedStr1 = str1.replaceAll(" ", "");
-        String strippedStr2 = str2.replaceAll(" ", "");
-        assertEquals(strippedStr1, strippedStr2);
-    }
-    
-    /**
-     * A dummy device that does nothing except store the provided executed shell command for 
-     * later retrieval
-     */
-    private static class MockDevice implements IDevice {
-
-        private String mLastShellCommand;
-        
-        /**
-         * Stores the provided command for later retrieval from getLastShellCommand
-         */
-        public void executeShellCommand(String command,
-                IShellOutputReceiver receiver) throws IOException {
-            mLastShellCommand = command;
-        }
-        
-        /**
-         * Get the last command provided to executeShellCommand
-         */
-        public String getLastShellCommand() {
-            return mLastShellCommand;
-        }
-        
-        public boolean createForward(int localPort, int remotePort) {
-            throw new UnsupportedOperationException();
-        }
-
-        public Client getClient(String applicationName) {
-            throw new UnsupportedOperationException();
-        }
-
-        public String getClientName(int pid) {
-            throw new UnsupportedOperationException();
-        }
-
-        public Client[] getClients() {
-            throw new UnsupportedOperationException();
-        }
-
-        public FileListingService getFileListingService() {
-            throw new UnsupportedOperationException();
-        }
-
-        public Map<String, String> getProperties() {
-            throw new UnsupportedOperationException();
-        }
-
-        public String getProperty(String name) {
-            throw new UnsupportedOperationException();
-        }
-
-        public int getPropertyCount() {
-            throw new UnsupportedOperationException();
-        }
-
-        public RawImage getScreenshot() throws IOException {
-            throw new UnsupportedOperationException();
-        }
-
-        public String getSerialNumber() {
-            throw new UnsupportedOperationException();
-        }
-
-        public DeviceState getState() {
-            throw new UnsupportedOperationException();
-        }
-
-        public SyncService getSyncService() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean hasClients() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean isBootLoader() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean isEmulator() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean isOffline() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean isOnline() {
-            throw new UnsupportedOperationException();
-        }
-
-        public boolean removeForward(int localPort, int remotePort) {
-            throw new UnsupportedOperationException();
-        }
-
-        public void runEventLogService(LogReceiver receiver) throws IOException {
-            throw new UnsupportedOperationException();
-        }
-
-        public String getAvdName() {
-            return "";
-        }
-
-    }
-    
-    /** An empty implementation of TestRunListener
-     */
-    private static class EmptyListener implements ITestRunListener {
-
-        public void testEnded(String className, String testName) {
-            // ignore
-        }
-
-        public void testFailed(int status, String className, String testName,
-                String trace) {
-            // ignore
-        }
-
-        public void testRunEnded(long elapsedTime) {
-            // ignore
-        }
-
-        public void testRunFailed(String errorMessage) {
-            // ignore
-        }
-
-        public void testRunStarted(int testCount) {
-            // ignore
-        }
-
-        public void testRunStopped(long elapsedTime) {
-            // ignore
-        }
-
-        public void testStarted(String className, String testName) {
-            // ignore
-        }
-        
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/.classpath b/tools/ddms/libs/ddmuilib/.classpath
deleted file mode 100644
index ce7e7f0..0000000
--- a/tools/ddms/libs/ddmuilib/.classpath
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry excluding="Makefile|resources" kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmlib"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_SWT"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_JFREECHART"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/ddms/libs/ddmuilib/.project b/tools/ddms/libs/ddmuilib/.project
deleted file mode 100644
index 29cb2f2..0000000
--- a/tools/ddms/libs/ddmuilib/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ddmuilib</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/ddms/libs/ddmuilib/Android.mk b/tools/ddms/libs/ddmuilib/Android.mk
deleted file mode 100644
index 7059e5e..0000000
--- a/tools/ddms/libs/ddmuilib/Android.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DDMUILIB_LOCAL_DIR := $(call my-dir)
-include $(DDMUILIB_LOCAL_DIR)/src/Android.mk
diff --git a/tools/ddms/libs/ddmuilib/README b/tools/ddms/libs/ddmuilib/README
deleted file mode 100644
index d66b84a..0000000
--- a/tools/ddms/libs/ddmuilib/README
+++ /dev/null
@@ -1,11 +0,0 @@
-Using the Eclipse projects for ddmuilib.
-
-ddmuilib requires SWT to compile.
-
-SWT is available in the depot under prebuild/<platform>/swt
-
-Because the build path cannot contain relative path that are not inside the project directory,
-the .classpath file references a user library called ANDROID_SWT.
-
-In order to compile the project, make a user library called ANDROID_SWT containing the jar
-available at prebuild/<platform>/swt.
\ No newline at end of file
diff --git a/tools/ddms/libs/ddmuilib/src/Android.mk b/tools/ddms/libs/ddmuilib/src/Android.mk
deleted file mode 100644
index acbda44..0000000
--- a/tools/ddms/libs/ddmuilib/src/Android.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_JAVA_LIBRARIES := \
-	ddmlib \
-	swt \
-	org.eclipse.jface_3.2.0.I20060605-1400 \
-	org.eclipse.equinox.common_3.2.0.v20060603 \
-	org.eclipse.core.commands_3.2.0.I20060605-1400 \
-	jcommon-1.0.12 \
-	jfreechart-1.0.9 \
-	jfreechart-1.0.9-swt
-	
-LOCAL_MODULE := ddmuilib
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Addr2Line.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Addr2Line.java
deleted file mode 100644
index a2f12d5..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Addr2Line.java
+++ /dev/null
@@ -1,278 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.*;
-
-import java.io.BufferedOutputStream;
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.Collection;
-import java.util.HashMap;
-
-/**
- * Represents an addr2line process to get filename/method information from a
- * memory address.<br>
- * Each process can only handle one library, which should be provided when
- * creating a new process.<br>
- * <br>
- * The processes take some time to load as they need to parse the library files.
- * For this reason, processes cannot be manually started. Instead the class
- * keeps an internal list of processes and one asks for a process for a specific
- * library, using <code>getProcess(String library)<code>.<br></br>
- * Internally, the processes are started in pipe mode to be able to query them
- * with multiple addresses.
- */
-public class Addr2Line {
-
-    /**
-     * Loaded processes list. This is also used as a locking object for any
-     * methods dealing with starting/stopping/creating processes/querying for
-     * method.
-     */
-    private static final HashMap<String, Addr2Line> sProcessCache =
-            new HashMap<String, Addr2Line>();
-
-    /**
-     * byte array representing a carriage return. Used to push addresses in the
-     * process pipes.
-     */
-    private static final byte[] sCrLf = {
-        '\n'
-    };
-
-    /** Path to the library */
-    private String mLibrary;
-
-    /** the command line process */
-    private Process mProcess;
-
-    /** buffer to read the result of the command line process from */
-    private BufferedReader mResultReader;
-
-    /**
-     * output stream to provide new addresses to decode to the command line
-     * process
-     */
-    private BufferedOutputStream mAddressWriter;
-
-    /**
-     * Returns the instance of a Addr2Line process for the specified library.
-     * <br>The library should be in a format that makes<br>
-     * <code>$ANDROID_PRODUCT_OUT + "/symbols" + library</code> a valid file.
-     *
-     * @param library the library in which to look for addresses.
-     * @return a new Addr2Line object representing a started process, ready to
-     *         be queried for addresses. If any error happened when launching a
-     *         new process, <code>null</code> will be returned.
-     */
-    public static Addr2Line getProcess(final String library) {
-        // synchronize around the hashmap object
-        if (library != null) {
-            synchronized (sProcessCache) {
-                // look for an existing process
-                Addr2Line process = sProcessCache.get(library);
-
-                // if we don't find one, we create it
-                if (process == null) {
-                    process = new Addr2Line(library);
-
-                    // then we start it
-                    boolean status = process.start();
-
-                    if (status) {
-                        // if starting the process worked, then we add it to the
-                        // list.
-                        sProcessCache.put(library, process);
-                    } else {
-                        // otherwise we just drop the object, to return null
-                        process = null;
-                    }
-                }
-                // return the process
-                return process;
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Construct the object with a library name.
-     * <br>The library should be in a format that makes<br>
-     * <code>$ANDROID_PRODUCT_OUT + "/symbols" + library</code> a valid file.
-     *
-     * @param library the library in which to look for address.
-     */
-    private Addr2Line(final String library) {
-        mLibrary = library;
-    }
-
-    /**
-     * Starts the command line process.
-     *
-     * @return true if the process was started, false if it failed to start, or
-     *         if there was any other errors.
-     */
-    private boolean start() {
-        // because this is only called from getProcess() we know we don't need
-        // to synchronize this code.
-
-        // get the output directory.
-        String symbols = DdmUiPreferences.getSymbolDirectory();
-
-        // build the command line
-        String[] command = new String[5];
-        command[0] = DdmUiPreferences.getAddr2Line();
-        command[1] = "-C";
-        command[2] = "-f";
-        command[3] = "-e";
-        command[4] = symbols + mLibrary.replaceAll("libc\\.so", "libc_debug\\.so");
-
-        try {
-            // attempt to start the process
-            mProcess = Runtime.getRuntime().exec(command);
-
-            if (mProcess != null) {
-                // get the result reader
-                InputStreamReader is = new InputStreamReader(mProcess
-                        .getInputStream());
-                mResultReader = new BufferedReader(is);
-
-                // get the outstream to write the addresses
-                mAddressWriter = new BufferedOutputStream(mProcess
-                        .getOutputStream());
-
-                // check our streams are here
-                if (mResultReader == null || mAddressWriter == null) {
-                    // not here? stop the process and return false;
-                    mProcess.destroy();
-                    mProcess = null;
-                    return false;
-                }
-
-                // return a success
-                return true;
-            }
-
-        } catch (IOException e) {
-            // log the error
-            String msg = String.format(
-                    "Error while trying to start %1$s process for library %2$s",
-                    DdmUiPreferences.getAddr2Line(), mLibrary);
-            Log.e("ddm-Addr2Line", msg);
-
-            // drop the process just in case
-            if (mProcess != null) {
-                mProcess.destroy();
-                mProcess = null;
-            }
-        }
-
-        // we can be here either cause the allocation of mProcess failed, or we
-        // caught an exception
-        return false;
-    }
-
-    /**
-     * Stops the command line process.
-     */
-    public void stop() {
-        synchronized (sProcessCache) {
-            if (mProcess != null) {
-                // remove the process from the list
-                sProcessCache.remove(mLibrary);
-
-                // then stops the process
-                mProcess.destroy();
-
-                // set the reference to null.
-                // this allows to make sure another thread calling getAddress()
-                // will not query a stopped thread
-                mProcess = null;
-            }
-        }
-    }
-
-    /**
-     * Stops all current running processes.
-     */
-    public static void stopAll() {
-        // because of concurrent access (and our use of HashMap.values()), we
-        // can't rely on the synchronized inside stop(). We need to put one
-        // around the whole loop.
-        synchronized (sProcessCache) {
-            // just a basic loop on all the values in the hashmap and call to
-            // stop();
-            Collection<Addr2Line> col = sProcessCache.values();
-            for (Addr2Line a2l : col) {
-                a2l.stop();
-            }
-        }
-    }
-
-    /**
-     * Looks up an address and returns method name, source file name, and line
-     * number.
-     *
-     * @param addr the address to look up
-     * @return a BacktraceInfo object containing the method/filename/linenumber
-     *         or null if the process we stopped before the query could be
-     *         processed, or if an IO exception happened.
-     */
-    public NativeStackCallInfo getAddress(long addr) {
-        // even though we don't access the hashmap object, we need to
-        // synchronized on it to prevent
-        // another thread from stopping the process we're going to query.
-        synchronized (sProcessCache) {
-            // check the process is still alive/allocated
-            if (mProcess != null) {
-                // prepare to the write the address to the output buffer.
-
-                // first, conversion to a string containing the hex value.
-                String tmp = Long.toString(addr, 16);
-
-                try {
-                    // write the address to the buffer
-                    mAddressWriter.write(tmp.getBytes());
-
-                    // add CR-LF
-                    mAddressWriter.write(sCrLf);
-
-                    // flush it all.
-                    mAddressWriter.flush();
-
-                    // read the result. We need to read 2 lines
-                    String method = mResultReader.readLine();
-                    String source = mResultReader.readLine();
-
-                    // make the backtrace object and return it
-                    if (method != null && source != null) {
-                        return new NativeStackCallInfo(mLibrary, method, source);
-                    }
-                } catch (IOException e) {
-                    // log the error
-                    Log.e("ddms",
-                            "Error while trying to get information for addr: "
-                                    + tmp + " in library: " + mLibrary);
-                    // we'll return null later
-                }
-            }
-        }
-        return null;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/AllocationPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/AllocationPanel.java
deleted file mode 100644
index 45d45ff..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/AllocationPanel.java
+++ /dev/null
@@ -1,487 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.AllocationInfo;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.layout.FormLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Sash;
-import org.eclipse.swt.widgets.Table;
-
-/**
- * Base class for our information panels.
- */
-public class AllocationPanel extends TablePanel {
-
-    private final static String PREFS_ALLOC_COL_SIZE = "allocPanel.Col0"; //$NON-NLS-1$
-    private final static String PREFS_ALLOC_COL_CLASS = "allocPanel.Col1"; //$NON-NLS-1$
-    private final static String PREFS_ALLOC_COL_THREAD = "allocPanel.Col2"; //$NON-NLS-1$
-    private final static String PREFS_ALLOC_COL_TRACE_CLASS = "allocPanel.Col3"; //$NON-NLS-1$
-    private final static String PREFS_ALLOC_COL_TRACE_METHOD = "allocPanel.Col4"; //$NON-NLS-1$
-    
-    private final static String PREFS_ALLOC_SASH = "allocPanel.sash"; //$NON-NLS-1$
-
-    private static final String PREFS_STACK_COL_CLASS = "allocPanel.stack.col0"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_METHOD = "allocPanel.stack.col1"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_FILE = "allocPanel.stack.col2"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_LINE = "allocPanel.stack.col3"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_NATIVE = "allocPanel.stack.col4"; //$NON-NLS-1$
-    
-    private Composite mAllocationBase;
-    private Table mAllocationTable;
-    private TableViewer mAllocationViewer;
-
-    private StackTracePanel mStackTracePanel;
-    private Table mStackTraceTable;
-    private Button mEnableButton;
-    private Button mRequestButton;
-
-    /**
-     * Content Provider to display the allocations of a client.
-     * Expected input is a {@link Client} object, elements used in the table are of type
-     * {@link AllocationInfo}.
-     */
-    private static class AllocationContentProvider implements IStructuredContentProvider {
-        public Object[] getElements(Object inputElement) {
-            if (inputElement instanceof Client) {
-                AllocationInfo[] allocs = ((Client)inputElement).getClientData().getAllocations();
-                if (allocs != null) {
-                    return allocs;
-                }
-            }
-
-            return new Object[0];
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            // pass
-        }
-    }
-
-    /**
-     * A Label Provider to use with {@link AllocationContentProvider}. It expects the elements to be
-     * of type {@link AllocationInfo}.
-     */
-    private static class AllocationLabelProvider implements ITableLabelProvider {
-
-        public Image getColumnImage(Object element, int columnIndex) {
-            return null;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            if (element instanceof AllocationInfo) {
-                AllocationInfo alloc = (AllocationInfo)element;
-                switch (columnIndex) {
-                    case 0:
-                        return Integer.toString(alloc.getSize());
-                    case 1:
-                        return alloc.getAllocatedClass();
-                    case 2:
-                        return Short.toString(alloc.getThreadId());
-                    case 3:
-                        StackTraceElement[] traces = alloc.getStackTrace();
-                        if (traces.length > 0) {
-                            return traces[0].getClassName();
-                        }
-                        break;
-                    case 4:
-                        traces = alloc.getStackTrace();
-                        if (traces.length > 0) {
-                            return traces[0].getMethodName();
-                        }
-                        break;
-                }
-            }
-
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-
-    /**
-     * Create our control(s).
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        final IPreferenceStore store = DdmUiPreferences.getStore();
-
-        // base composite for selected client with enabled thread update.
-        mAllocationBase = new Composite(parent, SWT.NONE);
-        mAllocationBase.setLayout(new FormLayout());
-        
-        // table above the sash
-        Composite topParent = new Composite(mAllocationBase, SWT.NONE);
-        topParent.setLayout(new GridLayout(2, false));
-        
-        mEnableButton = new Button(topParent, SWT.PUSH);
-        mEnableButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                Client current = getCurrentClient();
-                int status = current.getClientData().getAllocationStatus();
-                if (status == ClientData.ALLOCATION_TRACKING_ON) {
-                    current.enableAllocationTracker(false);
-                } else {
-                    current.enableAllocationTracker(true);
-                }
-                current.requestAllocationStatus();
-            }
-        });
-
-        mRequestButton = new Button(topParent, SWT.PUSH);
-        mRequestButton.setText("Get Allocations");
-        mRequestButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                getCurrentClient().requestAllocationDetails();
-            }
-        });
-        
-        setUpButtons(false /* enabled */, ClientData.ALLOCATION_TRACKING_OFF /* trackingStatus */);
-
-        mAllocationTable = new Table(topParent, SWT.MULTI | SWT.FULL_SELECTION);
-        GridData gridData;
-        mAllocationTable.setLayoutData(gridData = new GridData(GridData.FILL_BOTH));
-        gridData.horizontalSpan = 2;
-        mAllocationTable.setHeaderVisible(true);
-        mAllocationTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(
-                mAllocationTable,
-                "Allocation Size",
-                SWT.RIGHT,
-                "888", //$NON-NLS-1$
-                PREFS_ALLOC_COL_SIZE, store);
-
-        TableHelper.createTableColumn(
-                mAllocationTable,
-                "Allocated Class",
-                SWT.LEFT,
-                "Allocated Class", //$NON-NLS-1$
-                PREFS_ALLOC_COL_CLASS, store);
-
-        TableHelper.createTableColumn(
-                mAllocationTable,
-                "Thread Id",
-                SWT.LEFT,
-                "999", //$NON-NLS-1$
-                PREFS_ALLOC_COL_THREAD, store);
-
-        TableHelper.createTableColumn(
-                mAllocationTable,
-                "Allocated in",
-                SWT.LEFT,
-                "utime", //$NON-NLS-1$
-                PREFS_ALLOC_COL_TRACE_CLASS, store);
-
-        TableHelper.createTableColumn(
-                mAllocationTable,
-                "Allocated in",
-                SWT.LEFT,
-                "utime", //$NON-NLS-1$
-                PREFS_ALLOC_COL_TRACE_METHOD, store);
-        
-        mAllocationViewer = new TableViewer(mAllocationTable);
-        mAllocationViewer.setContentProvider(new AllocationContentProvider());
-        mAllocationViewer.setLabelProvider(new AllocationLabelProvider());
-
-        mAllocationViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                AllocationInfo selectedAlloc = getAllocationSelection(event.getSelection());
-                updateAllocationStackTrace(selectedAlloc);
-            }
-        });
-        
-        // the separating sash
-        final Sash sash = new Sash(mAllocationBase, SWT.HORIZONTAL);
-        Color darkGray = parent.getDisplay().getSystemColor(SWT.COLOR_DARK_GRAY);
-        sash.setBackground(darkGray);
-        
-        // the UI below the sash
-        mStackTracePanel = new StackTracePanel();
-        mStackTraceTable = mStackTracePanel.createPanel(mAllocationBase,
-                PREFS_STACK_COL_CLASS,
-                PREFS_STACK_COL_METHOD,
-                PREFS_STACK_COL_FILE,
-                PREFS_STACK_COL_LINE,
-                PREFS_STACK_COL_NATIVE,
-                store);
-        
-        // now setup the sash.
-        // form layout data
-        FormData data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(sash, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        topParent.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        if (store != null && store.contains(PREFS_ALLOC_SASH)) {
-            sashData.top = new FormAttachment(0, store.getInt(PREFS_ALLOC_SASH));
-        } else {
-            sashData.top = new FormAttachment(50,0); // 50% across
-        }
-        sashData.left = new FormAttachment(0, 0);
-        sashData.right = new FormAttachment(100, 0);
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(sash, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        mStackTraceTable.setLayoutData(data);
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = mAllocationBase.getClientArea();
-                int bottom = panelRect.height - sashRect.height - 100;
-                e.y = Math.max(Math.min(e.y, bottom), 100);
-                if (e.y != sashRect.y) {
-                    sashData.top = new FormAttachment(0, e.y);
-                    store.setValue(PREFS_ALLOC_SASH, e.y);
-                    mAllocationBase.layout();
-                }
-            }
-        });
-
-        return mAllocationBase;
-    }
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mAllocationTable.setFocus();
-    }
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        if (client == getCurrentClient()) {
-            if ((changeMask & Client.CHANGE_HEAP_ALLOCATIONS) != 0) {
-                try {
-                    mAllocationTable.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            mAllocationViewer.refresh();
-                            updateAllocationStackCall();
-                        }
-                    });
-                } catch (SWTException e) {
-                    // widget is disposed, we do nothing
-                }
-            } else if ((changeMask & Client.CHANGE_HEAP_ALLOCATION_STATUS) != 0) {
-                try {
-                    mAllocationTable.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            setUpButtons(true, client.getClientData().getAllocationStatus());
-                        }
-                    });
-                } catch (SWTException e) {
-                    // widget is disposed, we do nothing
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}.
-     */
-    @Override
-    public void deviceSelected() {
-        // pass
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-        if (mAllocationTable.isDisposed()) {
-            return;
-        }
-
-        Client client = getCurrentClient();
-        
-        mStackTracePanel.setCurrentClient(client);
-        mStackTracePanel.setViewerInput(null); // always empty on client selection change.
-
-        if (client != null) {
-            setUpButtons(true /* enabled */, client.getClientData().getAllocationStatus());
-        } else {
-            setUpButtons(false /* enabled */,
-                    ClientData.ALLOCATION_TRACKING_OFF /* trackingStatus */);
-        }
-
-        mAllocationViewer.setInput(client);
-    }
-    
-    /**
-     * Updates the stack call of the currently selected thread.
-     * <p/>
-     * This <b>must</b> be called from the UI thread.
-     */
-    private void updateAllocationStackCall() {
-        Client client = getCurrentClient();
-        if (client != null) {
-            // get the current selection in the ThreadTable
-            AllocationInfo selectedAlloc = getAllocationSelection(null);
-            
-            if (selectedAlloc != null) {
-                updateAllocationStackTrace(selectedAlloc);
-            } else {
-                updateAllocationStackTrace(null);
-            }
-        }
-    }
-
-    /**
-     * updates the stackcall of the specified allocation. If <code>null</code> the UI is emptied
-     * of current data.
-     * @param thread
-     */
-    private void updateAllocationStackTrace(AllocationInfo alloc) {
-        mStackTracePanel.setViewerInput(alloc);
-    }
-
-    @Override
-    protected void setTableFocusListener() {
-        addTableToFocusListener(mAllocationTable);
-        addTableToFocusListener(mStackTraceTable);
-    }
-
-    /**
-     * Returns the current allocation selection or <code>null</code> if none is found.
-     * If a {@link ISelection} object is specified, the first {@link AllocationInfo} from this
-     * selection is returned, otherwise, the <code>ISelection</code> returned by
-     * {@link TableViewer#getSelection()} is used.
-     * @param selection the {@link ISelection} to use, or <code>null</code>
-     */
-    private AllocationInfo getAllocationSelection(ISelection selection) {
-        if (selection == null) {
-            selection = mAllocationViewer.getSelection();
-        }
-        
-        if (selection instanceof IStructuredSelection) {
-            IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-            Object object = structuredSelection.getFirstElement();
-            if (object instanceof AllocationInfo) {
-                return (AllocationInfo)object;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * 
-     * @param enabled
-     * @param trackingStatus
-     */
-    private void setUpButtons(boolean enabled, int trackingStatus) {
-        if (enabled) {
-            switch (trackingStatus) {
-                case ClientData.ALLOCATION_TRACKING_UNKNOWN:
-                    mEnableButton.setText("?");
-                    mEnableButton.setEnabled(false);
-                    mRequestButton.setEnabled(false);
-                    break;
-                case ClientData.ALLOCATION_TRACKING_OFF:
-                    mEnableButton.setText("Start Tracking");
-                    mEnableButton.setEnabled(true);
-                    mRequestButton.setEnabled(false);
-                    break;
-                case ClientData.ALLOCATION_TRACKING_ON:
-                    mEnableButton.setText("Stop Tracking");
-                    mEnableButton.setEnabled(true);
-                    mRequestButton.setEnabled(true);
-                    break;
-            }
-        } else {
-            mEnableButton.setEnabled(false);
-            mRequestButton.setEnabled(false);
-            mEnableButton.setText("Start Tracking");
-        }
-    }
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BackgroundThread.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BackgroundThread.java
deleted file mode 100644
index 0ed4c95..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BackgroundThread.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Log;
-
-/**
- * base background thread class. The class provides a synchronous quit method
- * which sets a quitting flag to true. Inheriting classes should regularly test
- * this flag with <code>isQuitting()</code> and should finish if the flag is
- * true.
- */
-public abstract class BackgroundThread extends Thread {
-    private boolean mQuit = false;
-
-    /**
-     * Tell the thread to exit. This is usually called from the UI thread. The
-     * call is synchronous and will only return once the thread has terminated
-     * itself.
-     */
-    public final void quit() {
-        mQuit = true;
-        Log.d("ddms", "Waiting for BackgroundThread to quit");
-        try {
-            this.join();
-        } catch (InterruptedException ie) {
-            ie.printStackTrace();
-        }
-    }
-
-    /** returns if the thread was asked to quit. */
-    protected final boolean isQuitting() {
-        return mQuit;
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BaseHeapPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BaseHeapPanel.java
deleted file mode 100644
index 3e66ea5..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/BaseHeapPanel.java
+++ /dev/null
@@ -1,193 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.HeapSegment;
-import com.android.ddmlib.ClientData.HeapData;
-import com.android.ddmlib.HeapSegment.HeapSegmentElement;
-
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.PaletteData;
-
-import java.io.ByteArrayOutputStream;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.TreeMap;
-
-
-/**
- * Base Panel for heap panels.
- */
-public abstract class BaseHeapPanel extends TablePanel {
-
-    /** store the processed heap segment, so that we don't recompute Image for nothing */
-    protected byte[] mProcessedHeapData;
-    private Map<Integer, ArrayList<HeapSegmentElement>> mHeapMap;
-
-    /**
-     * Serialize the heap data into an array. The resulting array is available through
-     * <code>getSerializedData()</code>.
-     * @param heapData The heap data to serialize
-     * @return true if the data changed.
-     */
-    protected boolean serializeHeapData(HeapData heapData) {
-        Collection<HeapSegment> heapSegments;
-
-        // Atomically get and clear the heap data.
-        synchronized (heapData) {
-            // get the segments
-            heapSegments = heapData.getHeapSegments();
-            
-            
-            if (heapSegments != null) {
-                // if they are not null, we never processed them.
-                // Before we process then, we drop them from the HeapData
-                heapData.clearHeapData();
-
-                // process them into a linear byte[]
-                doSerializeHeapData(heapSegments);
-                heapData.setProcessedHeapData(mProcessedHeapData);
-                heapData.setProcessedHeapMap(mHeapMap);
-                
-            } else {
-                // the heap segments are null. Let see if the heapData contains a 
-                // list that is already processed.
-                
-                byte[] pixData = heapData.getProcessedHeapData();
-                
-                // and compare it to the one we currently have in the panel.
-                if (pixData == mProcessedHeapData) {
-                    // looks like its the same
-                    return false;
-                } else {
-                    mProcessedHeapData = pixData;
-                }
-                
-                Map<Integer, ArrayList<HeapSegmentElement>> heapMap =
-                    heapData.getProcessedHeapMap();
-                mHeapMap = heapMap;
-            }
-        }
-
-        return true;
-    }
-
-    /**
-     * Returns the serialized heap data
-     */
-    protected byte[] getSerializedData() {
-        return mProcessedHeapData;
-    }
-
-    /**
-     * Processes and serialize the heapData.
-     * <p/>
-     * The resulting serialized array is {@link #mProcessedHeapData}.
-     * <p/>
-     * the resulting map is {@link #mHeapMap}.
-     * @param heapData the collection of {@link HeapSegment} that forms the heap data.
-     */
-    private void doSerializeHeapData(Collection<HeapSegment> heapData) {
-        mHeapMap = new TreeMap<Integer, ArrayList<HeapSegmentElement>>();
-
-        Iterator<HeapSegment> iterator;
-        ByteArrayOutputStream out;
-
-        out = new ByteArrayOutputStream(4 * 1024);
-
-        iterator = heapData.iterator();
-        while (iterator.hasNext()) {
-            HeapSegment hs = iterator.next();
-
-            HeapSegmentElement e = null;
-            while (true) {
-                int v;
-
-                e = hs.getNextElement(null);
-                if (e == null) {
-                    break;
-                }
-                
-                if (e.getSolidity() == HeapSegmentElement.SOLIDITY_FREE) {
-                    v = 1;
-                } else {
-                    v = e.getKind() + 2;
-                }
-                
-                // put the element in the map
-                ArrayList<HeapSegmentElement> elementList = mHeapMap.get(v);
-                if (elementList == null) {
-                    elementList = new ArrayList<HeapSegmentElement>();
-                    mHeapMap.put(v, elementList);
-                }
-                elementList.add(e);
-
-
-                int len = e.getLength() / 8;
-                while (len > 0) {
-                    out.write(v);
-                    --len;
-                }
-            }
-        }
-        mProcessedHeapData = out.toByteArray();
-        
-        // sort the segment element in the heap info.
-        Collection<ArrayList<HeapSegmentElement>> elementLists = mHeapMap.values();
-        for (ArrayList<HeapSegmentElement> elementList : elementLists) {
-            Collections.sort(elementList);
-        }
-    }
-    
-    /**
-     * Creates a linear image of the heap data.
-     * @param pixData
-     * @param h
-     * @param palette
-     * @return
-     */
-    protected ImageData createLinearHeapImage(byte[] pixData, int h, PaletteData palette) {
-        int w = pixData.length / h;
-        if (pixData.length % h != 0) {
-            w++;
-        }
-
-        // Create the heap image.
-        ImageData id = new ImageData(w, h, 8, palette);
-
-        int x = 0;
-        int y = 0;
-        for (byte b : pixData) {
-            if (b >= 0) {
-                id.setPixel(x, y, b);
-            }
-
-            y++;
-            if (y >= h) {
-                y = 0;
-                x++;
-            }
-        }
-
-        return id;
-    }
-
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ClientDisplayPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ClientDisplayPanel.java
deleted file mode 100644
index a711933..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ClientDisplayPanel.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-
-public abstract class ClientDisplayPanel extends SelectionDependentPanel
-        implements IClientChangeListener {
-
-    @Override
-    protected void postCreation() {
-        AndroidDebugBridge.addClientChangeListener(this);
-    }
-
-    public void dispose() {
-        AndroidDebugBridge.removeClientChangeListener(this);
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DdmUiPreferences.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DdmUiPreferences.java
deleted file mode 100644
index f832a4e..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DdmUiPreferences.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-
-/**
- * Preference entry point for ddmuilib. Allows the lib to access a preference
- * store (org.eclipse.jface.preference.IPreferenceStore) defined by the
- * application that includes the lib.
- */
-public final class DdmUiPreferences {
-
-    public static final int DEFAULT_THREAD_REFRESH_INTERVAL = 4;  // seconds
-
-    private static int sThreadRefreshInterval = DEFAULT_THREAD_REFRESH_INTERVAL;
-    
-    private static IPreferenceStore mStore;
-    
-    private static String sSymbolLocation =""; //$NON-NLS-1$
-    private static String sAddr2LineLocation =""; //$NON-NLS-1$
-    private static String sTraceviewLocation =""; //$NON-NLS-1$
-
-    public static void setStore(IPreferenceStore store) {
-        mStore = store;
-    }
-    
-    public static IPreferenceStore getStore() {
-        return mStore;
-    }
-
-    public static int getThreadRefreshInterval() {
-        return sThreadRefreshInterval;
-    }
-
-    public static void setThreadRefreshInterval(int port) {
-        sThreadRefreshInterval = port;
-    }
-    
-    static String getSymbolDirectory() {
-        return sSymbolLocation;
-    }
-
-    public static void setSymbolsLocation(String location) {
-        sSymbolLocation = location;
-    }
-
-    static String getAddr2Line() {
-        return sAddr2LineLocation;
-    }
-
-    public static void setAddr2LineLocation(String location) {
-        sAddr2LineLocation = location;
-    }
-
-    public static String getTraceview() {
-        return sTraceviewLocation;
-    }
-
-    public static void setTraceviewLocation(String location) {
-        sTraceviewLocation = location;
-    }
-
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DevicePanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DevicePanel.java
deleted file mode 100644
index 81b757e..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/DevicePanel.java
+++ /dev/null
@@ -1,744 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.DdmPreferences;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-import com.android.ddmlib.AndroidDebugBridge.IDebugBridgeChangeListener;
-import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener;
-import com.android.ddmlib.Device.DeviceState;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.TreePath;
-import org.eclipse.jface.viewers.TreeSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeColumn;
-import org.eclipse.swt.widgets.TreeItem;
-
-import java.util.ArrayList;
-
-/**
- * A display of both the devices and their clients.
- */
-public final class DevicePanel extends Panel implements IDebugBridgeChangeListener,
-        IDeviceChangeListener, IClientChangeListener {
-
-    private final static String PREFS_COL_NAME_SERIAL = "devicePanel.Col0"; //$NON-NLS-1$
-    private final static String PREFS_COL_PID_STATE = "devicePanel.Col1"; //$NON-NLS-1$
-    private final static String PREFS_COL_PORT_BUILD = "devicePanel.Col4"; //$NON-NLS-1$
-
-    private final static int DEVICE_COL_SERIAL = 0;
-    private final static int DEVICE_COL_STATE = 1;
-    // col 2, 3 not used.
-    private final static int DEVICE_COL_BUILD = 4;
-
-    private final static int CLIENT_COL_NAME = 0;
-    private final static int CLIENT_COL_PID = 1;
-    private final static int CLIENT_COL_THREAD = 2;
-    private final static int CLIENT_COL_HEAP = 3;
-    private final static int CLIENT_COL_PORT = 4;
-    
-    public final static int ICON_WIDTH = 16;
-    public final static String ICON_THREAD = "thread.png"; //$NON-NLS-1$
-    public final static String ICON_HEAP = "heap.png"; //$NON-NLS-1$
-    public final static String ICON_HALT = "halt.png"; //$NON-NLS-1$
-    public final static String ICON_GC = "gc.png"; //$NON-NLS-1$
-
-    private Device mCurrentDevice;
-    private Client mCurrentClient;
-    
-    private Tree mTree;
-    private TreeViewer mTreeViewer;
-
-    private Image mDeviceImage;
-    private Image mEmulatorImage;
-
-    private Image mThreadImage;
-    private Image mHeapImage;
-    private Image mWaitingImage;
-    private Image mDebuggerImage;
-    private Image mDebugErrorImage;
-
-    private final ArrayList<IUiSelectionListener> mListeners = new ArrayList<IUiSelectionListener>();
-    
-    private final ArrayList<Device> mDevicesToExpand = new ArrayList<Device>();
-
-    private IImageLoader mLoader;
-
-    private boolean mAdvancedPortSupport;
-
-    /**
-     * A Content provider for the {@link TreeViewer}.
-     * <p/>
-     * The input is a {@link AndroidDebugBridge}. First level elements are {@link Device} objects,
-     * and second level elements are {@link Client} object.
-     */
-    private class ContentProvider implements ITreeContentProvider {
-        public Object[] getChildren(Object parentElement) {
-            if (parentElement instanceof Device) {
-                return ((Device)parentElement).getClients();
-            }
-            return new Object[0];
-        }
-
-        public Object getParent(Object element) {
-            if (element instanceof Client) {
-                return ((Client)element).getDevice();
-            }
-            return null;
-        }
-
-        public boolean hasChildren(Object element) {
-            if (element instanceof Device) {
-                return ((Device)element).hasClients();
-            }
-
-            // Clients never have children.
-            return false;
-        }
-
-        public Object[] getElements(Object inputElement) {
-            if (inputElement instanceof AndroidDebugBridge) {
-                return ((AndroidDebugBridge)inputElement).getDevices();
-            }
-            return new Object[0];
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            // pass
-        }
-    }
-
-    /**
-     * A Label Provider for the {@link TreeViewer} in {@link DevicePanel}. It provides
-     * labels and images for {@link Device} and {@link Client} objects.
-     */
-    private class LabelProvider implements ITableLabelProvider {
-
-        public Image getColumnImage(Object element, int columnIndex) {
-            if (columnIndex == DEVICE_COL_SERIAL && element instanceof Device) {
-                Device device = (Device)element;
-                if (device.isEmulator()) {
-                    return mEmulatorImage;
-                }
-
-                return mDeviceImage;
-            } else if (element instanceof Client) {
-                Client client = (Client)element;
-                ClientData cd = client.getClientData();
-
-                switch (columnIndex) {
-                    case CLIENT_COL_NAME:
-                        switch (cd.getDebuggerConnectionStatus()) {
-                            case ClientData.DEBUGGER_DEFAULT:
-                                return null;
-                            case ClientData.DEBUGGER_WAITING:
-                                return mWaitingImage;
-                            case ClientData.DEBUGGER_ATTACHED:
-                                return mDebuggerImage;
-                            case ClientData.DEBUGGER_ERROR:
-                                return mDebugErrorImage;
-                        }
-                        return null;
-                    case CLIENT_COL_THREAD:
-                        if (client.isThreadUpdateEnabled()) {
-                            return mThreadImage;
-                        }
-                        return null;
-                    case CLIENT_COL_HEAP:
-                        if (client.isHeapUpdateEnabled()) {
-                            return mHeapImage;
-                        }
-                        return null;
-                }
-            }
-            return null;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            if (element instanceof Device) {
-                Device device = (Device)element;
-                switch (columnIndex) {
-                    case DEVICE_COL_SERIAL:
-                        return device.getSerialNumber();
-                    case DEVICE_COL_STATE:
-                        return getStateString(device);
-                    case DEVICE_COL_BUILD: {
-                        String version = device.getProperty(Device.PROP_BUILD_VERSION);
-                        if (version != null) {
-                            String debuggable = device.getProperty(Device.PROP_DEBUGGABLE);
-                            if (device.isEmulator()) {
-                                String avdName = device.getAvdName();
-                                if (avdName == null) {
-                                    avdName = "?"; // the device is probably not online yet, so
-                                                   // we don't know its AVD name just yet.
-                                }
-                                if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
-                                    return String.format("%1$s [%2$s, debug]", avdName,
-                                            version);
-                                } else {
-                                    return String.format("%1$s [%2$s]", avdName, version); //$NON-NLS-1$
-                                }
-                            } else {
-                                if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
-                                    return String.format("%1$s, debug", version);
-                                } else {
-                                    return String.format("%1$s", version); //$NON-NLS-1$
-                                }
-                            }
-                        } else {
-                            return "unknown";
-                        }
-                    }
-                }
-            } else if (element instanceof Client) {
-                Client client = (Client)element;
-                ClientData cd = client.getClientData();
-
-                switch (columnIndex) {
-                    case CLIENT_COL_NAME:
-                        String name = cd.getClientDescription();
-                        if (name != null) {
-                            return name;
-                        }
-                        return "?";
-                    case CLIENT_COL_PID:
-                        return Integer.toString(cd.getPid());
-                    case CLIENT_COL_PORT:
-                        if (mAdvancedPortSupport) {
-                            int port = client.getDebuggerListenPort();
-                            String portString = "?";
-                            if (port != 0) {
-                                portString = Integer.toString(port);
-                            }
-                            if (client.isSelectedClient()) {
-                                return String.format("%1$s / %2$d", portString, //$NON-NLS-1$
-                                        DdmPreferences.getSelectedDebugPort());
-                            }
-
-                            return portString;
-                        }
-                }
-            }
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-
-    /**
-     * Classes which implement this interface provide methods that deals
-     * with {@link Device} and {@link Client} selection changes coming from the ui.
-     */
-    public interface IUiSelectionListener {
-        /**
-         * Sent when a new {@link Device} and {@link Client} are selected.
-         * @param selectedDevice the selected device. If null, no devices are selected.
-         * @param selectedClient The selected client. If null, no clients are selected.
-         */
-        public void selectionChanged(Device selectedDevice, Client selectedClient);
-    }
-
-    /**
-     * Creates the {@link DevicePanel} object.
-     * @param loader
-     * @param advancedPortSupport if true the device panel will add support for selected client port
-     * and display the ports in the ui.
-     */
-    public DevicePanel(IImageLoader loader, boolean advancedPortSupport) {
-        mLoader = loader;
-        mAdvancedPortSupport = advancedPortSupport;
-    }
-
-    public void addSelectionListener(IUiSelectionListener listener) {
-        mListeners.add(listener);
-    }
-
-    public void removeSelectionListener(IUiSelectionListener listener) {
-        mListeners.remove(listener);
-    }
-
-    @Override
-    protected Control createControl(Composite parent) {
-        loadImages(parent.getDisplay(), mLoader);
-
-        parent.setLayout(new FillLayout());
-
-        // create the tree and its column
-        mTree = new Tree(parent, SWT.SINGLE | SWT.FULL_SELECTION);
-        mTree.setHeaderVisible(true);
-        mTree.setLinesVisible(true);
-
-        IPreferenceStore store = DdmUiPreferences.getStore();
-
-        TableHelper.createTreeColumn(mTree, "Name", SWT.LEFT,
-                "com.android.home", //$NON-NLS-1$
-                PREFS_COL_NAME_SERIAL, store);
-        TableHelper.createTreeColumn(mTree, "", SWT.LEFT, //$NON-NLS-1$
-                "Offline", //$NON-NLS-1$
-                PREFS_COL_PID_STATE, store);
-
-        TreeColumn col = new TreeColumn(mTree, SWT.NONE);
-        col.setWidth(ICON_WIDTH + 8);
-        col.setResizable(false);
-        col = new TreeColumn(mTree, SWT.NONE);
-        col.setWidth(ICON_WIDTH + 8);
-        col.setResizable(false);
-
-        TableHelper.createTreeColumn(mTree, "", SWT.LEFT, //$NON-NLS-1$
-                "9999-9999", //$NON-NLS-1$
-                PREFS_COL_PORT_BUILD, store);
-
-        // create the tree viewer
-        mTreeViewer = new TreeViewer(mTree);
-
-        // make the device auto expanded.
-        mTreeViewer.setAutoExpandLevel(TreeViewer.ALL_LEVELS);
-
-        // set up the content and label providers.
-        mTreeViewer.setContentProvider(new ContentProvider());
-        mTreeViewer.setLabelProvider(new LabelProvider());
-
-        mTree.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                notifyListeners();
-            }
-        });
-
-        return mTree;
-    }
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mTree.setFocus();
-    }
-
-    @Override
-    protected void postCreation() {
-        // ask for notification of changes in AndroidDebugBridge (a new one is created when
-        // adb is restarted from a different location), Device and Client objects.
-        AndroidDebugBridge.addDebugBridgeChangeListener(this);
-        AndroidDebugBridge.addDeviceChangeListener(this);
-        AndroidDebugBridge.addClientChangeListener(this);
-    }
-
-    public void dispose() {
-        AndroidDebugBridge.removeDebugBridgeChangeListener(this);
-        AndroidDebugBridge.removeDeviceChangeListener(this);
-        AndroidDebugBridge.removeClientChangeListener(this);
-    }
-
-    /**
-     * Returns the selected {@link Client}. May be null.
-     */
-    public Client getSelectedClient() {
-        return mCurrentClient;
-    }
-
-    /**
-     * Returns the selected {@link Device}. If a {@link Client} is selected, it returns the
-     * Device object containing the client.
-     */
-    public Device getSelectedDevice() {
-        return mCurrentDevice;
-    }
-
-    /**
-     * Kills the selected {@link Client} by sending its VM a halt command.
-     */
-    public void killSelectedClient() {
-        if (mCurrentClient != null) {
-            Client client = mCurrentClient;
-            
-            // reset the selection to the device.
-            TreePath treePath = new TreePath(new Object[] { mCurrentDevice });
-            TreeSelection treeSelection = new TreeSelection(treePath);
-            mTreeViewer.setSelection(treeSelection);
-
-            client.kill();
-        }
-    }
-    
-    /**
-     * Forces a GC on the selected {@link Client}.
-     */
-    public void forceGcOnSelectedClient() {
-        if (mCurrentClient != null) {
-            mCurrentClient.executeGarbageCollector();
-        }
-    }
-    
-    public void setEnabledHeapOnSelectedClient(boolean enable) {
-        if (mCurrentClient != null) {
-            mCurrentClient.setHeapUpdateEnabled(enable);
-        }
-    }
-    
-    public void setEnabledThreadOnSelectedClient(boolean enable) {
-        if (mCurrentClient != null) {
-            mCurrentClient.setThreadUpdateEnabled(enable);
-        }
-    }
-
-    /**
-     * Sent when a new {@link AndroidDebugBridge} is started.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param bridge the new {@link AndroidDebugBridge} object.
-     *
-     * @see IDebugBridgeChangeListener#serverChanged(AndroidDebugBridge)
-     */
-    public void bridgeChanged(final AndroidDebugBridge bridge) {
-        if (mTree.isDisposed() == false) {
-            exec(new Runnable() {
-                public void run() {
-                    if (mTree.isDisposed() == false) {
-                        // set up the data source.
-                        mTreeViewer.setInput(bridge);
-
-                        // notify the listener of a possible selection change.
-                        notifyListeners();
-                    } else {
-                        // tree is disposed, we need to do something.
-                        // lets remove ourselves from the listener.
-                        AndroidDebugBridge.removeDebugBridgeChangeListener(DevicePanel.this);
-                        AndroidDebugBridge.removeDeviceChangeListener(DevicePanel.this);
-                        AndroidDebugBridge.removeClientChangeListener(DevicePanel.this);
-                    }
-                }
-            });
-        }
-
-        // all current devices are obsolete
-        synchronized (mDevicesToExpand) {
-            mDevicesToExpand.clear();
-        }
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     *
-     * @see IDeviceChangeListener#deviceConnected(Device)
-     */
-    public void deviceConnected(Device device) {
-        exec(new Runnable() {
-            public void run() {
-                if (mTree.isDisposed() == false) {
-                    // refresh all
-                    mTreeViewer.refresh();
-
-                    // notify the listener of a possible selection change.
-                    notifyListeners();
-                } else {
-                    // tree is disposed, we need to do something.
-                    // lets remove ourselves from the listener.
-                    AndroidDebugBridge.removeDebugBridgeChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeDeviceChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeClientChangeListener(DevicePanel.this);
-                }
-            }
-        });
-
-        // if it doesn't have clients yet, it'll need to be manually expanded when it gets them.
-        if (device.hasClients() == false) {
-            synchronized (mDevicesToExpand) {
-                mDevicesToExpand.add(device);
-            }
-        }
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     *
-     * @see IDeviceChangeListener#deviceDisconnected(Device)
-     */
-    public void deviceDisconnected(Device device) {
-        deviceConnected(device);
-        
-        // just in case, we remove it from the list of devices to expand.
-        synchronized (mDevicesToExpand) {
-            mDevicesToExpand.remove(device);
-        }
-    }
-
-    /**
-     * Sent when a device data changed, or when clients are started/terminated on the device.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the device that was updated.
-     * @param changeMask the mask indicating what changed.
-     *
-     * @see IDeviceChangeListener#deviceChanged(Device)
-     */
-    public void deviceChanged(final Device device, int changeMask) {
-        boolean expand = false;
-        synchronized (mDevicesToExpand) {
-            int index = mDevicesToExpand.indexOf(device);
-            if (device.hasClients() && index != -1) {
-                mDevicesToExpand.remove(index);
-                expand = true;
-            }
-        }
-        
-        final boolean finalExpand = expand;
-
-        exec(new Runnable() {
-            public void run() {
-                if (mTree.isDisposed() == false) {
-                    // look if the current device is selected. This is done in case the current
-                    // client of this particular device was killed. In this case, we'll need to
-                    // manually reselect the device.
-                    
-                    Device selectedDevice = getSelectedDevice();
-
-                    // refresh the device
-                    mTreeViewer.refresh(device);
-                    
-                    // if the selected device was the changed device and the new selection is
-                    // empty, we reselect the device.
-                    if (selectedDevice == device && mTreeViewer.getSelection().isEmpty()) {
-                        mTreeViewer.setSelection(new TreeSelection(new TreePath(
-                                new Object[] { device })));
-                    }
-                    
-                    // notify the listener of a possible selection change.
-                    notifyListeners();
-                    
-                    if (finalExpand) {
-                        mTreeViewer.setExpandedState(device, true);
-                    }
-                } else {
-                    // tree is disposed, we need to do something.
-                    // lets remove ourselves from the listener.
-                    AndroidDebugBridge.removeDebugBridgeChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeDeviceChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeClientChangeListener(DevicePanel.this);
-                }
-            }
-        });
-    }
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO},
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, final int changeMask) {
-        exec(new Runnable() {
-            public void run() {
-                if (mTree.isDisposed() == false) {
-                    // refresh the client
-                    mTreeViewer.refresh(client);
-
-                    if ((changeMask & Client.CHANGE_DEBUGGER_INTEREST) ==
-                            Client.CHANGE_DEBUGGER_INTEREST &&
-                            client.getClientData().getDebuggerConnectionStatus() ==
-                                ClientData.DEBUGGER_WAITING) {
-                        // make sure the device is expanded. Normally the setSelection below
-                        // will auto expand, but the children of device may not already exist
-                        // at this time. Forcing an expand will make the TreeViewer create them.
-                        Device device = client.getDevice();
-                        if (mTreeViewer.getExpandedState(device) == false) {
-                            mTreeViewer.setExpandedState(device, true);
-                        }
-
-                        // create and set the selection
-                        TreePath treePath = new TreePath(new Object[] { device, client});
-                        TreeSelection treeSelection = new TreeSelection(treePath);
-                        mTreeViewer.setSelection(treeSelection);
-                        
-                        if (mAdvancedPortSupport) {
-                            client.setAsSelectedClient();
-                        }
-                        
-                        // notify the listener of a possible selection change.
-                        notifyListeners(device, client);
-                    }
-                } else {
-                    // tree is disposed, we need to do something.
-                    // lets remove ourselves from the listener.
-                    AndroidDebugBridge.removeDebugBridgeChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeDeviceChangeListener(DevicePanel.this);
-                    AndroidDebugBridge.removeClientChangeListener(DevicePanel.this);
-                }
-            }
-        });
-    }
-
-    private void loadImages(Display display, IImageLoader loader) {
-        if (mDeviceImage == null) {
-            mDeviceImage = ImageHelper.loadImage(loader, display, "device.png", //$NON-NLS-1$
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_RED));
-        }
-        if (mEmulatorImage == null) {
-            mEmulatorImage = ImageHelper.loadImage(loader, display,
-                    "emulator.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
-                    display.getSystemColor(SWT.COLOR_BLUE));
-        }
-        if (mThreadImage == null) {
-            mThreadImage = ImageHelper.loadImage(loader, display, ICON_THREAD,
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_YELLOW));
-        }
-        if (mHeapImage == null) {
-            mHeapImage = ImageHelper.loadImage(loader, display, ICON_HEAP,
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_BLUE));
-        }
-        if (mWaitingImage == null) {
-            mWaitingImage = ImageHelper.loadImage(loader, display,
-                    "debug-wait.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
-                    display.getSystemColor(SWT.COLOR_RED));
-        }
-        if (mDebuggerImage == null) {
-            mDebuggerImage = ImageHelper.loadImage(loader, display,
-                    "debug-attach.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
-                    display.getSystemColor(SWT.COLOR_GREEN));
-        }
-        if (mDebugErrorImage == null) {
-            mDebugErrorImage = ImageHelper.loadImage(loader, display,
-                    "debug-error.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
-                    display.getSystemColor(SWT.COLOR_RED));
-        }
-    }
-
-    /**
-     * Returns a display string representing the state of the device.
-     * @param d the device
-     */
-    private static String getStateString(Device d) {
-        DeviceState deviceState = d.getState();
-        if (deviceState == DeviceState.ONLINE) {
-            return "Online";
-        } else if (deviceState == DeviceState.OFFLINE) {
-            return "Offline";
-        } else if (deviceState == DeviceState.BOOTLOADER) {
-            return "Bootloader";
-        }
-
-        return "??";
-    }
-
-    /**
-     * Executes the {@link Runnable} in the UI thread.
-     * @param runnable the runnable to execute.
-     */
-    private void exec(Runnable runnable) {
-        try {
-            Display display = mTree.getDisplay();
-            display.asyncExec(runnable);
-        } catch (SWTException e) {
-            // tree is disposed, we need to do something. lets remove ourselves from the listener.
-            AndroidDebugBridge.removeDebugBridgeChangeListener(this);
-            AndroidDebugBridge.removeDeviceChangeListener(this);
-            AndroidDebugBridge.removeClientChangeListener(this);
-        }
-    }
-    
-    private void notifyListeners() {
-        // get the selection
-        TreeItem[] items = mTree.getSelection();
-
-        Client client = null;
-        Device device = null;
-
-        if (items.length == 1) {
-            Object object = items[0].getData();
-            if (object instanceof Client) {
-                client = (Client)object;
-                device = client.getDevice();
-            } else if (object instanceof Device) {
-                device = (Device)object;
-            }
-        }
-
-        notifyListeners(device, client);
-    }
-    
-    private void notifyListeners(Device selectedDevice, Client selectedClient) {
-        if (selectedDevice != mCurrentDevice || selectedClient != mCurrentClient) {
-            mCurrentDevice = selectedDevice;
-            mCurrentClient = selectedClient;
-        
-            for (IUiSelectionListener listener : mListeners) {
-                // notify the listener with a try/catch-all to make sure this thread won't die
-                // because of an uncaught exception before all the listeners were notified.
-                try {
-                    listener.selectionChanged(selectedDevice, selectedClient);
-                } catch (Exception e) {
-                }
-            }
-        }
-    }
-    
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/EmulatorControlPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/EmulatorControlPanel.java
deleted file mode 100644
index 5583760..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/EmulatorControlPanel.java
+++ /dev/null
@@ -1,1454 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.EmulatorConsole;
-import com.android.ddmlib.EmulatorConsole.GsmMode;
-import com.android.ddmlib.EmulatorConsole.GsmStatus;
-import com.android.ddmlib.EmulatorConsole.NetworkStatus;
-import com.android.ddmuilib.location.CoordinateControls;
-import com.android.ddmuilib.location.GpxParser;
-import com.android.ddmuilib.location.KmlParser;
-import com.android.ddmuilib.location.TrackContentProvider;
-import com.android.ddmuilib.location.TrackLabelProvider;
-import com.android.ddmuilib.location.TrackPoint;
-import com.android.ddmuilib.location.WayPoint;
-import com.android.ddmuilib.location.WayPointContentProvider;
-import com.android.ddmuilib.location.WayPointLabelProvider;
-import com.android.ddmuilib.location.GpxParser.Track;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Panel to control the emulator using EmulatorConsole objects.
- */
-public class EmulatorControlPanel extends SelectionDependentPanel {
-
-    // default location: Patio outside Charlie's
-    private final static double DEFAULT_LONGITUDE = -122.084095;
-    private final static double DEFAULT_LATITUDE = 37.422006;
-    
-    private final static String SPEED_FORMAT = "Speed: %1$dX";
-
-
-    /**
-     * Map between the display gsm mode and the internal tag used by the display.
-     */
-    private final static String[][] GSM_MODES = new String[][] {
-        { "unregistered", GsmMode.UNREGISTERED.getTag() },
-        { "home", GsmMode.HOME.getTag() },
-        { "roaming", GsmMode.ROAMING.getTag() },
-        { "searching", GsmMode.SEARCHING.getTag() },
-        { "denied", GsmMode.DENIED.getTag() },
-    };
-
-    private final static String[] NETWORK_SPEEDS = new String[] {
-        "Full",
-        "GSM",
-        "HSCSD",
-        "GPRS",
-        "EDGE",
-        "UMTS",
-        "HSDPA",
-    };
-
-    private final static String[] NETWORK_LATENCIES = new String[] {
-        "None",
-        "GPRS",
-        "EDGE",
-        "UMTS",
-    };
-    
-    private final static int[] PLAY_SPEEDS = new int[] { 1, 2, 5, 10, 20, 50 };
-
-    private final static String RE_PHONE_NUMBER = "^[+#0-9]+$"; //$NON-NLS-1$
-    private final static String PREFS_WAYPOINT_COL_NAME = "emulatorControl.waypoint.name"; //$NON-NLS-1$
-    private final static String PREFS_WAYPOINT_COL_LONGITUDE = "emulatorControl.waypoint.longitude"; //$NON-NLS-1$
-    private final static String PREFS_WAYPOINT_COL_LATITUDE = "emulatorControl.waypoint.latitude"; //$NON-NLS-1$
-    private final static String PREFS_WAYPOINT_COL_ELEVATION = "emulatorControl.waypoint.elevation"; //$NON-NLS-1$
-    private final static String PREFS_WAYPOINT_COL_DESCRIPTION = "emulatorControl.waypoint.desc"; //$NON-NLS-1$
-    private final static String PREFS_TRACK_COL_NAME = "emulatorControl.track.name"; //$NON-NLS-1$
-    private final static String PREFS_TRACK_COL_COUNT = "emulatorControl.track.count"; //$NON-NLS-1$
-    private final static String PREFS_TRACK_COL_FIRST = "emulatorControl.track.first"; //$NON-NLS-1$
-    private final static String PREFS_TRACK_COL_LAST = "emulatorControl.track.last"; //$NON-NLS-1$
-    private final static String PREFS_TRACK_COL_COMMENT = "emulatorControl.track.comment"; //$NON-NLS-1$
-
-    private IImageLoader mImageLoader;
-
-    private EmulatorConsole mEmulatorConsole;
-
-    private Composite mParent;
-
-    private Label mVoiceLabel;
-    private Combo mVoiceMode;
-    private Label mDataLabel;
-    private Combo mDataMode;
-    private Label mSpeedLabel;
-    private Combo mNetworkSpeed;
-    private Label mLatencyLabel;
-    private Combo mNetworkLatency;
-
-    private Label mNumberLabel;
-    private Text mPhoneNumber;
-
-    private Button mVoiceButton;
-    private Button mSmsButton;
-
-    private Label mMessageLabel;
-    private Text mSmsMessage;
-
-    private Button mCallButton;
-    private Button mCancelButton;
-
-    private TabFolder mLocationFolders;
-    
-    private Button mDecimalButton;
-    private Button mSexagesimalButton;
-    private CoordinateControls mLongitudeControls;
-    private CoordinateControls mLatitudeControls;
-    private Button mGpxUploadButton;
-    private Table mGpxWayPointTable;
-    private Table mGpxTrackTable;
-    private Button mKmlUploadButton;
-    private Table mKmlWayPointTable;
-
-    private Button mPlayGpxButton;
-    private Button mGpxBackwardButton;
-    private Button mGpxForwardButton;
-    private Button mGpxSpeedButton;
-    private Button mPlayKmlButton;
-    private Button mKmlBackwardButton;
-    private Button mKmlForwardButton;
-    private Button mKmlSpeedButton;
-
-    private Image mPlayImage;
-    private Image mPauseImage;
-
-    private Thread mPlayingThread;
-    private boolean mPlayingTrack;
-    private int mPlayDirection = 1;
-    private int mSpeed;
-    private int mSpeedIndex;
-    
-    private final SelectionAdapter mDirectionButtonAdapter = new SelectionAdapter() {
-        @Override
-        public void widgetSelected(SelectionEvent e) {
-            Button b = (Button)e.getSource();
-            if (b.getSelection() == false) {
-                // basically the button was unselected, which we don't allow.
-                // so we reselect it.
-                b.setSelection(true);
-                return;
-            }
-            
-            // now handle selection change.
-            if (b == mGpxForwardButton || b == mKmlForwardButton) {
-                mGpxBackwardButton.setSelection(false);
-                mGpxForwardButton.setSelection(true);
-                mKmlBackwardButton.setSelection(false);
-                mKmlForwardButton.setSelection(true);
-                mPlayDirection = 1;
-                
-            } else {
-                mGpxBackwardButton.setSelection(true);
-                mGpxForwardButton.setSelection(false);
-                mKmlBackwardButton.setSelection(true);
-                mKmlForwardButton.setSelection(false);
-                mPlayDirection = -1;
-            }
-        }
-    };
-    
-    private final SelectionAdapter mSpeedButtonAdapter = new SelectionAdapter() {
-        @Override
-        public void widgetSelected(SelectionEvent e) {
-            mSpeedIndex = (mSpeedIndex+1) % PLAY_SPEEDS.length;
-            mSpeed = PLAY_SPEEDS[mSpeedIndex];
-            
-            mGpxSpeedButton.setText(String.format(SPEED_FORMAT, mSpeed));
-            mGpxPlayControls.pack();
-            mKmlSpeedButton.setText(String.format(SPEED_FORMAT, mSpeed));
-            mKmlPlayControls.pack();
-            
-            if (mPlayingThread != null) {
-                mPlayingThread.interrupt();
-            }
-        } 
-     };
-    private Composite mKmlPlayControls;
-    private Composite mGpxPlayControls;
-
-    
-    public EmulatorControlPanel(IImageLoader imageLoader) {
-        mImageLoader = imageLoader;
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}
-     */
-    @Override
-    public void deviceSelected() {
-        handleNewDevice(getCurrentDevice());
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}
-     */
-    @Override
-    public void clientSelected() {
-        // pass
-    }
-
-    /**
-     * Creates a control capable of displaying some information.  This is
-     * called once, when the application is initializing, from the UI thread.
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mParent = parent;
-
-        final ScrolledComposite scollingParent = new ScrolledComposite(parent, SWT.V_SCROLL);
-        scollingParent.setExpandVertical(true);
-        scollingParent.setExpandHorizontal(true);
-        scollingParent.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        final Composite top = new Composite(scollingParent, SWT.NONE);
-        scollingParent.setContent(top);
-        top.setLayout(new GridLayout(1, false));
-
-        // set the resize for the scrolling to work (why isn't that done automatically?!?)
-        scollingParent.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Rectangle r = scollingParent.getClientArea();
-                scollingParent.setMinSize(top.computeSize(r.width, SWT.DEFAULT));
-            }
-        });
-        
-        createRadioControls(top);
-
-        createCallControls(top);
-        
-        createLocationControls(top);
-
-        doEnable(false);
-
-        top.layout();
-        Rectangle r = scollingParent.getClientArea();
-        scollingParent.setMinSize(top.computeSize(r.width, SWT.DEFAULT));
-
-        return scollingParent;
-    }
-
-    /**
-     * Create Radio (on/off/roaming, for voice/data) controls.
-     * @param top
-     */
-    private void createRadioControls(final Composite top) {
-        Group g1 = new Group(top, SWT.NONE);
-        g1.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        g1.setLayout(new GridLayout(2, false));
-        g1.setText("Telephony Status");
-
-        // the inside of the group is 2 composite so that all the column of the controls (mainly
-        // combos) have the same width, while not taking the whole screen width
-        Composite insideGroup = new Composite(g1, SWT.NONE);
-        GridLayout gl = new GridLayout(4, false);
-        gl.marginBottom = gl.marginHeight = gl.marginLeft = gl.marginRight = 0;
-        insideGroup.setLayout(gl);
-
-        mVoiceLabel = new Label(insideGroup, SWT.NONE);
-        mVoiceLabel.setText("Voice:");
-        mVoiceLabel.setAlignment(SWT.RIGHT);
-
-        mVoiceMode = new Combo(insideGroup, SWT.READ_ONLY);
-        mVoiceMode.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        for (String[] mode : GSM_MODES) {
-            mVoiceMode.add(mode[0]);
-        }
-        mVoiceMode.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setVoiceMode(mVoiceMode.getSelectionIndex());
-            }
-        });
-
-        mSpeedLabel = new Label(insideGroup, SWT.NONE);
-        mSpeedLabel.setText("Speed:");
-        mSpeedLabel.setAlignment(SWT.RIGHT);
-
-        mNetworkSpeed = new Combo(insideGroup, SWT.READ_ONLY);
-        mNetworkSpeed.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        for (String mode : NETWORK_SPEEDS) {
-            mNetworkSpeed.add(mode);
-        }
-        mNetworkSpeed.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setNetworkSpeed(mNetworkSpeed.getSelectionIndex());
-            }
-        });
-
-        mDataLabel = new Label(insideGroup, SWT.NONE);
-        mDataLabel.setText("Data:");
-        mDataLabel.setAlignment(SWT.RIGHT);
-
-        mDataMode = new Combo(insideGroup, SWT.READ_ONLY);
-        mDataMode.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        for (String[] mode : GSM_MODES) {
-            mDataMode.add(mode[0]);
-        }
-        mDataMode.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setDataMode(mDataMode.getSelectionIndex());
-            }
-        });
-
-        mLatencyLabel = new Label(insideGroup, SWT.NONE);
-        mLatencyLabel.setText("Latency:");
-        mLatencyLabel.setAlignment(SWT.RIGHT);
-
-        mNetworkLatency = new Combo(insideGroup, SWT.READ_ONLY);
-        mNetworkLatency.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        for (String mode : NETWORK_LATENCIES) {
-            mNetworkLatency.add(mode);
-        }
-        mNetworkLatency.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setNetworkLatency(mNetworkLatency.getSelectionIndex());
-            }
-        });
-
-        // now an empty label to take the rest of the width of the group
-        Label l = new Label(g1, SWT.NONE);
-        l.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-    }
-    
-    /**
-     * Create Voice/SMS call/hang up controls
-     * @param top
-     */
-    private void createCallControls(final Composite top) {
-        GridLayout gl;
-        Group g2 = new Group(top, SWT.NONE);
-        g2.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        g2.setLayout(new GridLayout(1, false));
-        g2.setText("Telephony Actions");
-
-        // horizontal composite for label + text field
-        Composite phoneComp = new Composite(g2, SWT.NONE);
-        phoneComp.setLayoutData(new GridData(GridData.FILL_BOTH));
-        gl = new GridLayout(2, false);
-        gl.marginBottom = gl.marginHeight = gl.marginLeft = gl.marginRight = 0;
-        phoneComp.setLayout(gl);
-
-        mNumberLabel = new Label(phoneComp, SWT.NONE);
-        mNumberLabel.setText("Incoming number:");
-
-        mPhoneNumber = new Text(phoneComp, SWT.BORDER | SWT.LEFT | SWT.SINGLE);
-        mPhoneNumber.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mPhoneNumber.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                // Reenable the widgets based on the content of the text.
-                // doEnable checks the validity of the phone number to enable/disable some
-                // widgets.
-                // Looks like we're getting a callback at creation time, so we can't
-                // suppose that we are enabled when the text is modified...
-                doEnable(mEmulatorConsole != null);
-            }
-        });
-
-        mVoiceButton = new Button(phoneComp, SWT.RADIO);
-        GridData gd = new GridData();
-        gd.horizontalSpan = 2;
-        mVoiceButton.setText("Voice");
-        mVoiceButton.setLayoutData(gd);
-        mVoiceButton.setEnabled(false);
-        mVoiceButton.setSelection(true);
-        mVoiceButton.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                doEnable(true);
-
-                if (mVoiceButton.getSelection()) {
-                    mCallButton.setText("Call");
-                } else {
-                    mCallButton.setText("Send");
-                }
-            }
-        });
-
-        mSmsButton = new Button(phoneComp, SWT.RADIO);
-        mSmsButton.setText("SMS");
-        gd = new GridData();
-        gd.horizontalSpan = 2;
-        mSmsButton.setLayoutData(gd);
-        mSmsButton.setEnabled(false);
-        // Since there are only 2 radio buttons, we can put a listener on only one (they
-        // are both called on select and unselect event.
-
-        mMessageLabel = new Label(phoneComp, SWT.NONE);
-        gd = new GridData();
-        gd.verticalAlignment = SWT.TOP;
-        mMessageLabel.setLayoutData(gd);
-        mMessageLabel.setText("Message:");
-        mMessageLabel.setEnabled(false);
-
-        mSmsMessage = new Text(phoneComp, SWT.BORDER | SWT.LEFT | SWT.MULTI | SWT.WRAP | SWT.V_SCROLL);
-        mSmsMessage.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.heightHint = 70;
-        mSmsMessage.setEnabled(false);
-
-        // composite to put the 2 buttons horizontally
-        Composite g2ButtonComp = new Composite(g2, SWT.NONE);
-        g2ButtonComp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        gl = new GridLayout(2, false);
-        gl.marginWidth = gl.marginHeight = 0;
-        g2ButtonComp.setLayout(gl);
-
-        // now a button below the phone number
-        mCallButton = new Button(g2ButtonComp, SWT.PUSH);
-        mCallButton.setText("Call");
-        mCallButton.setEnabled(false);
-        mCallButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mEmulatorConsole != null) {
-                    if (mVoiceButton.getSelection()) {
-                        processCommandResult(mEmulatorConsole.call(mPhoneNumber.getText().trim()));
-                    } else {
-                        // we need to encode the message. We need to replace the carriage return
-                        // character by the 2 character string \n.
-                        // Because of this the \ character needs to be escaped as well.
-                        // ReplaceAll() expects regexp so \ char are escaped twice.
-                        String message = mSmsMessage.getText();
-                        message = message.replaceAll("\\\\", //$NON-NLS-1$
-                                "\\\\\\\\"); //$NON-NLS-1$
-
-                        // While the normal line delimiter is returned by Text.getLineDelimiter()
-                        // it seems copy pasting text coming from somewhere else could have another
-                        // delimited. For this reason, we'll replace is several steps
-
-                        // replace the dual CR-LF
-                        message = message.replaceAll("\r\n", "\\\\n"); //$NON-NLS-1$ //$NON-NLS-1$
-
-                        // replace remaining stand alone \n
-                        message = message.replaceAll("\n", "\\\\n"); //$NON-NLS-1$ //$NON-NLS-1$
-
-                        // replace remaining stand alone \r
-                        message = message.replaceAll("\r", "\\\\n"); //$NON-NLS-1$ //$NON-NLS-1$
-
-                        processCommandResult(mEmulatorConsole.sendSms(mPhoneNumber.getText().trim(),
-                                message));
-                    }
-                }
-            }
-        });
-
-        mCancelButton = new Button(g2ButtonComp, SWT.PUSH);
-        mCancelButton.setText("Hang Up");
-        mCancelButton.setEnabled(false);
-        mCancelButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mEmulatorConsole != null) {
-                    if (mVoiceButton.getSelection()) {
-                        processCommandResult(mEmulatorConsole.cancelCall(
-                                mPhoneNumber.getText().trim()));
-                    }
-                }
-            }
-        });
-    }
-    
-    /**
-     * Create Location controls.
-     * @param top
-     */
-    private void createLocationControls(final Composite top) {
-        Label l = new Label(top, SWT.NONE);
-        l.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        l.setText("Location Controls");
-        
-        mLocationFolders = new TabFolder(top, SWT.NONE);
-        mLocationFolders.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        Composite manualLocationComp = new Composite(mLocationFolders, SWT.NONE);
-        TabItem item = new TabItem(mLocationFolders, SWT.NONE);
-        item.setText("Manual");
-        item.setControl(manualLocationComp);
-        
-        createManualLocationControl(manualLocationComp);
-
-        mPlayImage = mImageLoader.loadImage("play.png", mParent.getDisplay()); // $NON-NLS-1$
-        mPauseImage = mImageLoader.loadImage("pause.png", mParent.getDisplay()); // $NON-NLS-1$
-
-        Composite gpxLocationComp = new Composite(mLocationFolders, SWT.NONE);
-        item = new TabItem(mLocationFolders, SWT.NONE);
-        item.setText("GPX");
-        item.setControl(gpxLocationComp);
-        
-        createGpxLocationControl(gpxLocationComp);
-
-        Composite kmlLocationComp = new Composite(mLocationFolders, SWT.NONE);
-        kmlLocationComp.setLayout(new FillLayout());
-        item = new TabItem(mLocationFolders, SWT.NONE);
-        item.setText("KML");
-        item.setControl(kmlLocationComp);
-        
-        createKmlLocationControl(kmlLocationComp);
-    }
-
-    private void createManualLocationControl(Composite manualLocationComp) {
-        final StackLayout sl;
-        GridLayout gl;
-        Label label;
-
-        manualLocationComp.setLayout(new GridLayout(1, false));
-        mDecimalButton = new Button(manualLocationComp, SWT.RADIO);
-        mDecimalButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mDecimalButton.setText("Decimal");
-        mSexagesimalButton = new Button(manualLocationComp, SWT.RADIO);
-        mSexagesimalButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mSexagesimalButton.setText("Sexagesimal");
-
-        // composite to hold and switching between the 2 modes.
-        final Composite content = new Composite(manualLocationComp, SWT.NONE);
-        content.setLayout(sl = new StackLayout());
-        
-        // decimal display
-        final Composite decimalContent = new Composite(content, SWT.NONE);
-        decimalContent.setLayout(gl = new GridLayout(2, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        
-        mLongitudeControls = new CoordinateControls();
-        mLatitudeControls = new CoordinateControls();
-        
-        label = new Label(decimalContent, SWT.NONE);
-        label.setText("Longitude");
-        
-        mLongitudeControls.createDecimalText(decimalContent);
-        
-        label = new Label(decimalContent, SWT.NONE);
-        label.setText("Latitude");
-        
-        mLatitudeControls.createDecimalText(decimalContent);
-
-        // sexagesimal content
-        final Composite sexagesimalContent = new Composite(content, SWT.NONE);
-        sexagesimalContent.setLayout(gl = new GridLayout(7, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("Longitude");
-        
-        mLongitudeControls.createSexagesimalDegreeText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("\u00B0"); // degree character
-        
-        mLongitudeControls.createSexagesimalMinuteText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("'");
-
-        mLongitudeControls.createSexagesimalSecondText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("\"");
-
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("Latitude");
-        
-        mLatitudeControls.createSexagesimalDegreeText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("\u00B0");
-        
-        mLatitudeControls.createSexagesimalMinuteText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("'");
-
-        mLatitudeControls.createSexagesimalSecondText(sexagesimalContent);
-        
-        label = new Label(sexagesimalContent, SWT.NONE);
-        label.setText("\"");
-
-        // set the default display to decimal
-        sl.topControl = decimalContent;
-        mDecimalButton.setSelection(true);
-
-        mDecimalButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mDecimalButton.getSelection()) {
-                    sl.topControl = decimalContent;
-                } else {
-                    sl.topControl = sexagesimalContent;
-                }
-                content.layout();
-            }
-        });
-        
-        Button sendButton = new Button(manualLocationComp, SWT.PUSH);
-        sendButton.setText("Send");
-        sendButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mEmulatorConsole != null) {
-                    processCommandResult(mEmulatorConsole.sendLocation(
-                            mLongitudeControls.getValue(), mLatitudeControls.getValue(), 0));
-                }
-            }
-        });
-        
-        mLongitudeControls.setValue(DEFAULT_LONGITUDE);
-        mLatitudeControls.setValue(DEFAULT_LATITUDE);
-    }
-
-    private void createGpxLocationControl(Composite gpxLocationComp) {
-        GridData gd;
-
-        IPreferenceStore store = DdmUiPreferences.getStore();
-
-        gpxLocationComp.setLayout(new GridLayout(1, false));
-
-        mGpxUploadButton = new Button(gpxLocationComp, SWT.PUSH);
-        mGpxUploadButton.setText("Load GPX...");
-
-        // Table for way point
-        mGpxWayPointTable = new Table(gpxLocationComp,
-                SWT.V_SCROLL | SWT.H_SCROLL | SWT.FULL_SELECTION);
-        mGpxWayPointTable.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.heightHint = 100;
-        mGpxWayPointTable.setHeaderVisible(true);
-        mGpxWayPointTable.setLinesVisible(true);
-        
-        TableHelper.createTableColumn(mGpxWayPointTable, "Name", SWT.LEFT,
-                "Some Name",
-                PREFS_WAYPOINT_COL_NAME, store);
-        TableHelper.createTableColumn(mGpxWayPointTable, "Longitude", SWT.LEFT,
-                "-199.999999",
-                PREFS_WAYPOINT_COL_LONGITUDE, store);
-        TableHelper.createTableColumn(mGpxWayPointTable, "Latitude", SWT.LEFT,
-                "-199.999999",
-                PREFS_WAYPOINT_COL_LATITUDE, store);
-        TableHelper.createTableColumn(mGpxWayPointTable, "Elevation", SWT.LEFT,
-                "99999.9",
-                PREFS_WAYPOINT_COL_ELEVATION, store);
-        TableHelper.createTableColumn(mGpxWayPointTable, "Description", SWT.LEFT,
-                "Some Description",
-                PREFS_WAYPOINT_COL_DESCRIPTION, store);
-
-        final TableViewer gpxWayPointViewer = new TableViewer(mGpxWayPointTable);
-        gpxWayPointViewer.setContentProvider(new WayPointContentProvider());
-        gpxWayPointViewer.setLabelProvider(new WayPointLabelProvider());
-        
-        gpxWayPointViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                    Object selectedObject = structuredSelection.getFirstElement();
-                    if (selectedObject instanceof WayPoint) {
-                        WayPoint wayPoint = (WayPoint)selectedObject;
-                        
-                        if (mEmulatorConsole != null && mPlayingTrack == false) {
-                            processCommandResult(mEmulatorConsole.sendLocation(
-                                    wayPoint.getLongitude(), wayPoint.getLatitude(),
-                                    wayPoint.getElevation()));
-                        }
-                    }
-                }
-            }
-        });
-
-        // table for tracks.
-        mGpxTrackTable = new Table(gpxLocationComp,
-                SWT.V_SCROLL | SWT.H_SCROLL | SWT.FULL_SELECTION);
-        mGpxTrackTable.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.heightHint = 100;
-        mGpxTrackTable.setHeaderVisible(true);
-        mGpxTrackTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mGpxTrackTable, "Name", SWT.LEFT,
-                "Some very long name",
-                PREFS_TRACK_COL_NAME, store);
-        TableHelper.createTableColumn(mGpxTrackTable, "Point Count", SWT.RIGHT,
-                "9999",
-                PREFS_TRACK_COL_COUNT, store);
-        TableHelper.createTableColumn(mGpxTrackTable, "First Point Time", SWT.LEFT,
-                "999-99-99T99:99:99Z",
-                PREFS_TRACK_COL_FIRST, store);
-        TableHelper.createTableColumn(mGpxTrackTable, "Last Point Time", SWT.LEFT,
-                "999-99-99T99:99:99Z",
-                PREFS_TRACK_COL_LAST, store);
-        TableHelper.createTableColumn(mGpxTrackTable, "Comment", SWT.LEFT,
-                "-199.999999",
-                PREFS_TRACK_COL_COMMENT, store);
-
-        final TableViewer gpxTrackViewer = new TableViewer(mGpxTrackTable);
-        gpxTrackViewer.setContentProvider(new TrackContentProvider());
-        gpxTrackViewer.setLabelProvider(new TrackLabelProvider());
-        
-        gpxTrackViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                    Object selectedObject = structuredSelection.getFirstElement();
-                    if (selectedObject instanceof Track) {
-                        Track track = (Track)selectedObject;
-                        
-                        if (mEmulatorConsole != null && mPlayingTrack == false) {
-                            TrackPoint[] points = track.getPoints();
-                            processCommandResult(mEmulatorConsole.sendLocation(
-                                    points[0].getLongitude(), points[0].getLatitude(),
-                                    points[0].getElevation()));
-                        }
-                        
-                        mPlayGpxButton.setEnabled(true);
-                        mGpxBackwardButton.setEnabled(true);
-                        mGpxForwardButton.setEnabled(true);
-                        mGpxSpeedButton.setEnabled(true);
-                        
-                        return;
-                    }
-                }
-
-                mPlayGpxButton.setEnabled(false);
-                mGpxBackwardButton.setEnabled(false);
-                mGpxForwardButton.setEnabled(false);
-                mGpxSpeedButton.setEnabled(false);
-            }
-        });
-        
-        mGpxUploadButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.OPEN);
-
-                fileDialog.setText("Load GPX File");
-                fileDialog.setFilterExtensions(new String[] { "*.gpx" } );
-
-                String fileName = fileDialog.open();
-                if (fileName != null) {
-                    GpxParser parser = new GpxParser(fileName);
-                    if (parser.parse()) {
-                        gpxWayPointViewer.setInput(parser.getWayPoints());
-                        gpxTrackViewer.setInput(parser.getTracks());
-                    }
-                }
-            }
-        });
-        
-        mGpxPlayControls = new Composite(gpxLocationComp, SWT.NONE);
-        GridLayout gl;
-        mGpxPlayControls.setLayout(gl = new GridLayout(5, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        mGpxPlayControls.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mPlayGpxButton = new Button(mGpxPlayControls, SWT.PUSH | SWT.FLAT);
-        mPlayGpxButton.setImage(mPlayImage);
-        mPlayGpxButton.addSelectionListener(new SelectionAdapter() {
-           @Override
-            public void widgetSelected(SelectionEvent e) {
-               if (mPlayingTrack == false) {
-                   ISelection selection = gpxTrackViewer.getSelection();
-                   if (selection.isEmpty() == false && selection instanceof IStructuredSelection) {
-                       IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                       Object selectedObject = structuredSelection.getFirstElement();
-                       if (selectedObject instanceof Track) {
-                           Track track = (Track)selectedObject;
-                           playTrack(track);
-                       }
-                   }
-               } else {
-                   // if we're playing, then we pause
-                   mPlayingTrack = false;
-                   if (mPlayingThread != null) {
-                       mPlayingThread.interrupt();
-                   }
-               }
-            } 
-        });
-        
-        Label separator = new Label(mGpxPlayControls, SWT.SEPARATOR | SWT.VERTICAL);
-        separator.setLayoutData(gd = new GridData(
-                GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL));
-        gd.heightHint = 0;
-        
-        mGpxBackwardButton = new Button(mGpxPlayControls, SWT.TOGGLE | SWT.FLAT);
-        mGpxBackwardButton.setImage(mImageLoader.loadImage("backward.png", mParent.getDisplay())); // $NON-NLS-1$
-        mGpxBackwardButton.setSelection(false);
-        mGpxBackwardButton.addSelectionListener(mDirectionButtonAdapter);
-        mGpxForwardButton = new Button(mGpxPlayControls, SWT.TOGGLE | SWT.FLAT);
-        mGpxForwardButton.setImage(mImageLoader.loadImage("forward.png", mParent.getDisplay())); // $NON-NLS-1$
-        mGpxForwardButton.setSelection(true);
-        mGpxForwardButton.addSelectionListener(mDirectionButtonAdapter);
-
-        mGpxSpeedButton = new Button(mGpxPlayControls, SWT.PUSH | SWT.FLAT);
-
-        mSpeedIndex = 0;
-        mSpeed = PLAY_SPEEDS[mSpeedIndex];
-
-        mGpxSpeedButton.setText(String.format(SPEED_FORMAT, mSpeed));
-        mGpxSpeedButton.addSelectionListener(mSpeedButtonAdapter);
-        
-        mPlayGpxButton.setEnabled(false);
-        mGpxBackwardButton.setEnabled(false);
-        mGpxForwardButton.setEnabled(false);
-        mGpxSpeedButton.setEnabled(false);
-
-    }
-
-    private void createKmlLocationControl(Composite kmlLocationComp) {
-        GridData gd;
-
-        IPreferenceStore store = DdmUiPreferences.getStore();
-
-        kmlLocationComp.setLayout(new GridLayout(1, false));
-
-        mKmlUploadButton = new Button(kmlLocationComp, SWT.PUSH);
-        mKmlUploadButton.setText("Load KML...");
-
-        // Table for way point
-        mKmlWayPointTable = new Table(kmlLocationComp,
-                SWT.V_SCROLL | SWT.H_SCROLL | SWT.FULL_SELECTION);
-        mKmlWayPointTable.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.heightHint = 200;
-        mKmlWayPointTable.setHeaderVisible(true);
-        mKmlWayPointTable.setLinesVisible(true);
-        
-        TableHelper.createTableColumn(mKmlWayPointTable, "Name", SWT.LEFT,
-                "Some Name",
-                PREFS_WAYPOINT_COL_NAME, store);
-        TableHelper.createTableColumn(mKmlWayPointTable, "Longitude", SWT.LEFT,
-                "-199.999999",
-                PREFS_WAYPOINT_COL_LONGITUDE, store);
-        TableHelper.createTableColumn(mKmlWayPointTable, "Latitude", SWT.LEFT,
-                "-199.999999",
-                PREFS_WAYPOINT_COL_LATITUDE, store);
-        TableHelper.createTableColumn(mKmlWayPointTable, "Elevation", SWT.LEFT,
-                "99999.9",
-                PREFS_WAYPOINT_COL_ELEVATION, store);
-        TableHelper.createTableColumn(mKmlWayPointTable, "Description", SWT.LEFT,
-                "Some Description",
-                PREFS_WAYPOINT_COL_DESCRIPTION, store);
-
-        final TableViewer kmlWayPointViewer = new TableViewer(mKmlWayPointTable);
-        kmlWayPointViewer.setContentProvider(new WayPointContentProvider());
-        kmlWayPointViewer.setLabelProvider(new WayPointLabelProvider());
-
-        mKmlUploadButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.OPEN);
-
-                fileDialog.setText("Load KML File");
-                fileDialog.setFilterExtensions(new String[] { "*.kml" } );
-
-                String fileName = fileDialog.open();
-                if (fileName != null) {
-                    KmlParser parser = new KmlParser(fileName);
-                    if (parser.parse()) {
-                        kmlWayPointViewer.setInput(parser.getWayPoints());
-                        
-                        mPlayKmlButton.setEnabled(true);
-                        mKmlBackwardButton.setEnabled(true);
-                        mKmlForwardButton.setEnabled(true);
-                        mKmlSpeedButton.setEnabled(true);
-                    }
-                }
-            }
-        });
-        
-        kmlWayPointViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                    Object selectedObject = structuredSelection.getFirstElement();
-                    if (selectedObject instanceof WayPoint) {
-                        WayPoint wayPoint = (WayPoint)selectedObject;
-                        
-                        if (mEmulatorConsole != null && mPlayingTrack == false) {
-                            processCommandResult(mEmulatorConsole.sendLocation(
-                                    wayPoint.getLongitude(), wayPoint.getLatitude(),
-                                    wayPoint.getElevation()));
-                        }
-                    }
-                }
-            }
-        });
-        
-        
-        
-        mKmlPlayControls = new Composite(kmlLocationComp, SWT.NONE);
-        GridLayout gl;
-        mKmlPlayControls.setLayout(gl = new GridLayout(5, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        mKmlPlayControls.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mPlayKmlButton = new Button(mKmlPlayControls, SWT.PUSH | SWT.FLAT);
-        mPlayKmlButton.setImage(mPlayImage);
-        mPlayKmlButton.addSelectionListener(new SelectionAdapter() {
-           @Override
-            public void widgetSelected(SelectionEvent e) {
-               if (mPlayingTrack == false) {
-                   Object input = kmlWayPointViewer.getInput();
-                   if (input instanceof WayPoint[]) {
-                       playKml((WayPoint[])input);
-                   }
-               } else {
-                   // if we're playing, then we pause
-                   mPlayingTrack = false;
-                   if (mPlayingThread != null) {
-                       mPlayingThread.interrupt();
-                   }
-               }
-            } 
-        });
-        
-        Label separator = new Label(mKmlPlayControls, SWT.SEPARATOR | SWT.VERTICAL);
-        separator.setLayoutData(gd = new GridData(
-                GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL));
-        gd.heightHint = 0;
-        
-        mKmlBackwardButton = new Button(mKmlPlayControls, SWT.TOGGLE | SWT.FLAT);
-        mKmlBackwardButton.setImage(mImageLoader.loadImage("backward.png", mParent.getDisplay())); // $NON-NLS-1$
-        mKmlBackwardButton.setSelection(false);
-        mKmlBackwardButton.addSelectionListener(mDirectionButtonAdapter);
-        mKmlForwardButton = new Button(mKmlPlayControls, SWT.TOGGLE | SWT.FLAT);
-        mKmlForwardButton.setImage(mImageLoader.loadImage("forward.png", mParent.getDisplay())); // $NON-NLS-1$
-        mKmlForwardButton.setSelection(true);
-        mKmlForwardButton.addSelectionListener(mDirectionButtonAdapter);
-
-        mKmlSpeedButton = new Button(mKmlPlayControls, SWT.PUSH | SWT.FLAT);
-
-        mSpeedIndex = 0;
-        mSpeed = PLAY_SPEEDS[mSpeedIndex];
-
-        mKmlSpeedButton.setText(String.format(SPEED_FORMAT, mSpeed));
-        mKmlSpeedButton.addSelectionListener(mSpeedButtonAdapter);
-        
-        mPlayKmlButton.setEnabled(false);
-        mKmlBackwardButton.setEnabled(false);
-        mKmlForwardButton.setEnabled(false);
-        mKmlSpeedButton.setEnabled(false);
-    }
-
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-    }
-
-    @Override
-    protected void postCreation() {
-        // pass
-    }
-
-    private synchronized void setDataMode(int selectionIndex) {
-        if (mEmulatorConsole != null) {
-            processCommandResult(mEmulatorConsole.setGsmDataMode(
-                    GsmMode.getEnum(GSM_MODES[selectionIndex][1])));
-        }
-    }
-
-    private synchronized void setVoiceMode(int selectionIndex) {
-        if (mEmulatorConsole != null) {
-            processCommandResult(mEmulatorConsole.setGsmVoiceMode(
-                    GsmMode.getEnum(GSM_MODES[selectionIndex][1])));
-        }
-    }
-
-    private synchronized void setNetworkLatency(int selectionIndex) {
-        if (mEmulatorConsole != null) {
-            processCommandResult(mEmulatorConsole.setNetworkLatency(selectionIndex));
-        }
-    }
-
-    private synchronized void setNetworkSpeed(int selectionIndex) {
-        if (mEmulatorConsole != null) {
-            processCommandResult(mEmulatorConsole.setNetworkSpeed(selectionIndex));
-        }
-    }
-
-
-    /**
-     * Callback on device selection change.
-     * @param device the new selected device
-     */
-    public void handleNewDevice(Device device) {
-        if (mParent.isDisposed()) {
-            return;
-        }
-        // unlink to previous console.
-        synchronized (this) {
-            mEmulatorConsole = null;
-        }
-
-        try {
-            // get the emulator console for this device
-            // First we need the device itself
-            if (device != null) {
-                GsmStatus gsm = null;
-                NetworkStatus netstatus = null;
-
-                synchronized (this) {
-                    mEmulatorConsole = EmulatorConsole.getConsole(device);
-                    if (mEmulatorConsole != null) {
-                        // get the gsm status
-                        gsm = mEmulatorConsole.getGsmStatus();
-                        netstatus = mEmulatorConsole.getNetworkStatus();
-                        
-                        if (gsm == null || netstatus == null) {
-                            mEmulatorConsole = null;
-                        }
-                    }
-                }
-
-                if (gsm != null && netstatus != null) {
-                    Display d = mParent.getDisplay();
-                    if (d.isDisposed() == false) {
-                        final GsmStatus f_gsm = gsm;
-                        final NetworkStatus f_netstatus = netstatus;
-                        
-                        d.asyncExec(new Runnable() {
-                            public void run() {
-                                if (f_gsm.voice != GsmMode.UNKNOWN) {
-                                    mVoiceMode.select(getGsmComboIndex(f_gsm.voice));
-                                } else {
-                                    mVoiceMode.clearSelection();
-                                }
-                                if (f_gsm.data != GsmMode.UNKNOWN) {
-                                    mDataMode.select(getGsmComboIndex(f_gsm.data));
-                                } else {
-                                    mDataMode.clearSelection();
-                                }
-
-                                if (f_netstatus.speed != -1) {
-                                    mNetworkSpeed.select(f_netstatus.speed);
-                                } else {
-                                    mNetworkSpeed.clearSelection();
-                                }
-
-                                if (f_netstatus.latency != -1) {
-                                    mNetworkLatency.select(f_netstatus.latency);
-                                } else {
-                                    mNetworkLatency.clearSelection();
-                                }
-                            }
-                        });
-                    }
-                }
-            }
-        } finally {
-            // enable/disable the ui
-            boolean enable = false;
-            synchronized (this) {
-                enable = mEmulatorConsole != null;
-            }
-            
-            enable(enable);
-        }
-    }
-
-    /**
-     * Enable or disable the ui. Can be called from non ui threads.
-     * @param enabled
-     */
-    private void enable(final boolean enabled) {
-        try {
-            Display d = mParent.getDisplay();
-            d.asyncExec(new Runnable() {
-                public void run() {
-                    if (mParent.isDisposed() == false) {
-                        doEnable(enabled);
-                    }
-                }
-            });
-        } catch (SWTException e) {
-            // disposed. do nothing
-        }
-    }
-
-    private boolean isValidPhoneNumber() {
-        String number = mPhoneNumber.getText().trim();
-
-        return number.matches(RE_PHONE_NUMBER);
-    }
-
-    /**
-     * Enable or disable the ui. Cannot be called from non ui threads.
-     * @param enabled
-     */
-    protected void doEnable(boolean enabled) {
-        mVoiceLabel.setEnabled(enabled);
-        mVoiceMode.setEnabled(enabled);
-
-        mDataLabel.setEnabled(enabled);
-        mDataMode.setEnabled(enabled);
-
-        mSpeedLabel.setEnabled(enabled);
-        mNetworkSpeed.setEnabled(enabled);
-
-        mLatencyLabel.setEnabled(enabled);
-        mNetworkLatency.setEnabled(enabled);
-
-        // Calling setEnabled on a text field will trigger a modifyText event, so we don't do it
-        // if we don't need to.
-        if (mPhoneNumber.isEnabled() != enabled) {
-            mNumberLabel.setEnabled(enabled);
-            mPhoneNumber.setEnabled(enabled);
-        }
-
-        boolean valid = isValidPhoneNumber();
-
-        mVoiceButton.setEnabled(enabled && valid);
-        mSmsButton.setEnabled(enabled && valid);
-
-        boolean smsValid = enabled && valid && mSmsButton.getSelection();
-
-        // Calling setEnabled on a text field will trigger a modifyText event, so we don't do it
-        // if we don't need to.
-        if (mSmsMessage.isEnabled() != smsValid) {
-            mMessageLabel.setEnabled(smsValid);
-            mSmsMessage.setEnabled(smsValid);
-        }
-        if (enabled == false) {
-            mSmsMessage.setText(""); //$NON-NLs-1$
-        }
-
-        mCallButton.setEnabled(enabled && valid);
-        mCancelButton.setEnabled(enabled && valid && mVoiceButton.getSelection());
-
-        if (enabled == false) {
-            mVoiceMode.clearSelection();
-            mDataMode.clearSelection();
-            mNetworkSpeed.clearSelection();
-            mNetworkLatency.clearSelection();
-            if (mPhoneNumber.getText().length() > 0) {
-                mPhoneNumber.setText(""); //$NON-NLS-1$
-            }
-        }
-
-        // location controls
-        mLocationFolders.setEnabled(enabled);
-
-        mDecimalButton.setEnabled(enabled);
-        mSexagesimalButton.setEnabled(enabled);
-        mLongitudeControls.setEnabled(enabled);
-        mLatitudeControls.setEnabled(enabled);
-
-        mGpxUploadButton.setEnabled(enabled);
-        mGpxWayPointTable.setEnabled(enabled);
-        mGpxTrackTable.setEnabled(enabled);
-        mKmlUploadButton.setEnabled(enabled);
-        mKmlWayPointTable.setEnabled(enabled);
-    }
-
-    /**
-     * Returns the index of the combo item matching a specific GsmMode.
-     * @param mode
-     */
-    private int getGsmComboIndex(GsmMode mode) {
-        for (int i = 0 ; i < GSM_MODES.length; i++) {
-            String[] modes = GSM_MODES[i];
-            if (mode.getTag().equals(modes[1])) {
-                return i;
-            }
-        }
-        return -1;
-    }
-
-    /**
-     * Processes the result of a command sent to the console.
-     * @param result the result of the command.
-     */
-    private boolean processCommandResult(final String result) {
-        if (result != EmulatorConsole.RESULT_OK) {
-            try {
-                mParent.getDisplay().asyncExec(new Runnable() {
-                    public void run() {
-                        if (mParent.isDisposed() == false) {
-                            MessageDialog.openError(mParent.getShell(), "Emulator Console",
-                                    result);
-                        }
-                    }
-                });
-            } catch (SWTException e) {
-                // we're quitting, just ignore
-            }
-            
-            return false;
-        }
-        
-        return true;
-    }
-
-    /**
-     * @param track
-     */
-    private void playTrack(final Track track) {
-        // no need to synchronize this check, the worst that can happen, is we start the thread
-        // for nothing.
-        if (mEmulatorConsole != null) {
-            mPlayGpxButton.setImage(mPauseImage);
-            mPlayKmlButton.setImage(mPauseImage);
-            mPlayingTrack = true;
-
-            mPlayingThread = new Thread() {
-                @Override
-                public void run() {
-                    try {
-                        TrackPoint[] trackPoints = track.getPoints();
-                        int count = trackPoints.length;
-                        
-                        // get the start index.
-                        int start = 0;
-                        if (mPlayDirection == -1) {
-                            start = count - 1;
-                        }
-                        
-                        for (int p = start; p >= 0 && p < count; p += mPlayDirection) {
-                            if (mPlayingTrack == false) {
-                                return;
-                            }
-
-                            // get the current point and send its location to
-                            // the emulator.
-                            final TrackPoint trackPoint = trackPoints[p];
-
-                            synchronized (EmulatorControlPanel.this) {
-                                if (mEmulatorConsole == null ||
-                                        processCommandResult(mEmulatorConsole.sendLocation(
-                                                trackPoint.getLongitude(), trackPoint.getLatitude(),
-                                                trackPoint.getElevation())) == false) {
-                                    return;
-                                }
-                            }
-
-                            // if this is not the final point, then get the next one and
-                            // compute the delta time
-                            int nextIndex = p + mPlayDirection;
-                            if (nextIndex >=0 && nextIndex < count) {
-                                TrackPoint nextPoint = trackPoints[nextIndex];
-
-                                long delta = nextPoint.getTime() - trackPoint.getTime();
-                                if (delta < 0) {
-                                    delta = -delta;
-                                }
-                                
-                                long startTime = System.currentTimeMillis();
-
-                                try {
-                                    sleep(delta / mSpeed);
-                                } catch (InterruptedException e) {
-                                    if (mPlayingTrack == false) {
-                                        return;
-                                    }
-                                    
-                                    // we got interrupted, lets make sure we can play
-                                    do {
-                                        long waited = System.currentTimeMillis() - startTime;
-                                        long needToWait = delta / mSpeed;
-                                        if (waited < needToWait) {
-                                            try {
-                                                sleep(needToWait - waited);
-                                            } catch (InterruptedException e1) {
-                                                // we'll just loop and wait again if needed.
-                                                // unless we're supposed to stop
-                                                if (mPlayingTrack == false) {
-                                                    return;
-                                                }
-                                            }
-                                        } else {
-                                            break;
-                                        }
-                                    } while (true);
-                                }
-                            }
-                        }
-                    } finally {
-                        mPlayingTrack = false;
-                        try {
-                            mParent.getDisplay().asyncExec(new Runnable() {
-                                public void run() {
-                                    if (mPlayGpxButton.isDisposed() == false) {
-                                        mPlayGpxButton.setImage(mPlayImage);
-                                        mPlayKmlButton.setImage(mPlayImage);
-                                    }
-                                }
-                            });
-                        } catch (SWTException e) {
-                            // we're quitting, just ignore
-                        }
-                    }
-                }
-            };
-
-            mPlayingThread.start();
-        }
-    }
-    
-    private void playKml(final WayPoint[] trackPoints) {
-        // no need to synchronize this check, the worst that can happen, is we start the thread
-        // for nothing.
-        if (mEmulatorConsole != null) {
-            mPlayGpxButton.setImage(mPauseImage);
-            mPlayKmlButton.setImage(mPauseImage);
-            mPlayingTrack = true;
-
-            mPlayingThread = new Thread() {
-                @Override
-                public void run() {
-                    try {
-                        int count = trackPoints.length;
-                        
-                        // get the start index.
-                        int start = 0;
-                        if (mPlayDirection == -1) {
-                            start = count - 1;
-                        }
-                        
-                        for (int p = start; p >= 0 && p < count; p += mPlayDirection) {
-                            if (mPlayingTrack == false) {
-                                return;
-                            }
-
-                            // get the current point and send its location to
-                            // the emulator.
-                            WayPoint trackPoint = trackPoints[p];
-
-                            synchronized (EmulatorControlPanel.this) {
-                                if (mEmulatorConsole == null ||
-                                        processCommandResult(mEmulatorConsole.sendLocation(
-                                                trackPoint.getLongitude(), trackPoint.getLatitude(),
-                                                trackPoint.getElevation())) == false) {
-                                    return;
-                                }
-                            }
-
-                            // if this is not the final point, then get the next one and
-                            // compute the delta time
-                            int nextIndex = p + mPlayDirection;
-                            if (nextIndex >=0 && nextIndex < count) {
-
-                                long delta = 1000; // 1 second
-                                if (delta < 0) {
-                                    delta = -delta;
-                                }
-                                
-                                long startTime = System.currentTimeMillis();
-
-                                try {
-                                    sleep(delta / mSpeed);
-                                } catch (InterruptedException e) {
-                                    if (mPlayingTrack == false) {
-                                        return;
-                                    }
-                                    
-                                    // we got interrupted, lets make sure we can play
-                                    do {
-                                        long waited = System.currentTimeMillis() - startTime;
-                                        long needToWait = delta / mSpeed;
-                                        if (waited < needToWait) {
-                                            try {
-                                                sleep(needToWait - waited);
-                                            } catch (InterruptedException e1) {
-                                                // we'll just loop and wait again if needed.
-                                                // unless we're supposed to stop
-                                                if (mPlayingTrack == false) {
-                                                    return;
-                                                }
-                                            }
-                                        } else {
-                                            break;
-                                        }
-                                    } while (true);
-                                }
-                            }
-                        }
-                    } finally {
-                        mPlayingTrack = false;
-                        try {
-                            mParent.getDisplay().asyncExec(new Runnable() {
-                                public void run() {
-                                    if (mPlayGpxButton.isDisposed() == false) {
-                                        mPlayGpxButton.setImage(mPlayImage);
-                                        mPlayKmlButton.setImage(mPlayImage);
-                                    }
-                                }
-                            });
-                        } catch (SWTException e) {
-                            // we're quitting, just ignore
-                        }
-                    }
-                }
-            };
-
-            mPlayingThread.start();
-        }        
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/HeapPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/HeapPanel.java
deleted file mode 100644
index 977203b..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/HeapPanel.java
+++ /dev/null
@@ -1,1294 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-import com.android.ddmlib.HeapSegment.HeapSegmentElement;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.PaletteData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.jfree.chart.ChartFactory;
-import org.jfree.chart.JFreeChart;
-import org.jfree.chart.axis.CategoryAxis;
-import org.jfree.chart.axis.CategoryLabelPositions;
-import org.jfree.chart.labels.CategoryToolTipGenerator;
-import org.jfree.chart.plot.CategoryPlot;
-import org.jfree.chart.plot.Plot;
-import org.jfree.chart.plot.PlotOrientation;
-import org.jfree.chart.renderer.category.CategoryItemRenderer;
-import org.jfree.chart.title.TextTitle;
-import org.jfree.data.category.CategoryDataset;
-import org.jfree.data.category.DefaultCategoryDataset;
-import org.jfree.experimental.chart.swt.ChartComposite;
-import org.jfree.experimental.swt.SWTUtils;
-
-import java.io.ByteArrayInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.text.NumberFormat;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
-
-/**
- * Base class for our information panels.
- */
-public final class HeapPanel extends BaseHeapPanel {
-    private static final String PREFS_STATS_COL_TYPE = "heapPanel.col0"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_COUNT = "heapPanel.col1"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_SIZE = "heapPanel.col2"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_SMALLEST = "heapPanel.col3"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_LARGEST = "heapPanel.col4"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_MEDIAN = "heapPanel.col5"; //$NON-NLS-1$
-    private static final String PREFS_STATS_COL_AVERAGE = "heapPanel.col6"; //$NON-NLS-1$
-
-    /* args to setUpdateStatus() */
-    private static final int NOT_SELECTED   = 0;
-    private static final int NOT_ENABLED    = 1;
-    private static final int ENABLED        = 2;
-
-    /** color palette and map legend. NATIVE is the last enum is a 0 based enum list, so we need
-     * Native+1 at least. We also need 2 more entries for free area and expansion area.  */
-    private static final int NUM_PALETTE_ENTRIES = HeapSegmentElement.KIND_NATIVE+2 +1;
-    private static final String[] mMapLegend = new String[NUM_PALETTE_ENTRIES];
-    private static final PaletteData mMapPalette = createPalette();
-
-    private static final boolean DISPLAY_HEAP_BITMAP = false;
-    private static final boolean DISPLAY_HILBERT_BITMAP = false;
-
-    private static final int PLACEHOLDER_HILBERT_SIZE = 200;
-    private static final int PLACEHOLDER_LINEAR_V_SIZE = 100;
-    private static final int PLACEHOLDER_LINEAR_H_SIZE = 300;
-
-    private static final int[] ZOOMS = {100, 50, 25};
-    
-    private static final NumberFormat sByteFormatter = NumberFormat.getInstance();
-    private static final NumberFormat sLargeByteFormatter = NumberFormat.getInstance();
-    private static final NumberFormat sCountFormatter = NumberFormat.getInstance();
-    
-    static {
-        sByteFormatter.setMinimumFractionDigits(0);
-        sByteFormatter.setMaximumFractionDigits(1);
-        sLargeByteFormatter.setMinimumFractionDigits(3);
-        sLargeByteFormatter.setMaximumFractionDigits(3);
-
-        sCountFormatter.setGroupingUsed(true);
-    }
-
-    private Display mDisplay;
-
-    private Composite mTop; // real top
-    private Label mUpdateStatus;
-    private Table mHeapSummary;
-    private Combo mDisplayMode;
-
-    //private ScrolledComposite mScrolledComposite;
-
-    private Composite mDisplayBase; // base of the displays.
-    private StackLayout mDisplayStack;
-
-    private Composite mStatisticsBase;
-    private Table mStatisticsTable;
-    private JFreeChart mChart;
-    private ChartComposite mChartComposite;
-    private Button mGcButton;
-    private DefaultCategoryDataset mAllocCountDataSet;
-
-    private Composite mLinearBase;
-    private Label mLinearHeapImage;
-
-    private Composite mHilbertBase;
-    private Label mHilbertHeapImage;
-    private Group mLegend;
-    private Combo mZoom;
-
-    /** Image used for the hilbert display. Since we recreate a new image every time, we
-     * keep this one around to dispose it. */
-    private Image mHilbertImage;
-    private Image mLinearImage;
-    private Composite[] mLayout;
-
-    /*
-     * Create color palette for map.  Set up titles for legend.
-     */
-    private static PaletteData createPalette() {
-        RGB colors[] = new RGB[NUM_PALETTE_ENTRIES];
-        colors[0]
-                = new RGB(192, 192, 192); // non-heap pixels are gray
-        mMapLegend[0]
-                = "(heap expansion area)";
-
-        colors[1]
-                = new RGB(0, 0, 0);       // free chunks are black
-        mMapLegend[1]
-                = "free";
-
-        colors[HeapSegmentElement.KIND_OBJECT + 2]
-                = new RGB(0, 0, 255);     // objects are blue
-        mMapLegend[HeapSegmentElement.KIND_OBJECT + 2]
-                = "data object";
-
-        colors[HeapSegmentElement.KIND_CLASS_OBJECT + 2]
-                = new RGB(0, 255, 0);     // class objects are green
-        mMapLegend[HeapSegmentElement.KIND_CLASS_OBJECT + 2]
-                = "class object";
-
-        colors[HeapSegmentElement.KIND_ARRAY_1 + 2]
-                = new RGB(255, 0, 0);     // byte/bool arrays are red
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_1 + 2]
-                = "1-byte array (byte[], boolean[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_2 + 2]
-                = new RGB(255, 128, 0);   // short/char arrays are orange
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_2 + 2]
-                = "2-byte array (short[], char[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_4 + 2]
-                = new RGB(255, 255, 0);   // obj/int/float arrays are yellow
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_4 + 2]
-                = "4-byte array (object[], int[], float[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_8 + 2]
-                = new RGB(255, 128, 128); // long/double arrays are pink
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_8 + 2]
-                = "8-byte array (long[], double[])";
-
-        colors[HeapSegmentElement.KIND_UNKNOWN + 2]
-                = new RGB(255, 0, 255);   // unknown objects are cyan
-        mMapLegend[HeapSegmentElement.KIND_UNKNOWN + 2]
-                = "unknown object";
-
-        colors[HeapSegmentElement.KIND_NATIVE + 2]
-                = new RGB(64, 64, 64);    // native objects are dark gray
-        mMapLegend[HeapSegmentElement.KIND_NATIVE + 2]
-                = "non-Java object";
-
-        return new PaletteData(colors);
-    }
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        if (client == getCurrentClient()) {
-            if ((changeMask & Client.CHANGE_HEAP_MODE) == Client.CHANGE_HEAP_MODE ||
-                    (changeMask & Client.CHANGE_HEAP_DATA) == Client.CHANGE_HEAP_DATA) {
-                try {
-                    mTop.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            clientSelected();
-                        }
-                    });
-                } catch (SWTException e) {
-                    // display is disposed (app is quitting most likely), we do nothing.
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}
-     */
-    @Override
-    public void deviceSelected() {
-        // pass
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-        if (mTop.isDisposed())
-            return;
-
-        Client client = getCurrentClient();
-
-        Log.d("ddms", "HeapPanel: changed " + client);
-
-        if (client != null) {
-            ClientData cd = client.getClientData();
-
-            if (client.isHeapUpdateEnabled()) {
-                mGcButton.setEnabled(true);
-                mDisplayMode.setEnabled(true);
-                setUpdateStatus(ENABLED);
-            } else {
-                setUpdateStatus(NOT_ENABLED);
-                mGcButton.setEnabled(false);
-                mDisplayMode.setEnabled(false);
-            }
-
-            fillSummaryTable(cd);
-            
-            int mode = mDisplayMode.getSelectionIndex();
-            if (mode == 0) {
-                fillDetailedTable(client, false /* forceRedraw */);
-            } else {
-                if (DISPLAY_HEAP_BITMAP) {
-                    renderHeapData(cd, mode - 1, false /* forceRedraw */);
-                }
-            }
-        } else {
-            mGcButton.setEnabled(false);
-            mDisplayMode.setEnabled(false);
-            fillSummaryTable(null);
-            fillDetailedTable(null, true);
-            setUpdateStatus(NOT_SELECTED);
-        }
-
-        // sizes of things change frequently, so redo layout
-        //mScrolledComposite.setMinSize(mDisplayStack.topControl.computeSize(SWT.DEFAULT,
-        //        SWT.DEFAULT));
-        mDisplayBase.layout();
-        //mScrolledComposite.redraw();
-    }
-
-    /**
-     * Create our control(s).
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mDisplay = parent.getDisplay();
-
-        GridLayout gl;
-
-        mTop = new Composite(parent, SWT.NONE);
-        mTop.setLayout(new GridLayout(1, false));
-        mTop.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        mUpdateStatus = new Label(mTop, SWT.NONE);
-        setUpdateStatus(NOT_SELECTED);
-
-        Composite summarySection = new Composite(mTop, SWT.NONE);
-        summarySection.setLayout(gl = new GridLayout(2, false));
-        gl.marginHeight = gl.marginWidth = 0;
-
-        mHeapSummary = createSummaryTable(summarySection);
-        mGcButton = new Button(summarySection, SWT.PUSH);
-        mGcButton.setText("Cause GC");
-        mGcButton.setEnabled(false);
-        mGcButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                Client client = getCurrentClient();
-                if (client != null) {
-                    client.executeGarbageCollector();
-                }
-            }
-        });
-
-        Composite comboSection = new Composite(mTop, SWT.NONE);
-        gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        comboSection.setLayout(gl);
-
-        Label displayLabel = new Label(comboSection, SWT.NONE);
-        displayLabel.setText("Display: ");
-
-        mDisplayMode = new Combo(comboSection, SWT.READ_ONLY);
-        mDisplayMode.setEnabled(false);
-        mDisplayMode.add("Stats");
-        if (DISPLAY_HEAP_BITMAP) {
-            mDisplayMode.add("Linear");
-            if (DISPLAY_HILBERT_BITMAP) {
-                mDisplayMode.add("Hilbert");
-            }
-        }
-
-        // the base of the displays.
-        mDisplayBase = new Composite(mTop, SWT.NONE);
-        mDisplayBase.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mDisplayStack = new StackLayout();
-        mDisplayBase.setLayout(mDisplayStack);
-
-        // create the statistics display
-        mStatisticsBase = new Composite(mDisplayBase, SWT.NONE);
-        //mStatisticsBase.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mStatisticsBase.setLayout(gl = new GridLayout(1, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        mDisplayStack.topControl = mStatisticsBase;
-        
-        mStatisticsTable = createDetailedTable(mStatisticsBase);
-        mStatisticsTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        
-        createChart();
-
-        //create the linear composite
-        mLinearBase = new Composite(mDisplayBase, SWT.NONE);
-        //mLinearBase.setLayoutData(new GridData());
-        gl = new GridLayout(1, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        mLinearBase.setLayout(gl);
-
-        {
-            mLinearHeapImage = new Label(mLinearBase, SWT.NONE);
-            mLinearHeapImage.setLayoutData(new GridData());
-            mLinearHeapImage.setImage(ImageHelper.createPlaceHolderArt(mDisplay,
-                    PLACEHOLDER_LINEAR_H_SIZE, PLACEHOLDER_LINEAR_V_SIZE,
-                    mDisplay.getSystemColor(SWT.COLOR_BLUE)));
-
-            // create a composite to contain the bottom part (legend)
-            Composite bottomSection = new Composite(mLinearBase, SWT.NONE);
-            gl = new GridLayout(1, false);
-            gl.marginHeight = gl.marginWidth = 0;
-            bottomSection.setLayout(gl);
-
-            createLegend(bottomSection);
-        }
-
-/*        
-        mScrolledComposite = new ScrolledComposite(mTop, SWT.H_SCROLL | SWT.V_SCROLL);
-        mScrolledComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mScrolledComposite.setExpandHorizontal(true);
-        mScrolledComposite.setExpandVertical(true);
-        mScrolledComposite.setContent(mDisplayBase);
-*/
-
-
-        // create the hilbert display.
-        mHilbertBase = new Composite(mDisplayBase, SWT.NONE);
-        //mHilbertBase.setLayoutData(new GridData());
-        gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        mHilbertBase.setLayout(gl);
-
-        if (DISPLAY_HILBERT_BITMAP) {
-            mHilbertHeapImage = new Label(mHilbertBase, SWT.NONE);
-            mHilbertHeapImage.setLayoutData(new GridData());
-            mHilbertHeapImage.setImage(ImageHelper.createPlaceHolderArt(mDisplay,
-                    PLACEHOLDER_HILBERT_SIZE, PLACEHOLDER_HILBERT_SIZE,
-                    mDisplay.getSystemColor(SWT.COLOR_BLUE)));
-
-            // create a composite to contain the right part (legend + zoom)
-            Composite rightSection = new Composite(mHilbertBase, SWT.NONE);
-            gl = new GridLayout(1, false);
-            gl.marginHeight = gl.marginWidth = 0;
-            rightSection.setLayout(gl);
-
-            Composite zoomComposite = new Composite(rightSection, SWT.NONE);
-            gl = new GridLayout(2, false);
-            zoomComposite.setLayout(gl);
-
-            Label l = new Label(zoomComposite, SWT.NONE);
-            l.setText("Zoom:");
-            mZoom = new Combo(zoomComposite, SWT.READ_ONLY);
-            for (int z : ZOOMS) {
-                mZoom.add(String.format("%1$d%%", z)); // $NON-NLS-1$
-            }
-
-            mZoom.select(0);
-            mZoom.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    setLegendText(mZoom.getSelectionIndex());
-                    Client client = getCurrentClient();
-                    if (client != null) {
-                        renderHeapData(client.getClientData(), 1, true);
-                        mTop.pack();
-                    }
-                }
-            });
-
-            createLegend(rightSection);
-        }
-        mHilbertBase.pack();
-
-        mLayout = new Composite[] { mStatisticsBase, mLinearBase, mHilbertBase };
-        mDisplayMode.select(0);
-        mDisplayMode.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                int index = mDisplayMode.getSelectionIndex();
-                Client client = getCurrentClient();
-
-                if (client != null) {
-                    if (index == 0) {
-                        fillDetailedTable(client, true /* forceRedraw */);
-                    } else {
-                        renderHeapData(client.getClientData(), index-1, true /* forceRedraw */);
-                    }
-                }
-
-                mDisplayStack.topControl = mLayout[index];
-                //mScrolledComposite.setMinSize(mDisplayStack.topControl.computeSize(SWT.DEFAULT,
-                //        SWT.DEFAULT));
-                mDisplayBase.layout();
-                //mScrolledComposite.redraw();
-            }
-        });
-
-        //mScrolledComposite.setMinSize(mDisplayStack.topControl.computeSize(SWT.DEFAULT,
-        //        SWT.DEFAULT));
-        mDisplayBase.layout();
-        //mScrolledComposite.redraw();
-
-        return mTop;
-    }
-
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mHeapSummary.setFocus();
-    }
-    
-
-    private Table createSummaryTable(Composite base) {
-        Table tab = new Table(base, SWT.SINGLE | SWT.FULL_SELECTION);
-        tab.setHeaderVisible(true);
-        tab.setLinesVisible(true);
-
-        TableColumn col;
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("ID");
-        col.pack();
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("000.000WW"); // $NON-NLS-1$
-        col.pack();
-        col.setText("Heap Size");
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("000.000WW"); // $NON-NLS-1$
-        col.pack();
-        col.setText("Allocated");
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("000.000WW"); // $NON-NLS-1$
-        col.pack();
-        col.setText("Free");
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("000.00%"); // $NON-NLS-1$
-        col.pack();
-        col.setText("% Used");
-
-        col = new TableColumn(tab, SWT.RIGHT);
-        col.setText("000,000,000"); // $NON-NLS-1$
-        col.pack();
-        col.setText("# Objects");
-
-        return tab;
-    }
-    
-    private Table createDetailedTable(Composite base) {
-        IPreferenceStore store = DdmUiPreferences.getStore();
-        
-        Table tab = new Table(base, SWT.SINGLE | SWT.FULL_SELECTION);
-        tab.setHeaderVisible(true);
-        tab.setLinesVisible(true);
-
-        TableHelper.createTableColumn(tab, "Type", SWT.LEFT,
-                "4-byte array (object[], int[], float[])", //$NON-NLS-1$
-                PREFS_STATS_COL_TYPE, store);
-
-        TableHelper.createTableColumn(tab, "Count", SWT.RIGHT,
-                "00,000", //$NON-NLS-1$
-                PREFS_STATS_COL_COUNT, store);
-
-        TableHelper.createTableColumn(tab, "Total Size", SWT.RIGHT,
-                "000.000 WW", //$NON-NLS-1$
-                PREFS_STATS_COL_SIZE, store);
-
-        TableHelper.createTableColumn(tab, "Smallest", SWT.RIGHT,
-                "000.000 WW", //$NON-NLS-1$
-                PREFS_STATS_COL_SMALLEST, store);
-
-        TableHelper.createTableColumn(tab, "Largest", SWT.RIGHT,
-                "000.000 WW", //$NON-NLS-1$
-                PREFS_STATS_COL_LARGEST, store);
-
-        TableHelper.createTableColumn(tab, "Median", SWT.RIGHT,
-                "000.000 WW", //$NON-NLS-1$
-                PREFS_STATS_COL_MEDIAN, store);
-
-        TableHelper.createTableColumn(tab, "Average", SWT.RIGHT,
-                "000.000 WW", //$NON-NLS-1$
-                PREFS_STATS_COL_AVERAGE, store);
-
-        tab.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                
-                Client client = getCurrentClient();
-                if (client != null) {
-                    int index = mStatisticsTable.getSelectionIndex();
-                    TableItem item = mStatisticsTable.getItem(index);
-                    
-                    if (item != null) {
-                        Map<Integer, ArrayList<HeapSegmentElement>> heapMap =
-                            client.getClientData().getVmHeapData().getProcessedHeapMap();
-                        
-                        ArrayList<HeapSegmentElement> list = heapMap.get(item.getData());
-                        if (list != null) {
-                            showChart(list);
-                        }
-                    }
-                }
-
-            }
-        });
-        
-        return tab;
-    }
-    
-    /**
-     * Creates the chart below the statistics table
-     */
-    private void createChart() {
-        mAllocCountDataSet = new DefaultCategoryDataset();
-        mChart = ChartFactory.createBarChart(null, "Size", "Count", mAllocCountDataSet,
-                PlotOrientation.VERTICAL, false, true, false);
-        
-        // get the font to make a proper title. We need to convert the swt font,
-        // into an awt font.
-        Font f = mStatisticsBase.getFont();
-        FontData[] fData = f.getFontData();
-        
-        // event though on Mac OS there could be more than one fontData, we'll only use
-        // the first one.
-        FontData firstFontData = fData[0];
-        
-        java.awt.Font awtFont = SWTUtils.toAwtFont(mStatisticsBase.getDisplay(),
-                firstFontData, true /* ensureSameSize */);
-
-        mChart.setTitle(new TextTitle("Allocation count per size", awtFont));
-        
-        Plot plot = mChart.getPlot();
-        if (plot instanceof CategoryPlot) {
-            // get the plot
-            CategoryPlot categoryPlot = (CategoryPlot)plot;
-            
-            // set the domain axis to draw labels that are displayed even with many values.
-            CategoryAxis domainAxis = categoryPlot.getDomainAxis();
-            domainAxis.setCategoryLabelPositions(CategoryLabelPositions.DOWN_90);
-            
-            CategoryItemRenderer renderer = categoryPlot.getRenderer();
-            renderer.setBaseToolTipGenerator(new CategoryToolTipGenerator() {
-                public String generateToolTip(CategoryDataset dataset, int row, int column) {
-                    // get the key for the size of the allocation
-                    ByteLong columnKey = (ByteLong)dataset.getColumnKey(column);
-                    String rowKey = (String)dataset.getRowKey(row);
-                    Number value = dataset.getValue(rowKey, columnKey);
-                    
-                    return String.format("%1$d %2$s of %3$d bytes", value.intValue(), rowKey, 
-                            columnKey.getValue());
-                }
-            });
-        }
-        mChartComposite = new ChartComposite(mStatisticsBase, SWT.BORDER, mChart,
-                ChartComposite.DEFAULT_WIDTH,
-                ChartComposite.DEFAULT_HEIGHT,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_WIDTH,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_HEIGHT,
-                3000, // max draw width. We don't want it to zoom, so we put a big number
-                3000, // max draw height. We don't want it to zoom, so we put a big number
-                true,  // off-screen buffer
-                true,  // properties
-                true,  // save
-                true,  // print
-                false,  // zoom
-                true);   // tooltips
-
-        mChartComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-    }
-
-    private static String prettyByteCount(long bytes) {
-        double fracBytes = bytes;
-        String units = " B";
-        if (fracBytes < 1024) {
-            return sByteFormatter.format(fracBytes) + units;
-        } else {
-            fracBytes /= 1024;
-            units = " KB";
-        }
-        if (fracBytes >= 1024) {
-            fracBytes /= 1024;
-            units = " MB";
-        }
-        if (fracBytes >= 1024) {
-            fracBytes /= 1024;
-            units = " GB";
-        }
-
-        return sLargeByteFormatter.format(fracBytes) + units;
-    }
-
-    private static String approximateByteCount(long bytes) {
-        double fracBytes = bytes;
-        String units = "";
-        if (fracBytes >= 1024) {
-            fracBytes /= 1024;
-            units = "K";
-        }
-        if (fracBytes >= 1024) {
-            fracBytes /= 1024;
-            units = "M";
-        }
-        if (fracBytes >= 1024) {
-            fracBytes /= 1024;
-            units = "G";
-        }
-
-        return sByteFormatter.format(fracBytes) + units;
-    }
-
-    private static String addCommasToNumber(long num) {
-        return sCountFormatter.format(num);
-    }
-
-    private static String fractionalPercent(long num, long denom) {
-        double val = (double)num / (double)denom;
-        val *= 100;
-
-        NumberFormat nf = NumberFormat.getInstance();
-        nf.setMinimumFractionDigits(2);
-        nf.setMaximumFractionDigits(2);
-        return nf.format(val) + "%";
-    }
-
-    private void fillSummaryTable(ClientData cd) {
-        if (mHeapSummary.isDisposed()) {
-            return;
-        }
-
-        mHeapSummary.setRedraw(false);
-        mHeapSummary.removeAll();
-
-        if (cd != null) {
-            synchronized (cd) {
-                Iterator<Integer> iter = cd.getVmHeapIds();
-    
-                while (iter.hasNext()) {
-                    Integer id = iter.next();
-                    Map<String, Long> heapInfo = cd.getVmHeapInfo(id);
-                    if (heapInfo == null) {
-                        continue;
-                    }
-                    long sizeInBytes = heapInfo.get(ClientData.HEAP_SIZE_BYTES);
-                    long bytesAllocated = heapInfo.get(ClientData.HEAP_BYTES_ALLOCATED);
-                    long objectsAllocated = heapInfo.get(ClientData.HEAP_OBJECTS_ALLOCATED);
-    
-                    TableItem item = new TableItem(mHeapSummary, SWT.NONE);
-                    item.setText(0, id.toString());
-    
-                    item.setText(1, prettyByteCount(sizeInBytes));
-                    item.setText(2, prettyByteCount(bytesAllocated));
-                    item.setText(3, prettyByteCount(sizeInBytes - bytesAllocated));
-                    item.setText(4, fractionalPercent(bytesAllocated, sizeInBytes));
-                    item.setText(5, addCommasToNumber(objectsAllocated));
-                }
-            }
-        }
-
-        mHeapSummary.pack();
-        mHeapSummary.setRedraw(true);
-    }
-    
-    private void fillDetailedTable(Client client, boolean forceRedraw) {
-        // first check if the client is invalid or heap updates are not enabled.
-        if (client == null || client.isHeapUpdateEnabled() == false) {
-            mStatisticsTable.removeAll();
-            showChart(null);
-            return;
-        }
-        
-        ClientData cd = client.getClientData();
-
-        Map<Integer, ArrayList<HeapSegmentElement>> heapMap;
-
-        // Atomically get and clear the heap data.
-        synchronized (cd) {
-            if (serializeHeapData(cd.getVmHeapData()) == false && forceRedraw == false) {
-                // no change, we return.
-                return;
-            }
-            
-            heapMap = cd.getVmHeapData().getProcessedHeapMap();
-        }
-        
-        // we have new data, lets display it.
-        
-        // First, get the current selection, and its key.
-        int index = mStatisticsTable.getSelectionIndex();
-        Integer selectedKey = null;
-        if (index != -1) {
-            selectedKey = (Integer)mStatisticsTable.getItem(index).getData();
-        }
-
-        // disable redraws and remove all from the table.
-        mStatisticsTable.setRedraw(false);
-        mStatisticsTable.removeAll();
-        
-        if (heapMap != null) {
-            int selectedIndex = -1;
-            ArrayList<HeapSegmentElement> selectedList = null;
-            
-            // get the keys
-            Set<Integer> keys = heapMap.keySet();
-            int iter = 0; // use a manual iter int because Set<?> doesn't have an index
-            // based accessor.
-            for (Integer key : keys) {
-                ArrayList<HeapSegmentElement> list = heapMap.get(key);
-
-                // check if this is the key that is supposed to be selected
-                if (key.equals(selectedKey)) {
-                    selectedIndex = iter;
-                    selectedList = list;
-                }
-                iter++;
-
-                TableItem item = new TableItem(mStatisticsTable, SWT.NONE);
-                item.setData(key);
-
-                // get the type
-                item.setText(0, mMapLegend[key]);
-                
-                // set the count, smallest, largest
-                int count = list.size();
-                item.setText(1, addCommasToNumber(count));
-                
-                if (count > 0) {
-                    item.setText(3, prettyByteCount(list.get(0).getLength()));
-                    item.setText(4, prettyByteCount(list.get(count-1).getLength()));
-
-                    int median = count / 2;
-                    HeapSegmentElement element = list.get(median);
-                    long size = element.getLength();
-                    item.setText(5, prettyByteCount(size));
-
-                    long totalSize = 0;
-                    for (int i = 0 ; i < count; i++) {
-                        element = list.get(i);
-                        
-                        size = element.getLength();
-                        totalSize += size;
-                    }
-                    
-                    // set the average and total
-                    item.setText(2, prettyByteCount(totalSize));
-                    item.setText(6, prettyByteCount(totalSize / count));
-                }
-            }
-
-            mStatisticsTable.setRedraw(true);
-            
-            if (selectedIndex != -1) {
-                mStatisticsTable.setSelection(selectedIndex);
-                showChart(selectedList);
-            } else {
-                showChart(null);
-            }
-        } else {
-            mStatisticsTable.setRedraw(true);
-        }
-    }
-    
-    private static class ByteLong implements Comparable<ByteLong> {
-        private long mValue;
-        
-        private ByteLong(long value) {
-            mValue = value;
-        }
-        
-        public long getValue() {
-            return mValue;
-        }
-
-        @Override
-        public String toString() {
-            return approximateByteCount(mValue);
-        }
-
-        public int compareTo(ByteLong other) {
-            if (mValue != other.mValue) {
-                return mValue < other.mValue ? -1 : 1;
-            }
-            return 0;
-        }
-        
-    }
-    
-    /**
-     * Fills the chart with the content of the list of {@link HeapSegmentElement}.
-     */
-    private void showChart(ArrayList<HeapSegmentElement> list) {
-        mAllocCountDataSet.clear();
-
-        if (list != null) {
-            String rowKey = "Alloc Count";
-    
-            long currentSize = -1;
-            int currentCount = 0;
-            for (HeapSegmentElement element : list) {
-                if (element.getLength() != currentSize) {
-                    if (currentSize != -1) {
-                        ByteLong columnKey = new ByteLong(currentSize);
-                        mAllocCountDataSet.addValue(currentCount, rowKey, columnKey);
-                    }
-                    
-                    currentSize = element.getLength();
-                    currentCount = 1;
-                } else {
-                    currentCount++;
-                }
-            }
-            
-            // add the last item
-            if (currentSize != -1) {
-                ByteLong columnKey = new ByteLong(currentSize);
-                mAllocCountDataSet.addValue(currentCount, rowKey, columnKey);
-            }
-        }
-    }
-
-    /*
-     * Add a color legend to the specified table.
-     */
-    private void createLegend(Composite parent) {
-        mLegend = new Group(parent, SWT.NONE);
-        mLegend.setText(getLegendText(0));
-
-        mLegend.setLayout(new GridLayout(2, false));
-
-        RGB[] colors = mMapPalette.colors;
-
-        for (int i = 0; i < NUM_PALETTE_ENTRIES; i++) {
-            Image tmpImage = createColorRect(parent.getDisplay(), colors[i]);
-
-            Label l = new Label(mLegend, SWT.NONE);
-            l.setImage(tmpImage);
-
-            l = new Label(mLegend, SWT.NONE);
-            l.setText(mMapLegend[i]);
-        }
-    }
-
-    private String getLegendText(int level) {
-        int bytes = 8 * (100 / ZOOMS[level]);
-
-        return String.format("Key (1 pixel = %1$d bytes)", bytes);
-    }
-
-    private void setLegendText(int level) {
-        mLegend.setText(getLegendText(level));
-
-    }
-
-    /*
-     * Create a nice rectangle in the specified color.
-     */
-    private Image createColorRect(Display display, RGB color) {
-        int width = 32;
-        int height = 16;
-
-        Image img = new Image(display, width, height);
-        GC gc = new GC(img);
-        gc.setBackground(new Color(display, color));
-        gc.fillRectangle(0, 0, width, height);
-        gc.dispose();
-        return img;
-    }
-
-
-    /*
-     * Are updates enabled?
-     */
-    private void setUpdateStatus(int status) {
-        switch (status) {
-            case NOT_SELECTED:
-                mUpdateStatus.setText("Select a client to see heap updates");
-                break;
-            case NOT_ENABLED:
-                mUpdateStatus.setText("Heap updates are " +
-                                      "NOT ENABLED for this client");
-                break;
-            case ENABLED:
-                mUpdateStatus.setText("Heap updates will happen after " +
-                                      "every GC for this client");
-                break;
-            default:
-                throw new RuntimeException();
-        }
-
-        mUpdateStatus.pack();
-    }
-
-
-    /**
-     * Return the closest power of two greater than or equal to value.
-     *
-     * @param value the return value will be >= value
-     * @return a power of two >= value.  If value > 2^31, 2^31 is returned.
-     */
-//xxx use Integer.highestOneBit() or numberOfLeadingZeros().
-    private int nextPow2(int value) {
-        for (int i = 31; i >= 0; --i) {
-            if ((value & (1<<i)) != 0) {
-                if (i < 31) {
-                    return 1<<(i + 1);
-                } else {
-                    return 1<<31;
-                }
-            }
-        }
-        return 0;
-    }
-
-    private int zOrderData(ImageData id, byte pixData[]) {
-        int maxX = 0;
-        for (int i = 0; i < pixData.length; i++) {
-            /* Tread the pixData index as a z-order curve index and
-             * decompose into Cartesian coordinates.
-             */
-            int x = (i & 1) |
-                    ((i >>> 2) & 1) << 1 |
-                    ((i >>> 4) & 1) << 2 |
-                    ((i >>> 6) & 1) << 3 |
-                    ((i >>> 8) & 1) << 4 |
-                    ((i >>> 10) & 1) << 5 |
-                    ((i >>> 12) & 1) << 6 |
-                    ((i >>> 14) & 1) << 7 |
-                    ((i >>> 16) & 1) << 8 |
-                    ((i >>> 18) & 1) << 9 |
-                    ((i >>> 20) & 1) << 10 |
-                    ((i >>> 22) & 1) << 11 |
-                    ((i >>> 24) & 1) << 12 |
-                    ((i >>> 26) & 1) << 13 |
-                    ((i >>> 28) & 1) << 14 |
-                    ((i >>> 30) & 1) << 15;
-            int y = ((i >>> 1) & 1) << 0 |
-                    ((i >>> 3) & 1) << 1 |
-                    ((i >>> 5) & 1) << 2 |
-                    ((i >>> 7) & 1) << 3 |
-                    ((i >>> 9) & 1) << 4 |
-                    ((i >>> 11) & 1) << 5 |
-                    ((i >>> 13) & 1) << 6 |
-                    ((i >>> 15) & 1) << 7 |
-                    ((i >>> 17) & 1) << 8 |
-                    ((i >>> 19) & 1) << 9 |
-                    ((i >>> 21) & 1) << 10 |
-                    ((i >>> 23) & 1) << 11 |
-                    ((i >>> 25) & 1) << 12 |
-                    ((i >>> 27) & 1) << 13 |
-                    ((i >>> 29) & 1) << 14 |
-                    ((i >>> 31) & 1) << 15;
-            try {
-                id.setPixel(x, y, pixData[i]);
-                if (x > maxX) {
-                    maxX = x;
-                }
-            } catch (IllegalArgumentException ex) {
-                System.out.println("bad pixels: i " + i +
-                        ", w " + id.width +
-                        ", h " + id.height +
-                        ", x " + x +
-                        ", y " + y);
-                throw ex;
-            }
-        }
-        return maxX;
-    }
-
-    private final static int HILBERT_DIR_N = 0;
-    private final static int HILBERT_DIR_S = 1;
-    private final static int HILBERT_DIR_E = 2;
-    private final static int HILBERT_DIR_W = 3;
-
-    private void hilbertWalk(ImageData id, InputStream pixData,
-                             int order, int x, int y, int dir)
-                             throws IOException {
-        if (x >= id.width || y >= id.height) {
-            return;
-        } else if (order == 0) {
-            try {
-                int p = pixData.read();
-                if (p >= 0) {
-                    // flip along x=y axis;  assume width == height
-                    id.setPixel(y, x, p);
-
-                    /* Skanky; use an otherwise-unused ImageData field
-                     * to keep track of the max x,y used. Note that x and y are inverted.
-                     */
-                    if (y > id.x) {
-                        id.x = y;
-                    }
-                    if (x > id.y) {
-                        id.y = x;
-                    }
-                }
-//xxx just give up; don't bother walking the rest of the image
-            } catch (IllegalArgumentException ex) {
-                System.out.println("bad pixels: order " + order +
-                        ", dir " + dir +
-                        ", w " + id.width +
-                        ", h " + id.height +
-                        ", x " + x +
-                        ", y " + y);
-                throw ex;
-            }
-        } else {
-            order--;
-            int delta = 1 << order;
-            int nextX = x + delta;
-            int nextY = y + delta;
-
-            switch (dir) {
-            case HILBERT_DIR_E:
-                hilbertWalk(id, pixData, order,     x,     y, HILBERT_DIR_N);
-                hilbertWalk(id, pixData, order,     x, nextY, HILBERT_DIR_E);
-                hilbertWalk(id, pixData, order, nextX, nextY, HILBERT_DIR_E);
-                hilbertWalk(id, pixData, order, nextX,     y, HILBERT_DIR_S);
-                break;
-            case HILBERT_DIR_N:
-                hilbertWalk(id, pixData, order,     x,     y, HILBERT_DIR_E);
-                hilbertWalk(id, pixData, order, nextX,     y, HILBERT_DIR_N);
-                hilbertWalk(id, pixData, order, nextX, nextY, HILBERT_DIR_N);
-                hilbertWalk(id, pixData, order,     x, nextY, HILBERT_DIR_W);
-                break;
-            case HILBERT_DIR_S:
-                hilbertWalk(id, pixData, order, nextX, nextY, HILBERT_DIR_W);
-                hilbertWalk(id, pixData, order,     x, nextY, HILBERT_DIR_S);
-                hilbertWalk(id, pixData, order,     x,     y, HILBERT_DIR_S);
-                hilbertWalk(id, pixData, order, nextX,     y, HILBERT_DIR_E);
-                break;
-            case HILBERT_DIR_W:
-                hilbertWalk(id, pixData, order, nextX, nextY, HILBERT_DIR_S);
-                hilbertWalk(id, pixData, order, nextX,     y, HILBERT_DIR_W);
-                hilbertWalk(id, pixData, order,     x,     y, HILBERT_DIR_W);
-                hilbertWalk(id, pixData, order,     x, nextY, HILBERT_DIR_N);
-                break;
-            default:
-                throw new RuntimeException("Unexpected Hilbert direction " +
-                                           dir);
-            }
-        }
-    }
-
-    private Point hilbertOrderData(ImageData id, byte pixData[]) {
-
-        int order = 0;
-        for (int n = 1; n < id.width; n *= 2) {
-            order++;
-        }
-        /* Skanky; use an otherwise-unused ImageData field
-         * to keep track of maxX.
-         */
-        Point p = new Point(0,0);
-        int oldIdX = id.x;
-        int oldIdY = id.y;
-        id.x = id.y = 0;
-        try {
-            hilbertWalk(id, new ByteArrayInputStream(pixData),
-                        order, 0, 0, HILBERT_DIR_E);
-            p.x = id.x;
-            p.y = id.y;
-        } catch (IOException ex) {
-            System.err.println("Exception during hilbertWalk()");
-            p.x = id.height;
-            p.y = id.width;
-        }
-        id.x = oldIdX;
-        id.y = oldIdY;
-        return p;
-    }
-
-    private ImageData createHilbertHeapImage(byte pixData[]) {
-        int w, h;
-
-        // Pick an image size that the largest of heaps will fit into.
-        w = (int)Math.sqrt((double)((16 * 1024 * 1024)/8));
-
-        // Space-filling curves require a power-of-2 width.
-        w = nextPow2(w);
-        h = w;
-
-        // Create the heap image.
-        ImageData id = new ImageData(w, h, 8, mMapPalette);
-
-        // Copy the data into the image
-        //int maxX = zOrderData(id, pixData);
-        Point maxP = hilbertOrderData(id, pixData);
-
-        // update the max size to make it a round number once the zoom is applied
-        int factor = 100 / ZOOMS[mZoom.getSelectionIndex()];
-        if (factor != 1) {
-            int tmp = maxP.x % factor;
-            if (tmp != 0) {
-                maxP.x += factor - tmp;
-            }
-
-            tmp = maxP.y % factor;
-            if (tmp != 0) {
-                maxP.y += factor - tmp;
-            }
-        }
-
-        if (maxP.y < id.height) {
-            // Crop the image down to the interesting part.
-            id = new ImageData(id.width, maxP.y, id.depth, id.palette,
-                               id.scanlinePad, id.data);
-        }
-
-        if (maxP.x < id.width) {
-            // crop the image again. A bit trickier this time.
-           ImageData croppedId = new ImageData(maxP.x, id.height, id.depth, id.palette);
-
-           int[] buffer = new int[maxP.x];
-           for (int l = 0 ; l < id.height; l++) {
-               id.getPixels(0, l, maxP.x, buffer, 0);
-               croppedId.setPixels(0, l, maxP.x, buffer, 0);
-           }
-
-           id = croppedId;
-        }
-
-        // apply the zoom
-        if (factor != 1) {
-            id = id.scaledTo(id.width / factor, id.height / factor);
-        }
-
-        return id;
-    }
-
-    /**
-     * Convert the raw heap data to an image.  We know we're running in
-     * the UI thread, so we can issue graphics commands directly.
-     *
-     * http://help.eclipse.org/help31/nftopic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/swt/graphics/GC.html
-     *
-     * @param cd The client data
-     * @param mode The display mode. 0 = linear, 1 = hilbert.
-     * @param forceRedraw
-     */
-    private void renderHeapData(ClientData cd, int mode, boolean forceRedraw) {
-        Image image;
-
-        byte[] pixData;
-
-        // Atomically get and clear the heap data.
-        synchronized (cd) {
-            if (serializeHeapData(cd.getVmHeapData()) == false && forceRedraw == false) {
-                // no change, we return.
-                return;
-            }
-
-            pixData = getSerializedData();
-        }
-
-        if (pixData != null) {
-            ImageData id;
-            if (mode == 1) {
-                id = createHilbertHeapImage(pixData);
-            } else {
-                id = createLinearHeapImage(pixData, 200, mMapPalette);
-            }
-
-            image = new Image(mDisplay, id);
-        } else {
-            // Render a placeholder image.
-            int width, height;
-            if (mode == 1) {
-                width = height = PLACEHOLDER_HILBERT_SIZE;
-            } else {
-                width = PLACEHOLDER_LINEAR_H_SIZE;
-                height = PLACEHOLDER_LINEAR_V_SIZE;
-            }
-            image = new Image(mDisplay, width, height);
-            GC gc = new GC(image);
-            gc.setForeground(mDisplay.getSystemColor(SWT.COLOR_RED));
-            gc.drawLine(0, 0, width-1, height-1);
-            gc.dispose();
-            gc = null;
-        }
-
-        // set the new image
-
-        if (mode == 1) {
-            if (mHilbertImage != null) {
-                mHilbertImage.dispose();
-            }
-
-            mHilbertImage = image;
-            mHilbertHeapImage.setImage(mHilbertImage);
-            mHilbertHeapImage.pack(true);
-            mHilbertBase.layout();
-            mHilbertBase.pack(true);
-        } else {
-            if (mLinearImage != null) {
-                mLinearImage.dispose();
-            }
-
-            mLinearImage = image;
-            mLinearHeapImage.setImage(mLinearImage);
-            mLinearHeapImage.pack(true);
-            mLinearBase.layout();
-            mLinearBase.pack(true);
-        }
-    }
-
-    @Override
-    protected void setTableFocusListener() {
-        addTableToFocusListener(mHeapSummary);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/IImageLoader.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/IImageLoader.java
deleted file mode 100644
index bcbf612..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/IImageLoader.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-
-/**
- * Interface defining an image loader. jar app/lib and plugin have different packaging method
- * so each implementation will be different.
- * The implementation should implement at least one of the methods, and preferably both if possible.
- *
- */
-public interface IImageLoader {
-
-    /**
-     * Load an image from the resource from a filename
-     * @param filename
-     * @param display
-     */
-    public Image loadImage(String filename, Display display);
-
-    /**
-     * Load an ImageDescriptor from the resource from a filename
-     * @param filename
-     * @param display
-     */
-    public ImageDescriptor loadDescriptor(String filename, Display display);
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ITableFocusListener.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ITableFocusListener.java
deleted file mode 100644
index bf425d9..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ITableFocusListener.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.swt.dnd.Clipboard;
-
-/**
- * An object listening to focus change in Table objects.<br>
- * For application not relying on a RCP to provide menu changes based on focus,
- * this class allows to get monitor the focus change of several Table widget
- * and update the menu action accordingly.
- */
-public interface ITableFocusListener {
-
-	public interface IFocusedTableActivator {
-		public void copy(Clipboard clipboard);
-
-		public void selectAll();
-	}
-
-	public void focusGained(IFocusedTableActivator activator);
-
-	public void focusLost(IFocusedTableActivator activator);
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageHelper.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageHelper.java
deleted file mode 100644
index d65978b..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageHelper.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Log;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-
-public class ImageHelper {
-
-    /**
-     * Loads an image from a resource. This method used a class to locate the
-     * resources, and then load the filename from /images inside the resources.<br>
-     * Extra parameters allows for creation of a replacement image of the
-     * loading failed.
-     *
-     * @param loader the image loader used.
-     * @param display the Display object
-     * @param fileName the file name
-     * @param width optional width to create replacement Image. If -1, null be
-     *            be returned if the loading fails.
-     * @param height optional height to create replacement Image. If -1, null be
-     *            be returned if the loading fails.
-     * @param phColor optional color to create replacement Image. If null, Blue
-     *            color will be used.
-     * @return a new Image or null if the loading failed and the optional
-     *         replacement size was -1
-     */
-    public static Image loadImage(IImageLoader loader, Display display,
-            String fileName, int width, int height, Color phColor) {
-
-        Image img = null;
-        if (loader != null) {
-            img = loader.loadImage(fileName, display);
-        }
-
-        if (img == null) {
-            Log.w("ddms", "Couldn't load " + fileName);
-            // if we had the extra parameter to create replacement image then we
-            // create and return it.
-            if (width != -1 && height != -1) {
-                return createPlaceHolderArt(display, width, height,
-                        phColor != null ? phColor : display
-                                .getSystemColor(SWT.COLOR_BLUE));
-            }
-
-            // otherwise, just return null
-            return null;
-        }
-
-        return img;
-    }
-
-    /**
-     * Create place-holder art with the specified color.
-     */
-    public static Image createPlaceHolderArt(Display display, int width,
-            int height, Color color) {
-        Image img = new Image(display, width, height);
-        GC gc = new GC(img);
-        gc.setForeground(color);
-        gc.drawLine(0, 0, width, height);
-        gc.drawLine(0, height - 1, width, -1);
-        gc.dispose();
-        return img;
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageLoader.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageLoader.java
deleted file mode 100644
index 76f2285..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ImageLoader.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-
-import java.io.InputStream;
-
-/**
- * Image loader for an normal standalone app.
- */
-public class ImageLoader implements IImageLoader {
-
-    /** class used as reference to get the reources */
-    private Class<?> mClass;
-
-    /**
-     * Creates a loader for a specific class. The class allows java to figure
-     * out which .jar file to search for the image.
-     *
-     * @param theClass
-     */
-    public ImageLoader(Class<?> theClass) {
-        mClass = theClass;
-    }
-
-    public ImageDescriptor loadDescriptor(String filename, Display display) {
-        // we don't support ImageDescriptor
-        return null;
-    }
-
-    public Image loadImage(String filename, Display display) {
-
-        String tmp = "/images/" + filename;
-        InputStream imageStream = mClass.getResourceAsStream(tmp);
-
-        if (imageStream != null) {
-            Image img = new Image(display, imageStream);
-            if (img == null)
-                throw new NullPointerException("couldn't load " + tmp);
-            return img;
-        }
-
-        return null;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/InfoPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/InfoPanel.java
deleted file mode 100644
index 72cbb4a..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/InfoPanel.java
+++ /dev/null
@@ -1,175 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-
-/**
- * Display client info in a two-column format.
- */
-public class InfoPanel extends TablePanel {
-    private Table mTable;
-    private TableColumn mCol2;
-
-    private static final String mLabels[] = {
-        "DDM-aware?",
-        "App description:",
-        "VM version:",
-        "Process ID:",
-    };
-    private static final int ENT_DDM_AWARE = 0;
-    private static final int ENT_APP_DESCR = 1;
-    private static final int ENT_VM_VERSION = 2;
-    private static final int ENT_PROCESS_ID = 3;
-
-    /**
-     * Create our control(s).
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mTable = new Table(parent, SWT.MULTI | SWT.FULL_SELECTION);
-        mTable.setHeaderVisible(false);
-        mTable.setLinesVisible(false);
-
-        TableColumn col1 = new TableColumn(mTable, SWT.RIGHT);
-        col1.setText("name");
-        mCol2 = new TableColumn(mTable, SWT.LEFT);
-        mCol2.setText("PlaceHolderContentForWidth");
-
-        TableItem item;
-        for (int i = 0; i < mLabels.length; i++) {
-            item = new TableItem(mTable, SWT.NONE);
-            item.setText(0, mLabels[i]);
-            item.setText(1, "-");
-        }
-
-        col1.pack();
-        mCol2.pack();
-
-        return mTable;
-    }
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mTable.setFocus();
-    }
-
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_PORT}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        if (client == getCurrentClient()) {
-            if ((changeMask & Client.CHANGE_INFO) == Client.CHANGE_INFO) {
-                if (mTable.isDisposed())
-                    return;
-
-                mTable.getDisplay().asyncExec(new Runnable() {
-                    public void run() {
-                        clientSelected();
-                    }
-                });
-            }
-        }
-    }
-
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}
-     */
-    @Override
-    public void deviceSelected() {
-        // pass
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}
-     */
-    @Override
-    public void clientSelected() {
-        if (mTable.isDisposed())
-            return;
-
-        Client client = getCurrentClient();
-
-        if (client == null) {
-            for (int i = 0; i < mLabels.length; i++) {
-                TableItem item = mTable.getItem(i);
-                item.setText(1, "-");
-            }
-        } else {
-            TableItem item;
-            String clientDescription, vmIdentifier, isDdmAware,
-                pid;
-
-            ClientData cd = client.getClientData();
-            synchronized (cd) {
-                clientDescription = (cd.getClientDescription() != null) ?
-                        cd.getClientDescription() : "?";
-                vmIdentifier = (cd.getVmIdentifier() != null) ?
-                        cd.getVmIdentifier() : "?";
-                isDdmAware = cd.isDdmAware() ?
-                        "yes" : "no";
-                pid = (cd.getPid() != 0) ?
-                        String.valueOf(cd.getPid()) : "?";
-            }
-
-            item = mTable.getItem(ENT_APP_DESCR);
-            item.setText(1, clientDescription);
-            item = mTable.getItem(ENT_VM_VERSION);
-            item.setText(1, vmIdentifier);
-            item = mTable.getItem(ENT_DDM_AWARE);
-            item.setText(1, isDdmAware);
-            item = mTable.getItem(ENT_PROCESS_ID);
-            item.setText(1, pid);
-        }
-
-        mCol2.pack();
-
-        //Log.i("ddms", "InfoPanel: changed " + client);
-    }
-
-    @Override
-    protected void setTableFocusListener() {
-        addTableToFocusListener(mTable);
-    }
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/NativeHeapPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/NativeHeapPanel.java
deleted file mode 100644
index 149d689..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/NativeHeapPanel.java
+++ /dev/null
@@ -1,1633 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.NativeAllocationInfo;
-import com.android.ddmlib.NativeLibraryMapInfo;
-import com.android.ddmlib.NativeStackCallInfo;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-import com.android.ddmlib.HeapSegment.HeapSegmentElement;
-import com.android.ddmuilib.annotation.WorkerThread;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.PaletteData;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.layout.FormLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Sash;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.io.BufferedWriter;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.io.PrintWriter;
-import java.text.DecimalFormat;
-import java.text.NumberFormat;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.Iterator;
-
-/**
- * Panel with native heap information.
- */
-public final class NativeHeapPanel extends BaseHeapPanel {
-
-    /** color palette and map legend. NATIVE is the last enum is a 0 based enum list, so we need
-     * Native+1 at least. We also need 2 more entries for free area and expansion area.  */
-    private static final int NUM_PALETTE_ENTRIES = HeapSegmentElement.KIND_NATIVE+2 +1;
-    private static final String[] mMapLegend = new String[NUM_PALETTE_ENTRIES];
-    private static final PaletteData mMapPalette = createPalette();
-    
-    private static final int ALLOC_DISPLAY_ALL = 0;
-    private static final int ALLOC_DISPLAY_PRE_ZYGOTE = 1;
-    private static final int ALLOC_DISPLAY_POST_ZYGOTE = 2;
-
-    private Display mDisplay;
-
-    private Composite mBase;
-
-    private Label mUpdateStatus;
-
-    /** combo giving choice of what to display: all, pre-zygote, post-zygote */
-    private Combo mAllocDisplayCombo;
-
-    private Button mFullUpdateButton;
-
-    // see CreateControl()
-    //private Button mDiffUpdateButton;
-
-    private Combo mDisplayModeCombo;
-
-    /** stack composite for mode (1-2) & 3 */
-    private Composite mTopStackComposite;
-
-    private StackLayout mTopStackLayout;
-
-    /** stack composite for mode 1 & 2 */
-    private Composite mAllocationStackComposite;
-
-    private StackLayout mAllocationStackLayout;
-
-    /** top level container for mode 1 & 2 */
-    private Composite mTableModeControl;
-
-    /** top level object for the allocation mode */
-    private Control mAllocationModeTop;
-
-    /** top level for the library mode */
-    private Control mLibraryModeTopControl;
-
-    /** composite for page UI and total memory display */
-    private Composite mPageUIComposite;
-
-    private Label mTotalMemoryLabel;
-
-    private Label mPageLabel;
-
-    private Button mPageNextButton;
-
-    private Button mPagePreviousButton;
-
-    private Table mAllocationTable;
-
-    private Table mLibraryTable;
-
-    private Table mLibraryAllocationTable;
-
-    private Table mDetailTable;
-
-    private Label mImage;
-    
-    private int mAllocDisplayMode = ALLOC_DISPLAY_ALL;
-
-    /**
-     * pointer to current stackcall thread computation in order to quit it if
-     * required (new update requested)
-     */
-    private StackCallThread mStackCallThread;
-
-    /** Current Library Allocation table fill thread. killed if selection changes */
-    private FillTableThread mFillTableThread;
-
-    /**
-     * current client data. Used to access the malloc info when switching pages
-     * or selecting allocation to show stack call
-     */
-    private ClientData mClientData;
-
-    /**
-     * client data from a previous display. used when asking for an "update & diff"
-     */
-    private ClientData mBackUpClientData;
-
-    /** list of NativeAllocationInfo objects filled with the list from ClientData */
-    private final ArrayList<NativeAllocationInfo> mAllocations =
-        new ArrayList<NativeAllocationInfo>();
-    
-    /** list of the {@link NativeAllocationInfo} being displayed based on the selection
-     * of {@link #mAllocDisplayCombo}.
-     */
-    private final ArrayList<NativeAllocationInfo> mDisplayedAllocations =
-        new ArrayList<NativeAllocationInfo>();
-
-    /** list of NativeAllocationInfo object kept as backup when doing an "update & diff" */
-    private final ArrayList<NativeAllocationInfo> mBackUpAllocations =
-        new ArrayList<NativeAllocationInfo>();
-
-    /** back up of the total memory, used when doing an "update & diff" */
-    private int mBackUpTotalMemory;
-
-    private int mCurrentPage = 0;
-
-    private int mPageCount = 0;
-
-    /**
-     * list of allocation per Library. This is created from the list of
-     * NativeAllocationInfo objects that is stored in the ClientData object. Since we
-     * don't keep this list around, it is recomputed everytime the client
-     * changes.
-     */
-    private final ArrayList<LibraryAllocations> mLibraryAllocations =
-        new ArrayList<LibraryAllocations>();
-
-    /* args to setUpdateStatus() */
-    private static final int NOT_SELECTED = 0;
-
-    private static final int NOT_ENABLED = 1;
-
-    private static final int ENABLED = 2;
-
-    private static final int DISPLAY_PER_PAGE = 20;
-
-    private static final String PREFS_ALLOCATION_SASH = "NHallocSash"; //$NON-NLS-1$
-    private static final String PREFS_LIBRARY_SASH = "NHlibrarySash"; //$NON-NLS-1$
-    private static final String PREFS_DETAIL_ADDRESS = "NHdetailAddress"; //$NON-NLS-1$
-    private static final String PREFS_DETAIL_LIBRARY = "NHdetailLibrary"; //$NON-NLS-1$
-    private static final String PREFS_DETAIL_METHOD = "NHdetailMethod"; //$NON-NLS-1$
-    private static final String PREFS_DETAIL_FILE = "NHdetailFile"; //$NON-NLS-1$
-    private static final String PREFS_DETAIL_LINE = "NHdetailLine"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_TOTAL = "NHallocTotal"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_COUNT = "NHallocCount"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_SIZE = "NHallocSize"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_LIBRARY = "NHallocLib"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_METHOD = "NHallocMethod"; //$NON-NLS-1$
-    private static final String PREFS_ALLOC_FILE = "NHallocFile"; //$NON-NLS-1$
-    private static final String PREFS_LIB_LIBRARY = "NHlibLibrary"; //$NON-NLS-1$
-    private static final String PREFS_LIB_SIZE = "NHlibSize"; //$NON-NLS-1$
-    private static final String PREFS_LIB_COUNT = "NHlibCount"; //$NON-NLS-1$
-    private static final String PREFS_LIBALLOC_TOTAL = "NHlibAllocTotal"; //$NON-NLS-1$
-    private static final String PREFS_LIBALLOC_COUNT = "NHlibAllocCount"; //$NON-NLS-1$
-    private static final String PREFS_LIBALLOC_SIZE = "NHlibAllocSize"; //$NON-NLS-1$
-    private static final String PREFS_LIBALLOC_METHOD = "NHlibAllocMethod"; //$NON-NLS-1$
-
-    /** static formatter object to format all numbers as #,### */
-    private static DecimalFormat sFormatter;
-    static {
-        sFormatter = (DecimalFormat)NumberFormat.getInstance();
-        if (sFormatter != null)
-            sFormatter = new DecimalFormat("#,###");
-        else
-            sFormatter.applyPattern("#,###");
-    }
-
-
-    /**
-     * caching mechanism to avoid recomputing the backtrace for a particular
-     * address several times.
-     */
-    private HashMap<Long, NativeStackCallInfo> mSourceCache =
-        new HashMap<Long,NativeStackCallInfo>();
-    private int mTotalSize;
-    private Button mSaveButton;
-    private Button mSymbolsButton;
-
-    /**
-     * thread class to convert the address call into method, file and line
-     * number in the background.
-     */
-    private class StackCallThread extends BackgroundThread {
-        private ClientData mClientData;
-
-        public StackCallThread(ClientData cd) {
-            mClientData = cd;
-        }
-
-        public ClientData getClientData() {
-            return mClientData;
-        }
-
-        @Override
-        public void run() {
-            // loop through all the NativeAllocationInfo and init them
-            Iterator<NativeAllocationInfo> iter = mAllocations.iterator();
-            int total = mAllocations.size();
-            int count = 0;
-            while (iter.hasNext()) {
-
-                if (isQuitting())
-                    return;
-
-                NativeAllocationInfo info = iter.next();
-                if (info.isStackCallResolved() == false) {
-                    final Long[] list = info.getStackCallAddresses();
-                    final int size = list.length;
-                    
-                    ArrayList<NativeStackCallInfo> resolvedStackCall =
-                        new ArrayList<NativeStackCallInfo>(); 
-
-                    for (int i = 0; i < size; i++) {
-                        long addr = list[i];
-
-                        // first check if the addr has already been converted.
-                        NativeStackCallInfo source = mSourceCache.get(addr);
-
-                        // if not we convert it
-                        if (source == null) {
-                            source = sourceForAddr(addr);
-                            mSourceCache.put(addr, source);
-                        }
-
-                        resolvedStackCall.add(source);
-                    }
-                    
-                    info.setResolvedStackCall(resolvedStackCall);
-                }
-                // after every DISPLAY_PER_PAGE we ask for a ui refresh, unless
-                // we reach total, since we also do it after the loop
-                // (only an issue in case we have a perfect number of page)
-                count++;
-                if ((count % DISPLAY_PER_PAGE) == 0 && count != total) {
-                    if (updateNHAllocationStackCalls(mClientData, count) == false) {
-                        // looks like the app is quitting, so we just
-                        // stopped the thread
-                        return;
-                    }
-                }
-            }
-
-            updateNHAllocationStackCalls(mClientData, count);
-        }
-
-        private NativeStackCallInfo sourceForAddr(long addr) {
-            NativeLibraryMapInfo library = getLibraryFor(addr);
-
-            if (library != null) {
-
-                Addr2Line process = Addr2Line.getProcess(library.getLibraryName());
-                if (process != null) {
-                    // remove the base of the library address
-                    long value = addr - library.getStartAddress();
-                    NativeStackCallInfo info = process.getAddress(value);
-                    if (info != null) {
-                        return info;
-                    }
-                }
-            }
-
-            return new NativeStackCallInfo(library != null ? library.getLibraryName() : null,
-                    Long.toHexString(addr), "");
-        }
-
-        private NativeLibraryMapInfo getLibraryFor(long addr) {
-            Iterator<NativeLibraryMapInfo> it = mClientData.getNativeLibraryMapInfo();
-
-            while (it.hasNext()) {
-                NativeLibraryMapInfo info = it.next();
-
-                if (info.isWithinLibrary(addr)) {
-                    return info;
-                }
-            }
-
-            Log.d("ddm-nativeheap", "Failed finding Library for " + Long.toHexString(addr));
-            return null;
-        }
-
-        /**
-         * update the Native Heap panel with the amount of allocation for which the
-         * stack call has been computed. This is called from a non UI thread, but
-         * will be executed in the UI thread.
-         *
-         * @param count the amount of allocation
-         * @return false if the display was disposed and the update couldn't happen
-         */
-        private boolean updateNHAllocationStackCalls(final ClientData clientData, final int count) {
-            if (mDisplay.isDisposed() == false) {
-                mDisplay.asyncExec(new Runnable() {
-                    public void run() {
-                        updateAllocationStackCalls(clientData, count);
-                    }
-                });
-                return true;
-            }
-            return false;
-        }
-    }
-
-    private class FillTableThread extends BackgroundThread {
-        private LibraryAllocations mLibAlloc;
-
-        private int mMax;
-
-        public FillTableThread(LibraryAllocations liballoc, int m) {
-            mLibAlloc = liballoc;
-            mMax = m;
-        }
-
-        @Override
-        public void run() {
-            for (int i = mMax; i > 0 && isQuitting() == false; i -= 10) {
-                updateNHLibraryAllocationTable(mLibAlloc, mMax - i, mMax - i + 10);
-            }
-        }
-
-        /**
-         * updates the library allocation table in the Native Heap panel. This is
-         * called from a non UI thread, but will be executed in the UI thread.
-         *
-         * @param liballoc the current library allocation object being displayed
-         * @param start start index of items that need to be displayed
-         * @param end end index of the items that need to be displayed
-         */
-        private void updateNHLibraryAllocationTable(final LibraryAllocations libAlloc,
-                final int start, final int end) {
-            if (mDisplay.isDisposed() == false) {
-                mDisplay.asyncExec(new Runnable() {
-                    public void run() {
-                        updateLibraryAllocationTable(libAlloc, start, end);
-                    }
-                });
-            }
-
-        }
-    }
-
-    /** class to aggregate allocations per library */
-    public static class LibraryAllocations {
-        private String mLibrary;
-
-        private final ArrayList<NativeAllocationInfo> mLibAllocations =
-            new ArrayList<NativeAllocationInfo>();
-
-        private int mSize;
-
-        private int mCount;
-
-        /** construct the aggregate object for a library */
-        public LibraryAllocations(final String lib) {
-            mLibrary = lib;
-        }
-
-        /** get the library name */
-        public String getLibrary() {
-            return mLibrary;
-        }
-
-        /** add a NativeAllocationInfo object to this aggregate object */
-        public void addAllocation(NativeAllocationInfo info) {
-            mLibAllocations.add(info);
-        }
-
-        /** get an iterator on the NativeAllocationInfo objects */
-        public Iterator<NativeAllocationInfo> getAllocations() {
-            return mLibAllocations.iterator();
-        }
-
-        /** get a NativeAllocationInfo object by index */
-        public NativeAllocationInfo getAllocation(int index) {
-            return mLibAllocations.get(index);
-        }
-
-        /** returns the NativeAllocationInfo object count */
-        public int getAllocationSize() {
-            return mLibAllocations.size();
-        }
-
-        /** returns the total allocation size */
-        public int getSize() {
-            return mSize;
-        }
-
-        /** returns the number of allocations */
-        public int getCount() {
-            return mCount;
-        }
-
-        /**
-         * compute the allocation count and size for allocation objects added
-         * through <code>addAllocation()</code>, and sort the objects by
-         * total allocation size.
-         */
-        public void computeAllocationSizeAndCount() {
-            mSize = 0;
-            mCount = 0;
-            for (NativeAllocationInfo info : mLibAllocations) {
-                mCount += info.getAllocationCount();
-                mSize += info.getAllocationCount() * info.getSize();
-            }
-            Collections.sort(mLibAllocations, new Comparator<NativeAllocationInfo>() {
-                public int compare(NativeAllocationInfo o1, NativeAllocationInfo o2) {
-                    return o2.getAllocationCount() * o2.getSize() -
-                        o1.getAllocationCount() * o1.getSize();
-                }
-            });
-        }
-    }
-
-    /**
-     * Create our control(s).
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-
-        mDisplay = parent.getDisplay();
-
-        mBase = new Composite(parent, SWT.NONE);
-        GridLayout gl = new GridLayout(1, false);
-        gl.horizontalSpacing = 0;
-        gl.verticalSpacing = 0;
-        mBase.setLayout(gl);
-        mBase.setLayoutData(new GridData(GridData.FILL_BOTH));
-        
-        // composite for <update btn> <status>
-        Composite tmp = new Composite(mBase, SWT.NONE);
-        tmp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        tmp.setLayout(gl = new GridLayout(2, false));
-        gl.marginWidth = gl.marginHeight = 0;
-
-        mFullUpdateButton = new Button(tmp, SWT.NONE);
-        mFullUpdateButton.setText("Full Update");
-        mFullUpdateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mBackUpClientData = null;
-                mDisplayModeCombo.setEnabled(false);
-                mSaveButton.setEnabled(false);
-                emptyTables();
-                // if we already have a stack call computation for this
-                // client
-                // we stop it
-                if (mStackCallThread != null &&
-                        mStackCallThread.getClientData() == mClientData) {
-                    mStackCallThread.quit();
-                    mStackCallThread = null;
-                }
-                mLibraryAllocations.clear();
-                Client client = getCurrentClient();
-                if (client != null) {
-                    client.requestNativeHeapInformation();
-                }
-            }
-        });
-
-        mUpdateStatus = new Label(tmp, SWT.NONE);
-        mUpdateStatus.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // top layout for the combos and oter controls on the right.
-        Composite top_layout = new Composite(mBase, SWT.NONE);
-        top_layout.setLayout(gl = new GridLayout(4, false));
-        gl.marginWidth = gl.marginHeight = 0;
-        
-        new Label(top_layout, SWT.NONE).setText("Show:");
-        
-        mAllocDisplayCombo = new Combo(top_layout, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mAllocDisplayCombo.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mAllocDisplayCombo.add("All Allocations");
-        mAllocDisplayCombo.add("Pre-Zygote Allocations");
-        mAllocDisplayCombo.add("Zygote Child Allocations (Z)");
-        mAllocDisplayCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onAllocDisplayChange();
-            }
-        });
-        mAllocDisplayCombo.select(0);
-        
-        // separator
-        Label separator = new Label(top_layout, SWT.SEPARATOR | SWT.VERTICAL);
-        GridData gd;
-        separator.setLayoutData(gd = new GridData(
-                GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL));
-        gd.heightHint = 0;
-        gd.verticalSpan = 2;
-
-        mSaveButton = new Button(top_layout, SWT.PUSH);
-        mSaveButton.setText("Save...");
-        mSaveButton.setEnabled(false);
-        mSaveButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                FileDialog fileDialog = new FileDialog(mBase.getShell(), SWT.SAVE);
-
-                fileDialog.setText("Save Allocations");
-                fileDialog.setFileName("allocations.txt");
-
-                String fileName = fileDialog.open();
-                if (fileName != null) {
-                    saveAllocations(fileName);
-                }
-            }
-        });
-        
-        /*
-         * TODO: either fix the diff mechanism or remove it altogether.
-        mDiffUpdateButton = new Button(top_layout, SWT.NONE);
-        mDiffUpdateButton.setText("Update && Diff");
-        mDiffUpdateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // since this is an update and diff, we need to store the
-                // current list
-                // of mallocs
-                mBackUpAllocations.clear();
-                mBackUpAllocations.addAll(mAllocations);
-                mBackUpClientData = mClientData;
-                mBackUpTotalMemory = mClientData.getTotalNativeMemory();
-
-                mDisplayModeCombo.setEnabled(false);
-                emptyTables();
-                // if we already have a stack call computation for this
-                // client
-                // we stop it
-                if (mStackCallThread != null &&
-                        mStackCallThread.getClientData() == mClientData) {
-                    mStackCallThread.quit();
-                    mStackCallThread = null;
-                }
-                mLibraryAllocations.clear();
-                Client client = getCurrentClient();
-                if (client != null) {
-                    client.requestNativeHeapInformation();
-                }
-            }
-        });
-        */
-
-        Label l = new Label(top_layout, SWT.NONE);
-        l.setText("Display:");
-
-        mDisplayModeCombo = new Combo(top_layout, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mDisplayModeCombo.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mDisplayModeCombo.setItems(new String[] { "Allocation List", "By Libraries" });
-        mDisplayModeCombo.select(0);
-        mDisplayModeCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                switchDisplayMode();
-            }
-        });
-        mDisplayModeCombo.setEnabled(false);
-        
-        mSymbolsButton = new Button(top_layout, SWT.PUSH);
-        mSymbolsButton.setText("Load Symbols");
-        mSymbolsButton.setEnabled(false);
-
-
-        // create a composite that will contains the actual content composites,
-        // in stack mode layout.
-        // This top level composite contains 2 other composites.
-        // * one for both Allocations and Libraries mode
-        // * one for flat mode (which is gone for now)
-
-        mTopStackComposite = new Composite(mBase, SWT.NONE);
-        mTopStackComposite.setLayout(mTopStackLayout = new StackLayout());
-        mTopStackComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // create 1st and 2nd modes
-        createTableDisplay(mTopStackComposite);
-
-        mTopStackLayout.topControl = mTableModeControl;
-        mTopStackComposite.layout();
-
-        setUpdateStatus(NOT_SELECTED);
-
-        // Work in progress
-        // TODO add image display of native heap.
-        //mImage = new Label(mBase, SWT.NONE);
-
-        mBase.pack();
-
-        return mBase;
-    }
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        // TODO
-    }
-
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        if (client == getCurrentClient()) {
-            if ((changeMask & Client.CHANGE_NATIVE_HEAP_DATA) == Client.CHANGE_NATIVE_HEAP_DATA) {
-                if (mBase.isDisposed())
-                    return;
-
-                mBase.getDisplay().asyncExec(new Runnable() {
-                    public void run() {
-                        clientSelected();
-                    }
-                });
-            }
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}.
-     */
-    @Override
-    public void deviceSelected() {
-        // pass
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-        if (mBase.isDisposed())
-            return;
-
-        Client client = getCurrentClient();
-
-        mDisplayModeCombo.setEnabled(false);
-        emptyTables();
-
-        Log.d("ddms", "NativeHeapPanel: changed " + client);
-
-        if (client != null) {
-            ClientData cd = client.getClientData();
-            mClientData = cd;
-
-            // if (cd.getShowHeapUpdates())
-            setUpdateStatus(ENABLED);
-            // else
-            // setUpdateStatus(NOT_ENABLED);
-
-            initAllocationDisplay();
-
-            //renderBitmap(cd);
-        } else {
-            mClientData = null;
-            setUpdateStatus(NOT_SELECTED);
-        }
-
-        mBase.pack();
-    }
-
-    /**
-     * Update the UI with the newly compute stack calls, unless the UI switched
-     * to a different client.
-     *
-     * @param cd the ClientData for which the stack call are being computed.
-     * @param count the current count of allocations for which the stack calls
-     *            have been computed.
-     */
-    @WorkerThread
-    public void updateAllocationStackCalls(ClientData cd, int count) {
-        // we have to check that the panel still shows the same clientdata than
-        // the thread is computing for.
-        if (cd == mClientData) {
-
-            int total = mAllocations.size();
-
-            if (count == total) {
-                // we're done: do something
-                mDisplayModeCombo.setEnabled(true);
-                mSaveButton.setEnabled(true);
-                
-                mStackCallThread = null;
-            } else {
-                // work in progress, update the progress bar.
-//                mUiThread.setStatusLine("Computing stack call: " + count
-//                        + "/" + total);
-            }
-
-            // FIXME: attempt to only update when needed.
-            // Because the number of pages is not related to mAllocations.size() anymore
-            // due to pre-zygote/post-zygote display, update all the time.
-            // At some point we should remove the pages anyway, since it's getting computed
-            // really fast now.
-//            if ((mCurrentPage + 1) * DISPLAY_PER_PAGE == count
-//                    || (count == total && mCurrentPage == mPageCount - 1)) {
-            try {
-                // get the current selection of the allocation
-                int index = mAllocationTable.getSelectionIndex();
-                NativeAllocationInfo info = null;
-                
-                if (index != -1) {
-                    info = (NativeAllocationInfo)mAllocationTable.getItem(index).getData();
-                }
-
-                // empty the table
-                emptyTables();
-
-                // fill it again
-                fillAllocationTable();
-
-                // reselect
-                mAllocationTable.setSelection(index);
-
-                // display detail table if needed
-                if (info != null) {
-                    fillDetailTable(info);
-                }
-            } catch (SWTException e) {
-                if (mAllocationTable.isDisposed()) {
-                    // looks like the table is disposed. Let's ignore it.
-                } else {
-                    throw e;
-                }
-            }
-
-        } else {
-            // old client still running. doesn't really matter.
-        }
-    }
-
-    @Override
-    protected void setTableFocusListener() {
-        addTableToFocusListener(mAllocationTable);
-        addTableToFocusListener(mLibraryTable);
-        addTableToFocusListener(mLibraryAllocationTable);
-        addTableToFocusListener(mDetailTable);
-    }
-    
-    protected void onAllocDisplayChange() {
-        mAllocDisplayMode = mAllocDisplayCombo.getSelectionIndex();
-        
-        // create the new list
-        updateAllocDisplayList();
-        
-        updateTotalMemoryDisplay();
-
-        // reset the ui.
-        mCurrentPage = 0;
-        updatePageUI();
-        switchDisplayMode();
-    }
-    
-    private void updateAllocDisplayList() {
-        mTotalSize = 0;
-        mDisplayedAllocations.clear();
-        for (NativeAllocationInfo info : mAllocations) {
-            if (mAllocDisplayMode == ALLOC_DISPLAY_ALL ||
-                    (mAllocDisplayMode == ALLOC_DISPLAY_PRE_ZYGOTE ^ info.isZygoteChild())) {
-                mDisplayedAllocations.add(info);
-                mTotalSize += info.getSize() * info.getAllocationCount();
-            } else {
-                // skip this item
-                continue;
-            }
-        }
-        
-        int count = mDisplayedAllocations.size();
-        
-        mPageCount = count / DISPLAY_PER_PAGE;
-
-        // need to add a page for the rest of the div
-        if ((count % DISPLAY_PER_PAGE) > 0) {
-            mPageCount++;
-        }
-    }
-    
-    private void updateTotalMemoryDisplay() {
-        switch (mAllocDisplayMode) {
-            case ALLOC_DISPLAY_ALL:
-                mTotalMemoryLabel.setText(String.format("Total Memory: %1$s Bytes",
-                        sFormatter.format(mTotalSize)));
-                break;
-            case ALLOC_DISPLAY_PRE_ZYGOTE:
-                mTotalMemoryLabel.setText(String.format("Zygote Memory: %1$s Bytes",
-                        sFormatter.format(mTotalSize)));
-                break;
-            case ALLOC_DISPLAY_POST_ZYGOTE:
-                mTotalMemoryLabel.setText(String.format("Post-zygote Memory: %1$s Bytes",
-                        sFormatter.format(mTotalSize)));
-                break;
-        }
-    }
-
-
-    private void switchDisplayMode() {
-        switch (mDisplayModeCombo.getSelectionIndex()) {
-            case 0: {// allocations
-                mTopStackLayout.topControl = mTableModeControl;
-                mAllocationStackLayout.topControl = mAllocationModeTop;
-                mAllocationStackComposite.layout();
-                mTopStackComposite.layout();
-                emptyTables();
-                fillAllocationTable();
-            }
-                break;
-            case 1: {// libraries
-                mTopStackLayout.topControl = mTableModeControl;
-                mAllocationStackLayout.topControl = mLibraryModeTopControl;
-                mAllocationStackComposite.layout();
-                mTopStackComposite.layout();
-                emptyTables();
-                fillLibraryTable();
-            }
-                break;
-        }
-    }
-
-    private void initAllocationDisplay() {
-        mAllocations.clear();
-        mAllocations.addAll(mClientData.getNativeAllocationList());
-        
-        updateAllocDisplayList();
-
-        // if we have a previous clientdata and it matches the current one. we
-        // do a diff between the new list and the old one.
-        if (mBackUpClientData != null && mBackUpClientData == mClientData) {
-
-            ArrayList<NativeAllocationInfo> add = new ArrayList<NativeAllocationInfo>();
-
-            // we go through the list of NativeAllocationInfo in the new list and check if
-            // there's one with the same exact data (size, allocation, count and
-            // stackcall addresses) in the old list.
-            // if we don't find any, we add it to the "add" list
-            for (NativeAllocationInfo mi : mAllocations) {
-                boolean found = false;
-                for (NativeAllocationInfo old_mi : mBackUpAllocations) {
-                    if (mi.equals(old_mi)) {
-                        found = true;
-                        break;
-                    }
-                }
-                if (found == false) {
-                    add.add(mi);
-                }
-            }
-
-            // put the result in mAllocations
-            mAllocations.clear();
-            mAllocations.addAll(add);
-
-            // display the difference in memory usage. This is computed
-            // calculating the memory usage of the objects in mAllocations.
-            int count = 0;
-            for (NativeAllocationInfo allocInfo : mAllocations) {
-                count += allocInfo.getSize() * allocInfo.getAllocationCount();
-            }
-
-            mTotalMemoryLabel.setText(String.format("Memory Difference: %1$s Bytes",
-                    sFormatter.format(count)));
-        }
-        else {
-            // display the full memory usage
-            updateTotalMemoryDisplay();
-            //mDiffUpdateButton.setEnabled(mClientData.getTotalNativeMemory() > 0);
-        }
-        mTotalMemoryLabel.pack();
-
-        // update the page ui
-        mDisplayModeCombo.select(0);
-
-        mLibraryAllocations.clear();
-
-        // reset to first page
-        mCurrentPage = 0;
-
-        // update the label
-        updatePageUI();
-
-        // now fill the allocation Table with the current page
-        switchDisplayMode();
-
-        // start the thread to compute the stack calls
-        if (mAllocations.size() > 0) {
-            mStackCallThread = new StackCallThread(mClientData);
-            mStackCallThread.start();
-        }
-    }
-
-    private void updatePageUI() {
-
-        // set the label and pack to update the layout, otherwise
-        // the label will be cut off if the new size is bigger
-        if (mPageCount == 0) {
-            mPageLabel.setText("0 of 0 allocations.");
-        } else {
-            StringBuffer buffer = new StringBuffer();
-            // get our starting index
-            int start = (mCurrentPage * DISPLAY_PER_PAGE) + 1;
-            // end index, taking into account the last page can be half full
-            int count = mDisplayedAllocations.size();
-            int end = Math.min(start + DISPLAY_PER_PAGE - 1, count);
-            buffer.append(sFormatter.format(start));
-            buffer.append(" - ");
-            buffer.append(sFormatter.format(end));
-            buffer.append(" of ");
-            buffer.append(sFormatter.format(count));
-            buffer.append(" allocations.");
-            mPageLabel.setText(buffer.toString());
-        }
-
-        // handle the button enabled state.
-        mPagePreviousButton.setEnabled(mCurrentPage > 0);
-        // reminder: mCurrentPage starts at 0.
-        mPageNextButton.setEnabled(mCurrentPage < mPageCount - 1);
-
-        mPageLabel.pack();
-        mPageUIComposite.pack();
-
-    }
-
-    private void fillAllocationTable() {
-        // get the count
-        int count = mDisplayedAllocations.size();
-
-        // get our starting index
-        int start = mCurrentPage * DISPLAY_PER_PAGE;
-
-        // loop for DISPLAY_PER_PAGE or till we reach count
-        int end = start + DISPLAY_PER_PAGE;
-
-        for (int i = start; i < end && i < count; i++) {
-            NativeAllocationInfo info = mDisplayedAllocations.get(i);
-
-            TableItem item = null;
-
-            if (mAllocDisplayMode == ALLOC_DISPLAY_ALL)  {
-                item = new TableItem(mAllocationTable, SWT.NONE);
-                item.setText(0, (info.isZygoteChild() ? "Z " : "") +
-                        sFormatter.format(info.getSize() * info.getAllocationCount()));
-                item.setText(1, sFormatter.format(info.getAllocationCount()));
-                item.setText(2, sFormatter.format(info.getSize()));
-            } else if (mAllocDisplayMode == ALLOC_DISPLAY_PRE_ZYGOTE ^ info.isZygoteChild()) {
-                item = new TableItem(mAllocationTable, SWT.NONE);
-                item.setText(0, sFormatter.format(info.getSize() * info.getAllocationCount()));
-                item.setText(1, sFormatter.format(info.getAllocationCount()));
-                item.setText(2, sFormatter.format(info.getSize()));
-            } else {
-                // skip this item
-                continue;
-            }
-
-            item.setData(info);
-
-            NativeStackCallInfo bti = info.getRelevantStackCallInfo();
-            if (bti != null) {
-                String lib = bti.getLibraryName();
-                String method = bti.getMethodName();
-                String source = bti.getSourceFile();
-                if (lib != null)
-                    item.setText(3, lib);
-                if (method != null)
-                    item.setText(4, method);
-                if (source != null)
-                    item.setText(5, source);
-            }
-        }
-    }
-
-    private void fillLibraryTable() {
-        // fill the library table
-        sortAllocationsPerLibrary();
-
-        for (LibraryAllocations liballoc : mLibraryAllocations) {
-            if (liballoc != null) {
-                TableItem item = new TableItem(mLibraryTable, SWT.NONE);
-                String lib = liballoc.getLibrary();
-                item.setText(0, lib != null ? lib : "");
-                item.setText(1, sFormatter.format(liballoc.getSize()));
-                item.setText(2, sFormatter.format(liballoc.getCount()));
-            }
-        }
-    }
-
-    private void fillLibraryAllocationTable() {
-        mLibraryAllocationTable.removeAll();
-        mDetailTable.removeAll();
-        int index = mLibraryTable.getSelectionIndex();
-        if (index != -1) {
-            LibraryAllocations liballoc = mLibraryAllocations.get(index);
-            // start a thread that will fill table 10 at a time to keep the ui
-            // responsive, but first we kill the previous one if there was one
-            if (mFillTableThread != null) {
-                mFillTableThread.quit();
-            }
-            mFillTableThread = new FillTableThread(liballoc,
-                    liballoc.getAllocationSize());
-            mFillTableThread.start();
-        }
-    }
-
-    public void updateLibraryAllocationTable(LibraryAllocations liballoc,
-            int start, int end) {
-        try {
-            if (mLibraryTable.isDisposed() == false) {
-                int index = mLibraryTable.getSelectionIndex();
-                if (index != -1) {
-                    LibraryAllocations newliballoc = mLibraryAllocations.get(
-                            index);
-                    if (newliballoc == liballoc) {
-                        int count = liballoc.getAllocationSize();
-                        for (int i = start; i < end && i < count; i++) {
-                            NativeAllocationInfo info = liballoc.getAllocation(i);
-
-                            TableItem item = new TableItem(
-                                    mLibraryAllocationTable, SWT.NONE);
-                            item.setText(0, sFormatter.format(
-                                    info.getSize() * info.getAllocationCount()));
-                            item.setText(1, sFormatter.format(info.getAllocationCount()));
-                            item.setText(2, sFormatter.format(info.getSize()));
-
-                            NativeStackCallInfo stackCallInfo = info.getRelevantStackCallInfo();
-                            if (stackCallInfo != null) {
-                                item.setText(3, stackCallInfo.getMethodName());
-                            }
-                        }
-                    } else {
-                        // we should quit the thread
-                        if (mFillTableThread != null) {
-                            mFillTableThread.quit();
-                            mFillTableThread = null;
-                        }
-                    }
-                }
-            }
-        } catch (SWTException e) {
-            Log.e("ddms", "error when updating the library allocation table");
-        }
-    }
-
-    private void fillDetailTable(final NativeAllocationInfo mi) {
-        mDetailTable.removeAll();
-        mDetailTable.setRedraw(false);
-        
-        try {
-            // populate the detail Table with the back trace
-            Long[] addresses = mi.getStackCallAddresses();
-            NativeStackCallInfo[] resolvedStackCall = mi.getResolvedStackCall();
-            
-            if (resolvedStackCall == null) {
-                return;
-            }
-
-            for (int i = 0 ; i < resolvedStackCall.length ; i++) {
-                if (addresses[i] == null || addresses[i].longValue() == 0) {
-                    continue;
-                }
-                
-                long addr = addresses[i].longValue();
-                NativeStackCallInfo source = resolvedStackCall[i];
-                
-                TableItem item = new TableItem(mDetailTable, SWT.NONE);
-                item.setText(0, String.format("%08x", addr)); //$NON-NLS-1$
-    
-                String libraryName = source.getLibraryName();
-                String methodName = source.getMethodName();
-                String sourceFile = source.getSourceFile();
-                int lineNumber = source.getLineNumber();
-                
-                if (libraryName != null)
-                    item.setText(1, libraryName);
-                if (methodName != null)
-                    item.setText(2, methodName);
-                if (sourceFile != null)
-                    item.setText(3, sourceFile);
-                if (lineNumber != -1)
-                    item.setText(4, Integer.toString(lineNumber));
-            }
-        } finally {
-            mDetailTable.setRedraw(true);
-        }
-    }
-
-    /*
-     * Are updates enabled?
-     */
-    private void setUpdateStatus(int status) {
-        switch (status) {
-            case NOT_SELECTED:
-                mUpdateStatus.setText("Select a client to see heap info");
-                mAllocDisplayCombo.setEnabled(false);
-                mFullUpdateButton.setEnabled(false);
-                //mDiffUpdateButton.setEnabled(false);
-                break;
-            case NOT_ENABLED:
-                mUpdateStatus.setText("Heap updates are " + "NOT ENABLED for this client");
-                mAllocDisplayCombo.setEnabled(false);
-                mFullUpdateButton.setEnabled(false);
-                //mDiffUpdateButton.setEnabled(false);
-                break;
-            case ENABLED:
-                mUpdateStatus.setText("Press 'Full Update' to retrieve " + "latest data");
-                mAllocDisplayCombo.setEnabled(true);
-                mFullUpdateButton.setEnabled(true);
-                //mDiffUpdateButton.setEnabled(true);
-                break;
-            default:
-                throw new RuntimeException();
-        }
-
-        mUpdateStatus.pack();
-    }
-
-    /**
-     * Create the Table display. This includes a "detail" Table in the bottom
-     * half and 2 modes in the top half: allocation Table and
-     * library+allocations Tables.
-     *
-     * @param base the top parent to create the display into
-     */
-    private void createTableDisplay(Composite base) {
-        final int minPanelWidth = 60;
-
-        final IPreferenceStore prefs = DdmUiPreferences.getStore();
-
-        // top level composite for mode 1 & 2
-        mTableModeControl = new Composite(base, SWT.NONE);
-        GridLayout gl = new GridLayout(1, false);
-        gl.marginLeft = gl.marginRight = gl.marginTop = gl.marginBottom = 0;
-        mTableModeControl.setLayout(gl);
-        mTableModeControl.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        mTotalMemoryLabel = new Label(mTableModeControl, SWT.NONE);
-        mTotalMemoryLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mTotalMemoryLabel.setText("Total Memory: 0 Bytes");
-
-        // the top half of these modes is dynamic
-
-        final Composite sash_composite = new Composite(mTableModeControl,
-                SWT.NONE);
-        sash_composite.setLayout(new FormLayout());
-        sash_composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // create the stacked composite
-        mAllocationStackComposite = new Composite(sash_composite, SWT.NONE);
-        mAllocationStackLayout = new StackLayout();
-        mAllocationStackComposite.setLayout(mAllocationStackLayout);
-        mAllocationStackComposite.setLayoutData(new GridData(
-                GridData.FILL_BOTH));
-
-        // create the top half for mode 1
-        createAllocationTopHalf(mAllocationStackComposite);
-
-        // create the top half for mode 2
-        createLibraryTopHalf(mAllocationStackComposite);
-
-        final Sash sash = new Sash(sash_composite, SWT.HORIZONTAL);
-
-        // bottom half of these modes is the same: detail table
-        createDetailTable(sash_composite);
-
-        // init value for stack
-        mAllocationStackLayout.topControl = mAllocationModeTop;
-
-        // form layout data
-        FormData data = new FormData();
-        data.top = new FormAttachment(mTotalMemoryLabel, 0);
-        data.bottom = new FormAttachment(sash, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        mAllocationStackComposite.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        if (prefs != null && prefs.contains(PREFS_ALLOCATION_SASH)) {
-            sashData.top = new FormAttachment(0,
-                    prefs.getInt(PREFS_ALLOCATION_SASH));
-        } else {
-            sashData.top = new FormAttachment(50, 0); // 50% across
-        }
-        sashData.left = new FormAttachment(0, 0);
-        sashData.right = new FormAttachment(100, 0);
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(sash, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        mDetailTable.setLayoutData(data);
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = sash_composite.getClientArea();
-                int bottom = panelRect.height - sashRect.height - minPanelWidth;
-                e.y = Math.max(Math.min(e.y, bottom), minPanelWidth);
-                if (e.y != sashRect.y) {
-                    sashData.top = new FormAttachment(0, e.y);
-                    prefs.setValue(PREFS_ALLOCATION_SASH, e.y);
-                    sash_composite.layout();
-                }
-            }
-        });
-    }
-
-    private void createDetailTable(Composite base) {
-
-        final IPreferenceStore prefs = DdmUiPreferences.getStore();
-
-        mDetailTable = new Table(base, SWT.MULTI | SWT.FULL_SELECTION);
-        mDetailTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mDetailTable.setHeaderVisible(true);
-        mDetailTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mDetailTable, "Address", SWT.RIGHT,
-                "00000000", PREFS_DETAIL_ADDRESS, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mDetailTable, "Library", SWT.LEFT,
-                "abcdefghijklmnopqrst", PREFS_DETAIL_LIBRARY, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mDetailTable, "Method", SWT.LEFT,
-                "abcdefghijklmnopqrst", PREFS_DETAIL_METHOD, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mDetailTable, "File", SWT.LEFT,
-                "abcdefghijklmnopqrstuvwxyz", PREFS_DETAIL_FILE, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mDetailTable, "Line", SWT.RIGHT,
-                "9,999", PREFS_DETAIL_LINE, prefs); //$NON-NLS-1$
-    }
-
-    private void createAllocationTopHalf(Composite b) {
-        final IPreferenceStore prefs = DdmUiPreferences.getStore();
-
-        Composite base = new Composite(b, SWT.NONE);
-        mAllocationModeTop = base;
-        GridLayout gl = new GridLayout(1, false);
-        gl.marginLeft = gl.marginRight = gl.marginTop = gl.marginBottom = 0;
-        gl.verticalSpacing = 0;
-        base.setLayout(gl);
-        base.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // horizontal layout for memory total and pages UI
-        mPageUIComposite = new Composite(base, SWT.NONE);
-        mPageUIComposite.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_BEGINNING));
-        gl = new GridLayout(3, false);
-        gl.marginLeft = gl.marginRight = gl.marginTop = gl.marginBottom = 0;
-        gl.horizontalSpacing = 0;
-        mPageUIComposite.setLayout(gl);
-
-        // Page UI
-        mPagePreviousButton = new Button(mPageUIComposite, SWT.NONE);
-        mPagePreviousButton.setText("<");
-        mPagePreviousButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mCurrentPage--;
-                updatePageUI();
-                emptyTables();
-                fillAllocationTable();
-            }
-        });
-
-        mPageNextButton = new Button(mPageUIComposite, SWT.NONE);
-        mPageNextButton.setText(">");
-        mPageNextButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mCurrentPage++;
-                updatePageUI();
-                emptyTables();
-                fillAllocationTable();
-            }
-        });
-
-        mPageLabel = new Label(mPageUIComposite, SWT.NONE);
-        mPageLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        updatePageUI();
-
-        mAllocationTable = new Table(base, SWT.MULTI | SWT.FULL_SELECTION);
-        mAllocationTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mAllocationTable.setHeaderVisible(true);
-        mAllocationTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mAllocationTable, "Total", SWT.RIGHT,
-                "9,999,999", PREFS_ALLOC_TOTAL, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mAllocationTable, "Count", SWT.RIGHT,
-                "9,999", PREFS_ALLOC_COUNT, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mAllocationTable, "Size", SWT.RIGHT,
-                "999,999", PREFS_ALLOC_SIZE, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mAllocationTable, "Library", SWT.LEFT,
-                "abcdefghijklmnopqrst", PREFS_ALLOC_LIBRARY, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mAllocationTable, "Method", SWT.LEFT,
-                "abcdefghijklmnopqrst", PREFS_ALLOC_METHOD, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mAllocationTable, "File", SWT.LEFT,
-                "abcdefghijklmnopqrstuvwxyz", PREFS_ALLOC_FILE, prefs); //$NON-NLS-1$
-
-        mAllocationTable.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get the selection index
-                int index = mAllocationTable.getSelectionIndex();
-                TableItem item = mAllocationTable.getItem(index);
-                if (item != null && item.getData() instanceof NativeAllocationInfo) {
-                    fillDetailTable((NativeAllocationInfo)item.getData());
-                }
-            }
-        });
-    }
-
-    private void createLibraryTopHalf(Composite base) {
-        final int minPanelWidth = 60;
-
-        final IPreferenceStore prefs = DdmUiPreferences.getStore();
-
-        // create a composite that'll contain 2 tables horizontally
-        final Composite top = new Composite(base, SWT.NONE);
-        mLibraryModeTopControl = top;
-        top.setLayout(new FormLayout());
-        top.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // first table: library
-        mLibraryTable = new Table(top, SWT.MULTI | SWT.FULL_SELECTION);
-        mLibraryTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mLibraryTable.setHeaderVisible(true);
-        mLibraryTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mLibraryTable, "Library", SWT.LEFT,
-                "abcdefghijklmnopqrstuvwxyz", PREFS_LIB_LIBRARY, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mLibraryTable, "Size", SWT.RIGHT,
-                "9,999,999", PREFS_LIB_SIZE, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mLibraryTable, "Count", SWT.RIGHT,
-                "9,999", PREFS_LIB_COUNT, prefs); //$NON-NLS-1$
-
-        mLibraryTable.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                fillLibraryAllocationTable();
-            }
-        });
-
-        final Sash sash = new Sash(top, SWT.VERTICAL);
-
-        // 2nd table: allocation per library
-        mLibraryAllocationTable = new Table(top, SWT.MULTI | SWT.FULL_SELECTION);
-        mLibraryAllocationTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mLibraryAllocationTable.setHeaderVisible(true);
-        mLibraryAllocationTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mLibraryAllocationTable, "Total",
-                SWT.RIGHT, "9,999,999", PREFS_LIBALLOC_TOTAL, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mLibraryAllocationTable, "Count",
-                SWT.RIGHT, "9,999", PREFS_LIBALLOC_COUNT, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mLibraryAllocationTable, "Size",
-                SWT.RIGHT, "999,999", PREFS_LIBALLOC_SIZE, prefs); //$NON-NLS-1$
-        TableHelper.createTableColumn(mLibraryAllocationTable, "Method",
-                SWT.LEFT, "abcdefghijklmnopqrst", PREFS_LIBALLOC_METHOD, prefs); //$NON-NLS-1$
-
-        mLibraryAllocationTable.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get the index of the selection in the library table
-                int index1 = mLibraryTable.getSelectionIndex();
-                // get the index in the library allocation table
-                int index2 = mLibraryAllocationTable.getSelectionIndex();
-                // get the MallocInfo object
-                LibraryAllocations liballoc = mLibraryAllocations.get(index1);
-                NativeAllocationInfo info = liballoc.getAllocation(index2);
-                fillDetailTable(info);
-            }
-        });
-
-        // form layout data
-        FormData data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(sash, 0);
-        mLibraryTable.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        if (prefs != null && prefs.contains(PREFS_LIBRARY_SASH)) {
-            sashData.left = new FormAttachment(0,
-                    prefs.getInt(PREFS_LIBRARY_SASH));
-        } else {
-            sashData.left = new FormAttachment(50, 0);
-        }
-        sashData.bottom = new FormAttachment(100, 0);
-        sashData.top = new FormAttachment(0, 0); // 50% across
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(sash, 0);
-        data.right = new FormAttachment(100, 0);
-        mLibraryAllocationTable.setLayoutData(data);
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = top.getClientArea();
-                int right = panelRect.width - sashRect.width - minPanelWidth;
-                e.x = Math.max(Math.min(e.x, right), minPanelWidth);
-                if (e.x != sashRect.x) {
-                    sashData.left = new FormAttachment(0, e.x);
-                    prefs.setValue(PREFS_LIBRARY_SASH, e.y);
-                    top.layout();
-                }
-            }
-        });
-    }
-
-    private void emptyTables() {
-        mAllocationTable.removeAll();
-        mLibraryTable.removeAll();
-        mLibraryAllocationTable.removeAll();
-        mDetailTable.removeAll();
-    }
-
-    private void sortAllocationsPerLibrary() {
-        if (mClientData != null) {
-            mLibraryAllocations.clear();
-            
-            // create a hash map of LibraryAllocations to access aggregate
-            // objects already created
-            HashMap<String, LibraryAllocations> libcache =
-                new HashMap<String, LibraryAllocations>();
-
-            // get the allocation count
-            int count = mDisplayedAllocations.size();
-            for (int i = 0; i < count; i++) {
-                NativeAllocationInfo allocInfo = mDisplayedAllocations.get(i);
-
-                NativeStackCallInfo stackCallInfo = allocInfo.getRelevantStackCallInfo();
-                if (stackCallInfo != null) {
-                    String libraryName = stackCallInfo.getLibraryName();
-                    LibraryAllocations liballoc = libcache.get(libraryName);
-                    if (liballoc == null) {
-                        // didn't find a library allocation object already
-                        // created so we create one
-                        liballoc = new LibraryAllocations(libraryName);
-                        // add it to the cache
-                        libcache.put(libraryName, liballoc);
-                        // add it to the list
-                        mLibraryAllocations.add(liballoc);
-                    }
-                    // add the MallocInfo object to it.
-                    liballoc.addAllocation(allocInfo);
-                }
-            }
-            // now that the list is created, we need to compute the size and
-            // sort it by size. This will also sort the MallocInfo objects
-            // inside each LibraryAllocation objects.
-            for (LibraryAllocations liballoc : mLibraryAllocations) {
-                liballoc.computeAllocationSizeAndCount();
-            }
-
-            // now we sort it
-            Collections.sort(mLibraryAllocations,
-                    new Comparator<LibraryAllocations>() {
-                public int compare(LibraryAllocations o1,
-                        LibraryAllocations o2) {
-                    return o2.getSize() - o1.getSize();
-                }
-            });
-        }
-    }
-
-    private void renderBitmap(ClientData cd) {
-        byte[] pixData;
-
-        // Atomically get and clear the heap data.
-        synchronized (cd) {
-            if (serializeHeapData(cd.getVmHeapData()) == false) {
-                // no change, we return.
-                return;
-            }
-
-            pixData = getSerializedData();
-
-            ImageData id = createLinearHeapImage(pixData, 200, mMapPalette);
-            Image image = new Image(mBase.getDisplay(), id);
-            mImage.setImage(image);
-            mImage.pack(true);
-        }
-    }
-
-    /*
-     * Create color palette for map.  Set up titles for legend.
-     */
-    private static PaletteData createPalette() {
-        RGB colors[] = new RGB[NUM_PALETTE_ENTRIES];
-        colors[0]
-                = new RGB(192, 192, 192); // non-heap pixels are gray
-        mMapLegend[0]
-                = "(heap expansion area)";
-
-        colors[1]
-                = new RGB(0, 0, 0);       // free chunks are black
-        mMapLegend[1]
-                = "free";
-
-        colors[HeapSegmentElement.KIND_OBJECT + 2]
-                = new RGB(0, 0, 255);     // objects are blue
-        mMapLegend[HeapSegmentElement.KIND_OBJECT + 2]
-                = "data object";
-
-        colors[HeapSegmentElement.KIND_CLASS_OBJECT + 2]
-                = new RGB(0, 255, 0);     // class objects are green
-        mMapLegend[HeapSegmentElement.KIND_CLASS_OBJECT + 2]
-                = "class object";
-
-        colors[HeapSegmentElement.KIND_ARRAY_1 + 2]
-                = new RGB(255, 0, 0);     // byte/bool arrays are red
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_1 + 2]
-                = "1-byte array (byte[], boolean[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_2 + 2]
-                = new RGB(255, 128, 0);   // short/char arrays are orange
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_2 + 2]
-                = "2-byte array (short[], char[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_4 + 2]
-                = new RGB(255, 255, 0);   // obj/int/float arrays are yellow
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_4 + 2]
-                = "4-byte array (object[], int[], float[])";
-
-        colors[HeapSegmentElement.KIND_ARRAY_8 + 2]
-                = new RGB(255, 128, 128); // long/double arrays are pink
-        mMapLegend[HeapSegmentElement.KIND_ARRAY_8 + 2]
-                = "8-byte array (long[], double[])";
-
-        colors[HeapSegmentElement.KIND_UNKNOWN + 2]
-                = new RGB(255, 0, 255);   // unknown objects are cyan
-        mMapLegend[HeapSegmentElement.KIND_UNKNOWN + 2]
-                = "unknown object";
-
-        colors[HeapSegmentElement.KIND_NATIVE + 2]
-                = new RGB(64, 64, 64);    // native objects are dark gray
-        mMapLegend[HeapSegmentElement.KIND_NATIVE + 2]
-                = "non-Java object";
-
-        return new PaletteData(colors);
-    }
-    
-    private void saveAllocations(String fileName) {
-        try {
-            PrintWriter out = new PrintWriter(new BufferedWriter(new FileWriter(fileName)));
-    
-            for (NativeAllocationInfo alloc : mAllocations) {
-                out.println(alloc.toString());
-            }
-            out.close();
-        } catch (IOException e) {
-            Log.e("Native", e);
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Panel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Panel.java
deleted file mode 100644
index d910cc7..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/Panel.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-
-/**
- * Base class for our information panels.
- */
-public abstract class Panel {
-
-    public final Control createPanel(Composite parent) {
-        Control panelControl = createControl(parent);
-
-        postCreation();
-
-        return panelControl;
-    }
-
-    protected abstract void postCreation();
-
-    /**
-     * Creates a control capable of displaying some information.  This is
-     * called once, when the application is initializing, from the UI thread.
-     */
-    protected abstract Control createControl(Composite parent);
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    public abstract void setFocus();
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/PortFieldEditor.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/PortFieldEditor.java
deleted file mode 100644
index 533372e..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/PortFieldEditor.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.jface.preference.IntegerFieldEditor;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Edit an integer field, validating it as a port number.
- */
-public class PortFieldEditor extends IntegerFieldEditor {
-
-    public boolean mRecursiveCheck = false;
-
-    public PortFieldEditor(String name, String label, Composite parent) {
-        super(name, label, parent);
-        setValidateStrategy(VALIDATE_ON_KEY_STROKE);
-    }
-
-    /*
-     * Get the current value of the field, as an integer.
-     */
-    public int getCurrentValue() {
-        int val;
-        try {
-            val = Integer.parseInt(getStringValue());
-        }
-        catch (NumberFormatException nfe) {
-            val = -1;
-        }
-        return val;
-    }
-
-    /*
-     * Check the validity of the field.
-     */
-    @Override
-    protected boolean checkState() {
-        if (super.checkState() == false) {
-            return false;
-        }
-        //Log.i("ddms", "check state " + getStringValue());
-        boolean err = false;
-        int val = getCurrentValue();
-        if (val < 1024 || val > 32767) {
-            setErrorMessage("Port must be between 1024 and 32767");
-            err = true;
-        } else {
-            setErrorMessage(null);
-            err = false;
-        }
-        showErrorMessage();
-        return !err;
-    }
-
-    protected void updateCheckState(PortFieldEditor pfe) {
-        pfe.refreshValidState();
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ScreenShotDialog.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ScreenShotDialog.java
deleted file mode 100644
index dad54dc..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ScreenShotDialog.java
+++ /dev/null
@@ -1,256 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.RawImage;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.ImageLoader;
-import org.eclipse.swt.graphics.PaletteData;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.IOException;
-
-
-/**
- * Gather a screen shot from the device and save it to a file.
- */
-public class ScreenShotDialog extends Dialog {
-
-    private Label mBusyLabel;
-    private Label mImageLabel;
-    private Button mSave;
-    private Device mDevice;
-
-
-    /**
-     * Create with default style.
-     */
-    public ScreenShotDialog(Shell parent) {
-        this(parent, SWT.DIALOG_TRIM | SWT.APPLICATION_MODAL);
-    }
-
-    /**
-     * Create with app-defined style.
-     */
-    public ScreenShotDialog(Shell parent, int style) {
-        super(parent, style);
-    }
-
-    /**
-     * Prepare and display the dialog.
-     * @param device The {@link Device} from which to get the screenshot.
-     */
-    public void open(Device device) {
-        mDevice = device;
-
-        Shell parent = getParent();
-        Shell shell = new Shell(parent, getStyle());
-        shell.setText("Device Screen Capture");
-
-        createContents(shell);
-        shell.pack();
-        shell.open();
-
-        updateDeviceImage(shell);
-
-        Display display = parent.getDisplay();
-        while (!shell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-    }
-
-    /*
-     * Create the screen capture dialog contents.
-     */
-    private void createContents(final Shell shell) {
-        GridData data;
-
-        shell.setLayout(new GridLayout(3, true));
-
-        // title/"capturing" label
-        mBusyLabel = new Label(shell, SWT.NONE);
-        mBusyLabel.setText("Preparing...");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
-        data.horizontalSpan = 3;
-        mBusyLabel.setLayoutData(data);
-
-        // space for the image
-        mImageLabel = new Label(shell, SWT.BORDER);
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.horizontalSpan = 3;
-        mImageLabel.setLayoutData(data);
-        Display display = shell.getDisplay();
-        mImageLabel.setImage(ImageHelper.createPlaceHolderArt(display, 50, 50, display.getSystemColor(SWT.COLOR_BLUE)));
-
-        // "refresh" button
-        Button refresh = new Button(shell, SWT.PUSH);
-        refresh.setText("Refresh");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.widthHint = 80;
-        refresh.setLayoutData(data);
-        refresh.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateDeviceImage(shell);
-            }
-        });
-
-        // "save" button
-        mSave = new Button(shell, SWT.PUSH);
-        mSave.setText("Save");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.widthHint = 80;
-        mSave.setLayoutData(data);
-        mSave.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                saveImage(shell);
-            }
-        });
-
-        // "done" button
-        Button done = new Button(shell, SWT.PUSH);
-        done.setText("Done");
-        data = new GridData(GridData.HORIZONTAL_ALIGN_CENTER);
-        data.widthHint = 80;
-        done.setLayoutData(data);
-        done.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                shell.close();
-            }
-        });
-
-        shell.setDefaultButton(done);
-    }
-
-    /*
-     * Capture a new image from the device.
-     */
-    private void updateDeviceImage(Shell shell) {
-        mBusyLabel.setText("Capturing...");     // no effect
-
-        shell.setCursor(shell.getDisplay().getSystemCursor(SWT.CURSOR_WAIT));
-
-        Image image = getDeviceImage();
-        if (image == null) {
-            Display display = shell.getDisplay();
-            image = ImageHelper.createPlaceHolderArt(display, 320, 240, display.getSystemColor(SWT.COLOR_BLUE));
-            mSave.setEnabled(false);
-            mBusyLabel.setText("Screen not available");
-        } else {
-            mSave.setEnabled(true);
-            mBusyLabel.setText("Captured image:");
-        }
-
-        mImageLabel.setImage(image);
-        mImageLabel.pack();
-        shell.pack();
-
-        // there's no way to restore old cursor; assume it's ARROW
-        shell.setCursor(shell.getDisplay().getSystemCursor(SWT.CURSOR_ARROW));
-    }
-
-    /*
-     * Grab an image from an ADB-connected device.
-     */
-    private Image getDeviceImage() {
-        RawImage rawImage;
-
-        try {
-            rawImage = mDevice.getScreenshot();
-        }
-        catch (IOException ioe) {
-            Log.w("ddms", "Unable to get frame buffer: " + ioe.getMessage());
-            return null;
-        }
-
-        // device/adb not available?
-        if (rawImage == null)
-            return null;
-
-        // convert raw data to an Image
-        assert rawImage.bpp == 16;
-        PaletteData palette = new PaletteData(0xf800, 0x07e0, 0x001f);
-        ImageData imageData = new ImageData(rawImage.width, rawImage.height,
-            rawImage.bpp, palette, 1, rawImage.data);
-
-        return new Image(getParent().getDisplay(), imageData);
-    }
-
-    /*
-     * Prompt the user to save the image to disk.
-     */
-    private void saveImage(Shell shell) {
-        FileDialog dlg = new FileDialog(shell, SWT.SAVE);
-        String fileName;
-
-        dlg.setText("Save image...");
-        dlg.setFileName("device.png");
-        dlg.setFilterPath(DdmUiPreferences.getStore().getString("lastImageSaveDir"));
-        dlg.setFilterNames(new String[] {
-            "PNG Files (*.png)"
-        });
-        dlg.setFilterExtensions(new String[] {
-            "*.png" //$NON-NLS-1$
-        });
-
-        fileName = dlg.open();
-        if (fileName != null) {
-            DdmUiPreferences.getStore().setValue("lastImageSaveDir", dlg.getFilterPath());
-
-            Log.i("ddms", "Saving image to " + fileName);
-            ImageData imageData = mImageLabel.getImage().getImageData();
-
-            try {
-                WritePng.savePng(fileName, imageData);
-            }
-            catch (IOException ioe) {
-                Log.w("ddms", "Unable to save " + fileName + ": " + ioe);
-            }
-
-            if (false) {
-                ImageLoader loader = new ImageLoader();
-                loader.data = new ImageData[] { imageData };
-                // PNG writing not available until 3.3?  See bug at:
-                //  https://bugs.eclipse.org/bugs/show_bug.cgi?id=24697
-                // GIF writing only works for 8 bits
-                // JPEG uses lossy compression
-                // BMP has screwed-up colors
-                loader.save(fileName, SWT.IMAGE_JPEG);
-            }
-        }
-    }
-
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SelectionDependentPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SelectionDependentPanel.java
deleted file mode 100644
index 4b5fe56..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SelectionDependentPanel.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-
-/**
- * A Panel that requires {@link Device}/{@link Client} selection notifications.
- */
-public abstract class SelectionDependentPanel extends Panel {
-    private Device mCurrentDevice = null;
-    private Client mCurrentClient = null;
-
-    /**
-     * Returns the current {@link Device}.
-     * @return the current device or null if none are selected.
-     */
-    protected final Device getCurrentDevice() {
-        return mCurrentDevice;
-    }
-
-    /**
-     * Returns the current {@link Client}.
-     * @return the current client or null if none are selected.
-     */
-    protected final Client getCurrentClient() {
-        return mCurrentClient;
-    }
-
-    /**
-     * Sent when a new device is selected.
-     * @param selectedDevice the selected device.
-     */
-    public final void deviceSelected(Device selectedDevice) {
-        if (selectedDevice != mCurrentDevice) {
-            mCurrentDevice = selectedDevice;
-            deviceSelected();
-        }
-    }
-
-    /**
-     * Sent when a new client is selected.
-     * @param selectedClient the selected client.
-     */
-    public final void clientSelected(Client selectedClient) {
-        if (selectedClient != mCurrentClient) {
-            mCurrentClient = selectedClient;
-            clientSelected();
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}.
-     */
-    public abstract void deviceSelected();
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    public abstract void clientSelected();
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/StackTracePanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/StackTracePanel.java
deleted file mode 100644
index 3358962..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/StackTracePanel.java
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.IStackTraceInfo;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-
-/**
- * Stack Trace Panel.
- * <p/>This is not a panel in the regular sense. Instead this is just an object around the creation
- * and management of a Stack Trace display.
- * <p/>UI creation is done through
- * {@link #createPanel(Composite, String, String, String, String, String, IPreferenceStore)}.
- *
- */
-public final class StackTracePanel {
-
-    private static ISourceRevealer sSourceRevealer;
-
-    private Table mStackTraceTable;
-    private TableViewer mStackTraceViewer;
-
-    private Client mCurrentClient;
-    
-    
-    /**
-     * Content Provider to display the stack trace of a thread.
-     * Expected input is a {@link IStackTraceInfo} object.
-     */
-    private static class StackTraceContentProvider implements IStructuredContentProvider {
-        public Object[] getElements(Object inputElement) {
-            if (inputElement instanceof IStackTraceInfo) {
-                // getElement cannot return null, so we return an empty array
-                // if there's no stack trace
-                StackTraceElement trace[] = ((IStackTraceInfo)inputElement).getStackTrace();
-                if (trace != null) {
-                    return trace;
-                }
-            }
-
-            return new Object[0];
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            // pass
-        }
-    }
-    
-
-    /**
-     * A Label Provider to use with {@link StackTraceContentProvider}. It expects the elements to be
-     * of type {@link StackTraceElement}.
-     */
-    private static class StackTraceLabelProvider implements ITableLabelProvider {
-
-        public Image getColumnImage(Object element, int columnIndex) {
-            return null;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            if (element instanceof StackTraceElement) {
-                StackTraceElement traceElement = (StackTraceElement)element;
-                switch (columnIndex) {
-                    case 0:
-                        return traceElement.getClassName();
-                    case 1:
-                        return traceElement.getMethodName();
-                    case 2:
-                        return traceElement.getFileName();
-                    case 3:
-                        return Integer.toString(traceElement.getLineNumber());
-                    case 4:
-                        return Boolean.toString(traceElement.isNativeMethod());
-                }
-            }
-
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-    
-    /**
-     * Classes which implement this interface provide a method that is able to reveal a method
-     * in a source editor
-     */
-    public interface ISourceRevealer {
-        /**
-         * Sent to reveal a particular line in a source editor
-         * @param applicationName the name of the application running the source.
-         * @param className the fully qualified class name
-         * @param line the line to reveal
-         */
-        public void reveal(String applicationName, String className, int line);
-    }
-    
-    
-    /**
-     * Sets the {@link ISourceRevealer} object able to reveal source code in a source editor.
-     * @param revealer
-     */
-    public static void setSourceRevealer(ISourceRevealer revealer) {
-        sSourceRevealer = revealer;
-    }
-    
-    /**
-     * Creates the controls for the StrackTrace display.
-     * <p/>This method will set the parent {@link Composite} to use a {@link GridLayout} with
-     * 2 columns.
-     * @param parent the parent composite.
-     * @param prefs_stack_col_class 
-     * @param prefs_stack_col_method 
-     * @param prefs_stack_col_file 
-     * @param prefs_stack_col_line 
-     * @param prefs_stack_col_native 
-     * @param store
-     */
-    public Table createPanel(Composite parent, String prefs_stack_col_class,
-            String prefs_stack_col_method, String prefs_stack_col_file, String prefs_stack_col_line,
-            String prefs_stack_col_native, IPreferenceStore store) {
-        
-        mStackTraceTable = new Table(parent, SWT.MULTI | SWT.FULL_SELECTION);
-        mStackTraceTable.setHeaderVisible(true);
-        mStackTraceTable.setLinesVisible(true);
-        
-        TableHelper.createTableColumn(
-                mStackTraceTable,
-                "Class",
-                SWT.LEFT,
-                "SomeLongClassName", //$NON-NLS-1$
-                prefs_stack_col_class, store);
-
-        TableHelper.createTableColumn(
-                mStackTraceTable,
-                "Method",
-                SWT.LEFT,
-                "someLongMethod", //$NON-NLS-1$
-                prefs_stack_col_method, store);
-
-        TableHelper.createTableColumn(
-                mStackTraceTable,
-                "File",
-                SWT.LEFT,
-                "android/somepackage/someotherpackage/somefile.class", //$NON-NLS-1$
-                prefs_stack_col_file, store);
-
-        TableHelper.createTableColumn(
-                mStackTraceTable,
-                "Line",
-                SWT.RIGHT,
-                "99999", //$NON-NLS-1$
-                prefs_stack_col_line, store);
-
-        TableHelper.createTableColumn(
-                mStackTraceTable,
-                "Native",
-                SWT.LEFT,
-                "Native", //$NON-NLS-1$
-                prefs_stack_col_native, store);
-        
-        mStackTraceViewer = new TableViewer(mStackTraceTable);
-        mStackTraceViewer.setContentProvider(new StackTraceContentProvider());
-        mStackTraceViewer.setLabelProvider(new StackTraceLabelProvider());
-        
-        mStackTraceViewer.addDoubleClickListener(new IDoubleClickListener() {
-            public void doubleClick(DoubleClickEvent event) {
-                if (sSourceRevealer != null && mCurrentClient != null) {
-                    // get the selected stack trace element
-                    ISelection selection = mStackTraceViewer.getSelection();
-                    
-                    if (selection instanceof IStructuredSelection) {
-                        IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                        Object object = structuredSelection.getFirstElement();
-                        if (object instanceof StackTraceElement) {
-                            StackTraceElement traceElement = (StackTraceElement)object;
-                            
-                            if (traceElement.isNativeMethod() == false) {
-                                sSourceRevealer.reveal(
-                                        mCurrentClient.getClientData().getClientDescription(), 
-                                        traceElement.getClassName(),
-                                        traceElement.getLineNumber());
-                            }
-                        }
-                    }
-                }
-            }
-        });
-
-        return mStackTraceTable;
-    }
-    
-    /**
-     * Sets the input for the {@link TableViewer}.
-     * @param input the {@link IStackTraceInfo} that will provide the viewer with the list of
-     * {@link StackTraceElement}
-     */
-    public void setViewerInput(IStackTraceInfo input) {
-        mStackTraceViewer.setInput(input);
-        mStackTraceViewer.refresh();
-    }
-    
-    /**
-     * Sets the current client running the stack trace.
-     * @param currentClient the {@link Client}.
-     */
-    public void setCurrentClient(Client currentClient) {
-        mCurrentClient = currentClient;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SysinfoPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SysinfoPanel.java
deleted file mode 100644
index 8ef237c..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/SysinfoPanel.java
+++ /dev/null
@@ -1,582 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.IShellOutputReceiver;
-import com.android.ddmlib.Log;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.jfree.chart.ChartFactory;
-import org.jfree.chart.JFreeChart;
-import org.jfree.data.general.DefaultPieDataset;
-import org.jfree.experimental.chart.swt.ChartComposite;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Displays system information graphs obtained from a bugreport file or device.
- */
-public class SysinfoPanel extends TablePanel implements IShellOutputReceiver {
-
-    // UI components
-    private Label mLabel;
-    private Button mFetchButton;
-    private Combo mDisplayMode;
-
-    private DefaultPieDataset mDataset;
-
-    // The bugreport file to process
-    private File mDataFile;
-
-    // To get output from adb commands
-    private FileOutputStream mTempStream;
-
-    // Selects the current display: MODE_CPU, etc.
-    private int mMode = 0;
-
-    private static final int MODE_CPU = 0;
-    private static final int MODE_ALARM = 1;
-    private static final int MODE_WAKELOCK = 2;
-    private static final int MODE_MEMINFO = 3;
-    private static final int MODE_SYNC = 4;
-
-    // argument to dumpsys; section in the bugreport holding the data
-    private static final String BUGREPORT_SECTION[] = {"cpuinfo", "alarm",
-            "batteryinfo", "MEMORY INFO", "content"};
-
-    private static final String DUMP_COMMAND[] = {"dumpsys cpuinfo",
-            "dumpsys alarm", "dumpsys batteryinfo", "cat /proc/meminfo ; procrank",
-            "dumpsys content"};
-
-    private static final String CAPTIONS[] = {"CPU load", "Alarms",
-            "Wakelocks", "Memory usage", "Sync"};
-
-    /**
-     * Generates the dataset to display.
-     *
-     * @param file The bugreport file to process.
-     */
-    public void generateDataset(File file) {
-        mDataset.clear();
-        mLabel.setText("");
-        if (file == null) {
-            return;
-        }
-        try {
-            BufferedReader br = getBugreportReader(file);
-            if (mMode == MODE_CPU) {
-                readCpuDataset(br);
-            } else if (mMode == MODE_ALARM) {
-                readAlarmDataset(br);
-            } else if (mMode == MODE_WAKELOCK) {
-                readWakelockDataset(br);
-            } else if (mMode == MODE_MEMINFO) {
-                readMeminfoDataset(br);
-            } else if (mMode == MODE_SYNC) {
-                readSyncDataset(br);
-            }
-        } catch (IOException e) {
-            Log.e("DDMS", e);
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed with
-     * {@link #getCurrentDevice()}
-     */
-    @Override
-    public void deviceSelected() {
-        if (getCurrentDevice() != null) {
-            mFetchButton.setEnabled(true);
-            loadFromDevice();
-        } else {
-            mFetchButton.setEnabled(false);
-        }
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed with
-     * {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-    }
-
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mDisplayMode.setFocus();
-    }
-
-    /**
-     * Fetches a new bugreport from the device and updates the display.
-     * Fetching is asynchronous.  See also addOutput, flush, and isCancelled.
-     */
-    private void loadFromDevice() {
-        try {
-            initShellOutputBuffer();
-            if (mMode == MODE_MEMINFO) {
-                // Hack to add bugreport-style section header for meminfo
-                mTempStream.write("------ MEMORY INFO ------\n".getBytes());
-            }
-            getCurrentDevice().executeShellCommand(
-                    DUMP_COMMAND[mMode], this);
-        } catch (IOException e) {
-            Log.e("DDMS", e);
-        }
-    }
-
-    /**
-     * Initializes temporary output file for executeShellCommand().
-     *
-     * @throws IOException on file error
-     */
-    void initShellOutputBuffer() throws IOException {
-        mDataFile = File.createTempFile("ddmsfile", ".txt");
-        mDataFile.deleteOnExit();
-        mTempStream = new FileOutputStream(mDataFile);
-    }
-
-    /**
-     * Adds output to the temp file. IShellOutputReceiver method. Called by
-     * executeShellCommand().
-     */
-    public void addOutput(byte[] data, int offset, int length) {
-        try {
-            mTempStream.write(data, offset, length);
-        }
-        catch (IOException e) {
-            Log.e("DDMS", e);
-        }
-    }
-
-    /**
-     * Processes output from shell command. IShellOutputReceiver method. The
-     * output is passed to generateDataset(). Called by executeShellCommand() on
-     * completion.
-     */
-    public void flush() {
-        if (mTempStream != null) {
-            try {
-                mTempStream.close();
-                generateDataset(mDataFile);
-                mTempStream = null;
-                mDataFile = null;
-            } catch (IOException e) {
-                Log.e("DDMS", e);
-            }
-        }
-    }
-
-    /**
-     * IShellOutputReceiver method.
-     *
-     * @return false - don't cancel
-     */
-    public boolean isCancelled() {
-        return false;
-    }
-
-    /**
-     * Create our controls for the UI panel.
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayout(new GridLayout(1, false));
-        top.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Composite buttons = new Composite(top, SWT.NONE);
-        buttons.setLayout(new RowLayout());
-
-        mDisplayMode = new Combo(buttons, SWT.PUSH);
-        for (String mode : CAPTIONS) {
-            mDisplayMode.add(mode);
-        }
-        mDisplayMode.select(mMode);
-        mDisplayMode.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mMode = mDisplayMode.getSelectionIndex();
-                if (mDataFile != null) {
-                    generateDataset(mDataFile);
-                } else if (getCurrentDevice() != null) {
-                    loadFromDevice();
-                }
-            }
-        });
-
-        final Button loadButton = new Button(buttons, SWT.PUSH);
-        loadButton.setText("Load from File");
-        loadButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                FileDialog fileDialog = new FileDialog(loadButton.getShell(),
-                        SWT.OPEN);
-                fileDialog.setText("Load bugreport");
-                String filename = fileDialog.open();
-                if (filename != null) {
-                    mDataFile = new File(filename);
-                    generateDataset(mDataFile);
-                }
-            }
-        });
-
-        mFetchButton = new Button(buttons, SWT.PUSH);
-        mFetchButton.setText("Update from Device");
-        mFetchButton.setEnabled(false);
-        mFetchButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                loadFromDevice();
-            }
-        });
-
-        mLabel = new Label(top, SWT.NONE);
-        mLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mDataset = new DefaultPieDataset();
-        JFreeChart chart = ChartFactory.createPieChart("", mDataset, false
-                /* legend */, true/* tooltips */, false /* urls */);
-
-        ChartComposite chartComposite = new ChartComposite(top,
-                SWT.BORDER, chart,
-                ChartComposite.DEFAULT_HEIGHT,
-                ChartComposite.DEFAULT_HEIGHT,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_WIDTH,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_HEIGHT,
-                3000,
-                // max draw width. We don't want it to zoom, so we put a big number
-                3000,
-                // max draw height. We don't want it to zoom, so we put a big number
-                true,  // off-screen buffer
-                true,  // properties
-                true,  // save
-                true,  // print
-                false,  // zoom
-                true);
-        chartComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        return top;
-    }
-
-    public void clientChanged(final Client client, int changeMask) {
-        // Don't care
-    }
-
-    /**
-     * Helper to open a bugreport and skip to the specified section.
-     *
-     * @param file File to open
-     * @return Reader to bugreport file
-     * @throws java.io.IOException on file error
-     */
-    private BufferedReader getBugreportReader(File file) throws
-            IOException {
-        BufferedReader br = new BufferedReader(new FileReader(file));
-        // Skip over the unwanted bugreport sections
-        while (true) {
-            String line = br.readLine();
-            if (line == null) {
-                Log.d("DDMS", "Service not found " + line);
-                break;
-            }
-            if ((line.startsWith("DUMP OF SERVICE ") || line.startsWith("-----")) &&
-                    line.indexOf(BUGREPORT_SECTION[mMode]) > 0) {
-                break;
-            }
-        }
-        return br;
-    }
-
-    /**
-     * Parse the time string generated by BatteryStats.
-     * A typical new-format string is "11d 13h 45m 39s 999ms".
-     * A typical old-format string is "12.3 sec".
-     * @return time in ms
-     */
-    private static long parseTimeMs(String s) {
-        long total = 0;
-        // Matches a single component e.g. "12.3 sec" or "45ms"
-        Pattern p = Pattern.compile("([\\d\\.]+)\\s*([a-z]+)");
-        Matcher m = p.matcher(s);
-        while (m.find()) {
-            String label = m.group(2);
-            if ("sec".equals(label)) {
-                // Backwards compatibility with old time format
-                total += (long) (Double.parseDouble(m.group(1)) * 1000);
-                continue;
-            }
-            long value = Integer.parseInt(m.group(1));
-            if ("d".equals(label)) {
-                total += value * 24 * 60 * 60 * 1000;
-            } else if ("h".equals(label)) {
-                total += value * 60 * 60 * 1000;
-            } else if ("m".equals(label)) {
-                total += value * 60 * 1000;
-            } else if ("s".equals(label)) {
-                total += value * 1000;
-            } else if ("ms".equals(label)) {
-                total += value;
-            }
-        }
-        return total;
-    }
-    /**
-     * Processes wakelock information from bugreport. Updates mDataset with the
-     * new data.
-     *
-     * @param br Reader providing the content
-     * @throws IOException if error reading file
-     */
-    void readWakelockDataset(BufferedReader br) throws IOException {
-        Pattern lockPattern = Pattern.compile("Wake lock (\\S+): (.+) partial");
-        Pattern totalPattern = Pattern.compile("Total: (.+) uptime");
-        double total = 0;
-        boolean inCurrent = false;
-
-        while (true) {
-            String line = br.readLine();
-            if (line == null || line.startsWith("DUMP OF SERVICE")) {
-                // Done, or moved on to the next service
-                break;
-            }
-            if (line.startsWith("Current Battery Usage Statistics")) {
-                inCurrent = true;
-            } else if (inCurrent) {
-                Matcher m = lockPattern.matcher(line);
-                if (m.find()) {
-                    double value = parseTimeMs(m.group(2)) / 1000.;
-                    mDataset.setValue(m.group(1), value);
-                    total -= value;
-                } else {
-                    m = totalPattern.matcher(line);
-                    if (m.find()) {
-                        total += parseTimeMs(m.group(1)) / 1000.;
-                    }
-                }
-            }
-        }
-        if (total > 0) {
-            mDataset.setValue("Unlocked", total);
-        }
-    }
-
-    /**
-     * Processes alarm information from bugreport. Updates mDataset with the new
-     * data.
-     *
-     * @param br Reader providing the content
-     * @throws IOException if error reading file
-     */
-    void readAlarmDataset(BufferedReader br) throws IOException {
-        Pattern pattern = Pattern
-                .compile("(\\d+) alarms: Intent .*\\.([^. ]+) flags");
-
-        while (true) {
-            String line = br.readLine();
-            if (line == null || line.startsWith("DUMP OF SERVICE")) {
-                // Done, or moved on to the next service
-                break;
-            }
-            Matcher m = pattern.matcher(line);
-            if (m.find()) {
-                long count = Long.parseLong(m.group(1));
-                String name = m.group(2);
-                mDataset.setValue(name, count);
-            }
-        }
-    }
-
-    /**
-     * Processes cpu load information from bugreport. Updates mDataset with the
-     * new data.
-     *
-     * @param br Reader providing the content
-     * @throws IOException if error reading file
-     */
-    void readCpuDataset(BufferedReader br) throws IOException {
-        Pattern pattern = Pattern
-                .compile("(\\S+): (\\S+)% = (.+)% user . (.+)% kernel");
-
-        while (true) {
-            String line = br.readLine();
-            if (line == null || line.startsWith("DUMP OF SERVICE")) {
-                // Done, or moved on to the next service
-                break;
-            }
-            if (line.startsWith("Load:")) {
-                mLabel.setText(line);
-                continue;
-            }
-            Matcher m = pattern.matcher(line);
-            if (m.find()) {
-                String name = m.group(1);
-                long both = Long.parseLong(m.group(2));
-                long user = Long.parseLong(m.group(3));
-                long kernel = Long.parseLong(m.group(4));
-                if ("TOTAL".equals(name)) {
-                    if (both < 100) {
-                        mDataset.setValue("Idle", (100 - both));
-                    }
-                } else {
-                    // Try to make graphs more useful even with rounding;
-                    // log often has 0% user + 0% kernel = 1% total
-                    // We arbitrarily give extra to kernel
-                    if (user > 0) {
-                        mDataset.setValue(name + " (user)", user);
-                    }
-                    if (kernel > 0) {
-                        mDataset.setValue(name + " (kernel)" , both - user);
-                    }
-                    if (user == 0 && kernel == 0 && both > 0) {
-                        mDataset.setValue(name, both);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Processes meminfo information from bugreport. Updates mDataset with the
-     * new data.
-     *
-     * @param br Reader providing the content
-     * @throws IOException if error reading file
-     */
-    void readMeminfoDataset(BufferedReader br) throws IOException {
-        Pattern valuePattern = Pattern.compile("(\\d+) kB");
-        long total = 0;
-        long other = 0;
-        mLabel.setText("PSS in kB");        
-
-        // Scan meminfo
-        while (true) {
-            String line = br.readLine();
-            if (line == null) {
-                // End of file
-                break;
-            }
-            Matcher m = valuePattern.matcher(line);
-            if (m.find()) {
-                long kb = Long.parseLong(m.group(1));
-                if (line.startsWith("MemTotal")) {
-                    total = kb;
-                } else if (line.startsWith("MemFree")) {
-                    mDataset.setValue("Free", kb);
-                    total -= kb;
-                } else if (line.startsWith("Slab")) {
-                    mDataset.setValue("Slab", kb);
-                    total -= kb;
-                } else if (line.startsWith("PageTables")) {
-                    mDataset.setValue("PageTables", kb);
-                    total -= kb;
-                } else if (line.startsWith("Buffers") && kb > 0) {
-                    mDataset.setValue("Buffers", kb);
-                    total -= kb;
-                } else if (line.startsWith("Inactive")) {
-                    mDataset.setValue("Inactive", kb);
-                    total -= kb;
-                } else if (line.startsWith("MemFree")) {
-                    mDataset.setValue("Free", kb);
-                    total -= kb;
-                }
-            } else {
-                break;
-            }
-        }
-        // Scan procrank
-        while (true) {
-            String line = br.readLine();
-            if (line == null) {
-                break;
-            }
-            if (line.indexOf("PROCRANK") >= 0 || line.indexOf("PID") >= 0) {
-                // procrank header
-                continue;
-            }
-            if  (line.indexOf("----") >= 0) {
-                //end of procrank section
-                break;
-            }
-            // Extract pss field from procrank output
-            long pss = Long.parseLong(line.substring(23, 31).trim());
-            String cmdline = line.substring(43).trim().replace("/system/bin/", "");
-            // Arbitrary minimum size to display
-            if (pss > 2000) {
-                mDataset.setValue(cmdline, pss);
-            } else {
-                other += pss;
-            }
-            total -= pss;
-        }
-        mDataset.setValue("Other", other);
-        mDataset.setValue("Unknown", total);
-    }
-
-    /**
-     * Processes sync information from bugreport. Updates mDataset with the new
-     * data.
-     *
-     * @param br Reader providing the content
-     * @throws IOException if error reading file
-     */
-    void readSyncDataset(BufferedReader br) throws IOException {
-        while (true) {
-            String line = br.readLine();
-            if (line == null || line.startsWith("DUMP OF SERVICE")) {
-                // Done, or moved on to the next service
-                break;
-            }
-            if (line.startsWith(" |") && line.length() > 70) {
-                String authority = line.substring(3, 18).trim();
-                String duration = line.substring(61, 70).trim();
-                // Duration is MM:SS or HH:MM:SS (DateUtils.formatElapsedTime)
-                String durParts[] = duration.split(":");
-                if (durParts.length == 2) {
-                    long dur = Long.parseLong(durParts[0]) * 60 + Long
-                            .parseLong(durParts[1]);
-                    mDataset.setValue(authority, dur);
-                } else if (duration.length() == 3) {
-                    long dur = Long.parseLong(durParts[0]) * 3600
-                            + Long.parseLong(durParts[1]) * 60 + Long
-                            .parseLong(durParts[2]);
-                    mDataset.setValue(authority, dur);
-                }
-            }
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TableHelper.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TableHelper.java
deleted file mode 100644
index f8d457e..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TableHelper.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeColumn;
-
-/**
- * Utility class to help using Table objects.
- *
- */
-public final class TableHelper {
-    /**
-     * Create a TableColumn with the specified parameters. If a
-     * <code>PreferenceStore</code> object and a preference entry name String
-     * object are provided then the column will listen to change in its width
-     * and update the preference store accordingly.
-     *
-     * @param parent The Table parent object
-     * @param header The header string
-     * @param style The column style
-     * @param sample_text A sample text to figure out column width if preference
-     *            value is missing
-     * @param pref_name The preference entry name for column width
-     * @param prefs The preference store
-     * @return The TableColumn object that was created
-     */
-    public static TableColumn createTableColumn(Table parent, String header,
-            int style, String sample_text, final String pref_name,
-            final IPreferenceStore prefs) {
-
-        // create the column
-        TableColumn col = new TableColumn(parent, style);
-
-        // if there is no pref store or the entry is missing, we use the sample
-        // text and pack the column.
-        // Otherwise we just read the width from the prefs and apply it.
-        if (prefs == null || prefs.contains(pref_name) == false) {
-            col.setText(sample_text);
-            col.pack();
-
-            // init the prefs store with the current value
-            if (prefs != null) {
-                prefs.setValue(pref_name, col.getWidth());
-            }
-        } else {
-            col.setWidth(prefs.getInt(pref_name));
-        }
-
-        // set the header
-        col.setText(header);
-
-        // if there is a pref store and a pref entry name, then we setup a
-        // listener to catch column resize to put store the new width value.
-        if (prefs != null && pref_name != null) {
-            col.addControlListener(new ControlListener() {
-                public void controlMoved(ControlEvent e) {
-                }
-
-                public void controlResized(ControlEvent e) {
-                    // get the new width
-                    int w = ((TableColumn)e.widget).getWidth();
-
-                    // store in pref store
-                    prefs.setValue(pref_name, w);
-                }
-            });
-        }
-
-        return col;
-    }
-
-    /**
-     * Create a TreeColumn with the specified parameters. If a
-     * <code>PreferenceStore</code> object and a preference entry name String
-     * object are provided then the column will listen to change in its width
-     * and update the preference store accordingly.
-     *
-     * @param parent The Table parent object
-     * @param header The header string
-     * @param style The column style
-     * @param sample_text A sample text to figure out column width if preference
-     *            value is missing
-     * @param pref_name The preference entry name for column width
-     * @param prefs The preference store
-     */
-    public static void createTreeColumn(Tree parent, String header, int style,
-            String sample_text, final String pref_name,
-            final IPreferenceStore prefs) {
-
-        // create the column
-        TreeColumn col = new TreeColumn(parent, style);
-
-        // if there is no pref store or the entry is missing, we use the sample
-        // text and pack the column.
-        // Otherwise we just read the width from the prefs and apply it.
-        if (prefs == null || prefs.contains(pref_name) == false) {
-            col.setText(sample_text);
-            col.pack();
-
-            // init the prefs store with the current value
-            if (prefs != null) {
-                prefs.setValue(pref_name, col.getWidth());
-            }
-        } else {
-            col.setWidth(prefs.getInt(pref_name));
-        }
-
-        // set the header
-        col.setText(header);
-
-        // if there is a pref store and a pref entry name, then we setup a
-        // listener to catch column resize to put store the new width value.
-        if (prefs != null && pref_name != null) {
-            col.addControlListener(new ControlListener() {
-                public void controlMoved(ControlEvent e) {
-                }
-
-                public void controlResized(ControlEvent e) {
-                    // get the new width
-                    int w = ((TreeColumn)e.widget).getWidth();
-
-                    // store in pref store
-                    prefs.setValue(pref_name, w);
-                }
-            });
-        }
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TablePanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TablePanel.java
deleted file mode 100644
index b037193..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/TablePanel.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmuilib.ITableFocusListener.IFocusedTableActivator;
-
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.dnd.TextTransfer;
-import org.eclipse.swt.dnd.Transfer;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.FocusListener;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.Arrays;
-
-/**
- * Base class for panel containing Table that need to support copy-paste-selectAll
- */
-public abstract class TablePanel extends ClientDisplayPanel {
-    private ITableFocusListener mGlobalListener;
-
-    /**
-     * Sets a TableFocusListener which will be notified when one of the tables
-     * gets or loses focus.
-     *
-     * @param listener
-     */
-    public final void setTableFocusListener(ITableFocusListener listener) {
-        // record the global listener, to make sure table created after
-        // this call will still be setup.
-        mGlobalListener = listener;
-
-        setTableFocusListener();
-    }
-
-    /**
-     * Sets up the Table of object of the panel to work with the global listener.<br>
-     * Default implementation does nothing.
-     */
-    protected void setTableFocusListener() {
-
-    }
-
-    /**
-     * Sets up a Table object to notify the global Table Focus listener when it
-     * gets or loses the focus.
-     *
-     * @param table the Table object.
-     * @param colStart
-     * @param colEnd
-     */
-    protected final void addTableToFocusListener(final Table table,
-            final int colStart, final int colEnd) {
-        // create the activator for this table
-        final IFocusedTableActivator activator = new IFocusedTableActivator() {
-            public void copy(Clipboard clipboard) {
-                int[] selection = table.getSelectionIndices();
-
-                // we need to sort the items to be sure.
-                Arrays.sort(selection);
-
-                // all lines must be concatenated.
-                StringBuilder sb = new StringBuilder();
-
-                // loop on the selection and output the file.
-                for (int i : selection) {
-                    TableItem item = table.getItem(i);
-                    for (int c = colStart ; c <= colEnd ; c++) {
-                        sb.append(item.getText(c));
-                        sb.append('\t');
-                    }
-                    sb.append('\n');
-                }
-
-                // now add that to the clipboard if the string has content
-                String data = sb.toString();
-                if (data != null || data.length() > 0) {
-                    clipboard.setContents(
-                            new Object[] { data },
-                            new Transfer[] { TextTransfer.getInstance() });
-                }
-            }
-
-            public void selectAll() {
-                table.selectAll();
-            }
-        };
-
-        // add the focus listener on the table to notify the global listener
-        table.addFocusListener(new FocusListener() {
-            public void focusGained(FocusEvent e) {
-                mGlobalListener.focusGained(activator);
-            }
-
-            public void focusLost(FocusEvent e) {
-                mGlobalListener.focusLost(activator);
-            }
-        });
-    }
-
-    /**
-     * Sets up a Table object to notify the global Table Focus listener when it
-     * gets or loses the focus.<br>
-     * When the copy method is invoked, all columns are put in the clipboard, separated
-     * by tabs
-     *
-     * @param table the Table object.
-     */
-    protected final void addTableToFocusListener(final Table table) {
-        addTableToFocusListener(table, 0, table.getColumnCount()-1);
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ThreadPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ThreadPanel.java
deleted file mode 100644
index a034063..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/ThreadPanel.java
+++ /dev/null
@@ -1,572 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ThreadInfo;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.layout.FormLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Sash;
-import org.eclipse.swt.widgets.Table;
-
-import java.util.Date;
-
-/**
- * Base class for our information panels.
- */
-public class ThreadPanel extends TablePanel {
-    
-    private final static String PREFS_THREAD_COL_ID = "threadPanel.Col0"; //$NON-NLS-1$
-    private final static String PREFS_THREAD_COL_TID = "threadPanel.Col1"; //$NON-NLS-1$
-    private final static String PREFS_THREAD_COL_STATUS = "threadPanel.Col2"; //$NON-NLS-1$
-    private final static String PREFS_THREAD_COL_UTIME = "threadPanel.Col3"; //$NON-NLS-1$
-    private final static String PREFS_THREAD_COL_STIME = "threadPanel.Col4"; //$NON-NLS-1$
-    private final static String PREFS_THREAD_COL_NAME = "threadPanel.Col5"; //$NON-NLS-1$
-    
-    private final static String PREFS_THREAD_SASH = "threadPanel.sash"; //$NON-NLS-1$
-
-    private static final String PREFS_STACK_COL_CLASS = "threadPanel.stack.col0"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_METHOD = "threadPanel.stack.col1"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_FILE = "threadPanel.stack.col2"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_LINE = "threadPanel.stack.col3"; //$NON-NLS-1$
-    private static final String PREFS_STACK_COL_NATIVE = "threadPanel.stack.col4"; //$NON-NLS-1$
-    
-    private Display mDisplay;
-    private Composite mBase;
-    private Label mNotEnabled;
-    private Label mNotSelected;
-    
-    private Composite mThreadBase;
-    private Table mThreadTable;
-    private TableViewer mThreadViewer;
-
-    private Composite mStackTraceBase;
-    private Button mRefreshStackTraceButton;
-    private Label mStackTraceTimeLabel;
-    private StackTracePanel mStackTracePanel;
-    private Table mStackTraceTable;
-
-    /** Indicates if a timer-based Runnable is current requesting thread updates regularly. */
-    private boolean mMustStopRecurringThreadUpdate = false;
-    /** Flag to tell the recurring thread update to stop running */
-    private boolean mRecurringThreadUpdateRunning = false;
-
-    private Object mLock = new Object();
-
-    private static final String[] THREAD_STATUS = {
-        "zombie", "running", "timed-wait", "monitor",
-        "wait", "init", "start", "native", "vmwait"
-    };
-    
-    /**
-     * Content Provider to display the threads of a client.
-     * Expected input is a {@link Client} object.
-     */
-    private static class ThreadContentProvider implements IStructuredContentProvider {
-        public Object[] getElements(Object inputElement) {
-            if (inputElement instanceof Client) {
-                return ((Client)inputElement).getClientData().getThreads();
-            }
-
-            return new Object[0];
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            // pass
-        }
-    }
-    
-
-    /**
-     * A Label Provider to use with {@link ThreadContentProvider}. It expects the elements to be
-     * of type {@link ThreadInfo}.
-     */
-    private static class ThreadLabelProvider implements ITableLabelProvider {
-
-        public Image getColumnImage(Object element, int columnIndex) {
-            return null;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            if (element instanceof ThreadInfo) {
-                ThreadInfo thread = (ThreadInfo)element;
-                switch (columnIndex) {
-                    case 0:
-                        return (thread.isDaemon() ? "*" : "") + //$NON-NLS-1$ //$NON-NLS-2$
-                            String.valueOf(thread.getThreadId());
-                    case 1:
-                        return String.valueOf(thread.getTid());
-                    case 2:
-                        if (thread.getStatus() >= 0 && thread.getStatus() < THREAD_STATUS.length)
-                            return THREAD_STATUS[thread.getStatus()];
-                        return "unknown";
-                    case 3:
-                        return String.valueOf(thread.getUtime());
-                    case 4:
-                        return String.valueOf(thread.getStime());
-                    case 5:
-                        return thread.getThreadName();
-                }
-            }
-
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-
-    /**
-     * Create our control(s).
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mDisplay = parent.getDisplay();
-
-        final IPreferenceStore store = DdmUiPreferences.getStore();
-
-        mBase = new Composite(parent, SWT.NONE);
-        mBase.setLayout(new StackLayout());
-
-        // UI for thread not enabled
-        mNotEnabled = new Label(mBase, SWT.CENTER | SWT.WRAP);
-        mNotEnabled.setText("Thread updates not enabled for selected client\n"
-            + "(use toolbar button to enable)");
-
-        // UI for not client selected
-        mNotSelected = new Label(mBase, SWT.CENTER | SWT.WRAP);
-        mNotSelected.setText("no client is selected");
-
-        // base composite for selected client with enabled thread update.
-        mThreadBase = new Composite(mBase, SWT.NONE);
-        mThreadBase.setLayout(new FormLayout());
-        
-        // table above the sash
-        mThreadTable = new Table(mThreadBase, SWT.MULTI | SWT.FULL_SELECTION);
-        mThreadTable.setHeaderVisible(true);
-        mThreadTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "ID",
-                SWT.RIGHT,
-                "888", //$NON-NLS-1$
-                PREFS_THREAD_COL_ID, store);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "Tid",
-                SWT.RIGHT,
-                "88888", //$NON-NLS-1$
-                PREFS_THREAD_COL_TID, store);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "Status",
-                SWT.LEFT,
-                "timed-wait", //$NON-NLS-1$
-                PREFS_THREAD_COL_STATUS, store);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "utime",
-                SWT.RIGHT,
-                "utime", //$NON-NLS-1$
-                PREFS_THREAD_COL_UTIME, store);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "stime",
-                SWT.RIGHT,
-                "utime", //$NON-NLS-1$
-                PREFS_THREAD_COL_STIME, store);
-
-        TableHelper.createTableColumn(
-                mThreadTable,
-                "Name",
-                SWT.LEFT,
-                "android.class.ReallyLongClassName.MethodName", //$NON-NLS-1$
-                PREFS_THREAD_COL_NAME, store);
-        
-        mThreadViewer = new TableViewer(mThreadTable);
-        mThreadViewer.setContentProvider(new ThreadContentProvider());
-        mThreadViewer.setLabelProvider(new ThreadLabelProvider());
-
-        mThreadViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ThreadInfo selectedThread = getThreadSelection(event.getSelection());
-                updateThreadStackTrace(selectedThread);
-            }
-        });
-        mThreadViewer.addDoubleClickListener(new IDoubleClickListener() {
-            public void doubleClick(DoubleClickEvent event) {
-                ThreadInfo selectedThread = getThreadSelection(event.getSelection());
-                if (selectedThread != null) {
-                    Client client = (Client)mThreadViewer.getInput();
-                    
-                    if (client != null) {
-                        client.requestThreadStackTrace(selectedThread.getThreadId());
-                    }
-                }
-            }
-        });
-        
-        // the separating sash
-        final Sash sash = new Sash(mThreadBase, SWT.HORIZONTAL);
-        Color darkGray = parent.getDisplay().getSystemColor(SWT.COLOR_DARK_GRAY);
-        sash.setBackground(darkGray);
-        
-        // the UI below the sash
-        mStackTraceBase = new Composite(mThreadBase, SWT.NONE);
-        mStackTraceBase.setLayout(new GridLayout(2, false));
-
-        mRefreshStackTraceButton = new Button(mStackTraceBase, SWT.PUSH);
-        mRefreshStackTraceButton.setText("Refresh");
-        mRefreshStackTraceButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                ThreadInfo selectedThread = getThreadSelection(null);
-                if (selectedThread != null) {
-                    Client currentClient = getCurrentClient();
-                    if (currentClient != null) {
-                        currentClient.requestThreadStackTrace(selectedThread.getThreadId());
-                    }
-                }
-            }
-        });
-        
-        mStackTraceTimeLabel = new Label(mStackTraceBase, SWT.NONE);
-        mStackTraceTimeLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mStackTracePanel = new StackTracePanel();
-        mStackTraceTable = mStackTracePanel.createPanel(mStackTraceBase,
-                PREFS_STACK_COL_CLASS,
-                PREFS_STACK_COL_METHOD,
-                PREFS_STACK_COL_FILE,
-                PREFS_STACK_COL_LINE,
-                PREFS_STACK_COL_NATIVE,
-                store);
-        
-        GridData gd;
-        mStackTraceTable.setLayoutData(gd = new GridData(GridData.FILL_BOTH));
-        gd.horizontalSpan = 2;
-        
-        // now setup the sash.
-        // form layout data
-        FormData data = new FormData();
-        data.top = new FormAttachment(0, 0);
-        data.bottom = new FormAttachment(sash, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        mThreadTable.setLayoutData(data);
-
-        final FormData sashData = new FormData();
-        if (store != null && store.contains(PREFS_THREAD_SASH)) {
-            sashData.top = new FormAttachment(0, store.getInt(PREFS_THREAD_SASH));
-        } else {
-            sashData.top = new FormAttachment(50,0); // 50% across
-        }
-        sashData.left = new FormAttachment(0, 0);
-        sashData.right = new FormAttachment(100, 0);
-        sash.setLayoutData(sashData);
-
-        data = new FormData();
-        data.top = new FormAttachment(sash, 0);
-        data.bottom = new FormAttachment(100, 0);
-        data.left = new FormAttachment(0, 0);
-        data.right = new FormAttachment(100, 0);
-        mStackTraceBase.setLayoutData(data);
-
-        // allow resizes, but cap at minPanelWidth
-        sash.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event e) {
-                Rectangle sashRect = sash.getBounds();
-                Rectangle panelRect = mThreadBase.getClientArea();
-                int bottom = panelRect.height - sashRect.height - 100;
-                e.y = Math.max(Math.min(e.y, bottom), 100);
-                if (e.y != sashRect.y) {
-                    sashData.top = new FormAttachment(0, e.y);
-                    store.setValue(PREFS_THREAD_SASH, e.y);
-                    mThreadBase.layout();
-                }
-            }
-        });
-
-        ((StackLayout)mBase.getLayout()).topControl = mNotSelected;
-
-        return mBase;
-    }
-    
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mThreadTable.setFocus();
-    }
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA}
-     *
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        if (client == getCurrentClient()) {
-            if ((changeMask & Client.CHANGE_THREAD_MODE) != 0 ||
-                    (changeMask & Client.CHANGE_THREAD_DATA) != 0) {
-                try {
-                    mThreadTable.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            clientSelected();
-                        }
-                    });
-                } catch (SWTException e) {
-                    // widget is disposed, we do nothing
-                }
-            } else if ((changeMask & Client.CHANGE_THREAD_STACKTRACE) != 0) {
-                try {
-                    mThreadTable.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            updateThreadStackCall();
-                        }
-                    });
-                } catch (SWTException e) {
-                    // widget is disposed, we do nothing
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}.
-     */
-    @Override
-    public void deviceSelected() {
-        // pass
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-        if (mThreadTable.isDisposed()) {
-            return;
-        }
-
-        Client client = getCurrentClient();
-        
-        mStackTracePanel.setCurrentClient(client);
-
-        if (client != null) {
-            if (!client.isThreadUpdateEnabled()) {
-                ((StackLayout)mBase.getLayout()).topControl = mNotEnabled;
-                mThreadViewer.setInput(null);
-
-                // if we are currently updating the thread, stop doing it.
-                mMustStopRecurringThreadUpdate = true;
-            } else {
-                ((StackLayout)mBase.getLayout()).topControl = mThreadBase;
-                mThreadViewer.setInput(client);
-
-                synchronized (mLock) {
-                    // if we're not updating we start the process
-                    if (mRecurringThreadUpdateRunning == false) {
-                        startRecurringThreadUpdate();
-                    } else if (mMustStopRecurringThreadUpdate) {
-                        // else if there's a runnable that's still going to get called, lets
-                        // simply cancel the stop, and keep going
-                        mMustStopRecurringThreadUpdate = false;
-                    }
-                }
-            }
-        } else {
-            ((StackLayout)mBase.getLayout()).topControl = mNotSelected;
-            mThreadViewer.setInput(null);
-        }
-
-        mBase.layout();
-    }
-    
-    /**
-     * Updates the stack call of the currently selected thread.
-     * <p/>
-     * This <b>must</b> be called from the UI thread.
-     */
-    private void updateThreadStackCall() {
-        Client client = getCurrentClient();
-        if (client != null) {
-            // get the current selection in the ThreadTable
-            ThreadInfo selectedThread = getThreadSelection(null);
-            
-            if (selectedThread != null) {
-                updateThreadStackTrace(selectedThread);
-            } else {
-                updateThreadStackTrace(null);
-            }
-        }
-    }
-    
-    /**
-     * updates the stackcall of the specified thread. If <code>null</code> the UI is emptied
-     * of current data.
-     * @param thread
-     */
-    private void updateThreadStackTrace(ThreadInfo thread) {
-        mStackTracePanel.setViewerInput(thread);
-        
-        if (thread != null) {
-            mRefreshStackTraceButton.setEnabled(true);
-            long stackcallTime = thread.getStackCallTime();
-            if (stackcallTime != 0) {
-                String label = new Date(stackcallTime).toString();
-                mStackTraceTimeLabel.setText(label);
-            } else {
-                mStackTraceTimeLabel.setText(""); //$NON-NLS-1$
-            }
-        } else {
-            mRefreshStackTraceButton.setEnabled(true);
-            mStackTraceTimeLabel.setText(""); //$NON-NLS-1$
-        }
-    }
-
-    @Override
-    protected void setTableFocusListener() {
-        addTableToFocusListener(mThreadTable);
-        addTableToFocusListener(mStackTraceTable);
-    }
-
-    /**
-     * Initiate recurring events. We use a shorter "initialWait" so we do the
-     * first execution sooner. We don't do it immediately because we want to
-     * give the clients a chance to get set up.
-     */
-    private void startRecurringThreadUpdate() {
-        mRecurringThreadUpdateRunning = true;
-        int initialWait = 1000;
-
-        mDisplay.timerExec(initialWait, new Runnable() {
-            public void run() {
-                synchronized (mLock) {
-                    // lets check we still want updates.
-                    if (mMustStopRecurringThreadUpdate == false) {
-                        Client client = getCurrentClient();
-                        if (client != null) {
-                            client.requestThreadUpdate();
-
-                            mDisplay.timerExec(
-                                    DdmUiPreferences.getThreadRefreshInterval() * 1000, this);
-                        } else {
-                            // we don't have a Client, which means the runnable is not
-                            // going to be called through the timer. We reset the running flag.
-                            mRecurringThreadUpdateRunning = false;
-                        }
-                    } else {
-                        // else actually stops (don't call the timerExec) and reset the flags.
-                        mRecurringThreadUpdateRunning = false;
-                        mMustStopRecurringThreadUpdate = false;
-                    }
-                }
-            }
-        });
-    }
-    
-    /**
-     * Returns the current thread selection or <code>null</code> if none is found.
-     * If a {@link ISelection} object is specified, the first {@link ThreadInfo} from this selection
-     * is returned, otherwise, the <code>ISelection</code> returned by
-     * {@link TableViewer#getSelection()} is used.
-     * @param selection the {@link ISelection} to use, or <code>null</code>
-     */
-    private ThreadInfo getThreadSelection(ISelection selection) {
-        if (selection == null) {
-            selection = mThreadViewer.getSelection();
-        }
-        
-        if (selection instanceof IStructuredSelection) {
-            IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-            Object object = structuredSelection.getFirstElement();
-            if (object instanceof ThreadInfo) {
-                return (ThreadInfo)object;
-            }
-        }
-        
-        return null;
-    }
-
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/WritePng.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/WritePng.java
deleted file mode 100644
index f65dafe..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/WritePng.java
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib;
-
-import com.android.ddmlib.Log;
-
-import org.eclipse.swt.graphics.ImageData;
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.OutputStream;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.util.zip.CRC32;
-import java.util.zip.Deflater;
-
-/**
- * Compensate for SWT issues by writing our own PNGs from ImageData.
- */
-public class WritePng {
-    private WritePng() {}
-
-    private static final byte[] PNG_MAGIC =
-        new byte[] { -119, 80, 78, 71, 13, 10, 26, 10 };
-
-    public static void savePng(String fileName, ImageData imageData)
-        throws IOException {
-
-        try {
-            FileOutputStream out = new FileOutputStream(fileName);
-
-            Log.d("ddms", "Saving to PNG, width=" + imageData.width
-                + ", height=" + imageData.height
-                + ", depth=" + imageData.depth
-                + ", bpl=" + imageData.bytesPerLine);
-
-            savePng(out, imageData);
-
-            // need to do that on, or the file is empty on windows!
-            out.flush();
-            out.close();
-        } catch (Exception e) {
-            Log.e("writepng", e);
-        }
-    }
-
-    /*
-     * Supply functionality missing from our version of SWT.
-     */
-    private static void savePng(OutputStream out, ImageData imageData)
-        throws IOException {
-
-        int width = imageData.width;
-        int height = imageData.height;
-        byte[] out24;
-
-        Log.i("ddms-png", "Convert to 24bit from " + imageData.depth);
-
-        if (imageData.depth == 24 || imageData.depth == 32) {
-            out24 = convertTo24ForPng(imageData.data, width, height,
-                imageData.depth, imageData.bytesPerLine);
-        } else if (imageData.depth == 16) {
-            out24 = convert16to24(imageData);
-        } else {
-            return;
-        }
-
-        // Create the compressed form.  I'm taking the low road here and
-        // just creating a large buffer, which should always be enough to
-        // hold the compressed output.
-        byte[] compPixels = new byte[out24.length + 16384];
-        Deflater compressor = new Deflater();
-        compressor.setLevel(Deflater.BEST_COMPRESSION);
-        compressor.setInput(out24);
-        compressor.finish();
-        int compLen;
-        do {        // must do this in a loop to satisfy java.util.Zip
-            compLen = compressor.deflate(compPixels);
-            assert compLen != 0 || !compressor.needsInput();
-        } while (compLen == 0);
-        Log.d("ddms", "Compressed image data from " + out24.length
-            + " to " + compLen);
-
-        // Write the PNG magic
-        out.write(PNG_MAGIC);
-
-        ByteBuffer buf;
-        CRC32 crc;
-
-        // Write the IHDR chunk (13 bytes)
-        byte[] header = new byte[8 + 13 + 4];
-        buf = ByteBuffer.wrap(header);
-        buf.order(ByteOrder.BIG_ENDIAN);
-
-        putChunkHeader(buf, 13, "IHDR");
-        buf.putInt(width);
-        buf.putInt(height);
-        buf.put((byte) 8);       // 8pp
-        buf.put((byte) 2);       // direct color used
-        buf.put((byte) 0);       // compression method == deflate
-        buf.put((byte) 0);       // filter method (none)
-        buf.put((byte) 0);       // interlace method (none)
-
-        crc = new CRC32();
-        crc.update(header, 4, 4+13);
-        buf.putInt((int)crc.getValue());
-
-        out.write(header);
-
-        // Write the IDAT chunk
-        byte[] datHdr = new byte[8 + 0 + 4];
-        buf = ByteBuffer.wrap(datHdr);
-        buf.order(ByteOrder.BIG_ENDIAN);
-
-        putChunkHeader(buf, compLen, "IDAT");
-        crc = new CRC32();
-        crc.update(datHdr, 4, 4+0);
-        crc.update(compPixels, 0, compLen);
-        buf.putInt((int) crc.getValue());
-
-        out.write(datHdr, 0, 8);
-        out.write(compPixels, 0, compLen);
-        out.write(datHdr, 8, 4);
-
-        // Write the IEND chunk (0 bytes)
-        byte[] trailer = new byte[8 + 0 + 4];
-
-        buf = ByteBuffer.wrap(trailer);
-        buf.order(ByteOrder.BIG_ENDIAN);
-        putChunkHeader(buf, 0, "IEND");
-
-        crc = new CRC32();
-        crc.update(trailer, 4, 4+0);
-        buf.putInt((int)crc.getValue());
-
-        out.write(trailer);
-    }
-
-    /*
-     * Output a chunk header.
-     */
-    private static void putChunkHeader(ByteBuffer buf, int length,
-        String typeStr) {
-
-        int type = 0;
-
-        if (typeStr.length() != 4)
-            throw new RuntimeException();
-
-        for (int i = 0; i < 4; i++) {
-            type <<= 8;
-            type |= (byte) typeStr.charAt(i);
-        }
-
-        buf.putInt(length);
-        buf.putInt(type);
-    }
-
-    /*
-     * Convert raw pixels to 24-bit RGB with a "filter" byte at the start
-     * of each row.
-     */
-    private static byte[] convertTo24ForPng(byte[] in, int width, int height,
-        int depth, int stride) {
-
-        assert depth == 24 || depth == 32;
-        assert stride == width * (depth/8);
-
-        // 24 bit pixels plus one byte per line for "filter"
-        byte[] out24 = new byte[width * height * 3 + height];
-        int y;
-
-        int inOff = 0;
-        int outOff = 0;
-        for (y = 0; y < height; y++) {
-            out24[outOff++] = 0;           // filter flag
-
-            if (depth == 24) {
-                System.arraycopy(in, inOff, out24, outOff, width * 3);
-                outOff += width * 3;
-            } else if (depth == 32) {
-                int tmpOff = inOff;
-                for (int x = 0; x < width; x++) {
-                    tmpOff++;       // ignore alpha
-                    out24[outOff++] = in[tmpOff++];
-                    out24[outOff++] = in[tmpOff++];
-                    out24[outOff++] = in[tmpOff++];
-                }
-            }
-
-            inOff += stride;
-        }
-
-        assert outOff == out24.length;
-
-        return out24;
-    }
-
-    private static byte[] convert16to24(ImageData imageData) {
-        int width = imageData.width;
-        int height = imageData.height;
-
-        int redShift = imageData.palette.redShift;
-        int greenShift = imageData.palette.greenShift;
-        int blueShift = imageData.palette.blueShift;
-
-        int redMask = imageData.palette.redMask;
-        int greenMask = imageData.palette.greenMask;
-        int blueMask = imageData.palette.blueMask;
-
-        // 24 bit pixels plus one byte per line for "filter"
-        byte[] out24 = new byte[width * height * 3 + height];
-        int outOff = 0;
-
-
-        int[] line = new int[width];
-        for (int y = 0; y < height; y++) {
-            imageData.getPixels(0, y, width, line, 0);
-
-            out24[outOff++] = 0; // filter flag
-            for (int x = 0; x < width; x++) {
-                int pixelValue = line[x];
-                out24[outOff++] = byteChannelValue(pixelValue, redMask, redShift);
-                out24[outOff++] = byteChannelValue(pixelValue, greenMask, greenShift);
-                out24[outOff++] = byteChannelValue(pixelValue, blueMask, blueShift);
-            }
-        }
-
-        return out24;
-    }
-
-    private static byte byteChannelValue(int value, int mask, int shift) {
-        int bValue = value & mask;
-        if (shift < 0) {
-            bValue = bValue >>> -shift;
-        } else {
-            bValue = bValue << shift;
-        }
-
-        return (byte)bValue;
-
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ICommonAction.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ICommonAction.java
deleted file mode 100644
index 856b874..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ICommonAction.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.actions;
-
-/**
- * Common interface for basic action handling. This allows the common ui
- * components to access ToolItem or Action the same way.
- */
-public interface ICommonAction {
-    /**
-     * Sets the enabled state of this action.
-     * @param enabled <code>true</code> to enable, and
-     *   <code>false</code> to disable
-     */
-    public void setEnabled(boolean enabled);
-
-    /**
-     * Sets the checked status of this action.
-     * @param checked the new checked status
-     */
-    public void setChecked(boolean checked);
-    
-    /**
-     * Sets the {@link Runnable} that will be executed when the action is triggered.
-     */
-    public void setRunnable(Runnable runnable);
-}
-
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ToolItemAction.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ToolItemAction.java
deleted file mode 100644
index bc1598f..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/actions/ToolItemAction.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.actions;
-
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.widgets.ToolBar;
-import org.eclipse.swt.widgets.ToolItem;
-
-/**
- * Wrapper around {@link ToolItem} to implement {@link ICommonAction}
- */
-public class ToolItemAction implements ICommonAction {
-    public ToolItem item;
-
-    public ToolItemAction(ToolBar parent, int style) {
-        item = new ToolItem(parent, style);
-    }
-
-    /**
-     * Sets the enabled state of this action.
-     * @param enabled <code>true</code> to enable, and
-     *   <code>false</code> to disable
-     * @see ICommonAction#setChecked(boolean)
-     */
-    public void setChecked(boolean checked) {
-        item.setSelection(checked);
-    }
-
-    /**
-     * Sets the enabled state of this action.
-     * @param enabled <code>true</code> to enable, and
-     *   <code>false</code> to disable
-     * @see ICommonAction#setEnabled(boolean)
-     */
-    public void setEnabled(boolean enabled) {
-        item.setEnabled(enabled);
-    }
-
-    /**
-     * Sets the {@link Runnable} that will be executed when the action is triggered (through
-     * {@link SelectionListener#widgetSelected(SelectionEvent)} on the wrapped {@link ToolItem}).
-     * @see ICommonAction#setRunnable(Runnable)
-     */
-    public void setRunnable(final Runnable runnable) {
-        item.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                runnable.run();
-            }
-        });
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/UiThread.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/UiThread.java
deleted file mode 100644
index 8e9e11b..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/UiThread.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.annotation;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-
-/**
- * Simple utility annotation used only to mark methods that are executed on the UI thread.
- * This annotation's sole purpose is to help reading the source code. It has no additional effect.
- */
-@Target({ ElementType.METHOD })
-@Retention(RetentionPolicy.SOURCE)
-public @interface UiThread {
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/WorkerThread.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/WorkerThread.java
deleted file mode 100644
index e767eda..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/annotation/WorkerThread.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.annotation;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-
-/**
- * Simple utility annotation used only to mark methods that are not executed on the UI thread.
- * This annotation's sole purpose is to help reading the source code. It has no additional effect.
- */
-@Target({ ElementType.METHOD })
-@Retention(RetentionPolicy.SOURCE)
-public @interface WorkerThread {
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/DdmConsole.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/DdmConsole.java
deleted file mode 100644
index 4df4376..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/DdmConsole.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.console;
-
-
-/**
- * Static Console used to ouput messages. By default outputs the message to System.out and
- * System.err, but can receive a IDdmConsole object which will actually do something.
- */
-public class DdmConsole {
-
-    private static IDdmConsole mConsole;
-
-    /**
-     * Prints a message to the android console.
-     * @param message the message to print
-     * @param forceDisplay if true, this force the console to be displayed.
-     */
-    public static void printErrorToConsole(String message) {
-        if (mConsole != null) {
-            mConsole.printErrorToConsole(message);
-        } else {
-            System.err.println(message);
-        }
-    }
-
-    /**
-     * Prints several messages to the android console.
-     * @param messages the messages to print
-     * @param forceDisplay if true, this force the console to be displayed.
-     */
-    public static void printErrorToConsole(String[] messages) {
-        if (mConsole != null) {
-            mConsole.printErrorToConsole(messages);
-        } else {
-            for (String message : messages) {
-                System.err.println(message);
-            }
-        }
-    }
-
-    /**
-     * Prints a message to the android console.
-     * @param message the message to print
-     * @param forceDisplay if true, this force the console to be displayed.
-     */
-    public static void printToConsole(String message) {
-        if (mConsole != null) {
-            mConsole.printToConsole(message);
-        } else {
-            System.out.println(message);
-        }
-    }
-
-    /**
-     * Prints several messages to the android console.
-     * @param messages the messages to print
-     * @param forceDisplay if true, this force the console to be displayed.
-     */
-    public static void printToConsole(String[] messages) {
-        if (mConsole != null) {
-            mConsole.printToConsole(messages);
-        } else {
-            for (String message : messages) {
-                System.out.println(message);
-            }
-        }
-    }
-
-    /**
-     * Sets a IDdmConsole to override the default behavior of the console
-     * @param console The new IDdmConsole
-     * **/
-    public static void setConsole(IDdmConsole console) {
-        mConsole = console;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/IDdmConsole.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/IDdmConsole.java
deleted file mode 100644
index 3679d41..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/console/IDdmConsole.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.console;
-
-
-/**
- * DDMS console interface.
- */
-public interface IDdmConsole {
-    /**
-     * Prints a message to the android console.
-     * @param message the message to print
-     */
-    public void printErrorToConsole(String message);
-
-    /**
-     * Prints several messages to the android console.
-     * @param messages the messages to print
-     */
-    public void printErrorToConsole(String[] messages);
-
-    /**
-     * Prints a message to the android console.
-     * @param message the message to print
-     */
-    public void printToConsole(String message);
-
-    /**
-     * Prints several messages to the android console.
-     * @param messages the messages to print
-     */
-    public void printToConsole(String[] messages);
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceContentProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceContentProvider.java
deleted file mode 100644
index 75c19fe..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceContentProvider.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.explorer;
-
-import com.android.ddmlib.FileListingService;
-import com.android.ddmlib.FileListingService.FileEntry;
-import com.android.ddmlib.FileListingService.IListingReceiver;
-
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Tree;
-
-/**
- * Content provider class for device Explorer.
- */
-class DeviceContentProvider implements ITreeContentProvider {
-
-    private TreeViewer mViewer;
-    private FileListingService mFileListingService;
-    private FileEntry mRootEntry;
-
-    private IListingReceiver sListingReceiver = new IListingReceiver() {
-        public void setChildren(final FileEntry entry, FileEntry[] children) {
-            final Tree t = mViewer.getTree();
-            if (t != null && t.isDisposed() == false) {
-                Display display = t.getDisplay();
-                if (display.isDisposed() == false) {
-                    display.asyncExec(new Runnable() {
-                        public void run() {
-                            if (t.isDisposed() == false) {
-                                // refresh the entry.
-                                mViewer.refresh(entry);
-
-                                // force it open, since on linux and windows
-                                // when getChildren() returns null, the node is
-                                // not considered expanded.
-                                mViewer.setExpandedState(entry, true);
-                            }
-                        }
-                    });
-                }
-            }
-        }
-
-        public void refreshEntry(final FileEntry entry) {
-            final Tree t = mViewer.getTree();
-            if (t != null && t.isDisposed() == false) {
-                Display display = t.getDisplay();
-                if (display.isDisposed() == false) {
-                    display.asyncExec(new Runnable() {
-                        public void run() {
-                            if (t.isDisposed() == false) {
-                                // refresh the entry.
-                                mViewer.refresh(entry);
-                            }
-                        }
-                    });
-                }
-            }
-        }
-    };
-
-    /**
-     *
-     */
-    public DeviceContentProvider() {
-    }
-
-    public void setListingService(FileListingService fls) {
-        mFileListingService = fls;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
-     */
-    public Object[] getChildren(Object parentElement) {
-        if (parentElement instanceof FileEntry) {
-            FileEntry parentEntry = (FileEntry)parentElement;
-
-            Object[] oldEntries = parentEntry.getCachedChildren();
-            Object[] newEntries = mFileListingService.getChildren(parentEntry,
-                    true, sListingReceiver);
-
-            if (newEntries != null) {
-                return newEntries;
-            } else {
-                // if null was returned, this means the cache was not valid,
-                // and a thread was launched for ls. sListingReceiver will be
-                // notified with the new entries.
-                return oldEntries;
-            }
-        }
-        return new Object[0];
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object)
-     */
-    public Object getParent(Object element) {
-        if (element instanceof FileEntry) {
-            FileEntry entry = (FileEntry)element;
-
-            return entry.getParent();
-        }
-        return null;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object)
-     */
-    public boolean hasChildren(Object element) {
-        if (element instanceof FileEntry) {
-            FileEntry entry = (FileEntry)element;
-
-            return entry.getType() == FileListingService.TYPE_DIRECTORY;
-        }
-        return false;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object)
-     */
-    public Object[] getElements(Object inputElement) {
-        if (inputElement instanceof FileEntry) {
-            FileEntry entry = (FileEntry)inputElement;
-            if (entry.isRoot()) {
-                return getChildren(mRootEntry);
-            }
-        }
-
-        return null;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IContentProvider#dispose()
-     */
-    public void dispose() {
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
-     */
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        if (viewer instanceof TreeViewer) {
-            mViewer = (TreeViewer)viewer;
-        }
-        if (newInput instanceof FileEntry) {
-            mRootEntry = (FileEntry)newInput;
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceExplorer.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceExplorer.java
deleted file mode 100644
index ba0f555..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/DeviceExplorer.java
+++ /dev/null
@@ -1,833 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.explorer;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.FileListingService;
-import com.android.ddmlib.IShellOutputReceiver;
-import com.android.ddmlib.SyncService;
-import com.android.ddmlib.FileListingService.FileEntry;
-import com.android.ddmlib.SyncService.ISyncProgressMonitor;
-import com.android.ddmlib.SyncService.SyncResult;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.Panel;
-import com.android.ddmuilib.TableHelper;
-import com.android.ddmuilib.actions.ICommonAction;
-import com.android.ddmuilib.console.DdmConsole;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.dialogs.ProgressMonitorDialog;
-import org.eclipse.jface.operation.IRunnableWithProgress;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.ViewerDropAdapter;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.dnd.DND;
-import org.eclipse.swt.dnd.FileTransfer;
-import org.eclipse.swt.dnd.Transfer;
-import org.eclipse.swt.dnd.TransferData;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.DirectoryDialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeItem;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Device filesystem explorer class.
- */
-public class DeviceExplorer extends Panel {
-
-    private final static String TRACE_KEY_EXT = ".key"; // $NON-NLS-1S
-    private final static String TRACE_DATA_EXT = ".data"; // $NON-NLS-1S
-
-    private static Pattern mKeyFilePattern = Pattern.compile(
-            "(.+)\\" + TRACE_KEY_EXT); // $NON-NLS-1S
-    private static Pattern mDataFilePattern = Pattern.compile(
-            "(.+)\\" + TRACE_DATA_EXT); // $NON-NLS-1S
-
-    public static String COLUMN_NAME = "android.explorer.name"; //$NON-NLS-1S
-    public static String COLUMN_SIZE = "android.explorer.size"; //$NON-NLS-1S
-    public static String COLUMN_DATE = "android.explorer.data"; //$NON-NLS-1S
-    public static String COLUMN_TIME = "android.explorer.time"; //$NON-NLS-1S
-    public static String COLUMN_PERMISSIONS = "android.explorer.permissions"; // $NON-NLS-1S
-    public static String COLUMN_INFO = "android.explorer.info"; // $NON-NLS-1S
-
-    private Composite mParent;
-    private TreeViewer mTreeViewer;
-    private Tree mTree;
-    private DeviceContentProvider mContentProvider;
-
-    private ICommonAction mPushAction;
-    private ICommonAction mPullAction;
-    private ICommonAction mDeleteAction;
-
-    private Image mFileImage;
-    private Image mFolderImage;
-    private Image mPackageImage;
-    private Image mOtherImage;
-
-    private Device mCurrentDevice;
-
-    private String mDefaultSave;
-
-    /**
-     * Implementation of the SyncService.ISyncProgressMonitor. It wraps a jFace IProgressMonitor
-     * and just forward the calls to the jFace object.
-     */
-    private static class SyncProgressMonitor implements ISyncProgressMonitor {
-
-        private IProgressMonitor mMonitor;
-        private String mName;
-
-        SyncProgressMonitor(IProgressMonitor monitor, String name) {
-            mMonitor = monitor;
-            mName = name;
-        }
-
-        public void start(int totalWork) {
-            mMonitor.beginTask(mName, totalWork);
-        }
-
-        public void stop() {
-            mMonitor.done();
-        }
-
-        public void advance(int work) {
-            mMonitor.worked(work);
-        }
-
-        public boolean isCanceled() {
-            return mMonitor.isCanceled();
-        }
-
-        public void startSubTask(String name) {
-            mMonitor.subTask(name);
-        }
-    }
-
-    public DeviceExplorer() {
-
-    }
-
-    /**
-     * Sets the images for the listview
-     * @param fileImage
-     * @param folderImage
-     * @param otherImage
-     */
-    public void setImages(Image fileImage, Image folderImage, Image packageImage,
-            Image otherImage) {
-        mFileImage = fileImage;
-        mFolderImage = folderImage;
-        mPackageImage = packageImage;
-        mOtherImage = otherImage;
-    }
-
-    /**
-     * Sets the actions so that the device explorer can enable/disable them based on the current
-     * selection
-     * @param pushAction
-     * @param pullAction
-     * @param deleteAction
-     */
-    public void setActions(ICommonAction pushAction, ICommonAction pullAction,
-            ICommonAction deleteAction) {
-        mPushAction = pushAction;
-        mPullAction = pullAction;
-        mDeleteAction = deleteAction;
-    }
-
-    /**
-     * Creates a control capable of displaying some information.  This is
-     * called once, when the application is initializing, from the UI thread.
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mParent = parent;
-        parent.setLayout(new FillLayout());
-
-        mTree = new Tree(parent, SWT.MULTI | SWT.FULL_SELECTION | SWT.VIRTUAL);
-        mTree.setHeaderVisible(true);
-
-        IPreferenceStore store = DdmUiPreferences.getStore();
-
-        // create columns
-        TableHelper.createTreeColumn(mTree, "Name", SWT.LEFT,
-                "0000drwxrwxrwx", COLUMN_NAME, store); //$NON-NLS-1$
-        TableHelper.createTreeColumn(mTree, "Size", SWT.RIGHT,
-                "000000", COLUMN_SIZE, store); //$NON-NLS-1$
-        TableHelper.createTreeColumn(mTree, "Date", SWT.LEFT,
-                "2007-08-14", COLUMN_DATE, store); //$NON-NLS-1$
-        TableHelper.createTreeColumn(mTree, "Time", SWT.LEFT,
-                "20:54", COLUMN_TIME, store); //$NON-NLS-1$
-        TableHelper.createTreeColumn(mTree, "Permissions", SWT.LEFT,
-                "drwxrwxrwx", COLUMN_PERMISSIONS, store); //$NON-NLS-1$
-        TableHelper.createTreeColumn(mTree, "Info", SWT.LEFT,
-                "drwxrwxrwx", COLUMN_INFO, store); //$NON-NLS-1$
-
-        // create the jface wrapper
-        mTreeViewer = new TreeViewer(mTree);
-
-        // setup data provider
-        mContentProvider = new DeviceContentProvider();
-        mTreeViewer.setContentProvider(mContentProvider);
-        mTreeViewer.setLabelProvider(new FileLabelProvider(mFileImage,
-                mFolderImage, mPackageImage, mOtherImage));
-
-        // setup a listener for selection
-        mTreeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection sel = event.getSelection();
-                if (sel.isEmpty()) {
-                    mPullAction.setEnabled(false);
-                    mPushAction.setEnabled(false);
-                    mDeleteAction.setEnabled(false);
-                    return;
-                }
-                if (sel instanceof IStructuredSelection) {
-                    IStructuredSelection selection = (IStructuredSelection) sel;
-                    Object element = selection.getFirstElement();
-                    if (element == null)
-                        return;
-                    if (element instanceof FileEntry) {
-                        mPullAction.setEnabled(true);
-                        mPushAction.setEnabled(selection.size() == 1);
-                        if (selection.size() == 1) {
-                            setDeleteEnabledState((FileEntry)element);
-                        } else {
-                            mDeleteAction.setEnabled(false);
-                        }
-                    }
-                }
-            }
-        });
-
-        // add support for double click
-        mTreeViewer.addDoubleClickListener(new IDoubleClickListener() {
-            public void doubleClick(DoubleClickEvent event) {
-                ISelection sel = event.getSelection();
-
-                if (sel instanceof IStructuredSelection) {
-                    IStructuredSelection selection = (IStructuredSelection) sel;
-
-                    if (selection.size() == 1) {
-                        FileEntry entry = (FileEntry)selection.getFirstElement();
-                        String name = entry.getName();
-
-                        FileEntry parentEntry = entry.getParent();
-
-                        // can't really do anything with no parent
-                        if (parentEntry == null) {
-                            return;
-                        }
-
-                        // check this is a file like we want.
-                        Matcher m = mKeyFilePattern.matcher(name);
-                        if (m.matches()) {
-                            // get the name w/o the extension
-                            String baseName = m.group(1);
-
-                            // add the data extension
-                            String dataName = baseName + TRACE_DATA_EXT;
-
-                            FileEntry dataEntry = parentEntry.findChild(dataName);
-
-                            handleTraceDoubleClick(baseName, entry, dataEntry);
-
-                        } else {
-                            m = mDataFilePattern.matcher(name);
-                            if (m.matches()) {
-                                // get the name w/o the extension
-                                String baseName = m.group(1);
-
-                                // add the key extension
-                                String keyName = baseName + TRACE_KEY_EXT;
-
-                                FileEntry keyEntry = parentEntry.findChild(keyName);
-
-                                handleTraceDoubleClick(baseName, keyEntry, entry);
-                            }
-                        }
-                    }
-                }
-            }
-        });
-
-        // setup drop listener
-        mTreeViewer.addDropSupport(DND.DROP_COPY | DND.DROP_MOVE,
-                new Transfer[] { FileTransfer.getInstance() },
-                new ViewerDropAdapter(mTreeViewer) {
-            @Override
-            public boolean performDrop(Object data) {
-                // get the item on which we dropped the item(s)
-                FileEntry target = (FileEntry)getCurrentTarget();
-
-                // in case we drop at the same level as root
-                if (target == null) {
-                    return false;
-                }
-
-                // if the target is not a directory, we get the parent directory
-                if (target.isDirectory() == false) {
-                    target = target.getParent();
-                }
-
-                if (target == null) {
-                    return false;
-                }
-
-                // get the list of files to drop
-                String[] files = (String[])data;
-
-                // do the drop
-                pushFiles(files, target);
-
-                // we need to finish with a refresh
-                refresh(target);
-
-                return true;
-            }
-
-            @Override
-            public boolean validateDrop(Object target, int operation, TransferData transferType) {
-                if (target == null) {
-                    return false;
-                }
-
-                // convert to the real item
-                FileEntry targetEntry = (FileEntry)target;
-
-                // if the target is not a directory, we get the parent directory
-                if (targetEntry.isDirectory() == false) {
-                    target = targetEntry.getParent();
-                }
-
-                if (target == null) {
-                    return false;
-                }
-
-                return true;
-            }
-        });
-
-        // create and start the refresh thread
-        new Thread("Device Ls refresher") {
-            @Override
-            public void run() {
-                while (true) {
-                    try {
-                        sleep(FileListingService.REFRESH_RATE);
-                    } catch (InterruptedException e) {
-                        return;
-                    }
-
-                    if (mTree != null && mTree.isDisposed() == false) {
-                        Display display = mTree.getDisplay();
-                        if (display.isDisposed() == false) {
-                            display.asyncExec(new Runnable() {
-                                public void run() {
-                                    if (mTree.isDisposed() == false) {
-                                        mTreeViewer.refresh(true);
-                                    }
-                                }
-                            });
-                        } else {
-                            return;
-                        }
-                    } else {
-                        return;
-                    }
-                }
-
-            }
-        }.start();
-        
-        return mTree;
-    }
-    
-    @Override
-    protected void postCreation() {
-        
-    }
-
-    /**
-     * Sets the focus to the proper control inside the panel.
-     */
-    @Override
-    public void setFocus() {
-        mTree.setFocus();
-    }
-
-    /**
-     * Processes a double click on a trace file
-     * @param baseName the base name of the 2 files.
-     * @param keyEntry The FileEntry for the .key file.
-     * @param dataEntry The FileEntry for the .data file.
-     */
-    private void handleTraceDoubleClick(String baseName, FileEntry keyEntry,
-            FileEntry dataEntry) {
-        // first we need to download the files.
-        File keyFile;
-        File dataFile;
-        String path;
-        try {
-            // create a temp file for keyFile
-            File f = File.createTempFile(baseName, ".trace");
-            f.delete();
-            f.mkdir();
-
-            path = f.getAbsolutePath();
-
-            keyFile = new File(path + File.separator + keyEntry.getName());
-            dataFile = new File(path + File.separator + dataEntry.getName());
-        } catch (IOException e) {
-            return;
-        }
-
-        // download the files
-        SyncService sync = mCurrentDevice.getSyncService();
-        if (sync != null) {
-            ISyncProgressMonitor monitor = SyncService.getNullProgressMonitor();
-            SyncResult result = sync.pullFile(keyEntry, keyFile.getAbsolutePath(), monitor);
-            if (result.getCode() != SyncService.RESULT_OK) {
-                DdmConsole.printErrorToConsole(String.format(
-                        "Failed to pull %1$s: %2$s", keyEntry.getName(), result.getMessage()));
-                return;
-            }
-
-            result = sync.pullFile(dataEntry, dataFile.getAbsolutePath(), monitor);
-            if (result.getCode() != SyncService.RESULT_OK) {
-                DdmConsole.printErrorToConsole(String.format(
-                        "Failed to pull %1$s: %2$s", dataEntry.getName(), result.getMessage()));
-                return;
-            }
-
-            // now that we have the file, we need to launch traceview
-            String[] command = new String[2];
-            command[0] = DdmUiPreferences.getTraceview();
-            command[1] = path + File.separator + baseName;
-
-            try {
-                final Process p = Runtime.getRuntime().exec(command);
-
-                // create a thread for the output
-                new Thread("Traceview output") {
-                    @Override
-                    public void run() {
-                        // create a buffer to read the stderr output
-                        InputStreamReader is = new InputStreamReader(p.getErrorStream());
-                        BufferedReader resultReader = new BufferedReader(is);
-
-                        // read the lines as they come. if null is returned, it's
-                        // because the process finished
-                        try {
-                            while (true) {
-                                String line = resultReader.readLine();
-                                if (line != null) {
-                                    DdmConsole.printErrorToConsole("Traceview: " + line);
-                                } else {
-                                    break;
-                                }
-                            }
-                            // get the return code from the process
-                            p.waitFor();
-                        } catch (IOException e) {
-                        } catch (InterruptedException e) {
-
-                        }
-                    }
-                }.start();
-
-            } catch (IOException e) {
-            }
-        }
-    }
-
-    /**
-     * Pull the current selection on the local drive. This method displays
-     * a dialog box to let the user select where to store the file(s) and
-     * folder(s).
-     */
-    public void pullSelection() {
-        // get the selection
-        TreeItem[] items = mTree.getSelection();
-
-        // name of the single file pull, or null if we're pulling a directory
-        // or more than one object.
-        String filePullName = null;
-        FileEntry singleEntry = null;
-
-        // are we pulling a single file?
-        if (items.length == 1) {
-            singleEntry = (FileEntry)items[0].getData();
-            if (singleEntry.getType() == FileListingService.TYPE_FILE) {
-                filePullName = singleEntry.getName();
-            }
-        }
-
-        // where do we save by default?
-        String defaultPath = mDefaultSave;
-        if (defaultPath == null) {
-            defaultPath = System.getProperty("user.home"); //$NON-NLS-1$
-        }
-
-        if (filePullName != null) {
-            FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.SAVE);
-
-            fileDialog.setText("Get Device File");
-            fileDialog.setFileName(filePullName);
-            fileDialog.setFilterPath(defaultPath);
-
-            String fileName = fileDialog.open();
-            if (fileName != null) {
-                mDefaultSave = fileDialog.getFilterPath();
-
-                pullFile(singleEntry, fileName);
-            }
-        } else {
-            DirectoryDialog directoryDialog = new DirectoryDialog(mParent.getShell(), SWT.SAVE);
-
-            directoryDialog.setText("Get Device Files/Folders");
-            directoryDialog.setFilterPath(defaultPath);
-
-            String directoryName = directoryDialog.open();
-            if (directoryName != null) {
-                pullSelection(items, directoryName);
-            }
-        }
-    }
-
-    /**
-     * Push new file(s) and folder(s) into the current selection. Current
-     * selection must be single item. If the current selection is not a
-     * directory, the parent directory is used.
-     * This method displays a dialog to let the user choose file to push to
-     * the device.
-     */
-    public void pushIntoSelection() {
-        // get the name of the object we're going to pull
-        TreeItem[] items = mTree.getSelection();
-
-        if (items.length == 0) {
-            return;
-        }
-
-        FileDialog dlg = new FileDialog(mParent.getShell(), SWT.OPEN);
-        String fileName;
-
-        dlg.setText("Put File on Device");
-
-        // There should be only one.
-        FileEntry entry = (FileEntry)items[0].getData();
-        dlg.setFileName(entry.getName());
-
-        String defaultPath = mDefaultSave;
-        if (defaultPath == null) {
-            defaultPath = System.getProperty("user.home"); //$NON-NLS-1$
-        }
-        dlg.setFilterPath(defaultPath);
-
-        fileName = dlg.open();
-        if (fileName != null) {
-            mDefaultSave = dlg.getFilterPath();
-
-            // we need to figure out the remote path based on the current selection type.
-            String remotePath;
-            FileEntry toRefresh = entry;
-            if (entry.isDirectory()) {
-                remotePath = entry.getFullPath();
-            } else {
-                toRefresh = entry.getParent();
-                remotePath = toRefresh.getFullPath();
-            }
-
-            pushFile(fileName, remotePath);
-            mTreeViewer.refresh(toRefresh);
-        }
-    }
-
-    public void deleteSelection() {
-        // get the name of the object we're going to pull
-        TreeItem[] items = mTree.getSelection();
-
-        if (items.length != 1) {
-            return;
-        }
-
-        FileEntry entry = (FileEntry)items[0].getData();
-        final FileEntry parentEntry = entry.getParent();
-
-        // create the delete command
-        String command = "rm " + entry.getFullEscapedPath(); //$NON-NLS-1$
-
-        try {
-            mCurrentDevice.executeShellCommand(command, new IShellOutputReceiver() {
-                public void addOutput(byte[] data, int offset, int length) {
-                    // pass
-                    // TODO get output to display errors if any.
-                }
-
-                public void flush() {
-                    mTreeViewer.refresh(parentEntry);
-                }
-
-                public boolean isCancelled() {
-                    return false;
-                }
-            });
-        } catch (IOException e) {
-            // adb failed somehow, we do nothing. We should be displaying the error from the output
-            // of the shell command.
-        }
-
-    }
-
-    /**
-     * Force a full refresh of the explorer.
-     */
-    public void refresh() {
-        mTreeViewer.refresh(true);
-    }
-
-    /**
-     * Sets the new device to explorer
-     */
-    public void switchDevice(final Device device) {
-        if (device != mCurrentDevice) {
-            mCurrentDevice = device;
-            // now we change the input. but we need to do that in the
-            // ui thread.
-            if (mTree.isDisposed() == false) {
-                Display d = mTree.getDisplay();
-                d.asyncExec(new Runnable() {
-                    public void run() {
-                        if (mTree.isDisposed() == false) {
-                            // new service
-                            if (mCurrentDevice != null) {
-                                FileListingService fls = mCurrentDevice.getFileListingService();
-                                mContentProvider.setListingService(fls);
-                                mTreeViewer.setInput(fls.getRoot());
-                            }
-                        }
-                    }
-                });
-            }
-        }
-    }
-
-    /**
-     * Refresh an entry from a non ui thread.
-     * @param entry the entry to refresh.
-     */
-    private void refresh(final FileEntry entry) {
-        Display d = mTreeViewer.getTree().getDisplay();
-        d.asyncExec(new Runnable() {
-            public void run() {
-                mTreeViewer.refresh(entry);
-            }
-        });
-    }
-
-    /**
-     * Pulls the selection from a device.
-     * @param items the tree selection the remote file on the device
-     * @param localDirector the local directory in which to save the files.
-     */
-    private void pullSelection(TreeItem[] items, final String localDirectory) {
-        final SyncService sync = mCurrentDevice.getSyncService();
-        if (sync != null) {
-            // make a list of the FileEntry.
-            ArrayList<FileEntry> entries = new ArrayList<FileEntry>();
-            for (TreeItem item : items) {
-                Object data = item.getData();
-                if (data instanceof FileEntry) {
-                    entries.add((FileEntry)data);
-                }
-            }
-            final FileEntry[] entryArray = entries.toArray(
-                    new FileEntry[entries.size()]);
-
-            // get a progressdialog
-            try {
-                new ProgressMonitorDialog(mParent.getShell()).run(true, true,
-                        new IRunnableWithProgress() {
-                    public void run(IProgressMonitor monitor)
-                            throws InvocationTargetException,
-                            InterruptedException {
-                        // create a monitor wrapper around the jface monitor
-                        SyncResult result = sync.pull(entryArray, localDirectory,
-                                new SyncProgressMonitor(monitor,
-                                        "Pulling file(s) from the device"));
-
-                        if (result.getCode() != SyncService.RESULT_OK) {
-                            DdmConsole.printErrorToConsole(String.format(
-                                    "Failed to pull selection: %1$s", result.getMessage()));
-                        }
-                        sync.close();
-                    }
-                });
-            } catch (InvocationTargetException e) {
-                DdmConsole.printErrorToConsole( "Failed to pull selection");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            } catch (InterruptedException e) {
-                DdmConsole.printErrorToConsole("Failed to pull selection");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            }
-        }
-    }
-
-    /**
-     * Pulls a file from a device.
-     * @param remote the remote file on the device
-     * @param local the destination filepath
-     */
-    private void pullFile(final FileEntry remote, final String local) {
-        final SyncService sync = mCurrentDevice.getSyncService();
-        if (sync != null) {
-            try {
-                new ProgressMonitorDialog(mParent.getShell()).run(true, true,
-                        new IRunnableWithProgress() {
-                    public void run(IProgressMonitor monitor)
-                            throws InvocationTargetException,
-                            InterruptedException {
-                        SyncResult result = sync.pullFile(remote, local, new SyncProgressMonitor(
-                                monitor, String.format("Pulling %1$s from the device",
-                                        remote.getName())));
-                        if (result.getCode() != SyncService.RESULT_OK) {
-                            DdmConsole.printErrorToConsole(String.format(
-                                    "Failed to pull %1$s: %2$s", remote, result.getMessage()));
-                        }
-
-                        sync.close();
-                    }
-                });
-            } catch (InvocationTargetException e) {
-                DdmConsole.printErrorToConsole( "Failed to pull selection");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            } catch (InterruptedException e) {
-                DdmConsole.printErrorToConsole("Failed to pull selection");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            }
-        }
-    }
-
-    /**
-     * Pushes several files and directory into a remote directory.
-     * @param localFiles
-     * @param remoteDirectory
-     */
-    private void pushFiles(final String[] localFiles, final FileEntry remoteDirectory) {
-        final SyncService sync = mCurrentDevice.getSyncService();
-        if (sync != null) {
-            try {
-                new ProgressMonitorDialog(mParent.getShell()).run(true, true,
-                        new IRunnableWithProgress() {
-                    public void run(IProgressMonitor monitor)
-                            throws InvocationTargetException,
-                            InterruptedException {
-                        SyncResult result = sync.push(localFiles, remoteDirectory,
-                                    new SyncProgressMonitor(monitor,
-                                            "Pushing file(s) to the device"));
-                        if (result.getCode() != SyncService.RESULT_OK) {
-                            DdmConsole.printErrorToConsole(String.format(
-                                    "Failed to push the items: %1$s", result.getMessage()));
-                        }
-
-                        sync.close();
-                    }
-                });
-            } catch (InvocationTargetException e) {
-                DdmConsole.printErrorToConsole("Failed to push the items");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            } catch (InterruptedException e) {
-                DdmConsole.printErrorToConsole("Failed to push the items");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            }
-            return;
-        }
-    }
-
-    /**
-     * Pushes a file on a device.
-     * @param local the local filepath of the file to push
-     * @param remoteDirectory the remote destination directory on the device
-     */
-    private void pushFile(final String local, final String remoteDirectory) {
-        final SyncService sync = mCurrentDevice.getSyncService();
-        if (sync != null) {
-            try {
-                new ProgressMonitorDialog(mParent.getShell()).run(true, true,
-                        new IRunnableWithProgress() {
-                    public void run(IProgressMonitor monitor)
-                            throws InvocationTargetException,
-                            InterruptedException {
-                        // get the file name
-                        String[] segs = local.split(Pattern.quote(File.separator));
-                        String name = segs[segs.length-1];
-                        String remoteFile = remoteDirectory + FileListingService.FILE_SEPARATOR
-                                + name;
-
-                        SyncResult result = sync.pushFile(local, remoteFile,
-                                    new SyncProgressMonitor(monitor,
-                                            String.format("Pushing %1$s to the device.", name)));
-                        if (result.getCode() != SyncService.RESULT_OK) {
-                            DdmConsole.printErrorToConsole(String.format(
-                                    "Failed to push %1$s on %2$s: %3$s",
-                                    name, mCurrentDevice.getSerialNumber(), result.getMessage()));
-                        }
-
-                        sync.close();
-                    }
-                });
-            } catch (InvocationTargetException e) {
-                DdmConsole.printErrorToConsole("Failed to push the item(s).");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            } catch (InterruptedException e) {
-                DdmConsole.printErrorToConsole("Failed to push the item(s).");
-                DdmConsole.printErrorToConsole(e.getMessage());
-            }
-            return;
-        }
-    }
-
-    /**
-     * Sets the enabled state based on a FileEntry properties
-     * @param element The selected FileEntry
-     */
-    protected void setDeleteEnabledState(FileEntry element) {
-        mDeleteAction.setEnabled(element.getType() == FileListingService.TYPE_FILE);
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/FileLabelProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/FileLabelProvider.java
deleted file mode 100644
index 1dca962..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/explorer/FileLabelProvider.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.explorer;
-
-import com.android.ddmlib.FileListingService;
-import com.android.ddmlib.FileListingService.FileEntry;
-
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * Label provider for the FileEntry.
- */
-class FileLabelProvider implements ILabelProvider, ITableLabelProvider {
-
-    private Image mFileImage;
-    private Image mFolderImage;
-    private Image mPackageImage;
-    private Image mOtherImage;
-
-    /**
-     * Creates Label provider with custom images.
-     * @param fileImage the Image to represent a file
-     * @param folderImage the Image to represent a folder
-     * @param packageImage the Image to represent a .apk file. If null,
-     *      fileImage is used instead.
-     * @param otherImage the Image to represent all other entry type.
-     */
-    public FileLabelProvider(Image fileImage, Image folderImage,
-            Image packageImage, Image otherImage) {
-        mFileImage = fileImage;
-        mFolderImage = folderImage;
-        mOtherImage = otherImage;
-        if (packageImage != null) {
-            mPackageImage = packageImage;
-        } else {
-            mPackageImage = fileImage;
-        }
-    }
-
-    /**
-     * Creates a label provider with default images.
-     *
-     */
-    public FileLabelProvider() {
-
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.ILabelProvider#getImage(java.lang.Object)
-     */
-    public Image getImage(Object element) {
-        return null;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.ILabelProvider#getText(java.lang.Object)
-     */
-    public String getText(Object element) {
-        return null;
-    }
-
-    public Image getColumnImage(Object element, int columnIndex) {
-        if (columnIndex == 0) {
-            if (element instanceof FileEntry) {
-                FileEntry entry = (FileEntry)element;
-                switch (entry.getType()) {
-                    case FileListingService.TYPE_FILE:
-                    case FileListingService.TYPE_LINK:
-                        // get the name and extension
-                        if (entry.isApplicationPackage()) {
-                            return mPackageImage;
-                        }
-                        return mFileImage;
-                    case FileListingService.TYPE_DIRECTORY:
-                    case FileListingService.TYPE_DIRECTORY_LINK:
-                        return mFolderImage;
-                }
-            }
-
-            // default case return a different image.
-            return mOtherImage;
-        }
-        return null;
-    }
-
-    public String getColumnText(Object element, int columnIndex) {
-        if (element instanceof FileEntry) {
-            FileEntry entry = (FileEntry)element;
-
-            switch (columnIndex) {
-                case 0:
-                    return entry.getName();
-                case 1:
-                    return entry.getSize();
-                case 2:
-                    return entry.getDate();
-                case 3:
-                    return entry.getTime();
-                case 4:
-                    return entry.getPermissions();
-                case 5:
-                    return entry.getInfo();
-            }
-        }
-        return null;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
-     */
-    public void addListener(ILabelProviderListener listener) {
-        // we don't need listeners.
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
-     */
-    public void dispose() {
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
-     */
-    public boolean isLabelProperty(Object element, String property) {
-        return false;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
-     */
-    public void removeListener(ILabelProviderListener listener) {
-        // we don't need listeners
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/CoordinateControls.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/CoordinateControls.java
deleted file mode 100644
index 578a7ac..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/CoordinateControls.java
+++ /dev/null
@@ -1,243 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Encapsulation of controls handling a location coordinate in decimal and sexagesimal.
- * <p/>This handle the conversion between both modes automatically by using a {@link ModifyListener}
- * on all the {@link Text} widgets.
- * <p/>To get/set the coordinate, use {@link #setValue(double)} and {@link #getValue()} (preceded by
- * a call to {@link #isValueValid()})
- */
-public final class CoordinateControls {
-    private double mValue;
-    private boolean mValueValidity = false;
-    private Text mDecimalText;
-    private Text mSexagesimalDegreeText;
-    private Text mSexagesimalMinuteText;
-    private Text mSexagesimalSecondText;
-    
-    /** Internal flag to prevent {@link ModifyEvent} to be sent when {@link Text#setText(String)}
-     * is called. This is an int instead of a boolean to act as a counter. */
-    private int mManualTextChange = 0;
-    
-    /**
-     * ModifyListener for the 3 {@link Text} controls of the sexagesimal mode.
-     */
-    private ModifyListener mSexagesimalListener = new ModifyListener() {
-        public void modifyText(ModifyEvent event) {
-            if (mManualTextChange > 0) {
-                return;
-            }
-            try {
-                mValue = getValueFromSexagesimalControls();
-                setValueIntoDecimalControl(mValue);
-                mValueValidity = true;
-            } catch (NumberFormatException e) {
-                // wrong format empty the decimal controls.
-                mValueValidity = false;
-                resetDecimalControls();
-            }
-        }
-    };
-    
-    /**
-     * Creates the {@link Text} control for the decimal display of the coordinate.
-     * <p/>The control is expected to be placed in a Composite using a {@link GridLayout}.
-     * @param parent The {@link Composite} parent of the control.
-     */
-    public void createDecimalText(Composite parent) {
-        mDecimalText = createTextControl(parent, "-199.999999", new ModifyListener() {
-            public void modifyText(ModifyEvent event) {
-                if (mManualTextChange > 0) {
-                    return;
-                }
-                try {
-                    mValue = Double.parseDouble(mDecimalText.getText());
-                    setValueIntoSexagesimalControl(mValue);
-                    mValueValidity = true;
-                } catch (NumberFormatException e) {
-                    // wrong format empty the sexagesimal controls.
-                    mValueValidity = false;
-                    resetSexagesimalControls();
-                }
-            }
-        });
-    }
-    
-    /**
-     * Creates the {@link Text} control for the "degree" display of the coordinate in sexagesimal
-     * mode.
-     * <p/>The control is expected to be placed in a Composite using a {@link GridLayout}.
-     * @param parent The {@link Composite} parent of the control.
-     */
-    public void createSexagesimalDegreeText(Composite parent) {
-        mSexagesimalDegreeText = createTextControl(parent, "-199", mSexagesimalListener); //$NON-NLS-1$
-    }
-    
-    /**
-     * Creates the {@link Text} control for the "minute" display of the coordinate in sexagesimal
-     * mode.
-     * <p/>The control is expected to be placed in a Composite using a {@link GridLayout}.
-     * @param parent The {@link Composite} parent of the control.
-     */
-    public void createSexagesimalMinuteText(Composite parent) {
-        mSexagesimalMinuteText = createTextControl(parent, "99", mSexagesimalListener); //$NON-NLS-1$
-    }
-
-    /**
-     * Creates the {@link Text} control for the "second" display of the coordinate in sexagesimal
-     * mode.
-     * <p/>The control is expected to be placed in a Composite using a {@link GridLayout}.
-     * @param parent The {@link Composite} parent of the control.
-     */
-    public void createSexagesimalSecondText(Composite parent) {
-        mSexagesimalSecondText = createTextControl(parent, "99.999", mSexagesimalListener); //$NON-NLS-1$
-    }
-    
-    /**
-     * Sets the coordinate into the {@link Text} controls.
-     * @param value the coordinate value to set.
-     */
-    public void setValue(double value) {
-        mValue = value;
-        mValueValidity = true;
-        setValueIntoDecimalControl(value);
-        setValueIntoSexagesimalControl(value);
-    }
-    
-    /**
-     * Returns whether the value in the control(s) is valid.
-     */
-    public boolean isValueValid() {
-        return mValueValidity;
-    }
-
-    /**
-     * Returns the current value set in the control(s).
-     * <p/>This value can be erroneous, and a check with {@link #isValueValid()} should be performed
-     * before any call to this method.
-     */
-    public double getValue() {
-        return mValue;
-    }
-    
-    /**
-     * Enables or disables all the {@link Text} controls.
-     * @param enabled the enabled state.
-     */
-    public void setEnabled(boolean enabled) {
-        mDecimalText.setEnabled(enabled);
-        mSexagesimalDegreeText.setEnabled(enabled);
-        mSexagesimalMinuteText.setEnabled(enabled);
-        mSexagesimalSecondText.setEnabled(enabled);
-    }
-    
-    private void resetDecimalControls() {
-        mManualTextChange++;
-        mDecimalText.setText(""); //$NON-NLS-1$
-        mManualTextChange--;
-    }
-
-    private void resetSexagesimalControls() {
-        mManualTextChange++;
-        mSexagesimalDegreeText.setText(""); //$NON-NLS-1$
-        mSexagesimalMinuteText.setText(""); //$NON-NLS-1$
-        mSexagesimalSecondText.setText(""); //$NON-NLS-1$
-        mManualTextChange--;
-    }
-    
-    /**
-     * Creates a {@link Text} with a given parent, default string and a {@link ModifyListener}
-     * @param parent the parent {@link Composite}.
-     * @param defaultString the default string to be used to compute the {@link Text} control
-     * size hint.
-     * @param listener the {@link ModifyListener} to be called when the {@link Text} control is
-     * modified.
-     */
-    private Text createTextControl(Composite parent, String defaultString,
-            ModifyListener listener) {
-        // create the control
-        Text text = new Text(parent, SWT.BORDER | SWT.LEFT | SWT.SINGLE);
-        
-        // add the standard listener to it.
-        text.addModifyListener(listener);
-        
-        // compute its size/
-        mManualTextChange++;
-        text.setText(defaultString);
-        text.pack();
-        Point size = text.computeSize(SWT.DEFAULT, SWT.DEFAULT);
-        text.setText(""); //$NON-NLS-1$
-        mManualTextChange--;
-        
-        GridData gridData = new GridData();
-        gridData.widthHint = size.x;
-        text.setLayoutData(gridData);
-        
-        return text;
-    }
-    
-    private double getValueFromSexagesimalControls() throws NumberFormatException {
-        double degrees = Double.parseDouble(mSexagesimalDegreeText.getText());
-        double minutes = Double.parseDouble(mSexagesimalMinuteText.getText());
-        double seconds = Double.parseDouble(mSexagesimalSecondText.getText());
-        
-        boolean isPositive = (degrees >= 0.);
-        degrees = Math.abs(degrees);
-
-        double value = degrees + minutes / 60. + seconds / 3600.; 
-        return isPositive ? value : - value;
-    }
-
-    private void setValueIntoDecimalControl(double value) {
-        mManualTextChange++;
-        mDecimalText.setText(String.format("%.6f", value));
-        mManualTextChange--;
-    }
-    
-    private void setValueIntoSexagesimalControl(double value) {
-        // get the sign and make the number positive no matter what.
-        boolean isPositive = (value >= 0.);
-        value = Math.abs(value);
-        
-        // get the degree
-        double degrees = Math.floor(value);
-        
-        // get the minutes
-        double minutes = Math.floor((value - degrees) * 60.);
-        
-        // get the seconds.
-        double seconds = (value - degrees) * 3600. - minutes * 60.;
-        
-        mManualTextChange++;
-        mSexagesimalDegreeText.setText(
-                Integer.toString(isPositive ? (int)degrees : (int)- degrees));
-        mSexagesimalMinuteText.setText(Integer.toString((int)minutes));
-        mSexagesimalSecondText.setText(String.format("%.3f", seconds)); //$NON-NLS-1$
-        mManualTextChange--;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/GpxParser.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/GpxParser.java
deleted file mode 100644
index a30337a..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/GpxParser.java
+++ /dev/null
@@ -1,373 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-import org.xml.sax.helpers.DefaultHandler;
-
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.List;
-import java.util.TimeZone;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * A very basic GPX parser to meet the need of the emulator control panel.
- * <p/>
- * It parses basic waypoint information, and tracks (merging segments).
- */
-public class GpxParser {
-    
-    private final static String NS_GPX = "http://www.topografix.com/GPX/1/1";  //$NON-NLS-1$
-        
-    private final static String NODE_WAYPOINT = "wpt"; //$NON-NLS-1$
-    private final static String NODE_TRACK = "trk"; //$NON-NLS-1$
-    private final static String NODE_TRACK_SEGMENT = "trkseg"; //$NON-NLS-1$
-    private final static String NODE_TRACK_POINT = "trkpt"; //$NON-NLS-1$
-    private final static String NODE_NAME = "name"; //$NON-NLS-1$
-    private final static String NODE_TIME = "time"; //$NON-NLS-1$
-    private final static String NODE_ELEVATION = "ele"; //$NON-NLS-1$
-    private final static String NODE_DESCRIPTION = "desc"; //$NON-NLS-1$
-    private final static String ATTR_LONGITUDE = "lon"; //$NON-NLS-1$
-    private final static String ATTR_LATITUDE = "lat"; //$NON-NLS-1$
-    
-    private static SAXParserFactory sParserFactory;
-    
-    static {
-        sParserFactory = SAXParserFactory.newInstance();
-        sParserFactory.setNamespaceAware(true);
-    }
-
-    private String mFileName;
-
-    private GpxHandler mHandler;
-    
-    /** Pattern to parse time with optional sub-second precision, and optional
-     * Z indicating the time is in UTC. */
-    private final static Pattern ISO8601_TIME =
-        Pattern.compile("(\\d{4})-(\\d\\d)-(\\d\\d)T(\\d\\d):(\\d\\d):(\\d\\d)(?:(\\.\\d+))?(Z)?"); //$NON-NLS-1$
-    
-    /**
-     * Handler for the SAX parser.
-     */
-    private static class GpxHandler extends DefaultHandler {
-        // --------- parsed data --------- 
-        List<WayPoint> mWayPoints;
-        List<Track> mTrackList;
-        
-        // --------- state for parsing --------- 
-        Track mCurrentTrack;
-        TrackPoint mCurrentTrackPoint;
-        WayPoint mCurrentWayPoint;
-        final StringBuilder mStringAccumulator = new StringBuilder();
-        
-        boolean mSuccess = true;
-
-        @Override
-        public void startElement(String uri, String localName, String name, Attributes attributes)
-                throws SAXException {
-            // we only care about the standard GPX nodes.
-            try {
-                if (NS_GPX.equals(uri)) {
-                    if (NODE_WAYPOINT.equals(localName)) {
-                        if (mWayPoints == null) {
-                            mWayPoints = new ArrayList<WayPoint>();
-                        }
-                        
-                        mWayPoints.add(mCurrentWayPoint = new WayPoint());
-                        handleLocation(mCurrentWayPoint, attributes);
-                    } else if (NODE_TRACK.equals(localName)) {
-                        if (mTrackList == null) {
-                            mTrackList = new ArrayList<Track>();
-                        }
-                        
-                        mTrackList.add(mCurrentTrack = new Track());
-                    } else if (NODE_TRACK_SEGMENT.equals(localName)) {
-                        // for now we do nothing here. This will merge all the segments into
-                        // a single TrackPoint list in the Track.
-                    } else if (NODE_TRACK_POINT.equals(localName)) {
-                        if (mCurrentTrack != null) {
-                            mCurrentTrack.addPoint(mCurrentTrackPoint = new TrackPoint());
-                            handleLocation(mCurrentTrackPoint, attributes);
-                        }
-                    }
-                }
-            } finally {
-                // no matter the node, we empty the StringBuilder accumulator when we start
-                // a new node.
-                mStringAccumulator.setLength(0);
-            }
-        }
-
-        /**
-         * Processes new characters for the node content. The characters are simply stored,
-         * and will be processed when {@link #endElement(String, String, String)} is called.
-         */
-        @Override
-        public void characters(char[] ch, int start, int length) throws SAXException {
-            mStringAccumulator.append(ch, start, length);
-        }
-        
-        @Override
-        public void endElement(String uri, String localName, String name) throws SAXException {
-            if (NS_GPX.equals(uri)) {
-                if (NODE_WAYPOINT.equals(localName)) {
-                    mCurrentWayPoint = null;
-                } else if (NODE_TRACK.equals(localName)) {
-                    mCurrentTrack = null;
-                } else if (NODE_TRACK_POINT.equals(localName)) {
-                    mCurrentTrackPoint = null;
-                } else if (NODE_NAME.equals(localName)) {
-                    if (mCurrentTrack != null) {
-                        mCurrentTrack.setName(mStringAccumulator.toString());
-                    } else if (mCurrentWayPoint != null) {
-                        mCurrentWayPoint.setName(mStringAccumulator.toString());
-                    }
-                } else if (NODE_TIME.equals(localName)) {
-                    if (mCurrentTrackPoint != null) {
-                        mCurrentTrackPoint.setTime(computeTime(mStringAccumulator.toString()));
-                    }
-                } else if (NODE_ELEVATION.equals(localName)) {
-                    if (mCurrentTrackPoint != null) {
-                        mCurrentTrackPoint.setElevation(
-                                Double.parseDouble(mStringAccumulator.toString()));
-                    } else if (mCurrentWayPoint != null) {
-                        mCurrentWayPoint.setElevation(
-                                Double.parseDouble(mStringAccumulator.toString()));
-                    }
-                } else if (NODE_DESCRIPTION.equals(localName)) {
-                    if (mCurrentWayPoint != null) {
-                        mCurrentWayPoint.setDescription(mStringAccumulator.toString());
-                    }
-                }
-            }
-        }
-
-        @Override
-        public void error(SAXParseException e) throws SAXException {
-            mSuccess = false;
-        }
-
-        @Override
-        public void fatalError(SAXParseException e) throws SAXException {
-            mSuccess = false;
-        }
-        
-        /**
-         * Converts the string description of the time into milliseconds since epoch.
-         * @param timeString the string data.
-         * @return date in milliseconds.
-         */
-        private long computeTime(String timeString) {
-            // Time looks like: 2008-04-05T19:24:50Z
-            Matcher m = ISO8601_TIME.matcher(timeString);
-            if (m.matches()) {
-                // get the various elements and reconstruct time as a long.
-                try {
-                    int year = Integer.parseInt(m.group(1));
-                    int month = Integer.parseInt(m.group(2));
-                    int date = Integer.parseInt(m.group(3));
-                    int hourOfDay = Integer.parseInt(m.group(4));
-                    int minute = Integer.parseInt(m.group(5));
-                    int second = Integer.parseInt(m.group(6));
-                    
-                    // handle the optional parameters.
-                    int milliseconds = 0;
-
-                    String subSecondGroup = m.group(7);
-                    if (subSecondGroup != null) {
-                        milliseconds = (int)(1000 * Double.parseDouble(subSecondGroup));
-                    }
-                    
-                    boolean utcTime = m.group(8) != null;
-
-                    // now we convert into milliseconds since epoch.
-                    Calendar c;
-                    if (utcTime) {
-                        c = Calendar.getInstance(TimeZone.getTimeZone("GMT")); //$NON-NLS-1$
-                    } else {
-                        c = Calendar.getInstance();
-                    }
-                    
-                    c.set(year, month, date, hourOfDay, minute, second);
-                    
-                    return c.getTimeInMillis() + milliseconds;
-                } catch (NumberFormatException e) {
-                    // format is invalid, we'll return -1 below.
-                }
-                
-            }
-
-            // invalid time!
-            return -1;
-        }
-        
-        /**
-         * Handles the location attributes and store them into a {@link LocationPoint}.
-         * @param locationNode the {@link LocationPoint} to receive the location data.
-         * @param attributes the attributes from the XML node.
-         */
-        private void handleLocation(LocationPoint locationNode, Attributes attributes) {
-            try {
-                double longitude = Double.parseDouble(attributes.getValue(ATTR_LONGITUDE));
-                double latitude = Double.parseDouble(attributes.getValue(ATTR_LATITUDE));
-                
-                locationNode.setLocation(longitude, latitude);
-            } catch (NumberFormatException e) {
-                // wrong data, do nothing.
-            }
-        }
-
-        WayPoint[] getWayPoints() {
-            if (mWayPoints != null) {
-                return mWayPoints.toArray(new WayPoint[mWayPoints.size()]);
-            }
-
-            return null;
-        }
-
-        Track[] getTracks() {
-            if (mTrackList != null) {
-                return mTrackList.toArray(new Track[mTrackList.size()]);
-            }
-
-            return null;
-        }
-        
-        boolean getSuccess() {
-            return mSuccess;
-        }
-    }
-
-    /**
-     * A GPS track.
-     * <p/>A track is composed of a list of {@link TrackPoint} and optional name and comment.
-     */
-    public final static class Track {
-        private String mName;
-        private String mComment;
-        private List<TrackPoint> mPoints = new ArrayList<TrackPoint>();
-
-        void setName(String name) {
-            mName = name;
-        }
-        
-        public String getName() {
-            return mName;
-        }
-        
-        void setComment(String comment) {
-            mComment = comment;
-        }
-        
-        public String getComment() {
-            return mComment;
-        }
-        
-        void addPoint(TrackPoint trackPoint) {
-            mPoints.add(trackPoint);
-        }
-        
-        public TrackPoint[] getPoints() {
-            return mPoints.toArray(new TrackPoint[mPoints.size()]);
-        }
-        
-        public long getFirstPointTime() {
-            if (mPoints.size() > 0) {
-                return mPoints.get(0).getTime();
-            }
-            
-            return -1;
-        }
-
-        public long getLastPointTime() {
-            if (mPoints.size() > 0) {
-                return mPoints.get(mPoints.size()-1).getTime();
-            }
-            
-            return -1;
-        }
-        
-        public int getPointCount() {
-            return mPoints.size();
-        }
-    }
-    
-    /**
-     * Creates a new GPX parser for a file specified by its full path.
-     * @param fileName The full path of the GPX file to parse.
-     */
-    public GpxParser(String fileName) {
-        mFileName = fileName;
-    }
-
-    /**
-     * Parses the GPX file.
-     * @return <code>true</code> if success.
-     */
-    public boolean parse() {
-        try {
-            SAXParser parser = sParserFactory.newSAXParser();
-
-            mHandler = new GpxHandler();
-
-            parser.parse(new InputSource(new FileReader(mFileName)), mHandler);
-            
-            return mHandler.getSuccess();
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (IOException e) {
-        } finally {
-        }
-
-        return false;
-    }
-    
-    /**
-     * Returns the parsed {@link WayPoint} objects, or <code>null</code> if none were found (or
-     * if the parsing failed.
-     */
-    public WayPoint[] getWayPoints() {
-        if (mHandler != null) {
-            return mHandler.getWayPoints();
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the parsed {@link Track} objects, or <code>null</code> if none were found (or
-     * if the parsing failed.
-     */
-    public Track[] getTracks() {
-        if (mHandler != null) {
-            return mHandler.getTracks();
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/KmlParser.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/KmlParser.java
deleted file mode 100644
index af485ac..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/KmlParser.java
+++ /dev/null
@@ -1,210 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-import org.xml.sax.helpers.DefaultHandler;
-
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * A very basic KML parser to meet the need of the emulator control panel.
- * <p/>
- * It parses basic Placemark information.
- */
-public class KmlParser {
-    
-    private final static String NS_KML_2 = "http://earth.google.com/kml/2.";  //$NON-NLS-1$
-        
-    private final static String NODE_PLACEMARK = "Placemark"; //$NON-NLS-1$
-    private final static String NODE_NAME = "name"; //$NON-NLS-1$
-    private final static String NODE_COORDINATES = "coordinates"; //$NON-NLS-1$
-    
-    private final static Pattern sLocationPattern = Pattern.compile("([^,]+),([^,]+)(?:,([^,]+))?");
-    
-    private static SAXParserFactory sParserFactory;
-    
-    static {
-        sParserFactory = SAXParserFactory.newInstance();
-        sParserFactory.setNamespaceAware(true);
-    }
-
-    private String mFileName;
-
-    private KmlHandler mHandler;
-    
-    /**
-     * Handler for the SAX parser.
-     */
-    private static class KmlHandler extends DefaultHandler {
-        // --------- parsed data --------- 
-        List<WayPoint> mWayPoints;
-        
-        // --------- state for parsing --------- 
-        WayPoint mCurrentWayPoint;
-        final StringBuilder mStringAccumulator = new StringBuilder();
-
-        boolean mSuccess = true;
-
-        @Override
-        public void startElement(String uri, String localName, String name, Attributes attributes)
-                throws SAXException {
-            // we only care about the standard GPX nodes.
-            try {
-                if (uri.startsWith(NS_KML_2)) {
-                    if (NODE_PLACEMARK.equals(localName)) {
-                        if (mWayPoints == null) {
-                            mWayPoints = new ArrayList<WayPoint>();
-                        }
-                        
-                        mWayPoints.add(mCurrentWayPoint = new WayPoint());
-                    }
-                }
-            } finally {
-                // no matter the node, we empty the StringBuilder accumulator when we start
-                // a new node.
-                mStringAccumulator.setLength(0);
-            }
-        }
-
-        /**
-         * Processes new characters for the node content. The characters are simply stored,
-         * and will be processed when {@link #endElement(String, String, String)} is called.
-         */
-        @Override
-        public void characters(char[] ch, int start, int length) throws SAXException {
-            mStringAccumulator.append(ch, start, length);
-        }
-        
-        @Override
-        public void endElement(String uri, String localName, String name) throws SAXException {
-            if (uri.startsWith(NS_KML_2)) {
-                if (NODE_PLACEMARK.equals(localName)) {
-                    mCurrentWayPoint = null;
-                } else if (NODE_NAME.equals(localName)) {
-                    if (mCurrentWayPoint != null) {
-                        mCurrentWayPoint.setName(mStringAccumulator.toString());
-                    }
-                } else if (NODE_COORDINATES.equals(localName)) {
-                    if (mCurrentWayPoint != null) {
-                        parseLocation(mCurrentWayPoint, mStringAccumulator.toString());
-                    }
-                }
-            }
-        }
-
-        @Override
-        public void error(SAXParseException e) throws SAXException {
-            mSuccess = false;
-        }
-
-        @Override
-        public void fatalError(SAXParseException e) throws SAXException {
-            mSuccess = false;
-        }
-        
-        /**
-         * Parses the location string and store the information into a {@link LocationPoint}.
-         * @param locationNode the {@link LocationPoint} to receive the location data.
-         * @param location The string containing the location info.
-         */
-        private void parseLocation(LocationPoint locationNode, String location) {
-            Matcher m = sLocationPattern.matcher(location);
-            if (m.matches()) {
-                try {
-                    double longitude = Double.parseDouble(m.group(1));
-                    double latitude = Double.parseDouble(m.group(2));
-                    
-                    locationNode.setLocation(longitude, latitude);
-                    
-                    if (m.groupCount() == 3) {
-                        // looks like we have elevation data.
-                        locationNode.setElevation(Double.parseDouble(m.group(3)));
-                    }
-                } catch (NumberFormatException e) {
-                    // wrong data, do nothing.
-                }
-            }
-        }
-        
-        WayPoint[] getWayPoints() {
-            if (mWayPoints != null) {
-                return mWayPoints.toArray(new WayPoint[mWayPoints.size()]);
-            }
-
-            return null;
-        }
-
-        boolean getSuccess() {
-            return mSuccess;
-        }
-    }
-
-    /**
-     * Creates a new GPX parser for a file specified by its full path.
-     * @param fileName The full path of the GPX file to parse.
-     */
-    public KmlParser(String fileName) {
-        mFileName = fileName;
-    }
-
-    /**
-     * Parses the GPX file.
-     * @return <code>true</code> if success.
-     */
-    public boolean parse() {
-        try {
-            SAXParser parser = sParserFactory.newSAXParser();
-
-            mHandler = new KmlHandler();
-
-            parser.parse(new InputSource(new FileReader(mFileName)), mHandler);
-            
-            return mHandler.getSuccess();
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (IOException e) {
-        } finally {
-        }
-
-        return false;
-    }
-    
-    /**
-     * Returns the parsed {@link WayPoint} objects, or <code>null</code> if none were found (or
-     * if the parsing failed.
-     */
-    public WayPoint[] getWayPoints() {
-        if (mHandler != null) {
-            return mHandler.getWayPoints();
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/LocationPoint.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/LocationPoint.java
deleted file mode 100644
index dbb8f41..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/LocationPoint.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-/**
- * Base class for Location aware points.
- */
-class LocationPoint {
-    private double mLongitude;
-    private double mLatitude;
-    private boolean mHasElevation = false;
-    private double mElevation;
-
-    final void setLocation(double longitude, double latitude) {
-        mLongitude = longitude;
-        mLatitude = latitude;
-    }
-    
-    public final double getLongitude() {
-        return mLongitude;
-    }
-    
-    public final double getLatitude() {
-        return mLatitude;
-    }
-
-    final void setElevation(double elevation) {
-        mElevation = elevation;
-        mHasElevation = true;
-    }
-    
-    public final boolean hasElevation() {
-        return mHasElevation;
-    }
-    
-    public final double getElevation() {
-        return mElevation;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackContentProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackContentProvider.java
deleted file mode 100644
index 7fb37ce..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackContentProvider.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import com.android.ddmuilib.location.GpxParser.Track;
-
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-
-/**
- * Content provider to display {@link Track} objects in a Table.
- * <p/>The expected type for the input is {@link Track}<code>[]</code>. 
- */
-public class TrackContentProvider implements IStructuredContentProvider {
-
-    public Object[] getElements(Object inputElement) {
-        if (inputElement instanceof Track[]) {
-            return (Track[])inputElement;
-        }
-
-        return new Object[0];
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        // pass
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackLabelProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackLabelProvider.java
deleted file mode 100644
index 81d1f7d..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackLabelProvider.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import com.android.ddmuilib.location.GpxParser.Track;
-
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Table;
-
-import java.util.Date;
-
-/**
- * Label Provider for {@link Table} objects displaying {@link Track} objects.
- */
-public class TrackLabelProvider implements ITableLabelProvider {
-
-    public Image getColumnImage(Object element, int columnIndex) {
-        return null;
-    }
-
-    public String getColumnText(Object element, int columnIndex) {
-        if (element instanceof Track) {
-            Track track = (Track)element;
-            switch (columnIndex) {
-                case 0:
-                    return track.getName();
-                case 1:
-                    return Integer.toString(track.getPointCount());
-                case 2:
-                    long time = track.getFirstPointTime();
-                    if (time != -1) {
-                        return new Date(time).toString();
-                    }
-                    break;
-                case 3:
-                    time = track.getLastPointTime();
-                    if (time != -1) {
-                        return new Date(time).toString();
-                    }
-                    break;
-                case 4:
-                    return track.getComment();
-            }
-        }
-
-        return null;
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // pass
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        // pass
-        return false;
-    }
-
-    public void removeListener(ILabelProviderListener listener) {
-        // pass
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackPoint.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackPoint.java
deleted file mode 100644
index 527f4bf..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/TrackPoint.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-
-/**
- * A Track Point.
- * <p/>A track point is a point in time and space.
- */
-public class TrackPoint extends LocationPoint {
-    private long mTime;
-
-    void setTime(long time) {
-        mTime = time;
-    }
-    
-    public long getTime() {
-        return mTime;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPoint.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPoint.java
deleted file mode 100644
index 32880bd..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPoint.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-/**
- * A GPS/KML way point.
- * <p/>A waypoint is a user specified location, with a name and an optional description.
- */
-public final class WayPoint extends LocationPoint {
-    private String mName;
-    private String mDescription;
-
-    void setName(String name) {
-        mName = name;
-    }
-    
-    public String getName() {
-        return mName;
-    }
-
-    void setDescription(String description) {
-        mDescription = description;
-    }
-
-    public String getDescription() {
-        return mDescription;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointContentProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointContentProvider.java
deleted file mode 100644
index fced777..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointContentProvider.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-
-/**
- * Content provider to display {@link WayPoint} objects in a Table.
- * <p/>The expected type for the input is {@link WayPoint}<code>[]</code>. 
- */
-public class WayPointContentProvider implements IStructuredContentProvider {
-
-    public Object[] getElements(Object inputElement) {
-        if (inputElement instanceof WayPoint[]) {
-            return (WayPoint[])inputElement;
-        }
-
-        return new Object[0];
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        // pass
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointLabelProvider.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointLabelProvider.java
deleted file mode 100644
index f5e6f1b..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/location/WayPointLabelProvider.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.location;
-
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Table;
-
-/**
- * Label Provider for {@link Table} objects displaying {@link WayPoint} objects.
- */
-public class WayPointLabelProvider implements ITableLabelProvider {
-
-    public Image getColumnImage(Object element, int columnIndex) {
-        return null;
-    }
-
-    public String getColumnText(Object element, int columnIndex) {
-        if (element instanceof WayPoint) {
-            WayPoint wayPoint = (WayPoint)element;
-            switch (columnIndex) {
-                case 0:
-                    return wayPoint.getName();
-                case 1:
-                    return String.format("%.6f", wayPoint.getLongitude());
-                case 2:
-                    return String.format("%.6f", wayPoint.getLatitude());
-                case 3:
-                    if (wayPoint.hasElevation()) {
-                        return String.format("%.1f", wayPoint.getElevation());
-                    } else {
-                        return "-";
-                    }
-                case 4:
-                    return wayPoint.getDescription();
-            }
-        }
-
-        return null;
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // pass
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        // pass
-        return false;
-    }
-
-    public void removeListener(ILabelProviderListener listener) {
-        // pass
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/BugReportImporter.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/BugReportImporter.java
deleted file mode 100644
index 9de1ac7..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/BugReportImporter.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import java.io.BufferedReader;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-
-public class BugReportImporter {
-    
-    private final static String TAG_HEADER = "------ EVENT LOG TAGS ------";
-    private final static String LOG_HEADER = "------ EVENT LOG ------";
-    private final static String HEADER_TAG = "------";
-    
-    private String[] mTags;
-    private String[] mLog;
-    
-    public BugReportImporter(String filePath) throws FileNotFoundException {
-        BufferedReader reader = new BufferedReader(
-                new InputStreamReader(new FileInputStream(filePath)));
-
-        try {
-            String line;
-            while ((line = reader.readLine()) != null) {
-                if (TAG_HEADER.equals(line)) {
-                    readTags(reader);
-                    return;
-                }
-            }
-        } catch (IOException e) {
-        }
-    }
-    
-    public String[] getTags() {
-        return mTags;
-    }
-    
-    public String[] getLog() {
-        return mLog;
-    }
-
-    private void readTags(BufferedReader reader) throws IOException {
-        String line;
-        
-        ArrayList<String> content = new ArrayList<String>();
-        while ((line = reader.readLine()) != null) {
-            if (LOG_HEADER.equals(line)) {
-                mTags = content.toArray(new String[content.size()]);
-                readLog(reader);
-                return;
-            } else {
-                content.add(line);
-            }
-        }
-    }
-
-    private void readLog(BufferedReader reader) throws IOException {
-        String line;
-
-        ArrayList<String> content = new ArrayList<String>();
-        while ((line = reader.readLine()) != null) {
-            if (line.startsWith(HEADER_TAG) == false) {
-                content.add(line);
-            } else {
-                break;
-            }
-        }
-        
-        mLog = content.toArray(new String[content.size()]);
-    }
-    
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayFilteredLog.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayFilteredLog.java
deleted file mode 100644
index 473387a..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayFilteredLog.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-
-import java.util.ArrayList;
-
-public class DisplayFilteredLog extends DisplayLog {
-
-    public DisplayFilteredLog(String name) {
-        super(name);
-    }
-
-    /**
-     * Adds event to the display.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        ArrayList<ValueDisplayDescriptor> valueDescriptors =
-                new ArrayList<ValueDisplayDescriptor>();
-
-        ArrayList<OccurrenceDisplayDescriptor> occurrenceDescriptors =
-                new ArrayList<OccurrenceDisplayDescriptor>();
-
-        if (filterEvent(event, valueDescriptors, occurrenceDescriptors)) {
-            addToLog(event, logParser, valueDescriptors, occurrenceDescriptors);
-        }
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_FILTERED_LOG;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayGraph.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayGraph.java
deleted file mode 100644
index 0cffd7e..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayGraph.java
+++ /dev/null
@@ -1,422 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.EventValueDescription;
-import com.android.ddmlib.log.InvalidTypeException;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.jfree.chart.axis.AxisLocation;
-import org.jfree.chart.axis.NumberAxis;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.renderer.xy.AbstractXYItemRenderer;
-import org.jfree.chart.renderer.xy.XYAreaRenderer;
-import org.jfree.chart.renderer.xy.XYLineAndShapeRenderer;
-import org.jfree.data.time.Millisecond;
-import org.jfree.data.time.TimeSeries;
-import org.jfree.data.time.TimeSeriesCollection;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Map;
-
-public class DisplayGraph extends EventDisplay {
-
-    public DisplayGraph(String name) {
-        super(name);
-    }
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        Collection<TimeSeriesCollection> datasets = mValueTypeDataSetMap.values();
-        for (TimeSeriesCollection dataset : datasets) {
-            dataset.removeAllSeries();
-        }
-        if (mOccurrenceDataSet != null) {
-            mOccurrenceDataSet.removeAllSeries();
-        }
-        mValueDescriptorSeriesMap.clear();
-        mOcurrenceDescriptorSeriesMap.clear();
-    }
-
-    /**
-     * Creates the UI for the event display.
-     * @param parent the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    @Override
-    public Control createComposite(final Composite parent, EventLogParser logParser,
-            final ILogColumnListener listener) {
-        String title = getChartTitle(logParser);
-        return createCompositeChart(parent, logParser, title);
-    }
-
-    /**
-     * Adds event to the display.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        ArrayList<ValueDisplayDescriptor> valueDescriptors =
-                new ArrayList<ValueDisplayDescriptor>();
-
-        ArrayList<OccurrenceDisplayDescriptor> occurrenceDescriptors =
-                new ArrayList<OccurrenceDisplayDescriptor>();
-
-        if (filterEvent(event, valueDescriptors, occurrenceDescriptors)) {
-            updateChart(event, logParser, valueDescriptors, occurrenceDescriptors);
-        }
-    }
-
-     /**
-     * Updates the chart with the {@link EventContainer} by adding the values/occurrences defined
-     * by the {@link ValueDisplayDescriptor} and {@link OccurrenceDisplayDescriptor} objects from
-     * the two lists.
-     * <p/>This method is only called when at least one of the descriptor list is non empty.
-     * @param event
-     * @param logParser
-     * @param valueDescriptors
-     * @param occurrenceDescriptors
-     */
-    private void updateChart(EventContainer event, EventLogParser logParser,
-            ArrayList<ValueDisplayDescriptor> valueDescriptors,
-            ArrayList<OccurrenceDisplayDescriptor> occurrenceDescriptors) {
-        Map<Integer, String> tagMap = logParser.getTagMap();
-
-        Millisecond millisecondTime = null;
-        long msec = -1;
-
-        // If the event container is a cpu container (tag == 2721), and there is no descriptor
-        // for the total CPU load, then we do accumulate all the values.
-        boolean accumulateValues = false;
-        double accumulatedValue = 0;
-
-        if (event.mTag == 2721) {
-            accumulateValues = true;
-            for (ValueDisplayDescriptor descriptor : valueDescriptors) {
-                accumulateValues &= (descriptor.valueIndex != 0);
-            }
-        }
-
-        for (ValueDisplayDescriptor descriptor : valueDescriptors) {
-            try {
-                // get the hashmap for this descriptor
-                HashMap<Integer, TimeSeries> map = mValueDescriptorSeriesMap.get(descriptor);
-
-                // if it's not there yet, we create it.
-                if (map == null) {
-                    map = new HashMap<Integer, TimeSeries>();
-                    mValueDescriptorSeriesMap.put(descriptor, map);
-                }
-
-                // get the TimeSeries for this pid
-                TimeSeries timeSeries = map.get(event.pid);
-
-                // if it doesn't exist yet, we create it
-                if (timeSeries == null) {
-                    // get the series name
-                    String seriesFullName = null;
-                    String seriesLabel = getSeriesLabel(event, descriptor);
-
-                    switch (mValueDescriptorCheck) {
-                        case EVENT_CHECK_SAME_TAG:
-                            seriesFullName = String.format("%1$s / %2$s", seriesLabel,
-                                    descriptor.valueName);
-                            break;
-                        case EVENT_CHECK_SAME_VALUE:
-                            seriesFullName = String.format("%1$s", seriesLabel);
-                            break;
-                        default:
-                            seriesFullName = String.format("%1$s / %2$s: %3$s", seriesLabel,
-                                    tagMap.get(descriptor.eventTag),
-                                    descriptor.valueName);
-                            break;
-                    }
-
-                    // get the data set for this ValueType
-                    TimeSeriesCollection dataset = getValueDataset(
-                            logParser.getEventInfoMap().get(event.mTag)[descriptor.valueIndex]
-                                                                        .getValueType(),
-                            accumulateValues);
-
-                    // create the series
-                    timeSeries = new TimeSeries(seriesFullName, Millisecond.class);
-                    if (mMaximumChartItemAge != -1) {
-                        timeSeries.setMaximumItemAge(mMaximumChartItemAge * 1000);
-                    }
-
-                    dataset.addSeries(timeSeries);
-
-                    // add it to the map.
-                    map.put(event.pid, timeSeries);
-                }
-
-                // update the timeSeries.
-
-                // get the value from the event
-                double value = event.getValueAsDouble(descriptor.valueIndex);
-
-                // accumulate the values if needed.
-                if (accumulateValues) {
-                    accumulatedValue += value;
-                    value = accumulatedValue;
-                }
-
-                // get the time
-                if (millisecondTime == null) {
-                    msec = (long)event.sec * 1000L + (event.nsec / 1000000L);
-                    millisecondTime = new Millisecond(new Date(msec));
-                }
-
-                // add the value to the time series
-                timeSeries.addOrUpdate(millisecondTime, value);
-            } catch (InvalidTypeException e) {
-                // just ignore this descriptor if there's a type mismatch
-            }
-        }
-
-        for (OccurrenceDisplayDescriptor descriptor : occurrenceDescriptors) {
-            try {
-                // get the hashmap for this descriptor
-                HashMap<Integer, TimeSeries> map = mOcurrenceDescriptorSeriesMap.get(descriptor);
-
-                // if it's not there yet, we create it.
-                if (map == null) {
-                    map = new HashMap<Integer, TimeSeries>();
-                    mOcurrenceDescriptorSeriesMap.put(descriptor, map);
-                }
-
-                // get the TimeSeries for this pid
-                TimeSeries timeSeries = map.get(event.pid);
-
-                // if it doesn't exist yet, we create it.
-                if (timeSeries == null) {
-                    String seriesLabel = getSeriesLabel(event, descriptor);
-
-                    String seriesFullName = String.format("[%1$s:%2$s]",
-                            tagMap.get(descriptor.eventTag), seriesLabel);
-
-                    timeSeries = new TimeSeries(seriesFullName, Millisecond.class);
-                    if (mMaximumChartItemAge != -1) {
-                        timeSeries.setMaximumItemAge(mMaximumChartItemAge);
-                    }
-
-                    getOccurrenceDataSet().addSeries(timeSeries);
-
-                    map.put(event.pid, timeSeries);
-                }
-
-                // update the series
-
-                // get the time
-                if (millisecondTime == null) {
-                    msec = (long)event.sec * 1000L + (event.nsec / 1000000L);
-                    millisecondTime = new Millisecond(new Date(msec));
-                }
-
-                // add the value to the time series
-                timeSeries.addOrUpdate(millisecondTime, 0); // the value is unused
-            } catch (InvalidTypeException e) {
-                // just ignore this descriptor if there's a type mismatch
-            }
-        }
-
-        // go through all the series and remove old values.
-        if (msec != -1 && mMaximumChartItemAge != -1) {
-            Collection<HashMap<Integer, TimeSeries>> pidMapValues =
-                mValueDescriptorSeriesMap.values();
-
-            for (HashMap<Integer, TimeSeries> pidMapValue : pidMapValues) {
-                Collection<TimeSeries> seriesCollection = pidMapValue.values();
-
-                for (TimeSeries timeSeries : seriesCollection) {
-                    timeSeries.removeAgedItems(msec, true);
-                }
-            }
-
-            pidMapValues = mOcurrenceDescriptorSeriesMap.values();
-            for (HashMap<Integer, TimeSeries> pidMapValue : pidMapValues) {
-                Collection<TimeSeries> seriesCollection = pidMapValue.values();
-
-                for (TimeSeries timeSeries : seriesCollection) {
-                    timeSeries.removeAgedItems(msec, true);
-                }
-            }
-        }
-    }
-
-       /**
-     * Returns a {@link TimeSeriesCollection} for a specific {@link com.android.ddmlib.log.EventValueDescription.ValueType}.
-     * If the data set is not yet created, it is first allocated and set up into the
-     * {@link org.jfree.chart.JFreeChart} object.
-     * @param type the {@link com.android.ddmlib.log.EventValueDescription.ValueType} of the data set.
-     * @param accumulateValues
-     */
-    private TimeSeriesCollection getValueDataset(EventValueDescription.ValueType type, boolean accumulateValues) {
-        TimeSeriesCollection dataset = mValueTypeDataSetMap.get(type);
-        if (dataset == null) {
-            // create the data set and store it in the map
-            dataset = new TimeSeriesCollection();
-            mValueTypeDataSetMap.put(type, dataset);
-
-            // create the renderer and configure it depending on the ValueType
-            AbstractXYItemRenderer renderer;
-            if (type == EventValueDescription.ValueType.PERCENT && accumulateValues) {
-                renderer = new XYAreaRenderer();
-            } else {
-                XYLineAndShapeRenderer r = new XYLineAndShapeRenderer();
-                r.setBaseShapesVisible(type != EventValueDescription.ValueType.PERCENT);
-
-                renderer = r;
-            }
-
-            // set both the dataset and the renderer in the plot object.
-            XYPlot xyPlot = mChart.getXYPlot();
-            xyPlot.setDataset(mDataSetCount, dataset);
-            xyPlot.setRenderer(mDataSetCount, renderer);
-
-            // put a new axis label, and configure it.
-            NumberAxis axis = new NumberAxis(type.toString());
-
-            if (type == EventValueDescription.ValueType.PERCENT) {
-                // force percent range to be (0,100) fixed.
-                axis.setAutoRange(false);
-                axis.setRange(0., 100.);
-            }
-
-            // for the index, we ignore the occurrence dataset
-            int count = mDataSetCount;
-            if (mOccurrenceDataSet != null) {
-                count--;
-            }
-
-            xyPlot.setRangeAxis(count, axis);
-            if ((count % 2) == 0) {
-                xyPlot.setRangeAxisLocation(count, AxisLocation.BOTTOM_OR_LEFT);
-            } else {
-                xyPlot.setRangeAxisLocation(count, AxisLocation.TOP_OR_RIGHT);
-            }
-
-            // now we link the dataset and the axis
-            xyPlot.mapDatasetToRangeAxis(mDataSetCount, count);
-
-            mDataSetCount++;
-        }
-
-        return dataset;
-    }
-
-    /**
-     * Return the series label for this event. This only contains the pid information.
-     * @param event the {@link EventContainer}
-     * @param descriptor the {@link OccurrenceDisplayDescriptor}
-     * @return the series label.
-     * @throws InvalidTypeException
-     */
-    private String getSeriesLabel(EventContainer event, OccurrenceDisplayDescriptor descriptor)
-            throws InvalidTypeException {
-        if (descriptor.seriesValueIndex != -1) {
-            if (descriptor.includePid == false) {
-                return event.getValueAsString(descriptor.seriesValueIndex);
-            } else {
-                return String.format("%1$s (%2$d)",
-                        event.getValueAsString(descriptor.seriesValueIndex), event.pid);
-            }
-        }
-
-        return Integer.toString(event.pid);
-    }
-
-    /**
-     * Returns the {@link TimeSeriesCollection} for the occurrence display. If the data set is not
-     * yet created, it is first allocated and set up into the {@link org.jfree.chart.JFreeChart} object.
-     */
-    private TimeSeriesCollection getOccurrenceDataSet() {
-        if (mOccurrenceDataSet == null) {
-            mOccurrenceDataSet = new TimeSeriesCollection();
-
-            XYPlot xyPlot = mChart.getXYPlot();
-            xyPlot.setDataset(mDataSetCount, mOccurrenceDataSet);
-
-            OccurrenceRenderer renderer = new OccurrenceRenderer();
-            renderer.setBaseShapesVisible(false);
-            xyPlot.setRenderer(mDataSetCount, renderer);
-
-            mDataSetCount++;
-        }
-
-        return mOccurrenceDataSet;
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_GRAPH;
-    }
-
-    /**
-     * Sets the current {@link EventLogParser} object.
-     */
-    @Override
-    protected void setNewLogParser(EventLogParser logParser) {
-        if (mChart != null) {
-            mChart.setTitle(getChartTitle(logParser));
-        }
-    }
-    /**
-     * Returns a meaningful chart title based on the value of {@link #mValueDescriptorCheck}.
-     *
-     * @param logParser the logParser.
-     * @return the chart title.
-     */
-    private String getChartTitle(EventLogParser logParser) {
-        if (mValueDescriptors.size() > 0) {
-            String chartDesc = null;
-            switch (mValueDescriptorCheck) {
-                case EVENT_CHECK_SAME_TAG:
-                    if (logParser != null) {
-                        chartDesc = logParser.getTagMap().get(mValueDescriptors.get(0).eventTag);
-                    }
-                    break;
-                case EVENT_CHECK_SAME_VALUE:
-                    if (logParser != null) {
-                        chartDesc = String.format("%1$s / %2$s",
-                                logParser.getTagMap().get(mValueDescriptors.get(0).eventTag),
-                                mValueDescriptors.get(0).valueName);
-                    }
-                    break;
-            }
-
-            if (chartDesc != null) {
-                return String.format("%1$s - %2$s", mName, chartDesc);
-            }
-        }
-
-        return mName;
-    }
-}
\ No newline at end of file
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayLog.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayLog.java
deleted file mode 100644
index 26296f3..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplayLog.java
+++ /dev/null
@@ -1,379 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.EventValueDescription;
-import com.android.ddmlib.log.InvalidTypeException;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.TableHelper;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.ScrollBar;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.ArrayList;
-import java.util.Calendar;
-
-public class DisplayLog extends EventDisplay {
-    public DisplayLog(String name) {
-        super(name);
-    }
-
-    private final static String PREFS_COL_DATE = "EventLogPanel.log.Col1"; //$NON-NLS-1$
-    private final static String PREFS_COL_PID = "EventLogPanel.log.Col2"; //$NON-NLS-1$
-    private final static String PREFS_COL_EVENTTAG = "EventLogPanel.log.Col3"; //$NON-NLS-1$
-    private final static String PREFS_COL_VALUENAME = "EventLogPanel.log.Col4"; //$NON-NLS-1$
-    private final static String PREFS_COL_VALUE = "EventLogPanel.log.Col5"; //$NON-NLS-1$
-    private final static String PREFS_COL_TYPE = "EventLogPanel.log.Col6"; //$NON-NLS-1$
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        mLogTable.removeAll();
-    }
-
-    /**
-     * Adds event to the display.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        addToLog(event, logParser);
-    }
-
-    /**
-     * Creates the UI for the event display.
-     *
-     * @param parent    the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    @Override
-    Control createComposite(Composite parent, EventLogParser logParser, ILogColumnListener listener) {
-        return createLogUI(parent, listener);
-    }
-
-    /**
-     * Adds an {@link EventContainer} to the log.
-     *
-     * @param event     the event.
-     * @param logParser the log parser.
-     */
-    private void addToLog(EventContainer event, EventLogParser logParser) {
-        ScrollBar bar = mLogTable.getVerticalBar();
-        boolean scroll = bar.getMaximum() == bar.getSelection() + bar.getThumb();
-
-        // get the date.
-        Calendar c = Calendar.getInstance();
-        long msec = (long) event.sec * 1000L;
-        c.setTimeInMillis(msec);
-
-        // convert the time into a string
-        String date = String.format("%1$tF %1$tT", c);
-
-        String eventName = logParser.getTagMap().get(event.mTag);
-        String pidName = Integer.toString(event.pid);
-
-        // get the value description
-        EventValueDescription[] valueDescription = logParser.getEventInfoMap().get(event.mTag);
-        if (valueDescription != null) {
-            for (int i = 0; i < valueDescription.length; i++) {
-                EventValueDescription description = valueDescription[i];
-                try {
-                    String value = event.getValueAsString(i);
-
-                    logValue(date, pidName, eventName, description.getName(), value,
-                            description.getEventValueType(), description.getValueType());
-                } catch (InvalidTypeException e) {
-                    logValue(date, pidName, eventName, description.getName(), e.getMessage(),
-                            description.getEventValueType(), description.getValueType());
-                }
-            }
-
-            // scroll if needed, by showing the last item
-            if (scroll) {
-                int itemCount = mLogTable.getItemCount();
-                if (itemCount > 0) {
-                    mLogTable.showItem(mLogTable.getItem(itemCount - 1));
-                }
-            }
-        }
-    }
-
-    /**
-     * Adds an {@link EventContainer} to the log. Only add the values/occurrences defined by
-     * the list of descriptors. If an event is configured to be displayed by value and occurrence,
-     * only the values are displayed (as they mark an event occurrence anyway).
-     * <p/>This method is only called when at least one of the descriptor list is non empty.
-     *
-     * @param event
-     * @param logParser
-     * @param valueDescriptors
-     * @param occurrenceDescriptors
-     */
-    protected void addToLog(EventContainer event, EventLogParser logParser,
-            ArrayList<ValueDisplayDescriptor> valueDescriptors,
-            ArrayList<OccurrenceDisplayDescriptor> occurrenceDescriptors) {
-        ScrollBar bar = mLogTable.getVerticalBar();
-        boolean scroll = bar.getMaximum() == bar.getSelection() + bar.getThumb();
-
-        // get the date.
-        Calendar c = Calendar.getInstance();
-        long msec = (long) event.sec * 1000L;
-        c.setTimeInMillis(msec);
-
-        // convert the time into a string
-        String date = String.format("%1$tF %1$tT", c);
-
-        String eventName = logParser.getTagMap().get(event.mTag);
-        String pidName = Integer.toString(event.pid);
-
-        if (valueDescriptors.size() > 0) {
-            for (ValueDisplayDescriptor descriptor : valueDescriptors) {
-                logDescriptor(event, descriptor, date, pidName, eventName, logParser);
-            }
-        } else {
-            // we display the event. Since the StringBuilder contains the header (date, event name,
-            // pid) at this point, there isn't anything else to display.
-        }
-
-        // scroll if needed, by showing the last item
-        if (scroll) {
-            int itemCount = mLogTable.getItemCount();
-            if (itemCount > 0) {
-                mLogTable.showItem(mLogTable.getItem(itemCount - 1));
-            }
-        }
-    }
-
-
-    /**
-     * Logs a value in the ui.
-     *
-     * @param date
-     * @param pid
-     * @param event
-     * @param valueName
-     * @param value
-     * @param eventValueType
-     * @param valueType
-     */
-    private void logValue(String date, String pid, String event, String valueName,
-            String value, EventContainer.EventValueType eventValueType, EventValueDescription.ValueType valueType) {
-
-        TableItem item = new TableItem(mLogTable, SWT.NONE);
-        item.setText(0, date);
-        item.setText(1, pid);
-        item.setText(2, event);
-        item.setText(3, valueName);
-        item.setText(4, value);
-
-        String type;
-        if (valueType != EventValueDescription.ValueType.NOT_APPLICABLE) {
-            type = String.format("%1$s, %2$s", eventValueType.toString(), valueType.toString());
-        } else {
-            type = eventValueType.toString();
-        }
-
-        item.setText(5, type);
-    }
-
-    /**
-     * Logs a value from an {@link EventContainer} as defined by the {@link ValueDisplayDescriptor}.
-     *
-     * @param event      the EventContainer
-     * @param descriptor the ValueDisplayDescriptor defining which value to display.
-     * @param date       the date of the event in a string.
-     * @param pidName
-     * @param eventName
-     * @param logParser
-     */
-    private void logDescriptor(EventContainer event, ValueDisplayDescriptor descriptor,
-            String date, String pidName, String eventName, EventLogParser logParser) {
-
-        String value;
-        try {
-            value = event.getValueAsString(descriptor.valueIndex);
-        } catch (InvalidTypeException e) {
-            value = e.getMessage();
-        }
-
-        EventValueDescription[] values = logParser.getEventInfoMap().get(event.mTag);
-
-        EventValueDescription valueDescription = values[descriptor.valueIndex];
-
-        logValue(date, pidName, eventName, descriptor.valueName, value,
-                valueDescription.getEventValueType(), valueDescription.getValueType());
-    }
-
-    /**
-     * Creates the UI for a log display.
-     *
-     * @param parent   the parent {@link Composite}
-     * @param listener the {@link ILogColumnListener} to notify on column resize events.
-     * @return the top Composite of the UI.
-     */
-    private Control createLogUI(Composite parent, final ILogColumnListener listener) {
-        Composite mainComp = new Composite(parent, SWT.NONE);
-        GridLayout gl;
-        mainComp.setLayout(gl = new GridLayout(1, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        mainComp.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                mLogTable = null;
-            }
-        });
-
-        Label l = new Label(mainComp, SWT.CENTER);
-        l.setText(mName);
-        l.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mLogTable = new Table(mainComp, SWT.MULTI | SWT.FULL_SELECTION | SWT.V_SCROLL |
-                SWT.BORDER);
-        mLogTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        IPreferenceStore store = DdmUiPreferences.getStore();
-
-        TableColumn col = TableHelper.createTableColumn(
-                mLogTable, "Time",
-                SWT.LEFT, "0000-00-00 00:00:00", PREFS_COL_DATE, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(0, (TableColumn) source);
-                }
-            }
-        });
-
-        col = TableHelper.createTableColumn(
-                mLogTable, "pid",
-                SWT.LEFT, "0000", PREFS_COL_PID, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(1, (TableColumn) source);
-                }
-            }
-        });
-
-        col = TableHelper.createTableColumn(
-                mLogTable, "Event",
-                SWT.LEFT, "abcdejghijklmno", PREFS_COL_EVENTTAG, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(2, (TableColumn) source);
-                }
-            }
-        });
-
-        col = TableHelper.createTableColumn(
-                mLogTable, "Name",
-                SWT.LEFT, "Process Name", PREFS_COL_VALUENAME, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(3, (TableColumn) source);
-                }
-            }
-        });
-
-        col = TableHelper.createTableColumn(
-                mLogTable, "Value",
-                SWT.LEFT, "0000000", PREFS_COL_VALUE, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(4, (TableColumn) source);
-                }
-            }
-        });
-
-        col = TableHelper.createTableColumn(
-                mLogTable, "Type",
-                SWT.LEFT, "long, seconds", PREFS_COL_TYPE, store); //$NON-NLS-1$
-        col.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Object source = e.getSource();
-                if (source instanceof TableColumn) {
-                    listener.columnResized(5, (TableColumn) source);
-                }
-            }
-        });
-
-        mLogTable.setHeaderVisible(true);
-        mLogTable.setLinesVisible(true);
-
-        return mainComp;
-    }
-
-    /**
-     * Resizes the <code>index</code>-th column of the log {@link Table} (if applicable).
-     * <p/>
-     * This does nothing if the <code>Table</code> object is <code>null</code> (because the display
-     * type does not use a column) or if the <code>index</code>-th column is in fact the originating
-     * column passed as argument.
-     *
-     * @param index        the index of the column to resize
-     * @param sourceColumn the original column that was resize, and on which we need to sync the
-     *                     index-th column width.
-     */
-    @Override
-    void resizeColumn(int index, TableColumn sourceColumn) {
-        if (mLogTable != null) {
-            TableColumn col = mLogTable.getColumn(index);
-            if (col != sourceColumn) {
-                col.setWidth(sourceColumn.getWidth());
-            }
-        }
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_LOG_ALL;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySync.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySync.java
deleted file mode 100644
index 82cc7a4..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySync.java
+++ /dev/null
@@ -1,293 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.InvalidTypeException;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.jfree.chart.labels.CustomXYToolTipGenerator;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.renderer.xy.XYBarRenderer;
-import org.jfree.chart.renderer.xy.XYLineAndShapeRenderer;
-import org.jfree.data.time.FixedMillisecond;
-import org.jfree.data.time.SimpleTimePeriod;
-import org.jfree.data.time.TimePeriodValues;
-import org.jfree.data.time.TimePeriodValuesCollection;
-import org.jfree.data.time.TimeSeries;
-import org.jfree.data.time.TimeSeriesCollection;
-import org.jfree.util.ShapeUtilities;
-
-import java.awt.Color;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Scanner;
-import java.util.regex.Pattern;
-
-public class DisplaySync extends SyncCommon {
-
-    // Information to graph for each authority
-    private TimePeriodValues mDatasetsSync[];
-    private List<String> mTooltipsSync[];
-    private CustomXYToolTipGenerator mTooltipGenerators[];
-    private TimeSeries mDatasetsSyncTickle[];
-
-    // Dataset of error events to graph
-    private TimeSeries mDatasetError;
-
-    public DisplaySync(String name) {
-        super(name);
-    }
-
-    /**
-     * Creates the UI for the event display.
-     * @param parent the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    @Override
-    public Control createComposite(final Composite parent, EventLogParser logParser,
-            final ILogColumnListener listener) {
-        Control composite = createCompositeChart(parent, logParser, "Sync Status");
-        resetUI();
-        return composite;
-    }
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        super.resetUI();
-        XYPlot xyPlot = mChart.getXYPlot();
-
-        XYBarRenderer br = new XYBarRenderer();
-        mDatasetsSync = new TimePeriodValues[NUM_AUTHS];
-        mTooltipsSync = new List[NUM_AUTHS];
-        mTooltipGenerators = new CustomXYToolTipGenerator[NUM_AUTHS];
-
-        TimePeriodValuesCollection tpvc = new TimePeriodValuesCollection();
-        xyPlot.setDataset(tpvc);
-        xyPlot.setRenderer(0, br);
-
-        XYLineAndShapeRenderer ls = new XYLineAndShapeRenderer();
-        ls.setBaseLinesVisible(false);
-        mDatasetsSyncTickle = new TimeSeries[NUM_AUTHS];
-        TimeSeriesCollection tsc = new TimeSeriesCollection();
-        xyPlot.setDataset(1, tsc);
-        xyPlot.setRenderer(1, ls);
-
-        mDatasetError = new TimeSeries("Errors", FixedMillisecond.class);
-        xyPlot.setDataset(2, new TimeSeriesCollection(mDatasetError));
-        XYLineAndShapeRenderer errls = new XYLineAndShapeRenderer();
-        errls.setBaseLinesVisible(false);
-        errls.setSeriesPaint(0, Color.RED);
-        xyPlot.setRenderer(2, errls);
-
-        for (int i = 0; i < NUM_AUTHS; i++) {
-            br.setSeriesPaint(i, AUTH_COLORS[i]);
-            ls.setSeriesPaint(i, AUTH_COLORS[i]);
-            mDatasetsSync[i] = new TimePeriodValues(AUTH_NAMES[i]);
-            tpvc.addSeries(mDatasetsSync[i]);
-            mTooltipsSync[i] = new ArrayList<String>();
-            mTooltipGenerators[i] = new CustomXYToolTipGenerator();
-            br.setSeriesToolTipGenerator(i, mTooltipGenerators[i]);
-            mTooltipGenerators[i].addToolTipSeries(mTooltipsSync[i]);
-
-            mDatasetsSyncTickle[i] = new TimeSeries(AUTH_NAMES[i] + " tickle",
-                    FixedMillisecond.class);
-            tsc.addSeries(mDatasetsSyncTickle[i]);
-            ls.setSeriesShape(i, ShapeUtilities.createUpTriangle(2.5f));
-        }
-    }
-
-    /**
-     * Updates the display with a new event.
-     *
-     * @param event     The event
-     * @param logParser The parser providing the event.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        super.newEvent(event, logParser); // Handle sync operation
-        try {
-            if (event.mTag == EVENT_TICKLE) {
-                int auth = getAuth(event.getValueAsString(0));
-                if (auth >= 0) {
-                    long msec = (long)event.sec * 1000L + (event.nsec / 1000000L);
-                    mDatasetsSyncTickle[auth].addOrUpdate(new FixedMillisecond(msec), -1);
-                }
-            }
-        } catch (InvalidTypeException e) {
-        }
-    }
-
-    /**
-     * Generate the height for an event.
-     * Height is somewhat arbitrarily the count of "things" that happened
-     * during the sync.
-     * When network traffic measurements are available, code should be modified
-     * to use that instead.
-     * @param details The details string associated with the event
-     * @return The height in arbirary units (0-100)
-     */
-    private int getHeightFromDetails(String details) {
-        if (details == null) {
-            return 1; // Arbitrary
-        }
-        int total = 0;
-        String parts[] = details.split("[a-zA-Z]");
-        for (String part : parts) {
-            if ("".equals(part)) continue;
-            total += Integer.parseInt(part);
-        }
-        if (total == 0) {
-            total = 1;
-        }
-        return total;
-    }
-
-    /**
-     * Generates the tooltips text for an event.
-     * This method decodes the cryptic details string.
-     * @param auth The authority associated with the event
-     * @param details The details string
-     * @param eventSource server, poll, etc.
-     * @return The text to display in the tooltips
-     */
-    private String getTextFromDetails(int auth, String details, int eventSource) {
-
-        StringBuffer sb = new StringBuffer();
-        sb.append(AUTH_NAMES[auth]).append(": \n");
-
-        Scanner scanner = new Scanner(details);
-        Pattern charPat = Pattern.compile("[a-zA-Z]");
-        Pattern numPat = Pattern.compile("[0-9]+");
-        while (scanner.hasNext()) {
-            String key = scanner.findInLine(charPat);
-            int val = Integer.parseInt(scanner.findInLine(numPat));
-            if (auth == GMAIL && "M".equals(key)) {
-                sb.append("messages from server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "L".equals(key)) {
-                sb.append("labels from server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "C".equals(key)) {
-                sb.append("check conversation requests from server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "A".equals(key)) {
-                sb.append("attachments from server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "U".equals(key)) {
-                sb.append("op updates from server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "u".equals(key)) {
-                sb.append("op updates to server: ").append(val).append("\n");
-            } else if (auth == GMAIL && "S".equals(key)) {
-                sb.append("send/receive cycles: ").append(val).append("\n");
-            } else if ("Q".equals(key)) {
-                sb.append("queries to server: ").append(val).append("\n");
-            } else if ("E".equals(key)) {
-                sb.append("entries from server: ").append(val).append("\n");
-            } else if ("u".equals(key)) {
-                sb.append("updates from client: ").append(val).append("\n");
-            } else if ("i".equals(key)) {
-                sb.append("inserts from client: ").append(val).append("\n");
-            } else if ("d".equals(key)) {
-                sb.append("deletes from client: ").append(val).append("\n");
-            } else if ("f".equals(key)) {
-                sb.append("full sync requested\n");
-            } else if ("r".equals(key)) {
-                sb.append("partial sync unavailable\n");
-            } else if ("X".equals(key)) {
-                sb.append("hard error\n");
-            } else if ("e".equals(key)) {
-                sb.append("number of parse exceptions: ").append(val).append("\n");
-            } else if ("c".equals(key)) {
-                sb.append("number of conflicts: ").append(val).append("\n");
-            } else if ("a".equals(key)) {
-                sb.append("number of auth exceptions: ").append(val).append("\n");
-            } else if ("D".equals(key)) {
-                sb.append("too many deletions\n");
-            } else if ("R".equals(key)) {
-                sb.append("too many retries: ").append(val).append("\n");
-            } else if ("b".equals(key)) {
-                sb.append("database error\n");
-            } else if ("x".equals(key)) {
-                sb.append("soft error\n");
-            } else if ("l".equals(key)) {
-                sb.append("sync already in progress\n");
-            } else if ("I".equals(key)) {
-                sb.append("io exception\n");
-            } else if (auth == CONTACTS && "p".equals(key)) {
-                sb.append("photos uploaded from client: ").append(val).append("\n");
-            } else if (auth == CONTACTS && "P".equals(key)) {
-                sb.append("photos downloaded from server: ").append(val).append("\n");
-            } else if (auth == CALENDAR && "F".equals(key)) {
-                sb.append("server refresh\n");
-            } else if (auth == CALENDAR && "s".equals(key)) {
-                sb.append("server diffs fetched\n");
-            } else {
-                sb.append(key).append("=").append(val);
-            }
-        }
-        if (eventSource == 0) {
-            sb.append("(server)");
-        } else if (eventSource == 1) {
-            sb.append("(local)");
-        } else if (eventSource == 2) {
-            sb.append("(poll)");
-        } else if (eventSource == 3) {
-            sb.append("(user)");
-        }
-        return sb.toString();
-    }
-
-
-    /**
-     * Callback to process a sync event.
-     */
-    @Override
-    void processSyncEvent(EventContainer event, int auth, long startTime, long stopTime,
-            String details, boolean newEvent, int syncSource) {
-        if (!newEvent) {
-            // Details arrived for a previous sync event
-            // Remove event before reinserting.
-            int lastItem = mDatasetsSync[auth].getItemCount();
-            mDatasetsSync[auth].delete(lastItem-1, lastItem-1);
-            mTooltipsSync[auth].remove(lastItem-1);
-        }
-        double height = getHeightFromDetails(details);
-        height = height / (stopTime - startTime + 1) * 10000;
-        if (height > 30) {
-            height = 30;
-        }
-        mDatasetsSync[auth].add(new SimpleTimePeriod(startTime, stopTime), height);
-        mTooltipsSync[auth].add(getTextFromDetails(auth, details, syncSource));
-        mTooltipGenerators[auth].addToolTipSeries(mTooltipsSync[auth]);
-        if (details.indexOf('x') >= 0 || details.indexOf('X') >= 0) {
-            long msec = (long)event.sec * 1000L + (event.nsec / 1000000L);
-            mDatasetError.addOrUpdate(new FixedMillisecond(msec), -1);
-        }
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_SYNC;
-    }
-}
\ No newline at end of file
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncHistogram.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncHistogram.java
deleted file mode 100644
index 36d90ce..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncHistogram.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.renderer.xy.AbstractXYItemRenderer;
-import org.jfree.chart.renderer.xy.XYBarRenderer;
-import org.jfree.data.time.RegularTimePeriod;
-import org.jfree.data.time.SimpleTimePeriod;
-import org.jfree.data.time.TimePeriodValues;
-import org.jfree.data.time.TimePeriodValuesCollection;
-
-import java.util.Calendar;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.TimeZone;
-
-public class DisplaySyncHistogram extends SyncCommon {
-
-    Map<SimpleTimePeriod, Integer> mTimePeriodMap[];
-
-    // Information to graph for each authority
-    private TimePeriodValues mDatasetsSyncHist[];
-
-    public DisplaySyncHistogram(String name) {
-        super(name);
-    }
-
-    /**
-     * Creates the UI for the event display.
-     * @param parent the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    @Override
-    public Control createComposite(final Composite parent, EventLogParser logParser,
-            final ILogColumnListener listener) {
-        Control composite = createCompositeChart(parent, logParser, "Sync Histogram");
-        resetUI();
-        return composite;
-    }
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        super.resetUI();
-        XYPlot xyPlot = mChart.getXYPlot();
-
-        AbstractXYItemRenderer br = new XYBarRenderer();
-        mDatasetsSyncHist = new TimePeriodValues[NUM_AUTHS+1];
-        mTimePeriodMap = new HashMap[NUM_AUTHS + 1];
-
-        TimePeriodValuesCollection tpvc = new TimePeriodValuesCollection();
-        xyPlot.setDataset(tpvc);
-        xyPlot.setRenderer(br);
-
-        for (int i = 0; i < NUM_AUTHS + 1; i++) {
-            br.setSeriesPaint(i, AUTH_COLORS[i]);
-            mDatasetsSyncHist[i] = new TimePeriodValues(AUTH_NAMES[i]);
-            tpvc.addSeries(mDatasetsSyncHist[i]);
-            mTimePeriodMap[i] = new HashMap<SimpleTimePeriod, Integer>();
-
-        }
-    }
-
-    /**
-     * Callback to process a sync event.
-     *
-     * @param event      The sync event
-     * @param startTime Start time (ms) of events
-     * @param stopTime Stop time (ms) of events
-     * @param details Details associated with the event.
-     * @param newEvent True if this event is a new sync event.  False if this event
-     * @param syncSource
-     */
-    @Override
-    void processSyncEvent(EventContainer event, int auth, long startTime, long stopTime,
-            String details, boolean newEvent, int syncSource) {
-        if (newEvent) {
-            if (details.indexOf('x') >= 0 || details.indexOf('X') >= 0) {
-                auth = ERRORS;
-            }
-            double delta = (stopTime - startTime) * 100. / 1000 / 3600; // Percent of hour
-            addHistEvent(0, auth, delta);
-        } else {
-            // sync_details arrived for an event that has already been graphed.
-            if (details.indexOf('x') >= 0 || details.indexOf('X') >= 0) {
-                // Item turns out to be in error, so transfer time from old auth to error.
-                double delta = (stopTime - startTime) * 100. / 1000 / 3600; // Percent of hour
-                addHistEvent(0, auth, -delta);
-                addHistEvent(0, ERRORS, delta);
-            }
-        }
-    }
-
-    /**
-     * Helper to add an event to the data series.
-     * Also updates error series if appropriate (x or X in details).
-     * @param stopTime Time event ends
-     * @param auth Sync authority
-     * @param value Value to graph for event
-     */
-    private void addHistEvent(long stopTime, int auth, double value) {
-        SimpleTimePeriod hour = getTimePeriod(stopTime, mHistWidth);
-
-        // Loop over all datasets to do the stacking.
-        for (int i = auth; i <= ERRORS; i++) {
-            addToPeriod(mDatasetsSyncHist, i, hour, value);
-        }
-    }
-
-    private void addToPeriod(TimePeriodValues tpv[], int auth, SimpleTimePeriod period,
-            double value) {
-        int index;
-        if (mTimePeriodMap[auth].containsKey(period)) {
-            index = mTimePeriodMap[auth].get(period);
-            double oldValue = tpv[auth].getValue(index).doubleValue();
-            tpv[auth].update(index, oldValue + value);
-        } else {
-            index = tpv[auth].getItemCount();
-            mTimePeriodMap[auth].put(period, index);
-            tpv[auth].add(period, value);
-        }
-    }
-
-    /**
-     * Creates a multiple-hour time period for the histogram.
-     * @param time Time in milliseconds.
-     * @param numHoursWide: should divide into a day.
-     * @return SimpleTimePeriod covering the number of hours and containing time.
-     */
-    private SimpleTimePeriod getTimePeriod(long time, long numHoursWide) {
-        Date date = new Date(time);
-        TimeZone zone = RegularTimePeriod.DEFAULT_TIME_ZONE;
-        Calendar calendar = Calendar.getInstance(zone);
-        calendar.setTime(date);
-        long hoursOfYear = calendar.get(Calendar.HOUR_OF_DAY) +
-                calendar.get(Calendar.DAY_OF_YEAR) * 24;
-        int year = calendar.get(Calendar.YEAR);
-        hoursOfYear = (hoursOfYear / numHoursWide) * numHoursWide;
-        calendar.clear();
-        calendar.set(year, 0, 1, 0, 0); // Jan 1
-        long start = calendar.getTimeInMillis() + hoursOfYear * 3600 * 1000;
-        return new SimpleTimePeriod(start, start + numHoursWide * 3600 * 1000);
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_SYNC_HIST;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncPerf.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncPerf.java
deleted file mode 100644
index 9ce7045..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/DisplaySyncPerf.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.InvalidTypeException;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.jfree.chart.labels.CustomXYToolTipGenerator;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.renderer.xy.XYBarRenderer;
-import org.jfree.data.time.SimpleTimePeriod;
-import org.jfree.data.time.TimePeriodValues;
-import org.jfree.data.time.TimePeriodValuesCollection;
-
-import java.awt.Color;
-import java.util.ArrayList;
-import java.util.List;
-
-public class DisplaySyncPerf extends SyncCommon {
-
-    CustomXYToolTipGenerator mTooltipGenerator;
-    List mTooltips[];
-
-    // The series number for each graphed item.
-    // sync authorities are 0-3
-    private static final int DB_QUERY = 4;
-    private static final int DB_WRITE = 5;
-    private static final int HTTP_NETWORK = 6;
-    private static final int HTTP_PROCESSING = 7;
-    private static final int NUM_SERIES = (HTTP_PROCESSING + 1);
-    private static final String SERIES_NAMES[] = {"Calendar", "Gmail", "Feeds", "Contacts",
-            "DB Query", "DB Write", "HTTP Response", "HTTP Processing",};
-    private static final Color SERIES_COLORS[] = {Color.MAGENTA, Color.GREEN, Color.BLUE,
-            Color.ORANGE, Color.RED, Color.CYAN, Color.PINK, Color.DARK_GRAY};
-    private static final double SERIES_YCOORD[] = {0, 0, 0, 0, 1, 1, 2, 2};
-
-    // Values from data/etc/event-log-tags
-    private static final int EVENT_DB_OPERATION = 52000;
-    private static final int EVENT_HTTP_STATS = 52001;
-    // op types for EVENT_DB_OPERATION
-    final int EVENT_DB_QUERY = 0;
-    final int EVENT_DB_WRITE = 1;
-
-    // Information to graph for each authority
-    private TimePeriodValues mDatasets[];
-
-    /**
-     * TimePeriodValuesCollection that supports Y intervals.  This allows the
-     * creation of "floating" bars, rather than bars rooted to the axis.
-     */
-    class YIntervalTimePeriodValuesCollection extends TimePeriodValuesCollection {
-        /** default serial UID */
-        private static final long serialVersionUID = 1L;
-
-        private double yheight;
-
-        /**
-         * Constructs a collection of bars with a fixed Y height.
-         *
-         * @param yheight The height of the bars.
-         */
-        YIntervalTimePeriodValuesCollection(double yheight) {
-            this.yheight = yheight;
-        }
-
-        /**
-         * Returns ending Y value that is a fixed amount greater than the starting value.
-         *
-         * @param series the series (zero-based index).
-         * @param item   the item (zero-based index).
-         * @return The ending Y value for the specified series and item.
-         */
-        @Override
-        public Number getEndY(int series, int item) {
-            return getY(series, item).doubleValue() + yheight;
-        }
-    }
-
-    /**
-     * Constructs a graph of network and database stats.
-     *
-     * @param name The name of this graph in the graph list.
-     */
-    public DisplaySyncPerf(String name) {
-        super(name);
-    }
-
-    /**
-     * Creates the UI for the event display.
-     *
-     * @param parent    the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    @Override
-    public Control createComposite(final Composite parent, EventLogParser logParser,
-            final ILogColumnListener listener) {
-        Control composite = createCompositeChart(parent, logParser, "Sync Performance");
-        resetUI();
-        return composite;
-    }
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        super.resetUI();
-        XYPlot xyPlot = mChart.getXYPlot();
-        xyPlot.getRangeAxis().setVisible(false);
-        mTooltipGenerator = new CustomXYToolTipGenerator();
-        mTooltips = new List[NUM_SERIES];
-
-        XYBarRenderer br = new XYBarRenderer();
-        br.setUseYInterval(true);
-        mDatasets = new TimePeriodValues[NUM_SERIES];
-
-        TimePeriodValuesCollection tpvc = new YIntervalTimePeriodValuesCollection(1);
-        xyPlot.setDataset(tpvc);
-        xyPlot.setRenderer(br);
-
-        for (int i = 0; i < NUM_SERIES; i++) {
-            br.setSeriesPaint(i, SERIES_COLORS[i]);
-            mDatasets[i] = new TimePeriodValues(SERIES_NAMES[i]);
-            tpvc.addSeries(mDatasets[i]);
-            mTooltips[i] = new ArrayList<String>();
-            mTooltipGenerator.addToolTipSeries(mTooltips[i]);
-            br.setSeriesToolTipGenerator(i, mTooltipGenerator);
-        }
-    }
-
-    /**
-     * Updates the display with a new event.
-     *
-     * @param event     The event
-     * @param logParser The parser providing the event.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        super.newEvent(event, logParser); // Handle sync operation
-        try {
-            if (event.mTag == EVENT_DB_OPERATION) {
-                // 52000 db_operation (name|3),(op_type|1|5),(time|2|3)
-                String tip = event.getValueAsString(0);
-                long endTime = (long) event.sec * 1000L + (event.nsec / 1000000L);
-                int opType = Integer.parseInt(event.getValueAsString(1));
-                long duration = Long.parseLong(event.getValueAsString(2));
-
-                if (opType == EVENT_DB_QUERY) {
-                    mDatasets[DB_QUERY].add(new SimpleTimePeriod(endTime - duration, endTime),
-                            SERIES_YCOORD[DB_QUERY]);
-                    mTooltips[DB_QUERY].add(tip);
-                } else if (opType == EVENT_DB_WRITE) {
-                    mDatasets[DB_WRITE].add(new SimpleTimePeriod(endTime - duration, endTime),
-                            SERIES_YCOORD[DB_WRITE]);
-                    mTooltips[DB_WRITE].add(tip);
-                }
-            } else if (event.mTag == EVENT_HTTP_STATS) {
-                // 52001 http_stats (useragent|3),(response|2|3),(processing|2|3),(tx|1|2),(rx|1|2)
-                String tip = event.getValueAsString(0) + ", tx:" + event.getValueAsString(3) +
-                        ", rx: " + event.getValueAsString(4);
-                long endTime = (long) event.sec * 1000L + (event.nsec / 1000000L);
-                long netEndTime = endTime - Long.parseLong(event.getValueAsString(2));
-                long netStartTime = netEndTime - Long.parseLong(event.getValueAsString(1));
-                mDatasets[HTTP_NETWORK].add(new SimpleTimePeriod(netStartTime, netEndTime),
-                        SERIES_YCOORD[HTTP_NETWORK]);
-                mDatasets[HTTP_PROCESSING].add(new SimpleTimePeriod(netEndTime, endTime),
-                        SERIES_YCOORD[HTTP_PROCESSING]);
-                mTooltips[HTTP_NETWORK].add(tip);
-                mTooltips[HTTP_PROCESSING].add(tip);
-            }
-        } catch (InvalidTypeException e) {
-        }
-    }
-
-    /**
-     * Callback from super.newEvent to process a sync event.
-     *
-     * @param event      The sync event
-     * @param startTime  Start time (ms) of events
-     * @param stopTime   Stop time (ms) of events
-     * @param details    Details associated with the event.
-     * @param newEvent   True if this event is a new sync event.  False if this event
-     * @param syncSource
-     */
-    @Override
-    void processSyncEvent(EventContainer event, int auth, long startTime, long stopTime,
-            String details, boolean newEvent, int syncSource) {
-        if (newEvent) {
-            mDatasets[auth].add(new SimpleTimePeriod(startTime, stopTime), SERIES_YCOORD[auth]);
-        }
-    }
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    @Override
-    int getDisplayType() {
-        return DISPLAY_TYPE_SYNC_PERF;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplay.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplay.java
deleted file mode 100644
index 2223a4d..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplay.java
+++ /dev/null
@@ -1,971 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.Log;
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventContainer.CompareMethod;
-import com.android.ddmlib.log.EventContainer.EventValueType;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.EventValueDescription.ValueType;
-import com.android.ddmlib.log.InvalidTypeException;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.jfree.chart.ChartFactory;
-import org.jfree.chart.JFreeChart;
-import org.jfree.chart.event.ChartChangeEvent;
-import org.jfree.chart.event.ChartChangeEventType;
-import org.jfree.chart.event.ChartChangeListener;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.title.TextTitle;
-import org.jfree.data.time.Millisecond;
-import org.jfree.data.time.TimeSeries;
-import org.jfree.data.time.TimeSeriesCollection;
-import org.jfree.experimental.chart.swt.ChartComposite;
-import org.jfree.experimental.swt.SWTUtils;
-
-import java.security.InvalidParameterException;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Set;
-import java.util.regex.Pattern;
-
-/**
- * Represents a custom display of one or more events.
- */
-abstract class EventDisplay {
-
-    private final static String DISPLAY_DATA_STORAGE_SEPARATOR = ":"; //$NON-NLS-1$
-    private final static String PID_STORAGE_SEPARATOR = ","; //$NON-NLS-1$
-    private final static String DESCRIPTOR_STORAGE_SEPARATOR = "$"; //$NON-NLS-1$
-    private final static String DESCRIPTOR_DATA_STORAGE_SEPARATOR = "!"; //$NON-NLS-1$
-
-    private final static String FILTER_VALUE_NULL = "<null>"; //$NON-NLS-1$
-
-    public final static int DISPLAY_TYPE_LOG_ALL = 0;
-    public final static int DISPLAY_TYPE_FILTERED_LOG = 1;
-    public final static int DISPLAY_TYPE_GRAPH = 2;
-    public final static int DISPLAY_TYPE_SYNC = 3;
-    public final static int DISPLAY_TYPE_SYNC_HIST = 4;
-    public final static int DISPLAY_TYPE_SYNC_PERF = 5;
-
-    private final static int EVENT_CHECK_FAILED = 0;
-    protected final static int EVENT_CHECK_SAME_TAG = 1;
-    protected final static int EVENT_CHECK_SAME_VALUE = 2;
-
-    /**
-     * Creates the appropriate EventDisplay subclass.
-     *
-     * @param type the type of display (DISPLAY_TYPE_LOG_ALL, etc)
-     * @param name the name of the display
-     * @return the created object
-     */
-    public static EventDisplay eventDisplayFactory(int type, String name) {
-        switch (type) {
-            case DISPLAY_TYPE_LOG_ALL:
-                return new DisplayLog(name);
-            case DISPLAY_TYPE_FILTERED_LOG:
-                return new DisplayFilteredLog(name);
-            case DISPLAY_TYPE_SYNC:
-                return new DisplaySync(name);
-            case DISPLAY_TYPE_SYNC_HIST:
-                return new DisplaySyncHistogram(name);
-            case DISPLAY_TYPE_GRAPH:
-                return new DisplayGraph(name);
-            case DISPLAY_TYPE_SYNC_PERF:
-                return new DisplaySyncPerf(name);
-            default:
-                throw new InvalidParameterException("Unknown Display Type " + type); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Adds event to the display.
-     * @param event The event
-     * @param logParser The log parser.
-     */
-    abstract void newEvent(EventContainer event, EventLogParser logParser);
-
-    /**
-     * Resets the display.
-     */
-    abstract void resetUI();
-
-    /**
-     * Gets display type
-     *
-     * @return display type as an integer
-     */
-    abstract int getDisplayType();
-
-    /**
-     * Creates the UI for the event display.
-     *
-     * @param parent    the parent composite.
-     * @param logParser the current log parser.
-     * @return the created control (which may have children).
-     */
-    abstract Control createComposite(final Composite parent, EventLogParser logParser,
-            final ILogColumnListener listener);
-
-    interface ILogColumnListener {
-        void columnResized(int index, TableColumn sourceColumn);
-    }
-
-    /**
-     * Describes an event to be displayed.
-     */
-    static class OccurrenceDisplayDescriptor {
-
-        int eventTag = -1;
-        int seriesValueIndex = -1;
-        boolean includePid = false;
-        int filterValueIndex = -1;
-        CompareMethod filterCompareMethod = CompareMethod.EQUAL_TO;
-        Object filterValue = null;
-
-        OccurrenceDisplayDescriptor() {
-        }
-
-        OccurrenceDisplayDescriptor(OccurrenceDisplayDescriptor descriptor) {
-            replaceWith(descriptor);
-        }
-
-        OccurrenceDisplayDescriptor(int eventTag) {
-            this.eventTag = eventTag;
-        }
-
-        OccurrenceDisplayDescriptor(int eventTag, int seriesValueIndex) {
-            this.eventTag = eventTag;
-            this.seriesValueIndex = seriesValueIndex;
-        }
-
-        void replaceWith(OccurrenceDisplayDescriptor descriptor) {
-            eventTag = descriptor.eventTag;
-            seriesValueIndex = descriptor.seriesValueIndex;
-            includePid = descriptor.includePid;
-            filterValueIndex = descriptor.filterValueIndex;
-            filterCompareMethod = descriptor.filterCompareMethod;
-            filterValue = descriptor.filterValue;
-        }
-
-        /**
-         * Loads the descriptor parameter from a storage string. The storage string must have
-         * been generated with {@link #getStorageString()}.
-         *
-         * @param storageString the storage string
-         */
-        final void loadFrom(String storageString) {
-            String[] values = storageString.split(Pattern.quote(DESCRIPTOR_DATA_STORAGE_SEPARATOR));
-            loadFrom(values, 0);
-        }
-
-        /**
-         * Loads the parameters from an array of strings.
-         *
-         * @param storageStrings the strings representing each parameter.
-         * @param index          the starting index in the array of strings.
-         * @return the new index in the array.
-         */
-        protected int loadFrom(String[] storageStrings, int index) {
-            eventTag = Integer.parseInt(storageStrings[index++]);
-            seriesValueIndex = Integer.parseInt(storageStrings[index++]);
-            includePid = Boolean.parseBoolean(storageStrings[index++]);
-            filterValueIndex = Integer.parseInt(storageStrings[index++]);
-            try {
-                filterCompareMethod = CompareMethod.valueOf(storageStrings[index++]);
-            } catch (IllegalArgumentException e) {
-                // if the name does not match any known CompareMethod, we init it to the default one
-                filterCompareMethod = CompareMethod.EQUAL_TO;
-            }
-            String value = storageStrings[index++];
-            if (filterValueIndex != -1 && FILTER_VALUE_NULL.equals(value) == false) {
-                filterValue = EventValueType.getObjectFromStorageString(value);
-            }
-
-            return index;
-        }
-
-        /**
-         * Returns the storage string for the receiver.
-         */
-        String getStorageString() {
-            StringBuilder sb = new StringBuilder();
-            sb.append(eventTag);
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(seriesValueIndex);
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(Boolean.toString(includePid));
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(filterValueIndex);
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(filterCompareMethod.name());
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            if (filterValue != null) {
-                String value = EventValueType.getStorageString(filterValue);
-                if (value != null) {
-                    sb.append(value);
-                } else {
-                    sb.append(FILTER_VALUE_NULL);
-                }
-            } else {
-                sb.append(FILTER_VALUE_NULL);
-            }
-
-            return sb.toString();
-        }
-    }
-
-    /**
-     * Describes an event value to be displayed.
-     */
-    static final class ValueDisplayDescriptor extends OccurrenceDisplayDescriptor {
-        String valueName;
-        int valueIndex = -1;
-
-        ValueDisplayDescriptor() {
-            super();
-        }
-
-        ValueDisplayDescriptor(ValueDisplayDescriptor descriptor) {
-            super();
-            replaceWith(descriptor);
-        }
-
-        ValueDisplayDescriptor(int eventTag, String valueName, int valueIndex) {
-            super(eventTag);
-            this.valueName = valueName;
-            this.valueIndex = valueIndex;
-        }
-
-        ValueDisplayDescriptor(int eventTag, String valueName, int valueIndex,
-                int seriesValueIndex) {
-            super(eventTag, seriesValueIndex);
-            this.valueName = valueName;
-            this.valueIndex = valueIndex;
-        }
-
-        @Override
-        void replaceWith(OccurrenceDisplayDescriptor descriptor) {
-            super.replaceWith(descriptor);
-            if (descriptor instanceof ValueDisplayDescriptor) {
-                ValueDisplayDescriptor valueDescriptor = (ValueDisplayDescriptor) descriptor;
-                valueName = valueDescriptor.valueName;
-                valueIndex = valueDescriptor.valueIndex;
-            }
-        }
-
-        /**
-         * Loads the parameters from an array of strings.
-         *
-         * @param storageStrings the strings representing each parameter.
-         * @param index          the starting index in the array of strings.
-         * @return the new index in the array.
-         */
-        @Override
-        protected int loadFrom(String[] storageStrings, int index) {
-            index = super.loadFrom(storageStrings, index);
-            valueName = storageStrings[index++];
-            valueIndex = Integer.parseInt(storageStrings[index++]);
-            return index;
-        }
-
-        /**
-         * Returns the storage string for the receiver.
-         */
-        @Override
-        String getStorageString() {
-            String superStorage = super.getStorageString();
-
-            StringBuilder sb = new StringBuilder();
-            sb.append(superStorage);
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(valueName);
-            sb.append(DESCRIPTOR_DATA_STORAGE_SEPARATOR);
-            sb.append(valueIndex);
-
-            return sb.toString();
-        }
-    }
-
-    /* ==================
-     * Event Display parameters.
-     * ================== */
-    protected String mName;
-
-    private boolean mPidFiltering = false;
-
-    private ArrayList<Integer> mPidFilterList = null;
-
-    protected final ArrayList<ValueDisplayDescriptor> mValueDescriptors =
-            new ArrayList<ValueDisplayDescriptor>();
-    private final ArrayList<OccurrenceDisplayDescriptor> mOccurrenceDescriptors =
-            new ArrayList<OccurrenceDisplayDescriptor>();
-
-    /* ==================
-     * Event Display members for display purpose.
-     * ================== */
-    // chart objects
-    /**
-     * This is a map of (descriptor, map2) where map2 is a map of (pid, chart-series)
-     */
-    protected final HashMap<ValueDisplayDescriptor, HashMap<Integer, TimeSeries>> mValueDescriptorSeriesMap =
-            new HashMap<ValueDisplayDescriptor, HashMap<Integer, TimeSeries>>();
-    /**
-     * This is a map of (descriptor, map2) where map2 is a map of (pid, chart-series)
-     */
-    protected final HashMap<OccurrenceDisplayDescriptor, HashMap<Integer, TimeSeries>> mOcurrenceDescriptorSeriesMap =
-            new HashMap<OccurrenceDisplayDescriptor, HashMap<Integer, TimeSeries>>();
-
-    /**
-     * This is a map of (ValueType, dataset)
-     */
-    protected final HashMap<ValueType, TimeSeriesCollection> mValueTypeDataSetMap =
-            new HashMap<ValueType, TimeSeriesCollection>();
-
-    protected JFreeChart mChart;
-    protected TimeSeriesCollection mOccurrenceDataSet;
-    protected int mDataSetCount;
-    private ChartComposite mChartComposite;
-    protected long mMaximumChartItemAge = -1;
-    protected long mHistWidth = 1;
-
-    // log objects.
-    protected Table mLogTable;
-
-    /* ==================
-     * Misc data.
-     * ================== */
-    protected int mValueDescriptorCheck = EVENT_CHECK_FAILED;
-
-    EventDisplay(String name) {
-        mName = name;
-    }
-
-    static EventDisplay clone(EventDisplay from) {
-        EventDisplay ed = eventDisplayFactory(from.getDisplayType(), from.getName());
-        ed.mName = from.mName;
-        ed.mPidFiltering = from.mPidFiltering;
-        ed.mMaximumChartItemAge = from.mMaximumChartItemAge;
-        ed.mHistWidth = from.mHistWidth;
-
-        if (from.mPidFilterList != null) {
-            ed.mPidFilterList = new ArrayList<Integer>();
-            ed.mPidFilterList.addAll(from.mPidFilterList);
-        }
-
-        for (ValueDisplayDescriptor desc : from.mValueDescriptors) {
-            ed.mValueDescriptors.add(new ValueDisplayDescriptor(desc));
-        }
-        ed.mValueDescriptorCheck = from.mValueDescriptorCheck;
-
-        for (OccurrenceDisplayDescriptor desc : from.mOccurrenceDescriptors) {
-            ed.mOccurrenceDescriptors.add(new OccurrenceDisplayDescriptor(desc));
-        }
-        return ed;
-    }
-
-    /**
-     * Returns the parameters of the receiver as a single String for storage.
-     */
-    String getStorageString() {
-        StringBuilder sb = new StringBuilder();
-
-        sb.append(mName);
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(getDisplayType());
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(Boolean.toString(mPidFiltering));
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(getPidStorageString());
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(getDescriptorStorageString(mValueDescriptors));
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(getDescriptorStorageString(mOccurrenceDescriptors));
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(mMaximumChartItemAge);
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-        sb.append(mHistWidth);
-        sb.append(DISPLAY_DATA_STORAGE_SEPARATOR);
-
-        return sb.toString();
-    }
-
-    void setName(String name) {
-        mName = name;
-    }
-
-    String getName() {
-        return mName;
-    }
-
-    void setPidFiltering(boolean filterByPid) {
-        mPidFiltering = filterByPid;
-    }
-
-    boolean getPidFiltering() {
-        return mPidFiltering;
-    }
-
-    void setPidFilterList(ArrayList<Integer> pids) {
-        if (mPidFiltering == false) {
-            new InvalidParameterException();
-        }
-
-        mPidFilterList = pids;
-    }
-
-    ArrayList<Integer> getPidFilterList() {
-        return mPidFilterList;
-    }
-
-    void addPidFiler(int pid) {
-        if (mPidFiltering == false) {
-            new InvalidParameterException();
-        }
-
-        if (mPidFilterList == null) {
-            mPidFilterList = new ArrayList<Integer>();
-        }
-
-        mPidFilterList.add(pid);
-    }
-
-    /**
-     * Returns an iterator to the list of {@link ValueDisplayDescriptor}.
-     */
-    Iterator<ValueDisplayDescriptor> getValueDescriptors() {
-        return mValueDescriptors.iterator();
-    }
-
-    /**
-     * Update checks on the descriptors. Must be called whenever a descriptor is modified outside
-     * of this class.
-     */
-    void updateValueDescriptorCheck() {
-        mValueDescriptorCheck = checkDescriptors();
-    }
-
-    /**
-     * Returns an iterator to the list of {@link OccurrenceDisplayDescriptor}.
-     */
-    Iterator<OccurrenceDisplayDescriptor> getOccurrenceDescriptors() {
-        return mOccurrenceDescriptors.iterator();
-    }
-
-    /**
-     * Adds a descriptor. This can be a {@link OccurrenceDisplayDescriptor} or a
-     * {@link ValueDisplayDescriptor}.
-     *
-     * @param descriptor the descriptor to be added.
-     */
-    void addDescriptor(OccurrenceDisplayDescriptor descriptor) {
-        if (descriptor instanceof ValueDisplayDescriptor) {
-            mValueDescriptors.add((ValueDisplayDescriptor) descriptor);
-            mValueDescriptorCheck = checkDescriptors();
-        } else {
-            mOccurrenceDescriptors.add(descriptor);
-        }
-    }
-
-    /**
-     * Returns a descriptor by index and class (extending {@link OccurrenceDisplayDescriptor}).
-     *
-     * @param descriptorClass the class of the descriptor to return.
-     * @param index           the index of the descriptor to return.
-     * @return either a {@link OccurrenceDisplayDescriptor} or a {@link ValueDisplayDescriptor}
-     *         or <code>null</code> if <code>descriptorClass</code> is another class.
-     */
-    OccurrenceDisplayDescriptor getDescriptor(
-            Class<? extends OccurrenceDisplayDescriptor> descriptorClass, int index) {
-
-        if (descriptorClass == OccurrenceDisplayDescriptor.class) {
-            return mOccurrenceDescriptors.get(index);
-        } else if (descriptorClass == ValueDisplayDescriptor.class) {
-            return mValueDescriptors.get(index);
-        }
-
-        return null;
-    }
-
-    /**
-     * Removes a descriptor based on its class and index.
-     *
-     * @param descriptorClass the class of the descriptor.
-     * @param index           the index of the descriptor to be removed.
-     */
-    void removeDescriptor(Class<? extends OccurrenceDisplayDescriptor> descriptorClass, int index) {
-        if (descriptorClass == OccurrenceDisplayDescriptor.class) {
-            mOccurrenceDescriptors.remove(index);
-        } else if (descriptorClass == ValueDisplayDescriptor.class) {
-            mValueDescriptors.remove(index);
-            mValueDescriptorCheck = checkDescriptors();
-        }
-    }
-
-    Control createCompositeChart(final Composite parent, EventLogParser logParser,
-            String title) {
-        mChart = ChartFactory.createTimeSeriesChart(
-                null,
-                null /* timeAxisLabel */,
-                null /* valueAxisLabel */,
-                null, /* dataset. set below */
-                true /* legend */,
-                false /* tooltips */,
-                false /* urls */);
-
-        // get the font to make a proper title. We need to convert the swt font,
-        // into an awt font.
-        Font f = parent.getFont();
-        FontData[] fData = f.getFontData();
-
-        // event though on Mac OS there could be more than one fontData, we'll only use
-        // the first one.
-        FontData firstFontData = fData[0];
-
-        java.awt.Font awtFont = SWTUtils.toAwtFont(parent.getDisplay(),
-                firstFontData, true /* ensureSameSize */);
-
-
-        mChart.setTitle(new TextTitle(title, awtFont));
-
-        final XYPlot xyPlot = mChart.getXYPlot();
-        xyPlot.setRangeCrosshairVisible(true);
-        xyPlot.setRangeCrosshairLockedOnData(true);
-        xyPlot.setDomainCrosshairVisible(true);
-        xyPlot.setDomainCrosshairLockedOnData(true);
-
-        mChart.addChangeListener(new ChartChangeListener() {
-            public void chartChanged(ChartChangeEvent event) {
-                ChartChangeEventType type = event.getType();
-                if (type == ChartChangeEventType.GENERAL) {
-                    // because the value we need (rangeCrosshair and domainCrosshair) are
-                    // updated on the draw, but the notification happens before the draw,
-                    // we process the click in a future runnable!
-                    parent.getDisplay().asyncExec(new Runnable() {
-                        public void run() {
-                            processClick(xyPlot);
-                        }
-                    });
-                }
-            }
-        });
-
-        mChartComposite = new ChartComposite(parent, SWT.BORDER, mChart,
-                ChartComposite.DEFAULT_WIDTH,
-                ChartComposite.DEFAULT_HEIGHT,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_WIDTH,
-                ChartComposite.DEFAULT_MINIMUM_DRAW_HEIGHT,
-                3000, // max draw width. We don't want it to zoom, so we put a big number
-                3000, // max draw height. We don't want it to zoom, so we put a big number
-                true,  // off-screen buffer
-                true,  // properties
-                true,  // save
-                true,  // print
-                true,  // zoom
-                true);   // tooltips
-
-        mChartComposite.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                mValueTypeDataSetMap.clear();
-                mDataSetCount = 0;
-                mOccurrenceDataSet = null;
-                mChart = null;
-                mChartComposite = null;
-                mValueDescriptorSeriesMap.clear();
-                mOcurrenceDescriptorSeriesMap.clear();
-            }
-        });
-
-        return mChartComposite;
-
-    }
-
-    private void processClick(XYPlot xyPlot) {
-        double rangeValue = xyPlot.getRangeCrosshairValue();
-        if (rangeValue != 0) {
-            double domainValue = xyPlot.getDomainCrosshairValue();
-
-            Millisecond msec = new Millisecond(new Date((long) domainValue));
-
-            // look for values in the dataset that contains data at this TimePeriod
-            Set<ValueDisplayDescriptor> descKeys = mValueDescriptorSeriesMap.keySet();
-
-            for (ValueDisplayDescriptor descKey : descKeys) {
-                HashMap<Integer, TimeSeries> map = mValueDescriptorSeriesMap.get(descKey);
-
-                Set<Integer> pidKeys = map.keySet();
-
-                for (Integer pidKey : pidKeys) {
-                    TimeSeries series = map.get(pidKey);
-
-                    Number value = series.getValue(msec);
-                    if (value != null) {
-                        // found a match. lets check against the actual value.
-                        if (value.doubleValue() == rangeValue) {
-
-                            return;
-                        }
-                    }
-                }
-            }
-        }
-    }
-
-
-    /**
-     * Resizes the <code>index</code>-th column of the log {@link Table} (if applicable).
-     * Subclasses can override if necessary.
-     * <p/>
-     * This does nothing if the <code>Table</code> object is <code>null</code> (because the display
-     * type does not use a column) or if the <code>index</code>-th column is in fact the originating
-     * column passed as argument.
-     *
-     * @param index        the index of the column to resize
-     * @param sourceColumn the original column that was resize, and on which we need to sync the
-     *                     index-th column width.
-     */
-    void resizeColumn(int index, TableColumn sourceColumn) {
-    }
-
-    /**
-     * Sets the current {@link EventLogParser} object.
-     * Subclasses can override if necessary.
-     */
-    protected void setNewLogParser(EventLogParser logParser) {
-    }
-
-    /**
-     * Prepares the {@link EventDisplay} for a multi event display.
-     */
-    void startMultiEventDisplay() {
-        if (mLogTable != null) {
-            mLogTable.setRedraw(false);
-        }
-    }
-
-    /**
-     * Finalizes the {@link EventDisplay} after a multi event display.
-     */
-    void endMultiEventDisplay() {
-        if (mLogTable != null) {
-            mLogTable.setRedraw(true);
-        }
-    }
-
-    /**
-     * Returns the {@link Table} object used to display events, if any.
-     *
-     * @return a Table object or <code>null</code>.
-     */
-    Table getTable() {
-        return mLogTable;
-    }
-
-    /**
-     * Loads a new {@link EventDisplay} from a storage string. The string must have been created
-     * with {@link #getStorageString()}.
-     *
-     * @param storageString the storage string
-     * @return a new {@link EventDisplay} or null if the load failed.
-     */
-    static EventDisplay load(String storageString) {
-        if (storageString.length() > 0) {
-            // the storage string is separated by ':'
-            String[] values = storageString.split(Pattern.quote(DISPLAY_DATA_STORAGE_SEPARATOR));
-
-            try {
-                int index = 0;
-
-                String name = values[index++];
-                int displayType = Integer.parseInt(values[index++]);
-                boolean pidFiltering = Boolean.parseBoolean(values[index++]);
-
-                EventDisplay ed = eventDisplayFactory(displayType, name);
-                ed.setPidFiltering(pidFiltering);
-
-                // because empty sections are removed by String.split(), we have to check
-                // the index for those.
-                if (index < values.length) {
-                    ed.loadPidFilters(values[index++]);
-                }
-
-                if (index < values.length) {
-                    ed.loadValueDescriptors(values[index++]);
-                }
-
-                if (index < values.length) {
-                    ed.loadOccurrenceDescriptors(values[index++]);
-                }
-
-                ed.updateValueDescriptorCheck();
-
-                if (index < values.length) {
-                    ed.mMaximumChartItemAge = Long.parseLong(values[index++]);
-                }
-
-                if (index < values.length) {
-                    ed.mHistWidth = Long.parseLong(values[index++]);
-                }
-
-                return ed;
-            } catch (RuntimeException re) {
-                // we'll return null below.
-                Log.e("ddms", re);
-            }
-        }
-
-        return null;
-    }
-
-    private String getPidStorageString() {
-        if (mPidFilterList != null) {
-            StringBuilder sb = new StringBuilder();
-            boolean first = true;
-            for (Integer i : mPidFilterList) {
-                if (first == false) {
-                    sb.append(PID_STORAGE_SEPARATOR);
-                } else {
-                    first = false;
-                }
-                sb.append(i);
-            }
-
-            return sb.toString();
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-
-    private void loadPidFilters(String storageString) {
-        if (storageString.length() > 0) {
-            String[] values = storageString.split(Pattern.quote(PID_STORAGE_SEPARATOR));
-
-            for (String value : values) {
-                if (mPidFilterList == null) {
-                    mPidFilterList = new ArrayList<Integer>();
-                }
-                mPidFilterList.add(Integer.parseInt(value));
-            }
-        }
-    }
-
-    private String getDescriptorStorageString(
-            ArrayList<? extends OccurrenceDisplayDescriptor> descriptorList) {
-        StringBuilder sb = new StringBuilder();
-        boolean first = true;
-
-        for (OccurrenceDisplayDescriptor descriptor : descriptorList) {
-            if (first == false) {
-                sb.append(DESCRIPTOR_STORAGE_SEPARATOR);
-            } else {
-                first = false;
-            }
-            sb.append(descriptor.getStorageString());
-        }
-
-        return sb.toString();
-    }
-
-    private void loadOccurrenceDescriptors(String storageString) {
-        if (storageString.length() == 0) {
-            return;
-        }
-
-        String[] values = storageString.split(Pattern.quote(DESCRIPTOR_STORAGE_SEPARATOR));
-
-        for (String value : values) {
-            OccurrenceDisplayDescriptor desc = new OccurrenceDisplayDescriptor();
-            desc.loadFrom(value);
-            mOccurrenceDescriptors.add(desc);
-        }
-    }
-
-    private void loadValueDescriptors(String storageString) {
-        if (storageString.length() == 0) {
-            return;
-        }
-
-        String[] values = storageString.split(Pattern.quote(DESCRIPTOR_STORAGE_SEPARATOR));
-
-        for (String value : values) {
-            ValueDisplayDescriptor desc = new ValueDisplayDescriptor();
-            desc.loadFrom(value);
-            mValueDescriptors.add(desc);
-        }
-    }
-
-    /**
-     * Fills a list with {@link OccurrenceDisplayDescriptor} (or a subclass of it) from another
-     * list if they are configured to display the {@link EventContainer}
-     *
-     * @param event    the event container
-     * @param fullList the list with all the descriptors.
-     * @param outList  the list to fill.
-     */
-    @SuppressWarnings("unchecked")
-    private void getDescriptors(EventContainer event,
-            ArrayList<? extends OccurrenceDisplayDescriptor> fullList,
-            ArrayList outList) {
-        for (OccurrenceDisplayDescriptor descriptor : fullList) {
-            try {
-                // first check the event tag.
-                if (descriptor.eventTag == event.mTag) {
-                    // now check if we have a filter on a value
-                    if (descriptor.filterValueIndex == -1 ||
-                            event.testValue(descriptor.filterValueIndex, descriptor.filterValue,
-                                    descriptor.filterCompareMethod)) {
-                        outList.add(descriptor);
-                    }
-                }
-            } catch (InvalidTypeException ite) {
-                // if the filter for the descriptor was incorrect, we ignore the descriptor.
-            } catch (ArrayIndexOutOfBoundsException aioobe) {
-                // if the index was wrong (the event content may have changed since we setup the
-                // display), we do nothing but log the error
-                Log.e("Event Log", String.format(
-                        "ArrayIndexOutOfBoundsException occured when checking %1$d-th value of event %2$d", //$NON-NLS-1$
-                        descriptor.filterValueIndex, descriptor.eventTag));
-            }
-        }
-    }
-
-    /**
-     * Filters the {@link com.android.ddmlib.log.EventContainer}, and fills two list of {@link com.android.ddmuilib.log.event.EventDisplay.ValueDisplayDescriptor}
-     * and {@link com.android.ddmuilib.log.event.EventDisplay.OccurrenceDisplayDescriptor} configured to display the event.
-     *
-     * @param event
-     * @param valueDescriptors
-     * @param occurrenceDescriptors
-     * @return true if the event should be displayed.
-     */
-
-    protected boolean filterEvent(EventContainer event,
-            ArrayList<ValueDisplayDescriptor> valueDescriptors,
-            ArrayList<OccurrenceDisplayDescriptor> occurrenceDescriptors) {
-
-        // test the pid first (if needed)
-        if (mPidFiltering && mPidFilterList != null) {
-            boolean found = false;
-            for (int pid : mPidFilterList) {
-                if (pid == event.pid) {
-                    found = true;
-                    break;
-                }
-            }
-
-            if (found == false) {
-                return false;
-            }
-        }
-
-        // now get the list of matching descriptors
-        getDescriptors(event, mValueDescriptors, valueDescriptors);
-        getDescriptors(event, mOccurrenceDescriptors, occurrenceDescriptors);
-
-        // and return whether there is at least one match in either list.
-        return (valueDescriptors.size() > 0 || occurrenceDescriptors.size() > 0);
-    }
-
-    /**
-     * Checks all the {@link ValueDisplayDescriptor} for similarity.
-     * If all the event values are from the same tag, the method will return EVENT_CHECK_SAME_TAG.
-     * If all the event/value are the same, the method will return EVENT_CHECK_SAME_VALUE
-     *
-     * @return flag as described above
-     */
-    private int checkDescriptors() {
-        if (mValueDescriptors.size() < 2) {
-            return EVENT_CHECK_SAME_VALUE;
-        }
-
-        int tag = -1;
-        int index = -1;
-        for (ValueDisplayDescriptor display : mValueDescriptors) {
-            if (tag == -1) {
-                tag = display.eventTag;
-                index = display.valueIndex;
-            } else {
-                if (tag != display.eventTag) {
-                    return EVENT_CHECK_FAILED;
-                } else {
-                    if (index != -1) {
-                        if (index != display.valueIndex) {
-                            index = -1;
-                        }
-                    }
-                }
-            }
-        }
-
-        if (index == -1) {
-            return EVENT_CHECK_SAME_TAG;
-        }
-
-        return EVENT_CHECK_SAME_VALUE;
-    }
-
-    /**
-     * Resets the time limit on the chart to be infinite.
-     */
-    void resetChartTimeLimit() {
-        mMaximumChartItemAge = -1;
-    }
-
-    /**
-     * Sets the time limit on the charts.
-     *
-     * @param timeLimit the time limit in seconds.
-     */
-    void setChartTimeLimit(long timeLimit) {
-        mMaximumChartItemAge = timeLimit;
-    }
-
-    long getChartTimeLimit() {
-        return mMaximumChartItemAge;
-    }
-
-    /**
-     * m
-     * Resets the histogram width
-     */
-    void resetHistWidth() {
-        mHistWidth = 1;
-    }
-
-    /**
-     * Sets the histogram width
-     *
-     * @param histWidth the width in hours
-     */
-    void setHistWidth(long histWidth) {
-        mHistWidth = histWidth;
-    }
-
-    long getHistWidth() {
-        return mHistWidth;
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplayOptions.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplayOptions.java
deleted file mode 100644
index 88c3cb2..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventDisplayOptions.java
+++ /dev/null
@@ -1,955 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.EventValueDescription;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.IImageLoader;
-import com.android.ddmuilib.log.event.EventDisplay.OccurrenceDisplayDescriptor;
-import com.android.ddmuilib.log.event.EventDisplay.ValueDisplayDescriptor;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.List;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.Map;
-
-class EventDisplayOptions  extends Dialog {
-    private static final int DLG_WIDTH = 700;
-    private static final int DLG_HEIGHT = 700;
-    
-    private IImageLoader mImageLoader;
-
-    private Shell mParent;
-    private Shell mShell;
-    
-    private boolean mEditStatus = false;
-    private final ArrayList<EventDisplay> mDisplayList = new ArrayList<EventDisplay>();
-
-    /* LEFT LIST */
-    private List mEventDisplayList;
-    private Button mEventDisplayNewButton;
-    private Button mEventDisplayDeleteButton;
-    private Button mEventDisplayUpButton;
-    private Button mEventDisplayDownButton;
-    private Text mDisplayWidthText;
-    private Text mDisplayHeightText;
-
-    /* WIDGETS ON THE RIGHT */
-    private Text mDisplayNameText;
-    private Combo mDisplayTypeCombo;
-    private Group mChartOptions;
-    private Group mHistOptions;
-    private Button mPidFilterCheckBox;
-    private Text mPidText;
-
-    /** Map with (event-tag, event name) */
-    private Map<Integer, String> mEventTagMap;
-
-    /** Map with (event-tag, array of value info for the event) */
-    private Map<Integer, EventValueDescription[]> mEventDescriptionMap;
-
-    /** list of current pids */
-    private ArrayList<Integer> mPidList;
-
-    private EventLogParser mLogParser;
-
-    private Group mInfoGroup;
-
-    private static class SelectionWidgets {
-        private List mList;
-        private Button mNewButton;
-        private Button mEditButton;
-        private Button mDeleteButton;
-        
-        private void setEnabled(boolean enable) {
-            mList.setEnabled(enable);
-            mNewButton.setEnabled(enable);
-            mEditButton.setEnabled(enable);
-            mDeleteButton.setEnabled(enable);
-        }
-    }
-    
-    private SelectionWidgets mValueSelection;
-    private SelectionWidgets mOccurrenceSelection;
-    
-    /** flag to temporarly disable processing of {@link Text} changes, so that 
-     * {@link Text#setText(String)} can be called safely. */
-    private boolean mProcessTextChanges = true;
-    private Text mTimeLimitText;
-    private Text mHistWidthText;
-
-    EventDisplayOptions(IImageLoader imageLoader, Shell parent) {
-        super(parent, SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL);
-        mImageLoader = imageLoader;
-    }
-
-    /**
-     * Opens the display option dialog, to edit the {@link EventDisplay} objects provided in the
-     * list.
-     * @param logParser
-     * @param displayList
-     * @param eventList
-     * @return true if the list of {@link EventDisplay} objects was updated.
-     */
-    boolean open(EventLogParser logParser, ArrayList<EventDisplay> displayList,
-            ArrayList<EventContainer> eventList) {
-        mLogParser = logParser;
-
-        if (logParser != null) {
-            // we need 2 things from the parser.
-            // the event tag / event name map
-            mEventTagMap = logParser.getTagMap();
-            
-            // the event info map
-            mEventDescriptionMap = logParser.getEventInfoMap();
-        }
-
-        // make a copy of the EventDisplay list since we'll use working copies.
-        duplicateEventDisplay(displayList);
-        
-        // build a list of pid from the list of events.
-        buildPidList(eventList);
-
-        createUI();
-
-        if (mParent == null || mShell == null) {
-            return false;
-        }
-
-        // Set the dialog size.
-        mShell.setMinimumSize(DLG_WIDTH, DLG_HEIGHT);
-        Rectangle r = mParent.getBounds();
-        // get the center new top left.
-        int cx = r.x + r.width/2;
-        int x = cx - DLG_WIDTH / 2;
-        int cy = r.y + r.height/2;
-        int y = cy - DLG_HEIGHT / 2;
-        mShell.setBounds(x, y, DLG_WIDTH, DLG_HEIGHT);
-
-        mShell.layout();
-
-        // actually open the dialog
-        mShell.open();
-
-        // event loop until the dialog is closed.
-        Display display = mParent.getDisplay();
-        while (!mShell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-        
-        return mEditStatus;
-    }
-    
-    ArrayList<EventDisplay> getEventDisplays() {
-        return mDisplayList;
-    }
-    
-    private void createUI() {
-        mParent = getParent();
-        mShell = new Shell(mParent, getStyle());
-        mShell.setText("Event Display Configuration");
-
-        mShell.setLayout(new GridLayout(1, true));
-
-        final Composite topPanel = new Composite(mShell, SWT.NONE);
-        topPanel.setLayoutData(new GridData(GridData.FILL_BOTH));
-        topPanel.setLayout(new GridLayout(2, false));
-        
-        // create the tree on the left and the controls on the right.
-        Composite leftPanel = new Composite(topPanel, SWT.NONE);
-        Composite rightPanel = new Composite(topPanel, SWT.NONE);
-
-        createLeftPanel(leftPanel);
-        createRightPanel(rightPanel);
-
-        mShell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-                event.doit = true;
-            }
-        });
-        
-        Label separator = new Label(mShell, SWT.SEPARATOR | SWT.HORIZONTAL);
-        separator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        Composite bottomButtons = new Composite(mShell, SWT.NONE);
-        bottomButtons.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        GridLayout gl;
-        bottomButtons.setLayout(gl = new GridLayout(2, true));
-        gl.marginHeight = gl.marginWidth = 0;
-        
-        Button okButton = new Button(bottomButtons, SWT.PUSH);
-        okButton.setText("OK");
-        okButton.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mShell.close();
-            }
-        });
-
-        Button cancelButton = new Button(bottomButtons, SWT.PUSH);
-        cancelButton.setText("Cancel");
-        cancelButton.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // cancel the modification flag.
-                mEditStatus = false;
-                
-                // and close
-                mShell.close();
-            }
-        });
-
-        enable(false);
-        
-        // fill the list with the current display
-        fillEventDisplayList();
-    }
-
-    private void createLeftPanel(Composite leftPanel) {
-        final IPreferenceStore store = DdmUiPreferences.getStore();
-
-        GridLayout gl;
-
-        leftPanel.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-        leftPanel.setLayout(gl = new GridLayout(1, false));
-        gl.verticalSpacing = 1;
-
-        mEventDisplayList = new List(leftPanel,
-                SWT.BORDER | SWT.SINGLE | SWT.V_SCROLL | SWT.FULL_SELECTION);
-        mEventDisplayList.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mEventDisplayList.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleEventDisplaySelection();
-            }
-        });
-
-        Composite bottomControls = new Composite(leftPanel, SWT.NONE);
-        bottomControls.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        bottomControls.setLayout(gl = new GridLayout(5, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        gl.verticalSpacing = 0;
-        gl.horizontalSpacing = 0;
-
-        mEventDisplayNewButton = new Button(bottomControls, SWT.PUSH | SWT.FLAT);
-        mEventDisplayNewButton.setImage(mImageLoader.loadImage("add.png", // $NON-NLS-1$
-                leftPanel.getDisplay()));
-        mEventDisplayNewButton.setToolTipText("Adds a new event display");
-        mEventDisplayNewButton.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER));
-        mEventDisplayNewButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                createNewEventDisplay();
-            }
-        });
-        
-        mEventDisplayDeleteButton = new Button(bottomControls, SWT.PUSH | SWT.FLAT);
-        mEventDisplayDeleteButton.setImage(mImageLoader.loadImage("delete.png", // $NON-NLS-1$
-                leftPanel.getDisplay()));
-        mEventDisplayDeleteButton.setToolTipText("Deletes the selected event display");
-        mEventDisplayDeleteButton.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER));
-        mEventDisplayDeleteButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                deleteEventDisplay();
-            }
-        });
-
-        mEventDisplayUpButton = new Button(bottomControls, SWT.PUSH | SWT.FLAT);
-        mEventDisplayUpButton.setImage(mImageLoader.loadImage("up.png", // $NON-NLS-1$
-                leftPanel.getDisplay()));
-        mEventDisplayUpButton.setToolTipText("Moves the selected event display up");
-        mEventDisplayUpButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get current selection.
-                int selection = mEventDisplayList.getSelectionIndex();
-                if (selection > 0) {
-                    // update the list of EventDisplay.
-                    EventDisplay display = mDisplayList.remove(selection);
-                    mDisplayList.add(selection - 1, display);
-                    
-                    // update the list widget
-                    mEventDisplayList.remove(selection);
-                    mEventDisplayList.add(display.getName(), selection - 1);
-                    
-                    // update the selection and reset the ui.
-                    mEventDisplayList.select(selection - 1);
-                    handleEventDisplaySelection();
-                    mEventDisplayList.showSelection();
-
-                    setModified();
-                }
-            }
-        });
-
-        mEventDisplayDownButton = new Button(bottomControls, SWT.PUSH | SWT.FLAT);
-        mEventDisplayDownButton.setImage(mImageLoader.loadImage("down.png", // $NON-NLS-1$
-                leftPanel.getDisplay()));
-        mEventDisplayDownButton.setToolTipText("Moves the selected event display down");
-        mEventDisplayDownButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get current selection.
-                int selection = mEventDisplayList.getSelectionIndex();
-                if (selection != -1 && selection < mEventDisplayList.getItemCount() - 1) {
-                    // update the list of EventDisplay.
-                    EventDisplay display = mDisplayList.remove(selection);
-                    mDisplayList.add(selection + 1, display);
-                    
-                    // update the list widget
-                    mEventDisplayList.remove(selection);
-                    mEventDisplayList.add(display.getName(), selection + 1);
-                    
-                    // update the selection and reset the ui.
-                    mEventDisplayList.select(selection + 1);
-                    handleEventDisplaySelection();
-                    mEventDisplayList.showSelection();
-
-                    setModified();
-                }
-            }
-        });
-        
-        Group sizeGroup = new Group(leftPanel, SWT.NONE);
-        sizeGroup.setText("Display Size:");
-        sizeGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        sizeGroup.setLayout(new GridLayout(2, false));
-
-        Label l = new Label(sizeGroup, SWT.NONE);
-        l.setText("Width:");
-        
-        mDisplayWidthText = new Text(sizeGroup, SWT.LEFT | SWT.SINGLE | SWT.BORDER);
-        mDisplayWidthText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mDisplayWidthText.setText(Integer.toString(
-                store.getInt(EventLogPanel.PREFS_DISPLAY_WIDTH)));
-        mDisplayWidthText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                String text = mDisplayWidthText.getText().trim();
-                try {
-                    store.setValue(EventLogPanel.PREFS_DISPLAY_WIDTH, Integer.parseInt(text));
-                    setModified();
-                } catch (NumberFormatException nfe) {
-                    // do something?
-                }
-            }
-        });
-
-        l = new Label(sizeGroup, SWT.NONE);
-        l.setText("Height:");
-
-        mDisplayHeightText = new Text(sizeGroup, SWT.LEFT | SWT.SINGLE | SWT.BORDER);
-        mDisplayHeightText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mDisplayHeightText.setText(Integer.toString(
-                store.getInt(EventLogPanel.PREFS_DISPLAY_HEIGHT)));
-        mDisplayHeightText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                String text = mDisplayHeightText.getText().trim();
-                try {
-                    store.setValue(EventLogPanel.PREFS_DISPLAY_HEIGHT, Integer.parseInt(text));
-                    setModified();
-                } catch (NumberFormatException nfe) {
-                    // do something?
-                }
-            }
-        });
-    }
-
-    private void createRightPanel(Composite rightPanel) {
-        rightPanel.setLayout(new GridLayout(1, true));
-        rightPanel.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        mInfoGroup = new Group(rightPanel, SWT.NONE);
-        mInfoGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mInfoGroup.setLayout(new GridLayout(2, false));
-        
-        Label nameLabel = new Label(mInfoGroup, SWT.LEFT);
-        nameLabel.setText("Name:");
-
-        mDisplayNameText = new Text(mInfoGroup, SWT.BORDER | SWT.LEFT | SWT.SINGLE);
-        mDisplayNameText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mDisplayNameText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                if (mProcessTextChanges) {
-                    EventDisplay eventDisplay = getCurrentEventDisplay();
-                    if (eventDisplay != null) {
-                        eventDisplay.setName(mDisplayNameText.getText());
-                        int index = mEventDisplayList.getSelectionIndex();
-                        mEventDisplayList.remove(index);
-                        mEventDisplayList.add(eventDisplay.getName(), index);
-                        mEventDisplayList.select(index);
-                        handleEventDisplaySelection();
-                        setModified();
-                    }
-                }
-            }
-        });
-
-        Label displayLabel = new Label(mInfoGroup, SWT.LEFT);
-        displayLabel.setText("Type:");
-        
-        mDisplayTypeCombo = new Combo(mInfoGroup, SWT.READ_ONLY | SWT.DROP_DOWN);
-        mDisplayTypeCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        // add the combo values. This must match the values EventDisplay.DISPLAY_TYPE_*
-        mDisplayTypeCombo.add("Log All");
-        mDisplayTypeCombo.add("Filtered Log");
-        mDisplayTypeCombo.add("Graph");
-        mDisplayTypeCombo.add("Sync");
-        mDisplayTypeCombo.add("Sync Histogram");
-        mDisplayTypeCombo.add("Sync Performance");
-        mDisplayTypeCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null && eventDisplay.getDisplayType() != mDisplayTypeCombo.getSelectionIndex()) {
-                    /* Replace the EventDisplay object with a different subclass */
-                    setModified();
-                    String name = eventDisplay.getName();
-                    EventDisplay newEventDisplay = EventDisplay.eventDisplayFactory(mDisplayTypeCombo.getSelectionIndex(), name);
-                    setCurrentEventDisplay(newEventDisplay);
-                    fillUiWith(newEventDisplay);
-                }
-            }
-        });
-        
-        mChartOptions = new Group(mInfoGroup, SWT.NONE);
-        mChartOptions.setText("Chart Options");
-        GridData gd;
-        mChartOptions.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 2;
-        mChartOptions.setLayout(new GridLayout(2, false));
-        
-        Label l = new Label(mChartOptions, SWT.NONE);
-        l.setText("Time Limit (seconds):");
-        
-        mTimeLimitText = new Text(mChartOptions, SWT.BORDER);
-        mTimeLimitText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mTimeLimitText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent arg0) {
-                String text = mTimeLimitText.getText().trim();
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null) {
-                    try {
-                        if (text.length() == 0) {
-                            eventDisplay.resetChartTimeLimit();
-                        } else {
-                            eventDisplay.setChartTimeLimit(Long.parseLong(text));
-                        }
-                    } catch (NumberFormatException nfe) {
-                        eventDisplay.resetChartTimeLimit();
-                    } finally {
-                        setModified();
-                    }
-                }
-            }
-        });
-
-        mHistOptions = new Group(mInfoGroup, SWT.NONE);
-        mHistOptions.setText("Histogram Options");
-        GridData gdh;
-        mHistOptions.setLayoutData(gdh = new GridData(GridData.FILL_HORIZONTAL));
-        gdh.horizontalSpan = 2;
-        mHistOptions.setLayout(new GridLayout(2, false));
-        
-        Label lh = new Label(mHistOptions, SWT.NONE);
-        lh.setText("Histogram width (hours):");
-        
-        mHistWidthText = new Text(mHistOptions, SWT.BORDER);
-        mHistWidthText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mHistWidthText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent arg0) {
-                String text = mHistWidthText.getText().trim();
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null) {
-                    try {
-                        if (text.length() == 0) {
-                            eventDisplay.resetHistWidth();
-                        } else {
-                            eventDisplay.setHistWidth(Long.parseLong(text));
-                        }
-                    } catch (NumberFormatException nfe) {
-                        eventDisplay.resetHistWidth();
-                    } finally {
-                        setModified();
-                    }
-                }
-            }
-        });
-
-        mPidFilterCheckBox = new Button(mInfoGroup, SWT.CHECK);
-        mPidFilterCheckBox.setText("Enable filtering by pid");
-        mPidFilterCheckBox.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 2;
-        mPidFilterCheckBox.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null) {
-                    eventDisplay.setPidFiltering(mPidFilterCheckBox.getSelection());
-                    mPidText.setEnabled(mPidFilterCheckBox.getSelection());
-                    setModified();
-                }
-            }
-        });
-
-        Label pidLabel = new Label(mInfoGroup, SWT.NONE);
-        pidLabel.setText("Pid Filter:");
-        pidLabel.setToolTipText("Enter all pids, separated by commas");
-        
-        mPidText = new Text(mInfoGroup, SWT.BORDER);
-        mPidText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mPidText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                if (mProcessTextChanges) {
-                    EventDisplay eventDisplay = getCurrentEventDisplay();
-                    if (eventDisplay != null && eventDisplay.getPidFiltering()) {
-                        String pidText = mPidText.getText().trim();
-                        String[] pids = pidText.split("\\s*,\\s*"); //$NON-NLS-1$
-    
-                        ArrayList<Integer> list = new ArrayList<Integer>();
-                        for (String pid : pids) {
-                            try {
-                                list.add(Integer.valueOf(pid));
-                            } catch (NumberFormatException nfe) {
-                                // just ignore non valid pid
-                            }
-                        }
-                        
-                        eventDisplay.setPidFilterList(list);
-                        setModified();
-                    }
-                }
-            }
-        });
-        
-        /* ------------------
-         * EVENT VALUE/OCCURRENCE SELECTION
-         * ------------------ */
-        mValueSelection = createEventSelection(rightPanel, ValueDisplayDescriptor.class,
-                "Event Value Display");
-        mOccurrenceSelection = createEventSelection(rightPanel, OccurrenceDisplayDescriptor.class,
-                "Event Occurrence Display");
-    }
-
-    private SelectionWidgets createEventSelection(Composite rightPanel,
-            final Class<? extends OccurrenceDisplayDescriptor> descriptorClass,
-            String groupMessage) {
-
-        Group eventSelectionPanel = new Group(rightPanel, SWT.NONE);
-        eventSelectionPanel.setLayoutData(new GridData(GridData.FILL_BOTH));
-        GridLayout gl;
-        eventSelectionPanel.setLayout(gl = new GridLayout(2, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        eventSelectionPanel.setText(groupMessage);
-        
-        final SelectionWidgets widgets = new SelectionWidgets();
-        
-        widgets.mList = new List(eventSelectionPanel, SWT.BORDER | SWT.SINGLE | SWT.V_SCROLL);
-        widgets.mList.setLayoutData(new GridData(GridData.FILL_BOTH));
-        widgets.mList.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                int index = widgets.mList.getSelectionIndex();
-                if (index != -1) {
-                    widgets.mDeleteButton.setEnabled(true);
-                    widgets.mEditButton.setEnabled(true);
-                } else {
-                    widgets.mDeleteButton.setEnabled(false);
-                    widgets.mEditButton.setEnabled(false);
-                }
-            }
-        });
-
-        Composite rightControls = new Composite(eventSelectionPanel, SWT.NONE);
-        rightControls.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-        rightControls.setLayout(gl = new GridLayout(1, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        gl.verticalSpacing = 0;
-        gl.horizontalSpacing = 0;
-
-        widgets.mNewButton = new Button(rightControls, SWT.PUSH | SWT.FLAT);
-        widgets.mNewButton.setText("New...");
-        widgets.mNewButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        widgets.mNewButton.setEnabled(false);
-        widgets.mNewButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // current event
-                try {
-                    EventDisplay eventDisplay = getCurrentEventDisplay();
-                    if (eventDisplay != null) {
-                        EventValueSelector dialog = new EventValueSelector(mShell);
-                        if (dialog.open(descriptorClass, mLogParser)) {
-                            eventDisplay.addDescriptor(dialog.getDescriptor());
-                            fillUiWith(eventDisplay);
-                            setModified();
-                        }
-                    }
-                } catch (Exception e1) {
-                    e1.printStackTrace();
-                }
-            }
-        });
-
-        widgets.mEditButton = new Button(rightControls, SWT.PUSH | SWT.FLAT);
-        widgets.mEditButton.setText("Edit...");
-        widgets.mEditButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        widgets.mEditButton.setEnabled(false);
-        widgets.mEditButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // current event
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null) {
-                    // get the current descriptor index
-                    int index = widgets.mList.getSelectionIndex();
-                    if (index != -1) {
-                        // get the descriptor itself
-                        OccurrenceDisplayDescriptor descriptor = eventDisplay.getDescriptor(
-                                descriptorClass, index);
-    
-                        // open the edit dialog.
-                        EventValueSelector dialog = new EventValueSelector(mShell);
-                        if (dialog.open(descriptor, mLogParser)) {
-                            descriptor.replaceWith(dialog.getDescriptor());
-                            eventDisplay.updateValueDescriptorCheck();
-                            fillUiWith(eventDisplay);
-
-                            // reselect the item since fillUiWith remove the selection.
-                            widgets.mList.select(index);
-                            widgets.mList.notifyListeners(SWT.Selection, null);
-                            
-                            setModified();
-                        }
-                    }
-                }
-            }
-        });
-
-        widgets.mDeleteButton = new Button(rightControls, SWT.PUSH | SWT.FLAT);
-        widgets.mDeleteButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        widgets.mDeleteButton.setText("Delete");
-        widgets.mDeleteButton.setEnabled(false);
-        widgets.mDeleteButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // current event
-                EventDisplay eventDisplay = getCurrentEventDisplay();
-                if (eventDisplay != null) {
-                    // get the current descriptor index
-                    int index = widgets.mList.getSelectionIndex();
-                    if (index != -1) {
-                        eventDisplay.removeDescriptor(descriptorClass, index);
-                        fillUiWith(eventDisplay);
-                        setModified();
-                    }
-                }
-            }
-        });
-
-        return widgets;
-    }
-   
-    
-    private void duplicateEventDisplay(ArrayList<EventDisplay> displayList) {
-        for (EventDisplay eventDisplay : displayList) {
-            mDisplayList.add(EventDisplay.clone(eventDisplay));
-        }
-    }
-    
-    private void buildPidList(ArrayList<EventContainer> eventList) {
-        mPidList = new ArrayList<Integer>();
-        for (EventContainer event : eventList) {
-            if (mPidList.indexOf(event.pid) == -1) {
-                mPidList.add(event.pid);
-            }
-        }
-    }
-
-    private void setModified() {
-        mEditStatus = true;
-    }
-
-    
-    private void enable(boolean status) {
-        mEventDisplayDeleteButton.setEnabled(status);
-
-        // enable up/down
-        int selection = mEventDisplayList.getSelectionIndex();
-        int count = mEventDisplayList.getItemCount();
-        mEventDisplayUpButton.setEnabled(status && selection > 0);
-        mEventDisplayDownButton.setEnabled(status && selection != -1 && selection < count - 1);
-
-        mDisplayNameText.setEnabled(status);
-        mDisplayTypeCombo.setEnabled(status);
-        mPidFilterCheckBox.setEnabled(status);
-
-        mValueSelection.setEnabled(status);
-        mOccurrenceSelection.setEnabled(status);
-        mValueSelection.mNewButton.setEnabled(status);
-        mOccurrenceSelection.mNewButton.setEnabled(status);
-        if (status == false) {
-            mPidText.setEnabled(false);
-        }
-    }
-    
-    private void fillEventDisplayList() {
-        for (EventDisplay eventDisplay : mDisplayList) {
-            mEventDisplayList.add(eventDisplay.getName());
-        }
-    }
-    
-    private void createNewEventDisplay() {
-        int count = mDisplayList.size();
-        
-        String name = String.format("display %1$d", count + 1);
-        
-        EventDisplay eventDisplay = EventDisplay.eventDisplayFactory(0 /* type*/, name);
-        
-        mDisplayList.add(eventDisplay);
-        mEventDisplayList.add(name);
-        
-        mEventDisplayList.select(count);
-        handleEventDisplaySelection();
-        mEventDisplayList.showSelection();
-        
-        setModified();
-    }
-    
-    private void deleteEventDisplay() {
-        int selection = mEventDisplayList.getSelectionIndex();
-        if (selection != -1) {
-            mDisplayList.remove(selection);
-            mEventDisplayList.remove(selection);
-            if (mDisplayList.size() < selection) {
-                selection--;
-            }
-            mEventDisplayList.select(selection);
-            handleEventDisplaySelection();
-
-            setModified();
-        }
-    }
-
-    private EventDisplay getCurrentEventDisplay() {
-        int selection = mEventDisplayList.getSelectionIndex();
-        if (selection != -1) {
-            return mDisplayList.get(selection);
-        }
-        
-        return null;
-    }
-
-    private void setCurrentEventDisplay(EventDisplay eventDisplay) {
-        int selection = mEventDisplayList.getSelectionIndex();
-        if (selection != -1) {
-            mDisplayList.set(selection, eventDisplay);
-        }
-    }
-    
-    private void handleEventDisplaySelection() {
-        EventDisplay eventDisplay = getCurrentEventDisplay();
-        if (eventDisplay != null) {
-            // enable the UI
-            enable(true);
-
-            // and fill it
-            fillUiWith(eventDisplay);
-        } else {
-            // disable the UI
-            enable(false);
-
-            // and empty it.
-            emptyUi();
-        }
-    }
-
-    private void emptyUi() {
-        mDisplayNameText.setText("");
-        mDisplayTypeCombo.clearSelection();
-        mValueSelection.mList.removeAll();
-        mOccurrenceSelection.mList.removeAll();
-    }
-
-    private void fillUiWith(EventDisplay eventDisplay) {
-        mProcessTextChanges = false;
-
-        mDisplayNameText.setText(eventDisplay.getName());
-        int displayMode = eventDisplay.getDisplayType();
-        mDisplayTypeCombo.select(displayMode);
-        if (displayMode == EventDisplay.DISPLAY_TYPE_GRAPH) {
-            GridData gd = (GridData) mChartOptions.getLayoutData();
-            gd.exclude = false;
-            mChartOptions.setVisible(!gd.exclude);
-            long limit = eventDisplay.getChartTimeLimit();
-            if (limit != -1) {
-                mTimeLimitText.setText(Long.toString(limit));
-            } else {
-                mTimeLimitText.setText(""); //$NON-NLS-1$
-            }
-        } else {
-            GridData gd = (GridData) mChartOptions.getLayoutData();
-            gd.exclude = true;
-            mChartOptions.setVisible(!gd.exclude);
-            mTimeLimitText.setText(""); //$NON-NLS-1$
-        }
-
-        if (displayMode == EventDisplay.DISPLAY_TYPE_SYNC_HIST) {
-            GridData gd = (GridData) mHistOptions.getLayoutData();
-            gd.exclude = false;
-            mHistOptions.setVisible(!gd.exclude);
-            long limit = eventDisplay.getHistWidth();
-            if (limit != -1) {
-                mHistWidthText.setText(Long.toString(limit));
-            } else {
-                mHistWidthText.setText(""); //$NON-NLS-1$
-            }
-        } else {
-            GridData gd = (GridData) mHistOptions.getLayoutData();
-            gd.exclude = true;
-            mHistOptions.setVisible(!gd.exclude);
-            mHistWidthText.setText(""); //$NON-NLS-1$
-        }
-        mInfoGroup.layout(true);
-        mShell.layout(true);
-        mShell.pack();
-        
-        if (eventDisplay.getPidFiltering()) {
-            mPidFilterCheckBox.setSelection(true);
-            mPidText.setEnabled(true);
-
-            // build the pid list.
-            ArrayList<Integer> list = eventDisplay.getPidFilterList();
-            if (list != null) {
-                StringBuilder sb = new StringBuilder();
-                int count = list.size();
-                for (int i = 0 ; i < count ; i++) {
-                    sb.append(list.get(i));
-                    if (i < count - 1) {
-                        sb.append(", ");//$NON-NLS-1$
-                    }
-                }
-                mPidText.setText(sb.toString());
-            } else {
-                mPidText.setText(""); //$NON-NLS-1$
-            }
-        } else {
-            mPidFilterCheckBox.setSelection(false);
-            mPidText.setEnabled(false);
-            mPidText.setText(""); //$NON-NLS-1$
-        }
-
-        mProcessTextChanges = true;
-
-        mValueSelection.mList.removeAll();
-        mOccurrenceSelection.mList.removeAll();
-        
-        if (eventDisplay.getDisplayType() == EventDisplay.DISPLAY_TYPE_FILTERED_LOG ||
-                eventDisplay.getDisplayType() == EventDisplay.DISPLAY_TYPE_GRAPH) {
-            mOccurrenceSelection.setEnabled(true);
-            mValueSelection.setEnabled(true);
-
-            Iterator<ValueDisplayDescriptor> valueIterator = eventDisplay.getValueDescriptors();
-    
-            while (valueIterator.hasNext()) {
-                ValueDisplayDescriptor descriptor = valueIterator.next();
-                mValueSelection.mList.add(String.format("%1$s: %2$s [%3$s]%4$s",
-                        mEventTagMap.get(descriptor.eventTag), descriptor.valueName,
-                        getSeriesLabelDescription(descriptor), getFilterDescription(descriptor)));
-            }
-
-            Iterator<OccurrenceDisplayDescriptor> occurrenceIterator =
-                eventDisplay.getOccurrenceDescriptors();
-    
-            while (occurrenceIterator.hasNext()) {
-                OccurrenceDisplayDescriptor descriptor = occurrenceIterator.next();
-    
-                mOccurrenceSelection.mList.add(String.format("%1$s [%2$s]%3$s",
-                        mEventTagMap.get(descriptor.eventTag),
-                        getSeriesLabelDescription(descriptor),
-                        getFilterDescription(descriptor)));
-            }
-
-            mValueSelection.mList.notifyListeners(SWT.Selection, null);
-            mOccurrenceSelection.mList.notifyListeners(SWT.Selection, null);
-        } else {
-            mOccurrenceSelection.setEnabled(false);
-            mValueSelection.setEnabled(false);
-        }
-        
-    }
-    
-    /**
-     * Returns a String describing what is used as the series label
-     * @param descriptor the descriptor of the display.
-     */
-    private String getSeriesLabelDescription(OccurrenceDisplayDescriptor descriptor) {
-        if (descriptor.seriesValueIndex != -1) {
-            if (descriptor.includePid) {
-                return String.format("%1$s + pid",
-                        mEventDescriptionMap.get(
-                                descriptor.eventTag)[descriptor.seriesValueIndex].getName());
-            } else {
-                return mEventDescriptionMap.get(descriptor.eventTag)[descriptor.seriesValueIndex]
-                                                                     .getName();
-            }
-        }
-        return "pid";
-    }
-    
-    private String getFilterDescription(OccurrenceDisplayDescriptor descriptor) {
-        if (descriptor.filterValueIndex != -1) {
-            return String.format(" [%1$s %2$s %3$s]",
-                    mEventDescriptionMap.get(
-                            descriptor.eventTag)[descriptor.filterValueIndex].getName(),
-                            descriptor.filterCompareMethod.testString(),
-                            descriptor.filterValue != null ?
-                                    descriptor.filterValue.toString() : "?"); //$NON-NLS-1$
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogImporter.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogImporter.java
deleted file mode 100644
index a1303f6..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogImporter.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.Log;
-
-import java.io.BufferedReader;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-
-/**
- * Imports a textual event log.  Gets tags from build path.
- */
-public class EventLogImporter {
-
-    private String[] mTags;
-    private String[] mLog;
-
-    public EventLogImporter(String filePath) throws FileNotFoundException {
-        String top = System.getenv("ANDROID_BUILD_TOP");
-        if (top == null) {
-            throw new FileNotFoundException();
-        }
-        final String tagFile = top + "/system/core/logcat/event-log-tags";
-        BufferedReader tagReader = new BufferedReader(
-                new InputStreamReader(new FileInputStream(tagFile)));
-        BufferedReader eventReader = new BufferedReader(
-                new InputStreamReader(new FileInputStream(filePath)));
-        try {
-            readTags(tagReader);
-            readLog(eventReader);
-        } catch (IOException e) {
-        }
-    }
-
-    public String[] getTags() {
-        return mTags;
-    }
-
-    public String[] getLog() {
-        return mLog;
-    }
-
-    private void readTags(BufferedReader reader) throws IOException {
-        String line;
-
-        ArrayList<String> content = new ArrayList<String>();
-        while ((line = reader.readLine()) != null) {
-            content.add(line);
-        }
-        mTags = content.toArray(new String[content.size()]);
-    }
-
-    private void readLog(BufferedReader reader) throws IOException {
-        String line;
-
-        ArrayList<String> content = new ArrayList<String>();
-        while ((line = reader.readLine()) != null) {
-            content.add(line);
-        }
-
-        mLog = content.toArray(new String[content.size()]);
-    }
-
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogPanel.java
deleted file mode 100644
index 2621c6a..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventLogPanel.java
+++ /dev/null
@@ -1,926 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.LogReceiver;
-import com.android.ddmlib.log.LogReceiver.ILogListener;
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.IImageLoader;
-import com.android.ddmuilib.TablePanel;
-import com.android.ddmuilib.actions.ICommonAction;
-import com.android.ddmuilib.annotation.UiThread;
-import com.android.ddmuilib.annotation.WorkerThread;
-import com.android.ddmuilib.log.event.EventDisplay.ILogColumnListener;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.RowData;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.text.NumberFormat;
-import java.util.ArrayList;
-import java.util.regex.Pattern;
-
-/**
- * Event log viewer
- */
-public class EventLogPanel extends TablePanel implements ILogListener,
-        ILogColumnListener {
-
-    private final static String TAG_FILE_EXT = ".tag"; //$NON-NLS-1$
-
-    private final static String PREFS_EVENT_DISPLAY = "EventLogPanel.eventDisplay"; //$NON-NLS-1$
-    private final static String EVENT_DISPLAY_STORAGE_SEPARATOR = "|"; //$NON-NLS-1$
-
-    static final String PREFS_DISPLAY_WIDTH = "EventLogPanel.width"; //$NON-NLS-1$
-    static final String PREFS_DISPLAY_HEIGHT = "EventLogPanel.height"; //$NON-NLS-1$
-
-    private final static int DEFAULT_DISPLAY_WIDTH = 500;
-    private final static int DEFAULT_DISPLAY_HEIGHT = 400;
-
-    private IImageLoader mImageLoader;
-
-    private Device mCurrentLoggedDevice;
-    private String mCurrentLogFile;
-    private LogReceiver mCurrentLogReceiver;
-    private EventLogParser mCurrentEventLogParser;
-
-    private Object mLock = new Object();
-
-    /** list of all the events. */
-    private final ArrayList<EventContainer> mEvents = new ArrayList<EventContainer>();
-
-    /** list of all the new events, that have yet to be displayed by the ui */
-    private final ArrayList<EventContainer> mNewEvents = new ArrayList<EventContainer>();
-    /** indicates a pending ui thread display */
-    private boolean mPendingDisplay = false;
-    
-    /** list of all the custom event displays */
-    private final ArrayList<EventDisplay> mEventDisplays = new ArrayList<EventDisplay>();
-
-    private final NumberFormat mFormatter = NumberFormat.getInstance();
-    private Composite mParent;
-    private ScrolledComposite mBottomParentPanel;
-    private Composite mBottomPanel;
-    private ICommonAction mOptionsAction;
-    private ICommonAction mClearAction;
-    private ICommonAction mSaveAction;
-    private ICommonAction mLoadAction;
-    private ICommonAction mImportAction;
-    
-    /** file containing the current log raw data. */
-    private File mTempFile = null;
-
-    public EventLogPanel(IImageLoader imageLoader) {
-        super();
-        mImageLoader = imageLoader;
-        mFormatter.setGroupingUsed(true);
-    }
-
-    /**
-     * Sets the external actions.
-     * <p/>This method sets up the {@link ICommonAction} objects to execute the proper code
-     * when triggered by using {@link ICommonAction#setRunnable(Runnable)}.
-     * <p/>It will also make sure they are enabled only when possible.
-     * @param optionsAction
-     * @param clearAction
-     * @param saveAction
-     * @param loadAction
-     * @param importAction
-     */
-    public void setActions(ICommonAction optionsAction, ICommonAction clearAction,
-            ICommonAction saveAction, ICommonAction loadAction, ICommonAction importAction) {
-        mOptionsAction = optionsAction;
-        mOptionsAction.setRunnable(new Runnable() {
-            public void run() {
-                openOptionPanel();
-            }
-        });
-
-        mClearAction = clearAction;
-        mClearAction.setRunnable(new Runnable() {
-            public void run() {
-                clearLog();
-            }
-        });
-
-        mSaveAction = saveAction;
-        mSaveAction.setRunnable(new Runnable() {
-            public void run() {
-                try {
-                    FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.SAVE);
-
-                    fileDialog.setText("Save Event Log");
-                    fileDialog.setFileName("event.log");
-
-                    String fileName = fileDialog.open();
-                    if (fileName != null) {
-                        saveLog(fileName);
-                    }
-                } catch (IOException e1) {
-                }
-            }
-        });
-
-        mLoadAction = loadAction;
-        mLoadAction.setRunnable(new Runnable() {
-            public void run() {
-                FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.OPEN);
-
-                fileDialog.setText("Load Event Log");
-
-                String fileName = fileDialog.open();
-                if (fileName != null) {
-                    loadLog(fileName);
-                }
-            }
-        });
-
-        mImportAction = importAction;
-        mImportAction.setRunnable(new Runnable() {
-            public void run() {
-                FileDialog fileDialog = new FileDialog(mParent.getShell(), SWT.OPEN);
-
-                fileDialog.setText("Import Bug Report");
-
-                String fileName = fileDialog.open();
-                if (fileName != null) {
-                    importBugReport(fileName);
-                }
-            }
-        });
-
-        mOptionsAction.setEnabled(false);
-        mClearAction.setEnabled(false);
-        mSaveAction.setEnabled(false);
-    }
-
-    /**
-     * Opens the option panel.
-     * </p>
-     * <b>This must be called from the UI thread</b>
-     */
-    @UiThread
-    public void openOptionPanel() {
-        try {
-            EventDisplayOptions dialog = new EventDisplayOptions(mImageLoader, mParent.getShell());
-            if (dialog.open(mCurrentEventLogParser, mEventDisplays, mEvents)) {
-                synchronized (mLock) {
-                    // get the new EventDisplay list
-                    mEventDisplays.clear();
-                    mEventDisplays.addAll(dialog.getEventDisplays());
-                    
-                    // since the list of EventDisplay changed, we store it.
-                    saveEventDisplays();
-                    
-                    rebuildUi();
-                }
-            }
-        } catch (SWTException e) {
-            Log.e("EventLog", e); //$NON-NLS-1$
-        }
-    }
-    
-    /**
-     * Clears the log.
-     * <p/>
-     * <b>This must be called from the UI thread</b>
-     */
-    public void clearLog() {
-        try {
-            synchronized (mLock) {
-                mEvents.clear();
-                mNewEvents.clear();
-                mPendingDisplay = false;
-                for (EventDisplay eventDisplay : mEventDisplays) {
-                    eventDisplay.resetUI();
-                }
-            }
-        } catch (SWTException e) {
-            Log.e("EventLog", e); //$NON-NLS-1$
-        }
-    }
-    
-    /**
-     * Saves the content of the event log into a file. The log is saved in the same
-     * binary format than on the device.
-     * @param filePath
-     * @throws IOException
-     */
-    public void saveLog(String filePath) throws IOException {
-        if (mCurrentLoggedDevice != null && mCurrentEventLogParser != null) {
-            File destFile = new File(filePath);
-            destFile.createNewFile();
-            FileInputStream fis = new FileInputStream(mTempFile);
-            FileOutputStream fos = new FileOutputStream(destFile);
-            byte[] buffer = new byte[1024];
-            
-            int count;
-            
-            while ((count = fis.read(buffer)) != -1) {
-                fos.write(buffer, 0, count);
-            }
-            
-            fos.close();
-            fis.close();
-            
-            // now we save the tag file
-            filePath = filePath + TAG_FILE_EXT;
-            mCurrentEventLogParser.saveTags(filePath);
-        }
-    }
-
-    /**
-     * Loads a binary event log (if has associated .tag file) or
-     * otherwise loads a textual event log.
-     * @param filePath Event log path (and base of potential tag file)
-     */
-    public void loadLog(String filePath) {
-        if ((new File(filePath + TAG_FILE_EXT)).exists()) {
-            startEventLogFromFiles(filePath);
-        } else {
-            try {
-                EventLogImporter importer = new EventLogImporter(filePath);
-                String[] tags = importer.getTags();
-                String[] log = importer.getLog();
-                startEventLogFromContent(tags, log);
-            } catch (FileNotFoundException e) {
-                // If this fails, display the error message from startEventLogFromFiles,
-                // and pretend we never tried EventLogImporter
-                Log.logAndDisplay(Log.LogLevel.ERROR, "EventLog",
-                        String.format("Failure to read %1$s", filePath + TAG_FILE_EXT));
-            }
-
-        }
-    }
-    
-    public void importBugReport(String filePath) {
-        try {
-            BugReportImporter importer = new BugReportImporter(filePath);
-            
-            String[] tags = importer.getTags();
-            String[] log = importer.getLog();
-            
-            startEventLogFromContent(tags, log);
-            
-        } catch (FileNotFoundException e) {
-            Log.logAndDisplay(LogLevel.ERROR, "Import",
-                    "Unable to import bug report: " + e.getMessage());
-        }
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmuilib.SelectionDependentPanel#clientSelected()
-     */
-    @Override
-    public void clientSelected() {
-        // pass
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmuilib.SelectionDependentPanel#deviceSelected()
-     */
-    @Override
-    public void deviceSelected() {
-        startEventLog(getCurrentDevice());
-    }
-    
-    /*
-     * (non-Javadoc)
-     * @see com.android.ddmlib.AndroidDebugBridge.IClientChangeListener#clientChanged(com.android.ddmlib.Client, int)
-     */
-    public void clientChanged(Client client, int changeMask) {
-        // pass
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmuilib.Panel#createControl(org.eclipse.swt.widgets.Composite)
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mParent = parent;
-        mParent.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                synchronized (mLock) {
-                    if (mCurrentLogReceiver != null) {
-                        mCurrentLogReceiver.cancel();
-                        mCurrentLogReceiver = null;
-                        mCurrentEventLogParser = null;
-                        mCurrentLoggedDevice = null;
-                        mEventDisplays.clear();
-                        mEvents.clear();
-                    }
-                }
-            }
-        });
-
-        final IPreferenceStore store = DdmUiPreferences.getStore();
-
-        // init some store stuff
-        store.setDefault(PREFS_DISPLAY_WIDTH, DEFAULT_DISPLAY_WIDTH);
-        store.setDefault(PREFS_DISPLAY_HEIGHT, DEFAULT_DISPLAY_HEIGHT);
-        
-        mBottomParentPanel = new ScrolledComposite(parent, SWT.V_SCROLL);
-        mBottomParentPanel.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mBottomParentPanel.setExpandHorizontal(true);
-        mBottomParentPanel.setExpandVertical(true);
-
-        mBottomParentPanel.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                if (mBottomPanel != null) {
-                    Rectangle r = mBottomParentPanel.getClientArea();
-                    mBottomParentPanel.setMinSize(mBottomPanel.computeSize(r.width,
-                        SWT.DEFAULT));
-                }
-            }
-        });
-
-        prepareDisplayUi();
-
-        // load the EventDisplay from storage.
-        loadEventDisplays();
-
-        // create the ui
-        createDisplayUi();
-        
-        return mBottomParentPanel;
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmuilib.Panel#postCreation()
-     */
-    @Override
-    protected void postCreation() {
-        // pass
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ddmuilib.Panel#setFocus()
-     */
-    @Override
-    public void setFocus() {
-        mBottomParentPanel.setFocus();
-    }
-    
-    /**
-     * Starts a new logcat and set mCurrentLogCat as the current receiver.
-     * @param device the device to connect logcat to.
-     */
-    private void startEventLog(final Device device) {
-        if (device == mCurrentLoggedDevice) {
-            return;
-        }
-
-        // if we have a logcat already running
-        if (mCurrentLogReceiver != null) {
-            stopEventLog(false);
-        }
-        mCurrentLoggedDevice = null;
-        mCurrentLogFile = null;
-
-        if (device != null) {
-            // create a new output receiver
-            mCurrentLogReceiver = new LogReceiver(this);
-
-            // start the logcat in a different thread
-            new Thread("EventLog")  { //$NON-NLS-1$
-                @Override
-                public void run() {
-                    while (device.isOnline() == false &&
-                            mCurrentLogReceiver != null &&
-                            mCurrentLogReceiver.isCancelled() == false) {
-                        try {
-                            sleep(2000);
-                        } catch (InterruptedException e) {
-                            return;
-                        }
-                    }
-
-                    if (mCurrentLogReceiver == null || mCurrentLogReceiver.isCancelled()) {
-                        // logcat was stopped/cancelled before the device became ready.
-                        return;
-                    }
-
-                    try {
-                        mCurrentLoggedDevice = device;
-                        synchronized (mLock) {
-                            mCurrentEventLogParser = new EventLogParser();
-                            mCurrentEventLogParser.init(device);
-                        }
-                        
-                        // update the event display with the new parser.
-                        updateEventDisplays();
-                        
-                        // prepare the temp file that will contain the raw data
-                        mTempFile = File.createTempFile("android-event-", ".log");
-
-                        device.runEventLogService(mCurrentLogReceiver);
-                    } catch (Exception e) {
-                        Log.e("EventLog", e);
-                    } finally {
-                    }
-                }
-            }.start();
-        }
-    }
-    
-    private void startEventLogFromFiles(final String fileName) {
-        // if we have a logcat already running
-        if (mCurrentLogReceiver != null) {
-            stopEventLog(false);
-        }
-        mCurrentLoggedDevice = null;
-        mCurrentLogFile = null;
-
-        // create a new output receiver
-        mCurrentLogReceiver = new LogReceiver(this);
-        
-        mSaveAction.setEnabled(false);
-
-        // start the logcat in a different thread
-        new Thread("EventLog")  { //$NON-NLS-1$
-            @Override
-            public void run() {
-                try {
-                    mCurrentLogFile = fileName;
-                    synchronized (mLock) {
-                        mCurrentEventLogParser = new EventLogParser();
-                        if (mCurrentEventLogParser.init(fileName + TAG_FILE_EXT) == false) {
-                            mCurrentEventLogParser = null;
-                            Log.logAndDisplay(LogLevel.ERROR, "EventLog",
-                                    String.format("Failure to read %1$s", fileName + TAG_FILE_EXT));
-                            return;
-                        }
-                    }
-                    
-                    // update the event display with the new parser.
-                    updateEventDisplays();
-                    
-                    runLocalEventLogService(fileName, mCurrentLogReceiver);
-                } catch (Exception e) {
-                    Log.e("EventLog", e);
-                } finally {
-                }
-            }
-        }.start();
-    }
-
-    private void startEventLogFromContent(final String[] tags, final String[] log) {
-        // if we have a logcat already running
-        if (mCurrentLogReceiver != null) {
-            stopEventLog(false);
-        }
-        mCurrentLoggedDevice = null;
-        mCurrentLogFile = null;
-
-        // create a new output receiver
-        mCurrentLogReceiver = new LogReceiver(this);
-        
-        mSaveAction.setEnabled(false);
-
-        // start the logcat in a different thread
-        new Thread("EventLog")  { //$NON-NLS-1$
-            @Override
-            public void run() {
-                try {
-                    synchronized (mLock) {
-                        mCurrentEventLogParser = new EventLogParser();
-                        if (mCurrentEventLogParser.init(tags) == false) {
-                            mCurrentEventLogParser = null;
-                            return;
-                        }
-                    }
-                    
-                    // update the event display with the new parser.
-                    updateEventDisplays();
-                    
-                    runLocalEventLogService(log, mCurrentLogReceiver);
-                } catch (Exception e) {
-                    Log.e("EventLog", e);
-                } finally {
-                }
-            }
-        }.start();
-    }
-
-
-    public void stopEventLog(boolean inUiThread) {
-        if (mCurrentLogReceiver != null) {
-            mCurrentLogReceiver.cancel();
-
-            // when the thread finishes, no one will reference that object
-            // and it'll be destroyed
-            synchronized (mLock) {
-                mCurrentLogReceiver = null;
-                mCurrentEventLogParser = null;
-
-                mCurrentLoggedDevice = null;
-                mEvents.clear();
-                mNewEvents.clear();
-                mPendingDisplay = false;
-            }
-
-            resetUI(inUiThread);
-        }
-        
-        if (mTempFile != null) {
-            mTempFile.delete();
-            mTempFile = null;
-        }
-    }
-
-    private void resetUI(boolean inUiThread) {
-        mEvents.clear();
-
-        // the ui is static we just empty it.
-        if (inUiThread) {
-            resetUiFromUiThread();
-        } else {
-            try {
-                Display d = mBottomParentPanel.getDisplay();
-
-                // run sync as we need to update right now.
-                d.syncExec(new Runnable() {
-                    public void run() {
-                        if (mBottomParentPanel.isDisposed() == false) {
-                            resetUiFromUiThread();
-                        }
-                    }
-                });
-            } catch (SWTException e) {
-                // display is disposed, we're quitting. Do nothing.
-            }
-        }
-    }
-    
-    private void resetUiFromUiThread() {
-        synchronized(mLock) {
-            for (EventDisplay eventDisplay : mEventDisplays) {
-                eventDisplay.resetUI();
-            }
-        }
-        mOptionsAction.setEnabled(false);
-        mClearAction.setEnabled(false);
-        mSaveAction.setEnabled(false);
-    }
-
-    private void prepareDisplayUi() {
-        mBottomPanel = new Composite(mBottomParentPanel, SWT.NONE);
-        mBottomParentPanel.setContent(mBottomPanel);
-    }
-
-    private void createDisplayUi() {
-        RowLayout rowLayout = new RowLayout();
-        rowLayout.wrap = true;
-        rowLayout.pack = false;
-        rowLayout.justify = true;
-        rowLayout.fill = true;
-        rowLayout.type = SWT.HORIZONTAL;
-        mBottomPanel.setLayout(rowLayout);
-        
-        IPreferenceStore store = DdmUiPreferences.getStore();
-        int displayWidth = store.getInt(PREFS_DISPLAY_WIDTH);
-        int displayHeight = store.getInt(PREFS_DISPLAY_HEIGHT);
-        
-        for (EventDisplay eventDisplay : mEventDisplays) {
-            Control c = eventDisplay.createComposite(mBottomPanel, mCurrentEventLogParser, this);
-            if (c != null) {
-                RowData rd = new RowData();
-                rd.height = displayHeight;
-                rd.width = displayWidth;
-                c.setLayoutData(rd);
-            }
-            
-            Table table = eventDisplay.getTable();
-            if (table != null) {
-                addTableToFocusListener(table);
-            }
-        }
-
-        mBottomPanel.layout();
-        mBottomParentPanel.setMinSize(mBottomPanel.computeSize(SWT.DEFAULT, SWT.DEFAULT));
-        mBottomParentPanel.layout();
-    }
-    
-    /**
-     * Rebuild the display ui.
-     */
-    @UiThread
-    private void rebuildUi() {
-        synchronized (mLock) {
-            // we need to rebuild the ui. First we get rid of it.
-            mBottomPanel.dispose();
-            mBottomPanel = null;
-            
-            prepareDisplayUi();
-            createDisplayUi();
-            
-            // and fill it
-            
-            boolean start_event = false;
-            synchronized (mNewEvents) {
-                mNewEvents.addAll(0, mEvents);
-                
-                if (mPendingDisplay == false) {
-                    mPendingDisplay = true;
-                    start_event = true;
-                }
-            }
-            
-            if (start_event) {
-                scheduleUIEventHandler();
-            }
-            
-            Rectangle r = mBottomParentPanel.getClientArea();
-            mBottomParentPanel.setMinSize(mBottomPanel.computeSize(r.width,
-                SWT.DEFAULT));
-        }
-    }
-
-
-    /**
-     * Processes a new {@link LogEntry} by parsing it with {@link EventLogParser} and displaying it.
-     * @param entry The new log entry
-     * @see LogReceiver.ILogListener#newEntry(LogEntry) 
-     */
-    @WorkerThread
-    public void newEntry(LogEntry entry) {
-        synchronized (mLock) {
-            if (mCurrentEventLogParser != null) {
-                EventContainer event = mCurrentEventLogParser.parse(entry);
-                if (event != null) {
-                    handleNewEvent(event);
-                }
-            }
-        }
-    }
-    
-    @WorkerThread
-    private void handleNewEvent(EventContainer event) {
-        // add the event to the generic list
-        mEvents.add(event);
-        
-        // add to the list of events that needs to be displayed, and trigger a
-        // new display if needed.
-        boolean start_event = false;
-        synchronized (mNewEvents) {
-            mNewEvents.add(event);
-            
-            if (mPendingDisplay == false) {
-                mPendingDisplay = true;
-                start_event = true;
-            }
-        }
-        
-        if (start_event == false) {
-            // we're done
-            return;
-        }
-
-        scheduleUIEventHandler();
-    }
-
-    /**
-     * Schedules the UI thread to execute a {@link Runnable} calling {@link #displayNewEvents()}.
-     */
-    private void scheduleUIEventHandler() {
-        try  {
-            Display d = mBottomParentPanel.getDisplay();
-            d.asyncExec(new Runnable() {
-                public void run() {
-                    if (mBottomParentPanel.isDisposed() == false) {
-                        if (mCurrentEventLogParser != null) {
-                            displayNewEvents();
-                        }
-                    }
-                }
-            });
-        } catch (SWTException e) {
-            // if the ui is disposed, do nothing 
-        }
-    }
-
-    /**
-     * Processes raw data coming from the log service.
-     * @see LogReceiver.ILogListener#newData(byte[], int, int)
-     */
-    public void newData(byte[] data, int offset, int length) {
-        if (mTempFile != null) {
-            try {
-                FileOutputStream fos = new FileOutputStream(mTempFile, true /* append */);
-                fos.write(data, offset, length);
-                fos.close();
-            } catch (FileNotFoundException e) {
-            } catch (IOException e) {
-            }
-        }
-    }
-
-    @UiThread
-    private void displayNewEvents() {
-        // never display more than 1,000 events in this loop. We can't do too much in the UI thread.
-        int count = 0;
-
-        // prepare the displays
-        for (EventDisplay eventDisplay : mEventDisplays) {
-            eventDisplay.startMultiEventDisplay();
-        }
-        
-        // display the new events
-        EventContainer event = null;
-        boolean need_to_reloop = false;
-        do {
-            // get the next event to display.
-            synchronized (mNewEvents) {
-                if (mNewEvents.size() > 0) {
-                    if (count > 200) {
-                        // there are still events to be displayed, but we don't want to hog the
-                        // UI thread for too long, so we stop this runnable, but launch a new
-                        // one to keep going.
-                        need_to_reloop = true;
-                        event = null;
-                    } else {
-                        event = mNewEvents.remove(0);
-                        count++;
-                    }
-                } else {
-                    // we're done.
-                    event = null;
-                    mPendingDisplay = false;
-                }
-            }
-
-            if (event != null) {
-                // notify the event display
-                for (EventDisplay eventDisplay : mEventDisplays) {
-                    eventDisplay.newEvent(event, mCurrentEventLogParser);
-                }
-            }
-        } while (event != null);
-
-        // we're done displaying events.
-        for (EventDisplay eventDisplay : mEventDisplays) {
-            eventDisplay.endMultiEventDisplay();
-        }
-        
-        // if needed, ask the UI thread to re-run this method.
-        if (need_to_reloop) {
-            scheduleUIEventHandler();
-        }
-    }
-
-    /**
-     * Loads the {@link EventDisplay}s from the preference store.
-     */
-    private void loadEventDisplays() {
-        IPreferenceStore store = DdmUiPreferences.getStore();
-        String storage = store.getString(PREFS_EVENT_DISPLAY);
-        
-        if (storage.length() > 0) {
-            String[] values = storage.split(Pattern.quote(EVENT_DISPLAY_STORAGE_SEPARATOR));
-            
-            for (String value : values) {
-                EventDisplay eventDisplay = EventDisplay.load(value);
-                if (eventDisplay != null) {
-                    mEventDisplays.add(eventDisplay);
-                }
-            }
-        }
-    }
-
-    /**
-     * Saves the {@link EventDisplay}s into the {@link DdmUiPreferences} store.
-     */
-    private void saveEventDisplays() {
-        IPreferenceStore store = DdmUiPreferences.getStore();
-        
-        boolean first = true;
-        StringBuilder sb = new StringBuilder();
-        
-        for (EventDisplay eventDisplay : mEventDisplays) {
-            String storage = eventDisplay.getStorageString();
-            if (storage != null) {
-                if (first == false) {
-                    sb.append(EVENT_DISPLAY_STORAGE_SEPARATOR);
-                } else {
-                    first = false;
-                }
-                
-                sb.append(storage);
-            }
-        }
-
-        store.setValue(PREFS_EVENT_DISPLAY, sb.toString());
-    }
-
-    /**
-     * Updates the {@link EventDisplay} with the new {@link EventLogParser}.
-     * <p/>
-     * This will run asynchronously in the UI thread.
-     */
-    @WorkerThread
-    private void updateEventDisplays() {
-        try {
-            Display d = mBottomParentPanel.getDisplay();
-
-            d.asyncExec(new Runnable() {
-                public void run() {
-                    if (mBottomParentPanel.isDisposed() == false) {
-                        for (EventDisplay eventDisplay : mEventDisplays) {
-                            eventDisplay.setNewLogParser(mCurrentEventLogParser);
-                        }
-                        
-                        mOptionsAction.setEnabled(true);
-                        mClearAction.setEnabled(true);
-                        if (mCurrentLogFile == null) {
-                            mSaveAction.setEnabled(true);
-                        } else {
-                            mSaveAction.setEnabled(false);
-                        }
-                    }
-                }
-            });
-        } catch (SWTException e) {
-            // display is disposed: do nothing.
-        }
-    }
-
-    @UiThread
-    public void columnResized(int index, TableColumn sourceColumn) {
-        for (EventDisplay eventDisplay : mEventDisplays) {
-            eventDisplay.resizeColumn(index, sourceColumn);
-        }
-    }
-
-    /**
-     * Runs an event log service out of a local file.
-     * @param fileName the full file name of the local file containing the event log.
-     * @param logReceiver the receiver that will handle the log
-     * @throws IOException 
-     */
-    @WorkerThread
-    private void runLocalEventLogService(String fileName, LogReceiver logReceiver)
-            throws IOException {
-        byte[] buffer = new byte[256];
-        
-        FileInputStream fis = new FileInputStream(fileName);
-        
-        int count;
-        while ((count = fis.read(buffer)) != -1) {
-            logReceiver.parseNewData(buffer, 0, count);
-        }
-    }
-    
-    @WorkerThread
-    private void runLocalEventLogService(String[] log, LogReceiver currentLogReceiver) {
-        synchronized (mLock) {
-            for (String line : log) {
-                EventContainer event = mCurrentEventLogParser.parse(line);
-                if (event != null) {
-                    handleNewEvent(event);
-                }
-            }
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventValueSelector.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventValueSelector.java
deleted file mode 100644
index dd32e2c..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/EventValueSelector.java
+++ /dev/null
@@ -1,628 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.EventValueDescription;
-import com.android.ddmlib.log.EventContainer.CompareMethod;
-import com.android.ddmlib.log.EventContainer.EventValueType;
-import com.android.ddmuilib.log.event.EventDisplay.OccurrenceDisplayDescriptor;
-import com.android.ddmuilib.log.event.EventDisplay.ValueDisplayDescriptor;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.Set;
-
-final class EventValueSelector extends Dialog {
-    private static final int DLG_WIDTH = 400;
-    private static final int DLG_HEIGHT = 300;
-
-    private Shell mParent;
-    private Shell mShell;
-    private boolean mEditStatus;
-    private Combo mEventCombo;
-    private Combo mValueCombo;
-    private Combo mSeriesCombo;
-    private Button mDisplayPidCheckBox;
-    private Combo mFilterCombo;
-    private Combo mFilterMethodCombo;
-    private Text mFilterValue;
-    private Button mOkButton;
-
-    private EventLogParser mLogParser;
-    private OccurrenceDisplayDescriptor mDescriptor;
-    
-    /** list of event integer in the order of the combo. */
-    private Integer[] mEventTags;
-    
-    /** list of indices in the {@link EventValueDescription} array of the current event
-     * that are of type string. This lets us get back the {@link EventValueDescription} from the
-     * index in the Series {@link Combo}.
-     */
-    private final ArrayList<Integer> mSeriesIndices = new ArrayList<Integer>();
-    
-    public EventValueSelector(Shell parent) {
-        super(parent, SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL);
-    }
-
-    /**
-     * Opens the display option dialog to edit a new descriptor.
-     * @param decriptorClass the class of the object to instantiate. Must extend
-     * {@link OccurrenceDisplayDescriptor}
-     * @param logParser
-     * @return true if the object is to be created, false if the creation was canceled.
-     */
-    boolean open(Class<? extends OccurrenceDisplayDescriptor> descriptorClass,
-            EventLogParser logParser) {
-        try {
-            OccurrenceDisplayDescriptor descriptor = descriptorClass.newInstance();
-            setModified();
-            return open(descriptor, logParser);
-        } catch (InstantiationException e) {
-            return false;
-        } catch (IllegalAccessException e) {
-            return false;
-        }
-    }
-
-    /**
-     * Opens the display option dialog, to edit a {@link OccurrenceDisplayDescriptor} object or
-     * a {@link ValueDisplayDescriptor} object.
-     * @param descriptor The descriptor to edit.
-     * @return true if the object was modified.
-     */
-    boolean open(OccurrenceDisplayDescriptor descriptor, EventLogParser logParser) {
-        // make a copy of the descriptor as we'll use a working copy.
-        if (descriptor instanceof ValueDisplayDescriptor) {
-            mDescriptor = new ValueDisplayDescriptor((ValueDisplayDescriptor)descriptor);
-        } else if (descriptor instanceof OccurrenceDisplayDescriptor) {
-            mDescriptor = new OccurrenceDisplayDescriptor(descriptor);
-        } else {
-            return false;
-        }
-
-        mLogParser = logParser;
-
-        createUI();
-
-        if (mParent == null || mShell == null) {
-            return false;
-        }
-
-        loadValueDescriptor();
-        
-        checkValidity();
-
-        // Set the dialog size.
-        try { 
-            mShell.setMinimumSize(DLG_WIDTH, DLG_HEIGHT);
-            Rectangle r = mParent.getBounds();
-            // get the center new top left.
-            int cx = r.x + r.width/2;
-            int x = cx - DLG_WIDTH / 2;
-            int cy = r.y + r.height/2;
-            int y = cy - DLG_HEIGHT / 2;
-            mShell.setBounds(x, y, DLG_WIDTH, DLG_HEIGHT);
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-
-        mShell.layout();
-
-        // actually open the dialog
-        mShell.open();
-
-        // event loop until the dialog is closed.
-        Display display = mParent.getDisplay();
-        while (!mShell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-        
-        return mEditStatus;
-    }
-    
-    OccurrenceDisplayDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-    
-    private void createUI() {
-        GridData gd;
-
-        mParent = getParent();
-        mShell = new Shell(mParent, getStyle());
-        mShell.setText("Event Display Configuration");
-
-        mShell.setLayout(new GridLayout(2, false));
-        
-        Label l = new Label(mShell, SWT.NONE);
-        l.setText("Event:");
-        
-        mEventCombo = new Combo(mShell, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mEventCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // the event tag / event name map
-        Map<Integer, String> eventTagMap = mLogParser.getTagMap();
-        Map<Integer, EventValueDescription[]> eventInfoMap = mLogParser.getEventInfoMap();
-        Set<Integer> keys = eventTagMap.keySet();
-        ArrayList<Integer> list = new ArrayList<Integer>();
-        for (Integer i : keys) {
-            if (eventInfoMap.get(i) != null) {
-                String eventName = eventTagMap.get(i);
-                mEventCombo.add(eventName);
-                
-                list.add(i);
-            }
-        }
-        mEventTags = list.toArray(new Integer[list.size()]);
-        
-        mEventCombo.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleEventComboSelection();
-                setModified();
-            }
-        });
-
-        l = new Label(mShell, SWT.NONE);
-        l.setText("Value:");
-        
-        mValueCombo = new Combo(mShell, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mValueCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mValueCombo.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleValueComboSelection();
-                setModified();
-            }
-        });
-
-        l = new Label(mShell, SWT.NONE);
-        l.setText("Series Name:");
-
-        mSeriesCombo = new Combo(mShell, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mSeriesCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mSeriesCombo.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleSeriesComboSelection();
-                setModified();
-            }
-        });
-
-        // empty comp
-        new Composite(mShell, SWT.NONE).setLayoutData(gd = new GridData());
-        gd.heightHint = gd.widthHint = 0;
-
-        mDisplayPidCheckBox = new Button(mShell, SWT.CHECK);
-        mDisplayPidCheckBox.setText("Also Show pid");
-        mDisplayPidCheckBox.setEnabled(false);
-        mDisplayPidCheckBox.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mDescriptor.includePid = mDisplayPidCheckBox.getSelection();
-                setModified();
-            }
-        });
-
-        l = new Label(mShell, SWT.NONE);
-        l.setText("Filter By:");
-
-        mFilterCombo = new Combo(mShell, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mFilterCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mFilterCombo.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleFilterComboSelection();
-                setModified();
-            }
-        });
-
-        l = new Label(mShell, SWT.NONE);
-        l.setText("Filter Method:");
-
-        mFilterMethodCombo = new Combo(mShell, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mFilterMethodCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        for (CompareMethod method : CompareMethod.values()) {
-            mFilterMethodCombo.add(method.toString());
-        }
-        mFilterMethodCombo.select(0);
-        mFilterMethodCombo.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleFilterMethodComboSelection();
-                setModified();
-            }
-        });
-
-        l = new Label(mShell, SWT.NONE);
-        l.setText("Filter Value:");
-        
-        mFilterValue = new Text(mShell, SWT.BORDER | SWT.SINGLE);
-        mFilterValue.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mFilterValue.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                if (mDescriptor.filterValueIndex != -1) {
-                    // get the current selection in the event combo
-                    int index = mEventCombo.getSelectionIndex();
-    
-                    if (index != -1) {
-                        // match it to an event
-                        int eventTag = mEventTags[index];
-                        mDescriptor.eventTag = eventTag;
-                        
-                        // get the EventValueDescription for this tag
-                        EventValueDescription valueDesc = mLogParser.getEventInfoMap()
-                            .get(eventTag)[mDescriptor.filterValueIndex];
-                        
-                        // let the EventValueDescription convert the String value into an object
-                        // of the proper type.
-                        mDescriptor.filterValue = valueDesc.getObjectFromString(
-                                mFilterValue.getText().trim());
-                        setModified();
-                    }
-                }
-            }
-        });
-        
-        // add a separator spanning the 2 columns
-        
-        l = new Label(mShell, SWT.SEPARATOR | SWT.HORIZONTAL);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        l.setLayoutData(gd);
-        
-        // add a composite to hold the ok/cancel button, no matter what the columns size are.
-        Composite buttonComp = new Composite(mShell, SWT.NONE);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        buttonComp.setLayoutData(gd);
-        GridLayout gl;
-        buttonComp.setLayout(gl = new GridLayout(6, true));
-        gl.marginHeight = gl.marginWidth = 0;
-
-        Composite padding = new Composite(mShell, SWT.NONE);
-        padding.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mOkButton = new Button(buttonComp, SWT.PUSH);
-        mOkButton.setText("OK");
-        mOkButton.setLayoutData(new GridData(GridData.CENTER));
-        mOkButton.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mShell.close();
-            }
-        });
-
-        padding = new Composite(mShell, SWT.NONE);
-        padding.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        padding = new Composite(mShell, SWT.NONE);
-        padding.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        Button cancelButton = new Button(buttonComp, SWT.PUSH);
-        cancelButton.setText("Cancel");
-        cancelButton.setLayoutData(new GridData(GridData.CENTER));
-        cancelButton.addSelectionListener(new SelectionAdapter() {
-            /* (non-Javadoc)
-             * @see org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse.swt.events.SelectionEvent)
-             */
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // cancel the edit
-                mEditStatus = false;
-                mShell.close();
-            }
-        });
-
-        padding = new Composite(mShell, SWT.NONE);
-        padding.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        mShell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-                event.doit = true;
-            }
-        });
-    }
-
-    private void setModified() {
-        mEditStatus = true;
-    }
-
-    private void handleEventComboSelection() {
-        // get the current selection in the event combo
-        int index = mEventCombo.getSelectionIndex();
-
-        if (index != -1) {
-            // match it to an event
-            int eventTag = mEventTags[index];
-            mDescriptor.eventTag = eventTag;
-            
-            // get the EventValueDescription for this tag
-            EventValueDescription[] values = mLogParser.getEventInfoMap().get(eventTag);
-            
-            // fill the combo for the values
-            mValueCombo.removeAll();
-            if (values != null) {
-                if (mDescriptor instanceof ValueDisplayDescriptor) {
-                    ValueDisplayDescriptor valueDescriptor = (ValueDisplayDescriptor)mDescriptor;
-    
-                    mValueCombo.setEnabled(true);
-                    for (EventValueDescription value : values) {
-                        mValueCombo.add(value.toString());
-                    }
-                    
-                    if (valueDescriptor.valueIndex != -1) {
-                        mValueCombo.select(valueDescriptor.valueIndex);
-                    } else {
-                        mValueCombo.clearSelection();
-                    }
-                } else {
-                    mValueCombo.setEnabled(false);
-                }
-
-                // fill the axis combo
-                mSeriesCombo.removeAll();
-                mSeriesCombo.setEnabled(false);
-                mSeriesIndices.clear();
-                int axisIndex = 0;
-                int selectionIndex = -1;
-                for (EventValueDescription value : values) {
-                    if (value.getEventValueType() == EventValueType.STRING) {
-                        mSeriesCombo.add(value.getName());
-                        mSeriesCombo.setEnabled(true);
-                        mSeriesIndices.add(axisIndex);
-                        
-                        if (mDescriptor.seriesValueIndex != -1 &&
-                                mDescriptor.seriesValueIndex == axisIndex) {
-                            selectionIndex = axisIndex;
-                        }
-                    }
-                    axisIndex++;
-                }
-
-                if (mSeriesCombo.isEnabled()) {
-                    mSeriesCombo.add("default (pid)", 0 /* index */);
-                    mSeriesIndices.add(0 /* index */, -1 /* value */);
-
-                    // +1 because we added another item at index 0
-                    mSeriesCombo.select(selectionIndex + 1);
-                    
-                    if (selectionIndex >= 0) {
-                        mDisplayPidCheckBox.setSelection(mDescriptor.includePid);
-                        mDisplayPidCheckBox.setEnabled(true);
-                    } else {
-                        mDisplayPidCheckBox.setEnabled(false);
-                        mDisplayPidCheckBox.setSelection(false);
-                    }
-                } else {
-                    mDisplayPidCheckBox.setSelection(false);
-                    mDisplayPidCheckBox.setEnabled(false);
-                }
-                
-                // fill the filter combo
-                mFilterCombo.setEnabled(true);
-                mFilterCombo.removeAll();
-                mFilterCombo.add("(no filter)");
-                for (EventValueDescription value : values) {
-                    mFilterCombo.add(value.toString());
-                }
-                
-                // select the current filter
-                mFilterCombo.select(mDescriptor.filterValueIndex + 1);
-                mFilterMethodCombo.select(getFilterMethodIndex(mDescriptor.filterCompareMethod));
-
-                // fill the current filter value
-                if (mDescriptor.filterValueIndex != -1) {
-                    EventValueDescription valueInfo = values[mDescriptor.filterValueIndex];
-                    if (valueInfo.checkForType(mDescriptor.filterValue)) {
-                        mFilterValue.setText(mDescriptor.filterValue.toString());
-                    } else {
-                        mFilterValue.setText("");
-                    }
-                } else {
-                    mFilterValue.setText("");
-                }
-            } else {
-                disableSubCombos();
-            }
-        } else {
-            disableSubCombos();
-        }
-        
-        checkValidity();
-    }
-
-    /**
-     * 
-     */
-    private void disableSubCombos() {
-        mValueCombo.removeAll();
-        mValueCombo.clearSelection();
-        mValueCombo.setEnabled(false);
-
-        mSeriesCombo.removeAll();
-        mSeriesCombo.clearSelection();
-        mSeriesCombo.setEnabled(false);
-        
-        mDisplayPidCheckBox.setEnabled(false);
-        mDisplayPidCheckBox.setSelection(false);
-        
-        mFilterCombo.removeAll();
-        mFilterCombo.clearSelection();
-        mFilterCombo.setEnabled(false);
-        
-        mFilterValue.setEnabled(false);
-        mFilterValue.setText("");
-        mFilterMethodCombo.setEnabled(false);
-    }
-
-    private void handleValueComboSelection() {
-        ValueDisplayDescriptor valueDescriptor = (ValueDisplayDescriptor)mDescriptor;
-
-        // get the current selection in the value combo
-        int index = mValueCombo.getSelectionIndex();
-        valueDescriptor.valueIndex = index;
-        
-        // for now set the built-in name
-
-        // get the current selection in the event combo
-        int eventIndex = mEventCombo.getSelectionIndex();
-        
-        // match it to an event
-        int eventTag = mEventTags[eventIndex];
-        
-        // get the EventValueDescription for this tag
-        EventValueDescription[] values = mLogParser.getEventInfoMap().get(eventTag);
-
-        valueDescriptor.valueName = values[index].getName();
-        
-        checkValidity();
-    }
-
-    private void handleSeriesComboSelection() {
-        // get the current selection in the axis combo
-        int index = mSeriesCombo.getSelectionIndex();
-        
-        // get the actual value index from the list.
-        int valueIndex = mSeriesIndices.get(index);
-        
-        mDescriptor.seriesValueIndex = valueIndex;
-        
-        if (index > 0) {
-            mDisplayPidCheckBox.setEnabled(true);
-            mDisplayPidCheckBox.setSelection(mDescriptor.includePid);
-        } else {
-            mDisplayPidCheckBox.setSelection(false);
-            mDisplayPidCheckBox.setEnabled(false);
-        }
-    }
-
-    private void handleFilterComboSelection() {
-        // get the current selection in the axis combo
-        int index = mFilterCombo.getSelectionIndex();
-        
-        // decrement index by 1 since the item 0 means
-        // no filter (index = -1), and the rest is offset by 1
-        index--;
-
-        mDescriptor.filterValueIndex = index;
-        
-        if (index != -1) {
-            mFilterValue.setEnabled(true);
-            mFilterMethodCombo.setEnabled(true);
-            if (mDescriptor.filterValue instanceof String) {
-                mFilterValue.setText((String)mDescriptor.filterValue);
-            }
-        } else {
-            mFilterValue.setText("");
-            mFilterValue.setEnabled(false);
-            mFilterMethodCombo.setEnabled(false);
-        }
-    }
-    
-    private void handleFilterMethodComboSelection() {
-        // get the current selection in the axis combo
-        int index = mFilterMethodCombo.getSelectionIndex();
-        CompareMethod method = CompareMethod.values()[index];
-        
-        mDescriptor.filterCompareMethod = method;
-    }
-
-    /**
-     * Returns the index of the filter method
-     * @param filterCompareMethod the {@link CompareMethod} enum.
-     */
-    private int getFilterMethodIndex(CompareMethod filterCompareMethod) {
-        CompareMethod[] values = CompareMethod.values();
-        for (int i = 0 ; i < values.length ; i++) {
-            if (values[i] == filterCompareMethod) {
-                return i;
-            }
-        }
-        return -1;
-    }
-
-
-    private void loadValueDescriptor() {
-        // get the index from the eventTag.
-        int eventIndex = 0;
-        int comboIndex = -1;
-        for (int i : mEventTags) {
-            if (i == mDescriptor.eventTag) {
-                comboIndex = eventIndex;
-                break;
-            }
-            eventIndex++;
-        }
-        
-        if (comboIndex == -1) {
-            mEventCombo.clearSelection();
-        } else {
-            mEventCombo.select(comboIndex);
-        }
-
-        // get the event from the descriptor
-        handleEventComboSelection();
-    }
-    
-    private void checkValidity() {
-        mOkButton.setEnabled(mEventCombo.getSelectionIndex() != -1 &&
-                (((mDescriptor instanceof ValueDisplayDescriptor) == false) ||
-                        mValueCombo.getSelectionIndex() != -1));
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/OccurrenceRenderer.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/OccurrenceRenderer.java
deleted file mode 100644
index 3af1447..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/OccurrenceRenderer.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import org.jfree.chart.axis.ValueAxis;
-import org.jfree.chart.plot.CrosshairState;
-import org.jfree.chart.plot.PlotOrientation;
-import org.jfree.chart.plot.PlotRenderingInfo;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.renderer.xy.XYItemRendererState;
-import org.jfree.chart.renderer.xy.XYLineAndShapeRenderer;
-import org.jfree.data.time.TimeSeriesCollection;
-import org.jfree.data.xy.XYDataset;
-import org.jfree.ui.RectangleEdge;
-
-import java.awt.Graphics2D;
-import java.awt.Paint;
-import java.awt.Stroke;
-import java.awt.geom.Line2D;
-import java.awt.geom.Rectangle2D;
-
-/**
- * Custom renderer to render event occurrence. This rendered ignores the y value, and simply
- * draws a line from min to max at the time of the item.
- */
-public class OccurrenceRenderer extends XYLineAndShapeRenderer {
-
-    private static final long serialVersionUID = 1L;
-
-    @Override
-    public void drawItem(Graphics2D g2, 
-                         XYItemRendererState state,
-                         Rectangle2D dataArea,
-                         PlotRenderingInfo info,
-                         XYPlot plot, 
-                         ValueAxis domainAxis, 
-                         ValueAxis rangeAxis,
-                         XYDataset dataset, 
-                         int series, 
-                         int item,
-                         CrosshairState crosshairState, 
-                         int pass) {
-        TimeSeriesCollection timeDataSet = (TimeSeriesCollection)dataset;
-        
-        // get the x value for the series/item.
-        double x = timeDataSet.getX(series, item).doubleValue();
-
-        // get the min/max of the range axis
-        double yMin = rangeAxis.getLowerBound();
-        double yMax = rangeAxis.getUpperBound();
-
-        RectangleEdge domainEdge = plot.getDomainAxisEdge();
-        RectangleEdge rangeEdge = plot.getRangeAxisEdge();
-
-        // convert the coordinates to java2d.
-        double x2D = domainAxis.valueToJava2D(x, dataArea, domainEdge);
-        double yMin2D = rangeAxis.valueToJava2D(yMin, dataArea, rangeEdge);
-        double yMax2D = rangeAxis.valueToJava2D(yMax, dataArea, rangeEdge);
-
-        // get the paint information for the series/item
-        Paint p = getItemPaint(series, item);
-        Stroke s = getItemStroke(series, item);
-        
-        Line2D line = null;
-        PlotOrientation orientation = plot.getOrientation();
-        if (orientation == PlotOrientation.HORIZONTAL) {
-            line = new Line2D.Double(yMin2D, x2D, yMax2D, x2D);
-        }
-        else if (orientation == PlotOrientation.VERTICAL) {
-            line = new Line2D.Double(x2D, yMin2D, x2D, yMax2D);
-        }
-        g2.setPaint(p);
-        g2.setStroke(s);
-        g2.draw(line);
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/SyncCommon.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/SyncCommon.java
deleted file mode 100644
index 108c097..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/log/event/SyncCommon.java
+++ /dev/null
@@ -1,158 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.log.event;
-
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.InvalidTypeException;
-
-import java.awt.Color;
-
-abstract public class SyncCommon extends EventDisplay {
-
-    // State information while processing the event stream
-    private int mLastState; // 0 if event started, 1 if event stopped
-    private long mLastStartTime; // ms
-    private long mLastStopTime; //ms
-    private String mLastDetails;
-    private int mLastSyncSource; // poll, server, user, etc.
-
-    // Some common variables for sync display.  These define the sync backends
-    //and how they should be displayed.
-    protected static final int CALENDAR = 0;
-    protected static final int GMAIL = 1;
-    protected static final int FEEDS = 2;
-    protected static final int CONTACTS = 3;
-    protected static final int ERRORS = 4;
-    protected static final int NUM_AUTHS = (CONTACTS + 1);
-    protected static final String AUTH_NAMES[] = {"Calendar", "Gmail", "Feeds", "Contacts",
-            "Errors"};
-    protected static final Color AUTH_COLORS[] = {Color.MAGENTA, Color.GREEN, Color.BLUE,
-            Color.ORANGE, Color.RED};
-
-    // Values from data/etc/event-log-tags
-    final int EVENT_SYNC = 2720;
-    final int EVENT_TICKLE = 2742;
-    final int EVENT_SYNC_DETAILS = 2743;
-
-    protected SyncCommon(String name) {
-        super(name);
-    }
-
-    /**
-     * Resets the display.
-     */
-    @Override
-    void resetUI() {
-        mLastStartTime = 0;
-        mLastStopTime = 0;
-        mLastState = -1;
-        mLastSyncSource = -1;
-        mLastDetails = "";
-    }
-
-    /**
-     * Updates the display with a new event.  This is the main entry point for
-     * each event.  This method has the logic to tie together the start event,
-     * stop event, and details event into one graph item.  The combined sync event
-     * is handed to the subclass via processSycnEvent.  Note that the details
-     * can happen before or after the stop event.
-     *
-     * @param event     The event
-     * @param logParser The parser providing the event.
-     */
-    @Override
-    void newEvent(EventContainer event, EventLogParser logParser) {
-        try {
-            if (event.mTag == EVENT_SYNC) {
-                int state = Integer.parseInt(event.getValueAsString(1));
-                if (state == 0) { // start
-                    mLastStartTime = (long) event.sec * 1000L + (event.nsec / 1000000L);
-                    mLastState = 0;
-                    mLastSyncSource = Integer.parseInt(event.getValueAsString(2));                    
-                    mLastDetails = "";
-                } else if (state == 1) { // stop
-                    if (mLastState == 0) {
-                        mLastStopTime = (long) event.sec * 1000L + (event.nsec / 1000000L);
-                        if (mLastStartTime == 0) {
-                            // Log starts with a stop event
-                            mLastStartTime = mLastStopTime;
-                        }
-                        int auth = getAuth(event.getValueAsString(0));
-                        processSyncEvent(event, auth, mLastStartTime, mLastStopTime, mLastDetails,
-                                true, mLastSyncSource);
-                        mLastState = 1;
-                    }
-                }
-            } else if (event.mTag == EVENT_SYNC_DETAILS) {
-                mLastDetails = event.getValueAsString(3);
-                if (mLastState != 0) { // Not inside event
-                    long updateTime = (long) event.sec * 1000L + (event.nsec / 1000000L);
-                    if (updateTime - mLastStopTime <= 250) {
-                        // Got details within 250ms after event, so delete and re-insert
-                        // Details later than 250ms (arbitrary) are discarded as probably
-                        // unrelated.
-                        int auth = getAuth(event.getValueAsString(0));
-                        processSyncEvent(event, auth, mLastStartTime, mLastStopTime, mLastDetails,
-                                false, mLastSyncSource);
-                    }
-                }
-            }
-        } catch (InvalidTypeException e) {
-        }
-    }
-
-    /**
-     * Callback hook for subclass to process a sync event.  newEvent has the logic
-     * to combine start and stop events and passes a processed event to the
-     * subclass.
-     *
-     * @param event     The sync event
-     * @param auth      The sync authority
-     * @param startTime Start time (ms) of events
-     * @param stopTime  Stop time (ms) of events
-     * @param details   Details associated with the event.
-     * @param newEvent  True if this event is a new sync event.  False if this event
-     * @param syncSource Poll, user, server, etc.
-     */
-    abstract void processSyncEvent(EventContainer event, int auth, long startTime, long stopTime,
-            String details, boolean newEvent, int syncSource);
-     
-    /**
-     * Converts authority name to auth number.
-     *
-     * @param authname "calendar", etc.
-     * @return number series number associated with the authority
-     */
-    protected int getAuth(String authname) throws InvalidTypeException {
-        if ("calendar".equals(authname) || "cl".equals(authname)) {
-            return CALENDAR;
-        } else if ("contacts".equals(authname) || "cp".equals(authname)) {
-            return CONTACTS;
-        } else if ("subscribedfeeds".equals(authname)) {
-            return FEEDS;
-        } else if ("gmail-ls".equals(authname) || "mail".equals(authname)) {
-            return GMAIL;
-        } else if ("gmail-live".equals(authname)) {
-            return GMAIL;
-        } else if ("unknown".equals(authname)) {
-            return -1; // Unknown tickles; discard
-        } else {
-            throw new InvalidTypeException("Unknown authname " + authname);
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/EditFilterDialog.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/EditFilterDialog.java
deleted file mode 100644
index c66fe48..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/EditFilterDialog.java
+++ /dev/null
@@ -1,353 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.logcat;
-
-import com.android.ddmuilib.IImageLoader;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Dialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Small dialog box to edit a static port number.
- */
-public class EditFilterDialog extends Dialog {
-
-    private static final int DLG_WIDTH = 400;
-    private static final int DLG_HEIGHT = 250;
-
-    private Shell mParent;
-
-    private Shell mShell;
-
-    private boolean mOk = false;
-
-    private IImageLoader mImageLoader;
-
-    /**
-     * Filter being edited or created
-     */
-    private LogFilter mFilter;
-
-    private String mName;
-    private String mTag;
-    private String mPid;
-
-    /** Log level as an index of the drop-down combo
-     * @see getLogLevel
-     * @see getComboIndex
-     */
-    private int mLogLevel;
-
-    private Button mOkButton;
-
-    private Label mPidWarning;
-
-    public EditFilterDialog(IImageLoader imageLoader, Shell parent) {
-        super(parent, SWT.DIALOG_TRIM | SWT.BORDER | SWT.APPLICATION_MODAL);
-        mImageLoader = imageLoader;
-    }
-
-    public EditFilterDialog(IImageLoader imageLoader, Shell shell,
-            LogFilter filter) {
-        this(imageLoader, shell);
-        mFilter = filter;
-    }
-
-    /**
-     * Opens the dialog. The method will return when the user closes the dialog
-     * somehow.
-     *
-     * @return true if ok was pressed, false if cancelled.
-     */
-    public boolean open() {
-        createUI();
-
-        if (mParent == null || mShell == null) {
-            return false;
-        }
-
-        mShell.setMinimumSize(DLG_WIDTH, DLG_HEIGHT);
-        Rectangle r = mParent.getBounds();
-        // get the center new top left.
-        int cx = r.x + r.width/2;
-        int x = cx - DLG_WIDTH / 2;
-        int cy = r.y + r.height/2;
-        int y = cy - DLG_HEIGHT / 2;
-        mShell.setBounds(x, y, DLG_WIDTH, DLG_HEIGHT);
-
-        mShell.open();
-
-        Display display = mParent.getDisplay();
-        while (!mShell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-        // we're quitting with OK.
-        // Lets update the filter if needed
-        if (mOk) {
-            // if it was a "Create filter" action we need to create it first.
-            if (mFilter == null) {
-                mFilter = new LogFilter(mName);
-            }
-
-            // setup the filter
-            mFilter.setTagMode(mTag);
-
-            if (mPid != null && mPid.length() > 0) {
-                mFilter.setPidMode(Integer.parseInt(mPid));
-            } else {
-                mFilter.setPidMode(-1);
-            }
-
-            mFilter.setLogLevel(getLogLevel(mLogLevel));
-        }
-
-        return mOk;
-    }
-
-    public LogFilter getFilter() {
-        return mFilter;
-    }
-
-    private void createUI() {
-        mParent = getParent();
-        mShell = new Shell(mParent, getStyle());
-        mShell.setText("Log Filter");
-
-        mShell.setLayout(new GridLayout(1, false));
-
-        mShell.addListener(SWT.Close, new Listener() {
-            public void handleEvent(Event event) {
-            }
-        });
-
-        // top part with the filter name
-        Composite nameComposite = new Composite(mShell, SWT.NONE);
-        nameComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        nameComposite.setLayout(new GridLayout(2, false));
-
-        Label l = new Label(nameComposite, SWT.NONE);
-        l.setText("Filter Name:");
-
-        final Text filterNameText = new Text(nameComposite,
-                SWT.SINGLE | SWT.BORDER);
-        if (mFilter != null) {
-            mName = mFilter.getName();
-            if (mName != null) {
-                filterNameText.setText(mName);
-            }
-        }
-        filterNameText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        filterNameText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mName = filterNameText.getText().trim();
-                validate();
-            }
-        });
-
-        // separator
-        l = new Label(mShell, SWT.SEPARATOR | SWT.HORIZONTAL);
-        l.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-
-        // center part with the filter parameters
-        Composite main = new Composite(mShell, SWT.NONE);
-        main.setLayoutData(new GridData(GridData.FILL_BOTH));
-        main.setLayout(new GridLayout(3, false));
-
-        l = new Label(main, SWT.NONE);
-        l.setText("by Log Tag:");
-
-        final Text tagText = new Text(main, SWT.SINGLE | SWT.BORDER);
-        if (mFilter != null) {
-            mTag = mFilter.getTagFilter();
-            if (mTag != null) {
-                tagText.setText(mTag);
-            }
-        }
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        tagText.setLayoutData(gd);
-        tagText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mTag = tagText.getText().trim();
-                validate();
-            }
-        });
-
-        l = new Label(main, SWT.NONE);
-        l.setText("by pid:");
-
-        final Text pidText = new Text(main, SWT.SINGLE | SWT.BORDER);
-        if (mFilter != null) {
-            if (mFilter.getPidFilter() != -1) {
-                mPid = Integer.toString(mFilter.getPidFilter());
-            } else {
-                mPid = "";
-            }
-            pidText.setText(mPid);
-        }
-        pidText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        pidText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mPid = pidText.getText().trim();
-                validate();
-            }
-        });
-
-        mPidWarning = new Label(main, SWT.NONE);
-        mPidWarning.setImage(mImageLoader.loadImage("empty.png", // $NON-NLS-1$
-                mShell.getDisplay()));
-
-        l = new Label(main, SWT.NONE);
-        l.setText("by Log level:");
-
-        final Combo logCombo = new Combo(main, SWT.DROP_DOWN | SWT.READ_ONLY);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        logCombo.setLayoutData(gd);
-
-        // add the labels
-        logCombo.add("<none>");
-        logCombo.add("Error");
-        logCombo.add("Warning");
-        logCombo.add("Info");
-        logCombo.add("Debug");
-        logCombo.add("Verbose");
-
-        if (mFilter != null) {
-            mLogLevel = getComboIndex(mFilter.getLogLevel());
-            logCombo.select(mLogLevel);
-        } else {
-            logCombo.select(0);
-        }
-
-        logCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // get the selection
-                mLogLevel = logCombo.getSelectionIndex();
-                validate();
-            }
-        });
-
-        // separator
-        l = new Label(mShell, SWT.SEPARATOR | SWT.HORIZONTAL);
-        l.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // bottom part with the ok/cancel
-        Composite bottomComp = new Composite(mShell, SWT.NONE);
-        bottomComp
-                .setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER));
-        bottomComp.setLayout(new GridLayout(2, true));
-
-        mOkButton = new Button(bottomComp, SWT.NONE);
-        mOkButton.setText("OK");
-        mOkButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mOk = true;
-                mShell.close();
-            }
-        });
-        mOkButton.setEnabled(false);
-        mShell.setDefaultButton(mOkButton);
-
-        Button cancelButton = new Button(bottomComp, SWT.NONE);
-        cancelButton.setText("Cancel");
-        cancelButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mShell.close();
-            }
-        });
-
-        validate();
-    }
-
-    /**
-     * Returns the log level from a combo index.
-     * @param index the Combo index
-     * @return a log level valid for the Log class.
-     */
-    protected int getLogLevel(int index) {
-        if (index == 0) {
-            return -1;
-        }
-
-        return 7 - index;
-    }
-
-    /**
-     * Returns the index in the combo that matches the log level
-     * @param logLevel The Log level.
-     * @return the combo index
-     */
-    private int getComboIndex(int logLevel) {
-        if (logLevel == -1) {
-            return 0;
-        }
-
-        return 7 - logLevel;
-    }
-
-    /**
-     * Validates the content of the 2 text fields and enable/disable "ok", while
-     * setting up the warning/error message.
-     */
-    private void validate() {
-
-        // then we check it only contains digits.
-        if (mPid != null) {
-            if (mPid.matches("[0-9]*") == false) { // $NON-NLS-1$
-                mOkButton.setEnabled(false);
-                mPidWarning.setImage(mImageLoader.loadImage(
-                        "warning.png", // $NON-NLS-1$
-                        mShell.getDisplay()));
-                return;
-            } else {
-                mPidWarning.setImage(mImageLoader.loadImage(
-                        "empty.png", // $NON-NLS-1$
-                        mShell.getDisplay()));
-            }
-        }
-
-        if (mName == null || mName.length() == 0) {
-            mOkButton.setEnabled(false);
-            return;
-        }
-
-        mOkButton.setEnabled(true);
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogColors.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogColors.java
deleted file mode 100644
index 9cff656..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogColors.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.logcat;
-
-import org.eclipse.swt.graphics.Color;
-
-public class LogColors {
-    public Color infoColor;
-    public Color debugColor;
-    public Color errorColor;
-    public Color warningColor;
-    public Color verboseColor;
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogFilter.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogFilter.java
deleted file mode 100644
index a32de2f..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogFilter.java
+++ /dev/null
@@ -1,555 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.logcat;
-
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.annotation.UiThread;
-import com.android.ddmuilib.logcat.LogPanel.LogMessage;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.widgets.ScrollBar;
-import org.eclipse.swt.widgets.TabItem;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.ArrayList;
-import java.util.regex.PatternSyntaxException;
-
-/** logcat output filter class */
-public class LogFilter {
-
-    public final static int MODE_PID = 0x01;
-    public final static int MODE_TAG = 0x02;
-    public final static int MODE_LEVEL = 0x04;
-
-    private String mName;
-
-    /**
-     * Filtering mode. Value can be a mix of MODE_PID, MODE_TAG, MODE_LEVEL
-     */
-    private int mMode = 0;
-
-    /**
-     * pid used for filtering. Only valid if mMode is MODE_PID.
-     */
-    private int mPid;
-
-    /** Single level log level as defined in Log.mLevelChar. Only valid
-     * if mMode is MODE_LEVEL */
-    private int mLogLevel;
-
-    /**
-     * log tag filtering. Only valid if mMode is MODE_TAG
-     */
-    private String mTag;
-
-    private Table mTable;
-    private TabItem mTabItem;
-    private boolean mIsCurrentTabItem = false;
-    private int mUnreadCount = 0;
-
-    /** Temp keyword filtering */
-    private String[] mTempKeywordFilters;
-
-    /** temp pid filtering */
-    private int mTempPid = -1;
-
-    /** temp tag filtering */
-    private String mTempTag;
-
-    /** temp log level filtering */
-    private int mTempLogLevel = -1;
-
-    private LogColors mColors;
-
-    private boolean mTempFilteringStatus = false;
-    
-    private final ArrayList<LogMessage> mMessages = new ArrayList<LogMessage>();
-    private final ArrayList<LogMessage> mNewMessages = new ArrayList<LogMessage>();
-
-    private boolean mSupportsDelete = true;
-    private boolean mSupportsEdit = true;
-    private int mRemovedMessageCount = 0;
-
-    /**
-     * Creates a filter with a particular mode.
-     * @param name The name to be displayed in the UI
-     */
-    public LogFilter(String name) {
-        mName = name;
-    }
-
-    public LogFilter() {
-
-    }
-
-    @Override
-    public String toString() {
-        StringBuilder sb = new StringBuilder(mName);
-
-        sb.append(':');
-        sb.append(mMode);
-        if ((mMode & MODE_PID) == MODE_PID) {
-            sb.append(':');
-            sb.append(mPid);
-        }
-
-        if ((mMode & MODE_LEVEL) == MODE_LEVEL) {
-            sb.append(':');
-            sb.append(mLogLevel);
-        }
-
-        if ((mMode & MODE_TAG) == MODE_TAG) {
-            sb.append(':');
-            sb.append(mTag);
-        }
-
-        return sb.toString();
-    }
-
-    public boolean loadFromString(String string) {
-        String[] segments = string.split(":"); // $NON-NLS-1$
-        int index = 0;
-
-        // get the name
-        mName = segments[index++];
-
-        // get the mode
-        mMode = Integer.parseInt(segments[index++]);
-
-        if ((mMode & MODE_PID) == MODE_PID) {
-            mPid = Integer.parseInt(segments[index++]);
-        }
-
-        if ((mMode & MODE_LEVEL) == MODE_LEVEL) {
-            mLogLevel = Integer.parseInt(segments[index++]);
-        }
-
-        if ((mMode & MODE_TAG) == MODE_TAG) {
-            mTag = segments[index++];
-        }
-
-        return true;
-    }
-
-
-    /** Sets the name of the filter. */
-    void setName(String name) {
-        mName = name;
-    }
-
-    /**
-     * Returns the UI display name.
-     */
-    public String getName() {
-        return mName;
-    }
-
-    /**
-     * Set the Table ui widget associated with this filter.
-     * @param tabItem The item in the TabFolder
-     * @param table The Table object
-     */
-    public void setWidgets(TabItem tabItem, Table table) {
-        mTable = table;
-        mTabItem = tabItem;
-    }
-
-    /**
-     * Returns true if the filter is ready for ui.
-     */
-    public boolean uiReady() {
-        return (mTable != null && mTabItem != null);
-    }
-
-    /**
-     * Returns the UI table object.
-     * @return
-     */
-    public Table getTable() {
-        return mTable;
-    }
-
-    public void dispose() {
-        mTable.dispose();
-        mTabItem.dispose();
-        mTable = null;
-        mTabItem = null;
-    }
-
-    /**
-     * Resets the filtering mode to be 0 (i.e. no filter).
-     */
-    public void resetFilteringMode() {
-        mMode = 0;
-    }
-
-    /**
-     * Returns the current filtering mode.
-     * @return A bitmask. Possible values are MODE_PID, MODE_TAG, MODE_LEVEL
-     */
-    public int getFilteringMode() {
-        return mMode;
-    }
-
-    /**
-     * Adds PID to the current filtering mode.
-     * @param pid
-     */
-    public void setPidMode(int pid) {
-        if (pid != -1) {
-            mMode |= MODE_PID;
-        } else {
-            mMode &= ~MODE_PID;
-        }
-        mPid = pid;
-    }
-
-    /** Returns the pid filter if valid, otherwise -1 */
-    public int getPidFilter() {
-        if ((mMode & MODE_PID) == MODE_PID)
-            return mPid;
-        return -1;
-    }
-
-    public void setTagMode(String tag) {
-        if (tag != null && tag.length() > 0) {
-            mMode |= MODE_TAG;
-        } else {
-            mMode &= ~MODE_TAG;
-        }
-        mTag = tag;
-    }
-
-    public String getTagFilter() {
-        if ((mMode & MODE_TAG) == MODE_TAG)
-            return mTag;
-        return null;
-    }
-
-    public void setLogLevel(int level) {
-        if (level == -1) {
-            mMode &= ~MODE_LEVEL;
-        } else {
-            mMode |= MODE_LEVEL;
-            mLogLevel = level;
-        }
-
-    }
-
-    public int getLogLevel() {
-        if ((mMode & MODE_LEVEL) == MODE_LEVEL) {
-            return mLogLevel;
-        }
-
-        return -1;
-    }
-
-
-    public boolean supportsDelete() {
-        return mSupportsDelete ;
-    }
-
-    public boolean supportsEdit() {
-        return mSupportsEdit;
-    }
-
-    /**
-     * Sets the selected state of the filter.
-     * @param selected selection state.
-     */
-    public void setSelectedState(boolean selected) {
-        if (selected) {
-            if (mTabItem != null) {
-                mTabItem.setText(mName);
-            }
-            mUnreadCount = 0;
-        }
-        mIsCurrentTabItem = selected;
-    }
-    
-    /**
-     * Adds a new message and optionally removes an old message.
-     * <p/>The new message is filtered through {@link #accept(LogMessage)}.
-     * Calls to {@link #flush()} from a UI thread will display it (and other
-     * pending messages) to the associated {@link Table}.
-     * @param logMessage the MessageData object to filter
-     * @return true if the message was accepted.
-     */
-    public boolean addMessage(LogMessage newMessage, LogMessage oldMessage) {
-        synchronized (mMessages) {
-            if (oldMessage != null) {
-                int index = mMessages.indexOf(oldMessage);
-                if (index != -1) {
-                    // TODO check that index will always be -1 or 0, as only the oldest message is ever removed.
-                    mMessages.remove(index);
-                    mRemovedMessageCount++;
-                }
-                
-                // now we look for it in mNewMessages. This can happen if the new message is added
-                // and then removed because too many messages are added between calls to #flush()
-                index = mNewMessages.indexOf(oldMessage);
-                if (index != -1) {
-                    // TODO check that index will always be -1 or 0, as only the oldest message is ever removed.
-                    mNewMessages.remove(index);
-                }
-            }
-
-            boolean filter = accept(newMessage);
-
-            if (filter) {
-                // at this point the message is accepted, we add it to the list
-                mMessages.add(newMessage);
-                mNewMessages.add(newMessage);
-            }
-
-            return filter;
-        }
-    }
-    
-    /**
-     * Removes all the items in the filter and its {@link Table}.
-     */
-    public void clear() {
-        mRemovedMessageCount = 0;
-        mNewMessages.clear();
-        mMessages.clear();
-        mTable.removeAll();
-    }
-    
-    /**
-     * Filters a message.
-     * @param logMessage the Message
-     * @return true if the message is accepted by the filter.
-     */
-    boolean accept(LogMessage logMessage) {
-        // do the regular filtering now
-        if ((mMode & MODE_PID) == MODE_PID && mPid != logMessage.data.pid) {
-            return false;
-        }
-
-        if ((mMode & MODE_TAG) == MODE_TAG && (
-                logMessage.data.tag == null ||
-                logMessage.data.tag.equals(mTag) == false)) {
-            return false;
-        }
-
-        int msgLogLevel = logMessage.data.logLevel.getPriority();
-
-        // test the temp log filtering first, as it replaces the old one
-        if (mTempLogLevel != -1) {
-            if (mTempLogLevel > msgLogLevel) {
-                return false;
-            }
-        } else if ((mMode & MODE_LEVEL) == MODE_LEVEL &&
-                mLogLevel > msgLogLevel) {
-            return false;
-        }
-
-        // do the temp filtering now.
-        if (mTempKeywordFilters != null) {
-            String msg = logMessage.msg;
-
-            for (String kw : mTempKeywordFilters) {
-                try {
-                    if (msg.contains(kw) == false && msg.matches(kw) == false) {
-                        return false;
-                    }
-                } catch (PatternSyntaxException e) {
-                    // if the string is not a valid regular expression,
-                    // this exception is thrown.
-                    return false;
-                }
-            }
-        }
-
-        if (mTempPid != -1 && mTempPid != logMessage.data.pid) {
-           return false;
-        }
-
-        if (mTempTag != null && mTempTag.length() > 0) {
-            if (mTempTag.equals(logMessage.data.tag) == false) {
-                return false;
-            }
-        }
-
-        return true;
-    }
-
-    /**
-     * Takes all the accepted messages and display them.
-     * This must be called from a UI thread.
-     */
-    @UiThread
-    public void flush() {
-        // if scroll bar is at the bottom, we will scroll
-        ScrollBar bar = mTable.getVerticalBar();
-        boolean scroll = bar.getMaximum() == bar.getSelection() + bar.getThumb();
-        
-        // if we are not going to scroll, get the current first item being shown.
-        int topIndex = mTable.getTopIndex();
-
-        // disable drawing
-        mTable.setRedraw(false);
-        
-        int totalCount = mNewMessages.size();
-
-        try {
-            // remove the items of the old messages.
-            for (int i = 0 ; i < mRemovedMessageCount && mTable.getItemCount() > 0 ; i++) {
-                mTable.remove(0);
-            }
-    
-            if (mUnreadCount > mTable.getItemCount()) {
-                mUnreadCount = mTable.getItemCount();
-            }
-    
-            // add the new items
-            for (int i = 0  ; i < totalCount ; i++) {
-                LogMessage msg = mNewMessages.get(i);
-                addTableItem(msg);
-            }
-        } catch (SWTException e) {
-            // log the error and keep going. Content of the logcat table maybe unexpected
-            // but at least ddms won't crash.
-            Log.e("LogFilter", e);
-        }
-        
-        // redraw
-        mTable.setRedraw(true);
-
-        // scroll if needed, by showing the last item
-        if (scroll) {
-            totalCount = mTable.getItemCount();
-            if (totalCount > 0) {
-                mTable.showItem(mTable.getItem(totalCount-1));
-            }
-        } else if (mRemovedMessageCount > 0) {
-            // we need to make sure the topIndex is still visible.
-            // Because really old items are removed from the list, this could make it disappear
-            // if we don't change the scroll value at all.
-
-            topIndex -= mRemovedMessageCount;
-            if (topIndex < 0) {
-                // looks like it disappeared. Lets just show the first item
-                mTable.showItem(mTable.getItem(0));
-            } else {
-                mTable.showItem(mTable.getItem(topIndex));
-            }
-        }
-
-        // if this filter is not the current one, we update the tab text
-        // with the amount of unread message
-        if (mIsCurrentTabItem == false) {
-            mUnreadCount += mNewMessages.size();
-            totalCount = mTable.getItemCount();
-            if (mUnreadCount > 0) {
-                mTabItem.setText(mName + " (" // $NON-NLS-1$
-                        + (mUnreadCount > totalCount ? totalCount : mUnreadCount)
-                        + ")");  // $NON-NLS-1$
-            } else {
-                mTabItem.setText(mName);  // $NON-NLS-1$
-            }
-        }
-        
-        mNewMessages.clear();
-    }
-
-    void setColors(LogColors colors) {
-        mColors = colors;
-    }
-
-    int getUnreadCount() {
-        return mUnreadCount;
-    }
-
-    void setUnreadCount(int unreadCount) {
-        mUnreadCount = unreadCount;
-    }
-
-    void setSupportsDelete(boolean support) {
-        mSupportsDelete = support;
-    }
-
-    void setSupportsEdit(boolean support) {
-        mSupportsEdit = support;
-    }
-
-    void setTempKeywordFiltering(String[] segments) {
-        mTempKeywordFilters = segments;
-        mTempFilteringStatus = true;
-    }
-
-    void setTempPidFiltering(int pid) {
-        mTempPid = pid;
-        mTempFilteringStatus = true;
-    }
-
-    void setTempTagFiltering(String tag) {
-        mTempTag = tag;
-        mTempFilteringStatus = true;
-    }
-
-    void resetTempFiltering() {
-        if (mTempPid != -1 || mTempTag != null || mTempKeywordFilters != null) {
-            mTempFilteringStatus = true;
-        }
-
-        mTempPid = -1;
-        mTempTag = null;
-        mTempKeywordFilters = null;
-    }
-
-    void resetTempFilteringStatus() {
-        mTempFilteringStatus = false;
-    }
-
-    boolean getTempFilterStatus() {
-        return mTempFilteringStatus;
-    }
-
-
-    /**
-     * Add a TableItem for the index-th item of the buffer
-     * @param filter The index of the table in which to insert the item.
-     */
-    private void addTableItem(LogMessage msg) {
-        TableItem item = new TableItem(mTable, SWT.NONE);
-        item.setText(0, msg.data.time);
-        item.setText(1, new String(new char[] { msg.data.logLevel.getPriorityLetter() }));
-        item.setText(2, msg.data.pidString);
-        item.setText(3, msg.data.tag);
-        item.setText(4, msg.msg);
-
-        // add the buffer index as data
-        item.setData(msg);
-
-        if (msg.data.logLevel == LogLevel.INFO) {
-            item.setForeground(mColors.infoColor);
-        } else if (msg.data.logLevel == LogLevel.DEBUG) {
-            item.setForeground(mColors.debugColor);
-        } else if (msg.data.logLevel == LogLevel.ERROR) {
-            item.setForeground(mColors.errorColor);
-        } else if (msg.data.logLevel == LogLevel.WARN) {
-            item.setForeground(mColors.warningColor);
-        } else {
-            item.setForeground(mColors.verboseColor);
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogPanel.java b/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogPanel.java
deleted file mode 100644
index bd8b75c..0000000
--- a/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib/logcat/LogPanel.java
+++ /dev/null
@@ -1,1571 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ddmuilib.logcat;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.MultiLineReceiver;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.IImageLoader;
-import com.android.ddmuilib.ITableFocusListener;
-import com.android.ddmuilib.SelectionDependentPanel;
-import com.android.ddmuilib.TableHelper;
-import com.android.ddmuilib.ITableFocusListener.IFocusedTableActivator;
-import com.android.ddmuilib.actions.ICommonAction;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.dnd.TextTransfer;
-import org.eclipse.swt.dnd.Transfer;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.FocusListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-public class LogPanel extends SelectionDependentPanel {
-
-    private static final int STRING_BUFFER_LENGTH = 10000;
-
-    /** no filtering. Only one tab with everything. */
-    public static final int FILTER_NONE = 0;
-    /** manual mode for filter. all filters are manually created. */
-    public static final int FILTER_MANUAL = 1;
-    /** automatic mode for filter (pid mode).
-     * All filters are automatically created. */
-    public static final int FILTER_AUTO_PID = 2;
-    /** automatic mode for filter (tag mode).
-     * All filters are automatically created. */
-    public static final int FILTER_AUTO_TAG = 3;
-    /** Manual filtering mode + new filter for debug app, if needed */
-    public static final int FILTER_DEBUG = 4;
-
-    public static final int COLUMN_MODE_MANUAL = 0;
-    public static final int COLUMN_MODE_AUTO = 1;
-
-    public static String PREFS_TIME;
-    public static String PREFS_LEVEL;
-    public static String PREFS_PID;
-    public static String PREFS_TAG;
-    public static String PREFS_MESSAGE;
-
-    /**
-     * This pattern is meant to parse the first line of a log message with the option
-     * 'logcat -v long'. The first line represents the date, tag, severity, etc.. while the
-     * following lines are the message (can be several line).<br>
-     * This first line looks something like<br>
-     * <code>"[ 00-00 00:00:00.000 &lt;pid&gt;:0x&lt;???&gt; &lt;severity&gt;/&lt;tag&gt;]"</code>
-     * <br>
-     * Note: severity is one of V, D, I, W, or EM<br>
-     * Note: the fraction of second value can have any number of digit.
-     * Note the tag should be trim as it may have spaces at the end.
-     */
-    private static Pattern sLogPattern = Pattern.compile(
-            "^\\[\\s(\\d\\d-\\d\\d\\s\\d\\d:\\d\\d:\\d\\d\\.\\d+)" + //$NON-NLS-1$
-            "\\s+(\\d*):(0x[0-9a-fA-F]+)\\s([VDIWE])/(.*)\\]$"); //$NON-NLS-1$
-
-    /**
-     * Interface for Storage Filter manager. Implementation of this interface
-     * provide a custom way to archive an reload filters.
-     */
-    public interface ILogFilterStorageManager {
-
-        public LogFilter[] getFilterFromStore();
-
-        public void saveFilters(LogFilter[] filters);
-
-        public boolean requiresDefaultFilter();
-    }
-
-    private Composite mParent;
-    private IPreferenceStore mStore;
-
-    /** top object in the view */
-    private TabFolder mFolders;
-
-    private LogColors mColors;
-
-    private ILogFilterStorageManager mFilterStorage;
-
-    private LogCatOuputReceiver mCurrentLogCat;
-
-    /**
-     * Circular buffer containing the logcat output. This is unfiltered.
-     * The valid content goes from <code>mBufferStart</code> to
-     * <code>mBufferEnd - 1</code>. Therefore its number of item is
-     * <code>mBufferEnd - mBufferStart</code>.
-     */
-    private LogMessage[] mBuffer = new LogMessage[STRING_BUFFER_LENGTH];
-
-    /** Represents the oldest message in the buffer */
-    private int mBufferStart = -1;
-
-    /**
-     * Represents the next usable item in the buffer to receive new message.
-     * This can be equal to mBufferStart, but when used mBufferStart will be
-     * incremented as well.
-     */
-    private int mBufferEnd = -1;
-
-    /** Filter list */
-    private LogFilter[] mFilters;
-
-    /** Default filter */
-    private LogFilter mDefaultFilter;
-
-    /** Current filter being displayed */
-    private LogFilter mCurrentFilter;
-
-    /** Filtering mode */
-    private int mFilterMode = FILTER_NONE;
-
-    /** Device currently running logcat */
-    private Device mCurrentLoggedDevice = null;
-
-    private ICommonAction mDeleteFilterAction;
-    private ICommonAction mEditFilterAction;
-
-    private ICommonAction[] mLogLevelActions;
-    
-    /** message data, separated from content for multi line messages */
-    protected static class LogMessageInfo {
-        public LogLevel logLevel;
-        public int pid;
-        public String pidString;
-        public String tag;
-        public String time;
-    }
-
-    /** pointer to the latest LogMessageInfo. this is used for multi line
-     * log message, to reuse the info regarding level, pid, etc...
-     */
-    private LogMessageInfo mLastMessageInfo = null;
-    
-    private boolean mPendingAsyncRefresh = false;
-
-    /** loader for the images. the implementation will varie between standalone
-     * app and eclipse plugin app and eclipse plugin. */
-    private IImageLoader mImageLoader;
-
-    private String mDefaultLogSave;
-
-    private int mColumnMode = COLUMN_MODE_MANUAL;
-    private Font mDisplayFont;
-
-    private ITableFocusListener mGlobalListener;
-
-    /** message data, separated from content for multi line messages */
-    protected static class LogMessage {
-        public LogMessageInfo data;
-        public String msg;
-
-        @Override
-        public String toString() {
-            return data.time + ": " //$NON-NLS-1$
-                + data.logLevel + "/" //$NON-NLS-1$
-                + data.tag + "(" //$NON-NLS-1$
-                + data.pidString + "): " //$NON-NLS-1$
-                + msg;
-        }
-    }
-
-    /**
-     * objects able to receive the output of a remote shell command,
-     * specifically a logcat command in this case
-     */
-    private final class LogCatOuputReceiver extends MultiLineReceiver {
-
-        public boolean isCancelled = false;
-
-        public LogCatOuputReceiver() {
-            super();
-
-            setTrimLine(false);
-        }
-
-        @Override
-        public void processNewLines(String[] lines) {
-            if (isCancelled == false) {
-                processLogLines(lines);
-            }
-        }
-
-        public boolean isCancelled() {
-            return isCancelled;
-        }
-    }
-
-    /**
-     * Parser class for the output of a "ps" shell command executed on a device.
-     * This class looks for a specific pid to find the process name from it.
-     * Once found, the name is used to update a filter and a tab object
-     *
-     */
-    private class PsOutputReceiver extends MultiLineReceiver {
-
-        private LogFilter mFilter;
-
-        private TabItem mTabItem;
-
-        private int mPid;
-
-        /** set to true when we've found the pid we're looking for */
-        private boolean mDone = false;
-
-        PsOutputReceiver(int pid, LogFilter filter, TabItem tabItem) {
-            mPid = pid;
-            mFilter = filter;
-            mTabItem = tabItem;
-        }
-
-        public boolean isCancelled() {
-            return mDone;
-        }
-
-        @Override
-        public void processNewLines(String[] lines) {
-            for (String line : lines) {
-                if (line.startsWith("USER")) { //$NON-NLS-1$
-                    continue;
-                }
-                // get the pid.
-                int index = line.indexOf(' ');
-                if (index == -1) {
-                    continue;
-                }
-                // look for the next non blank char
-                index++;
-                while (line.charAt(index) == ' ') {
-                    index++;
-                }
-
-                // this is the start of the pid.
-                // look for the end.
-                int index2 = line.indexOf(' ', index);
-
-                // get the line
-                String pidStr = line.substring(index, index2);
-                int pid = Integer.parseInt(pidStr);
-                if (pid != mPid) {
-                    continue;
-                } else {
-                    // get the process name
-                    index = line.lastIndexOf(' ');
-                    final String name = line.substring(index + 1);
-
-                    mFilter.setName(name);
-
-                    // update the tab
-                    Display d = mFolders.getDisplay();
-                    d.asyncExec(new Runnable() {
-                       public void run() {
-                           mTabItem.setText(name);
-                       }
-                    });
-
-                    // we're done with this ps.
-                    mDone = true;
-                    return;
-                }
-            }
-        }
-
-    }
-
-
-    /**
-     * Create the log view with some default parameters
-     * @param imageLoader the image loader.
-     * @param colors The display color object
-     * @param filterStorage the storage for user defined filters.
-     * @param mode The filtering mode
-     */
-    public LogPanel(IImageLoader imageLoader, LogColors colors,
-            ILogFilterStorageManager filterStorage, int mode) {
-        mImageLoader = imageLoader;
-        mColors = colors;
-        mFilterMode = mode;
-        mFilterStorage = filterStorage;
-        mStore = DdmUiPreferences.getStore();
-    }
-
-    public void setActions(ICommonAction deleteAction, ICommonAction editAction,
-            ICommonAction[] logLevelActions) {
-        mDeleteFilterAction = deleteAction;
-        mEditFilterAction = editAction;
-        mLogLevelActions = logLevelActions;
-    }
-
-    /**
-     * Sets the column mode. Must be called before creatUI
-     * @param mode the column mode. Valid values are COLUMN_MOD_MANUAL and
-     *  COLUMN_MODE_AUTO
-     */
-    public void setColumnMode(int mode) {
-        mColumnMode  = mode;
-    }
-
-    /**
-     * Sets the display font.
-     * @param font The display font.
-     */
-    public void setFont(Font font) {
-        mDisplayFont = font;
-
-        if (mFilters != null) {
-            for (LogFilter f : mFilters) {
-                Table table = f.getTable();
-                if (table != null) {
-                    table.setFont(font);
-                }
-            }
-        }
-
-        if (mDefaultFilter != null) {
-            Table table = mDefaultFilter.getTable();
-            if (table != null) {
-                table.setFont(font);
-            }
-        }
-    }
-
-    /**
-     * Sent when a new device is selected. The new device can be accessed
-     * with {@link #getCurrentDevice()}.
-     */
-    @Override
-    public void deviceSelected() {
-        startLogCat(getCurrentDevice());
-    }
-
-    /**
-     * Sent when a new client is selected. The new client can be accessed
-     * with {@link #getCurrentClient()}.
-     */
-    @Override
-    public void clientSelected() {
-        // pass
-    }
-
-
-    /**
-     * Creates a control capable of displaying some information.  This is
-     * called once, when the application is initializing, from the UI thread.
-     */
-    @Override
-    protected Control createControl(Composite parent) {
-        mParent = parent;
-
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayoutData(new GridData(GridData.FILL_BOTH));
-        top.setLayout(new GridLayout(1, false));
-
-        // create the tab folder
-        mFolders = new TabFolder(top, SWT.NONE);
-        mFolders.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mFolders.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mCurrentFilter != null) {
-                    mCurrentFilter.setSelectedState(false);
-                }
-                mCurrentFilter = getCurrentFilter();
-                mCurrentFilter.setSelectedState(true);
-                updateColumns(mCurrentFilter.getTable());
-                if (mCurrentFilter.getTempFilterStatus()) {
-                    initFilter(mCurrentFilter);
-                }
-                selectionChanged(mCurrentFilter);
-            }
-        });
-
-
-        Composite bottom = new Composite(top, SWT.NONE);
-        bottom.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        bottom.setLayout(new GridLayout(3, false));
-
-        Label label = new Label(bottom, SWT.NONE);
-        label.setText("Filter:");
-
-        final Text filterText = new Text(bottom, SWT.SINGLE | SWT.BORDER);
-        filterText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        filterText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                updateFilteringWith(filterText.getText());
-            }
-        });
-
-        /*
-        Button addFilterBtn = new Button(bottom, SWT.NONE);
-        addFilterBtn.setImage(mImageLoader.loadImage("add.png", //$NON-NLS-1$
-                addFilterBtn.getDisplay()));
-        */
-
-        // get the filters
-        createFilters();
-
-        // for each filter, create a tab.
-        int index = 0;
-
-        if (mDefaultFilter != null) {
-            createTab(mDefaultFilter, index++, false);
-        }
-
-        if (mFilters != null) {
-            for (LogFilter f : mFilters) {
-                createTab(f, index++, false);
-            }
-        }
-
-        return top;
-    }
-
-    @Override
-    protected void postCreation() {
-        // pass
-    }
-
-    /**
-     * Sets the focus to the proper object.
-     */
-    @Override
-    public void setFocus() {
-        mFolders.setFocus();
-    }
-
-
-    /**
-     * Starts a new logcat and set mCurrentLogCat as the current receiver.
-     * @param device the device to connect logcat to.
-     */
-    public void startLogCat(final Device device) {
-        if (device == mCurrentLoggedDevice) {
-            return;
-        }
-
-        // if we have a logcat already running
-        if (mCurrentLoggedDevice != null) {
-            stopLogCat(false);
-            mCurrentLoggedDevice = null;
-        }
-        
-        resetUI(false);
-
-        if (device != null) {
-            // create a new output receiver
-            mCurrentLogCat = new LogCatOuputReceiver();
-
-            // start the logcat in a different thread
-            new Thread("Logcat")  { //$NON-NLS-1$
-                @Override
-                public void run() {
-
-                    while (device.isOnline() == false &&
-                            mCurrentLogCat != null &&
-                            mCurrentLogCat.isCancelled == false) {
-                        try {
-                            sleep(2000);
-                        } catch (InterruptedException e) {
-                            return;
-                        }
-                    }
-
-                    if (mCurrentLogCat == null || mCurrentLogCat.isCancelled) {
-                        // logcat was stopped/cancelled before the device became ready.
-                        return;
-                    }
-
-                    try {
-                        mCurrentLoggedDevice = device;
-                        device.executeShellCommand("logcat -v long", mCurrentLogCat); //$NON-NLS-1$
-                    } catch (Exception e) {
-                        Log.e("Logcat", e);
-                    } finally {
-                        // at this point the command is terminated.
-                        mCurrentLogCat = null;
-                        mCurrentLoggedDevice = null;
-                    }
-                }
-            }.start();
-        }
-    }
-
-    /** Stop the current logcat */
-    public void stopLogCat(boolean inUiThread) {
-        if (mCurrentLogCat != null) {
-            mCurrentLogCat.isCancelled = true;
-
-            // when the thread finishes, no one will reference that object
-            // and it'll be destroyed
-            mCurrentLogCat = null;
-
-            // reset the content buffer
-            for (int i = 0 ; i < STRING_BUFFER_LENGTH; i++) {
-                mBuffer[i] = null;
-            }
-
-            // because it's a circular buffer, it's hard to know if
-            // the array is empty with both start/end at 0 or if it's full
-            // with both start/end at 0 as well. So to mean empty, we use -1
-            mBufferStart = -1;
-            mBufferEnd = -1;
-
-            resetFilters();
-            resetUI(inUiThread);
-        }
-    }
-
-    /**
-     * Adds a new Filter. This methods displays the UI to create the filter
-     * and set up its parameters.<br>
-     * <b>MUST</b> be called from the ui thread.
-     *
-     */
-    public void addFilter() {
-        EditFilterDialog dlg = new EditFilterDialog(mImageLoader,
-                mFolders.getShell());
-        if (dlg.open()) {
-            synchronized (mBuffer) {
-                // get the new filter in the array
-                LogFilter filter = dlg.getFilter();
-                addFilterToArray(filter);
-
-                int index = mFilters.length - 1;
-                if (mDefaultFilter != null) {
-                    index++;
-                }
-
-                if (false) {
-
-                    for (LogFilter f : mFilters) {
-                        if (f.uiReady()) {
-                            f.dispose();
-                        }
-                    }
-                    if (mDefaultFilter != null && mDefaultFilter.uiReady()) {
-                        mDefaultFilter.dispose();
-                    }
-
-                    // for each filter, create a tab.
-                    int i = 0;
-                    if (mFilters != null) {
-                        for (LogFilter f : mFilters) {
-                            createTab(f, i++, true);
-                        }
-                    }
-                    if (mDefaultFilter != null) {
-                        createTab(mDefaultFilter, i++, true);
-                    }
-                } else {
-
-                    // create ui for the filter.
-                    createTab(filter, index, true);
-
-                    // reset the default as it shouldn't contain the content of
-                    // this new filter.
-                    if (mDefaultFilter != null) {
-                        initDefaultFilter();
-                    }
-                }
-
-                // select the new filter
-                if (mCurrentFilter != null) {
-                    mCurrentFilter.setSelectedState(false);
-                }
-                mFolders.setSelection(index);
-                filter.setSelectedState(true);
-                mCurrentFilter = filter;
-
-                selectionChanged(filter);
-
-                // finally we update the filtering mode if needed
-                if (mFilterMode == FILTER_NONE) {
-                    mFilterMode = FILTER_MANUAL;
-                }
-
-                mFilterStorage.saveFilters(mFilters);
-
-            }
-        }
-    }
-
-    /**
-     * Edits the current filter. The method displays the UI to edit the filter.
-     */
-    public void editFilter() {
-        if (mCurrentFilter != null && mCurrentFilter != mDefaultFilter) {
-            EditFilterDialog dlg = new EditFilterDialog(mImageLoader,
-                    mFolders.getShell(),
-                    mCurrentFilter);
-            if (dlg.open()) {
-                synchronized (mBuffer) {
-                    // at this point the filter has been updated.
-                    // so we update its content
-                    initFilter(mCurrentFilter);
-
-                    // and the content of the "other" filter as well.
-                    if (mDefaultFilter != null) {
-                        initDefaultFilter();
-                    }
-
-                    mFilterStorage.saveFilters(mFilters);
-                }
-            }
-        }
-    }
-
-    /**
-     * Deletes the current filter.
-     */
-    public void deleteFilter() {
-        synchronized (mBuffer) {
-            if (mCurrentFilter != null && mCurrentFilter != mDefaultFilter) {
-                // remove the filter from the list
-                removeFilterFromArray(mCurrentFilter);
-                mCurrentFilter.dispose();
-
-                // select the new filter
-                mFolders.setSelection(0);
-                if (mFilters.length > 0) {
-                    mCurrentFilter = mFilters[0];
-                } else {
-                    mCurrentFilter = mDefaultFilter;
-                }
-
-                selectionChanged(mCurrentFilter);
-
-                // update the content of the "other" filter to include what was filtered out
-                // by the deleted filter.
-                if (mDefaultFilter != null) {
-                    initDefaultFilter();
-                }
-
-                mFilterStorage.saveFilters(mFilters);
-            }
-        }
-    }
-
-    /**
-     * saves the current selection in a text file.
-     * @return false if the saving failed.
-     */
-    public boolean save() {
-        synchronized (mBuffer) {
-            FileDialog dlg = new FileDialog(mParent.getShell(), SWT.SAVE);
-            String fileName;
-    
-            dlg.setText("Save log...");
-            dlg.setFileName("log.txt");
-            String defaultPath = mDefaultLogSave;
-            if (defaultPath == null) {
-                defaultPath = System.getProperty("user.home"); //$NON-NLS-1$
-            }
-            dlg.setFilterPath(defaultPath);
-            dlg.setFilterNames(new String[] {
-                "Text Files (*.txt)"
-            });
-            dlg.setFilterExtensions(new String[] {
-                "*.txt"
-            });
-    
-            fileName = dlg.open();
-            if (fileName != null) {
-                mDefaultLogSave = dlg.getFilterPath();
-
-                // get the current table and its selection
-                Table currentTable = mCurrentFilter.getTable();
-
-                int[] selection = currentTable.getSelectionIndices();
-
-                // we need to sort the items to be sure.
-                Arrays.sort(selection);
-
-                // loop on the selection and output the file.
-                try {
-                    FileWriter writer = new FileWriter(fileName);
-
-                    for (int i : selection) {
-                        TableItem item = currentTable.getItem(i);
-                        LogMessage msg = (LogMessage)item.getData();
-                        String line = msg.toString();
-                        writer.write(line);
-                        writer.write('\n');
-                    }
-                    writer.flush();
-
-                } catch (IOException e) {
-                    return false;
-                }
-            }
-        }
-
-        return true;
-    }
-
-    /**
-     * Empty the current circular buffer.
-     */
-    public void clear() {
-        synchronized (mBuffer) {
-            for (int i = 0 ; i < STRING_BUFFER_LENGTH; i++) {
-                mBuffer[i] = null;
-            }
-
-            mBufferStart = -1;
-            mBufferEnd = -1;
-
-            // now we clear the existing filters
-            for (LogFilter filter : mFilters) {
-                filter.clear();
-            }
-
-            // and the default one
-            if (mDefaultFilter != null) {
-                mDefaultFilter.clear();
-            }
-        }
-    }
-
-    /**
-     * Copies the current selection of the current filter as multiline text.
-     *
-     * @param clipboard The clipboard to place the copied content.
-     */
-    public void copy(Clipboard clipboard) {
-        // get the current table and its selection
-        Table currentTable = mCurrentFilter.getTable();
-
-        copyTable(clipboard, currentTable);
-    }
-
-    /**
-     * Selects all lines.
-     */
-    public void selectAll() {
-        Table currentTable = mCurrentFilter.getTable();
-        currentTable.selectAll();
-    }
-
-    /**
-     * Sets a TableFocusListener which will be notified when one of the tables
-     * gets or loses focus.
-     *
-     * @param listener
-     */
-    public void setTableFocusListener(ITableFocusListener listener) {
-        // record the global listener, to make sure table created after
-        // this call will still be setup.
-        mGlobalListener = listener;
-
-        // now we setup the existing filters
-        for (LogFilter filter : mFilters) {
-            Table table = filter.getTable();
-
-            addTableToFocusListener(table);
-        }
-
-        // and the default one
-        if (mDefaultFilter != null) {
-            addTableToFocusListener(mDefaultFilter.getTable());
-        }
-    }
-
-    /**
-     * Sets up a Table object to notify the global Table Focus listener when it
-     * gets or loses the focus.
-     *
-     * @param table the Table object.
-     */
-    private void addTableToFocusListener(final Table table) {
-        // create the activator for this table
-        final IFocusedTableActivator activator = new IFocusedTableActivator() {
-            public void copy(Clipboard clipboard) {
-                copyTable(clipboard, table);
-            }
-
-            public void selectAll() {
-                table.selectAll();
-            }
-        };
-
-        // add the focus listener on the table to notify the global listener
-        table.addFocusListener(new FocusListener() {
-            public void focusGained(FocusEvent e) {
-                mGlobalListener.focusGained(activator);
-            }
-
-            public void focusLost(FocusEvent e) {
-                mGlobalListener.focusLost(activator);
-            }
-        });
-    }
-
-    /**
-     * Copies the current selection of a Table into the provided Clipboard, as
-     * multi-line text.
-     *
-     * @param clipboard The clipboard to place the copied content.
-     * @param table The table to copy from.
-     */
-    private static void copyTable(Clipboard clipboard, Table table) {
-        int[] selection = table.getSelectionIndices();
-
-        // we need to sort the items to be sure.
-        Arrays.sort(selection);
-
-        // all lines must be concatenated.
-        StringBuilder sb = new StringBuilder();
-
-        // loop on the selection and output the file.
-        for (int i : selection) {
-            TableItem item = table.getItem(i);
-            LogMessage msg = (LogMessage)item.getData();
-            String line = msg.toString();
-            sb.append(line);
-            sb.append('\n');
-        }
-
-        // now add that to the clipboard
-        clipboard.setContents(new Object[] {
-            sb.toString()
-        }, new Transfer[] {
-            TextTransfer.getInstance()
-        });
-    }
-
-    /**
-     * Sets the log level for the current filter, but does not save it.
-     * @param i
-     */
-    public void setCurrentFilterLogLevel(int i) {
-        LogFilter filter = getCurrentFilter();
-
-        filter.setLogLevel(i);
-
-        initFilter(filter);
-    }
-
-    /**
-     * Creates a new tab in the folderTab item. Must be called from the ui
-     *      thread.
-     * @param filter The filter associated with the tab.
-     * @param index the index of the tab. if -1, the tab will be added at the
-     *          end.
-     * @param fillTable If true the table is filled with the current content of
-     *          the buffer.
-     * @return The TabItem object that was created.
-     */
-    private TabItem createTab(LogFilter filter, int index, boolean fillTable) {
-        synchronized (mBuffer) {
-            TabItem item = null;
-            if (index != -1) {
-                item = new TabItem(mFolders, SWT.NONE, index);
-            } else {
-                item = new TabItem(mFolders, SWT.NONE);
-            }
-            item.setText(filter.getName());
-
-            // set the control (the parent is the TabFolder item, always)
-            Composite top = new Composite(mFolders, SWT.NONE);
-            item.setControl(top);
-
-            top.setLayout(new FillLayout());
-
-            // create the ui, first the table
-            final Table t = new Table(top, SWT.MULTI | SWT.FULL_SELECTION);
-
-            if (mDisplayFont != null) {
-                t.setFont(mDisplayFont);
-            }
-
-            // give the ui objects to the filters.
-            filter.setWidgets(item, t);
-
-            t.setHeaderVisible(true);
-            t.setLinesVisible(false);
-
-            if (mGlobalListener != null) {
-            	addTableToFocusListener(t);
-            }
-
-            // create a controllistener that will handle the resizing of all the
-            // columns (except the last) and of the table itself.
-            ControlListener listener = null;
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                listener = new ControlListener() {
-                    public void controlMoved(ControlEvent e) {
-                    }
-
-                    public void controlResized(ControlEvent e) {
-                        Rectangle r = t.getClientArea();
-
-                        // get the size of all but the last column
-                        int total = t.getColumn(0).getWidth();
-                        total += t.getColumn(1).getWidth();
-                        total += t.getColumn(2).getWidth();
-                        total += t.getColumn(3).getWidth();
-
-                        if (r.width > total) {
-                            t.getColumn(4).setWidth(r.width-total);
-                        }
-                    }
-                };
-
-                t.addControlListener(listener);
-            }
-
-            // then its column
-            TableColumn col = TableHelper.createTableColumn(t, "Time", SWT.LEFT,
-                    "00-00 00:00:00", //$NON-NLS-1$
-                    PREFS_TIME, mStore);
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                col.addControlListener(listener);
-            }
-
-            col = TableHelper.createTableColumn(t, "", SWT.CENTER,
-                    "D", //$NON-NLS-1$
-                    PREFS_LEVEL, mStore);
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                col.addControlListener(listener);
-            }
-
-            col = TableHelper.createTableColumn(t, "pid", SWT.LEFT,
-                    "9999", //$NON-NLS-1$
-                    PREFS_PID, mStore);
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                col.addControlListener(listener);
-            }
-
-            col = TableHelper.createTableColumn(t, "tag", SWT.LEFT,
-                    "abcdefgh",  //$NON-NLS-1$
-                    PREFS_TAG, mStore);
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                col.addControlListener(listener);
-            }
-
-            col = TableHelper.createTableColumn(t, "Message", SWT.LEFT,
-                    "abcdefghijklmnopqrstuvwxyz0123456789",  //$NON-NLS-1$
-                    PREFS_MESSAGE, mStore);
-            if (mColumnMode == COLUMN_MODE_AUTO) {
-                // instead of listening on resize for the last column, we make
-                // it non resizable.
-                col.setResizable(false);
-            }
-
-            if (fillTable) {
-                initFilter(filter);
-            }
-            return item;
-        }
-    }
-
-    protected void updateColumns(Table table) {
-        if (table != null) {
-            int index = 0;
-            TableColumn col;
-
-            col = table.getColumn(index++);
-            col.setWidth(mStore.getInt(PREFS_TIME));
-
-            col = table.getColumn(index++);
-            col.setWidth(mStore.getInt(PREFS_LEVEL));
-
-            col = table.getColumn(index++);
-            col.setWidth(mStore.getInt(PREFS_PID));
-
-            col = table.getColumn(index++);
-            col.setWidth(mStore.getInt(PREFS_TAG));
-
-            col = table.getColumn(index++);
-            col.setWidth(mStore.getInt(PREFS_MESSAGE));
-        }
-    }
-
-    public void resetUI(boolean inUiThread) {
-        if (mFilterMode == FILTER_AUTO_PID || mFilterMode == FILTER_AUTO_TAG) {
-            if (inUiThread) {
-                mFolders.dispose();
-                mParent.pack(true);
-                createControl(mParent);
-            } else {
-                Display d = mFolders.getDisplay();
-
-                // run sync as we need to update right now.
-                d.syncExec(new Runnable() {
-                    public void run() {
-                        mFolders.dispose();
-                        mParent.pack(true);
-                        createControl(mParent);
-                    }
-                });
-            }
-        } else  {
-            // the ui is static we just empty it.
-            if (mFolders.isDisposed() == false) {
-                if (inUiThread) {
-                    emptyTables();
-                } else {
-                    Display d = mFolders.getDisplay();
-
-                    // run sync as we need to update right now.
-                    d.syncExec(new Runnable() {
-                        public void run() {
-                            if (mFolders.isDisposed() == false) {
-                                emptyTables();
-                            }
-                        }
-                    });
-                }
-            }
-        }
-    }
-
-    /**
-     * Process new Log lines coming from {@link LogCatOuputReceiver}. 
-     * @param lines the new lines
-     */
-    protected void processLogLines(String[] lines) {
-        // WARNING: this will not work if the string contains more line than
-        // the buffer holds.
-
-        if (lines.length > STRING_BUFFER_LENGTH) {
-            Log.e("LogCat", "Receiving more lines than STRING_BUFFER_LENGTH");
-        }
-        
-        // parse the lines and create LogMessage that are stored in a temporary list
-        final ArrayList<LogMessage> newMessages = new ArrayList<LogMessage>();
-        
-        synchronized (mBuffer) {
-            for (String line : lines) {
-                // ignore empty lines.
-                if (line.length() > 0) {
-                    // check for header lines.
-                    Matcher matcher = sLogPattern.matcher(line);
-                    if (matcher.matches()) {
-                        // this is a header line, parse the header and keep it around.
-                        mLastMessageInfo = new LogMessageInfo();
-    
-                        mLastMessageInfo.time = matcher.group(1);
-                        mLastMessageInfo.pidString = matcher.group(2);
-                        mLastMessageInfo.pid = Integer.valueOf(mLastMessageInfo.pidString);
-                        mLastMessageInfo.logLevel = LogLevel.getByLetterString(matcher.group(4));
-                        mLastMessageInfo.tag = matcher.group(5).trim();
-                    } else {
-                        // This is not a header line.
-                        // Create a new LogMessage and process it.
-                        LogMessage mc = new LogMessage();
-    
-                        if (mLastMessageInfo == null) {
-                            // The first line of output wasn't preceded
-                            // by a header line; make something up so
-                            // that users of mc.data don't NPE.
-                            mLastMessageInfo = new LogMessageInfo();
-                            mLastMessageInfo.time = "??-?? ??:??:??.???"; //$NON-NLS1$
-                            mLastMessageInfo.pidString = "<unknown>"; //$NON-NLS1$
-                            mLastMessageInfo.pid = 0;
-                            mLastMessageInfo.logLevel = LogLevel.INFO;
-                            mLastMessageInfo.tag = "<unknown>"; //$NON-NLS1$
-                        }
-    
-                        // If someone printed a log message with
-                        // embedded '\n' characters, there will
-                        // one header line followed by multiple text lines.
-                        // Use the last header that we saw.
-                        mc.data = mLastMessageInfo;
-    
-                        // tabs seem to display as only 1 tab so we replace the leading tabs
-                        // by 4 spaces.
-                        mc.msg = line.replaceAll("\t", "    "); //$NON-NLS-1$ //$NON-NLS-2$
-                        
-                        // process the new LogMessage.
-                        processNewMessage(mc);
-                        
-                        // store the new LogMessage
-                        newMessages.add(mc);
-                    }
-                }
-            }
-            
-            // if we don't have a pending Runnable that will do the refresh, we ask the Display
-            // to run one in the UI thread.
-            if (mPendingAsyncRefresh == false) {
-                mPendingAsyncRefresh = true;
-                
-                try {
-                    Display display = mFolders.getDisplay();
-                    
-                    // run in sync because this will update the buffer start/end indices
-                    display.asyncExec(new Runnable() {
-                        public void run() {
-                            asyncRefresh();
-                        }
-                    });
-                } catch (SWTException e) {
-                    // display is disposed, we're probably quitting. Let's stop.
-                    stopLogCat(false);
-                }
-            }
-        }
-    }
-
-    /**
-     * Refreshes the UI with new messages.
-     */
-    private void asyncRefresh() {
-        if (mFolders.isDisposed() == false) {
-            synchronized (mBuffer) {
-                try {
-                    // the circular buffer has been updated, let have the filter flush their
-                    // display with the new messages.
-                    if (mFilters != null) {
-                        for (LogFilter f : mFilters) {
-                            f.flush();
-                        }
-                    }
-    
-                    if (mDefaultFilter != null) {
-                        mDefaultFilter.flush();
-                    }
-                } finally {
-                    // the pending refresh is done.
-                    mPendingAsyncRefresh = false;
-                }
-            }
-        } else {
-            stopLogCat(true);
-        }
-    }
-
-    /**
-     * Processes a new Message.
-     * <p/>This adds the new message to the buffer, and gives it to the existing filters.
-     * @param newMessage
-     */
-    private void processNewMessage(LogMessage newMessage) {
-        // if we are in auto filtering mode, make sure we have
-        // a filter for this
-        if (mFilterMode == FILTER_AUTO_PID ||
-                mFilterMode == FILTER_AUTO_TAG) {
-           checkFilter(newMessage.data);
-        }
-
-        // compute the index where the message goes.
-        // was the buffer empty?
-        int messageIndex = -1;
-        if (mBufferStart == -1) {
-            messageIndex = mBufferStart = 0;
-            mBufferEnd = 1;
-        } else {
-            messageIndex = mBufferEnd;
-
-            // check we aren't overwriting start
-            if (mBufferEnd == mBufferStart) {
-                mBufferStart = (mBufferStart + 1) % STRING_BUFFER_LENGTH;
-            }
-
-            // increment the next usable slot index
-            mBufferEnd = (mBufferEnd + 1) % STRING_BUFFER_LENGTH;
-        }
-        
-        LogMessage oldMessage = null;
-
-        // record the message that was there before
-        if (mBuffer[messageIndex] != null) {
-            oldMessage = mBuffer[messageIndex];
-        }
-
-        // then add the new one
-        mBuffer[messageIndex] = newMessage;
-
-        // give the new message to every filters.
-        boolean filtered = false;
-        if (mFilters != null) {
-            for (LogFilter f : mFilters) {
-                filtered |= f.addMessage(newMessage, oldMessage);
-            }
-        }
-        if (filtered == false && mDefaultFilter != null) {
-            mDefaultFilter.addMessage(newMessage, oldMessage);
-        }
-    }
-
-    private void createFilters() {
-        if (mFilterMode == FILTER_DEBUG || mFilterMode == FILTER_MANUAL) {
-            // unarchive the filters.
-            mFilters = mFilterStorage.getFilterFromStore();
-
-            // set the colors
-            if (mFilters != null) {
-                for (LogFilter f : mFilters) {
-                    f.setColors(mColors);
-                }
-            }
-
-            if (mFilterStorage.requiresDefaultFilter()) {
-                mDefaultFilter = new LogFilter("Log");
-                mDefaultFilter.setColors(mColors);
-                mDefaultFilter.setSupportsDelete(false);
-                mDefaultFilter.setSupportsEdit(false);
-            }
-        } else if (mFilterMode == FILTER_NONE) {
-            // if the filtering mode is "none", we create a single filter that
-            // will receive all
-            mDefaultFilter = new LogFilter("Log");
-            mDefaultFilter.setColors(mColors);
-            mDefaultFilter.setSupportsDelete(false);
-            mDefaultFilter.setSupportsEdit(false);
-        }
-    }
-
-    /** Checks if there's an automatic filter for this md and if not
-     * adds the filter and the ui.
-     * This must be called from the UI!
-     * @param md
-     * @return true if the filter existed already
-     */
-    private boolean checkFilter(final LogMessageInfo md) {
-        if (true)
-            return true;
-        // look for a filter that matches the pid
-        if (mFilterMode == FILTER_AUTO_PID) {
-            for (LogFilter f : mFilters) {
-                if (f.getPidFilter() == md.pid) {
-                    return true;
-                }
-            }
-        } else if (mFilterMode == FILTER_AUTO_TAG) {
-            for (LogFilter f : mFilters) {
-                if (f.getTagFilter().equals(md.tag)) {
-                    return true;
-                }
-            }
-        }
-
-        // if we reach this point, no filter was found.
-        // create a filter with a temporary name of the pid
-        final LogFilter newFilter = new LogFilter(md.pidString);
-        String name = null;
-        if (mFilterMode == FILTER_AUTO_PID) {
-            newFilter.setPidMode(md.pid);
-
-            // ask the monitor thread if it knows the pid.
-            name = mCurrentLoggedDevice.getClientName(md.pid);
-        } else {
-            newFilter.setTagMode(md.tag);
-            name = md.tag;
-        }
-        addFilterToArray(newFilter);
-
-        final String fname = name;
-
-        // create the tabitem
-        final TabItem newTabItem = createTab(newFilter, -1, true);
-
-        // if the name is unknown
-        if (fname == null) {
-            // we need to find the process running under that pid.
-            // launch a thread do a ps on the device
-            new Thread("remote PS") { //$NON-NLS-1$
-                @Override
-                public void run() {
-                    // create the receiver
-                    PsOutputReceiver psor = new PsOutputReceiver(md.pid,
-                            newFilter, newTabItem);
-
-                    // execute ps
-                    try {
-                        mCurrentLoggedDevice.executeShellCommand("ps", psor); //$NON-NLS-1$
-                    } catch (IOException e) {
-                        // hmm...
-                    }
-                }
-            }.start();
-        }
-
-        return false;
-    }
-
-    /**
-     * Adds a new filter to the current filter array, and set its colors
-     * @param newFilter The filter to add
-     */
-    private void addFilterToArray(LogFilter newFilter) {
-        // set the colors
-        newFilter.setColors(mColors);
-
-        // add it to the array.
-        if (mFilters != null && mFilters.length > 0) {
-            LogFilter[] newFilters = new LogFilter[mFilters.length+1];
-            System.arraycopy(mFilters, 0, newFilters, 0, mFilters.length);
-            newFilters[mFilters.length] = newFilter;
-            mFilters = newFilters;
-        } else {
-            mFilters = new LogFilter[1];
-            mFilters[0] = newFilter;
-        }
-    }
-
-    private void removeFilterFromArray(LogFilter oldFilter) {
-        // look for the index
-        int index = -1;
-        for (int i = 0 ; i < mFilters.length ; i++) {
-            if (mFilters[i] == oldFilter) {
-                index = i;
-                break;
-            }
-        }
-
-        if (index != -1) {
-            LogFilter[] newFilters = new LogFilter[mFilters.length-1];
-            System.arraycopy(mFilters, 0, newFilters, 0, index);
-            System.arraycopy(mFilters, index + 1, newFilters, index,
-                    newFilters.length-index);
-            mFilters = newFilters;
-        }
-    }
-
-    /**
-     * Initialize the filter with already existing buffer.
-     * @param filter
-     */
-    private void initFilter(LogFilter filter) {
-        // is it empty
-        if (filter.uiReady() == false) {
-            return;
-        }
-
-        if (filter == mDefaultFilter) {
-            initDefaultFilter();
-            return;
-        }
-        
-        filter.clear();
-
-        if (mBufferStart != -1) {
-            int max = mBufferEnd;
-            if (mBufferEnd < mBufferStart) {
-                max += STRING_BUFFER_LENGTH;
-            }
-
-            for (int i = mBufferStart; i < max; i++) {
-                int realItemIndex = i % STRING_BUFFER_LENGTH;
-
-                filter.addMessage(mBuffer[realItemIndex], null /* old message */);
-            }
-        }
-
-        filter.flush();
-        filter.resetTempFilteringStatus();
-    }
-
-    /**
-     * Refill the default filter. Not to be called directly.
-     * @see initFilter()
-     */
-    private void initDefaultFilter() {
-        mDefaultFilter.clear();
-
-        if (mBufferStart != -1) {
-            int max = mBufferEnd;
-            if (mBufferEnd < mBufferStart) {
-                max += STRING_BUFFER_LENGTH;
-            }
-
-            for (int i = mBufferStart; i < max; i++) {
-                int realItemIndex = i % STRING_BUFFER_LENGTH;
-                LogMessage msg = mBuffer[realItemIndex];
-
-                // first we check that the other filters don't take this message
-                boolean filtered = false;
-                for (LogFilter f : mFilters) {
-                    filtered |= f.accept(msg);
-                }
-
-                if (filtered == false) {
-                    mDefaultFilter.addMessage(msg, null /* old message */);
-                }
-            }
-        }
-
-        mDefaultFilter.flush();
-        mDefaultFilter.resetTempFilteringStatus();
-    }
-
-    /**
-     * Reset the filters, to handle change in device in automatic filter mode
-     */
-    private void resetFilters() {
-        // if we are in automatic mode, then we need to rmove the current
-        // filter.
-        if (mFilterMode == FILTER_AUTO_PID || mFilterMode == FILTER_AUTO_TAG) {
-            mFilters = null;
-
-            // recreate the filters.
-            createFilters();
-        }
-    }
-
-
-    private LogFilter getCurrentFilter() {
-        int index = mFolders.getSelectionIndex();
-
-        // if mFilters is null or index is invalid, we return the default
-        // filter. It doesn't matter if that one is null as well, since we
-        // would return null anyway.
-        if (index == 0 || mFilters == null) {
-            return mDefaultFilter;
-        }
-
-        return mFilters[index-1];
-    }
-
-
-    private void emptyTables() {
-        for (LogFilter f : mFilters) {
-            f.getTable().removeAll();
-        }
-
-        if (mDefaultFilter != null) {
-            mDefaultFilter.getTable().removeAll();
-        }
-    }
-
-    protected void updateFilteringWith(String text) {
-        synchronized (mBuffer) {
-            // reset the temp filtering for all the filters
-            for (LogFilter f : mFilters) {
-                f.resetTempFiltering();
-            }
-            if (mDefaultFilter != null) {
-                mDefaultFilter.resetTempFiltering();
-            }
-    
-            // now we need to figure out the new temp filtering
-            // split each word
-            String[] segments = text.split(" "); //$NON-NLS-1$
-    
-            ArrayList<String> keywords = new ArrayList<String>(segments.length);
-    
-            // loop and look for temp id/tag
-            int tempPid = -1;
-            String tempTag = null;
-            for (int i = 0 ; i < segments.length; i++) {
-                String s = segments[i];
-                if (tempPid == -1 && s.startsWith("pid:")) { //$NON-NLS-1$
-                    // get the pid
-                    String[] seg = s.split(":"); //$NON-NLS-1$
-                    if (seg.length == 2) {
-                        if (seg[1].matches("^[0-9]*$")) { //$NON-NLS-1$
-                            tempPid = Integer.valueOf(seg[1]);
-                        }
-                    }
-                } else if (tempTag == null && s.startsWith("tag:")) { //$NON-NLS-1$
-                    String seg[] = segments[i].split(":"); //$NON-NLS-1$
-                    if (seg.length == 2) {
-                        tempTag = seg[1];
-                    }
-                } else {
-                    keywords.add(s);
-                }
-            }
-    
-            // set the temp filtering in the filters
-            if (tempPid != -1 || tempTag != null || keywords.size() > 0) {
-                String[] keywordsArray = keywords.toArray(
-                        new String[keywords.size()]);
-    
-                for (LogFilter f : mFilters) {
-                    if (tempPid != -1) {
-                        f.setTempPidFiltering(tempPid);
-                    }
-                    if (tempTag != null) {
-                        f.setTempTagFiltering(tempTag);
-                    }
-                    f.setTempKeywordFiltering(keywordsArray);
-                }
-    
-                if (mDefaultFilter != null) {
-                    if (tempPid != -1) {
-                        mDefaultFilter.setTempPidFiltering(tempPid);
-                    }
-                    if (tempTag != null) {
-                        mDefaultFilter.setTempTagFiltering(tempTag);
-                    }
-                    mDefaultFilter.setTempKeywordFiltering(keywordsArray);
-    
-                }
-            }
-    
-            initFilter(mCurrentFilter);
-        }
-    }
-
-    /**
-     * Called when the current filter selection changes.
-     * @param selectedFilter
-     */
-    private void selectionChanged(LogFilter selectedFilter) {
-        if (mLogLevelActions != null) {
-            // get the log level
-            int level = selectedFilter.getLogLevel();
-            for (int i = 0 ; i < mLogLevelActions.length; i++) {
-                ICommonAction a = mLogLevelActions[i];
-                if (i == level - 2) {
-                    a.setChecked(true);
-                } else {
-                    a.setChecked(false);
-                }
-            }
-        }
-
-        if (mDeleteFilterAction != null) {
-            mDeleteFilterAction.setEnabled(selectedFilter.supportsDelete());
-        }
-        if (mEditFilterAction != null) {
-            mEditFilterAction.setEnabled(selectedFilter.supportsEdit());
-        }
-    }
-}
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/add.png b/tools/ddms/libs/ddmuilib/src/resources/images/add.png
deleted file mode 100644
index eefc2ca..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/add.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/android.png b/tools/ddms/libs/ddmuilib/src/resources/images/android.png
deleted file mode 100644
index 3779d4d..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/android.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/backward.png b/tools/ddms/libs/ddmuilib/src/resources/images/backward.png
deleted file mode 100644
index 90a9713..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/backward.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/clear.png b/tools/ddms/libs/ddmuilib/src/resources/images/clear.png
deleted file mode 100644
index 0009cf6..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/clear.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/d.png b/tools/ddms/libs/ddmuilib/src/resources/images/d.png
deleted file mode 100644
index d45506e..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/d.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/debug-attach.png b/tools/ddms/libs/ddmuilib/src/resources/images/debug-attach.png
deleted file mode 100644
index 9b8a11c..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/debug-attach.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/debug-error.png b/tools/ddms/libs/ddmuilib/src/resources/images/debug-error.png
deleted file mode 100644
index f22da1f..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/debug-error.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/debug-wait.png b/tools/ddms/libs/ddmuilib/src/resources/images/debug-wait.png
deleted file mode 100644
index 322be63..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/debug-wait.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/delete.png b/tools/ddms/libs/ddmuilib/src/resources/images/delete.png
deleted file mode 100644
index db5fab8..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/delete.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/device.png b/tools/ddms/libs/ddmuilib/src/resources/images/device.png
deleted file mode 100644
index 7dbbbb6..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/device.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/down.png b/tools/ddms/libs/ddmuilib/src/resources/images/down.png
deleted file mode 100644
index f9426cb..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/down.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/e.png b/tools/ddms/libs/ddmuilib/src/resources/images/e.png
deleted file mode 100644
index dee7c97..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/e.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/edit.png b/tools/ddms/libs/ddmuilib/src/resources/images/edit.png
deleted file mode 100644
index b8f65bc..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/edit.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/empty.png b/tools/ddms/libs/ddmuilib/src/resources/images/empty.png
deleted file mode 100644
index f021542..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/empty.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/emulator.png b/tools/ddms/libs/ddmuilib/src/resources/images/emulator.png
deleted file mode 100644
index a718042..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/emulator.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/file.png b/tools/ddms/libs/ddmuilib/src/resources/images/file.png
deleted file mode 100644
index 043a814..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/file.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/folder.png b/tools/ddms/libs/ddmuilib/src/resources/images/folder.png
deleted file mode 100644
index 7e29b1a..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/folder.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/forward.png b/tools/ddms/libs/ddmuilib/src/resources/images/forward.png
deleted file mode 100644
index a97a605..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/forward.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/gc.png b/tools/ddms/libs/ddmuilib/src/resources/images/gc.png
deleted file mode 100644
index 5194806..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/gc.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/halt.png b/tools/ddms/libs/ddmuilib/src/resources/images/halt.png
deleted file mode 100644
index 10e3720..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/halt.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/heap.png b/tools/ddms/libs/ddmuilib/src/resources/images/heap.png
deleted file mode 100644
index e3aa3f0..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/heap.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/i.png b/tools/ddms/libs/ddmuilib/src/resources/images/i.png
deleted file mode 100644
index 98385c5..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/i.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/importBug.png b/tools/ddms/libs/ddmuilib/src/resources/images/importBug.png
deleted file mode 100644
index f5da179..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/importBug.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/load.png b/tools/ddms/libs/ddmuilib/src/resources/images/load.png
deleted file mode 100644
index 9e7bf6e..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/load.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/pause.png b/tools/ddms/libs/ddmuilib/src/resources/images/pause.png
deleted file mode 100644
index 19d286d..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/pause.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/play.png b/tools/ddms/libs/ddmuilib/src/resources/images/play.png
deleted file mode 100644
index d54f013..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/play.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/pull.png b/tools/ddms/libs/ddmuilib/src/resources/images/pull.png
deleted file mode 100644
index f48f1b1..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/pull.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/push.png b/tools/ddms/libs/ddmuilib/src/resources/images/push.png
deleted file mode 100644
index 6222864..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/push.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/save.png b/tools/ddms/libs/ddmuilib/src/resources/images/save.png
deleted file mode 100644
index 040ebda..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/save.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/thread.png b/tools/ddms/libs/ddmuilib/src/resources/images/thread.png
deleted file mode 100644
index ac839e8..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/thread.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/up.png b/tools/ddms/libs/ddmuilib/src/resources/images/up.png
deleted file mode 100644
index 92edf5a..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/up.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/v.png b/tools/ddms/libs/ddmuilib/src/resources/images/v.png
deleted file mode 100644
index 8044051..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/v.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/w.png b/tools/ddms/libs/ddmuilib/src/resources/images/w.png
deleted file mode 100644
index 129d0f9..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/w.png
+++ /dev/null
Binary files differ
diff --git a/tools/ddms/libs/ddmuilib/src/resources/images/warning.png b/tools/ddms/libs/ddmuilib/src/resources/images/warning.png
deleted file mode 100644
index ca3b6ed..0000000
--- a/tools/ddms/libs/ddmuilib/src/resources/images/warning.png
+++ /dev/null
Binary files differ
diff --git a/tools/draw9patch/Android.mk b/tools/draw9patch/Android.mk
deleted file mode 100644
index 934495d..0000000
--- a/tools/draw9patch/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-DRAW9PATCH_LOCAL_DIR := $(call my-dir)
-include $(DRAW9PATCH_LOCAL_DIR)/etc/Android.mk
-include $(DRAW9PATCH_LOCAL_DIR)/src/Android.mk
diff --git a/tools/draw9patch/MODULE_LICENSE_APACHE2 b/tools/draw9patch/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/tools/draw9patch/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/tools/draw9patch/etc/Android.mk b/tools/draw9patch/etc/Android.mk
deleted file mode 100644
index 8d7d080..0000000
--- a/tools/draw9patch/etc/Android.mk
+++ /dev/null
@@ -1,20 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := draw9patch
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/draw9patch/etc/draw9patch b/tools/draw9patch/etc/draw9patch
deleted file mode 100755
index 5d272a6..0000000
--- a/tools/draw9patch/etc/draw9patch
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/bin/sh
-# Copyright 2008, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=draw9patch.jar
-frameworkdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Djava.ext.dirs="$frameworkdir" -jar "$jarpath" "$@"
diff --git a/tools/draw9patch/etc/draw9patch.bat b/tools/draw9patch/etc/draw9patch.bat
deleted file mode 100755
index 1d56d85..0000000
--- a/tools/draw9patch/etc/draw9patch.bat
+++ /dev/null
@@ -1,41 +0,0 @@
-@echo off
-rem Copyright (C) 2008 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Change current directory to where ddms is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=draw9patch.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-
-:JarFileOk
-
-set jarpath=%frameworkdir%%jarfile%
-
-call java -Djava.ext.dirs=%frameworkdir% -jar %jarpath% %*
diff --git a/tools/draw9patch/etc/manifest.txt b/tools/draw9patch/etc/manifest.txt
deleted file mode 100644
index b2e3528..0000000
--- a/tools/draw9patch/etc/manifest.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-Main-Class: com.android.draw9patch.Application
-Class-Path: swing-worker-1.1.jar
diff --git a/tools/draw9patch/src/Android.mk b/tools/draw9patch/src/Android.mk
deleted file mode 100644
index 3dc9db4..0000000
--- a/tools/draw9patch/src/Android.mk
+++ /dev/null
@@ -1,26 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	swing-worker-1.1
-LOCAL_MODULE := draw9patch
-
-include $(BUILD_HOST_JAVA_LIBRARY)
diff --git a/tools/draw9patch/src/com/android/draw9patch/Application.java b/tools/draw9patch/src/com/android/draw9patch/Application.java
deleted file mode 100644
index c7c6aaf..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/Application.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch;
-
-import com.android.draw9patch.ui.MainFrame;
-
-import javax.swing.SwingUtilities;
-import javax.swing.UIManager;
-import javax.swing.UnsupportedLookAndFeelException;
-
-public class Application {
-    private static void initUserInterface() {
-        System.setProperty("apple.laf.useScreenMenuBar", "true");
-        System.setProperty("com.apple.mrj.application.apple.menu.about.name", "Draw 9-patch");
-
-        try {
-            UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
-        } catch (ClassNotFoundException e) {
-            e.printStackTrace();
-        } catch (InstantiationException e) {
-            e.printStackTrace();
-        } catch (IllegalAccessException e) {
-            e.printStackTrace();
-        } catch (UnsupportedLookAndFeelException e) {
-            e.printStackTrace();
-        }
-    }
-
-    public static void main(String... args) {
-        initUserInterface();
-        SwingUtilities.invokeLater(new Runnable() {
-            public void run() {
-                MainFrame frame = new MainFrame();
-                frame.setDefaultCloseOperation(MainFrame.EXIT_ON_CLOSE);
-                frame.setLocationRelativeTo(null);
-                frame.setVisible(true);
-            }
-        });
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/graphics/GraphicsUtilities.java b/tools/draw9patch/src/com/android/draw9patch/graphics/GraphicsUtilities.java
deleted file mode 100644
index c6c182c..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/graphics/GraphicsUtilities.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.graphics;
-
-import javax.imageio.ImageIO;
-import java.awt.image.BufferedImage;
-import java.awt.image.Raster;
-import java.awt.GraphicsConfiguration;
-import java.awt.GraphicsEnvironment;
-import java.awt.Graphics;
-import java.awt.Transparency;
-import java.net.URL;
-import java.io.IOException;
-
-public class GraphicsUtilities {
-    public static BufferedImage loadCompatibleImage(URL resource) throws IOException {
-        BufferedImage image = ImageIO.read(resource);
-        return toCompatibleImage(image);
-    }
-
-    public static BufferedImage createCompatibleImage(int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height);
-    }
-
-    public static BufferedImage toCompatibleImage(BufferedImage image) {
-        if (isHeadless()) {
-            return image;
-        }
-
-        if (image.getColorModel().equals(getGraphicsConfiguration().getColorModel())) {
-            return image;
-        }
-
-        BufferedImage compatibleImage = getGraphicsConfiguration().createCompatibleImage(
-                    image.getWidth(), image.getHeight(), image.getTransparency());
-        Graphics g = compatibleImage.getGraphics();
-        g.drawImage(image, 0, 0, null);
-        g.dispose();
-
-        return compatibleImage;
-    }
-
-    public static BufferedImage createCompatibleImage(BufferedImage image, int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height,
-                                                   image.getTransparency());
-    }
-
-    private static GraphicsConfiguration getGraphicsConfiguration() {
-        GraphicsEnvironment environment = GraphicsEnvironment.getLocalGraphicsEnvironment();
-        return environment.getDefaultScreenDevice().getDefaultConfiguration();
-    }
-
-    private static boolean isHeadless() {
-        return GraphicsEnvironment.isHeadless();
-    }
-
-    public static BufferedImage createTranslucentCompatibleImage(int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height,
-                Transparency.TRANSLUCENT);
-    }
-
-    public static int[] getPixels(BufferedImage img, int x, int y, int w, int h, int[] pixels) {
-        if (w == 0 || h == 0) {
-            return new int[0];
-        }
-
-        if (pixels == null) {
-            pixels = new int[w * h];
-        } else if (pixels.length < w * h) {
-            throw new IllegalArgumentException("Pixels array must have a length >= w * h");
-        }
-
-        int imageType = img.getType();
-        if (imageType == BufferedImage.TYPE_INT_ARGB || imageType == BufferedImage.TYPE_INT_RGB) {
-            Raster raster = img.getRaster();
-            return (int[]) raster.getDataElements(x, y, w, h, pixels);
-        }
-
-        // Unmanages the image
-        return img.getRGB(x, y, w, h, pixels, 0, w);
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/GradientPanel.java b/tools/draw9patch/src/com/android/draw9patch/ui/GradientPanel.java
deleted file mode 100644
index bc1465f..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/GradientPanel.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui;
-
-import java.awt.Graphics;
-import java.awt.Graphics2D;
-import java.awt.Paint;
-import java.awt.GradientPaint;
-import java.awt.Color;
-import java.awt.Rectangle;
-import java.awt.BorderLayout;
-import javax.swing.JPanel;
-
-class GradientPanel extends JPanel {
-    private static final int DARK_BLUE = 0x202737;
-
-    GradientPanel() {
-        super(new BorderLayout());
-    }
-
-    @Override
-    protected void paintComponent(Graphics g) {
-        Graphics2D g2 = (Graphics2D) g;
-        Rectangle clip = g2.getClipBounds();
-        Paint paint = g2.getPaint();
-
-        g2.setPaint(new GradientPaint(0.0f, getHeight() * 0.22f, new Color(DARK_BLUE),
-                                      0.0f, getHeight() * 0.9f, Color.BLACK));
-        g2.fillRect(clip.x, clip.y, clip.width, clip.height);
-
-        g2.setPaint(paint);
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/ImageEditorPanel.java b/tools/draw9patch/src/com/android/draw9patch/ui/ImageEditorPanel.java
deleted file mode 100644
index 86c801f..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/ImageEditorPanel.java
+++ /dev/null
@@ -1,1129 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui;
-
-import com.android.draw9patch.graphics.GraphicsUtilities;
-
-import javax.swing.JPanel;
-import javax.swing.JLabel;
-import javax.swing.BorderFactory;
-import javax.swing.JSlider;
-import javax.swing.JComponent;
-import javax.swing.JScrollPane;
-import javax.swing.JCheckBox;
-import javax.swing.Box;
-import javax.swing.JFileChooser;
-import javax.swing.JSplitPane;
-import javax.swing.JButton;
-import javax.swing.border.EmptyBorder;
-import javax.swing.event.ChangeListener;
-import javax.swing.event.ChangeEvent;
-import java.awt.image.BufferedImage;
-import java.awt.image.RenderedImage;
-import java.awt.Graphics2D;
-import java.awt.BorderLayout;
-import java.awt.Color;
-import java.awt.Graphics;
-import java.awt.Dimension;
-import java.awt.TexturePaint;
-import java.awt.Shape;
-import java.awt.BasicStroke;
-import java.awt.RenderingHints;
-import java.awt.Rectangle;
-import java.awt.GridBagLayout;
-import java.awt.GridBagConstraints;
-import java.awt.Insets;
-import java.awt.Toolkit;
-import java.awt.AWTEvent;
-import java.awt.event.MouseMotionAdapter;
-import java.awt.event.MouseEvent;
-import java.awt.event.MouseAdapter;
-import java.awt.event.ActionListener;
-import java.awt.event.ActionEvent;
-import java.awt.event.KeyEvent;
-import java.awt.event.AWTEventListener;
-import java.awt.geom.Rectangle2D;
-import java.awt.geom.Line2D;
-import java.awt.geom.Area;
-import java.awt.geom.RoundRectangle2D;
-import java.io.IOException;
-import java.io.File;
-import java.net.URL;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Arrays;
-
-class ImageEditorPanel extends JPanel {
-    private static final String EXTENSION_9PATCH = ".9.png";
-    private static final int DEFAULT_ZOOM = 8;
-    private static final float DEFAULT_SCALE = 2.0f;
-
-    private String name;
-    private BufferedImage image;
-    private boolean is9Patch;
-
-    private ImageViewer viewer;
-    private StretchesViewer stretchesViewer;
-    private JLabel xLabel;
-    private JLabel yLabel;
-
-    private TexturePaint texture;    
-
-    private List<Rectangle> patches;
-    private List<Rectangle> horizontalPatches;
-    private List<Rectangle> verticalPatches;
-    private List<Rectangle> fixed;
-    private boolean verticalStartWithPatch;
-    private boolean horizontalStartWithPatch;
-
-    private Pair<Integer> horizontalPadding;
-    private Pair<Integer> verticalPadding;    
-
-    ImageEditorPanel(MainFrame mainFrame, BufferedImage image, String name) {
-        this.image = image;
-        this.name = name;
-
-        setTransferHandler(new ImageTransferHandler(mainFrame));
-
-        checkImage();
-
-        setOpaque(false);
-        setLayout(new BorderLayout());
-
-        loadSupport();
-        buildImageViewer();
-        buildStatusPanel();
-    }
-
-    private void loadSupport() {
-        try {
-            URL resource = getClass().getResource("/images/checker.png");
-            BufferedImage checker = GraphicsUtilities.loadCompatibleImage(resource);
-            texture = new TexturePaint(checker, new Rectangle2D.Double(0, 0,
-                    checker.getWidth(), checker.getHeight()));
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-
-    private void buildImageViewer() {
-        viewer = new ImageViewer();
-
-        JSplitPane splitter = new JSplitPane();
-        splitter.setContinuousLayout(true);
-        splitter.setResizeWeight(0.8);
-        splitter.setBorder(null);
-
-        JScrollPane scroller = new JScrollPane(viewer);
-        scroller.setOpaque(false);
-        scroller.setBorder(null);
-        scroller.getViewport().setBorder(null);
-        scroller.getViewport().setOpaque(false);
-
-        splitter.setLeftComponent(scroller);
-        splitter.setRightComponent(buildStretchesViewer());
-
-        add(splitter);
-    }
-
-    private JComponent buildStretchesViewer() {
-        stretchesViewer = new StretchesViewer();
-        JScrollPane scroller = new JScrollPane(stretchesViewer);
-        scroller.setBorder(null);
-        scroller.getViewport().setBorder(null);
-        scroller.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
-        scroller.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
-        return scroller;
-    }
-
-    private void buildStatusPanel() {
-        JPanel status = new JPanel(new GridBagLayout());
-        status.setOpaque(false);
-
-        JLabel label = new JLabel();
-        label.setForeground(Color.WHITE);
-        label.setText("Zoom: ");
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(0, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 6, 0, 0), 0, 0));
-
-        label = new JLabel();
-        label.setForeground(Color.WHITE);
-        label.setText("100%");
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(1, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        JSlider zoomSlider = new JSlider(1, 16, DEFAULT_ZOOM);
-        zoomSlider.setSnapToTicks(true);
-        zoomSlider.putClientProperty("JComponent.sizeVariant", "small");
-        zoomSlider.addChangeListener(new ChangeListener() {
-            public void stateChanged(ChangeEvent evt) {
-                viewer.setZoom(((JSlider) evt.getSource()).getValue());
-            }
-        });
-        status.add(zoomSlider, new GridBagConstraints(2, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        JLabel maxZoomLabel = new JLabel();
-        maxZoomLabel.setForeground(Color.WHITE);
-        maxZoomLabel.putClientProperty("JComponent.sizeVariant", "small");
-        maxZoomLabel.setText("800%");
-        status.add(maxZoomLabel, new GridBagConstraints(3, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        label = new JLabel();
-        label.setForeground(Color.WHITE);
-        label.setText("Patch scale: ");
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(0, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 6, 0, 0), 0, 0));
-
-        label = new JLabel();
-        label.setForeground(Color.WHITE);
-        label.setText("2x");
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(1, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        zoomSlider = new JSlider(200, 600, (int) (DEFAULT_SCALE * 100.0f));
-        zoomSlider.setSnapToTicks(true);
-        zoomSlider.putClientProperty("JComponent.sizeVariant", "small");
-        zoomSlider.addChangeListener(new ChangeListener() {
-            public void stateChanged(ChangeEvent evt) {
-                stretchesViewer.setScale(((JSlider) evt.getSource()).getValue() / 100.0f);
-            }
-        });
-        status.add(zoomSlider, new GridBagConstraints(2, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        maxZoomLabel = new JLabel();
-        maxZoomLabel.setForeground(Color.WHITE);
-        maxZoomLabel.putClientProperty("JComponent.sizeVariant", "small");
-        maxZoomLabel.setText("6x");
-        status.add(maxZoomLabel, new GridBagConstraints(3, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        JCheckBox showLock = new JCheckBox("Show lock");
-        showLock.setOpaque(false);
-        showLock.setForeground(Color.WHITE);
-        showLock.setSelected(true);
-        showLock.putClientProperty("JComponent.sizeVariant", "small");
-        showLock.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent event) {
-                viewer.setLockVisible(((JCheckBox) event.getSource()).isSelected());
-            }
-        });
-        status.add(showLock, new GridBagConstraints(4, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 12, 0, 0), 0, 0));
-
-        JCheckBox showPatches = new JCheckBox("Show patches");
-        showPatches.setOpaque(false);
-        showPatches.setForeground(Color.WHITE);
-        showPatches.putClientProperty("JComponent.sizeVariant", "small");
-        showPatches.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent event) {
-                viewer.setPatchesVisible(((JCheckBox) event.getSource()).isSelected());
-            }
-        });
-        status.add(showPatches, new GridBagConstraints(4, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 12, 0, 0), 0, 0));
-
-        JCheckBox showPadding = new JCheckBox("Show content");
-        showPadding.setOpaque(false);
-        showPadding.setForeground(Color.WHITE);
-        showPadding.putClientProperty("JComponent.sizeVariant", "small");
-        showPadding.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent event) {
-                stretchesViewer.setPaddingVisible(((JCheckBox) event.getSource()).isSelected());
-            }
-        });
-        status.add(showPadding, new GridBagConstraints(5, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                new Insets(0, 12, 0, 0), 0, 0));
-
-        status.add(Box.createHorizontalGlue(), new GridBagConstraints(6, 0, 1, 1, 1.0f, 1.0f,
-                GridBagConstraints.LINE_START, GridBagConstraints.BOTH,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        label = new JLabel("X: ");
-        label.setForeground(Color.WHITE);
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(7, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        xLabel = new JLabel("0px");
-        xLabel.setForeground(Color.WHITE);
-        xLabel.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(xLabel, new GridBagConstraints(8, 0, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 6), 0, 0));
-
-        label = new JLabel("Y: ");
-        label.setForeground(Color.WHITE);
-        label.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(label, new GridBagConstraints(7, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 0), 0, 0));
-
-        yLabel = new JLabel("0px");
-        yLabel.setForeground(Color.WHITE);
-        yLabel.putClientProperty("JComponent.sizeVariant", "small");
-        status.add(yLabel, new GridBagConstraints(8, 1, 1, 1, 0.0f, 0.0f,
-                GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                new Insets(0, 0, 0, 6), 0, 0));
-
-        add(status, BorderLayout.SOUTH);
-    }
-
-    private void checkImage() {
-        is9Patch = name.endsWith(EXTENSION_9PATCH);
-        if (!is9Patch) {
-            convertTo9Patch();
-        } else {
-            ensure9Patch();
-        }
-    }
-
-    private void ensure9Patch() {
-        int width = image.getWidth();
-        int height = image.getHeight();
-        for (int i = 0; i < width; i++) {
-            int pixel = image.getRGB(i, 0);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(i, 0, 0);
-            }
-            pixel = image.getRGB(i, height - 1);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(i, height - 1, 0);
-            }
-        }
-        for (int i = 0; i < height; i++) {
-            int pixel = image.getRGB(0, i);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(0, i, 0);
-            }
-            pixel = image.getRGB(width - 1, i);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(width - 1, i, 0);
-            }
-        }
-    }
-
-    private void convertTo9Patch() {
-        BufferedImage buffer = GraphicsUtilities.createTranslucentCompatibleImage(
-                image.getWidth() + 2, image.getHeight() + 2);
-
-        Graphics2D g2 = buffer.createGraphics();
-        g2.drawImage(image, 1, 1, null);
-        g2.dispose();
-
-        image = buffer;
-        name = name.substring(0, name.lastIndexOf('.')) + ".9.png";
-    }
-
-    File chooseSaveFile() {
-        if (is9Patch) {
-            return new File(name);
-        } else {
-            JFileChooser chooser = new JFileChooser();
-            chooser.setFileFilter(new PngFileFilter());
-            int choice = chooser.showSaveDialog(this);
-            if (choice == JFileChooser.APPROVE_OPTION) {
-                File file = chooser.getSelectedFile();
-                if (!file.getAbsolutePath().endsWith(EXTENSION_9PATCH)) {
-                    String path = file.getAbsolutePath();
-                    if (path.endsWith(".png")) {
-                        path = path.substring(0, path.lastIndexOf(".png")) + EXTENSION_9PATCH;
-                    } else {
-                        path = path + EXTENSION_9PATCH;
-                    }
-                    name = path;
-                    is9Patch = true;
-                    return new File(path);
-                }
-                is9Patch = true;
-                return file;
-            }
-        }
-        return null;
-    }
-
-    RenderedImage getImage() {
-        return image;
-    }
-
-    private class StretchesViewer extends JPanel {
-        private static final int MARGIN = 24;
-
-        private StretchView horizontal;
-        private StretchView vertical;
-        private StretchView both;
-
-        private Dimension size;
-
-        private float horizontalPatchesSum;
-        private float verticalPatchesSum;
-
-        private boolean showPadding;
-
-        StretchesViewer() {
-            setOpaque(false);
-            setLayout(new GridBagLayout());
-            setBorder(BorderFactory.createEmptyBorder(MARGIN, MARGIN, MARGIN, MARGIN));
-
-            horizontal = new StretchView();
-            vertical = new StretchView();
-            both = new StretchView();
-
-            setScale(DEFAULT_SCALE);
-            
-            add(vertical, new GridBagConstraints(0, 0, 1, 1, 1.0, 1.0, GridBagConstraints.CENTER,
-                    GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
-            add(horizontal, new GridBagConstraints(0, 1, 1, 1, 1.0, 1.0, GridBagConstraints.CENTER,
-                    GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
-            add(both, new GridBagConstraints(0, 2, 1, 1, 1.0, 1.0, GridBagConstraints.CENTER,
-                    GridBagConstraints.BOTH, new Insets(0, 0, 0, 0), 0, 0));
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            Graphics2D g2 = (Graphics2D) g.create();
-            g2.setPaint(texture);
-            g2.fillRect(0, 0, getWidth(), getHeight());
-            g2.dispose();
-        }
-
-        void setScale(float scale) {
-            int patchWidth = image.getWidth() - 2;
-            int patchHeight = image.getHeight() - 2;
-
-            int scaledWidth = (int) (patchWidth * scale);
-            int scaledHeight = (int) (patchHeight * scale);
-
-            horizontal.scaledWidth = scaledWidth;
-            vertical.scaledHeight = scaledHeight;
-            both.scaledWidth = scaledWidth;
-            both.scaledHeight = scaledHeight;
-
-            size = new Dimension(scaledWidth, scaledHeight);
-
-            computePatches();
-        }
-
-        void computePatches() {
-            boolean measuredWidth = false;
-            boolean endRow = true;
-
-            int remainderHorizontal = 0;
-            int remainderVertical = 0;
-
-            if (fixed.size() > 0) {
-                int start = fixed.get(0).y;
-                for (Rectangle rect : fixed) {
-                    if (rect.y > start) {
-                        endRow = true;
-                        measuredWidth = true;
-                    }
-                    if (!measuredWidth) {
-                        remainderHorizontal += rect.width;
-                    }
-                    if (endRow) {
-                        remainderVertical += rect.height;
-                        endRow = false;
-                        start = rect.y;
-                    }
-                }
-            }
-
-            horizontal.remainderHorizontal = horizontal.scaledWidth - remainderHorizontal;
-            vertical.remainderHorizontal = vertical.scaledWidth - remainderHorizontal;
-            both.remainderHorizontal = both.scaledWidth - remainderHorizontal;
-
-            horizontal.remainderVertical = horizontal.scaledHeight - remainderVertical;
-            vertical.remainderVertical = vertical.scaledHeight - remainderVertical;
-            both.remainderVertical = both.scaledHeight - remainderVertical;
-
-            horizontalPatchesSum = 0;
-            if (horizontalPatches.size() > 0) {
-                int start = -1;
-                for (Rectangle rect : horizontalPatches) {
-                    if (rect.x > start) {
-                        horizontalPatchesSum += rect.width;
-                        start = rect.x;
-                    }
-                }
-            }
-
-            verticalPatchesSum = 0;
-            if (verticalPatches.size() > 0) {
-                int start = -1;
-                for (Rectangle rect : verticalPatches) {
-                    if (rect.y > start) {
-                        verticalPatchesSum += rect.height;
-                        start = rect.y;
-                    }
-                }
-            }
-
-            setSize(size);
-            ImageEditorPanel.this.validate();
-            repaint();
-        }
-
-        void setPaddingVisible(boolean visible) {
-            showPadding = visible;
-            repaint();
-        }
-
-        private class StretchView extends JComponent {
-            private final Color PADDING_COLOR = new Color(0.37f, 0.37f, 1.0f, 0.5f);
-
-            int scaledWidth;
-            int scaledHeight;
-
-            int remainderHorizontal;
-            int remainderVertical;
-
-            StretchView() {
-                scaledWidth = image.getWidth();
-                scaledHeight = image.getHeight();
-            }
-
-            @Override
-            protected void paintComponent(Graphics g) {
-                int x = (getWidth() - scaledWidth) / 2;
-                int y = (getHeight() - scaledHeight) / 2;
-
-                Graphics2D g2 = (Graphics2D) g.create();
-                g2.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
-                        RenderingHints.VALUE_INTERPOLATION_BILINEAR);
-                g.translate(x, y);
-
-                x = 0;
-                y = 0;
-
-                if (patches.size() == 0 || horizontalPatches.size() == 0 ||
-                        verticalPatches.size() == 0) {
-                    g.drawImage(image, 0, 0, scaledWidth, scaledHeight, null);
-                    g2.dispose();
-                    return;
-                }
-
-                int fixedIndex = 0;
-                int horizontalIndex = 0;
-                int verticalIndex = 0;
-                int patchIndex = 0;
-
-                boolean hStretch;
-                boolean vStretch;
-
-                float vWeightSum = 1.0f;
-                float vRemainder = remainderVertical;
-
-                vStretch = verticalStartWithPatch;
-                while (y < scaledHeight - 1) {
-                    hStretch = horizontalStartWithPatch;
-
-                    int height = 0;
-                    float vExtra = 0.0f;
-
-                    float hWeightSum = 1.0f;
-                    float hRemainder = remainderHorizontal;
-
-                    while (x < scaledWidth - 1) {
-                        Rectangle r;
-                        if (!vStretch) {
-                            if (hStretch) {
-                                r = horizontalPatches.get(horizontalIndex++);
-                                float extra = r.width / horizontalPatchesSum;
-                                int width = (int) (extra * hRemainder / hWeightSum);
-                                hWeightSum -= extra;
-                                hRemainder -= width;
-                                g.drawImage(image, x, y, x + width, y + r.height, r.x, r.y,
-                                        r.x + r.width, r.y + r.height, null);
-                                x += width;
-                            } else {
-                                r = fixed.get(fixedIndex++);
-                                g.drawImage(image, x, y, x + r.width, y + r.height, r.x, r.y,
-                                        r.x + r.width, r.y + r.height, null);
-                                x += r.width;
-                            }
-                            height = r.height;
-                        } else {
-                            if (hStretch) {
-                                r = patches.get(patchIndex++);
-                                vExtra = r.height / verticalPatchesSum;
-                                height = (int) (vExtra * vRemainder / vWeightSum);
-                                float extra = r.width / horizontalPatchesSum;
-                                int width = (int) (extra * hRemainder / hWeightSum);
-                                hWeightSum -= extra;
-                                hRemainder -= width;
-                                g.drawImage(image, x, y, x + width, y + height, r.x, r.y,
-                                        r.x + r.width, r.y + r.height, null);
-                                x += width;
-                            } else {
-                                r = verticalPatches.get(verticalIndex++);
-                                vExtra = r.height / verticalPatchesSum;
-                                height = (int) (vExtra * vRemainder / vWeightSum);
-                                g.drawImage(image, x, y, x + r.width, y + height, r.x, r.y,
-                                        r.x + r.width, r.y + r.height, null);
-                                x += r.width;
-                            }
-                            
-                        }
-                        hStretch = !hStretch;
-                    }
-                    x = 0;
-                    y += height;
-                    if (vStretch) {
-                        vWeightSum -= vExtra;
-                        vRemainder -= height;
-                    }
-                    vStretch = !vStretch;
-                }
-
-                if (showPadding) {
-                    g.setColor(PADDING_COLOR);
-                    g.fillRect(horizontalPadding.first, verticalPadding.first,
-                            scaledWidth - horizontalPadding.first - horizontalPadding.second,
-                            scaledHeight - verticalPadding.first - verticalPadding.second);
-                }
-
-                g2.dispose();
-            }
-
-            @Override
-            public Dimension getPreferredSize() {
-                return size;
-            }
-        }
-    }
-
-    private class ImageViewer extends JComponent {
-        private final Color CORRUPTED_COLOR = new Color(1.0f, 0.0f, 0.0f, 0.7f);
-        private final Color LOCK_COLOR = new Color(0.0f, 0.0f, 0.0f, 0.7f);
-        private final Color STRIPES_COLOR = new Color(1.0f, 0.0f, 0.0f, 0.5f);
-        private final Color BACK_COLOR = new Color(0xc0c0c0);
-        private final Color HELP_COLOR = new Color(0xffffe1);
-        private final Color PATCH_COLOR = new Color(1.0f, 0.37f, 0.99f, 0.5f);
-        private final Color PATCH_ONEWAY_COLOR = new Color(0.37f, 1.0f, 0.37f, 0.5f);
-
-        private static final float STRIPES_WIDTH = 4.0f;
-        private static final double STRIPES_SPACING = 6.0;
-        private static final int STRIPES_ANGLE = 45;
-
-        private int zoom;
-        private boolean showPatches;
-        private boolean showLock = true;
-
-        private Dimension size;
-
-        private boolean locked;
-
-        private int[] row;
-        private int[] column;
-
-        private int lastPositionX;
-        private int lastPositionY;
-        private boolean showCursor;
-
-        private JLabel helpLabel;
-        private boolean eraseMode;
-
-        private JButton checkButton;
-        private List<Rectangle> corruptedPatches;
-        private boolean showBadPatches;
-
-        private JPanel helpPanel;
-
-        ImageViewer() {
-            setLayout(new GridBagLayout());
-            helpPanel = new JPanel(new BorderLayout());
-            helpPanel.setBorder(new EmptyBorder(0, 6, 0, 6));
-            helpPanel.setBackground(HELP_COLOR);
-            helpLabel = new JLabel("Press Shift to erase pixels");
-            helpLabel.putClientProperty("JComponent.sizeVariant", "small");            
-            helpPanel.add(helpLabel, BorderLayout.WEST);
-            checkButton = new JButton("Show bad patches");
-            checkButton.putClientProperty("JComponent.sizeVariant", "small");
-            checkButton.putClientProperty("JButton.buttonType", "roundRect");
-            helpPanel.add(checkButton, BorderLayout.EAST);
-
-            add(helpPanel, new GridBagConstraints(0, 0, 1, 1,
-                    1.0f, 1.0f, GridBagConstraints.FIRST_LINE_START, GridBagConstraints.HORIZONTAL,
-                    new Insets(0, 0, 0, 0), 0, 0));
-
-            setOpaque(true);
-
-            setZoom(DEFAULT_ZOOM);
-            findPatches();
-
-            addMouseListener(new MouseAdapter() {
-                @Override
-                public void mousePressed(MouseEvent event) {
-                    paint(event.getX(), event.getY(), event.isShiftDown() ? MouseEvent.BUTTON3 :
-                                event.getButton());
-                }
-            });
-            addMouseMotionListener(new MouseMotionAdapter() {
-                @Override
-                public void mouseDragged(MouseEvent event) {
-                    if (!checkLockedRegion(event.getX(), event.getY())) {
-                        paint(event.getX(), event.getY(), event.isShiftDown() ? MouseEvent.BUTTON3 :
-                                event.getButton());
-                    }
-                }
-
-                @Override
-                public void mouseMoved(MouseEvent event) {
-                    checkLockedRegion(event.getX(), event.getY());
-                }
-            });
-            Toolkit.getDefaultToolkit().addAWTEventListener(new AWTEventListener() {
-                public void eventDispatched(AWTEvent event) {
-                    enableEraseMode((KeyEvent) event);                    
-                }
-            }, AWTEvent.KEY_EVENT_MASK);
-
-            checkButton.addActionListener(new ActionListener() {
-                public void actionPerformed(ActionEvent event) {
-                    if (!showBadPatches) {
-                        findBadPatches();
-                        checkButton.setText("Hide bad patches");
-                    } else {
-                        checkButton.setText("Show bad patches");
-                        corruptedPatches = null;
-                    }
-                    repaint();
-                    showBadPatches = !showBadPatches;
-                }
-            });
-        }
-
-        private void findBadPatches() {
-            corruptedPatches = new ArrayList<Rectangle>();
-
-            for (Rectangle patch : patches) {
-                if (corruptPatch(patch)) {
-                    corruptedPatches.add(patch);
-                }
-            }
-
-            for (Rectangle patch : horizontalPatches) {
-                if (corruptHorizontalPatch(patch)) {
-                    corruptedPatches.add(patch);
-                }
-            }
-
-            for (Rectangle patch : verticalPatches) {
-                if (corruptVerticalPatch(patch)) {
-                    corruptedPatches.add(patch);
-                }
-            }
-        }
-
-        private boolean corruptPatch(Rectangle patch) {
-            int[] pixels = GraphicsUtilities.getPixels(image, patch.x, patch.y,
-                    patch.width, patch.height, null);
-
-            if (pixels.length > 0) {
-                int reference = pixels[0];
-                for (int pixel : pixels) {
-                    if (pixel != reference) {
-                        return true;
-                    }
-                }
-            }
-
-            return false;
-        }
-
-        private boolean corruptHorizontalPatch(Rectangle patch) {
-            int[] reference = new int[patch.height];
-            int[] column = new int[patch.height];
-            reference = GraphicsUtilities.getPixels(image, patch.x, patch.y,
-                    1, patch.height, reference);
-
-            for (int i = 1; i < patch.width; i++) {
-                column = GraphicsUtilities.getPixels(image, patch.x + i, patch.y,
-                        1, patch.height, column);
-                if (!Arrays.equals(reference, column)) {
-                    return true;
-                }
-            }
-
-            return false;
-        }
-
-        private boolean corruptVerticalPatch(Rectangle patch) {
-            int[] reference = new int[patch.width];
-            int[] row = new int[patch.width];
-            reference = GraphicsUtilities.getPixels(image, patch.x, patch.y,
-                    patch.width, 1, reference);
-
-            for (int i = 1; i < patch.height; i++) {
-                row = GraphicsUtilities.getPixels(image, patch.x, patch.y + i, patch.width, 1, row);
-                if (!Arrays.equals(reference, row)) {
-                    return true;
-                }
-            }
-
-            return false;
-        }
-
-        private void enableEraseMode(KeyEvent event) {
-            boolean oldEraseMode = eraseMode;
-            eraseMode = event.isShiftDown();
-            if (eraseMode != oldEraseMode) {
-                if (eraseMode) {
-                    helpLabel.setText("Release Shift to draw pixels");
-                } else {
-                    helpLabel.setText("Press Shift to erase pixels");
-                }
-            }
-        }
-
-        private void paint(int x, int y, int button) {
-            int color;
-            switch (button) {
-                case MouseEvent.BUTTON1:
-                    color = 0xFF000000;
-                    break;
-                case MouseEvent.BUTTON3:
-                    color = 0;
-                    break;
-                default:
-                    return;
-            }
-
-            int left = (getWidth() - size.width) / 2;
-            int top = (helpPanel.getHeight() + getHeight() - size.height) / 2;
-
-            x = (x - left) / zoom;
-            y = (y - top) / zoom;
-
-            int width = image.getWidth();
-            int height = image.getHeight();
-            if (((x == 0 || x == width - 1) && (y > 0 && y < height - 1)) ||
-                    ((x > 0 && x < width - 1) && (y == 0 || y == height - 1))) {
-                image.setRGB(x, y, color);
-                findPatches();
-                stretchesViewer.computePatches();
-                if (showBadPatches) {
-                    findBadPatches();
-                }
-                repaint();
-            }
-        }
-
-        private boolean checkLockedRegion(int x, int y) {
-            int oldX = lastPositionX;
-            int oldY = lastPositionY;
-            lastPositionX = x;
-            lastPositionY = y;
-
-            int left = (getWidth() - size.width) / 2;
-            int top = (helpPanel.getHeight() + getHeight() - size.height) / 2;
-
-            x = (x - left) / zoom;
-            y = (y - top) / zoom;
-
-            int width = image.getWidth();
-            int height = image.getHeight();
-
-            xLabel.setText(Math.max(0, Math.min(x, width - 1)) + " px");
-            yLabel.setText(Math.max(0, Math.min(y, height - 1)) + " px");
-
-            boolean previousLock = locked;
-            locked = x > 0 && x < width - 1 && y > 0 && y < height - 1;
-
-            boolean previousCursor = showCursor;
-            showCursor = ((x == 0 || x == width - 1) && (y > 0 && y < height - 1)) ||
-                    ((x > 0 && x < width - 1) && (y == 0 || y == height - 1));
-
-            if (locked != previousLock) {
-                repaint();
-            } else if (showCursor || (showCursor != previousCursor)) {
-                Rectangle clip = new Rectangle(lastPositionX - 1 - zoom / 2,
-                        lastPositionY - 1 - zoom / 2, zoom + 2, zoom + 2);
-                clip = clip.union(new Rectangle(oldX - 1 - zoom / 2,
-                        oldY - 1 - zoom / 2, zoom + 2, zoom + 2));
-                repaint(clip);
-            }
-
-            return locked;
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            int x = (getWidth() - size.width) / 2;
-            int y = (helpPanel.getHeight() + getHeight() - size.height) / 2;
-
-            Graphics2D g2 = (Graphics2D) g.create();
-            g2.setColor(BACK_COLOR);
-            g2.fillRect(0, 0, getWidth(), getHeight());
-
-            g2.translate(x, y);
-            g2.setPaint(texture);
-            g2.fillRect(0, 0, size.width, size.height);
-            g2.scale(zoom, zoom);
-            g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
-                    RenderingHints.VALUE_ANTIALIAS_ON);
-            g2.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
-                    RenderingHints.VALUE_INTERPOLATION_NEAREST_NEIGHBOR);
-            g2.drawImage(image, 0, 0, null);
-
-            if (showPatches) {
-                g2.setColor(PATCH_COLOR);
-                for (Rectangle patch : patches) {
-                    g2.fillRect(patch.x, patch.y, patch.width, patch.height);
-                }
-                g2.setColor(PATCH_ONEWAY_COLOR);
-                for (Rectangle patch : horizontalPatches) {
-                    g2.fillRect(patch.x, patch.y, patch.width, patch.height);
-                }
-                for (Rectangle patch : verticalPatches) {
-                    g2.fillRect(patch.x, patch.y, patch.width, patch.height);
-                }
-            }
-
-            if (corruptedPatches != null) {
-                g2.setColor(CORRUPTED_COLOR);
-                g2.setStroke(new BasicStroke(3.0f / zoom));
-                for (Rectangle patch : corruptedPatches) {
-                    g2.draw(new RoundRectangle2D.Float(patch.x - 2.0f / zoom, patch.y - 2.0f / zoom,
-                            patch.width + 2.0f / zoom, patch.height + 2.0f / zoom,
-                            6.0f / zoom, 6.0f / zoom));
-                }
-            }
-
-            if (showLock && locked) {
-                int width = image.getWidth();
-                int height = image.getHeight();
-
-                g2.setColor(LOCK_COLOR);
-                g2.fillRect(1, 1, width - 2, height - 2);
-
-                g2.setColor(STRIPES_COLOR);
-                g2.translate(1, 1);
-                paintStripes(g2, width - 2, height - 2);
-                g2.translate(-1, -1);
-            }
-
-            g2.dispose();
-
-            if (showCursor) {
-                Graphics cursor = g.create();
-                cursor.setXORMode(Color.WHITE);
-                cursor.setColor(Color.BLACK);
-                cursor.drawRect(lastPositionX - zoom / 2, lastPositionY - zoom / 2, zoom, zoom);
-                cursor.dispose();
-            }
-        }
-
-        private void paintStripes(Graphics2D g, int width, int height) {
-            //draws pinstripes at the angle specified in this class
-            //and at the given distance apart
-            Shape oldClip = g.getClip();
-            Area area = new Area(new Rectangle(0, 0, width, height));
-            if(oldClip != null) {
-                area = new Area(oldClip);
-            }
-            area.intersect(new Area(new Rectangle(0,0,width,height)));
-            g.setClip(area);
-
-            g.setStroke(new BasicStroke(STRIPES_WIDTH));
-
-            double hypLength = Math.sqrt((width * width) +
-                    (height * height));
-
-            double radians = Math.toRadians(STRIPES_ANGLE);
-            g.rotate(radians);
-
-            double spacing = STRIPES_SPACING;
-            spacing += STRIPES_WIDTH;
-            int numLines = (int)(hypLength / spacing);
-
-            for (int i=0; i<numLines; i++) {
-                double x = i * spacing;
-                Line2D line = new Line2D.Double(x, -hypLength, x, hypLength);
-                g.draw(line);
-            }
-            g.setClip(oldClip);
-        }
-
-        @Override
-        public Dimension getPreferredSize() {
-            return size;
-        }
-
-        void setZoom(int value) {
-            int width = image.getWidth();
-            int height = image.getHeight();
-
-            zoom = value;
-            size = new Dimension(width * zoom, height * zoom);
-
-            setSize(size);
-            ImageEditorPanel.this.validate();
-            repaint();
-        }
-
-        void setPatchesVisible(boolean visible) {
-            showPatches = visible;
-            findPatches();
-            repaint();
-        }
-
-        private void findPatches() {
-            int width = image.getWidth();
-            int height = image.getHeight();
-
-            row = GraphicsUtilities.getPixels(image, 0, 0, width, 1, row);
-            column = GraphicsUtilities.getPixels(image, 0, 0, 1, height, column);
-
-            boolean[] result = new boolean[1];
-            Pair<List<Pair<Integer>>> left = getPatches(column, result);
-            verticalStartWithPatch = result[0];
-
-            result = new boolean[1];
-            Pair<List<Pair<Integer>>> top = getPatches(row, result);
-            horizontalStartWithPatch = result[0];
-
-            fixed = getRectangles(left.first, top.first);
-            patches = getRectangles(left.second, top.second);
-
-            if (fixed.size() > 0) {
-                horizontalPatches = getRectangles(left.first, top.second);
-                verticalPatches = getRectangles(left.second, top.first);
-            } else {
-                horizontalPatches = verticalPatches = new ArrayList<Rectangle>(0);
-            }
-
-            row = GraphicsUtilities.getPixels(image, 0, height - 1, width, 1, row);
-            column = GraphicsUtilities.getPixels(image, width - 1, 0, 1, height, column);
-
-            top = getPatches(row, result);
-            horizontalPadding = getPadding(top.first);
-
-            left = getPatches(column, result);
-            verticalPadding = getPadding(left.first);
-        }
-
-        private Pair<Integer> getPadding(List<Pair<Integer>> pairs) {
-            if (pairs.size() == 0) {
-                return new Pair<Integer>(0, 0);
-            } else if (pairs.size() == 1) {
-                if (pairs.get(0).first == 1) {
-                    return new Pair<Integer>(pairs.get(0).second - pairs.get(0).first, 0);
-                } else {
-                    return new Pair<Integer>(0, pairs.get(0).second - pairs.get(0).first);                    
-                }
-            } else {
-                int index = pairs.size() - 1;
-                return new Pair<Integer>(pairs.get(0).second - pairs.get(0).first,
-                        pairs.get(index).second - pairs.get(index).first);
-            }
-        }
-
-        private List<Rectangle> getRectangles(List<Pair<Integer>> leftPairs,
-                List<Pair<Integer>> topPairs) {
-            List<Rectangle> rectangles = new ArrayList<Rectangle>();
-            for (Pair<Integer> left : leftPairs) {
-                int y = left.first;
-                int height = left.second - left.first;
-                for (Pair<Integer> top: topPairs) {
-                    int x = top.first;
-                    int width = top.second - top.first;
-
-                    rectangles.add(new Rectangle(x, y, width, height));
-                }
-            }
-            return rectangles;
-        }
-
-        private Pair<List<Pair<Integer>>> getPatches(int[] pixels, boolean[] startWithPatch) {
-            int lastIndex = 1;
-            int lastPixel = pixels[1];
-            boolean first = true;
-
-            List<Pair<Integer>> fixed = new ArrayList<Pair<Integer>>();
-            List<Pair<Integer>> patches = new ArrayList<Pair<Integer>>();
-
-            for (int i = 1; i < pixels.length - 1; i++) {
-                int pixel = pixels[i];
-                if (pixel != lastPixel) {
-                    if (lastPixel == 0xFF000000) {
-                        if (first) startWithPatch[0] = true;
-                        patches.add(new Pair<Integer>(lastIndex, i));
-                    } else {
-                        fixed.add(new Pair<Integer>(lastIndex, i));
-                    }
-                    first = false;
-
-                    lastIndex = i;
-                    lastPixel = pixel;
-                }
-            }
-            if (lastPixel == 0xFF000000) {
-                if (first) startWithPatch[0] = true;
-                patches.add(new Pair<Integer>(lastIndex, pixels.length - 1));
-            } else {
-                fixed.add(new Pair<Integer>(lastIndex, pixels.length - 1));
-            }
-
-            if (patches.size() == 0) {
-                patches.add(new Pair<Integer>(1, pixels.length - 1));
-                startWithPatch[0] = true;
-                fixed.clear();
-            }
-            return new Pair<List<Pair<Integer>>>(fixed, patches);
-        }
-
-        void setLockVisible(boolean visible) {
-            showLock = visible;
-            repaint();
-        }
-    }
-
-    static class Pair<E> {
-        E first;
-        E second;
-
-        Pair(E first, E second) {
-            this.first = first;
-            this.second = second;
-        }
-
-        @Override
-        public String toString() {
-            return "Pair[" + first + ", " + second + "]";
-        }
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/ImageTransferHandler.java b/tools/draw9patch/src/com/android/draw9patch/ui/ImageTransferHandler.java
deleted file mode 100644
index a62884f..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/ImageTransferHandler.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui;
-
-import javax.swing.TransferHandler;
-import javax.swing.JComponent;
-import java.awt.datatransfer.Transferable;
-import java.awt.datatransfer.DataFlavor;
-import java.awt.datatransfer.UnsupportedFlavorException;
-import java.io.File;
-import java.io.IOException;
-import java.util.List;
-import java.net.MalformedURLException;
-
-class ImageTransferHandler extends TransferHandler {
-    private final MainFrame mainFrame;
-
-    ImageTransferHandler(MainFrame mainFrame) {
-        this.mainFrame = mainFrame;
-    }
-
-    @Override
-    public boolean importData(JComponent component, Transferable transferable) {
-        try {
-            Object data = transferable.getTransferData(DataFlavor.javaFileListFlavor);
-            //noinspection unchecked
-            final File file = ((List<File>) data).get(0);
-            mainFrame.open(file).execute();
-        } catch (UnsupportedFlavorException e) {
-            return false;
-        } catch (MalformedURLException e) {
-            e.printStackTrace();
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-
-        return true;
-    }
-
-    @Override
-    public boolean canImport(JComponent component, DataFlavor[] dataFlavors) {
-        for (DataFlavor flavor : dataFlavors) {
-            if (flavor.isFlavorJavaFileListType()) {
-                return true;
-            }
-        }
-        return false;
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/MainFrame.java b/tools/draw9patch/src/com/android/draw9patch/ui/MainFrame.java
deleted file mode 100644
index 9ffd93e..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/MainFrame.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui;
-
-import com.android.draw9patch.ui.action.ExitAction;
-import com.android.draw9patch.ui.action.OpenAction;
-import com.android.draw9patch.ui.action.SaveAction;
-import com.android.draw9patch.graphics.GraphicsUtilities;
-
-import javax.swing.JFrame;
-import javax.swing.JMenuBar;
-import javax.swing.JMenu;
-import javax.swing.JMenuItem;
-import javax.swing.ActionMap;
-import javax.swing.JFileChooser;
-import javax.imageio.ImageIO;
-import java.awt.HeadlessException;
-import java.awt.image.BufferedImage;
-import java.io.File;
-import java.util.concurrent.ExecutionException;
-
-import org.jdesktop.swingworker.SwingWorker;
-
-public class MainFrame extends JFrame {
-    private ActionMap actionsMap;
-    private JMenuItem saveMenuItem;
-    private ImageEditorPanel imageEditor;
-
-    public MainFrame() throws HeadlessException {
-        super("Draw 9-patch");
-
-        buildActions();
-        buildMenuBar();
-        buildContent();
-
-        showOpenFilePanel();
-
-        // pack();
-        setSize(1024, 600);
-    }
-
-    private void buildActions() {
-        actionsMap = new ActionMap();
-        actionsMap.put(OpenAction.ACTION_NAME, new OpenAction(this));
-        actionsMap.put(SaveAction.ACTION_NAME, new SaveAction(this));
-        actionsMap.put(ExitAction.ACTION_NAME, new ExitAction(this));
-    }
-
-    private void buildMenuBar() {
-        JMenu fileMenu = new JMenu("File");
-        JMenuItem openMenuItem = new JMenuItem();
-        saveMenuItem = new JMenuItem();
-        JMenuItem exitMenuItem = new JMenuItem();
-
-        openMenuItem.setAction(actionsMap.get(OpenAction.ACTION_NAME));
-        fileMenu.add(openMenuItem);
-
-        saveMenuItem.setAction(actionsMap.get(SaveAction.ACTION_NAME));
-        saveMenuItem.setEnabled(false);
-        fileMenu.add(saveMenuItem);
-
-        exitMenuItem.setAction(actionsMap.get(ExitAction.ACTION_NAME));
-        fileMenu.add(exitMenuItem);
-
-        JMenuBar menuBar = new JMenuBar();
-        menuBar.add(fileMenu);
-        setJMenuBar(menuBar);
-    }
-
-    private void buildContent() {
-        setContentPane(new GradientPanel());
-    }
-
-    private void showOpenFilePanel() {
-        add(new OpenFilePanel(this));
-    }
-
-    public SwingWorker<?, ?> open(File file) {
-        if (file == null) {
-            JFileChooser chooser = new JFileChooser();
-            chooser.setFileFilter(new PngFileFilter());
-            int choice = chooser.showOpenDialog(this);
-            if (choice == JFileChooser.APPROVE_OPTION) {
-                return new OpenTask(chooser.getSelectedFile());
-            } else {
-                return null;
-            }
-        } else {
-            return new OpenTask(file);
-        }
-    }
-
-    void showImageEditor(BufferedImage image, String name) {
-        getContentPane().removeAll();
-        imageEditor = new ImageEditorPanel(this, image, name);
-        add(imageEditor);
-        saveMenuItem.setEnabled(true);
-        validate();
-        repaint();
-    }
-
-    public SwingWorker<?, ?> save() {
-        if (imageEditor == null) {
-            return null;
-        }
-
-        File file = imageEditor.chooseSaveFile();
-        return file != null ? new SaveTask(file) : null;
-    }
-
-    private class SaveTask extends SwingWorker<Boolean, Void> {
-        private final File file;
-
-        SaveTask(File file) {
-            this.file = file;
-        }
-
-        protected Boolean doInBackground() throws Exception {
-            try {
-                ImageIO.write(imageEditor.getImage(), "PNG", file);
-            } catch (Exception e) {
-                e.printStackTrace();
-            }
-            return true;
-        }
-    }
-
-    private class OpenTask extends SwingWorker<BufferedImage, Void> {
-        private final File file;
-
-        OpenTask(File file) {
-            this.file = file;
-        }
-
-        protected BufferedImage doInBackground() throws Exception {
-            return GraphicsUtilities.loadCompatibleImage(file.toURI().toURL());
-        }
-
-        @Override
-        protected void done() {
-            try {
-                showImageEditor(get(), file.getAbsolutePath());
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            }
-        }
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/OpenFilePanel.java b/tools/draw9patch/src/com/android/draw9patch/ui/OpenFilePanel.java
deleted file mode 100644
index a444332..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/OpenFilePanel.java
+++ /dev/null
@@ -1,51 +0,0 @@
-package com.android.draw9patch.ui;
-
-import com.android.draw9patch.graphics.GraphicsUtilities;
-
-import javax.swing.JComponent;
-import java.awt.image.BufferedImage;
-import java.awt.Graphics;
-import java.io.IOException;
-import java.net.URL;/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-class OpenFilePanel extends JComponent {
-    private BufferedImage dropHere;
-
-    OpenFilePanel(MainFrame mainFrame) {
-        setOpaque(false);
-        loadSupportImage();
-        setTransferHandler(new ImageTransferHandler(mainFrame));
-    }
-
-    private void loadSupportImage() {
-        try {
-            URL resource = getClass().getResource("/images/drop.png");
-            dropHere = GraphicsUtilities.loadCompatibleImage(resource);
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-
-    @Override
-    protected void paintComponent(Graphics g) {
-        int x = (getWidth() - dropHere.getWidth()) / 2;
-        int y = (getHeight() - dropHere.getHeight()) / 2;
-
-        g.drawImage(dropHere, x, y, null);
-    }
-
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/PngFileFilter.java b/tools/draw9patch/src/com/android/draw9patch/ui/PngFileFilter.java
deleted file mode 100644
index 8f8885a..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/PngFileFilter.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui;
-
-import javax.swing.filechooser.FileFilter;
-import java.io.File;
-
-class PngFileFilter extends FileFilter {
-    @Override
-    public boolean accept(File f) {
-        return f.isDirectory() || f.getName().toLowerCase().endsWith(".png");
-    }
-
-    @Override
-    public String getDescription() {
-        return "PNG Image (*.png)";
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/action/BackgroundAction.java b/tools/draw9patch/src/com/android/draw9patch/ui/action/BackgroundAction.java
deleted file mode 100644
index 85d9d4f..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/action/BackgroundAction.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui.action;
-
-import org.jdesktop.swingworker.SwingWorker;
-
-import javax.swing.AbstractAction;
-
-public abstract class BackgroundAction extends AbstractAction {
-    protected void executeBackgroundTask(SwingWorker<?, ?> worker) {
-        if (worker != null) {
-            worker.execute();
-        }
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/action/ExitAction.java b/tools/draw9patch/src/com/android/draw9patch/ui/action/ExitAction.java
deleted file mode 100644
index b6f047d..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/action/ExitAction.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui.action;
-
-import javax.swing.AbstractAction;
-import javax.swing.KeyStroke;
-import javax.swing.JFrame;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class ExitAction extends AbstractAction {
-    public static final String ACTION_NAME = "exit";
-    private JFrame frame;
-
-    public ExitAction(JFrame frame) {
-        putValue(NAME, "Quit");
-        putValue(SHORT_DESCRIPTION, "Quit");
-        putValue(LONG_DESCRIPTION, "Quit");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_Q);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_Q,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.frame = frame;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        frame.dispose();
-        System.exit(0);
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/action/OpenAction.java b/tools/draw9patch/src/com/android/draw9patch/ui/action/OpenAction.java
deleted file mode 100644
index 45ee5be..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/action/OpenAction.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui.action;
-
-import com.android.draw9patch.ui.MainFrame;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class OpenAction extends BackgroundAction {
-    public static final String ACTION_NAME = "open";
-    private MainFrame frame;
-
-    public OpenAction(MainFrame frame) {
-        this.frame = frame;
-        putValue(NAME, "Open 9-patch...");
-        putValue(SHORT_DESCRIPTION, "Open...");
-        putValue(LONG_DESCRIPTION, "Open 9-patch...");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_O);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_O,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(frame.open(null));
-    }
-}
diff --git a/tools/draw9patch/src/com/android/draw9patch/ui/action/SaveAction.java b/tools/draw9patch/src/com/android/draw9patch/ui/action/SaveAction.java
deleted file mode 100644
index 5c1dc52..0000000
--- a/tools/draw9patch/src/com/android/draw9patch/ui/action/SaveAction.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.draw9patch.ui.action;
-
-import com.android.draw9patch.ui.MainFrame;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class SaveAction extends BackgroundAction {
-    public static final String ACTION_NAME = "save";
-    private MainFrame frame;
-
-    public SaveAction(MainFrame frame) {
-        this.frame = frame;
-        putValue(NAME, "Save 9-patch...");
-        putValue(SHORT_DESCRIPTION, "Save...");
-        putValue(LONG_DESCRIPTION, "Save 9-patch...");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_S);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_S,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(frame.save());
-    }
-}
diff --git a/tools/draw9patch/src/resources/images/checker.png b/tools/draw9patch/src/resources/images/checker.png
deleted file mode 100644
index 78908f4..0000000
--- a/tools/draw9patch/src/resources/images/checker.png
+++ /dev/null
Binary files differ
diff --git a/tools/draw9patch/src/resources/images/drop.png b/tools/draw9patch/src/resources/images/drop.png
deleted file mode 100644
index 7a7436a..0000000
--- a/tools/draw9patch/src/resources/images/drop.png
+++ /dev/null
Binary files differ
diff --git a/tools/dumpeventlog/.classpath b/tools/dumpeventlog/.classpath
deleted file mode 100644
index b0326c8..0000000
--- a/tools/dumpeventlog/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmlib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/dumpeventlog/.project b/tools/dumpeventlog/.project
deleted file mode 100644
index c416f4f..0000000
--- a/tools/dumpeventlog/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>dumpeventlog</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/dumpeventlog/Android.mk b/tools/dumpeventlog/Android.mk
deleted file mode 100644
index 7bb870d..0000000
--- a/tools/dumpeventlog/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-DUMPEVENTLOG_LOCAL_DIR := $(call my-dir)
-include $(DUMPEVENTLOG_LOCAL_DIR)/etc/Android.mk
-include $(DUMPEVENTLOG_LOCAL_DIR)/src/Android.mk
diff --git a/tools/dumpeventlog/etc/Android.mk b/tools/dumpeventlog/etc/Android.mk
deleted file mode 100644
index 8094734..0000000
--- a/tools/dumpeventlog/etc/Android.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := dumpeventlog
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/dumpeventlog/etc/dumpeventlog b/tools/dumpeventlog/etc/dumpeventlog
deleted file mode 100755
index 56f8c22..0000000
--- a/tools/dumpeventlog/etc/dumpeventlog
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=dumpeventlog.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-if [ debug = "$1" ]; then
-    # add this in for debugging
-    java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-else
-    java_debug=
-fi
-
-# Mac OS X needs an additional arg, or you get an "illegal thread" complaint.
-if [ `uname` = "Darwin" ]; then
-    os_opts="-XstartOnFirstThread"
-else
-    os_opts=
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Xmx128M $os_opts $java_debug -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -jar "$jarpath" "$@"
diff --git a/tools/dumpeventlog/etc/manifest.txt b/tools/dumpeventlog/etc/manifest.txt
deleted file mode 100644
index 0eea915..0000000
--- a/tools/dumpeventlog/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.dumpeventlog.DumpEventLog
diff --git a/tools/dumpeventlog/src/Android.mk b/tools/dumpeventlog/src/Android.mk
deleted file mode 100644
index bf99375..0000000
--- a/tools/dumpeventlog/src/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	ddmlib
-LOCAL_MODULE := dumpeventlog
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/dumpeventlog/src/com/android/dumpeventlog/DumpEventLog.java b/tools/dumpeventlog/src/com/android/dumpeventlog/DumpEventLog.java
deleted file mode 100644
index 6c528e1..0000000
--- a/tools/dumpeventlog/src/com/android/dumpeventlog/DumpEventLog.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.dumpeventlog;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.ILogOutput;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmlib.log.LogReceiver;
-import com.android.ddmlib.log.LogReceiver.ILogListener;
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-
-/**
- * Connects to a device using ddmlib and dumps its event log as long as the device is connected. 
- */
-public class DumpEventLog {
-
-    /**
-     * Custom {@link ILogListener} to receive and save the event log raw output.
-     */
-    private static class LogWriter implements ILogListener {
-        private FileOutputStream mOutputStream;
-        private LogReceiver mReceiver;
-
-        public LogWriter(String filePath) throws IOException {
-            mOutputStream = new FileOutputStream(filePath);
-        }
-
-        public void newData(byte[] data, int offset, int length) {
-            try {
-                mOutputStream.write(data, offset, length);
-            } catch (IOException e) {
-                if (mReceiver != null) {
-                    mReceiver.cancel();
-                }
-                System.out.println(e);
-            }
-        }
-
-        public void newEntry(LogEntry entry) {
-            // pass
-        }
-
-        public void setReceiver(LogReceiver receiver) {
-            mReceiver = receiver;
-        }
-
-        public void done() throws IOException {
-            mOutputStream.close();
-        }
-    }
-
-    public static void main(String[] args) {
-        if (args.length != 2) {
-            System.out.println("Usage: dumpeventlog <device s/n> <filepath>");
-            return;
-        }
-        
-        // redirect the log output to /dev/null
-        Log.setLogOutput(new ILogOutput() {
-            public void printAndPromptLog(LogLevel logLevel, String tag, String message) {
-                // pass
-            }
-
-            public void printLog(LogLevel logLevel, String tag, String message) {
-                // pass
-            }
-        });
-        
-        // init the lib
-        AndroidDebugBridge.init(false /* debugger support */);
-        
-        try {
-            AndroidDebugBridge bridge = AndroidDebugBridge.createBridge();
-            
-            // we can't just ask for the device list right away, as the internal thread getting
-            // them from ADB may not be done getting the first list.
-            // Since we don't really want getDevices() to be blocking, we wait here manually.
-            int count = 0;
-            while (bridge.hasInitialDeviceList() == false) {
-                try {
-                    Thread.sleep(100);
-                    count++;
-                } catch (InterruptedException e) {
-                    // pass
-                }
-                
-                // let's not wait > 10 sec.
-                if (count > 100) {
-                    System.err.println("Timeout getting device list!");
-                    return;
-                }
-            }
-
-            // now get the devices
-            Device[] devices = bridge.getDevices();
-            
-            for (Device device : devices) {
-                if (device.getSerialNumber().equals(args[0])) {
-                    try {
-                        grabLogFrom(device, args[1]);
-                    } catch (FileNotFoundException e) {
-                        e.printStackTrace();
-                    } catch (IOException e) {
-                        e.printStackTrace();
-                    }
-                    return;
-                }
-            }
-            
-            System.err.println("Could not find " + args[0]);
-        } finally {
-            AndroidDebugBridge.terminate();
-        }
-    }
-
-    private static void grabLogFrom(Device device, String filePath) throws IOException {
-        LogWriter writer = new LogWriter(filePath);
-        LogReceiver receiver = new LogReceiver(writer);
-        writer.setReceiver(receiver);
-
-        device.runEventLogService(receiver);
-        
-        writer.done();
-    }
-}
diff --git a/tools/eclipse/README_WINDOWS.txt b/tools/eclipse/README_WINDOWS.txt
deleted file mode 100644
index 1480f5d..0000000
--- a/tools/eclipse/README_WINDOWS.txt
+++ /dev/null
@@ -1,32 +0,0 @@
-[RM 20080623]
-
-1- To build the Eclipse plugin:
-Under Linux:
-$ cd your-device-directory
-$ tools/eclipse/scripts/build_server.sh destination-directory
-
-This will create an "android-eclipse.zip" in the selected destination directory.
-Then in Eclipse, you can use Help > Software Updates > Find and Install > Search for new Features > Next > New Archived Site > select the new android-eclipse.zip. Then with the new archive checked, click Finish/Next.
-
-
-2- To build a Windows SDK, you need two steps:
-a- First you need to create a Linux SDK:
-
-Under Linux:
-$ cd your-device-directory
-$ make sdk
-Note: if you get an error when building the javadoc, make sure you use a Java SDK 1.5
-Note: if you get an error when building layoutlib, make sure you use a Java SDK 1.5.0-b13.
-
-b- Once you have a Linux SDK, you can create a Windows SDK:
-
-You need a Windows machine with XP or Vista and Cygwin.
-- Installer at http://sources.redhat.com/cygwin/
-- Set Default Text File Type to DOS/text, not Unix/binary.
-- Select packages autoconf, gcc, g++, bison, python, zip, unzip, mingw-zlib
-- Suggested extra packages: emacs, wget, openssh, rsync
-
-Then under Cygwin:
-$ cd your-device-directory
-$ tools/buildbot/_make_windows_sdk.sh path-to-the-linux-sdk.zip destination-directory
-
diff --git a/tools/eclipse/buildConfig/allElements.xml b/tools/eclipse/buildConfig/allElements.xml
deleted file mode 100644
index 2c8229c..0000000
--- a/tools/eclipse/buildConfig/allElements.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<!-- ========================================================================= -->
-<!-- Feature build ant targets                                                 -->
-<!-- Template obtained from org.eclipse.pde.build/templates/headless-build     -->
-<!-- ========================================================================= -->
-<project name="allElements Delegator">
-    
-     <!-- ===================================================================== -->
-     <!-- Run a given ${target} on all elements being built                     -->
-     <!-- Replace element.id with the id of the top level element being built.    -->
-     <!-- If element.id does not exist in ${buildDirectory}/features/element.id   -->
-     <!-- or ${baseLocation}/features/element.id, then you must provide the       -->
-     <!-- location by setting the property "pluginPath"                           -->
-     <!-- Add on <ant> task for each top level element being built.             -->
-     <!-- ===================================================================== -->
-     <target name="allElementsDelegator">
-         
-         <ant antfile="${genericTargets}" target="${target}">
-             <property name="type" value="feature" />
-             <property name="id" value="com.android.ide.eclipse.ddms" />
-         </ant>
-
-         <ant antfile="${genericTargets}" target="${target}">
-             <property name="type" value="feature" />
-             <property name="id" value="com.android.ide.eclipse.adt" />
-         </ant>
-         
-        <antcall target="buildInternalFeatures"/>
-         
-     </target>
-    
-     <!-- ===================================================================== -->
-     <!-- Conditional target for building the internal features                 -->
-     <!-- Builds if property internalSite is set                                -->
-     <!-- ===================================================================== -->
-     <target name="buildInternalFeatures" if="internalSite">
-        <ant antfile="${genericTargets}" target="${target}">
-            <property name="type" value="feature" />
-            <property name="id" value="com.android.ide.eclipse.tests" />
-        </ant>
-     </target>    
-         
-     <!-- ===================================================================== -->
-     <!-- Targets to assemble the built elements for particular configurations  -->
-     <!-- These generally call the generated assemble scripts (named in         -->
-     <!-- ${assembleScriptName}) but may also add pre and post processing       -->
-     <!-- Add one target for each root element and each configuration           -->
-     <!-- Replace element.id with the id of the top level element being built   -->
-     <!-- ===================================================================== -->
-     <target name="assemble.com.android.ide.eclipse.adt">
-         <ant antfile="${assembleScriptName}" dir="${buildDirectory}"/>
-     </target>
-
-     <target name="assemble.com.android.ide.eclipse.ddms">
-         <ant antfile="${assembleScriptName}" dir="${buildDirectory}"/>
-     </target>
-    
-    <target name="assemble.com.android.ide.eclipse.tests">
-        <ant antfile="${assembleScriptName}" dir="${buildDirectory}"/>
-    </target>
-</project>
diff --git a/tools/eclipse/buildConfig/build.properties b/tools/eclipse/buildConfig/build.properties
deleted file mode 100644
index cd477d8..0000000
--- a/tools/eclipse/buildConfig/build.properties
+++ /dev/null
@@ -1,238 +0,0 @@
-###############################################################################
-# Copyright (c) 2003, 2006 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-# 
-# Contributors:
-#     IBM Corporation - initial API and implementation
-###############################################################################
-
-
-# This file was generated per the instructions located in Eclipse Help>Plug-in Development
-# Environment >  Guide > Tasks > Building features and customized for building the
-# Android Eclipse plugins.
-
-#####################
-# Parameters describing how and where to execute the build.
-# Typical users need only update the following properties:
-#    baseLocation - where things you are building against are installed
-#    bootclasspath - The base jars to compile against (typicaly rt.jar)
-#    configs - the list of {os, ws, arch} configurations to build.  
-#
-# Of course any of the settings here can be overridden by spec'ing 
-# them on the command line (e.g., -DbaseLocation=d:/eclipse
-
-############# PRODUCT/PACKAGING CONTROL #############
-product=/plugin or feature id/path/to/.product
-runPackager=true
-
-#Set the name of the archive that will result from the product build.
-#archiveNamePrefix=
-
-# The prefix that will be used in the generated archive.
-# override default of "eclipse" to aid for external site generation 
-archivePrefix=android-eclipse
-
-# The location underwhich all of the build output will be collected.
-collectingFolder=${archivePrefix}
-
-# The list of {os, ws, arch} configurations to build.  This 
-# value is a '&' separated list of ',' separate triples.  For example, 
-#     configs=win32,win32,x86 & linux,motif,x86
-# By default the value is *,*,*
-configs = *, *, *
-#configs=win32, win32, x86 & \
-#	linux, gtk, ppc &\
-# linux, gtk, x86 & \
-#	linux, gtk, x86_64 & \
-#	linux, motif, x86 & \
-#	solaris, motif, sparc & \
-#	solaris, gtk, sparc & \
-#	aix, motif, ppc & \
-#	hpux, motif, PA_RISC & \
-#	macosx, carbon, ppc
-
-# By default PDE creates one archive (result) per entry listed in the configs property.
-# Setting this value to try will cause PDE to only create one output containing all 
-# artifacts for all the platforms listed in the configs property.
-#groupConfigurations=true
-
-#The format of the archive. By default a zip is created using antZip.
-#The list can only contain the configuration for which the desired format is different than zip.
-#archivesFormat=win32, win32, x86 - antZip& \
-#	linux, gtk, ppc - antZip &\
-#    linux, gtk, x86 - antZip& \
-#	linux, gtk, x86_64 - antZip& \
-# linux, motif, x86 - antZip& \
-#	solaris, motif, sparc - antZip& \
-#	solaris, gtk, sparc - antZip& \
-#	aix, motif, ppc - antZip& \
-#	hpux, motif, PA_RISC - antZip& \
-#	macosx, carbon, ppc - antZip
-	
-#Set to true if you want the output to be ready for an update jar (no site.xml generated)
-outputUpdateJars = true
-
-#Set to true for Jnlp generation
-#codebase should be a URL that will be used as the root of all relative URLs in the output.
-#generateJnlp=false
-#jnlp.codebase=<codebase url>
-#jnlp.j2se=<j2se version>
-#jnlp.locale=<a locale>
-#jnlp.generateOfflineAllowed=true or false generate <offlineAllowed/> attribute in the generated features
-#jnlp.configs=${configs}			#uncomment to filter the content of the generated jnlp files based on the configuration being built
-
-#Set to true if you want to sign jars
-#signJars=false
-#sign.alias=<alias>
-#sign.keystore=<keystore location>
-#sign.storepass=<keystore password>
-
-#Arguments to send to the zip executable
-zipargs=
-
-#Arguments to send to the tar executable
-tarargs=
-
-#Control the creation of a file containing the version included in each configuration - on by default 
-#generateVersionsLists=false
-
-############## BUILD NAMING CONTROL ################
-# The directory into which the build elements are fetched and where
-# the build takes place.
-buildDirectory=.
-
-# Type of build.  Used in naming the build output.  Typically this value is
-# one of I, N, M, S, ...
-buildType=build
-
-# ID of the build.  Used in naming the build output.
-# forceContextQualifer = build label
-buildId=${forceContextQualifier}
-
-# Label for the build.  Used in naming the build output
-buildLabel=${buildId}
-
-# Timestamp for the build.  Used in naming the build output
-timestamp=007
-
-#The value to be used for the qualifier of a plugin or feature when you want to override the value computed by pde.
-#The value will only be applied to plugin or features indicating build.properties, qualifier = context 
-#forceContextQualifier=<the value for the qualifier>
-
-#Enable / disable the generation of a suffix for the features that use .qualifier. 
-#The generated suffix is computed according to the content of the feature   
-#generateFeatureVersionSuffix=true
-
-############# BASE CONTROL #############
-# Settings for the base Eclipse components and Java class libraries 
-# against which you are building.
-# Base location for anything the build needs to compile against.  For example,
-# in most RCP app or a plug-in,  the baseLocation should be the location of a previously
-# installed Eclipse against which the application or plug-in code will be compiled and the RCP delta pack.
-
-baseLocation=${ECLIPSE_HOME}
-#Os/Ws/Arch/nl of the eclipse specified by baseLocation
-baseos=linux
-basews=gtk
-basearch=x86
-
-#this property indicates whether you want the set of plug-ins and features to be considered during the build to be limited to the ones reachable from the features / plugins being built
-filteredDependencyCheck=false
-
-#this property indicates whether the resolution should be done in development mode (i.e. ignore multiple bundles with singletons)
-resolution.devMode=false
-
-#pluginPath is a list of locations in which to find plugins and features.  This list is separated by the platform file separator (; or :)
-#a location is one of:  
-#- the location of the jar or folder that is the plugin or feature : /path/to/foo.jar or /path/to/foo
-#- a directory that contains a /plugins or /features subdirectory
-#- the location of a feature.xml, or for 2.1 style plugins, the plugin.xml or fragment.xml
-#pluginPath=
-
-skipBase=true
-eclipseURL=<url for eclipse download site>
-eclipseBuildId=<Id of Eclipse build to get>
-eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip
-
-
-############# MAP FILE CONTROL ################
-# This section defines CVS tags to use when fetching the map files from the repository.
-# If you want to fetch the map file from repository / location, change the getMapFiles target in the customTargets.xml
-
-skipMaps=true
-mapsRepo=:pserver:anonymous@example.com/path/to/repo
-mapsRoot=path/to/maps
-mapsCheckoutTag=HEAD
-
-#tagMaps=true
-mapsTagTag=v${buildId}
-
-
-############ REPOSITORY CONTROL ###############
-# This section defines properties parameterizing the repositories where plugins, fragments
-# bundles and features are being obtained from. 
-
-# The tags to use when fetching elements to build.
-# By default thebuilder will use whatever is in the maps.  
-# This value takes the form of a comma separated list of repository identifier (like used in the map files) and the 
-# overriding value
-# For example fetchTag=CVS=HEAD, SVN=v20050101
-# fetchTag=HEAD
-skipFetch=true
-
-
-############# JAVA COMPILER OPTIONS ##############
-# The location of the Java jars to compile against.  Typically the rt.jar for your JDK/JRE
-#bootclasspath=${java.home}/lib/rt.jar
-
-# specific JRE locations to compile against. These values are used to compile bundles specifying a 
-# Bundle-RequiredExecutionEnvironment. Uncomment and set values for environments that you support
-#CDC-1.0/Foundation-1.0= /path/to/rt.jar
-#CDC-1.1/Foundation-1.1=
-#OSGi/Minimum-1.0=
-#OSGi/Minimum-1.1=
-#JRE-1.1=
-#J2SE-1.2=
-#J2SE-1.3=
-#J2SE-1.4=
-#J2SE-1.5=
-#JavaSE-1.6=
-#PersonalJava-1.1=
-#PersonalJava-1.2=
-#CDC-1.0/PersonalBasis-1.0=
-#CDC-1.0/PersonalJava-1.0=
-#CDC-1.1/PersonalBasis-1.1=
-#CDC-1.1/PersonalJava-1.1=
-
-# Specify the output format of the compiler log when eclipse jdt is used
-logExtension=.log
-
-# Whether or not to include debug info in the output jars
-javacDebugInfo=false 
-
-# Whether or not to fail the build if there are compiler errors
-javacFailOnError=true
-
-# Enable or disable verbose mode of the compiler
-javacVerbose=true
-
-# Extra arguments for the compiler. These are specific to the java compiler being used.
-#compilerArg=
-
-# Default value for the version of the source code. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacSource in build.properties
-javacSource=1.5
-
-# Default value for the version of the byte code targeted. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacTarget in build.properties.
-javacTarget=1.5
-
-################### CUSTOM PROPERTIES #######################################
-# repository location for update site
-# comment out - this is passed in from command line 
-#updateSiteSource=${buildDirectory}/sites/external
-# where to place update site build
-updateSiteRoot=${user.home}/www/no_crawl/
-updateSiteFolder=${archivePrefix}
-updateSiteDestination=${updateSiteRoot}/${updateSiteFolder}
diff --git a/tools/eclipse/buildConfig/buildUpdateSite.xml b/tools/eclipse/buildConfig/buildUpdateSite.xml
deleted file mode 100644
index 1ab7c99..0000000
--- a/tools/eclipse/buildConfig/buildUpdateSite.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<project name="update site">
-    <!-- ========================================================================= -->
-    <!-- Extracts feature zip for update site                                      -->
-    <!-- expected properties:                                                      -->
-    <!--    id - feature id to extract                                             -->
-    <!--    buildDirectory - base directgory where build takes place               -->
-    <!--    buildLabel - build id label                                            -->
-    <!--    updateSiteRoot - where to extract feature zip                          -->
-    <!-- ========================================================================= -->
-    <target name="extractFeature">
-        <unzip src="${buildDirectory}/${buildLabel}/${id}-${buildLabel}.zip" dest="${updateSiteRoot}"/>        
-    </target>
-</project>
diff --git a/tools/eclipse/buildConfig/customTargets.xml b/tools/eclipse/buildConfig/customTargets.xml
deleted file mode 100644
index 5a46bfc..0000000
--- a/tools/eclipse/buildConfig/customTargets.xml
+++ /dev/null
@@ -1,195 +0,0 @@
-<!-- ========================================================================= -->
-<!-- Eclipse template file for PDE builds -->
-<!-- template originally obtained from org.eclipse.pde.build/templates/headless-build -->
-<!-- ========================================================================= -->
-<project name="Build specific targets and properties" default="noDefault">
-
-    <!-- ===================================================================== -->
-    <!-- Run a given ${target} on all elements being built -->
-    <!-- Add on <ant> task for each top level element being built. -->
-    <!-- ===================================================================== -->
-    <property name="allElementsFile" value="${builder}/allElements.xml"/>
-    <import file="${allElementsFile}" />
-    <target name="allElements">
-        <antcall target="allElementsDelegator" />
-    </target>
-    
-    <!-- ===================================================================== -->
-    <!-- ===================================================================== -->
-    <target name="getBaseComponents" depends="checkLocalBase" unless="skipBase">
-        <get src="${eclipseBaseURL}" dest="${buildDirectory}/../temp-base.zip" />
-        <unzip dest="${base}" overwrite="true" src="${buildDirectory}/../temp-base.zip" />
-    </target>
-
-    <target name="checkLocalBase">
-        <available file="${base}" property="skipBase" />
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Check out map files from correct repository -->
-    <!-- Replace values for mapsCheckoutTag as desired. -->
-    <!-- ===================================================================== -->
-    <target name="getMapFiles" depends="checkLocalMaps" unless="skipMaps">
-        <property name="mapsCheckoutTag" value="HEAD" />
-        <cvs cvsRoot="${mapsRepo}" package="${mapsRoot}" dest="${buildDirectory}/maps" tag="${mapsCheckoutTag}" />
-    </target>
-
-    <target name="checkLocalMaps">
-        <available property="skipMaps" file="${buildDirectory}/maps" />
-    </target>
-
-    <target name="tagMapFiles" if="tagMaps">
-        <cvs dest="${buildDirectory}/maps/${mapsRoot}" command="tag ${mapsTagTag}" />
-    </target>
-
-    <!-- ===================================================================== -->
-
-    <target name="clean" unless="noclean">
-        <antcall target="allElements">
-            <param name="target" value="cleanElement" />
-        </antcall>
-    </target>
-
-    <target name="gatherLogs">
-        <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" />
-        <antcall target="allElements">
-            <param name="target" value="gatherLogs" />
-        </antcall>
-        <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true">
-            <fileset dir="${buildDirectory}/features">
-                <include name="**/*.log.zip" />
-            </fileset>
-        </unzip>
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before setup -->
-    <!-- ===================================================================== -->
-    <target name="preSetup">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after setup but before starting the build proper -->
-    <!-- ===================================================================== -->
-    <target name="postSetup">
-        <antcall target="getBaseComponents" />
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before fetching the build elements -->
-    <!-- ===================================================================== -->
-    <target name="preFetch">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after fetching the build elements -->
-    <!-- ===================================================================== -->
-    <target name="postFetch">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before generating the build scripts. -->
-    <!-- ===================================================================== -->
-    <target name="preGenerate">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after generating the build scripts. -->
-    <!-- ===================================================================== -->
-    <target name="postGenerate">
-        <antcall target="clean" />
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before running the build.xmls for the elements being built. -->
-    <!-- ===================================================================== -->
-    <target name="preProcess">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after running the build.xmls for the elements being built. -->
-    <!-- ===================================================================== -->
-    <target name="postProcess">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before running assemble. -->
-    <!-- ===================================================================== -->
-    <target name="preAssemble">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after  running assemble. -->
-    <!-- ===================================================================== -->
-    <target name="postAssemble">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do before running package. -->
-    <!-- ===================================================================== -->
-    <target name="prePackage">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after  running package. -->
-    <!-- ===================================================================== -->
-    <target name="postPackage">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do after the build is done. -->
-    <!-- ===================================================================== -->
-    <target name="postBuild">
-        <antcall target="gatherLogs" />
-        <!-- Added this custom target ! -->
-        <antcall target="generateUpdateSite" />
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do to test the build results -->
-    <!-- ===================================================================== -->
-    <target name="test">
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Steps to do to publish the build results -->
-    <!-- ===================================================================== -->
-    <target name="publish">
-        
-    </target>
-
-    <!-- ===================================================================== -->
-    <!-- Default target                                                        -->
-    <!-- ===================================================================== -->
-    <target name="noDefault">
-        <echo message="You must specify a target when invoking this file" />
-    </target>
-    
-    <!-- ===================================================================== -->
-    <!-- Custom target:                                                        -->
-    <!-- Steps to do to generate the update site                               -->
-    <!-- ===================================================================== -->
-    <target name="generateUpdateSite">
-        <echo message="Copying update site source ${updateSiteSource} to destination"/>
-    	
-        <copy file="${updateSiteSource}/site.xml" overwrite="true" todir="${updateSiteDestination}"/>
-        <copy file="${updateSiteSource}/index.html" overwrite="true" todir="${updateSiteDestination}"/>
-        <copy file="${updateSiteSource}/web/site.css" overwrite="true" todir="${updateSiteDestination}/web"/>
-        <copy file="${updateSiteSource}/web/site.xsl" overwrite="true" todir="${updateSiteDestination}/web"/>
-        
-        <!-- replace qualifier version references with build label -->
-        <replace file="${updateSiteDestination}/site.xml" token="qualifier" value="${buildId}"/>
-        
-        <!-- now extract each features zip to update site -->
-        <antcall target="allElements">
-            <param name="genericTargets" value="${builder}/buildUpdateSite.xml"/>
-            <param name="target" value="extractFeature" />
-        </antcall>
-        
-        <chmod perm="755" type="both">
-            <fileset dir="${updateSiteDestination}">
-            </fileset>
-        </chmod>    
-    </target>
-
-</project>
diff --git a/tools/eclipse/changes.txt b/tools/eclipse/changes.txt
deleted file mode 100644
index 5cb8245..0000000
--- a/tools/eclipse/changes.txt
+++ /dev/null
@@ -1,210 +0,0 @@
-0.9.0 (work in progress)
-- Support for SDK with multiple versions of the Android platform and vendor supplied add-ons.
-
-0.8.1:
-
-- Alternate Layout wizard. In the layout editor, the "create" button is now enabled, and allows to easily create alternate versions.
-- Fixed issue with custom themes/styles in the layout editor.
-- Export Wizard: To export an application for release, sign with a non debug key. Accessible from the export menu, from the Android Tools contextual menu, or from the overview page of the manifest editor.
-- New XML File Wizard: To easily create new XML resources file in the /res directory.
-- New checks on launch when attempting to debug on a device.
-- Basic support for drag'n'drop in Graphical layout editor. You can add new items by drag'n'drop from the palette. There's is no support for moving/resizing yet.
-- Undo/redo support in all XML form editors and Graphical layout editor.
-
-0.8.0:
-
-- Fixed issue with using custom classes implementing Parcelable in aidl files. Right click the project and choose Android Tools > Create aidl preprocess file for Parcelable Classes.
-- Added Custom Themes to theme drop down in the layout editor.
-- Customizable debug signing keystore path in preferences
-- Customizable HOME package name.
-
-0.7.1:
-
-- Layout Editor.
-
-0.6.1:
-
-- Fixed install issue when project name contains spaces (requires new emulator image)
-- Fixed setup of the New class wizard in the manifest (when clicking on "name" for a class attribute) in the cases where the class and some of its parent packages were missing.
-- Properly kill the application that is about to be reinstalled.
-- Create missing android folder automatically when building application (caused a signing error)
-- Manifest editor: support for uses-library node
-- Fixed NPE in editors.xml.descriptors.XmlDescriptors.createPreference
-- Fixed assert in MultiEditorPart.setActivePage
-- Fixed "connect to debugger" button in DeviceView. Also fixed support for custom process names.
-
-0.6.0:
-
-- new launch option for activity. Can choose to launch default activity (finds an activity configured to show up in the home screen), or specific activity, or none.
-- normal java resources (non java files placed in package folders) are now properly packaged in the final package, and can be accessed through normal java API such as ClassLoader.getResourceAsStream()
-- launch configuration now has an option to wipe emulator data on launch. This always asks for confirmation.
-- launch configuration now has an option to disable the boot animation. This will let the emulator start faster on older computers.
-- Applications are now signed with a debug key (stored in debug.keystore in ~/.android).
-- Installation of application is now more robust and will notify of installation failure. Also installation is blocking, removing issues where ADT tried to launch the activity before the app was installed.
-- Tree-based resource editor + content assist in XML editor for layout, menu, preferences, values xml files. Work in progress...
-
-
-0.4.0 (adt 0.4.0, ddms 0.3.0, editors 0.2.0, common 0.1.0)
-
-- New AndroidManifest editor.
-- True multiple device support allowing debugging apps on several device at the same time
-- New launch modes for device selection: automatic will launch an emulator if no device are present, automatically target the device if only one exists, and prompt the user if 2+ are connected. Manual mode always prompt the user.
-- New classpath container remove the dependencies on the location of android.jar making it easier to share a project through dsvn, cvs, etc... You should fix your project (right click project, choose Android > Fix Project properties)
-- Fixed a case where pm would fail and would up end outputting the "usage" text, which would in turn confuse the plugin during parsing.
-- Fixed an issue with compiling aidl file when they import project local files.
-
-0.3.4 (adt 0.3.4, ddms 0.2.3, editors 0.1.0)
-
-Internal release only.
-- Enabled device support.
-
-0.3.3 (adt 0.3.3, ddms 0.2.3, editors 0.1.0)
-
-- Support for referenced projects.
-- During launch, display if a package conflict occurs when the new application is pushed onto the device.
-- You can now change the font of the logcat view. Also indentation is now properly displayed.
-- Plugin generated files are now properly marked as derived. This will make Team plugins ignore them.
-
-0.3.2
-
-- XML Highlighting for AndroidManifest.xml (requires WebTools WST plugin)
-- Custom java editor for R.java/Manifest.java to make those files non editable. This is to replace the current locking mechanism which causes issues on Mac OS.
-- Fixed some issue in the "Restart adb" feature in the device view of ddms.
-- Better handling of aidl files and the java files generated from them.
-- Plugin now retries to launch the app on the emulator if it fails due to timing issues.
-- Skin dropdown in the Emulator/Target tabs is now build from the content of the skin directory, to support developer made skins.
-- Emulator control panel. This is a UI on top of the emulator console. it allows you to change the state of the network and gsm connection, and to initiate incoming voice call.
-
-0.3.1
-
-- Fixed issue on winXP/Eclipse 3.2 where errors in the New Project Wizard would not display.
-- Added missing intent definition in the AndroidManifest.xml file created by the New Project Wizard.
-- Fixed possible NPE in the debug action from the Process View
-- Support for Eclipse 3.4
-
-0.2.6 / 0.3.0
-
-- New Project Wizard now makes it easy to open Android sample code
-- Plugin will output a warning if the build id of the device/emulator does not match the sdk build id.
-- Java/Debug/ddms perspective now contains direct menus to open some of the ddms views, and to create a new android project. This will require you to reset your perspectives.
-- Error during builds now put an error marker on the project instead of displaying an (annoying) dialog box.
-- Custom builders now remember their build state when restarting eclipse.
-- Properly parse some aapt warnings and don't abort the build when they happen.
-- Abort launch and prompt the user if the project contains errors.
-- New silent/normal/verbose build output.
-
-0.2.5
-
-- Check compiler compliance level before compilation and abort if different from 1.5
-- Fix Project Properties will fix the project compiler compliance if needed.
-- Fixed an issue with multiple source folders.
-- Added support for new Manifest.java class (it is automatically generated with R.java if the content of the AndroidManifest.xml requires it)
-- Fixed an issue that could result in not packaging code changes.
-- Automatic fix of the Launch Configurations when the java package in the manifest is changed. Also improved Launch Config dialog and error alert for erroneous activity names in the Launch Configuration.
-- Support for external jars that are not under the project root directory.
-- New projects have a default layout.
-- Misc fixes for Windows support.
-
-0.2.4
-
-- fixed large resource corruption issue.
-
-0.2.3
-
-- fixed issue related to the integration of dx.
-- fixed issue related to the package generation that was modified for windows support. 
-
-0.2.2
-
-- Changing the SDK location in the Preferences does not require to restart Eclipse anymore.
-- New SDK-Project sync mode in Android preference pane. Default value set to true. If true, all android projects are automatically sync'ed to the SDK defined in the preferences.
-- Cases where no emulator is running but a dialog still says "An emulator is running..." should be less frequent.
-- Projects do not reference the standard desktop JRE anymore, as android.zip contains the core java library. This will solve the case where using a core class non present on the platform would not generate a compilation error.
-- Changing the package defined in the manifest now deletes the R.java class from its previous location. This will require 1 build after upgrading the plugin, before it works.
-- Project selection in the Launch Config Dialog now only shows Android projects.
-- Launching a debug/run session now checks that the project uses the SDK set in the preferences (This is for the non automatic sync mode).
-- Removed obsolete wallpaper mode in the New Project Creation Wizard.
-- dx (dalvik code conversion tool) now embedded instead of calling the external version.
-- improvements in the parsing of the aapt errors.
-- some fixes for windows support.
-
-0.2.1
-
-- fixed bug in logcat search where invalid regexp would cause a crash
-- minor improvements to the build/launch process.
-
-0.2.0
-
-- Logcat view.
-- File Explorer view.
-- Custom options for emulator. In the Launch configuration dialog you can specify custom command line emulator options. See "emulator -help" for available options.
-- Android Tools > Export Application Package is now implemented.
-- Misc incremental builder fixes.
-- Including static .jar files as library in your project will automatically include them in the final APK. Warning: only the .class content is included.
-
-0.1.10
-
-- res and assets folders now fully refresh before the build, ensuring R.java and packaged resources are always up to date. This can be disabled in the preferences under "Android" if this becomes slow due to too many files.
-
-0.1.9
-
-- New Action in the "Processes" view to debug an application that is already running. The source project for this application MUST be opened in the current workspace.
-- Building the project now force refreshes the res folder. This should help rebuilding the resources when only binary files were changed from outside eclipse.
-- Clean/full builds now compile all aidl files found in the build path (previously only incremental builds would compile them). Also, misc improvements to the incremental builders.
-- Starting a run/debug session now asks to save the files and forces a new build to ensure that the latest package is pushed on the device.
-- Plugin should be less aggressive when waiting for the emulator to be ready. This should translate in fewer failed launches.
-
-0.1.8
-
-- Fixed Debugger issue introduced in 0.1.6
-- Added Log level preferences for DDMS. Look under Android > DDMS > Advanced. Default error level is Error.
-
-0.1.7
-
-- Fixed issue where java warnings wouldn't trigger a new package. Now only errors stop the packaging like it should be.
-- Added more error output in the console during launch.
-
-0.1.6
-
-- New "Android" Console. It receives the error output from external tools such and aidl, dx, and aapt (only when they can't be parsed). Any error force the console to be displayed.
-- The Activity Manager on the device/emulator now outputs some messages in the "Android" console when asked to start an activity. This should help you figure out what is wrong if the application doesn't start.
-- Fixed a case where the .apk file would be updated with broken code. Now if there are java compile error, the .apk is not touched.
-- Added support for manifest with non fully qualified activity java name, yet not starting with a dot.
-- Fixed creation of manifest files (through New Project wizard) to use proper namespace for attributes.
-- Better error reporting for namespace issue in the manifest.
-- "Reset Adb" action from the device view. Use this is the plugin tells you  an emulator is running when there are none.
-- New "ddms" Console which receives the standard output of ddms.
-
-0.1.5
-
-- Support for new activity declaration inside AndroidManifest.xml
-- fixed issue that prevented bin/ to be removed from the buildpath when converting project.
-
-0.1.4
-
-- Changes in the Manifest, now properly trigger a new package of the resources.
-
-0.1.3
-
-- Fixed the "fix project properties" action to remove old framework libraries, just not add new ones.
-
-0.1.2
-
-- aidl builder. The Android Resources PreBuilder now also converts aidl files into java files.
-- New Project wizard now allows to make Wallpaper activities instead of gadgets (which are obsolete.)
-- Launch shortcuts. Right click in the package explorer allow you to launch the application in debug or run mode directly without creating launch configurations.
-- New project wizard and Project conversion now sets up the java doc path for android.zip
-- Package builder now supports custom application assets placed in assets/ (which is now created automatically by the New Project Wizard).
-- New action: Android Tools > Fix Project Properties, in the package explorer contextual menu. This allows you to fix the framework path (and its javadoc path) in case you change the sdk location.
-
-0.1.1
-
-- Fixed project convertor to add the framework library if missing.
-
-0.1.0
-
-- New project wizard.
-- Python script-generated project convertor.
-- Incremental builders.
-- XML validation for resource files.
-- Android Launch Configuration.
diff --git a/tools/eclipse/features/com.android.ide.eclipse.adt/.project b/tools/eclipse/features/com.android.ide.eclipse.adt/.project
deleted file mode 100644
index beca599..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.adt/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>adt-feature</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.pde.FeatureBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.FeatureNature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/features/com.android.ide.eclipse.adt/build.properties b/tools/eclipse/features/com.android.ide.eclipse.adt/build.properties
deleted file mode 100644
index 64f93a9..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.adt/build.properties
+++ /dev/null
@@ -1 +0,0 @@
-bin.includes = feature.xml
diff --git a/tools/eclipse/features/com.android.ide.eclipse.adt/feature.xml b/tools/eclipse/features/com.android.ide.eclipse.adt/feature.xml
deleted file mode 100644
index b9e2c7f..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.adt/feature.xml
+++ /dev/null
@@ -1,146 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
-      id="com.android.ide.eclipse.adt"
-      label="Android Development Tools"
-      version="0.9.0.qualifier"
-      provider-name="The Android Open Source Project"
-      plugin="com.android.ide.eclipse.adt">
-
-   <description>
-      Android Developer Tools.
-   </description>
-
-   <copyright>
-      Copyright (C) 2007 The Android Open Source Project
-   </copyright>
-
-   <license url="http://www.eclipse.org/org/documents/epl-v10.php">
-      Eclipse Public License - v 1.0
-
-THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT&apos;S ACCEPTANCE OF THIS AGREEMENT.
-
-1. DEFINITIONS
-
-&quot;Contribution&quot; means:
-
-a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and
-
-b) in the case of each subsequent Contributor:
-
-i) changes to the Program, and
-
-ii) additions to the Program;
-
-where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution &apos;originates&apos; from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor&apos;s behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program.
-
-&quot;Contributor&quot; means any person or entity that distributes the Program.
-
-&quot;Licensed Patents&quot; mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program.
-
-&quot;Program&quot; means the Contributions distributed in accordance with this Agreement.
-
-&quot;Recipient&quot; means anyone who receives the Program under this Agreement, including all Contributors.
-
-2. GRANT OF RIGHTS
-
-a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form.
-
-b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder.
-
-c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient&apos;s responsibility to acquire that license before distributing the Program.
-
-d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement.
-
-3. REQUIREMENTS
-
-A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that:
-
-a) it complies with the terms and conditions of this Agreement; and
-
-b) its license agreement:
-
-i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose;
-
-ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits;
-
-iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and
-
-iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange.
-
-When the Program is made available in source code form:
-
-a) it must be made available under this Agreement; and
-
-b) a copy of this Agreement must be included with each copy of the Program.
-
-Contributors may not remove or alter any copyright notices contained within the Program.
-
-Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution.
-
-4. COMMERCIAL DISTRIBUTION
-
-Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor (&quot;Commercial Contributor&quot;) hereby agrees to defend and indemnify every other Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense.
-
-For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor&apos;s responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages.
-
-5. NO WARRANTY
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations.
-
-6. DISCLAIMER OF LIABILITY
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
-
-7. GENERAL
-
-If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable.
-
-If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient&apos;s patent(s), then such Recipient&apos;s rights granted under Section 2(b) shall terminate as of the date such litigation is filed.
-
-All Recipient&apos;s rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient&apos;s rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient&apos;s obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive.
-
-Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved.
-
-This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation.
-   </license>
-
-   <url>
-      <update label="Android Update Site" url="https://dl-ssl.google.com/android/eclipse/"/>
-   </url>
-
-   <requires>
-      <import plugin="com.android.ide.eclipse.ddms"/>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.core.resources"/>
-      <import plugin="org.eclipse.debug.core"/>
-      <import plugin="org.eclipse.debug.ui"/>
-      <import plugin="org.eclipse.jdt"/>
-      <import plugin="org.eclipse.ant.core"/>
-      <import plugin="org.eclipse.jdt.core"/>
-      <import plugin="org.eclipse.jdt.ui"/>
-      <import plugin="org.eclipse.jdt.launching"/>
-      <import plugin="org.eclipse.jface.text"/>
-      <import plugin="org.eclipse.ui.editors"/>
-      <import plugin="org.eclipse.ui.workbench.texteditor"/>
-      <import plugin="org.eclipse.ui.console"/>
-      <import plugin="org.eclipse.core.filesystem"/>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.ui.ide"/>
-      <import plugin="org.eclipse.ui.forms"/>
-      <import plugin="org.eclipse.gef"/>
-      <import plugin="org.eclipse.ui.browser"/>
-      <import plugin="org.eclipse.ui.views"/>
-      <import plugin="org.eclipse.wst.sse.core"/>
-      <import plugin="org.eclipse.wst.sse.ui"/>
-      <import plugin="org.eclipse.wst.xml.core"/>
-      <import plugin="org.eclipse.wst.xml.ui"/>
-   </requires>
-
-   <plugin
-         id="com.android.ide.eclipse.adt"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-</feature>
diff --git a/tools/eclipse/features/com.android.ide.eclipse.ddms/.project b/tools/eclipse/features/com.android.ide.eclipse.ddms/.project
deleted file mode 100644
index f80ff60..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.ddms/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ddms-feature</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.pde.FeatureBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.FeatureNature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/features/com.android.ide.eclipse.ddms/build.properties b/tools/eclipse/features/com.android.ide.eclipse.ddms/build.properties
deleted file mode 100644
index 64f93a9..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.ddms/build.properties
+++ /dev/null
@@ -1 +0,0 @@
-bin.includes = feature.xml
diff --git a/tools/eclipse/features/com.android.ide.eclipse.ddms/feature.xml b/tools/eclipse/features/com.android.ide.eclipse.ddms/feature.xml
deleted file mode 100644
index dfdf985..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.ddms/feature.xml
+++ /dev/null
@@ -1,237 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
-      id="com.android.ide.eclipse.ddms"
-      label="Android DDMS"
-      version="0.9.0.qualifier"
-      provider-name="The Android Open Source Project">
-
-   <description>
-      Android Dalvik Debug Monitor Service
-   </description>
-
-   <copyright>
-      Copyright (C) 2007 The Android Open Source Project
-   </copyright>
-
-   <license url="http://www.apache.org/licenses/LICENSE-2.0">
-      Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      &quot;License&quot; shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      &quot;Licensor&quot; shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      &quot;Legal Entity&quot; shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      &quot;control&quot; means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      &quot;You&quot; (or &quot;Your&quot;) shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      &quot;Source&quot; form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      &quot;Object&quot; form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      &quot;Work&quot; shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      &quot;Derivative Works&quot; shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      &quot;Contribution&quot; shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, &quot;submitted&quot;
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as &quot;Not a Contribution.&quot;
-
-      &quot;Contributor&quot; shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a &quot;NOTICE&quot; text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an &quot;AS IS&quot; BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets &quot;[]&quot;
-      replaced with your own identifying information. (Don&apos;t include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same &quot;printed page&quot; as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright [yyyy] [name of copyright owner]
-
-   Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an &quot;AS IS&quot; BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-   </license>
-
-   <url>
-      <update label="Android Update Site" url="https://dl-ssl.google.com/android/eclipse/"/>
-   </url>
-
-   <requires>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.ui.console"/>
-   </requires>
-
-   <plugin
-         id="com.android.ide.eclipse.ddms"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-</feature>
diff --git a/tools/eclipse/features/com.android.ide.eclipse.tests/.project b/tools/eclipse/features/com.android.ide.eclipse.tests/.project
deleted file mode 100644
index 6a16276..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.tests/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>adt-tests-feature</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.pde.FeatureBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.FeatureNature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/features/com.android.ide.eclipse.tests/build.properties b/tools/eclipse/features/com.android.ide.eclipse.tests/build.properties
deleted file mode 100644
index 64f93a9..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.tests/build.properties
+++ /dev/null
@@ -1 +0,0 @@
-bin.includes = feature.xml
diff --git a/tools/eclipse/features/com.android.ide.eclipse.tests/feature.xml b/tools/eclipse/features/com.android.ide.eclipse.tests/feature.xml
deleted file mode 100644
index 2a3a74f..0000000
--- a/tools/eclipse/features/com.android.ide.eclipse.tests/feature.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
-      id="com.android.ide.eclipse.tests"
-      label="ADT Tests"
-      version="0.9.0.qualifier"
-      provider-name="The Android Open Source Project">
-
-   <copyright>
-      Copyright (C) 2007 The Android Open Source Project
-   </copyright>
-
-   <requires>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.core.resources"/>
-      <import plugin="com.android.ide.eclipse.adt"/>
-      <import plugin="org.junit"/>
-      <import plugin="org.eclipse.jdt.core"/>
-      <import plugin="org.eclipse.jdt.launching"/>
-      <import plugin="org.eclipse.ui.views"/>
-   </requires>
-
-   <plugin
-         id="com.android.ide.eclipse.tests"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-</feature>
diff --git a/tools/eclipse/plugins/README.txt b/tools/eclipse/plugins/README.txt
deleted file mode 100644
index 184d731..0000000
--- a/tools/eclipse/plugins/README.txt
+++ /dev/null
@@ -1,114 +0,0 @@
-Compiling and deploying the Android Development Toolkit (ADT) feature.
-
-The ADT feature is composed of four plugins:
-- com.android.ide.eclipse.adt:
-    The ADT plugin, which provides support for compiling and debugging android
-    applications.
-- com.android.ide.eclipse.common:
-    A common plugin providing utility services to the other plugins.
-- com.android.ide.eclipse.editors:
-    A plugin providing optional XML editors.
-- com.android.ide.eclipse.ddms:
-    A plugin version of the tool DDMS
-
-Because the DDMS plugin source code is not yet released, compiling the
-ADT/Common/Editors plugins requires to install the DDMS plugin in eclipse.
-
-Basic requirements:
-- Eclipse 3.3 or 3.4 with JDT and PDE.
-- DDMS plugin installed and running.
-
-
---------------------------
-1- Install the DDMS plugin
---------------------------
-
-The easiest way to setup the DDMS plugin in your Eclipse environment is to
-install the ADT features (see SDK documentation for details) and then remove
-the following features and plugins:
-
-- <eclipse-directory>/features/com.android.ide.eclipse.adt_x.x.x.jar
-- <eclipse-directory>/plugins/com.android.ide.eclipse.adt_x.x.x.jar
-- <eclipse-directory>/plugins/com.android.ide.eclipse.common_x.x.x.jar
-- <eclipse-directory>/plugins/com.android.ide.eclipse.editors_x.x.x.jar
-
-This will leave you with only the DDMS plugin installed in your Eclipse
-distribution.
-
-
--------------------------------------
-2- Setting up the ADT/Common project
--------------------------------------
-
-- Download the ADT/Common/Editors source.
-
-- From the SDK, copy the following jars:
-   * androidprefs.jar    => com.android.ide.eclipse.adt folder.
-   * jarutils.jar        => com.android.ide.eclipse.adt folder.
-   * ping.jar            => com.android.ide.eclipse.common folder.
-   * androidprefs.jar    => com.android.ide.eclipse.common folder.
-
-- Create a java project from existing source for both the ADT plugin and the
-  common plugin.
-
-- In the Package Explorer, right click the projects and choose
-     PDE Tools > Convert Projects to Plug-in Project...
-
-- Select your projects in the dialog box and click OK.
-
-- In the Package Explorer, for ADT and common, right click the jar files mentioned above
-  and choose Build Path > Add to Build Path
-
-At this point the projects will compile.
-
-To launch the projects, open the Run/Debug Dialog and create an "Eclipse
-Application" launch configuration.
-
-Additionnaly, another feature containing the Android Editors Plugin
-(com.android.ide.eclipse.editors) is available.
-
-- Make sure the common project is present in your workspace as the Editors
-  plugin depends on this plugin. Alternatively, you can have the offical ADT
-  feature installed in your Eclipse distribution.
-- Create a java project from existing source for the Editors project.
-- In the Package Explorer, right click the project and choose
-     PDE Tools > Convert Projects to Plug-in Project...
-- Select your project in the dialog box and click OK.
-
-Create an "Eclipse Application" launch configuration to test the plugin.
-
--------------------------------------
-3- Setting up the Editors project
--------------------------------------
-
-The "editors" plugin is optional. You can use ADT to develop Android
-applications without the XML editor support. When this plugin is present, it
-offers several customized form-based XML editors and one graphical layout
-editor.
-
-At the time of this release (Android 0.9 SDK), some of the supporting libraries
-still need some cleanup and are currently only provided as JAR files.
-
-- Download the ADT/Common/Editors source.
-
-- From the source archives, copy the following jars:
-   * ninepatch.jar       => com.android.ide.eclipse.editors folder.
-   * layoutlib_utils.jar => com.android.ide.eclipse.editors folder.
-   * layoutlib_api.jar   => com.android.ide.eclipse.editors folder.
-
-- From http://kxml.sourceforge.net/ download:
-   * kXML2-2.3.0.jar     => com.android.ide.eclipse.editors folder.
-
-- Create a java project from existing source for both the editors plugin.
-
-- In the Package Explorer, right click the project and choose
-     PDE Tools > Convert Projects to Plug-in Project...
-
-- Select your project in the dialog box and click OK.
-
-- In the Package Explorer for editors, right click the jar files mentioned
-  above and choose Build Path > Add to Build Path
-
-To launch the projects, reuse the "Eclipse Application" launch configuration
-created for ADT.
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/.classpath b/tools/eclipse/plugins/com.android.ide.eclipse.adt/.classpath
deleted file mode 100644
index c3c8c10..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/.classpath
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry excluding="Makefile|resources/" kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-	<classpathentry kind="lib" path="jarutils.jar"/>
-	<classpathentry kind="lib" path="androidprefs.jar"/>
-	<classpathentry kind="lib" path="sdkstats.jar"/>
-	<classpathentry kind="lib" path="kxml2-2.3.0.jar"/>
-	<classpathentry kind="lib" path="layoutlib_api.jar"/>
-	<classpathentry kind="lib" path="layoutlib_utils.jar"/>
-	<classpathentry kind="lib" path="ninepatch.jar"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkUiLib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/.project b/tools/eclipse/plugins/com.android.ide.eclipse.adt/.project
deleted file mode 100644
index c7b1ad4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/.project
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>adt</name>
-	<comment></comment>
-	<projects>
-		<project>SdkLib</project>
-		<project>SdkUiLib</project>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.ManifestBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.SchemaBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.PluginNature</nature>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/META-INF/MANIFEST.MF b/tools/eclipse/plugins/com.android.ide.eclipse.adt/META-INF/MANIFEST.MF
deleted file mode 100644
index a464d5c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,79 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Android Development Toolkit
-Bundle-SymbolicName: com.android.ide.eclipse.adt;singleton:=true
-Bundle-Version: 0.9.0.qualifier
-Bundle-ClassPath: .,
- jarutils.jar,
- androidprefs.jar,
- sdkstats.jar,
- kxml2-2.3.0.jar,
- layoutlib_api.jar,
- ninepatch.jar,
- layoutlib_utils.jar,
- sdklib.jar,
- sdkuilib.jar
-Bundle-Activator: com.android.ide.eclipse.adt.AdtPlugin
-Bundle-Vendor: The Android Open Source Project
-Require-Bundle: com.android.ide.eclipse.ddms,
- org.eclipse.core.runtime,
- org.eclipse.core.resources,
- org.eclipse.debug.core,
- org.eclipse.debug.ui,
- org.eclipse.jdt,
- org.eclipse.ant.core,
- org.eclipse.jdt.core,
- org.eclipse.jdt.ui,
- org.eclipse.jdt.launching,
- org.eclipse.jface.text,
- org.eclipse.ui.editors,
- org.eclipse.ui.workbench.texteditor,
- org.eclipse.ui.console,
- org.eclipse.core.filesystem,
- org.eclipse.ui,
- org.eclipse.ui.ide,
- org.eclipse.ui.forms,
- org.eclipse.gef,
- org.eclipse.ui.browser,
- org.eclipse.ui.views,
- org.eclipse.wst.sse.core,
- org.eclipse.wst.sse.ui,
- org.eclipse.wst.xml.core,
- org.eclipse.wst.xml.ui
-Eclipse-LazyStart: true
-Export-Package: com.android.ide.eclipse.adt,
- com.android.ide.eclipse.adt.build;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.adt.project;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.adt.project.internal;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.adt.sdk;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.adt.wizards.newproject;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.common,
- com.android.ide.eclipse.common.project,
- com.android.ide.eclipse.common.resources,
- com.android.ide.eclipse.editors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.descriptors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.layout;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.layout.descriptors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.layout.parts;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.layout.uimodel;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.manifest;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.manifest.descriptors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.manifest.model;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.manifest.pages;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.menu;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.menu.descriptors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.configurations;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.descriptors;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.explorer;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.manager;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.manager.files;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.resources.uimodel;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.ui;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.ui.tree;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.uimodel;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.wizards;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.xml;x-friends:="com.android.ide.eclipse.tests",
- com.android.ide.eclipse.editors.xml.descriptors;x-friends:="com.android.ide.eclipse.tests"
-
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/MODULE_LICENSE_EPL b/tools/eclipse/plugins/com.android.ide.eclipse.adt/MODULE_LICENSE_EPL
deleted file mode 100644
index e69de29..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/MODULE_LICENSE_EPL
+++ /dev/null
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/NOTICE b/tools/eclipse/plugins/com.android.ide.eclipse.adt/NOTICE
deleted file mode 100644
index 49c101d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/NOTICE
+++ /dev/null
@@ -1,224 +0,0 @@
-*Eclipse Public License - v 1.0*
-
-THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE
-PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF
-THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT.
-
-*1. DEFINITIONS*
-
-"Contribution" means:
-
-a) in the case of the initial Contributor, the initial code and
-documentation distributed under this Agreement, and
-b) in the case of each subsequent Contributor:
-
-i) changes to the Program, and
-
-ii) additions to the Program;
-
-where such changes and/or additions to the Program originate from and
-are distributed by that particular Contributor. A Contribution
-'originates' from a Contributor if it was added to the Program by such
-Contributor itself or anyone acting on such Contributor's behalf.
-Contributions do not include additions to the Program which: (i) are
-separate modules of software distributed in conjunction with the Program
-under their own license agreement, and (ii) are not derivative works of
-the Program.
-
-"Contributor" means any person or entity that distributes the Program.
-
-"Licensed Patents " mean patent claims licensable by a Contributor which
-are necessarily infringed by the use or sale of its Contribution alone
-or when combined with the Program.
-
-"Program" means the Contributions distributed in accordance with this
-Agreement.
-
-"Recipient" means anyone who receives the Program under this Agreement,
-including all Contributors.
-
-*2. GRANT OF RIGHTS*
-
-a) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free copyright
-license to reproduce, prepare derivative works of, publicly display,
-publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and
-object code form.
-
-b) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free patent license
-under Licensed Patents to make, use, sell, offer to sell, import and
-otherwise transfer the Contribution of such Contributor, if any, in
-source code and object code form. This patent license shall apply to the
-combination of the Contribution and the Program if, at the time the
-Contribution is added by the Contributor, such addition of the
-Contribution causes such combination to be covered by the Licensed
-Patents. The patent license shall not apply to any other combinations
-which include the Contribution. No hardware per se is licensed hereunder.
-
-c) Recipient understands that although each Contributor grants the
-licenses to its Contributions set forth herein, no assurances are
-provided by any Contributor that the Program does not infringe the
-patent or other intellectual property rights of any other entity. Each
-Contributor disclaims any liability to Recipient for claims brought by
-any other entity based on infringement of intellectual property rights
-or otherwise. As a condition to exercising the rights and licenses
-granted hereunder, each Recipient hereby assumes sole responsibility to
-secure any other intellectual property rights needed, if any. For
-example, if a third party patent license is required to allow Recipient
-to distribute the Program, it is Recipient's responsibility to acquire
-that license before distributing the Program.
-
-d) Each Contributor represents that to its knowledge it has sufficient
-copyright rights in its Contribution, if any, to grant the copyright
-license set forth in this Agreement.
-
-*3. REQUIREMENTS*
-
-A Contributor may choose to distribute the Program in object code form
-under its own license agreement, provided that:
-
-a) it complies with the terms and conditions of this Agreement; and
-
-b) its license agreement:
-
-i) effectively disclaims on behalf of all Contributors all warranties
-and conditions, express and implied, including warranties or conditions
-of title and non-infringement, and implied warranties or conditions of
-merchantability and fitness for a particular purpose;
-
-ii) effectively excludes on behalf of all Contributors all liability for
-damages, including direct, indirect, special, incidental and
-consequential damages, such as lost profits;
-
-iii) states that any provisions which differ from this Agreement are
-offered by that Contributor alone and not by any other party; and
-
-iv) states that source code for the Program is available from such
-Contributor, and informs licensees how to obtain it in a reasonable
-manner on or through a medium customarily used for software exchange.
-
-When the Program is made available in source code form:
-
-a) it must be made available under this Agreement; and
-
-b) a copy of this Agreement must be included with each copy of the Program.
-
-Contributors may not remove or alter any copyright notices contained
-within the Program.
-
-Each Contributor must identify itself as the originator of its
-Contribution, if any, in a manner that reasonably allows subsequent
-Recipients to identify the originator of the Contribution.
-
-*4. COMMERCIAL DISTRIBUTION*
-
-Commercial distributors of software may accept certain responsibilities
-with respect to end users, business partners and the like. While this
-license is intended to facilitate the commercial use of the Program, the
-Contributor who includes the Program in a commercial product offering
-should do so in a manner which does not create potential liability for
-other Contributors. Therefore, if a Contributor includes the Program in
-a commercial product offering, such Contributor ("Commercial
-Contributor") hereby agrees to defend and indemnify every other
-Contributor ("Indemnified Contributor") against any losses, damages and
-costs (collectively "Losses") arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified
-Contributor to the extent caused by the acts or omissions of such
-Commercial Contributor in connection with its distribution of the
-Program in a commercial product offering. The obligations in this
-section do not apply to any claims or Losses relating to any actual or
-alleged intellectual property infringement. In order to qualify, an
-Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial
-Contributor to control, and cooperate with the Commercial Contributor
-in, the defense and any related settlement negotiations. The Indemnified
-Contributor may participate in any such claim at its own expense.
-
-For example, a Contributor might include the Program in a commercial
-product offering, Product X. That Contributor is then a Commercial
-Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance
-claims and warranties are such Commercial Contributor's responsibility
-alone. Under this section, the Commercial Contributor would have to
-defend claims against the other Contributors related to those
-performance claims and warranties, and if a court requires any other
-Contributor to pay any damages as a result, the Commercial Contributor
-must pay those damages.
-
-*5. NO WARRANTY*
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED
-ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
-EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES
-OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR
-A PARTICULAR PURPOSE. Each Recipient is solely responsible for
-determining the appropriateness of using and distributing the Program
-and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program
-errors, compliance with applicable laws, damage to or loss of data,
-programs or equipment, and unavailability or interruption of operations.
-
-*6. DISCLAIMER OF LIABILITY*
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR
-ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT,
-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING
-WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF
-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR
-DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED
-HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
-
-*7. GENERAL*
-
-If any provision of this Agreement is invalid or unenforceable under
-applicable law, it shall not affect the validity or enforceability of
-the remainder of the terms of this Agreement, and without further action
-by the parties hereto, such provision shall be reformed to the minimum
-extent necessary to make such provision valid and enforceable.
-
-If Recipient institutes patent litigation against any entity (including
-a cross-claim or counterclaim in a lawsuit) alleging that the Program
-itself (excluding combinations of the Program with other software or
-hardware) infringes such Recipient's patent(s), then such Recipient's
-rights granted under Section 2(b) shall terminate as of the date such
-litigation is filed.
-
-All Recipient's rights under this Agreement shall terminate if it fails
-to comply with any of the material terms or conditions of this Agreement
-and does not cure such failure in a reasonable period of time after
-becoming aware of such noncompliance. If all Recipient's rights under
-this Agreement terminate, Recipient agrees to cease use and distribution
-of the Program as soon as reasonably practicable. However, Recipient's
-obligations under this Agreement and any licenses granted by Recipient
-relating to the Program shall continue and survive.
-
-Everyone is permitted to copy and distribute copies of this Agreement,
-but in order to avoid inconsistency the Agreement is copyrighted and may
-only be modified in the following manner. The Agreement Steward reserves
-the right to publish new versions (including revisions) of this
-Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the
-initial Agreement Steward. The Eclipse Foundation may assign the
-responsibility to serve as the Agreement Steward to a suitable separate
-entity. Each new version of the Agreement will be given a distinguishing
-version number. The Program (including Contributions) may always be
-distributed subject to the version of the Agreement under which it was
-received. In addition, after a new version of the Agreement is
-published, Contributor may elect to distribute the Program (including
-its Contributions) under the new version. Except as expressly stated in
-Sections 2(a) and 2(b) above, Recipient receives no rights or licenses
-to the intellectual property of any Contributor under this Agreement,
-whether expressly, by implication, estoppel or otherwise. All rights in
-the Program not expressly granted under this Agreement are reserved.
-
-This Agreement is governed by the laws of the State of New York and the
-intellectual property laws of the United States of America. No party to
-this Agreement will bring a legal action under this Agreement more than
-one year after the cause of action arose. Each party waives its rights
-to a jury trial in any resulting litigation.
-
- 
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/about.ini b/tools/eclipse/plugins/com.android.ide.eclipse.adt/about.ini
deleted file mode 100644
index fddaef0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/about.ini
+++ /dev/null
@@ -1 +0,0 @@
-featureImage=icons/android_32X32.jpg
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/build.properties b/tools/eclipse/plugins/com.android.ide.eclipse.adt/build.properties
deleted file mode 100644
index c7eb749..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/build.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-bin.includes = plugin.xml,\
-               META-INF/,\
-               icons/,\
-               .,\
-               templates/,\
-               about.ini,\
-               jarutils.jar,\
-               androidprefs.jar,\
-               sdkstats.jar,\
-               kxml2-2.3.0.jar,\
-               layoutlib_api.jar,\
-               layoutlib_utils.jar,\
-               ninepatch.jar,\
-               sdklib.jar,\
-               sdkuilib.jar
-source.. = src/
-output.. = bin/
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/add.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/add.png
deleted file mode 100644
index eefc2ca..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/add.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android.png
deleted file mode 100644
index 3779d4d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_32X32.jpg b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_32X32.jpg
deleted file mode 100644
index 823670b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_32X32.jpg
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_large.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_large.png
deleted file mode 100644
index 64e3601..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_large.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_project.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_project.png
deleted file mode 100644
index 5334568..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/android_project.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/az_sort.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/az_sort.png
deleted file mode 100644
index 5d92f76..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/az_sort.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/delete.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/delete.png
deleted file mode 100644
index db5fab8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/delete.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dimension.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dimension.png
deleted file mode 100644
index 10057c8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dimension.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/down.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/down.png
deleted file mode 100644
index 36cd223..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/down.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dpi.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dpi.png
deleted file mode 100644
index fae5e96..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/dpi.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/error.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/error.png
deleted file mode 100644
index 1eecf2c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/error.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/keyboard.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/keyboard.png
deleted file mode 100644
index 7911a85..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/keyboard.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/language.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/language.png
deleted file mode 100644
index a727dd5..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/language.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mainLaunchTab.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mainLaunchTab.png
deleted file mode 100644
index 2540fbb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mainLaunchTab.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/match.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/match.png
deleted file mode 100644
index 7e939c2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/match.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mcc.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mcc.png
deleted file mode 100644
index 4dc95d7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mcc.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mnc.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mnc.png
deleted file mode 100644
index aefffe4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/mnc.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/navpad.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/navpad.png
deleted file mode 100644
index c2bb79a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/navpad.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/orientation.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/orientation.png
deleted file mode 100644
index 423c3cd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/orientation.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/region.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/region.png
deleted file mode 100644
index 9608cd6..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/region.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/text_input.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/text_input.png
deleted file mode 100644
index b4ddc87..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/text_input.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/touch.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/touch.png
deleted file mode 100644
index 6536576..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/touch.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/up.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/up.png
deleted file mode 100644
index 35b9a46..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/up.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/warning.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/warning.png
deleted file mode 100644
index ca3b6ed..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/icons/warning.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/plugin.xml b/tools/eclipse/plugins/com.android.ide.eclipse.adt/plugin.xml
deleted file mode 100644
index f7c366d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/plugin.xml
+++ /dev/null
@@ -1,467 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
-   <extension
-         id="com.android.ide.eclipse.common.xmlProblem"
-         name="Android XML Format Problem"
-         point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <super type="org.eclipse.core.resources.textmarker"/>
-      <persistent value="true"/>
-   </extension>
-   <extension
-         id="com.android.ide.eclipse.common.aaptProblem"
-         name="Android AAPT Problem"
-         point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <super type="org.eclipse.core.resources.textmarker"/>
-      <persistent value="true"/>
-   </extension>
-   <extension
-         id="com.android.ide.eclipse.common.aidlProblem"
-         name="Android AIDL Problem"
-         point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <super type="org.eclipse.core.resources.textmarker"/>
-      <persistent value="true"/>
-   </extension>
-   <extension
-        id="com.android.ide.eclipse.common.androidProblem"
-        name="Android XML Content Problem"
-        point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <super type="org.eclipse.core.resources.textmarker"/>
-      <persistent value="true"/>
-   </extension>
-   <extension
-         id="ResourceManagerBuilder"
-         name="Android Resource Manager"
-         point="org.eclipse.core.resources.builders">
-      <builder
-            hasNature="true">
-         <run class="com.android.ide.eclipse.adt.build.ResourceManagerBuilder"/>
-      </builder>
-   </extension>
-   <extension
-         id="PreCompilerBuilder"
-         name="Android Pre Compiler"
-         point="org.eclipse.core.resources.builders">
-      <builder
-            hasNature="true">
-         <run class="com.android.ide.eclipse.adt.build.PreCompilerBuilder"/>
-      </builder>
-   </extension>
-   <extension
-         id="ApkBuilder"
-         name="Android Package Builder"
-         point="org.eclipse.core.resources.builders">
-      <builder
-            hasNature="true">
-         <run class="com.android.ide.eclipse.adt.build.ApkBuilder"/>
-      </builder>
-   </extension>
-   <extension
-         id="AndroidNature"
-         name="AndroidNature"
-         point="org.eclipse.core.resources.natures">
-      <runtime>
-         <run class="com.android.ide.eclipse.adt.project.AndroidNature"/>
-      </runtime>
-      <builder id="com.android.ide.eclipse.adt.ResourceManagerBuilder"/>
-      <builder id="com.android.ide.eclipse.adt.PreCompilerBuilder"/>
-      <builder id="com.android.ide.eclipse.adt.ApkBuilder"/>
-   </extension>
-   <extension
-         point="org.eclipse.ui.newWizards">
-      <category
-            id="com.android.ide.eclipse.wizards.category"
-            name="Android"/>
-      <wizard
-            canFinishEarly="false"
-            category="com.android.ide.eclipse.wizards.category"
-            class="com.android.ide.eclipse.adt.wizards.newproject.NewProjectWizard"
-            finalPerspective="org.eclipse.jdt.ui.JavaPerspective"
-            hasPages="true"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.adt.project.NewProjectWizard"
-            name="Android Project"
-            preferredPerspectives="org.eclipse.jdt.ui.JavaPerspective"
-            project="true"/>
-      <wizard
-            canFinishEarly="false"
-            category="com.android.ide.eclipse.wizards.category"
-            class="com.android.ide.eclipse.editors.wizards.NewXmlFileWizard"
-            finalPerspective="org.eclipse.jdt.ui.JavaPerspective"
-            hasPages="true"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.wizards.NewXmlFileWizard"
-            name="Android XML File"
-            preferredPerspectives="org.eclipse.jdt.ui.JavaPerspective"
-            project="false">
-      </wizard>
-   </extension>
-   <extension
-         point="org.eclipse.debug.core.launchConfigurationTypes">
-      <launchConfigurationType
-            delegate="com.android.ide.eclipse.adt.debug.launching.LaunchConfigDelegate"
-            delegateDescription="The Android Application Launcher supports running and debugging remote Android applications on devices or emulators."
-            delegateName="Android Launcher"
-            id="com.android.ide.eclipse.adt.debug.LaunchConfigType"
-            modes="debug, run"
-            name="Android Application"
-            public="true"
-            sourceLocatorId="org.eclipse.jdt.launching.sourceLocator.JavaSourceLookupDirector"
-            sourcePathComputerId="org.eclipse.jdt.launching.sourceLookup.javaSourcePathComputer">
-      </launchConfigurationType>
-   </extension>
-   <extension
-         point="org.eclipse.debug.ui.launchConfigurationTypeImages">
-      <launchConfigurationTypeImage
-            configTypeID="com.android.ide.eclipse.adt.debug.LaunchConfigType"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.adt.debug.LaunchConfigTypeImage"/>
-   </extension>
-   <extension
-         point="org.eclipse.debug.ui.launchConfigurationTabGroups">
-      <launchConfigurationTabGroup
-            class="com.android.ide.eclipse.adt.debug.ui.LaunchConfigTabGroup"
-            description="Android Application"
-            id="com.android.ide.eclipse.adt.debug.LaunchConfigTabGroup"
-            type="com.android.ide.eclipse.adt.debug.LaunchConfigType"/>
-   </extension>
-   <extension
-         point="org.eclipse.debug.ui.launchShortcuts">
-      <shortcut
-            category="com.android.ide.eclipse.adt.debug.LaunchConfigType"
-            class="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut"
-            label="Android Application"
-            modes="debug, run">
-        <contextualLaunch>
-           <enablement>
-             <with variable="selection">
-               <count value="1"/>
-               <iterate>
-                  <and>
-                     <test property="org.eclipse.jdt.launching.isContainer"/>
-                     <test property="org.eclipse.jdt.launching.hasProjectNature" args="com.android.ide.eclipse.adt.AndroidNature"/>
-                  </and>
-               </iterate>
-               </with>
-           </enablement>
-         </contextualLaunch>
-         <perspective id="org.eclipse.jdt.ui.JavaPerspective"/>
-         <perspective id="org.eclipse.debug.ui.DebugPerspective"/>
-         <description
-               description="Runs an Android Application"
-               mode="run">
-         </description>
-         <description
-               description="Debugs an Android Application"
-               mode="debug">
-         </description>
-      </shortcut>
-   </extension>
-   <extension
-         point="org.eclipse.ui.popupMenus">
-      <objectContribution
-            id="com.android.ide.eclipse.adt.contribution1"
-            nameFilter="*"
-            objectClass="org.eclipse.core.resources.IProject"
-            adaptable="true">
-         <menu
-               id="com.android.ide.eclipse.adt.AndroidTools"
-               label="Android Tools"
-               path="additions">
-            <separator name="group1"/>
-         </menu>
-         <visibility>
-            <not>
-            <or>
-            <objectState
-                name="projectNature"
-                value="com.android.ide.eclipse.adt.AndroidNature"/>
-            <objectState
-                name="open"
-                value="false"/>
-            </or>
-            </not>
-         </visibility>
-         <action
-               class="com.android.ide.eclipse.adt.project.ConvertToAndroidAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.ConvertToAndroidAction"
-               label="Convert To Android Project"
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group1"/>
-      </objectContribution>
-      <objectContribution
-            id="com.android.ide.eclipse.adt.contribution2"
-            nameFilter="*"
-            objectClass="org.eclipse.core.resources.IProject"
-            adaptable="true">
-         <menu
-               id="com.android.ide.eclipse.adt.AndroidTools"
-               label="Android Tools"
-               path="additions">
-            <separator name="group1"/>
-            <separator name="group2"/>
-         </menu>
-         <filter
-               name="projectNature"
-               value="com.android.ide.eclipse.adt.AndroidNature">
-         </filter>
-         <action
-               class="com.android.ide.eclipse.adt.project.CreateAidlImportAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.project.CreateAidlImportAction"
-               label="Create Aidl preprocess file for Parcelable classes"
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group1"/>
-         <action
-               class="com.android.ide.eclipse.adt.project.NewXmlFileWizardAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.project.NewXmlFileWizardAction"
-               label="New Resource File..."
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group1">
-         </action>
-         <action
-               class="com.android.ide.eclipse.adt.project.ExportAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.project.ExportAction"
-               label="Export Unsigned Application Package..."
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group2"/>
-         <action
-               class="com.android.ide.eclipse.adt.project.ExportWizardAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.project.ExportWizardAction"
-               label="Export Signed Application Package..."
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group2"/>
-         <action
-               class="com.android.ide.eclipse.adt.project.FixProjectAction"
-               enablesFor="1"
-               id="com.android.ide.eclipse.adt.project.FixProjectAction"
-               label="Fix Project Properties"
-               menubarPath="com.android.ide.eclipse.adt.AndroidTools/group3"/>
-      </objectContribution>
-   </extension>
-   <extension
-         point="org.eclipse.ui.preferencePages">
-      <page
-            class="com.android.ide.eclipse.adt.preferences.AndroidPreferencePage"
-            id="com.android.ide.eclipse.preferences.main"
-            name="Android"/>
-      <page
-            category="com.android.ide.eclipse.preferences.main"
-            class="com.android.ide.eclipse.adt.preferences.BuildPreferencePage"
-            id="com.android.ide.eclipse.adt.preferences.BuildPreferencePage"
-            name="Build"/>
-      <page
-            category="com.android.ide.eclipse.preferences.main"
-            class="com.android.ide.eclipse.adt.preferences.LaunchPreferencePage"
-            id="com.android.ide.eclipse.adt.preferences.LaunchPreferencePage"
-            name="Launch"/>
-      <page
-            category="com.android.ide.eclipse.preferences.main"
-            class="com.android.ide.eclipse.common.preferences.UsagePreferencePage"
-            id="com.android.ide.eclipse.common.preferences.UsagePreferencePage"
-            name="Usage Stats">
-      </page>
-   </extension>
-   <extension
-         point="org.eclipse.core.runtime.preferences">
-      <initializer class="com.android.ide.eclipse.adt.preferences.PreferenceInitializer"/>
-   </extension>
-   <extension
-         id="com.android.ide.eclipse.adt.adtProblem"
-         name="Android ADT Problem"
-         point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <persistent value="true"/>
-   </extension>
-   <extension
-         id="com.android.ide.eclipse.adt.targetProblem"
-         name="Android Target Problem"
-         point="org.eclipse.core.resources.markers">
-      <super type="org.eclipse.core.resources.problemmarker"/>
-      <persistent value="false"/>
-   </extension>
-   <extension
-         point="org.eclipse.ui.perspectiveExtensions">
-      <perspectiveExtension targetID="org.eclipse.jdt.ui.JavaPerspective">
-         <newWizardShortcut id="com.android.ide.eclipse.adt.project.NewProjectWizard" />
-         <newWizardShortcut
-               id="com.android.ide.eclipse.editors.wizards.NewXmlFileWizard">
-         </newWizardShortcut>
-      </perspectiveExtension>
-      <perspectiveExtension targetID="org.eclipse.debug.ui.DebugPerspective">
-         <viewShortcut id="com.android.ide.eclipse.ddms.views.LogCatView"/>
-         <viewShortcut id="com.android.ide.eclipse.ddms.views.DeviceView"/>
-      </perspectiveExtension>
-   </extension>
-   <extension
-         point="org.eclipse.ui.ide.projectNatureImages">
-      <image
-            icon="icons/android_project.png"
-            id="com.android.ide.eclipse.adt.AndroidNature.image"
-            natureId="com.android.ide.eclipse.adt.AndroidNature">
-      </image>
-   </extension>
-   <extension
-         point="org.eclipse.jdt.core.classpathContainerInitializer">
-      <classpathContainerInitializer
-            class="com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer"
-            id="com.android.ide.eclipse.adt.project.AndroidClasspathContainerInitializer">
-      </classpathContainerInitializer>
-      <classpathContainerInitializer
-            class="com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer"
-            id="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK">
-      </classpathContainerInitializer>
-   </extension>
-   <extension
-         point="org.eclipse.ui.exportWizards">
-      <category
-            id="com.android.ide.eclipse.wizards.category"
-            name="Android">
-      </category>
-      <wizard
-            category="com.android.ide.eclipse.wizards.category"
-            class="com.android.ide.eclipse.adt.project.export.ExportWizard"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.adt.project.ExportWizard"
-            name="Export Android Application">
-      </wizard>
-   </extension>
-   <extension
-         point="org.eclipse.ui.commands">
-      <command
-            name="Debug Android Application"
-            description="Debug Android Application"
-            categoryId="org.eclipse.debug.ui.category.run"
-            id="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut.debug">
-      </command>
-      <command
-            name="Run Android Application"
-            description="Run Android Application"
-            categoryId="org.eclipse.debug.ui.category.run"
-            id="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut.run">
-      </command>
-      <keyBinding
-            keySequence="M3+M2+A D"
-            contextId="org.eclipse.ui.globalScope"
-            commandId="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut.debug"
-            keyConfigurationId="org.eclipse.ui.defaultAcceleratorConfiguration">
-      </keyBinding>
-      <keyBinding
-            keySequence="M3+M2+A R"
-            contextId="org.eclipse.ui.globalScope"
-            commandId="com.android.ide.eclipse.adt.debug.launching.LaunchShortcut.run"
-            keyConfigurationId="org.eclipse.ui.defaultAcceleratorConfiguration">
-      </keyBinding>
-   </extension>
-   <extension
-         point="org.eclipse.ui.decorators">
-      <decorator
-            adaptable="true"
-            class="com.android.ide.eclipse.adt.project.FolderDecorator"
-            id="com.android.ide.eclipse.adt.project.FolderDecorator"
-            label="Android Decorator"
-            lightweight="true"
-            location="TOP_RIGHT"
-            objectClass="org.eclipse.core.resources.IFolder"
-            state="true">
-      </decorator>
-   </extension>
-   <extension
-         point="org.eclipse.ui.editors">
-      <editor
-            class="com.android.ide.eclipse.editors.manifest.ManifestEditor"
-            default="true"
-            filenames="AndroidManifest.xml"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.manifest.ManifestEditor"
-            name="Android Manifest Editor">
-      </editor>
-      <editor
-            class="com.android.ide.eclipse.editors.resources.ResourcesEditor"
-            default="false"
-            extensions="xml"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.resources.ResourcesEditor"
-            name="Android Resource Editor">
-      </editor>
-      <editor
-            class="com.android.ide.eclipse.editors.layout.LayoutEditor"
-            default="false"
-            extensions="xml"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.layout.LayoutEditor"
-            matchingStrategy="com.android.ide.eclipse.editors.layout.MatchingStrategy"
-            name="Android Layout Editor">
-      </editor>
-      <editor
-            class="com.android.ide.eclipse.editors.menu.MenuEditor"
-            default="false"
-            extensions="xml"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.menu.MenuEditor"
-            name="Android Menu Editor">
-      </editor>
-      <editor
-            class="com.android.ide.eclipse.editors.xml.XmlEditor"
-            default="false"
-            extensions="xml"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.xml.XmlEditor"
-            name="Android Xml Resources Editor">
-      </editor>
-   </extension>
-   <extension
-         point="org.eclipse.ui.views">
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.editors.resources.explorer.ResourceExplorerView"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.editors.resources.explorer.ResourceExplorerView"
-            name="Resource Explorer">
-      </view>
-   </extension>
-   <extension
-         point="org.eclipse.wst.sse.ui.editorConfiguration">
-      <sourceViewerConfiguration
-            class="com.android.ide.eclipse.editors.manifest.ManifestSourceViewerConfig"
-            target="com.android.ide.eclipse.editors.manifest.ManifestEditor">
-      </sourceViewerConfiguration>
-      <sourceViewerConfiguration
-            class="com.android.ide.eclipse.editors.resources.ResourcesSourceViewerConfig"
-            target="com.android.ide.eclipse.editors.resources.ResourcesEditor">
-      </sourceViewerConfiguration>
-      <sourceViewerConfiguration
-            class="com.android.ide.eclipse.editors.layout.LayoutSourceViewerConfig"
-            target="com.android.ide.eclipse.editors.layout.LayoutEditor">
-      </sourceViewerConfiguration>
-      <sourceViewerConfiguration
-            class="com.android.ide.eclipse.editors.menu.MenuSourceViewerConfig"
-            target="com.android.ide.eclipse.editors.menu.MenuEditor">
-      </sourceViewerConfiguration>
-      <sourceViewerConfiguration
-            class="com.android.ide.eclipse.editors.xml.XmlSourceViewerConfig"
-            target="com.android.ide.eclipse.editors.xml.XmlEditor">
-      </sourceViewerConfiguration>
-   </extension>
-   <extension
-         point="org.eclipse.ui.propertyPages">
-      <page
-            adaptable="true"
-            class="com.android.ide.eclipse.adt.project.properties.AndroidPropertyPage"
-            id="com.android.ide.eclipse.adt.project.properties.AndroidPropertyPage"
-            name="Android"
-            nameFilter="*"
-            objectClass="org.eclipse.core.resources.IProject">
-         <enabledWhen>
-               <test property="org.eclipse.jdt.launching.hasProjectNature"
-                     args="com.android.ide.eclipse.adt.AndroidNature"/>
-         </enabledWhen>
-      </page>
-   </extension>
-</plugin>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtConstants.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtConstants.java
deleted file mode 100644
index 7304e5e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtConstants.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt;
-
-import com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer;
-
-
-/**
- * Constant definition class.<br>
- * <br>
- * Most constants have a prefix defining the content.
- * <ul>
- * <li><code>WS_</code> Workspace path constant. Those are absolute paths,
- * from the project root.</li>
- * <li><code>OS_</code> OS path constant. These paths are different depending on the platform.</li>
- * <li><code>FN_</code> File name constant.</li>
- * <li><code>FD_</code> Folder name constant.</li>
- * <li><code>MARKER_</code> Resource Marker Ids constant.</li>
- * <li><code>EXT_</code> File extension constant. This does NOT include a dot.</li>
- * <li><code>DOT_</code> File extension constant. This start with a dot.</li>
- * <li><code>RE_</code> Regexp constant.</li>
- * <li><code>BUILD_</code> Build verbosity level constant. To use with
- * <code>AdtPlugin.printBuildToConsole()</code></li>
- * </ul>
- */
-public class AdtConstants {
-    /** Generic marker for ADT errors. */
-    public final static String MARKER_ADT = AdtPlugin.PLUGIN_ID + ".adtProblem"; //$NON-NLS-1$
-
-    /** Marker for Android Target errors.
-     * This is not cleared on each like other markers. Instead, it's cleared
-     * when an {@link AndroidClasspathContainerInitializer} has succeeded in creating an
-     * AndroidClasspathContainer */
-    public final static String MARKER_TARGET = AdtPlugin.PLUGIN_ID + ".targetProblem"; //$NON-NLS-1$
-
-    /** Build verbosity "Always". Those messages are always displayed. */
-    public final static int BUILD_ALWAYS = 0;
-
-    /** Build verbosity level "Normal" */
-    public final static int BUILD_NORMAL = 1;
-
-    /** Build verbosity level "Verbose". Those messages are only displayed in verbose mode */
-    public final static int BUILD_VERBOSE = 2;
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtPlugin.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtPlugin.java
deleted file mode 100644
index 9aa9354..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/AdtPlugin.java
+++ /dev/null
@@ -1,1330 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt;
-
-import com.android.ddmuilib.StackTracePanel;
-import com.android.ddmuilib.StackTracePanel.ISourceRevealer;
-import com.android.ddmuilib.console.DdmConsole;
-import com.android.ddmuilib.console.IDdmConsole;
-import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController;
-import com.android.ide.eclipse.adt.preferences.BuildPreferencePage;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard;
-import com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetParser;
-import com.android.ide.eclipse.adt.sdk.LoadStatus;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.EclipseUiHelper;
-import com.android.ide.eclipse.common.SdkStatsHelper;
-import com.android.ide.eclipse.common.StreamHelper;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.common.project.ExportHelper;
-import com.android.ide.eclipse.common.project.ExportHelper.IExportCallback;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.ImageLoader;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.layout.LayoutEditor;
-import com.android.ide.eclipse.editors.menu.MenuEditor;
-import com.android.ide.eclipse.editors.resources.ResourcesEditor;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolder;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener;
-import com.android.ide.eclipse.editors.xml.XmlEditor;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Preferences;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.SubMonitor;
-import org.eclipse.core.runtime.Preferences.IPropertyChangeListener;
-import org.eclipse.core.runtime.Preferences.PropertyChangeEvent;
-import org.eclipse.core.runtime.jobs.IJobChangeEvent;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.core.runtime.jobs.JobChangeAdapter;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IEditorDescriptor;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.console.ConsolePlugin;
-import org.eclipse.ui.console.IConsole;
-import org.eclipse.ui.console.IConsoleConstants;
-import org.eclipse.ui.console.MessageConsole;
-import org.eclipse.ui.console.MessageConsoleStream;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.Constants;
-import org.osgi.framework.Version;
-
-import java.io.BufferedInputStream;
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.io.OutputStream;
-import java.io.PrintStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class AdtPlugin extends AbstractUIPlugin {
-    /** The plug-in ID */
-    public static final String PLUGIN_ID = "com.android.ide.eclipse.adt"; //$NON-NLS-1$
-    
-    public final static String PREFS_SDK_DIR = PLUGIN_ID + ".sdk"; //$NON-NLS-1$
-
-    public final static String PREFS_RES_AUTO_REFRESH = PLUGIN_ID + ".resAutoRefresh"; //$NON-NLS-1$
-
-    public final static String PREFS_BUILD_VERBOSITY = PLUGIN_ID + ".buildVerbosity"; //$NON-NLS-1$
-
-    public final static String PREFS_DEFAULT_DEBUG_KEYSTORE = PLUGIN_ID + ".defaultDebugKeyStore"; //$NON-NLS-1$
-
-    public final static String PREFS_CUSTOM_DEBUG_KEYSTORE = PLUGIN_ID + ".customDebugKeyStore"; //$NON-NLS-1$
-
-    public final static String PREFS_HOME_PACKAGE = PLUGIN_ID + ".homePackage"; //$NON-NLS-1$
-
-    public final static String PREFS_EMU_OPTIONS = PLUGIN_ID + ".emuOptions"; //$NON-NLS-1$
-    
-    /** singleton instance */
-    private static AdtPlugin sPlugin;
-
-    private static Image sAndroidLogo;
-    private static ImageDescriptor sAndroidLogoDesc;
-
-    /** default store, provided by eclipse */
-    private IPreferenceStore mStore;
-
-    /** cached location for the sdk folder */
-    private String mOsSdkLocation;
-
-    /** The global android console */
-    private MessageConsole mAndroidConsole;
-
-    /** Stream to write in the android console */
-    private MessageConsoleStream mAndroidConsoleStream;
-
-    /** Stream to write error messages to the android console */
-    private MessageConsoleStream mAndroidConsoleErrorStream;
-
-    /** Image loader object */
-    private ImageLoader mLoader;
-
-    /** Verbosity of the build */
-    private int mBuildVerbosity = AdtConstants.BUILD_NORMAL;
-
-    /** Color used in the error console */
-    private Color mRed;
-    
-    /** Load status of the SDK. Any access MUST be in a synchronized(mPostLoadProjects) block */
-    private LoadStatus mSdkIsLoaded = LoadStatus.LOADING;
-    /** Project to update once the SDK is loaded.
-     * Any access MUST be in a synchronized(mPostLoadProjectsToResolve) block */
-    private final ArrayList<IJavaProject> mPostLoadProjectsToResolve =
-            new ArrayList<IJavaProject>();
-    /** Project to check validity of cache vs actual once the SDK is loaded.
-     * Any access MUST be in a synchronized(mPostLoadProjectsToResolve) block */
-    private final ArrayList<IJavaProject> mPostLoadProjectsToCheck = new ArrayList<IJavaProject>();
-    
-    private ResourceMonitor mResourceMonitor;
-    private ArrayList<Runnable> mResourceRefreshListener = new ArrayList<Runnable>();
-
-    /**
-     * Custom PrintStream for Dx output. This class overrides the method
-     * <code>println()</code> and adds the standard output tag with the
-     * date and the project name in front of every messages.
-     */
-    private static final class AndroidPrintStream extends PrintStream {
-        private IProject mProject;
-        private String mPrefix;
-
-        /**
-         * Default constructor with project and output stream.
-         * The project is used to get the project name for the output tag.
-         *
-         * @param project The Project
-         * @param prefix A prefix to be printed before the actual message. Can be null
-         * @param stream The Stream
-         */
-        public AndroidPrintStream(IProject project, String prefix, OutputStream stream) {
-            super(stream);
-            mProject = project;
-        }
-
-        @Override
-        public void println(String message) {
-            // write the date/project tag first.
-            String tag = StreamHelper.getMessageTag(mProject != null ? mProject.getName() : null);
-
-            print(tag);
-            if (mPrefix != null) {
-                print(mPrefix);
-            }
-
-            // then write the regular message
-            super.println(message);
-        }
-    }
-
-    /**
-     * An error handler for checkSdkLocationAndId() that will handle the generated error
-     * or warning message. Each method must return a boolean that will in turn be returned by
-     * checkSdkLocationAndId.
-     */
-    public static abstract class CheckSdkErrorHandler {
-        /** Handle an error message during sdk location check. Returns whatever
-         * checkSdkLocationAndId() should returns.
-         */
-        public abstract boolean handleError(String message);
-
-        /** Handle a warning message during sdk location check. Returns whatever
-         * checkSdkLocationAndId() should returns.
-         */
-        public abstract boolean handleWarning(String message);
-    }
-
-    /**
-     * The constructor
-     */
-    public AdtPlugin() {
-        sPlugin = this;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-
-        Display display = getDisplay();
-
-        // set the default android console.
-        mAndroidConsole = new MessageConsole("Android", null); //$NON-NLS-1$
-        ConsolePlugin.getDefault().getConsoleManager().addConsoles(
-                new IConsole[] { mAndroidConsole });
-
-        // get the stream to write in the android console.
-        mAndroidConsoleStream = mAndroidConsole.newMessageStream();
-        mAndroidConsoleErrorStream = mAndroidConsole.newMessageStream();
-        mRed = new Color(display, 0xFF, 0x00, 0x00);
-
-        // because this can be run, in some cases, by a non ui thread, and beccause
-        // changing the console properties update the ui, we need to make this change
-        // in the ui thread.
-        display.asyncExec(new Runnable() {
-            public void run() {
-                mAndroidConsoleErrorStream.setColor(mRed);
-            }
-        });
-
-        // set up the ddms console to use this objects
-        DdmConsole.setConsole(new IDdmConsole() {
-            public void printErrorToConsole(String message) {
-                AdtPlugin.printErrorToConsole((String)null, message);
-            }
-            public void printErrorToConsole(String[] messages) {
-                AdtPlugin.printErrorToConsole((String)null, (Object[])messages);
-            }
-            public void printToConsole(String message) {
-                AdtPlugin.printToConsole((String)null, message);
-            }
-            public void printToConsole(String[] messages) {
-                AdtPlugin.printToConsole((String)null, (Object[])messages);
-            }
-        });
-
-        // get the eclipse store
-        mStore = getPreferenceStore();
-
-        // set the listener for the preference change
-        Preferences prefs = getPluginPreferences();
-        prefs.addPropertyChangeListener(new IPropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent event) {
-                // get the name of the property that changed.
-                String property = event.getProperty();
-
-                // if the SDK changed, we update the cached version
-                if (PREFS_SDK_DIR.equals(property)) {
-
-                    // get the new one from the preferences
-                    mOsSdkLocation = (String)event.getNewValue();
-
-                    // make sure it ends with a separator
-                    if (mOsSdkLocation.endsWith(File.separator) == false) {
-                        mOsSdkLocation = mOsSdkLocation + File.separator;
-                    }
-
-                    // finally restart adb, in case it's a different version
-                    DdmsPlugin.setAdb(getOsAbsoluteAdb(), true /* startAdb */);
-
-                    // get the SDK location and build id.
-                    if (checkSdkLocationAndId()) {
-                        // if sdk if valid, reparse it
-                        
-                        // add all the opened Android projects to the list of projects to be updated
-                        // after the SDK is reloaded
-                        synchronized (getSdkLockObject()) {
-                            // get the project to refresh.
-                            IJavaProject[] androidProjects = BaseProjectHelper.getAndroidProjects();
-                            mPostLoadProjectsToResolve.addAll(Arrays.asList(androidProjects));
-                        }
-    
-                        // parse the SDK resources at the new location
-                        parseSdkContent();
-                    }
-                } else if (PREFS_BUILD_VERBOSITY.equals(property)) {
-                    mBuildVerbosity = BuildPreferencePage.getBuildLevel(
-                            mStore.getString(PREFS_BUILD_VERBOSITY));
-                }
-            }
-        });
-
-        mOsSdkLocation = mStore.getString(PREFS_SDK_DIR);
-
-        // make sure it ends with a separator. Normally this is done when the preference
-        // is set. But to make sure older version still work, we fix it here as well.
-        if (mOsSdkLocation.length() > 0 && mOsSdkLocation.endsWith(File.separator) == false) {
-            mOsSdkLocation = mOsSdkLocation + File.separator;
-        }
-
-        // check the location of SDK
-        final boolean isSdkLocationValid = checkSdkLocationAndId();
-        
-        mBuildVerbosity = BuildPreferencePage.getBuildLevel(
-                mStore.getString(PREFS_BUILD_VERBOSITY));
-
-        // create the loader that's able to load the images
-        mLoader = new ImageLoader(this);
-
-        // start the DdmsPlugin by setting the adb location, only if it is set already.
-        if (mOsSdkLocation.length() > 0) {
-            DdmsPlugin.setAdb(getOsAbsoluteAdb(), true);
-        }
-
-        // and give it the debug launcher for android projects
-        DdmsPlugin.setRunningAppDebugLauncher(new DdmsPlugin.IDebugLauncher() {
-            public boolean debug(String appName, int port) {
-                // search for an android project matching the process name 
-                IProject project = ProjectHelper.findAndroidProjectByAppName(appName);
-                if (project != null) {
-                    AndroidLaunchController.debugRunningApp(project, port);
-                    return true;
-                } else {
-                    return false;
-                }
-            }
-        });
-        
-        StackTracePanel.setSourceRevealer(new ISourceRevealer() {
-            public void reveal(String applicationName, String className, int line) {
-                IProject project = ProjectHelper.findAndroidProjectByAppName(applicationName);
-                if (project != null) {
-                    BaseProjectHelper.revealSource(project, className, line);
-                }
-            }
-        });
-        
-        // setup export callback for editors
-        ExportHelper.setCallback(new IExportCallback() {
-            public void startExportWizard(IProject project) {
-                StructuredSelection selection = new StructuredSelection(project);
-                
-                ExportWizard wizard = new ExportWizard();
-                wizard.init(PlatformUI.getWorkbench(), selection);
-                WizardDialog dialog = new WizardDialog(getDisplay().getActiveShell(),
-                        wizard);
-                dialog.open();
-            }
-        });
-        
-        // initialize editors
-        startEditors();
-
-        // Ping the usage server and parse the SDK content.
-        // This is deferred in separate jobs to avoid blocking the bundle start.
-        // We also serialize them to avoid too many parallel jobs when Eclipse starts.
-        Job pingJob = createPingUsageServerJob();
-        pingJob.addJobChangeListener(new JobChangeAdapter() {
-           @Override
-            public void done(IJobChangeEvent event) {
-                super.done(event);
-    
-                // Once the ping job is finished, start the SDK parser
-                if (isSdkLocationValid) {
-                    // parse the SDK resources.
-                    parseSdkContent();
-                }
-            } 
-        });
-        // build jobs are run after other interactive jobs
-        pingJob.setPriority(Job.BUILD); 
-        // Wait 2 seconds before starting the ping job. This leaves some time to the
-        // other bundles to initialize.
-        pingJob.schedule(2000 /*milliseconds*/);
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        super.stop(context);
-        
-        stopEditors();
-        
-        mRed.dispose();
-        synchronized (AdtPlugin.class) {
-            sPlugin = null;
-        }
-    }
-
-    /** Return the image loader for the plugin */
-    public static synchronized ImageLoader getImageLoader() {
-        if (sPlugin != null) {
-            return sPlugin.mLoader;
-        }
-        return null;
-    }
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static synchronized AdtPlugin getDefault() {
-        return sPlugin;
-    }
-
-    public static Display getDisplay() {
-        IWorkbench bench = null;
-        synchronized (AdtPlugin.class) {
-            bench = sPlugin.getWorkbench();
-        }
-
-        if (bench != null) {
-            return bench.getDisplay();
-        }
-        return null;
-    }
-
-    /** Returns the adb path relative to the sdk folder */
-    public static String getOsRelativeAdb() {
-        return SdkConstants.OS_SDK_TOOLS_FOLDER + AndroidConstants.FN_ADB;
-    }
-
-    /** Returns the emulator path relative to the sdk folder */
-    public static String getOsRelativeEmulator() {
-        return SdkConstants.OS_SDK_TOOLS_FOLDER + AndroidConstants.FN_EMULATOR;
-    }
-
-    /** Returns the absolute adb path */
-    public static String getOsAbsoluteAdb() {
-        return getOsSdkFolder() + getOsRelativeAdb();
-    }
-
-    /** Returns the absolute traceview path */
-    public static String getOsAbsoluteTraceview() {
-        return getOsSdkFolder() + SdkConstants.OS_SDK_TOOLS_FOLDER +
-                AndroidConstants.FN_TRACEVIEW;
-    }
-
-    /** Returns the absolute emulator path */
-    public static String getOsAbsoluteEmulator() {
-        return getOsSdkFolder() + getOsRelativeEmulator();
-    }
-
-    /**
-     * Returns a Url file path to the javaDoc folder.
-     */
-    public static String getUrlDoc() {
-        return ProjectHelper.getJavaDocPath(
-                getOsSdkFolder() + AndroidConstants.WS_JAVADOC_FOLDER_LEAF);
-    }
-
-    /**
-     * Returns the SDK folder.
-     * Guaranteed to be terminated by a platform-specific path separator.
-     */
-    public static synchronized String getOsSdkFolder() {
-        if (sPlugin == null) {
-            return null;
-        }
-
-        if (sPlugin.mOsSdkLocation == null) {
-            sPlugin.mOsSdkLocation = sPlugin.mStore.getString(PREFS_SDK_DIR);
-        }
-        return sPlugin.mOsSdkLocation;
-    }
-
-    public static String getOsSdkToolsFolder() {
-        return getOsSdkFolder() + SdkConstants.OS_SDK_TOOLS_FOLDER;
-    }
-
-    public static synchronized boolean getAutoResRefresh() {
-        if (sPlugin == null) {
-            return false;
-        }
-        return sPlugin.mStore.getBoolean(PREFS_RES_AUTO_REFRESH);
-    }
-
-    public static synchronized int getBuildVerbosity() {
-        if (sPlugin != null) {
-            return sPlugin.mBuildVerbosity;
-        }
-        
-        return 0;
-    }
-
-    /**
-     * Returns an image descriptor for the image file at the given
-     * plug-in relative path
-     *
-     * @param path the path
-     * @return the image descriptor
-     */
-    public static ImageDescriptor getImageDescriptor(String path) {
-    	return imageDescriptorFromPlugin(PLUGIN_ID, path);
-    }
-
-    /**
-     * Reads and returns the content of a text file embedded in the plugin jar
-     * file.
-     * @param filepath the file path to the text file
-     * @return null if the file could not be read
-     */
-    public static String readEmbeddedTextFile(String filepath) {
-        Bundle bundle = null;
-        synchronized (AdtPlugin.class) {
-            if (sPlugin != null) {
-                bundle = sPlugin.getBundle();
-            } else {
-                return null;
-            }
-        }
-        
-        // attempt to get a file to one of the template.
-        try {
-            URL url = bundle.getEntry(AndroidConstants.WS_SEP + filepath);
-            if (url != null) {
-                BufferedReader reader = new BufferedReader(
-                        new InputStreamReader(url.openStream()));
-
-                String line;
-                StringBuilder total = new StringBuilder(reader.readLine());
-                while ((line = reader.readLine()) != null) {
-                    total.append('\n');
-                    total.append(line);
-                }
-
-                return total.toString();
-            }
-        } catch (MalformedURLException e) {
-            // we'll just return null.
-        } catch (IOException e) {
-            // we'll just return null.
-        }
-
-        return null;
-    }
-
-    /**
-     * Reads and returns the content of a binary file embedded in the plugin jar
-     * file.
-     * @param filepath the file path to the text file
-     * @return null if the file could not be read
-     */
-    public static byte[] readEmbeddedFile(String filepath) {
-        Bundle bundle = null;
-        synchronized (AdtPlugin.class) {
-            if (sPlugin != null) {
-                bundle = sPlugin.getBundle();
-            } else {
-                return null;
-            }
-        }
-
-        // attempt to get a file to one of the template.
-        try {
-            URL url = bundle.getEntry(AndroidConstants.WS_SEP + filepath);
-            if (url != null) {
-                // create a buffered reader to facilitate reading.
-                BufferedInputStream stream = new BufferedInputStream(
-                        url.openStream());
-
-                // get the size to read.
-                int avail = stream.available();
-
-                // create the buffer and reads it.
-                byte[] buffer = new byte[avail];
-                stream.read(buffer);
-
-                // and return.
-                return buffer;
-            }
-        } catch (MalformedURLException e) {
-            // we'll just return null.
-        } catch (IOException e) {
-            // we'll just return null;.
-        }
-
-        return null;
-    }
-
-    /**
-     * Displays an error dialog box. This dialog box is ran asynchronously in the ui thread,
-     * therefore this method can be called from any thread.
-     * @param title The title of the dialog box
-     * @param message The error message
-     */
-    public final static void displayError(final String title, final String message) {
-        // get the current Display
-        final Display display = getDisplay();
-
-        // dialog box only run in ui thread..
-        display.asyncExec(new Runnable() {
-            public void run() {
-                Shell shell = display.getActiveShell();
-                MessageDialog.openError(shell, title, message);
-            }
-        });
-    }
-
-    /**
-     * Displays a warning dialog box. This dialog box is ran asynchronously in the ui thread,
-     * therefore this method can be called from any thread.
-     * @param title The title of the dialog box
-     * @param message The warning message
-     */
-    public final static void displayWarning(final String title, final String message) {
-        // get the current Display
-        final Display display = getDisplay();
-
-        // dialog box only run in ui thread..
-        display.asyncExec(new Runnable() {
-            public void run() {
-                Shell shell = display.getActiveShell();
-                MessageDialog.openWarning(shell, title, message);
-            }
-        });
-    }
-
-    /**
-     * Display a yes/no question dialog box. This dialog is opened synchronously in the ui thread,
-     * therefore this message can be called from any thread.
-     * @param title The title of the dialog box
-     * @param message The error message
-     * @return true if OK was clicked.
-     */
-    public final static boolean displayPrompt(final String title, final String message) {
-        // get the current Display and Shell
-        final Display display = getDisplay();
-
-        // we need to ask the user what he wants to do.
-        final boolean[] result = new boolean[1];
-        display.syncExec(new Runnable() {
-            public void run() {
-                Shell shell = display.getActiveShell();
-                result[0] = MessageDialog.openQuestion(shell, title, message);
-            }
-        });
-        return result[0];
-    }
-    
-    /**
-     * Logs a message to the default Eclipse log.
-     * 
-     * @param severity The severity code. Valid values are: {@link IStatus#OK},
-     * {@link IStatus#ERROR}, {@link IStatus#INFO}, {@link IStatus#WARNING} or
-     * {@link IStatus#CANCEL}.
-     * @param format The format string, like for {@link String#format(String, Object...)}.
-     * @param args The arguments for the format string, like for
-     * {@link String#format(String, Object...)}.
-     */
-    public static void log(int severity, String format, Object ... args) {
-        String message = String.format(format, args);
-        Status status = new Status(severity, PLUGIN_ID, message);
-        getDefault().getLog().log(status);
-    }
-
-    /**
-     * Logs an exception to the default Eclipse log.
-     * <p/>
-     * The status severity is always set to ERROR.
-     * 
-     * @param exception the exception to log.
-     * @param format The format string, like for {@link String#format(String, Object...)}.
-     * @param args The arguments for the format string, like for
-     * {@link String#format(String, Object...)}.
-     */
-    public static void log(Throwable exception, String format, Object ... args) {
-        String message = String.format(format, args);
-        Status status = new Status(IStatus.ERROR, PLUGIN_ID, message, exception);
-        getDefault().getLog().log(status);
-    }
-    
-    /**
-     * This is a mix between log(Throwable) and printErrorToConsole.
-     * <p/>
-     * This logs the exception with an ERROR severity and the given printf-like format message.
-     * The same message is then printed on the Android error console with the associated tag.
-     * 
-     * @param exception the exception to log.
-     * @param format The format string, like for {@link String#format(String, Object...)}.
-     * @param args The arguments for the format string, like for
-     * {@link String#format(String, Object...)}.
-     */
-    public static synchronized void logAndPrintError(Throwable exception, String tag,
-            String format, Object ... args) {
-        if (sPlugin != null) {
-            String message = String.format(format, args);
-            Status status = new Status(IStatus.ERROR, PLUGIN_ID, message, exception);
-            getDefault().getLog().log(status);
-            StreamHelper.printToStream(sPlugin.mAndroidConsoleErrorStream, tag, message);
-            showAndroidConsole();
-        }
-    }
-
-    /**
-     * Prints one or more error message to the android console.
-     * @param tag A tag to be associated with the message. Can be null.
-     * @param objects the objects to print through their <code>toString</code> method.
-     */
-    public static synchronized void printErrorToConsole(String tag, Object... objects) {
-        if (sPlugin != null) {
-            StreamHelper.printToStream(sPlugin.mAndroidConsoleErrorStream, tag, objects);
-    
-            showAndroidConsole();
-        }
-    }
-
-    /**
-     * Prints one or more error message to the android console.
-     * @param objects the objects to print through their <code>toString</code> method.
-     */
-    public static void printErrorToConsole(Object... objects) {
-        printErrorToConsole((String)null, objects);
-    }
-
-    /**
-     * Prints one or more error message to the android console.
-     * @param project The project to which the message is associated. Can be null.
-     * @param objects the objects to print through their <code>toString</code> method.
-     */
-    public static void printErrorToConsole(IProject project, Object... objects) {
-        String tag = project != null ? project.getName() : null;
-        printErrorToConsole(tag, objects);
-    }
-
-    /**
-     * Prints one or more build messages to the android console, filtered by Build output verbosity.
-     * @param level Verbosity level of the message.
-     * @param project The project to which the message is associated. Can be null.
-     * @param objects the objects to print through their <code>toString</code> method.
-     * @see AdtConstants#BUILD_ALWAYS
-     * @see AdtConstants#BUILD_NORMAL
-     * @see AdtConstants#BUILD_VERBOSE
-     */
-    public static synchronized void printBuildToConsole(int level, IProject project,
-            Object... objects) {
-        if (sPlugin != null) {
-            if (level <= sPlugin.mBuildVerbosity) {
-                String tag = project != null ? project.getName() : null;
-                StreamHelper.printToStream(sPlugin.mAndroidConsoleStream, tag, objects);
-            }
-        }
-    }
-
-    /**
-     * Prints one or more message to the android console.
-     * @param tag The tag to be associated with the message. Can be null.
-     * @param objects the objects to print through their <code>toString</code> method.
-     */
-    public static synchronized void printToConsole(String tag, Object... objects) {
-        if (sPlugin != null) {
-            StreamHelper.printToStream(sPlugin.mAndroidConsoleStream, tag, objects);
-        }
-    }
-
-    /**
-     * Prints one or more message to the android console.
-     * @param project The project to which the message is associated. Can be null.
-     * @param objects the objects to print through their <code>toString</code> method.
-     */
-    public static void printToConsole(IProject project, Object... objects) {
-        String tag = project != null ? project.getName() : null;
-        printToConsole(tag, objects);
-    }
-
-    /** Force the display of the android console */
-    public static void showAndroidConsole() {
-        // first make sure the console is in the workbench
-        EclipseUiHelper.showView(IConsoleConstants.ID_CONSOLE_VIEW, true);
-        
-        // now make sure it's not docked.
-        ConsolePlugin.getDefault().getConsoleManager().showConsoleView(
-                AdtPlugin.getDefault().getAndroidConsole());
-    }
-
-    /**
-     * Returns an standard PrintStream object for a specific project.<br>
-     * This PrintStream will add a date/project at the beginning of every
-     * <code>println()</code> output.
-     *
-     * @param project The project object
-     * @param prefix The prefix to be added to the message. Can be null.
-     * @return a new PrintStream
-     */
-    public static synchronized PrintStream getOutPrintStream(IProject project, String prefix) {
-        if (sPlugin != null) {
-            return new AndroidPrintStream(project, prefix, sPlugin.mAndroidConsoleStream);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns an error PrintStream object for a specific project.<br>
-     * This PrintStream will add a date/project at the beginning of every
-     * <code>println()</code> output.
-     *
-     * @param project The project object
-     * @param prefix The prefix to be added to the message. Can be null.
-     * @return a new PrintStream
-     */
-    public static synchronized PrintStream getErrPrintStream(IProject project, String prefix) {
-        if (sPlugin != null) {
-            return new AndroidPrintStream(project, prefix, sPlugin.mAndroidConsoleErrorStream);
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns whether the Sdk has been loaded.
-     */
-    public final LoadStatus getSdkLoadStatus() {
-        synchronized (getSdkLockObject()) {
-            return mSdkIsLoaded;
-        }
-    }
-    
-    /**
-     * Returns the lock object for SDK loading. If you wish to do things while the SDK is loading,
-     * you must synchronize on this object.
-     * @return
-     */
-    public final Object getSdkLockObject() {
-        return mPostLoadProjectsToResolve;
-    }
-    
-    /**
-     * Sets the given {@link IJavaProject} to have its target resolved again once the SDK finishes
-     * to load.
-     */
-    public final void setProjectToResolve(IJavaProject javaProject) {
-        synchronized (getSdkLockObject()) {
-            mPostLoadProjectsToResolve.add(javaProject);
-        }
-    }
-    
-    /**
-     * Sets the given {@link IJavaProject} to have its target checked for consistency
-     * once the SDK finishes to load. This is used if the target is resolved using cached
-     * information while the SDK is loading.
-     */
-    public final void setProjectToCheck(IJavaProject javaProject) {
-        // only lock on 
-        synchronized (getSdkLockObject()) {
-            mPostLoadProjectsToCheck.add(javaProject);
-        }
-    }
-
-    /**
-     * Checks the location of the SDK is valid and if it is, grab the SDK API version
-     * from the SDK.
-     * @return false if the location is not correct.
-     */
-    private boolean checkSdkLocationAndId() {
-        if (mOsSdkLocation == null || mOsSdkLocation.length() == 0) {
-            displayError(Messages.Dialog_Title_SDK_Location, Messages.SDK_Not_Setup);
-            return false;
-        }
-
-        return checkSdkLocationAndId(mOsSdkLocation, new CheckSdkErrorHandler() {
-            @Override
-            public boolean handleError(String message) {
-                AdtPlugin.displayError(Messages.Dialog_Title_SDK_Location,
-                        String.format(Messages.Error_Check_Prefs, message));
-                return false;
-            }
-
-            @Override
-            public boolean handleWarning(String message) {
-                AdtPlugin.displayWarning(Messages.Dialog_Title_SDK_Location, message);
-                return true;
-            }
-        });
-    }
-
-    /**
-     * Internal helper to perform the actual sdk location and id check.
-     *
-     * @param osSdkLocation The sdk directory, an OS path.
-     * @param errorHandler An checkSdkErrorHandler that can display a warning or an error.
-     * @return False if there was an error or the result from the errorHandler invocation.
-     */
-    public boolean checkSdkLocationAndId(String osSdkLocation, CheckSdkErrorHandler errorHandler) {
-        if (osSdkLocation.endsWith(File.separator) == false) {
-            osSdkLocation = osSdkLocation + File.separator;
-        }
-
-        File osSdkFolder = new File(osSdkLocation);
-        if (osSdkFolder.isDirectory() == false) {
-            return errorHandler.handleError(
-                    String.format(Messages.Could_Not_Find_Folder, osSdkLocation));
-        }
-
-        String osTools = osSdkLocation + SdkConstants.OS_SDK_TOOLS_FOLDER;
-        File toolsFolder = new File(osTools);
-        if (toolsFolder.isDirectory() == false) {
-            return errorHandler.handleError(
-                    String.format(Messages.Could_Not_Find_Folder_In_SDK,
-                            SdkConstants.FD_TOOLS, osSdkLocation));
-        }
-
-        // check the path to various tools we use
-        String[] filesToCheck = new String[] {
-                osSdkLocation + getOsRelativeAdb(),
-                osSdkLocation + getOsRelativeEmulator()
-        };
-        for (String file : filesToCheck) {
-            if (checkFile(file) == false) {
-                return errorHandler.handleError(String.format(Messages.Could_Not_Find, file));
-            }
-        }
-
-        // check the SDK build id/version and the plugin version.
-        return VersionCheck.checkVersion(osSdkLocation, errorHandler);
-    }
-
-    /**
-     * Checks if a path reference a valid existing file.
-     * @param osPath the os path to check.
-     * @return true if the file exists and is, in fact, a file.
-     */
-    private boolean checkFile(String osPath) {
-        File file = new File(osPath);
-        if (file.isFile() == false) {
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Creates a job than can ping the usage server.
-     */
-    private Job createPingUsageServerJob() {
-        // In order to not block the plugin loading, so we spawn another thread.
-        Job job = new Job("Android SDK Ping") {  // Job name, visible in progress view
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {
-
-                    // get the version of the plugin
-                    String versionString = (String) getBundle().getHeaders().get(
-                            Constants.BUNDLE_VERSION);
-                    Version version = new Version(versionString);
-                    
-                    SdkStatsHelper.pingUsageServer("editors", version); //$NON-NLS-1$
-                    
-                    return Status.OK_STATUS;
-                } catch (Throwable t) {
-                    log(t, "pingUsageServer failed"); //$NON-NLS-1$
-                    return new Status(IStatus.ERROR, PLUGIN_ID,
-                            "pingUsageServer failed", t);
-                }
-            }
-        };
-        return job;
-    }
-    
-    /**
-     * Parses the SDK resources.
-     */
-    private void parseSdkContent() {
-        // Perform the update in a thread (here an Eclipse runtime job)
-        // since this should never block the caller (especially the start method)
-        Job job = new Job(Messages.AdtPlugin_Android_SDK_Content_Loader) {
-            @SuppressWarnings("unchecked")
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {                    
-                    SubMonitor progress = SubMonitor.convert(monitor,
-                            "Initialize SDK Manager", 100);
-                    
-                    Sdk sdk = Sdk.loadSdk(mOsSdkLocation);
-                    
-                    if (sdk != null) {
-                        
-                        progress.setTaskName(Messages.AdtPlugin_Parsing_Resources);
-                        
-                        for (IAndroidTarget target : sdk.getTargets()) {
-                            IStatus status = new AndroidTargetParser(target).run(progress);
-                            if (status.getCode() != IStatus.OK) {
-                                synchronized (getSdkLockObject()) {
-                                    mSdkIsLoaded = LoadStatus.FAILED;
-                                    mPostLoadProjectsToResolve.clear();
-                                }
-                                return status;
-                            }
-                        }
-
-                        // FIXME: move this per platform, or somewhere else.
-                        progress = SubMonitor.convert(monitor,
-                                Messages.AdtPlugin_Parsing_Resources, 20);
-
-                        synchronized (getSdkLockObject()) {
-                            mSdkIsLoaded = LoadStatus.LOADED;
-
-                            // check the projects that need checking.
-                            // The method modifies the list (it removes the project that
-                            // do not need to be resolved again).
-                            AndroidClasspathContainerInitializer.checkProjectsCache(
-                                    mPostLoadProjectsToCheck);
-                            
-                            mPostLoadProjectsToResolve.addAll(mPostLoadProjectsToCheck);
-                            
-                            // update the project that needs recompiling.
-                            if (mPostLoadProjectsToResolve.size() > 0) {
-                                IJavaProject[] array = mPostLoadProjectsToResolve.toArray(
-                                        new IJavaProject[mPostLoadProjectsToResolve.size()]);
-                                AndroidClasspathContainerInitializer.updateProjects(array);
-                                mPostLoadProjectsToResolve.clear();
-                            }
-                        }
-                    }
-                        
-                    // Notify resource changed listeners
-                    progress.subTask("Refresh UI");
-                    progress.setWorkRemaining(mResourceRefreshListener.size());
-                    
-                    // Clone the list before iterating, to avoid Concurrent Modification
-                    // exceptions
-                    List<Runnable> listeners = (List<Runnable>)mResourceRefreshListener.clone();
-                    for (Runnable listener : listeners) {
-                        try {
-                            AdtPlugin.getDisplay().syncExec(listener);
-                        } catch (Exception e) {
-                            AdtPlugin.log(e, "ResourceRefreshListener Failed");  //$NON-NLS-1$
-                        } finally {
-                            progress.worked(1);
-                        }
-                    }
-                } finally {
-                    if (monitor != null) {
-                        monitor.done();
-                    }
-                }
-
-                return Status.OK_STATUS;
-            }
-        };
-        job.setPriority(Job.BUILD); // build jobs are run after other interactive jobs
-        job.schedule();
-    }
-    
-    /** Returns the global android console */
-    public MessageConsole getAndroidConsole() {
-        return mAndroidConsole;
-    }
-    
-    // ----- Methods for Editors -------
-
-    public void startEditors() {
-        sAndroidLogoDesc = imageDescriptorFromPlugin(AdtPlugin.PLUGIN_ID,
-                "/icons/android.png"); //$NON-NLS-1$
-        sAndroidLogo = sAndroidLogoDesc.createImage();
-        
-        // get the stream to write in the android console.
-        MessageConsole androidConsole = AdtPlugin.getDefault().getAndroidConsole();
-        mAndroidConsoleStream = androidConsole.newMessageStream();
-
-        mAndroidConsoleErrorStream = androidConsole.newMessageStream();
-        mRed = new Color(getDisplay(), 0xFF, 0x00, 0x00);
-
-        // because this can be run, in some cases, by a non ui thread, and beccause
-        // changing the console properties update the ui, we need to make this change
-        // in the ui thread.
-        getDisplay().asyncExec(new Runnable() {
-            public void run() {
-                mAndroidConsoleErrorStream.setColor(mRed);
-            }
-        });
-
-        // Add a resource listener to handle compiled resources.
-        IWorkspace ws = ResourcesPlugin.getWorkspace();
-        mResourceMonitor = ResourceMonitor.startMonitoring(ws);
-
-        if (mResourceMonitor != null) {
-            try {
-                setupDefaultEditor(mResourceMonitor);
-                ResourceManager.setup(mResourceMonitor);
-            } catch (Throwable t) {
-                log(t, "ResourceManager.setup failed"); //$NON-NLS-1$
-            }
-        }
-    }
-
-    /**
-     * The <code>AbstractUIPlugin</code> implementation of this <code>Plugin</code>
-     * method saves this plug-in's preference and dialog stores and shuts down 
-     * its image registry (if they are in use). Subclasses may extend this
-     * method, but must send super <b>last</b>. A try-finally statement should
-     * be used where necessary to ensure that <code>super.shutdown()</code> is
-     * always done.
-     * 
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
-     */
-    public void stopEditors() {
-        sAndroidLogo.dispose();
-        
-        IconFactory.getInstance().Dispose();
-        
-        // Remove the resource listener that handles compiled resources.
-        IWorkspace ws = ResourcesPlugin.getWorkspace();
-        ResourceMonitor.stopMonitoring(ws);
-
-        mRed.dispose();
-    }
-
-    /**
-     * Returns an Image for the small Android logo.
-     * 
-     * Callers should not dispose it.
-     */
-    public static Image getAndroidLogo() {
-        return sAndroidLogo;
-    }
-
-    /**
-     * Returns an {@link ImageDescriptor} for the small Android logo.
-     * 
-     * Callers should not dispose it.
-     */
-    public static ImageDescriptor getAndroidLogoDesc() {
-        return sAndroidLogoDesc;
-    }
-    
-    /**
-     * Returns the ResourceMonitor object.
-     */
-    public ResourceMonitor getResourceMonitor() {
-        return mResourceMonitor;
-    }
-
-    /**
-     * Sets up the editor to register default editors for resource files when needed.
-     * 
-     * This is called by the {@link AdtPlugin} during initialization.
-     * 
-     * @param monitor The main Resource Monitor object.
-     */
-    public void setupDefaultEditor(ResourceMonitor monitor) {
-        monitor.addFileListener(new IFileListener() {
-
-            private static final String UNKNOWN_EDITOR = "unknown-editor"; //$NON-NLS-1$
-            
-            /* (non-Javadoc)
-             * Sent when a file changed.
-             * @param file The file that changed.
-             * @param markerDeltas The marker deltas for the file.
-             * @param kind The change kind. This is equivalent to
-             * {@link IResourceDelta#accept(IResourceDeltaVisitor)}
-             * 
-             * @see IFileListener#fileChanged
-             */
-            public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind) {
-                if (AndroidConstants.EXT_XML.equals(file.getFileExtension())) {
-                    // The resources files must have a file path similar to
-                    //    project/res/.../*.xml
-                    // There is no support for sub folders, so the segment count must be 4
-                    if (file.getFullPath().segmentCount() == 4) {
-                        // check if we are inside the res folder.
-                        String segment = file.getFullPath().segment(1); 
-                        if (segment.equalsIgnoreCase(SdkConstants.FD_RESOURCES)) {
-                            // we are inside a res/ folder, get the actual ResourceFolder
-                            ProjectResources resources = ResourceManager.getInstance().
-                                getProjectResources(file.getProject());
-
-                            // This happens when importing old Android projects in Eclipse
-                            // that lack the container (probably because resources fail to build
-                            // properly.)
-                            if (resources == null) {
-                                log(IStatus.INFO,
-                                        "getProjectResources failed for path %1$s in project %2$s", //$NON-NLS-1$
-                                        file.getFullPath().toOSString(),
-                                        file.getProject().getName());
-                                return;
-                            }
-
-                            ResourceFolder resFolder = resources.getResourceFolder(
-                                (IFolder)file.getParent());
-                        
-                            if (resFolder != null) {
-                                if (kind == IResourceDelta.ADDED) {
-                                    resourceAdded(file, resFolder.getType());
-                                } else if (kind == IResourceDelta.CHANGED) {
-                                    resourceChanged(file, resFolder.getType());
-                                }
-                            } else {
-                                // if the res folder is null, this means the name is invalid,
-                                // in this case we remove whatever android editors that was set
-                                // as the default editor.
-                                IEditorDescriptor desc = IDE.getDefaultEditor(file);
-                                String editorId = desc.getId();
-                                if (editorId.startsWith(AndroidConstants.EDITORS_NAMESPACE)) {
-                                    // reset the default editor.
-                                    IDE.setDefaultEditor(file, null);
-                                }
-                            }
-                        }
-                    }
-                }
-            }
-
-            private void resourceAdded(IFile file, ResourceFolderType type) {
-                // set the default editor based on the type.
-                if (type == ResourceFolderType.LAYOUT) {
-                    IDE.setDefaultEditor(file, LayoutEditor.ID);
-                } else if (type == ResourceFolderType.DRAWABLE
-                        || type == ResourceFolderType.VALUES) {
-                    IDE.setDefaultEditor(file, ResourcesEditor.ID);
-                } else if (type == ResourceFolderType.MENU) {
-                    IDE.setDefaultEditor(file, MenuEditor.ID);
-                } else if (type == ResourceFolderType.XML) {
-                    if (XmlEditor.canHandleFile(file)) {
-                        IDE.setDefaultEditor(file, XmlEditor.ID);
-                    } else {
-                        // set a property to determine later if the XML can be handled
-                        QualifiedName qname = new QualifiedName(
-                                AdtPlugin.PLUGIN_ID,
-                                UNKNOWN_EDITOR);
-                        try {
-                            file.setPersistentProperty(qname, "1");
-                        } catch (CoreException e) {
-                            // pass
-                        }
-                    }
-                }
-            }
-
-            private void resourceChanged(IFile file, ResourceFolderType type) {
-                if (type == ResourceFolderType.XML) {
-                    IEditorDescriptor ed = IDE.getDefaultEditor(file);
-                    if (ed == null || ed.getId() != XmlEditor.ID) {
-                        QualifiedName qname = new QualifiedName(
-                                AdtPlugin.PLUGIN_ID,
-                                UNKNOWN_EDITOR);
-                        String prop = null;
-                        try {
-                            prop = file.getPersistentProperty(qname);
-                        } catch (CoreException e) {
-                            // pass
-                        }
-                        if (prop != null && XmlEditor.canHandleFile(file)) {
-                            try {
-                                // remove the property & set editor
-                                file.setPersistentProperty(qname, null);
-                                IWorkbenchPage page = PlatformUI.getWorkbench().
-                                                        getActiveWorkbenchWindow().getActivePage();
-                                
-                                IEditorPart oldEditor = page.findEditor(new FileEditorInput(file));
-                                if (oldEditor != null &&
-                                        AdtPlugin.displayPrompt("Android XML Editor",
-                                            String.format("The file you just saved as been recognized as a file that could be better handled using the Android XML Editor. Do you want to edit '%1$s' using the Android XML editor instead?",
-                                                    file.getFullPath()))) {
-                                    IDE.setDefaultEditor(file, XmlEditor.ID);
-                                    IEditorPart newEditor = page.openEditor(
-                                            new FileEditorInput(file),
-                                            XmlEditor.ID,
-                                            true, /* activate */
-                                            IWorkbenchPage.MATCH_NONE);
-                                
-                                    if (newEditor != null) {
-                                        page.closeEditor(oldEditor, true /* save */);
-                                    }
-                                }
-                            } catch (CoreException e) {
-                                // setPersistentProperty or page.openEditor may have failed
-                            }
-                        }
-                    }
-                }
-            }
-
-        }, IResourceDelta.ADDED | IResourceDelta.CHANGED);
-    }
-
-    public void addResourceChangedListener(Runnable resourceRefreshListener) {
-        mResourceRefreshListener.add(resourceRefreshListener);
-    }
-
-    public void removeResourceChangedListener(Runnable resourceRefreshListener) {
-        mResourceRefreshListener.remove(resourceRefreshListener);
-    }
-    
-    public static synchronized OutputStream getErrorStream() {
-        return sPlugin.mAndroidConsoleErrorStream;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/Messages.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/Messages.java
deleted file mode 100644
index a638810..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/Messages.java
+++ /dev/null
@@ -1,48 +0,0 @@
-
-package com.android.ide.eclipse.adt;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "com.android.ide.eclipse.adt.messages"; //$NON-NLS-1$
-
-    public static String AdtPlugin_Android_SDK_Content_Loader;
-
-    public static String AdtPlugin_Android_SDK_Resource_Parser;
-
-    public static String AdtPlugin_Failed_To_Parse_s;
-
-    public static String AdtPlugin_Failed_To_Start_s;
-
-    public static String AdtPlugin_Parsing_Resources;
-
-    public static String Could_Not_Find;
-
-    public static String Could_Not_Find_Folder;
-
-    public static String Could_Not_Find_Folder_In_SDK;
-
-    public static String Dialog_Title_SDK_Location;
-
-    public static String Error_Check_Prefs;
-
-    public static String SDK_Not_Setup;
-
-    public static String VersionCheck_Plugin_Too_Old;
-
-    public static String VersionCheck_Plugin_Version_Failed;
-
-    public static String VersionCheck_SDK_Build_Too_Low;
-
-    public static String VersionCheck_SDK_Milestone_Too_Low;
-
-    public static String VersionCheck_Unable_To_Parse_Version_s;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/VersionCheck.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/VersionCheck.java
deleted file mode 100644
index 6d85af3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/VersionCheck.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt;
-
-import com.android.ide.eclipse.adt.AdtPlugin.CheckSdkErrorHandler;
-import com.android.sdklib.SdkConstants;
-
-import org.osgi.framework.Constants;
-import org.osgi.framework.Version;
-
-import java.io.BufferedReader;
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Class handling the version check for the plugin vs. the SDK.<br>
- * The plugin must be able to support all version of the SDK.
- * 
- * <p/>An SDK can require a new version of the plugin.
- * <p/>The SDK contains a file with the minimum version for the plugin. This file is inside the
- * <code>tools/lib</code> directory, and is called <code>plugin.prop</code>.<br>
- * Inside that text file, there is a line in the format "plugin.version=#.#.#". This is checked
- * against the current plugin version.<br>
- *
- */
-final class VersionCheck {
-    /**
-     * Pattern to get the minimum plugin version supported by the SDK. This is read from
-     * the file <code>$SDK/tools/lib/plugin.prop</code>.
-     */
-    private final static Pattern sPluginVersionPattern = Pattern.compile(
-            "^plugin.version=(\\d+)\\.(\\d+)\\.(\\d+).*$"); //$NON-NLS-1$
-
-    /**
-     * Checks the plugin and the SDK have compatible versions.
-     * @param osSdkPath The path to the SDK
-     * @return true if compatible.
-     */
-    public static boolean checkVersion(String osSdkPath, CheckSdkErrorHandler errorHandler) {
-        AdtPlugin plugin = AdtPlugin.getDefault();
-        String osLibs = osSdkPath + SdkConstants.OS_SDK_TOOLS_LIB_FOLDER;
-
-        // get the plugin property file, and grab the minimum plugin version required
-        // to work with the sdk
-        int minMajorVersion = -1;
-        int minMinorVersion = -1;
-        int minMicroVersion = -1;
-        try {
-            FileReader reader = new FileReader(osLibs + SdkConstants.FN_PLUGIN_PROP);
-            BufferedReader bReader = new BufferedReader(reader);
-            String line;
-            while ((line = bReader.readLine()) != null) {
-                Matcher m = sPluginVersionPattern.matcher(line);
-                if (m.matches()) {
-                    minMajorVersion = Integer.parseInt(m.group(1));
-                    minMinorVersion = Integer.parseInt(m.group(2));
-                    minMicroVersion = Integer.parseInt(m.group(3));
-                    break;
-                }
-            }
-        } catch (FileNotFoundException e) {
-            // the build id will be null, and this is handled by the builders.
-        } catch (IOException e) {
-            // the build id will be null, and this is handled by the builders.
-        }
-
-        // Failed to get the min plugin version number?
-        if (minMajorVersion == -1 || minMinorVersion == -1 || minMicroVersion ==-1) {
-            return errorHandler.handleWarning(Messages.VersionCheck_Plugin_Version_Failed);
-        }
-
-        // test the plugin number
-        String versionString = (String) plugin.getBundle().getHeaders().get(
-                Constants.BUNDLE_VERSION);
-        Version version = new Version(versionString);
-
-        boolean valid = true;
-        if (version.getMajor() < minMajorVersion) {
-            valid = false;
-        } else if (version.getMajor() == minMajorVersion) {
-            if (version.getMinor() < minMinorVersion) {
-                valid = false;
-            } else if (version.getMinor() == minMinorVersion) {
-                if (version.getMicro() < minMicroVersion) {
-                    valid = false;
-                }
-            }
-        }
-
-        if (valid == false) {
-            return errorHandler.handleWarning(
-                    String.format(Messages.VersionCheck_Plugin_Too_Old,
-                            minMajorVersion, minMinorVersion, minMicroVersion, versionString));
-        }
-
-        return true; // no error!
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkBuilder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkBuilder.java
deleted file mode 100644
index 96068c2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkBuilder.java
+++ /dev/null
@@ -1,1128 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.jarutils.DebugKeyProvider;
-import com.android.jarutils.JavaResourceFilter;
-import com.android.jarutils.SignedJarBuilder;
-import com.android.jarutils.DebugKeyProvider.IKeyGenOutput;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-import com.android.jarutils.SignedJarBuilder.IZipEntryFilter;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jface.preference.IPreferenceStore;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintStream;
-import java.security.GeneralSecurityException;
-import java.security.PrivateKey;
-import java.security.cert.X509Certificate;
-import java.text.DateFormat;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-public class ApkBuilder extends BaseBuilder {
-
-    public static final String ID = "com.android.ide.eclipse.adt.ApkBuilder"; //$NON-NLS-1$
-
-    private static final String PROPERTY_CONVERT_TO_DEX = "convertToDex"; //$NON-NLS-1$
-    private static final String PROPERTY_PACKAGE_RESOURCES = "packageResources"; //$NON-NLS-1$
-    private static final String PROPERTY_BUILD_APK = "buildApk"; //$NON-NLS-1$
-
-    private static final String DX_PREFIX = "Dx"; //$NON-NLS-1$
-
-    /**
-     * Dex conversion flag. This is set to true if one of the changed/added/removed
-     * file is a .class file. Upon visiting all the delta resource, if this
-     * flag is true, then we know we'll have to make the "classes.dex" file.
-     */
-    private boolean mConvertToDex = false;
-
-    /**
-     * Package resources flag. This is set to true if one of the changed/added/removed
-     * file is a resource file. Upon visiting all the delta resource, if
-     * this flag is true, then we know we'll have to repackage the resources.
-     */
-    private boolean mPackageResources = false;
-
-    /**
-     * Final package build flag.
-     */
-    private boolean mBuildFinalPackage = false;
-
-    private PrintStream mOutStream = null;
-    private PrintStream mErrStream = null;
-
-    /**
-     * Basic Resource Delta Visitor class to check if a referenced project had a change in its
-     * compiled java files.
-     */
-    private static class ReferencedProjectDeltaVisitor implements IResourceDeltaVisitor {
-
-        private boolean mConvertToDex = false;
-        private boolean mMakeFinalPackage;
-        
-        private IPath mOutputFolder;
-        private ArrayList<IPath> mSourceFolders;
-        
-        private ReferencedProjectDeltaVisitor(IJavaProject javaProject) {
-            try {
-                mOutputFolder = javaProject.getOutputLocation();
-                mSourceFolders = BaseProjectHelper.getSourceClasspaths(javaProject);
-            } catch (JavaModelException e) {
-            } finally {
-            }
-        }
-
-        /**
-         * {@inheritDoc}
-         * @throws CoreException
-         */
-        public boolean visit(IResourceDelta delta) throws CoreException {
-            //  no need to keep looking if we already know we need to convert
-            // to dex and make the final package.
-            if (mConvertToDex && mMakeFinalPackage) {
-                return false;
-            }
-            
-            // get the resource and the path segments.
-            IResource resource = delta.getResource();
-            IPath resourceFullPath = resource.getFullPath();
-            
-            if (mOutputFolder.isPrefixOf(resourceFullPath)) {
-                int type = resource.getType();
-                if (type == IResource.FILE) {
-                    String ext = resource.getFileExtension();
-                    if (AndroidConstants.EXT_CLASS.equals(ext)) {
-                        mConvertToDex = true;
-                    }
-                }
-                return true;
-            } else {
-                for (IPath sourceFullPath : mSourceFolders) {
-                    if (sourceFullPath.isPrefixOf(resourceFullPath)) {
-                        int type = resource.getType();
-                        if (type == IResource.FILE) {
-                            // check if the file is a valid file that would be
-                            // included during the final packaging.
-                            if (checkFileForPackaging((IFile)resource)) {
-                                mMakeFinalPackage = true;
-                            }
-                            
-                            return false;
-                        } else if (type == IResource.FOLDER) {
-                            // if this is a folder, we check if this is a valid folder as well.
-                            // If this is a folder that needs to be ignored, we must return false,
-                            // so that we ignore its content.
-                            return checkFolderForPackaging((IFolder)resource);
-                        }
-                    }
-                }
-            }
-            
-            return true;
-        }
-
-        /**
-         * Returns if one of the .class file was modified.
-         */
-        boolean needDexConvertion() {
-            return mConvertToDex;
-        }
-        
-        boolean needMakeFinalPackage() {
-            return mMakeFinalPackage;
-        }
-    }
-
-    /**
-     * {@link IZipEntryFilter} to filter out everything that is not a standard java resources.
-     * <p/>Used in {@link SignedJarBuilder#writeZip(java.io.InputStream, IZipEntryFilter)} when
-     * we only want the java resources from external jars.
-     */
-    private final IZipEntryFilter mJavaResourcesFilter = new JavaResourceFilter();
-
-    public ApkBuilder() {
-        super();
-    }
-
-    // build() returns a list of project from which this project depends for future compilation.
-    @SuppressWarnings("unchecked") //$NON-NLS-1$
-    @Override
-    protected IProject[] build(int kind, Map args, IProgressMonitor monitor)
-            throws CoreException {
-        // get a project object
-        IProject project = getProject();
-
-        // get the list of referenced projects.
-        IProject[] referencedProjects = ProjectHelper.getReferencedProjects(project);
-        IJavaProject[] referencedJavaProjects = getJavaProjects(referencedProjects);
-
-        // get the output folder, this method returns the path with a trailing
-        // separator
-        IJavaProject javaProject = JavaCore.create(project);
-        IFolder outputFolder = BaseProjectHelper.getOutputFolder(project);
-
-        // now we need to get the classpath list
-        ArrayList<IPath> sourceList = BaseProjectHelper.getSourceClasspaths(javaProject);
-
-        // First thing we do is go through the resource delta to not
-        // lose it if we have to abort the build for any reason.
-        ApkDeltaVisitor dv = null;
-        if (kind == FULL_BUILD) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Start_Full_Apk_Build);
-
-            mPackageResources = true;
-            mConvertToDex = true;
-            mBuildFinalPackage = true;
-        } else {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Start_Inc_Apk_Build);
-
-            // go through the resources and see if something changed.
-            IResourceDelta delta = getDelta(project);
-            if (delta == null) {
-                mPackageResources = true;
-                mConvertToDex = true;
-                mBuildFinalPackage = true;
-            } else {
-                dv = new ApkDeltaVisitor(this, sourceList, outputFolder);
-                delta.accept(dv);
-
-                // save the state
-                mPackageResources |= dv.getPackageResources();
-                mConvertToDex |= dv.getConvertToDex();
-                mBuildFinalPackage |= dv.getMakeFinalPackage();
-            }
-
-            // also go through the delta for all the referenced projects, until we are forced to
-            // compile anyway
-            for (int i = 0 ; i < referencedJavaProjects.length &&
-                    (mBuildFinalPackage == false || mConvertToDex == false); i++) {
-                IJavaProject referencedJavaProject = referencedJavaProjects[i];
-                delta = getDelta(referencedJavaProject.getProject());
-                if (delta != null) {
-                    ReferencedProjectDeltaVisitor refProjectDv = new ReferencedProjectDeltaVisitor(
-                            referencedJavaProject);
-                    delta.accept(refProjectDv);
-
-                    // save the state
-                    mConvertToDex |= refProjectDv.needDexConvertion();
-                    mBuildFinalPackage |= refProjectDv.needMakeFinalPackage();
-                }
-            }
-        }
-
-        // do some extra check, in case the output files are not present. This
-        // will force to recreate them.
-        IResource tmp = null;
-
-        if (mPackageResources == false && outputFolder != null) {
-            tmp = outputFolder.findMember(AndroidConstants.FN_RESOURCES_AP_);
-            if (tmp == null || tmp.exists() == false) {
-                mPackageResources = true;
-                mBuildFinalPackage = true;
-            }
-        }
-        if (mConvertToDex == false && outputFolder != null) {
-            tmp = outputFolder.findMember(AndroidConstants.FN_CLASSES_DEX);
-            if (tmp == null || tmp.exists() == false) {
-                mConvertToDex = true;
-                mBuildFinalPackage = true;
-            }
-        }
-
-        // get the extra configs for the project. This will give us a list of custom apk
-        // to build based on a restricted set of resources.
-        Map<String, String> configs = Sdk.getCurrent().getProjectApkConfigs(project);
-
-        // also check the final file(s)!
-        String finalPackageName = getFileName(project, null /*config*/);
-        if (mBuildFinalPackage == false && outputFolder != null) {
-            tmp = outputFolder.findMember(finalPackageName);
-            if (tmp == null || (tmp instanceof IFile &&
-                    tmp.exists() == false)) {
-                String msg = String.format(Messages.s_Missing_Repackaging, finalPackageName);
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, msg);
-                mBuildFinalPackage = true;
-            }
-
-            if (configs != null) {
-                Set<Entry<String, String>> entrySet = configs.entrySet();
-                
-                for (Entry<String, String> entry : entrySet) {
-                    String filename = getFileName(project, entry.getKey());
-
-                    tmp = outputFolder.findMember(filename);
-                    if (tmp == null || (tmp instanceof IFile &&
-                            tmp.exists() == false)) {
-                        String msg = String.format(Messages.s_Missing_Repackaging,
-                                finalPackageName);
-                        AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, msg);
-                        mBuildFinalPackage = true;
-                        break;
-                    }
-                }
-            }
-        }
-
-        // store the build status in the persistent storage
-        saveProjectBooleanProperty(PROPERTY_CONVERT_TO_DEX , mConvertToDex);
-        saveProjectBooleanProperty(PROPERTY_PACKAGE_RESOURCES, mPackageResources);
-        saveProjectBooleanProperty(PROPERTY_BUILD_APK, mBuildFinalPackage);
-
-        // At this point, we can abort the build if we have to, as we have computed
-        // our resource delta and stored the result.
-        abortOnBadSetup(project);
-        
-        if (dv != null && dv.mXmlError) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-            Messages.Xml_Error);
-
-            // if there was some XML errors, we just return w/o doing
-            // anything since we've put some markers in the files anyway
-            return referencedProjects;
-        }
-
-        if (outputFolder == null) {
-            // mark project and exit
-            markProject(AdtConstants.MARKER_ADT, Messages.Failed_To_Get_Output,
-                    IMarker.SEVERITY_ERROR);
-            return referencedProjects;
-        }
-
-        // first thing we do is check that the SDK directory has been setup.
-        String osSdkFolder = AdtPlugin.getOsSdkFolder();
-
-        if (osSdkFolder.length() == 0) {
-            // this has already been checked in the precompiler. Therefore,
-            // while we do have to cancel the build, we don't have to return
-            // any error or throw anything.
-            return referencedProjects;
-        }
-
-        // at this point we know if we need to recreate the temporary apk
-        // or the dex file, but we don't know if we simply need to recreate them
-        // because they are missing
-
-        // refresh the output directory first
-        IContainer ic = outputFolder.getParent();
-        if (ic != null) {
-            ic.refreshLocal(IResource.DEPTH_ONE, monitor);
-        }
-
-        // we need to test all three, as we may need to make the final package
-        // but not the intermediary ones.
-        if (mPackageResources || mConvertToDex || mBuildFinalPackage) {
-            IPath binLocation = outputFolder.getLocation();
-            if (binLocation == null) {
-                markProject(AdtConstants.MARKER_ADT, Messages.Output_Missing,
-                        IMarker.SEVERITY_ERROR);
-                return referencedProjects;
-            }
-            String osBinPath = binLocation.toOSString();
-
-            // Remove the old .apk.
-            // This make sure that if the apk is corrupted, then dx (which would attempt
-            // to open it), will not fail.
-            String osFinalPackagePath = osBinPath + File.separator + finalPackageName;
-            File finalPackage = new File(osFinalPackagePath);
-
-            // if delete failed, this is not really a problem, as the final package generation
-            // handle already present .apk, and if that one failed as well, the user will be
-            // notified.
-            finalPackage.delete();
-            
-            if (configs != null) {
-                Set<Entry<String, String>> entrySet = configs.entrySet();
-                for (Entry<String, String> entry : entrySet) {
-                    String packageFilepath = osBinPath + File.separator +
-                            getFileName(project, entry.getKey());
-
-                    finalPackage = new File(packageFilepath);
-                    finalPackage.delete();
-                }
-            }
-
-            // first we check if we need to package the resources.
-            if (mPackageResources) {
-                // need to figure out some path before we can execute aapt;
-
-                // resource to the AndroidManifest.xml file
-                IResource manifestResource = project .findMember(
-                        AndroidConstants.WS_SEP + AndroidConstants.FN_ANDROID_MANIFEST);
-
-                if (manifestResource == null
-                        || manifestResource.exists() == false) {
-                    // mark project and exit
-                    String msg = String.format(Messages.s_File_Missing,
-                            AndroidConstants.FN_ANDROID_MANIFEST);
-                    markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-                    return referencedProjects;
-                }
-
-                // get the resource folder
-                IFolder resFolder = project.getFolder(
-                        AndroidConstants.WS_RESOURCES);
-
-                // and the assets folder
-                IFolder assetsFolder = project.getFolder(
-                        AndroidConstants.WS_ASSETS);
-
-                // we need to make sure this one exists.
-                if (assetsFolder.exists() == false) {
-                    assetsFolder = null;
-                }
-
-                IPath resLocation = resFolder.getLocation();
-                IPath manifestLocation = manifestResource.getLocation();
-
-                if (resLocation != null && manifestLocation != null) {
-                    String osResPath = resLocation.toOSString();
-                    String osManifestPath = manifestLocation.toOSString();
-
-                    String osAssetsPath = null;
-                    if (assetsFolder != null) {
-                        osAssetsPath = assetsFolder.getLocation().toOSString();
-                    }
-
-                    // build the default resource package
-                    if (executeAapt(project, osManifestPath, osResPath,
-                            osAssetsPath, osBinPath + File.separator +
-                            AndroidConstants.FN_RESOURCES_AP_, null /*configFilter*/) == false) {
-                        // aapt failed. Whatever files that needed to be marked
-                        // have already been marked. We just return.
-                        return referencedProjects;
-                    }
-                    
-                    // now do the same thing for all the configured resource packages.
-                    if (configs != null) {
-                        Set<Entry<String, String>> entrySet = configs.entrySet();
-                        for (Entry<String, String> entry : entrySet) {
-                            String outPathFormat = osBinPath + File.separator +
-                                    AndroidConstants.FN_RESOURCES_S_AP_;
-                            String outPath = String.format(outPathFormat, entry.getKey());
-                            if (executeAapt(project, osManifestPath, osResPath,
-                                    osAssetsPath, outPath, entry.getValue()) == false) {
-                                // aapt failed. Whatever files that needed to be marked
-                                // have already been marked. We just return.
-                                return referencedProjects;
-                            }
-                        }
-                    }
-
-                    // build has been done. reset the state of the builder
-                    mPackageResources = false;
-
-                    // and store it
-                    saveProjectBooleanProperty(PROPERTY_PACKAGE_RESOURCES, mPackageResources);
-                }
-            }
-
-            // then we check if we need to package the .class into classes.dex
-            if (mConvertToDex) {
-                if (executeDx(javaProject, osBinPath, osBinPath + File.separator +
-                        AndroidConstants.FN_CLASSES_DEX, referencedJavaProjects) == false) {
-                    // dx failed, we return
-                    return referencedProjects;
-                }
-
-                // build has been done. reset the state of the builder
-                mConvertToDex = false;
-
-                // and store it
-                saveProjectBooleanProperty(PROPERTY_CONVERT_TO_DEX, mConvertToDex);
-            }
-
-            // now we need to make the final package from the intermediary apk
-            // and classes.dex.
-            // This is the default package with all the resources.
-            
-            String classesDexPath = osBinPath + File.separator + AndroidConstants.FN_CLASSES_DEX; 
-            if (finalPackage(osBinPath + File.separator + AndroidConstants.FN_RESOURCES_AP_,
-                            classesDexPath,osFinalPackagePath, javaProject,
-                            referencedJavaProjects) == false) {
-                return referencedProjects;
-            }
-            
-            // now do the same thing for all the configured resource packages.
-            if (configs != null) {
-                String resPathFormat = osBinPath + File.separator +
-                        AndroidConstants.FN_RESOURCES_S_AP_;
-
-                Set<Entry<String, String>> entrySet = configs.entrySet();
-                for (Entry<String, String> entry : entrySet) {
-                    // make the filename for the resource package.
-                    String resPath = String.format(resPathFormat, entry.getKey());
-                    
-                    // make the filename for the apk to generate
-                    String apkOsFilePath = osBinPath + File.separator +
-                            getFileName(project, entry.getKey());
-                    if (finalPackage(resPath, classesDexPath, apkOsFilePath, javaProject,
-                            referencedJavaProjects) == false) {
-                        return referencedProjects;
-                    }
-                }
-            }
-
-            // we are done.
-            
-            // get the resource to bin
-            outputFolder.refreshLocal(IResource.DEPTH_ONE, monitor);
-
-            // build has been done. reset the state of the builder
-            mBuildFinalPackage = false;
-
-            // and store it
-            saveProjectBooleanProperty(PROPERTY_BUILD_APK, mBuildFinalPackage);
-            
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                    "Build Success!");
-        }
-        return referencedProjects;
-    }
-
-
-    @Override
-    protected void startupOnInitialize() {
-        super.startupOnInitialize();
-
-        // load the build status. We pass true as the default value to
-        // force a recompile in case the property was not found
-        mConvertToDex = loadProjectBooleanProperty(PROPERTY_CONVERT_TO_DEX , true);
-        mPackageResources = loadProjectBooleanProperty(PROPERTY_PACKAGE_RESOURCES, true);
-        mBuildFinalPackage = loadProjectBooleanProperty(PROPERTY_BUILD_APK, true);
-    }
-
-    /**
-     * Executes aapt. If any error happen, files or the project will be marked.
-     * @param project The Project
-     * @param osManifestPath The path to the manifest file
-     * @param osResPath The path to the res folder
-     * @param osAssetsPath The path to the assets folder. This can be null.
-     * @param osOutFilePath The path to the temporary resource file to create.
-     * @param configFilter The configuration filter for the resources to include
-     * (used with -c option)
-     * @return true if success, false otherwise.
-     */
-    private boolean executeAapt(IProject project, String osManifestPath,
-            String osResPath, String osAssetsPath, String osOutFilePath, String configFilter) {
-        IAndroidTarget target = Sdk.getCurrent().getTarget(project);
-
-        // Create the command line.
-        ArrayList<String> commandArray = new ArrayList<String>();
-        commandArray.add(target.getPath(IAndroidTarget.AAPT));
-        commandArray.add("package"); //$NON-NLS-1$
-        commandArray.add("-f");//$NON-NLS-1$
-        if (AdtPlugin.getBuildVerbosity() == AdtConstants.BUILD_VERBOSE) {
-            commandArray.add("-v"); //$NON-NLS-1$
-        }
-        if (configFilter != null) {
-            commandArray.add("-c"); //$NON-NLS-1$
-            commandArray.add(configFilter);
-        }
-        commandArray.add("-M"); //$NON-NLS-1$
-        commandArray.add(osManifestPath);
-        commandArray.add("-S"); //$NON-NLS-1$
-        commandArray.add(osResPath);
-        if (osAssetsPath != null) {
-            commandArray.add("-A"); //$NON-NLS-1$
-            commandArray.add(osAssetsPath);
-        }
-        commandArray.add("-I"); //$NON-NLS-1$
-        commandArray.add(target.getPath(IAndroidTarget.ANDROID_JAR));
-        commandArray.add("-F"); //$NON-NLS-1$
-        commandArray.add(osOutFilePath);
-
-        String command[] = commandArray.toArray(
-                new String[commandArray.size()]);
-        
-        if (AdtPlugin.getBuildVerbosity() == AdtConstants.BUILD_VERBOSE) {
-            StringBuilder sb = new StringBuilder();
-            for (String c : command) {
-                sb.append(c);
-                sb.append(' ');
-            }
-            AdtPlugin.printToConsole(project, sb.toString());
-        }
-
-        // launch
-        int execError = 1;
-        try {
-            // launch the command line process
-            Process process = Runtime.getRuntime().exec(command);
-
-            // list to store each line of stderr
-            ArrayList<String> results = new ArrayList<String>();
-
-            // get the output and return code from the process
-            execError = grabProcessOutput(process, results);
-
-            // attempt to parse the error output
-            boolean parsingError = parseAaptOutput(results, project);
-
-            // if we couldn't parse the output we display it in the console.
-            if (parsingError) {
-                if (execError != 0) {
-                    AdtPlugin.printErrorToConsole(project, results.toArray());
-                } else {
-                    AdtPlugin.printBuildToConsole(AdtConstants.BUILD_ALWAYS, project,
-                            results.toArray());
-                }
-            }
-
-            // We need to abort if the exec failed.
-            if (execError != 0) {
-                // if the exec failed, and we couldn't parse the error output (and therefore
-                // not all files that should have been marked, were marked), we put a generic
-                // marker on the project and abort.
-                if (parsingError) {
-                    markProject(AdtConstants.MARKER_ADT, Messages.Unparsed_AAPT_Errors,
-                            IMarker.SEVERITY_ERROR);
-                }
-
-                // abort if exec failed.
-                return false;
-            }
-        } catch (IOException e1) {
-            String msg = String.format(Messages.AAPT_Exec_Error, command[0]);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        } catch (InterruptedException e) {
-            String msg = String.format(Messages.AAPT_Exec_Error, command[0]);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Execute the Dx tool for dalvik code conversion.
-     * @param javaProject The java project
-     * @param osBinPath the path to the output folder of the project
-     * @param osOutFilePath the path of the dex file to create.
-     * @param referencedJavaProjects the list of referenced projects for this project.
-     *
-     * @throws CoreException
-     */
-    private boolean executeDx(IJavaProject javaProject, String osBinPath, String osOutFilePath,
-            IJavaProject[] referencedJavaProjects) throws CoreException {
-        IAndroidTarget target = Sdk.getCurrent().getTarget(javaProject.getProject());
-        AndroidTargetData targetData = Sdk.getCurrent().getTargetData(target);
-        if (targetData == null) {
-            throw new CoreException(new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                    Messages.ApkBuilder_UnableBuild_Dex_Not_loaded));
-        }
-        
-        // get the dex wrapper
-        DexWrapper wrapper = targetData.getDexWrapper();
-        
-        if (wrapper == null) {
-            throw new CoreException(new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                    Messages.ApkBuilder_UnableBuild_Dex_Not_loaded));
-        }
-
-        // make sure dx use the proper output streams.
-        // first make sure we actually have the streams available.
-        if (mOutStream == null) {
-            IProject project = getProject();
-            mOutStream = AdtPlugin.getOutPrintStream(project, DX_PREFIX);
-            mErrStream = AdtPlugin.getErrPrintStream(project, DX_PREFIX);
-        }
-
-        try {
-            // get the list of libraries to include with the source code
-            String[] libraries = getExternalJars();
-
-            // get the list of referenced projects output to add
-            String[] projectOutputs = getProjectOutputs(referencedJavaProjects);
-            
-            String[] fileNames = new String[1 + projectOutputs.length + libraries.length];
-
-            // first this project output
-            fileNames[0] = osBinPath;
-
-            // then other project output
-            System.arraycopy(projectOutputs, 0, fileNames, 1, projectOutputs.length);
-
-            // then external jars.
-            System.arraycopy(libraries, 0, fileNames, 1 + projectOutputs.length, libraries.length);
-            
-            int res = wrapper.run(osOutFilePath, fileNames,
-                    AdtPlugin.getBuildVerbosity() == AdtConstants.BUILD_VERBOSE,
-                    mOutStream, mErrStream);
-
-            if (res != 0) {
-                // output error message and marker the project.
-                String message = String.format(Messages.Dalvik_Error_d,
-                        res);
-                AdtPlugin.printErrorToConsole(getProject(), message);
-                markProject(AdtConstants.MARKER_ADT, message, IMarker.SEVERITY_ERROR);
-                return false;
-            }
-        } catch (Throwable ex) {
-            String message = ex.getMessage();
-            if (message == null) {
-                message = ex.getClass().getCanonicalName();
-            }
-            message = String.format(Messages.Dalvik_Error_s, message);
-            AdtPlugin.printErrorToConsole(getProject(), message);
-            markProject(AdtConstants.MARKER_ADT, message, IMarker.SEVERITY_ERROR);
-            if ((ex instanceof NoClassDefFoundError)
-                    || (ex instanceof NoSuchMethodError)) {
-                AdtPlugin.printErrorToConsole(getProject(), Messages.Incompatible_VM_Warning,
-                        Messages.Requires_1_5_Error);
-            }
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Makes the final package. Package the dex files, the temporary resource file into the final
-     * package file.
-     * @param intermediateApk The path to the temporary resource file.
-     * @param dex The path to the dex file.
-     * @param output The path to the final package file to create.
-     * @param javaProject
-     * @param referencedJavaProjects
-     * @return true if success, false otherwise.
-     */
-    private boolean finalPackage(String intermediateApk, String dex, String output,
-            final IJavaProject javaProject, IJavaProject[] referencedJavaProjects) {
-        FileOutputStream fos = null;
-        try {
-            IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-            String osKeyPath = store.getString(AdtPlugin.PREFS_CUSTOM_DEBUG_KEYSTORE);
-            if (osKeyPath == null || new File(osKeyPath).exists() == false) {
-                osKeyPath = DebugKeyProvider.getDefaultKeyStoreOsPath();
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                        Messages.ApkBuilder_Using_Default_Key);
-            } else {
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                        String.format(Messages.ApkBuilder_Using_s_To_Sign, osKeyPath));
-            }
-            
-            // TODO: get the store type from somewhere else.
-            DebugKeyProvider provider = new DebugKeyProvider(osKeyPath, null /* storeType */,
-                    new IKeyGenOutput() {
-                        public void err(String message) {
-                            AdtPlugin.printErrorToConsole(javaProject.getProject(),
-                                    Messages.ApkBuilder_Signing_Key_Creation_s + message);
-                        }
-
-                        public void out(String message) {
-                            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE,
-                                    javaProject.getProject(),
-                                    Messages.ApkBuilder_Signing_Key_Creation_s + message);
-                        }
-            });
-            PrivateKey key = provider.getDebugKey();
-            X509Certificate certificate = (X509Certificate)provider.getCertificate();
-            
-            if (key == null) {
-                String msg = String.format(Messages.Final_Archive_Error_s,
-                        Messages.ApkBuilder_Unable_To_Gey_Key);
-                AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-                markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-                return false;
-            }
-            
-            // compare the certificate expiration date
-            if (certificate != null && certificate.getNotAfter().compareTo(new Date()) < 0) {
-                // TODO, regenerate a new one.
-                String msg = String.format(Messages.Final_Archive_Error_s,
-                    String.format(Messages.ApkBuilder_Certificate_Expired_on_s, 
-                            DateFormat.getInstance().format(certificate.getNotAfter())));
-                AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-                markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-                return false;
-            }
-
-            // create the jar builder.
-            fos = new FileOutputStream(output);
-            SignedJarBuilder builder = new SignedJarBuilder(fos, key, certificate);
-            
-            // add the intermediate file containing the compiled resources.
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                    String.format(Messages.ApkBuilder_Packaging_s, intermediateApk));
-            FileInputStream fis = new FileInputStream(intermediateApk);
-            try {
-                builder.writeZip(fis, null /* filter */);
-            } finally {
-                fis.close();
-            }
-            
-            // Now we add the new file to the zip archive for the classes.dex file.
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                    String.format(Messages.ApkBuilder_Packaging_s, AndroidConstants.FN_CLASSES_DEX));
-            File entryFile = new File(dex);
-            builder.writeFile(entryFile, AndroidConstants.FN_CLASSES_DEX);
-
-            // Now we write the standard resources from the project and the referenced projects.
-            writeStandardResources(builder, javaProject, referencedJavaProjects);
-            
-            // Now we write the standard resources from the external libraries
-            for (String libraryOsPath : getExternalJars()) {
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                        String.format(Messages.ApkBuilder_Packaging_s, libraryOsPath));
-                try {
-                    fis = new FileInputStream(libraryOsPath);
-                    builder.writeZip(fis, mJavaResourcesFilter);
-                } finally {
-                    fis.close();
-                }
-            }
-
-            // now write the native libraries.
-            // First look if the lib folder is there.
-            IResource libFolder = javaProject.getProject().findMember(SdkConstants.FD_NATIVE_LIBS);
-            if (libFolder != null && libFolder.exists() &&
-                    libFolder.getType() == IResource.FOLDER) {
-                // look inside and put .so in lib/* by keeping the relative folder path.
-                writeNativeLibraries(libFolder.getFullPath().segmentCount(), builder, libFolder);
-            }
-
-            // close the jar file and write the manifest and sign it.
-            builder.close();
-        } catch (GeneralSecurityException e1) {
-            // mark project and return
-            String msg = String.format(Messages.Final_Archive_Error_s, e1.getMessage());
-            AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        } catch (IOException e1) {
-            // mark project and return
-            String msg = String.format(Messages.Final_Archive_Error_s, e1.getMessage());
-            AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        } catch (KeytoolException e) {
-            String eMessage = e.getMessage();
-
-            // mark the project with the standard message
-            String msg = String.format(Messages.Final_Archive_Error_s, eMessage);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-
-            // output more info in the console
-            AdtPlugin.printErrorToConsole(javaProject.getProject(),
-                    msg,
-                    String.format(Messages.ApkBuilder_JAVA_HOME_is_s, e.getJavaHome()),
-                    Messages.ApkBuilder_Update_or_Execute_manually_s,
-                    e.getCommandLine());
-        } catch (AndroidLocationException e) {
-            String eMessage = e.getMessage();
-
-            // mark the project with the standard message
-            String msg = String.format(Messages.Final_Archive_Error_s, eMessage);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-
-            // and also output it in the console
-            AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-        } catch (CoreException e) {
-            // mark project and return
-            String msg = String.format(Messages.Final_Archive_Error_s, e.getMessage());
-            AdtPlugin.printErrorToConsole(javaProject.getProject(), msg);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        } finally {
-            if (fos != null) {
-                try {
-                    fos.close();
-                } catch (IOException e) {
-                    // pass.
-                }
-            }
-        }
-
-        return true;
-    }
-    
-    /**
-     * Writes native libraries into a {@link SignedJarBuilder}.
-     * <p/>This recursively go through folder and writes .so files. 
-     * The path in the archive is based on the root folder containing the libraries in the project.
-     * Its segment count is passed to the method to compute the resources path relative to the root
-     * folder.
-     * Native libraries in the archive must be in a "lib" folder. Everything in the project native
-     * lib folder directly goes in this "lib" folder in the archive.
-     * 
-     *  
-     * @param rootSegmentCount The number of segment of the path of the folder containing the
-     * libraries. This is used to compute the path in the archive.
-     * @param jarBuilder the {@link SignedJarBuilder} used to create the archive.
-     * @param resource the IResource to write.
-     * @throws CoreException
-     * @throws IOException 
-     */
-    private void writeNativeLibraries(int rootSegmentCount, SignedJarBuilder jarBuilder,
-            IResource resource) throws CoreException, IOException {
-        if (resource.getType() == IResource.FILE) {
-            IPath path = resource.getFullPath();
-
-            // check the extension.
-            if (path.getFileExtension().equalsIgnoreCase(AndroidConstants.EXT_NATIVE_LIB)) {
-                // remove the first segment to build the path inside the archive.
-                path = path.removeFirstSegments(rootSegmentCount);
-                
-                // add it to the archive.
-                IPath apkPath = new Path(SdkConstants.FD_APK_NATIVE_LIBS);
-                apkPath = apkPath.append(path);
-                
-                // writes the file in the apk.
-                jarBuilder.writeFile(resource.getLocation().toFile(), apkPath.toString());
-            }
-        } else if (resource.getType() == IResource.FOLDER) {
-            IResource[] members = ((IFolder)resource).members();
-            for (IResource member : members) {
-                writeNativeLibraries(rootSegmentCount, jarBuilder, member);
-            }
-        }
-    }
-
-    /**
-     * Writes the standard resources of a project and its referenced projects
-     * into a {@link SignedJarBuilder}.
-     * Standard resources are non java/aidl files placed in the java package folders.
-     * @param jarBuilder the {@link SignedJarBuilder}.
-     * @param javaProject the javaProject object.
-     * @param referencedJavaProjects the java projects that this project references.
-     * @throws IOException 
-     */
-    private void writeStandardResources(SignedJarBuilder jarBuilder, IJavaProject javaProject,
-            IJavaProject[] referencedJavaProjects) throws IOException {
-        IWorkspace ws = ResourcesPlugin.getWorkspace();
-        IWorkspaceRoot wsRoot = ws.getRoot();
-        
-        // create a list of path already put into the archive, in order to detect conflict
-        ArrayList<String> list = new ArrayList<String>();
-
-        writeStandardProjectResources(jarBuilder, javaProject, wsRoot, list);
-        
-        for (IJavaProject referencedJavaProject : referencedJavaProjects) {
-            writeStandardProjectResources(jarBuilder, referencedJavaProject, wsRoot, list);
-        }
-    }
-    
-    /**
-     * Writes the standard resources of a {@link IJavaProject} into a {@link SignedJarBuilder}.
-     * Standard resources are non java/aidl files placed in the java package folders.
-     * @param jarBuilder the {@link SignedJarBuilder}.
-     * @param javaProject the javaProject object.
-     * @param wsRoot the {@link IWorkspaceRoot}.
-     * @param list a list of files already added to the archive, to detect conflicts.
-     * @throws IOException
-     */
-    private void writeStandardProjectResources(SignedJarBuilder jarBuilder,
-            IJavaProject javaProject, IWorkspaceRoot wsRoot, ArrayList<String> list)
-            throws IOException {
-        // get the source pathes
-        ArrayList<IPath> sourceFolders = BaseProjectHelper.getSourceClasspaths(javaProject);
-        
-        // loop on them and then recursively go through the content looking for matching files.
-        for (IPath sourcePath : sourceFolders) {
-            IResource sourceResource = wsRoot.findMember(sourcePath);
-            if (sourceResource != null && sourceResource.getType() == IResource.FOLDER) {
-                writeStandardSourceFolderResources(jarBuilder, sourcePath, (IFolder)sourceResource,
-                        list);
-            }
-        }
-    }
-
-    /**
-     * Recursively writes the standard resources of a source folder into a {@link SignedJarBuilder}.
-     * Standard resources are non java/aidl files placed in the java package folders.
-     * @param jarBuilder the {@link SignedJarBuilder}.
-     * @param sourceFolder the {@link IPath} of the source folder.
-     * @param currentFolder The current folder we're recursively processing.
-     * @param list a list of files already added to the archive, to detect conflicts.
-     * @throws IOException
-     */
-    private void writeStandardSourceFolderResources(SignedJarBuilder jarBuilder, IPath sourceFolder,
-            IFolder currentFolder, ArrayList<String> list) throws IOException {
-        try {
-            IResource[] members = currentFolder.members();
-            
-            for (IResource member : members) {
-                int type = member.getType(); 
-                if (type == IResource.FILE && member.exists()) {
-                    if (checkFileForPackaging((IFile)member)) {
-                        // this files must be added to the archive.
-                        IPath fullPath = member.getFullPath();
-                        
-                        // We need to create its path inside the archive.
-                        // This path is relative to the source folder.
-                        IPath relativePath = fullPath.removeFirstSegments(
-                                sourceFolder.segmentCount());
-                        String zipPath = relativePath.toString();
-                        
-                        // lets check it's not already in the list of path added to the archive
-                        if (list.indexOf(zipPath) != -1) {
-                            AdtPlugin.printErrorToConsole(getProject(),
-                                    String.format(
-                                            Messages.ApkBuilder_s_Conflict_with_file_s,
-                                            fullPath, zipPath));
-                        } else {
-                            // get the File object
-                            File entryFile = member.getLocation().toFile();
-
-                            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                                    String.format(Messages.ApkBuilder_Packaging_s_into_s, fullPath, zipPath));
-
-                            // write it in the zip archive
-                            jarBuilder.writeFile(entryFile, zipPath);
-
-                            // and add it to the list of entries
-                            list.add(zipPath);
-                        }
-                    }
-                } else if (type == IResource.FOLDER) {
-                    if (checkFolderForPackaging((IFolder)member)) {
-                        writeStandardSourceFolderResources(jarBuilder, sourceFolder,
-                                (IFolder)member, list);
-                    }
-                }
-            }
-        } catch (CoreException e) {
-            // if we can't get the members of the folder, we just don't do anything.
-        }
-    }
-
-    /**
-     * Returns the list of the output folders for the specified {@link IJavaProject} objects.
-     * @param referencedJavaProjects the java projects.
-     * @return an array, always. Can be empty.
-     * @throws CoreException
-     */
-    private String[] getProjectOutputs(IJavaProject[] referencedJavaProjects) throws CoreException {
-        ArrayList<String> list = new ArrayList<String>();
-
-        IWorkspace ws = ResourcesPlugin.getWorkspace();
-        IWorkspaceRoot wsRoot = ws.getRoot();
-
-        for (IJavaProject javaProject : referencedJavaProjects) {
-            // get the output folder
-            IPath path = null;
-            try {
-                path = javaProject.getOutputLocation();
-            } catch (JavaModelException e) {
-                continue;
-            }
-
-            IResource outputResource = wsRoot.findMember(path);
-            if (outputResource != null && outputResource.getType() == IResource.FOLDER) {
-                String outputOsPath = outputResource.getLocation().toOSString();
-
-                list.add(outputOsPath);
-            }
-        }
-
-        return list.toArray(new String[list.size()]);
-    }
-    
-    /**
-     * Returns an array of {@link IJavaProject} matching the provided {@link IProject} objects.
-     * @param projects the IProject objects.
-     * @return an array, always. Can be empty.
-     * @throws CoreException 
-     */
-    private IJavaProject[] getJavaProjects(IProject[] projects) throws CoreException {
-        ArrayList<IJavaProject> list = new ArrayList<IJavaProject>();
-
-        for (IProject p : projects) {
-            if (p.isOpen() && p.hasNature(JavaCore.NATURE_ID)) {
-
-                list.add(JavaCore.create(p));
-            }
-        }
-
-        return list.toArray(new IJavaProject[list.size()]);
-    }
-    
-    /**
-     * Returns the apk filename for the given project
-     * @param project The project.
-     * @param config An optional config name. Can be null.
-     */
-    private static String getFileName(IProject project, String config) {
-        if (config != null) {
-            return project.getName() + "-" + config + AndroidConstants.DOT_ANDROID_PACKAGE; //$NON-NLS-1$ 
-        }
-        
-        return project.getName() + AndroidConstants.DOT_ANDROID_PACKAGE;
-    }
-
-    /**
-     * Checks a {@link IFile} to make sure it should be packaged as standard resources.
-     * @param file the IFile representing the file.
-     * @return true if the file should be packaged as standard java resources.
-     */
-    static boolean checkFileForPackaging(IFile file) {
-        String name = file.getName();
-        
-        String ext = file.getFileExtension();
-        return JavaResourceFilter.checkFileForPackaging(name, ext);
-    }
-
-    /**
-     * Checks whether an {@link IFolder} and its content is valid for packaging into the .apk as
-     * standard Java resource.
-     * @param folder the {@link IFolder} to check.
-     */
-    static boolean checkFolderForPackaging(IFolder folder) {
-        String name = folder.getName();
-        return JavaResourceFilter.checkFolderForPackaging(name);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkDeltaVisitor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkDeltaVisitor.java
deleted file mode 100644
index 5d6793a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ApkDeltaVisitor.java
+++ /dev/null
@@ -1,280 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.build.BaseBuilder.BaseDeltaVisitor;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-
-import java.util.ArrayList;
-
-/**
- * Delta resource visitor looking for changes that will trigger a new packaging of an Android
- * application.
- * <p/>
- * This looks for the following changes:
- * <ul>
- * <li>Any change to the AndroidManifest.xml file</li>
- * <li>Any change inside the assets/ folder</li>
- * <li>Any file change inside the res/ folder</li>
- * <li>Any .class file change inside the output folder</li>
- * <li>Any change to the classes.dex inside the output folder</li>
- * <li>Any change to the packaged resources file inside the output folder</li>
- * <li>Any change to a non java/aidl file inside the source folders</li>
- * <li>Any change to .so file inside the lib (native library) folder</li>
- * </ul>
- */
-public class ApkDeltaVisitor extends BaseDeltaVisitor
-        implements IResourceDeltaVisitor {
-
-    /**
-     * compile flag. This is set to true if one of the changed/added/removed
-     * file is a .class file. Upon visiting all the delta resources, if this
-     * flag is true, then we know we'll have to make the "classes.dex" file.
-     */
-    private boolean mConvertToDex = false;
-
-    /**
-     * compile flag. This is set to true if one of the changed/added/removed
-     * file is a resource file. Upon visiting all the delta resources, if
-     * this flag is true, then we know we'll have to make the intermediate
-     * apk file.
-     */
-    private boolean mPackageResources = false;
-    
-    /**
-     * Final package flag. This is set to true if one of the changed/added/removed
-     * file is a non java file (or aidl) in the resource folder. Upon visiting all the
-     * delta resources, if this flag is true, then we know we'll have to make the final
-     * package.
-     */
-    private boolean mMakeFinalPackage = false;
-
-    /** List of source folders. */
-    private ArrayList<IPath> mSourceFolders;
-
-    private IPath mOutputPath;
-
-    private IPath mAssetPath;
-
-    private IPath mResPath;
-
-    private IPath mLibFolder;
-
-    /**
-     * Builds the object with a specified output folder.
-     * @param builder the xml builder using this object to visit the
-     *  resource delta.
-     * @param sourceFolders the list of source folders for the project, relative to the workspace.
-     * @param outputfolder the output folder of the project.
-     */
-    public ApkDeltaVisitor(BaseBuilder builder, ArrayList<IPath> sourceFolders,
-            IFolder outputfolder) {
-        super(builder);
-        mSourceFolders = sourceFolders;
-        
-        if (outputfolder != null) {
-            mOutputPath = outputfolder.getFullPath();
-        }
-        
-        IResource assetFolder = builder.getProject().findMember(SdkConstants.FD_ASSETS);
-        if (assetFolder != null) {
-            mAssetPath = assetFolder.getFullPath();
-        }
-
-        IResource resFolder = builder.getProject().findMember(SdkConstants.FD_RESOURCES);
-        if (resFolder != null) {
-            mResPath = resFolder.getFullPath();
-        }
-        
-        IResource libFolder = builder.getProject().findMember(SdkConstants.FD_NATIVE_LIBS);
-        if (libFolder != null) {
-            mLibFolder = libFolder.getFullPath();
-        }
-    }
-
-    public boolean getConvertToDex() {
-        return mConvertToDex;
-    }
-
-    public boolean getPackageResources() {
-        return mPackageResources;
-    }
-    
-    public boolean getMakeFinalPackage() {
-        return mMakeFinalPackage;
-    }
-
-    /**
-     * {@inheritDoc}
-     * @throws CoreException 
-     *
-     * @see org.eclipse.core.resources.IResourceDeltaVisitor
-     *      #visit(org.eclipse.core.resources.IResourceDelta)
-     */
-    public boolean visit(IResourceDelta delta) throws CoreException {
-        // if all flags are true, we can stop going through the resource delta.
-        if (mConvertToDex && mPackageResources && mMakeFinalPackage) {
-            return false;
-        }
-
-        // we are only going to look for changes in res/, src/ and in
-        // AndroidManifest.xml since the delta visitor goes through the main
-        // folder before its childre we can check when the path segment
-        // count is 2 (format will be /$Project/folder) and make sure we are
-        // processing res/, src/ or AndroidManifest.xml
-        IResource resource = delta.getResource();
-        IPath path = resource.getFullPath();
-        String[] pathSegments = path.segments();
-        int type = resource.getType();
-
-        // since the delta visitor also visits the root we return true if
-        // segments.length = 1
-        if (pathSegments.length == 1) {
-            return true;
-        }
-
-        // check the manifest.
-        if (pathSegments.length == 2 &&
-                AndroidConstants.FN_ANDROID_MANIFEST.equalsIgnoreCase(pathSegments[1])) {
-            // if the manifest changed we have to repackage the
-            // resources.
-            mPackageResources = true;
-            mMakeFinalPackage = true;
-
-            // we don't want to go to the children, not like they are
-            // any for this resource anyway.
-            return false;
-        }
-        
-        // check the other folders.
-        if (mOutputPath != null && mOutputPath.isPrefixOf(path)) {
-            // a resource changed inside the output folder.
-            if (type == IResource.FILE) {
-                // just check this is a .class file. Any modification will
-                // trigger a change in the classes.dex file
-                String ext = resource.getFileExtension();
-                if (AndroidConstants.EXT_CLASS.equalsIgnoreCase(ext)) {
-                    mConvertToDex = true;
-                    mMakeFinalPackage = true;
-    
-                    // no need to check the children, as we are in a package
-                    // and there can only be subpackage children containing
-                    // only .class files
-                    return false;
-                }
-
-                // check for a few files directly in the output folder and force
-                // rebuild if they have been deleted.
-                if (delta.getKind() == IResourceDelta.REMOVED) {
-                    IPath parentPath = path.removeLastSegments(1);
-                    if (mOutputPath.equals(parentPath)) {
-                        String resourceName = resource.getName();
-                        // check if classes.dex was removed
-                        if (resourceName.equalsIgnoreCase(AndroidConstants.FN_CLASSES_DEX)) {
-                            mConvertToDex = true;
-                            mMakeFinalPackage = true;
-                        } else if (resourceName.equalsIgnoreCase(
-                                AndroidConstants.FN_RESOURCES_AP_) ||
-                                AndroidConstants.PATTERN_RESOURCES_S_AP_.matcher(
-                                        resourceName).matches()) {
-                            // or if the default resources.ap_ or a configured version
-                            // (resources-###.ap_) was removed.
-                            mPackageResources = true;
-                            mMakeFinalPackage = true;
-                        }
-                    }
-                }
-            }
-
-            // if this is a folder, we only go visit it if we don't already know
-            // that we need to convert to dex already.
-            return mConvertToDex == false;
-        } else if (mResPath != null && mResPath.isPrefixOf(path)) {
-            // in the res folder we are looking for any file modification
-            // (we don't care about folder being added/removed, only content
-            // is important)
-            if (type == IResource.FILE) {
-                mPackageResources = true;
-                mMakeFinalPackage = true;
-                return false;
-            }
-
-            // for folders, return true only if we don't already know we have to
-            // package the resources.
-            return mPackageResources == false;
-        } else if (mAssetPath != null && mAssetPath.isPrefixOf(path)) {
-            // this is the assets folder that was modified.
-            // we don't care what content was changed. All we care
-            // about is that something changed inside. No need to visit
-            // the children even.
-            mPackageResources = true;
-            mMakeFinalPackage = true;
-            return false;
-        } else if (mLibFolder != null && mLibFolder.isPrefixOf(path)) {
-            // inside the native library folder. Test if the changed resource is a .so file.
-            if (type == IResource.FILE &&
-                    path.getFileExtension().equalsIgnoreCase(AndroidConstants.EXT_NATIVE_LIB)) {
-                mMakeFinalPackage = true;
-                return false; // return false for file.
-            }
-
-            // for folders, return true only if we don't already know we have to make the
-            // final package.
-            return mMakeFinalPackage == false;
-        } else {
-            // we are in a folder that is neither the resource folders, nor the output.
-            // check against all the source folders, unless we already know we need to do
-            // the final package.
-            // This could be a source folder or a folder leading to a source folder.
-            // However we only check this if we don't already know that we need to build the
-            // package anyway
-            if (mMakeFinalPackage == false) {
-                for (IPath sourcePath : mSourceFolders) {
-                    if (sourcePath.isPrefixOf(path)) {
-                        // In the source folders, we are looking for any kind of
-                        // modification related to file that are not java files.
-                        // Also excluded are aidl files, and package.html files
-                        if (type == IResource.FOLDER) {
-                            // always visit the subfolders, unless the folder is not to be included
-                            return ApkBuilder.checkFolderForPackaging((IFolder)resource);
-                        } else if (type == IResource.FILE) {
-                            if (ApkBuilder.checkFileForPackaging((IFile)resource)) {
-                                mMakeFinalPackage = true;
-                            }
-
-                            return false;
-                        }
-                        
-                    }
-                }
-            }
-        }
-        
-        // if the folder is not inside one of the folders we are interested in (res, assets, output,
-        // source folders), it could be a folder leading to them, so we return true.
-        return true;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/BaseBuilder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/BaseBuilder.java
deleted file mode 100644
index 6b0810a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/BaseBuilder.java
+++ /dev/null
@@ -1,898 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.LoadStatus;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.common.project.XmlErrorHandler;
-import com.android.ide.eclipse.common.project.XmlErrorHandler.XmlErrorListener;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.IncrementalProjectBuilder;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.xml.sax.SAXException;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * Base builder for XML files. This class allows for basic XML parsing with
- * error checking and marking the files for errors/warnings.
- */
-abstract class BaseBuilder extends IncrementalProjectBuilder {
-
-    // TODO: rename the pattern to something that makes sense + javadoc comments.
-
-    /**
-     * Single line aapt warning for skipping files.<br>
-     * "  (skipping hidden file '&lt;file path&gt;'"
-     */
-    private final static Pattern sPattern0Line1 = Pattern.compile(
-            "^\\s+\\(skipping hidden file\\s'(.*)'\\)$"); //$NON-NLS-1$
-
-    /**
-     * First line of dual line aapt error.<br>
-     * "ERROR at line &lt;line&gt;: &lt;error&gt;"<br>
-     * " (Occurred while parsing &lt;path&gt;)"
-     */
-    private final static Pattern sPattern1Line1 = Pattern.compile(
-            "^ERROR\\s+at\\s+line\\s+(\\d+):\\s+(.*)$"); //$NON-NLS-1$
-    /**
-     * Second line of dual line aapt error.<br>
-     * "ERROR at line &lt;line&gt;: &lt;error&gt;"<br>
-     * " (Occurred while parsing &lt;path&gt;)"<br>
-     * @see #sPattern1Line1
-     */
-    private final static Pattern sPattern1Line2 = Pattern.compile(
-            "^\\s+\\(Occurred while parsing\\s+(.*)\\)$");  //$NON-NLS-1$
-    /**
-     * First line of dual line aapt error.<br>
-     * "ERROR: &lt;error&gt;"<br>
-     * "Defined at file &lt;path&gt; line &lt;line&gt;"
-     */
-    private final static Pattern sPattern2Line1 = Pattern.compile(
-            "^ERROR:\\s+(.+)$"); //$NON-NLS-1$
-    /**
-     * Second line of dual line aapt error.<br>
-     * "ERROR: &lt;error&gt;"<br>
-     * "Defined at file &lt;path&gt; line &lt;line&gt;"<br>
-     * @see #sPattern2Line1
-     */
-    private final static Pattern sPattern2Line2 = Pattern.compile(
-            "Defined\\s+at\\s+file\\s+(.+)\\s+line\\s+(\\d+)"); //$NON-NLS-1$
-    /**
-     * Single line aapt error<br>
-     * "&lt;path&gt; line &lt;line&gt;: &lt;error&gt;"
-     */
-    private final static Pattern sPattern3Line1 = Pattern.compile(
-            "^(.+)\\sline\\s(\\d+):\\s(.+)$"); //$NON-NLS-1$
-    /**
-     * First line of dual line aapt error.<br>
-     * "ERROR parsing XML file &lt;path&gt;"<br>
-     * "&lt;error&gt; at line &lt;line&gt;"
-     */
-    private final static Pattern sPattern4Line1 = Pattern.compile(
-            "^Error\\s+parsing\\s+XML\\s+file\\s(.+)$"); //$NON-NLS-1$
-    /**
-     * Second line of dual line aapt error.<br>
-     * "ERROR parsing XML file &lt;path&gt;"<br>
-     * "&lt;error&gt; at line &lt;line&gt;"<br>
-     * @see #sPattern4Line1
-     */
-    private final static Pattern sPattern4Line2 = Pattern.compile(
-            "^(.+)\\s+at\\s+line\\s+(\\d+)$"); //$NON-NLS-1$
-
-    /**
-     * Single line aapt warning<br>
-     * "&lt;path&gt;:&lt;line&gt;: &lt;error&gt;"
-     */
-    private final static Pattern sPattern5Line1 = Pattern.compile(
-            "^(.+?):(\\d+):\\s+WARNING:(.+)$"); //$NON-NLS-1$
-
-    /**
-     * Single line aapt error<br>
-     * "&lt;path&gt;:&lt;line&gt;: &lt;error&gt;"
-     */
-    private final static Pattern sPattern6Line1 = Pattern.compile(
-            "^(.+?):(\\d+):\\s+(.+)$"); //$NON-NLS-1$
-
-    /**
-     * 4 line aapt error<br>
-     * "ERROR: 9-path image &lt;path&gt; malformed"<br>
-     * Line 2 and 3 are taken as-is while line 4 is ignored (it repeats with<br>
-     * 'ERROR: failure processing &lt;path&gt;)
-     */
-    private final static Pattern sPattern7Line1 = Pattern.compile(
-            "^ERROR:\\s+9-patch\\s+image\\s+(.+)\\s+malformed\\.$"); //$NON-NLS-1$
-    
-    private final static Pattern sPattern8Line1 = Pattern.compile(
-            "^(invalid resource directory name): (.*)$"); //$NON-NLS-1$
-
-    /** SAX Parser factory. */
-    private SAXParserFactory mParserFactory;
-
-    /**
-     * Base Resource Delta Visitor to handle XML error
-     */
-    protected static class BaseDeltaVisitor implements XmlErrorListener {
-
-        /** The Xml builder used to validate XML correctness. */
-        protected BaseBuilder mBuilder;
-
-        /**
-         * XML error flag. if true, we keep parsing the ResourceDelta but the
-         * compilation will not happen (we're putting markers)
-         */
-        public boolean mXmlError = false;
-
-        public BaseDeltaVisitor(BaseBuilder builder) {
-            mBuilder = builder;
-        }
-        
-        /**
-         * Finds a matching Source folder for the current path. This checkds if the current path
-         * leads to, or is a source folder.
-         * @param sourceFolders The list of source folders
-         * @param pathSegments The segments of the current path
-         * @return The segments of the source folder, or null if no match was found
-         */
-        protected static String[] findMatchingSourceFolder(ArrayList<IPath> sourceFolders,
-                String[] pathSegments) {
-        
-            for (IPath p : sourceFolders) {
-                // check if we are inside one of those source class path
-    
-                // get the segments
-                String[] srcSegments = p.segments();
-    
-                // compare segments. We want the path of the resource
-                // we're visiting to be
-                boolean valid = true;
-                int segmentCount = pathSegments.length;
-    
-                for (int i = 0 ; i < segmentCount; i++) {
-                    String s1 = pathSegments[i];
-                    String s2 = srcSegments[i];
-
-                    if (s1.equalsIgnoreCase(s2) == false) {
-                        valid = false;
-                        break;
-                    }
-                }
-    
-                if (valid) {
-                    // this folder, or one of this children is a source
-                    // folder!
-                    // we return its segments
-                    return srcSegments;
-                }
-            }
-            
-            return null;
-        }
-
-        /**
-         * Sent when an XML error is detected.
-         * @see XmlErrorListener
-         */
-        public void errorFound() {
-            mXmlError = true;
-        }
-    }
-
-    public BaseBuilder() {
-        super();
-        mParserFactory = SAXParserFactory.newInstance();
-
-        // FIXME when the compiled XML support for namespace is in, set this to true.
-        mParserFactory.setNamespaceAware(false);
-    }
-
-    /**
-     * Checks an Xml file for validity. Errors/warnings will be marked on the
-     * file
-     * @param resource the resource to check
-     * @param visitor a valid resource delta visitor
-     */
-    protected final void checkXML(IResource resource, BaseDeltaVisitor visitor) {
-
-        // first make sure this is an xml file
-        if (resource instanceof IFile) {
-            IFile file = (IFile)resource;
-
-            // remove previous markers
-            removeMarkersFromFile(file, AndroidConstants.MARKER_XML);
-
-            // create  the error handler
-            XmlErrorHandler reporter = new XmlErrorHandler(file, visitor);
-            try {
-                // parse
-                getParser().parse(file.getContents(), reporter);
-            } catch (Exception e1) {
-            }
-        }
-    }
-
-    /**
-     * Returns the SAXParserFactory, instantiating it first if it's not already
-     * created.
-     * @return the SAXParserFactory object
-     * @throws ParserConfigurationException
-     * @throws SAXException
-     */
-    protected final SAXParser getParser() throws ParserConfigurationException,
-            SAXException {
-        return mParserFactory.newSAXParser();
-    }
-
-    /**
-     * Adds a marker to the current project.
-     * 
-     * @param markerId The id of the marker to add.
-     * @param message the message associated with the mark
-     * @param severity the severity of the marker.
-     */
-    protected final void markProject(String markerId, String message, int severity) {
-        BaseProjectHelper.addMarker(getProject(), markerId, message, severity);
-    }
-
-
-    /**
-     * Removes markers from a file.
-     * @param file The file from which to delete the markers.
-     * @param markerId The id of the markers to remove. If null, all marker of
-     * type <code>IMarker.PROBLEM</code> will be removed.
-     */
-    protected final void removeMarkersFromFile(IFile file, String markerId) {
-        try {
-            if (file.exists()) {
-                file.deleteMarkers(markerId, true, IResource.DEPTH_ZERO);
-            }
-        } catch (CoreException ce) {
-            String msg = String.format(Messages.Marker_Delete_Error, markerId, file.toString());
-            AdtPlugin.printErrorToConsole(getProject(), msg);
-        }
-    }
-
-    /**
-     * Removes markers from a container and its children.
-     * @param folder The container from which to delete the markers.
-     * @param markerId The id of the markers to remove. If null, all marker of
-     * type <code>IMarker.PROBLEM</code> will be removed.
-     */
-    protected final void removeMarkersFromContainer(IContainer folder, String markerId) {
-        try {
-            if (folder.exists()) {
-                folder.deleteMarkers(markerId, true, IResource.DEPTH_INFINITE);
-            }
-        } catch (CoreException ce) {
-            String msg = String.format(Messages.Marker_Delete_Error, markerId, folder.toString());
-            AdtPlugin.printErrorToConsole(getProject(), msg);
-        }
-    }
-
-    /**
-     * Removes markers from a project and its children.
-     * @param project The project from which to delete the markers
-     * @param markerId The id of the markers to remove. If null, all marker of
-     * type <code>IMarker.PROBLEM</code> will be removed.
-     */
-    protected final static void removeMarkersFromProject(IProject project,
-            String markerId) {
-        try {
-            if (project.exists()) {
-                project.deleteMarkers(markerId, true, IResource.DEPTH_INFINITE);
-            }
-        } catch (CoreException ce) {
-            String msg = String.format(Messages.Marker_Delete_Error, markerId, project.getName());
-            AdtPlugin.printErrorToConsole(project, msg);
-        }
-    }
-
-    /**
-     * Get the stderr output of a process and return when the process is done.
-     * @param process The process to get the ouput from
-     * @param results The array to store the stderr output
-     * @return the process return code.
-     * @throws InterruptedException
-     */
-    protected final int grabProcessOutput(final Process process,
-            final ArrayList<String> results)
-            throws InterruptedException {
-    	// Due to the limited buffer size on windows for the standard io (stderr, stdout), we
-    	// *need* to read both stdout and stderr all the time. If we don't and a process output
-    	// a large amount, this could deadlock the process.
-
-        // read the lines as they come. if null is returned, it's
-        // because the process finished
-        new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                // create a buffer to read the stderr output
-                InputStreamReader is = new InputStreamReader(process.getErrorStream());
-                BufferedReader errReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = errReader.readLine();
-                        if (line != null) {
-                            results.add(line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        }.start();
-
-        new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                InputStreamReader is = new InputStreamReader(process.getInputStream());
-                BufferedReader outReader = new BufferedReader(is);
-
-                IProject project = getProject();
-
-                try {
-                    while (true) {
-                        String line = outReader.readLine();
-                        if (line != null) {
-                            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE,
-                                    project, line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-
-        }.start();
-
-        // get the return code from the process
-        return process.waitFor();
-    }
-
-    /**
-     * Parse the output of aapt and mark the incorrect file with error markers
-     *
-     * @param results the output of aapt
-     * @param project the project containing the file to mark
-     * @return true if the parsing failed, false if success.
-     */
-    protected final boolean parseAaptOutput(ArrayList<String> results,
-            IProject project) {
-        // nothing to parse? just return false;
-        if (results.size() == 0) {
-            return false;
-        }
-
-        // get the root of the project so that we can make IFile from full
-        // file path
-        String osRoot = project.getLocation().toOSString();
-
-        Matcher m;
-
-        for (int i = 0; i < results.size(); i++) {
-            String p = results.get(i);
-
-            m = sPattern0Line1.matcher(p);
-            if (m.matches()) {
-                // we ignore those (as this is an ignore message from aapt)
-                continue;
-            }
-
-            m = sPattern1Line1.matcher(p);
-            if (m.matches()) {
-                String lineStr = m.group(1);
-                String msg = m.group(2);
-
-                // get the matcher for the next line.
-                m = getNextLineMatcher(results, ++i, sPattern1Line2);
-                if (m == null) {
-                    return true;
-                }
-
-                String location = m.group(1);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project, IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-                continue;
-            }
-
-            // this needs to be tested before Pattern2 since they both start with 'ERROR:'
-            m = sPattern7Line1.matcher(p);
-            if (m.matches()) {
-                String location = m.group(1);
-                String msg = p; // default msg is the line in case we don't find anything else
-
-                if (++i < results.size()) {
-                    msg = results.get(i).trim();
-                    if (++i < results.size()) {
-                        msg = msg + " - " + results.get(i).trim(); //$NON-NLS-1$
-
-                        // skip the next line
-                        i++;
-                    }
-                }
-
-                // display the error
-                if (checkAndMark(location, null, msg, osRoot, project,
-                        IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-
-            m =  sPattern2Line1.matcher(p);
-            if (m.matches()) {
-                // get the msg
-                String msg = m.group(1);
-
-                // get the matcher for the next line.
-                m = getNextLineMatcher(results, ++i, sPattern2Line2);
-                if (m == null) {
-                    return true;
-                }
-
-                String location = m.group(1);
-                String lineStr = m.group(2);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project, IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-                continue;
-            }
-
-            m = sPattern3Line1.matcher(p);
-            if (m.matches()) {
-                String location = m.group(1);
-                String lineStr = m.group(2);
-                String msg = m.group(3);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project, IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-
-            m = sPattern4Line1.matcher(p);
-            if (m.matches()) {
-                // get the filename.
-                String location = m.group(1);
-
-                // get the matcher for the next line.
-                m = getNextLineMatcher(results, ++i, sPattern4Line2);
-                if (m == null) {
-                    return true;
-                }
-
-                String msg = m.group(1);
-                String lineStr = m.group(2);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project, IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-
-            m = sPattern5Line1.matcher(p);
-            if (m.matches()) {
-                String location = m.group(1);
-                String lineStr = m.group(2);
-                String msg = m.group(3);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project,IMarker.SEVERITY_WARNING) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-
-            m = sPattern6Line1.matcher(p);
-            if (m.matches()) {
-                String location = m.group(1);
-                String lineStr = m.group(2);
-                String msg = m.group(3);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, lineStr, msg, osRoot,
-                        project, IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-            
-            m = sPattern8Line1.matcher(p);
-            if (m.matches()) {
-                String location = m.group(2);
-                String msg = m.group(1);
-
-                // check the values and attempt to mark the file.
-                if (checkAndMark(location, null, msg, osRoot, project,
-                        IMarker.SEVERITY_ERROR) == false) {
-                    return true;
-                }
-
-                // success, go to the next line
-                continue;
-            }
-
-            // invalid line format, flag as error, and bail
-            return true;
-        }
-
-        return false;
-    }
-
-
-
-    /**
-     * Saves a String property into the persistent storage of the project.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param value the value to save
-     * @return true if the save succeeded.
-     */
-    protected boolean saveProjectStringProperty(String propertyName, String value) {
-        IProject project = getProject();
-        return ProjectHelper.saveStringProperty(project, propertyName, value);
-    }
-
-
-    /**
-     * Loads a String property from the persistent storage of the project.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @return the property value or null if it was not found.
-     */
-    protected String loadProjectStringProperty(String propertyName) {
-        IProject project = getProject();
-        return ProjectHelper.loadStringProperty(project, propertyName);
-    }
-
-    /**
-     * Saves a property into the persistent storage of the project.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param value the value to save
-     * @return true if the save succeeded.
-     */
-    protected boolean saveProjectBooleanProperty(String propertyName, boolean value) {
-        IProject project = getProject();
-        return ProjectHelper.saveStringProperty(project, propertyName, Boolean.toString(value));
-    }
-
-    /**
-     * Loads a boolean property from the persistent storage of the project.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param defaultValue The default value to return if the property was not found.
-     * @return the property value or the default value if the property was not found.
-     */
-    protected boolean loadProjectBooleanProperty(String propertyName, boolean defaultValue) {
-        IProject project = getProject();
-        return ProjectHelper.loadBooleanProperty(project, propertyName, defaultValue);
-    }
-
-    /**
-     * Saves the path of a resource into the persistent storate of the project.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param resource the resource which path is saved.
-     * @return true if the save succeeded
-     */
-    protected boolean saveProjectResourceProperty(String propertyName, IResource resource) {
-        return ProjectHelper.saveResourceProperty(getProject(), propertyName, resource);
-    }
-
-    /**
-     * Loads the path of a resource from the persistent storage of the project, and returns the
-     * corresponding IResource object.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @return The corresponding IResource object (or children interface) or null
-     */
-    protected IResource loadProjectResourceProperty(String propertyName) {
-        IProject project = getProject();
-        return ProjectHelper.loadResourceProperty(project, propertyName);
-    }
-
-    /**
-     * Check if the parameters gotten from the error output are valid, and mark
-     * the file with an AAPT marker.
-     * @param location
-     * @param lineStr
-     * @param message
-     * @param root The root directory of the project, in OS specific format.
-     * @param project
-     * @param severity The severity of the marker to put (IMarker.SEVERITY_*)
-     * @return true if the parameters were valid and the file was marked
-     * sucessfully.
-     *
-     * @see IMarker
-     */
-    private final  boolean checkAndMark(String location, String lineStr,
-            String message, String root, IProject project, int severity) {
-        // check this is in fact a file
-        File f = new File(location);
-        if (f.exists() == false) {
-            return false;
-        }
-
-        // get the line number
-        int line = -1; // default value for error with no line.
-
-        if (lineStr != null) {
-            try {
-                line = Integer.parseInt(lineStr);
-            } catch (NumberFormatException e) {
-                // looks like the string we extracted wasn't a valid
-                // file number. Parsing failed and we return true
-                return false;
-            }
-        }
-
-        // add the marker
-        IResource f2 = getResourceFromFullPath(location, root, project);
-        if (f2 == null) {
-            return false;
-        }
-
-        // check if there's a similar marker already, since aapt is launched twice
-        boolean markerAlreadyExists = false;
-        try {
-            IMarker[] markers = f2.findMarkers(AndroidConstants.MARKER_AAPT, true,
-                    IResource.DEPTH_ZERO);
-
-            for (IMarker marker : markers) {
-                int tmpLine = marker.getAttribute(IMarker.LINE_NUMBER, -1);
-                if (tmpLine != line) {
-                    break;
-                }
-
-                int tmpSeverity = marker.getAttribute(IMarker.SEVERITY, -1);
-                if (tmpSeverity != severity) {
-                    break;
-                }
-
-                String tmpMsg = marker.getAttribute(IMarker.MESSAGE, null);
-                if (tmpMsg == null || tmpMsg.equals(message) == false) {
-                    break;
-                }
-
-                // if we're here, all the marker attributes are equals, we found it
-                // and exit
-                markerAlreadyExists = true;
-                break;
-            }
-
-        } catch (CoreException e) {
-            // if we couldn't get the markers, then we just mark the file again
-            // (since markerAlreadyExists is initialized to false, we do nothing)
-        }
-
-        if (markerAlreadyExists == false) {
-            if (line != -1) {
-                BaseProjectHelper.addMarker(f2, AndroidConstants.MARKER_AAPT, message, line,
-                        severity);
-            } else {
-                BaseProjectHelper.addMarker(f2, AndroidConstants.MARKER_AAPT, message, severity);
-            }
-        }
-
-        return true;
-    }
-
-    /**
-     * Returns a matching matcher for the next line
-     * @param lines The array of lines
-     * @param nextIndex The index of the next line
-     * @param pattern The pattern to match
-     * @return null if error or no match, the matcher otherwise.
-     */
-    private final Matcher getNextLineMatcher(ArrayList<String> lines,
-            int nextIndex, Pattern pattern) {
-        // unless we can't, because we reached the last line
-        if (nextIndex == lines.size()) {
-            // we expected a 2nd line, so we flag as error
-            // and we bail
-            return null;
-        }
-
-        Matcher m = pattern.matcher(lines.get(nextIndex));
-        if (m.matches()) {
-           return m;
-        }
-
-        return null;
-    }
-
-    private IResource getResourceFromFullPath(String filename, String root,
-            IProject project) {
-        if (filename.startsWith(root)) {
-            String file = filename.substring(root.length());
-
-            // get the resource
-            IResource r = project.findMember(file);
-
-            // if the resource is valid, we add the marker
-            if (r.exists()) {
-                return r;
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Returns an array of external jar files used by the project.
-     * @return an array of OS-specific absolute file paths
-     */
-    protected final String[] getExternalJars() {
-        // get the current project
-        IProject project = getProject();
-
-        // get a java project from it
-        IJavaProject javaProject = JavaCore.create(project);
-        
-        IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot();
-
-        ArrayList<String> oslibraryList = new ArrayList<String>();
-        IClasspathEntry[] classpaths = javaProject.readRawClasspath();
-        if (classpaths != null) {
-            for (IClasspathEntry e : classpaths) {
-                if (e.getEntryKind() == IClasspathEntry.CPE_LIBRARY ||
-                        e.getEntryKind() == IClasspathEntry.CPE_VARIABLE) {
-                    // if this is a classpath variable reference, we resolve it.
-                    if (e.getEntryKind() == IClasspathEntry.CPE_VARIABLE) {
-                        e = JavaCore.getResolvedClasspathEntry(e); 
-                    }
-
-                    // get the IPath
-                    IPath path = e.getPath();
-
-                    // check the name ends with .jar
-                    if (AndroidConstants.EXT_JAR.equalsIgnoreCase(path.getFileExtension())) {
-                        boolean local = false;
-                        IResource resource = wsRoot.findMember(path);
-                        if (resource != null && resource.exists() &&
-                                resource.getType() == IResource.FILE) {
-                            local = true;
-                            oslibraryList.add(resource.getLocation().toOSString());
-                        }
-
-                        if (local == false) {
-                            // if the jar path doesn't match a workspace resource,
-                            // then we get an OSString and check if this links to a valid file.
-                            String osFullPath = path.toOSString();
-
-                            File f = new File(osFullPath);
-                            if (f.exists()) {
-                                oslibraryList.add(osFullPath);
-                            } else {
-                                String message = String.format( Messages.Couldnt_Locate_s_Error,
-                                        path);
-                                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE,
-                                        project, message);
-
-                                // Also put a warning marker on the project
-                                markProject(AdtConstants.MARKER_ADT, message,
-                                        IMarker.SEVERITY_WARNING);
-                            }
-                        }
-                    }
-                }
-            }
-        }
-
-        return oslibraryList.toArray(new String[oslibraryList.size()]);
-    }
-    
-    /**
-     * Aborts the build if the SDK/project setups are broken. This does not
-     * display any errors.
-     * 
-     * @param javaProject The {@link IJavaProject} being compiled.
-     * @throws CoreException
-     */
-    protected final void abortOnBadSetup(IProject project) throws CoreException {
-        // check if we have finished loading the SDK.
-        if (AdtPlugin.getDefault().getSdkLoadStatus() != LoadStatus.LOADED) {
-            // we exit silently
-            stopBuild("SDK is not loaded yet");
-        }
-
-        // check the compiler compliance level.
-        if (ProjectHelper.checkCompilerCompliance(project) !=
-                ProjectHelper.COMPILER_COMPLIANCE_OK) {
-            // we exit silently
-            stopBuild(Messages.Compiler_Compliance_Error);
-        }
-
-        // Check that the SDK directory has been setup.
-        String osSdkFolder = AdtPlugin.getOsSdkFolder();
-
-        if (osSdkFolder == null || osSdkFolder.length() == 0) {
-            stopBuild(Messages.No_SDK_Setup_Error);
-        }
-
-        IAndroidTarget projectTarget = Sdk.getCurrent().getTarget(project);
-        if (projectTarget == null) {
-            // no target. error has been output by the container initializer:
-            // exit silently.
-            stopBuild("Project has no target");
-        }
-    }
-    
-    /**
-     * Throws an exception to cancel the build.
-     * 
-     * @param error the error message
-     * @param args the printf-style arguments to the error message.
-     * @throws CoreException
-     */
-    protected final void stopBuild(String error, Object... args) throws CoreException {
-        throw new CoreException(new Status(IStatus.CANCEL, AdtPlugin.PLUGIN_ID,
-                String.format(error, args)));
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/DexWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/DexWrapper.java
deleted file mode 100644
index 26d96d7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/DexWrapper.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-
-import java.io.File;
-import java.io.PrintStream;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Field;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLClassLoader;
-
-/**
- * Wrapper to access dex.jar through reflection.
- * <p/>Since there is no proper api to call the method in the dex library, this wrapper is going
- * to access it through reflection.
- */
-public final class DexWrapper {
-    
-    private final static String DEX_MAIN = "com.android.dx.command.dexer.Main"; //$NON-NLS-1$
-    private final static String DEX_CONSOLE = "com.android.dx.command.DxConsole"; //$NON-NLS-1$
-    private final static String DEX_ARGS = "com.android.dx.command.dexer.Main$Arguments"; //$NON-NLS-1$
-    
-    private final static String MAIN_RUN = "run"; //$NON-NLS-1$
-    
-    private Method mRunMethod;
-
-    private Constructor<?> mArgConstructor;
-    private Field mArgOutName;
-    private Field mArgVerbose;
-    private Field mArgJarOutput;
-    private Field mArgFileNames;
-
-    private Field mConsoleOut;
-    private Field mConsoleErr;
-    
-    /**
-     * Loads the dex library from a file path. The loaded library can be used with the
-     * {@link DexWrapper} object returned by {@link #getWrapper()}
-     * @param osFilepath the location of the dex.jar file.
-     * @return an IStatus indicating the result of the load.
-     */
-    public synchronized IStatus loadDex(String osFilepath) {
-        try {
-            File f = new File(osFilepath);
-            if (f.isFile() == false) {
-                return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID, String.format(
-                        Messages.DexWrapper_s_does_not_exists, osFilepath));
-            }
-            URL url = f.toURL();
-    
-            URLClassLoader loader = new URLClassLoader(new URL[] { url },
-                    DexWrapper.class.getClassLoader());
-            
-            // get the classes.
-            Class<?> mainClass = loader.loadClass(DEX_MAIN);
-            Class<?> consoleClass = loader.loadClass(DEX_CONSOLE);
-            Class<?> argClass = loader.loadClass(DEX_ARGS);
-            
-            try {
-                // now get the fields/methods we need
-                mRunMethod = mainClass.getMethod(MAIN_RUN, argClass);
-                
-                mArgConstructor = argClass.getConstructor();
-                mArgOutName = argClass.getField("outName"); //$NON-NLS-1$
-                mArgJarOutput = argClass.getField("jarOutput"); //$NON-NLS-1$
-                mArgFileNames = argClass.getField("fileNames"); //$NON-NLS-1$
-                mArgVerbose = argClass.getField("verbose"); //$NON-NLS-1$
-                
-                mConsoleOut = consoleClass.getField("out"); //$NON-NLS-1$
-                mConsoleErr = consoleClass.getField("err"); //$NON-NLS-1$
-                
-            } catch (SecurityException e) {
-                return createErrorStatus(Messages.DexWrapper_SecuryEx_Unable_To_Find_API, e);
-            } catch (NoSuchMethodException e) {
-                return createErrorStatus(Messages.DexWrapper_SecuryEx_Unable_To_Find_Method, e);
-            } catch (NoSuchFieldException e) {
-                return createErrorStatus(Messages.DexWrapper_SecuryEx_Unable_To_Find_Field, e);
-            }
-
-            return Status.OK_STATUS;
-        } catch (MalformedURLException e) {
-            // really this should not happen.
-            return createErrorStatus(
-                    String.format(Messages.DexWrapper_Failed_to_load_s, osFilepath), e);
-        } catch (ClassNotFoundException e) {
-            return createErrorStatus(
-                    String.format(Messages.DexWrapper_Failed_to_load_s, osFilepath), e);
-        }
-    }
-    
-    /**
-     * Runs the dex command.
-     * @param osOutFilePath the OS path to the outputfile (classes.dex
-     * @param osFilenames list of input source files (.class and .jar files)
-     * @param verbose verbose mode.
-     * @param outStream the stdout console
-     * @param errStream the stderr console
-     * @return the integer return code of com.android.dx.command.dexer.Main.run()
-     * @throws CoreException
-     */
-    public synchronized int run(String osOutFilePath, String[] osFilenames,
-            boolean verbose, PrintStream outStream, PrintStream errStream) throws CoreException {
-        
-        try {
-            // set the stream
-            mConsoleErr.set(null /* obj: static field */, errStream);
-            mConsoleOut.set(null /* obj: static field */, outStream);
-            
-            // create the Arguments object.
-            Object args = mArgConstructor.newInstance();
-            mArgOutName.set(args, osOutFilePath);
-            mArgFileNames.set(args, osFilenames);
-            mArgJarOutput.set(args, false);
-            mArgVerbose.set(args, verbose);
-            
-            // call the run method
-            Object res = mRunMethod.invoke(null /* obj: static method */, args);
-            
-            if (res instanceof Integer) {
-                return ((Integer)res).intValue();
-            }
-        
-            return -1;
-        } catch (IllegalAccessException e) {
-            throw new CoreException(createErrorStatus(
-                    String.format(Messages.DexWrapper_Unable_To_Execute_Dex_s, e.getMessage()), e));
-        } catch (InstantiationException e) {
-            throw new CoreException(createErrorStatus(
-                    String.format(Messages.DexWrapper_Unable_To_Execute_Dex_s, e.getMessage()), e));
-        } catch (InvocationTargetException e) {
-            throw new CoreException(createErrorStatus(
-                    String.format(Messages.DexWrapper_Unable_To_Execute_Dex_s, e.getMessage()), e));
-        }
-    }
-    
-    private static IStatus createErrorStatus(String message, Exception e) {
-        AdtPlugin.log(e, message);
-        AdtPlugin.printErrorToConsole(Messages.DexWrapper_Dex_Loader, message);
-        
-        return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID, message, e);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/Messages.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/Messages.java
deleted file mode 100644
index 0100049..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/Messages.java
+++ /dev/null
@@ -1,137 +0,0 @@
-
-package com.android.ide.eclipse.adt.build;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "com.android.ide.eclipse.adt.build.build_messages"; //$NON-NLS-1$
-
-    public static String AAPT_Error;
-
-    public static String AAPT_Exec_Error;
-
-    public static String Added_s_s_Needs_Updating;
-
-    public static String AIDL_Exec_Error;
-
-    public static String AIDL_Java_Conflict;
-
-    public static String ApkBuilder_Certificate_Expired_on_s;
-
-    public static String ApkBuilder_JAVA_HOME_is_s;
-
-    public static String ApkBuilder_Packaging_s;
-
-    public static String ApkBuilder_Packaging_s_into_s;
-
-    public static String ApkBuilder_s_Conflict_with_file_s;
-
-    public static String ApkBuilder_Signing_Key_Creation_s;
-
-    public static String ApkBuilder_Unable_To_Gey_Key;
-
-    public static String ApkBuilder_UnableBuild_Dex_Not_loaded;
-
-    public static String ApkBuilder_Update_or_Execute_manually_s;
-
-    public static String ApkBuilder_Using_Default_Key;
-
-    public static String ApkBuilder_Using_s_To_Sign;
-
-    public static String Checking_Package_Change;
-
-    public static String Compiler_Compliance_Error;
-
-    public static String Couldnt_Locate_s_Error;
-
-    public static String Dalvik_Error_d;
-
-    public static String Dalvik_Error_s;
-
-    public static String Delete_Obsolete_Error;
-
-    public static String DexWrapper_Dex_Loader;
-
-    public static String DexWrapper_Failed_to_load_s;
-
-    public static String DexWrapper_s_does_not_exists;
-
-    public static String DexWrapper_SecuryEx_Unable_To_Find_API;
-
-    public static String DexWrapper_SecuryEx_Unable_To_Find_Field;
-
-    public static String DexWrapper_SecuryEx_Unable_To_Find_Method;
-
-    public static String DexWrapper_Unable_To_Execute_Dex_s;
-
-    public static String DX_Jar_Error;
-
-    public static String Failed_To_Get_Output;
-
-    public static String Final_Archive_Error_s;
-
-    public static String Incompatible_VM_Warning;
-
-    public static String Marker_Delete_Error;
-
-    public static String No_SDK_Setup_Error;
-
-    public static String Nothing_To_Compile;
-
-    public static String Output_Missing;
-
-    public static String Package_s_Doesnt_Exist_Error;
-
-    public static String Preparing_Generated_Files;
-
-    public static String Project_Has_Errors;
-
-    public static String Refreshing_Res;
-
-    public static String Removing_Generated_Classes;
-
-    public static String Requires_1_5_Error;
-
-    public static String Requires_Class_Compatibility_5;
-
-    public static String Requires_Compiler_Compliance_5;
-
-    public static String Requires_Source_Compatibility_5;
-
-    public static String s_Contains_Xml_Error;
-
-    public static String s_Doesnt_Declare_Package_Error;
-
-    public static String s_File_Missing;
-
-    public static String s_Missing_Repackaging;
-
-    public static String s_Modified_Manually_Recreating_s;
-
-    public static String s_Modified_Recreating_s;
-
-    public static String s_Removed_Recreating_s;
-
-    public static String s_Removed_s_Needs_Updating;
-
-    public static String Start_Full_Apk_Build;
-
-    public static String Start_Full_Pre_Compiler;
-
-    public static String Start_Inc_Apk_Build;
-
-    public static String Start_Inc_Pre_Compiler;
-
-    public static String Unparsed_AAPT_Errors;
-
-    public static String Unparsed_AIDL_Errors;
-
-    public static String Xml_Error;
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerBuilder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerBuilder.java
deleted file mode 100644
index 958cac2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerBuilder.java
+++ /dev/null
@@ -1,1150 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.FixLaunchConfig;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.common.project.XmlErrorHandler.BasicXmlErrorListener;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourceAttributes;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Pre Java Compiler.
- * This incremental builder performs 2 tasks:
- * <ul>
- * <li>compiles the resources located in the res/ folder, along with the
- * AndroidManifest.xml file into the R.java class.</li>
- * <li>compiles any .aidl files into a corresponding java file.</li>
- * </ul>
- *
- */
-public class PreCompilerBuilder extends BaseBuilder {
-
-    public static final String ID = "com.android.ide.eclipse.adt.PreCompilerBuilder"; //$NON-NLS-1$
-
-    private static final String PROPERTY_PACKAGE = "manifestPackage"; //$NON-NLS-1$
-
-    private static final String PROPERTY_SOURCE_FOLDER =
-        "manifestPackageSourceFolder"; //$NON-NLS-1$
-
-    private static final String PROPERTY_COMPILE_RESOURCES = "compileResources"; //$NON-NLS-1$
-
-    static final String PROPERTY_ANDROID_GENERATED = "androidGenerated"; //$NON-NLS-1$
-    static final String PROPERTY_ANDROID_CONFLICT = "androidConflict"; //$NON-NLS-1$
-
-    /**
-     * Single line aidl error<br>
-     * "&lt;path&gt;:&lt;line&gt;: &lt;error&gt;"
-     */
-    private static Pattern sAidlPattern1 = Pattern.compile("^(.+?):(\\d+):\\s(.+)$"); //$NON-NLS-1$
-
-    /**
-     * Compile flag. This is set to true if one of the changed/added/removed
-     * file is a resource file. Upon visiting all the delta resources, if
-     * this flag is true, then we know we'll have to compile the resources
-     * into R.java
-     */
-    private boolean mCompileResources = false;
-
-    /** List of .aidl files found that are modified or new. */
-    private final ArrayList<IFile> mAidlToCompile = new ArrayList<IFile>();
-
-    /** List of .aidl files that have been removed. */
-    private final ArrayList<IFile> mAidlToRemove = new ArrayList<IFile>();
-
-    /** cache of the java package defined in the manifest */
-    private String mManifestPackage;
-
-    /** Source folder containing the java package defined in the manifest. */
-    private IFolder mManifestPackageSourceFolder;
-
-    /**
-     * Progress monitor waiting the end of the process to set a persistent value
-     * in a file. This is typically used in conjunction with <code>IResource.refresh()</code>,
-     * since this call is asysnchronous, and we need to wait for it to finish for the file
-     * to be known by eclipse, before we can call <code>resource.setPersistentProperty</code> on
-     * a new file.
-     */
-    private static class RefreshProgressMonitor implements IProgressMonitor {
-        private boolean mCancelled = false;
-        private IFile mNewFile;
-        private IFile mSource;
-        private boolean mDoneExecuted = false;
-        public RefreshProgressMonitor(IFile newFile, IFile source) {
-            mNewFile = newFile;
-            mSource = source;
-        }
-
-        public void beginTask(String name, int totalWork) {
-        }
-
-        public void done() {
-            if (mDoneExecuted == false) {
-                mDoneExecuted = true;
-                if (mNewFile.exists()) {
-                    ProjectHelper.saveResourceProperty(mNewFile, PROPERTY_ANDROID_GENERATED,
-                            mSource);
-                    try {
-                        mNewFile.setDerived(true);
-                    } catch (CoreException e) {
-                        // This really shouldn't happen since we check that the resource exist.
-                        // Worst case scenario, the resource isn't marked as derived.
-                    }
-                }
-            }
-        }
-
-        public void internalWorked(double work) {
-        }
-
-        public boolean isCanceled() {
-            return mCancelled;
-        }
-
-        public void setCanceled(boolean value) {
-            mCancelled = value;
-        }
-
-        public void setTaskName(String name) {
-        }
-
-        public void subTask(String name) {
-        }
-
-        public void worked(int work) {
-        }
-    }
-
-    /**
-     * Progress Monitor setting up to two files as derived once their parent is refreshed.
-     * This is used as ProgressMonitor to refresh the R.java/Manifest.java parent (to display
-     * the newly created files in the package explorer).
-     */
-    private static class DerivedProgressMonitor implements IProgressMonitor {
-        private boolean mCancelled = false;
-        private IFile mFile1;
-        private IFile mFile2;
-        private boolean mDoneExecuted = false;
-        public DerivedProgressMonitor(IFile file1, IFile file2) {
-            mFile1 = file1;
-            mFile2 = file2;
-        }
-
-        public void beginTask(String name, int totalWork) {
-        }
-
-        public void done() {
-            if (mDoneExecuted == false) {
-                if (mFile1 != null && mFile1.exists()) {
-                    mDoneExecuted = true;
-                    try {
-                        mFile1.setDerived(true);
-                    } catch (CoreException e) {
-                        // This really shouldn't happen since we check that the resource edit.
-                        // Worst case scenario, the resource isn't marked as derived.
-                    }
-                }
-                if (mFile2 != null && mFile2.exists()) {
-                    try {
-                        mFile2.setDerived(true);
-                    } catch (CoreException e) {
-                        // This really shouldn't happen since we check that the resource edit.
-                        // Worst case scenario, the resource isn't marked as derived.
-                    }
-                }
-            }
-        }
-
-        public void internalWorked(double work) {
-        }
-
-        public boolean isCanceled() {
-            return mCancelled;
-        }
-
-        public void setCanceled(boolean value) {
-            mCancelled = value;
-        }
-
-        public void setTaskName(String name) {
-        }
-
-        public void subTask(String name) {
-        }
-
-        public void worked(int work) {
-        }
-    }
-
-    public PreCompilerBuilder() {
-        super();
-    }
-    
-    // build() returns a list of project from which this project depends for future compilation.
-    @SuppressWarnings("unchecked") //$NON-NLS-1$
-    @Override
-    protected IProject[] build(int kind, Map args, IProgressMonitor monitor)
-            throws CoreException {
-        // First thing we do is go through the resource delta to not
-        // lose it if we have to abort the build for any reason.
-
-        // get the project objects
-        IProject project = getProject();
-        IJavaProject javaProject = JavaCore.create(project);
-        IAndroidTarget projectTarget = Sdk.getCurrent().getTarget(project);
-
-        // now we need to get the classpath list
-        ArrayList<IPath> sourceList = BaseProjectHelper.getSourceClasspaths(javaProject);
-
-        PreCompilerDeltaVisitor dv = null;
-        String javaPackage = null;
-
-        if (kind == FULL_BUILD) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Start_Full_Pre_Compiler);
-            mCompileResources = true;
-            buildAidlCompilationList(project, sourceList);
-        } else {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Start_Inc_Pre_Compiler);
-
-            // Go through the resources and see if something changed.
-            // Even if the mCompileResources flag is true from a previously aborted
-            // build, we need to go through the Resource delta to get a possible
-            // list of aidl files to compile/remove.
-            IResourceDelta delta = getDelta(project);
-            if (delta == null) {
-                mCompileResources = true;
-                buildAidlCompilationList(project, sourceList);
-            } else {
-                dv = new PreCompilerDeltaVisitor(this, sourceList);
-                delta.accept(dv);
-
-                // record the state
-                mCompileResources |= dv.getCompileResources();
-                
-                // handle aidl modification
-                if (dv.getFullAidlRecompilation()) {
-                    buildAidlCompilationList(project, sourceList);
-                } else {
-                    mergeAidlFileModifications(dv.getAidlToCompile(),
-                            dv.getAidlToRemove());
-                }
-                
-                // get the java package from the visitor
-                javaPackage = dv.getManifestPackage();
-            }
-        }
-
-        // store the build status in the persistent storage
-        saveProjectBooleanProperty(PROPERTY_COMPILE_RESOURCES , mCompileResources);
-        // TODO also needs to store the list of aidl to compile/remove
-
-        // At this point we have stored what needs to be build, so we can
-        // do some high level test and abort if needed.
-        abortOnBadSetup(project);
-        
-        // if there was some XML errors, we just return w/o doing
-        // anything since we've put some markers in the files anyway.
-        if (dv != null && dv.mXmlError) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Xml_Error);
-
-            // This interrupts the build. The next builders will not run.
-            stopBuild(Messages.Xml_Error);
-        }
-
-
-        // get the manifest file
-        IFile manifest = AndroidManifestHelper.getManifest(project);
-
-        if (manifest == null) {
-            String msg = String.format(Messages.s_File_Missing,
-                    AndroidConstants.FN_ANDROID_MANIFEST);
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, msg);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-
-            // This interrupts the build. The next builders will not run.
-            stopBuild(msg);
-        }
-
-        // lets check the XML of the manifest first, if that hasn't been done by the
-        // resource delta visitor yet.
-        if (dv == null || dv.getCheckedManifestXml() == false) {
-            BasicXmlErrorListener errorListener = new BasicXmlErrorListener();
-            AndroidManifestParser parser = BaseProjectHelper.parseManifestForError(manifest,
-                    errorListener);
-            
-            if (errorListener.mHasXmlError == true) {
-                // there was an error in the manifest, its file has been marked,
-                // by the XmlErrorHandler.
-                // We return;
-                String msg = String.format(Messages.s_Contains_Xml_Error,
-                        AndroidConstants.FN_ANDROID_MANIFEST);
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, msg);
-
-                // This interrupts the build. The next builders will not run.
-                stopBuild(msg);
-            }
-            
-            // get the java package from the parser
-            javaPackage = parser.getPackage();
-        }
-
-        if (javaPackage == null || javaPackage.length() == 0) {
-            // looks like the AndroidManifest file isn't valid.
-            String msg = String.format(Messages.s_Doesnt_Declare_Package_Error,
-                    AndroidConstants.FN_ANDROID_MANIFEST);
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    msg);
-
-            // This interrupts the build. The next builders will not run.
-            stopBuild(msg);
-        }
-
-        // at this point we have the java package. We need to make sure it's not a different package
-        // than the previous one that were built.
-        if (javaPackage.equals(mManifestPackage) == false) {
-            // The manifest package has changed, the user may want to update
-            // the launch configuration
-            if (mManifestPackage != null) {
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                        Messages.Checking_Package_Change);
-
-                FixLaunchConfig flc = new FixLaunchConfig(project, mManifestPackage, javaPackage);
-                flc.start();
-            }
-
-            // now we delete the generated classes from their previous location
-            deleteObsoleteGeneratedClass(AndroidConstants.FN_RESOURCE_CLASS,
-                    mManifestPackageSourceFolder, mManifestPackage);
-            deleteObsoleteGeneratedClass(AndroidConstants.FN_MANIFEST_CLASS,
-                    mManifestPackageSourceFolder, mManifestPackage);
-
-            // record the new manifest package, and save it.
-            mManifestPackage = javaPackage;
-            saveProjectStringProperty(PROPERTY_PACKAGE, mManifestPackage);
-        }
-
-        if (mCompileResources) {
-            // we need to figure out where to store the R class.
-            // get the parent folder for R.java and update mManifestPackageSourceFolder
-            IFolder packageFolder = getManifestPackageFolder(project, sourceList);
-
-            // at this point, either we have found the package or not.
-            // if we haven't well it's time to tell the user and abort
-            if (mManifestPackageSourceFolder == null) {
-                // mark the manifest file
-                String message = String.format(Messages.Package_s_Doesnt_Exist_Error,
-                        mManifestPackage);
-                BaseProjectHelper.addMarker(manifest, AndroidConstants.MARKER_AAPT, message,
-                        IMarker.SEVERITY_ERROR);
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, message);
-
-                // abort
-                // This interrupts the build. The next builders will not run.
-                stopBuild(message);
-            }
-
-
-            // found the folder in which to write the stuff
-
-            // get the resource folder
-            IFolder resFolder = project.getFolder(AndroidConstants.WS_RESOURCES);
-
-            // get the file system path
-            IPath outputLocation = mManifestPackageSourceFolder.getLocation();
-            IPath resLocation = resFolder.getLocation();
-            IPath manifestLocation = manifest.getLocation();
-
-            // those locations have to exist for us to do something!
-            if (outputLocation != null && resLocation != null
-                    && manifestLocation != null) {
-                String osOutputPath = outputLocation.toOSString();
-                String osResPath = resLocation.toOSString();
-                String osManifestPath = manifestLocation.toOSString();
-
-                // remove the aapt markers
-                removeMarkersFromFile(manifest, AndroidConstants.MARKER_AAPT);
-                removeMarkersFromContainer(resFolder, AndroidConstants.MARKER_AAPT);
-
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                        Messages.Preparing_Generated_Files);
-
-                // since the R.java file may be already existing in read-only
-                // mode we need to make it readable so that aapt can overwrite
-                // it
-                IFile rJavaFile = packageFolder.getFile(AndroidConstants.FN_RESOURCE_CLASS);
-                prepareFileForExternalModification(rJavaFile);
-
-                // do the same for the Manifest.java class
-                IFile manifestJavaFile = packageFolder.getFile(AndroidConstants.FN_MANIFEST_CLASS);
-                prepareFileForExternalModification(manifestJavaFile);
-
-                // we actually need to delete the manifest.java as it may become empty and in this
-                // case aapt doesn't generate an empty one, but instead doesn't touch it.
-                manifestJavaFile.delete(true, null);
-
-                // launch aapt: create the command line
-                ArrayList<String> array = new ArrayList<String>();
-                array.add(projectTarget.getPath(IAndroidTarget.AAPT));
-                array.add("package"); //$NON-NLS-1$
-                array.add("-m"); //$NON-NLS-1$
-                if (AdtPlugin.getBuildVerbosity() == AdtConstants.BUILD_VERBOSE) {
-                    array.add("-v"); //$NON-NLS-1$
-                }
-                array.add("-J"); //$NON-NLS-1$
-                array.add(osOutputPath);
-                array.add("-M"); //$NON-NLS-1$
-                array.add(osManifestPath);
-                array.add("-S"); //$NON-NLS-1$
-                array.add(osResPath);
-                array.add("-I"); //$NON-NLS-1$
-                array.add(projectTarget.getPath(IAndroidTarget.ANDROID_JAR));
-
-                if (AdtPlugin.getBuildVerbosity() == AdtConstants.BUILD_VERBOSE) {
-                    StringBuilder sb = new StringBuilder();
-                    for (String c : array) {
-                        sb.append(c);
-                        sb.append(' ');
-                    }
-                    String cmd_line = sb.toString();
-                    AdtPlugin.printToConsole(project, cmd_line);
-                }
-
-                // launch
-                int execError = 1;
-                try {
-                    // launch the command line process
-                    Process process = Runtime.getRuntime().exec(
-                            array.toArray(new String[array.size()]));
-
-                    // list to store each line of stderr
-                    ArrayList<String> results = new ArrayList<String>();
-
-                    // get the output and return code from the process
-                    execError = grabProcessOutput(process, results);
-
-                    // attempt to parse the error output
-                    boolean parsingError = parseAaptOutput(results, project);
-
-                    // if we couldn't parse the output we display it in the console.
-                    if (parsingError) {
-                        if (execError != 0) {
-                            AdtPlugin.printErrorToConsole(project, results.toArray());
-                        } else {
-                            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_NORMAL,
-                                    project, results.toArray());
-                        }
-                    }
-
-                    if (execError != 0) {
-                        // if the exec failed, and we couldn't parse the error output (and therefore
-                        // not all files that should have been marked, were marked), we put a
-                        // generic marker on the project and abort.
-                        if (parsingError) {
-                            markProject(AdtConstants.MARKER_ADT, Messages.Unparsed_AAPT_Errors,
-                                    IMarker.SEVERITY_ERROR);
-                        }
-
-                        AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                                Messages.AAPT_Error);
-
-                        // abort if exec failed.
-                        // This interrupts the build. The next builders will not run.
-                        stopBuild(Messages.AAPT_Error);
-                    }
-                } catch (IOException e1) {
-                    // something happen while executing the process,
-                    // mark the project and exit
-                    String msg = String.format(Messages.AAPT_Exec_Error, array.get(0));
-                    markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-
-                    // This interrupts the build. The next builders will not run.
-                    stopBuild(msg);
-                } catch (InterruptedException e) {
-                    // we got interrupted waiting for the process to end...
-                    // mark the project and exit
-                    String msg = String.format(Messages.AAPT_Exec_Error, array.get(0));
-                    markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-
-                    // This interrupts the build. The next builders will not run.
-                    stopBuild(msg);
-                }
-
-                // if the return code was OK, we refresh the folder that
-                // contains R.java to force a java recompile.
-                if (execError == 0) {
-                    // now set the R.java/Manifest.java file as read only.
-                    finishJavaFilesAfterExternalModification(rJavaFile, manifestJavaFile);
-
-                    // build has been done. reset the state of the builder
-                    mCompileResources = false;
-
-                    // and store it
-                    saveProjectBooleanProperty(PROPERTY_COMPILE_RESOURCES, mCompileResources);
-                }
-            }
-        } else {
-            // nothing to do
-        }
-
-        // now handle the aidl stuff.
-        // look for a preprocessed aidl file
-        IResource projectAidl = project.findMember("project.aidl"); //$NON-NLS-1$
-        String folderAidlPath = null;
-        if (projectAidl != null && projectAidl.exists()) {
-            folderAidlPath = projectAidl.getLocation().toOSString();
-        }
-        boolean aidlStatus = handleAidl(projectTarget, sourceList, folderAidlPath, monitor);
-
-        if (aidlStatus == false && mCompileResources == false) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Nothing_To_Compile);
-        }
-
-        return null;
-    }
-
-    @Override
-    protected void clean(IProgressMonitor monitor) throws CoreException {
-        super.clean(monitor);
-
-        AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, getProject(),
-                Messages.Removing_Generated_Classes);
-
-        // check if we have the R.java info already.
-        if (mManifestPackageSourceFolder != null && mManifestPackage != null) {
-            deleteObsoleteGeneratedClass(AndroidConstants.FN_RESOURCE_CLASS,
-                    mManifestPackageSourceFolder, mManifestPackage);
-            deleteObsoleteGeneratedClass(AndroidConstants.FN_MANIFEST_CLASS,
-                    mManifestPackageSourceFolder, mManifestPackage);
-        }
-        
-        // FIXME: delete all java generated from aidl.
-    }
-
-    @Override
-    protected void startupOnInitialize() {
-        super.startupOnInitialize();
-
-        // load the previous IFolder and java package.
-        mManifestPackage = loadProjectStringProperty(PROPERTY_PACKAGE);
-        IResource resource = loadProjectResourceProperty(PROPERTY_SOURCE_FOLDER);
-        if (resource instanceof IFolder) {
-            mManifestPackageSourceFolder = (IFolder)resource;
-        }
-
-        // Load the current compile flag. We ask for true if not found to force a
-        // recompile.
-        mCompileResources = loadProjectBooleanProperty(PROPERTY_COMPILE_RESOURCES, true);
-    }
-
-    /**
-     * Delete the a generated java class associated with the specified java package.
-     * @param filename Name of the generated file to remove.
-     * @param sourceFolder The source Folder containing the old java package.
-     * @param javaPackage the old java package
-     */
-    private void deleteObsoleteGeneratedClass(String filename, IFolder sourceFolder,
-            String javaPackage) {
-        if (sourceFolder == null || javaPackage == null) {
-            return;
-        }
-
-        // convert the java package into path
-        String[] segments = javaPackage.split(AndroidConstants.RE_DOT);
-
-        StringBuilder path = new StringBuilder();
-        for (String s : segments) {
-           path.append(AndroidConstants.WS_SEP_CHAR);
-           path.append(s);
-        }
-
-        // appends the name of the generated file
-        path.append(AndroidConstants.WS_SEP_CHAR);
-        path.append(filename);
-
-        Path iPath = new Path(path.toString());
-
-        // Find a matching resource object.
-        IResource javaFile = sourceFolder.findMember(iPath);
-        if (javaFile != null && javaFile.exists() && javaFile.getType() == IResource.FILE) {
-            try {
-                // remove the read-only tag
-                prepareFileForExternalModification((IFile)javaFile);
-
-                // delete
-                javaFile.delete(true, null);
-
-                // refresh parent
-                javaFile.getParent().refreshLocal(IResource.DEPTH_ONE, new NullProgressMonitor());
-
-            } catch (CoreException e) {
-                // failed to delete it, the user will have to delete it manually.
-                String message = String.format(Messages.Delete_Obsolete_Error, path);
-                IProject project = getProject();
-                AdtPlugin.printErrorToConsole(project, message);
-                AdtPlugin.printErrorToConsole(project, e.getMessage());
-            }
-        }
-    }
-
-    /**
-     * Looks for the folder containing the package defined in the manifest. It looks in the
-     * list of source folders for the one containing folders matching the package defined in the
-     * manifest (from the field <code>mManifestPackage</code>). It returns the final folder, which
-     * will contain the R class, and update the field <code>mManifestPackageSourceFolder</code>
-     * to be the source folder containing the full package.
-     * @param project The project.
-     * @param sourceList The list of source folders for the project.
-     * @return the package that will contain the R class or null if the folder was not found.
-     * @throws CoreException
-     */
-    private IFolder getManifestPackageFolder(IProject project, ArrayList<IPath> sourceList)
-            throws CoreException {
-        // split the package in segments
-        String[] packageSegments = mManifestPackage.split(AndroidConstants.RE_DOT);
-
-        // we look for 2 folders.
-        // 1. The source folder that contains the full java package.
-        // we will store the folder in the field mJavaSourceFolder, for reuse during
-        IFolder manifestPackageSourceFolder = null;
-        // subsequent builds. This is the folder we will give to aapt.
-        // 2. The folder actually containing the R.java files. We need this one to do a refresh
-        IFolder packageFolder = null;
-
-        for (IPath iPath : sourceList) {
-            int packageSegmentIndex = 0;
-
-            // the path is relative to the workspace. We ignore the first segment,
-            // when getting the resource from the IProject object.
-            IResource classpathEntry = project.getFolder(iPath.removeFirstSegments(1));
-
-            if (classpathEntry instanceof IFolder) {
-                IFolder classpathFolder = (IFolder)classpathEntry;
-                IFolder folder = classpathFolder;
-
-                boolean failed = false;
-                while (failed == false
-                        && packageSegmentIndex < packageSegments.length) {
-
-                    // loop on that folder content looking for folders
-                    // that match the package
-                    // defined in AndroidManifest.xml
-
-                    // get the folder content
-                    IResource[] content = folder.members();
-
-                    // this is the segment we look for
-                    String segment = packageSegments[packageSegmentIndex];
-
-                    // did we find it at this level
-                    boolean found = false;
-
-                    for (IResource r : content) {
-                        // look for the java package segment
-                        if (r instanceof IFolder) {
-                            if (r.getName().equals(segment)) {
-                                // we need to skip to the next one
-                                folder = (IFolder)r;
-                                packageSegmentIndex++;
-                                found = true;
-                                break;
-                            }
-                        }
-                    }
-
-                    // if we didn't find it at this level we just fail.
-                    if (found == false) {
-                        failed = true;
-                    }
-                }
-
-                // if we didn't fail then we found it. no point in
-                // looping through the rest
-                // or the classpathEntry
-                if (failed == false) {
-                    // save the target folder reference
-                    manifestPackageSourceFolder = classpathFolder;
-                    packageFolder = folder;
-                    break;
-                }
-            }
-        }
-
-        // save the location of the folder into the persistent storage
-        if (manifestPackageSourceFolder != mManifestPackageSourceFolder) {
-            mManifestPackageSourceFolder = manifestPackageSourceFolder;
-            saveProjectResourceProperty(PROPERTY_SOURCE_FOLDER, mManifestPackageSourceFolder);
-        }
-        return packageFolder;
-    }
-
-    /**
-     * Compiles aidl files into java. This will also removes old java files
-     * created from aidl files that are now gone.
-     * @param projectTarget Target of the project
-     * @param sourceFolders the list of source folders, relative to the workspace.
-     * @param folderAidlPath 
-     * @param monitor the projess monitor
-     * @returns true if it did something
-     * @throws CoreException
-     */
-    private boolean handleAidl(IAndroidTarget projectTarget, ArrayList<IPath> sourceFolders,
-            String folderAidlPath, IProgressMonitor monitor) throws CoreException {
-        if (mAidlToCompile.size() == 0 && mAidlToRemove.size() == 0) {
-            return false;
-        }
-        
-
-        // create the command line
-        String[] command = new String[4 + sourceFolders.size() + (folderAidlPath != null ? 1 : 0)];
-        int index = 0;
-        int aidlIndex;
-        command[index++] = projectTarget.getPath(IAndroidTarget.AIDL);
-        command[aidlIndex = index++] = "-p"; //$NON-NLS-1$
-        if (folderAidlPath != null) {
-            command[index++] = "-p" + folderAidlPath; //$NON-NLS-1$
-        }
-        
-        // since the path are relative to the workspace and not the project itself, we need
-        // the workspace root.
-        IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot(); 
-        for (IPath p : sourceFolders) {
-            IFolder f = wsRoot.getFolder(p);
-            command[index++] = "-I" + f.getLocation().toOSString(); //$NON-NLS-1$
-        }
-
-        // list of files that have failed compilation.
-        ArrayList<IFile> stillNeedCompilation = new ArrayList<IFile>();
-
-        // if an aidl file is being removed before we managed to compile it, it'll be in
-        // both list. We *need* to remove it from the compile list or it'll never go away.
-        for (IFile aidlFile : mAidlToRemove) {
-            int pos = mAidlToCompile.indexOf(aidlFile);
-            if (pos != -1) {
-                mAidlToCompile.remove(pos);
-            }
-        }
-        
-        // loop until we've compile them all
-        for (IFile aidlFile : mAidlToCompile) {
-            // Remove the AIDL error markers from the aidl file
-            removeMarkersFromFile(aidlFile, AndroidConstants.MARKER_AIDL);
-
-            // get the path
-            IPath iPath = aidlFile.getLocation();
-            String osPath = iPath.toOSString();
-
-            // get the parent container
-            IContainer parentContainer = aidlFile.getParent();
-
-            // replace the extension in both the full path and the
-            // last segment
-            String osJavaPath = osPath.replaceAll(AndroidConstants.RE_AIDL_EXT,
-                    AndroidConstants.DOT_JAVA);
-            String javaName = aidlFile.getName().replaceAll(AndroidConstants.RE_AIDL_EXT,
-                    AndroidConstants.DOT_JAVA);
-
-            // check if we can compile it, or if there is a conflict with a java file
-            boolean conflict = ProjectHelper.loadBooleanProperty(aidlFile,
-                    PROPERTY_ANDROID_CONFLICT, false);
-            if (conflict) {
-                String msg = String.format(Messages.AIDL_Java_Conflict, javaName,
-                        aidlFile.getName());
-
-                // put a marker
-                BaseProjectHelper.addMarker(aidlFile, AndroidConstants.MARKER_AIDL, msg,
-                        IMarker.SEVERITY_ERROR);
-
-                // output an error
-                AdtPlugin.printErrorToConsole(getProject(), msg);
-
-                stillNeedCompilation.add(aidlFile);
-
-                // move on to next file
-                continue;
-            }
-
-            // get the resource for the java file.
-            Path javaIPath = new Path(javaName);
-            IFile javaFile = parentContainer.getFile(javaIPath);
-
-            // if the file was read-only, this will make it readable.
-            prepareFileForExternalModification(javaFile);
-
-            // finish to set the command line.
-            command[aidlIndex] = "-p" + Sdk.getCurrent().getTarget(aidlFile.getProject()).getPath(
-                    IAndroidTarget.ANDROID_AIDL); //$NON-NLS-1$
-            command[index] = osPath;
-            command[index + 1] = osJavaPath;
-
-            // launch the process
-            if (execAidl(command, aidlFile) == false) {
-                // aidl failed. File should be marked. We add the file to the list
-                // of file that will need compilation again.
-                stillNeedCompilation.add(aidlFile);
-
-                // and we move on to the next one.
-                continue;
-            } else {
-                // since the exec worked, we refresh the parent, and set the
-                // file as read only.
-                finishFileAfterExternalModification(javaFile, aidlFile);
-            }
-        }
-
-        // change the list to only contains the file that have failed compilation
-        mAidlToCompile.clear();
-        mAidlToCompile.addAll(stillNeedCompilation);
-
-        // Remove the java files created from aidl files that have been removed.
-        for (IFile aidlFile : mAidlToRemove) {
-            // make the java filename
-            String javaName = aidlFile.getName().replaceAll(
-                    AndroidConstants.RE_AIDL_EXT,
-                    AndroidConstants.DOT_JAVA);
-
-            // get the parent container
-            IContainer ic = aidlFile.getParent();
-
-            // and get the IFile corresponding to the java file.
-            IFile javaFile = ic.getFile(new Path(javaName));
-            if (javaFile != null && javaFile.exists() ) {
-                // check if this java file has a persistent data marking it as generated by
-                // the builder.
-                // While we put the aidl path as a resource, internally it's all string anyway.
-                // We use loadStringProperty, because loadResourceProperty tries to match
-                // the string value (a path in this case) with an existing resource, but
-                // the aidl file was deleted, so it would return null, even though the property
-                // existed.
-                String aidlPath = ProjectHelper.loadStringProperty(javaFile,
-                        PROPERTY_ANDROID_GENERATED);
-
-                if (aidlPath != null) {
-                    // This confirms the java file was generated by the builder,
-                    // we can delete the aidlFile.
-                    javaFile.delete(true, null);
-
-                    // Refresh parent.
-                    ic.refreshLocal(IResource.DEPTH_ONE, monitor);
-                }
-            }
-        }
-        mAidlToRemove.clear();
-
-        return true;
-    }
-
-    /**
-     * Execute the aidl command line, parse the output, and mark the aidl file
-     * with any reported errors.
-     * @param command the String array containing the command line to execute.
-     * @param file The IFile object representing the aidl file being
-     *      compiled.
-     * @return false if the exec failed, and build needs to be aborted.
-     */
-    private boolean execAidl(String[] command, IFile file) {
-        // do the exec
-        try {
-            Process p = Runtime.getRuntime().exec(command);
-
-            // list to store each line of stderr
-            ArrayList<String> results = new ArrayList<String>();
-
-            // get the output and return code from the process
-            int result = grabProcessOutput(p, results);
-
-            // attempt to parse the error output
-            boolean error = parseAidlOutput(results, file);
-
-            // If the process failed and we couldn't parse the output
-            // we pring a message, mark the project and exit
-            if (result != 0 && error == true) {
-                // display the message in the console.
-                AdtPlugin.printErrorToConsole(getProject(), results.toArray());
-
-                // mark the project and exit
-                markProject(AdtConstants.MARKER_ADT, Messages.Unparsed_AIDL_Errors,
-                        IMarker.SEVERITY_ERROR);
-                return false;
-            }
-        } catch (IOException e) {
-            // mark the project and exit
-            String msg = String.format(Messages.AIDL_Exec_Error, command[0]);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        } catch (InterruptedException e) {
-            // mark the project and exit
-            String msg = String.format(Messages.AIDL_Exec_Error, command[0]);
-            markProject(AdtConstants.MARKER_ADT, msg, IMarker.SEVERITY_ERROR);
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Goes through the build paths and fills the list of aidl files to compile
-     * ({@link #mAidlToCompile}).
-     * @param project The project.
-     * @param buildPaths The list of build paths.
-     */
-    private void buildAidlCompilationList(IProject project,
-            ArrayList<IPath> buildPaths) {
-        for (IPath p : buildPaths) {
-            // Because the path contains the name of the project as well, we
-            // need to remove it, to access the final folder.
-            String[] segments = p.segments();
-            IContainer folder = project;
-            for (int i = 1; i < segments.length; i++) {
-                IResource r = folder.findMember(segments[i]);
-                if (r != null && r.exists() &&
-                        r.getType() == IResource.FOLDER) {
-                    folder = (IContainer)r;
-                } else {
-                    // hmm looks like the build path is corrupted/wrong.
-                    // reset and break
-                    folder = project;
-                    break;
-                }
-            }
-
-            // did we ge a folder?
-            if (folder != project) {
-                // then we scan!
-                scanContainerForAidl(folder);
-            }
-        }
-    }
-
-    /**
-     * Scans a container and fills the list of aidl files to compile.
-     * @param container The container to scan.
-     */
-    private void scanContainerForAidl(IContainer container) {
-        try {
-            IResource[] members = container.members();
-            for (IResource r : members) {
-                // get the type of the resource
-               switch (r.getType()) {
-                   case IResource.FILE:
-                       // if this a file, check that the file actually exist
-                       // and that it's an aidl file
-                       if (r.exists() &&
-                               AndroidConstants.EXT_AIDL.equalsIgnoreCase(r.getFileExtension())) {
-                           mAidlToCompile.add((IFile)r);
-                       }
-                       break;
-                   case IResource.FOLDER:
-                       // recursively go through children
-                       scanContainerForAidl((IFolder)r);
-                       break;
-                   default:
-                       // this would mean it's a project or the workspace root
-                       // which is unlikely to happen. we do nothing
-                       break;
-               }
-            }
-        } catch (CoreException e) {
-            // Couldn't get the members list for some reason. Just return.
-        }
-    }
-
-
-    /**
-     * Parse the output of aidl and mark the file with any errors.
-     * @param lines The output to parse.
-     * @param file The file to mark with error.
-     * @return true if the parsing failed, false if success.
-     */
-    private boolean parseAidlOutput(ArrayList<String> lines, IFile file) {
-        // nothing to parse? just return false;
-        if (lines.size() == 0) {
-            return false;
-        }
-
-        Matcher m;
-
-        for (int i = 0; i < lines.size(); i++) {
-            String p = lines.get(i);
-
-            m = sAidlPattern1.matcher(p);
-            if (m.matches()) {
-                // we can ignore group 1 which is the location since we already
-                // have a IFile object representing the aidl file.
-                String lineStr = m.group(2);
-                String msg = m.group(3);
-
-                // get the line number
-                int line = 0;
-                try {
-                    line = Integer.parseInt(lineStr);
-                } catch (NumberFormatException e) {
-                    // looks like the string we extracted wasn't a valid
-                    // file number. Parsing failed and we return true
-                    return true;
-                }
-
-                // mark the file
-                BaseProjectHelper.addMarker(file, AndroidConstants.MARKER_AIDL, msg, line,
-                        IMarker.SEVERITY_ERROR);
-
-                // success, go to the next line
-                continue;
-            }
-
-            // invalid line format, flag as error, and bail
-            return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * Merge the current list of aidl file to compile/remove with the new one.
-     * @param toCompile List of file to compile
-     * @param toRemove List of file to remove
-     */
-    private void mergeAidlFileModifications(ArrayList<IFile> toCompile,
-            ArrayList<IFile> toRemove) {
-
-        // loop through the new toRemove list, and add it to the old one,
-        // plus remove any file that was still to compile and that are now
-        // removed
-        for (IFile r : toRemove) {
-            if (mAidlToRemove.indexOf(r) == -1) {
-                mAidlToRemove.add(r);
-            }
-
-            int index = mAidlToCompile.indexOf(r);
-            if (index != -1) {
-                mAidlToCompile.remove(index);
-            }
-        }
-
-        // now loop through the new files to compile and add it to the list.
-        // Also look for them in the remove list, this would mean that they
-        // were removed, then added back, and we shouldn't remove them, just
-        // recompile them.
-        for (IFile r : toCompile) {
-            if (mAidlToCompile.indexOf(r) == -1) {
-                mAidlToCompile.add(r);
-            }
-
-            int index = mAidlToRemove.indexOf(r);
-            if (index != -1) {
-                mAidlToRemove.remove(index);
-            }
-        }
-    }
-
-    /**
-     * Prepare an already existing file for modification. File generated from
-     * command line processed are marked as read-only. This method prepares
-     * them (mark them as read-write) before the command line process is
-     * started. A check is made to be sure the file exists.
-     * @param file The IResource object for the file to prepare.
-     * @throws CoreException
-     */
-    private void prepareFileForExternalModification(IFile file)
-            throws CoreException {
-        // file may not exist yet, so we check that.
-        if (file != null && file.exists()) {
-            // get the attributes.
-            ResourceAttributes ra = file.getResourceAttributes();
-            if (ra != null) {
-                // change the attributes
-                ra.setReadOnly(false);
-
-                // set the new attributes in the file.
-                file.setResourceAttributes(ra);
-            }
-        }
-    }
-
-    /**
-     * Finish a file created/modified by an outside command line process.
-     * The file is marked as modified by Android, and the parent folder is refreshed, so that,
-     * in case the file didn't exist beforehand, the file appears in the package explorer.
-     * @param rFile The R file to "finish".
-     * @param manifestFile The manifest file to "finish".
-     * @throws CoreException
-     */
-    private void finishJavaFilesAfterExternalModification(IFile rFile, IFile manifestFile)
-            throws CoreException {
-        IContainer parent = rFile.getParent();
-
-        IProgressMonitor monitor = new DerivedProgressMonitor(rFile, manifestFile);
-
-        // refresh the parent node in the package explorer. Once this is done the custom progress
-        // monitor will mark them as derived.
-        parent.refreshLocal(IResource.DEPTH_ONE, monitor);
-    }
-
-    /**
-     * Finish a file created/modified by an outside command line process.
-     * The file is marked as modified by Android, and the parent folder is refreshed, so that,
-     * in case the file didn't exist beforehand, the file appears in the package explorer.
-     * @param file The file to "finish".
-     * @param aidlFile The AIDL file to "finish".
-     * @throws CoreException
-     */
-    private void finishFileAfterExternalModification(IFile file, IFile aidlFile)
-            throws CoreException {
-        IContainer parent = file.getParent();
-
-        // we need to add a link to the aidl file.
-        // We need to wait for the refresh of the parent to be done, so we'll do
-        // it in the monitor. This will also set the file as derived.
-        IProgressMonitor monitor = new RefreshProgressMonitor(file, aidlFile);
-
-        // refresh the parent node in the package explorer.
-        parent.refreshLocal(IResource.DEPTH_ONE, monitor);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerDeltaVisitor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerDeltaVisitor.java
deleted file mode 100644
index f4778d7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/PreCompilerDeltaVisitor.java
+++ /dev/null
@@ -1,432 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.build.BaseBuilder.BaseDeltaVisitor;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-
-import java.util.ArrayList;
-
-/**
- * Resource Delta visitor for the pre-compiler.
- */
-class PreCompilerDeltaVisitor extends BaseDeltaVisitor implements
-        IResourceDeltaVisitor {
-
-    // Result fields.
-    /**
-     * Compile flag. This is set to true if one of the changed/added/removed
-     * file is a resource file. Upon visiting all the delta resources, if
-     * this flag is true, then we know we'll have to compile the resources
-     * into R.java
-     */
-    private boolean mCompileResources = false;
-
-    /** List of .aidl files found that are modified or new. */
-    private final ArrayList<IFile> mAidlToCompile = new ArrayList<IFile>();
-
-    /** List of .aidl files that have been removed. */
-    private final ArrayList<IFile> mAidlToRemove = new ArrayList<IFile>();
-    
-    /** Aidl forced recompilation flag. This is set to true if project.aidl is modified. */
-    private boolean mFullAidlCompilation = false;
-
-    /** Manifest check/parsing flag. */
-    private boolean mCheckedManifestXml = false;
-
-    /** Application Pacakge, gathered from the parsing of the manifest */
-    private String mJavaPackage = null;
-
-    // Internal usage fields.
-    /**
-     * In Resource folder flag. This allows us to know if we're in the
-     * resource folder.
-     */
-    private boolean mInRes = false;
-
-    /**
-     * In Source folder flag. This allows us to know if we're in a source
-     * folder.
-     */
-    private boolean mInSrc = false;
-
-    /** List of source folders. */
-    private ArrayList<IPath> mSourceFolders;
-
-
-    public PreCompilerDeltaVisitor(BaseBuilder builder, ArrayList<IPath> sourceFolders) {
-        super(builder);
-        mSourceFolders = sourceFolders;
-    }
-
-    public boolean getCompileResources() {
-        return mCompileResources;
-    }
-
-    public ArrayList<IFile> getAidlToCompile() {
-        return mAidlToCompile;
-    }
-
-    public ArrayList<IFile> getAidlToRemove() {
-        return mAidlToRemove;
-    }
-    
-    public boolean getFullAidlRecompilation() {
-        return mFullAidlCompilation;
-    }
-
-    /**
-     * Returns whether the manifest file was parsed/checked for error during the resource delta
-     * visiting.
-     */
-    public boolean getCheckedManifestXml() {
-        return mCheckedManifestXml;
-    }
-    
-    /**
-     * Returns the manifest package if the manifest was checked/parsed.
-     * <p/>
-     * This can return null in two cases:
-     * <ul>
-     * <li>The manifest was not part of the resource change delta, and the manifest was
-     * not checked/parsed ({@link #getCheckedManifestXml()} returns <code>false</code>)</li>
-     * <li>The manifest was parsed ({@link #getCheckedManifestXml()} returns <code>true</code>),
-     * but the package declaration is missing</li>
-     * </ul>
-     * @return the manifest package or null.
-     */
-    public String getManifestPackage() {
-        return mJavaPackage;
-    }
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.core.resources.IResourceDeltaVisitor
-     *      #visit(org.eclipse.core.resources.IResourceDelta)
-     */
-    public boolean visit(IResourceDelta delta) throws CoreException {
-        // we are only going to look for changes in res/, source folders and in
-        // AndroidManifest.xml since the delta visitor goes through the main
-        // folder before its children we can check when the path segment
-        // count is 2 (format will be /$Project/folder) and make sure we are
-        // processing res/, source folders or AndroidManifest.xml
-
-        IResource resource = delta.getResource();
-        IPath path = resource.getFullPath();
-        String[] segments = path.segments();
-
-        // since the delta visitor also visits the root we return true if
-        // segments.length = 1
-        if (segments.length == 1) {
-            return true;
-        } else if (segments.length == 2) {
-            // if we are at an item directly under the root directory,
-            // then we are not yet in a source or resource folder
-            mInRes = mInSrc = false;
-
-            if (SdkConstants.FD_RESOURCES.equalsIgnoreCase(segments[1])) {
-                // this is the resource folder that was modified. we want to
-                // see its content.
-
-                // since we're going to visit its children next, we set the
-                // flag
-                mInRes = true;
-                mInSrc = false;
-                return true;
-            } else if (AndroidConstants.FN_ANDROID_MANIFEST.equalsIgnoreCase(segments[1])) {
-                // any change in the manifest could trigger a new R.java
-                // class, so we don't need to check the delta kind
-                if (delta.getKind() != IResourceDelta.REMOVED) {
-                    // parse the manifest for errors
-                    AndroidManifestParser parser = BaseProjectHelper.parseManifestForError(
-                            (IFile)resource, this);
-                    
-                    if (parser != null) {
-                        mJavaPackage = parser.getPackage();
-                    }
-
-                    mCheckedManifestXml = true;
-                }
-                mCompileResources = true;
-
-                // we don't want to go to the children, not like they are
-                // any for this resource anyway.
-                return false;
-            } else if (AndroidConstants.FN_PROJECT_AIDL.equalsIgnoreCase(segments[1])) {
-                // need to force recompilation of all the aidl files
-                mFullAidlCompilation = true;
-            }
-        }
-
-        // at this point we can either be in the source folder or in the
-        // resource folder or in a different folder that contains a source
-        // folder.
-        // This is due to not all source folder being src/. Some could be
-        // something/somethingelse/src/
-
-        // so first we test if we already know we are in a source or
-        // resource folder.
-
-        if (mInSrc) {
-            // if we are in the res folder, we are looking for the following changes:
-            // - added/removed/modified aidl files.
-            // - missing R.java file
-
-            // if the resource is a folder, we just go straight to the children
-            if (resource.getType() == IResource.FOLDER) {
-                return true;
-            }
-
-            if (resource.getType() != IResource.FILE) {
-                return false;
-            }
-            IFile file = (IFile)resource;
-
-            // get the modification kind
-            int kind = delta.getKind();
-
-            if (kind == IResourceDelta.ADDED) {
-                // we only care about added files (inside the source folders), if they
-                // are aidl files.
-
-                // get the extension of the resource
-                String ext = resource.getFileExtension();
-
-                if (AndroidConstants.EXT_AIDL.equalsIgnoreCase(ext)) {
-                    // look for an already existing matching java file
-                    String javaName = resource.getName().replaceAll(
-                            AndroidConstants.RE_AIDL_EXT,
-                            AndroidConstants.DOT_JAVA);
-
-                    // get the parent container
-                    IContainer ic = resource.getParent();
-
-                    IFile javaFile = ic.getFile(new Path(javaName));
-                    if (javaFile != null && javaFile.exists()) {
-                        // check if that file was generated by the plugin. Normally those files are
-                        // deleted automatically, but it's better to check.
-                        String aidlPath = ProjectHelper.loadStringProperty(javaFile,
-                                PreCompilerBuilder.PROPERTY_ANDROID_GENERATED);
-                        if (aidlPath == null) {
-                            // mark the aidl file that it cannot be compile just yet
-                            ProjectHelper.saveBooleanProperty(file,
-                                    PreCompilerBuilder.PROPERTY_ANDROID_CONFLICT, true);
-                        }
-
-                        // we add it anyway so that we can try to compile it at every compilation
-                        // until the conflict is fixed.
-                        mAidlToCompile.add(file);
-
-                    } else {
-                        // the java file doesn't exist, we can safely add the file to the list
-                        // of files to compile.
-                        mAidlToCompile.add(file);
-                    }
-                }
-
-                return false;
-            }
-
-            // get the filename
-            String fileName = segments[segments.length - 1];
-
-            boolean outputMessage = false;
-
-            // Special case of R.java/Manifest.java.
-            // FIXME: This does not check the package. Any modification of R.java/Manifest.java in another project will trigger a new recompilation of the resources.
-            if (AndroidConstants.FN_RESOURCE_CLASS.equals(fileName) ||
-                    AndroidConstants.FN_MANIFEST_CLASS.equals(fileName)) {
-                // if it was removed, there's a possibility that it was removed due to a
-                // package change, or an aidl that was removed, but the only thing
-                // that will happen is that we'll have an extra build. Not much of a problem.
-                mCompileResources = true;
-
-                // we want a warning
-                outputMessage = true;
-            } else {
-
-                // get the extension of the resource
-                String ext = resource.getFileExtension();
-
-                if (AndroidConstants.EXT_AIDL.equalsIgnoreCase(ext)) {
-                    if (kind == IResourceDelta.REMOVED) {
-                        mAidlToRemove.add(file);
-                    } else {
-                        mAidlToCompile.add(file);
-                    }
-                } else {
-                    if (kind == IResourceDelta.REMOVED) {
-                        // the file has been removed. we need to check it's a java file and that
-                        // there's a matching aidl file. We can't check its persistent storage
-                        // anymore.
-                        if (AndroidConstants.EXT_JAVA.equalsIgnoreCase(ext)) {
-                            String aidlFile = resource.getName().replaceAll(
-                                    AndroidConstants.RE_JAVA_EXT,
-                                    AndroidConstants.DOT_AIDL);
-
-                            // get the parent container
-                            IContainer ic = resource.getParent();
-
-                            IFile f = ic.getFile(new Path(aidlFile));
-                            if (f != null && f.exists() ) {
-                                // make sure that the aidl file is not in conflict anymore, in
-                                // case the java file was not generated by us.
-                                if (ProjectHelper.loadBooleanProperty(f,
-                                        PreCompilerBuilder.PROPERTY_ANDROID_CONFLICT, false)) {
-                                    ProjectHelper.saveBooleanProperty(f,
-                                            PreCompilerBuilder.PROPERTY_ANDROID_CONFLICT, false);
-                                } else {
-                                    outputMessage = true;
-                                }
-                                mAidlToCompile.add(f);
-                            }
-                        }
-                    } else {
-                        // check if it's an android generated java file.
-                        IResource aidlSource = ProjectHelper.loadResourceProperty(
-                                file, PreCompilerBuilder.PROPERTY_ANDROID_GENERATED);
-
-                        if (aidlSource != null && aidlSource.exists() &&
-                                aidlSource.getType() == IResource.FILE) {
-                            // it looks like this was a java file created from an aidl file.
-                            // we need to add the aidl file to the list of aidl file to compile
-                            mAidlToCompile.add((IFile)aidlSource);
-                            outputMessage = true;
-                        }
-                    }
-                }
-            }
-
-            if (outputMessage) {
-                if (kind == IResourceDelta.REMOVED) {
-                    // We pring an error just so that it's red, but it's just a warning really.
-                    String msg = String.format(Messages.s_Removed_Recreating_s, fileName);
-                    AdtPlugin.printErrorToConsole(mBuilder.getProject(), msg);
-                } else if (kind == IResourceDelta.CHANGED) {
-                    // the file was modified manually! we can't allow it.
-                    String msg = String.format(Messages.s_Modified_Manually_Recreating_s, fileName);
-                    AdtPlugin.printErrorToConsole(mBuilder.getProject(), msg);
-                }
-            }
-
-            // no children.
-            return false;
-        } else if (mInRes) {
-            // if we are in the res folder, we are looking for the following
-            // changes:
-            // - added/removed/modified xml files.
-            // - added/removed files of any other type
-
-            // if the resource is a folder, we just go straight to the
-            // children
-            if (resource.getType() == IResource.FOLDER) {
-                return true;
-            }
-
-            // get the extension of the resource
-            String ext = resource.getFileExtension();
-            int kind = delta.getKind();
-
-            String p = resource.getProjectRelativePath().toString();
-            String message = null;
-            switch (kind) {
-                case IResourceDelta.CHANGED:
-                    // display verbose message
-                    message = String.format(Messages.s_Modified_Recreating_s, p,
-                            AndroidConstants.FN_RESOURCE_CLASS);
-                    break;
-                case IResourceDelta.ADDED:
-                    // display verbose message
-                    message = String.format(Messages.Added_s_s_Needs_Updating, p,
-                            AndroidConstants.FN_RESOURCE_CLASS);
-                    break;
-                case IResourceDelta.REMOVED:
-                    // display verbose message
-                    message = String.format(Messages.s_Removed_s_Needs_Updating, p,
-                            AndroidConstants.FN_RESOURCE_CLASS);
-                    break;
-            }
-            if (message != null) {
-                AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE,
-                        mBuilder.getProject(), message);
-            }
-
-            if (AndroidConstants.EXT_XML.equalsIgnoreCase(ext)) {
-                if (kind != IResourceDelta.REMOVED) {
-                    // check xml Validity
-                    mBuilder.checkXML(resource, this);
-                }
-
-                // if we are going through this resource, it was modified
-                // somehow.
-                // we don't care if it was an added/removed/changed event
-                mCompileResources = true;
-                return false;
-            } else {
-                // this is a non xml resource.
-                if (kind == IResourceDelta.ADDED
-                        || kind == IResourceDelta.REMOVED) {
-                    mCompileResources = true;
-                    return false;
-                }
-            }
-        } else if (resource instanceof IFolder) {
-            // in this case we may be inside a folder that contains a source
-            // folder.
-            String[] sourceFolderSegments = findMatchingSourceFolder(mSourceFolders, segments);
-            if (sourceFolderSegments != null) {
-                // we have a match!
-                mInRes = false;
-
-                // Check if the current folder is actually a source folder
-                if (sourceFolderSegments.length == segments.length) {
-                    mInSrc = true;
-                }
-                
-                // and return true to visit the content, no matter what
-                return true;
-            }
-
-            // if we're here, we are visiting another folder
-            // like /$Project/bin/ for instance (we get notified for changes
-            // in .class!)
-            // This could also be another source folder and we have found
-            // R.java in a previous source folder
-            // We don't want to visit its children
-            return false;
-        }
-
-        return false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ResourceManagerBuilder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ResourceManagerBuilder.java
deleted file mode 100644
index 19d7185..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/ResourceManagerBuilder.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.LoadStatus;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-
-import java.util.Map;
-
-/**
- * Resource manager builder whose only purpose is to refresh the resource folder
- * so that the other builder use an up to date version.
- */
-public class ResourceManagerBuilder extends BaseBuilder {
-
-    public static final String ID = "com.android.ide.eclipse.adt.ResourceManagerBuilder"; //$NON-NLS-1$
-
-    public ResourceManagerBuilder() {
-        super();
-    }
-
-    // build() returns a list of project from which this project depends for future compilation.
-    @SuppressWarnings("unchecked") //$NON-NLS-1$
-    @Override
-    protected IProject[] build(int kind, Map args, IProgressMonitor monitor)
-            throws CoreException {
-        // Get the project.
-        IProject project = getProject();
-
-        // Clear the project of the generic markers
-        BaseBuilder.removeMarkersFromProject(project, AdtConstants.MARKER_ADT);
-
-        // Check the compiler compliance level, displaying the error message
-        // since this is the first builder.
-        int res = ProjectHelper.checkCompilerCompliance(project);
-        String errorMessage = null;
-        switch (res) {
-            case ProjectHelper.COMPILER_COMPLIANCE_LEVEL:
-                errorMessage = Messages.Requires_Compiler_Compliance_5;
-            case ProjectHelper.COMPILER_COMPLIANCE_SOURCE:
-                errorMessage = Messages.Requires_Source_Compatibility_5;
-            case ProjectHelper.COMPILER_COMPLIANCE_CODEGEN_TARGET:
-                errorMessage = Messages.Requires_Class_Compatibility_5;
-        }
-
-        if (errorMessage != null) {
-            BaseProjectHelper.addMarker(project, AdtConstants.MARKER_ADT, errorMessage,
-                    IMarker.SEVERITY_ERROR);
-            AdtPlugin.printErrorToConsole(project, errorMessage);
-            
-            // interrupt the build. The next builders will not run.
-            stopBuild(errorMessage);
-        }
-
-        // Check that the SDK directory has been setup.
-        String osSdkFolder = AdtPlugin.getOsSdkFolder();
-
-        if (osSdkFolder == null || osSdkFolder.length() == 0) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.No_SDK_Setup_Error);
-            markProject(AdtConstants.MARKER_ADT, Messages.No_SDK_Setup_Error,
-                    IMarker.SEVERITY_ERROR);
-
-            // This interrupts the build. The next builders will not run.
-            stopBuild(Messages.No_SDK_Setup_Error);
-        }
-
-        // check if we have finished loading the SDK.
-        if (AdtPlugin.getDefault().getSdkLoadStatus() != LoadStatus.LOADED) {
-            // we exit silently
-            // This interrupts the build. The next builders will not run.
-            stopBuild("SDK is not loaded yet");
-        }
-        
-        // check the project has a target
-        IAndroidTarget projectTarget = Sdk.getCurrent().getTarget(project);
-        if (projectTarget == null) {
-            // no target. marker has been set by the container initializer: exit silently.
-            // This interrupts the build. The next builders will not run.
-            stopBuild("Project has no target");
-        }
-
-        // Check the preference to be sure we are supposed to refresh
-        // the folders.
-        if (AdtPlugin.getAutoResRefresh()) {
-            AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project,
-                    Messages.Refreshing_Res);
-
-            // refresh the res folder.
-            IFolder resFolder = project.getFolder(
-                    AndroidConstants.WS_RESOURCES);
-            resFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor);
-
-            // Also refresh the assets folder to make sure the ApkBuilder
-            // will now it's changed and will force a new resource packaging.
-            IFolder assetsFolder = project.getFolder(
-                    AndroidConstants.WS_ASSETS);
-            assetsFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor);
-        }
-
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/build_messages.properties b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/build_messages.properties
deleted file mode 100644
index 8ba43d4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/build/build_messages.properties
+++ /dev/null
@@ -1,61 +0,0 @@
-Start_Full_Apk_Build=Starting full Package build.
-Start_Full_Pre_Compiler=Starting full Pre Compiler.
-Start_Inc_Apk_Build=Starting incremental Package build: Checking resource changes.
-Start_Inc_Pre_Compiler=Starting incremental Pre Compiler: Checking resource changes.
-Xml_Error=Error in an XML file: aborting build.
-s_Missing_Repackaging=%1$s missing. Repackaging.
-Project_Has_Errors=Project contains error(s). Package Builder aborted.
-Failed_To_Get_Output=Failed to get project output folder\!
-Output_Missing=Output folder missing\! Make sure your project is configured properly.
-s_File_Missing=%1$s file missing\!
-Unparsed_AAPT_Errors=Unparsed aapt error(s)\! Check the console for output.
-Unparsed_AIDL_Errors=Unparsed aidl error\! Check the console for output.
-AAPT_Exec_Error=Error executing aapt. Please check aapt is present at %1$s
-Dalvik_Error_d=Conversion to Dalvik format failed with error %1$d
-DX_Jar_Error=Dx.jar is not found inside the plugin. Reinstall ADT\!
-Dalvik_Error_s=Conversion to Dalvik format failed: %1$s
-Incompatible_VM_Warning=Note: You may be using an incompatible virtual machine or class library.
-Requires_1_5_Error=This program requires JDK 1.5 compatibility.
-Final_Archive_Error_s=Error generating final archive: %1$s
-Marker_Delete_Error=Failed to delete marker '%1$s' for %2$s
-Couldnt_Locate_s_Error=Could not locate '%1$s'. This will not be added to the package.
-Compiler_Compliance_Error=Compiler compliance level not compatible: Build aborted.
-No_SDK_Setup_Error=SDK directory has not been setup. Please go to the Android preferences and enter the location of the SDK.
-s_Contains_Xml_Error=%1$s contains XML error: Build aborted.
-s_Doesnt_Declare_Package_Error=%1$s does not declare a Java package: Build aborted.
-Checking_Package_Change=Checking Java package value did not change...
-Package_s_Doesnt_Exist_Error=Package '%1$s' does not exist\!
-Preparing_Generated_Files=Preparing generated java files for update/creation.
-AAPT_Error='aapt' error. Pre Compiler Build aborted.
-Nothing_To_Compile=Nothing to pre compile\!
-Removing_Generated_Classes=Removing generated java classes.
-Delete_Obsolete_Error=Failed to delete obsolete %1$s, please delete it manually
-DexWrapper_Dex_Loader=Dex Loader
-AIDL_Java_Conflict=%1$s is in the way of %2$s, remove it or rename of one the files.
-AIDL_Exec_Error=Error executing aidl. Please check aidl is present at %1$s
-s_Removed_Recreating_s=%1$s was removed\! Recreating %1$s\!
-s_Modified_Manually_Recreating_s=%1$s was modified manually\! Reverting to generated version\!
-s_Modified_Recreating_s='%1$s' was modified, %2$s needs to be updated.
-Added_s_s_Needs_Updating=New resource file: '%1$s', %2$s needs to be updated.
-s_Removed_s_Needs_Updating='%1$s' was removed, %2$s needs to be updated.
-Requires_Compiler_Compliance_5=Android requires compiler compliance level 5.0. Please fix project properties.
-Requires_Source_Compatibility_5=Android requires source compatibility set to 5.0. Please fix project properties.
-Requires_Class_Compatibility_5=Android requires .class compatibility set to 5.0. Please fix project properties.
-Refreshing_Res=Refreshing resource folders.
-DexWrapper_s_does_not_exists=%1$s does not exist or is not a file
-DexWrapper_Failed_to_load_s=Failed to load %1$s
-DexWrapper_Unable_To_Execute_Dex_s=Unable to execute dex: %1$s
-DexWrapper_SecuryEx_Unable_To_Find_API=SecurityException: Unable to find API for dex.jar
-DexWrapper_SecuryEx_Unable_To_Find_Method=SecurityException: Unable to find method for dex.jar
-DexWrapper_SecuryEx_Unable_To_Find_Field=SecurityException: Unable to find field for dex.jar
-ApkBuilder_UnableBuild_Dex_Not_loaded=Unable to build: the file dex.jar was not loaded from the SDK folder\!
-ApkBuilder_Using_Default_Key=Using default debug key to sign package
-ApkBuilder_Using_s_To_Sign=Using '%1$s' to sign package
-ApkBuilder_Signing_Key_Creation_s=Signing Key Creation: 
-ApkBuilder_Unable_To_Gey_Key=Unable to get debug signature key
-ApkBuilder_Certificate_Expired_on_s=Debug certificate expired on %1$s\!
-ApkBuilder_Packaging_s=Packaging %1$s
-ApkBuilder_JAVA_HOME_is_s=The Java VM Home used is: %1$s
-ApkBuilder_Update_or_Execute_manually_s=Update it if necessary, or manually execute the following command:
-ApkBuilder_s_Conflict_with_file_s=%1$s conflicts with another file already put at %2$s
-ApkBuilder_Packaging_s_into_s=Packaging %1$s into %2$s
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunch.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunch.java
deleted file mode 100644
index 3d60401..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunch.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.launching;
-
-import org.eclipse.debug.core.DebugException;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.debug.core.Launch;
-import org.eclipse.debug.core.model.ISourceLocator;
-
-/**
- * Custom implementation of Launch to allow access to the LaunchManager
- *
- */
-class AndroidLaunch extends Launch {
-
-    /**
-     * Basic constructor does nothing special
-     * @param launchConfiguration
-     * @param mode
-     * @param locator
-     */
-    public AndroidLaunch(ILaunchConfiguration launchConfiguration, String mode,
-            ISourceLocator locator) {
-        super(launchConfiguration, mode, locator);
-    }
-
-    /** Stops the launch, and removes it from the launch manager */
-    public void stopLaunch() {
-        ILaunchManager mgr = getLaunchManager();
-
-        if (canTerminate()) {
-            try {
-                terminate();
-            } catch (DebugException e) {
-                // well looks like we couldn't stop it. nothing else to be
-                // done really
-            }
-        }
-        // remove the launch
-        mgr.removeLaunch(this);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunchController.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunchController.java
deleted file mode 100644
index ac003df..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/AndroidLaunchController.java
+++ /dev/null
@@ -1,1838 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.launching;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.MultiLineReceiver;
-import com.android.ddmlib.SyncService;
-import com.android.ddmlib.AndroidDebugBridge.IClientChangeListener;
-import com.android.ddmlib.AndroidDebugBridge.IDebugBridgeChangeListener;
-import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener;
-import com.android.ddmlib.SyncService.SyncResult;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.debug.launching.DeviceChooserDialog.DeviceChooserResponse;
-import com.android.ide.eclipse.adt.debug.ui.EmulatorConfigTab;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkManager;
-import com.android.sdklib.avd.AvdManager;
-import com.android.sdklib.avd.AvdManager.AvdInfo;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.debug.core.model.IDebugTarget;
-import org.eclipse.debug.ui.DebugUITools;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-import org.eclipse.jdt.launching.IVMConnector;
-import org.eclipse.jdt.launching.JavaRuntime;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.preference.IPreferenceStore;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map.Entry;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Controls the launch of Android application either on a device or on the
- * emulator. If an emulator is already running, this class will attempt to reuse
- * it.
- */
-public final class AndroidLaunchController implements IDebugBridgeChangeListener,
-        IDeviceChangeListener, IClientChangeListener {
-    
-    private static final String FLAG_AVD = "-avd"; //$NON-NLS-1$
-    private static final String FLAG_NETDELAY = "-netdelay"; //$NON-NLS-1$
-    private static final String FLAG_NETSPEED = "-netspeed"; //$NON-NLS-1$
-    private static final String FLAG_WIPE_DATA = "-wipe-data"; //$NON-NLS-1$
-    private static final String FLAG_NO_BOOT_ANIM = "-no-boot-anim"; //$NON-NLS-1$
-
-    private static final int MAX_ATTEMPT_COUNT = 5;
-
-    private final static Pattern sAmErrorType = Pattern.compile("Error type (\\d+)"); //$NON-NLS-1$
-
-    /**
-     * A delayed launch waiting for a device to be present or ready before the
-     * application is launched.
-     */
-    static final class DelayedLaunchInfo {
-        /** The device on which to launch the app */
-        Device mDevice = null;
-
-        /** The eclipse project */
-        IProject mProject;
-
-        /** Package name */
-        String mPackageName;
-
-        /** fully qualified name of the activity */
-        String mActivity;
-
-        /** IFile to the package (.apk) file */
-        IFile mPackageFile;
-        
-        /** Debuggable attribute of the manifest file. */
-        Boolean mDebuggable = null;
-        
-        /** Required ApiVersionNumber by the app. 0 means no requirements */
-        int mRequiredApiVersionNumber = 0;
-        
-        InstallRetryMode mRetryMode = InstallRetryMode.NEVER;
-        
-        /**
-         * Launch action. See {@link LaunchConfigDelegate#ACTION_DEFAULT},
-         * {@link LaunchConfigDelegate#ACTION_ACTIVITY},
-         * {@link LaunchConfigDelegate#ACTION_DO_NOTHING}
-         */
-        int mLaunchAction;
-
-        /** the launch object */
-        AndroidLaunch mLaunch;
-
-        /** the monitor object */
-        IProgressMonitor mMonitor;
-
-        /** debug mode flag */
-        boolean mDebugMode;
-
-        int mAttemptCount = 0;
-
-        boolean mCancelled = false;
-
-        /** Basic constructor with activity and package info. */
-        private DelayedLaunchInfo(IProject project, String packageName, String activity,
-                IFile pack, Boolean debuggable, int requiredApiVersionNumber, int launchAction,
-                AndroidLaunch launch, IProgressMonitor monitor) {
-            mProject = project;
-            mPackageName = packageName;
-            mActivity = activity;
-            mPackageFile = pack;
-            mLaunchAction = launchAction;
-            mLaunch = launch;
-            mMonitor = monitor;
-            mDebuggable = debuggable;
-            mRequiredApiVersionNumber = requiredApiVersionNumber;
-        }
-    }
-    
-    /**
-     * Map to store {@link ILaunchConfiguration} objects that must be launched as simple connection
-     * to running application. The integer is the port on which to connect. 
-     * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b>
-     */
-    private final static HashMap<ILaunchConfiguration, Integer> sRunningAppMap =
-        new HashMap<ILaunchConfiguration, Integer>();
-
-    private final static Object sListLock = sRunningAppMap;
-
-    /**
-     * List of {@link DelayedLaunchInfo} waiting for an emulator to connect.
-     * <p>Once an emulator has connected, {@link DelayedLaunchInfo#mDevice} is set and the
-     * DelayedLaunchInfo object is moved to {@link AndroidLaunchController#mWaitingForReadyEmulatorList}.
-     * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b>
-     */
-    private final ArrayList<DelayedLaunchInfo> mWaitingForEmulatorLaunches =
-        new ArrayList<DelayedLaunchInfo>();
-
-    /**
-     * List of application waiting to be launched on a device/emulator.<br>
-     * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b>
-     * */
-    private final ArrayList<DelayedLaunchInfo> mWaitingForReadyEmulatorList =
-        new ArrayList<DelayedLaunchInfo>();
-    
-    /**
-     * Application waiting to show up as waiting for debugger.
-     * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b>
-     */
-    private final ArrayList<DelayedLaunchInfo> mWaitingForDebuggerApplications =
-        new ArrayList<DelayedLaunchInfo>();
-    
-    /**
-     * List of clients that have appeared as waiting for debugger before their name was available.
-     * <b>ALL ACCESS MUST BE INSIDE A <code>synchronized (sListLock)</code> block!</b>
-     */
-    private final ArrayList<Client> mUnknownClientsWaitingForDebugger = new ArrayList<Client>();
-    
-    /** static instance for singleton */
-    private static AndroidLaunchController sThis = new AndroidLaunchController();
-    
-    enum InstallRetryMode {
-        NEVER, ALWAYS, PROMPT;  
-    }
-
-    /**
-     * Launch configuration data. This stores the result of querying the
-     * {@link ILaunchConfiguration} so that it's only done once. 
-     */
-    static final class AndroidLaunchConfiguration {
-        
-        /**
-         * Launch action. See {@link LaunchConfigDelegate#ACTION_DEFAULT},
-         * {@link LaunchConfigDelegate#ACTION_ACTIVITY},
-         * {@link LaunchConfigDelegate#ACTION_DO_NOTHING}
-         */
-        public int mLaunchAction = LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION;
-        
-        public static final boolean AUTO_TARGET_MODE = true;
-
-        /**
-         * Target selection mode.
-         * <ul>
-         * <li><code>true</code>: automatic mode, see {@link #AUTO_TARGET_MODE}</li>
-         * <li><code>false</code>: manual mode</li>
-         * </ul>
-         */
-        public boolean mTargetMode = LaunchConfigDelegate.DEFAULT_TARGET_MODE;
-
-        /**
-         * Indicates whether the emulator should be called with -wipe-data
-         */
-        public boolean mWipeData = LaunchConfigDelegate.DEFAULT_WIPE_DATA;
-
-        /**
-         * Indicates whether the emulator should be called with -no-boot-anim
-         */
-        public boolean mNoBootAnim = LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM;
-        
-        /**
-         * AVD Name.
-         */
-        public String mAvdName = null;
-        
-        public String mNetworkSpeed = EmulatorConfigTab.getSpeed(
-                LaunchConfigDelegate.DEFAULT_SPEED);
-        public String mNetworkDelay = EmulatorConfigTab.getDelay(
-                LaunchConfigDelegate.DEFAULT_DELAY);
-
-        /**
-         * Optional custom command line parameter to launch the emulator
-         */
-        public String mEmulatorCommandLine;
-
-        /**
-         * Initialized the structure from an ILaunchConfiguration object.
-         * @param config
-         */
-        public void set(ILaunchConfiguration config) {
-            try {
-                mLaunchAction = config.getAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION,
-                        mLaunchAction);
-            } catch (CoreException e1) {
-                // nothing to be done here, we'll use the default value
-            }
-
-            try {
-                mTargetMode = config.getAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
-                        mTargetMode);
-            } catch (CoreException e) {
-                // nothing to be done here, we'll use the default value
-            }
-
-            try {
-                mAvdName = config.getAttribute(LaunchConfigDelegate.ATTR_AVD_NAME, mAvdName);
-            } catch (CoreException e) {
-            }
-
-            int index = LaunchConfigDelegate.DEFAULT_SPEED;
-            try {
-                index = config.getAttribute(LaunchConfigDelegate.ATTR_SPEED, index);
-            } catch (CoreException e) {
-                // nothing to be done here, we'll use the default value
-            }
-            mNetworkSpeed = EmulatorConfigTab.getSpeed(index);
-
-            index = LaunchConfigDelegate.DEFAULT_DELAY;
-            try {
-                index = config.getAttribute(LaunchConfigDelegate.ATTR_DELAY, index);
-            } catch (CoreException e) {
-                // nothing to be done here, we'll use the default value
-            }
-            mNetworkDelay = EmulatorConfigTab.getDelay(index);
-
-            try {
-                mEmulatorCommandLine = config.getAttribute(
-                        LaunchConfigDelegate.ATTR_COMMANDLINE, ""); //$NON-NLS-1$
-            } catch (CoreException e) {
-                // lets not do anything here, we'll use the default value
-            }
-
-            try {
-                mWipeData = config.getAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA, mWipeData);
-            } catch (CoreException e) {
-                // nothing to be done here, we'll use the default value
-            }
-
-            try {
-                mNoBootAnim = config.getAttribute(LaunchConfigDelegate.ATTR_NO_BOOT_ANIM,
-                                                  mNoBootAnim);
-            } catch (CoreException e) {
-                // nothing to be done here, we'll use the default value
-            }
-        }
-    }
-
-    /**
-     * Output receiver for am process (activity Manager);
-     */
-    private final class AMReceiver extends MultiLineReceiver {
-        private DelayedLaunchInfo mLaunchInfo;
-        private Device mDevice;
-
-        /**
-         * Basic constructor.
-         * @param launchInfo The launch info associated with the am process.
-         * @param device The device on which the launch is done.
-         */
-        public AMReceiver(DelayedLaunchInfo launchInfo, Device device) {
-            mLaunchInfo = launchInfo;
-            mDevice = device;
-        }
-
-        @Override
-        public void processNewLines(String[] lines) {
-            // first we check if one starts with error
-            ArrayList<String> array = new ArrayList<String>();
-            boolean error = false;
-            boolean warning = false;
-            for (String s : lines) {
-                // ignore empty lines.
-                if (s.length() == 0) {
-                    continue;
-                }
-
-                // check for errors that output an error type, if the attempt count is still
-                // valid. If not the whole text will be output in the console
-                if (mLaunchInfo.mAttemptCount < MAX_ATTEMPT_COUNT &&
-                        mLaunchInfo.mCancelled == false) {
-                    Matcher m = sAmErrorType.matcher(s);
-                    if (m.matches()) {
-                        // get the error type
-                        int type = Integer.parseInt(m.group(1));
-
-                        final int waitTime = 3;
-                        String msg;
-
-                        switch (type) {
-                            case 1:
-                                /* Intended fall through */
-                            case 2:
-                                msg = String.format(
-                                        "Device not ready. Waiting %1$d seconds before next attempt.",
-                                        waitTime);
-                                break;
-                            case 3:
-                                msg = String.format(
-                                        "New package not yet registered with the system. Waiting %1$d seconds before next attempt.",
-                                        waitTime);
-                                break;
-                            default:
-                                msg = String.format(
-                                        "Device not ready (%2$d). Waiting %1$d seconds before next attempt.",
-                                        waitTime, type);
-                                break;
-
-                        }
-
-                        AdtPlugin.printToConsole(mLaunchInfo.mProject, msg);
-
-                        // launch another thread, that waits a bit and attempts another launch
-                        new Thread("Delayed Launch attempt") {
-                            @Override
-                            public void run() {
-                                try {
-                                    sleep(waitTime * 1000);
-                                } catch (InterruptedException e) {
-                                }
-
-                                launchApp(mLaunchInfo, mDevice);
-                            }
-                        }.start();
-
-                        // no need to parse the rest
-                        return;
-                    }
-                }
-
-                // check for error if needed
-                if (error == false && s.startsWith("Error:")) { //$NON-NLS-1$
-                    error = true;
-                }
-                if (warning == false && s.startsWith("Warning:")) { //$NON-NLS-1$
-                    warning = true;
-                }
-
-                // add the line to the list
-                array.add("ActivityManager: " + s); //$NON-NLS-1$
-            }
-
-            // then we display them in the console
-            if (warning || error) {
-                AdtPlugin.printErrorToConsole(mLaunchInfo.mProject, array.toArray());
-            } else {
-                AdtPlugin.printToConsole(mLaunchInfo.mProject, array.toArray());
-            }
-
-            // if error then we cancel the launch, and remove the delayed info
-            if (error) {
-                mLaunchInfo.mLaunch.stopLaunch();
-                synchronized (sListLock) {
-                    mWaitingForReadyEmulatorList.remove(mLaunchInfo);
-                }
-            }
-        }
-
-        public boolean isCancelled() {
-            return false;
-        }
-    }
-
-    /**
-     * Output receiver for "pm install package.apk" command line.
-     */
-    private final static class InstallReceiver extends MultiLineReceiver {
-        
-        private final static String SUCCESS_OUTPUT = "Success"; //$NON-NLS-1$
-        private final static Pattern FAILURE_PATTERN = Pattern.compile("Failure\\s+\\[(.*)\\]"); //$NON-NLS-1$
-        
-        private String mSuccess = null;
-        
-        public InstallReceiver() {
-        }
-
-        @Override
-        public void processNewLines(String[] lines) {
-            for (String line : lines) {
-                if (line.length() > 0) {
-                    if (line.startsWith(SUCCESS_OUTPUT)) {
-                        mSuccess = null;
-                    } else {
-                        Matcher m = FAILURE_PATTERN.matcher(line);
-                        if (m.matches()) {
-                            mSuccess = m.group(1);
-                        }
-                    }
-                }
-            }
-        }
-
-        public boolean isCancelled() {
-            return false;
-        }
-
-        public String getSuccess() {
-            return mSuccess;
-        }
-    }
-
-
-    /** private constructor to enforce singleton */
-    private AndroidLaunchController() {
-        AndroidDebugBridge.addDebugBridgeChangeListener(this);
-        AndroidDebugBridge.addDeviceChangeListener(this);
-        AndroidDebugBridge.addClientChangeListener(this);
-    }
-
-    /**
-     * Returns the singleton reference.
-     */
-    public static AndroidLaunchController getInstance() {
-        return sThis;
-    }
-
-
-    /**
-     * Launches a remote java debugging session on an already running application
-     * @param project The project of the application to debug.
-     * @param debugPort The port to connect the debugger to.
-     */
-    public static void debugRunningApp(IProject project, int debugPort) {
-        // get an existing or new launch configuration
-        ILaunchConfiguration config = AndroidLaunchController.getLaunchConfig(project);
-        
-        if (config != null) {
-            setPortLaunchConfigAssociation(config, debugPort);
-            
-            // and launch
-            DebugUITools.launch(config, ILaunchManager.DEBUG_MODE);
-        }
-    }
-    
-    /**
-     * Returns an {@link ILaunchConfiguration} for the specified {@link IProject}.
-     * @param project the project
-     * @return a new or already existing <code>ILaunchConfiguration</code> or null if there was
-     * an error when creating a new one.
-     */
-    public static ILaunchConfiguration getLaunchConfig(IProject project) {
-        // get the launch manager
-        ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager();
-
-        // now get the config type for our particular android type.
-        ILaunchConfigurationType configType = manager.getLaunchConfigurationType(
-                        LaunchConfigDelegate.ANDROID_LAUNCH_TYPE_ID);
-
-        String name = project.getName();
-
-        // search for an existing launch configuration
-        ILaunchConfiguration config = findConfig(manager, configType, name);
-
-        // test if we found one or not
-        if (config == null) {
-            // Didn't find a matching config, so we make one.
-            // It'll be made in the "working copy" object first.
-            ILaunchConfigurationWorkingCopy wc = null;
-
-            try {
-                // make the working copy object
-                wc = configType.newInstance(null,
-                        manager.generateUniqueLaunchConfigurationNameFrom(name));
-
-                // set the project name
-                wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, name);
-
-                // set the launch mode to default.
-                wc.setAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION,
-                        LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION);
-
-                // set default target mode
-                wc.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
-                        LaunchConfigDelegate.DEFAULT_TARGET_MODE);
-
-                // default AVD: None
-                wc.setAttribute(LaunchConfigDelegate.ATTR_AVD_NAME, (String)null);
-
-                // set the default network speed
-                wc.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
-                        LaunchConfigDelegate.DEFAULT_SPEED);
-
-                // and delay
-                wc.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
-                        LaunchConfigDelegate.DEFAULT_DELAY);
-                
-                // default wipe data mode
-                wc.setAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA,
-                        LaunchConfigDelegate.DEFAULT_WIPE_DATA);
-                
-                // default disable boot animation option
-                wc.setAttribute(LaunchConfigDelegate.ATTR_NO_BOOT_ANIM,
-                        LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM);
-                
-                // set default emulator options
-                IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-                String emuOptions = store.getString(AdtPlugin.PREFS_EMU_OPTIONS);
-                wc.setAttribute(LaunchConfigDelegate.ATTR_COMMANDLINE, emuOptions);
-                
-                // map the config and the project
-                wc.setMappedResources(getResourcesToMap(project));
-
-                // save the working copy to get the launch config object which we return.
-                return wc.doSave();
-
-            } catch (CoreException e) {
-                String msg = String.format(
-                        "Failed to create a Launch config for project '%1$s': %2$s",
-                        project.getName(), e.getMessage());
-                AdtPlugin.printErrorToConsole(project, msg);
-
-                // no launch!
-                return null;
-            }
-        }
-        
-        return config;
-    }
-    
-    /**
-     * Returns the list of resources to map to a Launch Configuration.
-     * @param project the project associated to the launch configuration.
-     */
-    public static IResource[] getResourcesToMap(IProject project) {
-        ArrayList<IResource> array = new ArrayList<IResource>(2);
-        array.add(project);
-        
-        AndroidManifestHelper helper = new AndroidManifestHelper(project);
-        IFile manifest = helper.getManifestIFile();
-        if (manifest != null) {
-            array.add(manifest);
-        }
-        
-        return array.toArray(new IResource[array.size()]);
-    }
-
-    /**
-     * Launches an android app on the device or emulator
-     *
-     * @param project The project we're launching
-     * @param mode the mode in which to launch, one of the mode constants
-     *      defined by <code>ILaunchManager</code> - <code>RUN_MODE</code> or
-     *      <code>DEBUG_MODE</code>.
-     * @param apk the resource to the apk to launch.
-     * @param debuggable the debuggable value of the app, or null if not set.
-     * @param requiredApiVersionNumber the api version required by the app, or -1 if none.
-     * @param activity the class to provide to am to launch
-     * @param config the launch configuration
-     * @param launch the launch object
-     */
-    public void launch(final IProject project, String mode, IFile apk,
-            String packageName, Boolean debuggable, int requiredApiVersionNumber, String activity,
-            final AndroidLaunchConfiguration config, final AndroidLaunch launch,
-            IProgressMonitor monitor) {
-        
-        String message;
-        if (config.mLaunchAction == LaunchConfigDelegate.ACTION_DO_NOTHING) {
-            message = String.format("Only Syncing Application Package");
-        } else {
-            message = String.format("Launching: %1$s", activity);
-        }
-        AdtPlugin.printToConsole(project, message);
-
-        // create the launch info
-        final DelayedLaunchInfo launchInfo = new DelayedLaunchInfo(project, packageName,
-                activity, apk, debuggable, requiredApiVersionNumber, config.mLaunchAction,
-                launch, monitor);
-
-        // set the debug mode
-        launchInfo.mDebugMode = mode.equals(ILaunchManager.DEBUG_MODE);
-
-        // get the SDK
-        Sdk currentSdk = Sdk.getCurrent();
-        AvdManager avdManager = currentSdk.getAvdManager();
-        
-        // get the project target
-        final IAndroidTarget projectTarget = currentSdk.getTarget(project);
-        
-        // FIXME: check errors on missing sdk, AVD manager, or project target.
-        
-        // device chooser response object.
-        final DeviceChooserResponse response = new DeviceChooserResponse();
-        
-        /*
-         * Launch logic:
-         * - Manually Mode
-         *       Always display a UI that lets a user see the current running emulators/devices.
-         *       The UI must show which devices are compatibles, and allow launching new emulators
-         *       with compatible (and not yet running) AVD.
-         * - Automatic Way
-         *     * Preferred AVD set.
-         *           If Preferred AVD is not running: launch it.
-         *           Launch the application on the preferred AVD.
-         *     * No preferred AVD.
-         *           Count the number of compatible emulators/devices.
-         *           If != 1, display a UI similar to manual mode.
-         *           If == 1, launch the application on this AVD/device.
-         */
-        
-        if (config.mTargetMode == AndroidLaunchConfiguration.AUTO_TARGET_MODE) {
-            // if we are in automatic target mode, we need to find the current devices
-            Device[] devices = AndroidDebugBridge.getBridge().getDevices();
-            
-            // first check if we have a preferred AVD name, and if it actually exists, and is valid
-            // (ie able to run the project).
-            // We need to check this in case the AVD was recreated with a different target that is
-            // not compatible.
-            AvdInfo preferredAvd = null;
-            if (config.mAvdName != null) {
-                preferredAvd = avdManager.getAvd(config.mAvdName);
-                if (projectTarget.isCompatibleBaseFor(preferredAvd.getTarget()) == false) {
-                    preferredAvd = null;
-
-                    AdtPlugin.printErrorToConsole(project, String.format(
-                            "Preferred AVD '%1$s' is not compatible with the project target '%2$s'. Looking for a compatible AVD...",
-                            config.mAvdName, projectTarget.getName()));
-                }
-            }
-                
-            if (preferredAvd != null) {
-                // look for a matching device
-                for (Device d : devices) {
-                    String deviceAvd = d.getAvdName();
-                    if (deviceAvd != null && deviceAvd.equals(config.mAvdName)) {
-                        response.setDeviceToUse(d);
-
-                        AdtPlugin.printToConsole(project, String.format(
-                                "Automatic Target Mode: Preferred AVD '%1$s' is available on emulator '%2$s'",
-                                config.mAvdName, d));
-
-                        continueLaunch(response, project, launch, launchInfo, config);
-                        return;
-                    }
-                }
-                
-                // at this point we have a valid preferred AVD that is not running.
-                // We need to start it.
-                response.setAvdToLaunch(preferredAvd);
-
-                AdtPlugin.printToConsole(project, String.format(
-                        "Automatic Target Mode: Preferred AVD '%1$s' is not available. Launching new emulator.",
-                        config.mAvdName));
-
-                continueLaunch(response, project, launch, launchInfo, config);
-                return;
-            }
-
-            // no (valid) preferred AVD? look for one.
-            HashMap<Device, AvdInfo> compatibleRunningAvds = new HashMap<Device, AvdInfo>();
-            boolean hasDevice = false; // if there's 1+ device running, we may force manual mode,
-                                       // as we cannot always detect proper compatibility with
-                                       // devices. This is the case if the project target is not
-                                       // a standard platform
-            for (Device d : devices) {
-                String deviceAvd = d.getAvdName();
-                if (deviceAvd != null) { // physical devices return null.
-                    AvdInfo info = avdManager.getAvd(deviceAvd);
-                    if (info != null && projectTarget.isCompatibleBaseFor(info.getTarget())) {
-                        compatibleRunningAvds.put(d, info);
-                    }
-                } else {
-                    if (projectTarget.isPlatform()) { // means this can run on any device as long
-                                                      // as api level is high enough
-                        String apiString = d.getProperty(SdkManager.PROP_VERSION_SDK);
-                        try {
-                            int apiNumber = Integer.parseInt(apiString);
-                            if (apiNumber >= projectTarget.getApiVersionNumber()) {
-                                // device is compatible with project
-                                compatibleRunningAvds.put(d, null);
-                                continue;
-                            }
-                        } catch (NumberFormatException e) {
-                            // do nothing, we'll consider it a non compatible device below.
-                        }
-                    }
-                    hasDevice = true;
-                }
-            }
-            
-            // depending on the number of devices, we'll simulate an automatic choice
-            // from the device chooser or simply show up the device chooser.
-            if (hasDevice == false && compatibleRunningAvds.size() == 0) {
-                // if zero emulators/devices, we launch an emulator.
-                // We need to figure out which AVD first.
-                
-                // we are going to take the closest AVD. ie a compatible AVD that has the API level
-                // closest to the project target.
-                AvdInfo[] avds = avdManager.getAvds();
-                AvdInfo defaultAvd = null;
-                for (AvdInfo avd : avds) {
-                    if (projectTarget.isCompatibleBaseFor(avd.getTarget())) {
-                        if (defaultAvd == null ||
-                                avd.getTarget().getApiVersionNumber() <
-                                    defaultAvd.getTarget().getApiVersionNumber()) {
-                            defaultAvd = avd;
-                        }
-                    }
-                }
-
-                if (defaultAvd != null) {
-                    response.setAvdToLaunch(defaultAvd);
-
-                    AdtPlugin.printToConsole(project, String.format(
-                            "Automatic Target Mode: launching new emulator with compatible AVD '%1$s'",
-                            defaultAvd.getName()));
-
-                    continueLaunch(response, project, launch, launchInfo, config);
-                    return;
-                } else {
-                    // FIXME: ask the user if he wants to create a AVD.
-                    // we found no compatible AVD.
-                    AdtPlugin.printErrorToConsole(project, String.format(
-                            "Failed to find a AVD compatible with target '%1$s'. Launch aborted.",
-                            projectTarget.getName()));
-                    launch.stopLaunch();
-                    return;
-                }
-            } else if (hasDevice == false && compatibleRunningAvds.size() == 1) {
-                Entry<Device, AvdInfo> e = compatibleRunningAvds.entrySet().iterator().next();
-                response.setDeviceToUse(e.getKey());
-
-                // get the AvdInfo, if null, the device is a physical device.
-                AvdInfo avdInfo = e.getValue();
-                if (avdInfo != null) {
-                    message = String.format("Automatic Target Mode: using existing emulator '%1$s' running compatible AVD '%2$s'",
-                            response.getDeviceToUse(), e.getValue().getName());
-                } else {
-                    message = String.format("Automatic Target Mode: using device '%1$s'",
-                            response.getDeviceToUse());
-                }
-                AdtPlugin.printToConsole(project, message);
-
-                continueLaunch(response, project, launch, launchInfo, config);
-                return;
-            }
-
-            // if more than one device, we'll bring up the DeviceChooser dialog below.
-            if (compatibleRunningAvds.size() >= 2) {
-                message = "Automatic Target Mode: Several compatible targets. Please select a target device."; 
-            } else if (hasDevice) {
-                message = "Automatic Target Mode: Unable to detect device compatibility. Please select a target device."; 
-            }
-
-            AdtPlugin.printToConsole(project, message);
-        }
-        
-        // bring up the device chooser.
-        AdtPlugin.getDisplay().asyncExec(new Runnable() {
-            public void run() {
-                try {
-                    // open the chooser dialog. It'll fill 'response' with the device to use
-                    // or the AVD to launch.
-                    DeviceChooserDialog dialog = new DeviceChooserDialog(
-                            AdtPlugin.getDisplay().getActiveShell(),
-                            response, launchInfo.mPackageName, projectTarget);
-                    if (dialog.open() == Dialog.OK) {
-                        AndroidLaunchController.this.continueLaunch(response, project, launch,
-                                launchInfo, config);
-                    } else {
-                        AdtPlugin.printErrorToConsole(project, "Launch canceled!");
-                        launch.stopLaunch();
-                        return;
-                    }
-                } catch (Exception e) {
-                    // there seems to be some case where the shell will be null. (might be
-                    // an OS X bug). Because of this the creation of the dialog will throw
-                    // and IllegalArg exception interrupting the launch with no user feedback.
-                    // So we trap all the exception and display something.
-                    String msg = e.getMessage();
-                    if (msg == null) {
-                        msg = e.getClass().getCanonicalName();
-                    }
-                    AdtPlugin.printErrorToConsole(project,
-                            String.format("Error during launch: %s", msg));
-                    launch.stopLaunch();
-                }
-            }
-        });
-    }
-    
-    /**
-     * Continues the launch based on the DeviceChooser response.
-     * @param response the device chooser response
-     * @param project The project being launched
-     * @param launch The eclipse launch info
-     * @param launchInfo The {@link DelayedLaunchInfo}
-     * @param config The config needed to start a new emulator.
-     */
-    void continueLaunch(final DeviceChooserResponse response, final IProject project,
-            final AndroidLaunch launch, final DelayedLaunchInfo launchInfo,
-            final AndroidLaunchConfiguration config) {
-
-        // Since this is called from the UI thread we spawn a new thread
-        // to finish the launch.
-        new Thread() {
-            @Override
-            public void run() {
-                if (response.getAvdToLaunch() != null) {
-                    // there was no selected device, we start a new emulator.
-                    synchronized (sListLock) {
-                        AvdInfo info = response.getAvdToLaunch();
-                        mWaitingForEmulatorLaunches.add(launchInfo);
-                        AdtPlugin.printToConsole(project, String.format(
-                                "Launching a new emulator with Virtual Device '%1$s'",
-                                info.getName()));
-                        boolean status = launchEmulator(config, info);
-            
-                        if (status == false) {
-                            // launching the emulator failed!
-                            AdtPlugin.displayError("Emulator Launch",
-                                    "Couldn't launch the emulator! Make sure the SDK directory is properly setup and the emulator is not missing.");
-            
-                            // stop the launch and return
-                            mWaitingForEmulatorLaunches.remove(launchInfo);
-                            AdtPlugin.printErrorToConsole(project, "Launch canceled!");
-                            launch.stopLaunch();
-                            return;
-                        }
-                        
-                        return;
-                    }
-                } else if (response.getDeviceToUse() != null) {
-                    launchInfo.mDevice = response.getDeviceToUse();
-                    simpleLaunch(launchInfo, launchInfo.mDevice);
-                }
-            }
-        }.start();
-    }
-    
-    /**
-     * Queries for a debugger port for a specific {@link ILaunchConfiguration}.
-     * <p/>
-     * If the configuration and a debugger port where added through
-     * {@link #setPortLaunchConfigAssociation(ILaunchConfiguration, int)}, then this method
-     * will return the debugger port, and remove the configuration from the list.
-     * @param launchConfig the {@link ILaunchConfiguration}
-     * @return the debugger port or {@link LaunchConfigDelegate#INVALID_DEBUG_PORT} if the
-     * configuration was not setup.
-     */
-    static int getPortForConfig(ILaunchConfiguration launchConfig) {
-        synchronized (sListLock) {
-            Integer port = sRunningAppMap.get(launchConfig);
-            if (port != null) {
-                sRunningAppMap.remove(launchConfig);
-                return port;
-            }
-        }
-        
-        return LaunchConfigDelegate.INVALID_DEBUG_PORT;
-    }
-    
-    /**
-     * Set a {@link ILaunchConfiguration} and its associated debug port, in the list of
-     * launch config to connect directly to a running app instead of doing full launch (sync,
-     * launch, and connect to).
-     * @param launchConfig the {@link ILaunchConfiguration} object.
-     * @param port The debugger port to connect to.
-     */
-    private static void setPortLaunchConfigAssociation(ILaunchConfiguration launchConfig,
-            int port) {
-        synchronized (sListLock) {
-            sRunningAppMap.put(launchConfig, port);
-        }
-    }
-    
-    /**
-     * Checks the build information, and returns whether the launch should continue.
-     * <p/>The value tested are:
-     * <ul>
-     * <li>Minimum API version requested by the application. If the target device does not match,
-     * the launch is canceled.</li>
-     * <li>Debuggable attribute of the application and whether or not the device requires it. If
-     * the device requires it and it is not set in the manifest, the launch will be forced to
-     * "release" mode instead of "debug"</li>
-     * <ul>
-     */
-    private boolean checkBuildInfo(DelayedLaunchInfo launchInfo, Device device) {
-        if (device != null) {
-            // check the app required API level versus the target device API level
-            
-            String deviceApiVersionName = device.getProperty(Device.PROP_BUILD_VERSION);
-            String value = device.getProperty(Device.PROP_BUILD_VERSION_NUMBER);
-            int deviceApiVersionNumber = 0;
-            try {
-                deviceApiVersionNumber = Integer.parseInt(value);
-            } catch (NumberFormatException e) {
-                // pass, we'll keep the deviceVersionNumber value at 0.
-            }
-            
-            if (launchInfo.mRequiredApiVersionNumber == 0) {
-                // warn the API level requirement is not set.
-                AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                        "WARNING: Application does not specify an API level requirement!");
-
-                // and display the target device API level (if known)
-                if (deviceApiVersionName == null || deviceApiVersionNumber == 0) {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            "WARNING: Unknown device API version!");
-                } else {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject, String.format(
-                            "Device API version is %1$d (Android %2$s)", deviceApiVersionNumber,
-                            deviceApiVersionName));
-                }
-            } else { // app requires a specific API level
-                if (deviceApiVersionName == null || deviceApiVersionNumber == 0) {
-                    AdtPlugin.printToConsole(launchInfo.mProject,
-                            "WARNING: Unknown device API version!");
-                } else if (deviceApiVersionNumber < launchInfo.mRequiredApiVersionNumber) {
-                    String msg = String.format(
-                            "ERROR: Application requires API version %1$d. Device API version is %2$d (Android %3$s).",
-                            launchInfo.mRequiredApiVersionNumber, deviceApiVersionNumber,
-                            deviceApiVersionName);
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject, msg);
-                    
-                    // abort the launch
-                    return false;
-                }
-            }
-
-            // now checks that the device/app can be debugged (if needed)
-            if (device.isEmulator() == false && launchInfo.mDebugMode) {
-                String debuggableDevice = device.getProperty(Device.PROP_DEBUGGABLE);
-                if (debuggableDevice != null && debuggableDevice.equals("0")) { //$NON-NLS-1$
-                    // the device is "secure" and requires apps to declare themselves as debuggable!
-                    if (launchInfo.mDebuggable == null) {
-                        String message1 = String.format(
-                                "Device '%1$s' requires that applications explicitely declare themselves as debuggable in their manifest.",
-                                device.getSerialNumber());
-                        String message2 = String.format("Application '%1$s' does not have the attribute 'debuggable' set to TRUE in its manifest and cannot be debugged.",
-                                launchInfo.mPackageName);
-                        AdtPlugin.printErrorToConsole(launchInfo.mProject, message1, message2);
-                        
-                        // because am -D does not check for ro.debuggable and the
-                        // 'debuggable' attribute, it is important we do not use the -D option
-                        // in this case or the app will wait for a debugger forever and never
-                        // really launch.
-                        launchInfo.mDebugMode = false;
-                    } else if (launchInfo.mDebuggable == Boolean.FALSE) {
-                        String message = String.format("Application '%1$s' has its 'debuggable' attribute set to FALSE and cannot be debugged.",
-                                launchInfo.mPackageName);
-                        AdtPlugin.printErrorToConsole(launchInfo.mProject, message);
-
-                        // because am -D does not check for ro.debuggable and the
-                        // 'debuggable' attribute, it is important we do not use the -D option
-                        // in this case or the app will wait for a debugger forever and never
-                        // really launch.
-                        launchInfo.mDebugMode = false;
-                    }
-                }
-            }
-        }
-        
-        return true;
-    }
-
-    /**
-     * Do a simple launch on the specified device, attempting to sync the new
-     * package, and then launching the application. Failed sync/launch will
-     * stop the current AndroidLaunch and return false;
-     * @param launchInfo
-     * @param device
-     * @return true if succeed
-     */
-    private boolean simpleLaunch(DelayedLaunchInfo launchInfo, Device device) {
-        // API level check
-        if (checkBuildInfo(launchInfo, device) == false) {
-            AdtPlugin.printErrorToConsole(launchInfo.mProject, "Launch canceled!");
-            launchInfo.mLaunch.stopLaunch();
-            return false;
-        }
-
-        // sync the app
-        if (syncApp(launchInfo, device) == false) {
-            AdtPlugin.printErrorToConsole(launchInfo.mProject, "Launch canceled!");
-            launchInfo.mLaunch.stopLaunch();
-            return false;
-        }
-
-        // launch the app
-        launchApp(launchInfo, device);
-
-        return true;
-    }
-
-
-    /**
-     * Syncs the application on the device/emulator.
-     *
-     * @param launchInfo The Launch information object.
-     * @param device the device on which to sync the application
-     * @return true if the install succeeded.
-     */
-    private boolean syncApp(DelayedLaunchInfo launchInfo, Device device) {
-        SyncService sync = device.getSyncService();
-        if (sync != null) {
-            IPath path = launchInfo.mPackageFile.getLocation();
-            String message = String.format("Uploading %1$s onto device '%2$s'",
-                    path.lastSegment(), device.getSerialNumber());
-            AdtPlugin.printToConsole(launchInfo.mProject, message);
-
-            String osLocalPath = path.toOSString();
-            String apkName = launchInfo.mPackageFile.getName();
-            String remotePath = "/data/local/tmp/" + apkName; //$NON-NLS-1$
-
-            SyncResult result = sync.pushFile(osLocalPath, remotePath,
-                    SyncService.getNullProgressMonitor());
-
-            if (result.getCode() != SyncService.RESULT_OK) {
-                String msg = String.format("Failed to upload %1$s on '%2$s': %3$s",
-                        apkName, device.getSerialNumber(), result.getMessage());
-                AdtPlugin.printErrorToConsole(launchInfo.mProject, msg);
-                return false;
-            }
-
-            // Now that the package is uploaded, we can install it properly.
-            // This will check that there isn't another apk declaring the same package, or
-            // that another install used a different key.
-            boolean installResult =  installPackage(launchInfo, remotePath, device);
-            
-            // now we delete the app we sync'ed
-            try {
-                device.executeShellCommand("rm " + remotePath, new MultiLineReceiver() { //$NON-NLS-1$
-                    @Override
-                    public void processNewLines(String[] lines) {
-                        // pass
-                    }
-                    public boolean isCancelled() {
-                        return false;
-                    }
-                });
-            } catch (IOException e) {
-                AdtPlugin.printErrorToConsole(launchInfo.mProject, String.format(
-                        "Failed to delete temporary package: %1$s", e.getMessage()));
-                return false;
-            }
-            
-            return installResult;
-        }
-
-        String msg = String.format(
-                "Failed to upload %1$s on device '%2$s': Unable to open sync connection!",
-                launchInfo.mPackageFile.getName(), device.getSerialNumber());
-        AdtPlugin.printErrorToConsole(launchInfo.mProject, msg);
-
-        return false;
-    }
-
-    /**
-     * Installs the application package that was pushed to a temporary location on the device.
-     * @param launchInfo The launch information
-     * @param remotePath The remote path of the package.
-     * @param device The device on which the launch is done.
-     */
-    private boolean installPackage(DelayedLaunchInfo launchInfo, final String remotePath,
-            final Device device) {
-
-        String message = String.format("Installing %1$s...", launchInfo.mPackageFile.getName());
-        AdtPlugin.printToConsole(launchInfo.mProject, message);
-
-        try {
-            String result = doInstall(launchInfo, remotePath, device, false /* reinstall */);
-            
-            /* For now we force to retry the install (after uninstalling) because there's no
-             * other way around it: adb install does not want to update a package w/o uninstalling
-             * the old one first!
-             */
-            return checkInstallResult(result, device, launchInfo, remotePath,
-                    InstallRetryMode.ALWAYS);
-        } catch (IOException e) {
-            // do nothing, we'll return false
-        }
-        
-        return false;
-    }
-
-    /**
-     * Checks the result of an installation, and takes optional actions based on it.
-     * @param result the result string from the installation
-     * @param device the device on which the installation occured.
-     * @param launchInfo the {@link DelayedLaunchInfo}
-     * @param remotePath the temporary path of the package on the device
-     * @param retryMode indicates what to do in case, a package already exists.
-     * @return <code>true<code> if success, <code>false</code> otherwise.
-     * @throws IOException
-     */
-    private boolean checkInstallResult(String result, Device device, DelayedLaunchInfo launchInfo,
-            String remotePath, InstallRetryMode retryMode) throws IOException {
-        if (result == null) {
-            AdtPlugin.printToConsole(launchInfo.mProject, "Success!");
-            return true;
-        } else if (result.equals("INSTALL_FAILED_ALREADY_EXISTS")) { //$NON-NLS-1$
-            if (retryMode == InstallRetryMode.PROMPT) {
-                boolean prompt = AdtPlugin.displayPrompt("Application Install",
-                        "A previous installation needs to be uninstalled before the new package can be installed.\nDo you want to uninstall?");
-                if (prompt) {
-                    retryMode = InstallRetryMode.ALWAYS;
-                } else {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                        "Installation error! The package already exists.");
-                    return false;
-                }
-            }
-
-            if (retryMode == InstallRetryMode.ALWAYS) {
-                /*
-                 * TODO: create a UI that gives the dev the choice to:
-                 * - clean uninstall on launch
-                 * - full uninstall if application exists.
-                 * - soft uninstall if application exists (keeps the app data around).
-                 * - always ask (choice of soft-reinstall, full reinstall)
-                AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                        "Application already exists, uninstalling...");
-                String res = doUninstall(device, launchInfo);
-                if (res == null) {
-                    AdtPlugin.printToConsole(launchInfo.mProject, "Success!");
-                } else {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            String.format("Failed to uninstall: %1$s", res));
-                    return false;
-                }
-                */
-
-                AdtPlugin.printToConsole(launchInfo.mProject,
-                        "Application already exists. Attempting to re-install instead...");
-                String res = doInstall(launchInfo, remotePath, device, true /* reinstall */);
-                return checkInstallResult(res, device, launchInfo, remotePath,
-                        InstallRetryMode.NEVER);
-            }
-
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                    "Installation error! The package already exists.");
-        } else if (result.equals("INSTALL_FAILED_INVALID_APK")) { //$NON-NLS-1$
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                "Installation failed due to invalid APK file!",
-                "Please check logcat output for more details.");
-        } else if (result.equals("INSTALL_FAILED_INVALID_URI")) { //$NON-NLS-1$
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                "Installation failed due to invalid URI!",
-                "Please check logcat output for more details.");
-        } else if (result.equals("INSTALL_FAILED_COULDNT_COPY")) { //$NON-NLS-1$
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                String.format("Installation failed: Could not copy %1$s to its final location!",
-                        launchInfo.mPackageFile.getName()),
-                "Please check logcat output for more details.");
-        } else if (result.equals("INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES")) {
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                    "Re-installation failed due to different application signatures.",
-                    "You must perform a full uninstall of the application. WARNING: This will remove the application data!",
-                    String.format("Please execute 'adb uninstall %1$s' in a shell.", launchInfo.mPackageName));
-        } else {
-            AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                String.format("Installation error: %1$s", result),
-                "Please check logcat output for more details.");
-        }
-
-        return false;
-    }
-
-    /**
-     * Performs the uninstallation of an application.
-     * @param device the device on which to install the application.
-     * @param launchInfo the {@link DelayedLaunchInfo}.
-     * @return a {@link String} with an error code, or <code>null</code> if success.
-     * @throws IOException 
-     */
-    @SuppressWarnings("unused")
-    private String doUninstall(Device device, DelayedLaunchInfo launchInfo) throws IOException {
-        InstallReceiver receiver = new InstallReceiver();
-        try {
-            device.executeShellCommand("pm uninstall " + launchInfo.mPackageName, //$NON-NLS-1$
-                    receiver);
-        } catch (IOException e) {
-            String msg = String.format(
-                    "Failed to uninstall %1$s: %2$s", launchInfo.mPackageName, e.getMessage());
-            AdtPlugin.printErrorToConsole(launchInfo.mProject, msg);
-            throw e;
-        }
-        
-        return receiver.getSuccess();
-    }
-
-    /**
-     * Performs the installation of an application whose package has been uploaded on the device.
-     * <p/>Before doing it, if the application is already running on the device, it is killed. 
-     * @param launchInfo the {@link DelayedLaunchInfo}.
-     * @param remotePath the path of the application package in the device tmp folder.
-     * @param device the device on which to install the application.
-     * @param reinstall 
-     * @return a {@link String} with an error code, or <code>null</code> if success.
-     * @throws IOException 
-     */
-    private String doInstall(DelayedLaunchInfo launchInfo, final String remotePath,
-            final Device device, boolean reinstall) throws IOException {
-        // kill running application
-        Client application = device.getClient(launchInfo.mPackageName);
-        if (application != null) {
-            application.kill();
-        }
-        
-        InstallReceiver receiver = new InstallReceiver();
-        try {
-            String cmd = String.format(
-                    reinstall ? "pm install -r \"%1$s\"" : "pm install \"%1$s\"", //$NON-NLS-1$ //$NON-NLS-2$
-                    remotePath); //$NON-NLS-1$ //$NON-NLS-2$
-            device.executeShellCommand(cmd, receiver);
-        } catch (IOException e) {
-            String msg = String.format(
-                    "Failed to install %1$s on device '%2$s': %3$s",
-                    launchInfo.mPackageFile.getName(), device.getSerialNumber(), e.getMessage());
-            AdtPlugin.printErrorToConsole(launchInfo.mProject, msg);
-            throw e;
-        }
-        
-        return receiver.getSuccess();
-    }
-    
-    /**
-     * launches an application on a device or emulator
-     *
-     * @param info the {@link DelayedLaunchInfo} that indicates the activity to launch
-     * @param device the device or emulator to launch the application on
-     */
-    private void launchApp(final DelayedLaunchInfo info, Device device) {
-        // if we're not supposed to do anything, just stop the Launch item and return;
-        if (info.mLaunchAction == LaunchConfigDelegate.ACTION_DO_NOTHING) {
-            String msg = String.format("%1$s installed on device",
-                    info.mPackageFile.getFullPath().toOSString());
-            AdtPlugin.printToConsole(info.mProject, msg, "Done!");
-            info.mLaunch.stopLaunch();
-            return;
-        }
-        try {
-            String msg = String.format("Starting activity %1$s on device ", info.mActivity,
-                    info.mDevice);
-            AdtPlugin.printToConsole(info.mProject, msg);
-
-            // In debug mode, we need to add the info to the list of application monitoring
-            // client changes.
-            if (info.mDebugMode) {
-                synchronized (sListLock) {
-                    if (mWaitingForDebuggerApplications.contains(info) == false) {
-                        mWaitingForDebuggerApplications.add(info);
-                    }
-                }
-            }
-
-            // increment launch attempt count, to handle retries and timeouts
-            info.mAttemptCount++;
-
-            // now we actually launch the app.
-            device.executeShellCommand("am start" //$NON-NLS-1$
-                    + (info.mDebugMode ? " -D" //$NON-NLS-1$
-                            : "") //$NON-NLS-1$
-                    + " -n " //$NON-NLS-1$
-                    + info.mPackageName + "/" //$NON-NLS-1$
-                    + info.mActivity.replaceAll("\\$", "\\\\\\$"), //$NON-NLS-1$ //$NON-NLS-2$
-                    new AMReceiver(info, device));
-
-            // if the app is not a debug app, we need to do some clean up, as
-            // the process is done!
-            if (info.mDebugMode == false) {
-                // stop the launch object, since there's no debug, and it can't
-                // provide any control over the app
-                info.mLaunch.stopLaunch();
-            }
-        } catch (IOException e) {
-            // something went wrong trying to launch the app.
-            // lets stop the Launch
-            AdtPlugin.printErrorToConsole(info.mProject,
-                    String.format("Launch error: %s", e.getMessage()));
-            info.mLaunch.stopLaunch();
-
-            // and remove it from the list of app waiting for debuggers
-            synchronized (sListLock) {
-                mWaitingForDebuggerApplications.remove(info);
-            }
-        }
-    }
-
-    private boolean launchEmulator(AndroidLaunchConfiguration config, AvdInfo avdToLaunch) {
-
-        // split the custom command line in segments
-        ArrayList<String> customArgs = new ArrayList<String>();
-        boolean has_wipe_data = false;
-        if (config.mEmulatorCommandLine != null && config.mEmulatorCommandLine.length() > 0) {
-            String[] segments = config.mEmulatorCommandLine.split("\\s+"); //$NON-NLS-1$
-
-            // we need to remove the empty strings
-            for (String s : segments) {
-                if (s.length() > 0) {
-                    customArgs.add(s);
-                    if (!has_wipe_data && s.equals(FLAG_WIPE_DATA)) {
-                        has_wipe_data = true;
-                    }
-                }
-            }
-        }
-
-        boolean needs_wipe_data = config.mWipeData && !has_wipe_data;
-        if (needs_wipe_data) {
-            if (!AdtPlugin.displayPrompt("Android Launch", "Are you sure you want to wipe all user data when starting this emulator?")) {
-                needs_wipe_data = false;
-            }
-        }
-        
-        // build the command line based on the available parameters.
-        ArrayList<String> list = new ArrayList<String>();
-
-        list.add(AdtPlugin.getOsAbsoluteEmulator());
-        list.add(FLAG_AVD);
-        list.add(avdToLaunch.getName());
-        
-        if (config.mNetworkSpeed != null) {
-            list.add(FLAG_NETSPEED);
-            list.add(config.mNetworkSpeed);
-        }
-        
-        if (config.mNetworkDelay != null) {
-            list.add(FLAG_NETDELAY);
-            list.add(config.mNetworkDelay);
-        }
-        
-        if (needs_wipe_data) {
-            list.add(FLAG_WIPE_DATA);
-        }
-
-        if (config.mNoBootAnim) {
-            list.add(FLAG_NO_BOOT_ANIM);
-        }
-
-        list.addAll(customArgs);
-        
-        // convert the list into an array for the call to exec.
-        String[] command = list.toArray(new String[list.size()]);
-
-        // launch the emulator
-        try {
-            Process process = Runtime.getRuntime().exec(command);
-            grabEmulatorOutput(process);
-        } catch (IOException e) {
-            return false;
-        }
-
-        return true;
-    }
-    
-    /**
-     * Looks for and returns an existing {@link ILaunchConfiguration} object for a
-     * specified project.
-     * @param manager The {@link ILaunchManager}.
-     * @param type The {@link ILaunchConfigurationType}.
-     * @param projectName The name of the project
-     * @return an existing <code>ILaunchConfiguration</code> object matching the project, or
-     *      <code>null</code>.
-     */
-    private static ILaunchConfiguration findConfig(ILaunchManager manager,
-            ILaunchConfigurationType type, String projectName) {
-        try {
-            ILaunchConfiguration[] configs = manager.getLaunchConfigurations(type);
-
-            for (ILaunchConfiguration config : configs) {
-                if (config.getAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME,
-                        "").equals(projectName)) {  //$NON-NLS-1$
-                    return config;
-                }
-            }
-        } catch (CoreException e) {
-            MessageDialog.openError(AdtPlugin.getDisplay().getActiveShell(),
-                    "Launch Error", e.getStatus().getMessage());
-        }
-
-        // didn't find anything that matches. Return null
-        return null;
-
-    }
-
-
-    /**
-     * Connects a remote debugger on the specified port.
-     * @param debugPort The port to connect the debugger to
-     * @param launch The associated AndroidLaunch object.
-     * @param monitor A Progress monitor
-     * @return false if cancelled by the monitor
-     * @throws CoreException
-     */
-    public static boolean connectRemoteDebugger(int debugPort,
-            AndroidLaunch launch, IProgressMonitor monitor)
-                throws CoreException {
-        // get some default parameters.
-        int connectTimeout = JavaRuntime.getPreferences().getInt(JavaRuntime.PREF_CONNECT_TIMEOUT);
-
-        HashMap<String, String> newMap = new HashMap<String, String>();
-
-        newMap.put("hostname", "localhost");  //$NON-NLS-1$ //$NON-NLS-2$
-
-        newMap.put("port", Integer.toString(debugPort)); //$NON-NLS-1$
-
-        newMap.put("timeout", Integer.toString(connectTimeout));
-
-        // get the default VM connector
-        IVMConnector connector = JavaRuntime.getDefaultVMConnector();
-
-        // connect to remote VM
-        connector.connect(newMap, monitor, launch);
-
-        // check for cancellation
-        if (monitor.isCanceled()) {
-            IDebugTarget[] debugTargets = launch.getDebugTargets();
-            for (IDebugTarget target : debugTargets) {
-                if (target.canDisconnect()) {
-                    target.disconnect();
-                }
-            }
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Launch a new thread that connects a remote debugger on the specified port.
-     * @param debugPort The port to connect the debugger to
-     * @param androidLaunch The associated AndroidLaunch object.
-     * @param monitor A Progress monitor
-     * @see #connectRemoteDebugger(int, AndroidLaunch, IProgressMonitor)
-     */
-    public static void launchRemoteDebugger( final int debugPort, final AndroidLaunch androidLaunch,
-            final IProgressMonitor monitor) {
-        new Thread("Debugger connection") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                try {
-                    connectRemoteDebugger(debugPort, androidLaunch, monitor);
-                } catch (CoreException e) {
-                    androidLaunch.stopLaunch();
-                }
-                monitor.done();
-            }
-        }.start();
-    }
-
-    /**
-     * Sent when a new {@link AndroidDebugBridge} is started.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param bridge the new {@link AndroidDebugBridge} object.
-     * 
-     * @see IDebugBridgeChangeListener#bridgeChanged(AndroidDebugBridge)
-     */
-    public void bridgeChanged(AndroidDebugBridge bridge) {
-        // The adb server has changed. We cancel any pending launches.
-        String message1 = "adb server change: cancelling '%1$s' launch!";
-        String message2 = "adb server change: cancelling sync!";
-        synchronized (sListLock) {
-            for (DelayedLaunchInfo launchInfo : mWaitingForReadyEmulatorList) {
-                if (launchInfo.mLaunchAction == LaunchConfigDelegate.ACTION_DO_NOTHING) {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject, message2);
-                } else {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            String.format(message1, launchInfo.mActivity));
-                }
-                launchInfo.mLaunch.stopLaunch();
-            }
-            for (DelayedLaunchInfo launchInfo : mWaitingForDebuggerApplications) {
-                if (launchInfo.mLaunchAction == LaunchConfigDelegate.ACTION_DO_NOTHING) {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject, message2);
-                } else {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            String.format(message1, launchInfo.mActivity));
-                }
-                launchInfo.mLaunch.stopLaunch();
-            }
-
-            mWaitingForReadyEmulatorList.clear();
-            mWaitingForDebuggerApplications.clear();
-        }
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceConnected(Device)
-     */
-    public void deviceConnected(Device device) {
-        synchronized (sListLock) {
-            // look if there's an app waiting for a device
-            if (mWaitingForEmulatorLaunches.size() > 0) {
-                // get/remove first launch item from the list
-                // FIXME: what if we have multiple launches waiting?
-                DelayedLaunchInfo launchInfo = mWaitingForEmulatorLaunches.get(0);
-                mWaitingForEmulatorLaunches.remove(0);
-
-                // give the launch item its device for later use.
-                launchInfo.mDevice = device;
-
-                // and move it to the other list
-                mWaitingForReadyEmulatorList.add(launchInfo);
-                
-                // and tell the user about it
-                AdtPlugin.printToConsole(launchInfo.mProject,
-                        String.format("New emulator found: %1$s", device.getSerialNumber()));
-                AdtPlugin.printToConsole(launchInfo.mProject,
-                        String.format("Waiting for HOME ('%1$s') to be launched...",
-                            AdtPlugin.getDefault().getPreferenceStore().getString(
-                                    AdtPlugin.PREFS_HOME_PACKAGE)));
-            }
-        }
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceDisconnected(Device)
-     */
-    @SuppressWarnings("unchecked")
-    public void deviceDisconnected(Device device) {
-        // any pending launch on this device must be canceled.
-        String message = "%1$s disconnected! Cancelling '%2$s' launch!";
-        synchronized (sListLock) {
-            ArrayList<DelayedLaunchInfo> copyList =
-                (ArrayList<DelayedLaunchInfo>)mWaitingForReadyEmulatorList.clone();
-            for (DelayedLaunchInfo launchInfo : copyList) {
-                if (launchInfo.mDevice == device) {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            String.format(message, device.getSerialNumber(), launchInfo.mActivity));
-                    launchInfo.mLaunch.stopLaunch();
-                    mWaitingForReadyEmulatorList.remove(launchInfo);
-                }
-            }
-            copyList = (ArrayList<DelayedLaunchInfo>)mWaitingForDebuggerApplications.clone();
-            for (DelayedLaunchInfo launchInfo : copyList) {
-                if (launchInfo.mDevice == device) {
-                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                            String.format(message, device.getSerialNumber(), launchInfo.mActivity));
-                    launchInfo.mLaunch.stopLaunch();
-                    mWaitingForDebuggerApplications.remove(launchInfo);
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a device data changed, or when clients are started/terminated on the device.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the device that was updated.
-     * @param changeMask the mask indicating what changed.
-     * 
-     * @see IDeviceChangeListener#deviceChanged(Device, int)
-     */
-    public void deviceChanged(Device device, int changeMask) {
-        // We could check if any starting device we care about is now ready, but we can wait for
-        // its home app to show up, so...
-    }
-
-    /**
-     * Sent when an existing client information changed.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param client the updated client.
-     * @param changeMask the bit mask describing the changed properties. It can contain
-     * any of the following values: {@link Client#CHANGE_INFO}, {@link Client#CHANGE_NAME}
-     * {@link Client#CHANGE_DEBUGGER_INTEREST}, {@link Client#CHANGE_THREAD_MODE},
-     * {@link Client#CHANGE_THREAD_DATA}, {@link Client#CHANGE_HEAP_MODE},
-     * {@link Client#CHANGE_HEAP_DATA}, {@link Client#CHANGE_NATIVE_HEAP_DATA} 
-     * 
-     * @see IClientChangeListener#clientChanged(Client, int)
-     */
-    public void clientChanged(final Client client, int changeMask) {
-        boolean connectDebugger = false;
-        if ((changeMask & Client.CHANGE_NAME) == Client.CHANGE_NAME) {
-            String applicationName = client.getClientData().getClientDescription();
-            if (applicationName != null) {
-                IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-                String home = store.getString(AdtPlugin.PREFS_HOME_PACKAGE);
-                
-                if (home.equals(applicationName)) {
-                    
-                    // looks like home is up, get its device
-                    Device device = client.getDevice();
-                    
-                    // look for application waiting for home
-                    synchronized (sListLock) {
-                        for (int i = 0 ; i < mWaitingForReadyEmulatorList.size() ;) {
-                            DelayedLaunchInfo launchInfo = mWaitingForReadyEmulatorList.get(i);
-                            if (launchInfo.mDevice == device) {
-                                // it's match, remove from the list
-                                mWaitingForReadyEmulatorList.remove(i);
-                                
-                                // We couldn't check earlier the API level of the device
-                                // (it's asynchronous when the device boot, and usually
-                                // deviceConnected is called before it's queried for its build info)
-                                // so we check now
-                                if (checkBuildInfo(launchInfo, device) == false) {
-                                    // device is not the proper API!
-                                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                                            "Launch canceled!");
-                                    launchInfo.mLaunch.stopLaunch();
-                                    return;
-                                }
-        
-                                AdtPlugin.printToConsole(launchInfo.mProject,
-                                        String.format("HOME is up on device '%1$s'",
-                                                device.getSerialNumber()));
-                                
-                                // attempt to sync the new package onto the device.
-                                if (syncApp(launchInfo, device)) {
-                                    // application package is sync'ed, lets attempt to launch it.
-                                    launchApp(launchInfo, device);
-                                } else {
-                                    // failure! Cancel and return
-                                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                                    "Launch canceled!");
-                                    launchInfo.mLaunch.stopLaunch();
-                                }
-                                
-                                break;
-                            } else {
-                                i++;
-                            }
-                        }
-                    }
-                }
-    
-                // check if it's already waiting for a debugger, and if so we connect to it.
-                if (client.getClientData().getDebuggerConnectionStatus() == ClientData.DEBUGGER_WAITING) {
-                    // search for this client in the list;
-                    synchronized (sListLock) {
-                        int index = mUnknownClientsWaitingForDebugger.indexOf(client);
-                        if (index != -1) {
-                            connectDebugger = true;
-                            mUnknownClientsWaitingForDebugger.remove(client);
-                        }
-                    }
-                }
-            }
-        }
-        
-        // if it's not home, it could be an app that is now in debugger mode that we're waiting for
-        // lets check it
-
-        if ((changeMask & Client.CHANGE_DEBUGGER_INTEREST) == Client.CHANGE_DEBUGGER_INTEREST) {
-            ClientData clientData = client.getClientData();
-            String applicationName = client.getClientData().getClientDescription();
-            if (clientData.getDebuggerConnectionStatus() == ClientData.DEBUGGER_WAITING) {
-                // Get the application name, and make sure its valid.
-                if (applicationName == null) {
-                    // looks like we don't have the client yet, so we keep it around for when its
-                    // name becomes available.
-                    synchronized (sListLock) {
-                        mUnknownClientsWaitingForDebugger.add(client);
-                    }
-                    return;
-                } else {
-                    connectDebugger = true;
-                }
-            }
-        }
-
-        if (connectDebugger) {
-            Log.d("adt", "Debugging " + client);
-            // now check it against the apps waiting for a debugger
-            String applicationName = client.getClientData().getClientDescription();
-            Log.d("adt", "App Name: " + applicationName);
-            synchronized (sListLock) {
-                for (int i = 0 ; i < mWaitingForDebuggerApplications.size() ;) {
-                    final DelayedLaunchInfo launchInfo = mWaitingForDebuggerApplications.get(i);
-                    if (client.getDevice() == launchInfo.mDevice &&
-                            applicationName.equals(launchInfo.mPackageName)) {
-                        // this is a match. We remove the launch info from the list
-                        mWaitingForDebuggerApplications.remove(i);
-                        
-                        // and connect the debugger.
-                        String msg = String.format(
-                                "Attempting to connect debugger to '%1$s' on port %2$d",
-                                launchInfo.mPackageName, client.getDebuggerListenPort());
-                        AdtPlugin.printToConsole(launchInfo.mProject, msg);
-                        
-                        new Thread("Debugger Connection") { //$NON-NLS-1$
-                            @Override
-                            public void run() {
-                                try {
-                                    if (connectRemoteDebugger(
-                                            client.getDebuggerListenPort(),
-                                            launchInfo.mLaunch, launchInfo.mMonitor) == false) {
-                                        return;
-                                    }
-                                } catch (CoreException e) {
-                                    // well something went wrong.
-                                    AdtPlugin.printErrorToConsole(launchInfo.mProject,
-                                            String.format("Launch error: %s", e.getMessage()));
-                                    // stop the launch
-                                    launchInfo.mLaunch.stopLaunch();
-                                }
-
-                                launchInfo.mMonitor.done();
-                            }
-                        }.start();
-                        
-                        // we're done processing this client.
-                        return;
-
-                    } else {
-                        i++;
-                    }
-                }
-            }
-            
-            // if we get here, we haven't found an app that we were launching, so we look
-            // for opened android projects that contains the app asking for a debugger.
-            // If we find one, we automatically connect to it.
-            IProject project = ProjectHelper.findAndroidProjectByAppName(applicationName);
-            
-            if (project != null) {
-                debugRunningApp(project, client.getDebuggerListenPort());
-            }
-        }
-    }
-    
-    /**
-     * Get the stderr/stdout outputs of a process and return when the process is done.
-     * Both <b>must</b> be read or the process will block on windows.
-     * @param process The process to get the ouput from
-     */
-    private void grabEmulatorOutput(final Process process) {
-        // read the lines as they come. if null is returned, it's
-        // because the process finished
-        new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                // create a buffer to read the stderr output
-                InputStreamReader is = new InputStreamReader(process.getErrorStream());
-                BufferedReader errReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = errReader.readLine();
-                        if (line != null) {
-                            AdtPlugin.printErrorToConsole("Emulator", line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        }.start();
-
-        new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                InputStreamReader is = new InputStreamReader(process.getInputStream());
-                BufferedReader outReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = outReader.readLine();
-                        if (line != null) {
-                            AdtPlugin.printToConsole("Emulator", line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        }.start();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/DeviceChooserDialog.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/DeviceChooserDialog.java
deleted file mode 100644
index a260350..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/DeviceChooserDialog.java
+++ /dev/null
@@ -1,705 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.launching;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.IDevice;
-import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener;
-import com.android.ddmlib.Device.DeviceState;
-import com.android.ddmuilib.IImageLoader;
-import com.android.ddmuilib.ImageHelper;
-import com.android.ddmuilib.TableHelper;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.avd.AvdManager;
-import com.android.sdklib.avd.AvdManager.AvdInfo;
-import com.android.sdkuilib.AvdSelector;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-
-import java.util.ArrayList;
-
-public class DeviceChooserDialog extends Dialog implements IDeviceChangeListener {
-
-    private final static int ICON_WIDTH = 16;
-
-    private final static String PREFS_COL_SERIAL = "deviceChooser.serial"; //$NON-NLS-1$
-    private final static String PREFS_COL_STATE  = "deviceChooser.state"; //$NON-NLS-1$
-    private final static String PREFS_COL_AVD     = "deviceChooser.avd"; //$NON-NLS-1$
-    private final static String PREFS_COL_TARGET = "deviceChooser.target"; //$NON-NLS-1$
-    private final static String PREFS_COL_DEBUG  = "deviceChooser.debug"; //$NON-NLS-1$
-
-    private Table mDeviceTable;
-    private TableViewer mViewer;
-    private AvdSelector mPreferredAvdSelector;
-    
-    private Image mDeviceImage;
-    private Image mEmulatorImage;
-    private Image mMatchImage;
-    private Image mNoMatchImage;
-    private Image mWarningImage;
-
-    private final DeviceChooserResponse mResponse;
-    private final String mPackageName;
-    private final IAndroidTarget mProjectTarget;
-    private final Sdk mSdk;
-
-    private final AvdInfo[] mFullAvdList;
-
-    private Button mDeviceRadioButton;
-
-    private boolean mDisableAvdSelectionChange = false;
-    
-    /**
-     * Basic Content Provider for a table full of {@link Device} objects. The input is
-     * a {@link AndroidDebugBridge}.
-     */
-    private class ContentProvider implements IStructuredContentProvider {
-        public Object[] getElements(Object inputElement) {
-            if (inputElement instanceof AndroidDebugBridge) {
-                return ((AndroidDebugBridge)inputElement).getDevices();
-            }
-
-            return new Object[0];
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            // pass
-        }
-    }
-    
-
-    /**
-     * A Label Provider for the {@link TableViewer} in {@link DeviceChooserDialog}.
-     * It provides labels and images for {@link Device} objects.
-     */
-    private class LabelProvider implements ITableLabelProvider {
-
-        public Image getColumnImage(Object element, int columnIndex) {
-            if (element instanceof Device) {
-                Device device = (Device)element;
-                switch (columnIndex) {
-                    case 0:
-                        return device.isEmulator() ? mEmulatorImage : mDeviceImage;
-                        
-                    case 2:
-                        // check for compatibility.
-                        if (device.isEmulator() == false) { // physical device
-                            // get the api level of the device
-                            try {
-                                String apiValue = device.getProperty(
-                                        IDevice.PROP_BUILD_VERSION_NUMBER);
-                                if (apiValue != null) {
-                                    int api = Integer.parseInt(apiValue);
-                                    if (api >= mProjectTarget.getApiVersionNumber()) {
-                                        // if the project is compiling against an add-on, the optional
-                                        // API may be missing from the device.
-                                        return mProjectTarget.isPlatform() ?
-                                                mMatchImage : mWarningImage;
-                                    } else {
-                                        return mNoMatchImage;
-                                    }
-                                } else {
-                                    return mWarningImage;
-                                }
-                            } catch (NumberFormatException e) {
-                                // lets consider the device non compatible
-                                return mNoMatchImage;
-                            }
-                        } else {
-                            // get the AvdInfo
-                            AvdInfo info = mSdk.getAvdManager().getAvd(device.getAvdName());
-                            if (info == null) {
-                                return mWarningImage;
-                            }
-                            return mProjectTarget.isCompatibleBaseFor(info.getTarget()) ?
-                                    mMatchImage : mNoMatchImage;
-                        }
-                }
-            }
-
-            return null;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            if (element instanceof Device) {
-                Device device = (Device)element;
-                switch (columnIndex) {
-                    case 0:
-                        return device.getSerialNumber();
-                    case 1:
-                        if (device.isEmulator()) {
-                            return device.getAvdName();
-                        } else {
-                            return "N/A"; // devices don't have AVD names.
-                        }
-                    case 2:
-                        if (device.isEmulator()) {
-                            AvdInfo info = mSdk.getAvdManager().getAvd(device.getAvdName());
-                            if (info == null) {
-                                return "?";
-                            }
-                            return info.getTarget().getFullName();
-                        } else {
-                            String deviceBuild = device.getProperty(IDevice.PROP_BUILD_VERSION);
-                            if (deviceBuild == null) {
-                                return "unknown";
-                            }
-                            return deviceBuild;
-                        }
-                    case 3:
-                        String debuggable = device.getProperty(IDevice.PROP_DEBUGGABLE);
-                        if (debuggable != null && debuggable.equals("1")) { //$NON-NLS-1$
-                            return "Yes";
-                        } else {
-                            return "";
-                        }
-                    case 4:
-                        return getStateString(device);
-                }
-            }
-
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-    
-    public static class DeviceChooserResponse {
-        private AvdInfo mAvdToLaunch;
-        private Device mDeviceToUse;
-        
-        public void setDeviceToUse(Device d) {
-            mDeviceToUse = d;
-            mAvdToLaunch = null;
-        }
-        
-        public void setAvdToLaunch(AvdInfo avd) {
-            mAvdToLaunch = avd;
-            mDeviceToUse = null;
-        }
-        
-        public Device getDeviceToUse() {
-            return mDeviceToUse;
-        }
-        
-        public AvdInfo getAvdToLaunch() {
-            return mAvdToLaunch;
-        }
-    }
-    
-    public DeviceChooserDialog(Shell parent, DeviceChooserResponse response, String packageName,
-            IAndroidTarget projectTarget) {
-        super(parent);
-        mResponse = response;
-        mPackageName = packageName;
-        mProjectTarget = projectTarget;
-        mSdk = Sdk.getCurrent();
-        
-        // get the full list of Android Virtual Devices
-        AvdManager avdManager = mSdk.getAvdManager();
-        if (avdManager != null) {
-            mFullAvdList = avdManager.getAvds();
-        } else {
-            mFullAvdList = null;
-        }
-
-        loadImages();
-    }
-
-    private void cleanup() {
-        // done listening.
-        AndroidDebugBridge.removeDeviceChangeListener(this);
-
-        mEmulatorImage.dispose();
-        mDeviceImage.dispose();
-        mMatchImage.dispose();
-        mNoMatchImage.dispose();
-        mWarningImage.dispose();
-    }
-    
-    @Override
-    protected void okPressed() {
-        cleanup();
-        super.okPressed();
-    }
-    
-    @Override
-    protected void cancelPressed() {
-        cleanup();
-        super.cancelPressed();
-    }
-    
-    @Override
-    protected Control createContents(Composite parent) {
-        Control content = super.createContents(parent);
-        
-        // this must be called after createContents() has happened so that the
-        // ok button has been created (it's created after the call to createDialogArea)
-        updateDefaultSelection();
-
-        return content;
-    }
-
-    
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayout(new GridLayout(1, true));
-
-        mDeviceRadioButton = new Button(top, SWT.RADIO);
-        mDeviceRadioButton.setText("Choose a running Android device");
-        mDeviceRadioButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                boolean deviceMode = mDeviceRadioButton.getSelection();
-
-                mDeviceTable.setEnabled(deviceMode);
-                mPreferredAvdSelector.setEnabled(!deviceMode);
-
-                if (deviceMode) {
-                    handleDeviceSelection();
-                } else {
-                    mResponse.setAvdToLaunch(mPreferredAvdSelector.getFirstSelected());
-                }
-                
-                enableOkButton();
-            }
-        });
-        mDeviceRadioButton.setSelection(true);
-        
-
-        // offset the selector from the radio button
-        Composite offsetComp = new Composite(top, SWT.NONE);
-        offsetComp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        GridLayout layout = new GridLayout(1, false);
-        layout.marginRight = layout.marginHeight = 0;
-        layout.marginLeft = 30;
-        offsetComp.setLayout(layout);
-
-        IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore(); 
-        mDeviceTable = new Table(offsetComp, SWT.SINGLE | SWT.FULL_SELECTION);
-        GridData gd;
-        mDeviceTable.setLayoutData(gd = new GridData(GridData.FILL_BOTH));
-        gd.heightHint = 100;
-
-        mDeviceTable.setHeaderVisible(true);
-        mDeviceTable.setLinesVisible(true);
-
-        TableHelper.createTableColumn(mDeviceTable, "Serial Number",
-                SWT.LEFT, "AAA+AAAAAAAAAAAAAAAAAAA", //$NON-NLS-1$
-                PREFS_COL_SERIAL, store);
-
-        TableHelper.createTableColumn(mDeviceTable, "AVD Name",
-                SWT.LEFT, "engineering", //$NON-NLS-1$
-                PREFS_COL_AVD, store);
-
-        TableHelper.createTableColumn(mDeviceTable, "Target",
-                SWT.LEFT, "AAA+Android 9.9.9", //$NON-NLS-1$
-                PREFS_COL_TARGET, store);
-
-        TableHelper.createTableColumn(mDeviceTable, "Debug",
-                SWT.LEFT, "Debug", //$NON-NLS-1$
-                PREFS_COL_DEBUG, store);
-
-        TableHelper.createTableColumn(mDeviceTable, "State",
-                SWT.LEFT, "bootloader", //$NON-NLS-1$
-                PREFS_COL_STATE, store);
-
-        // create the viewer for it
-        mViewer = new TableViewer(mDeviceTable);
-        mViewer.setContentProvider(new ContentProvider());
-        mViewer.setLabelProvider(new LabelProvider());
-        mViewer.setInput(AndroidDebugBridge.getBridge());
-        mViewer.addDoubleClickListener(new IDoubleClickListener() {
-            public void doubleClick(DoubleClickEvent event) {
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structuredSelection = (IStructuredSelection)selection;
-                    Object object = structuredSelection.getFirstElement();
-                    if (object instanceof Device) {
-                        mResponse.setDeviceToUse((Device)object);
-                    }
-                }
-            }
-        });
-        
-        Button radio2 = new Button(top, SWT.RADIO);
-        radio2.setText("Launch a new Android Virtual Device");
-
-        // offset the selector from the radio button
-        offsetComp = new Composite(top, SWT.NONE);
-        offsetComp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        layout = new GridLayout(1, false);
-        layout.marginRight = layout.marginHeight = 0;
-        layout.marginLeft = 30;
-        offsetComp.setLayout(layout);
-        
-        mPreferredAvdSelector = new AvdSelector(offsetComp, getNonRunningAvds(), mProjectTarget,
-                false /*allowMultipleSelection*/);
-        mPreferredAvdSelector.setTableHeightHint(100);
-        mPreferredAvdSelector.setEnabled(false);
-        mDeviceTable.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                handleDeviceSelection();
-            }
-        });
-        
-        mPreferredAvdSelector.setSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (mDisableAvdSelectionChange == false) {
-                    mResponse.setAvdToLaunch(mPreferredAvdSelector.getFirstSelected());
-                    enableOkButton();
-                }
-            }
-        });
-        
-        AndroidDebugBridge.addDeviceChangeListener(this);
-
-        return top;
-    }
-    
-    private void loadImages() {
-        IImageLoader ddmsLoader = DdmsPlugin.getImageLoader();
-        Display display = DdmsPlugin.getDisplay();
-        IImageLoader adtLoader = AdtPlugin.getImageLoader();
-
-        if (mDeviceImage == null) {
-            mDeviceImage = ImageHelper.loadImage(ddmsLoader, display,
-                    "device.png", //$NON-NLS-1$
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_RED));
-        }
-        if (mEmulatorImage == null) {
-            mEmulatorImage = ImageHelper.loadImage(ddmsLoader, display,
-                    "emulator.png", ICON_WIDTH, ICON_WIDTH, //$NON-NLS-1$
-                    display.getSystemColor(SWT.COLOR_BLUE));
-        }
-        
-        if (mMatchImage == null) {
-            mMatchImage = ImageHelper.loadImage(adtLoader, display,
-                    "match.png", //$NON-NLS-1$
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_GREEN));
-        }
-
-        if (mNoMatchImage == null) {
-            mNoMatchImage = ImageHelper.loadImage(adtLoader, display,
-                    "error.png", //$NON-NLS-1$
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_RED));
-        }
-
-        if (mWarningImage == null) {
-            mWarningImage = ImageHelper.loadImage(adtLoader, display,
-                    "warning.png", //$NON-NLS-1$
-                    ICON_WIDTH, ICON_WIDTH,
-                    display.getSystemColor(SWT.COLOR_YELLOW));
-        }
-
-    }
-    
-    /**
-     * Returns a display string representing the state of the device.
-     * @param d the device
-     */
-    private static String getStateString(Device d) {
-        DeviceState deviceState = d.getState();
-        if (deviceState == DeviceState.ONLINE) {
-            return "Online";
-        } else if (deviceState == DeviceState.OFFLINE) {
-            return "Offline";
-        } else if (deviceState == DeviceState.BOOTLOADER) {
-            return "Bootloader";
-        }
-
-        return "??";
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceConnected(Device)
-     */
-    public void deviceConnected(Device device) {
-        final DeviceChooserDialog dialog = this;
-        exec(new Runnable() {
-            public void run() {
-                if (mDeviceTable.isDisposed() == false) {
-                    // refresh all
-                    mViewer.refresh();
-                    
-                    // update the selection
-                    updateDefaultSelection();
-                    
-                    // update the display of AvdInfo (since it's filtered to only display
-                    // non running AVD.)
-                    refillAvdList();
-                } else {
-                    // table is disposed, we need to do something.
-                    // lets remove ourselves from the listener.
-                    AndroidDebugBridge.removeDeviceChangeListener(dialog);
-                }
-
-            }
-        });
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceDisconnected(Device)
-     */
-    public void deviceDisconnected(Device device) {
-        deviceConnected(device);
-    }
-
-    /**
-     * Sent when a device data changed, or when clients are started/terminated on the device.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the device that was updated.
-     * @param changeMask the mask indicating what changed.
-     * 
-     * @see IDeviceChangeListener#deviceChanged(Device, int)
-     */
-    public void deviceChanged(final Device device, int changeMask) {
-        if ((changeMask & (Device.CHANGE_STATE | Device.CHANGE_BUILD_INFO)) != 0) {
-            final DeviceChooserDialog dialog = this;
-            exec(new Runnable() {
-                public void run() {
-                    if (mDeviceTable.isDisposed() == false) {
-                        // refresh the device
-                        mViewer.refresh(device);
-                        
-                        // update the defaultSelection.
-                        updateDefaultSelection();
-                    
-                        // update the display of AvdInfo (since it's filtered to only display
-                        // non running AVD). This is done on deviceChanged because the avd name
-                        // of a (emulator) device may be updated as the emulator boots.
-                        refillAvdList();
-
-                        // if the changed device is the current selection,
-                        // we update the OK button based on its state.
-                        if (device == mResponse.getDeviceToUse()) {
-                            enableOkButton();
-                        }
-
-                    } else {
-                        // table is disposed, we need to do something.
-                        // lets remove ourselves from the listener.
-                        AndroidDebugBridge.removeDeviceChangeListener(dialog);
-                    }
-                }
-            });
-        }
-    }
-    
-    /**
-     * Returns whether the dialog is in "device" mode (true), or in "avd" mode (false).
-     */
-    private boolean isDeviceMode() {
-        return mDeviceRadioButton.getSelection();
-    }
-    
-    /**
-     * Enables or disables the OK button of the dialog based on various selections in the dialog.
-     */
-    private void enableOkButton() {
-        Button okButton = getButton(IDialogConstants.OK_ID);
-        
-        if (isDeviceMode()) {
-            okButton.setEnabled(mResponse.getDeviceToUse() != null &&
-                    mResponse.getDeviceToUse().isOnline());
-        } else {
-            okButton.setEnabled(mResponse.getAvdToLaunch() != null);
-        }
-    }
-    
-    /**
-     * Executes the {@link Runnable} in the UI thread.
-     * @param runnable the runnable to execute.
-     */
-    private void exec(Runnable runnable) {
-        try {
-            Display display = mDeviceTable.getDisplay();
-            display.asyncExec(runnable);
-        } catch (SWTException e) {
-            // tree is disposed, we need to do something. lets remove ourselves from the listener.
-            AndroidDebugBridge.removeDeviceChangeListener(this);
-        }
-    }
-    
-    private void handleDeviceSelection() {
-        int count = mDeviceTable.getSelectionCount();
-        if (count != 1) {
-            handleSelection(null);
-        } else {
-            int index = mDeviceTable.getSelectionIndex();
-            Object data = mViewer.getElementAt(index);
-            if (data instanceof Device) {
-                handleSelection((Device)data);
-            } else {
-                handleSelection(null);
-            }
-        }
-    }
-
-    private void handleSelection(Device device) {
-        mResponse.setDeviceToUse(device);
-        enableOkButton();
-    }
-    
-    /**
-     * Look for a default device to select. This is done by looking for the running
-     * clients on each device and finding one similar to the one being launched.
-     * <p/>
-     * This is done every time the device list changed unless there is a already selection.
-     */
-    private void updateDefaultSelection() {
-        if (mDeviceTable.getSelectionCount() == 0) {
-            AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-            
-            Device[] devices = bridge.getDevices();
-            
-            for (Device device : devices) {
-                Client[] clients = device.getClients();
-                
-                for (Client client : clients) {
-                    
-                    if (mPackageName.equals(client.getClientData().getClientDescription())) {
-                        // found a match! Select it.
-                        mViewer.setSelection(new StructuredSelection(device));
-                        handleSelection(device);
-                        
-                        // and we're done.
-                        return;
-                    }
-                }
-            }
-        }
-
-        handleDeviceSelection();
-    }
-    
-    /**
-     * Returns the list of {@link AvdInfo} that are not already running in an emulator.
-     */
-    private AvdInfo[] getNonRunningAvds() {
-        ArrayList<AvdInfo> list = new ArrayList<AvdInfo>();
-        
-        Device[] devices = AndroidDebugBridge.getBridge().getDevices();
-        
-        // loop through all the Avd and put the one that are not running in the list.
-        avdLoop: for (AvdInfo info : mFullAvdList) {
-            for (Device d : devices) {
-                if (info.getName().equals(d.getAvdName())) {
-                    continue avdLoop;
-                }
-            }
-            list.add(info);
-        }
-        
-        return list.toArray(new AvdInfo[list.size()]);
-    } 
-    
-    /**
-     * Refills the AVD list keeping the current selection.
-     */
-    private void refillAvdList() {
-        AvdInfo[] array = getNonRunningAvds();
-        
-        // save the current selection
-        AvdInfo selected = mPreferredAvdSelector.getFirstSelected();
-        
-        // disable selection change.
-        mDisableAvdSelectionChange = true;
-        
-        // set the new list in the selector
-        mPreferredAvdSelector.setAvds(array, mProjectTarget);
-        
-        // attempt to reselect the proper avd if needed
-        if (selected != null) {
-            if (mPreferredAvdSelector.setSelection(selected) == false) {
-                // looks like the selection is lost. this can happen if an emulator
-                // running the AVD that was selected was launched from outside of Eclipse).
-                mResponse.setAvdToLaunch(null);
-                enableOkButton();
-            }
-        }
-        
-        // enable the selection change
-        mDisableAvdSelectionChange = false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchConfigDelegate.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchConfigDelegate.java
deleted file mode 100644
index bbd320b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchConfigDelegate.java
+++ /dev/null
@@ -1,431 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.launching;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController.AndroidLaunchConfiguration;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.debug.core.ILaunch;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.model.LaunchConfigurationDelegate;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-
-/**
- * Implementation of an eclipse LauncConfigurationDelegate to launch android
- * application in debug.
- */
-public class LaunchConfigDelegate extends LaunchConfigurationDelegate {
-    final static int INVALID_DEBUG_PORT = -1;
-    
-    public final static String ANDROID_LAUNCH_TYPE_ID =
-        "com.android.ide.eclipse.adt.debug.LaunchConfigType"; //$NON-NLS-1$
-
-    /** Target mode parameters: true is automatic, false is manual */
-    public static final String ATTR_TARGET_MODE = AdtPlugin.PLUGIN_ID + ".target"; //$NON-NLS-1$
-    public static final boolean DEFAULT_TARGET_MODE = true; //automatic mode
-
-    /**
-     * Launch action:
-     * <ul>
-     * <li>0: launch default activity</li>
-     * <li>1: launch specified activity. See {@link #ATTR_ACTIVITY}</li>
-     * <li>2: Do Nothing</li>
-     * </ul>
-     */
-    public final static String ATTR_LAUNCH_ACTION = AdtPlugin.PLUGIN_ID + ".action"; //$NON-NLS-1$
-    
-    /** Default launch action. This launches the activity that is setup to be found in the HOME
-     * screen.
-     */
-    public final static int ACTION_DEFAULT = 0;
-    /** Launch action starting a specific activity. */
-    public final static int ACTION_ACTIVITY = 1;
-    /** Launch action that does nothing. */
-    public final static int ACTION_DO_NOTHING = 2;
-    /** Default launch action value. */
-    public final static int DEFAULT_LAUNCH_ACTION = ACTION_DEFAULT;
-
-    /**
-     * Activity to be launched if {@link #ATTR_LAUNCH_ACTION} is 1
-     */
-    public static final String ATTR_ACTIVITY = AdtPlugin.PLUGIN_ID + ".activity"; //$NON-NLS-1$
-
-    public static final String ATTR_AVD_NAME = AdtPlugin.PLUGIN_ID + ".avd"; //$NON-NLS-1$
-    
-    public static final String ATTR_SPEED = AdtPlugin.PLUGIN_ID + ".speed"; //$NON-NLS-1$
-
-    /**
-     * Index of the default network speed setting for the emulator.<br>
-     * Get the emulator option with <code>EmulatorConfigTab.getSpeed(index)</code>
-     */
-    public static final int DEFAULT_SPEED = 0;
-
-    public static final String ATTR_DELAY = AdtPlugin.PLUGIN_ID + ".delay"; //$NON-NLS-1$
-
-    /**
-     * Index of the default network latency setting for the emulator.<br>
-     * Get the emulator option with <code>EmulatorConfigTab.getDelay(index)</code>
-     */
-    public static final int DEFAULT_DELAY = 0;
-
-    public static final String ATTR_COMMANDLINE = AdtPlugin.PLUGIN_ID + ".commandline"; //$NON-NLS-1$
-
-    public static final String ATTR_WIPE_DATA = AdtPlugin.PLUGIN_ID + ".wipedata"; //$NON-NLS-1$
-    public static final boolean DEFAULT_WIPE_DATA = false;
-
-    public static final String ATTR_NO_BOOT_ANIM = AdtPlugin.PLUGIN_ID + ".nobootanim"; //$NON-NLS-1$
-    public static final boolean DEFAULT_NO_BOOT_ANIM = false;
-
-    public static final String ATTR_DEBUG_PORT = 
-        AdtPlugin.PLUGIN_ID + ".debugPort"; //$NON-NLS-1$
-
-    public void launch(ILaunchConfiguration configuration, String mode,
-            ILaunch launch, IProgressMonitor monitor) throws CoreException {
-        // We need to check if it's a standard launch or if it's a launch
-        // to debug an application already running.
-        int debugPort = AndroidLaunchController.getPortForConfig(configuration);
-
-        // get the project
-        IProject project = getProject(configuration);
-
-        // first we make sure the launch is of the proper type
-        AndroidLaunch androidLaunch = null;
-        if (launch instanceof AndroidLaunch) {
-            androidLaunch = (AndroidLaunch)launch;
-        } else {
-            // wrong type, not sure how we got there, but we don't do
-            // anything else
-            AdtPlugin.printErrorToConsole(project, "Wrong Launch Type!");
-            return;
-        }
-
-        // if we have a valid debug port, this means we're debugging an app
-        // that's already launched.
-        if (debugPort != INVALID_DEBUG_PORT) {
-            AndroidLaunchController.launchRemoteDebugger(debugPort, androidLaunch, monitor);
-            return;
-        }
-
-        if (project == null) {
-            AdtPlugin.printErrorToConsole("Couldn't get project object!");
-            androidLaunch.stopLaunch();
-            return;
-        }
-
-        // check if the project has errors, and abort in this case.
-        if (ProjectHelper.hasError(project, true)) {
-            AdtPlugin.displayError("Android Launch",
-                    "Your project contains error(s), please fix them before running your application.");
-            return;
-        }
-
-        AdtPlugin.printToConsole(project, "------------------------------"); //$NON-NLS-1$
-        AdtPlugin.printToConsole(project, "Android Launch!");
-
-        // check if the project is using the proper sdk.
-        // if that throws an exception, we simply let it propage to the caller.
-        if (checkAndroidProject(project) == false) {
-            AdtPlugin.printErrorToConsole(project, "Project is not an Android Project. Aborting!");
-            androidLaunch.stopLaunch();
-            return;
-        }
-
-        // Check adb status and abort if needed.
-        AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-        if (bridge == null || bridge.isConnected() == false) {
-            try {
-                int connections = -1;
-                int restarts = -1;
-                if (bridge != null) {
-                    connections = bridge.getConnectionAttemptCount();
-                    restarts = bridge.getRestartAttemptCount();
-                }
-
-                // if we get -1, the device monitor is not even setup (anymore?).
-                // We need to ask the user to restart eclipse.
-                // This shouldn't happen, but it's better to let the user know in case it does.
-                if (connections == -1 || restarts == -1) {
-                    AdtPlugin.printErrorToConsole(project, 
-                            "The connection to adb is down, and a severe error has occured.",
-                            "You must restart adb and Eclipse.",
-                            String.format(
-                                    "Please ensure that adb is correctly located at '%1$s' and can be executed.",
-                                    AdtPlugin.getOsAbsoluteAdb()));
-                    return;
-                }
-                
-                if (restarts == 0) {
-                    AdtPlugin.printErrorToConsole(project,
-                            "Connection with adb was interrupted.",
-                            String.format("%1$s attempts have been made to reconnect.", connections),
-                            "You may want to manually restart adb from the Devices view.");
-                } else {
-                    AdtPlugin.printErrorToConsole(project,
-                            "Connection with adb was interrupted, and attempts to reconnect have failed.",
-                            String.format("%1$s attempts have been made to restart adb.", restarts),
-                            "You may want to manually restart adb from the Devices view.");
-                    
-                }
-                return;
-            } finally {
-                androidLaunch.stopLaunch();
-            }
-        }
-        
-        // since adb is working, we let the user know
-        // TODO have a verbose mode for launch with more info (or some of the less useful info we now have).
-        AdtPlugin.printToConsole(project, "adb is running normally.");
-
-        // make a config class
-        AndroidLaunchConfiguration config = new AndroidLaunchConfiguration();
-
-        // fill it with the config coming from the ILaunchConfiguration object
-        config.set(configuration);
-
-        // get the launch controller singleton
-        AndroidLaunchController controller = AndroidLaunchController.getInstance();
-
-        // get the application package
-        IFile applicationPackage = getApplicationPackage(project);
-        if (applicationPackage == null) {
-            androidLaunch.stopLaunch();
-            return;
-        }
-
-        // we need some information from the manifest
-        AndroidManifestParser manifestParser = AndroidManifestParser.parse(
-                BaseProjectHelper.getJavaProject(project), null /* errorListener */,
-                true /* gatherData */, false /* markErrors */);
-        
-        if (manifestParser == null) {
-            AdtPlugin.printErrorToConsole(project, "Failed to parse AndroidManifest: aborting!");
-            androidLaunch.stopLaunch();
-            return;
-        }
-
-        String activityName = null;
-        
-        if (config.mLaunchAction == ACTION_ACTIVITY) { 
-            // Get the activity name defined in the config
-            activityName = getActivityName(configuration);
-    
-            // Get the full activity list and make sure the one we got matches.
-            String[] activities = manifestParser.getActivities();
-    
-            // first we check that there are, in fact, activities.
-            if (activities.length == 0) {
-                // if the activities list is null, then the manifest is empty
-                // and we can't launch the app. We'll revert to a sync-only launch
-                AdtPlugin.printErrorToConsole(project,
-                        "The Manifest defines no activity!",
-                        "The launch will only sync the application package on the device!");
-                config.mLaunchAction = ACTION_DO_NOTHING;
-            } else if (activityName == null) {
-                // if the activity we got is null, we look for the default one.
-                AdtPlugin.printErrorToConsole(project,
-                        "No activity specified! Getting the launcher activity.");
-                activityName = manifestParser.getLauncherActivity();
-                
-                // if there's no default activity. We revert to a sync-only launch.
-                if (activityName == null) {
-                    revertToNoActionLaunch(project, config);
-                }
-            } else {
-    
-                // check the one we got from the config matches any from the list
-                boolean match = false;
-                for (String a : activities) {
-                    if (a != null && a.equals(activityName)) {
-                        match = true;
-                        break;
-                    }
-                }
-    
-                // if we didn't find a match, we revert to the default activity if any.
-                if (match == false) {
-                    AdtPlugin.printErrorToConsole(project,
-                            "The specified activity does not exist! Getting the launcher activity.");
-                    activityName = manifestParser.getLauncherActivity();
-            
-                    // if there's no default activity. We revert to a sync-only launch.
-                    if (activityName == null) {
-                        revertToNoActionLaunch(project, config);
-                    }
-                }
-            }
-        } else if (config.mLaunchAction == ACTION_DEFAULT) {
-            activityName = manifestParser.getLauncherActivity();
-            
-            // if there's no default activity. We revert to a sync-only launch.
-            if (activityName == null) {
-                revertToNoActionLaunch(project, config);
-            }
-        }
-
-        // everything seems fine, we ask the launch controller to handle
-        // the rest
-        controller.launch(project, mode, applicationPackage, manifestParser.getPackage(),
-                manifestParser.getDebuggable(), manifestParser.getApiLevelRequirement(),
-                activityName, config, androidLaunch, monitor);
-    }
-    
-    @Override
-    public boolean buildForLaunch(ILaunchConfiguration configuration,
-            String mode, IProgressMonitor monitor) throws CoreException {
-
-        // need to check we have everything
-        IProject project = getProject(configuration);
-
-        if (project != null) {
-            // force an incremental build to be sure the resources will
-            // be updated if they were not saved before the launch was launched.
-            return true;
-        }
-
-        throw new CoreException(new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                        1 /* code, unused */, "Can't find the project!", null /* exception */));
-    }
-
-    /**
-     * {@inheritDoc}
-     * @throws CoreException
-     */
-    @Override
-    public ILaunch getLaunch(ILaunchConfiguration configuration, String mode)
-            throws CoreException {
-        return new AndroidLaunch(configuration, mode, null);
-    }
-
-    /**
-     * Returns the IProject object matching the name found in the configuration
-     * object under the name
-     * <code>IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME</code>
-     * @param configuration
-     * @return The IProject object or null
-     */
-    private IProject getProject(ILaunchConfiguration configuration){
-        // get the project name from the config
-        String projectName;
-        try {
-            projectName = configuration.getAttribute(
-                    IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, "");
-        } catch (CoreException e) {
-            return null;
-        }
-
-        // get the current workspace
-        IWorkspace workspace = ResourcesPlugin.getWorkspace();
-
-        // and return the project with the name from the config
-        return workspace.getRoot().getProject(projectName);
-    }
-
-    /**
-     * Checks the project is an android project.
-     * @param project The project to check
-     * @return true if the project is an android SDK.
-     * @throws CoreException
-     */
-    private boolean checkAndroidProject(IProject project) throws CoreException {
-        // check if the project is a java and an android project.
-        if (project.hasNature(JavaCore.NATURE_ID) == false) {
-            String msg = String.format("%1$s is not a Java project!", project.getName());
-            AdtPlugin.displayError("Android Launch", msg);
-            return false;
-        }
-
-        if (project.hasNature(AndroidConstants.NATURE) == false) {
-            String msg = String.format("%1$s is not an Android project!", project.getName());
-            AdtPlugin.displayError("Android Launch", msg);
-            return false;
-        }
-
-        return true;
-    }
-
-
-    /**
-     * Returns the android package file as an IFile object for the specified
-     * project.
-     * @param project The project
-     * @return The android package as an IFile object or null if not found.
-     */
-    private IFile getApplicationPackage(IProject project) {
-        // get the output folder
-        IFolder outputLocation = BaseProjectHelper.getOutputFolder(project);
-
-        if (outputLocation == null) {
-            AdtPlugin.printErrorToConsole(project,
-                    "Failed to get the output location of the project. Check build path properties"
-                    );
-            return null;
-        }
-        
-
-        // get the package path
-        String packageName = project.getName() + AndroidConstants.DOT_ANDROID_PACKAGE;
-        IResource r = outputLocation.findMember(packageName);
-
-        // check the package is present
-        if (r instanceof IFile && r.exists()) {
-            return (IFile)r;
-        }
-
-        String msg = String.format("Could not find %1$s!", packageName);
-        AdtPlugin.printErrorToConsole(project, msg);
-
-        return null;
-    }
-
-    /**
-     * Returns the name of the activity.
-     */
-    private String getActivityName(ILaunchConfiguration configuration) {
-        String empty = "";
-        String activityName;
-        try {
-            activityName = configuration.getAttribute(ATTR_ACTIVITY, empty);
-        } catch (CoreException e) {
-            return null;
-        }
-
-        return (activityName != empty) ? activityName : null;
-    }
-    
-    private final void revertToNoActionLaunch(IProject project, AndroidLaunchConfiguration config) {
-        AdtPlugin.printErrorToConsole(project,
-                "No Launcher activity found!",
-                "The launch will only sync the application package on the device!");
-        config.mLaunchAction = ACTION_DO_NOTHING;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchShortcut.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchShortcut.java
deleted file mode 100644
index 92677f1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/launching/LaunchShortcut.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.launching;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.ui.DebugUITools;
-import org.eclipse.debug.ui.ILaunchShortcut;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IEditorPart;
-
-/**
- * Launch shortcut to launch debug/run configuration directly.
- */
-public class LaunchShortcut implements ILaunchShortcut {
-
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchShortcut#launch(
-     * org.eclipse.jface.viewers.ISelection, java.lang.String)
-     */
-    public void launch(ISelection selection, String mode) {
-        if (selection instanceof IStructuredSelection) {
-
-            // get the object and the project from it
-            IStructuredSelection structSelect = (IStructuredSelection)selection;
-            Object o = structSelect.getFirstElement();
-
-            // get the first (and normally only) element
-            if (o instanceof IAdaptable) {
-                IResource r = (IResource)((IAdaptable)o).getAdapter(IResource.class);
-
-                // get the project from the resource
-                if (r != null) {
-                    IProject project = r.getProject();
-
-                    if (project != null)  {
-                        // and launch
-                        launch(project, mode);
-                    }
-                }
-            }
-        }
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchShortcut#launch(
-     * org.eclipse.ui.IEditorPart, java.lang.String)
-     */
-    public void launch(IEditorPart editor, String mode) {
-        // since we force the shortcut to only work on selection in the
-        // package explorer, this will never be called.
-    }
-
-
-    /**
-     * Launch a config for the specified project.
-     * @param project The project to launch
-     * @param mode The launch mode ("debug", "run" or "profile")
-     */
-    private void launch(IProject project, String mode) {
-        // get an existing or new launch configuration
-        ILaunchConfiguration config = AndroidLaunchController.getLaunchConfig(project);
-
-        if (config != null) {
-            // and launch!
-            DebugUITools.launch(config, mode);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/EmulatorConfigTab.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/EmulatorConfigTab.java
deleted file mode 100644
index d919c1f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/EmulatorConfigTab.java
+++ /dev/null
@@ -1,459 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.ui;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.debug.launching.LaunchConfigDelegate;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.avd.AvdManager;
-import com.android.sdklib.avd.AvdManager.AvdInfo;
-import com.android.sdkuilib.AvdSelector;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.AbstractLaunchConfigurationTab;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Launch configuration tab to control the parameters of the Emulator
- */
-public class EmulatorConfigTab extends AbstractLaunchConfigurationTab {
-
-    private final static String[][] NETWORK_SPEEDS = new String[][] {
-        { "Full", "full" }, //$NON-NLS-2$
-        { "GSM", "gsm" }, //$NON-NLS-2$
-        { "HSCSD", "hscsd" }, //$NON-NLS-2$
-        { "GPRS", "gprs" }, //$NON-NLS-2$
-        { "EDGE", "edge" }, //$NON-NLS-2$
-        { "UMTS", "umts" }, //$NON-NLS-2$
-        { "HSPDA", "hsdpa" }, //$NON-NLS-2$
-    };
-
-    private final static String[][] NETWORK_LATENCIES = new String[][] {
-        { "None", "none" }, //$NON-NLS-2$
-        { "GPRS", "gprs" }, //$NON-NLS-2$
-        { "EDGE", "edge" }, //$NON-NLS-2$
-        { "UMTS", "umts" }, //$NON-NLS-2$
-    };
-
-    private Button mAutoTargetButton;
-    private Button mManualTargetButton;
-
-    private AvdSelector mPreferredAvdSelector;
-
-    private Combo mSpeedCombo;
-
-    private Combo mDelayCombo;
-
-    private Group mEmulatorOptionsGroup;
-
-    private Text mEmulatorCLOptions;
-
-    private Button mWipeDataButton;
-
-    private Button mNoBootAnimButton;
-
-    private Label mPreferredAvdLabel;
-
-    /**
-     * Returns the emulator ready speed option value.
-     * @param value The index of the combo selection.
-     */
-    public static String getSpeed(int value) {
-        try {
-            return NETWORK_SPEEDS[value][1];
-        } catch (ArrayIndexOutOfBoundsException e) {
-            return NETWORK_SPEEDS[LaunchConfigDelegate.DEFAULT_SPEED][1];
-        }
-    }
-
-    /**
-     * Returns the emulator ready network latency value.
-     * @param value The index of the combo selection.
-     */
-    public static String getDelay(int value) {
-        try {
-            return NETWORK_LATENCIES[value][1];
-        } catch (ArrayIndexOutOfBoundsException e) {
-            return NETWORK_LATENCIES[LaunchConfigDelegate.DEFAULT_DELAY][1];
-        }
-    }
-
-    /**
-     *
-     */
-    public EmulatorConfigTab() {
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchConfigurationTab#createControl(org.eclipse.swt.widgets.Composite)
-     */
-    public void createControl(Composite parent) {
-        Font font = parent.getFont();
-
-        Composite topComp = new Composite(parent, SWT.NONE);
-        setControl(topComp);
-        GridLayout topLayout = new GridLayout();
-        topLayout.numColumns = 1;
-        topLayout.verticalSpacing = 0;
-        topComp.setLayout(topLayout);
-        topComp.setFont(font);
-
-        GridData gd;
-        GridLayout layout;
-        
-        // radio button for the target mode
-        Group targetModeGroup = new Group(topComp, SWT.NONE);
-        targetModeGroup.setText("Device Target Selection Mode");
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        targetModeGroup.setLayoutData(gd);
-        layout = new GridLayout();
-        layout.numColumns = 1;
-        targetModeGroup.setLayout(layout);
-        targetModeGroup.setFont(font);
-
-        mManualTargetButton = new Button(targetModeGroup, SWT.RADIO);
-        mManualTargetButton.setText("Manual");
-        // Since there are only 2 radio buttons, we can put a listener on only one (they
-        // are both called on select and unselect event.
-
-        // add the radio button
-        mAutoTargetButton = new Button(targetModeGroup, SWT.RADIO);
-        mAutoTargetButton.setText("Automatic");
-        mAutoTargetButton.setSelection(true);
-        mAutoTargetButton.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-                
-                boolean auto = mAutoTargetButton.getSelection();
-                mPreferredAvdSelector.setEnabled(auto);
-                mPreferredAvdLabel.setEnabled(auto);
-            }
-        });
-
-        Composite offsetComp = new Composite(targetModeGroup, SWT.NONE);
-        offsetComp.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        layout = new GridLayout(1, false);
-        layout.marginRight = layout.marginHeight = 0;
-        layout.marginLeft = 30;
-        offsetComp.setLayout(layout);
-
-        mPreferredAvdLabel = new Label(offsetComp, SWT.NONE);
-        mPreferredAvdLabel.setText("Select a preferred Android Virtual Device:");
-        AvdInfo[] avds = new AvdInfo[0];
-        mPreferredAvdSelector = new AvdSelector(offsetComp, avds,
-                false /*allowMultipleSelection*/);
-        mPreferredAvdSelector.setTableHeightHint(100);
-        mPreferredAvdSelector.setSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-
-        // emulator size
-        mEmulatorOptionsGroup = new Group(topComp, SWT.NONE);
-        mEmulatorOptionsGroup.setText("Emulator launch parameters:");
-        mEmulatorOptionsGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        layout = new GridLayout();
-        layout.numColumns = 2;
-        mEmulatorOptionsGroup.setLayout(layout);
-        mEmulatorOptionsGroup.setFont(font);
-
-        // network options
-        new Label(mEmulatorOptionsGroup, SWT.NONE).setText("Network Speed:");
-
-        mSpeedCombo = new Combo(mEmulatorOptionsGroup, SWT.READ_ONLY);
-        for (String[] speed : NETWORK_SPEEDS) {
-            mSpeedCombo.add(speed[0]);
-        }
-        mSpeedCombo.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-        mSpeedCombo.pack();
-
-        new Label(mEmulatorOptionsGroup, SWT.NONE).setText("Network Latency:");
-
-        mDelayCombo = new Combo(mEmulatorOptionsGroup, SWT.READ_ONLY);
-
-        for (String[] delay : NETWORK_LATENCIES) {
-            mDelayCombo.add(delay[0]);
-        }
-        mDelayCombo.addSelectionListener(new SelectionAdapter() {
-            // called when selection changes
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-        mDelayCombo.pack();
-
-        // wipe data option
-        mWipeDataButton = new Button(mEmulatorOptionsGroup, SWT.CHECK);
-        mWipeDataButton.setText("Wipe User Data");
-        mWipeDataButton.setToolTipText("Check this if you want to wipe your user data each time you start the emulator. You will be prompted for confirmation when the emulator starts.");
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        mWipeDataButton.setLayoutData(gd);
-        mWipeDataButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-
-        // no boot anim option
-        mNoBootAnimButton = new Button(mEmulatorOptionsGroup, SWT.CHECK);
-        mNoBootAnimButton.setText("Disable Boot Animation");
-        mNoBootAnimButton.setToolTipText("Check this if you want to disable the boot animation. This can help the emulator start faster on slow machines.");
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        mNoBootAnimButton.setLayoutData(gd);
-        mNoBootAnimButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-        
-        // custom command line option for emulator
-        Label l = new Label(mEmulatorOptionsGroup, SWT.NONE);
-        l.setText("Additional Emulator Command Line Options");
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        l.setLayoutData(gd);
-
-        mEmulatorCLOptions = new Text(mEmulatorOptionsGroup, SWT.BORDER);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        mEmulatorCLOptions.setLayoutData(gd);
-        mEmulatorCLOptions.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                updateLaunchConfigurationDialog();
-            }
-        });
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
-     */
-    public String getName() {
-        return "Target";
-    }
-
-    @Override
-    public Image getImage() {
-        return DdmsPlugin.getImageLoader().loadImage("emulator.png", null); //$NON-NLS-1$
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchConfigurationTab#initializeFrom(org.eclipse.debug.core.ILaunchConfiguration)
-     */
-    public void initializeFrom(ILaunchConfiguration configuration) {
-        AvdManager avdManager = Sdk.getCurrent().getAvdManager();
-
-        boolean value = LaunchConfigDelegate.DEFAULT_TARGET_MODE; // true == automatic
-        try {
-            value = configuration.getAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE, value);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-        mAutoTargetButton.setSelection(value);
-        mManualTargetButton.setSelection(!value);
-        
-        // look for the project name to get its target.
-        String stringValue = "";
-        try {
-            stringValue = configuration.getAttribute(
-                    IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, stringValue);
-        } catch (CoreException ce) {
-            // let's not do anything here, we'll use the default value
-        }
-
-        IProject project = null;
-
-        // get the list of existing Android projects from the workspace.
-        IJavaProject[] projects = BaseProjectHelper.getAndroidProjects();
-        if (projects != null) {
-            // look for the project whose name we read from the configuration.
-            for (IJavaProject p : projects) {
-                if (p.getElementName().equals(stringValue)) {
-                    project = p.getProject();
-                    break;
-                }
-            }
-        }
-
-        // update the AVD list
-        AvdInfo[] avds = null;
-        if (avdManager != null) {
-            avds = avdManager.getAvds();
-        }
-
-        IAndroidTarget projectTarget = null;
-        if (project != null) {
-            projectTarget = Sdk.getCurrent().getTarget(project);
-        } else {
-            avds = null; // no project? we don't want to display any "compatible" AVDs.
-        }
-        
-        mPreferredAvdSelector.setAvds(avds, projectTarget);
-
-        stringValue = "";
-        try {
-            stringValue = configuration.getAttribute(LaunchConfigDelegate.ATTR_AVD_NAME,
-                    stringValue);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-
-        if (stringValue != null && stringValue.length() > 0 && avdManager != null) {
-            AvdInfo targetAvd = avdManager.getAvd(stringValue);
-            mPreferredAvdSelector.setSelection(targetAvd);
-        } else {
-            mPreferredAvdSelector.setSelection(null);
-        }
-
-        value = LaunchConfigDelegate.DEFAULT_WIPE_DATA;
-        try {
-            value = configuration.getAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA, value);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-        mWipeDataButton.setSelection(value);
-
-        value = LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM;
-        try {
-            value = configuration.getAttribute(LaunchConfigDelegate.ATTR_NO_BOOT_ANIM, value);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-        mNoBootAnimButton.setSelection(value);
-
-        int index = -1;
-
-        index = LaunchConfigDelegate.DEFAULT_SPEED;
-        try {
-            index = configuration.getAttribute(LaunchConfigDelegate.ATTR_SPEED,
-                    index);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-        if (index == -1) {
-            mSpeedCombo.clearSelection();
-        } else {
-            mSpeedCombo.select(index);
-        }
-
-        index = LaunchConfigDelegate.DEFAULT_DELAY;
-        try {
-            index = configuration.getAttribute(LaunchConfigDelegate.ATTR_DELAY,
-                    index);
-        } catch (CoreException e) {
-            // let's not do anything here, we'll put a proper value in
-            // performApply anyway
-        }
-        if (index == -1) {
-            mDelayCombo.clearSelection();
-        } else {
-            mDelayCombo.select(index);
-        }
-
-        String commandLine = null;
-        try {
-            commandLine = configuration.getAttribute(
-                    LaunchConfigDelegate.ATTR_COMMANDLINE, ""); //$NON-NLS-1$
-        } catch (CoreException e) {
-            // let's not do anything here, we'll use the default value
-        }
-        if (commandLine != null) {
-            mEmulatorCLOptions.setText(commandLine);
-        }
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchConfigurationTab#performApply(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy)
-     */
-    public void performApply(ILaunchConfigurationWorkingCopy configuration) {
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
-                mAutoTargetButton.getSelection());
-        AvdInfo avd = mPreferredAvdSelector.getFirstSelected();
-        if (avd != null) {
-            configuration.setAttribute(LaunchConfigDelegate.ATTR_AVD_NAME, avd.getName());
-        } else {
-            configuration.setAttribute(LaunchConfigDelegate.ATTR_AVD_NAME, (String)null);
-        }
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
-                mSpeedCombo.getSelectionIndex());
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
-                mDelayCombo.getSelectionIndex());
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_COMMANDLINE,
-                mEmulatorCLOptions.getText());
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA,
-                mWipeDataButton.getSelection());
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_NO_BOOT_ANIM,
-                mNoBootAnimButton.getSelection());
-   }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.debug.ui.ILaunchConfigurationTab#setDefaults(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy)
-     */
-    public void setDefaults(ILaunchConfigurationWorkingCopy configuration) {
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_TARGET_MODE,
-                LaunchConfigDelegate.DEFAULT_TARGET_MODE);
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_SPEED,
-                LaunchConfigDelegate.DEFAULT_SPEED);
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_DELAY,
-                LaunchConfigDelegate.DEFAULT_DELAY);
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_WIPE_DATA,
-                LaunchConfigDelegate.DEFAULT_WIPE_DATA);
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_NO_BOOT_ANIM,
-                LaunchConfigDelegate.DEFAULT_NO_BOOT_ANIM);
-        
-        IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-        String emuOptions = store.getString(AdtPlugin.PREFS_EMU_OPTIONS);
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_COMMANDLINE, emuOptions);
-   }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/LaunchConfigTabGroup.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/LaunchConfigTabGroup.java
deleted file mode 100644
index c0dbd54..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/LaunchConfigTabGroup.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.ui;
-
-import org.eclipse.debug.ui.AbstractLaunchConfigurationTabGroup;
-import org.eclipse.debug.ui.CommonTab;
-import org.eclipse.debug.ui.ILaunchConfigurationDialog;
-import org.eclipse.debug.ui.ILaunchConfigurationTab;
-
-/**
- * Tab group object for Android Launch Config type.
- */
-public class LaunchConfigTabGroup extends AbstractLaunchConfigurationTabGroup {
-
-    public LaunchConfigTabGroup() {
-    }
-
-    public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
-        ILaunchConfigurationTab[] tabs = new ILaunchConfigurationTab[] {
-                new MainLaunchConfigTab(),
-                new EmulatorConfigTab(),
-                new CommonTab()
-            };
-            setTabs(tabs);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/MainLaunchConfigTab.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/MainLaunchConfigTab.java
deleted file mode 100644
index 6a40ed0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/debug/ui/MainLaunchConfigTab.java
+++ /dev/null
@@ -1,489 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.debug.ui;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.debug.launching.AndroidLaunchController;
-import com.android.ide.eclipse.adt.debug.launching.LaunchConfigDelegate;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.common.project.ProjectChooserHelper;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.AbstractLaunchConfigurationTab;
-import org.eclipse.debug.ui.ILaunchConfigurationTab;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Class for the main launch configuration tab.
- */
-public class MainLaunchConfigTab extends AbstractLaunchConfigurationTab {
-
-    protected static final String EMPTY_STRING = ""; //$NON-NLS-1$
-    
-    protected Text mProjText;
-    private Button mProjButton;
-
-    private Combo mActivityCombo;
-    private String[] mActivities;
-
-    private WidgetListener mListener = new WidgetListener();
-
-    private Button mDefaultActionButton;
-    private Button mActivityActionButton;
-    private Button mDoNothingActionButton;
-    private int mLaunchAction = LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION;
-    
-    private ProjectChooserHelper mProjectChooserHelper;
-    
-    /**
-     * A listener which handles widget change events for the controls in this
-     * tab.
-     */
-    private class WidgetListener implements ModifyListener, SelectionListener {
-
-        public void modifyText(ModifyEvent e) {
-            IProject project = checkParameters();
-            loadActivities(project);
-            setDirty(true);
-        }
-
-        public void widgetDefaultSelected(SelectionEvent e) {/* do nothing */
-        }
-
-        public void widgetSelected(SelectionEvent e) {
-            Object source = e.getSource();
-            if (source == mProjButton) {
-                handleProjectButtonSelected();
-            } else {
-                checkParameters();
-            }
-        }
-    }
-
-    public MainLaunchConfigTab() {
-    }
-
-    public void createControl(Composite parent) {
-        mProjectChooserHelper = new ProjectChooserHelper(parent.getShell());
-
-        Font font = parent.getFont();
-        Composite comp = new Composite(parent, SWT.NONE);
-        setControl(comp);
-        GridLayout topLayout = new GridLayout();
-        topLayout.verticalSpacing = 0;
-        comp.setLayout(topLayout);
-        comp.setFont(font);
-        createProjectEditor(comp);
-        createVerticalSpacer(comp, 1);
-
-        // create the combo for the activity chooser
-        Group group = new Group(comp, SWT.NONE);
-        group.setText("Launch Action:");
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        group.setLayoutData(gd);
-        GridLayout layout = new GridLayout();
-        layout.numColumns = 2;
-        group.setLayout(layout);
-        group.setFont(font);
-
-        mDefaultActionButton = new Button(group, SWT.RADIO);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        mDefaultActionButton.setLayoutData(gd);
-        mDefaultActionButton.setText("Launch Default Activity");
-        mDefaultActionButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // event are received for both selection and deselection, so we only process
-                // the selection event to avoid doing it twice.
-                if (mDefaultActionButton.getSelection() == true) {
-                    mLaunchAction = LaunchConfigDelegate.ACTION_DEFAULT;
-                    mActivityCombo.setEnabled(false);
-                    checkParameters();
-                }
-            }
-        });
-
-        mActivityActionButton = new Button(group, SWT.RADIO);
-        mActivityActionButton.setText("Launch:");
-        mActivityActionButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // event are received for both selection and deselection, so we only process
-                // the selection event to avoid doing it twice.
-                if (mActivityActionButton.getSelection() == true) {
-                    mLaunchAction = LaunchConfigDelegate.ACTION_ACTIVITY;
-                    mActivityCombo.setEnabled(true);
-                    checkParameters();
-                }
-            }
-        });
-
-        mActivityCombo = new Combo(group, SWT.DROP_DOWN | SWT.READ_ONLY);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        mActivityCombo.setLayoutData(gd);
-        mActivityCombo.clearSelection();
-        mActivityCombo.setEnabled(false);
-        mActivityCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                checkParameters();
-            }
-        });
-        
-        mDoNothingActionButton = new Button(group, SWT.RADIO);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalSpan = 2;
-        mDoNothingActionButton.setLayoutData(gd);
-        mDoNothingActionButton.setText("Do Nothing");
-        mDoNothingActionButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // event are received for both selection and deselection, so we only process
-                // the selection event to avoid doing it twice.
-                if (mDoNothingActionButton.getSelection() == true) {
-                    mLaunchAction = LaunchConfigDelegate.ACTION_DO_NOTHING;
-                    mActivityCombo.setEnabled(false);
-                    checkParameters();
-                }
-            }
-        });
-        
-    }
-
-    public String getName() {
-        return "Android";
-    }
-
-    @Override
-    public Image getImage() {
-        return AdtPlugin.getImageLoader().loadImage("mainLaunchTab.png", null);
-    }
-
-
-    public void performApply(ILaunchConfigurationWorkingCopy configuration) {
-        configuration.setAttribute(
-                IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, mProjText.getText());
-        configuration.setAttribute(
-                IJavaLaunchConfigurationConstants.ATTR_ALLOW_TERMINATE, true);
-
-        // add the launch mode
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION, mLaunchAction);
-        
-        // add the activity
-        int selection = mActivityCombo.getSelectionIndex();
-        if (mActivities != null && selection >=0 && selection < mActivities.length) {
-            configuration.setAttribute(LaunchConfigDelegate.ATTR_ACTIVITY, mActivities[selection]);
-        }
-        
-        // link the project and the launch config.
-        mapResources(configuration);
-    }
-
-    public void setDefaults(ILaunchConfigurationWorkingCopy configuration) {
-        configuration.setAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION,
-                LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION);
-    }
-
-    /**
-     * Creates the widgets for specifying a main type.
-     *
-     * @param parent the parent composite
-     */
-    protected void createProjectEditor(Composite parent) {
-        Font font = parent.getFont();
-        Group group = new Group(parent, SWT.NONE);
-        group.setText("Project:");
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        group.setLayoutData(gd);
-        GridLayout layout = new GridLayout();
-        layout.numColumns = 2;
-        group.setLayout(layout);
-        group.setFont(font);
-        mProjText = new Text(group, SWT.SINGLE | SWT.BORDER);
-        gd = new GridData(GridData.FILL_HORIZONTAL);
-        mProjText.setLayoutData(gd);
-        mProjText.setFont(font);
-        mProjText.addModifyListener(mListener);
-        mProjButton = createPushButton(group, "Browse...", null);
-        mProjButton.addSelectionListener(mListener);
-    }
-
-    /**
-     * returns the default listener from this class. For all subclasses this
-     * listener will only provide the functi Jaonality of updating the current
-     * tab
-     *
-     * @return a widget listener
-     */
-    protected WidgetListener getDefaultListener() {
-        return mListener;
-    }
-
-    /**
-     * Return the {@link IJavaProject} corresponding to the project name in the project
-     * name text field, or null if the text does not match a project name.
-     * @param javaModel the Java Model object corresponding for the current workspace root.
-     * @return a IJavaProject object or null.
-     */
-    protected IJavaProject getJavaProject(IJavaModel javaModel) {
-        String projectName = mProjText.getText().trim();
-        if (projectName.length() < 1) {
-            return null;
-        }
-        return javaModel.getJavaProject(projectName);
-    }
-
-    /**
-     * Show a dialog that lets the user select a project. This in turn provides
-     * context for the main type, allowing the user to key a main type name, or
-     * constraining the search for main types to the specified project.
-     */
-    protected void handleProjectButtonSelected() {
-        IJavaProject javaProject = mProjectChooserHelper.chooseJavaProject(
-                mProjText.getText().trim());
-        if (javaProject == null) {
-            return;
-        }// end if
-        String projectName = javaProject.getElementName();
-        mProjText.setText(projectName);
-        
-        // get the list of activities and fill the combo
-        IProject project = javaProject.getProject();
-        loadActivities(project);
-    }// end handle selected
-
-    /**
-     * Initializes this tab's controls with values from the given
-     * launch configuration. This method is called when
-     * a configuration is selected to view or edit, after this
-     * tab's control has been created.
-     * 
-     * @param config launch configuration
-     * 
-     * @see ILaunchConfigurationTab
-     */
-    public void initializeFrom(ILaunchConfiguration config) {
-        String projectName = EMPTY_STRING;
-        try {
-            projectName = config.getAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME,
-                    EMPTY_STRING);
-        }// end try
-        catch (CoreException ce) {
-        }
-        mProjText.setText(projectName);
-
-        // get the list of projects
-        IJavaProject[] projects = mProjectChooserHelper.getAndroidProjects(null);
-
-        if (projects != null) {
-            // look for the currently selected project
-            IProject proj = null;
-            for (IJavaProject p : projects) {
-                if (p.getElementName().equals(projectName)) {
-                    proj = p.getProject();
-                    break;
-                }
-            }
-
-            loadActivities(proj);
-        }
-        
-        // load the launch action.
-        mLaunchAction = LaunchConfigDelegate.DEFAULT_LAUNCH_ACTION;
-        try {
-            mLaunchAction = config.getAttribute(LaunchConfigDelegate.ATTR_LAUNCH_ACTION,
-                    mLaunchAction);
-        } catch (CoreException e) {
-            // nothing to be done really. launchAction will keep its default value.
-        }
-        
-        mDefaultActionButton.setSelection(mLaunchAction == LaunchConfigDelegate.ACTION_DEFAULT);
-        mActivityActionButton.setSelection(mLaunchAction == LaunchConfigDelegate.ACTION_ACTIVITY);
-        mDoNothingActionButton.setSelection(
-                mLaunchAction == LaunchConfigDelegate.ACTION_DO_NOTHING);
-
-        // now look for the activity and load it if present, otherwise, revert
-        // to the current one.
-        String activityName = EMPTY_STRING;
-        try {
-            activityName = config.getAttribute(LaunchConfigDelegate.ATTR_ACTIVITY, EMPTY_STRING);
-        }// end try
-        catch (CoreException ce) {
-            // nothing to be done really. activityName will stay empty
-        }
-
-        if (mLaunchAction != LaunchConfigDelegate.ACTION_ACTIVITY) {
-            mActivityCombo.setEnabled(false);
-            mActivityCombo.clearSelection();
-        } else {
-            mActivityCombo.setEnabled(true);
-            if (activityName == null || activityName.equals(EMPTY_STRING)) {
-                mActivityCombo.clearSelection();
-            } else if (mActivities != null && mActivities.length > 0) {
-                // look for the name of the activity in the combo.
-                boolean found = false;
-                for (int i = 0 ; i < mActivities.length ; i++) {
-                    if (activityName.equals(mActivities[i])) {
-                        found = true;
-                        mActivityCombo.select(i);
-                        break;
-                    }
-                }
-    
-                // if we haven't found a matching activity we clear the combo selection
-                if (found == false) {
-                    mActivityCombo.clearSelection();
-                }
-            }
-        }
-    }
-
-    /**
-     * Associates the launch config and the project. This allows Eclipse to delete the launch
-     * config when the project is deleted.
-     *
-     * @param config the launch config working copy.
-     */
-    protected void mapResources(ILaunchConfigurationWorkingCopy config) {
-        // get the java model
-        IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
-        IJavaModel javaModel = JavaCore.create(workspaceRoot);
-
-        // get the IJavaProject described by the text field.
-        IJavaProject javaProject = getJavaProject(javaModel);
-        IResource[] resources = null;
-        if (javaProject != null) {
-            resources = AndroidLaunchController.getResourcesToMap(javaProject.getProject());
-        }
-        config.setMappedResources(resources);
-    }
-
-    /**
-     * Loads the ui with the activities of the specified project, and stores the
-     * activities in <code>mActivities</code>.
-     * <p/>
-     * First activity is selected by default if present.
-     * 
-     * @param project The project to load the activities from.
-     */
-    private void loadActivities(IProject project) {
-        if (project != null) {
-            try {
-                // parse the manifest for the list of activities.
-                AndroidManifestParser manifestParser = AndroidManifestParser.parse(
-                        BaseProjectHelper.getJavaProject(project), null /* errorListener */,
-                        true /* gatherData */, false /* markErrors */);
-                if (manifestParser != null) {
-                    mActivities = manifestParser.getActivities();
-    
-                    mActivityCombo.removeAll();
-    
-                    if (mActivities.length > 0) {
-                        if (mLaunchAction == LaunchConfigDelegate.ACTION_ACTIVITY) {
-                            mActivityCombo.setEnabled(true);
-                        }
-                        for (String s : mActivities) {
-                            mActivityCombo.add(s);
-                        }
-                    } else {
-                        mActivityCombo.setEnabled(false);
-                    }
-    
-                    // the selection will be set when we update the ui from the current
-                    // config object.
-                    mActivityCombo.clearSelection();
-    
-                    return;
-                }
-
-            } catch (CoreException e) {
-                // The AndroidManifest parsing failed. The builders must have reported the errors
-                // already so there's nothing to do.
-            }
-        }
-        
-        // if we reach this point, either project is null, or we got an exception during
-        // the parsing. In either case, we empty the activity list.
-        mActivityCombo.removeAll();
-        mActivities = null;
-    }
-    
-    /**
-     * Checks the parameters for correctness, and update the error message and buttons.
-     * @return the current IProject of this launch config.
-     */
-    private IProject checkParameters() {
-        try {
-            //test the project name first!
-            String text = mProjText.getText();
-            if (text.length() == 0) {
-                setErrorMessage("Project Name is required!");
-            } else if (text.matches("[a-zA-Z0-9_ \\.-]+") == false) {
-                setErrorMessage("Project name contains unsupported characters!");
-            } else {
-                IJavaProject[] projects = mProjectChooserHelper.getAndroidProjects(null);
-                IProject found = null;
-                for (IJavaProject javaProject : projects) {
-                    if (javaProject.getProject().getName().equals(text)) {
-                        found = javaProject.getProject();
-                        break;
-                    }
-                    
-                }
-                
-                if (found != null) {
-                    setErrorMessage(null);
-                } else {
-                    setErrorMessage(String.format("There is no android project named '%1$s'",
-                            text));
-                }
-                
-                return found;
-            }
-        } finally {
-            updateLaunchConfigurationDialog();
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/messages.properties b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/messages.properties
deleted file mode 100644
index dfb0eb2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/messages.properties
+++ /dev/null
@@ -1,16 +0,0 @@
-Dialog_Title_SDK_Location=Android SDK Location
-SDK_Not_Setup=The location of the Android SDK has not been setup. Please go to Preferences > Android and set it up
-Error_Check_Prefs=%1$s\nPlease check the Android plugin's preferences.
-Could_Not_Find_Folder=Could not find SDK folder '%1$s'.
-Could_Not_Find_Folder_In_SDK=Could not find folder '%1$s' inside SDK '%2$s'.
-Could_Not_Find=Could not find %1$s\!
-VersionCheck_SDK_Milestone_Too_Low=This version of ADT requires a SDK in version M%1$d or above.\n\nCurrent version is %2$s.\n\nPlease update your SDK to the latest version.
-VersionCheck_SDK_Build_Too_Low=This version of ADT requires a SDK in version %1$d (M%2$d) or above.\n\nCurrent version is %3$s.\n\nPlease update your SDK to the latest version.
-VersionCheck_Plugin_Version_Failed=Failed to get the required ADT version number from the SDK.\n\nThe Android Developer Toolkit may not work properly.
-VersionCheck_Unable_To_Parse_Version_s=Unable to parse sdk build version: %1$s
-VersionCheck_Plugin_Too_Old=This Android SDK requires Android Developer Toolkit version %1$d.%2$d.%3$d or above.\n\nCurrent version is %4$s.\n\nPlease update ADT to the latest version.
-AdtPlugin_Failed_To_Start_s=Failed to start %1$s
-AdtPlugin_Android_SDK_Content_Loader=Android SDK Content Loader
-AdtPlugin_Parsing_Resources=Parsing Resources
-AdtPlugin_Android_SDK_Resource_Parser=Android SDK Resource Parser
-AdtPlugin_Failed_To_Parse_s=Failed to parse: 
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/AndroidPreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/AndroidPreferencePage.java
deleted file mode 100644
index c27c106..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/AndroidPreferencePage.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.preferences;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-
-import org.eclipse.jface.preference.DirectoryFieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-import java.io.File;
-
-/**
- * This class represents a preference page that is contributed to the
- * Preferences dialog. By subclassing <samp>FieldEditorPreferencePage</samp>,
- * we can use the field support built into JFace that allows us to create a page
- * that is small and knows how to save, restore and apply itself.
- * <p>
- * This page is used to modify preferences only. They are stored in the
- * preference store that belongs to the main plug-in class. That way,
- * preferences can be accessed directly via the preference store.
- */
-
-public class AndroidPreferencePage extends FieldEditorPreferencePage implements
-        IWorkbenchPreferencePage {
-
-    public AndroidPreferencePage() {
-        super(GRID);
-        setPreferenceStore(AdtPlugin.getDefault().getPreferenceStore());
-        setDescription(Messages.AndroidPreferencePage_Title);
-    }
-
-    /**
-     * Creates the field editors. Field editors are abstractions of the common
-     * GUI blocks needed to manipulate various types of preferences. Each field
-     * editor knows how to save and restore itself.
-     */
-    @Override
-    public void createFieldEditors() {
-
-        addField(new SdkDirectoryFieldEditor(AdtPlugin.PREFS_SDK_DIR,
-                Messages.AndroidPreferencePage_SDK_Location_, getFieldEditorParent()));
-    }
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
-     */
-    public void init(IWorkbench workbench) {
-    }
-
-    /**
-     * Custom version of DirectoryFieldEditor which validates that the directory really
-     * contains an SDK.
-     *
-     * There's a known issue here, which is really a rare edge-case: if the pref dialog is open
-     * which a given sdk directory and the *content* of the directory changes such that the sdk
-     * state changed (i.e. from valid to invalid or vice versa), the pref panel will display or
-     * hide the error as appropriate but the pref panel will fail to validate the apply/ok buttons
-     * appropriately. The easy workaround is to cancel the pref panel and enter it again.
-     */
-    private static class SdkDirectoryFieldEditor extends DirectoryFieldEditor {
-
-        public SdkDirectoryFieldEditor(String name, String labelText, Composite parent) {
-            super(name, labelText, parent);
-            setEmptyStringAllowed(false);
-        }
-
-        /**
-         * Method declared on StringFieldEditor and overridden in DirectoryFieldEditor.
-         * Checks whether the text input field contains a valid directory.
-         *
-         * @return True if the apply/ok button should be enabled in the pref panel
-         */
-        @Override
-        protected boolean doCheckState() {
-            String fileName = getTextControl().getText();
-            fileName = fileName.trim();
-            
-            if (fileName.indexOf(',') >= 0 || fileName.indexOf(';') >= 0) {
-                setErrorMessage(Messages.AndroidPreferencePage_ERROR_Reserved_Char);
-                return false;  // Apply/OK must be disabled
-            }
-            
-            File file = new File(fileName);
-            if (!file.isDirectory()) {
-                setErrorMessage(JFaceResources.getString(
-                    "DirectoryFieldEditor.errorMessage")); //$NON-NLS-1$
-                return false;
-            }
-
-            boolean ok = AdtPlugin.getDefault().checkSdkLocationAndId(fileName,
-                    new AdtPlugin.CheckSdkErrorHandler() {
-                @Override
-                public boolean handleError(String message) {
-                    setErrorMessage(message.replaceAll("\n", " ")); //$NON-NLS-1$ //$NON-NLS-2$
-                    return false;  // Apply/OK must be disabled
-                }
-
-                @Override
-                public boolean handleWarning(String message) {
-                    showMessage(message.replaceAll("\n", " ")); //$NON-NLS-1$ //$NON-NLS-2$
-                    return true;  // Apply/OK must be enabled
-                }
-            });
-            if (ok) clearMessage();
-            return ok;
-        }
-
-        @Override
-        public Text getTextControl(Composite parent) {
-            setValidateStrategy(VALIDATE_ON_KEY_STROKE);
-            return super.getTextControl(parent);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/BuildPreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/BuildPreferencePage.java
deleted file mode 100644
index e64c2f4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/BuildPreferencePage.java
+++ /dev/null
@@ -1,217 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.preferences;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.jarutils.DebugKeyProvider;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.FileFieldEditor;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
-import org.eclipse.jface.preference.StringFieldEditor;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-import java.io.File;
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-import java.security.PrivateKey;
-import java.security.cert.X509Certificate;
-import java.util.Date;
-
-/**
- * Preference page for build options.
- *
- */
-public class BuildPreferencePage extends FieldEditorPreferencePage implements
-        IWorkbenchPreferencePage {
-
-    final static String BUILD_STR_SILENT = "silent"; //$NON-NLS-1$
-    final static String BUILD_STR_NORMAL = "normal"; //$NON-NLS-1$
-    final static String BUILD_STR_VERBOSE = "verbose"; //$NON-NLS-1$
-
-    public BuildPreferencePage() {
-        super(GRID);
-        setPreferenceStore(AdtPlugin.getDefault().getPreferenceStore());
-        setDescription(Messages.BuildPreferencePage_Title);
-    }
-
-    public static int getBuildLevel(String buildPrefValue) {
-        if (BUILD_STR_SILENT.equals(buildPrefValue)) {
-            return AdtConstants.BUILD_ALWAYS;
-        } else if (BUILD_STR_VERBOSE.equals(buildPrefValue)) {
-            return AdtConstants.BUILD_VERBOSE;
-        }
-
-        return AdtConstants.BUILD_NORMAL;
-    }
-
-    @Override
-    protected void createFieldEditors() {
-        addField(new BooleanFieldEditor(AdtPlugin.PREFS_RES_AUTO_REFRESH,
-                Messages.BuildPreferencePage_Auto_Refresh_Resources_on_Build,
-                getFieldEditorParent()));
-
-        RadioGroupFieldEditor rgfe = new RadioGroupFieldEditor(
-                AdtPlugin.PREFS_BUILD_VERBOSITY,
-                Messages.BuildPreferencePage_Build_Output, 1, new String[][] {
-                    { Messages.BuildPreferencePage_Silent, BUILD_STR_SILENT },
-                    { Messages.BuildPreferencePage_Normal, BUILD_STR_NORMAL },
-                    { Messages.BuildPreferencePage_Verbose, BUILD_STR_VERBOSE }
-                    },
-                getFieldEditorParent(), true);
-        addField(rgfe);
-
-        addField(new ReadOnlyFieldEditor(AdtPlugin.PREFS_DEFAULT_DEBUG_KEYSTORE,
-                Messages.BuildPreferencePage_Default_KeyStore, getFieldEditorParent()));
-
-        addField(new KeystoreFieldEditor(AdtPlugin.PREFS_CUSTOM_DEBUG_KEYSTORE,
-                Messages.BuildPreferencePage_Custom_Keystore, getFieldEditorParent()));
-
-    }
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
-     */
-    public void init(IWorkbench workbench) {
-    }
-
-    /**
-     * A read-only string field editor.
-     */
-    private static class ReadOnlyFieldEditor extends StringFieldEditor {
-
-        public ReadOnlyFieldEditor(String name, String labelText, Composite parent) {
-            super(name, labelText, parent);
-        }
-
-        @Override
-        protected void createControl(Composite parent) {
-            super.createControl(parent);
-            
-            Text control = getTextControl();
-            control.setEditable(false);
-        }
-    }
-    
-    /**
-     * Custom {@link FileFieldEditor} that checks that the keystore is valid.
-     */
-    private static class KeystoreFieldEditor extends FileFieldEditor {
-        public KeystoreFieldEditor(String name, String label, Composite parent) {
-            super(name, label, parent);
-            setValidateStrategy(VALIDATE_ON_KEY_STROKE);
-        }
-        
-        @Override
-        protected boolean checkState() {
-            String fileName = getTextControl().getText();
-            fileName = fileName.trim();
-            
-            // empty values are considered ok.
-            if (fileName.length() > 0) {
-                File file = new File(fileName);
-                if (file.isFile()) {
-                    // attempt to load the debug key.
-                    try {
-                        DebugKeyProvider provider = new DebugKeyProvider(fileName,
-                                null /* storeType */, null /* key gen output */);
-                        PrivateKey key = provider.getDebugKey();
-                        X509Certificate certificate = (X509Certificate)provider.getCertificate();
-                        
-                        if (key == null || certificate == null) {
-                            showErrorMessage("Unable to find debug key in keystore!");
-                            return false;
-                        }
-                        
-                        Date today = new Date();
-                        if (certificate.getNotAfter().compareTo(today) < 0) {
-                            showErrorMessage("Certificate is expired!");
-                            return false;
-                        }
-                        
-                        if (certificate.getNotBefore().compareTo(today) > 0) {
-                            showErrorMessage("Certificate validity is in the future!");
-                            return false;
-                        }
-
-                        // we're good!
-                        clearErrorMessage();
-                        return true;
-                    } catch (GeneralSecurityException e) {
-                        handleException(e);
-                        return false;
-                    } catch (IOException e) {
-                        handleException(e);
-                        return false;
-                    } catch (KeytoolException e) {
-                        handleException(e);
-                        return false;
-                    } catch (AndroidLocationException e) {
-                        handleException(e);
-                        return false;
-                    }
-
-            
-                } else {
-                    // file does not exist.
-                    showErrorMessage("Not a valid keystore path.");
-                    return false;  // Apply/OK must be disabled
-                }
-            }
-
-            clearErrorMessage();
-            return true;
-        }
-        
-        @Override
-        public Text getTextControl(Composite parent) {
-            setValidateStrategy(VALIDATE_ON_KEY_STROKE);
-            return super.getTextControl(parent);
-        }
-
-        /**
-         * Set the error message from a {@link Throwable}. If the exception has no message, try
-         * to get the message from the cause.
-         * @param t the Throwable.
-         */
-        private void handleException(Throwable t) {
-            String msg = t.getMessage();
-            if (msg == null) {
-                Throwable cause = t.getCause();
-                if (cause != null) {
-                    handleException(cause);
-                } else {
-                    setErrorMessage("Uknown error when getting the debug key!");
-                }
-                
-                return;
-            }
-
-            // valid text, display it.
-            showErrorMessage(msg);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/LaunchPreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/LaunchPreferencePage.java
deleted file mode 100644
index 8fd72c1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/LaunchPreferencePage.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.preferences;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.StringFieldEditor;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * Settings page for launch related preferences.
- */
-public class LaunchPreferencePage extends FieldEditorPreferencePage implements
-        IWorkbenchPreferencePage {
-    
-    public LaunchPreferencePage() {
-        super(GRID);
-        setPreferenceStore(AdtPlugin.getDefault().getPreferenceStore());
-        setDescription(Messages.LaunchPreferencePage_Title);
-    }
-
-    @Override
-    protected void createFieldEditors() {
-        addField(new StringFieldEditor(AdtPlugin.PREFS_EMU_OPTIONS,
-                Messages.LaunchPreferencePage_Default_Emu_Options, getFieldEditorParent()));
-
-        addField(new StringFieldEditor(AdtPlugin.PREFS_HOME_PACKAGE,
-                Messages.LaunchPreferencePage_Default_HOME_Package, getFieldEditorParent()));
-    }
-
-    public void init(IWorkbench workbench) {
-        // pass
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/Messages.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/Messages.java
deleted file mode 100644
index e0197b9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/Messages.java
+++ /dev/null
@@ -1,43 +0,0 @@
-
-package com.android.ide.eclipse.adt.preferences;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "com.android.ide.eclipse.adt.preferences.messages"; //$NON-NLS-1$
-
-    public static String AndroidPreferencePage_ERROR_Reserved_Char;
-
-    public static String AndroidPreferencePage_SDK_Location_;
-
-    public static String AndroidPreferencePage_Title;
-
-    public static String BuildPreferencePage_Auto_Refresh_Resources_on_Build;
-
-    public static String BuildPreferencePage_Build_Output;
-
-    public static String BuildPreferencePage_Custom_Keystore;
-
-    public static String BuildPreferencePage_Default_KeyStore;
-
-    public static String BuildPreferencePage_Normal;
-
-    public static String BuildPreferencePage_Silent;
-
-    public static String BuildPreferencePage_Title;
-
-    public static String BuildPreferencePage_Verbose;
-
-    public static String LaunchPreferencePage_Default_Emu_Options;
-
-    public static String LaunchPreferencePage_Default_HOME_Package;
-
-    public static String LaunchPreferencePage_Title;
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/PreferenceInitializer.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/PreferenceInitializer.java
deleted file mode 100644
index 2b1fb66..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/PreferenceInitializer.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.preferences;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.jarutils.DebugKeyProvider;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-
-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
-import org.eclipse.jface.preference.IPreferenceStore;
-
-/**
- * Class used to initialize default preference values.
- */
-public class PreferenceInitializer extends AbstractPreferenceInitializer {
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer
-     * #initializeDefaultPreferences()
-     */
-    @Override
-    public void initializeDefaultPreferences() {
-        IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-
-        store.setDefault(AdtPlugin.PREFS_RES_AUTO_REFRESH, true);
-
-        store.setDefault(AdtPlugin.PREFS_BUILD_VERBOSITY, BuildPreferencePage.BUILD_STR_NORMAL);
-        
-        store.setDefault(AdtPlugin.PREFS_HOME_PACKAGE, "android.process.acore"); //$NON-NLS-1$
-        
-        try {
-            store.setDefault(AdtPlugin.PREFS_DEFAULT_DEBUG_KEYSTORE,
-                    DebugKeyProvider.getDefaultKeyStoreOsPath());
-        } catch (KeytoolException e) {
-            AdtPlugin.log(e, "Get default debug keystore path failed"); //$NON-NLS-1$
-        } catch (AndroidLocationException e) {
-            AdtPlugin.log(e, "Get default debug keystore path failed"); //$NON-NLS-1$
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/messages.properties b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/messages.properties
deleted file mode 100644
index 865ac19..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/preferences/messages.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-BuildPreferencePage_Title=Build Settings:
-BuildPreferencePage_Auto_Refresh_Resources_on_Build=Automatically refresh Resources and Assets folder on build
-BuildPreferencePage_Build_Output=Build output
-BuildPreferencePage_Silent=Silent
-BuildPreferencePage_Normal=Normal
-BuildPreferencePage_Verbose=Verbose
-BuildPreferencePage_Default_KeyStore=Default debug keystore:
-BuildPreferencePage_Custom_Keystore=Custom debug keystore:
-LaunchPreferencePage_Title=Launch Settings:
-LaunchPreferencePage_Default_Emu_Options=Default emulator options:
-LaunchPreferencePage_Default_HOME_Package=Default HOME package:
-AndroidPreferencePage_Title=Android Preferences
-AndroidPreferencePage_SDK_Location_=SDK Location:
-AndroidPreferencePage_ERROR_Reserved_Char=Reserved characters ',' and ';' cannot be used in the SDK Location.
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/AndroidNature.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/AndroidNature.java
deleted file mode 100644
index 9bcadaf..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/AndroidNature.java
+++ /dev/null
@@ -1,291 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.build.ApkBuilder;
-import com.android.ide.eclipse.adt.build.PreCompilerBuilder;
-import com.android.ide.eclipse.adt.build.ResourceManagerBuilder;
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.ICommand;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IProjectNature;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.jdt.core.JavaCore;
-
-/**
- * Project nature for the Android Projects.
- */
-public class AndroidNature implements IProjectNature {
-
-    /** the project this nature object is associated with */
-    private IProject mProject;
-
-    /**
-     * Configures this nature for its project. This is called by the workspace
-     * when natures are added to the project using
-     * <code>IProject.setDescription</code> and should not be called directly
-     * by clients. The nature extension id is added to the list of natures
-     * before this method is called, and need not be added here.
-     *
-     * Exceptions thrown by this method will be propagated back to the caller of
-     * <code>IProject.setDescription</code>, but the nature will remain in
-     * the project description.
-     *
-     * The Android nature adds the pre-builder and the APK builder if necessary.
-     *
-     * @see org.eclipse.core.resources.IProjectNature#configure()
-     * @throws CoreException if configuration fails.
-     */
-    public void configure() throws CoreException {
-        configureResourceManagerBuilder(mProject);
-        configurePreBuilder(mProject);
-        configureApkBuilder(mProject);
-    }
-
-    /**
-     * De-configures this nature for its project. This is called by the
-     * workspace when natures are removed from the project using
-     * <code>IProject.setDescription</code> and should not be called directly
-     * by clients. The nature extension id is removed from the list of natures
-     * before this method is called, and need not be removed here.
-     *
-     * Exceptions thrown by this method will be propagated back to the caller of
-     * <code>IProject.setDescription</code>, but the nature will still be
-     * removed from the project description.
-     *
-     * The Android nature removes the custom pre builder and APK builder.
-     *
-     * @see org.eclipse.core.resources.IProjectNature#deconfigure()
-     * @throws CoreException if configuration fails.
-     */
-    public void deconfigure() throws CoreException {
-        // remove the android builders
-        removeBuilder(mProject, ResourceManagerBuilder.ID);
-        removeBuilder(mProject, PreCompilerBuilder.ID);
-        removeBuilder(mProject, ApkBuilder.ID);
-    }
-
-    /**
-     * Returns the project to which this project nature applies.
-     *
-     * @return the project handle
-     * @see org.eclipse.core.resources.IProjectNature#getProject()
-     */
-    public IProject getProject() {
-        return mProject;
-    }
-
-    /**
-     * Sets the project to which this nature applies. Used when instantiating
-     * this project nature runtime. This is called by
-     * <code>IProject.create()</code> or
-     * <code>IProject.setDescription()</code> and should not be called
-     * directly by clients.
-     *
-     * @param project the project to which this nature applies
-     * @see org.eclipse.core.resources.IProjectNature#setProject(org.eclipse.core.resources.IProject)
-     */
-    public void setProject(IProject project) {
-        mProject = project;
-    }
-
-    /**
-     * Adds the Android Nature and the Java Nature to the project if it doesn't
-     * already have them.
-     *
-     * @param project An existing or new project to update
-     * @param monitor An optional progress monitor. Can be null.
-     * @throws CoreException if fails to change the nature.
-     */
-    public static synchronized void setupProjectNatures(IProject project,
-            IProgressMonitor monitor) throws CoreException {
-        if (project == null || !project.isOpen()) return;
-        if (monitor == null) monitor = new NullProgressMonitor();
-
-        // Add the natures. We need to add the Java nature first, so it adds its builder to the
-        // project first. This way, when the android nature is added, we can control where to put
-        // the android builders in relation to the java builder.
-        // Adding the java nature after the android one, would place the java builder before the
-        // android builders.
-        addNatureToProjectDescription(project, JavaCore.NATURE_ID, monitor);
-        addNatureToProjectDescription(project, AndroidConstants.NATURE, monitor);
-    }
-
-    /**
-     * Add the specified nature to the specified project. The nature is only
-     * added if not already present.
-     * <p/>
-     * Android Natures are always inserted at the beginning of the list of natures in order to
-     * have the jdt views/dialogs display the proper icon.
-     *
-     * @param project The project to modify.
-     * @param natureId The Id of the nature to add.
-     * @param monitor An existing progress monitor.
-     * @throws CoreException if fails to change the nature.
-     */
-    private static void addNatureToProjectDescription(IProject project,
-            String natureId, IProgressMonitor monitor) throws CoreException {
-        if (!project.hasNature(natureId)) {
-
-            IProjectDescription description = project.getDescription();
-            String[] natures = description.getNatureIds();
-            String[] newNatures = new String[natures.length + 1];
-            
-            // Android natures always come first.
-            if (natureId.equals(AndroidConstants.NATURE)) {
-                System.arraycopy(natures, 0, newNatures, 1, natures.length);
-                newNatures[0] = natureId;
-            } else {
-                System.arraycopy(natures, 0, newNatures, 0, natures.length);
-                newNatures[natures.length] = natureId;
-            }
-            
-            description.setNatureIds(newNatures);
-            project.setDescription(description, new SubProgressMonitor(monitor, 10));
-        }
-    }
-
-    /**
-     * Adds the ResourceManagerBuilder, if its not already there. It'll insert
-     * itself as the first builder.
-     * @throws CoreException
-     *
-     */
-    public static void configureResourceManagerBuilder(IProject project)
-            throws CoreException {
-        // get the builder list
-        IProjectDescription desc = project.getDescription();
-        ICommand[] commands = desc.getBuildSpec();
-
-        // look for the builder in case it's already there.
-        for (int i = 0; i < commands.length; ++i) {
-            if (ResourceManagerBuilder.ID.equals(commands[i].getBuilderName())) {
-                return;
-            }
-        }
-
-        // it's not there, lets add it at the beginning of the builders
-        ICommand[] newCommands = new ICommand[commands.length + 1];
-        System.arraycopy(commands, 0, newCommands, 1, commands.length);
-        ICommand command = desc.newCommand();
-        command.setBuilderName(ResourceManagerBuilder.ID);
-        newCommands[0] = command;
-        desc.setBuildSpec(newCommands);
-        project.setDescription(desc, null);
-    }
-
-    /**
-     * Adds the PreCompilerBuilder if its not already there. It'll check for
-     * presence of the ResourceManager and insert itself right after.
-     * @param project
-     * @throws CoreException
-     */
-    public static void configurePreBuilder(IProject project)
-            throws CoreException {
-        // get the builder list
-        IProjectDescription desc = project.getDescription();
-        ICommand[] commands = desc.getBuildSpec();
-
-        // look for the builder in case it's already there.
-        for (int i = 0; i < commands.length; ++i) {
-            if (PreCompilerBuilder.ID.equals(commands[i].getBuilderName())) {
-                return;
-            }
-        }
-
-        // we need to add it after the resource manager builder.
-        // Let's look for it
-        int index = -1;
-        for (int i = 0; i < commands.length; ++i) {
-            if (ResourceManagerBuilder.ID.equals(commands[i].getBuilderName())) {
-                index = i;
-                break;
-            }
-        }
-
-        // we're inserting after
-        index++;
-
-        // do the insertion
-
-        // copy the builders before.
-        ICommand[] newCommands = new ICommand[commands.length + 1];
-        System.arraycopy(commands, 0, newCommands, 0, index);
-
-        // insert the new builder
-        ICommand command = desc.newCommand();
-        command.setBuilderName(PreCompilerBuilder.ID);
-        newCommands[index] = command;
-
-        // copy the builder after
-        System.arraycopy(commands, index, newCommands, index + 1, commands.length-index);
-
-        // set the new builders in the project
-        desc.setBuildSpec(newCommands);
-        project.setDescription(desc, null);
-    }
-
-    public static void configureApkBuilder(IProject project)
-            throws CoreException {
-        // Add the .apk builder at the end if it's not already there
-        IProjectDescription desc = project.getDescription();
-        ICommand[] commands = desc.getBuildSpec();
-
-        for (int i = 0; i < commands.length; ++i) {
-            if (ApkBuilder.ID.equals(commands[i].getBuilderName())) {
-                return;
-            }
-        }
-
-        ICommand[] newCommands = new ICommand[commands.length + 1];
-        System.arraycopy(commands, 0, newCommands, 0, commands.length);
-        ICommand command = desc.newCommand();
-        command.setBuilderName(ApkBuilder.ID);
-        newCommands[commands.length] = command;
-        desc.setBuildSpec(newCommands);
-        project.setDescription(desc, null);
-    }
-
-    /**
-     * Removes a builder from the project.
-     * @param project The project to remove the builder from.
-     * @param id The String ID of the builder to remove.
-     * @return true if the builder was found and removed.
-     * @throws CoreException
-     */
-    public static boolean removeBuilder(IProject project, String id) throws CoreException {
-        IProjectDescription description = project.getDescription();
-        ICommand[] commands = description.getBuildSpec();
-        for (int i = 0; i < commands.length; ++i) {
-            if (id.equals(commands[i].getBuilderName())) {
-                ICommand[] newCommands = new ICommand[commands.length - 1];
-                System.arraycopy(commands, 0, newCommands, 0, i);
-                System.arraycopy(commands, i + 1, newCommands, i, commands.length - i - 1);
-                description.setBuildSpec(newCommands);
-                project.setDescription(description, null);
-                return true;
-            }
-        }
-
-        return false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ConvertToAndroidAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ConvertToAndroidAction.java
deleted file mode 100644
index ffb2535..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ConvertToAndroidAction.java
+++ /dev/null
@@ -1,153 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbenchPart;
-
-import java.util.Iterator;
-
-/**
- * Converts a project created with the activity creator into an
- * Android project.
- */
-public class ConvertToAndroidAction implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
-     */
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-        // pass
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see IActionDelegate#run(IAction)
-     */
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-            for (Iterator<?> it = ((IStructuredSelection)mSelection).iterator(); it.hasNext();) {
-                Object element = it.next();
-                IProject project = null;
-                if (element instanceof IProject) {
-                    project = (IProject)element;
-                } else if (element instanceof IAdaptable) {
-                    project = (IProject)((IAdaptable)element).getAdapter(IProject.class);
-                }
-                if (project != null) {
-                    convertProject(project);
-                }
-            }
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see IActionDelegate#selectionChanged(IAction, ISelection)
-     */
-    public void selectionChanged(IAction action, ISelection selection) {
-        this.mSelection = selection;
-    }
-
-    /**
-     * Toggles sample nature on a project
-     * 
-     * @param project to have sample nature added or removed
-     */
-    private void convertProject(final IProject project) {
-        new Job("Convert Project") {
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {
-                    if (monitor != null) {
-                        monitor.beginTask(String.format(
-                                "Convert %1$s to Android", project.getName()), 5);
-                    }
-
-                    IProjectDescription description = project.getDescription();
-                    String[] natures = description.getNatureIds();
-
-                    // check if the project already has the android nature.
-                    for (int i = 0; i < natures.length; ++i) {
-                        if (AndroidConstants.NATURE.equals(natures[i])) {
-                            // we shouldn't be here as the visibility of the item
-                            // is dependent on the project.
-                            return new Status(Status.WARNING, AdtPlugin.PLUGIN_ID,
-                                    "Project is already an Android project");
-                        }
-                    }
-
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    String[] newNatures = new String[natures.length + 1];
-                    System.arraycopy(natures, 0, newNatures, 1, natures.length);
-                    newNatures[0] = AndroidConstants.NATURE;
-
-                    // set the new nature list in the project
-                    description.setNatureIds(newNatures);
-                    project.setDescription(description, null);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    // Fix the classpath entries.
-                    // get a java project
-                    IJavaProject javaProject = JavaCore.create(project);
-                    ProjectHelper.fixProjectClasspathEntries(javaProject);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    return Status.OK_STATUS;
-                } catch (JavaModelException e) {
-                    return e.getJavaModelStatus();
-                } catch (CoreException e) {
-                    return e.getStatus();
-                } finally {
-                    if (monitor != null) {
-                        monitor.done();
-                    }
-                }
-            }
-        }.schedule();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/CreateAidlImportAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/CreateAidlImportAction.java
deleted file mode 100644
index a1b3c38..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/CreateAidlImportAction.java
+++ /dev/null
@@ -1,210 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbenchPart;
-
-import java.io.File;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Iterator;
-
-/**
- * Action going through all the source of a project and creating a pre-processed aidl file
- * with all the custom parcelable classes.
- */
-public class CreateAidlImportAction  implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-
-    public CreateAidlImportAction() {
-        // pass
-    }
-
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-        // pass
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction)
-     */
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-            for (Iterator<?> it = ((IStructuredSelection)mSelection).iterator(); it.hasNext();) {
-                Object element = it.next();
-                IProject project = null;
-                if (element instanceof IProject) {
-                    project = (IProject)element;
-                } else if (element instanceof IAdaptable) {
-                    project = (IProject)((IAdaptable)element).getAdapter(IProject.class);
-                }
-                if (project != null) {
-                    final IProject fproject = project;
-                    new Job("Aidl preprocess") {
-                        @Override
-                        protected IStatus run(IProgressMonitor monitor) {
-                            return createImportFile(fproject, monitor);
-                        }
-                    }.schedule();
-                }
-            }
-        }
-    }
-
-    public void selectionChanged(IAction action, ISelection selection) {
-        mSelection = selection;
-    }
-
-    private IStatus createImportFile(IProject project, IProgressMonitor monitor) {
-        try {
-            if (monitor != null) {
-                monitor.beginTask(String.format(
-                        "Creating aid preprocess file for %1$s", project.getName()), 1);
-            }
-            
-            ArrayList<String> parcelables = new ArrayList<String>();
-            
-            IJavaProject javaProject = JavaCore.create(project);
-            
-            IPackageFragmentRoot[] roots = javaProject.getPackageFragmentRoots();
-            
-            for (IPackageFragmentRoot root : roots) {
-                if (root.isArchive() == false && root.isExternal() == false) {
-                    parsePackageFragmentRoot(root, parcelables, monitor);
-                }
-            }
-            
-            // create the file with the parcelables
-            if (parcelables.size() > 0) {
-                IPath path = project.getLocation();
-                path = path.append(AndroidConstants.FN_PROJECT_AIDL);
-                
-                File f = new File(path.toOSString());
-                if (f.exists() == false) {
-                    if (f.createNewFile() == false) {
-                        return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                                "Failed to create /project.aidl");
-                    }
-                }
-                
-                FileWriter fw = new FileWriter(f);
-                
-                fw.write("// This file is auto-generated by the\n");
-                fw.write("//    'Create Aidl preprocess file for Parcelable classes'\n");
-                fw.write("// action. Do not modify!\n\n");
-                
-                for (String parcelable : parcelables) {
-                    fw.write("parcelable "); //$NON-NLS-1$
-                    fw.write(parcelable);
-                    fw.append(";\n"); //$NON-NLS-1$
-                }
-                
-                fw.close();
-                
-                // need to refresh the level just below the project to make sure it's being picked
-                // up by eclipse.
-                project.refreshLocal(IResource.DEPTH_ONE, monitor);
-            }
-            
-            if (monitor != null) {
-                monitor.worked(1);
-                monitor.done();
-            }
-            
-            return Status.OK_STATUS;
-        } catch (JavaModelException e) {
-            return e.getJavaModelStatus();
-        } catch (IOException e) {
-            return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                    "Failed to create /project.aidl", e);
-        } catch (CoreException e) {
-            return e.getStatus();
-        } finally {
-            if (monitor != null) {
-                monitor.done();
-            }
-        }
-    }
-    
-    private void parsePackageFragmentRoot(IPackageFragmentRoot root,
-            ArrayList<String> parcelables, IProgressMonitor monitor) throws JavaModelException {
-        
-        IJavaElement[] elements = root.getChildren();
-        
-        for (IJavaElement element : elements) {
-            if (element instanceof IPackageFragment) {
-                ICompilationUnit[] compilationUnits =
-                    ((IPackageFragment)element).getCompilationUnits();
-                
-                for (ICompilationUnit unit : compilationUnits) {
-                    IType[] types = unit.getTypes();
-                    
-                    for (IType type : types) {
-                        parseType(type, parcelables, monitor);
-                    }
-                }
-            }
-        }
-    }
-
-    private void parseType(IType type, ArrayList<String> parcelables, IProgressMonitor monitor)
-            throws JavaModelException {
-        // first look in this type if it somehow extends parcelable.
-        ITypeHierarchy typeHierarchy = type.newSupertypeHierarchy(monitor);
-        
-        IType[] superInterfaces = typeHierarchy.getAllSuperInterfaces(type);
-        for (IType superInterface : superInterfaces) {
-            if (AndroidConstants.CLASS_PARCELABLE.equals(superInterface.getFullyQualifiedName())) {
-                parcelables.add(type.getFullyQualifiedName());
-            }
-        }
-        
-        // then look in inner types.
-        IType[] innerTypes = type.getTypes();
-        
-        for (IType innerType : innerTypes) {
-            parseType(innerType, parcelables, monitor);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportAction.java
deleted file mode 100644
index 3d7e929..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportAction.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.common.project.ExportHelper;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbenchPart;
-
-public class ExportAction implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-
-    /**
-     * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
-     */
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-    }
-
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-            IStructuredSelection selection = (IStructuredSelection)mSelection;
-            // get the unique selected item.
-            if (selection.size() == 1) {
-                Object element = selection.getFirstElement();
-
-                // get the project object from it.
-                IProject project = null;
-                if (element instanceof IProject) {
-                    project = (IProject) element;
-                } else if (element instanceof IAdaptable) {
-                    project = (IProject) ((IAdaptable) element).getAdapter(IProject.class);
-                }
-
-                // and finally do the action
-                if (project != null) {
-                    ExportHelper.exportProject(project);
-                }
-            }
-        }
-    }
-
-    public void selectionChanged(IAction action, ISelection selection) {
-        this.mSelection = selection;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportWizardAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportWizardAction.java
deleted file mode 100644
index 9ade490..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ExportWizardAction.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.project.export.ExportWizard;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPart;
-
-public class ExportWizardAction implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-    private IWorkbench mWorkbench;
-
-    /**
-     * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
-     */
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-        mWorkbench = targetPart.getSite().getWorkbenchWindow().getWorkbench();
-    }
-
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-            IStructuredSelection selection = (IStructuredSelection)mSelection;
-
-            // call the export wizard on the current selection.
-            ExportWizard wizard = new ExportWizard();
-            wizard.init(mWorkbench, selection);
-            WizardDialog dialog = new WizardDialog(mWorkbench.getDisplay().getActiveShell(),
-                    wizard);
-            dialog.open();
-        }
-    }
-
-    public void selectionChanged(IAction action, ISelection selection) {
-        this.mSelection = selection;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixLaunchConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixLaunchConfig.java
deleted file mode 100644
index b8a0b0c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixLaunchConfig.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.debug.launching.LaunchConfigDelegate;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
-
-import java.util.ArrayList;
-
-/**
- * Class to fix the launch configuration of a project if the java package
- * defined in the manifest has been changed.<br>
- * This fix can be done synchronously, or asynchronously.<br>
- * <code>start()</code> will start a thread that will do the fix.<br>
- * <code>run()</code> will do the fix in the current thread.<br><br>
- * By default, the fix first display a dialog to the user asking if he/she wants to
- * do the fix. This can be overriden by calling <code>setDisplayPrompt(false)</code>.
- *
- */
-public class FixLaunchConfig extends Thread {
-
-    private IProject mProject;
-    private String mOldPackage;
-    private String mNewPackage;
-
-    private boolean mDisplayPrompt = true;
-
-    public FixLaunchConfig(IProject project, String oldPackage, String newPackage) {
-        super();
-
-        mProject = project;
-        mOldPackage = oldPackage;
-        mNewPackage = newPackage;
-    }
-
-    /**
-     * Set the display prompt. If true run()/start() first ask the user if he/she wants
-     * to fix the Launch Config
-     * @param displayPrompt
-     */
-    public void setDisplayPrompt(boolean displayPrompt) {
-        mDisplayPrompt = displayPrompt;
-    }
-
-    /**
-     * Fix the Launch configurations.
-     */
-    @Override
-    public void run() {
-
-        if (mDisplayPrompt) {
-            // ask the user if he really wants to fix the launch config
-            boolean res = AdtPlugin.displayPrompt(
-                    "Launch Configuration Update",
-                    "The package definition in the manifest changed.\nDo you want to update your Launch Configuration(s)?");
-
-            if (res == false) {
-                return;
-            }
-        }
-
-        // get the list of config for the project
-        String projectName = mProject.getName();
-        ILaunchConfiguration[] configs = findConfigs(mProject.getName());
-
-        // loop through all the config and update the package
-        for (ILaunchConfiguration config : configs) {
-            try {
-                // get the working copy so that we can make changes.
-                ILaunchConfigurationWorkingCopy copy = config.getWorkingCopy();
-
-                // get the attributes for the activity
-                String activity = config.getAttribute(LaunchConfigDelegate.ATTR_ACTIVITY,
-                        ""); //$NON-NLS-1$
-
-                // manifests can define activities that are not in the defined package,
-                // so we need to make sure the activity is inside the old package.
-                if (activity.startsWith(mOldPackage)) {
-                    // create the new activity
-                    activity = mNewPackage + activity.substring(mOldPackage.length());
-
-                    // put it in the copy
-                    copy.setAttribute(LaunchConfigDelegate.ATTR_ACTIVITY, activity);
-
-                    // save the config
-                    copy.doSave();
-                }
-            } catch (CoreException e) {
-                // couldn't get the working copy. we output the error in the console
-                String msg = String.format("Failed to modify %1$s: %2$s", projectName,
-                        e.getMessage());
-                AdtPlugin.printErrorToConsole(mProject, msg);
-            }
-        }
-
-    }
-
-    /**
-     * Looks for and returns all existing Launch Configuration object for a
-     * specified project.
-     * @param projectName The name of the project
-     * @return all the ILaunchConfiguration object. If none are present, an empty array is
-     * returned.
-     */
-    private static ILaunchConfiguration[] findConfigs(String projectName) {
-        // get the launch manager
-        ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager();
-
-        // now get the config type for our particular android type.
-        ILaunchConfigurationType configType = manager.
-                getLaunchConfigurationType(LaunchConfigDelegate.ANDROID_LAUNCH_TYPE_ID);
-
-        // create a temp list to hold all the valid configs
-        ArrayList<ILaunchConfiguration> list = new ArrayList<ILaunchConfiguration>();
-
-        try {
-            ILaunchConfiguration[] configs = manager.getLaunchConfigurations(configType);
-
-            for (ILaunchConfiguration config : configs) {
-                if (config.getAttribute(
-                        IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME,
-                        "").equals(projectName)) {  //$NON-NLS-1$
-                    list.add(config);
-                }
-            }
-        } catch (CoreException e) {
-        }
-
-        return list.toArray(new ILaunchConfiguration[list.size()]);
-
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixProjectAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixProjectAction.java
deleted file mode 100644
index 3043818..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FixProjectAction.java
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.IWorkbenchWindowActionDelegate;
-
-import java.util.Iterator;
-
-/**
- * Action to fix the project properties:
- * <ul>
- * <li>Make sure the framework archive is present with the link to the java
- * doc</li>
- * </ul>
- */
-public class FixProjectAction implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-
-    /**
-     * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
-     */
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-    }
-
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-
-            for (Iterator<?> it = ((IStructuredSelection) mSelection).iterator();
-                    it.hasNext();) {
-                Object element = it.next();
-                IProject project = null;
-                if (element instanceof IProject) {
-                    project = (IProject) element;
-                } else if (element instanceof IAdaptable) {
-                    project = (IProject) ((IAdaptable) element)
-                            .getAdapter(IProject.class);
-                }
-                if (project != null) {
-                    fixProject(project);
-                }
-            }
-        }
-    }
-
-    public void selectionChanged(IAction action, ISelection selection) {
-        this.mSelection = selection;
-    }
-
-    private void fixProject(final IProject project) {
-        new Job("Fix Project Properties") {
-
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {
-                    if (monitor != null) {
-                        monitor.beginTask("Fix Project Properties", 6);
-                    }
-
-                    ProjectHelper.fixProject(project);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-                    
-                    // fix the nature order to have the proper project icon
-                    ProjectHelper.fixProjectNatureOrder(project);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    // now we fix the builders
-                    AndroidNature.configureResourceManagerBuilder(project);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    AndroidNature.configurePreBuilder(project);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-
-                    AndroidNature.configureApkBuilder(project);
-                    if (monitor != null) {
-                        monitor.worked(1);
-                    }
-                    
-                    return Status.OK_STATUS;
-                } catch (JavaModelException e) {
-                    return e.getJavaModelStatus();
-                } catch (CoreException e) {
-                    return e.getStatus();
-                } finally {
-                    if (monitor != null) {
-                        monitor.done();
-                    }
-                }
-            }
-        }.schedule();
-    }
-
-    /**
-     * @see IWorkbenchWindowActionDelegate#init
-     */
-    public void init(IWorkbenchWindow window) {
-        // pass
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FolderDecorator.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FolderDecorator.java
deleted file mode 100644
index 7fc3318..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/FolderDecorator.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.IDecoration;
-import org.eclipse.jface.viewers.ILabelDecorator;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ILightweightLabelDecorator;
-
-/**
- * A {@link ILabelDecorator} associated with an org.eclipse.ui.decorators extension.
- * This is used to add android icons in some special folders in the package explorer.
- */
-public class FolderDecorator implements ILightweightLabelDecorator {
-    
-    private ImageDescriptor mDescriptor;
-
-    public FolderDecorator() {
-        mDescriptor = AdtPlugin.getImageDescriptor("/icons/android_project.png");
-    }
-
-    public void decorate(Object element, IDecoration decoration) {
-        if (element instanceof IFolder) {
-            IFolder folder = (IFolder)element;
-            
-            // get the project and make sure this is an android project
-            IProject project = folder.getProject();
-
-            try {
-                if (project.hasNature(AndroidConstants.NATURE)) {
-                    // check the folder is directly under the project.
-                    if (folder.getParent().getType() == IResource.PROJECT) {
-                        String name = folder.getName();
-                        if (name.equals(SdkConstants.FD_ASSETS)) {
-                            decorate(decoration, " [Android assets]");
-                            decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT);
-                        } else if (name.equals(SdkConstants.FD_RESOURCES)) {
-                            decorate(decoration, " [Android resources]");
-                            decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT);
-                        } else if (name.equals(SdkConstants.FD_NATIVE_LIBS)) {
-                            decorate(decoration, " [Native Libraries]");
-                        }
-                    }
-                }
-            } catch (CoreException e) {
-                // log the error
-                AdtPlugin.log(e, "Unable to get nature of project '%s'.", project.getName());
-            }
-        }
-    }
-    
-    public void decorate(IDecoration decoration, String suffix) {
-        decoration.addOverlay(mDescriptor, IDecoration.TOP_RIGHT);
-
-        // this is broken as it changes the color of the whole text, not only of the decoration.
-        // TODO: figure out how to change the color of the decoration only.
-//        decoration.addSuffix(suffix);
-//        ITheme theme = PlatformUI.getWorkbench().getThemeManager().getCurrentTheme();
-//        ColorRegistry registry = theme.getColorRegistry();
-//        decoration.setForegroundColor(registry.get("org.eclipse.jdt.ui.ColoredLabels.decorations"));
-
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        // at this time return false.
-        return false;
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // No state change will affect the rendering.
-    }
-
-
-
-    public void removeListener(ILabelProviderListener listener) {
-        // No state change will affect the rendering.
-    }
-
-    public void dispose() {
-        // nothind to dispose
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/NewXmlFileWizardAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/NewXmlFileWizardAction.java
deleted file mode 100644
index c117b4e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/NewXmlFileWizardAction.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.editors.wizards.NewXmlFileWizard;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPart;
-
-public class NewXmlFileWizardAction implements IObjectActionDelegate {
-
-    private ISelection mSelection;
-    private IWorkbench mWorkbench;
-
-    /**
-     * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
-     */
-    public void setActivePart(IAction action, IWorkbenchPart targetPart) {
-        mWorkbench = targetPart.getSite().getWorkbenchWindow().getWorkbench();
-    }
-
-    public void run(IAction action) {
-        if (mSelection instanceof IStructuredSelection) {
-            IStructuredSelection selection = (IStructuredSelection)mSelection;
-
-            // call the new xml file wizard on the current selection.
-            NewXmlFileWizard wizard = new NewXmlFileWizard();
-            wizard.init(mWorkbench, selection);
-            WizardDialog dialog = new WizardDialog(mWorkbench.getDisplay().getActiveShell(),
-                    wizard);
-            dialog.open();
-        }
-    }
-
-    public void selectionChanged(IAction action, ISelection selection) {
-        this.mSelection = selection;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ProjectHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ProjectHelper.java
deleted file mode 100644
index cbeddd7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/ProjectHelper.java
+++ /dev/null
@@ -1,668 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.IncrementalProjectBuilder;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.launching.JavaRuntime;
-
-import java.util.ArrayList;
-
-/**
- * Utility class to manipulate Project parameters/properties.
- */
-public final class ProjectHelper {
-    public final static int COMPILER_COMPLIANCE_OK = 0;
-    public final static int COMPILER_COMPLIANCE_LEVEL = 1;
-    public final static int COMPILER_COMPLIANCE_SOURCE = 2;
-    public final static int COMPILER_COMPLIANCE_CODEGEN_TARGET = 3;
-
-    /**
-     * Adds the corresponding source folder to the class path entries.
-     *
-     * @param entries The class path entries to read. A copy will be returned.
-     * @param new_entry The parent source folder to remove.
-     * @return A new class path entries array.
-     */
-    public static IClasspathEntry[] addEntryToClasspath(
-            IClasspathEntry[] entries, IClasspathEntry new_entry) {
-        int n = entries.length;
-        IClasspathEntry[] newEntries = new IClasspathEntry[n + 1];
-        System.arraycopy(entries, 0, newEntries, 0, n);
-        newEntries[n] = new_entry;
-        return newEntries;
-    }
-
-    /**
-     * Remove a classpath entry from the array.
-     * @param entries The class path entries to read. A copy will be returned
-     * @param index The index to remove.
-     * @return A new class path entries array.
-     */
-    public static IClasspathEntry[] removeEntryFromClasspath(
-            IClasspathEntry[] entries, int index) {
-        int n = entries.length;
-        IClasspathEntry[] newEntries = new IClasspathEntry[n-1];
-
-        // copy the entries before index
-        System.arraycopy(entries, 0, newEntries, 0, index);
-
-        // copy the entries after index
-        System.arraycopy(entries, index + 1, newEntries, index,
-                entries.length - index - 1);
-
-        return newEntries;
-    }
-
-    /**
-     * Converts a OS specific path into a path valid for the java doc location
-     * attributes of a project.
-     * @param javaDocOSLocation The OS specific path.
-     * @return a valid path for the java doc location.
-     */
-    public static String getJavaDocPath(String javaDocOSLocation) {
-        // first thing we do is convert the \ into /
-        String javaDoc = javaDocOSLocation.replaceAll("\\\\", //$NON-NLS-1$
-                AndroidConstants.WS_SEP);
-
-        // then we add file: at the beginning for unix path, and file:/ for non
-        // unix path
-        if (javaDoc.startsWith(AndroidConstants.WS_SEP)) {
-            return "file:" + javaDoc; //$NON-NLS-1$
-        }
-
-        return "file:/" + javaDoc; //$NON-NLS-1$
-    }
-
-    /**
-     * Look for a specific classpath entry by full path and return its index.
-     * @param entries The entry array to search in.
-     * @param entryPath The OS specific path of the entry.
-     * @param entryKind The kind of the entry. Accepted values are 0
-     * (no filter), IClasspathEntry.CPE_LIBRARY, IClasspathEntry.CPE_PROJECT,
-     * IClasspathEntry.CPE_SOURCE, IClasspathEntry.CPE_VARIABLE,
-     * and IClasspathEntry.CPE_CONTAINER
-     * @return the index of the found classpath entry or -1.
-     */
-    public static int findClasspathEntryByPath(IClasspathEntry[] entries,
-            String entryPath, int entryKind) {
-        for (int i = 0 ; i < entries.length ; i++) {
-            IClasspathEntry entry = entries[i];
-
-            int kind = entry.getEntryKind();
-
-            if (kind == entryKind || entryKind == 0) {
-                // get the path
-                IPath path = entry.getPath();
-
-                String osPathString = path.toOSString();
-                if (osPathString.equals(entryPath)) {
-                    return i;
-                }
-            }
-        }
-
-        // not found, return bad index.
-        return -1;
-    }
-
-    /**
-     * Look for a specific classpath entry for file name only and return its
-     *  index.
-     * @param entries The entry array to search in.
-     * @param entryName The filename of the entry.
-     * @param entryKind The kind of the entry. Accepted values are 0
-     * (no filter), IClasspathEntry.CPE_LIBRARY, IClasspathEntry.CPE_PROJECT,
-     * IClasspathEntry.CPE_SOURCE, IClasspathEntry.CPE_VARIABLE,
-     * and IClasspathEntry.CPE_CONTAINER
-     * @param startIndex Index where to start the search
-     * @return the index of the found classpath entry or -1.
-     */
-    public static int findClasspathEntryByName(IClasspathEntry[] entries,
-            String entryName, int entryKind, int startIndex) {
-        if (startIndex < 0) {
-            startIndex = 0;
-        }
-        for (int i = startIndex ; i < entries.length ; i++) {
-            IClasspathEntry entry = entries[i];
-
-            int kind = entry.getEntryKind();
-
-            if (kind == entryKind || entryKind == 0) {
-                // get the path
-                IPath path = entry.getPath();
-                String name = path.segment(path.segmentCount()-1);
-
-                if (name.equals(entryName)) {
-                    return i;
-                }
-            }
-        }
-
-        // not found, return bad index.
-        return -1;
-    }
-
-    /**
-     * Fix the project. This checks the SDK location.
-     * @param project The project to fix.
-     * @throws JavaModelException
-     */
-    public static void fixProject(IProject project) throws JavaModelException {
-        if (AdtPlugin.getOsSdkFolder().length() == 0) {
-            AdtPlugin.printToConsole(project, "Unknown SDK Location, project not fixed.");
-            return;
-        }
-        
-        // get a java project
-        IJavaProject javaProject = JavaCore.create(project);
-        fixProjectClasspathEntries(javaProject);
-    }
-
-    /**
-     * Fix the project classpath entries. The method ensures that:
-     * <ul>
-     * <li>The project does not reference any old android.zip/android.jar archive.</li>
-     * <li>The project does not use its output folder as a sourc folder.</li>
-     * <li>The project does not reference a desktop JRE</li>
-     * <li>The project references the AndroidClasspathContainer.
-     * </ul>
-     * @param javaProject The project to fix.
-     * @throws JavaModelException
-     */
-    public static void fixProjectClasspathEntries(IJavaProject javaProject)
-            throws JavaModelException {
-
-        // get the project classpath
-        IClasspathEntry[] entries = javaProject.getRawClasspath();
-        IClasspathEntry[] oldEntries = entries;
-
-        // check if the JRE is set as library
-        int jreIndex = ProjectHelper.findClasspathEntryByPath(entries, JavaRuntime.JRE_CONTAINER,
-                IClasspathEntry.CPE_CONTAINER);
-        if (jreIndex != -1) {
-            // the project has a JRE included, we remove it
-            entries = ProjectHelper.removeEntryFromClasspath(entries, jreIndex);
-        }
-
-        // get the output folder
-        IPath outputFolder = javaProject.getOutputLocation();
-        
-        boolean foundContainer = false;
-
-        for (int i = 0 ; i < entries.length ;) {
-            // get the entry and kind
-            IClasspathEntry entry = entries[i];
-            int kind = entry.getEntryKind();
-
-            if (kind == IClasspathEntry.CPE_SOURCE) {
-                IPath path = entry.getPath();
-                
-                if (path.equals(outputFolder)) {
-                    entries = ProjectHelper.removeEntryFromClasspath(entries, i);
-                    
-                    // continue, to skip the i++;
-                    continue;
-                }
-            } else if (kind == IClasspathEntry.CPE_CONTAINER) {
-                if (AndroidClasspathContainerInitializer.checkPath(entry.getPath())) {
-                    foundContainer = true;
-                }
-            }
-            
-            i++;
-        }
-
-        // if the framework container is not there, we add it
-        if (foundContainer == false) {
-            // add the android container to the array
-            entries = ProjectHelper.addEntryToClasspath(entries,
-                    AndroidClasspathContainerInitializer.getContainerEntry());
-        }
-
-        // set the new list of entries to the project
-        if (entries != oldEntries) {
-            javaProject.setRawClasspath(entries, new NullProgressMonitor());
-        }
-
-        // If needed, check and fix compiler compliance and source compatibility
-        ProjectHelper.checkAndFixCompilerCompliance(javaProject);
-    }
-    /**
-     * Checks the project compiler compliance level is supported.
-     * @param javaProject The project to check
-     * @return <ul>
-     * <li><code>COMPILER_COMPLIANCE_OK</code> if the project is properly configured</li>
-     * <li><code>COMPILER_COMPLIANCE_LEVEL</code> for unsupported compiler level</li>
-     * <li><code>COMPILER_COMPLIANCE_SOURCE</code> for unsupported source compatibility</li>
-     * <li><code>COMPILER_COMPLIANCE_CODEGEN_TARGET</code> for unsupported .class format</li>
-     * </ul>
-     */
-    public static final int checkCompilerCompliance(IJavaProject javaProject) {
-        // get the project compliance level option
-        String compliance = javaProject.getOption(JavaCore.COMPILER_COMPLIANCE, true);
-
-        // check it against a list of valid compliance level strings.
-        if (checkCompliance(compliance) == false) {
-            // if we didn't find the proper compliance level, we return an error
-            return COMPILER_COMPLIANCE_LEVEL;
-        }
-
-        // otherwise we check source compatibility
-        String source = javaProject.getOption(JavaCore.COMPILER_SOURCE, true);
-
-        // check it against a list of valid compliance level strings.
-        if (checkCompliance(source) == false) {
-            // if we didn't find the proper compliance level, we return an error
-            return COMPILER_COMPLIANCE_SOURCE;
-        }
-
-        // otherwise check codegen level
-        String codeGen = javaProject.getOption(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM, true);
-
-        // check it against a list of valid compliance level strings.
-        if (checkCompliance(codeGen) == false) {
-            // if we didn't find the proper compliance level, we return an error
-            return COMPILER_COMPLIANCE_CODEGEN_TARGET;
-        }
-
-        return COMPILER_COMPLIANCE_OK;
-    }
-
-    /**
-     * Checks the project compiler compliance level is supported.
-     * @param project The project to check
-     * @return <ul>
-     * <li><code>COMPILER_COMPLIANCE_OK</code> if the project is properly configured</li>
-     * <li><code>COMPILER_COMPLIANCE_LEVEL</code> for unsupported compiler level</li>
-     * <li><code>COMPILER_COMPLIANCE_SOURCE</code> for unsupported source compatibility</li>
-     * <li><code>COMPILER_COMPLIANCE_CODEGEN_TARGET</code> for unsupported .class format</li>
-     * </ul>
-     */
-    public static final int checkCompilerCompliance(IProject project) {
-        // get the java project from the IProject resource object
-        IJavaProject javaProject = JavaCore.create(project);
-
-        // check and return the result.
-        return checkCompilerCompliance(javaProject);
-    }
-
-
-    /**
-     * Checks, and fixes if needed, the compiler compliance level, and the source compatibility
-     * level
-     * @param project The project to check and fix.
-     */
-    public static final void checkAndFixCompilerCompliance(IProject project) {
-        // get the java project from the IProject resource object
-        IJavaProject javaProject = JavaCore.create(project);
-
-        // Now we check the compiler compliance level and make sure it is valid
-        checkAndFixCompilerCompliance(javaProject);
-    }
-
-    /**
-     * Checks, and fixes if needed, the compiler compliance level, and the source compatibility
-     * level
-     * @param javaProject The Java project to check and fix.
-     */
-    public static final void checkAndFixCompilerCompliance(IJavaProject javaProject) {
-        if (checkCompilerCompliance(javaProject) != COMPILER_COMPLIANCE_OK) {
-            // setup the preferred compiler compliance level.
-            javaProject.setOption(JavaCore.COMPILER_COMPLIANCE,
-                    AndroidConstants.COMPILER_COMPLIANCE_PREFERRED);
-            javaProject.setOption(JavaCore.COMPILER_SOURCE,
-                    AndroidConstants.COMPILER_COMPLIANCE_PREFERRED);
-            javaProject.setOption(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM,
-                    AndroidConstants.COMPILER_COMPLIANCE_PREFERRED);
-
-            // clean the project to make sure we recompile
-            try {
-                javaProject.getProject().build(IncrementalProjectBuilder.CLEAN_BUILD,
-                        new NullProgressMonitor());
-            } catch (CoreException e) {
-                AdtPlugin.printErrorToConsole(javaProject.getProject(),
-                        "Project compiler settings changed. Clean your project.");
-            }
-        }
-    }
-
-    /**
-     * Returns a {@link IProject} by its running application name, as it returned by the AVD.
-     * <p/>
-     * <var>applicationName</var> will in most case be the package declared in the manifest, but
-     * can, in some cases, be a custom process name declared in the manifest, in the
-     * <code>application</code>, <code>activity</code>, <code>receiver</code>, or
-     * <code>service</code> nodes.
-     * @param applicationName The application name.
-     * @return a project or <code>null</code> if no matching project were found.
-     */
-    public static IProject findAndroidProjectByAppName(String applicationName) {
-        // Get the list of project for the current workspace
-        IWorkspace workspace = ResourcesPlugin.getWorkspace();
-        IProject[] projects = workspace.getRoot().getProjects();
-        
-        // look for a project that matches the packageName of the app
-        // we're trying to debug
-        for (IProject p : projects) {
-            if (p.isOpen()) {
-                try {
-                    if (p.hasNature(AndroidConstants.NATURE) == false) {
-                        // ignore non android projects
-                        continue;
-                    }
-                } catch (CoreException e) {
-                    // failed to get the nature? skip project.
-                    continue;
-                }
-
-                AndroidManifestHelper androidManifest = new AndroidManifestHelper(p);
-                
-                // check that there is indeed a manifest file.
-                if (androidManifest.getManifestIFile() == null) {
-                    // no file? skip this project.
-                    continue;
-                }
-
-                AndroidManifestParser parser = null;
-                try {
-                    parser = AndroidManifestParser.parseForData(
-                        androidManifest.getManifestIFile());
-                } catch (CoreException e) {
-                    // skip this project.
-                    continue;
-                }
-
-                String manifestPackage = parser.getPackage();
-
-                if (manifestPackage != null && manifestPackage.equals(applicationName)) {
-                    // this is the project we were looking for!
-                    return p;
-                } else {
-                    // if the package and application name don't match,
-                    // we look for other possible process names declared in the manifest.
-                    String[] processes = parser.getProcesses();
-                    for (String process : processes) {
-                        if (process.equals(applicationName)) {
-                            return p;
-                        }
-                    }
-                }
-            }
-        }
-
-        return null;
-
-    }
-
-    public static void fixProjectNatureOrder(IProject project) throws CoreException {
-        IProjectDescription description = project.getDescription();
-        String[] natures = description.getNatureIds();
-        
-        // if the android nature is not the first one, we reorder them
-        if (AndroidConstants.NATURE.equals(natures[0]) == false) {
-            // look for the index
-            for (int i = 0 ; i < natures.length ; i++) {
-                if (AndroidConstants.NATURE.equals(natures[i])) {
-                    // if we try to just reorder the array in one pass, this doesn't do 
-                    // anything. I guess JDT check that we are actually adding/removing nature.
-                    // So, first we'll remove the android nature, and then add it back.
-
-                    // remove the android nature
-                    removeNature(project, AndroidConstants.NATURE);
-                    
-                    // now add it back at the first index.
-                    description = project.getDescription();
-                    natures = description.getNatureIds();
-                    
-                    String[] newNatures = new String[natures.length + 1];
-
-                    // first one is android
-                    newNatures[0] = AndroidConstants.NATURE;
-                    
-                    // next the rest that was before the android nature
-                    System.arraycopy(natures, 0, newNatures, 1, natures.length);
-                    
-                    // set the new natures
-                    description.setNatureIds(newNatures);
-                    project.setDescription(description, null);
-
-                    // and stop
-                    break;
-                }
-            }
-        }
-    }
-
-
-    /**
-     * Removes a specific nature from a project.
-     * @param project The project to remove the nature from.
-     * @param nature The nature id to remove.
-     * @throws CoreException
-     */
-    public static void removeNature(IProject project, String nature) throws CoreException {
-        IProjectDescription description = project.getDescription();
-        String[] natures = description.getNatureIds();
-
-        // check if the project already has the android nature.
-        for (int i = 0; i < natures.length; ++i) {
-            if (nature.equals(natures[i])) {
-                String[] newNatures = new String[natures.length - 1];
-                if (i > 0) {
-                    System.arraycopy(natures, 0, newNatures, 0, i);
-                }
-                System.arraycopy(natures, i + 1, newNatures, i, natures.length - i - 1);
-                description.setNatureIds(newNatures);
-                project.setDescription(description, null);
-
-                return;
-            }
-        }
-
-    }
-
-    /**
-     * Returns if the project has error level markers.
-     * @param includeReferencedProjects flag to also test the referenced projects.
-     * @throws CoreException
-     */
-    public static boolean hasError(IProject project, boolean includeReferencedProjects)
-    throws CoreException {
-        IMarker[] markers = project.findMarkers(IMarker.PROBLEM, true, IResource.DEPTH_INFINITE);
-        if (markers != null && markers.length > 0) {
-            // the project has marker(s). even though they are "problem" we
-            // don't know their severity. so we loop on them and figure if they
-            // are warnings or errors
-            for (IMarker m : markers) {
-                int s = m.getAttribute(IMarker.SEVERITY, -1);
-                if (s == IMarker.SEVERITY_ERROR) {
-                    return true;
-                }
-            }
-        }
-        
-        // test the referenced projects if needed.
-        if (includeReferencedProjects) {
-            IProject[] projects = getReferencedProjects(project);
-            
-            for (IProject p : projects) {
-                if (hasError(p, false)) {
-                    return true;
-                }
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Saves a String property into the persistent storage of a resource.
-     * @param resource The resource into which the string value is saved.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param value the value to save
-     * @return true if the save succeeded.
-     */
-    public static boolean saveStringProperty(IResource resource, String propertyName,
-            String value) {
-        QualifiedName qname = new QualifiedName(AdtPlugin.PLUGIN_ID, propertyName);
-
-        try {
-            resource.setPersistentProperty(qname, value);
-        } catch (CoreException e) {
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
-     * Loads a String property from the persistent storage of a resource.
-     * @param resource The resource from which the string value is loaded.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @return the property value or null if it was not found.
-     */
-    public static String loadStringProperty(IResource resource, String propertyName) {
-        QualifiedName qname = new QualifiedName(AdtPlugin.PLUGIN_ID, propertyName);
-
-        try {
-            String value = resource.getPersistentProperty(qname);
-            return value;
-        } catch (CoreException e) {
-            return null;
-        }
-    }
-
-    /**
-     * Saves a property into the persistent storage of a resource.
-     * @param resource The resource into which the boolean value is saved.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param value the value to save
-     * @return true if the save succeeded.
-     */
-    public static boolean saveBooleanProperty(IResource resource, String propertyName,
-            boolean value) {
-        return saveStringProperty(resource, propertyName, Boolean.toString(value));
-    }
-
-    /**
-     * Loads a boolean property from the persistent storage of the project.
-     * @param resource The resource from which the boolean value is loaded.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param defaultValue The default value to return if the property was not found.
-     * @return the property value or the default value if the property was not found.
-     */
-    public static boolean loadBooleanProperty(IResource resource, String propertyName,
-            boolean defaultValue) {
-        String value = loadStringProperty(resource, propertyName);
-        if (value != null) {
-            return Boolean.parseBoolean(value);
-        }
-
-        return defaultValue;
-    }
-
-    /**
-     * Saves the path of a resource into the persistent storate of the project.
-     * @param resource The resource into which the resource path is saved.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @param value The resource to save. It's its path that is actually stored. If null, an
-     *      empty string is stored.
-     * @return true if the save succeeded
-     */
-    public static boolean saveResourceProperty(IResource resource, String propertyName,
-            IResource value) {
-        if (value != null) {
-            IPath iPath = value.getProjectRelativePath();
-            return saveStringProperty(resource, propertyName, iPath.toString());
-        }
-
-        return saveStringProperty(resource, propertyName, ""); //$NON-NLS-1$
-    }
-
-    /**
-     * Loads the path of a resource from the persistent storage of the project, and returns the
-     * corresponding IResource object, if it exists in the same project as <code>resource</code>.
-     * @param resource The resource from which the resource path is loaded.
-     * @param propertyName the name of the property. The id of the plugin is added to this string.
-     * @return The corresponding IResource object (or children interface) or null
-     */
-    public static IResource loadResourceProperty(IResource resource, String propertyName) {
-        String value = loadStringProperty(resource, propertyName);
-
-        if (value != null && value.length() > 0) {
-            return resource.getProject().findMember(value);
-        }
-
-        return null;
-    }
-    
-    /**
-     * Returns the list of referenced project that are opened and Java projects.
-     * @param project
-     * @return list of opened referenced java project.
-     * @throws CoreException
-     */
-    public static IProject[] getReferencedProjects(IProject project) throws CoreException {
-        IProject[] projects = project.getReferencedProjects();
-        
-        ArrayList<IProject> list = new ArrayList<IProject>();
-        
-        for (IProject p : projects) {
-            if (p.isOpen() && p.hasNature(JavaCore.NATURE_ID)) {
-                list.add(p);
-            }
-        }
-
-        return list.toArray(new IProject[list.size()]);
-    }
-
-
-    /**
-     * Checks a Java project compiler level option against a list of supported versions.
-     * @param optionValue the Compiler level option.
-     * @return true if the option value is supproted.
-     */
-    private static boolean checkCompliance(String optionValue) {
-        for (String s : AndroidConstants.COMPILER_COMPLIANCE) {
-            if (s != null && s.equals(optionValue)) {
-                return true;
-            }
-        }
-
-        return false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ExportWizard.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ExportWizard.java
deleted file mode 100644
index 399eac9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ExportWizard.java
+++ /dev/null
@@ -1,501 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.jarutils.KeystoreHelper;
-import com.android.jarutils.SignedJarBuilder;
-import com.android.jarutils.DebugKeyProvider.IKeyGenOutput;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IExportWizard;
-import org.eclipse.ui.IWorkbench;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.security.GeneralSecurityException;
-import java.security.KeyStore;
-import java.security.NoSuchAlgorithmException;
-import java.security.PrivateKey;
-import java.security.KeyStore.PrivateKeyEntry;
-import java.security.cert.X509Certificate;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Export wizard to export an apk signed with a release key/certificate. 
- */
-public final class ExportWizard extends Wizard implements IExportWizard {
-
-    private static final String PROJECT_LOGO_LARGE = "icons/android_large.png"; //$NON-NLS-1$
-    
-    private static final String PAGE_PROJECT_CHECK = "Page_ProjectCheck"; //$NON-NLS-1$
-    private static final String PAGE_KEYSTORE_SELECTION = "Page_KeystoreSelection"; //$NON-NLS-1$
-    private static final String PAGE_KEY_CREATION = "Page_KeyCreation"; //$NON-NLS-1$
-    private static final String PAGE_KEY_SELECTION = "Page_KeySelection"; //$NON-NLS-1$
-    private static final String PAGE_KEY_CHECK = "Page_KeyCheck"; //$NON-NLS-1$
-    
-    static final String PROPERTY_KEYSTORE = "keystore"; //$NON-NLS-1$
-    static final String PROPERTY_ALIAS = "alias"; //$NON-NLS-1$
-    static final String PROPERTY_DESTINATION = "destination"; //$NON-NLS-1$
-    
-    /**
-     * Base page class for the ExportWizard page. This class add the {@link #onShow()} callback.
-     */
-    static abstract class ExportWizardPage extends WizardPage {
-        
-        /** bit mask constant for project data change event */
-        protected static final int DATA_PROJECT = 0x001;
-        /** bit mask constant for keystore data change event */
-        protected static final int DATA_KEYSTORE = 0x002;
-        /** bit mask constant for key data change event */
-        protected static final int DATA_KEY = 0x004;
-
-        protected static final VerifyListener sPasswordVerifier = new VerifyListener() {
-            public void verifyText(VerifyEvent e) {
-                // verify the characters are valid for password.
-                int len = e.text.length();
-                
-                // first limit to 127 characters max
-                if (len + ((Text)e.getSource()).getText().length() > 127) {
-                    e.doit = false;
-                    return;
-                }
-                
-                // now only take non control characters
-                for (int i = 0 ; i < len ; i++) {
-                    if (e.text.charAt(i) < 32) {
-                        e.doit = false;
-                        return;
-                    }
-                }
-            }
-        };
-        
-        /**
-         * Bit mask indicating what changed while the page was hidden.
-         * @see #DATA_PROJECT
-         * @see #DATA_KEYSTORE
-         * @see #DATA_KEY
-         */
-        protected int mProjectDataChanged = 0;
-        
-        ExportWizardPage(String name) {
-            super(name);
-        }
-        
-        abstract void onShow();
-        
-        @Override
-        public void setVisible(boolean visible) {
-            super.setVisible(visible);
-            if (visible) {
-                onShow();
-                mProjectDataChanged = 0;
-            }
-        }
-        
-        final void projectDataChanged(int changeMask) {
-            mProjectDataChanged |= changeMask;
-        }
-        
-        /**
-         * Calls {@link #setErrorMessage(String)} and {@link #setPageComplete(boolean)} based on a
-         * {@link Throwable} object.
-         */
-        protected final void onException(Throwable t) {
-            String message = getExceptionMessage(t);
-            
-            setErrorMessage(message);
-            setPageComplete(false);
-        }
-    }
-    
-    private ExportWizardPage mPages[] = new ExportWizardPage[5];
-
-    private IProject mProject;
-
-    private String mKeystore;
-    private String mKeystorePassword;
-    private boolean mKeystoreCreationMode;
-
-    private String mKeyAlias;
-    private String mKeyPassword;
-    private int mValidity;
-    private String mDName;
-
-    private PrivateKey mPrivateKey;
-    private X509Certificate mCertificate;
-
-    private String mDestinationPath;
-    private String mApkFilePath;
-    private String mApkFileName;
-
-    private ExportWizardPage mKeystoreSelectionPage;
-    private ExportWizardPage mKeyCreationPage;
-    private ExportWizardPage mKeySelectionPage;
-    private ExportWizardPage mKeyCheckPage;
-
-    private boolean mKeyCreationMode;
-
-    private List<String> mExistingAliases;
-
-    public ExportWizard() {
-        setHelpAvailable(false); // TODO have help
-        setWindowTitle("Export Android Application");
-        setImageDescriptor();
-    }
-    
-    @Override
-    public void addPages() {
-        addPage(mPages[0] = new ProjectCheckPage(this, PAGE_PROJECT_CHECK));
-        addPage(mKeystoreSelectionPage = mPages[1] = new KeystoreSelectionPage(this,
-                PAGE_KEYSTORE_SELECTION));
-        addPage(mKeyCreationPage = mPages[2] = new KeyCreationPage(this, PAGE_KEY_CREATION));
-        addPage(mKeySelectionPage = mPages[3] = new KeySelectionPage(this, PAGE_KEY_SELECTION));
-        addPage(mKeyCheckPage = mPages[4] = new KeyCheckPage(this, PAGE_KEY_CHECK));
-    }
-
-    @Override
-    public boolean performFinish() {
-        // first we make sure export is fine if the destination file already exists
-        File f = new File(mDestinationPath);
-        if (f.isFile()) {
-            if (AdtPlugin.displayPrompt("Export Wizard",
-                    "File already exists. Do you want to overwrite it?") == false) {
-                return false;
-            }
-        }
-        
-        // save the properties
-        ProjectHelper.saveStringProperty(mProject, PROPERTY_KEYSTORE, mKeystore);
-        ProjectHelper.saveStringProperty(mProject, PROPERTY_ALIAS, mKeyAlias);
-        ProjectHelper.saveStringProperty(mProject, PROPERTY_DESTINATION, mDestinationPath);
-        
-        try {
-            if (mKeystoreCreationMode || mKeyCreationMode) {
-                final ArrayList<String> output = new ArrayList<String>();
-                if (KeystoreHelper.createNewStore(
-                        mKeystore,
-                        null /*storeType*/,
-                        mKeystorePassword,
-                        mKeyAlias,
-                        mKeyPassword,
-                        mDName,
-                        mValidity,
-                        new IKeyGenOutput() {
-                            public void err(String message) {
-                                output.add(message);
-                            }
-                            public void out(String message) {
-                                output.add(message);
-                            }
-                        }) == false) {
-                    // keystore creation error!
-                    displayError(output.toArray(new String[output.size()]));
-                    return false;
-                }
-                
-                // keystore is created, now load the private key and certificate.
-                KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType());
-                FileInputStream fis = new FileInputStream(mKeystore);
-                keyStore.load(fis, mKeystorePassword.toCharArray());
-                fis.close();
-                PrivateKeyEntry entry = (KeyStore.PrivateKeyEntry)keyStore.getEntry(
-                        mKeyAlias, new KeyStore.PasswordProtection(mKeyPassword.toCharArray()));
-                
-                if (entry != null) {
-                    mPrivateKey = entry.getPrivateKey();
-                    mCertificate = (X509Certificate)entry.getCertificate();
-                } else {
-                    // this really shouldn't happen since we now let the user choose the key
-                    // from a list read from the store.
-                    displayError("Could not find key");
-                    return false;
-                }
-            }
-            
-            // check the private key/certificate again since it may have been created just above.
-            if (mPrivateKey != null && mCertificate != null) {
-                FileOutputStream fos = new FileOutputStream(mDestinationPath);
-                SignedJarBuilder builder = new SignedJarBuilder(fos, mPrivateKey, mCertificate);
-                
-                // get the input file.
-                FileInputStream fis = new FileInputStream(mApkFilePath);
-                try {
-                    builder.writeZip(fis, null /* filter */);
-                } finally {
-                    fis.close();
-                }
-    
-                builder.close();
-                fos.close();
-                
-                return true;
-            }
-        } catch (FileNotFoundException e) {
-            displayError(e);
-        } catch (NoSuchAlgorithmException e) {
-            displayError(e);
-        } catch (IOException e) {
-            displayError(e);
-        } catch (GeneralSecurityException e) {
-            displayError(e);
-        } catch (KeytoolException e) {
-            displayError(e);
-        }
-
-        return false;
-    }
-    
-    @Override
-    public boolean canFinish() {
-        // check if we have the apk to resign, the destination location, and either
-        // a private key/certificate or the creation mode. In creation mode, unless
-        // all the key/keystore info is valid, the user cannot reach the last page, so there's
-        // no need to check them again here.
-        return mApkFilePath != null &&
-                ((mPrivateKey != null && mCertificate != null)
-                        || mKeystoreCreationMode || mKeyCreationMode) &&
-                mDestinationPath != null;
-    }
-    
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection)
-     */
-    public void init(IWorkbench workbench, IStructuredSelection selection) {
-        // get the project from the selection
-        Object selected = selection.getFirstElement();
-        
-        if (selected instanceof IProject) {
-            mProject = (IProject)selected;
-        } else if (selected instanceof IAdaptable) {
-            IResource r = (IResource)((IAdaptable)selected).getAdapter(IResource.class);
-            if (r != null) {
-                mProject = r.getProject();
-            }
-        }
-    }
-    
-    ExportWizardPage getKeystoreSelectionPage() {
-        return mKeystoreSelectionPage;
-    }
-    
-    ExportWizardPage getKeyCreationPage() {
-        return mKeyCreationPage;
-    }
-    
-    ExportWizardPage getKeySelectionPage() {
-        return mKeySelectionPage;
-    }
-    
-    ExportWizardPage getKeyCheckPage() {
-        return mKeyCheckPage;
-    }
-
-    /**
-     * Returns an image descriptor for the wizard logo.
-     */
-    private void setImageDescriptor() {
-        ImageDescriptor desc = AdtPlugin.getImageDescriptor(PROJECT_LOGO_LARGE);
-        setDefaultPageImageDescriptor(desc);
-    }
-    
-    IProject getProject() {
-        return mProject;
-    }
-    
-    void setProject(IProject project, String apkFilePath, String filename) {
-        mProject = project;
-        mApkFilePath = apkFilePath;
-        mApkFileName = filename;
-        
-        updatePageOnChange(ExportWizardPage.DATA_PROJECT);
-    }
-    
-    String getApkFilename() {
-        return mApkFileName;
-    }
-    
-    void setKeystore(String path) {
-        mKeystore = path;
-        mPrivateKey = null;
-        mCertificate = null;
-        
-        updatePageOnChange(ExportWizardPage.DATA_KEYSTORE);
-    }
-    
-    String getKeystore() {
-        return mKeystore;
-    }
-    
-    void setKeystoreCreationMode(boolean createStore) {
-        mKeystoreCreationMode = createStore;
-        updatePageOnChange(ExportWizardPage.DATA_KEYSTORE);
-    }
-    
-    boolean getKeystoreCreationMode() {
-        return mKeystoreCreationMode;
-    }
-    
-    
-    void setKeystorePassword(String password) {
-        mKeystorePassword = password;
-        mPrivateKey = null;
-        mCertificate = null;
-
-        updatePageOnChange(ExportWizardPage.DATA_KEYSTORE);
-    }
-    
-    String getKeystorePassword() {
-        return mKeystorePassword;
-    }
-
-    void setKeyCreationMode(boolean createKey) {
-        mKeyCreationMode = createKey;
-        updatePageOnChange(ExportWizardPage.DATA_KEY);
-    }
-    
-    boolean getKeyCreationMode() {
-        return mKeyCreationMode;
-    }
-    
-    void setExistingAliases(List<String> aliases) {
-        mExistingAliases = aliases;
-    }
-    
-    List<String> getExistingAliases() {
-        return mExistingAliases;
-    }
-
-    void setKeyAlias(String name) {
-        mKeyAlias = name;
-        mPrivateKey = null;
-        mCertificate = null;
-
-        updatePageOnChange(ExportWizardPage.DATA_KEY);
-    }
-    
-    String getKeyAlias() {
-        return mKeyAlias;
-    }
-
-    void setKeyPassword(String password) {
-        mKeyPassword = password;
-        mPrivateKey = null;
-        mCertificate = null;
-
-        updatePageOnChange(ExportWizardPage.DATA_KEY);
-    }
-    
-    String getKeyPassword() {
-        return mKeyPassword;
-    }
-
-    void setValidity(int validity) {
-        mValidity = validity;
-        updatePageOnChange(ExportWizardPage.DATA_KEY);
-    }
-    
-    int getValidity() {
-        return mValidity;
-    }
-
-    void setDName(String dName) {
-        mDName = dName;
-        updatePageOnChange(ExportWizardPage.DATA_KEY);
-    }
-    
-    String getDName() {
-        return mDName;
-    }
-
-    void setSigningInfo(PrivateKey privateKey, X509Certificate certificate) {
-        mPrivateKey = privateKey;
-        mCertificate = certificate;
-    }
-
-    void setDestination(String path) {
-        mDestinationPath = path;
-    }
-    
-    void updatePageOnChange(int changeMask) {
-        for (ExportWizardPage page : mPages) {
-            page.projectDataChanged(changeMask);
-        }
-    }
-    
-    private void displayError(String... messages) {
-        String message = null;
-        if (messages.length == 1) {
-            message = messages[0];
-        } else {
-            StringBuilder sb = new StringBuilder(messages[0]);
-            for (int i = 1;  i < messages.length; i++) {
-                sb.append('\n');
-                sb.append(messages[i]);
-            }
-            
-            message = sb.toString();
-        }
-
-        AdtPlugin.displayError("Export Wizard", message);
-    }
-    
-    private void displayError(Exception e) {
-        String message = getExceptionMessage(e);
-        displayError(message);
-        
-        AdtPlugin.log(e, "Export Wizard Error");
-    }
-    
-    /**
-     * Returns the {@link Throwable#getMessage()}. If the {@link Throwable#getMessage()} returns
-     * <code>null</code>, the method is called again on the cause of the Throwable object.
-     * <p/>If no Throwable in the chain has a valid message, the canonical name of the first
-     * exception is returned.
-     */
-    private static String getExceptionMessage(Throwable t) {
-        String message = t.getMessage();
-        if (message == null) {
-            Throwable cause = t.getCause();
-            if (cause != null) {
-                return getExceptionMessage(cause);
-            }
-
-            // no more cause and still no message. display the first exception.
-            return t.getClass().getCanonicalName();
-        }
-        
-        return message;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCheckPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCheckPage.java
deleted file mode 100644
index c64bf10..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCheckPage.java
+++ /dev/null
@@ -1,291 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard.ExportWizardPage;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.widgets.FormText;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.security.KeyStore;
-import java.security.KeyStoreException;
-import java.security.NoSuchAlgorithmException;
-import java.security.PrivateKey;
-import java.security.UnrecoverableEntryException;
-import java.security.KeyStore.PrivateKeyEntry;
-import java.security.cert.CertificateException;
-import java.security.cert.X509Certificate;
-import java.util.Calendar;
-
-/**
- * Final page of the wizard that checks the key and ask for the ouput location.
- */
-final class KeyCheckPage extends ExportWizardPage {
-
-    private final ExportWizard mWizard;
-    private PrivateKey mPrivateKey;
-    private X509Certificate mCertificate;
-    private Text mDestination;
-    private boolean mFatalSigningError;
-    private FormText mDetailText;
-
-    protected KeyCheckPage(ExportWizard wizard, String pageName) {
-        super(pageName);
-        mWizard = wizard;
-        
-        setTitle("Destination and key/certificate checks");
-        setDescription(""); // TODO
-    }
-
-    public void createControl(Composite parent) {
-        setErrorMessage(null);
-        setMessage(null);
-
-        // build the ui.
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        GridLayout gl = new GridLayout(3, false);
-        gl.verticalSpacing *= 3;
-        composite.setLayout(gl);
-        
-        GridData gd;
-
-        new Label(composite, SWT.NONE).setText("Destination APK file:");
-        mDestination = new Text(composite, SWT.BORDER);
-        mDestination.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mDestination.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onDestinationChange();
-            }
-        });
-        final Button browseButton = new Button(composite, SWT.PUSH);
-        browseButton.setText("Browse...");
-        browseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                FileDialog fileDialog = new FileDialog(browseButton.getShell(), SWT.SAVE);
-                
-                fileDialog.setText("Destination file name");
-                fileDialog.setFileName(mWizard.getApkFilename());
-        
-                String saveLocation = fileDialog.open();
-                if (saveLocation != null) {
-                    mDestination.setText(saveLocation);
-                }
-            }
-        });
-        
-        mDetailText = new FormText(composite, SWT.NONE);
-        mDetailText.setLayoutData(gd = new GridData(GridData.FILL_BOTH));
-        gd.horizontalSpan = 3;
-        
-        setControl(composite);
-    }
-    
-    @Override
-    void onShow() {
-        // fill the texts with information loaded from the project.
-        if ((mProjectDataChanged & DATA_PROJECT) != 0) {
-            // reset the destination from the content of the project
-            IProject project = mWizard.getProject();
-            
-            String destination = ProjectHelper.loadStringProperty(project,
-                    ExportWizard.PROPERTY_DESTINATION);
-            if (destination != null) {
-                mDestination.setText(destination);
-            }
-        }
-        
-        // if anything change we basically reload the data.
-        if (mProjectDataChanged != 0) {
-            mFatalSigningError = false;
-
-            // reset the wizard with no key/cert to make it not finishable, unless a valid
-            // key/cert is found.
-            mWizard.setSigningInfo(null, null);
-    
-            if (mWizard.getKeystoreCreationMode() || mWizard.getKeyCreationMode()) {
-                int validity = mWizard.getValidity();
-                StringBuilder sb = new StringBuilder(
-                        String.format("<form><p>Certificate expires in %d years.</p>",
-                        validity));
-
-                if (validity < 25) {
-                    sb.append("<p>Make sure the certificate is valid for the planned lifetime of the product.</p>");
-                    sb.append("<p>If the certificate expires, you will be forced to sign your application with a different one.</p>");
-                    sb.append("<p>Applications cannot be upgraded if their certificate changes from one version to another, ");
-                    sb.append("forcing a full uninstall/install, which will make the user lose his/her data.</p>");
-                    sb.append("<p>Android Market currently requires certificates to be valid until 2033.</p>");
-                }
-
-                sb.append("</form>");
-                mDetailText.setText(sb.toString(), true /* parseTags */, true /* expandURLs */);
-            } else {
-                try {
-                    KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType());
-                    FileInputStream fis = new FileInputStream(mWizard.getKeystore());
-                    keyStore.load(fis, mWizard.getKeystorePassword().toCharArray());
-                    fis.close();
-                    PrivateKeyEntry entry = (KeyStore.PrivateKeyEntry)keyStore.getEntry(
-                            mWizard.getKeyAlias(),
-                            new KeyStore.PasswordProtection(
-                                    mWizard.getKeyPassword().toCharArray()));
-                    
-                    if (entry != null) {
-                        mPrivateKey = entry.getPrivateKey();
-                        mCertificate = (X509Certificate)entry.getCertificate();
-                    } else {
-                        setErrorMessage("Unable to find key.");
-                        
-                        setPageComplete(false);
-                    }
-                } catch (FileNotFoundException e) {
-                    // this was checked at the first previous step and will not happen here, unless
-                    // the file was removed during the export wizard execution.
-                    onException(e);
-                } catch (KeyStoreException e) {
-                    onException(e);
-                } catch (NoSuchAlgorithmException e) {
-                    onException(e);
-                } catch (UnrecoverableEntryException e) {
-                    onException(e);
-                } catch (CertificateException e) {
-                    onException(e);
-                } catch (IOException e) {
-                    onException(e);
-                }
-                
-                if (mPrivateKey != null && mCertificate != null) {
-                    Calendar expirationCalendar = Calendar.getInstance();
-                    expirationCalendar.setTime(mCertificate.getNotAfter());
-                    Calendar today = Calendar.getInstance();
-                    
-                    if (expirationCalendar.before(today)) {
-                        mDetailText.setText(String.format(
-                                "<form><p>Certificate expired on %s</p></form>",
-                                mCertificate.getNotAfter().toString()),
-                                true /* parseTags */, true /* expandURLs */);
-                        
-                        // fatal error = nothing can make the page complete.
-                        mFatalSigningError = true;
-        
-                        setErrorMessage("Certificate is expired.");
-                        setPageComplete(false);
-                    } else {
-                        // valid, key/cert: put it in the wizard so that it can be finished
-                        mWizard.setSigningInfo(mPrivateKey, mCertificate);
-        
-                        StringBuilder sb = new StringBuilder(String.format(
-                                "<form><p>Certificate expires on %s.</p>",
-                                mCertificate.getNotAfter().toString()));
-                        
-                        int expirationYear = expirationCalendar.get(Calendar.YEAR);
-                        int thisYear = today.get(Calendar.YEAR);
-                        
-                        if (thisYear + 25 < expirationYear) {
-                            // do nothing
-                        } else {
-                            if (expirationYear == thisYear) {
-                                sb.append("<p>The certificate expires this year.</p>");
-                            } else {
-                                int count = expirationYear-thisYear;
-                                sb.append(String.format(
-                                        "<p>The Certificate expires in %1$s %2$s.</p>",
-                                        count, count == 1 ? "year" : "years"));
-                            }
-                            
-                            sb.append("<p>Make sure the certificate is valid for the planned lifetime of the product.</p>");
-                            sb.append("<p>If the certificate expires, you will be forced to sign your application with a different one.</p>");
-                            sb.append("<p>Applications cannot be upgraded if their certificate changes from one version to another, ");
-                            sb.append("forcing a full uninstall/install, which will make the user lose his/her data.</p>");
-                            sb.append("<p>Android Market currently requires certificates to be valid until 2033.</p>");
-                        }
-                        
-                        sb.append("</form>");
-        
-                        mDetailText.setText(sb.toString(), true /* parseTags */, true /* expandURLs */);
-                    }
-                    mDetailText.getParent().layout();
-                } else {
-                    // fatal error = nothing can make the page complete.
-                    mFatalSigningError = true;
-                }
-            }
-        }
-
-        onDestinationChange();
-    }
-    
-    private void onDestinationChange() {
-        if (mFatalSigningError == false) {
-            // reset messages for now.
-            setErrorMessage(null);
-            setMessage(null);
-
-            String path = mDestination.getText().trim();
-
-            if (path.length() == 0) {
-                setErrorMessage("Enter destination for the APK file.");
-                mWizard.setDestination(null); // this is to reset canFinish in the wizard
-                setPageComplete(false);
-                return;
-            }
-
-            File file = new File(path);
-            if (file.isDirectory()) {
-                setErrorMessage("Destination is a directory.");
-                mWizard.setDestination(null); // this is to reset canFinish in the wizard
-                setPageComplete(false);
-                return;
-            }
-
-            File parentFile = file.getParentFile();
-            if (parentFile == null || parentFile.isDirectory() == false) {
-                setErrorMessage("Not a valid directory.");
-                mWizard.setDestination(null); // this is to reset canFinish in the wizard
-                setPageComplete(false);
-                return;
-            }
-
-            // no error, set the destination in the wizard.
-            mWizard.setDestination(path);
-            setPageComplete(true);
-            
-            // However, we should also test if the file already exists.
-            if (file.isFile()) {
-                setMessage("Destination file already exists.", WARNING);
-            }
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCreationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCreationPage.java
deleted file mode 100644
index d7365f7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeyCreationPage.java
+++ /dev/null
@@ -1,332 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard.ExportWizardPage;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.List;
-
-/**
- * Key creation page. 
- */
-final class KeyCreationPage extends ExportWizardPage {
-
-    private final ExportWizard mWizard;
-    private Text mAlias;
-    private Text mKeyPassword;
-    private Text mKeyPassword2;
-    private Text mCnField;
-    private boolean mDisableOnChange = false;
-    private Text mOuField;
-    private Text mOField;
-    private Text mLField;
-    private Text mStField;
-    private Text mCField;
-    private String mDName;
-    private int mValidity = 0;
-    private List<String> mExistingAliases;
-
-    
-    protected KeyCreationPage(ExportWizard wizard, String pageName) {
-        super(pageName);
-        mWizard = wizard;
-
-        setTitle("Key Creation");
-        setDescription(""); // TODO?
-    }
-
-    public void createControl(Composite parent) {
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        GridLayout gl = new GridLayout(2, false);
-        composite.setLayout(gl);
-        
-        GridData gd;
-
-        new Label(composite, SWT.NONE).setText("Alias:");
-        mAlias = new Text(composite, SWT.BORDER);
-        mAlias.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        new Label(composite, SWT.NONE).setText("Password:");
-        mKeyPassword = new Text(composite, SWT.BORDER | SWT.PASSWORD);
-        mKeyPassword.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mKeyPassword.addVerifyListener(sPasswordVerifier);
-
-        new Label(composite, SWT.NONE).setText("Confirm:");
-        mKeyPassword2 = new Text(composite, SWT.BORDER | SWT.PASSWORD);
-        mKeyPassword2.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mKeyPassword2.addVerifyListener(sPasswordVerifier);
-
-        new Label(composite, SWT.NONE).setText("Validity (years):");
-        final Text validityText = new Text(composite, SWT.BORDER);
-        validityText.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        validityText.addVerifyListener(new VerifyListener() {
-            public void verifyText(VerifyEvent e) {
-                // check for digit only.
-                for (int i = 0 ; i < e.text.length(); i++) {
-                    char letter = e.text.charAt(i);
-                    if (letter < '0' || letter > '9') {
-                        e.doit = false;
-                        return;
-                    }
-                }
-            }
-        });
-
-        new Label(composite, SWT.SEPARATOR | SWT.HORIZONTAL).setLayoutData(
-                gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 2;
-        
-        new Label(composite, SWT.NONE).setText("First and Last Name:");
-        mCnField = new Text(composite, SWT.BORDER);
-        mCnField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        new Label(composite, SWT.NONE).setText("Organizational Unit:");
-        mOuField = new Text(composite, SWT.BORDER);
-        mOuField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        new Label(composite, SWT.NONE).setText("Organization:");
-        mOField = new Text(composite, SWT.BORDER);
-        mOField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        new Label(composite, SWT.NONE).setText("City or Locality:");
-        mLField = new Text(composite, SWT.BORDER);
-        mLField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        new Label(composite, SWT.NONE).setText("State or Province:");
-        mStField = new Text(composite, SWT.BORDER);
-        mStField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        
-        new Label(composite, SWT.NONE).setText("Country Code (XX):");
-        mCField = new Text(composite, SWT.BORDER);
-        mCField.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setControl(composite);
-        
-        mAlias.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mWizard.setKeyAlias(mAlias.getText().trim());
-                onChange();
-            }
-        });
-        mKeyPassword.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mWizard.setKeyPassword(mKeyPassword.getText());
-                onChange();
-            }
-        });
-        mKeyPassword2.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onChange();
-            }
-        });
-        
-        validityText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                try {
-                    mValidity = Integer.parseInt(validityText.getText());
-                } catch (NumberFormatException e2) {
-                    // this should only happen if the text field is empty due to the verifyListener.
-                    mValidity = 0;
-                }
-                mWizard.setValidity(mValidity);
-                onChange();
-            }
-        });
-
-        ModifyListener dNameListener = new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onDNameChange();
-            }
-        };
-        
-        mCnField.addModifyListener(dNameListener);
-        mOuField.addModifyListener(dNameListener);
-        mOField.addModifyListener(dNameListener);
-        mLField.addModifyListener(dNameListener);
-        mStField.addModifyListener(dNameListener);
-        mCField.addModifyListener(dNameListener);
-    }
-    
-    @Override
-    void onShow() {
-        // fill the texts with information loaded from the project.
-        if ((mProjectDataChanged & (DATA_PROJECT | DATA_KEYSTORE)) != 0) {
-            // reset the keystore/alias from the content of the project
-            IProject project = mWizard.getProject();
-            
-            // disable onChange for now. we'll call it once at the end.
-            mDisableOnChange = true;
-            
-            String alias = ProjectHelper.loadStringProperty(project, ExportWizard.PROPERTY_ALIAS);
-            if (alias != null) {
-                mAlias.setText(alias);
-            }
-            
-            // get the existing list of keys if applicable
-            if (mWizard.getKeyCreationMode()) {
-                mExistingAliases = mWizard.getExistingAliases();
-            } else {
-                mExistingAliases = null;
-            }
-            
-            // reset the passwords
-            mKeyPassword.setText(""); //$NON-NLS-1$
-            mKeyPassword2.setText(""); //$NON-NLS-1$
-            
-            // enable onChange, and call it to display errors and enable/disable pageCompleted.
-            mDisableOnChange = false;
-            onChange();
-        }
-    }
-
-    @Override
-    public IWizardPage getPreviousPage() {
-        if (mWizard.getKeyCreationMode()) { // this means we create a key from an existing store
-            return mWizard.getKeySelectionPage();
-        }
-        
-        return mWizard.getKeystoreSelectionPage();
-    }
-
-    @Override
-    public IWizardPage getNextPage() {
-        return mWizard.getKeyCheckPage();
-    }
-
-    /**
-     * Handles changes and update the error message and calls {@link #setPageComplete(boolean)}.
-     */
-    private void onChange() {
-        if (mDisableOnChange) {
-            return;
-        }
-
-        setErrorMessage(null);
-        setMessage(null);
-
-        if (mAlias.getText().trim().length() == 0) {
-            setErrorMessage("Enter key alias.");
-            setPageComplete(false);
-            return;
-        } else if (mExistingAliases != null) {
-            // we cannot use indexOf, because we need to do a case-insensitive check
-            String keyAlias = mAlias.getText().trim();
-            for (String alias : mExistingAliases) {
-                if (alias.equalsIgnoreCase(keyAlias)) {
-                    setErrorMessage("Key alias already exists in keystore.");
-                    setPageComplete(false);
-                    return;
-                }
-            }
-        }
-
-        String value = mKeyPassword.getText();
-        if (value.length() == 0) {
-            setErrorMessage("Enter key password.");
-            setPageComplete(false);
-            return;
-        } else if (value.length() < 6) {
-            setErrorMessage("Key password is too short - must be at least 6 characters.");
-            setPageComplete(false);
-            return;
-        }
-
-        if (value.equals(mKeyPassword2.getText()) == false) {
-            setErrorMessage("Key passwords don't match.");
-            setPageComplete(false);
-            return;
-        }
-
-        if (mValidity == 0) {
-            setErrorMessage("Key certificate validity is required.");
-            setPageComplete(false);
-            return;
-        } else if (mValidity < 25) {
-            setMessage("A 25 year certificate validity is recommended.", WARNING);
-        } else if (mValidity > 1000) {
-            setErrorMessage("Key certificate validity must be between 1 and 1000 years.");
-            setPageComplete(false);
-            return;
-        }
-
-        if (mDName == null || mDName.length() == 0) {
-            setErrorMessage("At least one Certificate issuer field is required to be non-empty.");
-            setPageComplete(false);
-            return;
-        }
-
-        setPageComplete(true);
-    }
-    
-    /**
-     * Handles changes in the DName fields.
-     */
-    private void onDNameChange() {
-        StringBuilder sb = new StringBuilder();
-        
-        buildDName("CN", mCnField, sb);
-        buildDName("OU", mOuField, sb);
-        buildDName("O", mOField, sb);
-        buildDName("L", mLField, sb);
-        buildDName("ST", mStField, sb);
-        buildDName("C", mCField, sb);
-        
-        mDName = sb.toString();
-        mWizard.setDName(mDName);
-
-        onChange();
-    }
-    
-    /**
-     * Builds the distinguished name string with the provided {@link StringBuilder}.
-     * @param prefix the prefix of the entry.
-     * @param textField The {@link Text} field containing the entry value.
-     * @param sb the string builder containing the dname.
-     */
-    private void buildDName(String prefix, Text textField, StringBuilder sb) {
-        if (textField != null) {
-            String value = textField.getText().trim();
-            if (value.length() > 0) {
-                if (sb.length() > 0) {
-                    sb.append(",");
-                }
-                
-                sb.append(prefix);
-                sb.append('=');
-                sb.append(value);
-            }
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeySelectionPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeySelectionPage.java
deleted file mode 100644
index 2fcd757..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeySelectionPage.java
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard.ExportWizardPage;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.security.KeyStore;
-import java.security.KeyStoreException;
-import java.security.NoSuchAlgorithmException;
-import java.security.cert.CertificateException;
-import java.util.ArrayList;
-import java.util.Enumeration;
-
-/**
- * Key Selection Page. This is used when an existing keystore is used. 
- */
-final class KeySelectionPage extends ExportWizardPage {
-
-    private final ExportWizard mWizard;
-    private Label mKeyAliasesLabel;
-    private Combo mKeyAliases;
-    private Label mKeyPasswordLabel;
-    private Text mKeyPassword;
-    private boolean mDisableOnChange = false;
-    private Button mUseExistingKey;
-    private Button mCreateKey;
-
-    protected KeySelectionPage(ExportWizard wizard, String pageName) {
-        super(pageName);
-        mWizard = wizard;
-
-        setTitle("Key alias selection");
-        setDescription(""); // TODO
-    }
-
-    public void createControl(Composite parent) {
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        GridLayout gl = new GridLayout(3, false);
-        composite.setLayout(gl);
-
-        GridData gd;
-
-        mUseExistingKey = new Button(composite, SWT.RADIO);
-        mUseExistingKey.setText("Use existing key");
-        mUseExistingKey.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 3;
-        mUseExistingKey.setSelection(true);
-
-        new Composite(composite, SWT.NONE).setLayoutData(gd = new GridData());
-        gd.heightHint = 0;
-        gd.widthHint = 50;
-        mKeyAliasesLabel = new Label(composite, SWT.NONE);
-        mKeyAliasesLabel.setText("Alias:");
-        mKeyAliases = new Combo(composite, SWT.READ_ONLY);
-        mKeyAliases.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        new Composite(composite, SWT.NONE).setLayoutData(gd = new GridData());
-        gd.heightHint = 0;
-        gd.widthHint = 50;
-        mKeyPasswordLabel = new Label(composite, SWT.NONE);
-        mKeyPasswordLabel.setText("Password:");
-        mKeyPassword = new Text(composite, SWT.BORDER | SWT.PASSWORD);
-        mKeyPassword.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        mCreateKey = new Button(composite, SWT.RADIO);
-        mCreateKey.setText("Create new key");
-        mCreateKey.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 3;
-
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setControl(composite);
-        
-        mUseExistingKey.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mWizard.setKeyCreationMode(!mUseExistingKey.getSelection());
-                enableWidgets();
-                onChange();
-            }
-        });
-        
-        mKeyAliases.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                mWizard.setKeyAlias(mKeyAliases.getItem(mKeyAliases.getSelectionIndex()));
-                onChange();
-            }
-        });
-        
-        mKeyPassword.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mWizard.setKeyPassword(mKeyPassword.getText());
-                onChange();
-            }
-        });
-    }
-    
-    @Override
-    void onShow() {
-        // fill the texts with information loaded from the project.
-        if ((mProjectDataChanged & (DATA_PROJECT | DATA_KEYSTORE)) != 0) {
-            // disable onChange for now. we'll call it once at the end.
-            mDisableOnChange = true;
-
-            // reset the alias from the content of the project
-            try {
-                // reset to using a key
-                mWizard.setKeyCreationMode(false);
-                mUseExistingKey.setSelection(true);
-                mCreateKey.setSelection(false);
-                enableWidgets();
-
-                // remove the content of the alias combo always and first, in case the
-                // keystore password is wrong
-                mKeyAliases.removeAll();
-
-                // get the alias list (also used as a keystore password test)
-                KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType());
-                FileInputStream fis = new FileInputStream(mWizard.getKeystore());
-                keyStore.load(fis, mWizard.getKeystorePassword().toCharArray());
-                fis.close();
-                
-                Enumeration<String> aliases = keyStore.aliases();
-
-                // get the alias from the project previous export, and look for a match as
-                // we add the aliases to the combo.
-                IProject project = mWizard.getProject();
-
-                String keyAlias = ProjectHelper.loadStringProperty(project,
-                        ExportWizard.PROPERTY_ALIAS);
-                
-                ArrayList<String> aliasList = new ArrayList<String>();
-
-                int selection = -1;
-                int count = 0;
-                while (aliases.hasMoreElements()) {
-                    String alias = aliases.nextElement();
-                    mKeyAliases.add(alias);
-                    aliasList.add(alias);
-                    if (selection == -1 && alias.equalsIgnoreCase(keyAlias)) {
-                        selection = count;
-                    }
-                    count++;
-                }
-                
-                mWizard.setExistingAliases(aliasList);
-
-                if (selection != -1) {
-                    mKeyAliases.select(selection);
-
-                    // since a match was found and is selected, we need to give it to
-                    // the wizard as well
-                    mWizard.setKeyAlias(keyAlias);
-                } else {
-                    mKeyAliases.clearSelection();
-                }
-
-                // reset the password
-                mKeyPassword.setText(""); //$NON-NLS-1$
-
-                // enable onChange, and call it to display errors and enable/disable pageCompleted.
-                mDisableOnChange = false;
-                onChange();
-            } catch (KeyStoreException e) {
-                onException(e);
-            } catch (FileNotFoundException e) {
-                onException(e);
-            } catch (NoSuchAlgorithmException e) {
-                onException(e);
-            } catch (CertificateException e) {
-                onException(e);
-            } catch (IOException e) {
-                onException(e);
-            } finally {
-                // in case we exit with an exception, we need to reset this
-                mDisableOnChange = false;
-            }
-        }
-    }
-    
-    @Override
-    public IWizardPage getPreviousPage() {
-        return mWizard.getKeystoreSelectionPage();
-    }
-
-    @Override
-    public IWizardPage getNextPage() {
-        if (mWizard.getKeyCreationMode()) {
-            return mWizard.getKeyCreationPage();
-        }
-        
-        return mWizard.getKeyCheckPage();
-    }
-
-    /**
-     * Handles changes and update the error message and calls {@link #setPageComplete(boolean)}.
-     */
-    private void onChange() {
-        if (mDisableOnChange) {
-            return;
-        }
-
-        setErrorMessage(null);
-        setMessage(null);
-
-        if (mWizard.getKeyCreationMode() == false) {
-            if (mKeyAliases.getSelectionIndex() == -1) {
-                setErrorMessage("Select a key alias.");
-                setPageComplete(false);
-                return;
-            }
-    
-            if (mKeyPassword.getText().trim().length() == 0) {
-                setErrorMessage("Enter key password.");
-                setPageComplete(false);
-                return;
-            }
-        }
-
-        setPageComplete(true);
-    }
-    
-    private void enableWidgets() {
-        boolean useKey = !mWizard.getKeyCreationMode();
-        mKeyAliasesLabel.setEnabled(useKey);
-        mKeyAliases.setEnabled(useKey);
-        mKeyPassword.setEnabled(useKey);
-        mKeyPasswordLabel.setEnabled(useKey);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeystoreSelectionPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeystoreSelectionPage.java
deleted file mode 100644
index c5a4d47..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/KeystoreSelectionPage.java
+++ /dev/null
@@ -1,260 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard.ExportWizardPage;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.File;
-
-/**
- * Keystore selection page. This page allows to choose to create a new keystore or use an
- * existing one. 
- */
-final class KeystoreSelectionPage extends ExportWizardPage {
-
-    private final ExportWizard mWizard;
-    private Button mUseExistingKeystore;
-    private Button mCreateKeystore;
-    private Text mKeystore;
-    private Text mKeystorePassword;
-    private Label mConfirmLabel;
-    private Text mKeystorePassword2;
-    private boolean mDisableOnChange = false;
-
-    protected KeystoreSelectionPage(ExportWizard wizard, String pageName) {
-        super(pageName);
-        mWizard = wizard;
-
-        setTitle("Keystore selection");
-        setDescription(""); //TODO
-    }
-
-    public void createControl(Composite parent) {
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        GridLayout gl = new GridLayout(3, false);
-        composite.setLayout(gl);
-        
-        GridData gd;
-        
-        mUseExistingKeystore = new Button(composite, SWT.RADIO);
-        mUseExistingKeystore.setText("Use existing keystore");
-        mUseExistingKeystore.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 3;
-        mUseExistingKeystore.setSelection(true);
-
-        mCreateKeystore = new Button(composite, SWT.RADIO);
-        mCreateKeystore.setText("Create new keystore");
-        mCreateKeystore.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 3;
-
-        new Label(composite, SWT.NONE).setText("Location:");
-        mKeystore = new Text(composite, SWT.BORDER);
-        mKeystore.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        final Button browseButton = new Button(composite, SWT.PUSH);
-        browseButton.setText("Browse...");
-        browseButton.addSelectionListener(new SelectionAdapter() {
-           @Override
-           public void widgetSelected(SelectionEvent e) {
-               FileDialog fileDialog;
-               if (mUseExistingKeystore.getSelection()) {
-                   fileDialog = new FileDialog(browseButton.getShell(),SWT.OPEN);
-                   fileDialog.setText("Load Keystore");
-               } else {
-                   fileDialog = new FileDialog(browseButton.getShell(),SWT.SAVE);
-                   fileDialog.setText("Select Keystore Name");
-               }
-
-               String fileName = fileDialog.open();
-               if (fileName != null) {
-                   mKeystore.setText(fileName);
-               }
-           }
-        });
-
-        new Label(composite, SWT.NONE).setText("Password:");
-        mKeystorePassword = new Text(composite, SWT.BORDER | SWT.PASSWORD);
-        mKeystorePassword.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mKeystorePassword.addVerifyListener(sPasswordVerifier);
-        new Composite(composite, SWT.NONE).setLayoutData(gd = new GridData());
-        gd.heightHint = gd.widthHint = 0;
-
-        mConfirmLabel = new Label(composite, SWT.NONE);
-        mConfirmLabel.setText("Confirm:");
-        mKeystorePassword2 = new Text(composite, SWT.BORDER | SWT.PASSWORD);
-        mKeystorePassword2.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mKeystorePassword2.addVerifyListener(sPasswordVerifier);
-        new Composite(composite, SWT.NONE).setLayoutData(gd = new GridData());
-        gd.heightHint = gd.widthHint = 0;
-        mKeystorePassword2.setEnabled(false);
-
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setControl(composite);
-        
-        mUseExistingKeystore.addSelectionListener(new SelectionAdapter() {
-           @Override
-           public void widgetSelected(SelectionEvent e) {
-               boolean createStore = !mUseExistingKeystore.getSelection();
-               mKeystorePassword2.setEnabled(createStore);
-               mConfirmLabel.setEnabled(createStore);
-               mWizard.setKeystoreCreationMode(createStore);
-               onChange();
-            }
-        });
-        
-        mKeystore.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mWizard.setKeystore(mKeystore.getText().trim());
-                onChange();
-            }
-        });
-
-        mKeystorePassword.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                mWizard.setKeystorePassword(mKeystorePassword.getText());
-                onChange();
-            }
-        });
-
-        mKeystorePassword2.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onChange();
-            }
-        });
-    }
-    
-    @Override
-    public IWizardPage getNextPage() {
-        if (mUseExistingKeystore.getSelection()) {
-            return mWizard.getKeySelectionPage();
-        }
-        
-        return mWizard.getKeyCreationPage();
-    }
-    
-    @Override
-    void onShow() {
-        // fill the texts with information loaded from the project.
-        if ((mProjectDataChanged & DATA_PROJECT) != 0) {
-            // reset the keystore/alias from the content of the project
-            IProject project = mWizard.getProject();
-            
-            // disable onChange for now. we'll call it once at the end.
-            mDisableOnChange = true;
-            
-            String keystore = ProjectHelper.loadStringProperty(project,
-                    ExportWizard.PROPERTY_KEYSTORE);
-            if (keystore != null) {
-                mKeystore.setText(keystore);
-            }
-            
-            // reset the passwords
-            mKeystorePassword.setText(""); //$NON-NLS-1$
-            mKeystorePassword2.setText(""); //$NON-NLS-1$
-            
-            // enable onChange, and call it to display errors and enable/disable pageCompleted.
-            mDisableOnChange = false;
-            onChange();
-        }
-    }
-
-    /**
-     * Handles changes and update the error message and calls {@link #setPageComplete(boolean)}.
-     */
-    private void onChange() {
-        if (mDisableOnChange) {
-            return;
-        }
-
-        setErrorMessage(null);
-        setMessage(null);
-
-        boolean createStore = !mUseExistingKeystore.getSelection();
-
-        // checks the keystore path is non null.
-        String keystore = mKeystore.getText().trim();
-        if (keystore.length() == 0) {
-            setErrorMessage("Enter path to keystore.");
-            setPageComplete(false);
-            return;
-        } else {
-            File f = new File(keystore);
-            if (f.exists() == false) {
-                if (createStore == false) {
-                    setErrorMessage("Keystore does not exist.");
-                    setPageComplete(false);
-                    return;
-                }
-            } else if (f.isDirectory()) {
-                setErrorMessage("Keystore path is a directory.");
-                setPageComplete(false);
-                return;
-            } else if (f.isFile()) {
-                if (createStore) {
-                    setErrorMessage("File already exists.");
-                    setPageComplete(false);
-                    return;
-                }
-            }
-        }
-        
-        String value = mKeystorePassword.getText();
-        if (value.length() == 0) {
-            setErrorMessage("Enter keystore password.");
-            setPageComplete(false);
-            return;
-        } else if (createStore && value.length() < 6) {
-            setErrorMessage("Keystore password is too short - must be at least 6 characters.");
-            setPageComplete(false);
-            return;
-        }
-
-        if (createStore) {
-            if (mKeystorePassword2.getText().length() == 0) {
-                setErrorMessage("Confirm keystore password.");
-                setPageComplete(false);
-                return;
-            }
-            
-            if (mKeystorePassword.getText().equals(mKeystorePassword2.getText()) == false) {
-                setErrorMessage("Keystore passwords do not match.");
-                setPageComplete(false);
-                return;
-            }
-        }
-
-        setPageComplete(true);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ProjectCheckPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ProjectCheckPage.java
deleted file mode 100644
index e161e18..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/export/ProjectCheckPage.java
+++ /dev/null
@@ -1,322 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.export;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.project.export.ExportWizard.ExportWizardPage;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestParser;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.common.project.ProjectChooserHelper;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.File;
-
-/**
- * First Export Wizard Page. Display warning/errors. 
- */
-final class ProjectCheckPage extends ExportWizardPage {
-    private final static String IMG_ERROR = "error.png"; //$NON-NLS-1$
-    private final static String IMG_WARNING = "warning.png"; //$NON-NLS-1$
-
-    private final ExportWizard mWizard;
-    private Display mDisplay;
-    private Image mError;
-    private Image mWarning;
-    private boolean mHasMessage = false;
-    private Composite mTopComposite;
-    private Composite mErrorComposite;
-    private Text mProjectText;
-    private ProjectChooserHelper mProjectChooserHelper;
-    private boolean mFirstOnShow = true;
-
-    protected ProjectCheckPage(ExportWizard wizard, String pageName) {
-        super(pageName);
-        mWizard = wizard;
-
-        setTitle("Project Checks");
-        setDescription("Performs a set of checks to make sure the application can be exported.");
-    }
-
-    public void createControl(Composite parent) {
-        mProjectChooserHelper = new ProjectChooserHelper(parent.getShell());
-        mDisplay = parent.getDisplay();
-
-        GridLayout gl = null;
-        GridData gd = null;
-
-        mTopComposite = new Composite(parent, SWT.NONE);
-        mTopComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mTopComposite.setLayout(new GridLayout(1, false));
-        
-        // composite for the project selection.
-        Composite projectComposite = new Composite(mTopComposite, SWT.NONE);
-        projectComposite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        projectComposite.setLayout(gl = new GridLayout(3, false));
-        gl.marginHeight = gl.marginWidth = 0;
-
-        Label label = new Label(projectComposite, SWT.NONE);
-        label.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = 3;
-        label.setText("Select the project to export:");
-
-        new Label(projectComposite, SWT.NONE).setText("Project:");
-        mProjectText = new Text(projectComposite, SWT.BORDER);
-        mProjectText.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        mProjectText.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                handleProjectNameChange();
-            }
-        });
-
-        Button browseButton = new Button(projectComposite, SWT.PUSH);
-        browseButton.setText("Browse...");
-        browseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                IJavaProject javaProject = mProjectChooserHelper.chooseJavaProject(
-                        mProjectText.getText().trim());
-
-                if (javaProject != null) {
-                    IProject project = javaProject.getProject();
-
-                    // set the new name in the text field. The modify listener will take
-                    // care of updating the status and the ExportWizard object.
-                    mProjectText.setText(project.getName());
-                }
-            }
-        });
-
-        setControl(mTopComposite);
-    }
-
-    @Override
-    void onShow() {
-        if (mFirstOnShow) {
-            // get the project and init the ui
-            IProject project = mWizard.getProject();
-            if (project != null) {
-                mProjectText.setText(project.getName());
-            }
-            
-            mFirstOnShow = false;
-        }
-    }
-    
-    private void buildErrorUi(IProject project) {
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setPageComplete(true);
-        mHasMessage = false;
-
-        // composite parent for the warning/error
-        GridLayout gl = null;
-        mErrorComposite = new Composite(mTopComposite, SWT.NONE);
-        mErrorComposite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        gl.verticalSpacing *= 3; // more spacing than normal.
-        mErrorComposite.setLayout(gl);
-
-        if (project == null) {
-            setErrorMessage("Select project to export.");
-            mHasMessage = true;
-        } else {
-            try {
-                if (project.hasNature(AndroidConstants.NATURE) == false) {
-                    addError(mErrorComposite, "Project is not an Android project.");
-                } else {
-                    // check for errors
-                    if (ProjectHelper.hasError(project, true))  {
-                        addError(mErrorComposite, "Project has compilation error(s)");
-                    }
-                    
-                    // check the project output
-                    IFolder outputIFolder = BaseProjectHelper.getOutputFolder(project);
-                    if (outputIFolder != null) {
-                        String outputOsPath =  outputIFolder.getLocation().toOSString();
-                        String apkFilePath =  outputOsPath + File.separator + project.getName() +
-                                AndroidConstants.DOT_ANDROID_PACKAGE;
-                        
-                        File f = new File(apkFilePath);
-                        if (f.isFile() == false) {
-                            addError(mErrorComposite,
-                                    String.format("%1$s/%2$s/%1$s%3$s does not exists!",
-                                            project.getName(),
-                                            outputIFolder.getName(),
-                                            AndroidConstants.DOT_ANDROID_PACKAGE));
-                        }
-                    } else {
-                        addError(mErrorComposite,
-                                "Unable to get the output folder of the project!");
-                    }
-
-
-                    // project is an android project, we check the debuggable attribute.
-                    AndroidManifestParser manifestParser = AndroidManifestParser.parse(
-                            BaseProjectHelper.getJavaProject(project), null /* errorListener */,
-                            true /* gatherData */, false /* markErrors */);
-
-                    Boolean debuggable = manifestParser.getDebuggable();
-                    
-                    if (debuggable != null && debuggable == Boolean.TRUE) {
-                        addWarning(mErrorComposite,
-                                "The manifest 'debuggable' attribute is set to true.\nYou should set it to false for applications that you release to the public."); 
-                    }
-                    
-                    // check for mapview stuff
-                }
-            } catch (CoreException e) {
-                // unable to access nature
-                addError(mErrorComposite, "Unable to get project nature");
-            }
-        }
-        
-        if (mHasMessage == false) {
-            Label label = new Label(mErrorComposite, SWT.NONE);
-            GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-            gd.horizontalSpan = 2;
-            label.setLayoutData(gd);
-            label.setText("No errors found. Click Next.");
-        }
-        
-        mTopComposite.layout();
-    }
-    
-    /**
-     * Adds an error label to a {@link Composite} object.
-     * @param parent the Composite parent.
-     * @param message the error message.
-     */
-    private void addError(Composite parent, String message) {
-        if (mError == null) {
-            mError = AdtPlugin.getImageLoader().loadImage(IMG_ERROR, mDisplay);
-        }
-        
-        new Label(parent, SWT.NONE).setImage(mError);
-        Label label = new Label(parent, SWT.NONE);
-        label.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        label.setText(message);
-        
-        setErrorMessage("Application cannot be exported due to the error(s) below.");
-        setPageComplete(false);
-        mHasMessage = true;
-    }
-    
-    /**
-     * Adds a warning label to a {@link Composite} object.
-     * @param parent the Composite parent.
-     * @param message the warning message.
-     */
-    private void addWarning(Composite parent, String message) {
-        if (mWarning == null) {
-            mWarning = AdtPlugin.getImageLoader().loadImage(IMG_WARNING, mDisplay);
-        }
-        
-        new Label(parent, SWT.NONE).setImage(mWarning);
-        Label label = new Label(parent, SWT.NONE);
-        label.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        label.setText(message);
-        
-        mHasMessage = true;
-    }
-    
-    /**
-     * Checks the parameters for correctness, and update the error message and buttons.
-     */
-    private void handleProjectNameChange() {
-        setPageComplete(false);
-        
-        if (mErrorComposite != null) {
-            mErrorComposite.dispose();
-            mErrorComposite = null;
-        }
-        
-        // update the wizard with the new project
-        mWizard.setProject(null, null, null);
-
-        //test the project name first!
-        String text = mProjectText.getText().trim();
-        if (text.length() == 0) {
-            setErrorMessage("Select project to export.");
-        } else if (text.matches("[a-zA-Z0-9_ \\.-]+") == false) {
-            setErrorMessage("Project name contains unsupported characters!");
-        } else {
-            IJavaProject[] projects = mProjectChooserHelper.getAndroidProjects(null);
-            IProject found = null;
-            for (IJavaProject javaProject : projects) {
-                if (javaProject.getProject().getName().equals(text)) {
-                    found = javaProject.getProject();
-                    break;
-                }
-                
-            }
-            
-            if (found != null) {
-                setErrorMessage(null);
-                
-                // update the wizard with the new project
-                setApkFilePathInWizard(found);
-
-                // now rebuild the error ui.
-                buildErrorUi(found);
-            } else {
-                setErrorMessage(String.format("There is no android project named '%1$s'",
-                        text));
-            }
-        }
-    }
-    
-    private void setApkFilePathInWizard(IProject project) {
-        if (project != null) {
-            IFolder outputIFolder = BaseProjectHelper.getOutputFolder(project);
-            if (outputIFolder != null) {
-                String outputOsPath =  outputIFolder.getLocation().toOSString();
-                String apkFilePath =  outputOsPath + File.separator + project.getName() +
-                        AndroidConstants.DOT_ANDROID_PACKAGE;
-                
-                File f = new File(apkFilePath);
-                if (f.isFile()) {
-                    mWizard.setProject(project, apkFilePath, f.getName());
-                    return;
-                }
-            }
-        }
-
-        mWizard.setProject(null, null, null);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainer.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainer.java
deleted file mode 100644
index c7cb427..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainer.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.internal;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IClasspathContainer;
-import org.eclipse.jdt.core.IClasspathEntry;
-
-/**
- * Classpath container for the Android projects.
- */
-class AndroidClasspathContainer implements IClasspathContainer {
-    
-    private IClasspathEntry[] mClasspathEntry;
-    private IPath mContainerPath;
-    private String mName;
-    
-    /**
-     * Constructs the container with the {@link IClasspathEntry} representing the android
-     * framework jar file and the container id
-     * @param entries the entries representing the android framework and optional libraries.
-     * @param path the path containing the classpath container id.
-     * @param name the name of the container to display.
-     */
-    AndroidClasspathContainer(IClasspathEntry[] entries, IPath path, String name) {
-        mClasspathEntry = entries;
-        mContainerPath = path;
-        mName = name;
-    }
-    
-    public IClasspathEntry[] getClasspathEntries() {
-        return mClasspathEntry;
-    }
-
-    public String getDescription() {
-        return mName;
-    }
-
-    public int getKind() {
-        return IClasspathContainer.K_DEFAULT_SYSTEM;
-    }
-
-    public IPath getPath() {
-        return mContainerPath;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainerInitializer.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainerInitializer.java
deleted file mode 100644
index 339dcd0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/internal/AndroidClasspathContainerInitializer.java
+++ /dev/null
@@ -1,629 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.internal;
-
-import com.android.ide.eclipse.adt.AdtConstants;
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.LoadStatus;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.IAndroidTarget.IOptionalLibrary;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jdt.core.ClasspathContainerInitializer;
-import org.eclipse.jdt.core.IAccessRule;
-import org.eclipse.jdt.core.IClasspathAttribute;
-import org.eclipse.jdt.core.IClasspathContainer;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-
-import java.io.File;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.regex.Pattern;
-
-/**
- * Classpath container initializer responsible for binding {@link AndroidClasspathContainer} to
- * {@link IProject}s. This removes the hard-coded path to the android.jar.
- */
-public class AndroidClasspathContainerInitializer extends ClasspathContainerInitializer {
-    /** The container id for the android framework jar file */
-    private final static String CONTAINER_ID =
-        "com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"; //$NON-NLS-1$
-
-    /** path separator to store multiple paths in a single property. This is guaranteed to not
-     * be in a path.
-     */
-    private final static String PATH_SEPARATOR = "\u001C"; //$NON-NLS-1$
-
-    private final static String PROPERTY_CONTAINER_CACHE = "androidContainerCache"; //$NON-NLS-1$
-    private final static String PROPERTY_TARGET_NAME = "androidTargetCache"; //$NON-NLS-1$
-    private final static String CACHE_VERSION = "01"; //$NON-NLS-1$
-    private final static String CACHE_VERSION_SEP = CACHE_VERSION + PATH_SEPARATOR;
-    
-    private final static int PATH_ANDROID_JAR = 0;
-    private final static int PATH_ANDROID_SRC = 1;
-    private final static int PATH_ANDROID_DOCS = 2;
-    private final static int PATH_ANDROID_OPT_DOCS = 3;
-    
-    public AndroidClasspathContainerInitializer() {
-        // pass
-    }
-
-    /**
-     * Binds a classpath container  to a {@link IClasspathContainer} for a given project,
-     * or silently fails if unable to do so.
-     * @param containerPath the container path that is the container id.
-     * @param project the project to bind
-     */
-    @Override
-    public void initialize(IPath containerPath, IJavaProject project) throws CoreException {
-        if (CONTAINER_ID.equals(containerPath.toString())) {
-            JavaCore.setClasspathContainer(new Path(CONTAINER_ID),
-                    new IJavaProject[] { project },
-                    new IClasspathContainer[] { allocateAndroidContainer(project) },
-                    new NullProgressMonitor());
-        }
-    }
-
-    /**
-     * Creates a new {@link IClasspathEntry} of type {@link IClasspathEntry#CPE_CONTAINER}
-     * linking to the Android Framework.
-     */
-    public static IClasspathEntry getContainerEntry() {
-        return JavaCore.newContainerEntry(new Path(CONTAINER_ID));
-    }
-
-    /**
-     * Checks the {@link IPath} objects against the android framework container id and
-     * returns <code>true</code> if they are identical.
-     * @param path the <code>IPath</code> to check.
-     */
-    public static boolean checkPath(IPath path) {
-        return CONTAINER_ID.equals(path.toString());
-    }
-    
-    /**
-     * Updates the {@link IJavaProject} objects with new android framework container. This forces
-     * JDT to recompile them.
-     * @param androidProjects the projects to update.
-     * @return <code>true</code> if success, <code>false</code> otherwise.
-     */
-    public static boolean updateProjects(IJavaProject[] androidProjects) {
-        try {
-            // Allocate a new AndroidClasspathContainer, and associate it to the android framework 
-            // container id for each projects.
-            // By providing a new association between a container id and a IClasspathContainer,
-            // this forces the JDT to query the IClasspathContainer for new IClasspathEntry (with
-            // IClasspathContainer#getClasspathEntries()), and therefore force recompilation of 
-            // the projects.
-            int projectCount = androidProjects.length;
-
-            IClasspathContainer[] containers = new IClasspathContainer[projectCount];
-            for (int i = 0 ; i < projectCount; i++) {
-                containers[i] = allocateAndroidContainer(androidProjects[i]);
-            }
-
-            // give each project their new container in one call.
-            JavaCore.setClasspathContainer(
-                    new Path(CONTAINER_ID),
-                    androidProjects, containers, new NullProgressMonitor());
-            
-            return true;
-        } catch (JavaModelException e) {
-            return false;
-        }
-    }
-
-    /**
-     * Allocates and returns an {@link AndroidClasspathContainer} object with the proper
-     * path to the framework jar file.
-     * @param javaProject The java project that will receive the container.
-     */
-    private static IClasspathContainer allocateAndroidContainer(IJavaProject javaProject) {
-        final IProject iProject = javaProject.getProject();
-
-        String markerMessage = null;
-        boolean outputToConsole = true;
-        
-        try {
-            AdtPlugin plugin = AdtPlugin.getDefault();
-            
-            // get the lock object for project manipulation during SDK load.
-            Object lock = plugin.getSdkLockObject();
-            synchronized (lock) {
-                boolean sdkIsLoaded = plugin.getSdkLoadStatus() == LoadStatus.LOADED;
-                
-                // check if the project has a valid target.
-                IAndroidTarget target = null;
-                if (sdkIsLoaded) {
-                    target = Sdk.getCurrent().getTarget(iProject);
-                }
-
-                // if we are loaded and the target is non null, we create a valid ClassPathContainer
-                if (sdkIsLoaded && target != null) {
-                    String targetName = target.getFullName();
-
-                    return new AndroidClasspathContainer(
-                            createClasspathEntries(iProject, target, targetName),
-                            new Path(CONTAINER_ID), targetName);
-                }
-
-                // In case of error, we'll try different thing to provide the best error message
-                // possible.
-                // Get the project's target's hash string (if it exists)
-                String hashString = Sdk.getProjectTargetHashString(iProject);
-
-                if (hashString == null || hashString.length() == 0) {
-                    // if there is no hash string we only show this if the SDK is loaded.
-                    // For a project opened at start-up with no target, this would be displayed
-                    // twice, once when the project is opened, and once after the SDK has
-                    // finished loading.
-                    // By testing the sdk is loaded, we only show this once in the console.
-                    if (sdkIsLoaded) {
-                        markerMessage = String.format(
-                                "Project has no target set. Edit the project properties to set one.");
-                    }
-                } else if (sdkIsLoaded) {
-                    markerMessage = String.format(
-                            "Unable to resolve target '%s'", hashString);
-                } else {
-                    // this is the case where there is a hashString but the SDK is not yet
-                    // loaded and therefore we can't get the target yet.
-                    // We check if there is a cache of the needed information.
-                    AndroidClasspathContainer container = getContainerFromCache(iProject);
-                    
-                    if (container == null) {
-                        // either the cache was wrong (ie folder does not exists anymore), or 
-                        // there was no cache. In this case we need to make sure the project
-                        // is resolved again after the SDK is loaded.
-                        plugin.setProjectToResolve(javaProject);
-                        
-                        markerMessage = String.format(
-                                "Unable to resolve target '%s' until the SDK is loaded.",
-                                hashString);
-
-                        // let's not log this one to the console as it will happen at every boot,
-                        // and it's expected. (we do keep the error marker though).
-                        outputToConsole = false;
-
-                    } else {
-                        // we created a container from the cache, so we register the project
-                        // to be checked for cache validity once the SDK is loaded
-                        plugin.setProjectToCheck(javaProject);
-                        
-                        // and return the container
-                        return container;
-                    }
-                    
-                }
-                
-                // return a dummy container to replace the one we may have had before.
-                // It'll be replaced by the real when if/when the target is resolved if/when the
-                // SDK finishes loading.
-                return new IClasspathContainer() {
-                    public IClasspathEntry[] getClasspathEntries() {
-                        return new IClasspathEntry[0];
-                    }
-
-                    public String getDescription() {
-                        return "Unable to get system library for the project";
-                    }
-
-                    public int getKind() {
-                        return IClasspathContainer.K_DEFAULT_SYSTEM;
-                    }
-
-                    public IPath getPath() {
-                        return null;
-                    }
-                };
-            }
-        } finally {
-            if (markerMessage != null) {
-                // log the error and put the marker on the project if we can.
-                if (outputToConsole) {
-                    AdtPlugin.printBuildToConsole(AdtConstants.BUILD_ALWAYS, iProject,
-                            markerMessage);
-                }
-                
-                try {
-                    BaseProjectHelper.addMarker(iProject, AdtConstants.MARKER_TARGET, markerMessage,
-                            -1, IMarker.SEVERITY_ERROR, IMarker.PRIORITY_HIGH);
-                } catch (CoreException e) {
-                    // In some cases, the workspace may be locked for modification when we
-                    // pass here.
-                    // We schedule a new job to put the marker after.
-                    final String fmessage = markerMessage;
-                    Job markerJob = new Job("Android SDK: Resolving error markers") {
-                        @SuppressWarnings("unchecked")
-                        @Override
-                        protected IStatus run(IProgressMonitor monitor) {
-                            try {
-                                BaseProjectHelper.addMarker(iProject, AdtConstants.MARKER_TARGET,
-                                        fmessage, -1, IMarker.SEVERITY_ERROR,
-                                        IMarker.PRIORITY_HIGH);
-                            } catch (CoreException e2) {
-                                return e2.getStatus();
-                            }
-
-                            return Status.OK_STATUS;
-                        }
-                    };
-
-                    // build jobs are run after other interactive jobs
-                    markerJob.setPriority(Job.BUILD);
-                    markerJob.schedule();
-                }
-            } else {
-                // no error, remove potential MARKER_TARGETs.
-                try {
-                    if (iProject.exists()) {
-                        iProject.deleteMarkers(AdtConstants.MARKER_TARGET, true,
-                                IResource.DEPTH_INFINITE);
-                    }
-                } catch (CoreException ce) {
-                    // In some cases, the workspace may be locked for modification when we pass
-                    // here, so we schedule a new job to put the marker after.
-                    Job markerJob = new Job("Android SDK: Resolving error markers") {
-                        @SuppressWarnings("unchecked")
-                        @Override
-                        protected IStatus run(IProgressMonitor monitor) {
-                            try {
-                                iProject.deleteMarkers(AdtConstants.MARKER_TARGET, true,
-                                        IResource.DEPTH_INFINITE);
-                            } catch (CoreException e2) {
-                                return e2.getStatus();
-                            }
-
-                            return Status.OK_STATUS;
-                        }
-                    };
-
-                    // build jobs are run after other interactive jobs
-                    markerJob.setPriority(Job.BUILD);
-                    markerJob.schedule();
-                }
-            }
-        }
-    }
-
-    /**
-     * Creates and returns an array of {@link IClasspathEntry} objects for the android
-     * framework and optional libraries.
-     * <p/>This references the OS path to the android.jar and the
-     * java doc directory. This is dynamically created when a project is opened,
-     * and never saved in the project itself, so there's no risk of storing an
-     * obsolete path.
-     * The method also stores the paths used to create the entries in the project persistent
-     * properties. A new {@link AndroidClasspathContainer} can be created from the stored path
-     * using the {@link #getContainerFromCache(IProject)} method.
-     * @param project 
-     * @param target The target that contains the libraries.
-     * @param targetName 
-     */
-    private static IClasspathEntry[] createClasspathEntries(IProject project,
-            IAndroidTarget target, String targetName) {
-        
-        // get the path from the target
-        String[] paths = getTargetPaths(target);
-        
-        // create the classpath entry from the paths
-        IClasspathEntry[] entries = createClasspathEntriesFromPaths(paths);
-        
-        // paths now contains all the path required to recreate the IClasspathEntry with no
-        // target info. We encode them in a single string, with each path separated by
-        // OS path separator.
-        StringBuilder sb = new StringBuilder(CACHE_VERSION);
-        for (String p : paths) {
-            sb.append(PATH_SEPARATOR);
-            sb.append(p);
-        }
-        
-        // store this in a project persistent property
-        ProjectHelper.saveStringProperty(project, PROPERTY_CONTAINER_CACHE, sb.toString());
-        ProjectHelper.saveStringProperty(project, PROPERTY_TARGET_NAME, targetName);
-
-        return entries;
-    }
-    
-    /**
-     * Generates an {@link AndroidClasspathContainer} from the project cache, if possible.
-     */
-    private static AndroidClasspathContainer getContainerFromCache(IProject project) {
-        // get the cached info from the project persistent properties.
-        String cache = ProjectHelper.loadStringProperty(project, PROPERTY_CONTAINER_CACHE);
-        String targetNameCache = ProjectHelper.loadStringProperty(project, PROPERTY_TARGET_NAME);
-        if (cache == null || targetNameCache == null) {
-            return null;
-        }
-        
-        // the first 2 chars must match CACHE_VERSION. The 3rd char is the normal separator.
-        if (cache.startsWith(CACHE_VERSION_SEP) == false) {
-            return null;
-        }
-        
-        cache = cache.substring(CACHE_VERSION_SEP.length());
-        
-        // the cache contains multiple paths, separated by a character guaranteed to not be in
-        // the path (\u001C).
-        // The first 3 are for android.jar (jar, source, doc), the rest are for the optional
-        // libraries and should contain at least one doc and a jar (if there are any libraries).
-        // Therefore, the path count should be 3 or 5+
-        String[] paths = cache.split(Pattern.quote(PATH_SEPARATOR));
-        if (paths.length < 3 || paths.length == 4) {
-            return null;
-        }
-        
-        // now we check the paths actually exist.
-        // There's an exception: If the source folder for android.jar does not exist, this is
-        // not a problem, so we skip it.
-        // Also paths[PATH_ANDROID_DOCS] is a URI to the javadoc, so we test it a bit differently.
-        try {
-            if (new File(paths[PATH_ANDROID_JAR]).exists() == false ||
-                    new File(new URI(paths[PATH_ANDROID_DOCS])).exists() == false) {
-                return null;
-            }
-        } catch (URISyntaxException e) {
-            return null;
-        } finally {
-            
-        }
-        
-        for (int i = 3 ; i < paths.length; i++) {
-            String path = paths[i];
-            if (path.length() > 0) {
-                File f =  new File(path);
-                if (f.exists() == false) {
-                    return null;
-                }
-            }
-        }
-
-        IClasspathEntry[] entries = createClasspathEntriesFromPaths(paths);
-
-        return new AndroidClasspathContainer(entries,
-                new Path(CONTAINER_ID), targetNameCache);
-    }
-    
-    /**
-     * Generates an array of {@link IClasspathEntry} from a set of paths.
-     * @see #getTargetPaths(IAndroidTarget)
-     */
-    private static IClasspathEntry[] createClasspathEntriesFromPaths(String[] paths) {
-        ArrayList<IClasspathEntry> list = new ArrayList<IClasspathEntry>();
-        
-        // First, we create the IClasspathEntry for the framework.
-        // now add the android framework to the class path.
-        // create the path object.
-        IPath android_lib = new Path(paths[PATH_ANDROID_JAR]);
-        IPath android_src = new Path(paths[PATH_ANDROID_SRC]);
-
-        // create the java doc link.
-        IClasspathAttribute cpAttribute = JavaCore.newClasspathAttribute(
-                IClasspathAttribute.JAVADOC_LOCATION_ATTRIBUTE_NAME,
-                paths[PATH_ANDROID_DOCS]);
-        
-        // create the access rule to restrict access to classes in com.android.internal
-        IAccessRule accessRule = JavaCore.newAccessRule(
-                new Path("com/android/internal/**"), //$NON-NLS-1$
-                IAccessRule.K_NON_ACCESSIBLE);
-
-        IClasspathEntry frameworkClasspathEntry = JavaCore.newLibraryEntry(android_lib,
-                android_src, // source attachment path
-                null,        // default source attachment root path.
-                new IAccessRule[] { accessRule },
-                new IClasspathAttribute[] { cpAttribute },
-                false // not exported.
-                );
-
-        list.add(frameworkClasspathEntry);
-        
-        // now deal with optional libraries
-        if (paths.length >= 5) {
-            String docPath = paths[PATH_ANDROID_OPT_DOCS];
-            int i = 4;
-            while (i < paths.length) {
-                Path jarPath = new Path(paths[i++]);
-
-                IClasspathAttribute[] attributes = null;
-                if (docPath.length() > 0) {
-                    attributes = new IClasspathAttribute[] {
-                            JavaCore.newClasspathAttribute(
-                                    IClasspathAttribute.JAVADOC_LOCATION_ATTRIBUTE_NAME,
-                                    docPath)
-                    };
-                }
-    
-                IClasspathEntry entry = JavaCore.newLibraryEntry(
-                        jarPath,
-                        null, // source attachment path
-                        null, // default source attachment root path.
-                        null,
-                        attributes,
-                        false // not exported.
-                        );
-                list.add(entry);
-            }
-        }
-        
-        return list.toArray(new IClasspathEntry[list.size()]);
-    }
-
-    /**
-     * Checks the projects' caches. If the cache was valid, the project is removed from the list.
-     * @param projects the list of projects to check.
-     */
-    public static void checkProjectsCache(ArrayList<IJavaProject> projects) {
-        int i = 0;
-        projectLoop: while (i < projects.size()) {
-            IJavaProject javaProject = projects.get(i);
-            IProject iProject = javaProject.getProject();
-            
-            // get the target from the project and its paths
-            IAndroidTarget target = Sdk.getCurrent().getTarget(javaProject.getProject());
-            if (target == null) {
-                // this is really not supposed to happen. This would mean there are cached paths,
-                // but default.properties was deleted. Keep the project in the list to force
-                // a resolve which will display the error.
-                i++;
-                continue;
-            }
-            
-            String[] targetPaths = getTargetPaths(target);
-            
-            // now get the cached paths
-            String cache = ProjectHelper.loadStringProperty(iProject, PROPERTY_CONTAINER_CACHE);
-            if (cache == null) {
-                // this should not happen. We'll force resolve again anyway.
-                i++;
-                continue;
-            }
-            
-            String[] cachedPaths = cache.split(Pattern.quote(PATH_SEPARATOR));
-            if (cachedPaths.length < 3 || cachedPaths.length == 4) {
-                // paths length is wrong. simply resolve the project again
-                i++;
-                continue;
-            }
-            
-            // Now we compare the paths. The first 4 can be compared directly.
-            // because of case sensitiveness we need to use File objects
-            
-            if (targetPaths.length != cachedPaths.length) {
-                // different paths, force resolve again.
-                i++;
-                continue;
-            }
-            
-            // compare the main paths (android.jar, main sources, main javadoc)
-            if (new File(targetPaths[PATH_ANDROID_JAR]).equals(
-                            new File(cachedPaths[PATH_ANDROID_JAR])) == false ||
-                    new File(targetPaths[PATH_ANDROID_SRC]).equals(
-                            new File(cachedPaths[PATH_ANDROID_SRC])) == false ||
-                    new File(targetPaths[PATH_ANDROID_DOCS]).equals(
-                            new File(cachedPaths[PATH_ANDROID_DOCS])) == false) {
-                // different paths, force resolve again.
-                i++;
-                continue;
-            }
-            
-            if (cachedPaths.length > PATH_ANDROID_OPT_DOCS) {
-                // compare optional libraries javadoc
-                if (new File(targetPaths[PATH_ANDROID_OPT_DOCS]).equals(
-                        new File(cachedPaths[PATH_ANDROID_OPT_DOCS])) == false) {
-                    // different paths, force resolve again.
-                    i++;
-                    continue;
-                }
-                
-                // testing the optional jar files is a little bit trickier.
-                // The order is not guaranteed to be identical.
-                // From a previous test, we do know however that there is the same number.
-                // The number of libraries should be low enough that we can simply go through the
-                // lists manually.
-                targetLoop: for (int tpi = 4 ; tpi < targetPaths.length; tpi++) {
-                    String targetPath = targetPaths[tpi];
-                    
-                    // look for a match in the other array
-                    for (int cpi = 4 ; cpi < cachedPaths.length; cpi++) {
-                        if (new File(targetPath).equals(new File(cachedPaths[cpi]))) {
-                            // found a match. Try the next targetPath
-                            continue targetLoop;
-                        }
-                    }
-                    
-                    // if we stop here, we haven't found a match, which means there's a
-                    // discrepancy in the libraries. We force a resolve.
-                    i++;
-                    continue projectLoop;
-                }
-            }
-
-            // at the point the check passes, and we can remove the project from the list.
-            // we do not increment i in this case.
-            projects.remove(i);
-        }
-    }
-    
-    /**
-     * Returns the paths necessary to create the {@link IClasspathEntry} for this targets.
-     * <p/>The paths are always in the same order.
-     * <ul>
-     * <li>Path to android.jar</li>
-     * <li>Path to the source code for android.jar</li>
-     * <li>Path to the javadoc for the android platform</li>
-     * </ul>
-     * Additionally, if there are optional libraries, the array will contain:
-     * <ul>
-     * <li>Path to the librairies javadoc</li>
-     * <li>Path to the first .jar file</li>
-     * <li>(more .jar as needed)</li>
-     * </ul>
-     */
-    private static String[] getTargetPaths(IAndroidTarget target) {
-        ArrayList<String> paths = new ArrayList<String>();
-        
-        // first, we get the path for android.jar
-        // The order is: android.jar, source folder, docs folder
-        paths.add(target.getPath(IAndroidTarget.ANDROID_JAR));
-        paths.add(target.getPath(IAndroidTarget.SOURCES));
-        paths.add(AdtPlugin.getUrlDoc());
-        
-        // now deal with optional libraries.
-        IOptionalLibrary[] libraries = target.getOptionalLibraries();
-        if (libraries != null) {
-            // all the optional libraries use the same javadoc, so we start with this
-            String targetDocPath = target.getPath(IAndroidTarget.DOCS);
-            if (targetDocPath != null) {
-                paths.add(targetDocPath);
-            } else {
-                // we add an empty string, to always have the same count.
-                paths.add("");
-            }
-            
-            // because different libraries could use the same jar file, we make sure we add
-            // each jar file only once.
-            HashSet<String> visitedJars = new HashSet<String>();
-            for (IOptionalLibrary library : libraries) {
-                String jarPath = library.getJarPath();
-                if (visitedJars.contains(jarPath) == false) {
-                    visitedJars.add(jarPath);
-                    paths.add(jarPath);
-                }
-            }
-        }
-
-        return paths.toArray(new String[paths.size()]);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/properties/AndroidPropertyPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/properties/AndroidPropertyPage.java
deleted file mode 100644
index 584dd0d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/project/properties/AndroidPropertyPage.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project.properties;
-
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdkuilib.SdkTargetSelector;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.IWorkbenchPropertyPage;
-import org.eclipse.ui.dialogs.PropertyPage;
-
-/**
- * Property page for "Android" project.
- * This is accessible from the Package Explorer when right clicking a project and choosing
- * "Properties".
- *
- */
-public class AndroidPropertyPage extends PropertyPage implements IWorkbenchPropertyPage {
-
-    private IProject mProject;
-    private SdkTargetSelector mSelector;
-
-    public AndroidPropertyPage() {
-        // pass
-    }
-
-    @Override
-    protected Control createContents(Composite parent) {
-        // get the element (this is not yet valid in the constructor).
-        mProject = (IProject)getElement();
-        
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayoutData(new GridData(GridData.FILL_BOTH));
-        top.setLayout(new GridLayout(1, false));
-
-        Label l = new Label(top, SWT.NONE);
-        l.setText("Project Target");
-        
-        // get the targets from the sdk
-        IAndroidTarget[] targets = null;
-        if (Sdk.getCurrent() != null) {
-            targets = Sdk.getCurrent().getTargets();
-        }
-        
-        // build the UI.
-        mSelector = new SdkTargetSelector(top, targets, false /*allowMultipleSelection*/);
-
-        if (Sdk.getCurrent() != null) {
-            IAndroidTarget target = Sdk.getCurrent().getTarget(mProject);
-            if (target != null) {
-                mSelector.setSelection(target);
-            }
-        }
-
-        mSelector.setSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // look for the selection and validate the page if there is a selection
-                IAndroidTarget target = mSelector.getFirstSelected();
-                setValid(target != null);
-            }
-        });
-
-        return top;
-    }
-
-    @Override
-    public boolean performOk() {
-        if (Sdk.getCurrent() != null) {
-            Sdk.getCurrent().setProject(mProject, mSelector.getFirstSelected());
-        }
-        
-        return true;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidJarLoader.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidJarLoader.java
deleted file mode 100644
index 1f6ebf1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidJarLoader.java
+++ /dev/null
@@ -1,431 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.SubMonitor;
-
-import java.io.FileInputStream;
-import java.io.IOException;
-import java.lang.reflect.Modifier;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.zip.ZipEntry;
-import java.util.zip.ZipInputStream;
-
-import javax.management.InvalidAttributeValueException;
-
-/**
- * Custom class loader able to load a class from the SDK jar file.
- */
-public class AndroidJarLoader extends ClassLoader implements IAndroidClassLoader {
-    
-    /**
-     * Wrapper around a {@link Class} to provide the methods of
-     * {@link IAndroidClassLoader.IClassDescriptor}.
-     */
-    public final static class ClassWrapper implements IClassDescriptor {
-        private Class<?> mClass;
-
-        public ClassWrapper(Class<?> clazz) {
-            mClass = clazz;
-        }
-
-        public String getCanonicalName() {
-            return mClass.getCanonicalName();
-        }
-
-        public IClassDescriptor[] getDeclaredClasses() {
-            Class<?>[] classes = mClass.getDeclaredClasses();
-            IClassDescriptor[] iclasses = new IClassDescriptor[classes.length];
-            for (int i = 0 ; i < classes.length ; i++) {
-                iclasses[i] = new ClassWrapper(classes[i]);
-            }
-
-            return iclasses;
-        }
-
-        public IClassDescriptor getEnclosingClass() {
-            return new ClassWrapper(mClass.getEnclosingClass());
-        }
-
-        public String getSimpleName() {
-            return mClass.getSimpleName();
-        }
-
-        public IClassDescriptor getSuperclass() {
-            return new ClassWrapper(mClass.getSuperclass());
-        }
-        
-        @Override
-        public boolean equals(Object clazz) {
-            if (clazz instanceof ClassWrapper) {
-                return mClass.equals(((ClassWrapper)clazz).mClass);
-            }
-            return super.equals(clazz);
-        }
-        
-        @Override
-        public int hashCode() {
-            return mClass.hashCode();
-        }
-
-
-        public boolean isInstantiable() {
-            int modifiers = mClass.getModifiers();
-            return Modifier.isAbstract(modifiers) == false && Modifier.isPublic(modifiers) == true;
-        }
-
-        public Class<?> wrappedClass() {
-            return mClass;
-        }
-
-    }
-    
-    private String mOsFrameworkLocation;
-    
-    /** A cache for binary data extracted from the zip */
-    private final HashMap<String, byte[]> mEntryCache = new HashMap<String, byte[]>();
-    /** A cache for already defined Classes */
-    private final HashMap<String, Class<?> > mClassCache = new HashMap<String, Class<?> >();
-    
-    /**
-     * Creates the class loader by providing the os path to the framework jar archive
-     * 
-     * @param osFrameworkLocation OS Path of the framework JAR file
-     */
-    public AndroidJarLoader(String osFrameworkLocation) {
-        super();
-        mOsFrameworkLocation = osFrameworkLocation;
-    }
-    
-    public String getSource() {
-        return mOsFrameworkLocation;
-    }
-    
-    /**
-     * Pre-loads all class binary data that belong to the given package by reading the archive
-     * once and caching them internally.
-     * <p/>
-     * This does not actually preload "classes", it just reads the unzipped bytes for a given
-     * class. To obtain a class, one must call {@link #findClass(String)} later.
-     * <p/>
-     * All classes which package name starts with "packageFilter" will be included and can be
-     * found later.
-     * <p/>
-     * May throw some exceptions if the framework JAR cannot be read.
-     * 
-     * @param packageFilter The package that contains all the class data to preload, using a fully
-     *                    qualified binary name (.e.g "com.my.package."). The matching algorithm
-     *                    is simple "startsWith". Use an empty string to include everything.
-     * @param taskLabel An optional task name for the sub monitor. Can be null.
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     * @throws IOException
-     * @throws InvalidAttributeValueException
-     * @throws ClassFormatError
-     */
-    public void preLoadClasses(String packageFilter, String taskLabel, IProgressMonitor monitor)
-        throws IOException, InvalidAttributeValueException, ClassFormatError {
-        // Transform the package name into a zip entry path
-        String pathFilter = packageFilter.replaceAll("\\.", "/"); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        SubMonitor progress = SubMonitor.convert(monitor, taskLabel == null ? "" : taskLabel, 100);
-        
-        // create streams to read the intermediary archive
-        FileInputStream fis = new FileInputStream(mOsFrameworkLocation);
-        ZipInputStream zis = new ZipInputStream(fis);
-        ZipEntry entry;       
-        while ((entry = zis.getNextEntry()) != null) {
-            // get the name of the entry.
-            String entryPath = entry.getName();
-            
-            if (!entryPath.endsWith(AndroidConstants.DOT_CLASS)) {
-                // only accept class files
-                continue;
-            }
-
-            // check if it is part of the package to preload
-            if (pathFilter.length() > 0 && !entryPath.startsWith(pathFilter)) {
-                continue;
-            }
-            String className = entryPathToClassName(entryPath);
-
-            if (!mEntryCache.containsKey(className)) {
-                long entrySize = entry.getSize();
-                if (entrySize > Integer.MAX_VALUE) {
-                    throw new InvalidAttributeValueException();
-                }
-                byte[] data = readZipData(zis, (int)entrySize);
-                mEntryCache.put(className, data);
-            }
-
-            // advance 5% of whatever is allocated on the progress bar
-            progress.setWorkRemaining(100);
-            progress.worked(5);
-            progress.subTask(String.format("Preload %1$s", className));
-        }
-    }
-
-    /**
-     * Finds and loads all classes that derive from a given set of super classes.
-     * <p/>
-     * As a side-effect this will load and cache most, if not all, classes in the input JAR file.
-     * 
-     * @param packageFilter Base name of package of classes to find.
-     *                      Use an empty string to find everyting.
-     * @param superClasses The super classes of all the classes to find. 
-     * @return An hash map which keys are the super classes looked for and which values are
-     *         ArrayList of the classes found. The array lists are always created for all the
-     *         valid keys, they are simply empty if no deriving class is found for a given
-     *         super class. 
-     * @throws IOException
-     * @throws InvalidAttributeValueException
-     * @throws ClassFormatError
-     */
-    public HashMap<String, ArrayList<IClassDescriptor>> findClassesDerivingFrom(
-            String packageFilter,
-            String[] superClasses)
-            throws IOException, InvalidAttributeValueException, ClassFormatError {
-
-        packageFilter = packageFilter.replaceAll("\\.", "/"); //$NON-NLS-1$ //$NON-NLS-2$
-
-        HashMap<String, ArrayList<IClassDescriptor>> mClassesFound =
-                new HashMap<String, ArrayList<IClassDescriptor>>();
-
-        for (String className : superClasses) {
-            mClassesFound.put(className, new ArrayList<IClassDescriptor>());
-        }
-
-        // create streams to read the intermediary archive
-        FileInputStream fis = new FileInputStream(mOsFrameworkLocation);
-        ZipInputStream zis = new ZipInputStream(fis);
-        ZipEntry entry;
-        while ((entry = zis.getNextEntry()) != null) {
-            // get the name of the entry and convert to a class binary name
-            String entryPath = entry.getName();
-            if (!entryPath.endsWith(AndroidConstants.DOT_CLASS)) {
-                // only accept class files
-                continue;
-            }
-            if (packageFilter.length() > 0 && !entryPath.startsWith(packageFilter)) {
-                // only accept stuff from the requested root package.
-                continue;
-            }
-            String className = entryPathToClassName(entryPath);
-      
-            Class<?> loaded_class = mClassCache.get(className);
-            if (loaded_class == null) {
-                byte[] data = mEntryCache.get(className);
-                if (data == null) {    
-                    // Get the class and cache it
-                    long entrySize = entry.getSize();
-                    if (entrySize > Integer.MAX_VALUE) {
-                        throw new InvalidAttributeValueException();
-                    }
-                    data = readZipData(zis, (int)entrySize);
-                }
-                loaded_class = defineAndCacheClass(className, data);
-            }
-
-            for (Class<?> superClass = loaded_class.getSuperclass();
-                    superClass != null;
-                    superClass = superClass.getSuperclass()) {
-                String superName = superClass.getCanonicalName();
-                if (mClassesFound.containsKey(superName)) {
-                    mClassesFound.get(superName).add(new ClassWrapper(loaded_class));
-                    break;
-                }
-            }
-        }
-
-        return mClassesFound;
-    }
-
-    /** Helper method that converts a Zip entry path into a corresponding
-     *  Java full qualified binary class name.
-     *  <p/>
-     *  F.ex, this converts "com/my/package/Foo.class" into "com.my.package.Foo".
-     */
-    private String entryPathToClassName(String entryPath) {
-        return entryPath.replaceFirst("\\.class$", "").replaceAll("[/\\\\]", "."); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-    }
-
-    /**
-     * Finds the class with the specified binary name.
-     * 
-     * {@inheritDoc}
-     */
-    @Override
-    protected Class<?> findClass(String name) throws ClassNotFoundException {
-        try {
-            // try to find the class in the cache
-            Class<?> cached_class = mClassCache.get(name);
-            if (cached_class == ClassNotFoundException.class) {
-                // we already know we can't find this class, don't try again
-                throw new ClassNotFoundException(name);
-            } else if (cached_class != null) {
-                return cached_class;
-            }
-            
-            // if not found, look it up and cache it
-            byte[] data = loadClassData(name);
-            if (data != null) {
-                return defineAndCacheClass(name, data);
-            } else {
-                // if the class can't be found, record a CNFE class in the map so
-                // that we don't try to reload it next time
-                mClassCache.put(name, ClassNotFoundException.class);
-                throw new ClassNotFoundException(name);
-            }
-        } catch (ClassNotFoundException e) {
-            throw e;
-        } catch (Exception e) {
-            throw new ClassNotFoundException(e.getMessage()); 
-        }
-    }
-
-    /**
-     * Defines a class based on its binary data and caches the resulting class object.
-     * 
-     * @param name The binary name of the class (i.e. package.class1$class2)
-     * @param data The binary data from the loader.
-     * @return The class defined
-     * @throws ClassFormatError if defineClass failed.
-     */
-    private Class<?> defineAndCacheClass(String name, byte[] data) throws ClassFormatError {
-        Class<?> cached_class;
-        cached_class = defineClass(null, data, 0, data.length);
-
-        if (cached_class != null) {
-            // Add new class to the cache class and remove it from the zip entry data cache
-            mClassCache.put(name, cached_class);
-            mEntryCache.remove(name);
-        }
-        return cached_class;
-    }
-    
-    /**
-     * Loads a class data from its binary name.
-     * <p/>
-     * This uses the class binary data that has been preloaded earlier by the preLoadClasses()
-     * method if possible.
-     * 
-     * @param className the binary name
-     * @return an array of bytes representing the class data or null if not found
-     * @throws InvalidAttributeValueException 
-     * @throws IOException 
-     */
-    private synchronized byte[] loadClassData(String className)
-            throws InvalidAttributeValueException, IOException {
-
-        byte[] data = mEntryCache.get(className);
-        if (data != null) {
-            return data;
-        }
-        
-        // The name is a binary name. Something like "android.R", or "android.R$id".
-        // Make a path out of it.
-        String entryName = className.replaceAll("\\.", "/") + AndroidConstants.DOT_CLASS; //$NON-NLS-1$ //$NON-NLS-2$
-
-       // create streams to read the intermediary archive
-        FileInputStream fis = new FileInputStream(mOsFrameworkLocation);
-        ZipInputStream zis = new ZipInputStream(fis);
-        
-        // loop on the entries of the intermediary package and put them in the final package.
-        ZipEntry entry;
-
-        while ((entry = zis.getNextEntry()) != null) {
-            // get the name of the entry.
-            String currEntryName = entry.getName();
-            
-            if (currEntryName.equals(entryName)) {
-                long entrySize = entry.getSize();
-                if (entrySize > Integer.MAX_VALUE) {
-                    throw new InvalidAttributeValueException();
-                }
-
-                data = readZipData(zis, (int)entrySize);
-                return data;
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Reads data for the <em>current</em> entry from the zip input stream.
-     * 
-     * @param zis The Zip input stream
-     * @param entrySize The entry size. -1 if unknown.
-     * @return The new data for the <em>current</em> entry.
-     * @throws IOException If ZipInputStream.read() fails.
-     */
-    private byte[] readZipData(ZipInputStream zis, int entrySize) throws IOException {
-        int block_size = 1024;
-        int data_size = entrySize < 1 ? block_size : entrySize; 
-        int offset = 0;
-        byte[] data = new byte[data_size];
-        
-        while(zis.available() != 0) {
-            int count = zis.read(data, offset, data_size - offset);
-            if (count < 0) {  // read data is done
-                break;
-            }
-            offset += count;
-            
-            if (entrySize >= 1 && offset >= entrySize) {  // we know the size and we're done
-                break;
-            }
-
-            // if we don't know the entry size and we're not done reading,
-            // expand the data buffer some more.
-            if (offset >= data_size) {
-                byte[] temp = new byte[data_size + block_size];
-                System.arraycopy(data, 0, temp, 0, data_size);
-                data_size += block_size;
-                data = temp;
-                block_size *= 2;
-            }
-        }
-        
-        if (offset < data_size) {
-            // buffer was allocated too large, trim it
-            byte[] temp = new byte[offset];
-            if (offset > 0) {
-                System.arraycopy(data, 0, temp, 0, offset);
-            }
-            data = temp;
-        }
-        
-        return data;
-    }
-
-    /**
-     * Returns a {@link IAndroidClassLoader.IClassDescriptor} by its fully-qualified name.
-     * @param className the fully-qualified name of the class to return.
-     * @throws ClassNotFoundException
-     */
-    public IClassDescriptor getClass(String className) throws ClassNotFoundException {
-        try {
-            return new ClassWrapper(loadClass(className));
-        } catch (ClassNotFoundException e) {
-            throw e;  // useful for debugging
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetData.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetData.java
deleted file mode 100644
index 2309181..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetData.java
+++ /dev/null
@@ -1,298 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.build.DexWrapper;
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.layout.descriptors.LayoutDescriptors;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.menu.descriptors.MenuDescriptors;
-import com.android.ide.eclipse.editors.resources.descriptors.ResourcesDescriptors;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.ide.eclipse.editors.xml.descriptors.XmlDescriptors;
-import com.android.layoutlib.api.ILayoutBridge;
-import com.android.sdklib.IAndroidTarget;
-
-import java.util.Hashtable;
-import java.util.Map;
-
-/**
- * This class contains the data of an Android Target as loaded from the SDK.
- */
-public class AndroidTargetData {
-    
-    public final static int DESCRIPTOR_MANIFEST = 1;
-    public final static int DESCRIPTOR_LAYOUT = 2;
-    public final static int DESCRIPTOR_MENU = 3;
-    public final static int DESCRIPTOR_XML = 4;
-    public final static int DESCRIPTOR_RESOURCES = 5;
-    public final static int DESCRIPTOR_SEARCHABLE = 6;
-    public final static int DESCRIPTOR_PREFERENCES = 7;
-    
-    public final static class LayoutBridge {
-        /** Link to the layout bridge */
-        public ILayoutBridge bridge;
-
-        public LoadStatus status = LoadStatus.LOADING;
-        
-        public ClassLoader classLoader;
-    }
-
-    private final IAndroidTarget mTarget;
-
-    private DexWrapper mDexWrapper;
-
-    /**
-     * mAttributeValues is a map { key => list [ values ] }.
-     * The key for the map is "(element-xml-name,attribute-namespace:attribute-xml-local-name)".
-     * The attribute namespace prefix must be:
-     * - "android" for AndroidConstants.NS_RESOURCES
-     * - "xmlns" for the XMLNS URI.
-     * 
-     * This is used for attributes that do not have a unique name, but still need to be populated
-     * with values in the UI. Uniquely named attributes have their values in {@link #mEnumValueMap}.
-     */
-    private Hashtable<String, String[]> mAttributeValues = new Hashtable<String, String[]>();
-    
-    private IResourceRepository mSystemResourceRepository;
-
-    private AndroidManifestDescriptors mManifestDescriptors;
-    private LayoutDescriptors mLayoutDescriptors;
-    private MenuDescriptors mMenuDescriptors;
-    private XmlDescriptors mXmlDescriptors;
-
-    private Map<String, Map<String, Integer>> mEnumValueMap;
-
-    private ProjectResources mFrameworkResources;
-    private LayoutBridge mLayoutBridge;
-
-    private boolean mLayoutBridgeInit = false;
-
-    AndroidTargetData(IAndroidTarget androidTarget) {
-        mTarget = androidTarget;
-    }
-    
-    void setDexWrapper(DexWrapper wrapper) {
-        mDexWrapper = wrapper;
-    }
-    
-    /**
-     * Creates an AndroidTargetData object.
-     */
-    void setExtraData(IResourceRepository systemResourceRepository,
-            AndroidManifestDescriptors manifestDescriptors,
-            LayoutDescriptors layoutDescriptors,
-            MenuDescriptors menuDescriptors,
-            XmlDescriptors xmlDescriptors,
-            Map<String, Map<String, Integer>> enumValueMap,
-            String[] permissionValues,
-            String[] activityIntentActionValues,
-            String[] broadcastIntentActionValues,
-            String[] serviceIntentActionValues,
-            String[] intentCategoryValues,
-            ProjectResources resources,
-            LayoutBridge layoutBridge) {
-        
-        mSystemResourceRepository = systemResourceRepository;
-        mManifestDescriptors = manifestDescriptors;
-        mLayoutDescriptors = layoutDescriptors;
-        mMenuDescriptors = menuDescriptors;
-        mXmlDescriptors = xmlDescriptors;
-        mEnumValueMap = enumValueMap;
-        mFrameworkResources = resources;
-        mLayoutBridge = layoutBridge;
-
-        setPermissions(permissionValues);
-        setIntentFilterActionsAndCategories(activityIntentActionValues, broadcastIntentActionValues,
-                serviceIntentActionValues, intentCategoryValues);
-    }
-    
-    public DexWrapper getDexWrapper() {
-        return mDexWrapper;
-    }
-    
-    public IResourceRepository getSystemResources() {
-        return mSystemResourceRepository;
-    }
-    
-    /**
-     * Returns an {@link IDescriptorProvider} from a given Id.
-     * The Id can be one of {@link #DESCRIPTOR_MANIFEST}, {@link #DESCRIPTOR_LAYOUT},
-     * {@link #DESCRIPTOR_MENU}, or {@link #DESCRIPTOR_XML}.
-     * All other values will throw an {@link IllegalArgumentException}.
-     */
-    public IDescriptorProvider getDescriptorProvider(int descriptorId) {
-        switch (descriptorId) {
-            case DESCRIPTOR_MANIFEST:
-                return mManifestDescriptors;
-            case DESCRIPTOR_LAYOUT:
-                return mLayoutDescriptors;
-            case DESCRIPTOR_MENU:
-                return mMenuDescriptors;
-            case DESCRIPTOR_XML:
-                return mXmlDescriptors;
-            case DESCRIPTOR_RESOURCES:
-                // FIXME: since it's hard-coded the Resources Descriptors are not platform dependent.
-                return ResourcesDescriptors.getInstance();
-            case DESCRIPTOR_PREFERENCES:
-                return mXmlDescriptors.getPreferencesProvider();
-            case DESCRIPTOR_SEARCHABLE:
-                return mXmlDescriptors.getSearchableProvider();
-            default :
-                 throw new IllegalArgumentException();
-        }
-    }
-    
-    /**
-     * Returns the manifest descriptors.
-     */
-    public AndroidManifestDescriptors getManifestDescriptors() {
-        return mManifestDescriptors;
-    }
-    
-    /**
-     * Returns the layout Descriptors.
-     */
-    public LayoutDescriptors getLayoutDescriptors() {
-        return mLayoutDescriptors;
-    }
-    
-    /**
-     * Returns the menu descriptors.
-     */
-    public MenuDescriptors getMenuDescriptors() {
-        return mMenuDescriptors;
-    }
-
-    /**
-     * Returns the XML descriptors
-     */
-    public XmlDescriptors getXmlDescriptors() {
-        return mXmlDescriptors;
-    }
-
-    /**
-     * Returns this list of possible values for an XML attribute.
-     * <p/>This should only be called for attributes for which possible values depend on the
-     * parent element node.
-     * <p/>For attributes that have the same values no matter the parent node, use
-     * {@link #getEnumValueMap()}.  
-     * @param elementName the name of the element containing the attribute.
-     * @param attributeName the name of the attribute
-     * @return an array of String with the possible values, or <code>null</code> if no values were
-     * found.
-     */
-    public String[] getAttributeValues(String elementName, String attributeName) {
-        String key = String.format("(%1$s,%2$s)", elementName, attributeName); //$NON-NLS-1$
-        return mAttributeValues.get(key);
-    }
-
-    /**
-     * Returns this list of possible values for an XML attribute.
-     * <p/>This should only be called for attributes for which possible values depend on the
-     * parent and great-grand-parent element node.
-     * <p/>The typical example of this is for the 'name' attribute under
-     * activity/intent-filter/action
-     * <p/>For attributes that have the same values no matter the parent node, use
-     * {@link #getEnumValueMap()}.  
-     * @param elementName the name of the element containing the attribute.
-     * @param attributeName the name of the attribute
-     * @param greatGrandParentElementName the great-grand-parent node.
-     * @return an array of String with the possible values, or <code>null</code> if no values were
-     * found.
-     */
-    public String[] getAttributeValues(String elementName, String attributeName,
-            String greatGrandParentElementName) {
-        if (greatGrandParentElementName != null) {
-            String key = String.format("(%1$s,%2$s,%3$s)", //$NON-NLS-1$
-                    greatGrandParentElementName, elementName, attributeName); 
-            String[] values = mAttributeValues.get(key);
-            if (values != null) {
-                return values;
-            }
-        }
-        
-        return getAttributeValues(elementName, attributeName);
-    }
-
-    /**
-     * Returns the enum values map.
-     * <p/>The map defines the possible values for XML attributes. The key is the attribute name
-     * and the value is a map of (string, integer) in which the key (string) is the name of
-     * the value, and the Integer is the numerical value in the compiled binary XML files.
-     */
-    public Map<String, Map<String, Integer>> getEnumValueMap() {
-        return mEnumValueMap;
-    }
-    
-    /**
-     * Returns the {@link ProjectResources} containing the Framework Resources.
-     */
-    public ProjectResources getFrameworkResources() {
-        return mFrameworkResources;
-    }
-    
-    /**
-     * Returns a {@link LayoutBridge} object possibly containing a {@link ILayoutBridge} object.
-     * <p/>If {@link LayoutBridge#bridge} is <code>null</code>, {@link LayoutBridge#status} will
-     * contain the reason (either {@link LoadStatus#LOADING} or {@link LoadStatus#FAILED}).
-     * <p/>Valid {@link ILayoutBridge} objects are always initialized before being returned.
-     */
-    public synchronized LayoutBridge getLayoutBridge() {
-        if (mLayoutBridgeInit == false && mLayoutBridge.bridge != null) {
-            mLayoutBridge.bridge.init(mTarget.getPath(IAndroidTarget.FONTS),
-                    getEnumValueMap());
-            mLayoutBridgeInit = true;
-        }
-        return mLayoutBridge;
-    }
-    
-    /**
-     * Sets the permission values
-     * @param permissionValues the list of permissions
-     */
-    private void setPermissions(String[] permissionValues) {
-        setValues("(uses-permission,android:name)", permissionValues); //$NON-NLS-1$
-        setValues("(application,android:permission)", permissionValues); //$NON-NLS-1$
-        setValues("(activity,android:permission)", permissionValues); //$NON-NLS-1$
-        setValues("(receiver,android:permission)", permissionValues); //$NON-NLS-1$
-        setValues("(service,android:permission)", permissionValues); //$NON-NLS-1$
-        setValues("(provider,android:permission)", permissionValues); //$NON-NLS-1$
-    }
-    
-    private void setIntentFilterActionsAndCategories(String[] activityIntentActions,
-            String[] broadcastIntentActions, String[] serviceIntentActions,
-            String[] intentCategoryValues) {
-        setValues("(activity,action,android:name)", activityIntentActions); //$NON-NLS-1$
-        setValues("(receiver,action,android:name)", broadcastIntentActions); //$NON-NLS-1$
-        setValues("(service,action,android:name)", serviceIntentActions); //$NON-NLS-1$
-        setValues("(category,android:name)", intentCategoryValues); //$NON-NLS-1$
-    }
-
-    /**
-     * Sets a (name, values) pair in the hash map.
-     * <p/>
-     * If the name is already present in the map, it is first removed.
-     * @param name the name associated with the values.
-     * @param values The values to add.
-     */
-    private void setValues(String name, String[] values) {
-        mAttributeValues.remove(name);
-        mAttributeValues.put(name, values);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetParser.java
deleted file mode 100644
index aab660d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/AndroidTargetParser.java
+++ /dev/null
@@ -1,664 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.build.DexWrapper;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData.LayoutBridge;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.AttrsXmlParser;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo;
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.editors.layout.descriptors.LayoutDescriptors;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.menu.descriptors.MenuDescriptors;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.xml.descriptors.XmlDescriptors;
-import com.android.layoutlib.api.ILayoutBridge;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.SubMonitor;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.IOException;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import javax.management.InvalidAttributeValueException;
-
-/**
- * Parser for the platform data in an SDK.
- * <p/>
- * This gather the following information:
- * <ul>
- * <li>Resource ID from <code>android.R</code></li>
- * <li>The list of permissions values from <code>android.Manifest$permission</code></li>
- * <li></li>
- * </ul> 
- */
-public final class AndroidTargetParser {
-    
-    private static final String TAG = "Framework Resource Parser";
-    private final IAndroidTarget mAndroidTarget;
-
-    /**
-     * Creates a platform data parser.
-     */
-    public AndroidTargetParser(IAndroidTarget platformTarget) {
-        mAndroidTarget = platformTarget;
-    }
-    
-    /**
-     * Parses the framework, collects all interesting information and stores them in the
-     * {@link IAndroidTarget} given to the constructor.
-     * 
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     * @return True if the SDK path was valid and parsing has been attempted.
-     */
-    public IStatus run(IProgressMonitor monitor) {
-        try {
-            SubMonitor progress = SubMonitor.convert(monitor,
-                    String.format("Parsing SDK %1$s", mAndroidTarget.getName()),
-                    200);
-            
-            AndroidTargetData targetData = new AndroidTargetData(mAndroidTarget);
-
-            // load DX.
-            DexWrapper dexWrapper = new DexWrapper();
-            IStatus res = dexWrapper.loadDex(mAndroidTarget.getPath(IAndroidTarget.DX_JAR));
-            if (res != Status.OK_STATUS) {
-                return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                        String.format("dx.jar loading failed for target '%1$s'",
-                                mAndroidTarget.getFullName()));
-            }
-            
-            // we have loaded dx.
-            targetData.setDexWrapper(dexWrapper);
-            
-            // parse the rest of the data.
-            progress.setWorkRemaining(120);
-
-            AndroidJarLoader classLoader =
-                new AndroidJarLoader(mAndroidTarget.getPath(IAndroidTarget.ANDROID_JAR));
-            
-            preload(classLoader, progress.newChild(40, SubMonitor.SUPPRESS_NONE));
-            progress.setWorkRemaining(80);
-            
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-            
-            // get the resource Ids.
-            progress.subTask("Resource IDs");
-            IResourceRepository frameworkRepository = collectResourceIds(classLoader);
-            progress.worked(5);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            // get the permissions
-            progress.subTask("Permissions");
-            String[] permissionValues = collectPermissions(classLoader);
-            progress.worked(5);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            // get the action and category values for the Intents.
-            progress.subTask("Intents");
-            ArrayList<String> activity_actions = new ArrayList<String>();
-            ArrayList<String> broadcast_actions = new ArrayList<String>();
-            ArrayList<String> service_actions = new ArrayList<String>();
-            ArrayList<String> categories = new ArrayList<String>();
-            collectIntentFilterActionsAndCategories(activity_actions, broadcast_actions,
-                    service_actions, categories);
-            progress.worked(5);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            // gather the attribute definition
-            progress.subTask("Attributes definitions");
-            AttrsXmlParser attrsXmlParser = new AttrsXmlParser(
-                    mAndroidTarget.getPath(IAndroidTarget.ATTRIBUTES));
-            attrsXmlParser.preload();
-
-            progress.subTask("Manifest definitions");
-            AttrsXmlParser attrsManifestXmlParser = new AttrsXmlParser(
-                    mAndroidTarget.getPath(IAndroidTarget.MANIFEST_ATTRIBUTES),
-                    attrsXmlParser);
-            attrsManifestXmlParser.preload();
-
-            Collection<ViewClassInfo> mainList = new ArrayList<ViewClassInfo>();
-            Collection<ViewClassInfo> groupList = new ArrayList<ViewClassInfo>();
-
-            // collect the layout/widgets classes
-            progress.subTask("Widgets and layouts");
-            collectLayoutClasses(classLoader, attrsXmlParser, mainList, groupList,
-                    progress.newChild(40));
-            
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            ViewClassInfo[] layoutViewsInfo = mainList.toArray(new ViewClassInfo[mainList.size()]);
-            ViewClassInfo[] layoutGroupsInfo = groupList.toArray(
-                    new ViewClassInfo[groupList.size()]);
-            
-            // collect the preferences classes.
-            mainList.clear();
-            groupList.clear();
-            collectPreferenceClasses(classLoader, attrsXmlParser, mainList, groupList,
-                    progress.newChild(5));
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            ViewClassInfo[] preferencesInfo = mainList.toArray(new ViewClassInfo[mainList.size()]);
-            ViewClassInfo[] preferenceGroupsInfo = groupList.toArray(
-                    new ViewClassInfo[groupList.size()]);
-
-            Map<String, DeclareStyleableInfo> xmlMenuMap = collectMenuDefinitions(attrsXmlParser);
-            Map<String, DeclareStyleableInfo> xmlSearchableMap = collectSearchableDefinitions(
-                    attrsXmlParser);
-            Map<String, DeclareStyleableInfo> manifestMap = collectManifestDefinitions(
-                                                                            attrsManifestXmlParser);
-            Map<String, Map<String, Integer>> enumValueMap = attrsXmlParser.getEnumFlagValues();
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-            
-            // From the information that was collected, create the pieces that will be put in
-            // the PlatformData object.
-            AndroidManifestDescriptors manifestDescriptors = new AndroidManifestDescriptors(); 
-            manifestDescriptors.updateDescriptors(manifestMap);
-            progress.worked(10);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            LayoutDescriptors layoutDescriptors = new LayoutDescriptors();
-            layoutDescriptors.updateDescriptors(layoutViewsInfo, layoutGroupsInfo);
-            progress.worked(10);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            MenuDescriptors menuDescriptors = new MenuDescriptors();
-            menuDescriptors.updateDescriptors(xmlMenuMap);
-            progress.worked(10);
-
-            if (progress.isCanceled()) {
-                return Status.CANCEL_STATUS;
-            }
-
-            XmlDescriptors xmlDescriptors = new XmlDescriptors();
-            xmlDescriptors.updateDescriptors(xmlSearchableMap, preferencesInfo,
-                    preferenceGroupsInfo);
-            progress.worked(10);
-            
-            // load the framework resources.
-            ProjectResources resources = ResourceManager.getInstance().loadFrameworkResources(
-                    mAndroidTarget);
-            progress.worked(10);
-            
-            // now load the layout lib bridge
-            LayoutBridge layoutBridge = loadLayoutBridge();
-            progress.worked(10);
-            
-            // and finally create the PlatformData with all that we loaded.
-            targetData.setExtraData(frameworkRepository,
-                    manifestDescriptors,
-                    layoutDescriptors,
-                    menuDescriptors,
-                    xmlDescriptors,
-                    enumValueMap,
-                    permissionValues,
-                    activity_actions.toArray(new String[activity_actions.size()]),
-                    broadcast_actions.toArray(new String[broadcast_actions.size()]),
-                    service_actions.toArray(new String[service_actions.size()]),
-                    categories.toArray(new String[categories.size()]),
-                    resources,
-                    layoutBridge);
-            
-            Sdk.getCurrent().setTargetData(mAndroidTarget, targetData);
-
-            return Status.OK_STATUS;
-        } catch (Exception e) {
-            AdtPlugin.logAndPrintError(e, TAG, "SDK parser failed"); //$NON-NLS-1$
-            AdtPlugin.printToConsole("SDK parser failed", e.getMessage());
-            return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID, "SDK parser failed", e);
-        } finally {
-            if (monitor != null) {
-                monitor.done();
-            }
-        }
-    }
-
-    /**
-     * Preloads all "interesting" classes from the framework SDK jar.
-     * <p/>
-     * Currently this preloads all classes from the framework jar
-     * 
-     * @param classLoader The framework SDK jar classloader
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     */
-    private void preload(AndroidJarLoader classLoader, IProgressMonitor monitor) {
-        try {
-            classLoader.preLoadClasses("" /* all classes */,        //$NON-NLS-1$
-                    mAndroidTarget.getName(),                       // monitor task label
-                    monitor);
-        } catch (InvalidAttributeValueException e) {
-            AdtPlugin.log(e, "Problem preloading classes"); //$NON-NLS-1$
-        } catch (IOException e) {
-            AdtPlugin.log(e, "Problem preloading classes"); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Creates an IResourceRepository for the framework resources.
-     * 
-     * @param classLoader The framework SDK jar classloader
-     * @return a map of the resources, or null if it failed.
-     */
-    private IResourceRepository collectResourceIds(
-            AndroidJarLoader classLoader) {
-        try {
-            Class<?> r = classLoader.loadClass(AndroidConstants.CLASS_R);
-            
-            if (r != null) {
-                Map<ResourceType, List<ResourceItem>> map = parseRClass(r);
-                if (map != null) {
-                    return new FrameworkResourceRepository(map);
-                }
-            }
-        } catch (ClassNotFoundException e) {
-            AdtPlugin.logAndPrintError(e, TAG,
-                    "Collect resource IDs failed, class %1$s not found in %2$s", //$NON-NLS-1$
-                    AndroidConstants.CLASS_R, 
-                    mAndroidTarget.getPath(IAndroidTarget.ANDROID_JAR));
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Parse the R class and build the resource map.
-     * 
-     * @param rClass the Class object representing the Resources.
-     * @return a map of the resource or null
-     */
-    private Map<ResourceType, List<ResourceItem>> parseRClass(Class<?> rClass) {
-        // get the sub classes.
-        Class<?>[] classes = rClass.getClasses();
-        
-        if (classes.length > 0) {
-            HashMap<ResourceType, List<ResourceItem>> map =
-                new HashMap<ResourceType, List<ResourceItem>>();
-
-            // get the fields of each class.
-            for (int c = 0 ; c < classes.length ; c++) {
-                Class<?> subClass = classes[c];
-                String name = subClass.getSimpleName();
-                
-                // get the matching ResourceType
-                ResourceType type = ResourceType.getEnum(name);
-                if (type != null) {
-                    List<ResourceItem> list = new ArrayList<ResourceItem>();
-                    map.put(type, list);
-                    
-                    Field[] fields = subClass.getFields();
-                    
-                    for (Field f : fields) {
-                        list.add(new ResourceItem(f.getName()));
-                    }
-                }
-            }
-            
-            return map;
-        }
-        
-        return null;
-    }
-
-    /**
-     * Loads, collects and returns the list of default permissions from the framework.
-     * 
-     * @param classLoader The framework SDK jar classloader
-     * @return a non null (but possibly empty) array containing the permission values.
-     */
-    private String[] collectPermissions(AndroidJarLoader classLoader) {
-        try {
-            Class<?> permissionClass =
-                classLoader.loadClass(AndroidConstants.CLASS_MANIFEST_PERMISSION);
-            
-            if (permissionClass != null) {
-                ArrayList<String> list = new ArrayList<String>();
-
-                Field[] fields = permissionClass.getFields();
-                
-                for (Field f : fields) {
-                    int modifiers = f.getModifiers();
-                    if (Modifier.isStatic(modifiers) && Modifier.isFinal(modifiers) &&
-                            Modifier.isPublic(modifiers)) {
-                        try {
-                            Object value = f.get(null);
-                            if (value instanceof String) {
-                                list.add((String)value);
-                            }
-                        } catch (IllegalArgumentException e) {
-                            // since we provide null this should not happen
-                        } catch (IllegalAccessException e) {
-                            // if the field is inaccessible we ignore it.
-                        } catch (NullPointerException npe) {
-                            // looks like this is not a static field. we can ignore.
-                        } catch (ExceptionInInitializerError  eiie) {
-                            // lets just ignore the field again
-                        }
-                    }
-                }
-                
-                return list.toArray(new String[list.size()]);
-            }
-        } catch (ClassNotFoundException e) {
-            AdtPlugin.logAndPrintError(e, TAG,
-                    "Collect permissions failed, class %1$s not found in %2$s", //$NON-NLS-1$
-                    AndroidConstants.CLASS_MANIFEST_PERMISSION, 
-                    mAndroidTarget.getPath(IAndroidTarget.ANDROID_JAR));
-        }
-        
-        return new String[0];
-    }
-    
-    /**
-     * Loads and collects the action and category default values from the framework.
-     * The values are added to the <code>actions</code> and <code>categories</code> lists.
-     * 
-     * @param activityActions the list which will receive the activity action values.
-     * @param broadcastActions the list which will receive the broadcast action values.
-     * @param serviceActions the list which will receive the service action values.
-     * @param categories the list which will receive the category values.
-     */
-    private void collectIntentFilterActionsAndCategories(ArrayList<String> activityActions,
-            ArrayList<String> broadcastActions,
-            ArrayList<String> serviceActions, ArrayList<String> categories)  {
-        collectValues(mAndroidTarget.getPath(IAndroidTarget.ACTIONS_ACTIVITY),
-                activityActions);
-        collectValues(mAndroidTarget.getPath(IAndroidTarget.ACTIONS_BROADCAST),
-                broadcastActions);
-        collectValues(mAndroidTarget.getPath(IAndroidTarget.ACTIONS_SERVICE),
-                serviceActions);
-        collectValues(mAndroidTarget.getPath(IAndroidTarget.CATEGORIES),
-                categories);
-    }
-
-    /**
-     * Collects values from a text file located in the SDK
-     * @param osFilePath The path to the text file.
-     * @param values the {@link ArrayList} to fill with the values.
-     */
-    private void collectValues(String osFilePath, ArrayList<String> values) {
-        FileReader fr = null;
-        BufferedReader reader = null;
-        try {
-            fr = new FileReader(osFilePath);
-            reader = new BufferedReader(fr);
-
-            String line;
-            while ((line = reader.readLine()) != null) {
-                line = line.trim();
-                if (line.length() > 0 && line.startsWith("#") == false) { //$NON-NLS-1$
-                    values.add(line);
-                }
-            }
-        } catch (IOException e) {
-            AdtPlugin.log(e, "Failed to read SDK values"); //$NON-NLS-1$
-        } finally {
-            try {
-                if (reader != null) {
-                    reader.close();
-                }
-            } catch (IOException e) {
-                AdtPlugin.log(e, "Failed to read SDK values"); //$NON-NLS-1$
-            }
-
-            try {
-                if (fr != null) {
-                    fr.close();
-                }
-            } catch (IOException e) {
-                AdtPlugin.log(e, "Failed to read SDK values"); //$NON-NLS-1$
-            }
-        }
-    }
-
-    /**
-     * Collects all layout classes information from the class loader and the
-     * attrs.xml and sets the corresponding structures in the resource manager.
-     * 
-     * @param classLoader The framework SDK jar classloader in case we cannot get the widget from
-     * the platform directly
-     * @param attrsXmlParser The parser of the attrs.xml file
-     * @param mainList the Collection to receive the main list of {@link ViewClassInfo}.
-     * @param groupList the Collection to receive the group list of {@link ViewClassInfo}.
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     */
-    private void collectLayoutClasses(AndroidJarLoader classLoader,
-            AttrsXmlParser attrsXmlParser,
-            Collection<ViewClassInfo> mainList, Collection<ViewClassInfo> groupList, 
-            IProgressMonitor monitor) {
-        LayoutParamsParser ldp = null;
-        try {
-            WidgetClassLoader loader = new WidgetClassLoader(
-                    mAndroidTarget.getPath(IAndroidTarget.WIDGETS));
-            if (loader.parseWidgetList(monitor)) {
-                ldp = new LayoutParamsParser(loader, attrsXmlParser);
-            }
-            // if the parsing failed, we'll use the old loader below.
-        } catch (FileNotFoundException e) {
-            AdtPlugin.log(e, "Android Framework Parser"); //$NON-NLS-1$
-            // the file does not exist, we'll use the old loader below.
-        }
-
-        if (ldp == null) {
-            ldp = new LayoutParamsParser(classLoader, attrsXmlParser);
-        }
-        ldp.parseLayoutClasses(monitor);
-        
-        List<ViewClassInfo> views = ldp.getViews();
-        List<ViewClassInfo> groups = ldp.getGroups();
-
-        if (views != null && groups != null) {
-            mainList.addAll(views);
-            groupList.addAll(groups);
-        }
-    }
-
-    /**
-     * Collects all preferences definition information from the attrs.xml and
-     * sets the corresponding structures in the resource manager.
-     * 
-     * @param classLoader The framework SDK jar classloader
-     * @param attrsXmlParser The parser of the attrs.xml file
-     * @param mainList the Collection to receive the main list of {@link ViewClassInfo}.
-     * @param groupList the Collection to receive the group list of {@link ViewClassInfo}.
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     */
-    private void collectPreferenceClasses(AndroidJarLoader classLoader,
-            AttrsXmlParser attrsXmlParser, Collection<ViewClassInfo> mainList,
-            Collection<ViewClassInfo> groupList, IProgressMonitor monitor) {
-        LayoutParamsParser ldp = new LayoutParamsParser(classLoader, attrsXmlParser);
-        
-        try {
-            ldp.parsePreferencesClasses(monitor);
-            
-            List<ViewClassInfo> prefs = ldp.getViews();
-            List<ViewClassInfo> groups = ldp.getGroups();
-    
-            if (prefs != null && groups != null) {
-                mainList.addAll(prefs);
-                groupList.addAll(groups);
-            }
-        } catch (NoClassDefFoundError e) {
-            AdtPlugin.logAndPrintError(e, TAG,
-                    "Collect preferences failed, class %1$s not found in %2$s",
-                    e.getMessage(), 
-                    classLoader.getSource());
-        } catch (Throwable e) {
-            AdtPlugin.log(e, "Android Framework Parser: failed to collect preference classes"); //$NON-NLS-1$
-            AdtPlugin.printErrorToConsole("Android Framework Parser",
-                    "failed to collect preference classes");
-        }
-    }
-
-    /**
-     * Collects all menu definition information from the attrs.xml and returns it.
-     * 
-     * @param attrsXmlParser The parser of the attrs.xml file
-     */
-    private Map<String, DeclareStyleableInfo> collectMenuDefinitions(
-            AttrsXmlParser attrsXmlParser) {
-        Map<String, DeclareStyleableInfo> map = attrsXmlParser.getDeclareStyleableList();
-        Map<String, DeclareStyleableInfo> map2 = new HashMap<String, DeclareStyleableInfo>();
-        for (String key : new String[] { "Menu",        //$NON-NLS-1$
-                                         "MenuItem",        //$NON-NLS-1$
-                                         "MenuGroup" }) {   //$NON-NLS-1$
-            if (map.containsKey(key)) {
-                map2.put(key, map.get(key));
-            } else {
-                AdtPlugin.log(IStatus.WARNING,
-                        "Menu declare-styleable %1$s not found in file %2$s", //$NON-NLS-1$
-                        key, attrsXmlParser.getOsAttrsXmlPath());
-                AdtPlugin.printErrorToConsole("Android Framework Parser", 
-                        String.format("Menu declare-styleable %1$s not found in file %2$s", //$NON-NLS-1$
-                        key, attrsXmlParser.getOsAttrsXmlPath()));
-            }
-        }
-        
-        return Collections.unmodifiableMap(map2);
-    }
-
-    /**
-     * Collects all searchable definition information from the attrs.xml and returns it.
-     * 
-     * @param attrsXmlParser The parser of the attrs.xml file
-     */
-    private Map<String, DeclareStyleableInfo> collectSearchableDefinitions(
-            AttrsXmlParser attrsXmlParser) {
-        Map<String, DeclareStyleableInfo> map = attrsXmlParser.getDeclareStyleableList();
-        Map<String, DeclareStyleableInfo> map2 = new HashMap<String, DeclareStyleableInfo>();
-        for (String key : new String[] { "Searchable",              //$NON-NLS-1$
-                                         "SearchableActionKey" }) { //$NON-NLS-1$
-            if (map.containsKey(key)) {
-                map2.put(key, map.get(key));
-            } else {
-                AdtPlugin.log(IStatus.WARNING,
-                        "Searchable declare-styleable %1$s not found in file %2$s", //$NON-NLS-1$
-                        key, attrsXmlParser.getOsAttrsXmlPath());
-                AdtPlugin.printErrorToConsole("Android Framework Parser",
-                        String.format("Searchable declare-styleable %1$s not found in file %2$s", //$NON-NLS-1$
-                        key, attrsXmlParser.getOsAttrsXmlPath()));
-            }
-        }
-
-        return Collections.unmodifiableMap(map2);
-    }
-
-    /**
-     * Collects all manifest definition information from the attrs_manifest.xml and returns it.
-     */
-    private Map<String, DeclareStyleableInfo> collectManifestDefinitions(
-            AttrsXmlParser attrsXmlParser) {
-
-        return attrsXmlParser.getDeclareStyleableList();
-    }
-
-    /**
-     * Loads the layout bridge from the dynamically loaded layoutlib.jar
-     */
-    private LayoutBridge loadLayoutBridge() {
-        LayoutBridge layoutBridge = new LayoutBridge();
-
-        try {
-            // get the URL for the file.
-            File f = new File(mAndroidTarget.getPath(IAndroidTarget.LAYOUT_LIB));
-            if (f.isFile() == false) {
-                AdtPlugin.log(IStatus.ERROR, "layoutlib.jar is missing!"); //$NON-NLS-1$
-            } else {
-                URL url = f.toURL();
-                
-                // create a class loader. Because this jar reference interfaces
-                // that are in the editors plugin, it's important to provide 
-                // a parent class loader.
-                layoutBridge.classLoader = new URLClassLoader(new URL[] { url },
-                        this.getClass().getClassLoader());
-   
-                // load the class
-                Class<?> clazz = layoutBridge.classLoader.loadClass(AndroidConstants.CLASS_BRIDGE);
-                if (clazz != null) {
-                    // instantiate an object of the class.
-                    Constructor<?> constructor = clazz.getConstructor();
-                    if (constructor != null) {
-                        Object bridge = constructor.newInstance();
-                        if (bridge instanceof ILayoutBridge) {
-                            layoutBridge.bridge = (ILayoutBridge)bridge;
-                        }
-                    }
-                }
-                
-                if (layoutBridge.bridge == null) {
-                    layoutBridge.status = LoadStatus.FAILED;
-                    AdtPlugin.log(IStatus.ERROR, "Failed to load " + AndroidConstants.CLASS_BRIDGE); //$NON-NLS-1$
-                } else {
-                    layoutBridge.status = LoadStatus.LOADED;
-                }
-            }
-        } catch (Throwable t) {
-            layoutBridge.status = LoadStatus.FAILED;
-            // log the error.
-            AdtPlugin.log(t, "Failed to load the LayoutLib");
-        }
-        
-        return layoutBridge;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/FrameworkResourceRepository.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/FrameworkResourceRepository.java
deleted file mode 100644
index f4b10df..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/FrameworkResourceRepository.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Implementation of the {@link IResourceRepository} interface to hold the system resource Ids
- * parsed by {@link AndroidTargetParser}. 
- */
-final class FrameworkResourceRepository implements IResourceRepository {
-    
-    private Map<ResourceType, List<ResourceItem>> mResourcesMap; 
-    
-    public FrameworkResourceRepository(Map<ResourceType, List<ResourceItem>> systemResourcesMap) {
-        mResourcesMap = systemResourcesMap;
-    }
-
-    public ResourceType[] getAvailableResourceTypes() {
-        if (mResourcesMap != null) {
-            Set<ResourceType> types = mResourcesMap.keySet();
-
-            if (types != null) {
-                return types.toArray(new ResourceType[types.size()]);
-            }
-        }
-
-        return null;
-    }
-
-    public ResourceItem[] getResources(ResourceType type) {
-        if (mResourcesMap != null) {
-            List<ResourceItem> items = mResourcesMap.get(type);
-
-            if (items != null) {
-                return items.toArray(new ResourceItem[items.size()]);
-            }
-        }
-
-        return null;
-    }
-
-    public boolean hasResources(ResourceType type) {
-        if (mResourcesMap != null) {
-            List<ResourceItem> items = mResourcesMap.get(type);
-
-            return (items != null && items.size() > 0);
-        }
-
-        return false;
-    }
-
-    public boolean isSystemRepository() {
-        return true;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/IAndroidClassLoader.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/IAndroidClassLoader.java
deleted file mode 100644
index 35057d1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/IAndroidClassLoader.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashMap;
-
-import javax.management.InvalidAttributeValueException;
-
-/**
- * Classes which implements this interface provide methods to access framework resource
- * data loaded from the SDK.
- */
-public interface IAndroidClassLoader {
-    
-    /**
-     * Classes which implement this interface provide methods to describe a class.
-     */
-    public interface IClassDescriptor {
-
-        String getCanonicalName();
-
-        IClassDescriptor getSuperclass();
-
-        String getSimpleName();
-
-        IClassDescriptor getEnclosingClass();
-
-        IClassDescriptor[] getDeclaredClasses();
-        
-        boolean isInstantiable();
-    }
-
-    /**
-     * Finds and loads all classes that derive from a given set of super classes.
-     * 
-     * @param rootPackage Root package of classes to find. Use an empty string to find everyting.
-     * @param superClasses The super classes of all the classes to find. 
-     * @return An hash map which keys are the super classes looked for and which values are
-     *         ArrayList of the classes found. The array lists are always created for all the
-     *         valid keys, they are simply empty if no deriving class is found for a given
-     *         super class. 
-     * @throws IOException
-     * @throws InvalidAttributeValueException
-     * @throws ClassFormatError
-     */
-    public HashMap<String, ArrayList<IClassDescriptor>> findClassesDerivingFrom(
-            String rootPackage, String[] superClasses)
-        throws IOException, InvalidAttributeValueException, ClassFormatError;
-
-    /**
-     * Returns a {@link IClassDescriptor} by its fully-qualified name.
-     * @param className the fully-qualified name of the class to return.
-     * @throws ClassNotFoundException
-     */
-    public IClassDescriptor getClass(String className) throws ClassNotFoundException;
-
-    /**
-     * Returns a string indicating the source of the classes, typically for debugging
-     * or in error messages. This would typically be a JAR file name or some kind of
-     * identifier that would mean something to the user when looking at error messages.
-     * 
-     * @return An informal string representing the source of the classes.
-     */
-    public String getSource();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LayoutParamsParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LayoutParamsParser.java
deleted file mode 100644
index dc600d7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LayoutParamsParser.java
+++ /dev/null
@@ -1,372 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.IAndroidClassLoader.IClassDescriptor;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.AttrsXmlParser;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.common.resources.ViewClassInfo.LayoutParamsInfo;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.SubMonitor;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-import java.util.SortedMap;
-import java.util.TreeMap;
-
-import javax.management.InvalidAttributeValueException;
-
-/*
- * TODO: refactor this. Could use some cleanup.
- */
-
-/**
- * Parser for the framework library.
- * <p/>
- * This gather the following information:
- * <ul>
- * <li>Resource ID from <code>android.R</code></li>
- * <li>The list of permissions values from <code>android.Manifest$permission</code></li>
- * <li></li>
- * </ul> 
- */
-public class LayoutParamsParser {
-    
-    /**
-     * Class extending {@link ViewClassInfo} by adding the notion of instantiability.
-     * {@link LayoutParamsParser#getViews()} and {@link LayoutParamsParser#getGroups()} should
-     * only return classes that can be instantiated.
-     */
-    final static class ExtViewClassInfo extends ViewClassInfo {
-
-        private boolean mIsInstantiable;
-
-        ExtViewClassInfo(boolean instantiable, boolean isLayout, String canonicalClassName,
-                String shortClassName) {
-            super(isLayout, canonicalClassName, shortClassName);
-            mIsInstantiable = instantiable;
-        }
-        
-        boolean isInstantiable() {
-            return mIsInstantiable;
-        }
-    }
-    
-    /* Note: protected members/methods are overridden in unit tests */
-    
-    /** Reference to android.view.View */
-    protected IClassDescriptor mTopViewClass;
-    /** Reference to android.view.ViewGroup */
-    protected IClassDescriptor mTopGroupClass;
-    /** Reference to android.view.ViewGroup$LayoutParams */
-    protected IClassDescriptor mTopLayoutParamsClass;
-    
-    /** Input list of all classes deriving from android.view.View */
-    protected ArrayList<IClassDescriptor> mViewList;
-    /** Input list of all classes deriving from android.view.ViewGroup */
-    protected ArrayList<IClassDescriptor> mGroupList;
-    
-    /** Output map of FQCN => info on View classes */
-    protected TreeMap<String, ExtViewClassInfo> mViewMap;
-    /** Output map of FQCN => info on ViewGroup classes */
-    protected TreeMap<String, ExtViewClassInfo> mGroupMap;
-    /** Output map of FQCN => info on LayoutParams classes */
-    protected HashMap<String, LayoutParamsInfo> mLayoutParamsMap;
-    
-    /** The attrs.xml parser */
-    protected AttrsXmlParser mAttrsXmlParser;
-
-    /** The android.jar class loader */
-    protected IAndroidClassLoader mClassLoader;
-
-    /**
-     * Instantiate a new LayoutParamsParser.
-     * @param classLoader The android.jar class loader
-     * @param attrsXmlParser The parser of the attrs.xml file
-     */
-    public LayoutParamsParser(IAndroidClassLoader classLoader,
-            AttrsXmlParser attrsXmlParser) {
-        mClassLoader = classLoader;
-        mAttrsXmlParser = attrsXmlParser;
-    }
-    
-    /** Returns the map of FQCN => info on View classes */
-    public List<ViewClassInfo> getViews() {
-        return getInstantiables(mViewMap);
-    }
-
-    /** Returns the map of FQCN => info on ViewGroup classes */
-    public List<ViewClassInfo> getGroups() {
-        return getInstantiables(mGroupMap);
-    }
-    
-    /**
-     * TODO: doc here.
-     * <p/>
-     * Note: on output we should have NO dependency on {@link IClassDescriptor},
-     * otherwise we wouldn't be able to unload the class loader later.
-     * <p/>
-     * Note on Vocabulary: FQCN=Fully Qualified Class Name (e.g. "my.package.class$innerClass")
-     * @param monitor A progress monitor. Can be null. Caller is responsible for calling done.
-     */
-    public void parseLayoutClasses(IProgressMonitor monitor) {
-        parseClasses(monitor,
-                AndroidConstants.CLASS_VIEW,
-                AndroidConstants.CLASS_VIEWGROUP,
-                AndroidConstants.CLASS_VIEWGROUP_LAYOUTPARAMS);
-    }
-
-    public void parsePreferencesClasses(IProgressMonitor monitor) {
-        parseClasses(monitor,
-                AndroidConstants.CLASS_PREFERENCE,
-                AndroidConstants.CLASS_PREFERENCEGROUP,
-                null /* paramsClassName */ );
-    }
-    
-    private void parseClasses(IProgressMonitor monitor,
-            String rootClassName,
-            String groupClassName,
-            String paramsClassName) {
-        try {
-            SubMonitor progress = SubMonitor.convert(monitor, 100);
-
-            String[] superClasses = new String[2 + (paramsClassName == null ? 0 : 1)];
-            superClasses[0] = groupClassName;
-            superClasses[1] = rootClassName;
-            if (paramsClassName != null) {
-                superClasses[2] = paramsClassName;
-            }
-            HashMap<String, ArrayList<IClassDescriptor>> found =
-                    mClassLoader.findClassesDerivingFrom("android.", superClasses);
-            mTopViewClass = mClassLoader.getClass(rootClassName);
-            mTopGroupClass = mClassLoader.getClass(groupClassName);
-            if (paramsClassName != null) {
-                mTopLayoutParamsClass = mClassLoader.getClass(paramsClassName);
-            }
-
-            mViewList = found.get(rootClassName);
-            mGroupList = found.get(groupClassName);
-
-            mViewMap = new TreeMap<String, ExtViewClassInfo>();
-            mGroupMap = new TreeMap<String, ExtViewClassInfo>();
-            if (mTopLayoutParamsClass != null) {
-                mLayoutParamsMap = new HashMap<String, LayoutParamsInfo>();
-            }
-            
-            // Add top classes to the maps since by design they are not listed in classes deriving
-            // from themselves.
-            addGroup(mTopGroupClass);
-            addView(mTopViewClass);
-
-            // ViewGroup derives from View
-            mGroupMap.get(groupClassName).setSuperClass(
-                mViewMap.get(rootClassName));
-
-            progress.setWorkRemaining(mGroupList.size() + mViewList.size());
-            
-            for (IClassDescriptor groupChild : mGroupList) {
-                addGroup(groupChild);
-                progress.worked(1);
-            }
-
-            for (IClassDescriptor viewChild : mViewList) {
-                if (viewChild != mTopGroupClass) {
-                    addView(viewChild);
-                }
-                progress.worked(1);
-            }
-        } catch (ClassNotFoundException e) {
-            AdtPlugin.log(e, "Problem loading class %1$s or %2$s",  //$NON-NLS-1$
-                    rootClassName, groupClassName);
-        } catch (InvalidAttributeValueException e) {
-            AdtPlugin.log(e, "Problem loading classes"); //$NON-NLS-1$
-        } catch (ClassFormatError e) {
-            AdtPlugin.log(e, "Problem loading classes"); //$NON-NLS-1$
-        } catch (IOException e) {
-            AdtPlugin.log(e, "Problem loading classes"); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Parses a View class and adds a ExtViewClassInfo for it in mViewMap.
-     * It calls itself recursively to handle super classes which are also Views.
-     */
-    private ExtViewClassInfo addView(IClassDescriptor viewClass) {
-        String fqcn = viewClass.getCanonicalName();
-        if (mViewMap.containsKey(fqcn)) {
-            return mViewMap.get(fqcn);
-        } else if (mGroupMap.containsKey(fqcn)) {
-            return mGroupMap.get(fqcn);
-        }
-
-        ExtViewClassInfo info = new ExtViewClassInfo(viewClass.isInstantiable(),
-                false /* layout */, fqcn, viewClass.getSimpleName());
-        mViewMap.put(fqcn, info);
-
-        // All view classes derive from mTopViewClass by design.
-        // Do not lookup the super class for mTopViewClass itself.
-        if (viewClass.equals(mTopViewClass) == false) {
-            IClassDescriptor superClass = viewClass.getSuperclass(); 
-            ExtViewClassInfo superClassInfo = addView(superClass);
-            info.setSuperClass(superClassInfo);
-        }
-
-        mAttrsXmlParser.loadViewAttributes(info);
-        return info;
-    }
-
-    /**
-     * Parses a ViewGroup class and adds a ExtViewClassInfo for it in mGroupMap.
-     * It calls itself recursively to handle super classes which are also ViewGroups.
-     */
-    private ExtViewClassInfo addGroup(IClassDescriptor groupClass) {
-        String fqcn = groupClass.getCanonicalName();
-        if (mGroupMap.containsKey(fqcn)) {
-            return mGroupMap.get(fqcn);
-        }
-
-        ExtViewClassInfo info = new ExtViewClassInfo(groupClass.isInstantiable(),
-                true /* layout */, fqcn, groupClass.getSimpleName());
-        mGroupMap.put(fqcn, info);
-
-        // All groups derive from android.view.ViewGroup, which in turns derives from
-        // android.view.View (i.e. mTopViewClass here). So the only group that can have View as
-        // its super class is the ViewGroup base class and we don't try to resolve it since groups
-        // are loaded before views.
-        IClassDescriptor superClass = groupClass.getSuperclass(); 
-        
-        // Assertion: at this point, we should have
-        //   superClass != mTopViewClass || fqcn.equals(AndroidConstants.CLASS_VIEWGROUP);
-
-        if (superClass != null && superClass.equals(mTopViewClass) == false) {
-            ExtViewClassInfo superClassInfo = addGroup(superClass);
-            
-            // Assertion: we should have superClassInfo != null && superClassInfo != info;
-            if (superClassInfo != null && superClassInfo != info) {
-                info.setSuperClass(superClassInfo);
-            }
-        }
-
-        mAttrsXmlParser.loadViewAttributes(info);
-        if (mTopLayoutParamsClass != null) {
-            info.setLayoutParams(addLayoutParams(groupClass));
-        }
-        return info;
-    }
-    
-    /**
-     * Parses a ViewGroup class and returns an info object on its inner LayoutParams.
-     * 
-     * @return The {@link LayoutParamsInfo} for the ViewGroup class or null.
-     */
-    private LayoutParamsInfo addLayoutParams(IClassDescriptor groupClass) {
-
-        // Is there a LayoutParams in this group class?
-        IClassDescriptor layoutParamsClass = findLayoutParams(groupClass);
-
-        // if there's no layout data in the group class, link to the one from the
-        // super class.
-        if (layoutParamsClass == null) {
-            for (IClassDescriptor superClass = groupClass.getSuperclass();
-                    layoutParamsClass == null &&
-                        superClass != null &&
-                        superClass.equals(mTopViewClass) == false;
-                    superClass = superClass.getSuperclass()) {
-                layoutParamsClass = findLayoutParams(superClass);
-            }
-        }
-
-        if (layoutParamsClass != null) {
-            return getLayoutParamsInfo(layoutParamsClass);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Parses a LayoutParams class and returns a LayoutParamsInfo object for it.
-     * It calls itself recursively to handle the super class of the LayoutParams.
-     */
-    private LayoutParamsInfo getLayoutParamsInfo(IClassDescriptor layoutParamsClass) {
-        String fqcn = layoutParamsClass.getCanonicalName();
-        LayoutParamsInfo layoutParamsInfo = mLayoutParamsMap.get(fqcn);
-
-        if (layoutParamsInfo != null) {
-            return layoutParamsInfo;
-        }
-        
-        // Find the link on the LayoutParams super class 
-        LayoutParamsInfo superClassInfo = null;
-        if (layoutParamsClass.equals(mTopLayoutParamsClass) == false) {
-            IClassDescriptor superClass = layoutParamsClass.getSuperclass(); 
-            superClassInfo = getLayoutParamsInfo(superClass);
-        }
-        
-        // Find the link on the enclosing ViewGroup
-        ExtViewClassInfo enclosingGroupInfo = addGroup(layoutParamsClass.getEnclosingClass());
-
-        layoutParamsInfo = new ExtViewClassInfo.LayoutParamsInfo(
-                enclosingGroupInfo, layoutParamsClass.getSimpleName(), superClassInfo);
-        mLayoutParamsMap.put(fqcn, layoutParamsInfo);
-
-        mAttrsXmlParser.loadLayoutParamsAttributes(layoutParamsInfo);
-
-        return layoutParamsInfo;
-    }
-
-    /**
-     * Given a ViewGroup-derived class, looks for an inner class named LayoutParams
-     * and if found returns its class definition.
-     * <p/>
-     * This uses the actual defined inner classes and does not look at inherited classes.
-     *  
-     * @param groupClass The ViewGroup derived class
-     * @return The Class of the inner LayoutParams or null if none is declared.
-     */
-    private IClassDescriptor findLayoutParams(IClassDescriptor groupClass) {
-        IClassDescriptor[] innerClasses = groupClass.getDeclaredClasses();
-        for (IClassDescriptor innerClass : innerClasses) {
-            if (innerClass.getSimpleName().equals(AndroidConstants.CLASS_LAYOUTPARAMS)) {
-                return innerClass;
-            }
-        }
-        return null;
-    }
-    
-    /**
-     * Computes and return a list of ViewClassInfo from a map by filtering out the class that
-     * cannot be instantiated.
-     */
-    private List<ViewClassInfo> getInstantiables(SortedMap<String, ExtViewClassInfo> map) {
-        Collection<ExtViewClassInfo> values = map.values();
-        ArrayList<ViewClassInfo> list = new ArrayList<ViewClassInfo>();
-        
-        for (ExtViewClassInfo info : values) {
-            if (info.isInstantiable()) {
-                list.add(info);
-            }
-        }
-        
-        return list;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LoadStatus.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LoadStatus.java
deleted file mode 100644
index 6bf0272..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/LoadStatus.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-/**
- * Enum for loading status of various SDK parts.
- */
-public enum LoadStatus {
-    LOADING, LOADED, FAILED;
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/Sdk.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/Sdk.java
deleted file mode 100644
index c7773cc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/Sdk.java
+++ /dev/null
@@ -1,424 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.internal.AndroidClasspathContainerInitializer;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IProjectListener;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkConstants;
-import com.android.sdklib.SdkManager;
-import com.android.sdklib.avd.AvdManager;
-import com.android.sdklib.project.ApkConfigurationHelper;
-import com.android.sdklib.project.ProjectProperties;
-import com.android.sdklib.project.ProjectProperties.PropertyType;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IncrementalProjectBuilder;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * Central point to load, manipulate and deal with the Android SDK. Only one SDK can be used
- * at the same time.
- * 
- * To start using an SDK, call {@link #loadSdk(String)} which returns the instance of
- * the Sdk object.
- * 
- * To get the list of platforms or add-ons present in the SDK, call {@link #getTargets()}.
- */
-public class Sdk implements IProjectListener {
-    private static Sdk sCurrentSdk = null;
-
-    private final SdkManager mManager;
-    private final AvdManager mAvdManager;
-
-    private final HashMap<IProject, IAndroidTarget> mProjectTargetMap =
-            new HashMap<IProject, IAndroidTarget>();
-    private final HashMap<IAndroidTarget, AndroidTargetData> mTargetDataMap = 
-            new HashMap<IAndroidTarget, AndroidTargetData>();
-    private final HashMap<IProject, Map<String, String>> mProjectApkConfigMap =
-        new HashMap<IProject, Map<String, String>>();
-    private final String mDocBaseUrl;
-    
-    /**
-     * Loads an SDK and returns an {@link Sdk} object if success.
-     * @param sdkLocation the OS path to the SDK.
-     */
-    public static Sdk loadSdk(String sdkLocation) {
-        if (sCurrentSdk != null) {
-            sCurrentSdk.dispose();
-            sCurrentSdk = null;
-        }
-
-        final ArrayList<String> logMessages = new ArrayList<String>();
-        ISdkLog log = new ISdkLog() {
-            public void error(Throwable throwable, String errorFormat, Object... arg) {
-                if (errorFormat != null) {
-                    logMessages.add(String.format(errorFormat, arg));
-                }
-                
-                if (throwable != null) {
-                    logMessages.add(throwable.getMessage());
-                }
-            }
-
-            public void warning(String warningFormat, Object... arg) {
-                logMessages.add(String.format(warningFormat, arg));
-            }
-            
-            public void printf(String msgFormat, Object... arg) {
-                logMessages.add(String.format(msgFormat, arg));
-            }
-        };
-
-        // get an SdkManager object for the location
-        SdkManager manager = SdkManager.createManager(sdkLocation, log);
-        if (manager != null) {
-            AvdManager avdManager = null;
-            try {
-                avdManager = new AvdManager(manager, log);
-            } catch (AndroidLocationException e) {
-                log.error(e, "Error parsing the AVDs");
-            }
-            sCurrentSdk = new Sdk(manager, avdManager);
-            return sCurrentSdk;
-        } else {
-            StringBuilder sb = new StringBuilder("Error Loading the SDK:\n");
-            for (String msg : logMessages) {
-                sb.append('\n');
-                sb.append(msg);
-            }
-            AdtPlugin.displayError("Android SDK", sb.toString());
-        }
-        return null;
-    }
-
-    /**
-     * Returns the current {@link Sdk} object.
-     */
-    public static Sdk getCurrent() {
-        return sCurrentSdk;
-    }
-    
-    /**
-     * Returns the location (OS path) of the current SDK.
-     */
-    public String getSdkLocation() {
-        return mManager.getLocation();
-    }
-    
-    /**
-     * Returns the URL to the local documentation.
-     * Can return null if no documentation is found in the current SDK.
-     * 
-     * @return A file:// URL on the local documentation folder if it exists or null.
-     */
-    public String getDocumentationBaseUrl() {
-        return mDocBaseUrl;
-    }
-
-    /**
-     * Returns the list of targets that are available in the SDK.
-     */
-    public IAndroidTarget[] getTargets() {
-        return mManager.getTargets();
-    }
-    
-    /**
-     * Returns a target from a hash that was generated by {@link IAndroidTarget#hashString()}.
-     * 
-     * @param hash the {@link IAndroidTarget} hash string.
-     * @return The matching {@link IAndroidTarget} or null.
-     */
-    public IAndroidTarget getTargetFromHashString(String hash) {
-        return mManager.getTargetFromHashString(hash);
-    }
-    
-    /**
-     * Associates an {@link IProject} and an {@link IAndroidTarget}.
-     */
-    public void setProject(IProject project, IAndroidTarget target) {
-        synchronized (mProjectTargetMap) {
-            // look for the current target of the project
-            IAndroidTarget previousTarget = mProjectTargetMap.get(project);
-            
-            if (target != previousTarget) {
-                // save the target hash string in the project persistent property
-                setProjectTargetHashString(project, target.hashString());
-                
-                // put it in a local map for easy access.
-                mProjectTargetMap.put(project, target);
-
-                // recompile the project if needed.
-                IJavaProject javaProject = JavaCore.create(project);
-                AndroidClasspathContainerInitializer.updateProjects(
-                        new IJavaProject[] { javaProject });
-            }
-        }
-    }
-    
-    /**
-     * Returns the {@link IAndroidTarget} object associated with the given {@link IProject}.
-     */
-    public IAndroidTarget getTarget(IProject project) {
-        synchronized (mProjectTargetMap) {
-            IAndroidTarget target = mProjectTargetMap.get(project);
-            if (target == null) {
-                // get the value from the project persistent property.
-                String targetHashString = loadProjectProperties(project, this);
-
-                if (targetHashString != null) {
-                    target = mManager.getTargetFromHashString(targetHashString);
-                }
-            }
-
-            return target;
-        }
-    }
-    
-
-    /**
-     * Parses the project properties and returns the hash string uniquely identifying the
-     * target of the given project.
-     * <p/>
-     * This methods reads the content of the <code>default.properties</code> file present in
-     * the root folder of the project.
-     * <p/>The returned string is equivalent to the return of {@link IAndroidTarget#hashString()}.
-     * @param project The project for which to return the target hash string.
-     * @param sdkStorage The sdk in which to store the Apk Configs. Can be null. 
-     * @return the hash string or null if the project does not have a target set.
-     */
-    private static String loadProjectProperties(IProject project, Sdk sdkStorage) {
-        // load the default.properties from the project folder.
-        ProjectProperties properties = ProjectProperties.load(project.getLocation().toOSString(),
-                PropertyType.DEFAULT);
-        if (properties == null) {
-            AdtPlugin.log(IStatus.ERROR, "Failed to load properties file for project '%s'",
-                    project.getName());
-            return null;
-        }
-        
-        if (sdkStorage != null) {
-            Map<String, String> configMap = ApkConfigurationHelper.getConfigs(properties);
-            
-            if (configMap.size() > 0) {
-                sdkStorage.mProjectApkConfigMap.put(project, configMap);
-            }
-        }
-        
-        return properties.getProperty(ProjectProperties.PROPERTY_TARGET);
-    }
-    
-    /**
-     * Returns the hash string uniquely identifying the target of a project.
-     * <p/>
-     * This methods reads the content of the <code>default.properties</code> file present in
-     * the root folder of the project.
-     * <p/>The string is equivalent to the return of {@link IAndroidTarget#hashString()}.
-     * @param project The project for which to return the target hash string.
-     * @return the hash string or null if the project does not have a target set.
-     */
-    public static String getProjectTargetHashString(IProject project) {
-        return loadProjectProperties(project, null /*storeConfigs*/);
-    }
-
-    /**
-     * Sets a target hash string in given project's <code>default.properties</code> file.
-     * @param project The project in which to save the hash string.
-     * @param targetHashString The target hash string to save. This must be the result from
-     * {@link IAndroidTarget#hashString()}.
-     */
-    public static void setProjectTargetHashString(IProject project, String targetHashString) {
-        // because we don't want to erase other properties from default.properties, we first load
-        // them
-        ProjectProperties properties = ProjectProperties.load(project.getLocation().toOSString(),
-                PropertyType.DEFAULT);
-        if (properties == null) {
-            // doesn't exist yet? we create it.
-            properties = ProjectProperties.create(project.getLocation().toOSString(),
-                    PropertyType.DEFAULT);
-        }
-        
-        // add/change the target hash string.
-        properties.setProperty(ProjectProperties.PROPERTY_TARGET, targetHashString);
-        
-        // and rewrite the file.
-        try {
-            properties.save();
-        } catch (IOException e) {
-            AdtPlugin.log(e, "Failed to save default.properties for project '%s'",
-                    project.getName());
-        }
-    }
-    /**
-     * Return the {@link AndroidTargetData} for a given {@link IAndroidTarget}.
-     */
-    public AndroidTargetData getTargetData(IAndroidTarget target) {
-        synchronized (mTargetDataMap) {
-            return mTargetDataMap.get(target);
-        }
-    }
-    
-    /**
-     * Returns the configuration map for a given project.
-     * <p/>The Map key are name to be used in the apk filename, while the values are comma separated
-     * config values. The config value can be passed directly to aapt through the -c option.
-     */
-    public Map<String, String> getProjectApkConfigs(IProject project) {
-        return mProjectApkConfigMap.get(project);
-    }
-    
-    public void setProjectApkConfigs(IProject project, Map<String, String> configMap)
-            throws CoreException {
-        // first set the new map
-        mProjectApkConfigMap.put(project, configMap);
-        
-        // Now we write this in default.properties.
-        // Because we don't want to erase other properties from default.properties, we first load
-        // them
-        ProjectProperties properties = ProjectProperties.load(project.getLocation().toOSString(),
-                PropertyType.DEFAULT);
-        if (properties == null) {
-            // doesn't exist yet? we create it.
-            properties = ProjectProperties.create(project.getLocation().toOSString(),
-                    PropertyType.DEFAULT);
-        }
-        
-        // sets the configs in the property file.
-        boolean hasRemovedConfig = ApkConfigurationHelper.setConfigs(properties, configMap);
-
-        // and rewrite the file.
-        try {
-            properties.save();
-        } catch (IOException e) {
-            AdtPlugin.log(e, "Failed to save default.properties for project '%s'",
-                    project.getName());
-        }
-
-        // we're done, force a rebuild. If there was removed config, we clean instead of build
-        // (to remove the obsolete ap_ and apk file from removed configs). 
-        project.build(hasRemovedConfig ?
-                IncrementalProjectBuilder.CLEAN_BUILD : IncrementalProjectBuilder.FULL_BUILD,
-                null);
-    }
-
-    /**
-     * Returns the {@link AvdManager}. If the AvdManager failed to parse the AVD folder, this could
-     * be <code>null</code>.
-     */
-    public AvdManager getAvdManager() {
-        return mAvdManager;
-    }
-    
-    private Sdk(SdkManager manager, AvdManager avdManager) {
-        mManager = manager;
-        mAvdManager = avdManager;
-        
-        // listen to projects closing
-        ResourceMonitor monitor = ResourceMonitor.getMonitor();
-        monitor.addProjectListener(this);
-        
-        // pre-compute some paths
-        mDocBaseUrl = getDocumentationBaseUrl(mManager.getLocation() +
-                SdkConstants.OS_SDK_DOCS_FOLDER);
-    }
-
-    /**
-     *  Cleans and unloads the SDK.
-     */
-    private void dispose() {
-        ResourceMonitor.getMonitor().removeProjectListener(this);
-    }
-    
-    void setTargetData(IAndroidTarget target, AndroidTargetData data) {
-        synchronized (mTargetDataMap) {
-            mTargetDataMap.put(target, data);
-        }
-    }
-    
-    /**
-     * Returns the URL to the local documentation.
-     * Can return null if no documentation is found in the current SDK.
-     * 
-     * @param osDocsPath Path to the documentation folder in the current SDK.
-     *  The folder may not actually exist.
-     * @return A file:// URL on the local documentation folder if it exists or null.
-     */
-    private String getDocumentationBaseUrl(String osDocsPath) {
-        File f = new File(osDocsPath);
-
-        if (f.isDirectory()) {
-            try {
-                // Note: to create a file:// URL, one would typically use something like
-                // f.toURI().toURL().toString(). However this generates a broken path on
-                // Windows, namely "C:\\foo" is converted to "file:/C:/foo" instead of
-                // "file:///C:/foo" (i.e. there should be 3 / after "file:"). So we'll
-                // do the correct thing manually.
-                
-                String path = f.getAbsolutePath();
-                if (File.separatorChar != '/') {
-                    path = path.replace(File.separatorChar, '/');
-                }
-                
-                // For some reason the URL class doesn't add the mandatory "//" after
-                // the "file:" protocol name, so it has to be hacked into the path.
-                URL url = new URL("file", null, "//" + path);  //$NON-NLS-1$ //$NON-NLS-2$
-                String result = url.toString();
-                return result;
-            } catch (MalformedURLException e) {
-                // ignore malformed URLs
-            }
-        }
-
-        return null;
-    }
-
-    public void projectClosed(IProject project) {
-        mProjectTargetMap.remove(project);
-        mProjectApkConfigMap.remove(project);
-    }
-
-    public void projectDeleted(IProject project) {
-        projectClosed(project);
-    }
-
-    public void projectOpened(IProject project) {
-        // ignore this. The project will be added to the map the first time the target needs
-        // to be resolved.
-    }
-
-    public void projectOpenedWithWorkspace(IProject project) {
-        // ignore this. The project will be added to the map the first time the target needs
-        // to be resolved.
-    }
-}
-
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/WidgetClassLoader.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/WidgetClassLoader.java
deleted file mode 100644
index 0e60f8a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/sdk/WidgetClassLoader.java
+++ /dev/null
@@ -1,334 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-
-import java.io.BufferedReader;
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.TreeMap;
-
-import javax.management.InvalidAttributeValueException;
-
-/**
- * Parser for the text file containing the list of widgets, layouts and layout params.
- * <p/>
- * The file is a straight text file containing one class per line.<br>
- * Each line is in the following format<br>
- * <code>[code][class name] [super class name] [super class name]...</code>
- * where code is a single letter (W for widget, L for layout, P for layout params), and class names
- * are the fully qualified name of the classes.
- */
-public final class WidgetClassLoader implements IAndroidClassLoader {
-    
-    /**
-     * Basic class containing the class descriptions found in the text file. 
-     */
-    private final static class ClassDescriptor implements IClassDescriptor {
-        
-        private String mName;
-        private String mSimpleName;
-        private ClassDescriptor mSuperClass;
-        private ClassDescriptor mEnclosingClass;
-        private final ArrayList<IClassDescriptor> mDeclaredClasses =
-                new ArrayList<IClassDescriptor>();
-        private boolean mIsInstantiable = false;
-
-        ClassDescriptor(String fqcn) {
-            mName = fqcn;
-            mSimpleName = getSimpleName(fqcn);
-        }
-
-        public String getCanonicalName() {
-            return mName;
-        }
-
-        public String getSimpleName() {
-            return mSimpleName;
-        }
-
-        public IClassDescriptor[] getDeclaredClasses() {
-            return mDeclaredClasses.toArray(new IClassDescriptor[mDeclaredClasses.size()]);
-        }
-
-        private void addDeclaredClass(ClassDescriptor declaredClass) {
-            mDeclaredClasses.add(declaredClass);
-        }
-
-        public IClassDescriptor getEnclosingClass() {
-            return mEnclosingClass;
-        }
-        
-        void setEnclosingClass(ClassDescriptor enclosingClass) {
-            // set the enclosing class.
-            mEnclosingClass = enclosingClass;
-            
-            // add this to the list of declared class in the enclosing class.
-            mEnclosingClass.addDeclaredClass(this);
-            
-            // finally change the name of declared class to make sure it uses the
-            // convention: package.enclosing$declared instead of package.enclosing.declared
-            mName = enclosingClass.mName + "$" + mName.substring(enclosingClass.mName.length() + 1);
-        }
-
-        public IClassDescriptor getSuperclass() {
-            return mSuperClass;
-        }
-        
-        void setSuperClass(ClassDescriptor superClass) {
-            mSuperClass = superClass;
-        }
-        
-        @Override
-        public boolean equals(Object clazz) {
-            if (clazz instanceof ClassDescriptor) {
-                return mName.equals(((ClassDescriptor)clazz).mName);
-            }
-            return super.equals(clazz);
-        }
-        
-        @Override
-        public int hashCode() {
-            return mName.hashCode();
-        }
-        
-        public boolean isInstantiable() {
-            return mIsInstantiable;
-        }
-        
-        void setInstantiable(boolean state) {
-            mIsInstantiable = state;
-        }
-        
-        private String getSimpleName(String fqcn) {
-            String[] segments = fqcn.split("\\.");
-            return segments[segments.length-1];
-        }
-    }
-
-    private BufferedReader mReader;
-
-    /** Output map of FQCN => descriptor on all classes */
-    private final Map<String, ClassDescriptor> mMap = new TreeMap<String, ClassDescriptor>();
-    /** Output map of FQCN => descriptor on View classes */
-    private final Map<String, ClassDescriptor> mWidgetMap = new TreeMap<String, ClassDescriptor>();
-    /** Output map of FQCN => descriptor on ViewGroup classes */
-    private final Map<String, ClassDescriptor> mLayoutMap = new TreeMap<String, ClassDescriptor>();
-    /** Output map of FQCN => descriptor on LayoutParams classes */
-    private final Map<String, ClassDescriptor> mLayoutParamsMap =
-        new HashMap<String, ClassDescriptor>();
-    /** File path of the source text file */
-    private String mOsFilePath;
-
-    /**
-     * Creates a loader with a given file path.
-     * @param osFilePath the OS path of the file to load.
-     * @throws FileNotFoundException if the file is not found.
-     */
-    WidgetClassLoader(String osFilePath) throws FileNotFoundException {
-        mOsFilePath = osFilePath;
-        mReader = new BufferedReader(new FileReader(osFilePath));
-    }
-
-    public String getSource() {
-        return mOsFilePath;
-    }
-    
-    /**
-     * Parses the text file and return true if the file was successfully parsed.
-     * @param monitor
-     */
-    boolean parseWidgetList(IProgressMonitor monitor) {
-        try {
-            String line;
-            while ((line = mReader.readLine()) != null) {
-                if (line.length() > 0) {
-                    char prefix = line.charAt(0);
-                    String[] classes = null;
-                    ClassDescriptor clazz = null;
-                    switch (prefix) {
-                        case 'W':
-                            classes = line.substring(1).split(" ");
-                            clazz = processClass(classes, 0, null /* map */);
-                            if (clazz != null) {
-                                clazz.setInstantiable(true);
-                                mWidgetMap.put(classes[0], clazz);
-                            }
-                            break;
-                        case 'L':
-                            classes = line.substring(1).split(" ");
-                            clazz = processClass(classes, 0, null /* map */);
-                            if (clazz != null) {
-                                clazz.setInstantiable(true);
-                                mLayoutMap.put(classes[0], clazz);
-                            }
-                            break;
-                        case 'P':
-                            classes = line.substring(1).split(" ");
-                            clazz = processClass(classes, 0, mLayoutParamsMap);
-                            if (clazz != null) {
-                                clazz.setInstantiable(true);
-                            }
-                            break;
-                        case '#':
-                            // comment, do nothing
-                            break;
-                        default:
-                                throw new IllegalArgumentException();
-                    }
-                }
-            }
-            
-            // reconciliate the layout and their layout params
-            postProcess();
-            
-            return true;
-        } catch (IOException e) {
-        } finally {
-            try {
-                mReader.close();
-            } catch (IOException e) {
-            }
-        }
-        
-        return false;
-    }
-    
-    /**
-     * Parses a View class and adds a ViewClassInfo for it in mWidgetMap.
-     * It calls itself recursively to handle super classes which are also Views.
-     * @param classes the inheritance list of the class to process.
-     * @param index the index of the class to process in the <code>classes</code> array.
-     * @param map an optional map in which to put every {@link ClassDescriptor} created.
-     */
-    private ClassDescriptor processClass(String[] classes, int index,
-            Map<String, ClassDescriptor> map) {
-        if (index >= classes.length) {
-            return null;
-        }
-        
-        String fqcn = classes[index];
-        
-        if ("java.lang.Object".equals(fqcn)) { //$NON-NLS-1$
-            return null;
-        }
-
-        // check if the ViewInfoClass has not yet been created.
-        if (mMap.containsKey(fqcn)) {
-            return mMap.get(fqcn);
-        }
-
-        // create the custom class.
-        ClassDescriptor clazz = new ClassDescriptor(fqcn);
-        mMap.put(fqcn, clazz);
-        if (map != null) {
-            map.put(fqcn, clazz);
-        }
-        
-        // get the super class
-        ClassDescriptor superClass = processClass(classes, index+1, map);
-        if (superClass != null) {
-            clazz.setSuperClass(superClass);
-        }
-        
-        return clazz;
-    }
-    
-    /**
-     * Goes through the layout params and look for the enclosed class. If the layout params
-     * has no known enclosed type it is dropped.
-     */
-    private void postProcess() {
-        Collection<ClassDescriptor> params = mLayoutParamsMap.values();
-
-        for (ClassDescriptor param : params) {
-            String fqcn = param.getCanonicalName();
-            
-            // get the enclosed name.
-            String enclosed = getEnclosedName(fqcn);
-            
-            // look for a match in the layouts. We don't use the layout map as it only contains the
-            // end classes, but in this case we also need to process the layout params for the base
-            // layout classes.
-            ClassDescriptor enclosingType = mMap.get(enclosed);
-            if (enclosingType != null) {
-                param.setEnclosingClass(enclosingType);
-                
-                // remove the class from the map, and put it back with the fixed name
-                mMap.remove(fqcn);
-                mMap.put(param.getCanonicalName(), param);
-            }
-        }
-    }
-
-    private String getEnclosedName(String fqcn) {
-        int index = fqcn.lastIndexOf('.');
-        return fqcn.substring(0, index);
-    }
-
-    /**
-     * Finds and loads all classes that derive from a given set of super classes.
-     * 
-     * @param rootPackage Root package of classes to find. Use an empty string to find everyting.
-     * @param superClasses The super classes of all the classes to find. 
-     * @return An hash map which keys are the super classes looked for and which values are
-     *         ArrayList of the classes found. The array lists are always created for all the
-     *         valid keys, they are simply empty if no deriving class is found for a given
-     *         super class. 
-     * @throws IOException
-     * @throws InvalidAttributeValueException
-     * @throws ClassFormatError
-     */
-    public HashMap<String, ArrayList<IClassDescriptor>> findClassesDerivingFrom(String rootPackage,
-            String[] superClasses) throws IOException, InvalidAttributeValueException,
-            ClassFormatError {
-        HashMap<String, ArrayList<IClassDescriptor>> map =
-                new HashMap<String, ArrayList<IClassDescriptor>>();
-        
-        ArrayList<IClassDescriptor> list = new ArrayList<IClassDescriptor>();
-        list.addAll(mWidgetMap.values());
-        map.put(AndroidConstants.CLASS_VIEW, list);
-        
-        list = new ArrayList<IClassDescriptor>();
-        list.addAll(mLayoutMap.values());
-        map.put(AndroidConstants.CLASS_VIEWGROUP, list);
-
-        list = new ArrayList<IClassDescriptor>();
-        list.addAll(mLayoutParamsMap.values());
-        map.put(AndroidConstants.CLASS_VIEWGROUP_LAYOUTPARAMS, list);
-
-        return map;
-    }
-
-    /**
-     * Returns a {@link IAndroidClassLoader.IClassDescriptor} by its fully-qualified name.
-     * @param className the fully-qualified name of the class to return.
-     * @throws ClassNotFoundException
-     */
-    public IClassDescriptor getClass(String className) throws ClassNotFoundException {
-        return mMap.get(className);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectCreationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectCreationPage.java
deleted file mode 100644
index 33ec2bc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectCreationPage.java
+++ /dev/null
@@ -1,1319 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*
- * References:
- * org.eclipse.jdt.internal.ui.wizards.JavaProjectWizard
- * org.eclipse.jdt.internal.ui.wizards.JavaProjectWizardFirstPage
- */
-
-package com.android.ide.eclipse.adt.wizards.newproject;
-
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-import com.android.sdklib.project.ProjectProperties;
-import com.android.sdklib.project.ProjectProperties.PropertyType;
-import com.android.sdkuilib.SdkTargetSelector;
-
-import org.eclipse.core.filesystem.URIUtil;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jdt.core.JavaConventions;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.osgi.util.TextProcessor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.DirectoryDialog;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Text;
-
-import java.io.File;
-import java.io.FileFilter;
-import java.net.URI;
-import java.util.regex.Pattern;
-
-/**
- * NewAndroidProjectCreationPage is a project creation page that provides the
- * following fields:
- * <ul>
- * <li> Project name
- * <li> SDK Target
- * <li> Application name
- * <li> Package name
- * <li> Activity name
- * </ul>
- * Note: this class is public so that it can be accessed from unit tests.
- * It is however an internal class. Its API may change without notice.
- * It should semantically be considered as a private final class.
- * Do not derive from this class. 
- */
-public class NewProjectCreationPage extends WizardPage {
-
-    // constants
-    /** Initial value for all name fields (project, activity, application, package). Used
-     * whenever a value is requested before controls are created. */
-    private static final String INITIAL_NAME = "";  //$NON-NLS-1$
-    /** Initial value for the Create New Project radio; False means Create From Existing would be
-     * the default.*/
-    private static final boolean INITIAL_CREATE_NEW_PROJECT = true;
-    /** Initial value for the Use Default Location check box. */
-    private static final boolean INITIAL_USE_DEFAULT_LOCATION = true;
-    /** Initial value for the Create Activity check box. */
-    private static final boolean INITIAL_CREATE_ACTIVITY = true;
-    
-
-    /** Pattern for characters accepted in a project name. Since this will be used as a
-     * directory name, we're being a bit conservative on purpose. It cannot start with a space. */
-    private static final Pattern sProjectNamePattern = Pattern.compile("^[\\w][\\w. -]*$");  //$NON-NLS-1$
-    /** Last user-browsed location, static so that it be remembered for the whole session */
-    private static String sCustomLocationOsPath = "";  //$NON-NLS-1$
-    private static boolean sAutoComputeCustomLocation = true;
-
-    private final int MSG_NONE = 0;
-    private final int MSG_WARNING = 1;
-    private final int MSG_ERROR = 2;
-    
-    private String mUserPackageName = "";       //$NON-NLS-1$
-    private String mUserActivityName = "";      //$NON-NLS-1$
-    private boolean mUserCreateActivityCheck = INITIAL_CREATE_ACTIVITY;
-    private String mSourceFolder = "";          //$NON-NLS-1$
-
-    // widgets
-    private Text mProjectNameField;
-    private Text mPackageNameField;
-    private Text mActivityNameField;
-    private Text mApplicationNameField;
-    private Button mCreateNewProjectRadio;
-    private Button mUseDefaultLocation;
-    private Label mLocationLabel;
-    private Text mLocationPathField;
-    private Button mBrowseButton;
-    private Button mCreateActivityCheck;
-    private Text mMinSdkVersionField;
-    private SdkTargetSelector mSdkTargetSelector;
-
-    private boolean mInternalLocationPathUpdate;
-    protected boolean mInternalProjectNameUpdate;
-    protected boolean mInternalApplicationNameUpdate;
-    private boolean mInternalCreateActivityUpdate;
-    private boolean mInternalActivityNameUpdate;
-    protected boolean mProjectNameModifiedByUser;
-    protected boolean mApplicationNameModifiedByUser;
-    private boolean mInternalMinSdkVersionUpdate;
-    private boolean mMinSdkVersionModifiedByUser;
-
-
-    /**
-     * Creates a new project creation wizard page.
-     *
-     * @param pageName the name of this page
-     */
-    public NewProjectCreationPage(String pageName) {
-        super(pageName);
-        setPageComplete(false);
-    }
-
-    // --- Getters used by NewProjectWizard ---
-
-    /**
-     * Returns the current project location path as entered by the user, or its
-     * anticipated initial value. Note that if the default has been returned the
-     * path in a project description used to create a project should not be set.
-     *
-     * @return the project location path or its anticipated initial value.
-     */
-    public IPath getLocationPath() {
-        return new Path(getProjectLocation());
-    }
-
-    /** Returns the value of the project name field with leading and trailing spaces removed. */
-    public String getProjectName() {
-        return mProjectNameField == null ? INITIAL_NAME : mProjectNameField.getText().trim();
-    }
-
-    /** Returns the value of the package name field with spaces trimmed. */
-    public String getPackageName() {
-        return mPackageNameField == null ? INITIAL_NAME : mPackageNameField.getText().trim();
-    }
-
-    /** Returns the value of the activity name field with spaces trimmed. */
-    public String getActivityName() {
-        return mActivityNameField == null ? INITIAL_NAME : mActivityNameField.getText().trim();
-    }
-
-    /** Returns the value of the min sdk version field with spaces trimmed. */
-    public String getMinSdkVersion() {
-        return mMinSdkVersionField == null ? "" : mMinSdkVersionField.getText().trim();
-    }
-
-    /** Returns the value of the application name field with spaces trimmed. */
-    public String getApplicationName() {
-        // Return the name of the activity as default application name.
-        return mApplicationNameField == null ? getActivityName()
-                                             : mApplicationNameField.getText().trim();
-
-    }
-
-    /** Returns the value of the "Create New Project" radio. */
-    public boolean isNewProject() {
-        return mCreateNewProjectRadio == null ? INITIAL_CREATE_NEW_PROJECT
-                                              : mCreateNewProjectRadio.getSelection();
-    }
-
-    /** Returns the value of the "Create Activity" checkbox. */
-    public boolean isCreateActivity() {
-        return mCreateActivityCheck == null ? INITIAL_CREATE_ACTIVITY
-                                              : mCreateActivityCheck.getSelection();
-    }
-
-    /** Returns the value of the Use Default Location field. */
-    public boolean useDefaultLocation() {
-        return mUseDefaultLocation == null ? INITIAL_USE_DEFAULT_LOCATION
-                                           : mUseDefaultLocation.getSelection();
-    }
-
-    /** Returns the internal source folder (for the "existing project" mode) or the default
-     * "src" constant. */
-    public String getSourceFolder() {
-        if (isNewProject() || mSourceFolder == null || mSourceFolder.length() == 0) {
-            return SdkConstants.FD_SOURCES;
-        } else {
-            return mSourceFolder;
-        }
-    }
-    
-    /** Returns the current sdk target or null if none has been selected yet. */
-    public IAndroidTarget getSdkTarget() {
-        return mSdkTargetSelector == null ? null : mSdkTargetSelector.getFirstSelected();
-    }
-
-    /**
-     * Overrides @DialogPage.setVisible(boolean) to put the focus in the project name when
-     * the dialog is made visible.
-     */
-    @Override
-    public void setVisible(boolean visible) {
-        super.setVisible(visible);
-        if (visible) {
-            mProjectNameField.setFocus();
-        }
-    }
-
-    // --- UI creation ---
-
-    /**
-     * Creates the top level control for this dialog page under the given parent
-     * composite.
-     *
-     * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
-     */
-    public void createControl(Composite parent) {
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setFont(parent.getFont());
-
-        initializeDialogUnits(parent);
-
-        composite.setLayout(new GridLayout());
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        createProjectNameGroup(composite);
-        createLocationGroup(composite);
-        createTargetGroup(composite);
-        createPropertiesGroup(composite);
-
-        // Update state the first time
-        enableLocationWidgets();
-
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setControl(composite);
-
-        // Validate. This will complain about the first empty field.
-        setPageComplete(validatePage());
-    }
-
-    /**
-     * Creates the group for the project name:
-     * [label: "Project Name"] [text field]
-     *
-     * @param parent the parent composite
-     */
-    private final void createProjectNameGroup(Composite parent) {
-        Composite group = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout();
-        layout.numColumns = 2;
-        group.setLayout(layout);
-        group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // new project label
-        Label label = new Label(group, SWT.NONE);
-        label.setText("Project name:");
-        label.setFont(parent.getFont());
-        label.setToolTipText("Name of the Eclipse project to create. It cannot be empty.");
-
-        // new project name entry field
-        mProjectNameField = new Text(group, SWT.BORDER);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        mProjectNameField.setToolTipText("Name of the Eclipse project to create. It cannot be empty.");
-        mProjectNameField.setLayoutData(data);
-        mProjectNameField.setFont(parent.getFont());
-        mProjectNameField.addListener(SWT.Modify, new Listener() {
-            public void handleEvent(Event event) {
-                if (!mInternalProjectNameUpdate) {
-                    mProjectNameModifiedByUser = true;
-                }
-                updateLocationPathField(null);
-            }
-        });
-    }
-
-
-    /**
-     * Creates the group for the Project options:
-     * [radio] Create new project
-     * [radio] Create project from existing sources
-     * [check] Use default location
-     * Location [text field] [browse button]
-     *
-     * @param parent the parent composite
-     */
-    private final void createLocationGroup(Composite parent) {
-        Group group = new Group(parent, SWT.SHADOW_ETCHED_IN);
-        // Layout has 4 columns of non-equal size
-        group.setLayout(new GridLayout());
-        group.setLayoutData(new GridData(GridData.FILL_BOTH));
-        group.setFont(parent.getFont());
-        group.setText("Contents");
-
-        mCreateNewProjectRadio = new Button(group, SWT.RADIO);
-        mCreateNewProjectRadio.setText("Create new project in workspace");
-        mCreateNewProjectRadio.setSelection(INITIAL_CREATE_NEW_PROJECT);
-        Button existing_project_radio = new Button(group, SWT.RADIO);
-        existing_project_radio.setText("Create project from existing source");
-        existing_project_radio.setSelection(!INITIAL_CREATE_NEW_PROJECT);
-
-        mUseDefaultLocation = new Button(group, SWT.CHECK);
-        mUseDefaultLocation.setText("Use default location");
-        mUseDefaultLocation.setSelection(INITIAL_USE_DEFAULT_LOCATION);
-
-        SelectionListener location_listener = new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                enableLocationWidgets();
-                extractNamesFromAndroidManifest();
-                setPageComplete(validatePage());
-            }
-        };
-
-        mCreateNewProjectRadio.addSelectionListener(location_listener);
-        existing_project_radio.addSelectionListener(location_listener);
-        mUseDefaultLocation.addSelectionListener(location_listener);
-
-        Composite location_group = new Composite(group, SWT.NONE);
-        location_group.setLayout(new GridLayout(4, /* num columns */
-                false /* columns of not equal size */));
-        location_group.setLayoutData(new GridData(GridData.FILL_BOTH));
-        location_group.setFont(parent.getFont());
-
-        mLocationLabel = new Label(location_group, SWT.NONE);
-        mLocationLabel.setText("Location:");
-
-        mLocationPathField = new Text(location_group, SWT.BORDER);
-        GridData data = new GridData(GridData.FILL, /* horizontal alignment */
-                GridData.BEGINNING, /* vertical alignment */
-                true,  /* grabExcessHorizontalSpace */
-                false, /* grabExcessVerticalSpace */
-                2,     /* horizontalSpan */
-                1);    /* verticalSpan */
-        mLocationPathField.setLayoutData(data);
-        mLocationPathField.setFont(parent.getFont());
-        mLocationPathField.addListener(SWT.Modify, new Listener() {
-           public void handleEvent(Event event) {
-               onLocationPathFieldModified();
-            }
-        });
-
-        mBrowseButton = new Button(location_group, SWT.PUSH);
-        mBrowseButton.setText("Browse...");
-        setButtonLayoutData(mBrowseButton);
-        mBrowseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                openDirectoryBrowser();
-            }
-        });
-    }
-
-    /**
-     * Creates the target group.
-     * It only contains an SdkTargetSelector.
-     */
-    private void createTargetGroup(Composite parent) {
-        Group group = new Group(parent, SWT.SHADOW_ETCHED_IN);
-        // Layout has 1 column
-        group.setLayout(new GridLayout());
-        group.setLayoutData(new GridData(GridData.FILL_BOTH));
-        group.setFont(parent.getFont());
-        group.setText("Target");
-        
-        // get the targets from the sdk
-        IAndroidTarget[] targets = null;
-        if (Sdk.getCurrent() != null) {
-            targets = Sdk.getCurrent().getTargets();
-        }
-
-        mSdkTargetSelector = new SdkTargetSelector(group, targets, false /*multi-selection*/);
-
-        // If there's only one target, select it
-        if (targets != null && targets.length == 1) {
-            mSdkTargetSelector.setSelection(targets[0]);
-        }
-        
-        mSdkTargetSelector.setSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onSdkTargetModified();
-                updateLocationPathField(null);
-                setPageComplete(validatePage());
-            }
-        });
-    }
-
-    /**
-     * Display a directory browser and update the location path field with the selected path
-     */
-    private void openDirectoryBrowser() {
-
-        String existing_dir = getLocationPathFieldValue();
-
-        // Disable the path if it doesn't exist
-        if (existing_dir.length() == 0) {
-            existing_dir = null;
-        } else {
-            File f = new File(existing_dir);
-            if (!f.exists()) {
-                existing_dir = null;
-            }
-        }
-
-        DirectoryDialog dd = new DirectoryDialog(mLocationPathField.getShell());
-        dd.setMessage("Browse for folder");
-        dd.setFilterPath(existing_dir);
-        String abs_dir = dd.open();
-
-        if (abs_dir != null) {
-            updateLocationPathField(abs_dir);
-            extractNamesFromAndroidManifest();
-            setPageComplete(validatePage());
-        }
-    }
-
-    /**
-     * Creates the group for the project properties:
-     * - Package name [text field]
-     * - Activity name [text field]
-     * - Application name [text field]
-     *
-     * @param parent the parent composite
-     */
-    private final void createPropertiesGroup(Composite parent) {
-        // package specification group
-        Group group = new Group(parent, SWT.SHADOW_ETCHED_IN);
-        GridLayout layout = new GridLayout();
-        layout.numColumns = 2;
-        group.setLayout(layout);
-        group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        group.setFont(parent.getFont());
-        group.setText("Properties");
-
-        // new application label
-        Label label = new Label(group, SWT.NONE);
-        label.setText("Application name:");
-        label.setFont(parent.getFont());
-        label.setToolTipText("Name of the Application. This is a free string. It can be empty.");
-
-        // new application name entry field
-        mApplicationNameField = new Text(group, SWT.BORDER);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        mApplicationNameField.setToolTipText("Name of the Application. This is a free string. It can be empty.");
-        mApplicationNameField.setLayoutData(data);
-        mApplicationNameField.setFont(parent.getFont());
-        mApplicationNameField.addListener(SWT.Modify, new Listener() {
-           public void handleEvent(Event event) {
-               if (!mInternalApplicationNameUpdate) {
-                   mApplicationNameModifiedByUser = true;
-               }
-           } 
-        });
-
-        // new package label
-        label = new Label(group, SWT.NONE);
-        label.setText("Package name:");
-        label.setFont(parent.getFont());
-        label.setToolTipText("Namespace of the Package to create. This must be a Java namespace with at least two components.");
-
-        // new package name entry field
-        mPackageNameField = new Text(group, SWT.BORDER);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        mPackageNameField.setToolTipText("Namespace of the Package to create. This must be a Java namespace with at least two components.");
-        mPackageNameField.setLayoutData(data);
-        mPackageNameField.setFont(parent.getFont());
-        mPackageNameField.addListener(SWT.Modify, new Listener() {
-            public void handleEvent(Event event) {
-                onPackageNameFieldModified();
-            }
-        });
-
-        // new activity label
-        mCreateActivityCheck = new Button(group, SWT.CHECK);
-        mCreateActivityCheck.setText("Create Activity:");
-        mCreateActivityCheck.setToolTipText("Specifies if you want to create a default Activity.");
-        mCreateActivityCheck.setFont(parent.getFont());
-        mCreateActivityCheck.setSelection(INITIAL_CREATE_ACTIVITY);
-        mCreateActivityCheck.addListener(SWT.Selection, new Listener() {
-            public void handleEvent(Event event) {
-                onCreateActivityCheckModified();
-                enableLocationWidgets();
-            }
-        });
-
-        // new activity name entry field
-        mActivityNameField = new Text(group, SWT.BORDER);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        mActivityNameField.setToolTipText("Name of the Activity class to create. Must be a valid Java identifier.");
-        mActivityNameField.setLayoutData(data);
-        mActivityNameField.setFont(parent.getFont());
-        mActivityNameField.addListener(SWT.Modify, new Listener() {
-            public void handleEvent(Event event) {
-                onActivityNameFieldModified();
-            }
-        });
-
-        // min sdk version label
-        label = new Label(group, SWT.NONE);
-        label.setText("Min SDK Version:");
-        label.setFont(parent.getFont());
-        label.setToolTipText("The minimum SDK version number that the application requires. Must be an integer > 0. It can be empty.");
-
-        // min sdk version entry field
-        mMinSdkVersionField = new Text(group, SWT.BORDER);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        label.setToolTipText("The minimum SDK version number that the application requires. Must be an integer > 0. It can be empty.");
-        mMinSdkVersionField.setLayoutData(data);
-        mMinSdkVersionField.setFont(parent.getFont());
-        mMinSdkVersionField.addListener(SWT.Modify, new Listener() {
-            public void handleEvent(Event event) {
-                onMinSdkVersionFieldModified();
-                setPageComplete(validatePage());
-            }
-        });
-    }
-
-
-    //--- Internal getters & setters ------------------
-
-    /** Returns the location path field value with spaces trimmed. */
-    private String getLocationPathFieldValue() {
-        return mLocationPathField == null ? "" : mLocationPathField.getText().trim();
-    }
-
-    /** Returns the current project location, depending on the Use Default Location check box. */
-    public String getProjectLocation() {
-        if (isNewProject() && useDefaultLocation()) {
-            return Platform.getLocation().toString();
-        } else {
-            return getLocationPathFieldValue();
-        }
-    }
-
-    /**
-     * Creates a project resource handle for the current project name field
-     * value.
-     * <p>
-     * This method does not create the project resource; this is the
-     * responsibility of <code>IProject::create</code> invoked by the new
-     * project resource wizard.
-     * </p>
-     *
-     * @return the new project resource handle
-     */
-    private IProject getProjectHandle() {
-        return ResourcesPlugin.getWorkspace().getRoot().getProject(getProjectName());
-    }
-
-    // --- UI Callbacks ----
-
-    /**
-     * Enables or disable the location widgets depending on the user selection:
-     * the location path is enabled when using the "existing source" mode (i.e. not new project)
-     * or in new project mode with the "use default location" turned off.
-     */
-    private void enableLocationWidgets() {
-        boolean is_new_project = isNewProject();
-        boolean use_default = useDefaultLocation();
-        boolean location_enabled = !is_new_project || !use_default;
-        boolean create_activity = isCreateActivity();
-        
-        mUseDefaultLocation.setEnabled(is_new_project);
-
-        mLocationLabel.setEnabled(location_enabled);
-        mLocationPathField.setEnabled(location_enabled);
-        mBrowseButton.setEnabled(location_enabled);
-
-        mPackageNameField.setEnabled(is_new_project);
-        mCreateActivityCheck.setEnabled(is_new_project);
-        mActivityNameField.setEnabled(is_new_project & create_activity);
-
-        updateLocationPathField(null);
-        updatePackageAndActivityFields();
-    }
-
-    /**
-     * Updates the location directory path field.
-     * <br/>
-     * When custom user selection is enabled, use the abs_dir argument if not null and also
-     * save it internally. If abs_dir is null, restore the last saved abs_dir. This allows the
-     * user selection to be remembered when the user switches from default to custom.
-     * <br/>
-     * When custom user selection is disabled, use the workspace default location with the
-     * current project name. This does not change the internally cached abs_dir.
-     *
-     * @param abs_dir A new absolute directory path or null to use the default.
-     */
-    private void updateLocationPathField(String abs_dir) {
-        boolean is_new_project = isNewProject();
-        boolean use_default = useDefaultLocation();
-        boolean custom_location = !is_new_project || !use_default;
-
-        if (!mInternalLocationPathUpdate) {
-            mInternalLocationPathUpdate = true;
-            if (custom_location) {
-                if (abs_dir != null) {
-                    // We get here if the user selected a directory with the "Browse" button.
-                    // Disable auto-compute of the custom location unless the user selected
-                    // the exact same path.
-                    sAutoComputeCustomLocation = sAutoComputeCustomLocation &&
-                                                 abs_dir.equals(sCustomLocationOsPath);
-                    sCustomLocationOsPath = TextProcessor.process(abs_dir);
-                } else  if (sAutoComputeCustomLocation ||
-                            !new File(sCustomLocationOsPath).isDirectory()) {
-                    // By default select the samples directory of the current target
-                    IAndroidTarget target = getSdkTarget();
-                    if (target != null) {
-                        sCustomLocationOsPath = target.getPath(IAndroidTarget.SAMPLES);
-                    }
-
-                    // If we don't have a target, select the base directory of the
-                    // "universal sdk". If we don't even have that, use a root drive.
-                    if (sCustomLocationOsPath == null || sCustomLocationOsPath.length() == 0) {
-                        if (Sdk.getCurrent() != null) {
-                            sCustomLocationOsPath = Sdk.getCurrent().getSdkLocation();
-                        } else {
-                            sCustomLocationOsPath = File.listRoots()[0].getAbsolutePath();
-                        }
-                    }
-                }
-                if (!mLocationPathField.getText().equals(sCustomLocationOsPath)) {
-                    mLocationPathField.setText(sCustomLocationOsPath);
-                }
-            } else {
-                String value = Platform.getLocation().append(getProjectName()).toString();
-                value = TextProcessor.process(value);
-                if (!mLocationPathField.getText().equals(value)) {
-                    mLocationPathField.setText(value);
-                }
-            }
-            setPageComplete(validatePage());
-            mInternalLocationPathUpdate = false;
-        }
-    }
-
-    /**
-     * The location path field is either modified internally (from updateLocationPathField)
-     * or manually by the user when the custom_location mode is not set.
-     *
-     * Ignore the internal modification. When modified by the user, memorize the choice and
-     * validate the page.
-     */
-    private void onLocationPathFieldModified() {
-        if (!mInternalLocationPathUpdate) {
-            // When the updates doesn't come from updateLocationPathField, it must be the user
-            // editing the field manually, in which case we want to save the value internally
-            // and we disable auto-compute of the custom location (to avoid overriding the user
-            // value)
-            String newPath = getLocationPathFieldValue();
-            sAutoComputeCustomLocation = sAutoComputeCustomLocation &&
-                                         newPath.equals(sCustomLocationOsPath);
-            sCustomLocationOsPath = newPath;
-            extractNamesFromAndroidManifest();
-            setPageComplete(validatePage());
-        }
-    }
-
-    /**
-     * The package name field is either modified internally (from extractNamesFromAndroidManifest)
-     * or manually by the user when the custom_location mode is not set.
-     *
-     * Ignore the internal modification. When modified by the user, memorize the choice and
-     * validate the page.
-     */
-    private void onPackageNameFieldModified() {
-        if (isNewProject()) {
-            mUserPackageName = getPackageName();
-            setPageComplete(validatePage());
-        }
-    }
-
-    /**
-     * The create activity checkbox is either modified internally (from
-     * extractNamesFromAndroidManifest)  or manually by the user.
-     *
-     * Ignore the internal modification. When modified by the user, memorize the choice and
-     * validate the page.
-     */
-    private void onCreateActivityCheckModified() {
-        if (isNewProject() && !mInternalCreateActivityUpdate) {
-            mUserCreateActivityCheck = isCreateActivity();
-        }
-        setPageComplete(validatePage());
-    }
-
-    /**
-     * The activity name field is either modified internally (from extractNamesFromAndroidManifest)
-     * or manually by the user when the custom_location mode is not set.
-     *
-     * Ignore the internal modification. When modified by the user, memorize the choice and
-     * validate the page.
-     */
-    private void onActivityNameFieldModified() {
-        if (isNewProject() && !mInternalActivityNameUpdate) {
-            mUserActivityName = getActivityName();
-            setPageComplete(validatePage());
-        }
-    }
-
-    /**
-     * Called when the min sdk version field has been modified.
-     * 
-     * Ignore the internal modifications. When modified by the user, try to match
-     * a target with the same API level.
-     */
-    private void onMinSdkVersionFieldModified() {
-        if (mInternalMinSdkVersionUpdate) {
-            return;
-        }
-
-        try {
-            int version = Integer.parseInt(getMinSdkVersion());
-            
-            // Before changing, compare with the currently selected one, if any.
-            // There can be multiple targets with the same sdk api version, so don't change
-            // it if it's already at the right version.
-            IAndroidTarget curr_target = getSdkTarget();
-            if (curr_target != null && curr_target.getApiVersionNumber() == version) {
-                return;
-            }
-            
-            for (IAndroidTarget target : mSdkTargetSelector.getTargets()) {
-                if (target.getApiVersionNumber() == version) {
-                    mSdkTargetSelector.setSelection(target);
-                    break;
-                }
-            }
-        } catch (NumberFormatException e) {
-            // ignore
-        }
-
-        mMinSdkVersionModifiedByUser = true;
-    }
-    
-    /**
-     * Called when an SDK target is modified.
-     * 
-     * If the minSdkVersion field hasn't been modified by the user yet, we change it
-     * to reflect the sdk api level that has just been selected.
-     */
-    private void onSdkTargetModified() {
-        IAndroidTarget target = getSdkTarget();
-        
-        if (target != null && !mMinSdkVersionModifiedByUser) {
-            mInternalMinSdkVersionUpdate = true;
-            mMinSdkVersionField.setText(Integer.toString(target.getApiVersionNumber()));
-            mInternalMinSdkVersionUpdate = false;
-        }
-    }
-
-    /**
-     * Called when the radio buttons are changed between the "create new project" and the
-     * "use existing source" mode. This reverts the fields to whatever the user manually
-     * entered before.
-     */
-    private void updatePackageAndActivityFields() {
-        if (isNewProject()) {
-            if (mUserPackageName.length() > 0 &&
-                    !mPackageNameField.getText().equals(mUserPackageName)) {
-                mPackageNameField.setText(mUserPackageName);
-            }
-
-            if (mUserActivityName.length() > 0 &&
-                    !mActivityNameField.getText().equals(mUserActivityName)) {
-                mInternalActivityNameUpdate = true;
-                mActivityNameField.setText(mUserActivityName);
-                mInternalActivityNameUpdate = false;
-            }
-            
-            if (mUserCreateActivityCheck != mCreateActivityCheck.getSelection()) {
-                mInternalCreateActivityUpdate = true;
-                mCreateActivityCheck.setSelection(mUserCreateActivityCheck);
-                mInternalCreateActivityUpdate = false;
-            }
-        }
-    }
-
-    /**
-     * Extract names from an android manifest.
-     * This is done only if the user selected the "use existing source" and a manifest xml file
-     * can actually be found in the custom user directory.
-     */
-    private void extractNamesFromAndroidManifest() {
-        if (isNewProject()) {
-            return;
-        }
-
-        String projectLocation = getProjectLocation();
-        File f = new File(projectLocation);
-        if (!f.isDirectory()) {
-            return;
-        }
-
-        Path path = new Path(f.getPath());
-        String osPath = path.append(AndroidConstants.FN_ANDROID_MANIFEST).toOSString();
-        AndroidManifestHelper manifest = new AndroidManifestHelper(osPath);
-        if (!manifest.exists()) {
-            return;
-        }
-        
-        String packageName = null;
-        String activityName = null;
-        String minSdkVersion = null;
-        try {
-            packageName = manifest.getPackageName();
-            activityName = manifest.getActivityName(1);
-            minSdkVersion = manifest.getMinSdkVersion();
-        } catch (Exception e) {
-            // ignore exceptions
-        }
-
-
-        if (packageName != null && packageName.length() > 0) {
-            mPackageNameField.setText(packageName);
-        }
-
-        if (activityName != null && activityName.length() > 0) {
-            mInternalActivityNameUpdate = true;
-            mInternalCreateActivityUpdate = true;
-            mActivityNameField.setText(activityName);
-            mCreateActivityCheck.setSelection(true);
-            mInternalCreateActivityUpdate = false;
-            mInternalActivityNameUpdate = false;
-
-            // If project name and application names are empty, use the activity
-            // name as a default. If the activity name has dots, it's a part of a
-            // package specification and only the last identifier must be used.
-            if (activityName.indexOf('.') != -1) {
-                String[] ids = activityName.split(AndroidConstants.RE_DOT);
-                activityName = ids[ids.length - 1];
-            }
-            if (mProjectNameField.getText().length() == 0 ||
-                    !mProjectNameModifiedByUser) {
-                mInternalProjectNameUpdate = true;
-                mProjectNameField.setText(activityName);
-                mInternalProjectNameUpdate = false;
-            }
-            if (mApplicationNameField.getText().length() == 0 ||
-                    !mApplicationNameModifiedByUser) {
-                mInternalApplicationNameUpdate = true;
-                mApplicationNameField.setText(activityName);
-                mInternalApplicationNameUpdate = false;
-            }
-        } else {
-            mInternalActivityNameUpdate = true;
-            mInternalCreateActivityUpdate = true;
-            mActivityNameField.setText("");  //$NON-NLS-1$
-            mCreateActivityCheck.setSelection(false);
-            mInternalCreateActivityUpdate = false;
-            mInternalActivityNameUpdate = false;
-            
-            // There is no activity name to use to fill in the project and application
-            // name. However if there's a package name, we can use this as a base.
-            if (packageName != null && packageName.length() > 0) {
-                // Package name is a java identifier, so it's most suitable for
-                // an application name.
-
-                if (mApplicationNameField.getText().length() == 0 ||
-                        !mApplicationNameModifiedByUser) {
-                    mInternalApplicationNameUpdate = true;
-                    mApplicationNameField.setText(packageName);
-                    mInternalApplicationNameUpdate = false;
-                }
-
-                // For the project name, remove any dots
-                packageName = packageName.replace('.', '_');
-                if (mProjectNameField.getText().length() == 0 ||
-                        !mProjectNameModifiedByUser) {
-                    mInternalProjectNameUpdate = true;
-                    mProjectNameField.setText(packageName);
-                    mInternalProjectNameUpdate = false;
-                }
-                
-            }
-        }
-
-        // Select the target matching the manifest's sdk or build properties, if any
-        boolean foundTarget = false;
-        
-        ProjectProperties p = ProjectProperties.create(projectLocation, null);
-        if (p != null) {
-            // Check the {build|default}.properties files if present
-            p.merge(PropertyType.BUILD).merge(PropertyType.DEFAULT);
-            String v = p.getProperty(ProjectProperties.PROPERTY_TARGET);
-            IAndroidTarget target = Sdk.getCurrent().getTargetFromHashString(v);
-            if (target != null) {
-                mSdkTargetSelector.setSelection(target);
-                foundTarget = true;
-            }
-        }
-
-        if (!foundTarget && minSdkVersion != null) {
-            try {
-                int sdkVersion = Integer.parseInt(minSdkVersion); 
-
-                for (IAndroidTarget target : mSdkTargetSelector.getTargets()) {
-                    if (target.getApiVersionNumber() == sdkVersion) {
-                        mSdkTargetSelector.setSelection(target);
-                        foundTarget = true;
-                        break;
-                    }
-                }
-            } catch(NumberFormatException e) {
-                // ignore
-            }
-        }
-        
-        if (!foundTarget) {
-            for (IAndroidTarget target : mSdkTargetSelector.getTargets()) {
-                if (projectLocation.startsWith(target.getLocation())) {
-                    mSdkTargetSelector.setSelection(target);
-                    foundTarget = true;
-                    break;
-                }
-            }
-        }
-
-        if (!foundTarget) {
-            mInternalMinSdkVersionUpdate = true;
-            mMinSdkVersionField.setText(minSdkVersion == null ? "" : minSdkVersion); //$NON-NLS-1$
-            mInternalMinSdkVersionUpdate = false;
-        }
-    }
-
-    /**
-     * Returns whether this page's controls currently all contain valid values.
-     *
-     * @return <code>true</code> if all controls are valid, and
-     *         <code>false</code> if at least one is invalid
-     */
-    protected boolean validatePage() {
-        IWorkspace workspace = ResourcesPlugin.getWorkspace();
-
-        int status = validateProjectField(workspace);
-        if ((status & MSG_ERROR) == 0) {
-            status |= validateLocationPath(workspace);
-        }
-        if ((status & MSG_ERROR) == 0) {
-            status |= validateSdkTarget();
-        }
-        if ((status & MSG_ERROR) == 0) {
-            status |= validatePackageField();
-        }
-        if ((status & MSG_ERROR) == 0) {
-            status |= validateActivityField();
-        }
-        if ((status & MSG_ERROR) == 0) {
-            status |= validateMinSdkVersionField();
-        }
-        if ((status & MSG_ERROR) == 0) {
-            status |= validateSourceFolder();
-        }
-        if (status == MSG_NONE)  {
-            setStatus(null, MSG_NONE);
-        }
-        
-        // Return false if there's an error so that the finish button be disabled.
-        return (status & MSG_ERROR) == 0;
-    }
-
-    /**
-     * Validates the project name field.
-     *
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateProjectField(IWorkspace workspace) {
-        // Validate project field
-        String projectFieldContents = getProjectName();
-        if (projectFieldContents.length() == 0) {
-            return setStatus("Project name must be specified", MSG_ERROR);
-        }
-
-        // Limit the project name to shell-agnostic characters since it will be used to
-        // generate the final package
-        if (!sProjectNamePattern.matcher(projectFieldContents).matches()) {
-            return setStatus("The project name must start with an alphanumeric characters, followed by one or more alphanumerics, digits, dots, dashes, underscores or spaces.",
-                    MSG_ERROR);
-        }
-
-        IStatus nameStatus = workspace.validateName(projectFieldContents, IResource.PROJECT);
-        if (!nameStatus.isOK()) {
-            return setStatus(nameStatus.getMessage(), MSG_ERROR);
-        }
-
-        if (getProjectHandle().exists()) {
-            return setStatus("A project with that name already exists in the workspace",
-                    MSG_ERROR);
-        }
-
-        return MSG_NONE;
-    }
-
-    /**
-     * Validates the location path field.
-     *
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateLocationPath(IWorkspace workspace) {
-        Path path = new Path(getProjectLocation());
-        if (isNewProject()) {
-            if (!useDefaultLocation()) {
-                // If not using the default value validate the location.
-                URI uri = URIUtil.toURI(path.toOSString());
-                IStatus locationStatus = workspace.validateProjectLocationURI(getProjectHandle(),
-                        uri);
-                if (!locationStatus.isOK()) {
-                    return setStatus(locationStatus.getMessage(), MSG_ERROR);
-                } else {
-                    // The location is valid as far as Eclipse is concerned (i.e. mostly not
-                    // an existing workspace project.) Check it either doesn't exist or is
-                    // a directory that is empty.
-                    File f = path.toFile();
-                    if (f.exists() && !f.isDirectory()) {
-                        return setStatus("A directory name must be specified.", MSG_ERROR);
-                    } else if (f.isDirectory()) {
-                        // However if the directory exists, we should put a warning if it is not
-                        // empty. We don't put an error (we'll ask the user again for confirmation
-                        // before using the directory.)
-                        String[] l = f.list();
-                        if (l.length != 0) {
-                            return setStatus("The selected output directory is not empty.",
-                                    MSG_WARNING);
-                        }
-                    }
-                }
-            } else {
-                // Otherwise validate the path string is not empty
-                if (getProjectLocation().length() == 0) {
-                    return setStatus("A directory name must be specified.", MSG_ERROR);
-                }
-
-                File dest = path.append(getProjectName()).toFile();
-                if (dest.exists()) {
-                    return setStatus(String.format("There is already a file or directory named \"%1$s\" in the selected location.",
-                            getProjectName()), MSG_ERROR);
-                }
-            }
-        } else {
-            // Must be an existing directory
-            File f = path.toFile();
-            if (!f.isDirectory()) {
-                return setStatus("An existing directory name must be specified.", MSG_ERROR);
-            }
-            
-            // Check there's an android manifest in the directory
-            String osPath = path.append(AndroidConstants.FN_ANDROID_MANIFEST).toOSString();
-            AndroidManifestHelper manifest = new AndroidManifestHelper(osPath);
-            if (!manifest.exists()) {
-                return setStatus(
-                        String.format("File %1$s not found in %2$s.",
-                                AndroidConstants.FN_ANDROID_MANIFEST, f.getName()),
-                                MSG_ERROR);
-            }
-
-            // Parse it and check the important fields.
-            String packageName = manifest.getPackageName();
-            if (packageName == null || packageName.length() == 0) {
-                return setStatus(
-                        String.format("No package name defined in %1$s.", osPath),
-                        MSG_ERROR);
-            }
-
-            String activityName = manifest.getActivityName(1);
-            if (activityName == null || activityName.length() == 0) {
-                // This is acceptable now as long as no activity needs to be created
-                if (isCreateActivity()) {
-                    return setStatus(
-                            String.format("No activity name defined in %1$s.", osPath),
-                            MSG_ERROR);
-                }
-            }
-            
-            // If there's already a .project, tell the user to use import instead.
-            if (path.append(".project").toFile().exists()) {  //$NON-NLS-1$
-                return setStatus("An Eclipse project already exists in this directory. Consider using File > Import > Existing Project instead.",
-                        MSG_WARNING);
-            }
-        }
-
-        return MSG_NONE;
-    }
-
-    /**
-     * Validates the sdk target choice.
-     * 
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateSdkTarget() {
-        if (getSdkTarget() == null) {
-            return setStatus("An SDK Target must be specified.", MSG_ERROR);
-        }
-        return MSG_NONE;
-    }
-
-    /**
-     * Validates the sdk target choice.
-     * 
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateMinSdkVersionField() {
-
-        // If the min sdk version is empty, it is always accepted.
-        if (getMinSdkVersion().length() == 0) {
-            return MSG_NONE;
-        }
-
-        int version = -1;
-        try {
-            // If not empty, it must be a valid integer > 0
-            version = Integer.parseInt(getMinSdkVersion());
-        } catch (NumberFormatException e) {
-            // ignore
-        }
-        
-        if (version < 1) {
-            return setStatus("Min SDK Version must be an integer > 0.", MSG_ERROR);
-        }
-                
-        if (getSdkTarget() != null && getSdkTarget().getApiVersionNumber() != version) {
-            return setStatus("The API level for the selected SDK target does not match the Min SDK version.",
-                    MSG_WARNING);
-        }
-
-        return MSG_NONE;
-    }
-
-    /**
-     * Validates the activity name field.
-     *
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateActivityField() {
-        // Disregard if not creating an activity
-        if (!isCreateActivity()) {
-            return MSG_NONE;
-        }
-
-        // Validate activity field
-        String activityFieldContents = getActivityName();
-        if (activityFieldContents.length() == 0) {
-            return setStatus("Activity name must be specified.", MSG_ERROR);
-        }
-
-        // The activity field can actually contain part of a sub-package name
-        // or it can start with a dot "." to indicates it comes from the parent package name.
-        String packageName = "";
-        int pos = activityFieldContents.lastIndexOf('.');
-        if (pos >= 0) {
-            packageName = activityFieldContents.substring(0, pos);
-            if (packageName.startsWith(".")) { //$NON-NLS-1$
-                packageName = packageName.substring(1);
-            }
-            
-            activityFieldContents = activityFieldContents.substring(pos + 1);
-        }
-        
-        // the activity field can contain a simple java identifier, or a
-        // package name or one that starts with a dot. So if it starts with a dot,
-        // ignore this dot -- the rest must look like a package name.
-        if (activityFieldContents.charAt(0) == '.') {
-            activityFieldContents = activityFieldContents.substring(1);
-        }
-        
-        // Check it's a valid activity string
-        int result = MSG_NONE;
-        IStatus status = JavaConventions.validateTypeVariableName(activityFieldContents,
-                                                            "1.5", "1.5"); //$NON-NLS-1$ $NON-NLS-2$
-        if (!status.isOK()) {
-            result = setStatus(status.getMessage(),
-                        status.getSeverity() == IStatus.ERROR ? MSG_ERROR : MSG_WARNING);
-        }
-
-        // Check it's a valid package string
-        if (result != MSG_ERROR && packageName.length() > 0) {
-            status = JavaConventions.validatePackageName(packageName,
-                                                            "1.5", "1.5"); //$NON-NLS-1$ $NON-NLS-2$
-            if (!status.isOK()) {
-                result = setStatus(status.getMessage() + " (in the activity name)",
-                            status.getSeverity() == IStatus.ERROR ? MSG_ERROR : MSG_WARNING);
-            }
-        }
-
-
-        return result;
-    }
-
-    /**
-     * Validates the package name field.
-     *
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validatePackageField() {
-        // Validate package field
-        String packageFieldContents = getPackageName();
-        if (packageFieldContents.length() == 0) {
-            return setStatus("Package name must be specified.", MSG_ERROR);
-        }
-
-        // Check it's a valid package string
-        int result = MSG_NONE;
-        IStatus status = JavaConventions.validatePackageName(packageFieldContents, "1.5", "1.5"); //$NON-NLS-1$ $NON-NLS-2$
-        if (!status.isOK()) {
-            result = setStatus(status.getMessage(),
-                        status.getSeverity() == IStatus.ERROR ? MSG_ERROR : MSG_WARNING);
-        }
-
-        // The Android Activity Manager does not accept packages names with only one
-        // identifier. Check the package name has at least one dot in them (the previous rule
-        // validated that if such a dot exist, it's not the first nor last characters of the
-        // string.)
-        if (result != MSG_ERROR && packageFieldContents.indexOf('.') == -1) {
-            return setStatus("Package name must have at least two identifiers.", MSG_ERROR);
-        }
-
-        return result;
-    }
-
-    /**
-     * Validates that an existing project actually has a source folder.
-     *
-     * For project in "use existing source" mode, this tries to find the source folder.
-     * A source folder should be just under the project directory and it should have all
-     * the directories composing the package+activity name.
-     *
-     * As a side effect, it memorizes the source folder in mSourceFolder.
-     *
-     * TODO: support multiple source folders for multiple activities.
-     *
-     * @return The wizard message type, one of MSG_ERROR, MSG_WARNING or MSG_NONE.
-     */
-    private int validateSourceFolder() {
-        // This check does nothing when creating a new project.
-        // This check is also useless when no activity is present or created.
-        if (isNewProject() || !isCreateActivity()) {
-            return MSG_NONE;
-        }
-
-        String osTarget = getActivityName();
-        
-        if (osTarget.indexOf('.') == -1) {
-            osTarget = getPackageName() + File.separator + osTarget;
-        } else if (osTarget.indexOf('.') == 0) {
-            osTarget = getPackageName() + osTarget;
-        }
-        osTarget = osTarget.replace('.', File.separatorChar) + AndroidConstants.DOT_JAVA;
-
-        String projectPath = getProjectLocation();
-        File projectDir = new File(projectPath);
-        File[] all_dirs = projectDir.listFiles(new FileFilter() {
-            public boolean accept(File pathname) {
-                return pathname.isDirectory();
-            }
-        });
-        for (File f : all_dirs) {
-            Path path = new Path(f.getAbsolutePath());
-            File java_activity = path.append(osTarget).toFile();
-            if (java_activity.isFile()) {
-                mSourceFolder = f.getName();
-                return MSG_NONE;
-            }
-        }
-
-        if (all_dirs.length > 0) {
-            return setStatus(
-                    String.format("%1$s can not be found under %2$s.", osTarget, projectPath),
-                    MSG_ERROR);
-        } else {
-            return setStatus(
-                    String.format("No source folders can be found in %1$s.", projectPath),
-                    MSG_ERROR);
-        }
-    }
-
-    /**
-     * Sets the error message for the wizard with the given message icon.
-     *
-     * @param message The wizard message type, one of MSG_ERROR or MSG_WARNING.
-     * @return As a convenience, always returns messageType so that the caller can return
-     *         immediately.
-     */
-    private int setStatus(String message, int messageType) {
-        if (message == null) {
-            setErrorMessage(null);
-            setMessage(null);
-        } else if (!message.equals(getMessage())) {
-            setMessage(message, messageType == MSG_WARNING ? WizardPage.WARNING : WizardPage.ERROR);
-        }
-        return messageType;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectWizard.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectWizard.java
deleted file mode 100644
index 607159a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/wizards/newproject/NewProjectWizard.java
+++ /dev/null
@@ -1,729 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.wizards.newproject;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.project.AndroidNature;
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceStatus;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.OperationCanceledException;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.ui.actions.OpenJavaPerspectiveAction;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.ui.INewWizard;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-
-import java.io.ByteArrayInputStream;
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.lang.reflect.InvocationTargetException;
-import java.net.MalformedURLException;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-/**
- * A "New Android Project" Wizard.
- * <p/>
- * Note: this class is public so that it can be accessed from unit tests.
- * It is however an internal class. Its API may change without notice.
- * It should semantically be considered as a private final class.
- * Do not derive from this class. 
-
- */
-public class NewProjectWizard extends Wizard implements INewWizard {
-
-    private static final String PARAM_SDK_TOOLS_DIR = "ANDROID_SDK_TOOLS"; //$NON-NLS-1$
-    private static final String PARAM_ACTIVITY = "ACTIVITY_NAME"; //$NON-NLS-1$
-    private static final String PARAM_APPLICATION = "APPLICATION_NAME"; //$NON-NLS-1$
-    private static final String PARAM_PACKAGE = "PACKAGE"; //$NON-NLS-1$
-    private static final String PARAM_PROJECT = "PROJECT_NAME"; //$NON-NLS-1$
-    private static final String PARAM_STRING_NAME = "STRING_NAME"; //$NON-NLS-1$
-    private static final String PARAM_STRING_CONTENT = "STRING_CONTENT"; //$NON-NLS-1$
-    private static final String PARAM_IS_NEW_PROJECT = "IS_NEW_PROJECT"; //$NON-NLS-1$
-    private static final String PARAM_SRC_FOLDER = "SRC_FOLDER"; //$NON-NLS-1$
-    private static final String PARAM_SDK_TARGET = "SDK_TARGET"; //$NON-NLS-1$
-    private static final String PARAM_MIN_SDK_VERSION = "MIN_SDK_VERSION"; //$NON-NLS-1$
-
-    private static final String PH_ACTIVITIES = "ACTIVITIES"; //$NON-NLS-1$
-    private static final String PH_USES_SDK = "USES-SDK"; //$NON-NLS-1$
-    private static final String PH_INTENT_FILTERS = "INTENT_FILTERS"; //$NON-NLS-1$
-    private static final String PH_STRINGS = "STRINGS"; //$NON-NLS-1$
-
-    private static final String BIN_DIRECTORY =
-        SdkConstants.FD_OUTPUT + AndroidConstants.WS_SEP;
-    private static final String RES_DIRECTORY =
-        SdkConstants.FD_RESOURCES + AndroidConstants.WS_SEP;
-    private static final String ASSETS_DIRECTORY =
-        SdkConstants.FD_ASSETS + AndroidConstants.WS_SEP;
-    private static final String DRAWABLE_DIRECTORY =
-        SdkConstants.FD_DRAWABLE + AndroidConstants.WS_SEP;
-    private static final String LAYOUT_DIRECTORY =
-        SdkConstants.FD_LAYOUT + AndroidConstants.WS_SEP;
-    private static final String VALUES_DIRECTORY =
-        SdkConstants.FD_VALUES + AndroidConstants.WS_SEP;
-
-    private static final String TEMPLATES_DIRECTORY = "templates/"; //$NON-NLS-1$
-    private static final String TEMPLATE_MANIFEST = TEMPLATES_DIRECTORY
-            + "AndroidManifest.template"; //$NON-NLS-1$
-    private static final String TEMPLATE_ACTIVITIES = TEMPLATES_DIRECTORY
-            + "activity.template"; //$NON-NLS-1$
-    private static final String TEMPLATE_USES_SDK = TEMPLATES_DIRECTORY
-            + "uses-sdk.template"; //$NON-NLS-1$
-    private static final String TEMPLATE_INTENT_LAUNCHER = TEMPLATES_DIRECTORY
-    		+ "launcher_intent_filter.template"; //$NON-NLS-1$
-
-    private static final String TEMPLATE_STRINGS = TEMPLATES_DIRECTORY
-            + "strings.template"; //$NON-NLS-1$
-    private static final String TEMPLATE_STRING = TEMPLATES_DIRECTORY
-            + "string.template"; //$NON-NLS-1$
-    private static final String ICON = "icon.png"; //$NON-NLS-1$
-
-    private static final String STRINGS_FILE = "strings.xml"; //$NON-NLS-1$
-
-    private static final String STRING_RSRC_PREFIX = "@string/"; //$NON-NLS-1$
-    private static final String STRING_APP_NAME = "app_name"; //$NON-NLS-1$
-    private static final String STRING_HELLO_WORLD = "hello"; //$NON-NLS-1$
-
-    private static final String[] DEFAULT_DIRECTORIES = new String[] {
-            BIN_DIRECTORY, RES_DIRECTORY, ASSETS_DIRECTORY };
-    private static final String[] RES_DIRECTORIES = new String[] {
-            DRAWABLE_DIRECTORY, LAYOUT_DIRECTORY, VALUES_DIRECTORY};
-
-    private static final String PROJECT_LOGO_LARGE = "icons/android_large.png"; //$NON-NLS-1$
-    private static final String JAVA_ACTIVITY_TEMPLATE = "java_file.template"; //$NON-NLS-1$
-    private static final String LAYOUT_TEMPLATE = "layout.template"; //$NON-NLS-1$
-    private static final String MAIN_LAYOUT_XML = "main.xml"; //$NON-NLS-1$
-    
-    protected static final String MAIN_PAGE_NAME = "newAndroidProjectPage"; //$NON-NLS-1$
-
-    private NewProjectCreationPage mMainPage;
-
-    /**
-     * Initializes this creation wizard using the passed workbench and object
-     * selection. Inherited from org.eclipse.ui.IWorkbenchWizard
-     */
-    public void init(IWorkbench workbench, IStructuredSelection selection) {
-        setHelpAvailable(false); // TODO have help
-        setWindowTitle("New Android Project");
-        setImageDescriptor();
-
-        mMainPage = createMainPage();
-        mMainPage.setTitle("New Android Project");
-        mMainPage.setDescription("Creates a new Android Project resource.");
-    }
-    
-    /**
-     * Creates the wizard page.
-     * <p/>
-     * Please do NOT override this method.
-     * <p/>
-     * This is protected so that it can be overridden by unit tests.
-     * However the contract of this class is private and NO ATTEMPT will be made
-     * to maintain compatibility between different versions of the plugin.
-     */
-    protected NewProjectCreationPage createMainPage() {
-        return new NewProjectCreationPage(MAIN_PAGE_NAME);
-    }
-
-    // -- Methods inherited from org.eclipse.jface.wizard.Wizard --
-    // The Wizard class implements most defaults and boilerplate code needed by
-    // IWizard
-
-    /**
-     * Adds pages to this wizard.
-     */
-    @Override
-    public void addPages() {
-        addPage(mMainPage);
-    }
-
-    /**
-     * Performs any actions appropriate in response to the user having pressed
-     * the Finish button, or refuse if finishing now is not permitted: here, it
-     * actually creates the workspace project and then switch to the Java
-     * perspective.
-     *
-     * @return True
-     */
-    @Override
-    public boolean performFinish() {
-        if (!createAndroidProject()) {
-            return false;
-        }
-
-        // Open the default Java Perspective
-        OpenJavaPerspectiveAction action = new OpenJavaPerspectiveAction();
-        action.run();
-        return true;
-    }
-
-    // -- Custom Methods --
-
-    /**
-     * Before actually creating the project for a new project (as opposed to using an
-     * existing project), we check if the target location is a directory that either does
-     * not exist or is empty.
-     * 
-     * If it's not empty, ask the user for confirmation.
-     *  
-     * @param destination The destination folder where the new project is to be created.
-     * @return True if the destination doesn't exist yet or is an empty directory or is
-     *         accepted by the user.
-     */
-    private boolean validateNewProjectLocationIsEmpty(IPath destination) {
-        File f = new File(destination.toOSString());
-        if (f.isDirectory() && f.list().length > 0) {
-            return AdtPlugin.displayPrompt("New Android Project",
-                    "You are going to create a new Android Project in an existing, non-empty, directory. Are you sure you want to proceed?");
-        }
-        return true;
-    }
-
-    /**
-     * Creates the android project.
-     * @return True if the project could be created.
-     */
-    private boolean createAndroidProject() {
-        IWorkspace workspace = ResourcesPlugin.getWorkspace();
-        final IProject project = workspace.getRoot().getProject(mMainPage.getProjectName());
-        final IProjectDescription description = workspace.newProjectDescription(project.getName());
-
-        final Map<String, Object> parameters = new HashMap<String, Object>();
-        parameters.put(PARAM_PROJECT, mMainPage.getProjectName());
-        parameters.put(PARAM_PACKAGE, mMainPage.getPackageName());
-        parameters.put(PARAM_APPLICATION, STRING_RSRC_PREFIX + STRING_APP_NAME);
-        parameters.put(PARAM_SDK_TOOLS_DIR, AdtPlugin.getOsSdkToolsFolder());
-        parameters.put(PARAM_IS_NEW_PROJECT, mMainPage.isNewProject());
-        parameters.put(PARAM_SRC_FOLDER, mMainPage.getSourceFolder());
-        parameters.put(PARAM_SDK_TARGET, mMainPage.getSdkTarget());
-        parameters.put(PARAM_MIN_SDK_VERSION, mMainPage.getMinSdkVersion());
-
-        if (mMainPage.isCreateActivity()) {
-            // An activity name can be of the form ".package.Class" or ".Class".
-            // The initial dot is ignored, as it is always added later in the templates.
-            String activityName = mMainPage.getActivityName();
-            if (activityName.startsWith(".")) { //$NON-NLS-1$
-                activityName = activityName.substring(1);
-            }
-            parameters.put(PARAM_ACTIVITY, activityName);
-        }
-
-        // create a dictionary of string that will contain name+content.
-        // we'll put all the strings into values/strings.xml
-        final HashMap<String, String> stringDictionary = new HashMap<String, String>();
-        stringDictionary.put(STRING_APP_NAME, mMainPage.getApplicationName());
-
-        IPath path = mMainPage.getLocationPath();
-        IPath defaultLocation = Platform.getLocation();
-        if (!path.equals(defaultLocation)) {
-            description.setLocation(path);
-        }
-        
-        if (mMainPage.isNewProject() && !mMainPage.useDefaultLocation() &&
-                !validateNewProjectLocationIsEmpty(path)) {
-            return false;
-        }
-
-        // Create a monitored operation to create the actual project
-        WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
-            @Override
-            protected void execute(IProgressMonitor monitor) throws InvocationTargetException {
-                createProjectAsync(project, description, monitor, parameters, stringDictionary);
-            }
-        };
-
-        // Run the operation in a different thread
-        runAsyncOperation(op);
-        return true;
-    }
-
-    /**
-     * Runs the operation in a different thread and display generated
-     * exceptions.
-     *
-     * @param op The asynchronous operation to run.
-     */
-    private void runAsyncOperation(WorkspaceModifyOperation op) {
-        try {
-            getContainer().run(true /* fork */, true /* cancelable */, op);
-        } catch (InvocationTargetException e) {
-            // The runnable threw an exception
-            Throwable t = e.getTargetException();
-            if (t instanceof CoreException) {
-                CoreException core = (CoreException) t;
-                if (core.getStatus().getCode() == IResourceStatus.CASE_VARIANT_EXISTS) {
-                    // The error indicates the file system is not case sensitive
-                    // and there's a resource with a similar name.
-                    MessageDialog.openError(getShell(), "Error", "Error: Case Variant Exists");
-                } else {
-                    ErrorDialog.openError(getShell(), "Error", null, core.getStatus());
-                }
-            } else {
-                // Some other kind of exception
-                MessageDialog.openError(getShell(), "Error", t.getMessage());
-            }
-            e.printStackTrace();
-        } catch (InterruptedException e) {
-            e.printStackTrace();
-        }
-    }
-
-    /**
-     * Creates the actual project, sets its nature and adds the required folders
-     * and files to it. This is run asynchronously in a different thread.
-     *
-     * @param project The project to create.
-     * @param description A description of the project.
-     * @param monitor An existing monitor.
-     * @param parameters Template parameters.
-     * @param stringDictionary String definition.
-     * @throws InvocationTargetException to wrap any unmanaged exception and
-     *         return it to the calling thread. The method can fail if it fails
-     *         to create or modify the project or if it is canceled by the user.
-     */
-    private void createProjectAsync(IProject project, IProjectDescription description,
-            IProgressMonitor monitor, Map<String, Object> parameters,
-            Map<String, String> stringDictionary)
-            throws InvocationTargetException {
-        monitor.beginTask("Create Android Project", 100);
-        try {
-            // Create project and open it
-            project.create(description, new SubProgressMonitor(monitor, 10));
-            if (monitor.isCanceled()) throw new OperationCanceledException();
-            project.open(IResource.BACKGROUND_REFRESH, new SubProgressMonitor(monitor, 10));
-
-            // Add the Java and android nature to the project
-            AndroidNature.setupProjectNatures(project, monitor);
-
-            // Create folders in the project if they don't already exist
-            addDefaultDirectories(project, AndroidConstants.WS_ROOT, DEFAULT_DIRECTORIES, monitor);
-            String[] sourceFolder = new String[] { (String) parameters.get(PARAM_SRC_FOLDER) };
-            addDefaultDirectories(project, AndroidConstants.WS_ROOT, sourceFolder, monitor);
-
-            // Create the resource folders in the project if they don't already exist.
-            addDefaultDirectories(project, RES_DIRECTORY, RES_DIRECTORIES, monitor);
-
-            // Setup class path
-            IJavaProject javaProject = JavaCore.create(project);
-            setupSourceFolder(javaProject, sourceFolder[0], monitor);
-
-            if (((Boolean) parameters.get(PARAM_IS_NEW_PROJECT)).booleanValue()) {
-                // Create files in the project if they don't already exist
-                addManifest(project, parameters, stringDictionary, monitor);
-
-                // add the default app icon
-                addIcon(project, monitor);
-
-                // Create the default package components
-                addSampleCode(project, sourceFolder[0], parameters, stringDictionary, monitor);
-
-                // add the string definition file if needed
-                if (stringDictionary.size() > 0) {
-                    addStringDictionaryFile(project, stringDictionary, monitor);
-                }
-
-                // Set output location
-                javaProject.setOutputLocation(project.getFolder(BIN_DIRECTORY).getFullPath(),
-                        monitor);
-            }
-
-            Sdk.getCurrent().setProject(project, (IAndroidTarget) parameters.get(PARAM_SDK_TARGET));
-            
-            // Fix the project to make sure all properties are as expected.
-            // Necessary for existing projects and good for new ones to.
-            ProjectHelper.fixProject(project);
-
-        } catch (CoreException e) {
-            throw new InvocationTargetException(e);
-        } catch (IOException e) {
-            throw new InvocationTargetException(e);
-        } finally {
-            monitor.done();
-        }
-    }
-
-    /**
-     * Adds default directories to the project.
-     *
-     * @param project The Java Project to update.
-     * @param parentFolder The path of the parent folder. Must end with a
-     *        separator.
-     * @param folders Folders to be added.
-     * @param monitor An existing monitor.
-     * @throws CoreException if the method fails to create the directories in
-     *         the project.
-     */
-    private void addDefaultDirectories(IProject project, String parentFolder,
-            String[] folders, IProgressMonitor monitor) throws CoreException {
-        for (String name : folders) {
-            if (name.length() > 0) {
-                IFolder folder = project.getFolder(parentFolder + name);
-                if (!folder.exists()) {
-                    folder.create(true /* force */, true /* local */,
-                            new SubProgressMonitor(monitor, 10));
-                }
-            }
-        }
-    }
-
-    /**
-     * Adds the manifest to the project.
-     *
-     * @param project The Java Project to update.
-     * @param parameters Template Parameters.
-     * @param stringDictionary String List to be added to a string definition
-     *        file. This map will be filled by this method.
-     * @param monitor An existing monitor.
-     * @throws CoreException if the method fails to update the project.
-     * @throws IOException if the method fails to create the files in the
-     *         project.
-     */
-    private void addManifest(IProject project, Map<String, Object> parameters,
-            Map<String, String> stringDictionary, IProgressMonitor monitor)
-            throws CoreException, IOException {
-
-        // get IFile to the manifest and check if it's not already there.
-        IFile file = project.getFile(AndroidConstants.FN_ANDROID_MANIFEST);
-        if (!file.exists()) {
-
-            // Read manifest template
-            String manifestTemplate = AdtPlugin.readEmbeddedTextFile(TEMPLATE_MANIFEST);
-
-            // Replace all keyword parameters
-            manifestTemplate = replaceParameters(manifestTemplate, parameters);
-
-            if (parameters.containsKey(PARAM_ACTIVITY)) {
-                // now get the activity template
-                String activityTemplate = AdtPlugin.readEmbeddedTextFile(TEMPLATE_ACTIVITIES);
-    
-                // Replace all keyword parameters to make main activity.
-                String activities = replaceParameters(activityTemplate, parameters);
-    
-                // set the intent.
-                String intent = AdtPlugin.readEmbeddedTextFile(TEMPLATE_INTENT_LAUNCHER);
-                
-                // set the intent to the main activity
-                activities = activities.replaceAll(PH_INTENT_FILTERS, intent);
-    
-                // set the activity(ies) in the manifest
-                manifestTemplate = manifestTemplate.replaceAll(PH_ACTIVITIES, activities);
-            } else {
-                // remove the activity(ies) from the manifest
-                manifestTemplate = manifestTemplate.replaceAll(PH_ACTIVITIES, "");
-            }
-            
-            String minSdkVersion = (String) parameters.get(PARAM_MIN_SDK_VERSION);
-            if (minSdkVersion != null && minSdkVersion.length() > 0) {
-                String usesSdkTemplate = AdtPlugin.readEmbeddedTextFile(TEMPLATE_USES_SDK);
-                String usesSdk = replaceParameters(usesSdkTemplate, parameters);
-                manifestTemplate = manifestTemplate.replaceAll(PH_USES_SDK, usesSdk);
-            } else {
-                manifestTemplate = manifestTemplate.replaceAll(PH_USES_SDK, "");
-            }
-
-            // Save in the project as UTF-8
-            InputStream stream = new ByteArrayInputStream(
-                    manifestTemplate.getBytes("UTF-8")); //$NON-NLS-1$
-            file.create(stream, false /* force */, new SubProgressMonitor(monitor, 10));
-        }
-    }
-
-    /**
-     * Adds the string resource file.
-     *
-     * @param project The Java Project to update.
-     * @param strings The list of strings to be added to the string file.
-     * @param monitor An existing monitor.
-     * @throws CoreException if the method fails to update the project.
-     * @throws IOException if the method fails to create the files in the
-     *         project.
-     */
-    private void addStringDictionaryFile(IProject project,
-            Map<String, String> strings, IProgressMonitor monitor)
-            throws CoreException, IOException {
-
-        // create the IFile object and check if the file doesn't already exist.
-        IFile file = project.getFile(RES_DIRECTORY + AndroidConstants.WS_SEP
-                                     + VALUES_DIRECTORY + AndroidConstants.WS_SEP + STRINGS_FILE);
-        if (!file.exists()) {
-            // get the Strings.xml template
-            String stringDefinitionTemplate = AdtPlugin.readEmbeddedTextFile(TEMPLATE_STRINGS);
-
-            // get the template for one string
-            String stringTemplate = AdtPlugin.readEmbeddedTextFile(TEMPLATE_STRING);
-
-            // get all the string names
-            Set<String> stringNames = strings.keySet();
-
-            // loop on it and create the string definitions
-            StringBuilder stringNodes = new StringBuilder();
-            for (String key : stringNames) {
-                // get the value from the key
-                String value = strings.get(key);
-
-                // place them in the template
-                String stringDef = stringTemplate.replace(PARAM_STRING_NAME, key);
-                stringDef = stringDef.replace(PARAM_STRING_CONTENT, value);
-
-                // append to the other string
-                if (stringNodes.length() > 0) {
-                    stringNodes.append("\n");
-                }
-                stringNodes.append(stringDef);
-            }
-
-            // put the string nodes in the Strings.xml template
-            stringDefinitionTemplate = stringDefinitionTemplate.replace(PH_STRINGS,
-                                                                        stringNodes.toString());
-
-            // write the file as UTF-8
-            InputStream stream = new ByteArrayInputStream(
-                    stringDefinitionTemplate.getBytes("UTF-8")); //$NON-NLS-1$
-            file.create(stream, false /* force */, new SubProgressMonitor(monitor, 10));
-        }
-    }
-
-
-    /**
-     * Adds default application icon to the project.
-     *
-     * @param project The Java Project to update.
-     * @param monitor An existing monitor.
-     * @throws CoreException if the method fails to update the project.
-     */
-    private void addIcon(IProject project, IProgressMonitor monitor)
-            throws CoreException {
-        IFile file = project.getFile(RES_DIRECTORY + AndroidConstants.WS_SEP
-                                     + DRAWABLE_DIRECTORY + AndroidConstants.WS_SEP + ICON);
-        if (!file.exists()) {
-            // read the content from the template
-            byte[] buffer = AdtPlugin.readEmbeddedFile(TEMPLATES_DIRECTORY + ICON);
-
-            // if valid
-            if (buffer != null) {
-                // Save in the project
-                InputStream stream = new ByteArrayInputStream(buffer);
-                file.create(stream, false /* force */, new SubProgressMonitor(monitor, 10));
-            }
-        }
-    }
-
-    /**
-     * Creates the package folder and copies the sample code in the project.
-     *
-     * @param project The Java Project to update.
-     * @param parameters Template Parameters.
-     * @param stringDictionary String List to be added to a string definition
-     *        file. This map will be filled by this method.
-     * @param monitor An existing monitor.
-     * @throws CoreException if the method fails to update the project.
-     * @throws IOException if the method fails to create the files in the
-     *         project.
-     */
-    private void addSampleCode(IProject project, String sourceFolder,
-            Map<String, Object> parameters, Map<String, String> stringDictionary,
-            IProgressMonitor monitor) throws CoreException, IOException {
-        // create the java package directories.
-        IFolder pkgFolder = project.getFolder(sourceFolder);
-        String packageName = (String) parameters.get(PARAM_PACKAGE);
-        
-        // The PARAM_ACTIVITY key will be absent if no activity should be created,
-        // in which case activityName will be null.
-        String activityName = (String) parameters.get(PARAM_ACTIVITY);
-        Map<String, Object> java_activity_parameters = parameters;
-        if (activityName != null) {
-            if (activityName.indexOf('.') >= 0) {
-                // There are package names in the activity name. Transform packageName to add
-                // those sub packages and remove them from activityName.
-                packageName += "." + activityName; //$NON-NLS-1$
-                int pos = packageName.lastIndexOf('.');
-                activityName = packageName.substring(pos + 1);
-                packageName = packageName.substring(0, pos);
-                
-                // Also update the values used in the JAVA_FILE_TEMPLATE below
-                // (but not the ones from the manifest so don't change the caller's dictionary)
-                java_activity_parameters = new HashMap<String, Object>(parameters);
-                java_activity_parameters.put(PARAM_PACKAGE, packageName);
-                java_activity_parameters.put(PARAM_ACTIVITY, activityName);
-            }
-        }
-
-        String[] components = packageName.split(AndroidConstants.RE_DOT);
-        for (String component : components) {
-            pkgFolder = pkgFolder.getFolder(component);
-            if (!pkgFolder.exists()) {
-                pkgFolder.create(true /* force */, true /* local */,
-                        new SubProgressMonitor(monitor, 10));
-            }
-        }
-
-        if (activityName != null) {
-            // create the main activity Java file
-            String activityJava = activityName + AndroidConstants.DOT_JAVA;
-            IFile file = pkgFolder.getFile(activityJava);
-            if (!file.exists()) {
-                copyFile(JAVA_ACTIVITY_TEMPLATE, file, java_activity_parameters, monitor);
-            }
-        }
-
-        // create the layout file
-        IFolder layoutfolder = project.getFolder(RES_DIRECTORY).getFolder(LAYOUT_DIRECTORY);
-        IFile file = layoutfolder.getFile(MAIN_LAYOUT_XML);
-        if (!file.exists()) {
-            copyFile(LAYOUT_TEMPLATE, file, parameters, monitor);
-            if (activityName != null) {
-                stringDictionary.put(STRING_HELLO_WORLD, "Hello World, " + activityName + "!");
-            } else {
-                stringDictionary.put(STRING_HELLO_WORLD, "Hello World!");
-            }
-        }
-    }
-
-    /**
-     * Adds the given folder to the project's class path.
-     *
-     * @param javaProject The Java Project to update.
-     * @param sourceFolder Template Parameters.
-     * @param monitor An existing monitor.
-     * @throws JavaModelException if the classpath could not be set.
-     */
-    private void setupSourceFolder(IJavaProject javaProject, String sourceFolder,
-            IProgressMonitor monitor) throws JavaModelException {
-        IProject project = javaProject.getProject();
-
-        // Add "src" to class path
-        IFolder srcFolder = project.getFolder(sourceFolder);
-
-        IClasspathEntry[] entries = javaProject.getRawClasspath();
-        entries = removeSourceClasspath(entries, srcFolder);
-        entries = removeSourceClasspath(entries, srcFolder.getParent());
-
-        entries = ProjectHelper.addEntryToClasspath(entries,
-                JavaCore.newSourceEntry(srcFolder.getFullPath()));
-
-        javaProject.setRawClasspath(entries, new SubProgressMonitor(monitor, 10));
-    }
-
-
-    /**
-     * Removes the corresponding source folder from the class path entries if
-     * found.
-     *
-     * @param entries The class path entries to read. A copy will be returned.
-     * @param folder The parent source folder to remove.
-     * @return A new class path entries array.
-     */
-    private IClasspathEntry[] removeSourceClasspath(IClasspathEntry[] entries, IContainer folder) {
-        if (folder == null) {
-            return entries;
-        }
-        IClasspathEntry source = JavaCore.newSourceEntry(folder.getFullPath());
-        int n = entries.length;
-        for (int i = n - 1; i >= 0; i--) {
-            if (entries[i].equals(source)) {
-                IClasspathEntry[] newEntries = new IClasspathEntry[n - 1];
-                if (i > 0) System.arraycopy(entries, 0, newEntries, 0, i);
-                if (i < n - 1) System.arraycopy(entries, i + 1, newEntries, i, n - i - 1);
-                n--;
-                entries = newEntries;
-            }
-        }
-        return entries;
-    }
-
-
-    /**
-     * Copies the given file from our resource folder to the new project.
-     * Expects the file to the US-ASCII or UTF-8 encoded.
-     *
-     * @throws CoreException from IFile if failing to create the new file.
-     * @throws MalformedURLException from URL if failing to interpret the URL.
-     * @throws FileNotFoundException from RandomAccessFile.
-     * @throws IOException from RandomAccessFile.length() if can't determine the
-     *         length.
-     */
-    private void copyFile(String resourceFilename, IFile destFile,
-            Map<String, Object> parameters, IProgressMonitor monitor)
-            throws CoreException, IOException {
-
-        // Read existing file.
-        String template = AdtPlugin.readEmbeddedTextFile(
-                TEMPLATES_DIRECTORY + resourceFilename);
-
-        // Replace all keyword parameters
-        template = replaceParameters(template, parameters);
-
-        // Save in the project as UTF-8
-        InputStream stream = new ByteArrayInputStream(template.getBytes("UTF-8")); //$NON-NLS-1$
-        destFile.create(stream, false /* force */, new SubProgressMonitor(monitor, 10));
-    }
-
-    /**
-     * Returns an image descriptor for the wizard logo.
-     */
-    private void setImageDescriptor() {
-        ImageDescriptor desc = AdtPlugin.getImageDescriptor(PROJECT_LOGO_LARGE);
-        setDefaultPageImageDescriptor(desc);
-    }
-
-    /**
-     * Replaces placeholders found in a string with values.
-     *
-     * @param str the string to search for placeholders.
-     * @param parameters a map of <placeholder, Value> to search for in the string
-     * @return A new String object with the placeholder replaced by the values.
-     */
-    private String replaceParameters(String str, Map<String, Object> parameters) {
-        for (Entry<String, Object> entry : parameters.entrySet()) {
-            if (entry.getValue() instanceof String) {
-                str = str.replaceAll(entry.getKey(), (String) entry.getValue());
-            }
-        }
-
-        return str;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/AndroidConstants.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/AndroidConstants.java
deleted file mode 100644
index b1c57a6..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/AndroidConstants.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common;
-
-import com.android.sdklib.SdkConstants;
-
-import java.io.File;
-import java.util.regex.Pattern;
-
-/**
- * Constant definition class.<br>
- * <br>
- * Most constants have a prefix defining the content.
- * <ul>
- * <li><code>WS_</code> Workspace path constant. Those are absolute paths,
- * from the project root.</li>
- * <li><code>OS_</code> OS path constant. These paths are different depending on the platform.</li>
- * <li><code>FN_</code> File name constant.</li>
- * <li><code>FD_</code> Folder name constant.</li>
- * <li><code>MARKER_</code> Resource Marker Ids constant.</li>
- * <li><code>EXT_</code> File extension constant. This does NOT include a dot.</li>
- * <li><code>DOT_</code> File extension constant. This start with a dot.</li>
- * <li><code>RE_</code> Regexp constant.</li>
- * <li><code>NS_</code> Namespace constant.</li>
- * <li><code>CLASS_</code> Fully qualified class name.</li>
- * </ul>
- *
- */
-public class AndroidConstants {
-    /**
-     * The old Editors Plugin ID. It is still used in some places for compatibility.
-     * Please do not use for new features.
-     */
-    public static final String EDITORS_NAMESPACE = "com.android.ide.eclipse.editors"; // $NON-NLS-1$
-
-    /** Nature of android projects */
-    public final static String NATURE = "com.android.ide.eclipse.adt.AndroidNature"; //$NON-NLS-1$
-
-    /** Separator for workspace path, i.e. "/". */
-    public final static String WS_SEP = "/"; //$NON-NLS-1$
-    /** Separator character for workspace path, i.e. '/'. */
-    public final static char WS_SEP_CHAR = '/';
-
-    /** Extension of the Application package Files, i.e. "apk". */
-    public final static String EXT_ANDROID_PACKAGE = "apk"; //$NON-NLS-1$
-    /** Extension of java files, i.e. "java" */
-    public final static String EXT_JAVA = "java"; //$NON-NLS-1$
-    /** Extension of compiled java files, i.e. "class" */
-    public final static String EXT_CLASS = "class"; //$NON-NLS-1$
-    /** Extension of xml files, i.e. "xml" */
-    public final static String EXT_XML = "xml"; //$NON-NLS-1$
-    /** Extension of jar files, i.e. "jar" */
-    public final static String EXT_JAR = "jar"; //$NON-NLS-1$
-    /** Extension of aidl files, i.e. "aidl" */
-    public final static String EXT_AIDL = "aidl"; //$NON-NLS-1$
-    /** Extension of native libraries, i.e. "so" */
-    public final static String EXT_NATIVE_LIB = "so"; //$NON-NLS-1$
-
-    private final static String DOT = "."; //$NON-NLS-1$
-
-    /** Dot-Extension of the Application package Files, i.e. ".apk". */
-    public final static String DOT_ANDROID_PACKAGE = DOT + EXT_ANDROID_PACKAGE;
-    /** Dot-Extension of java files, i.e. ".java" */
-    public final static String DOT_JAVA = DOT + EXT_JAVA;
-    /** Dot-Extension of compiled java files, i.e. ".class" */
-    public final static String DOT_CLASS = DOT + EXT_CLASS;
-    /** Dot-Extension of xml files, i.e. ".xml" */
-    public final static String DOT_XML = DOT + EXT_XML;
-    /** Dot-Extension of jar files, i.e. ".jar" */
-    public final static String DOT_JAR = DOT + EXT_JAR;
-    /** Dot-Extension of aidl files, i.e. ".aidl" */
-    public final static String DOT_AIDL = DOT + EXT_AIDL;
-
-    /** Name of the manifest file, i.e. "AndroidManifest.xml". */
-    public static final String FN_ANDROID_MANIFEST = "AndroidManifest.xml"; //$NON-NLS-1$
-    public static final String FN_PROJECT_AIDL = "project.aidl"; //$NON-NLS-1$
-
-    /** Name of the android sources directory */
-    public static final String FD_ANDROID_SOURCES = "sources"; //$NON-NLS-1$
-
-    /** Resource java class  filename, i.e. "R.java" */
-    public final static String FN_RESOURCE_CLASS = "R.java"; //$NON-NLS-1$
-    /** Resource class file  filename, i.e. "R.class" */
-    public final static String FN_COMPILED_RESOURCE_CLASS = "R.class"; //$NON-NLS-1$
-    /** Manifest java class filename, i.e. "Manifest.java" */
-    public final static String FN_MANIFEST_CLASS = "Manifest.java"; //$NON-NLS-1$
-    /** Dex conversion output filname, i.e. "classes.dex" */
-    public final static String FN_CLASSES_DEX = "classes.dex"; //$NON-NLS-1$
-    /** Temporary packaged resources file name, i.e. "resources.ap_" */
-    public final static String FN_RESOURCES_AP_ = "resources.ap_"; //$NON-NLS-1$
-    /** Temporary packaged resources file name for a specific set of configuration */
-    public final static String FN_RESOURCES_S_AP_ = "resources-%s.ap_"; //$NON-NLS-1$
-    public final static Pattern PATTERN_RESOURCES_S_AP_ =
-        Pattern.compile("resources-.*\\.ap_", Pattern.CASE_INSENSITIVE);
-
-    public final static String FN_ADB =
-        (SdkConstants.CURRENT_PLATFORM == SdkConstants.PLATFORM_WINDOWS) ?
-            "adb.exe" : "adb"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    public final static String FN_EMULATOR =
-        (SdkConstants.CURRENT_PLATFORM == SdkConstants.PLATFORM_WINDOWS) ?
-            "emulator.exe" : "emulator"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    public final static String FN_TRACEVIEW =
-        (SdkConstants.CURRENT_PLATFORM == SdkConstants.PLATFORM_WINDOWS) ?
-            "traceview.exe" : "traceview"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    /** Absolute path of the workspace root, i.e. "/" */
-    public final static String WS_ROOT = WS_SEP;
-
-    /** Absolute path of the resource folder, eg "/res".<br> This is a workspace path. */
-    public final static String WS_RESOURCES = WS_SEP + SdkConstants.FD_RESOURCES;
-
-    /** Absolute path of the resource folder, eg "/assets".<br> This is a workspace path. */
-    public final static String WS_ASSETS = WS_SEP + SdkConstants.FD_ASSETS;
-
-    /** Leaf of the javaDoc folder. Does not start with a separator. */
-    public final static String WS_JAVADOC_FOLDER_LEAF = SdkConstants.FD_DOCS + "/reference"; //$NON-NLS-1$
-
-    /** Path of the samples directory relative to the sdk folder.
-     *  This is an OS path, ending with a separator.
-     *  FIXME: remove once the NPW is fixed. */
-    public final static String OS_SDK_SAMPLES_FOLDER = SdkConstants.FD_SAMPLES + File.separator;
-
-    public final static String RE_DOT = "\\."; //$NON-NLS-1$
-    /** Regexp for java extension, i.e. "\.java$" */
-    public final static String RE_JAVA_EXT = "\\.java$"; //$NON-NLS-1$
-    /** Regexp for aidl extension, i.e. "\.aidl$" */
-    public final static String RE_AIDL_EXT = "\\.aidl$"; //$NON-NLS-1$
-
-    /** Namespace pattern for the custom resource XML, i.e. "http://schemas.android.com/apk/res/%s" */
-    public final static String NS_CUSTOM_RESOURCES = "http://schemas.android.com/apk/res/%1$s"; //$NON-NLS-1$
-
-    /** The old common plug-in ID. Please do not use for new features. */
-    public static final String COMMON_PLUGIN_ID = "com.android.ide.eclipse.common"; //$NON-NLS-1$
-
-    /** aapt marker error. */
-    public final static String MARKER_AAPT = COMMON_PLUGIN_ID + ".aaptProblem"; //$NON-NLS-1$
-
-    /** XML marker error. */
-    public final static String MARKER_XML = COMMON_PLUGIN_ID + ".xmlProblem"; //$NON-NLS-1$
-
-    /** aidl marker error. */
-    public final static String MARKER_AIDL = COMMON_PLUGIN_ID + ".aidlProblem"; //$NON-NLS-1$
-    
-    /** android marker error */
-    public final static String MARKER_ANDROID = COMMON_PLUGIN_ID + ".androidProblem"; //$NON-NLS-1$
-    
-    /** Name for the "type" marker attribute */
-    public final static String MARKER_ATTR_TYPE = "android.type"; //$NON-NLS-1$
-    /** Name for the "class" marker attribute */
-    public final static String MARKER_ATTR_CLASS = "android.class"; //$NON-NLS-1$
-    /** activity value for marker attribute "type" */
-    public final static String MARKER_ATTR_TYPE_ACTIVITY = "activity"; //$NON-NLS-1$
-    /** service value for marker attribute "type" */
-    public final static String MARKER_ATTR_TYPE_SERVICE = "service"; //$NON-NLS-1$
-    /** receiver value for marker attribute "type" */
-    public final static String MARKER_ATTR_TYPE_RECEIVER = "receiver"; //$NON-NLS-1$
-    /** provider value for marker attribute "type" */
-    public final static String MARKER_ATTR_TYPE_PROVIDER = "provider"; //$NON-NLS-1$
-
-    public final static String CLASS_ACTIVITY = "android.app.Activity"; //$NON-NLS-1$ 
-    public final static String CLASS_SERVICE = "android.app.Service"; //$NON-NLS-1$ 
-    public final static String CLASS_BROADCASTRECEIVER = "android.content.BroadcastReceiver"; //$NON-NLS-1$ 
-    public final static String CLASS_CONTENTPROVIDER = "android.content.ContentProvider"; //$NON-NLS-1$
-    public final static String CLASS_INSTRUMENTATION = "android.app.Instrumentation"; //$NON-NLS-1$
-    public final static String CLASS_BUNDLE = "android.os.Bundle"; //$NON-NLS-1$
-    public final static String CLASS_R = "android.R"; //$NON-NLS-1$
-    public final static String CLASS_MANIFEST_PERMISSION = "android.Manifest$permission"; //$NON-NLS-1$
-    public final static String CLASS_INTENT = "android.content.Intent"; //$NON-NLS-1$
-    public final static String CLASS_CONTEXT = "android.content.Context"; //$NON-NLS-1$
-    public final static String CLASS_VIEW = "android.view.View"; //$NON-NLS-1$
-    public final static String CLASS_VIEWGROUP = "android.view.ViewGroup"; //$NON-NLS-1$
-    public final static String CLASS_LAYOUTPARAMS = "LayoutParams"; //$NON-NLS-1$
-    public final static String CLASS_VIEWGROUP_LAYOUTPARAMS =
-        CLASS_VIEWGROUP + "$" + CLASS_LAYOUTPARAMS; //$NON-NLS-1$
-    public final static String CLASS_FRAMELAYOUT = "FrameLayout"; //$NON-NLS-1$
-    public final static String CLASS_PREFERENCE = "android.preference.Preference"; //$NON-NLS-1$
-    public final static String CLASS_PREFERENCE_SCREEN = "PreferenceScreen"; //$NON-NLS-1$
-    public final static String CLASS_PREFERENCES =
-        "android.preference." + CLASS_PREFERENCE_SCREEN; //$NON-NLS-1$
-    public final static String CLASS_PREFERENCEGROUP = "android.preference.PreferenceGroup"; //$NON-NLS-1$
-    public final static String CLASS_PARCELABLE = "android.os.Parcelable"; //$NON-NLS-1$
-    
-    public final static String CLASS_BRIDGE = "com.android.layoutlib.bridge.Bridge"; //$NON-NLS-1$
-
-    /**
-     * Prefered compiler level, i.e. "1.5".
-     */
-    public final static String COMPILER_COMPLIANCE_PREFERRED = "1.5"; //$NON-NLS-1$
-    /**
-     * List of valid compiler level, i.e. "1.5" and "1.6"
-     */
-    public final static String[] COMPILER_COMPLIANCE = {
-        "1.5", //$NON-NLS-1$
-        "1.6", //$NON-NLS-1$
-    };
-
-    /** The base URL where to find the Android class & manifest documentation */
-    public static final String CODESITE_BASE_URL = "http://code.google.com/android";  //$NON-NLS-1$
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/EclipseUiHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/EclipseUiHelper.java
deleted file mode 100644
index 6dc8562..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/EclipseUiHelper.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common;
-
-import org.eclipse.ui.IViewPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Helpers for Eclipse UI related stuff.
- */
-public final class EclipseUiHelper {
-
-    /** View Id for the default Eclipse Content Outline view. */
-    public static final String CONTENT_OUTLINE_VIEW_ID = "org.eclipse.ui.views.ContentOutline";
-    /** View Id for the default Eclipse Property Sheet view. */
-    public static final String PROPERTY_SHEET_VIEW_ID  = "org.eclipse.ui.views.PropertySheet";
-    
-    /** This class never gets instantiated. */
-    private EclipseUiHelper() {
-    }
-    
-    /**
-     * Shows the corresponding view.
-     * <p/>
-     * Silently fails in case of error.
-     * 
-     * @param viewId One of {@link #CONTENT_OUTLINE_VIEW_ID}, {@link #PROPERTY_SHEET_VIEW_ID}.
-     * @param activate True to force activate (i.e. takes focus), false to just make visible (i.e.
-     *                 does not steal focus.)
-     */
-    public static void showView(String viewId, boolean activate) {
-        IWorkbenchWindow win = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-        if (win != null) {
-            IWorkbenchPage page = win.getActivePage();
-            if (page != null) {
-                try {
-                    IViewPart part = page.showView(viewId,
-                            null /* secondaryId */,
-                            activate ? IWorkbenchPage.VIEW_ACTIVATE : IWorkbenchPage.VIEW_VISIBLE);
-                } catch (PartInitException e) {
-                    // ignore
-                }
-            }
-        }
-        
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/Messages.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/Messages.java
deleted file mode 100644
index 3f1bde4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/Messages.java
+++ /dev/null
@@ -1,21 +0,0 @@
-
-package com.android.ide.eclipse.common;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "com.android.ide.eclipse.common.messages"; //$NON-NLS-1$
-
-    public static String Console_Data_Project_Tag;
-
-    public static String Console_Date_Tag;
-
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/SdkStatsHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/SdkStatsHelper.java
deleted file mode 100644
index 345c663..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/SdkStatsHelper.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common;
-
-import com.android.sdkstats.SdkStatsService;
-
-import org.osgi.framework.Version;
-
-/**
- * Helper class to access the ping usage stat server.
- */
-public class SdkStatsHelper {
-
-    /**
-     * Pings the usage start server.
-     * @param pluginName the name of the plugin to appear in the stats
-     * @param pluginVersion the {@link Version} of the plugin.
-     */
-    public static void pingUsageServer(String pluginName, Version pluginVersion) {
-        String versionString = String.format("%1$d.%2$d.%3$d", pluginVersion.getMajor(),
-                pluginVersion.getMinor(), pluginVersion.getMicro());
-
-        SdkStatsService.ping(pluginName, versionString);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/StreamHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/StreamHelper.java
deleted file mode 100644
index 6ccf4f2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/StreamHelper.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common;
-
-import org.eclipse.ui.console.MessageConsoleStream;
-
-import java.util.Calendar;
-
-/**
- * Stream helper class.
- */
-public class StreamHelper {
-
-    /**
-     * Prints messages, associated with a project to the specified stream
-     * @param stream The stream to write to
-     * @param tag The tag associated to the message. Can be null
-     * @param objects The objects to print through their toString() method (or directly for
-     * {@link String} objects.
-     */
-    public static synchronized void printToStream(MessageConsoleStream stream, String tag,
-            Object... objects) {
-        String dateTag = getMessageTag(tag);
-
-        for (Object obj : objects) {
-            stream.print(dateTag);
-            if (obj instanceof String) {
-                stream.println((String)obj);
-            } else {
-                stream.println(obj.toString());
-            }
-        }
-    }
-
-    /**
-     * Creates a string containing the current date/time, and the tag
-     * @param tag The tag associated to the message. Can be null
-     * @return The dateTag
-     */
-    public static String getMessageTag(String tag) {
-        Calendar c = Calendar.getInstance();
-
-        if (tag == null) {
-            return String.format(Messages.Console_Date_Tag, c);
-        }
-
-        return String.format(Messages.Console_Data_Project_Tag, c, tag);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/messages.properties b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/messages.properties
deleted file mode 100644
index dba6edc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/messages.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-Console_Date_Tag=[%1$tF %1$tT] 
-Console_Data_Project_Tag=[%1$tF %1$tT - %2$s] 
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/preferences/UsagePreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/preferences/UsagePreferencePage.java
deleted file mode 100644
index 58c2f40..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/preferences/UsagePreferencePage.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.preferences;
-
-import com.android.sdkstats.SdkStatsService;
-
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jface.preference.PreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Link;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-import java.io.IOException;
-
-public class UsagePreferencePage extends PreferencePage implements IWorkbenchPreferencePage {
-
-    private BooleanFieldEditor mOptInCheckBox;
-
-    public UsagePreferencePage() {
-    }
-
-    public void init(IWorkbench workbench) {
-        // pass
-    }
-
-    @Override
-    protected Control createContents(Composite parent) {
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayout(new GridLayout(1, false));
-        top.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        Link text = new Link(top, SWT.WRAP);
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.widthHint = 200;
-        text.setLayoutData(gd);
-        text.setText(SdkStatsService.BODY_TEXT);
-
-        text.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent event) {
-                SdkStatsService.openUrl(event.text);
-            }
-        });
-
-        mOptInCheckBox = new BooleanFieldEditor(SdkStatsService.PING_OPT_IN,
-                SdkStatsService.CHECKBOX_TEXT, top);
-        mOptInCheckBox.setPage(this);
-        mOptInCheckBox.setPreferenceStore(SdkStatsService.getPreferenceStore());
-        mOptInCheckBox.load();
-        
-        return top;
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.preference.PreferencePage#performCancel()
-     */
-    @Override
-    public boolean performCancel() {
-        mOptInCheckBox.load();
-        return super.performCancel();
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.preference.PreferencePage#performDefaults()
-     */
-    @Override
-    protected void performDefaults() {
-        mOptInCheckBox.loadDefault();
-        super.performDefaults();
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.preference.PreferencePage#performOk()
-     */
-    @Override
-    public boolean performOk() {
-        save();
-        return super.performOk();
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.jface.preference.PreferencePage#performApply()
-     */
-    @Override
-    protected void performApply() {
-        save();
-        super.performApply();
-    }
-    
-    private void save() {
-        try {
-            PreferenceStore store = SdkStatsService.getPreferenceStore();
-            if (store !=  null) {
-                store.setValue(SdkStatsService.PING_OPT_IN, mOptInCheckBox.getBooleanValue());
-                store.save();
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestHelper.java
deleted file mode 100644
index cd238d2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestHelper.java
+++ /dev/null
@@ -1,241 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.xml.sax.InputSource;
-
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathExpressionException;
-
-/**
- * Utility class that manages the AndroidManifest.xml file.
- * <p/>
- * All the get method work by XPath. Repeated calls to those may warrant using
- * {@link AndroidManifestParser} instead.
- */
-public class AndroidManifestHelper {
-    private IFile mManifestIFile;
-    private File mManifestFile;
-    private XPath mXPath;
-
-    /**
-     * Creates an AndroidManifest based on an existing Eclipse {@link IProject} object.
-     * </p>
-     * Use {@link #exists()} to check if the manifest file really exists in the project.
-     *
-     * @param project The project to search for the manifest.
-     */
-    public AndroidManifestHelper(IProject project) {
-        mXPath = AndroidXPathFactory.newXPath();
-        mManifestIFile = getManifest(project);
-    }
-    
-    /**
-     * Creates an AndroidManifest based on a file path.
-     * <p/>
-     * Use {@link #exists()} to check if the manifest file really exists.
-     *
-     * @param osManifestFilePath the os path to the AndroidManifest.xml file.
-     */
-    public AndroidManifestHelper(String osManifestFilePath) {
-        mXPath = AndroidXPathFactory.newXPath();
-        mManifestFile = new File(osManifestFilePath);
-    }
-
-
-    /**
-     * Returns the underlying {@link IFile} for the android manifest XML file, if found in the
-     * given Eclipse project.
-     *
-     * Always return null if the constructor that takes an {@link IProject} was NOT called.
-     *
-     * @return The IFile for the androidManifest.xml or null if no such file could be found.
-     */
-    public IFile getManifestIFile() {
-        return mManifestIFile;
-    }
-    
-    /**
-     * Returns the underlying {@link File} for the android manifest XML file.
-     */
-    public File getManifestFile() {
-        if (mManifestIFile != null) {
-            return mManifestIFile.getLocation().toFile();
-        }
-        
-        return mManifestFile;
-    }
-
-     /**
-     * Returns the package name defined in the manifest file.
-     *
-     * @return A String object with the package or null if any error happened.
-     */
-    public String getPackageName() {
-        try {
-            return mXPath.evaluate("/manifest/@package", getSource());  //$NON-NLS-1$
-        } catch (XPathExpressionException e1) {
-            // If the XPath failed to evaluate, we'll return null.
-        } catch (Exception e) {
-            // if this happens this is due to the resource being out of sync.
-            // so we must refresh it and do it again
-
-            // for any other kind of exception we must return null as well;
-        }
-
-        return null;
-    }
-
-    /**
-     * Returns the minSdkVersion defined in the manifest file.
-     *
-     * @return A String object with the package or null if any error happened.
-     */
-    public String getMinSdkVersion() {
-        try {
-            return mXPath.evaluate("/manifest/uses-sdk/@"                       //$NON-NLS-1$
-                    + AndroidXPathFactory.DEFAULT_NS_PREFIX
-                    + ":minSdkVersion", getSource());                           //$NON-NLS-1$
-        } catch (XPathExpressionException e1) {
-            // If the XPath failed to evaluate, we'll return null.
-        } catch (Exception e) {
-            // if this happens this is due to the resource being out of sync.
-            // so we must refresh it and do it again
-
-            // for any other kind of exception we must return null as well;
-        }
-
-        return null;
-    }
-    /**
-     * Returns the i-th activity defined in the manifest file.
-     *
-     * @param index The 1-based index of the activity to return.
-     * @return A String object with the activity or null if any error happened.
-     */
-    public String getActivityName(int index) {
-        try {
-            return mXPath.evaluate("/manifest/application/activity["            //$NON-NLS-1$
-                    + index
-                    + "]/@"                                                     //$NON-NLS-1$
-                    + AndroidXPathFactory.DEFAULT_NS_PREFIX +":name",           //$NON-NLS-1$
-                    getSource());
-        } catch (XPathExpressionException e1) {
-            // If the XPath failed to evaluate, we'll return null.
-        } catch (Exception e) {
-            // if this happens this is due to the resource being out of sync.
-            // so we must refresh it and do it again
-
-            // for any other kind of exception we must return null as well;
-        }
-        return null;
-    }
-
-    /**
-     * Returns an IFile object representing the manifest for the specified
-     * project.
-     *
-     * @param project The project containing the manifest file.
-     * @return An IFile object pointing to the manifest or null if the manifest
-     *         is missing.
-     */
-    public static IFile getManifest(IProject project) {
-        IResource r = project.findMember(AndroidConstants.WS_SEP
-                + AndroidConstants.FN_ANDROID_MANIFEST);
-
-        if (r == null || r.exists() == false || (r instanceof IFile) == false) {
-            return null;
-        }
-        return (IFile) r;
-    }
-
-    /**
-     * Combines a java package, with a class value from the manifest to make a fully qualified
-     * class name
-     * @param javaPackage the java package from the manifest.
-     * @param className the class name from the manifest. 
-     * @return the fully qualified class name.
-     */
-    public static String combinePackageAndClassName(String javaPackage, String className) {
-        if (className == null || className.length() == 0) {
-            return javaPackage;
-        }
-        if (javaPackage == null || javaPackage.length() == 0) {
-            return className;
-        }
-
-        // the class name can be a subpackage (starts with a '.'
-        // char), a simple class name (no dot), or a full java package
-        boolean startWithDot = (className.charAt(0) == '.');
-        boolean hasDot = (className.indexOf('.') != -1);
-        if (startWithDot || hasDot == false) {
-
-            // add the concatenation of the package and class name
-            if (startWithDot) {
-                return javaPackage + className;
-            } else {
-                return javaPackage + '.' + className;
-            }
-        } else {
-            // just add the class as it should be a fully qualified java name.
-            return className;
-        }
-    }
-    
-    
-
-    /**
-     * Returns true either if an androidManifest.xml file was found in the project
-     * or if the given file path exists.
-     */
-    public boolean exists() {
-        if (mManifestIFile != null) {
-            return mManifestIFile.exists();
-        } else if (mManifestFile != null) {
-            return mManifestFile.exists();
-        }
-        
-        return false;
-    }
-
-    /**
-     * Returns an InputSource for XPath.
-     *
-     * @throws FileNotFoundException if file does not exist.
-     * @throws CoreException if the {@link IFile} does not exist.
-     */
-    private InputSource getSource() throws FileNotFoundException, CoreException {
-        if (mManifestIFile != null) {
-            return new InputSource(mManifestIFile.getContents());
-        } else if (mManifestFile != null) {
-            return new InputSource(new FileReader(mManifestFile));
-        }
-        
-        return null;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestParser.java
deleted file mode 100644
index 850c59d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidManifestParser.java
+++ /dev/null
@@ -1,661 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.XmlErrorHandler.XmlErrorListener;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jdt.core.IJavaProject;
-import org.xml.sax.Attributes;
-import org.xml.sax.InputSource;
-import org.xml.sax.Locator;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Set;
-import java.util.TreeSet;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-public class AndroidManifestParser {
-
-    private final static String ATTRIBUTE_PACKAGE = "package"; //$NON-NLS-1$
-    private final static String ATTRIBUTE_NAME = "name"; //$NON-NLS-1$
-    private final static String ATTRIBUTE_PROCESS = "process"; //$NON-NLS-$
-    private final static String ATTRIBUTE_DEBUGGABLE = "debuggable"; //$NON-NLS-$
-    private final static String ATTRIBUTE_MIN_SDK_VERSION = "minSdkVersion"; //$NON-NLS-$
-    private final static String NODE_MANIFEST = "manifest"; //$NON-NLS-1$
-    private final static String NODE_APPLICATION = "application"; //$NON-NLS-1$
-    private final static String NODE_ACTIVITY = "activity"; //$NON-NLS-1$
-    private final static String NODE_SERVICE = "service"; //$NON-NLS-1$
-    private final static String NODE_RECEIVER = "receiver"; //$NON-NLS-1$
-    private final static String NODE_PROVIDER = "provider"; //$NON-NLS-1$
-    private final static String NODE_INTENT = "intent-filter"; //$NON-NLS-1$
-    private final static String NODE_ACTION = "action"; //$NON-NLS-1$
-    private final static String NODE_CATEGORY = "category"; //$NON-NLS-1$
-    private final static String NODE_USES_SDK = "uses-sdk"; //$NON-NLS-1$
-
-    private final static int LEVEL_MANIFEST = 0;
-    private final static int LEVEL_APPLICATION = 1;
-    private final static int LEVEL_ACTIVITY = 2;
-    private final static int LEVEL_INTENT_FILTER = 3;
-    private final static int LEVEL_CATEGORY = 4;
-
-    private final static String ACTION_MAIN = "android.intent.action.MAIN"; //$NON-NLS-1$
-    private final static String CATEGORY_LAUNCHER = "android.intent.category.LAUNCHER"; //$NON-NLS-1$
-    
-    private static class ManifestHandler extends XmlErrorHandler {
-        
-        //--- data read from the parsing
-        
-        /** Application package */
-        private String mPackage;
-        /** List of all activities */
-        private final ArrayList<String> mActivities = new ArrayList<String>();
-        /** Launcher activity */
-        private String mLauncherActivity = null;
-        /** list of process names declared by the manifest */
-        private Set<String> mProcesses = null;
-        /** debuggable attribute value. If null, the attribute is not present. */
-        private Boolean mDebuggable = null;
-        /** API level requirement. if 0 the attribute was not present. */
-        private int mApiLevelRequirement = 0;
-
-        //--- temporary data/flags used during parsing
-        private IJavaProject mJavaProject;
-        private boolean mGatherData = false;
-        private boolean mMarkErrors = false;
-        private int mCurrentLevel = 0;
-        private int mValidLevel = 0;
-        private boolean mFoundMainAction = false;
-        private boolean mFoundLauncherCategory = false;
-        private String mCurrentActivity = null;
-        private Locator mLocator;
-        
-        /**
-         * 
-         * @param manifestFile
-         * @param errorListener
-         * @param gatherData
-         * @param javaProject
-         * @param markErrors
-         */
-        ManifestHandler(IFile manifestFile, XmlErrorListener errorListener,
-                boolean gatherData, IJavaProject javaProject, boolean markErrors) {
-            super(manifestFile, errorListener);
-            mGatherData = gatherData;
-            mJavaProject = javaProject;
-            mMarkErrors = markErrors;
-        }
-
-        /**
-         * Returns the package defined in the manifest, if found.
-         * @return The package name or null if not found.
-         */
-        String getPackage() {
-            return mPackage;
-        }
-        
-        /** 
-         * Returns the list of activities found in the manifest.
-         * @return An array of fully qualified class names, or empty if no activity were found.
-         */
-        String[] getActivities() {
-            return mActivities.toArray(new String[mActivities.size()]);
-        }
-        
-        /**
-         * Returns the name of one activity found in the manifest, that is configured to show
-         * up in the HOME screen.  
-         * @return the fully qualified name of a HOME activity or null if none were found. 
-         */
-        String getLauncherActivity() {
-            return mLauncherActivity;
-        }
-        
-        /**
-         * Returns the list of process names declared by the manifest.
-         */
-        String[] getProcesses() {
-            if (mProcesses != null) {
-                return mProcesses.toArray(new String[mProcesses.size()]);
-            }
-            
-            return new String[0];
-        }
-        
-        /**
-         * Returns the <code>debuggable</code> attribute value or null if it is not set.
-         */
-        Boolean getDebuggable() {
-            return mDebuggable;
-        }
-        
-        /**
-         * Returns the <code>minSdkVersion</code> attribute, or 0 if it's not set. 
-         */
-        int getApiLevelRequirement() {
-            return mApiLevelRequirement;
-        }
-        
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#setDocumentLocator(org.xml.sax.Locator)
-         */
-        @Override
-        public void setDocumentLocator(Locator locator) {
-            mLocator = locator;
-            super.setDocumentLocator(locator);
-        }
-        
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#startElement(java.lang.String, java.lang.String,
-         * java.lang.String, org.xml.sax.Attributes)
-         */
-        @Override
-        public void startElement(String uri, String localName, String name, Attributes attributes)
-                throws SAXException {
-            try {
-                if (mGatherData == false) {
-                    return;
-                }
-
-                // if we're at a valid level
-                if (mValidLevel == mCurrentLevel) {
-                    String value;
-                    switch (mValidLevel) {
-                        case LEVEL_MANIFEST:
-                            if (NODE_MANIFEST.equals(localName)) {
-                                // lets get the package name.
-                                mPackage = getAttributeValue(attributes, ATTRIBUTE_PACKAGE,
-                                        false /* hasNamespace */);
-                                mValidLevel++;
-                            }
-                            break;
-                        case LEVEL_APPLICATION:
-                            if (NODE_APPLICATION.equals(localName)) {
-                                value = getAttributeValue(attributes, ATTRIBUTE_PROCESS,
-                                        true /* hasNamespace */);
-                                if (value != null) {
-                                    addProcessName(value);
-                                }
-                                
-                                value = getAttributeValue(attributes, ATTRIBUTE_DEBUGGABLE,
-                                        true /* hasNamespace*/);
-                                if (value != null) {
-                                    mDebuggable = Boolean.parseBoolean(value);
-                                }
-                                
-                                mValidLevel++;
-                            } else if (NODE_USES_SDK.equals(localName)) {
-                                value = getAttributeValue(attributes, ATTRIBUTE_MIN_SDK_VERSION,
-                                        true /* hasNamespace */);
-                                
-                                try {
-                                    mApiLevelRequirement = Integer.parseInt(value);
-                                } catch (NumberFormatException e) {
-                                    handleError(e, -1 /* lineNumber */);
-                                }
-                            }
-                            break;
-                        case LEVEL_ACTIVITY:
-                            if (NODE_ACTIVITY.equals(localName)) {
-                                processActivityNode(attributes);
-                                mValidLevel++;
-                            } else if (NODE_SERVICE.equals(localName)) {
-                                processNode(attributes, AndroidConstants.CLASS_SERVICE);
-                                mValidLevel++;
-                            } else if (NODE_RECEIVER.equals(localName)) {
-                                processNode(attributes, AndroidConstants.CLASS_BROADCASTRECEIVER);
-                                mValidLevel++;
-                            } else if (NODE_PROVIDER.equals(localName)) {
-                                processNode(attributes, AndroidConstants.CLASS_CONTENTPROVIDER);
-                                mValidLevel++;
-                            }
-                            break;
-                        case LEVEL_INTENT_FILTER:
-                            // only process this level if we are in an activity
-                            if (mCurrentActivity != null && NODE_INTENT.equals(localName)) {
-                                // if we're at the intent level, lets reset some flag to
-                                // be used when parsing the children
-                                mFoundMainAction = false;
-                                mFoundLauncherCategory = false;
-                                mValidLevel++;
-                            }
-                            break;
-                        case LEVEL_CATEGORY:
-                            if (mCurrentActivity != null && mLauncherActivity == null) {
-                                if (NODE_ACTION.equals(localName)) {
-                                    // get the name attribute
-                                    if (ACTION_MAIN.equals(
-                                            getAttributeValue(attributes, ATTRIBUTE_NAME,
-                                                    true /* hasNamespace */))) {
-                                        mFoundMainAction = true;
-                                    }
-                                } else if (NODE_CATEGORY.equals(localName)) {
-                                    if (CATEGORY_LAUNCHER.equals(
-                                            getAttributeValue(attributes, ATTRIBUTE_NAME,
-                                                    true /* hasNamespace */))) {
-                                        mFoundLauncherCategory = true;
-                                    }
-                                }
-                                
-                                // no need to increase mValidLevel as we don't process anything
-                                // below this level.
-                            }
-                            break;
-                    }
-                }
-
-                mCurrentLevel++;
-            } finally {
-                super.startElement(uri, localName, name, attributes);
-            }
-        }
-
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#endElement(java.lang.String, java.lang.String,
-         * java.lang.String)
-         */
-        @Override
-        public void endElement(String uri, String localName, String name) throws SAXException {
-            try {
-                if (mGatherData == false) {
-                    return;
-                }
-    
-                // decrement the levels.
-                if (mValidLevel == mCurrentLevel) {
-                    mValidLevel--;
-                }
-                mCurrentLevel--;
-                
-                // if we're at a valid level
-                // process the end of the element
-                if (mValidLevel == mCurrentLevel) {
-                    switch (mValidLevel) {
-                        case LEVEL_ACTIVITY:
-                            mCurrentActivity = null;
-                            break;
-                        case LEVEL_INTENT_FILTER:
-                            // if we found both a main action and a launcher category, this is our
-                            // launcher activity!
-                            if (mCurrentActivity != null &&
-                                    mFoundMainAction && mFoundLauncherCategory) {
-                                mLauncherActivity = mCurrentActivity;
-                            }
-                            break;
-                        default:
-                            break;
-                    }
-    
-                }
-            } finally {
-                super.endElement(uri, localName, name);
-            }
-        }
-        
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#error(org.xml.sax.SAXParseException)
-         */
-        @Override
-        public void error(SAXParseException e) {
-            if (mMarkErrors) {
-                handleError(e, e.getLineNumber());
-            }
-        }
-
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#fatalError(org.xml.sax.SAXParseException)
-         */
-        @Override
-        public void fatalError(SAXParseException e) {
-            if (mMarkErrors) {
-                handleError(e, e.getLineNumber());
-            }
-        }
-
-        /* (non-Javadoc)
-         * @see org.xml.sax.helpers.DefaultHandler#warning(org.xml.sax.SAXParseException)
-         */
-        @Override
-        public void warning(SAXParseException e) throws SAXException {
-            if (mMarkErrors) {
-                super.warning(e);
-            }
-        }
-        
-        /**
-         * Processes the activity node.
-         * @param attributes the attributes for the activity node.
-         */
-        private void processActivityNode(Attributes attributes) {
-            // lets get the activity name, and add it to the list
-            String activityName = getAttributeValue(attributes, ATTRIBUTE_NAME,
-                    true /* hasNamespace */);
-            if (activityName != null) {
-                mCurrentActivity = AndroidManifestHelper.combinePackageAndClassName(mPackage,
-                        activityName);
-                mActivities.add(mCurrentActivity);
-                
-                if (mMarkErrors) {
-                    checkClass(mCurrentActivity, AndroidConstants.CLASS_ACTIVITY,
-                            true /* testVisibility */);
-                }
-            } else {
-                // no activity found! Aapt will output an error,
-                // so we don't have to do anything
-                mCurrentActivity = activityName;
-            }
-            
-            String processName = getAttributeValue(attributes, ATTRIBUTE_PROCESS,
-                    true /* hasNamespace */);
-            if (processName != null) {
-                addProcessName(processName);
-            }
-        }
-
-        /**
-         * Processes the service/receiver/provider nodes.
-         * @param attributes the attributes for the activity node.
-         * @param superClassName the fully qualified name of the super class that this
-         * node is representing
-         */
-        private void processNode(Attributes attributes, String superClassName) {
-            // lets get the class name, and check it if required.
-            String serviceName = getAttributeValue(attributes, ATTRIBUTE_NAME,
-                    true /* hasNamespace */);
-            if (serviceName != null) {
-                serviceName = AndroidManifestHelper.combinePackageAndClassName(mPackage,
-                        serviceName);
-                
-                if (mMarkErrors) {
-                    checkClass(serviceName, superClassName, false /* testVisibility */);
-                }
-            }
-            
-            String processName = getAttributeValue(attributes, ATTRIBUTE_PROCESS,
-                    true /* hasNamespace */);
-            if (processName != null) {
-                addProcessName(processName);
-            }
-        }
-
-        /**
-         * Checks that a class is valid and can be used in the Android Manifest.
-         * <p/>
-         * Errors are put as {@link IMarker} on the manifest file. 
-         * @param className the fully qualified name of the class to test.
-         * @param superClassName the fully qualified name of the class it is supposed to extend.
-         * @param testVisibility if <code>true</code>, the method will check the visibility of
-         * the class or of its constructors.
-         */
-        private void checkClass(String className, String superClassName, boolean testVisibility) {
-            // we need to check the validity of the activity.
-            String result = BaseProjectHelper.testClassForManifest(mJavaProject,
-                    className, superClassName, testVisibility);
-            if (result != BaseProjectHelper.TEST_CLASS_OK) {
-                // get the line number
-                int line = mLocator.getLineNumber();
-                
-                // mark the file
-                IMarker marker = BaseProjectHelper.addMarker(getFile(),
-                        AndroidConstants.MARKER_ANDROID,
-                        result, line, IMarker.SEVERITY_ERROR);
-                
-                // add custom attributes to be used by the manifest editor.
-                if (marker != null) {
-                    try {
-                        marker.setAttribute(AndroidConstants.MARKER_ATTR_TYPE,
-                                AndroidConstants.MARKER_ATTR_TYPE_ACTIVITY);
-                        marker.setAttribute(AndroidConstants.MARKER_ATTR_CLASS, className);
-                    } catch (CoreException e) {
-                    }
-                }
-            }
-            
-        }
-
-        /**
-         * Searches through the attributes list for a particular one and returns its value.
-         * @param attributes the attribute list to search through
-         * @param attributeName the name of the attribute to look for.
-         * @param hasNamespace Indicates whether the attribute has an android namespace.
-         * @return a String with the value or null if the attribute was not found.
-         * @see SdkConstants#NS_RESOURCES
-         */
-        private String getAttributeValue(Attributes attributes, String attributeName,
-                boolean hasNamespace) {
-            int count = attributes.getLength();
-            for (int i = 0 ; i < count ; i++) {
-                if (attributeName.equals(attributes.getLocalName(i)) &&
-                        ((hasNamespace &&
-                                SdkConstants.NS_RESOURCES.equals(attributes.getURI(i))) ||
-                                (hasNamespace == false && attributes.getURI(i).length() == 0))) {
-                    return attributes.getValue(i);
-                }
-            }
-            
-            return null;
-        }
-        
-        private void addProcessName(String processName) {
-            if (mProcesses == null) {
-                mProcesses = new TreeSet<String>();
-            }
-            
-            mProcesses.add(processName);
-        }
-    }
-
-    private static SAXParserFactory sParserFactory;
-    
-    private final String mJavaPackage;
-    private final String[] mActivities;
-    private final String mLauncherActivity;
-    private final String[] mProcesses;
-    private final Boolean mDebuggable;
-    private final int mApiLevelRequirement;
-
-    static {
-        sParserFactory = SAXParserFactory.newInstance();
-        sParserFactory.setNamespaceAware(true);
-    }
-    
-    /**
-     * Parses the Android Manifest, and returns an object containing
-     * the result of the parsing.
-     * @param javaProject The java project.
-     * @param manifestFile the {@link IFile} representing the manifest file.
-     * @param errorListener
-     * @param gatherData indicates whether the parsing will extract data from the manifest.
-     * @param markErrors indicates whether the error found during parsing should put a
-     * marker on the file. For class validation errors to put a marker, <code>gatherData</code>
-     * must be set to <code>true</code>
-     * @return an {@link AndroidManifestParser} or null if the parsing failed.
-     * @throws CoreException
-     */
-    public static AndroidManifestParser parse(IJavaProject javaProject, IFile manifestFile,
-            XmlErrorListener errorListener, boolean gatherData, boolean markErrors)
-            throws CoreException {
-        try {
-            SAXParser parser = sParserFactory.newSAXParser();
-
-            ManifestHandler manifestHandler = new ManifestHandler(manifestFile,
-                    errorListener, gatherData, javaProject, markErrors);
-
-            parser.parse(new InputSource(manifestFile.getContents()), manifestHandler);
-            
-            // get the result from the handler
-            
-            return new AndroidManifestParser(manifestHandler.getPackage(),
-                    manifestHandler.getActivities(), manifestHandler.getLauncherActivity(),
-                    manifestHandler.getProcesses(), manifestHandler.getDebuggable(),
-                    manifestHandler.getApiLevelRequirement());
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (IOException e) {
-        } finally {
-        }
-
-        return null;
-    }
-
-    /**
-     * Parses the Android Manifest for the specified project, and returns an object containing
-     * the result of the parsing.
-     * @param javaProject The java project. Required if <var>markErrors</var> is <code>true</code>
-     * @param errorListener the {@link XmlErrorListener} object being notified of the presence
-     * of errors. Optional.
-     * @param gatherData indicates whether the parsing will extract data from the manifest.
-     * @param markErrors indicates whether the error found during parsing should put a
-     * marker on the file. For class validation errors to put a marker, <code>gatherData</code>
-     * must be set to <code>true</code>
-     * @return an {@link AndroidManifestParser} or null if the parsing failed.
-     * @throws CoreException
-     */
-    public static AndroidManifestParser parse(IJavaProject javaProject,
-            XmlErrorListener errorListener, boolean gatherData, boolean markErrors)
-            throws CoreException {
-        try {
-            SAXParser parser = sParserFactory.newSAXParser();
-            
-            IFile manifestFile = AndroidManifestHelper.getManifest(javaProject.getProject());
-            if (manifestFile != null) {
-                ManifestHandler manifestHandler = new ManifestHandler(manifestFile,
-                        errorListener, gatherData, javaProject, markErrors);
-
-                parser.parse(new InputSource(manifestFile.getContents()), manifestHandler);
-                
-                // get the result from the handler
-                return new AndroidManifestParser(manifestHandler.getPackage(),
-                        manifestHandler.getActivities(), manifestHandler.getLauncherActivity(),
-                        manifestHandler.getProcesses(), manifestHandler.getDebuggable(),
-                        manifestHandler.getApiLevelRequirement());
-            }
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (IOException e) {
-        } finally {
-        }
-        
-        return null;
-    }
-
-    /**
-     * Parses the manifest file, collects data, and checks for errors.
-     * @param javaProject The java project. Required.
-     * @param manifestFile The manifest file to parse.
-     * @param errorListener the {@link XmlErrorListener} object being notified of the presence
-     * of errors. Optional.
-     * @return an {@link AndroidManifestParser} or null if the parsing failed.
-     * @throws CoreException
-     */
-    public static AndroidManifestParser parseForError(IJavaProject javaProject, IFile manifestFile,
-            XmlErrorListener errorListener) throws CoreException {
-        return parse(javaProject, manifestFile, errorListener, true, true);
-    }
-
-    /**
-     * Parses the manifest file, and collects data.
-     * @param manifestFile The manifest file to parse.
-     * @return an {@link AndroidManifestParser} or null if the parsing failed.
-     * @throws CoreException
-     */
-    public static AndroidManifestParser parseForData(IFile manifestFile) throws CoreException {
-        return parse(null /* javaProject */, manifestFile, null /* errorListener */,
-                true /* gatherData */, false /* markErrors */);
-    }
-
-    /**
-     * Returns the package defined in the manifest, if found.
-     * @return The package name or null if not found.
-     */
-    public String getPackage() {
-        return mJavaPackage;
-    }
-
-    /** 
-     * Returns the list of activities found in the manifest.
-     * @return An array of fully qualified class names, or empty if no activity were found.
-     */
-    public String[] getActivities() {
-        return mActivities;
-    }
-
-    /**
-     * Returns the name of one activity found in the manifest, that is configured to show
-     * up in the HOME screen.  
-     * @return the fully qualified name of a HOME activity or null if none were found. 
-     */
-    public String getLauncherActivity() {
-        return mLauncherActivity;
-    }
-    
-    /**
-     * Returns the list of process names declared by the manifest.
-     */
-    public String[] getProcesses() {
-        return mProcesses;
-    }
-    
-    /**
-     * Returns the debuggable attribute value or <code>null</code> if it is not set.
-     */
-    public Boolean getDebuggable() {
-        return mDebuggable;
-    }
-    
-    /**
-     * Returns the <code>minSdkVersion</code> attribute, or 0 if it's not set. 
-     */
-    public int getApiLevelRequirement() {
-        return mApiLevelRequirement;
-    }
-
-    
-    /**
-     * Private constructor to enforce using
-     * {@link #parse(IJavaProject, XmlErrorListener, boolean, boolean)},
-     * {@link #parse(IJavaProject, IFile, XmlErrorListener, boolean, boolean)},
-     * or {@link #parseForError(IJavaProject, IFile, XmlErrorListener)} to get an
-     * {@link AndroidManifestParser} object.
-     * @param javaPackage the package parsed from the manifest.
-     * @param activities the list of activities parsed from the manifest.
-     * @param launcherActivity the launcher activity parser from the manifest.
-     * @param processes the list of custom processes declared in the manifest.
-     * @param debuggable the debuggable attribute, or null if not set.
-     * @param apiLevelRequirement the minSdkVersion attribute value or 0 if not set.
-     */
-    private AndroidManifestParser(String javaPackage, String[] activities,
-            String launcherActivity, String[] processes, Boolean debuggable,
-            int apiLevelRequirement) {
-        mJavaPackage = javaPackage;
-        mActivities = activities;
-        mLauncherActivity = launcherActivity;
-        mProcesses = processes;
-        mDebuggable = debuggable;
-        mApiLevelRequirement = apiLevelRequirement;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidXPathFactory.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidXPathFactory.java
deleted file mode 100644
index 0f1e255..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/AndroidXPathFactory.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.sdklib.SdkConstants;
-
-import java.util.Iterator;
-
-import javax.xml.XMLConstants;
-import javax.xml.namespace.NamespaceContext;
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathFactory;
-
-/**
- * XPath factory with automatic support for the android namespace.
- */
-public class AndroidXPathFactory {
-    public final static String DEFAULT_NS_PREFIX = "android"; //$NON-NLS-1$
-
-    private final static XPathFactory sFactory = XPathFactory.newInstance();
-    
-    /** Namespace context for Android resource XML files. */
-    private static class AndroidNamespaceContext implements NamespaceContext {
-        private String mAndroidPrefix;
-
-        /**
-         * Construct the context with the prefix associated with the android namespace.
-         * @param androidPrefix the Prefix
-         */
-        public AndroidNamespaceContext(String androidPrefix) {
-            mAndroidPrefix = androidPrefix;
-        }
-
-        public String getNamespaceURI(String prefix) {
-            if (prefix != null) {
-                if (prefix.equals(mAndroidPrefix)) {
-                    return SdkConstants.NS_RESOURCES;
-                }
-            }
-            
-            return XMLConstants.NULL_NS_URI;
-        }
-
-        public String getPrefix(String namespaceURI) {
-            // This isn't necessary for our use.
-            assert false;
-            return null;
-        }
-
-        public Iterator<?> getPrefixes(String namespaceURI) {
-            // This isn't necessary for our use.
-            assert false;
-            return null;
-        }
-    }
-    
-    /**
-     * Creates a new XPath object, specifying which prefix in the query is used for the
-     * android namespace.
-     * @param androidPrefix The namespace prefix.
-     */
-    public static XPath newXPath(String androidPrefix) {
-        XPath xpath = sFactory.newXPath();
-        xpath.setNamespaceContext(new AndroidNamespaceContext(androidPrefix));
-        return xpath;
-    }
-
-    /**
-     * Creates a new XPath object using the default prefix for the android namespace.
-     * @see #DEFAULT_NS_PREFIX
-     */
-    public static XPath newXPath() {
-        return newXPath(DEFAULT_NS_PREFIX);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/BaseProjectHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/BaseProjectHelper.java
deleted file mode 100644
index bd8b444..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/BaseProjectHelper.java
+++ /dev/null
@@ -1,452 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.XmlErrorHandler.XmlErrorListener;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.Flags;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IMethod;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jdt.ui.actions.OpenJavaPerspectiveAction;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.texteditor.IDocumentProvider;
-import org.eclipse.ui.texteditor.ITextEditor;
-
-import java.util.ArrayList;
-
-/**
- * Utility methods to manipulate projects.
- */
-public final class BaseProjectHelper {
-
-    public static final String TEST_CLASS_OK = null;
-
-    /**
-     * returns a list of source classpath for a specified project
-     * @param javaProject
-     * @return a list of path relative to the workspace root.
-     */
-    public static ArrayList<IPath> getSourceClasspaths(IJavaProject javaProject) {
-        ArrayList<IPath> sourceList = new ArrayList<IPath>();
-        IClasspathEntry[] classpaths = javaProject.readRawClasspath();
-        if (classpaths != null) {
-            for (IClasspathEntry e : classpaths) {
-                if (e.getEntryKind() == IClasspathEntry.CPE_SOURCE) {
-                    sourceList.add(e.getPath());
-                }
-            }
-        }
-        return sourceList;
-    }
-
-    /**
-     * Adds a marker to a file on a specific line. This methods catches thrown
-     * {@link CoreException}, and returns null instead.
-     * @param file the file to be marked
-     * @param markerId The id of the marker to add.
-     * @param message the message associated with the mark
-     * @param lineNumber the line number where to put the mark. If line is < 1, it puts the marker
-     * on line 1.
-     * @param severity the severity of the marker.
-     * @return the IMarker that was added or null if it failed to add one.
-     */
-    public final static IMarker addMarker(IResource file, String markerId,
-            String message, int lineNumber, int severity) {
-        try {
-            IMarker marker = file.createMarker(markerId);
-            marker.setAttribute(IMarker.MESSAGE, message);
-            marker.setAttribute(IMarker.SEVERITY, severity);
-            if (lineNumber < 1) {
-                lineNumber = 1;
-            }
-            marker.setAttribute(IMarker.LINE_NUMBER, lineNumber);
-
-            // on Windows, when adding a marker to a project, it takes a refresh for the marker
-            // to show. In order to fix this we're forcing a refresh of elements receiving
-            // markers (and only the element, not its children), to force the marker display.
-            file.refreshLocal(IResource.DEPTH_ZERO, new NullProgressMonitor());
-
-            return marker;
-        } catch (CoreException e) {
-            AdtPlugin.log(e, "Failed to add marker '%1$s' to '%2$s'", //$NON-NLS-1$
-                    markerId, file.getFullPath());
-        }
-        
-        return null;
-    }
-
-    /**
-     * Adds a marker to a resource. This methods catches thrown {@link CoreException},
-     * and returns null instead.
-     * @param resource the file to be marked
-     * @param markerId The id of the marker to add.
-     * @param message the message associated with the mark
-     * @param severity the severity of the marker.
-     * @return the IMarker that was added or null if it failed to add one.
-     */
-    public final static IMarker addMarker(IResource resource, String markerId,
-            String message, int severity) {
-        try {
-            IMarker marker = resource.createMarker(markerId);
-            marker.setAttribute(IMarker.MESSAGE, message);
-            marker.setAttribute(IMarker.SEVERITY, severity);
-
-            // on Windows, when adding a marker to a project, it takes a refresh for the marker
-            // to show. In order to fix this we're forcing a refresh of elements receiving
-            // markers (and only the element, not its children), to force the marker display.
-            resource.refreshLocal(IResource.DEPTH_ZERO, new NullProgressMonitor());
-
-            return marker;
-        } catch (CoreException e) {
-            AdtPlugin.log(e, "Failed to add marker '%1$s' to '%2$s'", //$NON-NLS-1$
-                    markerId, resource.getFullPath());
-        }
-        
-        return null;
-    }
-
-    /**
-     * Adds a marker to a resource. This method does not catch {@link CoreException} and instead
-     * throw them.
-     * @param resource the file to be marked
-     * @param markerId The id of the marker to add.
-     * @param message the message associated with the mark
-     * @param lineNumber the line number where to put the mark if != -1.
-     * @param severity the severity of the marker.
-     * @param priority the priority of the marker
-     * @return the IMarker that was added.
-     * @throws CoreException 
-     */
-    public final static IMarker addMarker(IResource resource, String markerId,
-            String message, int lineNumber, int severity, int priority) throws CoreException {
-        IMarker marker = resource.createMarker(markerId);
-        marker.setAttribute(IMarker.MESSAGE, message);
-        marker.setAttribute(IMarker.SEVERITY, severity);
-        if (lineNumber != -1) {
-            marker.setAttribute(IMarker.LINE_NUMBER, lineNumber);
-        }
-        marker.setAttribute(IMarker.PRIORITY, priority);
-
-        // on Windows, when adding a marker to a project, it takes a refresh for the marker
-        // to show. In order to fix this we're forcing a refresh of elements receiving
-        // markers (and only the element, not its children), to force the marker display.
-        resource.refreshLocal(IResource.DEPTH_ZERO, new NullProgressMonitor());
-
-        return marker;
-    }
-
-    /**
-     * Tests that a class name is valid for usage in the manifest.
-     * <p/>
-     * This tests the class existence, that it can be instantiated (ie it must not be abstract,
-     * nor non static if enclosed), and that it extends the proper super class (not necessarily
-     * directly)
-     * @param javaProject the {@link IJavaProject} containing the class.
-     * @param className the fully qualified name of the class to test.
-     * @param superClassName the fully qualified name of the expected super class.
-     * @param testVisibility if <code>true</code>, the method will check the visibility of the class
-     * or of its constructors.
-     * @return {@link #TEST_CLASS_OK} or an error message.
-     */
-    public final static String testClassForManifest(IJavaProject javaProject, String className,
-            String superClassName, boolean testVisibility) {
-        try {
-            // replace $ by .
-            String javaClassName = className.replaceAll("\\$", "\\."); //$NON-NLS-1$ //$NON-NLS-2$
-
-            // look for the IType object for this class
-            IType type = javaProject.findType(javaClassName);
-            if (type != null && type.exists()) {
-                // test that the class is not abstract
-                int flags = type.getFlags();
-                if (Flags.isAbstract(flags)) {
-                    return String.format("%1$s is abstract", className);
-                }
-                
-                // test whether the class is public or not.
-                if (testVisibility && Flags.isPublic(flags) == false) {
-                    // if its not public, it may have a public default constructor,
-                    // which would then be fine.
-                    IMethod basicConstructor = type.getMethod(type.getElementName(), new String[0]);
-                    if (basicConstructor != null && basicConstructor.exists()) {
-                        int constructFlags = basicConstructor.getFlags();
-                        if (Flags.isPublic(constructFlags) == false) {
-                            return String.format(
-                                    "%1$s or its default constructor must be public for the system to be able to instantiate it",
-                                    className);
-                        }
-                    } else {
-                        return String.format(
-                                "%1$s must be public, or the system will not be able to instantiate it.",
-                                className);
-                    }
-                }
-
-                // If it's enclosed, test that it's static. If its declaring class is enclosed
-                // as well, test that it is also static, and public.
-                IType declaringType = type;
-                do {
-                    IType tmpType = declaringType.getDeclaringType();
-                    if (tmpType != null) {
-                        if (tmpType.exists()) {
-                            flags = declaringType.getFlags();
-                            if (Flags.isStatic(flags) == false) {
-                                return String.format("%1$s is enclosed, but not static",
-                                        declaringType.getFullyQualifiedName());
-                            }
-                            
-                            flags = tmpType.getFlags();
-                            if (testVisibility && Flags.isPublic(flags) == false) {
-                                return String.format("%1$s is not public",
-                                        tmpType.getFullyQualifiedName());
-                            }
-                        } else {
-                            // if it doesn't exist, we need to exit so we may as well mark it null.
-                            tmpType = null;
-                        }
-                    }
-                    declaringType = tmpType;
-                } while (declaringType != null);
-
-                // test the class inherit from the specified super class.
-                // get the type hierarchy
-                ITypeHierarchy hierarchy = type.newSupertypeHierarchy(new NullProgressMonitor());
-                
-                // if the super class is not the reference class, it may inherit from
-                // it so we get its supertype. At some point it will be null and we
-                // will stop
-                IType superType = type;
-                boolean foundProperSuperClass = false;
-                while ((superType = hierarchy.getSuperclass(superType)) != null &&
-                        superType.exists()) {
-                    if (superClassName.equals(superType.getFullyQualifiedName())) {
-                        foundProperSuperClass = true;
-                    }
-                }
-                
-                // didn't find the proper superclass? return false.
-                if (foundProperSuperClass == false) {
-                    return String.format("%1$s does not extend %2$s", className, superClassName);
-                }
-                
-                return TEST_CLASS_OK;
-            } else {
-                return String.format("Class %1$s does not exist", className);
-            }
-        } catch (JavaModelException e) {
-            return String.format("%1$s: %2$s", className, e.getMessage());
-        }
-    }
-    
-    /**
-     * Parses the manifest file for errors.
-     * <p/>
-     * This starts by removing the current XML marker, and then parses the xml for errors, both
-     * of XML type and of Android type (checking validity of class files).
-     * @param manifestFile
-     * @param errorListener
-     * @throws CoreException
-     */
-    public static AndroidManifestParser parseManifestForError(IFile manifestFile,
-            XmlErrorListener errorListener) throws CoreException {
-        // remove previous markers
-        if (manifestFile.exists()) {
-            manifestFile.deleteMarkers(AndroidConstants.MARKER_XML, true, IResource.DEPTH_ZERO);
-            manifestFile.deleteMarkers(AndroidConstants.MARKER_ANDROID, true, IResource.DEPTH_ZERO);
-        }
-        
-        // and parse
-        return AndroidManifestParser.parseForError(
-                BaseProjectHelper.getJavaProject(manifestFile.getProject()),
-                manifestFile, errorListener);
-    }
-
-    /**
-     * Returns the {@link IJavaProject} for a {@link IProject} object.
-     * <p/>
-     * This checks if the project has the Java Nature first.
-     * @param project
-     * @return the IJavaProject or null if the project couldn't be created or if the project
-     * does not have the Java Nature.
-     * @throws CoreException
-     */
-    public static IJavaProject getJavaProject(IProject project) throws CoreException {
-        if (project != null && project.hasNature(JavaCore.NATURE_ID)) {
-            return JavaCore.create(project);
-        }
-        return null;
-    }
-    
-    /**
-     * Reveals a specific line in the source file defining a specified class,
-     * for a specific project.
-     * @param project
-     * @param className
-     * @param line
-     */
-    public static void revealSource(IProject project, String className, int line) {
-        // in case the type is enclosed, we need to replace the $ with .
-        className = className.replaceAll("\\$", "\\."); //$NON-NLS-1$ //$NON-NLS2$
-
-        // get the java project
-        IJavaProject javaProject = JavaCore.create(project);
-        
-        try {
-            // look for the IType matching the class name.
-            IType result = javaProject.findType(className);
-            if (result != null && result.exists()) {
-                // before we show the type in an editor window, we make sure the current
-                // workbench page has an editor area (typically the ddms perspective doesn't).
-                IWorkbench workbench = PlatformUI.getWorkbench();
-                IWorkbenchWindow window = workbench.getActiveWorkbenchWindow();
-                IWorkbenchPage page = window.getActivePage();
-                if (page.isEditorAreaVisible() == false) {
-                    // no editor area? we open the java perspective.
-                    new OpenJavaPerspectiveAction().run();
-                }
-                
-                IEditorPart editor = JavaUI.openInEditor(result);
-                if (editor instanceof ITextEditor) {
-                    // get the text editor that was just opened.
-                    ITextEditor textEditor = (ITextEditor)editor;
-                    
-                    IEditorInput input = textEditor.getEditorInput();
-                    
-                    // get the location of the line to show.
-                    IDocumentProvider documentProvider = textEditor.getDocumentProvider();
-                    IDocument document = documentProvider.getDocument(input);
-                    IRegion lineInfo = document.getLineInformation(line - 1);
-                    
-                    // select and reveal the line.
-                    textEditor.selectAndReveal(lineInfo.getOffset(), lineInfo.getLength());
-                }
-            }
-        } catch (JavaModelException e) {
-        } catch (PartInitException e) {
-        } catch (BadLocationException e) {
-        }
-    }
-    
-    /**
-     * Returns the list of android-flagged projects. This list contains projects that are opened
-     * in the workspace and that are flagged as android project (through the android nature)
-     * @return an array of IJavaProject, which can be empty if no projects match.
-     */
-    public static IJavaProject[] getAndroidProjects() {
-        IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
-        IJavaModel javaModel = JavaCore.create(workspaceRoot);
-
-        return getAndroidProjects(javaModel);
-    }
-
-    /**
-     * Returns the list of android-flagged projects for the specified java Model.
-     * This list contains projects that are opened in the workspace and that are flagged as android
-     * project (through the android nature)
-     * @param javaModel the Java Model object corresponding for the current workspace root.
-     * @return an array of IJavaProject, which can be empty if no projects match.
-     */
-    public static IJavaProject[] getAndroidProjects(IJavaModel javaModel) {
-        // get the java projects
-        IJavaProject[] javaProjectList = null;
-        try {
-            javaProjectList  = javaModel.getJavaProjects();
-        }
-        catch (JavaModelException jme) {
-            return new IJavaProject[0];
-        }
-
-        // temp list to build the android project array
-        ArrayList<IJavaProject> androidProjectList = new ArrayList<IJavaProject>();
-
-        // loop through the projects and add the android flagged projects to the temp list.
-        for (IJavaProject javaProject : javaProjectList) {
-            // get the workspace project object
-            IProject project = javaProject.getProject();
-
-            // check if it's an android project based on its nature
-            try {
-                if (project.hasNature(AndroidConstants.NATURE)) {
-                    androidProjectList.add(javaProject);
-                }
-            } catch (CoreException e) {
-                // this exception, thrown by IProject.hasNature(), means the project either doesn't
-                // exist or isn't opened. So, in any case we just skip it (the exception will
-                // bypass the ArrayList.add()
-            }
-        }
-
-        // return the android projects list.
-        return androidProjectList.toArray(new IJavaProject[androidProjectList.size()]);
-    }
-    
-    /**
-     * Returns the {@link IFolder} representing the output for the project.
-     * <p>
-     * The project must be a java project and be opened, or the method will return null.
-     * @param project the {@link IProject}
-     * @return an IFolder item or null.
-     */
-    public final static IFolder getOutputFolder(IProject project) {
-        try {
-            if (project.isOpen() && project.hasNature(JavaCore.NATURE_ID)) {
-                // get a java project from the normal project object
-                IJavaProject javaProject = JavaCore.create(project);
-    
-                IPath path = javaProject.getOutputLocation();
-                IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot();
-                IResource outputResource = wsRoot.findMember(path);
-                if (outputResource != null && outputResource.getType() == IResource.FOLDER) {
-                    return (IFolder)outputResource;
-                }
-            }
-        } catch (JavaModelException e) {
-            // Let's do nothing and return null
-        } catch (CoreException e) {
-            // Let's do nothing and return null
-        }
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ExportHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ExportHelper.java
deleted file mode 100644
index 4b169a1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ExportHelper.java
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.util.jar.JarEntry;
-import java.util.zip.ZipEntry;
-import java.util.zip.ZipInputStream;
-import java.util.zip.ZipOutputStream;
-
-/**
- * Export helper for project.
- */
-public final class ExportHelper {
-    
-    private static IExportCallback sCallback;
-
-    public interface IExportCallback {
-        void startExportWizard(IProject project);
-    }
-    
-    public static void setCallback(IExportCallback callback) {
-        sCallback = callback;
-    }
-    
-    public static void startExportWizard(IProject project) {
-        if (sCallback != null) {
-            sCallback.startExportWizard(project);
-        }
-    }
-
-    /**
-     * Exports an <b>unsigned</b> version of the application created by the given project.
-     * @param project the project to export
-     */
-    public static void exportProject(IProject project) {
-        Shell shell = Display.getCurrent().getActiveShell();
-
-        // get the java project to get the output directory
-        IFolder outputFolder = BaseProjectHelper.getOutputFolder(project);
-        if (outputFolder != null) {
-            IPath binLocation = outputFolder.getLocation();
-    
-            // make the full path to the package
-            String fileName = project.getName() + AndroidConstants.DOT_ANDROID_PACKAGE;
-    
-            File file = new File(binLocation.toOSString() + File.separator + fileName);
-    
-            if (file.exists() == false || file.isFile() == false) {
-                MessageDialog.openInformation(Display.getCurrent().getActiveShell(),
-                        "Android IDE Plug-in",
-                        String.format("Failed to export %1$s: %2$s doesn't exist!",
-                                project.getName(), file.getPath()));
-                return;
-            }
-    
-            // ok now pop up the file save window
-            FileDialog fileDialog = new FileDialog(shell, SWT.SAVE);
-    
-            fileDialog.setText("Export Project");
-            fileDialog.setFileName(fileName);
-    
-            String saveLocation = fileDialog.open();
-            if (saveLocation != null) {
-                // get the stream from the original file
-                
-                ZipInputStream zis = null;
-                ZipOutputStream zos = null;
-                FileInputStream input = null;
-                FileOutputStream output = null;
-
-                try {
-                    input = new FileInputStream(file);
-                    zis = new ZipInputStream(input);
-
-                    // get an output stream into the new file
-                    File saveFile = new File(saveLocation);
-                    output = new FileOutputStream(saveFile);
-                    zos = new ZipOutputStream(output);
-                } catch (FileNotFoundException e) {
-                    // only the input/output stream are throwing this exception.
-                    // so we only have to close zis if output is the one that threw.
-                    if (zis != null) {
-                        try {
-                            zis.close();
-                        } catch (IOException e1) {
-                            // pass
-                        }
-                    }
-                    
-                    MessageDialog.openInformation(shell, "Android IDE Plug-in",
-                            String.format("Failed to export %1$s: %2$s doesn't exist!",
-                                    project.getName(), file.getPath()));
-                    return;
-                }
-
-                try {
-                    ZipEntry entry;
-                    
-                    byte[] buffer = new byte[4096];
-
-                    while ((entry = zis.getNextEntry()) != null) {
-                        String name = entry.getName();
-                        
-                        // do not take directories or anything inside the META-INF folder since
-                        // we want to strip the signature.
-                        if (entry.isDirectory() || name.startsWith("META-INF/")) { //$NON-NL1$
-                            continue;
-                        }
-            
-                        ZipEntry newEntry;
-            
-                        // Preserve the STORED method of the input entry.
-                        if (entry.getMethod() == JarEntry.STORED) {
-                            newEntry = new JarEntry(entry);
-                        } else {
-                            // Create a new entry so that the compressed len is recomputed.
-                            newEntry = new JarEntry(name);
-                        }
-                        
-                        // add the entry to the jar archive
-                        zos.putNextEntry(newEntry);
-
-                        // read the content of the entry from the input stream, and write it into the archive.
-                        int count; 
-                        while ((count = zis.read(buffer)) != -1) {
-                            zos.write(buffer, 0, count);
-                        }
-
-                        // close the entry for this file
-                        zos.closeEntry();
-                        zis.closeEntry();
-
-                    }
-    
-                } catch (IOException e) {
-                    MessageDialog.openInformation(shell, "Android IDE Plug-in",
-                            String.format("Failed to export %1$s: %2$s",
-                                    project.getName(), e.getMessage()));
-                } finally {
-                    try {
-                        zos.close();
-                    } catch (IOException e) {
-                        // pass
-                    }
-                    try {
-                        zis.close();
-                    } catch (IOException e) {
-                        // pass
-                    }
-                }
-            }
-        } else {
-            MessageDialog.openInformation(shell, "Android IDE Plug-in",
-                    String.format("Failed to export %1$s: Could not get project output location",
-                            project.getName()));
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ProjectChooserHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ProjectChooserHelper.java
deleted file mode 100644
index 0c43499..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/ProjectChooserHelper.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.ui.JavaElementLabelProvider;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.window.Window;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.ElementListSelectionDialog;
-
-/**
- * Helper class to deal with displaying a project choosing dialog that lists only the
- * projects with the Android nature.
- */
-public class ProjectChooserHelper {
-
-    private final Shell mParentShell;
-
-    /**
-     * List of current android projects. Since the dialog is modal, we'll just get
-     * the list once on-demand.
-     */
-    private IJavaProject[] mAndroidProjects;
-
-    public ProjectChooserHelper(Shell parentShell) {
-        mParentShell = parentShell;
-    }
-    /**
-     * Displays a project chooser dialog which lists all available projects with the Android nature.
-     * <p/>
-     * The list of project is built from Android flagged projects currently opened in the workspace.
-     *
-     * @param projectName If non null and not empty, represents the name of an Android project
-     *                    that will be selected by default.
-     * @return the project chosen by the user in the dialog, or null if the dialog was canceled.
-     */
-    public IJavaProject chooseJavaProject(String projectName) {
-        ILabelProvider labelProvider = new JavaElementLabelProvider(
-                JavaElementLabelProvider.SHOW_DEFAULT);
-        ElementListSelectionDialog dialog = new ElementListSelectionDialog(
-                mParentShell, labelProvider);
-        dialog.setTitle("Project Selection");
-        dialog.setMessage("Select a project to constrain your search.");
-
-        IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
-        IJavaModel javaModel = JavaCore.create(workspaceRoot);
-
-        // set the elements in the dialog. These are opened android projects.
-        dialog.setElements(getAndroidProjects(javaModel));
-
-        // look for the project matching the given project name
-        IJavaProject javaProject = null;
-        if (projectName != null && projectName.length() > 0) {
-            javaProject = javaModel.getJavaProject(projectName);
-        }
-
-        // if we found it, we set the initial selection in the dialog to this one.
-        if (javaProject != null) {
-            dialog.setInitialSelections(new Object[] { javaProject });
-        }
-
-        // open the dialog and return the object selected if OK was clicked, or null otherwise
-        if (dialog.open() == Window.OK) {
-            return (IJavaProject)dialog.getFirstResult();
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the list of Android projects.
-     * <p/>
-     * Because this list can be time consuming, this class caches the list of project.
-     * It is recommended to call this method instead of
-     * {@link BaseProjectHelper#getAndroidProjects()}.
-     * 
-     * @param javaModel the java model. Can be null.
-     */
-    public IJavaProject[] getAndroidProjects(IJavaModel javaModel) {
-        if (mAndroidProjects == null) {
-            if (javaModel == null) {
-                mAndroidProjects = BaseProjectHelper.getAndroidProjects();
-            } else {
-                mAndroidProjects = BaseProjectHelper.getAndroidProjects(javaModel);
-            }
-        }
-        
-        return mAndroidProjects;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/XmlErrorHandler.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/XmlErrorHandler.java
deleted file mode 100644
index fda55c4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/project/XmlErrorHandler.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-import org.xml.sax.helpers.DefaultHandler;
-
-/**
- * XML error handler used by the parser to report errors/warnings.
- */
-public class XmlErrorHandler extends DefaultHandler {
-
-    /** file being parsed */
-    private IFile mFile;
-
-    /** link to the delta visitor, to set the xml error flag */
-    private XmlErrorListener mErrorListener;
-    
-    /**
-     * Classes which implement this interface provide a method that deals
-     * with XML errors.
-     */
-    public interface XmlErrorListener {
-        /**
-         * Sent when an XML error is detected.
-         */
-        public void errorFound();
-    }
-    
-    public static class BasicXmlErrorListener implements XmlErrorListener {
-        public boolean mHasXmlError = false;
-        
-        public void errorFound() {
-            mHasXmlError = true;
-        }
-    }
-
-    public XmlErrorHandler(IFile file, XmlErrorListener errorListener) {
-        mFile = file;
-        mErrorListener = errorListener;
-    }
-
-    /**
-     * Xml Error call back
-     * @param exception the parsing exception
-     * @throws SAXException 
-     */
-    @Override
-    public void error(SAXParseException exception) throws SAXException {
-        handleError(exception, exception.getLineNumber());
-    }
-
-    /**
-     * Xml Fatal Error call back
-     * @param exception the parsing exception
-     * @throws SAXException 
-     */
-    @Override
-    public void fatalError(SAXParseException exception) throws SAXException {
-        handleError(exception, exception.getLineNumber());
-    }
-
-    /**
-     * Xml Warning call back
-     * @param exception the parsing exception
-     * @throws SAXException 
-     */
-    @Override
-    public void warning(SAXParseException exception) throws SAXException {
-        BaseProjectHelper.addMarker(mFile, AndroidConstants.MARKER_XML, exception.getMessage(),
-                exception.getLineNumber(), IMarker.SEVERITY_WARNING);
-    }
-    
-    protected final IFile getFile() {
-        return mFile;
-    }
-    
-    /**
-     * Handles a parsing error and an optional line number.
-     * @param exception
-     * @param lineNumber
-     */
-    protected void handleError(Exception exception, int lineNumber) {
-        if (mErrorListener != null) {
-            mErrorListener.errorFound();
-        }
-        
-        if (lineNumber != -1) {
-            BaseProjectHelper.addMarker(mFile, AndroidConstants.MARKER_XML, exception.getMessage(),
-                    lineNumber, IMarker.SEVERITY_ERROR);
-        } else {
-            BaseProjectHelper.addMarker(mFile, AndroidConstants.MARKER_XML, exception.getMessage(),
-                    IMarker.SEVERITY_ERROR);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/AttrsXmlParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/AttrsXmlParser.java
deleted file mode 100644
index 3875e81..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/AttrsXmlParser.java
+++ /dev/null
@@ -1,505 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo.Format;
-import com.android.ide.eclipse.common.resources.ViewClassInfo.LayoutParamsInfo;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-
-import org.eclipse.core.runtime.IStatus;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.xml.sax.SAXException;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.TreeSet;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-
-/**
- * Parser for attributes description files.
- */
-public final class AttrsXmlParser {
-
-    private Document mDocument;
-    private String mOsAttrsXmlPath;
-    // all attributes that have the same name are supposed to have the same
-    // parameters so we'll keep a cache of them to avoid processing them twice.
-    private HashMap<String, AttributeInfo> mAttributeMap;
-
-    /** Map of all attribute names for a given element */
-    private HashMap<String, DeclareStyleableInfo> mStyleMap;
-    
-    /** Map of all (constant, value) pairs for attributes of format enum or flag.
-     * E.g. for attribute name=gravity, this tells us there's an enum/flag called "center"
-     * with value 0x11. 
-     */
-    private Map<String, Map<String, Integer>> mEnumFlagValues;
-    
-    
-    /**
-     * Creates a new {@link AttrsXmlParser}, set to load things from the given
-     * XML file. Nothing has been parsed yet. Callers should call {@link #preload()}
-     * next.
-     */
-    public AttrsXmlParser(String osAttrsXmlPath) {
-        this(osAttrsXmlPath, null /* inheritableAttributes */);
-    }
-
-    /**
-     * Creates a new {@link AttrsXmlParser} set to load things from the given
-     * XML file. If inheritableAttributes is non-null, it must point to a preloaded
-     * {@link AttrsXmlParser} which attributes will be used for this one. Since
-     * already defined attributes are not modifiable, they are thus "inherited".
-     */
-    public AttrsXmlParser(String osAttrsXmlPath, AttrsXmlParser inheritableAttributes) {
-        mOsAttrsXmlPath = osAttrsXmlPath;
-
-        // styles are not inheritable.
-        mStyleMap = new HashMap<String, DeclareStyleableInfo>();
-
-        if (inheritableAttributes == null) {
-            mAttributeMap = new HashMap<String, AttributeInfo>();
-            mEnumFlagValues = new HashMap<String, Map<String,Integer>>();
-        } else {
-            mAttributeMap = new HashMap<String, AttributeInfo>(inheritableAttributes.mAttributeMap);
-            mEnumFlagValues = new HashMap<String, Map<String,Integer>>(
-                                                             inheritableAttributes.mEnumFlagValues);
-        }
-    }
-
-    /**
-     * @return The OS path of the attrs.xml file parsed
-     */
-    public String getOsAttrsXmlPath() {
-        return mOsAttrsXmlPath;
-    }
-    
-    /**
-     * Preloads the document, parsing all attributes and declared styles.
-     * 
-     * @return Self, for command chaining.
-     */
-    public AttrsXmlParser preload() {
-        Document doc = getDocument();
-
-        if (doc == null) {
-            AdtPlugin.log(IStatus.WARNING, "Failed to find %1$s", //$NON-NLS-1$
-                    mOsAttrsXmlPath);
-            return this;
-        }
-
-        Node res = doc.getFirstChild();
-        while (res != null &&
-                res.getNodeType() != Node.ELEMENT_NODE &&
-                !res.getNodeName().equals("resources")) { //$NON-NLS-1$
-            res = res.getNextSibling();
-        }
-        
-        if (res == null) {
-            AdtPlugin.log(IStatus.WARNING, "Failed to find a <resources> node in %1$s", //$NON-NLS-1$
-                    mOsAttrsXmlPath);
-            return this;
-        }
-        
-        parseResources(res);
-        return this;
-    }
-
-    /**
-     * Loads all attributes & javadoc for the view class info based on the class name.
-     */
-    public void loadViewAttributes(ViewClassInfo info) {
-        if (getDocument() != null) {
-            String xmlName = info.getShortClassName();
-            DeclareStyleableInfo style = mStyleMap.get(xmlName);
-            if (style != null) {
-                info.setAttributes(style.getAttributes());
-                info.setJavaDoc(style.getJavaDoc());
-            }
-        }
-    }
-
-    /**
-     * Loads all attributes for the layout data info based on the class name.
-     */
-    public void loadLayoutParamsAttributes(LayoutParamsInfo info) {
-        if (getDocument() != null) {
-            // Transforms "LinearLayout" and "LayoutParams" into "LinearLayout_Layout".
-            String xmlName = String.format("%1$s_%2$s", //$NON-NLS-1$
-                    info.getViewLayoutClass().getShortClassName(),
-                    info.getShortClassName());
-            xmlName = xmlName.replaceFirst("Params$", ""); //$NON-NLS-1$ //$NON-NLS-2$
-
-            DeclareStyleableInfo style = mStyleMap.get(xmlName);
-            if (style != null) {
-                info.setAttributes(style.getAttributes());
-            }
-        }
-    }
-    
-    /**
-     * Returns a list of all decleare-styleable found in the xml file.
-     */
-    public Map<String, DeclareStyleableInfo> getDeclareStyleableList() {
-        return Collections.unmodifiableMap(mStyleMap);
-    }
-    
-    /**
-     * Returns a map of all enum and flag constants sorted by parent attribute name.
-     * The map is attribute_name => (constant_name => integer_value).
-     */
-    public Map<String, Map<String, Integer>> getEnumFlagValues() {
-        return mEnumFlagValues;
-    }
-
-    //-------------------------
-
-    /**
-     * Creates an XML document from the attrs.xml OS path.
-     * May return null if the file doesn't exist or cannot be parsed. 
-     */
-    private Document getDocument() {
-        if (mDocument == null) {
-            DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
-            factory.setIgnoringComments(false);
-            try {
-                DocumentBuilder builder = factory.newDocumentBuilder();
-                mDocument = builder.parse(new File(mOsAttrsXmlPath));
-            } catch (ParserConfigurationException e) {
-                AdtPlugin.log(e, "Failed to create XML document builder for %1$s", //$NON-NLS-1$
-                        mOsAttrsXmlPath);
-            } catch (SAXException e) {
-                AdtPlugin.log(e, "Failed to parse XML document %1$s", //$NON-NLS-1$
-                        mOsAttrsXmlPath);
-            } catch (IOException e) {
-                AdtPlugin.log(e, "Failed to read XML document %1$s", //$NON-NLS-1$
-                        mOsAttrsXmlPath);
-            }
-        }
-        return mDocument;
-    }
-
-    /**
-     * Finds all the <declare-styleable> and <attr> nodes in the top <resources> node.
-     */
-    private void parseResources(Node res) {
-        Node lastComment = null;
-        for (Node node = res.getFirstChild(); node != null; node = node.getNextSibling()) {
-            switch (node.getNodeType()) {
-            case Node.COMMENT_NODE:
-                lastComment = node;
-                break;
-            case Node.ELEMENT_NODE:
-                if (node.getNodeName().equals("declare-styleable")) {          //$NON-NLS-1$
-                    Node nameNode = node.getAttributes().getNamedItem("name"); //$NON-NLS-1$
-                    if (nameNode != null) {
-                        String name = nameNode.getNodeValue();
-                        
-                        Node parentNode = node.getAttributes().getNamedItem("parent"); //$NON-NLS-1$
-                        String parents = parentNode == null ? null : parentNode.getNodeValue();
-                        
-                        if (name != null && !mStyleMap.containsKey(name)) {
-                            DeclareStyleableInfo style = parseDeclaredStyleable(name, node);
-                            if (parents != null) {
-                                style.setParents(parents.split("[ ,|]"));  //$NON-NLS-1$
-                            }
-                            mStyleMap.put(name, style);
-                            if (lastComment != null) {
-                                style.setJavaDoc(parseJavadoc(lastComment.getNodeValue()));
-                            }
-                        }
-                    }
-                } else if (node.getNodeName().equals("attr")) {                //$NON-NLS-1$
-                    parseAttr(node, lastComment);
-                }
-                lastComment = null;
-                break;
-            }
-        }
-    }
-
-    /**
-     * Parses an <attr> node and convert it into an {@link AttributeInfo} if it is valid.
-     */
-    private AttributeInfo parseAttr(Node attrNode, Node lastComment) {
-        AttributeInfo info = null;
-        Node nameNode = attrNode.getAttributes().getNamedItem("name"); //$NON-NLS-1$
-        if (nameNode != null) {
-            String name = nameNode.getNodeValue();
-            if (name != null) {
-                info = mAttributeMap.get(name);
-                // If the attribute is unknown yet, parse it.
-                // If the attribute is know but its format is unknown, parse it too.
-                if (info == null || info.getFormats().length == 0) {
-                    info = parseAttributeTypes(attrNode, name);
-                    if (info != null) {
-                        mAttributeMap.put(name, info);
-                    }
-                } else if (lastComment != null) {
-                    info = new AttributeInfo(info);
-                }
-                if (info != null) {
-                    if (lastComment != null) {
-                        info.setJavaDoc(parseJavadoc(lastComment.getNodeValue()));
-                        info.setDeprecatedDoc(parseDeprecatedDoc(lastComment.getNodeValue()));
-                    }
-                }
-            }
-        }
-        return info;
-    }
-
-    /**
-     * Finds all the attributes for a particular style node,
-     * e.g. a declare-styleable of name "TextView" or "LinearLayout_Layout".
-     * 
-     * @param styleName The name of the declare-styleable node
-     * @param declareStyleableNode The declare-styleable node itself 
-     */
-    private DeclareStyleableInfo parseDeclaredStyleable(String styleName,
-            Node declareStyleableNode) {
-        ArrayList<AttributeInfo> attrs = new ArrayList<AttributeInfo>();
-        Node lastComment = null;
-        for (Node node = declareStyleableNode.getFirstChild();
-             node != null;
-             node = node.getNextSibling()) {
-
-            switch (node.getNodeType()) {
-            case Node.COMMENT_NODE:
-                lastComment = node;
-                break;
-            case Node.ELEMENT_NODE:
-                if (node.getNodeName().equals("attr")) {                       //$NON-NLS-1$
-                    AttributeInfo info = parseAttr(node, lastComment);
-                    if (info != null) {
-                        attrs.add(info);
-                    }
-                }
-                lastComment = null;
-                break;
-            }
-            
-        }
-        
-        return new DeclareStyleableInfo(styleName, attrs.toArray(new AttributeInfo[attrs.size()]));
-    }
-
-    /**
-     * Returns the {@link AttributeInfo} for a specific <attr> XML node.
-     * This gets the javadoc, the type, the name and the enum/flag values if any.
-     * <p/>
-     * The XML node is expected to have the following attributes:
-     * <ul>
-     * <li>"name", which is mandatory. The node is skipped if this is missing.</li>
-     * <li>"format".</li>
-     * </ul>
-     * The format may be one type or two types (e.g. "reference|color").
-     * An extra format can be implied: "enum" or "flag" are not specified in the "format" attribute,
-     * they are implicitely stated by the presence of sub-nodes <enum> or <flag>.
-     * <p/>
-     * By design, <attr> nodes of the same name MUST have the same type.
-     * Attribute nodes are thus cached by name and reused as much as possible.
-     * When reusing a node, it is duplicated and its javadoc reassigned. 
-     */
-    private AttributeInfo parseAttributeTypes(Node attrNode, String name) {
-        TreeSet<AttributeInfo.Format> formats = new TreeSet<AttributeInfo.Format>();
-        String[] enumValues = null;
-        String[] flagValues = null;
-
-        Node attrFormat = attrNode.getAttributes().getNamedItem("format"); //$NON-NLS-1$
-        if (attrFormat != null) {
-            for (String f : attrFormat.getNodeValue().split("\\|")) { //$NON-NLS-1$
-                try {
-                    Format format = AttributeInfo.Format.valueOf(f.toUpperCase());
-                    // enum and flags are handled differently right below
-                    if (format != null &&
-                            format != AttributeInfo.Format.ENUM &&
-                            format != AttributeInfo.Format.FLAG) {
-                        formats.add(format);
-                    }
-                } catch (IllegalArgumentException e) {
-                    AdtPlugin.log(e, "Unknown format name '%s' in <attr name=\"%s\">, file '%s'.", //$NON-NLS-1$
-                            f, name, getOsAttrsXmlPath());
-                }
-            }
-        }
-
-        // does this <attr> have <enum> children?
-        enumValues = parseEnumFlagValues(attrNode, "enum", name); //$NON-NLS-1$
-        if (enumValues != null) {
-            formats.add(AttributeInfo.Format.ENUM);
-        }
-
-        // does this <attr> have <flag> children?
-        flagValues = parseEnumFlagValues(attrNode, "flag", name); //$NON-NLS-1$
-        if (flagValues != null) {
-            formats.add(AttributeInfo.Format.FLAG);
-        }
-
-        AttributeInfo info = new AttributeInfo(name,
-                formats.toArray(new AttributeInfo.Format[formats.size()]));
-        info.setEnumValues(enumValues);
-        info.setFlagValues(flagValues);
-        return info;
-    }
-
-    /**
-     * Given an XML node that represents an <attr> node, this method searches
-     * if the node has any children nodes named "target" (e.g. "enum" or "flag").
-     * Such nodes must have a "name" attribute.
-     * <p/>
-     * If "attrNode" is null, look for any <attr> that has the given attrNode
-     * and the requested children nodes.
-     * <p/>
-     * This method collects all the possible names of these children nodes and
-     * return them.
-     * 
-     * @param attrNode The <attr> XML node
-     * @param filter The child node to look for, either "enum" or "flag".
-     * @param attrName The value of the name attribute of <attr> 
-     * 
-     * @return Null if there are no such children nodes, otherwise an array of length >= 1
-     *         of all the names of these children nodes.
-     */
-    private String[] parseEnumFlagValues(Node attrNode, String filter, String attrName) {
-        ArrayList<String> names = null;
-        for (Node child = attrNode.getFirstChild(); child != null; child = child.getNextSibling()) {
-            if (child.getNodeType() == Node.ELEMENT_NODE && child.getNodeName().equals(filter)) {
-                Node nameNode = child.getAttributes().getNamedItem("name");  //$NON-NLS-1$
-                if (nameNode == null) {
-                    AdtPlugin.log(IStatus.WARNING,
-                            "Missing name attribute in <attr name=\"%s\"><%s></attr>", //$NON-NLS-1$
-                            attrName, filter);
-                } else {
-                    if (names == null) {
-                        names = new ArrayList<String>();
-                    }
-                    String name = nameNode.getNodeValue();
-                    names.add(name);
-                    
-                    Node valueNode = child.getAttributes().getNamedItem("value");  //$NON-NLS-1$
-                    if (valueNode == null) {
-                        AdtPlugin.log(IStatus.WARNING,
-                                "Missing value attribute in <attr name=\"%s\"><%s name=\"%s\"></attr>", //$NON-NLS-1$
-                                attrName, filter, name);
-                    } else {
-                        String value = valueNode.getNodeValue();
-                        try {
-                            int i = value.startsWith("0x") ?
-                                    Integer.parseInt(value.substring(2), 16 /* radix */) :
-                                    Integer.parseInt(value);
-                            
-                            Map<String, Integer> map = mEnumFlagValues.get(attrName);
-                            if (map == null) {
-                                map = new HashMap<String, Integer>();
-                                mEnumFlagValues.put(attrName, map);
-                            }
-                            map.put(name, Integer.valueOf(i));
-                            
-                        } catch(NumberFormatException e) {
-                            AdtPlugin.log(e,
-                                    "Value in <attr name=\"%s\"><%s name=\"%s\" value=\"%s\"></attr> is not a valid decimal or hexadecimal", //$NON-NLS-1$
-                                    attrName, filter, name, value);
-                        }
-                    }
-                }
-            }
-        }
-        return names == null ? null : names.toArray(new String[names.size()]);
-    }
-    
-    /**
-     * Parses the javadoc comment.
-     * Only keeps the first sentence.
-     * <p/>
-     * This does not remove nor simplify links and references. Such a transformation
-     * is done later at "display" time in {@link DescriptorsUtils#formatTooltip(String)} and co.
-     */
-    private String parseJavadoc(String comment) {
-        if (comment == null) {
-            return null;
-        }
-        
-        // sanitize & collapse whitespace
-        comment = comment.replaceAll("\\s+", " "); //$NON-NLS-1$ //$NON-NLS-2$
-
-        // Explicitly remove any @deprecated tags since they are handled separately.
-        comment = comment.replaceAll("(?:\\{@deprecated[^}]*\\}|@deprecated[^@}]*)", "");
-
-        // take everything up to the first dot that is followed by a space or the end of the line.
-        // I love regexps :-). For the curious, the regexp is:
-        // - start of line
-        // - ignore whitespace
-        // - group:
-        //   - everything, not greedy
-        //   - non-capturing group (?: )
-        //      - end of string
-        //      or
-        //      - not preceded by a letter, a dot and another letter (for "i.e" and "e.g" )
-        //                            (<! non-capturing zero-width negative look-behind)
-        //      - a dot
-        //      - followed by a space (?= non-capturing zero-width positive look-ahead)
-        // - anything else is ignored
-        comment = comment.replaceFirst("^\\s*(.*?(?:$|(?<![a-zA-Z]\\.[a-zA-Z])\\.(?=\\s))).*", "$1"); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        return comment;
-    }
-
-
-    /**
-     * Parses the javadoc and extract the first @deprecated tag, if any.
-     * Returns null if there's no @deprecated tag.
-     * The deprecated tag can be of two forms:
-     * - {+@deprecated ...text till the next bracket }
-     *   Note: there should be no space or + between { and @. I need one in this comment otherwise
-     *   this method will be tagged as deprecated ;-)
-     * - @deprecated ...text till the next @tag or end of the comment.
-     * In both cases the comment can be multi-line.
-     */
-    private String parseDeprecatedDoc(String comment) {
-        // Skip if we can't even find the tag in the comment.
-        if (comment == null) {
-            return null;
-        }
-        
-        // sanitize & collapse whitespace
-        comment = comment.replaceAll("\\s+", " "); //$NON-NLS-1$ //$NON-NLS-2$
-
-        int pos = comment.indexOf("{@deprecated");
-        if (pos >= 0) {
-            comment = comment.substring(pos + 12 /* len of {@deprecated */);
-            comment = comment.replaceFirst("^([^}]*).*", "$1");
-        } else if ((pos = comment.indexOf("@deprecated")) >= 0) {
-            comment = comment.substring(pos + 11 /* len of @deprecated */);
-            comment = comment.replaceFirst("^(.*?)(?:@.*|$)", "$1");
-        } else {
-            return null;
-        }
-        
-        return comment.trim();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/DeclareStyleableInfo.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/DeclareStyleableInfo.java
deleted file mode 100644
index efa5981..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/DeclareStyleableInfo.java
+++ /dev/null
@@ -1,174 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-
-/**
- * Information needed to represent a View or ViewGroup (aka Layout) item
- * in the layout hierarchy, as extracted from the main android.jar and the
- * associated attrs.xml.
- */
-public class DeclareStyleableInfo {
-    /** The style name, never null. */
-    private String mStyleName;
-    /** Attributes for this view or view group. Can be empty but never null. */
-    private AttributeInfo[] mAttributes;
-    /** Short javadoc. Can be null. */
-    private String mJavaDoc;
-    /** Optional name of the parents stylable. Can be null. */
-    private String[] mParents;    
-
-    public static class AttributeInfo {
-        /** XML Name of the attribute */
-        private String mName;
-        
-        public enum Format {
-            STRING,
-            BOOLEAN,
-            INTEGER,
-            FLOAT,
-            REFERENCE,
-            COLOR,
-            DIMENSION,
-            FRACTION,
-            ENUM,
-            FLAG,
-        }
-        
-        /** Formats of the attribute. Cannot be null. Should have at least one format. */
-        private Format[] mFormats;
-        /** Values for enum. null for other types. */
-        private String[] mEnumValues;
-        /** Values for flag. null for other types. */
-        private String[] mFlagValues;
-        /** Short javadoc (i.e. the first sentence). */
-        private String mJavaDoc;
-        /** Documentation for deprecated attributes. Null if not deprecated. */
-        private String mDeprecatedDoc;
-
-        /**
-         * @param name The XML Name of the attribute
-         * @param formats The formats of the attribute. Cannot be null.
-         *                Should have at least one format.
-         */
-        public AttributeInfo(String name, Format[] formats) {
-            mName = name;
-            mFormats = formats;
-        }
-
-        public AttributeInfo(AttributeInfo info) {
-            mName = info.mName;
-            mFormats = info.mFormats;
-            mEnumValues = info.mEnumValues;
-            mFlagValues = info.mFlagValues;
-            mJavaDoc = info.mJavaDoc;
-            mDeprecatedDoc = info.mDeprecatedDoc;
-        }
-        
-        /** Returns the XML Name of the attribute */
-        public String getName() {
-            return mName;
-        }
-        /** Returns the formats of the attribute. Cannot be null.
-         *  Should have at least one format. */
-        public Format[] getFormats() {
-            return mFormats;
-        }
-        /** Returns the values for enums. null for other types. */
-        public String[] getEnumValues() {
-            return mEnumValues;
-        }
-        /** Returns the values for flags. null for other types. */
-        public String[] getFlagValues() {
-            return mFlagValues;
-        }
-        /** Returns a short javadoc, .i.e. the first sentence. */
-        public String getJavaDoc() {
-            return mJavaDoc;
-        }
-        /** Returns the documentation for deprecated attributes. Null if not deprecated. */
-        public String getDeprecatedDoc() {
-            return mDeprecatedDoc;
-        }
-
-        /** Sets the values for enums. null for other types. */
-        public void setEnumValues(String[] values) {
-            mEnumValues = values;
-        }
-        /** Sets the values for flags. null for other types. */
-        public void setFlagValues(String[] values) {
-            mFlagValues = values;
-        }
-        /** Sets a short javadoc, .i.e. the first sentence. */
-        public void setJavaDoc(String javaDoc) {
-            mJavaDoc = javaDoc;
-        }
-        /** Sets the documentation for deprecated attributes. Null if not deprecated. */
-        public void setDeprecatedDoc(String deprecatedDoc) {
-            mDeprecatedDoc = deprecatedDoc;
-        }
-
-    }
-    
-    // --------
-    
-    /**
-     * Creates a new {@link DeclareStyleableInfo}.
-     * 
-     * @param styleName The name of the style. Should not be empty nor null.
-     * @param attributes The initial list of attributes. Can be null.
-     */
-    public DeclareStyleableInfo(String styleName, AttributeInfo[] attributes) {
-        mStyleName = styleName;
-        mAttributes = attributes == null ? new AttributeInfo[0] : attributes;
-    }
-    
-    /** Returns style name */
-    public String getStyleName() {
-        return mStyleName;
-    }
-
-    /** Returns the attributes for this view or view group. Maybe empty but not null. */
-    public AttributeInfo[] getAttributes() {
-        return mAttributes;
-    }
-
-    /** Sets the list of attributes for this View or ViewGroup. */
-    public void setAttributes(AttributeInfo[] attributes) {
-        mAttributes = attributes;
-    }
-    
-    /** Returns a short javadoc */
-    public String getJavaDoc() {
-        return mJavaDoc;
-    }
-
-    /** Sets the javadoc. */
-    public void setJavaDoc(String javaDoc) {
-        mJavaDoc = javaDoc;
-    }
-
-    /** Sets the name of the parents styleable. Can be null. */
-    public void setParents(String[] parents) {
-        mParents = parents;
-    }
-
-    /** Returns the name of the parents styleable. Can be null. */
-    public String[] getParents() {
-        return mParents;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IIdResourceItem.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IIdResourceItem.java
deleted file mode 100644
index 38b7e03..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IIdResourceItem.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-/**
- * Classes which implements this interface provides a method indicating the state of a resource of
- * type {@link ResourceType#ID}.
- */
-public interface IIdResourceItem {
-    /**
-     * Returns whether the ID resource has been declared inline inside another resource XML file. 
-     */
-    public boolean isDeclaredInline();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IPathChangedListener.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IPathChangedListener.java
deleted file mode 100644
index 53d9077..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IPathChangedListener.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-/**
- * Classes which implement this interface provide a method that deals with
- * a path change.
- */
-public interface IPathChangedListener {
-    /**
-     * Sent when the location of the android sdk directory changed.
-     * @param osPath The new android sdk directory location.
-     */
-    public void pathChanged(String osPath);
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IResourceRepository.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IResourceRepository.java
deleted file mode 100644
index 3819997..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/IResourceRepository.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-/**
- * A repository of resources. This allows access to the resource by {@link ResourceType}.
- */
-public interface IResourceRepository {
-
-    /**
-     * Returns the present {@link ResourceType}s in the project.
-     * @return an array containing all the type of resources existing in the project.
-     */
-    public abstract ResourceType[] getAvailableResourceTypes();
-
-    /**
-     * Returns an array of the existing resource for the specified type.
-     * @param type the type of the resources to return
-     */
-    public abstract ResourceItem[] getResources(ResourceType type);
-
-    /**
-     * Returns whether resources of the specified type are present.
-     * @param type the type of the resources to check.
-     */
-    public abstract boolean hasResources(ResourceType type);
-    
-    /**
-     * Returns whether the repository is a system repository.
-     */
-    public abstract boolean isSystemRepository();
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceItem.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceItem.java
deleted file mode 100644
index 83527f3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceItem.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-/**
- * Base class representing a Resource Item, as returned by a {@link IResourceRepository}.
- */
-public class ResourceItem implements Comparable<ResourceItem> {
-    
-    private final String mName;
-    
-    /**
-     * Constructs a new ResourceItem
-     * @param name the name of the resource as it appears in the XML and R.java files.
-     */
-    public ResourceItem(String name) {
-        mName = name;
-    }
-
-    /**
-     * Returns the name of the resource item.
-     */
-    public final String getName() {
-        return mName;
-    }
-
-    /**
-     * Compares the {@link ResourceItem} to another.
-     * @param other the ResourceItem to be compared to.
-     */
-    public int compareTo(ResourceItem other) {
-        return mName.compareTo(other.mName);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceType.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceType.java
deleted file mode 100644
index 60c471e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ResourceType.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-/**
- * Enum representing a type of compiled resource.
- */
-public enum ResourceType {
-    ANIM("anim", "Animation"), //$NON-NLS-1$
-    ARRAY("array", "Array", "string-array", "integer-array"), //$NON-NLS-1$ //$NON-NLS-3$ //$NON-NLS-4$
-    ATTR("attr", "Attr"), //$NON-NLS-1$
-    COLOR("color", "Color"), //$NON-NLS-1$
-    DIMEN("dimen", "Dimension"), //$NON-NLS-1$
-    DRAWABLE("drawable", "Drawable"), //$NON-NLS-1$
-    ID("id", "ID"), //$NON-NLS-1$
-    LAYOUT("layout", "Layout"), //$NON-NLS-1$
-    MENU("menu", "Menu"), //$NON-NLS-1$
-    RAW("raw", "Raw"), //$NON-NLS-1$
-    STRING("string", "String"), //$NON-NLS-1$
-    STYLE("style", "Style"), //$NON-NLS-1$
-    STYLEABLE("styleable", "Styleable"), //$NON-NLS-1$
-    XML("xml", "XML"); //$NON-NLS-1$
-
-    private final String mName;
-    private final String mDisplayName;
-    private final String[] mAlternateXmlNames;
-
-    ResourceType(String name, String displayName, String... alternateXmlNames) {
-        mName = name;
-        mDisplayName = displayName;
-        mAlternateXmlNames = alternateXmlNames;
-    }
-    
-    /**
-     * Returns the resource type name, as used by XML files.
-     */
-    public String getName() {
-        return mName;
-    }
-
-    /**
-     * Returns a translated display name for the resource type.
-     */
-    public String getDisplayName() {
-        return mDisplayName;
-    }
-    
-    /**
-     * Returns the enum by its name as it appears in the XML or the R class.
-     * @param name name of the resource
-     * @return the matching {@link ResourceType} or <code>null</code> if no match was found.
-     */
-    public static ResourceType getEnum(String name) {
-        for (ResourceType rType : values()) {
-            if (rType.mName.equals(name)) {
-                return rType;
-            } else if (rType.mAlternateXmlNames != null) {
-                // if there are alternate Xml Names, we test those too
-                for (String alternate : rType.mAlternateXmlNames) {
-                    if (alternate.equals(name)) {
-                        return rType;
-                    }
-                }
-            }
-        }
-        return null;
-    }
-    
-    /**
-     * Returns a formatted string usable in an XML to use the specified {@link ResourceItem}.
-     * @param resourceItem The resource item.
-     * @param system Whether this is a system resource or a project resource.
-     * @return a string in the format @[type]/[name] 
-     */
-    public String getXmlString(ResourceItem resourceItem, boolean system) {
-        if (this == ID && resourceItem instanceof IIdResourceItem) {
-            IIdResourceItem idResource = (IIdResourceItem)resourceItem;
-            if (idResource.isDeclaredInline()) {
-                return (system?"@android:":"@+") + mName + "/" + resourceItem.getName(); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-            }
-        }
-
-        return (system?"@android:":"@") + mName + "/" + resourceItem.getName(); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-    }
-    
-    /**
-     * Returns an array with all the names defined by this enum.
-     */
-    public static String[] getNames() {
-        ResourceType[] values = values();
-        String[] names = new String[values.length];
-        for (int i = values.length - 1; i >= 0; --i) {
-            names[i] = values[i].getName();
-        }
-        return names;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ViewClassInfo.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ViewClassInfo.java
deleted file mode 100644
index 619e3cc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/common/resources/ViewClassInfo.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-
-/**
- * Information needed to represent a View or ViewGroup (aka Layout) item
- * in the layout hierarchy, as extracted from the main android.jar and the
- * associated attrs.xml.
- */
-public class ViewClassInfo {
-    /** Is this a layout class (i.e. ViewGroup) or just a view? */
-    private boolean mIsLayout;
-    /** FQCN e.g. android.view.View, never null. */
-    private String mCanonicalClassName;
-    /** Short class name, e.g. View, never null. */
-    private String mShortClassName;
-    /** Super class. Can be null. */
-    private ViewClassInfo mSuperClass;
-    /** Short javadoc. Can be null. */
-    private String mJavaDoc;    
-    /** Attributes for this view or view group. Can be empty but never null. */
-    private AttributeInfo[] mAttributes;
-    
-    public static class LayoutParamsInfo {
-        /** Short class name, e.g. LayoutData, never null. */
-        private String mShortClassName;
-        /** ViewLayout class info owning this layout data */
-        private ViewClassInfo mViewLayoutClass;
-        /** Super class. Can be null. */
-        private LayoutParamsInfo mSuperClass; 
-        /** Layout Data Attributes for layout classes. Can be empty but not null. */
-        private AttributeInfo[] mAttributes;
-
-        public LayoutParamsInfo(ViewClassInfo enclosingViewClassInfo,
-                String shortClassName, LayoutParamsInfo superClassInfo) {
-            mShortClassName = shortClassName;
-            mViewLayoutClass = enclosingViewClassInfo;
-            mSuperClass = superClassInfo;
-            mAttributes = new AttributeInfo[0];
-        }
-        
-        /** Returns short class name, e.g. "LayoutData" */
-        public String getShortClassName() {
-            return mShortClassName;
-        }
-        /** Returns the ViewLayout class info enclosing this layout data. Cannot null. */
-        public ViewClassInfo getViewLayoutClass() {
-            return mViewLayoutClass;
-        }
-        /** Returns the super class info. Can be null. */
-        public LayoutParamsInfo getSuperClass() {
-            return mSuperClass;
-        }
-        /** Returns the LayoutData attributes. Can be empty but not null. */
-        public AttributeInfo[] getAttributes() {
-            return mAttributes;
-        }
-        /** Sets the LayoutData attributes. Can be empty but not null. */
-        public void setAttributes(AttributeInfo[] attributes) {
-            mAttributes = attributes;
-        }
-    }
-
-    /** Layout data info for a layout class. Null for all non-layout classes and always
-     *  non-null for a layout class. */
-    public LayoutParamsInfo mLayoutData;
-
-    // --------
-    
-    public ViewClassInfo(boolean isLayout, String canonicalClassName, String shortClassName) {
-        mIsLayout = isLayout;
-        mCanonicalClassName = canonicalClassName;
-        mShortClassName = shortClassName;
-        mAttributes = new AttributeInfo[0];
-    }
-    
-    /** Returns whether this is a layout class (i.e. ViewGroup) or just a View */
-    public boolean isLayout() {
-        return mIsLayout;
-    }
-
-    /** Returns FQCN e.g. "android.view.View" */
-    public String getCanonicalClassName() {
-        return mCanonicalClassName;
-    }
-
-    /** Returns short class name, e.g. "View" */
-    public String getShortClassName() {
-        return mShortClassName;
-    }
-
-    /** Returns the super class. Can be null. */
-    public ViewClassInfo getSuperClass() {
-        return mSuperClass;
-    }
-
-    /** Returns a short javadoc */
-    public String getJavaDoc() {
-        return mJavaDoc;
-    }
-
-    /** Returns the attributes for this view or view group. Maybe empty but not null. */
-    public AttributeInfo[] getAttributes() {
-        return mAttributes;
-    }
-
-    /** Returns the LayoutData info for layout classes. Null for non-layout view classes. */
-    public LayoutParamsInfo getLayoutData() {
-        return mLayoutData;
-    }
-
-    /**
-     * Sets a link on the info of the super class of this View or ViewGroup.
-     * <p/>
-     * The super class info must be of the same kind (i.e. group to group or view to view)
-     * except for the top ViewGroup which links to the View info.
-     * <p/>
-     * The super class cannot be null except for the top View info.
-     */
-    public void setSuperClass(ViewClassInfo superClass) {
-        mSuperClass = superClass;
-    }
-
-    /** Sets the javadoc for this View or ViewGroup. */
-    public void setJavaDoc(String javaDoc) {
-        mJavaDoc = javaDoc;
-    }
-
-    /** Sets the list of attributes for this View or ViewGroup. */
-    public void setAttributes(AttributeInfo[] attributes) {
-        mAttributes = attributes;
-    }
-
-    /**
-     * Sets the {@link LayoutParamsInfo} for layout classes.
-     * Does nothing for non-layout view classes.
-     */
-    public void setLayoutParams(LayoutParamsInfo layoutData) {
-        if (mIsLayout) {
-            mLayoutData = layoutData;
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidContentAssist.java
deleted file mode 100644
index a325ccb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidContentAssist.java
+++ /dev/null
@@ -1,771 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextValueDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiFlagAttributeNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.TextSelection;
-import org.eclipse.jface.text.contentassist.CompletionProposal;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.regex.Pattern;
-
-/**
- * Content Assist Processor for Android XML files
- */
-public abstract class AndroidContentAssist implements IContentAssistProcessor {
-
-    /** Regexp to detect a full attribute after an element tag.
-     * <pre>Syntax:
-     *    name = "..." quoted string with all but < and "
-     * or:
-     *    name = '...' quoted string with all but < and '
-     * </pre>
-     */
-    private static Pattern sFirstAttribute = Pattern.compile(
-            "^ *[a-zA-Z_:]+ *= *(?:\"[^<\"]*\"|'[^<']*')");  //$NON-NLS-1$
-
-    /** Regexp to detect an element tag name */
-    private static Pattern sFirstElementWord = Pattern.compile("^[a-zA-Z0-9_:]+"); //$NON-NLS-1$
-    
-    /** Regexp to detect whitespace */
-    private static Pattern sWhitespace = Pattern.compile("\\s+"); //$NON-NLS-1$
-
-    protected final static String ROOT_ELEMENT = "";
-
-    /** Descriptor of the root of the XML hierarchy. This a "fake" ElementDescriptor which
-     *  is used to list all the possible roots given by actual implementations.
-     *  DO NOT USE DIRECTLY. Call {@link #getRootDescriptor()} instead. */
-    private ElementDescriptor mRootDescriptor;
-
-    private final int mDescriptorId;
-    
-    private AndroidEditor mEditor;
-
-    /**
-     * Constructor for AndroidContentAssist 
-     * @param descriptorId An id for {@link AndroidTargetData#getDescriptorProvider(int)}.
-     *      The Id can be one of {@link AndroidTargetData#DESCRIPTOR_MANIFEST},
-     *      {@link AndroidTargetData#DESCRIPTOR_LAYOUT},
-     *      {@link AndroidTargetData#DESCRIPTOR_MENU},
-     *      or {@link AndroidTargetData#DESCRIPTOR_XML}.
-     *      All other values will throw an {@link IllegalArgumentException} later at runtime.
-     */
-    public AndroidContentAssist(int descriptorId) {
-        mDescriptorId = descriptorId;
-    }
-
-    /**
-     * Returns a list of completion proposals based on the
-     * specified location within the document that corresponds
-     * to the current cursor position within the text viewer.
-     *
-     * @param viewer the viewer whose document is used to compute the proposals
-     * @param offset an offset within the document for which completions should be computed
-     * @return an array of completion proposals or <code>null</code> if no proposals are possible
-     * 
-     * @see org.eclipse.jface.text.contentassist.IContentAssistProcessor#computeCompletionProposals(org.eclipse.jface.text.ITextViewer, int)
-     */
-    public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
-      
-        if (mEditor == null) {
-            mEditor = getAndroidEditor(viewer);
-        }
-
-        UiElementNode rootUiNode = mEditor.getUiRootNode();
-        
-        Object[] choices = null; /* An array of ElementDescriptor, or AttributeDescriptor
-                                    or String or null */
-        String parent = "";      //$NON-NLS-1$
-        String wordPrefix = extractElementPrefix(viewer, offset);
-        char needTag = 0;
-        boolean isElement = false;
-        boolean isAttribute = false;
-
-        Node currentNode = getNode(viewer, offset);
-        if (currentNode == null)
-            return null;
-
-        // check to see if we can find a UiElementNode matching this XML node
-        UiElementNode currentUiNode =
-            rootUiNode == null ? null : rootUiNode.findXmlNode(currentNode);
-        
-        if (currentNode.getNodeType() == Node.ELEMENT_NODE) {
-            parent = currentNode.getNodeName();
-
-            if (wordPrefix.equals(parent)) {
-                // We are still editing the element's tag name, not the attributes
-                // (the element's tag name may not even be complete)
-                isElement = true;
-                choices = getChoicesForElement(parent, currentNode);
-            } else {
-                // We're not editing the current node name, so we might be editing its
-                // attributes instead...
-                isAttribute = true;
-                AttribInfo info = parseAttributeInfo(viewer, offset);
-                if (info != null) {
-                    // We're editing attributes in an element node (either the attributes' names
-                    // or their values).
-                    choices = getChoicesForAttribute(parent, currentNode, currentUiNode, info);
-                    
-                    if (info.correctedPrefix != null) {
-                        wordPrefix = info.correctedPrefix;
-                    }
-                    needTag = info.needTag;
-                }
-            }
-        } else if (currentNode.getNodeType() == Node.TEXT_NODE) {
-            isElement = true;
-            // Examine the parent of the text node.
-            choices = getChoicesForTextNode(currentNode);
-        }
-
-        // Abort if we can't recognize the context or there are no completion choices
-        if (choices == null || choices.length == 0) return null;
-
-        if (isElement) {
-            // If we found some suggestions, do we need to add an opening "<" bracket
-            // for the element? We don't if the cursor is right after "<" or "</".
-            // Per XML Spec, there's no whitespace between "<" or "</" and the tag name.
-            int offset2 = offset - wordPrefix.length() - 1;
-            int c1 = extractChar(viewer, offset2);
-            if (!((c1 == '<') || (c1 == '/' && extractChar(viewer, offset2 - 1) == '<'))) {
-                needTag = '<';
-            }
-        }
-        
-        // get the selection length
-        int selectionLength = 0;
-        ISelection selection = viewer.getSelectionProvider().getSelection();
-        if (selection instanceof TextSelection) {
-            TextSelection textSelection = (TextSelection)selection;
-            selectionLength = textSelection.getLength();
-        }
-
-        return computeProposals(offset, currentNode, choices, wordPrefix, needTag,
-                isAttribute, selectionLength);
-    }
-
-    /**
-     * Returns the namespace prefix matching the Android Resource URI.
-     * If no such declaration is found, returns the default "android" prefix.
-     *  
-     * @param node The current node. Must not be null.
-     * @param nsUri The namespace URI of which the prefix is to be found,
-     *              e.g. {@link SdkConstants#NS_RESOURCES}
-     * @return The first prefix declared or the default "android" prefix.
-     */
-    private String lookupNamespacePrefix(Node node, String nsUri) {
-        // Note: Node.lookupPrefix is not implemented in wst/xml/core NodeImpl.java
-        // The following emulates this:
-        //   String prefix = node.lookupPrefix(SdkConstants.NS_RESOURCES);
-
-        if (XmlnsAttributeDescriptor.XMLNS_URI.equals(nsUri)) {
-            return "xmlns"; //$NON-NLS-1$
-        }
-        
-        HashSet<String> visited = new HashSet<String>();
-        
-        String prefix = null;
-        for (; prefix == null &&
-                    node != null &&
-                    node.getNodeType() == Node.ELEMENT_NODE;
-               node = node.getParentNode()) {
-            NamedNodeMap attrs = node.getAttributes();
-            for (int n = attrs.getLength() - 1; n >= 0; --n) {
-                Node attr = attrs.item(n);
-                if ("xmlns".equals(attr.getPrefix())) {  //$NON-NLS-1$
-                    String uri = attr.getNodeValue();
-                    if (SdkConstants.NS_RESOURCES.equals(uri)) {
-                        return attr.getLocalName();
-                    }
-                    visited.add(uri);
-                }
-            }
-        }
-        
-        // Use a sensible default prefix if we can't find one.
-        // We need to make sure the prefix is not one that was declared in the scope
-        // visited above.
-        prefix = SdkConstants.NS_RESOURCES.equals(nsUri) ? "android" : "ns"; //$NON-NLS-1$ //$NON-NLS-2$
-        String base = prefix;
-        for (int i = 1; visited.contains(prefix); i++) {
-            prefix = base + Integer.toString(i);
-        }
-        return prefix;
-    }
-
-    /**
-     * Gets the choices when the user is editing the name of an XML element.
-     * <p/>
-     * The user is editing the name of an element (the "parent").
-     * Find the grand-parent and if one is found, return its children element list.
-     * The name which is being edited should be one of those.
-     * <p/>
-     * Example: <manifest><applic*cursor* => returns the list of all elements that
-     * can be found under <manifest>, of which <application> is one of the choices.
-     * 
-     * @return an ElementDescriptor[] or null if no valid element was found.
-     */
-    private Object[] getChoicesForElement(String parent, Node current_node) {
-        ElementDescriptor grandparent = null;
-        if (current_node.getParentNode().getNodeType() == Node.ELEMENT_NODE) {
-            grandparent = getDescriptor(current_node.getParentNode().getNodeName());
-        } else if (current_node.getParentNode().getNodeType() == Node.DOCUMENT_NODE) {
-            grandparent = getRootDescriptor();
-        }
-        if (grandparent != null) {
-            for (ElementDescriptor e : grandparent.getChildren()) {
-                if (e.getXmlName().startsWith(parent)) {
-                    return grandparent.getChildren();
-                }
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Gets the choices when the user is editing an XML attribute.
-     * <p/>
-     * In input, attrInfo contains details on the analyzed context, namely whether the
-     * user is editing an attribute value (isInValue) or an attribute name.
-     * <p/>
-     * In output, attrInfo also contains two possible new values (this is a hack to circumvent
-     * the lack of out-parameters in Java):
-     * - AttribInfo.correctedPrefix if the user has been editing an attribute value and it has
-     *   been detected that what the user typed is different from what extractElementPrefix()
-     *   predicted. This happens because extractElementPrefix() stops when a character that
-     *   cannot be an element name appears whereas parseAttributeInfo() uses a grammar more
-     *   lenient as suitable for attribute values.
-     * - AttribInfo.needTag will be non-zero if we find that the attribute completion proposal
-     *   must be double-quoted.
-     * @param currentUiNode 
-     * 
-     * @return an AttributeDescriptor[] if the user is editing an attribute name.
-     *         a String[] if the user is editing an attribute value with some known values,
-     *         or null if nothing is known about the context.
-     */
-    private Object[] getChoicesForAttribute(String parent,
-            Node currentNode, UiElementNode currentUiNode, AttribInfo attrInfo) {
-        Object[] choices = null;
-        if (attrInfo.isInValue) {
-            // Editing an attribute's value... Get the attribute name and then the
-            // possible choice for the tuple(parent,attribute)
-            String value = attrInfo.value;
-            if (value.startsWith("'") || value.startsWith("\"")) {   //$NON-NLS-1$   //$NON-NLS-2$
-                value = value.substring(1);
-                // The prefix that was found at the beginning only scan for characters
-                // valid of tag name. We now know the real prefix for this attribute's
-                // value, which is needed to generate the completion choices below.
-                attrInfo.correctedPrefix = value;
-            } else {
-                attrInfo.needTag = '"';
-            }
-            
-            if (currentUiNode != null) {
-                // look for an UI attribute matching the current attribute name
-                String attrName = attrInfo.name;
-
-                UiAttributeNode currAttrNode = null;
-                for (UiAttributeNode attrNode : currentUiNode.getUiAttributes()) {
-                    if (attrNode.getDescriptor().getXmlLocalName().equals(attrName)) {
-                        currAttrNode = attrNode;
-                        break;
-                    }
-                }
-
-                if (currAttrNode != null) {
-                    choices = currAttrNode.getPossibleValues();
-                    
-                    if (currAttrNode instanceof UiFlagAttributeNode) {
-                        // A "flag" can consist of several values separated by "or" (|).
-                        // If the correct prefix contains such a pipe character, we change
-                        // it so that only the currently edited value is completed.
-                        int pos = value.indexOf('|');
-                        if (pos >= 0) {
-                            attrInfo.correctedPrefix = value = value.substring(pos + 1);
-                            attrInfo.needTag = 0;
-                        }
-                    }
-                }
-            }
-
-            if (choices == null) {
-                // fallback on the older descriptor-only based lookup.
-                
-                // in order to properly handle the special case of the name attribute in
-                // the action tag, we need the grandparent of the action node, to know
-                // what type of actions we need.
-                // e.g. activity -> intent-filter -> action[@name]
-                String greatGrandParentName = null;
-                Node grandParent = currentNode.getParentNode();
-                if (grandParent != null) {
-                    Node greatGrandParent = grandParent.getParentNode();
-                    if (greatGrandParent != null) {
-                        greatGrandParentName = greatGrandParent.getLocalName();
-                    }
-                }
-                
-                AndroidTargetData data = mEditor.getTargetData();
-                if (data != null) {
-                    choices = data.getAttributeValues(parent, attrInfo.name, greatGrandParentName);
-                }
-            }
-        } else {
-            // Editing an attribute's name... Get attributes valid for the parent node.
-            if (currentUiNode != null) {
-                choices = currentUiNode.getAttributeDescriptors();
-            } else {
-                ElementDescriptor parent_desc = getDescriptor(parent);
-                choices = parent_desc.getAttributes();
-            }
-        }
-        return choices;
-    }
-
-    /**
-     * Gets the choices when the user is editing an XML text node.
-     * <p/>
-     * This means the user is editing outside of any XML element or attribute.
-     * Simply return the list of XML elements that can be present there, based on the
-     * parent of the current node.
-     * 
-     * @return An ElementDescriptor[] or null.
-     */
-    private Object[] getChoicesForTextNode(Node currentNode) {
-        Object[] choices = null;
-        String parent;
-        Node parent_node = currentNode.getParentNode();
-        if (parent_node.getNodeType() == Node.ELEMENT_NODE) {
-            // We're editing a text node which parent is an element node. Limit
-            // content assist to elements valid for the parent.
-            parent = parent_node.getNodeName();
-            ElementDescriptor desc = getDescriptor(parent);
-            if (desc != null) {
-                choices = desc.getChildren();
-            }
-        } else if (parent_node.getNodeType() == Node.DOCUMENT_NODE) {
-            // We're editing a text node at the first level (i.e. root node).
-            // Limit content assist to the only valid root elements.
-            choices = getRootDescriptor().getChildren();
-        }
-        return choices;
-    }
-
-    /**
-     * Given a list of choices found, generates the proposals to be displayed to the user.
-     * <p/>
-     * Choices is an object array. Items of the array can be:
-     * - ElementDescriptor: a possible element descriptor which XML name should be completed.
-     * - AttributeDescriptor: a possible attribute descriptor which XML name should be completed.
-     * - String: string values to display as-is to the user. Typically those are possible
-     *           values for a given attribute.
-     * 
-     * @return The ICompletionProposal[] to display to the user.
-     */
-    private ICompletionProposal[] computeProposals(int offset, Node currentNode,
-            Object[] choices, String wordPrefix, char need_tag,
-            boolean is_attribute, int selectionLength) {
-        ArrayList<CompletionProposal> proposals = new ArrayList<CompletionProposal>();
-        HashMap<String, String> nsUriMap = new HashMap<String, String>();
-        
-        for (Object choice : choices) {
-            String keyword = null;
-            String nsPrefix = null;
-            Image icon = null;
-            String tooltip = null;
-            if (choice instanceof ElementDescriptor) {
-                keyword = ((ElementDescriptor)choice).getXmlName();
-                icon    = ((ElementDescriptor)choice).getIcon();
-                tooltip = DescriptorsUtils.formatTooltip(((ElementDescriptor)choice).getTooltip());
-            } else if (choice instanceof TextValueDescriptor) {
-                continue; // Value nodes are not part of the completion choices
-            } else if (choice instanceof SeparatorAttributeDescriptor) {
-                continue; // not real attribute descriptors
-            } else if (choice instanceof AttributeDescriptor) {
-                keyword = ((AttributeDescriptor)choice).getXmlLocalName();
-                icon    = ((AttributeDescriptor)choice).getIcon();
-                if (choice instanceof TextAttributeDescriptor) {
-                    tooltip = ((TextAttributeDescriptor) choice).getTooltip();
-                }
-                
-                String nsUri = ((AttributeDescriptor)choice).getNamespaceUri();
-                nsPrefix = nsUriMap.get(nsUri);
-                if (nsPrefix == null) {
-                    nsPrefix = lookupNamespacePrefix(currentNode, nsUri);
-                    nsUriMap.put(nsUri, nsPrefix);
-                }
-                if (nsPrefix != null) {
-                    nsPrefix += ":"; //$NON-NLS-1$
-                }
-                
-            } else if (choice instanceof String) {
-                keyword = (String) choice;
-            } else {
-                continue; // discard unknown choice
-            }
-
-            if (keyword.startsWith(wordPrefix) ||
-                    (nsPrefix != null && keyword.startsWith(nsPrefix))) {
-                if (nsPrefix != null) {
-                    keyword = nsPrefix + keyword;
-                }
-                String end_tag = ""; //$NON-NLS-1$
-                if (need_tag != 0) {
-                    if (need_tag == '"') {
-                        keyword = need_tag + keyword;
-                        end_tag = String.valueOf(need_tag);
-                    } else if (need_tag == '<') {
-                        if (elementCanHaveChildren(choice)) {
-                            end_tag = String.format("></%1$s>", keyword);  //$NON-NLS-1$
-                            keyword = need_tag + keyword;
-                        } else {
-                            keyword = need_tag + keyword;
-                            end_tag = "/>";  //$NON-NLS-1$
-                        }
-                    }
-                }
-                CompletionProposal proposal = new CompletionProposal(
-                        keyword + end_tag,                  // String replacementString
-                        offset - wordPrefix.length(),           // int replacementOffset
-                        wordPrefix.length() + selectionLength,  // int replacementLength
-                        keyword.length(),                   // int cursorPosition (rel. to rplcmntOffset)
-                        icon,                               // Image image
-                        null,                               // String displayString
-                        null,                               // IContextInformation contextInformation
-                        tooltip                             // String additionalProposalInfo
-                        );
-
-                proposals.add(proposal);
-            }
-        }
-        
-        return proposals.toArray(new ICompletionProposal[proposals.size()]);
-    }
-
-    /**
-     * Indicates whether this descriptor describes an element that can potentially
-     * have children (either sub-elements or text value). If an element can have children,
-     * we want to explicitly write an opening and a separate closing tag.
-     * <p/>
-     * Elements can have children if the descriptor has children element descriptors
-     * or if one of the attributes is a TextValueDescriptor.
-     * 
-     * @param descriptor An ElementDescriptor or an AttributeDescriptor
-     * @return True if the descriptor is an ElementDescriptor that can have children or a text value
-     */
-    private boolean elementCanHaveChildren(Object descriptor) {
-        if (descriptor instanceof ElementDescriptor) {
-            ElementDescriptor desc = (ElementDescriptor) descriptor;
-            if (desc.hasChildren()) {
-                return true;
-            }
-            for (AttributeDescriptor attr_desc : desc.getAttributes()) {
-                if (attr_desc instanceof TextValueDescriptor) {
-                    return true;
-                }
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Returns the element descriptor matching a given XML node name or null if it can't be
-     * found.
-     * <p/>
-     * This is simplistic; ideally we should consider the parent's chain to make sure we
-     * can differentiate between different hierarchy trees. Right now the first match found
-     * is returned.
-     */
-    private ElementDescriptor getDescriptor(String nodeName) {
-        return getRootDescriptor().findChildrenDescriptor(nodeName, true /* recursive */);
-    }
-
-    public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
-        return null;
-    }
-
-    /**
-     * Returns the characters which when entered by the user should
-     * automatically trigger the presentation of possible completions.
-     * 
-     * In our case, we auto-activate on opening tags and attributes namespace.
-     *
-     * @return the auto activation characters for completion proposal or <code>null</code>
-     *      if no auto activation is desired
-     */
-    public char[] getCompletionProposalAutoActivationCharacters() {
-        return new char[]{ '<', ':', '=' };
-    }
-
-    public char[] getContextInformationAutoActivationCharacters() {
-        return null;
-    }
-
-    public IContextInformationValidator getContextInformationValidator() {
-        return null;
-    }
-
-    public String getErrorMessage() {
-        return null;
-    }
-    
-    /**
-     * Heuristically extracts the prefix used for determining template relevance
-     * from the viewer's document. The default implementation returns the String from
-     * offset backwards that forms a potential XML element name.
-     *
-     * Code extracted from org.eclipse.jface.text.templatesTemplateCompletionProcessor
-     * and adapted to our needs.
-     * 
-     * @param viewer the viewer
-     * @param offset offset into document
-     * @return the prefix to consider
-     */
-    protected String extractElementPrefix(ITextViewer viewer, int offset) {
-        int i = offset;
-        IDocument document = viewer.getDocument();
-        if (i > document.getLength()) return ""; //$NON-NLS-1$
-
-        try {
-            for (; i > 0; --i) {
-                char ch = document.getChar(i - 1);
-                // accepted characters are a-z and : (for attributes' namespace)
-                if (ch != ':' && (ch < 'a' || ch > 'z')) break;
-            }
-
-            return document.get(i, offset - i);
-        } catch (BadLocationException e) {
-            return ""; //$NON-NLS-1$
-        }
-    }
-    
-    /**
-     * Extracts the character at the given offset.
-     * Returns 0 if the offset is invalid.
-     */
-    protected char extractChar(ITextViewer viewer, int offset) {
-        IDocument document = viewer.getDocument();
-        if (offset > document.getLength()) return 0;
-
-        try {
-            return document.getChar(offset);
-        } catch (BadLocationException e) {
-            return 0;
-        }
-    }
-
-    /**
-     * Information about the current edit of an attribute as reported by parseAttributeInfo.
-     */
-    private class AttribInfo {
-        /** True if the cursor is located in an attribute's value, false if in an attribute name */
-        public boolean isInValue = false;
-        /** The attribute name. Null when not set. */
-        public String name = null;
-        /** The attribute value. Null when not set. The value *may* start with a quote
-         *  (' or "), in which case we know we don't need to quote the string for the user */
-        public String value = null;
-        /** String typed by the user so far (i.e. right before requesting code completion),
-         *  which will be corrected if we find a possible completion for an attribute value.
-         *  See the long comment in getChoicesForAttribute(). */
-        public String correctedPrefix = null;
-        /** Non-zero if an attribute value need a start/end tag (i.e. quotes or brackets) */
-        public char needTag = 0;
-    }
-
-
-    /**
-     * Try to guess if the cursor is editing an element's name or an attribute following an
-     * element. If it's an attribute, try to find if an attribute name is being defined or
-     * its value.
-     * <br/>
-     * This is currently *only* called when we know the cursor is after a complete element
-     * tag name, so it should never return null.
-     * <br/>
-     * Reference for XML syntax: http://www.w3.org/TR/2006/REC-xml-20060816/#sec-starttags
-     * <br/>
-     * @return An AttribInfo describing which attribute is being edited or null if the cursor is
-     *         not editing an attribute (in which case it must be an element's name).
-     */
-    private AttribInfo parseAttributeInfo(ITextViewer viewer, int offset) {
-        AttribInfo info = new AttribInfo();
-
-        IDocument document = viewer.getDocument();
-        int n = document.getLength();
-        if (offset <= n) {
-            try {
-                n = offset;
-                for (;offset > 0; --offset) {
-                    char ch = document.getChar(offset - 1);
-                    if (ch == '<') break;
-                }
-
-                // text will contain the full string of the current element,
-                // i.e. whatever is after the "<" to the current cursor
-                String text = document.get(offset, n - offset);
-                
-                // Normalize whitespace to single spaces
-                text = sWhitespace.matcher(text).replaceAll(" "); //$NON-NLS-1$
-
-                // Remove the leading element name. By spec, it must be after the < without
-                // any whitespace. If there's nothing left, no attribute has been defined yet.
-                // Be sure to keep any whitespace after the initial word if any, as it matters.
-                text = sFirstElementWord.matcher(text).replaceFirst("");  //$NON-NLS-1$
-                
-                // There MUST be space after the element name. If not, the cursor is still
-                // defining the element name.
-                if (!text.startsWith(" ")) { //$NON-NLS-1$
-                    return null;
-                }
-                
-                // Remove full attributes:
-                // Syntax:
-                //    name = "..." quoted string with all but < and "
-                // or:
-                //    name = '...' quoted string with all but < and '
-                String temp;
-                do {
-                    temp = text;
-                    text = sFirstAttribute.matcher(temp).replaceFirst("");  //$NON-NLS-1$
-                } while(!temp.equals(text));
-
-                // Now we're left with 3 cases:
-                // - nothing: either there is no attribute definition or the cursor located after
-                //   a completed attribute definition.
-                // - a string with no =: the user is writing an attribute name. This case can be
-                //   merged with the previous one.
-                // - string with an = sign, optionally followed by a quote (' or "): the user is
-                //   writing the value of the attribute.
-                int pos_equal = text.indexOf('='); 
-                if (pos_equal == -1) {
-                    info.isInValue = false;
-                    info.name = text.trim();
-                } else {
-                    info.isInValue = true;
-                    info.name = text.substring(0, pos_equal).trim();
-                    info.value = text.substring(pos_equal + 1).trim();
-                }
-                return info;
-            } catch (BadLocationException e) {
-                // pass
-            }
-        }
-
-        return null;
-    }
-
-
-    /**
-     * Returns the XML DOM node corresponding to the given offset of the given document.
-     */
-    protected Node getNode(ITextViewer viewer, int offset) {
-        Node node = null;
-        try {
-            IModelManager mm = StructuredModelManager.getModelManager();
-            if (mm != null) {
-                IStructuredModel model = mm.getExistingModelForRead(viewer.getDocument());
-                if (model != null) {
-                    for(; offset >= 0 && node == null; --offset) {
-                        node = (Node) model.getIndexedRegion(offset);
-                    }
-                }
-            }
-        } catch (Exception e) {
-            // Ignore exceptions.
-        }
-
-        return node;
-    }
-    
-    /**
-     * Computes (if needed) and returns the root descriptor.
-     */
-    private ElementDescriptor getRootDescriptor() {
-        if (mRootDescriptor == null) {
-            AndroidTargetData data = mEditor.getTargetData();
-            if (data != null) {
-                IDescriptorProvider descriptorProvider = data.getDescriptorProvider(mDescriptorId);
-                
-                if (descriptorProvider != null) {
-                    mRootDescriptor = new ElementDescriptor("",
-                            descriptorProvider.getRootElementDescriptors());
-                }
-            }
-        }
-        
-        return mRootDescriptor;
-    }
-    
-    /**
-     * Returns the active {@link AndroidEditor} matching this source viewer.
-     */
-    private AndroidEditor getAndroidEditor(ITextViewer viewer) {
-        IWorkbenchWindow wwin = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-        if (wwin != null) {
-            IWorkbenchPage page = wwin.getActivePage();
-            if (page != null) {
-                IEditorPart editor = page.getActiveEditor();
-                if (editor instanceof AndroidEditor) {
-                    ISourceViewer ssviewer = ((AndroidEditor) editor).getStructuredSourceViewer();
-                    if (ssviewer == viewer) {
-                        return (AndroidEditor) editor;
-                    }
-                }
-            }
-        }
-
-        return null;
-    }
-    
-    
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidEditor.java
deleted file mode 100644
index dca7db0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidEditor.java
+++ /dev/null
@@ -1,820 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceChangeEvent;
-import org.eclipse.core.resources.IResourceChangeListener;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.actions.ActionFactory;
-import org.eclipse.ui.browser.IWorkbenchBrowserSupport;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.forms.editor.IFormPage;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.events.IHyperlinkListener;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.internal.browser.WorkbenchBrowserSupport;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.part.MultiPageEditorPart;
-import org.eclipse.ui.part.WorkbenchPart;
-import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IModelStateListener;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.sse.ui.StructuredTextEditor;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
-import org.w3c.dom.Document;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-
-/**
- * Multi-page form editor for Android XML files.
- * <p/>
- * It is designed to work with a {@link StructuredTextEditor} that will display an XML file.
- * <br/>
- * Derived classes must implement createFormPages to create the forms before the
- * source editor. This can be a no-op if desired.
- */
-public abstract class AndroidEditor extends FormEditor implements IResourceChangeListener {
-    
-    /** Preference name for the current page of this file */
-    private static final String PREF_CURRENT_PAGE = "_current_page";
-
-    /** Id string used to create the Android SDK browser */
-    private static String BROWSER_ID = "android"; // $NON-NLS-1$
-
-    /** Page id of the XML source editor, used for switching tabs programmatically */
-    public final static String TEXT_EDITOR_ID = "editor_part"; //$NON-NLS-1$
-
-    /** Width hint for text fields. Helps the grid layout resize properly on smaller screens */
-    public static final int TEXT_WIDTH_HINT = 50;
-    
-    /** Page index of the text editor (always the last page) */
-    private int mTextPageIndex;
-    /** The text editor */
-    private StructuredTextEditor mTextEditor;
-    /** Listener for the XML model from the StructuredEditor */
-    private XmlModelStateListener mXmlModelStateListener;
-    /** Listener to update the root node if the resource framework changes */
-    private Runnable mResourceRefreshListener;
-
-    /**
-     * Creates a form editor.
-     */
-    public AndroidEditor() {
-        super();
-        ResourcesPlugin.getWorkspace().addResourceChangeListener(this);
-        
-        mResourceRefreshListener = new Runnable() {
-            public void run() {
-                commitPages(false /* onSave */);
-
-                // recreate the ui root node always
-                initUiRootNode(true /*force*/);
-            }
-        };
-        AdtPlugin.getDefault().addResourceChangedListener(mResourceRefreshListener);
-    }
-
-    // ---- Abstract Methods ----
-
-    /**
-     * Returns the root node of the UI element hierarchy manipulated by the current
-     * UI node editor.
-     */
-    abstract public UiElementNode getUiRootNode();
-    
-    /**
-     * Creates the various form pages.
-     * <p/>
-     * Derived classes must implement this to add their own specific tabs.
-     */
-    abstract protected void createFormPages();
-    
-    /**
-     * Creates the initial UI Root Node, including the known mandatory elements.
-     * @param force if true, a new UiManifestNode is recreated even if it already exists.
-     */
-    abstract protected void initUiRootNode(boolean force);
-
-    /**
-     * Subclasses should override this method to process the new XML Model, which XML
-     * root node is given.
-     * 
-     * The base implementation is empty.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    protected void xmlModelChanged(Document xml_doc) {
-        // pass
-    }
-
-    // ---- Base Class Overrides, Interfaces Implemented ----
-
-    /**
-     * Creates the pages of the multi-page editor.
-     */
-    @Override
-    protected void addPages() {
-        createAndroidPages();
-        selectDefaultPage(null /* defaultPageId */);
-    }
-    
-    /**
-     * Creates the page for the Android Editors
-     */
-    protected void createAndroidPages() {
-        createFormPages();
-        createTextEditor();
-
-        createUndoRedoActions();
-    }
-
-    /**
-     * Creates undo redo actions for the editor site (so that it works for any page of this
-     * multi-page editor) by re-using the actions defined by the {@link StructuredTextEditor}
-     * (aka the XML text editor.)
-     */
-    private void createUndoRedoActions() {
-        IActionBars bars = getEditorSite().getActionBars();
-        if (bars != null) {
-            IAction action = mTextEditor.getAction(ActionFactory.UNDO.getId());
-            bars.setGlobalActionHandler(ActionFactory.UNDO.getId(), action);
-
-            action = mTextEditor.getAction(ActionFactory.REDO.getId());
-            bars.setGlobalActionHandler(ActionFactory.REDO.getId(), action);
-            
-            bars.updateActionBars();
-        }
-    }
-
-    /**
-     * Selects the default active page.
-     * @param defaultPageId the id of the page to show. If <code>null</code> the editor attempts to
-     * find the default page in the properties of the {@link IResource} object being edited.
-     */
-    protected void selectDefaultPage(String defaultPageId) {
-        if (defaultPageId == null) {
-            if (getEditorInput() instanceof IFileEditorInput) {
-                IFile file = ((IFileEditorInput) getEditorInput()).getFile();
-    
-                QualifiedName qname = new QualifiedName(AdtPlugin.PLUGIN_ID,
-                        getClass().getSimpleName() + PREF_CURRENT_PAGE);
-                String pageId;
-                try {
-                    pageId = file.getPersistentProperty(qname);
-                    if (pageId != null) {
-                        defaultPageId = pageId;
-                    }
-                } catch (CoreException e) {
-                    // ignored
-                }
-            }
-        }
-
-        if (defaultPageId != null) {
-            try {
-                setActivePage(Integer.parseInt(defaultPageId));
-            } catch (Exception e) {
-                // We can get NumberFormatException from parseInt but also
-                // AssertionError from setActivePage when the index is out of bounds.
-                // Generally speaking we just want to ignore any exception and fall back on the
-                // first page rather than crash the editor load. Logging the error is enough.
-                AdtPlugin.log(e, "Selecting page '%s' in AndroidEditor failed", defaultPageId);
-            }
-        }
-    }
-    
-    /**
-     * Removes all the pages from the editor.
-     */
-    protected void removePages() {
-        int count = getPageCount();
-        for (int i = count - 1 ; i >= 0 ; i--) {
-            removePage(i);
-        }
-    }
-
-    /**
-     * Overrides the parent's setActivePage to be able to switch to the xml editor.
-     * 
-     * If the special pageId TEXT_EDITOR_ID is given, switches to the mTextPageIndex page.
-     * This is needed because the editor doesn't actually derive from IFormPage and thus
-     * doesn't have the get-by-page-id method. In this case, the method returns null since 
-     * IEditorPart does not implement IFormPage.
-     */
-    @Override
-    public IFormPage setActivePage(String pageId) {
-        if (pageId.equals(TEXT_EDITOR_ID)) {
-            super.setActivePage(mTextPageIndex);
-            return null;
-        } else {
-            return super.setActivePage(pageId);
-        }
-    }
-   
-    
-    /**
-     * Notifies this multi-page editor that the page with the given id has been
-     * activated. This method is called when the user selects a different tab.
-     * 
-     * @see MultiPageEditorPart#pageChange(int)
-     */
-    @Override
-    protected void pageChange(int newPageIndex) {
-        super.pageChange(newPageIndex);
-        
-        if (getEditorInput() instanceof IFileEditorInput) {
-            IFile file = ((IFileEditorInput) getEditorInput()).getFile();
-
-            QualifiedName qname = new QualifiedName(AdtPlugin.PLUGIN_ID,
-                    getClass().getSimpleName() + PREF_CURRENT_PAGE);
-            try {
-                file.setPersistentProperty(qname, Integer.toString(newPageIndex));
-            } catch (CoreException e) {
-                // ignore
-            }
-        }
-    }
-
-    /**
-     * Notifies this listener that some resource changes 
-     * are happening, or have already happened.
-     * 
-     * Closes all project files on project close.
-     * @see IResourceChangeListener
-     */
-    public void resourceChanged(final IResourceChangeEvent event) {
-        if (event.getType() == IResourceChangeEvent.PRE_CLOSE) {
-            Display.getDefault().asyncExec(new Runnable() {
-                public void run() {
-                    IWorkbenchPage[] pages = getSite().getWorkbenchWindow()
-                            .getPages();
-                    for (int i = 0; i < pages.length; i++) {
-                        if (((FileEditorInput)mTextEditor.getEditorInput())
-                                .getFile().getProject().equals(
-                                        event.getResource())) {
-                            IEditorPart editorPart = pages[i].findEditor(mTextEditor
-                                    .getEditorInput());
-                            pages[i].closeEditor(editorPart, true);
-                        }
-                    }
-                }
-            });
-        }
-    }
-
-    /**
-     * Initializes the editor part with a site and input.
-     * <p/>
-     * Checks that the input is an instance of {@link IFileEditorInput}.
-     * 
-     * @see FormEditor
-     */
-    @Override
-    public void init(IEditorSite site, IEditorInput editorInput) throws PartInitException {
-        if (!(editorInput instanceof IFileEditorInput))
-            throw new PartInitException("Invalid Input: Must be IFileEditorInput");
-        super.init(site, editorInput);
-    }
-
-    /**
-     * Removes attached listeners.
-     * 
-     * @see WorkbenchPart
-     */
-    @Override
-    public void dispose() {
-        IStructuredModel xml_model = getModelForRead();
-        if (xml_model != null) {
-            try {
-                if (mXmlModelStateListener != null) {
-                    xml_model.removeModelStateListener(mXmlModelStateListener);
-                }
-        
-            } finally {
-                xml_model.releaseFromRead();
-            }
-        }
-        ResourcesPlugin.getWorkspace().removeResourceChangeListener(this);
-
-        if (mResourceRefreshListener != null) {
-            AdtPlugin.getDefault().removeResourceChangedListener(mResourceRefreshListener);
-            mResourceRefreshListener = null;
-        }
-
-        super.dispose();
-    }
-    
-    /**
-     * Commit all dirty pages then saves the contents of the text editor.
-     * <p/>
-     * This works by committing all data to the XML model and then
-     * asking the Structured XML Editor to save the XML.
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public void doSave(IProgressMonitor monitor) {
-        commitPages(true /* onSave */);
-
-        // The actual "save" operation is done by the Structured XML Editor
-        getEditor(mTextPageIndex).doSave(monitor);
-    }
-
-    /* (non-Javadoc)
-     * Saves the contents of this editor to another object.
-     * <p>
-     * Subclasses must override this method to implement the open-save-close lifecycle
-     * for an editor.  For greater details, see <code>IEditorPart</code>
-     * </p>
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public void doSaveAs() {
-        commitPages(true /* onSave */);
-
-        IEditorPart editor = getEditor(mTextPageIndex);
-        editor.doSaveAs();
-        setPageText(mTextPageIndex, editor.getTitle());
-        setInput(editor.getEditorInput());
-    }
-
-    /**
-     * Commits all dirty pages in the editor. This method should
-     * be called as a first step of a 'save' operation.
-     * <p/>
-     * This is the same implementation as in {@link FormEditor}
-     * except it fixes two bugs: a cast to IFormPage is done
-     * from page.get(i) <em>before</em> being tested with instanceof.
-     * Another bug is that the last page might be a null pointer.
-     * <p/>
-     * The incorrect casting makes the original implementation crash due
-     * to our {@link StructuredTextEditor} not being an {@link IFormPage}
-     * so we have to override and duplicate to fix it.
-     * 
-     * @param onSave <code>true</code> if commit is performed as part
-     * of the 'save' operation, <code>false</code> otherwise.
-     * @since 3.3
-     */
-    @Override
-    public void commitPages(boolean onSave) {
-        if (pages != null) {
-            for (int i = 0; i < pages.size(); i++) {
-                Object page = pages.get(i);
-                if (page != null && page instanceof IFormPage) {
-                    IFormPage form_page = (IFormPage) page;
-                    IManagedForm managed_form = form_page.getManagedForm();
-                    if (managed_form != null && managed_form.isDirty()) {
-                        managed_form.commit(onSave);
-                    }
-                }
-            }
-        }   
-    }
-
-    /* (non-Javadoc)
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p>
-     * Subclasses must override this method to implement the open-save-close lifecycle
-     * for an editor.  For greater details, see <code>IEditorPart</code>
-     * </p>
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return false;
-    }
-
-    // ---- Local methods ----
-
-
-    /**
-     * Helper method that creates a new hyper-link Listener.
-     * Used by derived classes which need active links in {@link FormText}.
-     * <p/>
-     * This link listener handles two kinds of URLs:
-     * <ul>
-     * <li> Links starting with "http" are simply sent to a local browser.
-     * <li> Links starting with "file:/" are simply sent to a local browser.
-     * <li> Links starting with "page:" are expected to be an editor page id to switch to.
-     * <li> Other links are ignored.
-     * </ul> 
-     * 
-     * @return A new hyper-link listener for FormText to use.
-     */
-    public final IHyperlinkListener createHyperlinkListener() {
-        return new HyperlinkAdapter() {
-            /**
-             * Switch to the page corresponding to the link that has just been clicked.
-             * For this purpose, the HREF of the &lt;a&gt; tags above is the page ID to switch to.
-             */
-            @Override
-            public void linkActivated(HyperlinkEvent e) {
-                super.linkActivated(e);
-                String link = e.data.toString();
-                if (link.startsWith("http") ||          //$NON-NLS-1$
-                        link.startsWith("file:/")) {    //$NON-NLS-1$
-                    openLinkInBrowser(link);
-                } else if (link.startsWith("page:")) {  //$NON-NLS-1$
-                    // Switch to an internal page
-                    setActivePage(link.substring(5 /* strlen("page:") */));
-                }
-            }
-        };
-    }
-
-    /**
-     * Open the http link into a browser
-     * 
-     * @param link The URL to open in a browser
-     */
-    private void openLinkInBrowser(String link) {
-        try {
-            IWorkbenchBrowserSupport wbs = WorkbenchBrowserSupport.getInstance();
-            wbs.createBrowser(BROWSER_ID).openURL(new URL(link));
-        } catch (PartInitException e1) {
-            // pass
-        } catch (MalformedURLException e1) {
-            // pass
-        }
-    }
-
-    /**
-     * Creates the XML source editor.
-     * <p/>
-     * Memorizes the index page of the source editor (it's always the last page, but the number
-     * of pages before can change.)
-     * <br/>
-     * Retrieves the underlying XML model from the StructuredEditor and attaches a listener to it.
-     * Finally triggers modelChanged() on the model listener -- derived classes can use this
-     * to initialize the model the first time.
-     * <p/>
-     * Called only once <em>after</em> createFormPages.
-     */
-    private void createTextEditor() {
-        try {
-            mTextEditor = new StructuredTextEditor();
-            int index = addPage(mTextEditor, getEditorInput());
-            mTextPageIndex = index;
-            setPageText(index, mTextEditor.getTitle());
-
-            if (!(mTextEditor.getTextViewer().getDocument() instanceof IStructuredDocument)) {
-                Status status = new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                        "Error opening the Android XML editor. Is the document an XML file?");
-                throw new RuntimeException("Android XML Editor Error", new CoreException(status));
-            }
-            
-            IStructuredModel xml_model = getModelForRead();
-            if (xml_model != null) {
-                try {
-                    mXmlModelStateListener = new XmlModelStateListener();
-                    xml_model.addModelStateListener(mXmlModelStateListener);
-                    mXmlModelStateListener.modelChanged(xml_model);
-                } catch (Exception e) {
-                    AdtPlugin.log(e, "Error while loading editor"); //$NON-NLS-1$
-                } finally {
-                    xml_model.releaseFromRead();
-                }
-            }
-        } catch (PartInitException e) {
-            ErrorDialog.openError(getSite().getShell(),
-                    "Android XML Editor Error", null, e.getStatus());
-        }
-    }
-    
-    /**
-     * Returns the ISourceViewer associated with the Structured Text editor. 
-     */
-    public final ISourceViewer getStructuredSourceViewer() {
-        if (mTextEditor != null) {
-            // We can't access mEditor.getSourceViewer() because it is protected,
-            // however getTextViewer simply returns the SourceViewer casted, so we
-            // can use it instead.
-            return mTextEditor.getTextViewer();
-        }
-        return null;
-    }
-
-    /**
-     * Returns the {@link IStructuredDocument} used by the StructuredTextEditor (aka Source
-     * Editor) or null if not available.
-     */
-    public final IStructuredDocument getStructuredDocument() {
-        if (mTextEditor != null && mTextEditor.getTextViewer() != null) {
-            return (IStructuredDocument) mTextEditor.getTextViewer().getDocument();
-        }
-        return null;
-    }
-    
-    /**
-     * Returns a version of the model that has been shared for read.
-     * <p/>
-     * Callers <em>must</em> call model.releaseFromRead() when done, typically
-     * in a try..finally clause.
-     *  
-     * @return The model for the XML document or null if cannot be obtained from the editor
-     */
-    public final IStructuredModel getModelForRead() {
-        IStructuredDocument document = getStructuredDocument();
-        if (document != null) {
-            IModelManager mm = StructuredModelManager.getModelManager();
-            if (mm != null) {
-                return mm.getModelForRead(document);
-            }
-        }
-        return null;
-    }    
-    
-    /**
-     * Returns a version of the model that has been shared for edit.
-     * <p/>
-     * Callers <em>must</em> call model.releaseFromEdit() when done, typically
-     * in a try..finally clause.
-     * 
-     * @return The model for the XML document or null if cannot be obtained from the editor
-     */
-    public final IStructuredModel getModelForEdit() {
-        IStructuredDocument document = getStructuredDocument();
-        if (document != null) {
-            IModelManager mm = StructuredModelManager.getModelManager();
-            if (mm != null) {
-                return mm.getModelForEdit(document);
-            }
-        }
-        return null;
-    }    
-
-    /**
-     * Helper class to perform edits on the XML model whilst making sure the
-     * model has been prepared to be changed.
-     * <p/>
-     * It first gets a model for edition using {@link #getModelForEdit()},
-     * then calls {@link IStructuredModel#aboutToChangeModel()},
-     * then performs the requested action
-     * and finally calls {@link IStructuredModel#changedModel()}
-     * and {@link IStructuredModel#releaseFromEdit()}.
-     * <p/>
-     * The method is synchronous. As soon as the {@link IStructuredModel#changedModel()} method
-     * is called, XML model listeners will be triggered.
-     * 
-     * @param edit_action Something that will change the XML.
-     */
-    public final void editXmlModel(Runnable edit_action) {
-        IStructuredModel model = getModelForEdit();
-        try {
-            model.aboutToChangeModel();
-            edit_action.run();
-        } finally {
-            // Notify the model we're done modifying it. This must *always* be executed.
-            model.changedModel();
-            model.releaseFromEdit();
-        }
-    }
-    
-    /**
-     * Starts an "undo recording" session. This is managed by the underlying undo manager
-     * associated to the structured XML model.
-     * <p/>
-     * There <em>must</em> be a corresponding call to {@link #endUndoRecording()}.
-     * <p/>
-     * beginUndoRecording/endUndoRecording calls can be nested (inner calls are ignored, only one
-     * undo operation is recorded.)
-     * 
-     * @param label The label for the undo operation. Can be null but we should really try to put
-     *              something meaningful if possible.
-     * @return True if the undo recording actually started, false if any kind of error occured.
-     *         {@link #endUndoRecording()} should only be called if True is returned.
-     */
-    private final boolean beginUndoRecording(String label) {
-        IStructuredDocument document = getStructuredDocument();
-        if (document != null) {
-            IModelManager mm = StructuredModelManager.getModelManager();
-            if (mm != null) {
-                IStructuredModel model = mm.getModelForEdit(document);
-                if (model != null) {
-                    model.beginRecording(this, label);
-                    return true;
-                }
-            }
-        }
-        return false;
-    }
-    
-    /**
-     * Ends an "undo recording" session.
-     * <p/>
-     * This is the counterpart call to {@link #beginUndoRecording(String)} and should only be
-     * used if the initial call returned true.
-     */
-    private final void endUndoRecording() {
-        IStructuredDocument document = getStructuredDocument();
-        if (document != null) {
-            IModelManager mm = StructuredModelManager.getModelManager();
-            if (mm != null) {
-                IStructuredModel model = mm.getModelForEdit(document);
-                if (model != null) {
-                    model.endRecording(this);
-                }
-            }
-        }
-    }
-    
-    /**
-     * Creates an "undo recording" session by calling the undoableAction runnable
-     * using {@link #beginUndoRecording(String)} and {@link #endUndoRecording()}.
-     * <p>
-     * You can nest several calls to {@link #wrapUndoRecording(String, Runnable)}, only one
-     * recording session will be created.
-     * 
-     * @param label The label for the undo operation. Can be null. Ideally we should really try
-     *              to put something meaningful if possible.
-     */
-    public void wrapUndoRecording(String label, Runnable undoableAction) {
-        boolean recording = false;
-        try {
-            recording = beginUndoRecording(label);
-            undoableAction.run();
-        } finally {
-            if (recording) {
-                endUndoRecording();
-            }
-        }
-    }
-    
-    /**
-     * Returns the XML {@link Document} or null if we can't get it
-     */
-    protected final Document getXmlDocument(IStructuredModel model) {
-        if (model == null) {
-            AdtPlugin.log(IStatus.WARNING, "Android Editor: No XML model for root node."); //$NON-NLS-1$
-            return null;
-        }
-
-        if (model instanceof IDOMModel) {
-            IDOMModel dom_model = (IDOMModel) model;
-            return dom_model.getDocument();
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the {@link IProject} for the edited file.
-     */
-    public IProject getProject() {
-        if (mTextEditor != null) {
-            IEditorInput input = mTextEditor.getEditorInput();
-            if (input instanceof FileEditorInput) {
-                FileEditorInput fileInput = (FileEditorInput)input;
-                IFile inputFile = fileInput.getFile();
-                
-                if (inputFile != null) {
-                    return inputFile.getProject();
-                }
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the {@link AndroidTargetData} for the edited file.
-     */
-    public AndroidTargetData getTargetData() {
-        IProject project = getProject();
-        if (project != null) {
-            Sdk currentSdk = Sdk.getCurrent();
-            if (currentSdk != null) {
-                IAndroidTarget target = currentSdk.getTarget(project);
-                
-                if (target != null) {
-                    return currentSdk.getTargetData(target);
-                }
-            }
-        }
-        
-        return null;
-    }
-
-    
-    /**
-     * Listen to changes in the underlying XML model in the structured editor.
-     */
-    private class XmlModelStateListener implements IModelStateListener {
-    
-        /**
-         * A model is about to be changed. This typically is initiated by one
-         * client of the model, to signal a large change and/or a change to the
-         * model's ID or base Location. A typical use might be if a client might
-         * want to suspend processing until all changes have been made.
-         * <p/>
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelAboutToBeChanged(IStructuredModel model) {
-            // pass
-        }
-    
-        /**
-         * Signals that the changes foretold by modelAboutToBeChanged have been
-         * made. A typical use might be to refresh, or to resume processing that
-         * was suspended as a result of modelAboutToBeChanged.
-         * <p/>
-         * This AndroidEditor implementation calls the xmlModelChanged callback.
-         */
-        public void modelChanged(IStructuredModel model) {
-            xmlModelChanged(getXmlDocument(model));
-        }
-    
-        /**
-         * Notifies that a model's dirty state has changed, and passes that state
-         * in isDirty. A model becomes dirty when any change is made, and becomes
-         * not-dirty when the model is saved.
-         * <p/>
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelDirtyStateChanged(IStructuredModel model, boolean isDirty) {
-            // pass
-        }
-    
-        /**
-         * A modelDeleted means the underlying resource has been deleted. The
-         * model itself is not removed from model management until all have
-         * released it. Note: baseLocation is not (necessarily) changed in this
-         * event, but may not be accurate.
-         * <p/>
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelResourceDeleted(IStructuredModel model) {
-            // pass
-        }
-    
-        /**
-         * A model has been renamed or copied (as in saveAs..). In the renamed
-         * case, the two paramenters are the same instance, and only contain the
-         * new info for id and base location.
-         * <p/>
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelResourceMoved(IStructuredModel oldModel, IStructuredModel newModel) {
-            // pass
-        }
-    
-        /**
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelAboutToBeReinitialized(IStructuredModel structuredModel) {
-            // pass
-        }
-    
-        /**
-         * This AndroidEditor implementation of IModelChangedListener is empty.
-         */
-        public void modelReinitialized(IStructuredModel structuredModel) {
-            // pass
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidSourceViewerConfig.java
deleted file mode 100644
index ab17bef..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/AndroidSourceViewerConfig.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors;
-
-
-import org.eclipse.jface.text.IAutoEditStrategy;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.ITextHover;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.jface.text.contentassist.IContentAssistant;
-import org.eclipse.jface.text.formatter.IContentFormatter;
-import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.jface.viewers.IInputProvider;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
-import org.eclipse.wst.xml.core.text.IXMLPartitions;
-import org.eclipse.wst.xml.ui.StructuredTextViewerConfigurationXML;
-
-import java.util.ArrayList;
-
-/**
- * Base Source Viewer Configuration for Android resources.
- */
-public class AndroidSourceViewerConfig extends StructuredTextViewerConfigurationXML {
-
-    /** Content Assist Processor to use for all handled partitions. */
-    private IContentAssistProcessor mProcessor;
-
-    public AndroidSourceViewerConfig(IContentAssistProcessor processor) {
-        super();
-        mProcessor = processor;
-    }
-    
-    @Override
-    public IContentAssistant getContentAssistant(ISourceViewer sourceViewer) {
-        return super.getContentAssistant(sourceViewer);
-    }
-
-    /**
-     * Returns the content assist processors that will be used for content
-     * assist in the given source viewer and for the given partition type.
-     * 
-     * @param sourceViewer the source viewer to be configured by this
-     *        configuration
-     * @param partitionType the partition type for which the content assist
-     *        processors are applicable
-     * @return IContentAssistProcessors or null if should not be supported
-     */
-    @Override
-    protected IContentAssistProcessor[] getContentAssistProcessors(
-            ISourceViewer sourceViewer, String partitionType) {
-        ArrayList<IContentAssistProcessor> processors = new ArrayList<IContentAssistProcessor>();
-        if (partitionType == IStructuredPartitions.UNKNOWN_PARTITION ||
-            partitionType == IStructuredPartitions.DEFAULT_PARTITION ||
-            partitionType == IXMLPartitions.XML_DEFAULT) {
-            if (sourceViewer instanceof IInputProvider) {
-                IInputProvider input = (IInputProvider) sourceViewer;
-                Object a = input.getInput();
-                if (a != null)
-                    a.toString();
-            }
-
-            IDocument doc = sourceViewer.getDocument();
-            if (doc != null)
-                doc.toString();
-            
-            processors.add(mProcessor);
-        }
-
-        IContentAssistProcessor[] others = super.getContentAssistProcessors(sourceViewer,
-                partitionType);
-        if (others != null && others.length > 0) {
-            for (IContentAssistProcessor p : others) {
-                processors.add(p);
-            }
-        }
-        
-        if (processors.size() > 0) {
-            return processors.toArray(new IContentAssistProcessor[processors.size()]);
-        } else {
-            return null;
-        }
-    }
-    
-    @Override
-    public ITextHover getTextHover(ISourceViewer sourceViewer, String contentType) {
-        // TODO text hover for android xml
-        return super.getTextHover(sourceViewer, contentType);
-    }
-
-    @Override
-    public IAutoEditStrategy[] getAutoEditStrategies(
-            ISourceViewer sourceViewer, String contentType) {
-        // TODO auto edit strategies for android xml
-        return super.getAutoEditStrategies(sourceViewer, contentType);
-    }
-    
-    @Override
-    public IContentFormatter getContentFormatter(ISourceViewer sourceViewer) {
-        // TODO content formatter for android xml
-        return super.getContentFormatter(sourceViewer);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/FirstElementParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/FirstElementParser.java
deleted file mode 100644
index bb0996b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/FirstElementParser.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-import org.xml.sax.helpers.DefaultHandler;
-
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.IOException;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * Quickly parses a (potential) XML file to extract its first element (i.e. the root element)
- * and namespace, if any.
- * <p/>
- * This is used to determine if a file is an XML document that the XmlEditor can process.
- * <p/>
- * TODO use this to remove the hardcoded "android" namespace prefix limitation.
- */
-public final class FirstElementParser {
-    
-    private static SAXParserFactory sSaxfactory;
-    
-    /**
-     * Result from the XML parsing. <br/>
-     * Contains the name of the root XML element. <br/>
-     * If an XMLNS URI was specified and found, the XMLNS prefix is recorded. Otherwise it is null.
-     */
-    public static final class Result {
-        private String mElement;
-        private String mXmlnsPrefix;
-        private String mXmlnsUri;
-        
-        public String getElement() {
-            return mElement;
-        }
-        
-        public String getXmlnsPrefix() {
-            return mXmlnsPrefix;
-        }
-        
-        public String getXmlnsUri() {
-            return mXmlnsUri;
-        }
-        
-        void setElement(String element) {
-            mElement = element;
-        }
-        
-        void setXmlnsPrefix(String xmlnsPrefix) {
-            mXmlnsPrefix = xmlnsPrefix;
-        }
-        
-        void setXmlnsUri(String xmlnsUri) {
-            mXmlnsUri = xmlnsUri;
-        }
-    }
-    
-    private static class ResultFoundException extends SAXException { }
-    
-    /**
-     * Parses the given filename.
-     * 
-     * @param osFilename The file to parse.
-     * @param xmlnsUri An optional URL of which we want to know the prefix. 
-     * @return The element details found or null if not found.
-     */
-    public static Result parse(String osFilename, String xmlnsUri) {
-        if (sSaxfactory == null) {
-            // TODO just create a single factory in CommonPlugin and reuse it
-            sSaxfactory = SAXParserFactory.newInstance();
-            sSaxfactory.setNamespaceAware(true);
-        }
-
-        Result result = new Result();
-        if (xmlnsUri != null && xmlnsUri.length() > 0) {
-            result.setXmlnsUri(xmlnsUri);
-        }
-
-        try {
-            SAXParser parser = sSaxfactory.newSAXParser();
-            XmlHandler handler = new XmlHandler(result);
-            parser.parse(new InputSource(new FileReader(osFilename)), handler);
-
-        } catch(ResultFoundException e) {
-            // XML handling was aborted because the required element was found.
-            // Simply return the result.
-            return result;
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (FileNotFoundException e) {
-        } catch (IOException e) {
-        }
-
-        return null;
-    }
-
-    /**
-     * Private constructor. Use the static parse() method instead.
-     */
-    private FirstElementParser() {
-        // pass
-    }
-    
-    /**
-     * A specialized SAX handler that captures the arguments of the very first element
-     * (i.e. the root element)
-     */
-    private static class XmlHandler extends DefaultHandler {
-        private final Result mResult;
-
-        public XmlHandler(Result result) {
-            mResult = result;
-        }
-        
-        /**
-         * Processes a namespace prefix mapping.
-         * I.e. for xmlns:android="some-uri", this received prefix="android" and uri="some-uri".
-         * <p/>
-         * The prefix is recorded in the result structure if the URI is the one searched for.
-         * <p/>
-         * This event happens <em>before</em> the corresponding startElement event.
-         */
-        @Override
-        public void startPrefixMapping(String prefix, String uri) {
-            if (uri.equals(mResult.getXmlnsUri())) {
-                mResult.setXmlnsPrefix(prefix);
-            }
-        }
-
-        /**
-         * Processes a new element start.
-         * <p/>
-         * This simply records the element name and abort processing by throwing an exception.
-         */
-        @Override
-        public void startElement(String uri, String localName, String name, Attributes attributes)
-            throws SAXException {
-            mResult.setElement(localName);
-            throw new ResultFoundException();
-        }
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/IconFactory.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/IconFactory.java
deleted file mode 100644
index 2c24772..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/IconFactory.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.widgets.Display;
-
-import java.util.HashMap;
-
-/**
- * Factory to generate icons for Android Editors.
- * <p/>
- * Icons are kept here and reused.
- */
-public class IconFactory {
-
-    public static final int COLOR_RED     = SWT.COLOR_DARK_RED;
-    public static final int COLOR_GREEN   = SWT.COLOR_DARK_GREEN;
-    public static final int COLOR_BLUE    = SWT.COLOR_DARK_BLUE;
-    public static final int COLOR_DEFAULT = SWT.COLOR_BLACK;
-
-    public static final int SHAPE_CIRCLE  = 'C';
-    public static final int SHAPE_RECT    = 'R';
-    public static final int SHAPE_DEFAULT = SHAPE_CIRCLE;
-    
-    private static IconFactory sInstance;
-
-    private HashMap<String, Image> mIconMap = new HashMap<String, Image>();
-    private HashMap<String, ImageDescriptor> mImageDescMap = new HashMap<String, ImageDescriptor>();
-    
-    private IconFactory() {
-    }
-    
-    public static synchronized IconFactory getInstance() {
-        if (sInstance == null) {
-            sInstance = new IconFactory();
-        }
-        return sInstance;
-    }
-    
-    public void Dispose() {
-        // Dispose icons
-        for (Image icon : mIconMap.values()) {
-            // The map can contain null values
-            if (icon != null) {
-                icon.dispose();
-            }
-        }
-        mIconMap.clear();
-    }
-
-    /**
-     * Returns an Image for a given icon name.
-     * <p/>
-     * Callers should not dispose it.
-     * 
-     * @param osName The leaf name, without the extension, of an existing icon in the
-     *        editor's "icons" directory. If it doesn't exists, a default icon will be
-     *        generated automatically based on the name.
-     */
-    public Image getIcon(String osName) {
-        return getIcon(osName, COLOR_DEFAULT, SHAPE_DEFAULT);
-    }
-
-    /**
-     * Returns an Image for a given icon name.
-     * <p/>
-     * Callers should not dispose it.
-     * 
-     * @param osName The leaf name, without the extension, of an existing icon in the
-     *        editor's "icons" directory. If it doesn't exists, a default icon will be
-     *        generated automatically based on the name.
-     * @param color The color of the text in the automatically generated icons,
-     *        one of COLOR_DEFAULT, COLOR_RED, COLOR_BLUE or COLOR_RED.
-     * @param shape The shape of the icon in the automatically generated icons,
-     *        one of SHAPE_DEFAULT, SHAPE_CIRCLE or SHAPE_RECT.
-     */
-    public Image getIcon(String osName, int color, int shape) {
-        String key = Character.toString((char) shape) + Integer.toString(color) + osName;
-        Image icon = mIconMap.get(key);
-        if (icon == null && !mIconMap.containsKey(key)) {
-            ImageDescriptor id = getImageDescriptor(osName, color, shape);
-            if (id != null) {
-                icon = id.createImage();
-            }
-            // Note that we store null references in the icon map, to avoid looking them
-            // up every time. If it didn't exist once, it will not exist later.
-            mIconMap.put(key, icon);
-        }
-        return icon;
-    }
-
-    /**
-     * Returns an ImageDescriptor for a given icon name.
-     * <p/>
-     * Callers should not dispose it.
-     * 
-     * @param osName The leaf name, without the extension, of an existing icon in the
-     *        editor's "icons" directory. If it doesn't exists, a default icon will be
-     *        generated automatically based on the name.
-     */
-    public ImageDescriptor getImageDescriptor(String osName) {
-        return getImageDescriptor(osName, COLOR_DEFAULT, SHAPE_DEFAULT);
-    }
-    
-    /**
-     * Returns an ImageDescriptor for a given icon name.
-     * <p/>
-     * Callers should not dispose it.
-     * 
-     * @param osName The leaf name, without the extension, of an existing icon in the
-     *        editor's "icons" directory. If it doesn't exists, a default icon will be
-     *        generated automatically based on the name.
-     * @param color The color of the text in the automatically generated icons.
-     *        one of COLOR_DEFAULT, COLOR_RED, COLOR_BLUE or COLOR_RED.
-     * @param shape The shape of the icon in the automatically generated icons,
-     *        one of SHAPE_DEFAULT, SHAPE_CIRCLE or SHAPE_RECT.
-     */
-    public ImageDescriptor getImageDescriptor(String osName, int color, int shape) {
-        String key = Character.toString((char) shape) + Integer.toString(color) + osName;
-        ImageDescriptor id = mImageDescMap.get(key);
-        if (id == null && !mImageDescMap.containsKey(key)) {
-            id = AdtPlugin.imageDescriptorFromPlugin(
-                    AdtPlugin.PLUGIN_ID,
-                    String.format("/icons/%1$s.png", osName)); //$NON-NLS-1$
-
-            if (id == null) {
-                id = new LetterImageDescriptor(osName.charAt(0), color, shape);
-            }
-            
-            // Note that we store null references in the icon map, to avoid looking them
-            // up every time. If it didn't exist once, it will not exist later.
-            mImageDescMap.put(key, id);
-        }
-        return id;
-    }
-
-    /**
-     * A simple image description that generates a 16x16 image which consists
-     * of a colored letter inside a black & white circle.
-     */
-    private static class LetterImageDescriptor extends ImageDescriptor {
-
-        private final char mLetter;
-        private final int mColor;
-        private final int mShape;
-
-        public LetterImageDescriptor(char letter, int color, int shape) {
-            mLetter = letter;
-            mColor = color;
-            mShape = shape;
-        }
-        
-        @Override
-        public ImageData getImageData() {
-            
-            final int SX = 15;
-            final int SY = 15;
-            final int RX = 4;
-            final int RY = 4;
-            
-            Display display = Display.getCurrent();
-            if (display == null) {
-                return null;
-            }
-
-            Image image = new Image(display, SX, SY);
-            
-            image.setBackground(display.getSystemColor(SWT.COLOR_WHITE));
-            
-            GC gc = new GC(image);
-            gc.setAdvanced(true);
-            gc.setAntialias(SWT.ON);
-            gc.setTextAntialias(SWT.ON);
-
-            gc.setBackground(display.getSystemColor(SWT.COLOR_WHITE));
-            if (mShape == SHAPE_CIRCLE) {
-                gc.fillOval(0, 0, SX - 1, SY - 1);
-            } else if (mShape == SHAPE_RECT) {
-                gc.fillRoundRectangle(0, 0, SX - 1, SY - 1, RX, RY);
-            }
-            
-            gc.setForeground(display.getSystemColor(SWT.COLOR_BLACK));
-            gc.setLineWidth(1);
-            if (mShape == SHAPE_CIRCLE) {
-                gc.drawOval(0, 0, SX - 1, SY - 1);
-            } else if (mShape == SHAPE_RECT) {
-                gc.drawRoundRectangle(0, 0, SX - 1, SY - 1, RX, RY);
-            }
-
-            // Get a bold version of the default system font, if possible.
-            Font font = display.getSystemFont();
-            FontData[] fds = font.getFontData();
-            fds[0].setStyle(SWT.BOLD);
-            // use 3/4th of the circle diameter for the font size (in pixels)
-            // and convert it to "font points" (font points in SWT are hardcoded in an
-            // arbitrary 72 dpi and then converted in real pixels using whatever is
-            // indicated by getDPI -- at least that's how it works under Win32).
-            fds[0].setHeight((int) ((SY + 1) * 3./4. * 72./display.getDPI().y));
-            // Note: win32 implementation always uses fds[0] so we change just that one.
-            // getFontData indicates that the array of fd is really an unusual thing for X11.
-            font = new Font(display, fds);
-            gc.setFont(font);
-            gc.setForeground(display.getSystemColor(mColor));
-
-            // Text measurement varies so slightly depending on the platform
-            int ofx = 0;
-            int ofy = 0;
-            if (SdkConstants.CURRENT_PLATFORM == SdkConstants.PLATFORM_WINDOWS) {
-                ofx = +1;
-                ofy = -1;
-            }
-            
-            String s = Character.toString(mLetter).toUpperCase();
-            Point p = gc.textExtent(s);
-            int tx = (SX + ofx - p.x) / 2;
-            int ty = (SY + ofy - p.y) / 2;
-            gc.drawText(s, tx, ty, true /* isTransparent */);
-
-            font.dispose();
-            gc.dispose();
-            
-            ImageData data = image.getImageData();
-            image.dispose();
-            return data;
-        }
-        
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptor.java
deleted file mode 100644
index e0ec86b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptor.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * {@link AttributeDescriptor} describes an XML attribute with its XML attribute name.
- * <p/>
- * An attribute descriptor also knows which UI node should be instantiated to represent
- * this particular attribute (e.g. text field, icon chooser, class selector, etc.)
- * Some attributes may be hidden and have no user interface at all.
- * <p/>
- * This is an abstract class. Derived classes must implement data description and return
- * the correct UiAttributeNode-derived class.
- */
-public abstract class AttributeDescriptor {
-    private String mXmlLocalName;
-    private ElementDescriptor mParent;
-    private final String mNsUri;
-    private boolean mDeprecated;
-    
-    /**
-     * Creates a new {@link AttributeDescriptor}
-     * 
-     * @param xmlLocalName The XML name of the attribute (case sensitive)
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     */
-    public AttributeDescriptor(String xmlLocalName, String nsUri) {
-        mXmlLocalName = xmlLocalName;
-        mNsUri = nsUri;
-    }
-
-    /**
-     * Returns the XML local name of the attribute (case sensitive)
-     */
-    public final String getXmlLocalName() {
-        return mXmlLocalName;
-    }
-    
-    public final String getNamespaceUri() {
-        return mNsUri;
-    }
-    
-    final void setParent(ElementDescriptor parent) {
-        mParent = parent;
-    }
-    
-    public final ElementDescriptor getParent() {
-        return mParent;
-    }
-
-    public void setDeprecated(boolean isDeprecated) {
-        mDeprecated = isDeprecated;
-    }
-    
-    public boolean isDeprecated() {
-        return mDeprecated;
-    }
-
-    /** 
-     * Returns an optional icon for the attribute.
-     * <p/>
-     * By default this tries to return an icon based on the XML name of the attribute.
-     * If this fails, it tries to return the default Android logo as defined in the
-     * plugin. If all fails, it returns null.
-     * 
-     * @return An icon for this element or null.
-     */
-    public Image getIcon() {
-        IconFactory factory = IconFactory.getInstance();
-        Image icon;
-        icon = factory.getIcon(getXmlLocalName(), IconFactory.COLOR_RED, IconFactory.SHAPE_CIRCLE);
-        return icon != null ? icon : AdtPlugin.getAndroidLogo();
-    }
-    
-    /**
-     * @param uiParent The {@link UiElementNode} parent of this UI attribute.
-     * @return A new {@link UiAttributeNode} linked to this descriptor or null if this
-     *         attribute has no user interface.
-     */
-    public abstract UiAttributeNode createUiNode(UiElementNode uiParent);
-}    
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptorLabelProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptorLabelProvider.java
deleted file mode 100644
index 2729565..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/AttributeDescriptorLabelProvider.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.uimodel.UiAbstractTextAttributeNode;
-
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * Label provider for {@link UiAbstractTextAttributeNode}.
- */
-public class AttributeDescriptorLabelProvider implements ILabelProvider {
-    
-    private final static AttributeDescriptorLabelProvider sThis =
-        new AttributeDescriptorLabelProvider();
-    
-    public static ILabelProvider getProvider() {
-        return sThis;
-    }
-
-    public Image getImage(Object element) {
-        if (element instanceof UiAbstractTextAttributeNode) {
-            UiAbstractTextAttributeNode node = (UiAbstractTextAttributeNode) element;
-            if (node.getDescriptor().isDeprecated()) {
-                String v = node.getCurrentValue();
-                if (v != null && v.length() > 0) {
-                    IconFactory factory = IconFactory.getInstance();
-                    return factory.getIcon("warning"); //$NON-NLS-1$
-                }                
-            }
-        }
-
-        return null;
-    }
-
-    public String getText(Object element) {
-        if (element instanceof UiAbstractTextAttributeNode) {
-            return ((UiAbstractTextAttributeNode)element).getCurrentValue();
-        }
-
-        return null;
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // TODO Auto-generated method stub
-
-    }
-
-    public void dispose() {
-        // TODO Auto-generated method stub
-
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        // TODO Auto-generated method stub
-        return false;
-    }
-
-    public void removeListener(ILabelProviderListener listener) {
-        // TODO Auto-generated method stub
-
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/BooleanAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/BooleanAttributeDescriptor.java
deleted file mode 100644
index 9ebf5f1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/BooleanAttributeDescriptor.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiListAttributeNode;
-
-/**
- * Describes a text attribute that can only contain boolean values.
- * It is displayed by a {@link UiListAttributeNode}.
- */
-public class BooleanAttributeDescriptor extends ListAttributeDescriptor {
-
-    public BooleanAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip,
-                new String[] { "true", "false" } );
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DescriptorsUtils.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DescriptorsUtils.java
deleted file mode 100644
index cc923bf..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DescriptorsUtils.java
+++ /dev/null
@@ -1,845 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo.Format;
-import com.android.ide.eclipse.editors.layout.LayoutConstants;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-
-/**
- * Utility methods related to descriptors handling.
- */
-public final class DescriptorsUtils {
-
-    private static final String DEFAULT_WIDGET_PREFIX = "widget";
-
-    private static final int JAVADOC_BREAK_LENGTH = 60;
-
-    /**
-     * The path in the online documentation for the manifest description.
-     * <p/>
-     * This is NOT a complete URL. To be used, it needs to be appended
-     * to {@link AndroidConstants#CODESITE_BASE_URL} or to the local SDK
-     * documentation.
-     */
-    public static final String MANIFEST_SDK_URL = "/reference/android/R.styleable.html#";  //$NON-NLS-1$
-
-    public static final String IMAGE_KEY = "image"; //$NON-NLS-1$
-    
-    private static final String CODE  = "$code";  //$NON-NLS-1$
-    private static final String LINK  = "$link";  //$NON-NLS-1$
-    private static final String ELEM  = "$elem";  //$NON-NLS-1$
-    private static final String BREAK = "$break"; //$NON-NLS-1$
-
-    /**
-     * The {@link ITextAttributeCreator} interface is used by the appendAttribute() method
-     * to provide a way for caller to override the kind of {@link TextAttributeDescriptor}
-     * created for a give XML attribute name.
-     */
-    public interface ITextAttributeCreator {
-        /**
-         * Creates a new {@link TextAttributeDescriptor} instance for the given XML name,
-         * UI name and tooltip.
-         * 
-         * @param xmlName The XML attribute name.
-         * @param uiName The UI attribute name.
-         * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-         *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-         * @param tooltip An optional tooltip.
-         * @return A new {@link TextAttributeDescriptor} (or derived) instance.
-         */
-        public TextAttributeDescriptor create(String xmlName, String uiName, String nsUri,
-                String tooltip);
-    }
-
-    /**
-     * Add all {@link AttributeInfo} to the the array of {@link AttributeDescriptor}.
-     * 
-     * @param attributes The list of {@link AttributeDescriptor} to append to
-     * @param elementXmlName Optional XML local name of the element to which attributes are
-     *              being added. When not null, this is used to filter overrides.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param infos The array of {@link AttributeInfo} to read and append to attributes
-     * @param requiredAttributes An optional set of attributes to mark as "required" (i.e. append
-     *        a "*" to their UI name as a hint for the user.) If not null, must contains
-     *        entries in the form "elem-name/attr-name". Elem-name can be "*".
-     * @param overrides A map [attribute name => TextAttributeDescriptor creator]. A creator
-     *        can either by a Class<? extends TextAttributeDescriptor> or an instance of
-     *        {@link ITextAttributeCreator} that instantiates the right TextAttributeDescriptor.
-     */
-    public static void appendAttributes(ArrayList<AttributeDescriptor> attributes,
-            String elementXmlName,
-            String nsUri, AttributeInfo[] infos,
-            Set<String> requiredAttributes,
-            Map<String, Object> overrides) {
-        for (AttributeInfo info : infos) {
-            boolean required = false;
-            if (requiredAttributes != null) {
-                String attr_name = info.getName();
-                if (requiredAttributes.contains("*/" + attr_name) ||
-                        requiredAttributes.contains(elementXmlName + "/" + attr_name)) {
-                    required = true;
-                }
-            }
-            appendAttribute(attributes, elementXmlName, nsUri, info, required, overrides);
-        }
-    }
-
-    /**
-     * Add an {@link AttributeInfo} to the the array of {@link AttributeDescriptor}.
-     * 
-     * @param attributes The list of {@link AttributeDescriptor} to append to
-     * @param elementXmlName Optional XML local name of the element to which attributes are
-     *              being added. When not null, this is used to filter overrides.
-     * @param info The {@link AttributeInfo} to append to attributes
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param required True if the attribute is to be marked as "required" (i.e. append
-     *        a "*" to its UI name as a hint for the user.)
-     * @param overrides A map [attribute name => TextAttributeDescriptor creator]. A creator
-     *        can either by a Class<? extends TextAttributeDescriptor> or an instance of
-     *        {@link ITextAttributeCreator} that instantiates the right TextAttributeDescriptor.
-     */
-    public static void appendAttribute(ArrayList<AttributeDescriptor> attributes,
-            String elementXmlName,
-            String nsUri,
-            AttributeInfo info, boolean required,
-            Map<String, Object> overrides) {
-        AttributeDescriptor attr = null;
-
-        String xmlLocalName = info.getName();
-        String uiName = prettyAttributeUiName(info.getName()); // ui_name
-        if (required) {
-            uiName += "*"; //$NON-NLS-1$
-        }
-        
-        String tooltip = null;
-        String rawTooltip = info.getJavaDoc();
-        if (rawTooltip == null) {
-            rawTooltip = "";
-        }
-        
-        String deprecated = info.getDeprecatedDoc();
-        if (deprecated != null) {
-            if (rawTooltip.length() > 0) {
-                rawTooltip += "@@"; //$NON-NLS-1$ insert a break
-            }
-            rawTooltip += "* Deprecated";
-            if (deprecated.length() != 0) {
-                rawTooltip += ": " + deprecated;                            //$NON-NLS-1$
-            }
-            if (deprecated.length() == 0 || !deprecated.endsWith(".")) {    //$NON-NLS-1$
-                rawTooltip += ".";                                          //$NON-NLS-1$
-            }
-        }
-
-        // Add the known types to the tooltip
-        Format[] formats_list = info.getFormats();
-        int flen = formats_list.length;
-        if (flen > 0) {
-            // Fill the formats in a set for faster access
-            HashSet<Format> formats_set = new HashSet<Format>();
-            
-            StringBuilder sb = new StringBuilder();
-            if (rawTooltip != null && rawTooltip.length() > 0) {
-                sb.append(rawTooltip);
-                sb.append(" ");     //$NON-NLS-1$
-            }
-            if (sb.length() > 0) {
-                sb.append("@@");    //$NON-NLS-1$  @@ inserts a break before the types
-            }
-            sb.append("[");         //$NON-NLS-1$
-            for (int i = 0; i < flen; i++) {
-                Format f = formats_list[i];
-                formats_set.add(f);
-
-                sb.append(f.toString().toLowerCase());
-                if (i < flen - 1) {
-                    sb.append(", "); //$NON-NLS-1$
-                }
-            }
-            // The extra space at the end makes the tooltip more readable on Windows.
-            sb.append("]"); //$NON-NLS-1$
-
-            if (required) {
-                sb.append(".@@* ");          //$NON-NLS-1$ @@ inserts a break.
-                sb.append("Required.");
-            }
-
-            // The extra space at the end makes the tooltip more readable on Windows.
-            sb.append(" "); //$NON-NLS-1$
-
-            rawTooltip = sb.toString();
-            tooltip = formatTooltip(rawTooltip);
-
-            // Create a specialized attribute if we can
-            if (overrides != null) {
-                for (Entry<String, Object> entry: overrides.entrySet()) {
-                    String key = entry.getKey();
-                    String elements[] = key.split("/");          //$NON-NLS-1$
-                    String overrideAttrLocalName = null;
-                    if (elements.length < 1) {
-                        continue;
-                    } else if (elements.length == 1) {
-                        overrideAttrLocalName = elements[0];
-                        elements = null;
-                    } else {
-                        overrideAttrLocalName = elements[elements.length - 1];
-                        elements = elements[0].split(",");       //$NON-NLS-1$
-                    }
-                    
-                    if (overrideAttrLocalName == null ||
-                            !overrideAttrLocalName.equals(xmlLocalName)) {
-                        continue;
-                    }
-
-                    boolean ok_element = elements.length < 1;
-                    if (!ok_element) {
-                        for (String element : elements) {
-                            if (element.equals("*")              //$NON-NLS-1$
-                                    || element.equals(elementXmlName)) {
-                                ok_element = true;
-                                break;
-                            }
-                        }
-                    }
-                    
-                    if (!ok_element) {
-                        continue;
-                    }
-
-                    Object override = entry.getValue();
-                    if (override instanceof Class) {
-                        try {
-                            // The override is instance of the class to create, which must
-                            // have a constructor compatible with TextAttributeDescriptor.
-                            @SuppressWarnings("unchecked") //$NON-NLS-1$
-                            Class<? extends TextAttributeDescriptor> clazz = 
-                                (Class<? extends TextAttributeDescriptor>) override;
-                            Constructor<? extends TextAttributeDescriptor> cons;
-                                cons = clazz.getConstructor(new Class<?>[] {
-                                        String.class, String.class, String.class, String.class } );
-                            attr = cons.newInstance(
-                                    new Object[] { xmlLocalName, uiName, nsUri, tooltip });
-                        } catch (SecurityException e) {
-                            // ignore
-                        } catch (NoSuchMethodException e) {
-                            // ignore
-                        } catch (IllegalArgumentException e) {
-                            // ignore
-                        } catch (InstantiationException e) {
-                            // ignore
-                        } catch (IllegalAccessException e) {
-                            // ignore
-                        } catch (InvocationTargetException e) {
-                            // ignore
-                        }
-                    } else if (override instanceof ITextAttributeCreator) {
-                        attr = ((ITextAttributeCreator) override).create(
-                                xmlLocalName, uiName, nsUri, tooltip);
-                    }
-                }
-            } // if overrides
-
-            // Create a specialized descriptor if we can, based on type
-            if (attr == null) {
-                if (formats_set.contains(Format.REFERENCE)) {
-                    // This is either a multi-type reference or a generic reference.
-                    attr = new ReferenceAttributeDescriptor(xmlLocalName, uiName, nsUri, tooltip);
-                } else if (formats_set.contains(Format.ENUM)) {
-                    attr = new ListAttributeDescriptor(xmlLocalName, uiName, nsUri, tooltip,
-                            info.getEnumValues());
-                } else if (formats_set.contains(Format.FLAG)) {
-                    attr = new FlagAttributeDescriptor(xmlLocalName, uiName, nsUri, tooltip,
-                            info.getFlagValues());
-                } else if (formats_set.contains(Format.BOOLEAN)) {
-                    attr = new BooleanAttributeDescriptor(xmlLocalName, uiName, nsUri, tooltip);
-                } else if (formats_set.contains(Format.STRING)) {
-                    attr = new ReferenceAttributeDescriptor(ResourceType.STRING,
-                            xmlLocalName, uiName, nsUri,
-                            tooltip);
-                }
-            }
-        }
-
-        // By default a simple text field is used
-        if (attr == null) {
-            if (tooltip == null) {
-                tooltip = formatTooltip(rawTooltip);
-            }
-            attr = new TextAttributeDescriptor(xmlLocalName, uiName, nsUri, tooltip);
-        }
-        attr.setDeprecated(info.getDeprecatedDoc() != null);
-        attributes.add(attr);
-    }
-
-    /**
-     * Indicates the the given {@link AttributeInfo} already exists in the ArrayList of
-     * {@link AttributeDescriptor}. This test for the presence of a descriptor with the same
-     * XML name.
-     * 
-     * @param attributes The list of {@link AttributeDescriptor} to compare to.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link AndroidConstants#NS_RESOURCES} for a common value.
-     * @param info The {@link AttributeInfo} to know whether it is included in the above list.
-     * @return True if this {@link AttributeInfo} is already present in
-     *         the {@link AttributeDescriptor} list.
-     */
-    public static boolean containsAttribute(ArrayList<AttributeDescriptor> attributes,
-            String nsUri,
-            AttributeInfo info) {
-        String xmlLocalName = info.getName();
-        for (AttributeDescriptor desc : attributes) {
-            if (desc.getXmlLocalName().equals(xmlLocalName)) {
-                if (nsUri == desc.getNamespaceUri() ||
-                        (nsUri != null && nsUri.equals(desc.getNamespaceUri()))) {
-                    return true;
-                }
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Create a pretty attribute UI name from an XML name.
-     * <p/>
-     * The original xml name starts with a lower case and is camel-case,
-     * e.g. "maxWidthForView". The pretty name starts with an upper case
-     * and has space separators, e.g. "Max width for view".
-     */
-    public static String prettyAttributeUiName(String name) {
-        if (name.length() < 1) {
-            return name;
-        }
-        StringBuffer buf = new StringBuffer();
-
-        char c = name.charAt(0);
-        // Use upper case initial letter
-        buf.append((char)(c >= 'a' && c <= 'z' ? c + 'A' - 'a' : c));
-        int len = name.length();
-        for (int i = 1; i < len; i++) {
-            c = name.charAt(i);
-            if (c >= 'A' && c <= 'Z') {
-                // Break camel case into separate words
-                buf.append(' ');
-                // Use a lower case initial letter for the next word, except if the
-                // word is solely X, Y or Z.
-                if (c >= 'X' && c <= 'Z' &&
-                        (i == len-1 ||
-                            (i < len-1 && name.charAt(i+1) >= 'A' && name.charAt(i+1) <= 'Z'))) {
-                    buf.append(c);
-                } else {
-                    buf.append((char)(c - 'A' + 'a'));
-                }
-            } else if (c == '_') {
-                buf.append(' ');
-            } else {
-                buf.append(c);
-            }
-        }
-        
-        name = buf.toString();
-        
-        // Replace these acronyms by upper-case versions
-        // - (?<=^| ) means "if preceded by a space or beginning of string"
-        // - (?=$| )  means "if followed by a space or end of string"
-        name = name.replaceAll("(?<=^| )sdk(?=$| )", "SDK");
-        name = name.replaceAll("(?<=^| )uri(?=$| )", "URI");
-
-        return name;
-    }
-    
-    /**
-     * Capitalizes the string, i.e. transforms the initial [a-z] into [A-Z].
-     * Returns the string unmodified if the first character is not [a-z].
-     * 
-     * @param str The string to capitalize.
-     * @return The capitalized string
-     */
-    public static String capitalize(String str) {
-        if (str == null || str.length() < 1 || str.charAt(0) < 'a' || str.charAt(0) > 'z') {
-            return str;
-        }
-        
-        StringBuilder sb = new StringBuilder();
-        sb.append((char)(str.charAt(0) + 'A' - 'a'));
-        sb.append(str.substring(1));
-        return sb.toString();
-    }
-
-    /**
-     * Formats the javadoc tooltip to be usable in a tooltip.
-     */
-    public static String formatTooltip(String javadoc) {
-        ArrayList<String> spans = scanJavadoc(javadoc);
-        
-        StringBuilder sb = new StringBuilder();
-        boolean needBreak = false;
-
-        for (int n = spans.size(), i = 0; i < n; ++i) {
-            String s = spans.get(i);
-            if (CODE.equals(s)) {
-                s = spans.get(++i);
-                if (s != null) {
-                    sb.append('"').append(s).append('"');
-                }
-            } else if (LINK.equals(s)) {
-                String base   = spans.get(++i);
-                String anchor = spans.get(++i);
-                String text   = spans.get(++i);
-
-                if (base != null) {
-                    base = base.trim();
-                }
-                if (anchor != null) {
-                    anchor = anchor.trim();
-                }
-                if (text != null) {
-                    text = text.trim();
-                }
-                
-                // If there's no text, use the anchor if there's one
-                if (text == null || text.length() == 0) {
-                    text = anchor;
-                }
-
-                if (base != null && base.length() > 0) {
-                    if (text == null || text.length() == 0) {
-                        // If we still have no text, use the base as text
-                        text = base;
-                    }
-                } 
-
-                if (text != null) {
-                    sb.append(text);
-                }
-                
-            } else if (ELEM.equals(s)) {
-                s = spans.get(++i);
-                if (s != null) {
-                    sb.append(s);
-                }
-            } else if (BREAK.equals(s)) {
-                needBreak = true;
-            } else if (s != null) {
-                if (needBreak && s.trim().length() > 0) {
-                    sb.append('\r');
-                }
-                sb.append(s);
-                needBreak = false;
-            }
-        }
-        
-        return sb.toString();
-    }
-    
-    /**
-     * Formats the javadoc tooltip to be usable in a FormText.
-     * <p/>
-     * If the descriptor can provide an icon, the caller should provide
-     * elementsDescriptor.getIcon() as "image" to FormText, e.g.:
-     * <code>formText.setImage(IMAGE_KEY, elementsDescriptor.getIcon());</code>
-     * 
-     * @param javadoc The javadoc to format. Cannot be null.
-     * @param elementDescriptor The element descriptor parent of the javadoc. Cannot be null.
-     * @param androidDocBaseUrl The base URL for the documentation. Cannot be null. Should be
-     *   <code>FrameworkResourceManager.getInstance().getDocumentationBaseUrl()</code>
-     */
-    public static String formatFormText(String javadoc,
-            ElementDescriptor elementDescriptor,
-            String androidDocBaseUrl) {
-        ArrayList<String> spans = scanJavadoc(javadoc);
-
-        String fullSdkUrl = androidDocBaseUrl + MANIFEST_SDK_URL;
-        String sdkUrl = elementDescriptor.getSdkUrl();
-        if (sdkUrl != null && sdkUrl.startsWith(MANIFEST_SDK_URL)) {
-            fullSdkUrl = androidDocBaseUrl + sdkUrl;
-        }
-        
-        StringBuilder sb = new StringBuilder();
-        
-        Image icon = elementDescriptor.getIcon();
-        if (icon != null) {
-            sb.append("<form><li style=\"image\" value=\"" +        //$NON-NLS-1$
-                    IMAGE_KEY + "\">");                             //$NON-NLS-1$
-        } else {
-            sb.append("<form><p>");                                 //$NON-NLS-1$
-        }
-
-        for (int n = spans.size(), i = 0; i < n; ++i) {
-            String s = spans.get(i);
-            if (CODE.equals(s)) {
-                s = spans.get(++i);
-                if (elementDescriptor.getXmlName().equals(s) && fullSdkUrl != null) {
-                    sb.append("<a href=\"");                        //$NON-NLS-1$
-                    sb.append(fullSdkUrl);
-                    sb.append("\">");                               //$NON-NLS-1$
-                    sb.append(s);
-                    sb.append("</a>");                              //$NON-NLS-1$
-                } else if (s != null) {
-                    sb.append('"').append(s).append('"');
-                }
-            } else if (LINK.equals(s)) {
-                String base   = spans.get(++i);
-                String anchor = spans.get(++i);
-                String text   = spans.get(++i);
-                
-                if (base != null) {
-                    base = base.trim();
-                }
-                if (anchor != null) {
-                    anchor = anchor.trim();
-                }
-                if (text != null) {
-                    text = text.trim();
-                }
-                
-                // If there's no text, use the anchor if there's one
-                if (text == null || text.length() == 0) {
-                    text = anchor;
-                }
-
-                // TODO specialize with a base URL for views, menus & other resources
-                // Base is empty for a local page anchor, in which case we'll replace it
-                // by the element SDK URL if it exists.
-                if ((base == null || base.length() == 0) && fullSdkUrl != null) {
-                    base = fullSdkUrl;
-                }
-
-                String url = null;
-                if (base != null && base.length() > 0) {
-                    if (base.startsWith("http")) {                  //$NON-NLS-1$
-                        // If base looks an URL, use it, with the optional anchor
-                        url = base;
-                        if (anchor != null && anchor.length() > 0) {
-                            // If the base URL already has an anchor, it needs to be
-                            // removed first. If there's no anchor, we need to add "#"
-                            int pos = url.lastIndexOf('#');
-                            if (pos < 0) {
-                                url += "#";                         //$NON-NLS-1$
-                            } else if (pos < url.length() - 1) {
-                                url = url.substring(0, pos + 1);
-                            }
-
-                            url += anchor;
-                        }
-                    } else if (text == null || text.length() == 0) {
-                        // If we still have no text, use the base as text
-                        text = base;
-                    }
-                } 
-
-                if (url != null && text != null) {
-                    sb.append("<a href=\"");                        //$NON-NLS-1$
-                    sb.append(url);
-                    sb.append("\">");                               //$NON-NLS-1$
-                    sb.append(text);
-                    sb.append("</a>");                              //$NON-NLS-1$
-                } else if (text != null) {
-                    sb.append("<b>").append(text).append("</b>");   //$NON-NLS-1$ //$NON-NLS-2$
-                }
-
-            } else if (ELEM.equals(s)) {
-                s = spans.get(++i);
-                if (sdkUrl != null && s != null) {
-                    sb.append("<a href=\"");                        //$NON-NLS-1$
-                    sb.append(sdkUrl);
-                    sb.append("\">");                               //$NON-NLS-1$
-                    sb.append(s);
-                    sb.append("</a>");                              //$NON-NLS-1$
-                } else if (s != null) {
-                    sb.append("<b>").append(s).append("</b>");      //$NON-NLS-1$ //$NON-NLS-2$
-                }
-            } else if (BREAK.equals(s)) {
-                // ignore line breaks in pseudo-HTML rendering
-            } else if (s != null) {
-                sb.append(s);
-            }
-        }
-
-        if (icon != null) {
-            sb.append("</li></form>");                              //$NON-NLS-1$
-        } else {
-            sb.append("</p></form>");                               //$NON-NLS-1$
-        }
-        return sb.toString();
-    }
-
-    private static ArrayList<String> scanJavadoc(String javadoc) {
-        ArrayList<String> spans = new ArrayList<String>();
-        
-        // Standardize all whitespace in the javadoc to single spaces.
-        if (javadoc != null) {
-            javadoc = javadoc.replaceAll("[ \t\f\r\n]+", " "); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-        
-        // Detects {@link <base>#<name> <text>} where all 3 are optional
-        Pattern p_link = Pattern.compile("\\{@link\\s+([^#\\}\\s]*)(?:#([^\\s\\}]*))?(?:\\s*([^\\}]*))?\\}(.*)"); //$NON-NLS-1$
-        // Detects <code>blah</code> 
-        Pattern p_code = Pattern.compile("<code>(.+?)</code>(.*)");                 //$NON-NLS-1$
-        // Detects @blah@, used in hard-coded tooltip descriptors
-        Pattern p_elem = Pattern.compile("@([\\w -]+)@(.*)");                       //$NON-NLS-1$
-        // Detects a buffer that starts by @@ (request for a break)
-        Pattern p_break = Pattern.compile("@@(.*)");                                //$NON-NLS-1$
-        // Detects a buffer that starts by @ < or { (one that was not matched above)
-        Pattern p_open = Pattern.compile("([@<\\{])(.*)");                          //$NON-NLS-1$
-        // Detects everything till the next potential separator, i.e. @ < or {
-        Pattern p_text = Pattern.compile("([^@<\\{]+)(.*)");                        //$NON-NLS-1$
-
-        int currentLength = 0;
-        String text = null;
-        
-        while(javadoc != null && javadoc.length() > 0) {
-            Matcher m;
-            String s = null;
-            if ((m = p_code.matcher(javadoc)).matches()) {
-                spans.add(CODE);
-                spans.add(text = cleanupJavadocHtml(m.group(1))); // <code> text
-                javadoc = m.group(2);
-                if (text != null) {
-                    currentLength += text.length();
-                }
-            } else if ((m = p_link.matcher(javadoc)).matches()) {
-                spans.add(LINK);
-                spans.add(m.group(1)); // @link base
-                spans.add(m.group(2)); // @link anchor
-                spans.add(text = cleanupJavadocHtml(m.group(3))); // @link text
-                javadoc = m.group(4);
-                if (text != null) {
-                    currentLength += text.length();
-                }
-            } else if ((m = p_elem.matcher(javadoc)).matches()) {
-                spans.add(ELEM);
-                spans.add(text = cleanupJavadocHtml(m.group(1))); // @text@
-                javadoc = m.group(2);
-                if (text != null) {
-                    currentLength += text.length() - 2;
-                }
-            } else if ((m = p_break.matcher(javadoc)).matches()) {
-                spans.add(BREAK);
-                currentLength = 0;
-                javadoc = m.group(1);
-            } else if ((m = p_open.matcher(javadoc)).matches()) {
-                s = m.group(1);
-                javadoc = m.group(2);
-            } else if ((m = p_text.matcher(javadoc)).matches()) {
-                s = m.group(1);
-                javadoc = m.group(2);
-            } else {
-                // This is not supposed to happen. In case of, just use everything.
-                s = javadoc;
-                javadoc = null;
-            }
-            if (s != null && s.length() > 0) {
-                s = cleanupJavadocHtml(s);
-                
-                if (currentLength >= JAVADOC_BREAK_LENGTH) {
-                    spans.add(BREAK);
-                    currentLength = 0;
-                }
-                while (currentLength + s.length() > JAVADOC_BREAK_LENGTH) {
-                    int pos = s.indexOf(' ', JAVADOC_BREAK_LENGTH - currentLength);
-                    if (pos <= 0) {
-                        break;
-                    }
-                    spans.add(s.substring(0, pos + 1));
-                    spans.add(BREAK);
-                    currentLength = 0;
-                    s = s.substring(pos + 1);
-                }
-                
-                spans.add(s);
-                currentLength += s.length();
-            }
-        }
-        
-        return spans;
-    }
-
-    /**
-     * Remove anything that looks like HTML from a javadoc snippet, as it is supported
-     * neither by FormText nor a standard text tooltip.
-     */
-    private static String cleanupJavadocHtml(String s) {
-        if (s != null) {
-            s = s.replaceAll("&lt;", "\"");     //$NON-NLS-1$ $NON-NLS-2$
-            s = s.replaceAll("&gt;", "\"");     //$NON-NLS-1$ $NON-NLS-2$
-            s = s.replaceAll("<[^>]+>", "");    //$NON-NLS-1$ $NON-NLS-2$
-        }
-        return s;
-    }
-
-    /**
-     * Sets the default layout attributes for the a new UiElementNode.
-     * <p/>
-     * Note that ideally the node should already be part of a hierarchy so that its
-     * parent layout and previous sibling can be determined, if any.
-     * <p/>
-     * This does not override attributes which are not empty.
-     */
-    public static void setDefaultLayoutAttributes(UiElementNode ui_node, boolean updateLayout) {
-        // if this ui_node is a layout and we're adding it to a document, use fill_parent for
-        // both W/H. Otherwise default to wrap_layout.
-        boolean fill = ui_node.getDescriptor().hasChildren() &&
-                       ui_node.getUiParent() instanceof UiDocumentNode;
-        ui_node.setAttributeValue(LayoutConstants.ATTR_LAYOUT_WIDTH,
-                fill ? LayoutConstants.VALUE_FILL_PARENT : LayoutConstants.VALUE_WRAP_CONTENT,
-                false /* override */);
-        ui_node.setAttributeValue(LayoutConstants.ATTR_LAYOUT_HEIGHT,
-                fill ? LayoutConstants.VALUE_FILL_PARENT : LayoutConstants.VALUE_WRAP_CONTENT,
-                false /* override */);
-
-        String widget_id = getFreeWidgetId(ui_node.getUiRoot(),
-                new Object[] { ui_node.getDescriptor().getXmlLocalName(), null, null, null });
-        if (widget_id != null) {
-            ui_node.setAttributeValue(LayoutConstants.ATTR_ID, "@+id/" + widget_id, //$NON-NLS-1$
-                    false /* override */);
-        }
-
-        ui_node.setAttributeValue(LayoutConstants.ATTR_TEXT, widget_id, false /*override*/);
-        
-        if (updateLayout) {
-            UiElementNode ui_parent = ui_node.getUiParent();
-            if (ui_parent != null &&
-                    ui_parent.getDescriptor().getXmlLocalName().equals(
-                            LayoutConstants.RELATIVE_LAYOUT)) {
-                UiElementNode ui_previous = ui_node.getUiPreviousSibling();
-                if (ui_previous != null) {
-                    String id = ui_previous.getAttributeValue(LayoutConstants.ATTR_ID);
-                    if (id != null && id.length() > 0) {
-                        id = id.replace("@+", "@");                     //$NON-NLS-1$ //$NON-NLS-2$
-                        ui_node.setAttributeValue(LayoutConstants.ATTR_LAYOUT_BELOW, id,
-                                false /* override */);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Given a UI root node, returns the first available id that matches the
-     * pattern "prefix%02d".
-     *  
-     * @param uiNode The UI node that gives the prefix to match.
-     * @return A suitable generated id
-     */
-    public static String getFreeWidgetId(UiElementNode uiNode) {
-        return getFreeWidgetId(uiNode.getUiRoot(),
-                new Object[] { uiNode.getDescriptor().getXmlLocalName(), null, null, null });
-    }
-
-    /**
-     * Given a UI root node, returns the first available id that matches the
-     * pattern "prefix%02d".
-     * 
-     * For recursion purposes, a "context" is given. Since Java doesn't have in-out parameters
-     * in methods and we're not going to do a dedicated type, we just use an object array which
-     * must contain one initial item and several are built on the fly just for internal storage:
-     * <ul>
-     * <li> prefix(String): The prefix of the generated id, i.e. "widget". Cannot be null.
-     * <li> index(Integer): The minimum index of the generated id. Must start with null.
-     * <li> generated(String): The generated widget currently being searched. Must start with null.
-     * <li> map(Set<String>): A set of the ids collected so far when walking through the widget
-     *                        hierarchy. Must start with null.
-     * </ul>
-     *  
-     * @param uiRoot The Ui root node where to start searching recursively. For the initial call
-     *               you want to pass the document root.
-     * @param params An in-out context of parameters used during recursion, as explained above.
-     * @return A suitable generated id
-     */
-    @SuppressWarnings("unchecked")
-    private static String getFreeWidgetId(UiElementNode uiRoot,
-            Object[] params) {
-
-        Set<String> map = (Set<String>)params[3];
-        if (map == null) {
-            params[3] = map = new HashSet<String>();
-        }
-
-        int num = params[1] == null ? 0 : ((Integer)params[1]).intValue();
-
-        String generated = (String) params[2];
-        String prefix = (String) params[0];
-        if (generated == null) {
-            int pos = prefix.indexOf('.');
-            if (pos >= 0) {
-                prefix = prefix.substring(pos + 1);
-            }
-            pos = prefix.indexOf('$');
-            if (pos >= 0) {
-                prefix = prefix.substring(pos + 1);
-            }
-            prefix = prefix.replaceAll("[^a-zA-Z]", "");                //$NON-NLS-1$ $NON-NLS-2$
-            if (prefix.length() == 0) {
-                prefix = DEFAULT_WIDGET_PREFIX;
-            }
-
-            do {
-                num++;
-                generated = String.format("%1$s%2$02d", prefix, num);   //$NON-NLS-1$
-            } while (map.contains(generated));
-
-            params[0] = prefix;
-            params[1] = num;
-            params[2] = generated;
-        }
-
-        String id = uiRoot.getAttributeValue(LayoutConstants.ATTR_ID);
-        if (id != null) {
-            id = id.replace("@+id/", "");                               //$NON-NLS-1$ $NON-NLS-2$
-            id = id.replace("@id/", "");                                //$NON-NLS-1$ $NON-NLS-2$
-            if (map.add(id) && map.contains(generated)) {
-
-                do {
-                    num++;
-                    generated = String.format("%1$s%2$02d", prefix, num);   //$NON-NLS-1$
-                } while (map.contains(generated));
-
-                params[1] = num;
-                params[2] = generated;
-            }
-        }
-
-        for (UiElementNode uiChild : uiRoot.getUiChildren()) {
-            getFreeWidgetId(uiChild, params);
-        }
-        
-        // Note: return params[2] (not "generated") since it could have changed during recursion.
-        return (String) params[2];
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DocumentDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DocumentDescriptor.java
deleted file mode 100644
index 7d296f7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/DocumentDescriptor.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * {@link DocumentDescriptor} describes the properties expected for an XML document node.
- * 
- * Compared to ElementDescriptor, {@link DocumentDescriptor} does not have XML name nor UI name,
- * tooltip, SDK url and attributes list.
- * <p/>
- * It has a children list which represent all the possible roots of the document.
- * <p/>
- * The document nodes are "mandatory", meaning the UI node is never deleted and it may lack
- * an actual XML node attached.
- */
-public class DocumentDescriptor extends ElementDescriptor {
-
-    /**
-     * Constructs a new {@link DocumentDescriptor} based on its XML name and children list.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * <p/>
-     * The XML name is never shown in the UI directly. It is however used when an icon
-     * needs to be found for the node.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param children The list of allowed children. Can be null or empty.
-     */
-    public DocumentDescriptor(String xml_name, ElementDescriptor[] children) {
-        super(xml_name, children, true /* mandatory */);
-    }
-
-    /**
-     * @return A new {@link UiElementNode} linked to this descriptor.
-     */
-    @Override
-    public UiElementNode createUiNode() {
-        return new UiDocumentNode(this);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ElementDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ElementDescriptor.java
deleted file mode 100644
index 5550155..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ElementDescriptor.java
+++ /dev/null
@@ -1,318 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.swt.graphics.Image;
-
-import java.util.HashSet;
-import java.util.Set;
-
-/**
- * {@link ElementDescriptor} describes the properties expected for a given XML element node.
- * 
- * {@link ElementDescriptor} have an XML name, UI name, a tooltip, an SDK url,
- * an attributes list and a children list.
- * 
- * An UI node can be "mandatory", meaning the UI node is never deleted and it may lack
- * an actual XML node attached. A non-mandatory UI node MUST have an XML node attached
- * and it will cease to exist when the XML node ceases to exist.
- */
-public class ElementDescriptor {
-    /** The XML element node name. Case sensitive. */
-    private String mXmlName;
-    /** The XML element name for the user interface, typically capitalized. */
-    private String mUiName;
-    /** The list of allowed attributes. */
-    private AttributeDescriptor[] mAttributes;
-    /** The list of allowed children */
-    private ElementDescriptor[] mChildren;
-    /* An optional tooltip. Can be empty. */
-    private String mTooltip;
-    /** An optional SKD URL. Can be empty. */
-    private String mSdkUrl;
-    /** Whether this UI node must always exist (even for empty models). */
-    private boolean mMandatory;
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name, UI name,
-     * tooltip, SDK url, attributes list, children list and mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param ui_name The XML element name for the user interface, typically capitalized.
-     * @param tooltip An optional tooltip. Can be null or empty.
-     * @param sdk_url An optional SKD URL. Can be null or empty.
-     * @param attributes The list of allowed attributes. Can be null or empty.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models). A mandatory
-     *  UI node is never deleted and it may lack an actual XML node attached. A non-mandatory
-     *  UI node MUST have an XML node attached and it will cease to exist when the XML node
-     *  ceases to exist.
-     */
-    public ElementDescriptor(String xml_name, String ui_name, String tooltip, String sdk_url,
-            AttributeDescriptor[] attributes,
-            ElementDescriptor[] children,
-            boolean mandatory) {
-        mMandatory = mandatory;
-        mXmlName = xml_name;
-        mUiName = ui_name;
-        mTooltip = (tooltip != null && tooltip.length() > 0) ? tooltip : null;
-        mSdkUrl = (sdk_url != null && sdk_url.length() > 0) ? sdk_url : null;
-        setAttributes(attributes != null ? attributes : new AttributeDescriptor[]{});
-        mChildren = children != null ? children : new ElementDescriptor[]{};
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name and children list.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models). A mandatory
-     *  UI node is never deleted and it may lack an actual XML node attached. A non-mandatory
-     *  UI node MUST have an XML node attached and it will cease to exist when the XML node
-     *  ceases to exist.
-     */
-    public ElementDescriptor(String xml_name, ElementDescriptor[] children, boolean mandatory) {
-        this(xml_name, prettyName(xml_name), null, null, null, children, mandatory);
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name and children list.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param children The list of allowed children. Can be null or empty.
-     */
-    public ElementDescriptor(String xml_name, ElementDescriptor[] children) {
-        this(xml_name, prettyName(xml_name), null, null, null, children, false);
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     */
-    public ElementDescriptor(String xml_name) {
-        this(xml_name, prettyName(xml_name), null, null, null, null, false);
-    }
-
-    /** Returns whether this node must always exist (even for empty models) */
-    public boolean isMandatory() {
-        return mMandatory;
-    }
-    
-    /**
-     * Returns the XML element node local name (case sensitive)
-     */
-    public final String getXmlLocalName() {
-        int pos = mXmlName.indexOf(':'); 
-        if (pos != -1) {
-            return mXmlName.substring(pos+1);
-        }
-        return mXmlName;
-    }
-
-    /** Returns the XML element node name. Case sensitive. */
-    public String getXmlName() {
-        return mXmlName;
-    }
-    
-    /**
-     * Returns the namespace of the attribute.
-     */
-    public final String getNamespace() {
-        // For now we hard-code the prefix as being "android"
-        if (mXmlName.startsWith("android:")) { //$NON-NLs-1$
-            return SdkConstants.NS_RESOURCES;
-        }
-        
-        return ""; //$NON-NLs-1$
-    }
-
-
-    /** Returns the XML element name for the user interface, typically capitalized. */
-    public String getUiName() {
-        return mUiName;
-    }
-
-    /** 
-     * Returns an optional icon for the element.
-     * <p/>
-     * By default this tries to return an icon based on the XML name of the element.
-     * If this fails, it tries to return the default Android logo as defined in the
-     * plugin. If all fails, it returns null.
-     * 
-     * @return An icon for this element or null.
-     */
-    public Image getIcon() {
-        IconFactory factory = IconFactory.getInstance();
-        int color = hasChildren() ? IconFactory.COLOR_BLUE : IconFactory.COLOR_GREEN;
-        int shape = hasChildren() ? IconFactory.SHAPE_RECT : IconFactory.SHAPE_CIRCLE;
-        Image icon = factory.getIcon(mXmlName, color, shape);
-        return icon != null ? icon : AdtPlugin.getAndroidLogo();
-    }
-
-    /** 
-     * Returns an optional ImageDescriptor for the element.
-     * <p/>
-     * By default this tries to return an image based on the XML name of the element.
-     * If this fails, it tries to return the default Android logo as defined in the
-     * plugin. If all fails, it returns null.
-     * 
-     * @return An ImageDescriptor for this element or null.
-     */
-    public ImageDescriptor getImageDescriptor() {
-        IconFactory factory = IconFactory.getInstance();
-        int color = hasChildren() ? IconFactory.COLOR_BLUE : IconFactory.COLOR_GREEN;
-        int shape = hasChildren() ? IconFactory.SHAPE_RECT : IconFactory.SHAPE_CIRCLE;
-        ImageDescriptor id = factory.getImageDescriptor(mXmlName, color, shape);
-        return id != null ? id : AdtPlugin.getAndroidLogoDesc();
-    }
-
-    /* Returns the list of allowed attributes. */
-    public AttributeDescriptor[] getAttributes() {
-        return mAttributes;
-    }
-    
-    /* Sets the list of allowed attributes. */
-    public void setAttributes(AttributeDescriptor[] attributes) {
-        mAttributes = attributes;
-        for (AttributeDescriptor attribute : attributes) {
-            attribute.setParent(this);
-        }
-    }
-
-    /** Returns the list of allowed children */
-    public ElementDescriptor[] getChildren() {
-        return mChildren;
-    }
-
-    /** @return True if this descriptor has children available */
-    public boolean hasChildren() {
-        return mChildren.length > 0;
-    }
-
-    /** Sets the list of allowed children. */
-    public void setChildren(ElementDescriptor[] newChildren) {
-        mChildren = newChildren;
-    }
-
-    /**
-     * Returns an optional tooltip. Will be null if not present.
-     * <p/>
-     * The tooltip is based on the Javadoc of the element and already processed via
-     * {@link DescriptorsUtils#formatTooltip(String)} to be displayed right away as
-     * a UI tooltip.
-     */
-    public String getTooltip() {
-        return mTooltip;
-    }
-
-    /** Returns an optional SKD URL. Will be null if not present. */
-    public String getSdkUrl() {
-        return mSdkUrl;
-    }
-
-    /** Sets the optional tooltip. Can be null or empty. */
-    public void setTooltip(String tooltip) {
-        mTooltip = tooltip;
-    }
-    
-    /** Sets the optional SDK URL. Can be null or empty. */
-    public void setSdkUrl(String sdkUrl) {
-        mSdkUrl = sdkUrl;
-    }
-
-    /**
-     * @return A new {@link UiElementNode} linked to this descriptor.
-     */
-    public UiElementNode createUiNode() {
-        return new UiElementNode(this);
-    }
-    
-    /**
-     * Returns the first children of this descriptor that describes the given XML element name. 
-     * <p/>
-     * In recursive mode, searches the direct children first before descending in the hierarchy.
-     * 
-     * @return The ElementDescriptor matching the requested XML node element name or null.
-     */
-    public ElementDescriptor findChildrenDescriptor(String element_name, boolean recursive) {
-        return findChildrenDescriptorInternal(element_name, recursive, null);
-    }
-
-    private ElementDescriptor findChildrenDescriptorInternal(String element_name,
-            boolean recursive,
-            Set<ElementDescriptor> visited) {
-        if (recursive && visited == null) {
-            visited = new HashSet<ElementDescriptor>();
-        }
-
-        for (ElementDescriptor e : getChildren()) {
-            if (e.getXmlName().equals(element_name)) {
-                return e;
-            }
-        }
-
-        if (visited != null) {
-            visited.add(this);
-        }
-
-        if (recursive) {
-            for (ElementDescriptor e : getChildren()) {
-                if (visited != null) {
-                    if (!visited.add(e)) {  // Set.add() returns false if element is already present
-                        continue;
-                    }
-                }
-                ElementDescriptor f = e.findChildrenDescriptorInternal(element_name,
-                        recursive, visited);
-                if (f != null) {
-                    return f;
-                }
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Utility helper than pretty-formats an XML Name for the UI.
-     * This is used by the simplified constructor that takes only an XML element name.
-     * 
-     * @param xml_name The XML name to convert.
-     * @return The XML name with dashes replaced by spaces and capitalized.
-     */
-    private static String prettyName(String xml_name) {
-        char c[] = xml_name.toCharArray();
-        if (c.length > 0) {
-            c[0] = Character.toUpperCase(c[0]);
-        }
-        return new String(c).replace("-", " ");  //$NON-NLS-1$  //$NON-NLS-2$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/EnumAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/EnumAttributeDescriptor.java
deleted file mode 100644
index cab9883..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/EnumAttributeDescriptor.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiListAttributeNode;
-
-/**
- * Describes a text attribute that can only contains some predefined values.
- * It is displayed by a {@link UiListAttributeNode}.
- */
-public class EnumAttributeDescriptor extends ListAttributeDescriptor {
-
-    public EnumAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiListAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiListAttributeNode(this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/FlagAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/FlagAttributeDescriptor.java
deleted file mode 100644
index 903417b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/FlagAttributeDescriptor.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.ui.FlagValueCellEditor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiFlagAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiListAttributeNode;
-
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Describes a text attribute that can only contains some predefined values.
- * It is displayed by a {@link UiListAttributeNode}.
- * 
- * Note: in Android resources, a "flag" is a list of fixed values where one or
- * more values can be selected using an "or", e.g. "align='left|top'".
- * By contrast, an "enum" is a list of fixed values of which only one can be
- * selected at a given time, e.g. "gravity='right'".
- * <p/>
- * This class handles the "flag" case.
- * The "enum" case is done using {@link ListAttributeDescriptor}.
- */
-public class FlagAttributeDescriptor extends TextAttributeDescriptor {
-
-    private String[] mNames;
-
-    /**
-     * Creates a new {@link FlagAttributeDescriptor} which automatically gets its
-     * values from the FrameworkResourceManager.
-     */
-    public FlagAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-
-    /**
-    * Creates a new {@link FlagAttributeDescriptor} which uses the provided values.
-    */
-    public FlagAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip, String[] names) {
-       super(xmlLocalName, uiName, nsUri, tooltip);
-       mNames = names;
-    }
-
-    /**
-     * @return The initial names of the flags. Can be null, in which case the Framework
-     *         resource parser should be checked.
-     */
-    public String[] getNames() {
-        return mNames;
-    }
-    
-    /**
-     * @return A new {@link UiListAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiFlagAttributeNode(this, uiParent);
-    }
-    
-    // ------- IPropertyDescriptor Methods
-
-    @Override
-    public CellEditor createPropertyEditor(Composite parent) {
-        return new FlagValueCellEditor(parent);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/IDescriptorProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/IDescriptorProvider.java
deleted file mode 100644
index 4c115e9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/IDescriptorProvider.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-public interface IDescriptorProvider {
-
-    ElementDescriptor[] getRootElementDescriptors();
-    
-    ElementDescriptor getDescriptor();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ListAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ListAttributeDescriptor.java
deleted file mode 100644
index 93969e9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ListAttributeDescriptor.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.ui.ListValueCellEditor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiListAttributeNode;
-
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Describes a text attribute that can contains some predefined values.
- * It is displayed by a {@link UiListAttributeNode}.
- */
-public class ListAttributeDescriptor extends TextAttributeDescriptor {
-
-    private String[] mValues = null;
-    
-    /**
-     * Creates a new {@link ListAttributeDescriptor} which automatically gets its
-     * values from the FrameworkResourceManager.
-     */
-    public ListAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-
-     /**
-     * Creates a new {@link ListAttributeDescriptor} which uses the provided values.
-     */
-    public ListAttributeDescriptor(String xmlLocalName, String uiName, String nsUri, 
-            String tooltip, String[] values) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-        mValues = values;
-    }
-   
-    public String[] getValues() {
-        return mValues;
-    }
-
-    /**
-     * @return A new {@link UiListAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiListAttributeNode(this, uiParent);
-    }
-    
-    // ------- IPropertyDescriptor Methods
-
-    @Override
-    public CellEditor createPropertyEditor(Composite parent) {
-        return new ListValueCellEditor(parent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ReferenceAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ReferenceAttributeDescriptor.java
deleted file mode 100644
index 336dfe2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/ReferenceAttributeDescriptor.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.ui.ResourceValueCellEditor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiResourceAttributeNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Describes an XML attribute displayed containing a value or a reference to a resource.
- * It is displayed by a {@link UiResourceAttributeNode}.
- */
-public final class ReferenceAttributeDescriptor extends TextAttributeDescriptor {
-
-    private ResourceType mResourceType;
-    
-    /**
-     * Creates a reference attributes that can contain any type of resources.
-     * @param xmlLocalName The XML name of the attribute (case sensitive)
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param tooltip A non-empty tooltip string or null
-     */
-    public ReferenceAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * Creates a reference attributes that can contain a reference to a specific
-     * {@link ResourceType}.
-     * @param resourceType The specific {@link ResourceType} that this reference attribute supports.
-     * It can be <code>null</code>, in which case, all resource types are supported.
-     * @param xmlLocalName The XML name of the attribute (case sensitive)
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param tooltip A non-empty tooltip string or null
-     */
-    public ReferenceAttributeDescriptor(ResourceType resourceType, 
-            String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-        mResourceType = resourceType;
-    }
-    
-    
-    /**
-     * @return A new {@link UiResourceAttributeNode} linked to this reference descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiResourceAttributeNode(mResourceType, this, uiParent);
-    }
-    
-    // ------- IPropertyDescriptor Methods
-
-    @Override
-    public CellEditor createPropertyEditor(Composite parent) {
-        return new ResourceValueCellEditor(parent);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/SeparatorAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/SeparatorAttributeDescriptor.java
deleted file mode 100644
index 8fb1c7c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/SeparatorAttributeDescriptor.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiSeparatorAttributeNode;
-
-/**
- * {@link SeparatorAttributeDescriptor} does not represent any real attribute.
- * <p/>
- * It is used to separate groups of attributes visually.
- */
-public class SeparatorAttributeDescriptor extends AttributeDescriptor {
-    
-    /**
-     * Creates a new {@link SeparatorAttributeDescriptor}
-     */
-    public SeparatorAttributeDescriptor(String label) {
-        super(label /* xmlLocalName */, null /* nsUri */);
-    }
-
-    /**
-     * @return A new {@link UiAttributeNode} linked to this descriptor or null if this
-     *         attribute has no user interface.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiSeparatorAttributeNode(this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextAttributeDescriptor.java
deleted file mode 100644
index 77fc067..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextAttributeDescriptor.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.ui.TextValueCellEditor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiTextAttributeNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-
-/**
- * Describes a textual XML attribute.
- * <p/>
- * Such an attribute has a tooltip and would typically be displayed by
- * {@link UiTextAttributeNode} using a label widget and text field.
- * <p/>
- * This is the "default" kind of attribute. If in doubt, use this.
- */
-public class TextAttributeDescriptor extends AttributeDescriptor implements IPropertyDescriptor {
-    private String mUiName;
-    private String mTooltip;
-    
-    /**
-     * Creates a new {@link TextAttributeDescriptor}
-     * 
-     * @param xmlLocalName The XML name of the attribute (case sensitive)
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param tooltip A non-empty tooltip string or null
-     */
-    public TextAttributeDescriptor(String xmlLocalName, String uiName,
-            String nsUri, String tooltip) {
-        super(xmlLocalName, nsUri);
-        mUiName = uiName;
-        mTooltip = (tooltip != null && tooltip.length() > 0) ? tooltip : null;
-    }
-
-    /**
-     * @return The UI name of the attribute. Cannot be an empty string and cannot be null.
-     */
-    public final String getUiName() {
-        return mUiName;
-    }
-
-    /**
-     * The tooltip string is either null or a non-empty string.
-     * <p/>
-     * The tooltip is based on the Javadoc of the attribute and already processed via
-     * {@link DescriptorsUtils#formatTooltip(String)} to be displayed right away as
-     * a UI tooltip.
-     * <p/>
-     * An empty string is converted to null, to match the behavior of setToolTipText() in
-     * {@link Control}.
-     * 
-     * @return A non-empty tooltip string or null
-     */
-    public final String getTooltip() {
-        return mTooltip;
-    }
-    
-    /**
-     * @return A new {@link UiTextAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiTextAttributeNode(this, uiParent);
-    }
-    
-    // ------- IPropertyDescriptor Methods
-
-    public CellEditor createPropertyEditor(Composite parent) {
-        return new TextValueCellEditor(parent);
-    }
-
-    public String getCategory() {
-        if (isDeprecated()) {
-            return "Deprecated";
-        }
-
-        ElementDescriptor parent = getParent();
-        if (parent != null) {
-            return parent.getUiName();
-        }
-
-        return null;
-    }
-
-    public String getDescription() {
-        return mTooltip;
-    }
-
-    public String getDisplayName() {
-        return mUiName;
-    }
-
-    public String[] getFilterFlags() {
-        return null;
-    }
-
-    public Object getHelpContextIds() {
-        return null;
-    }
-
-    public Object getId() {
-        return this;
-    }
-
-    public ILabelProvider getLabelProvider() {
-        return AttributeDescriptorLabelProvider.getProvider();
-    }
-
-    public boolean isCompatibleWith(IPropertyDescriptor anotherProperty) {
-        return anotherProperty == this;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextValueDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextValueDescriptor.java
deleted file mode 100644
index 2015d71..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/TextValueDescriptor.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiTextValueNode;
-
-
-/**
- * Describes the value of an XML element.
- * <p/>
- * The value is a simple text string, displayed by an {@link UiTextValueNode}.
- */
-public class TextValueDescriptor extends TextAttributeDescriptor {
-    
-    /**
-     * Creates a new {@link TextValueDescriptor}
-     * 
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param tooltip A non-empty tooltip string or null
-     */
-    public TextValueDescriptor(String uiName, String tooltip) {
-        super("#text" /* xmlLocalName */, uiName, null /* nsUri */, tooltip);
-    }
-
-    /**
-     * @return A new {@link UiTextValueNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiTextValueNode(this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/XmlnsAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/XmlnsAttributeDescriptor.java
deleted file mode 100644
index ed9c897..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/descriptors/XmlnsAttributeDescriptor.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-
-/**
- * Describes an XMLNS attribute that is hidden.
- * <p/>
- * Such an attribute has no user interface and no corresponding {@link UiAttributeNode}.
- * It also has a single constant default value.
- * <p/>
- * When loading an XML, we'll ignore this attribute.
- * However when writing a new XML, we should always write this attribute.
- * <p/>
- * Currently this is used for the xmlns:android attribute in the manifest element.
- */
-public final class XmlnsAttributeDescriptor extends AttributeDescriptor {
-
-    /**
-     * URI of the reserved "xmlns"  prefix, as described in
-     * http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/namespaces-algorithms.html#normalizeDocumentAlgo
-     */
-    public final static String XMLNS_URI = "http://www.w3.org/2000/xmlns/"; //$NON-NLS-1$ 
-    
-    private String mValue;
-
-    
-    public XmlnsAttributeDescriptor(String defaultPrefix, String value) {
-        super(defaultPrefix, XMLNS_URI);
-        mValue = value;
-    }
-
-    /**
-     * Returns the value of this specialized attribute descriptor, which is the URI associated
-     * to the declared namespace prefix.
-     */
-    public String getValue() {
-        return mValue;
-    }
-
-    /**
-     * Returns the "xmlns" prefix that is always used by this node for its namespace URI.
-     * This is defined by the XML specification.
-     */
-    public String getXmlNsPrefix() {
-        return "xmlns"; //$NON-NLS-1$
-    }
-    
-    /**
-     * Returns the fully-qualified attribute name, namely "xmlns:xxx" where xxx is
-     * the defaultPrefix passed in the constructor.
-     */
-    public String getXmlNsName() {
-        return getXmlNsPrefix() + ":" + getXmlLocalName(); //$NON-NLS-1$
-    }
-    
-    /**
-     * @return Always returns null. {@link XmlnsAttributeDescriptor} has no user interface.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/BasePullParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/BasePullParser.java
deleted file mode 100644
index 381539b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/BasePullParser.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.layoutlib.api.IXmlPullParser;
-
-import org.xmlpull.v1.XmlPullParserException;
-
-import java.io.InputStream;
-import java.io.Reader;
-
-/**
- * Base implementation of an {@link IXmlPullParser} for cases where the parser is not sitting
- * on top of an actual XML file.
- * <p/>It's designed to work on layout files, and will most likely not work on other resource
- * files.
- */
-public abstract class BasePullParser implements IXmlPullParser {
-    
-    protected int mParsingState = START_DOCUMENT;
-    
-    public BasePullParser() {
-    }
-    
-    // --- new methods to override ---
-    
-    public abstract void onNextFromStartDocument();
-    public abstract void onNextFromStartTag();
-    public abstract void onNextFromEndTag();
-    
-    // --- basic implementation of IXmlPullParser ---
-    
-    public void setFeature(String name, boolean state) throws XmlPullParserException {
-        if (FEATURE_PROCESS_NAMESPACES.equals(name) && state) {
-            return;
-        }
-        if (FEATURE_REPORT_NAMESPACE_ATTRIBUTES.equals(name) && state) {
-            return;
-        }
-        throw new XmlPullParserException("Unsupported feature: " + name);
-    }
-
-    public boolean getFeature(String name) {
-        if (FEATURE_PROCESS_NAMESPACES.equals(name)) {
-            return true;
-        }
-        if (FEATURE_REPORT_NAMESPACE_ATTRIBUTES.equals(name)) {
-            return true;
-        }
-        return false;
-    }
-
-    public void setProperty(String name, Object value) throws XmlPullParserException {
-        throw new XmlPullParserException("setProperty() not supported");
-    }
-
-    public Object getProperty(String name) {
-        return null;
-    }
-
-    public void setInput(Reader in) throws XmlPullParserException {
-        throw new XmlPullParserException("setInput() not supported");
-    }
-
-    public void setInput(InputStream inputStream, String inputEncoding)
-            throws XmlPullParserException {
-        throw new XmlPullParserException("setInput() not supported");
-    }
-
-    public void defineEntityReplacementText(String entityName, String replacementText)
-            throws XmlPullParserException {
-        throw new XmlPullParserException("defineEntityReplacementText() not supported");
-    }
-
-    public String getNamespacePrefix(int pos) throws XmlPullParserException {
-        throw new XmlPullParserException("getNamespacePrefix() not supported");
-    }
-
-    public String getInputEncoding() {
-        return null;
-    }
-
-    public String getNamespace(String prefix) {
-        throw new RuntimeException("getNamespace() not supported");
-    }
-
-    public int getNamespaceCount(int depth) throws XmlPullParserException {
-        throw new XmlPullParserException("getNamespaceCount() not supported");
-    }
-
-    public String getNamespaceUri(int pos) throws XmlPullParserException {
-        throw new XmlPullParserException("getNamespaceUri() not supported");
-    }
-
-    public int getColumnNumber() {
-        return -1;
-    }
-
-    public int getLineNumber() {
-        return -1;
-    }
-
-    public String getAttributeType(int arg0) {
-        return "CDATA";
-    }
-
-    public int getEventType() {
-        return mParsingState;
-    }
-
-    public String getText() {
-        return null;
-    }
-
-    public char[] getTextCharacters(int[] arg0) {
-        return null;
-    }
-
-    public boolean isAttributeDefault(int arg0) {
-        return false;
-    }
-
-    public boolean isWhitespace() {
-        return false;
-    }
-    
-    public int next() throws XmlPullParserException {
-        switch (mParsingState) {
-            case END_DOCUMENT:
-                throw new XmlPullParserException("Nothing after the end");
-            case START_DOCUMENT:
-                onNextFromStartDocument();
-                break;
-            case START_TAG:
-                onNextFromStartTag();
-                break;
-            case END_TAG:
-                onNextFromEndTag();
-                break;
-            case TEXT:
-                // not used
-                break;
-            case CDSECT:
-                // not used
-                break;
-            case ENTITY_REF:
-                // not used
-                break;
-            case IGNORABLE_WHITESPACE:
-                // not used
-                break;
-            case PROCESSING_INSTRUCTION:
-                // not used
-                break;
-            case COMMENT:
-                // not used
-                break;
-            case DOCDECL:
-                // not used
-                break;
-        }
-        
-        return mParsingState;
-    }
-
-    public int nextTag() throws XmlPullParserException {
-        int eventType = next();
-        if (eventType != START_TAG && eventType != END_TAG) {
-            throw new XmlPullParserException("expected start or end tag", this, null);
-        }
-        return eventType;
-    }
-
-    public String nextText() throws XmlPullParserException {
-        if (getEventType() != START_TAG) {
-            throw new XmlPullParserException("parser must be on START_TAG to read next text", this,
-                    null);
-        }
-        int eventType = next();
-        if (eventType == TEXT) {
-            String result = getText();
-            eventType = next();
-            if (eventType != END_TAG) {
-                throw new XmlPullParserException(
-                        "event TEXT it must be immediately followed by END_TAG", this, null);
-            }
-            return result;
-        } else if (eventType == END_TAG) {
-            return "";
-        } else {
-            throw new XmlPullParserException("parser must be on START_TAG or TEXT to read text",
-                    this, null);
-        }
-    }
-
-    public int nextToken() throws XmlPullParserException {
-        return next();
-    }
-
-    public void require(int type, String namespace, String name) throws XmlPullParserException {
-        if (type != getEventType() || (namespace != null && !namespace.equals(getNamespace()))
-                || (name != null && !name.equals(getName())))
-            throw new XmlPullParserException("expected " + TYPES[type] + getPositionDescription());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/GraphicalLayoutEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/GraphicalLayoutEditor.java
deleted file mode 100644
index ca7cac5..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/GraphicalLayoutEditor.java
+++ /dev/null
@@ -1,2355 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.LoadStatus;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData.LayoutBridge;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.layout.LayoutEditor.UiEditorActions;
-import com.android.ide.eclipse.editors.layout.LayoutReloadMonitor.ILayoutReloadListener;
-import com.android.ide.eclipse.editors.layout.descriptors.ViewElementDescriptor;
-import com.android.ide.eclipse.editors.layout.parts.ElementCreateCommand;
-import com.android.ide.eclipse.editors.layout.parts.UiElementEditPart;
-import com.android.ide.eclipse.editors.layout.parts.UiElementsEditPartFactory;
-import com.android.ide.eclipse.editors.resources.configurations.CountryCodeQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.KeyboardStateQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.LanguageQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.NavigationMethodQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.NetworkCodeQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.PixelDensityQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.RegionQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenDimensionQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenOrientationQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.TextInputMethodQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.TouchScreenQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.KeyboardStateQualifier.KeyboardState;
-import com.android.ide.eclipse.editors.resources.configurations.NavigationMethodQualifier.NavigationMethod;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenOrientationQualifier.ScreenOrientation;
-import com.android.ide.eclipse.editors.resources.configurations.TextInputMethodQualifier.TextInputMethod;
-import com.android.ide.eclipse.editors.resources.configurations.TouchScreenQualifier.TouchScreenType;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFile;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.ui.tree.CopyCutAction;
-import com.android.ide.eclipse.editors.ui.tree.PasteAction;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.DensityVerifier;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.DimensionVerifier;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.LanguageRegionVerifier;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.MobileCodeVerifier;
-import com.android.layoutlib.api.ILayoutLog;
-import com.android.layoutlib.api.ILayoutResult;
-import com.android.layoutlib.api.IResourceValue;
-import com.android.layoutlib.api.IStyleResourceValue;
-import com.android.layoutlib.api.ILayoutResult.ILayoutViewInfo;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.DefaultEditDomain;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.GraphicalViewer;
-import org.eclipse.gef.SelectionManager;
-import org.eclipse.gef.dnd.TemplateTransferDragSourceListener;
-import org.eclipse.gef.dnd.TemplateTransferDropTargetListener;
-import org.eclipse.gef.editparts.ScalableFreeformRootEditPart;
-import org.eclipse.gef.palette.PaletteRoot;
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.gef.ui.parts.GraphicalEditorWithPalette;
-import org.eclipse.gef.ui.parts.SelectionSynchronizer;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.PaletteData;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.part.FileEditorInput;
-
-import java.awt.image.BufferedImage;
-import java.awt.image.DataBufferInt;
-import java.awt.image.Raster;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.PrintStream;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Graphical layout editor, based on GEF.
- * <p/>
- * To understand GEF: http://www.ibm.com/developerworks/opensource/library/os-gef/
- * <p/>
- * To understand Drag'n'drop: http://www.eclipse.org/articles/Article-Workbench-DND/drag_drop.html
- */
-public class GraphicalLayoutEditor extends GraphicalEditorWithPalette
-        implements ILayoutReloadListener {
-    
-    private final static String THEME_SEPARATOR = "----------"; //$NON-NLS-1$
-
-    /** Reference to the layout editor */
-    private final LayoutEditor mLayoutEditor;
-
-    /** reference to the file being edited. */
-    private IFile mEditedFile;
-
-    private Clipboard mClipboard;
-    private Composite mParent;
-    private PaletteRoot mPaletteRoot;
-
-    private Text mCountry;
-    private Text mNetwork;
-    private Combo mLanguage;
-    private Combo mRegion;
-    private Combo mOrientation;
-    private Text mDensity;
-    private Combo mTouch;
-    private Combo mKeyboard;
-    private Combo mTextInput;
-    private Combo mNavigation;
-    private Text mSize1;
-    private Text mSize2;
-    private Combo mThemeCombo;
-    private Button mCreateButton;
-
-    private Label mCountryIcon;
-    private Label mNetworkIcon;
-    private Label mLanguageIcon;
-    private Label mRegionIcon;
-    private Label mOrientationIcon;
-    private Label mDensityIcon;
-    private Label mTouchIcon;
-    private Label mKeyboardIcon;
-    private Label mTextInputIcon;
-    private Label mNavigationIcon;
-    private Label mSizeIcon;
-
-    private Label mCurrentLayoutLabel;
-
-    private Image mWarningImage;
-    private Image mMatchImage;
-    private Image mErrorImage;
-
-    /** The {@link FolderConfiguration} representing the state of the UI controls */
-    private FolderConfiguration mCurrentConfig = new FolderConfiguration();
-    /** The {@link FolderConfiguration} being edited. */
-    private FolderConfiguration mEditedConfig;
-
-    private Map<String, Map<String, IResourceValue>> mConfiguredFrameworkRes;
-    private Map<String, Map<String, IResourceValue>> mConfiguredProjectRes;
-    private ProjectCallback mProjectCallback;
-    private ILayoutLog mLogger;
-
-    private boolean mNeedsRecompute = false;
-    private int mPlatformThemeCount = 0;
-    private boolean mDisableUpdates = false;
-    private boolean mActive = false;
-
-    private Runnable mFrameworkResourceChangeListener = new Runnable() {
-        public void run() {
-            // because the SDK changed we must reset the configured framework resource.
-            mConfiguredFrameworkRes = null;
-            
-            updateUIFromResources();
-
-            mThemeCombo.getParent().layout();
-
-            // updateUiFromFramework will reset language/region combo, so we must call
-            // setConfiguration after, or the settext on language/region will be lost.
-            if (mEditedConfig != null) {
-                setConfiguration(mEditedConfig);
-            }
-
-            // make sure we remove the custom view loader, since its parent class loader is the
-            // bridge class loader.
-            mProjectCallback = null;
-
-            recomputeLayout();
-        }
-    };
-
-    private final Runnable mConditionalRecomputeRunnable = new Runnable() {
-        public void run() {
-            if (mActive) {
-                recomputeLayout();
-            } else {
-                mNeedsRecompute = true;
-            }
-        }
-    };
-
-    private final Runnable mUiUpdateFromResourcesRunnable = new Runnable() {
-        public void run() {
-            updateUIFromResources();
-            mThemeCombo.getParent().layout();
-        }
-    };
-
-    public GraphicalLayoutEditor(LayoutEditor layoutEditor) {
-        mLayoutEditor = layoutEditor;
-        setEditDomain(new DefaultEditDomain(this));
-        setPartName("Layout");
-
-        IconFactory factory = IconFactory.getInstance();
-        mWarningImage = factory.getIcon("warning"); //$NON-NLS-1$
-        mMatchImage = factory.getIcon("match"); //$NON-NLS-1$
-        mErrorImage = factory.getIcon("error"); //$NON-NLS-1$
-
-        AdtPlugin.getDefault().addResourceChangedListener(mFrameworkResourceChangeListener);
-    }
-
-    // ------------------------------------
-    // Methods overridden from base classes
-    //------------------------------------
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mParent = parent;
-        GridLayout gl;
-        GridData gd;
-
-        mClipboard = new Clipboard(parent.getDisplay());
-
-        parent.setLayout(gl = new GridLayout(1, false));
-        gl.marginHeight = gl.marginWidth = 0;
-
-        // create the top part for the configuration control
-        int cols = 10;
-
-        Composite topParent = new Composite(parent, SWT.NONE);
-        topParent.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        topParent.setLayout(gl = new GridLayout(cols, false));
-
-        new Label(topParent, SWT.NONE).setText("MCC");
-        mCountryIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mCountry = new Text(mCountryIcon.getParent(), SWT.BORDER);
-        mCountry.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mCountry.addVerifyListener(new MobileCodeVerifier());
-        mCountry.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onCountryCodeChange();
-            }
-        });
-        mCountry.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onCountryCodeChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("MNC");
-        mNetworkIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mNetwork = new Text(mNetworkIcon.getParent(), SWT.BORDER);
-        mNetwork.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mNetwork.addVerifyListener(new MobileCodeVerifier());
-        mNetwork.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onNetworkCodeChange();
-            }
-        });
-        mNetwork.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onNetworkCodeChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Lang");
-        mLanguageIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mLanguage = new Combo(mLanguageIcon.getParent(), SWT.DROP_DOWN);
-        mLanguage.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mLanguage.addVerifyListener(new LanguageRegionVerifier());
-        mLanguage.addSelectionListener(new SelectionListener() {
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onLanguageChange();
-            }
-            public void widgetSelected(SelectionEvent e) {
-                onLanguageChange();
-            }
-        });
-        mLanguage.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onLanguageChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Region");
-        mRegionIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mRegion = new Combo(mRegionIcon.getParent(), SWT.DROP_DOWN);
-        mRegion.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mRegion.addVerifyListener(new LanguageRegionVerifier());
-        mRegion.addSelectionListener(new SelectionListener() {
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onRegionChange();
-            }
-            public void widgetSelected(SelectionEvent e) {
-                onRegionChange();
-            }
-        });
-        mRegion.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onRegionChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Orient");
-        mOrientationIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mOrientation = new Combo(mOrientationIcon.getParent(), SWT.DROP_DOWN | SWT.READ_ONLY);
-        ScreenOrientation[] soValues = ScreenOrientation.values();
-        mOrientation.add("(Default)");
-        for (ScreenOrientation value : soValues) {
-            mOrientation.add(value.getDisplayValue());
-        }
-        mOrientation.select(0);
-        mOrientation.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mOrientation.addSelectionListener(new SelectionAdapter() {
-           @Override
-            public void widgetSelected(SelectionEvent e) {
-               onOrientationChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Density");
-        mDensityIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mDensity = new Text(mDensityIcon.getParent(), SWT.BORDER);
-        mDensity.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mDensity.addVerifyListener(new DensityVerifier());
-        mDensity.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onDensityChange();
-            }
-        });
-        mDensity.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onDensityChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Touch");
-        mTouchIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mTouch = new Combo(mTouchIcon.getParent(), SWT.DROP_DOWN | SWT.READ_ONLY);
-        TouchScreenType[] tstValues = TouchScreenType.values();
-        mTouch.add("(Default)");
-        for (TouchScreenType value : tstValues) {
-            mTouch.add(value.getDisplayValue());
-        }
-        mTouch.select(0);
-        mTouch.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mTouch.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onTouchChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Keybrd");
-        mKeyboardIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mKeyboard = new Combo(mKeyboardIcon.getParent(), SWT.DROP_DOWN | SWT.READ_ONLY);
-        KeyboardState[] ksValues = KeyboardState.values();
-        mKeyboard.add("(Default)");
-        for (KeyboardState value : ksValues) {
-            mKeyboard.add(value.getDisplayValue());
-        }
-        mKeyboard.select(0);
-        mKeyboard.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mKeyboard.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onKeyboardChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Input");
-        mTextInputIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mTextInput = new Combo(mTextInputIcon.getParent(), SWT.DROP_DOWN | SWT.READ_ONLY);
-        TextInputMethod[] timValues = TextInputMethod.values();
-        mTextInput.add("(Default)");
-        for (TextInputMethod value : timValues) {
-            mTextInput.add(value.getDisplayValue());
-        }
-        mTextInput.select(0);
-        mTextInput.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mTextInput.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onTextInputChange();
-            }
-        });
-
-        new Label(topParent, SWT.NONE).setText("Nav");
-        mNavigationIcon = createControlComposite(topParent, true /* grab_horizontal */);
-        mNavigation = new Combo(mNavigationIcon.getParent(), SWT.DROP_DOWN | SWT.READ_ONLY);
-        NavigationMethod[] nValues = NavigationMethod.values();
-        mNavigation.add("(Default)");
-        for (NavigationMethod value : nValues) {
-            mNavigation.add(value.getDisplayValue());
-        }
-        mNavigation.select(0);
-        mNavigation.setLayoutData(new GridData(
-                GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        mNavigation.addSelectionListener(new SelectionAdapter() {
-            @Override
-             public void widgetSelected(SelectionEvent e) {
-                onNavigationChange();
-            } 
-        });
-
-        Composite labelParent = new Composite(topParent, SWT.NONE);
-        labelParent.setLayout(gl = new GridLayout(8, false));
-        gl.marginWidth = gl.marginHeight = 0;
-        labelParent.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.horizontalSpan = cols;
-
-        new Label(labelParent, SWT.NONE).setText("Editing config:");
-        mCurrentLayoutLabel = new Label(labelParent, SWT.NONE);
-        mCurrentLayoutLabel.setLayoutData(gd = new GridData(GridData.FILL_HORIZONTAL));
-        gd.widthHint = 50;
-
-        new Label(labelParent, SWT.NONE).setText("Size");
-        mSizeIcon = createControlComposite(labelParent, false);
-        Composite sizeParent = new Composite(mSizeIcon.getParent(), SWT.NONE);
-        sizeParent.setLayout(gl = new GridLayout(3, false));
-        gl.marginWidth = gl.marginHeight = 0;
-        gl.horizontalSpacing = 0;
-
-        mSize1 = new Text(sizeParent, SWT.BORDER);
-        mSize1.setLayoutData(gd = new GridData());
-        gd.widthHint = 30;
-        new Label(sizeParent, SWT.NONE).setText("x");
-        mSize2 = new Text(sizeParent, SWT.BORDER);
-        mSize2.setLayoutData(gd = new GridData());
-        gd.widthHint = 30;
-
-        DimensionVerifier verifier = new DimensionVerifier();
-        mSize1.addVerifyListener(verifier);
-        mSize2.addVerifyListener(verifier);
-
-        SelectionListener sl = new SelectionListener() {
-            public void widgetDefaultSelected(SelectionEvent e) {
-                onSizeChange();
-            }
-            public void widgetSelected(SelectionEvent e) {
-                onSizeChange();
-            }
-        };
-
-        mSize1.addSelectionListener(sl);
-        mSize2.addSelectionListener(sl);
-        
-        ModifyListener sizeModifyListener = new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onSizeChange();
-            }
-        };
-
-        mSize1.addModifyListener(sizeModifyListener);
-        mSize2.addModifyListener(sizeModifyListener);
-
-        // first separator
-        Label separator = new Label(labelParent, SWT.SEPARATOR | SWT.VERTICAL);
-        separator.setLayoutData(gd = new GridData(
-                GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL));
-        gd.heightHint = 0;
-
-        mThemeCombo = new Combo(labelParent, SWT.READ_ONLY | SWT.DROP_DOWN);
-        mThemeCombo.setEnabled(false);
-        updateUIFromResources();
-        mThemeCombo.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onThemeChange();
-            }
-        });
-
-        // second separator
-        separator = new Label(labelParent, SWT.SEPARATOR | SWT.VERTICAL);
-        separator.setLayoutData(gd = new GridData(
-                GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL));
-        gd.heightHint = 0;
-
-        mCreateButton = new Button(labelParent, SWT.PUSH | SWT.FLAT);
-        mCreateButton.setText("Create...");
-        mCreateButton.setEnabled(false);
-        mCreateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                LayoutCreatorDialog dialog = new LayoutCreatorDialog(mCreateButton.getShell(),
-                        mEditedFile.getName(), mCurrentConfig);
-                if (dialog.open() == Dialog.OK) {
-                    final FolderConfiguration config = new FolderConfiguration();
-                    dialog.getConfiguration(config);
-                    
-                    createAlternateLayout(config);
-                }
-            }
-        });
-
-        // create a new composite that will contain the standard editor controls.
-        Composite editorParent = new Composite(parent, SWT.NONE);
-        editorParent.setLayoutData(new GridData(GridData.FILL_BOTH));
-        editorParent.setLayout(new FillLayout());
-        super.createPartControl(editorParent);
-    }
-
-    @Override
-    public void dispose() {
-        if (mFrameworkResourceChangeListener != null) {
-            AdtPlugin.getDefault().removeResourceChangedListener(
-                    mFrameworkResourceChangeListener);
-            mFrameworkResourceChangeListener = null;
-        }
-
-        LayoutReloadMonitor.getMonitor().removeListener(mEditedFile.getProject(), this);
-
-        if (mClipboard != null) {
-            mClipboard.dispose();
-            mClipboard = null;
-        }
-
-        super.dispose();
-    }
-
-    /* (non-Javadoc)
-     * Creates the palette root.
-     */
-    @Override
-    protected PaletteRoot getPaletteRoot() {
-        mPaletteRoot = PaletteFactory.createPaletteRoot(mPaletteRoot,
-                mLayoutEditor.getTargetData()); 
-        return mPaletteRoot;
-    }
-
-    public Clipboard getClipboard() {
-        return mClipboard;
-    }
-
-    /**
-     * Save operation in the Graphical Layout Editor.
-     * <p/>
-     * In our workflow, the model is owned by the Structured XML Editor.
-     * The graphical layout editor just displays it -- thus we don't really
-     * save anything here.
-     * <p/>
-     * This must NOT call the parent editor part. At the contrary, the parent editor
-     * part will call this *after* having done the actual save operation.
-     * <p/>
-     * The only action this editor must do is mark the undo command stack as
-     * being no longer dirty.
-     */
-    @Override
-    public void doSave(IProgressMonitor monitor) {
-        getCommandStack().markSaveLocation();
-        firePropertyChange(PROP_DIRTY);
-    }
-    
-    @Override
-    protected void configurePaletteViewer() {
-        super.configurePaletteViewer();
-
-        // Create a drag source listener on an edit part that is a viewer.
-        // What this does is use DND with a TemplateTransfer type which is actually
-        // the PaletteTemplateEntry held in the PaletteRoot.
-        TemplateTransferDragSourceListener dragSource =
-            new TemplateTransferDragSourceListener(getPaletteViewer());
-        
-        // Create a drag source on the palette viewer.
-        // See the drag target associated with the GraphicalViewer in configureGraphicalViewer.
-        getPaletteViewer().addDragSourceListener(dragSource);
-    }
-
-    /* (non-javadoc)
-     * Configure the graphical viewer before it receives its contents.
-     */
-    @Override
-    protected void configureGraphicalViewer() {
-        super.configureGraphicalViewer();
-
-        GraphicalViewer viewer = getGraphicalViewer();
-        viewer.setEditPartFactory(new UiElementsEditPartFactory(mParent.getDisplay()));
-        viewer.setRootEditPart(new ScalableFreeformRootEditPart());
-
-        // Disable the following -- we don't drag *from* the GraphicalViewer yet: 
-        // viewer.addDragSourceListener(new TemplateTransferDragSourceListener(viewer));
-        
-        viewer.addDropTargetListener(new DropListener(viewer));
-    }
-    
-    class DropListener extends TemplateTransferDropTargetListener {
-        public DropListener(EditPartViewer viewer) {
-            super(viewer);
-        }
-
-        // TODO explain
-        @Override
-        protected CreationFactory getFactory(final Object template) {
-            return new CreationFactory() {
-                public Object getNewObject() {
-                    // We don't know the newly created EditPart since "creating" new
-                    // elements is done by ElementCreateCommand.execute() directly by
-                    // manipulating the XML elements..
-                    return null;
-                }
-
-                public Object getObjectType() {
-                    return template;
-                }
-                
-            };
-        }
-    }
-
-    /* (non-javadoc)
-     * Set the contents of the GraphicalViewer after it has been created.
-     */
-    @Override
-    protected void initializeGraphicalViewer() {
-        GraphicalViewer viewer = getGraphicalViewer();
-        viewer.setContents(getModel());
-
-        IEditorInput input = getEditorInput();
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput)input;
-            mEditedFile = fileInput.getFile();
-
-            updateUIFromResources();
-
-            LayoutReloadMonitor.getMonitor().addListener(mEditedFile.getProject(), this);
-        } else {
-            // really this shouldn't happen! Log it in case it happens
-            mEditedFile = null;
-            AdtPlugin.log(IStatus.ERROR, "Input is not of type FileEditorInput: %1$s",
-                    input.toString());
-        }
-    }
-    
-    /* (non-javadoc)
-     * Sets the graphicalViewer for this EditorPart.
-     * @param viewer the graphical viewer
-     */
-    @Override
-    protected void setGraphicalViewer(GraphicalViewer viewer) {
-        super.setGraphicalViewer(viewer);
-
-        // TODO: viewer.setKeyHandler()
-        viewer.setContextMenu(createContextMenu(viewer));
-    }
-
-    /**
-     * Used by LayoutEditor.UiEditorActions.selectUiNode to select a new UI Node
-     * created by  {@link ElementCreateCommand#execute()}.
-     * 
-     * @param uiNodeModel The {@link UiElementNode} to select.
-     */
-    public void selectModel(UiElementNode uiNodeModel) {
-        GraphicalViewer viewer = getGraphicalViewer();
-        
-        // Give focus to the graphical viewer (in case the outline has it)
-        viewer.getControl().forceFocus();
-        
-        Object editPart = viewer.getEditPartRegistry().get(uiNodeModel);
-        
-        if (editPart instanceof EditPart) {
-            viewer.select((EditPart)editPart);
-        }
-    }
-
-
-    //--------------
-    // Local methods
-    //--------------
-
-    public LayoutEditor getLayoutEditor() {
-        return mLayoutEditor;
-    }
-
-    private MenuManager createContextMenu(GraphicalViewer viewer) {
-        MenuManager menuManager = new MenuManager();
-        menuManager.setRemoveAllWhenShown(true);
-        menuManager.addMenuListener(new ActionMenuListener(viewer));
-        
-        return menuManager;
-    }
-
-    private class ActionMenuListener implements IMenuListener {
-        private final GraphicalViewer mViewer;
-
-        public ActionMenuListener(GraphicalViewer viewer) {
-            mViewer = viewer;
-        }
-
-        /**
-         * The menu is about to be shown. The menu manager has already been
-         * requested to remove any existing menu item. This method gets the
-         * tree selection and if it is of the appropriate type it re-creates
-         * the necessary actions.
-         */
-       public void menuAboutToShow(IMenuManager manager) {
-           ArrayList<UiElementNode> selected = new ArrayList<UiElementNode>();
-
-           // filter selected items and only keep those we can handle
-           for (Object obj : mViewer.getSelectedEditParts()) {
-               if (obj instanceof UiElementEditPart) {
-                   UiElementEditPart part = (UiElementEditPart) obj;
-                   UiElementNode uiNode = part.getUiNode();
-                   if (uiNode != null) {
-                       selected.add(uiNode);
-                   }
-               }
-           }
-           
-           if (selected.size() > 0) {
-               doCreateMenuAction(manager, mViewer, selected);
-           }
-        }
-    }
-    
-    private void doCreateMenuAction(IMenuManager manager,
-            final GraphicalViewer viewer,
-            final ArrayList<UiElementNode> selected) {
-        if (selected != null) {
-            boolean hasXml = false;
-            for (UiElementNode uiNode : selected) {
-                if (uiNode.getXmlNode() != null) {
-                    hasXml = true;
-                    break;
-                }
-            }
-
-            if (hasXml) {
-                manager.add(new CopyCutAction(mLayoutEditor, getClipboard(),
-                        null, selected, true /* cut */));
-                manager.add(new CopyCutAction(mLayoutEditor, getClipboard(),
-                        null, selected, false /* cut */));
-
-                // Can't paste with more than one element selected (the selection is the target)
-                if (selected.size() <= 1) {
-                    // Paste is not valid if it would add a second element on a terminal element
-                    // which parent is a document -- an XML document can only have one child. This
-                    // means paste is valid if the current UI node can have children or if the
-                    // parent is not a document.
-                    UiElementNode ui_root = selected.get(0).getUiRoot();
-                    if (ui_root.getDescriptor().hasChildren() ||
-                            !(ui_root.getUiParent() instanceof UiDocumentNode)) {
-                        manager.add(new PasteAction(mLayoutEditor, getClipboard(),
-                                                    selected.get(0)));
-                    }
-                }
-                manager.add(new Separator());
-            }
-        }
-
-        // Append "add" and "remove" actions. They do the same thing as the add/remove
-        // buttons on the side.
-        IconFactory factory = IconFactory.getInstance();
-        
-        final UiEditorActions uiActions = mLayoutEditor.getUiEditorActions();
-
-        // "Add" makes sense only if there's 0 or 1 item selected since the
-        // one selected item becomes the target.
-        if (selected == null || selected.size() <= 1) {
-            manager.add(new Action("Add...", factory.getImageDescriptor("add")) { //$NON-NLS-2$
-                @Override
-                public void run() {
-                    UiElementNode node = selected != null && selected.size() > 0 ? selected.get(0)
-                                                                                 : null;
-                    uiActions.doAdd(node, viewer.getControl().getShell());
-                }
-            });
-        }
-
-        if (selected != null) {
-            manager.add(new Action("Remove", factory.getImageDescriptor("delete")) { //$NON-NLS-2$
-                @Override
-                public void run() {
-                    uiActions.doRemove(selected, viewer.getControl().getShell());
-                }
-            });
-
-            manager.add(new Separator());
-            
-            manager.add(new Action("Up", factory.getImageDescriptor("up")) { //$NON-NLS-2$
-                @Override
-                public void run() {
-                    uiActions.doUp(selected);
-                }
-            });
-            manager.add(new Action("Down", factory.getImageDescriptor("down")) { //$NON-NLS-2$
-                @Override
-                public void run() {
-                    uiActions.doDown(selected);
-                }
-            });
-        }
-        
-    } 
-
-    /**
-     * Sets the UI for the edition of a new file.
-     * @param configuration the configuration of the new file.
-     */
-    public void editNewFile(FolderConfiguration configuration) {
-        // update the configuration UI
-        setConfiguration(configuration);
-        
-        // enable the create button if the current and edited config are not equals
-        mCreateButton.setEnabled(mEditedConfig.equals(mCurrentConfig) == false);
-    }
-    
-    public Rectangle getBounds() {
-        ScreenOrientation orientation = null;
-        if (mOrientation.getSelectionIndex() == 0) {
-            orientation = ScreenOrientation.PORTRAIT;
-        } else {
-            orientation = ScreenOrientation.getByIndex(
-                    mOrientation.getSelectionIndex() - 1);
-        }
-
-        int s1, s2;
-
-        // get the size from the UI controls. If it fails, revert to default values.
-        try {
-            s1 = Integer.parseInt(mSize1.getText().trim());
-        } catch (NumberFormatException e) {
-            s1 = 480;
-        }
-
-        try {
-            s2 = Integer.parseInt(mSize2.getText().trim());
-        } catch (NumberFormatException e) {
-            s2 = 320;
-        }
-
-        // make sure s1 is bigger than s2
-        if (s1 < s2) {
-            int tmp = s1;
-            s1 = s2;
-            s2 = tmp;
-        }
-
-        switch (orientation) {
-            default:
-            case PORTRAIT:
-                return new Rectangle(0, 0, s2, s1);
-            case LANDSCAPE:
-                return new Rectangle(0, 0, s1, s2);
-            case SQUARE:
-                return new Rectangle(0, 0, s1, s1);
-        }
-    }
-    
-    /**
-     * Renders an Android View described by a {@link ViewElementDescriptor}.
-     * <p/>This uses the <code>wrap_content</code> mode for both <code>layout_width</code> and
-     * <code>layout_height</code>, and use the class name for the <code>text</code> attribute.
-     * @param descriptor the descriptor for the class to render.
-     * @return an ImageData containing the rendering or <code>null</code> if rendering failed.
-     */
-    public ImageData renderWidget(ViewElementDescriptor descriptor) {
-        if (mEditedFile == null) {
-            return null;
-        }
-        
-        IAndroidTarget target = Sdk.getCurrent().getTarget(mEditedFile.getProject());
-        if (target == null) {
-            return null;
-        }
-        
-        AndroidTargetData data = Sdk.getCurrent().getTargetData(target);
-        if (data == null) {
-            return null;
-        }
-        
-        LayoutBridge bridge = data.getLayoutBridge();
-
-        if (bridge.bridge != null) { // bridge can never be null.
-            ResourceManager resManager = ResourceManager.getInstance();
-
-            ProjectCallback projectCallback = null;
-            Map<String, Map<String, IResourceValue>> configuredProjectResources = null;
-            if (mEditedFile != null) {
-                ProjectResources projectRes = resManager.getProjectResources(
-                        mEditedFile.getProject());
-                projectCallback = new ProjectCallback(bridge.classLoader,
-                        projectRes, mEditedFile.getProject());
-
-                // get the configured resources for the project
-                // get the resources of the file's project.
-                if (mConfiguredProjectRes == null && projectRes != null) {
-                    // make sure they are loaded
-                    projectRes.loadAll();
-
-                    // get the project resource values based on the current config
-                    mConfiguredProjectRes = projectRes.getConfiguredResources(mCurrentConfig);
-                }
-                
-                configuredProjectResources = mConfiguredProjectRes;
-            } else {
-                // we absolutely need a Map of configured project resources.
-                configuredProjectResources = new HashMap<String, Map<String, IResourceValue>>();
-            }
-
-            // get the framework resources
-            Map<String, Map<String, IResourceValue>> frameworkResources =
-                    getConfiguredFrameworkResources();
-
-            if (configuredProjectResources != null && frameworkResources != null) {
-                // get the selected theme
-                int themeIndex = mThemeCombo.getSelectionIndex();
-                if (themeIndex != -1) {
-                    String theme = mThemeCombo.getItem(themeIndex);
-                    
-                    // change the string if it's a custom theme to make sure we can
-                    // differentiate them
-                    if (themeIndex >= mPlatformThemeCount) {
-                        theme = "*" + theme; //$NON-NLS-1$
-                    }
-
-                    // Render a single object as described by the ViewElementDescriptor.
-                    WidgetPullParser parser = new WidgetPullParser(descriptor);
-                    ILayoutResult result = bridge.bridge.computeLayout(parser,
-                            null /* projectKey */,
-                            300 /* width */, 300 /* height */, theme,
-                            configuredProjectResources, frameworkResources, projectCallback,
-                            null /* logger */);
-
-                    // update the UiElementNode with the layout info.
-                    if (result.getSuccess() == ILayoutResult.SUCCESS) {
-                        BufferedImage largeImage = result.getImage();
-
-                        // we need to resize it to the actual widget size, and convert it into
-                        // an SWT image object.
-                        int width = result.getRootView().getRight();
-                        int height = result.getRootView().getBottom();
-                        Raster raster = largeImage.getData(new java.awt.Rectangle(width, height));
-                        int[] imageDataBuffer = ((DataBufferInt)raster.getDataBuffer()).getData();
-                        
-                        ImageData imageData = new ImageData(width, height, 32,
-                                new PaletteData(0x00FF0000, 0x0000FF00, 0x000000FF));
-
-                        imageData.setPixels(0, 0, imageDataBuffer.length, imageDataBuffer, 0);
-                        
-                        return imageData;
-                    }
-                }
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Reloads this editor, by getting the new model from the {@link LayoutEditor}.
-     */
-    void reloadEditor() {
-        GraphicalViewer viewer = getGraphicalViewer();
-        viewer.setContents(getModel());
-
-        IEditorInput input = mLayoutEditor.getEditorInput();
-        setInput(input);
-
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput)input;
-            mEditedFile = fileInput.getFile();
-        } else {
-            // really this shouldn't happen! Log it in case it happens
-            mEditedFile = null;
-            AdtPlugin.log(IStatus.ERROR, "Input is not of type FileEditorInput: %1$s",
-                    input.toString());
-        }
-    }
-
-    /**
-     * Update the layout editor when the Xml model is changed.
-     */
-    void onXmlModelChanged() {
-        GraphicalViewer viewer = getGraphicalViewer();
-
-        // try to preserve the selection before changing the content
-        SelectionManager selMan = viewer.getSelectionManager();
-        ISelection selection = selMan.getSelection();
-
-        try {
-            viewer.setContents(getModel());
-        } finally {
-            selMan.setSelection(selection);
-        }
-
-        if (mLayoutEditor.isGraphicalEditorActive()) {
-            recomputeLayout();
-        } else {
-            mNeedsRecompute = true;
-        }
-    }
-
-    /**
-     * Update the UI controls state with a given {@link FolderConfiguration}.
-     * <p/>If a qualifier is not present in the {@link FolderConfiguration} object, the UI control
-     * is not modified. However if the value in the control is not the default value, a warning
-     * icon is showed.
-     */
-    void setConfiguration(FolderConfiguration config) {
-        mDisableUpdates = true; // we do not want to trigger onXXXChange when setting new values in the widgets.
-
-        mEditedConfig = config;
-        mConfiguredFrameworkRes = mConfiguredProjectRes = null;
-
-        mCountryIcon.setImage(mMatchImage);
-        CountryCodeQualifier countryQualifier = config.getCountryCodeQualifier();
-        if (countryQualifier != null) {
-            mCountry.setText(String.format("%1$d", countryQualifier.getCode()));
-            mCurrentConfig.setCountryCodeQualifier(countryQualifier);
-        } else if (mCountry.getText().length() > 0) {
-            mCountryIcon.setImage(mWarningImage);
-        }
-
-        mNetworkIcon.setImage(mMatchImage);
-        NetworkCodeQualifier networkQualifier = config.getNetworkCodeQualifier();
-        if (networkQualifier != null) {
-            mNetwork.setText(String.format("%1$d", networkQualifier.getCode()));
-            mCurrentConfig.setNetworkCodeQualifier(networkQualifier);
-        } else if (mNetwork.getText().length() > 0) {
-            mNetworkIcon.setImage(mWarningImage);
-        }
-
-        mLanguageIcon.setImage(mMatchImage);
-        LanguageQualifier languageQualifier = config.getLanguageQualifier();
-        if (languageQualifier != null) {
-            mLanguage.setText(languageQualifier.getValue());
-            mCurrentConfig.setLanguageQualifier(languageQualifier);
-        } else if (mLanguage.getText().length() > 0) {
-            mLanguageIcon.setImage(mWarningImage);
-        }
-
-        mRegionIcon.setImage(mMatchImage);
-        RegionQualifier regionQualifier = config.getRegionQualifier();
-        if (regionQualifier != null) {
-            mRegion.setText(regionQualifier.getValue());
-            mCurrentConfig.setRegionQualifier(regionQualifier);
-        } else if (mRegion.getText().length() > 0) {
-            mRegionIcon.setImage(mWarningImage);
-        }
-
-        mOrientationIcon.setImage(mMatchImage);
-        ScreenOrientationQualifier orientationQualifier = config.getScreenOrientationQualifier();
-        if (orientationQualifier != null) {
-            mOrientation.select(
-                    ScreenOrientation.getIndex(orientationQualifier.getValue()) + 1);
-            mCurrentConfig.setScreenOrientationQualifier(orientationQualifier);
-        } else if (mOrientation.getSelectionIndex() != 0) {
-            mOrientationIcon.setImage(mWarningImage);
-        }
-
-        mDensityIcon.setImage(mMatchImage);
-        PixelDensityQualifier densityQualifier = config.getPixelDensityQualifier();
-        if (densityQualifier != null) {
-            mDensity.setText(String.format("%1$d", densityQualifier.getValue()));
-            mCurrentConfig.setPixelDensityQualifier(densityQualifier);
-        } else if (mDensity.getText().length() > 0) {
-            mDensityIcon.setImage(mWarningImage);
-        }
-
-        mTouchIcon.setImage(mMatchImage);
-        TouchScreenQualifier touchQualifier = config.getTouchTypeQualifier();
-        if (touchQualifier != null) {
-            mTouch.select(TouchScreenType.getIndex(touchQualifier.getValue()) + 1);
-            mCurrentConfig.setTouchTypeQualifier(touchQualifier);
-        } else if (mTouch.getSelectionIndex() != 0) {
-            mTouchIcon.setImage(mWarningImage);
-        }
-
-        mKeyboardIcon.setImage(mMatchImage);
-        KeyboardStateQualifier keyboardQualifier = config.getKeyboardStateQualifier();
-        if (keyboardQualifier != null) {
-            mKeyboard.select(KeyboardState.getIndex(keyboardQualifier.getValue()) + 1);
-            mCurrentConfig.setKeyboardStateQualifier(keyboardQualifier);
-        } else if (mKeyboard.getSelectionIndex() != 0) {
-            mKeyboardIcon.setImage(mWarningImage);
-        }
-
-        mTextInputIcon.setImage(mMatchImage);
-        TextInputMethodQualifier inputQualifier = config.getTextInputMethodQualifier();
-        if (inputQualifier != null) {
-            mTextInput.select(TextInputMethod.getIndex(inputQualifier.getValue()) + 1);
-            mCurrentConfig.setTextInputMethodQualifier(inputQualifier);
-        } else if (mTextInput.getSelectionIndex() != 0) {
-            mTextInputIcon.setImage(mWarningImage);
-        }
-
-        mNavigationIcon.setImage(mMatchImage);
-        NavigationMethodQualifier navigationQualifiter = config.getNavigationMethodQualifier();
-        if (navigationQualifiter != null) {
-            mNavigation.select(
-                    NavigationMethod.getIndex(navigationQualifiter.getValue()) + 1);
-            mCurrentConfig.setNavigationMethodQualifier(navigationQualifiter);
-        } else if (mNavigation.getSelectionIndex() != 0) {
-            mNavigationIcon.setImage(mWarningImage);
-        }
-
-        mSizeIcon.setImage(mMatchImage);
-        ScreenDimensionQualifier sizeQualifier = config.getScreenDimensionQualifier();
-        if (sizeQualifier != null) {
-            mSize1.setText(String.format("%1$d", sizeQualifier.getValue1()));
-            mSize2.setText(String.format("%1$d", sizeQualifier.getValue2()));
-            mCurrentConfig.setScreenDimensionQualifier(sizeQualifier);
-        } else if (mSize1.getText().length() > 0 && mSize2.getText().length() > 0) {
-            mSizeIcon.setImage(mWarningImage);
-        }
-
-        // update the string showing the folder name
-        String current = config.toDisplayString();
-        mCurrentLayoutLabel.setText(current != null ? current : "(Default)");
-        
-        mDisableUpdates = false;
-    }
-    
-    /**
-     * Displays an error icon in front of all the non-null qualifiers.
-     */
-    void displayConfigError() {
-        mCountryIcon.setImage(mMatchImage);
-        CountryCodeQualifier countryQualifier = mCurrentConfig.getCountryCodeQualifier();
-        if (countryQualifier != null) {
-            mCountryIcon.setImage(mErrorImage);
-        }
-        
-        mNetworkIcon.setImage(mMatchImage);
-        NetworkCodeQualifier networkQualifier = mCurrentConfig.getNetworkCodeQualifier();
-        if (networkQualifier != null) {
-            mNetworkIcon.setImage(mErrorImage);
-        }
-        
-        mLanguageIcon.setImage(mMatchImage);
-        LanguageQualifier languageQualifier = mCurrentConfig.getLanguageQualifier();
-        if (languageQualifier != null) {
-            mLanguageIcon.setImage(mErrorImage);
-        }
-        
-        mRegionIcon.setImage(mMatchImage);
-        RegionQualifier regionQualifier = mCurrentConfig.getRegionQualifier();
-        if (regionQualifier != null) {
-            mRegionIcon.setImage(mErrorImage);
-        }
-        
-        mOrientationIcon.setImage(mMatchImage);
-        ScreenOrientationQualifier orientationQualifier =
-            mCurrentConfig.getScreenOrientationQualifier();
-        if (orientationQualifier != null) {
-            mOrientationIcon.setImage(mErrorImage);
-        }
-        
-        mDensityIcon.setImage(mMatchImage);
-        PixelDensityQualifier densityQualifier = mCurrentConfig.getPixelDensityQualifier();
-        if (densityQualifier != null) {
-            mDensityIcon.setImage(mErrorImage);
-        }
-        
-        mTouchIcon.setImage(mMatchImage);
-        TouchScreenQualifier touchQualifier = mCurrentConfig.getTouchTypeQualifier();
-        if (touchQualifier != null) {
-            mTouchIcon.setImage(mErrorImage);
-        }
-        
-        mKeyboardIcon.setImage(mMatchImage);
-        KeyboardStateQualifier keyboardQualifier = mCurrentConfig.getKeyboardStateQualifier();
-        if (keyboardQualifier != null) {
-            mKeyboardIcon.setImage(mErrorImage);
-        }
-
-        mTextInputIcon.setImage(mMatchImage);
-        TextInputMethodQualifier inputQualifier = mCurrentConfig.getTextInputMethodQualifier();
-        if (inputQualifier != null) {
-            mTextInputIcon.setImage(mErrorImage);
-        }
-        
-        mNavigationIcon.setImage(mMatchImage);
-        NavigationMethodQualifier navigationQualifiter =
-            mCurrentConfig.getNavigationMethodQualifier();
-        if (navigationQualifiter != null) {
-            mNavigationIcon.setImage(mErrorImage);
-        }
-        
-        mSizeIcon.setImage(mMatchImage);
-        ScreenDimensionQualifier sizeQualifier = mCurrentConfig.getScreenDimensionQualifier();
-        if (sizeQualifier != null) {
-            mSizeIcon.setImage(mErrorImage);
-        }
-        
-        // update the string showing the folder name
-        String current = mCurrentConfig.toDisplayString();
-        mCurrentLayoutLabel.setText(current != null ? current : "(Default)");
-    }
-
-    UiDocumentNode getModel() {
-        return mLayoutEditor.getUiRootNode();
-    }
-    
-    void reloadPalette() {
-        PaletteFactory.createPaletteRoot(mPaletteRoot, mLayoutEditor.getTargetData());
-    }
-
-    private void onCountryCodeChange() {
-        // because mCountry triggers onCountryCodeChange at each modification, calling setText()
-        // will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String value = mCountry.getText();
-
-        // empty string, means no qualifier.
-        if (value.length() == 0) {
-            mCurrentConfig.setCountryCodeQualifier(null);
-        } else {
-            try {
-                CountryCodeQualifier qualifier = CountryCodeQualifier.getQualifier(
-                        CountryCodeQualifier.getFolderSegment(Integer.parseInt(value)));
-                if (qualifier != null) {
-                    mCurrentConfig.setCountryCodeQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong (for instance a one letter string).
-                    // We do nothing in this case.
-                    mCountryIcon.setImage(mErrorImage);
-                    return;
-                }
-            } catch (NumberFormatException e) {
-                // Looks like the code is not a number. This should not happen since the text
-                // field has a VerifyListener that prevents it.
-                mCurrentConfig.setCountryCodeQualifier(null);
-                mCountryIcon.setImage(mErrorImage);
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onNetworkCodeChange() {
-        // because mNetwork triggers onNetworkCodeChange at each modification, calling setText()
-        // will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String value = mNetwork.getText();
-
-        // empty string, means no qualifier.
-        if (value.length() == 0) {
-            mCurrentConfig.setNetworkCodeQualifier(null);
-        } else {
-            try {
-                NetworkCodeQualifier qualifier = NetworkCodeQualifier.getQualifier(
-                        NetworkCodeQualifier.getFolderSegment(Integer.parseInt(value)));
-                if (qualifier != null) {
-                    mCurrentConfig.setNetworkCodeQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong (for instance a one letter string).
-                    // We do nothing in this case.
-                    mNetworkIcon.setImage(mErrorImage);
-                    return;
-                }
-            } catch (NumberFormatException e) {
-                // Looks like the code is not a number. This should not happen since the text
-                // field has a VerifyListener that prevents it.
-                mCurrentConfig.setNetworkCodeQualifier(null);
-                mNetworkIcon.setImage(mErrorImage);
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    /**
-     * Call back for language combo selection
-     */
-    private void onLanguageChange() {
-        // because mLanguage triggers onLanguageChange at each modification, the filling
-        // of the combo with data will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String value = mLanguage.getText();
-
-        updateRegionUi(null /* projectResources */, null /* frameworkResources */);
-
-        // empty string, means no qualifier.
-        if (value.length() == 0) {
-            mCurrentConfig.setLanguageQualifier(null);
-        } else {
-            LanguageQualifier qualifier = null;
-            String segment = LanguageQualifier.getFolderSegment(value);
-            if (segment != null) {
-                qualifier = LanguageQualifier.getQualifier(segment);
-            }
-
-            if (qualifier != null) {
-                mCurrentConfig.setLanguageQualifier(qualifier);
-            } else {
-                // Failure! Looks like the value is wrong (for instance a one letter string).
-                mCurrentConfig.setLanguageQualifier(null);
-                mLanguageIcon.setImage(mErrorImage);
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onRegionChange() {
-        // because mRegion triggers onRegionChange at each modification, the filling
-        // of the combo with data will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String value = mRegion.getText();
-
-        // empty string, means no qualifier.
-        if (value.length() == 0) {
-            mCurrentConfig.setRegionQualifier(null);
-        } else {
-            RegionQualifier qualifier = null;
-            String segment = RegionQualifier.getFolderSegment(value);
-            if (segment != null) {
-                qualifier = RegionQualifier.getQualifier(segment);
-            }
-
-            if (qualifier != null) {
-                mCurrentConfig.setRegionQualifier(qualifier);
-            } else {
-                // Failure! Looks like the value is wrong (for instance a one letter string).
-                mCurrentConfig.setRegionQualifier(null);
-                mRegionIcon.setImage(mErrorImage);
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onOrientationChange() {
-        // update the current config
-        int index = mOrientation.getSelectionIndex();
-        if (index != 0) {
-            mCurrentConfig.setScreenOrientationQualifier(new ScreenOrientationQualifier(
-                ScreenOrientation.getByIndex(index-1)));
-        } else {
-            mCurrentConfig.setScreenOrientationQualifier(null);
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onDensityChange() {
-        // because mDensity triggers onDensityChange at each modification, calling setText()
-        // will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String value = mDensity.getText();
-
-        // empty string, means no qualifier.
-        if (value.length() == 0) {
-            mCurrentConfig.setPixelDensityQualifier(null);
-        } else {
-            try {
-                PixelDensityQualifier qualifier = PixelDensityQualifier.getQualifier(
-                        PixelDensityQualifier.getFolderSegment(Integer.parseInt(value)));
-                if (qualifier != null) {
-                    mCurrentConfig.setPixelDensityQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong (for instance a one letter string).
-                    // We do nothing in this case.
-                    return;
-                }
-            } catch (NumberFormatException e) {
-                // Looks like the code is not a number. This should not happen since the text
-                // field has a VerifyListener that prevents it.
-                // We do nothing in this case.
-                mDensityIcon.setImage(mErrorImage);
-                return;
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onTouchChange() {
-        // update the current config
-        int index = mTouch.getSelectionIndex();
-        if (index != 0) {
-            mCurrentConfig.setTouchTypeQualifier(new TouchScreenQualifier(
-                TouchScreenType.getByIndex(index-1)));
-        } else {
-            mCurrentConfig.setTouchTypeQualifier(null);
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onKeyboardChange() {
-        // update the current config
-        int index = mKeyboard.getSelectionIndex();
-        if (index != 0) {
-            mCurrentConfig.setKeyboardStateQualifier(new KeyboardStateQualifier(
-                KeyboardState.getByIndex(index-1)));
-        } else {
-            mCurrentConfig.setKeyboardStateQualifier(null);
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onTextInputChange() {
-        // update the current config
-        int index = mTextInput.getSelectionIndex();
-        if (index != 0) {
-            mCurrentConfig.setTextInputMethodQualifier(new TextInputMethodQualifier(
-                TextInputMethod.getByIndex(index-1)));
-        } else {
-            mCurrentConfig.setTextInputMethodQualifier(null);
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onNavigationChange() {
-        // update the current config
-        int index = mNavigation.getSelectionIndex();
-        if (index != 0) {
-            mCurrentConfig.setNavigationMethodQualifier(new NavigationMethodQualifier(
-                NavigationMethod.getByIndex(index-1)));
-        } else {
-            mCurrentConfig.setNavigationMethodQualifier(null);
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-    private void onSizeChange() {
-        // because mSize1 and mSize2 trigger onSizeChange at each modification, calling setText()
-        // will trigger notifications, and we don't want that.
-        if (mDisableUpdates == true) {
-            return;
-        }
-
-        // update the current config
-        String size1 = mSize1.getText();
-        String size2 = mSize2.getText();
-
-        // if only one of the strings is empty, do nothing
-        if ((size1.length() == 0) ^ (size2.length() == 0)) {
-            mSizeIcon.setImage(mErrorImage);
-            return;
-        } else if (size1.length() == 0 && size2.length() == 0) {
-            // both sizes are empty: remove the qualifier.
-            mCurrentConfig.setScreenDimensionQualifier(null);
-        } else {
-            ScreenDimensionQualifier qualifier = ScreenDimensionQualifier.getQualifier(size1,
-                    size2);
-
-            if (qualifier != null) {
-                mCurrentConfig.setScreenDimensionQualifier(qualifier);
-            } else {
-                // Failure! Looks like the value is wrong.
-                // we do nothing in this case.
-                return;
-            }
-        }
-
-        // look for a file to open/create
-        onConfigurationChange();
-    }
-
-
-    /**
-     * Looks for a file matching the new {@link FolderConfiguration} and attempts to open it.
-     * <p/>If there is no match, notify the user.
-     */
-    private void onConfigurationChange() {
-        mConfiguredFrameworkRes = mConfiguredProjectRes = null;
-
-        if (mEditedFile == null || mEditedConfig == null) {
-            return;
-        }
-        
-        // get the resources of the file's project.
-        ProjectResources resources = ResourceManager.getInstance().getProjectResources(
-                mEditedFile.getProject());
-        
-        // from the resources, look for a matching file
-        ResourceFile match = null;
-        if (resources != null) {
-            match = resources.getMatchingFile(mEditedFile.getName(),
-                                              ResourceFolderType.LAYOUT,
-                                              mCurrentConfig);
-        }
-
-        if (match != null) {
-            if (match.getFile().equals(mEditedFile) == false) {
-                try {
-                    IDE.openEditor(
-                            getSite().getWorkbenchWindow().getActivePage(),
-                            match.getFile().getIFile());
-
-                    // we're done!
-                    return;
-                } catch (PartInitException e) {
-                    // FIXME: do something!
-                }
-            }
-
-            // at this point, we have not opened a new file.
-
-            // update the configuration icons with the new edited config.
-            setConfiguration(mEditedConfig);
-            
-            // enable the create button if the current and edited config are not equals
-            mCreateButton.setEnabled(mEditedConfig.equals(mCurrentConfig) == false);
-
-            // Even though the layout doesn't change, the config changed, and referenced
-            // resources need to be updated.
-            recomputeLayout();
-        } else {
-            // update the configuration icons with the new edited config.
-            displayConfigError();
-            
-            // enable the Create button
-            mCreateButton.setEnabled(true);
-
-            // display the error.
-            String message = String.format(
-                    "No resources match the configuration\n \n\t%1$s\n \nChange the configuration or create:\n \n\tres/%2$s/%3$s\n \nYou can also click the 'Create' button above.",
-                    mCurrentConfig.toDisplayString(),
-                    mCurrentConfig.getFolderName(ResourceFolderType.LAYOUT),
-                    mEditedFile.getName());
-            showErrorInEditor(message);
-        }
-    }
-
-    private void onThemeChange() {
-        int themeIndex = mThemeCombo.getSelectionIndex();
-        if (themeIndex != -1) {
-            String theme = mThemeCombo.getItem(themeIndex);
-            
-            if (theme.equals(THEME_SEPARATOR)) {
-                mThemeCombo.select(0);
-            }
-
-            recomputeLayout();
-        }
-    }
-
-    /**
-     * Creates a composite with no margin/spacing, and puts a {@link Label} in it with the matching
-     * icon.
-     * @param parent the parent to receive the composite
-     * @return the created {@link Label} object.
-     */
-    private Label createControlComposite(Composite parent, boolean grab) {
-        GridLayout gl;
-
-        Composite composite = new Composite(parent, SWT.NONE);
-        composite.setLayout(gl = new GridLayout(2, false));
-        gl.marginHeight = gl.marginWidth = 0;
-        gl.horizontalSpacing = 0;
-        if (grab) {
-            composite.setLayoutData(
-                    new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL));
-        }
-
-        // create the label
-        Label icon = new Label(composite, SWT.NONE);
-        icon.setImage(mMatchImage);
-
-        return icon;
-    }
-
-    /**
-     * Recomputes the layout with the help of layoutlib.
-     */
-    void recomputeLayout() {
-        try {
-            // check that the resource exists. If the file is opened but the project is closed
-            // or deleted for some reason (changed from outside of eclipse), then this will
-            // return false;
-            if (mEditedFile.exists() == false) {
-                String message = String.format("Resource '%1$s' does not exist.",
-                        mEditedFile.getFullPath().toString());
-
-                showErrorInEditor(message);
-
-                return;
-            }
-
-            IProject iProject = mEditedFile.getProject();
-
-            if (mEditedFile.isSynchronized(IResource.DEPTH_ZERO) == false) {
-                String message = String.format("%1$s is out of sync. Please refresh.",
-                        mEditedFile.getName());
-
-                showErrorInEditor(message);
-
-                // also print it in the error console.
-                AdtPlugin.printErrorToConsole(iProject.getName(), message);
-                return;
-            }
-
-            Sdk currentSdk = Sdk.getCurrent();
-            if (currentSdk != null) {
-                IAndroidTarget target = currentSdk.getTarget(mEditedFile.getProject());
-                if (target == null) {
-                    showErrorInEditor("The project target is not set.");
-                    return;
-                }
-                
-                AndroidTargetData data = currentSdk.getTargetData(target);
-                if (data == null) {
-                    // It can happen that the workspace refreshes while the SDK is loading its
-                    // data, which could trigger a redraw of the opened layout if some resources
-                    // changed while Eclipse is closed.
-                    // In this case data could be null, but this is not an error.
-                    // We can just silently return, as all the opened editors are automatically
-                    // refreshed once the SDK finishes loading.
-                    if (AdtPlugin.getDefault().getSdkLoadStatus() != LoadStatus.LOADING) {
-                        showErrorInEditor(String.format(
-                                "The project target (%s) was not properly loaded.",
-                                target.getName()));
-                    }
-                    return;
-                }
-
-                // check there is actually a model (maybe the file is empty).
-                UiDocumentNode model = getModel();
-
-                if (model.getUiChildren().size() == 0) {
-                    showErrorInEditor("No Xml content. Go to the Outline view and add nodes.");
-                    return;
-                }
-
-                LayoutBridge bridge = data.getLayoutBridge();
-
-                if (bridge.bridge != null) { // bridge can never be null.
-                    ResourceManager resManager = ResourceManager.getInstance();
-    
-                    ProjectResources projectRes = resManager.getProjectResources(iProject);
-                    if (projectRes == null) {
-                        return;
-                    }
-    
-                    // get the resources of the file's project.
-                    if (mConfiguredProjectRes == null) {
-                        // make sure they are loaded
-                        projectRes.loadAll();
-    
-                        // get the project resource values based on the current config
-                        mConfiguredProjectRes = projectRes.getConfiguredResources(mCurrentConfig);
-                    }
-    
-                    // get the framework resources
-                    Map<String, Map<String, IResourceValue>> frameworkResources =
-                        getConfiguredFrameworkResources();
-    
-                    if (mConfiguredProjectRes != null && frameworkResources != null) {
-                        if (mProjectCallback == null) {
-                            mProjectCallback = new ProjectCallback(
-                                    bridge.classLoader, projectRes, iProject);
-                        }
-    
-                        if (mLogger == null) {
-                            mLogger = new ILayoutLog() {
-                                public void error(String message) {
-                                    AdtPlugin.printErrorToConsole(mEditedFile.getName(), message);
-                                }
-    
-                                public void error(Throwable error) {
-                                    String message = error.getMessage();
-                                    if (message == null) {
-                                        message = error.getClass().getName();
-                                    }
-    
-                                    PrintStream ps = new PrintStream(AdtPlugin.getErrorStream());
-                                    error.printStackTrace(ps);
-                                }
-    
-                                public void warning(String message) {
-                                    AdtPlugin.printToConsole(mEditedFile.getName(), message);
-                                }
-                            };
-                        }
-    
-                        // get the selected theme
-                        int themeIndex = mThemeCombo.getSelectionIndex();
-                        if (themeIndex != -1) {
-                            String theme = mThemeCombo.getItem(themeIndex);
-                            
-                            // change the string if it's a custom theme to make sure we can
-                            // differentiate them
-                            if (themeIndex >= mPlatformThemeCount) {
-                                theme = "*" + theme; //$NON-NLS-1$
-                            }
-    
-                            // Compute the layout
-                            UiElementPullParser parser = new UiElementPullParser(getModel());
-                            Rectangle rect = getBounds();
-                            ILayoutResult result = bridge.bridge.computeLayout(parser,
-                                    iProject /* projectKey */,
-                                    rect.width, rect.height, theme,
-                                    mConfiguredProjectRes, frameworkResources, mProjectCallback,
-                                    mLogger);
-    
-                            // update the UiElementNode with the layout info.
-                            if (result.getSuccess() == ILayoutResult.SUCCESS) {
-                                model.setEditData(result.getImage());
-    
-                                updateNodeWithBounds(result.getRootView());
-                            } else {
-                                String message = result.getErrorMessage();
-    
-                                // Reset the edit data for all the nodes.
-                                resetNodeBounds(model);
-    
-                                if (message != null) {
-                                    // set the error in the top element.
-                                    model.setEditData(message);
-                                }
-                            }
-    
-                            model.refreshUi();
-                        }
-                    }
-                } else {
-                    // SDK is loaded but not the layout library!
-                    String message = null;
-                    // check whether the bridge managed to load, or not
-                    if (bridge.status == LoadStatus.LOADING) {
-                        message = String.format(
-                                "Eclipse is loading framework information and the Layout library from the SDK folder.\n%1$s will refresh automatically once the process is finished.",
-                                mEditedFile.getName());
-                    } else {
-                        message = String.format("Eclipse failed to load the framework information and the Layout library!");
-                    }
-                    showErrorInEditor(message);
-                }
-            } else {
-                String message = String.format(
-                        "Eclipse is loading the SDK.\n%1$s will refresh automatically once the process is finished.",
-                        mEditedFile.getName());
-
-                showErrorInEditor(message);
-            }
-        } finally {
-            // no matter the result, we are done doing the recompute based on the latest
-            // resource/code change.
-            mNeedsRecompute = false;
-        }
-    }
-
-    private void showErrorInEditor(String message) {
-        // get the model to display the error directly in the editor
-        UiDocumentNode model = getModel();
-
-        // Reset the edit data for all the nodes.
-        resetNodeBounds(model);
-
-        if (message != null) {
-            // set the error in the top element.
-            model.setEditData(message);
-        }
-
-        model.refreshUi();
-    }
-
-    private void resetNodeBounds(UiElementNode node) {
-        node.setEditData(null);
-
-        List<UiElementNode> children = node.getUiChildren();
-        for (UiElementNode child : children) {
-            resetNodeBounds(child);
-        }
-    }
-
-    private void updateNodeWithBounds(ILayoutViewInfo r) {
-        if (r != null) {
-            // update the node itself, as the viewKey is the XML node in this implementation.
-            Object viewKey = r.getViewKey();
-            if (viewKey instanceof UiElementNode) {
-                Rectangle bounds = new Rectangle(r.getLeft(), r.getTop(),
-                        r.getRight()-r.getLeft(), r.getBottom() - r.getTop());
-
-                ((UiElementNode)viewKey).setEditData(bounds);
-            }
-
-            // and then its children.
-            ILayoutViewInfo[] children = r.getChildren();
-            if (children != null) {
-                for (ILayoutViewInfo child : children) {
-                    updateNodeWithBounds(child);
-                }
-            }
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.layout.LayoutReloadMonitor.ILayoutReloadListener#reloadLayout(boolean, boolean, boolean)
-     *
-     * Called when the file changes triggered a redraw of the layout
-     */
-    public void reloadLayout(boolean codeChange, boolean rChange, boolean resChange) {
-        boolean recompute = rChange;
-
-        if (resChange) {
-            recompute = true;
-
-            // TODO: differentiate between single and multi resource file changed, and whether the resource change affects the cache.
-
-            // force a reparse in case a value XML file changed.
-            mConfiguredProjectRes = null;
-
-            // clear the cache in the bridge in case a bitmap/9-patch changed.
-            IAndroidTarget target = Sdk.getCurrent().getTarget(mEditedFile.getProject());
-            if (target != null) {
-                
-                AndroidTargetData data = Sdk.getCurrent().getTargetData(target);
-                if (data != null) {
-                    LayoutBridge bridge = data.getLayoutBridge();
-        
-                    if (bridge.bridge != null) {
-                        bridge.bridge.clearCaches(mEditedFile.getProject());
-                    }
-                }
-            }
-
-            mParent.getDisplay().asyncExec(mUiUpdateFromResourcesRunnable);
-        }
-
-        if (codeChange) {
-            // only recompute if the custom view loader was used to load some code.
-            if (mProjectCallback != null && mProjectCallback.isUsed()) {
-                mProjectCallback = null;
-                recompute = true;
-            }
-        }
-
-        if (recompute) {
-            mParent.getDisplay().asyncExec(mConditionalRecomputeRunnable);
-        }
-    }
-
-    /**
-     * Responds to a page change that made the Graphical editor page the activated page.
-     */
-    void activated() {
-    	mActive = true;
-        if (mNeedsRecompute) {
-            recomputeLayout();
-        }
-    }
-
-    /**
-     * Responds to a page change that made the Graphical editor page the deactivated page
-     */
-    void deactivated() {
-    	mActive = false;
-    }
-
-    /**
-     * Updates the UI from values in the resources, such as languages, regions, themes, etc...
-     * This must be called from the UI thread.
-     */
-    private void updateUIFromResources() {
-
-        ResourceManager manager = ResourceManager.getInstance();
-
-        ProjectResources frameworkProject = getFrameworkResources();
-
-        mDisableUpdates = true;
-        
-        // Reset stuff
-        int selection = mThemeCombo.getSelectionIndex();
-        mThemeCombo.removeAll();
-        mPlatformThemeCount = 0;
-        mLanguage.removeAll();
-        
-        Set<String> languages = new HashSet<String>();
-        ArrayList<String> themes = new ArrayList<String>();
-        
-        // get the themes, and languages from the Framework.
-        if (frameworkProject != null) {
-            // get the configured resources for the framework
-            Map<String, Map<String, IResourceValue>> frameworResources =
-                getConfiguredFrameworkResources();
-            
-            if (frameworResources != null) {
-                // get the styles.
-                Map<String, IResourceValue> styles = frameworResources.get(
-                        ResourceType.STYLE.getName());
-                
-                
-                // collect the themes out of all the styles.
-                for (IResourceValue value : styles.values()) {
-                    String name = value.getName();
-                    if (name.startsWith("Theme.") || name.equals("Theme")) {
-                        themes.add(value.getName());
-                        mPlatformThemeCount++;
-                    }
-                }
-
-                // sort them and add them to the combo
-                Collections.sort(themes);
-                
-                for (String theme : themes) {
-                    mThemeCombo.add(theme);
-                }
-                
-                mPlatformThemeCount = themes.size();
-                themes.clear();
-            }
-            // now get the languages from the framework.
-            Set<String> frameworkLanguages = frameworkProject.getLanguages();
-            if (frameworkLanguages != null) {
-                languages.addAll(frameworkLanguages);
-            }
-        }
-        
-        // now get the themes and languages from the project.
-        ProjectResources project = null;
-        if (mEditedFile != null) {
-            project = manager.getProjectResources(mEditedFile.getProject());
-
-            // in cases where the opened file is not linked to a project, this could be null.
-            if (project != null) {
-                // get the configured resources for the project 
-                if (mConfiguredProjectRes == null) {
-                    // make sure they are loaded
-                    project.loadAll();
-
-                    // get the project resource values based on the current config
-                    mConfiguredProjectRes = project.getConfiguredResources(mCurrentConfig);
-                }
-                
-                if (mConfiguredProjectRes != null) {
-                    // get the styles.
-                    Map<String, IResourceValue> styleMap = mConfiguredProjectRes.get(
-                            ResourceType.STYLE.getName());
-                    
-                    if (styleMap != null) {
-                        // collect the themes out of all the styles, ie styles that extend,
-                        // directly or indirectly a platform theme.
-                        for (IResourceValue value : styleMap.values()) {
-                            if (isTheme(value, styleMap)) {
-                                themes.add(value.getName());
-                            }
-                        }
-
-                        // sort them and add them the to the combo.
-                        if (mPlatformThemeCount > 0 && themes.size() > 0) {
-                            mThemeCombo.add(THEME_SEPARATOR);
-                        }
-                        
-                        Collections.sort(themes);
-                        
-                        for (String theme : themes) {
-                            mThemeCombo.add(theme);
-                        }
-                    }
-                }
-
-                // now get the languages from the project.
-                Set<String> projectLanguages = project.getLanguages();
-                if (projectLanguages != null) {
-                    languages.addAll(projectLanguages);
-                }
-            }
-        }
-
-        // add the languages to the Combo
-        for (String language : languages) {
-            mLanguage.add(language);
-        }
-        
-        mDisableUpdates = false;
-
-        // and update the Region UI based on the current language
-        updateRegionUi(project, frameworkProject);
-
-        // handle default selection of themes
-        if (mThemeCombo.getItemCount() > 0) {
-            mThemeCombo.setEnabled(true);
-            if (selection == -1) {
-                selection = 0;
-            }
-
-            if (mThemeCombo.getItemCount() <= selection) {
-                mThemeCombo.select(0);
-            } else {
-                mThemeCombo.select(selection);
-            }
-        } else {
-            mThemeCombo.setEnabled(false);
-        }
-    }
-
-    /**
-     * Returns whether the given <var>style</var> is a theme.
-     * This is done by making sure the parent is a theme.
-     * @param value the style to check
-     * @param styleMap the map of styles for the current project. Key is the style name.
-     * @return True if the given <var>style</var> is a theme.
-     */
-    private boolean isTheme(IResourceValue value, Map<String, IResourceValue> styleMap) {
-        if (value instanceof IStyleResourceValue) {
-            IStyleResourceValue style = (IStyleResourceValue)value;
-            
-            boolean frameworkStyle = false;
-            String parentStyle = style.getParentStyle();
-            if (parentStyle == null) {
-                // if there is no specified parent style we look an implied one.
-                // For instance 'Theme.light' is implied child style of 'Theme',
-                // and 'Theme.light.fullscreen' is implied child style of 'Theme.light'
-                String name = style.getName();
-                int index = name.lastIndexOf('.');
-                if (index != -1) {
-                    parentStyle = name.substring(0, index);
-                }
-            } else {
-                // remove the useless @ if it's there
-                if (parentStyle.startsWith("@")) {
-                    parentStyle = parentStyle.substring(1);
-                }
-                
-                // check for framework identifier.
-                if (parentStyle.startsWith("android:")) {
-                    frameworkStyle = true;
-                    parentStyle = parentStyle.substring("android:".length());
-                }
-                
-                // at this point we could have the format style/<name>. we want only the name
-                if (parentStyle.startsWith("style/")) {
-                    parentStyle = parentStyle.substring("style/".length());
-                }
-            }
-
-            if (frameworkStyle) {
-                // if the parent is a framework style, it has to be 'Theme' or 'Theme.*'
-                return parentStyle.equals("Theme") || parentStyle.startsWith("Theme.");
-            } else {
-                // if it's a project style, we check this is a theme.
-                value = styleMap.get(parentStyle);
-                if (value != null) {
-                    return isTheme(value, styleMap);
-                }
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Update the Region UI widget based on the current language selection
-     * @param projectResources the project resources or {@code null}.
-     * @param frameworkResources the framework resource or {@code null}
-     */
-    private void updateRegionUi(ProjectResources projectResources,
-            ProjectResources frameworkResources) {
-        if (projectResources == null && mEditedFile != null) {
-            projectResources = ResourceManager.getInstance().getProjectResources(
-                    mEditedFile.getProject());
-        }
-
-        if (frameworkResources == null) {
-            frameworkResources = getFrameworkResources();
-        }
-
-        String currentLanguage = mLanguage.getText();
-
-        Set<String> set = null;
-
-        if (projectResources != null) {
-            set = projectResources.getRegions(currentLanguage);
-        }
-
-        if (frameworkResources != null) {
-            if (set != null) {
-                Set<String> set2 = frameworkResources.getRegions(currentLanguage);
-                set.addAll(set2);
-            } else {
-                set = frameworkResources.getRegions(currentLanguage);
-            }
-        }
-
-        if (set != null) {
-            mDisableUpdates = true;
-
-            mRegion.removeAll();
-            for (String region : set) {
-                mRegion.add(region);
-            }
-
-            mDisableUpdates = false;
-        }
-    }
-    
-    private Map<String, Map<String, IResourceValue>> getConfiguredFrameworkResources() {
-        if (mConfiguredFrameworkRes == null) {
-            ProjectResources frameworkRes = getFrameworkResources();
-
-            if (frameworkRes == null) {
-                AdtPlugin.log(IStatus.ERROR, "Failed to get ProjectResource for the framework");
-            }
-
-            // get the framework resource values based on the current config
-            mConfiguredFrameworkRes = frameworkRes.getConfiguredResources(mCurrentConfig);
-        }
-        
-        return mConfiguredFrameworkRes;
-    }
-
-    /**
-     * Returns the selection synchronizer object.
-     * The synchronizer can be used to sync the selection of 2 or more EditPartViewers.
-     * <p/>
-     * This is changed from protected to public so that the outline can use it.
-     *
-     * @return the synchronizer
-     */
-    @Override
-    public SelectionSynchronizer getSelectionSynchronizer() {
-        return super.getSelectionSynchronizer();
-    }
-
-    /**
-     * Returns the edit domain.
-     * <p/>
-     * This is changed from protected to public so that the outline can use it.
-     *
-     * @return the edit domain
-     */
-    @Override
-    public DefaultEditDomain getEditDomain() {
-        return super.getEditDomain();
-    }
-
-    /**
-     * Creates a new layout file from the specificed {@link FolderConfiguration}.
-     */
-    private void createAlternateLayout(final FolderConfiguration config) {
-        new Job("Create Alternate Resource") {
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                // get the folder name
-                String folderName = config.getFolderName(ResourceFolderType.LAYOUT);
-                try {
-                    
-                    // look to see if it exists.
-                    // get the res folder
-                    IFolder res = (IFolder)mEditedFile.getParent().getParent();
-                    String path = res.getLocation().toOSString();
-                    
-                    File newLayoutFolder = new File(path + File.separator + folderName);
-                    if (newLayoutFolder.isFile()) {
-                        // this should not happen since aapt would have complained
-                        // before, but if one disable the automatic build, this could
-                        // happen.
-                        String message = String.format("File 'res/%1$s' is in the way!",
-                                folderName);
-                        
-                        AdtPlugin.displayError("Layout Creation", message);
-                        
-                        return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID, message);
-                    } else if (newLayoutFolder.exists() == false) {
-                        // create it.
-                        newLayoutFolder.mkdir();
-                    }
-                    
-                    // now create the file
-                    File newLayoutFile = new File(newLayoutFolder.getAbsolutePath() +
-                                File.separator + mEditedFile.getName());
-
-                    newLayoutFile.createNewFile();
-                    
-                    InputStream input = mEditedFile.getContents();
-                    
-                    FileOutputStream fos = new FileOutputStream(newLayoutFile);
-                    
-                    byte[] data = new byte[512];
-                    int count;
-                    while ((count = input.read(data)) != -1) {
-                        fos.write(data, 0, count);
-                    }
-                    
-                    input.close();
-                    fos.close();
-                    
-                    // refreshes the res folder to show up the new
-                    // layout folder (if needed) and the file.
-                    // We use a progress monitor to catch the end of the refresh
-                    // to trigger the edit of the new file.
-                    res.refreshLocal(IResource.DEPTH_INFINITE, new IProgressMonitor() {
-                        public void done() {
-                            mCurrentConfig.set(config);
-                            mParent.getDisplay().asyncExec(new Runnable() {
-                                public void run() {
-                                    onConfigurationChange();
-                                }
-                            });
-                        }
-
-                        public void beginTask(String name, int totalWork) {
-                            // pass
-                        }
-
-                        public void internalWorked(double work) {
-                            // pass
-                        }
-
-                        public boolean isCanceled() {
-                            // pass
-                            return false;
-                        }
-
-                        public void setCanceled(boolean value) {
-                            // pass
-                        }
-
-                        public void setTaskName(String name) {
-                            // pass
-                        }
-
-                        public void subTask(String name) {
-                            // pass
-                        }
-
-                        public void worked(int work) {
-                            // pass
-                        }
-                    });
-                } catch (IOException e2) {
-                    String message = String.format(
-                            "Failed to create File 'res/%1$s/%2$s' : %3$s",
-                            folderName, mEditedFile.getName(), e2.getMessage());
-                    
-                    AdtPlugin.displayError("Layout Creation", message);
-                    
-                    return new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                            message, e2);
-                } catch (CoreException e2) {
-                    String message = String.format(
-                            "Failed to create File 'res/%1$s/%2$s' : %3$s",
-                            folderName, mEditedFile.getName(), e2.getMessage());
-                    
-                    AdtPlugin.displayError("Layout Creation", message);
-
-                    return e2.getStatus();
-                }
-                
-                return Status.OK_STATUS;
-
-            }
-        }.schedule();
-    }
-    
-    /**
-     * Returns a {@link ProjectResources} for the framework resources.
-     * @return the framework resources or null if not found.
-     */
-    private ProjectResources getFrameworkResources() {
-        if (mEditedFile != null) {
-            Sdk currentSdk = Sdk.getCurrent();
-            if (currentSdk != null) {
-                IAndroidTarget target = currentSdk.getTarget(mEditedFile.getProject());
-    
-                if (target != null) {
-                    AndroidTargetData data = currentSdk.getTargetData(target);
-                    
-                    if (data != null) {
-                        return data.getFrameworkResources();
-                    }
-                }
-            }
-        }
-
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutConstants.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutConstants.java
deleted file mode 100644
index d4ec5e1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutConstants.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-/**
- * A bunch of constants that map to either:
- * <ul>
- * <li>Android Layouts XML element names (Linear, Relative, Absolute, etc.)
- * <li>Attributes for layout XML elements. 
- * <li>Values for attributes.
- * </ul>
- */
-public class LayoutConstants {
-
-    public static final String RELATIVE_LAYOUT = "RelativeLayout";      //$NON-NLS-1$
-    public static final String LINEAR_LAYOUT   = "LinearLayout";        //$NON-NLS-1$
-    public static final String ABSOLUTE_LAYOUT = "AbsoluteLayout";      //$NON-NLS-1$
-
-    public static final String ATTR_TEXT = "text";                      //$NON-NLS-1$
-    public static final String ATTR_ID = "id";                          //$NON-NLS-1$
-
-    public static final String ATTR_LAYOUT_HEIGHT = "layout_height";    //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_WIDTH = "layout_width";      //$NON-NLS-1$
-
-    public static final String ATTR_LAYOUT_ALIGN_PARENT_TOP = "layout_alignParentTop"; //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_ALIGN_PARENT_BOTTOM = "layout_alignParentBottom"; //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_ALIGN_PARENT_LEFT = "layout_alignParentLeft";//$NON-NLS-1$
-    public static final String ATTR_LAYOUT_ALIGN_PARENT_RIGHT = "layout_alignParentRight";   //$NON-NLS-1$
-    
-    public static final String ATTR_LAYOUT_ALIGN_BASELINE = "layout_alignBaseline"; //$NON-NLS-1$
-
-    public static final String ATTR_LAYOUT_CENTER_VERTICAL = "layout_centerVertical"; //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_CENTER_HORIZONTAL = "layout_centerHorizontal"; //$NON-NLS-1$
-    
-    public static final String ATTR_LAYOUT_TO_RIGHT_OF = "layout_toRightOf";    //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_TO_LEFT_OF = "layout_toLeftOf";      //$NON-NLS-1$
-    
-    public static final String ATTR_LAYOUT_BELOW = "layout_below";              //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_ABOVE = "layout_above";              //$NON-NLS-1$
-    
-    public static final String ATTR_LAYOUT_Y = "layout_y";                      //$NON-NLS-1$
-    public static final String ATTR_LAYOUT_X = "layout_x";                      //$NON-NLS-1$
-
-    public static final String VALUE_WRAP_CONTENT = "wrap_content";             //$NON-NLS-1$
-    public static final String VALUE_FILL_PARENT = "fill_parent";               //$NON-NLS-1$
-    public static final String VALUE_TRUE = "true";                             //$NON-NLS-1$
-    public static final String VALUE_N_DIP = "%ddip";                           //$NON-NLS-1$
-
-    private LayoutConstants() {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutContentAssist.java
deleted file mode 100644
index 9f39495..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutContentAssist.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidContentAssist;
-
-/**
- * Content Assist Processor for /res/layout XML files
- */
-class LayoutContentAssist extends AndroidContentAssist {
-
-    /**
-     * Constructor for LayoutContentAssist 
-     */
-    public LayoutContentAssist() {
-        super(AndroidTargetData.DESCRIPTOR_LAYOUT);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutCreatorDialog.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutCreatorDialog.java
deleted file mode 100644
index c4a8f5c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutCreatorDialog.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.ConfigurationState;
-
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.TrayDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * Dialog to choose a non existing {@link FolderConfiguration}.
- */
-class LayoutCreatorDialog extends TrayDialog {
-
-    private ConfigurationSelector mSelector;
-    private Composite mStatusComposite;
-    private Label mStatusLabel; 
-    private Label mStatusImage;
-
-    private final FolderConfiguration mConfig = new FolderConfiguration();
-    private final String mFileName;
-
-    /**
-     * Creates a dialog, and init the UI from a {@link FolderConfiguration}.
-     * @param parentShell the parent {@link Shell}.
-     * @param config The starting configuration.
-     */
-    LayoutCreatorDialog(Shell parentShell, String fileName, FolderConfiguration config) {
-        super(parentShell);
-
-        mFileName = fileName;        
-        // FIXME: add some data to know what configurations already exist. 
-        mConfig.set(config);
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite top = new Composite(parent, SWT.NONE);
-        top.setLayoutData(new GridData());
-        top.setLayout(new GridLayout(1, false));
-
-        new Label(top, SWT.NONE).setText(
-                String.format("Configuration for the alternate version of %1$s", mFileName));
-        
-        mSelector = new ConfigurationSelector(top);
-        mSelector.setConfiguration(mConfig);
-        
-        // parent's layout is a GridLayout as specified in the javadoc.
-        GridData gd = new GridData();
-        gd.widthHint = ConfigurationSelector.WIDTH_HINT;
-        gd.heightHint = ConfigurationSelector.HEIGHT_HINT;
-        mSelector.setLayoutData(gd);
-        
-        // add a listener to check on the validity of the FolderConfiguration as
-        // they are built.
-        mSelector.setOnChangeListener(new Runnable() {
-            public void run() {
-                ConfigurationState state = mSelector.getState();
-                
-                switch (state) {
-                    case OK:
-                        mSelector.getConfiguration(mConfig);
-
-                        resetStatus();
-                        mStatusImage.setImage(null);
-                        getButton(IDialogConstants.OK_ID).setEnabled(true);
-                        break;
-                    case INVALID_CONFIG:
-                        ResourceQualifier invalidQualifier = mSelector.getInvalidQualifier();
-                        mStatusLabel.setText(String.format(
-                                "Invalid Configuration: %1$s has no filter set.",
-                                invalidQualifier.getName()));
-                        mStatusImage.setImage(IconFactory.getInstance().getIcon("warning")); //$NON-NLS-1$
-                        getButton(IDialogConstants.OK_ID).setEnabled(false);
-                        break;
-                    case REGION_WITHOUT_LANGUAGE:
-                        mStatusLabel.setText(
-                                "The Region qualifier requires the Language qualifier.");
-                        mStatusImage.setImage(IconFactory.getInstance().getIcon("warning")); //$NON-NLS-1$
-                        getButton(IDialogConstants.OK_ID).setEnabled(false);
-                        break;
-                }
-
-                // need to relayout, because of the change in size in mErrorImage.
-                mStatusComposite.layout();
-            }
-        });
-
-        mStatusComposite = new Composite(top, SWT.NONE);
-        mStatusComposite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        GridLayout gl = new GridLayout(2, false);
-        mStatusComposite.setLayout(gl);
-        gl.marginHeight = gl.marginWidth = 0;
-
-        mStatusImage = new Label(mStatusComposite, SWT.NONE);
-        mStatusLabel = new Label(mStatusComposite, SWT.NONE);
-        mStatusLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        resetStatus();
-
-        return top;
-    }
-    
-    public void getConfiguration(FolderConfiguration config) {
-        config.set(mConfig);
-    }
-    
-    /**
-     * resets the status label to show the file that will be created.
-     */
-    private void resetStatus() {
-        mStatusLabel.setText(String.format("New File: res/%1$s/%2$s",
-                mConfig.getFolderName(ResourceFolderType.LAYOUT), mFileName));
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutEditor.java
deleted file mode 100644
index 880ee2b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutEditor.java
+++ /dev/null
@@ -1,411 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.EclipseUiHelper;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolder;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.ui.tree.UiActions;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.gef.ui.parts.TreeViewer;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IPartListener;
-import org.eclipse.ui.IShowEditorInput;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchPartSite;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-import org.w3c.dom.Document;
-
-/**
- * Multi-page form editor for /res/layout XML files. 
- */
-public class LayoutEditor extends AndroidEditor implements IShowEditorInput, IPartListener {
-
-    public static final String ID = AndroidConstants.EDITORS_NAMESPACE + ".layout.LayoutEditor"; //$NON-NLS-1$
-
-    /** Root node of the UI element hierarchy */
-    private UiDocumentNode mUiRootNode;
-    
-    private GraphicalLayoutEditor mGraphicalEditor;
-    private int mGraphicalEditorIndex;
-    /** Implementation of the {@link IContentOutlinePage} for this editor */
-    private UiContentOutlinePage mOutline;
-    /** Custom implementation of {@link IPropertySheetPage} for this editor */
-    private UiPropertySheetPage mPropertyPage;
-
-    private UiEditorActions mUiEditorActions;
-   
-    /**
-     * Creates the form editor for resources XML files.
-     */
-    public LayoutEditor() {
-        super();
-    }
-
-    /**
-     * @return The root node of the UI element hierarchy
-     */
-    @Override
-    public UiDocumentNode getUiRootNode() {
-        return mUiRootNode;
-    }
-
-    // ---- Base Class Overrides ----
-
-    @Override
-    public void dispose() {
-        getSite().getPage().removePartListener(this);
-
-        super.dispose();
-    }
-    
-    /**
-     * Save the XML.
-     * <p/>
-     * The actual save operation is done in the super class by committing
-     * all data to the XML model and then having the Structured XML Editor
-     * save the XML.
-     * <p/>
-     * Here we just need to tell the graphical editor that the model has
-     * been saved.
-     */
-    @Override
-    public void doSave(IProgressMonitor monitor) {
-        super.doSave(monitor);
-        if (mGraphicalEditor != null) {
-            mGraphicalEditor.doSave(monitor);
-        }
-    }
-    
-    /**
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p/>
-     * Save-As is a valid operation for the ManifestEditor since it acts on a
-     * single source file. 
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return true;
-    }
-
-    /**
-     * Create the various form pages.
-     */
-    @Override
-    protected void createFormPages() {
-        try {
-            // The graphical layout editor is now enabled by default.
-            // In case there's an issue we provide a way to disable it using an
-            // env variable.
-            if (System.getenv("ANDROID_DISABLE_LAYOUT") == null) {
-                if (mGraphicalEditor == null) {
-                    mGraphicalEditor = new GraphicalLayoutEditor(this);
-                    mGraphicalEditorIndex = addPage(mGraphicalEditor, getEditorInput());
-                    setPageText(mGraphicalEditorIndex, mGraphicalEditor.getTitle());
-                } else {
-                    mGraphicalEditor.reloadEditor();
-                }
-
-                // update the config based on the opened file.
-                IEditorInput input = getEditorInput();
-                if (input instanceof FileEditorInput) {
-                    FileEditorInput fileInput = (FileEditorInput)input;
-                    ResourceFolder resFolder = ResourceManager.getInstance().getResourceFolder(
-                            fileInput.getFile());
-                    if (resFolder != null) {
-                        mGraphicalEditor.editNewFile(resFolder.getConfiguration());
-                    }
-                }
-
-                // put in place the listener to handle layout recompute only when needed.
-                getSite().getPage().addPartListener(this);
-            }
-        } catch (PartInitException e) {
-            AdtPlugin.log(e, "Error creating nested page"); //$NON-NLS-1$
-        }
-     }
-
-    /* (non-java doc)
-     * Change the tab/title name to include the name of the layout.
-     */
-    @Override
-    protected void setInput(IEditorInput input) {
-        super.setInput(input);
-        handleNewInput(input);
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.part.EditorPart#setInputWithNotify(org.eclipse.ui.IEditorInput)
-     */
-    @Override
-    protected void setInputWithNotify(IEditorInput input) {
-        super.setInputWithNotify(input);
-        handleNewInput(input);
-    }
-    
-    /**
-     * Called to replace the current {@link IEditorInput} with another one.
-     * <p/>This is used when {@link MatchingStrategy} returned <code>true</code> which means we're
-     * opening a different configuration of the same layout.
-     */
-    public void showEditorInput(IEditorInput editorInput) {
-        // save the current editor input.
-        doSave(new NullProgressMonitor());
-        
-        // get the current page
-        int currentPage = getActivePage();
-        
-        // remove the pages, except for the graphical editor, which will be dynamically adapted
-        // to the new model.
-        // page after the graphical editor:
-        int count = getPageCount();
-        for (int i = count - 1 ; i > mGraphicalEditorIndex ; i--) {
-            removePage(i);
-        }
-        // pages before the graphical editor
-        for (int i = mGraphicalEditorIndex - 1 ; i >= 0 ; i--) {
-            removePage(i);
-        }
-        
-        // set the current input.
-        setInputWithNotify(editorInput);
-        
-        // re-create or reload the pages with the default page shown as the previous active page.
-        createAndroidPages();
-        selectDefaultPage(Integer.toString(currentPage));
-
-        // update the outline
-        if (mOutline != null && mGraphicalEditor != null) {
-            mOutline.reloadModel();
-        }
-    }
-    
-    /**
-     * Processes the new XML Model, which XML root node is given.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    @Override
-    protected void xmlModelChanged(Document xml_doc) {
-        // init the ui root on demand
-        initUiRootNode(false /*force*/);
-
-        mUiRootNode.loadFromXmlNode(xml_doc);
-
-        // update the model first, since it is used by the viewers.
-        super.xmlModelChanged(xml_doc);
-        
-        if (mGraphicalEditor != null) {
-            mGraphicalEditor.onXmlModelChanged();
-        }
-        
-        if (mOutline != null) {
-            mOutline.reloadModel();
-        }
-    }
-    
-    /* (non-java doc)
-     * Returns the IContentOutlinePage when asked for it.
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    public Object getAdapter(Class adapter) {
-        // for the outline, force it to come from the Graphical Editor.
-        // This fixes the case where a layout file is opened in XML view first and the outline
-        // gets stuck in the XML outline.
-        if (IContentOutlinePage.class == adapter && mGraphicalEditor != null) {
-            if (mOutline == null) {
-                mOutline = new UiContentOutlinePage(mGraphicalEditor, new TreeViewer());
-            }
-            
-            return mOutline;
-        }
-        
-        if (IPropertySheetPage.class == adapter && mGraphicalEditor != null) {
-            if (mPropertyPage == null) {
-                mPropertyPage = new UiPropertySheetPage();
-            }
-            
-            return mPropertyPage;
-        }
-
-        // return default
-        return super.getAdapter(adapter);
-    }
-    
-    @Override
-    protected void pageChange(int newPageIndex) {
-        super.pageChange(newPageIndex);
-        
-        if (mGraphicalEditor != null && newPageIndex == mGraphicalEditorIndex) {
-            mGraphicalEditor.activated();
-        }
-    }
-    
-    // ----- IPartListener Methods ----
-    
-    public void partActivated(IWorkbenchPart part) {
-        if (part == this) {
-            if (mGraphicalEditor != null && getActivePage() == mGraphicalEditorIndex) {
-                mGraphicalEditor.activated();
-            }
-        }
-    }
-
-    public void partBroughtToTop(IWorkbenchPart part) {
-        partActivated(part);
-    }
-
-    public void partClosed(IWorkbenchPart part) {
-        // pass
-    }
-
-    public void partDeactivated(IWorkbenchPart part) {
-        if (part == this) {
-            if (mGraphicalEditor != null && getActivePage() == mGraphicalEditorIndex) {
-                mGraphicalEditor.deactivated();
-            }
-        }
-    }
-
-    public void partOpened(IWorkbenchPart part) {
-        EclipseUiHelper.showView(EclipseUiHelper.CONTENT_OUTLINE_VIEW_ID, false /* activate */);
-        EclipseUiHelper.showView(EclipseUiHelper.PROPERTY_SHEET_VIEW_ID, false /* activate */);
-    }
-    
-    public class UiEditorActions extends UiActions {
-
-        @Override
-        protected UiDocumentNode getRootNode() {
-            return mUiRootNode;
-        }
-
-        // Select the new item
-        @Override
-        protected void selectUiNode(UiElementNode uiNodeToSelect) {
-            mGraphicalEditor.selectModel(uiNodeToSelect);
-        }
-
-        @Override
-        public void commitPendingXmlChanges() {
-            // Pass. There is nothing to commit before the XML is changed here.
-        }
-    }
-    
-    public UiEditorActions getUiEditorActions() {
-        if (mUiEditorActions == null) {
-            mUiEditorActions = new UiEditorActions();
-        }
-        return mUiEditorActions;
-    }
-    
-    // ---- Local Methods ----
-    
-    /**
-     * Returns true if the Graphics editor page is visible.
-     * This <b>must</b> be called from the UI thread.
-     */
-    boolean isGraphicalEditorActive() {
-        IWorkbenchPartSite workbenchSite = getSite();
-        IWorkbenchPage workbenchPage = workbenchSite.getPage();
-        
-        // check if the editor is visible in the workbench page
-        if (workbenchPage.isPartVisible(this)) {
-            // and then if the page of the editor is visible (not to be confused with
-            // the workbench page)
-            return mGraphicalEditorIndex == getActivePage();
-        }
-        
-        return false;
-    }
-
-    @Override
-    protected void initUiRootNode(boolean force) {
-        // The root UI node is always created, even if there's no corresponding XML node.
-        if (mUiRootNode == null || force) {
-            // get the target data from the opened file (and its project)
-            AndroidTargetData data = getTargetData();
-            
-            Document doc = null;
-            if (mUiRootNode != null) {
-                doc = mUiRootNode.getXmlDocument();
-            }
-            
-            DocumentDescriptor desc;
-            if (data == null) {
-                desc = new DocumentDescriptor("temp", null /*children*/);
-            } else {
-                desc = data.getLayoutDescriptors().getDescriptor();
-            }
-
-            // get the descriptors from the data.
-            mUiRootNode = (UiDocumentNode) desc.createUiNode();
-            mUiRootNode.setEditor(this);
-
-            onDescriptorsChanged(doc);
-        }
-    }
-    
-    private void onDescriptorsChanged(Document document) {
-        if (document != null) {
-            mUiRootNode.loadFromXmlNode(document);
-        } else {
-            mUiRootNode.reloadFromXmlNode(mUiRootNode.getXmlDocument());
-        }
-        
-        if (mOutline != null) {
-            mOutline.reloadModel();
-        }
-        
-        if (mGraphicalEditor != null) {
-            mGraphicalEditor.reloadEditor();
-            mGraphicalEditor.reloadPalette();
-            mGraphicalEditor.recomputeLayout();
-        }
-    }
-
-    /**
-     * Handles a new input, and update the part name.
-     * @param input the new input.
-     */
-    private void handleNewInput(IEditorInput input) {
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput) input;
-            IFile file = fileInput.getFile();
-            setPartName(String.format("%1$s",
-                    file.getName()));
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutReloadMonitor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutReloadMonitor.java
deleted file mode 100644
index cf20288..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutReloadMonitor.java
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolder;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IResourceEventListener;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResourceDelta;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Map.Entry;
-
-/**
- * Monitor for file changes triggering a layout redraw.
- */
-public final class LayoutReloadMonitor implements IFileListener, IResourceEventListener {
-    
-    // singleton, enforced by private constructor.
-    private final static LayoutReloadMonitor sThis = new LayoutReloadMonitor();
-    
-    /**
-     * Map of listeners by IProject.
-     */
-    private final Map<IProject, List<ILayoutReloadListener>> mListenerMap =
-        new HashMap<IProject, List<ILayoutReloadListener>>();
-    
-    private final static int CHANGE_CODE = 0;
-    private final static int CHANGE_RESOURCES = 1;
-    private final static int CHANGE_R = 2;
-    private final static int CHANGE_COUNT = 3;
-    /**
-     * List of projects having received a file change. the boolean[] contains 3 values:
-     * <ul><li>CHANGE_CODE: code change flag.</li>
-     * <li>CHANGE_RESOURCES: resource change flag.</li>
-     * <li>CHANGE_R: R clas change flag</li></ul>
-     */
-    private final Map<IProject, boolean[]> mChangedProjects = new HashMap<IProject, boolean[]>();
-    
-    /**
-     * Classes which implement this interface provide a method to respond to resource changes
-     * triggering a layout redraw
-     */
-    public interface ILayoutReloadListener {
-        /**
-         * Sent when the layout needs to be redrawn
-         * @param codeChange The trigger happened due to a code change.
-         * @param rChange The trigger happened due to a change in the R class.
-         * @param resChange The trigger happened due to a resource change.
-         */
-        void reloadLayout(boolean codeChange, boolean rChange, boolean resChange); 
-    }
-    
-    /**
-     * Returns the single instance of {@link LayoutReloadMonitor}.
-     */
-    public static LayoutReloadMonitor getMonitor() {
-        return sThis;
-    }
-    
-    private LayoutReloadMonitor() {
-        ResourceMonitor monitor = ResourceMonitor.getMonitor();
-        monitor.addFileListener(this, IResourceDelta.ADDED | IResourceDelta.CHANGED);
-        monitor.addResourceEventListener(this);
-    }
-    
-    /**
-     * Adds a listener for a given {@link IProject}.
-     * @param project
-     * @param listener
-     */
-    public void addListener(IProject project, ILayoutReloadListener listener) {
-        synchronized (mListenerMap) {
-            List<ILayoutReloadListener> list = mListenerMap.get(project);
-            if (list == null) {
-                list = new ArrayList<ILayoutReloadListener>();
-                mListenerMap.put(project, list);
-            }
-            
-            list.add(listener);
-        }
-    }
-    
-    /**
-     * Removes a listener for a given {@link IProject}.
-     * @param project
-     * @param listener
-     */
-    public void removeListener(IProject project, ILayoutReloadListener listener) {
-        synchronized (mListenerMap) {
-            List<ILayoutReloadListener> list = mListenerMap.get(project);
-            if (list != null) {
-                list.remove(listener);
-            }
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener#fileChanged(org.eclipse.core.resources.IFile, org.eclipse.core.resources.IMarkerDelta[], int)
-     * 
-     * Callback for ResourceMonitor.IFileListener. Called when a file changed.
-     * This records the changes for each project, but does not notify listeners.
-     * @see #resourceChangeEventEnd
-     */
-    public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind) {
-        // get the file project
-        IProject project = file.getProject();
-
-        // if this project has already been marked as modified, we do nothing.
-        boolean[] changeFlags = mChangedProjects.get(project);
-        if (changeFlags != null && changeFlags[CHANGE_CODE] && changeFlags[CHANGE_RESOURCES] &&
-                changeFlags[CHANGE_R]) {
-            return;
-        }
-        
-        // now check that the file is *NOT* a layout file (those automatically trigger a layout
-        // reload and we don't want to do it twice.
-        ResourceFolder resFolder = ResourceManager.getInstance().getResourceFolder(file);
-        if (resFolder != null) {
-            if (resFolder.getType() != ResourceFolderType.LAYOUT) {
-                // this is a resource change!
-                if (changeFlags == null) {
-                    changeFlags = new boolean[CHANGE_COUNT];
-                    mChangedProjects.put(project, changeFlags);
-                }
-    
-                changeFlags[CHANGE_RESOURCES] = true;
-            }
-        } else if (AndroidConstants.EXT_CLASS.equals(file.getFileExtension())) {
-            if (file.getName().matches("R[\\$\\.](.*)")) {
-                // this is a R change!
-                if (changeFlags == null) {
-                    changeFlags = new boolean[CHANGE_COUNT];
-                    mChangedProjects.put(project, changeFlags);
-                }
-
-                changeFlags[CHANGE_R] = true;
-            } else {
-                // this is a code change!
-                if (changeFlags == null) {
-                    changeFlags = new boolean[CHANGE_COUNT];
-                    mChangedProjects.put(project, changeFlags);
-                }
-
-                changeFlags[CHANGE_CODE] = true;
-            }
-        }
-    }
-    
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IResourceEventListener#resourceChangeEventStart()
-     * 
-     * Callback for ResourceMonitor.IResourceEventListener. Called at the beginning of a resource
-     * change event. This is called once, while fileChanged can be called several times.
-     * 
-     */
-    public void resourceChangeEventStart() {
-        // nothing to be done here, it all happens in the resourceChangeEventEnd
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IResourceEventListener#resourceChangeEventEnd()
-     * 
-     * Callback for ResourceMonitor.IResourceEventListener. Called at the end of a resource
-     * change event. This is where we notify the listeners.
-     */
-    public void resourceChangeEventEnd() {
-        // for each IProject that was changed, we notify all the listeners.
-        synchronized (mListenerMap) {
-            for (Entry<IProject, boolean[]> project : mChangedProjects.entrySet()) {
-                List<ILayoutReloadListener> listeners = mListenerMap.get(project.getKey());
-                
-                boolean[] flags = project.getValue();
-                
-                if (listeners != null) {
-                    for (ILayoutReloadListener listener : listeners) {
-                        listener.reloadLayout(flags[CHANGE_CODE], flags[CHANGE_R],
-                                flags[CHANGE_RESOURCES]);
-                    }
-                }
-            }
-        }
-        
-        // empty the list.
-        mChangedProjects.clear();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutSourceViewerConfig.java
deleted file mode 100644
index 1aa1f4c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/LayoutSourceViewerConfig.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-
-import com.android.ide.eclipse.editors.AndroidSourceViewerConfig;
-
-/**
- * Source Viewer Configuration that calls in LayoutContentAssist.
- */
-public class LayoutSourceViewerConfig extends AndroidSourceViewerConfig {
-
-    public LayoutSourceViewerConfig() {
-        super(new LayoutContentAssist());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/MatchingStrategy.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/MatchingStrategy.java
deleted file mode 100644
index bb075c2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/MatchingStrategy.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolder;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorMatchingStrategy;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-
-/**
- * Matching strategy for the Layout Editor. This is used to open all configurations of a layout
- * in the same editor.
- */
-public class MatchingStrategy implements IEditorMatchingStrategy {
-
-    public boolean matches(IEditorReference editorRef, IEditorInput input) {
-        // first check that the file being opened is a layout file.
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput)input;
-            
-            // get the IFile object and check it's in one of the layout folders.
-            IFile iFile = fileInput.getFile();
-            ResourceFolder resFolder = ResourceManager.getInstance().getResourceFolder(iFile);
-            
-            // if it's a layout, we know check the name of the fileInput against the name of the
-            // file being currently edited by the editor since those are independent of the config.
-            if (resFolder != null && resFolder.getType() == ResourceFolderType.LAYOUT) {
-                try {
-                    IEditorInput editorInput = editorRef.getEditorInput();
-                    if (editorInput instanceof FileEditorInput) {
-                        FileEditorInput editorFileInput = (FileEditorInput)editorInput;
-                        IFile editorIFile = editorFileInput.getFile();
-                        
-                        return editorIFile.getProject().equals(iFile.getProject())
-                            && editorIFile.getName().equals(iFile.getName());
-                    }
-                } catch (PartInitException e) {
-                    // we do nothing, we'll just return false.
-                }
-            }
-        }
-        return false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/PaletteFactory.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/PaletteFactory.java
deleted file mode 100644
index 94df28f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/PaletteFactory.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-
-import org.eclipse.gef.palette.PaletteDrawer;
-import org.eclipse.gef.palette.PaletteGroup;
-import org.eclipse.gef.palette.PaletteRoot;
-import org.eclipse.gef.palette.PaletteTemplateEntry;
-
-import java.util.List;
-
-/**
- * Factory that creates the palette for the {@link GraphicalLayoutEditor}.
- */
-public class PaletteFactory {
-
-    /** Static factory, nothing to instantiate here. */
-    private PaletteFactory() {
-    }
-
-    public static PaletteRoot createPaletteRoot(PaletteRoot currentPalette,
-            AndroidTargetData targetData) {
-        
-        if (currentPalette == null) {
-            currentPalette = new PaletteRoot();
-        }
-
-        for (int n = currentPalette.getChildren().size() - 1; n >= 0; n--) {
-            currentPalette.getChildren().remove(n);
-        }
-        
-        if (targetData != null) {
-            addTools(currentPalette);
-            addViews(currentPalette, "Layouts",
-                    targetData.getLayoutDescriptors().getLayoutDescriptors());
-            addViews(currentPalette, "Views",
-                    targetData.getLayoutDescriptors().getViewDescriptors());
-        }
-
-        return currentPalette;
-    }
-
-    private static void addTools(PaletteRoot paletteRoot) {
-        PaletteGroup group = new PaletteGroup("Tools");
-        
-        // Default tools: selection.
-        // Do not use the MarqueeToolEntry since we don't support multiple selection.
-        /* -- Do not put the selection tool. It's the unique tool so it looks useless.
-              Leave this piece of code here in case we want it back later.
-        PanningSelectionToolEntry entry = new PanningSelectionToolEntry();
-        group.add(entry);
-        paletteRoot.setDefaultEntry(entry);
-        */
-
-        paletteRoot.add(group);
-    }
-
-    private static void addViews(PaletteRoot paletteRoot, String groupName,
-            List<ElementDescriptor> descriptors) {
-        PaletteDrawer group = new PaletteDrawer(groupName);
-        
-        for (ElementDescriptor desc : descriptors) {
-            PaletteTemplateEntry entry = new PaletteTemplateEntry(
-                    desc.getUiName(),           // label
-                    desc.getTooltip(),          // short description
-                    desc,                       // template
-                    desc.getImageDescriptor(),  // small icon
-                    desc.getImageDescriptor()   // large icon
-                    );
-            
-            group.add(entry);
-        }
-        
-        paletteRoot.add(group);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/ProjectCallback.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/ProjectCallback.java
deleted file mode 100644
index 81fd2ed..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/ProjectCallback.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.ide.eclipse.editors.resources.manager.ProjectClassLoader;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.layoutlib.api.IProjectCallback;
-
-import org.eclipse.core.resources.IProject;
-
-import java.lang.reflect.Constructor;
-import java.util.HashMap;
-
-/**
- * Loader for Android Project class in order to use them in the layout editor.
- */
-public final class ProjectCallback implements IProjectCallback {
-    
-    private final HashMap<String, Class<?>> mLoadedClasses = new HashMap<String, Class<?>>();
-    private final IProject mProject;
-    private final ClassLoader mParentClassLoader;
-    private final ProjectResources mProjectRes;
-    private boolean mUsed = false;
-    private String mNamespace;
-    
-    ProjectCallback(ClassLoader classLoader, ProjectResources projectRes, IProject project) {
-        mParentClassLoader = classLoader;
-        mProjectRes = projectRes;
-        mProject = project;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     * 
-     * This implementation goes through the output directory of the Eclipse project and loads the
-     * <code>.class</code> file directly.
-     */
-    @SuppressWarnings("unchecked")
-    public Object loadView(String className, Class[] constructorSignature,
-            Object[] constructorParameters)
-            throws ClassNotFoundException, Exception {
-        
-        // look for a cached version
-        Class<?> clazz = mLoadedClasses.get(className);
-        if (clazz != null) {
-            return instantiateClass(clazz, constructorSignature, constructorParameters);
-        }
-        
-        // load the class.
-        ProjectClassLoader loader = new ProjectClassLoader(mParentClassLoader, mProject);
-        try {
-            clazz = loader.loadClass(className);
-            
-            if (clazz != null) {
-                mUsed = true;
-                mLoadedClasses.put(className, clazz);
-                return instantiateClass(clazz, constructorSignature, constructorParameters);
-            }
-        } catch (Error e) {
-            // Log this error with the class name we're trying to load and abort.
-            AdtPlugin.log(e, "ProjectCallback.loadView failed to find class %1$s", className); //$NON-NLS-1$
-        }
-        
-        return null;
-    }
-    
-    /**
-     * {@inheritDoc}
-     * 
-     * Returns the namespace for the project. The namespace contains a standard part + the
-     * application package.
-     */
-    public String getNamespace() {
-        if (mNamespace == null) {
-            AndroidManifestHelper manifest = new AndroidManifestHelper(mProject);
-            String javaPackage = manifest.getPackageName();
-            
-            mNamespace = String.format(AndroidConstants.NS_CUSTOM_RESOURCES, javaPackage);
-        }
-
-        return mNamespace;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.layoutlib.api.IProjectCallback#resolveResourceValue(int)
-     */
-    public String[] resolveResourceValue(int id) {
-        if (mProjectRes != null) {
-            return mProjectRes.resolveResourceValue(id);
-        }
-
-        return null;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.layoutlib.api.IProjectCallback#resolveResourceValue(int[])
-     */
-    public String resolveResourceValue(int[] id) {
-        if (mProjectRes != null) {
-            return mProjectRes.resolveResourceValue(id);
-        }
-        
-        return null;
-    }
-    
-    /*
-     * (non-Javadoc)
-     * @see com.android.layoutlib.api.IProjectCallback#getResourceValue(java.lang.String, java.lang.String)
-     */
-    public Integer getResourceValue(String type, String name) {
-        if (mProjectRes != null) {
-            return mProjectRes.getResourceValue(type, name);
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns whether the loader has received requests to load custom views.
-     * <p/>This allows to efficiently only recreate when needed upon code change in the project.
-     */
-    boolean isUsed() {
-        return mUsed;
-    }
-
-    /**
-     * Instantiate a class object, using a specific constructor and parameters.
-     * @param clazz the class to instantiate
-     * @param constructorSignature the signature of the constructor to use
-     * @param constructorParameters the parameters to use in the constructor.
-     * @return A new class object, created using a specific constructor and parameters.
-     * @throws Exception 
-     */
-    @SuppressWarnings("unchecked")
-    private Object instantiateClass(Class<?> clazz, Class[] constructorSignature,
-            Object[] constructorParameters) throws Exception {
-        Constructor<?> constructor = clazz.getConstructor(constructorSignature);
-        constructor.setAccessible(true);
-        return constructor.newInstance(constructorParameters);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiContentOutlinePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiContentOutlinePage.java
deleted file mode 100644
index 3e0f5d8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiContentOutlinePage.java
+++ /dev/null
@@ -1,615 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.common.EclipseUiHelper;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.layout.parts.UiDocumentTreeEditPart;
-import com.android.ide.eclipse.editors.layout.parts.UiElementTreeEditPart;
-import com.android.ide.eclipse.editors.layout.parts.UiElementTreeEditPartFactory;
-import com.android.ide.eclipse.editors.layout.parts.UiLayoutTreeEditPart;
-import com.android.ide.eclipse.editors.layout.parts.UiViewTreeEditPart;
-import com.android.ide.eclipse.editors.ui.tree.CopyCutAction;
-import com.android.ide.eclipse.editors.ui.tree.PasteAction;
-import com.android.ide.eclipse.editors.ui.tree.UiActions;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.ui.parts.ContentOutlinePage;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreePath;
-import org.eclipse.jface.viewers.TreeSelection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeItem;
-import org.eclipse.ui.IActionBars;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-
-/**
- * Implementation of the {@link ContentOutlinePage} to display {@link UiElementNode}.
- */
-class UiContentOutlinePage extends ContentOutlinePage {
-
-    private GraphicalLayoutEditor mEditor;
-    
-    private Action mAddAction;
-    private Action mDeleteAction;
-    private Action mUpAction;
-    private Action mDownAction;
-    
-    private UiOutlineActions mUiActions = new UiOutlineActions();
-
-    public UiContentOutlinePage(GraphicalLayoutEditor editor, final EditPartViewer viewer) {
-        super(viewer);
-        mEditor = editor;
-        IconFactory factory = IconFactory.getInstance();
-        
-        mAddAction = new Action("Add...") {
-            @Override
-            public void run() {
-                List<UiElementNode> nodes = getModelSelections();
-                UiElementNode node = nodes != null && nodes.size() > 0 ? nodes.get(0) : null;
-                
-                mUiActions.doAdd(node, viewer.getControl().getShell());
-            }
-        };
-        mAddAction.setToolTipText("Adds a new element.");
-        mAddAction.setImageDescriptor(factory.getImageDescriptor("add")); //$NON-NLS-1$
-
-        mDeleteAction = new Action("Remove...") {
-            @Override
-            public void run() {
-                List<UiElementNode> nodes = getModelSelections();
-                
-                mUiActions.doRemove(nodes, viewer.getControl().getShell());
-            }
-        };
-        mDeleteAction.setToolTipText("Removes an existing selected element.");
-        mDeleteAction.setImageDescriptor(factory.getImageDescriptor("delete")); //$NON-NLS-1$
-
-        mUpAction = new Action("Up") {
-            @Override
-            public void run() {
-                List<UiElementNode> nodes = getModelSelections();
-                
-                mUiActions.doUp(nodes);
-            }
-        };
-        mUpAction.setToolTipText("Moves the selected element up");
-        mUpAction.setImageDescriptor(factory.getImageDescriptor("up")); //$NON-NLS-1$
-
-        mDownAction = new Action("Down") {
-            @Override
-            public void run() {
-                List<UiElementNode> nodes = getModelSelections();
-                
-                mUiActions.doDown(nodes);
-            }
-        };
-        mDownAction.setToolTipText("Moves the selected element down");
-        mDownAction.setImageDescriptor(factory.getImageDescriptor("down")); //$NON-NLS-1$
-
-        // all actions disabled by default.
-        mAddAction.setEnabled(false);
-        mDeleteAction.setEnabled(false);
-        mUpAction.setEnabled(false);
-        mDownAction.setEnabled(false);
-
-        addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection selection = event.getSelection();
-                
-                // the selection is never empty. The least it'll contain is the
-                // UiDocumentTreeEditPart object.
-                if (selection instanceof StructuredSelection) {
-                    StructuredSelection structSel = (StructuredSelection)selection;
-
-                    if (structSel.size() == 1 &&
-                            structSel.getFirstElement() instanceof UiDocumentTreeEditPart) {
-                        mDeleteAction.setEnabled(false);
-                        mUpAction.setEnabled(false);
-                        mDownAction.setEnabled(false);
-                    } else {
-                        mDeleteAction.setEnabled(true);
-                        mUpAction.setEnabled(true);
-                        mDownAction.setEnabled(true);
-                    }
-
-                    // the "add" button is always enabled, in order to be able to set the
-                    // initial root node
-                    mAddAction.setEnabled(true);
-                }
-            }
-        });
-    }
-    
-
-    /* (non-Javadoc)
-     * @see org.eclipse.ui.part.IPage#createControl(org.eclipse.swt.widgets.Composite)
-     */
-    @Override
-    public void createControl(Composite parent) {
-        // create outline viewer page
-        getViewer().createControl(parent);
-
-        // configure outline viewer
-        getViewer().setEditPartFactory(new UiElementTreeEditPartFactory());
-
-        setupOutline();
-        setupContextMenu();
-        setupTooltip();
-        setupDoubleClick();
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.part.Page#setActionBars(org.eclipse.ui.IActionBars)
-     * 
-     * Called automatically after createControl
-     */
-    @Override
-    public void setActionBars(IActionBars actionBars) {
-        IToolBarManager toolBarManager = actionBars.getToolBarManager();
-        toolBarManager.add(mAddAction);
-        toolBarManager.add(mDeleteAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mUpAction);
-        toolBarManager.add(mDownAction);
-        
-        IMenuManager menuManager = actionBars.getMenuManager();
-        menuManager.add(mAddAction);
-        menuManager.add(mDeleteAction);
-        menuManager.add(new Separator());
-        menuManager.add(mUpAction);
-        menuManager.add(mDownAction);
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.ui.part.IPage#dispose()
-     */
-    @Override
-    public void dispose() {
-        breakConnectionWithEditor();
-
-        // dispose
-        super.dispose();
-    }
-
-    /* (non-Javadoc)
-     * @see org.eclipse.ui.part.IPage#getControl()
-     */
-    @Override
-    public Control getControl() {
-        return getViewer().getControl();
-    }
-    
-    void setNewEditor(GraphicalLayoutEditor editor) {
-        mEditor = editor;
-        setupOutline();
-    }
-    
-    void breakConnectionWithEditor() {
-        // unhook outline viewer
-        mEditor.getSelectionSynchronizer().removeViewer(getViewer());
-    }
-    
-    private void setupOutline() {
-        getViewer().setEditDomain(mEditor.getEditDomain());
-
-        // hook outline viewer
-        mEditor.getSelectionSynchronizer().addViewer(getViewer());
-
-        // initialize outline viewer with model
-        getViewer().setContents(mEditor.getModel());
-    }
-
-    private void setupContextMenu() {
-        MenuManager menuManager = new MenuManager();
-        menuManager.setRemoveAllWhenShown(true);
-        menuManager.addMenuListener(new IMenuListener() {
-            /**
-             * The menu is about to be shown. The menu manager has already been
-             * requested to remove any existing menu item. This method gets the
-             * tree selection and if it is of the appropriate type it re-creates
-             * the necessary actions.
-             */
-           public void menuAboutToShow(IMenuManager manager) {
-               List<UiElementNode> selected = getModelSelections();
-               
-               if (selected != null) {
-                   doCreateMenuAction(manager, selected);
-                   return;
-               }
-               doCreateMenuAction(manager, null /* ui_node */);
-            } 
-        });
-        Control control = getControl();
-        Menu contextMenu = menuManager.createContextMenu(control);
-        control.setMenu(contextMenu);
-    }
-
-    /**
-     * Adds the menu actions to the context menu when the given UI node is selected in
-     * the tree view.
-     * 
-     * @param manager The context menu manager
-     * @param selected The UI node selected in the tree. Can be null, in which case the root
-     *                is to be modified.
-     */
-    private void doCreateMenuAction(IMenuManager manager, List<UiElementNode> selected) {
-        
-        if (selected != null) {
-            boolean hasXml = false;
-            for (UiElementNode uiNode : selected) {
-                if (uiNode.getXmlNode() != null) {
-                    hasXml = true;
-                    break;
-                }
-            }
-
-            if (hasXml) {
-                manager.add(new CopyCutAction(mEditor.getLayoutEditor(), mEditor.getClipboard(),
-                        null, selected, true /* cut */));
-                manager.add(new CopyCutAction(mEditor.getLayoutEditor(), mEditor.getClipboard(),
-                        null, selected, false /* cut */));
-
-                // Can't paste with more than one element selected (the selection is the target)
-                if (selected.size() <= 1) {
-                    // Paste is not valid if it would add a second element on a terminal element
-                    // which parent is a document -- an XML document can only have one child. This
-                    // means paste is valid if the current UI node can have children or if the parent
-                    // is not a document.
-                    UiElementNode ui_root = selected.get(0).getUiRoot();
-                    if (ui_root.getDescriptor().hasChildren() ||
-                            !(ui_root.getUiParent() instanceof UiDocumentNode)) {
-                        manager.add(new PasteAction(mEditor.getLayoutEditor(),
-                                mEditor.getClipboard(),
-                                selected.get(0)));
-                    }
-                }
-                manager.add(new Separator());
-            }
-        }
-
-        // Append "add" and "remove" actions. They do the same thing as the add/remove
-        // buttons on the side.
-        //
-        // "Add" makes sense only if there's 0 or 1 item selected since the
-        // one selected item becomes the target.
-        if (selected == null || selected.size() <= 1) {
-            manager.add(mAddAction);
-        }
-
-        if (selected != null) {
-            manager.add(mDeleteAction);
-            manager.add(new Separator());
-            
-            manager.add(mUpAction);
-            manager.add(mDownAction);
-        }
-
-        if (selected != null && selected.size() == 1) {
-            manager.add(new Separator());
-            
-            Action propertiesAction = new Action("Properties") {
-                @Override
-                public void run() {
-                    EclipseUiHelper.showView(EclipseUiHelper.PROPERTY_SHEET_VIEW_ID,
-                            true /* activate */);
-                }
-            };
-            propertiesAction.setToolTipText("Displays properties of the selected element.");
-            manager.add(propertiesAction);
-        }
-    }
-
-    /**
-     * Updates the outline view with the model of the {@link GraphicalLayoutEditor}.
-     * <p/>
-     * This attemps to preserve the selection, if any.
-     */
-    public void reloadModel() {
-        // Attemps to preserve the UiNode selection, if any
-        List<UiElementNode> uiNodes = null;
-        try {
-            // get current selection using the model rather than the edit part as
-            // reloading the content may change the actual edit part.
-            uiNodes = getModelSelections();
-
-            // perform the update
-            getViewer().setContents(mEditor.getModel());
-
-        } finally {
-            // restore selection
-            if (uiNodes != null) {
-                setModelSelection(uiNodes.get(0));
-            }
-        }
-    }
-
-    /**
-     * Returns the currently selected element, if any, in the viewer.
-     * This returns the viewer's elements (i.e. an {@link UiElementTreeEditPart})
-     * and not the underlying model node.
-     * <p/>
-     * When there is no actual selection, this might still return the root node,
-     * which is of type {@link UiDocumentTreeEditPart}.
-     */
-    @SuppressWarnings("unchecked")
-    private List<UiElementTreeEditPart> getViewerSelections() {
-        ISelection selection = getSelection();
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structuredSelection = (StructuredSelection)selection;
-            
-            if (structuredSelection.size() > 0) {
-                ArrayList<UiElementTreeEditPart> selected = new ArrayList<UiElementTreeEditPart>();
-                
-                for (Iterator it = structuredSelection.iterator(); it.hasNext(); ) {
-                    Object selectedObj = it.next();
-                
-                    if (selectedObj instanceof UiElementTreeEditPart) {
-                        selected.add((UiElementTreeEditPart) selectedObj);
-                    }
-                }
-                
-                return selected.size() > 0 ? selected : null;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the currently selected model element, which is either an
-     * {@link UiViewTreeEditPart} or an {@link UiLayoutTreeEditPart}.
-     * <p/>
-     * Returns null if there is no selection or if the implicit root is "selected"
-     * (which actually represents the lack of a real element selection.)
-     */
-    private List<UiElementNode> getModelSelections() {
-
-        List<UiElementTreeEditPart> parts = getViewerSelections();
-
-        if (parts != null) {
-            ArrayList<UiElementNode> selected = new ArrayList<UiElementNode>();
-            
-            for (UiElementTreeEditPart part : parts) {
-                if (part instanceof UiViewTreeEditPart || part instanceof UiLayoutTreeEditPart) {
-                    selected.add((UiElementNode) part.getModel());
-                }
-            }
-            
-            return selected.size() > 0 ? selected : null;
-        }
-        
-        return null;
-    }
-
-    /**
-     * Selects the corresponding edit part in the tree viewer.
-     */
-    private void setViewerSelection(UiElementTreeEditPart selectedPart) {
-        if (selectedPart != null && !(selectedPart instanceof UiDocumentTreeEditPart)) {
-            LinkedList<UiElementTreeEditPart> segments = new LinkedList<UiElementTreeEditPart>();
-            for (UiElementTreeEditPart part = selectedPart;
-                    !(part instanceof UiDocumentTreeEditPart);
-                    part = (UiElementTreeEditPart) part.getParent()) {
-                segments.add(0, part);
-            }
-            setSelection(new TreeSelection(new TreePath(segments.toArray())));
-        }
-    }
-
-    /** 
-     * Selects the corresponding model element in the tree viewer.
-     */
-    private void setModelSelection(UiElementNode uiNodeToSelect) {
-        if (uiNodeToSelect != null) {
-            
-            // find an edit part that has the requested model element
-            UiElementTreeEditPart part = findPartForModel(
-                    (UiElementTreeEditPart) getViewer().getContents(),
-                    uiNodeToSelect);
-            
-            // if we found a part, select it and reveal it
-            if (part != null) {
-                setViewerSelection(part);
-                getViewer().reveal(part);
-            }
-        }
-    }
-
-    /**
-     * Utility method that tries to find an edit part that matches a given model UI node.
-     * 
-     * @param rootPart The root of the viewer edit parts
-     * @param uiNode The UI node model to find
-     * @return The part that matches the model or null if it's not in the sub tree.
-     */
-    private UiElementTreeEditPart findPartForModel(UiElementTreeEditPart rootPart,
-            UiElementNode uiNode) {
-        if (rootPart.getModel() == uiNode) {
-            return rootPart;
-        }
-        
-        for (Object part : rootPart.getChildren()) {
-            if (part instanceof UiElementTreeEditPart) {
-                UiElementTreeEditPart found = findPartForModel(
-                        (UiElementTreeEditPart) part, uiNode);
-                if (found != null) {
-                    return found;
-                }
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Sets up a custom tooltip when hovering over tree items.
-     * <p/>
-     * The tooltip will display the element's javadoc, if any, or the item's getText otherwise.
-     */
-    private void setupTooltip() {
-        final Tree tree = (Tree) getControl();
-        
-        /*
-         * Reference: 
-         * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet125.java?view=markup
-         */
-        
-        final Listener listener = new Listener() {
-            Shell tip = null;
-            Label label  = null;
-            
-            public void handleEvent(Event event) {
-                switch(event.type) {
-                case SWT.Dispose:
-                case SWT.KeyDown:
-                case SWT.MouseExit:
-                case SWT.MouseDown:
-                case SWT.MouseMove:
-                    if (tip != null) {
-                        tip.dispose();
-                        tip = null;
-                        label = null;
-                    }
-                    break;
-                case SWT.MouseHover:
-                    if (tip != null) {
-                        tip.dispose();
-                        tip = null;
-                        label = null;
-                    }
-
-                    String tooltip = null;
-                    
-                    TreeItem item = tree.getItem(new Point(event.x, event.y));
-                    if (item != null) {
-                        Object data = item.getData();
-                        if (data instanceof UiElementTreeEditPart) {
-                            Object model = ((UiElementTreeEditPart) data).getModel();
-                            if (model instanceof UiElementNode) {
-                                tooltip = ((UiElementNode) model).getDescriptor().getTooltip();
-                            }
-                        }
-
-                        if (tooltip == null) {
-                            tooltip = item.getText();
-                        } else {
-                            tooltip = item.getText() + ":\r" + tooltip;
-                        }
-                    }
-                    
-                    
-                    if (tooltip != null) {
-                        Shell shell = tree.getShell();
-                        Display display = tree.getDisplay();
-                        
-                        tip = new Shell(shell, SWT.ON_TOP | SWT.NO_FOCUS | SWT.TOOL);
-                        tip.setBackground(display .getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-                        FillLayout layout = new FillLayout();
-                        layout.marginWidth = 2;
-                        tip.setLayout(layout);
-                        label = new Label(tip, SWT.NONE);
-                        label.setForeground(display.getSystemColor(SWT.COLOR_INFO_FOREGROUND));
-                        label.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-                        label.setData("_TABLEITEM", item);
-                        label.setText(tooltip);
-                        label.addListener(SWT.MouseExit, this);
-                        label.addListener(SWT.MouseDown, this);
-                        Point size = tip.computeSize(SWT.DEFAULT, SWT.DEFAULT);
-                        Rectangle rect = item.getBounds(0);
-                        Point pt = tree.toDisplay(rect.x, rect.y);
-                        tip.setBounds(pt.x, pt.y, size.x, size.y);
-                        tip.setVisible(true);
-                    }
-                }
-            }
-        };
-        
-        tree.addListener(SWT.Dispose, listener);
-        tree.addListener(SWT.KeyDown, listener);
-        tree.addListener(SWT.MouseMove, listener);
-        tree.addListener(SWT.MouseHover, listener);
-    }
-
-    /**
-     * Sets up double-click action on the tree.
-     * <p/>
-     * By default, double-click (a.k.a. "default selection") on a valid list item will
-     * show the property view.
-     */
-    private void setupDoubleClick() {
-        final Tree tree = (Tree) getControl();
-
-        tree.addListener(SWT.DefaultSelection, new Listener() {
-            public void handleEvent(Event event) {
-                EclipseUiHelper.showView(EclipseUiHelper.PROPERTY_SHEET_VIEW_ID,
-                        true /* activate */);
-            }
-        });
-    }
-
-    // ---------------
-    
-    private class UiOutlineActions extends UiActions {
-
-        @Override
-        protected UiDocumentNode getRootNode() {
-            return mEditor.getModel(); // this is LayoutEditor.getUiRootNode()
-        }
-
-        // Select the new item
-        @Override
-        protected void selectUiNode(UiElementNode uiNodeToSelect) {
-            setModelSelection(uiNodeToSelect);
-        }
-
-        @Override
-        public void commitPendingXmlChanges() {
-            // Pass. There is nothing to commit before the XML is changed here.
-        }
-        
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiElementPullParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiElementPullParser.java
deleted file mode 100644
index b0e6fdb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiElementPullParser.java
+++ /dev/null
@@ -1,244 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.layoutlib.api.IXmlPullParser;
-
-import org.w3c.dom.Node;
-import org.xmlpull.v1.XmlPullParserException;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * {@link IXmlPullParser} implementation on top of {@link UiElementNode}.
- * <p/>It's designed to work on layout files, and will most likely not work on other resource
- * files.
- */
-public final class UiElementPullParser extends BasePullParser {
-    
-    private final ArrayList<UiElementNode> mNodeStack = new ArrayList<UiElementNode>();
-    private UiElementNode mRoot;
-    
-    public UiElementPullParser(UiElementNode top) {
-        super();
-        mRoot = top;
-        push(mRoot);
-    }
-    
-    private UiElementNode getCurrentNode() {
-        if (mNodeStack.size() > 0) {
-            return mNodeStack.get(mNodeStack.size()-1);
-        }
-        
-        return null;
-    }
-    
-    private Node getAttribute(int i) {
-        if (mParsingState != START_TAG) {
-            throw new IndexOutOfBoundsException();
-        }
-
-        // get the current uiNode
-        UiElementNode uiNode = getCurrentNode();
-        
-        // get its xml node
-        Node xmlNode = uiNode.getXmlNode();
-
-        if (xmlNode != null) {
-            return xmlNode.getAttributes().item(i);
-        }
-
-        return null;
-    }
-    
-    private void push(UiElementNode node) {
-        mNodeStack.add(node);
-    }
-    
-    private UiElementNode pop() {
-        return mNodeStack.remove(mNodeStack.size()-1);
-    }
-
-    // ------------- IXmlPullParser --------
-
-    /**
-     * {@inheritDoc}
-     * 
-     * This implementation returns the underlying DOM node.
-     */
-    public Object getViewKey() {
-        return getCurrentNode();
-    }
-
-    // ------------- XmlPullParser --------
-
-    public String getPositionDescription() {
-        return "XML DOM element depth:" + mNodeStack.size();
-    }
-
-    public int getAttributeCount() {
-        UiElementNode node = getCurrentNode();
-        if (node != null) {
-            return node.getUiAttributes().size();
-        }
-
-        return 0;
-    }
-
-    public String getAttributeName(int i) {
-        Node attribute = getAttribute(i);
-        if (attribute != null) {
-            return attribute.getLocalName();
-        }
-
-        return null;
-    }
-
-    public String getAttributeNamespace(int i) {
-        Node attribute = getAttribute(i);
-        if (attribute != null) {
-            return attribute.getNamespaceURI();
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-    public String getAttributePrefix(int i) {
-        Node attribute = getAttribute(i);
-        if (attribute != null) {
-            return attribute.getPrefix();
-        }
-        return null;
-    }
-
-    public String getAttributeValue(int i) {
-        Node attribute = getAttribute(i);
-        if (attribute != null) {
-            return attribute.getNodeValue();
-        }
-        
-        return null;
-    }
-
-    public String getAttributeValue(String namespace, String localName) {
-        // get the current uiNode
-        UiElementNode uiNode = getCurrentNode();
-        
-        // get its xml node
-        Node xmlNode = uiNode.getXmlNode();
-        
-        if (xmlNode != null) {
-            Node attribute = xmlNode.getAttributes().getNamedItemNS(namespace, localName);
-            if (attribute != null) {
-                return attribute.getNodeValue();
-            }
-        }
-
-        return null;
-    }
-
-    public int getDepth() {
-        return mNodeStack.size();
-    }
-
-    public String getName() {
-        if (mParsingState == START_TAG || mParsingState == END_TAG) {
-            return getCurrentNode().getDescriptor().getXmlLocalName();
-        }
-
-        return null;
-    }
-
-    public String getNamespace() {
-        if (mParsingState == START_TAG || mParsingState == END_TAG) {
-            return getCurrentNode().getDescriptor().getNamespace();
-        }
-
-        return null;
-    }
-
-    public String getPrefix() {
-        if (mParsingState == START_TAG || mParsingState == END_TAG) {
-            // FIXME will NEVER work
-            if (getCurrentNode().getDescriptor().getXmlLocalName().startsWith("android:")) { //$NON-NLS-1$
-                return "android"; //$NON-NLS-1$
-            }
-        }
-
-        return null;
-    }
-
-    public boolean isEmptyElementTag() throws XmlPullParserException {
-        if (mParsingState == START_TAG) {
-            return getCurrentNode().getUiChildren().size() == 0;
-        }
-        
-        throw new XmlPullParserException("Call to isEmptyElementTag while not in START_TAG",
-                this, null);
-    }
-    
-    @Override
-    public void onNextFromStartDocument() {
-        onNextFromStartTag();
-    }
-    
-    @Override
-    public void onNextFromStartTag() {
-        // get the current node, and look for text or children (children first)
-        UiElementNode node = getCurrentNode();
-        List<UiElementNode> children = node.getUiChildren();
-        if (children.size() > 0) {
-            // move to the new child, and don't change the state.
-            push(children.get(0));
-            
-            // in case the current state is CURRENT_DOC, we set the proper state.
-            mParsingState = START_TAG;
-        } else {
-            if (mParsingState == START_DOCUMENT) {
-                // this handles the case where there's no node.
-                mParsingState = END_DOCUMENT;
-            } else {
-                mParsingState = END_TAG;
-            }
-        }
-    }
-    
-    @Override
-    public void onNextFromEndTag() {
-        // look for a sibling. if no sibling, go back to the parent
-        UiElementNode node = getCurrentNode();
-        node = node.getUiNextSibling();
-        if (node != null) {
-            // to go to the sibling, we need to remove the current node,
-            pop();
-            // and add its sibling.
-            push(node);
-            mParsingState = START_TAG;
-        } else {
-            // move back to the parent
-            pop();
-            
-            // we have only one element left (mRoot), then we're done with the document.
-            if (mNodeStack.size() == 1) {
-                mParsingState = END_DOCUMENT;
-            } else {
-                mParsingState = END_TAG;
-            }
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiPropertySheetPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiPropertySheetPage.java
deleted file mode 100644
index 8093c90..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/UiPropertySheetPage.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeItem;
-import org.eclipse.ui.views.properties.PropertySheetEntry;
-import org.eclipse.ui.views.properties.PropertySheetPage;
-
-/**
- * A customized property sheet page for the graphical layout editor.
- * <p/>
- * Currently it just provides a custom tooltip to display attributes javadocs.
- */
-public class UiPropertySheetPage extends PropertySheetPage {
-
-    
-    public UiPropertySheetPage() {
-        super();
-    }
-
-    @Override
-    public void createControl(Composite parent) {
-        super.createControl(parent);
-        
-        setupTooltip();
-    }
-
-    /**
-     * Sets up a custom tooltip when hovering over tree items.
-     * <p/>
-     * The tooltip will display the element's javadoc, if any, or the item's getText otherwise.
-     */
-    private void setupTooltip() {
-        final Tree tree = (Tree) getControl();
-
-        /*
-         * Reference: 
-         * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet125.java?view=markup
-         */
-
-        final Listener listener = new Listener() {
-            Shell tip = null;
-            Label label  = null;
-            
-            public void handleEvent(Event event) {
-                switch(event.type) {
-                case SWT.Dispose:
-                case SWT.KeyDown:
-                case SWT.MouseExit:
-                case SWT.MouseDown:
-                case SWT.MouseMove:
-                    if (tip != null) {
-                        tip.dispose();
-                        tip = null;
-                        label = null;
-                    }
-                    break;
-                case SWT.MouseHover:
-                    if (tip != null) {
-                        tip.dispose();
-                        tip = null;
-                        label = null;
-                    }
-
-                    String tooltip = null;
-                    
-                    TreeItem item = tree.getItem(new Point(event.x, event.y));
-                    if (item != null) {
-                        Object data = item.getData();
-                        if (data instanceof PropertySheetEntry) {
-                            tooltip = ((PropertySheetEntry) data).getDescription();
-                        }
-
-                        if (tooltip == null) {
-                            tooltip = item.getText();
-                        } else {
-                            tooltip = item.getText() + ":\r" + tooltip;
-                        }
-                    }
-                    
-                    if (tooltip != null) {
-                        Shell shell = tree.getShell();
-                        Display display = tree.getDisplay();
-                        
-                        tip = new Shell(shell, SWT.ON_TOP | SWT.NO_FOCUS | SWT.TOOL);
-                        tip.setBackground(display .getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-                        FillLayout layout = new FillLayout();
-                        layout.marginWidth = 2;
-                        tip.setLayout(layout);
-                        label = new Label(tip, SWT.NONE);
-                        label.setForeground(display.getSystemColor(SWT.COLOR_INFO_FOREGROUND));
-                        label.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
-                        label.setData("_TABLEITEM", item);
-                        label.setText(tooltip);
-                        label.addListener(SWT.MouseExit, this);
-                        label.addListener(SWT.MouseDown, this);
-                        Point size = tip.computeSize(SWT.DEFAULT, SWT.DEFAULT);
-                        Rectangle rect = item.getBounds(0);
-                        Point pt = tree.toDisplay(rect.x, rect.y);
-                        tip.setBounds(pt.x, pt.y, size.x, size.y);
-                        tip.setVisible(true);
-                    }
-                }
-            }
-        };
-        
-        tree.addListener(SWT.Dispose, listener);
-        tree.addListener(SWT.KeyDown, listener);
-        tree.addListener(SWT.MouseMove, listener);
-        tree.addListener(SWT.MouseHover, listener);
-
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/WidgetPullParser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/WidgetPullParser.java
deleted file mode 100644
index e62ab69..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/WidgetPullParser.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.layout.descriptors.ViewElementDescriptor;
-import com.android.layoutlib.api.IXmlPullParser;
-import com.android.sdklib.SdkConstants;
-
-import org.xmlpull.v1.XmlPullParserException;
-
-/**
- * {@link IXmlPullParser} implementation to render android widget bitmap.
- * <p/>The parser emulates a layout that contains just one widget, described by the
- * {@link ViewElementDescriptor} passed in the constructor.
- */
-public class WidgetPullParser extends BasePullParser {
-    
-    private final ViewElementDescriptor mDescriptor;
-    private String[][] mAttributes = new String[][] {
-            { "text", null },
-            { "layout_width", "wrap_content" },
-            { "layout_height", "wrap_content" },
-    };
-
-    public WidgetPullParser(ViewElementDescriptor descriptor) {
-        mDescriptor = descriptor;
-        
-        String[] segments = mDescriptor.getCanonicalClassName().split(AndroidConstants.RE_DOT);
-        mAttributes[0][1] = segments[segments.length-1];
-    }
-
-    public Object getViewKey() {
-        // we need a viewKey or the ILayoutResult will not contain any ILayoutViewInfo
-        return mDescriptor;
-    }
-
-    public int getAttributeCount() {
-        return mAttributes.length; // text attribute
-    }
-
-    public String getAttributeName(int index) {
-        if (index < mAttributes.length) {
-            return mAttributes[index][0];
-        }
-        
-        return null;
-    }
-
-    public String getAttributeNamespace(int index) {
-        return SdkConstants.NS_RESOURCES;
-    }
-
-    public String getAttributePrefix(int index) {
-        // pass
-        return null;
-    }
-
-    public String getAttributeValue(int index) {
-        if (index < mAttributes.length) {
-            return mAttributes[index][1];
-        }
-        
-        return null;
-    }
-
-    public String getAttributeValue(String ns, String name) {
-        if (SdkConstants.NS_RESOURCES.equals(ns)) {
-            for (String[] attribute : mAttributes) {
-                if (name.equals(attribute[0])) {
-                    return attribute[1];
-                }
-            }
-        }
-        
-        return null;
-    }
-
-    public int getDepth() {
-        // pass
-        return 0;
-    }
-
-    public String getName() {
-        return mDescriptor.getXmlLocalName();
-    }
-
-    public String getNamespace() {
-        // pass
-        return null;
-    }
-
-    public String getPositionDescription() {
-        // pass
-        return null;
-    }
-
-    public String getPrefix() {
-        // pass
-        return null;
-    }
-
-    public boolean isEmptyElementTag() throws XmlPullParserException {
-        if (mParsingState == START_TAG) {
-            return true;
-        }
-        
-        throw new XmlPullParserException("Call to isEmptyElementTag while not in START_TAG",
-                this, null);
-    }
-
-    @Override
-    public void onNextFromStartDocument() {
-        // just go to start_tag
-        mParsingState = START_TAG;
-    }
-
-    @Override
-    public void onNextFromStartTag() {
-        // since we have no children, just go to end_tag
-        mParsingState = END_TAG;
-    }
-
-    @Override
-    public void onNextFromEndTag() {
-        // just one tag. we are done.
-        mParsingState = END_DOCUMENT;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/CustomViewDescriptorService.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/CustomViewDescriptorService.java
deleted file mode 100644
index d5ee2ca..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/CustomViewDescriptorService.java
+++ /dev/null
@@ -1,284 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.descriptors;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-
-import java.util.HashMap;
-import java.util.List;
-
-/**
- * Service responsible for creating/managing {@link ElementDescriptor} objects for custom
- * View classes per project.
- * <p/>
- * The service provides an on-demand monitoring of custom classes to check for changes. Monitoring
- * starts once a request for an {@link ElementDescriptor} object has been done for a specific
- * class.<br>
- * The monitoring will notify a listen of any changes in the class triggering a change in its
- * associated {@link ElementDescriptor} object.
- * <p/>
- * If the custom class does not exist, no monitoring is put in place to avoid having to listen
- * to all class changes in the projects. 
- * 
- */
-public final class CustomViewDescriptorService {
-
-    private static CustomViewDescriptorService sThis = new CustomViewDescriptorService();
-    
-    /**
-     * Map where keys are the project, and values are another map containing all the known
-     * custom View class for this project. The custom View class are stored in a map
-     * where the keys are the fully qualified class name, and the values are their associated
-     * {@link ElementDescriptor}.
-     */
-    private HashMap<IProject, HashMap<String, ElementDescriptor>> mCustomDescriptorMap =
-        new HashMap<IProject, HashMap<String, ElementDescriptor>>();
-
-    /**
-     * TODO will be used to update the ElementDescriptor of the custom view when it
-     * is modified (either the class itself or its attributes.xml)
-     */
-    @SuppressWarnings("unused")
-    private ICustomViewDescriptorListener mListener;
-    
-    /**
-     * Classes which implements this interface provide a method that deal with modifications
-     * in custom View class triggering a change in its associated {@link ViewClassInfo} object. 
-     */
-    public interface ICustomViewDescriptorListener {
-        /**
-         * Sent when a custom View class has changed and its {@link ElementDescriptor} was modified.
-         * @param project the project containing the class.
-         * @param className the fully qualified class name.
-         * @param descriptor the updated ElementDescriptor.
-         */
-        public void updatedClassInfo(IProject project, String className, ElementDescriptor descriptor);
-    }
-    
-    /**
-     * Returns the singleton instance of {@link CustomViewDescriptorService}.
-     */
-    public static CustomViewDescriptorService getInstance() {
-        return sThis;
-    }
-    
-    /**
-     * Sets the listener receiving custom View class modification notifications.
-     * @param listener the listener to receive the notifications.
-     *
-     * TODO will be used to update the ElementDescriptor of the custom view when it
-     * is modified (either the class itself or its attributes.xml)
-     */
-    public void setListener(ICustomViewDescriptorListener listener) {
-        mListener = listener;
-    }
-    
-    /**
-     * Returns the {@link ElementDescriptor} for a particular project/class.
-     * <p/>
-     * If it is the first time the <code>ElementDescriptor</code> is requested, the method
-     * will check that the specified class is in fact a custom View class. Once this is
-     * established, a monitoring for that particular class is initiated. Any change will
-     * trigger a notification to the {@link ICustomViewDescriptorListener}.
-     * @param project the project containing the class.
-     * @param fqClassName the fully qualified name of the class.
-     * @return a <code>ElementDescriptor</code> or <code>null</code> if the class was not
-     * a custom View class.
-     */
-    public ElementDescriptor getDescriptor(IProject project, String fqClassName) {
-        // look in the map first
-        synchronized (mCustomDescriptorMap) {
-            HashMap<String, ElementDescriptor> map = mCustomDescriptorMap.get(project);
-            
-            if (map != null) {
-                ElementDescriptor descriptor = map.get(fqClassName);
-                if (descriptor != null) {
-                    return descriptor;
-                }
-            }
-        
-            // if we step here, it looks like we haven't created it yet.
-            // First lets check this is in fact a valid type in the project
-            
-            try {
-                // We expect the project to be both opened and of java type (since it's an android
-                // project), so we can create a IJavaProject object from our IProject.
-                IJavaProject javaProject = JavaCore.create(project);
-                
-                // replace $ by . in the class name
-                String javaClassName = fqClassName.replaceAll("\\$", "\\."); //$NON-NLS-1$ //$NON-NLS-2$
-        
-                // look for the IType object for this class
-                IType type = javaProject.findType(javaClassName);
-                if (type != null && type.exists()) {
-                    // the type exists. Let's get the parent class and its ViewClassInfo.
-                    
-                    // get the type hierarchy
-                    ITypeHierarchy hierarchy = type.newSupertypeHierarchy(
-                            new NullProgressMonitor());
-                    
-                    ElementDescriptor parentDescriptor = getDescriptor(
-                            hierarchy.getSuperclass(type), project, hierarchy);
-                    
-                    if (parentDescriptor != null) {
-                        // we have a valid parent, lets create a new ElementDescriptor.
-
-                        ViewElementDescriptor descriptor = new ViewElementDescriptor(fqClassName,
-                                fqClassName, // ui_name
-                                fqClassName, // canonical class name
-                                null, // tooltip
-                                null, // sdk_url
-                                getAttributeDescriptor(type, parentDescriptor),
-                                null, // layout attributes
-                                null, // children
-                                false /* mandatory */);
-
-                        synchronized (mCustomDescriptorMap) {
-                            map = mCustomDescriptorMap.get(project);
-                            if (map == null) {
-                                map = new HashMap<String, ElementDescriptor>();
-                                mCustomDescriptorMap.put(project, map);
-                            }
-                        
-                            map.put(fqClassName, descriptor);
-                        }
-                        
-                        //TODO setup listener on this resource change.
-                        
-                        return descriptor;
-                    }
-                }
-            } catch (JavaModelException e) {
-                // there was an error accessing any of the IType, we'll just return null;
-            }
-        }
-
-
-        return null;
-    }
-    
-    /**
-     * Computes (if needed) and returns the {@link ElementDescriptor} for the specified type.
-     * 
-     * @param type 
-     * @param project 
-     * @param typeHierarchy
-     * @return A ViewElementDescriptor or null if type or typeHierarchy is null.
-     */
-    private ViewElementDescriptor getDescriptor(IType type, IProject project,
-            ITypeHierarchy typeHierarchy) {
-        // check if the type is a built-in View class.
-        List<ElementDescriptor> builtInList = null;
-
-        Sdk currentSdk = Sdk.getCurrent();
-        IAndroidTarget target = currentSdk == null ? null : currentSdk.getTarget(project);
-        if (target != null) {
-            AndroidTargetData data = currentSdk.getTargetData(target);
-            builtInList = data.getLayoutDescriptors().getViewDescriptors();
-        }
-
-        // give up if there's no type
-        if (type == null) {
-            return null;
-        }
-
-        String canonicalName = type.getFullyQualifiedName();
-        
-        if (builtInList != null) {
-            for (ElementDescriptor desc : builtInList) {
-                if (desc instanceof ViewElementDescriptor) {
-                    ViewElementDescriptor viewDescriptor = (ViewElementDescriptor)desc;
-                    if (canonicalName.equals(viewDescriptor.getCanonicalClassName())) {
-                        return viewDescriptor;
-                    }
-                }
-            }
-        }
-        
-        // it's not a built-in class? Lets look if the superclass is built-in
-        // give up if there's no type
-        if (typeHierarchy == null) {
-            return null;
-        }
-
-        IType parentType = typeHierarchy.getSuperclass(type);
-        if (parentType != null) {
-            ViewElementDescriptor parentDescriptor = getDescriptor(parentType, project,
-                    typeHierarchy);
-            
-            if (parentDescriptor != null) {
-                // parent class is a valid View class with a descriptor, so we create one
-                // for this class.
-                ViewElementDescriptor descriptor = new ViewElementDescriptor(canonicalName,
-                        canonicalName, // ui_name
-                        canonicalName, // canonical name
-                        null, // tooltip
-                        null, // sdk_url
-                        getAttributeDescriptor(type, parentDescriptor),
-                        null, // layout attributes
-                        null, // children
-                        false /* mandatory */);
-                
-                // add it to the map
-                synchronized (mCustomDescriptorMap) {
-                    HashMap<String, ElementDescriptor> map = mCustomDescriptorMap.get(project);
-                    
-                    if (map == null) {
-                        map = new HashMap<String, ElementDescriptor>();
-                        mCustomDescriptorMap.put(project, map);
-                    }
-                    
-                    map.put(canonicalName, descriptor);
-                    
-                }
-
-                //TODO setup listener on this resource change.
-                
-                return descriptor;
-            }
-        }
-        
-        // class is neither a built-in view class, nor extend one. return null.
-        return null;
-    }
-    
-    /**
-     * Returns the array of {@link AttributeDescriptor} for the specified {@link IType}.
-     * <p/>
-     * The array should contain the descriptor for this type and all its supertypes.
-     * @param type the type for which the {@link AttributeDescriptor} are returned.
-     * @param parentDescriptor the {@link ElementDescriptor} of the direct superclass.
-     */
-    private AttributeDescriptor[] getAttributeDescriptor(IType type,
-            ElementDescriptor parentDescriptor) {
-        // TODO add the class attribute descriptors to the parent descriptors.
-        return parentDescriptor.getAttributes();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/LayoutDescriptors.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/LayoutDescriptors.java
deleted file mode 100644
index 7caa50f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/LayoutDescriptors.java
+++ /dev/null
@@ -1,204 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-import com.android.ide.eclipse.common.resources.ViewClassInfo.LayoutParamsInfo;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-import com.android.sdklib.SdkConstants;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-
-/**
- * Complete description of the layout structure.
- */
-public final class LayoutDescriptors implements IDescriptorProvider {
-
-    // Public attributes names, attributes descriptors and elements descriptors
-    public static final String ID_ATTR = "id"; //$NON-NLS-1$
-
-    /** The document descriptor. Contains all layouts and views linked together. */
-    private DocumentDescriptor mDescriptor =
-        new DocumentDescriptor("layout_doc", null); //$NON-NLS-1$
-
-    /** The list of all known ViewLayout descriptors. */
-    private ArrayList<ElementDescriptor> mLayoutDescriptors = new ArrayList<ElementDescriptor>();
-
-    /** Read-Only list of View Descriptors. */
-    private List<ElementDescriptor> mROLayoutDescriptors;
-
-    /** The list of all known View (not ViewLayout) descriptors. */
-    private ArrayList<ElementDescriptor> mViewDescriptors = new ArrayList<ElementDescriptor>();
-    
-    /** Read-Only list of View Descriptors. */
-    private List<ElementDescriptor> mROViewDescriptors;
-    
-    /** @return the document descriptor. Contains all layouts and views linked together. */
-    public DocumentDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-    
-    /** @return The read-only list of all known ViewLayout descriptors. */
-    public List<ElementDescriptor> getLayoutDescriptors() {
-        return mROLayoutDescriptors;
-    }
-    
-    /** @return The read-only list of all known View (not ViewLayout) descriptors. */
-    public List<ElementDescriptor> getViewDescriptors() {
-        return mROViewDescriptors;
-    }
-    
-    public ElementDescriptor[] getRootElementDescriptors() {
-        return mDescriptor.getChildren();
-    }
-
-    /**
-     * Updates the document descriptor.
-     * <p/>
-     * It first computes the new children of the descriptor and then update them
-     * all at once.
-     * <p/> 
-     *  TODO: differentiate groups from views in the tree UI? => rely on icons
-     * <p/> 
-     * 
-     * @param views The list of views in the framework.
-     * @param layouts The list of layouts in the framework.
-     */
-    public synchronized void updateDescriptors(ViewClassInfo[] views, ViewClassInfo[] layouts) {
-        ArrayList<ElementDescriptor> newViews = new ArrayList<ElementDescriptor>();
-        if (views != null) {
-            for (ViewClassInfo info : views) {
-                ElementDescriptor desc = convertView(info);
-                newViews.add(desc);
-            }
-        }
-
-        ArrayList<ElementDescriptor> newLayouts = new ArrayList<ElementDescriptor>();
-        if (layouts != null) {
-            for (ViewClassInfo info : layouts) {
-                ElementDescriptor desc = convertView(info);
-                newLayouts.add(desc);
-            }
-        }
-
-        ArrayList<ElementDescriptor> newDescriptors = new ArrayList<ElementDescriptor>();
-        newDescriptors.addAll(newLayouts);
-        newDescriptors.addAll(newViews);
-        ElementDescriptor[] newArray = newDescriptors.toArray(
-                new ElementDescriptor[newDescriptors.size()]);
-
-        // Link all layouts to everything else here.. recursively
-        for (ElementDescriptor layoutDesc : newLayouts) {
-            layoutDesc.setChildren(newArray);
-        }
-
-        mViewDescriptors = newViews;
-        mLayoutDescriptors  = newLayouts;
-        mDescriptor.setChildren(newArray);
-        
-        mROLayoutDescriptors = Collections.unmodifiableList(mLayoutDescriptors);
-        mROViewDescriptors = Collections.unmodifiableList(mViewDescriptors);
-    }
-
-    /**
-     * Creates an element descriptor from a given {@link ViewClassInfo}.
-     */
-    private ElementDescriptor convertView(ViewClassInfo info) {
-        String xml_name = info.getShortClassName();
-        String tooltip = info.getJavaDoc();
-        
-        // Process all View attributes
-        ArrayList<AttributeDescriptor> attributes = new ArrayList<AttributeDescriptor>();
-        DescriptorsUtils.appendAttributes(attributes,
-                null, // elementName
-                SdkConstants.NS_RESOURCES,
-                info.getAttributes(),
-                null, // requiredAttributes
-                null /* overrides */);
-        
-        for (ViewClassInfo link = info.getSuperClass();
-                link != null;
-                link = link.getSuperClass()) {
-            AttributeInfo[] attrList = link.getAttributes();
-            if (attrList.length > 0) {
-                attributes.add(new SeparatorAttributeDescriptor(
-                        String.format("Attributes from %1$s", link.getShortClassName()))); 
-                DescriptorsUtils.appendAttributes(attributes,
-                        null, // elementName
-                        SdkConstants.NS_RESOURCES,
-                        attrList,
-                        null, // requiredAttributes
-                        null /* overrides */);
-            }
-        }
-        
-        // Process all LayoutParams attributes
-        ArrayList<AttributeDescriptor> layoutAttributes = new ArrayList<AttributeDescriptor>();
-        LayoutParamsInfo layoutParams = info.getLayoutData();
-
-        for(; layoutParams != null; layoutParams = layoutParams.getSuperClass()) {
-            boolean need_separator = true;
-            for (AttributeInfo attr_info : layoutParams.getAttributes()) {
-                if (DescriptorsUtils.containsAttribute(layoutAttributes,
-                        SdkConstants.NS_RESOURCES, attr_info)) {
-                    continue;
-                }
-                if (need_separator) {
-                    String title;
-                    if (layoutParams.getShortClassName().equals(
-                            AndroidConstants.CLASS_LAYOUTPARAMS)) {
-                        title = String.format("Layout Attributes from %1$s",
-                                    layoutParams.getViewLayoutClass().getShortClassName());
-                    } else {
-                        title = String.format("Layout Attributes from %1$s (%2$s)",
-                                layoutParams.getViewLayoutClass().getShortClassName(),
-                                layoutParams.getShortClassName());
-                    }
-                    layoutAttributes.add(new SeparatorAttributeDescriptor(title));
-                    need_separator = false;
-                }
-                DescriptorsUtils.appendAttribute(layoutAttributes,
-                        null, // elementName
-                        SdkConstants.NS_RESOURCES,
-                        attr_info,
-                        false, // required
-                        null /* overrides */);
-            }
-        }
-
-        return new ViewElementDescriptor(xml_name,
-                xml_name, // ui_name
-                info.getCanonicalClassName(),
-                tooltip,
-                null, // sdk_url
-                attributes.toArray(new AttributeDescriptor[attributes.size()]),
-                layoutAttributes.toArray(new AttributeDescriptor[layoutAttributes.size()]),
-                null, // children
-                false /* mandatory */);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/ViewElementDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/ViewElementDescriptor.java
deleted file mode 100644
index d718ebd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/descriptors/ViewElementDescriptor.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.layout.uimodel.UiViewElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * {@link ViewElementDescriptor} describes the properties expected for a given XML element node
- * representing a class in an XML Layout file.
- * 
- * @see ElementDescriptor
- */
-public final class ViewElementDescriptor extends ElementDescriptor {
-    
-    private String mCanonicalClassName;
-
-    /** The list of layout attributes. Can be empty but not null. */
-    private AttributeDescriptor[] mLayoutAttributes;
-
-    
-    /**
-     * Constructs a new {@link ViewElementDescriptor} based on its XML name, UI name,
-     * the canonical name of the class it represents, its tooltip, its SDK url, its attributes list,
-     * its children list and its mandatory flag.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param ui_name The XML element name for the user interface, typically capitalized.
-     * @param canonicalClassName The canonical class name the {@link ViewElementDescriptor} is
-     * representing.
-     * @param tooltip An optional tooltip. Can be null or empty.
-     * @param sdk_url An optional SKD URL. Can be null or empty.
-     * @param attributes The list of allowed attributes. Can be null or empty.
-     * @param layoutAttributes The list of layout attributes. Can be null or empty.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models). A mandatory
-     *  UI node is never deleted and it may lack an actual XML node attached. A non-mandatory
-     *  UI node MUST have an XML node attached and it will cease to exist when the XML node
-     *  ceases to exist.
-     */
-    public ViewElementDescriptor(String xml_name, String ui_name,
-            String canonicalClassName,
-            String tooltip, String sdk_url,
-            AttributeDescriptor[] attributes, AttributeDescriptor[] layoutAttributes,
-            ElementDescriptor[] children, boolean mandatory) {
-        super(xml_name, ui_name, tooltip, sdk_url, attributes, children, mandatory);
-        mCanonicalClassName = canonicalClassName;
-        mLayoutAttributes = layoutAttributes != null ? layoutAttributes : new AttributeDescriptor[0];
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name, the canonical
-     * name of the class it represents, and its children list.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param canonicalClassName The canonical class name the {@link ViewElementDescriptor} is
-     * representing.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models). A mandatory
-     *  UI node is never deleted and it may lack an actual XML node attached. A non-mandatory
-     *  UI node MUST have an XML node attached and it will cease to exist when the XML node
-     *  ceases to exist.
-     */
-    public ViewElementDescriptor(String xml_name, String canonicalClassName,
-            ElementDescriptor[] children,
-            boolean mandatory) {
-        super(xml_name, children, mandatory);
-        mCanonicalClassName = canonicalClassName;
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name and children list.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param canonicalClassName The canonical class name the {@link ViewElementDescriptor} is
-     * representing.
-     * @param children The list of allowed children. Can be null or empty.
-     */
-    public ViewElementDescriptor(String xml_name, String canonicalClassName,
-            ElementDescriptor[] children) {
-        super(xml_name, children);
-        mCanonicalClassName = canonicalClassName;
-    }
-
-    /**
-     * Constructs a new {@link ElementDescriptor} based on its XML name and on the canonical
-     * name of the class it represents.
-     * The UI name is build by capitalizing the XML name.
-     * The UI nodes will be non-mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param canonicalClassName The canonical class name the {@link ViewElementDescriptor} is
-     * representing.
-     */
-    public ViewElementDescriptor(String xml_name, String canonicalClassName) {
-        super(xml_name);
-        mCanonicalClassName = canonicalClassName;
-    }
-    
-    /**
-     * Returns the canonical name of the class represented by this element descriptor.
-     */
-    public String getCanonicalClassName() {
-        return mCanonicalClassName;
-    }
-    
-    /** Returns the list of layout attributes. Can be empty but not null. */
-    public AttributeDescriptor[] getLayoutAttributes() {
-        return mLayoutAttributes;
-    }
-
-    /**
-     * @return A new {@link UiViewElementNode} linked to this descriptor.
-     */
-    @Override
-    public UiElementNode createUiNode() {
-        return new UiViewElementNode(this);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/DropFeedback.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/DropFeedback.java
deleted file mode 100644
index 6e79d64..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/DropFeedback.java
+++ /dev/null
@@ -1,761 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.layout.LayoutConstants;
-import com.android.ide.eclipse.editors.layout.LayoutEditor.UiEditorActions;
-import com.android.ide.eclipse.editors.layout.parts.UiLayoutEditPart.HighlightInfo;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-
-import java.util.HashMap;
-import java.util.Map.Entry;
-
-/**
- * Utility methods used when dealing with dropping EditPart on the GLE.
- * <p/>
- * This class uses some temporary static storage to avoid excessive allocations during
- * drop operations. It is expected to only be invoked from the main UI thread with no
- * concurrent access.
- */
-class DropFeedback {
-
-    private static final int TOP    = 0;
-    private static final int LEFT   = 1;
-    private static final int BOTTOM = 2;
-    private static final int RIGHT  = 3;
-    private static final int MAX_DIR = RIGHT;
-    
-    private static final int sOppositeDirection[] = { BOTTOM, RIGHT, TOP, LEFT };
-
-    private static final UiElementEditPart sTempClosests[] = new UiElementEditPart[4];
-    private static final int sTempMinDists[] = new int[4];
-    
-
-    /**
-     * Target information computed from a drop on a RelativeLayout.
-     * We need only one instance of this and it is sRelativeInfo.
-     */
-    private static class RelativeInfo {
-        /** The two target parts 0 and 1. They can be null, meaning a border is used.
-         *  The direction from part 0 to 1 is always to-the-right or to-the-bottom. */
-        final UiElementEditPart targetParts[] = new UiElementEditPart[2];
-        /** Direction from the anchor part to the drop point. */
-        int direction;
-        /** The index of the "anchor" part, i.e. the closest one selected by the drop.
-         *  This can be either 0 or 1. The corresponding part can be null. */
-        int anchorIndex;
-    }
-
-    /** The single RelativeInfo used to compute results from a drop on a RelativeLayout */
-    private static final RelativeInfo sRelativeInfo = new RelativeInfo();
-    /** A temporary array of 2 {@link UiElementEditPart} to avoid allocations. */
-    private static final UiElementEditPart sTempTwoParts[] = new UiElementEditPart[2];
-    
-
-    private DropFeedback() {
-    }
-
-    
-    //----- Package methods called by users of this helper class -----
-    
-    
-    /**
-     * This method is used by {@link ElementCreateCommand#execute()} when a new item
-     * needs to be "dropped" in the current XML document. It creates the new item using
-     * the given descriptor as a child of the given parent part.
-     * 
-     * @param parentPart The parent part.
-     * @param descriptor The descriptor for the new XML element.
-     * @param where      The drop location (in parent coordinates)
-     * @param actions    The helper that actually modifies the XML model.
-     */
-    static void addElementToXml(UiElementEditPart parentPart,
-            ElementDescriptor descriptor, Point where,
-            UiEditorActions actions) {
-        
-        String layoutXmlName = getXmlLocalName(parentPart);
-        RelativeInfo info = null;
-        UiElementEditPart sibling = null;
-        
-        if (LayoutConstants.LINEAR_LAYOUT.equals(layoutXmlName)) {
-            sibling = findLinearTarget(parentPart, where)[1];
-            
-        } else if (LayoutConstants.RELATIVE_LAYOUT.equals(layoutXmlName)) {
-            info = findRelativeTarget(parentPart, where, sRelativeInfo);
-            if (info != null) {
-                sibling = info.targetParts[info.anchorIndex];
-                sibling = getNextUiSibling(sibling);
-            }
-        }
-
-        if (actions != null) {
-            UiElementNode uiSibling = sibling != null ? sibling.getUiNode() : null;
-            UiElementNode uiParent = parentPart.getUiNode();
-            UiElementNode uiNode = actions.addElement(uiParent, uiSibling, descriptor,
-                    false /*updateLayout*/);
-            
-            if (LayoutConstants.ABSOLUTE_LAYOUT.equals(layoutXmlName)) {
-                adjustAbsoluteAttributes(uiNode, where);
-            } else if (LayoutConstants.RELATIVE_LAYOUT.equals(layoutXmlName)) {
-                adustRelativeAttributes(uiNode, info);
-            }
-        }
-    }
-
-    /**
-     * This method is used by {@link UiLayoutEditPart#showDropTarget(Point)} to compute
-     * highlight information when a drop target is moved over a valid drop area.
-     * <p/>
-     * Since there are no "out" parameters in Java, all the information is returned
-     * via the {@link HighlightInfo} structure passed as parameter. 
-     * 
-     * @param parentPart    The parent part, always a layout.
-     * @param highlightInfo A structure where result is stored to perform highlight.
-     * @param where         The target drop point, in parent's coordinates
-     * @return The {@link HighlightInfo} structured passed as a parameter, for convenience.
-     */
-    static HighlightInfo computeDropFeedback(UiLayoutEditPart parentPart,
-            HighlightInfo highlightInfo,
-            Point where) {
-        String layoutType = getXmlLocalName(parentPart);
-        
-        if (LayoutConstants.ABSOLUTE_LAYOUT.equals(layoutType)) {
-            highlightInfo.anchorPoint = where;
-            
-        } else if (LayoutConstants.LINEAR_LAYOUT.equals(layoutType)) {
-            boolean isVertical = isVertical(parentPart);
-
-            highlightInfo.childParts = findLinearTarget(parentPart, where);
-            computeLinearLine(parentPart, isVertical, highlightInfo);
-            
-        } else if (LayoutConstants.RELATIVE_LAYOUT.equals(layoutType)) {
-
-            RelativeInfo info = findRelativeTarget(parentPart, where, sRelativeInfo);
-            if (info != null) {
-                highlightInfo.childParts = sRelativeInfo.targetParts;
-                computeRelativeLine(parentPart, info, highlightInfo);
-            }
-        }
-        
-        return highlightInfo;
-    }
-    
-    
-    //----- Misc utilities -----
-    
-    /**
-     * Returns the next UI sibling of this part, i.e. the element which is just after in
-     * the UI/XML order in the same parent. Returns null if there's no such part.
-     * <p/>
-     * Note: by "UI sibling" here we mean the sibling in the UiNode hierarchy. By design the
-     * UiNode model has the <em>exact</em> same order as the XML model. This has nothing to do
-     * with the "user interface" order that you see on the rendered Android layouts (e.g. for
-     * LinearLayout they are the same but for AbsoluteLayout or RelativeLayout the UI/XML model
-     * order can be vastly different from the user interface order.)
-     */
-    private static UiElementEditPart getNextUiSibling(UiElementEditPart part) {
-        if (part != null) {
-            UiElementNode uiNode = part.getUiNode();
-            if (uiNode != null) {
-                uiNode = uiNode.getUiNextSibling();
-            }
-            if (uiNode != null) {
-                for (Object childPart : part.getParent().getChildren()) {
-                    if (childPart instanceof UiElementEditPart &&
-                            ((UiElementEditPart) childPart).getUiNode() == uiNode) {
-                        return (UiElementEditPart) childPart;
-                    }
-                }
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Returns the XML local name of the ui node associated with this edit part or null.
-     */
-    private static String getXmlLocalName(UiElementEditPart editPart) {
-        UiElementNode uiNode = editPart.getUiNode();
-        if (uiNode != null) {
-            ElementDescriptor desc = uiNode.getDescriptor();
-            if (desc != null) {
-                return desc.getXmlLocalName();
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Adjusts the attributes of a new node dropped in an AbsoluteLayout.
-     * 
-     * @param uiNode The new node being dropped.
-     * @param where  The drop location (in parent coordinates)
-     */
-    private static void adjustAbsoluteAttributes(final UiElementNode uiNode, final Point where) {
-        if (where == null) {
-            return;
-        }
-        uiNode.getEditor().editXmlModel(new Runnable() {
-            public void run() {
-                uiNode.setAttributeValue(LayoutConstants.ATTR_LAYOUT_X,
-                        String.format(LayoutConstants.VALUE_N_DIP, where.x),
-                        false /* override */);
-                uiNode.setAttributeValue(LayoutConstants.ATTR_LAYOUT_Y,
-                        String.format(LayoutConstants.VALUE_N_DIP, where.y),
-                        false /* override */);
-
-                uiNode.commitDirtyAttributesToXml();
-            }
-        });
-    }
-
-    /**
-     * Adjusts the attributes of a new node dropped in a RelativeLayout:
-     * <ul>
-     * <li> anchor part: the one the user selected (or the closest) and to which the new one
-     *      will "attach". The anchor part can be null, either because the layout is currently
-     *      empty or the user is attaching to an existing empty border.
-     * <li> direction: the direction from the anchor part to the drop point. That's also the
-     *      direction from the anchor part to the new part. 
-     * <li> the new node; it is created either after the anchor for right or top directions
-     *      or before the anchor for left or bottom directions. This means the new part can 
-     *      reference the id of the anchor part. 
-     * </ul>
-     * 
-     * Several cases:
-     * <ul>
-     * <li> set:  layout_above/below/toLeftOf/toRightOf to point to the anchor.
-     * <li> copy: layout_centerHorizontal for top/bottom directions
-     * <li> copy: layout_centerVertical for left/right directions.
-     * <li> copy: layout_above/below/toLeftOf/toRightOf for the orthogonal direction
-     *            (i.e. top/bottom or left/right.)
-     * </ul>
-     * 
-     * @param uiNode The new node being dropped.
-     * @param info   The context computed by {@link #findRelativeTarget(UiElementEditPart, Point, RelativeInfo)}.
-     */
-    private static void adustRelativeAttributes(final UiElementNode uiNode, RelativeInfo info) {
-        if (uiNode == null || info == null) {
-            return;
-        }
-        
-        final UiElementEditPart anchorPart = info.targetParts[info.anchorIndex];  // can be null       
-        final int direction = info.direction;
-        
-        uiNode.getEditor().editXmlModel(new Runnable() {
-            public void run() {
-                HashMap<String, String> map = new HashMap<String, String>();
-
-                UiElementNode anchorUiNode = anchorPart != null ? anchorPart.getUiNode() : null;
-                String anchorId = anchorUiNode != null
-                                    ? anchorUiNode.getAttributeValue("id")          //$NON-NLS-1$
-                                    : null;
-
-                if (anchorId == null) {
-                    anchorId = DescriptorsUtils.getFreeWidgetId(anchorUiNode);
-                    anchorUiNode.setAttributeValue("id", anchorId, true /*override*/); //$NON-NLS-1$
-                }
-                
-                if (anchorId != null) {
-                    switch(direction) {
-                    case TOP:
-                        map.put(LayoutConstants.ATTR_LAYOUT_ABOVE, anchorId);
-                        break;
-                    case BOTTOM:
-                        map.put(LayoutConstants.ATTR_LAYOUT_BELOW, anchorId);
-                        break;
-                    case LEFT:
-                        map.put(LayoutConstants.ATTR_LAYOUT_TO_LEFT_OF, anchorId);
-                        break;
-                    case RIGHT:
-                        map.put(LayoutConstants.ATTR_LAYOUT_TO_RIGHT_OF, anchorId);
-                        break;
-                    }
-
-                    switch(direction) {
-                    case TOP:
-                    case BOTTOM:
-                        map.put(LayoutConstants.ATTR_LAYOUT_CENTER_HORIZONTAL,
-                                anchorUiNode.getAttributeValue(
-                                        LayoutConstants.ATTR_LAYOUT_CENTER_HORIZONTAL));
-
-                        map.put(LayoutConstants.ATTR_LAYOUT_TO_LEFT_OF,
-                                anchorUiNode.getAttributeValue(
-                                        LayoutConstants.ATTR_LAYOUT_TO_LEFT_OF));
-                        map.put(LayoutConstants.ATTR_LAYOUT_TO_RIGHT_OF,
-                                anchorUiNode.getAttributeValue(
-                                        LayoutConstants.ATTR_LAYOUT_TO_RIGHT_OF));
-                        break;
-                    case LEFT:
-                    case RIGHT:
-                        map.put(LayoutConstants.ATTR_LAYOUT_CENTER_VERTICAL,
-                                anchorUiNode.getAttributeValue(
-                                        LayoutConstants.ATTR_LAYOUT_CENTER_VERTICAL));
-                        map.put(LayoutConstants.ATTR_LAYOUT_ALIGN_BASELINE,
-                                anchorUiNode.getAttributeValue(
-                                        LayoutConstants.ATTR_LAYOUT_ALIGN_BASELINE));
-                        
-                        map.put(LayoutConstants.ATTR_LAYOUT_ABOVE,
-                                anchorUiNode.getAttributeValue(LayoutConstants.ATTR_LAYOUT_ABOVE));
-                        map.put(LayoutConstants.ATTR_LAYOUT_BELOW,
-                                anchorUiNode.getAttributeValue(LayoutConstants.ATTR_LAYOUT_BELOW));
-                        break;
-                    }
-                } else {
-                    // We don't have an anchor node. Assume we're targeting a border and align
-                    // to the parent.
-                    switch(direction) {
-                    case TOP:
-                        map.put(LayoutConstants.ATTR_LAYOUT_ALIGN_PARENT_TOP,
-                                LayoutConstants.VALUE_TRUE);
-                        break;
-                    case BOTTOM:
-                        map.put(LayoutConstants.ATTR_LAYOUT_ALIGN_PARENT_BOTTOM,
-                                LayoutConstants.VALUE_TRUE);
-                        break;
-                    case LEFT:
-                        map.put(LayoutConstants.ATTR_LAYOUT_ALIGN_PARENT_LEFT,
-                                LayoutConstants.VALUE_TRUE);
-                        break;
-                    case RIGHT:
-                        map.put(LayoutConstants.ATTR_LAYOUT_ALIGN_PARENT_RIGHT,
-                                LayoutConstants.VALUE_TRUE);
-                        break;
-                    }
-                }
-                
-                for (Entry<String, String> entry : map.entrySet()) {
-                    uiNode.setAttributeValue(entry.getKey(), entry.getValue(), true /* override */);
-                }
-                uiNode.commitDirtyAttributesToXml();
-            }
-        });
-    }
-
-
-    //----- LinearLayout --------
-
-    /**
-     * For a given parent edit part that MUST represent a LinearLayout, finds the
-     * element before which the location points.
-     * <p/>
-     * This computes the edit part that corresponds to what will be the "next sibling" of the new
-     * element.
-     * <p/>
-     * It returns null if it can't be determined, in which case the element will be added at the
-     * end of the parent child list.
-     * 
-     * @return The edit parts that correspond to what will be the "prev" and "next sibling" of the
-     *         new element. The previous sibling can be null if adding before the first element.
-     *         The next sibling can be null if adding after the last element.
-     */
-    private static UiElementEditPart[] findLinearTarget(UiElementEditPart parent, Point point) {
-        // default orientation is horizontal
-        boolean isVertical = isVertical(parent);
-        
-        int target = isVertical ? point.y : point.x;
-        
-        UiElementEditPart prev = null;
-        UiElementEditPart next = null;
-
-        for (Object child : parent.getChildren()) {
-            if (child instanceof UiElementEditPart) {
-                UiElementEditPart childPart = (UiElementEditPart) child;
-                Point p = childPart.getBounds().getCenter();
-                int middle = isVertical ? p.y : p.x;
-                if (target < middle) {
-                    next = childPart;
-                    break;
-                }
-                prev = childPart;
-            }
-        }
-        
-        sTempTwoParts[0] = prev;
-        sTempTwoParts[1] = next;
-        return sTempTwoParts;
-    }
-
-    /**
-     * Computes the highlight line between two parts.
-     * <p/>
-     * The two parts are listed in HighlightInfo.childParts[2]. Any of the parts
-     * can be null.
-     * The result is stored in HighlightInfo.
-     * <p/>
-     * Caller must clear the HighlightInfo as appropriate before this call.
-     * 
-     * @param parentPart    The parent part, always a layout.
-     * @param isVertical    True for vertical parts, thus computing an horizontal line.
-     * @param highlightInfo The in-out highlight info.
-     */
-    private static void computeLinearLine(UiLayoutEditPart parentPart,
-            boolean isVertical, HighlightInfo highlightInfo) {
-        Rectangle r = parentPart.getBounds();
-
-        if (isVertical) {
-            Point p = null;
-            UiElementEditPart part = highlightInfo.childParts[0];
-            if (part != null) {
-                p = part.getBounds().getBottom();
-            } else {
-                part = highlightInfo.childParts[1];
-                if (part != null) {
-                    p = part.getBounds().getTop();
-                }
-            }
-            if (p != null) {
-                // horizontal line with middle anchor point
-                highlightInfo.tempPoints[0].setLocation(0, p.y);
-                highlightInfo.tempPoints[1].setLocation(r.width, p.y);
-                highlightInfo.linePoints = highlightInfo.tempPoints;
-                highlightInfo.anchorPoint = p.setLocation(r.width / 2, p.y);
-            }
-        } else {
-            Point p = null;
-            UiElementEditPart part = highlightInfo.childParts[0];
-            if (part != null) {
-                p = part.getBounds().getRight();
-            } else {
-                part = highlightInfo.childParts[1];
-                if (part != null) {
-                    p = part.getBounds().getLeft();
-                }
-            }
-            if (p != null) {
-                // vertical line with middle anchor point
-                highlightInfo.tempPoints[0].setLocation(p.x, 0);
-                highlightInfo.tempPoints[1].setLocation(p.x, r.height);
-                highlightInfo.linePoints = highlightInfo.tempPoints;
-                highlightInfo.anchorPoint = p.setLocation(p.x, r.height / 2);
-            }
-        }
-    }
-
-    /**
-     * Returns true if the linear layout is marked as vertical.
-     * 
-     * @param parent The a layout part that must be a LinearLayout 
-     * @return True if the linear layout has a vertical orientation attribute.
-     */
-    private static boolean isVertical(UiElementEditPart parent) {
-        String orientation = parent.getStringAttr("orientation");     //$NON-NLS-1$
-        boolean isVertical = "vertical".equals(orientation) ||        //$NON-NLS-1$ 
-                             "1".equals(orientation);                 //$NON-NLS-1$
-        return isVertical;
-    }
-
-    
-    //----- RelativeLayout --------
-
-    /**
-     * Finds the "target" relative layout item for the drop operation & feedback.
-     * <p/>
-     * If the drop point is exactly on a current item, simply returns the side the drop will occur
-     * compared to the center of that element. For the actual XML, we'll need to insert *after*
-     * that element to make sure that referenced are defined in the right order.
-     * In that case the result contains two elements, the second one always being on the right or
-     * bottom side of the first one. When insert in XML, we want to insert right before that
-     * second element or at the end of the child list if the second element is null.
-     * <p/>
-     * If the drop point is not exactly on a current element, find the closest in each
-     * direction and align with the two closest of these.
-     * 
-     * @return null if we fail to find anything (such as there are currently no items to compare
-     *         with); otherwise fills the {@link RelativeInfo} and return it.
-     */
-    private static RelativeInfo findRelativeTarget(UiElementEditPart parent,
-            Point point,
-            RelativeInfo outInfo) {
-        
-        for (int i = 0; i < 4; i++) {
-            sTempMinDists[i] = Integer.MAX_VALUE;
-            sTempClosests[i] = null;
-        }
-
-        
-        for (Object child : parent.getChildren()) {
-            if (child instanceof UiElementEditPart) {
-                UiElementEditPart childPart = (UiElementEditPart) child;
-                Rectangle r = childPart.getBounds();
-                if (r.contains(point)) {
-                    
-                    float rx = ((float)(point.x - r.x) / (float)r.width ) - 0.5f;
-                    float ry = ((float)(point.y - r.y) / (float)r.height) - 0.5f;
-
-                    /*   TOP
-                     *  \   /
-                     *   \ /
-                     * L  X  R
-                     *   / \
-                     *  /   \
-                     *   BOT
-                     */
-
-                    int index = 0;
-                    if (Math.abs(rx) >= Math.abs(ry)) {
-                        if (rx < 0) {
-                            outInfo.direction = LEFT;
-                            index = 1;
-                        } else {
-                            outInfo.direction = RIGHT;
-                        }
-                    } else {
-                        if (ry < 0) {
-                            outInfo.direction = TOP;
-                            index = 1;
-                        } else {
-                            outInfo.direction = BOTTOM;
-                        }
-                    }
-
-                    outInfo.anchorIndex = index;
-                    outInfo.targetParts[index] = childPart;
-                    outInfo.targetParts[1 - index] = findClosestPart(childPart,
-                            outInfo.direction);
-
-                    return outInfo;
-                }
-                
-                computeClosest(point, childPart, sTempClosests, sTempMinDists, TOP);
-                computeClosest(point, childPart, sTempClosests, sTempMinDists, LEFT);
-                computeClosest(point, childPart, sTempClosests, sTempMinDists, BOTTOM);
-                computeClosest(point, childPart, sTempClosests, sTempMinDists, RIGHT);
-            }
-        }
-        
-        UiElementEditPart closest = null;
-        int minDist = Integer.MAX_VALUE;
-        int minDir = -1;
-        
-        for (int i = 0; i <= MAX_DIR; i++) {
-            if (sTempClosests[i] != null && sTempMinDists[i] < minDist) {
-                closest = sTempClosests[i];
-                minDist = sTempMinDists[i];
-                minDir = i;
-            }
-        }
-        
-        if (closest != null) {
-            int index = 0;
-            switch(minDir) {
-            case TOP:
-            case LEFT:
-                index = 0;
-                break;
-            case BOTTOM:
-            case RIGHT:
-                index = 1;
-                break;
-            }
-            outInfo.anchorIndex = index;
-            outInfo.targetParts[index] = closest;
-            outInfo.targetParts[1 - index] = findClosestPart(closest, sOppositeDirection[minDir]);
-            outInfo.direction = sOppositeDirection[minDir];
-            return outInfo;
-        }
-
-        return null;
-    }
-
-    /**
-     * Computes the highlight line for a drop on a RelativeLayout.
-     * <p/>
-     * The line is always placed on the side of the anchor part indicated by the
-     * direction. The direction always point from the anchor part to the drop point.
-     * <p/>
-     * If there's no anchor part, use the other one with a reversed direction.
-     * <p/>
-     * On output, this updates the {@link HighlightInfo}.
-     */
-    private static void computeRelativeLine(UiLayoutEditPart parentPart,
-            RelativeInfo relInfo,
-            HighlightInfo highlightInfo) {
-
-        UiElementEditPart[] parts = relInfo.targetParts;
-        int dir = relInfo.direction;
-        int index = relInfo.anchorIndex;
-        UiElementEditPart part = parts[index];
-
-        if (part == null) {
-            dir = sOppositeDirection[dir];
-            part = parts[1 - index];
-        }
-        if (part == null) {
-            // give up if both parts are null
-            return;
-        }
-
-        Rectangle r = part.getBounds();
-        Point p = null;
-        switch(dir) {
-        case TOP:
-            p = r.getTop();
-            break;
-        case BOTTOM:
-            p = r.getBottom();
-            break;
-        case LEFT:
-            p = r.getLeft();
-            break;
-        case RIGHT:
-            p = r.getRight();
-            break;
-        }
-
-        highlightInfo.anchorPoint = p;
-
-        r = parentPart.getBounds();
-        switch(dir) {
-        case TOP:
-        case BOTTOM:
-            // horizontal line with middle anchor point
-            highlightInfo.tempPoints[0].setLocation(0, p.y);
-            highlightInfo.tempPoints[1].setLocation(r.width, p.y);
-            highlightInfo.linePoints = highlightInfo.tempPoints;
-            highlightInfo.anchorPoint = p;
-            break;
-        case LEFT:
-        case RIGHT:
-            // vertical line with middle anchor point
-            highlightInfo.tempPoints[0].setLocation(p.x, 0);
-            highlightInfo.tempPoints[1].setLocation(p.x, r.height);
-            highlightInfo.linePoints = highlightInfo.tempPoints;
-            highlightInfo.anchorPoint = p;
-            break;
-        }
-    }
-
-    /**
-     * Given a certain reference point (drop point), computes the distance to the given
-     * part in the given direction. For example if direction is top, only accepts parts which
-     * bottom is above the reference point, computes their distance and then updates the
-     * current minimal distances and current closest parts arrays accordingly.
-     */
-    private static void computeClosest(Point refPoint,
-            UiElementEditPart compareToPart,
-            UiElementEditPart[] currClosests,
-            int[] currMinDists,
-            int direction) {
-        Rectangle r = compareToPart.getBounds();
-
-        Point p = null;
-        boolean usable = false;
-        
-        switch(direction) {
-        case TOP:
-            p = r.getBottom();
-            usable = p.y <= refPoint.y;
-            break;
-        case BOTTOM:
-            p = r.getTop();
-            usable = p.y >= refPoint.y;
-            break;
-        case LEFT:
-            p = r.getRight();
-            usable = p.x <= refPoint.x;
-            break;
-        case RIGHT:
-            p = r.getLeft();
-            usable = p.x >= refPoint.x;
-            break;
-        }
-
-        if (usable) {
-            int d = p.getDistance2(refPoint);
-            if (d < currMinDists[direction]) {
-                currMinDists[direction] = d;
-                currClosests[direction] = compareToPart;
-            }
-        }
-    }
-
-    /**
-     * Given a reference parts, finds the closest part in the parent in the given direction.
-     * For example if direction is top, finds the closest sibling part which is above the
-     * reference part and non-overlapping (they can touch.)
-     */
-    private static UiElementEditPart findClosestPart(UiElementEditPart referencePart,
-            int direction) {
-        if (referencePart == null || referencePart.getParent() == null) {
-            return null;
-        }
-        
-        Rectangle r = referencePart.getBounds();
-        Point ref = null;
-        switch(direction) {
-        case TOP:
-            ref = r.getTop();
-            break;
-        case BOTTOM:
-            ref = r.getBottom();
-            break;
-        case LEFT:
-            ref = r.getLeft();
-            break;
-        case RIGHT:
-            ref = r.getRight();
-            break;
-        }
-        
-        int minDist = Integer.MAX_VALUE;
-        UiElementEditPart closestPart = null;
-        
-        for (Object childPart : referencePart.getParent().getChildren()) {
-            if (childPart != referencePart && childPart instanceof UiElementEditPart) {
-                r = ((UiElementEditPart) childPart).getBounds();
-                Point p = null;
-                boolean usable = false;
-                
-                switch(direction) {
-                case TOP:
-                    p = r.getBottom();
-                    usable = p.y <= ref.y;
-                    break;
-                case BOTTOM:
-                    p = r.getTop();
-                    usable = p.y >= ref.y;
-                    break;
-                case LEFT:
-                    p = r.getRight();
-                    usable = p.x <= ref.x;
-                    break;
-                case RIGHT:
-                    p = r.getLeft();
-                    usable = p.x >= ref.x;
-                    break;
-                }
-
-                if (usable) {
-                    int d = p.getDistance2(ref);
-                    if (d < minDist) {
-                        minDist = d;
-                        closestPart = (UiElementEditPart) childPart;
-                    }
-                }
-            }
-        }
-        
-        return closestPart;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementCreateCommand.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementCreateCommand.java
deleted file mode 100644
index d36d9f7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementCreateCommand.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.layout.LayoutEditor;
-import com.android.ide.eclipse.editors.layout.LayoutEditor.UiEditorActions;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.commands.Command;
-
-/**
- * A command that knows how to instantiate a new element based on a given {@link ElementDescriptor},
- * the parent {@link UiElementEditPart} and an optional target location.
- */
-public class ElementCreateCommand extends Command {
-
-    /** Descriptor of the new element to create */
-    private final ElementDescriptor mDescriptor;
-    /** The edit part that hosts the new edit part */
-    private final UiElementEditPart mParentPart;
-    /** The drop location in parent coordinates */
-    private final Point mTargetPoint;
-
-    /**
-     * Creates a new {@link ElementCreateCommand}.
-     * 
-     * @param descriptor Descriptor of the new element to create
-     * @param targetPart The edit part that hosts the new edit part
-     * @param targetPoint The drop location in parent coordinates
-     */
-    public ElementCreateCommand(ElementDescriptor descriptor,
-            UiElementEditPart targetPart, Point targetPoint) {
-                mDescriptor = descriptor;
-                mParentPart = targetPart;
-                mTargetPoint = targetPoint;
-    }
-    
-    // --- Methods inherited from Command ---
-
-    @Override
-    public boolean canExecute() {
-        return mDescriptor != null &&
-            mParentPart != null &&
-            mParentPart.getUiNode() != null &&
-            mParentPart.getUiNode().getEditor() instanceof LayoutEditor;
-    }
-
-    @Override
-    public void execute() {
-        super.execute();
-        UiElementNode uiParent = mParentPart.getUiNode();
-        if (uiParent != null) {
-            final AndroidEditor editor = uiParent.getEditor();
-            if (editor instanceof LayoutEditor) {
-                ((LayoutEditor) editor).wrapUndoRecording(
-                        String.format("Create %1$s", mDescriptor.getXmlLocalName()),
-                        new Runnable() {
-                    public void run() {
-                        UiEditorActions actions = ((LayoutEditor) editor).getUiEditorActions();
-                        if (actions != null) {
-                            DropFeedback.addElementToXml(mParentPart, mDescriptor, mTargetPoint,
-                                    actions);
-                        }
-                    }
-                });
-            }
-        }        
-    }
-
-    @Override
-    public void redo() {
-        throw new UnsupportedOperationException("redo not supported by this command"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public void undo() {
-        throw new UnsupportedOperationException("undo not supported by this command"); //$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementFigure.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementFigure.java
deleted file mode 100644
index f863037..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/ElementFigure.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.Figure;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.swt.SWT;
-
-    
-/**
- * The figure used to draw basic elements.
- * <p/>
- * The figure is totally empty and transparent except for the selection border.
- */
-class ElementFigure extends Figure {
-
-    private boolean mIsSelected;
-    private Rectangle mInnerBounds;
-
-    public ElementFigure() {
-        setOpaque(false);
-    }
-    
-    public void setSelected(boolean isSelected) {
-        if (isSelected != mIsSelected) {
-            mIsSelected = isSelected;
-            repaint();
-        }
-    }
-    
-    @Override
-    public void setBounds(Rectangle rect) {
-        super.setBounds(rect);
-        
-        mInnerBounds = getBounds().getCopy();
-        if (mInnerBounds.width > 0) {
-            mInnerBounds.width--;
-        }
-        if (mInnerBounds.height > 0) {
-            mInnerBounds.height--;
-        }
-    }
-    
-    public Rectangle getInnerBounds() {
-        return mInnerBounds;
-    }
-    
-    @Override
-    protected void paintBorder(Graphics graphics) {
-        super.paintBorder(graphics);
-
-        if (mIsSelected) {
-            graphics.setLineWidth(1);
-            graphics.setLineStyle(SWT.LINE_SOLID);
-            graphics.setForegroundColor(ColorConstants.red);
-            graphics.drawRectangle(getInnerBounds());
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/LayoutFigure.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/LayoutFigure.java
deleted file mode 100644
index 55ed39b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/LayoutFigure.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.layout.parts.UiLayoutEditPart.HighlightInfo;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.Figure;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.swt.SWT;
-
-/**
- * The figure used to draw the feedback on a layout.
- * <p/>
- * By default the figure is transparent and empty.
- * The base {@link ElementFigure} knows how to draw the selection border.
- * This figure knows how to draw the drop feedback.
- */
-class LayoutFigure extends ElementFigure {
-
-    private HighlightInfo mHighlightInfo;
-    
-    public LayoutFigure() {
-        super();
-    }
-
-    public void setHighlighInfo(HighlightInfo highlightInfo) {
-        mHighlightInfo = highlightInfo;
-        repaint();
-    }
-
-    /**
-     * Paints the "border" for this figure.
-     * <p/>
-     * The parent {@link Figure#paint(Graphics)} calls {@link #paintFigure(Graphics)} then
-     * {@link #paintClientArea(Graphics)} then {@link #paintBorder(Graphics)}. Here we thus
-     * draw the actual highlight border but also the highlight anchor lines and points so that
-     * we can make sure they are all drawn on top of the border. 
-     * <p/>
-     * Note: This method doesn't really need to restore its graphic state. The parent
-     * Figure will do it for us.
-     * <p/>
-     * 
-     * @param graphics The Graphics object used for painting
-     */
-    @Override
-    protected void paintBorder(Graphics graphics) {
-        super.paintBorder(graphics);
-
-        if (mHighlightInfo == null) {
-            return;
-        }
-
-        // Draw the border. We want other highlighting to be drawn on top of the border.
-        if (mHighlightInfo.drawDropBorder) {
-            graphics.setLineWidth(3);
-            graphics.setLineStyle(SWT.LINE_SOLID);
-            graphics.setForegroundColor(ColorConstants.green);
-            graphics.drawRectangle(getInnerBounds().getCopy().shrink(1, 1));
-        }
-
-        Rectangle bounds = getBounds();
-        int bx = bounds.x;
-        int by = bounds.y;
-        int w = bounds.width;
-        int h = bounds.height;
-
-        // Draw frames of target child parts, if any
-        if (mHighlightInfo.childParts != null) {
-            graphics.setLineWidth(2);
-            graphics.setLineStyle(SWT.LINE_DOT);
-            graphics.setForegroundColor(ColorConstants.lightBlue);
-            for (UiElementEditPart part : mHighlightInfo.childParts) {
-                if (part != null) {
-                    graphics.drawRectangle(part.getBounds().getCopy().translate(bx, by));
-                }
-            }
-        }
-
-        // Draw the target line, if any
-        if (mHighlightInfo.linePoints != null) {
-            int x1 = mHighlightInfo.linePoints[0].x;
-            int y1 = mHighlightInfo.linePoints[0].y;
-            int x2 = mHighlightInfo.linePoints[1].x;
-            int y2 = mHighlightInfo.linePoints[1].y;
-            
-            // if the line is right to the edge, draw it one pixel more inside so that the
-            // full 2-pixel width be visible.
-            if (x1 <= 0) x1++;
-            if (x2 <= 0) x2++;
-            if (y1 <= 0) y1++;
-            if (y2 <= 0) y2++;
-
-            if (x1 >= w - 1) x1--;
-            if (x2 >= w - 1) x2--;
-            if (y1 >= h - 1) y1--;
-            if (y2 >= h - 1) y2--;
-            
-            x1 += bx;
-            x2 += bx;
-            y1 += by;
-            y2 += by;
-            
-            graphics.setLineWidth(2);
-            graphics.setLineStyle(SWT.LINE_DASH);
-            graphics.setLineCap(SWT.CAP_ROUND);
-            graphics.setForegroundColor(ColorConstants.orange);
-            graphics.drawLine(x1, y1, x2, y2);
-        }
-
-        // Draw the anchor point, if any
-        if (mHighlightInfo.anchorPoint != null) {
-            int x = mHighlightInfo.anchorPoint.x;
-            int y = mHighlightInfo.anchorPoint.y;
-
-            // If the point is right on the edge, draw it one pixel inside so that it
-            // matches the highlight line. It makes it slightly more visible that way.
-            if (x <= 0) x++;
-            if (y <= 0) y++;
-            if (x >= w - 1) x--;
-            if (y >= h - 1) y--;
-            x += bx;
-            y += by;
-
-            graphics.setLineWidth(2);
-            graphics.setLineStyle(SWT.LINE_SOLID);
-            graphics.setLineCap(SWT.CAP_ROUND);
-            graphics.setForegroundColor(ColorConstants.orange);
-            graphics.drawLine(x-5, y-5, x+5, y+5);
-            graphics.drawLine(x-5, y+5, x+5, y-5);
-            // 7 * cos(45) == 5 so we use 8 for the circle radius (it looks slightly better than 7)
-            graphics.setLineWidth(1);
-            graphics.drawOval(x-8, y-8, 16, 16);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentEditPart.java
deleted file mode 100644
index 2f7636d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentEditPart.java
+++ /dev/null
@@ -1,212 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.draw2d.AbstractBackground;
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.FreeformLayer;
-import org.eclipse.draw2d.FreeformLayout;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.RequestConstants;
-import org.eclipse.gef.editpolicies.RootComponentEditPolicy;
-import org.eclipse.gef.requests.DropRequest;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.PaletteData;
-import org.eclipse.swt.widgets.Display;
-
-import java.awt.image.BufferedImage;
-import java.awt.image.DataBufferInt;
-
-/**
- * Graphical edit part for the root document.
- * <p/>
- * It acts as a simple container. 
- */
-public class UiDocumentEditPart extends UiElementEditPart {
-    
-    private Display mDisplay;
-    private FreeformLayer mLayer;
-    private ImageBackground mImage;
-    private Label mChild = null;
-    
-    final static class ImageBackground extends AbstractBackground {
-        
-        private BufferedImage mBufferedImage;
-        private Image mImage;
-
-        ImageBackground() {
-        }
-        
-        ImageBackground(BufferedImage image, Display display) {
-            setImage(image, display);
-        }
-        
-        @Override
-        public void paintBackground(IFigure figure, Graphics graphics, Insets insets) {
-            if (mImage != null) {
-                Rectangle rect = getPaintRectangle(figure, insets);
-                graphics.drawImage(mImage, rect.x, rect.y);
-            }
-        }
-        
-        void setImage(BufferedImage image, Display display) {
-            if (image != null) {
-                int[] data = ((DataBufferInt)image.getData().getDataBuffer()).getData();
-
-                ImageData imageData = new ImageData(image.getWidth(), image.getHeight(), 32,
-                      new PaletteData(0x00FF0000, 0x0000FF00, 0x000000FF));
-
-                imageData.setPixels(0, 0, data.length, data, 0);
-
-                mImage = new Image(display, imageData);
-            } else {
-                mImage = null;
-            }
-        }
-
-        BufferedImage getBufferedImage() {
-            return mBufferedImage;
-        }
-    }
-
-    public UiDocumentEditPart(UiDocumentNode uiDocumentNode, Display display) {
-        super(uiDocumentNode);
-        mDisplay = display;
-    }
-
-    @Override
-    protected IFigure createFigure() {
-        mLayer = new FreeformLayer();
-        mLayer.setLayoutManager(new FreeformLayout());
-        
-        mLayer.setOpaque(true);
-        mLayer.setBackgroundColor(ColorConstants.lightGray);
-        
-        return mLayer;
-    }
-    
-    @Override
-    protected void refreshVisuals() {
-        UiElementNode model = (UiElementNode)getModel();
-        
-        Object editData = model.getEditData();
-        if (editData instanceof BufferedImage) {
-            BufferedImage image = (BufferedImage)editData;
-            
-            if (mImage == null || image != mImage.getBufferedImage()) {
-                mImage = new ImageBackground(image, mDisplay);
-            }
-            
-            mLayer.setBorder(mImage);
-            
-            if (mChild != null && mChild.getParent() == mLayer) {
-                mLayer.remove(mChild);
-            }
-        } else if (editData instanceof String) {
-            mLayer.setBorder(null);
-            if (mChild == null) {
-                mChild = new Label();
-            }
-            mChild.setText((String)editData);
-
-            if (mChild != null && mChild.getParent() != mLayer) {
-                mLayer.add(mChild);
-            }
-            Rectangle bounds = mChild.getTextBounds();
-            bounds.x = bounds.y = 0;
-            mLayer.setConstraint(mChild, bounds);
-        }
-
-        // refresh the children as well
-        refreshChildrenVisuals();
-    }
-
-    @Override
-    protected void hideSelection() {
-        // no selection at this level.
-    }
-
-    @Override
-    protected void showSelection() {
-        // no selection at this level.
-    }
-    
-    @Override
-    protected void createEditPolicies() {
-        super.createEditPolicies();
-
-        // This policy indicates this a root component that cannot be removed
-        installEditPolicy(EditPolicy.COMPONENT_ROLE, new RootComponentEditPolicy());
-
-        installLayoutEditPolicy(this);
-    }
-
-    /**
-     * Returns the EditPart that should be used as the target for the specified Request. 
-     * For instance this is called during drag'n'drop with a CreateRequest.
-     * <p/>
-     * For the root document, we want the first child edit part to the be the target
-     * since an XML document can have only one root element.
-     * 
-     * {@inheritDoc}
-     */
-    @Override
-    public EditPart getTargetEditPart(Request request) {
-        if (request != null && request.getType() == RequestConstants.REQ_CREATE) {
-            // We refuse the drop if it's not in the bounds of the document.
-            if (request instanceof DropRequest) {
-                Point where = ((DropRequest) request).getLocation().getCopy();
-                UiElementNode uiNode = getUiNode();
-                if (uiNode instanceof UiDocumentNode) {
-                    // Take the bounds of the background image as the valid drop zone
-                    Object editData = uiNode.getEditData();
-                    if (editData instanceof BufferedImage) {
-                        BufferedImage image = (BufferedImage)editData;
-                        int w = image.getWidth();
-                        int h = image.getHeight();
-                        if (where.x > w || where.y > h) {
-                            return null;
-                        }
-                    }
-                    
-                }
-            }
-
-            // For the root document, we want the first child edit part to the be the target
-            // since an XML document can have only one root element.
-            if (getChildren().size() > 0) {
-                Object o = getChildren().get(0);
-                if (o instanceof EditPart) {
-                    return ((EditPart) o).getTargetEditPart(request);
-                }
-            }
-        }
-        return super.getTargetEditPart(request);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentTreeEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentTreeEditPart.java
deleted file mode 100644
index af22afb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiDocumentTreeEditPart.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-
-import java.util.List;
-
-/**
- * Implementation of {@link UiElementTreeEditPart} for the document root.
- */
-public class UiDocumentTreeEditPart extends UiElementTreeEditPart {
-
-    public UiDocumentTreeEditPart(UiDocumentNode model) {
-        super(model);
-    }
-    
-    @SuppressWarnings("unchecked")
-    @Override
-    protected List getModelChildren() {
-        return getUiNode().getUiChildren();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementEditPart.java
deleted file mode 100644
index a2e05c7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementEditPart.java
+++ /dev/null
@@ -1,345 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.DragTracker;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.RequestConstants;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editparts.AbstractGraphicalEditPart;
-import org.eclipse.gef.editpolicies.LayoutEditPolicy;
-import org.eclipse.gef.editpolicies.SelectionEditPolicy;
-import org.eclipse.gef.requests.CreateRequest;
-import org.eclipse.gef.requests.DropRequest;
-import org.eclipse.gef.tools.SelectEditPartTracker;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-
-import java.util.List;
-
-/**
- * An {@link EditPart} for a {@link UiElementNode}.
- */
-public abstract class UiElementEditPart extends AbstractGraphicalEditPart
-    implements IUiUpdateListener {
-    
-    public UiElementEditPart(UiElementNode uiElementNode) {
-        setModel(uiElementNode);
-    }
-
-    //-------------------------
-    // Derived classes must define these
-
-    abstract protected void hideSelection();
-    abstract protected void showSelection();
-
-    //-------------------------
-    // Base class overrides
-    
-    @Override
-    public DragTracker getDragTracker(Request request) {
-        return new SelectEditPartTracker(this);
-    }
-
-    @Override
-    protected void createEditPolicies() {
-        /*
-         * This is no longer needed, as a selection edit policy is set by the parent layout.
-         * Leave this code commented out right now, I'll want to play with this later.
-         * 
-        installEditPolicy(EditPolicy.SELECTION_FEEDBACK_ROLE,
-                new NonResizableSelectionEditPolicy(this));
-         */
-    }
-    
-    /* (non-javadoc)
-     * Returns a List containing the children model objects.
-     * Must not return null, instead use the super which returns an empty list.
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    protected List getModelChildren() {
-        return getUiNode().getUiChildren();
-    }
-
-    @Override
-    public void activate() {
-        super.activate();
-        getUiNode().addUpdateListener(this);
-    }
-    
-    @Override
-    public void deactivate() {
-        super.deactivate();
-        getUiNode().removeUpdateListener(this);
-    }
-
-    @Override
-    protected void refreshVisuals() {
-        if (getFigure().getParent() != null) {
-            ((GraphicalEditPart) getParent()).setLayoutConstraint(this, getFigure(), getBounds());
-        }
-        
-        // update the visuals of the children as well
-        refreshChildrenVisuals();
-    }
-    
-    protected void refreshChildrenVisuals() {
-        if (children != null) {
-            for (Object child : children) {
-                if (child instanceof UiElementEditPart) {
-                    UiElementEditPart childPart = (UiElementEditPart)child;
-                    childPart.refreshVisuals();
-                }
-            }
-        }
-    }
-
-    //-------------------------
-    // IUiUpdateListener implementation
-
-    public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-        // TODO: optimize by refreshing only when needed
-        switch(state) {
-        case ATTR_UPDATED:
-            refreshVisuals();
-            break;
-        case CHILDREN_CHANGED:
-            refreshChildren();
-            
-            // new children list, need to update the layout
-            refreshVisuals();
-            break;
-        case CREATED:
-            refreshVisuals();
-            break;
-        case DELETED:
-            // pass
-            break;
-        }
-    }
-
-    //-------------------------
-    // Local methods
-
-    /** @return The object model casted to an {@link UiElementNode} */
-    public final UiElementNode getUiNode() {
-        return (UiElementNode) getModel();
-    }
-    
-    protected final ElementDescriptor getDescriptor() {
-        return getUiNode().getDescriptor();
-    }
-    
-    protected final UiElementEditPart getEditPartParent() {
-        EditPart parent = getParent();
-        if (parent instanceof UiElementEditPart) {
-            return (UiElementEditPart)parent; 
-        }
-        return null;
-    }
-    
-    /**
-     * Returns a given XML attribute.
-     * @param attrName The local name of the attribute.
-     * @return the attribute as a {@link String}, if it exists, or <code>null</code>
-     */
-    protected final String getStringAttr(String attrName) {
-        UiElementNode uiNode = getUiNode();
-        if (uiNode.getXmlNode() != null) {
-            Node xmlNode = uiNode.getXmlNode();
-            if (xmlNode != null) {
-                NamedNodeMap nodeAttributes = xmlNode.getAttributes();
-                if (nodeAttributes != null) {
-                    Node attr = nodeAttributes.getNamedItemNS(
-                            SdkConstants.NS_RESOURCES, attrName);
-                    if (attr != null) {
-                        return attr.getNodeValue();
-                    }
-                }
-            }
-        }
-        return null;
-    }
-    
-    protected final Rectangle getBounds() {
-        UiElementNode model = (UiElementNode)getModel();
-        
-        Object editData = model.getEditData();
-
-        if (editData != null) {
-            // assert with fully qualified class name to prevent import changes to another
-            // Rectangle class.
-            assert (editData instanceof org.eclipse.draw2d.geometry.Rectangle);
-    
-            return (Rectangle)editData;
-        }
-
-        // return a dummy rect
-        return new Rectangle(0, 0, 0, 0);
-    }
-
-    /**
-     * Returns the EditPart that should be used as the target for the specified Request. 
-     * <p/>
-     * For instance this is called during drag'n'drop with a CreateRequest.
-     * <p/>
-     * Reject being a target for elements which descriptor does not allow children.
-     * 
-     * {@inheritDoc}
-     */
-    @Override
-    public EditPart getTargetEditPart(Request request) {
-        if (request != null && request.getType() == RequestConstants.REQ_CREATE) {
-            // Reject being a target for elements which descriptor does not allow children.
-            if (!getUiNode().getDescriptor().hasChildren()) {
-                return null;
-            }
-        }
-        return super.getTargetEditPart(request);
-    }
-
-    /**
-     * Used by derived classes {@link UiDocumentEditPart} and {@link UiLayoutEditPart}
-     * to accept drag'n'drop of new items from the palette.
-     * 
-     * @param layoutEditPart The layout edit part where this policy is installed. It can
-     *        be either a {@link UiDocumentEditPart} or a {@link UiLayoutEditPart}.
-     */
-    protected void installLayoutEditPolicy(final UiElementEditPart layoutEditPart) {
-        // This policy indicates how elements can be constrained by the layout.
-        // TODO Right now we use the XY layout policy since our constraints are
-        // handled by the android rendering engine rather than GEF. Tweak as
-        // appropriate.
-        installEditPolicy(EditPolicy.LAYOUT_ROLE,  new LayoutEditPolicy() {
-
-            /**
-             * We don't allow layout children to be resized yet.
-             * <p/>
-             * Typical choices would be:
-             * <ul>
-             * <li> ResizableEditPolicy, to allow for selection, move and resize.
-             * <li> NonResizableEditPolicy, to allow for selection, move but not resize.
-             * <li> SelectionEditPolicy to allow for only selection.
-             * </ul>
-             * <p/>
-             * TODO: make this depend on the part layout. For an AbsoluteLayout we should
-             * probably use a NonResizableEditPolicy and SelectionEditPolicy for the rest.
-             * Whether to use ResizableEditPolicy or NonResizableEditPolicy should depend
-             * on the child in an AbsoluteLayout.
-             */
-            @Override
-            protected EditPolicy createChildEditPolicy(EditPart child) {
-                if (child instanceof UiElementEditPart) {
-                    return new NonResizableSelectionEditPolicy((UiElementEditPart) child);
-                }
-                return null;
-            }
-
-            @Override
-            protected Command getCreateCommand(CreateRequest request) {
-                // We store the ElementDescriptor in the request.factory.type
-                Object newType = request.getNewObjectType();
-                if (newType instanceof ElementDescriptor) {
-                    Point where = request.getLocation().getCopy();
-                    Point origin = getLayoutContainer().getClientArea().getLocation();
-                    where.translate(origin.getNegated());
-                    
-                    // The host is the EditPart where this policy is installed,
-                    // e.g. this UiElementEditPart.
-                    EditPart host = getHost();
-                    if (host instanceof UiElementEditPart) {
-                        
-                        return new ElementCreateCommand((ElementDescriptor) newType,
-                                (UiElementEditPart) host,
-                                where);
-                    }
-                }
-                
-                return null;
-            }
-
-            @Override
-            protected Command getMoveChildrenCommand(Request request) {
-                // TODO Auto-generated method stub
-                return null;
-            }
-            
-            @Override
-            public void showLayoutTargetFeedback(Request request) {
-                super.showLayoutTargetFeedback(request);
-                
-                // for debugging
-                // System.out.println("target: " + request.toString() + " -- " + layoutEditPart.getUiNode().getBreadcrumbTrailDescription(false));
-                
-                if (layoutEditPart instanceof UiLayoutEditPart &&
-                        request instanceof DropRequest) {
-                    Point where = ((DropRequest) request).getLocation().getCopy();
-                    Point origin = getLayoutContainer().getClientArea().getLocation();
-                    where.translate(origin.getNegated());
-
-                    ((UiLayoutEditPart) layoutEditPart).showDropTarget(where);
-                }
-            }
-
-            @Override
-            protected void eraseLayoutTargetFeedback(Request request) {
-                super.eraseLayoutTargetFeedback(request);
-                if (layoutEditPart instanceof UiLayoutEditPart) {
-                    ((UiLayoutEditPart) layoutEditPart).hideDropTarget();
-                }
-            }
-            
-            @Override
-            protected IFigure createSizeOnDropFeedback(CreateRequest createRequest) {
-                // TODO understand if this is useful for us or remove
-                return super.createSizeOnDropFeedback(createRequest);
-            }
-            
-        });
-    }
-    
-    protected static class NonResizableSelectionEditPolicy extends SelectionEditPolicy {
-        
-        private final UiElementEditPart mEditPart;
-
-        public NonResizableSelectionEditPolicy(UiElementEditPart editPart) {
-            mEditPart = editPart;
-        }
-        
-        @Override
-        protected void hideSelection() {
-            mEditPart.hideSelection();
-        }
-
-        @Override
-        protected void showSelection() {
-            mEditPart.showSelection();
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPart.java
deleted file mode 100644
index fd788dd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPart.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.gef.editparts.AbstractTreeEditPart;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * Base {@link AbstractTreeEditPart} to represent {@link UiElementNode} objects in the
- * {@link IContentOutlinePage} linked to the layout editor.
- */
-public class UiElementTreeEditPart extends AbstractTreeEditPart {
-
-    public UiElementTreeEditPart(UiElementNode uiElementNode) {
-        setModel(uiElementNode);
-    }
-
-    @Override
-    protected void createEditPolicies() {
-        // TODO Auto-generated method stub
-        super.createEditPolicies();
-    }
-
-    @Override
-    protected Image getImage() {
-        return getUiNode().getDescriptor().getIcon();
-    }
-
-    @Override
-    protected String getText() {
-        return getUiNode().getShortDescription();
-    }
-
-    @Override
-    public void activate() {
-        if (!isActive()) {
-            super.activate();
-            // TODO
-        }
-    }
-
-    @Override
-    public void deactivate() {
-        if (isActive()) {
-            super.deactivate();
-            // TODO
-        }
-    }
-
-    /**
-     * Returns the casted model object represented by this {@link AbstractTreeEditPart}.
-     */
-    protected UiElementNode getUiNode() {
-        return (UiElementNode)getModel();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPartFactory.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPartFactory.java
deleted file mode 100644
index de6c404..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementTreeEditPartFactory.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartFactory;
-import org.eclipse.gef.editparts.AbstractTreeEditPart;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * {@link EditPartFactory} to create {@link AbstractTreeEditPart} for {@link UiElementNode} objects.
- * These objects are used in the {@link IContentOutlinePage} linked to the layout editor. 
- */
-public class UiElementTreeEditPartFactory implements EditPartFactory {
-
-    public EditPart createEditPart(EditPart context, Object model) {
-        if (model instanceof UiDocumentNode) {
-            return new UiDocumentTreeEditPart((UiDocumentNode) model);
-        } else if (model instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) model;
-            if (node.getDescriptor().hasChildren()) {
-                return new UiLayoutTreeEditPart(node);
-            } else {
-                return new UiViewTreeEditPart(node);
-            }
-        }
-        return null;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementsEditPartFactory.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementsEditPartFactory.java
deleted file mode 100644
index 18dcd9c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiElementsEditPartFactory.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartFactory;
-import org.eclipse.swt.widgets.Display;
-
-/**
- * A factory that returns the appropriate {@link EditPart} for a given model object.
- * <p/>
- * The only model objects we use are {@link UiElementNode} objects and they are
- * edited using {@link UiElementEditPart}.
- */
-public class UiElementsEditPartFactory implements EditPartFactory {
-    
-    private Display mDisplay;
-
-    public UiElementsEditPartFactory(Display display) {
-        mDisplay = display;
-    }
-    
-    public EditPart createEditPart(EditPart context, Object model) {
-        if (model instanceof UiDocumentNode) {
-            return new UiDocumentEditPart((UiDocumentNode) model, mDisplay);
-        } else if (model instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) model;
-
-            if (node.getDescriptor().hasChildren()) {
-                return new UiLayoutEditPart(node);
-            }
-
-            return new UiViewEditPart(node);
-        }
-        return null;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutEditPart.java
deleted file mode 100644
index 43a70a5..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutEditPart.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.XYLayout;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.ContainerEditPolicy;
-import org.eclipse.gef.requests.CreateRequest;
-
-/**
- * Graphical edit part for an {@link UiElementNode} that represents a ViewLayout.
- * <p/>
- * It acts as a simple container. 
- */
-public final class UiLayoutEditPart extends UiElementEditPart {
-    
-    static class HighlightInfo {
-        public boolean drawDropBorder;
-        public UiElementEditPart[] childParts;
-        public Point anchorPoint;
-        public Point linePoints[];
-
-        public final Point tempPoints[] = new Point[] { new Point(), new Point() };
-
-        public void clear() {
-            drawDropBorder = false;
-            childParts = null;
-            anchorPoint = null;
-            linePoints = null;
-        }
-    }
-    
-    private final HighlightInfo mHighlightInfo = new HighlightInfo();
-    
-    public UiLayoutEditPart(UiElementNode uiElementNode) {
-        super(uiElementNode);
-    }
-    
-    @Override
-    protected void createEditPolicies() {
-        super.createEditPolicies();
-        
-        installEditPolicy(EditPolicy.CONTAINER_ROLE, new ContainerEditPolicy() {
-            @Override
-            protected Command getCreateCommand(CreateRequest request) {
-                return null;
-            }
-        });
-        
-        installLayoutEditPolicy(this);
-    }
-
-    @Override
-    protected IFigure createFigure() {
-        IFigure f = new LayoutFigure();
-        f.setLayoutManager(new XYLayout());
-        return f;
-    }
-
-    @Override
-    protected void showSelection() {
-        IFigure f = getFigure();
-        if (f instanceof ElementFigure) {
-            ((ElementFigure) f).setSelected(true);
-        }
-    }
-
-    @Override
-    protected void hideSelection() {
-        IFigure f = getFigure();
-        if (f instanceof ElementFigure) {
-            ((ElementFigure) f).setSelected(false);
-        }
-    }
-
-    public void showDropTarget(Point where) {
-        if (where != null) {
-            mHighlightInfo.clear();
-            mHighlightInfo.drawDropBorder = true;
-            DropFeedback.computeDropFeedback(this, mHighlightInfo, where);
-
-            IFigure f = getFigure();
-            if (f instanceof LayoutFigure) {
-                ((LayoutFigure) f).setHighlighInfo(mHighlightInfo);
-            }
-        }
-    }
-
-    public void hideDropTarget() {
-        mHighlightInfo.clear();
-        IFigure f = getFigure();
-        if (f instanceof LayoutFigure) {
-            ((LayoutFigure) f).setHighlighInfo(mHighlightInfo);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutTreeEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutTreeEditPart.java
deleted file mode 100644
index 4359e23..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiLayoutTreeEditPart.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import java.util.List;
-
-/**
- * Implementation of {@link UiElementTreeEditPart} for layout objects.
- */
-public class UiLayoutTreeEditPart extends UiElementTreeEditPart {
-
-    public UiLayoutTreeEditPart(UiElementNode node) {
-        super(node);
-    }
-    
-    @SuppressWarnings("unchecked")
-    @Override
-    protected List getModelChildren() {
-        return getUiNode().getUiChildren();
-    }
-
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewEditPart.java
deleted file mode 100644
index 05329f3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewEditPart.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.XYLayout;
-
-/**
- * Graphical edit part for an {@link UiElementNode} that represents a View.
- */
-public class UiViewEditPart extends UiElementEditPart {
-
-    public UiViewEditPart(UiElementNode uiElementNode) {
-        super(uiElementNode);
-    }
-
-    @Override
-    protected IFigure createFigure() {
-        IFigure f = new ElementFigure();
-        f.setLayoutManager(new XYLayout());
-        return f;
-    }
-
-    @Override
-    protected void showSelection() {
-        IFigure f = getFigure();
-        if (f instanceof ElementFigure) {
-            ((ElementFigure) f).setSelected(true);
-        }
-    }
-
-    @Override
-    protected void hideSelection() {
-        IFigure f = getFigure();
-        if (f instanceof ElementFigure) {
-            ((ElementFigure) f).setSelected(false);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewTreeEditPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewTreeEditPart.java
deleted file mode 100644
index 62b5e8a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/parts/UiViewTreeEditPart.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.parts;
-
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * Implementation of {@link UiElementTreeEditPart} for view objects.
- */
-public class UiViewTreeEditPart extends UiElementTreeEditPart {
-
-    public UiViewTreeEditPart(UiElementNode node) {
-        super(node);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/uimodel/UiViewElementNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/uimodel/UiViewElementNode.java
deleted file mode 100644
index 1bf5d5a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/layout/uimodel/UiViewElementNode.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout.uimodel;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.layout.descriptors.ViewElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IProject;
-
-import java.util.List;
-
-/**
- * Specialized version of {@link UiElementNode} for the {@link ViewElementDescriptor}s.
- */
-public class UiViewElementNode extends UiElementNode {
-
-    private AttributeDescriptor[] mCachedAttributeDescriptors;
-
-    public UiViewElementNode(ViewElementDescriptor elementDescriptor) {
-        super(elementDescriptor);
-    }
-
-    /**
-     * Returns an AttributeDescriptor array that depends on the current UiParent.
-     * <p/>
-     * The array merges both "direct" attributes with the descriptor layout attributes.
-     * The array instance is cached and cleared if the UiParent is changed.
-     */
-    @Override
-    public AttributeDescriptor[] getAttributeDescriptors() {
-        if (mCachedAttributeDescriptors != null) {
-            return mCachedAttributeDescriptors;
-        }
-
-        UiElementNode ui_parent = getUiParent();
-        AttributeDescriptor[] direct_attrs = super.getAttributeDescriptors();
-        mCachedAttributeDescriptors = direct_attrs;
-
-        AttributeDescriptor[] layout_attrs = null;
-        boolean need_xmlns = false;
-
-        if (ui_parent instanceof UiDocumentNode) {
-            // Limitation: right now the layout behaves as if everything was
-            // owned by a FrameLayout.
-            // TODO replace by something user-configurable.
-
-            List<ElementDescriptor> layoutDescriptors = null;
-            IProject project = getEditor().getProject();
-            if (project != null) {
-                Sdk currentSdk = Sdk.getCurrent();
-                IAndroidTarget target = currentSdk.getTarget(project);
-                if (target != null) {
-                    AndroidTargetData data = currentSdk.getTargetData(target);
-                    layoutDescriptors = data.getLayoutDescriptors().getLayoutDescriptors();
-                }
-            }
-            
-            if (layoutDescriptors != null) {
-                for (ElementDescriptor desc : layoutDescriptors) {
-                    if (desc instanceof ViewElementDescriptor &&
-                            desc.getXmlName().equals(AndroidConstants.CLASS_FRAMELAYOUT)) {
-                        layout_attrs = ((ViewElementDescriptor) desc).getLayoutAttributes();
-                        need_xmlns = true;
-                        break;
-                    }
-                }
-            }
-        } else if (ui_parent instanceof UiViewElementNode){
-            layout_attrs =
-                ((ViewElementDescriptor) ui_parent.getDescriptor()).getLayoutAttributes();
-        }
-
-        if (layout_attrs == null || layout_attrs.length == 0) {
-            return mCachedAttributeDescriptors;
-        }
-
-        mCachedAttributeDescriptors =
-            new AttributeDescriptor[direct_attrs.length +
-                                    layout_attrs.length +
-                                    (need_xmlns ? 1 : 0)];
-        System.arraycopy(direct_attrs, 0,
-                mCachedAttributeDescriptors, 0,
-                direct_attrs.length);
-        System.arraycopy(layout_attrs, 0,
-                mCachedAttributeDescriptors, direct_attrs.length,
-                layout_attrs.length);
-        if (need_xmlns) {
-            AttributeDescriptor desc = new XmlnsAttributeDescriptor(
-                    "android",  //$NON-NLS-1$
-                    SdkConstants.NS_RESOURCES);
-            mCachedAttributeDescriptors[direct_attrs.length + layout_attrs.length] = desc;
-        }
-
-        return mCachedAttributeDescriptors;
-    }
-    
-    /**
-     * Sets the parent of this UI node.
-     * <p/>
-     * Also removes the cached AttributeDescriptor array that depends on the current UiParent.
-     */
-    @Override
-    protected void setUiParent(UiElementNode parent) {
-        super.setUiParent(parent);
-        mCachedAttributeDescriptors = null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestContentAssist.java
deleted file mode 100644
index b40e458..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestContentAssist.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidContentAssist;
-
-/**
- * Content Assist Processor for AndroidManifest.xml
- */
-final class ManifestContentAssist extends AndroidContentAssist {
-
-    /**
-     * Constructor for ManifestContentAssist 
-     */
-    public ManifestContentAssist() {
-        super(AndroidTargetData.DESCRIPTOR_MANIFEST);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditor.java
deleted file mode 100644
index d0f8d7b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditor.java
+++ /dev/null
@@ -1,387 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidXPathFactory;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.manifest.pages.ApplicationPage;
-import com.android.ide.eclipse.editors.manifest.pages.InstrumentationPage;
-import com.android.ide.eclipse.editors.manifest.pages.OverviewPage;
-import com.android.ide.eclipse.editors.manifest.pages.PermissionPage;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-import java.util.List;
-
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathConstants;
-import javax.xml.xpath.XPathExpressionException;
-
-/**
- * Multi-page form editor for AndroidManifest.xml. 
- */
-public final class ManifestEditor extends AndroidEditor {
-    private final static String EMPTY = ""; //$NON-NLS-1$
-
-    
-    /** Root node of the UI element hierarchy */
-    private UiElementNode mUiManifestNode;
-    /** The Application Page tab */
-    private ApplicationPage mAppPage;
-    /** The Overview Manifest Page tab */
-    private OverviewPage mOverviewPage;
-    /** The Permission Page tab */
-    private PermissionPage mPermissionPage;
-    /** The Instrumentation Page tab */
-    private InstrumentationPage mInstrumentationPage;
-    
-    private IFileListener mMarkerMonitor;
-    
-
-    /**
-     * Creates the form editor for AndroidManifest.xml.
-     */
-    public ManifestEditor() {
-        super();
-    }
-    
-    @Override
-    public void dispose() {
-        super.dispose();
-
-        ResourceMonitor.getMonitor().removeFileListener(mMarkerMonitor);
-    }
-
-    /**
-     * Return the root node of the UI element hierarchy, which here
-     * is the "manifest" node.
-     */
-    @Override
-    public UiElementNode getUiRootNode() {
-        return mUiManifestNode;
-    }
-    
-    /**
-     * Returns the Manifest descriptors for the file being edited.
-     */
-    public AndroidManifestDescriptors getManifestDescriptors() {
-        AndroidTargetData data = getTargetData();
-        if (data != null) {
-            return data.getManifestDescriptors();
-        }
-        
-        return null;
-    }
-    
-    // ---- Base Class Overrides ----
-
-    /**
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p/>
-     * Save-As is a valid operation for the ManifestEditor since it acts on a
-     * single source file. 
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return true;
-    }
-
-    /**
-     * Creates the various form pages.
-     */
-    @Override
-    protected void createFormPages() {
-        try {
-            addPage(mOverviewPage = new OverviewPage(this));
-            addPage(mAppPage = new ApplicationPage(this));
-            addPage(mPermissionPage = new PermissionPage(this));
-            addPage(mInstrumentationPage = new InstrumentationPage(this));
-        } catch (PartInitException e) {
-            AdtPlugin.log(e, "Error creating nested page"); //$NON-NLS-1$
-        }
-    }
-
-    /* (non-java doc)
-     * Change the tab/title name to include the project name.
-     */
-    @Override
-    protected void setInput(IEditorInput input) {
-        super.setInput(input);
-        IFile inputFile = getInputFile();
-        if (inputFile != null) {
-            startMonitoringMarkers();
-            setPartName(String.format("%1$s Manifest", inputFile.getProject().getName()));
-        }
-    }
-
-    /**
-     * Processes the new XML Model, which XML root node is given.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    @Override
-    protected void xmlModelChanged(Document xml_doc) {
-        // create the ui root node on demand.
-        initUiRootNode(false /*force*/);
-        
-        loadFromXml(xml_doc);
-        
-        super.xmlModelChanged(xml_doc);
-    }
-    
-    private void loadFromXml(Document xmlDoc) {
-        mUiManifestNode.setXmlDocument(xmlDoc);
-        if (xmlDoc != null) {
-            ElementDescriptor manifest_desc = mUiManifestNode.getDescriptor();
-            try {
-                XPath xpath = AndroidXPathFactory.newXPath();
-                Node node = (Node) xpath.evaluate("/" + manifest_desc.getXmlName(),  //$NON-NLS-1$
-                        xmlDoc,
-                        XPathConstants.NODE);
-                assert node != null && node.getNodeName().equals(manifest_desc.getXmlName());
-
-                // Refresh the manifest UI node and all its descendants 
-                mUiManifestNode.loadFromXmlNode(node);
-            } catch (XPathExpressionException e) {
-                AdtPlugin.log(e, "XPath error when trying to find '%s' element in XML.", //$NON-NLS-1$
-                        manifest_desc.getXmlName());
-            }
-        }
-    }
-    
-    private void onDescriptorsChanged(UiElementNode oldManifestNode) {
-        mUiManifestNode.reloadFromXmlNode(oldManifestNode.getXmlNode());
-
-        if (mOverviewPage != null) {
-            mOverviewPage.refreshUiApplicationNode();
-        }
-
-        if (mAppPage != null) {
-            mAppPage.refreshUiApplicationNode();
-        }
-        
-        if (mPermissionPage != null) {
-            mPermissionPage.refreshUiNode();
-        }
-        
-        if (mInstrumentationPage != null) {
-            mInstrumentationPage.refreshUiNode();
-        }
-    }
-
-    /**
-     * Reads and processes the current markers and adds a listener for marker changes. 
-     */
-    private void startMonitoringMarkers() {
-        final IFile inputFile = getInputFile();
-        if (inputFile != null) {
-            updateFromExistingMarkers(inputFile);
-            
-            mMarkerMonitor = new IFileListener() {
-                public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind) {
-                    if (file.equals(inputFile)) {
-                        processMarkerChanges(markerDeltas);
-                    }
-                }
-            };
-            
-            ResourceMonitor.getMonitor().addFileListener(mMarkerMonitor, IResourceDelta.CHANGED);
-        }
-    }
-
-    /**
-     * Processes the markers of the specified {@link IFile} and updates the error status of 
-     * {@link UiElementNode}s and {@link UiAttributeNode}s.
-     * @param inputFile the file being edited.
-     */
-    private void updateFromExistingMarkers(IFile inputFile) {
-        try {
-            // get the markers for the file
-            IMarker[] markers = inputFile.findMarkers(AndroidConstants.MARKER_ANDROID, true,
-                    IResource.DEPTH_ZERO);
-            
-            AndroidManifestDescriptors desc = getManifestDescriptors();
-            if (desc != null) {
-                ElementDescriptor appElement = desc.getApplicationElement();
-                
-                if (appElement != null) {
-                    UiElementNode app_ui_node = mUiManifestNode.findUiChildNode(
-                            appElement.getXmlName());
-                    List<UiElementNode> children = app_ui_node.getUiChildren();
-
-                    for (IMarker marker : markers) {
-                        processMarker(marker, children, IResourceDelta.ADDED);
-                    }
-                }
-            }
-            
-        } catch (CoreException e) {
-            // findMarkers can throw an exception, in which case, we'll do nothing.
-        }
-    }
-    
-    /**
-     * Processes a {@link IMarker} change.
-     * @param markerDeltas the list of {@link IMarkerDelta}
-     */
-    private void processMarkerChanges(IMarkerDelta[] markerDeltas) {
-        AndroidManifestDescriptors descriptors = getManifestDescriptors();
-        if (descriptors != null && descriptors.getApplicationElement() != null) {
-            UiElementNode app_ui_node = mUiManifestNode.findUiChildNode(
-                    descriptors.getApplicationElement().getXmlName());
-            List<UiElementNode> children = app_ui_node.getUiChildren();
-    
-            for (IMarkerDelta markerDelta : markerDeltas) {
-                processMarker(markerDelta.getMarker(), children, markerDelta.getKind());
-            }
-        }
-    }
-
-    /**
-     * Processes a new/old/updated marker.
-     * @param marker The marker being added/removed/changed
-     * @param nodeList the list of activity/service/provider/receiver nodes.
-     * @param kind the change kind. Can be {@link IResourceDelta#ADDED},
-     * {@link IResourceDelta#REMOVED}, or {@link IResourceDelta#CHANGED}
-     */
-    private void processMarker(IMarker marker, List<UiElementNode> nodeList, int kind) {
-        // get the data from the marker
-        String nodeType = marker.getAttribute(AndroidConstants.MARKER_ATTR_TYPE, EMPTY);
-        if (nodeType == EMPTY) {
-            return;
-        }
-        
-        String className = marker.getAttribute(AndroidConstants.MARKER_ATTR_CLASS, EMPTY);
-        if (className == EMPTY) {
-            return;
-        }
-
-        for (UiElementNode ui_node : nodeList) {
-            if (ui_node.getDescriptor().getXmlName().equals(nodeType)) {
-                for (UiAttributeNode attr : ui_node.getUiAttributes()) {
-                    if (attr.getDescriptor().getXmlLocalName().equals(
-                            AndroidManifestDescriptors.ANDROID_NAME_ATTR)) {
-                        if (attr.getCurrentValue().equals(className)) {
-                            if (kind == IResourceDelta.REMOVED) {
-                                attr.setHasError(false);
-                            } else {
-                                attr.setHasError(true);
-                            }
-                            return;
-                        }
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Creates the initial UI Root Node, including the known mandatory elements.
-     * @param force if true, a new UiManifestNode is recreated even if it already exists.
-     */
-    @Override
-    protected void initUiRootNode(boolean force) {
-        // The manifest UI node is always created, even if there's no corresponding XML node.
-        if (mUiManifestNode != null && force == false) {
-            return;
-        }
-
-        
-        AndroidManifestDescriptors manifestDescriptor = getManifestDescriptors();
-        
-        if (manifestDescriptor != null) {
-            // save the old manifest node if it exists
-            UiElementNode oldManifestNode = mUiManifestNode;
-
-            ElementDescriptor manifestElement = manifestDescriptor.getManifestElement();   
-            mUiManifestNode = manifestElement.createUiNode();
-            mUiManifestNode.setEditor(this);
-    
-            // Similarly, always create the /manifest/application and /manifest/uses-sdk nodes
-            ElementDescriptor appElement = manifestDescriptor.getApplicationElement();
-            boolean present = false;
-            for (UiElementNode ui_node : mUiManifestNode.getUiChildren()) {
-                if (ui_node.getDescriptor() == appElement) {
-                    present = true;
-                    break;
-                }
-            }
-            if (!present) {
-                mUiManifestNode.appendNewUiChild(appElement);
-            }
-
-            appElement = manifestDescriptor.getUsesSdkElement();
-            present = false;
-            for (UiElementNode ui_node : mUiManifestNode.getUiChildren()) {
-                if (ui_node.getDescriptor() == appElement) {
-                    present = true;
-                    break;
-                }
-            }
-            if (!present) {
-                mUiManifestNode.appendNewUiChild(appElement);
-            }
-
-            if (oldManifestNode != null) {
-                onDescriptorsChanged(oldManifestNode);
-            }
-        } else {
-            // create a dummy descriptor/uinode until we have real descriptors
-            ElementDescriptor desc = new ElementDescriptor("manifest", //$NON-NLS-1$
-                    "temporary descriptors due to missing decriptors", //$NON-NLS-1$
-                    null /*tooltip*/, null /*sdk_url*/, null /*attributes*/,
-                    null /*children*/, false /*mandatory*/);
-            mUiManifestNode = desc.createUiNode();
-            mUiManifestNode.setEditor(this);
-        }
-    }
-    
-    /**
-     * Returns the {@link IFile} being edited, or <code>null</code> if it couldn't be computed.
-     */
-    private IFile getInputFile() {
-        IEditorInput input = getEditorInput();
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput) input;
-            return fileInput.getFile();
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditorContributor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditorContributor.java
deleted file mode 100644
index 911faa1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestEditorContributor.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.actions.ActionFactory;
-import org.eclipse.ui.ide.IDEActionFactory;
-import org.eclipse.ui.part.MultiPageEditorActionBarContributor;
-import org.eclipse.ui.texteditor.ITextEditor;
-import org.eclipse.ui.texteditor.ITextEditorActionConstants;
-
-/**
- * Manages the installation/deinstallation of global actions for multi-page
- * editors. Responsible for the redirection of global actions to the active
- * editor. Multi-page contributor replaces the contributors for the individual
- * editors in the multi-page editor.
- * 
- * TODO: Doesn't look like we need this. Remove it if not needed.
- * @deprecated
- */
-final class ManifestEditorContributor extends MultiPageEditorActionBarContributor {
-    private IEditorPart mActiveEditorPart;
-
-    /**
-     * Creates a multi-page contributor.
-     * 
-     * Marked as Private so it can't be instanciated. This is a cheap way to make sure
-     * it's not being used. As noted in constructor, should be removed if not used.
-     * @deprecated
-     */
-    private ManifestEditorContributor() {
-        super();
-    }
-
-    /**
-     * Returns the action registed with the given text editor.
-     *
-     * @return IAction or null if editor is null.
-     */
-    protected IAction getAction(ITextEditor editor, String actionID) {
-        return (editor == null ? null : editor.getAction(actionID));
-    }
-
-    /*
-     * (non-JavaDoc) Method declared in
-     * AbstractMultiPageEditorActionBarContributor.
-     */
-
-    @Override
-    public void setActivePage(IEditorPart part) {
-        if (mActiveEditorPart == part)
-            return;
-
-        mActiveEditorPart = part;
-
-        IActionBars actionBars = getActionBars();
-        if (actionBars != null) {
-
-            ITextEditor editor =
-                (part instanceof ITextEditor) ? (ITextEditor)part : null;
-
-            actionBars.setGlobalActionHandler(ActionFactory.DELETE.getId(),
-                    getAction(editor, ITextEditorActionConstants.DELETE));
-            actionBars.setGlobalActionHandler(ActionFactory.UNDO.getId(),
-                    getAction(editor, ITextEditorActionConstants.UNDO));
-            actionBars.setGlobalActionHandler(ActionFactory.REDO.getId(),
-                    getAction(editor, ITextEditorActionConstants.REDO));
-            actionBars.setGlobalActionHandler(ActionFactory.CUT.getId(),
-                    getAction(editor, ITextEditorActionConstants.CUT));
-            actionBars.setGlobalActionHandler(ActionFactory.COPY.getId(),
-                    getAction(editor, ITextEditorActionConstants.COPY));
-            actionBars.setGlobalActionHandler(ActionFactory.PASTE.getId(),
-                    getAction(editor, ITextEditorActionConstants.PASTE));
-            actionBars.setGlobalActionHandler(ActionFactory.SELECT_ALL.getId(),
-                    getAction(editor, ITextEditorActionConstants.SELECT_ALL));
-            actionBars.setGlobalActionHandler(ActionFactory.FIND.getId(),
-                    getAction(editor, ITextEditorActionConstants.FIND));
-            actionBars.setGlobalActionHandler(
-                    IDEActionFactory.BOOKMARK.getId(), getAction(editor,
-                            IDEActionFactory.BOOKMARK.getId()));
-            actionBars.updateActionBars();
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestSourceViewerConfig.java
deleted file mode 100644
index e33e1efc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/ManifestSourceViewerConfig.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest;
-
-
-import com.android.ide.eclipse.editors.AndroidSourceViewerConfig;
-
-/**
- * Source Viewer Configuration that calls in ManifestContentAssist.
- */
-public final class ManifestSourceViewerConfig extends AndroidSourceViewerConfig {
-
-    public ManifestSourceViewerConfig() {
-        super(new ManifestContentAssist());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/AndroidManifestDescriptors.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/AndroidManifestDescriptors.java
deleted file mode 100644
index 61b73a2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/AndroidManifestDescriptors.java
+++ /dev/null
@@ -1,560 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.ListAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ReferenceAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.runtime.IStatus;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-import java.util.TreeSet;
-import java.util.Map.Entry;
-
-
-/**
- * Complete description of the AndroidManifest.xml structure.
- * <p/>
- * The root element are static instances which always exists.
- * However their sub-elements and attributes are created only when the SDK changes or is
- * loaded the first time.
- */
-public final class AndroidManifestDescriptors implements IDescriptorProvider {
-
-    private static final String MANIFEST_NODE_NAME = "manifest";                //$NON-NLS-1$
-    private static final String ANDROID_MANIFEST_STYLEABLE = "AndroidManifest"; //$NON-NLS-1$
-
-    // Public attributes names, attributes descriptors and elements descriptors
-    
-    public static final String ANDROID_LABEL_ATTR = "label";    //$NON-NLS-1$
-    public static final String ANDROID_NAME_ATTR  = "name";     //$NON-NLS-1$
-    public static final String PACKAGE_ATTR       = "package";  //$NON-NLS-1$
-
-    /** The {@link ElementDescriptor} for the root Manifest element. */
-    private final ElementDescriptor MANIFEST_ELEMENT;
-    /** The {@link ElementDescriptor} for the root Application element. */
-    private final ElementDescriptor APPLICATION_ELEMENT;
-
-    /** The {@link ElementDescriptor} for the root Instrumentation element. */
-    private final ElementDescriptor INTRUMENTATION_ELEMENT;
-    /** The {@link ElementDescriptor} for the root Permission element. */
-    private final ElementDescriptor PERMISSION_ELEMENT;
-    /** The {@link ElementDescriptor} for the root UsesPermission element. */
-    private final ElementDescriptor USES_PERMISSION_ELEMENT;
-    /** The {@link ElementDescriptor} for the root UsesSdk element. */
-    private final ElementDescriptor USES_SDK_ELEMENT;
-
-    /** The {@link ElementDescriptor} for the root PermissionGroup element. */
-    private final ElementDescriptor PERMISSION_GROUP_ELEMENT;
-    /** The {@link ElementDescriptor} for the root PermissionTree element. */
-    private final ElementDescriptor PERMISSION_TREE_ELEMENT;
-
-    /** Private package attribute for the manifest element. Needs to be handled manually. */
-    private final TextAttributeDescriptor PACKAGE_ATTR_DESC;
-    
-    public AndroidManifestDescriptors() {
-        APPLICATION_ELEMENT = createElement("application", null, true); //$NON-NLS-1$ + no child & mandatory
-        INTRUMENTATION_ELEMENT = createElement("instrumentation"); //$NON-NLS-1$
-
-        PERMISSION_ELEMENT = createElement("permission"); //$NON-NLS-1$
-        USES_PERMISSION_ELEMENT = createElement("uses-permission"); //$NON-NLS-1$
-        USES_SDK_ELEMENT = createElement("uses-sdk", null, true); //$NON-NLS-1$ + no child & mandatory
-
-        PERMISSION_GROUP_ELEMENT = createElement("permission-group"); //$NON-NLS-1$
-        PERMISSION_TREE_ELEMENT = createElement("permission-tree"); //$NON-NLS-1$
-
-        MANIFEST_ELEMENT = createElement(
-                        MANIFEST_NODE_NAME, // xml name
-                        new ElementDescriptor[] {
-                                        APPLICATION_ELEMENT,
-                                        INTRUMENTATION_ELEMENT,
-                                        PERMISSION_ELEMENT,
-                                        USES_PERMISSION_ELEMENT,
-                                        PERMISSION_GROUP_ELEMENT,
-                                        PERMISSION_TREE_ELEMENT,
-                                        USES_SDK_ELEMENT,
-                        },
-                        true /* mandatory */);
-
-        // The "package" attribute is treated differently as it doesn't have the standard
-        // Android XML namespace.
-        PACKAGE_ATTR_DESC = new PackageAttributeDescriptor(PACKAGE_ATTR,
-                "Package",
-                null /* nsUri */,
-                "This attribute gives a unique name for the package, using a Java-style naming convention to avoid name collisions.\nFor example, applications published by Google could have names of the form com.google.app.appname");
-    }
-    
-    public ElementDescriptor[] getRootElementDescriptors() {
-        return new ElementDescriptor[] { MANIFEST_ELEMENT };
-    }
-    
-    public ElementDescriptor getDescriptor() {
-        return getManifestElement();
-    }
-    
-    public ElementDescriptor getApplicationElement() {
-        return APPLICATION_ELEMENT;
-    }
-    
-    public ElementDescriptor getManifestElement() {
-        return MANIFEST_ELEMENT;
-    }
-    
-    public ElementDescriptor getUsesSdkElement() {
-        return USES_SDK_ELEMENT;
-    }
-    
-    public ElementDescriptor getInstrumentationElement() {
-        return INTRUMENTATION_ELEMENT;
-    }
-    
-    public ElementDescriptor getPermissionElement() {
-        return PERMISSION_ELEMENT;
-    }
-    
-    public ElementDescriptor getUsesPermissionElement() {
-        return USES_PERMISSION_ELEMENT;
-    }
-    
-    public ElementDescriptor getPermissionGroupElement() {
-        return PERMISSION_GROUP_ELEMENT;
-    }
-    
-    public ElementDescriptor getPermissionTreeElement() {
-        return PERMISSION_TREE_ELEMENT;
-    }
-
-    /**
-     * Updates the document descriptor.
-     * <p/>
-     * It first computes the new children of the descriptor and then updates them
-     * all at once.
-     * 
-     * @param manifestMap The map style => attributes from the attrs_manifest.xml file
-     */
-    public synchronized void updateDescriptors(
-            Map<String, DeclareStyleableInfo> manifestMap) {
-
-        XmlnsAttributeDescriptor xmlns = new XmlnsAttributeDescriptor(
-                "android", //$NON-NLS-1$
-                SdkConstants.NS_RESOURCES); 
-
-        // -- setup the required attributes overrides --
-        
-        Set<String> required = new HashSet<String>();
-        required.add("provider/authorities");  //$NON-NLS-1$
-        
-        // -- setup the various attribute format overrides --
-        
-        // The key for each override is "element1,element2,.../attr-xml-local-name" or
-        // "*/attr-xml-local-name" to match the attribute in any element.
-        
-        Map<String, Object> overrides = new HashMap<String, Object>();
-
-        overrides.put("*/icon", new DescriptorsUtils.ITextAttributeCreator() { //$NON-NLS-1$
-            public TextAttributeDescriptor create(String xmlName, String uiName, String nsUri,
-                    String tooltip) {
-                return new ReferenceAttributeDescriptor(
-                        ResourceType.DRAWABLE,
-                        xmlName, uiName, nsUri,
-                        tooltip);
-            }
-        });
-        
-        overrides.put("*/theme",         ThemeAttributeDescriptor.class);   //$NON-NLS-1$
-        overrides.put("*/permission",    ListAttributeDescriptor.class);    //$NON-NLS-1$
-        overrides.put("*/targetPackage", PackageAttributeDescriptor.class); //$NON-NLS-1$
-        
-        overrides.put("action,category,uses-permission/" + ANDROID_NAME_ATTR,    //$NON-NLS-1$
-                      ListAttributeDescriptor.class);
-        overrides.put("application/" + ANDROID_NAME_ATTR, ApplicationAttributeDescriptor.class);  //$NON-NLS-1$
-
-        overrideClassName(overrides, "activity", AndroidConstants.CLASS_ACTIVITY);           //$NON-NLS-1$
-        overrideClassName(overrides, "receiver", AndroidConstants.CLASS_BROADCASTRECEIVER);  //$NON-NLS-1$
-        overrideClassName(overrides, "service", AndroidConstants.CLASS_SERVICE);             //$NON-NLS-1$
-        overrideClassName(overrides, "provider", AndroidConstants.CLASS_CONTENTPROVIDER);    //$NON-NLS-1$
-
-        // -- list element nodes already created --
-        // These elements are referenced by already opened editors, so we want to update them
-        // but not re-create them when reloading an SDK on the fly.
-        
-        HashMap<String, ElementDescriptor> elementDescs =
-            new HashMap<String, ElementDescriptor>();
-        elementDescs.put(MANIFEST_ELEMENT.getXmlLocalName(),         MANIFEST_ELEMENT);
-        elementDescs.put(APPLICATION_ELEMENT.getXmlLocalName(),      APPLICATION_ELEMENT);
-        elementDescs.put(INTRUMENTATION_ELEMENT.getXmlLocalName(),   INTRUMENTATION_ELEMENT);
-        elementDescs.put(PERMISSION_ELEMENT.getXmlLocalName(),       PERMISSION_ELEMENT);
-        elementDescs.put(USES_PERMISSION_ELEMENT.getXmlLocalName(),  USES_PERMISSION_ELEMENT);
-        elementDescs.put(USES_SDK_ELEMENT.getXmlLocalName(),         USES_SDK_ELEMENT);
-        elementDescs.put(PERMISSION_GROUP_ELEMENT.getXmlLocalName(), PERMISSION_GROUP_ELEMENT);
-        elementDescs.put(PERMISSION_TREE_ELEMENT.getXmlLocalName(),  PERMISSION_TREE_ELEMENT);
-
-        // --
-
-        inflateElement(manifestMap,
-                overrides,
-                required,
-                elementDescs,
-                MANIFEST_ELEMENT,
-                "AndroidManifest"); //$NON-NLS-1$
-        insertAttribute(MANIFEST_ELEMENT, PACKAGE_ATTR_DESC);
-        
-        sanityCheck(manifestMap, MANIFEST_ELEMENT);
-    }
-    
-    /**
-     * Sets up an attribute override for ANDROID_NAME_ATTR using a ClassAttributeDescriptor
-     * with the specified class name.
-     */
-    private static void overrideClassName(Map<String, Object> overrides,
-            String elementName, final String className) {
-        overrides.put(elementName + "/" + ANDROID_NAME_ATTR,
-                new DescriptorsUtils.ITextAttributeCreator() {
-            public TextAttributeDescriptor create(String xmlName, String uiName, String nsUri,
-                    String tooltip) {
-                if (AndroidConstants.CLASS_ACTIVITY.equals(className)) {
-                    return new ClassAttributeDescriptor(
-                            className,
-                            PostActivityCreationAction.getAction(),
-                            xmlName, uiName + "*", //$NON-NLS-1$
-                            nsUri,
-                            tooltip,
-                            true /*mandatory */);
-                } else if (AndroidConstants.CLASS_BROADCASTRECEIVER.equals(className)) {
-                    return new ClassAttributeDescriptor(
-                            className,
-                            PostReceiverCreationAction.getAction(),
-                            xmlName, uiName + "*", //$NON-NLS-1$
-                            nsUri,
-                            tooltip,
-                            true /*mandatory */);
-                    
-                } else {
-                    return new ClassAttributeDescriptor(
-                            className,
-                            xmlName, uiName + "*", //$NON-NLS-1$
-                            nsUri,
-                            tooltip,
-                            true /*mandatory */);
-                }
-            }
-        });
-    }
-
-    /**
-     * Returns a new ElementDescriptor constructed from the information given here
-     * and the javadoc & attributes extracted from the style map if any.
-     * <p/>
-     * Creates an element with no attribute overrides.
-     */
-    private ElementDescriptor createElement(
-            String xmlName,
-            ElementDescriptor[] childrenElements,
-            boolean mandatory) {
-        // Creates an element with no attribute overrides.
-        String styleName = guessStyleName(xmlName);
-        String sdkUrl = DescriptorsUtils.MANIFEST_SDK_URL + styleName; 
-        String uiName = getUiName(xmlName);
-
-        ElementDescriptor element = new ManifestElementDescriptor(xmlName, uiName, null, sdkUrl,
-                null, childrenElements, mandatory);
-
-        return element;
-    }
-
-    /**
-     * Returns a new ElementDescriptor constructed from its XML local name.
-     * <p/>
-     * This version creates an element not mandatory.
-     */
-    private ElementDescriptor createElement(String xmlName) {
-        // Creates an element with no child and not mandatory
-        return createElement(xmlName, null, false);
-    }
-
-    /**
-     * Inserts an attribute in this element attribute list if it is not present there yet
-     * (based on the attribute XML name.)
-     * The attribute is inserted at the beginning of the attribute list.
-     */
-    private void insertAttribute(ElementDescriptor element, AttributeDescriptor newAttr) {
-        AttributeDescriptor[] attributes = element.getAttributes();
-        for (AttributeDescriptor attr : attributes) {
-            if (attr.getXmlLocalName().equals(newAttr.getXmlLocalName())) {
-                return;
-            }
-        }
-        
-        AttributeDescriptor[] newArray = new AttributeDescriptor[attributes.length + 1];
-        newArray[0] = newAttr;
-        System.arraycopy(attributes, 0, newArray, 1, attributes.length);
-        element.setAttributes(newArray);
-    }
-
-    /**
-     * "Inflates" the properties of an {@link ElementDescriptor} from the styleable declaration.
-     * <p/>
-     * This first creates all the attributes for the given ElementDescriptor.
-     * It then finds all children of the descriptor, inflate them recursively and set them
-     * as child to this ElementDescriptor.
-     * 
-     * @param styleMap The input styleable map for manifest elements & attributes.
-     * @param overrides A list of attribute overrides (to customize the type of the attribute
-     *          descriptors).
-     * @param requiredAttributes Set of attributes to be marked as required.
-     * @param existingElementDescs A map of already created element descriptors, keyed by
-     *          XML local name. This is used to use the static elements created initially by this
-     *          class, which are referenced directly by editors (so that reloading an SDK won't
-     *          break these references).
-     * @param elemDesc The current {@link ElementDescriptor} to inflate.
-     * @param styleName The name of the {@link ElementDescriptor} to inflate. Its XML local name
-     *          will be guessed automatically from the style name. 
-     */
-    private void inflateElement(
-            Map<String, DeclareStyleableInfo> styleMap,
-            Map<String, Object> overrides,
-            Set<String> requiredAttributes,
-            HashMap<String, ElementDescriptor> existingElementDescs,
-            ElementDescriptor elemDesc,
-            String styleName) {
-        assert elemDesc != null;
-        assert styleName != null;
-        
-        // define attributes
-        DeclareStyleableInfo style = styleMap != null ? styleMap.get(styleName) : null;
-        if (style != null) {
-            ArrayList<AttributeDescriptor> attrDescs = new ArrayList<AttributeDescriptor>();
-            DescriptorsUtils.appendAttributes(attrDescs,
-                    elemDesc.getXmlLocalName(),
-                    SdkConstants.NS_RESOURCES,
-                    style.getAttributes(),
-                    requiredAttributes,
-                    overrides);
-            elemDesc.setTooltip(style.getJavaDoc());
-            elemDesc.setAttributes(attrDescs.toArray(new AttributeDescriptor[attrDescs.size()]));
-        }
-        
-        // find all elements that have this one as parent
-        ArrayList<ElementDescriptor> children = new ArrayList<ElementDescriptor>();
-        for (Entry<String, DeclareStyleableInfo> entry : styleMap.entrySet()) {
-            DeclareStyleableInfo childStyle = entry.getValue();
-            boolean isParent = false;
-            String[] parents = childStyle.getParents();
-            if (parents != null) {
-                for (String parent: parents) {
-                    if (styleName.equals(parent)) {
-                        isParent = true;
-                        break;
-                    }
-                }
-            }
-            if (isParent) {
-                String childStyleName = entry.getKey();
-                String childXmlName = guessXmlName(childStyleName);
-                
-                // create or re-use element
-                ElementDescriptor child = existingElementDescs.get(childXmlName);
-                if (child == null) {
-                    child = createElement(childXmlName);
-                    existingElementDescs.put(childXmlName, child);
-                }
-                children.add(child);
-                
-                inflateElement(styleMap,
-                        overrides,
-                        requiredAttributes,
-                        existingElementDescs,
-                        child,
-                        childStyleName);
-            }
-        }
-        elemDesc.setChildren(children.toArray(new ElementDescriptor[children.size()]));
-    }
-
-    /**
-     * Get an UI name from the element XML name.
-     * <p/>
-     * Capitalizes the first letter and replace non-alphabet by a space followed by a capital.
-     */
-    private String getUiName(String xmlName) {
-        StringBuilder sb = new StringBuilder();
-
-        boolean capitalize = true;
-        for (char c : xmlName.toCharArray()) {
-            if (capitalize && c >= 'a' && c <= 'z') {
-                sb.append((char)(c + 'A' - 'a'));
-                capitalize = false;
-            } else if ((c < 'A' || c > 'Z') && (c < 'a' || c > 'z')) {
-                sb.append(' ');
-                capitalize = true;
-            } else {
-                sb.append(c);
-            }
-        }
-        
-        return sb.toString();
-    }
-
-    /**
-     * Guesses the style name for a given XML element name.
-     * <p/> 
-     * The rules are:
-     * - capitalize the first letter: 
-     * - if there's a dash, skip it and capitalize the next one
-     * - prefix AndroidManifest
-     * The exception is "manifest" which just becomes AndroidManifest.
-     * <p/>
-     * Examples:
-     * - manifest        => AndroidManifest
-     * - application     => AndroidManifestApplication
-     * - uses-permission => AndroidManifestUsesPermission
-     */
-    private String guessStyleName(String xmlName) {
-        StringBuilder sb = new StringBuilder();
-
-        if (!xmlName.equals(MANIFEST_NODE_NAME)) {
-            boolean capitalize = true;
-            for (char c : xmlName.toCharArray()) {
-                if (capitalize && c >= 'a' && c <= 'z') {
-                    sb.append((char)(c + 'A' - 'a'));
-                    capitalize = false;
-                } else if ((c < 'A' || c > 'Z') && (c < 'a' || c > 'z')) {
-                    // not a letter -- skip the character and capitalize the next one
-                    capitalize = true;
-                } else {
-                    sb.append(c);
-                }
-            }
-        }
-        
-        sb.insert(0, ANDROID_MANIFEST_STYLEABLE);
-        return sb.toString();
-    }
-
-    /**
-     * This method performs a sanity check to make sure all the styles declared in the
-     * manifestMap are actually defined in the actual element descriptors and reachable from
-     * the manifestElement root node.
-     */
-    private void sanityCheck(Map<String, DeclareStyleableInfo> manifestMap,
-            ElementDescriptor manifestElement) {
-        TreeSet<String> elementsDeclared = new TreeSet<String>();
-        findAllElementNames(manifestElement, elementsDeclared);
-
-        TreeSet<String> stylesDeclared = new TreeSet<String>();
-        for (String styleName : manifestMap.keySet()) {
-            if (styleName.startsWith(ANDROID_MANIFEST_STYLEABLE)) {
-                stylesDeclared.add(styleName);
-            }
-        }
-        
-        for (Iterator<String> it = elementsDeclared.iterator(); it.hasNext();) {
-            String xmlName = it.next();
-            String styleName = guessStyleName(xmlName);
-            if (stylesDeclared.remove(styleName)) {
-                it.remove();
-            }
-        }
-
-        StringBuilder sb = new StringBuilder();
-        if (!stylesDeclared.isEmpty()) {
-            sb.append("Warning, ADT/SDK Mismatch! The following elements are declared by the SDK but unknown to ADT: ");
-            for (String name : stylesDeclared) {
-                name = guessXmlName(name);
-                
-                if (name != stylesDeclared.last()) {
-                    sb.append(", ");    //$NON-NLS-1$
-                }
-            }
-            
-            AdtPlugin.log(IStatus.WARNING, "%s", sb.toString());
-            AdtPlugin.printToConsole((String)null, sb);
-            sb.setLength(0);
-        }
-
-        if (!elementsDeclared.isEmpty()) {
-            sb.append("Warning, ADT/SDK Mismatch! The following elements are declared by ADT but not by the SDK: ");
-            for (String name : elementsDeclared) {
-                sb.append(name);
-                if (name != elementsDeclared.last()) {
-                    sb.append(", ");    //$NON-NLS-1$
-                }
-            }
-
-            AdtPlugin.log(IStatus.WARNING, "%s", sb.toString());
-            AdtPlugin.printToConsole((String)null, sb);
-        }
-    }
-
-    /**
-     * Performs an approximate translation of the style name into a potential
-     * xml name. This is more or less the reverse from guessStyleName().
-     * 
-     * @return The XML local name for a given style name. 
-     */
-    private String guessXmlName(String name) {
-        StringBuilder sb = new StringBuilder();
-        if (ANDROID_MANIFEST_STYLEABLE.equals(name)) {
-            sb.append(MANIFEST_NODE_NAME);
-        } else {
-            name = name.replace(ANDROID_MANIFEST_STYLEABLE, "");    //$NON-NLS-1$
-            boolean first_char = true;
-            for (char c : name.toCharArray()) {
-                if (c >= 'A' && c <= 'Z') {
-                    if (!first_char) {
-                        sb.append('-');
-                    }
-                    c = (char) (c - 'A' + 'a');
-                }
-                sb.append(c);
-                first_char = false;
-            }
-        }
-        return sb.toString();
-    }
-
-    /**
-     * Helper method used by {@link #sanityCheck(Map, ElementDescriptor)} to find all the
-     * {@link ElementDescriptor} names defined by the tree of descriptors.
-     * <p/>
-     * Note: this assumes no circular reference in the tree of {@link ElementDescriptor}s.
-     */
-    private void findAllElementNames(ElementDescriptor element, TreeSet<String> declared) {
-        declared.add(element.getXmlName());
-        for (ElementDescriptor desc : element.getChildren()) {
-            findAllElementNames(desc, declared);
-        }
-    }
-
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ApplicationAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ApplicationAttributeDescriptor.java
deleted file mode 100644
index eab7f09..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ApplicationAttributeDescriptor.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * Describes an 'Application' class XML attribute. It is displayed by a
- * {@link UiClassAttributeNode}, that restricts creation and selection to classes
- * inheriting from android.app.Application.
- */
-public class ApplicationAttributeDescriptor extends TextAttributeDescriptor {
-
-    public ApplicationAttributeDescriptor(String xmlLocalName, String uiName,
-            String nsUri, String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiClassAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiClassAttributeNode("android.app.Application", //$NON-NLS-1$
-                null /* postCreationAction */, false /* mandatory */, this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ClassAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ClassAttributeDescriptor.java
deleted file mode 100644
index abaf438..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ClassAttributeDescriptor.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode.IPostTypeCreationAction;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * Describes an XML attribute representing a class name.
- * It is displayed by a {@link UiClassAttributeNode}.
- */
-public class ClassAttributeDescriptor extends TextAttributeDescriptor {
-
-    /** Superclass of the class value. */
-    private String mSuperClassName;
-    
-    private IPostTypeCreationAction mPostCreationAction;
-    
-    /** indicates if the class parameter is mandatory */
-    boolean mMandatory;
-    
-    /**
-     * Creates a new {@link ClassAttributeDescriptor}
-     * @param superClassName the fully qualified name of the superclass of the class represented
-     * by the attribute.
-     * @param xmlLocalName The XML name of the attribute (case sensitive, with android: prefix).
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param tooltip A non-empty tooltip string or null.
-     * @param mandatory indicates if the class attribute is mandatory.
-     */
-    public ClassAttributeDescriptor(String superClassName,
-            String xmlLocalName, String uiName, String nsUri,
-            String tooltip, boolean mandatory) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-        mSuperClassName = superClassName;
-    }
-
-    /**
-     * Creates a new {@link ClassAttributeDescriptor}
-     * @param superClassName the fully qualified name of the superclass of the class represented
-     * by the attribute.
-     * @param postCreationAction the {@link IPostTypeCreationAction} to be executed on the
-     *        newly created class.
-     * @param xmlLocalName The XML local name of the attribute (case sensitive).
-     * @param uiName The UI name of the attribute. Cannot be an empty string and cannot be null.
-     * @param nsUri The URI of the attribute. Can be null if attribute has no namespace.
-     *              See {@link SdkConstants#NS_RESOURCES} for a common value.
-     * @param tooltip A non-empty tooltip string or null.
-     * @param mandatory indicates if the class attribute is mandatory.
-     */
-    public ClassAttributeDescriptor(String superClassName,
-            IPostTypeCreationAction postCreationAction,
-            String xmlLocalName, String uiName, String nsUri,
-            String tooltip, boolean mandatory) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-        mSuperClassName = superClassName;
-        mPostCreationAction = postCreationAction;
-    }
-
-    /**
-     * @return A new {@link UiClassAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiClassAttributeNode(mSuperClassName, mPostCreationAction,
-                mMandatory, this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/InstrumentationAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/InstrumentationAttributeDescriptor.java
deleted file mode 100644
index 6e589f7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/InstrumentationAttributeDescriptor.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * Describes a 'Instrumentation' class XML attribute. It is displayed by a
- * {@link UiClassAttributeNode}, that restricts creation and selection to classes inheriting from
- * android.app.Instrumentation.
- */
-public class InstrumentationAttributeDescriptor extends TextAttributeDescriptor {
-
-    public InstrumentationAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiClassAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiClassAttributeNode(AndroidConstants.CLASS_INSTRUMENTATION,
-                null /* postCreationAction */, true /* mandatory */, this, uiParent);
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ManifestElementDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ManifestElementDescriptor.java
deleted file mode 100644
index d89292b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ManifestElementDescriptor.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.model.UiManifestElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * {@link ManifestElementDescriptor} describes an XML element node, with its
- * element name, its possible attributes, its possible child elements but also
- * its display name and tooltip.
- * 
- * This {@link ElementDescriptor} is specialized to create {@link UiManifestElementNode} UI nodes.
- */
-public class ManifestElementDescriptor extends ElementDescriptor {
-
-    /**
-     * Constructs a new {@link ManifestElementDescriptor}.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param ui_name The XML element name for the user interface, typically capitalized.
-     * @param tooltip An optional tooltip. Can be null or empty.
-     * @param sdk_url An optional SKD URL. Can be null or empty.
-     * @param attributes The list of allowed attributes. Can be null or empty.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models).
-     */
-    public ManifestElementDescriptor(String xml_name, String ui_name, String tooltip, String sdk_url,
-            AttributeDescriptor[] attributes,
-            ElementDescriptor[] children,
-            boolean mandatory) {
-        super(xml_name, ui_name, tooltip, sdk_url, attributes, children, mandatory);
-    }
-
-    /**
-     * Constructs a new {@link ManifestElementDescriptor}.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param ui_name The XML element name for the user interface, typically capitalized.
-     * @param tooltip An optional tooltip. Can be null or empty.
-     * @param sdk_url An optional SKD URL. Can be null or empty.
-     * @param attributes The list of allowed attributes. Can be null or empty.
-     * @param children The list of allowed children. Can be null or empty.
-     */
-    public ManifestElementDescriptor(String xml_name, String ui_name, String tooltip, String sdk_url,
-            AttributeDescriptor[] attributes,
-            ElementDescriptor[] children) {
-        super(xml_name, ui_name, tooltip, sdk_url, attributes, children, false);
-    }
-
-    /**
-     * This is a shortcut for
-     * ManifestElementDescriptor(xml_name, xml_name.capitalize(), null, null, null, children).
-     * This constructor is mostly used for unit tests.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     */
-    public ManifestElementDescriptor(String xml_name, ElementDescriptor[] children) {
-        super(xml_name, children);
-    }
-
-    /**
-     * This is a shortcut for
-     * ManifestElementDescriptor(xml_name, xml_name.capitalize(), null, null, null, null).
-     * This constructor is mostly used for unit tests.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     */
-    public ManifestElementDescriptor(String xml_name) {
-        super(xml_name, null);
-    }
-
-    /**
-     * @return A new {@link UiElementNode} linked to this descriptor.
-     */
-    @Override
-    public UiElementNode createUiNode() {
-        return new UiManifestElementNode(this);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PackageAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PackageAttributeDescriptor.java
deleted file mode 100644
index 34c5d0d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PackageAttributeDescriptor.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.model.UiPackageAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * Describes a package XML attribute. It is displayed by a {@link UiPackageAttributeNode}.
- */
-public class PackageAttributeDescriptor extends TextAttributeDescriptor {
-
-    public PackageAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiPackageAttributeNode} linked to this descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiPackageAttributeNode(this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostActivityCreationAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostActivityCreationAction.java
deleted file mode 100644
index 3442c24..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostActivityCreationAction.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode.IPostTypeCreationAction;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaModelException;
-
-/**
- * Action to be executed after an Activity class is created.
- */
-class PostActivityCreationAction implements IPostTypeCreationAction {
-    
-    private final static PostActivityCreationAction sAction = new PostActivityCreationAction();
-    
-    private PostActivityCreationAction() {
-        // private constructor to enforce singleton.
-    }
-    
-    
-    /**
-     * Returns the action.
-     */
-    public static IPostTypeCreationAction getAction() {
-        return sAction;
-    }
-
-    /**
-     * Processes a newly created Activity.
-     * 
-     */
-    public void processNewType(IType newType) {
-        try {
-            String methodContent = 
-                "    /** Called when the activity is first created. */\n" +
-                "    @Override\n" +
-                "    public void onCreate(Bundle savedInstanceState) {\n" +
-                "        super.onCreate(savedInstanceState);\n" +
-                "\n" +
-                "        // TODO Auto-generated method stub\n" +
-                "    }";
-            newType.createMethod(methodContent, null /* sibling*/, false /* force */,
-                    new NullProgressMonitor());
-
-            // we need to add the import for Bundle, so we need the compilation unit.
-            // Since the type could be enclosed in other types, we loop till we find it.
-            ICompilationUnit compilationUnit = null;
-            IJavaElement element = newType;
-            do {
-                IJavaElement parentElement = element.getParent();
-                if (parentElement !=  null) {
-                    if (parentElement.getElementType() == IJavaElement.COMPILATION_UNIT) {
-                        compilationUnit = (ICompilationUnit)parentElement;
-                    }
-                    
-                    element = parentElement;
-                } else {
-                    break;
-                }
-            } while (compilationUnit == null);
-            
-            if (compilationUnit != null) {
-                compilationUnit.createImport(AndroidConstants.CLASS_BUNDLE,
-                        null /* sibling */, new NullProgressMonitor());
-            }
-        } catch (JavaModelException e) {
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostReceiverCreationAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostReceiverCreationAction.java
deleted file mode 100644
index 5a8137d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/PostReceiverCreationAction.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.manifest.model.UiClassAttributeNode.IPostTypeCreationAction;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaModelException;
-
-/**
- * Action to be executed after an BroadcastReceiver class is created.
- */
-class PostReceiverCreationAction implements IPostTypeCreationAction {
-    
-    private final static PostReceiverCreationAction sAction = new PostReceiverCreationAction();
-    
-    private PostReceiverCreationAction() {
-        // private constructor to enforce singleton.
-    }
-    
-    /**
-     * Returns the action.
-     */
-    public static IPostTypeCreationAction getAction() {
-        return sAction;
-    }
-
-    /**
-     * Processes a newly created Activity.
-     * 
-     */
-    public void processNewType(IType newType) {
-        try {
-            String methodContent = 
-                "    @Override\n" +
-                "    public void onReceive(Context context, Intent intent) {\n" +
-                "        // TODO Auto-generated method stub\n" +
-                "    }";
-            newType.createMethod(methodContent, null /* sibling*/, false /* force */,
-                    new NullProgressMonitor());
-
-            // we need to add the import for Bundle, so we need the compilation unit.
-            // Since the type could be enclosed in other types, we loop till we find it.
-            ICompilationUnit compilationUnit = null;
-            IJavaElement element = newType;
-            do {
-                IJavaElement parentElement = element.getParent();
-                if (parentElement !=  null) {
-                    if (parentElement.getElementType() == IJavaElement.COMPILATION_UNIT) {
-                        compilationUnit = (ICompilationUnit)parentElement;
-                    }
-                    
-                    element = parentElement;
-                } else {
-                    break;
-                }
-            } while (compilationUnit == null);
-            
-            if (compilationUnit != null) {
-                compilationUnit.createImport(AndroidConstants.CLASS_CONTEXT,
-                        null /* sibling */, new NullProgressMonitor());
-                compilationUnit.createImport(AndroidConstants.CLASS_INTENT,
-                        null /* sibling */, new NullProgressMonitor());
-            }
-        } catch (JavaModelException e) {
-            // looks like the class already existed (this happens when the user check to create
-            // inherited abstract methods).
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ThemeAttributeDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ThemeAttributeDescriptor.java
deleted file mode 100644
index 4219007..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/descriptors/ThemeAttributeDescriptor.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.descriptors;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiResourceAttributeNode;
-
-/**
- * Describes a Theme/Style XML attribute displayed by a {@link UiResourceAttributeNode}
- */
-public final class ThemeAttributeDescriptor extends TextAttributeDescriptor {
-
-    public ThemeAttributeDescriptor(String xmlLocalName, String uiName, String nsUri,
-            String tooltip) {
-        super(xmlLocalName, uiName, nsUri, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiResourceAttributeNode} linked to this theme descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiResourceAttributeNode(ResourceType.STYLE, this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiClassAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiClassAttributeNode.java
deleted file mode 100644
index f8aac1d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiClassAttributeNode.java
+++ /dev/null
@@ -1,624 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.model;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiTextAttributeNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jdt.core.search.SearchEngine;
-import org.eclipse.jdt.ui.IJavaElementSearchConstants;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jdt.ui.actions.OpenNewClassWizardAction;
-import org.eclipse.jdt.ui.dialogs.ITypeInfoFilterExtension;
-import org.eclipse.jdt.ui.dialogs.ITypeInfoRequestor;
-import org.eclipse.jdt.ui.dialogs.ITypeSelectionComponent;
-import org.eclipse.jdt.ui.dialogs.TypeSelectionExtension;
-import org.eclipse.jdt.ui.wizards.NewClassWizardPage;
-import org.eclipse.jface.dialogs.IMessageProvider;
-import org.eclipse.jface.window.Window;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.w3c.dom.Element;
-
-import java.util.ArrayList;
-
-/**
- * Represents an XML attribute for a class, that can be modified using a simple text field or
- * a dialog to choose an existing class. Also, there's a link to create a new class.
- * <p/>
- * See {@link UiTextAttributeNode} for more information.
- */
-public class UiClassAttributeNode extends UiTextAttributeNode {
-
-    private String mReferenceClass;
-    private IPostTypeCreationAction mPostCreationAction;
-    private boolean mMandatory;
-    
-    private class HierarchyTypeSelection extends TypeSelectionExtension {
-        
-        private IJavaProject mJavaProject;
-
-        public HierarchyTypeSelection(IProject project, String referenceClass) {
-            mJavaProject = JavaCore.create(project);
-            mReferenceClass = referenceClass;
-        }
-
-        @Override
-        public ITypeInfoFilterExtension getFilterExtension() {
-            return new ITypeInfoFilterExtension() {
-                public boolean select(ITypeInfoRequestor typeInfoRequestor) {
-                    String packageName = typeInfoRequestor.getPackageName();
-                    String typeName = typeInfoRequestor.getTypeName();
-                    String enclosingType = typeInfoRequestor.getEnclosingName();
-                    
-                    // build the full class name.
-                    StringBuilder sb = new StringBuilder(packageName);
-                    sb.append('.');
-                    if (enclosingType.length() > 0) {
-                        sb.append(enclosingType);
-                        sb.append('.');
-                    }
-                    sb.append(typeName);
-                    
-                    String className = sb.toString();
-                    
-                    try {
-                        IType type = mJavaProject.findType(className);
-                        if (type != null) {
-                            // get the type hierarchy
-                            ITypeHierarchy hierarchy = type.newSupertypeHierarchy(
-                                    new NullProgressMonitor());
-                            
-                            // if the super class is not the reference class, it may inherit from
-                            // it so we get its supertype. At some point it will be null and we
-                            // will return false;
-                            IType superType = type;
-                            while ((superType = hierarchy.getSuperclass(superType)) != null) {
-                                if (mReferenceClass.equals(superType.getFullyQualifiedName())) {
-                                    return true;
-                                }
-                            }
-                        }
-                    } catch (JavaModelException e) {
-                    }
-                    
-                    return false;
-                }
-            };
-        }
-    }
-
-    /**
-     * Classes which implement this interface provide a method processing newly created classes.
-     */
-    public static interface IPostTypeCreationAction {
-        /**
-         * Sent to process a newly created class.
-         * @param newType the IType representing the newly created class.
-         */
-        public void processNewType(IType newType);
-    }
-
-    /**
-     * Creates a {@link UiClassAttributeNode} object that will display ui to select or create
-     * classes.
-     * @param referenceClass The allowed supertype of the classes that are to be selected
-     * or created. Can be null.
-     * @param postCreationAction a {@link IPostTypeCreationAction} object handling post creation
-     * modification of the class.
-     * @param mandatory indicates if the class value is mandatory
-     * @param attributeDescriptor the {@link AttributeDescriptor} object linked to the Ui Node.
-     */
-    public UiClassAttributeNode(String referenceClass, IPostTypeCreationAction postCreationAction,
-            boolean mandatory, AttributeDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-        
-        mReferenceClass = referenceClass;
-        mPostCreationAction = postCreationAction;
-        mMandatory = mandatory;
-    }
-
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public void createUiControl(final Composite parent, IManagedForm managedForm) {
-        setManagedForm(managedForm);
-        FormToolkit toolkit = managedForm.getToolkit();
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-
-        StringBuilder label = new StringBuilder();
-        label.append("<form><p><a href='unused'>");
-        label.append(desc.getUiName());
-        label.append("</a></p></form>");
-        FormText formText = SectionHelper.createFormText(parent, toolkit, true /* isHtml */,
-                label.toString(), true /* setupLayoutData */);
-        formText.addHyperlinkListener(new HyperlinkAdapter() {
-            @Override
-            public void linkActivated(HyperlinkEvent e) {
-                super.linkActivated(e);
-                handleLabelClick();
-            }
-        });
-        formText.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        SectionHelper.addControlTooltip(formText, desc.getTooltip());
-        
-        Composite composite = toolkit.createComposite(parent);
-        composite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE));
-        GridLayout gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        composite.setLayout(gl);
-        // Fixes missing text borders under GTK... also requires adding a 1-pixel margin
-        // for the text field below
-        toolkit.paintBordersFor(composite);
-        
-        final Text text = toolkit.createText(composite, getCurrentValue());
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalIndent = 1;  // Needed by the fixed composite borders under GTK
-        text.setLayoutData(gd);
-        Button browseButton = toolkit.createButton(composite, "Browse...", SWT.PUSH);
-        
-        setTextWidget(text);
-
-        browseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                handleBrowseClick();
-            }
-        });
-    }
-    
-    /* (non-java doc)
-     * 
-     * Add a modify listener that will check the validity of the class
-     */
-    @Override
-    protected void onAddValidators(final Text text) {
-        ModifyListener listener = new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                try {
-                    String textValue = text.getText().trim();
-                    if (textValue.length() == 0) {
-                        if (mMandatory) {
-                            setErrorMessage("Value is mandatory", text);
-                        } else {
-                            setErrorMessage(null, text);
-                        }
-                        return;
-                    }
-                    // first we need the current java package.
-                    String javaPackage = getManifestPackage();
-
-                    // build the fully qualified name of the class
-                    String className = AndroidManifestHelper.combinePackageAndClassName(javaPackage,
-                            textValue);
-                    
-                    // only test the vilibility for activities.
-                    boolean testVisibility = AndroidConstants.CLASS_ACTIVITY.equals(
-                            mReferenceClass); 
-
-                    // test the class
-                    setErrorMessage(BaseProjectHelper.testClassForManifest(
-                            BaseProjectHelper.getJavaProject(getProject()), className,
-                            mReferenceClass, testVisibility), text);
-                } catch (CoreException ce) {
-                    setErrorMessage(ce.getMessage(), text);
-                }
-            }
-        };
-
-        text.addModifyListener(listener);
-
-        // Make sure the validator removes its message(s) when the widget is disposed
-        text.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                // we don't want to use setErrorMessage, because we don't want to reset
-                // the error flag in the UiAttributeNode
-                getManagedForm().getMessageManager().removeMessage(text, text);
-            }
-        });
-
-        // Finally call the validator once to make sure the initial value is processed
-        listener.modifyText(null);
-    }
-
-    private void handleBrowseClick() {
-        Text text = getTextWidget();
-        
-        // we need to get the project of the manifest.
-        IProject project = getProject();
-        if (project != null) {
-            
-            // Create a search scope including only the source folder of the current
-            // project.
-            IJavaSearchScope scope = SearchEngine.createJavaSearchScope(
-                    getPackageFragmentRoots(project), false);
-
-            try {
-                SelectionDialog dlg = JavaUI.createTypeDialog(text.getShell(),
-                    PlatformUI.getWorkbench().getProgressService(),
-                    scope,
-                    IJavaElementSearchConstants.CONSIDER_CLASSES,  // style
-                    false, // no multiple selection
-                    "**", //$NON-NLS-1$ //filter
-                    new HierarchyTypeSelection(project, mReferenceClass));
-                dlg.setMessage(String.format("Select class name for element %1$s:",
-                        getUiParent().getBreadcrumbTrailDescription(false /* include_root */)));
-                if (dlg instanceof ITypeSelectionComponent) {
-                    ((ITypeSelectionComponent)dlg).triggerSearch();
-                }
-                
-                if (dlg.open() == Window.OK) {
-                    Object[] results = dlg.getResult();
-                    if (results.length == 1) {
-                        handleNewType((IType)results[0]);
-                    }
-                }
-            } catch (JavaModelException e1) {
-            }
-        }
-    }
-
-    private void handleLabelClick() {
-        // get the current value
-        String className = getTextWidget().getText().trim();
-
-        // get the package name from the manifest.
-        String packageName = getManifestPackage();
-        
-        if (className.length() == 0) {
-            createNewClass(packageName, null /* className */);
-        } else {
-            // build back the fully qualified class name.
-            String fullClassName = className;
-            if (className.startsWith(".")) { //$NON-NLS-1$
-                fullClassName = packageName + className;
-            } else {
-                String[] segments = className.split(AndroidConstants.RE_DOT);
-                if (segments.length == 1) {
-                    fullClassName = packageName + "." + className; //$NON-NLS-1$
-                }
-            }
-            
-            // in case the type is enclosed, we need to replace the $ with .
-            fullClassName = fullClassName.replaceAll("\\$", "\\."); //$NON-NLS-1$ //$NON-NLS2$
-            
-            // now we try to find the file that contains this class and we open it in the editor.
-            IProject project = getProject();
-            IJavaProject javaProject = JavaCore.create(project);
-
-            try {
-                IType result = javaProject.findType(fullClassName);
-                if (result != null) {
-                    JavaUI.openInEditor(result);
-                } else {
-                    // split the last segment from the fullClassname
-                    int index = fullClassName.lastIndexOf('.');
-                    if (index != -1) {
-                        createNewClass(fullClassName.substring(0, index),
-                                fullClassName.substring(index+1));
-                    } else {
-                        createNewClass(packageName, className);
-                    }
-                }
-            } catch (JavaModelException e) {
-            } catch (PartInitException e) {
-            }
-        }
-    }
-    
-    private IProject getProject() {
-        UiElementNode uiNode = getUiParent();
-        AndroidEditor editor = uiNode.getEditor();
-        IEditorInput input = editor.getEditorInput();
-        if (input instanceof IFileEditorInput) {
-            // from the file editor we can get the IFile object, and from it, the IProject.
-            IFile file = ((IFileEditorInput)input).getFile();
-            return file.getProject();
-        }
-        
-        return null;
-    }
-
-
-    /**
-     * Returns the current value of the /manifest/package attribute.
-     * @return the package or an empty string if not found
-     */
-    private String getManifestPackage() {
-        // get the root uiNode to get the 'package' attribute value.
-        UiElementNode rootNode = getUiParent().getUiRoot();
-                  
-        Element xmlElement = (Element) rootNode.getXmlNode();
-
-        if (xmlElement != null) {
-            return xmlElement.getAttribute(AndroidManifestDescriptors.PACKAGE_ATTR);
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-
-    /**
-     * Computes and return the {@link IPackageFragmentRoot}s corresponding to the source folders of
-     * the specified project.
-     * @param project the project
-     * @return an array of IPackageFragmentRoot.
-     */
-    private IPackageFragmentRoot[] getPackageFragmentRoots(IProject project) {
-        ArrayList<IPackageFragmentRoot> result = new ArrayList<IPackageFragmentRoot>();
-        try {
-            IJavaProject javaProject = JavaCore.create(project);
-            IPackageFragmentRoot[] roots = javaProject.getPackageFragmentRoots();
-            for (int i = 0; i < roots.length; i++) {
-                IClasspathEntry entry = roots[i].getRawClasspathEntry();
-                if (entry.getEntryKind() == IClasspathEntry.CPE_SOURCE) {
-                    result.add(roots[i]);
-                }
-            }
-        } catch (JavaModelException e) {
-        }
-
-        return result.toArray(new IPackageFragmentRoot[result.size()]);
-    }
-    
-    private void handleNewType(IType type) {
-        Text text = getTextWidget();
-
-        // get the fully qualified name with $ to properly detect the enclosing types.
-        String name = type.getFullyQualifiedName('$');
-        
-        String packageValue = getManifestPackage();
-        
-        // check if the class doesn't start with the package.
-        if (packageValue.length() > 0 && name.startsWith(packageValue)) {
-            // if it does, we remove the package and the first dot.
-            name = name.substring(packageValue.length() + 1);
-            
-            // look for how many segments we have left.
-            // if one, just write it that way.
-            // if more than one, write it with a leading dot.
-            String[] packages = name.split(AndroidConstants.RE_DOT);
-            if (packages.length == 1) {
-                text.setText(name);
-            } else {
-                text.setText("." + name); //$NON-NLS-1$
-            }
-        } else {
-            text.setText(name);
-        }
-    }
-    
-    private void createNewClass(String packageName, String className) {
-        // create the wizard page for the class creation, and configure it
-        NewClassWizardPage page = new NewClassWizardPage();
-        
-        // set the parent class
-        page.setSuperClass(mReferenceClass, true /* canBeModified */);
-        
-        // get the source folders as java elements.
-        IPackageFragmentRoot[] roots = getPackageFragmentRoots(getProject());
-
-        IPackageFragmentRoot currentRoot = null;
-        IPackageFragment currentFragment = null;
-        int packageMatchCount = -1;
-        
-        for (IPackageFragmentRoot root : roots) {
-            // Get the java element for the package.
-            // This method is said to always return a IPackageFragment even if the
-            // underlying folder doesn't exist...
-            IPackageFragment fragment = root.getPackageFragment(packageName);
-            if (fragment != null && fragment.exists()) {
-                // we have a perfect match! we use it.
-                currentRoot = root;
-                currentFragment = fragment;
-                packageMatchCount = -1;
-                break;
-            } else {
-                // we don't have a match. we look for the fragment with the best match
-                // (ie the closest parent package we can find)
-                try {
-                    IJavaElement[] children;
-                    children = root.getChildren();
-                    for (IJavaElement child : children) {
-                        if (child instanceof IPackageFragment) {
-                            fragment = (IPackageFragment)child;
-                            if (packageName.startsWith(fragment.getElementName())) {
-                                // its a match. get the number of segments
-                                String[] segments = fragment.getElementName().split("\\."); //$NON-NLS-1$
-                                if (segments.length > packageMatchCount) {
-                                    packageMatchCount = segments.length;
-                                    currentFragment = fragment;
-                                    currentRoot = root;
-                                }
-                            }
-                        }
-                    }
-                } catch (JavaModelException e) {
-                    // Couldn't get the children: we just ignore this package root.
-                }
-            }
-        }
-        
-        ArrayList<IPackageFragment> createdFragments = null;
-
-        if (currentRoot != null) {
-            // if we have a perfect match, we set it and we're done.
-            if (packageMatchCount == -1) {
-                page.setPackageFragmentRoot(currentRoot, true /* canBeModified*/);
-                page.setPackageFragment(currentFragment, true /* canBeModified */);
-            } else {
-                // we have a partial match.
-                // create the package. We have to start with the first segment so that we
-                // know what to delete in case of a cancel.
-                try {
-                    createdFragments = new ArrayList<IPackageFragment>();
-                    
-                    int totalCount = packageName.split("\\.").length; //$NON-NLS-1$
-                    int count = 0;
-                    int index = -1;
-                    // skip the matching packages
-                    while (count < packageMatchCount) {
-                        index = packageName.indexOf('.', index+1);
-                        count++;
-                    }
-                    
-                    // create the rest of the segments, except for the last one as indexOf will
-                    // return -1;
-                    while (count < totalCount - 1) {
-                        index = packageName.indexOf('.', index+1);
-                        count++;
-                        createdFragments.add(currentRoot.createPackageFragment(
-                                packageName.substring(0, index),
-                                true /* force*/, new NullProgressMonitor()));
-                    }
-                    
-                    // create the last package
-                    createdFragments.add(currentRoot.createPackageFragment(
-                            packageName, true /* force*/, new NullProgressMonitor()));
-                    
-                    // set the root and fragment in the Wizard page
-                    page.setPackageFragmentRoot(currentRoot, true /* canBeModified*/);
-                    page.setPackageFragment(createdFragments.get(createdFragments.size()-1),
-                            true /* canBeModified */);
-                } catch (JavaModelException e) {
-                    // if we can't create the packages, there's a problem. we revert to the default
-                    // package
-                    for (IPackageFragmentRoot root : roots) {
-                        // Get the java element for the package.
-                        // This method is said to always return a IPackageFragment even if the
-                        // underlying folder doesn't exist...
-                        IPackageFragment fragment = root.getPackageFragment(packageName);
-                        if (fragment != null && fragment.exists()) {
-                            page.setPackageFragmentRoot(root, true /* canBeModified*/);
-                            page.setPackageFragment(fragment, true /* canBeModified */);
-                            break;
-                        }
-                    }
-                }
-            }
-        } else if (roots.length > 0) {
-            // if we haven't found a valid fragment, we set the root to the first source folder.
-            page.setPackageFragmentRoot(roots[0], true /* canBeModified*/);
-        }
-        
-        // if we have a starting class name we use it
-        if (className != null) {
-            page.setTypeName(className, true /* canBeModified*/);
-        }
-        
-        // create the action that will open it the wizard.
-        OpenNewClassWizardAction action = new OpenNewClassWizardAction();
-        action.setConfiguredWizardPage(page);
-        action.run();
-        IJavaElement element = action.getCreatedElement();
-        
-        if (element != null) {
-            if (element.getElementType() == IJavaElement.TYPE) {
-                    
-                IType type = (IType)element;
-                
-                if (mPostCreationAction != null) {
-                    mPostCreationAction.processNewType(type);
-                }
-                
-                handleNewType(type);
-            }
-        } else {
-            // lets delete the packages we created just for this.
-            // we need to start with the leaf and go up
-            if (createdFragments != null) {
-                try {
-                    for (int i = createdFragments.size() - 1 ; i >= 0 ; i--) {
-                        createdFragments.get(i).delete(true /* force*/, new NullProgressMonitor());
-                    }
-                } catch (JavaModelException e) {
-                    e.printStackTrace();
-                }
-            }
-        }
-    }
-    
-    /**
-     * Sets the error messages. If message is <code>null</code>, the message is removed.
-     * @param message the message to set, or <code>null</code> to remove the current message
-     * @param textWidget the {@link Text} widget associated to the message.
-     */
-    private final void setErrorMessage(String message, Text textWidget) {
-        if (message != null) {
-            setHasError(true);
-            getManagedForm().getMessageManager().addMessage(textWidget, message, null /* data */,
-                    IMessageProvider.ERROR, textWidget);
-        } else {
-            setHasError(false);
-            getManagedForm().getMessageManager().removeMessage(textWidget, textWidget);
-        }
-    }
-    
-    @Override
-    public String[] getPossibleValues() {
-        // TODO: compute a list of existing classes for content assist completion
-        return null;
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiManifestElementNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiManifestElementNode.java
deleted file mode 100644
index fb8f211..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiManifestElementNode.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.model;
-
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.manifest.descriptors.ManifestElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.w3c.dom.Element;
-
-/**
- * Represents an XML node that can be modified by the user interface in the XML editor.
- * <p/>
- * Each tree viewer used in the application page's parts needs to keep a model representing
- * each underlying node in the tree. This interface represents the base type for such a node.
- * <p/>
- * Each node acts as an intermediary model between the actual XML model (the real data support)
- * and the tree viewers or the corresponding page parts.
- * <p/>
- * Element nodes don't contain data per se. Their data is contained in their attributes
- * as well as their children's attributes, see {@link UiAttributeNode}.
- * <p/>
- * The structure of a given {@link UiElementNode} is declared by a corresponding
- * {@link ElementDescriptor}.
- */
-public final class UiManifestElementNode extends UiElementNode {
-    
-    /**
-     * Creates a new {@link UiElementNode} described by a given {@link ElementDescriptor}.
-     * 
-     * @param elementDescriptor The {@link ElementDescriptor} for the XML node. Cannot be null.
-     */
-    public UiManifestElementNode(ManifestElementDescriptor elementDescriptor) {
-        super(elementDescriptor);
-    }
-
-    /**
-     * Computes a short string describing the UI node suitable for tree views.
-     * Uses the element's attribute "android:name" if present, or the "android:label" one
-     * followed by the element's name.
-     * 
-     * @return A short string describing the UI node suitable for tree views.
-     */
-    @Override
-    public String getShortDescription() {
-        if (getXmlNode() != null &&
-                getXmlNode() instanceof Element &&
-                getXmlNode().hasAttributes()) {
-
-            AndroidManifestDescriptors manifestDescriptors =
-                    getAndroidTarget().getManifestDescriptors();
-            
-            // Application and Manifest nodes have a special treatment: they are unique nodes
-            // so we don't bother trying to differentiate their strings and we fall back to
-            // just using the UI name below.
-            ElementDescriptor desc = getDescriptor();
-            if (desc != manifestDescriptors.getManifestElement() &&
-                    desc != manifestDescriptors.getApplicationElement()) {
-                Element elem = (Element) getXmlNode();
-                String attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                                  AndroidManifestDescriptors.ANDROID_NAME_ATTR);
-                if (attr == null || attr.length() == 0) {
-                    attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                               AndroidManifestDescriptors.ANDROID_LABEL_ATTR);
-                }
-                if (attr != null && attr.length() > 0) {
-                    return String.format("%1$s (%2$s)", attr, getDescriptor().getUiName());
-                }
-            }
-        }
-
-        return String.format("%1$s", getDescriptor().getUiName());
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiPackageAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiPackageAttributeNode.java
deleted file mode 100644
index 02fb44f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/model/UiPackageAttributeNode.java
+++ /dev/null
@@ -1,319 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.model;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiTextAttributeNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jdt.ui.actions.OpenNewPackageWizardAction;
-import org.eclipse.jdt.ui.actions.ShowInPackageViewAction;
-import org.eclipse.jface.dialogs.IMessageProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.window.Window;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.IWorkbenchPartSite;
-import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-
-import java.util.ArrayList;
-
-/**
- * Represents an XML attribute for a package, that can be modified using a simple text field or
- * a dialog to choose an existing package. Also, there's a link to create a new package.
- * <p/>
- * See {@link UiTextAttributeNode} for more information.
- */
-public class UiPackageAttributeNode extends UiTextAttributeNode {
-
-    /**
-     * Creates a {@link UiPackageAttributeNode} object that will display ui to select or create
-     * a package.
-     * @param attributeDescriptor the {@link AttributeDescriptor} object linked to the Ui Node.
-     */
-    public UiPackageAttributeNode(AttributeDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public void createUiControl(final Composite parent, final IManagedForm managedForm) {
-        setManagedForm(managedForm);
-        FormToolkit toolkit = managedForm.getToolkit();
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-
-        StringBuilder label = new StringBuilder();
-        label.append("<form><p><a href='unused'>");  //$NON-NLS-1$
-        label.append(desc.getUiName());
-        label.append("</a></p></form>");  //$NON-NLS-1$
-        FormText formText = SectionHelper.createFormText(parent, toolkit, true /* isHtml */,
-                label.toString(), true /* setupLayoutData */);
-        formText.addHyperlinkListener(new HyperlinkAdapter() {
-            @Override
-            public void linkActivated(HyperlinkEvent e) {
-                super.linkActivated(e);
-                doLabelClick();
-            }
-        });
-        formText.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        SectionHelper.addControlTooltip(formText, desc.getTooltip());
-        
-        Composite composite = toolkit.createComposite(parent);
-        composite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE));
-        GridLayout gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        composite.setLayout(gl);
-        // Fixes missing text borders under GTK... also requires adding a 1-pixel margin
-        // for the text field below
-        toolkit.paintBordersFor(composite);
-        
-        final Text text = toolkit.createText(composite, getCurrentValue());
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalIndent = 1;  // Needed by the fixed composite borders under GTK
-        text.setLayoutData(gd);
-
-        setTextWidget(text);
-
-        Button browseButton = toolkit.createButton(composite, "Browse...", SWT.PUSH);
-        
-        browseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                doBrowseClick();
-            }
-        });
-        
-    }
-    
-    /* (non-java doc)
-     * Adds a validator to the text field that calls managedForm.getMessageManager().
-     */
-    @Override
-    protected void onAddValidators(final Text text) {
-        ModifyListener listener = new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                String package_name = text.getText();
-                if (package_name.indexOf('.') < 1) {
-                    getManagedForm().getMessageManager().addMessage(text,
-                            "Package name should contain at least two identifiers.",
-                            null /* data */, IMessageProvider.ERROR, text);
-                } else {
-                    getManagedForm().getMessageManager().removeMessage(text, text);
-                }
-            }
-        };
-
-        text.addModifyListener(listener);
-
-        // Make sure the validator removes its message(s) when the widget is disposed
-        text.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                getManagedForm().getMessageManager().removeMessage(text, text);
-            }
-        });
-
-        // Finally call the validator once to make sure the initial value is processed
-        listener.modifyText(null);
-    }
-
-    /**
-     * Handles response to the Browse button by creating a Package dialog.
-     * */
-    private void doBrowseClick() {
-        Text text = getTextWidget();
-        
-        // we need to get the project of the manifest.
-        IProject project = getProject();
-        if (project != null) {
-            
-            try {
-                SelectionDialog dlg = JavaUI.createPackageDialog(text.getShell(),
-                        JavaCore.create(project), 0);
-                dlg.setTitle("Select Android Package");
-                dlg.setMessage("Select the package for the Android project.");
-                SelectionDialog.setDefaultImage(AdtPlugin.getAndroidLogo());
-
-                if (dlg.open() == Window.OK) {
-                    Object[] results = dlg.getResult();
-                    if (results.length == 1) {
-                        setPackageTextField((IPackageFragment)results[0]);
-                    }
-                }
-            } catch (JavaModelException e1) {
-            }
-        }
-    }
-
-    /**
-     * Handles response to the Label hyper link being activated.
-     */
-    private void doLabelClick() {
-        // get the current package name
-        String package_name = getTextWidget().getText().trim();
-        
-        if (package_name.length() == 0) {
-            createNewPackage();
-        } else {
-            // Try to select the package in the Package Explorer for the current
-            // project and the current editor's site.
-
-            IProject project = getProject();
-            if (project == null) {
-                AdtPlugin.log(IStatus.ERROR, "Failed to get project for UiPackageAttribute"); //$NON-NLS-1$
-                return;
-            }
-
-            IWorkbenchPartSite site = getUiParent().getEditor().getSite();
-            if (site == null) {
-                AdtPlugin.log(IStatus.ERROR, "Failed to get editor site for UiPackageAttribute"); //$NON-NLS-1$
-                return;
-            }
-
-            for (IPackageFragmentRoot root : getPackageFragmentRoots(project)) {
-                IPackageFragment fragment = root.getPackageFragment(package_name);
-                if (fragment != null && fragment.exists()) {
-                    ShowInPackageViewAction action = new ShowInPackageViewAction(site);
-                    action.run(fragment);
-                    // This action's run() doesn't provide the status (although internally it could)
-                    // so we just assume it worked.
-                    return;
-                }
-            }
-        }
-    }
-
-    /**
-     * Utility method that returns the project for the current file being edited.
-     * 
-     * @return The IProject for the current file being edited or null.
-     */
-    private IProject getProject() {
-        UiElementNode uiNode = getUiParent();
-        AndroidEditor editor = uiNode.getEditor();
-        IEditorInput input = editor.getEditorInput();
-        if (input instanceof IFileEditorInput) {
-            // from the file editor we can get the IFile object, and from it, the IProject.
-            IFile file = ((IFileEditorInput)input).getFile();
-            return file.getProject();
-        }
-        
-        return null;
-    }
-
-    /**
-     * Utility method that computes and returns the list of {@link IPackageFragmentRoot}
-     * corresponding to the source folder of the specified project.
-     * 
-     * @param project the project
-     * @return an array of IPackageFragmentRoot. Can be empty but not null.
-     */
-    private IPackageFragmentRoot[] getPackageFragmentRoots(IProject project) {
-        ArrayList<IPackageFragmentRoot> result = new ArrayList<IPackageFragmentRoot>();
-        try {
-            IJavaProject javaProject = JavaCore.create(project);
-            IPackageFragmentRoot[] roots = javaProject.getPackageFragmentRoots();
-            for (int i = 0; i < roots.length; i++) {
-                IClasspathEntry entry = roots[i].getRawClasspathEntry();
-                if (entry.getEntryKind() == IClasspathEntry.CPE_SOURCE) {
-                    result.add(roots[i]);
-                }
-            }
-        } catch (JavaModelException e) {
-        }
-
-        return result.toArray(new IPackageFragmentRoot[result.size()]);
-    }
-    
-    /**
-     * Utility method that sets the package's text field to the package fragment's name.
-     * */
-    private void setPackageTextField(IPackageFragment type) {
-        Text text = getTextWidget();
-
-        String name = type.getElementName();
-        
-        text.setText(name);
-    }
-    
-
-    /**
-     * Displays and handles a "Create Package Wizard".
-     * 
-     * This is invoked by doLabelClick() when clicking on the hyperlink label with an
-     * empty package text field.  
-     */
-    private void createNewPackage() {
-        OpenNewPackageWizardAction action = new OpenNewPackageWizardAction();
-
-        IProject project = getProject();
-        action.setSelection(new StructuredSelection(project));
-        action.run();
-
-        IJavaElement element = action.getCreatedElement();
-        if (element != null &&
-                element.exists() &&
-                element.getElementType() == IJavaElement.PACKAGE_FRAGMENT) {
-            setPackageTextField((IPackageFragment) element);
-        }
-    }
-    
-    @Override
-    public String[] getPossibleValues() {
-        // TODO: compute a list of existing packages for content assist completion
-        return null;
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationAttributesPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationAttributesPart.java
deleted file mode 100644
index 01b0f8f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationAttributesPart.java
+++ /dev/null
@@ -1,174 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.ui.UiElementPart;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-/**
- * Application's attributes section part for Application page.
- * <p/>
- * This part is displayed at the top of the application page and displays all the possible
- * attributes of an application node in the AndroidManifest (icon, class name, label, etc.)
- */
-final class ApplicationAttributesPart extends UiElementPart {
-
-    /** Listen to changes to the UI node for <application> and updates the UI */
-    private AppNodeUpdateListener mAppNodeUpdateListener;
-    /** ManagedForm needed to create the UI controls */ 
-    private IManagedForm mManagedForm;
-
-    public ApplicationAttributesPart(Composite body, FormToolkit toolkit, ManifestEditor editor,
-            UiElementNode applicationUiNode) {
-        super(body, toolkit, editor, applicationUiNode,
-                "Application Attributes", // section title
-                "Defines the attributes specific to the application.", // section description
-                Section.TWISTIE | Section.EXPANDED);
-    }
-    
-    /**
-     * Changes and refreshes the Application UI node handle by the this part.
-     */
-    @Override
-    public void setUiElementNode(UiElementNode uiElementNode) {
-        super.setUiElementNode(uiElementNode);
-
-        createUiAttributes(mManagedForm);
-    }
-
-    /* (non-java doc)
-     * Create the controls to edit the attributes for the given ElementDescriptor.
-     * <p/>
-     * This MUST not be called by the constructor. Instead it must be called from
-     * <code>initialize</code> (i.e. right after the form part is added to the managed form.)
-     * <p/>
-     * Derived classes can override this if necessary.
-     * 
-     * @param managedForm The owner managed form
-     */
-    @Override
-    protected void createFormControls(final IManagedForm managedForm) {
-        mManagedForm = managedForm; 
-        setTable(createTableLayout(managedForm.getToolkit(), 4 /* numColumns */));
-
-        mAppNodeUpdateListener = new AppNodeUpdateListener();
-        getUiElementNode().addUpdateListener(mAppNodeUpdateListener);
-
-        createUiAttributes(mManagedForm);
-    }
-    
-    @Override
-    public void dispose() {
-        super.dispose();
-        if (getUiElementNode() != null && mAppNodeUpdateListener != null) {
-            getUiElementNode().removeUpdateListener(mAppNodeUpdateListener);
-            mAppNodeUpdateListener = null;
-        }
-    }
-
-    @Override
-    protected void createUiAttributes(IManagedForm managedForm) {
-        Composite table = getTable();
-        if (table == null || managedForm == null) {
-            return;
-        }
-        
-        // Remove any old UI controls 
-        for (Control c : table.getChildren()) {
-            c.dispose();
-        }
-        
-        UiElementNode uiElementNode = getUiElementNode(); 
-        AttributeDescriptor[] attr_desc_list = uiElementNode.getAttributeDescriptors();
-
-        // Display the attributes in 2 columns:
-        // attr 0 | attr 4 
-        // attr 1 | attr 5
-        // attr 2 | attr 6
-        // attr 3 | attr 7
-        // that is we have to fill the grid in order 0, 4, 1, 5, 2, 6, 3, 7
-        // thus index = i/2 + (i is odd * n/2)
-        int n = attr_desc_list.length;
-        int n2 = (int) Math.ceil(n / 2.0);
-        for (int i = 0; i < n; i++) {
-            AttributeDescriptor attr_desc = attr_desc_list[i / 2 + (i & 1) * n2];
-            if (attr_desc instanceof XmlnsAttributeDescriptor) {
-                // Do not show hidden attributes
-                continue;
-            }
-
-            UiAttributeNode ui_attr = uiElementNode.findUiAttribute(attr_desc);
-            if (ui_attr != null) {
-                ui_attr.createUiControl(table, managedForm);
-            } else {
-                // The XML has an extra attribute which wasn't declared in
-                // AndroidManifestDescriptors. This is not a problem, we just ignore it.
-                AdtPlugin.log(IStatus.WARNING,
-                        "Attribute %1$s not declared in node %2$s, ignored.", //$NON-NLS-1$
-                        attr_desc.getXmlLocalName(),
-                        uiElementNode.getDescriptor().getXmlName());
-            }
-        }
-        
-        if (n == 0) {
-            createLabel(table, managedForm.getToolkit(),
-                    "No attributes to display, waiting for SDK to finish loading...",
-                    null /* tooltip */ );
-        }
-
-        // Initialize the enabled/disabled state
-        if (mAppNodeUpdateListener != null) {
-            mAppNodeUpdateListener.uiElementNodeUpdated(uiElementNode, null /* state, not used */);
-        }
-        
-        // Tell the section that the layout has changed.
-        layoutChanged();
-    }
-
-    /**
-     * This listener synchronizes the UI with the actual presence of the application XML node.
-     */
-    private class AppNodeUpdateListener implements IUiUpdateListener {        
-        public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-            // The UiElementNode for the application XML node always exists, even
-            // if there is no corresponding XML node in the XML file.
-            //
-            // We enable the UI here if the XML node is not null.
-            Composite table = getTable();
-            boolean exists = (ui_node.getXmlNode() != null);
-            if (table != null && table.getEnabled() != exists) {
-                table.setEnabled(exists);
-                for (Control c : table.getChildren()) {
-                    c.setEnabled(exists);
-                }
-            }
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationPage.java
deleted file mode 100644
index 77527f0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationPage.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-
-/**
- * Page for "Application" settings, part of the AndroidManifest form editor.
- * <p/>
- * Useful reference:
- * <a href="http://www.eclipse.org/articles/Article-Forms/article.html">
- *   http://www.eclipse.org/articles/Article-Forms/article.html</a>
- */
-public final class ApplicationPage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "application_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    ManifestEditor mEditor;
-    /** The Application Toogle part */
-    private ApplicationToggle mTooglePart;
-    /** The Application Attributes part */ 
-    private ApplicationAttributesPart mAttrPart;
-    /** The tree view block */
-    private UiTreeBlock mTreeBlock;
-
-    public ApplicationPage(ManifestEditor editor) {
-        super(editor, PAGE_ID, "Application"); // tab's label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Manifest Application");
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode appUiNode = getUiApplicationNode();
-
-        Composite body = form.getBody();
-        FormToolkit toolkit = managedForm.getToolkit();
-        
-        // We usually prefer to have a ColumnLayout here. However
-        // MasterDetailsBlock.createContent() below will reset the body's layout to a grid layout.
-        mTooglePart = new ApplicationToggle(body, toolkit, mEditor, appUiNode);
-        mTooglePart.getSection().setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false));
-        managedForm.addPart(mTooglePart);
-        mAttrPart = new ApplicationAttributesPart(body, toolkit, mEditor, appUiNode);
-        mAttrPart.getSection().setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false));
-        managedForm.addPart(mAttrPart);
-
-        mTreeBlock = new UiTreeBlock(mEditor, appUiNode,
-                false /* autoCreateRoot */,
-                null /* element filters */,
-                "Application Nodes",
-                "List of all elements in the application");
-        mTreeBlock.createContent(managedForm);
-    }
-
-    /**
-     * Retrieves the application UI node. Since this is a mandatory node, it *always*
-     * exists, even if there is no matching XML node.
-     */
-    private UiElementNode getUiApplicationNode() {
-        AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-        if (manifestDescriptor != null) {
-            ElementDescriptor desc = manifestDescriptor.getApplicationElement();
-            return mEditor.getUiRootNode().findUiChildNode(desc.getXmlName());
-        } else {
-            // return the ui root node, as a dummy application root node.
-            return mEditor.getUiRootNode();
-        }
-    }
-
-    /**
-     * Changes and refreshes the Application UI node handled by the sub parts.
-     */
-    public void refreshUiApplicationNode() {
-        UiElementNode appUiNode = getUiApplicationNode();
-        if (mTooglePart != null) {
-            mTooglePart.setUiElementNode(appUiNode);
-        }
-        if (mAttrPart != null) {
-            mAttrPart.setUiElementNode(appUiNode);
-        }
-        if (mTreeBlock != null) {
-            mTreeBlock.changeRootAndDescriptors(appUiNode,
-                    null /* element filters */,
-                    true /* refresh */);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationToggle.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationToggle.java
deleted file mode 100644
index 139575d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/ApplicationToggle.java
+++ /dev/null
@@ -1,313 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.ui.UiElementPart;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener.UiUpdateState;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.w3c.dom.Text;
-
-/**
- * Appllication Toogle section part for application page.
- */
-final class ApplicationToggle extends UiElementPart {
-    
-    /** Checkbox indicating whether an application node is present */ 
-    private Button mCheckbox;
-    /** Listen to changes to the UI node for <application> and updates the checkbox */
-    private AppNodeUpdateListener mAppNodeUpdateListener;
-    /** Internal flag to know where we're programmatically modifying the checkbox and we want to
-     *  avoid triggering the checkbox's callback. */
-    public boolean mInternalModification;
-    private FormText mTooltipFormText;
-
-    public ApplicationToggle(Composite body, FormToolkit toolkit, ManifestEditor editor,
-            UiElementNode applicationUiNode) {
-        super(body, toolkit, editor, applicationUiNode,
-                "Application Toggle",
-                null, /* description */
-                Section.TWISTIE | Section.EXPANDED);
-    }
-    
-    @Override
-    public void dispose() {
-        super.dispose();
-        if (getUiElementNode() != null && mAppNodeUpdateListener != null) {
-            getUiElementNode().removeUpdateListener(mAppNodeUpdateListener);
-            mAppNodeUpdateListener = null;
-        }
-    }
-    
-    /**
-     * Changes and refreshes the Application UI node handle by the this part.
-     */
-    @Override
-    public void setUiElementNode(UiElementNode uiElementNode) {
-        super.setUiElementNode(uiElementNode);
-
-        updateTooltip();
-
-        // Set the state of the checkbox
-        mAppNodeUpdateListener.uiElementNodeUpdated(getUiElementNode(),
-                UiUpdateState.CHILDREN_CHANGED);
-    }
-
-    /**
-     * Create the controls to edit the attributes for the given ElementDescriptor.
-     * <p/>
-     * This MUST not be called by the constructor. Instead it must be called from
-     * <code>initialize</code> (i.e. right after the form part is added to the managed form.)
-     * 
-     * @param managedForm The owner managed form
-     */
-    @Override
-    protected void createFormControls(IManagedForm managedForm) {
-        FormToolkit toolkit = managedForm.getToolkit();
-        Composite table = createTableLayout(toolkit, 1 /* numColumns */);
-
-        mTooltipFormText = createFormText(table, toolkit, true, "<form></form>",
-                false /* setupLayoutData */);
-        updateTooltip();
-
-        mCheckbox = toolkit.createButton(table,
-                "Define an <application> tag in the AndroidManifest.xml",
-                SWT.CHECK);
-        mCheckbox.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP));
-        mCheckbox.setSelection(false);
-        mCheckbox.addSelectionListener(new CheckboxSelectionListener());
-
-        mAppNodeUpdateListener = new AppNodeUpdateListener();
-        getUiElementNode().addUpdateListener(mAppNodeUpdateListener);
-
-        // Initialize the state of the checkbox
-        mAppNodeUpdateListener.uiElementNodeUpdated(getUiElementNode(),
-                UiUpdateState.CHILDREN_CHANGED);
-        
-        // Tell the section that the layout has changed.
-        layoutChanged();
-    }
-
-    /**
-     * Updates the application tooltip in the form text.
-     * If there is no tooltip, the form text is hidden. 
-     */
-    private void updateTooltip() {
-        boolean isVisible = false;
-
-        String tooltip = getUiElementNode().getDescriptor().getTooltip();
-        if (tooltip != null) {
-            tooltip = DescriptorsUtils.formatFormText(tooltip,
-                    getUiElementNode().getDescriptor(),
-                    Sdk.getCurrent().getDocumentationBaseUrl());
-    
-            mTooltipFormText.setText(tooltip, true /* parseTags */, true /* expandURLs */);
-            mTooltipFormText.setImage(DescriptorsUtils.IMAGE_KEY, AdtPlugin.getAndroidLogo());
-            mTooltipFormText.addHyperlinkListener(getEditor().createHyperlinkListener());
-            isVisible = true;
-        }
-        
-        mTooltipFormText.setVisible(isVisible);
-    }
-
-    /**
-     * This listener synchronizes the XML application node when the checkbox
-     * is changed by the user.
-     */
-    private class CheckboxSelectionListener extends SelectionAdapter {
-        private Node mUndoXmlNode;
-        private Node mUndoXmlParent;
-        private Node mUndoXmlNextNode;
-        private Node mUndoXmlNextElement;
-        private Document mUndoXmlDocument;
-
-        @Override
-        public void widgetSelected(SelectionEvent e) {
-            super.widgetSelected(e);
-            if (!mInternalModification && getUiElementNode() != null) {
-                getUiElementNode().getEditor().wrapUndoRecording(
-                        mCheckbox.getSelection()
-                            ? "Create or restore Application node"
-                            : "Remove Application node",
-                        new Runnable() {
-                            public void run() {
-                                getUiElementNode().getEditor().editXmlModel(new Runnable() {
-                                    public void run() {
-                                        if (mCheckbox.getSelection()) {
-                                            // The user wants an <application> node.
-                                            // Either restore a previous one
-                                            // or create a full new one.
-                                            boolean create = true;
-                                            if (mUndoXmlNode != null) {
-                                                create = !restoreApplicationNode();
-                                            }
-                                            if (create) {
-                                                getUiElementNode().createXmlNode();
-                                            }
-                                        } else {
-                                            // Users no longer wants the <application> node.
-                                            removeApplicationNode();
-                                        }
-                                    }
-                                });
-                            }
-                });
-            }
-        }
-
-        /**
-         * Restore a previously "saved" application node.
-         * 
-         * @return True if the node could be restored, false otherwise.
-         */
-        private boolean restoreApplicationNode() {
-            if (mUndoXmlDocument == null || mUndoXmlNode == null) {
-                return false;
-            }
-
-            // Validate node references...
-            mUndoXmlParent = validateNode(mUndoXmlDocument, mUndoXmlParent);
-            mUndoXmlNextNode = validateNode(mUndoXmlDocument, mUndoXmlNextNode);
-            mUndoXmlNextElement = validateNode(mUndoXmlDocument, mUndoXmlNextElement);
-
-            if (mUndoXmlParent == null){
-                // If the parent node doesn't exist, try to find a new manifest node.
-                // If it doesn't exist, create it.
-                mUndoXmlParent = getUiElementNode().getUiParent().prepareCommit();
-                mUndoXmlNextNode = null;
-                mUndoXmlNextElement = null;
-            }
-
-            boolean success = false;
-            if (mUndoXmlParent != null) {
-                // If the parent is still around, reuse the same node.
-
-                // Ideally we want to insert the node before what used to be its next sibling.
-                // If that's not possible, we try to insert it before its next sibling element.
-                // If that's not possible either, it will be inserted at the end of the parent's.
-                Node next = mUndoXmlNextNode;
-                if (next == null) {
-                    next = mUndoXmlNextElement;
-                }
-                mUndoXmlParent.insertBefore(mUndoXmlNode, next);
-                if (next == null) {
-                    Text sep = mUndoXmlDocument.createTextNode("\n");  //$NON-NLS-1$
-                    mUndoXmlParent.insertBefore(sep, null);  // insert separator before end tag
-                }
-                success = true;
-            } 
-
-            // Remove internal references to avoid using them twice
-            mUndoXmlParent = null;
-            mUndoXmlNextNode = null;
-            mUndoXmlNextElement = null;
-            mUndoXmlNode = null;
-            mUndoXmlDocument = null;
-            return success;
-        }
-
-        /**
-         * Validates that the given xml_node is still either the root node or one of its
-         * direct descendants. 
-         * 
-         * @param root_node The root of the node hierarchy to examine.
-         * @param xml_node The XML node to find.
-         * @return Returns xml_node if it is, otherwise returns null.
-         */
-        private Node validateNode(Node root_node, Node xml_node) {
-            if (root_node == xml_node) {
-                return xml_node;
-            } else {
-                for (Node node = root_node.getFirstChild(); node != null;
-                        node = node.getNextSibling()) {
-                    if (root_node == xml_node || validateNode(node, xml_node) != null) {
-                        return xml_node;
-                    }
-                }
-            }
-            return null;
-        }
-
-        /**
-         * Removes the <application> node from the hierarchy.
-         * Before doing that, we try to remember where it was so that we can put it back
-         * in the same place.
-         */
-        private void removeApplicationNode() {
-            // Make sure the node actually exists...
-            Node xml_node = getUiElementNode().getXmlNode();
-            if (xml_node == null) {
-                return;
-            }
-
-            // Save its parent, next sibling and next element
-            mUndoXmlDocument = xml_node.getOwnerDocument();
-            mUndoXmlParent = xml_node.getParentNode();
-            mUndoXmlNextNode = xml_node.getNextSibling();
-            mUndoXmlNextElement = mUndoXmlNextNode;
-            while (mUndoXmlNextElement != null &&
-                    mUndoXmlNextElement.getNodeType() != Node.ELEMENT_NODE) {
-                mUndoXmlNextElement = mUndoXmlNextElement.getNextSibling();
-            }
-
-            // Actually remove the node from the hierarchy and keep it here.
-            // The returned node looses its parents/siblings pointers.
-            mUndoXmlNode = getUiElementNode().deleteXmlNode();
-        }
-    }
-
-    /**
-     * This listener synchronizes the UI (i.e. the checkbox) with the
-     * actual presence of the application XML node.
-     */
-    private class AppNodeUpdateListener implements IUiUpdateListener {        
-        public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-            // The UiElementNode for the application XML node always exists, even
-            // if there is no corresponding XML node in the XML file.
-            //
-            // To update the checkbox to reflect the actual state, we just need
-            // to check if the XML node is null.
-            try {
-                mInternalModification = true;
-                boolean exists = ui_node.getXmlNode() != null;
-                if (mCheckbox.getSelection() != exists) {
-                    mCheckbox.setSelection(exists);
-                }
-            } finally {
-                mInternalModification = false;
-            }
-            
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/InstrumentationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/InstrumentationPage.java
deleted file mode 100644
index 86d0dd1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/InstrumentationPage.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * Page for instrumentation settings, part of the AndroidManifest form editor.
- */
-public final class InstrumentationPage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "instrumentation_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    ManifestEditor mEditor;
-
-    private UiTreeBlock mTreeBlock;
-
-    public InstrumentationPage(ManifestEditor editor) {
-        super(editor, PAGE_ID, "Instrumentation");  // tab's label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Manifest Instrumentation");
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode manifest = mEditor.getUiRootNode();
-        AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-
-        ElementDescriptor[] descriptorFilters = null;
-        if (manifestDescriptor != null) {
-            descriptorFilters = new ElementDescriptor[] {
-                    manifestDescriptor.getInstrumentationElement(),
-            };
-        }
-
-        mTreeBlock = new UiTreeBlock(mEditor, manifest,
-                true /* autoCreateRoot */,
-                descriptorFilters,
-                "Instrumentation",
-                "List of instrumentations defined in the manifest");
-        mTreeBlock.createContent(managedForm);
-    }
-    
-    /**
-     * Changes and refreshes the Application UI node handled by the sub parts.
-     */
-    public void refreshUiNode() {
-        if (mTreeBlock != null) {
-            UiElementNode manifest = mEditor.getUiRootNode();
-            AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-
-            mTreeBlock.changeRootAndDescriptors(manifest,
-                    new ElementDescriptor[] {
-                        manifestDescriptor.getInstrumentationElement()
-                    },
-                    true /* refresh */);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewExportPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewExportPart.java
deleted file mode 100644
index 66af84c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewExportPart.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.common.project.ExportHelper;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.ui.SectionHelper.ManifestSectionPart;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.part.FileEditorInput;
-
-/**
- * Export section part for overview page.
- */
-final class OverviewExportPart extends ManifestSectionPart {
-
-    private final OverviewPage mOverviewPage;
-
-    public OverviewExportPart(OverviewPage overviewPage, Composite body, FormToolkit toolkit, ManifestEditor editor) {
-        super(body, toolkit, Section.TWISTIE | Section.EXPANDED, true /* description */);
-        mOverviewPage = overviewPage;
-        Section section = getSection();
-        section.setText("Exporting");
-        section.setDescription("To export the application for distribution, you have the following options:");
-
-        Composite table = createTableLayout(toolkit, 2 /* numColumns */);
-        
-        StringBuffer buf = new StringBuffer();
-        buf.append("<form><li><a href=\"wizard\">"); //$NON-NLS-1$
-        buf.append("Use the Export Wizard");
-        buf.append("</a>"); //$NON-NLS-1$
-        buf.append(" to export and sign an APK");
-        buf.append("</li>"); //$NON-NLS-1$
-        buf.append("<li><a href=\"manual\">"); //$NON-NLS-1$
-        buf.append("Export an unsigned APK");
-        buf.append("</a>"); //$NON-NLS-1$
-        buf.append(" and sign it manually");
-        buf.append("</li></form>"); //$NON-NLS-1$
-
-        FormText text = createFormText(table, toolkit, true, buf.toString(),
-                false /* setupLayoutData */);
-        text.addHyperlinkListener(new HyperlinkAdapter() {
-            @Override
-            public void linkActivated(HyperlinkEvent e) {
-                // get the project from the editor
-                IEditorInput input = mOverviewPage.mEditor.getEditorInput();
-                if (input instanceof FileEditorInput) {
-                    FileEditorInput fileInput = (FileEditorInput)input;
-                    IFile file = fileInput.getFile();
-                    IProject project = file.getProject();
-                    
-                    if ("manual".equals(e.data)) { //$NON-NLS-1$
-                        // now we can export an unsigned apk for the project.
-                        ExportHelper.exportProject(project);
-                    } else {
-                        // call the export wizard
-                        ExportHelper.startExportWizard(project);
-                    }
-                }
-            }
-        });
-        
-        layoutChanged();
-    }        
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewInfoPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewInfoPart.java
deleted file mode 100644
index 026b760..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewInfoPart.java
+++ /dev/null
@@ -1,222 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.UiElementPart;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-import org.w3c.dom.Node;
-
-/**
- * Generic info section part for overview page
- */
-final class OverviewInfoPart extends UiElementPart {
-
-    private IManagedForm mManagedForm;
-
-    public OverviewInfoPart(Composite body, FormToolkit toolkit, ManifestEditor editor) {
-        super(body, toolkit, editor,
-                null,  // uiElementNode
-                "General Information", // section title
-                "Defines general information about the AndroidManifest.xml", // section description
-                Section.TWISTIE | Section.EXPANDED);
-    }
-
-    /**
-     * Retrieves the UiElementNode that this part will edit. The node must exist
-     * and can't be null, by design, because it's a mandatory node.
-     */
-    private static UiElementNode getManifestUiNode(ManifestEditor editor) {
-        AndroidManifestDescriptors manifestDescriptors = editor.getManifestDescriptors();
-        if (manifestDescriptors != null) {
-            ElementDescriptor desc = manifestDescriptors.getManifestElement();
-            if (editor.getUiRootNode().getDescriptor() == desc) {
-                return editor.getUiRootNode();
-            } else {
-                return editor.getUiRootNode().findUiChildNode(desc.getXmlName());
-            }
-        }
-        
-        // No manifest descriptor: we have a dummy UiRootNode, so we return that.
-        // The editor will be reloaded once we have the proper descriptors anyway.
-        return editor.getUiRootNode();
-    }
-
-    /**
-     * Retrieves the uses-sdk UI node. Since this is a mandatory node, it *always*
-     * exists, even if there is no matching XML node.
-     */
-    private UiElementNode getUsesSdkUiNode(ManifestEditor editor) {
-        AndroidManifestDescriptors manifestDescriptors = editor.getManifestDescriptors();
-        if (manifestDescriptors != null) {
-            ElementDescriptor desc = manifestDescriptors.getUsesSdkElement();
-            return editor.getUiRootNode().findUiChildNode(desc.getXmlName());
-        }
-        
-        // No manifest descriptor: we have a dummy UiRootNode, so we return that.
-        // The editor will be reloaded once we have the proper descriptors anyway.
-        return editor.getUiRootNode();
-    }
-
-    /**
-     * Overridden in order to capture the current managed form.
-     * 
-     * {@inheritDoc}
-     */
-    @Override
-    protected void createFormControls(final IManagedForm managedForm) {
-        mManagedForm = managedForm; 
-        super.createFormControls(managedForm);
-    }
-
-    /**
-     * Removes any existing Attribute UI widgets and recreate them if the SDK has changed.
-     * <p/>
-     * This is called by {@link OverviewPage#refreshUiApplicationNode()} when the
-     * SDK has changed.
-     */
-    public void onSdkChanged() {
-        createUiAttributes(mManagedForm);
-    }
-    
-    /**
-     * Overridden to add the description and the ui attributes of both the
-     * manifest and uses-sdk UI nodes.
-     * <p/>
-     * {@inheritDoc}
-     */
-    @Override
-    protected void fillTable(Composite table, IManagedForm managedForm) {
-        int n = 0;
-
-        UiElementNode uiNode = getManifestUiNode(getEditor());
-        n += insertUiAttributes(uiNode, table, managedForm);
-
-        uiNode = getUsesSdkUiNode(getEditor());
-        n += insertUiAttributes(uiNode, table, managedForm);
-
-        if (n == 0) {
-            createLabel(table, managedForm.getToolkit(),
-                    "No attributes to display, waiting for SDK to finish loading...",
-                    null /* tooltip */ );
-        }
-        
-        layoutChanged();
-    }
-
-    /**
-     * Overridden to tests whether either the manifest or uses-sdk nodes parts are dirty.
-     * <p/>
-     * {@inheritDoc}
-     * 
-     * @return <code>true</code> if the part is dirty, <code>false</code>
-     *         otherwise.
-     */
-    @Override
-    public boolean isDirty() {
-        boolean dirty = super.isDirty();
-        
-        if (!dirty) {
-            UiElementNode uiNode = getManifestUiNode(getEditor());
-            if (uiNode != null) {
-                for (UiAttributeNode ui_attr : uiNode.getUiAttributes()) {
-                    if (ui_attr.isDirty()) {
-                        markDirty();
-                        dirty = true;
-                        break;
-                    }
-                }
-            }
-        }
-
-        if (!dirty) {
-            UiElementNode uiNode = getUsesSdkUiNode(getEditor());
-            if (uiNode != null) {
-                for (UiAttributeNode ui_attr : uiNode.getUiAttributes()) {
-                    if (ui_attr.isDirty()) {
-                        markDirty();
-                        dirty = true;
-                        break;
-                    }
-                }
-            }
-        }
-
-        return dirty;
-    }
-    
-    /**
-     * Overridden to save both the manifest or uses-sdk nodes.
-     * <p/>
-     * {@inheritDoc}
-     */
-    @Override
-    public void commit(boolean onSave) {
-        final UiElementNode manifestUiNode = getManifestUiNode(getEditor());
-        final UiElementNode usesSdkUiNode = getUsesSdkUiNode(getEditor());
-
-        getEditor().editXmlModel(new Runnable() {
-            public void run() {
-                if (manifestUiNode != null && manifestUiNode.isDirty()) {
-                    for (UiAttributeNode ui_attr : manifestUiNode.getUiAttributes()) {
-                        ui_attr.commit();
-                    }
-                }
-
-                if (usesSdkUiNode != null && usesSdkUiNode.isDirty()) {
-                    for (UiAttributeNode ui_attr : usesSdkUiNode.getUiAttributes()) {
-                        ui_attr.commit();
-                    }
-
-                    if (!usesSdkUiNode.isDirty()) {
-                        // Remove the <uses-sdk> XML element if it is empty.
-                        // Rather than rely on the internal UI state, actually check that the
-                        // XML element has no attributes and no child element so that we don't
-                        // trash some user-generated content.
-                        Node element = usesSdkUiNode.prepareCommit();
-                        if (element != null &&
-                                !element.hasAttributes() &&
-                                !element.hasChildNodes()) {
-                            // Important note: we MUST NOT use usesSdkUiNode.deleteXmlNode()
-                            // here, as it would clear the UiAttribute list and thus break the
-                            // link between the controls and the ui attribute field.
-                            // Instead what we want is simply to remove the XML node and let the
-                            // UiElementNode node know.
-                            Node parent = element.getParentNode();
-                            if (parent != null) {
-                                parent.removeChild(element);
-                                usesSdkUiNode.loadFromXmlNode(null /*xml_node*/);
-                            }
-                        }
-                    }
-                }
-            }
-        });
-
-        // We need to call super's commit after we synchronized the nodes to make sure we
-        // reset the dirty flag after all the side effects from committing have occurred.
-        super.commit(onSave);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewLinksPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewLinksPart.java
deleted file mode 100644
index d637a8f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewLinksPart.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.SectionHelper.ManifestSectionPart;
-
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-/**
- * Links section part for overview page.
- */
-final class OverviewLinksPart extends ManifestSectionPart {
-
-    private final ManifestEditor mEditor;
-    private FormText mFormText;
-
-    public OverviewLinksPart(Composite body, FormToolkit toolkit, ManifestEditor editor) {
-        super(body, toolkit, Section.TWISTIE | Section.EXPANDED, true /* description */);
-        mEditor = editor;
-        Section section = getSection();
-        section.setText("Links");
-        section.setDescription("The content of the Android Manifest is made up of three sections. You can also edit the XML directly.");
-
-        Composite table = createTableLayout(toolkit, 2 /* numColumns */);
-        
-        StringBuffer buf = new StringBuffer();
-        buf.append(String.format("<form><li style=\"image\" value=\"app_img\"><a href=\"page:%1$s\">", // $NON-NLS-1$
-                ApplicationPage.PAGE_ID));
-        buf.append("Application");
-        buf.append("</a>");  //$NON-NLS-1$
-        buf.append(": Activities, intent filters, providers, services and receivers.");
-        buf.append("</li>"); //$NON-NLS-1$
-
-        buf.append(String.format("<li style=\"image\" value=\"perm_img\"><a href=\"page:%1$s\">", // $NON-NLS-1$
-                PermissionPage.PAGE_ID));
-        buf.append("Permission");
-        buf.append("</a>"); //$NON-NLS-1$
-        buf.append(": Permissions defined and permissions used.");
-        buf.append("</li>"); //$NON-NLS-1$
-
-        buf.append(String.format("<li style=\"image\" value=\"inst_img\"><a href=\"page:%1$s\">", // $NON-NLS-1$
-                InstrumentationPage.PAGE_ID));
-        buf.append("Instrumentation");
-        buf.append("</a>"); //$NON-NLS-1$
-        buf.append(": Instrumentation defined.");
-        buf.append("</li>"); //$NON-NLS-1$
-
-        buf.append(String.format("<li style=\"image\" value=\"android_img\"><a href=\"page:%1$s\">", // $NON-NLS-1$
-                ManifestEditor.TEXT_EDITOR_ID));
-        buf.append("XML Source");
-        buf.append("</a>"); //$NON-NLS-1$
-        buf.append(": Directly edit the AndroidManifest.xml file.");
-        buf.append("</li>"); //$NON-NLS-1$
-
-        buf.append("<li style=\"image\" value=\"android_img\">"); // $NON-NLS-1$
-        buf.append("<a href=\"http://code.google.com/android/devel/bblocks-manifest.html\">Documentation</a>: Documentation from the Android SDK for AndroidManifest.xml."); // $NON-NLS-1$
-        buf.append("</li>"); //$NON-NLS-1$
-        buf.append("</form>"); //$NON-NLS-1$
-
-        mFormText = createFormText(table, toolkit, true, buf.toString(),
-                false /* setupLayoutData */);
-        
-        AndroidManifestDescriptors manifestDescriptor = editor.getManifestDescriptors();
-
-        Image androidLogo = AdtPlugin.getAndroidLogo();
-        mFormText.setImage("android_img", androidLogo); //$NON-NLS-1$
-        
-        if (manifestDescriptor != null) {
-            mFormText.setImage("app_img", getIcon(manifestDescriptor.getApplicationElement())); //$NON-NLS-1$
-            mFormText.setImage("perm_img", getIcon(manifestDescriptor.getPermissionElement())); //$NON-NLS-1$
-            mFormText.setImage("inst_img", getIcon(manifestDescriptor.getInstrumentationElement())); //$NON-NLS-1$
-        } else {
-            mFormText.setImage("app_img", androidLogo); //$NON-NLS-1$
-            mFormText.setImage("perm_img", androidLogo); //$NON-NLS-1$
-            mFormText.setImage("inst_img", androidLogo); //$NON-NLS-1$
-        }
-        mFormText.addHyperlinkListener(editor.createHyperlinkListener());
-    }
-    
-    /**
-     * Update the UI with information from the new descriptors.
-     * <p/>At this point, this only refreshes the icons.
-     * <p/>
-     * This is called by {@link OverviewPage#refreshUiApplicationNode()} when the
-     * SDK has changed.
-     */
-    public void onSdkChanged() {
-        AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-        if (manifestDescriptor != null) {
-            mFormText.setImage("app_img", getIcon(manifestDescriptor.getApplicationElement())); //$NON-NLS-1$
-            mFormText.setImage("perm_img", getIcon(manifestDescriptor.getPermissionElement())); //$NON-NLS-1$
-            mFormText.setImage("inst_img", getIcon(manifestDescriptor.getInstrumentationElement())); //$NON-NLS-1$
-        }
-    }
-    
-    private Image getIcon(ElementDescriptor desc) {
-        if (desc != null && desc.getIcon() != null) {
-            return desc.getIcon();
-        }
-        
-        return AdtPlugin.getAndroidLogo();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewPage.java
deleted file mode 100644
index 62954bd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/OverviewPage.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ColumnLayout;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-
-/**
- * Page for overview settings, part of the AndroidManifest form editor.
- * <p/>
- * Useful reference:
- * <a href="http://www.eclipse.org/articles/Article-Forms/article.html">
- *   http://www.eclipse.org/articles/Article-Forms/article.html</a>
- */
-public final class OverviewPage extends FormPage {
-
-    /** Page id used for switching tabs programmatically */
-    final static String PAGE_ID = "overview_page"; //$NON-NLS-1$
-    
-    /** Container editor */
-    ManifestEditor mEditor;
-    /** Overview part (attributes for manifest) */
-    private OverviewInfoPart mOverviewPart;
-    /** Overview link part */
-    private OverviewLinksPart mOverviewLinkPart;
-    
-    public OverviewPage(ManifestEditor editor) {
-        super(editor, PAGE_ID, "Overview");  // tab's label, user visible, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Manifest Overview");
-        form.setImage(AdtPlugin.getAndroidLogo());
-        
-        Composite body = form.getBody();
-        FormToolkit toolkit = managedForm.getToolkit();
-        ColumnLayout cl = new ColumnLayout();
-        cl.minNumColumns = cl.maxNumColumns = 1;
-        body.setLayout(cl);
-        mOverviewPart = new OverviewInfoPart(body, toolkit, mEditor);
-        managedForm.addPart(mOverviewPart);
-        managedForm.addPart(new OverviewExportPart(this, body, toolkit, mEditor));
-        mOverviewLinkPart = new OverviewLinksPart(body, toolkit, mEditor);
-        managedForm.addPart(mOverviewLinkPart);
-    }
-
-    /**
-     * Changes and refreshes the Application UI node handle by the sub parts.
-     */
-    public void refreshUiApplicationNode() {
-        if (mOverviewPart != null) {
-            mOverviewPart.onSdkChanged();
-        }
-        
-        if (mOverviewLinkPart != null) {
-            mOverviewLinkPart.onSdkChanged();
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/PermissionPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/PermissionPage.java
deleted file mode 100644
index 41ba22e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/manifest/pages/PermissionPage.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.pages;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * Page for permissions settings, part of the AndroidManifest form editor.
- * <p/>
- * Useful reference:
- * <a href="http://www.eclipse.org/articles/Article-Forms/article.html">
- *   http://www.eclipse.org/articles/Article-Forms/article.html</a>
- */
-public final class PermissionPage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "permission_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    ManifestEditor mEditor;
-
-    private UiTreeBlock mTreeBlock;
-
-    public PermissionPage(ManifestEditor editor) {
-        super(editor, PAGE_ID, "Permissions");  // tab label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Manifest Permissions");
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode manifest = mEditor.getUiRootNode();
-        AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-        
-        ElementDescriptor[] descriptorFilters = null;
-        if (manifestDescriptor != null) {
-            descriptorFilters = new ElementDescriptor[] {
-                    manifestDescriptor.getPermissionElement(),
-                    manifestDescriptor.getUsesPermissionElement(),
-                    manifestDescriptor.getPermissionGroupElement(),
-                    manifestDescriptor.getPermissionTreeElement()
-            };
-        }
-        mTreeBlock = new UiTreeBlock(mEditor, manifest,
-                true /* autoCreateRoot */,
-                descriptorFilters,
-                "Permissions",
-                "List of permissions defined and used by the manifest");
-        mTreeBlock.createContent(managedForm);
-    }
-
-    /**
-     * Changes and refreshes the Application UI node handled by the sub parts.
-     */
-    public void refreshUiNode() {
-        if (mTreeBlock != null) {
-            UiElementNode manifest = mEditor.getUiRootNode();
-            AndroidManifestDescriptors manifestDescriptor = mEditor.getManifestDescriptors();
-
-            mTreeBlock.changeRootAndDescriptors(manifest,
-                    new ElementDescriptor[] {
-                        manifestDescriptor.getPermissionElement(),
-                        manifestDescriptor.getUsesPermissionElement(),
-                        manifestDescriptor.getPermissionGroupElement(),
-                        manifestDescriptor.getPermissionTreeElement()
-                    },
-                    true /* refresh */);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuContentAssist.java
deleted file mode 100644
index bf76d53..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuContentAssist.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.menu;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidContentAssist;
-
-/**
- * Content Assist Processor for /res/menu XML files
- */
-class MenuContentAssist extends AndroidContentAssist {
-
-    /**
-     * Constructor for LayoutContentAssist 
-     */
-    public MenuContentAssist() {
-        super(AndroidTargetData.DESCRIPTOR_MENU);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuEditor.java
deleted file mode 100644
index cff1746..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuEditor.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.menu;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidXPathFactory;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathConstants;
-import javax.xml.xpath.XPathExpressionException;
-
-/**
- * Multi-page form editor for /res/menu XML files. 
- */
-public class MenuEditor extends AndroidEditor {
-
-    public static final String ID = AndroidConstants.EDITORS_NAMESPACE + ".menu.MenuEditor"; //$NON-NLS-1$
-
-    /** Root node of the UI element hierarchy */
-    private UiElementNode mUiRootNode;
-
-    /**
-     * Creates the form editor for resources XML files.
-     */
-    public MenuEditor() {
-        super();
-    }
-
-    /**
-     * Returns the root node of the UI element hierarchy, which here is
-     * the "menu" node.
-     */
-    @Override
-    public UiElementNode getUiRootNode() {
-        return mUiRootNode;
-    }
-
-    // ---- Base Class Overrides ----
-
-    /**
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p/>
-     * Save-As is a valid operation for the ManifestEditor since it acts on a
-     * single source file. 
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return true;
-    }
-
-    /**
-     * Create the various form pages.
-     */
-    @Override
-    protected void createFormPages() {
-        try {
-            addPage(new MenuTreePage(this));
-        } catch (PartInitException e) {
-            AdtPlugin.log(e, "Error creating nested page"); //$NON-NLS-1$
-        }
-        
-     }
-
-    /* (non-java doc)
-     * Change the tab/title name to include the project name.
-     */
-    @Override
-    protected void setInput(IEditorInput input) {
-        super.setInput(input);
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput) input;
-            IFile file = fileInput.getFile();
-            setPartName(String.format("%1$s", file.getName()));
-        }
-    }
-    
-    /**
-     * Processes the new XML Model, which XML root node is given.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    @Override
-    protected void xmlModelChanged(Document xml_doc) {
-        // init the ui root on demand
-        initUiRootNode(false /*force*/);
-
-        mUiRootNode.setXmlDocument(xml_doc);
-        if (xml_doc != null) {
-            ElementDescriptor root_desc = mUiRootNode.getDescriptor();
-            try {
-                XPath xpath = AndroidXPathFactory.newXPath();
-                Node node = (Node) xpath.evaluate("/" + root_desc.getXmlName(),  //$NON-NLS-1$
-                        xml_doc,
-                        XPathConstants.NODE);
-                if (node == null && root_desc.isMandatory()) {
-                    // Create the root element if it doesn't exist yet (for empty new documents)
-                    node = mUiRootNode.createXmlNode();
-                }
-
-                // Refresh the manifest UI node and all its descendants 
-                mUiRootNode.loadFromXmlNode(node);
-                
-                // TODO ? startMonitoringMarkers();
-            } catch (XPathExpressionException e) {
-                AdtPlugin.log(e, "XPath error when trying to find '%s' element in XML.", //$NON-NLS-1$
-                        root_desc.getXmlName());
-            }
-        }
-        
-        super.xmlModelChanged(xml_doc);
-    }
-    
-    /**
-     * Creates the initial UI Root Node, including the known mandatory elements.
-     * @param force if true, a new UiRootNode is recreated even if it already exists.
-     */
-    @Override
-    protected void initUiRootNode(boolean force) {
-        // The root UI node is always created, even if there's no corresponding XML node.
-        if (mUiRootNode == null || force) {
-            Document doc = null;
-            if (mUiRootNode != null) {
-                doc = mUiRootNode.getXmlDocument();
-            }
-            
-            // get the target data from the opened file (and its project)
-            AndroidTargetData data = getTargetData();
-
-            ElementDescriptor desc;
-            if (data == null) {
-                desc = new ElementDescriptor("temp", null /*children*/);
-            } else {
-                desc = data.getMenuDescriptors().getDescriptor();
-            }
-
-            mUiRootNode = desc.createUiNode();
-            mUiRootNode.setEditor(this);
-
-            onDescriptorsChanged(doc);
-        }
-    }
-
-    // ---- Local Methods ----
-
-    /**
-     * Reloads the UI manifest node from the XML, and calls the pages to update.
-     */
-    private void onDescriptorsChanged(Document document) {
-        if (document != null) {
-            mUiRootNode.loadFromXmlNode(document);
-        } else {
-            mUiRootNode.reloadFromXmlNode(mUiRootNode.getXmlNode());
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuSourceViewerConfig.java
deleted file mode 100644
index a5e3b09..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuSourceViewerConfig.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.menu;
-
-
-import com.android.ide.eclipse.editors.AndroidSourceViewerConfig;
-
-/**
- * Source Viewer Configuration that calls in MenuContentAssist.
- */
-public class MenuSourceViewerConfig extends AndroidSourceViewerConfig {
-
-    public MenuSourceViewerConfig() {
-        super(new MenuContentAssist());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuTreePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuTreePage.java
deleted file mode 100644
index edbfa5e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/MenuTreePage.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.menu;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * Page for the menu form editor.
- */
-public final class MenuTreePage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "layout_tree_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    MenuEditor mEditor;
-
-    public MenuTreePage(MenuEditor editor) {
-        super(editor, PAGE_ID, "Layout");  // tab's label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Menu");
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode rootNode = mEditor.getUiRootNode();
-        UiTreeBlock block = new UiTreeBlock(mEditor, rootNode,
-                true /* autoCreateRoot */,
-                null /* no element filters */,
-                "Menu Elements",
-                "List of all menu elements in this XML file.");
-        block.createContent(managedForm);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/descriptors/MenuDescriptors.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/descriptors/MenuDescriptors.java
deleted file mode 100644
index 40a8f16..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/menu/descriptors/MenuDescriptors.java
+++ /dev/null
@@ -1,196 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.menu.descriptors;
-
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.sdklib.SdkConstants;
-
-import java.util.ArrayList;
-import java.util.Map;
-
-
-/**
- * Complete description of the menu structure.
- */
-public final class MenuDescriptors implements IDescriptorProvider {
-
-    public static final String MENU_ROOT_ELEMENT = "menu"; //$NON-NLS-1$
-
-    /** The root element descriptor. */
-    private ElementDescriptor mDescriptor = null;
-
-    /** @return the root descriptor. */
-    public ElementDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-    
-    public ElementDescriptor[] getRootElementDescriptors() {
-        return mDescriptor.getChildren();
-    }
-    
-    /**
-     * Updates the document descriptor.
-     * <p/>
-     * It first computes the new children of the descriptor and then updates them
-     * all at once.
-     * 
-     * @param styleMap The map style => attributes from the attrs.xml file
-     */
-    public synchronized void updateDescriptors(Map<String, DeclareStyleableInfo> styleMap) {
-
-        // There are 3 elements: menu, item and group.
-        // The root element MUST be a menu.
-        // A top menu can contain items or group:
-        //  - top groups can contain top items
-        //  - top items can contain sub-menus
-        // A sub menu can contains sub items or sub groups:
-        //  - sub groups can contain sub items
-        //  - sub items cannot contain anything
-        
-        if (mDescriptor == null) {
-            mDescriptor = createElement(styleMap,
-                MENU_ROOT_ELEMENT, // xmlName
-                "Menu", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                null, // childrenElements,
-                true /* mandatory */);
-        }
-
-        // -- sub menu can have sub_items, sub_groups but not sub_menus
-
-        ElementDescriptor sub_item = createElement(styleMap,
-                "item", // xmlName //$NON-NLS-1$
-                "Item", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                null, // childrenElements,
-                false /* mandatory */);
-
-        ElementDescriptor sub_group = createElement(styleMap,
-                "group", // xmlName //$NON-NLS-1$
-                "Group", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                new ElementDescriptor[] { sub_item }, // childrenElements,
-                false /* mandatory */);
-
-        ElementDescriptor sub_menu = createElement(styleMap,
-                MENU_ROOT_ELEMENT, // xmlName //$NON-NLS-1$
-                "Sub-Menu", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                new ElementDescriptor[] { sub_item, sub_group }, // childrenElements,
-                true /* mandatory */);
-
-        // -- top menu can have all top groups and top items (which can have sub menus)
-
-        ElementDescriptor top_item = createElement(styleMap,
-                "item", // xmlName //$NON-NLS-1$
-                "Item", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                new ElementDescriptor[] { sub_menu }, // childrenElements,
-                false /* mandatory */);
-
-        ElementDescriptor top_group = createElement(styleMap,
-                "group", // xmlName //$NON-NLS-1$
-                "Group", // uiName,
-                null, // TODO SDK URL
-                null, // extraAttribute
-                new ElementDescriptor[] { top_item }, // childrenElements,
-                false /* mandatory */);
-
-        XmlnsAttributeDescriptor xmlns = new XmlnsAttributeDescriptor("android", //$NON-NLS-1$
-                SdkConstants.NS_RESOURCES); 
-
-        updateElement(mDescriptor, styleMap, "Menu", xmlns); //$NON-NLS-1$
-        mDescriptor.setChildren(new ElementDescriptor[] { top_item, top_group });
-    }
-
-    /**
-     * Returns a new ElementDescriptor constructed from the information given here
-     * and the javadoc & attributes extracted from the style map if any.
-     */
-    private ElementDescriptor createElement(
-            Map<String, DeclareStyleableInfo> styleMap, 
-            String xmlName, String uiName, String sdkUrl,
-            AttributeDescriptor extraAttribute,
-            ElementDescriptor[] childrenElements, boolean mandatory) {
-
-        ElementDescriptor element = new ElementDescriptor(xmlName, uiName, null, sdkUrl,
-                null, childrenElements, mandatory);
-
-        return updateElement(element, styleMap,
-                getStyleName(xmlName),
-                extraAttribute);
-    }
-    
-    /**
-     * Updates an ElementDescriptor with the javadoc & attributes extracted from the style
-     * map if any.
-     */
-    private ElementDescriptor updateElement(ElementDescriptor element,
-            Map<String, DeclareStyleableInfo> styleMap,
-            String styleName,
-            AttributeDescriptor extraAttribute) {
-        ArrayList<AttributeDescriptor> descs = new ArrayList<AttributeDescriptor>();
-
-        DeclareStyleableInfo style = styleMap != null ? styleMap.get(styleName) : null;
-        if (style != null) {
-            DescriptorsUtils.appendAttributes(descs,
-                    null,   // elementName
-                    SdkConstants.NS_RESOURCES,
-                    style.getAttributes(),
-                    null,   // requiredAttributes
-                    null);  // overrides
-            element.setTooltip(style.getJavaDoc());
-        }
-
-        if (extraAttribute != null) {
-            descs.add(extraAttribute);
-        }
-
-        element.setAttributes(descs.toArray(new AttributeDescriptor[descs.size()]));
-        return element;
-    }
-
-    /**
-     * Returns the style name (i.e. the <declare-styleable> name found in attrs.xml)
-     * for a given XML element name.
-     * <p/>
-     * The rule is that all elements have for style name:
-     * - their xml name capitalized
-     * - a "Menu" prefix, except for <menu> itself which is just "Menu".
-     */
-    private String getStyleName(String xmlName) {
-        String styleName = DescriptorsUtils.capitalize(xmlName);
-
-        // This is NOT the UI Name but the expected internal style name
-        final String MENU_STYLE_BASE_NAME = "Menu"; //$NON-NLS-1$
-        
-        if (!styleName.equals(MENU_STYLE_BASE_NAME)) {        
-            styleName = MENU_STYLE_BASE_NAME + styleName;
-        }
-        return styleName;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesContentAssist.java
deleted file mode 100644
index c9c8e17..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesContentAssist.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidContentAssist;
-
-/**
- * Content Assist Processor for /res/values and /res/drawable XML files
- */
-class ResourcesContentAssist extends AndroidContentAssist {
-
-    /**
-     * Constructor for ResourcesContentAssist 
-     */
-    public ResourcesContentAssist() {
-        super(AndroidTargetData.DESCRIPTOR_RESOURCES);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesEditor.java
deleted file mode 100644
index 46a9112..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesEditor.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidXPathFactory;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.resources.descriptors.ResourcesDescriptors;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathConstants;
-import javax.xml.xpath.XPathExpressionException;
-
-/**
- * Multi-page form editor for /res/values and /res/drawable XML files. 
- */
-public class ResourcesEditor extends AndroidEditor {
-
-    public static final String ID = AndroidConstants.EDITORS_NAMESPACE + ".resources.ResourcesEditor"; //$NON-NLS-1$
-
-    /** Root node of the UI element hierarchy */
-    private UiElementNode mUiResourcesNode;
-
-
-    /**
-     * Creates the form editor for resources XML files.
-     */
-    public ResourcesEditor() {
-        super();
-    }
-
-    /**
-     * Returns the root node of the UI element hierarchy, which
-     * here is the "resources" node.
-     */
-    @Override
-    public UiElementNode getUiRootNode() {
-        return mUiResourcesNode;
-    }
-    
-    // ---- Base Class Overrides ----
-
-    /**
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p/>
-     * Save-As is a valid operation for the ManifestEditor since it acts on a
-     * single source file. 
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return true;
-    }
-
-    /**
-     * Create the various form pages.
-     */
-    @Override
-    protected void createFormPages() {
-        try {
-            addPage(new ResourcesTreePage(this));
-        } catch (PartInitException e) {
-            AdtPlugin.log(IStatus.ERROR, "Error creating nested page"); //$NON-NLS-1$
-            AdtPlugin.getDefault().getLog().log(e.getStatus());
-        }
-     }
-
-    /* (non-java doc)
-     * Change the tab/title name to include the project name.
-     */
-    @Override
-    protected void setInput(IEditorInput input) {
-        super.setInput(input);
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput) input;
-            IFile file = fileInput.getFile();
-            setPartName(String.format("%1$s",
-                    file.getName()));
-        }
-    }
-    
-    /**
-     * Processes the new XML Model, which XML root node is given.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    @Override
-    protected void xmlModelChanged(Document xml_doc) {
-        // init the ui root on demand
-        initUiRootNode(false /*force*/);
-
-        mUiResourcesNode.setXmlDocument(xml_doc);
-        if (xml_doc != null) {
-            ElementDescriptor resources_desc =
-                    ResourcesDescriptors.getInstance().getElementDescriptor();
-            try {
-                XPath xpath = AndroidXPathFactory.newXPath();
-                Node node = (Node) xpath.evaluate("/" + resources_desc.getXmlName(),  //$NON-NLS-1$
-                        xml_doc,
-                        XPathConstants.NODE);
-                assert node != null && node.getNodeName().equals(resources_desc.getXmlName());
-
-                // Refresh the manifest UI node and all its descendants 
-                mUiResourcesNode.loadFromXmlNode(node);
-            } catch (XPathExpressionException e) {
-                AdtPlugin.log(e, "XPath error when trying to find '%s' element in XML.", //$NON-NLS-1$
-                        resources_desc.getXmlName());
-            }
-        }
-        
-        super.xmlModelChanged(xml_doc);
-    }
-    
-    /**
-     * Creates the initial UI Root Node, including the known mandatory elements.
-     * @param force if true, a new UiRootNode is recreated even if it already exists.
-     */
-    @Override
-    protected void initUiRootNode(boolean force) {
-        // The manifest UI node is always created, even if there's no corresponding XML node.
-        if (mUiResourcesNode == null || force) {
-            ElementDescriptor resources_desc =
-                    ResourcesDescriptors.getInstance().getElementDescriptor();   
-            mUiResourcesNode = resources_desc.createUiNode();
-            mUiResourcesNode.setEditor(this);
-            
-            onDescriptorsChanged();
-        }
-    }
-
-    // ---- Local Methods ----
-
-    private void onDescriptorsChanged() {
-        // nothing to be done, as the descriptor are static for now.
-        // FIXME Update when the descriptors are not static
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesSourceViewerConfig.java
deleted file mode 100644
index 1804312..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesSourceViewerConfig.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources;
-
-
-import com.android.ide.eclipse.editors.AndroidSourceViewerConfig;
-
-/**
- * Source Viewer Configuration that calls in ResourcesContentAssist.
- */
-public class ResourcesSourceViewerConfig extends AndroidSourceViewerConfig {
-
-    public ResourcesSourceViewerConfig() {
-        super(new ResourcesContentAssist());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesTreePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesTreePage.java
deleted file mode 100644
index 5c1b0e1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/ResourcesTreePage.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolder;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.part.FileEditorInput;
-
-/**
- * Page for instrumentation settings, part of the AndroidManifest form editor.
- */
-public final class ResourcesTreePage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "res_tree_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    ResourcesEditor mEditor;
-
-    public ResourcesTreePage(ResourcesEditor editor) {
-        super(editor, PAGE_ID, "Resources");  // tab's label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        
-        String configText = null;
-        IEditorInput input = mEditor.getEditorInput();
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput)input;
-            IFile iFile = fileInput.getFile();
-            
-            ResourceFolder resFolder = ResourceManager.getInstance().getResourceFolder(iFile);
-            if (resFolder != null) {
-                configText = resFolder.getConfiguration().toDisplayString();
-            }
-        }
-        
-        if (configText != null) {
-            form.setText(String.format("Android Resources (%1$s)", configText));
-        } else {
-            form.setText("Android Resources");
-        }
-
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode resources = mEditor.getUiRootNode();
-        UiTreeBlock block = new UiTreeBlock(mEditor, resources,
-                true /* autoCreateRoot */,
-                null /* no element filters */,
-                "Resources Elements",
-                "List of all resources elements in this XML file.");
-        block.createContent(managedForm);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifier.java
deleted file mode 100644
index 9a61d17..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifier.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Mobile Country Code.
- */
-public final class CountryCodeQualifier extends ResourceQualifier {
-    /** Default pixel density value. This means the property is not set. */
-    private final static int DEFAULT_CODE = -1;
-
-    private final static Pattern sCountryCodePattern = Pattern.compile("^mcc(\\d{3})$");//$NON-NLS-1$
-
-    private int mCode = DEFAULT_CODE;
-    
-    public static final String NAME = "Mobile Country Code";
-    
-    /**
-     * Creates and returns a qualifier from the given folder segment. If the segment is incorrect,
-     * <code>null</code> is returned.
-     * @param segment the folder segment from which to create a qualifier.
-     * @return a new {@link CountryCodeQualifier} object or <code>null</code>
-     */
-    public static CountryCodeQualifier getQualifier(String segment) {
-        Matcher m = sCountryCodePattern.matcher(segment);
-        if (m.matches()) {
-            String v = m.group(1);
-
-            int code = -1;
-            try {
-                code = Integer.parseInt(v);
-            } catch (NumberFormatException e) {
-                // looks like the string we extracted wasn't a valid number.
-                return null;
-            }
-            
-            CountryCodeQualifier qualifier = new CountryCodeQualifier();
-            qualifier.mCode = code;
-            return qualifier;
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the folder name segment for the given value. This is equivalent to calling
-     * {@link #toString()} on a {@link CountryCodeQualifier} object.
-     * @param code the value of the qualifier, as returned by {@link #getCode()}.
-     */
-    public static String getFolderSegment(int code) {
-        if (code != DEFAULT_CODE && code >= 100 && code <=999) { // code is 3 digit.) {
-            return String.format("mcc%1$d", code); //$NON-NLS-1$
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-    
-    public int getCode() {
-        return mCode;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Country Code";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("mcc"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mCode != DEFAULT_CODE;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        CountryCodeQualifier qualifier = getQualifier(value);
-        if (qualifier != null) {
-            config.setCountryCodeQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof CountryCodeQualifier) {
-            return mCode == ((CountryCodeQualifier)qualifier).mCode;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public int hashCode() {
-        return mCode;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        return getFolderSegment(mCode);
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mCode != DEFAULT_CODE) {
-            return String.format("MCC %1$d", mCode);
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/FolderConfiguration.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/FolderConfiguration.java
deleted file mode 100644
index 3c3e11f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/FolderConfiguration.java
+++ /dev/null
@@ -1,499 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-
-
-/**
- * Represents the configuration for Resource Folders. All the properties have a default
- * value which means that the property is not set.
- */
-public final class FolderConfiguration implements Comparable<FolderConfiguration> {
-    public final static String QUALIFIER_SEP = "-"; //$NON-NLS-1$
-
-    private final ResourceQualifier[] mQualifiers = new ResourceQualifier[INDEX_COUNT];
-    
-    private final static int INDEX_COUNTRY_CODE = 0;
-    private final static int INDEX_NETWORK_CODE = 1;
-    private final static int INDEX_LANGUAGE = 2;
-    private final static int INDEX_REGION = 3;
-    private final static int INDEX_SCREEN_ORIENTATION = 4;
-    private final static int INDEX_PIXEL_DENSITY = 5;
-    private final static int INDEX_TOUCH_TYPE = 6;
-    private final static int INDEX_KEYBOARD_STATE = 7;
-    private final static int INDEX_TEXT_INPUT_METHOD = 8;
-    private final static int INDEX_NAVIGATION_METHOD = 9;
-    private final static int INDEX_SCREEN_DIMENSION = 10;
-    private final static int INDEX_COUNT = 11;
-    
-    /**
-     * Sets the config from the qualifiers of a given <var>config</var>.
-     * @param config
-     */
-    public void set(FolderConfiguration config) {
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            mQualifiers[i] = config.mQualifiers[i];
-        }
-    }
-
-    /**
-     * Removes the qualifiers from the receiver if they are present (and valid)
-     * in the given configuration.
-     */
-    public void substract(FolderConfiguration config) {
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            if (config.mQualifiers[i] != null && config.mQualifiers[i].isValid()) {
-                mQualifiers[i] = null;
-            }
-        }
-    }
-    
-    /**
-     * Returns the first invalid qualifier, or <code>null<code> if they are all valid (or if none
-     * exists).
-     */
-    public ResourceQualifier getInvalidQualifier() {
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            if (mQualifiers[i] != null && mQualifiers[i].isValid() == false) {
-                return mQualifiers[i];
-            }
-        }
-        
-        // all allocated qualifiers are valid, we return null.
-        return null;
-    }
-    
-    /**
-     * Returns whether the Region qualifier is valid. Region qualifier can only be present if a
-     * Language qualifier is present as well.
-     * @return true if the Region qualifier is valid.
-     */
-    public boolean checkRegion() {
-        if (mQualifiers[INDEX_LANGUAGE] == null && mQualifiers[INDEX_REGION] != null) {
-            return false;
-        }
-
-        return true;
-    }
-    
-    /**
-     * Adds a qualifier to the {@link FolderConfiguration}
-     * @param qualifier the {@link ResourceQualifier} to add.
-     */
-    public void addQualifier(ResourceQualifier qualifier) {
-        if (qualifier instanceof CountryCodeQualifier) {
-            mQualifiers[INDEX_COUNTRY_CODE] = qualifier;
-        } else if (qualifier instanceof NetworkCodeQualifier) {
-            mQualifiers[INDEX_NETWORK_CODE] = qualifier;
-        } else if (qualifier instanceof LanguageQualifier) {
-            mQualifiers[INDEX_LANGUAGE] = qualifier;
-        } else if (qualifier instanceof RegionQualifier) {
-            mQualifiers[INDEX_REGION] = qualifier;
-        } else if (qualifier instanceof ScreenOrientationQualifier) {
-            mQualifiers[INDEX_SCREEN_ORIENTATION] = qualifier;
-        } else if (qualifier instanceof PixelDensityQualifier) {
-            mQualifiers[INDEX_PIXEL_DENSITY] = qualifier;
-        } else if (qualifier instanceof TouchScreenQualifier) {
-            mQualifiers[INDEX_TOUCH_TYPE] = qualifier;
-        } else if (qualifier instanceof KeyboardStateQualifier) {
-            mQualifiers[INDEX_KEYBOARD_STATE] = qualifier;
-        } else if (qualifier instanceof TextInputMethodQualifier) {
-            mQualifiers[INDEX_TEXT_INPUT_METHOD] = qualifier;
-        } else if (qualifier instanceof NavigationMethodQualifier) {
-            mQualifiers[INDEX_NAVIGATION_METHOD] = qualifier;
-        } else if (qualifier instanceof ScreenDimensionQualifier) {
-            mQualifiers[INDEX_SCREEN_DIMENSION] = qualifier;
-        }
-    }
-    
-    /**
-     * Removes a given qualifier from the {@link FolderConfiguration}.
-     * @param qualifier the {@link ResourceQualifier} to remove.
-     */
-    public void removeQualifier(ResourceQualifier qualifier) {
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            if (mQualifiers[i] == qualifier) {
-                mQualifiers[i] = null;
-                return;
-            }
-        }
-    }
-    
-    public void setCountryCodeQualifier(CountryCodeQualifier qualifier) {
-        mQualifiers[INDEX_COUNTRY_CODE] = qualifier;
-    }
-
-    public CountryCodeQualifier getCountryCodeQualifier() {
-        return (CountryCodeQualifier)mQualifiers[INDEX_COUNTRY_CODE];
-    }
-
-    public void setNetworkCodeQualifier(NetworkCodeQualifier qualifier) {
-        mQualifiers[INDEX_NETWORK_CODE] = qualifier;
-    }
-
-    public NetworkCodeQualifier getNetworkCodeQualifier() {
-        return (NetworkCodeQualifier)mQualifiers[INDEX_NETWORK_CODE];
-    }
-
-    public void setLanguageQualifier(LanguageQualifier qualifier) {
-        mQualifiers[INDEX_LANGUAGE] = qualifier;
-    }
-
-    public LanguageQualifier getLanguageQualifier() {
-        return (LanguageQualifier)mQualifiers[INDEX_LANGUAGE];
-    }
-
-    public void setRegionQualifier(RegionQualifier qualifier) {
-        mQualifiers[INDEX_REGION] = qualifier;
-    }
-
-    public RegionQualifier getRegionQualifier() {
-        return (RegionQualifier)mQualifiers[INDEX_REGION];
-    }
-
-    public void setScreenOrientationQualifier(ScreenOrientationQualifier qualifier) {
-        mQualifiers[INDEX_SCREEN_ORIENTATION] = qualifier;
-    }
-
-    public ScreenOrientationQualifier getScreenOrientationQualifier() {
-        return (ScreenOrientationQualifier)mQualifiers[INDEX_SCREEN_ORIENTATION];
-    }
-
-    public void setPixelDensityQualifier(PixelDensityQualifier qualifier) {
-        mQualifiers[INDEX_PIXEL_DENSITY] = qualifier;
-    }
-
-    public PixelDensityQualifier getPixelDensityQualifier() {
-        return (PixelDensityQualifier)mQualifiers[INDEX_PIXEL_DENSITY];
-    }
-
-    public void setTouchTypeQualifier(TouchScreenQualifier qualifier) {
-        mQualifiers[INDEX_TOUCH_TYPE] = qualifier;
-    }
-
-    public TouchScreenQualifier getTouchTypeQualifier() {
-        return (TouchScreenQualifier)mQualifiers[INDEX_TOUCH_TYPE];
-    }
-
-    public void setKeyboardStateQualifier(KeyboardStateQualifier qualifier) {
-        mQualifiers[INDEX_KEYBOARD_STATE] = qualifier;
-    }
-
-    public KeyboardStateQualifier getKeyboardStateQualifier() {
-        return (KeyboardStateQualifier)mQualifiers[INDEX_KEYBOARD_STATE];
-    }
-
-    public void setTextInputMethodQualifier(TextInputMethodQualifier qualifier) {
-        mQualifiers[INDEX_TEXT_INPUT_METHOD] = qualifier;
-    }
-
-    public TextInputMethodQualifier getTextInputMethodQualifier() {
-        return (TextInputMethodQualifier)mQualifiers[INDEX_TEXT_INPUT_METHOD];
-    }
-    
-    public void setNavigationMethodQualifier(NavigationMethodQualifier qualifier) {
-        mQualifiers[INDEX_NAVIGATION_METHOD] = qualifier;
-    }
-
-    public NavigationMethodQualifier getNavigationMethodQualifier() {
-        return (NavigationMethodQualifier)mQualifiers[INDEX_NAVIGATION_METHOD];
-    }
-    
-    public void setScreenDimensionQualifier(ScreenDimensionQualifier qualifier) {
-        mQualifiers[INDEX_SCREEN_DIMENSION] = qualifier;
-    }
-
-    public ScreenDimensionQualifier getScreenDimensionQualifier() {
-        return (ScreenDimensionQualifier)mQualifiers[INDEX_SCREEN_DIMENSION];
-    }
-
-    /**
-     * Returns whether an object is equals to the receiver.
-     */
-    @Override
-    public boolean equals(Object obj) {
-        if (obj == this) {
-            return true;
-        }
-        
-        if (obj instanceof FolderConfiguration) {
-            FolderConfiguration fc = (FolderConfiguration)obj;
-            for (int i = 0 ; i < INDEX_COUNT ; i++) {
-                ResourceQualifier qualifier = mQualifiers[i];
-                ResourceQualifier fcQualifier = fc.mQualifiers[i];
-                if (qualifier != null) {
-                    if (qualifier.equals(fcQualifier) == false) {
-                        return false;
-                    }
-                } else if (fcQualifier != null) {
-                    return false;
-                }
-            }
-
-            return true;
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return toString().hashCode();
-    }
-    
-    /**
-     * Returns whether the Configuration has only default values.
-     */
-    public boolean isDefault() {
-        for (ResourceQualifier irq : mQualifiers) {
-            if (irq != null) {
-                return false;
-            }
-        }
-        
-        return true;
-    }
-    
-    /**
-     * Returns the name of a folder with the configuration.
-     */
-    public String getFolderName(ResourceFolderType folder) {
-        StringBuilder result = new StringBuilder(folder.getName());
-        
-        for (ResourceQualifier qualifier : mQualifiers) {
-            if (qualifier != null) {
-                result.append(QUALIFIER_SEP);
-                result.append(qualifier.toString());
-            }
-        }
-        
-        return result.toString();
-    }
-    
-    /**
-     * Returns a string valid for usage in a folder name, or <code>null</code> if the configuration
-     * is default.
-     */
-    @Override
-    public String toString() {
-        StringBuilder result = null;
-        
-        for (ResourceQualifier irq : mQualifiers) {
-            if (irq != null) {
-                if (result == null) {
-                    result = new StringBuilder();
-                } else {
-                    result.append(QUALIFIER_SEP);
-                }
-                result.append(irq.toString());
-            }
-        }
-        
-        if (result != null) {
-            return result.toString();
-        } else {
-            return null;
-        }
-    }
-    
-    /**
-     * Returns a string valid for display purpose.
-     */
-    public String toDisplayString() {
-        if (isDefault()) {
-            return "default";
-        }
-
-        StringBuilder result = null;
-        int index = 0;
-        ResourceQualifier qualifier = null;
-        
-        // pre- language/region qualifiers
-        while (index < INDEX_LANGUAGE) {
-            qualifier = mQualifiers[index++];
-            if (qualifier != null) {
-                if (result == null) {
-                    result = new StringBuilder();
-                } else {
-                    result.append(", "); //$NON-NLS-1$
-                }
-                result.append(qualifier.getStringValue());
-                
-            }
-        }
-        
-        // process the language/region qualifier in a custom way, if there are both non null.
-        if (mQualifiers[INDEX_LANGUAGE] != null && mQualifiers[INDEX_REGION] != null) {
-            String language = mQualifiers[INDEX_LANGUAGE].getStringValue();
-            String region = mQualifiers[INDEX_REGION].getStringValue();
-
-            if (result == null) {
-                result = new StringBuilder();
-            } else {
-                result.append(", "); //$NON-NLS-1$
-            }
-            result.append(String.format("%s_%s", language, region)); //$NON-NLS-1$
-            
-            index += 2;
-        }
-        
-        // post language/region qualifiers.
-        while (index < INDEX_COUNT) {
-            qualifier = mQualifiers[index++];
-            if (qualifier != null) {
-                if (result == null) {
-                    result = new StringBuilder();
-                } else {
-                    result.append(", "); //$NON-NLS-1$
-                }
-                result.append(qualifier.getStringValue());
-                
-            }
-        }
-
-        return result.toString();
-    }
-
-    public int compareTo(FolderConfiguration folderConfig) {
-        // default are always at the top.
-        if (isDefault()) {
-            if (folderConfig.isDefault()) {
-                return 0;
-            }
-            return -1;
-        }
-        
-        // now we compare the qualifiers
-        for (int i = 0 ; i < INDEX_COUNT; i++) {
-            ResourceQualifier qualifier1 = mQualifiers[i];
-            ResourceQualifier qualifier2 = folderConfig.mQualifiers[i];
-            
-            if (qualifier1 == null) {
-                if (qualifier2 == null) {
-                    continue;
-                } else {
-                    return -1;
-                }
-            } else {
-                if (qualifier2 == null) {
-                    return 1;
-                } else {
-                    int result = qualifier1.compareTo(qualifier2);
-                    
-                    if (result == 0) {
-                        continue;
-                    }
-                    
-                    return result;
-                }
-            }
-        }
-        
-        // if we arrive here, all the qualifier matches
-        return 0;
-    }
-
-    /**
-     * Returns whether the configuration match the given reference config.
-     * <p/>A match means that:
-     * <ul>
-     * <li>This config does not use any qualifier not used by the reference config</li>
-     * <li>The qualifier used by this config have the same values as the qualifiers of
-     * the reference config.</li>
-     * </ul>
-     * @param referenceConfig The reference configuration to test against.
-     * @return the number of matching qualifiers or -1 if the configurations are not compatible.
-     */
-    public int match(FolderConfiguration referenceConfig) {
-        int matchCount = 0;
-        
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            ResourceQualifier testQualifier = mQualifiers[i];
-            ResourceQualifier referenceQualifier = referenceConfig.mQualifiers[i];
-            
-            // we only care if testQualifier is non null. If it's null, it's a match but
-            // without increasing the matchCount.
-            if (testQualifier != null) {
-                if (referenceQualifier == null) {
-                    return -1;
-                } else if (testQualifier.equals(referenceQualifier) == false) {
-                    return -1;
-                }
-                
-                // the qualifier match, increment the count
-                matchCount++;
-            }
-        }
-        return matchCount;
-    }
-
-    /**
-     * Returns the index of the first non null {@link ResourceQualifier} starting at index
-     * <var>startIndex</var>
-     * @param startIndex
-     * @return -1 if no qualifier was found.
-     */
-    public int getHighestPriorityQualifier(int startIndex) {
-        for (int i = startIndex ; i < INDEX_COUNT ; i++) {
-            if (mQualifiers[i] != null) {
-                return i;
-            }
-        }
-        
-        return -1;
-    }
-    
-    /**
-     * Create default qualifiers.
-     */
-    public void createDefault() {
-        mQualifiers[INDEX_COUNTRY_CODE] = new CountryCodeQualifier();
-        mQualifiers[INDEX_NETWORK_CODE] = new NetworkCodeQualifier();
-        mQualifiers[INDEX_LANGUAGE] = new LanguageQualifier();
-        mQualifiers[INDEX_REGION] = new RegionQualifier();
-        mQualifiers[INDEX_SCREEN_ORIENTATION] = new ScreenOrientationQualifier();
-        mQualifiers[INDEX_PIXEL_DENSITY] = new PixelDensityQualifier();
-        mQualifiers[INDEX_TOUCH_TYPE] = new TouchScreenQualifier();
-        mQualifiers[INDEX_KEYBOARD_STATE] = new KeyboardStateQualifier();
-        mQualifiers[INDEX_TEXT_INPUT_METHOD] = new TextInputMethodQualifier();
-        mQualifiers[INDEX_NAVIGATION_METHOD] = new NavigationMethodQualifier();
-        mQualifiers[INDEX_SCREEN_DIMENSION] = new ScreenDimensionQualifier();
-    }
-
-    /**
-     * Returns an array of all the non null qualifiers.
-     */
-    public ResourceQualifier[] getQualifiers() {
-        int count = 0;
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            if (mQualifiers[i] != null) {
-                count++;
-            }
-        }
-        
-        ResourceQualifier[] array = new ResourceQualifier[count];
-        int index = 0;
-        for (int i = 0 ; i < INDEX_COUNT ; i++) {
-            if (mQualifiers[i] != null) {
-                array[index++] = mQualifiers[i];
-            }
-        }
-        
-        return array;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifier.java
deleted file mode 100644
index ad232ed..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifier.java
+++ /dev/null
@@ -1,180 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-
-
-/**
- * Resource Qualifier for keyboard state.
- */
-public final class KeyboardStateQualifier extends ResourceQualifier {
-    
-    public static final String NAME = "Keyboard State";
-
-    private KeyboardState mValue = null;
-
-    /**
-     * Screen Orientation enum.
-     */
-    public static enum KeyboardState {
-        EXPOSED("keysexposed", "Exposed"), //$NON-NLS-1$
-        HIDDEN("keyshidden", "Hidden"); //$NON-NLS-1$
-        
-        private String mValue;
-        private String mDisplayValue;
-        
-        private KeyboardState(String value, String displayValue) {
-            mValue = value;
-            mDisplayValue = displayValue;
-        }
-        
-        /**
-         * Returns the enum for matching the provided qualifier value.
-         * @param value The qualifier value.
-         * @return the enum for the qualifier value or null if no matching was found.
-         */
-        static KeyboardState getEnum(String value) {
-            for (KeyboardState orient : values()) {
-                if (orient.mValue.equals(value)) {
-                    return orient;
-                }
-            }
-            
-            return null;
-        }
-
-        public String getValue() {
-            return mValue;
-        }
-        
-        public String getDisplayValue() {
-            return mDisplayValue;
-        }
-        
-        public static int getIndex(KeyboardState value) {
-            int i = 0;
-            for (KeyboardState input : values()) {
-                if (value == input) {
-                    return i;
-                }
-                
-                i++;
-            }
-
-            return -1;
-        }
-
-        public static KeyboardState getByIndex(int index) {
-            int i = 0;
-            for (KeyboardState value : values()) {
-                if (i == index) {
-                    return value;
-                }
-                i++;
-            }
-            return null;
-        }
-    }
-
-    public KeyboardStateQualifier() {
-        // pass
-    }
-
-    public KeyboardStateQualifier(KeyboardState value) {
-        mValue = value;
-    }
-
-    public KeyboardState getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Keyboard";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("keyboard"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-    
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        KeyboardState orientation = KeyboardState.getEnum(value);
-        if (orientation != null) {
-            KeyboardStateQualifier qualifier = new KeyboardStateQualifier();
-            qualifier.mValue = orientation;
-            config.setKeyboardStateQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof KeyboardStateQualifier) {
-            return mValue == ((KeyboardStateQualifier)qualifier).mValue;
-        }
-
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return mValue.getValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue.getDisplayValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifier.java
deleted file mode 100644
index 99c3a43..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifier.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Language.
- */
-public final class LanguageQualifier extends ResourceQualifier {
-    private final static Pattern sLanguagePattern = Pattern.compile("^[a-z]{2}$"); //$NON-NLS-1$
-
-    public static final String NAME = "Language";
-    
-    private String mValue;
-    
-    /**
-     * Creates and returns a qualifier from the given folder segment. If the segment is incorrect,
-     * <code>null</code> is returned.
-     * @param segment the folder segment from which to create a qualifier.
-     * @return a new {@link LanguageQualifier} object or <code>null</code>
-     */
-    public static LanguageQualifier getQualifier(String segment) {
-        if (sLanguagePattern.matcher(segment).matches()) {
-            LanguageQualifier qualifier = new LanguageQualifier();
-            qualifier.mValue = segment;
-            
-            return qualifier;
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the folder name segment for the given value. This is equivalent to calling
-     * {@link #toString()} on a {@link LanguageQualifier} object.
-     * @param value the value of the qualifier, as returned by {@link #getValue()}.
-     */
-    public static String getFolderSegment(String value) {
-        String segment = value.toLowerCase();
-        if (sLanguagePattern.matcher(segment).matches()) {
-            return segment;
-        }
-        
-        return null;
-    }
-
-    public String getValue() {
-        if (mValue != null) {
-            return mValue;
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return NAME;
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("language"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        LanguageQualifier qualifier = getQualifier(value);
-        if (qualifier != null) {
-            config.setLanguageQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof LanguageQualifier) {
-            if (mValue == null) {
-                return ((LanguageQualifier)qualifier).mValue == null;
-            }
-            return mValue.equals(((LanguageQualifier)qualifier).mValue);
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return getFolderSegment(mValue);
-        }
-
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue;
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifier.java
deleted file mode 100644
index 1a2cf53..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifier.java
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-
-
-/**
- * Resource Qualifier for Navigation Method.
- */
-public final class NavigationMethodQualifier extends ResourceQualifier {
-    
-    public static final String NAME = "Navigation Method";
-
-    private NavigationMethod mValue;
-
-    /**
-     * Navigation Method enum.
-     */
-    public static enum NavigationMethod {
-        DPAD("dpad", "D-pad"), //$NON-NLS-1$
-        TRACKBALL("trackball", "Trackball"), //$NON-NLS-1$
-        WHEEL("wheel", "Wheel"), //$NON-NLS-1$
-        NONAV("nonav", "No Navigation"); //$NON-NLS-1$
-        
-        private String mValue;
-        private String mDisplay;
-        
-        private NavigationMethod(String value, String display) {
-            mValue = value;
-            mDisplay = display;
-        }
-        
-        /**
-         * Returns the enum for matching the provided qualifier value.
-         * @param value The qualifier value.
-         * @return the enum for the qualifier value or null if no matching was found.
-         */
-        static NavigationMethod getEnum(String value) {
-            for (NavigationMethod orient : values()) {
-                if (orient.mValue.equals(value)) {
-                    return orient;
-                }
-            }
-            
-            return null;
-        }
-        
-        public String getValue() {
-            return mValue;
-        }
-        
-        public String getDisplayValue() {
-            return mDisplay;
-        }
-
-        public static int getIndex(NavigationMethod value) {
-            int i = 0;
-            for (NavigationMethod nav : values()) {
-                if (nav == value) {
-                    return i;
-                }
-                
-                i++;
-            }
-
-            return -1;
-        }
-
-        public static NavigationMethod getByIndex(int index) {
-            int i = 0;
-            for (NavigationMethod value : values()) {
-                if (i == index) {
-                    return value;
-                }
-                i++;
-            }
-            return null;
-        }
-    }
-    
-    public NavigationMethodQualifier() {
-        // pass
-    }
-
-    public NavigationMethodQualifier(NavigationMethod value) {
-        mValue = value;
-    }
-
-    public NavigationMethod getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Navigation";
-    }
-
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("navpad"); //$NON-NLS-1$
-    }
-
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        NavigationMethod method = NavigationMethod.getEnum(value);
-        if (method != null) {
-            NavigationMethodQualifier qualifier = new NavigationMethodQualifier();
-            qualifier.mValue = method;
-            config.setNavigationMethodQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof NavigationMethodQualifier) {
-            return mValue == ((NavigationMethodQualifier)qualifier).mValue;
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return mValue.getValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue.getDisplayValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifier.java
deleted file mode 100644
index 7e30901..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifier.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Mobile Network Code Pixel Density.
- */
-public final class NetworkCodeQualifier extends ResourceQualifier {
-    /** Default pixel density value. This means the property is not set. */
-    private final static int DEFAULT_CODE = -1;
-
-    private final static Pattern sNetworkCodePattern = Pattern.compile("^mnc(\\d{1,3})$"); //$NON-NLS-1$
-
-    private int mCode = DEFAULT_CODE;
-    
-    public final static String NAME = "Mobile Network Code";
-    
-    /**
-     * Creates and returns a qualifier from the given folder segment. If the segment is incorrect,
-     * <code>null</code> is returned.
-     * @param segment the folder segment from which to create a qualifier.
-     * @return a new {@link CountryCodeQualifier} object or <code>null</code>
-     */
-    public static NetworkCodeQualifier getQualifier(String segment) {
-        Matcher m = sNetworkCodePattern.matcher(segment);
-        if (m.matches()) {
-            String v = m.group(1);
-
-            int code = -1;
-            try {
-                code = Integer.parseInt(v);
-            } catch (NumberFormatException e) {
-                // looks like the string we extracted wasn't a valid number.
-                return null;
-            }
-            
-            NetworkCodeQualifier qualifier = new NetworkCodeQualifier();
-            qualifier.mCode = code;
-            return qualifier;
-        }
-
-        return null;
-    }
-
-    /**
-     * Returns the folder name segment for the given value. This is equivalent to calling
-     * {@link #toString()} on a {@link NetworkCodeQualifier} object.
-     * @param code the value of the qualifier, as returned by {@link #getCode()}.
-     */
-    public static String getFolderSegment(int code) {
-        if (code != DEFAULT_CODE && code >= 1 && code <= 999) { // code is 1-3 digit.
-            return String.format("mnc%1$d", code); //$NON-NLS-1$
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    public int getCode() {
-        return mCode;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Network Code";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("mnc"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mCode != DEFAULT_CODE;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        Matcher m = sNetworkCodePattern.matcher(value);
-        if (m.matches()) {
-            String v = m.group(1);
-
-            int code = -1;
-            try {
-                code = Integer.parseInt(v);
-            } catch (NumberFormatException e) {
-                // looks like the string we extracted wasn't a valid number.
-                return false;
-            }
-            
-            NetworkCodeQualifier qualifier = new NetworkCodeQualifier();
-            qualifier.mCode = code;
-            config.setNetworkCodeQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof NetworkCodeQualifier) {
-            return mCode == ((NetworkCodeQualifier)qualifier).mCode;
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return mCode;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        return getFolderSegment(mCode);
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mCode != DEFAULT_CODE) {
-            return String.format("MNC %1$d", mCode);
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifier.java
deleted file mode 100644
index c47bb83..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifier.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Screen Pixel Density.
- */
-public final class PixelDensityQualifier extends ResourceQualifier {
-    /** Default pixel density value. This means the property is not set. */
-    private final static int DEFAULT_DENSITY = -1;
-
-    private final static Pattern sPixelDensityPattern = Pattern.compile("^(\\d+)dpi$");//$NON-NLS-1$
-
-    public static final String NAME = "Pixel Density";
-
-    private int mValue = DEFAULT_DENSITY;
-    
-    /**
-     * Creates and returns a qualifier from the given folder segment. If the segment is incorrect,
-     * <code>null</code> is returned.
-     * @param folderSegment the folder segment from which to create a qualifier.
-     * @return a new {@link CountryCodeQualifier} object or <code>null</code>
-     */
-    public static PixelDensityQualifier getQualifier(String folderSegment) {
-        Matcher m = sPixelDensityPattern.matcher(folderSegment);
-        if (m.matches()) {
-            String v = m.group(1);
-
-            int density = -1;
-            try {
-                density = Integer.parseInt(v);
-            } catch (NumberFormatException e) {
-                // looks like the string we extracted wasn't a valid number.
-                return null;
-            }
-            
-            PixelDensityQualifier qualifier = new PixelDensityQualifier();
-            qualifier.mValue = density;
-            
-            return qualifier;
-        }
-        return null;
-    }
-
-    /**
-     * Returns the folder name segment for the given value. This is equivalent to calling
-     * {@link #toString()} on a {@link NetworkCodeQualifier} object.
-     * @param value the value of the qualifier, as returned by {@link #getValue()}.
-     */
-    public static String getFolderSegment(int value) {
-        if (value != DEFAULT_DENSITY) {
-            return String.format("%1$ddpi", value); //$NON-NLS-1$
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    public int getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return NAME;
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("dpi"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mValue != DEFAULT_DENSITY;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        PixelDensityQualifier qualifier = getQualifier(value);
-        if (qualifier != null) {
-            config.setPixelDensityQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof PixelDensityQualifier) {
-            return mValue == ((PixelDensityQualifier)qualifier).mValue;
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return mValue;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        return getFolderSegment(mValue);
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != DEFAULT_DENSITY) {
-            return String.format("%1$d dpi", mValue);
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/RegionQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/RegionQualifier.java
deleted file mode 100644
index dc4d5fa..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/RegionQualifier.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Region.
- */
-public final class RegionQualifier extends ResourceQualifier {
-    private final static Pattern sRegionPattern = Pattern.compile("^r([A-Z]{2})$"); //$NON-NLS-1$
-
-    public static final String NAME = "Region";
-    
-    private String mValue;
-    
-    /**
-     * Creates and returns a qualifier from the given folder segment. If the segment is incorrect,
-     * <code>null</code> is returned.
-     * @param segment the folder segment from which to create a qualifier.
-     * @return a new {@link RegionQualifier} object or <code>null</code>
-     */
-    public static RegionQualifier getQualifier(String segment) {
-        Matcher m = sRegionPattern.matcher(segment);
-        if (m.matches()) {
-            RegionQualifier qualifier = new RegionQualifier();
-            qualifier.mValue = m.group(1);
-
-            return qualifier;
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the folder name segment for the given value. This is equivalent to calling
-     * {@link #toString()} on a {@link RegionQualifier} object.
-     * @param value the value of the qualifier, as returned by {@link #getValue()}.
-     */
-    public static String getFolderSegment(String value) {
-        if (value != null) {
-            String segment = "r" + value.toUpperCase(); //$NON-NLS-1$
-            if (sRegionPattern.matcher(segment).matches()) {
-                return segment;
-            }
-        }
-            
-        return "";  //$NON-NLS-1$
-    }
-
-    public String getValue() {
-        if (mValue != null) {
-            return mValue;
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return NAME;
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("region"); //$NON-NLS-1$
-    }
-
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        RegionQualifier qualifier = getQualifier(value);
-        if (qualifier != null) {
-            config.setRegionQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof RegionQualifier) {
-            if (mValue == null) {
-                return ((RegionQualifier)qualifier).mValue == null;
-            }
-            return mValue.equals(((RegionQualifier)qualifier).mValue);
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        return getFolderSegment(mValue);
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue;
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ResourceQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ResourceQualifier.java
deleted file mode 100644
index 0257afa..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ResourceQualifier.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * Base class for resource qualifiers.
- * <p/>The resource qualifier classes are designed as immutable.
- */
-public abstract class ResourceQualifier implements Comparable<ResourceQualifier> {
-    
-    /**
-     * Returns the human readable name of the qualifier.
-     */
-    public abstract String getName();
-    
-    /**
-     * Returns a shorter human readable name for the qualifier.
-     * @see #getName()
-     */
-    public abstract String getShortName();
-    
-    /**
-     * Returns the icon for the qualifier.
-     */
-    public abstract Image getIcon();
-    
-    /**
-     * Returns whether the qualifier has a valid filter value.
-     */
-    public abstract boolean isValid();
-    
-    /**
-     * Check if the value is valid for this qualifier, and if so sets the value
-     * into a Folder Configuration.
-     * @param value The value to check and set. Must not be null.
-     * @param config The folder configuration to receive the value. Must not be null.
-     * @return true if the value was valid and was set.
-     */
-    public abstract boolean checkAndSet(String value, FolderConfiguration config);
-    
-    /**
-     * Returns a string formated to be used in a folder name.
-     * <p/>This is declared as abstract to force children classes to implement it.
-     */
-    @Override
-    public abstract String toString();
-
-    /**
-     * Returns a string formatted for display purpose.
-     */
-    public abstract String getStringValue();
-
-    /**
-     * Returns <code>true</code> if both objects are equal.
-     * <p/>This is declared as abstract to force children classes to implement it.
-     */
-    @Override
-    public abstract boolean equals(Object object);
-    
-    /**
-     * Returns a hash code value for the object.
-     * <p/>This is declared as abstract to force children classes to implement it.
-     */
-    @Override
-    public abstract int hashCode();
-
-    public final int compareTo(ResourceQualifier o) {
-        return toString().compareTo(o.toString());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifier.java
deleted file mode 100644
index a2cc789..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifier.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Resource Qualifier for Screen Dimension.
- */
-public final class ScreenDimensionQualifier extends ResourceQualifier {
-    /** Default screen size value. This means the property is not set */
-    final static int DEFAULT_SIZE = -1;
-
-    private final static Pattern sDimensionPattern = Pattern.compile(
-            "^(\\d+)x(\\d+)$"); //$NON-NLS-1$
-
-    public static final String NAME = "Screen Dimension";
-
-    /** Screen size 1 value. This is not size X or Y because the folder name always
-     * contains the biggest size first. So if the qualifier is 400x200, size 1 will always be
-     * 400 but that'll be X in landscape and Y in portrait.
-     * Default value is <code>DEFAULT_SIZE</code> */
-    private int mValue1 = DEFAULT_SIZE;
-
-    /** Screen size 2 value. This is not size X or Y because the folder name always
-     * contains the biggest size first. So if the qualifier is 400x200, size 2 will always be
-     * 200 but that'll be Y in landscape and X in portrait.
-     * Default value is <code>DEFAULT_SIZE</code> */
-    private int mValue2 = DEFAULT_SIZE;
-    
-    public int getValue1() {
-        return mValue1;
-    }
-
-    public int getValue2() {
-        return mValue2;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Dimension";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("dimension"); //$NON-NLS-1$
-    }
-
-    @Override
-    public boolean isValid() {
-        return mValue1 != DEFAULT_SIZE && mValue2 != DEFAULT_SIZE;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        Matcher m = sDimensionPattern.matcher(value);
-        if (m.matches()) {
-            String d1 = m.group(1);
-            String d2 = m.group(2);
-            
-            ScreenDimensionQualifier qualifier = getQualifier(d1, d2);
-            if (qualifier != null) {
-                config.setScreenDimensionQualifier(qualifier);
-                return true;
-            }
-        }
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof ScreenDimensionQualifier) {
-            ScreenDimensionQualifier q = (ScreenDimensionQualifier)qualifier;
-            return (mValue1 == q.mValue1 && mValue2 == q.mValue2);
-        }
-        
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return toString().hashCode();
-    }
-    
-    public static ScreenDimensionQualifier getQualifier(String size1, String size2) {
-        try {
-            int s1 = Integer.parseInt(size1);
-            int s2 = Integer.parseInt(size2);
-            
-            ScreenDimensionQualifier qualifier = new ScreenDimensionQualifier();
-
-            if (s1 > s2) {
-                qualifier.mValue1 = s1;
-                qualifier.mValue2 = s2;
-            } else {
-                qualifier.mValue1 = s2;
-                qualifier.mValue2 = s1;
-            }
-
-            return qualifier;
-        } catch (NumberFormatException e) {
-            // looks like the string we extracted wasn't a valid number.
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        return String.format("%1$dx%2$d", mValue1, mValue2); //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue1 != -1 && mValue2 != -1) {
-            return String.format("%1$dx%2$d", mValue1, mValue2);
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifier.java
deleted file mode 100644
index e30930f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifier.java
+++ /dev/null
@@ -1,178 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * Resource Qualifier for Screen Orientation.
- */
-public final class ScreenOrientationQualifier extends ResourceQualifier {
-    
-    public static final String NAME = "Screen Orientation";
-
-    private ScreenOrientation mValue = null;
-
-    /**
-     * Screen Orientation enum.
-     */
-    public static enum ScreenOrientation {
-        PORTRAIT("port", "Portrait"), //$NON-NLS-1$
-        LANDSCAPE("land", "Landscape"), //$NON-NLS-1$
-        SQUARE("square", "Square"); //$NON-NLS-1$
-        
-        private String mValue;
-        private String mDisplayValue;
-        
-        private ScreenOrientation(String value, String displayValue) {
-            mValue = value;
-            mDisplayValue = displayValue;
-        }
-        
-        /**
-         * Returns the enum for matching the provided qualifier value.
-         * @param value The qualifier value.
-         * @return the enum for the qualifier value or null if no matching was found.
-         */
-        static ScreenOrientation getEnum(String value) {
-            for (ScreenOrientation orient : values()) {
-                if (orient.mValue.equals(value)) {
-                    return orient;
-                }
-            }
-
-            return null;
-        }
-
-        public String getValue() {
-            return mValue;
-        }
-        
-        public String getDisplayValue() {
-            return mDisplayValue;
-        }
-        
-        public static int getIndex(ScreenOrientation orientation) {
-            int i = 0;
-            for (ScreenOrientation orient : values()) {
-                if (orient == orientation) {
-                    return i;
-                }
-                
-                i++;
-            }
-
-            return -1;
-        }
-
-        public static ScreenOrientation getByIndex(int index) {
-            int i = 0;
-            for (ScreenOrientation orient : values()) {
-                if (i == index) {
-                    return orient;
-                }
-                i++;
-            }
-
-            return null;
-        }
-    }
-
-    public ScreenOrientationQualifier() {
-    }
-
-    public ScreenOrientationQualifier(ScreenOrientation value) {
-        mValue = value;
-    }
-
-    public ScreenOrientation getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Orientation";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("orientation"); //$NON-NLS-1$
-    }
-    
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        ScreenOrientation orientation = ScreenOrientation.getEnum(value);
-        if (orientation != null) {
-            ScreenOrientationQualifier qualifier = new ScreenOrientationQualifier(orientation);
-            config.setScreenOrientationQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof ScreenOrientationQualifier) {
-            return mValue == ((ScreenOrientationQualifier)qualifier).mValue;
-        }
-
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-    
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return mValue.getValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue.getDisplayValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifier.java
deleted file mode 100644
index de40138..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifier.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-
-
-
-/**
- * Resource Qualifier for Text Input Method.
- */
-public final class TextInputMethodQualifier extends ResourceQualifier {
-
-    public static final String NAME = "Text Input Method";
-
-    private TextInputMethod mValue;
-    
-    /**
-     * Screen Orientation enum.
-     */
-    public static enum TextInputMethod {
-        NOKEY("nokeys", "No Keys"), //$NON-NLS-1$
-        QWERTY("qwerty", "Qwerty"), //$NON-NLS-1$
-        TWELVEKEYS("12key", "12 Key"); //$NON-NLS-1$
-        
-        private String mValue;
-        private String mDisplayValue;
-        
-        private TextInputMethod(String value, String displayValue) {
-            mValue = value;
-            mDisplayValue = displayValue;
-        }
-        
-        /**
-         * Returns the enum for matching the provided qualifier value.
-         * @param value The qualifier value.
-         * @return the enum for the qualifier value or null if no matching was found.
-         */
-        static TextInputMethod getEnum(String value) {
-            for (TextInputMethod orient : values()) {
-                if (orient.mValue.equals(value)) {
-                    return orient;
-                }
-            }
-            
-            return null;
-        }
-
-        public String getValue() {
-            return mValue;
-        }
-        
-        public String getDisplayValue() {
-            return mDisplayValue;
-        }
-
-        public static int getIndex(TextInputMethod value) {
-            int i = 0;
-            for (TextInputMethod input : values()) {
-                if (value == input) {
-                    return i;
-                }
-                
-                i++;
-            }
-
-            return -1;
-        }
-
-        public static TextInputMethod getByIndex(int index) {
-            int i = 0;
-            for (TextInputMethod value : values()) {
-                if (i == index) {
-                    return value;
-                }
-                i++;
-            }
-            return null;
-        }
-    }
-    
-    public TextInputMethodQualifier() {
-        // pass
-    }
-
-    public TextInputMethodQualifier(TextInputMethod value) {
-        mValue = value;
-    }
-
-    public TextInputMethod getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return "Text Input";
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("text_input"); //$NON-NLS-1$
-    }
-
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        TextInputMethod method = TextInputMethod.getEnum(value);
-        if (method != null) {
-            TextInputMethodQualifier qualifier = new TextInputMethodQualifier();
-            qualifier.mValue = method;
-            config.setTextInputMethodQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof TextInputMethodQualifier) {
-            return mValue == ((TextInputMethodQualifier)qualifier).mValue;
-        }
-
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return mValue.getValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue.getDisplayValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifier.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifier.java
deleted file mode 100644
index 2390e2c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifier.java
+++ /dev/null
@@ -1,180 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import com.android.ide.eclipse.editors.IconFactory;
-
-import org.eclipse.swt.graphics.Image;
-
-
-/**
- * Resource Qualifier for Touch Screen type.
- */
-public final class TouchScreenQualifier extends ResourceQualifier {
-
-    public static final String NAME = "Touch Screen";
-
-    private TouchScreenType mValue;
-    
-    /**
-     * Screen Orientation enum.
-     */
-    public static enum TouchScreenType {
-        NOTOUCH("notouch", "No Touch"), //$NON-NLS-1$
-        STYLUS("stylus", "Stylus"), //$NON-NLS-1$
-        FINGER("finger", "Finger"); //$NON-NLS-1$
-        
-        private String mValue;
-        private String mDisplayValue;
-        
-        private TouchScreenType(String value, String displayValue) {
-            mValue = value;
-            mDisplayValue = displayValue;
-        }
-        
-        /**
-         * Returns the enum for matching the provided qualifier value.
-         * @param value The qualifier value.
-         * @return the enum for the qualifier value or null if no matching was found.
-         */
-        static TouchScreenType getEnum(String value) {
-            for (TouchScreenType orient : values()) {
-                if (orient.mValue.equals(value)) {
-                    return orient;
-                }
-            }
-            
-            return null;
-        }
-
-        public String getValue() {
-            return mValue;
-        }
-        
-        public String getDisplayValue() {
-            return mDisplayValue;
-        }
-
-        public static int getIndex(TouchScreenType touch) {
-            int i = 0;
-            for (TouchScreenType t : values()) {
-                if (t == touch) {
-                    return i;
-                }
-                
-                i++;
-            }
-
-            return -1;
-        }
-
-        public static TouchScreenType getByIndex(int index) {
-            int i = 0;
-            for (TouchScreenType value : values()) {
-                if (i == index) {
-                    return value;
-                }
-                i++;
-            }
-
-            return null;
-        }
-    }
-    
-    public TouchScreenQualifier() {
-        // pass
-    }
-
-    public TouchScreenQualifier(TouchScreenType touchValue) {
-        mValue = touchValue;
-    }
-
-    public TouchScreenType getValue() {
-        return mValue;
-    }
-    
-    @Override
-    public String getName() {
-        return NAME;
-    }
-    
-    @Override
-    public String getShortName() {
-        return NAME;
-    }
-    
-    @Override
-    public Image getIcon() {
-        return IconFactory.getInstance().getIcon("touch"); //$NON-NLS-1$
-    }
-
-    @Override
-    public boolean isValid() {
-        return mValue != null;
-    }
-
-    @Override
-    public boolean checkAndSet(String value, FolderConfiguration config) {
-        TouchScreenType type = TouchScreenType.getEnum(value);
-        if (type != null) {
-            TouchScreenQualifier qualifier = new TouchScreenQualifier();
-            qualifier.mValue = type;
-            config.setTouchTypeQualifier(qualifier);
-            return true;
-        }
-        
-        return false;
-    }
-    
-    @Override
-    public boolean equals(Object qualifier) {
-        if (qualifier instanceof TouchScreenQualifier) {
-            return mValue == ((TouchScreenQualifier)qualifier).mValue;
-        }
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        if (mValue != null) {
-            return mValue.hashCode();
-        }
-        
-        return 0;
-    }
-
-    /**
-     * Returns the string used to represent this qualifier in the folder name.
-     */
-    @Override
-    public String toString() {
-        if (mValue != null) {
-            return mValue.getValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-
-    @Override
-    public String getStringValue() {
-        if (mValue != null) {
-            return mValue.getDisplayValue();
-        }
-        
-        return ""; //$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ColorValueDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ColorValueDescriptor.java
deleted file mode 100644
index 92288ba..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ColorValueDescriptor.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.TextValueDescriptor;
-import com.android.ide.eclipse.editors.resources.uimodel.UiColorValueNode;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiResourceAttributeNode;
-
-/**
- * Describes a Color XML element value displayed by an {@link UiColorValueNode}.
- */
-public final class ColorValueDescriptor extends TextValueDescriptor {
-
-    public ColorValueDescriptor(String uiName, String tooltip) {
-        super(uiName, tooltip);
-    }
-    
-    /**
-     * @return A new {@link UiResourceAttributeNode} linked to this theme descriptor.
-     */
-    @Override
-    public UiAttributeNode createUiNode(UiElementNode uiParent) {
-        return new UiColorValueNode(this, uiParent);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ItemElementDescriptor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ItemElementDescriptor.java
deleted file mode 100644
index bf83d52..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ItemElementDescriptor.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.descriptors;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.resources.uimodel.UiItemElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-/**
- * {@link ItemElementDescriptor} is a special version of {@link ElementDescriptor} that
- * uses a specialized {@link UiItemElementNode} for display.
- */
-public class ItemElementDescriptor extends ElementDescriptor {
-
-    /**
-     * Constructs a new {@link ItemElementDescriptor} based on its XML name, UI name,
-     * tooltip, SDK url, attributes list, children list and mandatory.
-     * 
-     * @param xml_name The XML element node name. Case sensitive.
-     * @param ui_name The XML element name for the user interface, typically capitalized.
-     * @param tooltip An optional tooltip. Can be null or empty.
-     * @param sdk_url An optional SKD URL. Can be null or empty.
-     * @param attributes The list of allowed attributes. Can be null or empty.
-     * @param children The list of allowed children. Can be null or empty.
-     * @param mandatory Whether this node must always exist (even for empty models). A mandatory
-     *  UI node is never deleted and it may lack an actual XML node attached. A non-mandatory
-     *  UI node MUST have an XML node attached and it will cease to exist when the XML node
-     *  ceases to exist.
-     */
-    public ItemElementDescriptor(String xml_name, String ui_name,
-            String tooltip, String sdk_url, AttributeDescriptor[] attributes,
-            ElementDescriptor[] children, boolean mandatory) {
-        super(xml_name, ui_name, tooltip, sdk_url, attributes, children, mandatory);
-    }
-
-    @Override
-    public UiElementNode createUiNode() {
-        return new UiItemElementNode(this);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ResourcesDescriptors.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ResourcesDescriptors.java
deleted file mode 100644
index 1075897..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/descriptors/ResourcesDescriptors.java
+++ /dev/null
@@ -1,283 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.descriptors;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.FlagAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.ListAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextValueDescriptor;
-
-
-/**
- * Complete description of the structure for resources XML files (under res/values/)
- */
-public class ResourcesDescriptors implements IDescriptorProvider {
-
-    // Public attributes names, attributes descriptors and elements descriptors
-
-    public static final String ROOT_ELEMENT = "resources";  //$NON-NLS-1$
-
-    public static final String NAME_ATTR = "name"; //$NON-NLS-1$
-    public static final String TYPE_ATTR = "type"; //$NON-NLS-1$
-
-    private static final ResourcesDescriptors sThis = new ResourcesDescriptors();
-
-    /** The {@link ElementDescriptor} for the root Resources element. */
-    public final ElementDescriptor mResourcesElement;
-
-    public static ResourcesDescriptors getInstance() {
-        return sThis;
-    }
-    
-    /*
-     * @see com.android.ide.eclipse.editors.descriptors.IDescriptorProvider#getRootElementDescriptors()
-     */
-    public ElementDescriptor[] getRootElementDescriptors() {
-        return new ElementDescriptor[] { mResourcesElement };
-    }
-    
-    public ElementDescriptor getDescriptor() {
-        return mResourcesElement;
-    }
-    
-    public ElementDescriptor getElementDescriptor() {
-        return mResourcesElement;
-    }
-    
-    private ResourcesDescriptors() {
-
-        // Common attributes used in many placed
-
-        // Elements
-
-         ElementDescriptor color_element = new ElementDescriptor(
-                "color", //$NON-NLS-1$
-                "Color", 
-                "A @color@ value specifies an RGB value with an alpha channel, which can be used in various places such as specifying a solid color for a Drawable or the color to use for text.  It always begins with a # character and then is followed by the alpha-red-green-blue information in one of the following formats: #RGB, #ARGB, #RRGGBB or #AARRGGBB.",
-                "http://code.google.com/android/reference/available-resources.html#colorvals",  //$NON-NLS-1$
-                new AttributeDescriptor[] {
-                        new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this color."),
-                        new ColorValueDescriptor(
-                                "Value*",
-                                "A mandatory color value.")
-                },
-                null,  // no child nodes
-                false /* not mandatory */);
-
-         ElementDescriptor string_element = new ElementDescriptor(
-                "string", //$NON-NLS-1$
-                "String", 
-                "@Strings@, with optional simple formatting, can be stored and retrieved as resources. You can add formatting to your string by using three standard HTML tags: b, i, and u. If you use an apostrophe or a quote in your string, you must either escape it or enclose the whole string in the other kind of enclosing quotes.",
-                "http://code.google.com/android/reference/available-resources.html#stringresources",  //$NON-NLS-1$
-                new AttributeDescriptor[] {
-                        new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this string."),
-                        new TextValueDescriptor(
-                                "Value*",
-                                "A mandatory string value.")
-                },
-                null,  // no child nodes
-                false /* not mandatory */);
-
-         ElementDescriptor item_element = new ItemElementDescriptor(
-                 "item", //$NON-NLS-1$
-                 "Item", 
-                 null,  // TODO find javadoc
-                 null,  // TODO find link to javadoc
-                 new AttributeDescriptor[] {
-                         new TextAttributeDescriptor(NAME_ATTR,
-                                 "Name*",
-                                 null /* nsUri */,
-                                 "The mandatory name used in referring to this resource."),
-                         new ListAttributeDescriptor(TYPE_ATTR,
-                                 "Type*",
-                                 null /* nsUri */,
-                                 "The mandatory type of this resource.",
-                                 ResourceType.getNames()
-                         ),
-                         new FlagAttributeDescriptor("format",
-                                 "Format",
-                                 null /* nsUri */,
-                                 "The optional format of this resource.",
-                                 new String[] {
-                                     "boolean",     //$NON-NLS-1$
-                                     "color",       //$NON-NLS-1$
-                                     "dimension",   //$NON-NLS-1$
-                                     "float",       //$NON-NLS-1$
-                                     "fraction",    //$NON-NLS-1$
-                                     "integer",     //$NON-NLS-1$
-                                     "reference",   //$NON-NLS-1$
-                                     "string"       //$NON-NLS-1$
-                         }),
-                         new TextValueDescriptor(
-                                 "Value",
-                                 "A standard string, hex color value, or reference to any other resource type.")
-                 },
-                 null,  // no child nodes
-                 false /* not mandatory */);
-
-         ElementDescriptor drawable_element = new ElementDescriptor(
-                "drawable", //$NON-NLS-1$
-                "Drawable", 
-                "A @drawable@ defines a rectangle of color. Android accepts color values written in various web-style formats -- a hexadecimal constant in any of the following forms: #RGB, #ARGB, #RRGGBB, #AARRGGBB. Zero in the alpha channel means transparent. The default value is opaque.",
-                "http://code.google.com/android/reference/available-resources.html#colordrawableresources",  //$NON-NLS-1$
-                new AttributeDescriptor[] {
-                        new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this drawable."),
-                        new TextValueDescriptor(
-                                "Value*",
-                                "A mandatory color value in the form #RGB, #ARGB, #RRGGBB or #AARRGGBB.")
-                },
-                null,  // no child nodes
-                false /* not mandatory */);
-
-         ElementDescriptor dimen_element = new ElementDescriptor(
-                "dimen", //$NON-NLS-1$
-                "Dimension", 
-                "You can create common dimensions to use for various screen elements by defining @dimension@ values in XML. A dimension resource is a number followed by a unit of measurement. Supported units are px (pixels), in (inches), mm (millimeters), pt (points at 72 DPI), dp (density-independent pixels) and sp (scale-independent pixels)",
-                "http://code.google.com/android/reference/available-resources.html#dimension",  //$NON-NLS-1$
-                new AttributeDescriptor[] {
-                        new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this dimension."),
-                        new TextValueDescriptor(
-                                "Value*",
-                                "A mandatory dimension value is a number followed by a unit of measurement. For example: 10px, 2in, 5sp.")
-                },
-                null,  // no child nodes
-                false /* not mandatory */);
-
-         ElementDescriptor style_element = new ElementDescriptor(
-                "style", //$NON-NLS-1$
-                "Style/Theme", 
-                "Both @styles and themes@ are defined in a style block containing one or more string or numerical values (typically color values), or references to other resources (drawables and so on).",
-                "http://code.google.com/android/reference/available-resources.html#stylesandthemes",  //$NON-NLS-1$
-                new AttributeDescriptor[] {
-                        new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this theme."),
-                        new TextAttributeDescriptor("parent", // $NON-NLS-1$
-                                "Parent",
-                                null /* nsUri */,
-                                "An optional parent theme. All values from the specified theme will be inherited into this theme. Any values with identical names that you specify will override inherited values."),
-                },
-                new ElementDescriptor[] {
-                    new ElementDescriptor(
-                        "item", //$NON-NLS-1$
-                        "Item", 
-                        "A value to use in this @theme@. It can be a standard string, a hex color value, or a reference to any other resource type.",
-                        "http://code.google.com/android/reference/available-resources.html#stylesandthemes",  //$NON-NLS-1$
-                        new AttributeDescriptor[] {
-                            new TextAttributeDescriptor(NAME_ATTR,
-                                "Name*",
-                                null /* nsUri */,
-                                "The mandatory name used in referring to this item."),
-                            new TextValueDescriptor(
-                                "Value*",
-                                "A mandatory standard string, hex color value, or reference to any other resource type.")
-                        },
-                        null,  // no child nodes
-                        false /* not mandatory */)
-                },
-                false /* not mandatory */);
-
-         ElementDescriptor string_array_element = new ElementDescriptor(
-                 "string-array", //$NON-NLS-1$
-                 "String Array",
-                 "An array of strings. Strings are added as underlying item elements to the array.",
-                 null, // tooltips
-                 new AttributeDescriptor[] {
-                         new TextAttributeDescriptor(NAME_ATTR,
-                                 "Name*",
-                                 null /* nsUri */,
-                                 "The mandatory name used in referring to this string array."),
-                 },
-                 new ElementDescriptor[] {
-                     new ElementDescriptor(
-                         "item", //$NON-NLS-1$
-                         "Item", 
-                         "A string value to use in this string array.",
-                         null, // tooltip
-                         new AttributeDescriptor[] {
-                             new TextValueDescriptor(
-                                 "Value*",
-                                 "A mandatory string.")
-                         },
-                         null,  // no child nodes
-                         false /* not mandatory */)
-                 },
-                 false /* not mandatory */);
-
-         ElementDescriptor integer_array_element = new ElementDescriptor(
-                 "integer-array", //$NON-NLS-1$
-                 "Integer Array",
-                 "An array of integers. Integers are added as underlying item elements to the array.",
-                 null, // tooltips
-                 new AttributeDescriptor[] {
-                         new TextAttributeDescriptor(NAME_ATTR,
-                                 "Name*",
-                                 null /* nsUri */,
-                                 "The mandatory name used in referring to this integer array."),
-                 },
-                 new ElementDescriptor[] {
-                     new ElementDescriptor(
-                         "item", //$NON-NLS-1$
-                         "Item", 
-                         "An integer value to use in this integer array.",
-                         null, // tooltip
-                         new AttributeDescriptor[] {
-                             new TextValueDescriptor(
-                                 "Value*",
-                                 "A mandatory integer.")
-                         },
-                         null,  // no child nodes
-                         false /* not mandatory */)
-                 },
-                 false /* not mandatory */);
-
-         mResourcesElement = new ElementDescriptor(
-                        ROOT_ELEMENT,
-                        "Resources", 
-                        null,
-                        "http://code.google.com/android/reference/available-resources.html",  //$NON-NLS-1$
-                        null,  // no attributes
-                        new ElementDescriptor[] {
-                                string_element,
-                                color_element,
-                                dimen_element,
-                                drawable_element,
-                                style_element,
-                                item_element,
-                                string_array_element,
-                                integer_array_element,
-                        },
-                        true /* mandatory */);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/explorer/ResourceExplorerView.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/explorer/ResourceExplorerView.java
deleted file mode 100644
index d1d8891..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/explorer/ResourceExplorerView.java
+++ /dev/null
@@ -1,340 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.explorer;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResourceItem;
-import com.android.ide.eclipse.editors.resources.manager.ProjectResources;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFile;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IResourceEventListener;
-import com.android.ide.eclipse.editors.wizards.ResourceContentProvider;
-import com.android.ide.eclipse.editors.wizards.ResourceLabelProvider;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeColumn;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.ISelectionListener;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.part.ViewPart;
-
-import java.util.Iterator;
-
-/**
- * Resource Explorer View.
- * <p/>
- * This contains a basic Tree view, and uses a TreeViewer to handle the data.
- * <p/>
- * The view listener to change in selection in the workbench, and update to show the resource
- * of the project of the current selected item (either item in the package explorer, or of the
- * current editor).
- * 
- * @see ResourceContentProvider
- */
-public class ResourceExplorerView extends ViewPart implements ISelectionListener,
-        IResourceEventListener {
-    
-    // Note: keep using the obsolete AndroidConstants.EDITORS_NAMESPACE (which used
-    // to be the Editors Plugin ID) to keep existing preferences functional.
-    private final static String PREFS_COLUMN_RES =
-        AndroidConstants.EDITORS_NAMESPACE + "ResourceExplorer.Col1"; //$NON-NLS-1$
-    private final static String PREFS_COLUMN_2 =
-        AndroidConstants.EDITORS_NAMESPACE + "ResourceExplorer.Col2"; //$NON-NLS-1$
-
-    private Tree mTree;
-    private TreeViewer mTreeViewer;
-    
-    private IProject mCurrentProject;
-
-    public ResourceExplorerView() {
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mTree = new Tree(parent, SWT.SINGLE | SWT.VIRTUAL);
-        mTree.setLayoutData(new GridData(GridData.FILL_BOTH));
-        mTree.setHeaderVisible(true);
-        mTree.setLinesVisible(true);
-
-        final IPreferenceStore store = AdtPlugin.getDefault().getPreferenceStore();
-
-        // create 2 columns. The main one with the resources, and an "info" column.
-        createTreeColumn(mTree, "Resources", SWT.LEFT,
-                "abcdefghijklmnopqrstuvwxz", -1, PREFS_COLUMN_RES, store); //$NON-NLS-1$
-        createTreeColumn(mTree, "Info", SWT.LEFT,
-                "0123456789", -1, PREFS_COLUMN_2, store); //$NON-NLS-1$
-
-        // create the jface wrapper
-        mTreeViewer = new TreeViewer(mTree);
-        
-        mTreeViewer.setContentProvider(new ResourceContentProvider(true /* fullLevels */));
-        mTreeViewer.setLabelProvider(new ResourceLabelProvider());
-        
-        // listen to selection change in the workbench.
-        IWorkbenchPage page = getSite().getPage();
-        
-        page.addSelectionListener(this);
-        
-        // init with current selection
-        selectionChanged(getSite().getPart(), page.getSelection());
-        
-        // add support for double click.
-        mTreeViewer.addDoubleClickListener(new IDoubleClickListener() {
-            public void doubleClick(DoubleClickEvent event) {
-                ISelection sel = event.getSelection();
-
-                if (sel instanceof IStructuredSelection) {
-                    IStructuredSelection selection = (IStructuredSelection) sel;
-
-                    if (selection.size() == 1) {
-                        Object element = selection.getFirstElement();
-                        
-                        // if it's a resourceFile, we directly open it.
-                        if (element instanceof ResourceFile) {
-                            try {
-                                IDE.openEditor(getSite().getWorkbenchWindow().getActivePage(),
-                                        ((ResourceFile)element).getFile().getIFile());
-                            } catch (PartInitException e) {
-                            }
-                        } else if (element instanceof ProjectResourceItem) {
-                            // if it's a ResourceItem, we open the first file, but only if
-                            // there's no alternate files.
-                            ProjectResourceItem item = (ProjectResourceItem)element;
-                            
-                            if (item.isEditableDirectly()) {
-                                ResourceFile[] files = item.getSourceFileArray();
-                                if (files[0] != null) {
-                                    try {
-                                        IDE.openEditor(
-                                                getSite().getWorkbenchWindow().getActivePage(),
-                                                files[0].getFile().getIFile());
-                                    } catch (PartInitException e) {
-                                    }
-                                }
-                            }
-                        }
-                    }
-                }
-            }
-        });
-        
-        // set up the resource manager to send us resource change notification
-        AdtPlugin.getDefault().getResourceMonitor().addResourceEventListener(this);
-    }
-    
-    @Override
-    public void dispose() {
-        AdtPlugin.getDefault().getResourceMonitor().removeResourceEventListener(this);
-
-        super.dispose();
-    }
-
-    @Override
-    public void setFocus() {
-        mTree.setFocus();
-    }
-
-    /**
-     * Processes a new selection.
-     */
-    public void selectionChanged(IWorkbenchPart part, ISelection selection) {
-        // first we test if the part is an editor.
-        if (part instanceof IEditorPart) {
-            // if it is, we check if it's a file editor.
-            IEditorInput input = ((IEditorPart)part).getEditorInput();
-            
-            if (input instanceof IFileEditorInput) {
-                // from the file editor we can get the IFile object, and from it, the IProject.
-                IFile file = ((IFileEditorInput)input).getFile();
-                
-                // get the file project
-                IProject project = file.getProject();
-                
-                handleProjectSelection(project);
-            }
-        } else if (selection instanceof IStructuredSelection) {
-            // if it's not an editor, we look for structured selection.
-            for (Iterator<?> it = ((IStructuredSelection) selection).iterator();
-                    it.hasNext();) {
-                Object element = it.next();
-                IProject project = null;
-                
-                // if we are in the navigator or package explorer, the selection could contain a
-                // IResource object.
-                if (element instanceof IResource) {
-                    project = ((IResource) element).getProject();
-                } else if (element instanceof IJavaElement) {
-                    // if we are in the package explorer on a java element, we handle that too.
-                    IJavaElement javaElement = (IJavaElement)element;
-                    IJavaProject javaProject = javaElement.getJavaProject();
-                    if (javaProject != null) {
-                        project = javaProject.getProject();
-                    }
-                } else if (element instanceof IAdaptable) {
-                    // finally we try to get a project object from IAdaptable.
-                    project = (IProject) ((IAdaptable) element)
-                            .getAdapter(IProject.class);
-                }
-
-                // if we found a project, handle it, and return.
-                if (project != null) {
-                    if (handleProjectSelection(project)) {
-                        return;
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Handles a project selection.
-     * @param project the new selected project
-     * @return true if the project could be processed.
-     */
-    private boolean handleProjectSelection(IProject project) {
-        try {
-            // if it's an android project, then we get its resources, and feed them
-            // to the tree viewer.
-            if (project.hasNature(AndroidConstants.NATURE)) {
-                if (mCurrentProject != project) {
-                    ProjectResources projRes = ResourceManager.getInstance().getProjectResources(
-                            project);
-                    if (projRes != null) {
-                        mTreeViewer.setInput(projRes);
-                        mCurrentProject = project;
-                        return true;
-                    }
-                }
-            }
-        } catch (CoreException e) {
-        }
-        
-        return false;
-    }
-    
-    /**
-     * Create a TreeColumn with the specified parameters. If a
-     * <code>PreferenceStore</code> object and a preference entry name String
-     * object are provided then the column will listen to change in its width
-     * and update the preference store accordingly.
-     *
-     * @param parent The Table parent object
-     * @param header The header string
-     * @param style The column style
-     * @param sample_text A sample text to figure out column width if preference
-     *            value is missing
-     * @param fixedSize a fixed size. If != -1 the column is non resizable
-     * @param pref_name The preference entry name for column width
-     * @param prefs The preference store
-     */
-    public void createTreeColumn(Tree parent, String header, int style,
-            String sample_text, int fixedSize, final String pref_name,
-            final IPreferenceStore prefs) {
-
-        // create the column
-        TreeColumn col = new TreeColumn(parent, style);
-        
-        if (fixedSize != -1) {
-            col.setWidth(fixedSize);
-            col.setResizable(false);
-        } else {
-            // if there is no pref store or the entry is missing, we use the sample
-            // text and pack the column.
-            // Otherwise we just read the width from the prefs and apply it.
-            if (prefs == null || prefs.contains(pref_name) == false) {
-                col.setText(sample_text);
-                col.pack();
-    
-                // init the prefs store with the current value
-                if (prefs != null) {
-                    prefs.setValue(pref_name, col.getWidth());
-                }
-            } else {
-                col.setWidth(prefs.getInt(pref_name));
-            }
-    
-            // if there is a pref store and a pref entry name, then we setup a
-            // listener to catch column resize to put the new width value into the store.
-            if (prefs != null && pref_name != null) {
-                col.addControlListener(new ControlListener() {
-                    public void controlMoved(ControlEvent e) {
-                    }
-    
-                    public void controlResized(ControlEvent e) {
-                        // get the new width
-                        int w = ((TreeColumn)e.widget).getWidth();
-    
-                        // store in pref store
-                        prefs.setValue(pref_name, w);
-                    }
-                });
-            }
-        }
-
-        // set the header
-        col.setText(header);
-    }
-
-    /**
-     * Processes a start in a resource event change.
-     */
-    public void resourceChangeEventStart() {
-        // pass
-    }
-
-    /**
-     * Processes the end of a resource change event.
-     */
-    public void resourceChangeEventEnd() {
-        try {
-            mTree.getDisplay().asyncExec(new Runnable() {
-                public void run() {
-                    if (mTree.isDisposed() == false) {
-                        mTreeViewer.refresh();
-                    }
-                }
-            });
-        } catch (SWTException e) {
-            // display is disposed. nothing to do.
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/CompiledResourcesMonitor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/CompiledResourcesMonitor.java
deleted file mode 100644
index 455c825..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/CompiledResourcesMonitor.java
+++ /dev/null
@@ -1,211 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.AndroidManifestHelper;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IProjectListener;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.runtime.CoreException;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * A monitor for the compiled resources. This only monitors changes in the resources of type
- *  {@link ResourceType#ID}.
- */
-public final class CompiledResourcesMonitor implements IFileListener, IProjectListener {
-
-    private final static CompiledResourcesMonitor sThis = new CompiledResourcesMonitor();
-    
-    /**
-     * Sets up the monitoring system.
-     * @param monitor The main Resource Monitor.
-     */
-    public static void setupMonitor(ResourceMonitor monitor) {
-        monitor.addFileListener(sThis, IResourceDelta.ADDED | IResourceDelta.CHANGED);
-        monitor.addProjectListener(sThis);
-    }
-
-    /**
-     * private constructor to prevent construction.
-     */
-    private CompiledResourcesMonitor() {
-    }
-
-
-    /* (non-Javadoc)
-     * Sent when a file changed : if the file is the R class, then it is parsed again to update
-     * the internal data.
-     * 
-     * @param file The file that changed.
-     * @param markerDeltas The marker deltas for the file.
-     * @param kind The change kind. This is equivalent to
-     * {@link IResourceDelta#accept(IResourceDeltaVisitor)}
-     * 
-     * @see IFileListener#fileChanged
-     */
-    public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind) {
-        if (file.getName().equals(AndroidConstants.FN_COMPILED_RESOURCE_CLASS)) {
-            loadAndParseRClass(file.getProject());
-        }
-    }
-
-    /**
-     * Processes project close event.
-     */
-    public void projectClosed(IProject project) {
-        // the ProjectResources object will be removed by the ResourceManager.
-    }
-
-    /**
-     * Processes project delete event.
-     */
-    public void projectDeleted(IProject project) {
-        // the ProjectResources object will be removed by the ResourceManager.
-    }
-
-    /**
-     * Processes project open event.
-     */
-    public void projectOpened(IProject project) {
-        // when the project is opened, we get an ADDED event for each file, so we don't
-        // need to do anything here.
-    }
-
-    /**
-     * Processes existing project at init time.
-     */
-    public void projectOpenedWithWorkspace(IProject project) {
-        try {
-            // check this is an android project
-            if (project.hasNature(AndroidConstants.NATURE)) {
-                loadAndParseRClass(project);
-            }
-        } catch (CoreException e) {
-            // pass
-        }
-    }
-    
-    private void loadAndParseRClass(IProject project) {
-        try {
-            // first check there's a ProjectResources to store the content
-            ProjectResources projectResources = ResourceManager.getInstance().getProjectResources(
-                    project);
-
-            if (projectResources != null) {
-                // create the classname
-                String className = getRClassName(project);
-        
-                // create a temporary class loader to load it. 
-                ProjectClassLoader loader = new ProjectClassLoader(null /* parentClassLoader */,
-                        project);
-                
-                try {
-                    Class<?> clazz = loader.loadClass(className);
-                    
-                    if (clazz != null) {
-                        // create the maps to store the result of the parsing
-                        Map<String, Map<String, Integer>> resourceValueMap =
-                            new HashMap<String, Map<String, Integer>>();
-                        Map<Integer, String[]> genericValueToNameMap =
-                            new HashMap<Integer, String[]>();
-                        Map<IntArrayWrapper, String> styleableValueToNameMap =
-                            new HashMap<IntArrayWrapper, String>();
-                        
-                        // parse the class
-                        if (parseClass(clazz, genericValueToNameMap, styleableValueToNameMap,
-                                resourceValueMap)) {
-                            // now we associate the maps to the project.
-                            projectResources.setCompiledResources(genericValueToNameMap,
-                                    styleableValueToNameMap, resourceValueMap);
-                        }
-                    }
-                } catch (Error e) {
-                    // Log this error with the class name we're trying to load and abort.
-                    AdtPlugin.log(e, "loadAndParseRClass failed to find class %1$s", className); //$NON-NLS-1$
-                }
-            }
-        } catch (ClassNotFoundException e) {
-            // pass
-        }
-    }
-
-    /**
-     * Parses a R class, and fills maps.
-     * @param rClass the class to parse
-     * @param genericValueToNameMap
-     * @param styleableValueToNameMap
-     * @param resourceValueMap
-     * @return True if we managed to parse the R class.
-     */
-    private boolean parseClass(Class<?> rClass, Map<Integer, String[]> genericValueToNameMap,
-            Map<IntArrayWrapper, String> styleableValueToNameMap, Map<String,
-            Map<String, Integer>> resourceValueMap) {
-        try {
-            for (Class<?> inner : rClass.getDeclaredClasses()) {
-                String resType = inner.getSimpleName();
-
-                Map<String, Integer> fullMap = new HashMap<String, Integer>();
-                resourceValueMap.put(resType, fullMap);
-                
-                for (Field f : inner.getDeclaredFields()) {
-                    // only process static final fields.
-                    int modifiers = f.getModifiers();
-                    if (Modifier.isStatic(modifiers) && Modifier.isFinal(modifiers)) {
-                        Class<?> type = f.getType();
-                        if (type.isArray() && type.getComponentType() == int.class) {
-                            // if the object is an int[] we put it in the styleable map
-                            styleableValueToNameMap.put(new IntArrayWrapper((int[]) f.get(null)),
-                                    f.getName());
-                        } else if (type == int.class) {
-                            Integer value = (Integer) f.get(null); 
-                            genericValueToNameMap.put(value, new String[] { f.getName(), resType });
-                            fullMap.put(f.getName(), value);
-                        } else {
-                            assert false;
-                        }
-                    }
-                }
-            }
-
-            return true;
-        } catch (IllegalArgumentException e) {
-        } catch (IllegalAccessException e) {
-        }
-        return false;
-    }
-    
-    private String getRClassName(IProject project) {
-        // create the classname
-        AndroidManifestHelper manifest = new AndroidManifestHelper(project);
-        String javaPackage = manifest.getPackageName();
-        
-        return javaPackage + ".R"; //$NON-NLS-1$
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ConfigurableResourceItem.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ConfigurableResourceItem.java
deleted file mode 100644
index 57c17fc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ConfigurableResourceItem.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-/**
- * Represents a resource item that can exist in multiple "alternate" versions. 
- */
-public class ConfigurableResourceItem extends ProjectResourceItem {
-    
-    /**
-     * Constructs a new Resource Item.
-     * @param name the name of the resource as it appears in the XML and R.java files.
-     */
-    public ConfigurableResourceItem(String name) {
-        super(name);
-    }
-
-    /**
-     * Returns if the resource item has at least one non-default configuration.
-     */
-    public boolean hasAlternates() {
-        for (ResourceFile file : mFiles) {
-            if (file.getFolder().getConfiguration().isDefault() == false) {
-                return true;
-            }
-        }
-        
-        return false;
-    }
-
-    /**
-     * Returns whether the resource has a default version, with no qualifier.
-     */
-    public boolean hasDefault() {
-        for (ResourceFile file : mFiles) {
-            if (file.getFolder().getConfiguration().isDefault()) {
-                return true;
-            }
-        }
-        
-        // We only want to return false if there's no default and more than 0 items.
-        return (mFiles.size() == 0);
-    }
-
-    /**
-     * Returns the number of alternate versions of this resource.
-     */
-    public int getAlternateCount() {
-        int count = 0;
-        for (ResourceFile file : mFiles) {
-            if (file.getFolder().getConfiguration().isDefault() == false) {
-                count++;
-            }
-        }
-
-        return count;
-    }
-
-    /*
-     * (non-Javadoc)
-     * Returns whether the item can be edited directly (ie it does not have alternate versions).
-     */
-    @Override
-    public boolean isEditableDirectly() {
-        return hasAlternates() == false;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/FolderTypeRelationship.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/FolderTypeRelationship.java
deleted file mode 100644
index a9f80bd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/FolderTypeRelationship.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Set;
-
-/**
- * This class gives access to the bi directional relationship between {@link ResourceType} and
- * {@link ResourceFolderType}.
- */
-public final class FolderTypeRelationship {
-    
-    private final static HashMap<ResourceType, ResourceFolderType[]> mTypeToFolderMap =
-        new HashMap<ResourceType, ResourceFolderType[]>();
-        
-    private final static HashMap<ResourceFolderType, ResourceType[]> mFolderToTypeMap =
-        new HashMap<ResourceFolderType, ResourceType[]>();
-    
-    // generate the relationships.
-    static {
-        HashMap<ResourceType, List<ResourceFolderType>> typeToFolderMap =
-            new HashMap<ResourceType, List<ResourceFolderType>>();
-        
-        HashMap<ResourceFolderType, List<ResourceType>> folderToTypeMap =
-            new HashMap<ResourceFolderType, List<ResourceType>>();
-
-        add(ResourceType.ANIM, ResourceFolderType.ANIM, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.ARRAY, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.COLOR, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.COLOR, ResourceFolderType.COLOR, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.DIMEN, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.DRAWABLE, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.DRAWABLE, ResourceFolderType.DRAWABLE, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.ID, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.LAYOUT, ResourceFolderType.LAYOUT, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.MENU, ResourceFolderType.MENU, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.RAW, ResourceFolderType.RAW, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.STRING, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.STYLE, ResourceFolderType.VALUES, typeToFolderMap, folderToTypeMap);
-        add(ResourceType.XML, ResourceFolderType.XML, typeToFolderMap, folderToTypeMap);
-        
-        optimize(typeToFolderMap, folderToTypeMap);
-    }
-    
-    /**
-     * Returns a list of {@link ResourceType}s that can be generated from files inside a folder
-     * of the specified type.
-     * @param folderType The folder type.
-     * @return an array of {@link ResourceType}
-     */
-    public static ResourceType[] getRelatedResourceTypes(ResourceFolderType folderType) {
-        ResourceType[] array = mFolderToTypeMap.get(folderType);
-        if (array != null) {
-            return array;
-        }
-        return new ResourceType[0];
-    }
-    
-    /**
-     * Returns a list of {@link ResourceFolderType} that can contain files generating resources
-     * of the specified type.
-     * @param resType the type of resource.
-     * @return an array of {@link ResourceFolderType}
-     */
-    public static ResourceFolderType[] getRelatedFolders(ResourceType resType) {
-        ResourceFolderType[] array = mTypeToFolderMap.get(resType);
-        if (array != null) {
-            return array;
-        }
-        return new ResourceFolderType[0];
-    }
-    
-    /**
-     * Returns true if the {@link ResourceType} and the {@link ResourceFolderType} values match.
-     * @param resType the resource type.
-     * @param folderType the folder type.
-     * @return true if files inside the folder of the specified {@link ResourceFolderType}
-     * could generate a resource of the specified {@link ResourceType}
-     */
-    public static boolean match(ResourceType resType, ResourceFolderType folderType) {
-        ResourceFolderType[] array = mTypeToFolderMap.get(resType);
-        
-        if (array != null && array.length > 0) {
-            for (ResourceFolderType fType : array) {
-                if (fType == folderType) {
-                    return true;
-                }
-            }
-        }
-        
-        return false;
-    }
-    
-    /**
-     * Adds a {@link ResourceType} - {@link ResourceFolderType} relationship. this indicates that
-     * a file in the folder can generate a resource of the specified type.
-     * @param type The resourceType
-     * @param folder The {@link ResourceFolderType}
-     * @param folderToTypeMap 
-     * @param typeToFolderMap 
-     */
-    private static void add(ResourceType type, ResourceFolderType folder,
-            HashMap<ResourceType, List<ResourceFolderType>> typeToFolderMap,
-            HashMap<ResourceFolderType, List<ResourceType>> folderToTypeMap) {
-        // first we add the folder to the list associated with the type.
-        List<ResourceFolderType> folderList = typeToFolderMap.get(type);
-        if (folderList == null) {
-            folderList = new ArrayList<ResourceFolderType>();
-            typeToFolderMap.put(type, folderList);
-        }
-        if (folderList.indexOf(folder) == -1) {
-            folderList.add(folder);
-        }
-        
-        // now we add the type to the list associated with the folder.
-        List<ResourceType> typeList = folderToTypeMap.get(folder);
-        if (typeList == null) {
-            typeList = new ArrayList<ResourceType>();
-            folderToTypeMap.put(folder, typeList);
-        }
-        if (typeList.indexOf(type) == -1) {
-            typeList.add(type);
-        }
-    }
-
-    /**
-     * Optimize the map to contains array instead of lists (since the api returns arrays)
-     * @param typeToFolderMap
-     * @param folderToTypeMap
-     */
-    private static void optimize(HashMap<ResourceType, List<ResourceFolderType>> typeToFolderMap,
-            HashMap<ResourceFolderType, List<ResourceType>> folderToTypeMap) {
-        Set<ResourceType> types = typeToFolderMap.keySet();
-        for (ResourceType type : types) {
-            List<ResourceFolderType> list = typeToFolderMap.get(type);
-            mTypeToFolderMap.put(type, list.toArray(new ResourceFolderType[list.size()]));
-        }
-
-        Set<ResourceFolderType> folders = folderToTypeMap.keySet();
-        for (ResourceFolderType folder : folders) {
-            List<ResourceType> list = folderToTypeMap.get(folder);
-            mFolderToTypeMap.put(folder, list.toArray(new ResourceType[list.size()]));
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IdResourceItem.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IdResourceItem.java
deleted file mode 100644
index 552aec9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IdResourceItem.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.IIdResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-
-/**
- * Represents a resource item of type {@link ResourceType#ID}
- */
-public class IdResourceItem extends ProjectResourceItem implements IIdResourceItem {
-
-    private final boolean mIsDeclaredInline;
-
-    /**
-     * Constructs a new ResourceItem.
-     * @param name the name of the resource as it appears in the XML and R.java files.
-     * @param isDeclaredInline Whether this id was declared inline.
-     */
-    IdResourceItem(String name, boolean isDeclaredInline) {
-        super(name);
-        mIsDeclaredInline = isDeclaredInline;
-    }
-
-    /*
-     * (non-Javadoc)
-     * Returns whether the ID resource has been declared inline inside another resource XML file. 
-     */
-    public boolean isDeclaredInline() {
-        return mIsDeclaredInline;
-    }
-
-    /* (non-Javadoc)
-     * Returns whether the item can be edited (ie, the id was not declared inline).
-     */
-    @Override
-    public boolean isEditableDirectly() {
-        return !mIsDeclaredInline;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IntArrayWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IntArrayWrapper.java
deleted file mode 100644
index 25eb112..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/IntArrayWrapper.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import java.util.Arrays;
-
-
-/**
- * Wrapper around a int[] to provide hashCode/equals support.
- */
-public final class IntArrayWrapper {
-    
-    private int[] mData;
-    
-    public IntArrayWrapper(int[] data) {
-        mData = data;
-    }
-    
-    public void set(int[] data) {
-        mData = data;
-    }
-    
-    @Override
-    public int hashCode() {
-        return Arrays.hashCode(mData);
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (getClass().equals(obj.getClass())) {
-            return Arrays.equals(mData, ((IntArrayWrapper)obj).mData);
-        }
-
-        return super.equals(obj);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/MultiResourceFile.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/MultiResourceFile.java
deleted file mode 100644
index 3812791..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/MultiResourceFile.java
+++ /dev/null
@@ -1,174 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFile;
-import com.android.layoutlib.api.IResourceValue;
-import com.android.layoutlib.utils.ResourceValue;
-import com.android.layoutlib.utils.ValueResourceParser;
-import com.android.layoutlib.utils.ValueResourceParser.IValueResourceRepository;
-
-import org.eclipse.core.runtime.CoreException;
-import org.xml.sax.SAXException;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Set;
-
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * Represents a resource file able to declare multiple resources, which could be of
- * different {@link ResourceType}.
- * <p/>
- * This is typically an XML file inside res/values.
- */
-public final class MultiResourceFile extends ResourceFile implements IValueResourceRepository {
-
-    private final static SAXParserFactory sParserFactory = SAXParserFactory.newInstance();
-    
-    private final HashMap<ResourceType, HashMap<String, ResourceValue>> mResourceItems =
-        new HashMap<ResourceType, HashMap<String, ResourceValue>>();
-
-    public MultiResourceFile(IAbstractFile file, ResourceFolder folder) {
-        super(file, folder);
-    }
-
-    @Override
-    public ResourceType[] getResourceTypes() {
-        update();
-
-        Set<ResourceType> keys = mResourceItems.keySet();
-        
-        return keys.toArray(new ResourceType[keys.size()]);
-    }
-
-    @Override
-    public boolean hasResources(ResourceType type) {
-        update();
-
-        HashMap<String, ResourceValue> list = mResourceItems.get(type);
-        return (list != null && list.size() > 0);
-    }
-    
-    @Override
-    public Collection<ProjectResourceItem> getResources(ResourceType type,
-            ProjectResources projectResources) {
-        update();
-
-        HashMap<String, ResourceValue> list = mResourceItems.get(type);
-        
-        ArrayList<ProjectResourceItem> items = new ArrayList<ProjectResourceItem>();
-        
-        if (list != null) {
-            Collection<ResourceValue> values = list.values();
-            for (ResourceValue res : values) {
-                ProjectResourceItem item = projectResources.findResourceItem(type, res.getName());
-                
-                if (item == null) {
-                    if (type == ResourceType.ID) {
-                        item = new IdResourceItem(res.getName(), false /* isDeclaredInline */);
-                    } else {
-                        item = new ConfigurableResourceItem(res.getName());
-                    }
-                    items.add(item);
-                }
-
-                item.add(this);
-            }
-        }
-
-        return items;
-    }
-    
-    /**
-     * Updates the Resource items if necessary.
-     */
-    private void update() {
-        if (isTouched() == true) {
-            // reset current content.
-            mResourceItems.clear();
-
-            // need to parse the file and find the content.
-            parseFile();
-            
-            resetTouch();
-        }
-    }
-
-    /**
-     * Parses the file and creates a list of {@link ResourceType}.
-     */
-    private void parseFile() {
-        try {
-            SAXParser parser = sParserFactory.newSAXParser();
-            parser.parse(getFile().getContents(), new ValueResourceParser(this, isFramework()));
-        } catch (ParserConfigurationException e) {
-        } catch (SAXException e) {
-        } catch (IOException e) {
-        } catch (CoreException e) {
-        }
-    }
-    
-    /**
-     * Adds a resource item to the list
-     * @param resType The type of the resource
-     * @param value The value of the resource.
-     */
-    public void addResourceValue(String resType, ResourceValue value) {
-        ResourceType type = ResourceType.getEnum(resType);
-        if (type != null) {
-            HashMap<String, ResourceValue> list = mResourceItems.get(type);
-    
-            // if the list does not exist, create it.
-            if (list == null) {
-                list = new HashMap<String, ResourceValue>();
-                mResourceItems.put(type, list);
-            } else {
-                // look for a possible value already existing.
-                ResourceValue oldValue = list.get(value.getName());
-                
-                if (oldValue != null) {
-                    oldValue.replaceWith(value);
-                    return;
-                }
-            }
-            
-            // empty list or no match found? add the given resource
-            list.put(value.getName(), value);
-        }
-    }
-
-    @Override
-    public IResourceValue getValue(ResourceType type, String name) {
-        update();
-
-        // get the list for the given type
-        HashMap<String, ResourceValue> list = mResourceItems.get(type);
-
-        if (list != null) {
-            return list.get(name);
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectClassLoader.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectClassLoader.java
deleted file mode 100644
index 8b6c3c1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectClassLoader.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-
-/**
- * ClassLoader able to load class from output of an Eclipse project.
- */
-public final class ProjectClassLoader extends ClassLoader {
-
-    private final IJavaProject mJavaProject;
-    private URLClassLoader mJarClassLoader;
-    private boolean mInsideJarClassLoader = false;
-
-    public ProjectClassLoader(ClassLoader parentClassLoader, IProject project) {
-        super(parentClassLoader);
-        mJavaProject = JavaCore.create(project);
-    }
-
-    @Override
-    protected Class<?> findClass(String name) throws ClassNotFoundException {
-        try {
-            // get the project output folder.
-            IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot();
-            IPath outputLocation = mJavaProject.getOutputLocation();
-            IResource outRes = root.findMember(outputLocation);
-            if (outRes == null) {
-                throw new ClassNotFoundException(name);
-            }
-
-            File outFolder = new File(outRes.getLocation().toOSString());
-
-            // get the class name segments
-            String[] segments = name.split("\\."); //$NON-NLS-1$
-            
-            File classFile = getFile(outFolder, segments, 0);
-            if (classFile == null) {
-                if (mInsideJarClassLoader == false) {
-                    // if no file matching the class name was found, look in the 3rd party jars
-                    return loadClassFromJar(name);
-                } else {
-                    throw new ClassNotFoundException(name);
-                }
-            }
-            
-            // load the content of the file and create the class.
-            FileInputStream fis = new FileInputStream(classFile);
-            byte[] data = new byte[(int)classFile.length()];
-            int read = 0;
-            try {
-                read = fis.read(data);
-            } catch (IOException e) {
-                data = null;
-            }
-            fis.close();
-            
-            if (data != null) {
-                Class<?> clazz = defineClass(null, data, 0, read);
-                if (clazz != null) {
-                    return clazz;
-                }
-            }
-        } catch (Exception e) {
-            throw new ClassNotFoundException(e.getMessage());
-        }
-
-        throw new ClassNotFoundException(name);
-    }
-    
-    /**
-     * Returns the File matching the a certain path from a root {@link File}.
-     * <p/>The methods checks that the file ends in .class even though the last segment
-     * does not.
-     * @param parent the root of the file.
-     * @param segments the segments containing the path of the file
-     * @param index the offset at which to start looking into segments.
-     * @throws FileNotFoundException
-     */
-    private File getFile(File parent, String[] segments, int index)
-            throws FileNotFoundException {
-        // reached the end with no match?
-        if (index == segments.length) {
-            throw new FileNotFoundException();
-        }
-
-        String toMatch = segments[index];
-        File[] files = parent.listFiles();
-
-        // we're at the last segments. we look for a matching <file>.class
-        if (index == segments.length - 1) {
-            toMatch = toMatch + ".class"; 
-
-            if (files != null) {
-                for (File file : files) {
-                    if (file.isFile() && file.getName().equals(toMatch)) {
-                        return file;
-                    }
-                }
-            }
-            
-            // no match? abort.
-            throw new FileNotFoundException();
-        }
-        
-        String innerClassName = null;
-        
-        if (files != null) {
-            for (File file : files) {
-                if (file.isDirectory()) {
-                    if (toMatch.equals(file.getName())) {
-                        return getFile(file, segments, index+1);
-                    }
-                } else if (file.getName().startsWith(toMatch)) {
-                    if (innerClassName == null) {
-                        StringBuilder sb = new StringBuilder(segments[index]);
-                        for (int i = index + 1 ; i < segments.length ; i++) {
-                            sb.append('$');
-                            sb.append(segments[i]);
-                        }
-                        sb.append(".class");
-                        
-                        innerClassName = sb.toString();
-                    }
-                    
-                    if (file.getName().equals(innerClassName)) {
-                        return file;
-                    }
-                }
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Loads a class from the 3rd party jar present in the project
-     * @throws ClassNotFoundException
-     */
-    private Class<?> loadClassFromJar(String name) throws ClassNotFoundException {
-        if (mJarClassLoader == null) {
-            // get the OS path to all the external jars
-            URL[] jars = getExternalJars();
-            
-            mJarClassLoader = new URLClassLoader(jars, this /* parent */);
-        }
-        
-        try {
-            // because a class loader always look in its parent loader first, we need to know
-            // that we are querying the jar classloader. This will let us know to not query
-            // it again for classes we don't find, or this would create an infinite loop.
-            mInsideJarClassLoader = true;
-            return mJarClassLoader.loadClass(name);
-        } finally {
-            mInsideJarClassLoader = false;
-        }
-    }
-    
-    /**
-     * Returns an array of external jar files used by the project.
-     * @return an array of OS-specific absolute file paths
-     */
-    private final URL[] getExternalJars() {
-        // get a java project from it
-        IJavaProject javaProject = JavaCore.create(mJavaProject.getProject());
-        
-        IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot();
-
-        ArrayList<URL> oslibraryList = new ArrayList<URL>();
-        IClasspathEntry[] classpaths = javaProject.readRawClasspath();
-        if (classpaths != null) {
-            for (IClasspathEntry e : classpaths) {
-                if (e.getEntryKind() == IClasspathEntry.CPE_LIBRARY ||
-                        e.getEntryKind() == IClasspathEntry.CPE_VARIABLE) {
-                    // if this is a classpath variable reference, we resolve it.
-                    if (e.getEntryKind() == IClasspathEntry.CPE_VARIABLE) {
-                        e = JavaCore.getResolvedClasspathEntry(e); 
-                    }
-
-                    // get the IPath
-                    IPath path = e.getPath();
-
-                    // check the name ends with .jar
-                    if (AndroidConstants.EXT_JAR.equalsIgnoreCase(path.getFileExtension())) {
-                        boolean local = false;
-                        IResource resource = wsRoot.findMember(path);
-                        if (resource != null && resource.exists() &&
-                                resource.getType() == IResource.FILE) {
-                            local = true;
-                            try {
-                                oslibraryList.add(
-                                        new File(resource.getLocation().toOSString()).toURL());
-                            } catch (MalformedURLException mue) {
-                                // pass
-                            }
-                        }
-
-                        if (local == false) {
-                            // if the jar path doesn't match a workspace resource,
-                            // then we get an OSString and check if this links to a valid file.
-                            String osFullPath = path.toOSString();
-
-                            File f = new File(osFullPath);
-                            if (f.exists()) {
-                                try {
-                                    oslibraryList.add(f.toURL());
-                                } catch (MalformedURLException mue) {
-                                    // pass
-                                }
-                            }
-                        }
-                    }
-                }
-            }
-        }
-
-        return oslibraryList.toArray(new URL[oslibraryList.size()]);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResourceItem.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResourceItem.java
deleted file mode 100644
index ba770b2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResourceItem.java
+++ /dev/null
@@ -1,91 +0,0 @@
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-
-/**
- * Base class for Resource Item coming from an Android Project.
- */
-public abstract class ProjectResourceItem extends ResourceItem {
-
-    private final static Comparator<ResourceFile> sComparator = new Comparator<ResourceFile>() {
-        public int compare(ResourceFile file1, ResourceFile file2) {
-            // get both FolderConfiguration and compare them
-            FolderConfiguration fc1 = file1.getFolder().getConfiguration();
-            FolderConfiguration fc2 = file2.getFolder().getConfiguration();
-            
-            return fc1.compareTo(fc2);
-        }
-    };
-
-    /**
-     * List of files generating this ResourceItem.
-     */
-    protected final ArrayList<ResourceFile> mFiles = new ArrayList<ResourceFile>();
-
-    /**
-     * Constructs a new ResourceItem.
-     * @param name the name of the resource as it appears in the XML and R.java files.
-     */
-    public ProjectResourceItem(String name) {
-        super(name);
-    }
-    
-    /**
-     * Returns whether the resource item is editable directly.
-     * <p/>
-     * This is typically the case for resources that don't have alternate versions, or resources
-     * of type {@link ResourceType#ID} that aren't declared inline.
-     */
-    public abstract boolean isEditableDirectly();
-
-    /**
-     * Adds a new version of this resource item, by adding its {@link ResourceFile}.
-     * @param file the {@link ResourceFile} object.
-     */
-    protected void add(ResourceFile file) {
-        mFiles.add(file);
-    }
-    
-    /**
-     * Reset the item by emptying its version list.
-     */
-    protected void reset() {
-        mFiles.clear();
-    }
-    
-    /**
-     * Returns the sorted list of {@link ResourceItem} objects for this resource item.
-     */
-    public ResourceFile[] getSourceFileArray() {
-        ArrayList<ResourceFile> list = new ArrayList<ResourceFile>();
-        list.addAll(mFiles);
-        
-        Collections.sort(list, sComparator);
-        
-        return list.toArray(new ResourceFile[list.size()]);
-    }
-    
-    /**
-     * Returns the list of {@link ResourceItem} objects for this resource item.
-     */
-    public List<ResourceFile> getSourceFileList() {
-        return Collections.unmodifiableList(mFiles);
-    }
-    
-
-    /**
-     * Replaces the content of the receiver with the ResourceItem received as parameter.
-     * @param item
-     */
-    protected void replaceWith(ProjectResourceItem item) {
-        mFiles.clear();
-        mFiles.addAll(item.mFiles);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResources.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResources.java
deleted file mode 100644
index 40e4e3b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ProjectResources.java
+++ /dev/null
@@ -1,804 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.LanguageQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.RegionQualifier;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFolder;
-import com.android.layoutlib.api.IResourceValue;
-import com.android.layoutlib.utils.ResourceValue;
-
-import org.eclipse.core.resources.IFolder;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Represents the resources of a project. This is a file view of the resources, with handling
- * for the alternate resource types. For a compiled view use CompiledResources.
- */
-public class ProjectResources implements IResourceRepository {
-    private final HashMap<ResourceFolderType, List<ResourceFolder>> mFolderMap =
-        new HashMap<ResourceFolderType, List<ResourceFolder>>();
-    
-    private final HashMap<ResourceType, List<ProjectResourceItem>> mResourceMap =
-        new HashMap<ResourceType, List<ProjectResourceItem>>();
-    
-    /** Map of (name, id) for resources of type {@link ResourceType#ID} coming from R.java */
-    private Map<String, Map<String, Integer>> mResourceValueMap;
-    /** Map of (id, [name, resType]) for all resources coming from R.java */
-    private Map<Integer, String[]> mResIdValueToNameMap;
-    /** Map of (int[], name) for styleable resources coming from R.java */
-    private Map<IntArrayWrapper, String> mStyleableValueToNameMap;
-    
-    /** Cached list of {@link IdResourceItem}. This is mix of IdResourceItem created by
-     * {@link MultiResourceFile} for ids coming from XML files under res/values and
-     * {@link IdResourceItem} created manually, from the list coming from R.java */
-    private final ArrayList<IdResourceItem> mIdResourceList = new ArrayList<IdResourceItem>();
-
-    private final boolean mIsFrameworkRepository;
-    
-    private final IntArrayWrapper mWrapper = new IntArrayWrapper(null);
-
-    public ProjectResources(boolean isFrameworkRepository) {
-        mIsFrameworkRepository = isFrameworkRepository;
-    }
-    
-    public boolean isSystemRepository() {
-        return mIsFrameworkRepository;
-    }
-
-    /**
-     * Adds a Folder Configuration to the project.
-     * @param type The resource type.
-     * @param config The resource configuration.
-     * @param folder The workspace folder object.
-     * @return the {@link ResourceFolder} object associated to this folder.
-     */
-    protected ResourceFolder add(ResourceFolderType type, FolderConfiguration config,
-            IAbstractFolder folder) {
-        // get the list for the resource type
-        List<ResourceFolder> list = mFolderMap.get(type);
-        
-        if (list == null) {
-            list = new ArrayList<ResourceFolder>();
-
-            ResourceFolder cf = new ResourceFolder(type, config, folder, mIsFrameworkRepository);
-            list.add(cf);
-
-            mFolderMap.put(type, list);
-            
-            return cf;
-        }
-
-        // look for an already existing folder configuration.
-        for (ResourceFolder cFolder : list) {
-            if (cFolder.mConfiguration.equals(config)) {
-                // config already exist. Nothing to be done really, besides making sure
-                // the IFolder object is up to date.
-                cFolder.mFolder = folder;
-                return cFolder;
-            }
-        }
-
-        // If we arrive here, this means we didn't find a matching configuration.
-        // So we add one.
-        ResourceFolder cf = new ResourceFolder(type, config, folder, mIsFrameworkRepository);
-        list.add(cf);
-        
-        return cf;
-    }
-
-    /**
-     * Removes a {@link ResourceFolder} associated with the specified {@link IAbstractFolder}.
-     * @param type The type of the folder
-     * @param folder the IFolder object.
-     */
-    protected void removeFolder(ResourceFolderType type, IFolder folder) {
-        // get the list of folders for the resource type.
-        List<ResourceFolder> list = mFolderMap.get(type);
-        
-        if (list != null) {
-            int count = list.size();
-            for (int i = 0 ; i < count ; i++) {
-                ResourceFolder resFolder = list.get(i);
-                if (resFolder.getFolder().getIFolder().equals(folder)) {
-                    // we found the matching ResourceFolder. we need to remove it.
-                    list.remove(i);
-                    
-                    // we now need to invalidate this resource type.
-                    // The easiest way is to touch one of the other folders of the same type.
-                    if (list.size() > 0) {
-                        list.get(0).touch();
-                    } else {
-                        // if the list is now empty, and we have a single ResouceType out of this
-                        // ResourceFolderType, then we are done.
-                        // However, if another ResourceFolderType can generate similar ResourceType
-                        // than this, we need to update those ResourceTypes as well.
-                        // For instance, if the last "drawable-*" folder is deleted, we need to
-                        // refresh the ResourceItem associated with ResourceType.DRAWABLE.
-                        // Those can be found in ResourceFolderType.DRAWABLE but also in
-                        // ResourceFolderType.VALUES.
-                        // If we don't find a single folder to touch, then it's fine, as the top
-                        // level items (the list of generated resource types) is not cached
-                        // (for now)
-                        
-                        // get the lists of ResourceTypes generated by this ResourceFolderType
-                        ResourceType[] resTypes = FolderTypeRelationship.getRelatedResourceTypes(
-                                type);
-                        
-                        // for each of those, make sure to find one folder to touch so that the
-                        // list of ResourceItem associated with the type is rebuilt.
-                        for (ResourceType resType : resTypes) {
-                            // get the list of folder that can generate this type
-                            ResourceFolderType[] folderTypes =
-                                FolderTypeRelationship.getRelatedFolders(resType);
-                            
-                            // we only need to touch one folder in any of those (since it's one
-                            // folder per type, not per folder type).
-                            for (ResourceFolderType folderType : folderTypes) {
-                                List<ResourceFolder> resFolders = mFolderMap.get(folderType);
-                                
-                                if (resFolders != null && resFolders.size() > 0) {
-                                    resFolders.get(0).touch();
-                                    break;
-                                }
-                            }
-                        }
-                    }
-                    
-                    // we're done updating/touching, we can stop
-                    break;
-                }
-            }
-        }
-    }
-
-    
-    /**
-     * Returns a list of {@link ResourceFolder} for a specific {@link ResourceFolderType}.
-     * @param type The {@link ResourceFolderType}
-     */
-    public List<ResourceFolder> getFolders(ResourceFolderType type) {
-        return mFolderMap.get(type);
-    }
-    
-    /* (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.IResourceRepository#getAvailableResourceTypes()
-     */
-    public ResourceType[] getAvailableResourceTypes() {
-        ArrayList<ResourceType> list = new ArrayList<ResourceType>();
-        
-        // For each key, we check if there's a single ResourceType match.
-        // If not, we look for the actual content to give us the resource type.
-
-        for (ResourceFolderType folderType : mFolderMap.keySet()) {
-            ResourceType types[] = FolderTypeRelationship.getRelatedResourceTypes(folderType);
-            if (types.length == 1) {
-                // before we add it we check if it's not already present, since a ResourceType
-                // could be created from multiple folders, even for the folders that only create
-                // one type of resource (drawable for instance, can be created from drawable/ and
-                // values/)
-                if (list.indexOf(types[0]) == -1) {
-                    list.add(types[0]);
-                }
-            } else {
-                // there isn't a single resource type out of this folder, so we look for all
-                // content.
-                List<ResourceFolder> folders = mFolderMap.get(folderType);
-                if (folders != null) {
-                    for (ResourceFolder folder : folders) {
-                        Collection<ResourceType> folderContent = folder.getResourceTypes();
-                        
-                        // then we add them, but only if they aren't already in the list.
-                        for (ResourceType folderResType : folderContent) {
-                            if (list.indexOf(folderResType) == -1) {
-                                list.add(folderResType);
-                            }
-                        }
-                    }
-                }
-            }
-        }
-        
-        // in case ResourceType.ID haven't been added yet because there's no id defined
-        // in XML, we check on the list of compiled id resources.
-        if (list.indexOf(ResourceType.ID) == -1 && mResourceValueMap != null) {
-            Map<String, Integer> map = mResourceValueMap.get(ResourceType.ID.getName());
-            if (map != null && map.size() > 0) {
-                list.add(ResourceType.ID);
-            }
-        }
-
-        // at this point the list is full of ResourceType defined in the files.
-        // We need to sort it.
-        Collections.sort(list);
-        
-        return list.toArray(new ResourceType[list.size()]);
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.IResourceRepository#getResources(com.android.ide.eclipse.common.resources.ResourceType)
-     */
-    public ProjectResourceItem[] getResources(ResourceType type) {
-        checkAndUpdate(type);
-        
-        if (type == ResourceType.ID) {
-            synchronized (mIdResourceList) {
-                return mIdResourceList.toArray(new ProjectResourceItem[mIdResourceList.size()]);
-            }
-        }
-        
-        List<ProjectResourceItem> items = mResourceMap.get(type);
-        
-        return items.toArray(new ProjectResourceItem[items.size()]);
-    }
-
-    /* (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.IResourceRepository#hasResources(com.android.ide.eclipse.common.resources.ResourceType)
-     */
-    public boolean hasResources(ResourceType type) {
-        checkAndUpdate(type);
-
-        if (type == ResourceType.ID) {
-            synchronized (mIdResourceList) {
-                return mIdResourceList.size() > 0;
-            }
-        }
-
-        List<ProjectResourceItem> items = mResourceMap.get(type);
-        return (items != null && items.size() > 0);
-    }
-
-    /**
-     * Returns the {@link ResourceFolder} associated with a {@link IFolder}.
-     * @param folder The {@link IFolder} object.
-     * @return the {@link ResourceFolder} or null if it was not found.
-     */
-    public ResourceFolder getResourceFolder(IFolder folder) {
-        for (List<ResourceFolder> list : mFolderMap.values()) {
-            for (ResourceFolder resFolder : list) {
-                if (resFolder.getFolder().getIFolder().equals(folder)) {
-                    return resFolder;
-                }
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the {@link ResourceFile} matching the given name, {@link ResourceFolderType} and
-     * configuration.
-     * <p/>This only works with files generating one resource named after the file (for instance,
-     * layouts, bitmap based drawable, xml, anims).
-     * @return the matching file or <code>null</code> if no match was found.
-     */
-    public ResourceFile getMatchingFile(String name, ResourceFolderType type,
-            FolderConfiguration config) {
-        // get the folders for the given type
-        List<ResourceFolder> folders = mFolderMap.get(type);
-
-        // look for folders containing a file with the given name.
-        ArrayList<ResourceFolder> matchingFolders = new ArrayList<ResourceFolder>();
-        
-        // remove the folders that do not have a file with the given name, or if their config
-        // is incompatible.
-        for (int i = 0 ; i < folders.size(); i++) {
-            ResourceFolder folder = folders.get(i);
-            
-            if (folder.hasFile(name) == true) {
-                matchingFolders.add(folder);
-            }
-        }
-        
-        // from those, get the folder with a config matching the given reference configuration.
-        Resource match = findMatchingConfiguredResource(matchingFolders, config);
-        
-        // do we have a matching folder?
-        if (match instanceof ResourceFolder) {
-            // get the ResourceFile from the filename
-            return ((ResourceFolder)match).getFile(name);
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the resources values matching a given {@link FolderConfiguration}.
-     * @param referenceConfig the configuration that each value must match.
-     */
-    public Map<String, Map<String, IResourceValue>> getConfiguredResources(
-            FolderConfiguration referenceConfig) {
-
-        Map<String, Map<String, IResourceValue>> map =
-            new HashMap<String, Map<String, IResourceValue>>();
-        
-        // special case for Id since there's a mix of compiled id (declared inline) and id declared
-        // in the XML files.
-        if (mIdResourceList.size() > 0) {
-            Map<String, IResourceValue> idMap = new HashMap<String, IResourceValue>();
-            String idType = ResourceType.ID.getName();
-            for (IdResourceItem id : mIdResourceList) {
-                // FIXME: cache the ResourceValue!
-                idMap.put(id.getName(), new ResourceValue(idType, id.getName(),
-                        mIsFrameworkRepository));
-            }
-            
-            map.put(ResourceType.ID.getName(), idMap);
-        }
-        
-        Set<ResourceType> keys = mResourceMap.keySet();
-        for (ResourceType key : keys) {
-            // we don't process ID resources since we already did it above.
-            if (key != ResourceType.ID) {
-                map.put(key.getName(), getConfiguredResource(key, referenceConfig));
-            }
-        }
-        
-        return map;
-    }
-    
-    /**
-     * Loads all the resources. Essentially this forces to load the values from the
-     * {@link ResourceFile} objects to make sure they are up to date and loaded
-     * in {@link #mResourceMap}.
-     */
-    public void loadAll() {
-        // gets all the resource types available.
-        ResourceType[] types = getAvailableResourceTypes();
-        
-        // loop on them and load them
-        for (ResourceType type: types) {
-            checkAndUpdate(type);
-        }
-    }
-    
-    /**
-     * Resolves a compiled resource id into the resource name and type
-     * @param id
-     * @return an array of 2 strings { name, type } or null if the id could not be resolved
-     */
-    public String[] resolveResourceValue(int id) {
-        if (mResIdValueToNameMap != null) {
-            return mResIdValueToNameMap.get(id);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Resolves a compiled resource id of type int[] into the resource name.
-     */
-    public String resolveResourceValue(int[] id) {
-        if (mStyleableValueToNameMap != null) {
-            mWrapper.set(id);
-            return mStyleableValueToNameMap.get(mWrapper);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the value of a resource by its type and name.
-     */
-    public Integer getResourceValue(String type, String name) {
-        if (mResourceValueMap != null) {
-            Map<String, Integer> map = mResourceValueMap.get(type);
-            if (map != null) {
-                return map.get(name);
-            }
-        }
-
-        return null;
-    }
-    
-    /**
-     * Returns the list of languages used in the resources.
-     */
-    public Set<String> getLanguages() {
-        Set<String> set = new HashSet<String>();
-
-        Collection<List<ResourceFolder>> folderList = mFolderMap.values();
-        for (List<ResourceFolder> folderSubList : folderList) {
-            for (ResourceFolder folder : folderSubList) {
-                FolderConfiguration config = folder.getConfiguration();
-                LanguageQualifier lang = config.getLanguageQualifier();
-                if (lang != null) {
-                    set.add(lang.getStringValue());
-                }
-            }
-        }
-        
-        return set;
-    }
-    
-    /**
-     * Returns the list of regions used in the resources with the given language.
-     * @param currentLanguage the current language the region must be associated with.
-     */
-    public Set<String> getRegions(String currentLanguage) {
-        Set<String> set = new HashSet<String>();
-
-        Collection<List<ResourceFolder>> folderList = mFolderMap.values();
-        for (List<ResourceFolder> folderSubList : folderList) {
-            for (ResourceFolder folder : folderSubList) {
-                FolderConfiguration config = folder.getConfiguration();
-                
-                // get the language
-                LanguageQualifier lang = config.getLanguageQualifier();
-                if (lang != null && lang.getStringValue().equals(currentLanguage)) {
-                    RegionQualifier region = config.getRegionQualifier();
-                    if (region != null) {
-                        set.add(region.getStringValue());
-                    }
-                }
-            }
-        }
-        
-        return set;
-    }
-
-    /**
-     * Returns a map of (resource name, resource value) for the given {@link ResourceType}.
-     * <p/>The values returned are taken from the resource files best matching a given
-     * {@link FolderConfiguration}.
-     * @param type the type of the resources.
-     * @param referenceConfig the configuration to best match.
-     */
-    private Map<String, IResourceValue> getConfiguredResource(ResourceType type,
-            FolderConfiguration referenceConfig) {
-        // get the resource item for the given type
-        List<ProjectResourceItem> items = mResourceMap.get(type);
-        
-        // create the map
-        HashMap<String, IResourceValue> map = new HashMap<String, IResourceValue>();
-        
-        for (ProjectResourceItem item : items) {
-            // get the source files generating this resource
-            List<ResourceFile> list = item.getSourceFileList();
-            
-            // look for the best match for the given configuration
-            Resource match = findMatchingConfiguredResource(list, referenceConfig);
-            
-            if (match instanceof ResourceFile) {
-                ResourceFile matchResFile = (ResourceFile)match;
-                
-                // get the value of this configured resource.
-                IResourceValue value = matchResFile.getValue(type, item.getName());
-                
-                if (value != null) {
-                    map.put(item.getName(), value);
-                }
-            }
-        }
-
-        return map;
-    }
-
-    /**
-     * Returns the best matching {@link Resource}. 
-     * @param resources the list of {@link Resource} to choose from.
-     * @param referenceConfig the {@link FolderConfiguration} to match.
-     */
-    private Resource findMatchingConfiguredResource(List<? extends Resource> resources,
-            FolderConfiguration referenceConfig) {
-        // look for resources with the maximum number of qualifier match.
-        int currentMax = -1;
-        ArrayList<Resource> matchingResources = new ArrayList<Resource>();
-        for (int i = 0 ; i < resources.size(); i++) {
-            Resource res = resources.get(i);
-            
-            int count = res.getConfiguration().match(referenceConfig);
-            if (count > currentMax) {
-                matchingResources.clear();
-                matchingResources.add(res);
-                currentMax = count;
-            } else if (count != -1 && count == currentMax) {
-                matchingResources.add(res);
-            }
-        }
-        
-        // if we have more than one match, we look for the match with the qualifiers with the
-        // highest priority.
-        Resource resMatch = null;
-        if (matchingResources.size() == 1) {
-            resMatch = matchingResources.get(0);
-        } else if (matchingResources.size() > 1) {
-            // More than one resource with the same number of qualifier match.
-            // We loop, looking for the resource with the highest priority qualifiers.
-            ArrayList<Resource> tmpResources = new ArrayList<Resource>();
-            int startIndex = 0;
-            while (matchingResources.size() > 1) {
-                int highest = -1;
-                for (int i = 0 ; i < matchingResources.size() ; i++) {
-                    Resource folder = matchingResources.get(i);
-                 
-                    // get highest priority qualifiers.
-                    int m = folder.getConfiguration().getHighestPriorityQualifier(startIndex);
-
-                    // add to the list if highest.
-                    if (m != -1) {
-                        if (highest == -1 || m == highest) {
-                            tmpResources.add(folder);
-                            highest = m;
-                        } else if (m < highest) { // highest priority == lowest index.
-                            tmpResources.clear();
-                            tmpResources.add(folder);
-                        }
-                    }
-                }
-                
-                // at this point, we have a list with 1+ resources that all have the same highest
-                // priority qualifiers. Go through the list again looking for the next highest
-                // priority qualifier.
-                startIndex = highest + 1;
-                
-                // this should not happen, but it's better to check.
-                if (matchingResources.size() == tmpResources.size() && highest == -1) {
-                    // this means all the resources match with the same qualifiers
-                    // (highest == -1 means we reached the end of the qualifier list)
-                    // In this case, we arbitrarily take the first resource.
-                    matchingResources.clear();
-                    matchingResources.add(tmpResources.get(0));
-                } else {
-                    matchingResources.clear();
-                    matchingResources.addAll(tmpResources);
-                }
-                tmpResources.clear();
-            }
-            
-            // we should have only one match here.
-            resMatch = matchingResources.get(0);
-        }
-
-        return resMatch;
-    }
-
-    /**
-     * Checks if the list of {@link ResourceItem}s for the specified {@link ResourceType} needs
-     * to be updated. 
-     * @param type the Resource Type.
-     */
-    private void checkAndUpdate(ResourceType type) {
-        // get the list of folder that can output this type
-        ResourceFolderType[] folderTypes = FolderTypeRelationship.getRelatedFolders(type);
-
-        for (ResourceFolderType folderType : folderTypes) {
-            List<ResourceFolder> folders = mFolderMap.get(folderType);
-            
-            if (folders != null) {
-                for (ResourceFolder folder : folders) {
-                    if (folder.isTouched()) {
-                        // if this folder is touched we need to update all the types that can
-                        // be generated from a file in this folder.
-                        // This will include 'type' obviously.
-                        ResourceType[] resTypes = FolderTypeRelationship.getRelatedResourceTypes(
-                                folderType);
-                        for (ResourceType resType : resTypes) {
-                            update(resType);
-                        }
-                        return;
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Updates the list of {@link ResourceItem} objects associated with a {@link ResourceType}.
-     * This will reset the touch status of all the folders that can generate this resource type.
-     * @param type the Resource Type.
-     */
-    private void update(ResourceType type) {
-        // get the cache list, and lets make a backup
-        List<ProjectResourceItem> items = mResourceMap.get(type);
-        List<ProjectResourceItem> backup = new ArrayList<ProjectResourceItem>();
-        
-        if (items == null) {
-            items = new ArrayList<ProjectResourceItem>();
-            mResourceMap.put(type, items);
-        } else {
-            // backup the list
-            backup.addAll(items);
-
-            // we reset the list itself.
-            items.clear();
-        }
-        
-        // get the list of folder that can output this type
-        ResourceFolderType[] folderTypes = FolderTypeRelationship.getRelatedFolders(type);
-
-        for (ResourceFolderType folderType : folderTypes) {
-            List<ResourceFolder> folders = mFolderMap.get(folderType);
-
-            if (folders != null) {
-                for (ResourceFolder folder : folders) {
-                    items.addAll(folder.getResources(type, this));
-                    folder.resetTouch();
-                }
-            }
-        }
-
-        // now items contains the new list. We "merge" it with the backup list.
-        // Basically, we need to keep the old instances of ResourceItem (where applicable),
-        // but replace them by the content of the new items.
-        // This will let the resource explorer keep the expanded state of the nodes whose data
-        // is a ResourceItem object.
-        if (backup.size() > 0) {
-            // this is not going to change as we're only replacing instances.
-            int count = items.size();
-
-            for (int i = 0 ; i < count;) {
-                // get the "new" item
-                ProjectResourceItem item = items.get(i);
-                
-                // look for a similar item in the old list.
-                ProjectResourceItem foundOldItem = null;
-                for (ProjectResourceItem oldItem : backup) {
-                    if (oldItem.getName().equals(item.getName())) {
-                        foundOldItem = oldItem;
-                        break;
-                    }
-                }
-                
-                if (foundOldItem != null) {
-                    // erase the data of the old item with the data from the new one.
-                    foundOldItem.replaceWith(item);
-                    
-                    // remove the old and new item from their respective lists
-                    items.remove(i);
-                    backup.remove(foundOldItem);
-                    
-                    // add the old item to the new list
-                    items.add(foundOldItem);
-                } else {
-                    // this is a new item, we skip to the next object
-                    i++;
-                }
-            }
-        }
-        
-        // if this is the ResourceType.ID, we create the actual list, from this list and
-        // the compiled resource list.
-        if (type == ResourceType.ID) {
-            mergeIdResources();
-        } else {
-            // else this is the list that will actually be displayed, so we sort it.
-            Collections.sort(items);
-        }
-    }
-
-    /**
-     * Looks up an existing {@link ProjectResourceItem} by {@link ResourceType} and name. 
-     * @param type the Resource Type.
-     * @param name the Resource name.
-     * @return the existing ResourceItem or null if no match was found.
-     */
-    protected ProjectResourceItem findResourceItem(ResourceType type, String name) {
-        List<ProjectResourceItem> list = mResourceMap.get(type);
-        
-        for (ProjectResourceItem item : list) {
-            if (name.equals(item.getName())) {
-                return item;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Sets compiled resource information.
-     * @param resIdValueToNameMap a map of compiled resource id to resource name.
-     *  The map is acquired by the {@link ProjectResources} object.
-     * @param styleableValueMap
-     * @param resourceValueMap a map of (name, id) for resources of type {@link ResourceType#ID}.
-     * The list is acquired by the {@link ProjectResources} object.
-     */
-    void setCompiledResources(Map<Integer, String[]> resIdValueToNameMap,
-            Map<IntArrayWrapper, String> styleableValueMap,
-            Map<String, Map<String, Integer>> resourceValueMap) {
-        mResourceValueMap = resourceValueMap;
-        mResIdValueToNameMap = resIdValueToNameMap;
-        mStyleableValueToNameMap = styleableValueMap;
-        mergeIdResources();
-    }
-
-    /**
-     * Merges the list of ID resource coming from R.java and the list of ID resources
-     * coming from XML declaration into the cached list {@link #mIdResourceList}.
-     */
-    void mergeIdResources() {
-        // get the list of IDs coming from XML declaration. Those ids are present in
-        // mCompiledIdResources already, so we'll need to use those instead of creating
-        // new IdResourceItem
-        List<ProjectResourceItem> xmlIdResources = mResourceMap.get(ResourceType.ID);
-
-        synchronized (mIdResourceList) {
-            // copy the currently cached items.
-            ArrayList<IdResourceItem> oldItems = new ArrayList<IdResourceItem>();
-            oldItems.addAll(mIdResourceList);
-
-            // empty the current list
-            mIdResourceList.clear();
-            
-            // get the list of compile id resources.
-            Map<String, Integer> idMap = null;
-            if (mResourceValueMap != null) {
-                idMap = mResourceValueMap.get(ResourceType.ID.getName());
-            }
-            
-            if (idMap == null) {
-                if (xmlIdResources != null) {
-                    for (ProjectResourceItem resourceItem : xmlIdResources) {
-                        // check the actual class just for safety.
-                        if (resourceItem instanceof IdResourceItem) {
-                            mIdResourceList.add((IdResourceItem)resourceItem);
-                        }
-                    }
-                }
-            } else {
-                // loop on the full list of id, and look for a match in the old list,
-                // in the list coming from XML (in case a new XML item was created.)
-                
-                Set<String> idSet = idMap.keySet();
-                
-                idLoop: for (String idResource : idSet) {
-                    // first look in the XML list in case an id went from inline to XML declared.
-                    if (xmlIdResources != null) {
-                        for (ProjectResourceItem resourceItem : xmlIdResources) {
-                            if (resourceItem instanceof IdResourceItem && 
-                                    resourceItem.getName().equals(idResource)) {
-                                mIdResourceList.add((IdResourceItem)resourceItem);
-                                continue idLoop;
-                            }
-                        }
-                    }
-                    
-                    // if we haven't found it, look in the old items.
-                    int count = oldItems.size();
-                    for (int i = 0 ; i < count ; i++) {
-                        IdResourceItem resourceItem = oldItems.get(i);
-                        if (resourceItem.getName().equals(idResource)) {
-                            oldItems.remove(i);
-                            mIdResourceList.add(resourceItem);
-                            continue idLoop;
-                        }
-                    }
-                    
-                    // if we haven't found it, it looks like it's a new id that was
-                    // declared inline.
-                    mIdResourceList.add(new IdResourceItem(idResource,
-                            true /* isDeclaredInline */));
-                }
-            }
-            
-            // now we sort the list
-            Collections.sort(mIdResourceList);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/Resource.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/Resource.java
deleted file mode 100644
index dd8d080..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/Resource.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-
-/**
- * Base class for file system resource items (Folders, Files).
- */
-public abstract class Resource {
-    private boolean mTouched = true;
-    
-    /**
-     * Returns the {@link FolderConfiguration} for this object.
-     */
-    public abstract FolderConfiguration getConfiguration();
-
-    /**
-     * Indicates that the underlying file was changed.
-     */
-    public final void touch() {
-       mTouched = true; 
-    }
-    
-    public final boolean isTouched() {
-        return mTouched;
-    }
-    
-    public final void resetTouch() {
-        mTouched = false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFile.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFile.java
deleted file mode 100644
index f927a9a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFile.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFile;
-import com.android.layoutlib.api.IResourceValue;
-
-import java.util.Collection;
-
-/**
- * Represents a Resource file (a file under $Project/res/)
- */
-public abstract class ResourceFile extends Resource {
-    
-    private final IAbstractFile mFile;
-    private final ResourceFolder mFolder;
-    
-    protected ResourceFile(IAbstractFile file, ResourceFolder folder) {
-        mFile = file;
-        mFolder = folder;
-    }
-    
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.Resource#getConfiguration()
-     */
-    @Override
-    public FolderConfiguration getConfiguration() {
-        return mFolder.getConfiguration();
-    }
-    
-    /**
-     * Returns the IFile associated with the ResourceFile.
-     */
-    public final IAbstractFile getFile() {
-        return mFile;
-    }
-    
-    /**
-     * Returns the parent folder as a {@link ResourceFolder}.
-     */
-    public final ResourceFolder getFolder() {
-        return mFolder;
-    }
-    
-    /**
-     * Returns whether the resource is a framework resource.
-     */
-    public final boolean isFramework() {
-        return mFolder.isFramework();
-    }
-
-    /**
-     * Returns the list of {@link ResourceType} generated by the file.
-     */
-    public abstract ResourceType[] getResourceTypes();
-
-    /**
-     * Returns whether the file generated a resource of a specific type.
-     * @param type The {@link ResourceType}
-     */
-    public abstract boolean hasResources(ResourceType type);
-
-    /**
-     * Get the list of {@link ProjectResourceItem} of a specific type generated by the file.
-     * This method must make sure not to create duplicate.
-     * @param type The type of {@link ProjectResourceItem} to return.
-     * @param projectResources The global Project Resource object, allowing the implementation to
-     * query for already existing {@link ProjectResourceItem}
-     * @return The list of <b>new</b> {@link ProjectResourceItem}
-     * @see ProjectResources#findResourceItem(ResourceType, String)
-     */
-    public abstract Collection<ProjectResourceItem> getResources(ResourceType type,
-            ProjectResources projectResources);
-    
-    /**
-     * Returns the value of a resource generated by this file by {@link ResourceType} and name.
-     * <p/>If no resource match, <code>null</code> is returned. 
-     * @param type the type of the resource.
-     * @param name the name of the resource.
-     */
-    public abstract IResourceValue getValue(ResourceType type, String name);
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolder.java
deleted file mode 100644
index 98f5b39..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolder.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFile;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFolder;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-/**
- * Resource Folder class. Contains list of {@link ResourceFile}s,
- * the {@link FolderConfiguration}, and a link to the workspace {@link IFolder} object.
- */
-public final class ResourceFolder extends Resource {
-    ResourceFolderType mType;
-    FolderConfiguration mConfiguration;
-    IAbstractFolder mFolder;
-    ArrayList<ResourceFile> mFiles = null;
-    private final boolean mIsFramework;
-    
-    /**
-     * Creates a new {@link ResourceFolder}
-     * @param type The type of the folder
-     * @param config The configuration of the folder
-     * @param folder The associated {@link IAbstractFolder} object.
-     * @param isFrameworkRepository 
-     */
-    public ResourceFolder(ResourceFolderType type, FolderConfiguration config,
-            IAbstractFolder folder, boolean isFrameworkRepository) {
-        mType = type;
-        mConfiguration = config;
-        mFolder = folder;
-        mIsFramework = isFrameworkRepository;
-    }
-    
-    /**
-     * Adds a {@link ResourceFile} to the folder.
-     * @param file The {@link ResourceFile}.
-     */
-    public void addFile(ResourceFile file) {
-        if (mFiles == null) {
-            mFiles = new ArrayList<ResourceFile>();
-        }
-
-        mFiles.add(file);
-    }
-    
-    /**
-     * Attempts to remove the {@link ResourceFile} associated with a specified {@link IFile}.
-     * @param file the IFile object.
-     */
-    public void removeFile(IFile file) {
-        if (mFiles != null) {
-            int count = mFiles.size();
-            for (int i = 0 ; i < count ; i++) {
-                ResourceFile resFile = mFiles.get(i);
-                if (resFile != null) {
-                    IFile iFile = resFile.getFile().getIFile();
-                    if (iFile != null && iFile.equals(file)) {
-                        mFiles.remove(i);
-                        touch();
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Returns the {@link IFolder} associated with this object.
-     */
-    public IAbstractFolder getFolder() {
-        return mFolder;
-    }
-
-    /**
-     * Returns the {@link ResourceFolderType} of this object.
-     */
-    public ResourceFolderType getType() {
-        return mType;
-    }
-    
-    /**
-     * Returns whether the folder is a framework resource folder.
-     */
-    public boolean isFramework() {
-        return mIsFramework;
-    }
-    
-    /**
-     * Returns the list of {@link ResourceType}s generated by the files inside this folder.
-     */
-    public Collection<ResourceType> getResourceTypes() {
-        ArrayList<ResourceType> list = new ArrayList<ResourceType>();
-
-        if (mFiles != null) {
-            for (ResourceFile file : mFiles) {
-                ResourceType[] types = file.getResourceTypes();
-                
-                // loop through those and add them to the main list,
-                // if they are not already present
-                if (types != null) {
-                    for (ResourceType resType : types) {
-                        if (list.indexOf(resType) == -1) {
-                            list.add(resType);
-                        }
-                    }
-                }
-            }
-        }
-        
-        return list;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.Resource#getConfiguration()
-     */
-    @Override
-    public FolderConfiguration getConfiguration() {
-        return mConfiguration;
-    }
-    
-    /**
-     * Returns whether the folder contains a file with the given name.
-     * @param name the name of the file.
-     */
-    public boolean hasFile(String name) {
-        return mFolder.hasFile(name);
-    }
-
-    /**
-     * Returns the {@link ResourceFile} matching a {@link IAbstractFile} object.
-     * @param file The {@link IFile} object.
-     * @return the {@link ResourceFile} or null if no match was found.
-     */
-    public ResourceFile getFile(IAbstractFile file) {
-        if (mFiles != null) {
-            for (ResourceFile f : mFiles) {
-                if (f.getFile().equals(file)) {
-                    return f;
-                }
-            }
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the {@link ResourceFile} matching a {@link IFile} object.
-     * @param file The {@link IFile} object.
-     * @return the {@link ResourceFile} or null if no match was found.
-     */
-    public ResourceFile getFile(IFile file) {
-        if (mFiles != null) {
-            for (ResourceFile f : mFiles) {
-                IFile iFile = f.getFile().getIFile();
-                if (iFile != null && iFile.equals(file)) {
-                    return f;
-                }
-            }
-        }
-        return null;
-    }
-
-    
-    /**
-     * Returns the {@link ResourceFile} matching a given name.
-     * @param filename The name of the file to return.
-     * @return the {@link ResourceFile} or <code>null</code> if no match was found.
-     */
-    public ResourceFile getFile(String filename) {
-        if (mFiles != null) {
-            for (ResourceFile f : mFiles) {
-                if (f.getFile().getName().equals(filename)) {
-                    return f;
-                }
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Returns whether a file in the folder is generating a resource of a specified type.
-     * @param type The {@link ResourceType} being looked up.
-     */
-    public boolean hasResources(ResourceType type) {
-        // Check if the folder type is able to generate resource of the type that was asked.
-        // this is a first check to avoid going through the files.
-        ResourceFolderType[] folderTypes = FolderTypeRelationship.getRelatedFolders(type);
-        
-        boolean valid = false;
-        for (ResourceFolderType rft : folderTypes) {
-            if (rft == mType) {
-                valid = true;
-                break;
-            }
-        }
-        
-        if (valid) {
-            if (mFiles != null) {
-                for (ResourceFile f : mFiles) {
-                    if (f.hasResources(type)) {
-                        return true;
-                    }
-                }
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Get the list of {@link ResourceItem} of a specific type generated by all the files
-     * in the folder.
-     * This method must make sure not to create duplicates.
-     * @param type The type of {@link ResourceItem} to return.
-     * @param projectResources The global Project Resource object, allowing the implementation to
-     * query for already existing {@link ResourceItem}
-     * @return The list of <b>new</b> {@link ResourceItem}
-     * @see ProjectResources#findResourceItem(ResourceType, String)
-     */
-    public Collection<ProjectResourceItem> getResources(ResourceType type,
-            ProjectResources projectResources) {
-        Collection<ProjectResourceItem> list = new ArrayList<ProjectResourceItem>();
-        if (mFiles != null) {
-            for (ResourceFile f : mFiles) {
-                list.addAll(f.getResources(type, projectResources));
-            }
-        }
-        return list;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolderType.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolderType.java
deleted file mode 100644
index 5fc7393..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceFolderType.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.sdklib.SdkConstants;
-
-/**
- * Enum representing a type of resource folder.
- */
-public enum ResourceFolderType {
-    ANIM(SdkConstants.FD_ANIM),
-    COLOR(SdkConstants.FD_COLOR),
-    DRAWABLE(SdkConstants.FD_DRAWABLE),
-    LAYOUT(SdkConstants.FD_LAYOUT),
-    MENU(SdkConstants.FD_MENU),
-    RAW(SdkConstants.FD_RAW),
-    VALUES(SdkConstants.FD_VALUES),
-    XML(SdkConstants.FD_XML);
-
-    private final String mName;
-
-    ResourceFolderType(String name) {
-        mName = name;
-    }
-
-    public String getName() {
-        return mName;
-    }
-    
-    /**
-     * Returns the enum by name.
-     * @param name The enum string value.
-     * @return the enum or null if not found.
-     */
-    public static ResourceFolderType getTypeByName(String name) {
-        for (ResourceFolderType rType : values()) {
-            if (rType.mName.equals(name)) {
-                return rType;
-            }
-        }
-        return null;
-    }
-    
-    /**
-     * Returns the {@link ResourceFolderType} from the folder name
-     * @param folderName The name of the folder. This must be a valid folder name in the format
-     * <code>resType[-resqualifiers[-resqualifiers[...]]</code>
-     * @return the <code>ResourceFolderType</code> representing the type of the folder, or
-     * <code>null</code> if no matching type was found.
-     */
-    public static ResourceFolderType getFolderType(String folderName) {
-        // split the name of the folder in segments.
-        String[] folderSegments = folderName.split(FolderConfiguration.QUALIFIER_SEP);
-
-        // get the enum for the resource type.
-        return getTypeByName(folderSegments[0]);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceManager.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceManager.java
deleted file mode 100644
index 6099008..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceManager.java
+++ /dev/null
@@ -1,493 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFileListener;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IFolderListener;
-import com.android.ide.eclipse.editors.resources.manager.ResourceMonitor.IProjectListener;
-import com.android.ide.eclipse.editors.resources.manager.files.FileWrapper;
-import com.android.ide.eclipse.editors.resources.manager.files.FolderWrapper;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFile;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFolder;
-import com.android.ide.eclipse.editors.resources.manager.files.IFileWrapper;
-import com.android.ide.eclipse.editors.resources.manager.files.IFolderWrapper;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.HashMap;
-
-public final class ResourceManager implements IProjectListener, IFolderListener, IFileListener {
-
-    private final static ResourceManager sThis = new ResourceManager();
-
-    /** List of the qualifier object helping for the parsing of folder names */
-    private final ResourceQualifier[] mQualifiers;
-    
-    /**
-     * Map associating project resource with project objects.
-     */
-    private final HashMap<IProject, ProjectResources> mMap =
-        new HashMap<IProject, ProjectResources>();
-    
-    /**
-     * Sets up the resource manager with the global resource monitor.
-     * @param monitor The global resource monitor
-     */
-    public static void setup(ResourceMonitor monitor) {
-        monitor.addProjectListener(sThis);
-        int mask = IResourceDelta.ADDED | IResourceDelta.REMOVED | IResourceDelta.CHANGED;
-        monitor.addFolderListener(sThis, mask);
-        monitor.addFileListener(sThis, mask);
-        
-        CompiledResourcesMonitor.setupMonitor(monitor);
-    }
-    
-    /**
-     * Returns the singleton instance.
-     */
-    public static ResourceManager getInstance() {
-        return sThis;
-    }
-
-    /**
-     * Returns the resources of a project.
-     * @param project The project
-     * @return a ProjectResources object or null if none was found.
-     */
-    public ProjectResources getProjectResources(IProject project) {
-        return mMap.get(project);
-    }
-    
-    /**
-     * Processes folder event.
-     */
-    public void folderChanged(IFolder folder, int kind) {
-        ProjectResources resources;
-        
-        final IProject project = folder.getProject();
-        
-        try {
-            if (project.hasNature(AndroidConstants.NATURE) == false) {
-                return;
-            }
-        } catch (CoreException e) {
-            // can't get the project nature? return!
-            return;
-        }
-        
-        switch (kind) {
-            case IResourceDelta.ADDED:
-                // checks if the folder is under res.
-                IPath path = folder.getFullPath();
-                
-                // the path will be project/res/<something>
-                if (path.segmentCount() == 3) {
-                    if (isInResFolder(path)) {
-                        // get the project and its resource object.
-                        resources = mMap.get(project);
-                        
-                        // if it doesn't exist, we create it.
-                        if (resources == null) {
-                            resources = new ProjectResources(false /* isFrameworkRepository */);
-                            mMap.put(project, resources);
-                        }
-
-                        processFolder(new IFolderWrapper(folder), resources);
-                    }
-                }
-                break;
-            case IResourceDelta.CHANGED:
-                resources = mMap.get(folder.getProject());
-                if (resources != null) {
-                    ResourceFolder resFolder = resources.getResourceFolder(folder);
-                    if (resFolder != null) {
-                        resFolder.touch();
-                    }
-                }
-                break;
-            case IResourceDelta.REMOVED:
-                resources = mMap.get(folder.getProject());
-                if (resources != null) {
-                    // lets get the folder type
-                    ResourceFolderType type = ResourceFolderType.getFolderType(folder.getName());
-
-                    resources.removeFolder(type, folder);
-                }
-                break;
-        }
-    }
-    
-    /* (non-Javadoc)
-     * Sent when a file changed. Depending on the file being changed, and the type of change (ADDED,
-     * REMOVED, CHANGED), the file change is processed to update the resource manager data.
-     * 
-     * @param file The file that changed.
-     * @param markerDeltas The marker deltas for the file.
-     * @param kind The change kind. This is equivalent to
-     * {@link IResourceDelta#accept(IResourceDeltaVisitor)}
-     * 
-     * @see IFileListener#fileChanged
-     */
-    public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind) {
-        ProjectResources resources;
-        
-        final IProject project = file.getProject();
-        
-        try {
-            if (project.hasNature(AndroidConstants.NATURE) == false) {
-                return;
-            }
-        } catch (CoreException e) {
-            // can't get the project nature? return!
-            return;
-        }
-        
-        switch (kind) {
-            case IResourceDelta.ADDED:
-                // checks if the file is under res/something.
-                IPath path = file.getFullPath();
-                
-                if (path.segmentCount() == 4) {
-                    if (isInResFolder(path)) {
-                        // get the project and its resources
-                        resources = mMap.get(project);
-        
-                        IContainer container = file.getParent();
-                        if (container instanceof IFolder && resources != null) {
-                            
-                            ResourceFolder folder = resources.getResourceFolder((IFolder)container);
-                            
-                            if (folder != null) {
-                                processFile(new IFileWrapper(file), folder);
-                            }
-                        }
-                    }
-                }
-                break;
-            case IResourceDelta.CHANGED:
-                // try to find a matching ResourceFile
-                resources = mMap.get(project);
-                if (resources != null) {
-                    IContainer container = file.getParent();
-                    if (container instanceof IFolder) {
-                        ResourceFolder resFolder = resources.getResourceFolder((IFolder)container);
-                        
-                        // we get the delete on the folder before the file, so it is possible
-                        // the associated ResourceFolder doesn't exist anymore.
-                        if (resFolder != null) {
-                            // get the resourceFile, and touch it.
-                            ResourceFile resFile = resFolder.getFile(file);
-                            if (resFile != null) {
-                                resFile.touch();
-                            }
-                        }
-                    }
-                }
-                break;
-            case IResourceDelta.REMOVED:
-                // try to find a matching ResourceFile
-                resources = mMap.get(project);
-                if (resources != null) {
-                    IContainer container = file.getParent();
-                    if (container instanceof IFolder) {
-                        ResourceFolder resFolder = resources.getResourceFolder((IFolder)container);
-                        
-                        // we get the delete on the folder before the file, so it is possible
-                        // the associated ResourceFolder doesn't exist anymore.
-                        if (resFolder != null) {
-                            // remove the file
-                            resFolder.removeFile(file);
-                        }
-                    }
-                }
-                break;
-        }
-    }
-
-    public void projectClosed(IProject project) {
-        mMap.remove(project);
-    }
-
-    public void projectDeleted(IProject project) {
-        mMap.remove(project);
-    }
-
-    public void projectOpened(IProject project) {
-        createProject(project);
-    }
-
-    public void projectOpenedWithWorkspace(IProject project) {
-        createProject(project);
-    }
-    
-    /**
-     * Returns the {@link ResourceFolder} for the given file or <code>null</code> if none exists.
-     */
-    public ResourceFolder getResourceFolder(IFile file) {
-        IContainer container = file.getParent();
-        if (container.getType() == IResource.FOLDER) {
-            IFolder parent = (IFolder)container;
-            IProject project = file.getProject();
-            
-            ProjectResources resources = getProjectResources(project);
-            if (resources != null) {
-                return resources.getResourceFolder(parent);
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Loads and returns the resources for a given {@link IAndroidTarget}
-     * @param androidTarget the target from which to load the framework resources
-     */
-    public ProjectResources loadFrameworkResources(IAndroidTarget androidTarget) {
-        String osResourcesPath = androidTarget.getPath(IAndroidTarget.RESOURCES);
-        
-        File frameworkRes = new File(osResourcesPath);
-        if (frameworkRes.isDirectory()) {
-            ProjectResources resources = new ProjectResources(true /* isFrameworkRepository */);
-
-            try {
-                File[] files = frameworkRes.listFiles();
-                for (File file : files) {
-                    if (file.isDirectory()) {
-                        ResourceFolder resFolder = processFolder(new FolderWrapper(file),
-                                resources);
-                        
-                        if (resFolder != null) {
-                            // now we process the content of the folder
-                            File[] children = file.listFiles();
-                            
-                            for (File childRes : children) {
-                                if (childRes.isFile()) {
-                                    processFile(new FileWrapper(childRes), resFolder);
-                                }
-                            }
-                        }
-                        
-                    }
-                }
-                
-                // now that we have loaded the files, we need to force load the resources from them
-                resources.loadAll();
-                
-                return resources;
-                
-            } catch (IOException e) {
-                // since we test that folders are folders, and files are files, this shouldn't
-                // happen. We can ignore it.
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Initial project parsing to gather resource info.
-     * @param project
-     */
-    private void createProject(IProject project) {
-        if (project.isOpen()) {
-            try {
-                if (project.hasNature(AndroidConstants.NATURE) == false) {
-                    return;
-                }
-            } catch (CoreException e1) {
-                // can't check the nature of the project? ignore it.
-                return;
-            }
-            
-            IFolder resourceFolder = project.getFolder(SdkConstants.FD_RESOURCES);
-            
-            ProjectResources projectResources = mMap.get(project);
-            if (projectResources == null) {
-                projectResources = new ProjectResources(false /* isFrameworkRepository */);
-                mMap.put(project, projectResources);
-            }
-            
-            if (resourceFolder != null && resourceFolder.exists()) {
-                try {
-                    IResource[] resources = resourceFolder.members();
-                    
-                    for (IResource res : resources) {
-                        if (res.getType() == IResource.FOLDER) {
-                            IFolder folder = (IFolder)res;
-                            ResourceFolder resFolder = processFolder(new IFolderWrapper(folder),
-                                    projectResources);
-                            
-                            if (resFolder != null) {
-                                // now we process the content of the folder
-                                IResource[] files = folder.members();
-                                
-                                for (IResource fileRes : files) {
-                                    if (fileRes.getType() == IResource.FILE) {
-                                        IFile file = (IFile)fileRes;
-                                        
-                                        processFile(new IFileWrapper(file), resFolder);
-                                    }
-                                }
-                            }
-                        }
-                    }
-                } catch (CoreException e) {
-                    // This happens if the project is closed or if the folder doesn't exist.
-                    // Since we already test for that, we can ignore this exception.
-                }
-            }
-        }
-    }
-
-    /**
-     * Creates a {@link FolderConfiguration} matching the folder segments.
-     * @param folderSegments The segments of the folder name. The first segments should contain
-     * the name of the folder
-     * @return a FolderConfiguration object, or null if the folder name isn't valid..
-     */
-    public FolderConfiguration getConfig(String[] folderSegments) {
-        FolderConfiguration config = new FolderConfiguration();
-
-        // we are going to loop through the segments, and match them with the first
-        // available qualifier. If the segment doesn't match we try with the next qualifier.
-        // Because the order of the qualifier is fixed, we do not reset the first qualifier
-        // after each sucessful segment.
-        // If we run out of qualifier before processing all the segments, we fail.
-        
-        int qualifierIndex = 0;
-        int qualifierCount = mQualifiers.length;
-        
-        for (int i = 1 ; i < folderSegments.length; i++) {
-            String seg = folderSegments[i];
-            if (seg.length() > 0) {
-                while (qualifierIndex < qualifierCount &&
-                        mQualifiers[qualifierIndex].checkAndSet(seg, config) == false) {
-                    qualifierIndex++;
-                }
-                
-                // if we reached the end of the qualifier we didn't find a matching qualifier.
-                if (qualifierIndex == qualifierCount) {
-                    return null;
-                }
-                
-            } else {
-                return null;
-            }
-        }
-
-        return config;
-    }
-    
-    /**
-     * Processes a folder and adds it to the list of the project resources.
-     * @param folder the folder to process
-     * @param project the folder's project.
-     * @return the ConfiguredFolder created from this folder, or null if the process failed.
-     */
-    private ResourceFolder processFolder(IAbstractFolder folder, ProjectResources project) {
-        // split the name of the folder in segments.
-        String[] folderSegments = folder.getName().split(FolderConfiguration.QUALIFIER_SEP);
-
-        // get the enum for the resource type.
-        ResourceFolderType type = ResourceFolderType.getTypeByName(folderSegments[0]);
-        
-        if (type != null) {
-            // get the folder configuration.
-            FolderConfiguration config = getConfig(folderSegments);
-            
-            if (config != null) {
-                ResourceFolder configuredFolder = project.add(type, config, folder);
-
-                return configuredFolder;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Processes a file and adds it to its parent folder resource.
-     * @param file
-     * @param folder
-     */
-    private void processFile(IAbstractFile file, ResourceFolder folder) {
-        // get the type of the folder
-        ResourceFolderType type = folder.getType();
-        
-        // look for this file if it's already been created
-        ResourceFile resFile = folder.getFile(file);
-        
-        if (resFile != null) {
-            // invalidate the file
-            resFile.touch();
-        } else {
-            // create a ResourceFile for it.
-            
-            // check if that's a single or multi resource type folder. For now we define this by
-            // the number of possible resource type output by files in the folder. This does
-            // not make the difference between several resource types from a single file or
-            // the ability to have 2 files in the same folder generating 2 different types of
-            // resource. The former is handled by MultiResourceFile properly while we don't
-            // handle the latter. If we were to add this behavior we'd have to change this call.
-            ResourceType[] types = FolderTypeRelationship.getRelatedResourceTypes(type);
-    
-            if (types.length == 1) {
-                resFile = new SingleResourceFile(file, folder);
-            } else {
-                resFile = new MultiResourceFile(file, folder);
-            }
-    
-            // add it to the folder
-            folder.addFile(resFile);
-        }
-    }
-
-    /**
-     * Returns true if the path is under /project/res/
-     * @param path a workspace relative path
-     * @return true if the path is under /project res/
-     */
-    private boolean isInResFolder(IPath path) {
-        return SdkConstants.FD_RESOURCES.equalsIgnoreCase(path.segment(1));
-    }
-    
-    /**
-     * Private constructor to enforce singleton design.
-     */
-    ResourceManager() {
-        // get the default qualifiers.
-        FolderConfiguration defaultConfig = new FolderConfiguration();
-        defaultConfig.createDefault();
-        mQualifiers = defaultConfig.getQualifiers();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceMonitor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceMonitor.java
deleted file mode 100644
index 59a72fb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/ResourceMonitor.java
+++ /dev/null
@@ -1,377 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.project.BaseProjectHelper;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarkerDelta;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceChangeEvent;
-import org.eclipse.core.resources.IResourceChangeListener;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-
-import java.util.ArrayList;
-
-/**
- * Resource Monitor for the whole editor plugin. Other, more simple, listeners can register to
- * that one.
- */
-public class ResourceMonitor implements IResourceChangeListener {
-
-    private final static ResourceMonitor sThis = new ResourceMonitor();
-
-    /**
-     * Classes which implement this interface provide a method that deals
-     * with file change events.
-     */
-    public interface IFileListener {
-        /**
-         * Sent when a file changed.
-         * @param file The file that changed.
-         * @param markerDeltas The marker deltas for the file.
-         * @param kind The change kind. This is equivalent to
-         * {@link IResourceDelta#accept(IResourceDeltaVisitor)}
-         */
-        public void fileChanged(IFile file, IMarkerDelta[] markerDeltas, int kind);
-    }
-
-    /**
-     * Classes which implements this interface provide methods dealing with project events.
-     */
-    public interface IProjectListener {
-        /**
-         * Sent for each opened android project at the time the listener is put in place.
-         * @param project the opened project.
-         */
-        public void projectOpenedWithWorkspace(IProject project);
-        /**
-         * Sent when a project is opened.
-         * @param project the project being opened.
-         */
-        public void projectOpened(IProject project);
-        /**
-         * Sent when a project is closed.
-         * @param project the project being closed.
-         */
-        public void projectClosed(IProject project);
-        /**
-         * Sent when a project is deleted.
-         * @param project the project about to be deleted.
-         */
-        public void projectDeleted(IProject project);
-    }
-
-    /**
-     * Classes which implement this interface provide a method that deals
-     * with folder change events
-     */
-    public interface IFolderListener {
-        /**
-         * Sent when a folder changed.
-         * @param folder The file that was changed
-         * @param kind The change kind. This is equivalent to {@link IResourceDelta#getKind()}
-         */
-        public void folderChanged(IFolder folder, int kind);
-    }
-    
-    /**
-     * Interface for a listener to be notified when resource change event starts and ends.
-     */
-    public interface IResourceEventListener {
-        public void resourceChangeEventStart();
-        public void resourceChangeEventEnd();
-    }
-    
-    /**
-     * Base listener bundle to associate a listener to an event mask.
-     */
-    private static class ListenerBundle {
-        /** Mask value to accept all events */
-        public final static int MASK_NONE = -1; 
-
-        /**
-         * Event mask. Values accepted are IResourceDelta.###
-         * @see IResourceDelta#ADDED
-         * @see IResourceDelta#REMOVED
-         * @see IResourceDelta#CHANGED
-         * @see IResourceDelta#ADDED_PHANTOM
-         * @see IResourceDelta#REMOVED_PHANTOM
-         * */
-        int kindMask;
-    }
-    
-    /**
-     * Listener bundle for file event.
-     */
-    private static class FileListenerBundle extends ListenerBundle {
-
-        /** The file listener */
-        IFileListener listener;
-    }
-    
-    /**
-     * Listener bundle for folder event.
-     */
-    private static class FolderListenerBundle extends ListenerBundle {
-        /** The file listener */
-        IFolderListener listener;
-    }
-    
-    private final ArrayList<FileListenerBundle> mFileListeners =
-        new ArrayList<FileListenerBundle>();
-
-    private final ArrayList<FolderListenerBundle> mFolderListeners =
-        new ArrayList<FolderListenerBundle>();
-
-    private final ArrayList<IProjectListener> mProjectListeners = new ArrayList<IProjectListener>();
-    
-    private final ArrayList<IResourceEventListener> mEventListeners =
-        new ArrayList<IResourceEventListener>();
-    
-    private IWorkspace mWorkspace;
-
-    /**
-     * Delta visitor for resource changes.
-     */
-    private final class DeltaVisitor implements IResourceDeltaVisitor {
-
-        public boolean visit(IResourceDelta delta) {
-            IResource r = delta.getResource();
-            int type = r.getType();
-            if (type == IResource.FILE) {
-                int kind = delta.getKind();
-                // notify the listeners.
-                for (FileListenerBundle bundle : mFileListeners) {
-                    if (bundle.kindMask == ListenerBundle.MASK_NONE
-                            || (bundle.kindMask & kind) != 0) {
-                        bundle.listener.fileChanged((IFile)r, delta.getMarkerDeltas(), kind);
-                    }
-                }
-                return false;
-            } else if (type == IResource.FOLDER) {
-                int kind = delta.getKind();
-                // notify the listeners.
-                for (FolderListenerBundle bundle : mFolderListeners) {
-                    if (bundle.kindMask == ListenerBundle.MASK_NONE
-                            || (bundle.kindMask & kind) != 0) {
-                        bundle.listener.folderChanged((IFolder)r, kind);
-                    }
-                }
-                return true;
-            } else if (type == IResource.PROJECT) {
-                int flags = delta.getFlags();
-
-                if (flags == IResourceDelta.OPEN) {
-                    // the project is opening or closing.
-                    IProject project = (IProject)r;
-                    
-                    if (project.isOpen()) {
-                        // notify the listeners.
-                        for (IProjectListener pl : mProjectListeners) {
-                            pl.projectOpened(project);
-                        }
-                    } else {
-                        // notify the listeners.
-                        for (IProjectListener pl : mProjectListeners) {
-                            pl.projectClosed(project);
-                        }
-                    }
-                }
-            }
-
-            return true;
-        }
-    }
-    
-    public static ResourceMonitor getMonitor() {
-        return sThis;
-    }
-
-    
-    /**
-     * Starts the resource monitoring.
-     * @param ws The current workspace.
-     * @return The monitor object.
-     */
-    public static ResourceMonitor startMonitoring(IWorkspace ws) {
-        if (sThis != null) {
-            ws.addResourceChangeListener(sThis,
-                    IResourceChangeEvent.POST_CHANGE | IResourceChangeEvent.PRE_DELETE);
-            sThis.mWorkspace = ws;
-        }
-        return sThis;
-    }
-
-    /**
-     * Stops the resource monitoring.
-     * @param ws The current workspace.
-     */
-    public static void stopMonitoring(IWorkspace ws) {
-        if (sThis != null) {
-            ws.removeResourceChangeListener(sThis);
-            
-            sThis.mFileListeners.clear();
-            sThis.mProjectListeners.clear();
-        }
-    }
-
-    /**
-     * Adds a file listener.
-     * @param listener The listener to receive the events.
-     * @param kindMask The event mask to filter out specific events.
-     * {@link ListenerBundle#MASK_NONE} will forward all events. 
-     */
-    public synchronized void addFileListener(IFileListener listener, int kindMask) {
-        FileListenerBundle bundle = new FileListenerBundle();
-        bundle.listener = listener;
-        bundle.kindMask = kindMask;
-        
-        mFileListeners.add(bundle);
-    }
-    
-    /**
-     * Removes an existing file listener.
-     * @param listener the listener to remove.
-     */
-    public synchronized void removeFileListener(IFileListener listener) {
-        for (int i = 0 ; i < mFileListeners.size() ; i++) {
-            FileListenerBundle bundle = mFileListeners.get(i);
-            if (bundle.listener == listener) {
-                mFileListeners.remove(i);
-                return;
-            }
-        }
-    }
-
-    /**
-     * Adds a folder listener.
-     * @param listener The listener to receive the events.
-     * @param kindMask The event mask to filter out specific events.
-     * {@link ListenerBundle#MASK_NONE} will forward all events. 
-     */
-    public synchronized void addFolderListener(IFolderListener listener, int kindMask) {
-        FolderListenerBundle bundle = new FolderListenerBundle();
-        bundle.listener = listener;
-        bundle.kindMask = kindMask;
-        
-        mFolderListeners.add(bundle);
-    }
-
-    /**
-     * Removes an existing folder listener.
-     * @param listener the listener to remove.
-     */
-    public synchronized void removeFolderListener(IFolderListener listener) {
-        for (int i = 0 ; i < mFolderListeners.size() ; i++) {
-            FolderListenerBundle bundle = mFolderListeners.get(i);
-            if (bundle.listener == listener) {
-                mFolderListeners.remove(i);
-                return;
-            }
-        }
-    }
-
-    /**
-     * Adds a project listener.
-     * @param listener The listener to receive the events.
-     */
-    public synchronized void addProjectListener(IProjectListener listener) {
-        mProjectListeners.add(listener);
-        
-        // we need to look at the opened projects and give them to the listener.
-
-        // get the list of opened android projects.
-        IWorkspaceRoot workspaceRoot = mWorkspace.getRoot();
-        IJavaModel javaModel = JavaCore.create(workspaceRoot);
-        IJavaProject[] androidProjects = BaseProjectHelper.getAndroidProjects(javaModel);
-
-        for (IJavaProject androidProject : androidProjects) {
-            listener.projectOpenedWithWorkspace(androidProject.getProject());
-        }
-    }
-    
-    /**
-     * Removes an existing project listener.
-     * @param listener the listener to remove.
-     */
-    public synchronized void removeProjectListener(IProjectListener listener) {
-        mProjectListeners.remove(listener);
-    }
-    
-    /**
-     * Adds a resource event listener.
-     * @param listener The listener to receive the events.
-     */
-    public synchronized void addResourceEventListener(IResourceEventListener listener) {
-        mEventListeners.add(listener);
-    }
-
-    /**
-     * Removes an existing Resource Event listener.
-     * @param listener the listener to remove.
-     */
-    public synchronized void removeResourceEventListener(IResourceEventListener listener) {
-        mEventListeners.remove(listener);
-    }
-
-    /**
-     * Processes the workspace resource change events.
-     */
-    public void resourceChanged(IResourceChangeEvent event) {
-        // notify the event listeners of a start.
-        for (IResourceEventListener listener : mEventListeners) {
-            listener.resourceChangeEventStart();
-        }
-        
-        if (event.getType() == IResourceChangeEvent.PRE_DELETE) {
-            // a project is being deleted. Lets get the project object and remove
-            // its compiled resource list.
-            IResource r = event.getResource();
-            IProject project = r.getProject();
-
-            // notify the listeners.
-            for (IProjectListener pl : mProjectListeners) {
-                pl.projectDeleted(project);
-            }
-        } else {
-            // this a regular resource change. We get the delta and go through it with a visitor.
-            IResourceDelta delta = event.getDelta();
-            
-            DeltaVisitor visitor = new DeltaVisitor();
-            try {
-                delta.accept(visitor);
-            } catch (CoreException e) {
-            }
-        }
-
-        // we're done, notify the event listeners.
-        for (IResourceEventListener listener : mEventListeners) {
-            listener.resourceChangeEventEnd();
-        }
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/SingleResourceFile.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/SingleResourceFile.java
deleted file mode 100644
index 32b1107..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/SingleResourceFile.java
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFile;
-import com.android.layoutlib.api.IResourceValue;
-import com.android.layoutlib.utils.ResourceValue;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.xml.parsers.SAXParserFactory;
-
-/**
- * Represents a resource file describing a single resource.
- * <p/>
- * This is typically an XML file inside res/anim, res/layout, or res/menu or an image file
- * under res/drawable.
- */
-public class SingleResourceFile extends ResourceFile {
-
-    private final static SAXParserFactory sParserFactory = SAXParserFactory.newInstance();
-    static {
-        sParserFactory.setNamespaceAware(true);
-    }
-    
-    private final static Pattern sXmlPattern = Pattern.compile("^(.+)\\.xml", //$NON-NLS-1$
-            Pattern.CASE_INSENSITIVE);
-    
-    private final static Pattern[] sDrawablePattern = new Pattern[] {
-        Pattern.compile("^(.+)\\.9\\.png", Pattern.CASE_INSENSITIVE), //$NON-NLS-1$
-        Pattern.compile("^(.+)\\.png", Pattern.CASE_INSENSITIVE), //$NON-NLS-1$
-        Pattern.compile("^(.+)\\.jpg", Pattern.CASE_INSENSITIVE), //$NON-NLS-1$
-        Pattern.compile("^(.+)\\.gif", Pattern.CASE_INSENSITIVE), //$NON-NLS-1$
-    };
-    
-    private String mResourceName;
-    private ResourceType mType;
-    private IResourceValue mValue;
-
-    public SingleResourceFile(IAbstractFile file, ResourceFolder folder) {
-        super(file, folder);
-        
-        // we need to infer the type of the resource from the folder type.
-        // This is easy since this is a single Resource file.
-        ResourceType[] types = FolderTypeRelationship.getRelatedResourceTypes(folder.getType());
-        mType = types[0];
-
-        // compute the resource name
-        mResourceName = getResourceName(mType);
-        
-        mValue = new ResourceValue(mType.getName(), getResourceName(mType), file.getOsLocation(),
-                isFramework());
-    }
-
-    @Override
-    public ResourceType[] getResourceTypes() {
-        return FolderTypeRelationship.getRelatedResourceTypes(getFolder().getType());
-    }
-
-    @Override
-    public boolean hasResources(ResourceType type) {
-        return FolderTypeRelationship.match(type, getFolder().getType());
-    }
-
-    @Override
-    public Collection<ProjectResourceItem> getResources(ResourceType type,
-            ProjectResources projectResources) {
-        
-        // looking for an existing ResourceItem with this name and type
-        ProjectResourceItem item = projectResources.findResourceItem(type, mResourceName);
-        
-        ArrayList<ProjectResourceItem> items = new ArrayList<ProjectResourceItem>();
-
-        if (item == null) {
-            item = new ConfigurableResourceItem(mResourceName);
-            items.add(item);
-        }
-        
-        // add this ResourceFile to the ResourceItem
-        item.add(this);
-        
-        return items;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ide.eclipse.editors.resources.manager.ResourceFile#getValue(com.android.ide.eclipse.common.resources.ResourceType, java.lang.String)
-     * 
-     * This particular implementation does not care about the type or name since a
-     * SingleResourceFile represents a file generating only one resource.
-     * The value returned is the full absolute path of the file in OS form.
-     */
-    @Override
-    public IResourceValue getValue(ResourceType type, String name) {
-        return mValue;
-    }
-    
-    /**
-     * Returns the name of the resources.
-     */
-    private String getResourceName(ResourceType type) {
-        // get the name from the filename.
-        String name = getFile().getName();
-        
-        if (type == ResourceType.ANIM || type == ResourceType.LAYOUT || type == ResourceType.MENU ||
-                type == ResourceType.COLOR || type == ResourceType.XML) {
-            Matcher m = sXmlPattern.matcher(name);
-            if (m.matches()) {
-                return m.group(1);
-            }
-        } else if (type == ResourceType.DRAWABLE) {
-            for (Pattern p : sDrawablePattern) {
-                Matcher m = p.matcher(name);
-                if (m.matches()) {
-                    return m.group(1);
-                }
-            }
-            
-            // also try the Xml pattern for selector/shape based drawable.
-            Matcher m = sXmlPattern.matcher(name);
-            if (m.matches()) {
-                return m.group(1);
-            }
-        }
-        return name;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FileWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FileWrapper.java
deleted file mode 100644
index d99cb13..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FileWrapper.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFile;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-
-/**
- * An implementation of {@link IAbstractFile} on top of a {@link File} object.
- *
- */
-public class FileWrapper implements IAbstractFile {
-    
-    private File mFile;
-
-    /**
-     * Constructs a {@link FileWrapper} object. If {@link File#isFile()} returns <code>false</code>
-     * then an {@link IOException} is thrown. 
-     */
-    public FileWrapper(File file) throws IOException {
-        if (file.isFile() == false) {
-            throw new IOException("FileWrapper must wrap a File object representing an existing file!"); //$NON-NLS-1$
-        }
-        
-        mFile = file;
-    }
-
-    public InputStream getContents() {
-        try {
-            return new FileInputStream(mFile);
-        } catch (FileNotFoundException e) {
-            // we'll return null below.
-        }
-        
-        return null;
-    }
-
-    public IFile getIFile() {
-        return null;
-    }
-
-    public String getOsLocation() {
-        return mFile.getAbsolutePath();
-    }
-
-    public String getName() {
-        return mFile.getName();
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof FileWrapper) {
-            return mFile.equals(((FileWrapper)obj).mFile);
-        }
-        
-        if (obj instanceof File) {
-            return mFile.equals(obj);
-        }
-
-        return super.equals(obj);
-    }
-    
-    @Override
-    public int hashCode() {
-        return mFile.hashCode();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FolderWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FolderWrapper.java
deleted file mode 100644
index 9ad7460..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/FolderWrapper.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFolder;
-
-import java.io.File;
-import java.io.IOException;
-
-/**
- * An implementation of {@link IAbstractFolder} on top of a {@link File} object.
- */
-public class FolderWrapper implements IAbstractFolder {
-
-    private File mFolder;
-
-    /**
-     * Constructs a {@link FileWrapper} object. If {@link File#isDirectory()} returns
-     * <code>false</code> then an {@link IOException} is thrown. 
-     */
-    public FolderWrapper(File folder) throws IOException {
-        if (folder.isDirectory() == false) {
-            throw new IOException("FileWrapper must wrap a File object representing an existing folder!"); //$NON-NLS-1$
-        }
-        
-        mFolder = folder;
-    }
-    
-    public boolean hasFile(String name) {
-        return false;
-    }
-
-    public String getName() {
-        return mFolder.getName();
-    }
-
-    public IFolder getIFolder() {
-        return null;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof FolderWrapper) {
-            return mFolder.equals(((FolderWrapper)obj).mFolder);
-        }
-        
-        if (obj instanceof File) {
-            return mFolder.equals(obj);
-        }
-
-        return super.equals(obj);
-    }
-    
-    @Override
-    public int hashCode() {
-        return mFolder.hashCode();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFile.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFile.java
deleted file mode 100644
index 7e807f9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFile.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-import java.io.InputStream;
-
-/**
- * A file.
- */
-public interface IAbstractFile extends IAbstractResource {
-
-    /**
-     * Returns an {@link InputStream} object on the file content.
-     * @throws CoreException
-     */
-    InputStream getContents() throws CoreException;
-
-    /**
-     * Returns the OS path of the file location.
-     */
-    String getOsLocation();
-
-    /**
-     * Returns the {@link IFile} object that the receiver could represent. Can be <code>null</code>
-     */
-    IFile getIFile();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFolder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFolder.java
deleted file mode 100644
index b35283d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractFolder.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFolder;
-
-/**
- *  A folder.
- */
-public interface IAbstractFolder extends IAbstractResource {
-
-    /**
-     * Returns true if the receiver contains a file with a given name 
-     * @param name the name of the file. This is the name without the path leading to the
-     * parent folder.
-     */
-    boolean hasFile(String name);
-
-    /**
-     * Returns the {@link IFolder} object that the receiver could represent.
-     * Can be <code>null</code>
-     */
-    IFolder getIFolder();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractResource.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractResource.java
deleted file mode 100644
index daf243d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IAbstractResource.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFile;
-
-import java.io.File;
-
-/**
- * Base representation of a file system resource.<p/>
- * This somewhat limited interface is designed to let classes use file-system resources, without
- * having the manually handle  {@link IFile} and/or {@link File} manually.
- */
-public interface IAbstractResource {
-
-    /**
-     * Returns the name of the resource.
-     */
-    String getName();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFileWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFileWrapper.java
deleted file mode 100644
index f0f5f2d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFileWrapper.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-
-import java.io.InputStream;
-
-/**
- * An implementation of {@link IAbstractFile} on top of an {@link IFile} object.
- */
-public class IFileWrapper implements IAbstractFile {
-
-    private IFile mFile;
-
-    public IFileWrapper(IFile file) {
-        mFile = file;
-    }
-    
-    public InputStream getContents() throws CoreException {
-        return mFile.getContents();
-    }
-
-    public String getOsLocation() {
-        return mFile.getLocation().toOSString();
-    }
-
-    public String getName() {
-        return mFile.getName();
-    }
-
-    public IFile getIFile() {
-        return mFile;
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof IFileWrapper) {
-            return mFile.equals(((IFileWrapper)obj).mFile);
-        }
-        
-        if (obj instanceof IFile) {
-            return mFile.equals(obj);
-        }
-
-        return super.equals(obj);
-    }
-    
-    @Override
-    public int hashCode() {
-        return mFile.hashCode();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFolderWrapper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFolderWrapper.java
deleted file mode 100644
index b1fa3ef..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/manager/files/IFolderWrapper.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager.files;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-
-/**
- * An implementation of {@link IAbstractFolder} on top of an {@link IFolder} object.
- */
-public class IFolderWrapper implements IAbstractFolder {
-    
-    private IFolder mFolder;
-
-    public IFolderWrapper(IFolder folder) {
-        mFolder = folder;
-    }
-
-    public String getName() {
-        return mFolder.getName();
-    }
-
-    public boolean hasFile(String name) {
-        try {
-            IResource[] files = mFolder.members();
-            for (IResource file : files) {
-                if (name.equals(file.getName())) {
-                    return true;
-                }
-            }
-        } catch (CoreException e) {
-            // we'll return false below.
-        }
-
-        return false;
-    }
-    
-    public IFolder getIFolder() {
-        return mFolder;
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof IFolderWrapper) {
-            return mFolder.equals(((IFolderWrapper)obj).mFolder);
-        }
-        
-        if (obj instanceof IFolder) {
-            return mFolder.equals(obj);
-        }
-
-        return super.equals(obj);
-    }
-    
-    @Override
-    public int hashCode() {
-        return mFolder.hashCode();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiColorValueNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiColorValueNode.java
deleted file mode 100644
index 29453e9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiColorValueNode.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.TextValueDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.ide.eclipse.editors.uimodel.UiTextValueNode;
-
-import org.eclipse.jface.dialogs.IMessageProvider;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.regex.Pattern;
-
-/**
- * Displays and edits a color XML element value with a custom validator.
- * <p/>
- * See {@link UiAttributeNode} for more information.
- */
-public class UiColorValueNode extends UiTextValueNode {
-
-    /** Accepted RGBA formats are one of #RGB, #ARGB, #RRGGBB or #AARRGGBB. */
-    private static final Pattern RGBA_REGEXP = Pattern.compile(
-            "#(?:[0-9a-fA-F]{3,4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})"); //$NON-NLS-1$
-    
-    public UiColorValueNode(TextValueDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-
-    /* (non-java doc)
-     * 
-     * Add a modify listener that will check colors have the proper format,
-     * that is one of #RGB, #ARGB, #RRGGBB or #AARRGGBB.
-     */
-    @Override
-    protected void onAddValidators(final Text text) {
-        ModifyListener listener = new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                String color = text.getText();
-                if (RGBA_REGEXP.matcher(color).matches()) {
-                    getManagedForm().getMessageManager().removeMessage(text, text);
-                } else {
-                    getManagedForm().getMessageManager().addMessage(text,
-                            "Accepted color formats are one of #RGB, #ARGB, #RRGGBB or #AARRGGBB.",
-                            null /* data */, IMessageProvider.ERROR, text);
-                }
-            }
-        };
-
-        text.addModifyListener(listener);
-
-        // Make sure the validator removes its message(s) when the widget is disposed
-        text.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                getManagedForm().getMessageManager().removeMessage(text, text);
-            }
-        });
-
-        // Finally call the validator once to make sure the initial value is processed
-        listener.modifyText(null);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiItemElementNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiItemElementNode.java
deleted file mode 100644
index 89649f5..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/resources/uimodel/UiItemElementNode.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.resources.descriptors.ItemElementDescriptor;
-import com.android.ide.eclipse.editors.resources.descriptors.ResourcesDescriptors;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * {@link UiItemElementNode} is apecial version of {@link UiElementNode} that 
- * customizes the element display to include the item type attribute if present.
- */
-public class UiItemElementNode extends UiElementNode {
-
-    /**
-     * Creates a new {@link UiElementNode} described by a given {@link ItemElementDescriptor}.
-     * 
-     * @param elementDescriptor The {@link ItemElementDescriptor} for the XML node. Cannot be null.
-     */
-    public UiItemElementNode(ItemElementDescriptor elementDescriptor) {
-        super(elementDescriptor);
-    }
-
-    @Override
-    public String getShortDescription() {
-        Node xmlNode = getXmlNode();
-        if (xmlNode != null && xmlNode instanceof Element && xmlNode.hasAttributes()) {
-
-            Element elem = (Element) xmlNode;
-            String type = elem.getAttribute(ResourcesDescriptors.TYPE_ATTR);
-            String name = elem.getAttribute(ResourcesDescriptors.NAME_ATTR);
-            if (type != null && name != null && type.length() > 0 && name.length() > 0) {
-                type = DescriptorsUtils.capitalize(type);
-                return String.format("%1$s (%2$s %3$s)", name, type, getDescriptor().getUiName());
-            }
-        }
-
-        return super.getShortDescription();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/EditableDialogCellEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/EditableDialogCellEditor.java
deleted file mode 100644
index 5fb479f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/EditableDialogCellEditor.java
+++ /dev/null
@@ -1,458 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.viewers.DialogCellEditor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.TraverseEvent;
-import org.eclipse.swt.events.TraverseListener;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-
-import java.text.MessageFormat;
-
-/**
- * Custom DialogCellEditor, replacing the Label with an editable {@link Text} widget.
- * <p/>Also set the button to {@link SWT#FLAT} to make sure it looks good on MacOS X.
- * <p/>Most of the code comes from TextCellEditor.
- */
-public abstract class EditableDialogCellEditor extends DialogCellEditor {
-    
-    private Text text; 
-    
-    private ModifyListener modifyListener;
-
-    /**
-     * State information for updating action enablement
-     */
-    private boolean isSelection = false;
-
-    private boolean isDeleteable = false;
-
-    private boolean isSelectable = false;
-    
-    EditableDialogCellEditor(Composite parent) {
-        super(parent);
-    }
-
-    /*
-     * Re-implement this method only to properly set the style in the button, or it won't look
-     * good in MacOS X
-     */
-    @Override
-    protected Button createButton(Composite parent) {
-        Button result = new Button(parent, SWT.DOWN | SWT.FLAT);
-        result.setText("..."); //$NON-NLS-1$
-        return result;
-    }
-
-    
-    @Override
-    protected Control createContents(Composite cell) {
-        text = new Text(cell, SWT.SINGLE);
-        text.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetDefaultSelected(SelectionEvent e) {
-                handleDefaultSelection(e);
-            }
-        });
-        text.addKeyListener(new KeyAdapter() {
-            // hook key pressed - see PR 14201  
-            @Override
-            public void keyPressed(KeyEvent e) {
-                keyReleaseOccured(e);
-
-                // as a result of processing the above call, clients may have
-                // disposed this cell editor
-                if ((getControl() == null) || getControl().isDisposed()) {
-                    return;
-                }
-                checkSelection(); // see explanation below
-                checkDeleteable();
-                checkSelectable();
-            }
-        });
-        text.addTraverseListener(new TraverseListener() {
-            public void keyTraversed(TraverseEvent e) {
-                if (e.detail == SWT.TRAVERSE_ESCAPE
-                        || e.detail == SWT.TRAVERSE_RETURN) {
-                    e.doit = false;
-                }
-            }
-        });
-        // We really want a selection listener but it is not supported so we
-        // use a key listener and a mouse listener to know when selection changes
-        // may have occurred
-        text.addMouseListener(new MouseAdapter() {
-            @Override
-            public void mouseUp(MouseEvent e) {
-                checkSelection();
-                checkDeleteable();
-                checkSelectable();
-            }
-        });
-        text.addFocusListener(new FocusAdapter() {
-            @Override
-            public void focusLost(FocusEvent e) {
-                EditableDialogCellEditor.this.focusLost();
-            }
-        });
-        text.setFont(cell.getFont());
-        text.setBackground(cell.getBackground());
-        text.setText("");//$NON-NLS-1$
-        text.addModifyListener(getModifyListener());
-        return text;
-    }
-
-   /**
-     * Checks to see if the "deletable" state (can delete/
-     * nothing to delete) has changed and if so fire an
-     * enablement changed notification.
-     */
-    private void checkDeleteable() {
-        boolean oldIsDeleteable = isDeleteable;
-        isDeleteable = isDeleteEnabled();
-        if (oldIsDeleteable != isDeleteable) {
-            fireEnablementChanged(DELETE);
-        }
-    }
-
-    /**
-     * Checks to see if the "selectable" state (can select)
-     * has changed and if so fire an enablement changed notification.
-     */
-    private void checkSelectable() {
-        boolean oldIsSelectable = isSelectable;
-        isSelectable = isSelectAllEnabled();
-        if (oldIsSelectable != isSelectable) {
-            fireEnablementChanged(SELECT_ALL);
-        }
-    }
-
-    /**
-     * Checks to see if the selection state (selection /
-     * no selection) has changed and if so fire an
-     * enablement changed notification.
-     */
-    private void checkSelection() {
-        boolean oldIsSelection = isSelection;
-        isSelection = text.getSelectionCount() > 0;
-        if (oldIsSelection != isSelection) {
-            fireEnablementChanged(COPY);
-            fireEnablementChanged(CUT);
-        }
-    }
-
-    /* (non-Javadoc)
-     * Method declared on CellEditor.
-     */
-    @Override
-    protected void doSetFocus() {
-        if (text != null) {
-            text.selectAll();
-            text.setFocus();
-            checkSelection();
-            checkDeleteable();
-            checkSelectable();
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.jface.viewers.DialogCellEditor#updateContents(java.lang.Object)
-     */
-    @Override
-    protected void updateContents(Object value) {
-        Assert.isTrue(text != null && (value == null || (value instanceof String)));
-        if (value != null) {
-            text.removeModifyListener(getModifyListener());
-            text.setText((String) value);
-            text.addModifyListener(getModifyListener());
-        }
-    }
-    
-    /**
-     * The <code>TextCellEditor</code> implementation of
-     * this <code>CellEditor</code> framework method returns
-     * the text string.
-     *
-     * @return the text string
-     */
-    @Override
-    protected Object doGetValue() {
-        return text.getText();
-    }
-
-
-    /**
-     * Processes a modify event that occurred in this text cell editor.
-     * This framework method performs validation and sets the error message
-     * accordingly, and then reports a change via <code>fireEditorValueChanged</code>.
-     * Subclasses should call this method at appropriate times. Subclasses
-     * may extend or reimplement.
-     *
-     * @param e the SWT modify event
-     */
-    protected void editOccured(ModifyEvent e) {
-        String value = text.getText();
-        if (value == null) {
-            value = "";//$NON-NLS-1$
-        }
-        Object typedValue = value;
-        boolean oldValidState = isValueValid();
-        boolean newValidState = isCorrect(typedValue);
-
-        if (!newValidState) {
-            // try to insert the current value into the error message.
-            setErrorMessage(MessageFormat.format(getErrorMessage(),
-                    new Object[] { value }));
-        }
-        valueChanged(oldValidState, newValidState);
-    }
-
-    /**
-     * Return the modify listener.
-     */
-    private ModifyListener getModifyListener() {
-        if (modifyListener == null) {
-            modifyListener = new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    editOccured(e);
-                }
-            };
-        }
-        return modifyListener;
-    }
-
-    /**
-     * Handles a default selection event from the text control by applying the editor
-     * value and deactivating this cell editor.
-     * 
-     * @param event the selection event
-     * 
-     * @since 3.0
-     */
-    protected void handleDefaultSelection(SelectionEvent event) {
-        // same with enter-key handling code in keyReleaseOccured(e);
-        fireApplyEditorValue();
-        deactivate();
-    }
-
-    /**
-     * The <code>TextCellEditor</code>  implementation of this 
-     * <code>CellEditor</code> method returns <code>true</code> if 
-     * the current selection is not empty.
-     */
-    @Override
-    public boolean isCopyEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return text.getSelectionCount() > 0;
-    }
-
-    /**
-     * The <code>TextCellEditor</code>  implementation of this 
-     * <code>CellEditor</code> method returns <code>true</code> if 
-     * the current selection is not empty.
-     */
-    @Override
-    public boolean isCutEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return text.getSelectionCount() > 0;
-    }
-
-    /**
-     * The <code>TextCellEditor</code>  implementation of this 
-     * <code>CellEditor</code> method returns <code>true</code>
-     * if there is a selection or if the caret is not positioned 
-     * at the end of the text.
-     */
-    @Override
-    public boolean isDeleteEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return text.getSelectionCount() > 0
-                || text.getCaretPosition() < text.getCharCount();
-    }
-
-    /**
-     * The <code>TextCellEditor</code>  implementation of this 
-     * <code>CellEditor</code> method always returns <code>true</code>.
-     */
-    @Override
-    public boolean isPasteEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return true;
-    }
-
-    /**
-     * Check if save all is enabled
-     * @return true if it is 
-     */
-    public boolean isSaveAllEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return true;
-    }
-
-    /**
-     * Returns <code>true</code> if this cell editor is
-     * able to perform the select all action.
-     * <p>
-     * This default implementation always returns 
-     * <code>false</code>.
-     * </p>
-     * <p>
-     * Subclasses may override
-     * </p>
-     * @return <code>true</code> if select all is possible,
-     *  <code>false</code> otherwise
-     */
-    @Override
-    public boolean isSelectAllEnabled() {
-        if (text == null || text.isDisposed()) {
-            return false;
-        }
-        return text.getCharCount() > 0;
-    }
-
-    /**
-     * Processes a key release event that occurred in this cell editor.
-     * <p>
-     * The <code>TextCellEditor</code> implementation of this framework method 
-     * ignores when the RETURN key is pressed since this is handled in 
-     * <code>handleDefaultSelection</code>.
-     * An exception is made for Ctrl+Enter for multi-line texts, since
-     * a default selection event is not sent in this case. 
-     * </p>
-     *
-     * @param keyEvent the key event
-     */
-    @Override
-    protected void keyReleaseOccured(KeyEvent keyEvent) {
-        if (keyEvent.character == '\r') { // Return key
-            // Enter is handled in handleDefaultSelection.
-            // Do not apply the editor value in response to an Enter key event
-            // since this can be received from the IME when the intent is -not-
-            // to apply the value.  
-            // See bug 39074 [CellEditors] [DBCS] canna input mode fires bogus event from Text Control
-            //
-            // An exception is made for Ctrl+Enter for multi-line texts, since
-            // a default selection event is not sent in this case. 
-            if (text != null && !text.isDisposed()
-                    && (text.getStyle() & SWT.MULTI) != 0) {
-                if ((keyEvent.stateMask & SWT.CTRL) != 0) {
-                    super.keyReleaseOccured(keyEvent);
-                }
-            }
-            return;
-        }
-        super.keyReleaseOccured(keyEvent);
-    }
-
-    /**
-     * The <code>TextCellEditor</code> implementation of this
-     * <code>CellEditor</code> method copies the
-     * current selection to the clipboard. 
-     */
-    @Override
-    public void performCopy() {
-        text.copy();
-    }
-
-    /**
-     * The <code>TextCellEditor</code> implementation of this
-     * <code>CellEditor</code> method cuts the
-     * current selection to the clipboard. 
-     */
-    @Override
-    public void performCut() {
-        text.cut();
-        checkSelection();
-        checkDeleteable();
-        checkSelectable();
-    }
-
-    /**
-     * The <code>TextCellEditor</code> implementation of this
-     * <code>CellEditor</code> method deletes the
-     * current selection or, if there is no selection,
-     * the character next character from the current position. 
-     */
-    @Override
-    public void performDelete() {
-        if (text.getSelectionCount() > 0) {
-            // remove the contents of the current selection
-            text.insert(""); //$NON-NLS-1$
-        } else {
-            // remove the next character
-            int pos = text.getCaretPosition();
-            if (pos < text.getCharCount()) {
-                text.setSelection(pos, pos + 1);
-                text.insert(""); //$NON-NLS-1$
-            }
-        }
-        checkSelection();
-        checkDeleteable();
-        checkSelectable();
-    }
-
-    /**
-     * The <code>TextCellEditor</code> implementation of this
-     * <code>CellEditor</code> method pastes the
-     * the clipboard contents over the current selection. 
-     */
-    @Override
-    public void performPaste() {
-        text.paste();
-        checkSelection();
-        checkDeleteable();
-        checkSelectable();
-    }
-
-    /**
-     * The <code>TextCellEditor</code> implementation of this
-     * <code>CellEditor</code> method selects all of the
-     * current text. 
-     */
-    @Override
-    public void performSelectAll() {
-        text.selectAll();
-        checkSelection();
-        checkDeleteable();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ErrorImageComposite.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ErrorImageComposite.java
deleted file mode 100644
index d095376..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ErrorImageComposite.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package com.android.ide.eclipse.editors.ui;
-
-import org.eclipse.jface.resource.CompositeImageDescriptor;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.DecorationOverlayIcon;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * ImageDescriptor that adds a error marker.
- * Based on {@link DecorationOverlayIcon} only available in Eclipse 3.3
- */
-public class ErrorImageComposite extends CompositeImageDescriptor {
-
-    private Image mBaseImage;
-    private ImageDescriptor mErrorImageDescriptor;
-    private Point mSize;
-
-    public ErrorImageComposite(Image baseImage) {
-        mBaseImage = baseImage;
-        mErrorImageDescriptor = PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(
-                ISharedImages.IMG_OBJS_ERROR_TSK);
-        mSize = new Point(baseImage.getBounds().width, baseImage.getBounds().height);
-    }
-    
-    @Override
-    protected void drawCompositeImage(int width, int height) {
-        ImageData baseData = mBaseImage.getImageData();
-        drawImage(baseData, 0, 0);
-
-        ImageData overlayData = mErrorImageDescriptor.getImageData();
-        if (overlayData.width == baseData.width && baseData.height == baseData.height) {
-            overlayData = overlayData.scaledTo(14, 14);
-            drawImage(overlayData, -3, mSize.y - overlayData.height + 3);
-        } else {
-            drawImage(overlayData, 0, mSize.y - overlayData.height);
-        }
-    }
-
-    @Override
-    protected Point getSize() {
-        return mSize;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/FlagValueCellEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/FlagValueCellEditor.java
deleted file mode 100644
index ccae099..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/FlagValueCellEditor.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.editors.uimodel.UiFlagAttributeNode;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * DialogCellEditor able to receive a {@link UiFlagAttributeNode} in the {@link #setValue(Object)}
- * method.
- * <p/>The dialog box opened is the same as the one in the ui created by
- * {@link UiFlagAttributeNode#createUiControl(Composite, org.eclipse.ui.forms.IManagedForm)}
- */
-public class FlagValueCellEditor extends EditableDialogCellEditor {
-    
-    private UiFlagAttributeNode mUiFlagAttribute;
-
-    public FlagValueCellEditor(Composite parent) {
-        super(parent);
-    }
-    
-    @Override
-    protected Object openDialogBox(Control cellEditorWindow) {
-        if (mUiFlagAttribute != null) {
-            String currentValue = (String)getValue();
-            return mUiFlagAttribute.showDialog(cellEditorWindow.getShell(), currentValue);
-        }
-        
-        return null;
-    }
-    
-    @Override
-    protected void doSetValue(Object value) {
-        if (value instanceof UiFlagAttributeNode) {
-            mUiFlagAttribute = (UiFlagAttributeNode)value;
-            super.doSetValue(mUiFlagAttribute.getCurrentValue());
-            return;
-        }
-        
-        super.doSetValue(value);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ListValueCellEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ListValueCellEditor.java
deleted file mode 100644
index 304dd14..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ListValueCellEditor.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.editors.uimodel.UiListAttributeNode;
-
-import org.eclipse.jface.viewers.ComboBoxCellEditor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * ComboBoxCellEditor able to receive a {@link UiListAttributeNode} in the {@link #setValue(Object)}
- * method, and returning a {@link String} in {@link #getValue()} instead of an {@link Integer}.
- */
-public class ListValueCellEditor extends ComboBoxCellEditor {
-    private String[] mItems;
-    private CCombo mCombo;
-    
-    public ListValueCellEditor(Composite parent) {
-        super(parent, new String[0], SWT.DROP_DOWN);
-    }
-    
-    @Override
-    protected Control createControl(Composite parent) {
-        mCombo = (CCombo) super.createControl(parent);
-        return mCombo;
-    }
-    
-    @Override
-    protected void doSetValue(Object value) {
-        if (value instanceof UiListAttributeNode) {
-            UiListAttributeNode uiListAttribute = (UiListAttributeNode)value;
-            
-            // set the possible values in the combo
-            String[] items = uiListAttribute.getPossibleValues();
-            mItems = new String[items.length];
-            System.arraycopy(items, 0, mItems, 0, items.length);
-            setItems(mItems);
-            
-            // now edit the current value of the attribute
-            String attrValue = uiListAttribute.getCurrentValue();
-            mCombo.setText(attrValue);
-            
-            return;
-        }
-        
-        // default behavior
-        super.doSetValue(value);
-    }
-    
-    @Override
-    protected Object doGetValue() {
-        String comboText = mCombo.getText();
-        if (comboText == null) {
-            return ""; //$NON-NLS-1$
-        }
-        return comboText;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ResourceValueCellEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ResourceValueCellEditor.java
deleted file mode 100644
index 4fc0ab3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/ResourceValueCellEditor.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.editors.uimodel.UiFlagAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiResourceAttributeNode;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * DialogCellEditor able to receive a {@link UiFlagAttributeNode} in the {@link #setValue(Object)}
- * method.
- * <p/>The dialog box opened is the same as the one in the ui created by
- * {@link UiFlagAttributeNode#createUiControl(Composite, org.eclipse.ui.forms.IManagedForm)}
- */
-public class ResourceValueCellEditor extends EditableDialogCellEditor {
-
-    private UiResourceAttributeNode mUiResourceAttribute;
-
-    public ResourceValueCellEditor(Composite parent) {
-        super(parent);
-    }
-
-    @Override
-    protected Object openDialogBox(Control cellEditorWindow) {
-        if (mUiResourceAttribute != null) {
-            String currentValue = (String)getValue();
-            return mUiResourceAttribute.showDialog(cellEditorWindow.getShell(), currentValue);
-        }
-        
-        return null;
-    }
-    
-    @Override
-    protected void doSetValue(Object value) {
-        if (value instanceof UiResourceAttributeNode) {
-            mUiResourceAttribute = (UiResourceAttributeNode)value;
-            super.doSetValue(mUiResourceAttribute.getCurrentValue());
-            return;
-        }
-        
-        super.doSetValue(value);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/SectionHelper.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/SectionHelper.java
deleted file mode 100644
index 409e92f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/SectionHelper.java
+++ /dev/null
@@ -1,348 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.AndroidEditor;
-
-import org.eclipse.jface.text.DefaultInformationControl;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.MouseTrackListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.SectionPart;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-
-import java.lang.reflect.Method;
-
-/**
- * Helper for the AndroidManifest form editor.
- * 
- * Helps create a new SectionPart with sensible default parameters,
- * create default layout or add typical widgets.
- * 
- * IMPORTANT: This is NOT a generic class. It makes a lot of assumptions on the
- * UI as used by the form editor for the AndroidManifest.
- * 
- * TODO: Consider moving to a common package.
- */
-public final class SectionHelper {
-
-    /**
-     * Utility class that derives from SectionPart, constructs the Section with
-     * sensible defaults (with a title and a description) and provide some shorthand
-     * methods for creating typically UI (label and text, form text.)
-     */
-    static public class ManifestSectionPart extends SectionPart {
-
-        /**
-         * Construct a SectionPart that uses a title bar and a description.
-         * It's up to the caller to call setText() and setDescription().
-         * <p/>
-         * The section style includes a description and a title bar by default.
-         * 
-         * @param body The parent (e.g. FormPage body)
-         * @param toolkit Form Toolkit
-         */
-        public ManifestSectionPart(Composite body, FormToolkit toolkit) {
-            this(body, toolkit, 0, false);
-        }
-
-        /**
-         * Construct a SectionPart that uses a title bar and a description.
-         * It's up to the caller to call setText() and setDescription().
-         * <p/>
-         * The section style includes a description and a title bar by default.
-         * You can add extra styles, like Section.TWISTIE.
-         * 
-         * @param body The parent (e.g. FormPage body).
-         * @param toolkit Form Toolkit.
-         * @param extra_style Extra styles (on top of description and title bar).
-         * @param use_description True if the Section.DESCRIPTION style should be added.
-         */
-        public ManifestSectionPart(Composite body, FormToolkit toolkit,
-                int extra_style, boolean use_description) {
-            super(body, toolkit, extra_style |
-                    Section.TITLE_BAR |
-                    (use_description ? Section.DESCRIPTION : 0));
-        }
-
-        // Create non-static methods of helpers just for convenience
-        
-        /**
-         * Creates a new composite with a TableWrapLayout set with a given number of columns.
-         * 
-         * If the parent composite is a Section, the new composite is set as a client.
-         * 
-         * @param toolkit Form Toolkit
-         * @param numColumns Desired number of columns.
-         * @return The new composite.
-         */
-        public Composite createTableLayout(FormToolkit toolkit, int numColumns) {
-            return SectionHelper.createTableLayout(getSection(), toolkit, numColumns);
-        }
-
-        /**
-         * Creates a label widget.
-         * If the parent layout if a TableWrapLayout, maximize it to span over all columns.
-         * 
-         * @param parent The parent (e.g. composite from CreateTableLayout())
-         * @param toolkit Form Toolkit
-         * @param label The string for the label.
-         * @param tooltip An optional tooltip for the label and text. Can be null.
-         * @return The new created label 
-         */
-        public Label createLabel(Composite parent, FormToolkit toolkit, String label,
-                String tooltip) {
-            return SectionHelper.createLabel(parent, toolkit, label, tooltip);
-        }
-
-        /**
-         * Creates two widgets: a label and a text field.
-         * 
-         * This expects the parent composite to have a TableWrapLayout with 2 columns.
-         * 
-         * @param parent The parent (e.g. composite from CreateTableLayout())
-         * @param toolkit Form Toolkit
-         * @param label The string for the label.
-         * @param value The initial value of the text field. Can be null.
-         * @param tooltip An optional tooltip for the label and text. Can be null.
-         * @return The new created Text field (the label is not returned) 
-         */
-        public Text createLabelAndText(Composite parent, FormToolkit toolkit, String label,
-                String value, String tooltip) {
-            return SectionHelper.createLabelAndText(parent, toolkit, label, value, tooltip);
-        }
-
-        /**
-         * Creates a FormText widget.
-         * 
-         * This expects the parent composite to have a TableWrapLayout with 2 columns.
-         * 
-         * @param parent The parent (e.g. composite from CreateTableLayout())
-         * @param toolkit Form Toolkit
-         * @param isHtml True if the form text will contain HTML that must be interpreted as
-         *               rich text (i.e. parse tags & expand URLs).
-         * @param label The string for the label.
-         * @param setupLayoutData indicates whether the created form text receives a TableWrapData
-         * through the setLayoutData method. In some case, creating it will make the table parent
-         * huge, which we don't want.
-         * @return The new created FormText.
-         */
-        public FormText createFormText(Composite parent, FormToolkit toolkit, boolean isHtml,
-                String label, boolean setupLayoutData) {
-            return SectionHelper.createFormText(parent, toolkit, isHtml, label, setupLayoutData);
-        }
-
-        /**
-         * Forces the section to recompute its layout and redraw.
-         * This is needed after the content of the section has been changed at runtime.
-         */
-        public void layoutChanged() {
-            Section section = getSection();
-
-            // Calls getSection().reflow(), which is the same that Section calls
-            // when the expandable state is changed and the height changes.
-            // Since this is protected, some reflection is needed to invoke it.
-            try {
-                Method reflow;
-                reflow = section.getClass().getDeclaredMethod("reflow", (Class<?>[])null);
-                reflow.setAccessible(true);
-                reflow.invoke(section);
-            } catch (Exception e) {
-                AdtPlugin.log(e, "Error when invoking Section.reflow");
-            }
-            
-            section.layout(true /* changed */, true /* all */);
-        }
-    }
-    
-    /**
-     * Creates a new composite with a TableWrapLayout set with a given number of columns.
-     * 
-     * If the parent composite is a Section, the new composite is set as a client.
-     * 
-     * @param composite The parent (e.g. a Section or SectionPart)
-     * @param toolkit Form Toolkit
-     * @param numColumns Desired number of columns.
-     * @return The new composite.
-     */
-    static public Composite createTableLayout(Composite composite, FormToolkit toolkit,
-            int numColumns) {
-        Composite table = toolkit.createComposite(composite);
-        TableWrapLayout layout = new TableWrapLayout();
-        layout.numColumns = numColumns;
-        table.setLayout(layout);
-        toolkit.paintBordersFor(table);
-        if (composite instanceof Section) {
-            ((Section) composite).setClient(table);
-        }
-        return table;
-    }
-
-    /**
-     * Creates a new composite with a GridLayout set with a given number of columns.
-     * 
-     * If the parent composite is a Section, the new composite is set as a client.
-     * 
-     * @param composite The parent (e.g. a Section or SectionPart)
-     * @param toolkit Form Toolkit
-     * @param numColumns Desired number of columns.
-     * @return The new composite.
-     */
-    static public Composite createGridLayout(Composite composite, FormToolkit toolkit,
-            int numColumns) {
-        Composite grid = toolkit.createComposite(composite);
-        GridLayout layout = new GridLayout();
-        layout.numColumns = numColumns;
-        grid.setLayout(layout);
-        toolkit.paintBordersFor(grid);
-        if (composite instanceof Section) {
-            ((Section) composite).setClient(grid);
-        }
-        return grid;
-    }
-
-    /**
-     * Creates two widgets: a label and a text field.
-     * 
-     * This expects the parent composite to have a TableWrapLayout with 2 columns.
-     * 
-     * @param parent The parent (e.g. composite from CreateTableLayout())
-     * @param toolkit Form Toolkit
-     * @param label_text The string for the label.
-     * @param value The initial value of the text field. Can be null.
-     * @param tooltip An optional tooltip for the label and text. Can be null.
-     * @return The new created Text field (the label is not returned) 
-     */
-    static public Text createLabelAndText(Composite parent, FormToolkit toolkit, String label_text,
-            String value, String tooltip) {
-        Label label = toolkit.createLabel(parent, label_text);
-        label.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        Text text = toolkit.createText(parent, value);
-        text.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE));
-
-        addControlTooltip(label, tooltip);
-        return text;
-    }
-
-    /**
-     * Creates a label widget.
-     * If the parent layout if a TableWrapLayout, maximize it to span over all columns.
-     * 
-     * @param parent The parent (e.g. composite from CreateTableLayout())
-     * @param toolkit Form Toolkit
-     * @param label_text The string for the label.
-     * @param tooltip An optional tooltip for the label and text. Can be null.
-     * @return The new created label 
-     */
-    static public Label createLabel(Composite parent, FormToolkit toolkit, String label_text,
-            String tooltip) {
-        Label label = toolkit.createLabel(parent, label_text);
-
-        TableWrapData twd = new TableWrapData(TableWrapData.FILL_GRAB);
-        if (parent.getLayout() instanceof TableWrapLayout) {
-            twd.colspan = ((TableWrapLayout) parent.getLayout()).numColumns;
-        }
-        label.setLayoutData(twd);
-
-        addControlTooltip(label, tooltip);
-        return label;
-    }
-
-    /**
-     * Associates a tooltip with a control.
-     * 
-     * This mirrors the behavior from org.eclipse.pde.internal.ui.editor.text.PDETextHover
-     * 
-     * @param control The control to which associate the tooltip.
-     * @param tooltip The tooltip string. Can use \n for multi-lines. Will not display if null.
-     */
-    static public void addControlTooltip(final Control control, String tooltip) {
-        if (control == null || tooltip == null || tooltip.length() == 0) {
-            return;
-        }
-        
-        // Some kinds of controls already properly implement tooltip display. 
-        if (control instanceof Button) {
-            control.setToolTipText(tooltip);
-            return;
-        }
-
-        control.setToolTipText(null);
-
-        final DefaultInformationControl ic = new DefaultInformationControl(control.getShell());
-        ic.setInformation(tooltip);
-        Point sz = ic.computeSizeHint();
-        ic.setSize(sz.x, sz.y);
-        ic.setVisible(false); // initially hidden
-        
-        control.addMouseTrackListener(new MouseTrackListener() {
-            public void mouseEnter(MouseEvent e) {
-            }
-
-            public void mouseExit(MouseEvent e) {
-                ic.setVisible(false);
-            }
-
-            public void mouseHover(MouseEvent e) {
-                ic.setLocation(control.toDisplay(10, 25));  // same offset as in PDETextHover
-                ic.setVisible(true);
-            }
-        });
-    }
-
-    /**
-     * Creates a FormText widget.
-     * 
-     * This expects the parent composite to have a TableWrapLayout with 2 columns.
-     * 
-     * @param parent The parent (e.g. composite from CreateTableLayout())
-     * @param toolkit Form Toolkit
-     * @param isHtml True if the form text will contain HTML that must be interpreted as
-     *               rich text (i.e. parse tags & expand URLs).
-     * @param label The string for the label.
-     * @param setupLayoutData indicates whether the created form text receives a TableWrapData
-     * through the setLayoutData method. In some case, creating it will make the table parent
-     * huge, which we don't want.
-     * @return The new created FormText.
-     */
-    static public FormText createFormText(Composite parent, FormToolkit toolkit,
-            boolean isHtml, String label, boolean setupLayoutData) {
-        FormText text = toolkit.createFormText(parent, true /* track focus */);
-        if (setupLayoutData) {
-            TableWrapData twd = new TableWrapData(TableWrapData.FILL_GRAB);
-            twd.maxWidth = AndroidEditor.TEXT_WIDTH_HINT;
-            if (parent.getLayout() instanceof TableWrapLayout) {
-                twd.colspan = ((TableWrapLayout) parent.getLayout()).numColumns;
-            }
-            text.setLayoutData(twd);
-        }
-        text.setWhitespaceNormalized(true);
-        text.setText(label, isHtml /* parseTags */, isHtml /* expandURLs */);
-        return text;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/TextValueCellEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/TextValueCellEditor.java
deleted file mode 100644
index 2fe5783..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/TextValueCellEditor.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-
-import org.eclipse.jface.viewers.TextCellEditor;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * TextCellEditor able to receive a {@link UiAttributeNode} in the {@link #setValue(Object)}
- * method.
- */
-public class TextValueCellEditor extends TextCellEditor {
-    
-    public TextValueCellEditor(Composite parent) {
-        super(parent);
-    }
-
-    @Override
-    protected void doSetValue(Object value) {
-        if (value instanceof UiAttributeNode) {
-            super.doSetValue(((UiAttributeNode)value).getCurrentValue());
-            return;
-        }
-        
-        super.doSetValue(value);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/UiElementPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/UiElementPart.java
deleted file mode 100644
index 66773bd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/UiElementPart.java
+++ /dev/null
@@ -1,283 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.manifest.ManifestEditor;
-import com.android.ide.eclipse.editors.ui.SectionHelper.ManifestSectionPart;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-/**
- * Generic page's section part that displays all attributes of a given {@link UiElementNode}.
- * <p/>
- * This part is designed to be displayed in a page that has a table column layout.
- * It is linked to a specific {@link UiElementNode} and automatically displays all of its
- * attributes, manages its dirty state and commits the attributes when necessary.
- * <p/>
- * No derivation is needed unless the UI or workflow needs to be extended.
- */
-public class UiElementPart extends ManifestSectionPart {
-
-    /** A reference to the container editor */
-    private ManifestEditor mEditor;
-    /** The {@link UiElementNode} manipulated by this SectionPart. It can be null. */
-    private UiElementNode mUiElementNode;
-    /** Table that contains all the attributes */
-    private Composite mTable;
-
-    public UiElementPart(Composite body, FormToolkit toolkit, ManifestEditor editor,
-            UiElementNode uiElementNode, String sectionTitle, String sectionDescription,
-            int extra_style) {
-        super(body, toolkit, extra_style, sectionDescription != null);
-        mEditor = editor;
-        mUiElementNode = uiElementNode;
-        setupSection(sectionTitle, sectionDescription);
-
-        if (uiElementNode == null) {
-            // This is serious and should never happen. Instead of crashing, simply abort.
-            // There will be no UI, which will prevent further damage.
-            AdtPlugin.log(IStatus.ERROR, "Missing node to edit!"); //$NON-NLS-1$
-            return;
-        }
-    }
-
-    /**
-     * Returns the Editor associated with this part.
-     */
-    public ManifestEditor getEditor() {
-        return mEditor;
-    }
-    
-    /**
-     * Returns the {@link UiElementNode} associated with this part.
-     */
-    public UiElementNode getUiElementNode() {
-        return mUiElementNode;
-    }
-
-    /**
-     * Changes the element node handled by this part.
-     * 
-     * @param uiElementNode The new element node for the part. 
-     */
-    public void setUiElementNode(UiElementNode uiElementNode) {
-        mUiElementNode = uiElementNode;
-    }
-    
-    /**
-     * Initializes the form part.
-     * <p/>
-     * This is called by the owning managed form as soon as the part is added to the form,
-     * which happens right after the part is actually created.
-     */
-    @Override
-    public void initialize(IManagedForm form) {
-        super.initialize(form);
-        createFormControls(form);
-    }
-
-    /**
-     * Setup the section that contains this part.
-     * <p/>
-     * This is called by the constructor to set the section's title and description
-     * with parameters given in the constructor.
-     * <br/>
-     * Derived class override this if needed, however in most cases the default
-     * implementation should be enough.
-     * 
-     * @param sectionTitle The section part's title
-     * @param sectionDescription The section part's description
-     */
-    protected void setupSection(String sectionTitle, String sectionDescription) {
-        Section section = getSection();
-        section.setText(sectionTitle);
-        section.setDescription(sectionDescription);
-    }
-
-    /**
-     * Create the controls to edit the attributes for the given ElementDescriptor.
-     * <p/>
-     * This MUST not be called by the constructor. Instead it must be called from
-     * <code>initialize</code> (i.e. right after the form part is added to the managed form.)
-     * <p/>
-     * Derived classes can override this if necessary.
-     * 
-     * @param managedForm The owner managed form
-     */
-    protected void createFormControls(IManagedForm managedForm) {
-        setTable(createTableLayout(managedForm.getToolkit(), 2 /* numColumns */));
-
-        createUiAttributes(managedForm);
-    }
-
-    /**
-     * Sets the table where the attribute UI needs to be created.
-     */
-    protected void setTable(Composite table) {
-        mTable = table;
-    }
-
-    /**
-     * Returns the table where the attribute UI needs to be created.
-     */
-    protected Composite getTable() {
-        return mTable;
-    }
-
-    /**
-     * Add all the attribute UI widgets into the underlying table layout.
-     * 
-     * @param managedForm The owner managed form
-     */
-    protected void createUiAttributes(IManagedForm managedForm) {
-        Composite table = getTable();
-        if (table == null || managedForm == null) {
-            return;
-        }
-
-        // Remove any old UI controls 
-        for (Control c : table.getChildren()) {
-            c.dispose();
-        }
-
-        fillTable(table, managedForm);
-
-        // Tell the section that the layout has changed.
-        layoutChanged();
-    }
-
-    /**
-     * Actually fills the table. 
-     * This is called by {@link #createUiAttributes(IManagedForm)} to populate the new
-     * table. The default implementation is to use
-     * {@link #insertUiAttributes(UiElementNode, Composite, IManagedForm)} to actually
-     * place the attributes of the default {@link UiElementNode} in the table.
-     * <p/>
-     * Derived classes can override this to add controls in the table before or after.
-     * 
-     * @param table The table to fill. It must have 2 columns.
-     * @param managedForm The managed form for new controls.
-     */
-    protected void fillTable(Composite table, IManagedForm managedForm) {
-        int inserted = insertUiAttributes(mUiElementNode, table, managedForm);
-        
-        if (inserted == 0) {
-            createLabel(table, managedForm.getToolkit(),
-                    "No attributes to display, waiting for SDK to finish loading...",
-                    null /* tooltip */ );
-        }
-    }
-
-    /**
-     * Insert the UI attributes of the given {@link UiElementNode} in the given table.
-     * 
-     * @param uiNode The {@link UiElementNode} that contains the attributes to display.
-     *               Must not be null.
-     * @param table The table to fill. It must have 2 columns.
-     * @param managedForm The managed form for new controls.
-     * @return The number of UI attributes inserted. It is >= 0.
-     */
-    protected int insertUiAttributes(UiElementNode uiNode, Composite table, IManagedForm managedForm) {
-        if (uiNode == null || table == null || managedForm == null) {
-            return 0;
-        }
-
-        // To iterate over all attributes, we use the {@link ElementDescriptor} instead
-        // of the {@link UiElementNode} because the attributes' order is guaranteed in the
-        // descriptor but not in the node itself.
-        AttributeDescriptor[] attr_desc_list = uiNode.getAttributeDescriptors();
-        for (AttributeDescriptor attr_desc : attr_desc_list) {
-            if (attr_desc instanceof XmlnsAttributeDescriptor) {
-                // Do not show hidden attributes
-                continue;
-            }
-
-            UiAttributeNode ui_attr = uiNode.findUiAttribute(attr_desc);
-            if (ui_attr != null) {
-                ui_attr.createUiControl(table, managedForm);
-            } else {
-                // The XML has an extra attribute which wasn't declared in
-                // AndroidManifestDescriptors. This is not a problem, we just ignore it.
-                AdtPlugin.log(IStatus.WARNING,
-                        "Attribute %1$s not declared in node %2$s, ignored.", //$NON-NLS-1$
-                        attr_desc.getXmlLocalName(),
-                        uiNode.getDescriptor().getXmlName());
-            }
-        }
-        return attr_desc_list.length;
-    }
-
-    /**
-     * Tests whether the part is dirty i.e. its widgets have state that is
-     * newer than the data in the model.
-     * <p/>
-     * This is done by iterating over all attributes and updating the super's
-     * internal dirty flag. Stop once at least one attribute is dirty.
-     * 
-     * @return <code>true</code> if the part is dirty, <code>false</code>
-     *         otherwise.
-     */
-    @Override
-    public boolean isDirty() {
-        if (mUiElementNode != null && !super.isDirty()) {
-            for (UiAttributeNode ui_attr : mUiElementNode.getUiAttributes()) {
-                if (ui_attr.isDirty()) {
-                    markDirty();
-                    break;
-                }
-            }
-        }
-        return super.isDirty();
-    }
-    
-    /**
-     * If part is displaying information loaded from a model, this method
-     * instructs it to commit the new (modified) data back into the model.
-     * 
-     * @param onSave
-     *            indicates if commit is called during 'save' operation or for
-     *            some other reason (for example, if form is contained in a
-     *            wizard or a multi-page editor and the user is about to leave
-     *            the page).
-     */
-    @Override
-    public void commit(boolean onSave) {
-        if (mUiElementNode != null) {
-            mEditor.editXmlModel(new Runnable() {
-                public void run() {
-                    for (UiAttributeNode ui_attr : mUiElementNode.getUiAttributes()) {
-                        ui_attr.commit();
-                    }
-                }
-            });
-        }
-
-        // We need to call super's commit after we synchronized the nodes to make sure we
-        // reset the dirty flag after all the side effects from committing have occurred.
-        super.commit(onSave);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/CopyCutAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/CopyCutAction.java
deleted file mode 100644
index 2aad217..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/CopyCutAction.java
+++ /dev/null
@@ -1,220 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.apache.xml.serialize.Method;
-import org.apache.xml.serialize.OutputFormat;
-import org.apache.xml.serialize.XMLSerializer;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.dnd.TextTransfer;
-import org.eclipse.swt.dnd.Transfer;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.IndexedRegion;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.xml.core.internal.document.NodeContainer;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-import java.io.IOException;
-import java.io.StringWriter;
-import java.util.ArrayList;
-import java.util.List;
-
-
-/**
- * Provides Cut and Copy actions for the tree nodes.
- */
-public class CopyCutAction extends Action {
-    private List<UiElementNode> mUiNodes;
-    private boolean mPerformCut;
-    private final AndroidEditor mEditor;
-    private final Clipboard mClipboard;
-    private final ICommitXml mXmlCommit;
-
-    /**
-     * Creates a new Copy or Cut action.
-     * 
-     * @param selected The UI node to cut or copy. It *must* have a non-null XML node.
-     * @param perform_cut True if the operation is cut, false if it is copy.
-     */
-    public CopyCutAction(AndroidEditor editor, Clipboard clipboard, ICommitXml xmlCommit,
-            UiElementNode selected, boolean perform_cut) {
-        this(editor, clipboard, xmlCommit, toList(selected), perform_cut);
-    }
-
-    /**
-     * Creates a new Copy or Cut action.
-     * 
-     * @param selected The UI nodes to cut or copy. They *must* have a non-null XML node.
-     *                 The list becomes owned by the {@link CopyCutAction}.
-     * @param perform_cut True if the operation is cut, false if it is copy.
-     */
-    public CopyCutAction(AndroidEditor editor, Clipboard clipboard, ICommitXml xmlCommit,
-            List<UiElementNode> selected, boolean perform_cut) {
-        super(perform_cut ? "Cut" : "Copy");
-        mEditor = editor;
-        mClipboard = clipboard;
-        mXmlCommit = xmlCommit;
-        
-        ISharedImages images = PlatformUI.getWorkbench().getSharedImages();
-        if (perform_cut) {
-            setImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_CUT));
-            setHoverImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_CUT));
-            setDisabledImageDescriptor(
-                    images.getImageDescriptor(ISharedImages.IMG_TOOL_CUT_DISABLED));
-        } else {
-            setImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_COPY));
-            setHoverImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_COPY));
-            setDisabledImageDescriptor(
-                    images.getImageDescriptor(ISharedImages.IMG_TOOL_COPY_DISABLED));
-        }
-
-        mUiNodes = selected;
-        mPerformCut = perform_cut;
-    }
-
-    /**
-     * Performs the cut or copy action.
-     * First an XML serializer is used to turn the existing XML node into a valid
-     * XML fragment, which is added as text to the clipboard.
-     */
-    @Override
-    public void run() {
-        super.run();
-        if (mUiNodes == null || mUiNodes.size() < 1) {
-            return;
-        }
-
-        // Commit the current pages first, to make sure the XML is in sync.
-        // Committing may change the XML structure.
-        if (mXmlCommit != null) {
-            mXmlCommit.commitPendingXmlChanges();
-        }
-
-        StringBuilder allText = new StringBuilder();
-        ArrayList<UiElementNode> nodesToCut = mPerformCut ? new ArrayList<UiElementNode>() : null;
-
-        for (UiElementNode uiNode : mUiNodes) {
-            try {            
-                Node xml_node = uiNode.getXmlNode();
-                if (xml_node == null) {
-                    return;
-                }
-                
-                String data = getXmlTextFromEditor(xml_node);
- 
-                // In the unlikely event that IStructuredDocument failed to extract the text
-                // directly from the editor, try to fall back on a direct XML serialization
-                // of the XML node. This uses the generic Node interface with no SSE tricks.
-                if (data == null) {
-                    data = getXmlTextFromSerialization(xml_node);
-                }
-                
-                if (data != null) {
-                    allText.append(data);
-                    if (mPerformCut) {
-                        // only remove notes to cut if we actually got some XML text from them
-                        nodesToCut.add(uiNode);
-                    }
-                }
-    
-            } catch (Exception e) {
-                AdtPlugin.log(e, "CopyCutAction failed for UI node %1$s", //$NON-NLS-1$
-                        uiNode.getBreadcrumbTrailDescription(true));
-            }
-        } // for uiNode
-
-        if (allText != null && allText.length() > 0) {
-            mClipboard.setContents(
-                    new Object[] { allText.toString() },
-                    new Transfer[] { TextTransfer.getInstance() });
-            if (mPerformCut) {
-                for (UiElementNode uiNode : nodesToCut) {
-                    uiNode.deleteXmlNode();
-                }
-            }
-        }
-    }
-
-    /** Get the data directly from the editor. */
-    private String getXmlTextFromEditor(Node xml_node) {
-        String data = null;
-        IStructuredModel model = mEditor.getModelForRead();
-        try {
-            IStructuredDocument sse_doc = mEditor.getStructuredDocument();
-            if (xml_node instanceof NodeContainer) {
-                // The easy way to get the source of an SSE XML node.
-                data = ((NodeContainer) xml_node).getSource();
-            } else  if (xml_node instanceof IndexedRegion && sse_doc != null) {
-                // Try harder.
-                IndexedRegion region = (IndexedRegion) xml_node;
-                int start = region.getStartOffset();
-                int end = region.getEndOffset();
-   
-                if (end > start) {
-                    data = sse_doc.get(start, end - start);
-                }
-            }
-        } catch (BadLocationException e) {
-            // the region offset was invalid. ignore.
-        } finally {
-            model.releaseFromRead();
-        }
-        return data;
-    }
-    
-    /**
-     * Direct XML serialization of the XML node.
-     * <p/>
-     * This uses the generic Node interface with no SSE tricks. It's however slower
-     * and doesn't respect formatting (since serialization is involved instead of reading
-     * the actual text buffer.)
-     */
-    private String getXmlTextFromSerialization(Node xml_node) throws IOException {
-        String data;
-        StringWriter sw = new StringWriter();
-        XMLSerializer serializer = new XMLSerializer(sw,
-                new OutputFormat(Method.XML,
-                        OutputFormat.Defaults.Encoding /* utf-8 */,
-                        true /* indent */));
-        // Serialize will throw an IOException if it fails.
-        serializer.serialize((Element) xml_node);
-        data = sw.toString();
-        return data;
-    }
-
-    /**
-     * Static helper class to wrap on node into a list for the constructors.
-     */
-    private static ArrayList<UiElementNode> toList(UiElementNode selected) {
-        ArrayList<UiElementNode> list = null;
-        if (selected != null) {
-            list = new ArrayList<UiElementNode>(1);
-            list.add(selected);
-        }
-        return list;
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/ICommitXml.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/ICommitXml.java
deleted file mode 100644
index 8b6aa0e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/ICommitXml.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-/**
- * Interface for an object that can commit its changes to the underlying XML model
- */
-public interface ICommitXml {
-
-    /** Commits pending data to the underlying XML model. */
-    public void commitPendingXmlChanges();
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/NewItemSelectionDialog.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/NewItemSelectionDialog.java
deleted file mode 100644
index 0729881..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/NewItemSelectionDialog.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.layout.descriptors.ViewElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.AbstractElementListSelectionDialog;
-import org.eclipse.ui.dialogs.ISelectionStatusValidator;
-
-import java.util.Arrays;
-
-/**
- * A selection dialog to select the type of the new element node to
- * created, either in the application node or the selected sub node.
- */
-public class NewItemSelectionDialog extends AbstractElementListSelectionDialog {
-
-    /** The UI node selected in the tree view before creating the new item selection dialog.
-     *  Can be null -- which means new items must be created in the root_node. */
-    private UiElementNode mSelectedUiNode;
-    /** The root node chosen by the user, either root_node or the one passed
-     *  to the constructor if not null */
-    private UiElementNode mChosenRootNode;
-    private UiElementNode mLocalRootNode;
-    /** The descriptor of the elements to be displayed as root in this tree view. All elements
-     *  of the same type in the root will be displayed. */
-    private ElementDescriptor[] mDescriptorFilters;
-
-    /**
-     * Creates the new item selection dialog.
-     * 
-     * @param shell The parent shell for the list.
-     * @param labelProvider ILabelProvider for the list.
-     * @param descriptorFilters The element allows at the root of the tree
-     * @param ui_node The selected node, or null if none is selected.
-     * @param root_node The root of the Ui Tree, either the UiDocumentNode or a sub-node.
-     */
-    public NewItemSelectionDialog(Shell shell, ILabelProvider labelProvider,
-            ElementDescriptor[] descriptorFilters,
-            UiElementNode ui_node,
-            UiElementNode root_node) {
-        super(shell, labelProvider);
-        mDescriptorFilters = descriptorFilters;
-        mLocalRootNode = root_node;
-
-        // Only accept the UI node if it is not the UI root node and it can have children.
-        // If the node cannot have children, select its parent as a potential target.
-        if (ui_node != null && ui_node != mLocalRootNode) {
-            if (ui_node.getDescriptor().hasChildren()) {
-                mSelectedUiNode = ui_node;
-            } else {
-                UiElementNode parent = ui_node.getUiParent();
-                if (parent != null && parent != mLocalRootNode) {
-                    mSelectedUiNode = parent;
-                }
-            }
-        }
-        
-        setHelpAvailable(false);
-        setMultipleSelection(false);
-        
-        setValidator(new ISelectionStatusValidator() {
-            public IStatus validate(Object[] selection) {
-                if (selection.length == 1 && selection[0] instanceof ViewElementDescriptor) {
-                    return new Status(IStatus.OK, // severity
-                            AdtPlugin.PLUGIN_ID, //plugin id
-                            IStatus.OK, // code
-                            ((ViewElementDescriptor) selection[0]).getCanonicalClassName(), //msg 
-                            null); // exception
-                } else if (selection.length == 1 && selection[0] instanceof ElementDescriptor) {
-                    return new Status(IStatus.OK, // severity
-                            AdtPlugin.PLUGIN_ID, //plugin id
-                            IStatus.OK, // code
-                            "", //$NON-NLS-1$ // msg
-                            null); // exception
-                } else {
-                    return new Status(IStatus.ERROR, // severity
-                            AdtPlugin.PLUGIN_ID, //plugin id
-                            IStatus.ERROR, // code
-                            "Invalid selection", // msg, translatable 
-                            null); // exception
-                }
-            }
-        });
-    }
-
-    /**
-     * @return The root node selected by the user, either root node or the
-     *         one passed to the constructor if not null.
-     */
-    public UiElementNode getChosenRootNode() {
-        return mChosenRootNode;
-    }
-
-    /**
-     * Internal helper to compute the result. Returns the selection from
-     * the list view, if any.
-     */
-    @Override
-    protected void computeResult() {
-        setResult(Arrays.asList(getSelectedElements()));
-    }
-
-    /**
-     * Creates the dialog area.
-     * 
-     * First add a radio area, which may be either 2 radio controls or
-     * just a message area if there's only one choice (the app root node).
-     * 
-     * Then uses the default from the AbstractElementListSelectionDialog
-     * which is to add both a filter text and a filtered list. Adding both
-     * is necessary (since the base class accesses both internal directly
-     * fields without checking for null pointers.) 
-     * 
-     * Finally sets the initial selection list.
-     */
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite contents = (Composite) super.createDialogArea(parent);
-
-        createRadioControl(contents);
-        createFilterText(contents);
-        createFilteredList(contents);
-
-        // Initialize the list state.
-        // This must be done after the filtered list as been created.
-        chooseNode(mChosenRootNode);
-        setSelection(getInitialElementSelections().toArray());
-        return contents;
-    }
-    
-    /**
-     * Creates the message text widget and sets layout data.
-     * @param content the parent composite of the message area.
-     */
-    private Composite createRadioControl(Composite content) {
-        
-        if (mSelectedUiNode != null) {
-            Button radio1 = new Button(content, SWT.RADIO);
-            radio1.setText(String.format("Create a new element at the top level, in %1$s.",
-                    mLocalRootNode.getShortDescription()));
-
-            Button radio2 = new Button(content, SWT.RADIO);
-            radio2.setText(String.format("Create a new element in the selected element, %1$s.",
-                    mSelectedUiNode.getBreadcrumbTrailDescription(false /* include_root */)));
-
-            // Set the initial selection before adding the listeners
-            // (they can't be run till the filtered list has been created)
-            radio1.setSelection(false);
-            radio2.setSelection(true);
-            mChosenRootNode = mSelectedUiNode;
-            
-            radio1.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    super.widgetSelected(e);
-                    chooseNode(mLocalRootNode);
-                }
-            });
-            
-            radio2.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    super.widgetSelected(e);
-                    chooseNode(mSelectedUiNode);
-                }
-            });
-        } else {
-            setMessage(String.format("Create a new element at the top level, in %1$s.",
-                    mLocalRootNode.getShortDescription()));
-            createMessageArea(content);
-
-            mChosenRootNode = mLocalRootNode;
-        }
-         
-        return content;
-    }
-
-    /**
-     * Internal helper to remember the root node choosen by the user.
-     * It also sets the list view to the adequate list of children that can
-     * be added to the chosen root node.
-     * 
-     * If the chosen root node is mLocalRootNode and a descriptor filter was specified
-     * when creating the master-detail part, we use this as the set of nodes that
-     * can be created on the root node.
-     * 
-     * @param ui_node The chosen root node, either mLocalRootNode or
-     *                mSelectedUiNode.
-     */
-    private void chooseNode(UiElementNode ui_node) {
-        mChosenRootNode = ui_node;
-
-        if (ui_node == mLocalRootNode && 
-                mDescriptorFilters != null &&
-                mDescriptorFilters.length != 0) {
-            setListElements(mDescriptorFilters);
-        } else {
-            setListElements(ui_node.getDescriptor().getChildren());
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/PasteAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/PasteAction.java
deleted file mode 100644
index 8bb4ad2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/PasteAction.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.dnd.TextTransfer;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.IndexedRegion;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocumentRegion;
-import org.eclipse.wst.xml.core.internal.document.NodeContainer;
-import org.w3c.dom.Node;
-
-
-/**
- * Provides Paste operation for the tree nodes
- */
-public class PasteAction extends Action {
-    private UiElementNode mUiNode;
-    private final AndroidEditor mEditor;
-    private final Clipboard mClipboard;
-
-    public PasteAction(AndroidEditor editor, Clipboard clipboard, UiElementNode ui_node) {
-        super("Paste");
-        mEditor = editor;
-        mClipboard = clipboard;
-
-        ISharedImages images = PlatformUI.getWorkbench().getSharedImages();
-        setImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_PASTE));
-        setHoverImageDescriptor(images.getImageDescriptor(ISharedImages.IMG_TOOL_PASTE));
-        setDisabledImageDescriptor(
-                images.getImageDescriptor(ISharedImages.IMG_TOOL_PASTE_DISABLED));
-
-        mUiNode = ui_node;
-    }
-
-    /**
-     * Performs the paste operation.
-     */
-    @Override
-    public void run() {
-        super.run();
-        
-        final String data = (String) mClipboard.getContents(TextTransfer.getInstance());
-        if (data != null) {
-            IStructuredModel model = mEditor.getModelForEdit();
-            try {
-                IStructuredDocument sse_doc = mEditor.getStructuredDocument();
-                if (sse_doc != null) {
-                    if (mUiNode.getDescriptor().hasChildren()) {
-                        // This UI Node can have children. The new XML is
-                        // inserted as the first child.
-                        
-                        if (mUiNode.getUiChildren().size() > 0) {
-                            // There's already at least one child, so insert right before it.
-                            Node xml_node = mUiNode.getUiChildren().get(0).getXmlNode();
-                            if (xml_node instanceof IndexedRegion) { // implies xml_node != null
-                                IndexedRegion region = (IndexedRegion) xml_node;
-                                sse_doc.replace(region.getStartOffset(), 0, data);
-                                return; // we're done, no need to try the other cases
-                            }                                
-                        }
-                        
-                        // If there's no first XML node child. Create one by
-                        // inserting at the end of the *start* tag.
-                        Node xml_node = mUiNode.getXmlNode();
-                        if (xml_node instanceof NodeContainer) {
-                            NodeContainer container = (NodeContainer) xml_node;
-                            IStructuredDocumentRegion start_tag =
-                                container.getStartStructuredDocumentRegion();
-                            if (start_tag != null) {
-                                sse_doc.replace(start_tag.getEndOffset(), 0, data);
-                                return; // we're done, no need to try the other case
-                            }
-                        }
-                    }
-                    
-                    // This UI Node doesn't accept children. The new XML is inserted as the
-                    // next sibling. This also serves as a fallback if all the previous
-                    // attempts failed. However, this is not possible if the current node
-                    // has for parent a document -- an XML document can only have one root,
-                    // with no siblings.
-                    if (!(mUiNode.getUiParent() instanceof UiDocumentNode)) {
-                        Node xml_node = mUiNode.getXmlNode();
-                        if (xml_node instanceof IndexedRegion) {
-                            IndexedRegion region = (IndexedRegion) xml_node;
-                            sse_doc.replace(region.getEndOffset(), 0, data);
-                        }
-                    }
-                }
-
-            } catch (BadLocationException e) {
-                AdtPlugin.log(e, "ParseAction failed for UI Node %2$s, content '%1$s'", //$NON-NLS-1$
-                        mUiNode.getBreadcrumbTrailDescription(true), data);
-            } finally {
-                model.releaseFromEdit();
-            }
-        }
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiActions.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiActions.java
deleted file mode 100644
index 21180b1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiActions.java
+++ /dev/null
@@ -1,385 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.swt.widgets.Shell;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-import java.util.List;
-
-/**
- * Performs basic actions on an XML tree: add node, remove node, move up/down.
- */
-public abstract class UiActions implements ICommitXml {
-
-    public UiActions() {
-    }
-
-    //---------------------
-    // Actual implementations must override these to provide specific hooks
-
-    /** Returns the UiDocumentNode for the current model. */
-    abstract protected UiElementNode getRootNode();
-
-    /** Commits pending data before the XML model is modified. */
-    abstract public void commitPendingXmlChanges();
-
-    /**
-     * Utility method to select an outline item based on its model node
-     * 
-     * @param uiNode The node to select. Can be null (in which case nothing should happen)
-     */
-    abstract protected void selectUiNode(UiElementNode uiNode);
-
-    //---------------------
-
-    /**
-     * Called when the "Add..." button next to the tree view is selected.
-     * <p/>
-     * This simplified version of doAdd does not support descriptor filters and creates
-     * a new {@link UiModelTreeLabelProvider} for each call.
-     */
-    public void doAdd(UiElementNode uiNode, Shell shell) {
-        doAdd(uiNode, null /* descriptorFilters */, shell, new UiModelTreeLabelProvider());
-    }
-    
-    /**
-     * Called when the "Add..." button next to the tree view is selected.
-     * 
-     * Displays a selection dialog that lets the user select which kind of node
-     * to create, depending on the current selection.
-     */
-    public void doAdd(UiElementNode uiNode,
-            ElementDescriptor[] descriptorFilters,
-            Shell shell, ILabelProvider labelProvider) {
-        // If the root node is a document with already a root, use it as the root node
-        UiElementNode rootNode = getRootNode();
-        if (rootNode instanceof UiDocumentNode && rootNode.getUiChildren().size() > 0) {
-            rootNode = rootNode.getUiChildren().get(0);
-        }
-
-        NewItemSelectionDialog dlg = new NewItemSelectionDialog(
-                shell,
-                labelProvider,
-                descriptorFilters,
-                uiNode, rootNode);
-        dlg.open();
-        Object[] results = dlg.getResult();
-        if (results != null && results.length > 0) {
-            addElement(dlg.getChosenRootNode(), null, (ElementDescriptor) results[0],
-                    true /*updateLayout*/);
-        }
-    }
-
-    /**
-     * Adds a new XML element based on the {@link ElementDescriptor} to the given parent
-     * {@link UiElementNode}, and then select it.
-     * <p/>
-     * If the parent is a document root which already contains a root element, the inner
-     * root element is used as the actual parent. This ensure you can't create a broken
-     * XML file with more than one root element.
-     * <p/>
-     * If a sibling is given and that sibling has the same parent, the new node is added
-     * right after that sibling. Otherwise the new node is added at the end of the parent
-     * child list.
-     * 
-     * @param uiParent An existing UI node or null to add to the tree root
-     * @param uiSibling An existing UI node before which to insert the new node. Can be null.
-     * @param descriptor The descriptor of the element to add
-     * @param updateLayout True if layout attributes should be set
-     * @return The new {@link UiElementNode} or null.
-     */
-    public UiElementNode addElement(UiElementNode uiParent,
-            UiElementNode uiSibling,
-            ElementDescriptor descriptor,
-            boolean updateLayout) {
-        if (uiParent instanceof UiDocumentNode && uiParent.getUiChildren().size() > 0) {
-            uiParent = uiParent.getUiChildren().get(0);
-        }
-        if (uiSibling != null && uiSibling.getUiParent() != uiParent) {
-            uiSibling = null;
-        }
-
-        UiElementNode uiNew = addNewTreeElement(uiParent, uiSibling, descriptor, updateLayout);
-        selectUiNode(uiNew);
-        
-        return uiNew;
-    }
-
-    /**
-     * Called when the "Remove" button is selected.
-     * 
-     * If the tree has a selection, remove it.
-     * This simply deletes the XML node attached to the UI node: when the XML model fires the
-     * update event, the tree will get refreshed.
-     */
-    public void doRemove(final List<UiElementNode> nodes, Shell shell) {
-        
-        if (nodes == null || nodes.size() == 0) {
-            return;
-        }
-        
-        final int len = nodes.size();
-        
-        StringBuilder sb = new StringBuilder();
-        for (UiElementNode node : nodes) {
-            sb.append("\n- "); //$NON-NLS-1$
-            sb.append(node.getBreadcrumbTrailDescription(false /* include_root */));
-        }
-        
-        if (MessageDialog.openQuestion(shell,
-                len > 1 ? "Remove elements from Android XML"  // title
-                        : "Remove element from Android XML",
-                String.format("Do you really want to remove %1$s?", sb.toString()))) {
-            commitPendingXmlChanges();
-            getRootNode().getEditor().editXmlModel(new Runnable() {
-                public void run() {
-                    UiElementNode previous = null;
-                    UiElementNode parent = null;
-
-                    for (int i = len - 1; i >= 0; i--) {
-                        UiElementNode node = nodes.get(i);
-                        previous = node.getUiPreviousSibling();
-                        parent = node.getUiParent();
-                        
-                        // delete node
-                        node.deleteXmlNode();
-                    }
-                    
-                    // try to select the last previous sibling or the last parent
-                    if (previous != null) {
-                        selectUiNode(previous);
-                    } else if (parent != null) {
-                        selectUiNode(parent);
-                    }
-                }
-            });
-        }
-    }
-
-    /**
-     * Called when the "Up" button is selected.
-     * <p/>
-     * If the tree has a selection, move it up, either in the child list or as the last child
-     * of the previous parent.
-     */
-    public void doUp(final List<UiElementNode> nodes) {
-        if (nodes == null || nodes.size() < 1) {
-            return;
-        }
-        
-        final Node[] select_xml_node = { null };
-        UiElementNode last_node = null;
-        UiElementNode search_root = null;
-        
-        for (int i = 0; i < nodes.size(); i++) {
-            final UiElementNode node = last_node = nodes.get(i);
-            
-            // the node will move either up to its parent or grand-parent
-            search_root = node.getUiParent();
-            if (search_root != null && search_root.getUiParent() != null) {
-                search_root = search_root.getUiParent();
-            }
-    
-            commitPendingXmlChanges();
-            getRootNode().getEditor().editXmlModel(new Runnable() {
-                public void run() {
-                    Node xml_node = node.getXmlNode();
-                    if (xml_node != null) {
-                        Node xml_parent = xml_node.getParentNode();
-                        if (xml_parent != null) {
-                            UiElementNode ui_prev = node.getUiPreviousSibling();
-                            if (ui_prev != null && ui_prev.getXmlNode() != null) {
-                                // This node is not the first one of the parent, so it can be
-                                // removed and then inserted before its previous sibling.
-                                // If the previous sibling can have children, though, then it
-                                // is inserted at the end of the children list.
-                                Node xml_prev = ui_prev.getXmlNode();
-                                if (ui_prev.getDescriptor().hasChildren()) {
-                                    xml_prev.appendChild(xml_parent.removeChild(xml_node));
-                                    select_xml_node[0] = xml_node;
-                                } else {
-                                    xml_parent.insertBefore(
-                                            xml_parent.removeChild(xml_node),
-                                            xml_prev);
-                                    select_xml_node[0] = xml_node;
-                                }
-                            } else if (!(xml_parent instanceof Document) &&
-                                    xml_parent.getParentNode() != null &&
-                                    !(xml_parent.getParentNode() instanceof Document)) {
-                                // If the node is the first one of the child list of its
-                                // parent, move it up in the hierarchy as previous sibling
-                                // to the parent. This is only possible if the parent of the
-                                // parent is not a document.
-                                Node grand_parent = xml_parent.getParentNode();
-                                grand_parent.insertBefore(xml_parent.removeChild(xml_node),
-                                        xml_parent);
-                                select_xml_node[0] = xml_node;
-                            }
-                        }
-                    }
-                }
-            });
-        }
-
-        if (select_xml_node[0] == null) {
-            // The XML node has not been moved, we can just select the same UI node
-            selectUiNode(last_node);
-        } else {
-            // The XML node has moved. At this point the UI model has been reloaded
-            // and the XML node has been affected to a new UI node. Find that new UI
-            // node and select it.
-            if (search_root == null) {
-                search_root = last_node.getUiRoot();
-            }
-            if (search_root != null) {
-                selectUiNode(search_root.findXmlNode(select_xml_node[0]));
-            }
-        }
-    }
-
-    /**
-     * Called when the "Down" button is selected.
-     * 
-     * If the tree has a selection, move it down, either in the same child list or as the
-     * first child of the next parent.
-     */
-    public void doDown(final List<UiElementNode> nodes) {
-        if (nodes == null || nodes.size() < 1) {
-            return;
-        }
-        
-        final Node[] select_xml_node = { null };
-        UiElementNode last_node = null;
-        UiElementNode search_root = null;
-
-        for (int i = nodes.size() - 1; i >= 0; i--) {
-            final UiElementNode node = last_node = nodes.get(i);
-            // the node will move either down to its parent or grand-parent
-            search_root = node.getUiParent();
-            if (search_root != null && search_root.getUiParent() != null) {
-                search_root = search_root.getUiParent();
-            }
-    
-            commitPendingXmlChanges();
-            getRootNode().getEditor().editXmlModel(new Runnable() {
-                public void run() {
-                    Node xml_node = node.getXmlNode();
-                    if (xml_node != null) {
-                        Node xml_parent = xml_node.getParentNode();
-                        if (xml_parent != null) {
-                            UiElementNode uiNext = node.getUiNextSibling();
-                            if (uiNext != null && uiNext.getXmlNode() != null) {
-                                // This node is not the last one of the parent, so it can be
-                                // removed and then inserted after its next sibling.
-                                // If the next sibling is a node that can have children, though,
-                                // then the node is inserted as the first child.
-                                Node xml_next = uiNext.getXmlNode();
-                                if (uiNext.getDescriptor().hasChildren()) {
-                                    // Note: insertBefore works as append if the ref node is
-                                    // null, i.e. when the node doesn't have children yet.
-                                    xml_next.insertBefore(xml_parent.removeChild(xml_node),
-                                            xml_next.getFirstChild());
-                                    select_xml_node[0] = xml_node;
-                                } else {
-                                    // Insert "before after next" ;-)
-                                    xml_parent.insertBefore(xml_parent.removeChild(xml_node),
-                                            xml_next.getNextSibling());
-                                    select_xml_node[0] = xml_node;
-                                }
-                            } else if (!(xml_parent instanceof Document) &&
-                                    xml_parent.getParentNode() != null &&
-                                    !(xml_parent.getParentNode() instanceof Document)) {
-                                // This node is the last node of its parent.
-                                // If neither the parent nor the grandparent is a document,
-                                // then the node can be insert right after the parent.
-                                Node grand_parent = xml_parent.getParentNode();
-                                grand_parent.insertBefore(xml_parent.removeChild(xml_node),
-                                        xml_parent.getNextSibling());
-                                select_xml_node[0] = xml_node;
-                            }
-                        }
-                    }
-                }
-            });
-        }
-
-        if (select_xml_node[0] == null) {
-            // The XML node has not been moved, we can just select the same UI node
-            selectUiNode(last_node);
-        } else {
-            // The XML node has moved. At this point the UI model has been reloaded
-            // and the XML node has been affected to a new UI node. Find that new UI
-            // node and select it.
-            if (search_root == null) {
-                search_root = last_node.getUiRoot();
-            }
-            if (search_root != null) {
-                selectUiNode(search_root.findXmlNode(select_xml_node[0]));
-            }
-        }
-    }
-
-    //---------------------
-    
-    /**
-     * Adds a new element of the given descriptor's type to the given UI parent node.
-     * 
-     * This actually creates the corresponding XML node in the XML model, which in turn
-     * will refresh the current tree view.
-     *  
-     * @param uiParent An existing UI node or null to add to the tree root
-     * @param uiSibling An existing UI node to insert right before. Can be null. 
-     * @param descriptor The descriptor of the element to add
-     * @param updateLayout True if layout attributes should be set
-     * @return The {@link UiElementNode} that has been added to the UI tree.
-     */
-    private UiElementNode addNewTreeElement(UiElementNode uiParent,
-            final UiElementNode uiSibling,
-            ElementDescriptor descriptor,
-            final boolean updateLayout) {
-        commitPendingXmlChanges();
-        
-        int index = 0;
-        for (UiElementNode uiChild : uiParent.getUiChildren()) {
-            if (uiChild == uiSibling) {
-                break;
-            }
-            index++;
-        }
-        
-        final UiElementNode uiNew = uiParent.insertNewUiChild(index, descriptor);
-        UiElementNode rootNode = getRootNode();
-
-        rootNode.getEditor().editXmlModel(new Runnable() {
-            public void run() {
-                DescriptorsUtils.setDefaultLayoutAttributes(uiNew, updateLayout);
-                Node xmlNode = uiNew.createXmlNode();
-            }
-        });
-        return uiNew;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiElementDetail.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiElementDetail.java
deleted file mode 100644
index 15c67c3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiElementDetail.java
+++ /dev/null
@@ -1,486 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.ide.eclipse.editors.ui.SectionHelper.ManifestSectionPart;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener;
-import com.android.ide.eclipse.editors.uimodel.UiAttributeNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ITreeSelection;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IFormPart;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.events.ExpansionEvent;
-import org.eclipse.ui.forms.events.IExpansionListener;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.forms.widgets.SharedScrolledComposite;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-
-import java.util.Collection;
-import java.util.HashSet;
-
-/**
- * Details page for the {@link UiElementNode} nodes in the tree view.
- * <p/>
- * See IDetailsBase for more details.
- */
-class UiElementDetail implements IDetailsPage {
-
-    /** The master-detail part, composed of a main tree and an auxiliary detail part */
-    private ManifestSectionPart mMasterPart;
-
-    private Section mMasterSection;
-    private UiElementNode mCurrentUiElementNode;
-    private Composite mCurrentTable;
-    private boolean mIsDirty;
-
-    private IManagedForm mManagedForm;
-
-    private final UiTreeBlock mTree;
-    
-    public UiElementDetail(UiTreeBlock tree) {
-        mTree = tree;
-        mMasterPart = mTree.getMasterPart();
-        mManagedForm = mMasterPart.getManagedForm();
-    }
-    
-    /* (non-java doc)
-     * Initializes the part.
-     */
-    public void initialize(IManagedForm form) {
-        mManagedForm = form;
-    }
-
-    /* (non-java doc)
-     * Creates the contents of the page in the provided parent.
-     */
-    public void createContents(Composite parent) {
-        mMasterSection = createMasterSection(parent);
-    }
-
-    /* (non-java doc)
-     * Called when the provided part has changed selection state.
-     * <p/>
-     * Only reply when our master part originates the selection.
-     */
-    public void selectionChanged(IFormPart part, ISelection selection) {
-        if (part == mMasterPart &&
-                !selection.isEmpty() &&
-                selection instanceof ITreeSelection) {
-            ITreeSelection tree_selection = (ITreeSelection) selection;
-
-            Object first = tree_selection.getFirstElement();
-            if (first instanceof UiElementNode) {
-                UiElementNode ui_node = (UiElementNode) first;
-                createUiAttributeControls(mManagedForm, ui_node);
-            }
-        }
-    }
-
-    /* (non-java doc)
-     * Instructs it to commit the new (modified) data back into the model.
-     */
-    public void commit(boolean onSave) {
-        
-        IStructuredModel model = mTree.getEditor().getModelForEdit();
-        try {
-            // Notify the model we're about to change data...
-            model.aboutToChangeModel();
-
-            if (mCurrentUiElementNode != null) {
-                mCurrentUiElementNode.commit();
-            }
-            
-            // Finally reset the dirty flag if everything was saved properly
-            mIsDirty = false;
-        } catch (Exception e) {
-            AdtPlugin.log(e, "Detail node failed to commit XML attribute!"); //$NON-NLS-1$
-        } finally {
-            // Notify the model we're done modifying it. This must *always* be executed.
-            model.changedModel();
-            model.releaseFromEdit();
-        }
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-
-    /* (non-java doc)
-     * Returns true if the part has been modified with respect to the data
-     * loaded from the model.
-     */
-    public boolean isDirty() {
-        if (mCurrentUiElementNode != null && mCurrentUiElementNode.isDirty()) {
-            markDirty();
-        }
-        return mIsDirty;
-    }
-
-    public boolean isStale() {
-        // pass
-        return false;
-    }
-
-    /**
-     * Called by the master part when the tree is refreshed after the framework resources
-     * have been reloaded.
-     */
-    public void refresh() {
-        if (mCurrentTable != null) {
-            mCurrentTable.dispose();
-            mCurrentTable = null;
-        }
-        mCurrentUiElementNode = null;
-        mMasterSection.getParent().pack(true /* changed */);
-    }
-
-    public void setFocus() {
-        // pass
-    }
-
-    public boolean setFormInput(Object input) {
-        // pass
-        return false;
-    }
-
-    /**
-     * Creates a TableWrapLayout in the DetailsPage, which in turns contains a Section.
-     * 
-     * All the UI should be created in a layout which parent is the mSection itself.
-     * The hierarchy is:
-     * <pre>
-     * DetailPage
-     * + TableWrapLayout
-     *   + Section (with title/description && fill_grab horizontal)
-     *     + TableWrapLayout [*]
-     *       + Labels/Forms/etc... [*]
-     * </pre>
-     * Both items marked with [*] are created by the derived classes to fit their needs.
-     * 
-     * @param parent Parent of the mSection (from createContents)
-     * @return The new Section
-     */
-    private Section createMasterSection(Composite parent) {
-        TableWrapLayout layout = new TableWrapLayout();
-        layout.topMargin = 0;
-        parent.setLayout(layout);
-
-        FormToolkit toolkit = mManagedForm.getToolkit();
-        Section section = toolkit.createSection(parent, Section.TITLE_BAR);
-        section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP));
-        return section;
-    }
-
-    /**
-     * Create the ui attribute controls to edit the attributes for the given
-     * ElementDescriptor.
-     * <p/>
-     * This is called by the constructor.
-     * Derived classes can override this if necessary.
-     * 
-     * @param managedForm The managed form
-     */
-    private void createUiAttributeControls(
-            final IManagedForm managedForm,
-            final UiElementNode ui_node) {
-
-        final ElementDescriptor elem_desc = ui_node.getDescriptor();
-        mMasterSection.setText(String.format("Attributes for %1$s", ui_node.getShortDescription()));
-
-        if (mCurrentUiElementNode != ui_node) {
-            // Before changing the table, commit all dirty state.
-            if (mIsDirty) {
-                commit(false);
-            }
-            if (mCurrentTable != null) {
-                mCurrentTable.dispose();
-                mCurrentTable = null;
-            }
-
-            // To iterate over all attributes, we use the {@link ElementDescriptor} instead
-            // of the {@link UiElementNode} because the attributes order is guaranteed in the
-            // descriptor but not in the node itself.
-            AttributeDescriptor[] attr_desc_list = ui_node.getAttributeDescriptors();
-
-            // If the attribute list contains at least one SeparatorAttributeDescriptor,
-            // sub-sections will be used. This needs to be known early as it influences the
-            // creation of the master table.
-            boolean useSubsections = false;
-            for (AttributeDescriptor attr_desc : attr_desc_list) {
-                if (attr_desc instanceof SeparatorAttributeDescriptor) {
-                    // Sub-sections will be used. The default sections should no longer be
-                    useSubsections = true;
-                    break;
-                }
-            }
-
-            FormToolkit toolkit = managedForm.getToolkit();
-            Composite masterTable = SectionHelper.createTableLayout(mMasterSection,
-                    toolkit, useSubsections ? 1 : 2 /* numColumns */);
-            mCurrentTable = masterTable;
-
-            mCurrentUiElementNode = ui_node;
-                
-            if (elem_desc.getTooltip() != null) {
-                String tooltip;
-                if (Sdk.getCurrent() != null &&
-                        Sdk.getCurrent().getDocumentationBaseUrl() != null) {
-                    tooltip = DescriptorsUtils.formatFormText(elem_desc.getTooltip(),
-                            elem_desc,
-                            Sdk.getCurrent().getDocumentationBaseUrl());
-                } else {
-                    tooltip = elem_desc.getTooltip();
-                }
-
-                try {
-                    FormText text = SectionHelper.createFormText(masterTable, toolkit,
-                            true /* isHtml */, tooltip, true /* setupLayoutData */);
-                    text.addHyperlinkListener(mTree.getEditor().createHyperlinkListener());
-                    Image icon = elem_desc.getIcon();
-                    if (icon != null) {
-                        text.setImage(DescriptorsUtils.IMAGE_KEY, icon);
-                    }
-                } catch(Exception e) {
-                    // The FormText parser is really really basic and will fail as soon as the
-                    // HTML javadoc is ever so slightly malformatted.
-                    AdtPlugin.log(e,
-                            "Malformed javadoc, rejected by FormText for node %1$s: '%2$s'", //$NON-NLS-1$
-                            ui_node.getDescriptor().getXmlName(),
-                            tooltip);
-                    
-                    // Fallback to a pure text tooltip, no fancy HTML
-                    tooltip = DescriptorsUtils.formatTooltip(elem_desc.getTooltip());
-                    Label label = SectionHelper.createLabel(masterTable, toolkit,
-                            tooltip, tooltip);
-                }
-            }
-
-            Composite table = useSubsections ? null : masterTable;
-            
-            for (AttributeDescriptor attr_desc : attr_desc_list) {
-                if (attr_desc instanceof XmlnsAttributeDescriptor) {
-                    // Do not show hidden attributes
-                    continue;
-                } else if (table == null || attr_desc instanceof SeparatorAttributeDescriptor) {
-                    String title = null;
-                    if (attr_desc instanceof SeparatorAttributeDescriptor) {
-                        // xmlName is actually the label of the separator
-                        title = attr_desc.getXmlLocalName();
-                    } else {
-                        title = String.format("Attributes from %1$s", elem_desc.getUiName());
-                    }
-
-                    table = createSubSectionTable(toolkit, masterTable, title);
-                    if (attr_desc instanceof SeparatorAttributeDescriptor) {
-                        continue;
-                    }
-                }
-
-                UiAttributeNode ui_attr = ui_node.findUiAttribute(attr_desc);
-
-                if (ui_attr != null) {
-                    ui_attr.createUiControl(table, managedForm);
-                    
-                    if (ui_attr.getCurrentValue() != null &&
-                            ui_attr.getCurrentValue().length() > 0) {
-                        ((Section) table.getParent()).setExpanded(true);
-                    }
-                } else {
-                    // The XML has an extra unknown attribute.
-                    // This is not expected to happen so it is ignored.
-                    AdtPlugin.log(IStatus.INFO,
-                            "Attribute %1$s not declared in node %2$s, ignored.", //$NON-NLS-1$
-                            attr_desc.getXmlLocalName(),
-                            ui_node.getDescriptor().getXmlName());
-                }
-            }
-
-            // Create a sub-section for the unknown attributes.
-            // It is initially hidden till there are some attributes to show here.
-            final Composite unknownTable = createSubSectionTable(toolkit, masterTable,
-                    "Unknown XML Attributes");
-            unknownTable.getParent().setVisible(false); // set section to not visible
-            final HashSet<UiAttributeNode> reference = new HashSet<UiAttributeNode>();
-            
-            final IUiUpdateListener updateListener = new IUiUpdateListener() {
-                public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-                    if (state == UiUpdateState.ATTR_UPDATED) {
-                        updateUnknownAttributesSection(ui_node, unknownTable, managedForm,
-                                reference);
-                    }
-                }
-            };
-            ui_node.addUpdateListener(updateListener);
-            
-            // remove the listener when the UI is disposed
-            unknownTable.addDisposeListener(new DisposeListener() {
-                public void widgetDisposed(DisposeEvent e) {
-                    ui_node.removeUpdateListener(updateListener);
-                }
-            });
-            
-            updateUnknownAttributesSection(ui_node, unknownTable, managedForm, reference);
-            
-            mMasterSection.getParent().pack(true /* changed */);
-        }
-    }
-
-    /**
-     * Create a sub Section and its embedding wrapper table with 2 columns.
-     * @return The table, child of a new section.
-     */
-    private Composite createSubSectionTable(FormToolkit toolkit,
-            Composite masterTable, String title) {
-        
-        // The Section composite seems to ignore colspan when assigned a TableWrapData so
-        // if the parent is a table with more than one column an extra table with one column
-        // is inserted to respect colspan.
-        int parentNumCol = ((TableWrapLayout) masterTable.getLayout()).numColumns;
-        if (parentNumCol > 1) {
-            masterTable = SectionHelper.createTableLayout(masterTable, toolkit, 1);
-            TableWrapData twd = new TableWrapData(TableWrapData.FILL_GRAB);
-            twd.maxWidth = AndroidEditor.TEXT_WIDTH_HINT;
-            twd.colspan = parentNumCol;
-            masterTable.setLayoutData(twd);
-        }
-        
-        Composite table;
-        Section section = toolkit.createSection(masterTable,
-                Section.TITLE_BAR | Section.TWISTIE);
-
-        // Add an expansion listener that will trigger a reflow on the parent
-        // ScrolledPageBook (which is actually a SharedScrolledComposite). This will
-        // recompute the correct size and adjust the scrollbar as needed.
-        section.addExpansionListener(new IExpansionListener() {
-            public void expansionStateChanged(ExpansionEvent e) {
-                reflowMasterSection();
-            }
-
-            public void expansionStateChanging(ExpansionEvent e) {
-                // pass
-            }
-        });
-
-        section.setText(title);
-        section.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB,
-                                                TableWrapData.TOP));
-        table = SectionHelper.createTableLayout(section, toolkit, 2 /* numColumns */);
-        return table;
-    }
-
-    /**
-     * Reflow the parent ScrolledPageBook (which is actually a SharedScrolledComposite).
-     * This will recompute the correct size and adjust the scrollbar as needed.
-     */
-    private void reflowMasterSection() {
-        for(Composite c = mMasterSection; c != null; c = c.getParent()) {
-            if (c instanceof SharedScrolledComposite) {
-                ((SharedScrolledComposite) c).reflow(true /* flushCache */);
-                break;
-            }
-        }
-    }
-
-    /**
-     * Updates the unknown attributes section for the UI Node.
-     */
-    private void updateUnknownAttributesSection(UiElementNode ui_node,
-            final Composite unknownTable, final IManagedForm managedForm,
-            HashSet<UiAttributeNode> reference) {
-        Collection<UiAttributeNode> ui_attrs = ui_node.getUnknownUiAttributes();
-        Section section = ((Section) unknownTable.getParent());
-        boolean needs_reflow = false;
-
-        // The table was created hidden, show it if there are unknown attributes now
-        if (ui_attrs.size() > 0 && !section.isVisible()) {
-            section.setVisible(true);
-            needs_reflow = true;
-        }
-
-        // Compare the new attribute set with the old "reference" one
-        boolean has_differences = ui_attrs.size() != reference.size();
-        if (!has_differences) {
-            for (UiAttributeNode ui_attr : ui_attrs) {
-                if (!reference.contains(ui_attr)) {
-                    has_differences = true;
-                    break;
-                }
-            }
-        }
-
-        if (has_differences) {
-            needs_reflow = true;
-            reference.clear();
-            
-            // Remove all children of the table
-            for (Control c : unknownTable.getChildren()) {
-                c.dispose();
-            }
-    
-            // Recreate all attributes UI
-            for (UiAttributeNode ui_attr : ui_attrs) {
-                reference.add(ui_attr);
-                ui_attr.createUiControl(unknownTable, managedForm);
-    
-                if (ui_attr.getCurrentValue() != null && ui_attr.getCurrentValue().length() > 0) {
-                    section.setExpanded(true);
-                }
-            }
-        }
-        
-        if (needs_reflow) {
-            reflowMasterSection();
-        }
-    }
-    
-    /**
-     * Marks the part dirty. Called as a result of user interaction with the widgets in the
-     * section.
-     */
-    private void markDirty() {
-        if (!mIsDirty) {
-            mIsDirty = true;
-            mManagedForm.dirtyStateChanged();
-        }
-    }
-}
-
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeContentProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeContentProvider.java
deleted file mode 100644
index 9f34d9e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeContentProvider.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-
-import java.util.ArrayList;
-
-/**
- * UiModelTreeContentProvider is a trivial implementation of {@link ITreeContentProvider}
- * where elements are expected to be instances of {@link UiElementNode}.
- */
-class UiModelTreeContentProvider implements ITreeContentProvider {
-    
-    /** The root {@link UiElementNode} which contains all the elements that are to be 
-     *  manipulated by this tree view. In general this is the manifest UI node. */
-    private UiElementNode mUiRootNode;
-    /** The descriptor of the elements to be displayed as root in this tree view. All elements
-     *  of the same type in the root will be displayed. */
-    private ElementDescriptor[] mDescriptorFilters;
-
-    public UiModelTreeContentProvider(UiElementNode uiRootNode,
-            ElementDescriptor[] descriptorFilters) {
-        mUiRootNode = uiRootNode;
-        mDescriptorFilters = descriptorFilters;
-    }
-    
-    /* (non-java doc)
-     * Returns all the UI node children of the given element or null if not the right kind
-     * of object. */
-    public Object[] getChildren(Object parentElement) {
-        if (parentElement instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) parentElement;
-            return node.getUiChildren().toArray();
-        }
-        return null;
-    }
-
-    /* (non-java doc)
-     * Returns the parent of a given UI node or null if it's a root node or it's not the
-     * right kind of node. */
-    public Object getParent(Object element) {
-        if (element instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) element;
-            return node.getUiParent();
-        }
-        return null;
-    }
-
-    /* (non-java doc)
-     * Returns true if the UI node has any UI children nodes. */
-    public boolean hasChildren(Object element) {
-        if (element instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) element;
-            return node.getUiChildren().size() > 0;
-        }
-        return false;
-    }
-
-    /* (non-java doc)
-     * Get root elements for the tree. These are all the UI nodes that
-     * match the filter descriptor in the current root node.
-     * <p/>
-     * Although not documented, it seems this method should not return null.
-     * At worse, it should return new Object[0].
-     * <p/>
-     * inputElement is not currently used. The root node and the filter are given
-     * by the enclosing class.
-     */
-    public Object[] getElements(Object inputElement) {
-        ArrayList<UiElementNode> roots = new ArrayList<UiElementNode>();
-        if (mUiRootNode != null) {
-            for (UiElementNode ui_node : mUiRootNode.getUiChildren()) {
-                if (mDescriptorFilters == null || mDescriptorFilters.length == 0) {
-                    roots.add(ui_node);
-                } else {
-                    for (ElementDescriptor filter : mDescriptorFilters) {
-                        if (ui_node.getDescriptor() == filter) {
-                            roots.add(ui_node);
-                        }
-                    }
-                }
-            }
-        }
-        
-        return roots.toArray();
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        // pass
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeLabelProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeLabelProvider.java
deleted file mode 100644
index 273a30b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiModelTreeLabelProvider.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.ui.ErrorImageComposite;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * UiModelTreeLabelProvider is a trivial implementation of {@link ILabelProvider}
- * where elements are expected to derive from {@link UiElementNode} or
- * from {@link ElementDescriptor}.
- * 
- * It is used by both the master tree viewer and by the list in the Add... selection dialog.
- */
-public class UiModelTreeLabelProvider implements ILabelProvider {
-
-    public UiModelTreeLabelProvider() {
-    }
-
-    /**
-     * Returns the element's logo with a fallback on the android logo.
-     */
-    public Image getImage(Object element) {
-        ElementDescriptor desc = null;
-        if (element instanceof ElementDescriptor) {
-            Image img = ((ElementDescriptor) element).getIcon();
-            if (img != null) {
-                return img;
-            }
-        } else if (element instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) element;
-            desc = node.getDescriptor();
-            if (desc != null) {
-                Image img = desc.getIcon();
-                if (img != null) {
-                    if (node.hasError()) {
-                        //TODO: cache image
-                        return new ErrorImageComposite(img).createImage();
-                    } else {
-                        return img;
-                    }
-                }
-            }
-        }
-        return AdtPlugin.getAndroidLogo();
-    }
-
-    /**
-     * Uses UiElementNode.shortDescription for the label for this tree item.
-     */
-    public String getText(Object element) {
-        if (element instanceof ElementDescriptor) {
-            ElementDescriptor desc = (ElementDescriptor) element;
-            return desc.getUiName();
-        } else if (element instanceof UiElementNode) {
-            UiElementNode node = (UiElementNode) element;
-            return node.getShortDescription();
-        }
-        return element.toString();
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // pass
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        // pass
-        return false;
-    }
-
-    public void removeListener(ILabelProviderListener listener) {
-        // pass
-    }
-}
-
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiTreeBlock.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiTreeBlock.java
deleted file mode 100644
index e3255d9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/ui/tree/UiTreeBlock.java
+++ /dev/null
@@ -1,868 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.ui.tree;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.ide.eclipse.editors.ui.SectionHelper.ManifestSectionPart;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.action.ToolBarManager;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ITreeSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TreePath;
-import org.eclipse.jface.viewers.TreeSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerComparator;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.ToolBar;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.ui.forms.DetailsPart;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IDetailsPageProvider;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.MasterDetailsBlock;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.LinkedList;
-
-/**
- * {@link UiTreeBlock} is a {@link MasterDetailsBlock} which displays a tree view for
- * a specific set of {@link UiElementNode}.
- * <p/>
- * For a given UI element node, the tree view displays all first-level children that
- * match a given type (given by an {@link ElementDescriptor}. All children from these
- * nodes are also displayed.
- * <p/>
- * In the middle next to the tree are some controls to add or delete tree nodes.
- * On the left is a details part that displays all the visible UI attributes for a given
- * selected UI element node.
- */
-public final class UiTreeBlock extends MasterDetailsBlock implements ICommitXml {
-
-    /** Height hint for the tree view. Helps the grid layout resize properly on smaller screens. */
-    private static final int TREE_HEIGHT_HINT = 50;
-
-    /** Container editor */
-    AndroidEditor mEditor;
-    /** The root {@link UiElementNode} which contains all the elements that are to be 
-     *  manipulated by this tree view. In general this is the manifest UI node. */
-    private UiElementNode mUiRootNode;
-    /** The descriptor of the elements to be displayed as root in this tree view. All elements
-     *  of the same type in the root will be displayed. */
-    private ElementDescriptor[] mDescriptorFilters;
-    /** The title for the master-detail part (displayed on the top "tab" on top of the tree) */
-    private String mTitle;
-    /** The description for the master-detail part (displayed on top of the tree view) */
-    private String mDescription;
-    /** The master-detail part, composed of a main tree and an auxiliary detail part */
-    private ManifestSectionPart mMasterPart;
-    /** The tree viewer in the master-detail part */
-    private TreeViewer mTreeViewer;
-    /** The "add" button for the tree view */ 
-    private Button mAddButton;
-    /** The "remove" button for the tree view */
-    private Button mRemoveButton;
-    /** The "up" button for the tree view */
-    private Button mUpButton;
-    /** The "down" button for the tree view */
-    private Button mDownButton;
-    /** The Managed Form used to create the master part */
-    private IManagedForm mManagedForm;
-    /** Reference to the details part of the tree master block. */
-    private DetailsPart mDetailsPart;
-    /** Reference to the clipboard for copy-paste */
-    private Clipboard mClipboard;
-    /** Listener to refresh the tree viewer when the parent's node has been updated */
-    private IUiUpdateListener mUiRefreshListener;
-    /** Listener to enable/disable the UI based on the application node's presence */
-    private IUiUpdateListener mUiEnableListener;
-    /** An adapter/wrapper to use the add/remove/up/down tree edit actions. */
-    private UiTreeActions mUiTreeActions;
-    /**
-     * True if the root node can be created on-demand (i.e. as needed as
-     * soon as children exist). False if an external entity controls the existence of the
-     * root node. In practise, this is false for the manifest application page (the actual
-     * "application" node is managed by the ApplicationToggle part) whereas it is true
-     * for all other tree pages.
-     */
-    private final boolean mAutoCreateRoot;
-
-
-    /**
-     * Creates a new {@link MasterDetailsBlock} that will display all UI nodes matching the
-     * given filter in the given root node.
-     * 
-     * @param editor The parent manifest editor.
-     * @param uiRootNode The root {@link UiElementNode} which contains all the elements that are
-     *        to be manipulated by this tree view. In general this is the manifest UI node or the
-     *        application UI node. This cannot be null.
-     * @param autoCreateRoot True if the root node can be created on-demand (i.e. as needed as
-     *        soon as children exist). False if an external entity controls the existence of the
-     *        root node. In practise, this is false for the manifest application page (the actual
-     *        "application" node is managed by the ApplicationToggle part) whereas it is true
-     *        for all other tree pages.
-     * @param descriptorFilters A list of descriptors of the elements to be displayed as root in
-     *        this tree view. Use null or an empty list to accept any kind of node.
-     * @param title Title for the section
-     * @param description Description for the section
-     */
-    public UiTreeBlock(AndroidEditor editor,
-            UiElementNode uiRootNode,
-            boolean autoCreateRoot,
-            ElementDescriptor[] descriptorFilters,
-            String title,
-            String description) {
-        mEditor = editor;
-        mUiRootNode = uiRootNode;
-        mAutoCreateRoot = autoCreateRoot;
-        mDescriptorFilters = descriptorFilters;
-        mTitle = title;
-        mDescription = description;
-    }
-    
-    /** @returns The container editor */
-    AndroidEditor getEditor() {
-        return mEditor;
-    }
-    
-    /** @returns The reference to the clipboard for copy-paste */
-    Clipboard getClipboard() {
-        return mClipboard;
-    }
-    
-    /** @returns The master-detail part, composed of a main tree and an auxiliary detail part */
-    ManifestSectionPart getMasterPart() {
-        return mMasterPart;
-    }
-
-    @Override
-    protected void createMasterPart(final IManagedForm managedForm, Composite parent) {
-        FormToolkit toolkit = managedForm.getToolkit();
-
-        mManagedForm = managedForm;
-        mMasterPart = new ManifestSectionPart(parent, toolkit);
-        Section section = mMasterPart.getSection();
-        section.setText(mTitle);
-        section.setDescription(mDescription);
-        section.setLayout(new GridLayout());
-        section.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Composite grid = SectionHelper.createGridLayout(section, toolkit, 2);
-
-        Tree tree = createTreeViewer(toolkit, grid, managedForm);
-        createButtons(toolkit, grid);
-        createTreeContextMenu(tree);
-        createSectionActions(section, toolkit);
-    }
-
-    private void createSectionActions(Section section, FormToolkit toolkit) {
-        ToolBarManager manager = new ToolBarManager(SWT.FLAT);
-        manager.removeAll();
-        
-        ToolBar toolbar = manager.createControl(section);        
-        section.setTextClient(toolbar);
-        
-        ElementDescriptor[] descs = mDescriptorFilters;
-        if (descs == null && mUiRootNode != null) {
-            descs = mUiRootNode.getDescriptor().getChildren();
-        }
-        
-        if (descs != null && descs.length > 1) {
-            for (ElementDescriptor desc : descs) {
-                manager.add(new DescriptorFilterAction(desc));
-            }
-        }
-        
-        manager.add(new TreeSortAction());
-
-        manager.update(true /*force*/);
-    }
-
-    /**
-     * Creates the tree and its viewer
-     * @return The tree control
-     */
-    private Tree createTreeViewer(FormToolkit toolkit, Composite grid,
-            final IManagedForm managedForm) {
-        // Note: we *could* use a FilteredTree instead of the Tree+TreeViewer here.
-        // However the class must be adapted to create an adapted toolkit tree.
-        final Tree tree = toolkit.createTree(grid, SWT.MULTI);
-        GridData gd = new GridData(GridData.FILL_BOTH);
-        gd.widthHint = AndroidEditor.TEXT_WIDTH_HINT;
-        gd.heightHint = TREE_HEIGHT_HINT;
-        tree.setLayoutData(gd);
-
-        mTreeViewer = new TreeViewer(tree);
-        mTreeViewer.setContentProvider(new UiModelTreeContentProvider(
-                mUiRootNode, mDescriptorFilters));
-        mTreeViewer.setLabelProvider(new UiModelTreeLabelProvider());
-        mTreeViewer.setInput("unused"); //$NON-NLS-1$
-
-        // Create a listener that reacts to selections on the tree viewer.
-        // When a selection is made, ask the managed form to propagate an event to
-        // all parts in the managed form.
-        // This is picked up by UiElementDetail.selectionChanged().
-        mTreeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                managedForm.fireSelectionChanged(mMasterPart, event.getSelection());
-                adjustTreeButtons(event.getSelection());
-            }
-        });
-        
-        // Create three listeners:
-        // - One to refresh the tree viewer when the parent's node has been updated
-        // - One to refresh the tree viewer when the framework resources have changed
-        // - One to enable/disable the UI based on the application node's presence.
-        mUiRefreshListener = new IUiUpdateListener() {
-            public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-                mTreeViewer.refresh();
-            }
-        };
-        
-        mUiEnableListener = new IUiUpdateListener() {
-            public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state) {
-                // The UiElementNode for the application XML node always exists, even
-                // if there is no corresponding XML node in the XML file.
-                //
-                // Normally, we enable the UI here if the XML node is not null.
-                //
-                // However if mAutoCreateRoot is true, the root node will be created on-demand
-                // so the tree/block is always enabled.
-                boolean exists = mAutoCreateRoot || (ui_node.getXmlNode() != null);
-                if (mMasterPart != null) {
-                    Section section = mMasterPart.getSection();
-                    if (section.getEnabled() != exists) {
-                        section.setEnabled(exists);
-                        for (Control c : section.getChildren()) {
-                            c.setEnabled(exists);
-                        }
-                    }
-                }
-            }
-        };
-
-        final Runnable resourceRefreshListener = new Runnable() {
-            public void run() {
-                // If a details part has been created, we need to "refresh" it too.
-                if (mDetailsPart != null) {
-                    // The details part does not directly expose access to its internal
-                    // page book. Instead it is possible to resize the page book to 0 and then
-                    // back to its original value, which as the side effect of removing all
-                    // existing cached pages.
-                    int limit = mDetailsPart.getPageLimit();
-                    mDetailsPart.setPageLimit(0);
-                    mDetailsPart.setPageLimit(limit);
-                }
-                // Refresh the tree, preserving the selection if possible.
-                mTreeViewer.refresh();
-            }
-        };
-
-        // Setup the listeners
-        changeRootAndDescriptors(mUiRootNode, mDescriptorFilters, false /* refresh */);
-
-        // Listen on resource framework changes to refresh the tree
-        AdtPlugin.getDefault().addResourceChangedListener(resourceRefreshListener);
-
-        // Remove listeners when the tree widget gets disposed.
-        tree.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                UiElementNode node = mUiRootNode.getUiParent() != null ?
-                                        mUiRootNode.getUiParent() :
-                                        mUiRootNode;
-
-                node.removeUpdateListener(mUiRefreshListener);
-                mUiRootNode.removeUpdateListener(mUiEnableListener);
-
-                AdtPlugin.getDefault().removeResourceChangedListener(resourceRefreshListener);
-                if (mClipboard != null) {
-                    mClipboard.dispose();
-                    mClipboard = null;
-                }
-            }
-        });
-        
-        // Get a new clipboard reference. It is disposed when the tree is disposed.
-        mClipboard = new Clipboard(tree.getDisplay());
-
-        return tree;
-    }
-
-    /**
-     * Changes the UI root node and the descriptor filters of the tree.
-     * <p/>
-     * This removes the listeners attached to the old root node and reattaches them to the
-     * new one.
-     * 
-     * @param uiRootNode The root {@link UiElementNode} which contains all the elements that are
-     *        to be manipulated by this tree view. In general this is the manifest UI node or the
-     *        application UI node. This cannot be null.
-     * @param descriptorFilters A list of descriptors of the elements to be displayed as root in
-     *        this tree view. Use null or an empty list to accept any kind of node.
-     * @param forceRefresh If tree, forces the tree to refresh
-     */
-    public void changeRootAndDescriptors(UiElementNode uiRootNode,
-            ElementDescriptor[] descriptorFilters, boolean forceRefresh) {
-        UiElementNode node;
-
-        // Remove previous listeners if any
-        if (mUiRootNode != null) {
-            node = mUiRootNode.getUiParent() != null ? mUiRootNode.getUiParent() : mUiRootNode;
-            node.removeUpdateListener(mUiRefreshListener);
-            mUiRootNode.removeUpdateListener(mUiEnableListener);
-        }
-        
-        mUiRootNode = uiRootNode;
-        mDescriptorFilters = descriptorFilters;
-
-        // Listen on structural changes on the root node of the tree
-        // If the node has a parent, listen on the parent instead.
-        node = mUiRootNode.getUiParent() != null ? mUiRootNode.getUiParent() : mUiRootNode;
-        node.addUpdateListener(mUiRefreshListener);
-        
-        // Use the root node to listen to its presence.
-        mUiRootNode.addUpdateListener(mUiEnableListener);
-
-        // Initialize the enabled/disabled state
-        mUiEnableListener.uiElementNodeUpdated(mUiRootNode, null /* state, not used */);
-        
-        if (forceRefresh) {
-            mTreeViewer.refresh();
-        }
-
-        createSectionActions(mMasterPart.getSection(), mManagedForm.getToolkit());
-    }
-
-    /**
-     * Creates the buttons next to the tree.
-     */
-    private void createButtons(FormToolkit toolkit, Composite grid) {
-        
-        mUiTreeActions = new UiTreeActions();
-        
-        Composite button_grid = SectionHelper.createGridLayout(grid, toolkit, 1);
-        button_grid.setLayoutData(new GridData(GridData.VERTICAL_ALIGN_BEGINNING));
-        mAddButton = toolkit.createButton(button_grid, "Add...", SWT.PUSH);
-        SectionHelper.addControlTooltip(mAddButton, "Adds a new element.");
-        mAddButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL |
-                GridData.VERTICAL_ALIGN_BEGINNING));
-
-        mAddButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                doTreeAdd();
-            }
-        });
-        
-        mRemoveButton = toolkit.createButton(button_grid, "Remove...", SWT.PUSH);
-        SectionHelper.addControlTooltip(mRemoveButton, "Removes an existing selected element.");
-        mRemoveButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        mRemoveButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                doTreeRemove();
-            }
-        });
-        
-        mUpButton = toolkit.createButton(button_grid, "Up", SWT.PUSH);
-        SectionHelper.addControlTooltip(mRemoveButton, "Moves the selected element up.");
-        mUpButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        mUpButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                doTreeUp();
-            }
-        });
-
-        mDownButton = toolkit.createButton(button_grid, "Down", SWT.PUSH);
-        SectionHelper.addControlTooltip(mRemoveButton, "Moves the selected element down.");
-        mDownButton.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        
-        mDownButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                doTreeDown();
-            }
-        });
-
-        adjustTreeButtons(TreeSelection.EMPTY);
-    }
-
-    private void createTreeContextMenu(Tree tree) {
-        MenuManager menuManager = new MenuManager();
-        menuManager.setRemoveAllWhenShown(true);
-        menuManager.addMenuListener(new IMenuListener() {
-            /**
-             * The menu is about to be shown. The menu manager has already been
-             * requested to remove any existing menu item. This method gets the
-             * tree selection and if it is of the appropriate type it re-creates
-             * the necessary actions.
-             */
-           public void menuAboutToShow(IMenuManager manager) {
-               ISelection selection = mTreeViewer.getSelection();
-               if (!selection.isEmpty() && selection instanceof ITreeSelection) {
-                   ArrayList<UiElementNode> selected = filterSelection((ITreeSelection) selection);
-                   doCreateMenuAction(manager, selected);
-                   return;
-               }
-               doCreateMenuAction(manager, null /* ui_node */);
-            } 
-        });
-        Menu contextMenu = menuManager.createContextMenu(tree);
-        tree.setMenu(contextMenu);
-    }
-
-    /**
-     * Adds the menu actions to the context menu when the given UI node is selected in
-     * the tree view.
-     * 
-     * @param manager The context menu manager
-     * @param selected The UI nodes selected in the tree. Can be null, in which case the root
-     *                is to be modified.
-     */
-    private void doCreateMenuAction(IMenuManager manager, ArrayList<UiElementNode> selected) {
-        if (selected != null) {
-            boolean hasXml = false;
-            for (UiElementNode uiNode : selected) {
-                if (uiNode.getXmlNode() != null) {
-                    hasXml = true;
-                    break;
-                }
-            }
-
-            if (hasXml) {
-                manager.add(new CopyCutAction(getEditor(), getClipboard(),
-                        null, selected, true /* cut */));
-                manager.add(new CopyCutAction(getEditor(), getClipboard(),
-                        null, selected, false /* cut */));
-
-                // Can't paste with more than one element selected (the selection is the target)
-                if (selected.size() <= 1) {
-                    // Paste is not valid if it would add a second element on a terminal element
-                    // which parent is a document -- an XML document can only have one child. This
-                    // means paste is valid if the current UI node can have children or if the
-                    // parent is not a document.
-                    UiElementNode ui_root = selected.get(0).getUiRoot();
-                    if (ui_root.getDescriptor().hasChildren() ||
-                            !(ui_root.getUiParent() instanceof UiDocumentNode)) {
-                        manager.add(new PasteAction(getEditor(), getClipboard(), selected.get(0)));
-                    }
-                }
-                manager.add(new Separator());
-            }
-        }
-
-        // Append "add" and "remove" actions. They do the same thing as the add/remove
-        // buttons on the side.
-        Action action;
-        IconFactory factory = IconFactory.getInstance();
-
-        // "Add" makes sense only if there's 0 or 1 item selected since the
-        // one selected item becomes the target.
-        if (selected == null || selected.size() <= 1) {
-            manager.add(new Action("Add...", factory.getImageDescriptor("add")) { //$NON-NLS-1$
-                @Override
-                public void run() {
-                    super.run();
-                    doTreeAdd();
-                }
-            });
-        }
-
-        if (selected != null) {
-            if (selected != null) {
-                manager.add(new Action("Remove", factory.getImageDescriptor("delete")) { //$NON-NLS-1$
-                    @Override
-                    public void run() {
-                        super.run();
-                        doTreeRemove();
-                    }
-                });
-            }
-            manager.add(new Separator());
-            
-            manager.add(new Action("Up", factory.getImageDescriptor("up")) { //$NON-NLS-1$
-                @Override
-                public void run() {
-                    super.run();
-                    doTreeUp();
-                }
-            });
-            manager.add(new Action("Down", factory.getImageDescriptor("down")) { //$NON-NLS-1$
-                @Override
-                public void run() {
-                    super.run();
-                    doTreeDown();
-                }
-            });
-        }
-    }
-
-    
-    /**
-     * This is called by the tree when a selection is made.
-     * It enables/disables the buttons associated with the tree depending on the current
-     * selection.
-     *
-     * @param selection The current tree selection (same as mTreeViewer.getSelection())
-     */
-    private void adjustTreeButtons(ISelection selection) {
-        mRemoveButton.setEnabled(!selection.isEmpty() && selection instanceof ITreeSelection);
-        mUpButton.setEnabled(!selection.isEmpty() && selection instanceof ITreeSelection);
-        mDownButton.setEnabled(!selection.isEmpty() && selection instanceof ITreeSelection);
-    }
-
-    /**
-     * An adapter/wrapper to use the add/remove/up/down tree edit actions.
-     */
-    private class UiTreeActions extends UiActions {
-        @Override
-        protected UiElementNode getRootNode() {
-            return mUiRootNode;
-        }
-
-        @Override
-        protected void selectUiNode(UiElementNode uiNodeToSelect) {
-            // Select the new item
-            if (uiNodeToSelect != null) {
-                LinkedList<UiElementNode> segments = new LinkedList<UiElementNode>();
-                for (UiElementNode ui_node = uiNodeToSelect; ui_node != mUiRootNode;
-                        ui_node = ui_node.getUiParent()) {
-                    segments.add(0, ui_node);
-                }
-                mTreeViewer.setSelection(new TreeSelection(new TreePath(segments.toArray())));
-            }
-        }
-
-        @Override
-        public void commitPendingXmlChanges() {
-            commitManagedForm();
-        }
-    }
-
-    /**
-     * Filters an ITreeSelection to only keep the {@link UiElementNode}s (in case there's
-     * something else in there).
-     * 
-     * @return A new list of {@link UiElementNode} with at least one item or null.
-     */
-    @SuppressWarnings("unchecked")
-    private ArrayList<UiElementNode> filterSelection(ITreeSelection selection) {
-        ArrayList<UiElementNode> selected = new ArrayList<UiElementNode>();
-        
-        for (Iterator it = selection.iterator(); it.hasNext(); ) {
-            Object selectedObj = it.next();
-        
-            if (selectedObj instanceof UiElementNode) {
-                selected.add((UiElementNode) selectedObj);
-            }
-        }
-
-        return selected.size() > 0 ? selected : null;
-    }
-
-    /**
-     * Called when the "Add..." button next to the tree view is selected.
-     * 
-     * Displays a selection dialog that lets the user select which kind of node
-     * to create, depending on the current selection.
-     */
-    private void doTreeAdd() {
-        UiElementNode ui_node = mUiRootNode;
-        ISelection selection = mTreeViewer.getSelection();
-        if (!selection.isEmpty() && selection instanceof ITreeSelection) {
-            ITreeSelection tree_selection = (ITreeSelection) selection;
-            Object first = tree_selection.getFirstElement();
-            if (first != null && first instanceof UiElementNode) {
-                ui_node = (UiElementNode) first;
-            }
-        }
-
-        mUiTreeActions.doAdd(
-                ui_node,
-                mDescriptorFilters,
-                mTreeViewer.getControl().getShell(),
-                (ILabelProvider) mTreeViewer.getLabelProvider());
-    }
-
-    /**
-     * Called when the "Remove" button is selected.
-     * 
-     * If the tree has a selection, remove it.
-     * This simply deletes the XML node attached to the UI node: when the XML model fires the
-     * update event, the tree will get refreshed.
-     */
-    protected void doTreeRemove() {
-        ISelection selection = mTreeViewer.getSelection();
-        if (!selection.isEmpty() && selection instanceof ITreeSelection) {
-            ArrayList<UiElementNode> selected = filterSelection((ITreeSelection) selection);
-            mUiTreeActions.doRemove(selected, mTreeViewer.getControl().getShell());
-        }
-    }
-
-    /**
-     * Called when the "Up" button is selected.
-     * <p/>
-     * If the tree has a selection, move it up, either in the child list or as the last child
-     * of the previous parent.
-     */
-    protected void doTreeUp() {
-        ISelection selection = mTreeViewer.getSelection();
-        if (!selection.isEmpty() && selection instanceof ITreeSelection) {
-            ArrayList<UiElementNode> selected = filterSelection((ITreeSelection) selection);
-            mUiTreeActions.doUp(selected);
-        }
-    }
-    
-    /**
-     * Called when the "Down" button is selected.
-     * 
-     * If the tree has a selection, move it down, either in the same child list or as the
-     * first child of the next parent.
-     */
-    protected void doTreeDown() {
-        ISelection selection = mTreeViewer.getSelection();
-        if (!selection.isEmpty() && selection instanceof ITreeSelection) {
-            ArrayList<UiElementNode> selected = filterSelection((ITreeSelection) selection);
-            mUiTreeActions.doDown(selected);
-        }
-    }
-
-    /**
-     * Commits the current managed form (the one associated with our master part).
-     * As a side effect, this will commit the current UiElementDetails page.
-     */
-    void commitManagedForm() {
-        if (mManagedForm != null) {
-            mManagedForm.commit(false /* onSave */);
-        }
-    }
-
-    /* Implements ICommitXml for CopyCutAction */
-    public void commitPendingXmlChanges() {
-        commitManagedForm();
-    }
-
-    @Override
-    protected void createToolBarActions(IManagedForm managedForm) {
-        // Pass. Not used, toolbar actions are defined by createSectionActions().
-    }
-
-    @Override
-    protected void registerPages(DetailsPart detailsPart) {
-        // Keep a reference on the details part (the super class doesn't provide a getter
-        // for it.)
-        mDetailsPart = detailsPart;
-        
-        // The page selection mechanism does not use pages registered by association with
-        // a node class. Instead it uses a custom details page provider that provides a
-        // new UiElementDetail instance for each node instance. A limit of 5 pages is
-        // then set (the value is arbitrary but should be reasonable) for the internal
-        // page book.
-        detailsPart.setPageLimit(5);
-        
-        final UiTreeBlock tree = this;
-        
-        detailsPart.setPageProvider(new IDetailsPageProvider() {
-            public IDetailsPage getPage(Object key) {
-                if (key instanceof UiElementNode) {
-                    return new UiElementDetail(tree);
-                }
-                return null;
-            }
-
-            public Object getPageKey(Object object) {
-                return object;  // use node object as key
-            }
-        });
-    }
-
-    /**
-     * An alphabetic sort action for the tree viewer.
-     */
-    private class TreeSortAction extends Action {
-        
-        private ViewerComparator mComparator;
-
-        public TreeSortAction() {
-            super("Sorts elements alphabetically.", AS_CHECK_BOX);
-            setImageDescriptor(IconFactory.getInstance().getImageDescriptor("az_sort")); //$NON-NLS-1$
- 
-            if (mTreeViewer != null) {
-                boolean is_sorted = mTreeViewer.getComparator() != null;
-                setChecked(is_sorted);
-            }
-        }
-
-        /**
-         * Called when the button is selected. Toggles the tree viewer comparator.
-         */
-        @Override
-        public void run() {
-            if (mTreeViewer == null) {
-                notifyResult(false /*success*/);
-                return;
-            }
-
-            ViewerComparator comp = mTreeViewer.getComparator();
-            if (comp != null) {
-                // Tree is currently sorted.
-                // Save currently comparator and remove it
-                mComparator = comp;
-                mTreeViewer.setComparator(null);
-            } else {
-                // Tree is not currently sorted.
-                // Reuse or add a new comparator.
-                if (mComparator == null) {
-                    mComparator = new ViewerComparator();
-                }
-                mTreeViewer.setComparator(mComparator);
-            }
-            
-            notifyResult(true /*success*/);
-        }
-    }
-
-    /**
-     * A filter on descriptor for the tree viewer.
-     * <p/>
-     * The tree viewer will contain many of these actions and only one can be enabled at a
-     * given time. When no action is selected, everything is displayed.
-     * <p/>
-     * Since "radio"-like actions do not allow for unselecting all of them, we manually
-     * handle the exclusive radio button-like property: when an action is selected, it manually
-     * removes all other actions as needed.
-     */
-    private class DescriptorFilterAction extends Action {
-
-        private final ElementDescriptor mDescriptor;
-        private ViewerFilter mFilter;
-        
-        public DescriptorFilterAction(ElementDescriptor descriptor) {
-            super(String.format("Displays only %1$s elements.", descriptor.getUiName()),
-                    AS_CHECK_BOX);
-            
-            mDescriptor = descriptor;
-            setImageDescriptor(descriptor.getImageDescriptor());
-        }
-
-        /**
-         * Called when the button is selected.
-         * <p/>
-         * Find any existing {@link DescriptorFilter}s and remove them. Install ours.
-         */
-        @Override
-        public void run() {
-            super.run();
-            
-            if (isChecked()) {
-                if (mFilter == null) {
-                    // create filter when required
-                    mFilter = new DescriptorFilter(this);
-                }
-
-                // we add our filter first, otherwise the UI might show the full list
-                mTreeViewer.addFilter(mFilter);
-
-                // Then remove the any other filters except ours. There should be at most
-                // one other filter, since that's how the actions are made to look like
-                // exclusive radio buttons.
-                for (ViewerFilter filter : mTreeViewer.getFilters()) {
-                    if (filter instanceof DescriptorFilter && filter != mFilter) {
-                        DescriptorFilterAction action = ((DescriptorFilter) filter).getAction();
-                        action.setChecked(false);
-                        mTreeViewer.removeFilter(filter);
-                    }
-                }
-            } else if (mFilter != null){
-                mTreeViewer.removeFilter(mFilter);
-            }
-        }
-
-        /**
-         * Filters the tree viewer for the given descriptor.
-         * <p/>
-         * The filter is linked to the action so that an action can iterate through the list
-         * of filters and un-select the actions.
-         */
-        private class DescriptorFilter extends ViewerFilter {
-
-            private final DescriptorFilterAction mAction;
-
-            public DescriptorFilter(DescriptorFilterAction action) {
-                mAction = action;
-            }
-            
-            public DescriptorFilterAction getAction() {
-                return mAction;
-            }
-
-            /**
-             * Returns true if an element should be displayed, that if the element or
-             * any of its parent matches the requested descriptor.
-             */
-            @Override
-            public boolean select(Viewer viewer, Object parentElement, Object element) {
-                while (element instanceof UiElementNode) {
-                    UiElementNode uiNode = (UiElementNode)element;
-                    if (uiNode.getDescriptor() == mDescriptor) {
-                        return true;
-                    }
-                    element = uiNode.getUiParent();
-                }
-                return false;
-            }
-        }
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiSettableAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiSettableAttributeNode.java
deleted file mode 100644
index 7fe44da..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiSettableAttributeNode.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.uimodel;
-
-/**
- * This interface decoration indicates that a given UiAttributeNode can both
- * set and get its current value.
- */
-public interface IUiSettableAttributeNode {
-
-    /** Returns the current value of the node. */
-    public String getCurrentValue();
-    
-    /** Sets the current value of the node. Cannot be null (use an empty string). */
-    public void setCurrentValue(String value);
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiUpdateListener.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiUpdateListener.java
deleted file mode 100644
index 12cb31b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/IUiUpdateListener.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-
-/**
- * Listen to update notifications in UI nodes.
- */
-public interface IUiUpdateListener {
-
-    /** Update state of the UI node */
-    public enum UiUpdateState {
-        /** The node's attributes have been updated. They may or may not actually have changed. */
-        ATTR_UPDATED,
-        /** The node sub-structure (i.e. child nodes) has changed */
-        CHILDREN_CHANGED,
-        /** The XML counterpart for the UI node has just been created. */
-        CREATED,
-        /** The XML counterpart for the UI node has just been deleted.
-         *  Note that mandatory UI nodes are never actually deleted. */
-        DELETED
-    }
-
-    /**
-     * Indicates that an UiElementNode has been updated.
-     * <p/>
-     * This happens when an {@link UiElementNode} is refreshed to match the
-     * XML model. The actual UI element node may or may not have changed.
-     * 
-     * @param ui_node The {@link UiElementNode} being updated.
-     */
-    public void uiElementNodeUpdated(UiElementNode ui_node, UiUpdateState state);
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAbstractTextAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAbstractTextAttributeNode.java
deleted file mode 100644
index 4a9fbb1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAbstractTextAttributeNode.java
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-
-import org.w3c.dom.Node;
-
-/**
- * Represents an XML attribute in that can be modified using a simple text field
- * in the XML editor's user interface.
- * <p/>
- * The XML attribute has no default value. When unset, the text field is blank.
- * When updating the XML, if the field is empty, the attribute will be removed
- * from the XML element.  
- * <p/>
- * See {@link UiAttributeNode} for more information.
- */
-public abstract class UiAbstractTextAttributeNode extends UiAttributeNode
-    implements IUiSettableAttributeNode {
-
-    protected static final String DEFAULT_VALUE = "";  //$NON-NLS-1$
-
-    /** Prevent internal listener from firing when internally modifying the text */
-    private boolean mInternalTextModification;
-    /** Last value read from the XML model. Cannot be null. */
-    private String mCurrentValue = DEFAULT_VALUE;
-
-    public UiAbstractTextAttributeNode(AttributeDescriptor attributeDescriptor,
-            UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-    
-    /** Returns the current value of the node. */
-    @Override
-    public final String getCurrentValue() {
-        return mCurrentValue;
-    }
-    
-    /** Sets the current value of the node. Cannot be null (use an empty string). */
-    public final void setCurrentValue(String value) {
-        mCurrentValue = value;
-    }
-    
-    /** Returns if the attribute node is valid, and its UI has been created. */
-    public abstract boolean isValid();
-
-    /** Returns the text value present in the UI. */
-    public abstract String getTextWidgetValue();
-    
-    /** Sets the text value to be displayed in the UI. */
-    public abstract void setTextWidgetValue(String value);
-    
-
-    /**
-     * Updates the current text field's value when the XML has changed.
-     * <p/>
-     * The caller doesn't really know if attributes have changed,
-     * so it will call this to refresh the attribute anyway. The value
-     * is only set if it has changed.
-     * <p/>
-     * This also resets the "dirty" flag.
-    */
-    @Override
-    public void updateValue(Node xml_attribute_node) {
-        mCurrentValue = DEFAULT_VALUE;
-        if (xml_attribute_node != null) {
-            mCurrentValue = xml_attribute_node.getNodeValue();
-        }
-
-        if (isValid() && !getTextWidgetValue().equals(mCurrentValue)) {
-            try {
-                mInternalTextModification = true;
-                setTextWidgetValue(mCurrentValue);
-                setDirty(false);
-            } finally {
-                mInternalTextModification = false;
-            }
-        }
-    }
-
-    /* (non-java doc)
-     * Called by the user interface when the editor is saved or its state changed
-     * and the modified attributes must be committed (i.e. written) to the XML model.
-     */
-    @Override
-    public void commit() {
-        UiElementNode parent = getUiParent();
-        if (parent != null && isValid() && isDirty()) {
-            String value = getTextWidgetValue();
-            if (parent.commitAttributeToXml(this, value)) {
-                mCurrentValue = value;
-                setDirty(false);
-            }
-        }
-    }
-    
-    protected final boolean isInInternalTextModification() {
-        return mInternalTextModification;
-    }
-    
-    protected final void setInInternalTextModification(boolean internalTextModification) {
-        mInternalTextModification = internalTextModification;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAttributeNode.java
deleted file mode 100644
index 5972f22..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiAttributeNode.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.w3c.dom.Node;
-
-/**
- * Represents an XML attribute that can be modified by the XML editor's user interface.
- * <p/>
- * The characteristics of an {@link UiAttributeNode} are declared by a
- * corresponding {@link AttributeDescriptor}.
- * <p/>
- * This is an abstract class. Derived classes must implement the creation of the UI
- * and manage its synchronization with the XML.
- */
-public abstract class UiAttributeNode {
-
-    private AttributeDescriptor mDescriptor;
-    private UiElementNode mUiParent;
-    private boolean mIsDirty;
-    private boolean mHasError;
-
-    /** Creates a new {@link UiAttributeNode} linked to a specific {@link AttributeDescriptor} 
-     * and the corresponding runtine {@link UiElementNode} parent. */
-    public UiAttributeNode(AttributeDescriptor attributeDescriptor, UiElementNode uiParent) {
-        mDescriptor = attributeDescriptor;
-        mUiParent = uiParent;
-    }
-
-    /** Returns the {@link AttributeDescriptor} specific to this UI attribute node */
-    public final AttributeDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-
-    /** Returns the {@link UiElementNode} that owns this {@link UiAttributeNode} */
-    public final UiElementNode getUiParent() {
-        return mUiParent;
-    }
-    
-    /** Returns the current value of the node. */
-    public abstract String getCurrentValue();
-
-    /**
-     * @return True if the attribute has been changed since it was last loaded
-     *         from the XML model.
-     */
-    public final boolean isDirty() {
-        return mIsDirty;
-    }
-
-    /**
-     * Sets whether the attribute is dirty and also notifies the editor some part's dirty
-     * flag as changed.
-     * <p/>
-     * Subclasses should set the to true as a result of user interaction with the widgets in
-     * the section and then should set to false when the commit() method completed.
-     */
-    public void setDirty(boolean isDirty) {
-        boolean old_value = mIsDirty;
-        mIsDirty = isDirty;
-        // TODO: for unknown attributes, getParent() != null && getParent().getEditor() != null
-        if (old_value != isDirty) {
-            getUiParent().getEditor().editorDirtyStateChanged();
-        }
-    }
-    
-    /**
-     * Sets the error flag value.
-     * @param errorFlag the error flag
-     */
-    public final void setHasError(boolean errorFlag) {
-        mHasError = errorFlag;
-    }
-    
-    /**
-     * Returns whether this node has errors.
-     */
-    public final boolean hasError() {
-        return mHasError;
-    }
-    
-    /**
-     * Called once by the parent user interface to creates the necessary
-     * user interface to edit this attribute.
-     * <p/>
-     * This method can be called more than once in the life cycle of an UI node,
-     * typically when the UI is part of a master-detail tree, as pages are swapped.
-     * 
-     * @param parent The composite where to create the user interface.
-     * @param managedForm The managed form owning this part.
-     */
-    public abstract void createUiControl(Composite parent, IManagedForm managedForm);
-
-    /**
-     * Used to get a list of all possible values for this UI attribute.
-     * <p/>
-     * This is used, among other things, by the XML Content Assists to complete values
-     * for an attribute.
-     * <p/>
-     * Implementations that do not have any known values should return null.
-     * 
-     * @return A list of possible completion values or null.
-     */
-    public abstract String[] getPossibleValues();
-
-    /**
-     * Called when the XML is being loaded or has changed to
-     * update the value held by this user interface attribute node.
-     * <p/>
-     * The XML Node <em>may</em> be null, which denotes that the attribute is not
-     * specified in the XML model. In general, this means the "default" value of the
-     * attribute should be used.
-     * <p/>
-     * The caller doesn't really know if attributes have changed,
-     * so it will call this to refresh the attribute anyway. It's up to the
-     * UI implementation to minimize refreshes.
-     * 
-     * @param xml_attribute_node
-     */
-    public abstract void updateValue(Node xml_attribute_node);
-
-    /**
-     * Called by the user interface when the editor is saved or its state changed
-     * and the modified attributes must be committed (i.e. written) to the XML model.
-     * <p/>
-     * Important behaviors:
-     * <ul>
-     * <li>The caller *must* have called IStructuredModel.aboutToChangeModel before.
-     *     The implemented methods must assume it is safe to modify the XML model.
-     * <li>On success, the implementation *must* call setDirty(false).
-     * <li>On failure, the implementation can fail with an exception, which
-     *     is trapped and logged by the caller, or do nothing, whichever is more
-     *     appropriate.
-     * </ul>
-     */
-    public abstract void commit();
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiDocumentNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiDocumentNode.java
deleted file mode 100644
index 113738f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiDocumentNode.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener.UiUpdateState;
-
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-/**
- * Represents an XML document node that can be modified by the user interface in the XML editor.
- * <p/>
- * The structure of a given {@link UiDocumentNode} is declared by a corresponding
- * {@link DocumentDescriptor}.
- */
-public class UiDocumentNode extends UiElementNode {
-    
-    /**
-     * Creates a new {@link UiDocumentNode} described by a given {@link DocumentDescriptor}.
-     * 
-     * @param documentDescriptor The {@link DocumentDescriptor} for the XML node. Cannot be null.
-     */
-    public UiDocumentNode(DocumentDescriptor documentDescriptor) {
-        super(documentDescriptor);
-    }
-
-    /**
-     * Computes a short string describing the UI node suitable for tree views.
-     * Uses the element's attribute "android:name" if present, or the "android:label" one
-     * followed by the element's name.
-     * 
-     * @return A short string describing the UI node suitable for tree views.
-     */
-    @Override
-    public String getShortDescription() {
-        return "Document"; //$NON-NLS-1$
-    }
-    
-    /**
-     * Computes a "breadcrumb trail" description for this node.
-     * 
-     * @param include_root Whether to include the root (e.g. "Manifest") or not. Has no effect
-     *                     when called on the root node itself.
-     * @return The "breadcrumb trail" description for this node.
-     */
-    @Override
-    public String getBreadcrumbTrailDescription(boolean include_root) {
-        return "Document"; //$NON-NLS-1$
-    }
-    
-    /**
-     * This method throws an exception when attempted to assign a parent, since XML documents
-     * cannot have a parent. It is OK to assign null.
-     */
-    @Override
-    protected void setUiParent(UiElementNode parent) {
-        if (parent != null) {
-            // DEBUG. Change to log warning.
-            throw new UnsupportedOperationException("Documents can't have UI parents"); //$NON-NLS-1$
-        }
-        super.setUiParent(null);
-    }
-
-    /**
-     * Populate this element node with all values from the given XML node.
-     * 
-     * This fails if the given XML node has a different element name -- it won't change the
-     * type of this ui node.
-     * 
-     * This method can be both used for populating values the first time and updating values
-     * after the XML model changed.
-     * 
-     * @param xml_node The XML node to mirror
-     * @return Returns true if the XML structure has changed (nodes added, removed or replaced)
-     */
-    @Override
-    public boolean loadFromXmlNode(Node xml_node) {
-        boolean structure_changed = (getXmlDocument() != xml_node);
-        setXmlDocument((Document) xml_node);
-        structure_changed |= super.loadFromXmlNode(xml_node);
-        if (structure_changed) {
-            invokeUiUpdateListeners(UiUpdateState.CHILDREN_CHANGED);
-        }
-        return structure_changed;
-    }
-    
-    /**
-     * This method throws an exception if there is no underlying XML document.
-     * <p/>
-     * XML documents cannot be created per se -- they are a by-product of the StructuredEditor
-     * XML parser.
-     * 
-     * @return The current value of getXmlDocument().
-     */
-    @Override
-    public Node createXmlNode() {
-        if (getXmlDocument() == null) {
-            // By design, a document node cannot be created, it is owned by the XML parser.
-            // By "design" this should never happen since the XML parser always creates an XML
-            // document container, even for an empty file.
-            throw new UnsupportedOperationException("Documents cannot be created"); //$NON-NLS-1$
-        }
-        return getXmlDocument();
-    }
-
-    /**
-     * This method throws an exception and does not even try to delete the XML document.
-     * <p/>
-     * XML documents cannot be deleted per se -- they are a by-product of the StructuredEditor
-     * XML parser.
-     * 
-     * @return The removed node or null if it didn't exist in the firtst place. 
-     */
-    @Override
-    public Node deleteXmlNode() {
-        // DEBUG. Change to log warning.
-        throw new UnsupportedOperationException("Documents cannot be deleted"); //$NON-NLS-1$
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiElementNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiElementNode.java
deleted file mode 100644
index 3728886..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiElementNode.java
+++ /dev/null
@@ -1,1500 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.layout.descriptors.CustomViewDescriptorService;
-import com.android.ide.eclipse.editors.layout.descriptors.LayoutDescriptors;
-import com.android.ide.eclipse.editors.manifest.descriptors.AndroidManifestDescriptors;
-import com.android.ide.eclipse.editors.resources.descriptors.ResourcesDescriptors;
-import com.android.ide.eclipse.editors.uimodel.IUiUpdateListener.UiUpdateState;
-import com.android.ide.eclipse.editors.xml.descriptors.XmlDescriptors;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertySource;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.Text;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-/**
- * Represents an XML node that can be modified by the user interface in the XML editor.
- * <p/>
- * Each tree viewer used in the application page's parts needs to keep a model representing
- * each underlying node in the tree. This interface represents the base type for such a node.
- * <p/>
- * Each node acts as an intermediary model between the actual XML model (the real data support)
- * and the tree viewers or the corresponding page parts.
- * <p/>
- * Element nodes don't contain data per se. Their data is contained in their attributes
- * as well as their children's attributes, see {@link UiAttributeNode}.
- * <p/>
- * The structure of a given {@link UiElementNode} is declared by a corresponding
- * {@link ElementDescriptor}.
- * <p/>
- * The class implements {@link IPropertySource}, in order to fill the Eclipse property tab when
- * an element is selected. The {@link AttributeDescriptor} are used property descriptors.
- */
-public class UiElementNode implements IPropertySource {
-    
-    /** List of prefixes removed from android:id strings when creating short descriptions. */
-    private static String[] ID_PREFIXES = {
-        "@android:id/", //$NON-NLS-1$
-        "@+id/", "@id/", "@+", "@" }; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
-    
-    /** The element descriptor for the node. Always present, never null. */
-    private ElementDescriptor mDescriptor;
-    /** The parent element node in the UI model. It is null for a root element or until
-     *  the node is attached to its parent. */
-    private UiElementNode mUiParent;
-    /** The {@link AndroidEditor} handling the UI hierarchy. This is defined only for the
-     *  root node. All children have the value set to null and query their parent. */
-    private AndroidEditor mEditor;
-    /** The XML {@link Document} model that is being mirror by the UI model. This is defined
-     *  only for the root node. All children have the value set to null and query their parent. */
-    private Document mXmlDocument;
-    /** The XML {@link Node} mirror by this UI node. This can be null for mandatory UI node which
-     *  have no corresponding XML node or for new UI nodes before their XML node is set. */
-    private Node mXmlNode;
-    /** The list of all UI children nodes. Can be empty but never null. There's one UI children
-     *  node per existing XML children node. */
-    private ArrayList<UiElementNode> mUiChildren;
-    /** The list of <em>all</em> UI attributes, as declared in the {@link ElementDescriptor}.
-     *  The list is always defined and never null. Unlike the UiElementNode children list, this
-     *  is always defined, even for attributes that do not exist in the XML model -- that's because
-     *  "missing" attributes in the XML model simply mean a default value is used. Also note that
-     *  the underlying collection is a map, so order is not respected. To get the desired attribute
-     *  order, iterate through the {@link ElementDescriptor}'s attribute list. */
-    private HashMap<AttributeDescriptor, UiAttributeNode> mUiAttributes;
-    private HashSet<UiAttributeNode> mUnknownUiAttributes;
-    /** A read-only view of the UI children node collection. */
-    private List<UiElementNode> mReadOnlyUiChildren;
-    /** A read-only view of the UI attributes collection. */
-    private Collection<UiAttributeNode> mReadOnlyUiAttributes;
-    /** A map of hidden attribute descriptors. Key is the XML name. */
-    private Map<String, AttributeDescriptor> mCachedHiddenAttributes;
-    /** An optional list of {@link IUiUpdateListener}. Most element nodes will not have any
-     *  listeners attached, so the list is only created on demand and can be null. */
-    private ArrayList<IUiUpdateListener> mUiUpdateListeners;
-    /** Error Flag */
-    private boolean mHasError;
-    /** Temporary data used by the editors. This data is not sync'ed with the XML */
-    private Object mEditData;
-    
-    /**
-     * Creates a new {@link UiElementNode} described by a given {@link ElementDescriptor}.
-     * 
-     * @param elementDescriptor The {@link ElementDescriptor} for the XML node. Cannot be null.
-     */
-    public UiElementNode(ElementDescriptor elementDescriptor) {
-        mDescriptor = elementDescriptor;
-        clearContent();
-    }
-    
-    /**
-     * Clears the {@link UiElementNode} by resetting the children list and
-     * the {@link UiAttributeNode}s list.
-     * Also resets the attached XML node, document, editor if any.
-     * <p/>
-     * The parent {@link UiElementNode} node is not reset so that it's position
-     * in the hierarchy be left intact, if any.
-     */
-    /* package */ void clearContent() {
-        mXmlNode = null;
-        mXmlDocument = null;
-        mEditor = null;
-        clearAttributes();
-        mReadOnlyUiChildren = null;
-        if (mUiChildren == null) {
-            mUiChildren = new ArrayList<UiElementNode>();
-        } else {
-            // We can't remove mandatory nodes, we just clear them.
-            for (int i = mUiChildren.size() - 1; i >= 0; --i) {
-                removeUiChildAtIndex(i);
-            }
-        }
-    }
-
-    /**
-     * Clears the internal list of attributes, the read-only cached version of it
-     * and the read-only cached hidden attribute list.
-     */
-    private void clearAttributes() {
-        mUiAttributes = null;
-        mReadOnlyUiAttributes = null;
-        mCachedHiddenAttributes = null;
-        mUnknownUiAttributes = new HashSet<UiAttributeNode>();
-    }
-
-    /**
-     * Gets or creates the internal UiAttributes list.
-     * <p/>
-     * When the descriptor derives from ViewElementDescriptor, this list depends on the
-     * current UiParent node.
-     *  
-     * @return A new set of {@link UiAttributeNode} that matches the expected
-     *         attributes for this node.
-     */
-    private HashMap<AttributeDescriptor, UiAttributeNode> getInternalUiAttributes() {
-        if (mUiAttributes == null) {
-            AttributeDescriptor[] attr_list = getAttributeDescriptors();
-            mUiAttributes = new HashMap<AttributeDescriptor, UiAttributeNode>(attr_list.length);
-            for (AttributeDescriptor desc : attr_list) {
-                UiAttributeNode ui_node = desc.createUiNode(this);
-                if (ui_node != null) {  // Some AttributeDescriptors do not have UI associated
-                    mUiAttributes.put(desc, ui_node);
-                }
-            }
-        }
-        return mUiAttributes;
-    }
-
-    /**
-     * Computes a short string describing the UI node suitable for tree views.
-     * Uses the element's attribute "android:name" if present, or the "android:label" one
-     * followed by the element's name.
-     * 
-     * @return A short string describing the UI node suitable for tree views.
-     */
-    public String getShortDescription() {
-        if (mXmlNode != null && mXmlNode instanceof Element && mXmlNode.hasAttributes()) {
-
-            // Application and Manifest nodes have a special treatment: they are unique nodes
-            // so we don't bother trying to differentiate their strings and we fall back to
-            // just using the UI name below.
-            Element elem = (Element) mXmlNode;
-            
-            String attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                              AndroidManifestDescriptors.ANDROID_NAME_ATTR);
-            if (attr == null || attr.length() == 0) {
-                attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                           AndroidManifestDescriptors.ANDROID_LABEL_ATTR);
-            }
-            if (attr == null || attr.length() == 0) {
-                attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                           XmlDescriptors.PREF_KEY_ATTR);
-            }
-            if (attr == null || attr.length() == 0) {
-                attr = elem.getAttribute(ResourcesDescriptors.NAME_ATTR);
-            }
-            if (attr == null || attr.length() == 0) {
-                attr = elem.getAttributeNS(SdkConstants.NS_RESOURCES,
-                                           LayoutDescriptors.ID_ATTR);
-
-                if (attr != null && attr.length() > 0) {
-                    for (String prefix : ID_PREFIXES) {
-                        if (attr.startsWith(prefix)) {
-                            attr = attr.substring(prefix.length());
-                            break;
-                        }
-                    }
-                }
-            }
-            if (attr != null && attr.length() > 0) {
-                return String.format("%1$s (%2$s)", attr, mDescriptor.getUiName());
-            }
-        }
-
-        return String.format("%1$s", mDescriptor.getUiName());
-    }
-    
-    /**
-     * Computes a "breadcrumb trail" description for this node.
-     * It will look something like "Manifest > Application > .myactivity (Activity) > Intent-Filter"
-     * 
-     * @param include_root Whether to include the root (e.g. "Manifest") or not. Has no effect
-     *                     when called on the root node itself.
-     * @return The "breadcrumb trail" description for this node.
-     */
-    public String getBreadcrumbTrailDescription(boolean include_root) {
-        StringBuilder sb = new StringBuilder(getShortDescription());
-
-        for (UiElementNode ui_node = getUiParent();
-                ui_node != null;
-                ui_node = ui_node.getUiParent()) {
-            if (!include_root && ui_node.getUiParent() == null) {
-                break;
-            }
-            sb.insert(0, String.format("%1$s > ", ui_node.getShortDescription())); //$NON-NLS-1$
-        }
-        
-        return sb.toString();
-    }
-    
-    /**
-     * Sets the XML {@link Document}.
-     * <p/>
-     * The XML {@link Document} is initially null. The XML {@link Document} must be set only on the
-     * UI root element node (this method takes care of that.) 
-     */
-    public void setXmlDocument(Document xml_doc) {
-        if (mUiParent == null) {
-            mXmlDocument = xml_doc;
-        } else {
-            mUiParent.setXmlDocument(xml_doc);
-        }
-    }
-
-    /**
-     * Returns the XML {@link Document}.
-     * <p/>
-     * The value is initially null until the UI node is attached to its UI parent -- the value
-     * of the document is then propagated.
-     * 
-     * @return the XML {@link Document} or the parent's XML {@link Document} or null.
-     */
-    public Document getXmlDocument() {
-        if (mXmlDocument != null) {
-            return mXmlDocument;
-        } else if (mUiParent != null) {
-            return mUiParent.getXmlDocument();
-        }
-        return null;
-    }
-
-    /**
-     * Returns the XML node associated with this UI node.
-     * <p/>
-     * Some {@link ElementDescriptor} are declared as being "mandatory". This means the
-     * corresponding UI node will exist even if there is no corresponding XML node. Such structure
-     * is created and enforced by the parent of the tree, not the element themselves. However
-     * such nodes will likely not have an XML node associated, so getXmlNode() can return null. 
-     *
-     * @return The associated XML node. Can be null for mandatory nodes.
-     */
-    public Node getXmlNode() {
-        return mXmlNode;
-    }
-
-    /**
-     * Returns the {@link ElementDescriptor} for this node. This is never null.
-     * <p/>
-     * Do not use this to call getDescriptor().getAttributes(), instead call
-     * getAttributeDescriptors() which can be overriden by derived classes.
-     */
-    public ElementDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-
-    /**
-     * Returns the {@link AttributeDescriptor} array for the descriptor of this node.
-     * <p/>
-     * Use this instead of getDescriptor().getAttributes() -- derived classes can override
-     * this to manipulate the attribute descriptor list depending on the current UI node. 
-     */
-    public AttributeDescriptor[] getAttributeDescriptors() {
-        return mDescriptor.getAttributes();
-    }
-
-    /**
-     * Returns the hidden {@link AttributeDescriptor} array for the descriptor of this node.
-     * This is a subset of the getAttributeDescriptors() list.
-     * <p/>
-     * Use this instead of getDescriptor().getHiddenAttributes() -- potentially derived classes
-     * could override this to manipulate the attribute descriptor list depending on the current
-     * UI node. There's no need for it right now so keep it private.
-     */
-    private Map<String, AttributeDescriptor> getHiddenAttributeDescriptors() {
-        if (mCachedHiddenAttributes == null) {
-            mCachedHiddenAttributes = new HashMap<String, AttributeDescriptor>();
-            for (AttributeDescriptor attr_desc : getAttributeDescriptors()) {
-                if (attr_desc instanceof XmlnsAttributeDescriptor) {
-                    mCachedHiddenAttributes.put(
-                            ((XmlnsAttributeDescriptor) attr_desc).getXmlNsName(), 
-                            attr_desc);
-                }
-            }
-        }
-        return mCachedHiddenAttributes;
-    }
-
-    /**
-     * Sets the parent of this UiElementNode.
-     * <p/>
-     * The root node has no parent.
-     */
-    protected void setUiParent(UiElementNode parent) {
-        mUiParent = parent;
-        // Invalidate the internal UiAttributes list, as it may depend on the actual UiParent.
-        clearAttributes();
-    }
-
-    /**
-     * @return The parent {@link UiElementNode} or null if this is the root node.
-     */
-    public UiElementNode getUiParent() {
-        return mUiParent;
-    }
-    
-    /**
-     * Returns The root {@link UiElementNode}.
-     */
-    public UiElementNode getUiRoot() {
-        UiElementNode root = this;
-        while (root.mUiParent != null) {
-            root = root.mUiParent;
-        }
-        
-        return root;
-    }
-
-    /**
-     * Returns the previous UI sibling of this UI node.
-     * If the node does not have a previous sibling, returns null. 
-     */
-    public UiElementNode getUiPreviousSibling() {
-        if (mUiParent != null) {
-            List<UiElementNode> childlist = mUiParent.getUiChildren();
-            if (childlist != null && childlist.size() > 1 && childlist.get(0) != this) {
-                int index = childlist.indexOf(this);
-                return index > 0 ? childlist.get(index - 1) : null;
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Returns the next UI sibling of this UI node.
-     * If the node does not have a next sibling, returns null. 
-     */
-    public UiElementNode getUiNextSibling() {
-        if (mUiParent != null) {
-            List<UiElementNode> childlist = mUiParent.getUiChildren();
-            if (childlist != null) {
-                int size = childlist.size();
-                if (size > 1 && childlist.get(size - 1) != this) {
-                    int index = childlist.indexOf(this);
-                    return index >= 0 && index < size - 1 ? childlist.get(index + 1) : null;
-                }
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Sets the {@link AndroidEditor} handling this {@link UiElementNode} hierarchy.
-     * <p/>
-     * The editor must always be set on the root node. This method takes care of that.
-     */
-    public void setEditor(AndroidEditor editor) {
-        if (mUiParent == null) {
-            mEditor = editor;
-        } else {
-            mUiParent.setEditor(editor);
-        }
-    }
-
-    /**
-     * Returns the {@link AndroidEditor} that embeds this {@link UiElementNode}.
-     * <p/>
-     * The value is initially null until the node is attached to its parent -- the value
-     * of the root node is then propagated.
-     * 
-     * @return The embedding {@link AndroidEditor} or null.
-     */
-    public AndroidEditor getEditor() {
-        return mUiParent == null ? mEditor : mUiParent.getEditor();
-    }
-    
-    /**
-     * Returns the Android target data for the file being edited.
-     */
-    public AndroidTargetData getAndroidTarget() {
-        return getEditor().getTargetData();
-    }
-
-    /**
-     * @return A read-only version of the children collection.
-     */
-    public List<UiElementNode> getUiChildren() {
-        if (mReadOnlyUiChildren == null) {
-            mReadOnlyUiChildren = Collections.unmodifiableList(mUiChildren);
-        }
-        return mReadOnlyUiChildren;
-    }
-
-    /**
-     * @return A read-only version of the attributes collection.
-     */
-    public Collection<UiAttributeNode> getUiAttributes() {
-        if (mReadOnlyUiAttributes == null) {
-            mReadOnlyUiAttributes = Collections.unmodifiableCollection(
-                    getInternalUiAttributes().values());
-        }
-        return mReadOnlyUiAttributes;
-    }
-
-    /**
-     * @return A read-only version of the unknown attributes collection.
-     */
-    public Collection<UiAttributeNode> getUnknownUiAttributes() {
-        return Collections.unmodifiableCollection(mUnknownUiAttributes);
-    }
-    
-    /**
-     * Sets the error flag value.
-     * @param errorFlag the error flag
-     */
-    public final void setHasError(boolean errorFlag) {
-        mHasError = errorFlag;
-    }
-    
-    /**
-     * Returns whether this node, its attributes, or one of the children nodes (and attributes)
-     * has errors.
-     */
-    public final boolean hasError() {
-        if (mHasError) {
-            return true;
-        }
-
-        // get the error value from the attributes.
-        Collection<UiAttributeNode> attributes = getInternalUiAttributes().values();
-        for (UiAttributeNode attribute : attributes) {
-            if (attribute.hasError()) {
-                return true;
-            }
-        }
-
-        // and now from the children.
-        for (UiElementNode child : mUiChildren) {
-            if (child.hasError()) {
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Adds a new {@link IUiUpdateListener} to the internal update listener list.
-     */
-    public void addUpdateListener(IUiUpdateListener listener) {
-       if (mUiUpdateListeners == null) {
-           mUiUpdateListeners = new ArrayList<IUiUpdateListener>();
-       }
-       if (!mUiUpdateListeners.contains(listener)) {
-           mUiUpdateListeners.add(listener);
-       }
-    }
-
-    /**
-     * Removes an existing {@link IUiUpdateListener} from the internal update listener list.
-     * Does nothing if the list is empty or the listener is not registered.
-     */
-    public void removeUpdateListener(IUiUpdateListener listener) {
-       if (mUiUpdateListeners != null) {
-           mUiUpdateListeners.remove(listener);
-       }
-    }
-
-    /**
-     * Finds a child node relative to this node using a path-like expression.
-     * F.ex. "node1/node2" would find a child "node1" that contains a child "node2" and
-     * returns the latter. If there are multiple nodes with the same name at the same
-     * level, always uses the first one found.
-     * 
-     * @param path The path like expression to select a child node.
-     * @return The ui node found or null.
-     */
-    public UiElementNode findUiChildNode(String path) {
-        String[] items = path.split("/");  //$NON-NLS-1$
-        UiElementNode ui_node = this;
-        for (String item : items) {
-            boolean next_segment = false;
-            for (UiElementNode c : ui_node.mUiChildren) {
-                if (c.getDescriptor().getXmlName().equals(item)) {
-                    ui_node = c;
-                    next_segment = true;
-                    break;
-                }
-            }
-            if (!next_segment) {
-                return null;
-            }
-        }
-        return ui_node;
-    }
-
-    /**
-     * Finds an {@link UiElementNode} which contains the give XML {@link Node}.
-     * Looks recursively in all children UI nodes.
-     * 
-     * @param xmlNode The XML node to look for.
-     * @return The {@link UiElementNode} that contains xmlNode or null if not found,
-     */
-    public UiElementNode findXmlNode(Node xmlNode) {
-        if (xmlNode == null) {
-            return null;
-        }
-        if (getXmlNode() == xmlNode) {
-            return this;
-        }
-        
-        for (UiElementNode uiChild : mUiChildren) {
-            UiElementNode found = uiChild.findXmlNode(xmlNode);
-            if (found != null) {
-                return found;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the {@link UiAttributeNode} matching this attribute descriptor or
-     * null if not found.
-     * 
-     * @param attr_desc The {@link AttributeDescriptor} to match.
-     * @return the {@link UiAttributeNode} matching this attribute descriptor or null
-     *         if not found.
-     */
-    public UiAttributeNode findUiAttribute(AttributeDescriptor attr_desc) {
-        return getInternalUiAttributes().get(attr_desc);
-    }
-
-    /**
-     * Populate this element node with all values from the given XML node.
-     * 
-     * This fails if the given XML node has a different element name -- it won't change the
-     * type of this ui node.
-     * 
-     * This method can be both used for populating values the first time and updating values
-     * after the XML model changed.
-     * 
-     * @param xml_node The XML node to mirror
-     * @return Returns true if the XML structure has changed (nodes added, removed or replaced)
-     */
-    public boolean loadFromXmlNode(Node xml_node) {
-        boolean structure_changed = (mXmlNode != xml_node);
-        mXmlNode = xml_node;
-        if (xml_node != null) {
-            updateAttributeList(xml_node);
-            structure_changed |= updateElementList(xml_node);
-            invokeUiUpdateListeners(structure_changed ? UiUpdateState.CHILDREN_CHANGED
-                                                      : UiUpdateState.ATTR_UPDATED);
-        }
-        return structure_changed;
-    }
-
-    /**
-     * Clears the UI node and reload it from the given XML node.
-     * <p/>
-     * This works by clearing all references to any previous XML or UI nodes and
-     * then reloads the XML document from scratch. The editor reference is kept.
-     * <p/>
-     * This is used in the special case where the ElementDescriptor structure has changed.
-     * Rather than try to diff inflated UI nodes (as loadFromXmlNode does), we don't bother
-     * and reload everything. This is not subtle and should be used very rarely.
-     * 
-     * @param xml_node The XML node or document to reload. Can be null.
-     */
-    public void reloadFromXmlNode(Node xml_node) {
-        // The editor needs to be preserved, it is not affected by an XML change.
-        AndroidEditor editor = getEditor();
-        clearContent();
-        setEditor(editor);
-        if (xml_node != null) {
-            setXmlDocument(xml_node.getOwnerDocument());
-        }
-        // This will reload all the XML and recreate the UI structure from scratch.
-        loadFromXmlNode(xml_node);
-    }
-
-    /**
-     * Called by attributes when they want to commit their value
-     * to an XML node.
-     * <p/>
-     * For mandatory nodes, this makes sure the underlying XML element node
-     * exists in the model. If not, it is created and assigned as the underlying
-     * XML node.
-     * </br>
-     * For non-mandatory nodes, simply return the underlying XML node, which
-     * must always exists.
-     * 
-     * @return The XML node matching this {@link UiElementNode} or null.
-     */
-    public Node prepareCommit() {
-        if (getDescriptor().isMandatory()) {
-            createXmlNode();
-            // The new XML node has been created.
-            // We don't need to refresh using loadFromXmlNode() since there are
-            // no attributes or elements that need to be loading into this node.
-        }
-        return getXmlNode();
-    }
-
-    /**
-     * Commits the attributes (all internal, inherited from UI parent & unknown attributes).
-     * This is called by the UI when the embedding part needs to be committed.
-     */
-    public void commit() {
-        for (UiAttributeNode ui_attr : getInternalUiAttributes().values()) {
-            ui_attr.commit();
-        }
-        
-        for (UiAttributeNode ui_attr : mUnknownUiAttributes) {
-            ui_attr.commit();
-        }
-    }
-
-    /**
-     * Returns true if the part has been modified with respect to the data
-     * loaded from the model.
-     */
-    public boolean isDirty() {
-        for (UiAttributeNode ui_attr : getInternalUiAttributes().values()) {
-            if (ui_attr.isDirty()) {
-                return true;
-            }
-        }
-        
-        for (UiAttributeNode ui_attr : mUnknownUiAttributes) {
-            if (ui_attr.isDirty()) {
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Creates the underlying XML element node for this UI node if it doesn't already
-     * exists.
-     * 
-     * @return The new value of getXmlNode() (can be null if creation failed)
-     */
-    public Node createXmlNode() {
-        if (mXmlNode != null) {
-            return null;
-        }
-        Node parentXmlNode = null;
-        if (mUiParent != null) {
-            parentXmlNode = mUiParent.prepareCommit();
-            if (parentXmlNode == null) {
-                // The parent failed to create its own backing XML node. Abort.
-                // No need to throw an exception, the parent will most likely
-                // have done so itself.
-                return null;
-            }
-        }
-
-        String element_name = getDescriptor().getXmlName();
-        Document doc = getXmlDocument();
-
-        // We *must* have a root node. If not, we need to abort.
-        if (doc == null) {
-            throw new RuntimeException(
-                    String.format("Missing XML document for %1$s XML node.", element_name));
-        }
-
-        // If we get here and parent_xml_node is null, the node is to be created
-        // as the root node of the document (which can't be null, cf check above).
-        if (parentXmlNode == null) {
-            parentXmlNode = doc;
-        }
-
-        mXmlNode = doc.createElement(element_name);
-        
-        Node xmlNextSibling = null;
-
-        UiElementNode uiNextSibling = getUiNextSibling();
-        if (uiNextSibling != null) {
-            xmlNextSibling = uiNextSibling.getXmlNode();
-        }
-
-        parentXmlNode.insertBefore(mXmlNode, xmlNextSibling);
-
-        // Insert a separator after the tag, to make it easier to read
-        Text sep = doc.createTextNode("\n");
-        parentXmlNode.appendChild(sep);
-
-        // Set all initial attributes in the XML node if they are not empty. 
-        // Iterate on the descriptor list to get the desired order and then use the
-        // internal values, if any.
-        for (AttributeDescriptor attr_desc : getAttributeDescriptors()) {
-            if (attr_desc instanceof XmlnsAttributeDescriptor) {
-                XmlnsAttributeDescriptor desc = (XmlnsAttributeDescriptor) attr_desc;
-                Attr attr = doc.createAttributeNS(XmlnsAttributeDescriptor.XMLNS_URI,
-                        desc.getXmlNsName());
-                attr.setValue(desc.getValue());
-                attr.setPrefix(desc.getXmlNsPrefix());
-                mXmlNode.getAttributes().setNamedItemNS(attr);
-            } else {
-                UiAttributeNode ui_attr = getInternalUiAttributes().get(attr_desc);
-                commitAttributeToXml(ui_attr, ui_attr.getCurrentValue());
-            }
-        }
-        
-        invokeUiUpdateListeners(UiUpdateState.CREATED);
-        return mXmlNode;
-    }
-
-    /**
-     * Removes the XML node corresponding to this UI node if it exists
-     * and also removes all mirrored information in this UI node (i.e. children, attributes)
-     * 
-     * @return The removed node or null if it didn't exist in the firtst place. 
-     */
-    public Node deleteXmlNode() {
-        if (mXmlNode == null) {
-            return null;
-        }
-
-        // First clear the internals of the node and *then* actually deletes the XML
-        // node (because doing so will generate an update even and this node may be
-        // revisited via loadFromXmlNode).
-        Node old_xml_node = mXmlNode;
-        clearContent();
-        
-        Node xml_parent = old_xml_node.getParentNode();
-        if (xml_parent == null) {
-            xml_parent = getXmlDocument();
-        }
-        old_xml_node = xml_parent.removeChild(old_xml_node);
-
-        invokeUiUpdateListeners(UiUpdateState.DELETED);
-        return old_xml_node;
-    }
-
-    /**
-     * Updates the element list for this UiElementNode.
-     * At the end, the list of children UiElementNode here will match the one from the
-     * provided XML {@link Node}:
-     * <ul>
-     * <li> Walk both the current ui children list and the xml children list at the same time.
-     * <li> If we have a new xml child but already reached the end of the ui child list, add the
-     *      new xml node.
-     * <li> Otherwise, check if the xml node is referenced later in the ui child list and if so,
-     *      move it here. It means the XML child list has been reordered.
-     * <li> Otherwise, this is a new XML node that we add in the middle of the ui child list.
-     * <li> At the end, we may have finished walking the xml child list but still have remaining
-     *      ui children, simply delete them as they matching trailing xml nodes that have been
-     *      removed unless they are mandatory ui nodes.
-     * </ul>
-     * Note that only the first case is used when populating the ui list the first time.
-     * 
-     * @param xml_node The XML node to mirror
-     * @return True when the XML structure has changed.
-     */
-    protected boolean updateElementList(Node xml_node) {
-        boolean structure_changed = false;
-        int ui_index = 0;
-        Node xml_child = xml_node.getFirstChild();
-        while (xml_child != null) {
-            if (xml_child.getNodeType() == Node.ELEMENT_NODE) {
-                String element_name = xml_child.getNodeName();
-                UiElementNode ui_node = null;
-                if (mUiChildren.size() <= ui_index) {
-                    // A new node is being added at the end of the list
-                    ElementDescriptor desc = mDescriptor.findChildrenDescriptor(element_name,
-                            false /* recursive */);
-                    if (desc == null) {
-                        // Unknown node. Create a temporary descriptor for it.
-                        // most important we want to auto-add unknown attributes to it.
-                        AndroidEditor editor = getEditor();
-                        IEditorInput editorInput = editor.getEditorInput();
-                        if (editorInput instanceof IFileEditorInput) {
-                            IFileEditorInput fileInput = (IFileEditorInput)editorInput;
-                            desc = CustomViewDescriptorService.getInstance().getDescriptor(
-                                    fileInput.getFile().getProject(), element_name);
-                            if (desc == null) {
-                                desc = new ElementDescriptor(element_name);
-                            }
-                        } else {
-                            desc = new ElementDescriptor(element_name);
-                            // TODO associate a new "?" icon to this descriptor.
-                        }
-                    }
-                    structure_changed = true;
-                    ui_node = appendNewUiChild(desc);
-                    ui_index++;
-                } else {
-                    // A new node is being inserted or moved.
-                    // Note: mandatory nodes can be created without an XML node in which case
-                    // getXmlNode() is null.
-                    UiElementNode ui_child;
-                    int n = mUiChildren.size();
-                    for (int j = ui_index; j < n; j++) {
-                        ui_child = mUiChildren.get(j);
-                        if (ui_child.getXmlNode() != null && ui_child.getXmlNode() == xml_child) {
-                            if (j > ui_index) {
-                                // Found the same XML node at some later index, now move it here.
-                                mUiChildren.remove(j);
-                                mUiChildren.add(ui_index, ui_child);
-                                structure_changed = true;
-                            }
-                            ui_node = ui_child;
-                            ui_index++;
-                            break;
-                        }
-                    }
-
-                    if (ui_node == null) {
-                        // Look for an unused mandatory node with no XML node attached
-                        // referencing the same XML element name
-                        for (int j = ui_index; j < n; j++) {
-                            ui_child = mUiChildren.get(j);
-                            if (ui_child.getXmlNode() == null &&
-                                    ui_child.getDescriptor().isMandatory() &&
-                                    ui_child.getDescriptor().getXmlName().equals(element_name)) {
-                                if (j > ui_index) {
-                                    // Found it, now move it here
-                                    mUiChildren.remove(j);
-                                    mUiChildren.add(ui_index, ui_child);
-                                }
-                                // assign the XML node to this empty mandatory element.
-                                ui_child.mXmlNode = xml_child;
-                                structure_changed = true;
-                                ui_node = ui_child;
-                                ui_index++;
-                            }
-                        }
-                    }
-
-                    if (ui_node == null) {
-                        // Inserting new node
-                        ElementDescriptor desc = mDescriptor.findChildrenDescriptor(element_name,
-                                false /* recursive */);
-                        if (desc == null) {
-                            // Unknown element. Simply ignore it.
-                            AdtPlugin.log(IStatus.WARNING,
-                                    "AndroidManifest: Ignoring unknown '%s' XML element", //$NON-NLS-1$
-                                    element_name);
-                        } else {
-                            structure_changed = true;
-                            ui_node = insertNewUiChild(ui_index, desc);
-                            ui_index++;
-                        }
-                    }
-                }
-                if (ui_node != null) {
-                    // If we touched an UI Node, even an existing one, refresh its content.
-                    // For new nodes, this will populate them recursively.
-                    structure_changed |= ui_node.loadFromXmlNode(xml_child);
-                }
-            }
-            xml_child = xml_child.getNextSibling();
-        }
-
-        // There might be extra UI nodes at the end if the XML node list got shorter.
-        for (int index = mUiChildren.size() - 1; index >= ui_index; --index) {
-             structure_changed |= removeUiChildAtIndex(index);
-        }
-
-        return structure_changed;
-    }
-
-    /**
-     * Internal helper to remove an UI child node given by its index in the
-     * internal child list.
-     * 
-     * Also invokes the update listener on the node to be deleted.
-     * 
-     * @param ui_index The index of the UI child to remove, range 0 .. mUiChildren.size()-1
-     * @return True if the structure has changed
-     * @throws IndexOutOfBoundsException if index is out of mUiChildren's bounds. Of course you
-     *         know that could never happen unless the computer is on fire or something.
-     */
-    private boolean removeUiChildAtIndex(int ui_index) {
-        UiElementNode ui_node = mUiChildren.get(ui_index);
-        invokeUiUpdateListeners(UiUpdateState.DELETED);
-        if (ui_node.getDescriptor().isMandatory()) {
-            // We can't remove a mandatory node, we just clear its content.
-
-            // A mandatory node with no XML means it doesn't really exist, so it can't be
-            // deleted.
-            boolean xml_exists = (ui_node.getXmlNode() != null); 
-
-            ui_node.clearContent();
-            return xml_exists;
-        } else {
-            mUiChildren.remove(ui_index);
-            return true;
-        }
-    }
-
-    /**
-     * Creates a new {@link UiElementNode} from the given {@link ElementDescriptor}
-     * and appends it to the end of the element children list.
-     *  
-     * @param descriptor The {@link ElementDescriptor} that knows how to create the UI node.
-     * @return The new UI node that has been appended
-     */
-    public UiElementNode appendNewUiChild(ElementDescriptor descriptor) {
-        UiElementNode ui_node;
-        ui_node = descriptor.createUiNode();
-        mUiChildren.add(ui_node);
-        ui_node.setUiParent(this);
-        ui_node.invokeUiUpdateListeners(UiUpdateState.CREATED);
-        return ui_node;
-    }
-
-    /**
-     * Creates a new {@link UiElementNode} from the given {@link ElementDescriptor}
-     * and inserts it in the element children list at the specified position.
-     *  
-     * @param index The position where to insert in the element children list.
-     * @param descriptor The {@link ElementDescriptor} that knows how to create the UI node.
-     * @return The new UI node.
-     */
-    public UiElementNode insertNewUiChild(int index, ElementDescriptor descriptor) {
-        UiElementNode ui_node;
-        ui_node = descriptor.createUiNode();
-        mUiChildren.add(index, ui_node);
-        ui_node.setUiParent(this);
-        ui_node.invokeUiUpdateListeners(UiUpdateState.CREATED);
-        return ui_node;
-    }
-
-    /**
-     * Updates the {@link UiAttributeNode} list for this {@link UiElementNode}.
-     * <p/>
-     * For a given {@link UiElementNode}, the attribute list always exists in
-     * full and is totally independent of whether the XML model actually
-     * has the corresponding attributes.
-     * <p/>
-     * For each attribute declared in this {@link UiElementNode}, get
-     * the corresponding XML attribute. It may not exist, in which case the
-     * value will be null. We don't really know if a value has changed, so
-     * the updateValue() is called on the UI sattribute in all cases. 
-     * 
-     * @param xmlNode The XML node to mirror
-     */
-    protected void updateAttributeList(Node xmlNode) {
-        NamedNodeMap xmlAttrMap = xmlNode.getAttributes();
-        HashSet<Node> visited = new HashSet<Node>();
-        
-        // For all known (i.e. expected) UI attributes, find an existing XML attribute of
-        // same (uri, local name) and update the internal Ui attribute value.
-        for (UiAttributeNode uiAttr : getInternalUiAttributes().values()) {
-            AttributeDescriptor desc = uiAttr.getDescriptor();
-            if (!(desc instanceof SeparatorAttributeDescriptor)) {
-                Node xmlAttr = xmlAttrMap == null ? null :
-                    xmlAttrMap.getNamedItemNS(desc.getNamespaceUri(), desc.getXmlLocalName());
-                uiAttr.updateValue(xmlAttr);
-                visited.add(xmlAttr);
-            }
-        }
-
-        // Clone the current list of unknown attributes. We'll then remove from this list when
-        // we still attributes which are still unknown. What will be left are the old unknown
-        // attributes that have been deleted in the current XML attribute list.
-        @SuppressWarnings("unchecked") //$NON-NLS-1$
-        HashSet<UiAttributeNode> deleted = (HashSet<UiAttributeNode>) mUnknownUiAttributes.clone();
-
-        // We need to ignore hidden attributes.
-        Map<String, AttributeDescriptor> hiddenAttrDesc = getHiddenAttributeDescriptors();
-        
-        // Traverse the actual XML attribute list to find unknown attributes
-        if (xmlAttrMap != null) {
-            for (int i = 0; i < xmlAttrMap.getLength(); i++) {
-                Node xmlAttr = xmlAttrMap.item(i);
-                // Ignore attributes which have actual descriptors 
-                if (visited.contains(xmlAttr)) {
-                    continue;
-                }
-                
-                String xmlFullName = xmlAttr.getNodeName();
-
-                // Ignore attributes which are hidden (based on the prefix:localName key)
-                if (hiddenAttrDesc.containsKey(xmlFullName)) {
-                    continue;
-                }
-                
-                String xmlAttrLocalName = xmlAttr.getLocalName();
-                String xmlNsUri = xmlAttr.getNamespaceURI();
-
-                UiAttributeNode uiAttr = null;
-                for (UiAttributeNode a : mUnknownUiAttributes) {
-                    String aLocalName = a.getDescriptor().getXmlLocalName();
-                    String aNsUri = a.getDescriptor().getNamespaceUri();
-                    if (aLocalName.equals(xmlAttrLocalName) &&
-                            (aNsUri == xmlNsUri || (aNsUri != null && aNsUri.equals(xmlNsUri)))) {
-                        // This attribute is still present in the unknown list
-                        uiAttr = a;
-                        // It has not been deleted
-                        deleted.remove(a);
-                        break;
-                    }
-                }
-                if (uiAttr == null) {
-                    // Create a new unknown attribute
-                    TextAttributeDescriptor desc = new TextAttributeDescriptor(
-                            xmlAttrLocalName, // xml name
-                            xmlFullName, // ui name
-                            xmlNsUri, // NS uri
-                            "Unknown XML attribute"); // tooltip, translatable
-                    uiAttr = desc.createUiNode(this);
-                    mUnknownUiAttributes.add(uiAttr);
-                }
-                
-                uiAttr.updateValue(xmlAttr);
-            }
-            
-            // Remove from the internal list unknown attributes that have been deleted from the xml
-            for (UiAttributeNode a : deleted) {
-                mUnknownUiAttributes.remove(a);
-            }
-        }
-    }
-
-    /**
-     * Invoke all registered {@link IUiUpdateListener} listening on this UI updates for this node.
-     */
-    protected void invokeUiUpdateListeners(UiUpdateState state) {
-        if (mUiUpdateListeners != null) {
-            for (IUiUpdateListener listener : mUiUpdateListeners) {
-                try {
-                    listener.uiElementNodeUpdated(this, state);
-                } catch (Exception e) {
-                    // prevent a crashing listener from crashing the whole invocation chain
-                    AdtPlugin.log(e, "UIElement Listener failed: %s, state=%s",  //$NON-NLS-1$
-                            getBreadcrumbTrailDescription(true),
-                            state.toString());
-                }
-            }
-        }
-    }
-
-    // --- for derived implementations only ---
-
-    // TODO doc
-    protected void setXmlNode(Node xml_node) {
-        mXmlNode = xml_node;
-    }
-    
-    /**
-     * Sets the temporary data used by the editors.
-     * @param data the data.
-     */
-    public void setEditData(Object data) {
-        mEditData = data;
-    }
-    
-    /**
-     * Returns the temporary data used by the editors for this object.
-     * @return the data, or <code>null</code> if none has been set.
-     */
-    public Object getEditData() {
-        return mEditData;
-    }
-    
-    public void refreshUi() {
-        invokeUiUpdateListeners(UiUpdateState.ATTR_UPDATED);
-    }
-    
-
-    // ------------- Helpers
-    
-    /**
-     * Helper method to commit a single attribute value to XML.
-     * <p/>
-     * This method updates the XML regardless of the current XML value.
-     * Callers should check first if an update is needed.
-     * If the new value is empty, the XML attribute will be actually removed.
-     * <p/>
-     * Note that the caller MUST ensure that modifying the underlying XML model is
-     * safe and must take care of marking the model as dirty if necessary.
-     * 
-     * @see AndroidEditor#editXmlModel(Runnable)
-     * 
-     * @param uiAttr The attribute node to commit. Must be a child of this UiElementNode.
-     * @param newValue The new value to set.
-     * @return True if the XML attribute was modified or removed, false if nothing changed.
-     */
-    public boolean commitAttributeToXml(UiAttributeNode uiAttr, String newValue) {
-        // Get (or create) the underlying XML element node that contains the attributes.
-        Node element = prepareCommit();
-        if (element != null && uiAttr != null) {
-            String attrLocalName = uiAttr.getDescriptor().getXmlLocalName();
-            String attrNsUri = uiAttr.getDescriptor().getNamespaceUri();
-            
-            NamedNodeMap attrMap = element.getAttributes();
-            if (newValue == null || newValue.length() == 0) {
-                // Remove attribute if it's empty
-                if (attrMap.getNamedItemNS(attrNsUri, attrLocalName) != null) {
-                    attrMap.removeNamedItemNS(attrNsUri, attrLocalName);
-                    return true;
-                }
-            } else {
-                // Add or replace an attribute 
-                Document doc = element.getOwnerDocument();
-                if (doc != null) {
-                    Attr attr = doc.createAttributeNS(attrNsUri, attrLocalName);
-                    attr.setValue(newValue);
-                    attr.setPrefix(lookupNamespacePrefix(element, attrNsUri));
-                    attrMap.setNamedItemNS(attr);
-                    return true;
-                }
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Helper method to commit all dirty attributes values to XML.
-     * <p/>
-     * This method is useful if {@link #setAttributeValue(String, String, boolean)} has been
-     * called more than once and all the attributes marked as dirty must be commited to the
-     * XML. It calls {@link #commitAttributeToXml(UiAttributeNode, String)} on each dirty
-     * attribute.
-     * <p/>
-     * Note that the caller MUST ensure that modifying the underlying XML model is
-     * safe and must take care of marking the model as dirty if necessary.
-     * 
-     * @see AndroidEditor#editXmlModel(Runnable)
-     * 
-     * @return True if one or more values were actually modified or removed,
-     *         false if nothing changed.
-     */
-    public boolean commitDirtyAttributesToXml() {
-        boolean result = false;
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        for (Entry<AttributeDescriptor, UiAttributeNode> entry : attributeMap.entrySet()) {
-            UiAttributeNode ui_attr = entry.getValue();
-            if (ui_attr.isDirty()) {
-                result |= commitAttributeToXml(ui_attr, ui_attr.getCurrentValue());
-                ui_attr.setDirty(false);
-            }
-        }
-        return result;
-    }
-
-    /**
-     * Returns the namespace prefix matching the requested namespace URI.
-     * If no such declaration is found, returns the default "android" prefix.
-     *  
-     * @param node The current node. Must not be null.
-     * @param nsUri The namespace URI of which the prefix is to be found,
-     *              e.g. SdkConstants.NS_RESOURCES
-     * @return The first prefix declared or the default "android" prefix.
-     */
-    private String lookupNamespacePrefix(Node node, String nsUri) {
-        // Note: Node.lookupPrefix is not implemented in wst/xml/core NodeImpl.java
-        // The following code emulates this simple call:
-        //   String prefix = node.lookupPrefix(SdkConstants.NS_RESOURCES);
-
-        // if the requested URI is null, it denotes an attribute with no namespace.
-        if (nsUri == null) {
-            return null;
-        }
-        
-        // per XML specification, the "xmlns" URI is reserved
-        if (XmlnsAttributeDescriptor.XMLNS_URI.equals(nsUri)) {
-            return "xmlns"; //$NON-NLS-1$
-        }
-        
-        HashSet<String> visited = new HashSet<String>();
-        Document doc = node == null ? null : node.getOwnerDocument();
-        
-        for (; node != null && node.getNodeType() == Node.ELEMENT_NODE;
-               node = node.getParentNode()) {
-            NamedNodeMap attrs = node.getAttributes();
-            for (int n = attrs.getLength() - 1; n >= 0; --n) {
-                Node attr = attrs.item(n);
-                if ("xmlns".equals(attr.getPrefix())) {  //$NON-NLS-1$
-                    String uri = attr.getNodeValue();
-                    String nsPrefix = attr.getLocalName(); 
-                    if (SdkConstants.NS_RESOURCES.equals(uri)) {
-                        return nsPrefix;
-                    }
-                    visited.add(nsPrefix);
-                }
-            }
-        }
-        
-        // Use a sensible default prefix if we can't find one.
-        // We need to make sure the prefix is not one that was declared in the scope
-        // visited above.
-        String prefix = SdkConstants.NS_RESOURCES.equals(nsUri) ? "android" : "ns"; //$NON-NLS-1$ //$NON-NLS-2$
-        String base = prefix;
-        for (int i = 1; visited.contains(prefix); i++) {
-            prefix = base + Integer.toString(i);
-        }
-        
-        // Also create & define this prefix/URI in the XML document as an attribute in the
-        // first element of the document.
-        if (doc != null) {
-            node = doc.getFirstChild();
-            while (node != null && node.getNodeType() != Node.ELEMENT_NODE) {
-                node = node.getNextSibling();
-            }
-            if (node != null) {
-                Attr attr = doc.createAttributeNS(XmlnsAttributeDescriptor.XMLNS_URI, prefix);
-                attr.setValue(nsUri);
-                attr.setPrefix("xmlns"); //$NON-NLS-1$
-                node.getAttributes().setNamedItemNS(attr);
-            }
-        }
-        
-        return prefix;
-    }
-
-    /**
-     * Utility method to internally set the value of a text attribute for the current
-     * UiElementNode.
-     * <p/>
-     * This method is a helper. It silently ignores the errors such as the requested 
-     * attribute not being present in the element or attribute not being settable.
-     * It accepts inherited attributes (such as layout).
-     * <p/>
-     * This does not commit to the XML model. It does mark the attribute node as dirty.
-     * This is up to the caller.
-     * 
-     * @see #commitAttributeToXml(UiAttributeNode, String)
-     * @see #commitDirtyAttributesToXml()
-     * 
-     * @param attrXmlName The XML name of the attribute to modify
-     * @param value The new value for the attribute. If set to null, the attribute is removed.
-     * @param override True if the value must be set even if one already exists.
-     * @return The {@link UiAttributeNode} that has been modified or null.
-     */
-    public UiAttributeNode setAttributeValue(String attrXmlName, String value, boolean override) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        if (value == null) {
-            value = ""; //$NON-NLS-1$ -- this removes an attribute
-        }
-        
-        for (Entry<AttributeDescriptor, UiAttributeNode> entry : attributeMap.entrySet()) {
-            AttributeDescriptor ui_desc = entry.getKey();
-            if (ui_desc.getXmlLocalName().equals(attrXmlName)) {
-                UiAttributeNode ui_attr = entry.getValue();
-                // Not all attributes are editable, ignore those which are not
-                if (ui_attr instanceof IUiSettableAttributeNode) {
-                    String current = ui_attr.getCurrentValue();
-                    // Only update (and mark as dirty) if the attribute did not have any
-                    // value or if the value was different.
-                    if (override || current == null || !current.equals(value)) {
-                        ((IUiSettableAttributeNode) ui_attr).setCurrentValue(value);
-                        // mark the attribute as dirty since their internal content
-                        // as been modified, but not the underlying XML model
-                        ui_attr.setDirty(true);
-                        return ui_attr;
-                    }
-                }
-                break;
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Utility method to retrieve the internal value of an attribute.
-     * <p/>
-     * Note that this retrieves the *field* value if the attribute has some UI, and
-     * not the actual XML value. They may differ if the attribute is dirty.
-     * 
-     * @param attrXmlName The XML name of the attribute to modify
-     * @return The current internal value for the attribute or null in case of error.
-     */
-    public String getAttributeValue(String attrXmlName) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        for (Entry<AttributeDescriptor, UiAttributeNode> entry : attributeMap.entrySet()) {
-            AttributeDescriptor ui_desc = entry.getKey();
-            if (ui_desc.getXmlLocalName().equals(attrXmlName)) {
-                UiAttributeNode ui_attr = entry.getValue();
-                return ui_attr.getCurrentValue();
-            }
-        }
-        return null;
-    }
-
-    // ------ IPropertySource methods
-
-    public Object getEditableValue() {
-        return null;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.views.properties.IPropertySource#getPropertyDescriptors()
-     * 
-     * Returns the property descriptor for this node. Since the descriptors are not linked to the
-     * data, the AttributeDescriptor are used directly.
-     */
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        List<IPropertyDescriptor> propDescs = new ArrayList<IPropertyDescriptor>();
-
-        // get the standard descriptors
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        Set<AttributeDescriptor> keys = attributeMap.keySet();
-        
-        
-        // we only want the descriptor that do implement the IPropertyDescriptor interface.
-        for (AttributeDescriptor key : keys) {
-            if (key instanceof IPropertyDescriptor) {
-                propDescs.add((IPropertyDescriptor)key);
-            }
-        }
-        
-        // now get the descriptor from the unknown attributes
-        for (UiAttributeNode unknownNode : mUnknownUiAttributes) {
-            if (unknownNode.getDescriptor() instanceof IPropertyDescriptor) {
-                propDescs.add((IPropertyDescriptor)unknownNode.getDescriptor());
-            }
-        }
-        
-        // TODO cache this maybe, as it's not going to change (except for unknown descriptors)
-        return propDescs.toArray(new IPropertyDescriptor[propDescs.size()]);
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.views.properties.IPropertySource#getPropertyValue(java.lang.Object)
-     * 
-     * Returns the value of a given property. The id is the result of IPropertyDescriptor.getId(),
-     * which return the AttributeDescriptor itself.
-     */
-    public Object getPropertyValue(Object id) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        UiAttributeNode attribute = attributeMap.get(id);
-
-        if (attribute == null) {
-            // look for the id in the unknown attributes.
-            for (UiAttributeNode unknownAttr : mUnknownUiAttributes) {
-                if (id == unknownAttr.getDescriptor()) {
-                    return unknownAttr;
-                }
-            }
-        }
-        
-        return attribute;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.views.properties.IPropertySource#isPropertySet(java.lang.Object)
-     * 
-     * Returns whether the property is set. In our case this is if the string is non empty.
-     */
-    public boolean isPropertySet(Object id) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        UiAttributeNode attribute = attributeMap.get(id);
-
-        if (attribute != null) {
-            return attribute.getCurrentValue().length() > 0;
-        }
-        
-        // look for the id in the unknown attributes.
-        for (UiAttributeNode unknownAttr : mUnknownUiAttributes) {
-            if (id == unknownAttr.getDescriptor()) {
-                return unknownAttr.getCurrentValue().length() > 0;
-            }
-        }
-        
-        return false;
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.views.properties.IPropertySource#resetPropertyValue(java.lang.Object)
-     * 
-     * Reset the property to its default value. For now we simply empty it.
-     */
-    public void resetPropertyValue(Object id) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        UiAttributeNode attribute = attributeMap.get(id);
-        if (attribute != null) {
-            // TODO: reset the value of the attribute
-            
-            return;
-        }
-        
-        // look for the id in the unknown attributes.
-        for (UiAttributeNode unknownAttr : mUnknownUiAttributes) {
-            if (id == unknownAttr.getDescriptor()) {
-                // TODO: reset the value of the attribute
-                
-                return;
-            }
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see org.eclipse.ui.views.properties.IPropertySource#setPropertyValue(java.lang.Object, java.lang.Object)
-     * 
-     * Set the property value. id is the result of IPropertyDescriptor.getId(), which is the
-     * AttributeDescriptor itself. Value should be a String.
-     */
-    public void setPropertyValue(Object id, Object value) {
-        HashMap<AttributeDescriptor, UiAttributeNode> attributeMap = getInternalUiAttributes();
-        
-        UiAttributeNode attribute = attributeMap.get(id);
-        
-        if (attribute == null) {
-            // look for the id in the unknown attributes.
-            for (UiAttributeNode unknownAttr : mUnknownUiAttributes) {
-                if (id == unknownAttr.getDescriptor()) {
-                    attribute = unknownAttr;
-                    break;
-                }
-            }
-        }
-        
-        if (attribute != null) {
-            final UiAttributeNode fAttribute = attribute;
-
-            // get the current value and compare it to the new value
-            String oldValue = fAttribute.getCurrentValue();
-            final String newValue = (String)value;
-            
-            if (oldValue.equals(newValue)) {
-                return;
-            }
-            
-            AndroidEditor editor = getEditor();
-            editor.editXmlModel(new Runnable() {
-                public void run() {
-                    commitAttributeToXml(fAttribute, newValue);
-                }
-            });
-        }
-    }
-
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiFlagAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiFlagAttributeNode.java
deleted file mode 100644
index ddcf0a0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiFlagAttributeNode.java
+++ /dev/null
@@ -1,308 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.FlagAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.resource.FontDescriptor;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.dialogs.SelectionStatusDialog;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Set;
-
-/**
- * Represents an XML attribute that is defined by a set of flag values,
- * i.e. enum names separated by pipe (|) characters.
- * 
- * Note: in Android resources, a "flag" is a list of fixed values where one or
- * more values can be selected using an "or", e.g. "align='left|top'".
- * By contrast, an "enum" is a list of fixed values of which only one can be
- * selected at a given time, e.g. "gravity='right'".
- * <p/>
- * This class handles the "flag" case.
- * The "enum" case is done using {@link UiListAttributeNode}.
- */
-public class UiFlagAttributeNode extends UiTextAttributeNode {
-
-    public UiFlagAttributeNode(FlagAttributeDescriptor attributeDescriptor,
-            UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public void createUiControl(Composite parent, IManagedForm managedForm) {
-        setManagedForm(managedForm);
-        FormToolkit toolkit = managedForm.getToolkit();
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-
-        Label label = toolkit.createLabel(parent, desc.getUiName());
-        label.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        SectionHelper.addControlTooltip(label, DescriptorsUtils.formatTooltip(desc.getTooltip()));
-
-        Composite composite = toolkit.createComposite(parent);
-        composite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE));
-        GridLayout gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        composite.setLayout(gl);
-        // Fixes missing text borders under GTK... also requires adding a 1-pixel margin
-        // for the text field below
-        toolkit.paintBordersFor(composite);
-        
-        final Text text = toolkit.createText(composite, getCurrentValue());
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalIndent = 1;  // Needed by the fixed composite borders under GTK
-        text.setLayoutData(gd);
-        final Button selectButton = toolkit.createButton(composite, "Select...", SWT.PUSH);
-        
-        setTextWidget(text);
-        
-        selectButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-
-                String currentText = getTextWidgetValue();
-                
-                String result = showDialog(selectButton.getShell(), currentText);
-                
-                if (result != null) {
-                    setTextWidgetValue(result);
-                }
-            }
-        });
-    }
-
-    /**
-     * Get the flag names, either from the initial names set in the attribute
-     * or by querying the framework resource parser.
-     */
-    @Override
-    public String[] getPossibleValues() {
-        String attr_name = getDescriptor().getXmlLocalName();
-        String element_name = getUiParent().getDescriptor().getXmlName();
-        
-        String[] values = null;
-        
-        if (getDescriptor() instanceof FlagAttributeDescriptor &&
-                ((FlagAttributeDescriptor) getDescriptor()).getNames() != null) {
-            // Get enum values from the descriptor
-            values = ((FlagAttributeDescriptor) getDescriptor()).getNames();
-        }
-
-        if (values == null) {
-            // or from the AndroidTargetData
-            UiElementNode uiNode = getUiParent();
-            AndroidEditor editor = uiNode.getEditor();
-            AndroidTargetData data = editor.getTargetData();
-            if (data != null) {
-                values = data.getAttributeValues(element_name, attr_name);
-            }
-        }
-        
-        return values;
-    }
-    
-    /**
-     * Shows a dialog letting the user choose a set of enum, and returns a string
-     * containing the result.
-     */
-    public String showDialog(Shell shell, String currentValue) {
-        FlagSelectionDialog dlg = new FlagSelectionDialog(
-                shell, currentValue.trim().split("\\s*\\|\\s*")); //$NON-NLS-1$
-        dlg.open();
-        Object[] result = dlg.getResult();
-        if (result != null) {
-            StringBuilder buf = new StringBuilder();
-            for (Object name : result) {
-                if (name instanceof String) {
-                    if (buf.length() > 0) {
-                        buf.append("|"); //$NON-NLS-1$
-                    }
-                    buf.append(name);
-                }
-            }
-            
-            return buf.toString();
-        }
-        
-        return null;
-
-    }
-    
-    /**
-     * Displays a list of flag names with checkboxes.
-     */
-    private class FlagSelectionDialog extends SelectionStatusDialog {
-
-        private Set<String> mCurrentSet;
-        private Table mTable;
-
-        public FlagSelectionDialog(Shell parentShell, String[] currentNames) {
-            super(parentShell);
-            
-            mCurrentSet = new HashSet<String>();
-            for (String name : currentNames) {
-                if (name.length() > 0) {
-                    mCurrentSet.add(name);
-                }
-            }
-
-            int shellStyle = getShellStyle();
-            setShellStyle(shellStyle | SWT.MAX | SWT.RESIZE);
-        }
-
-        @Override
-        protected void computeResult() {
-            if (mTable != null) {
-                ArrayList<String> results = new ArrayList<String>();
-                
-                for (TableItem item : mTable.getItems()) {
-                    if (item.getChecked()) {
-                        results.add((String)item.getData());
-                    }
-                }
-                
-                setResult(results);
-            }
-        }
-
-        @Override
-        protected Control createDialogArea(Composite parent) {
-            Composite composite= new Composite(parent, SWT.NONE);
-            composite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
-            composite.setLayout(new GridLayout(1, true));
-            composite.setFont(parent.getFont());
-            
-            Label label = new Label(composite, SWT.NONE);
-            label.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
-            label.setText(String.format("Select the flag values for attribute %1$s:",
-                    ((FlagAttributeDescriptor) getDescriptor()).getUiName()));
- 
-            mTable = new Table(composite, SWT.CHECK | SWT.BORDER);
-            GridData data = new GridData();
-            // The 60,18 hints are the ones used by AbstractElementListSelectionDialog
-            data.widthHint = convertWidthInCharsToPixels(60);
-            data.heightHint = convertHeightInCharsToPixels(18);
-            data.grabExcessVerticalSpace = true;
-            data.grabExcessHorizontalSpace = true;
-            data.horizontalAlignment = GridData.FILL;
-            data.verticalAlignment = GridData.FILL;
-            mTable.setLayoutData(data);
-
-            mTable.setHeaderVisible(false);
-            final TableColumn column = new TableColumn(mTable, SWT.NONE);
-
-            // List all the expected flag names and check those which are currently used
-            String[] names = getPossibleValues();
-            if (names != null) {
-                for (String name : names) {
-                    TableItem item = new TableItem(mTable, SWT.NONE);
-                    item.setText(name);
-                    item.setData(name);
-                    
-                    boolean hasName = mCurrentSet.contains(name);
-                    item.setChecked(hasName);
-                    if (hasName) {
-                        mCurrentSet.remove(name);
-                    }
-                }
-            }
-
-            // If there are unknown flag names currently used, display them at the end if the
-            // table already checked.
-            if (!mCurrentSet.isEmpty()) {
-                FontDescriptor fontDesc = JFaceResources.getDialogFontDescriptor();
-                fontDesc = fontDesc.withStyle(SWT.ITALIC);
-                Font font = fontDesc.createFont(JFaceResources.getDialogFont().getDevice());
-
-                for (String name : mCurrentSet) {
-                    TableItem item = new TableItem(mTable, SWT.NONE);
-                    item.setText(String.format("%1$s (unknown flag)", name));
-                    item.setData(name);
-                    item.setChecked(true);
-                    item.setFont(font);
-                }
-            }
-            
-            // Add a listener that will resize the column to the full width of the table
-            // so that only one column appears in the table even if the dialog is resized.
-            ControlAdapter listener = new ControlAdapter() {
-                @Override
-                public void controlResized(ControlEvent e) {
-                    Rectangle r = mTable.getClientArea();
-                    column.setWidth(r.width);
-                }
-            };
-            
-            mTable.addControlListener(listener);
-            listener.controlResized(null /* event not used */);
-
-            // Add a selection listener that will check/uncheck items when they are double-clicked
-            mTable.addSelectionListener(new SelectionAdapter() {
-                /** Default selection means double-click on "most" platforms */
-                @Override
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    if (e.item instanceof TableItem) {
-                        TableItem i = (TableItem) e.item;
-                        i.setChecked(!i.getChecked());
-                    }
-                    super.widgetDefaultSelected(e);
-                } 
-            });
-            
-            Dialog.applyDialogFont(composite);            
-            setHelpAvailable(false);
-            
-            return composite;
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiListAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiListAttributeNode.java
deleted file mode 100644
index c5c10aa..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiListAttributeNode.java
+++ /dev/null
@@ -1,200 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.ListAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-
-/**
- * Represents an XML attribute which has possible built-in values, and can be modified by
- * an editable Combo box.
- * <p/>
- * See {@link UiTextAttributeNode} for more information.
- */
-public class UiListAttributeNode extends UiAbstractTextAttributeNode {
-
-    protected Combo mCombo;
-
-    public UiListAttributeNode(ListAttributeDescriptor attributeDescriptor,
-            UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-    
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public final void createUiControl(final Composite parent, IManagedForm managedForm) {
-        FormToolkit toolkit = managedForm.getToolkit();
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-
-        Label label = toolkit.createLabel(parent, desc.getUiName());
-        label.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        SectionHelper.addControlTooltip(label, DescriptorsUtils.formatTooltip(desc.getTooltip()));
-
-        int style = SWT.DROP_DOWN;
-        mCombo = new Combo(parent, style); 
-        TableWrapData twd = new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE);
-        twd.maxWidth = 100;
-        mCombo.setLayoutData(twd);
-        
-        fillCombo();
-        
-        setTextWidgetValue(getCurrentValue());
-        
-        mCombo.addModifyListener(new ModifyListener() {
-            /**
-             * Sent when the text is modified, whether by the user via manual
-             * input or programmatic input via setText().
-             * <p/>
-             * Simply mark the attribute as dirty if it really changed.
-             * The container SectionPart will collect these flag and manage them.
-             */
-            public void modifyText(ModifyEvent e) {
-                if (!isInInternalTextModification() &&
-                        !isDirty() &&
-                        mCombo != null &&
-                        getCurrentValue() != null &&
-                        !mCombo.getText().equals(getCurrentValue())) {
-                    setDirty(true);
-                }
-            }            
-        });
-
-        // Remove self-reference when the widget is disposed
-        mCombo.addDisposeListener(new DisposeListener() {
-            public void widgetDisposed(DisposeEvent e) {
-                mCombo = null;
-            }
-        });
-    }
-    
-    protected void fillCombo() {
-        String[] values = getPossibleValues();
-
-        if (values == null) {
-            AdtPlugin.log(IStatus.ERROR,
-                    "FrameworkResourceManager did not provide values yet for %1$s",
-                    getDescriptor().getXmlLocalName());
-        } else {
-            for (String value : values) {
-                mCombo.add(value);
-            }
-        }
-    }
-    
-    /**
-     * Get the list values, either from the initial values set in the attribute
-     * or by querying the framework resource parser.
-     */
-    @Override
-    public String[] getPossibleValues() {
-        AttributeDescriptor descriptor = getDescriptor();
-        UiElementNode uiParent = getUiParent();
-
-        String attr_name = descriptor.getXmlLocalName();
-        String element_name = uiParent.getDescriptor().getXmlName();
-        
-        // FrameworkResourceManager expects a specific prefix for the attribute.
-        String prefix = "";
-        if (SdkConstants.NS_RESOURCES.equals(descriptor.getNamespaceUri())) {
-            prefix = "android:"; //$NON-NLS-1$
-        } else if (XmlnsAttributeDescriptor.XMLNS_URI.equals(descriptor.getNamespaceUri())) {
-            prefix = "xmlns:"; //$NON-NLS-1$
-        }
-        attr_name = prefix + attr_name;
-        
-        String[] values = null;
-        
-        if (descriptor instanceof ListAttributeDescriptor &&
-                ((ListAttributeDescriptor) descriptor).getValues() != null) {
-            // Get enum values from the descriptor
-            values = ((ListAttributeDescriptor) descriptor).getValues();
-        }
-
-        if (values == null) {
-            // or from the AndroidTargetData
-            UiElementNode uiNode = getUiParent();
-            AndroidEditor editor = uiNode.getEditor();
-            AndroidTargetData data = editor.getTargetData();
-            if (data != null) {
-                // get the great-grand-parent descriptor.
-                
-                // the parent should always exist.
-                UiElementNode grandParentNode = uiParent.getUiParent();
-    
-                String greatGrandParentNodeName = null;
-                if (grandParentNode != null) {
-                    UiElementNode greatGrandParentNode = grandParentNode.getUiParent();
-                    if (greatGrandParentNode != null) {
-                        greatGrandParentNodeName =
-                            greatGrandParentNode.getDescriptor().getXmlName();
-                    }
-                }
-            
-                values = data.getAttributeValues(element_name, attr_name, greatGrandParentNodeName);
-            }
-        }
-        
-        return values;
-    }
-
-    @Override
-    public String getTextWidgetValue() {
-        if (mCombo != null) {
-            return mCombo.getText();
-        }
-        
-        return null;
-    }
-
-    @Override
-    public final boolean isValid() {
-        return mCombo != null;
-    }
-
-    @Override
-    public void setTextWidgetValue(String value) {
-        if (mCombo != null) {
-            mCombo.setText(value);
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiResourceAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiResourceAttributeNode.java
deleted file mode 100644
index 1c1e1bd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiResourceAttributeNode.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-import com.android.ide.eclipse.editors.wizards.ReferenceChooserDialog;
-import com.android.ide.eclipse.editors.wizards.ResourceChooser;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.window.Window;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-
-/**
- * Represents an XML attribute for a resource that can be modified using a simple text field or
- * a dialog to choose an existing resource.
- * <p/>
- * It can be configured to represent any kind of resource, by providing the desired
- * {@link ResourceType} in the constructor.
- * <p/>
- * See {@link UiTextAttributeNode} for more information.
- */
-public class UiResourceAttributeNode extends UiTextAttributeNode {
-    
-    private ResourceType mType;
-    
-    public UiResourceAttributeNode(ResourceType type,
-            AttributeDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-        
-        mType = type;
-    }
-
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public void createUiControl(final Composite parent, IManagedForm managedForm) {
-        setManagedForm(managedForm);
-        FormToolkit toolkit = managedForm.getToolkit();
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-
-        Label label = toolkit.createLabel(parent, desc.getUiName());
-        label.setLayoutData(new TableWrapData(TableWrapData.LEFT, TableWrapData.MIDDLE));
-        SectionHelper.addControlTooltip(label, DescriptorsUtils.formatTooltip(desc.getTooltip()));
-
-        Composite composite = toolkit.createComposite(parent);
-        composite.setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.MIDDLE));
-        GridLayout gl = new GridLayout(2, false);
-        gl.marginHeight = gl.marginWidth = 0;
-        composite.setLayout(gl);
-        // Fixes missing text borders under GTK... also requires adding a 1-pixel margin
-        // for the text field below
-        toolkit.paintBordersFor(composite);
-        
-        final Text text = toolkit.createText(composite, getCurrentValue());
-        GridData gd = new GridData(GridData.FILL_HORIZONTAL);
-        gd.horizontalIndent = 1;  // Needed by the fixed composite borders under GTK
-        text.setLayoutData(gd);
-        Button browseButton = toolkit.createButton(composite, "Browse...", SWT.PUSH);
-        
-        setTextWidget(text);
-
-        // TODO Add a validator using onAddModifyListener
-        
-        browseButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                String result = showDialog(parent.getShell(), text.getText().trim());
-                if (result != null) {
-                    text.setText(result);
-                }
-            }
-        });
-    }
-    
-    /**
-     * Shows a dialog letting the user choose a set of enum, and returns a string
-     * containing the result.
-     */
-    public String showDialog(Shell shell, String currentValue) {
-        // we need to get the project of the file being edited.
-        UiElementNode uiNode = getUiParent();
-        AndroidEditor editor = uiNode.getEditor();
-        IProject project = editor.getProject();
-        if (project != null) {
-            // get the resource repository for this project and the system resources.
-            IResourceRepository projectRepository =
-                ResourceManager.getInstance().getProjectResources(project);
-            
-            if (mType != null) {
-                // get the Target Data to get the system resources
-                AndroidTargetData data = editor.getTargetData();
-                IResourceRepository systemRepository = data.getSystemResources();
-
-                // open a resource chooser dialog for specified resource type.
-                ResourceChooser dlg = new ResourceChooser(mType,
-                        projectRepository, systemRepository, shell);
-
-                dlg.setCurrentResource(currentValue);
-
-                if (dlg.open() == Window.OK) {
-                    return dlg.getCurrentResource();
-                }
-            } else {
-                ReferenceChooserDialog dlg = new ReferenceChooserDialog(projectRepository,
-                        shell);
-
-                dlg.setCurrentResource(currentValue);
-
-                if (dlg.open() == Window.OK) {
-                    return dlg.getCurrentResource();
-                }
-            }
-        }
-
-        return null;
-    }
-    
-    @Override
-    public String[] getPossibleValues() {
-        // TODO: compute a list of existing resources for content assist completion
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiSeparatorAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiSeparatorAttributeNode.java
deleted file mode 100644
index 192f752..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiSeparatorAttributeNode.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-import org.w3c.dom.Node;
-
-/**
- * {@link UiSeparatorAttributeNode} does not represent any real attribute.
- * <p/>
- * It is used to separate groups of attributes visually.
- */
-public class UiSeparatorAttributeNode extends UiAttributeNode {
-
-    /** Creates a new {@link UiAttributeNode} linked to a specific {@link AttributeDescriptor} */
-    public UiSeparatorAttributeNode(SeparatorAttributeDescriptor attrDesc,
-            UiElementNode uiParent) {
-        super(attrDesc, uiParent);
-    }
-
-    /** Returns the current value of the node. */
-    @Override
-    public String getCurrentValue() {
-        // There is no value here.
-        return null;
-    }
-
-    /**
-     * Sets whether the attribute is dirty and also notifies the editor some part's dirty
-     * flag as changed.
-     * <p/>
-     * Subclasses should set the to true as a result of user interaction with the widgets in
-     * the section and then should set to false when the commit() method completed.
-     */
-    @Override
-    public void setDirty(boolean isDirty) {
-        // This is never dirty.
-    }
-    
-    /**
-     * Called once by the parent user interface to creates the necessary
-     * user interface to edit this attribute.
-     * <p/>
-     * This method can be called more than once in the life cycle of an UI node,
-     * typically when the UI is part of a master-detail tree, as pages are swapped.
-     * 
-     * @param parent The composite where to create the user interface.
-     * @param managedForm The managed form owning this part.
-     */
-    @Override
-    public void createUiControl(Composite parent, IManagedForm managedForm) {
-        FormToolkit toolkit = managedForm.getToolkit();
-        Composite row = toolkit.createComposite(parent);
-        
-        TableWrapData twd = new TableWrapData(TableWrapData.FILL_GRAB);
-        if (parent.getLayout() instanceof TableWrapLayout) {
-            twd.colspan = ((TableWrapLayout) parent.getLayout()).numColumns;
-        }
-        row.setLayoutData(twd);
-        row.setLayout(new GridLayout(3, false /* equal width */));
-
-        Label sep = toolkit.createSeparator(row, SWT.HORIZONTAL);
-        GridData gd = new GridData(SWT.LEFT, SWT.CENTER, false, false);
-        gd.widthHint = 16;
-        sep.setLayoutData(gd);
-
-        Label label = toolkit.createLabel(row, getDescriptor().getXmlLocalName());
-        label.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false));
-
-        sep = toolkit.createSeparator(row, SWT.HORIZONTAL);
-        sep.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false));
-    }
-    
-    /** No completion values for this UI attribute. */
-    @Override
-    public String[] getPossibleValues() {
-        return null;
-    }
-    
-    /**
-     * Called when the XML is being loaded or has changed to
-     * update the value held by this user interface attribute node.
-     * <p/>
-     * The XML Node <em>may</em> be null, which denotes that the attribute is not
-     * specified in the XML model. In general, this means the "default" value of the
-     * attribute should be used.
-     * <p/>
-     * The caller doesn't really know if attributes have changed,
-     * so it will call this to refresh the attribute anyway. It's up to the
-     * UI implementation to minimize refreshes.
-     * 
-     * @param xml_attribute_node
-     */
-    @Override
-    public void updateValue(Node xml_attribute_node) {
-        // No value to update.
-    }
-
-    /**
-     * Called by the user interface when the editor is saved or its state changed
-     * and the modified attributes must be committed (i.e. written) to the XML model.
-     * <p/>
-     * Important behaviors:
-     * <ul>
-     * <li>The caller *must* have called IStructuredModel.aboutToChangeModel before.
-     *     The implemented methods must assume it is safe to modify the XML model.
-     * <li>On success, the implementation *must* call setDirty(false).
-     * <li>On failure, the implementation can fail with an exception, which
-     *     is trapped and logged by the caller, or do nothing, whichever is more
-     *     appropriate.
-     * </ul>
-     */
-    @Override
-    public void commit() {
-        // No value to commit.
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextAttributeNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextAttributeNode.java
deleted file mode 100644
index 4c53f4c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextAttributeNode.java
+++ /dev/null
@@ -1,190 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.ui.SectionHelper;
-
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-
-/**
- * Represents an XML attribute in that can be modified using a simple text field
- * in the XML editor's user interface.
- * <p/>
- * The XML attribute has no default value. When unset, the text field is blank.
- * When updating the XML, if the field is empty, the attribute will be removed
- * from the XML element.  
- * <p/>
- * See {@link UiAttributeNode} for more information.
- */
-public class UiTextAttributeNode extends UiAbstractTextAttributeNode {
-
-    /** Text field */
-    private Text mText;
-    /** The managed form, set only once createUiControl has been called. */
-    private IManagedForm mManagedForm;
-
-    public UiTextAttributeNode(AttributeDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-    
-    /* (non-java doc)
-     * Creates a label widget and an associated text field.
-     * <p/>
-     * As most other parts of the android manifest editor, this assumes the
-     * parent uses a table layout with 2 columns.
-     */
-    @Override
-    public void createUiControl(Composite parent, IManagedForm managedForm) {
-        setManagedForm(managedForm);
-        TextAttributeDescriptor desc = (TextAttributeDescriptor) getDescriptor();
-        Text text = SectionHelper.createLabelAndText(parent, managedForm.getToolkit(),
-                desc.getUiName(), getCurrentValue(),
-                DescriptorsUtils.formatTooltip(desc.getTooltip()));
-
-        setTextWidget(text);
-    }
-
-    /** No completion values for this UI attribute. */
-    @Override
-    public String[] getPossibleValues() {
-        return null;
-    }
-    
-    /**
-     * Sets the internal managed form.
-     * This is usually set by createUiControl.
-     */
-    protected void setManagedForm(IManagedForm managedForm) {
-         mManagedForm = managedForm;
-    }
-    
-    /**
-     * @return The managed form, set only once createUiControl has been called.
-     */
-    protected IManagedForm getManagedForm() {
-        return mManagedForm;
-    }
-    
-    /* (non-java doc)
-     * Returns if the attribute node is valid, and its UI has been created.
-     */
-    @Override
-    public boolean isValid() {
-        return mText != null;
-    }
-
-    @Override
-    public String getTextWidgetValue() {
-        if (mText != null) {
-            return mText.getText();
-        }
-        
-        return null;
-    }
-
-    @Override
-    public void setTextWidgetValue(String value) {
-        if (mText != null) {
-            mText.setText(value);
-        }
-    }
-
-    /**
-     * Sets the Text widget object, and prepares it to handle modification and synchronization
-     * with the XML node.
-     * @param textWidget
-     */
-    protected final void setTextWidget(Text textWidget) {
-        mText = textWidget;
- 
-        if (textWidget != null) {
-            // Sets the with hint for the text field. Derived classes can always override it.
-            // This helps the grid layout to resize correctly on smaller screen sizes.
-            Object data = textWidget.getLayoutData();
-            if (data == null) {
-            } else if (data instanceof GridData) {
-                ((GridData)data).widthHint = AndroidEditor.TEXT_WIDTH_HINT;
-            } else if (data instanceof TableWrapData) {
-                ((TableWrapData)data).maxWidth = 100;
-            }
-            
-            mText.addModifyListener(new ModifyListener() {
-                /**
-                 * Sent when the text is modified, whether by the user via manual
-                 * input or programmatic input via setText().
-                 * <p/>
-                 * Simply mark the attribute as dirty if it really changed.
-                 * The container SectionPart will collect these flag and manage them.
-                 */
-                public void modifyText(ModifyEvent e) {
-                    if (!isInInternalTextModification() &&
-                            !isDirty() &&
-                            mText != null &&
-                            getCurrentValue() != null &&
-                            !mText.getText().equals(getCurrentValue())) {
-                        setDirty(true);
-                    }
-                }            
-            });
-            
-            // Remove self-reference when the widget is disposed
-            mText.addDisposeListener(new DisposeListener() {
-                public void widgetDisposed(DisposeEvent e) {
-                    mText = null;
-                }
-            });
-        }
-        
-        onAddValidators(mText);
-    }
-
-    /**
-     * Called after the text widget as been created.
-     * <p/>
-     * Derived classes typically want to:
-     * <li> Create a new {@link ModifyListener} and attach it to the given {@link Text} widget.
-     * <li> In the modify listener, call getManagedForm().getMessageManager().addMessage()
-     *      and getManagedForm().getMessageManager().removeMessage() as necessary.
-     * <li> Call removeMessage in a new text.addDisposeListener.
-     * <li> Call the validator once to setup the initial messages as needed.
-     * <p/>
-     * The base implementation does nothing.
-     * 
-     * @param text The {@link Text} widget to validate.
-     */
-    protected void onAddValidators(Text text) {
-    }
-
-    /**
-     * Returns the text widget.
-     */
-    protected final Text getTextWidget() {
-        return mText;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextValueNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextValueNode.java
deleted file mode 100644
index 5c1db05..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/uimodel/UiTextValueNode.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.uimodel;
-
-import com.android.ide.eclipse.editors.descriptors.TextValueDescriptor;
-
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.w3c.dom.Text;
-
-/**
- * Represents an XML element value in that can be modified using a simple text field
- * in the XML editor's user interface.
- */
-public class UiTextValueNode extends UiTextAttributeNode {
-
-    public UiTextValueNode(TextValueDescriptor attributeDescriptor, UiElementNode uiParent) {
-        super(attributeDescriptor, uiParent);
-    }
-
-    /**
-     * Updates the current text field's value when the XML has changed.
-     * <p/>
-     * The caller doesn't really know if value of the element has changed,
-     * so it will call this to refresh the value anyway. The value
-     * is only set if it has changed.
-     * <p/>
-     * This also resets the "dirty" flag.
-    */
-    @Override
-    public void updateValue(Node xml_attribute_node) {
-        setCurrentValue(DEFAULT_VALUE);
-
-        // The argument xml_attribute_node is not used here. It should always be
-        // null since this is not an attribute. What we want is the "text value" of
-        // the parent element, which is actually the first text node of the element.
-        
-        UiElementNode parent = getUiParent();
-        if (parent != null) {
-            Node xml_node = parent.getXmlNode();
-            if (xml_node != null) {
-                for (Node xml_child = xml_node.getFirstChild();
-                    xml_child != null;
-                    xml_child = xml_child.getNextSibling()) {
-                    if (xml_child.getNodeType() == Node.TEXT_NODE) {
-                        setCurrentValue(xml_child.getNodeValue());
-                        break;
-                    }
-                }
-            }
-        }
-
-        if (isValid() && !getTextWidgetValue().equals(getCurrentValue())) {
-            try {
-                setInInternalTextModification(true);
-                setTextWidgetValue(getCurrentValue());
-                setDirty(false);
-            } finally {
-                setInInternalTextModification(false);
-            }
-        }
-    }
-
-    /* (non-java doc)
-     * Called by the user interface when the editor is saved or its state changed
-     * and the modified "attributes" must be committed (i.e. written) to the XML model.
-     */
-    @Override
-    public void commit() {
-        UiElementNode parent = getUiParent();
-        if (parent != null && isValid() && isDirty()) {
-            // Get (or create) the underlying XML element node that contains the value.
-            Node element = parent.prepareCommit();
-            if (element != null) {
-                String value = getTextWidgetValue();
-
-                // Try to find an existing text child to update.
-                boolean updated = false;
-
-                for (Node xml_child = element.getFirstChild();
-                        xml_child != null;
-                        xml_child = xml_child.getNextSibling()) {
-                    if (xml_child.getNodeType() == Node.TEXT_NODE) {
-                        xml_child.setNodeValue(value);
-                        updated = true;
-                        break;
-                    }
-                }
-
-                // If we didn't find a text child to update, we need to create one.
-                if (!updated) {
-                    Document doc = element.getOwnerDocument();
-                    if (doc != null) {
-                        Text text = doc.createTextNode(value);
-                        element.appendChild(text);
-                    }
-                }
-                
-                setCurrentValue(value);
-            }
-        }
-        setDirty(false);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ConfigurationSelector.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ConfigurationSelector.java
deleted file mode 100644
index 4a05b1e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ConfigurationSelector.java
+++ /dev/null
@@ -1,1278 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.editors.resources.configurations.CountryCodeQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.KeyboardStateQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.LanguageQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.NavigationMethodQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.NetworkCodeQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.PixelDensityQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.RegionQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenDimensionQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenOrientationQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.TextInputMethodQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.TouchScreenQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.KeyboardStateQualifier.KeyboardState;
-import com.android.ide.eclipse.editors.resources.configurations.NavigationMethodQualifier.NavigationMethod;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenOrientationQualifier.ScreenOrientation;
-import com.android.ide.eclipse.editors.resources.configurations.TextInputMethodQualifier.TextInputMethod;
-import com.android.ide.eclipse.editors.resources.configurations.TouchScreenQualifier.TouchScreenType;
-import com.android.ide.eclipse.editors.resources.manager.ResourceManager;
-
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.HashMap;
-
-/**
- * Custom UI widget to let user build a Folder configuration.
- * <p/>
- * To use this, instantiate somewhere in the UI and then:
- * <ul>
- * <li>Use {@link #setConfiguration(String)} or {@link #setConfiguration(FolderConfiguration)}.
- * <li>Retrieve the configuration using {@link #getConfiguration(FolderConfiguration)}.
- * </ul> 
- */
-public class ConfigurationSelector extends Composite {
-    
-    public static final int WIDTH_HINT = 600;
-    public static final int HEIGHT_HINT = 250;
-    
-    private Runnable mOnChangeListener;
-
-    private TableViewer mFullTableViewer;
-    private TableViewer mSelectionTableViewer;
-    private Button mAddButton;
-    private Button mRemoveButton;
-    private StackLayout mStackLayout;
-    
-    private boolean mOnRefresh = false;
-
-    private final FolderConfiguration mBaseConfiguration = new FolderConfiguration();
-    private final FolderConfiguration mSelectedConfiguration = new FolderConfiguration();
-    
-    private final HashMap<Class<? extends ResourceQualifier>, QualifierEditBase> mUiMap =
-        new HashMap<Class<? extends ResourceQualifier>, QualifierEditBase>();
-    private Composite mQualifierEditParent;
-    
-    /**
-     * Basic of {@link VerifyListener} to only accept digits.
-     */
-    private static class DigitVerifier implements VerifyListener {
-        public void verifyText(VerifyEvent e) {
-            // check for digit only.
-            for (int i = 0 ; i < e.text.length(); i++) {
-                char letter = e.text.charAt(i);
-                if (letter < '0' || letter > '9') {
-                    e.doit = false;
-                    return;
-                }
-            }
-        }
-    }
-    
-    /**
-     * Implementation of {@link VerifyListener} for Country Code qualifiers.
-     */
-    public static class MobileCodeVerifier extends DigitVerifier {
-        @Override
-        public void verifyText(VerifyEvent e) {
-            super.verifyText(e);
-
-            // basic tests passed?
-            if (e.doit) {
-                // check the max 3 digits.
-                if (e.text.length() - e.end + e.start +
-                        ((Text)e.getSource()).getText().length() > 3) {
-                    e.doit = false;
-                }
-            }
-        }
-    }
-    
-    /**
-     * Implementation of {@link VerifyListener} for the Language and Region qualifiers.
-     */
-    public static class LanguageRegionVerifier implements VerifyListener {
-        public void verifyText(VerifyEvent e) {
-            // check for length
-            if (e.text.length() - e.end + e.start + ((Combo)e.getSource()).getText().length() > 2) {
-                e.doit = false;
-                return;
-            }
-            
-            // check for lower case only.
-            for (int i = 0 ; i < e.text.length(); i++) {
-                char letter = e.text.charAt(i);
-                if ((letter < 'a' || letter > 'z') && (letter < 'A' || letter > 'Z')) {
-                    e.doit = false;
-                    return;
-                }
-            }
-        }
-    }
-    
-    /**
-     * Implementation of {@link VerifyListener} for the Pixel Density qualifier.
-     */
-    public static class DensityVerifier extends DigitVerifier { }
-    
-    /**
-     * Implementation of {@link VerifyListener} for the Screen Dimension qualifier.
-     */
-    public static class DimensionVerifier extends DigitVerifier { }
-    
-    /**
-     * Enum for the state of the configuration being created.
-     */
-    public enum ConfigurationState {
-        OK, INVALID_CONFIG, REGION_WITHOUT_LANGUAGE;
-    }
-
-    public ConfigurationSelector(Composite parent) {
-        super(parent, SWT.NONE);
-
-        mBaseConfiguration.createDefault();
-
-        GridLayout gl = new GridLayout(4, false);
-        gl.marginWidth = gl.marginHeight = 0;
-        setLayout(gl);
-        
-        // first column is the first table
-        final Table fullTable = new Table(this, SWT.SINGLE | SWT.FULL_SELECTION | SWT.BORDER);
-        fullTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        fullTable.setHeaderVisible(true);
-        fullTable.setLinesVisible(true);
-        
-        // create the column
-        final TableColumn fullTableColumn = new TableColumn(fullTable, SWT.LEFT);
-        // set the header
-        fullTableColumn.setText("Available Qualifiers");
-        
-        fullTable.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Rectangle r = fullTable.getClientArea();
-                fullTableColumn.setWidth(r.width);
-            }
-        });
-
-        mFullTableViewer = new TableViewer(fullTable);
-        mFullTableViewer.setContentProvider(new QualifierContentProvider());
-        mFullTableViewer.setLabelProvider(new QualifierLabelProvider(
-                false /* showQualifierValue */));
-        mFullTableViewer.setInput(mBaseConfiguration);
-        mFullTableViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structSelection = (IStructuredSelection)selection;
-                    Object first = structSelection.getFirstElement();
-                    
-                    if (first instanceof ResourceQualifier) {
-                        mAddButton.setEnabled(true);
-                        return;
-                    }
-                }
-                
-                mAddButton.setEnabled(false);
-            }
-        });
-        
-        // 2nd column is the left/right arrow button
-        Composite buttonComposite = new Composite(this, SWT.NONE);
-        gl = new GridLayout(1, false);
-        gl.marginWidth = gl.marginHeight = 0;
-        buttonComposite.setLayout(gl);
-        buttonComposite.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-        
-        new Composite(buttonComposite, SWT.NONE);
-        mAddButton = new Button(buttonComposite, SWT.BORDER | SWT.PUSH);
-        mAddButton.setText("->");
-        mAddButton.setEnabled(false);
-        mAddButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                IStructuredSelection selection = 
-                    (IStructuredSelection)mFullTableViewer.getSelection();
-                
-                Object first = selection.getFirstElement();
-                if (first instanceof ResourceQualifier) {
-                    ResourceQualifier qualifier = (ResourceQualifier)first;
-                    
-                    mBaseConfiguration.removeQualifier(qualifier);
-                    mSelectedConfiguration.addQualifier(qualifier);
-                    
-                    mFullTableViewer.refresh();
-                    mSelectionTableViewer.refresh();
-                    mSelectionTableViewer.setSelection(new StructuredSelection(qualifier), true);
-                    
-                    onChange(false /* keepSelection */);
-                }
-            }
-        });
-
-        mRemoveButton = new Button(buttonComposite, SWT.BORDER | SWT.PUSH);
-        mRemoveButton.setText("<-");
-        mRemoveButton.setEnabled(false);
-        mRemoveButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                IStructuredSelection selection = 
-                    (IStructuredSelection)mSelectionTableViewer.getSelection();
-                
-                Object first = selection.getFirstElement();
-                if (first instanceof ResourceQualifier) {
-                    ResourceQualifier qualifier = (ResourceQualifier)first;
-                    
-                    mSelectedConfiguration.removeQualifier(qualifier);
-                    mBaseConfiguration.addQualifier(qualifier);
-
-                    mFullTableViewer.refresh();
-                    mSelectionTableViewer.refresh();
-                    
-                    onChange(false /* keepSelection */);
-                }
-            }
-        });
-
-        // 3rd column is the selected config table
-        final Table selectionTable = new Table(this, SWT.SINGLE | SWT.FULL_SELECTION | SWT.BORDER);
-        selectionTable.setLayoutData(new GridData(GridData.FILL_BOTH));
-        selectionTable.setHeaderVisible(true);
-        selectionTable.setLinesVisible(true);
-        
-        // create the column
-        final TableColumn selectionTableColumn = new TableColumn(selectionTable, SWT.LEFT);
-        // set the header
-        selectionTableColumn.setText("Chosen Qualifiers");
-        
-        selectionTable.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Rectangle r = selectionTable.getClientArea();
-                selectionTableColumn.setWidth(r.width);
-            }
-        });
-        mSelectionTableViewer = new TableViewer(selectionTable);
-        mSelectionTableViewer.setContentProvider(new QualifierContentProvider());
-        mSelectionTableViewer.setLabelProvider(new QualifierLabelProvider(
-                true /* showQualifierValue */));
-        mSelectionTableViewer.setInput(mSelectedConfiguration);
-        mSelectionTableViewer.addSelectionChangedListener(new ISelectionChangedListener() {
-            public void selectionChanged(SelectionChangedEvent event) {
-                // ignore selection changes during resfreshes in some cases.
-                if (mOnRefresh) {
-                    return;
-                }
-
-                ISelection selection = event.getSelection();
-                if (selection instanceof IStructuredSelection) {
-                    IStructuredSelection structSelection = (IStructuredSelection)selection;
-                    
-                    if (structSelection.isEmpty() == false) {
-                        Object first = structSelection.getFirstElement();
-                        
-                        if (first instanceof ResourceQualifier) {
-                            mRemoveButton.setEnabled(true);
-                            
-                            QualifierEditBase composite = mUiMap.get(first.getClass());
-    
-                            if (composite != null) {
-                                composite.setQualifier((ResourceQualifier)first);
-                            }
-    
-                            mStackLayout.topControl = composite;
-                            mQualifierEditParent.layout();
-                            
-                            return;
-                        }
-                    } else {
-                        mStackLayout.topControl = null;
-                        mQualifierEditParent.layout();
-                    }
-                }
-                
-                mRemoveButton.setEnabled(false);
-            }
-        });
-        
-        // 4th column is the detail of the selected qualifier 
-        mQualifierEditParent = new Composite(this, SWT.NONE);
-        mQualifierEditParent.setLayout(mStackLayout = new StackLayout());
-        mQualifierEditParent.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-        
-        // create the UI for all the qualifiers, and associate them to the ResourceQualifer class.
-        mUiMap.put(CountryCodeQualifier.class, new MCCEdit(mQualifierEditParent));
-        mUiMap.put(NetworkCodeQualifier.class, new MNCEdit(mQualifierEditParent));
-        mUiMap.put(LanguageQualifier.class, new LanguageEdit(mQualifierEditParent));
-        mUiMap.put(RegionQualifier.class, new RegionEdit(mQualifierEditParent));
-        mUiMap.put(ScreenOrientationQualifier.class, new OrientationEdit(mQualifierEditParent));
-        mUiMap.put(PixelDensityQualifier.class, new PixelDensityEdit(mQualifierEditParent));
-        mUiMap.put(TouchScreenQualifier.class, new TouchEdit(mQualifierEditParent));
-        mUiMap.put(KeyboardStateQualifier.class, new KeyboardEdit(mQualifierEditParent));
-        mUiMap.put(TextInputMethodQualifier.class, new TextInputEdit(mQualifierEditParent));
-        mUiMap.put(NavigationMethodQualifier.class, new NavigationEdit(mQualifierEditParent));
-        mUiMap.put(ScreenDimensionQualifier.class, new ScreenDimensionEdit(mQualifierEditParent));
-    }
-    
-    /**
-     * Sets a listener to be notified when the configuration changes.
-     * @param listener A {@link Runnable} whose <code>run()</code> method is called when the
-     * configuration is changed. The method is called from the UI thread.
-     */
-    public void setOnChangeListener(Runnable listener) {
-        mOnChangeListener = listener;
-    }
-    
-    /**
-     * Initialize the UI with a given {@link FolderConfiguration}. This must
-     * be called from the UI thread.
-     * @param config The configuration.
-     */
-    public void setConfiguration(FolderConfiguration config) {
-        mSelectedConfiguration.set(config);
-        mSelectionTableViewer.refresh();
-        
-        // create the base config, which is the default config minus the qualifiers
-        // in SelectedConfiguration
-        mBaseConfiguration.substract(mSelectedConfiguration);
-        mFullTableViewer.refresh();
-    }
-    
-    /**
-     * Initialize the UI with the configuration represented by a resource folder name.
-     * This must be called from the UI thread.
-     * 
-     * @param folderSegments the segments of the folder name,
-     *                       split using {@link FolderConfiguration#QUALIFIER_SEP}.
-     * @return true if success, or false if the folder name is not a valid name.
-     */
-    public boolean setConfiguration(String[] folderSegments) {
-        FolderConfiguration config = ResourceManager.getInstance().getConfig(folderSegments);
-        
-        if (config == null) {
-            return false;
-        }
-
-        setConfiguration(config);
-
-        return true;
-    }
-    
-    /**
-     * Initialize the UI with the configuration represented by a resource folder name.
-     * This must be called from the UI thread.
-     * @param folderName the name of the folder.
-     * @return true if success, or false if the folder name is not a valid name.
-     */
-    public boolean setConfiguration(String folderName) {
-        // split the name of the folder in segments.
-        String[] folderSegments = folderName.split(FolderConfiguration.QUALIFIER_SEP);
-
-        return setConfiguration(folderSegments);
-    }
-    
-    /**
-     * Gets the configuration as setup by the widget.
-     * @param config the {@link FolderConfiguration} object to be filled with the information
-     * from the UI.
-     */
-    public void getConfiguration(FolderConfiguration config) {
-        config.set(mSelectedConfiguration);
-    }
-    
-    /**
-     * Returns the state of the configuration being edited/created.
-     */
-    public ConfigurationState getState() {
-        if (mSelectedConfiguration.getInvalidQualifier() != null) {
-            return ConfigurationState.INVALID_CONFIG;
-        }
-        
-        if (mSelectedConfiguration.checkRegion() == false) {
-            return ConfigurationState.REGION_WITHOUT_LANGUAGE;
-        }
-        
-        return ConfigurationState.OK;
-    }
-    
-    /**
-     * Returns the first invalid qualifier of the configuration being edited/created,
-     * or <code>null<code> if they are all valid (or if none exists).
-     * <p/>If {@link #getState()} return {@link ConfigurationState#INVALID_CONFIG} then this will
-     * not return <code>null</code>.
-     */
-    public ResourceQualifier getInvalidQualifier() {
-        return mSelectedConfiguration.getInvalidQualifier();
-    }
-
-    /**
-     * Handle changes in the configuration.
-     * @param keepSelection if <code>true</code> attemps to avoid triggering selection change in
-     * {@link #mSelectedConfiguration}.
-     */
-    private void onChange(boolean keepSelection) {
-        ISelection selection = null;
-        if (keepSelection) {
-            mOnRefresh = true;
-            selection = mSelectionTableViewer.getSelection();
-        }
-
-        mSelectionTableViewer.refresh(true);
-        
-        if (keepSelection) {
-            mSelectionTableViewer.setSelection(selection);
-            mOnRefresh = false;
-        }
-
-        if (mOnChangeListener != null) {
-            mOnChangeListener.run();
-        }
-    }
-    
-    /**
-     * Content provider around a {@link FolderConfiguration}.
-     */
-    private static class QualifierContentProvider implements IStructuredContentProvider {
-        
-        private FolderConfiguration mInput;
-
-        public QualifierContentProvider() {
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public Object[] getElements(Object inputElement) {
-            return mInput.getQualifiers();
-        }
-
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-            mInput = null;
-            if (newInput instanceof FolderConfiguration) {
-                mInput = (FolderConfiguration)newInput;
-            }
-        }
-    }
-    
-    /**
-     * Label provider for {@link ResourceQualifier} objects.
-     */
-    private static class QualifierLabelProvider implements ITableLabelProvider {
-        
-        private final boolean mShowQualifierValue;
-
-        public QualifierLabelProvider(boolean showQualifierValue) {
-            mShowQualifierValue = showQualifierValue;
-        }
-
-        public String getColumnText(Object element, int columnIndex) {
-            // only one column, so we can ignore columnIndex
-            if (element instanceof ResourceQualifier) {
-                if (mShowQualifierValue) {
-                    String value = ((ResourceQualifier)element).getStringValue();
-                    if (value.length() == 0) {
-                        return String.format("%1$s (?)",
-                                ((ResourceQualifier)element).getShortName());
-                    } else {
-                        return value;
-                    }
-                    
-                } else {
-                    return ((ResourceQualifier)element).getShortName();
-                }
-            }
-
-            return null;
-        }
-        
-        public Image getColumnImage(Object element, int columnIndex) {
-            // only one column, so we can ignore columnIndex
-            if (element instanceof ResourceQualifier) {
-                return ((ResourceQualifier)element).getIcon();
-            }
-
-            return null;
-        }
-
-        public void addListener(ILabelProviderListener listener) {
-            // pass
-        }
-
-        public void dispose() {
-            // pass
-        }
-
-        public boolean isLabelProperty(Object element, String property) {
-            // pass
-            return false;
-        }
-
-        public void removeListener(ILabelProviderListener listener) {
-            // pass
-        }
-    }
-    
-    /**
-     * Base class for Edit widget for {@link ResourceQualifier}.
-     */
-    private abstract static class QualifierEditBase extends Composite {
-
-        public QualifierEditBase(Composite parent, String title) {
-            super(parent, SWT.NONE);
-            setLayout(new GridLayout(1, false));
-
-            new Label(this, SWT.NONE).setText(title);
-        }
-        
-        public abstract void setQualifier(ResourceQualifier qualifier);
-    }
-    
-    /**
-     * Edit widget for {@link CountryCodeQualifier}.
-     */
-    private class MCCEdit extends QualifierEditBase {
-
-        private Text mText;
-
-        public MCCEdit(Composite parent) {
-            super(parent, CountryCodeQualifier.NAME);
-            
-            mText = new Text(this, SWT.BORDER);
-            mText.addVerifyListener(new MobileCodeVerifier());
-            mText.addModifyListener(new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onTextChange();
-                } 
-            });
-
-            mText.addFocusListener(new FocusAdapter() {
-                @Override
-                public void focusLost(FocusEvent e) {
-                    onTextChange();
-                }
-            });
-            
-            new Label(this, SWT.NONE).setText("(3 digit code)");
-        }
-        
-        private void onTextChange() {
-            String value = mText.getText();
-            
-            if (value.length() == 0) {
-                // empty string, means a qualifier with no value.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setCountryCodeQualifier(new CountryCodeQualifier());
-            } else {
-                try {
-                    CountryCodeQualifier qualifier = CountryCodeQualifier.getQualifier(
-                            CountryCodeQualifier.getFolderSegment(Integer.parseInt(value)));
-                    if (qualifier != null) {
-                        mSelectedConfiguration.setCountryCodeQualifier(qualifier);
-                    } else {
-                        // Failure! Looks like the value is wrong
-                        // (for instance not exactly 3 digits).
-                        mSelectedConfiguration.setCountryCodeQualifier(new CountryCodeQualifier());
-                    }
-                } catch (NumberFormatException nfe) {
-                    // Looks like the code is not a number. This should not happen since the text
-                    // field has a VerifyListener that prevents it.
-                    mSelectedConfiguration.setCountryCodeQualifier(new CountryCodeQualifier());
-                }
-            }
-   
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            CountryCodeQualifier q = (CountryCodeQualifier)qualifier;
-            
-            mText.setText(Integer.toString(q.getCode()));
-        }
-    }
-
-    /**
-     * Edit widget for {@link NetworkCodeQualifier}.
-     */
-    private class MNCEdit extends QualifierEditBase {
-        private Text mText;
-
-        public MNCEdit(Composite parent) {
-            super(parent, NetworkCodeQualifier.NAME);
-            
-            mText = new Text(this, SWT.BORDER);
-            mText.addVerifyListener(new MobileCodeVerifier());
-            mText.addModifyListener(new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onTextChange();
-                }
-            });
-            mText.addFocusListener(new FocusAdapter() {
-                @Override
-                public void focusLost(FocusEvent e) {
-                    onTextChange();
-                }
-            });
-
-            new Label(this, SWT.NONE).setText("(1-3 digit code)");
-        }
-        
-        private void onTextChange() {
-            String value = mText.getText();
-            
-            if (value.length() == 0) {
-                // empty string, means a qualifier with no value.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setNetworkCodeQualifier(new NetworkCodeQualifier());
-            } else {
-                try {
-                    NetworkCodeQualifier qualifier = NetworkCodeQualifier.getQualifier(
-                            NetworkCodeQualifier.getFolderSegment(Integer.parseInt(value)));
-                    if (qualifier != null) {
-                        mSelectedConfiguration.setNetworkCodeQualifier(qualifier);
-                    } else {
-                        // Failure! Looks like the value is wrong
-                        // (for instance not exactly 3 digits).
-                        mSelectedConfiguration.setNetworkCodeQualifier(new NetworkCodeQualifier());
-                    }
-                } catch (NumberFormatException nfe) {
-                    // Looks like the code is not a number. This should not happen since the text
-                    // field has a VerifyListener that prevents it.
-                    mSelectedConfiguration.setNetworkCodeQualifier(new NetworkCodeQualifier());
-                }
-            }
-   
-            // notify of change
-            onChange(true /* keepSelection */);
-        } 
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            NetworkCodeQualifier q = (NetworkCodeQualifier)qualifier;
-            
-            mText.setText(Integer.toString(q.getCode()));
-        }
-    }
-    
-    /**
-     * Edit widget for {@link LanguageQualifier}.
-     */
-    private class LanguageEdit extends QualifierEditBase {
-        private Combo mLanguage;
-
-        public LanguageEdit(Composite parent) {
-            super(parent, LanguageQualifier.NAME);
-
-            mLanguage = new Combo(this, SWT.DROP_DOWN);
-            mLanguage.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mLanguage.addVerifyListener(new LanguageRegionVerifier());
-            mLanguage.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onLanguageChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onLanguageChange();
-                }
-            });
-            mLanguage.addModifyListener(new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onLanguageChange();
-                }
-            });
-
-            new Label(this, SWT.NONE).setText("(2 letter code)");
-        }
-
-        private void onLanguageChange() {
-            // update the current config
-            String value = mLanguage.getText();
-            
-            if (value.length() == 0) {
-                // empty string, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setLanguageQualifier(new LanguageQualifier());
-            } else {
-                LanguageQualifier qualifier = null;
-                String segment = LanguageQualifier.getFolderSegment(value);
-                if (segment != null) {
-                    qualifier = LanguageQualifier.getQualifier(segment);
-                }
-
-                if (qualifier != null) {
-                    mSelectedConfiguration.setLanguageQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong (for instance a one letter string).
-                    mSelectedConfiguration.setLanguageQualifier(new LanguageQualifier());
-                }
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            LanguageQualifier q = (LanguageQualifier)qualifier;
-
-            String value = q.getValue();
-            if (value != null) {
-                mLanguage.setText(value);
-            }
-        }
-    }
-
-    /**
-     * Edit widget for {@link RegionQualifier}.
-     */
-    private class RegionEdit extends QualifierEditBase {
-        private Combo mRegion;
-
-        public RegionEdit(Composite parent) {
-            super(parent, RegionQualifier.NAME);
-
-            mRegion = new Combo(this, SWT.DROP_DOWN);
-            mRegion.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mRegion.addVerifyListener(new LanguageRegionVerifier());
-            mRegion.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onRegionChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onRegionChange();
-                }
-            });
-            mRegion.addModifyListener(new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onRegionChange();
-                }
-            });
-
-            new Label(this, SWT.NONE).setText("(2 letter code)");
-        }
-
-        private void onRegionChange() {
-            // update the current config
-            String value = mRegion.getText();
-            
-            if (value.length() == 0) {
-                // empty string, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setRegionQualifier(new RegionQualifier());
-            } else {
-                RegionQualifier qualifier = null;
-                String segment = RegionQualifier.getFolderSegment(value);
-                if (segment != null) {
-                    qualifier = RegionQualifier.getQualifier(segment);
-                }
-
-                if (qualifier != null) {
-                    mSelectedConfiguration.setRegionQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong (for instance a one letter string).
-                    mSelectedConfiguration.setRegionQualifier(new RegionQualifier());
-                }
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            RegionQualifier q = (RegionQualifier)qualifier;
-
-            String value = q.getValue();
-            if (value != null) {
-                mRegion.setText(q.getValue());
-            }
-        }
-    }
-    
-    /**
-     * Edit widget for {@link ScreenOrientationQualifier}.
-     */
-    private class OrientationEdit extends QualifierEditBase {
-
-        private Combo mOrientation;
-
-        public OrientationEdit(Composite parent) {
-            super(parent, ScreenOrientationQualifier.NAME);
-
-            mOrientation = new Combo(this, SWT.DROP_DOWN | SWT.READ_ONLY);
-            ScreenOrientation[] soValues = ScreenOrientation.values();
-            for (ScreenOrientation value : soValues) {
-                mOrientation.add(value.getDisplayValue());
-            }
-
-            mOrientation.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mOrientation.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onOrientationChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onOrientationChange();
-                }
-            });
-        }
-
-        protected void onOrientationChange() {
-            // update the current config
-            int index = mOrientation.getSelectionIndex();
-
-            if (index != -1) {
-                mSelectedConfiguration.setScreenOrientationQualifier(new ScreenOrientationQualifier(
-                    ScreenOrientation.getByIndex(index)));
-            } else {
-                // empty selection, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setScreenOrientationQualifier(
-                        new ScreenOrientationQualifier());
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            ScreenOrientationQualifier q = (ScreenOrientationQualifier)qualifier;
-
-            ScreenOrientation value = q.getValue();
-            if (value == null) {
-                mOrientation.clearSelection();
-            } else {
-                mOrientation.select(ScreenOrientation.getIndex(value));
-            }
-        }
-    }
-
-    /**
-     * Edit widget for {@link PixelDensityQualifier}.
-     */
-    private class PixelDensityEdit extends QualifierEditBase {
-        private Text mText;
-
-        public PixelDensityEdit(Composite parent) {
-            super(parent, PixelDensityQualifier.NAME);
-            
-            mText = new Text(this, SWT.BORDER);
-            mText.addVerifyListener(new DensityVerifier());
-            mText.addModifyListener(new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onTextChange();
-                }
-            });
-            mText.addFocusListener(new FocusAdapter() {
-                @Override
-                public void focusLost(FocusEvent e) {
-                    onTextChange();
-                }
-            });
-        }
-        
-        private void onTextChange() {
-            String value = mText.getText();
-            
-            if (value.length() == 0) {
-                // empty string, means a qualifier with no value.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setPixelDensityQualifier(new PixelDensityQualifier());
-            } else {
-                try {
-                    PixelDensityQualifier qualifier = PixelDensityQualifier.getQualifier(
-                            PixelDensityQualifier.getFolderSegment(Integer.parseInt(value)));
-                    if (qualifier != null) {
-                        mSelectedConfiguration.setPixelDensityQualifier(qualifier);
-                    } else {
-                        // Failure! Looks like the value is wrong
-                        // (for instance a one letter string).
-                        // We do nothing in this case.
-                        return;
-                    }
-                } catch (NumberFormatException nfe) {
-                    // Looks like the code is not a number. This should not happen since the text
-                    // field has a VerifyListener that prevents it.
-                    // We do nothing in this case.
-                    return;
-                }
-            }
-   
-            // notify of change
-            onChange(true /* keepSelection */);
-        } 
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            PixelDensityQualifier q = (PixelDensityQualifier)qualifier;
-            
-            mText.setText(Integer.toString(q.getValue()));
-        }
-    }
-
-    /**
-     * Edit widget for {@link TouchScreenQualifier}.
-     */
-    private class TouchEdit extends QualifierEditBase {
-
-        private Combo mTouchScreen;
-
-        public TouchEdit(Composite parent) {
-            super(parent, TouchScreenQualifier.NAME);
-
-            mTouchScreen = new Combo(this, SWT.DROP_DOWN | SWT.READ_ONLY);
-            TouchScreenType[] tstValues = TouchScreenType.values();
-            for (TouchScreenType value : tstValues) {
-                mTouchScreen.add(value.getDisplayValue());
-            }
-
-            mTouchScreen.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mTouchScreen.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onTouchChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onTouchChange();
-                }
-            });
-        }
-
-        protected void onTouchChange() {
-            // update the current config
-            int index = mTouchScreen.getSelectionIndex();
-
-            if (index != -1) {
-                mSelectedConfiguration.setTouchTypeQualifier(new TouchScreenQualifier(
-                        TouchScreenType.getByIndex(index)));
-            } else {
-                // empty selection, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setTouchTypeQualifier(new TouchScreenQualifier());
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            TouchScreenQualifier q = (TouchScreenQualifier)qualifier;
-
-            TouchScreenType value = q.getValue();
-            if (value == null) {
-                mTouchScreen.clearSelection();
-            } else {
-                mTouchScreen.select(TouchScreenType.getIndex(value));
-            }
-        }
-    }
-
-    /**
-     * Edit widget for {@link KeyboardStateQualifier}.
-     */
-    private class KeyboardEdit extends QualifierEditBase {
-
-        private Combo mKeyboard;
-
-        public KeyboardEdit(Composite parent) {
-            super(parent, KeyboardStateQualifier.NAME);
-
-            mKeyboard = new Combo(this, SWT.DROP_DOWN | SWT.READ_ONLY);
-            KeyboardState[] ksValues = KeyboardState.values();
-            for (KeyboardState value : ksValues) {
-                mKeyboard.add(value.getDisplayValue());
-            }
-
-            mKeyboard.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mKeyboard.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onKeyboardChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onKeyboardChange();
-                }
-            });
-        }
-
-        protected void onKeyboardChange() {
-            // update the current config
-            int index = mKeyboard.getSelectionIndex();
-
-            if (index != -1) {
-                mSelectedConfiguration.setKeyboardStateQualifier(new KeyboardStateQualifier(
-                        KeyboardState.getByIndex(index)));
-            } else {
-                // empty selection, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setKeyboardStateQualifier(
-                        new KeyboardStateQualifier());
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            KeyboardStateQualifier q = (KeyboardStateQualifier)qualifier;
-
-            KeyboardState value = q.getValue();
-            if (value == null) {
-                mKeyboard.clearSelection();
-            } else {
-                mKeyboard.select(KeyboardState.getIndex(value));
-            }
-        }
-    }
-
-    /**
-     * Edit widget for {@link TextInputMethodQualifier}.
-     */
-    private class TextInputEdit extends QualifierEditBase {
-
-        private Combo mTextInput;
-
-        public TextInputEdit(Composite parent) {
-            super(parent, TextInputMethodQualifier.NAME);
-
-            mTextInput = new Combo(this, SWT.DROP_DOWN | SWT.READ_ONLY);
-            TextInputMethod[] timValues = TextInputMethod.values();
-            for (TextInputMethod value : timValues) {
-                mTextInput.add(value.getDisplayValue());
-            }
-
-            mTextInput.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mTextInput.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onTextInputChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onTextInputChange();
-                }
-            });
-        }
-
-        protected void onTextInputChange() {
-            // update the current config
-            int index = mTextInput.getSelectionIndex();
-
-            if (index != -1) {
-                mSelectedConfiguration.setTextInputMethodQualifier(new TextInputMethodQualifier(
-                        TextInputMethod.getByIndex(index)));
-            } else {
-                // empty selection, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setTextInputMethodQualifier(
-                        new TextInputMethodQualifier());
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            TextInputMethodQualifier q = (TextInputMethodQualifier)qualifier;
-
-            TextInputMethod value = q.getValue();
-            if (value == null) {
-                mTextInput.clearSelection();
-            } else {
-                mTextInput.select(TextInputMethod.getIndex(value));
-            }
-        }
-    }
-
-    /**
-     * Edit widget for {@link NavigationMethodQualifier}.
-     */
-    private class NavigationEdit extends QualifierEditBase {
-
-        private Combo mNavigation;
-
-        public NavigationEdit(Composite parent) {
-            super(parent, NavigationMethodQualifier.NAME);
-
-            mNavigation = new Combo(this, SWT.DROP_DOWN | SWT.READ_ONLY);
-            NavigationMethod[] nmValues = NavigationMethod.values();
-            for (NavigationMethod value : nmValues) {
-                mNavigation.add(value.getDisplayValue());
-            }
-
-            mNavigation.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-            mNavigation.addSelectionListener(new SelectionListener() {
-                public void widgetDefaultSelected(SelectionEvent e) {
-                    onNavigationChange();
-                }
-                public void widgetSelected(SelectionEvent e) {
-                    onNavigationChange();
-                }
-            });
-        }
-
-        protected void onNavigationChange() {
-            // update the current config
-            int index = mNavigation.getSelectionIndex();
-
-            if (index != -1) {
-                mSelectedConfiguration.setNavigationMethodQualifier(new NavigationMethodQualifier(
-                        NavigationMethod.getByIndex(index)));
-            } else {
-                // empty selection, means no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setNavigationMethodQualifier(
-                        new NavigationMethodQualifier());
-            }
-
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            NavigationMethodQualifier q = (NavigationMethodQualifier)qualifier;
-
-            NavigationMethod value = q.getValue();
-            if (value == null) {
-                mNavigation.clearSelection();
-            } else {
-                mNavigation.select(NavigationMethod.getIndex(value));
-            }
-        }
-    }
-    
-    /**
-     * Edit widget for {@link ScreenDimensionQualifier}.
-     */
-    private class ScreenDimensionEdit extends QualifierEditBase {
-
-        private Text mSize1;
-        private Text mSize2;
-
-        public ScreenDimensionEdit(Composite parent) {
-            super(parent, ScreenDimensionQualifier.NAME);
-
-            ModifyListener modifyListener = new ModifyListener() {
-                public void modifyText(ModifyEvent e) {
-                    onSizeChange();
-                } 
-            };
-            
-            FocusAdapter focusListener = new FocusAdapter() {
-                @Override
-                public void focusLost(FocusEvent e) {
-                    onSizeChange();
-                }
-            };
-
-            mSize1 = new Text(this, SWT.BORDER);
-            mSize1.addVerifyListener(new DimensionVerifier());
-            mSize1.addModifyListener(modifyListener);
-            mSize1.addFocusListener(focusListener);
-
-            mSize2 = new Text(this, SWT.BORDER);
-            mSize2.addVerifyListener(new DimensionVerifier());
-            mSize2.addModifyListener(modifyListener);
-            mSize2.addFocusListener(focusListener);
-        }
-        
-        private void onSizeChange() {
-            // update the current config
-            String size1 = mSize1.getText();
-            String size2 = mSize2.getText();
-            
-            if (size1.length() == 0 || size2.length() == 0) {
-                // if one of the strings is empty, reset to no qualifier.
-                // Since the qualifier classes are immutable, and we don't want to
-                // remove the qualifier from the configuration, we create a new default one.
-                mSelectedConfiguration.setScreenDimensionQualifier(new ScreenDimensionQualifier());
-            } else {
-                ScreenDimensionQualifier qualifier = ScreenDimensionQualifier.getQualifier(size1,
-                        size2);
-
-                if (qualifier != null) {
-                    mSelectedConfiguration.setScreenDimensionQualifier(qualifier);
-                } else {
-                    // Failure! Looks like the value is wrong, reset the qualifier
-                    // Since the qualifier classes are immutable, and we don't want to
-                    // remove the qualifier from the configuration, we create a new default one.
-                    mSelectedConfiguration.setScreenDimensionQualifier(
-                            new ScreenDimensionQualifier());
-                }
-            }
-   
-            // notify of change
-            onChange(true /* keepSelection */);
-        }
-
-        @Override
-        public void setQualifier(ResourceQualifier qualifier) {
-            ScreenDimensionQualifier q = (ScreenDimensionQualifier)qualifier;
-            
-            mSize1.setText(Integer.toString(q.getValue1()));
-            mSize2.setText(Integer.toString(q.getValue2()));
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileCreationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileCreationPage.java
deleted file mode 100644
index 4d17176..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileCreationPage.java
+++ /dev/null
@@ -1,1062 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.project.ProjectChooserHelper;
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.menu.descriptors.MenuDescriptors;
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-import com.android.ide.eclipse.editors.resources.descriptors.ResourcesDescriptors;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFolderType;
-import com.android.ide.eclipse.editors.wizards.ConfigurationSelector.ConfigurationState;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashSet;
-
-/**
- * This is the single page of the {@link NewXmlFileWizard} which provides the ability to create
- * skeleton XML resources files for Android projects.
- * <p/>
- * This page is used to select the project, the resource folder, resource type and file name.
- */
-class NewXmlFileCreationPage extends WizardPage {
-
-    /**
-     * Information on one type of resource that can be created (e.g. menu, pref, layout, etc.)
-     */
-    static class TypeInfo {
-        private final String mUiName;
-        private final ResourceFolderType mResFolderType;
-        private final String mTooltip;
-        private final Object mRootSeed;
-        private Button mWidget;
-        private ArrayList<String> mRoots = new ArrayList<String>();
-        private final String mXmlns;
-        private final String mDefaultAttrs;
-        private final String mDefaultRoot;
-        
-        public TypeInfo(String uiName,
-                        String tooltip, 
-                        ResourceFolderType resFolderType, 
-                        Object rootSeed,
-                        String defaultRoot,
-                        String xmlns,
-                        String defaultAttrs) {
-            mUiName = uiName;
-            mResFolderType = resFolderType;
-            mTooltip = tooltip;
-            mRootSeed = rootSeed;
-            mDefaultRoot = defaultRoot;
-            mXmlns = xmlns;
-            mDefaultAttrs = defaultAttrs;
-        }
-
-        /** Returns the UI name for the resource type. Unique. Never null. */
-        String getUiName() {
-            return mUiName;
-        }
-        
-        /** Returns the tooltip for the resource type. Can be null. */ 
-        String getTooltip() {
-            return mTooltip;
-        }
-        
-        /**
-         * Returns the name of the {@link ResourceFolderType}.
-         * Never null but not necessarily unique,
-         * e.g. two types use  {@link ResourceFolderType#XML}.
-         */
-        String getResFolderName() {
-            return mResFolderType.getName();
-        }
-        
-        /**
-         * Returns the matching {@link ResourceFolderType}.
-         * Never null but not necessarily unique,
-         * e.g. two types use  {@link ResourceFolderType#XML}.
-         */
-        ResourceFolderType getResFolderType() {
-            return mResFolderType;
-        }
-
-        /** Sets the radio button associate with the resource type. Can be null. */
-        void setWidget(Button widget) {
-            mWidget = widget;
-        }
-        
-        /** Returns the radio button associate with the resource type. Can be null. */
-        Button getWidget() {
-            return mWidget;
-        }
-        
-        /**
-         * Returns the seed used to fill the root element values.
-         * The seed might be either a String, a String array, an {@link ElementDescriptor},
-         * a {@link DocumentDescriptor} or null. 
-         */
-        Object getRootSeed() {
-            return mRootSeed;
-        }
-
-        /** Returns the default root element that should be selected by default. Can be null. */
-        String getDefaultRoot() {
-            return mDefaultRoot;
-        }
-
-        /**
-         * Returns the list of all possible root elements for the resource type.
-         * This can be an empty ArrayList but not null.
-         * <p/>
-         * TODO: the root list SHOULD depend on the currently selected project, to include
-         * custom classes.
-         */
-        ArrayList<String> getRoots() {
-            return mRoots;
-        }
-
-        /**
-         * If the generated resource XML file requires an "android" XMLNS, this should be set
-         * to {@link SdkConstants#NS_RESOURCES}. When it is null, no XMLNS is generated.
-         */
-        String getXmlns() {
-            return mXmlns;
-        }
-
-        /**
-         * When not null, this represent extra attributes that must be specified in the
-         * root element of the generated XML file. When null, no extra attributes are inserted.
-         */
-        String getDefaultAttrs() {
-            return mDefaultAttrs;
-        }
-    }
-
-    /**
-     * TypeInfo, information for each "type" of file that can be created.
-     */
-    private static final TypeInfo[] sTypes = {
-        new TypeInfo(
-                "Layout",                                           // UI name
-                "An XML file that describes a screen layout.",      // tooltip
-                ResourceFolderType.LAYOUT,                          // folder type
-                AndroidTargetData.DESCRIPTOR_LAYOUT,                // root seed
-                "LinearLayout",                                     // default root
-                SdkConstants.NS_RESOURCES,                          // xmlns
-                "android:layout_width=\"wrap_content\"\n" +         // default attributes
-                "android:layout_height=\"wrap_content\""
-                ),
-        new TypeInfo("Values",                                      // UI name
-                "An XML file with simple values: colors, strings, dimensions, etc.", // tooltip
-                ResourceFolderType.VALUES,                          // folder type
-                ResourcesDescriptors.ROOT_ELEMENT,                  // root seed
-                null,                                               // default root
-                null,                                               // xmlns
-                null                                                // default attributes
-                ),
-        new TypeInfo("Menu",                                        // UI name
-                "An XML file that describes an menu.",              // tooltip
-                ResourceFolderType.MENU,                            // folder type
-                MenuDescriptors.MENU_ROOT_ELEMENT,                  // root seed
-                null,                                               // default root
-                SdkConstants.NS_RESOURCES,                          // xmlns
-                null                                                // default attributes
-                ),
-        new TypeInfo("Preference",                                  // UI name
-                "An XML file that describes preferences.",          // tooltip
-                ResourceFolderType.XML,                             // folder type
-                AndroidTargetData.DESCRIPTOR_PREFERENCES,           // root seed
-                AndroidConstants.CLASS_PREFERENCE_SCREEN,           // default root
-                SdkConstants.NS_RESOURCES,                          // xmlns
-                null                                                // default attributes
-                ),
-        new TypeInfo("Searchable",                                  // UI name
-                "An XML file that describes a searchable [TODO].",  // tooltip
-                ResourceFolderType.XML,                             // folder type
-                AndroidTargetData.DESCRIPTOR_SEARCHABLE,            // root seed
-                null,                                               // default root
-                SdkConstants.NS_RESOURCES,                          // xmlns
-                null                                                // default attributes
-                ),
-        new TypeInfo("Animation",                                   // UI name
-                "An XML file that describes an animation.",         // tooltip
-                ResourceFolderType.ANIM,                            // folder type
-                // TODO reuse constants if we ever make an editor with descriptors for animations
-                new String[] {                                      // root seed
-                    "set",          //$NON-NLS-1$
-                    "alpha",        //$NON-NLS-1$
-                    "scale",        //$NON-NLS-1$
-                    "translate",    //$NON-NLS-1$
-                    "rotate"        //$NON-NLS-1$
-                    },
-                "set",              //$NON-NLS-1$                   // default root
-                null,                                               // xmlns
-                null                                                // default attributes
-                ),
-    };
-
-    /** Absolute destination folder root, e.g. "/res/" */
-    private static String sResFolderAbs = AndroidConstants.WS_RESOURCES + AndroidConstants.WS_SEP;
-    /** Relative destination folder root, e.g. "res/" */
-    private static String sResFolderRel = SdkConstants.FD_RESOURCES + AndroidConstants.WS_SEP;
-    
-    private IProject mProject;
-    private Text mProjectTextField;
-    private Button mProjectBrowseButton;
-    private Text mFileNameTextField;
-    private Text mWsFolderPathTextField;
-    private Combo mRootElementCombo;
-    private IStructuredSelection mInitialSelection;
-    private ConfigurationSelector mConfigSelector;
-    private FolderConfiguration mTempConfig = new FolderConfiguration();
-    private boolean mInternalWsFolderPathUpdate;
-    private boolean mInternalTypeUpdate;
-    private boolean mInternalConfigSelectorUpdate;
-    private ProjectChooserHelper mProjectChooserHelper;
-
-
-    // --- UI creation ---
-    
-    /**
-     * Constructs a new {@link NewXmlFileCreationPage}.
-     * <p/>
-     * Called by {@link NewXmlFileWizard#createMainPage()}.
-     */
-    protected NewXmlFileCreationPage(String pageName) {
-        super(pageName);
-        setPageComplete(false);
-    }
-
-    public void setInitialSelection(IStructuredSelection initialSelection) {
-        mInitialSelection = initialSelection;
-    }
-
-    /**
-     * Called by the parent Wizard to create the UI for this Wizard Page.
-     * 
-     * {@inheritDoc}
-     * 
-     * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
-     */
-    public void createControl(Composite parent) {
-        Composite composite = new Composite(parent, SWT.NULL);
-        composite.setFont(parent.getFont());
-
-        initializeDialogUnits(parent);
-
-        composite.setLayout(new GridLayout(3, false /*makeColumnsEqualWidth*/));
-        composite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        createProjectGroup(composite);
-        createTypeGroup(composite);
-        createRootGroup(composite);
-
-        // Show description the first time
-        setErrorMessage(null);
-        setMessage(null);
-        setControl(composite);
-
-        // Update state the first time
-        initializeRootValues();
-        initializeFromSelection(mInitialSelection);
-        validatePage();
-    }
-
-    /**
-     * Returns the target project or null.
-     */
-    public IProject getProject() {
-        return mProject;
-    }
-
-    /**
-     * Returns the destination filename or an empty string.
-     */
-    public String getFileName() {
-        return mFileNameTextField == null ? "" : mFileNameTextField.getText();         //$NON-NLS-1$
-    }
-
-    /**
-     * Returns the destination folder path relative to the project or an empty string.
-     */
-    public String getWsFolderPath() {
-        return mWsFolderPathTextField == null ? "" : mWsFolderPathTextField.getText(); //$NON-NLS-1$
-    }
-    
-
-    /**
-     * Returns an {@link IFile} on the destination file.
-     * <p/>
-     * Uses {@link #getProject()}, {@link #getWsFolderPath()} and {@link #getFileName()}.
-     * <p/>
-     * Returns null if the project, filename or folder are invalid and the destination file
-     * cannot be determined.
-     * <p/>
-     * The {@link IFile} is a resource. There might or might not be an actual real file.
-     */
-    public IFile getDestinationFile() {
-        IProject project = getProject();
-        String wsFolderPath = getWsFolderPath();
-        String fileName = getFileName();
-        if (project != null && wsFolderPath.length() > 0 && fileName.length() > 0) {
-            IPath dest = new Path(wsFolderPath).append(fileName);
-            IFile file = project.getFile(dest);
-            return file;
-        }
-        return null;
-    }
-
-    /**
-     * Returns the {@link TypeInfo} for the currently selected type radio button.
-     * Returns null if no radio button is selected.
-     * 
-     * @return A {@link TypeInfo} or null.
-     */
-    public TypeInfo getSelectedType() {
-        TypeInfo type = null;
-        for (TypeInfo ti : sTypes) {
-            if (ti.getWidget().getSelection()) {
-                type = ti;
-                break;
-            }
-        }
-        return type;
-    }
-    
-    /**
-     * Returns the selected root element string, if any.
-     * 
-     * @return The selected root element string or null.
-     */
-    public String getRootElement() {
-        int index = mRootElementCombo.getSelectionIndex();
-        if (index >= 0) {
-            return mRootElementCombo.getItem(index);
-        }
-        return null;
-    }
-
-    // --- UI creation ---
-
-    /**
-     * Helper method to create a new GridData with an horizontal span.
-     * 
-     * @param horizSpan The number of cells for the horizontal span.
-     * @return A new GridData with the horizontal span.
-     */
-    private GridData newGridData(int horizSpan) {
-        GridData gd = new GridData();
-        gd.horizontalSpan = horizSpan;
-        return gd;
-    }
-
-    /**
-     * Helper method to create a new GridData with an horizontal span and a style.
-     * 
-     * @param horizSpan The number of cells for the horizontal span.
-     * @param style The style, e.g. {@link GridData#FILL_HORIZONTAL}
-     * @return A new GridData with the horizontal span and the style.
-     */
-    private GridData newGridData(int horizSpan, int style) {
-        GridData gd = new GridData(style);
-        gd.horizontalSpan = horizSpan;
-        return gd;
-    }
-
-    /**
-     * Helper method that creates an empty cell in the parent composite.
-     * 
-     * @param parent The parent composite.
-     */
-    private void emptyCell(Composite parent) {
-        new Label(parent, SWT.NONE);
-    }
-
-    /**
-     * Creates the project & filename fields.
-     * <p/>
-     * The parent must be a GridLayout with 3 colums.
-     */
-    private void createProjectGroup(Composite parent) {
-        // project name
-        String tooltip = "The Android Project where the new resource file will be created.";
-        Label label = new Label(parent, SWT.NONE);
-        label.setText("Project");
-        label.setToolTipText(tooltip);
-
-        mProjectTextField = new Text(parent, SWT.BORDER);
-        mProjectTextField.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mProjectTextField.setToolTipText(tooltip);
-        mProjectTextField.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onProjectFieldUpdated();
-            }
-        });
-
-        mProjectBrowseButton = new Button(parent, SWT.NONE);
-        mProjectBrowseButton.setText("Browse...");
-        mProjectBrowseButton.setToolTipText("Allows you to select the Android project to modify.");
-        mProjectBrowseButton.addSelectionListener(new SelectionAdapter() {
-           @Override
-            public void widgetSelected(SelectionEvent e) {
-               onProjectBrowse();
-            }
-        });
-        mProjectChooserHelper = new ProjectChooserHelper(parent.getShell());
-
-        // file name
-        tooltip = "The name of the resource file to create.";
-        label = new Label(parent, SWT.NONE);
-        label.setText("File");
-        label.setToolTipText(tooltip);
-
-        mFileNameTextField = new Text(parent, SWT.BORDER);
-        mFileNameTextField.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mFileNameTextField.setToolTipText(tooltip);
-        mFileNameTextField.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                validatePage();
-            }
-        });
-
-        emptyCell(parent);
-    }
-
-    /**
-     * Creates the type field, {@link ConfigurationSelector} and the folder field.
-     * <p/>
-     * The parent must be a GridLayout with 3 colums.
-     */
-    private void createTypeGroup(Composite parent) {
-        // separator
-        Label label = new Label(parent, SWT.SEPARATOR | SWT.HORIZONTAL);
-        label.setLayoutData(newGridData(3, GridData.GRAB_HORIZONTAL));
-        
-        // label before type radios
-        label = new Label(parent, SWT.NONE);
-        label.setText("What type of resource would you like to create?");
-        label.setLayoutData(newGridData(3));
-
-        // display the types on three columns of radio buttons.
-        emptyCell(parent);
-        Composite grid = new Composite(parent, SWT.NONE);
-        emptyCell(parent);
-
-        grid.setLayout(new GridLayout(3, true /*makeColumnsEqualWidth*/));
-        
-        SelectionListener radioListener = new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                // single-click. Only do something if activated.
-                if (e.getSource() instanceof Button) {
-                    onRadioTypeUpdated((Button) e.getSource());
-                }
-            }
-        };
-        
-        int n = sTypes.length;
-        int num_lines = n/3;
-        for (int line = 0; line < num_lines; line++) {
-            for (int i = 0; i < 3; i++) {
-                TypeInfo type = sTypes[line * 3 + i];
-                Button radio = new Button(grid, SWT.RADIO);
-                type.setWidget(radio);
-                radio.setSelection(false);
-                radio.setText(type.getUiName());
-                radio.setToolTipText(type.getTooltip());
-                radio.addSelectionListener(radioListener);
-            }
-        }
-
-        // label before configuration selector
-        label = new Label(parent, SWT.NONE);
-        label.setText("What type of resource configuration would you like?");
-        label.setLayoutData(newGridData(3));
-
-        // configuration selector
-        emptyCell(parent);
-        mConfigSelector = new ConfigurationSelector(parent);
-        GridData gd = newGridData(2, GridData.GRAB_HORIZONTAL | GridData.GRAB_VERTICAL);
-        gd.widthHint = ConfigurationSelector.WIDTH_HINT;
-        gd.heightHint = ConfigurationSelector.HEIGHT_HINT;
-        mConfigSelector.setLayoutData(gd);
-        mConfigSelector.setOnChangeListener(new onConfigSelectorUpdated());
-        
-        // folder name
-        String tooltip = "The folder where the file will be generated, relative to the project.";
-        label = new Label(parent, SWT.NONE);
-        label.setText("Folder");
-        label.setToolTipText(tooltip);
-
-        mWsFolderPathTextField = new Text(parent, SWT.BORDER);
-        mWsFolderPathTextField.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mWsFolderPathTextField.setToolTipText(tooltip);
-        mWsFolderPathTextField.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent e) {
-                onWsFolderPathUpdated();
-            }
-        });
-
-        emptyCell(parent);
-    }
-
-    /**
-     * Creates the root element combo.
-     * <p/>
-     * The parent must be a GridLayout with 3 colums.
-     */
-    private void createRootGroup(Composite parent) {
-        // separator
-        Label label = new Label(parent, SWT.SEPARATOR | SWT.HORIZONTAL);
-        label.setLayoutData(newGridData(3, GridData.GRAB_HORIZONTAL));
-
-        // label before the root combo
-        String tooltip = "The root element to create in the XML file.";
-        label = new Label(parent, SWT.NONE);
-        label.setText("Select the root element for the XML file:");
-        label.setLayoutData(newGridData(3));
-        label.setToolTipText(tooltip);
-
-        // root combo
-        emptyCell(parent);
-
-        mRootElementCombo = new Combo(parent, SWT.DROP_DOWN | SWT.READ_ONLY);
-        mRootElementCombo.setEnabled(false);
-        mRootElementCombo.select(0);
-        mRootElementCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        mRootElementCombo.setToolTipText(tooltip);
-        
-        emptyCell(parent);
-    }
-
-    /**
-     * Called by {@link NewXmlFileWizard} to initialize the page with the selection
-     * received by the wizard -- typically the current user workbench selection.
-     * <p/>
-     * Things we expect to find out from the selection:
-     * <ul>
-     * <li>The project name, valid if it's an android nature.</li>
-     * <li>The current folder, valid if it's a folder under /res</li>
-     * <li>An existing filename, in which case the user will be asked whether to override it.</li>
-     * <ul>
-     * 
-     * @param selection The selection when the wizard was initiated.
-     */
-    private void initializeFromSelection(IStructuredSelection selection) {
-        if (selection == null) {
-            return;
-        }
-
-        
-        // Find the best match in the element list. In case there are multiple selected elements
-        // select the one that provides the most information and assign them a score,
-        // e.g. project=1 + folder=2 + file=4.
-        IProject targetProject = null;
-        String targetWsFolderPath = null;
-        String targetFileName = null;
-        int targetScore = 0;
-        for (Object element : selection.toList()) {
-            if (element instanceof IAdaptable) {
-                IResource res = (IResource) ((IAdaptable) element).getAdapter(IResource.class);
-                IProject project = res != null ? res.getProject() : null;
-                
-                // Is this an Android project?
-                try {
-                    if (project == null || !project.hasNature(AndroidConstants.NATURE)) {
-                        continue;
-                    }
-                } catch (CoreException e) {
-                    // checking the nature failed, ignore this resource
-                    continue;
-                }
-                
-                int score = 1; // we have a valid project at least
-
-                IPath wsFolderPath = null;
-                String fileName = null;
-                if (res.getType() == IResource.FOLDER) {
-                    wsFolderPath = res.getProjectRelativePath();                    
-                } else if (res.getType() == IResource.FILE) {
-                    fileName = res.getName();
-                    wsFolderPath = res.getParent().getProjectRelativePath();
-                }
-                
-                // Disregard this folder selection if it doesn't point to /res/something
-                if (wsFolderPath != null &&
-                        wsFolderPath.segmentCount() > 1 &&
-                        SdkConstants.FD_RESOURCES.equals(wsFolderPath.segment(0))) {
-                    score += 2;
-                } else {
-                    wsFolderPath = null;
-                    fileName = null;
-                }
-
-                score += fileName != null ? 4 : 0;
-                
-                if (score > targetScore) {
-                    targetScore = score;
-                    targetProject = project;
-                    targetWsFolderPath = wsFolderPath != null ? wsFolderPath.toString() : null;
-                    targetFileName = fileName;
-                }
-            }
-        }
-        
-        // Now set the UI accordingly
-        if (targetScore > 0) {
-            mProject = targetProject;
-            mProjectTextField.setText(targetProject != null ? targetProject.getName() : ""); //$NON-NLS-1$
-            mFileNameTextField.setText(targetFileName != null ? targetFileName : ""); //$NON-NLS-1$
-            mWsFolderPathTextField.setText(targetWsFolderPath != null ? targetWsFolderPath : ""); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Initialize the root values of the type infos based on the current framework values.
-     */
-    private void initializeRootValues() {
-        for (TypeInfo type : sTypes) {
-            // Clear all the roots for this type
-            ArrayList<String> roots = type.getRoots();
-            if (roots.size() > 0) {
-                roots.clear();
-            }
-            
-            // depending of the type of the seed, initialize the root in different ways
-            Object rootSeed = type.getRootSeed();
-
-            if (rootSeed instanceof String) {
-                // The seed is a single string, Add it as-is.
-                roots.add((String) rootSeed);
-            } else if (rootSeed instanceof String[]) {
-                // The seed is an array of strings. Add them as-is.
-                for (String value : (String[]) rootSeed) {
-                    roots.add(value);
-                }
-            } else if (rootSeed instanceof Integer && mProject != null) {
-                // The seed is a descriptor reference defined in AndroidTargetData.DESCRIPTOR_*
-                // In this case add all the children element descriptors defined, recursively,
-                // and avoid infinite recursion by keeping track of what has already been added.
-
-                // Note: if project is null, the root list will be empty since it has been
-                // cleared above.
-                
-                // get the AndroidTargetData from the project
-                IAndroidTarget target = Sdk.getCurrent().getTarget(mProject);
-                AndroidTargetData data = Sdk.getCurrent().getTargetData(target);
-                ElementDescriptor descriptor = data.getDescriptorProvider(
-                        (Integer)rootSeed).getDescriptor();
-                
-                HashSet<ElementDescriptor> visited = new HashSet<ElementDescriptor>();
-                initRootElementDescriptor(roots, descriptor, visited);
-
-                // Sort alphabetically.
-                Collections.sort(roots);
-            }
-        }
-    }
-
-    /**
-     * Helper method to recursively insert all XML names for the given {@link ElementDescriptor}
-     * into the roots array list. Keeps track of visited nodes to avoid infinite recursion.
-     * Also avoids inserting the top {@link DocumentDescriptor} which is generally synthetic
-     * and not a valid root element.
-     */
-    private void initRootElementDescriptor(ArrayList<String> roots,
-            ElementDescriptor desc, HashSet<ElementDescriptor> visited) {
-        if (!(desc instanceof DocumentDescriptor)) {
-            String xmlName = desc.getXmlName();
-            if (xmlName != null && xmlName.length() > 0) {
-                roots.add(xmlName);
-            }
-        }
-        
-        visited.add(desc);
-        
-        for (ElementDescriptor child : desc.getChildren()) {
-            if (!visited.contains(child)) {
-                initRootElementDescriptor(roots, child, visited);
-            }
-        }
-    }
-    
-    /**
-     * Callback called when the user edits the project text field.
-     */
-    private void onProjectFieldUpdated() {
-        String project = mProjectTextField.getText();
-        
-        // Is this a valid project?
-        IJavaProject[] projects = mProjectChooserHelper.getAndroidProjects(null /*javaModel*/);
-        IProject found = null;
-        for (IJavaProject p : projects) {
-            if (p.getProject().getName().equals(project)) {
-                found = p.getProject();
-                break;
-            }
-        }
-
-        if (found != mProject) {
-            mProject = found;
-
-            // update the Type with the new descriptors.
-            initializeRootValues();
-            
-            // update the combo
-            updateRootCombo(getSelectedType());
-            
-            validatePage();
-        }
-    }
-
-    /**
-     * Callback called when the user uses the "Browse Projects" button.
-     */
-    private void onProjectBrowse() {
-        IJavaProject p = mProjectChooserHelper.chooseJavaProject(mProjectTextField.getText());
-        if (p != null) {
-            mProject = p.getProject();
-            mProjectTextField.setText(mProject.getName());
-            
-            // update the Type with the new descriptors.
-            initializeRootValues();
-            
-            // update the combo
-            updateRootCombo(getSelectedType());
-            
-            validatePage();
-        }
-    } 
-
-    /**
-     * Callback called when the Folder text field is changed, either programmatically
-     * or by the user.
-     */
-    private void onWsFolderPathUpdated() {
-        if (mInternalWsFolderPathUpdate) {
-            return;
-        }
-
-        String wsFolderPath = mWsFolderPathTextField.getText();
-
-        // This is a custom path, we need to sanitize it.
-        // First it should start with "/res/". Then we need to make sure there are no
-        // relative paths, things like "../" or "./" or even "//".
-        wsFolderPath = wsFolderPath.replaceAll("/+\\.\\./+|/+\\./+|//+|\\\\+|^/+", "/");  //$NON-NLS-1$ //$NON-NLS-2$
-        wsFolderPath = wsFolderPath.replaceAll("^\\.\\./+|^\\./+", "");                   //$NON-NLS-1$ //$NON-NLS-2$
-        wsFolderPath = wsFolderPath.replaceAll("/+\\.\\.$|/+\\.$|/+$", "");               //$NON-NLS-1$ //$NON-NLS-2$
-
-        ArrayList<TypeInfo> matches = new ArrayList<TypeInfo>();
-
-        // We get "res/foo" from selections relative to the project when we want a "/res/foo" path.
-        if (wsFolderPath.startsWith(sResFolderRel)) {
-            wsFolderPath = sResFolderAbs + wsFolderPath.substring(sResFolderRel.length());
-            
-            mInternalWsFolderPathUpdate = true;
-            mWsFolderPathTextField.setText(wsFolderPath);
-            mInternalWsFolderPathUpdate = false;
-        }
-
-        if (wsFolderPath.startsWith(sResFolderAbs)) {
-            wsFolderPath = wsFolderPath.substring(sResFolderAbs.length());
-            
-            int pos = wsFolderPath.indexOf(AndroidConstants.WS_SEP_CHAR);
-            if (pos >= 0) {
-                wsFolderPath = wsFolderPath.substring(0, pos);
-            }
-
-            String[] folderSegments = wsFolderPath.split(FolderConfiguration.QUALIFIER_SEP);
-
-            if (folderSegments.length > 0) {
-                String folderName = folderSegments[0];
-
-                // update config selector
-                mInternalConfigSelectorUpdate = true;
-                mConfigSelector.setConfiguration(folderSegments);
-                mInternalConfigSelectorUpdate = false;
-
-                boolean selected = false;
-                for (TypeInfo type : sTypes) {
-                    if (type.getResFolderName().equals(folderName)) {
-                        matches.add(type);
-                        selected |= type.getWidget().getSelection();
-                    }
-                }
-
-                if (matches.size() == 1) {
-                    // If there's only one match, select it if it's not already selected
-                    if (!selected) {
-                        selectType(matches.get(0));
-                    }
-                } else if (matches.size() > 1) {
-                    // There are multiple type candidates for this folder. This can happen
-                    // for /res/xml for example. Check to see if one of them is currently
-                    // selected. If yes, leave the selection unchanged. If not, deselect all type.
-                    if (!selected) {
-                        selectType(null);
-                    }
-                } else {
-                    // Nothing valid was selected.
-                    selectType(null);
-                }
-            }
-        }
-
-        validatePage();
-    }
-
-    /**
-     * Callback called when one of the type radio button is changed.
-     * 
-     * @param typeWidget The type radio button that changed.
-     */
-    private void onRadioTypeUpdated(Button typeWidget) {
-        // Do nothing if this is an internal modification or if the widget has been
-        // de-selected.
-        if (mInternalTypeUpdate || !typeWidget.getSelection()) {
-            return;
-        }
-
-        // Find type info that has just been enabled.
-        TypeInfo type = null;
-        for (TypeInfo ti : sTypes) {
-            if (ti.getWidget() == typeWidget) {
-                type = ti;
-                break;
-            }
-        }
-        
-        if (type == null) {
-            return;
-        }
-
-        // update the combo
-        
-        updateRootCombo(type);
-
-        // update the folder path
-
-        String wsFolderPath = mWsFolderPathTextField.getText();
-        String newPath = null;
-
-        mConfigSelector.getConfiguration(mTempConfig);
-        ResourceQualifier qual = mTempConfig.getInvalidQualifier();
-        if (qual == null) {
-            // The configuration is valid. Reformat the folder path using the canonical
-            // value from the configuration.
-            
-            newPath = sResFolderAbs + mTempConfig.getFolderName(type.getResFolderType());
-        } else {
-            // The configuration is invalid. We still update the path but this time
-            // do it manually on the string.
-            if (wsFolderPath.startsWith(sResFolderAbs)) {
-                wsFolderPath.replaceFirst(
-                        "^(" + sResFolderAbs +")[^-]*(.*)",         //$NON-NLS-1$ //$NON-NLS-2$
-                        "\\1" + type.getResFolderName() + "\\2");   //$NON-NLS-1$ //$NON-NLS-2$
-            } else {
-                newPath = sResFolderAbs + mTempConfig.getFolderName(type.getResFolderType());
-            }
-        }
-
-        if (newPath != null && !newPath.equals(wsFolderPath)) {
-            mInternalWsFolderPathUpdate = true;
-            mWsFolderPathTextField.setText(newPath);
-            mInternalWsFolderPathUpdate = false;
-        }
-
-        validatePage();
-    }
-
-    /**
-     * Helper method that fills the values of the "root element" combo box based
-     * on the currently selected type radio button. Also disables the combo is there's
-     * only one choice. Always select the first root element for the given type.
-     * 
-     * @param type The currently selected {@link TypeInfo}. Cannot be null.
-     */
-    private void updateRootCombo(TypeInfo type) {
-        // reset all the values in the combo
-        mRootElementCombo.removeAll();
-
-        if (type != null) {
-            // get the list of roots. The list can be empty but not null.
-            ArrayList<String> roots = type.getRoots();
-            
-            // enable the combo if there's more than one choice
-            mRootElementCombo.setEnabled(roots != null && roots.size() > 1);
-            
-            for (String root : roots) {
-                mRootElementCombo.add(root);
-            }
-            
-            int index = 0; // default is to select the first one
-            String defaultRoot = type.getDefaultRoot();
-            if (defaultRoot != null) {
-                index = roots.indexOf(defaultRoot);
-            }
-            mRootElementCombo.select(index < 0 ? 0 : index);
-        }
-    }
-
-    /**
-     * Callback called when the configuration has changed in the {@link ConfigurationSelector}.
-     */
-    private class onConfigSelectorUpdated implements Runnable {
-        public void run() {
-            if (mInternalConfigSelectorUpdate) {
-                return;
-            }
-
-            TypeInfo type = getSelectedType();
-            
-            if (type != null) {
-                mConfigSelector.getConfiguration(mTempConfig);
-                StringBuffer sb = new StringBuffer(sResFolderAbs);
-                sb.append(mTempConfig.getFolderName(type.getResFolderType()));
-                
-                mInternalWsFolderPathUpdate = true;
-                mWsFolderPathTextField.setText(sb.toString());
-                mInternalWsFolderPathUpdate = false;
-                
-                validatePage();
-            }
-        }
-    }
-
-    /**
-     * Helper method to select on of the type radio buttons.
-     * 
-     * @param type The TypeInfo matching the radio button to selected or null to deselect them all.
-     */
-    private void selectType(TypeInfo type) {
-        if (type == null || !type.getWidget().getSelection()) {
-            mInternalTypeUpdate = true;
-            for (TypeInfo type2 : sTypes) {
-                type2.getWidget().setSelection(type2 == type);
-            }
-            updateRootCombo(type);
-            mInternalTypeUpdate = false;
-        }
-    }
-
-    /**
-     * Validates the fields, displays errors and warnings.
-     * Enables the finish button if there are no errors.
-     */
-    private void validatePage() {
-        String error = null;
-        String warning = null;
-
-        // -- validate project
-        if (getProject() == null) {
-            error = "Please select an Android project.";
-        }
-
-        // -- validate filename
-        if (error == null) {
-            String fileName = getFileName();
-            if (fileName == null || fileName.length() == 0) {
-                error = "A destination file name is required.";
-            } else if (!fileName.endsWith(AndroidConstants.DOT_XML)) {
-                error = String.format("The filename must end with %1$s.", AndroidConstants.DOT_XML);
-            }
-        }
-
-        // -- validate type
-        if (error == null) {
-            TypeInfo type = getSelectedType();
-
-            if (type == null) {
-                error = "One of the types must be selected (e.g. layout, values, etc.)";
-            }
-        }
-
-        // -- validate folder configuration
-        if (error == null) {
-            ConfigurationState state = mConfigSelector.getState();
-            if (state == ConfigurationState.INVALID_CONFIG) {
-                ResourceQualifier qual = mConfigSelector.getInvalidQualifier();
-                if (qual != null) {
-                    error = String.format("The qualifier '%1$s' is invalid in the folder configuration.",
-                            qual.getName());
-                }
-            } else if (state == ConfigurationState.REGION_WITHOUT_LANGUAGE) {
-                error = "The Region qualifier requires the Language qualifier.";
-            }
-        }
-
-        // -- validate generated path
-        if (error == null) {
-            String wsFolderPath = getWsFolderPath();
-            if (!wsFolderPath.startsWith(sResFolderAbs)) {
-                error = String.format("Target folder must start with %1$s.", sResFolderAbs);
-            }
-        }
-
-        // -- validate destination file doesn't exist
-        if (error == null) {
-            IFile file = getDestinationFile();
-            if (file != null && file.exists()) {
-                warning = "The destination file already exists";
-            }
-        }
-
-        // -- update UI & enable finish if there's no error
-        setPageComplete(error == null);
-        if (error != null) {
-            setMessage(error, WizardPage.ERROR);
-        } else if (warning != null) {
-            setMessage(warning, WizardPage.WARNING);
-        } else {
-            setErrorMessage(null);
-            setMessage(null);
-        }
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileWizard.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileWizard.java
deleted file mode 100644
index 125102b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/NewXmlFileWizard.java
+++ /dev/null
@@ -1,226 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.IconFactory;
-import com.android.ide.eclipse.editors.wizards.NewXmlFileCreationPage.TypeInfo;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.ui.INewWizard;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.ide.IDE;
-
-import java.io.ByteArrayInputStream;
-import java.io.InputStream;
-import java.io.UnsupportedEncodingException;
-
-/**
- * The "New Android XML File Wizard" provides the ability to create skeleton XML
- * resources files for Android projects.
- * <p/>
- * The wizard has one page, {@link NewXmlFileCreationPage}, used to select the project,
- * the resource folder, resource type and file name. It then creates the XML file.
- */
-public class NewXmlFileWizard extends Wizard implements INewWizard {
-
-    private static final String PROJECT_LOGO_LARGE = "android_large"; //$NON-NLS-1$
-    
-    protected static final String MAIN_PAGE_NAME = "newAndroidXmlFilePage"; //$NON-NLS-1$
-
-    private NewXmlFileCreationPage mMainPage;
-
-    public void init(IWorkbench workbench, IStructuredSelection selection) {
-        setHelpAvailable(false); // TODO have help
-        setWindowTitle("New Android XML File");
-        setImageDescriptor();
-
-        mMainPage = createMainPage();
-        mMainPage.setTitle("New Android XML File");
-        mMainPage.setDescription("Creates a new Android XML file.");
-        mMainPage.setInitialSelection(selection);
-    }
-    
-    /**
-     * Creates the wizard page.
-     * <p/>
-     * Please do NOT override this method.
-     * <p/>
-     * This is protected so that it can be overridden by unit tests.
-     * However the contract of this class is private and NO ATTEMPT will be made
-     * to maintain compatibility between different versions of the plugin.
-     */
-    protected NewXmlFileCreationPage createMainPage() {
-        return new NewXmlFileCreationPage(MAIN_PAGE_NAME);
-    }
-
-    // -- Methods inherited from org.eclipse.jface.wizard.Wizard --
-    //
-    // The Wizard class implements most defaults and boilerplate code needed by
-    // IWizard
-
-    /**
-     * Adds pages to this wizard.
-     */
-    @Override
-    public void addPages() {
-        addPage(mMainPage);
-    }
-
-    /**
-     * Performs any actions appropriate in response to the user having pressed
-     * the Finish button, or refuse if finishing now is not permitted: here, it
-     * actually creates the workspace project and then switch to the Java
-     * perspective.
-     *
-     * @return True
-     */
-    @Override
-    public boolean performFinish() {
-        IFile file = createXmlFile();
-        if (file == null) {
-            return false;
-        } else {
-            // Open the file in an editor
-            IWorkbenchWindow win = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-            if (win != null) {
-                IWorkbenchPage page = win.getActivePage();
-                if (page != null) {
-                    try {
-                        IDE.openEditor(page, file);
-                    } catch (PartInitException e) {
-                        AdtPlugin.log(e, "Failed to create %1$s: missing type",  //$NON-NLS-1$
-                                file.getFullPath().toString());
-                    }
-                }
-            }
-            return true;
-        }
-    }
-
-    // -- Custom Methods --
-    
-    private IFile createXmlFile() {
-        IFile file = mMainPage.getDestinationFile();
-        String name = file.getFullPath().toString();
-        boolean need_delete = false;
-
-        if (file.exists()) {
-            if (!AdtPlugin.displayPrompt("New Android XML File",
-                String.format("Do you want to overwrite the file %1$s ?", name))) {
-                // abort if user selects cancel.
-                return null;
-            }
-            need_delete = true;
-        } else {
-            createWsParentDirectory(file.getParent());
-        }
-        
-        TypeInfo type = mMainPage.getSelectedType();
-        if (type == null) {
-            // this is not expected to happen
-            AdtPlugin.log(IStatus.ERROR, "Failed to create %1$s: missing type", name);  //$NON-NLS-1$
-            return null;
-        }
-        String xmlns = type.getXmlns();
-        String root = mMainPage.getRootElement();
-        if (root == null) {
-            // this is not expected to happen
-            AdtPlugin.log(IStatus.ERROR, "Failed to create %1$s: missing root element", //$NON-NLS-1$
-                    file.toString());
-            return null;
-        }
-        
-        StringBuilder sb = new StringBuilder("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n");   //$NON-NLS-1$
-
-        sb.append('<').append(root);
-        if (xmlns != null) {
-            sb.append('\n').append("  xmlns:android=\"").append(xmlns).append("\"");  //$NON-NLS-1$ //$NON-NLS-2$
-        }
-        
-        String attrs = type.getDefaultAttrs();
-        if (attrs != null) {
-            sb.append("\n  ");                       //$NON-NLS-1$
-            sb.append(attrs.replace("\n", "\n  "));  //$NON-NLS-1$ //$NON-NLS-2$
-        }
-        
-        sb.append(">\n");                            //$NON-NLS-1$
-        sb.append("</").append(root).append(">\n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-        String result = sb.toString();
-        String error = null;
-        try {
-            byte[] buf = result.getBytes("UTF8");
-            InputStream stream = new ByteArrayInputStream(buf);
-            if (need_delete) {
-                file.delete(IFile.KEEP_HISTORY | IFile.FORCE, null /*monitor*/);
-            }
-            file.create(stream, true /*force*/, null /*progres*/);
-            return file;
-        } catch (UnsupportedEncodingException e) {
-            error = e.getMessage();
-        } catch (CoreException e) {
-            error = e.getMessage();
-        }
-
-        error = String.format("Failed to generate %1$s: %2$s", name, error);
-        AdtPlugin.displayError("New Android XML File", error);
-        return null;
-    }
-
-    private boolean createWsParentDirectory(IContainer wsPath) {
-        if (wsPath.getType() == IContainer.FOLDER) {
-            if (wsPath == null || wsPath.exists()) {
-                return true;
-            }
-
-            IFolder folder = (IFolder) wsPath;
-            try {
-                if (createWsParentDirectory(wsPath.getParent())) {
-                    folder.create(true /* force */, true /* local */, null /* monitor */);
-                    return true;
-                }
-            } catch (CoreException e) {
-                e.printStackTrace();
-            }
-        }
-        
-        return false;
-    }
-
-    /**
-     * Returns an image descriptor for the wizard logo.
-     */
-    private void setImageDescriptor() {
-        ImageDescriptor desc = IconFactory.getInstance().getImageDescriptor(PROJECT_LOGO_LARGE);
-        setDefaultPageImageDescriptor(desc);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ReferenceChooserDialog.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ReferenceChooserDialog.java
deleted file mode 100644
index 6913ce0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ReferenceChooserDialog.java
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.dialogs.DialogSettings;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.TreePath;
-import org.eclipse.jface.viewers.TreeSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.ui.dialogs.FilteredTree;
-import org.eclipse.ui.dialogs.PatternFilter;
-import org.eclipse.ui.dialogs.SelectionStatusDialog;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * A dialog to let the user choose a reference to a resource.
- *
- */
-public class ReferenceChooserDialog extends SelectionStatusDialog {
-
-    private static Pattern sResourcePattern = Pattern.compile("@(.*)/(.+)"); //$NON-NLS-1$
-    private static Pattern sInlineIdResourcePattern = Pattern.compile("@\\+id/(.+)"); //$NON-NLS-1$
-
-    private static IDialogSettings sDialogSettings = new DialogSettings("");
-    
-    private IResourceRepository mResources;
-    private String mCurrentResource;
-
-    private FilteredTree mFilteredTree;
-
-    /**
-     * @param parent
-     */
-    public ReferenceChooserDialog(IResourceRepository resources, Shell parent) {
-        super(parent);
-
-        int shellStyle = getShellStyle();
-        setShellStyle(shellStyle | SWT.MAX | SWT.RESIZE);
-
-        setTitle("Reference Dialog");
-        setMessage(String.format("Choose a resource"));
-        mResources = resources;
-        
-        setDialogBoundsSettings(sDialogSettings, getDialogBoundsStrategy());
-    }
-
-    public void setCurrentResource(String resource) {
-        mCurrentResource = resource;
-    }
-    
-    public String getCurrentResource() {
-        return mCurrentResource;
-    }
-
-
-    /* (non-Javadoc)
-     * @see org.eclipse.ui.dialogs.SelectionStatusDialog#computeResult()
-     */
-    @Override
-    protected void computeResult() {
-        // get the selection
-        TreePath treeSelection = getSelection();
-        if (treeSelection != null) {
-            if (treeSelection.getSegmentCount() == 2) {
-                // get the resource type and the resource item
-                ResourceType resourceType = (ResourceType)treeSelection.getFirstSegment();
-                ResourceItem resourceItem = (ResourceItem)treeSelection.getLastSegment();
-                
-                mCurrentResource = resourceType.getXmlString(resourceItem, false /* system */); 
-            }
-        }
-    }
-    
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite top = (Composite)super.createDialogArea(parent);
-
-        // create the standard message area
-        createMessageArea(top);
-
-        // create the filtered tree
-        createFilteredTree(top);
-        
-        // setup the initial selection
-        setupInitialSelection();
-        
-        return top;
-    }
-
-    private void createFilteredTree(Composite parent) {
-        mFilteredTree = new FilteredTree(parent, SWT.BORDER | SWT.SINGLE | SWT.FULL_SELECTION,
-                new PatternFilter());
-        
-        GridData data = new GridData();
-        data.widthHint = convertWidthInCharsToPixels(60);
-        data.heightHint = convertHeightInCharsToPixels(18);
-        data.grabExcessVerticalSpace = true;
-        data.grabExcessHorizontalSpace = true;
-        data.horizontalAlignment = GridData.FILL;
-        data.verticalAlignment = GridData.FILL;
-        mFilteredTree.setLayoutData(data);
-        mFilteredTree.setFont(parent.getFont());
-        
-        TreeViewer treeViewer = mFilteredTree.getViewer();
-        Tree tree = treeViewer.getTree();
-        
-        tree.addSelectionListener(new SelectionListener() {
-            public void widgetDefaultSelected(SelectionEvent e) {
-                handleDoubleClick();
-            }
-
-            public void widgetSelected(SelectionEvent e) {
-                handleSelection();
-            }
-        });
-        
-        treeViewer.setLabelProvider(new ResourceLabelProvider());
-        treeViewer.setContentProvider(new ResourceContentProvider(false /* fullLevels */));
-        treeViewer.setInput(mResources);
-    }
-
-    protected void handleSelection() {
-        validateCurrentSelection();
-    }
-
-    protected void handleDoubleClick() {
-        if (validateCurrentSelection()) {
-            buttonPressed(IDialogConstants.OK_ID);
-        }
-    }
-    
-    /**
-     * Returns the selected item in the tree as a {@link TreePath} object.
-     * @return the <code>TreePath</code> object or <code>null</code> if there was no selection.
-     */
-    private TreePath getSelection() {
-        ISelection selection = mFilteredTree.getViewer().getSelection();
-        if (selection instanceof TreeSelection) {
-            TreeSelection treeSelection = (TreeSelection)selection;
-            TreePath[] treePaths = treeSelection.getPaths();
-            
-            // the selection mode is SWT.SINGLE, so we just get the first one.
-            if (treePaths.length > 0) {
-                return treePaths[0];
-            }
-        }
-        
-        return null;
-    }
-    
-    private boolean validateCurrentSelection() {
-        TreePath treeSelection = getSelection();
-        
-        IStatus status;
-        if (treeSelection != null) {
-            if (treeSelection.getSegmentCount() == 2) {
-                status = new Status(IStatus.OK, AdtPlugin.PLUGIN_ID,
-                        IStatus.OK, "", //$NON-NLS-1$
-                        null);
-            } else {
-                status = new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                        IStatus.ERROR, "You must select a Resource Item",
-                        null);
-            }
-        } else {
-            status = new Status(IStatus.ERROR, AdtPlugin.PLUGIN_ID,
-                    IStatus.ERROR, "", //$NON-NLS-1$
-                    null);
-        }
-        
-        updateStatus(status);
-
-        return status.isOK();
-    }
-    
-    /**
-     * Sets up the initial selection.
-     * <p/>
-     * This parses {@link #mCurrentResource} to find out the resource type and the resource name.
-     */
-    private void setupInitialSelection() {
-        // checks the inline id pattern first as it's more restrictive than the other one.
-        Matcher m = sInlineIdResourcePattern.matcher(mCurrentResource);
-        if (m.matches()) {
-            // get the matching name
-            String resourceName = m.group(1);
-
-            // setup initial selection
-            setupInitialSelection(ResourceType.ID, resourceName);
-        } else {
-            // attempts the inline id pattern
-            m = sResourcePattern.matcher(mCurrentResource);
-            if (m.matches()) {
-                // get the resource type.
-                ResourceType resourceType = ResourceType.getEnum(m.group(1));
-                if (resourceType != null) {
-                    // get the matching name
-                    String resourceName = m.group(2);
-                    
-                    // setup initial selection
-                    setupInitialSelection(resourceType, resourceName);
-                }
-            }
-        }
-    }
-    
-    /**
-     * Sets up the initial selection based on a {@link ResourceType} and a resource name.
-     * @param resourceType the resource type.
-     * @param resourceName the resource name.
-     */
-    private void setupInitialSelection(ResourceType resourceType, String resourceName) {
-        // get all the resources of this type
-        ResourceItem[] resourceItems = mResources.getResources(resourceType);
-        
-        for (ResourceItem resourceItem : resourceItems) {
-            if (resourceName.equals(resourceItem.getName())) {
-                // name of the resource match, we select it,
-                TreePath treePath = new TreePath(new Object[] { resourceType, resourceItem });
-                mFilteredTree.getViewer().setSelection(new TreeSelection(treePath));
-                
-                // and we're done.
-                return;
-            }
-        }
-        
-        // if we get here, the resource type is valid, but the resource is missing.
-        // we select and expand the resource type element.
-        TreePath treePath = new TreePath(new Object[] { resourceType });
-        mFilteredTree.getViewer().setSelection(new TreeSelection(treePath));
-        mFilteredTree.getViewer().setExpandedState(resourceType, true /* expanded */);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceChooser.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceChooser.java
deleted file mode 100644
index 60a627b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceChooser.java
+++ /dev/null
@@ -1,193 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.AbstractElementListSelectionDialog;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * A dialog to let the user select a resource based on a resource type. 
- */
-public class ResourceChooser extends AbstractElementListSelectionDialog {
-
-    private Pattern mProjectResourcePattern;
-
-    private ResourceType mResourceType;
-
-    private IResourceRepository mProjectResources;
-
-    // TODO: enable when we can display the system resources.
-    // private Pattern mSystemResourcePattern;
-    // private IResourceRepository mSystemResources;
-    // private Button mProjectButton;
-    // private Button mSystemButton;
-    
-    private String mCurrentResource;
-    
-    /**
-     * Creates a Resource Chooser dialog.
-     * @param type The type of the resource to choose
-     * @param project The repository for the project
-     * @param system The System resource repository
-     * @param parent the parent shell
-     */
-    public ResourceChooser(ResourceType type, IResourceRepository project,
-            IResourceRepository system, Shell parent) {
-        super(parent, new ResourceLabelProvider());
-
-        mResourceType = type;
-        mProjectResources = project;
-        // TODO: enable when we can display the system resources.
-        // mSystemResources = system;
-        
-        mProjectResourcePattern = Pattern.compile(
-                "@" + mResourceType.getName() + "/(.+)"); //$NON-NLS-1$ //$NON-NLS-2$
-        // TODO: enable when we can display the system resources.
-        // mSystemResourcePattern = Pattern.compile(
-        //        "@android:" + mResourceType.getName() + "/(.+)"); //$NON-NLS-1$ //$NON-NLS-2$
-
-        setTitle("Resource Chooser");
-        setMessage(String.format("Choose a %1$s resource",
-                mResourceType.getDisplayName().toLowerCase()));
-    }
-    
-    public void setCurrentResource(String resource) {
-        mCurrentResource = resource;
-    }
-    
-    public String getCurrentResource() {
-        return mCurrentResource;
-    }
-
-    @Override
-    protected void computeResult() {
-        Object[] elements = getSelectedElements();
-        if (elements.length == 1 && elements[0] instanceof ResourceItem) {
-            ResourceItem item = (ResourceItem)elements[0];
-            
-            mCurrentResource = mResourceType.getXmlString(item,
-                    // TODO: enable when we can display the system resources.
-                    false /*mSystemButton.getSelection()*/); 
-        }
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite top = (Composite)super.createDialogArea(parent);
-
-        createMessageArea(top);
-
-        // TODO: enable when we can display the system resources.
-        // createButtons(top);
-        
-        createFilterText(top);
-        createFilteredList(top);
-        
-        setupResourceListAndCurrent();
-        
-        return top;
-    }
-
-    /**
-     * Creates the radio button to switch between project and system resources.
-     * @param top the parent composite
-     */
-    /* TODO: enable when we can display the system resources.
-    private void createButtons(Composite top) {
-        mProjectButton = new Button(top, SWT.RADIO);
-        mProjectButton.setText("Project Resources");
-        mProjectButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                setListElements(mProjectResources.getResources(mResourceType));
-            }
-        });
-        mSystemButton = new Button(top, SWT.RADIO);
-        mSystemButton.setText("System Resources");
-        mSystemButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                super.widgetSelected(e);
-                setListElements(mSystemResources.getResources(mResourceType));
-            }
-        });
-    }
-    */
-    
-    /**
-     * Setups the current list based on the current resource.
-     */
-    private void setupResourceListAndCurrent() {
-        if (setupInitialSelection(mProjectResourcePattern, mProjectResources) == false) {
-            // if we couldn't understand the current value, we default to the project resources
-            ResourceItem[] items = mProjectResources.getResources(mResourceType); 
-            setListElements(items);
-        }
-        /*
-         * TODO: enable when we can display the system resources.
-        if (setupInitialSelection(mProjectResourcePattern, mProjectResources) == false) {
-            if (setupInitialSelection(mSystemResourcePattern, mSystemResources) == false) {
-                // if we couldn't understand the current value, we default to the project resources
-                IResourceItem[] items = mProjectResources.getResources(mResourceType); 
-                setListElements(items);
-                mProjectButton.setSelection(true);
-            } else {
-                mSystemButton.setSelection(true);
-            }
-        } else {
-            mProjectButton.setSelection(true);
-        }*/
-    }
-    
-    /**
-     * Attempts to setup the list of element from a repository if the current resource
-     * matches the provided pattern. 
-     * @param pattern the pattern to test the current value
-     * @param repository the repository to use if the pattern matches.
-     * @return true if success.
-     */
-    private boolean setupInitialSelection(Pattern pattern, IResourceRepository repository) {
-        Matcher m = pattern.matcher(mCurrentResource);
-        if (m.matches()) {
-            // we have a project resource, let's setup the list
-            ResourceItem[] items = repository.getResources(mResourceType); 
-            setListElements(items);
-            
-            // and let's look for the item we found
-            String name = m.group(1);
-
-            for (ResourceItem item : items) {
-                if (name.equals(item.getName())) {
-                    setSelection(new Object[] { item });
-                    break;
-                }
-            }
-            return true;
-        }
-        return false;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceContentProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceContentProvider.java
deleted file mode 100644
index 7c6a539..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceContentProvider.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.common.resources.IResourceRepository;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.manager.ConfigurableResourceItem;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFile;
-
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-
-/**
- * Content provider for the Resource Explorer TreeView.
- * Each level of the tree is represented by a different class.
- * <ul>
- * <li>{@link ResourceType}. This represents the list of existing Resource Type present
- * in the resources. This can be matched to the subclasses inside the class <code>R</code>
- * </li>
- * <ul>
- * <li>{@link ResourceItem}. This represents one resource (which can existing in various alternate
- * versions). This is similar to the resource Ids defined as <code>R.sometype.id</code>.
- * </li>
- * <ul>
- * <li>{@link ResourceFile}. (optional) This represents a particular version of the
- * {@link ResourceItem}. It is displayed as a list of resource qualifier.
- * </li>
- * </ul> 
- * </ul> 
- * </ul> 
- * 
- * @see ResourceLabelProvider
- */
-public class ResourceContentProvider implements ITreeContentProvider {
-
-    /**
-     * The current ProjectResources being displayed.
-     */
-    private IResourceRepository mResources;
-    
-    private boolean mFullLevels;
-    
-   /**
-     * Constructs a new content providers for resource display.
-     * @param fullLevels if <code>true</code> the content provider will suppport all 3 levels. If
-     * <code>false</code>, only two levels are provided.
-     */
-    public ResourceContentProvider(boolean fullLevels) {
-        mFullLevels = fullLevels;
-    }
-
-    public Object[] getChildren(Object parentElement) {
-        if (parentElement instanceof ResourceType) {
-            return mResources.getResources((ResourceType)parentElement);
-        } else if (mFullLevels && parentElement instanceof ConfigurableResourceItem) {
-            return ((ConfigurableResourceItem)parentElement).getSourceFileArray();
-        }
-        return null;
-    }
-
-    public Object getParent(Object element) {
-        // pass
-        return null;
-    }
-
-    public boolean hasChildren(Object element) {
-        if (element instanceof ResourceType) {
-            return mResources.hasResources((ResourceType)element);
-        } else if (mFullLevels && element instanceof ConfigurableResourceItem) {
-            return ((ConfigurableResourceItem)element).hasAlternates();
-        }
-        return false;
-    }
-
-    public Object[] getElements(Object inputElement) {
-        if (inputElement instanceof IResourceRepository) {
-            if ((IResourceRepository)inputElement == mResources) {
-                // get the top level resources.
-                return mResources.getAvailableResourceTypes();
-            }
-        }
-
-        return new Object[0];
-    }
-
-    public void dispose() {
-        // pass
-    }
-
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        if (newInput instanceof IResourceRepository) {
-             mResources = (IResourceRepository)newInput;
-        }
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceLabelProvider.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceLabelProvider.java
deleted file mode 100644
index 024d084..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/wizards/ResourceLabelProvider.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.wizards;
-
-import com.android.ide.eclipse.common.resources.IIdResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceItem;
-import com.android.ide.eclipse.common.resources.ResourceType;
-import com.android.ide.eclipse.editors.resources.manager.ConfigurableResourceItem;
-import com.android.ide.eclipse.editors.resources.manager.IdResourceItem;
-import com.android.ide.eclipse.editors.resources.manager.ResourceFile;
-
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Label provider for the Resource Explorer TreeView.
- * Each level of the tree is represented by a different class.
- * <ul>
- * <li>{@link ResourceType}. This represents the list of existing Resource Type present
- * in the resources. This can be matched to the subclasses inside the class <code>R</code>
- * </li>
- * <ul>
- * <li>{@link ResourceItem}. This represents one resource. The actual type can be
- * {@link ConfigurableResourceItem} (which can exist in various alternate versions),
- * or {@link IdResourceItem}.
- * This is similar to the resource Ids defined as <code>R.sometype.id</code>.
- * </li>
- * <ul>
- * <li>{@link ResourceFile}. This represents a particular version of the {@link ResourceItem}.
- * It is displayed as a list of resource qualifier.
- * </li>
- * </ul> 
- * </ul> 
- * </ul> 
- * 
- * @see ResourceContentProvider
- */
-public class ResourceLabelProvider implements ILabelProvider, ITableLabelProvider {
-    private Image mWarningImage;
-    
-    public ResourceLabelProvider() {
-        mWarningImage = PlatformUI.getWorkbench().getSharedImages().getImageDescriptor(
-                ISharedImages.IMG_OBJS_WARN_TSK).createImage();
-    }
-
-    /**
-     * @see #getColumnImage(Object, int)
-     */
-    public Image getImage(Object element) {
-        // pass
-        return null;
-    }
-
-    /**
-     * @see #getColumnText(Object, int)
-     */
-    public String getText(Object element) {
-        return getColumnText(element, 0);
-    }
-
-    public void addListener(ILabelProviderListener listener) {
-        // pass
-    }
-
-    public void dispose() {
-        mWarningImage.dispose();
-    }
-
-    public boolean isLabelProperty(Object element, String property) {
-        return false;
-    }
-
-    public void removeListener(ILabelProviderListener listener) {
-        // pass
-    }
-
-    public Image getColumnImage(Object element, int columnIndex) {
-        if (columnIndex == 1) {
-            if (element instanceof ConfigurableResourceItem) {
-                ConfigurableResourceItem item = (ConfigurableResourceItem)element;
-                if (item.hasDefault() == false) {
-                    return mWarningImage;
-                }
-            }
-        }
-        return null;
-    }
-
-    public String getColumnText(Object element, int columnIndex) {
-        switch (columnIndex) {
-            case 0:
-                if (element instanceof ResourceType) {
-                    return ((ResourceType)element).getDisplayName();
-                } else if (element instanceof ResourceItem) {
-                    return ((ResourceItem)element).getName();
-                } else if (element instanceof ResourceFile) {
-                    return ((ResourceFile)element).getFolder().getConfiguration().toDisplayString();
-                }
-                break;
-            case 1:
-                if (element instanceof ConfigurableResourceItem) {
-                    ConfigurableResourceItem item = (ConfigurableResourceItem)element;
-                    int count = item.getAlternateCount();
-                    if (count > 0) {
-                        if (item.hasDefault()) {
-                            count++;
-                        }
-                        return String.format("%1$d version(s)", count);
-                    }
-                } else if (element instanceof IIdResourceItem) {
-                    IIdResourceItem idResource = (IIdResourceItem)element;
-                    if (idResource.isDeclaredInline()) {
-                        return "Declared inline";
-                    }
-                }
-                return null;
-        }
-        return null;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlContentAssist.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlContentAssist.java
deleted file mode 100644
index f28b523..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlContentAssist.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.xml;
-
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.editors.AndroidContentAssist;
-
-/**
- * Content Assist Processor for /res/xml XML files
- */
-class XmlContentAssist extends AndroidContentAssist {
-
-    /**
-     * Constructor for LayoutContentAssist 
-     */
-    public XmlContentAssist() {
-        super(AndroidTargetData.DESCRIPTOR_XML);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlEditor.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlEditor.java
deleted file mode 100644
index d7f6119..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlEditor.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.xml;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.adt.sdk.AndroidTargetData;
-import com.android.ide.eclipse.adt.sdk.Sdk;
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.editors.AndroidEditor;
-import com.android.ide.eclipse.editors.FirstElementParser;
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.uimodel.UiDocumentNode;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkConstants;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.FileEditorInput;
-import org.w3c.dom.Document;
-
-/**
- * Multi-page form editor for /res/xml XML files. 
- */
-public class XmlEditor extends AndroidEditor {
-
-    public static final String ID = AndroidConstants.EDITORS_NAMESPACE + ".xml.XmlEditor"; //$NON-NLS-1$
-
-    /** Root node of the UI element hierarchy */
-    private UiDocumentNode mUiRootNode;
-
-    /**
-     * Creates the form editor for resources XML files.
-     */
-    public XmlEditor() {
-        super();
-    }
-
-    /**
-     * Returns the root node of the UI element hierarchy, which here
-     * is the document node.
-     */
-    @Override
-    public UiDocumentNode getUiRootNode() {
-        return mUiRootNode;
-    }
-
-    // ---- Static ----
-
-    /**
-     * Indicates if this is a file that this {@link XmlEditor} can handle.
-     * <p/>
-     * The {@link XmlEditor} can handle XML files that have a <searchable> or
-     * <Preferences> root XML element with the adequate xmlns:android attribute.
-     * 
-     * @return True if the {@link XmlEditor} can handle that file.
-     */
-    public static boolean canHandleFile(IFile file) {
-        // we need the target of the file's project to access the descriptors.
-        IProject project = file.getProject();
-        IAndroidTarget target = Sdk.getCurrent().getTarget(project);
-        if (target != null) {
-            AndroidTargetData data = Sdk.getCurrent().getTargetData(target);
-        
-            FirstElementParser.Result result = FirstElementParser.parse(
-                    file.getLocation().toOSString(),
-                    SdkConstants.NS_RESOURCES);
-            
-            if (result != null) {
-                String name = result.getElement(); 
-                if (name != null && result.getXmlnsPrefix() != null) {
-                    DocumentDescriptor desc = data.getXmlDescriptors().getDescriptor();
-                    for (ElementDescriptor elem : desc.getChildren()) {
-                        if (elem.getXmlName().equals(name)) {
-                            // This is an element that this document can handle
-                            return true;
-                        }
-                    }
-                }
-            }
-        }
-        
-        return false;
-    }
-
-    // ---- Base Class Overrides ----
-
-    /**
-     * Returns whether the "save as" operation is supported by this editor.
-     * <p/>
-     * Save-As is a valid operation for the ManifestEditor since it acts on a
-     * single source file. 
-     *
-     * @see IEditorPart
-     */
-    @Override
-    public boolean isSaveAsAllowed() {
-        return true;
-    }
-
-    /**
-     * Create the various form pages.
-     */
-    @Override
-    protected void createFormPages() {
-        try {
-            addPage(new XmlTreePage(this));
-        } catch (PartInitException e) {
-            AdtPlugin.log(e, "Error creating nested page"); //$NON-NLS-1$
-        }
-        
-    }
-
-    /* (non-java doc)
-     * Change the tab/title name to include the project name.
-     */
-    @Override
-    protected void setInput(IEditorInput input) {
-        super.setInput(input);
-        if (input instanceof FileEditorInput) {
-            FileEditorInput fileInput = (FileEditorInput) input;
-            IFile file = fileInput.getFile();
-            setPartName(String.format("%1$s", file.getName()));
-        }
-    }
-    
-    /**
-     * Processes the new XML Model, which XML root node is given.
-     * 
-     * @param xml_doc The XML document, if available, or null if none exists.
-     */
-    @Override
-    protected void xmlModelChanged(Document xml_doc) {
-        // init the ui root on demand
-        initUiRootNode(false /*force*/);
-
-        mUiRootNode.loadFromXmlNode(xml_doc);
-        
-        super.xmlModelChanged(xml_doc);
-    }
-    
-    /**
-     * Creates the initial UI Root Node, including the known mandatory elements.
-     * @param force if true, a new UiRootNode is recreated even if it already exists.
-     */
-    @Override
-    protected void initUiRootNode(boolean force) {
-        // The root UI node is always created, even if there's no corresponding XML node.
-        if (mUiRootNode == null || force) {
-            Document doc = null;
-            if (mUiRootNode != null) {
-                doc = mUiRootNode.getXmlDocument();
-            }
-
-            // get the target data from the opened file (and its project)
-            AndroidTargetData data = getTargetData();
-
-            DocumentDescriptor desc;
-            if (data == null) {
-                desc = new DocumentDescriptor("temp", null /*children*/);
-            } else {
-                desc = data.getXmlDescriptors().getDescriptor();
-            }
-
-            mUiRootNode = (UiDocumentNode) desc.createUiNode();
-            mUiRootNode.setEditor(this);
-
-            onDescriptorsChanged(doc);
-        }
-    }
-
-    // ---- Local Methods ----
-
-    /**
-     * Reloads the UI manifest node from the XML, and calls the pages to update.
-     */
-    private void onDescriptorsChanged(Document document) {
-        if (document != null) {
-            mUiRootNode.loadFromXmlNode(document);
-        } else {
-            mUiRootNode.reloadFromXmlNode(mUiRootNode.getXmlNode());
-        }
-    }
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlSourceViewerConfig.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlSourceViewerConfig.java
deleted file mode 100644
index d25c812..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlSourceViewerConfig.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.xml;
-
-
-import com.android.ide.eclipse.editors.AndroidSourceViewerConfig;
-
-/**
- * Source Viewer Configuration that calls in XmlContentAssist.
- */
-public class XmlSourceViewerConfig extends AndroidSourceViewerConfig {
-
-    public XmlSourceViewerConfig() {
-        super(new XmlContentAssist());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlTreePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlTreePage.java
deleted file mode 100644
index 91ce6dd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/XmlTreePage.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.xml;
-
-import com.android.ide.eclipse.adt.AdtPlugin;
-import com.android.ide.eclipse.editors.ui.tree.UiTreeBlock;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * Page for the xml form editor.
- */
-public final class XmlTreePage extends FormPage {
-    /** Page id used for switching tabs programmatically */
-    public final static String PAGE_ID = "xml_tree_page"; //$NON-NLS-1$
-
-    /** Container editor */
-    XmlEditor mEditor;
-
-    public XmlTreePage(XmlEditor editor) {
-        super(editor, PAGE_ID, "Structure");  // tab's label, keep it short
-        mEditor = editor;
-    }
-
-    /**
-     * Creates the content in the form hosted in this page.
-     * 
-     * @param managedForm the form hosted in this page.
-     */
-    @Override
-    protected void createFormContent(IManagedForm managedForm) {
-        super.createFormContent(managedForm);
-        ScrolledForm form = managedForm.getForm();
-        form.setText("Android Xml");
-        form.setImage(AdtPlugin.getAndroidLogo());
-
-        UiElementNode rootNode = mEditor.getUiRootNode();
-        UiTreeBlock block = new UiTreeBlock(mEditor, rootNode,
-                true /* autoCreateRoot */,
-                null /* no element filters */,
-                "Xml Elements",
-                "List of all xml elements in this XML file.");
-        block.createContent(managedForm);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/descriptors/XmlDescriptors.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/descriptors/XmlDescriptors.java
deleted file mode 100644
index fa1370f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/editors/xml/descriptors/XmlDescriptors.java
+++ /dev/null
@@ -1,315 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.xml.descriptors;
-
-import com.android.ide.eclipse.common.AndroidConstants;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.DescriptorsUtils;
-import com.android.ide.eclipse.editors.descriptors.DocumentDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.IDescriptorProvider;
-import com.android.ide.eclipse.editors.descriptors.SeparatorAttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.XmlnsAttributeDescriptor;
-import com.android.ide.eclipse.editors.layout.descriptors.ViewElementDescriptor;
-import com.android.sdklib.SdkConstants;
-
-import java.util.ArrayList;
-import java.util.Map;
-
-
-/**
- * Description of the /res/xml structure.
- * Currently supports the <searchable> and <preferences> root nodes.
- */
-public final class XmlDescriptors implements IDescriptorProvider {
-
-    // Public attributes names, attributes descriptors and elements descriptors referenced
-    // elsewhere.
-    public static final String PREF_KEY_ATTR = "key"; //$NON-NLS-1$
-
-    /** The root document descriptor for both searchable and preferences. */
-    private DocumentDescriptor mDescriptor = new DocumentDescriptor("xml_doc", null /* children */); //$NON-NLS-1$ 
-
-    /** The root document descriptor for searchable. */
-    private DocumentDescriptor mSearchDescriptor = new DocumentDescriptor("xml_doc", null /* children */); //$NON-NLS-1$ 
-
-    /** The root document descriptor for preferences. */
-    private DocumentDescriptor mPrefDescriptor = new DocumentDescriptor("xml_doc", null /* children */); //$NON-NLS-1$ 
-
-    /** @return the root descriptor for both searchable and preferences. */
-    public DocumentDescriptor getDescriptor() {
-        return mDescriptor;
-    }
-    
-    public ElementDescriptor[] getRootElementDescriptors() {
-        return mDescriptor.getChildren();
-    }
-    
-    /** @return the root descriptor for searchable. */
-    public DocumentDescriptor getSearchableDescriptor() {
-        return mSearchDescriptor;
-    }
-    
-    /** @return the root descriptor for preferences. */
-    public DocumentDescriptor getPreferencesDescriptor() {
-        return mPrefDescriptor;
-    }
-    
-    public IDescriptorProvider getSearchableProvider() {
-        return new IDescriptorProvider() {
-            public ElementDescriptor getDescriptor() {
-                return mSearchDescriptor;
-            }
-
-            public ElementDescriptor[] getRootElementDescriptors() {
-                return mSearchDescriptor.getChildren();
-            }
-        };
-    }
-
-    public IDescriptorProvider getPreferencesProvider() {
-        return new IDescriptorProvider() {
-            public ElementDescriptor getDescriptor() {
-                return mPrefDescriptor;
-            }
-
-            public ElementDescriptor[] getRootElementDescriptors() {
-                return mPrefDescriptor.getChildren();
-            }
-        };
-    }
-
-    /**
-     * Updates the document descriptor.
-     * <p/>
-     * It first computes the new children of the descriptor and then updates them
-     * all at once.
-     * 
-     * @param searchableStyleMap The map style=>attributes for <searchable> from the attrs.xml file
-     * @param prefs The list of non-group preference descriptions 
-     * @param prefGroups The list of preference group descriptions
-     */
-    public synchronized void updateDescriptors(
-            Map<String, DeclareStyleableInfo> searchableStyleMap,
-            ViewClassInfo[] prefs, ViewClassInfo[] prefGroups) {
-
-        XmlnsAttributeDescriptor xmlns = new XmlnsAttributeDescriptor(
-                "android", //$NON-NLS-1$
-                SdkConstants.NS_RESOURCES); 
-
-        ElementDescriptor searchable = createSearchable(searchableStyleMap, xmlns);
-        ElementDescriptor preferences = createPreference(prefs, prefGroups, xmlns);
-        ArrayList<ElementDescriptor> list =  new ArrayList<ElementDescriptor>();
-        if (searchable != null) {
-            list.add(searchable);
-            mSearchDescriptor.setChildren(new ElementDescriptor[]{ searchable });
-        }
-        if (preferences != null) {
-            list.add(preferences);
-            mPrefDescriptor.setChildren(new ElementDescriptor[]{ preferences });
-        }
-
-        if (list.size() > 0) {
-            mDescriptor.setChildren(list.toArray(new ElementDescriptor[list.size()]));
-        }
-    }
-
-    //-------------------------
-    // Creation of <searchable>
-    //-------------------------
-    
-    /**
-     * Returns the new ElementDescriptor for <searchable>
-     */
-    private ElementDescriptor createSearchable(
-            Map<String, DeclareStyleableInfo> searchableStyleMap,
-            XmlnsAttributeDescriptor xmlns) {
-
-        ElementDescriptor action_key = createElement(searchableStyleMap,
-                "SearchableActionKey", //$NON-NLS-1$ styleName
-                "actionkey", //$NON-NLS-1$ xmlName
-                "Action Key", // uiName
-                null, // sdk url
-                null, // extraAttribute
-                null, // childrenElements
-                false /* mandatory */ );
-
-        ElementDescriptor searchable = createElement(searchableStyleMap,
-                "Searchable", //$NON-NLS-1$ styleName
-                "searchable", //$NON-NLS-1$ xmlName
-                "Searchable", // uiName
-                null, // sdk url
-                xmlns, // extraAttribute
-                new ElementDescriptor[] { action_key }, // childrenElements
-                false /* mandatory */ );
-        return searchable;
-    }
-
-    /**
-     * Returns a new ElementDescriptor constructed from the information given here
-     * and the javadoc & attributes extracted from the style map if any.
-     */
-    private ElementDescriptor createElement(
-            Map<String, DeclareStyleableInfo> styleMap, String styleName,
-            String xmlName, String uiName, String sdkUrl,
-            AttributeDescriptor extraAttribute,
-            ElementDescriptor[] childrenElements, boolean mandatory) {
-
-        ElementDescriptor element = new ElementDescriptor(xmlName, uiName, null, sdkUrl,
-                null, childrenElements, mandatory);
-
-        return updateElement(element, styleMap, styleName, extraAttribute);
-    }
-
-    /**
-     * Updates an ElementDescriptor with the javadoc & attributes extracted from the style
-     * map if any.
-     */
-    private ElementDescriptor updateElement(ElementDescriptor element,
-            Map<String, DeclareStyleableInfo> styleMap,
-            String styleName,
-            AttributeDescriptor extraAttribute) {
-        ArrayList<AttributeDescriptor> descs = new ArrayList<AttributeDescriptor>();
-
-        DeclareStyleableInfo style = styleMap != null ? styleMap.get(styleName) : null;
-        if (style != null) {
-            DescriptorsUtils.appendAttributes(descs,
-                    null,   // elementName
-                    SdkConstants.NS_RESOURCES,
-                    style.getAttributes(),
-                    null,   // requiredAttributes
-                    null);  // overrides
-            element.setTooltip(style.getJavaDoc());
-        }
-
-        if (extraAttribute != null) {
-            descs.add(extraAttribute);
-        }
-
-        element.setAttributes(descs.toArray(new AttributeDescriptor[descs.size()]));
-        return element;
-    }
-
-    //--------------------------
-    // Creation of <Preferences>
-    //--------------------------
-
-    /**
-     * Returns the new ElementDescriptor for <Preferences>
-     */
-    private ElementDescriptor createPreference(ViewClassInfo[] prefs,
-            ViewClassInfo[] prefGroups, XmlnsAttributeDescriptor xmlns) {
-
-        ArrayList<ElementDescriptor> newPrefs = new ArrayList<ElementDescriptor>();
-        if (prefs != null) {
-            for (ViewClassInfo info : prefs) {
-                ElementDescriptor desc = convertPref(info);
-                newPrefs.add(desc);
-            }
-        }
-
-        ElementDescriptor topPreferences = null;
-        
-        ArrayList<ElementDescriptor> newGroups = new ArrayList<ElementDescriptor>();
-        if (prefGroups != null) {
-            for (ViewClassInfo info : prefGroups) {
-                ElementDescriptor desc = convertPref(info);
-                newGroups.add(desc);
-                
-                if (info.getCanonicalClassName() == AndroidConstants.CLASS_PREFERENCES) {
-                    topPreferences = desc;
-                }
-            }
-        }
-
-        ArrayList<ElementDescriptor> everything = new ArrayList<ElementDescriptor>();
-        everything.addAll(newGroups);
-        everything.addAll(newPrefs);
-        ElementDescriptor[] newArray = everything.toArray(new ElementDescriptor[everything.size()]);
-
-        // Link all groups to everything else here.. recursively
-        for (ElementDescriptor layoutDesc : newGroups) {
-            layoutDesc.setChildren(newArray);
-        }
-
-        // The "top" element to be returned corresponds to the class "Preferences".
-        // Its descriptor has already been created. However the root one also needs
-        // the hidden xmlns:android definition..
-        if (topPreferences != null) {
-            AttributeDescriptor[] attrs = topPreferences.getAttributes();
-            AttributeDescriptor[] newAttrs = new AttributeDescriptor[attrs.length + 1];
-            System.arraycopy(attrs, 0, newAttrs, 0, attrs.length);
-            newAttrs[attrs.length] = xmlns;
-            return new ElementDescriptor(
-                    topPreferences.getXmlName(),
-                    topPreferences.getUiName(),
-                    topPreferences.getTooltip(),
-                    topPreferences.getSdkUrl(),
-                    newAttrs,
-                    topPreferences.getChildren(),
-                    false /* mandatory */);
-        } else {
-            return null;
-        }
-    }
-
-    /**
-     * Creates an element descriptor from a given {@link ViewClassInfo}.
-     */
-    private ElementDescriptor convertPref(ViewClassInfo info) {
-        String xml_name = info.getShortClassName();
-        String tooltip = info.getJavaDoc();
-        
-        // Process all Preference attributes
-        ArrayList<AttributeDescriptor> attributes = new ArrayList<AttributeDescriptor>();
-        DescriptorsUtils.appendAttributes(attributes,
-                null,   // elementName
-                SdkConstants.NS_RESOURCES,
-                info.getAttributes(),
-                null,   // requiredAttributes
-                null);  // overrides
-        
-        for (ViewClassInfo link = info.getSuperClass();
-                link != null;
-                link = link.getSuperClass()) {
-            AttributeInfo[] attrList = link.getAttributes();
-            if (attrList.length > 0) {
-                attributes.add(new SeparatorAttributeDescriptor(
-                        String.format("Attributes from %1$s", link.getShortClassName()))); 
-                DescriptorsUtils.appendAttributes(attributes,
-                        null,   // elementName
-                        SdkConstants.NS_RESOURCES,
-                        attrList,
-                        null,   // requiredAttributes
-                        null);  // overrides
-            }
-        }
-
-        return new ViewElementDescriptor(xml_name,
-                xml_name, // ui_name
-                info.getCanonicalClassName(),
-                tooltip,
-                null, // sdk_url
-                attributes.toArray(new AttributeDescriptor[attributes.size()]),
-                null,
-                null, // children
-                false /* mandatory */);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/AndroidManifest.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/AndroidManifest.template
deleted file mode 100644
index b43e75f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/AndroidManifest.template
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-      package="PACKAGE"
-      android:versionCode="1"
-      android:versionName="1.0">
-    <application android:icon="@drawable/icon" android:label="APPLICATION_NAME">
-ACTIVITIES
-    </application>
-USES-SDK
-</manifest> 
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/activity.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/activity.template
deleted file mode 100644
index e91d602..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/activity.template
+++ /dev/null
@@ -1,7 +0,0 @@
-        <activity android:name=".ACTIVITY_NAME"
-                  android:label="APPLICATION_NAME">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-INTENT_FILTERS
-            </intent-filter>
-        </activity>
\ No newline at end of file
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/icon.png b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/icon.png
deleted file mode 100644
index 7502484..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/icon.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/java_file.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/java_file.template
deleted file mode 100644
index 173ff96..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/java_file.template
+++ /dev/null
@@ -1,13 +0,0 @@
-package PACKAGE;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class ACTIVITY_NAME extends Activity {
-    /** Called when the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState) {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.main);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/launcher_intent_filter.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/launcher_intent_filter.template
deleted file mode 100644
index f5681be..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/launcher_intent_filter.template
+++ /dev/null
@@ -1 +0,0 @@
-                <category android:name="android.intent.category.LAUNCHER" />
\ No newline at end of file
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/layout.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/layout.template
deleted file mode 100644
index 5f4c383..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/layout.template
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    >
-<TextView  
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content" 
-    android:text="@string/hello"
-    />
-</LinearLayout>
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/preference_intent_filter.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/preference_intent_filter.template
deleted file mode 100644
index 609bb2c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/preference_intent_filter.template
+++ /dev/null
@@ -1 +0,0 @@
-                <category android:name="android.intent.category.PREFERENCE" />
\ No newline at end of file
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/string.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/string.template
deleted file mode 100644
index 3a6e4b2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/string.template
+++ /dev/null
@@ -1 +0,0 @@
-    <string name="STRING_NAME">STRING_CONTENT</string>
\ No newline at end of file
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/strings.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/strings.template
deleted file mode 100644
index b980ace..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/strings.template
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
-STRINGS
-</resources>
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/uses-sdk.template b/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/uses-sdk.template
deleted file mode 100644
index 8adae71..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/templates/uses-sdk.template
+++ /dev/null
@@ -1 +0,0 @@
-    <uses-sdk android:minSdkVersion="MIN_SDK_VERSION" />
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.classpath b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.classpath
deleted file mode 100644
index 280621c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.classpath
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-	<classpathentry kind="lib" path="libs/jfreechart-1.0.9.jar"/>
-	<classpathentry kind="lib" path="libs/jcommon-1.0.12.jar"/>
-	<classpathentry kind="lib" path="libs/jfreechart-1.0.9-swt.jar"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.project b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.project
deleted file mode 100644
index 2e9f996..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>ddms-plugin</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.ManifestBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.SchemaBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.PluginNature</nature>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/META-INF/MANIFEST.MF b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/META-INF/MANIFEST.MF
deleted file mode 100644
index 09b8085..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,23 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Dalvik Debug Monitor Service
-Bundle-SymbolicName: com.android.ide.eclipse.ddms;singleton:=true
-Bundle-Version: 0.9.0.qualifier
-Bundle-Activator: com.android.ide.eclipse.ddms.DdmsPlugin
-Bundle-Vendor: The Android Open Source Project
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.eclipse.ui.console
-Eclipse-LazyStart: true
-Export-Package: com.android.ddmlib,
- com.android.ddmlib.log,
- com.android.ddmlib.testrunner,
- com.android.ddmuilib,
- com.android.ddmuilib.console,
- com.android.ide.eclipse.ddms,
- com.android.ide.eclipse.ddms.views
-Bundle-ClassPath: libs/jcommon-1.0.12.jar,
- libs/jfreechart-1.0.9.jar,
- libs/jfreechart-1.0.9-swt.jar,
- .
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/MODULE_LICENSE_APACHE2 b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/build.properties b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/build.properties
deleted file mode 100644
index 1c4c896..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/build.properties
+++ /dev/null
@@ -1,10 +0,0 @@
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               icons/,\
-               plugin.xml,\
-               ., \
-               libs/jcommon-1.0.12.jar,\
-               libs/jfreechart-1.0.9-swt.jar,\
-               libs/jfreechart-1.0.9.jar
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/android.png b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/android.png
deleted file mode 100644
index 3779d4d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/android.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/capture.png b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/capture.png
deleted file mode 100644
index d75e7a9..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/icons/capture.png
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/plugin.xml b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/plugin.xml
deleted file mode 100644
index 27fadf2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/plugin.xml
+++ /dev/null
@@ -1,102 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
-   <extension
-         point="org.eclipse.ui.views">
-      <category
-            name="Android"
-            id="com.android.ide.eclipse.ddms.views.category">
-      </category>
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.DeviceView"
-            icon="icons/device.png"
-            id="com.android.ide.eclipse.ddms.views.DeviceView"
-            name="Devices">
-      </view>
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.LogCatView"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.ddms.views.LogCatView"
-            name="LogCat"/>
-      <!-- Disabled for now due to AWT/SWT bridge issue on Leopard.
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.EventLogView"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.ddms.views.EventLogView"
-            name="Event Log"/> -->
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.ThreadView"
-            icon="icons/thread.png"
-            id="com.android.ide.eclipse.ddms.views.ThreadView"
-            name="Threads"/>
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.HeapView"
-            icon="icons/heap.png"
-            id="com.android.ide.eclipse.ddms.views.HeapView"
-            name="Heap"/>
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.FileExplorerView"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.ddms.views.FileExplorerView"
-            name="File Explorer"/>
-      <view
-            allowMultiple="false"
-            category="com.android.ide.eclipse.ddms.views.category"
-            class="com.android.ide.eclipse.ddms.views.EmulatorControlView"
-            icon="icons/emulator.png"
-            id="com.android.ide.eclipse.ddms.views.EmulatorControlView"
-            name="Emulator Control"/>
-   </extension>
-   <extension
-         point="org.eclipse.ui.perspectives">
-      <perspective
-            class="com.android.ide.eclipse.ddms.Perspective"
-            icon="icons/android.png"
-            id="com.android.ide.eclipse.ddms.Perspective"
-            name="DDMS"/>
-   </extension>
-   <extension
-         point="org.eclipse.core.runtime.preferences">
-      <initializer class="com.android.ide.eclipse.ddms.preferences.PreferenceInitializer"/>
-   </extension>
-   <extension
-         point="org.eclipse.ui.perspectiveExtensions">
-      <perspectiveExtension targetID="org.eclipse.jdt.ui.JavaPerspective">
-         <perspectiveShortcut id="com.android.ide.eclipse.ddms.Perspective"/>
-      </perspectiveExtension>
-      <perspectiveExtension targetID="org.eclipse.ui.resourcePerspective">
-         <perspectiveShortcut id="com.android.ide.eclipse.ddms.Perspective"/>
-      </perspectiveExtension>
-      <perspectiveExtension targetID="org.eclipse.debug.ui.DebugPerspective">
-         <perspectiveShortcut id="com.android.ide.eclipse.ddms.Perspective"/>
-         <view id="com.android.ide.eclipse.ddms.views.LogCatView"
-	         relative="org.eclipse.ui.views.ProblemView"
-	         relationship="stack" />
-      </perspectiveExtension>
-   </extension>
-   <extension
-         point="org.eclipse.ui.preferencePages">
-      <page
-            category="com.android.ide.eclipse.preferences.main"
-            class="com.android.ide.eclipse.ddms.preferences.PreferencePage"
-            id="com.android.ide.eclipse.ddms.preferences.PreferencePage"
-            name="DDMS"/>
-      <page
-            category="com.android.ide.eclipse.preferences.main"
-            class="com.android.ide.eclipse.ddms.preferences.LogCatPreferencePage"
-            id="com.android.ide.eclipse.ddms.preferences.LogCatPreferencePage"
-            name="LogCat"/>
-   </extension>
-</plugin>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/CommonAction.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/CommonAction.java
deleted file mode 100644
index 30ca4cb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/CommonAction.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package com.android.ide.eclipse.ddms;
-
-import com.android.ddmuilib.actions.ICommonAction;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.resource.ImageDescriptor;
-
-/**
- * Basic action extending the jFace Action class in order to implement
- * ICommonAction.
- */
-public class CommonAction extends Action implements ICommonAction {
-    
-    private Runnable mRunnable;
-
-    public CommonAction() {
-        super();
-    }
-
-    public CommonAction(String text) {
-        super(text);
-    }
-
-    /**
-     * @param text
-     * @param image
-     */
-    public CommonAction(String text, ImageDescriptor image) {
-        super(text, image);
-    }
-
-    /**
-     * @param text
-     * @param style
-     */
-    public CommonAction(String text, int style) {
-        super(text, style);
-    }
-    
-    @Override
-    public void run() {
-        if (mRunnable != null) {
-            mRunnable.run();
-        }
-    }
-    
-    /**
-     * Sets the {@link Runnable}.
-     * @see ICommonAction#setRunnable(Runnable)
-     */
-    public void setRunnable(Runnable runnable) {
-        mRunnable = runnable;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/DdmsPlugin.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/DdmsPlugin.java
deleted file mode 100644
index ccadce6..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/DdmsPlugin.java
+++ /dev/null
@@ -1,565 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.DdmPreferences;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.AndroidDebugBridge.IDeviceChangeListener;
-import com.android.ddmlib.Log.ILogOutput;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.DdmUiPreferences;
-import com.android.ddmuilib.DevicePanel.IUiSelectionListener;
-import com.android.ide.eclipse.ddms.preferences.PreferenceInitializer;
-import com.android.ide.eclipse.ddms.views.DeviceView;
-
-import org.eclipse.core.runtime.Preferences;
-import org.eclipse.core.runtime.Preferences.IPropertyChangeListener;
-import org.eclipse.core.runtime.Preferences.PropertyChangeEvent;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWTException;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.console.ConsolePlugin;
-import org.eclipse.ui.console.IConsole;
-import org.eclipse.ui.console.MessageConsole;
-import org.eclipse.ui.console.MessageConsoleStream;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-import java.util.ArrayList;
-import java.util.Calendar;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public final class DdmsPlugin extends AbstractUIPlugin implements IDeviceChangeListener,
-        IUiSelectionListener {
-
-    // The plug-in ID
-    public static final String PLUGIN_ID = "com.android.ide.eclipse.ddms"; // $NON-NLS-1$
-
-    private static final String ADB_LOCATION = PLUGIN_ID + ".adb"; // $NON-NLS-1$
-
-    /** The singleton instance */
-    private static DdmsPlugin sPlugin;
-
-    /** Location of the adb command line executable */
-    private static String sAdbLocation;
-
-    /**
-     * Debug Launcher for already running apps
-     */
-    private static IDebugLauncher sRunningAppDebugLauncher;
-
-    /** Console for DDMS log message */
-    private MessageConsole mDdmsConsole;
-
-    /** Image loader object */
-    private ImageLoader mLoader;
-    
-    private Device mCurrentDevice;
-    private Client mCurrentClient;
-    private boolean mListeningToUiSelection = false;
-    
-    private final ArrayList<ISelectionListener> mListeners = new ArrayList<ISelectionListener>();
-
-    private Color mRed;
-
-    private boolean mDdmlibInitialized;
-
-    /**
-     * Interface to provide debugger launcher for running apps.
-     */
-    public interface IDebugLauncher {
-        public boolean debug(String packageName, int port);
-    }
-    
-    /**
-     * Classes which implement this interface provide methods that deals
-     * with {@link Device} and {@link Client} selectionchanges.
-     */
-    public interface ISelectionListener {
-        
-        /**
-         * Sent when a new {@link Client} is selected.
-         * @param selectedClient The selected client. If null, no clients are selected.
-         */
-        public void selectionChanged(Client selectedClient);
-        
-        /**
-         * Sent when a new {@link Device} is selected.
-         * @param selectedDevice the selected device. If null, no devices are selected.
-         */
-        public void selectionChanged(Device selectedDevice);
-    }
-
-    /**
-     * The constructor
-     */
-    public DdmsPlugin() {
-        sPlugin = this;
-    }
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        
-        final Display display = getDisplay();
-
-        // get the eclipse store
-        final IPreferenceStore eclipseStore = getPreferenceStore();
-
-        AndroidDebugBridge.addDeviceChangeListener(this);
-        
-        DdmUiPreferences.setStore(eclipseStore);
-
-        //DdmUiPreferences.displayCharts();
-
-        // set the consoles.
-        mDdmsConsole = new MessageConsole("DDMS", null); // $NON-NLS-1$
-        ConsolePlugin.getDefault().getConsoleManager().addConsoles(
-                new IConsole[] {
-                    mDdmsConsole
-                });
-
-        final MessageConsoleStream consoleStream = mDdmsConsole.newMessageStream();
-        final MessageConsoleStream errorConsoleStream = mDdmsConsole.newMessageStream();
-        mRed = new Color(display, 0xFF, 0x00, 0x00);
-
-        // because this can be run, in some cases, by a non UI thread, and because
-        // changing the console properties update the UI, we need to make this change
-        // in the UI thread.
-        display.asyncExec(new Runnable() {
-            public void run() {
-                errorConsoleStream.setColor(mRed);
-            }
-        });
-
-        // set up the ddms log to use the ddms console.
-        Log.setLogOutput(new ILogOutput() {
-            public void printLog(LogLevel logLevel, String tag, String message) {
-                if (logLevel.getPriority() >= LogLevel.ERROR.getPriority()) {
-                    printToStream(errorConsoleStream, tag, message);
-                    ConsolePlugin.getDefault().getConsoleManager().showConsoleView(mDdmsConsole);
-                } else {
-                    printToStream(consoleStream, tag, message);
-                }
-            }
-
-            public void printAndPromptLog(final LogLevel logLevel, final String tag,
-                    final String message) {
-                printLog(logLevel, tag, message);
-                // dialog box only run in UI thread..
-                display.asyncExec(new Runnable() {
-                    public void run() {
-                        Shell shell = display.getActiveShell();
-                        if (logLevel == LogLevel.ERROR) {
-                            MessageDialog.openError(shell, tag, message);
-                        } else {
-                            MessageDialog.openWarning(shell, tag, message);
-                        }
-                    }
-                });
-            }
-            
-        });
-
-        // create the loader that's able to load the images
-        mLoader = new ImageLoader(this);
-        
-        // set the listener for the preference change
-        Preferences prefs = getPluginPreferences();
-        prefs.addPropertyChangeListener(new IPropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent event) {
-                // get the name of the property that changed.
-                String property = event.getProperty();
-
-                if (PreferenceInitializer.ATTR_DEBUG_PORT_BASE.equals(property)) {
-                    DdmPreferences.setDebugPortBase(
-                            eclipseStore.getInt(PreferenceInitializer.ATTR_DEBUG_PORT_BASE));
-                } else if (PreferenceInitializer.ATTR_SELECTED_DEBUG_PORT.equals(property)) {
-                    DdmPreferences.setSelectedDebugPort(
-                            eclipseStore.getInt(PreferenceInitializer.ATTR_SELECTED_DEBUG_PORT));
-                } else if (PreferenceInitializer.ATTR_THREAD_INTERVAL.equals(property)) {
-                    DdmUiPreferences.setThreadRefreshInterval(
-                            eclipseStore.getInt(PreferenceInitializer.ATTR_THREAD_INTERVAL));
-                } else if (PreferenceInitializer.ATTR_LOG_LEVEL.equals(property)) {
-                    DdmPreferences.setLogLevel(
-                            eclipseStore.getString(PreferenceInitializer.ATTR_LOG_LEVEL));
-                }
-            }
-        });
-        
-        // read the adb location from the prefs to attempt to start it properly without
-        // having to wait for ADT to start
-        sAdbLocation = eclipseStore.getString(ADB_LOCATION);
-
-        // start it in a thread to return from start() asap.
-        new Thread() {
-            @Override
-            public void run() {
-                // init ddmlib if needed
-                getDefault().initDdmlib();
-
-                // create and start the first bridge
-                AndroidDebugBridge.createBridge(sAdbLocation, true /* forceNewBridge */);
-            }
-        }.start();
-    }
-
-    public static Display getDisplay() {
-        IWorkbench bench = sPlugin.getWorkbench();
-        if (bench != null) {
-            return bench.getDisplay();
-        }
-        return null;
-    }
-
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        AndroidDebugBridge.removeDeviceChangeListener(this);
-        
-        AndroidDebugBridge.terminate();
-        
-        mRed.dispose();
-
-        sPlugin = null;
-        super.stop(context);
-    }
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static DdmsPlugin getDefault() {
-        return sPlugin;
-    }
-
-    /** Return the image loader for the plugin */
-    public static ImageLoader getImageLoader() {
-        if (sPlugin != null) {
-            return sPlugin.mLoader;
-        }
-        return null;
-    }
-
-    public static String getAdb() {
-        return sAdbLocation;
-    }
-
-    /**
-     * Set the location of the adb executable and optionally starts adb
-     * @param adb location of adb
-     * @param startAdb flag to start adb
-     */
-    public static void setAdb(String adb, boolean startAdb) {
-        sAdbLocation = adb;
-
-        // store the location for future ddms only start.
-        sPlugin.getPreferenceStore().setValue(ADB_LOCATION, sAdbLocation);
-
-        // starts the server in a thread in case this is blocking.
-        if (startAdb) {
-            new Thread() {
-                @Override
-                public void run() {
-                    // init ddmlib if needed
-                    getDefault().initDdmlib();
-
-                    // create and start the bridge
-                    AndroidDebugBridge.createBridge(sAdbLocation, false /* forceNewBridge */);
-                }
-            }.start();
-        }
-    }
-    
-    private synchronized void initDdmlib() {
-        if (mDdmlibInitialized == false) {
-            // set the preferences.
-            PreferenceInitializer.setupPreferences();
-    
-            // init the lib
-            AndroidDebugBridge.init(true /* debugger support */);
-            
-            mDdmlibInitialized = true;
-        }
-    }
-
-    /**
-     * Sets the launcher responsible for connecting the debugger to running applications.
-     * @param launcher The launcher.
-     */
-    public static void setRunningAppDebugLauncher(IDebugLauncher launcher) {
-        sRunningAppDebugLauncher = launcher;
-
-        // if the process view is already running, give it the launcher.
-        // This method could be called from a non ui thread, so we make sure to do that
-        // in the ui thread.
-        Display display = getDisplay();
-        if (display != null && display.isDisposed() == false) {
-            display.asyncExec(new Runnable() {
-                public void run() {
-                    DeviceView dv = DeviceView.getInstance();
-                    if (dv != null) {
-                        dv.setDebugLauncher(sRunningAppDebugLauncher);
-                    }
-                }
-            });
-        }
-    }
-
-    public static IDebugLauncher getRunningAppDebugLauncher() {
-        return sRunningAppDebugLauncher;
-    }
-    
-    public synchronized void addSelectionListener(ISelectionListener listener) {
-        mListeners.add(listener);
-        
-        // notify the new listener of the current selection
-       listener.selectionChanged(mCurrentDevice);
-       listener.selectionChanged(mCurrentClient);
-    }
-
-    public synchronized void removeSelectionListener(ISelectionListener listener) {
-        mListeners.remove(listener);
-    }
-
-    public synchronized void setListeningState(boolean state) {
-        mListeningToUiSelection = state;
-    }
-
-    /**
-     * Sent when the a device is connected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceConnected(Device)
-     */
-    public void deviceConnected(Device device) {
-        // if we are listening to selection coming from the ui, then we do nothing, as
-        // any change in the devices/clients, will be handled by the UI, and we'll receive
-        // selection notification through our implementation of IUiSelectionListener.
-        if (mListeningToUiSelection == false) {
-            if (mCurrentDevice == null) {
-                handleDefaultSelection(device);
-            }
-        }
-    }
-
-    /**
-     * Sent when the a device is disconnected to the {@link AndroidDebugBridge}.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the new device.
-     * 
-     * @see IDeviceChangeListener#deviceDisconnected(Device)
-     */
-    public void deviceDisconnected(Device device) {
-        // if we are listening to selection coming from the ui, then we do nothing, as
-        // any change in the devices/clients, will be handled by the UI, and we'll receive
-        // selection notification through our implementation of IUiSelectionListener.
-        if (mListeningToUiSelection == false) {
-            // test if the disconnected device was the default selection.
-            if (mCurrentDevice == device) {
-                // try to find a new device
-                AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-                if (bridge != null) {
-                    // get the device list
-                    Device[] devices = bridge.getDevices();
-                    
-                    // check if we still have devices
-                    if (devices.length == 0) {
-                        handleDefaultSelection((Device)null);
-                    } else {
-                        handleDefaultSelection(devices[0]);
-                    }
-                } else {
-                    handleDefaultSelection((Device)null);
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a device data changed, or when clients are started/terminated on the device.
-     * <p/>
-     * This is sent from a non UI thread.
-     * @param device the device that was updated.
-     * @param changeMask the mask indicating what changed.
-     * 
-     * @see IDeviceChangeListener#deviceChanged(Device)
-     */
-    public void deviceChanged(Device device, int changeMask) {
-        // if we are listening to selection coming from the ui, then we do nothing, as
-        // any change in the devices/clients, will be handled by the UI, and we'll receive
-        // selection notification through our implementation of IUiSelectionListener.
-        if (mListeningToUiSelection == false) {
-            
-            // check if this is our device
-            if (device == mCurrentDevice) {
-                if (mCurrentClient == null) {
-                    handleDefaultSelection(device);
-                } else {
-                    // get the clients and make sure ours is still in there.
-                    Client[] clients = device.getClients();
-                    boolean foundClient = false;
-                    for (Client client : clients) {
-                        if (client == mCurrentClient) {
-                            foundClient = true;
-                            break;
-                        }
-                    }
-                    
-                    // if we haven't found our client, lets look for a new one
-                    if (foundClient == false) {
-                        mCurrentClient = null;
-                        handleDefaultSelection(device);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Sent when a new {@link Device} and {@link Client} are selected.
-     * @param selectedDevice the selected device. If null, no devices are selected.
-     * @param selectedClient The selected client. If null, no clients are selected.
-     */
-    public synchronized void selectionChanged(Device selectedDevice, Client selectedClient) {
-        if (mCurrentDevice != selectedDevice) {
-            mCurrentDevice = selectedDevice;
-
-            // notify of the new default device
-            for (ISelectionListener listener : mListeners) {
-                listener.selectionChanged(mCurrentDevice);
-            }
-        }
-
-        if (mCurrentClient != selectedClient) {
-            mCurrentClient = selectedClient;
-            
-            // notify of the new default client
-            for (ISelectionListener listener : mListeners) {
-                listener.selectionChanged(mCurrentClient);
-            }
-        }
-    }
-
-    /**
-     * Handles a default selection of a {@link Device} and {@link Client}.
-     * @param device the selected device
-     */
-    private void handleDefaultSelection(final Device device) {
-        // because the listener expect to receive this from the UI thread, and this is called
-        // from the AndroidDebugBridge notifications, we need to run this in the UI thread.
-        try {
-            Display display = getDisplay();
-            
-            display.asyncExec(new Runnable() {
-                public void run() {
-                    // set the new device if different.
-                    boolean newDevice = false;
-                    if (mCurrentDevice != device) {
-                        mCurrentDevice = device;
-                        newDevice = true;
-                
-                        // notify of the new default device
-                        for (ISelectionListener listener : mListeners) {
-                            listener.selectionChanged(mCurrentDevice);
-                        }
-                    }
-                    
-                    if (device != null) {
-                        // if this is a device switch or the same device but we didn't find a valid
-                        // client the last time, we go look for a client to use again.
-                        if (newDevice || mCurrentClient == null) {
-                            // now get the new client
-                            Client[] clients =  device.getClients();
-                            if (clients.length > 0) {
-                                handleDefaultSelection(clients[0]);
-                            } else {
-                                handleDefaultSelection((Client)null);
-                            }
-                        }
-                    } else {
-                        handleDefaultSelection((Client)null);
-                    }
-                }
-            });
-        } catch (SWTException e) {
-            // display is disposed. Do nothing since we're quitting anyway.
-        }
-    }
-    
-    private void handleDefaultSelection(Client client) {
-        mCurrentClient = client;
-        
-        // notify of the new default client
-        for (ISelectionListener listener : mListeners) {
-            listener.selectionChanged(mCurrentClient);
-        }
-    }
-    
-    /**
-     * Prints a message, associated with a project to the specified stream
-     * @param stream The stream to write to
-     * @param tag The tag associated to the message. Can be null
-     * @param message The message to print.
-     */
-    private static synchronized void printToStream(MessageConsoleStream stream, String tag,
-            String message) {
-        String dateTag = getMessageTag(tag);
-
-        stream.print(dateTag);
-        stream.println(message);
-    }
-    
-    /**
-     * Creates a string containing the current date/time, and the tag
-     * @param tag The tag associated to the message. Can be null
-     * @return The dateTag
-     */
-    private static String getMessageTag(String tag) {
-        Calendar c = Calendar.getInstance();
-
-        if (tag == null) {
-            return String.format("[%1$tF %1$tT]", c);
-        }
-
-        return String.format("[%1$tF %1$tT - %2$s]", c, tag);
-    }
-
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ImageLoader.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ImageLoader.java
deleted file mode 100644
index a70405d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ImageLoader.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package com.android.ide.eclipse.ddms;
-
-import com.android.ddmuilib.IImageLoader;
-
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-
-/**
- * Implementation of the IImageLoader interface for the eclipse plugin.
- */
-public class ImageLoader implements IImageLoader  {
-
-    private URL mBaseUrl;
-
-    public ImageLoader(Plugin plugin) {
-        mBaseUrl = plugin.getBundle().getEntry("/"); // $NON-NLS-1$
-    }
-
-    /**
-     * default method. only need a filename. the 2 interface methods call this one.
-     * @param filename the filename of the image to load. The filename is searched for under /icons.
-     * @return
-     */
-    public ImageDescriptor loadDescriptor(String filename) {
-        try {
-            URL newUrl = new URL(mBaseUrl, "/icons/" + filename); // $NON-NLS-1$
-            return ImageDescriptor.createFromURL(newUrl);
-        } catch (MalformedURLException e) {
-            // we'll just return null;
-        }
-        return null;
-    }
-
-    public ImageDescriptor loadDescriptor(String filename, Display display) {
-        return loadDescriptor(filename);
-    }
-
-
-    public Image loadImage(String filename, Display display) {
-        ImageDescriptor descriptor = loadDescriptor(filename);
-        if (descriptor !=null) {
-            return descriptor.createImage();
-        }
-        return null;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/Perspective.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/Perspective.java
deleted file mode 100644
index 4c01e9b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/Perspective.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package com.android.ide.eclipse.ddms;
-
-import com.android.ide.eclipse.ddms.views.DeviceView;
-import com.android.ide.eclipse.ddms.views.EmulatorControlView;
-import com.android.ide.eclipse.ddms.views.FileExplorerView;
-import com.android.ide.eclipse.ddms.views.HeapView;
-import com.android.ide.eclipse.ddms.views.LogCatView;
-import com.android.ide.eclipse.ddms.views.ThreadView;
-
-import org.eclipse.ui.IFolderLayout;
-import org.eclipse.ui.IPageLayout;
-import org.eclipse.ui.IPerspectiveFactory;
-
-public class Perspective implements IPerspectiveFactory {
-
-    public void createInitialLayout(IPageLayout layout) {
-        // create a default layout that looks like the stand alone DDMS.
-
-        // no editor window
-        layout.setEditorAreaVisible(false);
-
-        String editorArea = layout.getEditorArea();
-        IFolderLayout folder;
-
-        folder = layout.createFolder("logcat", IPageLayout.BOTTOM, 0.8f, //$NON-NLS-1$
-                editorArea);
-        folder.addPlaceholder(LogCatView.ID + ":*"); //$NON-NLS-1$
-        folder.addView(LogCatView.ID);
-
-        folder = layout.createFolder("devices", IPageLayout.LEFT, 0.3f, //$NON-NLS-1$
-                editorArea);
-        folder.addPlaceholder(DeviceView.ID + ":*"); //$NON-NLS-1$
-        folder.addView(DeviceView.ID);
-
-        folder = layout.createFolder("emulator", IPageLayout.BOTTOM, 0.5f, //$NON-NLS-1$
-                "devices");
-        folder.addPlaceholder(EmulatorControlView.ID + ":*"); //$NON-NLS-1$
-        folder.addView(EmulatorControlView.ID);
-
-        folder = layout.createFolder("ddms-detail", IPageLayout.RIGHT, 0.5f, //$NON-NLS-1$
-                editorArea);
-        folder.addPlaceholder(ThreadView.ID + ":*"); //$NON-NLS-1$
-        folder.addView(ThreadView.ID);
-        folder.addView(HeapView.ID);
-        folder.addView(FileExplorerView.ID);
-
-        layout.addPerspectiveShortcut("org.eclipse.ui.resourcePerspective"); //$NON-NLS-1$
-        layout.addPerspectiveShortcut("org.eclipse.debug.ui.DebugPerspective"); //$NON-NLS-1$
-        layout.addPerspectiveShortcut("org.eclipse.jdt.ui.JavaPerspective"); //$NON-NLS-1$
-
-        layout.addShowViewShortcut(DeviceView.ID);
-        layout.addShowViewShortcut(FileExplorerView.ID);
-        layout.addShowViewShortcut(HeapView.ID);
-        layout.addShowViewShortcut(LogCatView.ID);
-        layout.addShowViewShortcut(ThreadView.ID);
-
-        layout.addShowViewShortcut(IPageLayout.ID_RES_NAV);
-        layout.addShowViewShortcut(IPageLayout.ID_BOOKMARKS);
-        layout.addShowViewShortcut(IPageLayout.ID_OUTLINE);
-        layout.addShowViewShortcut(IPageLayout.ID_PROP_SHEET);
-        layout.addShowViewShortcut(IPageLayout.ID_PROBLEM_VIEW);
-        layout.addShowViewShortcut(IPageLayout.ID_PROGRESS_VIEW);
-        layout.addShowViewShortcut(IPageLayout.ID_TASK_LIST);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/LogCatPreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/LogCatPreferencePage.java
deleted file mode 100644
index 909207d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/LogCatPreferencePage.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.preferences;
-
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.views.LogCatView;
-
-import org.eclipse.core.runtime.Preferences;
-import org.eclipse.core.runtime.Preferences.IPropertyChangeListener;
-import org.eclipse.core.runtime.Preferences.PropertyChangeEvent;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.FontFieldEditor;
-import org.eclipse.swt.SWTError;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * Preference Pane for LogCat.
- */
-public class LogCatPreferencePage extends FieldEditorPreferencePage implements
-        IWorkbenchPreferencePage {
-
-    public LogCatPreferencePage() {
-        super(GRID);
-        setPreferenceStore(DdmsPlugin.getDefault().getPreferenceStore());
-    }
-
-    @Override
-    protected void createFieldEditors() {
-        FontFieldEditor ffe = new FontFieldEditor(PreferenceInitializer.ATTR_LOGCAT_FONT,
-                "Display Font:", getFieldEditorParent());
-        addField(ffe);
-
-        Preferences prefs = DdmsPlugin.getDefault().getPluginPreferences();
-        prefs.addPropertyChangeListener(new IPropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent event) {
-                // get the name of the property that changed.
-                String property = event.getProperty();
-
-                if (PreferenceInitializer.ATTR_LOGCAT_FONT.equals(property)) {
-                    try {
-                        FontData fdat = new FontData((String)event.getNewValue());
-                        LogCatView.setFont(new Font(getFieldEditorParent().getDisplay(), fdat));
-                    } catch (IllegalArgumentException e) {
-                        // Looks like the data from the store is not valid.
-                        // We do nothing (default font will be used).
-                    } catch (SWTError e2) {
-                        // Looks like the Font() constructor failed.
-                        // We do nothing in this case, the logcat view will use the default font.
-                    }
-                }
-            }
-        });
-    }
-
-    public void init(IWorkbench workbench) {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferenceInitializer.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferenceInitializer.java
deleted file mode 100644
index b53d85c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferenceInitializer.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.preferences;
-
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ddmlib.DdmPreferences;
-import com.android.ddmuilib.DdmUiPreferences;
-
-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.FontData;
-
-/**
- * Class used to initialize default preference values.
- */
-public class PreferenceInitializer extends AbstractPreferenceInitializer {
-    
-    public final static String ATTR_LOG_LEVEL =
-        DdmsPlugin.PLUGIN_ID + ".logLevel"; //$NON-NLS-1$
-
-    public final static String ATTR_DEBUG_PORT_BASE =
-        DdmsPlugin.PLUGIN_ID + ".adbDebugBasePort"; //$NON-NLS-1$
-
-    public final static String ATTR_SELECTED_DEBUG_PORT =
-        DdmsPlugin.PLUGIN_ID + ".debugSelectedPort"; //$NON-NLS-1$
-
-    public final static String ATTR_DEFAULT_THREAD_UPDATE =
-        DdmsPlugin.PLUGIN_ID + ".defaultThreadUpdateEnabled"; //$NON-NLS-1$
-
-    public final static String ATTR_DEFAULT_HEAP_UPDATE =
-        DdmsPlugin.PLUGIN_ID + ".defaultHeapUpdateEnabled"; //$NON-NLS-1$
-
-    public final static String ATTR_THREAD_INTERVAL =
-        DdmsPlugin.PLUGIN_ID + ".threadStatusInterval"; //$NON-NLS-1$
-
-    public final static String ATTR_IMAGE_SAVE_DIR =
-        DdmsPlugin.PLUGIN_ID + ".imageSaveDir"; //$NON-NLS-1$
-
-    public final static String ATTR_LAST_IMAGE_SAVE_DIR =
-        DdmsPlugin.PLUGIN_ID + ".lastImageSaveDir"; //$NON-NLS-1$
-
-    public final static String ATTR_LOGCAT_FONT =
-        DdmsPlugin.PLUGIN_ID + ".logcatFont"; //$NON-NLS-1$
-    
-    /*
-     * (non-Javadoc)
-     *
-     * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer
-     * #initializeDefaultPreferences()
-     */
-    @Override
-    public void initializeDefaultPreferences() {
-        IPreferenceStore store = DdmsPlugin.getDefault().getPreferenceStore();
-
-        store.setDefault(ATTR_DEBUG_PORT_BASE, DdmPreferences.DEFAULT_DEBUG_PORT_BASE);
-
-        store.setDefault(ATTR_SELECTED_DEBUG_PORT, DdmPreferences.DEFAULT_SELECTED_DEBUG_PORT);
-
-        store.setDefault(ATTR_DEFAULT_THREAD_UPDATE, DdmPreferences.DEFAULT_INITIAL_THREAD_UPDATE);
-        store.setDefault(ATTR_DEFAULT_HEAP_UPDATE,
-                DdmPreferences.DEFAULT_INITIAL_HEAP_UPDATE);
-
-        store.setDefault(ATTR_THREAD_INTERVAL, DdmUiPreferences.DEFAULT_THREAD_REFRESH_INTERVAL);
-
-        String homeDir = System.getProperty("user.home"); //$NON-NLS-1$
-        store.setDefault(ATTR_IMAGE_SAVE_DIR, homeDir);
-
-        store.setDefault(ATTR_LOG_LEVEL, DdmPreferences.DEFAULT_LOG_LEVEL.getStringValue());
-
-        store.setDefault(ATTR_LOGCAT_FONT,
-                new FontData("Courier", 10, SWT.NORMAL).toString()); //$NON-NLS-1$
-    }
-    
-    /**
-     * Initializes the preferences of ddmlib and ddmuilib with values from the eclipse store. 
-     */
-    public synchronized static void setupPreferences() {
-        IPreferenceStore store = DdmsPlugin.getDefault().getPreferenceStore();
-        
-        DdmPreferences.setDebugPortBase(store.getInt(ATTR_DEBUG_PORT_BASE));
-        DdmPreferences.setSelectedDebugPort(store.getInt(ATTR_SELECTED_DEBUG_PORT));
-        DdmPreferences.setLogLevel(store.getString(ATTR_LOG_LEVEL));
-        DdmPreferences.setInitialThreadUpdate(store.getBoolean(ATTR_DEFAULT_THREAD_UPDATE));
-        DdmPreferences.setInitialHeapUpdate(store.getBoolean(ATTR_DEFAULT_HEAP_UPDATE));
-        DdmUiPreferences.setThreadRefreshInterval(store.getInt(ATTR_THREAD_INTERVAL));
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferencePage.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferencePage.java
deleted file mode 100644
index 86e87c7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/preferences/PreferencePage.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.preferences;
-
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.PortFieldEditor;
-
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.IntegerFieldEditor;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-public class PreferencePage extends FieldEditorPreferencePage implements
-        IWorkbenchPreferencePage {
-
-    public PreferencePage() {
-        super(GRID);
-        setPreferenceStore(DdmsPlugin.getDefault().getPreferenceStore());
-    }
-
-    /**
-     * Creates the field editors. Field editors are abstractions of the common
-     * GUI blocks needed to manipulate various types of preferences. Each field
-     * editor knows how to save and restore itself.
-     */
-    @Override
-    public void createFieldEditors() {
-        IntegerFieldEditor ife;
-
-        ife = new PortFieldEditor(PreferenceInitializer.ATTR_DEBUG_PORT_BASE,
-            "ADB debugger base port:", getFieldEditorParent());
-        addField(ife);
-
-        BooleanFieldEditor bfe;
-
-        bfe = new BooleanFieldEditor(PreferenceInitializer.ATTR_DEFAULT_THREAD_UPDATE,
-            "Thread updates enabled by default", getFieldEditorParent());
-        addField(bfe);
-
-        bfe = new BooleanFieldEditor(PreferenceInitializer.ATTR_DEFAULT_HEAP_UPDATE,
-            "Heap updates enabled by default", getFieldEditorParent());
-        addField(bfe);
-
-        ife = new IntegerFieldEditor(PreferenceInitializer.ATTR_THREAD_INTERVAL,
-            "Thread status refresh interval (seconds):", getFieldEditorParent());
-        ife.setValidRange(1, 60);
-        addField(ife);
-
-        RadioGroupFieldEditor rgfe = new RadioGroupFieldEditor(PreferenceInitializer.ATTR_LOG_LEVEL,
-                "Logging Level", 1, new String[][] {
-                    { "Verbose", LogLevel.VERBOSE.getStringValue() },
-                    { "Debug", LogLevel.DEBUG.getStringValue() },
-                    { "Info", LogLevel.INFO.getStringValue() },
-                    { "Warning", LogLevel.WARN.getStringValue() },
-                    { "Error", LogLevel.ERROR.getStringValue() },
-                    { "Assert", LogLevel.ASSERT.getStringValue() }
-                    },
-                getFieldEditorParent(), true);
-        addField(rgfe);
-
-    }
-
-    public void init(IWorkbench workbench) {
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/DeviceView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/DeviceView.java
deleted file mode 100644
index 62a528a..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/DeviceView.java
+++ /dev/null
@@ -1,329 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.ClientData;
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.ddmuilib.DevicePanel;
-import com.android.ddmuilib.ScreenShotDialog;
-import com.android.ddmuilib.DevicePanel.IUiSelectionListener;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.DdmsPlugin.IDebugLauncher;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.part.ViewPart;
-
-public class DeviceView extends ViewPart implements IUiSelectionListener {
-    
-    private final static boolean USE_SELECTED_DEBUG_PORT = true;
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.DeviceView"; //$NON-NLS-1$
-
-    private DevicePanel mDeviceList;
-    private Action mResetAdbAction;
-    private Action mCaptureAction;
-    private Action mUpdateThreadAction;
-    private Action mUpdateHeapAction;
-    private Action mGcAction;
-    private Action mKillAppAction;
-    private Action mDebugAction;
-    private IDebugLauncher mDebugLauncher;
-
-    private static DeviceView sThis;
-
-    public DeviceView() {
-        // the view is declared with allowMultiple="false" so we
-        // can safely do this.
-        sThis = this;
-    }
-
-    public static DeviceView getInstance() {
-        return sThis;
-    }
-    
-    /**
-     * Sets the {@link IDebugLauncher}.
-     * @param debugLauncher
-     */
-    public void setDebugLauncher(DdmsPlugin.IDebugLauncher debugLauncher) {
-        mDebugLauncher = debugLauncher;
-        if (mDebugAction != null && mDeviceList != null) {
-            Client currentClient = mDeviceList.getSelectedClient();
-            if (currentClient != null) {
-                mDebugAction.setEnabled(true);
-            }
-        }
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mDeviceList = new DevicePanel(DdmsPlugin.getImageLoader(), USE_SELECTED_DEBUG_PORT);
-        mDeviceList.createPanel(parent);
-        mDeviceList.addSelectionListener(this);
-        
-        DdmsPlugin plugin = DdmsPlugin.getDefault();
-        mDeviceList.addSelectionListener(plugin);
-        plugin.setListeningState(true);
-
-        mCaptureAction = new Action("Screen Capture") {
-            @Override
-            public void run() {
-                ScreenShotDialog dlg = new ScreenShotDialog(
-                        DdmsPlugin.getDisplay().getActiveShell());
-                dlg.open(mDeviceList.getSelectedDevice());
-            }
-        };
-        mCaptureAction.setToolTipText("Screen Capture");
-        mCaptureAction.setImageDescriptor(
-                DdmsPlugin.getImageLoader().loadDescriptor("capture.png")); //$NON-NLS-1$
-
-        mResetAdbAction = new Action("Reset adb") {
-            @Override
-            public void run() {
-                AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-                if (bridge != null) {
-                    if (bridge.restart() == false) {
-                        // get the current Display
-                        final Display display = DdmsPlugin.getDisplay();
-
-                        // dialog box only run in ui thread..
-                        display.asyncExec(new Runnable() {
-                            public void run() {
-                                Shell shell = display.getActiveShell();
-                                MessageDialog.openError(shell, "Adb Error",
-                                        "Adb failed to restart!\n\nMake sure the plugin is properly configured.");
-                            }
-                        });
-                    }
-                }
-            }
-        };
-        mResetAdbAction.setToolTipText("Reset the adb host daemon");
-        mResetAdbAction.setImageDescriptor(PlatformUI.getWorkbench()
-                .getSharedImages().getImageDescriptor(
-                        ISharedImages.IMG_OBJS_WARN_TSK));
-
-        mKillAppAction = new Action() {
-            @Override
-            public void run() {
-                mDeviceList.killSelectedClient();
-            }
-        };
-
-        mKillAppAction.setText("Stop Process");
-        mKillAppAction.setToolTipText("Stop Process");
-        mKillAppAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor(DevicePanel.ICON_HALT));
-
-        mGcAction = new Action() {
-            @Override
-            public void run() {
-                mDeviceList.forceGcOnSelectedClient();
-            }
-        };
-
-        mGcAction.setText("Cause GC");
-        mGcAction.setToolTipText("Cause GC");
-        mGcAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor(DevicePanel.ICON_GC));
-
-        mUpdateHeapAction = new Action("Update Heap", IAction.AS_CHECK_BOX) {
-            @Override
-            public void run() {
-                boolean enable = mUpdateHeapAction.isChecked();
-                mDeviceList.setEnabledHeapOnSelectedClient(enable);
-            }
-        };
-        mUpdateHeapAction.setToolTipText("Update Heap");
-        mUpdateHeapAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor(DevicePanel.ICON_HEAP));
-
-        mUpdateThreadAction = new Action("Update Threads", IAction.AS_CHECK_BOX) {
-            @Override
-            public void run() {
-                boolean enable = mUpdateThreadAction.isChecked();
-                mDeviceList.setEnabledThreadOnSelectedClient(enable);
-            }
-        };
-        mUpdateThreadAction.setToolTipText("Update Threads");
-        mUpdateThreadAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor(DevicePanel.ICON_THREAD));
-
-        // check if there's already a debug launcher set up in the plugin class
-        mDebugLauncher = DdmsPlugin.getRunningAppDebugLauncher();
-
-        mDebugAction = new Action("Debug Process") {
-            @Override
-            public void run() {
-                if (mDebugLauncher != null) {
-                    Client currentClient = mDeviceList.getSelectedClient();
-                    if (currentClient != null) {
-                        ClientData clientData = currentClient.getClientData();
-
-                        // make sure the client can be debugged
-                        switch (clientData.getDebuggerConnectionStatus()) {
-                            case ClientData.DEBUGGER_ERROR: {
-                                Display display = DdmsPlugin.getDisplay();
-                                Shell shell = display.getActiveShell();
-                                MessageDialog.openError(shell, "Process Debug",
-                                        "The process debug port is already in use!");
-                                return;
-                            }
-                            case ClientData.DEBUGGER_ATTACHED: {
-                                Display display = DdmsPlugin.getDisplay();
-                                Shell shell = display.getActiveShell();
-                                MessageDialog.openError(shell, "Process Debug",
-                                        "The process is already being debugged!");
-                                return;
-                            }
-                        }
-
-                        // get the name of the client
-                        String packageName = clientData.getClientDescription();
-                        if (packageName != null) {
-                            if (mDebugLauncher.debug(packageName,
-                                    currentClient.getDebuggerListenPort()) == false) {
-    
-                                // if we get to this point, then we failed to find a project
-                                // that matched the application to debug
-                                Display display = DdmsPlugin.getDisplay();
-                                Shell shell = display.getActiveShell();
-                                MessageDialog.openError(shell, "Process Debug",
-                                        String.format(
-                                                "No opened project found for %1$s. Debug session failed!",
-                                                packageName));
-                            }
-                        }
-                    }
-                }
-            }
-        };
-        mDebugAction.setToolTipText("Debug the selected process, provided its source project is present and opened in the workspace.");
-        mDebugAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor("debug-attach.png")); //$NON-NLS-1$
-        if (mDebugLauncher == null) {
-            mDebugAction.setEnabled(false);
-        }
-        
-        placeActions();
-    }
-
-    @Override
-    public void setFocus() {
-        mDeviceList.setFocus();
-    }
-    
-    /**
-     * Sent when a new {@link Device} and {@link Client} are selected.
-     * @param selectedDevice the selected device. If null, no devices are selected.
-     * @param selectedClient The selected client. If null, no clients are selected.
-     */
-    public void selectionChanged(Device selectedDevice, Client selectedClient) {
-        // update the buttons
-        doSelectionChanged(selectedClient);
-        doSelectionChanged(selectedDevice);
-    }
-
-    private void doSelectionChanged(Client selectedClient) {
-        // update the buttons
-        if (selectedClient != null) {
-            if (USE_SELECTED_DEBUG_PORT) {
-                // set the client as the debug client
-                selectedClient.setAsSelectedClient();
-            }
-
-            mDebugAction.setEnabled(mDebugLauncher != null);
-            mKillAppAction.setEnabled(true);
-            mGcAction.setEnabled(true);
-            
-            mUpdateHeapAction.setEnabled(true);
-            mUpdateHeapAction.setChecked(selectedClient.isHeapUpdateEnabled());
-
-            mUpdateThreadAction.setEnabled(true);
-            mUpdateThreadAction.setChecked(selectedClient.isThreadUpdateEnabled());
-        } else {
-            if (USE_SELECTED_DEBUG_PORT) {
-                // set the client as the debug client
-                AndroidDebugBridge bridge = AndroidDebugBridge.getBridge();
-                if (bridge != null) {
-                    bridge.setSelectedClient(null);
-                }
-            }
-            
-            mDebugAction.setEnabled(false);
-            mKillAppAction.setEnabled(false);
-            mGcAction.setEnabled(false);
-            mUpdateHeapAction.setChecked(false);
-            mUpdateHeapAction.setEnabled(false);
-            mUpdateThreadAction.setEnabled(false);
-            mUpdateThreadAction.setChecked(false);
-        }
-    }
-    
-    private void doSelectionChanged(Device selectedDevice) {
-        mCaptureAction.setEnabled(selectedDevice != null);
-    }
-
-    /**
-     * Place the actions in the ui.
-     */
-    private final void placeActions() {
-        IActionBars actionBars = getViewSite().getActionBars();
-
-        // first in the menu
-        IMenuManager menuManager = actionBars.getMenuManager();
-        menuManager.add(mDebugAction);
-        menuManager.add(new Separator());
-        menuManager.add(mUpdateThreadAction);
-        menuManager.add(mUpdateHeapAction);
-        menuManager.add(new Separator());
-        menuManager.add(mGcAction);
-        menuManager.add(new Separator());
-        menuManager.add(mKillAppAction);
-        menuManager.add(new Separator());
-        menuManager.add(mCaptureAction);
-        menuManager.add(new Separator());
-        menuManager.add(mResetAdbAction);
-
-        // and then in the toolbar
-        IToolBarManager toolBarManager = actionBars.getToolBarManager();
-        toolBarManager.add(mDebugAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mUpdateThreadAction);
-        toolBarManager.add(mUpdateHeapAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mKillAppAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mCaptureAction);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EmulatorControlView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EmulatorControlView.java
deleted file mode 100644
index ca9a691..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EmulatorControlView.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.EmulatorControlPanel;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-
-import org.eclipse.swt.widgets.Composite;
-
-public class EmulatorControlView extends SelectionDependentViewPart {
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.EmulatorControlView"; //$NON-NLS-1$
-
-    private EmulatorControlPanel mPanel;
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mPanel = new EmulatorControlPanel(DdmsPlugin.getImageLoader());
-        mPanel.createPanel(parent);
-        setSelectionDependentPanel(mPanel);
-    }
-
-    @Override
-    public void setFocus() {
-        mPanel.setFocus();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EventLogView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EventLogView.java
deleted file mode 100644
index 3a74e42..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/EventLogView.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.log.event.EventLogPanel;
-import com.android.ide.eclipse.ddms.CommonAction;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.ImageLoader;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IActionBars;
-
-public class EventLogView extends SelectionDependentViewPart {
-    
-    private EventLogPanel mLogPanel;
-
-    @Override
-    public void createPartControl(Composite parent) {
-        ImageLoader loader = DdmsPlugin.getImageLoader();
-
-        // create the external actions
-        CommonAction optionsAction = new CommonAction("Options...");
-        optionsAction.setToolTipText("Opens the options panel");
-        optionsAction.setImageDescriptor(loader
-                .loadDescriptor("edit.png")); // $NON-NLS-1$
-
-        CommonAction clearLogAction = new CommonAction("Clear Log");
-        clearLogAction.setToolTipText("Clears the event log");
-        clearLogAction.setImageDescriptor(loader
-                .loadDescriptor("clear.png")); // $NON-NLS-1$
-
-        CommonAction saveAction = new CommonAction("Save Log");
-        saveAction.setToolTipText("Saves the event log");
-        saveAction.setImageDescriptor(loader
-                .loadDescriptor("save.png")); // $NON-NLS-1$
-
-        CommonAction loadAction = new CommonAction("Load Log");
-        loadAction.setToolTipText("Loads an event log");
-        loadAction.setImageDescriptor(loader
-                .loadDescriptor("load.png")); // $NON-NLS-1$
-
-        CommonAction importBugAction = new CommonAction("Import Bug Report Log");
-        importBugAction.setToolTipText("Imports a bug report.");
-        importBugAction.setImageDescriptor(loader
-                .loadDescriptor("importBug.png")); // $NON-NLS-1$
-
-        placeActions(optionsAction, clearLogAction, saveAction, loadAction, importBugAction);
-
-        mLogPanel = new EventLogPanel(DdmsPlugin.getImageLoader());
-        mLogPanel.setActions(optionsAction, clearLogAction, saveAction, loadAction, importBugAction);
-        mLogPanel.createPanel(parent);
-        setSelectionDependentPanel(mLogPanel);
-    }
-
-    @Override
-    public void setFocus() {
-        mLogPanel.setFocus();
-    }
-    
-    @Override
-    public void dispose() {
-        if (mLogPanel != null) {
-            mLogPanel.stopEventLog(true);
-        }
-    }
-    
-    /**
-     * Places the actions in the toolbar and in the menu.
-     * @param importBugAction 
-     */
-    private void placeActions(IAction optionAction, IAction clearAction, IAction saveAction,
-            IAction loadAction, CommonAction importBugAction) {
-        IActionBars actionBars = getViewSite().getActionBars();
-
-        // first in the menu
-        IMenuManager menuManager = actionBars.getMenuManager();
-        menuManager.add(clearAction);
-        menuManager.add(new Separator());
-        menuManager.add(saveAction);
-        menuManager.add(loadAction);
-        menuManager.add(importBugAction);
-        menuManager.add(new Separator());
-        menuManager.add(optionAction);
-
-        // and then in the toolbar
-        IToolBarManager toolBarManager = actionBars.getToolBarManager();
-        toolBarManager.add(clearAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(saveAction);
-        toolBarManager.add(loadAction);
-        toolBarManager.add(importBugAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(optionAction);
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/FileExplorerView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/FileExplorerView.java
deleted file mode 100644
index 4f0dd2e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/FileExplorerView.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-import com.android.ddmuilib.explorer.DeviceExplorer;
-import com.android.ide.eclipse.ddms.CommonAction;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.DdmsPlugin.ISelectionListener;
-
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.part.ViewPart;
-
-public class FileExplorerView extends ViewPart implements ISelectionListener {
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.FileExplorerView"; //$NON-NLS-1$
-
-    private final static String COLUMN_NAME =
-        DdmsPlugin.PLUGIN_ID + ".explorer.name"; //$NON-NLS-1S
-    private final static  String COLUMN_SIZE =
-        DdmsPlugin.PLUGIN_ID + ".explorer.size"; //$NON-NLS-1S
-    private final static String COLUMN_DATE =
-        DdmsPlugin.PLUGIN_ID + ".explorer.data"; //$NON-NLS-1S
-    private final static String COLUMN_TIME =
-        DdmsPlugin.PLUGIN_ID + ".explorer.time"; //$NON-NLS-1S
-    private final static String COLUMN_PERMISSIONS =
-        DdmsPlugin.PLUGIN_ID +".explorer.permissions"; //$NON-NLS-1S
-    private final static String COLUMN_INFO =
-        DdmsPlugin.PLUGIN_ID + ".explorer.info"; //$NON-NLS-1$
-
-    private DeviceExplorer mExplorer;
-
-    public FileExplorerView() {
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        DeviceExplorer.COLUMN_NAME = COLUMN_NAME;
-        DeviceExplorer.COLUMN_SIZE = COLUMN_SIZE;
-        DeviceExplorer.COLUMN_DATE = COLUMN_DATE;
-        DeviceExplorer.COLUMN_TIME = COLUMN_TIME;
-        DeviceExplorer.COLUMN_PERMISSIONS = COLUMN_PERMISSIONS;
-        DeviceExplorer.COLUMN_INFO = COLUMN_INFO;
-
-        // device explorer
-        mExplorer = new DeviceExplorer();
-
-
-        mExplorer.setImages(PlatformUI.getWorkbench()
-                .getSharedImages().getImage(ISharedImages.IMG_OBJ_FILE),
-                PlatformUI.getWorkbench() .getSharedImages().getImage(
-                        ISharedImages.IMG_OBJ_FOLDER),
-                DdmsPlugin.getImageLoader().loadDescriptor("android.png") //$NON-NLS-1$
-                        .createImage(),
-                PlatformUI.getWorkbench() .getSharedImages().getImage(
-                        ISharedImages.IMG_OBJ_ELEMENT));
-
-        // creates the actions
-        CommonAction pushAction = new CommonAction("Push File...") {
-            @Override
-            public void run() {
-                mExplorer.pushIntoSelection();
-            }
-        };
-        pushAction.setToolTipText("Push a file onto the device");
-        pushAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor("push.png")); //$NON-NLS-1$
-        pushAction.setEnabled(false);
-
-        CommonAction pullAction = new CommonAction("Pull File...") {
-            @Override
-            public void run() {
-                mExplorer.pullSelection();
-            }
-        };
-        pullAction.setToolTipText("Pull a file from the device");
-        pullAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor("pull.png")); //$NON-NLS-1$
-        pullAction.setEnabled(false);
-
-        CommonAction deleteAction = new CommonAction("Delete") {
-            @Override
-            public void run() {
-                mExplorer.deleteSelection();
-            }
-        };
-        deleteAction.setToolTipText("Delete the selection");
-        deleteAction.setImageDescriptor(DdmsPlugin.getImageLoader()
-                .loadDescriptor("delete.png")); //$NON-NLS-1$
-        deleteAction.setEnabled(false);
-
-        // set up the actions in the explorer
-        mExplorer.setActions(pushAction, pullAction, deleteAction);
-
-        // and in the ui
-        IActionBars actionBars = getViewSite().getActionBars();
-        IMenuManager menuManager = actionBars.getMenuManager();
-        IToolBarManager toolBarManager = actionBars.getToolBarManager();
-
-        menuManager.add(pullAction);
-        menuManager.add(pushAction);
-        menuManager.add(new Separator());
-        menuManager.add(deleteAction);
-
-        toolBarManager.add(pullAction);
-        toolBarManager.add(pushAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(deleteAction);
-        
-        mExplorer.createPanel(parent);
-
-        DdmsPlugin.getDefault().addSelectionListener(this);
-    }
-
-    @Override
-    public void setFocus() {
-        mExplorer.setFocus();
-    }
-
-    /**
-     * Sent when a new {@link Client} is selected.
-     * @param selectedClient The selected client.
-     */
-    public void selectionChanged(Client selectedClient) {
-        // pass
-    }
-    
-    /**
-     * Sent when a new {@link Device} is selected.
-     * @param selectedDevice the selected device.
-     */
-    public void selectionChanged(Device selectedDevice) {
-        mExplorer.switchDevice(selectedDevice);
-    }
-    
-    /**
-     * Sent when there is no current selection.
-     */
-    public void selectionRemoved() {
-        
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/HeapView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/HeapView.java
deleted file mode 100644
index 5745e8e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/HeapView.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.HeapPanel;
-
-import org.eclipse.swt.widgets.Composite;
-
-public class HeapView extends TableView {
-
-    public static final String ID = "com.android.ide.eclipse.ddms.views.HeapView"; //$NON-NLS-1$
-    private HeapPanel mPanel;
-
-    public HeapView() {
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mPanel = new HeapPanel();
-        mPanel.createPanel(parent);
-
-        setSelectionDependentPanel(mPanel);
-
-        // listen to focus changes for table(s) of the panel.
-        setupTableFocusListener(mPanel, parent);
-    }
-
-    @Override
-    public void setFocus() {
-        mPanel.setFocus();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/LogCatView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/LogCatView.java
deleted file mode 100644
index d3053f1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/LogCatView.java
+++ /dev/null
@@ -1,328 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ide.eclipse.ddms.CommonAction;
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.ImageLoader;
-import com.android.ide.eclipse.ddms.preferences.PreferenceInitializer;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmuilib.logcat.LogColors;
-import com.android.ddmuilib.logcat.LogFilter;
-import com.android.ddmuilib.logcat.LogPanel;
-import com.android.ddmuilib.logcat.LogPanel.ILogFilterStorageManager;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.actions.ActionFactory;
-
-import java.util.ArrayList;
-
-/**
- * The log cat view displays log output from the current device selection.
- *
- */
-public final class LogCatView extends SelectionDependentViewPart {
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.LogCatView"; // $NON-NLS-1$
-
-    private static final String PREFS_COL_TIME =
-        DdmsPlugin.PLUGIN_ID + ".logcat.time"; // $NON-NLS-1$
-    private static final String PREFS_COL_LEVEL =
-        DdmsPlugin.PLUGIN_ID + ".logcat.level"; // $NON-NLS-1$
-    private static final String PREFS_COL_PID =
-        DdmsPlugin.PLUGIN_ID + ".logcat.pid"; // $NON-NLS-1$
-    private static final String PREFS_COL_TAG =
-        DdmsPlugin.PLUGIN_ID + ".logcat.tag"; // $NON-NLS-1$
-    private static final String PREFS_COL_MESSAGE =
-        DdmsPlugin.PLUGIN_ID + ".logcat.message"; // $NON-NLS-1$
-
-    private static final String PREFS_FILTERS =
-        DdmsPlugin.PLUGIN_ID + ".logcat.filters"; // $NON-NLS-1$
-
-    private static LogCatView sThis;
-    private LogPanel mLogPanel;
-
-    private CommonAction mCreateFilterAction;
-    private CommonAction mDeleteFilterAction;
-    private CommonAction mEditFilterAction;
-    private CommonAction mExportAction;
-
-    private CommonAction[] mLogLevelActions;
-    private String[] mLogLevelIcons = {
-            "v.png", //$NON-NLS-1S
-            "d.png", //$NON-NLS-1S
-            "i.png", //$NON-NLS-1S
-            "w.png", //$NON-NLS-1S
-            "e.png", //$NON-NLS-1S
-    };
-
-    private Action mClearAction;
-
-    private Clipboard mClipboard;
-
-    /**
-     * An implementation of {@link ILogFilterStorageManager} to bridge to the eclipse preference
-     * store, and saves the log filters.
-     */
-    private final class FilterStorage implements ILogFilterStorageManager {
-
-        public LogFilter[] getFilterFromStore() {
-            String filterPrefs = DdmsPlugin.getDefault().getPreferenceStore().getString(
-                    PREFS_FILTERS);
-
-            // split in a string per filter
-            String[] filters = filterPrefs.split("\\|"); // $NON-NLS-1$
-
-            ArrayList<LogFilter> list =
-                new ArrayList<LogFilter>(filters.length);
-
-            for (String f : filters) {
-                if (f.length() > 0) {
-                    LogFilter logFilter = new LogFilter();
-                    if (logFilter.loadFromString(f)) {
-                        list.add(logFilter);
-                    }
-                }
-            }
-
-            return list.toArray(new LogFilter[list.size()]);
-        }
-
-        public void saveFilters(LogFilter[] filters) {
-            StringBuilder sb = new StringBuilder();
-            for (LogFilter f : filters) {
-                String filterString = f.toString();
-                sb.append(filterString);
-                sb.append('|');
-            }
-
-            DdmsPlugin.getDefault().getPreferenceStore().setValue(PREFS_FILTERS, sb.toString());
-        }
-
-        public boolean requiresDefaultFilter() {
-            return true;
-        }
-    }
-
-    public LogCatView() {
-        sThis = this;
-        LogPanel.PREFS_TIME = PREFS_COL_TIME;
-        LogPanel.PREFS_LEVEL = PREFS_COL_LEVEL;
-        LogPanel.PREFS_PID = PREFS_COL_PID;
-        LogPanel.PREFS_TAG = PREFS_COL_TAG;
-        LogPanel.PREFS_MESSAGE = PREFS_COL_MESSAGE;
-    }
-
-    /**
-     * Returns the singleton instance.
-     */
-    public static LogCatView getInstance() {
-        return sThis;
-    }
-
-    /**
-     * Sets the display font.
-     * @param font The font.
-     */
-    public static void setFont(Font font) {
-        if (sThis != null && sThis.mLogPanel != null) {
-            sThis.mLogPanel.setFont(font);
-        }
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        Display d = parent.getDisplay();
-        LogColors colors = new LogColors();
-
-        ImageLoader loader = DdmsPlugin.getImageLoader();
-
-        colors.infoColor = new Color(d, 0, 127, 0);
-        colors.debugColor = new Color(d, 0, 0, 127);
-        colors.errorColor = new Color(d, 255, 0, 0);
-        colors.warningColor = new Color(d, 255, 127, 0);
-        colors.verboseColor = new Color(d, 0, 0, 0);
-
-        mCreateFilterAction = new CommonAction("Create Filter") {
-            @Override
-            public void run() {
-                mLogPanel.addFilter();
-            }
-        };
-        mCreateFilterAction.setToolTipText("Create Filter");
-        mCreateFilterAction.setImageDescriptor(loader
-                .loadDescriptor("add.png")); // $NON-NLS-1$
-
-        mEditFilterAction = new CommonAction("Edit Filter") {
-            @Override
-            public void run() {
-                mLogPanel.editFilter();
-            }
-        };
-        mEditFilterAction.setToolTipText("Edit Filter");
-        mEditFilterAction.setImageDescriptor(loader
-                .loadDescriptor("edit.png")); // $NON-NLS-1$
-
-        mDeleteFilterAction = new CommonAction("Delete Filter") {
-            @Override
-            public void run() {
-                mLogPanel.deleteFilter();
-            }
-        };
-        mDeleteFilterAction.setToolTipText("Delete Filter");
-        mDeleteFilterAction.setImageDescriptor(loader
-                .loadDescriptor("delete.png")); // $NON-NLS-1$
-
-        mExportAction = new CommonAction("Export Selection As Text...") {
-            @Override
-            public void run() {
-                mLogPanel.save();
-            }
-        };
-        mExportAction.setToolTipText("Export Selection As Text...");
-        mExportAction.setImageDescriptor(loader.loadDescriptor("save.png")); // $NON-NLS-1$
-
-        LogLevel[] levels = LogLevel.values();
-        mLogLevelActions = new CommonAction[mLogLevelIcons.length];
-        for (int i = 0 ; i < mLogLevelActions.length; i++) {
-            String name = levels[i].getStringValue();
-            mLogLevelActions[i] = new CommonAction(name, IAction.AS_CHECK_BOX) {
-                @Override
-                public void run() {
-                    // disable the other actions and record current index
-                    for (int i = 0 ; i < mLogLevelActions.length; i++) {
-                        Action a = mLogLevelActions[i];
-                        if (a == this) {
-                            a.setChecked(true);
-
-                            // set the log level
-                            mLogPanel.setCurrentFilterLogLevel(i+2);
-                        } else {
-                            a.setChecked(false);
-                        }
-                    }
-                }
-            };
-
-            mLogLevelActions[i].setToolTipText(name);
-            mLogLevelActions[i].setImageDescriptor(loader.loadDescriptor(mLogLevelIcons[i]));
-        }
-
-        mClearAction = new Action("Clear Log") {
-            @Override
-            public void run() {
-                mLogPanel.clear();
-            }
-        };
-        mClearAction.setImageDescriptor(loader
-                .loadDescriptor("clear.png")); // $NON-NLS-1$
-
-
-        // now create the log view
-        mLogPanel = new LogPanel(loader, colors, new FilterStorage(), LogPanel.FILTER_MANUAL);
-        mLogPanel.setActions(mDeleteFilterAction, mEditFilterAction, mLogLevelActions);
-
-        // get the font
-        String fontStr = DdmsPlugin.getDefault().getPreferenceStore().getString(
-                PreferenceInitializer.ATTR_LOGCAT_FONT);
-        if (fontStr != null) {
-            FontData data = new FontData(fontStr);
-
-            if (fontStr != null) {
-                mLogPanel.setFont(new Font(parent.getDisplay(), data));
-            }
-        }
-
-        mLogPanel.createPanel(parent);
-        setSelectionDependentPanel(mLogPanel);
-
-        // place the actions.
-        placeActions();
-
-        // setup the copy action
-        mClipboard = new Clipboard(d);
-        IActionBars actionBars = getViewSite().getActionBars();
-        actionBars.setGlobalActionHandler(ActionFactory.COPY.getId(), new Action("Copy") {
-            @Override
-            public void run() {
-                mLogPanel.copy(mClipboard);
-            }
-        });
-
-        // setup the select all action
-        actionBars.setGlobalActionHandler(ActionFactory.SELECT_ALL.getId(),
-                new Action("Select All") {
-            @Override
-            public void run() {
-                mLogPanel.selectAll();
-            }
-        });
-    }
-
-    @Override
-    public void dispose() {
-        mLogPanel.stopLogCat(true);
-        mClipboard.dispose();
-    }
-
-    @Override
-    public void setFocus() {
-        mLogPanel.setFocus();
-    }
-
-    /**
-     * Place the actions in the ui.
-     */
-    private void placeActions() {
-        IActionBars actionBars = getViewSite().getActionBars();
-
-        // first in the menu
-        IMenuManager menuManager = actionBars.getMenuManager();
-        menuManager.add(mCreateFilterAction);
-        menuManager.add(mEditFilterAction);
-        menuManager.add(mDeleteFilterAction);
-        menuManager.add(new Separator());
-        menuManager.add(mClearAction);
-        menuManager.add(new Separator());
-        menuManager.add(mExportAction);
-
-        // and then in the toolbar
-        IToolBarManager toolBarManager = actionBars.getToolBarManager();
-        for (CommonAction a : mLogLevelActions) {
-            toolBarManager.add(a);
-        }
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mCreateFilterAction);
-        toolBarManager.add(mEditFilterAction);
-        toolBarManager.add(mDeleteFilterAction);
-        toolBarManager.add(new Separator());
-        toolBarManager.add(mClearAction);
-    }
- }
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/NativeHeapView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/NativeHeapView.java
deleted file mode 100644
index ed5aacb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/NativeHeapView.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.NativeHeapPanel;
-
-import org.eclipse.swt.widgets.Composite;
-
-public class NativeHeapView extends TableView {
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.NativeHeapView"; // $NON-NLS-1$
-    private NativeHeapPanel mPanel;
-
-    public NativeHeapView() {
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mPanel = new NativeHeapPanel();
-        mPanel.createPanel(parent);
-        
-        setSelectionDependentPanel(mPanel);
-
-        // listen to focus changes for table(s) of the panel.
-        setupTableFocusListener(mPanel, parent);
-    }
-
-    @Override
-    public void setFocus() {
-        mPanel.setFocus();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/SelectionDependentViewPart.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/SelectionDependentViewPart.java
deleted file mode 100644
index 48b2689..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/SelectionDependentViewPart.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ide.eclipse.ddms.DdmsPlugin;
-import com.android.ide.eclipse.ddms.DdmsPlugin.ISelectionListener;
-import com.android.ddmlib.Client;
-import com.android.ddmlib.Device;
-import com.android.ddmuilib.SelectionDependentPanel;
-
-import org.eclipse.ui.part.ViewPart;
-
-/**
- * A Workbench {@link ViewPart} that requires {@link Device}/{@link Client} selection notifications
- * from {@link DdmsPlugin} through the {@link ISelectionListener} interface.
- */
-public abstract class SelectionDependentViewPart extends ViewPart implements ISelectionListener {
-    
-    private SelectionDependentPanel mPanel;
-    
-    protected final void setSelectionDependentPanel(SelectionDependentPanel panel) {
-        // remember the panel
-        mPanel = panel;
-        
-        // and add ourself as listener of selection events.
-        DdmsPlugin.getDefault().addSelectionListener(this);
-    }
-    
-    @Override
-    public void dispose() {
-        DdmsPlugin.getDefault().removeSelectionListener(this);
-        super.dispose();
-    }
-
-    /**
-     * Sent when a new {@link Client} is selected.
-     * @param selectedClient The selected client.
-     * 
-     * @see ISelectionListener
-     */
-    public final void selectionChanged(Client selectedClient) {
-        mPanel.clientSelected(selectedClient);
-    }
-    
-    /**
-     * Sent when a new {@link Device} is selected.
-     * @param selectedDevice the selected device.
-     *
-     * @see ISelectionListener
-     */
-    public final void selectionChanged(Device selectedDevice) {
-        mPanel.deviceSelected(selectedDevice);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/TableView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/TableView.java
deleted file mode 100644
index 0fda35d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/TableView.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.ITableFocusListener;
-import com.android.ddmuilib.TablePanel;
-import com.android.ddmuilib.ITableFocusListener.IFocusedTableActivator;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.swt.dnd.Clipboard;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.actions.ActionFactory;
-
-/**
- * Base class for view containing Table that needs to support copy, and select all.
- */
-public abstract class TableView extends SelectionDependentViewPart {
-
-    /** Activator for the current Table that has the focus */
-    IFocusedTableActivator mActivator = null;
-
-    private Clipboard mClipboard;
-
-    private Action mCopyAction;
-    private Action mSelectAllAction;
-
-    /**
-     * Setup the listener for the Table objects of <code>Panel</code>, and setup
-     * the copy and select all actions.
-     * @param panel The panel to setup
-     * @param parent The parent composite of the Panel's content.
-     */
-    void setupTableFocusListener(TablePanel panel, Composite parent) {
-        panel.setTableFocusListener(new ITableFocusListener() {
-            public void focusGained(IFocusedTableActivator activator) {
-                mActivator = activator;
-                mCopyAction.setEnabled(true);
-                mSelectAllAction.setEnabled(true);
-            }
-
-            public void focusLost(IFocusedTableActivator activator) {
-                if (activator == mActivator) {
-                    mActivator = null;
-                    mCopyAction.setEnabled(false);
-                    mSelectAllAction.setEnabled(false);
-                }
-            }
-        });
-
-        // setup the copy action
-        mClipboard = new Clipboard(parent.getDisplay());
-        IActionBars actionBars = getViewSite().getActionBars();
-        actionBars.setGlobalActionHandler(ActionFactory.COPY.getId(),
-                mCopyAction = new Action("Copy") {
-            @Override
-            public void run() {
-                if (mActivator != null) {
-                    mActivator.copy(mClipboard);
-                }
-            }
-        });
-
-        // setup the select all action
-        actionBars.setGlobalActionHandler(ActionFactory.SELECT_ALL.getId(),
-                mSelectAllAction = new Action("Select All") {
-            @Override
-            public void run() {
-                if (mActivator != null) {
-                    mActivator.selectAll();
-                }
-            }
-        });
-
-    }
-
-    @Override
-    public void dispose() {
-        super.dispose();
-        mClipboard.dispose();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/ThreadView.java b/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/ThreadView.java
deleted file mode 100644
index cd24458..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/views/ThreadView.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.ddms.views;
-
-import com.android.ddmuilib.ThreadPanel;
-
-import org.eclipse.swt.widgets.Composite;
-
-public class ThreadView extends TableView {
-
-    public static final String ID =
-        "com.android.ide.eclipse.ddms.views.ThreadView"; // $NON-NLS-1$
-    private ThreadPanel mPanel;
-
-    public ThreadView() {
-    }
-
-    @Override
-    public void createPartControl(Composite parent) {
-        mPanel = new ThreadPanel();
-        mPanel.createPanel(parent);
-
-        setSelectionDependentPanel(mPanel);
-
-        // listen to focus changes for table(s) of the panel.
-        setupTableFocusListener(mPanel, parent);
-    }
-
-    @Override
-    public void setFocus() {
-        mPanel.setFocus();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/.classpath b/tools/eclipse/plugins/com.android.ide.eclipse.tests/.classpath
deleted file mode 100644
index 4088683..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/.classpath
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="src" path="unittests"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-	<classpathentry kind="lib" path="kxml2-2.3.0.jar"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/.project b/tools/eclipse/plugins/com.android.ide.eclipse.tests/.project
deleted file mode 100644
index 99e4964..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/.project
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>adt-tests</name>
-	<comment></comment>
-	<projects>
-		<project>SdkLib</project>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.ManifestBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-		<buildCommand>
-			<name>org.eclipse.pde.SchemaBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.PluginNature</nature>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/META-INF/MANIFEST.MF b/tools/eclipse/plugins/com.android.ide.eclipse.tests/META-INF/MANIFEST.MF
deleted file mode 100644
index 266008c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,19 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: Android Plugin Tests
-Bundle-SymbolicName: com.android.ide.eclipse.tests
-Bundle-Version: 0.9.0.qualifier
-Bundle-Activator: com.android.ide.eclipse.tests.AndroidTestPlugin
-Require-Bundle: org.eclipse.ui,
- org.eclipse.core.runtime,
- org.eclipse.core.resources,
- com.android.ide.eclipse.adt,
- org.junit,
- org.eclipse.jdt.core,
- org.eclipse.jdt.launching,
- org.eclipse.ui.views,
- com.android.ide.eclipse.ddms
-Eclipse-LazyStart: true
-Bundle-Vendor: The Android Open Source Project
-Bundle-ClassPath: kxml2-2.3.0.jar,
- .
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/MODULE_LICENSE_EPL b/tools/eclipse/plugins/com.android.ide.eclipse.tests/MODULE_LICENSE_EPL
deleted file mode 100644
index e69de29..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/MODULE_LICENSE_EPL
+++ /dev/null
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/NOTICE b/tools/eclipse/plugins/com.android.ide.eclipse.tests/NOTICE
deleted file mode 100644
index 49c101d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/NOTICE
+++ /dev/null
@@ -1,224 +0,0 @@
-*Eclipse Public License - v 1.0*
-
-THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE
-PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF
-THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT.
-
-*1. DEFINITIONS*
-
-"Contribution" means:
-
-a) in the case of the initial Contributor, the initial code and
-documentation distributed under this Agreement, and
-b) in the case of each subsequent Contributor:
-
-i) changes to the Program, and
-
-ii) additions to the Program;
-
-where such changes and/or additions to the Program originate from and
-are distributed by that particular Contributor. A Contribution
-'originates' from a Contributor if it was added to the Program by such
-Contributor itself or anyone acting on such Contributor's behalf.
-Contributions do not include additions to the Program which: (i) are
-separate modules of software distributed in conjunction with the Program
-under their own license agreement, and (ii) are not derivative works of
-the Program.
-
-"Contributor" means any person or entity that distributes the Program.
-
-"Licensed Patents " mean patent claims licensable by a Contributor which
-are necessarily infringed by the use or sale of its Contribution alone
-or when combined with the Program.
-
-"Program" means the Contributions distributed in accordance with this
-Agreement.
-
-"Recipient" means anyone who receives the Program under this Agreement,
-including all Contributors.
-
-*2. GRANT OF RIGHTS*
-
-a) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free copyright
-license to reproduce, prepare derivative works of, publicly display,
-publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and
-object code form.
-
-b) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free patent license
-under Licensed Patents to make, use, sell, offer to sell, import and
-otherwise transfer the Contribution of such Contributor, if any, in
-source code and object code form. This patent license shall apply to the
-combination of the Contribution and the Program if, at the time the
-Contribution is added by the Contributor, such addition of the
-Contribution causes such combination to be covered by the Licensed
-Patents. The patent license shall not apply to any other combinations
-which include the Contribution. No hardware per se is licensed hereunder.
-
-c) Recipient understands that although each Contributor grants the
-licenses to its Contributions set forth herein, no assurances are
-provided by any Contributor that the Program does not infringe the
-patent or other intellectual property rights of any other entity. Each
-Contributor disclaims any liability to Recipient for claims brought by
-any other entity based on infringement of intellectual property rights
-or otherwise. As a condition to exercising the rights and licenses
-granted hereunder, each Recipient hereby assumes sole responsibility to
-secure any other intellectual property rights needed, if any. For
-example, if a third party patent license is required to allow Recipient
-to distribute the Program, it is Recipient's responsibility to acquire
-that license before distributing the Program.
-
-d) Each Contributor represents that to its knowledge it has sufficient
-copyright rights in its Contribution, if any, to grant the copyright
-license set forth in this Agreement.
-
-*3. REQUIREMENTS*
-
-A Contributor may choose to distribute the Program in object code form
-under its own license agreement, provided that:
-
-a) it complies with the terms and conditions of this Agreement; and
-
-b) its license agreement:
-
-i) effectively disclaims on behalf of all Contributors all warranties
-and conditions, express and implied, including warranties or conditions
-of title and non-infringement, and implied warranties or conditions of
-merchantability and fitness for a particular purpose;
-
-ii) effectively excludes on behalf of all Contributors all liability for
-damages, including direct, indirect, special, incidental and
-consequential damages, such as lost profits;
-
-iii) states that any provisions which differ from this Agreement are
-offered by that Contributor alone and not by any other party; and
-
-iv) states that source code for the Program is available from such
-Contributor, and informs licensees how to obtain it in a reasonable
-manner on or through a medium customarily used for software exchange.
-
-When the Program is made available in source code form:
-
-a) it must be made available under this Agreement; and
-
-b) a copy of this Agreement must be included with each copy of the Program.
-
-Contributors may not remove or alter any copyright notices contained
-within the Program.
-
-Each Contributor must identify itself as the originator of its
-Contribution, if any, in a manner that reasonably allows subsequent
-Recipients to identify the originator of the Contribution.
-
-*4. COMMERCIAL DISTRIBUTION*
-
-Commercial distributors of software may accept certain responsibilities
-with respect to end users, business partners and the like. While this
-license is intended to facilitate the commercial use of the Program, the
-Contributor who includes the Program in a commercial product offering
-should do so in a manner which does not create potential liability for
-other Contributors. Therefore, if a Contributor includes the Program in
-a commercial product offering, such Contributor ("Commercial
-Contributor") hereby agrees to defend and indemnify every other
-Contributor ("Indemnified Contributor") against any losses, damages and
-costs (collectively "Losses") arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified
-Contributor to the extent caused by the acts or omissions of such
-Commercial Contributor in connection with its distribution of the
-Program in a commercial product offering. The obligations in this
-section do not apply to any claims or Losses relating to any actual or
-alleged intellectual property infringement. In order to qualify, an
-Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial
-Contributor to control, and cooperate with the Commercial Contributor
-in, the defense and any related settlement negotiations. The Indemnified
-Contributor may participate in any such claim at its own expense.
-
-For example, a Contributor might include the Program in a commercial
-product offering, Product X. That Contributor is then a Commercial
-Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance
-claims and warranties are such Commercial Contributor's responsibility
-alone. Under this section, the Commercial Contributor would have to
-defend claims against the other Contributors related to those
-performance claims and warranties, and if a court requires any other
-Contributor to pay any damages as a result, the Commercial Contributor
-must pay those damages.
-
-*5. NO WARRANTY*
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED
-ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
-EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES
-OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR
-A PARTICULAR PURPOSE. Each Recipient is solely responsible for
-determining the appropriateness of using and distributing the Program
-and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program
-errors, compliance with applicable laws, damage to or loss of data,
-programs or equipment, and unavailability or interruption of operations.
-
-*6. DISCLAIMER OF LIABILITY*
-
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR
-ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT,
-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING
-WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF
-LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR
-DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED
-HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
-
-*7. GENERAL*
-
-If any provision of this Agreement is invalid or unenforceable under
-applicable law, it shall not affect the validity or enforceability of
-the remainder of the terms of this Agreement, and without further action
-by the parties hereto, such provision shall be reformed to the minimum
-extent necessary to make such provision valid and enforceable.
-
-If Recipient institutes patent litigation against any entity (including
-a cross-claim or counterclaim in a lawsuit) alleging that the Program
-itself (excluding combinations of the Program with other software or
-hardware) infringes such Recipient's patent(s), then such Recipient's
-rights granted under Section 2(b) shall terminate as of the date such
-litigation is filed.
-
-All Recipient's rights under this Agreement shall terminate if it fails
-to comply with any of the material terms or conditions of this Agreement
-and does not cure such failure in a reasonable period of time after
-becoming aware of such noncompliance. If all Recipient's rights under
-this Agreement terminate, Recipient agrees to cease use and distribution
-of the Program as soon as reasonably practicable. However, Recipient's
-obligations under this Agreement and any licenses granted by Recipient
-relating to the Program shall continue and survive.
-
-Everyone is permitted to copy and distribute copies of this Agreement,
-but in order to avoid inconsistency the Agreement is copyrighted and may
-only be modified in the following manner. The Agreement Steward reserves
-the right to publish new versions (including revisions) of this
-Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the
-initial Agreement Steward. The Eclipse Foundation may assign the
-responsibility to serve as the Agreement Steward to a suitable separate
-entity. Each new version of the Agreement will be given a distinguishing
-version number. The Program (including Contributions) may always be
-distributed subject to the version of the Agreement under which it was
-received. In addition, after a new version of the Agreement is
-published, Contributor may elect to distribute the Program (including
-its Contributions) under the new version. Except as expressly stated in
-Sections 2(a) and 2(b) above, Recipient receives no rights or licenses
-to the intellectual property of any Contributor under this Agreement,
-whether expressly, by implication, estoppel or otherwise. All rights in
-the Program not expressly granted under this Agreement are reserved.
-
-This Agreement is governed by the laws of the State of New York and the
-intellectual property laws of the United States of America. No party to
-this Agreement will bring a legal action under this Agreement more than
-one year after the cause of action arose. Each party waives its rights
-to a jury trial in any resulting litigation.
-
- 
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/README.txt b/tools/eclipse/plugins/com.android.ide.eclipse.tests/README.txt
deleted file mode 100644
index f5899e3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/README.txt
+++ /dev/null
@@ -1,72 +0,0 @@
-This project contains the tests for the Android Eclipse Plugins.
-
-You can do two things:
-1- Run the full "eclipse plugin" suite
-2- Run independent JUnit tests (not as plugin)
-
-------------------------------------------
-1- Running the full "eclipse plugin" suite
-------------------------------------------
-
-Steps to run the test suite:
-
-A- In Eclipse, import following projects from //device/tools/eclipse/plugins:
-	- adt-tests
-	- adt
-	- common
-	- editors
-
-B- Create a new "JUnit Plug-in Test" run configuration via the "Run > Open Run Dialog..." menu
-Set the launch configuration's data as follows:
-i. "Test" tab: 
-  Select "Run a single test"
-  Project: adt-tests 
-  Test class: com.android.ide.eclipse.tests.UnitTests
-  Test runner: JUnit 3
-ii. "Arguments" tab:
- Set "VM Arguments" to 
-"-Dtest_data=<adt>/plugins/com.android.ide.eclipse.tests/unittests/data/"
-replacing "<adt>" with absolute filesystem path to the android plugin source location
-
-All other fields can be left with their default values
-
-C. Run the newly created launch configuration
-
-Running the tests will run a secondary instance of Eclipse. 
-
-Please note the following constraints to be aware of when writing tests to run within a plugin environment:
-
-a. Access restrictions: cannot access package or protected members in a different
-plugin, even if they are in the same declared package 
-b. Using classloader.getResource or getResourceAsStream to access test data will 
-likely fail in the plugin environment. Instead, use AdtTestData to access test files
-in conjunction with the "test_data" environment variable mentioned above
-
-
--------------------------------------------
-2- Run independent JUnit tests (not plugin)
--------------------------------------------
-
-A- In Eclipse, import following projects from //device/tools/eclipse/plugins:
-	- adt-tests
-	- adt
-	- common
-	- editors
-
-B- Select the "unittests" source folder, right-click and select
-	"Run As > JUnit Test" (i.e. not the plugin tests)
-
-This creates a debug configuration of type "JUnit Test" running all tests
-in the source folder "unittests". The runtime must be JUnit 3.
-
-Note: this method runs the tests within a regular JVM environment (ie not within
-an Eclipse instance). This method has the advantage of being quicker than running
-as a JUnit plugin test, and requires less potential set-up, but has the 
-disadvantage of not properly replicating how the tests will be run in the 
-continuous test environment. Tests that pass when run as "JUnit Tests" can
-fail when run as "JUnit Plugin Tests", due to the extra constraints imposed by
-running within an Eclipse plug-in noted in section 1.
-
-
-
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/build.properties b/tools/eclipse/plugins/com.android.ide.eclipse.tests/build.properties
deleted file mode 100644
index cbfd993..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/build.properties
+++ /dev/null
@@ -1,10 +0,0 @@
-source.. = src/,\
-           unittests/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               test.xml,\
-               prefs.template,\
-               unittest.xml,\
-               kxml2-2.3.0.jar,\
-               unittests/data/
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class1.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class1.java
deleted file mode 100644
index 3cf1027..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class1.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package jar.example;
-
-public class Class1 {
-
-    public static final int sStaticField = 1;
-    
-    /** constructor */
-    public Class1() {
-        int a = 1;
-    }
-    
-    public static class InnerStaticClass1 {
-        
-    }
-
-    public class InnerClass2 {
-        
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class2.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class2.java
deleted file mode 100644
index 4d15c47..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/not_source_folder/jar/example/Class2.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package jar.example;
-
-public class Class2 extends Class1 {
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/prefs.template b/tools/eclipse/plugins/com.android.ide.eclipse.tests/prefs.template
deleted file mode 100644
index e0037de..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/prefs.template
+++ /dev/null
@@ -1,3 +0,0 @@
-#Wed Feb 20 16:56:40 PST 2008
-com.android.ide.eclipse.adt.sdk=sdk_home
-eclipse.preferences.version=1
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectCreationPage.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectCreationPage.java
deleted file mode 100644
index 42f8df0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectCreationPage.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.adt.wizards.newproject;
-
-import java.io.File;
-
-/**
- * Stub class for project creation page Returns canned responses for creating a
- * sample project
- */
-public class StubSampleProjectCreationPage extends NewProjectCreationPage {
-
-    private String mSampleProjectName;
-    private String mOsSdkLocation;
-
-    public StubSampleProjectCreationPage(String pageName,
-            String sampleProjectName, String osSdkLocation) {
-        super(pageName);
-        this.mSampleProjectName = sampleProjectName;
-        this.mOsSdkLocation = osSdkLocation;
-    }
-
-    @Override
-    public String getProjectName() {
-        return mSampleProjectName;
-    }
-
-    @Override
-    public String getPackageName() {
-        return "com.android.samples";
-    }
-
-    @Override
-    public String getActivityName() {
-        return mSampleProjectName;
-    }
-
-    @Override
-    public String getApplicationName() {
-        return mSampleProjectName;
-    }
-
-    @Override
-    public boolean isNewProject() {
-        return false;
-    }
-
-    @Override
-    public String getProjectLocation() {
-        return mOsSdkLocation + File.separator + "samples" + File.separator + mSampleProjectName;
-    }
-
-    @Override
-    public String getSourceFolder() {
-        return "src";
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectWizard.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectWizard.java
deleted file mode 100644
index 40cd636..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/adt/wizards/newproject/StubSampleProjectWizard.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.adt.wizards.newproject;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jface.operation.IRunnableWithProgress;
-import org.eclipse.jface.wizard.IWizardContainer;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.swt.widgets.Shell;
-
-import java.lang.reflect.InvocationTargetException;
-
-/**
- * Stub class for project creation wizard Created so project creation logic can
- * be run without UI creation/manipulation Returns canned responses for creating
- * a sample project
- */
-public class StubSampleProjectWizard extends NewProjectWizard {
-
-    private final String mSampleProjectName;
-    private final String mOsSdkLocation;
-
-    /**
-     * Constructor
-     * 
-     * @param sampleProjectName
-     * @param osSdkLocation
-     */
-    public StubSampleProjectWizard(String sampleProjectName, String osSdkLocation) {
-        this.mSampleProjectName = sampleProjectName;
-        this.mOsSdkLocation = osSdkLocation;
-    }
-
-    /**
-     * Override parent to return stub page
-     */
-    @Override
-    protected NewProjectCreationPage createMainPage() {
-        return new StubSampleProjectCreationPage(MAIN_PAGE_NAME,
-                mSampleProjectName, mOsSdkLocation);
-    }
-
-    /**
-     * Overrides parent to return dummy wizard container
-     */
-    @Override
-    public IWizardContainer getContainer() {
-        return new IWizardContainer() {
-
-            public IWizardPage getCurrentPage() {
-                return null;
-            }
-
-            public Shell getShell() {
-                return null;
-            }
-
-            public void showPage(IWizardPage page) {
-                // pass
-            }
-
-            public void updateButtons() {
-                // pass
-            }
-
-            public void updateMessage() {
-                // pass
-            }
-
-            public void updateTitleBar() {
-                // pass
-            }
-
-            public void updateWindowTitle() {
-                // pass
-            }
-
-            /**
-             * Executes runnable on current thread
-             */
-            public void run(boolean fork, boolean cancelable,
-                    IRunnableWithProgress runnable)
-                    throws InvocationTargetException, InterruptedException {
-                runnable.run(new NullProgressMonitor());
-            }
-
-        };
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AdtTestData.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AdtTestData.java
deleted file mode 100644
index 262ef65..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AdtTestData.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import java.io.File;
-import java.net.URL;
-import java.util.logging.Logger;
-
-/**
- * Helper class for retrieving test data
- * 
- * All tests which need to retrieve test data files should go through this class 
- *
- */
-public class AdtTestData {
-
-    /** singleton instance */
-    private static AdtTestData sInstance = null;
-    private static final Logger sLogger = Logger.getLogger(AdtTestData.class.getName());
-    
-    /** the absolute file path to the /data directory in this test 
-     * environment. 
-     */
-    private String mOsRootDataPath;
-    
-   
-    private AdtTestData() {
-        // can set test_data env variable to override default behavior of 
-        // finding data using class loader
-        // useful when running in plugin environment, where test data is inside 
-        // bundled jar, and must be extracted to temp filesystem location to be 
-        // accessed normally
-        mOsRootDataPath = System.getProperty("test_data");
-        if (mOsRootDataPath == null) {
-            sLogger.info("Cannot find test_data directory, init to class loader");
-            URL url = this.getClass().getClassLoader().getResource("data");  //$NON-NLS-1$
-            mOsRootDataPath = url.getFile();
-        }
-        if (!mOsRootDataPath.endsWith(File.separator)) {
-            sLogger.info("Fixing test_data env variable does not end with path separator");
-            mOsRootDataPath = mOsRootDataPath.concat(File.separator);
-        }
-    }
-    
-    /** Get the singleton instance of AdtTestData */
-    public static AdtTestData getInstance() {
-        if (sInstance == null) {
-            sInstance = new AdtTestData();
-        }
-        return sInstance;
-    }
-    
-    /** Returns the absolute file path to a file located in this plugins
-     * "data" directory
-     * @param osRelativePath - string path to file contained in /data. Must 
-     * use path separators appropriate to host OS
-     * @return String
-     */
-    public String getTestFilePath(String osRelativePath) {
-        return mOsRootDataPath + osRelativePath;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AllTests.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AllTests.java
deleted file mode 100644
index fb5504c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AllTests.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import junit.framework.TestSuite;
-
-
-/**
- * Container TestSuite for all eclipse tests, both functional and unit
- */
-public class AllTests extends TestSuite {
-
-    public AllTests() {
-        
-    }
-    
-    /**
-     * Returns a suite of test cases to be run.
-     */
-    public static TestSuite suite() {
-        TestSuite suite = new TestSuite();
-        suite.addTest(FuncTests.suite());
-        suite.addTest(UnitTests.suite());
-        return suite;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AndroidTestPlugin.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AndroidTestPlugin.java
deleted file mode 100644
index 45a6fbc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/AndroidTestPlugin.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class AndroidTestPlugin extends AbstractUIPlugin {
-
-    // The plug-in ID
-    public static final String PLUGIN_ID = "com.android.ide.eclipse.adt.tests";
-
-    // The shared instance
-    private static AndroidTestPlugin sPlugin;
-
-    /**
-     * The constructor
-     */
-    public AndroidTestPlugin() {
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        sPlugin = this;
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
-     */
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        sPlugin = null;
-        super.stop(context);
-    }
-
-    /**
-     * Returns the shared instance
-     * 
-     * @return the shared instance
-     */
-    public static AndroidTestPlugin getDefault() {
-        return sPlugin;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/EclipseTestCollector.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/EclipseTestCollector.java
deleted file mode 100644
index 29538bb..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/EclipseTestCollector.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-import org.eclipse.core.runtime.Plugin;
-
-import java.lang.reflect.Modifier;
-import java.net.URL;
-import java.util.Enumeration;
-import java.util.logging.Logger;
-
-/**
- * Class for collecting all test cases in an eclipse plugin
- * 
- */
-public class EclipseTestCollector {
-
-    private static final Logger sLogger = Logger.getLogger(EclipseTestCollector.class.getName());
-    
-    /**
-     * Constructor
-     */
-    public EclipseTestCollector() {
-        
-    }
-
-    /**
-     * Searches through given plugin, adding all TestCase classes to given suite
-     * @param suite - TestSuite to add to
-     * @param plugin - Plugin to search for tests
-     * @param expectedPackage - expected package for tests. Only test classes 
-     *  that start with this package name will be added to suite
-     */
-    public void addTestCases(TestSuite suite, Plugin plugin, String expectedPackage) {
-        if (plugin != null) {
-            Enumeration entries = plugin.getBundle().findEntries("/", "*.class", true);
-    
-            while (entries.hasMoreElements()) {
-                URL entry = (URL)entries.nextElement();
-                String filePath = entry.getPath().replace(".class", "");
-                try {
-                  Class testClass = getClass(filePath, expectedPackage);
-                  if (isTestClass(testClass)) {
-                      suite.addTestSuite(testClass);
-                  }
-                } 
-                catch (ClassNotFoundException e) {
-                  // ignore, this is not the class we're looking for
-                  //sLogger.log(Level.INFO, "Could not load class " + filePath);
-              }
-            }
-        }
-    }
-    
-    /**
-     * Returns true if given class shouk\ld be added to suite
-     * @param testClass
-     * @return
-     */
-    protected boolean isTestClass(Class testClass) {
-        return TestCase.class.isAssignableFrom(testClass) &&
-          Modifier.isPublic(testClass.getModifiers()) &&
-          hasPublicConstructor(testClass);
-    }
-    
-    /**
-     * Returns true if given class has a public constructor
-     * @param testClass
-     * @return
-     */
-    protected boolean hasPublicConstructor(Class testClass) {
-        try {
-            TestSuite.getTestConstructor(testClass);
-        } catch(NoSuchMethodException e) {
-            return false;
-        }
-        return true;
-    }
-    
-    /**
-     * Load the class given by the plugin aka bundle file path
-     * @param filePath - path of class in bundle
-     * @param expectedPackage - expected package of class
-     * @return
-     * @throws ClassNotFoundException
-     */
-    protected Class getClass(String filePath, String expectedPackage) throws ClassNotFoundException {
-        String dotPath = filePath.replace('/', '.');
-        // remove the output folders, by finding where package name starts
-        int index = dotPath.indexOf(expectedPackage);
-        if (index == -1) {
-            throw new ClassNotFoundException();
-        }
-        String packagePath = dotPath.substring(index);
-        return Class.forName(packagePath);   
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTestCase.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTestCase.java
deleted file mode 100644
index 63f17ab..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTestCase.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import junit.framework.TestCase;
-
-/**
- * Generic superclass for Eclipse Android functional test cases, that provides 
- * common facilities
- */
-public class FuncTestCase extends TestCase {
-
-    private String mOsSdkLocation;
-
-    /**
-     * Constructor
-     * 
-     * @throws IllegalArgumentException if environment variable "sdk_home" is
-     *         not set
-     */
-    protected FuncTestCase() {
-        mOsSdkLocation = System.getProperty("sdk_home");
-        if (mOsSdkLocation == null || mOsSdkLocation.length() < 1) {
-            throw new IllegalArgumentException(
-                    "Environment variable sdk_home is not set");
-        }
-    }
-
-    /**
-     * Returns the absolute file system path of the Android SDK location to use
-     * for this test
-     */
-    protected String getOsSdkLocation() {
-        return mOsSdkLocation;
-    }
-
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTests.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTests.java
deleted file mode 100644
index 08405e8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/FuncTests.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-import com.android.ide.eclipse.tests.functests.sampleProjects.SampleProjectTest;
-
-import junit.framework.TestSuite;
-
-/**
- * Container TestSuite for all eclipse tests to be run
- */
-
-public class FuncTests extends TestSuite {
-
-    static final String FUNC_TEST_PACKAGE = "com.android.ide.eclipse.tests.functests";
-
-    public FuncTests() {
-        
-    }
-    
-    /**
-     * Returns a suite of test cases to be run.
-     * Needed for JUnit3 compliant command line test runner
-     */
-    public static TestSuite suite() {
-        TestSuite suite = new TestSuite();
-        
-        suite.addTestSuite(SampleProjectTest.class);
-        
-        return suite;
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/UnitTests.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/UnitTests.java
deleted file mode 100644
index ac928db..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/UnitTests.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- * http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests;
-
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * Container TestSuite for all eclipse unit tests to be run
- * 
- * Uses Eclipse OSGI to find and then run all junit.junit.framework.Tests in 
- * this plugin, excluding tests in the FuncTests.FUNC_TEST_PACKAGE package
- * 
- * Since it uses Eclipse OSGI, it must be run in a Eclipse plugin environment
- * i.e. from Eclipse workbench, this suite must be run using the 
- * "JUnit Plug-in Test" launch configuration as opposed to as a "JUnit Test"  
- * 
- */                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
-public class UnitTests {
-    private static final String TEST_PACKAGE = "com.android.ide.eclipse";
-    
-    public static Test suite() {
-        TestSuite suite = new TestSuite();
-        
-        UnitTestCollector collector = new UnitTestCollector();
-        collector.addTestCases(suite, AndroidTestPlugin.getDefault(), TEST_PACKAGE);
-        return suite;
-    }
-    
-    /**
-     * Specialized test collector which will skip adding functional tests
-     */
-    private static class UnitTestCollector extends EclipseTestCollector {
-        /**
-         * Override parent class to exclude functional tests
-         */
-        @Override
-        protected boolean isTestClass(Class testClass) {
-            return super.isTestClass(testClass) &&
-            !testClass.getPackage().getName().startsWith(FuncTests.FUNC_TEST_PACKAGE);
-        }
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/functests/sampleProjects/SampleProjectTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/functests/sampleProjects/SampleProjectTest.java
deleted file mode 100644
index 98817c6..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/src/com/android/ide/eclipse/tests/functests/sampleProjects/SampleProjectTest.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- * 
- * Licensed under the Eclipse Public License, Version 1.0 (the "License"); you
- * may not use this file except in compliance with the License. You may obtain a
- * copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
- * License for the specific language governing permissions and limitations under
- * the License.
- */
-package com.android.ide.eclipse.tests.functests.sampleProjects;
-
-import com.android.ide.eclipse.adt.project.ProjectHelper;
-import com.android.ide.eclipse.adt.wizards.newproject.StubSampleProjectWizard;
-import com.android.ide.eclipse.tests.FuncTestCase;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResourceChangeEvent;
-import org.eclipse.core.resources.IResourceChangeListener;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.swt.widgets.Display;
-
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/**
- * Test case that verifies all SDK sample projects can be imported, built in
- * Eclipse
- * 
- * TODO: add support for deploying apps onto emulator and verifying successful
- * execution there
- * 
- */
-public class SampleProjectTest extends FuncTestCase {
-    
-    private static final Logger sLogger = Logger.getLogger(SampleProjectTest.class.getName());
-
-    /**
-     * Tests the sample project with the given name
-     * 
-     * @param name - name of sample project to test
-     */
-    protected void doTestSampleProject(String name) {
-        try {
-
-            StubSampleProjectWizard newProjCreator = new StubSampleProjectWizard(
-                    name, getOsSdkLocation());
-            newProjCreator.init(null, null);
-            newProjCreator.performFinish();
-
-            IProject iproject = validateProjectExists(name);
-
-            validateNoProblems(iproject);
-
-        } 
-        catch (CoreException e) {
-            fail("Unexpected exception when creating sample project: " + e.toString());
-        }
-    }
-
-    public void testApiDemos() {
-        doTestSampleProject("ApiDemos");
-    }
-
-    public void testHelloActivity() {
-        doTestSampleProject("HelloActivity");
-    }
-
-    public void testLunarLander() {
-        doTestSampleProject("LunarLander");
-    }
-
-    public void testNotePad() {
-        doTestSampleProject("NotePad");
-    }
-
-    public void testSkeletonApp() {
-        doTestSampleProject("SkeletonApp");
-    }
-
-    public void testSnake() {
-        doTestSampleProject("Snake");
-    }
-
-    private IProject validateProjectExists(String name) {
-        IProject iproject = getIProject(name);
-        assertTrue(iproject.exists());
-        assertTrue(iproject.isOpen());
-        return iproject;
-    }
-
-    private IProject getIProject(String name) {
-        IProject iproject = ResourcesPlugin.getWorkspace().getRoot()
-                .getProject(name);
-        return iproject;
-    }
-
-    private void validateNoProblems(IProject iproject) throws CoreException {
-        waitForBuild(iproject);
-        assertFalse(ProjectHelper.hasError(iproject, true));
-    }
-
-
-    /**
-     * Waits for build to complete.
-     * 
-     * @param iproject
-     */
-    private void waitForBuild(final IProject iproject) {
-       
-        final BuiltProjectDeltaVisitor deltaVisitor = new BuiltProjectDeltaVisitor(iproject);
-        IResourceChangeListener newBuildListener = new IResourceChangeListener() {
-
-            public void resourceChanged(IResourceChangeEvent event) {
-                try {
-                    event.getDelta().accept(deltaVisitor);
-                }
-                catch (CoreException e) {
-                    fail();
-                }
-            }
-            
-        };
-        iproject.getWorkspace().addResourceChangeListener(newBuildListener, 
-          IResourceChangeEvent.POST_BUILD);
-
-        // poll build listener to determine when build is done
-        // loop max of 1200 times * 50 ms = 60 seconds
-        final int maxWait = 1200;
-        for (int i=0; i < maxWait; i++) {
-            if (deltaVisitor.isProjectBuilt()) {
-                return;
-            }
-            try {
-                Thread.sleep(50);
-            }
-            catch (InterruptedException e) {
-                
-            }
-           if (Display.getCurrent() != null) {
-               Display.getCurrent().readAndDispatch();
-           }
-        }
-        
-        sLogger.log(Level.SEVERE, "expected build event never happened?");
-        fail("expected build event never happened for " + iproject.getName());
-
-    }
-    
-    /**
-     * Scans a given IResourceDelta looking for a "build event" change for given IProject
-     * 
-     */
-    private class BuiltProjectDeltaVisitor implements IResourceDeltaVisitor {
-
-        private IProject mIProject;
-        private boolean  mIsBuilt;
-        
-        public BuiltProjectDeltaVisitor(IProject iproject) {
-            mIProject = iproject;
-            mIsBuilt = false;
-        }
-        
-        public boolean visit(IResourceDelta delta) {
-            if (mIProject.equals(delta.getResource())) {
-                setBuilt(true);
-                return false;
-            }
-            return true;
-        }
-        
-        private synchronized void setBuilt(boolean b) {
-            mIsBuilt = b;
-        }
-
-        public synchronized boolean isProjectBuilt() {
-            return mIsBuilt;
-        }
-        
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/test.xml b/tools/eclipse/plugins/com.android.ide.eclipse.tests/test.xml
deleted file mode 100644
index 792ebc2..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/test.xml
+++ /dev/null
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- test launcher file for Android Eclipse functional tests -->
-<project name="testsuite" default="run" basedir="."> 
-    <!--The following properties should be passed into this script, set to some default value for now -->
-    <property name="eclipse.home" value="/opt/eclipse" />
-    <property name="sdk_home" value="/tmp/sdk" />
-    <property name="eclipse_test" value="${eclipse.home}/plugins/org.eclipse.test_3.2.0" />
-	
-    <!-- eclipse scripts use an annoying mixture of eclipse-home and eclipse.home -->
-    <!-- lets define both...-->
-    <property name="eclipse-home" value="${eclipse.home}" />
-    <property name="test-folder" value="${eclipse.home}/test_folder" />
-        
-    <!-- sets the properties eclipse.home, and library-file -->
-    <property name="plugin-name" value="com.android.ide.eclipse.tests" />
-    <property name="library-file" value="${eclipse_test}/library.xml" />
-
-    <!-- location of adt preference file (within workspace) -->
-    <property name="prefs_path" value="${test-folder}/.metadata/.plugins/org.eclipse.core.runtime/.settings/com.android.ide.eclipse.adt.prefs" />
-    <!-- location of pref template file relative to this file -->
-
-    <property name="prefs_template" value="prefs.template" />
-
-    <!-- This target holds all initialization code that needs to be done for -->
-    <!-- all tests that are to be run.         -->
-    <target name="init">
-        <tstamp />
-        <echo message="eclipse.home:  ${eclipse.home}" />
-        <echo message="libfile:  ${library-file}" />
-        
-        <!-- delete test eclipse workspace -->
-        <delete dir="${test-folder}" quiet="true" />
-    	
-    	<!-- delete test results dir -->
-    	<delete dir="${eclipse.home}/results" quiet="true" />
-
-        <!-- Copy a preference file into the test workspace. -->
-        <!-- This is done to ensure Android SDK preference is set on startup -->
-        <copy file="${prefs_template}" tofile="${prefs_path}" />
-        <!-- replace sdk path placeholder token with actual sdk path -->
-        <replace file="${prefs_path}" token="sdk_home" value="${sdk_home}" />

-        

-        <!-- if this is on windows, escape the drive and file separators -->

-        <replace file="${prefs_path}" token="\" value="\\" />

-        <replace file="${prefs_path}" token=":" value="\:" />
-    </target>
-
-    <!-- This target defines the tests that need to be run. -->
-    <target name="suite">
-        <!-- launch as ui-test ie as a test which needs Eclipse workbench -->
-        <ant target="ui-test" antfile="${library-file}" dir="${eclipse.home}">
-            <property name="data-dir" value="${test-folder}" />
-            <property name="plugin-name" value="${plugin-name}" />
-            <property name="classname" value="com.android.ide.eclipse.tests.FuncTests" />
-            <!-- pass extra vm arg to set sdk_home env variable -->
-            <property name="extraVMargs" value="-Dsdk_home=${sdk_home}" />
-        </ant>
-    </target>
-
-    <!-- This target holds code to cleanup the testing environment after -->
-    <!-- after all of the tests have been run. You can use this target to -->
-    <!-- delete temporary files that have been created. -->
-    <target name="cleanup">
-    </target>
-
-    <!-- This target runs the test suite. Any actions that need to happen -->
-    <!-- after all the tests have been run should go here. -->
-    <target name="run" depends="init,suite,cleanup">
-        <ant target="collect" antfile="${library-file}" dir="${eclipse.home}/results">
-            <property name="includes" value="com*.xml" />
-            <property name="output-file" value="${plugin-name}.xml" />
-        </ant>
-    </target>
-</project>
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittest.xml b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittest.xml
deleted file mode 100644
index 83e00ec..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittest.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- test launcher file for Android Eclipse unit tests -->
-<project name="testsuite" default="run" basedir="."> 
-    <!--The following properties should be passed into this script, set to some default value for now -->
-    <property name="eclipse.home" value="/opt/eclipse" />
-    <property name="eclipse_test" value="${eclipse.home}/plugins/org.eclipse.test_3.2.0" />
-
-    <!-- eclipse scripts use an annoying mixture of eclipse-home and eclipse.home -->
-    <!-- lets define both...-->
-    <property name="eclipse-home" value="${eclipse.home}" />
-    <property name="test-folder" value="${eclipse.home}/unittest_ws" />
-        
-    <!-- sets the properties eclipse.home, and library-file -->
-    <property name="plugin-name" value="com.android.ide.eclipse.tests" />
-    <property name="library-file" value="${eclipse_test}/library.xml" />
-	
-    <!-- This target holds all initialization code that needs to be done for -->
-    <!-- all tests that are to be run.         -->
-    <target name="init">
-    	<ant antfile="test.xml" target="init">
-    		<property name="test-folder" value="${test-folder}" />
-        </ant>
-    </target>
-
-    <!-- This target defines the tests that need to be run. -->
-    <target name="suite">
-        <!-- need to launch as ui-test since all ADT plugins depend on ui-->
-    	<!-- otherwise other plugins will not load -->
-        <ant target="ui-test" antfile="${library-file}" dir="${eclipse.home}">
-            <property name="data-dir" value="${test-folder}" />
-            <property name="plugin-name" value="${plugin-name}" />
-            <property name="classname" value="com.android.ide.eclipse.tests.UnitTests" />
-            <!-- pass extra vm arg to set test_data env variable -->
-            <property name="extraVMargs" value="-Dtest_data=${test_data}" />
-        </ant>
-    </target>
-
-    <!-- This target holds code to cleanup the testing environment after -->
-    <!-- after all of the tests have been run. You can use this target to -->
-    <!-- delete temporary files that have been created. -->
-    <target name="cleanup">
-    </target>
-
-    <!-- This target runs the test suite. Any actions that need to happen -->
-    <!-- after all the tests have been run should go here. -->
-    <target name="run" depends="init,suite,cleanup">
-        <ant target="collect" antfile="${library-file}" dir="${eclipse.home}/results">
-            <property name="includes" value="com*.xml" />
-            <property name="output-file" value="${plugin-name}.xml" />
-        </ant>
-    </target>
-</project>
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/build/BaseBuilderTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/build/BaseBuilderTest.java
deleted file mode 100644
index 0860e40..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/build/BaseBuilderTest.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.build;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import junit.framework.TestCase;
-
-public class BaseBuilderTest extends TestCase {
-
-    public void testParseAaptOutput() {
-        Pattern p = Pattern.compile( "^(.+):(\\d+):\\s(.+)$"); //$NON-NLS-1$
-        String s = "C:\\java\\workspace-android\\AndroidApp\\res\\values\\strings.xml:11: WARNING: empty 'some warning text";
-
-        Matcher m = p.matcher(s);
-        assertEquals(true, m.matches());
-        assertEquals("C:\\java\\workspace-android\\AndroidApp\\res\\values\\strings.xml", m.group(1));
-        assertEquals("11", m.group(2));
-        assertEquals("WARNING: empty 'some warning text", m.group(3));
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/project/ProjectHelperTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/project/ProjectHelperTest.java
deleted file mode 100644
index 8c52d81..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/project/ProjectHelperTest.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.project;
-
-import com.android.ide.eclipse.mock.ClasspathEntryMock;
-import com.android.ide.eclipse.mock.JavaProjectMock;
-
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.JavaModelException;
-
-import junit.framework.TestCase;
-
-public class ProjectHelperTest extends TestCase {
-
-    /** The old container id */
-    private final static String OLD_CONTAINER_ID =
-        "com.android.ide.eclipse.adt.project.AndroidClasspathContainerInitializer"; //$NON-NLS-1$
-
-    /** The container id for the android framework jar file */
-    private final static String CONTAINER_ID =
-        "com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"; //$NON-NLS-1$
-    
-    @Override
-    public void setUp() throws Exception {
-        // pass for now
-    }
-
-    @Override
-    public void tearDown() throws Exception {
-        // pass for now
-    }
-    
-    public final void testFixProjectClasspathEntriesFromOldContainer() throws JavaModelException {
-        // create a project with a path to an android .zip
-        JavaProjectMock javaProject = new JavaProjectMock(
-                new IClasspathEntry[] {
-                        new ClasspathEntryMock(new Path("Project/src"), //$NON-NLS-1$
-                                IClasspathEntry.CPE_SOURCE),
-                        new ClasspathEntryMock(new Path(OLD_CONTAINER_ID),
-                                IClasspathEntry.CPE_CONTAINER),
-                },
-                new Path("Project/bin"));
-        
-        ProjectHelper.fixProjectClasspathEntries(javaProject);
-        
-        IClasspathEntry[] fixedEntries = javaProject.getRawClasspath();
-        assertEquals(3, fixedEntries.length);
-        assertEquals("Project/src", fixedEntries[0].getPath().toString());
-        assertEquals(OLD_CONTAINER_ID, fixedEntries[1].getPath().toString());
-        assertEquals(CONTAINER_ID, fixedEntries[2].getPath().toString());
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/AndroidJarLoaderTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/AndroidJarLoaderTest.java
deleted file mode 100644
index 8af7e02..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/AndroidJarLoaderTest.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.sdk.IAndroidClassLoader.IClassDescriptor;
-import com.android.ide.eclipse.tests.AdtTestData;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.HashMap;
-
-import junit.framework.TestCase;
-
-/**
- * Unit Test for {@link AndroidJarLoader}.
- * 
- * Uses the classes jar.example.Class1/Class2 stored in tests/data/jar_example.jar.
- */
-public class AndroidJarLoaderTest extends TestCase {
-
-    private AndroidJarLoader mFrameworkClassLoader;
-
-    /** Creates an instance of {@link AndroidJarLoader} on our test data JAR */ 
-    @Override
-    public void setUp() throws Exception {
-        String jarfilePath = AdtTestData.getInstance().getTestFilePath("jar_example.jar");  //$NON-NLS-1$
-        mFrameworkClassLoader = new AndroidJarLoader(jarfilePath);
-    }
-
-    @Override
-    public void tearDown() throws Exception {
-        mFrameworkClassLoader = null;
-        System.gc();
-    }
-
-    /** Preloads classes. They should load just fine. */
-    public final void testPreLoadClasses() throws Exception {
-        mFrameworkClassLoader.preLoadClasses("jar.example.", null, null); //$NON-NLS-1$
-        HashMap<String, Class<?>> map = getPrivateClassCache();
-        assertEquals(0, map.size());
-        HashMap<String,byte[]> data = getPrivateEntryCache();
-        assertTrue(data.containsKey("jar.example.Class1"));                    //$NON-NLS-1$
-        assertTrue(data.containsKey("jar.example.Class2"));                    //$NON-NLS-1$
-        assertTrue(data.containsKey("jar.example.Class1$InnerStaticClass1"));  //$NON-NLS-1$
-        assertTrue(data.containsKey("jar.example.Class1$InnerClass2"));  //$NON-NLS-1$
-        assertEquals(4, data.size());
-    }
-
-    /** Preloads a class not in the JAR. Preloading does nothing in this case. */
-    public final void testPreLoadClasses_classNotFound() throws Exception {
-        mFrameworkClassLoader.preLoadClasses("not.a.package.", null, null);  //$NON-NLS-1$
-        HashMap<String, Class<?>> map = getPrivateClassCache();
-        assertEquals(0, map.size());
-        HashMap<String,byte[]> data = getPrivateEntryCache();
-        assertEquals(0, data.size());
-    }
-
-    /** Finds a class we just preloaded. It should work. */
-    public final void testFindClass_classFound() throws Exception {
-        Class<?> c = _findClass(mFrameworkClassLoader, "jar.example.Class2");  //$NON-NLS-1$
-        assertEquals("jar.example.Class2", c.getName());              //$NON-NLS-1$
-        HashMap<String, Class<?>> map = getPrivateClassCache();
-        assertTrue(map.containsKey("jar.example.Class1"));            //$NON-NLS-1$
-        assertTrue(map.containsKey("jar.example.Class2"));            //$NON-NLS-1$
-        assertEquals(2, map.size());
-    }
-    
-    /** call the protected method findClass */
-    private Class<?> _findClass(AndroidJarLoader jarLoader, String name) throws Exception {
-        Method findClassMethod = AndroidJarLoader.class.getDeclaredMethod(
-                "findClass", String.class);  //$NON-NLS-1$
-        findClassMethod.setAccessible(true);
-        try {
-            return (Class<?>)findClassMethod.invoke(jarLoader, name);
-        }
-        catch (InvocationTargetException e) {
-           throw (Exception)e.getCause();
-        }
-    }
-
-    /** Trying to find a class that we fail to preload should throw a CNFE. */
-    public final void testFindClass_classNotFound() throws Exception {
-        try {
-            // Will throw ClassNotFoundException
-            _findClass(mFrameworkClassLoader, "not.a.valid.ClassName");  //$NON-NLS-1$
-        } catch (ClassNotFoundException e) {
-            // check the message in the CNFE
-            assertEquals("not.a.valid.ClassName", e.getMessage());  //$NON-NLS-1$
-            return;
-        }
-        // Exception not thrown - this is a failure
-        fail("Expected ClassNotFoundException not thrown");
-    }
-    
-    public final void testFindClassesDerivingFrom() throws Exception {
-        HashMap<String, ArrayList<IClassDescriptor>> found =
-            mFrameworkClassLoader.findClassesDerivingFrom("jar.example.", new String[] {  //$NON-NLS-1$
-                "jar.example.Class1",       //$NON-NLS-1$
-                "jar.example.Class2" });    //$NON-NLS-1$
-
-        assertTrue(found.containsKey("jar.example.Class1"));  //$NON-NLS-1$
-        assertTrue(found.containsKey("jar.example.Class2"));  //$NON-NLS-1$
-        assertEquals(2, found.size());  
-        // Only Class2 derives from Class1..
-        // Class1 and Class1$InnerStaticClass1 derive from Object and are thus ignored.
-        // Class1$InnerClass2 should never be seen either.
-        assertEquals("jar.example.Class2",  //$NON-NLS-1$
-                found.get("jar.example.Class1").get(0).getCanonicalName());  //$NON-NLS-1$
-        assertEquals(1, found.get("jar.example.Class1").size());      //$NON-NLS-1$
-        assertEquals(0, found.get("jar.example.Class2").size());      //$NON-NLS-1$
-    }
-
-    // --- Utilities ---
-    
-    /**
-     * Retrieves the private mFrameworkClassLoader.mClassCache field using reflection.
-     * 
-     * @throws NoSuchFieldException 
-     * @throws SecurityException 
-     * @throws IllegalAccessException 
-     * @throws IllegalArgumentException 
-     */
-    @SuppressWarnings("unchecked")
-    private HashMap<String, Class<?> > getPrivateClassCache()
-            throws SecurityException, NoSuchFieldException,
-                IllegalArgumentException, IllegalAccessException {
-        Field field = AndroidJarLoader.class.getDeclaredField("mClassCache");  //$NON-NLS-1$
-        field.setAccessible(true);
-        return (HashMap<String, Class<?>>) field.get(mFrameworkClassLoader);
-    }
-
-    /**
-     * Retrieves the private mFrameworkClassLoader.mEntryCache field using reflection.
-     * 
-     * @throws NoSuchFieldException 
-     * @throws SecurityException 
-     * @throws IllegalAccessException 
-     * @throws IllegalArgumentException 
-     */
-    @SuppressWarnings("unchecked")
-    private HashMap<String,byte[]> getPrivateEntryCache()
-            throws SecurityException, NoSuchFieldException,
-                IllegalArgumentException, IllegalAccessException {
-        Field field = AndroidJarLoader.class.getDeclaredField("mEntryCache");  //$NON-NLS-1$
-        field.setAccessible(true);
-        return (HashMap<String, byte[]>) field.get(mFrameworkClassLoader);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/LayoutParamsParserTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/LayoutParamsParserTest.java
deleted file mode 100644
index cedf4d4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/adt/sdk/LayoutParamsParserTest.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.adt.sdk;
-
-import com.android.ide.eclipse.adt.sdk.AndroidJarLoader.ClassWrapper;
-import com.android.ide.eclipse.adt.sdk.IAndroidClassLoader.IClassDescriptor;
-import com.android.ide.eclipse.common.resources.AttrsXmlParser;
-import com.android.ide.eclipse.common.resources.ViewClassInfo;
-import com.android.ide.eclipse.common.resources.ViewClassInfo.LayoutParamsInfo;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Method;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.TreeMap;
-
-import junit.framework.TestCase;
-
-/**
- * Test the inner private methods of PlatformDataParser.
- * 
- * Convention: method names that start with an underscore are actually local wrappers
- * that call private methods from {@link AndroidTargetParser} using reflection.
- * This is inspired by the Python coding rule which mandates underscores prefixes for
- * "private" methods.
- */
-public class LayoutParamsParserTest extends TestCase {
-
-    private static class MockFrameworkClassLoader extends AndroidJarLoader {
-        MockFrameworkClassLoader() {
-            super(null /* osFrameworkLocation */);
-        }
-        
-        @Override
-        public HashMap<String, ArrayList<IClassDescriptor>> findClassesDerivingFrom(
-                String rootPackage, String[] superClasses) throws ClassFormatError {
-            return new HashMap<String, ArrayList<IClassDescriptor>>();
-        }
-    }
-    
-    private static class MockAttrsXmlPath {
-        public String getPath() {
-            ClassLoader cl = this.getClass().getClassLoader();
-            URL res = cl.getResource("data/mock_attrs.xml");  //$NON-NLS-1$
-            return res.getFile();
-        }
-    }
-    
-    private static class MockLayoutParamsParser extends LayoutParamsParser {
-        public MockLayoutParamsParser() {
-            super(new MockFrameworkClassLoader(),
-                  new AttrsXmlParser(new MockAttrsXmlPath().getPath()).preload());
-
-            mTopViewClass = new ClassWrapper(mock_android.view.View.class);
-            mTopGroupClass = new ClassWrapper(mock_android.view.ViewGroup.class);
-            mTopLayoutParamsClass = new ClassWrapper(mock_android.view.ViewGroup.LayoutParams.class);
-
-            mViewList = new ArrayList<IClassDescriptor>();
-            mGroupList = new ArrayList<IClassDescriptor>();
-            mViewMap = new TreeMap<String, ExtViewClassInfo>();
-            mGroupMap = new TreeMap<String, ExtViewClassInfo>();
-            mLayoutParamsMap = new HashMap<String, LayoutParamsInfo>();
-        }
-    }
-
-    private MockLayoutParamsParser mParser;
-    
-    @Override
-    public void setUp() throws Exception {
-        mParser = new MockLayoutParamsParser();
-    }
-
-    @Override
-    public void tearDown() throws Exception {
-    }
-    
-    public final void testFindLayoutParams() throws Exception {
-        assertEquals(mock_android.view.ViewGroup.LayoutParams.class,
-            ((ClassWrapper)_findLayoutParams(mock_android.view.ViewGroup.class)).wrappedClass());
-
-        assertEquals(mock_android.widget.LinearLayout.LayoutParams.class,
-            ((ClassWrapper)_findLayoutParams(mock_android.widget.LinearLayout.class)).wrappedClass());
-
-        assertEquals(mock_android.widget.TableLayout.LayoutParams.class,
-            ((ClassWrapper)_findLayoutParams(mock_android.widget.TableLayout.class)).wrappedClass());
-    }
-    
-    public final void testGetLayoutParamsInfo() throws Exception {
-        LayoutParamsInfo info1 = _getLayoutParamsInfo(
-                mock_android.view.ViewGroup.LayoutParams.class);
-        assertNotNull(info1);
-        // ViewGroup.LayoutData has Object for superClass, which we don't map
-        assertNull(info1.getSuperClass());
-
-        LayoutParamsInfo info2 = _getLayoutParamsInfo(
-                mock_android.widget.LinearLayout.LayoutParams.class);
-        assertNotNull(info2);
-        // LinearLayout.LayoutData links to ViewGroup.LayoutParams
-        assertSame(info1, info2.getSuperClass());
-        
-        LayoutParamsInfo info3 = _getLayoutParamsInfo(
-                mock_android.widget.TableLayout.LayoutParams.class);
-        assertNotNull(info3);
-        // TableLayout.LayoutData does not link to ViewGroup.LayoutParams nor
-        // LinearLayout.LayoutParams
-        assertNotSame(info1, info3.getSuperClass());
-        assertNotSame(info2, info3.getSuperClass());
-        // TableLayout.LayoutParams => ViewGroup.MarginLayoutParams => ViewGroup.LayoutParams
-        assertSame(info1, info3.getSuperClass().getSuperClass());        
-    }
-
-    public final void testGetLayoutClasses() throws Exception {
-        // _getLayoutClasses();
-    }
-
-    //---- access to private methods
-    
-    /** Calls the private constructor of the parser */
-    @SuppressWarnings("unused")
-    private AndroidTargetParser _Constructor(String osJarPath) throws Exception {
-        Constructor<AndroidTargetParser> constructor =
-            AndroidTargetParser.class.getDeclaredConstructor(String.class);
-        constructor.setAccessible(true);
-        return constructor.newInstance(osJarPath);
-    }
-    
-    /** calls the private getLayoutClasses() of the parser */
-    @SuppressWarnings("unused")
-    private void _getLayoutClasses() throws Exception {
-        Method method = AndroidTargetParser.class.getDeclaredMethod("getLayoutClasses");  //$NON-NLS-1$
-        method.setAccessible(true);
-        method.invoke(mParser);
-    }
-    
-    /** calls the private addGroup() of the parser */
-    @SuppressWarnings("unused")
-    private ViewClassInfo _addGroup(Class<?> groupClass) throws Exception {
-        Method method = LayoutParamsParser.class.getDeclaredMethod("addGroup",  //$NON-NLS-1$
-                IClassDescriptor.class);
-        method.setAccessible(true);
-        return (ViewClassInfo) method.invoke(mParser, new ClassWrapper(groupClass));
-    }
-
-    /** calls the private addLayoutParams() of the parser */
-    @SuppressWarnings("unused")
-    private LayoutParamsInfo _addLayoutParams(Class<?> groupClass) throws Exception {
-        Method method = LayoutParamsParser.class.getDeclaredMethod("addLayoutParams",   //$NON-NLS-1$
-                IClassDescriptor.class);
-        method.setAccessible(true);
-        return (LayoutParamsInfo) method.invoke(mParser, new ClassWrapper(groupClass));
-    }
-
-    /** calls the private getLayoutParamsInfo() of the parser */
-    private LayoutParamsInfo _getLayoutParamsInfo(Class<?> layoutParamsClass) throws Exception {
-        Method method = LayoutParamsParser.class.getDeclaredMethod("getLayoutParamsInfo",   //$NON-NLS-1$
-                IClassDescriptor.class);
-        method.setAccessible(true);
-        return (LayoutParamsInfo) method.invoke(mParser, new ClassWrapper(layoutParamsClass));
-    }
-    
-    /** calls the private findLayoutParams() of the parser */
-    private IClassDescriptor _findLayoutParams(Class<?> groupClass) throws Exception {
-        Method method = LayoutParamsParser.class.getDeclaredMethod("findLayoutParams",  //$NON-NLS-1$
-                IClassDescriptor.class);
-        method.setAccessible(true);
-        return (IClassDescriptor) method.invoke(mParser, new ClassWrapper(groupClass));
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/project/AndroidManifestHelperTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/project/AndroidManifestHelperTest.java
deleted file mode 100644
index 6604264..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/project/AndroidManifestHelperTest.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.project;
-
-import java.io.File;
-import java.io.FileWriter;
-import java.io.IOException;
-
-import junit.framework.TestCase;
-
-public class AndroidManifestHelperTest extends TestCase {
-    private File mFile;
-    private AndroidManifestHelper mManifest;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        mFile = File.createTempFile("androidManifest", "xml");  //$NON-NLS-1$ //$NON-NLS-2$
-        assertNotNull(mFile);
-
-        FileWriter fw = new FileWriter(mFile);
-        fw.write("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n");  //$NON-NLS-1$
-        fw.write("<manifest xmlns:android=\"http://schemas.android.com/apk/res/android\"\n");  //$NON-NLS-1$
-        fw.write("          package=\"com.android.testapp\">\n");  //$NON-NLS-1$
-        fw.write("  <application android:icon=\"@drawable/icon\">\n");  //$NON-NLS-1$
-        fw.write("    <activity android:name=\".MainActivity\" android:label=\"@string/app_name\">\n");  //$NON-NLS-1$
-        fw.write("      <intent-filter>\n");  //$NON-NLS-1$
-        fw.write("        <action android:name=\"android.intent.action.MAIN\" />\n");  //$NON-NLS-1$
-        fw.write("          <category android:name=\"android.intent.category.LAUNCHER\" />\"\n");  //$NON-NLS-1$
-        fw.write("          <category android:name=\"android.intent.category.DEFAULT\" />\n");  //$NON-NLS-1$
-        fw.write("      </intent-filter>\n");  //$NON-NLS-1$
-        fw.write("    </activity>\n");  //$NON-NLS-1$
-        fw.write("    <activity android:name=\".OptionsActivity\" android:label=\"@string/options\"\n");  //$NON-NLS-1$
-        fw.write("              android:theme=\"@style/Theme.Floating\">\n");  //$NON-NLS-1$
-        fw.write("      <intent-filter>\n");  //$NON-NLS-1$
-        fw.write("        <action android:name=\"com.android.mandelbrot.action.EDIT_OPTIONS\" />\n");  //$NON-NLS-1$
-        fw.write("        <category android:name=\"android.intent.category.PREFERENCE_CATEGORY\" />\n");  //$NON-NLS-1$
-        fw.write("      </intent-filter>\n");  //$NON-NLS-1$
-        fw.write("    </activity>\n");  //$NON-NLS-1$
-        fw.write("    <activity android:name=\".InfoActivity\" android:label=\"@string/options\"\n");  //$NON-NLS-1$
-        fw.write("             android:theme=\"@style/Theme.Floating\">\n");  //$NON-NLS-1$
-        fw.write("      <intent-filter>\n");  //$NON-NLS-1$
-        fw.write("        <action android:name=\"com.android.mandelbrot.action.DISPLAY_INFO\" />\n");  //$NON-NLS-1$
-        fw.write("      </intent-filter>\n");  //$NON-NLS-1$
-        fw.write("    </activity>\n");  //$NON-NLS-1$
-        fw.write("  </application>\n");  //$NON-NLS-1$
-        fw.write("</manifest>\n");  //$NON-NLS-1$
-        fw.flush();
-        fw.close();
-
-        mManifest = new AndroidManifestHelper(mFile.getAbsolutePath());
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        assertTrue(mFile.delete());
-        super.tearDown();
-    }
-
-    public void testExists() {
-        assertTrue(mManifest.exists());
-    }
-
-    public void testNotExists() throws IOException {
-        File f = File.createTempFile("androidManifest2", "xml");  //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue(f.delete());
-        AndroidManifestHelper manifest = new AndroidManifestHelper(f.getAbsolutePath());
-        assertFalse(manifest.exists());
-    }
-
-    public void testGetPackageName() {
-        assertEquals("com.android.testapp", mManifest.getPackageName());
-    }
-
-    public void testGetActivityName() {
-        assertEquals("", mManifest.getActivityName(0));  //$NON-NLS-1$
-        assertEquals(".MainActivity", mManifest.getActivityName(1));  //$NON-NLS-1$
-        assertEquals(".OptionsActivity", mManifest.getActivityName(2));  //$NON-NLS-1$
-        assertEquals(".InfoActivity", mManifest.getActivityName(3));  //$NON-NLS-1$
-        assertEquals("", mManifest.getActivityName(4));  //$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/resources/AttrsXmlParserTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/resources/AttrsXmlParserTest.java
deleted file mode 100644
index 8338453..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/common/resources/AttrsXmlParserTest.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.common.resources;
-
-
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo;
-import com.android.ide.eclipse.common.resources.DeclareStyleableInfo.AttributeInfo.Format;
-import com.android.ide.eclipse.tests.AdtTestData;
-
-import org.w3c.dom.Document;
-
-import java.lang.reflect.Method;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-public class AttrsXmlParserTest extends TestCase {
-    
-    private AttrsXmlParser mParser;
-    private String mFilePath;
-
-    @Override
-    public void setUp() throws Exception {
-        mFilePath = AdtTestData.getInstance().getTestFilePath("mock_attrs.xml"); //$NON-NLS-1$
-        mParser = new AttrsXmlParser(mFilePath);
-    }
-
-    @Override
-    public void tearDown() throws Exception {
-    }
-    
-    public final void testGetDocument() throws Exception {
-        assertNotNull(_getDocument());
-    }
-
-    public void testGetOsAttrsXmlPath() throws Exception {
-        assertEquals(mFilePath, mParser.getOsAttrsXmlPath());
-    }
-    
-    public final void testPreload() throws Exception {
-        assertSame(mParser, mParser.preload());
-    }
-    
-    
-    public final void testLoadViewAttributes() throws Exception {
-        mParser.preload();
-        ViewClassInfo info = new ViewClassInfo(
-                false /* isLayout */,
-                "mock_android.something.Theme",      //$NON-NLS-1$
-                "Theme");                            //$NON-NLS-1$
-        mParser.loadViewAttributes(info);
-        
-        assertEquals("These are the standard attributes that make up a complete theme.", //$NON-NLS-1$
-                info.getJavaDoc());
-        AttributeInfo[] attrs = info.getAttributes();
-        assertEquals(1, attrs.length);
-        assertEquals("scrollbarSize", info.getAttributes()[0].getName());
-        assertEquals(1, info.getAttributes()[0].getFormats().length);
-        assertEquals(Format.DIMENSION, info.getAttributes()[0].getFormats()[0]);
-    }
-    
-    public final void testEnumFlagValues() throws Exception {
-        /* The XML being read contains:
-            <!-- Standard orientation constant. -->
-            <attr name="orientation">
-                <!-- Defines an horizontal widget. -->
-                <enum name="horizontal" value="0" />
-                <!-- Defines a vertical widget. -->
-                <enum name="vertical" value="1" />
-            </attr>
-         */
-
-        mParser.preload();
-        Map<String, Map<String, Integer>> attrMap = mParser.getEnumFlagValues();
-        assertTrue(attrMap.containsKey("orientation"));
-        
-        Map<String, Integer> valueMap = attrMap.get("orientation");
-        assertTrue(valueMap.containsKey("horizontal"));
-        assertTrue(valueMap.containsKey("vertical"));
-        assertEquals(Integer.valueOf(0), valueMap.get("horizontal"));
-        assertEquals(Integer.valueOf(1), valueMap.get("vertical"));
-    }
-    
-    public final void testDeprecated() throws Exception {
-        mParser.preload();
-        
-        DeclareStyleableInfo dep = mParser.getDeclareStyleableList().get("DeprecatedTest");
-        assertNotNull(dep);
-        
-        AttributeInfo[] attrs = dep.getAttributes();
-        assertEquals(4, attrs.length);
-
-        assertEquals("deprecated-inline", attrs[0].getName());
-        assertEquals("In-line deprecated.", attrs[0].getDeprecatedDoc());
-        assertEquals("Deprecated comments using delimiters.", attrs[0].getJavaDoc());
-        
-        assertEquals("deprecated-multiline", attrs[1].getName());
-        assertEquals("Multi-line version of deprecated that works till the next tag.",
-                attrs[1].getDeprecatedDoc());
-        assertEquals("Deprecated comments on their own line.", attrs[1].getJavaDoc());
-        
-        assertEquals("deprecated-not", attrs[2].getName());
-        assertEquals(null, attrs[2].getDeprecatedDoc());
-        assertEquals("This attribute is not deprecated.", attrs[2].getJavaDoc());
-
-        assertEquals("deprecated-no-javadoc", attrs[3].getName());
-        assertEquals("There is no other javadoc here.", attrs[3].getDeprecatedDoc());
-        assertEquals("", attrs[3].getJavaDoc());
-    }
-
-    //---- access to private methods
-    
-    private Document _getDocument() throws Exception {
-        Method method = AttrsXmlParser.class.getDeclaredMethod("getDocument"); //$NON-NLS-1$
-        method.setAccessible(true);
-        return (Document) method.invoke(mParser);
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/descriptors/DescriptorsUtilsTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/descriptors/DescriptorsUtilsTest.java
deleted file mode 100644
index 69c3ed8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/descriptors/DescriptorsUtilsTest.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package com.android.ide.eclipse.editors.descriptors;
-
-import junit.framework.TestCase;
-
-/**
- * Unit tests for DescriptorsUtils in the editors plugin
- */
-public class DescriptorsUtilsTest extends TestCase {
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-    }
-
-    public void testPrettyAttributeUiName() {
-        assertEquals("", DescriptorsUtils.prettyAttributeUiName(""));
-
-        assertEquals("Max width for view",
-                DescriptorsUtils.prettyAttributeUiName("maxWidthForView"));
-
-        assertEquals("Layout width",
-                DescriptorsUtils.prettyAttributeUiName("layout_width"));
-
-        // X Y and Z are capitalized when used as single words (so "T" becomes "t")
-        assertEquals("Axis X", DescriptorsUtils.prettyAttributeUiName("axisX"));
-        assertEquals("Axis Y", DescriptorsUtils.prettyAttributeUiName("axisY"));
-        assertEquals("Axis Z", DescriptorsUtils.prettyAttributeUiName("axisZ"));
-        assertEquals("Axis t", DescriptorsUtils.prettyAttributeUiName("axisT"));
-
-        assertEquals("The X axis", DescriptorsUtils.prettyAttributeUiName("theXAxis"));
-        assertEquals("The Y axis", DescriptorsUtils.prettyAttributeUiName("theYAxis"));
-        assertEquals("The Z axis", DescriptorsUtils.prettyAttributeUiName("theZAxis"));
-        assertEquals("The t axis", DescriptorsUtils.prettyAttributeUiName("theTAxis"));
-    }
-
-    public void testCapitalize() {
-        assertEquals("UPPER", DescriptorsUtils.capitalize("UPPER"));
-        assertEquals("Lower", DescriptorsUtils.capitalize("lower"));
-        assertEquals("Capital", DescriptorsUtils.capitalize("Capital"));
-        assertEquals("CamelCase", DescriptorsUtils.capitalize("camelCase"));
-        assertEquals("", DescriptorsUtils.capitalize(""));
-    }
-
-    public void testFormatTooltip() {
-        assertEquals("", DescriptorsUtils.formatTooltip(""));
-
-        assertEquals("\"application\"",
-                DescriptorsUtils.formatTooltip(
-                        "<code>application</code>"));
-
-        assertEquals("android.content.Intent",
-                DescriptorsUtils.formatTooltip(
-                        "{@link android.content.Intent}"));
-        
-        assertEquals("FLAG_ACTIVITY_SINGLE_TOP",
-                DescriptorsUtils.formatTooltip(
-                        "{@link android.content.Intent#FLAG_ACTIVITY_SINGLE_TOP}"));
-        
-        assertEquals("activity-alias",
-                DescriptorsUtils.formatTooltip(
-                        "{@link \t  #AndroidManifestActivityAlias  \tactivity-alias }"));
-        
-        assertEquals("\"permission\"",
-                DescriptorsUtils.formatTooltip(
-                        "{@link #AndroidManifestPermission &lt;permission&gt;}"));
-        
-        assertEquals("and etc.",
-                DescriptorsUtils.formatTooltip(
-                        "{@link #IntentCategory <category> and etc. }"));
-        
-        assertEquals("Activity.onNewIntent()",
-                DescriptorsUtils.formatTooltip(
-                        "{@link android.app.Activity#onNewIntent Activity.onNewIntent()}"));
-    }
-
-    public void testFormatFormText() {
-        ElementDescriptor desc = new ElementDescriptor("application");
-        desc.setSdkUrl(DescriptorsUtils.MANIFEST_SDK_URL + "TagApplication");
-        String docBaseUrl = "http://base";
-        assertEquals("<form><li style=\"image\" value=\"image\"></li></form>", DescriptorsUtils.formatFormText("", desc, docBaseUrl));
-
-        assertEquals("<form><li style=\"image\" value=\"image\"><a href=\"http://base/reference/android/R.styleable.html#TagApplication\">application</a></li></form>",
-                DescriptorsUtils.formatFormText(
-                        "<code>application</code>",
-                        desc, docBaseUrl));
-
-        assertEquals("<form><li style=\"image\" value=\"image\"><b>android.content.Intent</b></li></form>",
-                DescriptorsUtils.formatFormText(
-                        "{@link android.content.Intent}",
-                        desc, docBaseUrl));
-
-        assertEquals("<form><li style=\"image\" value=\"image\"><a href=\"http://base/reference/android/R.styleable.html#AndroidManifestPermission\">AndroidManifestPermission</a></li></form>",
-                DescriptorsUtils.formatFormText(
-                        "{@link #AndroidManifestPermission}",
-                        desc, docBaseUrl));
-
-        assertEquals("<form><li style=\"image\" value=\"image\"><a href=\"http://base/reference/android/R.styleable.html#AndroidManifestPermission\">\"permission\"</a></li></form>",
-                DescriptorsUtils.formatFormText(
-                        "{@link #AndroidManifestPermission &lt;permission&gt;}",
-                        desc, docBaseUrl));
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/layout/UiElementPullParserTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/layout/UiElementPullParserTest.java
deleted file mode 100644
index b0deda0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/layout/UiElementPullParserTest.java
+++ /dev/null
@@ -1,240 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.layout;
-
-import com.android.ide.eclipse.editors.descriptors.AttributeDescriptor;
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.descriptors.TextAttributeDescriptor;
-import com.android.ide.eclipse.editors.mock.MockXmlNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-import com.android.sdklib.SdkConstants;
-
-import org.w3c.dom.Node;
-import org.xmlpull.v1.XmlPullParser;
-import org.xmlpull.v1.XmlPullParserException;
-
-import java.util.HashMap;
-
-import junit.framework.TestCase;
-
-public class UiElementPullParserTest extends TestCase {
-
-    private UiElementNode ui;
-    private HashMap<String, String> button1Map;
-    private HashMap<String, String> button2Map;
-    private HashMap<String, String> textMap;
-
-    @Override
-    protected void setUp() throws Exception {
-        // set up some basic descriptors.
-        // We have button, textview, linear layout, relative layout.
-        // only the layouts have children (all 4 descriptors possible)
-        // Also add some dummy attributes.
-        ElementDescriptor buttonDescriptor = new ElementDescriptor("Button", "Button", "", "",
-                new AttributeDescriptor[] {
-                    new TextAttributeDescriptor("name", "name", SdkConstants.NS_RESOURCES, ""),
-                    new TextAttributeDescriptor("text", "text", SdkConstants.NS_RESOURCES, ""),
-                    },
-                new ElementDescriptor[] {}, false);
-
-        ElementDescriptor textDescriptor = new ElementDescriptor("TextView", "TextView", "", "",
-                new AttributeDescriptor[] {
-                new TextAttributeDescriptor("name", "name", SdkConstants.NS_RESOURCES, ""),
-                new TextAttributeDescriptor("text", "text", SdkConstants.NS_RESOURCES, ""), },
-                new ElementDescriptor[] {}, false);
-
-        ElementDescriptor linearDescriptor = new ElementDescriptor("LinearLayout", "Linear Layout",
-                "", "",
-                new AttributeDescriptor[] {
-                    new TextAttributeDescriptor("orientation", "orientation",
-                            SdkConstants.NS_RESOURCES, ""),
-                },
-                new ElementDescriptor[] { }, false);
-
-        ElementDescriptor relativeDescriptor = new ElementDescriptor("RelativeLayout",
-                "Relative Layout", "", "",
-                new AttributeDescriptor[] {
-                    new TextAttributeDescriptor("orientation", "orientation",
-                            SdkConstants.NS_RESOURCES, ""),
-                },
-                new ElementDescriptor[] { }, false);
-
-        ElementDescriptor[] a = new ElementDescriptor[] {
-                buttonDescriptor, textDescriptor, linearDescriptor, relativeDescriptor
-        };
-        
-        linearDescriptor.setChildren(a);
-        relativeDescriptor.setChildren(a);
-
-        // document descriptor
-        ElementDescriptor rootDescriptor = new ElementDescriptor("root", "", "", "",
-                new AttributeDescriptor[] { }, a, false);
-
-        
-        ui = new UiElementNode(rootDescriptor);
-        
-        /* create a dummy XML file.
-         * <LinearLayout android:orientation="vertical">
-         *      <Button android:name="button1" android:text="button1text"/>
-         *      <RelativeLayout android:orientation="toto">
-         *          <Button android:name="button2" android:text="button2text"/>
-         *          <TextView android:name="text1" android:text="text1text"/>
-         *      </RelativeLayout>
-         * </LinearLayout>
-         */
-        MockXmlNode button1 = new MockXmlNode(null /* namespace */, "Button", Node.ELEMENT_NODE,
-                null);
-        button1.addAttributes(SdkConstants.NS_RESOURCES, "name", "button1");
-        button1.addAttributes(SdkConstants.NS_RESOURCES, "text", "button1text");
-        
-        // create a map of the attributes we add to the multi-attribute nodes so that
-        // we can more easily test the values when we parse the XML.
-        // This is due to some attributes showing in a certain order for a node and in a different
-        // order in another node. Since the order doesn't matter, we just simplify the test.
-        button1Map = new HashMap<String, String>();
-        button1Map.put("name", "button1");
-        button1Map.put("text", "button1text");
-
-        MockXmlNode button2 = new MockXmlNode(null /* namespace */, "Button", Node.ELEMENT_NODE,
-                null);
-        button2.addAttributes(SdkConstants.NS_RESOURCES, "name", "button2");
-        button2.addAttributes(SdkConstants.NS_RESOURCES, "text", "button2text");
-
-        button2Map = new HashMap<String, String>();
-        button2Map.put("name", "button2");
-        button2Map.put("text", "button2text");
-        
-        MockXmlNode text = new MockXmlNode(null /* namespace */, "TextView", Node.ELEMENT_NODE,
-                null);
-        text.addAttributes(SdkConstants.NS_RESOURCES, "name", "text1");
-        text.addAttributes(SdkConstants.NS_RESOURCES, "text", "text1text");
-
-        textMap = new HashMap<String, String>();
-        textMap.put("name", "text1");
-        textMap.put("text", "text1text");
-
-        MockXmlNode relative = new MockXmlNode(null /* namespace */, "RelativeLayout",
-                Node.ELEMENT_NODE, new MockXmlNode[] { button2, text });
-        relative.addAttributes(SdkConstants.NS_RESOURCES, "orientation", "toto");
-        
-        MockXmlNode linear = new MockXmlNode(null /* namespace */, "LinearLayout",
-                Node.ELEMENT_NODE, new MockXmlNode[] { button1, relative });
-        linear.addAttributes(SdkConstants.NS_RESOURCES, "orientation", "vertical");
-        
-        MockXmlNode root = new MockXmlNode(null /* namespace */, "root", Node.ELEMENT_NODE,
-                new MockXmlNode[] { linear });
-        
-        // put the namespace/prefix in place
-        root.setPrefix(SdkConstants.NS_RESOURCES, "android");
-
-        // load the xml into the UiElementNode
-        ui.loadFromXmlNode(root);
-
-        super.setUp();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-    }
-    
-    public void testParser() {
-        try {
-            // wrap the parser around the ui element node, and start parsing
-            UiElementPullParser parser = new UiElementPullParser(ui);
-            
-            assertEquals(XmlPullParser.START_DOCUMENT, parser.getEventType());
-            
-            // top level Linear layout
-            assertEquals(XmlPullParser.START_TAG, parser.next());
-            assertEquals("LinearLayout", parser.getName());
-            assertEquals(1, parser.getAttributeCount());
-            assertEquals("orientation", parser.getAttributeName(0));
-            assertEquals(SdkConstants.NS_RESOURCES, parser.getAttributeNamespace(0));
-            assertEquals("android", parser.getAttributePrefix(0));
-            assertEquals("vertical", parser.getAttributeValue(0));
-            
-            // Button
-            assertEquals(XmlPullParser.START_TAG, parser.next());
-            assertEquals("Button", parser.getName());
-            assertEquals(2, parser.getAttributeCount());
-            check(parser, 0, button1Map);
-            check(parser, 1, button1Map);
-            // end of button
-            assertEquals(XmlPullParser.END_TAG, parser.next());
-
-            // Relative Layout
-            assertEquals(XmlPullParser.START_TAG, parser.next());
-            assertEquals("RelativeLayout", parser.getName());
-            assertEquals(1, parser.getAttributeCount());
-            assertEquals("orientation", parser.getAttributeName(0));
-            assertEquals(SdkConstants.NS_RESOURCES, parser.getAttributeNamespace(0));
-            assertEquals("android", parser.getAttributePrefix(0));
-            assertEquals("toto", parser.getAttributeValue(0));
-
-            // Button
-            assertEquals(XmlPullParser.START_TAG, parser.next());
-            assertEquals("Button", parser.getName());
-            assertEquals(2, parser.getAttributeCount());
-            check(parser, 0, button2Map);
-            check(parser, 1, button2Map);
-            // end of button
-            assertEquals(XmlPullParser.END_TAG, parser.next());
-
-            // TextView
-            assertEquals(XmlPullParser.START_TAG, parser.next());
-            assertEquals("TextView", parser.getName());
-            assertEquals(2, parser.getAttributeCount());
-            check(parser, 0, textMap);
-            check(parser, 1, textMap);
-            // end of TextView
-            assertEquals(XmlPullParser.END_TAG, parser.next());
-            
-            // end of RelativeLayout
-            assertEquals(XmlPullParser.END_TAG, parser.next());
-
-            
-            // end of top level linear layout
-            assertEquals(XmlPullParser.END_TAG, parser.next());
-            
-            assertEquals(XmlPullParser.END_DOCUMENT, parser.next());
-        } catch (XmlPullParserException e) {
-            e.printStackTrace();
-            assertTrue(false);
-        }
-    }
-
-    /**
-     * Receives a {@link XmlPullParser} at the START_TAG level, and checks the i-th attribute
-     * to be present in the {@link HashMap} with the proper (name, value)
-     * @param parser
-     * @param i
-     * @param map
-     */
-    private void check(UiElementPullParser parser, int i, HashMap<String, String> map) {
-        String name = parser.getAttributeName(i);
-        String value = parser.getAttributeValue(i);
-        
-        String referenceValue = map.get(name);
-        assertNotNull(referenceValue);
-        assertEquals(referenceValue, value);
-        
-        assertEquals(SdkConstants.NS_RESOURCES, parser.getAttributeNamespace(i));
-        assertEquals("android", parser.getAttributePrefix(i));
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/manifest/model/UiElementNodeTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/manifest/model/UiElementNodeTest.java
deleted file mode 100644
index e75d9ef..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/manifest/model/UiElementNodeTest.java
+++ /dev/null
@@ -1,211 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.manifest.model;
-
-import com.android.ide.eclipse.editors.descriptors.ElementDescriptor;
-import com.android.ide.eclipse.editors.mock.MockXmlNode;
-import com.android.ide.eclipse.editors.uimodel.UiElementNode;
-
-import org.w3c.dom.Node;
-
-import java.util.Iterator;
-
-import junit.framework.TestCase;
-
-public class UiElementNodeTest extends TestCase {
-
-    private ElementDescriptor e;
-    private UiElementNode ui;
-
-    @Override
-    protected void setUp() throws Exception {
-        e = new ElementDescriptor("manifest", new ElementDescriptor[] {
-                new ElementDescriptor("application", new ElementDescriptor[] {
-                    new ElementDescriptor("provider"), 
-                    new ElementDescriptor("activity", new ElementDescriptor[] {
-                        new ElementDescriptor("intent-filter")
-                    }), 
-                }), 
-                new ElementDescriptor("permission")
-            });
-        
-        ui = new UiElementNode(e);
-        
-        super.setUp();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        // pass
-    }
-
-    /**
-     * Check initialization values for ui node
-     */
-    public void testInit() {
-        assertSame(e, ui.getDescriptor());
-        assertNull(ui.getUiParent());
-        assertEquals(0, ui.getUiChildren().size());
-        assertEquals(0, ui.getUiAttributes().size());
-    }
-    
-    /**
-     * loadFrom() does nothing if the root node doesn't match what's expected
-     */
-    public void testLoadFrom_InvalidRoot() {
-        assertEquals(0, ui.getUiChildren().size());
-        MockXmlNode root = new MockXmlNode(null /* namespace */, "blah", Node.ELEMENT_NODE, null);
-        ui.loadFromXmlNode(root);
-        assertEquals(0, ui.getUiChildren().size());
-    }
-
-    /**
-     * UiElementNode.loadFrom should be used to populate an empty ui node from an
-     * existing XML node tree.
-     */
-    public void testLoadFrom_NewTree_1_Node() {
-        MockXmlNode root = new MockXmlNode(null /* namespace */, "manifest", Node.ELEMENT_NODE,
-            new MockXmlNode[] {
-                new MockXmlNode(null /* namespace */, "application", Node.ELEMENT_NODE, null)
-            });
-        
-        // get /manifest
-        ui.loadFromXmlNode(root);
-        assertEquals("manifest", ui.getDescriptor().getXmlName());
-        assertEquals(1, ui.getUiChildren().size());
-        assertEquals(0, ui.getUiAttributes().size());
-
-        // get /manifest/application
-        Iterator<UiElementNode> ui_child_it = ui.getUiChildren().iterator();
-        UiElementNode application = ui_child_it.next();
-        assertEquals("application", application.getDescriptor().getXmlName());
-        assertEquals(0, application.getUiChildren().size());
-        assertEquals(0, application.getUiAttributes().size());
-    }
-
-
-    public void testLoadFrom_NewTree_2_Nodes() {
-        MockXmlNode root = new MockXmlNode(null /* namespace */, "manifest", Node.ELEMENT_NODE,
-            new MockXmlNode[] {
-                new MockXmlNode(null /* namespace */, "application", Node.ELEMENT_NODE, null),
-                new MockXmlNode(null /* namespace */, "permission", Node.ELEMENT_NODE, null),
-            });
-        
-        // get /manifest
-        ui.loadFromXmlNode(root);
-        assertEquals("manifest", ui.getDescriptor().getXmlName());
-        assertEquals(2, ui.getUiChildren().size());
-        assertEquals(0, ui.getUiAttributes().size());
-
-        // get /manifest/application
-        Iterator<UiElementNode> ui_child_it = ui.getUiChildren().iterator();
-        UiElementNode application = ui_child_it.next();
-        assertEquals("application", application.getDescriptor().getXmlName());
-        assertEquals(0, application.getUiChildren().size());
-        assertEquals(0, application.getUiAttributes().size());
-
-        // get /manifest/permission
-        UiElementNode first_permission = ui_child_it.next();
-        assertEquals("permission", first_permission.getDescriptor().getXmlName());
-        assertEquals(0, first_permission.getUiChildren().size());
-        assertEquals(0, first_permission.getUiAttributes().size());
-    }
-
-    public void testLoadFrom_NewTree_N_Nodes() {
-        MockXmlNode root = new MockXmlNode(null /* namespace */, "manifest", Node.ELEMENT_NODE,
-            new MockXmlNode[] {
-                new MockXmlNode(null /* namespace */, "application", Node.ELEMENT_NODE,
-                    new MockXmlNode[] {
-                        new MockXmlNode(null /* namespace */, "activity", Node.ELEMENT_NODE,
-                            null),
-                        new MockXmlNode(null /* namespace */, "activity", Node.ELEMENT_NODE,
-                            new MockXmlNode[] {
-                                new MockXmlNode(null /* namespace */, "intent-filter",
-                                        Node.ELEMENT_NODE, null),
-                            }),
-                        new MockXmlNode(null /* namespace */, "provider", Node.ELEMENT_NODE,
-                                null),
-                        new MockXmlNode(null /* namespace */, "provider", Node.ELEMENT_NODE,
-                                null),
-                    }),
-                new MockXmlNode(null /* namespace */, "permission", Node.ELEMENT_NODE,
-                        null),
-                new MockXmlNode(null /* namespace */, "permission", Node.ELEMENT_NODE,
-                        null),
-            });
-        
-        // get /manifest
-        ui.loadFromXmlNode(root);
-        assertEquals("manifest", ui.getDescriptor().getXmlName());
-        assertEquals(3, ui.getUiChildren().size());
-        assertEquals(0, ui.getUiAttributes().size());
-
-        // get /manifest/application
-        Iterator<UiElementNode> ui_child_it = ui.getUiChildren().iterator();
-        UiElementNode application = ui_child_it.next();
-        assertEquals("application", application.getDescriptor().getXmlName());
-        assertEquals(4, application.getUiChildren().size());
-        assertEquals(0, application.getUiAttributes().size());
-
-        // get /manifest/application/activity #1
-        Iterator<UiElementNode> app_child_it = application.getUiChildren().iterator();
-        UiElementNode first_activity = app_child_it.next();
-        assertEquals("activity", first_activity.getDescriptor().getXmlName());
-        assertEquals(0, first_activity.getUiChildren().size());
-        assertEquals(0, first_activity.getUiAttributes().size());
-
-        // get /manifest/application/activity #2
-        UiElementNode second_activity = app_child_it.next();
-        assertEquals("activity", second_activity.getDescriptor().getXmlName());
-        assertEquals(1, second_activity.getUiChildren().size());
-        assertEquals(0, second_activity.getUiAttributes().size());
-
-        // get /manifest/application/activity #2/intent-filter #1
-        Iterator<UiElementNode> activity_child_it = second_activity.getUiChildren().iterator();
-        UiElementNode intent_filter = activity_child_it.next();
-        assertEquals("intent-filter", intent_filter.getDescriptor().getXmlName());
-        assertEquals(0, intent_filter.getUiChildren().size());
-        assertEquals(0, intent_filter.getUiAttributes().size());
-
-        // get /manifest/application/provider #1
-        UiElementNode first_provider = app_child_it.next();
-        assertEquals("provider", first_provider.getDescriptor().getXmlName());
-        assertEquals(0, first_provider.getUiChildren().size());
-        assertEquals(0, first_provider.getUiAttributes().size());
-
-        // get /manifest/application/provider #2
-        UiElementNode second_provider = app_child_it.next();
-        assertEquals("provider", second_provider.getDescriptor().getXmlName());
-        assertEquals(0, second_provider.getUiChildren().size());
-        assertEquals(0, second_provider.getUiAttributes().size());
-        
-        // get /manifest/permission #1
-        UiElementNode first_permission = ui_child_it.next();
-        assertEquals("permission", first_permission.getDescriptor().getXmlName());
-        assertEquals(0, first_permission.getUiChildren().size());
-        assertEquals(0, first_permission.getUiAttributes().size());
-
-        // get /manifest/permission #1
-        UiElementNode second_permission = ui_child_it.next();
-        assertEquals("permission", second_permission.getDescriptor().getXmlName());
-        assertEquals(0, second_permission.getUiChildren().size());
-        assertEquals(0, second_permission.getUiAttributes().size());
-    }
-    
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNamedNodeMap.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNamedNodeMap.java
deleted file mode 100644
index b1f089b..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNamedNodeMap.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.mock;
-
-import org.w3c.dom.DOMException;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-
-class MockNamedNodeMap implements NamedNodeMap {
-    
-    /** map for access by namespace/name */
-    private final HashMap<String, HashMap<String, Node>> mNodeMap =
-        new HashMap<String, HashMap<String, Node>>();
-    
-    /** list for access by index */
-    private final ArrayList<Node> mNodeList = new ArrayList<Node>();
-     
-    public MockXmlNode addAttribute(String namespace, String localName, String value) {
-        MockXmlNode node = new MockXmlNode(namespace, localName, value);
-
-        if (namespace == null) {
-            namespace = ""; // no namespace
-        }
-        
-        // get the map for the namespace
-        HashMap<String, Node> map = mNodeMap.get(namespace);
-        if (map == null) {
-            map = new HashMap<String, Node>();
-            mNodeMap.put(namespace, map);
-        }
-        
-        
-        map.put(localName, node);
-        mNodeList.add(node);
-        
-        return node;
-    }
-    
-    // --------- NamedNodeMap -------
-
-    public int getLength() {
-        return mNodeList.size();
-    }
-
-    public Node getNamedItem(String name) {
-        HashMap<String, Node> map = mNodeMap.get(""); // no namespace
-        if (map != null) {
-            return map.get(name);
-        }
-        
-        return null;
-    }
-
-    public Node getNamedItemNS(String namespaceURI, String localName) throws DOMException {
-        if (namespaceURI == null) {
-            namespaceURI = ""; //no namespace
-        }
-        
-        HashMap<String, Node> map = mNodeMap.get(namespaceURI);
-        if (map != null) {
-            return map.get(localName);
-        }
-        
-        return null;
-    }
-
-    public Node item(int index) {
-        return mNodeList.get(index);
-    }
-
-    public Node removeNamedItem(String name) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Node removeNamedItemNS(String namespaceURI, String localName) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Node setNamedItem(Node arg) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Node setNamedItemNS(Node arg) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNodeList.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNodeList.java
deleted file mode 100644
index d766af7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockNodeList.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.mock;
-
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-import java.util.ArrayList;
-
-
-/**
- * A quick mock implementation of NodeList on top of ArrayList.
- */
-public class MockNodeList implements NodeList {
-
-    ArrayList<MockXmlNode> mChildren;
-
-    /**
-    * Constructs a node list from a given children list.
-    * 
-    * @param children The children list. Can be null.
-     */
-    public MockNodeList(MockXmlNode[] children) {
-        mChildren = new ArrayList<MockXmlNode>();
-        if (children != null) {
-            for (MockXmlNode n : children) {
-                mChildren.add(n);
-            }
-        }
-    }
-
-    public int getLength() {
-        return mChildren.size();
-    }
-
-    public Node item(int index) {
-        if (index >= 0 && index < mChildren.size()) {
-            return mChildren.get(index);
-        }
-        return null;
-    }
-
-    public ArrayList<MockXmlNode> getArrayList() {
-        return mChildren;
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockXmlNode.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockXmlNode.java
deleted file mode 100644
index 4a9dbbd..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/mock/MockXmlNode.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.mock;
-
-import org.w3c.dom.DOMException;
-import org.w3c.dom.Document;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.UserDataHandler;
-
-import java.util.HashMap;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-
-/**
- * A mock XML node with only a minimal set of information.
- */
-public class MockXmlNode implements Node {
-   
-    MockNodeList mNodeList;
-    private String mLocalName;
-    private String mNamespace;
-    private short mNodeType;
-    private MockXmlNode mParent;
-    private MockXmlNode mPreviousSibling;
-    private MockXmlNode mNextSibling;
-    private String mAttrValue;
-    private MockNamedNodeMap mAttributes;
-    
-    // namespace stuff only set in the root node
-    /** map from namespace to prefix. */
-    private HashMap<String, String> mNsMap = null;
-    
-    /**
-     * Constructs a node from a given children list.
-     * 
-     * @param namespace The namespace of the node or null if none
-     * @param localName The XML local node name.
-     * @param node_type One of Node.xxx_NODE constants, e.g. Node.ELEMENT_NODE
-     * @param children The children list. Can be null.
-     */
-    public MockXmlNode(String namespace, String localName, short node_type,
-            MockXmlNode[] children) {
-        mLocalName = localName;
-        mNamespace = namespace;
-        mNodeType = node_type;
-        mNodeList = new MockNodeList(children);
-        fixNavigation();
-    }
-
-    /**
-     * Constructs an attribute node
-     * 
-     * @param namespace The namespace of the node or null if none
-     * @param localName The XML local node name.
-     * @param value the value of the attribute
-     */
-    public MockXmlNode(String namespace, String localName, String value) {
-        mLocalName = localName;
-        mNamespace = namespace;
-        mAttrValue = value;
-        mNodeType = Node.ATTRIBUTE_NODE;
-        mNodeList = new MockNodeList(new MockXmlNode[0]);
-        fixNavigation();
-    }
-
-    private void fixNavigation() {
-        MockXmlNode prev = null;
-        for (MockXmlNode n : mNodeList.getArrayList()) {
-            n.mParent = this;
-            n.mPreviousSibling = prev;
-            if (prev != null) {
-                prev.mNextSibling = n;
-            }
-            n.fixNavigation();
-            prev = n;
-        }
-    }
-    
-    public void addAttributes(String namespaceURI, String localName, String value) {
-        if (mAttributes == null) {
-            mAttributes = new MockNamedNodeMap();
-        }
-        
-        MockXmlNode node = mAttributes.addAttribute(namespaceURI, localName, value);
-        node.mParent = this;
-    }
-    
-    public void setPrefix(String namespace, String prefix) {
-        if (mNsMap == null) {
-            mNsMap = new HashMap<String, String>();
-        }
-
-        mNsMap.put(namespace, prefix);
-    }
-    
-    public String getPrefix(String namespace) {
-        if (mNsMap != null) {
-            return mNsMap.get(namespace);
-        }
-        
-        return mParent.getPrefix(namespace);
-    }
-
-    
-    // ----------- Node methods
-
-    public Node appendChild(Node newChild) throws DOMException {
-        mNodeList.getArrayList().add((MockXmlNode) newChild);
-        return newChild;
-    }
-
-    public NamedNodeMap getAttributes() {
-        return mAttributes;
-    }
-
-    public NodeList getChildNodes() {
-        return mNodeList;
-    }
-
-    public Node getFirstChild() {
-        if (mNodeList.getLength() > 0) {
-            return mNodeList.item(0);
-        }
-        return null;
-    }
-
-    public Node getLastChild() {
-        if (mNodeList.getLength() > 0) {
-            return mNodeList.item(mNodeList.getLength() - 1);
-        }
-        return null;
-    }
-
-    public Node getNextSibling() {
-        return mNextSibling;
-    }
-
-    public String getNodeName() {
-        return mLocalName;
-    }
-    
-    public String getLocalName() {
-        return mLocalName;
-    }
-
-    public short getNodeType() {
-        return mNodeType;
-    }
-
-    public Node getParentNode() {
-        return mParent;
-    }
-
-    public Node getPreviousSibling() {
-        return mPreviousSibling;
-    }
-
-    public boolean hasChildNodes() {
-        return mNodeList.getLength() > 0;
-    }
-
-    public boolean hasAttributes() {
-        // TODO Auto-generated method stub
-        throw new NotImplementedException();
-        //return false;
-    }
-
-    public boolean isSameNode(Node other) {
-        return this == other;
-    }
-    
-    public String getNodeValue() throws DOMException {
-        return mAttrValue;
-    }
-    
-    public String getPrefix() {
-        return getPrefix(getNamespaceURI());
-    }
-
-    public String getNamespaceURI() {
-        return mNamespace;
-    }
-
-
-    // --- methods not implemented ---
-    
-    public Node cloneNode(boolean deep) {
-        throw new NotImplementedException();
-    }
-
-    public short compareDocumentPosition(Node other) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public String getBaseURI() {
-        throw new NotImplementedException();
-    }
-
-    public Object getFeature(String feature, String version) {
-        throw new NotImplementedException();
-    }
-
-    public Document getOwnerDocument() {
-        throw new NotImplementedException();
-    }
-
-    public String getTextContent() throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Object getUserData(String key) {
-        throw new NotImplementedException();
-    }
-
-    public Node insertBefore(Node newChild, Node refChild)
-            throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isDefaultNamespace(String namespaceURI) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isEqualNode(Node arg) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isSupported(String feature, String version) {
-        throw new NotImplementedException();
-    }
-
-    public String lookupNamespaceURI(String prefix) {
-        throw new NotImplementedException();
-    }
-
-    public String lookupPrefix(String namespaceURI) {
-        throw new NotImplementedException();
-    }
-
-    public void normalize() {
-        throw new NotImplementedException();
-    }
-
-    public Node removeChild(Node oldChild) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Node replaceChild(Node newChild, Node oldChild)
-            throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public void setNodeValue(String nodeValue) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public void setPrefix(String prefix) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public void setTextContent(String textContent) throws DOMException {
-        throw new NotImplementedException();
-    }
-
-    public Object setUserData(String key, Object data,
-            UserDataHandler handler) {
-        throw new NotImplementedException();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifierTest.java
deleted file mode 100644
index bedaa0d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/CountryCodeQualifierTest.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class CountryCodeQualifierTest extends TestCase {
-
-    private CountryCodeQualifier mccq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        mccq = new CountryCodeQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        mccq = null;
-        config = null;
-    }
-
-    public void testCheckAndSet() {
-        assertEquals(true, mccq.checkAndSet("mcc123", config));//$NON-NLS-1$
-        assertTrue(config.getCountryCodeQualifier() != null);
-        assertEquals(123, config.getCountryCodeQualifier().getCode());
-        assertEquals("mcc123", config.getCountryCodeQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, mccq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, mccq.checkAndSet("mcc", config));//$NON-NLS-1$
-        assertEquals(false, mccq.checkAndSet("MCC123", config));//$NON-NLS-1$
-        assertEquals(false, mccq.checkAndSet("123", config));//$NON-NLS-1$
-        assertEquals(false, mccq.checkAndSet("mccsdf", config));//$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifierTest.java
deleted file mode 100644
index e15434e..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/KeyboardStateQualifierTest.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class KeyboardStateQualifierTest extends TestCase {
-
-    private KeyboardStateQualifier ksq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        ksq = new KeyboardStateQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        ksq = null;
-        config = null;
-    }
-
-    public void testExposed() {
-        assertEquals(true, ksq.checkAndSet("keysexposed", config)); //$NON-NLS-1$
-        assertTrue(config.getKeyboardStateQualifier() != null);
-        assertEquals(KeyboardStateQualifier.KeyboardState.EXPOSED,
-                config.getKeyboardStateQualifier().getValue());
-        assertEquals("keysexposed", config.getKeyboardStateQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testHidden() {
-        assertEquals(true, ksq.checkAndSet("keyshidden", config)); //$NON-NLS-1$
-        assertTrue(config.getKeyboardStateQualifier() != null);
-        assertEquals(KeyboardStateQualifier.KeyboardState.HIDDEN,
-                config.getKeyboardStateQualifier().getValue());
-        assertEquals("keyshidden", config.getKeyboardStateQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, ksq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, ksq.checkAndSet("KEYSEXPOSED", config));//$NON-NLS-1$
-        assertEquals(false, ksq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifierTest.java
deleted file mode 100644
index d00972f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/LanguageQualifierTest.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class LanguageQualifierTest extends TestCase {
-    
-    private FolderConfiguration config;
-    private LanguageQualifier lq;
-
-    @Override
-    public void setUp()  throws Exception {
-        super.setUp();
-        config = new FolderConfiguration();
-        lq = new LanguageQualifier();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        config = null;
-        lq = null;
-    }
-    
-    public void testCheckAndSet() {
-        assertEquals(true, lq.checkAndSet("en", config)); //$NON-NLS-1$
-        assertTrue(config.getLanguageQualifier() != null);
-        assertEquals("en", config.getLanguageQualifier().toString()); //$NON-NLS-1$
-        
-    }
-    
-    public void testFailures() {
-        assertEquals(false, lq.checkAndSet("", config)); //$NON-NLS-1$
-        assertEquals(false, lq.checkAndSet("EN", config)); //$NON-NLS-1$
-        assertEquals(false, lq.checkAndSet("abc", config)); //$NON-NLS-1$
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifierTest.java
deleted file mode 100644
index d672f1f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NavigationMethodQualifierTest.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class NavigationMethodQualifierTest extends TestCase {
-
-    private FolderConfiguration config;
-    private NavigationMethodQualifier nmq;
-
-    @Override
-    public void setUp() throws Exception {
-        super.setUp();
-        config = new FolderConfiguration();
-        nmq = new NavigationMethodQualifier();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        config = null;
-        nmq = null;
-    }
-    
-    public void testDPad() {
-        assertEquals(true, nmq.checkAndSet("dpad", config)); //$NON-NLS-1$
-        assertTrue(config.getNavigationMethodQualifier() != null);
-        assertEquals(NavigationMethodQualifier.NavigationMethod.DPAD,
-                config.getNavigationMethodQualifier().getValue());
-        assertEquals("dpad", config.getNavigationMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testTrackball() {
-        assertEquals(true, nmq.checkAndSet("trackball", config)); //$NON-NLS-1$
-        assertTrue(config.getNavigationMethodQualifier() != null);
-        assertEquals(NavigationMethodQualifier.NavigationMethod.TRACKBALL,
-                config.getNavigationMethodQualifier().getValue());
-        assertEquals("trackball", config.getNavigationMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testWheel() {
-        assertEquals(true, nmq.checkAndSet("wheel", config)); //$NON-NLS-1$
-        assertTrue(config.getNavigationMethodQualifier() != null);
-        assertEquals(NavigationMethodQualifier.NavigationMethod.WHEEL,
-                config.getNavigationMethodQualifier().getValue());
-        assertEquals("wheel", config.getNavigationMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, nmq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, nmq.checkAndSet("WHEEL", config));//$NON-NLS-1$
-        assertEquals(false, nmq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifierTest.java
deleted file mode 100644
index 4567dff..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/NetworkCodeQualifierTest.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class NetworkCodeQualifierTest extends TestCase {
-
-    private NetworkCodeQualifier mncq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        mncq = new NetworkCodeQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        mncq = null;
-        config = null;
-    }
-
-    public void testCheckAndSet() {
-        assertEquals(true, mncq.checkAndSet("mnc123", config));//$NON-NLS-1$
-        assertTrue(config.getNetworkCodeQualifier() != null);
-        assertEquals(123, config.getNetworkCodeQualifier().getCode());
-        assertEquals("mnc123", config.getNetworkCodeQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, mncq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, mncq.checkAndSet("mnc", config));//$NON-NLS-1$
-        assertEquals(false, mncq.checkAndSet("MNC123", config));//$NON-NLS-1$
-        assertEquals(false, mncq.checkAndSet("123", config));//$NON-NLS-1$
-        assertEquals(false, mncq.checkAndSet("mncsdf", config));//$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifierTest.java
deleted file mode 100644
index 2c4cd2f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/PixelDensityQualifierTest.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class PixelDensityQualifierTest extends TestCase {
-
-    private PixelDensityQualifier pdq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        pdq = new PixelDensityQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        pdq = null;
-        config = null;
-    }
-
-    public void testCheckAndSet() {
-        assertEquals(true, pdq.checkAndSet("123dpi", config));//$NON-NLS-1$
-        assertTrue(config.getPixelDensityQualifier() != null);
-        assertEquals(123, config.getPixelDensityQualifier().getValue());
-        assertEquals("123dpi", config.getPixelDensityQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, pdq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, pdq.checkAndSet("dpi", config));//$NON-NLS-1$
-        assertEquals(false, pdq.checkAndSet("123DPI", config));//$NON-NLS-1$
-        assertEquals(false, pdq.checkAndSet("123", config));//$NON-NLS-1$
-        assertEquals(false, pdq.checkAndSet("sdfdpi", config));//$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/RegionQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/RegionQualifierTest.java
deleted file mode 100644
index 8a9e6f8..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/RegionQualifierTest.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class RegionQualifierTest extends TestCase {
-
-    private RegionQualifier rq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-
-        rq = new RegionQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        rq = null;
-        config = null;
-    }
-
-    public void testCheckAndSet() {
-        assertEquals(true, rq.checkAndSet("rUS", config));//$NON-NLS-1$
-        assertTrue(config.getRegionQualifier() != null);
-        assertEquals("US", config.getRegionQualifier().getValue()); //$NON-NLS-1$
-        assertEquals("rUS", config.getRegionQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, rq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, rq.checkAndSet("rus", config));//$NON-NLS-1$
-        assertEquals(false, rq.checkAndSet("rUSA", config));//$NON-NLS-1$
-        assertEquals(false, rq.checkAndSet("abc", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifierTest.java
deleted file mode 100644
index 681d4e0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenDimensionQualifierTest.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class ScreenDimensionQualifierTest extends TestCase {
-
-    private ScreenDimensionQualifier sdq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        sdq = new ScreenDimensionQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        sdq = null;
-        config = null;
-    }
-    
-    public void testCheckAndSet() {
-        assertEquals(true, sdq.checkAndSet("400x200", config));//$NON-NLS-1$
-        assertTrue(config.getScreenDimensionQualifier() != null);
-        assertEquals(400, config.getScreenDimensionQualifier().getValue1());
-        assertEquals(200, config.getScreenDimensionQualifier().getValue2());
-        assertEquals("400x200", config.getScreenDimensionQualifier().toString()); //$NON-NLS-1$
-    }
-    
-    public void testFailures() {
-        assertEquals(false, sdq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("400X200", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("x200", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("ax200", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("400x", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("400xa", config));//$NON-NLS-1$
-        assertEquals(false, sdq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifierTest.java
deleted file mode 100644
index 28f9961..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/ScreenOrientationQualifierTest.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class ScreenOrientationQualifierTest extends TestCase {
-
-    private ScreenOrientationQualifier soq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        soq = new ScreenOrientationQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        soq = null;
-        config = null;
-    }
-
-    public void testPortrait() {
-        assertEquals(true, soq.checkAndSet("port", config)); //$NON-NLS-1$
-        assertTrue(config.getScreenOrientationQualifier() != null);
-        assertEquals(ScreenOrientationQualifier.ScreenOrientation.PORTRAIT,
-                config.getScreenOrientationQualifier().getValue());
-        assertEquals("port", config.getScreenOrientationQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testLanscape() {
-        assertEquals(true, soq.checkAndSet("land", config)); //$NON-NLS-1$
-        assertTrue(config.getScreenOrientationQualifier() != null);
-        assertEquals(ScreenOrientationQualifier.ScreenOrientation.LANDSCAPE,
-                config.getScreenOrientationQualifier().getValue());
-        assertEquals("land", config.getScreenOrientationQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testSquare() {
-        assertEquals(true, soq.checkAndSet("square", config)); //$NON-NLS-1$
-        assertTrue(config.getScreenOrientationQualifier() != null);
-        assertEquals(ScreenOrientationQualifier.ScreenOrientation.SQUARE,
-                config.getScreenOrientationQualifier().getValue());
-        assertEquals("square", config.getScreenOrientationQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, soq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, soq.checkAndSet("PORT", config));//$NON-NLS-1$
-        assertEquals(false, soq.checkAndSet("landscape", config));//$NON-NLS-1$
-        assertEquals(false, soq.checkAndSet("portrait", config));//$NON-NLS-1$
-        assertEquals(false, soq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifierTest.java
deleted file mode 100644
index 28f7871..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TextInputMethodQualifierTest.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class TextInputMethodQualifierTest extends TestCase {
-    
-    private TextInputMethodQualifier timq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        timq = new TextInputMethodQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        timq = null;
-        config = null;
-    }
-
-    public void testQuerty() {
-        assertEquals(true, timq.checkAndSet("qwerty", config)); //$NON-NLS-1$
-        assertTrue(config.getTextInputMethodQualifier() != null);
-        assertEquals(TextInputMethodQualifier.TextInputMethod.QWERTY,
-                config.getTextInputMethodQualifier().getValue());
-        assertEquals("qwerty", config.getTextInputMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void test12Key() {
-        assertEquals(true, timq.checkAndSet("12key", config)); //$NON-NLS-1$
-        assertTrue(config.getTextInputMethodQualifier() != null);
-        assertEquals(TextInputMethodQualifier.TextInputMethod.TWELVEKEYS,
-                config.getTextInputMethodQualifier().getValue());
-        assertEquals("12key", config.getTextInputMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testNoKey() {
-        assertEquals(true, timq.checkAndSet("nokeys", config)); //$NON-NLS-1$
-        assertTrue(config.getTextInputMethodQualifier() != null);
-        assertEquals(TextInputMethodQualifier.TextInputMethod.NOKEY,
-                config.getTextInputMethodQualifier().getValue());
-        assertEquals("nokeys", config.getTextInputMethodQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, timq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, timq.checkAndSet("QWERTY", config));//$NON-NLS-1$
-        assertEquals(false, timq.checkAndSet("12keys", config));//$NON-NLS-1$
-        assertEquals(false, timq.checkAndSet("*12key", config));//$NON-NLS-1$
-        assertEquals(false, timq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifierTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifierTest.java
deleted file mode 100644
index 9a788ad..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/configurations/TouchScreenQualifierTest.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.configurations;
-
-import junit.framework.TestCase;
-
-public class TouchScreenQualifierTest extends TestCase {
-
-    private TouchScreenQualifier tsq;
-    private FolderConfiguration config;
-
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        tsq = new TouchScreenQualifier();
-        config = new FolderConfiguration();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        tsq = null;
-        config = null;
-    }
-
-    public void testNoTouch() {
-        assertEquals(true, tsq.checkAndSet("notouch", config)); //$NON-NLS-1$
-        assertTrue(config.getTouchTypeQualifier() != null);
-        assertEquals(TouchScreenQualifier.TouchScreenType.NOTOUCH,
-                config.getTouchTypeQualifier().getValue());
-        assertEquals("notouch", config.getTouchTypeQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFinger() {
-        assertEquals(true, tsq.checkAndSet("finger", config)); //$NON-NLS-1$
-        assertTrue(config.getTouchTypeQualifier() != null);
-        assertEquals(TouchScreenQualifier.TouchScreenType.FINGER,
-                config.getTouchTypeQualifier().getValue());
-        assertEquals("finger", config.getTouchTypeQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testStylus() {
-        assertEquals(true, tsq.checkAndSet("stylus", config)); //$NON-NLS-1$
-        assertTrue(config.getTouchTypeQualifier() != null);
-        assertEquals(TouchScreenQualifier.TouchScreenType.STYLUS,
-                config.getTouchTypeQualifier().getValue());
-        assertEquals("stylus", config.getTouchTypeQualifier().toString()); //$NON-NLS-1$
-    }
-
-    public void testFailures() {
-        assertEquals(false, tsq.checkAndSet("", config));//$NON-NLS-1$
-        assertEquals(false, tsq.checkAndSet("STYLUS", config));//$NON-NLS-1$
-        assertEquals(false, tsq.checkAndSet("other", config));//$NON-NLS-1$
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/ConfigMatchTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/ConfigMatchTest.java
deleted file mode 100644
index 25a86c3..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/ConfigMatchTest.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-import com.android.ide.eclipse.editors.resources.configurations.KeyboardStateQualifier.KeyboardState;
-import com.android.ide.eclipse.editors.resources.configurations.NavigationMethodQualifier.NavigationMethod;
-import com.android.ide.eclipse.editors.resources.configurations.ScreenOrientationQualifier.ScreenOrientation;
-import com.android.ide.eclipse.editors.resources.configurations.TextInputMethodQualifier.TextInputMethod;
-import com.android.ide.eclipse.editors.resources.configurations.TouchScreenQualifier.TouchScreenType;
-import com.android.ide.eclipse.editors.resources.manager.files.IAbstractFolder;
-import com.android.ide.eclipse.editors.resources.manager.files.IFileWrapper;
-import com.android.ide.eclipse.editors.resources.manager.files.IFolderWrapper;
-import com.android.ide.eclipse.mock.FileMock;
-import com.android.ide.eclipse.mock.FolderMock;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-
-import junit.framework.TestCase;
-
-public class ConfigMatchTest extends TestCase {
-    private static final String SEARCHED_FILENAME = "main.xml"; //$NON-NLS-1$
-    private static final String MISC1_FILENAME = "foo.xml"; //$NON-NLS-1$
-    private static final String MISC2_FILENAME = "bar.xml"; //$NON-NLS-1$
-    
-    private ProjectResources mResources;
-    private ResourceQualifier[] mQualifierList;
-    private FolderConfiguration config4;
-    private FolderConfiguration config3;
-    private FolderConfiguration config2;
-    private FolderConfiguration config1;
-
-    @SuppressWarnings("unchecked")
-    @Override
-    protected void setUp() throws Exception {
-        super.setUp();
-        
-        // create a Resource Manager to get a list of qualifier as instantiated by the real code.
-        // Thanks for QualifierListTest we know this contains all the qualifiers. 
-        ResourceManager manager = ResourceManager.getInstance();
-        Field qualifierListField = ResourceManager.class.getDeclaredField("mQualifiers");
-        assertNotNull(qualifierListField);
-        qualifierListField.setAccessible(true);
-        
-        // get the actual list.
-        mQualifierList = (ResourceQualifier[])qualifierListField.get(manager);
-        
-        // create the project resources.
-        mResources = new ProjectResources(false /* isFrameworkRepository */);
-        
-        // create 2 arrays of IResource. one with the filename being looked up, and one without.
-        // Since the required API uses IResource, we can use MockFolder for them.
-        FileMock[] validMemberList = new FileMock[] {
-                new FileMock(MISC1_FILENAME),
-                new FileMock(SEARCHED_FILENAME),
-                new FileMock(MISC2_FILENAME),
-        };
-        FileMock[] invalidMemberList = new FileMock[] {
-                new FileMock(MISC1_FILENAME),
-                new FileMock(MISC2_FILENAME),
-        };
-        
-        // add multiple ResourceFolder to the project resource.
-        FolderConfiguration defaultConfig = getConfiguration(
-                null, // country code
-                null, // network code
-                null, // language
-                null, // region
-                null, // screen orientation
-                null, // dpi
-                null, // touch mode
-                null, // keyboard state
-                null, // text input
-                null, // navigation
-                null); // screen size
-        
-        addFolder(mResources, defaultConfig, validMemberList);
-        
-        config1 = getConfiguration(
-                null, // country code
-                null, // network code
-                "en", // language
-                null, // region
-                null, // screen orientation
-                null, // dpi
-                null, // touch mode
-                KeyboardState.EXPOSED.getValue(), // keyboard state
-                null, // text input
-                null, // navigation
-                null); // screen size
-        
-        addFolder(mResources, config1, validMemberList);
-
-        config2 = getConfiguration(
-                null, // country code
-                null, // network code
-                "en", // language
-                null, // region
-                null, // screen orientation
-                null, // dpi
-                null, // touch mode
-                KeyboardState.HIDDEN.getValue(), // keyboard state
-                null, // text input
-                null, // navigation
-                null); // screen size
-        
-        addFolder(mResources, config2, validMemberList);
-
-        config3 = getConfiguration(
-                null, // country code
-                null, // network code
-                "en", // language
-                null, // region
-                ScreenOrientation.LANDSCAPE.getValue(), // screen orientation
-                null, // dpi
-                null, // touch mode
-                null, // keyboard state
-                null, // text input
-                null, // navigation
-                null); // screen size
-        
-        addFolder(mResources, config3, validMemberList);
-
-        config4 = getConfiguration(
-                "mcc310", // country code
-                "mnc435", // network code
-                "en", // language
-                "rUS", // region
-                ScreenOrientation.LANDSCAPE.getValue(), // screen orientation
-                "160dpi", // dpi
-                TouchScreenType.FINGER.getValue(), // touch mode
-                KeyboardState.EXPOSED.getValue(), // keyboard state
-                TextInputMethod.QWERTY.getValue(), // text input
-                NavigationMethod.DPAD.getValue(), // navigation
-                "480x320"); // screen size
-        
-        addFolder(mResources, config4, invalidMemberList);
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        mResources = null;
-    }
-
-    public void test1() {
-        FolderConfiguration testConfig = getConfiguration(
-                "mcc310", // country code
-                "mnc435", // network code
-                "en", // language
-                "rUS", // region
-                ScreenOrientation.LANDSCAPE.getValue(), // screen orientation
-                "160dpi", // dpi
-                TouchScreenType.FINGER.getValue(), // touch mode
-                KeyboardState.EXPOSED.getValue(), // keyboard state
-                TextInputMethod.QWERTY.getValue(), // text input
-                NavigationMethod.DPAD.getValue(), // navigation
-                "480x320"); // screen size
-        
-        ResourceFile result = mResources.getMatchingFile(SEARCHED_FILENAME,
-                ResourceFolderType.LAYOUT, testConfig);
-        
-        boolean bresult = result.getFolder().getConfiguration().equals(config3);
-        assertEquals(bresult, true);
-    }
-
-    /**
-     * Creates a {@link FolderConfiguration}.
-     * @param qualifierValues The list of qualifier values. The length must equals the total number
-     * of Qualifiers. <code>null</code> is permitted and will make the FolderConfiguration not use
-     * this particular qualifier.
-     */
-    private FolderConfiguration getConfiguration(String... qualifierValues) {
-        FolderConfiguration config = new FolderConfiguration();
-        
-        // those must be of the same length
-        assertEquals(qualifierValues.length, mQualifierList.length);
-        
-        int index = 0;
-
-        for (ResourceQualifier qualifier : mQualifierList) {
-            String value = qualifierValues[index++];
-            if (value != null) {
-                assertTrue(qualifier.checkAndSet(value, config));
-            }
-        }
-
-        return config;
-    }
-    
-    /**
-     * Adds a folder to the given {@link ProjectResources} with the given
-     * {@link FolderConfiguration}. The folder is filled with files from the provided list.
-     * @param resources the {@link ProjectResources} in which to add the folder.
-     * @param config the {@link FolderConfiguration} for the created folder.
-     * @param memberList the list of files for the folder.
-     */
-    private void addFolder(ProjectResources resources, FolderConfiguration config,
-            FileMock[] memberList) throws Exception {
-        
-        // figure out the folder name based on the configuration
-        String folderName = "layout";
-        if (config.isDefault() == false) {
-            folderName += "-" + config.toString();
-        }
-        
-        // create the folder mock
-        FolderMock folder = new FolderMock(folderName, memberList);
-
-        // add it to the resource, and get back a ResourceFolder object.
-        ResourceFolder resFolder = _addProjectResourceFolder(resources, config, folder);
-
-        // and fill it with files from the list.
-        for (FileMock file : memberList) {
-            resFolder.addFile(new SingleResourceFile(new IFileWrapper(file), resFolder));
-        }
-    }
-
-    /** Calls ProjectResource.add method via reflection to circumvent access 
-     * restrictions that are enforced when running in the plug-in environment 
-     * ie cannot access package or protected members in a different plug-in, even
-     * if they are in the same declared package as the accessor
-     */
-    private ResourceFolder _addProjectResourceFolder(ProjectResources resources,
-            FolderConfiguration config, FolderMock folder) throws Exception {
-
-        Method addMethod = ProjectResources.class.getDeclaredMethod("add", 
-                ResourceFolderType.class, FolderConfiguration.class,
-                IAbstractFolder.class);
-        addMethod.setAccessible(true);
-        ResourceFolder resFolder = (ResourceFolder)addMethod.invoke(resources,
-                ResourceFolderType.LAYOUT, config, new IFolderWrapper(folder));
-        return resFolder;
-    }
-    
-
-    
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/QualifierListTest.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/QualifierListTest.java
deleted file mode 100644
index 6a555a4..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/editors/resources/manager/QualifierListTest.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.editors.resources.manager;
-
-import com.android.ide.eclipse.editors.resources.configurations.FolderConfiguration;
-import com.android.ide.eclipse.editors.resources.configurations.ResourceQualifier;
-
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-
-import junit.framework.TestCase;
-
-public class QualifierListTest extends TestCase {
-    
-    private ResourceManager mManager;
-
-    @Override
-    public void setUp()  throws Exception {
-        super.setUp();
-        
-        mManager = ResourceManager.getInstance();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-        mManager = null;
-    }
-    
-    @SuppressWarnings("unchecked")
-    public void testQualifierList() {
-        try {
-            // get the list of qualifier in the resource manager
-            Field qualifierListField = ResourceManager.class.getDeclaredField("mQualifiers");
-            assertNotNull(qualifierListField);
-            qualifierListField.setAccessible(true);
-            
-            // get the actual list.
-            ResourceQualifier[] qualifierList =
-                (ResourceQualifier[])qualifierListField.get(mManager);
-            
-            // now get the number of qualifier in the FolderConfiguration
-            Field qualCountField = FolderConfiguration.class.getDeclaredField("INDEX_COUNT");
-            assertNotNull(qualCountField);
-            qualCountField.setAccessible(true);
-            
-            // get the constant value
-            Integer count = (Integer)qualCountField.get(null);
-            
-            // now compare
-            assertEquals(count.intValue(), qualifierList.length);
-        } catch (SecurityException e) {
-            assertTrue(false);
-        } catch (NoSuchFieldException e) {
-            assertTrue(false);
-        } catch (IllegalArgumentException e) {
-            assertTrue(false);
-        } catch (IllegalAccessException e) {
-            assertTrue(false);
-        }
-    }
-}
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ClasspathEntryMock.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ClasspathEntryMock.java
deleted file mode 100644
index 010aadf..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ClasspathEntryMock.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.mock;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IAccessRule;
-import org.eclipse.jdt.core.IClasspathAttribute;
-import org.eclipse.jdt.core.IClasspathEntry;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-public class ClasspathEntryMock implements IClasspathEntry {
-
-    private int mKind;
-    private IPath mPath;
-
-    public ClasspathEntryMock(IPath path, int kind) {
-        mPath = path;
-        mKind = kind;
-    }
-    
-    public int getEntryKind() {
-        return mKind;
-    }
-    
-    public IPath getPath() {
-        return mPath;
-    }
-    
-    // -------- UNIMPLEMENTED METHODS ----------------
-
-    public boolean combineAccessRules() {
-        throw new NotImplementedException();
-    }
-
-    public IAccessRule[] getAccessRules() {
-        throw new NotImplementedException();
-    }
-
-    public int getContentKind() {
-        throw new NotImplementedException();
-    }
-
-    public IPath[] getExclusionPatterns() {
-        throw new NotImplementedException();
-    }
-
-    public IClasspathAttribute[] getExtraAttributes() {
-        throw new NotImplementedException();
-    }
-
-    public IPath[] getInclusionPatterns() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getOutputLocation() {
-        throw new NotImplementedException();
-    }
-
-    public IClasspathEntry getResolvedEntry() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getSourceAttachmentPath() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getSourceAttachmentRootPath() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isExported() {
-        throw new NotImplementedException();
-    }
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FileMock.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FileMock.java
deleted file mode 100644
index a95286c..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FileMock.java
+++ /dev/null
@@ -1,447 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.mock;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFileState;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IResourceProxy;
-import org.eclipse.core.resources.IResourceProxyVisitor;
-import org.eclipse.core.resources.IResourceVisitor;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourceAttributes;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.core.runtime.content.IContentDescription;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-import java.io.InputStream;
-import java.io.Reader;
-import java.net.URI;
-import java.util.Map;
-
-/**
- * Mock implementation of {@link IFile}.
- * <p/>Supported methods:
- * <ul>
- * </ul>
- */
-public class FileMock implements IFile {
-
-    private String mName;
-
-    public FileMock(String name) {
-        mName = name;
-    }
-
-    // -------- MOCKED METHODS ----------------
-
-    public String getName() {
-        return mName;
-    }
-    
-    // -------- UNIMPLEMENTED METHODS ----------------
-
-    public void appendContents(InputStream source, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void appendContents(InputStream source, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void create(InputStream source, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void create(InputStream source, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void createLink(IPath localLocation, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void createLink(URI location, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean force, boolean keepHistory, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getCharset() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getCharset(boolean checkImplicit) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getCharsetFor(Reader reader) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IContentDescription getContentDescription() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public InputStream getContents() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public InputStream getContents(boolean force) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int getEncoding() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IPath getFullPath() {
-        throw new NotImplementedException();
-    }
-
-    public IFileState[] getHistory(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isReadOnly() {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, boolean force, boolean keepHistory, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setCharset(String newCharset) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setCharset(String newCharset, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setContents(InputStream source, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setContents(IFileState source, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setContents(InputStream source, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setContents(IFileState source, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceProxyVisitor visitor, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, boolean includePhantoms)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void clearHistory(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker createMarker(String type) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResourceProxy createProxy() {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean force, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(int updateFlags, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void deleteMarkers(String type, boolean includeSubtypes, int depth) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker findMarker(long id) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker[] findMarkers(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int findMaxProblemSeverity(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getFileExtension() {
-        throw new NotImplementedException();
-    }
-
-    public long getLocalTimeStamp() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getLocation() {
-        return new Path(mName);
-    }
-
-    public URI getLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker getMarker(long id) {
-        throw new NotImplementedException();
-    }
-
-    public long getModificationStamp() {
-        throw new NotImplementedException();
-    }
-
-    public IContainer getParent() {
-        throw new NotImplementedException();
-    }
-
-    public String getPersistentProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IProject getProject() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getProjectRelativePath() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getRawLocation() {
-        throw new NotImplementedException();
-    }
-
-    public URI getRawLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public ResourceAttributes getResourceAttributes() {
-        throw new NotImplementedException();
-    }
-
-    public Object getSessionProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int getType() {
-        throw new NotImplementedException();
-    }
-
-    public IWorkspace getWorkspace() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isAccessible() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isDerived() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked(int options) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLocal(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isPhantom() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isSynchronized(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isTeamPrivateMember() {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void refreshLocal(int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void revertModificationStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDerived(boolean isDerived) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setLocal(boolean flag, int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public long setLocalTimeStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setPersistentProperty(QualifiedName key, String value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setReadOnly(boolean readOnly) {
-        throw new NotImplementedException();
-    }
-
-    public void setResourceAttributes(ResourceAttributes attributes) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setSessionProperty(QualifiedName key, Object value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setTeamPrivateMember(boolean isTeamPrivate) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void touch(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("unchecked")
-    public Object getAdapter(Class adapter) {
-        throw new NotImplementedException();
-    }
-
-    public boolean contains(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isConflicting(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-	public Map getPersistentProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public Map getSessionProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public boolean isDerived(int options) {
-        throw new NotImplementedException();
-	}
-
-	public boolean isHidden() {
-        throw new NotImplementedException();
-	}
-
-	public void setHidden(boolean isHidden) throws CoreException {
-        throw new NotImplementedException();
-	}
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FolderMock.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FolderMock.java
deleted file mode 100644
index 223deb0..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/FolderMock.java
+++ /dev/null
@@ -1,451 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.mock;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceProxy;
-import org.eclipse.core.resources.IResourceProxyVisitor;
-import org.eclipse.core.resources.IResourceVisitor;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourceAttributes;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-import java.net.URI;
-import java.util.Map;
-
-/**
- * Mock implementation of {@link IFolder}.
- * <p/>Supported methods:
- * <ul>
- * <li>{@link #getName()}</li>
- * <li>{@link #members()}</li>
- * </ul>
- */
-public final class FolderMock implements IFolder {
-    
-    private String mName;
-    private IResource[] mMembers;
-    
-    public FolderMock(String name) {
-        mName = name;
-        mMembers = new IResource[0];
-    }
-    
-    public FolderMock(String name, IResource[] members) {
-        mName = name;
-        mMembers = members;
-    }
-    
-    // -------- MOCKED METHODS ----------------
-    
-    public String getName() {
-        return mName;
-    }
-    
-    public IResource[] members() throws CoreException {
-        return mMembers;
-    }
-
-    // -------- UNIMPLEMENTED METHODS ----------------
-
-    public void create(boolean force, boolean local, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void create(int updateFlags, boolean local, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void createLink(IPath localLocation, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void createLink(URI location, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean force, boolean keepHistory, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IFile getFile(String name) {
-        throw new NotImplementedException();
-    }
-
-    public IFolder getFolder(String name) {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, boolean force, boolean keepHistory, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IFile[] findDeletedMembersWithHistory(int depth, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(String name) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(String name, boolean includePhantoms) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(IPath path, boolean includePhantoms) {
-        throw new NotImplementedException();
-    }
-
-    public String getDefaultCharset() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getDefaultCharset(boolean checkImplicit) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IFile getFile(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IFolder getFolder(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IResource[] members(boolean includePhantoms) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResource[] members(int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDefaultCharset(String charset) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDefaultCharset(String charset, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceProxyVisitor visitor, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, boolean includePhantoms)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void clearHistory(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker createMarker(String type) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResourceProxy createProxy() {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean force, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(int updateFlags, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void deleteMarkers(String type, boolean includeSubtypes, int depth) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker findMarker(long id) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker[] findMarkers(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int findMaxProblemSeverity(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getFileExtension() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getFullPath() {
-        throw new NotImplementedException();
-    }
-
-    public long getLocalTimeStamp() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getLocation() {
-        throw new NotImplementedException();
-    }
-
-    public URI getLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker getMarker(long id) {
-        throw new NotImplementedException();
-    }
-
-    public long getModificationStamp() {
-        throw new NotImplementedException();
-    }
-
-    public IContainer getParent() {
-        throw new NotImplementedException();
-    }
-
-    public String getPersistentProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IProject getProject() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getProjectRelativePath() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getRawLocation() {
-        throw new NotImplementedException();
-    }
-
-    public URI getRawLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public ResourceAttributes getResourceAttributes() {
-        throw new NotImplementedException();
-    }
-
-    public Object getSessionProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int getType() {
-        throw new NotImplementedException();
-    }
-
-    public IWorkspace getWorkspace() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isAccessible() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isDerived() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked(int options) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLocal(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isPhantom() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isReadOnly() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isSynchronized(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isTeamPrivateMember() {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void refreshLocal(int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void revertModificationStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDerived(boolean isDerived) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setLocal(boolean flag, int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public long setLocalTimeStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setPersistentProperty(QualifiedName key, String value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setReadOnly(boolean readOnly) {
-        throw new NotImplementedException();
-    }
-
-    public void setResourceAttributes(ResourceAttributes attributes) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setSessionProperty(QualifiedName key, Object value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setTeamPrivateMember(boolean isTeamPrivate) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void touch(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("unchecked")
-    public Object getAdapter(Class adapter) {
-        throw new NotImplementedException();
-    }
-
-    public boolean contains(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isConflicting(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-	public Map getPersistentProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public Map getSessionProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public boolean isDerived(int options) {
-        throw new NotImplementedException();
-	}
-
-	public boolean isHidden() {
-        throw new NotImplementedException();
-	}
-
-	public void setHidden(boolean isHidden) throws CoreException {
-        throw new NotImplementedException();
-	}
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/JavaProjectMock.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/JavaProjectMock.java
deleted file mode 100644
index f23d2c1..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/JavaProjectMock.java
+++ /dev/null
@@ -1,414 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.mock;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-import org.eclipse.jdt.core.IBuffer;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IOpenable;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.IRegion;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.WorkingCopyOwner;
-import org.eclipse.jdt.core.eval.IEvaluationContext;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-import java.util.Map;
-
-public class JavaProjectMock implements IJavaProject {
-    
-    private IProject mProject;
-
-    private IClasspathEntry[] mEntries;
-    private IPath mOutputLocation;
-    private String mCompilerCompliance = "1.4"; //$NON-NLS-1
-    private String mCompilerSource = "1.4"; //$NON-NLS-1
-    private String mCompilerTarget = "1.4"; //$NON-NLS-1
-
-    public JavaProjectMock(IClasspathEntry[] entries, IPath outputLocation) {
-        mEntries = entries;
-        mOutputLocation = outputLocation;
-    }
-    
-    public IProject getProject() {
-        if (mProject == null) {
-            mProject = new ProjectMock();
-        }
-
-        return mProject;
-    }
-
-    
-    public void setRawClasspath(IClasspathEntry[] entries, IProgressMonitor monitor)
-            throws JavaModelException {
-        mEntries = entries;
-    }
-
-    public void setRawClasspath(IClasspathEntry[] entries, IPath outputLocation,
-            IProgressMonitor monitor) throws JavaModelException {
-        mEntries = entries;
-        mOutputLocation = outputLocation;
-    }
-    
-    public IClasspathEntry[] getRawClasspath() throws JavaModelException {
-        return mEntries;
-    }
-    
-    public IPath getOutputLocation() throws JavaModelException {
-        return mOutputLocation;
-    }
-    
-    public String getOption(String optionName, boolean inheritJavaCoreOptions) {
-        if (optionName.equals(JavaCore.COMPILER_COMPLIANCE)) {
-            return mCompilerCompliance;
-        } else if (optionName.equals(JavaCore.COMPILER_SOURCE)) {
-            return mCompilerSource;
-        } else if (optionName.equals(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM)) {
-            return mCompilerTarget;
-        }
-        
-        return null;
-    }
-        
-    public void setOption(String optionName, String optionValue) {
-        if (optionName.equals(JavaCore.COMPILER_COMPLIANCE)) {
-            mCompilerCompliance = optionValue;
-        } else if (optionName.equals(JavaCore.COMPILER_SOURCE)) {
-            mCompilerSource = optionValue;
-        } else if (optionName.equals(JavaCore.COMPILER_CODEGEN_TARGET_PLATFORM)) {
-            mCompilerTarget = optionValue;
-        } else {
-            throw new NotImplementedException();
-        }
-    }
-
-
-    // -------- UNIMPLEMENTED METHODS ----------------
-    
-    public IClasspathEntry decodeClasspathEntry(String encodedEntry) {
-        throw new NotImplementedException();
-    }
-
-    public String encodeClasspathEntry(IClasspathEntry classpathEntry) {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement findElement(IPath path) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement findElement(IPath path, WorkingCopyOwner owner) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragment findPackageFragment(IPath path) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot findPackageFragmentRoot(IPath path) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot[] findPackageFragmentRoots(IClasspathEntry entry) {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String fullyQualifiedName) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String fullyQualifiedName, IProgressMonitor progressMonitor)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String fullyQualifiedName, WorkingCopyOwner owner)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String packageName, String typeQualifiedName) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String fullyQualifiedName, WorkingCopyOwner owner,
-            IProgressMonitor progressMonitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String packageName, String typeQualifiedName,
-            IProgressMonitor progressMonitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String packageName, String typeQualifiedName, WorkingCopyOwner owner)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IType findType(String packageName, String typeQualifiedName, WorkingCopyOwner owner,
-            IProgressMonitor progressMonitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot[] getAllPackageFragmentRoots() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public Object[] getNonJavaResources() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("unchecked")
-    public Map getOptions(boolean inheritJavaCoreOptions) {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot getPackageFragmentRoot(String jarPath) {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot getPackageFragmentRoot(IResource resource) {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot[] getPackageFragmentRoots() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragmentRoot[] getPackageFragmentRoots(IClasspathEntry entry) {
-        throw new NotImplementedException();
-    }
-
-    public IPackageFragment[] getPackageFragments() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public String[] getRequiredProjectNames() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IClasspathEntry[] getResolvedClasspath(boolean ignoreUnresolvedEntry)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean hasBuildState() {
-        throw new NotImplementedException();
-    }
-
-    public boolean hasClasspathCycle(IClasspathEntry[] entries) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isOnClasspath(IJavaElement element) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isOnClasspath(IResource resource) {
-        throw new NotImplementedException();
-    }
-
-    public IEvaluationContext newEvaluationContext() {
-        throw new NotImplementedException();
-    }
-
-    public ITypeHierarchy newTypeHierarchy(IRegion region, IProgressMonitor monitor)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public ITypeHierarchy newTypeHierarchy(IRegion region, WorkingCopyOwner owner,
-            IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public ITypeHierarchy newTypeHierarchy(IType type, IRegion region, IProgressMonitor monitor)
-            throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public ITypeHierarchy newTypeHierarchy(IType type, IRegion region, WorkingCopyOwner owner,
-            IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IPath readOutputLocation() {
-        throw new NotImplementedException();
-    }
-
-    public IClasspathEntry[] readRawClasspath() {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("unchecked")
-    public void setOptions(Map newOptions) {
-        throw new NotImplementedException();
-    }
-
-    public void setOutputLocation(IPath path, IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public void setRawClasspath(IClasspathEntry[] entries, boolean canModifyResources,
-            IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public void setRawClasspath(IClasspathEntry[] entries, IPath outputLocation,
-            boolean canModifyResources, IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement[] getChildren() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean hasChildren() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists() {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement getAncestor(int ancestorType) {
-        throw new NotImplementedException();
-    }
-
-    public String getAttachedJavadoc(IProgressMonitor monitor) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IResource getCorrespondingResource() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public String getElementName() {
-        throw new NotImplementedException();
-    }
-
-    public int getElementType() {
-        throw new NotImplementedException();
-    }
-
-    public String getHandleIdentifier() {
-        throw new NotImplementedException();
-    }
-
-    public IJavaModel getJavaModel() {
-        throw new NotImplementedException();
-    }
-
-    public IJavaProject getJavaProject() {
-        throw new NotImplementedException();
-    }
-
-    public IOpenable getOpenable() {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement getParent() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getPath() {
-        throw new NotImplementedException();
-    }
-
-    public IJavaElement getPrimaryElement() {
-        throw new NotImplementedException();
-    }
-
-    public IResource getResource() {
-        throw new NotImplementedException();
-    }
-
-    public ISchedulingRule getSchedulingRule() {
-        throw new NotImplementedException();
-    }
-
-    public IResource getUnderlyingResource() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isReadOnly() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isStructureKnown() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("unchecked")
-    public Object getAdapter(Class adapter) {
-        throw new NotImplementedException();
-    }
-
-    public void close() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public String findRecommendedLineSeparator() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public IBuffer getBuffer() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean hasUnsavedChanges() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isConsistent() throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isOpen() {
-        throw new NotImplementedException();
-    }
-
-    public void makeConsistent(IProgressMonitor progress) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public void open(IProgressMonitor progress) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-    public void save(IProgressMonitor progress, boolean force) throws JavaModelException {
-        throw new NotImplementedException();
-    }
-
-	public IJavaElement findElement(String bindingKey, WorkingCopyOwner owner)
-			throws JavaModelException {
-        throw new NotImplementedException();
-	}
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ProjectMock.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ProjectMock.java
deleted file mode 100644
index 4c409dc..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/com/android/ide/eclipse/mock/ProjectMock.java
+++ /dev/null
@@ -1,499 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ide.eclipse.mock;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IProjectDescription;
-import org.eclipse.core.resources.IProjectNature;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceProxy;
-import org.eclipse.core.resources.IResourceProxyVisitor;
-import org.eclipse.core.resources.IResourceVisitor;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourceAttributes;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IPluginDescriptor;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.QualifiedName;
-import org.eclipse.core.runtime.content.IContentTypeMatcher;
-import org.eclipse.core.runtime.jobs.ISchedulingRule;
-
-import sun.reflect.generics.reflectiveObjects.NotImplementedException;
-
-import java.net.URI;
-import java.util.Map;
-
-public class ProjectMock implements IProject {
-
-    public void build(int kind, IProgressMonitor monitor) throws CoreException {
-        // pass
-    }
-
-    @SuppressWarnings("unchecked")
-    public void build(int kind, String builderName, Map args, IProgressMonitor monitor)
-            throws CoreException {
-        // pass
-    }
-    
-    // -------- UNIMPLEMENTED METHODS ----------------
-
-
-    public void close(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void create(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void create(IProjectDescription description, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean deleteContent, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IContentTypeMatcher getContentTypeMatcher() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IProjectDescription getDescription() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IFile getFile(String name) {
-        throw new NotImplementedException();
-    }
-
-    public IFolder getFolder(String name) {
-        throw new NotImplementedException();
-    }
-
-    public IProjectNature getNature(String natureId) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    @SuppressWarnings("deprecation")
-    public IPath getPluginWorkingLocation(IPluginDescriptor plugin) {
-        throw new NotImplementedException();
-    }
-
-    public IProject[] getReferencedProjects() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IProject[] getReferencingProjects() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getWorkingLocation(String id) {
-        throw new NotImplementedException();
-    }
-
-    public boolean hasNature(String natureId) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isNatureEnabled(String natureId) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean isOpen() {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void open(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void open(int updateFlags, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDescription(IProjectDescription description, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDescription(IProjectDescription description, int updateFlags,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IFile[] findDeletedMembersWithHistory(int depth, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(String name) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(String name, boolean includePhantoms) {
-        throw new NotImplementedException();
-    }
-
-    public IResource findMember(IPath path, boolean includePhantoms) {
-        throw new NotImplementedException();
-    }
-
-    public String getDefaultCharset() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getDefaultCharset(boolean checkImplicit) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IFile getFile(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IFolder getFolder(IPath path) {
-        throw new NotImplementedException();
-    }
-
-    public IResource[] members() throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResource[] members(boolean includePhantoms) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResource[] members(int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDefaultCharset(String charset) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDefaultCharset(String charset, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceProxyVisitor visitor, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, boolean includePhantoms)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void accept(IResourceVisitor visitor, int depth, int memberFlags) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void clearHistory(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void copy(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker createMarker(String type) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IResourceProxy createProxy() {
-        throw new NotImplementedException();
-    }
-
-    public void delete(boolean force, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void delete(int updateFlags, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void deleteMarkers(String type, boolean includeSubtypes, int depth) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public boolean exists() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker findMarker(long id) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IMarker[] findMarkers(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int findMaxProblemSeverity(String type, boolean includeSubtypes, int depth)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public String getFileExtension() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getFullPath() {
-        throw new NotImplementedException();
-    }
-
-    public long getLocalTimeStamp() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getLocation() {
-        throw new NotImplementedException();
-    }
-
-    public URI getLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public IMarker getMarker(long id) {
-        throw new NotImplementedException();
-    }
-
-    public long getModificationStamp() {
-        throw new NotImplementedException();
-    }
-
-    public String getName() {
-        throw new NotImplementedException();
-    }
-
-    public IContainer getParent() {
-        throw new NotImplementedException();
-    }
-
-    public String getPersistentProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public IProject getProject() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getProjectRelativePath() {
-        throw new NotImplementedException();
-    }
-
-    public IPath getRawLocation() {
-        throw new NotImplementedException();
-    }
-
-    public URI getRawLocationURI() {
-        throw new NotImplementedException();
-    }
-
-    public ResourceAttributes getResourceAttributes() {
-        throw new NotImplementedException();
-    }
-
-    public Object getSessionProperty(QualifiedName key) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public int getType() {
-        throw new NotImplementedException();
-    }
-
-    public IWorkspace getWorkspace() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isAccessible() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isDerived() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLinked(int options) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isLocal(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isPhantom() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isReadOnly() {
-        throw new NotImplementedException();
-    }
-
-    public boolean isSynchronized(int depth) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isTeamPrivateMember() {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, boolean force, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IPath destination, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, int updateFlags, IProgressMonitor monitor)
-            throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void move(IProjectDescription description, boolean force, boolean keepHistory,
-            IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void refreshLocal(int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void revertModificationStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setDerived(boolean isDerived) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setLocal(boolean flag, int depth, IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public long setLocalTimeStamp(long value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setPersistentProperty(QualifiedName key, String value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setReadOnly(boolean readOnly) {
-        throw new NotImplementedException();
-    }
-
-    public void setResourceAttributes(ResourceAttributes attributes) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setSessionProperty(QualifiedName key, Object value) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void setTeamPrivateMember(boolean isTeamPrivate) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public void touch(IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-    }
-
-    public Object getAdapter(Class adapter) {
-        throw new NotImplementedException();
-    }
-
-    public boolean contains(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-    public boolean isConflicting(ISchedulingRule rule) {
-        throw new NotImplementedException();
-    }
-
-	public void create(IProjectDescription description, int updateFlags,
-			IProgressMonitor monitor) throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public Map getPersistentProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public Map getSessionProperties() throws CoreException {
-        throw new NotImplementedException();
-	}
-
-	public boolean isDerived(int options) {
-        throw new NotImplementedException();
-	}
-
-	public boolean isHidden() {
-        throw new NotImplementedException();
-	}
-
-	public void setHidden(boolean isHidden) throws CoreException {
-        throw new NotImplementedException();
-	}
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jar b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jar
deleted file mode 100644
index f95b595..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jar
+++ /dev/null
Binary files differ
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jardesc b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jardesc
deleted file mode 100644
index 14cd44f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/jar_example.jardesc
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
-<jardesc>
-    <jar path="jar_example.jar"/>
-    <options buildIfNeeded="true" compress="true" descriptionLocation="/common/tests/data/jar_example.jardesc" exportErrors="false" exportWarnings="true" includeDirectoryEntries="false" overwrite="false" saveDescription="true" storeRefactorings="false" useSourceFolders="false"/>
-    <storedRefactorings deprecationInfo="true" structuralOnly="false"/>
-    <selectedProjects/>
-    <manifest generateManifest="true" manifestLocation="" manifestVersion="1.0" reuseManifest="false" saveManifest="false" usesManifest="true">
-        <sealing sealJar="false">
-            <packagesToSeal/>
-            <packagesToUnSeal/>
-        </sealing>
-    </manifest>
-    <selectedElements exportClassFiles="true" exportJavaFiles="false" exportOutputFolder="false">
-        <javaElement handleIdentifier="=common/tests&lt;jar.example"/>
-    </selectedElements>
-</jardesc>
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/mock_attrs.xml b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/mock_attrs.xml
deleted file mode 100644
index aa9a1f7..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/data/mock_attrs.xml
+++ /dev/null
@@ -1,340 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<resources>
-    <!-- WARNING !!! THIS IS A MOCK FILE. DO NOT USE FOR DOCUMENTATION PURPOSES.
-         This file has been trimmed down to only extract a number of interesting cases 
-         for unit tests.
-         
-         What this contains:
-         - View
-         - ViewGroup
-         - some attributes which format are defined in Theme
-         - orientation, gravity and layout_gravity defined before they are used
-         - ViewGroup_Layout
-         - ViewGroup_MarginLayout
-         - LinearLayout
-         - LinearLayout_Layout
-         - TableLayout
-         
-         Note that TableLayout does not have a TableLayout_Layout definition here
-         where these is a class TableLayout.LayoutData.
-    -->
-
-    <!-- These are the standard attributes that make up a complete theme. -->
-    <declare-styleable name="Theme">
-
-        <!-- Defines the scrollbars size. -->
-        <attr name="scrollbarSize" format="dimension" />
-
-    </declare-styleable>
-
-        
-    <!-- Standard orientation constant. -->
-    <attr name="orientation">
-        <!-- Defines an horizontal widget. -->
-        <enum name="horizontal" value="0" />
-        <!-- Defines a vertical widget. -->
-        <enum name="vertical" value="1" />
-    </attr>
-
-    <!-- Specifies how to place an object, both
-         its x and y axis, within a larger containing object. -->
-    <attr name="gravity">
-        <!-- Push object to the top of its container, not changing its size. -->
-        <flag name="top" value="0x30" />
-        <!-- Push object to the bottom of its container, not changing its size. -->
-        <flag name="bottom" value="0x50" />
-        <!-- Push object to the left of its container, not changing its size. -->
-        <flag name="left" value="0x03" />
-        <!-- Push object to the right of its container, not changing its size. -->
-        <flag name="right" value="0x05" />
-        <!-- Place object in the vertical center of its container, not changing its size. -->
-        <flag name="center_vertical" value="0x10" />
-        <!-- Grow the vertical size of the object if needed so it completely fills its container. -->
-        <flag name="fill_vertical" value="0x70" />
-        <!-- Place object in the horizontal center of its container, not changing its size. -->
-        <flag name="center_horizontal" value="0x01" />
-        <!-- Grow the horizontal size of the object if needed so it completely fills its container. -->
-        <flag name="fill_horizontal" value="0x07" />
-        <!-- Place the object in the center of its container in both the vertical and horizontal axis, not changing its size. -->
-        <flag name="center" value="0x11" />
-        <!-- Grow the horizontal and vertical size of the object if needed so it completely fills its container. -->
-        <flag name="fill" value="0x77" />
-    </attr>
-
-    <!-- Standard gravity constant that a child can supply to its parent.
-         Defines how to place an object, both
-         its x and y axis, within a larger containing object. -->
-    <attr name="layout_gravity">
-        <!-- Push object to the top of its container, not changing its size. -->
-        <flag name="top" value="0x30" />
-        <!-- Push object to the bottom of its container, not changing its size. -->
-        <flag name="bottom" value="0x50" />
-        <!-- Push object to the left of its container, not changing its size. -->
-        <flag name="left" value="0x03" />
-        <!-- Push object to the right of its container, not changing its size. -->
-        <flag name="right" value="0x05" />
-        <!-- Place object in the vertical center of its container, not changing its size. -->
-        <flag name="center_vertical" value="0x10" />
-        <!-- Grow the vertical size of the object if needed so it completely fills its container. -->
-        <flag name="fill_vertical" value="0x70" />
-        <!-- Place object in the horizontal center of its container, not changing its size. -->
-        <flag name="center_horizontal" value="0x01" />
-        <!-- Grow the horizontal size of the object if needed so it completely fills its container. -->
-        <flag name="fill_horizontal" value="0x07" />
-        <!-- Place the object in the center of its container in both the vertical and horizontal axis, not changing its size. -->
-        <flag name="center" value="0x11" />
-        <!-- Grow the horizontal and vertical size of the object if needed so it completely fills its container. -->
-        <flag name="fill" value="0x77" />
-    </attr>
-
-    <declare-styleable name="View">
-    <!-- NOTE: View does not have a javadoc. Do not place a comment BEFORE View to make sure it
-         is NOT interpreted as Javadoc -->
-    
-        <!-- Supply an identifier name for this view, to later retrieve it
-             with {@link android.view.View#findViewById View.findViewById()} or
-             {@link android.app.Activity#findViewById Activity.findViewById()}.
-             This must be a
-             resource reference; typically you set this using the
-             <code>@+</code> syntax to create a new ID resources.
-             For example: <code>android:id="@+id/my_id"</code> which
-             allows you to later retrieve the view
-             with <code>findViewById(R.id.my_id)</code>. -->
-        <attr name="id" format="reference" />
-        
-        <!-- Supply a tag for this view containing a String, to be retrieved
-             later with {@link android.view.View#getTag View.getTag()} or
-             searched for with {@link android.view.View#findViewWithTag
-             View.findViewWithTag()}.  It is generally preferable to use
-             IDs (through the android:id attribute) instead of tags because
-             they are faster and allow for compile-time type checking. -->
-        <attr name="tag" format="string" />
-        
-        <!-- The initial horizontal scroll offset, in pixels.-->
-        <attr name="scrollX" format="dimension" />
-
-        <!-- The initial vertical scroll offset, in pixels. -->
-        <attr name="scrollY" format="dimension" />
-
-        <!-- A drawable to use as the background.  This can be either a reference
-             to a full drawable resource (such as a PNG image, 9-patch,
-             XML state list description, etc), or a solid color such as "#ff000000"
-            (black). -->
-        <attr name="background" format="reference|color" />
-
-        <!-- Boolean that controls whether a view can take focus.  By default the user can not
-             move focus to a view; by setting this attribute to true the view is
-             allowed to take focus.  This value does not impact the behavior of
-             directly calling {@link android.view.View#requestFocus}, which will
-             always request focus regardless of this view.  It only impacts where
-             focus navigation will try to move focus. -->
-        <attr name="focusable" format="boolean" />
-
-        <!-- Sets the circumstances under which this view will take focus. There are
-             two choices: "weak" or "normal". The default value is "normal" for
-             any focusable views. The focus type only applies if the view
-             has been set to be focusable. -->
-        <attr name="focusType">
-            <!-- This view is focusable, but only if none of its descendants are already focused. -->
-            <enum name="normal" value="0" />
-            <!-- This view will always claim to be focusable. -->
-            <enum name="weak" value="1" />
-        </attr>
-        
-        <!-- Controls the initial visibility of the view.  -->
-        <attr name="visibility">
-            <!-- Visible on screen; the default value. -->
-            <enum name="visible" value="0" />
-            <!-- Not displayed, but taken into account during layout (space is left for it). -->
-            <enum name="invisible" value="1" />
-            <!-- Completely hidden, as if the view had not been added. -->
-            <enum name="gone" value="2" />
-        </attr>
-
-        <!-- Defines which scrollbars should be displayed on scrolling or not. -->
-        <attr name="scrollbars">
-            <!-- No scrollbar is displayed. -->
-            <flag name="none" value="0x00000000" />
-            <!-- Displays horizontal scrollbar only. -->
-            <flag name="horizontal" value="0x00000100" />
-            <!-- Displays vertical scrollbar only. -->
-            <flag name="vertical" value="0x00000200" />
-        </attr>
-
-        <!-- Sets the width of vertical scrollbars and height of horizontal scrollbars. -->
-        <attr name="scrollbarSize" />
-        
-        <!-- Text to display. (copied from TextView for the extra localization) -->
-        <attr name="text" format="string" localization="suggested" />
-        
-    </declare-styleable>
-
-    <!-- Attributes that can be used with a {@link android.view.ViewGroup} or any
-         of its subclasses.  Also see {@link #ViewGroup_Layout} for
-         attributes that this class processes in its children. -->
-    <declare-styleable name="ViewGroup">
-        <!-- Defines whether a child is limited to draw inside of its bounds or not.
-             This is useful with animations that scale the size of the children to more
-             than 100% for instance. In such a case, this property should be set to false
-             to allow the children to draw outside of their bounds. The default value of
-             this property is true. -->
-        <attr name="clipChildren" format="boolean" />
-        <!-- Defines the layout animation to use the first time the ViewGroup is laid out.
-             Layout animations can also be started manually after the first layout. -->
-        <attr name="layoutAnimation" format="reference" />
-        <!-- Defines whether a child's animation should be kept when it is over. Keeping
-             the animations is useful with animation whose final state is different from
-             the initial state of the View. This is particularly useful with animation
-             whose fillAfter property is enabled. This property is set to false by default. -->
-        <attr name="persistentDrawingCache">
-            <!-- The drawing cache is not persisted after use. -->
-            <flag name="none" value="0x0" />
-            <!-- The drawing cache is persisted after a layout animation. -->
-            <flag name="animation" value="0x1" />
-            <!-- The drawing cache is persisted after a scroll. -->
-            <flag name="scrolling" value="0x2" />
-            <!-- The drawing cache is always persisted. -->            
-            <flag name="all" value="0x3" />
-        </attr>
-    </declare-styleable>
-
-    <!-- This is the basic set of layout attributes that are common to all
-         layout managers.  These attributes are specified with the rest of
-         a view's normal attributes (such as {@link android.R.attr#background},
-         but will be parsed by the view's parent and ignored by the child.
-        <p>The values defined here correspond to the base layout attribute
-        class {@link android.view.ViewGroup.LayoutParams}. -->
-    <declare-styleable name="ViewGroup_Layout">
-        <!-- Specifies the basic width of the view.  This is a required attribute
-             for any view inside of a containing layout manager.  Its value may
-             be a dimension (such as "12dip") for a constant width or one of
-             the special constants. -->
-        <attr name="layout_width" format="dimension">
-            <!-- The view should be as big as its parent (minus padding). -->
-            <enum name="fill_parent" value="-1" />
-            <!-- The view should be only big enough to enclose its content (plus padding). -->
-            <enum name="wrap_content" value="-2" />
-        </attr>
-
-        <!-- Specifies the basic height of the view.  This is a required attribute
-             for any view inside of a containing layout manager.  Its value may
-             be a dimension (such as "12dip") for a constant height or one of
-             the special constants. -->
-        <attr name="layout_height" format="dimension">
-            <!-- The view should be as big as its parent (minus padding). -->
-            <enum name="fill_parent" value="-1" />
-            <!-- The view should be only big enough to enclose its content (plus padding). -->
-            <enum name="wrap_content" value="-2" />
-        </attr>
-    </declare-styleable>
-
-    <!-- This is the basic set of layout attributes for layout managers that
-         wish to place margins around their child views.
-         These attributes are specified with the rest of
-         a view's normal attributes (such as {@link android.R.attr#background},
-         but will be parsed by the view's parent and ignored by the child.
-        <p>The values defined here correspond to the base layout attribute
-        class {@link android.view.ViewGroup.MarginLayoutParams}. -->
-    <declare-styleable name="ViewGroup_MarginLayout">
-        <attr name="layout_width" />
-        <attr name="layout_height" />
-        <!--  Specifies extra space on the left side of this view.
-            This space is outside this view's bounds. -->
-        <attr name="layout_marginLeft" format="dimension"  />
-        <!--  Specifies extra space on the top side of this view.
-            This space is outside this view's bounds. -->
-        <attr name="layout_marginTop" format="dimension" />
-        <!--  Specifies extra space on the right side of this view.
-            This space is outside this view's bounds. -->
-        <attr name="layout_marginRight" format="dimension"  />
-        <!--  Specifies extra space on the bottom side of this view.
-            This space is outside this view's bounds. -->
-        <attr name="layout_marginBottom" format="dimension"  />
-    </declare-styleable>
-
-    <!-- This is a linear layout. -->
-    <declare-styleable name="LinearLayout">
-        <!-- Should the layout be a column or a row?  Use "horizontal"
-             for a row, "vertical" for a column.  The default is
-             horizontal. -->
-        <attr name="orientation" />
-        <attr name="baselineAligned" format="boolean|reference" />
-        <!-- When a linear layout is part of another layout that is baseline
-          aligned, it can specify which of its children to baseline align to
-          (i.e which child TextView).-->
-        <attr name="baselineAlignedChildIndex" format="integer|color" min="0"/>
-        <!-- Defines the maximum weight sum. If unspecified, the sum is computed
-             by adding the layout_weight of all of the children. This can be
-             used for instance to give a single child 50% of the total available
-             space by giving it a layout_weight of 0.5 and setting the weightSum
-             to 1.0. -->
-        <attr name="weightSum" format="float" />
-    </declare-styleable>
-
-    <declare-styleable name="LinearLayout_Layout">
-        <attr name="layout_width" />
-        <attr name="layout_height" />
-        <attr name="layout_weight" format="float" />
-        <attr name="layout_gravity" />
-    </declare-styleable>
-
-    <declare-styleable name="TableLayout">
-        <!-- The 0 based index of the columns to stretch. The column indices
-             must be separated by a comma: 1, 2, 5. Illegal and duplicate
-             indices are ignored. You can stretch all columns by using the
-             value "*" instead. Note that a column can be marked stretchable
-             and shrinkable at the same time. -->
-        <attr name="stretchColumns" format="string" />
-       <!-- The 0 based index of the columns to shrink. The column indices
-             must be separated by a comma: 1, 2, 5. Illegal and duplicate
-             indices are ignored. You can shrink all columns by using the
-             value "*" instead. Note that a column can be marked stretchable
-             and shrinkable at the same time. -->
-        <attr name="shrinkColumns" format="string" /> 
-        <!-- The 0 based index of the columns to collapse. The column indices
-             must be separated by a comma: 1, 2, 5. Illegal and duplicate
-             indices are ignored. -->
-        <attr name="collapseColumns" format="string" />
-    </declare-styleable>
-
-	<!-- Test for deprecated attributes. -->
-	<declare-styleable name="DeprecatedTest">
-		<!-- Deprecated comments using delimiters.
-			 Ignored. {@deprecated In-line deprecated.} {@ignore Ignored}.
-		 -->
-		<attr name="deprecated-inline" /> 
-
-		<!-- Deprecated comments on their own line.
-			 @deprecated Multi-line version of deprecated
-			    that works till the next tag.
-			 @ignore This tag must be ignored
-		 -->
-		<attr name="deprecated-multiline" />
-		
-		<!-- This attribute is not deprecated. -->
-		<attr name="deprecated-not" />
-		
-        <!-- {@deprecated There is no other javadoc here. } -->
-        <attr name="deprecated-no-javadoc" format="boolean" />
-		
-	</declare-styleable>
-
-</resources>
-
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/View.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/View.java
deleted file mode 100644
index a80a98d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/View.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package mock_android.view;
-
-public class View {
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/ViewGroup.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/ViewGroup.java
deleted file mode 100644
index 466470f..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/view/ViewGroup.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package mock_android.view;
-
-public class ViewGroup extends View {
-
-    public class MarginLayoutParams extends LayoutParams {
-
-    }
-
-    public class LayoutParams {
-
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/LinearLayout.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/LinearLayout.java
deleted file mode 100644
index 3870a63..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/LinearLayout.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package mock_android.widget;
-
-import mock_android.view.ViewGroup;
-
-public class LinearLayout extends ViewGroup {
-
-    public class LayoutParams extends mock_android.view.ViewGroup.LayoutParams {
-
-    }
-
-}
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/TableLayout.java b/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/TableLayout.java
deleted file mode 100644
index e455e7d..0000000
--- a/tools/eclipse/plugins/com.android.ide.eclipse.tests/unittests/mock_android/widget/TableLayout.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package mock_android.widget;
-
-import mock_android.view.ViewGroup;
-
-public class TableLayout extends ViewGroup {
-
-    public class LayoutParams extends MarginLayoutParams {
-
-    }
-
-}
diff --git a/tools/eclipse/scripts/_mk_icons.sh b/tools/eclipse/scripts/_mk_icons.sh
deleted file mode 100755
index b3ea35b..0000000
--- a/tools/eclipse/scripts/_mk_icons.sh
+++ /dev/null
@@ -1,55 +0,0 @@
-#!/bin/bash
-
-function icon() {
-  # $1=letter, $2=letter's color (e.g. A red), $3=filename
-  ./gen_icon.py ${3}.png 16 white black $2 $1
-}
-
-icon M green  manifest
-  icon S blue   sharedUserId
-  icon S red    signature
-  icon P green  package
-
-icon I green  instrumentation
-  icon F green  functionalTest
-  icon H green  handleProfiling
-  icon I green  icon
-  icon T green  targetPackage
-
-icon U blue   uses-permission
-icon P red    permission
-  icon N green  name
-  icon L blue   label
-
-icon A blue     application
-    icon P red    permission
-    icon P blue   persistent
-    icon P green  process
-    icon T green  taskAffinity
-    icon T blue   theme
-  icon P red    provider
-    icon A green  authorities
-    icon I green  initOrder
-    icon M green  multiprocess
-    icon R green  readPermission
-    icon W green  writePermission
-    icon S green  syncable
-  icon R green  receiver
-  icon S blue   service
-  icon A green  activity
-      icon C blue   clearOnBackground
-      icon C green  configChanges
-      icon E green  excludeFromRecents
-      icon L green  launchMode
-      icon S green  stateNotNeeded
-    icon F blue  intent-filter
-        icon P green  priority
-      icon A red    action
-      icon C green  category
-      icon D green  data
-        icon M green    mimeType
-        icon S green    scheme
-        icon H green    host
-        icon P green    port
-        icon P blue     path
-
diff --git a/tools/eclipse/scripts/build_plugins.sh b/tools/eclipse/scripts/build_plugins.sh
deleted file mode 100755
index 5f94ca0..0000000
--- a/tools/eclipse/scripts/build_plugins.sh
+++ /dev/null
@@ -1,225 +0,0 @@
-#!/bin/bash
-
-# build script for eclipse adt build on linux platform
-#
-# Usage: development/tools/eclipse/scripts/build_plugins <build_version> 
-#
-# It expects environment variable ECLIPSE_HOME to be defined to point to _your_
-# version of Eclipse RCP (must have the WTP & GEF plugins available too.)
-#
-# If ECLIPSE_HOME is not provided, this script will _download_ a reference version
-# of Eclipse RCP and install it in a specific location.
-# 
-# Other properties, ant scripts that drive the build are defined in ./buildConfig
-# Currently, this script will create an update site at ${user.home}/www/no_crawl/android-build
-# or at the directory specified using "-d"
-
-# Known Issues:
-# - Build does not properly clean up after itself (build server always executes from
-#   a clean state.)
-# - Script will fail if current absolute path has spaces in it.
-# - Only linux is supported for now
-
-
-set -e # abort this script early if any command fails
-
-#
-# -- Utility methods --
-# 
-
-function printUsage() {
-  echo "Usage: $0 <build_qualifier> [-i] [-d <destination-directory>] [-a <archivePrefix>] "
-  echo "<build_qualifier>: build qualifier string"
-  echo "-i = build internal site. Otherwise, external site will be built"
-  echo "-d = destination directory. Default is $USER/www/no_crawl/. Cannot contain spaces."
-  echo "-a = archive prefix. Cannot contain spaces."
-}
-
-function die() {
-  echo $@
-  exit 1
-}
-
-function dieWithUsage() {
-  echo $@
-  echo
-  printUsage
-  exit 1
-}
-
-
-#
-# -- Setup our custom version of Eclipse --
-#
-
-# The dependency on the linux platform comes from a series of environment
-# variables that the eclipse ant runner expects. These are defined in the
-# build.properties file. We can easily support other platforms but would need
-# to override those values in this script.
-HOST=`uname`
-[ "$HOST" == "Linux" ] || die "ERROR: This script is currently only supported on Linux platform"
-
-# Make sure this runs from the tools/eclipse plugin.
-D=`dirname "$0"`
-cd "$D/.."
-[ `basename "$PWD"` == "eclipse" ] || dieWithUsage "Please run this script from the device/tools/eclipse directory"
-
-# check for number of parameters
-[ $# -lt 1 ] && dieWithUsage "ERROR: Not enough parameters"
-
-# check if ECLIPSE_HOME set (ECLIPSE_HOME is were the "eclipse" binary and the
-# "plugins" sub-directory are located)
-if [ -z "$ECLIPSE_HOME" ]; then
-  BASE_DIR=/buildbot/eclipse-android
-
-  echo "ECLIPSE_HOME not set, using $BASE_DIR as default"
-
-  if [ ! -d "$BASE_DIR" ]; then
-    mkdir -p "$BASE_DIR" || die "Please create a directory $BASE_DIR where Eclipse will be installed, i.e. execute 'mkdir -p $BASE_DIR && chown $USER $BASE_DIR'."
-  fi
-
-  # download the version if not available
-  VERSION="3.4.0"
-  BASE_DIR="$BASE_DIR/$VERSION"
-  scripts/setup_eclipse.sh -p "$BASE_DIR"
-
-  ECLIPSE_HOME="$BASE_DIR/eclipse"      # path to installed directory
-  PID_FILE="$BASE_DIR/eclipse.pid"
-  [ -f "$PID_FILE" ] && ECLIPSE_PID=`cat "$PID_FILE"`
-fi
-
-echo "PWD=`pwd`"
-echo "ECLIPSE_HOME=$ECLIPSE_HOME"
-
-#
-# -- Site parameters and Build version --
-#
-
-BUILD_VERSION="$1" ; shift
-
-# parse for build internal site flag. If set, pass in internalSite property to ant scripts
-if [ "-i" == "$1" ]; then
-  shift
-  echo "Setting for internal site build"
-  SITE_PARAM="-DinternalSite=1 -DupdateSiteSource=$PWD/sites/internal"
-else
-  SITE_PARAM="-DupdateSiteSource=$PWD/sites/external"
-fi
-
-if [ "-d" == $1 ]; then
-  shift
-  echo "Setting destination directory to $1"
-  SITE_PARAM="$SITE_PARAM -DupdateSiteRoot=$1"
-  shift
-fi
-
-if [ "-a" == "$1" ]; then
-  shift
-  echo "Setting archivePrefix to $1"
-  SITE_PARAM="$SITE_PARAM -DarchivePrefix=$1"
-  shift
-fi
-
-
-#
-# -- Configuration directory --
-#
-
-# The "configuration directory" will hold the workspace for this build.
-# If it contains old data the build may fail so we need to clean it first
-# and create it if it doesn't exist.
-CONFIG_DIR="../../../out/eclipse-configuration-$BUILD_VERSION"
-[ -d "$CONFIG_DIR" ] && rm -rfv "$CONFIG_DIR"
-mkdir -p "$CONFIG_DIR"
-
-# The "buildConfig" directory contains our customized ant rules
-BUILDCONFIG="$PWD/buildConfig"
-
-
-#
-# -- Find Eclipse Launcher --
-#
-
-# Get the Eclipse launcher and build script to use
-function findFirst() {
-  for i in "$@"; do
-    if [ -f "$i" ]; then
-      echo "$i"
-      return
-    fi
-  done
-}
-
-LAUNCHER=`findFirst "$ECLIPSE_HOME"/plugins/org.eclipse.equinox.launcher_*.jar`
-BUILDFILE=`findFirst "$ECLIPSE_HOME"/plugins/org.eclipse.pde.build_*/scripts/build.xml`
-
-# make sure we found valid files
-if [ ! -f "$LAUNCHER" ]; then
-  echo "Installation Error: Eclipse plugin org.eclipse.equinox.launcher...jar not detected. " \
-       "Found '$LAUNCHER'. Aborting."
-  exit 1
-fi
-if [ ! -f "$BUILDFILE" ]; then
-  echo "Installation Error: Eclipse build file org.eclipse.pde.build_.../scripts/build.xml " \
-       "not detected. Found '$BUILDFILE'. Aborting."
-  exit 1
-fi
-
-
-#
-# -- Print configuration used and actually execute the build --
-#
-
-echo "Eclipse configuration found:"
-echo "  Eclipse Home: $ECLIPSE_HOME"
-echo "  Launcher:     $LAUNCHER"
-echo "  Build File:   $BUILDFILE"
-echo "  Build Config: $BUILDCONFIG"
-echo "  Config Dir:   $CONFIG_DIR"
-
-# clean input directories to make sure there's nothing left from previous run
-
-rm -fv *.properties *.xml
-find . -name "@*" | xargs rm -rfv
-
-# Now execute the ant runner
-
-set +e  # don't stop on errors anymore, we want to catch there here
-
-java \
-  -jar $LAUNCHER \
-  -data "$CONFIG_DIR" \
-  -configuration "$CONFIG_DIR" \
-  -application org.eclipse.ant.core.antRunner \
-  -buildfile $BUILDFILE \
-  -Dbuilder=$BUILDCONFIG \
-  -DbuildDirectory=$PWD \
-  -DforceContextQualifier=$BUILD_VERSION \
-  -DECLIPSE_HOME=$ECLIPSE_HOME \
-  $SITE_PARAM
-RESULT=$?
-
-if [ "0" != "$RESULT" ]; then
-    echo "JAVA died with error code $RESULT"
-    echo "Dump of build config logs:"
-    for i in "$CONFIG_DIR"/*.log; do
-        if [ -f "$i" ]; then
-            echo "----------------------"
-            echo "--- $i"
-            echo "----------------------"
-            cat "$i"
-            echo
-        fi
-    done
-fi
-
-#
-# -- Cleanup
-#
-
-if [ -n "$ECLIPSE_PID" ] && [ -f "$PID_FILE" ]; then
-  rm -fv "$PID_FILE"
-  kill -9 "$ECLIPSE_PID"
-fi
-
-# we're done!
diff --git a/tools/eclipse/scripts/build_server.sh b/tools/eclipse/scripts/build_server.sh
deleted file mode 100755
index 39c8dcd..0000000
--- a/tools/eclipse/scripts/build_server.sh
+++ /dev/null
@@ -1,118 +0,0 @@
-#!/bin/bash
-# Entry point to build the Eclipse plugins for the build server.
-#
-# Input parameters:
-# $1: *Mandatory* destination directory. Must already exist. Cannot contain spaces.
-# $2: Optional build number. If present, will be appended to the date qualifier.
-#     The build number cannot contain spaces *nor* periods (dashes are ok.)
-# -z: Optional, prevents the final zip and leaves the udate-site directory intact.
-# -i: Optional, if present, the Google internal update site will be built. Otherwise, 
-#     the external site will be built
-# Workflow:
-# - make dx, ddms, ping
-# - create symlinks (for eclipse code reorg, for ddms, ping)
-# - call the actual builder script from Brett
-# - zip resulting stuff and move to $DEST
-# Note: currently wrap around existing shell script, reuse most of it,
-# eventually both might merge as needed.
-
-set -e  # Fail this script as soon as a command fails -- fail early, fail fast
-
-DEST_DIR=""
-BUILD_NUMBER=""
-CREATE_ZIP="1"
-INTERNAL_BUILD=""
-
-function get_params() {
-  # parse input parameters
-  while [ $# -gt 0 ]; do
-    if [ "$1" == "-z" ]; then
-      CREATE_ZIP=""
-    elif [ "$1" == "-i" ]; then
-      INTERNAL_BUILD="-i"
-    elif [ "$1" != "" ] && [ -z "$DEST_DIR" ]; then
-      DEST_DIR="$1"
-    elif [ "$1" != "" ] && [ -z "$BUILD_NUMBER" ]; then
-      BUILD_NUMBER="$1"
-    fi
-    shift
-  done
-}
-
-function die() {
-  echo "Error:" $*
-  echo "Aborting"
-  exit 1
-}
-
-function check_params() {
-  # This needs to run from the top android directory
-  # Automatically CD to the top android directory, whatever its name
-  D=`dirname "$0"`
-  cd "$D/../../../../" && echo "Switched to directory $PWD"
-
-  # The current Eclipse build has some Linux dependency in its config files
-  [ `uname` == "Linux" ] || die "This must run from a Linux box."
-
-  # Check dest dir exists
-  [ -n "$DEST_DIR" ] || die "Usage: $0 <destination-directory> [build-number]"
-  [ -d "$DEST_DIR" ] || die "Destination directory $DEST_DIR must exist."
-}
-
-function build_libs() {
-  MAKE_OPT="-j8"
-  echo "*** Building: make $MAKE_OPT dx ping ddms jarutils androidprefs layoutlib_api ninepatch sdklib sdkuilib"
-  make $MAKE_OPT dx ping ddms jarutils androidprefs layoutlib_api layoutlib_utils ninepatch sdklib sdkuilib
-}
-
-function build_plugin {
-  development/tools/eclipse/scripts/create_all_symlinks.sh
-
-  # Qualifier is "v" followed by date/time in YYYYMMDDHHSS format and the optional
-  # build number.
-  DATE=`date +v%Y%m%d%H%M`
-  QUALIFIER="$DATE"
-  [ -n "$BUILD_NUMBER" ] && QUALIFIER="${QUALIFIER}-${BUILD_NUMBER}"
-
-  # Compute the final directory name and remove any leftovers from previous
-  # runs if any.
-  BUILD_PREFIX="android-eclipse"  
-  if [ "$INTERNAL_BUILD" ]; then
-    # append 'eng' signifier to end of archive name to denote internal build
-    BUILD_PREFIX="${BUILD_PREFIX}-eng"
-  fi  
-
-  # exclude date from build-zip name so it can be auto-calculated by continuous
-  # test process unless there's no build number, in which case the date is
-  # still used (useful for testing)
-  ZIP_NAME="${BUILD_PREFIX}-${BUILD_NUMBER:-$DATE}.zip"
-  [ -d "$DEST_DIR/$BUILD_PREFIX" ] || rm -rfv "$DEST_DIR/$BUILD_PREFIX"
-
-  # Perform the Eclipse build and move the result in $DEST_DIR/android-build
-  development/tools/eclipse/scripts/build_plugins.sh $QUALIFIER $INTERNAL_BUILD -d "$DEST_DIR" -a "$BUILD_PREFIX"
-
-  # Cleanup
-  [ -d "$QUALIFIER" ] && rm -rfv "$QUALIFIER"
-
-  if [ "$CREATE_ZIP" ]; then
-    # The result is a full update-site under $DEST_DIR/BUILD_PREFIX
-    # Zip it and remove the directory.
-    echo "**** Package in $DEST_DIR"
-    [ -d "$DEST_DIR/$BUILD_PREFIX" ] || \
-      die "Build failed to produce $DEST_DIR/$BUILD_PREFIX"
-    cd "$DEST_DIR"
-    [ -f "$ZIP_NAME" ] && rm -rfv "$ZIP_NAME"
-    cd "$BUILD_PREFIX"
-    zip -9r "../$ZIP_NAME" *
-    cd .. # back to $DEST_DIR
-    rm -rfv "$BUILD_PREFIX"  # removes the directory, not the zip
-    echo "ZIP of Update site available at $DEST_DIR/${ZIP_NAME}"
-  else
-    echo "Update site available in $DEST_DIR/$BUILD_PREFIX"
-  fi
-}
-
-get_params "$@"
-check_params
-build_libs
-build_plugin
diff --git a/tools/eclipse/scripts/build_update_site.sh b/tools/eclipse/scripts/build_update_site.sh
deleted file mode 100755
index 5998756..0000000
--- a/tools/eclipse/scripts/build_update_site.sh
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/bash
-# Entry point to build the Eclipse plugins for local deployment.
-#
-# Input parameters:
-# $1: Optional build number. If present, will be appended to the date qualifier.
-#     The build number cannot contain spaces *nor* periods (dashes are ok.)
-# -i: Optional, if present, the Google internal update site will be built. Otherwise, 
-#     the external site will be built
-#
-# Workflow:
-# - calls buildserver with /home/$USER/www/no_crawl and -z
-#   to build and create the update size but do not zip it in the destination directory.
-
-set -e  # Fail this script as soon as a command fails -- fail early, fail fast
-
-D=`dirname $0`
-BUILD_NUMBER=""
-INTERNAL_BUILD=""
-# parse input parameters
-while [ $# -gt 0 ]; do
-  if [ "$1" == "-i" ]; then
-    INTERNAL_BUILD="-i"
-  elif [ "$1" != "" ]; then
-    BUILD_NUMBER="$1"
-  fi
-  shift
-done
-
-DEST_DIR="$HOME"
-[ -z "$DEST_DIR" ] && [ -n "$USER" ] && DEST_DIR="/home/$USER"
-[ -z "$DEST_DIR" ] && DEST_DIR="~"
-DEST_DIR="$DEST_DIR/www/no_crawl"
-
-"$D/build_server.sh" "$DEST_DIR" "$BUILD_NUMBER" -z "$INTERNAL_BUILD"
diff --git a/tools/eclipse/scripts/collect_sources_for_sdk.sh b/tools/eclipse/scripts/collect_sources_for_sdk.sh
deleted file mode 100644
index 4637595..0000000
--- a/tools/eclipse/scripts/collect_sources_for_sdk.sh
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/bin/bash
-
-function usage() {
-    cat <<EOF
- Description:
-   This script collects all framework Java sources from the current android
-   source code and places them in a source folder suitable for the eclipse ADT
-   plugin.
-
- Usage:
-   $0 [-n] <android-git-repo root> <sdk/platforms/xyz/sources>
- 
- The source and destination directories must already exist.
- Use -n for a dry-run.
-
-EOF
-}
-
-DRY=""
-if [ "-n" == "$1" ]; then
-    DRY="echo"
-    shift
-fi
-
-SRC="$1"
-DST="$2"
-
-if [ -z "$SRC" ] || [ -z "$DST" ] || [ ! -d "$SRC" ] || [ ! -d "$DST" ]; then
-    usage
-    exit 1
-fi
-
-function process() {
-    echo "Examine" $1
-}
-
-N=0
-E=0
-for i in `find -L "${SRC}/frameworks" -name "*.java"`; do
-    if [ -f "$i" ]; then
-        # look for ^package (android.view.blah);$
-        PACKAGE=`sed -n '/^package [^ ;]\+; */{s/[^ ]* *\([^ ;]*\).*/\1/p;q}' "$i"`
-        if [ -n "$PACKAGE" ]; then
-            PACKAGE=${PACKAGE//./\/}    # e.g. android.view => android/view
-            JAVA=`basename "$i"`        # e.g. View.java
-            [ -z $DRY ] && [ ! -d "$DST/$PACKAGE" ] && mkdir -p -v "$DST/$PACKAGE"
-            $DRY cp -v "$i" "$DST/$PACKAGE/$JAVA"
-            N=$((N+1))
-        else
-            echo "Warning: $i does not have a Java package."
-            E=$((E+1))
-        fi
-    fi
-done
-
-echo "$N java files copied"
-[ $E -gt 0 ] && echo "$E warnings"
-
diff --git a/tools/eclipse/scripts/create_adt_symlinks.sh b/tools/eclipse/scripts/create_adt_symlinks.sh
deleted file mode 100755
index 557c4d9..0000000
--- a/tools/eclipse/scripts/create_adt_symlinks.sh
+++ /dev/null
@@ -1,50 +0,0 @@
-#!/bin/bash
-function die() {
-    echo "Error: $*"
-    exit 1
-}
-
-set -e # fail early
-
-# CD to the top android directory
-D=`dirname "$0"`
-cd "$D/../../../../"
-
-DEST="development/tools/eclipse/plugins/com.android.ide.eclipse.adt"
-# computes "../.." from DEST to here (in /android)
-BACK=`echo $DEST | sed 's@[^/]*@..@g'`
-
-LIBS="sdkstats jarutils androidprefs layoutlib_api layoutlib_utils ninepatch sdklib sdkuilib"
-
-echo "make java libs ..."
-make -j3 showcommands $LIBS || die "ADT: Fail to build one of $LIBS."
-
-echo "Copying java libs to $DEST"
-
-HOST=`uname`
-if [ "$HOST" == "Linux" ]; then
-    for LIB in $LIBS; do
-        ln -svf $BACK/out/host/linux-x86/framework/$LIB.jar "$DEST/"
-    done
-    ln -svf $BACK/out/host/linux-x86/framework/kxml2-2.3.0.jar "$DEST/"
-  
-elif [ "$HOST" == "Darwin" ]; then
-    for LIB in $LIBS; do
-        ln -svf $BACK/out/host/darwin-x86/framework/$LIB.jar "$DEST/"
-    done
-    ln -svf $BACK/out/host/darwin-x86/framework/kxml2-2.3.0.jar "$DEST/"
-
-elif [ "${HOST:0:6}" == "CYGWIN" ]; then
-    for LIB in $LIBS; do
-        cp -vf  out/host/windows-x86/framework/$LIB.jar "$DEST/"
-    done
-
-    if [ ! -f "$DEST/kxml2-2.3.0.jar" ]; then
-        cp -v "prebuilt/common/kxml2/kxml2-2.3.0.jar" "$DEST/"
-    fi
-
-    chmod -v a+rx "$DEST"/*.jar
-else
-    echo "Unsupported platform ($HOST). Nothing done."
-fi
-
diff --git a/tools/eclipse/scripts/create_all_symlinks.sh b/tools/eclipse/scripts/create_all_symlinks.sh
deleted file mode 100755
index 8508343..0000000
--- a/tools/eclipse/scripts/create_all_symlinks.sh
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/bash
-
-echo "### $0 executing"
-
-function die() {
-    echo "Error: $*"
-    exit 1
-}
-
-# CD to the top android directory
-D=`dirname "$0"`
-cd "$D/../../../../"
-
-DEST="development/tools/eclipse/scripts"
-
-set -e # fail early
-
-echo ; echo "### ADT ###" ; echo
-$DEST/create_adt_symlinks.sh "$*"
-echo ; echo "### DDMS ###" ; echo
-$DEST/create_ddms_symlinks.sh "$*"
-echo ; echo "### TEST ###" ; echo
-$DEST/create_test_symlinks.sh "$*"
-echo ; echo "### BRIDGE ###" ; echo
-$DEST/create_bridge_symlinks.sh "$*"
-
-echo "### $0 done"
diff --git a/tools/eclipse/scripts/create_bridge_symlinks.sh b/tools/eclipse/scripts/create_bridge_symlinks.sh
deleted file mode 100755
index 605ef63..0000000
--- a/tools/eclipse/scripts/create_bridge_symlinks.sh
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/bash
-function die() {
-    echo "Error: $*"
-    exit 1
-}
-
-set -e # fail early
-
-# CD to the top android directory
-D=`dirname "$0"`
-cd "$D/../../../../"
-
-HOST=`uname`
-if [ "$HOST" == "Linux" ]; then
-    echo # nothing to do
-
-elif [ "$HOST" == "Darwin" ]; then
-    echo # nothing to do
-
-elif [ "${HOST:0:6}" == "CYGWIN" ]; then
-    if [ "x$1" == "x" ] || [ `basename "$1"` != "layoutlib.jar" ]; then
-        echo "Usage: $0 sdk/platforms/xxx/data/layoutlib.jar"
-        echo "Argument 1 should be the path to the layoutlib.jar that should be updated."
-        exit 1
-    fi
-
-    LIBS="layoutlib ninepatch"
-    echo "Make java libs: $LIBS"
-    make -j3 showcommands $LIBS || die "Bridge: Failed to build one of $LIBS."
-
-    echo "Updating your SDK in $1"
-    cp -vf  "out/host/windows-x86/framework/layoutlib.jar" "$1"
-    chmod -v a+rx "$1"
-
-else
-    echo "Unsupported platform ($HOST). Nothing done."
-fi
-
diff --git a/tools/eclipse/scripts/create_ddms_symlinks.sh b/tools/eclipse/scripts/create_ddms_symlinks.sh
deleted file mode 100755
index 276cf9b..0000000
--- a/tools/eclipse/scripts/create_ddms_symlinks.sh
+++ /dev/null
@@ -1,79 +0,0 @@
-#!/bin/bash
-#----------------------------------------------------------------------------|
-# Creates the links to use ddm{ui}lib in the eclipse-ide plugin.
-# Run this from device/tools/eclipse/scripts
-#----------------------------------------------------------------------------|
-
-set -e
-
-HOST=`uname`
-if [ "${HOST:0:6}" == "CYGWIN" ]; then
-    # We can't use symlinks under Cygwin
-
-    function cpfile { # $1=dest $2=source
-        cp -fv $2 $1/
-    }
-
-    function cpdir() { # $1=dest $2=source
-        rsync -avW --delete-after $2 $1
-    }
-
-else
-    # For all other systems which support symlinks
-
-    # computes the "reverse" path, e.g. "a/b/c" => "../../.."
-    function back() {
-        echo $1 | sed 's@[^/]*@..@g'
-    }
-
-    function cpfile { # $1=dest $2=source
-        ln -svf `back $1`/$2 $1/
-    }
-
-    function cpdir() { # $1=dest $2=source
-        ln -svf `back $1`/$2 $1
-    }
-fi
-
-# CD to the top android directory
-D=`dirname "$0"`
-cd "$D/../../../../"
-
-
-BASE="development/tools/eclipse/plugins/com.android.ide.eclipse.ddms"
-
-DEST=$BASE/libs
-mkdir -p $DEST
-for i in prebuilt/common/jfreechart/*.jar; do
-  cpfile $DEST $i
-done
-
-DEST=$BASE/src/com/android
-mkdir -p $DEST
-for i in development/tools/ddms/libs/ddmlib/src/com/android/ddmlib \
-         development/tools/ddms/libs/ddmuilib/src/com/android/ddmuilib ; do
-  cpdir $DEST $i
-done
-
-DEST=$BASE/icons
-mkdir -p $DEST
-for i in \
-    add.png \
-    backward.png \
-    clear.png \
-    d.png debug-attach.png debug-error.png debug-wait.png delete.png device.png down.png \
-    e.png edit.png empty.png emulator.png \
-    forward.png \
-    gc.png \
-    heap.png halt.png \
-    i.png importBug.png \
-    load.png \
-    pause.png play.png pull.png push.png \
-    save.png \
-    thread.png \
-    up.png \
-    v.png \
-    w.png warning.png ; do
-  cpfile $DEST development/tools/ddms/libs/ddmuilib/src/resources/images/$i
-done
-
diff --git a/tools/eclipse/scripts/create_test_symlinks.sh b/tools/eclipse/scripts/create_test_symlinks.sh
deleted file mode 100755
index 931dce8..0000000
--- a/tools/eclipse/scripts/create_test_symlinks.sh
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/bash
-
-set -e
-
-# CD to the top android directory
-D=`dirname "$0"`
-cd "$D/../../../../"
-
-# computes relative ".." paths from $1 to here (in /android)
-function back() {
-  echo $1 | sed 's@[^/]*@..@g'
-}
-
-HOST=`uname`
-if [ "${HOST:0:6}" == "CYGWIN" ]; then
-    # We can't use symlinks under Cygwin
-    function cpdir() { # $1=dest $2=source
-        rsync -avW --delete-after $2 $1
-    }
-
-else
-    # For all other systems which support symlinks
-    function cpdir() { # $1=dest $2=source
-        ln -svf `back $1`/$2 $1
-    }
-fi
-
-BASE="development/tools/eclipse/plugins/com.android.ide.eclipse.tests"
-DEST=$BASE
-BACK=`back $DEST`
-
-HOST=`uname`
-if [ "$HOST" == "Linux" ]; then
-    ln -svf $BACK/out/host/linux-x86/framework/kxml2-2.3.0.jar "$DEST/"
-
-elif [ "$HOST" == "Darwin" ]; then
-    ln -svf $BACK/out/host/darwin-x86/framework/kxml2-2.3.0.jar "$DEST/"
-
-elif [ "${HOST:0:6}" == "CYGWIN" ]; then
-
-    if [ ! -f "$DEST/kxml2-2.3.0.jar" ]; then
-        cp -v "prebuilt/common/kxml2/kxml2-2.3.0.jar" "$DEST/"
-        chmod -v a+rx "$DEST"/*.jar
-    fi
-
-else
-    echo "Unsupported platform ($HOST). Nothing done."
-fi
-
-# create link to ddmlib tests
-DEST=$BASE/unittests/com/android
-BACK=`back $DEST`
-cpdir $DEST development/tools/ddms/libs/ddmlib/tests/src/com/android/ddmlib
-
diff --git a/tools/eclipse/scripts/gen_icon.py b/tools/eclipse/scripts/gen_icon.py
deleted file mode 100755
index f6274e1..0000000
--- a/tools/eclipse/scripts/gen_icon.py
+++ /dev/null
@@ -1,71 +0,0 @@
-#!/usr/bin/python
-
-import sys
-import StringIO
-try:
-    import Image, ImageDraw, ImageFont
-except ImportError, e:
-    print str(e)
-    print "Are you missing the Python Imaging Library? (apt-get install python-imaging)"
-    sys.exit(1)
-
-FONT_PATH = "/usr/share/fonts/truetype/msttcorefonts/arial.ttf"
-
-class Args(object):
-    def __init__(self, dest_name, size, circle_color, border_color,
-                 letter_color, letter):
-        self.dest_name = dest_name
-        self.size = size
-        self.circle_color = circle_color
-        self.border_color = border_color
-        self.letter_color = letter_color
-        self.letter = letter
-
-def main(args):
-    data = process_args(args)
-    if data:
-        createImage(data)
-
-def process_args(args):
-    if not args or len(args) != 6:
-        usage()
-    return Args(*args)
-    
-def usage():
-    print """Usage: %s <file_name> <size> <circle-color> <border-color> <letter-color> <letter>""" % sys.argv[0]
-    sys.exit(1)
-
-def createImage(data):
-    zoom = 4
-    rmin = -zoom/2
-    rmax = zoom/2
-    if zoom > 1:
-        r = range(-zoom/2, zoom/2+1)
-    else:
-        r = [ 0 ]
-    sz = int(data.size)
-    sz4 = sz * zoom
-    
-    img = Image.new("RGBA", (sz4, sz4), (255,255,255,0))
-    draw = ImageDraw.Draw(img)
-
-    draw.ellipse((0, 0, sz4-zoom, sz4-zoom),
-                     fill=data.circle_color, outline=None)
-    for i in r:
-        draw.ellipse((i, i, sz4-i-zoom, sz4-i-zoom),
-                     fill=None, outline=data.border_color)
-
-    font = ImageFont.truetype(FONT_PATH, int(sz4 * .75))
-    tsx, tsy = draw.textsize(data.letter, font=font)
-
-    ptx = (sz4 - tsx) / 2
-    pty = (sz4 - tsy) / 2
-    for i in r:
-        draw.text((ptx + i, pty), data.letter, font=font, fill=data.letter_color)
-
-    img = img.resize((sz, sz), Image.BICUBIC)
-    img.save(data.dest_name, "PNG")
-    print "Saved", data.dest_name
-
-if __name__ == "__main__":
-    main(sys.argv[1:])
diff --git a/tools/eclipse/scripts/setup_eclipse.sh b/tools/eclipse/scripts/setup_eclipse.sh
deleted file mode 100755
index 5143e23..0000000
--- a/tools/eclipse/scripts/setup_eclipse.sh
+++ /dev/null
@@ -1,67 +0,0 @@
-#!/bin/bash
-
-# Quick script used to setup Eclipse for the ADT plugin build.
-#
-# usage:
-#   setup_eclipse.sh <dest_dir>
-#
-# Workflow:
-# - downloads & unpack Eclipse if necessary
-# - *runs* it once
-
-
-#-----------------
-#
-# Note: right now this is invoked by //device/tools/eclipse/doBuild.sh
-# and it *MUST* be invoked with the following destination directory:
-#
-# $ setup_eclipse.sh /buildbot/eclipse-android/3.4.0/
-#
-#-----------------
-
-
-set -e # abort this script early if any command fails
-
-function die() {
-  echo $@
-  exit 1
-}
-
-if [ "-p" == "$1" ]; then
-  GET_PID="-p"
-  shift
-fi
-
-BASE_DIR="$1"
-
-[ -n "$1" ] || die "Usage: $0 <dest-dir>"
-
-# URL for 3.4.0 RCP Linux 32 Bits. Includes GEF, WTP as needed.
-DOWNLOAD_URL="http://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/ganymede/R/eclipse-rcp-ganymede-linux-gtk.tar.gz&url=http://eclipse.unixheads.org/technology/epp/downloads/release/ganymede/R/eclipse-rcp-ganymede-linux-gtk.tar.gz&mirror_id=480"
-
-BIN="$BASE_DIR/eclipse/eclipse"           # path to installed binary
-TARGZ="$BASE_DIR/eclipse-rcp-ganymede-linux-gtk.tar.gz"
-
-if [ ! -f "$BIN" ]; then   
-  echo "Downloading and installing Eclipse in $BASE_DIR."
-  mkdir -p "$BASE_DIR"
-  wget --continue --no-verbose --output-document="$TARGZ" "$DOWNLOAD_URL"
-  echo "Unpacking $TARGZ"
-  (cd "$BASE_DIR" && tar xzf "$TARGZ")
-    
-  echo
-  echo "*** WARNING: To setup Eclipse correctly, it must be ran at least once manually"
-  echo "***          Eclipse will now start."
-  echo
-  if [ -n "$GET_PID" ]; then
-    # if started from the automatic eclipse build, run Eclipse in the background
-    "$BIN" &
-    ECLIPSE_PID=$!
-    echo "*** Eclipse started in background with PID $ECLIPSE_PID"
-    echo "$ECLIPSE_PID" > "$BASE_DIR"/eclipse.pid
-    sleep 5  # give some time for Eclipse to start and setup its environment
-  else
-    # if started manually, run Eclipse in the foreground
-    "$BIN"
-  fi
-fi
diff --git a/tools/eclipse/scripts/update_version.sh b/tools/eclipse/scripts/update_version.sh
deleted file mode 100644
index a288965..0000000
--- a/tools/eclipse/scripts/update_version.sh
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/bin/bash
-
-OLD="$1"
-NEW="$2"
-
-# sanity check in input args
-if [ -z "$OLD" ] || [ -z "$NEW" ]; then
-    cat <<EOF
-Usage: $0 <old> <new>
-Changes the ADT plugin revision number.
-Example:
-  cd tools/eclipse
-  scripts/update_version.sh 0.1.2 0.2.3
-EOF
-    exit 1
-fi
-
-# sanity check on current dir
-if [ `basename "$PWD"` != "eclipse" ]; then
-    echo "Please run this from tools/eclipse."
-    exit 1
-fi
-
-# quote dots for regexps
-OLD="${OLD//./\.}"
-NEW="${NEW//./\.}"
-
-# Find all the files with the old pattern, except changes.txt and
-# p4 edit them. Skip that if there's no p4 in path.
-if which g4 1>/dev/null 2>/dev/null ; then
-    grep -rl "$OLD" * | grep -E "\.xml$|\.MF$" | xargs -n 5 g4 edit
-fi
-
-# Now find the same files but this time use sed to replace in-place with
-# the new pattern. Old files get backuped with the .old extension.
-grep -rl "$OLD" * | grep -E "\.xml$|\.MF$" | xargs -n 1 sed -i.old "s/$OLD/$NEW/g"
-
diff --git a/tools/eclipse/sites/external/.project b/tools/eclipse/sites/external/.project
deleted file mode 100644
index 9916269..0000000
--- a/tools/eclipse/sites/external/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>external-site</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.pde.UpdateSiteBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.UpdateSiteNature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/sites/external/index.html b/tools/eclipse/sites/external/index.html
deleted file mode 100644
index 784be4b..0000000
--- a/tools/eclipse/sites/external/index.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<html>
-<head>
-<title>Android Development Toolkit update site.</title>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<style>@import url("web/site.css");</style>
-<script type="text/javascript">
-	var returnval = 0;
-	var stylesheet, xmlFile, cache, doc;
-	function init(){
-		// NSCP 7.1+ / Mozilla 1.4.1+ / Safari
-		// Use the standard DOM Level 2 technique, if it is supported
-		if (document.implementation && document.implementation.createDocument) {
-			xmlFile = document.implementation.createDocument("", "", null);
-			stylesheet = document.implementation.createDocument("", "", null);
-			if (xmlFile.load){
-				xmlFile.load("site.xml");
-				stylesheet.load("web/site.xsl");
-			} else {
-				alert("Document could not be loaded by browser.");
-			}
-			xmlFile.addEventListener("load", transform, false);
-			stylesheet.addEventListener("load", transform, false);
-		}
-		//IE 6.0+ solution
-		else if (window.ActiveXObject) {
-			xmlFile = new ActiveXObject("msxml2.DOMDocument.3.0");
-			xmlFile.async = false;
-			xmlFile.load("site.xml");
-			stylesheet = new ActiveXObject("msxml2.FreeThreadedDOMDocument.3.0");
-			stylesheet.async = false;
-			stylesheet.load("web/site.xsl");
-			cache = new ActiveXObject("msxml2.XSLTemplate.3.0");
-			cache.stylesheet = stylesheet;
-			transformData();
-		}
-	}
-	// separate transformation function for IE 6.0+
-	function transformData(){
-		var processor = cache.createProcessor();
-		processor.input = xmlFile;
-		processor.transform();
-		data.innerHTML = processor.output;
-	}
-	// separate transformation function for NSCP 7.1+ and Mozilla 1.4.1+
-	function transform(){
-		returnval+=1;
-		if (returnval==2){
-			var processor = new XSLTProcessor();
-			processor.importStylesheet(stylesheet);
-			doc = processor.transformToDocument(xmlFile);
-			document.getElementById("data").innerHTML = doc.documentElement.innerHTML;
-		}
-	}
-</script>
-</head>
-<body onload="init();">
-<!--[insert static HTML here]-->
-<div id="data"><!-- this is where the transformed data goes --></div>
-</body>
-</html>
diff --git a/tools/eclipse/sites/external/site.xml b/tools/eclipse/sites/external/site.xml
deleted file mode 100644
index 9fca8d2..0000000
--- a/tools/eclipse/sites/external/site.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<site>
-   <description url="https://dl-ssl.google.com/android/eclipse/">
-      Update Site for Android Development Toolkit
-   </description>
-   <feature url="features/com.android.ide.eclipse.adt_0.9.0.qualifier.jar" id="com.android.ide.eclipse.adt" version="0.9.0.qualifier">
-      <category name="developer"/>
-   </feature>
-   <feature url="features/com.android.ide.eclipse.ddms_0.9.0.qualifier.jar" id="com.android.ide.eclipse.ddms" version="0.9.0.qualifier">
-      <category name="developer"/>
-   </feature>
-   <category-def name="developer" label="Developer Tools">
-      <description>
-         Features that add Android support to Eclipse for application developers.
-      </description>
-   </category-def>
-</site>
diff --git a/tools/eclipse/sites/external/web/site.css b/tools/eclipse/sites/external/web/site.css
deleted file mode 100644
index 62c6f9f..0000000
--- a/tools/eclipse/sites/external/web/site.css
+++ /dev/null
@@ -1,12 +0,0 @@
-<STYLE type="text/css">
-td.spacer {padding-bottom: 10px; padding-top: 10px;}
-.title { font-family: sans-serif; color: #99AACC;}
-.bodyText { font-family: sans-serif; font-size: 9pt; color:#000000;  }
-.sub-header { font-family: sans-serif; font-style: normal; font-weight: bold; font-size: 9pt; color: white;}
-.log-text {font-family: sans-serif; font-style: normal; font-weight: lighter; font-size: 8pt; color:black;}
-.big-header { font-family: sans-serif; font-style: normal; font-weight: bold; font-size: 9pt; color: white; border-top:10px solid white;}
-.light-row {background:#FFFFFF}
-.dark-row {background:#EEEEFF}
-.header {background:#99AADD}
-#indent {word-wrap : break-word;width :300px;text-indent:10px;}
-</STYLE>
diff --git a/tools/eclipse/sites/external/web/site.xsl b/tools/eclipse/sites/external/web/site.xsl
deleted file mode 100644
index a94157d..0000000
--- a/tools/eclipse/sites/external/web/site.xsl
+++ /dev/null
@@ -1,214 +0,0 @@
-<xsl:stylesheet version = '1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:msxsl="urn:schemas-microsoft-com:xslt">
-<xsl:output method="html" encoding="UTF-8"/>
-<xsl:key name="cat" match="category" use="@name"/>
-<xsl:template match="/">
-<xsl:for-each select="site">
-	<html>
-	<head>
-	<title>update-site</title>
-	<style>@import url("web/site.css");</style>
-	</head>
-	<body>
-	<h1 class="title">update-site</h1>
-	<p class="bodyText"><xsl:value-of select="description"/></p>
-	<table width="100%" border="0" cellspacing="1" cellpadding="2">
-	<xsl:for-each select="category-def">
-		<xsl:sort select="@label" order="ascending" case-order="upper-first"/>
-		<xsl:sort select="@name" order="ascending" case-order="upper-first"/>
-	<xsl:if test="count(key('cat',@name)) != 0">
-			<tr class="header">
-				<td class="sub-header" width="30%">
-					<xsl:value-of select="@name"/>
-				</td>
-				<td class="sub-header" width="70%">
-					<xsl:value-of select="@label"/>
-				</td>
-			</tr>
-			<xsl:for-each select="key('cat',@name)">
-			<xsl:sort select="ancestor::feature//@version" order="ascending"/>
-			<xsl:sort select="ancestor::feature//@id" order="ascending" case-order="upper-first"/>
-			<tr>
-				<xsl:choose>
-				<xsl:when test="(position() mod 2 = 1)">
-					<xsl:attribute name="class">dark-row</xsl:attribute>
-				</xsl:when>
-				<xsl:otherwise>
-					<xsl:attribute name="class">light-row</xsl:attribute>
-				</xsl:otherwise>
-				</xsl:choose>
-				<td class="log-text" id="indent">
-						<xsl:choose>
-						<xsl:when test="ancestor::feature//@label">
-							<a href="{ancestor::feature//@url}"><xsl:value-of select="ancestor::feature//@label"/></a>
-							<br/>
-							<div id="indent">
-							(<xsl:value-of select="ancestor::feature//@id"/> - <xsl:value-of select="ancestor::feature//@version"/>)
-							</div>
-						</xsl:when>
-						<xsl:otherwise>
-						<a href="{ancestor::feature//@url}"><xsl:value-of select="ancestor::feature//@id"/> - <xsl:value-of select="ancestor::feature//@version"/></a>
-						</xsl:otherwise>
-						</xsl:choose>
-						<br />
-				</td>
-				<td>
-					<table>
-						<xsl:if test="ancestor::feature//@os">
-							<tr><td class="log-text" id="indent">Operating Systems:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@os"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@ws">
-							<tr><td class="log-text" id="indent">Windows Systems:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@ws"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@nl">
-							<tr><td class="log-text" id="indent">Languages:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@nl"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@arch">
-							<tr><td class="log-text" id="indent">Architecture:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@arch"/></td>
-							</tr>
-						</xsl:if>
-					</table>
-				</td>
-			</tr>
-			</xsl:for-each>
-			<tr><td class="spacer"><br/></td><td class="spacer"><br/></td></tr>
-		</xsl:if>
-	</xsl:for-each>
-	<xsl:if test="count(feature)  &gt; count(feature/category)">
-	<tr class="header">
-		<td class="sub-header" colspan="2">
-		Uncategorized
-		</td>
-	</tr>
-	</xsl:if>
-	<xsl:choose>
-	<xsl:when test="function-available('msxsl:node-set')">
-	   <xsl:variable name="rtf-nodes">
-		<xsl:for-each select="feature[not(category)]">
-			<xsl:sort select="@id" order="ascending" case-order="upper-first"/>
-			<xsl:sort select="@version" order="ascending" />
-			<xsl:value-of select="."/>
-			<xsl:copy-of select="." />
-		</xsl:for-each>
-	   </xsl:variable>
-	   <xsl:variable name="myNodeSet" select="msxsl:node-set($rtf-nodes)/*"/>
-	<xsl:for-each select="$myNodeSet">
-	<tr>
-		<xsl:choose>
-		<xsl:when test="position() mod 2 = 1">
-		<xsl:attribute name="class">dark-row</xsl:attribute>
-		</xsl:when>
-		<xsl:otherwise>
-		<xsl:attribute name="class">light-row</xsl:attribute>
-		</xsl:otherwise>
-		</xsl:choose>
-		<td class="log-text" id="indent">
-			<xsl:choose>
-			<xsl:when test="@label">
-				<a href="{@url}"><xsl:value-of select="@label"/></a>
-				<br />
-				<div id="indent">
-				(<xsl:value-of select="@id"/> - <xsl:value-of select="@version"/>)
-				</div>
-			</xsl:when>
-			<xsl:otherwise>
-				<a href="{@url}"><xsl:value-of select="@id"/> - <xsl:value-of select="@version"/></a>
-			</xsl:otherwise>
-			</xsl:choose>
-			<br /><br />
-		</td>
-		<td>
-			<table>
-				<xsl:if test="@os">
-					<tr><td class="log-text" id="indent">Operating Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@os"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@ws">
-					<tr><td class="log-text" id="indent">Windows Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@ws"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@nl">
-					<tr><td class="log-text" id="indent">Languages:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@nl"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@arch">
-					<tr><td class="log-text" id="indent">Architecture:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@arch"/></td>
-					</tr>
-				</xsl:if>
-			</table>
-		</td>
-	</tr>
-	</xsl:for-each>
-	</xsl:when>
-	<xsl:otherwise>
-	<xsl:for-each select="feature[not(category)]">
-	<xsl:sort select="@id" order="ascending" case-order="upper-first"/>
-	<xsl:sort select="@version" order="ascending" />
-	<tr>
-		<xsl:choose>
-		<xsl:when test="count(preceding-sibling::feature[not(category)]) mod 2 = 1">
-		<xsl:attribute name="class">dark-row</xsl:attribute>
-		</xsl:when>
-		<xsl:otherwise>
-		<xsl:attribute name="class">light-row</xsl:attribute>
-		</xsl:otherwise>
-		</xsl:choose>
-		<td class="log-text" id="indent">
-			<xsl:choose>
-			<xsl:when test="@label">
-				<a href="{@url}"><xsl:value-of select="@label"/></a>
-				<br />
-				<div id="indent">
-				(<xsl:value-of select="@id"/> - <xsl:value-of select="@version"/>)
-				</div>
-			</xsl:when>
-			<xsl:otherwise>
-				<a href="{@url}"><xsl:value-of select="@id"/> - <xsl:value-of select="@version"/></a>
-			</xsl:otherwise>
-			</xsl:choose>
-			<br /><br />
-		</td>
-		<td>
-			<table>
-				<xsl:if test="@os">
-					<tr><td class="log-text" id="indent">Operating Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@os"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@ws">
-					<tr><td class="log-text" id="indent">Windows Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@ws"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@nl">
-					<tr><td class="log-text" id="indent">Languages:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@nl"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@arch">
-					<tr><td class="log-text" id="indent">Architecture:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@arch"/></td>
-					</tr>
-				</xsl:if>
-			</table>
-		</td>
-	</tr>
-	</xsl:for-each>
-	</xsl:otherwise>
-	</xsl:choose>
-	</table>
-	</body>
-	</html>
-</xsl:for-each>
-</xsl:template>
-</xsl:stylesheet>
diff --git a/tools/eclipse/sites/internal/.project b/tools/eclipse/sites/internal/.project
deleted file mode 100644
index 0bd658d..0000000
--- a/tools/eclipse/sites/internal/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>internal-site</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.pde.UpdateSiteBuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.pde.UpdateSiteNature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eclipse/sites/internal/index.html b/tools/eclipse/sites/internal/index.html
deleted file mode 100644
index 784be4b..0000000
--- a/tools/eclipse/sites/internal/index.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<html>
-<head>
-<title>Android Development Toolkit update site.</title>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<style>@import url("web/site.css");</style>
-<script type="text/javascript">
-	var returnval = 0;
-	var stylesheet, xmlFile, cache, doc;
-	function init(){
-		// NSCP 7.1+ / Mozilla 1.4.1+ / Safari
-		// Use the standard DOM Level 2 technique, if it is supported
-		if (document.implementation && document.implementation.createDocument) {
-			xmlFile = document.implementation.createDocument("", "", null);
-			stylesheet = document.implementation.createDocument("", "", null);
-			if (xmlFile.load){
-				xmlFile.load("site.xml");
-				stylesheet.load("web/site.xsl");
-			} else {
-				alert("Document could not be loaded by browser.");
-			}
-			xmlFile.addEventListener("load", transform, false);
-			stylesheet.addEventListener("load", transform, false);
-		}
-		//IE 6.0+ solution
-		else if (window.ActiveXObject) {
-			xmlFile = new ActiveXObject("msxml2.DOMDocument.3.0");
-			xmlFile.async = false;
-			xmlFile.load("site.xml");
-			stylesheet = new ActiveXObject("msxml2.FreeThreadedDOMDocument.3.0");
-			stylesheet.async = false;
-			stylesheet.load("web/site.xsl");
-			cache = new ActiveXObject("msxml2.XSLTemplate.3.0");
-			cache.stylesheet = stylesheet;
-			transformData();
-		}
-	}
-	// separate transformation function for IE 6.0+
-	function transformData(){
-		var processor = cache.createProcessor();
-		processor.input = xmlFile;
-		processor.transform();
-		data.innerHTML = processor.output;
-	}
-	// separate transformation function for NSCP 7.1+ and Mozilla 1.4.1+
-	function transform(){
-		returnval+=1;
-		if (returnval==2){
-			var processor = new XSLTProcessor();
-			processor.importStylesheet(stylesheet);
-			doc = processor.transformToDocument(xmlFile);
-			document.getElementById("data").innerHTML = doc.documentElement.innerHTML;
-		}
-	}
-</script>
-</head>
-<body onload="init();">
-<!--[insert static HTML here]-->
-<div id="data"><!-- this is where the transformed data goes --></div>
-</body>
-</html>
diff --git a/tools/eclipse/sites/internal/site.xml b/tools/eclipse/sites/internal/site.xml
deleted file mode 100644
index 9f2642f..0000000
--- a/tools/eclipse/sites/internal/site.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<site>
-   <description url="https://android.corp.google.com/adt/">
-      Update Site for Android Development Toolkit
-   </description>
-   <feature url="features/com.android.ide.eclipse.adt_0.9.0.qualifier.jar" id="com.android.ide.eclipse.adt" version="0.9.0.qualifier">
-      <category name="developer"/>
-   </feature>
-   <feature url="features/com.android.ide.eclipse.ddms_0.9.0.qualifier.jar" id="com.android.ide.eclipse.ddms" version="0.9.0.qualifier">
-      <category name="developer"/>
-   </feature>
-   <feature url="features/com.android.ide.eclipse.tests_0.9.0.qualifier.jar" id="com.android.ide.eclipse.tests" version="0.9.0.qualifier">
-      <category name="test"/>
-   </feature>
-   <category-def name="developer" label="Application Developer Tools">
-      <description>
-         Features that add Android support to Eclipse for application developers.
-      </description>
-   </category-def>
-   <category-def name="test" label="Plugin Developer Tests">
-      <description>
-         Tests for the other Android plugins
-      </description>
-   </category-def>
-</site>
diff --git a/tools/eclipse/sites/internal/web/site.css b/tools/eclipse/sites/internal/web/site.css
deleted file mode 100644
index 62c6f9f..0000000
--- a/tools/eclipse/sites/internal/web/site.css
+++ /dev/null
@@ -1,12 +0,0 @@
-<STYLE type="text/css">
-td.spacer {padding-bottom: 10px; padding-top: 10px;}
-.title { font-family: sans-serif; color: #99AACC;}
-.bodyText { font-family: sans-serif; font-size: 9pt; color:#000000;  }
-.sub-header { font-family: sans-serif; font-style: normal; font-weight: bold; font-size: 9pt; color: white;}
-.log-text {font-family: sans-serif; font-style: normal; font-weight: lighter; font-size: 8pt; color:black;}
-.big-header { font-family: sans-serif; font-style: normal; font-weight: bold; font-size: 9pt; color: white; border-top:10px solid white;}
-.light-row {background:#FFFFFF}
-.dark-row {background:#EEEEFF}
-.header {background:#99AADD}
-#indent {word-wrap : break-word;width :300px;text-indent:10px;}
-</STYLE>
diff --git a/tools/eclipse/sites/internal/web/site.xsl b/tools/eclipse/sites/internal/web/site.xsl
deleted file mode 100644
index a94157d..0000000
--- a/tools/eclipse/sites/internal/web/site.xsl
+++ /dev/null
@@ -1,214 +0,0 @@
-<xsl:stylesheet version = '1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:msxsl="urn:schemas-microsoft-com:xslt">
-<xsl:output method="html" encoding="UTF-8"/>
-<xsl:key name="cat" match="category" use="@name"/>
-<xsl:template match="/">
-<xsl:for-each select="site">
-	<html>
-	<head>
-	<title>update-site</title>
-	<style>@import url("web/site.css");</style>
-	</head>
-	<body>
-	<h1 class="title">update-site</h1>
-	<p class="bodyText"><xsl:value-of select="description"/></p>
-	<table width="100%" border="0" cellspacing="1" cellpadding="2">
-	<xsl:for-each select="category-def">
-		<xsl:sort select="@label" order="ascending" case-order="upper-first"/>
-		<xsl:sort select="@name" order="ascending" case-order="upper-first"/>
-	<xsl:if test="count(key('cat',@name)) != 0">
-			<tr class="header">
-				<td class="sub-header" width="30%">
-					<xsl:value-of select="@name"/>
-				</td>
-				<td class="sub-header" width="70%">
-					<xsl:value-of select="@label"/>
-				</td>
-			</tr>
-			<xsl:for-each select="key('cat',@name)">
-			<xsl:sort select="ancestor::feature//@version" order="ascending"/>
-			<xsl:sort select="ancestor::feature//@id" order="ascending" case-order="upper-first"/>
-			<tr>
-				<xsl:choose>
-				<xsl:when test="(position() mod 2 = 1)">
-					<xsl:attribute name="class">dark-row</xsl:attribute>
-				</xsl:when>
-				<xsl:otherwise>
-					<xsl:attribute name="class">light-row</xsl:attribute>
-				</xsl:otherwise>
-				</xsl:choose>
-				<td class="log-text" id="indent">
-						<xsl:choose>
-						<xsl:when test="ancestor::feature//@label">
-							<a href="{ancestor::feature//@url}"><xsl:value-of select="ancestor::feature//@label"/></a>
-							<br/>
-							<div id="indent">
-							(<xsl:value-of select="ancestor::feature//@id"/> - <xsl:value-of select="ancestor::feature//@version"/>)
-							</div>
-						</xsl:when>
-						<xsl:otherwise>
-						<a href="{ancestor::feature//@url}"><xsl:value-of select="ancestor::feature//@id"/> - <xsl:value-of select="ancestor::feature//@version"/></a>
-						</xsl:otherwise>
-						</xsl:choose>
-						<br />
-				</td>
-				<td>
-					<table>
-						<xsl:if test="ancestor::feature//@os">
-							<tr><td class="log-text" id="indent">Operating Systems:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@os"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@ws">
-							<tr><td class="log-text" id="indent">Windows Systems:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@ws"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@nl">
-							<tr><td class="log-text" id="indent">Languages:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@nl"/></td>
-							</tr>
-						</xsl:if>
-						<xsl:if test="ancestor::feature//@arch">
-							<tr><td class="log-text" id="indent">Architecture:</td>
-							<td class="log-text" id="indent"><xsl:value-of select="ancestor::feature//@arch"/></td>
-							</tr>
-						</xsl:if>
-					</table>
-				</td>
-			</tr>
-			</xsl:for-each>
-			<tr><td class="spacer"><br/></td><td class="spacer"><br/></td></tr>
-		</xsl:if>
-	</xsl:for-each>
-	<xsl:if test="count(feature)  &gt; count(feature/category)">
-	<tr class="header">
-		<td class="sub-header" colspan="2">
-		Uncategorized
-		</td>
-	</tr>
-	</xsl:if>
-	<xsl:choose>
-	<xsl:when test="function-available('msxsl:node-set')">
-	   <xsl:variable name="rtf-nodes">
-		<xsl:for-each select="feature[not(category)]">
-			<xsl:sort select="@id" order="ascending" case-order="upper-first"/>
-			<xsl:sort select="@version" order="ascending" />
-			<xsl:value-of select="."/>
-			<xsl:copy-of select="." />
-		</xsl:for-each>
-	   </xsl:variable>
-	   <xsl:variable name="myNodeSet" select="msxsl:node-set($rtf-nodes)/*"/>
-	<xsl:for-each select="$myNodeSet">
-	<tr>
-		<xsl:choose>
-		<xsl:when test="position() mod 2 = 1">
-		<xsl:attribute name="class">dark-row</xsl:attribute>
-		</xsl:when>
-		<xsl:otherwise>
-		<xsl:attribute name="class">light-row</xsl:attribute>
-		</xsl:otherwise>
-		</xsl:choose>
-		<td class="log-text" id="indent">
-			<xsl:choose>
-			<xsl:when test="@label">
-				<a href="{@url}"><xsl:value-of select="@label"/></a>
-				<br />
-				<div id="indent">
-				(<xsl:value-of select="@id"/> - <xsl:value-of select="@version"/>)
-				</div>
-			</xsl:when>
-			<xsl:otherwise>
-				<a href="{@url}"><xsl:value-of select="@id"/> - <xsl:value-of select="@version"/></a>
-			</xsl:otherwise>
-			</xsl:choose>
-			<br /><br />
-		</td>
-		<td>
-			<table>
-				<xsl:if test="@os">
-					<tr><td class="log-text" id="indent">Operating Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@os"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@ws">
-					<tr><td class="log-text" id="indent">Windows Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@ws"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@nl">
-					<tr><td class="log-text" id="indent">Languages:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@nl"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@arch">
-					<tr><td class="log-text" id="indent">Architecture:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@arch"/></td>
-					</tr>
-				</xsl:if>
-			</table>
-		</td>
-	</tr>
-	</xsl:for-each>
-	</xsl:when>
-	<xsl:otherwise>
-	<xsl:for-each select="feature[not(category)]">
-	<xsl:sort select="@id" order="ascending" case-order="upper-first"/>
-	<xsl:sort select="@version" order="ascending" />
-	<tr>
-		<xsl:choose>
-		<xsl:when test="count(preceding-sibling::feature[not(category)]) mod 2 = 1">
-		<xsl:attribute name="class">dark-row</xsl:attribute>
-		</xsl:when>
-		<xsl:otherwise>
-		<xsl:attribute name="class">light-row</xsl:attribute>
-		</xsl:otherwise>
-		</xsl:choose>
-		<td class="log-text" id="indent">
-			<xsl:choose>
-			<xsl:when test="@label">
-				<a href="{@url}"><xsl:value-of select="@label"/></a>
-				<br />
-				<div id="indent">
-				(<xsl:value-of select="@id"/> - <xsl:value-of select="@version"/>)
-				</div>
-			</xsl:when>
-			<xsl:otherwise>
-				<a href="{@url}"><xsl:value-of select="@id"/> - <xsl:value-of select="@version"/></a>
-			</xsl:otherwise>
-			</xsl:choose>
-			<br /><br />
-		</td>
-		<td>
-			<table>
-				<xsl:if test="@os">
-					<tr><td class="log-text" id="indent">Operating Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@os"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@ws">
-					<tr><td class="log-text" id="indent">Windows Systems:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@ws"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@nl">
-					<tr><td class="log-text" id="indent">Languages:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@nl"/></td>
-					</tr>
-				</xsl:if>
-				<xsl:if test="@arch">
-					<tr><td class="log-text" id="indent">Architecture:</td>
-					<td class="log-text" id="indent"><xsl:value-of select="@arch"/></td>
-					</tr>
-				</xsl:if>
-			</table>
-		</td>
-	</tr>
-	</xsl:for-each>
-	</xsl:otherwise>
-	</xsl:choose>
-	</table>
-	</body>
-	</html>
-</xsl:for-each>
-</xsl:template>
-</xsl:stylesheet>
diff --git a/tools/eclipse/source_package_readme.txt b/tools/eclipse/source_package_readme.txt
deleted file mode 100644
index 456bae7..0000000
--- a/tools/eclipse/source_package_readme.txt
+++ /dev/null
@@ -1,49 +0,0 @@
-HOW TO PACKAGE THE SOURCE OF THE PLUGINS FOR RELEASE.
-
-Note: this is only useful before we move to the public source repository, after which this will
-be obsolete.
-
-The source archive must contains:
-1/ Source of the EPL plugins that are released.
-2/ Any closed source dependencies that were created by Google.
-3/ The readme file explaining how to build the plugins.
-
-
-1/ PLUGIN SOURCE
-
-The Plugins that are currently released and that are EPL are:
-- Android Developer Tools => com.android.ide.eclipse.adt
-- Common                  => com.android.ide.eclipse.common
-- Android Editors         => com.android.ide.eclipse.editors
-
-All three plugins are located in
-    device/tools/eclipse/plugins/
-
-Before packing them up, it is important to:
-- remove the bin directory if it exists
-- remove any symlinks to jar files from the top level folder of each plugin
-
-2/ PLUGIN DEPENDENCIES
-
-The plugin dependencies are jar files embedded in some of the plugins. Some of those jar files
-are android libraries for which the source code is not yet being released (They will be released
-under the APL).
-
-Those libraries are not part of the SDK, and need to be taken from a engineering build.
-They will be located in
-    device/out/host/<platform>/framework/
-
-The libraries to copy are:
- - layoutlib_api.jar
- - layoutlib_utils.jar
- - ninepatch.jar
-
-They should be placed in a "libs" folder in the source archive.
-
-3/ README
-
-In the source archive, at the top level, needs to be present a file explaining how to compile
-the plugins.
-
-This file is located at:
-    device/tools/eclipse/plugins/README.txt
\ No newline at end of file
diff --git a/tools/eventanalyzer/.classpath b/tools/eventanalyzer/.classpath
deleted file mode 100644
index b0326c8..0000000
--- a/tools/eventanalyzer/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmlib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/eventanalyzer/.project b/tools/eventanalyzer/.project
deleted file mode 100644
index 2862978..0000000
--- a/tools/eventanalyzer/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>eventanalyzer</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/eventanalyzer/Android.mk b/tools/eventanalyzer/Android.mk
deleted file mode 100644
index 18e730e..0000000
--- a/tools/eventanalyzer/Android.mk
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-EVENTANALUZER_LOCAL_DIR := $(call my-dir)
-include $(EVENTANALUZER_LOCAL_DIR)/etc/Android.mk
-include $(EVENTANALUZER_LOCAL_DIR)/src/Android.mk
diff --git a/tools/eventanalyzer/etc/Android.mk b/tools/eventanalyzer/etc/Android.mk
deleted file mode 100644
index e7703b4..0000000
--- a/tools/eventanalyzer/etc/Android.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := eventanalyzer
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/eventanalyzer/etc/eventanalyzer b/tools/eventanalyzer/etc/eventanalyzer
deleted file mode 100755
index d6c7895..0000000
--- a/tools/eventanalyzer/etc/eventanalyzer
+++ /dev/null
@@ -1,73 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=eventanalyzer.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-# Mac OS X needs an additional arg, or you get an "illegal thread" complaint.
-if [ `uname` = "Darwin" ]; then
-    os_opts="-XstartOnFirstThread"
-else
-    os_opts=
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Xmx128M $os_opts -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -jar "$jarpath" "$@"
diff --git a/tools/eventanalyzer/etc/manifest.txt b/tools/eventanalyzer/etc/manifest.txt
deleted file mode 100644
index 6d99ea1..0000000
--- a/tools/eventanalyzer/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.eventanalyzer.EventAnalyzer
diff --git a/tools/eventanalyzer/src/Android.mk b/tools/eventanalyzer/src/Android.mk
deleted file mode 100644
index e65c61f..0000000
--- a/tools/eventanalyzer/src/Android.mk
+++ /dev/null
@@ -1,27 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	ddmlib
-LOCAL_MODULE := eventanalyzer
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java b/tools/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java
deleted file mode 100644
index c520784..0000000
--- a/tools/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java
+++ /dev/null
@@ -1,484 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.eventanalyzer;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.Log.ILogOutput;
-import com.android.ddmlib.Log.LogLevel;
-import com.android.ddmlib.log.EventContainer;
-import com.android.ddmlib.log.EventLogParser;
-import com.android.ddmlib.log.InvalidTypeException;
-import com.android.ddmlib.log.LogReceiver;
-import com.android.ddmlib.log.LogReceiver.ILogListener;
-import com.android.ddmlib.log.LogReceiver.LogEntry;
-
-import java.io.BufferedReader;
-import java.io.BufferedWriter;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileWriter;
-import java.io.FilenameFilter;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Set;
-import java.util.TreeMap;
-
-/**
- * Connects to a device using ddmlib and analyze its event log. 
- */
-public class EventAnalyzer implements ILogListener {
-    
-    private final static int TAG_ACTIVITY_LAUNCH_TIME = 30009;
-    private final static char DATA_SEPARATOR = ',';
-
-    private final static String CVS_EXT = ".csv";
-    private final static String TAG_FILE_EXT = ".tag"; //$NON-NLS-1$
-    
-    private EventLogParser mParser;
-    private TreeMap<String, ArrayList<Long>> mLaunchMap = new TreeMap<String, ArrayList<Long>>(); 
-    
-    String mInputTextFile = null;
-    String mInputBinaryFile = null;
-    String mInputDevice = null;
-    String mInputFolder = null;
-    String mAlternateTagFile = null;
-    String mOutputFile = null;
-
-    public static void main(String[] args) {
-        new EventAnalyzer().run(args);
-    }
-    
-    private void run(String[] args) {
-        if (args.length == 0) {
-            printUsageAndQuit();
-        }
-        
-        int index = 0;
-        do {
-            String argument = args[index++];
-
-            if ("-s".equals(argument)) {
-                checkInputValidity("-s");
-                
-                if (index == args.length) {
-                    printUsageAndQuit();
-                }
-                
-                mInputDevice = args[index++];
-            } else if ("-fb".equals(argument)) {
-                checkInputValidity("-fb");
-                
-                if (index == args.length) {
-                    printUsageAndQuit();
-                }
-                
-                mInputBinaryFile = args[index++];
-            } else if ("-ft".equals(argument)) {
-                checkInputValidity("-ft");
-                
-                if (index == args.length) {
-                    printUsageAndQuit();
-                }
-                
-                mInputTextFile = args[index++];
-            } else if ("-F".equals(argument)) {
-                checkInputValidity("-F");
-                
-                if (index == args.length) {
-                    printUsageAndQuit();
-                }
-                
-                mInputFolder = args[index++];
-            } else if ("-t".equals(argument)) {
-                if (index == args.length) {
-                    printUsageAndQuit();
-                }
-
-                mAlternateTagFile = args[index++];
-            } else {
-                // get the filepath and break.
-                mOutputFile = argument;
-
-                // should not be any other device.
-                if (index < args.length) {
-                    printAndExit("Too many arguments!", false /* terminate */);
-                }
-            }
-        } while (index < args.length);
-
-        if ((mInputTextFile == null && mInputBinaryFile == null && mInputFolder == null &&
-                mInputDevice == null)) {
-            printUsageAndQuit();
-        }
-
-        File outputParent = new File(mOutputFile).getParentFile();
-        if (outputParent == null || outputParent.isDirectory() == false) {
-            printAndExit(String.format("%1$s is not a valid ouput file", mOutputFile),
-                    false /* terminate */);
-        }
-
-        // redirect the log output to /dev/null
-        Log.setLogOutput(new ILogOutput() {
-            public void printAndPromptLog(LogLevel logLevel, String tag, String message) {
-                // pass
-            }
-
-            public void printLog(LogLevel logLevel, String tag, String message) {
-                // pass
-            }
-        });
-
-        try {
-            if (mInputBinaryFile != null) {
-                parseBinaryLogFile();
-            } else if (mInputTextFile != null) {
-                parseTextLogFile(mInputTextFile);
-            } else if (mInputFolder != null) {
-                parseFolder(mInputFolder);
-            } else if (mInputDevice != null) {
-                parseLogFromDevice();
-            }
-            
-            // analyze the data gathered by the parser methods
-            analyzeData();
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-    
-    /**
-     * Parses a binary event log file located at {@link #mInputBinaryFile}.
-     * @throws IOException 
-     */
-    private void parseBinaryLogFile() throws IOException {
-        mParser = new EventLogParser();
-
-        String tagFile = mInputBinaryFile + TAG_FILE_EXT;
-        if (mParser.init(tagFile) == false) {
-            // if we have an alternate location
-            if (mAlternateTagFile != null) {
-                if (mParser.init(mAlternateTagFile) == false) {
-                    printAndExit("Failed to get event tags from " + mAlternateTagFile,
-                            false /* terminate*/);
-                }
-            } else {
-                printAndExit("Failed to get event tags from " + tagFile, false /* terminate*/);
-            }
-        }
-        
-        LogReceiver receiver = new LogReceiver(this);
-
-        byte[] buffer = new byte[256];
-        
-        FileInputStream fis = new FileInputStream(mInputBinaryFile);
-        
-        int count;
-        while ((count = fis.read(buffer)) != -1) {
-            receiver.parseNewData(buffer, 0, count);
-        }
-    }
-
-    /**
-     * Parse a text Log file.
-     * @param filePath the location of the file.
-     * @throws IOException
-     */
-    private void parseTextLogFile(String filePath) throws IOException {
-        mParser = new EventLogParser();
-
-        String tagFile = filePath + TAG_FILE_EXT;
-        if (mParser.init(tagFile) == false) {
-            // if we have an alternate location
-            if (mAlternateTagFile != null) {
-                if (mParser.init(mAlternateTagFile) == false) {
-                    printAndExit("Failed to get event tags from " + mAlternateTagFile,
-                            false /* terminate*/);
-                }
-            } else {
-                printAndExit("Failed to get event tags from " + tagFile, false /* terminate*/);
-            }
-        }
-
-        // read the lines from the file and process them.
-        BufferedReader reader = new BufferedReader(
-                new InputStreamReader(new FileInputStream(filePath)));
-
-        String line;
-        while ((line = reader.readLine()) != null) {
-            processEvent(mParser.parse(line));
-        }
-    }
-
-    private void parseLogFromDevice() throws IOException {
-        // init the lib
-        AndroidDebugBridge.init(false /* debugger support */);
-        
-        try {
-            AndroidDebugBridge bridge = AndroidDebugBridge.createBridge();
-            
-            // we can't just ask for the device list right away, as the internal thread getting
-            // them from ADB may not be done getting the first list.
-            // Since we don't really want getDevices() to be blocking, we wait here manually.
-            int count = 0;
-            while (bridge.hasInitialDeviceList() == false) {
-                try {
-                    Thread.sleep(100);
-                    count++;
-                } catch (InterruptedException e) {
-                    // pass
-                }
-                
-                // let's not wait > 10 sec.
-                if (count > 100) {
-                    printAndExit("Timeout getting device list!", true /* terminate*/);
-                }
-            }
-
-            // now get the devices
-            Device[] devices = bridge.getDevices();
-            
-            for (Device device : devices) {
-                if (device.getSerialNumber().equals(mInputDevice)) {
-                    grabLogFrom(device);
-                    return;
-                }
-            }
-            
-            System.err.println("Could not find " + mInputDevice);
-        } finally {
-            AndroidDebugBridge.terminate();
-        }
-    }
-    
-    /**
-     * Parses the log files located in the folder, and its sub-folders.
-     * @param folderPath the path to the folder.
-     */
-    private void parseFolder(String folderPath) {
-        File f = new File(folderPath);
-        if (f.isDirectory() == false) {
-            printAndExit(String.format("%1$s is not a valid folder", folderPath),
-                    false /* terminate */);
-        }
-        
-        String[] files = f.list(new FilenameFilter() {
-            public boolean accept(File dir, String name) {
-                name = name.toLowerCase();
-                return name.endsWith(".tag") == false;
-            }
-        });
-        
-        for (String file : files) {
-            try {
-                f = new File(folderPath + File.separator + file);
-                if (f.isDirectory()) {
-                    parseFolder(f.getAbsolutePath());
-                } else {
-                    parseTextLogFile(f.getAbsolutePath());
-                }
-            } catch (IOException e) {
-                // ignore this file.
-            }
-        }
-    }
-
-    private void grabLogFrom(Device device) throws IOException {
-        mParser = new EventLogParser();
-        if (mParser.init(device) == false) {
-            printAndExit("Failed to get event-log-tags from " + device.getSerialNumber(),
-                    true /* terminate*/);
-        }
-        
-        LogReceiver receiver = new LogReceiver(this);
-
-        device.runEventLogService(receiver);
-    }
-    
-    /**
-     * Analyze the data and writes it to {@link #mOutputFile}
-     * @throws IOException
-     */
-    private void analyzeData() throws IOException {
-        BufferedWriter writer = null;
-        try {
-            // make sure the file name has the proper extension.
-            if (mOutputFile.toLowerCase().endsWith(CVS_EXT) == false) {
-                mOutputFile = mOutputFile + CVS_EXT;
-            }
-
-            writer = new BufferedWriter(new FileWriter(mOutputFile));
-            StringBuilder builder = new StringBuilder();
-            
-            // write the list of launch start. One column per activity.
-            Set<String> activities = mLaunchMap.keySet();
-            
-            // write the column headers.
-            for (String activity : activities) {
-                builder.append(activity).append(DATA_SEPARATOR);
-            }
-            writer.write(builder.append('\n').toString());
-            
-            // loop on the activities and write their values.
-            boolean moreValues = true;
-            int index = 0;
-            while (moreValues) {
-                moreValues = false;
-                builder.setLength(0);
-                
-                for (String activity : activities) {
-                    // get the activity list.
-                    ArrayList<Long> list = mLaunchMap.get(activity);
-                    if (index < list.size()) {
-                        moreValues = true;
-                        builder.append(list.get(index).longValue()).append(DATA_SEPARATOR);
-                    } else {
-                        builder.append(DATA_SEPARATOR);
-                    }
-                }
-                
-                // write the line.
-                if (moreValues) {
-                    writer.write(builder.append('\n').toString());
-                }
-                
-                index++;
-            }
-            
-            // write per-activity stats.
-            for (String activity : activities) {
-                builder.setLength(0);
-                builder.append(activity).append(DATA_SEPARATOR);
-    
-                // get the activity list.
-                ArrayList<Long> list = mLaunchMap.get(activity);
-                
-                // sort the list
-                Collections.sort(list);
-                
-                // write min/max
-                builder.append(list.get(0).longValue()).append(DATA_SEPARATOR);
-                builder.append(list.get(list.size()-1).longValue()).append(DATA_SEPARATOR);
-    
-                // write median value
-                builder.append(list.get(list.size()/2).longValue()).append(DATA_SEPARATOR);
-                
-                // compute and write average
-                long total = 0; // despite being encoded on a long, the values are low enough that
-                                // a Long should be enough to compute the total
-                for (Long value : list) {
-                    total += value.longValue();
-                }
-                builder.append(total / list.size()).append(DATA_SEPARATOR);
-                
-                // finally write the data.
-                writer.write(builder.append('\n').toString());
-            }
-        } finally {
-            writer.close();
-        }
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ddmlib.log.LogReceiver.ILogListener#newData(byte[], int, int)
-     */
-    public void newData(byte[] data, int offset, int length) {
-        // we ignore raw data. New entries are processed in #newEntry(LogEntry)
-    }
-
-    /*
-     * (non-Javadoc)
-     * @see com.android.ddmlib.log.LogReceiver.ILogListener#newEntry(com.android.ddmlib.log.LogReceiver.LogEntry)
-     */
-    public void newEntry(LogEntry entry) {
-        // parse and process the entry data.
-        processEvent(mParser.parse(entry));
-    }
-    
-    private void processEvent(EventContainer event) {
-        if (event != null && event.mTag == TAG_ACTIVITY_LAUNCH_TIME) {
-            // get the activity name
-            try {
-                String name = event.getValueAsString(0);
-
-                // get the launch time
-                Object value = event.getValue(1);
-                if (value instanceof Long) {
-                    addLaunchTime(name, (Long)value);
-                }
-
-            } catch (InvalidTypeException e) {
-                // Couldn't get the name as a string...
-                // Ignore this event.
-            }
-        }
-    }
-
-    private void addLaunchTime(String name, Long value) {
-        ArrayList<Long> list = mLaunchMap.get(name);
-        
-        if (list == null) {
-            list = new ArrayList<Long>();
-            mLaunchMap.put(name, list);
-        }
-        
-        list.add(value);
-    }
-
-    private void checkInputValidity(String option) {
-        if (mInputTextFile != null || mInputBinaryFile != null) {
-            printAndExit(String.format("ERROR: %1$s cannot be used with an input file.", option),
-                    false /* terminate */);
-        } else if (mInputFolder != null) {
-            printAndExit(String.format("ERROR: %1$s cannot be used with an input file.", option),
-                    false /* terminate */);
-        } else if (mInputDevice != null) {
-            printAndExit(String.format("ERROR: %1$s cannot be used with an input device serial number.",
-                    option), false /* terminate */);
-        }
-    }
-
-    private static void printUsageAndQuit() {
-        // 80 cols marker:  01234567890123456789012345678901234567890123456789012345678901234567890123456789
-        System.out.println("Usage:");
-        System.out.println("   eventanalyzer [-t <TAG_FILE>] <SOURCE> <OUTPUT>");
-        System.out.println("");
-        System.out.println("Possible sources:");
-        System.out.println("   -fb <file>    The path to a binary event log, gathered by dumpeventlog");
-        System.out.println("   -ft <file>    The path to a text event log, gathered by adb logcat -b events");
-        System.out.println("   -F <folder>   The path to a folder containing multiple text log files.");
-        System.out.println("   -s <serial>   The serial number of the Device to grab the event log from.");
-        System.out.println("Options:");
-        System.out.println("   -t <file>     The path to tag file to use in case the one associated with");
-        System.out.println("                 the source is missing");
-        
-        System.exit(1);
-    }
-    
-    
-    private static void printAndExit(String message, boolean terminate) {
-        System.out.println(message);
-        if (terminate) {
-            AndroidDebugBridge.terminate();
-        }
-        System.exit(1);
-    }
-}
diff --git a/tools/findunused/find_unused_resources.rb b/tools/findunused/find_unused_resources.rb
deleted file mode 100755
index 515b266..0000000
--- a/tools/findunused/find_unused_resources.rb
+++ /dev/null
@@ -1,235 +0,0 @@
-#!/usr/bin/ruby
-#
-# Find unused resources in all the apps found recursively under the current directory
-# Usage:
-#   find_unused_resources.rb [-html]
-#
-# If -html is specified, the output will be HTML, otherwise it will be plain text
-#
-# Author: cbeust@google.com
-
-require 'find'
-
-debug = false
-
-@@stringIdPattern = Regexp.new("name=\"([@_a-zA-Z0-9 ]*)\"")
-@@layoutIdPattern = Regexp.new("android:id=\".*id/([_a-zA-Z0-9]*)\"")
-
-@@stringXmlPatterns = [
-  Regexp.new("@string/([_a-zA-Z0-9]*)"),
-  Regexp.new("@array/([_a-zA-Z0-9]*)"),
-]
-
-@@javaIdPatterns = [
-  Regexp.new("R.id.([_a-zA-Z0-9]+)"),
-  Regexp.new("R.string.([_a-zA-Z0-9]+)"),
-  Regexp.new("R.array.([_a-zA-Z0-9]+)"),
-  Regexp.new("R.color.([_a-zA-Z0-9]+)"),
-  Regexp.new("R.configVarying.([_a-zA-Z0-9]+)"),
-  Regexp.new("R.dimen.([_a-zA-Z0-9]+)"),
-]
-
-
-@@appDir = "partner/google/apps/Gmail"
-
-def findResDirectories(root)
-  result = Array.new
-  Find.find(root) do |path|
-    if FileTest.directory?(path)
-      if File.basename(path) == "res"
-        result << path
-      else
-        next
-      end
-    end
-  end
-  result
-end
-
-class UnusedResources
-  attr_accessor :appDir, :unusedLayoutIds, :unusedStringIds
-end
-
-class FilePosition
-  attr_accessor :file, :lineNumber
-
-  def initialize(f, ln)
-    @file = f
-    @lineNumber = ln
-  end
-
-  def to_s
-    "#{file}:#{lineNumber}"
-  end
-
-  def <=>(other)
-    if @file == other.file
-      @lineNumber - other.lineNumber
-    else
-      @file <=> other.file
-    end
-  end
-end
-
-
-def findAllOccurrences(re, string)
-  result = Array.new
-
-  s = string
-  matchData = re.match(s)
-  while (matchData)
-    result << matchData[1].to_s
-    s = s[matchData.end(1) .. -1]
-    matchData = re.match(s)
-  end
-
-  result
-end
-
-@@globalJavaIdUses = Hash.new
-
-def recordJavaUses(glob)
-  Dir.glob(glob).each { |filename|
-    File.open(filename) { |file|
-      file.each { |line|
-	@@javaIdPatterns.each { |re|
-          findAllOccurrences(re, line).each { |id|
-            @@globalJavaIdUses[id] = FilePosition.new(filename, file.lineno)
-	  }
-        }
-      }
-    }
-  }
-end
-
-def findUnusedResources(dir)
-  javaIdUses = Hash.new
-  layouts = Hash.new
-  strings = Hash.new
-  xmlIdUses = Hash.new
-
-  Dir.glob("#{dir}/res/**/*.xml").each { |filename|
-    if ! (filename =~ /attrs.xml$/)
-      File.open(filename) { |file|
-        file.each { |line|
-          findAllOccurrences(@@stringIdPattern, line).each {|id|
-            strings[id] = FilePosition.new(filename, file.lineno)
-          }
-          findAllOccurrences(@@layoutIdPattern, line).each {|id|
-            layouts[id] = FilePosition.new(filename, file.lineno)
-          }
-          @@stringXmlPatterns.each { |re|
-            findAllOccurrences(re, line).each {|id|
-              xmlIdUses[id] = FilePosition.new(filename, file.lineno)
-            }
-          }
-        }
-      }
-    end
-  }
- 
-  Dir.glob("#{dir}/AndroidManifest.xml").each { |filename|
-    File.open(filename) { |file|
-      file.each { |line|
-        @@stringXmlPatterns.each { |re|
-          findAllOccurrences(re, line).each {|id|
-            xmlIdUses[id] = FilePosition.new(filename, file.lineno)
-          }
-        }
-      }
-    }
-  }
-
-  recordJavaUses("#{dir}/src/**/*.java")
-
-  @@globalJavaIdUses.each_pair { |id, file|
-    layouts.delete(id)
-    strings.delete(id)
-  }
-
-  javaIdUses.each_pair { |id, file|
-    layouts.delete(id)
-    strings.delete(id)
-  }
-
-  xmlIdUses.each_pair { |id, file|
-    layouts.delete(id)
-    strings.delete(id)
-  }
-
-  result = UnusedResources.new
-  result.appDir = dir
-  result.unusedLayoutIds = layouts
-  result.unusedStringIds = strings
-
-  result
-end
-
-def findApps(dir)
-  result = Array.new
-  Dir.glob("#{dir}/**/res").each { |filename|
-    a = filename.split("/")
-    result << a.slice(0, a.size-1).join("/")
-  }
-  result
-end
-
-def displayText(result)
-  result.each { |unusedResources|
-    puts "=== #{unusedResources.appDir}"
-
-    puts "----- Unused layout ids"
-    unusedResources.unusedLayoutIds.sort { |id, file| id[1] <=> file[1] }.each {|f|
-      puts "    #{f[0]} #{f[1]}"
-    }
-
- 
-    puts "----- Unused string ids"
-    unusedResources.unusedStringIds.sort { |id, file| id[1] <=> file[1] }.each {|f|
-      puts "    #{f[0]} #{f[1]}"
-    }
- 
-  }
-end
-
-def displayHtmlUnused(unusedResourceIds, title)
-
-  puts "<h3>#{title}</h3>"
-  puts "<table border='1'>"
-  unusedResourceIds.sort { |id, file| id[1] <=> file[1] }.each {|f|
-    puts "<tr><td><b>#{f[0]}</b></td> <td>#{f[1]}</td></tr>"
-  }
-  puts "</table>"
-end
-
-def displayHtml(result)
-  title = "Unused resources as of #{Time.now.localtime}"
-  puts "<html><header><title>#{title}</title></header><body>"
-
-  puts "<h1><p align=\"center\">#{title}</p></h1>"
-  result.each { |unusedResources|
-    puts "<h2>#{unusedResources.appDir}</h2>"
-    displayHtmlUnused(unusedResources.unusedLayoutIds, "Unused layout ids")
-    displayHtmlUnused(unusedResources.unusedStringIds, "Unused other ids")
-  }
-  puts "</body>"
-end
-
-result = Array.new
-
-recordJavaUses("java/android/**/*.java")
-
-if debug
-  result << findUnusedResources("apps/Browser")
-else 
-  findApps(".").each { |appDir|
-    result << findUnusedResources(appDir)
-  }
-end
-
-if ARGV[0] == "-html"
-  displayHtml result
-else
-  displayText result
-end
-
diff --git a/tools/findunused/findunusedresources b/tools/findunused/findunusedresources
deleted file mode 100755
index 748139a..0000000
--- a/tools/findunused/findunusedresources
+++ /dev/null
@@ -1,74 +0,0 @@
-#!/bin/sh
-
-if [ "$1" == "-h" ]
-then
-    cat <<- EOH
-		    Usage: $0 [-p] [folder]
-		      -p option prints out unused resources, otherwise a total count is printed
-		      folder option causes only that app folder to be scanned, default is to scan all folders onder apps/
-		EOH
-    exit
-fi
-
-showall=no
-if [ "$1" == "-p" ]
-then
-    showall=yes
-    shift
-fi
-
-apps=$1
-if [ "$apps" == "" ]
-then
-    apps=$ANDROID_BUILD_TOP/packages/apps/*
-fi
-
-for app in $apps
-do
-    echo '-----------------------------------------------------------'
-    if [ -d $app/res ]
-    then
-        appname=$(basename $app)
-        resources=
-        for res in $(echo $app/res/*)
-        do
-            resources="$resources $(echo $res | grep -v '\-mcc\|[a-z]*-[a-z][a-z]$\|[a-z]*-[a-z][a-z]-.*')"
-        done
-        sources=$app/src
-        if [ -d $app/tests ]
-        then
-            sources="$sources $app/tests"
-        fi
-        if [ -d $app/samples ]
-        then
-            sources="$sources $app/samples"
-        fi
-
-        # find the R.java file that contains all the generated resource identifiers
-        rDotJava=$(find out/target/common/obj/APPS/${appname}_intermediates/ -name R.java)
-
-        # Simplistically process the content of the file to get the names of all the constants,
-        # and try to find a reference to each constant.
-        for i in $(cat $rDotJava | grep "\w*=0x\d*" | sed 's/ *public static final int //' | sed 's/=0x.*//')
-        do
-            # Since periods in the names get translated to underscores in R.java, and you can actually
-            # refer to such constants from java by using an underscore instead of a period, we also
-            # replace all underscores with a pattern that will match periods and underscores.
-            p=$(echo $i | sed 's/_/[\\._]/g')
-            echo $i $(grep -Rw R\\..*\\.$i\\\|@style/$p\\\|@drawable/$p\\\|@anim/$p\\\|@color/$p\\\|@xml/$p\\\|@layout/$p\\\|@menu/$p\\\|@+id/$p\\\|@array/$p\\\|@string/$p\\\|@dimen/$p $resources $sources $app/AndroidManifest.xml | wc -l)
-        done | grep " 0$" | {
-            # this block gets as its input a list of constants which no references were found, one per line
-            if [ "$showall" == "yes" ]
-            then
-                echo $app
-                cat
-            else
-                count=$(wc -l)
-                if [ "$count" != "0" ]
-                then
-                    echo $app: $count unused resources
-                fi
-            fi
-        }
-    fi
-done
diff --git a/tools/findunused/findunusedstrings b/tools/findunused/findunusedstrings
deleted file mode 100755
index a54b060..0000000
--- a/tools/findunused/findunusedstrings
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/bash
-
-if [ "$1" == "-h" ]
-then
-    cat <<- EOH
-		    Usage: $0 [-p] [folder]
-		      -p option prints out unused strings, otherwise a total count is printed
-		      folder option causes only that app folder to be scanned, default is to scan all folders onder apps/
-		EOH
-    exit
-fi
-
-showall=no
-if [ "$1" == "-p" ]
-then
-    showall=yes
-    shift
-fi
-
-apps=$1
-if [ "$apps" == "" ]
-then
-    apps=$ANDROID_BUILD_TOP/packages/apps/*
-fi
-
-for app in $apps
-do
-    if [ -d $app/res ]
-    then
-        pushd $app > /dev/null
-        for i in $(grep -R "\(string\|plurals\) name=" res | sed 's/.*<\(string\|plurals\) name="//'|sed 's/".*$//'|sort -u)
-        do
-            echo $i $(grep -Rw R.plurals.$i\\\|R.string.$i\\\|@string/$i .|wc -l)
-        done | grep ' 0$' | {
-            if [ "$showall" == "yes" ]
-            then
-                echo $app
-                cat
-            else
-                count=$(wc -l)
-                if [ "$count" != "0" ]
-                then
-                    echo $app: $count unused strings
-                fi
-            fi
-        }
-        popd $app > /dev/null
-    fi
-done
diff --git a/tools/hierarchyviewer/Android.mk b/tools/hierarchyviewer/Android.mk
deleted file mode 100644
index 110e2ed..0000000
--- a/tools/hierarchyviewer/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-HIERARCHYVIEWER_LOCAL_DIR := $(call my-dir)
-include $(HIERARCHYVIEWER_LOCAL_DIR)/etc/Android.mk
-include $(HIERARCHYVIEWER_LOCAL_DIR)/src/Android.mk
diff --git a/tools/hierarchyviewer/MODULE_LICENSE_APACHE2 b/tools/hierarchyviewer/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/tools/hierarchyviewer/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/tools/hierarchyviewer/etc/Android.mk b/tools/hierarchyviewer/etc/Android.mk
deleted file mode 100644
index 2794a7f..0000000
--- a/tools/hierarchyviewer/etc/Android.mk
+++ /dev/null
@@ -1,20 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := hierarchyviewer
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/hierarchyviewer/etc/hierarchyviewer b/tools/hierarchyviewer/etc/hierarchyviewer
deleted file mode 100755
index 4244434..0000000
--- a/tools/hierarchyviewer/etc/hierarchyviewer
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/bin/sh
-# Copyright 2008, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=hierarchyviewer.jar
-frameworkdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Xmx512M -Djava.ext.dirs="$frameworkdir" -Dhierarchyviewer.adb="$progdir" -jar "$jarpath" "$@"
diff --git a/tools/hierarchyviewer/etc/hierarchyviewer.bat b/tools/hierarchyviewer/etc/hierarchyviewer.bat
deleted file mode 100755
index 67e4f80..0000000
--- a/tools/hierarchyviewer/etc/hierarchyviewer.bat
+++ /dev/null
@@ -1,41 +0,0 @@
-@echo off
-rem Copyright (C) 2008 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Change current directory to where ddms is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=hierarchyviewer.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-
-:JarFileOk
-
-set jarpath=%frameworkdir%%jarfile%
-
-call java -Xmx512m -Djava.ext.dirs=%frameworkdir% -Dhierarchyviewer.adb= -jar %jarpath% %*
diff --git a/tools/hierarchyviewer/etc/manifest.txt b/tools/hierarchyviewer/etc/manifest.txt
deleted file mode 100644
index f7ddfa9..0000000
--- a/tools/hierarchyviewer/etc/manifest.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-Main-Class: com.android.hierarchyviewer.HierarchyViewer
-Class-Path: ddmlib.jar swing-worker-1.1.jar org-openide-util.jar org-netbeans-api-visual.jar
diff --git a/tools/hierarchyviewer/src/Android.mk b/tools/hierarchyviewer/src/Android.mk
deleted file mode 100644
index 0bc1f1e..0000000
--- a/tools/hierarchyviewer/src/Android.mk
+++ /dev/null
@@ -1,30 +0,0 @@
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	ddmlib \
-	swing-worker-1.1 \
-	org-openide-util \
-	org-netbeans-api-visual
-LOCAL_MODULE := hierarchyviewer
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/HierarchyViewer.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/HierarchyViewer.java
deleted file mode 100644
index 59ce67f..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/HierarchyViewer.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer;
-
-import com.android.hierarchyviewer.ui.Workspace;
-import com.android.hierarchyviewer.device.DeviceBridge;
-
-import javax.swing.SwingUtilities;
-import javax.swing.UIManager;
-import javax.swing.UnsupportedLookAndFeelException;
-
-public class HierarchyViewer {
-    private static final CharSequence OS_WINDOWS = "Windows";
-    private static final CharSequence OS_MACOSX = "Mac OS X";
-
-    private static void initUserInterface() {
-        System.setProperty("apple.laf.useScreenMenuBar", "true");
-        System.setProperty("apple.awt.brushMetalLook", "true");
-        System.setProperty("com.apple.mrj.application.apple.menu.about.name", "HierarchyViewer");
-
-        final String os = System.getProperty("os.name");
-
-        try {
-            if (os.contains(OS_WINDOWS) || os.contains(OS_MACOSX)) {
-                UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
-            } else {
-                UIManager.setLookAndFeel(UIManager.getCrossPlatformLookAndFeelClassName());                
-            }
-        } catch (ClassNotFoundException e) {
-            e.printStackTrace();
-        } catch (InstantiationException e) {
-            e.printStackTrace();
-        } catch (IllegalAccessException e) {
-            e.printStackTrace();
-        } catch (UnsupportedLookAndFeelException e) {
-            e.printStackTrace();
-        }
-    }
-
-    public static void main(String[] args) {
-        initUserInterface();
-        DeviceBridge.initDebugBridge();
-
-        SwingUtilities.invokeLater(new Runnable() {
-            public void run() {
-                Workspace workspace = new Workspace();
-                workspace.setDefaultCloseOperation(Workspace.EXIT_ON_CLOSE);
-                workspace.setLocationRelativeTo(null);
-                workspace.setVisible(true);
-            }
-        });
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Configuration.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Configuration.java
deleted file mode 100644
index 090730f..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Configuration.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.device;
-
-public class Configuration {
-    public static final int DEFAULT_SERVER_PORT = 4939;
-
-    // These codes must match the auto-generated codes in IWindowManager.java
-    // See IWindowManager.aidl as well
-    public static final int SERVICE_CODE_START_SERVER = 1;
-    public static final int SERVICE_CODE_STOP_SERVER = 2;
-    public static final int SERVICE_CODE_IS_SERVER_RUNNING = 3;
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/DeviceBridge.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/DeviceBridge.java
deleted file mode 100644
index 850a238..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/DeviceBridge.java
+++ /dev/null
@@ -1,190 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.device;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.MultiLineReceiver;
-
-import java.io.IOException;
-import java.io.File;
-import java.util.HashMap;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-public class DeviceBridge {
-    private static AndroidDebugBridge bridge;
-    
-    private static final HashMap<Device, Integer> devicePortMap = new HashMap<Device, Integer>();
-    private static int nextLocalPort = Configuration.DEFAULT_SERVER_PORT;
-
-    public static void initDebugBridge() {
-        if (bridge == null) {
-            AndroidDebugBridge.init(false /* debugger support */);
-        }
-        if (bridge == null || !bridge.isConnected()) {
-            String adbLocation = System.getProperty("hierarchyviewer.adb");
-            if (adbLocation != null && adbLocation.length() != 0) {
-                adbLocation += File.separator + "adb";
-            } else {
-                adbLocation = "adb";
-            }
-
-            bridge = AndroidDebugBridge.createBridge(adbLocation, true);
-        }
-    }
-
-    public static void startListenForDevices(AndroidDebugBridge.IDeviceChangeListener listener) {
-        AndroidDebugBridge.addDeviceChangeListener(listener);
-    }
-
-    public static void stopListenForDevices(AndroidDebugBridge.IDeviceChangeListener listener) {
-        AndroidDebugBridge.removeDeviceChangeListener(listener);
-    }
-
-    public static Device[] getDevices() {
-        return bridge.getDevices();
-    }
-
-    public static boolean isViewServerRunning(Device device) {
-        initDebugBridge();
-        final boolean[] result = new boolean[1];
-        try {
-            if (device.isOnline()) {
-                device.executeShellCommand(buildIsServerRunningShellCommand(),
-                        new BooleanResultReader(result));
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-        return result[0];
-    }
-
-    public static boolean startViewServer(Device device) {
-        return startViewServer(device, Configuration.DEFAULT_SERVER_PORT);
-    }
-
-    public static boolean startViewServer(Device device, int port) {
-        initDebugBridge();
-        final boolean[] result = new boolean[1];
-        try {
-            if (device.isOnline()) {
-                device.executeShellCommand(buildStartServerShellCommand(port),
-                        new BooleanResultReader(result));
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-        return result[0];
-    }
-
-    public static boolean stopViewServer(Device device) {
-        initDebugBridge();
-        final boolean[] result = new boolean[1];
-        try {
-            if (device.isOnline()) {
-                device.executeShellCommand(buildStopServerShellCommand(),
-                        new BooleanResultReader(result));
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-        return result[0];
-    }
-
-    public static void terminate() {
-        AndroidDebugBridge.terminate();
-    }
-
-    /**
-     * Sets up a just-connected device to work with the view server.
-     * <p/>This starts a port forwarding between a local port and a port on the device.
-     * @param device
-     */
-    public static void setupDeviceForward(Device device) {
-        synchronized (devicePortMap) {
-            if (device.getState() == Device.DeviceState.ONLINE) {
-                int localPort = nextLocalPort++;
-                device.createForward(localPort, Configuration.DEFAULT_SERVER_PORT);
-                devicePortMap.put(device, localPort);
-            }
-        }
-    }
-    
-    public static void removeDeviceForward(Device device) {
-        synchronized (devicePortMap) {
-            final Integer localPort = devicePortMap.get(device);
-            if (localPort != null) {
-                device.removeForward(localPort, Configuration.DEFAULT_SERVER_PORT);
-                devicePortMap.remove(device);
-            }
-        }
-    }
-    
-    public static int getDeviceLocalPort(Device device) {
-        synchronized (devicePortMap) {
-            Integer port = devicePortMap.get(device);
-            if (port != null) {
-                return port;
-            }
-            
-            Log.e("hierarchy", "Missing forwarded port for " + device.getSerialNumber());
-            return -1;
-        }
-        
-    }
-
-    private static String buildStartServerShellCommand(int port) {
-        return String.format("service call window %d i32 %d",
-                Configuration.SERVICE_CODE_START_SERVER, port);
-    }
-
-    private static String buildStopServerShellCommand() {
-        return String.format("service call window %d", Configuration.SERVICE_CODE_STOP_SERVER);
-    }
-
-    private static String buildIsServerRunningShellCommand() {
-        return String.format("service call window %d",
-                Configuration.SERVICE_CODE_IS_SERVER_RUNNING);
-    }
-
-    private static class BooleanResultReader extends MultiLineReceiver {
-        private final boolean[] mResult;
-
-        public BooleanResultReader(boolean[] result) {
-            mResult = result;
-        }
-
-        @Override
-        public void processNewLines(String[] strings) {
-            if (strings.length > 0) {
-                Pattern pattern = Pattern.compile(".*?\\([0-9]{8} ([0-9]{8}).*");
-                Matcher matcher = pattern.matcher(strings[0]);
-                if (matcher.matches()) {
-                    if (Integer.parseInt(matcher.group(1)) == 1) {
-                        mResult[0] = true;
-                    }
-                }
-            }
-        }
-
-        public boolean isCancelled() {
-            return false;
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Window.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Window.java
deleted file mode 100644
index 0417df6..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/device/Window.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.device;
-
-public class Window {
-    public static final Window FOCUSED_WINDOW = new Window("<Focused Window>", -1);
-
-    private String title;
-    private int hashCode;
-
-    public Window(String title, int hashCode) {
-        this.title = title;
-        this.hashCode = hashCode;
-    }
-
-    public String getTitle() {
-        return title;
-    }
-
-    public int getHashCode() {
-        return hashCode;
-    }
-
-    public String encode() {
-        return Integer.toHexString(hashCode);
-    }
-
-    public String toString() {
-        return title;
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/laf/UnifiedContentBorder.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/laf/UnifiedContentBorder.java
deleted file mode 100644
index 401fb3e..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/laf/UnifiedContentBorder.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.laf;
-
-import javax.swing.border.AbstractBorder;
-import java.awt.*;
-
-public class UnifiedContentBorder extends AbstractBorder {
-    private static final Color BORDER_TOP_COLOR1 = new Color(0x575757);
-    private static final Color BORDER_BOTTOM_COLOR1 = new Color(0x404040);
-    private static final Color BORDER_BOTTOM_COLOR2 = new Color(0xd8d8d8);
-
-    public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
-        g.setColor(BORDER_TOP_COLOR1);
-        g.drawLine(x, y, x + width, y);
-        g.setColor(BORDER_BOTTOM_COLOR1);
-        g.drawLine(x, y + height - 2, x + width, y + height - 2);
-        g.setColor(BORDER_BOTTOM_COLOR2);
-        g.drawLine(x, y + height - 1, x + width, y + height - 1);
-    }
-
-    public Insets getBorderInsets(Component component) {
-        return new Insets(1, 0, 2, 0);
-    }
-
-    public boolean isBorderOpaque() {
-        return true;
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/CaptureLoader.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/CaptureLoader.java
deleted file mode 100644
index 7cc44bc..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/CaptureLoader.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import com.android.ddmlib.Device;
-import com.android.hierarchyviewer.device.Configuration;
-import com.android.hierarchyviewer.device.Window;
-import com.android.hierarchyviewer.device.DeviceBridge;
-
-import java.awt.Image;
-import java.io.BufferedInputStream;
-import java.io.BufferedWriter;
-import java.io.IOException;
-import java.io.OutputStreamWriter;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import javax.imageio.ImageIO;
-
-public class CaptureLoader {
-    public static Image loadCapture(Device device, Window window, String params) {
-        Socket socket = null;
-        BufferedInputStream in = null;
-        BufferedWriter out = null;
-        
-        try {
-            socket = new Socket();
-            socket.connect(new InetSocketAddress("127.0.0.1",
-                    DeviceBridge.getDeviceLocalPort(device)));
-            
-            out = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream()));
-            in = new BufferedInputStream(socket.getInputStream());
-
-            out.write("CAPTURE " + window.encode() + " " + params);
-            out.newLine();
-            out.flush();
-
-            return ImageIO.read(in);
-        } catch (IOException e) {
-            // Empty
-        } finally {
-            try {
-                if (out != null) {
-                    out.close();
-                }
-                if (in != null) {
-                    in.close();
-                }
-                if (socket != null) {
-                    socket.close();
-                }
-            } catch (IOException ex) {
-                ex.printStackTrace();
-            }
-        }
-        
-        return null;
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyLoader.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyLoader.java
deleted file mode 100644
index 6efb52d..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyLoader.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import com.android.ddmlib.Device;
-import com.android.hierarchyviewer.device.DeviceBridge;
-import com.android.hierarchyviewer.device.Window;
-
-import org.openide.util.Exceptions;
-
-import java.io.BufferedReader;
-import java.io.BufferedWriter;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.io.OutputStreamWriter;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Stack;
-
-public class ViewHierarchyLoader {
-    @SuppressWarnings("empty-statement")
-    public static ViewHierarchyScene loadScene(Device device, Window window) {
-        ViewHierarchyScene scene = new ViewHierarchyScene();
-
-        // Read the views tree
-        Socket socket = null;
-        BufferedReader in = null;
-        BufferedWriter out = null;
-        
-        String line;
-        
-        try {
-            System.out.println("==> Starting client");
-            
-            socket = new Socket();
-            socket.connect(new InetSocketAddress("127.0.0.1",
-                    DeviceBridge.getDeviceLocalPort(device)));
-
-            out = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream()));
-            in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
-
-            System.out.println("==> DUMP");
-            
-            out.write("DUMP " + window.encode());
-            out.newLine();
-            out.flush();
-            
-            Stack<ViewNode> stack = new Stack<ViewNode>();
-
-            boolean setRoot = true;
-            ViewNode lastNode = null;
-            int lastWhitespaceCount = Integer.MAX_VALUE;
-
-            while ((line = in.readLine()) != null) {
-                if ("DONE.".equalsIgnoreCase(line)) {
-                    break;
-                }
-                
-                int whitespaceCount = countFrontWhitespace(line);
-                if (lastWhitespaceCount < whitespaceCount) {
-                    stack.push(lastNode);
-                } else if (!stack.isEmpty()) {
-                    final int count = lastWhitespaceCount - whitespaceCount;
-                    for (int i = 0; i < count; i++) {
-                        stack.pop();
-                    }
-                }
-
-                lastWhitespaceCount = whitespaceCount;
-                line = line.trim();
-                int index = line.indexOf(' ');
-                
-                lastNode = new ViewNode();
-                lastNode.name = line.substring(0, index);
-
-                line = line.substring(index + 1);
-                loadProperties(lastNode, line);
-
-                scene.addNode(lastNode);
-                
-                if (setRoot) {
-                    scene.setRoot(lastNode);
-                    setRoot = false;
-                }
-                
-                if (!stack.isEmpty()) {
-                    final ViewNode parent = stack.peek();
-                    final String edge = parent.name + lastNode.name;
-                    scene.addEdge(edge);
-                    scene.setEdgeSource(edge, parent);
-                    scene.setEdgeTarget(edge, lastNode);
-                    lastNode.parent = parent;
-                    parent.children.add(lastNode);
-                }
-            }
-            
-        } catch (IOException ex) {
-            Exceptions.printStackTrace(ex);
-        } finally {
-            try {
-                if (out != null) {
-                    out.close();
-                }
-                if (in != null) {
-                    in.close();
-                }
-                socket.close();
-            } catch (IOException ex) {
-                Exceptions.printStackTrace(ex);
-            }
-        }
-        
-        System.out.println("==> DONE");
-        
-        return scene;
-    }
-    
-    private static int countFrontWhitespace(String line) {
-        int count = 0;
-        while (line.charAt(count) == ' ') {
-            count++;
-        }
-        return count;
-    }
-
-    private static void loadProperties(ViewNode node, String data) {
-        int start = 0;
-        boolean stop;
-
-        do {
-            int index = data.indexOf('=', start);
-            ViewNode.Property property = new ViewNode.Property();
-            property.name = data.substring(start, index);
-
-            int index2 = data.indexOf(',', index + 1);
-            int length = Integer.parseInt(data.substring(index + 1, index2));
-            start = index2 + 1 + length;
-            property.value = data.substring(index2 + 1, index2 + 1 + length);
-            
-            node.properties.add(property);
-            node.namedProperties.put(property.name, property);
-
-            stop = start >= data.length();
-            if (!stop) {
-                start += 1;
-            }
-        } while (!stop);
-
-        Collections.sort(node.properties, new Comparator<ViewNode.Property>() {
-            public int compare(ViewNode.Property source, ViewNode.Property destination) {
-                return source.name.compareTo(destination.name);
-            }
-        });
-
-        node.decode();
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyScene.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyScene.java
deleted file mode 100644
index d99a80c..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewHierarchyScene.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import java.awt.Color;
-import java.awt.Font;
-import java.awt.GradientPaint;
-import java.awt.Graphics2D;
-import java.awt.Rectangle;
-import java.awt.geom.Point2D;
-
-import org.netbeans.api.visual.action.ActionFactory;
-import org.netbeans.api.visual.action.WidgetAction;
-import org.netbeans.api.visual.anchor.AnchorFactory;
-import org.netbeans.api.visual.border.BorderFactory;
-import org.netbeans.api.visual.graph.GraphScene;
-import org.netbeans.api.visual.layout.LayoutFactory;
-import org.netbeans.api.visual.model.ObjectState;
-import org.netbeans.api.visual.widget.ConnectionWidget;
-import org.netbeans.api.visual.widget.LabelWidget;
-import org.netbeans.api.visual.widget.LayerWidget;
-import org.netbeans.api.visual.widget.Widget;
-
-public class ViewHierarchyScene extends GraphScene<ViewNode, String> {
-    private ViewNode root;
-    private LayerWidget widgetLayer;
-    private LayerWidget connectionLayer;
-
-    private WidgetAction moveAction = ActionFactory.createMoveAction();
-
-    public ViewHierarchyScene() {
-        widgetLayer = new LayerWidget(this);
-        connectionLayer = new LayerWidget(this);
-
-        addChild(widgetLayer);
-        addChild(connectionLayer);
-    }
-    
-    public ViewNode getRoot() {
-        return root;
-    }
-    
-    void setRoot(ViewNode root) {
-        this.root = root;
-    }
-
-    @Override
-    protected Widget attachNodeWidget(ViewNode node) {
-        Widget widget = createBox(node.name, node.id);
-        widget.getActions().addAction(createSelectAction());
-        widget.getActions().addAction(moveAction);
-        widgetLayer.addChild(widget);
-        return widget;
-    }
-
-    private Widget createBox(String node, String id) {
-        Widget box = new GradientWidget(this);
-        box.setLayout(LayoutFactory.createVerticalFlowLayout());
-        box.setBorder(BorderFactory.createLineBorder(2, Color.BLACK));
-        box.setOpaque(true);
-
-        LabelWidget label = new LabelWidget(this);
-        label.setFont(getDefaultFont().deriveFont(Font.PLAIN, 12.0f));
-        label.setLabel(getShortName(node));
-        label.setBorder(BorderFactory.createEmptyBorder(6, 6, 0, 6));
-        label.setAlignment(LabelWidget.Alignment.CENTER);
-
-        box.addChild(label);
-        
-        label = new LabelWidget(this);
-        label.setFont(getDefaultFont().deriveFont(Font.PLAIN, 10.0f));
-        label.setLabel(getAddress(node));
-        label.setBorder(BorderFactory.createEmptyBorder(3, 6, 0, 6));
-        label.setAlignment(LabelWidget.Alignment.CENTER);
-        
-        box.addChild(label);
-        
-        label = new LabelWidget(this);
-        label.setFont(getDefaultFont().deriveFont(Font.PLAIN, 10.0f));
-        label.setLabel(id);
-        label.setBorder(BorderFactory.createEmptyBorder(3, 6, 6, 6));
-        label.setAlignment(LabelWidget.Alignment.CENTER);
-        
-        box.addChild(label);
-
-        return box;
-    }
-    
-    private static String getAddress(String name) {
-        String[] nameAndHashcode = name.split("@");
-        return "@" + nameAndHashcode[1];
-    }
-    
-    private static String getShortName(String name) {
-        String[] nameAndHashcode = name.split("@");
-        String[] packages = nameAndHashcode[0].split("\\.");
-        return packages[packages.length - 1];
-    }
-
-    @Override
-    protected Widget attachEdgeWidget(String edge) {
-        ConnectionWidget connectionWidget = new ConnectionWidget(this);
-        connectionLayer.addChild(connectionWidget);
-        return connectionWidget;
-    }
-
-    @Override
-    protected void attachEdgeSourceAnchor(String edge, ViewNode oldSourceNode, ViewNode sourceNode) {
-        final ConnectionWidget connection = (ConnectionWidget) findWidget(edge);
-        final Widget source = findWidget(sourceNode);
-        connection.bringToBack();
-        source.bringToFront();
-        connection.setSourceAnchor(AnchorFactory.createRectangularAnchor(source));
-    }
-
-    @Override
-    protected void attachEdgeTargetAnchor(String edge, ViewNode oldTargetNode, ViewNode targetNode) {
-        final ConnectionWidget connection = (ConnectionWidget) findWidget(edge);
-        final Widget target = findWidget(targetNode);
-        connection.bringToBack();
-        target.bringToFront();
-        connection.setTargetAnchor(AnchorFactory.createRectangularAnchor(target));
-    }
-    
-    private static class GradientWidget extends Widget {
-        public static final GradientPaint BLUE_EXPERIENCE = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(168, 204, 241),
-                new Point2D.Double(0, 1),
-                new Color(44, 61, 146));
-        public static final GradientPaint MAC_OSX_SELECTED = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(81, 141, 236),
-                new Point2D.Double(0, 1),
-                new Color(36, 96, 192));
-        public static final GradientPaint MAC_OSX = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(167, 210, 250),
-                new Point2D.Double(0, 1),
-                new Color(99, 147, 206));
-        public static final GradientPaint AERITH = new GradientPaint(
-                new Point2D.Double(0, 0),
-                Color.WHITE,
-                new Point2D.Double(0, 1),
-                new Color(64, 110, 161));
-        public static final GradientPaint GRAY = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(226, 226, 226),
-                new Point2D.Double(0, 1),
-                new Color(250, 248, 248));
-        public static final GradientPaint RED_XP = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(236, 81, 81),
-                new Point2D.Double(0, 1),
-                new Color(192, 36, 36));
-        public static final GradientPaint NIGHT_GRAY = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(102, 111, 127),
-                new Point2D.Double(0, 1),
-                new Color(38, 45, 61));
-        public static final GradientPaint NIGHT_GRAY_LIGHT = new GradientPaint(
-                new Point2D.Double(0, 0),
-                new Color(129, 138, 155),
-                new Point2D.Double(0, 1),
-                new Color(58, 66, 82));
-
-        private static Color UNSELECTED = Color.BLACK;
-        private static Color SELECTED = Color.WHITE;
-
-        private boolean isSelected = false;
-        private GradientPaint gradient = MAC_OSX_SELECTED;
-
-        public GradientWidget(ViewHierarchyScene scene) {
-            super(scene);
-        }
-
-        @Override
-        protected void notifyStateChanged(ObjectState previous, ObjectState state) {
-            super.notifyStateChanged(previous, state);
-            isSelected = state.isSelected() || state.isFocused() || state.isWidgetFocused();
-
-            for (Widget child : getChildren()) {
-                child.setForeground(isSelected ? SELECTED : UNSELECTED);
-            }
-
-            repaint();
-        }
-
-        @Override
-        protected void paintBackground() {
-            super.paintBackground();
-
-            Graphics2D g2 = getGraphics();
-            Rectangle bounds = getBounds();
-            
-            if (!isSelected) {
-                g2.setColor(Color.WHITE);
-            } else {
-                g2.setPaint(new GradientPaint(bounds.x, bounds.y, gradient.getColor1(),
-                        bounds.x, bounds.x + bounds.height, gradient.getColor2()));
-            }
-            g2.fillRect(bounds.x, bounds.y, bounds.width, bounds.height);
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewManager.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewManager.java
deleted file mode 100644
index 6b212c0..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewManager.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import com.android.ddmlib.Device;
-import com.android.hierarchyviewer.device.Configuration;
-import com.android.hierarchyviewer.device.Window;
-import com.android.hierarchyviewer.device.DeviceBridge;
-
-import java.io.BufferedWriter;
-import java.io.IOException;
-import java.io.OutputStreamWriter;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-
-public class ViewManager {
-    public static void invalidate(Device device, Window window, String params) {
-        sendCommand("INVALIDATE", device, window, params);
-    }
-
-    public static void requestLayout(Device device, Window window, String params) {
-        sendCommand("REQUEST_LAYOUT", device, window, params);
-    }
-
-    private static void sendCommand(String command, Device device, Window window, String params) {
-        Socket socket = null;
-        BufferedWriter out = null;
-
-        try {
-            socket = new Socket();
-            socket.connect(new InetSocketAddress("127.0.0.1",
-                    DeviceBridge.getDeviceLocalPort(device)));
-
-            out = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream()));
-
-            out.write(command + " " + window.encode() + " " + params);
-            out.newLine();
-            out.flush();
-        } catch (IOException e) {
-            // Empty
-        } finally {
-            try {
-                if (out != null) {
-                    out.close();
-                }
-                if (socket != null) {
-                    socket.close();
-                }
-            } catch (IOException ex) {
-                ex.printStackTrace();
-            }
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewNode.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewNode.java
deleted file mode 100644
index 8284df1..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/ViewNode.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import java.awt.Image;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-public class ViewNode {
-    public String id;
-    public String name;
-
-    public List<Property> properties = new ArrayList<Property>();
-    public Map<String, Property> namedProperties = new HashMap<String, Property>();
-
-    public ViewNode parent;
-    public List<ViewNode> children = new ArrayList<ViewNode>();
-
-    public Image image;
-    
-    public int left;
-    public int top;
-    public int width;
-    public int height;
-    public int scrollX;
-    public int scrollY;
-    public int paddingLeft;
-    public int paddingRight;
-    public int paddingTop;
-    public int paddingBottom;
-    public int marginLeft;
-    public int marginRight;
-    public int marginTop;
-    public int marginBottom;
-    public int baseline;
-    public boolean willNotDraw;
-    public boolean hasMargins;
-    
-    public boolean decoded;
-    
-    void decode() {
-        id = namedProperties.get("mID").value;
-
-        left = getInt("mLeft", 0);
-        top = getInt("mTop", 0);
-        width = getInt("getWidth()", 0);
-        height = getInt("getHeight()", 0);
-        scrollX = getInt("mScrollX", 0);
-        scrollY = getInt("mScrollY", 0);
-        paddingLeft = getInt("mPaddingLeft", 0);
-        paddingRight = getInt("mPaddingRight", 0);
-        paddingTop = getInt("mPaddingTop", 0);
-        paddingBottom = getInt("mPaddingBottom", 0);
-        marginLeft = getInt("layout_leftMargin", Integer.MIN_VALUE);
-        marginRight = getInt("layout_rightMargin", Integer.MIN_VALUE);
-        marginTop = getInt("layout_topMargin", Integer.MIN_VALUE);
-        marginBottom = getInt("layout_bottomMargin", Integer.MIN_VALUE);
-        baseline = getInt("getBaseline()", 0);
-        willNotDraw = getBoolean("willNotDraw()", false);
-
-        hasMargins = marginLeft != Integer.MIN_VALUE &&
-                marginRight != Integer.MIN_VALUE &&
-                marginTop != Integer.MIN_VALUE &&
-                marginBottom != Integer.MIN_VALUE;
-
-        decoded = true;
-    }
-
-    private boolean getBoolean(String name, boolean defaultValue) {
-        Property p = namedProperties.get(name);
-        if (p != null) {
-            try {
-                return Boolean.parseBoolean(p.value);
-            } catch (NumberFormatException e) {
-                return defaultValue;
-            }   
-        }
-        return defaultValue;
-    }
-
-    private int getInt(String name, int defaultValue) {
-        Property p = namedProperties.get(name);
-        if (p != null) {
-            try {
-                return Integer.parseInt(p.value);
-            } catch (NumberFormatException e) {
-                return defaultValue;
-            }   
-        }
-        return defaultValue;
-    }
-
-    @SuppressWarnings({"StringEquality"})
-    @Override
-    public boolean equals(Object obj) {
-        if (obj == null) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        final ViewNode other = (ViewNode) obj;
-        return !(this.name != other.name && (this.name == null || !this.name.equals(other.name)));
-    }
-
-    @Override
-    public String toString() {
-        return name;
-    }
-
-    @Override
-    public int hashCode() {
-        int hash = 5;
-        hash = 67 * hash + (this.name != null ? this.name.hashCode() : 0);
-        return hash;
-    }
-
-    public static class Property {
-        public String name;
-        public String value;
-
-        @Override
-        public String toString() {
-            return name + '=' + value;
-        }
-        
-        @SuppressWarnings({"StringEquality"})
-        @Override
-        public boolean equals(Object obj) {
-            if (obj == null) {
-                return false;
-            }
-            if (getClass() != obj.getClass()) {
-                return false;
-            }
-            final Property other = (Property) obj;
-            if (this.name != other.name && (this.name == null || !this.name.equals(other.name))) {
-                return false;
-            }
-            return !(this.value != other.value && (this.value == null || !this.value.equals(other.value)));
-        }
-
-        @Override
-        public int hashCode() {
-            int hash = 5;
-            hash = 61 * hash + (this.name != null ? this.name.hashCode() : 0);
-            hash = 61 * hash + (this.value != null ? this.value.hashCode() : 0);
-            return hash;
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/WindowsLoader.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/WindowsLoader.java
deleted file mode 100644
index 6c14cb6..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/scene/WindowsLoader.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.scene;
-
-import com.android.ddmlib.Device;
-import com.android.hierarchyviewer.device.DeviceBridge;
-import com.android.hierarchyviewer.device.Window;
-
-import java.io.BufferedReader;
-import java.io.BufferedWriter;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.io.OutputStreamWriter;
-import java.net.InetSocketAddress;
-import java.net.Socket;
-import java.util.ArrayList;
-
-public class WindowsLoader {
-    public static Window[] loadWindows(Device device) {
-        Socket socket = null;
-        BufferedReader in = null;
-        BufferedWriter out = null;
-
-        try {
-            ArrayList<Window> windows = new ArrayList<Window>();
-
-            socket = new Socket();
-            socket.connect(new InetSocketAddress("127.0.0.1",
-                    DeviceBridge.getDeviceLocalPort(device)));
-
-            out = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream()));
-            in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
-
-            out.write("LIST");
-            out.newLine();
-            out.flush();
-
-            String line;
-            while ((line = in.readLine()) != null) {
-                if ("DONE.".equalsIgnoreCase(line)) {
-                    break;
-                }
-
-                int index = line.indexOf(' ');
-                if (index != -1) {
-                    Window w = new Window(line.substring(index + 1),
-                            Integer.parseInt(line.substring(0, index), 16));
-                    windows.add(w);
-                }
-            }
-
-            return windows.toArray(new Window[windows.size()]);
-        } catch (IOException e) {
-            // Empty
-        } finally {
-            try {
-                if (out != null) {
-                    out.close();
-                }
-                if (in != null) {
-                    in.close();
-                }
-                if (socket != null) {
-                    socket.close();
-                }
-            } catch (IOException ex) {
-                ex.printStackTrace();
-            }
-        }
-
-        return new Window[0];
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/CaptureRenderer.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/CaptureRenderer.java
deleted file mode 100644
index 7ccc818..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/CaptureRenderer.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui;
-
-import com.android.hierarchyviewer.scene.ViewNode;
-
-import javax.swing.*;
-import java.awt.*;
-
-class CaptureRenderer extends JLabel {
-    private ViewNode node;
-    private boolean showExtras;
-
-    CaptureRenderer(ImageIcon icon, ViewNode node) {
-        super(icon);
-        this.node = node;
-        setBackground(Color.BLACK);
-    }
-
-    @Override
-    public Dimension getPreferredSize() {
-        Dimension d = super.getPreferredSize();
-
-        if (node.hasMargins) {
-            d.width += node.marginLeft + node.marginRight;
-            d.height += node.marginTop + node.marginBottom;
-        }
-
-        return d;
-    }
-
-    public void setShowExtras(boolean showExtras) {
-        this.showExtras = showExtras;
-        repaint();
-    }
-
-    @Override
-    protected void paintComponent(Graphics g) {
-        Icon icon = getIcon();
-        int width = icon.getIconWidth();
-        int height = icon.getIconHeight();
-
-        int x = (getWidth() - width) / 2;
-        int y = (getHeight() - height) / 2;
-
-        icon.paintIcon(this, g, x, y);
-
-        if (showExtras) {
-            g.translate(x, y);
-            g.setXORMode(Color.WHITE);
-            if ((node.paddingBottom | node.paddingLeft |
-                    node.paddingTop | node.paddingRight) != 0) {
-                g.setColor(Color.RED);
-                g.drawRect(node.paddingLeft, node.paddingTop,
-                        width - node.paddingRight - node.paddingLeft,
-                        height - node.paddingBottom - node.paddingTop);
-            }
-            if (node.baseline != -1) {
-                g.setColor(Color.BLUE);
-                g.drawLine(0, node.baseline, width, node.baseline);
-            }
-            if (node.hasMargins && (node.marginLeft | node.marginBottom |
-                    node.marginRight | node.marginRight) != 0) {
-                g.setColor(Color.BLACK);
-                g.drawRect(-node.marginLeft, -node.marginTop,
-                        node.marginLeft + width + node.marginRight,
-                        node.marginTop + height + node.marginBottom);
-            }
-            g.translate(-x, -y);
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/LayoutRenderer.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/LayoutRenderer.java
deleted file mode 100644
index a50905c..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/LayoutRenderer.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui;
-
-import com.android.hierarchyviewer.scene.ViewHierarchyScene;
-import com.android.hierarchyviewer.scene.ViewNode;
-
-import javax.swing.JComponent;
-import javax.swing.BorderFactory;
-import java.awt.Color;
-import java.awt.Dimension;
-import java.awt.Graphics;
-import java.awt.Insets;
-import java.util.Set;
-
-class LayoutRenderer extends JComponent {
-    private static final int EMULATED_SCREEN_WIDTH = 320;
-    private static final int EMULATED_SCREEN_HEIGHT = 480;
-    private static final int SCREEN_MARGIN = 24;
-
-    private boolean showExtras;
-    private ViewHierarchyScene scene;
-
-    LayoutRenderer(ViewHierarchyScene scene) {
-        this.scene = scene;
-
-        setOpaque(true);
-        setBorder(BorderFactory.createEmptyBorder(0, 0, 12, 0));
-        setBackground(Color.BLACK);
-        setForeground(Color.WHITE);
-    }
-
-    @Override
-    public Dimension getPreferredSize() {
-        return new Dimension(EMULATED_SCREEN_WIDTH + SCREEN_MARGIN,
-                EMULATED_SCREEN_HEIGHT + SCREEN_MARGIN);
-    }
-
-    @Override
-    protected void paintComponent(Graphics g) {
-        g.setColor(getBackground());
-        g.fillRect(0, 0, getWidth(), getHeight());
-
-        Insets insets = getInsets();
-        g.clipRect(insets.left, insets.top,
-                getWidth() - insets.left - insets.right,
-                getHeight() - insets.top - insets.bottom);
-
-        if (scene == null) {
-            return;
-        }
-
-        ViewNode root = scene.getRoot();
-        if (root == null) {
-            return;
-        }
-
-        int x = (getWidth() - insets.left - insets.right - root.width) / 2;
-        int y = (getHeight() - insets.top - insets.bottom - root.height) / 2;
-        g.translate(insets.left + x, insets.top + y);
-
-        g.setColor(getForeground());
-        g.drawRect(root.left, root.top, root.width - 1, root.height - 1);
-        g.clipRect(root.left - 1, root.top - 1, root.width + 1, root.height + 1);
-        drawChildren(g, root, -root.scrollX, -root.scrollY);
-
-        Set<?> selection = scene.getSelectedObjects();
-        if (selection.size() > 0) {
-            ViewNode node = (ViewNode) selection.iterator().next();
-            g.setColor(Color.RED);
-            Graphics s = g.create();
-            ViewNode p = node.parent;
-            while (p != null) {
-                s.translate(p.left - p.scrollX, p.top - p.scrollY);
-                p = p.parent;
-            }
-            if (showExtras && node.image != null) {
-                s.drawImage(node.image, node.left, node.top, null);
-            }
-            s.drawRect(node.left, node.top, node.width - 1, node.height - 1);
-            s.dispose();
-        }
-
-        g.translate(-insets.left - x, -insets.top - y);
-    }
-
-    private void drawChildren(Graphics g, ViewNode root, int x, int y) {
-        g.translate(x, y);
-        for (ViewNode node : root.children) {
-            if (!node.willNotDraw) {
-                g.drawRect(node.left, node.top, node.width - 1, node.height - 1);
-            }
-
-            if (node.children.size() > 0) {
-                drawChildren(g, node,
-                        node.left - node.parent.scrollX,
-                        node.top - node.parent.scrollY);
-            }
-        }
-        g.translate(-x, -y);
-    }
-
-    public void setShowExtras(boolean showExtras) {
-        this.showExtras = showExtras;
-        repaint();
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/ScreenViewer.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/ScreenViewer.java
deleted file mode 100644
index 83d926f..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/ScreenViewer.java
+++ /dev/null
@@ -1,732 +0,0 @@
-package com.android.hierarchyviewer.ui;
-
-import com.android.ddmlib.Device;
-import com.android.ddmlib.RawImage;
-import com.android.hierarchyviewer.util.WorkerThread;
-import com.android.hierarchyviewer.scene.ViewNode;
-import com.android.hierarchyviewer.ui.util.PngFileFilter;
-import com.android.hierarchyviewer.ui.util.IconLoader;
-
-import javax.swing.JComponent;
-import javax.swing.Timer;
-import javax.swing.JPanel;
-import javax.swing.SwingUtilities;
-import javax.swing.BorderFactory;
-import javax.swing.JLabel;
-import javax.swing.JSlider;
-import javax.swing.Box;
-import javax.swing.JCheckBox;
-import javax.swing.JButton;
-import javax.swing.JFileChooser;
-import javax.swing.event.ChangeListener;
-import javax.swing.event.ChangeEvent;
-import javax.imageio.ImageIO;
-
-import org.jdesktop.swingworker.SwingWorker;
-
-import java.io.IOException;
-import java.io.File;
-import java.awt.image.BufferedImage;
-import java.awt.Graphics;
-import java.awt.Dimension;
-import java.awt.BorderLayout;
-import java.awt.Graphics2D;
-import java.awt.Color;
-import java.awt.Rectangle;
-import java.awt.Point;
-import java.awt.GridBagLayout;
-import java.awt.GridBagConstraints;
-import java.awt.Insets;
-import java.awt.FlowLayout;
-import java.awt.AlphaComposite;
-import java.awt.RenderingHints;
-import java.awt.event.ActionListener;
-import java.awt.event.ActionEvent;
-import java.awt.event.MouseAdapter;
-import java.awt.event.MouseEvent;
-import java.awt.event.MouseMotionAdapter;
-import java.util.concurrent.ExecutionException;
-
-class ScreenViewer extends JPanel implements ActionListener {
-    private final Workspace workspace;
-    private final Device device;
-
-    private GetScreenshotTask task;
-    private BufferedImage image;
-    private int[] scanline;
-    private volatile boolean isLoading;
-
-    private BufferedImage overlay;    
-    private AlphaComposite overlayAlpha = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.3f);
-
-    private ScreenViewer.LoupeStatus status;
-    private ScreenViewer.LoupeViewer loupe;
-    private ScreenViewer.Crosshair crosshair;
-
-    private int zoom = 8;
-    private int y = 0;
-
-    private Timer timer;
-    private ViewNode node;
-
-    ScreenViewer(Workspace workspace, Device device, int spacing) {
-        setLayout(new BorderLayout());
-        setOpaque(false);
-
-        this.workspace = workspace;
-        this.device = device;
-
-        timer = new Timer(5000, this);
-        timer.setInitialDelay(0);
-        timer.setRepeats(true);
-
-        JPanel panel = buildViewerAndControls();
-        add(panel, BorderLayout.WEST);
-
-        JPanel loupePanel = buildLoupePanel(spacing);
-        add(loupePanel, BorderLayout.CENTER);
-
-        SwingUtilities.invokeLater(new Runnable() {
-            public void run() {
-                timer.start();                
-            }
-        });
-    }
-
-    private JPanel buildLoupePanel(int spacing) {
-        loupe = new LoupeViewer();
-        CrosshairPanel crosshairPanel = new CrosshairPanel(loupe);
-
-        JPanel loupePanel = new JPanel(new BorderLayout());
-        loupePanel.add(crosshairPanel);
-        status = new LoupeStatus();
-        loupePanel.add(status, BorderLayout.SOUTH);
-
-        loupePanel.setBorder(BorderFactory.createEmptyBorder(0, spacing, 0, 0));
-        return loupePanel;
-    }
-
-    private JPanel buildViewerAndControls() {
-        JPanel panel = new JPanel(new GridBagLayout());
-        crosshair = new Crosshair(new ScreenshotViewer());
-        panel.add(crosshair,
-                new GridBagConstraints(0, y++, 2, 1, 1.0f, 0.0f,
-                    GridBagConstraints.FIRST_LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 0), 0, 0));
-        buildSlider(panel, "Overlay:", "0%", "100%", 0, 100, 30, 1).addChangeListener(
-                new ChangeListener() {
-                    public void stateChanged(ChangeEvent event) {
-                        float opacity = ((JSlider) event.getSource()).getValue() / 100.0f;
-                        overlayAlpha = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, opacity);
-                        repaint();
-                    }
-        });
-        buildOverlayExtraControls(panel);
-        buildSlider(panel, "Refresh Rate:", "1s", "40s", 1, 40, 5, 1).addChangeListener(
-                new ChangeListener() {
-                    public void stateChanged(ChangeEvent event) {
-                        int rate = ((JSlider) event.getSource()).getValue() * 1000;
-                        timer.setDelay(rate);
-                        timer.setInitialDelay(0);
-                        timer.restart();
-                    }
-        });
-        buildSlider(panel, "Zoom:", "2x", "24x", 2, 24, 8, 2).addChangeListener(
-                new ChangeListener() {
-                    public void stateChanged(ChangeEvent event) {
-                        zoom = ((JSlider) event.getSource()).getValue();
-                        loupe.clearGrid = true;
-                        loupe.moveToPoint(crosshair.crosshair.x, crosshair.crosshair.y);
-                        repaint();
-                    }
-        });
-        panel.add(Box.createVerticalGlue(),
-                new GridBagConstraints(0, y++, 2, 1, 1.0f, 1.0f,
-                    GridBagConstraints.FIRST_LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 0), 0, 0));
-        return panel;
-    }
-
-    private void buildOverlayExtraControls(JPanel panel) {
-        JPanel extras = new JPanel(new FlowLayout(FlowLayout.LEFT, 0, 0));
-
-        JButton loadOverlay = new JButton("Load...");
-        loadOverlay.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent event) {
-                SwingWorker<?, ?> worker = openOverlay();
-                if (worker != null) {
-                    worker.execute();
-                }
-            }
-        });
-        extras.add(loadOverlay);
-
-        JCheckBox showInLoupe = new JCheckBox("Show in Loupe");
-        showInLoupe.setSelected(false);
-        showInLoupe.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent event) {
-                loupe.showOverlay = ((JCheckBox) event.getSource()).isSelected();
-                loupe.repaint();
-            }
-        });
-        extras.add(showInLoupe);
-
-        panel.add(extras, new GridBagConstraints(1, y++, 1, 1, 1.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                        new Insets(0, 0, 0, 0), 0, 0));
-    }
-
-    public SwingWorker<?, ?> openOverlay() {
-        JFileChooser chooser = new JFileChooser();
-        chooser.setFileFilter(new PngFileFilter());
-        int choice = chooser.showOpenDialog(this);
-        if (choice == JFileChooser.APPROVE_OPTION) {
-            return new OpenOverlayTask(chooser.getSelectedFile());
-        } else {
-            return null;
-        }
-    }
-
-    private JSlider buildSlider(JPanel panel, String title, String minName, String maxName,
-            int min, int max, int value, int tick) {
-        panel.add(new JLabel(title), new GridBagConstraints(0, y, 1, 1, 1.0f, 0.0f,
-                    GridBagConstraints.LINE_END, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 6), 0, 0));
-        JPanel sliderPanel = new JPanel(new FlowLayout(FlowLayout.LEFT, 0, 0));
-        sliderPanel.add(new JLabel(minName));
-        JSlider slider = new JSlider(min, max, value);
-        slider.setMinorTickSpacing(tick);
-        slider.setMajorTickSpacing(tick);
-        slider.setSnapToTicks(true);
-        sliderPanel.add(slider);
-        sliderPanel.add(new JLabel(maxName));
-        panel.add(sliderPanel, new GridBagConstraints(1, y++, 1, 1, 1.0f, 0.0f,
-                    GridBagConstraints.FIRST_LINE_START, GridBagConstraints.NONE,
-                        new Insets(0, 0, 0, 0), 0, 0));
-        return slider;
-    }
-
-    void stop() {
-        timer.stop();
-    }
-
-    void start() {
-        timer.start();
-    }
-
-    void select(ViewNode node) {
-        this.node = node;
-        repaint();
-    }
-
-    class LoupeViewer extends JComponent {
-        private final Color lineColor = new Color(1.0f, 1.0f, 1.0f, 0.3f);
-
-        private int width;
-        private int height;
-        private BufferedImage grid;
-        private int left;
-        private int top;
-        public boolean clearGrid;
-
-        private final Rectangle clip = new Rectangle();
-        private boolean showOverlay = false;
-
-        LoupeViewer() {
-            addMouseListener(new MouseAdapter() {
-                @Override
-                public void mousePressed(MouseEvent event) {
-                    moveToPoint(event);
-                }
-            });
-            addMouseMotionListener(new MouseMotionAdapter() {
-                @Override
-                public void mouseDragged(MouseEvent event) {
-                    moveToPoint(event);
-                }
-            });
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            if (isLoading) {
-                return;
-            }
-
-            g.translate(-left, -top);
-
-            if (image != null) {
-                Graphics2D g2 = (Graphics2D) g.create();
-                g2.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
-                        RenderingHints.VALUE_INTERPOLATION_NEAREST_NEIGHBOR);
-                g2.scale(zoom, zoom);
-                g2.drawImage(image, 0, 0, null);
-                if (overlay != null && showOverlay) {
-                    g2.setComposite(overlayAlpha);
-                    g2.drawImage(overlay, 0, image.getHeight() - overlay.getHeight(), null);
-                }
-                g2.dispose();
-            }
-
-            int width = getWidth();
-            int height = getHeight();
-
-            Graphics2D g2 = null;
-            if (width != this.width || height != this.height) {
-                this.width = width;
-                this.height = height;
-
-                grid = new BufferedImage(width + zoom + 1, height + zoom + 1,
-                        BufferedImage.TYPE_INT_ARGB);
-                clearGrid = true;
-                g2 = grid.createGraphics();
-            } else if (clearGrid) {
-                g2 = grid.createGraphics();
-                g2.setComposite(AlphaComposite.Clear);
-                g2.fillRect(0, 0, grid.getWidth(), grid.getHeight());
-                g2.setComposite(AlphaComposite.SrcOver);
-            }
-
-            if (clearGrid) {
-                clearGrid = false;
-
-                g2.setColor(lineColor);
-                width += zoom;
-                height += zoom;
-
-                for (int x = zoom; x <= width; x += zoom) {
-                    g2.drawLine(x, 0, x, height);
-                }
-
-                for (int y = 0; y <= height; y += zoom) {
-                    g2.drawLine(0, y, width, y);
-                }
-
-                g2.dispose();
-            }
-
-            if (image != null) {
-                g.getClipBounds(clip);
-                g.clipRect(0, 0, image.getWidth() * zoom + 1, image.getHeight() * zoom + 1);
-                g.drawImage(grid, clip.x - clip.x % zoom, clip.y - clip.y % zoom, null);
-            }
-
-            g.translate(left, top);
-        }
-
-        void moveToPoint(MouseEvent event) {
-            int x = Math.max(0, Math.min((event.getX() + left) / zoom, image.getWidth() - 1));
-            int y = Math.max(0, Math.min((event.getY() + top) / zoom, image.getHeight() - 1));
-            moveToPoint(x, y);
-            crosshair.moveToPoint(x, y);
-        }
-
-        void moveToPoint(int x, int y) {
-            left = x * zoom - width / 2 + zoom / 2;
-            top = y * zoom - height / 2 + zoom / 2;
-            repaint();
-        }
-    }
-
-    class LoupeStatus extends JPanel {
-        private JLabel xLabel;
-        private JLabel yLabel;
-        private JLabel rLabel;
-        private JLabel gLabel;
-        private JLabel bLabel;
-        private JLabel hLabel;
-        private ScreenViewer.LoupeStatus.ColoredSquare square;
-        private Color color;
-
-        LoupeStatus() {
-            setOpaque(true);
-            setLayout(new GridBagLayout());
-            setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
-
-            square = new ColoredSquare();
-            add(square, new GridBagConstraints(0, 0, 1, 2, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-
-            JLabel label;
-
-            add(label = new JLabel("#ffffff"), new GridBagConstraints(0, 2, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            hLabel = label;
-
-            add(label = new JLabel("R:"), new GridBagConstraints(1, 0, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 6, 0, 6), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            add(label = new JLabel("255"), new GridBagConstraints(2, 0, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            rLabel = label;
-
-            add(label = new JLabel("G:"), new GridBagConstraints(1, 1, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 6, 0, 6), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            add(label = new JLabel("255"), new GridBagConstraints(2, 1, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            gLabel = label;
-
-            add(label = new JLabel("B:"), new GridBagConstraints(1, 2, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 6, 0, 6), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            add(label = new JLabel("255"), new GridBagConstraints(2, 2, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            bLabel = label;
-
-            add(label = new JLabel("X:"), new GridBagConstraints(3, 0, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 6, 0, 6), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            add(label = new JLabel("0 px"), new GridBagConstraints(4, 0, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            xLabel = label;
-
-            add(label = new JLabel("Y:"), new GridBagConstraints(3, 1, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 6, 0, 6), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            add(label = new JLabel("0 px"), new GridBagConstraints(4, 1, 1, 1, 0.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.NONE,
-                    new Insets(0, 0, 0, 12), 0, 0 ));
-            label.setForeground(Color.WHITE);
-            yLabel = label;
-
-            add(Box.createHorizontalGlue(), new GridBagConstraints(5, 0, 1, 1, 1.0f, 0.0f,
-                    GridBagConstraints.LINE_START, GridBagConstraints.BOTH,
-                    new Insets(0, 0, 0, 0), 0, 0 ));
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            g.setColor(Color.BLACK);
-            g.fillRect(0, 0, getWidth(), getHeight());
-        }
-
-        void showPixel(int x, int y) {
-            xLabel.setText(x + " px");
-            yLabel.setText(y + " px");
-
-            int pixel = image.getRGB(x, y);
-            color = new Color(pixel);
-            hLabel.setText("#" + Integer.toHexString(pixel));
-            rLabel.setText(String.valueOf((pixel >> 16) & 0xff));
-            gLabel.setText(String.valueOf((pixel >>  8) & 0xff));
-            bLabel.setText(String.valueOf((pixel      ) & 0xff));
-
-            square.repaint();
-        }
-
-        private class ColoredSquare extends JComponent {
-            @Override
-            public Dimension getPreferredSize() {
-                Dimension d = super.getPreferredSize();
-                d.width = 60;
-                d.height = 30;
-                return d;
-            }
-
-            @Override
-            protected void paintComponent(Graphics g) {
-                g.setColor(color);
-                g.fillRect(0, 0, getWidth(), getHeight());
-
-                g.setColor(Color.WHITE);
-                g.drawRect(0, 0, getWidth() - 1, getHeight() - 1);                
-            }
-        }
-    }
-
-    class Crosshair extends JPanel {
-        // magenta = 0xff5efe
-        private final Color crosshairColor = new Color(0x00ffff);
-        Point crosshair = new Point();
-        private int width;
-        private int height;
-
-        Crosshair(ScreenshotViewer screenshotViewer) {
-            setOpaque(true);
-            setLayout(new BorderLayout());
-            add(screenshotViewer);
-            addMouseListener(new MouseAdapter() {
-                @Override
-                public void mousePressed(MouseEvent event) {
-                    moveToPoint(event);
-                }
-            });
-            addMouseMotionListener(new MouseMotionAdapter() {
-                @Override
-                public void mouseDragged(MouseEvent event) {
-                    moveToPoint(event);
-                }
-            });
-        }
-
-        void moveToPoint(int x, int y) {
-            crosshair.x = x;
-            crosshair.y = y;
-            status.showPixel(crosshair.x, crosshair.y);
-            repaint();
-        }
-
-        private void moveToPoint(MouseEvent event) {
-            crosshair.x = Math.max(0, Math.min(image.getWidth() - 1, event.getX()));
-            crosshair.y = Math.max(0, Math.min(image.getHeight() - 1, event.getY()));
-            loupe.moveToPoint(crosshair.x, crosshair.y);
-            status.showPixel(crosshair.x, crosshair.y);
-
-            repaint();
-        }
-
-        @Override
-        public void paint(Graphics g) {
-            super.paint(g);
-
-            if (crosshair == null || width != getWidth() || height != getHeight()) {
-                width = getWidth();
-                height = getHeight();
-                crosshair = new Point(width / 2, height / 2);
-            }
-
-            g.setColor(crosshairColor);
-
-            g.drawLine(crosshair.x, 0, crosshair.x, height);
-            g.drawLine(0, crosshair.y, width, crosshair.y);
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            super.paintComponent(g);
-            g.setColor(Color.BLACK);
-            g.fillRect(0, 0, getWidth(), getHeight());
-        }
-    }
-
-    class ScreenshotViewer extends JComponent {
-        private final Color boundsColor = new Color(0xff5efe);
-
-        ScreenshotViewer() {
-            setOpaque(true);
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            g.setColor(Color.BLACK);
-            g.fillRect(0, 0, getWidth(), getHeight());
-
-            if (isLoading) {
-                return;
-            }
-
-            if (image != null) {
-                g.drawImage(image, 0, 0, null);
-                if (overlay != null) {
-                    Graphics2D g2 = (Graphics2D) g.create();
-                    g2.setComposite(overlayAlpha);
-                    g2.drawImage(overlay, 0, image.getHeight() - overlay.getHeight(), null);
-                }
-            }
-
-            if (node != null) {
-                Graphics s = g.create();
-                s.setColor(boundsColor);
-                ViewNode p = node.parent;
-                while (p != null) {
-                    s.translate(p.left - p.scrollX, p.top - p.scrollY);
-                    p = p.parent;
-                }
-                s.drawRect(node.left, node.top, node.width - 1, node.height - 1);
-                s.translate(node.left, node.top);
-
-                s.setXORMode(Color.WHITE);
-                if ((node.paddingBottom | node.paddingLeft |
-                        node.paddingTop | node.paddingRight) != 0) {
-                    s.setColor(Color.BLACK);
-                    s.drawRect(node.paddingLeft, node.paddingTop,
-                            node.width - node.paddingRight - node.paddingLeft - 1,
-                            node.height - node.paddingBottom - node.paddingTop - 1);
-                }
-                if (node.hasMargins && (node.marginLeft | node.marginBottom |
-                        node.marginRight | node.marginRight) != 0) {
-                    s.setColor(Color.BLACK);
-                    s.drawRect(-node.marginLeft, -node.marginTop,
-                            node.marginLeft + node.width + node.marginRight - 1,
-                            node.marginTop + node.height + node.marginBottom - 1);
-                }
-
-                s.dispose();
-            }
-        }
-
-        @Override
-        public Dimension getPreferredSize() {
-            if (image == null) {
-                return new Dimension(320, 480);
-            }
-            return new Dimension(image.getWidth(), image.getHeight());
-        }
-    }
-
-    private class CrosshairPanel extends JPanel {
-        private final Color crosshairColor = new Color(0xff5efe);
-        private final Insets insets = new Insets(0, 0, 0, 0);
-
-        CrosshairPanel(LoupeViewer loupe) {
-            setLayout(new BorderLayout());
-            add(loupe);
-        }
-
-        @Override
-        public void paint(Graphics g) {
-            super.paint(g);
-
-            g.setColor(crosshairColor);
-
-            int width = getWidth();
-            int height = getHeight();
-
-            getInsets(insets);
-
-            int x = (width - insets.left - insets.right) / 2;
-            int y = (height - insets.top - insets.bottom) / 2;
-
-            g.drawLine(insets.left + x, insets.top, insets.left + x, height - insets.bottom);
-            g.drawLine(insets.left, insets.top + y, width - insets.right, insets.top + y);
-        }
-
-        @Override
-        protected void paintComponent(Graphics g) {
-            g.setColor(Color.BLACK);
-            Insets insets = getInsets();
-            g.fillRect(insets.left, insets.top, getWidth() - insets.left - insets.right,
-                    getHeight() - insets.top - insets.bottom);
-        }
-    }
-
-    public void actionPerformed(ActionEvent event) {
-        if (task != null && !task.isDone()) {
-            return;
-        }
-        task = new GetScreenshotTask();
-        task.execute();
-    }
-
-    private class GetScreenshotTask extends SwingWorker<Boolean, Void> {
-        private GetScreenshotTask() {
-            workspace.beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Boolean doInBackground() throws Exception {
-            RawImage rawImage;
-            try {
-                rawImage = device.getScreenshot();
-            } catch (IOException ioe) {
-                return false;
-            }
-
-            boolean resize = false;
-            isLoading = true;
-            try {
-                if (rawImage != null && rawImage.bpp == 16) {
-                    if (image == null || rawImage.width != image.getWidth() ||
-                            rawImage.height != image.getHeight()) {
-                        image = new BufferedImage(rawImage.width, rawImage.height,
-                                BufferedImage.TYPE_INT_ARGB);
-                        scanline = new int[rawImage.width];
-                        resize = true;
-                    }
-
-                    byte[] buffer = rawImage.data;
-                    int index = 0;
-                    for (int y = 0 ; y < rawImage.height ; y++) {
-                        for (int x = 0 ; x < rawImage.width ; x++) {
-                            int value = buffer[index++] & 0x00FF;
-                            value |= (buffer[index++] << 8) & 0x0FF00;
-
-                            int r = ((value >> 11) & 0x01F) << 3;
-                            int g = ((value >> 5) & 0x03F) << 2;
-                            int b = ((value     ) & 0x01F) << 3;
-
-                            scanline[x] = 0xFF << 24 | r << 16 | g << 8 | b;
-                        }
-                        image.setRGB(0, y, rawImage.width, 1, scanline,
-                                0, rawImage.width);
-                    }
-                }
-            } finally {
-                isLoading = false;
-            }
-
-            return resize;
-        }
-
-        @Override
-        protected void done() {
-            workspace.endTask();
-            try {
-                if (get()) {
-                    validate();
-                    crosshair.crosshair = new Point(image.getWidth() / 2,
-                            image.getHeight() / 2);
-                    status.showPixel(image.getWidth() / 2, image.getHeight() / 2);
-                    loupe.moveToPoint(image.getWidth() / 2, image.getHeight() / 2);
-                }
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            }
-            repaint();
-        }
-    }
-
-    private class OpenOverlayTask extends SwingWorker<BufferedImage, Void> {
-        private File file;
-
-        private OpenOverlayTask(File file) {
-            this.file = file;
-            workspace.beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected BufferedImage doInBackground() {
-            try {
-                return IconLoader.toCompatibleImage(ImageIO.read(file));
-            } catch (IOException ex) {
-                ex.printStackTrace();
-            }
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            try {
-                overlay = get();
-                repaint();
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            } finally {
-                workspace.endTask();
-            }
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/Workspace.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/Workspace.java
deleted file mode 100644
index 0add4e9..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/Workspace.java
+++ /dev/null
@@ -1,1382 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.hierarchyviewer.device.DeviceBridge;
-import com.android.hierarchyviewer.device.Window;
-import com.android.hierarchyviewer.laf.UnifiedContentBorder;
-import com.android.hierarchyviewer.scene.CaptureLoader;
-import com.android.hierarchyviewer.scene.ViewHierarchyLoader;
-import com.android.hierarchyviewer.scene.ViewHierarchyScene;
-import com.android.hierarchyviewer.scene.ViewManager;
-import com.android.hierarchyviewer.scene.ViewNode;
-import com.android.hierarchyviewer.scene.WindowsLoader;
-import com.android.hierarchyviewer.util.OS;
-import com.android.hierarchyviewer.util.WorkerThread;
-import com.android.hierarchyviewer.ui.action.ShowDevicesAction;
-import com.android.hierarchyviewer.ui.action.RequestLayoutAction;
-import com.android.hierarchyviewer.ui.action.InvalidateAction;
-import com.android.hierarchyviewer.ui.action.CaptureNodeAction;
-import com.android.hierarchyviewer.ui.action.RefreshWindowsAction;
-import com.android.hierarchyviewer.ui.action.StopServerAction;
-import com.android.hierarchyviewer.ui.action.StartServerAction;
-import com.android.hierarchyviewer.ui.action.ExitAction;
-import com.android.hierarchyviewer.ui.action.LoadGraphAction;
-import com.android.hierarchyviewer.ui.action.SaveSceneAction;
-import com.android.hierarchyviewer.ui.util.PngFileFilter;
-import com.android.hierarchyviewer.ui.util.IconLoader;
-import com.android.hierarchyviewer.ui.model.PropertiesTableModel;
-import com.android.hierarchyviewer.ui.model.ViewsTreeModel;
-import org.jdesktop.swingworker.SwingWorker;
-import org.netbeans.api.visual.graph.layout.TreeGraphLayout;
-import org.netbeans.api.visual.model.ObjectSceneEvent;
-import org.netbeans.api.visual.model.ObjectSceneEventType;
-import org.netbeans.api.visual.model.ObjectSceneListener;
-import org.netbeans.api.visual.model.ObjectState;
-
-import javax.imageio.ImageIO;
-import javax.swing.ActionMap;
-import javax.swing.BorderFactory;
-import javax.swing.ButtonGroup;
-import javax.swing.ImageIcon;
-import javax.swing.JButton;
-import javax.swing.JCheckBox;
-import javax.swing.JComponent;
-import javax.swing.JFileChooser;
-import javax.swing.JFrame;
-import javax.swing.JLabel;
-import javax.swing.JMenu;
-import javax.swing.JMenuBar;
-import javax.swing.JMenuItem;
-import javax.swing.JPanel;
-import javax.swing.JProgressBar;
-import javax.swing.JScrollPane;
-import javax.swing.JSlider;
-import javax.swing.JSplitPane;
-import javax.swing.JTable;
-import javax.swing.JToggleButton;
-import javax.swing.JToolBar;
-import javax.swing.ListSelectionModel;
-import javax.swing.SwingUtilities;
-import javax.swing.JTree;
-import javax.swing.Box;
-import javax.swing.tree.TreePath;
-import javax.swing.tree.DefaultTreeCellRenderer;
-import javax.swing.event.ChangeEvent;
-import javax.swing.event.ChangeListener;
-import javax.swing.event.ListSelectionEvent;
-import javax.swing.event.ListSelectionListener;
-import javax.swing.event.TreeSelectionListener;
-import javax.swing.event.TreeSelectionEvent;
-import javax.swing.table.DefaultTableModel;
-import java.awt.image.BufferedImage;
-import java.awt.BorderLayout;
-import java.awt.Dimension;
-import java.awt.GridBagLayout;
-import java.awt.GridBagConstraints;
-import java.awt.Insets;
-import java.awt.FlowLayout;
-import java.awt.Color;
-import java.awt.Image;
-import java.awt.Graphics2D;
-import java.awt.Component;
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.awt.event.MouseAdapter;
-import java.awt.event.MouseEvent;
-import java.io.File;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Set;
-import java.util.concurrent.ExecutionException;
-
-public class Workspace extends JFrame {
-    private JLabel viewCountLabel;
-    private JSlider zoomSlider;
-    private JSplitPane sideSplitter;
-    private JSplitPane mainSplitter;
-    private JTable propertiesTable;
-    private JComponent pixelPerfectPanel;
-    private JTree pixelPerfectTree;
-    private ScreenViewer screenViewer;
-
-    private JPanel extrasPanel;
-    private LayoutRenderer layoutView;
-
-    private JScrollPane sceneScroller;
-    private JComponent sceneView;
-
-    private ViewHierarchyScene scene;
-
-    private ActionMap actionsMap;
-    private JPanel mainPanel;
-    private JProgressBar progress;
-    private JToolBar buttonsPanel;
-
-    private JComponent deviceSelector;
-    private DevicesTableModel devicesTableModel;
-    private WindowsTableModel windowsTableModel;
-
-    private Device currentDevice;
-    private Window currentWindow = Window.FOCUSED_WINDOW;
-
-    private JButton displayNodeButton;
-    private JButton invalidateButton;
-    private JButton requestLayoutButton;
-    private JButton loadButton;
-    private JButton startButton;
-    private JButton stopButton;
-    private JButton showDevicesButton;
-    private JButton refreshButton;
-    private JToggleButton graphViewButton;
-    private JToggleButton pixelPerfectViewButton;
-    private JMenuItem saveMenuItem;
-    private JMenuItem showDevicesMenuItem;
-    private JMenuItem loadMenuItem;
-    private JMenuItem startMenuItem;
-    private JMenuItem stopMenuItem;
-    private JTable devices;
-    private JTable windows;
-    private JLabel minZoomLabel;
-    private JLabel maxZoomLabel;
-
-    public Workspace() {
-        super("Hierarchy Viewer");
-
-        buildActions();
-        add(buildMainPanel());
-        setJMenuBar(buildMenuBar());
-
-        currentDeviceChanged();
-
-        pack();
-    }
-
-    private void buildActions() {
-        actionsMap = new ActionMap();
-        actionsMap.put(ExitAction.ACTION_NAME, new ExitAction(this));
-        actionsMap.put(ShowDevicesAction.ACTION_NAME, new ShowDevicesAction(this));
-        actionsMap.put(LoadGraphAction.ACTION_NAME, new LoadGraphAction(this));
-        actionsMap.put(SaveSceneAction.ACTION_NAME, new SaveSceneAction(this));
-        actionsMap.put(StartServerAction.ACTION_NAME, new StartServerAction(this));
-        actionsMap.put(StopServerAction.ACTION_NAME, new StopServerAction(this));
-        actionsMap.put(InvalidateAction.ACTION_NAME, new InvalidateAction(this));
-        actionsMap.put(RequestLayoutAction.ACTION_NAME, new RequestLayoutAction(this));
-        actionsMap.put(CaptureNodeAction.ACTION_NAME, new CaptureNodeAction(this));
-        actionsMap.put(RefreshWindowsAction.ACTION_NAME, new RefreshWindowsAction(this));
-    }
-
-    private JComponent buildMainPanel() {
-        mainPanel = new JPanel();
-        mainPanel.setLayout(new BorderLayout());
-        mainPanel.add(buildToolBar(), BorderLayout.PAGE_START);
-        mainPanel.add(deviceSelector = buildDeviceSelector(), BorderLayout.CENTER);
-        mainPanel.add(buildStatusPanel(), BorderLayout.SOUTH);
-
-        mainPanel.setPreferredSize(new Dimension(950, 800));
-
-        return mainPanel;
-    }
-
-    private JComponent buildGraphPanel() {
-        sceneScroller = new JScrollPane();
-        sceneScroller.setBorder(null);
-
-        mainSplitter = new JSplitPane();
-        mainSplitter.setResizeWeight(1.0);
-        mainSplitter.setContinuousLayout(true);
-        if (OS.isMacOsX() && OS.isLeopardOrLater()) {
-            mainSplitter.setBorder(new UnifiedContentBorder());
-        }
-
-        mainSplitter.setLeftComponent(sceneScroller);
-        mainSplitter.setRightComponent(buildSideSplitter());
-
-        return mainSplitter;
-    }
-
-    private JComponent buildDeviceSelector() {
-        JPanel panel = new JPanel(new GridBagLayout());
-        if (OS.isMacOsX() && OS.isLeopardOrLater()) {
-            panel.setBorder(new UnifiedContentBorder());
-        }
-
-        devicesTableModel = new DevicesTableModel();
-        for (Device device : DeviceBridge.getDevices()) {
-            DeviceBridge.setupDeviceForward(device);
-            devicesTableModel.addDevice(device);
-        }
-        DeviceBridge.startListenForDevices(devicesTableModel);
-
-        devices = new JTable(devicesTableModel);
-        devices.getSelectionModel().addListSelectionListener(new DeviceSelectedListener());
-        devices.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
-        devices.setBorder(null);
-        JScrollPane devicesScroller = new JScrollPane(devices);
-        devicesScroller.setBorder(null);
-        panel.add(devicesScroller, new GridBagConstraints(0, 0, 1, 1, 0.5, 1.0,
-                GridBagConstraints.LINE_START, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0),
-                0, 0));
-
-        windowsTableModel = new WindowsTableModel();
-        windowsTableModel.setVisible(false);
-
-        windows = new JTable(windowsTableModel);
-        windows.getSelectionModel().addListSelectionListener(new WindowSelectedListener());
-        windows.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
-        windows.setBorder(null);
-        JScrollPane windowsScroller = new JScrollPane(windows);
-        windowsScroller.setBorder(null);
-        panel.add(windowsScroller, new GridBagConstraints(2, 0, 1, 1, 0.5, 1.0,
-                GridBagConstraints.LINE_START, GridBagConstraints.BOTH, new Insets(0, 0, 0, 0),
-                0, 0));
-
-        return panel;
-    }
-
-    private JComponent buildSideSplitter() {
-        propertiesTable = new JTable();
-        propertiesTable.setModel(new DefaultTableModel(new Object[][] { },
-                new String[] { "Property", "Value" }));
-        propertiesTable.setBorder(null);
-        propertiesTable.getTableHeader().setBorder(null);
-
-        JScrollPane tableScroller = new JScrollPane(propertiesTable);
-        tableScroller.setBorder(null);
-
-        sideSplitter = new JSplitPane();
-        sideSplitter.setBorder(null);
-        sideSplitter.setOrientation(JSplitPane.VERTICAL_SPLIT);
-        sideSplitter.setResizeWeight(0.5);
-        sideSplitter.setLeftComponent(tableScroller);
-        sideSplitter.setBottomComponent(null);
-        sideSplitter.setContinuousLayout(true);
-
-        return sideSplitter;
-    }
-
-    private JPanel buildStatusPanel() {
-        JPanel statusPanel = new JPanel();
-        statusPanel.setLayout(new BorderLayout());
-
-        JPanel leftSide = new JPanel();
-        leftSide.setOpaque(false);
-        leftSide.setLayout(new FlowLayout(FlowLayout.LEFT, 0, 5));
-        leftSide.add(Box.createHorizontalStrut(6));
-
-        ButtonGroup group = new ButtonGroup();
-
-        graphViewButton = new JToggleButton(IconLoader.load(getClass(),
-                "/images/icon-graph-view.png"));
-        graphViewButton.setSelectedIcon(IconLoader.load(getClass(),
-                "/images/icon-graph-view-selected.png"));
-        graphViewButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        graphViewButton.putClientProperty("JButton.segmentPosition", "first");
-        graphViewButton.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent e) {
-                toggleGraphView();
-            }
-        });
-        group.add(graphViewButton);
-        leftSide.add(graphViewButton);
-
-        pixelPerfectViewButton = new JToggleButton(IconLoader.load(getClass(),
-                "/images/icon-pixel-perfect-view.png"));
-        pixelPerfectViewButton.setSelectedIcon(IconLoader.load(getClass(),
-                "/images/icon-pixel-perfect-view-selected.png"));
-        pixelPerfectViewButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        pixelPerfectViewButton.putClientProperty("JButton.segmentPosition", "last");
-        pixelPerfectViewButton.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent e) {
-                togglePixelPerfectView();
-            }
-        });
-        group.add(pixelPerfectViewButton);
-        leftSide.add(pixelPerfectViewButton);
-
-        graphViewButton.setSelected(true);
-
-        minZoomLabel = new JLabel();
-        minZoomLabel.setText("20%");
-        minZoomLabel.putClientProperty("JComponent.sizeVariant", "small");
-        minZoomLabel.setBorder(BorderFactory.createEmptyBorder(0, 6, 0, 0));
-        leftSide.add(minZoomLabel);
-
-        zoomSlider = new JSlider();
-        zoomSlider.putClientProperty("JComponent.sizeVariant", "small");
-        zoomSlider.setMaximum(200);
-        zoomSlider.setMinimum(20);
-        zoomSlider.setValue(100);
-        zoomSlider.addChangeListener(new ChangeListener() {
-            public void stateChanged(ChangeEvent evt) {
-                zoomSliderStateChanged(evt);
-            }
-        });
-        leftSide.add(zoomSlider);
-
-        maxZoomLabel = new JLabel();
-        maxZoomLabel.putClientProperty("JComponent.sizeVariant", "small");
-        maxZoomLabel.setText("200%");
-        leftSide.add(maxZoomLabel);
-
-        viewCountLabel = new JLabel();
-        viewCountLabel.setText("0 views");
-        viewCountLabel.putClientProperty("JComponent.sizeVariant", "small");
-        viewCountLabel.setBorder(BorderFactory.createEmptyBorder(0, 12, 0, 0));
-        leftSide.add(viewCountLabel);
-
-        statusPanel.add(leftSide, BorderLayout.LINE_START);
-
-        JPanel rightSide = new JPanel();
-        rightSide.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 12));
-        rightSide.setLayout(new FlowLayout(FlowLayout.RIGHT));
-
-        progress = new JProgressBar();
-        progress.setVisible(false);
-        progress.setIndeterminate(true);
-        progress.putClientProperty("JComponent.sizeVariant", "mini");
-        progress.putClientProperty("JProgressBar.style", "circular");
-        rightSide.add(progress);
-
-        statusPanel.add(rightSide, BorderLayout.LINE_END);
-
-        viewCountLabel.setVisible(false);
-        zoomSlider.setVisible(false);
-        minZoomLabel.setVisible(false);
-        maxZoomLabel.setVisible(false);        
-
-        return statusPanel;
-    }
-
-    private JToolBar buildToolBar() {
-        JToolBar toolBar = new JToolBar();
-        toolBar.setFloatable(false);
-        toolBar.setRollover(true);
-
-        startButton = new JButton();
-        startButton.setAction(actionsMap.get(StartServerAction.ACTION_NAME));
-        startButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        startButton.putClientProperty("JButton.segmentPosition", "first");
-        toolBar.add(startButton);
-
-        stopButton = new JButton();
-        stopButton.setAction(actionsMap.get(StopServerAction.ACTION_NAME));
-        stopButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        stopButton.putClientProperty("JButton.segmentPosition", "middle");
-        toolBar.add(stopButton);
-
-        refreshButton = new JButton();
-        refreshButton.setAction(actionsMap.get(RefreshWindowsAction.ACTION_NAME));
-        refreshButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        refreshButton.putClientProperty("JButton.segmentPosition", "last");
-        toolBar.add(refreshButton);
-
-        showDevicesButton = new JButton();
-        showDevicesButton.setAction(actionsMap.get(ShowDevicesAction.ACTION_NAME));
-        showDevicesButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        showDevicesButton.putClientProperty("JButton.segmentPosition", "first");
-        toolBar.add(showDevicesButton);
-        showDevicesButton.setEnabled(false);
-
-        loadButton = new JButton();
-        loadButton.setAction(actionsMap.get(LoadGraphAction.ACTION_NAME));
-        loadButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        loadButton.putClientProperty("JButton.segmentPosition", "last");
-        toolBar.add(loadButton);
-
-        displayNodeButton = new JButton();
-        displayNodeButton.setAction(actionsMap.get(CaptureNodeAction.ACTION_NAME));
-        displayNodeButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        displayNodeButton.putClientProperty("JButton.segmentPosition", "first");
-        toolBar.add(displayNodeButton);
-
-        invalidateButton = new JButton();
-        invalidateButton.setAction(actionsMap.get(InvalidateAction.ACTION_NAME));
-        invalidateButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        invalidateButton.putClientProperty("JButton.segmentPosition", "middle");
-        toolBar.add(invalidateButton);
-
-        requestLayoutButton = new JButton();
-        requestLayoutButton.setAction(actionsMap.get(RequestLayoutAction.ACTION_NAME));
-        requestLayoutButton.putClientProperty("JButton.buttonType", "segmentedTextured");
-        requestLayoutButton.putClientProperty("JButton.segmentPosition", "last");
-        toolBar.add(requestLayoutButton);
-
-        return toolBar;
-    }
-
-    private JMenuBar buildMenuBar() {
-        JMenuBar menuBar = new JMenuBar();
-
-        JMenu fileMenu = new JMenu();
-        JMenu viewMenu = new JMenu();
-        JMenu viewHierarchyMenu = new JMenu();
-        JMenu serverMenu = new JMenu();
-
-        saveMenuItem = new JMenuItem();
-        JMenuItem exitMenuItem = new JMenuItem();
-
-        showDevicesMenuItem = new JMenuItem();
-
-        loadMenuItem = new JMenuItem();
-
-        startMenuItem = new JMenuItem();
-        stopMenuItem = new JMenuItem();
-
-        fileMenu.setText("File");
-
-        saveMenuItem.setAction(actionsMap.get(SaveSceneAction.ACTION_NAME));
-        fileMenu.add(saveMenuItem);
-
-        exitMenuItem.setAction(actionsMap.get(ExitAction.ACTION_NAME));
-        fileMenu.add(exitMenuItem);
-
-        menuBar.add(fileMenu);
-
-        viewMenu.setText("View");
-
-        showDevicesMenuItem.setAction(actionsMap.get(ShowDevicesAction.ACTION_NAME));
-        showDevicesMenuItem.setEnabled(false);
-        viewMenu.add(showDevicesMenuItem);
-
-        menuBar.add(viewMenu);        
-
-        viewHierarchyMenu.setText("Hierarchy");
-
-        loadMenuItem.setAction(actionsMap.get(LoadGraphAction.ACTION_NAME));
-        viewHierarchyMenu.add(loadMenuItem);
-
-        menuBar.add(viewHierarchyMenu);
-
-        serverMenu.setText("Server");
-
-        startMenuItem.setAction(actionsMap.get(StartServerAction.ACTION_NAME));
-        serverMenu.add(startMenuItem);
-
-        stopMenuItem.setAction(actionsMap.get(StopServerAction.ACTION_NAME));
-        serverMenu.add(stopMenuItem);
-
-        menuBar.add(serverMenu);
-
-        return menuBar;
-    }
-
-    private JComponent buildPixelPerfectPanel() {
-        JSplitPane splitter = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
-
-        pixelPerfectTree = new JTree(new Object[0]);
-        pixelPerfectTree.setBorder(null);
-        pixelPerfectTree.setBorder(BorderFactory.createEmptyBorder(6, 6, 6, 6));
-        pixelPerfectTree.addTreeSelectionListener(new TreeSelectionListener() {
-            public void valueChanged(TreeSelectionEvent event) {
-                ViewNode node = (ViewNode) event.getPath().getLastPathComponent();
-                screenViewer.select(node);
-            }
-        });
-
-        JScrollPane scroller = new JScrollPane(pixelPerfectTree);
-        scroller.setBorder(null);
-        scroller.getViewport().setBorder(null);
-
-        splitter.setContinuousLayout(true);
-        splitter.setLeftComponent(scroller);
-        splitter.setRightComponent(buildPixelPerfectViewer(splitter));
-        splitter.setBorder(null);
-
-        if (OS.isMacOsX() && OS.isLeopardOrLater()) {
-            splitter.setBorder(new UnifiedContentBorder());
-        }
-
-        return splitter;
-    }
-
-    private JComponent buildPixelPerfectViewer(JSplitPane splitter) {
-        screenViewer = new ScreenViewer(this, currentDevice, splitter.getDividerSize());
-        return screenViewer;
-    }
-
-    private void toggleGraphView() {
-        viewCountLabel.setVisible(true);
-        zoomSlider.setVisible(true);
-        minZoomLabel.setVisible(true);
-        maxZoomLabel.setVisible(true);
-
-        screenViewer.stop();
-        mainPanel.remove(pixelPerfectPanel);
-        mainPanel.add(mainSplitter, BorderLayout.CENTER);
-
-        validate();
-        repaint();
-    }
-
-    private void togglePixelPerfectView() {
-        if (pixelPerfectPanel == null) {
-            pixelPerfectPanel = buildPixelPerfectPanel();
-            showPixelPerfectTree();
-        } else {
-            screenViewer.start();
-        }
-
-        viewCountLabel.setVisible(false);
-        zoomSlider.setVisible(false);
-        minZoomLabel.setVisible(false);
-        maxZoomLabel.setVisible(false);
-
-        mainPanel.remove(mainSplitter);
-        mainPanel.add(pixelPerfectPanel, BorderLayout.CENTER);
-
-        validate();
-        repaint();
-    }
-
-    private void zoomSliderStateChanged(ChangeEvent evt) {
-        JSlider slider = (JSlider) evt.getSource();
-        if (sceneView != null) {
-            scene.setZoomFactor(slider.getValue() / 100.0d);
-            sceneView.repaint();
-        }
-    }
-
-    private void showProperties(ViewNode node) {
-        propertiesTable.setModel(new PropertiesTableModel(node));
-    }
-
-    private void showPixelPerfectTree() {
-        if (pixelPerfectTree == null) {
-            return;
-        }
-        pixelPerfectTree.setModel(new ViewsTreeModel(scene.getRoot()));
-        pixelPerfectTree.setCellRenderer(new ViewsTreeCellRenderer());
-        expandAll(pixelPerfectTree, true);
-
-    }
-
-    private static void expandAll(JTree tree, boolean expand) {
-        ViewNode root = (ViewNode) tree.getModel().getRoot();
-        expandAll(tree, new TreePath(root), expand);
-    }
-
-    private static void expandAll(JTree tree, TreePath parent, boolean expand) {
-        // Traverse children
-        ViewNode node = (ViewNode)parent.getLastPathComponent();
-        if (node.children != null) {
-            for (ViewNode n : node.children) {
-                TreePath path = parent.pathByAddingChild(n);
-                expandAll(tree, path, expand);
-            }
-        }
-
-        if (expand) {
-            tree.expandPath(parent);
-        } else {
-            tree.collapsePath(parent);
-        }
-    }
-
-    private void createGraph(ViewHierarchyScene scene) {
-        scene.addObjectSceneListener(new SceneFocusListener(),
-                ObjectSceneEventType.OBJECT_FOCUS_CHANGED);
-
-        if (mainSplitter == null) {
-            mainPanel.remove(deviceSelector);
-            mainPanel.add(buildGraphPanel(), BorderLayout.CENTER);
-            showDevicesButton.setEnabled(true);
-            showDevicesMenuItem.setEnabled(true);
-            graphViewButton.setEnabled(true);
-            pixelPerfectViewButton.setEnabled(true);
-
-            viewCountLabel.setVisible(true);
-            zoomSlider.setVisible(true);
-            minZoomLabel.setVisible(true);
-            maxZoomLabel.setVisible(true);            
-        }
-
-        sceneView = scene.createView();
-        sceneView.addMouseListener(new NodeClickListener());
-        sceneScroller.setViewportView(sceneView);
-
-        if (extrasPanel != null) {
-            sideSplitter.remove(extrasPanel);
-        }
-        sideSplitter.setBottomComponent(buildExtrasPanel());
-
-        mainSplitter.setDividerLocation(getWidth() - mainSplitter.getDividerSize() -
-                buttonsPanel.getPreferredSize().width);
-
-        saveMenuItem.setEnabled(true);
-        showPixelPerfectTree();
-
-        updateStatus();
-        layoutScene();
-    }
-
-    private void layoutScene() {
-        TreeGraphLayout<ViewNode, String> layout =
-                new TreeGraphLayout<ViewNode, String>(scene, 50, 50, 70, 30, true);
-        layout.layout(scene.getRoot());
-    }
-
-    private void updateStatus() {
-        viewCountLabel.setText("" + scene.getNodes().size() + " views");
-        zoomSlider.setEnabled(scene.getNodes().size() > 0);
-    }
-
-    private JPanel buildExtrasPanel() {
-        extrasPanel = new JPanel(new BorderLayout());
-        extrasPanel.add(new JScrollPane(layoutView = new LayoutRenderer(scene)));
-        extrasPanel.add(scene.createSatelliteView(), BorderLayout.SOUTH);
-        extrasPanel.add(buildLayoutViewControlButtons(), BorderLayout.NORTH);
-        return extrasPanel;
-    }
-
-    private JComponent buildLayoutViewControlButtons() {
-        buttonsPanel = new JToolBar();
-        buttonsPanel.setFloatable(false);
-
-        ButtonGroup group = new ButtonGroup();
-
-        JToggleButton white = new JToggleButton("On White");
-        toggleColorOnSelect(white);
-        white.putClientProperty("JButton.buttonType", "segmentedTextured");
-        white.putClientProperty("JButton.segmentPosition", "first");
-        white.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent e) {
-                layoutView.setBackground(Color.WHITE);
-                layoutView.setForeground(Color.BLACK);
-            }
-        });
-        group.add(white);
-        buttonsPanel.add(white);
-
-        JToggleButton black = new JToggleButton("On Black");
-        toggleColorOnSelect(black);
-        black.putClientProperty("JButton.buttonType", "segmentedTextured");
-        black.putClientProperty("JButton.segmentPosition", "last");
-        black.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent e) {
-                layoutView.setBackground(Color.BLACK);
-                layoutView.setForeground(Color.WHITE);
-            }
-        });
-        group.add(black);
-        buttonsPanel.add(black);
-
-        black.setSelected(true);
-
-        JCheckBox showExtras = new JCheckBox("Show Extras");
-        showExtras.putClientProperty("JComponent.sizeVariant", "small");
-        showExtras.addChangeListener(new ChangeListener() {
-            public void stateChanged(ChangeEvent e) {
-                layoutView.setShowExtras(((JCheckBox) e.getSource()).isSelected());
-            }
-        });
-        buttonsPanel.add(showExtras);
-
-        return buttonsPanel;
-    }
-
-    private void showCaptureWindow(ViewNode node, String captureParams, Image image) {
-        if (image != null) {
-            layoutView.repaint();
-
-            JFrame frame = new JFrame(captureParams);
-            JPanel panel = new JPanel(new BorderLayout());
-
-            final CaptureRenderer label = new CaptureRenderer(new ImageIcon(image), node);
-            label.setBorder(BorderFactory.createEmptyBorder(24, 24, 24, 24));
-
-            final JPanel solidColor = new JPanel(new BorderLayout());
-            solidColor.setBackground(Color.BLACK);
-            solidColor.add(label);
-
-            JToolBar toolBar = new JToolBar();
-            toolBar.setFloatable(false);
-
-            ButtonGroup group = new ButtonGroup();
-
-            JToggleButton white = new JToggleButton("On White");
-            toggleColorOnSelect(white);
-            white.putClientProperty("JButton.buttonType", "segmentedTextured");
-            white.putClientProperty("JButton.segmentPosition", "first");
-            white.addActionListener(new ActionListener() {
-                public void actionPerformed(ActionEvent e) {
-                    solidColor.setBackground(Color.WHITE);
-                }
-            });
-            group.add(white);
-            toolBar.add(white);
-
-            JToggleButton black = new JToggleButton("On Black");
-            toggleColorOnSelect(black);
-            black.putClientProperty("JButton.buttonType", "segmentedTextured");
-            black.putClientProperty("JButton.segmentPosition", "last");
-            black.addActionListener(new ActionListener() {
-                public void actionPerformed(ActionEvent e) {
-                    solidColor.setBackground(Color.BLACK);
-                }
-            });
-            group.add(black);
-            toolBar.add(black);
-
-            black.setSelected(true);
-
-            JCheckBox showExtras = new JCheckBox("Show Extras");
-            showExtras.addChangeListener(new ChangeListener() {
-                public void stateChanged(ChangeEvent e) {
-                    label.setShowExtras(((JCheckBox) e.getSource()).isSelected());
-                }
-            });
-            toolBar.add(showExtras);
-
-            panel.add(toolBar, BorderLayout.NORTH);
-            panel.add(solidColor);
-            frame.add(panel);
-
-            frame.pack();
-            frame.setResizable(false);
-            frame.setLocationRelativeTo(Workspace.this);
-            frame.setVisible(true);
-        }
-    }
-
-    private void reset() {
-        currentDevice = null;
-        currentWindow = null;
-        currentDeviceChanged();
-        windowsTableModel.setVisible(false);
-        windowsTableModel.clear();
-
-        showDevicesSelector();
-    }
-
-    public void showDevicesSelector() {
-        if (mainSplitter != null) {
-            if (pixelPerfectPanel != null) {
-                screenViewer.start();                
-            }
-            mainPanel.remove(graphViewButton.isSelected() ? mainSplitter : pixelPerfectPanel);
-            mainPanel.add(deviceSelector, BorderLayout.CENTER);
-            pixelPerfectPanel = mainSplitter = null;
-            graphViewButton.setSelected(true);
-
-            viewCountLabel.setVisible(false);
-            zoomSlider.setVisible(false);
-            minZoomLabel.setVisible(false);
-            maxZoomLabel.setVisible(false);
-
-            saveMenuItem.setEnabled(false);            
-            showDevicesMenuItem.setEnabled(false);
-            showDevicesButton.setEnabled(false);
-            displayNodeButton.setEnabled(false);
-            invalidateButton.setEnabled(false);
-            requestLayoutButton.setEnabled(false);
-            graphViewButton.setEnabled(false);
-            pixelPerfectViewButton.setEnabled(false);
-
-            if (currentDevice != null) {
-                if (!DeviceBridge.isViewServerRunning(currentDevice)) {
-                    DeviceBridge.startViewServer(currentDevice);
-                }
-                loadWindows().execute();
-                windowsTableModel.setVisible(true);
-            }
-
-            validate();
-            repaint();
-        }
-    }
-
-    private void currentDeviceChanged() {
-        if (currentDevice == null) {
-            startButton.setEnabled(false);
-            startMenuItem.setEnabled(false);
-            stopButton.setEnabled(false);
-            stopMenuItem.setEnabled(false);
-            refreshButton.setEnabled(false);
-            saveMenuItem.setEnabled(false);
-            loadButton.setEnabled(false);
-            displayNodeButton.setEnabled(false);
-            invalidateButton.setEnabled(false);
-            graphViewButton.setEnabled(false);
-            pixelPerfectViewButton.setEnabled(false);
-            requestLayoutButton.setEnabled(false);
-            loadMenuItem.setEnabled(false);
-        } else {
-            loadMenuItem.setEnabled(true);
-            checkForServerOnCurrentDevice();
-        }
-    }
-
-    private void checkForServerOnCurrentDevice() {
-        if (DeviceBridge.isViewServerRunning(currentDevice)) {
-            startButton.setEnabled(false);
-            startMenuItem.setEnabled(false);
-            stopButton.setEnabled(true);
-            stopMenuItem.setEnabled(true);
-            loadButton.setEnabled(true);
-            refreshButton.setEnabled(true);
-        } else {
-            startButton.setEnabled(true);
-            startMenuItem.setEnabled(true);
-            stopButton.setEnabled(false);
-            stopMenuItem.setEnabled(false);
-            loadButton.setEnabled(false);
-            refreshButton.setEnabled(false);
-        }
-    }
-
-    public void cleanupDevices() {
-        for (Device device : devicesTableModel.getDevices()) {
-            DeviceBridge.removeDeviceForward(device);
-        }
-    }
-
-    private static void toggleColorOnSelect(JToggleButton button) {
-        if (!OS.isMacOsX() || !OS.isLeopardOrLater()) {
-            return;
-        }
-
-        button.addChangeListener(new ChangeListener() {
-            public void stateChanged(ChangeEvent event) {
-                JToggleButton button = (JToggleButton) event.getSource();
-                if (button.isSelected()) {
-                    button.setForeground(Color.WHITE);
-                } else {
-                    button.setForeground(Color.BLACK);
-                }
-            }
-        });
-    }
-
-    public void beginTask() {
-        progress.setVisible(true);
-    }
-
-    public void endTask() {
-        progress.setVisible(false);
-    }
-
-    public SwingWorker<?, ?> showNodeCapture() {
-        if (scene.getFocusedObject() == null) {
-            return null;
-        }
-        return new CaptureNodeTask();
-    }    
-
-    public SwingWorker<?, ?> startServer() {
-        return new StartServerTask();
-    }
-
-    public SwingWorker<?, ?> stopServer() {
-        return new StopServerTask();
-    }
-
-    public SwingWorker<?, ?> loadWindows() {
-        return new LoadWindowsTask();
-    }
-
-    public SwingWorker<?, ?> loadGraph() {
-        return new LoadGraphTask();
-    }
-
-    public SwingWorker<?, ?> invalidateView() {
-        if (scene.getFocusedObject() == null) {
-            return null;
-        }
-        return new InvalidateTask();
-    }
-
-    public SwingWorker<?, ?> requestLayout() {
-        if (scene.getFocusedObject() == null) {
-            return null;
-        }
-        return new RequestLayoutTask();
-    }
-
-    public SwingWorker<?, ?> saveSceneAsImage() {
-        JFileChooser chooser = new JFileChooser();
-        chooser.setFileFilter(new PngFileFilter());
-        int choice = chooser.showSaveDialog(sceneView);
-        if (choice == JFileChooser.APPROVE_OPTION) {
-            return new SaveSceneTask(chooser.getSelectedFile());
-        } else {
-            return null;
-        }
-    }
-
-    private class InvalidateTask extends SwingWorker<Object, Void> {
-        private String captureParams;
-
-        private InvalidateTask() {
-            captureParams = scene.getFocusedObject().toString();
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Object doInBackground() throws Exception {
-            ViewManager.invalidate(currentDevice, currentWindow, captureParams);
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            endTask();
-        }
-    }
-
-    private class RequestLayoutTask extends SwingWorker<Object, Void> {
-        private String captureParams;
-
-        private RequestLayoutTask() {
-            captureParams = scene.getFocusedObject().toString();
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Object doInBackground() throws Exception {
-            ViewManager.requestLayout(currentDevice, currentWindow, captureParams);
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            endTask();
-        }
-    }
-
-    private class CaptureNodeTask extends SwingWorker<Image, Void> {
-        private String captureParams;
-        private ViewNode node;
-
-        private CaptureNodeTask() {
-            node = (ViewNode) scene.getFocusedObject();
-            captureParams = node.toString();
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Image doInBackground() throws Exception {
-            node.image = CaptureLoader.loadCapture(currentDevice, currentWindow, captureParams);
-            return node.image;
-        }
-
-        @Override
-        protected void done() {
-            try {
-                Image image = get();
-                showCaptureWindow(node, captureParams, image);
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            } finally {
-                endTask();
-            }
-        }
-    }
-
-    private class LoadWindowsTask extends SwingWorker<Window[], Void> {
-        private LoadWindowsTask() {
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Window[] doInBackground() throws Exception {
-            return WindowsLoader.loadWindows(currentDevice);
-        }
-
-        @Override
-        protected void done() {
-            try {
-                windowsTableModel.clear();
-                windowsTableModel.addWindows(get());
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } finally {
-                endTask();
-            }
-        }
-    }
-
-    private class StartServerTask extends SwingWorker<Object, Void> {
-        public StartServerTask() {
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Object doInBackground() {
-            DeviceBridge.startViewServer(currentDevice);
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            new LoadWindowsTask().execute();
-            windowsTableModel.setVisible(true);
-            checkForServerOnCurrentDevice();
-            endTask();
-        }
-    }
-
-    private class StopServerTask extends SwingWorker<Object, Void> {
-        public StopServerTask() {
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Object doInBackground() {
-            DeviceBridge.stopViewServer(currentDevice);
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            windowsTableModel.setVisible(false);
-            windowsTableModel.clear();
-            checkForServerOnCurrentDevice();
-            endTask();
-        }
-    }
-
-    private class LoadGraphTask extends SwingWorker<ViewHierarchyScene, Void> {
-        public LoadGraphTask() {
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected ViewHierarchyScene doInBackground() {
-            scene = ViewHierarchyLoader.loadScene(currentDevice, currentWindow);
-            return scene;
-        }
-
-        @Override
-        protected void done() {
-            try {
-                createGraph(get());
-            } catch (InterruptedException e) {
-                e.printStackTrace();
-            } catch (ExecutionException e) {
-                e.printStackTrace();
-            } finally {
-                endTask();
-            }
-        }
-    }
-
-    private class SaveSceneTask extends SwingWorker<Object, Void> {
-        private File file;
-
-        private SaveSceneTask(File file) {
-            this.file = file;
-            beginTask();
-        }
-
-        @Override
-        @WorkerThread
-        protected Object doInBackground() {
-            if (sceneView == null) {
-                return null;
-            }
-
-            try {
-                BufferedImage image = new BufferedImage(sceneView.getWidth(),
-                        sceneView.getHeight(), BufferedImage.TYPE_INT_RGB);
-                Graphics2D g2 = image.createGraphics();
-                sceneView.paint(g2);
-                g2.dispose();
-                ImageIO.write(image, "PNG", file);
-            } catch (IOException ex) {
-                ex.printStackTrace();
-            }
-            return null;
-        }
-
-        @Override
-        protected void done() {
-            endTask();            
-        }
-    }
-
-    private class SceneFocusListener implements ObjectSceneListener {
-
-        public void objectAdded(ObjectSceneEvent arg0, Object arg1) {
-        }
-
-        public void objectRemoved(ObjectSceneEvent arg0, Object arg1) {
-        }
-
-        public void objectStateChanged(ObjectSceneEvent arg0, Object arg1,
-                ObjectState arg2, ObjectState arg3) {
-        }
-
-        public void selectionChanged(ObjectSceneEvent e, Set<Object> previousSelection,
-                Set<Object> newSelection) {
-        }
-
-        public void highlightingChanged(ObjectSceneEvent arg0, Set<Object> arg1, Set<Object> arg2) {
-        }
-
-        public void hoverChanged(ObjectSceneEvent arg0, Object arg1, Object arg2) {
-        }
-
-        public void focusChanged(ObjectSceneEvent e, Object oldFocus, Object newFocus) {
-            displayNodeButton.setEnabled(true);
-            invalidateButton.setEnabled(true);
-            requestLayoutButton.setEnabled(true);
-
-            Set<Object> selection = new HashSet<Object>();
-            selection.add(newFocus);
-            scene.setSelectedObjects(selection);
-
-            showProperties((ViewNode) newFocus);
-            layoutView.repaint();
-        }
-    }
-
-    private class NodeClickListener extends MouseAdapter {
-        @Override
-        public void mouseClicked(MouseEvent e) {
-            if (e.getClickCount() == 2) {
-                showNodeCapture().execute();
-            }
-        }
-    }
-
-    private class DevicesTableModel extends DefaultTableModel implements
-            AndroidDebugBridge.IDeviceChangeListener {
-
-        private ArrayList<Device> devices;
-
-        private DevicesTableModel() {
-            devices = new ArrayList<Device>();
-        }
-
-        @Override
-        public int getColumnCount() {
-            return 1;
-        }
-
-        @Override
-        public boolean isCellEditable(int row, int column) {
-            return false;
-        }
-
-        @Override
-        public Object getValueAt(int row, int column) {
-            return devices.get(row);
-        }
-
-        @Override
-        public String getColumnName(int column) {
-            return "Devices";
-        }
-
-        @WorkerThread
-        public void deviceConnected(final Device device) {
-            DeviceBridge.setupDeviceForward(device);
-
-            SwingUtilities.invokeLater(new Runnable() {
-                public void run() {
-                    addDevice(device);
-                }
-            });
-        }
-
-        @WorkerThread
-        public void deviceDisconnected(final Device device) {
-            DeviceBridge.removeDeviceForward(device);
-
-            SwingUtilities.invokeLater(new Runnable() {
-                public void run() {
-                    removeDevice(device);
-                }
-            });
-        }
-
-        public void addDevice(Device device) {
-            if (!devices.contains(device)) {
-                devices.add(device);
-                fireTableDataChanged();
-            }
-        }
-
-        public void removeDevice(Device device) {
-            if (device.equals(currentDevice)) {
-                reset();
-            }
-
-            if (devices.contains(device)) {
-                devices.remove(device);
-                fireTableDataChanged();
-            }
-        }
-
-        @WorkerThread
-        public void deviceChanged(Device device, int changeMask) {
-            if ((changeMask & Device.CHANGE_STATE) != 0 &&
-                    device.isOnline()) {
-                // if the device state changed and it's now online, we set up its port forwarding.
-                DeviceBridge.setupDeviceForward(device);
-            } else if (device == currentDevice && (changeMask & Device.CHANGE_CLIENT_LIST) != 0) {
-                // if the changed device is the current one and the client list changed, we update
-                // the UI.
-                loadWindows().execute();
-                windowsTableModel.setVisible(true);
-            }
-        }
-
-        @Override
-        public int getRowCount() {
-            return devices == null ? 0 : devices.size();
-        }
-
-        public Device getDevice(int index) {
-            return index < devices.size() ? devices.get(index) : null;
-        }
-
-        public Device[] getDevices() {
-            return devices.toArray(new Device[devices.size()]);
-        }
-    }
-
-    private static class WindowsTableModel extends DefaultTableModel {
-        private ArrayList<Window> windows;
-        private boolean visible;
-
-        private WindowsTableModel() {
-            windows = new ArrayList<Window>();
-            windows.add(Window.FOCUSED_WINDOW);
-        }
-
-        @Override
-        public int getColumnCount() {
-            return 1;
-        }
-
-        @Override
-        public boolean isCellEditable(int row, int column) {
-            return false;
-        }
-
-        @Override
-        public String getColumnName(int column) {
-            return "Windows";
-        }
-
-        @Override
-        public Object getValueAt(int row, int column) {
-            return windows.get(row);
-        }
-
-        @Override
-        public int getRowCount() {
-            return !visible || windows == null ? 0 : windows.size();
-        }
-
-        public void setVisible(boolean visible) {
-            this.visible = visible;
-            fireTableDataChanged();
-        }
-
-        public void addWindow(Window window) {
-            windows.add(window);
-            fireTableDataChanged();
-        }
-
-        public void addWindows(Window[] windowsList) {
-            //noinspection ManualArrayToCollectionCopy
-            for (Window window : windowsList) {
-                windows.add(window);
-            }
-            fireTableDataChanged();
-        }
-
-        public void clear() {
-            windows.clear();
-            windows.add(Window.FOCUSED_WINDOW);            
-        }
-
-        public Window getWindow(int index) {
-            return windows.get(index);
-        }
-    }
-
-    private class DeviceSelectedListener implements ListSelectionListener {
-        public void valueChanged(ListSelectionEvent event) {
-            if (event.getValueIsAdjusting()) {
-                return;
-            }
-
-            int row = devices.getSelectedRow();
-            if (row >= 0) {
-                currentDevice = devicesTableModel.getDevice(row);
-                currentDeviceChanged();
-                if (currentDevice != null) {
-                    if (!DeviceBridge.isViewServerRunning(currentDevice)) {
-                        DeviceBridge.startViewServer(currentDevice);
-                        checkForServerOnCurrentDevice();                        
-                    }
-                    loadWindows().execute();
-                    windowsTableModel.setVisible(true);
-                }
-            } else {
-                currentDevice = null;
-                currentDeviceChanged();
-                windowsTableModel.setVisible(false);
-                windowsTableModel.clear();
-            }
-        }
-    }
-
-    private class WindowSelectedListener implements ListSelectionListener {
-        public void valueChanged(ListSelectionEvent event) {
-            if (event.getValueIsAdjusting()) {
-                return;
-            }
-
-            int row = windows.getSelectedRow();
-            if (row >= 0) {
-                currentWindow = windowsTableModel.getWindow(row);
-            } else {
-                currentWindow = Window.FOCUSED_WINDOW;
-            }
-        }
-    }
-
-    private static class ViewsTreeCellRenderer extends DefaultTreeCellRenderer {
-        public Component getTreeCellRendererComponent(JTree tree, Object value, boolean selected,
-                boolean expanded, boolean leaf, int row, boolean hasFocus) {
-
-            final String name = ((ViewNode) value).name;
-            value = name.substring(name.lastIndexOf('.') + 1, name.lastIndexOf('@'));
-            return super.getTreeCellRendererComponent(tree, value, selected, expanded,
-                    leaf, row, hasFocus);
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/BackgroundAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/BackgroundAction.java
deleted file mode 100644
index 051e3f3..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/BackgroundAction.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import org.jdesktop.swingworker.SwingWorker;
-
-import javax.swing.AbstractAction;
-
-public abstract class BackgroundAction extends AbstractAction {
-    protected void executeBackgroundTask(SwingWorker<?, ?> worker) {
-        if (worker != null) {
-            worker.execute();
-        }
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/CaptureNodeAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/CaptureNodeAction.java
deleted file mode 100644
index a8aee3c..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/CaptureNodeAction.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class CaptureNodeAction extends BackgroundAction {
-    public static final String ACTION_NAME = "captureNode";
-    private Workspace mWorkspace;
-
-    public CaptureNodeAction(Workspace workspace) {
-        putValue(NAME, "Display View");
-        putValue(SHORT_DESCRIPTION, "Display View");
-        putValue(LONG_DESCRIPTION, "Display View");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_D,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.showNodeCapture());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ExitAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ExitAction.java
deleted file mode 100644
index e5aaed5..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ExitAction.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-import com.android.hierarchyviewer.device.DeviceBridge;
-
-import javax.swing.AbstractAction;
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class ExitAction extends AbstractAction {
-    public static final String ACTION_NAME = "exit";
-    private Workspace mWorkspace;
-
-    public ExitAction(Workspace workspace) {
-        putValue(NAME, "Quit");
-        putValue(SHORT_DESCRIPTION, "Quit");
-        putValue(LONG_DESCRIPTION, "Quit");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_Q);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_Q,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        mWorkspace.cleanupDevices();
-        mWorkspace.dispose();
-        DeviceBridge.terminate();
-        System.exit(0);
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/InvalidateAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/InvalidateAction.java
deleted file mode 100644
index 7767cda..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/InvalidateAction.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class InvalidateAction extends BackgroundAction {
-    public static final String ACTION_NAME = "invalidate";
-    private Workspace mWorkspace;
-
-    public InvalidateAction(Workspace workspace) {
-        putValue(NAME, "Invalidate");
-        putValue(SHORT_DESCRIPTION, "Invalidate");
-        putValue(LONG_DESCRIPTION, "Invalidate");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_I,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.invalidateView());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/LoadGraphAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/LoadGraphAction.java
deleted file mode 100644
index 42c8b8e..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/LoadGraphAction.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class LoadGraphAction extends BackgroundAction {
-    public static final String ACTION_NAME = "loadGraph";
-    private Workspace mWorkspace;
-
-    public LoadGraphAction(Workspace workspace) {
-        putValue(NAME, "Load View Hierarchy");
-        putValue(SHORT_DESCRIPTION, "Load");
-        putValue(LONG_DESCRIPTION, "Load View Hierarchy");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_L);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_L,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.loadGraph());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RefreshWindowsAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RefreshWindowsAction.java
deleted file mode 100644
index bcb7ea7..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RefreshWindowsAction.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-
-public class RefreshWindowsAction extends BackgroundAction {
-    public static final String ACTION_NAME = "refreshWindows";
-    private Workspace mWorkspace;
-
-    public RefreshWindowsAction(Workspace workspace) {
-        putValue(NAME, "Refresh Windows");
-        putValue(SHORT_DESCRIPTION, "Refresh");
-        putValue(LONG_DESCRIPTION, "Refresh Windows");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_F7, 0));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.loadWindows());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RequestLayoutAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RequestLayoutAction.java
deleted file mode 100644
index 6fc2832..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/RequestLayoutAction.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class RequestLayoutAction extends BackgroundAction {
-    public static final String ACTION_NAME = "requestLayout";
-    private Workspace mWorkspace;
-
-    public RequestLayoutAction(Workspace workspace) {
-        putValue(NAME, "Request Layout");
-        putValue(SHORT_DESCRIPTION, "Request Layout");
-        putValue(LONG_DESCRIPTION, "Request Layout");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_R,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.requestLayout());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/SaveSceneAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/SaveSceneAction.java
deleted file mode 100644
index 7c7a8a9..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/SaveSceneAction.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class SaveSceneAction extends BackgroundAction {
-    public static final String ACTION_NAME = "saveScene";
-    private Workspace mWorkspace;
-
-    public SaveSceneAction(Workspace workspace) {
-        mWorkspace = workspace;
-        putValue(NAME, "Save as PNG...");
-        putValue(SHORT_DESCRIPTION, "Save");
-        putValue(LONG_DESCRIPTION, "Save as PNG...");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_S);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_S,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.saveSceneAsImage());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ShowDevicesAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ShowDevicesAction.java
deleted file mode 100644
index a91ab7a..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/ShowDevicesAction.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.AbstractAction;
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-import java.awt.Toolkit;
-
-public class ShowDevicesAction extends AbstractAction {
-    public static final String ACTION_NAME = "showDevices";
-    private Workspace mWorkspace;
-
-    public ShowDevicesAction(Workspace workspace) {
-        putValue(NAME, "Devices");
-        putValue(SHORT_DESCRIPTION, "Devices");
-        putValue(LONG_DESCRIPTION, "Show Devices");
-        putValue(MNEMONIC_KEY, KeyEvent.VK_D);
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_D,
-                Toolkit.getDefaultToolkit().getMenuShortcutKeyMask()));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        mWorkspace.showDevicesSelector();
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StartServerAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StartServerAction.java
deleted file mode 100644
index ccb6ae0..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StartServerAction.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-
-public class StartServerAction extends BackgroundAction {
-    public static final String ACTION_NAME = "startServer";
-    private Workspace mWorkspace;
-
-    public StartServerAction(Workspace workspace) {
-        putValue(NAME, "Start Server");
-        putValue(SHORT_DESCRIPTION, "Start");
-        putValue(LONG_DESCRIPTION, "Start Server");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_F5, 0));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.startServer());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StopServerAction.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StopServerAction.java
deleted file mode 100644
index ac76e14..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/action/StopServerAction.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.action;
-
-import com.android.hierarchyviewer.ui.Workspace;
-
-import javax.swing.KeyStroke;
-import java.awt.event.KeyEvent;
-import java.awt.event.ActionEvent;
-
-public class StopServerAction extends BackgroundAction {
-    public static final String ACTION_NAME = "stopServer";
-    private Workspace mWorkspace;
-
-    public StopServerAction(Workspace workspace) {
-        putValue(NAME, "Stop Server");
-        putValue(SHORT_DESCRIPTION, "Stop");
-        putValue(LONG_DESCRIPTION, "Stop Server");
-        putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_F6, 0));
-        this.mWorkspace = workspace;
-    }
-
-    public void actionPerformed(ActionEvent e) {
-        executeBackgroundTask(mWorkspace.stopServer());
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/PropertiesTableModel.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/PropertiesTableModel.java
deleted file mode 100644
index cc4f7e3..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/PropertiesTableModel.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.model;
-
-import com.android.hierarchyviewer.scene.ViewNode;
-
-import javax.swing.table.DefaultTableModel;
-import java.util.List;
-import java.util.ArrayList;
-
-public class PropertiesTableModel extends DefaultTableModel {
-    private List<ViewNode.Property> properties;
-    private List<ViewNode.Property> privateProperties = new ArrayList<ViewNode.Property>();
-
-    public PropertiesTableModel(ViewNode node) {
-        properties = node.properties;
-        loadPrivateProperties(node);
-    }
-
-    private void loadPrivateProperties(ViewNode node) {
-        int x = node.left;
-        int y = node.top;
-        ViewNode p = node.parent;
-        while (p != null) {
-            x += p.left - p.scrollX;
-            y += p.top - p.scrollY;
-            p = p.parent;
-        }
-
-        ViewNode.Property property = new ViewNode.Property();
-        property.name = "absolute_x";
-        property.value = String.valueOf(x);
-        privateProperties.add(property);
-
-        property = new ViewNode.Property();
-        property.name = "absolute_y";
-        property.value = String.valueOf(y);
-        privateProperties.add(property);
-    }
-
-    @Override
-    public int getRowCount() {
-        return (privateProperties == null ? 0 : privateProperties.size()) +
-                (properties == null ? 0 : properties.size());
-    }
-
-    @Override
-    public Object getValueAt(int row, int column) {
-        ViewNode.Property property;
-
-        if (row < privateProperties.size()) {
-            property = privateProperties.get(row);
-        } else {
-            property = properties.get(row - privateProperties.size());
-        }
-
-        return column == 0 ? property.name : property.value;
-    }
-
-    @Override
-    public int getColumnCount() {
-        return 2;
-    }
-
-    @Override
-    public String getColumnName(int column) {
-        return column == 0 ? "Property" : "Value";
-    }
-
-    @Override
-    public boolean isCellEditable(int arg0, int arg1) {
-        return false;
-    }
-
-    @Override
-    public void setValueAt(Object arg0, int arg1, int arg2) {
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/ViewsTreeModel.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/ViewsTreeModel.java
deleted file mode 100644
index f3a07f8..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/model/ViewsTreeModel.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.model;
-
-import com.android.hierarchyviewer.scene.ViewNode;
-
-import javax.swing.tree.TreeModel;
-import javax.swing.tree.TreePath;
-import javax.swing.event.TreeModelListener;
-
-public class ViewsTreeModel implements TreeModel {
-    private final ViewNode root;
-
-    public ViewsTreeModel(ViewNode root) {
-        this.root = root;
-    }
-
-    public Object getRoot() {
-        return root;
-    }
-
-    public Object getChild(Object o, int i) {
-        return ((ViewNode) o).children.get(i);
-    }
-
-    public int getChildCount(Object o) {
-        return ((ViewNode) o).children.size();
-    }
-
-    public boolean isLeaf(Object child) {
-        ViewNode node = (ViewNode) child;
-        return node.children == null || node.children.size() == 0;
-    }
-
-    public void valueForPathChanged(TreePath treePath, Object child) {
-    }
-
-    public int getIndexOfChild(Object parent, Object child) {
-        //noinspection SuspiciousMethodCalls
-        return ((ViewNode) parent).children.indexOf(child);
-    }
-
-    public void addTreeModelListener(TreeModelListener treeModelListener) {
-    }
-
-    public void removeTreeModelListener(TreeModelListener treeModelListener) {
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/IconLoader.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/IconLoader.java
deleted file mode 100644
index ef73956..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/IconLoader.java
+++ /dev/null
@@ -1,49 +0,0 @@
-package com.android.hierarchyviewer.ui.util;
-
-import javax.swing.Icon;
-import javax.swing.ImageIcon;
-import javax.imageio.ImageIO;
-import java.io.IOException;
-import java.awt.image.BufferedImage;
-import java.awt.Graphics;
-import java.awt.GraphicsEnvironment;
-import java.awt.GraphicsConfiguration;
-
-public class IconLoader {
-    public static Icon load(Class<?> klass, String path) {
-        try {
-            return new ImageIcon(ImageIO.read(klass.getResourceAsStream(path)));
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-        return null;
-    }
-
-    private static GraphicsConfiguration getGraphicsConfiguration() {
-        GraphicsEnvironment environment = GraphicsEnvironment.getLocalGraphicsEnvironment();
-        return environment.getDefaultScreenDevice().getDefaultConfiguration();
-    }
-
-    private static boolean isHeadless() {
-        return GraphicsEnvironment.isHeadless();
-    }
-
-    public static BufferedImage toCompatibleImage(BufferedImage image) {
-        if (isHeadless()) {
-            return image;
-        }
-
-        if (image.getColorModel().equals(
-                getGraphicsConfiguration().getColorModel())) {
-            return image;
-        }
-
-        BufferedImage compatibleImage = getGraphicsConfiguration().createCompatibleImage(
-                    image.getWidth(), image.getHeight(), image.getTransparency());
-        Graphics g = compatibleImage.getGraphics();
-        g.drawImage(image, 0, 0, null);
-        g.dispose();
-
-        return compatibleImage;
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/PngFileFilter.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/PngFileFilter.java
deleted file mode 100644
index 5d6472d..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/ui/util/PngFileFilter.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.ui.util;
-
-import javax.swing.filechooser.FileFilter;
-import java.io.File;
-
-public class PngFileFilter extends FileFilter {
-    @Override
-    public boolean accept(File f) {
-        return f.isDirectory() || f.getName().toLowerCase().endsWith(".png");
-    }
-
-    @Override
-    public String getDescription() {
-        return "PNG Image (*.png)";
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/OS.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/OS.java
deleted file mode 100644
index fd619d6..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/OS.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.util;
-
-public class OS {
-    private static boolean macOs;
-    private static boolean leopard;
-    private static boolean linux;
-    private static boolean windows;
-
-    static {
-        String osName = System.getProperty("os.name");
-        macOs = "Mac OS X".startsWith(osName);
-        linux = "Linux".startsWith(osName);
-        windows = "Windows".startsWith(osName);
-
-        String version = System.getProperty("os.version");
-        final String[] parts = version.split("\\.");
-        leopard = Integer.parseInt(parts[0]) >= 10 && Integer.parseInt(parts[1]) >= 5;
-    }
-
-    public static boolean isMacOsX() {
-        return macOs;
-    }
-
-    public static boolean isLeopardOrLater() {
-        return leopard;
-    }
-
-    public static boolean isLinux() {
-        return linux;
-    }
-
-    public static boolean isWindows() {
-        return windows;
-    }
-}
diff --git a/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/WorkerThread.java b/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/WorkerThread.java
deleted file mode 100644
index c714c1c..0000000
--- a/tools/hierarchyviewer/src/com/android/hierarchyviewer/util/WorkerThread.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.hierarchyviewer.util;
-
-import java.lang.annotation.Target;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-
-/**
- * Simple utility class used only to mark methods that are not executed on the UI thread
- * (or Event Dispatch Thread in Swing/AWT.) This annotation's sole purpose is to help
- * reading the source code. It has no additional effect.
- */
-@Target({ ElementType.METHOD })
-@Retention(RetentionPolicy.SOURCE)
-public @interface WorkerThread {
-}
diff --git a/tools/hierarchyviewer/src/resources/images/icon-graph-view-selected.png b/tools/hierarchyviewer/src/resources/images/icon-graph-view-selected.png
deleted file mode 100644
index 91f7119..0000000
--- a/tools/hierarchyviewer/src/resources/images/icon-graph-view-selected.png
+++ /dev/null
Binary files differ
diff --git a/tools/hierarchyviewer/src/resources/images/icon-graph-view.png b/tools/hierarchyviewer/src/resources/images/icon-graph-view.png
deleted file mode 100644
index 9a7f68b..0000000
--- a/tools/hierarchyviewer/src/resources/images/icon-graph-view.png
+++ /dev/null
Binary files differ
diff --git a/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view-selected.png b/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view-selected.png
deleted file mode 100644
index 1e44000..0000000
--- a/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view-selected.png
+++ /dev/null
Binary files differ
diff --git a/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view.png b/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view.png
deleted file mode 100644
index ec51cec..0000000
--- a/tools/hierarchyviewer/src/resources/images/icon-pixel-perfect-view.png
+++ /dev/null
Binary files differ
diff --git a/tools/idegen/Android.mk b/tools/idegen/Android.mk
deleted file mode 100644
index e76e5b4..0000000
--- a/tools/idegen/Android.mk
+++ /dev/null
@@ -1,10 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_MODULE:= idegen
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/idegen/README b/tools/idegen/README
deleted file mode 100644
index 1f773d8..0000000
--- a/tools/idegen/README
+++ /dev/null
@@ -1,80 +0,0 @@
-IDEGen automatically generates Android IDE configurations for IntelliJ IDEA
-and Eclipse. Your IDE should be able to compile everything in a reasonable
-amount of time with no errors.
-
-If you're using IntelliJ...
-
-    If this is your first time using IDEGen...
-
-        IDEA needs a lot of memory. Add "-Xms748m -Xmx748m" to your VM options
-        in "IDEA_HOME/bin/idea.vmoptions" on Linux or 
-        "IntelliJ IDEA.app/Contents/Info.plist" on OS X.
-
-        Create a JDK configuration named "1.5 (No Libraries)" by adding a new
-        JDK like you normally would and then removing all of the jar entries
-        under the "Classpath" tab. This will ensure that you only get access to
-        Android's core libraries and not those from your desktop VM.
-
-    From the project's root directory...
-
-        Repeat these steps after each sync...
-        
-        1) make (to produce generated .java source)
-        2) development/tools/idegen/idegen.sh
-        3) Open android.ipr in IntelliJ. If you already have the project open,
-           hit the sync button in IntelliJ, and it will automatically detect the
-           updated configuration.
-        
-        If you get unexpected compilation errors from IntelliJ, try running
-        "Build -> Rebuild Project". Sometimes IntelliJ gets confused after the
-        project changes significantly.
-
-If you're using Eclipse...
-
-    If this is your first time using IDEGen...
-
-        Edit eclipse.ini ("Eclipse.app/Contents/MacOS/eclipse.ini" on OS X) and
-        add "-Xms748m -Xmx748m" to your VM options.
-
-        Configure a JRE named "1.5 (No Libraries)" under "Preferences -> Java ->
-        Installed JREs". Remove all of the jar entries underneath "JRE system
-        libraries". Eclipse will not let you save your configuration unless at
-        least one jar is present, so include a random jar that won't get in the
-        way.
-
-    From the project's root directory...
-
-        Repeat these steps after each sync...
-
-        1) make (to produce generated .java source)
-        2) development/tools/idegen/idegen.sh
-        3) Import the project root directory into your Eclipse workspace. If you
-           already have the project open, simply refresh it (F5).
-
-Excluding source roots and jars
-
-    IDEGen keeps an exclusion list in the "excluded-paths" file. This file 
-    has one regular expression per line that matches paths (relative to the
-    project root) that should be excluded from the IDE configuration. We
-    use Java's regular expression parser (see java.util.regex.Parser).
-
-    You can create your own additional exclusion list by creating an
-    "excluded-paths" file in the project's root directory. For example, you
-    might exclude all apps except the Browser in your IDE configuration with
-    this regular expression: "^packages/apps/(?!Browser)".
-    
-Controlling source root ordering (Eclipse)
-
-    You may want some source roots to come before others in Eclipse. Simply
-    create a file named "path-precedence" in your project's root directory.
-    Each line in the file is a regular expression that matches a source root
-    path (relative to the project's root directory). If a given source root's
-    path matches a regular expression that comes earlier in the file, that
-    source root will come earlier in the generated configuration. If a source
-    root doesn't match any of the expressions in the file, it will come last,
-    so you effectively have an implicit ".*" rule at the end of the file.
-
-    For example, if you want your applications's source root to come first,
-    you might add an expression like "^packages/apps/MyApp/src$" to the top
-    of the "path-precedence" file.  To make source roots under ./out come last,
-    add "^(?!out/)" (which matches all paths that don't start with "out/").
\ No newline at end of file
diff --git a/tools/idegen/excluded-paths b/tools/idegen/excluded-paths
deleted file mode 100644
index 35280ad..0000000
--- a/tools/idegen/excluded-paths
+++ /dev/null
@@ -1,64 +0,0 @@
-# Default Idegen excluded paths file. Contains regular expressions, one per
-# line, which match paths of directories and .jar files that should be excluded
-# from the IDE configuration.
-#
-# We want to exclude as litte as possible by default, so it's important to
-# document the reason for each exclusion.
-#
-# Developers can also create an 'excluded-paths' file in the project's root
-# directory and add their own excludes to slim down their build.
-#
-# Currently, we lump all the .java files together into one big module, so you
-# can't have two classes with the same name at once. In the future, we'll
-# generate individual modules, each with their own dependencies, much like the
-# build, so we won't have to worry about duplicate names any more than the
-# build does.
-#
-# Note: Google-specific excludes go in vendor/google/excluded-paths.
-
-# Generated API stubs. We only want the originals in our IDE.
-android_stubs
-
-# Extra copies of JUnit.
-^dalvik/dx/src/junit$
-^dalvik/libcore/luni/src/test/java/junit$
-
-# Duplicate R.java files. We'll keep the versions from the "intermediates"
-# directories.
-^out/target/common/R$
-
-# Not actually built. Also disabled in make file.
-^development/samples/MySampleRss$
-^development/apps/OBJViewer$
-^packages/apps/IM/samples/PluginDemo$
-
-# We don't currently support development tool source code. Development tools
-# typically have their own IDE configurations anyway.
-#
-# The main problem is that the development tools are meant to run against a
-# fully featured desktop VM while almost everything in our IDE configuration
-# is meant to run against Android's more limited APIs. Mixing the two
-# environments in one IDE configuration doesn't work well.
-^development/tools$
-^external/jdiff$
-^external/emma$
-^external/clearsilver$
-layoutlib
-^prebuilt/.*\.jar$
-^dalvik/.*\.jar$
-^build/tools/droiddoc$
-
-# Each test has a Main.java in the default package, so they conflict with
-# each other.
-^dalvik/tests$
-
-# We can only support one policy impl at a time.
-^frameworks/policies/base/mid$
-#^frameworks/policies/base/phone$
-
-# We don't want compiled jars.
-^out/.*\.jar$
-
-# This directory contains only an R.java file which is the same as the one in
-# Camera_intermediates.
-^out/target/common/obj/APPS/CameraTests_intermediates$
diff --git a/tools/idegen/idegen.iml b/tools/idegen/idegen.iml
deleted file mode 100644
index 04646ae..0000000
--- a/tools/idegen/idegen.iml
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module relativePaths="true" type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="false">
-    <output url="file://$MODULE_DIR$/classes" />
-    <output-test url="file://$MODULE_DIR$/classes" />
-    <exclude-output />
-    <content url="file://$MODULE_DIR$">
-      <sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
-    </content>
-    <orderEntry type="inheritedJdk" />
-    <orderEntry type="sourceFolder" forTests="false" />
-  </component>
-</module>
-
diff --git a/tools/idegen/idegen.ipr b/tools/idegen/idegen.ipr
deleted file mode 100644
index 00cf4fd..0000000
--- a/tools/idegen/idegen.ipr
+++ /dev/null
@@ -1,330 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project relativePaths="false" version="4">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-  </component>
-  <component name="BuildJarProjectSettings">
-    <option name="BUILD_JARS_ON_MAKE" value="false" />
-  </component>
-  <component name="CodeStyleProjectProfileManger">
-    <option name="PROJECT_PROFILE" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-  </component>
-  <component name="CodeStyleSettingsManager">
-    <option name="PER_PROJECT_SETTINGS">
-      <value>
-        <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
-        <option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="1000" />
-        <option name="RIGHT_MARGIN" value="80" />
-        <option name="BINARY_OPERATION_SIGN_ON_NEXT_LINE" value="true" />
-        <option name="PLACE_ASSIGNMENT_SIGN_ON_NEXT_LINE" value="true" />
-        <ADDITIONAL_INDENT_OPTIONS fileType="java">
-          <option name="INDENT_SIZE" value="4" />
-          <option name="CONTINUATION_INDENT_SIZE" value="8" />
-          <option name="TAB_SIZE" value="4" />
-          <option name="USE_TAB_CHARACTER" value="false" />
-          <option name="SMART_TABS" value="false" />
-          <option name="LABEL_INDENT_SIZE" value="0" />
-          <option name="LABEL_INDENT_ABSOLUTE" value="false" />
-        </ADDITIONAL_INDENT_OPTIONS>
-        <ADDITIONAL_INDENT_OPTIONS fileType="xml">
-          <option name="INDENT_SIZE" value="4" />
-          <option name="CONTINUATION_INDENT_SIZE" value="8" />
-          <option name="TAB_SIZE" value="4" />
-          <option name="USE_TAB_CHARACTER" value="false" />
-          <option name="SMART_TABS" value="false" />
-          <option name="LABEL_INDENT_SIZE" value="0" />
-          <option name="LABEL_INDENT_ABSOLUTE" value="false" />
-        </ADDITIONAL_INDENT_OPTIONS>
-      </value>
-    </option>
-    <option name="USE_PER_PROJECT_SETTINGS" value="true" />
-  </component>
-  <component name="CompilerConfiguration">
-    <option name="DEFAULT_COMPILER" value="Javac" />
-    <option name="DEPLOY_AFTER_MAKE" value="0" />
-    <resourceExtensions>
-      <entry name=".+\.(properties|xml|html|dtd|tld)" />
-      <entry name=".+\.(gif|png|jpeg|jpg)" />
-    </resourceExtensions>
-    <wildcardResourcePatterns>
-      <entry name="?*.properties" />
-      <entry name="?*.xml" />
-      <entry name="?*.gif" />
-      <entry name="?*.png" />
-      <entry name="?*.jpeg" />
-      <entry name="?*.jpg" />
-      <entry name="?*.html" />
-      <entry name="?*.dtd" />
-      <entry name="?*.tld" />
-    </wildcardResourcePatterns>
-  </component>
-  <component name="DependenciesAnalyzeManager">
-    <option name="myForwardDirection" value="false" />
-  </component>
-  <component name="DependencyValidationManager">
-    <option name="SKIP_IMPORT_STATEMENTS" value="false" />
-  </component>
-  <component name="EclipseCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EclipseEmbeddedCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
-  <component name="EntryPointsManager">
-    <entry_points />
-  </component>
-  <component name="ExportToHTMLSettings">
-    <option name="PRINT_LINE_NUMBERS" value="false" />
-    <option name="OPEN_IN_BROWSER" value="false" />
-    <option name="OUTPUT_DIRECTORY" />
-  </component>
-  <component name="IdProvider" IDEtalkID="D171F99B9178C1675593DC9A76A5CC7E" />
-  <component name="InspectionProjectProfileManager">
-    <option name="PROJECT_PROFILE" value="Project Default" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-    <scopes />
-    <profiles>
-      <profile version="1.0" is_locked="false">
-        <option name="myName" value="Project Default" />
-        <option name="myLocal" value="false" />
-        <inspection_tool class="JavaDoc" level="WARNING" enabled="false">
-          <option name="TOP_LEVEL_CLASS_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="INNER_CLASS_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="METHOD_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="@return@param@throws or @exception" />
-            </value>
-          </option>
-          <option name="FIELD_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="IGNORE_DEPRECATED" value="false" />
-          <option name="IGNORE_JAVADOC_PERIOD" value="true" />
-          <option name="myAdditionalJavadocTags" value="" />
-        </inspection_tool>
-      </profile>
-    </profiles>
-    <list size="0" />
-  </component>
-  <component name="JavacSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="DEPRECATION" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="JavadocGenerationManager">
-    <option name="OUTPUT_DIRECTORY" />
-    <option name="OPTION_SCOPE" value="protected" />
-    <option name="OPTION_HIERARCHY" value="true" />
-    <option name="OPTION_NAVIGATOR" value="true" />
-    <option name="OPTION_INDEX" value="true" />
-    <option name="OPTION_SEPARATE_INDEX" value="true" />
-    <option name="OPTION_DOCUMENT_TAG_USE" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_AUTHOR" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_VERSION" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
-    <option name="OPTION_DEPRECATED_LIST" value="true" />
-    <option name="OTHER_OPTIONS" value="" />
-    <option name="HEAP_SIZE" />
-    <option name="LOCALE" />
-    <option name="OPEN_IN_BROWSER" value="true" />
-  </component>
-  <component name="JikesSettings">
-    <option name="JIKES_PATH" value="" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="DEPRECATION" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="IS_EMACS_ERRORS_MODE" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="LogConsolePreferences">
-    <option name="FILTER_ERRORS" value="false" />
-    <option name="FILTER_WARNINGS" value="false" />
-    <option name="FILTER_INFO" value="true" />
-    <option name="CUSTOM_FILTER" />
-  </component>
-  <component name="Palette2">
-    <group name="Swing">
-      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
-      </item>
-      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
-        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
-        <initial-values>
-          <property name="text" value="Button" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="RadioButton" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="CheckBox" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="Label" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
-          <preferred-size width="-1" height="20" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
-      </item>
-    </group>
-  </component>
-  <component name="ProjectDetails">
-    <option name="projectName" value="idegen" />
-  </component>
-  <component name="ProjectFileVersion" converted="true" />
-  <component name="ProjectModuleManager">
-    <modules>
-      <module fileurl="file://$PROJECT_DIR$/idegen.iml" filepath="$PROJECT_DIR$/idegen.iml" />
-    </modules>
-  </component>
-  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_5" assert-keyword="true" jdk-15="true" project-jdk-name="1.5" project-jdk-type="JavaSDK">
-    <output url="file://$PROJECT_DIR$/classes" />
-  </component>
-  <component name="RmicSettings">
-    <option name="IS_EANABLED" value="false" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="GENERATE_IIOP_STUBS" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="SvnBranchConfigurationManager">
-    <option name="myVersion" value="124" />
-  </component>
-  <component name="VcsDirectoryMappings">
-    <mapping directory="" vcs="Perforce" />
-  </component>
-  <component name="com.intellij.jsf.UserDefinedFacesConfigs">
-    <option name="USER_DEFINED_CONFIGS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </component>
-  <component name="uidesigner-configuration">
-    <option name="INSTRUMENT_CLASSES" value="true" />
-    <option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />
-    <option name="DEFAULT_LAYOUT_MANAGER" value="GridLayoutManager" />
-  </component>
-</project>
-
diff --git a/tools/idegen/idegen.sh b/tools/idegen/idegen.sh
deleted file mode 100755
index d7e6986..0000000
--- a/tools/idegen/idegen.sh
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/bash
-
-if [ ! -d development ]; then
-    echo "Error: Run from the root of the tree."
-    exit 1
-fi
-
-idegenjar=`find out -name idegen.jar -follow | grep -v intermediates`
-if [ "" = "$idegenjar" ]; then
-    echo "Couldn't find idegen.jar. Please run make first."
-else 
-    java -cp $idegenjar Main
-fi
diff --git a/tools/idegen/src/Configuration.java b/tools/idegen/src/Configuration.java
deleted file mode 100644
index 392cb5d..0000000
--- a/tools/idegen/src/Configuration.java
+++ /dev/null
@@ -1,263 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.io.BufferedReader;
-import java.io.FileReader;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import java.util.Set;
-import java.util.TreeSet;
-import java.util.SortedSet;
-import java.util.regex.Pattern;
-
-/**
- * Immutable representation of an IDE configuration. Assumes that the current
- * directory is the project's root directory.
- */
-public class Configuration {
-
-    /** Java source tree roots. */
-    public final SortedSet<File> sourceRoots;
-
-    /** Found .jar files (that weren't excluded). */
-    public final List<File> jarFiles;
-
-    /** Excluded directories which may or may not be under a source root. */
-    public final SortedSet<File> excludedDirs;
-
-    /** The root directory for this tool. */
-    public final File toolDirectory;
-
-    /** File name used for excluded path files. */
-    private static final String EXCLUDED_PATHS = "excluded-paths";
-
-    /**
-     * Constructs a Configuration by traversing the directory tree, looking
-     * for .java and .jar files and identifying source roots.
-     */
-    public Configuration() throws IOException {
-        this.toolDirectory = new File("development/tools/idegen");
-        if (!toolDirectory.isDirectory()) {
-            // The wrapper script should have already verified this.
-            throw new AssertionError("Not in root directory.");
-        }
-
-        Stopwatch stopwatch = new Stopwatch();
-
-        Excludes excludes = readExcludes();
-
-        stopwatch.reset("Read excludes");
-
-        List<File> jarFiles = new ArrayList<File>(500);
-        SortedSet<File> excludedDirs = new TreeSet<File>();
-        SortedSet<File> sourceRoots = new TreeSet<File>();
-
-        traverse(new File("."), sourceRoots, jarFiles, excludedDirs, excludes);
-
-        stopwatch.reset("Traversed tree");
-
-        Log.debug(sourceRoots.size() + " source roots");
-        Log.debug(jarFiles.size() + " jar files");
-        Log.debug(excludedDirs.size() + " excluded dirs");
-
-        this.sourceRoots = Collections.unmodifiableSortedSet(sourceRoots);
-        this.jarFiles = Collections.unmodifiableList(jarFiles);
-        this.excludedDirs = Collections.unmodifiableSortedSet(excludedDirs);
-    }
-
-    /**
-     * Reads excluded path files.
-     */
-    private Excludes readExcludes() throws IOException {
-        List<Pattern> patterns = new ArrayList<Pattern>();
-
-        File globalExcludes = new File(toolDirectory, EXCLUDED_PATHS);
-        parseFile(globalExcludes, patterns);
-
-        // Look for Google-specific excludes.
-        // TODO: Traverse all vendor-specific directories.
-        File googleExcludes = new File("./vendor/google/" + EXCLUDED_PATHS);
-        if (googleExcludes.exists()) {
-            parseFile(googleExcludes, patterns);
-        }
-
-        // Look for user-specific excluded-paths file in current directory.
-        File localExcludes = new File(EXCLUDED_PATHS);
-        if (localExcludes.exists()) {
-            parseFile(localExcludes, patterns);
-        }
-
-        return new Excludes(patterns);
-    }
-
-    /**
-     * Recursively finds .java source roots, .jar files, and excluded
-     * directories.
-     */
-    private static void traverse(File directory, Set<File> sourceRoots,
-            Collection<File> jarFiles, Collection<File> excludedDirs,
-            Excludes excludes) throws IOException {
-        /*
-         * Note it would be faster to stop traversing a source root as soon as
-         * we encounter the first .java file, but it appears we have nested
-         * source roots in our generated source directory (specifically,
-         * R.java files and aidl .java files don't share the same source
-         * root).
-         */
-
-        boolean firstJavaFile = true;
-        for (File file : directory.listFiles()) {
-            // Trim preceding "./" from path.
-            String path = file.getPath().substring(2);
-
-            // Keep track of source roots for .java files.
-            if (path.endsWith(".java")) {
-                if (firstJavaFile) {
-                    // Only parse one .java file per directory.
-                    firstJavaFile = false;
-
-                    File sourceRoot = rootOf(file);
-                    if (sourceRoot != null) {
-                        sourceRoots.add(sourceRoot);
-                    }
-                }
-                                
-                continue;
-            }
-
-            // Keep track of .jar files.
-            if (path.endsWith(".jar")) {
-                if (!excludes.exclude(path)) {
-                    jarFiles.add(file);
-                } else {
-                    Log.debug("Skipped: " + file);
-                }
-
-                continue;
-            }
-
-            // Traverse nested directories.
-            if (file.isDirectory()) {
-                if (excludes.exclude(path)) {
-                    // Don't recurse into excluded dirs.
-                    Log.debug("Excluding: " + path);
-                    excludedDirs.add(file);
-                } else {
-                    traverse(file, sourceRoots, jarFiles, excludedDirs,
-                            excludes);
-                }
-            }
-        }
-    }
-
-    /**
-     * Determines the source root for a given .java file. Returns null
-     * if the file doesn't have a package or if the file isn't in the
-     * correct directory structure.
-     */
-    private static File rootOf(File javaFile) throws IOException {
-        String packageName = parsePackageName(javaFile);
-        if (packageName == null) {
-            // No package.
-            // TODO: Treat this as a source root?
-            return null;
-        }
-
-        String packagePath = packageName.replace('.', File.separatorChar);
-        File parent = javaFile.getParentFile();
-        String parentPath = parent.getPath();
-        if (!parentPath.endsWith(packagePath)) {
-            // Bad dir structure.
-            return null;
-        }
-
-        return new File(parentPath.substring(
-                0, parentPath.length() - packagePath.length()));
-    }
-
-    /**
-     * Reads a Java file and parses out the package name. Returns null if none
-     * found.
-     */
-    private static String parsePackageName(File file) throws IOException {
-        BufferedReader in = new BufferedReader(new FileReader(file));
-        try {
-            String line;
-            while ((line = in.readLine()) != null) {
-                String trimmed = line.trim();
-                if (trimmed.startsWith("package")) {
-                    // TODO: Make this more robust.
-                    // Assumes there's only once space after "package" and the
-                    // line ends in a ";".
-                    return trimmed.substring(8, trimmed.length() - 1);
-                }
-            }
-
-            return null;
-        } finally {
-            in.close();
-        }
-    }
-
-    /**
-     * Picks out excluded directories that are under source roots.
-     */
-    public SortedSet<File> excludesUnderSourceRoots() {
-        // TODO: Refactor this to share the similar logic in
-        // Eclipse.constructExcluding().
-        SortedSet<File> picked = new TreeSet<File>();
-        for (File sourceRoot : sourceRoots) {
-            String sourcePath = sourceRoot.getPath() + "/";
-            SortedSet<File> tailSet = excludedDirs.tailSet(sourceRoot);
-            for (File file : tailSet) {
-                if (file.getPath().startsWith(sourcePath)) {
-                    picked.add(file);
-                } else {
-                    break;
-                }
-            }
-        }
-        return picked;
-    }
-
-    /**
-     * Reads a list of regular expressions from a file, one per line, and adds
-     * the compiled patterns to the given collection. Ignores lines starting
-     * with '#'.
-     *
-     * @param file containing regular expressions, one per line
-     * @param patterns collection to add compiled patterns from file to
-     */
-    public static void parseFile(File file, Collection<Pattern> patterns)
-            throws IOException {
-        BufferedReader in = new BufferedReader(new FileReader(file));
-        try {
-            String line;
-            while ((line = in.readLine()) != null) {
-                String trimmed = line.trim();
-                if (trimmed.length() > 0 && !trimmed.startsWith("#")) {
-                    patterns.add(Pattern.compile(trimmed));
-                }
-            }
-        } finally {
-            in.close();
-        }
-    }
-}
diff --git a/tools/idegen/src/Eclipse.java b/tools/idegen/src/Eclipse.java
deleted file mode 100644
index 403c7d8..0000000
--- a/tools/idegen/src/Eclipse.java
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.util.SortedSet;
-import java.util.TreeMap;
-import java.util.TreeSet;
-import java.util.Collection;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.regex.Pattern;
-
-/**
- * Generates an Eclipse project.
- */
-public class Eclipse {
-
-    /**
-     * Generates an Eclipse .classpath file from the given configuration.
-     */
-    public static void generateFrom(Configuration c) throws IOException {
-        StringBuilder classpath = new StringBuilder();
-
-        classpath.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
-                + "<classpath>\n");
-
-        /*
-         * If the user has a file named "path-precedence" in their project's
-         * root directory, we'll order source roots based on how they match
-         * regular expressions in that file. Source roots that match earlier
-         * patterns will come sooner in configuration file.
-         */
-        List<Pattern> patterns = new ArrayList<Pattern>();
-
-        File precedence = new File("path-precedence");
-        if (precedence.exists()) {
-            Configuration.parseFile(precedence, patterns);
-        } else {
-            // Put ./out at the bottom by default.
-            patterns.add(Pattern.compile("^(?!out/)"));
-        }
-
-        // Everything not matched by the user's precedence spec.
-        patterns.add(Pattern.compile(".*"));
-
-
-        List<Bucket> buckets = new ArrayList<Bucket>(patterns.size());
-        for (Pattern pattern : patterns) {
-            buckets.add(new Bucket(pattern));
-        }
-
-        // Put source roots in respective buckets.
-        OUTER: for (File sourceRoot : c.sourceRoots) {
-            // Trim preceding "./" from path.
-            String path = sourceRoot.getPath().substring(2);
-
-            for (Bucket bucket : buckets) {
-                if (bucket.matches(path)) {
-                    bucket.sourceRoots.add(sourceRoot);
-                    continue OUTER;
-                }
-            }
-        }
-
-        // Output source roots to configuration file.
-        for (Bucket bucket : buckets) {
-            for (File sourceRoot : bucket.sourceRoots) {
-                classpath.append("  <classpathentry kind=\"src\"");
-                CharSequence excluding = constructExcluding(sourceRoot, c);
-                if (excluding.length() > 0) {
-                    classpath.append(" excluding=\"")
-                            .append(excluding).append("\"");
-                }
-                classpath.append(" path=\"")
-                        .append(trimmed(sourceRoot)).append("\"/>\n");
-            }
-
-        }
-
-        // Output .jar entries.
-        for (File jar : c.jarFiles) {
-            classpath.append("  <classpathentry kind=\"lib\" path=\"")
-                    .append(trimmed(jar)).append("\"/>\n");
-        }
-
-        /*
-         * Output directory. Unfortunately, Eclipse forces us to put it
-         * somewhere under the project directory.
-         */
-        classpath.append("  <classpathentry kind=\"output\" path=\""
-                + "out/eclipse\"/>\n");
-
-        classpath.append("</classpath>\n");
-
-        Files.toFile(classpath.toString(), new File(".classpath"));
-    }
-
-
-    /**
-     * Constructs the "excluding" argument for a given source root.
-     */
-    private static CharSequence constructExcluding(File sourceRoot,
-            Configuration c) {
-        StringBuilder classpath = new StringBuilder();
-        String path = sourceRoot.getPath();
-
-        // Exclude nested source roots.
-        SortedSet<File> nextRoots = c.sourceRoots.tailSet(sourceRoot);
-        int count = 0;
-        for (File nextRoot : nextRoots) {
-            // The first root is this root.
-            if (count == 0) {
-                count++;
-                continue;
-            }
-
-            String nextPath = nextRoot.getPath();
-            if (!nextPath.startsWith(path)) {
-                break;
-            }
-
-            if (count > 1) {
-                classpath.append('|');
-            }
-            classpath.append(nextPath.substring(path.length() + 1))
-                    .append('/');
-
-            count++;
-        }
-
-        // Exclude excluded directories under this source root.
-        SortedSet<File> excludedDirs = c.excludedDirs.tailSet(sourceRoot);
-        for (File excludedDir : excludedDirs) {
-            String excludedPath = excludedDir.getPath();
-            if (!excludedPath.startsWith(path)) {
-                break;
-            }
-
-            if (count > 1) {
-                classpath.append('|');
-            }
-            classpath.append(excludedPath.substring(path.length() + 1))
-                    .append('/');
-
-            count++;
-        }
-
-        return classpath;
-    }
-
-    /**
-     * Returns the trimmed path.
-     */
-    private static String trimmed(File file) {
-        return file.getPath().substring(2);
-    }
-
-    /**
-     * A precedence bucket for source roots.
-     */
-    private static class Bucket {
-
-        private final Pattern pattern;
-        private final List<File> sourceRoots = new ArrayList<File>();
-
-        private Bucket(Pattern pattern) {
-            this.pattern = pattern;
-        }
-
-        private boolean matches(String path) {
-            return pattern.matcher(path).find();
-        }
-    }
-}
diff --git a/tools/idegen/src/Excludes.java b/tools/idegen/src/Excludes.java
deleted file mode 100644
index 8531d47..0000000
--- a/tools/idegen/src/Excludes.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-import java.util.regex.Pattern;
-import java.util.List;
-
-/**
- * Decides whether or not to exclude certain paths.
- */
-public class Excludes {
-
-    private final List<Pattern> patterns;
-
-    /**
-     * Constructs a set of excludes matching the given patterns.
-     */
-    public Excludes(List<Pattern> patterns) {
-        this.patterns = patterns;
-    }
-
-    /**
-     * Returns true if the given path should be excluded.
-     */
-    public boolean exclude(String path) {
-        for (Pattern pattern : patterns) {
-            if (pattern.matcher(path).find()) {
-                return true;
-            }
-        }
-        return false;
-    }
-}
diff --git a/tools/idegen/src/Files.java b/tools/idegen/src/Files.java
deleted file mode 100644
index 81176ee..0000000
--- a/tools/idegen/src/Files.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-import java.io.*;
-
-/**
- * File utility methods.
- */
-class Files {
-
-    /**
-     * Reads file into a string using default encoding.
-     */
-    static String toString(File file) throws IOException {
-        char[] buffer = new char[0x1000]; // 4k
-        int read;
-        Reader in = new FileReader(file);
-        StringBuilder builder = new StringBuilder();
-        while ((read = in.read(buffer)) > -1) {
-            builder.append(buffer, 0, read);
-        }
-        in.close();
-        return builder.toString();
-    }
-
-    /**
-     * Writes a string to a file using default encoding.
-     */
-    static void toFile(String contents, File file) throws IOException {
-        FileWriter out = new FileWriter(file);
-        out.write(contents);
-        out.close();
-    }
-}
\ No newline at end of file
diff --git a/tools/idegen/src/IntelliJ.java b/tools/idegen/src/IntelliJ.java
deleted file mode 100644
index 00d731d..0000000
--- a/tools/idegen/src/IntelliJ.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-import java.io.File;
-import java.io.IOException;
-import java.util.SortedSet;
-
-/**
- * Generates an IntelliJ project.
- */
-public class IntelliJ {
-
-    private static final String IDEA_IML = "android.iml";
-    private static final String IDEA_IPR = "android.ipr";
-
-    /**
-     * Generates IntelliJ configuration files from the given configuration.
-     */
-    public static void generateFrom(Configuration c) throws IOException {
-        File templatesDirectory = new File(c.toolDirectory, "templates");
-        String ipr = Files.toString(new File(templatesDirectory, IDEA_IPR));
-        Files.toFile(ipr, new File(IDEA_IPR));
-
-        String iml = Files.toString(new File(templatesDirectory, IDEA_IML));
-
-        StringBuilder sourceRootsXml = new StringBuilder();
-        for (File sourceRoot : c.sourceRoots) {
-            sourceRootsXml.append("<sourceFolder url=\"file://$MODULE_DIR$/")
-                .append(sourceRoot.getPath())
-                .append("\" isTestSource=\"").append(isTests(sourceRoot))
-                .append("\"/>\n");
-        }
-
-        /*
-         * IntelliJ excludes are module-wide. We explicitly exclude directories
-         * under source roots but leave the rest in so you can still pull
-         * up random non-Java files.
-         */
-        StringBuilder excludeXml = new StringBuilder();
-        for (File excludedDir : c.excludesUnderSourceRoots()) {
-            sourceRootsXml.append("<excludeFolder url=\"file://$MODULE_DIR$/")
-                .append(excludedDir.getPath())
-                .append("\"/>\n");
-        }
-
-        // Exclude Eclipse's output directory.
-        sourceRootsXml.append("<excludeFolder "
-                + "url=\"file://$MODULE_DIR$/out/eclipse\"/>\n");
-
-        StringBuilder jarsXml = new StringBuilder();
-        for (File jar : c.jarFiles) {
-            jarsXml.append("<orderEntry type=\"module-library\">"
-                    + "<library><CLASSES><root url=\"jar://$MODULE_DIR$/")
-                .append(jar.getPath())
-            .append("!/\"/></CLASSES><JAVADOC/><SOURCES/></library>"
-                    + "</orderEntry>\n");
-        }
-
-        iml = iml.replace("SOURCE_FOLDERS",
-                sourceRootsXml.toString() + excludeXml.toString());
-        iml = iml.replace("JAR_ENTRIES", jarsXml.toString());
-
-        Files.toFile(iml, new File(IDEA_IML));
-    }
-
-    private static boolean isTests(File file) {
-        String path = file.getPath();
-
-        // test-runner is testing infrastructure, not test code.
-        if (path.contains("test-runner")) {
-            return false;
-        }
-
-        return path.toUpperCase().contains("TEST");
-    }
-}
\ No newline at end of file
diff --git a/tools/idegen/src/Log.java b/tools/idegen/src/Log.java
deleted file mode 100644
index e35d060..0000000
--- a/tools/idegen/src/Log.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * Logs messages.
- */
-class Log {
-
-    static final boolean DEBUG = false;
-
-    static void debug(String message) {
-        if (DEBUG) {
-            info(message);
-        }
-    }
-
-    static void info(String message) {
-        System.out.println(message);
-    }
-}
diff --git a/tools/idegen/src/Main.java b/tools/idegen/src/Main.java
deleted file mode 100644
index 294dbee..0000000
--- a/tools/idegen/src/Main.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-import java.io.File;
-import java.io.FileFilter;
-import java.io.FileReader;
-import java.io.IOException;
-import java.io.BufferedReader;
-import java.io.FileNotFoundException;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.SortedSet;
-import java.util.TreeSet;
-
-/**
- * Generates IntelliJ and Eclipse project configurations.
- */
-public class Main {
-
-    public static void main(String[] args) throws Exception {
-        Configuration configuration = new Configuration();
-        IntelliJ.generateFrom(configuration);
-        Eclipse.generateFrom(configuration);
-    }
-}
diff --git a/tools/idegen/src/Stopwatch.java b/tools/idegen/src/Stopwatch.java
deleted file mode 100644
index 4bd2ae8..0000000
--- a/tools/idegen/src/Stopwatch.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * Measures passed time.
- */
-class Stopwatch {
-
-    long last = System.currentTimeMillis();
-
-    void reset(String label) {
-        long now = System.currentTimeMillis();
-        Log.info(label + ": " + (now - last) + "ms");
-        last = now;
-    }
-}
\ No newline at end of file
diff --git a/tools/idegen/templates/android.iml b/tools/idegen/templates/android.iml
deleted file mode 100644
index 12e934c..0000000
--- a/tools/idegen/templates/android.iml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module version="4" relativePaths="true" type="JAVA_MODULE">
-  <component name="ModuleRootManager" />
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$">
-      SOURCE_FOLDERS
-    </content>
-    JAR_ENTRIES
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="inheritedJdk" />
-    <orderEntryProperties />
-  </component>
-</module>
-
diff --git a/tools/idegen/templates/android.ipr b/tools/idegen/templates/android.ipr
deleted file mode 100644
index d6aba4b..0000000
--- a/tools/idegen/templates/android.ipr
+++ /dev/null
@@ -1,311 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project relativePaths="true" version="4">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-    <buildFile url="file://$PROJECT_DIR$/ide/intellij/build.xml">
-      <additionalClassPath />
-      <antReference projectDefault="true" />
-      <customJdkName value="" />
-      <maximumHeapSize value="128" />
-      <properties />
-    </buildFile>
-  </component>
-  <component name="BuildJarProjectSettings">
-    <option name="BUILD_JARS_ON_MAKE" value="false" />
-  </component>
-  <component name="CodeStyleProjectProfileManger">
-    <option name="PROJECT_PROFILE" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-  </component>
-  <component name="CodeStyleSettingsManager">
-    <option name="PER_PROJECT_SETTINGS">
-      <value>
-        <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
-        <option name="RIGHT_MARGIN" value="80" />
-        <option name="BINARY_OPERATION_SIGN_ON_NEXT_LINE" value="true" />
-        <option name="PLACE_ASSIGNMENT_SIGN_ON_NEXT_LINE" value="true" />
-      </value>
-    </option>
-    <option name="USE_PER_PROJECT_SETTINGS" value="true" />
-  </component>
-  <component name="CompilerConfiguration">
-    <option name="DEFAULT_COMPILER" value="Javac" />
-    <option name="DEPLOY_AFTER_MAKE" value="0" />
-    <resourceExtensions>
-      <entry name=".+\.(properties|xml|html|dtd|tld)" />
-      <entry name=".+\.(gif|png|jpeg|jpg)" />
-    </resourceExtensions>
-    <wildcardResourcePatterns>
-      <entry name="?*.properties" />
-      <entry name="?*.xml" />
-      <entry name="?*.gif" />
-      <entry name="?*.png" />
-      <entry name="?*.jpeg" />
-      <entry name="?*.jpg" />
-      <entry name="?*.html" />
-      <entry name="?*.dtd" />
-      <entry name="?*.tld" />
-    </wildcardResourcePatterns>
-  </component>
-  <component name="DependenciesAnalyzeManager">
-    <option name="myForwardDirection" value="false" />
-  </component>
-  <component name="DependencyValidationManager">
-    <option name="SKIP_IMPORT_STATEMENTS" value="false" />
-  </component>
-  <component name="EclipseCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EclipseEmbeddedCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EntryPointsManager">
-    <entry_points version="2.0" />
-  </component>
-  <component name="ExportToHTMLSettings">
-    <option name="PRINT_LINE_NUMBERS" value="false" />
-    <option name="OPEN_IN_BROWSER" value="false" />
-    <option name="OUTPUT_DIRECTORY" />
-  </component>
-  <component name="IdProvider" IDEtalkID="C8FEF8FDDA8778BFC0BDE2CF5A21CB2C" />
-  <component name="InspectionProjectProfileManager">
-    <option name="PROJECT_PROFILE" value="Project Default" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-    <scopes />
-    <profiles>
-      <profile version="1.0" is_locked="false">
-        <option name="myName" value="Project Default" />
-        <option name="myLocal" value="false" />
-        <inspection_tool class="JavaDoc" level="WARNING" enabled="false">
-          <option name="TOP_LEVEL_CLASS_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="INNER_CLASS_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="METHOD_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="@return@param@throws or @exception" />
-            </value>
-          </option>
-          <option name="FIELD_OPTIONS">
-            <value>
-              <option name="ACCESS_JAVADOC_REQUIRED_FOR" value="none" />
-              <option name="REQUIRED_TAGS" value="" />
-            </value>
-          </option>
-          <option name="IGNORE_DEPRECATED" value="false" />
-          <option name="IGNORE_JAVADOC_PERIOD" value="true" />
-          <option name="myAdditionalJavadocTags" value="" />
-        </inspection_tool>
-      </profile>
-    </profiles>
-    <list size="0" />
-  </component>
-  <component name="JavacSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="-Xlint:all,-deprecation,-serial" />
-    <option name="MAXIMUM_HEAP_SIZE" value="512" />
-  </component>
-  <component name="JavadocGenerationManager">
-    <option name="OUTPUT_DIRECTORY" />
-    <option name="OPTION_SCOPE" value="protected" />
-    <option name="OPTION_HIERARCHY" value="true" />
-    <option name="OPTION_NAVIGATOR" value="true" />
-    <option name="OPTION_INDEX" value="true" />
-    <option name="OPTION_SEPARATE_INDEX" value="true" />
-    <option name="OPTION_DOCUMENT_TAG_USE" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_AUTHOR" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_VERSION" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
-    <option name="OPTION_DEPRECATED_LIST" value="true" />
-    <option name="OTHER_OPTIONS" value="" />
-    <option name="HEAP_SIZE" />
-    <option name="LOCALE" />
-    <option name="OPEN_IN_BROWSER" value="true" />
-  </component>
-  <component name="JikesSettings">
-    <option name="JIKES_PATH" value="" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="DEPRECATION" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="IS_EMACS_ERRORS_MODE" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="LogConsolePreferences">
-    <option name="FILTER_ERRORS" value="false" />
-    <option name="FILTER_WARNINGS" value="false" />
-    <option name="FILTER_INFO" value="true" />
-    <option name="CUSTOM_FILTER" />
-  </component>
-  <component name="Palette2">
-    <group name="Swing">
-      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
-      </item>
-      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
-        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
-        <initial-values>
-          <property name="text" value="Button" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="RadioButton" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="CheckBox" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="Label" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
-          <preferred-size width="-1" height="20" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
-      </item>
-    </group>
-  </component>
-  <component name="ProjectFileVersion" converted="true" />
-  <component name="ProjectModuleManager">
-    <modules>
-      <module fileurl="file://$PROJECT_DIR$/android.iml" filepath="$PROJECT_DIR$/android.iml" />
-    </modules>
-  </component>
-  <component name="ProjectRootManager" version="2" assert-keyword="true" jdk-15="true" project-jdk-name="1.5 (No Libraries)" project-jdk-type="JavaSDK">
-    <output url="file:///tmp/intellij$PROJECT_DIR$/classes" />
-  </component>
-  <component name="RmicSettings">
-    <option name="IS_EANABLED" value="false" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="GENERATE_IIOP_STUBS" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="VcsDirectoryMappings">
-    <mapping directory="" vcs="Perforce" />
-  </component>
-  <component name="com.intellij.jsf.UserDefinedFacesConfigs">
-    <option name="USER_DEFINED_CONFIGS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </component>
-  <component name="uidesigner-configuration">
-    <option name="INSTRUMENT_CLASSES" value="true" />
-    <option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />
-    <option name="DEFAULT_LAYOUT_MANAGER" value="GridLayoutManager" />
-  </component>
-</project>
-
diff --git a/tools/jarutils/.classpath b/tools/jarutils/.classpath
deleted file mode 100644
index fc17a43..0000000
--- a/tools/jarutils/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/jarutils/.project b/tools/jarutils/.project
deleted file mode 100644
index 3649e40..0000000
--- a/tools/jarutils/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>JarUtils</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/jarutils/Android.mk b/tools/jarutils/Android.mk
deleted file mode 100644
index 707614a..0000000
--- a/tools/jarutils/Android.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-JARUTILS_LOCAL_DIR := $(call my-dir)
-include $(JARUTILS_LOCAL_DIR)/src/Android.mk
diff --git a/tools/jarutils/src/Android.mk b/tools/jarutils/src/Android.mk
deleted file mode 100644
index 2248b7f..0000000
--- a/tools/jarutils/src/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := \
-	androidprefs
-
-LOCAL_MODULE := jarutils
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/jarutils/src/com/android/jarutils/DebugKeyProvider.java b/tools/jarutils/src/com/android/jarutils/DebugKeyProvider.java
deleted file mode 100644
index 6dc32ba..0000000
--- a/tools/jarutils/src/com/android/jarutils/DebugKeyProvider.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.jarutils;
-
-import com.android.prefs.AndroidLocation;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.security.KeyStore;
-import java.security.KeyStoreException;
-import java.security.NoSuchAlgorithmException;
-import java.security.PrivateKey;
-import java.security.UnrecoverableEntryException;
-import java.security.UnrecoverableKeyException;
-import java.security.cert.Certificate;
-import java.security.cert.CertificateException;
-
-/**
- * A provider of a dummy key to sign Android application for debugging purpose.
- * <p/>This provider uses a custom keystore to create and store a key with a known password.
- */
-public class DebugKeyProvider {
-    
-    public interface IKeyGenOutput {
-        public void out(String message);
-        public void err(String message);
-    }
-    
-    private static final String PASSWORD_STRING = "android";
-    private static final char[] PASSWORD_CHAR = PASSWORD_STRING.toCharArray();
-    private static final String DEBUG_ALIAS = "AndroidDebugKey";
-    
-    // Certificate CN value. This is a hard-coded value for the debug key.
-    // Android Market checks against this value in order to refuse applications signed with
-    // debug keys.
-    private static final String CERTIFICATE_DESC = "CN=Android Debug,O=Android,C=US";
-    
-    private KeyStore.PrivateKeyEntry mEntry;
-    
-    public static class KeytoolException extends Exception {
-        /** default serial uid */
-        private static final long serialVersionUID = 1L;
-        private String mJavaHome = null;
-        private String mCommandLine = null;
-        
-        KeytoolException(String message) {
-            super(message);
-        }
-
-        KeytoolException(String message, String javaHome, String commandLine) {
-            super(message);
-            
-            mJavaHome = javaHome;
-            mCommandLine = commandLine;
-        }
-        
-        public String getJavaHome() {
-            return mJavaHome;
-        }
-        
-        public String getCommandLine() {
-            return mCommandLine;
-        }
-    }
-    
-    /**
-     * Creates a provider using a keystore at the given location.
-     * <p/>The keystore, and a new random android debug key are created if they do not yet exist.
-     * <p/>Password for the store/key is <code>android</code>, and the key alias is
-     * <code>AndroidDebugKey</code>.
-     * @param osKeyStorePath the OS path to the keystore, or <code>null</code> if the default one
-     * is to be used.
-     * @param storeType an optional keystore type, or <code>null</code> if the default is to
-     * be used.
-     * @param output an optional {@link IKeyGenOutput} object to get the stdout and stderr
-     * of the keytool process call.
-     * @throws KeytoolException If the creation of the debug key failed.
-     * @throws AndroidLocationException 
-     */
-    public DebugKeyProvider(String osKeyStorePath, String storeType, IKeyGenOutput output)
-            throws KeyStoreException, NoSuchAlgorithmException, CertificateException,
-            UnrecoverableEntryException, IOException, KeytoolException, AndroidLocationException {
-        
-        if (osKeyStorePath == null) {
-            osKeyStorePath = getDefaultKeyStoreOsPath();
-        }
-        
-        if (loadKeyEntry(osKeyStorePath, storeType) == false) {
-            // create the store with the key
-            createNewStore(osKeyStorePath, storeType, output);
-        }
-    }
-
-    /**
-     * Returns the OS path to the default debug keystore.
-     * 
-     * @return The OS path to the default debug keystore.
-     * @throws KeytoolException
-     * @throws AndroidLocationException
-     */
-    public static String getDefaultKeyStoreOsPath()
-            throws KeytoolException, AndroidLocationException {
-        String folder = AndroidLocation.getFolder();
-        if (folder == null) {
-            throw new KeytoolException("Failed to get HOME directory!\n");
-        }
-        String osKeyStorePath = folder + "debug.keystore";
-
-        return osKeyStorePath;
-    }
-
-    /**
-     * Returns the debug {@link PrivateKey} to use to sign applications for debug purpose.
-     * @return the private key or <code>null</code> if its creation failed.
-     */
-    public PrivateKey getDebugKey() throws KeyStoreException, NoSuchAlgorithmException,
-            UnrecoverableKeyException, UnrecoverableEntryException {
-        if (mEntry != null) {
-            return mEntry.getPrivateKey();
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the debug {@link Certificate} to use to sign applications for debug purpose.
-     * @return the certificate or <code>null</code> if its creation failed.
-     */
-    public Certificate getCertificate() throws KeyStoreException, NoSuchAlgorithmException,
-            UnrecoverableKeyException, UnrecoverableEntryException {
-        if (mEntry != null) {
-            return mEntry.getCertificate();
-        }
-
-        return null;
-    }
-    
-    /**
-     * Loads the debug key from the keystore.
-     * @param osKeyStorePath the OS path to the keystore.
-     * @param storeType an optional keystore type, or <code>null</code> if the default is to
-     * be used.
-     * @return <code>true</code> if success, <code>false</code> if the keystore does not exist.
-     */
-    private boolean loadKeyEntry(String osKeyStorePath, String storeType) throws KeyStoreException,
-            NoSuchAlgorithmException, CertificateException, IOException,
-            UnrecoverableEntryException {
-        try {
-            KeyStore keyStore = KeyStore.getInstance(
-                    storeType != null ? storeType : KeyStore.getDefaultType());
-            FileInputStream fis = new FileInputStream(osKeyStorePath);
-            keyStore.load(fis, PASSWORD_CHAR);
-            fis.close();
-            mEntry = (KeyStore.PrivateKeyEntry)keyStore.getEntry(
-                    DEBUG_ALIAS, new KeyStore.PasswordProtection(PASSWORD_CHAR));
-        } catch (FileNotFoundException e) {
-            return false;
-        }
-        
-        return true;
-    }
-
-    /**
-     * Creates a new store
-     * @param osKeyStorePath the location of the store
-     * @param storeType an optional keystore type, or <code>null</code> if the default is to
-     * be used.
-     * @param output an optional {@link IKeyGenOutput} object to get the stdout and stderr
-     * of the keytool process call.
-     * @throws KeyStoreException
-     * @throws NoSuchAlgorithmException
-     * @throws CertificateException
-     * @throws UnrecoverableEntryException
-     * @throws IOException
-     * @throws KeytoolException
-     */
-    private void createNewStore(String osKeyStorePath, String storeType, IKeyGenOutput output)
-            throws KeyStoreException, NoSuchAlgorithmException, CertificateException,
-            UnrecoverableEntryException, IOException, KeytoolException {
-        
-        if (KeystoreHelper.createNewStore(osKeyStorePath, storeType, PASSWORD_STRING, DEBUG_ALIAS,
-                PASSWORD_STRING, CERTIFICATE_DESC, 1 /* validity*/, output)) {
-            loadKeyEntry(osKeyStorePath, storeType);
-        }
-    }
-}
diff --git a/tools/jarutils/src/com/android/jarutils/JavaResourceFilter.java b/tools/jarutils/src/com/android/jarutils/JavaResourceFilter.java
deleted file mode 100644
index d9f8da6..0000000
--- a/tools/jarutils/src/com/android/jarutils/JavaResourceFilter.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.jarutils;
-
-import com.android.jarutils.SignedJarBuilder.IZipEntryFilter;
-
-/**
- * A basic implementation of {@link IZipEntryFilter} to filter out anything that is not a
- * java resource.
- */
-public class JavaResourceFilter implements IZipEntryFilter {
-
-    public boolean checkEntry(String name) {
-        // split the path into segments.
-        String[] segments = name.split("/");
-
-        // empty path? skip to next entry.
-        if (segments.length == 0) {
-            return false;
-        }
-
-        // Check each folders to make sure they should be included.
-        // Folders like CVS, .svn, etc.. should already have been excluded from the
-        // jar file, but we need to exclude some other folder (like /META-INF) so
-        // we check anyway.
-        for (int i = 0 ; i < segments.length - 1; i++) {
-            if (checkFolderForPackaging(segments[i]) == false) {
-                return false;
-            }
-        }
-
-        // get the file name from the path
-        String fileName = segments[segments.length-1];
-        
-        return checkFileForPackaging(fileName);
-    }
-    
-    /**
-     * Checks whether a folder and its content is valid for packaging into the .apk as
-     * standard Java resource.
-     * @param folderName the name of the folder.
-     */
-    public static boolean checkFolderForPackaging(String folderName) {
-        return folderName.equals("CVS") == false &&
-            folderName.equals(".svn") == false &&
-            folderName.equals("SCCS") == false &&
-            folderName.equals("META-INF") == false &&
-            folderName.startsWith("_") == false;
-    }
-
-    /**
-     * Checks a file to make sure it should be packaged as standard resources.
-     * @param fileName the name of the file (including extension)
-     * @return true if the file should be packaged as standard java resources.
-     */
-    public static boolean checkFileForPackaging(String fileName) {
-        String[] fileSegments = fileName.split("\\.");
-        String fileExt = "";
-        if (fileSegments.length > 1) {
-            fileExt = fileSegments[fileSegments.length-1];
-        }
-
-        return checkFileForPackaging(fileName, fileExt);
-    }
-
-    /**
-     * Checks a file to make sure it should be packaged as standard resources.
-     * @param fileName the name of the file (including extension)
-     * @param extension the extension of the file (excluding '.')
-     * @return true if the file should be packaged as standard java resources.
-     */
-    public static boolean checkFileForPackaging(String fileName, String extension) {
-        return "aidl".equalsIgnoreCase(extension) == false &&
-            "java".equalsIgnoreCase(extension) == false &&
-            "class".equalsIgnoreCase(extension) == false &&
-            "package.html".equalsIgnoreCase(fileName) == false &&
-            "overview.html".equalsIgnoreCase(fileName) == false &&
-            ".cvsignore".equalsIgnoreCase(fileName) == false &&
-            ".DS_Store".equals(fileName) == false && 
-            fileName.charAt(fileName.length()-1) != '~';
-    }
-}
diff --git a/tools/jarutils/src/com/android/jarutils/KeystoreHelper.java b/tools/jarutils/src/com/android/jarutils/KeystoreHelper.java
deleted file mode 100644
index c694684..0000000
--- a/tools/jarutils/src/com/android/jarutils/KeystoreHelper.java
+++ /dev/null
@@ -1,228 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.jarutils;
-
-import com.android.jarutils.DebugKeyProvider.IKeyGenOutput;
-import com.android.jarutils.DebugKeyProvider.KeytoolException;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.security.KeyStoreException;
-import java.security.NoSuchAlgorithmException;
-import java.security.UnrecoverableEntryException;
-import java.security.cert.CertificateException;
-import java.util.ArrayList;
-
-/**
- * A Helper to create new keystore/key.
- */
-public final class KeystoreHelper {
-
-    /**
-     * Creates a new store
-     * @param osKeyStorePath the location of the store
-     * @param storeType an optional keystore type, or <code>null</code> if the default is to
-     * be used.
-     * @param output an optional {@link IKeyGenOutput} object to get the stdout and stderr
-     * of the keytool process call.
-     * @throws KeyStoreException
-     * @throws NoSuchAlgorithmException
-     * @throws CertificateException
-     * @throws UnrecoverableEntryException
-     * @throws IOException
-     * @throws KeytoolException
-     */
-    public static boolean createNewStore(
-            String osKeyStorePath,
-            String storeType,
-            String storePassword,
-            String alias,
-            String keyPassword,
-            String description,
-            int validityYears,
-            IKeyGenOutput output)
-            throws KeyStoreException, NoSuchAlgorithmException, CertificateException,
-            UnrecoverableEntryException, IOException, KeytoolException {
-        
-        // get the executable name of keytool depending on the platform.
-        String os = System.getProperty("os.name");
-
-        String keytoolCommand;
-        if (os.startsWith("Windows")) {
-            keytoolCommand = "keytool.exe";
-        } else {
-            keytoolCommand = "keytool";
-        }
-
-        String javaHome = System.getProperty("java.home");
-
-        if (javaHome != null && javaHome.length() > 0) {
-            keytoolCommand = javaHome + File.separator + "bin" + File.separator + keytoolCommand; 
-        }
-        
-        // create the command line to call key tool to build the key with no user input.
-        ArrayList<String> commandList = new ArrayList<String>();
-        commandList.add(keytoolCommand);
-        commandList.add("-genkey");
-        commandList.add("-alias");
-        commandList.add(alias);
-        commandList.add("-keyalg");
-        commandList.add("RSA");
-        commandList.add("-dname");
-        commandList.add(description);
-        commandList.add("-validity");
-        commandList.add(Integer.toString(validityYears * 365));
-        commandList.add("-keypass");
-        commandList.add(keyPassword);
-        commandList.add("-keystore");
-        commandList.add(osKeyStorePath);
-        commandList.add("-storepass");
-        commandList.add(storePassword);
-        if (storeType != null) {
-            commandList.add("-storetype");
-            commandList.add(storeType);
-        }
-
-        String[] commandArray = commandList.toArray(new String[commandList.size()]);
-
-        // launch the command line process
-        int result = 0;
-        try {
-            result = grabProcessOutput(Runtime.getRuntime().exec(commandArray), output);
-        } catch (Exception e) {
-            // create the command line as one string
-            StringBuilder builder = new StringBuilder();
-            boolean firstArg = true;
-            for (String arg : commandArray) {
-                boolean hasSpace = arg.indexOf(' ') != -1;
-                
-                if (firstArg == true) {
-                    firstArg = false;
-                } else {
-                    builder.append(' ');
-                }
-                
-                if (hasSpace) {
-                    builder.append('"');
-                }
-                
-                builder.append(arg);
-
-                if (hasSpace) {
-                    builder.append('"');
-                }
-            }
-            
-            throw new KeytoolException("Failed to create key: " + e.getMessage(),
-                    javaHome, builder.toString());
-        }
-        
-        if (result != 0) {
-            return false;
-        }
-        
-        return true;
-    }
-    
-    /**
-     * Get the stderr/stdout outputs of a process and return when the process is done.
-     * Both <b>must</b> be read or the process will block on windows.
-     * @param process The process to get the ouput from
-     * @return the process return code.
-     * @throws InterruptedException
-     */
-    private static int grabProcessOutput(final Process process, final IKeyGenOutput output) {
-        // read the lines as they come. if null is returned, it's
-        // because the process finished
-        Thread t1 = new Thread("") {
-            @Override
-            public void run() {
-                // create a buffer to read the stderr output
-                InputStreamReader is = new InputStreamReader(process.getErrorStream());
-                BufferedReader errReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = errReader.readLine();
-                        if (line != null) {
-                            if (output != null) {
-                                output.err(line);
-                            } else {
-                                System.err.println(line);
-                            }
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        Thread t2 = new Thread("") {
-            @Override
-            public void run() {
-                InputStreamReader is = new InputStreamReader(process.getInputStream());
-                BufferedReader outReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = outReader.readLine();
-                        if (line != null) {
-                            if (output != null) {
-                                output.out(line);
-                            } else {
-                                System.out.println(line);
-                            }
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        t1.start();
-        t2.start();
-
-        // it looks like on windows process#waitFor() can return
-        // before the thread have filled the arrays, so we wait for both threads and the
-        // process itself.
-        try {
-            t1.join();
-        } catch (InterruptedException e) {
-        }
-        try {
-            t2.join();
-        } catch (InterruptedException e) {
-        }
-
-        // get the return code from the process
-        try {
-            return process.waitFor();
-        } catch (InterruptedException e) {
-            // since we're waiting for the output thread above, we should never actually wait
-            // on the process to end, since it'll be done by the time we call waitFor()
-            return 0;
-        }
-    }
-}
diff --git a/tools/jarutils/src/com/android/jarutils/SignedJarBuilder.java b/tools/jarutils/src/com/android/jarutils/SignedJarBuilder.java
deleted file mode 100644
index 335ab7d..0000000
--- a/tools/jarutils/src/com/android/jarutils/SignedJarBuilder.java
+++ /dev/null
@@ -1,324 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.jarutils;
-
-import sun.misc.BASE64Encoder;
-import sun.security.pkcs.ContentInfo;
-import sun.security.pkcs.PKCS7;
-import sun.security.pkcs.SignerInfo;
-import sun.security.x509.AlgorithmId;
-import sun.security.x509.X500Name;
-
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FilterOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.io.PrintStream;
-import java.security.DigestOutputStream;
-import java.security.GeneralSecurityException;
-import java.security.MessageDigest;
-import java.security.NoSuchAlgorithmException;
-import java.security.PrivateKey;
-import java.security.Signature;
-import java.security.SignatureException;
-import java.security.cert.X509Certificate;
-import java.util.Map;
-import java.util.jar.Attributes;
-import java.util.jar.JarEntry;
-import java.util.jar.JarFile;
-import java.util.jar.JarOutputStream;
-import java.util.jar.Manifest;
-import java.util.zip.ZipEntry;
-import java.util.zip.ZipInputStream;
-
-/**
- * A Jar file builder with signature support.
- */
-public class SignedJarBuilder {
-    private static final String DIGEST_ALGORITHM = "SHA1";
-    private static final String DIGEST_ATTR = "SHA1-Digest";
-    private static final String DIGEST_MANIFEST_ATTR = "SHA1-Digest-Manifest";
-
-    /** Write to another stream and also feed it to the Signature object. */
-    private static class SignatureOutputStream extends FilterOutputStream {
-        private Signature mSignature;
-
-        public SignatureOutputStream(OutputStream out, Signature sig) {
-            super(out);
-            mSignature = sig;
-        }
-
-        @Override
-        public void write(int b) throws IOException {
-            try {
-                mSignature.update((byte) b);
-            } catch (SignatureException e) {
-                throw new IOException("SignatureException: " + e);
-            }
-            super.write(b);
-        }
-
-        @Override
-        public void write(byte[] b, int off, int len) throws IOException {
-            try {
-                mSignature.update(b, off, len);
-            } catch (SignatureException e) {
-                throw new IOException("SignatureException: " + e);
-            }
-            super.write(b, off, len);
-        }
-    }
-
-    private JarOutputStream mOutputJar;
-    private PrivateKey mKey;
-    private X509Certificate mCertificate;
-    private Manifest mManifest;
-    private BASE64Encoder mBase64Encoder;
-    private MessageDigest mMessageDigest;
-
-    private byte[] mBuffer = new byte[4096];
-
-    /**
-     * Classes which implement this interface provides a method to check whether a file should
-     * be added to a Jar file.
-     */
-    public interface IZipEntryFilter {
-        /**
-         * Checks a file for inclusion in a Jar archive.
-         * @param name the archive file path of the entry
-         * @return <code>true</code> if the file should be included.
-         */
-        public boolean checkEntry(String name);
-    }
-    
-    /**
-     * Creates a {@link SignedJarBuilder} with a given output stream, and signing information.
-     * <p/>If either <code>key</code> or <code>certificate</code> is <code>null</code> then
-     * the archive will not be signed.
-     * @param out the {@link OutputStream} where to write the Jar archive.
-     * @param key the {@link PrivateKey} used to sign the archive, or <code>null</code>.
-     * @param certificate the {@link X509Certificate} used to sign the archive, or
-     * <code>null</code>.
-     * @throws IOException
-     * @throws NoSuchAlgorithmException
-     */
-    public SignedJarBuilder(OutputStream out, PrivateKey key, X509Certificate certificate)
-            throws IOException, NoSuchAlgorithmException {
-        mOutputJar = new JarOutputStream(out);
-        mOutputJar.setLevel(9);
-        mKey = key;
-        mCertificate = certificate;
-        
-        if (mKey != null && mCertificate != null) {
-            mManifest = new Manifest();
-            Attributes main = mManifest.getMainAttributes();
-            main.putValue("Manifest-Version", "1.0");
-            main.putValue("Created-By", "1.0 (Android)");
-    
-            mBase64Encoder = new BASE64Encoder();
-            mMessageDigest = MessageDigest.getInstance(DIGEST_ALGORITHM);
-        }
-    }
-    
-    /**
-     * Writes a new {@link File} into the archive.
-     * @param inputFile the {@link File} to write.
-     * @param jarPath the filepath inside the archive.
-     * @throws IOException
-     */
-    public void writeFile(File inputFile, String jarPath) throws IOException {
-        // Get an input stream on the file.
-        FileInputStream fis = new FileInputStream(inputFile);
-        try {
-            
-            // create the zip entry
-            JarEntry entry = new JarEntry(jarPath);
-            entry.setTime(inputFile.lastModified());
-
-            writeEntry(fis, entry);
-        } finally {
-            // close the file stream used to read the file
-            fis.close();
-        }
-    }
-
-    /**
-     * Copies the content of a Jar/Zip archive into the receiver archive.
-     * <p/>An optional {@link IZipEntryFilter} allows to selectively choose which files
-     * to copy over.
-     * @param input the {@link InputStream} for the Jar/Zip to copy.
-     * @param filter the filter or <code>null</code>
-     * @throws IOException
-     */
-    public void writeZip(InputStream input, IZipEntryFilter filter) throws IOException {
-        ZipInputStream zis = new ZipInputStream(input);
-
-        try {
-            // loop on the entries of the intermediary package and put them in the final package.
-            ZipEntry entry;
-            while ((entry = zis.getNextEntry()) != null) {
-                String name = entry.getName();
-                
-                // do not take directories or anything inside a potential META-INF folder.
-                if (entry.isDirectory() || name.startsWith("META-INF/")) {
-                    continue;
-                }
-    
-                // if we have a filter, we check the entry against it
-                if (filter != null && filter.checkEntry(name) == false) {
-                    continue;
-                }
-    
-                JarEntry newEntry;
-    
-                // Preserve the STORED method of the input entry.
-                if (entry.getMethod() == JarEntry.STORED) {
-                    newEntry = new JarEntry(entry);
-                } else {
-                    // Create a new entry so that the compressed len is recomputed.
-                    newEntry = new JarEntry(name);
-                }
-                
-                writeEntry(zis, newEntry);
-    
-                zis.closeEntry();
-            }
-        } finally {
-            zis.close();
-        }
-    }
-
-    /**
-     * Closes the Jar archive by creating the manifest, and signing the archive. 
-     * @throws IOException
-     * @throws GeneralSecurityException
-     */
-    public void close() throws IOException, GeneralSecurityException {
-        if (mManifest != null) {
-            // write the manifest to the jar file
-            mOutputJar.putNextEntry(new JarEntry(JarFile.MANIFEST_NAME));
-            mManifest.write(mOutputJar);
-            
-            // CERT.SF
-            Signature signature = Signature.getInstance("SHA1with" + mKey.getAlgorithm());
-            signature.initSign(mKey);
-            mOutputJar.putNextEntry(new JarEntry("META-INF/CERT.SF"));
-            writeSignatureFile(new SignatureOutputStream(mOutputJar, signature));
-    
-            // CERT.*
-            mOutputJar.putNextEntry(new JarEntry("META-INF/CERT." + mKey.getAlgorithm()));
-            writeSignatureBlock(signature, mCertificate, mKey);
-        }
-        
-        mOutputJar.close();
-    }
-    
-    /**
-     * Adds an entry to the output jar, and write its content from the {@link InputStream}
-     * @param input The input stream from where to write the entry content.
-     * @param entry the entry to write in the jar.
-     * @throws IOException
-     */
-    private void writeEntry(InputStream input, JarEntry entry) throws IOException {
-        // add the entry to the jar archive
-        mOutputJar.putNextEntry(entry);
-
-        // read the content of the entry from the input stream, and write it into the archive.
-        int count; 
-        while ((count = input.read(mBuffer)) != -1) {
-            mOutputJar.write(mBuffer, 0, count);
-            
-            // update the digest
-            if (mMessageDigest != null) {
-                mMessageDigest.update(mBuffer, 0, count);
-            }
-        }
-
-        // close the entry for this file
-        mOutputJar.closeEntry();
-        
-        if (mManifest != null) {
-            // update the manifest for this entry.
-            Attributes attr = mManifest.getAttributes(entry.getName());
-            if (attr == null) {
-                attr = new Attributes();
-                mManifest.getEntries().put(entry.getName(), attr);
-            }
-            attr.putValue(DIGEST_ATTR, mBase64Encoder.encode(mMessageDigest.digest()));
-        }
-    }
-    
-    /** Writes a .SF file with a digest to the manifest. */
-    private void writeSignatureFile(OutputStream out)
-            throws IOException, GeneralSecurityException {
-        Manifest sf = new Manifest();
-        Attributes main = sf.getMainAttributes();
-        main.putValue("Signature-Version", "1.0");
-        main.putValue("Created-By", "1.0 (Android)");
-
-        BASE64Encoder base64 = new BASE64Encoder();
-        MessageDigest md = MessageDigest.getInstance(DIGEST_ALGORITHM);
-        PrintStream print = new PrintStream(
-                new DigestOutputStream(new ByteArrayOutputStream(), md),
-                true, "UTF-8");
-
-        // Digest of the entire manifest
-        mManifest.write(print);
-        print.flush();
-        main.putValue(DIGEST_MANIFEST_ATTR, base64.encode(md.digest()));
-
-        Map<String, Attributes> entries = mManifest.getEntries();
-        for (Map.Entry<String, Attributes> entry : entries.entrySet()) {
-            // Digest of the manifest stanza for this entry.
-            print.print("Name: " + entry.getKey() + "\r\n");
-            for (Map.Entry<Object, Object> att : entry.getValue().entrySet()) {
-                print.print(att.getKey() + ": " + att.getValue() + "\r\n");
-            }
-            print.print("\r\n");
-            print.flush();
-
-            Attributes sfAttr = new Attributes();
-            sfAttr.putValue(DIGEST_ATTR, base64.encode(md.digest()));
-            sf.getEntries().put(entry.getKey(), sfAttr);
-        }
-
-        sf.write(out);
-    }
-
-    /** Write the certificate file with a digital signature. */
-    private void writeSignatureBlock(Signature signature, X509Certificate publicKey,
-            PrivateKey privateKey)
-            throws IOException, GeneralSecurityException {
-        SignerInfo signerInfo = new SignerInfo(
-                new X500Name(publicKey.getIssuerX500Principal().getName()),
-                publicKey.getSerialNumber(),
-                AlgorithmId.get(DIGEST_ALGORITHM),
-                AlgorithmId.get(privateKey.getAlgorithm()),
-                signature.sign());
-
-        PKCS7 pkcs7 = new PKCS7(
-                new AlgorithmId[] { AlgorithmId.get(DIGEST_ALGORITHM) },
-                new ContentInfo(ContentInfo.DATA_OID, null),
-                new X509Certificate[] { publicKey },
-                new SignerInfo[] { signerInfo });
-
-        pkcs7.encodeSignedData(mOutputJar);
-    }
-}
diff --git a/tools/jdwpspy/Android.mk b/tools/jdwpspy/Android.mk
deleted file mode 100644
index eca3e22..0000000
--- a/tools/jdwpspy/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright 2006 The Android Open Source Project
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES:= \
-	Main.c \
-	Net.c \
-	find_JdwpConstants.c
-
-LOCAL_C_INCLUDES += \
-	dalvik/vm
-
-LOCAL_MODULE := jdwpspy
-
-include $(BUILD_HOST_EXECUTABLE)
-
diff --git a/tools/jdwpspy/Common.h b/tools/jdwpspy/Common.h
deleted file mode 100644
index c42d183..0000000
--- a/tools/jdwpspy/Common.h
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright 2006 The Android Open Source Project
- *
- * jdwpspy common stuff.
- */
-#ifndef _JDWPSPY_COMMON
-#define _JDWPSPY_COMMON
-
-#include <stdio.h>
-#include <sys/types.h>
-
-typedef unsigned char u1;
-typedef unsigned short u2;
-typedef unsigned int u4;
-typedef unsigned long long u8;
-
-#ifndef __bool_true_false_are_defined
-typedef enum { false=0, true=!false } bool;
-#define __bool_true_false_are_defined 1
-#endif
-
-#define NELEM(x) (sizeof(x) / sizeof((x)[0]))
-
-#ifndef _JDWP_MISC_INLINE
-# define INLINE extern inline
-#else
-# define INLINE
-#endif
-
-/*
- * Get 1 byte.  (Included to make the code more legible.)
- */
-INLINE u1 get1(unsigned const char* pSrc)
-{
-    return *pSrc;
-}
-
-/*
- * Get 2 big-endian bytes.
- */
-INLINE u2 get2BE(unsigned char const* pSrc)
-{
-    u2 result;
-
-    result = *pSrc++ << 8;
-    result |= *pSrc++;
-
-    return result;
-}
-
-/*
- * Get 4 big-endian bytes.
- */
-INLINE u4 get4BE(unsigned char const* pSrc)
-{
-    u4 result;
-
-    result = *pSrc++ << 24;
-    result |= *pSrc++ << 16;
-    result |= *pSrc++ << 8;
-    result |= *pSrc++;
-
-    return result;
-}
-
-/*
- * Get 8 big-endian bytes.
- */
-INLINE u8 get8BE(unsigned char const* pSrc)
-{
-    u8 result;
-
-    result = (u8) *pSrc++ << 56;
-    result |= (u8) *pSrc++ << 48;
-    result |= (u8) *pSrc++ << 40;
-    result |= (u8) *pSrc++ << 32;
-    result |= (u8) *pSrc++ << 24;
-    result |= (u8) *pSrc++ << 16;
-    result |= (u8) *pSrc++ << 8;
-    result |= (u8) *pSrc++;
-
-    return result;
-}
-
-
-/*
- * Start here.
- */
-int run(const char* connectHost, int connectPort, int listenPort);
-
-/*
- * Print a hex dump to the specified file pointer.
- *
- * "local" mode prints a hex dump starting from offset 0 (roughly equivalent
- * to "xxd -g1").
- *
- * "mem" mode shows the actual memory address, and will offset the start
- * so that the low nibble of the address is always zero.
- */
-typedef enum { kHexDumpLocal, kHexDumpMem } HexDumpMode;
-void printHexDump(const void* vaddr, size_t length);
-void printHexDump2(const void* vaddr, size_t length, const char* prefix);
-void printHexDumpEx(FILE* fp, const void* vaddr, size_t length,
-    HexDumpMode mode, const char* prefix);
-
-#endif /*_JDWPSPY_COMMON*/
diff --git a/tools/jdwpspy/Main.c b/tools/jdwpspy/Main.c
deleted file mode 100644
index 62a0007..0000000
--- a/tools/jdwpspy/Main.c
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright 2006 The Android Open Source Project
- *
- * JDWP spy.
- */
-#define _JDWP_MISC_INLINE
-#include "Common.h"
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include <assert.h>
-#include <ctype.h>
-
-static const char gHexDigit[] = "0123456789abcdef";
-
-/*
- * Print a hex dump.  Just hands control off to the fancy version.
- */
-void printHexDump(const void* vaddr, size_t length)
-{
-    printHexDumpEx(stdout, vaddr, length, kHexDumpLocal, "");
-}
-void printHexDump2(const void* vaddr, size_t length, const char* prefix)
-{
-    printHexDumpEx(stdout, vaddr, length, kHexDumpLocal, prefix);
-}
-
-/*
- * Print a hex dump in this format:
- *
-01234567: 00 11 22 33 44 55 66 77 88 99 aa bb cc dd ee ff  0123456789abcdef\n
- */
-void printHexDumpEx(FILE* fp, const void* vaddr, size_t length,
-    HexDumpMode mode, const char* prefix)
-{
-    const unsigned char* addr = vaddr;
-    char out[77];       /* exact fit */
-    unsigned int offset;    /* offset to show while printing */
-    char* hex;
-    char* asc;
-    int gap;
-
-    if (mode == kHexDumpLocal)
-        offset = 0;
-    else
-        offset = (int) addr;
-
-    memset(out, ' ', sizeof(out)-1);
-    out[8] = ':';
-    out[sizeof(out)-2] = '\n';
-    out[sizeof(out)-1] = '\0';
-
-    gap = (int) offset & 0x0f;
-    while (length) {
-        unsigned int lineOffset = offset & ~0x0f;
-        int i, count;
-        
-        hex = out;
-        asc = out + 59;
-
-        for (i = 0; i < 8; i++) {
-            *hex++ = gHexDigit[lineOffset >> 28];
-            lineOffset <<= 4;
-        }
-        hex++;
-        hex++;
-
-        count = ((int)length > 16-gap) ? 16-gap : (int) length; /* cap length */
-        assert(count != 0);
-        assert(count+gap <= 16);
-
-        if (gap) {
-            /* only on first line */
-            hex += gap * 3;
-            asc += gap;
-        }
-
-        for (i = gap ; i < count+gap; i++) {
-            *hex++ = gHexDigit[*addr >> 4];
-            *hex++ = gHexDigit[*addr & 0x0f];
-            hex++;
-            if (isprint(*addr))
-                *asc++ = *addr;
-            else
-                *asc++ = '.';
-            addr++;
-        }
-        for ( ; i < 16; i++) {
-            /* erase extra stuff; only happens on last line */
-            *hex++ = ' ';
-            *hex++ = ' ';
-            hex++;
-            *asc++ = ' ';
-        }
-
-        fprintf(fp, "%s%s", prefix, out);
-
-        gap = 0;
-        length -= count;
-        offset += count;
-    }
-}
-
-
-/*
- * Explain it.
- */
-static void usage(const char* progName)
-{
-    fprintf(stderr, "Usage: %s VM-port [debugger-listen-port]\n\n", progName);
-    fprintf(stderr,
-"When a debugger connects to the debugger-listen-port, jdwpspy will connect\n");
-    fprintf(stderr, "to the VM on the VM-port.\n");
-}
-
-/*
- * Parse args.
- */
-int main(int argc, char* argv[])
-{
-    int connectPort, listenPort;
-    int cc;
-
-    if (argc < 2 || argc > 3) {
-        usage("jdwpspy");
-        return 2;
-    }
-
-    setvbuf(stdout, NULL, _IONBF, 0);
-
-    /* may want this to be host:port */
-    connectPort = atoi(argv[1]);
-
-    if (argc > 2)
-        listenPort = atoi(argv[2]);
-    else
-        listenPort = connectPort + 1;
-
-    cc = run("localhost", connectPort, listenPort);
-
-    return (cc != 0);
-}
-
diff --git a/tools/jdwpspy/Net.c b/tools/jdwpspy/Net.c
deleted file mode 100644
index 555fe49..0000000
--- a/tools/jdwpspy/Net.c
+++ /dev/null
@@ -1,751 +0,0 @@
-/*
- * Copyright 2006 The Android Open Source Project
- *
- * JDWP spy.  This is a rearranged version of the JDWP code from the VM.
- */
-#include "Common.h"
-#include "jdwp/JdwpConstants.h"
-
-#include <stdlib.h>
-#include <unistd.h>     
-#include <stdio.h>
-#include <string.h>     
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <netinet/tcp.h>
-#include <arpa/inet.h>
-#include <netdb.h>
-#include <time.h>
-#include <errno.h>
-#include <assert.h>
-
-#define kInputBufferSize    (256*1024)
-
-#define kMagicHandshakeLen  14      /* "JDWP-Handshake" */
-#define kJDWPHeaderLen      11
-#define kJDWPFlagReply      0x80
-
-
-/*
- * Information about the remote end.
- */
-typedef struct Peer {
-    char    label[2];           /* 'D' or 'V' */
-
-    int     sock;
-    unsigned char   inputBuffer[kInputBufferSize];
-    int     inputCount;
-
-    bool    awaitingHandshake;  /* waiting for "JDWP-Handshake" */
-} Peer;
-
-
-/*
- * Network state.
- */
-typedef struct NetState {
-    /* listen here for connection from debugger */
-    int     listenSock;
-
-    /* connect here to contact VM */
-    struct in_addr vmAddr;
-    short   vmPort;
-
-    Peer    dbg;
-    Peer    vm;
-} NetState;
-
-/*
- * Function names.
- */
-typedef struct {
-    u1  cmdSet;
-    u1  cmd;
-    const char* descr;
-} JdwpHandlerMap;
-
-/*
- * Map commands to names.
- *
- * Command sets 0-63 are incoming requests, 64-127 are outbound requests,
- * and 128-256 are vendor-defined.
- */
-static const JdwpHandlerMap gHandlerMap[] = {
-    /* VirtualMachine command set (1) */
-    { 1,    1,  "VirtualMachine.Version" },
-    { 1,    2,  "VirtualMachine.ClassesBySignature" },
-    { 1,    3,  "VirtualMachine.AllClasses" },
-    { 1,    4,  "VirtualMachine.AllThreads" },
-    { 1,    5,  "VirtualMachine.TopLevelThreadGroups" },
-    { 1,    6,  "VirtualMachine.Dispose" },
-    { 1,    7,  "VirtualMachine.IDSizes" },
-    { 1,    8,  "VirtualMachine.Suspend" },
-    { 1,    9,  "VirtualMachine.Resume" },
-    { 1,    10, "VirtualMachine.Exit" },
-    { 1,    11, "VirtualMachine.CreateString" },
-    { 1,    12, "VirtualMachine.Capabilities" },
-    { 1,    13, "VirtualMachine.ClassPaths" },
-    { 1,    14, "VirtualMachine.DisposeObjects" },
-    { 1,    15, "VirtualMachine.HoldEvents" },
-    { 1,    16, "VirtualMachine.ReleaseEvents" },
-    { 1,    17, "VirtualMachine.CapabilitiesNew" },
-    { 1,    18, "VirtualMachine.RedefineClasses" },
-    { 1,    19, "VirtualMachine.SetDefaultStratum" },
-    { 1,    20, "VirtualMachine.AllClassesWithGeneric"},
-    { 1,    21, "VirtualMachine.InstanceCounts"},
-
-    /* ReferenceType command set (2) */
-    { 2,    1,  "ReferenceType.Signature" },
-    { 2,    2,  "ReferenceType.ClassLoader" },
-    { 2,    3,  "ReferenceType.Modifiers" },
-    { 2,    4,  "ReferenceType.Fields" },
-    { 2,    5,  "ReferenceType.Methods" },
-    { 2,    6,  "ReferenceType.GetValues" },
-    { 2,    7,  "ReferenceType.SourceFile" },
-    { 2,    8,  "ReferenceType.NestedTypes" },
-    { 2,    9,  "ReferenceType.Status" },
-    { 2,    10, "ReferenceType.Interfaces" },
-    { 2,    11, "ReferenceType.ClassObject" },
-    { 2,    12, "ReferenceType.SourceDebugExtension" },
-    { 2,    13, "ReferenceType.SignatureWithGeneric" },
-    { 2,    14, "ReferenceType.FieldsWithGeneric" },
-    { 2,    15, "ReferenceType.MethodsWithGeneric" },
-    { 2,    16, "ReferenceType.Instances" },
-    { 2,    17, "ReferenceType.ClassFileVersion" },
-    { 2,    18, "ReferenceType.ConstantPool" },
-
-    /* ClassType command set (3) */
-    { 3,    1,  "ClassType.Superclass" },
-    { 3,    2,  "ClassType.SetValues" },
-    { 3,    3,  "ClassType.InvokeMethod" },
-    { 3,    4,  "ClassType.NewInstance" },
-
-    /* ArrayType command set (4) */
-    { 4,    1,  "ArrayType.NewInstance" },
-
-    /* InterfaceType command set (5) */
-
-    /* Method command set (6) */
-    { 6,    1,  "Method.LineTable" },
-    { 6,    2,  "Method.VariableTable" },
-    { 6,    3,  "Method.Bytecodes" },
-    { 6,    4,  "Method.IsObsolete" },
-    { 6,    5,  "Method.VariableTableWithGeneric" },
-
-    /* Field command set (8) */
-
-    /* ObjectReference command set (9) */
-    { 9,    1,  "ObjectReference.ReferenceType" },
-    { 9,    2,  "ObjectReference.GetValues" },
-    { 9,    3,  "ObjectReference.SetValues" },
-    { 9,    4,  "ObjectReference.UNUSED" },
-    { 9,    5,  "ObjectReference.MonitorInfo" },
-    { 9,    6,  "ObjectReference.InvokeMethod" },
-    { 9,    7,  "ObjectReference.DisableCollection" },
-    { 9,    8,  "ObjectReference.EnableCollection" },
-    { 9,    9,  "ObjectReference.IsCollected" },
-    { 9,    10, "ObjectReference.ReferringObjects" },
-
-    /* StringReference command set (10) */
-    { 10,   1,  "StringReference.Value" },
-
-    /* ThreadReference command set (11) */
-    { 11,   1,  "ThreadReference.Name" },
-    { 11,   2,  "ThreadReference.Suspend" },
-    { 11,   3,  "ThreadReference.Resume" },
-    { 11,   4,  "ThreadReference.Status" },
-    { 11,   5,  "ThreadReference.ThreadGroup" },
-    { 11,   6,  "ThreadReference.Frames" },
-    { 11,   7,  "ThreadReference.FrameCount" },
-    { 11,   8,  "ThreadReference.OwnedMonitors" },
-    { 11,   9,  "ThreadReference.CurrentContendedMonitor" },
-    { 11,   10, "ThreadReference.Stop" },
-    { 11,   11, "ThreadReference.Interrupt" },
-    { 11,   12, "ThreadReference.SuspendCount" },
-    { 11,   13, "ThreadReference.OwnedMonitorsStackDepthInfo" },
-    { 11,   14, "ThreadReference.ForceEarlyReturn" },
-
-    /* ThreadGroupReference command set (12) */
-    { 12,   1,  "ThreadGroupReference.Name" },
-    { 12,   2,  "ThreadGroupReference.Parent" },
-    { 12,   3,  "ThreadGroupReference.Children" },
-
-    /* ArrayReference command set (13) */
-    { 13,   1,  "ArrayReference.Length" },
-    { 13,   2,  "ArrayReference.GetValues" },
-    { 13,   3,  "ArrayReference.SetValues" },
-
-    /* ClassLoaderReference command set (14) */
-    { 14,   1,  "ArrayReference.VisibleClasses" },
-
-    /* EventRequest command set (15) */
-    { 15,   1,  "EventRequest.Set" },
-    { 15,   2,  "EventRequest.Clear" },
-    { 15,   3,  "EventRequest.ClearAllBreakpoints" },
-
-    /* StackFrame command set (16) */
-    { 16,   1,  "StackFrame.GetValues" },
-    { 16,   2,  "StackFrame.SetValues" },
-    { 16,   3,  "StackFrame.ThisObject" },
-    { 16,   4,  "StackFrame.PopFrames" },
-
-    /* ClassObjectReference command set (17) */
-    { 17,   1,  "ClassObjectReference.ReflectedType" },
-
-    /* Event command set (64) */
-    { 64,  100, "Event.Composite" },
-
-    /* DDMS */
-    { 199,  1,  "DDMS.Chunk" },
-};
-
-/*
- * Look up a command's name.
- */
-static const char* getCommandName(int cmdSet, int cmd)
-{
-    int i;
-
-    for (i = 0; i < (int) NELEM(gHandlerMap); i++) {
-        if (gHandlerMap[i].cmdSet == cmdSet &&
-            gHandlerMap[i].cmd == cmd)
-        {
-            return gHandlerMap[i].descr;
-        }
-    }
-
-    return "?UNKNOWN?";
-}
-
-
-void jdwpNetFree(NetState* netState);       /* fwd */
-
-/*
- * Allocate state structure and bind to the listen port.
- *
- * Returns 0 on success.
- */
-NetState* jdwpNetStartup(unsigned short listenPort, const char* connectHost,
-    unsigned short connectPort)
-{
-    NetState* netState;
-    int one = 1;
-
-    netState = (NetState*) malloc(sizeof(*netState));
-    memset(netState, 0, sizeof(*netState));
-    netState->listenSock = -1;
-    netState->dbg.sock = netState->vm.sock = -1;
-
-    strcpy(netState->dbg.label, "D");
-    strcpy(netState->vm.label, "V");
-
-    /*
-     * Set up a socket to listen for connections from the debugger.
-     */
-
-    netState->listenSock = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP);
-    if (netState->listenSock < 0) {
-        fprintf(stderr, "Socket create failed: %s\n", strerror(errno));
-        goto fail;
-    }
-
-    /* allow immediate re-use if we die */
-    if (setsockopt(netState->listenSock, SOL_SOCKET, SO_REUSEADDR, &one,
-            sizeof(one)) < 0)
-    {
-        fprintf(stderr, "setsockopt(SO_REUSEADDR) failed: %s\n",
-            strerror(errno));
-        goto fail;
-    }
-
-    struct sockaddr_in addr;
-    addr.sin_family = AF_INET;
-    addr.sin_port = htons(listenPort);
-    addr.sin_addr.s_addr = INADDR_ANY;
-
-    if (bind(netState->listenSock, (struct sockaddr*) &addr, sizeof(addr)) != 0)
-    {
-        fprintf(stderr, "attempt to bind to port %u failed: %s\n",
-            listenPort, strerror(errno));
-        goto fail;
-    }
-
-    fprintf(stderr, "+++ bound to port %u\n", listenPort);
-
-    if (listen(netState->listenSock, 5) != 0) {
-        fprintf(stderr, "Listen failed: %s\n", strerror(errno));
-        goto fail;
-    }
-
-    /*
-     * Do the hostname lookup for the VM.
-     */
-    struct hostent* pHost;
-
-    pHost = gethostbyname(connectHost);
-    if (pHost == NULL) {
-        fprintf(stderr, "Name lookup of '%s' failed: %s\n",
-            connectHost, strerror(h_errno));
-        goto fail;
-    }
-
-    netState->vmAddr = *((struct in_addr*) pHost->h_addr_list[0]);
-    netState->vmPort = connectPort;
-
-    fprintf(stderr, "+++ connect host resolved to %s\n",
-        inet_ntoa(netState->vmAddr));
-
-    return netState;
-
-fail:
-    jdwpNetFree(netState);
-    return NULL;
-}
-
-/*
- * Shut down JDWP listener.  Don't free state.
- *
- * Note that "netState" may be partially initialized if "startup" failed.
- */
-void jdwpNetShutdown(NetState* netState)
-{
-    int listenSock = netState->listenSock;
-    int dbgSock = netState->dbg.sock;
-    int vmSock = netState->vm.sock;
-
-    /* clear these out so it doesn't wake up and try to reuse them */
-    /* (important when multi-threaded) */
-    netState->listenSock = netState->dbg.sock = netState->vm.sock = -1;
-
-    if (listenSock >= 0) {
-        shutdown(listenSock, SHUT_RDWR);
-        close(listenSock);
-    }
-    if (dbgSock >= 0) {
-        shutdown(dbgSock, SHUT_RDWR);
-        close(dbgSock);
-    }
-    if (vmSock >= 0) {
-        shutdown(vmSock, SHUT_RDWR);
-        close(vmSock);
-    }
-}
-
-/*
- * Shut down JDWP listener and free its state.
- */
-void jdwpNetFree(NetState* netState)
-{
-    if (netState == NULL)
-        return;
-
-    jdwpNetShutdown(netState);
-    free(netState);
-}
-
-/*
- * Disable the TCP Nagle algorithm, which delays transmission of outbound
- * packets until the previous transmissions have been acked.  JDWP does a
- * lot of back-and-forth with small packets, so this may help.
- */
-static int setNoDelay(int fd)
-{
-    int cc, on = 1;
-
-    cc = setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, &on, sizeof(on));
-    assert(cc == 0);
-    return cc;
-}
-
-/*
- * Accept a connection.  This will block waiting for somebody to show up.
- */
-bool jdwpAcceptConnection(NetState* netState)
-{
-    struct sockaddr_in addr;
-    socklen_t addrlen;
-    int sock;
-
-    if (netState->listenSock < 0)
-        return false;       /* you're not listening! */
-
-    assert(netState->dbg.sock < 0);     /* must not already be talking */
-
-    addrlen = sizeof(addr);
-    do {
-        sock = accept(netState->listenSock, (struct sockaddr*) &addr, &addrlen);
-        if (sock < 0 && errno != EINTR) {
-            fprintf(stderr, "accept failed: %s\n", strerror(errno));
-            return false;
-        }
-    } while (sock < 0);
-
-    fprintf(stderr, "+++ accepted connection from %s:%u\n",
-        inet_ntoa(addr.sin_addr), ntohs(addr.sin_port));
-
-    netState->dbg.sock = sock;
-    netState->dbg.awaitingHandshake = true;
-    netState->dbg.inputCount = 0;
-
-    setNoDelay(sock);
-
-    return true;
-}
-
-/*
- * Close the connections to the debugger and VM.
- *
- * Reset the state so we're ready to receive a new connection.
- */
-void jdwpCloseConnection(NetState* netState)
-{
-    if (netState->dbg.sock >= 0) {
-        fprintf(stderr, "+++ closing connection to debugger\n");
-        close(netState->dbg.sock);
-        netState->dbg.sock = -1;
-    }
-    if (netState->vm.sock >= 0) {
-        fprintf(stderr, "+++ closing connection to vm\n");
-        close(netState->vm.sock);
-        netState->vm.sock = -1;
-    }
-}
-
-/*
- * Figure out if we have a full packet in the buffer.
- */
-static bool haveFullPacket(Peer* pPeer)
-{
-    long length;
-
-    if (pPeer->awaitingHandshake)
-        return (pPeer->inputCount >= kMagicHandshakeLen);
-
-    if (pPeer->inputCount < 4)
-        return false;
-
-    length = get4BE(pPeer->inputBuffer);
-    return (pPeer->inputCount >= length);
-}
-
-/*
- * Consume bytes from the buffer.
- *
- * This would be more efficient with a circular buffer.  However, we're
- * usually only going to find one packet, which is trivial to handle.
- */
-static void consumeBytes(Peer* pPeer, int count)
-{
-    assert(count > 0);
-    assert(count <= pPeer->inputCount);
-
-    if (count == pPeer->inputCount) {
-        pPeer->inputCount = 0;
-        return;
-    }
-
-    memmove(pPeer->inputBuffer, pPeer->inputBuffer + count,
-        pPeer->inputCount - count);
-    pPeer->inputCount -= count;
-}
-
-/*
- * Get the current time.
- */
-static void getCurrentTime(int* pMin, int* pSec)
-{
-    time_t now;
-    struct tm* ptm;
-
-    now = time(NULL);
-    ptm = localtime(&now);
-    *pMin = ptm->tm_min;
-    *pSec = ptm->tm_sec;
-}
-
-/*
- * Dump the contents of a packet to stdout.
- */
-static void dumpPacket(const unsigned char* packetBuf, const char* srcName,
-    const char* dstName)
-{
-    const unsigned char* buf = packetBuf;
-    char prefix[3];
-    u4 length, id;
-    u1 flags, cmdSet=0, cmd=0;
-    u2 error=0;
-    bool reply;
-    int dataLen;
-
-    length = get4BE(buf+0);
-    id = get4BE(buf+4);
-    flags = get1(buf+8);
-    if ((flags & kJDWPFlagReply) != 0) {
-        reply = true;
-        error = get2BE(buf+9);
-    } else {
-        reply = false;
-        cmdSet = get1(buf+9);
-        cmd = get1(buf+10);
-    }
-
-    buf += kJDWPHeaderLen;
-    dataLen = length - (buf - packetBuf);
-
-    if (!reply) {
-        prefix[0] = srcName[0];
-        prefix[1] = '>';
-    } else {
-        prefix[0] = dstName[0];
-        prefix[1] = '<';
-    }
-    prefix[2] = '\0';
-
-    int min, sec;
-    getCurrentTime(&min, &sec);
-
-    if (!reply) {
-        printf("%s REQUEST dataLen=%-5u id=0x%08x flags=0x%02x cmd=%d/%d [%02d:%02d]\n",
-            prefix, dataLen, id, flags, cmdSet, cmd, min, sec);
-        printf("%s   --> %s\n", prefix, getCommandName(cmdSet, cmd));
-    } else {
-        printf("%s REPLY   dataLen=%-5u id=0x%08x flags=0x%02x err=%d (%s) [%02d:%02d]\n",
-            prefix, dataLen, id, flags, error, dvmJdwpErrorStr(error), min,sec);
-    }
-    if (dataLen > 0)
-        printHexDump2(buf, dataLen, prefix);
-    printf("%s ----------\n", prefix);
-}
-
-/*
- * Handle a packet.  Returns "false" if we encounter a connection-fatal error.
- */
-static bool handlePacket(Peer* pDst, Peer* pSrc)
-{
-    const unsigned char* buf = pSrc->inputBuffer;
-    u4 length;
-    u1 flags;
-    int cc;
-
-    length = get4BE(buf+0);
-    flags = get1(buf+9);
-
-    assert((int) length <= pSrc->inputCount);
-
-    dumpPacket(buf, pSrc->label, pDst->label);
-
-    cc = write(pDst->sock, buf, length);
-    if (cc != (int) length) {
-        fprintf(stderr, "Failed sending packet: %s\n", strerror(errno));
-        return false;
-    }
-    /*printf("*** wrote %d bytes from %c to %c\n",
-        cc, pSrc->label[0], pDst->label[0]);*/
-
-    consumeBytes(pSrc, length);
-    return true;
-}
-
-/*
- * Handle incoming data.  If we have a full packet in the buffer, process it.
- */
-static bool handleIncoming(Peer* pWritePeer, Peer* pReadPeer)
-{
-    if (haveFullPacket(pReadPeer)) {
-        if (pReadPeer->awaitingHandshake) {
-            printf("Handshake [%c]: %.14s\n",
-                pReadPeer->label[0], pReadPeer->inputBuffer);
-            if (write(pWritePeer->sock, pReadPeer->inputBuffer,
-                    kMagicHandshakeLen) != kMagicHandshakeLen)
-            {
-                fprintf(stderr,
-                    "+++ [%c] handshake write failed\n", pReadPeer->label[0]);
-                goto fail;
-            }
-            consumeBytes(pReadPeer, kMagicHandshakeLen);
-            pReadPeer->awaitingHandshake = false;
-        } else {
-            if (!handlePacket(pWritePeer, pReadPeer))
-                goto fail;
-        }
-    } else {
-        /*printf("*** %c not full yet\n", pReadPeer->label[0]);*/
-    }
-
-    return true;
-
-fail:
-    return false;
-}
-
-/*
- * Process incoming data.  If no data is available, this will block until
- * some arrives.
- *
- * Returns "false" on error (indicating that the connection has been severed).
- */
-bool jdwpProcessIncoming(NetState* netState)
-{
-    int cc;
-
-    assert(netState->dbg.sock >= 0);
-    assert(netState->vm.sock >= 0);
-
-    while (!haveFullPacket(&netState->dbg) && !haveFullPacket(&netState->vm)) {
-        /* read some more */
-        int highFd;
-        fd_set readfds;
-
-        highFd = (netState->dbg.sock > netState->vm.sock) ?
-            netState->dbg.sock+1 : netState->vm.sock+1;
-        FD_ZERO(&readfds);
-        FD_SET(netState->dbg.sock, &readfds);
-        FD_SET(netState->vm.sock, &readfds);
-
-        errno = 0;
-        cc = select(highFd, &readfds, NULL, NULL, NULL);
-        if (cc < 0) {
-            if (errno == EINTR) {
-                fprintf(stderr, "+++ EINTR on select\n");
-                continue;
-            }
-            fprintf(stderr, "+++ select failed: %s\n", strerror(errno));
-            goto fail;
-        }
-
-        if (FD_ISSET(netState->dbg.sock, &readfds)) {
-            cc = read(netState->dbg.sock,
-                netState->dbg.inputBuffer + netState->dbg.inputCount,
-                sizeof(netState->dbg.inputBuffer) - netState->dbg.inputCount);
-            if (cc < 0) {
-                if (errno == EINTR) {
-                    fprintf(stderr, "+++ EINTR on read\n");
-                    continue;
-                }
-                fprintf(stderr, "+++ dbg read failed: %s\n", strerror(errno));
-                goto fail;
-            }
-            if (cc == 0) {
-                if (sizeof(netState->dbg.inputBuffer) ==
-                        netState->dbg.inputCount)
-                    fprintf(stderr, "+++ debugger sent huge message\n");
-                else
-                    fprintf(stderr, "+++ debugger disconnected\n");
-                goto fail;
-            }
-
-            /*printf("*** %d bytes from dbg\n", cc);*/
-            netState->dbg.inputCount += cc;
-        }
-
-        if (FD_ISSET(netState->vm.sock, &readfds)) {
-            cc = read(netState->vm.sock,
-                netState->vm.inputBuffer + netState->vm.inputCount,
-                sizeof(netState->vm.inputBuffer) - netState->vm.inputCount);
-            if (cc < 0) {
-                if (errno == EINTR) {
-                    fprintf(stderr, "+++ EINTR on read\n");
-                    continue;
-                }
-                fprintf(stderr, "+++ vm read failed: %s\n", strerror(errno));
-                goto fail;
-            }
-            if (cc == 0) {
-                if (sizeof(netState->vm.inputBuffer) ==
-                        netState->vm.inputCount)
-                    fprintf(stderr, "+++ vm sent huge message\n");
-                else
-                    fprintf(stderr, "+++ vm disconnected\n");
-                goto fail;
-            }
-
-            /*printf("*** %d bytes from vm\n", cc);*/
-            netState->vm.inputCount += cc;
-        }
-    }
-
-    if (!handleIncoming(&netState->dbg, &netState->vm))
-        goto fail;
-    if (!handleIncoming(&netState->vm, &netState->dbg))
-        goto fail;
-
-    return true;
-
-fail:
-    jdwpCloseConnection(netState);
-    return false;
-}
-
-/*
- * Connect to the VM.
- */
-bool jdwpConnectToVm(NetState* netState)
-{
-    struct sockaddr_in addr;
-    int sock = -1;
-
-    sock = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP);
-    if (sock < 0) {
-        fprintf(stderr, "Socket create failed: %s\n", strerror(errno));
-        goto fail;
-    }
-
-    addr.sin_family = AF_INET;
-    addr.sin_addr = netState->vmAddr;
-    addr.sin_port = htons(netState->vmPort);
-    if (connect(sock, (struct sockaddr*) &addr, sizeof(addr)) != 0) {
-        fprintf(stderr, "Connection to %s:%u failed: %s\n",
-            inet_ntoa(addr.sin_addr), ntohs(addr.sin_port), strerror(errno));
-        goto fail;
-    }
-    fprintf(stderr, "+++ connected to VM %s:%u\n",
-        inet_ntoa(addr.sin_addr), ntohs(addr.sin_port));
-
-    netState->vm.sock = sock;
-    netState->vm.awaitingHandshake = true;
-    netState->vm.inputCount = 0;
-
-    setNoDelay(netState->vm.sock);
-    return true;
-
-fail:
-    if (sock >= 0)
-        close(sock);
-    return false;
-}
-
-/*
- * Establish network connections and start things running.
- *
- * We wait for a new connection from the debugger.  When one arrives we
- * open a connection to the VM.  If one side or the other goes away, we
- * drop both ends and go back to listening.
- */
-int run(const char* connectHost, int connectPort, int listenPort)
-{
-    NetState* state;
-
-    state = jdwpNetStartup(listenPort, connectHost, connectPort);
-    if (state == NULL)
-        return -1;
-
-    while (true) {
-        if (!jdwpAcceptConnection(state))
-            break;
-
-        if (jdwpConnectToVm(state)) {
-            while (true) {
-                if (!jdwpProcessIncoming(state))
-                    break;
-            }
-        }
-
-        jdwpCloseConnection(state);
-    }
-
-    jdwpNetFree(state);
-
-    return 0;
-}
-
diff --git a/tools/jdwpspy/find_JdwpConstants.c b/tools/jdwpspy/find_JdwpConstants.c
deleted file mode 100644
index 8ff8186..0000000
--- a/tools/jdwpspy/find_JdwpConstants.c
+++ /dev/null
@@ -1 +0,0 @@
-#include "jdwp/JdwpConstants.c"
diff --git a/tools/layoutlib_utils/.classpath b/tools/layoutlib_utils/.classpath
deleted file mode 100644
index 0321c43..0000000
--- a/tools/layoutlib_utils/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/layoutlib_api"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/layoutlib_utils/.project b/tools/layoutlib_utils/.project
deleted file mode 100644
index b427809..0000000
--- a/tools/layoutlib_utils/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>layoutlib_utils</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/layoutlib_utils/Android.mk b/tools/layoutlib_utils/Android.mk
deleted file mode 100644
index 50eb0ff..0000000
--- a/tools/layoutlib_utils/Android.mk
+++ /dev/null
@@ -1,26 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-java-files-under,src)
-
-LOCAL_JAVA_LIBRARIES := \
-	layoutlib_api
-
-LOCAL_MODULE := layoutlib_utils
-
-include $(BUILD_HOST_JAVA_LIBRARY)
diff --git a/tools/layoutlib_utils/src/com/android/layoutlib/utils/ResourceValue.java b/tools/layoutlib_utils/src/com/android/layoutlib/utils/ResourceValue.java
deleted file mode 100644
index 98b4de6..0000000
--- a/tools/layoutlib_utils/src/com/android/layoutlib/utils/ResourceValue.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.layoutlib.utils;
-
-import com.android.layoutlib.api.IResourceValue;
-
-public class ResourceValue implements IResourceValue {
-    private final String mType;
-    private final String mName;
-    private String mValue = null;
-    private final boolean mIsFramwork;
-    
-    public ResourceValue(String type, String name, boolean isFramwork) {
-        mType = type;
-        mName = name;
-        mIsFramwork = isFramwork;
-    }
-
-    public ResourceValue(String type, String name, String value, boolean isFramework) {
-        mType = type;
-        mName = name;
-        mValue = value;
-        mIsFramwork = isFramework;
-    }
-
-    public String getType() {
-        return mType;
-    }
-
-    public final String getName() {
-        return mName;
-    }
-    
-    public final String getValue() {
-        return mValue;
-    }
-    
-    public final void setValue(String value) {
-        mValue = value;
-    }
-    
-    public void replaceWith(ResourceValue value) {
-        mValue = value.mValue;
-    }
-
-    public boolean isFramework() {
-        return mIsFramwork;
-    }
-}
diff --git a/tools/layoutlib_utils/src/com/android/layoutlib/utils/StyleResourceValue.java b/tools/layoutlib_utils/src/com/android/layoutlib/utils/StyleResourceValue.java
deleted file mode 100644
index a32ac1b..0000000
--- a/tools/layoutlib_utils/src/com/android/layoutlib/utils/StyleResourceValue.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.layoutlib.utils;
-
-import com.android.layoutlib.api.IResourceValue;
-import com.android.layoutlib.api.IStyleResourceValue;
-
-import java.util.HashMap;
-
-public final class StyleResourceValue extends ResourceValue implements IStyleResourceValue {
-
-    private String mParentStyle = null;
-    private HashMap<String, IResourceValue> mItems = new HashMap<String, IResourceValue>();
-
-    public StyleResourceValue(String type, String name, boolean isFramework) {
-        super(type, name, isFramework);
-    }
-
-    public StyleResourceValue(String type, String name, String parentStyle, boolean isFramework) {
-        super(type, name, isFramework);
-        mParentStyle = parentStyle;
-    }
-
-    public String getParentStyle() {
-        return mParentStyle;
-    }
-    
-    public IResourceValue findItem(String name) {
-        return mItems.get(name);
-    }
-    
-    public void addItem(IResourceValue value) {
-        mItems.put(value.getName(), value);
-    }
-    
-    @Override
-    public void replaceWith(ResourceValue value) {
-        super.replaceWith(value);
-        
-        if (value instanceof StyleResourceValue) {
-            mItems.clear();
-            mItems.putAll(((StyleResourceValue)value).mItems);
-        }
-    }
-
-}
diff --git a/tools/layoutlib_utils/src/com/android/layoutlib/utils/ValueResourceParser.java b/tools/layoutlib_utils/src/com/android/layoutlib/utils/ValueResourceParser.java
deleted file mode 100644
index 8b768ef..0000000
--- a/tools/layoutlib_utils/src/com/android/layoutlib/utils/ValueResourceParser.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.layoutlib.utils;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.SAXException;
-import org.xml.sax.helpers.DefaultHandler;
-
-/**
- * SAX handler to parser value resource files.
- */
-public final class ValueResourceParser extends DefaultHandler {
-
-    // TODO: reuse definitions from somewhere else.
-    private final static String NODE_RESOURCES = "resources";
-    private final static String NODE_ITEM = "item";
-    private final static String ATTR_NAME = "name";
-    private final static String ATTR_TYPE = "type";
-    private final static String ATTR_PARENT = "parent";
-    
-    // Resource type definition
-    private final static String RES_STYLE = "style";
-    private final static String RES_ATTR = "attr";
-    
-    private final static String DEFAULT_NS_PREFIX = "android:";
-    private final static int DEFAULT_NS_PREFIX_LEN = DEFAULT_NS_PREFIX.length();
-    
-    public interface IValueResourceRepository {
-        void addResourceValue(String resType, ResourceValue value);
-    }
-    
-    private boolean inResources = false;
-    private int mDepth = 0;
-    private StyleResourceValue mCurrentStyle = null;
-    private ResourceValue mCurrentValue = null;
-    private IValueResourceRepository mRepository;
-    private final boolean mIsFramework;
-    
-    public ValueResourceParser(IValueResourceRepository repository, boolean isFramework) {
-        mRepository = repository;
-        mIsFramework = isFramework;
-    }
-
-    @Override
-    public void endElement(String uri, String localName, String qName) throws SAXException {
-        if (mCurrentValue != null) {
-            mCurrentValue.setValue(trimXmlWhitespaces(mCurrentValue.getValue()));
-        }
-        
-        if (inResources && qName.equals(NODE_RESOURCES)) {
-            inResources = false;
-        } else if (mDepth == 2) {
-            mCurrentValue = null;
-            mCurrentStyle = null;
-        } else if (mDepth == 3) {
-            mCurrentValue = null;
-        }
-        
-        mDepth--;
-        super.endElement(uri, localName, qName);
-    }
-
-    @Override
-    public void startElement(String uri, String localName, String qName, Attributes attributes)
-            throws SAXException {
-        try {
-            mDepth++;
-            if (inResources == false && mDepth == 1) {
-                if (qName.equals(NODE_RESOURCES)) {
-                    inResources = true;
-                }
-            } else if (mDepth == 2 && inResources == true) {
-                String type;
-                
-                // if the node is <item>, we get the type from the attribute "type"
-                if (NODE_ITEM.equals(qName)) {
-                    type = attributes.getValue(ATTR_TYPE);
-                } else {
-                    // the type is the name of the node.
-                    type = qName;
-                }
-
-                if (type != null) {
-                    if (RES_ATTR.equals(type) == false) {
-                        // get the resource name
-                        String name = attributes.getValue(ATTR_NAME);
-                        if (name != null) {
-                            if (RES_STYLE.equals(type)) {
-                                String parent = attributes.getValue(ATTR_PARENT);
-                                mCurrentStyle = new StyleResourceValue(type, name, parent, mIsFramework);
-                                mRepository.addResourceValue(type, mCurrentStyle);
-                            } else {
-                                mCurrentValue = new ResourceValue(type, name, mIsFramework);
-                                mRepository.addResourceValue(type, mCurrentValue);
-                            }
-                        }
-                    }
-                }
-            } else if (mDepth == 3 && mCurrentStyle != null) {
-                // get the resource name
-                String name = attributes.getValue(ATTR_NAME);
-                if (name != null) {
-                    // the name can, in some cases, contain a prefix! we remove it.
-                    if (name.startsWith(DEFAULT_NS_PREFIX)) {
-                        name = name.substring(DEFAULT_NS_PREFIX_LEN);
-                    }
-    
-                    mCurrentValue = new ResourceValue(null, name, mIsFramework);
-                    mCurrentStyle.addItem(mCurrentValue);
-                }
-            }
-        } finally {
-            super.startElement(uri, localName, qName, attributes);
-        }
-    }
-    
-    @Override
-    public void characters(char[] ch, int start, int length) throws SAXException {
-        if (mCurrentValue != null) {
-            String value = mCurrentValue.getValue();
-            if (value == null) {
-                mCurrentValue.setValue(new String(ch, start, length));
-            } else {
-                mCurrentValue.setValue(value + new String(ch, start, length));
-            }
-        }
-    }
-    
-    public static String trimXmlWhitespaces(String value) {
-        if (value == null) {
-            return null;
-        }
-
-        // look for carriage return and replace all whitespace around it by just 1 space.
-        int index;
-        
-        while ((index = value.indexOf('\n')) != -1) {
-            // look for whitespace on each side
-            int left = index - 1;
-            while (left >= 0) {
-                if (Character.isWhitespace(value.charAt(left))) {
-                    left--;
-                } else {
-                    break;
-                }
-            }
-            
-            int right = index + 1;
-            int count = value.length();
-            while (right < count) {
-                if (Character.isWhitespace(value.charAt(right))) {
-                    right++;
-                } else {
-                    break;
-                }
-            }
-            
-            // remove all between left and right (non inclusive) and replace by a single space.
-            String leftString = null;
-            if (left >= 0) {
-                leftString = value.substring(0, left + 1);
-            }
-            String rightString = null;
-            if (right < count) {
-                rightString = value.substring(right);
-            }
-            
-            if (leftString != null) {
-                value = leftString;
-                if (rightString != null) {
-                    value += " " + rightString;
-                }
-            } else {
-                value = rightString != null ? rightString : "";
-            }
-        }
-        
-        // now we un-escape the string
-        int length = value.length();
-        char[] buffer = value.toCharArray();
-        
-        for (int i = 0 ; i < length ; i++) {
-            if (buffer[i] == '\\') {
-                if (buffer[i+1] == 'u') {
-                    // this is unicode char.
-                    int unicodeChar = Integer.parseInt(new String(buffer, i+2, 4), 16);
-                    
-                    // put the unicode char at the location of the \
-                    buffer[i] = (char)unicodeChar;
-
-                    // offset the rest of the buffer since we go from 6 to 1 char
-                    if (i + 6 < buffer.length) {
-                        System.arraycopy(buffer, i+6, buffer, i+1, length - i - 6);
-                    }
-                    length -= 5;
-                } else {
-                    if (buffer[i+1] == 'n') {
-                        // replace the 'n' char with \n
-                        buffer[i+1] = '\n';
-                    }
-                    
-                    // offset the buffer to erase the \
-                    System.arraycopy(buffer, i+1, buffer, i, length - i - 1);
-                    length--;
-                }
-            }
-        }
-        
-        return new String(buffer, 0, length);
-    }
-}
diff --git a/tools/line_endings/Android.mk b/tools/line_endings/Android.mk
deleted file mode 100644
index e3902ae..0000000
--- a/tools/line_endings/Android.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-# Copies files into the directory structure described by a manifest
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := \
-	line_endings.c
-
-LOCAL_MODULE := line_endings
-
-include $(BUILD_HOST_EXECUTABLE)
-
diff --git a/tools/line_endings/line_endings.c b/tools/line_endings/line_endings.c
deleted file mode 100644
index 97e1a29..0000000
--- a/tools/line_endings/line_endings.c
+++ /dev/null
@@ -1,158 +0,0 @@
-#include <unistd.h>
-#include <fcntl.h>
-#include <stdio.h>
-#include <string.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-
-#define BUFSIZE (1024*8)
-static void to_unix(char* buf);
-static void unix_to_dos(char* buf2, const char* buf);
-
-int usage()
-{
-    fprintf(stderr, "usage: line_endings unix|dos FILES\n"
-            "\n"
-            "Convert FILES to either unix or dos line endings.\n");
-    return 1;
-}
-
-typedef struct Node {
-    struct Node *next;
-    char buf[BUFSIZE*2+3];
-} Node;
-
-int
-main(int argc, char** argv)
-{
-    enum { UNIX, DOS } ending;
-    int i;
-
-    if (argc < 2) {
-        return usage();
-    }
-
-    if (0 == strcmp("unix", argv[1])) {
-        ending = UNIX;
-    }
-    else if (0 == strcmp("dos", argv[1])) {
-        ending = DOS;
-    }
-    else {
-        return usage();
-    }
-
-    for (i=2; i<argc; i++) {
-        int fd;
-        int len;
-
-        // force implied
-        chmod(argv[i], S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP);
-
-        fd = open(argv[i], O_RDWR);
-        if (fd < 0) {
-            fprintf(stderr, "unable to open file for read/write: %s\n", argv[i]);
-            return 1;
-        }
-
-        len = lseek(fd, 0, SEEK_END);
-        lseek(fd, 0, SEEK_SET);
-
-        if (len > 0) {
-            Node* root = malloc(sizeof(Node));
-            Node* node = root;
-            node->buf[0] = 0;
-
-            while (len > 0) {
-                node->next = malloc(sizeof(Node));
-                node = node->next;
-                node->next = NULL;
-
-                char buf[BUFSIZE+2];
-                ssize_t amt;
-                ssize_t amt2 = len < BUFSIZE ? len : BUFSIZE;
-                amt = read(fd, buf, amt2);
-                if (amt != amt2) {
-                    fprintf(stderr, "unable to read file: %s\n", argv[i]);
-                    return 1;
-                }
-                buf[amt2] = '\0';
-                to_unix(buf);
-                if (ending == UNIX) {
-                    strcpy(node->buf, buf);
-                } else {
-                    char buf2[(BUFSIZE*2)+3];
-                    unix_to_dos(buf2, buf);
-                    strcpy(node->buf, buf2);
-                }
-                len -= amt2;
-            }
-
-            ftruncate(fd, 0);
-            lseek(fd, 0, SEEK_SET);
-            while (root) {
-                ssize_t amt2 = strlen(root->buf);
-                if (amt2 > 0) {
-                    ssize_t amt = write(fd, root->buf, amt2);
-                    if (amt != amt2) {
-                        fprintf(stderr, "unable to write file: %s\n", argv[i]);
-                        return 1;
-                    }
-                }
-                node = root;
-                root = root->next;
-                free(node);
-            }
-        }
-        close(fd);
-    }
-    return 0;
-}
-
-void
-to_unix(char* buf)
-{
-    char* p = buf;
-    char* q = buf;
-    while (*p) {
-        if (p[0] == '\r' && p[1] == '\n') {
-            // dos
-            *q = '\n';
-            p += 2;
-            q += 1;
-        }
-        else if (p[0] == '\r') {
-            // old mac
-            *q = '\n';
-            p += 1;
-            q += 1;
-        }
-        else {
-            *q = *p;
-            p += 1;
-            q += 1;
-        }
-    }
-    *q = '\0';
-}
-
-void
-unix_to_dos(char* buf2, const char* buf)
-{
-    const char* p = buf;
-    char* q = buf2;
-    while (*p) {
-        if (*p == '\n') {
-            q[0] = '\r';
-            q[1] = '\n';
-            q += 2;
-            p += 1;
-        } else {
-            *q = *p;
-            p += 1;
-            q += 1;
-        }
-    }
-    *q = '\0';
-}
-
diff --git a/tools/ninepatch/Android.mk b/tools/ninepatch/Android.mk
deleted file mode 100644
index 42e0205..0000000
--- a/tools/ninepatch/Android.mk
+++ /dev/null
@@ -1,23 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-java-files-under,src)
-
-LOCAL_MODULE := ninepatch
-
-include $(BUILD_HOST_JAVA_LIBRARY)
diff --git a/tools/ninepatch/src/com/android/ninepatch/GraphicsUtilities.java b/tools/ninepatch/src/com/android/ninepatch/GraphicsUtilities.java
deleted file mode 100644
index 7a823ec..0000000
--- a/tools/ninepatch/src/com/android/ninepatch/GraphicsUtilities.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ninepatch;
-
-import javax.imageio.ImageIO;
-import java.awt.image.BufferedImage;
-import java.awt.image.Raster;
-import java.awt.GraphicsConfiguration;
-import java.awt.GraphicsEnvironment;
-import java.awt.Graphics;
-import java.awt.Transparency;
-import java.net.URL;
-import java.io.IOException;
-
-public class GraphicsUtilities {
-    public static BufferedImage loadCompatibleImage(URL resource) throws IOException {
-        BufferedImage image = ImageIO.read(resource);
-        return toCompatibleImage(image);
-    }
-
-    public static BufferedImage createCompatibleImage(int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height);
-    }
-
-    public static BufferedImage toCompatibleImage(BufferedImage image) {
-        if (isHeadless()) {
-            return image;
-        }
-
-        if (image.getColorModel().equals(getGraphicsConfiguration().getColorModel())) {
-            return image;
-        }
-
-        BufferedImage compatibleImage = getGraphicsConfiguration().createCompatibleImage(
-                    image.getWidth(), image.getHeight(), image.getTransparency());
-        Graphics g = compatibleImage.getGraphics();
-        g.drawImage(image, 0, 0, null);
-        g.dispose();
-
-        return compatibleImage;
-    }
-
-    public static BufferedImage createCompatibleImage(BufferedImage image, int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height,
-                                                   image.getTransparency());
-    }
-
-    private static GraphicsConfiguration getGraphicsConfiguration() {
-        GraphicsEnvironment environment = GraphicsEnvironment.getLocalGraphicsEnvironment();
-        return environment.getDefaultScreenDevice().getDefaultConfiguration();
-    }
-
-    private static boolean isHeadless() {
-        return GraphicsEnvironment.isHeadless();
-    }
-
-    public static BufferedImage createTranslucentCompatibleImage(int width, int height) {
-        return getGraphicsConfiguration().createCompatibleImage(width, height,
-                Transparency.TRANSLUCENT);
-    }
-
-    public static int[] getPixels(BufferedImage img, int x, int y, int w, int h, int[] pixels) {
-        if (w == 0 || h == 0) {
-            return new int[0];
-        }
-
-        if (pixels == null) {
-            pixels = new int[w * h];
-        } else if (pixels.length < w * h) {
-            throw new IllegalArgumentException("Pixels array must have a length >= w * h");
-        }
-
-        int imageType = img.getType();
-        if (imageType == BufferedImage.TYPE_INT_ARGB || imageType == BufferedImage.TYPE_INT_RGB) {
-            Raster raster = img.getRaster();
-            return (int[]) raster.getDataElements(x, y, w, h, pixels);
-        }
-
-        // Unmanages the image
-        return img.getRGB(x, y, w, h, pixels, 0, w);
-    }
-}
diff --git a/tools/ninepatch/src/com/android/ninepatch/NinePatch.java b/tools/ninepatch/src/com/android/ninepatch/NinePatch.java
deleted file mode 100644
index 39e05c6..0000000
--- a/tools/ninepatch/src/com/android/ninepatch/NinePatch.java
+++ /dev/null
@@ -1,474 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.ninepatch;
-
-import java.awt.Graphics2D;
-import java.awt.Rectangle;
-import java.awt.RenderingHints;
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Represents a 9-Patch bitmap.
- */
-public class NinePatch {
-    public static final String EXTENSION_9PATCH = ".9.png";
-
-    private BufferedImage mImage;
-    
-    private int mMinWidth;
-    private int mMinHeight;
-
-    private int[] row;
-    private int[] column;
-
-    private boolean mVerticalStartWithPatch;
-    private boolean mHorizontalStartWithPatch;
-
-    private List<Rectangle> mFixed;
-    private List<Rectangle> mPatches;
-    private List<Rectangle> mHorizontalPatches;
-    private List<Rectangle> mVerticalPatches;
-
-    private Pair<Integer> mHorizontalPadding;
-    private Pair<Integer> mVerticalPadding;
-    
-    private float mHorizontalPatchesSum;
-    private float mVerticalPatchesSum;
-
-    private int mRemainderHorizontal;
-
-    private int mRemainderVertical;
-
-    private final URL mFileUrl;
-
-    /**
-     * Loads a 9 patch or regular bitmap.
-     * @param fileUrl the URL of the file to load.
-     * @param convert if <code>true</code>, non 9-patch bitmpa will be converted into a 9 patch.
-     * If <code>false</code> and the bitmap is not a 9 patch, the method will return
-     * <code>null</code>.
-     * @return a {@link NinePatch} or <code>null</code>.
-     * @throws IOException
-     */
-    public static NinePatch load(URL fileUrl, boolean convert) throws IOException {
-        BufferedImage image = null;
-        try {
-            image  = GraphicsUtilities.loadCompatibleImage(fileUrl);
-        } catch (MalformedURLException e) {
-            // really this shouldn't be happening since we're not creating the URL manually.
-            return null;
-        }
-        
-        boolean is9Patch = fileUrl.getPath().toLowerCase().endsWith(EXTENSION_9PATCH);
-        
-        if (is9Patch == false) {
-            if (convert) {
-                image = convertTo9Patch(image);
-            } else {
-                return null;
-            }
-        } else {
-            ensure9Patch(image);
-        }
-
-        
-        return new NinePatch(fileUrl, image);
-    }
-    
-    public int getWidth() {
-        return mImage.getWidth() - 2;
-    }
-
-    public int getHeight() {
-        return mImage.getHeight() - 2;
-    }
-    
-    /**
-     * 
-     * @param padding array of left, top, right, bottom padding
-     * @return
-     */
-    public boolean getPadding(int[] padding) {
-        padding[0] = mHorizontalPadding.mFirst; // left
-        padding[2] = mHorizontalPadding.mSecond; // right
-        padding[1] = mVerticalPadding.mFirst; // top
-        padding[3] = mVerticalPadding.mSecond; // bottom
-        return true;
-    }
-
-
-    public void draw(Graphics2D graphics2D, int x, int y, int scaledWidth, int scaledHeight) {
-        if (scaledWidth <= 1 || scaledHeight <= 1) {
-            return;
-        }
-
-        Graphics2D g = (Graphics2D)graphics2D.create();
-        g.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
-                RenderingHints.VALUE_INTERPOLATION_BILINEAR);
-        
-
-        try {
-            if (mPatches.size() == 0 || mHorizontalPatches.size() == 0 ||
-                    mVerticalPatches.size() == 0) {
-                g.drawImage(mImage, x, y, scaledWidth, scaledHeight, null);
-                return;
-            }
-
-            g.translate(x, y);
-            x = y = 0;
-            
-            computePatches(scaledWidth, scaledHeight);
-    
-            int fixedIndex = 0;
-            int horizontalIndex = 0;
-            int verticalIndex = 0;
-            int patchIndex = 0;
-    
-            boolean hStretch;
-            boolean vStretch;
-    
-            float vWeightSum = 1.0f;
-            float vRemainder = mRemainderVertical;
-    
-            vStretch = mVerticalStartWithPatch;
-            while (y < scaledHeight - 1) {
-                hStretch = mHorizontalStartWithPatch;
-    
-                int height = 0;
-                float vExtra = 0.0f;
-    
-                float hWeightSum = 1.0f;
-                float hRemainder = mRemainderHorizontal;
-    
-                while (x < scaledWidth - 1) {
-                    Rectangle r;
-                    if (!vStretch) {
-                        if (hStretch) {
-                            r = mHorizontalPatches.get(horizontalIndex++);
-                            float extra = r.width / mHorizontalPatchesSum;
-                            int width = (int) (extra * hRemainder / hWeightSum);
-                            hWeightSum -= extra;
-                            hRemainder -= width;
-                            g.drawImage(mImage, x, y, x + width, y + r.height, r.x, r.y,
-                                    r.x + r.width, r.y + r.height, null);
-                            x += width;
-                        } else {
-                            r = mFixed.get(fixedIndex++);
-                            g.drawImage(mImage, x, y, x + r.width, y + r.height, r.x, r.y,
-                                    r.x + r.width, r.y + r.height, null);
-                            x += r.width;
-                        }
-                        height = r.height;
-                    } else {
-                        if (hStretch) {
-                            r = mPatches.get(patchIndex++);
-                            vExtra = r.height / mVerticalPatchesSum;
-                            height = (int) (vExtra * vRemainder / vWeightSum);
-                            float extra = r.width / mHorizontalPatchesSum;
-                            int width = (int) (extra * hRemainder / hWeightSum);
-                            hWeightSum -= extra;
-                            hRemainder -= width;
-                            g.drawImage(mImage, x, y, x + width, y + height, r.x, r.y,
-                                    r.x + r.width, r.y + r.height, null);
-                            x += width;
-                        } else {
-                            r = mVerticalPatches.get(verticalIndex++);
-                            vExtra = r.height / mVerticalPatchesSum;
-                            height = (int) (vExtra * vRemainder / vWeightSum);
-                            g.drawImage(mImage, x, y, x + r.width, y + height, r.x, r.y,
-                                    r.x + r.width, r.y + r.height, null);
-                            x += r.width;
-                        }
-                        
-                    }
-                    hStretch = !hStretch;
-                }
-                x = 0;
-                y += height;
-                if (vStretch) {
-                    vWeightSum -= vExtra;
-                    vRemainder -= height;
-                }
-                vStretch = !vStretch;
-            }
-    
-        } finally {
-            g.dispose();
-        }
-    }
-    
-    void computePatches(int scaledWidth, int scaledHeight) {
-        boolean measuredWidth = false;
-        boolean endRow = true;
-
-        int remainderHorizontal = 0;
-        int remainderVertical = 0;
-
-        if (mFixed.size() > 0) {
-            int start = mFixed.get(0).y;
-            for (Rectangle rect : mFixed) {
-                if (rect.y > start) {
-                    endRow = true;
-                    measuredWidth = true;
-                }
-                if (!measuredWidth) {
-                    remainderHorizontal += rect.width;
-                }
-                if (endRow) {
-                    remainderVertical += rect.height;
-                    endRow = false;
-                    start = rect.y;
-                }
-            }
-        }
-
-        mRemainderHorizontal = scaledWidth - remainderHorizontal;
-
-        mRemainderVertical = scaledHeight - remainderVertical;
-
-        mHorizontalPatchesSum = 0;
-        if (mHorizontalPatches.size() > 0) {
-            int start = -1;
-            for (Rectangle rect : mHorizontalPatches) {
-                if (rect.x > start) {
-                    mHorizontalPatchesSum += rect.width;
-                    start = rect.x;
-                }
-            }
-        }
-
-        mVerticalPatchesSum = 0;
-        if (mVerticalPatches.size() > 0) {
-            int start = -1;
-            for (Rectangle rect : mVerticalPatches) {
-                if (rect.y > start) {
-                    mVerticalPatchesSum += rect.height;
-                    start = rect.y;
-                }
-            }
-        }
-    }
-
-    
-    private NinePatch(URL fileUrl, BufferedImage image) {
-        mFileUrl = fileUrl;
-        mImage = image;
-        
-        findPatches();
-    }
-    
-    private void findPatches() {
-        int width = mImage.getWidth();
-        int height = mImage.getHeight();
-
-        row = GraphicsUtilities.getPixels(mImage, 0, 0, width, 1, row);
-        column = GraphicsUtilities.getPixels(mImage, 0, 0, 1, height, column);
-
-        boolean[] result = new boolean[1];
-        Pair<List<Pair<Integer>>> left = getPatches(column, result);
-        mVerticalStartWithPatch = result[0];
-        
-        // compute the min size, based on the list of fixed sections, which is stored in 
-        // Pair.mFirst
-        mMinHeight = 0;
-        List<Pair<Integer>> fixedSections = left.mFirst;
-        for (Pair<Integer> section : fixedSections) {
-            mMinHeight += section.mSecond - section.mFirst;
-        }
-
-        result = new boolean[1];
-        Pair<List<Pair<Integer>>> top = getPatches(row, result);
-        mHorizontalStartWithPatch = result[0];
-
-        // compute the min size, based on the list of fixed sections, which is stored in 
-        // Pair.mFirst
-
-        mMinWidth = 0;
-        fixedSections = top.mFirst;
-        for (Pair<Integer> section : fixedSections) {
-            mMinWidth += section.mSecond - section.mFirst;
-        }
-
-        mFixed = getRectangles(left.mFirst, top.mFirst);
-        mPatches = getRectangles(left.mSecond, top.mSecond);
-
-        if (mFixed.size() > 0) {
-            mHorizontalPatches = getRectangles(left.mFirst, top.mSecond);
-            mVerticalPatches = getRectangles(left.mSecond, top.mFirst);
-        } else {
-            mHorizontalPatches = mVerticalPatches = new ArrayList<Rectangle>(0);
-        }
-
-        row = GraphicsUtilities.getPixels(mImage, 0, height - 1, width, 1, row);
-        column = GraphicsUtilities.getPixels(mImage, width - 1, 0, 1, height, column);
-
-        top = getPatches(row, result);
-        mHorizontalPadding = getPadding(top.mFirst);
-
-        left = getPatches(column, result);
-        mVerticalPadding = getPadding(left.mFirst);
-        
-        mHorizontalPatchesSum = 0;
-        if (mHorizontalPatches.size() > 0) {
-            int start = -1;
-            for (Rectangle rect : mHorizontalPatches) {
-                if (rect.x > start) {
-                    mHorizontalPatchesSum += rect.width;
-                    start = rect.x;
-                }
-            }
-        }
-
-        mVerticalPatchesSum = 0;
-        if (mVerticalPatches.size() > 0) {
-            int start = -1;
-            for (Rectangle rect : mVerticalPatches) {
-                if (rect.y > start) {
-                    mVerticalPatchesSum += rect.height;
-                    start = rect.y;
-                }
-            }
-        }
-
-    }
-    
-    private Pair<Integer> getPadding(List<Pair<Integer>> pairs) {
-        if (pairs.size() == 0) {
-            return new Pair<Integer>(0, 0);
-        } else if (pairs.size() == 1) {
-            if (pairs.get(0).mFirst == 1) {
-                return new Pair<Integer>(pairs.get(0).mSecond - pairs.get(0).mFirst, 0);
-            } else {
-                return new Pair<Integer>(0, pairs.get(0).mSecond - pairs.get(0).mFirst);
-            }
-        } else {
-            int index = pairs.size() - 1;
-            return new Pair<Integer>(pairs.get(0).mSecond - pairs.get(0).mFirst,
-                    pairs.get(index).mSecond - pairs.get(index).mFirst);
-        }
-    }
-    
-    private List<Rectangle> getRectangles(List<Pair<Integer>> leftPairs,
-            List<Pair<Integer>> topPairs) {
-        List<Rectangle> rectangles = new ArrayList<Rectangle>();
-        for (Pair<Integer> left : leftPairs) {
-            int y = left.mFirst;
-            int height = left.mSecond - left.mFirst;
-            for (Pair<Integer> top: topPairs) {
-                int x = top.mFirst;
-                int width = top.mSecond - top.mFirst;
-
-                rectangles.add(new Rectangle(x, y, width, height));
-            }
-        }
-        return rectangles;
-    }
-    
-    private Pair<List<Pair<Integer>>> getPatches(int[] pixels, boolean[] startWithPatch) {
-        int lastIndex = 1;
-        int lastPixel = pixels[1];
-        boolean first = true;
-
-        List<Pair<Integer>> fixed = new ArrayList<Pair<Integer>>();
-        List<Pair<Integer>> patches = new ArrayList<Pair<Integer>>();
-        
-        for (int i = 1; i < pixels.length - 1; i++) {
-            int pixel = pixels[i];
-            if (pixel != lastPixel) {
-                if (lastPixel == 0xFF000000) {
-                    if (first) startWithPatch[0] = true;
-                    patches.add(new Pair<Integer>(lastIndex, i));
-                } else {
-                    fixed.add(new Pair<Integer>(lastIndex, i));
-                }
-                first = false;
-
-                lastIndex = i;
-                lastPixel = pixel;
-            }
-        }
-        if (lastPixel == 0xFF000000) {
-            if (first) startWithPatch[0] = true;
-            patches.add(new Pair<Integer>(lastIndex, pixels.length - 1));
-        } else {
-            fixed.add(new Pair<Integer>(lastIndex, pixels.length - 1));
-        }
-
-        if (patches.size() == 0) {
-            patches.add(new Pair<Integer>(1, pixels.length - 1));
-            startWithPatch[0] = true;
-            fixed.clear();
-        }
-        return new Pair<List<Pair<Integer>>>(fixed, patches);
-    }
-
-    private static void ensure9Patch(BufferedImage image) {
-        int width = image.getWidth();
-        int height = image.getHeight();
-        for (int i = 0; i < width; i++) {
-            int pixel = image.getRGB(i, 0);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(i, 0, 0);
-            }
-            pixel = image.getRGB(i, height - 1);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(i, height - 1, 0);
-            }
-        }
-        for (int i = 0; i < height; i++) {
-            int pixel = image.getRGB(0, i);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(0, i, 0);
-            }
-            pixel = image.getRGB(width - 1, i);
-            if (pixel != 0 && pixel != 0xFF000000) {
-                image.setRGB(width - 1, i, 0);
-            }
-        }
-    }
-
-    private static BufferedImage convertTo9Patch(BufferedImage image) {
-        BufferedImage buffer = GraphicsUtilities.createTranslucentCompatibleImage(
-                image.getWidth() + 2, image.getHeight() + 2);
-
-        Graphics2D g2 = buffer.createGraphics();
-        g2.drawImage(image, 1, 1, null);
-        g2.dispose();
-
-        return buffer;
-    }
-    
-    static class Pair<E> {
-        E mFirst;
-        E mSecond;
-
-        Pair(E first, E second) {
-            mFirst = first;
-            mSecond = second;
-        }
-
-        @Override
-        public String toString() {
-            return "Pair[" + mFirst + ", " + mSecond + "]";
-        }
-    }
-}
diff --git a/tools/runtest b/tools/runtest
deleted file mode 100755
index 6280910..0000000
--- a/tools/runtest
+++ /dev/null
@@ -1,360 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Options and default values
-# TODO: other options ideas:
-#   pass options to am (then remove some of the more specific options)
-# TODO capture more non-error output when not -v
-# TODO read configs from vendor/*, not just from vendor/google
-
-optListTests=0
-optSkipBuild=0
-optPreview=0
-optRawmode=0
-optSuiteAssignmentMode=0
-optAdbTarget=""
-optVerbose=0
-optWaitForDebugger=0
-optTestClass=""
-optTestMethod=""
-optUserTests=${HOME}/.android/runtest.rc
-
-#
-# process command-line options.  You must pass them into this function.
-# TODO error messages on once-only or mutually-exclusive options
-#
-function processOptions() {
-  while getopts "l b n a r d e s: v w c:t:u:" opt ; do  
-    case ${opt} in  
-      l ) optListTests=1 ;;
-      b ) optSkipBuild=1 ;;
-      n ) optPreview=1 ;;
-      r ) optRawMode=1 ;;
-      a ) optSuiteAssignmentMode=1 ;;
-      d ) optAdbTarget="-d" ;;
-      e ) optAdbTarget="-e" ;;
-      s ) optAdbTarget="-s ${OPTARG}" ;;
-      v ) optVerbose=1 ;;
-      w ) optWaitForDebugger=1 ;;
-      c ) optTestClass=${OPTARG} ;;
-      t ) optTestMethod=${OPTARG} ;;
-      u ) optUserTests=${OPTARG} ;;
-      esac
-  done
-}
-
-#
-# Show the command usage and options
-#
-function showUsage() {
-  echo "usage: The $progName script works in two ways.  You can query it for a list" >&2
-  echo "       of tests, or you can launch a test, test case, or test suite." >&2
-  echo "" >&2
-  echo "       $progName -l           # To view the list of tests" >&2
-  echo "" >&2
-  echo "       $progName              # To launch tests" >&2
-  echo "           [-b]                     # Skip build - just launch" >&2
-  echo "           [-n]                     # Do not execute, just preview commands" >&2
-  echo "           [-r]                     # Raw mode (for output to other tools)" >&2
-  echo "           [-a]                     # Suite assignment (for details & usage" >&2
-  echo "                                    #   see InstrumentationTestRunner)" >&2
-  echo "           [-v]                     # Increase verbosity of ${progName}" >&2
-  echo "           [-w]                     # Wait for debugger before launching tests" >&2
-  echo "           [-c test-class]          # Restrict test to a specific class" >&2
-  echo "           [-t test-method]         # Restrict test to a specific method" >&2
-  echo "           [-e | -d | -s ser-num]   # use emulator, device, or serial number" >&2
-  echo "           [-u user-tests-file]     # Alternate source of user definitions" >&2
-  echo "           short-test-name          # (req'd) test configuration to launch" >&2
-}
-
-# The list below are built-in test definitions.  You can also define your own
-# tests by creating a file named "~/.android/runtest.rc" and adding them to that
-# file.  (No array needed, just plain lines of text).
-#
-# Tests are defined by entries with the following format:
-# <short-name> <build-path> <test-package> <test-class>
-#              <testrunner-package> <testrunner-component>
-#
-# These map to the following commands:
-#   (if test-class = "#")
-#      adb shell am instrument -w \
-#        <testrunner-package>/<testrunner-component>
-#   (else)
-#      adb shell am instrument -w \
-#        -e class <test-package>.<test-class> \
-#        <testrunner-package>/<testrunner-component>
-#
-# In order to define the most common cases simply, "#" can be used for some of
-# the fields, with the following default values:
-#   <build-path> = "#":  skip build/sync step
-#   <test-package> = "#": test class is fully qualified with package
-#   <test-class> = "#":  omit "-e class" section
-#   <testrunner-package> = "#":   use same value as test-package
-#   <testrunner-component> = "#":  use "android.test.InstrumentationTestRunner"
-#
-# TODO: fields may be omitted completely if the trailing values are all "#"
-# TODO: this should be a here doc instead of an array
-
-knownTests=(
-  # NAME      BUILD DIR               <test-package> <test-class> <testrunner-package> <testrunner-component>
-
-  # system-wide tests
-  "framework  frameworks/base/tests/FrameworkTest # com.android.frameworktest.AllTests com.android.frameworktest.tests #"
-  "android    frameworks/base/tests/AndroidTests  com.android.unit_tests AndroidTests # #"
-  "smoke      frameworks/base/tests/SmokeTest     com.android.smoketest # com.android.smoketest.tests #"
-  "core       frameworks/base/tests/CoreTests     # android.core.CoreTests android.core #"
-  "libcore    frameworks/base/tests/CoreTests     # android.core.JavaTests android.core #"
-  "apidemos   development/samples/ApiDemos        com.example.android.apis # com.example.android.apis.tests #"
-  "launchperf development/apps/launchperf         com.android.launchperf # # .SimpleActivityLaunchPerformance"
-
-  # targeted framework tests
-  "heap       frameworks/base/tests/AndroidTests  com.android.unit_tests HeapTest # #"
-  "activity   frameworks/base/tests/AndroidTests  com.android.unit_tests activity.ActivityTests # #"
-  "deadlock  tests/Deadlock                       com.android.deadlock # com.android.deadlock.tests #"
-  "syncadapter vendor/google/tests/AbstractGDataSyncAdapterTest # # com.google.android.providers.abstractgdatasyncadaptertests #"
-  "tablemerger frameworks/base/tests/FrameworkTest # android.content.AbstractTableMergerTest com.android.frameworktest.tests #"
-  
-  # selected app tests
-  "browser    packages/apps/Browser            com.android.browser # # .BrowserTestRunner"
-  "browserfunc packages/apps/Browser           com.android.browser # # .BrowserFunctionalTestRunner"
-  "calendar   packages/apps/Calendar/tests     com.android.calendar.tests # # #"
-  "calprov    packages/providers/CalendarProvider   com.android.providers.calendar # com.android.providers.calendar.tests #"
-  "camera     tests/Camera            com.android.cameratests # # CameraInstrumentationTestRunner"
-  "contactsprov packages/providers/GoogleContactsProvider/tests com.android.providers.contacts # com.android.providers.contactstests #"
-  "email      packages/apps/Email              com.android.email # com.android.email.tests #"
-  "emailsmall packages/apps/Email              com.android.email SmallTests com.android.email.tests #"
-  "media      tests/MediaFrameworkTest    com.android.mediaframeworktest # # .MediaFrameworkTestRunner"
-  "mediaunit  tests/MediaFrameworkTest com.android.mediaframeworktest # # .MediaFrameworkUnitTestRunner"
-  "mediaprov  tests/MediaProvider     com.android.mediaprovidertests # # .MediaProviderTestsInstrumentation"
-  "mms        packages/apps/Mms                # # com.android.mms.tests com.android.mms.ui.MMSInstrumentationTestRunner"
-  "mmslaunch  packages/apps/Mms                # # com.android.mms.tests com.android.mms.SmsLaunchPerformance"
-  "phone      tests/Phone             com.android.phonetests # # .PhoneInstrumentationTestRunner"
-  "phonestress tests/Phone            com.android.phonetests # # .PhoneInstrumentationStressTestRunner"
-  "ringtone   tests/RingtoneSettings  com.android.ringtonesettingstests # # .RingtoneSettingsInstrumentationTestRunner"
-)
-
-#
-# Searches for a runtest.rc file in a given directory and, if found, prepends it to
-# the list of known tests.
-#
-function readConfigFile () {
-  rcFile=$1
-  if [[ -f ${rcFile} ]] ; then
-    declare -a lines
-    exec 3<${rcFile} || exit
-    while read curline <&3; do
-      if [[ -z ${curline} || ${curline:0:1} = "#" ]]; then
-        continue
-      fi
-      lines=("${lines[@]}" "${curline}")
-    done
-    exec 3<&-
-
-    # now prepend the user lines (so they can override defaults)
-    knownTests=("${lines[@]}" "${knownTests[@]}")
-  fi
-}
-
-#
-# Searches for a specific test in the knownTests array.  If found, writes out
-# the remaining elements in the definition line (not including the test name).
-#
-function findTest() {
-  count=${#knownTests[@]}
-  index=0
-  while [[ ${index} -lt ${count} ]]
-  do
-    # If the first word in the entry matches the argument...
-    test=(${knownTests[$index]})
-    if [[ ${test[0]} = $1 ]] ; then
-      # Print all but the first word
-      echo ${test[@]:1}
-      return
-    fi
-    let "index = $index + 1"
-  done
-}
-
-#
-# Generate a simple listing of available tests
-#
-function dumpTests() {
-  echo "The following tests are currently defined:"
-  count=${#knownTests[@]}
-  index=0
-  while [[ ${index} -lt ${count} ]]
-  do
-    test=(${knownTests[$index]})
-    echo "  " ${test[0]}
-    let "index = $index + 1"
-  done
-}
-
-#
-# Writes the full pathname of the "top" of the development tree, as set by envsetup & lunch.
-# (based on gettop() from envsetup.sh)
-#
-function gettop {
-  TOPFILE=build/core/envsetup.mk
-  if [[ -n ${TOP} && -f ${TOP}/${TOPFILE} ]] ; then
-    echo ${TOP}
-  else
-    if [[ -f ${TOPFILE} ]] ; then
-      echo ${PWD}
-    else
-      # We redirect cd to /dev/null in case it's aliased to
-      # a command that prints something as a side-effect
-      # (like pushd)
-      HERE=${PWD}
-      T=
-    # while [ \( ! \( -f ${TOPFILE} \) \) -a \( $PWD != "/" \) ]; do
-      while [[ ! -f ${TOPFILE} && ${PWD} != "/" ]] ; do
-        cd .. > /dev/null
-        T=${PWD}
-      done
-      cd ${HERE} > /dev/null
-      if [[ -f ${T}/${TOPFILE} ]]; then
-        echo ${T}
-      fi
-    fi
-  fi
-}
-
-#
-# Captures the "mmm" command from envsetup.sh
-#
-function call_mmm() {
-  TOP=$(gettop)
-  if [[ -n ${TOP} ]] ; then
-    . ${TOP}/build/envsetup.sh
-    mmm ${TOP}/$@
-  fi
-}
-
-# main script
-
-progName=$(basename $0)
-
-if [[ $# -eq 0 ]] ; then
-  showUsage
-  exit 1
-fi
-
-processOptions $@
-shift $((OPTIND-1))
-
-readConfigFile $optUserTests
-# TODO: Read from *any* vendor/*/runtest.rc
-readConfigFile $(gettop)/vendor/google/runtest.rc
-
-# if requested, list all tests and halt
-if [[ ${optListTests} -ne 0 ]] ; then
-  dumpTests
-  exit 0
-fi
-
-testInfo=($(findTest $1))
-if [[ ${#testInfo[@]} -eq 5 ]] ; then
-  # break out test definition elements
-  buildPath=${testInfo[0]}
-  testPackage=${testInfo[1]}
-  testClass=${testInfo[2]}
-  runnerPackage=${testInfo[3]}
-  runnerComponent=${testInfo[4]}
-
-  # replace wildcards with default values
-  if [[ ${testPackage} == "#" ]] ; then
-    testPackage=
-  fi
-  if [[ ${runnerPackage} == "#" ]] ; then
-    runnerPackage=$testPackage
-  fi
-  if [[ ${runnerComponent} == "#" ]] ; then
-    runnerComponent="android.test.InstrumentationTestRunner"
-  fi
-
-  if [[ -n ${optTestClass} ]] ; then
-    testClass=$optTestClass
-  fi
-
-  # build & sync, if requested
-  if [[ ${optSkipBuild} -eq 0 ]] ; then
-    if [[ ${buildPath} != "#" ]] ; then
-      if [[ $optVerbose -ne 0 || ${optPreview} -ne 0 ]] ; then
-        echo mmm ${buildPath} "&&" adb ${optAdbTarget} remount "&&" adb ${optAdbTarget} sync
-      fi
-      if [[ ${optPreview} -eq 0 ]] ; then
-        call_mmm ${buildPath} && adb ${optAdbTarget} remount && adb ${optAdbTarget} sync
-        buildResult=$?
-      else
-        buildResult=0
-      fi
-      if [[ $buildResult -ne 0 ]] ; then
-        exit ${buildResult}
-      fi
-      # finally, sleep a bit.  this is a hack.  it gives the package manager time to
-      # install the package(s) that were just synced.  this causes a reduction in the number
-      # of false failures, but it's not a perfect solution.
-      sleep 2
-    fi
-  fi
-
-  # setup additional clauses for the command
-  classOptions=""
-  if [[ ${testClass} != "#" ]] ; then
-    if [[ -z ${testPackage} ]] ; then
-      classOptions="-e class ${testClass}"
-    else
-      classOptions="-e class ${testPackage}.${testClass}"
-    fi
-    if [[ -n ${optTestMethod} ]] ; then
-      classOptions=${classOptions}#${optTestMethod}
-    fi
-  fi
-  debugOptions=""
-  if [[ ${optWaitForDebugger} -ne 0 ]] ; then
-    debugOptions="-e debug true"
-  fi
-  if [[ ${optSuiteAssignmentMode} -ne 0 ]] ; then
-    debugOptions="-e suiteAssignment true "${debugOptions}
-  fi
-  if [[ ${optRawMode} -ne 0 ]] ; then
-    debugOptions="-r "${debugOptions}
-  fi
-
-  # "prevent" a race condition where we try to run the tests before they're
-  # actually installed
-  sleep 2
-  
-  # now run the command
-  if [[ $optVerbose -ne 0 || ${optPreview} -ne 0 ]] ; then
-    echo adb ${optAdbTarget} shell am instrument -w \
-      ${debugOptions} \
-      ${classOptions} \
-      ${runnerPackage}/${runnerComponent}
-  fi
-  if [[ ${optPreview} -eq 0 ]] ; then
-    adb ${optAdbTarget} shell am instrument -w \
-      ${debugOptions} \
-      ${classOptions} \
-      ${runnerPackage}/${runnerComponent}
-  fi
-  exit 0
-else
-  echo "$progName: unknown test \"$1\"" >&2
-  exit 1
-fi
-
diff --git a/tools/screenshot/.classpath b/tools/screenshot/.classpath
deleted file mode 100644
index b0326c8..0000000
--- a/tools/screenshot/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/ddmlib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/screenshot/.project b/tools/screenshot/.project
deleted file mode 100644
index f5d3f51..0000000
--- a/tools/screenshot/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>screenshot</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/screenshot/Android.mk b/tools/screenshot/Android.mk
deleted file mode 100644
index 7cf9090..0000000
--- a/tools/screenshot/Android.mk
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-SCREENSHOT2_LOCAL_DIR := $(call my-dir)
-include $(SCREENSHOT2_LOCAL_DIR)/etc/Android.mk
-include $(SCREENSHOT2_LOCAL_DIR)/src/Android.mk
diff --git a/tools/screenshot/etc/Android.mk b/tools/screenshot/etc/Android.mk
deleted file mode 100644
index 5107535..0000000
--- a/tools/screenshot/etc/Android.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := screenshot2
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/screenshot/etc/manifest.txt b/tools/screenshot/etc/manifest.txt
deleted file mode 100644
index f52874a..0000000
--- a/tools/screenshot/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.screenshot.Screenshot
diff --git a/tools/screenshot/etc/screenshot2 b/tools/screenshot/etc/screenshot2
deleted file mode 100755
index 10b921a..0000000
--- a/tools/screenshot/etc/screenshot2
+++ /dev/null
@@ -1,74 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=screenshot2.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-if [ debug = "$1" ]; then
-    # add this in for debugging
-    java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-else
-    java_debug=
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec java -Xmx128M $os_opts $java_debug -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -Dcom.android.screenshot.bindir="$progdir" -jar "$jarpath" "$@"
diff --git a/tools/screenshot/src/Android.mk b/tools/screenshot/src/Android.mk
deleted file mode 100644
index 8b5ea3a..0000000
--- a/tools/screenshot/src/Android.mk
+++ /dev/null
@@ -1,27 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	ddmlib
-LOCAL_MODULE := screenshot2
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/screenshot/src/com/android/screenshot/Screenshot.java b/tools/screenshot/src/com/android/screenshot/Screenshot.java
deleted file mode 100644
index 40ceffa..0000000
--- a/tools/screenshot/src/com/android/screenshot/Screenshot.java
+++ /dev/null
@@ -1,287 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.screenshot;
-
-import com.android.ddmlib.AndroidDebugBridge;
-import com.android.ddmlib.Device;
-import com.android.ddmlib.Log;
-import com.android.ddmlib.RawImage;
-import com.android.ddmlib.Log.ILogOutput;
-import com.android.ddmlib.Log.LogLevel;
-
-import java.awt.image.BufferedImage;
-import java.io.File;
-import java.io.IOException;
-
-import javax.imageio.ImageIO;
-
-/**
- * Connects to a device using ddmlib and dumps its event log as long as the device is connected. 
- */
-public class Screenshot {
-
-    public static void main(String[] args) {
-        boolean device = false;
-        boolean emulator = false;
-        String serial = null;
-        String filepath = null;
-        boolean landscape = false;
-        
-        if (args.length == 0) {
-            printUsageAndQuit();
-        }
-
-        // parse command line parameters.
-        int index = 0;
-        do {
-            String argument = args[index++];
-
-            if ("-d".equals(argument)) {
-                if (emulator || serial != null) {
-                    printAndExit("-d conflicts with -e and -s", false /* terminate */);
-                }
-                device = true;
-            } else if ("-e".equals(argument)) {
-                if (device || serial != null) {
-                    printAndExit("-e conflicts with -d and -s", false /* terminate */);
-                }
-                emulator = true;
-            } else if ("-s".equals(argument)) {
-                // quick check on the next argument.
-                if (index == args.length) {
-                    printAndExit("Missing serial number after -s", false /* terminate */);
-                }
-
-                if (device || emulator) {
-                    printAndExit("-s conflicts with -d and -e", false /* terminate */);
-                }
-                
-                serial = args[index++];
-            } else if ("-l".equals(argument)) {
-                landscape = true;
-            } else {
-                // get the filepath and break.
-                filepath = argument;
-
-                // should not be any other device.
-                if (index < args.length) {
-                    printAndExit("Too many arguments!", false /* terminate */);
-                }
-            }
-        } while (index < args.length);
-        
-        if (filepath == null) {
-            printUsageAndQuit();
-        }
-        
-        Log.setLogOutput(new ILogOutput() {
-            public void printAndPromptLog(LogLevel logLevel, String tag, String message) {
-                System.err.println(logLevel.getStringValue() + ":" + tag + ":" + message);
-            }
-
-            public void printLog(LogLevel logLevel, String tag, String message) {
-                System.err.println(logLevel.getStringValue() + ":" + tag + ":" + message);
-            }
-        });
-        
-        // init the lib
-        // [try to] ensure ADB is running
-        String adbLocation = System.getProperty("com.android.screenshot.bindir"); //$NON-NLS-1$
-        if (adbLocation != null && adbLocation.length() != 0) {
-            adbLocation += File.separator + "adb"; //$NON-NLS-1$
-        } else {
-            adbLocation = "adb"; //$NON-NLS-1$
-        }
-
-        AndroidDebugBridge.init(false /* debugger support */);
-        
-        try {
-            AndroidDebugBridge bridge = AndroidDebugBridge.createBridge(
-                    adbLocation, true /* forceNewBridge */);
-            
-            // we can't just ask for the device list right away, as the internal thread getting
-            // them from ADB may not be done getting the first list.
-            // Since we don't really want getDevices() to be blocking, we wait here manually.
-            int count = 0;
-            while (bridge.hasInitialDeviceList() == false) {
-                try {
-                    Thread.sleep(100);
-                    count++;
-                } catch (InterruptedException e) {
-                    // pass
-                }
-                
-                // let's not wait > 10 sec.
-                if (count > 100) {
-                    System.err.println("Timeout getting device list!");
-                    return;
-                }
-            }
-
-            // now get the devices
-            Device[] devices = bridge.getDevices();
-            
-            if (devices.length == 0) {
-                printAndExit("No devices found!", true /* terminate */);
-            }
-            
-            Device target = null;
-            
-            if (emulator || device) {
-                for (Device d : devices) {
-                    // this test works because emulator and device can't both be true at the same
-                    // time.
-                    if (d.isEmulator() == emulator) {
-                        // if we already found a valid target, we print an error and return.
-                        if (target != null) {
-                            if (emulator) {
-                                printAndExit("Error: more than one emulator launched!",
-                                        true /* terminate */);
-                            } else {
-                                printAndExit("Error: more than one device connected!",true /* terminate */);
-                            }
-                        }
-                        target = d;
-                    }
-                }
-            } else if (serial != null) {
-                for (Device d : devices) {
-                    if (serial.equals(d.getSerialNumber())) {
-                        target = d;
-                        break;
-                    }
-                }
-            } else {
-                if (devices.length > 1) {
-                    printAndExit("Error: more than one emulator or device available!",
-                            true /* terminate */);
-                }
-                target = devices[0];
-            }
-            
-            if (target != null) {
-                try {
-                    System.out.println("Taking screenshot from: " + target.getSerialNumber());
-                    getDeviceImage(target, filepath, landscape);
-                    System.out.println("Success.");
-                } catch (IOException e) {
-                    e.printStackTrace();
-                }
-            } else {
-                printAndExit("Could not find matching device/emulator.", true /* terminate */);
-            }
-        } finally {
-            AndroidDebugBridge.terminate();
-        }
-    }
-    
-    /*
-     * Grab an image from an ADB-connected device.
-     */
-    private static void getDeviceImage(Device device, String filepath, boolean landscape)
-            throws IOException {
-        RawImage rawImage;
-
-        try {
-            rawImage = device.getScreenshot();
-        }
-        catch (IOException ioe) {
-            printAndExit("Unable to get frame buffer: " + ioe.getMessage(), true /* terminate */);
-            return;
-        }
-
-        // device/adb not available?
-        if (rawImage == null)
-            return;
-
-        assert rawImage.bpp == 16;
-        
-        BufferedImage image;
-        
-        if (landscape) {
-            // convert raw data to an Image
-            image = new BufferedImage(rawImage.height, rawImage.width,
-                    BufferedImage.TYPE_INT_ARGB);
-            
-            byte[] buffer = rawImage.data;
-            int index = 0;
-            for (int y = 0 ; y < rawImage.height ; y++) {
-                for (int x = 0 ; x < rawImage.width ; x++) {
-                    
-                    int value = buffer[index++] & 0x00FF;
-                    value |= (buffer[index++] << 8) & 0x0FF00;
-                    
-                    int r = ((value >> 11) & 0x01F) << 3;
-                    int g = ((value >> 5) & 0x03F) << 2;
-                    int b = ((value >> 0) & 0x01F) << 3;
-                    
-                    value = 0xFF << 24 | r << 16 | g << 8 | b;
-                    
-                    image.setRGB(y, rawImage.width - x - 1, value);
-                }
-            }
-        } else {
-            // convert raw data to an Image
-            image = new BufferedImage(rawImage.width, rawImage.height,
-                    BufferedImage.TYPE_INT_ARGB);
-            
-            byte[] buffer = rawImage.data;
-            int index = 0;
-            for (int y = 0 ; y < rawImage.height ; y++) {
-                for (int x = 0 ; x < rawImage.width ; x++) {
-                    
-                    int value = buffer[index++] & 0x00FF;
-                    value |= (buffer[index++] << 8) & 0x0FF00;
-                    
-                    int r = ((value >> 11) & 0x01F) << 3;
-                    int g = ((value >> 5) & 0x03F) << 2;
-                    int b = ((value >> 0) & 0x01F) << 3;
-                    
-                    value = 0xFF << 24 | r << 16 | g << 8 | b;
-                    
-                    image.setRGB(x, y, value);
-                }
-            }
-        }
-        
-        if (!ImageIO.write(image, "png", new File(filepath))) {
-            throw new IOException("Failed to find png writer");
-        }
-    }
-    
-    private static void printUsageAndQuit() {
-        // 80 cols marker:  01234567890123456789012345678901234567890123456789012345678901234567890123456789
-        System.out.println("Usage: screenshot2 [-d | -e | -s SERIAL] [-l] OUT_FILE");
-        System.out.println("");
-        System.out.println("    -d      Uses the first device found.");
-        System.out.println("    -e      Uses the first emulator found.");
-        System.out.println("    -s      Targets the device by serial number.");
-        System.out.println("");
-        System.out.println("    -l      Rotate images for landscape mode.");
-        System.out.println("");
-        
-        System.exit(1);
-    }
-    
-    private static void printAndExit(String message, boolean terminate) {
-        System.out.println(message);
-        if (terminate) {
-            AndroidDebugBridge.terminate();
-        }
-        System.exit(1);
-    }
-}
diff --git a/tools/scripts/AndroidManifest.alias.template b/tools/scripts/AndroidManifest.alias.template
deleted file mode 100644
index b1be4c8..0000000
--- a/tools/scripts/AndroidManifest.alias.template
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-      package="PACKAGE"
-      android:versionCode="1"
-      android:versionName="1.0">
-    <application android:hasCode="false">
-        <activity android:name="android.app.AliasActivity" android:label="@string/app_name">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-            <meta-data android:name="android.app.alias" android:resource="@xml/alias" />
-        </activity>
-    </application>
-</manifest> 
diff --git a/tools/scripts/AndroidManifest.template b/tools/scripts/AndroidManifest.template
deleted file mode 100644
index 2b06e76..0000000
--- a/tools/scripts/AndroidManifest.template
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-      package="PACKAGE"
-      android:versionCode="1"
-      android:versionName="1.0">
-    <application android:label="@string/app_name">
-        <activity android:name=".ACTIVITY_NAME"
-                  android:label="@string/app_name">
-            <intent-filter>
-                <action android:name="android.intent.action.MAIN" />
-                <category android:name="android.intent.category.LAUNCHER" />
-            </intent-filter>
-        </activity>
-    </application>
-</manifest> 
diff --git a/tools/scripts/AndroidManifest.tests.template b/tools/scripts/AndroidManifest.tests.template
deleted file mode 100644
index 1f7d827..0000000
--- a/tools/scripts/AndroidManifest.tests.template
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- package name must be unique so suffix with "tests" so package loader doesn't ignore us -->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
-          package="PACKAGE.tests"
-          android:versionCode="1"
-          android:versionName="1.0">
-    <!-- We add an application tag here just so that we can indicate that
-         this package needs to link against the android.test library,
-         which is needed when building test cases. -->
-    <application>
-        <uses-library android:name="android.test.runner" />
-    </application>
-    <!--
-    This declares that this application uses the instrumentation test runner targeting
-    the package of PACKAGE.  To run the tests use the command:
-    "adb shell am instrument -w PACKAGE.tests/android.test.InstrumentationTestRunner"
-    -->
-    <instrumentation android:name="android.test.InstrumentationTestRunner"
-                     android:targetPackage="PACKAGE"
-                     android:label="Tests for ACTIVITY_NAME"/>
-</manifest>
diff --git a/tools/scripts/README_add-ons.txt b/tools/scripts/README_add-ons.txt
deleted file mode 100644
index b8eb1d6..0000000
--- a/tools/scripts/README_add-ons.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-Add-on folder.
-Drop vendor supplied SDK add-on in this folder.
\ No newline at end of file
diff --git a/tools/scripts/add-accounts b/tools/scripts/add-accounts
deleted file mode 100755
index d2cddc0..0000000
--- a/tools/scripts/add-accounts
+++ /dev/null
@@ -1,131 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""
-A faux Setup Wizard.  Stuffs one or two usernames + passwords into the
-database on the device.
-"""
-
-import sys
-if sys.hexversion < 0x02040000:
-  print "This script requires python 2.4 or higher."
-  sys.exit(1)
-
-import getpass
-import subprocess
-import time
-import sha
-
-DB = "/data/data/com.google.android.googleapps/databases/accounts.db"
-
-def RunCmd(args):
-  proc = subprocess.Popen(args, stdout=subprocess.PIPE)
-  out = proc.stdout.read()
-  if proc.wait():
-    print
-    print "failed: %s" % " ".join(args)
-    return None
-  return out
-
-def GetProp(adb_flags, name):
-  args = ("adb",) + adb_flags + ("shell", "su", "root",
-                                 "/system/bin/getprop", name)
-  return RunCmd(args)
-
-def SetProp(adb_flags, name, value):
-  args = ("adb",) + adb_flags + ("shell", "su", "root",
-                                 "/system/bin/setprop", name, value)
-  return RunCmd(args)
-
-def DbExists(adb_flags):
-  args = ("adb",) + adb_flags + ("shell", "su", "root",
-                                 "/system/bin/ls", DB)
-  result = RunCmd(args)
-  if result is None: return None
-  return "No such file" not in result
-
-def main(argv):
-  if len(argv) == 1:
-    print ("usage: %s [adb flags] "
-           "[<dasher address[:password]>] "
-           "[<gmail address[:password]>]") % (argv[0],)
-    sys.exit(2)
-
-  argv = argv[1:]
-
-  gmail = None
-  dasher = None
-  while argv and "@" in argv[-1]:
-    addr = argv.pop()
-    if "@gmail.com" in addr or "@googlemail.com" in addr:
-      gmail = addr
-    else:
-      dasher = addr
-
-  adb_flags = tuple(argv)
-
-  while True:
-    db = DbExists(adb_flags)
-    if db is None:
-      print "failed to contact device; will retry in 3 seconds"
-      time.sleep(3)
-      continue
-
-    if db:
-      print
-      print "GoogleLoginService has already started on this device;"
-      print "it's too late to use this script to add accounts."
-      print
-      print "This script only works on a freshly-wiped device (or "
-      print "emulator) while booting for the first time."
-      print
-      break
-
-    hosted_account = GetProp(adb_flags, "ro.config.hosted_account").strip()
-    google_account = GetProp(adb_flags, "ro.config.google_account").strip()
-
-    if dasher and hosted_account:
-      print
-      print "A dasher account is already configured on this device;"
-      print "can't add", hosted_account
-      print
-      dasher = None
-
-    if gmail and google_account:
-      print
-      print "A google account is already configured on this device;"
-      print "can't add", google_account
-      print
-      gmail = None
-
-    if not gmail and not dasher: break
-
-    if dasher:
-      SetProp(adb_flags, "ro.config.hosted_account", dasher)
-      print "set hosted_account to", dasher
-    if gmail:
-      SetProp(adb_flags, "ro.config.google_account", gmail)
-      print "set google_account to", gmail
-
-    break
-
-
-
-
-
-
-if __name__ == "__main__":
-  main(sys.argv)
diff --git a/tools/scripts/add-accounts-sdk b/tools/scripts/add-accounts-sdk
deleted file mode 100755
index bb3447f..0000000
--- a/tools/scripts/add-accounts-sdk
+++ /dev/null
@@ -1,128 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""
-A faux Setup Wizard.  Stuffs one or two usernames + passwords into the
-database on the device.
-"""
-
-import sys
-if sys.hexversion < 0x02040000:
-  print "This script requires python 2.4 or higher."
-  sys.exit(1)
-
-import getpass
-import subprocess
-import time
-import sha
-
-DB = "/data/data/com.google.android.googleapps/databases/accounts.db"
-
-def RunCmd(args):
-  proc = subprocess.Popen(args, stdout=subprocess.PIPE)
-  out = proc.stdout.read()
-  if proc.wait():
-    print
-    print "failed: %s" % " ".join(args)
-    return None
-  return out
-
-def GetProp(adb_flags, name):
-  args = ("adb",) + adb_flags + ("shell", "/system/bin/getprop", name)
-  return RunCmd(args)
-
-def SetProp(adb_flags, name, value):
-  args = ("adb",) + adb_flags + ("shell", "/system/bin/setprop", name, value)
-  return RunCmd(args)
-
-def DbExists(adb_flags):
-  args = ("adb",) + adb_flags + ("shell", "/system/bin/ls", DB)
-  result = RunCmd(args)
-  if result is None: return None
-  return "No such file" not in result
-
-def main(argv):
-  if len(argv) == 1:
-    print ("usage: %s [adb flags] "
-           "[<hosted address[:password]>] "
-           "[<gmail address[:password]>]") % (argv[0],)
-    sys.exit(2)
-
-  argv = argv[1:]
-
-  gmail = None
-  hosted = None
-  while argv and "@" in argv[-1]:
-    addr = argv.pop()
-    if "@gmail.com" in addr or "@googlemail.com" in addr:
-      gmail = addr
-    else:
-      hosted = addr
-
-  adb_flags = tuple(argv)
-
-  while True:
-    db = DbExists(adb_flags)
-    if db is None:
-      print "failed to contact device; will retry in 3 seconds"
-      time.sleep(3)
-      continue
-
-    if db:
-      print
-      print "GoogleLoginService has already started on this device;"
-      print "it's too late to use this script to add accounts."
-      print
-      print "This script only works on a freshly-wiped device (or "
-      print "emulator) while booting for the first time."
-      print
-      break
-
-    hosted_account = GetProp(adb_flags, "ro.config.hosted_account").strip()
-    google_account = GetProp(adb_flags, "ro.config.google_account").strip()
-
-    if hosted and hosted_account:
-      print
-      print "A hosted account is already configured on this device;"
-      print "can't add", hosted_account
-      print
-      hosted = None
-
-    if gmail and google_account:
-      print
-      print "A google account is already configured on this device;"
-      print "can't add", google_account
-      print
-      gmail = None
-
-    if not gmail and not hosted: break
-
-    if hosted:
-      SetProp(adb_flags, "ro.config.hosted_account", hosted)
-      print "set hosted_account to", hosted
-    if gmail:
-      SetProp(adb_flags, "ro.config.google_account", gmail)
-      print "set google_account to", gmail
-
-    break
-
-
-
-
-
-
-if __name__ == "__main__":
-  main(sys.argv)
diff --git a/tools/scripts/alias.template b/tools/scripts/alias.template
deleted file mode 100644
index 8be355b..0000000
--- a/tools/scripts/alias.template
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<alias xmlns:android="http://schemas.android.com/apk/res/android">
-    <intent android:action="android.intent.action.VIEW"
-        android:data="ALIASDATA"/>
-</alias>
\ No newline at end of file
diff --git a/tools/scripts/alias_rules.xml b/tools/scripts/alias_rules.xml
deleted file mode 100644
index bc7de7c..0000000
--- a/tools/scripts/alias_rules.xml
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="alias_rules" default="package">
-
-    <!-- No user servicable parts below. -->
-
-    <!-- Input directories -->
-    <property name="resource-dir" value="res" />
-
-    <!-- The final package file to generate -->
-    <property name="out-package" value="${ant.project.name}.apk" />
-
-    <!-- Tools -->
-    <condition property="aapt" value="${android-tools}/aapt.exe" else="${android-tools}/aapt" >
-        <os family="windows"/>
-    </condition>
-    <condition property="adb" value="${android-tools}/adb.exe" else="${android-tools}/adb" >
-        <os family="windows"/>
-    </condition>
-    <property name="android-jar" value="${sdk-folder}/android.jar" />
-
-    <!-- Rules -->
-
-    <!-- Packages the manifest and the resource files -->
-    <target name="package-res">
-        <echo>Packaging resources...</echo>
-        <exec executable="${aapt}" failonerror="true">
-            <arg value="package" />
-            <arg value="-f" />
-            <arg value="-M" />
-            <arg value="AndroidManifest.xml" />
-            <arg value="-S" />
-            <arg value="${resource-dir}" />
-            <arg value="-I" />
-            <arg value="${android-jar}" />
-            <arg value="-F" />
-            <arg value="${out-package}" />
-        </exec>
-    </target>
-
-    <!-- Create the package file for this project from the sources. -->
-    <target name="package" depends="package-res" />
-
-    <!-- Create the package and install package on the default emulator -->
-    <target name="install" depends="package">
-        <echo>Sending package to default emulator...</echo>
-        <exec executable="${adb}" failonerror="true">
-            <arg value="install" />
-            <arg value="${out-package}" />
-        </exec>
-    </target>
-
-</project>
diff --git a/tools/scripts/android.el b/tools/scripts/android.el
deleted file mode 100644
index 49f2f1e..0000000
--- a/tools/scripts/android.el
+++ /dev/null
@@ -1,131 +0,0 @@
-;;;; Copyright 2007 The Android Open Source Project
-
-;;; Set up GUD+JDB to attach to a Java process running on the phone or
-;;; under the emulator.
-
-(defvar android-jdb-port-history '("8700")
- "history of ports supplied to `android-jdb'")
-
-(defvar android-jdb-project-root-history '()
- "history of project roots supplied to `android-jdb'")
-(defvar android-jdb-history nil
- "history of commands supplied to `android-jdb'")
-
-(defvar android-jdb-activity-class-history ()
- "history of activity classes supplied to `start-android-activity'")
-
-(defcustom  android-jdb-command-name "jdb"
-  "Name of Java debugger."
-  :type 'string
-  :group 'android)
-
-(defgroup android nil
-  "Android Applications."
-  :group 'applications)
-
-(defcustom android-project-root nil
- "This is where your Android project root is stored."
-  :type 'directory
- :group 'android )
-
-(defcustom android-apk nil
- "This is where your Android Application Package is stored."
- :type 'string
- :group 'android)
-
-(defcustom android-activity-class nil
- "This is where your Android Activity class is stored."
- :type 'string
- :group 'android)
-
-(defun android-read-project-root ()
- (if (or (string-match "XEmacs" emacs-version)
-         (>= emacs-major-version 22))
-     (read-file-name "Android project root: "
-                     android-project-root
-                     nil
-                     t
-                     nil
-                     'file-directory-p)
-   (labels ((read-directory ()
-                            (read-file-name "Android project root: "
-                                            android-project-root
-                                            nil
-                                            t
-                                            nil)))
-     (do ((entered-root (read-directory) (read-directory)))
-         ((and entered-root
-               (file-directory-p entered-root))
-          (expand-file-name entered-root))))))
-
-(defun android-jdb (port root)
- "Set GUD+JDB up to run against Android on PORT in directory ROOT."
- (interactive
-  (list
-   (read-from-minibuffer "Activity's JDWP DDMS port: "
-                     (car android-jdb-port-history)
-                     nil
-                     t
-                     'android-jdb-port-history)
-                    (android-read-project-root)))
- (setq android-project-root root)
- (let ((jdb-command
-        (format "%s -attach localhost:%s -sourcepath%s"
-                android-jdb-command-name
-                port
-                (format "%s/src" root))))
-   (if (not (string= jdb-command (car android-jdb-history)))
-       (push jdb-command android-jdb-history))
-   (jdb jdb-command)))
-
-(defun android-emulate ()
- "Run the Android emulator. This expects the SDK tools directory to be in the current path."
- (interactive)
- (compile "emulator"))
-
-(defun android-install-app (apk)
-  "Install an Android application package APK in the Android emulator. This expects the SDK tools directory to be in the current path."
-  (interactive (list (expand-file-name
-                      (read-file-name "Android Application Package (.apk): "
-                                      nil
-                                      android-apk
-                                      t
-                                      nil
-                                      nil))))
-  (setq android-apk apk)
-  (compile (format "adb install -r %s" apk)))
-
-(defun android-uninstall-app (package-name)
-  "Uninstall an Android application package APK in the Android emulator. This expects the SDK tools directory to be in the current path.
-Specify the package name --- and not the name of the application e.g., com.android.foo."
-  (interactive
-   (list
-    (read-from-minibuffer "Package: ")))
-  (compile (format "adb install -r %s" package)))
-
-(defun android-start-activity (package class)
- "Start the activity PACKAGE/CLASS in the Android emulator. This expects the SDK tools directory to be in the current path."
- (interactive
-  (list
-   (read-from-minibuffer "Package: ")
-   (read-from-minibuffer "Activity Java class: "
-         (car android-jdb-activity-class-history)
-         nil
-         t
-         'android-jdb-activity-class-history)))
- (compile (format "adb shell am start -n %s/%s" package class)))
-
-(defun android-debug-activity (package class)
- "Start the activity PACKAGE/CLASS within the debugger in the Android emulator. This expects the SDK tools directory to be in the current path."
- (interactive
-  (list
-   (read-from-minibuffer "Package: ")
-   (read-from-minibuffer "Activity Java class: "
-         (car android-jdb-activity-class-history)
-         nil
-         t
-         'android-jdb-activity-class-history)))
- (compile (format "adb shell am start -D -n %s/%s" package class)))
-
-(provide 'android)
-
diff --git a/tools/scripts/android_rules.xml b/tools/scripts/android_rules.xml
deleted file mode 100644
index 799aa0b..0000000
--- a/tools/scripts/android_rules.xml
+++ /dev/null
@@ -1,225 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="android_rules" default="debug">
-
-    <!--
-        This rules file is meant to be imported by the custom Ant task:
-            com.android.ant.AndroidInitTask
-
-        The following properties are put in place by the importing task:
-            android-jar, android-aidl, aapt, aidl, and dx
-
-        Additionnaly, the task sets up the following classpath reference:
-            android.target.classpath
-        This is used by the compiler task as the boot classpath.
-    -->
-
-    <!-- Custom tasks -->
-    <taskdef name="aaptexec"
-        classname="com.android.ant.AaptExecLoopTask"
-        classpathref="android.antlibs"/>
-
-    <taskdef name="apkbuilder"
-        classname="com.android.ant.ApkBuilderTask"
-        classpathref="android.antlibs"/>
-
-    <!-- Properties -->
-
-    <property name="android-tools" value="${sdk-location}/tools" />
-
-    <!-- Input directories -->
-    <property name="source-folder" value="src" />
-    <property name="resource-folder" value="res" />
-    <property name="asset-folder" value="assets" />
-    <property name="source-location" value="${basedir}/${source-folder}" />
-
-    <!-- folder for the 3rd party java libraries -->
-    <property name="external-libs-folder" value="libs" />
-
-    <!-- folder for the native libraries -->
-    <property name="native-libs-folder" value="libs" />
-
-    <!-- Output directories -->
-    <property name="out-folder" value="bin" />
-    <property name="out-classes" value="${out-folder}/classes" />
-    <property name="out-classes-location" value="${basedir}/${out-classes}"/>
-    <!-- out folders for a parent project if this project is an instrumentation project -->
-    <property name="main-out-folder" value="../${out-folder}" />
-    <property name="main-out-classes" value="${main-out-folder}/classes"/>
-
-    <!-- Create R.java in the source directory -->
-    <property name="r-folder" value="${source-folder}" />
-
-    <!-- Intermediate files -->
-    <property name="dex-file" value="classes.dex" />
-    <property name="intermediate-dex" value="${out-folder}/${dex-file}" />
-    <!-- dx does not properly support incorrect / or \ based on the platform
-         and Ant cannot convert them because the parameter is not a valid path.
-         Because of this we have to compute different paths depending on the platform. -->
-    <condition property="intermediate-dex-location"
-            value="${basedir}\${intermediate-dex}"
-            else="${basedir}/${intermediate-dex}" >
-        <os family="windows"/>
-    </condition>
-
-    <!-- The final package file to generate -->
-    <property name="out-debug-package" value="${out-folder}/${ant.project.name}-debug.apk"/>
-
-    <!-- Tools -->
-    <condition property="exe" value="exe" else=""><os family="windows"/></condition>
-    <property name="adb" value="${android-tools}/adb${exe}"/>
-
-    <!-- rules -->
-
-    <!-- Create the output directories if they don't exist yet. -->
-    <target name="dirs">
-        <echo>Creating output directories if needed...</echo>
-        <mkdir dir="${out-folder}" />
-        <mkdir dir="${out-classes}" />
-    </target>
-
-    <!-- Generate the R.java file for this project's resources. -->
-    <target name="resource-src" depends="dirs">
-        <echo>Generating R.java / Manifest.java from the resources...</echo>
-        <exec executable="${aapt}" failonerror="true">
-            <arg value="package" />
-            <arg value="-m" />
-            <arg value="-J" />
-            <arg path="${r-folder}" />
-            <arg value="-M" />
-            <arg path="AndroidManifest.xml" />
-            <arg value="-S" />
-            <arg path="${resource-folder}" />
-            <arg value="-I" />
-            <arg path="${android-jar}" />
-        </exec>
-    </target>
-
-    <!-- Generate java classes from .aidl files. -->
-    <target name="aidl" depends="dirs">
-        <echo>Compiling aidl files into Java classes...</echo>
-        <apply executable="${aidl}" failonerror="true">
-            <arg value="-p${android-aidl}" />
-            <arg value="-I${source-folder}" />
-            <fileset dir="${source-folder}">
-                <include name="**/*.aidl"/>
-            </fileset>
-        </apply>
-    </target>
-
-    <!-- Compile this project's .java files into .class files. -->
-    <target name="compile" depends="dirs, resource-src, aidl">
-        <javac encoding="ascii" target="1.5" debug="true" extdirs=""
-                srcdir="${source-folder}"
-                destdir="${out-classes}"
-                bootclasspathref="android.target.classpath">
-            <classpath>
-                <fileset dir="${external-libs-folder}" includes="*.jar"/>
-                <pathelement path="${main-out-classes}"/>
-            </classpath>
-         </javac>
-    </target>
-
-    <!-- Convert this project's .class files into .dex files. -->
-    <target name="dex" depends="compile">
-        <echo>Converting compiled files and external libraries into ${out-folder}/${dex-file}...</echo>
-        <apply executable="${dx}" failonerror="true" parallel="true">
-            <arg value="--dex" />
-            <arg value="--output=${intermediate-dex-location}" />
-            <arg path="${out-classes-location}" />
-            <fileset dir="${external-libs-folder}" includes="*.jar"/>
-        </apply>
-    </target>
-
-    <!-- Put the project's resources into the output package file
-         This actually can create multiple resource package in case
-         Some custom apk with specific configuration have been
-         declared in default.properties.
-         -->
-    <target name="package-resources">
-        <echo>Packaging resources</echo>
-        <aaptexec executable="${aapt}"
-                command="package"
-                manifest="AndroidManifest.xml"
-                resources="${resource-folder}"
-                assets="${asset-folder}"
-                androidjar="${android-jar}"
-                outfolder="${out-folder}"
-                basename="${ant.project.name}" />
-    </target>
-
-    <!-- Package the application and sign it with a debug key.
-         This is the default target when building. It is used for debug. -->
-    <target name="debug" depends="dex, package-resources">
-        <apkbuilder
-                outfolder="${out-folder}"
-                basename="${ant.project.name}"
-                signed="true"
-                verbose="false">
-            <file path="${intermediate-dex}" />
-            <sourcefolder path="${source-folder}" />
-            <jarfolder path="${external-libs-folder}" />
-            <nativefolder path="${native-libs-folder}" />
-        </apkbuilder>
-    </target>
-
-    <!-- Package the application without signing it.
-         This allows for the application to be signed later with an official publishing key. -->
-    <target name="release" depends="dex, package-resources">
-        <apkbuilder
-                outfolder="${out-folder}"
-                basename="${ant.project.name}"
-                signed="false"
-                verbose="false">
-            <file path="${intermediate-dex}" />
-            <sourcefolder path="${source-folder}" />
-            <jarfolder path="${external-libs-folder}" />
-            <nativefolder path="${native-libs-folder}" />
-        </apkbuilder>
-        <echo>All generated packages need to be signed with jarsigner before they are published.</echo>
-    </target>
-
-    <!-- Install the package on the default emulator -->
-    <target name="install" depends="debug">
-        <echo>Installing ${out-debug-package} onto default emulator...</echo>
-        <exec executable="${adb}" failonerror="true">
-            <arg value="install" />
-            <arg path="${out-debug-package}" />
-        </exec>
-    </target>
-
-    <target name="reinstall" depends="debug">
-        <echo>Installing ${out-debug-package} onto default emulator...</echo>
-        <exec executable="${adb}" failonerror="true">
-            <arg value="install" />
-            <arg value="-r" />
-            <arg path="${out-debug-package}" />
-        </exec>
-    </target>
-
-    <!-- Uinstall the package from the default emulator -->
-    <target name="uninstall">
-        <echo>Uninstalling ${application-package} from the default emulator...</echo>
-        <exec executable="${adb}" failonerror="true">
-            <arg value="uninstall" />
-            <arg path="${application-package}" />
-        </exec>
-    </target>
-    
-    <target name="help">
-        <!-- displays starts at col 13
-              |13                                                              80| -->
-        <echo>Android Ant Build. Available targets:</echo>
-        <echo>   help:      Displays this help.</echo>
-        <echo>   debug:     Builds the application and sign it with a debug key.</echo>
-        <echo>   release:   Builds the application. The generated apk file must be</echo>
-        <echo>              signed before it is published.</echo>
-        <echo>   install:   Installs the debug package onto a running emulator or</echo>
-        <echo>              device. This can only be used if the application has </echo>
-        <echo>              not yet been installed.</echo>
-        <echo>   reinstall: Installs the debug package on a running emulator or</echo>
-        <echo>              device that already has the application.</echo>
-        <echo>              The signatures must match.</echo>
-        <echo>   uninstall: uninstall the application from a running emulator or</echo>
-        <echo>              device.</echo>
-    </target>
-</project>
diff --git a/tools/scripts/app_engine_server/LICENSE b/tools/scripts/app_engine_server/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/tools/scripts/app_engine_server/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
-                                 Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets "[]"
-      replaced with your own identifying information. (Don't include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same "printed page" as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright [yyyy] [name of copyright owner]
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
diff --git a/tools/scripts/app_engine_server/app.yaml b/tools/scripts/app_engine_server/app.yaml
deleted file mode 100755
index 1fb50c7..0000000
--- a/tools/scripts/app_engine_server/app.yaml
+++ /dev/null
@@ -1,16 +0,0 @@
-application: androidappdocs-staging
-version: 1
-runtime: python
-api_version: 1
-
-handlers:
-- url: /gae_shell/static
-  static_dir: gae_shell/static
-  expiration: 1d
-
-- url: /gae_shell/.*
-  script: /gae_shell/shell.py
-  login: admin
-
-- url: .*
-  script: main.py
diff --git a/tools/scripts/app_engine_server/gae_shell/README b/tools/scripts/app_engine_server/gae_shell/README
deleted file mode 100644
index 5b0089f..0000000
--- a/tools/scripts/app_engine_server/gae_shell/README
+++ /dev/null
@@ -1,17 +0,0 @@
-An interactive, stateful AJAX shell that runs Python code on the server.
-
-Part of http://code.google.com/p/google-app-engine-samples/.
-
-May be run as a standalone app or in an existing app as an admin-only handler.
-Can be used for system administration tasks, as an interactive way to try out
-APIs, or as a debugging aid during development.
-
-The logging, os, sys, db, and users modules are imported automatically.
-
-Interpreter state is stored in the datastore so that variables, function
-definitions, and other values in the global and local namespaces can be used
-across commands.
-
-To use the shell in your app, copy shell.py, static/*, and templates/* into
-your app's source directory. Then, copy the URL handlers from app.yaml into
-your app.yaml.
diff --git a/tools/scripts/app_engine_server/gae_shell/__init__.py b/tools/scripts/app_engine_server/gae_shell/__init__.py
deleted file mode 100644
index e69de29..0000000
--- a/tools/scripts/app_engine_server/gae_shell/__init__.py
+++ /dev/null
diff --git a/tools/scripts/app_engine_server/gae_shell/__init__.pyc b/tools/scripts/app_engine_server/gae_shell/__init__.pyc
deleted file mode 100644
index 84951e9..0000000
--- a/tools/scripts/app_engine_server/gae_shell/__init__.pyc
+++ /dev/null
Binary files differ
diff --git a/tools/scripts/app_engine_server/gae_shell/shell.py b/tools/scripts/app_engine_server/gae_shell/shell.py
deleted file mode 100755
index df2fb17..0000000
--- a/tools/scripts/app_engine_server/gae_shell/shell.py
+++ /dev/null
@@ -1,308 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright 2007 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""
-An interactive, stateful AJAX shell that runs Python code on the server.
-
-Part of http://code.google.com/p/google-app-engine-samples/.
-
-May be run as a standalone app or in an existing app as an admin-only handler.
-Can be used for system administration tasks, as an interactive way to try out
-APIs, or as a debugging aid during development.
-
-The logging, os, sys, db, and users modules are imported automatically.
-
-Interpreter state is stored in the datastore so that variables, function
-definitions, and other values in the global and local namespaces can be used
-across commands.
-
-To use the shell in your app, copy shell.py, static/*, and templates/* into
-your app's source directory. Then, copy the URL handlers from app.yaml into
-your app.yaml.
-
-TODO: unit tests!
-"""
-
-import logging
-import new
-import os
-import pickle
-import sys
-import traceback
-import types
-import wsgiref.handlers
-
-from google.appengine.api import users
-from google.appengine.ext import db
-from google.appengine.ext import webapp
-from google.appengine.ext.webapp import template
-
-
-# Set to True if stack traces should be shown in the browser, etc.
-_DEBUG = True
-
-# The entity kind for shell sessions. Feel free to rename to suit your app.
-_SESSION_KIND = '_Shell_Session'
-
-# Types that can't be pickled.
-UNPICKLABLE_TYPES = (
-  types.ModuleType,
-  types.TypeType,
-  types.ClassType,
-  types.FunctionType,
-  )
-
-# Unpicklable statements to seed new sessions with.
-INITIAL_UNPICKLABLES = [
-  'import logging',
-  'import os',
-  'import sys',
-  'from google.appengine.ext import db',
-  'from google.appengine.api import users',
-  ]
-
-
-class Session(db.Model):
-  """A shell session. Stores the session's globals.
-
-  Each session globals is stored in one of two places:
-
-  If the global is picklable, it's stored in the parallel globals and
-  global_names list properties. (They're parallel lists to work around the
-  unfortunate fact that the datastore can't store dictionaries natively.)
-
-  If the global is not picklable (e.g. modules, classes, and functions), or if
-  it was created by the same statement that created an unpicklable global,
-  it's not stored directly. Instead, the statement is stored in the
-  unpicklables list property. On each request, before executing the current
-  statement, the unpicklable statements are evaluated to recreate the
-  unpicklable globals.
-
-  The unpicklable_names property stores all of the names of globals that were
-  added by unpicklable statements. When we pickle and store the globals after
-  executing a statement, we skip the ones in unpicklable_names.
-
-  Using Text instead of string is an optimization. We don't query on any of
-  these properties, so they don't need to be indexed.
-  """
-  global_names = db.ListProperty(db.Text)
-  globals = db.ListProperty(db.Blob)
-  unpicklable_names = db.ListProperty(db.Text)
-  unpicklables = db.ListProperty(db.Text)
-
-  def set_global(self, name, value):
-    """Adds a global, or updates it if it already exists.
-
-    Also removes the global from the list of unpicklable names.
-
-    Args:
-      name: the name of the global to remove
-      value: any picklable value
-    """
-    blob = db.Blob(pickle.dumps(value))
-
-    if name in self.global_names:
-      index = self.global_names.index(name)
-      self.globals[index] = blob
-    else:
-      self.global_names.append(db.Text(name))
-      self.globals.append(blob)
-
-    self.remove_unpicklable_name(name)
-
-  def remove_global(self, name):
-    """Removes a global, if it exists.
-
-    Args:
-      name: string, the name of the global to remove
-    """
-    if name in self.global_names:
-      index = self.global_names.index(name)
-      del self.global_names[index]
-      del self.globals[index]
-
-  def globals_dict(self):
-    """Returns a dictionary view of the globals.
-    """
-    return dict((name, pickle.loads(val))
-                for name, val in zip(self.global_names, self.globals))
-
-  def add_unpicklable(self, statement, names):
-    """Adds a statement and list of names to the unpicklables.
-
-    Also removes the names from the globals.
-
-    Args:
-      statement: string, the statement that created new unpicklable global(s).
-      names: list of strings; the names of the globals created by the statement.
-    """
-    self.unpicklables.append(db.Text(statement))
-
-    for name in names:
-      self.remove_global(name)
-      if name not in self.unpicklable_names:
-        self.unpicklable_names.append(db.Text(name))
-
-  def remove_unpicklable_name(self, name):
-    """Removes a name from the list of unpicklable names, if it exists.
-
-    Args:
-      name: string, the name of the unpicklable global to remove
-    """
-    if name in self.unpicklable_names:
-      self.unpicklable_names.remove(name)
-
-
-class FrontPageHandler(webapp.RequestHandler):
-  """Creates a new session and renders the shell.html template.
-  """
-
-  def get(self):
-    # set up the session. TODO: garbage collect old shell sessions
-    session_key = self.request.get('session')
-    if session_key:
-      session = Session.get(session_key)
-    else:
-      # create a new session
-      session = Session()
-      session.unpicklables = [db.Text(line) for line in INITIAL_UNPICKLABLES]
-      session_key = session.put()
-
-    template_file = os.path.join(os.path.dirname(__file__), 'templates',
-                                 'shell.html')
-    session_url = '/?session=%s' % session_key
-    vars = { 'server_software': os.environ['SERVER_SOFTWARE'],
-             'python_version': sys.version,
-             'session': str(session_key),
-             'user': users.get_current_user(),
-             'login_url': users.create_login_url(session_url),
-             'logout_url': users.create_logout_url(session_url),
-             }
-    rendered = webapp.template.render(template_file, vars, debug=_DEBUG)
-    self.response.out.write(rendered)
-
-
-class StatementHandler(webapp.RequestHandler):
-  """Evaluates a python statement in a given session and returns the result.
-  """
-
-  def get(self):
-    self.response.headers['Content-Type'] = 'text/plain'
-
-    # extract the statement to be run
-    statement = self.request.get('statement')
-    if not statement:
-      return
-
-    # the python compiler doesn't like network line endings
-    statement = statement.replace('\r\n', '\n')
-
-    # add a couple newlines at the end of the statement. this makes
-    # single-line expressions such as 'class Foo: pass' evaluate happily.
-    statement += '\n\n'
-
-    # log and compile the statement up front
-    try:
-      logging.info('Compiling and evaluating:\n%s' % statement)
-      compiled = compile(statement, '<string>', 'single')
-    except:
-      self.response.out.write(traceback.format_exc())
-      return
-
-    # create a dedicated module to be used as this statement's __main__
-    statement_module = new.module('__main__')
-
-    # use this request's __builtin__, since it changes on each request.
-    # this is needed for import statements, among other things.
-    import __builtin__
-    statement_module.__builtins__ = __builtin__
-
-    # load the session from the datastore
-    session = Session.get(self.request.get('session'))
-
-    # swap in our custom module for __main__. then unpickle the session
-    # globals, run the statement, and re-pickle the session globals, all
-    # inside it.
-    old_main = sys.modules.get('__main__')
-    try:
-      sys.modules['__main__'] = statement_module
-      statement_module.__name__ = '__main__'
-
-      # re-evaluate the unpicklables
-      for code in session.unpicklables:
-        exec code in statement_module.__dict__
-
-      # re-initialize the globals
-      for name, val in session.globals_dict().items():
-        try:
-          statement_module.__dict__[name] = val
-        except:
-          msg = 'Dropping %s since it could not be unpickled.\n' % name
-          self.response.out.write(msg)
-          logging.warning(msg + traceback.format_exc())
-          session.remove_global(name)
-
-      # run!
-      old_globals = dict(statement_module.__dict__)
-      try:
-        old_stdout = sys.stdout
-        old_stderr = sys.stderr
-        try:
-          sys.stdout = self.response.out
-          sys.stderr = self.response.out
-          exec compiled in statement_module.__dict__
-        finally:
-          sys.stdout = old_stdout
-          sys.stderr = old_stderr
-      except:
-        self.response.out.write(traceback.format_exc())
-        return
-
-      # extract the new globals that this statement added
-      new_globals = {}
-      for name, val in statement_module.__dict__.items():
-        if name not in old_globals or val != old_globals[name]:
-          new_globals[name] = val
-
-      if True in [isinstance(val, UNPICKLABLE_TYPES)
-                  for val in new_globals.values()]:
-        # this statement added an unpicklable global. store the statement and
-        # the names of all of the globals it added in the unpicklables.
-        session.add_unpicklable(statement, new_globals.keys())
-        logging.debug('Storing this statement as an unpicklable.')
-
-      else:
-        # this statement didn't add any unpicklables. pickle and store the
-        # new globals back into the datastore.
-        for name, val in new_globals.items():
-          if not name.startswith('__'):
-            session.set_global(name, val)
-
-    finally:
-      sys.modules['__main__'] = old_main
-
-    session.put()
-
-
-def main():
-  application = webapp.WSGIApplication(
-    [('/gae_shell/', FrontPageHandler),
-     ('/gae_shell/shell.do', StatementHandler)], debug=_DEBUG)
-  wsgiref.handlers.CGIHandler().run(application)
-
-
-if __name__ == '__main__':
-  main()
diff --git a/tools/scripts/app_engine_server/gae_shell/shell.py~ b/tools/scripts/app_engine_server/gae_shell/shell.py~
deleted file mode 100755
index dee9fdb..0000000
--- a/tools/scripts/app_engine_server/gae_shell/shell.py~
+++ /dev/null
@@ -1,308 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright 2007 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""
-An interactive, stateful AJAX shell that runs Python code on the server.
-
-Part of http://code.google.com/p/google-app-engine-samples/.
-
-May be run as a standalone app or in an existing app as an admin-only handler.
-Can be used for system administration tasks, as an interactive way to try out
-APIs, or as a debugging aid during development.
-
-The logging, os, sys, db, and users modules are imported automatically.
-
-Interpreter state is stored in the datastore so that variables, function
-definitions, and other values in the global and local namespaces can be used
-across commands.
-
-To use the shell in your app, copy shell.py, static/*, and templates/* into
-your app's source directory. Then, copy the URL handlers from app.yaml into
-your app.yaml.
-
-TODO: unit tests!
-"""
-
-import logging
-import new
-import os
-import pickle
-import sys
-import traceback
-import types
-import wsgiref.handlers
-
-from google.appengine.api import users
-from google.appengine.ext import db
-from google.appengine.ext import webapp
-from google.appengine.ext.webapp import template
-
-
-# Set to True if stack traces should be shown in the browser, etc.
-_DEBUG = True
-
-# The entity kind for shell sessions. Feel free to rename to suit your app.
-_SESSION_KIND = '_Shell_Session'
-
-# Types that can't be pickled.
-UNPICKLABLE_TYPES = (
-  types.ModuleType,
-  types.TypeType,
-  types.ClassType,
-  types.FunctionType,
-  )
-
-# Unpicklable statements to seed new sessions with.
-INITIAL_UNPICKLABLES = [
-  'import logging',
-  'import os',
-  'import sys',
-  'from google.appengine.ext import db',
-  'from google.appengine.api import users',
-  ]
-
-
-class Session(db.Model):
-  """A shell session. Stores the session's globals.
-
-  Each session globals is stored in one of two places:
-
-  If the global is picklable, it's stored in the parallel globals and
-  global_names list properties. (They're parallel lists to work around the
-  unfortunate fact that the datastore can't store dictionaries natively.)
-
-  If the global is not picklable (e.g. modules, classes, and functions), or if
-  it was created by the same statement that created an unpicklable global,
-  it's not stored directly. Instead, the statement is stored in the
-  unpicklables list property. On each request, before executing the current
-  statement, the unpicklable statements are evaluated to recreate the
-  unpicklable globals.
-
-  The unpicklable_names property stores all of the names of globals that were
-  added by unpicklable statements. When we pickle and store the globals after
-  executing a statement, we skip the ones in unpicklable_names.
-
-  Using Text instead of string is an optimization. We don't query on any of
-  these properties, so they don't need to be indexed.
-  """
-  global_names = db.ListProperty(db.Text)
-  globals = db.ListProperty(db.Blob)
-  unpicklable_names = db.ListProperty(db.Text)
-  unpicklables = db.ListProperty(db.Text)
-
-  def set_global(self, name, value):
-    """Adds a global, or updates it if it already exists.
-
-    Also removes the global from the list of unpicklable names.
-
-    Args:
-      name: the name of the global to remove
-      value: any picklable value
-    """
-    blob = db.Blob(pickle.dumps(value))
-
-    if name in self.global_names:
-      index = self.global_names.index(name)
-      self.globals[index] = blob
-    else:
-      self.global_names.append(db.Text(name))
-      self.globals.append(blob)
-
-    self.remove_unpicklable_name(name)
-
-  def remove_global(self, name):
-    """Removes a global, if it exists.
-
-    Args:
-      name: string, the name of the global to remove
-    """
-    if name in self.global_names:
-      index = self.global_names.index(name)
-      del self.global_names[index]
-      del self.globals[index]
-
-  def globals_dict(self):
-    """Returns a dictionary view of the globals.
-    """
-    return dict((name, pickle.loads(val))
-                for name, val in zip(self.global_names, self.globals))
-
-  def add_unpicklable(self, statement, names):
-    """Adds a statement and list of names to the unpicklables.
-
-    Also removes the names from the globals.
-
-    Args:
-      statement: string, the statement that created new unpicklable global(s).
-      names: list of strings; the names of the globals created by the statement.
-    """
-    self.unpicklables.append(db.Text(statement))
-
-    for name in names:
-      self.remove_global(name)
-      if name not in self.unpicklable_names:
-        self.unpicklable_names.append(db.Text(name))
-
-  def remove_unpicklable_name(self, name):
-    """Removes a name from the list of unpicklable names, if it exists.
-
-    Args:
-      name: string, the name of the unpicklable global to remove
-    """
-    if name in self.unpicklable_names:
-      self.unpicklable_names.remove(name)
-
-
-class FrontPageHandler(webapp.RequestHandler):
-  """Creates a new session and renders the shell.html template.
-  """
-
-  def get(self):
-    # set up the session. TODO: garbage collect old shell sessions
-    session_key = self.request.get('session')
-    if session_key:
-      session = Session.get(session_key)
-    else:
-      # create a new session
-      session = Session()
-      session.unpicklables = [db.Text(line) for line in INITIAL_UNPICKLABLES]
-      session_key = session.put()
-
-    template_file = os.path.join(os.path.dirname(__file__), 'templates',
-                                 'shell.html')
-    session_url = '/?session=%s' % session_key
-    vars = { 'server_software': os.environ['SERVER_SOFTWARE'],
-             'python_version': sys.version,
-             'session': str(session_key),
-             'user': users.get_current_user(),
-             'login_url': users.create_login_url(session_url),
-             'logout_url': users.create_logout_url(session_url),
-             }
-    rendered = webapp.template.render(template_file, vars, debug=_DEBUG)
-    self.response.out.write(rendered)
-
-
-class StatementHandler(webapp.RequestHandler):
-  """Evaluates a python statement in a given session and returns the result.
-  """
-
-  def get(self):
-    self.response.headers['Content-Type'] = 'text/plain'
-
-    # extract the statement to be run
-    statement = self.request.get('statement')
-    if not statement:
-      return
-
-    # the python compiler doesn't like network line endings
-    statement = statement.replace('\r\n', '\n')
-
-    # add a couple newlines at the end of the statement. this makes
-    # single-line expressions such as 'class Foo: pass' evaluate happily.
-    statement += '\n\n'
-
-    # log and compile the statement up front
-    try:
-      logging.info('Compiling and evaluating:\n%s' % statement)
-      compiled = compile(statement, '<string>', 'single')
-    except:
-      self.response.out.write(traceback.format_exc())
-      return
-
-    # create a dedicated module to be used as this statement's __main__
-    statement_module = new.module('__main__')
-
-    # use this request's __builtin__, since it changes on each request.
-    # this is needed for import statements, among other things.
-    import __builtin__
-    statement_module.__builtins__ = __builtin__
-
-    # load the session from the datastore
-    session = Session.get(self.request.get('session'))
-
-    # swap in our custom module for __main__. then unpickle the session
-    # globals, run the statement, and re-pickle the session globals, all
-    # inside it.
-    old_main = sys.modules.get('__main__')
-    try:
-      sys.modules['__main__'] = statement_module
-      statement_module.__name__ = '__main__'
-
-      # re-evaluate the unpicklables
-      for code in session.unpicklables:
-        exec code in statement_module.__dict__
-
-      # re-initialize the globals
-      for name, val in session.globals_dict().items():
-        try:
-          statement_module.__dict__[name] = val
-        except:
-          msg = 'Dropping %s since it could not be unpickled.\n' % name
-          self.response.out.write(msg)
-          logging.warning(msg + traceback.format_exc())
-          session.remove_global(name)
-
-      # run!
-      old_globals = dict(statement_module.__dict__)
-      try:
-        old_stdout = sys.stdout
-        old_stderr = sys.stderr
-        try:
-          sys.stdout = self.response.out
-          sys.stderr = self.response.out
-          exec compiled in statement_module.__dict__
-        finally:
-          sys.stdout = old_stdout
-          sys.stderr = old_stderr
-      except:
-        self.response.out.write(traceback.format_exc())
-        return
-
-      # extract the new globals that this statement added
-      new_globals = {}
-      for name, val in statement_module.__dict__.items():
-        if name not in old_globals or val != old_globals[name]:
-          new_globals[name] = val
-
-      if True in [isinstance(val, UNPICKLABLE_TYPES)
-                  for val in new_globals.values()]:
-        # this statement added an unpicklable global. store the statement and
-        # the names of all of the globals it added in the unpicklables.
-        session.add_unpicklable(statement, new_globals.keys())
-        logging.debug('Storing this statement as an unpicklable.')
-
-      else:
-        # this statement didn't add any unpicklables. pickle and store the
-        # new globals back into the datastore.
-        for name, val in new_globals.items():
-          if not name.startswith('__'):
-            session.set_global(name, val)
-
-    finally:
-      sys.modules['__main__'] = old_main
-
-    session.put()
-
-
-def main():
-  application = webapp.WSGIApplication(
-    [('/', FrontPageHandler),
-     ('/shell.do', StatementHandler)], debug=_DEBUG)
-  wsgiref.handlers.CGIHandler().run(application)
-
-
-if __name__ == '__main__':
-  main()
diff --git a/tools/scripts/app_engine_server/gae_shell/static/shell.js b/tools/scripts/app_engine_server/gae_shell/static/shell.js
deleted file mode 100644
index 4aa1583..0000000
--- a/tools/scripts/app_engine_server/gae_shell/static/shell.js
+++ /dev/null
@@ -1,195 +0,0 @@
-// Copyright 2007 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-/**
- * @fileoverview
- * Javascript code for the interactive AJAX shell.
- *
- * Part of http://code.google.com/p/google-app-engine-samples/.
- *
- * Includes a function (shell.runStatement) that sends the current python
- * statement in the shell prompt text box to the server, and a callback
- * (shell.done) that displays the results when the XmlHttpRequest returns.
- *
- * Also includes cross-browser code (shell.getXmlHttpRequest) to get an
- * XmlHttpRequest.
- */
-
-/**
- * Shell namespace.
- * @type {Object}
- */
-var shell = {}
-
-/**
- * The shell history. history is an array of strings, ordered oldest to
- * newest. historyCursor is the current history element that the user is on.
- *
- * The last history element is the statement that the user is currently
- * typing. When a statement is run, it's frozen in the history, a new history
- * element is added to the end of the array for the new statement, and
- * historyCursor is updated to point to the new element.
- *
- * @type {Array}
- */
-shell.history = [''];
-
-/**
- * See {shell.history}
- * @type {number}
- */
-shell.historyCursor = 0;
-
-/**
- * A constant for the XmlHttpRequest 'done' state.
- * @type Number
- */
-shell.DONE_STATE = 4;
-
-/**
- * A cross-browser function to get an XmlHttpRequest object.
- *
- * @return {XmlHttpRequest?} a new XmlHttpRequest
- */
-shell.getXmlHttpRequest = function() {
-  if (window.XMLHttpRequest) {
-    return new XMLHttpRequest();
-  } else if (window.ActiveXObject) {
-    try {
-      return new ActiveXObject('Msxml2.XMLHTTP');
-    } catch(e) {
-      return new ActiveXObject('Microsoft.XMLHTTP');
-    }
-  }
-
-  return null;
-};
-
-/**
- * This is the prompt textarea's onkeypress handler. Depending on the key that
- * was pressed, it will run the statement, navigate the history, or update the
- * current statement in the history.
- *
- * @param {Event} event the keypress event
- * @return {Boolean} false to tell the browser not to submit the form.
- */
-shell.onPromptKeyPress = function(event) {
-  var statement = document.getElementById('statement');
-
-  if (this.historyCursor == this.history.length - 1) {
-    // we're on the current statement. update it in the history before doing
-    // anything.
-    this.history[this.historyCursor] = statement.value;
-  }
-
-  // should we pull something from the history?
-  if (event.ctrlKey && event.keyCode == 38 /* up arrow */) {
-    if (this.historyCursor > 0) {
-      statement.value = this.history[--this.historyCursor];
-    }
-    return false;
-  } else if (event.ctrlKey && event.keyCode == 40 /* down arrow */) {
-    if (this.historyCursor < this.history.length - 1) {
-      statement.value = this.history[++this.historyCursor];
-    }
-    return false;
-  } else if (!event.altKey) {
-    // probably changing the statement. update it in the history.
-    this.historyCursor = this.history.length - 1;
-    this.history[this.historyCursor] = statement.value;
-  }
-
-  // should we submit?
-  var ctrlEnter = (document.getElementById('submit_key').value == 'ctrl-enter');
-  if (event.keyCode == 13 /* enter */ && !event.altKey && !event.shiftKey &&
-      event.ctrlKey == ctrlEnter) {
-    return this.runStatement();
-  }
-};
-
-/**
- * The XmlHttpRequest callback. If the request succeeds, it adds the command
- * and its resulting output to the shell history div.
- *
- * @param {XmlHttpRequest} req the XmlHttpRequest we used to send the current
- *     statement to the server
- */
-shell.done = function(req) {
-  if (req.readyState == this.DONE_STATE) {
-    var statement = document.getElementById('statement')
-    statement.className = 'prompt';
-
-    // add the command to the shell output
-    var output = document.getElementById('output');
-
-    output.value += '\n>>> ' + statement.value;
-    statement.value = '';
-
-    // add a new history element
-    this.history.push('');
-    this.historyCursor = this.history.length - 1;
-
-    // add the command's result
-    var result = req.responseText.replace(/^\s*|\s*$/g, '');  // trim whitespace
-    if (result != '')
-      output.value += '\n' + result;
-
-    // scroll to the bottom
-    output.scrollTop = output.scrollHeight;
-    if (output.createTextRange) {
-      var range = output.createTextRange();
-      range.collapse(false);
-      range.select();
-    }
-  }
-};
-
-/**
- * This is the form's onsubmit handler. It sends the python statement to the
- * server, and registers shell.done() as the callback to run when it returns.
- *
- * @return {Boolean} false to tell the browser not to submit the form.
- */
-shell.runStatement = function() {
-  var form = document.getElementById('form');
-
-  // build a XmlHttpRequest
-  var req = this.getXmlHttpRequest();
-  if (!req) {
-    document.getElementById('ajax-status').innerHTML =
-        "<span class='error'>Your browser doesn't support AJAX. :(</span>";
-    return false;
-  }
-
-  req.onreadystatechange = function() { shell.done(req); };
-
-  // build the query parameter string
-  var params = '';
-  for (i = 0; i < form.elements.length; i++) {
-    var elem = form.elements[i];
-    if (elem.type != 'submit' && elem.type != 'button' && elem.id != 'caret') {
-      var value = escape(elem.value).replace(/\+/g, '%2B'); // escape ignores +
-      params += '&' + elem.name + '=' + value;
-    }
-  }
-
-  // send the request and tell the user.
-  document.getElementById('statement').className = 'prompt processing';
-  req.open(form.method, form.action + '?' + params, true);
-  req.setRequestHeader('Content-type',
-                       'application/x-www-form-urlencoded;charset=UTF-8');
-  req.send(null);
-
-  return false;
-};
diff --git a/tools/scripts/app_engine_server/gae_shell/static/spinner.gif b/tools/scripts/app_engine_server/gae_shell/static/spinner.gif
deleted file mode 100644
index 3e58d6e..0000000
--- a/tools/scripts/app_engine_server/gae_shell/static/spinner.gif
+++ /dev/null
Binary files differ
diff --git a/tools/scripts/app_engine_server/gae_shell/templates/shell.html b/tools/scripts/app_engine_server/gae_shell/templates/shell.html
deleted file mode 100644
index 123b200..0000000
--- a/tools/scripts/app_engine_server/gae_shell/templates/shell.html
+++ /dev/null
@@ -1,122 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html>
-<head>
-<meta http-equiv="content-type" content="text/html; charset=utf-8" />
-<title> Interactive Shell </title>
-<script type="text/javascript" src="/gae_shell/static/shell.js"></script>
-<style type="text/css">
-body {
-  font-family: monospace;
-  font-size: 10pt;
-}
-
-p {
-  margin: 0.5em;
-}
-
-.prompt, #output {
-  width: 45em;
-  border: 1px solid silver;
-  background-color: #f5f5f5;
-  font-size: 10pt;
-  margin: 0.5em;
-  padding: 0.5em;
-  padding-right: 0em;
-  overflow-x: hidden;
-}
-
-#toolbar {
-  margin-left: 0.5em;
-  padding-left: 0.5em;
-}
-
-#caret {
-  width: 2.5em;
-  margin-right: 0px;
-  padding-right: 0px;
-  border-right: 0px;
-}
-
-#statement {
-  width: 43em;
-  margin-left: -1em;
-  padding-left: 0px;
-  border-left: 0px;
-  background-position: top right;
-  background-repeat: no-repeat;
-}
-
-.processing {
-  background-image: url("/gae_shell/static/spinner.gif");
-}
-
-#ajax-status {
-  font-weight: bold;
-}
-
-.message {
-  color: #8AD;
-  font-weight: bold;
-  font-style: italic;
-}
-
-.error {
-  color: #F44;
-}
-
-.username {
-  font-weight: bold;
-}
-
-</style>
-</head>
-
-<body>
-
-<p> Interactive server-side Python shell for
-<a href="http://code.google.com/appengine/">Google App Engine</a>.
-(<a href="http://code.google.com/p/google-app-engine-samples/">source</a>)
-</p>
-
-<textarea id="output" rows="22" readonly="readonly">
-{{ server_software }}
-Python {{ python_version }}
-</textarea>
-
-<form id="form" action="shell.do" method="get">
-  <nobr>
-  <textarea class="prompt" id="caret" readonly="readonly" rows="4"
-            onfocus="document.getElementById('statement').focus()"
-            >&gt;&gt;&gt;</textarea>
-  <textarea class="prompt" name="statement" id="statement" rows="4"
-            onkeypress="return shell.onPromptKeyPress(event);"></textarea>
-  </nobr>
-  <input type="hidden" name="session" value="{{ session }}" />
-  <input type="submit" style="display: none" />
-</form>
-
-<p id="ajax-status"></p>
-
-<p id="toolbar">
-{% if user %}
-  <span class="username">{{ user.nickname }}</span>
-  (<a href="{{ logout_url }}">log out</a>)
-{% else %}
-  <a href="{{ login_url }}">log in</a>
-{% endif %}
- | Ctrl-Up/Down for history |
-<select id="submit_key">
-  <option value="enter">Enter</option>
-  <option value="ctrl-enter" selected="selected">Ctrl-Enter</option>
-</select>
-<label for="submit_key">submits</label>
-</p>
-
-<script type="text/javascript">
-document.getElementById('statement').focus();
-</script>
-
-</body>
-</html>
-
diff --git a/tools/scripts/app_engine_server/index.yaml b/tools/scripts/app_engine_server/index.yaml
deleted file mode 100644
index 8e6046d..0000000
--- a/tools/scripts/app_engine_server/index.yaml
+++ /dev/null
@@ -1,12 +0,0 @@
-indexes:
-
-# AUTOGENERATED
-
-# This index.yaml is automatically updated whenever the dev_appserver
-# detects that a new type of query is run.  If you want to manage the
-# index.yaml file manually, remove the above marker line (the line
-# saying "# AUTOGENERATED").  If you want to manage some indexes
-# manually, move them above the marker line.  The index.yaml file is
-# automatically uploaded to the admin console when you next deploy
-# your application using appcfg.py.
-
diff --git a/tools/scripts/app_engine_server/memcache_zipserve.py b/tools/scripts/app_engine_server/memcache_zipserve.py
deleted file mode 100644
index e11cfc5..0000000
--- a/tools/scripts/app_engine_server/memcache_zipserve.py
+++ /dev/null
@@ -1,412 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright 2009 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#   http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""A class to serve pages from zip files and use memcache for performance.
-
-This contains a class and a function to create an anonymous instance of the
-class to serve HTTP GET requests. Memcache is used to increase response speed
-and lower processing cycles used in serving. Credit to Guido van Rossum and
-his implementation of zipserve which served as a reference as I wrote this.
-
-  MemcachedZipHandler: Class that serves request
-  create_handler: method to create instance of MemcachedZipHandler
-"""
-
-__author__ = 'jmatt@google.com (Justin Mattson)'
-
-import email.Utils
-import logging
-import mimetypes
-import time
-import zipfile
-
-from google.appengine.api import memcache
-from google.appengine.ext import webapp
-from google.appengine.ext.webapp import util
-
-
-def create_handler(zip_files, max_age=None, public=None):
-  """Factory method to create a MemcachedZipHandler instance.
-
-  Args:
-    zip_files: A list of file names, or a list of lists of file name, first
-        member of file mappings. See MemcachedZipHandler documentation for
-        more information about using the list of lists format
-    max_age: The maximum client-side cache lifetime
-    public: Whether this should be declared public in the client-side cache
-  Returns:
-    A MemcachedZipHandler wrapped in a pretty, anonymous bow for use with App
-    Engine
-
-  Raises:
-    ValueError: if the zip_files argument is not a list
-  """
-  # verify argument integrity. If the argument is passed in list format,
-  # convert it to list of lists format
-  
-  if zip_files and type(zip_files).__name__ == 'list':
-    num_items = len(zip_files)
-    while num_items > 0:
-      if type(zip_files[num_items - 1]).__name__ != 'list':
-        zip_files[num_items - 1] = [zip_files[num_items-1]]
-      num_items -= 1
-  else:
-    raise ValueError('File name arguments must be a list')
-
-  class HandlerWrapper(MemcachedZipHandler):
-    """Simple wrapper for an instance of MemcachedZipHandler.
-
-    I'm still not sure why this is needed
-    """
-    
-    def get(self, name):
-      self.zipfilenames = zip_files
-      self.TrueGet(name)
-      if max_age is not None:
-        MAX_AGE = max_age
-      if public is not None:
-        PUBLIC = public
-
-  return HandlerWrapper
-
-
-class MemcachedZipHandler(webapp.RequestHandler):
-  """Handles get requests for a given URL.
-
-  Serves a GET request from a series of zip files. As files are served they are
-  put into memcache, which is much faster than retreiving them from the zip
-  source file again. It also uses considerably fewer CPU cycles.
-  """
-  zipfile_cache = {}                # class cache of source zip files
-  MAX_AGE = 600                     # max client-side cache lifetime
-  PUBLIC = True                     # public cache setting
-  CACHE_PREFIX = 'cache://'         # memcache key prefix for actual URLs
-  NEG_CACHE_PREFIX = 'noncache://'  # memcache key prefix for non-existant URL
-
-  def TrueGet(self, name):
-    """The top-level entry point to serving requests.
-
-    Called 'True' get because it does the work when called from the wrapper
-    class' get method
-
-    Args:
-      name: URL requested
-
-    Returns:
-      None
-    """
-    name = self.PreprocessUrl(name)
-
-    # see if we have the page in the memcache
-    resp_data = self.GetFromCache(name)
-    if resp_data is None:
-      logging.info('Cache miss for %s', name)
-      resp_data = self.GetFromNegativeCache(name)
-      if resp_data is None:
-        resp_data = self.GetFromStore(name)
-
-        # IF we have the file, put it in the memcache
-        # ELSE put it in the negative cache
-        if resp_data is not None:
-          self.StoreOrUpdateInCache(name, resp_data)
-        else:
-          logging.info('Adding %s to negative cache, serving 404', name)
-          self.StoreInNegativeCache(name)
-          self.Write404Error()
-          return
-      else:
-        self.Write404Error()
-        return
-
-    content_type, encoding = mimetypes.guess_type(name)
-    if content_type:
-      self.response.headers['Content-Type'] = content_type
-    self.SetCachingHeaders()
-    self.response.out.write(resp_data)
-
-  def PreprocessUrl(self, name):
-    """Any preprocessing work on the URL when it comes it.
-
-    Put any work related to interpretting the incoming URL here. For example,
-    this is used to redirect requests for a directory to the index.html file
-    in that directory. Subclasses should override this method to do different
-    preprocessing.
-
-    Args:
-      name: The incoming URL
-
-    Returns:
-      The processed URL
-    """
-    # handle special case of requesting the domain itself
-    if not name:
-      name = 'index.html'
-
-    # determine if this is a request for a directory
-    final_path_segment = name
-    final_slash_offset = name.rfind('/')
-    if final_slash_offset != len(name) - 1:
-      final_path_segment = name[final_slash_offset + 1:]
-      if final_path_segment.find('.') == -1:
-        name = ''.join([name, '/'])
-
-    # if this is a directory, redirect to index.html
-    if name[len(name) - 1:] == '/':
-      return '%s%s' % (name, 'index.html')
-    else:
-      return name
-
-  def GetFromStore(self, file_path):
-    """Retrieve file from zip files.
-
-    Get the file from the source, it must not have been in the memcache. If
-    possible, we'll use the zip file index to quickly locate where the file
-    should be found. (See MapToFileArchive documentation for assumptions about
-    file ordering.) If we don't have an index or don't find the file where the
-    index says we should, look through all the zip files to find it.
-
-    Args:
-      file_path: the file that we're looking for
-
-    Returns:
-      The contents of the requested file
-    """
-    resp_data = None
-    file_itr = iter(self.zipfilenames)
-
-    # check the index, if we have one, to see what archive the file is in
-    archive_name = self.MapFileToArchive(file_path)
-    if not archive_name:
-      archive_name = file_itr.next()[0]
-    
-    while resp_data is None and archive_name:
-      zip_archive = self.LoadZipFile(archive_name)
-      if zip_archive:
-
-        # we expect some lookups will fail, and that's okay, 404s will deal
-        # with that
-        try:
-          resp_data = zip_archive.read(file_path)
-        except (KeyError, RuntimeError), err:
-          # no op
-          x = False
-        if resp_data is not None:
-          logging.info('%s read from %s', file_path, archive_name)
-          
-      try:
-        archive_name = file_itr.next()[0]
-      except (StopIteration), err:
-        archive_name = False
-
-    return resp_data
-
-  def LoadZipFile(self, zipfilename):
-    """Convenience method to load zip file.
-
-    Just a convenience method to load the zip file from the data store. This is
-    useful if we ever want to change data stores and also as a means of
-    dependency injection for testing. This method will look at our file cache
-    first, and then load and cache the file if there's a cache miss
-
-    Args:
-      zipfilename: the name of the zip file to load
-
-    Returns:
-      The zip file requested, or None if there is an I/O error
-    """
-    zip_archive = None
-    zip_archive = self.zipfile_cache.get(zipfilename)
-    if zip_archive is None:
-      try:
-        zip_archive = zipfile.ZipFile(zipfilename)
-        self.zipfile_cache[zipfilename] = zip_archive
-      except (IOError, RuntimeError), err:
-        logging.error('Can\'t open zipfile %s, cause: %s' % (zipfilename,
-                                                             err))
-    return zip_archive
-
-  def MapFileToArchive(self, file_path):
-    """Given a file name, determine what archive it should be in.
-
-    This method makes two critical assumptions.
-    (1) The zip files passed as an argument to the handler, if concatenated
-        in that same order, would result in a total ordering
-        of all the files. See (2) for ordering type.
-    (2) Upper case letters before lower case letters. The traversal of a
-        directory tree is depth first. A parent directory's files are added
-        before the files of any child directories
-
-    Args:
-      file_path: the file to be mapped to an archive
-
-    Returns:
-      The name of the archive where we expect the file to be
-    """
-    num_archives = len(self.zipfilenames)
-    while num_archives > 0:
-      target = self.zipfilenames[num_archives - 1]
-      if len(target) > 1:
-        if self.CompareFilenames(target[1], file_path) >= 0:
-          return target[0]
-      num_archives -= 1
-
-    return None
-
-  def CompareFilenames(self, file1, file2):
-    """Determines whether file1 is lexigraphically 'before' file2.
-
-    WARNING: This method assumes that paths are output in a depth-first,
-    with parent directories' files stored before childs'
-
-    We say that file1 is lexigraphically before file2 if the last non-matching
-    path segment of file1 is alphabetically before file2.
-    
-    Args:
-      file1: the first file path
-      file2: the second file path
-
-    Returns:
-      A positive number if file1 is before file2
-      A negative number if file2 is before file1
-      0 if filenames are the same
-    """
-    f1_segments = file1.split('/')
-    f2_segments = file2.split('/')
-
-    segment_ptr = 0
-    while (segment_ptr < len(f1_segments) and
-           segment_ptr < len(f2_segments) and
-           f1_segments[segment_ptr] == f2_segments[segment_ptr]):
-      segment_ptr += 1
-
-    if len(f1_segments) == len(f2_segments):
-
-      # we fell off the end, the paths much be the same
-      if segment_ptr == len(f1_segments):
-        return 0
-
-      # we didn't fall of the end, compare the segments where they differ
-      if f1_segments[segment_ptr] < f2_segments[segment_ptr]:
-        return 1
-      elif f1_segments[segment_ptr] > f2_segments[segment_ptr]:
-        return -1
-      else:
-        return 0
-
-      # the number of segments differs, we either mismatched comparing
-      # directories, or comparing a file to a directory
-    else:
-
-      # IF we were looking at the last segment of one of the paths,
-      # the one with fewer segments is first because files come before
-      # directories
-      # ELSE we just need to compare directory names
-      if (segment_ptr + 1 == len(f1_segments) or
-          segment_ptr + 1 == len(f2_segments)):
-        return len(f2_segments) - len(f1_segments)
-      else:
-        if f1_segments[segment_ptr] < f2_segments[segment_ptr]:
-          return 1
-        elif f1_segments[segment_ptr] > f2_segments[segment_ptr]:
-          return -1
-        else:
-          return 0
-
-  def SetCachingHeaders(self):
-    """Set caching headers for the request."""
-    max_age = self.MAX_AGE
-    self.response.headers['Expires'] = email.Utils.formatdate(
-        time.time() + max_age, usegmt=True)
-    cache_control = []
-    if self.PUBLIC:
-      cache_control.append('public')
-    cache_control.append('max-age=%d' % max_age)
-    self.response.headers['Cache-Control'] = ', '.join(cache_control)
-
-  def GetFromCache(self, filename):
-    """Get file from memcache, if available.
-
-    Args:
-      filename: The URL of the file to return
-
-    Returns:
-      The content of the file
-    """
-    return memcache.get('%s%s' % (self.CACHE_PREFIX, filename))
-
-  def StoreOrUpdateInCache(self, filename, data):
-    """Store data in the cache.
-
-    Store a piece of data in the memcache. Memcache has a maximum item size of
-    1*10^6 bytes. If the data is too large, fail, but log the failure. Future
-    work will consider compressing the data before storing or chunking it
-
-    Args:
-      filename: the name of the file to store
-      data: the data of the file
-
-    Returns:
-      None
-    """
-    try:
-      if not memcache.add('%s%s' % (self.CACHE_PREFIX, filename), data):
-        memcache.replace('%s%s' % (self.CACHE_PREFIX, filename), data)
-    except (ValueError), err:
-      logging.warning('Data size too large to cache\n%s' % err)
-
-  def Write404Error(self):
-    """Ouptut a simple 404 response."""
-    self.error(404)
-    self.response.out.write(
-        ''.join(['<html><head><title>404: Not Found</title></head>',
-                 '<body><b><h2>Error 404</h2><br/>',
-                 'File not found</b></body></html>']))
-
-  def StoreInNegativeCache(self, filename):
-    """If a non-existant URL is accessed, cache this result as well.
-
-    Future work should consider setting a maximum negative cache size to
-    prevent it from from negatively impacting the real cache.
-
-    Args:
-      filename: URL to add ot negative cache
-
-    Returns:
-      None
-    """
-    memcache.add('%s%s' % (self.NEG_CACHE_PREFIX, filename), -1)
-
-  def GetFromNegativeCache(self, filename):
-    """Retrieve from negative cache.
-
-    Args:
-      filename: URL to retreive
-
-    Returns:
-      The file contents if present in the negative cache.
-    """
-    return memcache.get('%s%s' % (self.NEG_CACHE_PREFIX, filename))
-
-
-def main():
-  application = webapp.WSGIApplication([('/([^/]+)/(.*)',
-                                         MemcachedZipHandler)])
-  util.run_wsgi_app(application)
-
-
-if __name__ == '__main__':
-  main()
diff --git a/tools/scripts/build.alias.template b/tools/scripts/build.alias.template
deleted file mode 100644
index b605295..0000000
--- a/tools/scripts/build.alias.template
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="PROJECT_NAME" default="package">
-
-    <!-- The build.properties file can be created by you and is never touched
-         by activitycreator. If you want to manually set properties, this is
-         the best place to set them. -->
-    <property file="build.properties"/>
-
-    <!-- The default.properties file is created and updated by activitycreator.
-         It will set any properties not already defined by build.properties. -->
-    <property file="default.properties"/>
-
-    <!-- ************************************************************************************* -->
-    <!-- Import the default Android build rules. 
-         This requires ant 1.6.0 or above. -->
-
-    <import file="${sdk-folder}/tools/lib/alias_rules.xml" />
-
-</project>
diff --git a/tools/scripts/build.template b/tools/scripts/build.template
deleted file mode 100644
index 7939e6c..0000000
--- a/tools/scripts/build.template
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project name="PROJECT_NAME" default="help">
-
-    <!-- The local.properties file is created and updated by the 'android' tool.
-         It contain the path to the SDK. It should *NOT* be checked in in Version
-         Control Systems. -->
-    <property file="local.properties"/>
-
-    <!-- The build.properties file can be created by you and is never touched
-         by the 'android' tool. This is the place to change some of the default property values
-         used by the Ant rules.
-         Here are some properties you may want to change/update:
-
-         application-package
-             the name of your application package as defined in the manifest. Used by the
-             'uninstall' rule.
-         source-folder
-             the name of the source folder. Default is 'src'.
-         out-folder
-             the name of the output folder. Default is 'bin'.
-
-         Properties related to the SDK location or the project target should be updated
-          using the 'android' tool with the 'update' action.
-
-         This file is an integral part of the build system for your application and
-         should be checked in in Version Control Systems.
-
-         -->
-    <property file="build.properties"/>
-
-    <!-- The default.properties file is created and updated by the 'android' tool, as well
-         as ADT. 
-         This file is an integral part of the build system for your application and
-         should be checked in in Version Control Systems. -->
-    <property file="default.properties"/>
-
-    <!-- Custom Android task to deal with the project target, and import the proper rules.
-         This requires ant 1.6.0 or above. -->
-    <path id="android.antlibs">
-        <pathelement path="${sdk-location}/tools/lib/anttasks.jar" />
-        <pathelement path="${sdk-location}/tools/lib/sdklib.jar" />
-        <pathelement path="${sdk-location}/tools/lib/androidprefs.jar" />
-        <pathelement path="${sdk-location}/tools/lib/apkbuilder.jar" />
-        <pathelement path="${sdk-location}/tools/lib/jarutils.jar" />
-    </path>
-
-    <taskdef name="setup"
-        classname="com.android.ant.SetupTask"
-        classpathref="android.antlibs"/>
-
-    <!-- Execute the Android Setup task that will setup some properties specific to the target,
-         and import the rules files.
-         To customize the rules, copy/paste them below the task, and disable import by setting
-         the import attribute to false:
-            <setup import="false" />
-         
-         This will ensure that the properties are setup correctly but that your customized
-         targets are used.
-    -->
-    <setup />
-</project>
diff --git a/tools/scripts/combine_sdks.sh b/tools/scripts/combine_sdks.sh
deleted file mode 100755
index ebaa1c6..0000000
--- a/tools/scripts/combine_sdks.sh
+++ /dev/null
@@ -1,105 +0,0 @@
-#!/bin/bash
-
-function replace()
-{
-        echo replacing $1
-        rm $V -rf "$UNZIPPED_BASE_DIR"/$1
-        cp $V -rf "$UNZIPPED_IMAGE_DIR"/$1 "$UNZIPPED_BASE_DIR"/$1
-}
-
-V=""
-Q="-q"
-if [ "$1" == "-v" ]; then
-    V="-v"
-    Q=""
-    shift
-fi
-
-NOZIP=""
-if [ "$1" == "-nozip" ]; then
-    NOZIP="1"
-    shift
-fi
-
-BASE="$1"
-IMAGES="$2"
-OUTPUT="$3"
-
-if [[ -z "$BASE" || -z "$IMAGES" || -z "$OUTPUT" ]] ; then
-    echo "usage: combine_sdks.sh [-v] [-nozip] BASE IMAGES OUTPUT"
-    echo
-    echo "  BASE and IMAGES should be sdk zip files.  The system image files,"
-    echo "  emulator and other runtime files will be copied from IMAGES and"
-    echo "  everything else will be copied from BASE.  All of this will be"
-    echo "  bundled into OUTPUT and zipped up again (unless -nozip is specified)."
-    echo
-    exit 1
-fi
-
-TMP=$(mktemp -d)
-
-TMP_ZIP=tmp.zip
-
-# determine executable extension
-case `uname -s` in
-    *_NT-*)  # for Windows
-        EXE=.exe
-        ;;
-    *)
-        EXE=
-        ;;
-esac
-
-BASE_DIR="$TMP"/base
-IMAGES_DIR="$TMP"/images
-OUTPUT_TMP_ZIP="$BASE_DIR/$TMP_ZIP"
-
-unzip $Q "$BASE"   -d "$BASE_DIR"
-unzip $Q "$IMAGES" -d "$IMAGES_DIR"
-
-UNZIPPED_BASE_DIR=$(echo "$BASE_DIR"/*)
-UNZIPPED_IMAGE_DIR=$(echo "$IMAGES_DIR"/*)
-
-#
-# The commands to copy over the files that we want
-#
-
-# replace tools/emulator # at this time we do not want the exe from SDK1.x
-replace tools/lib/images
-replace tools/lib/res
-replace tools/lib/fonts
-replace tools/lib/layoutlib.jar
-replace docs
-replace android.jar
-
-for i in widgets categories broadcast_actions service_actions; do
-    replace tools/lib/$i.txt
-done
-
-if [ -d "$UNZIPPED_BASE_DIR"/usb_driver ]; then
-    replace usb_driver
-fi
-
-#
-# end
-#
-
-if [ -z "$NOZIP" ]; then
-    pushd "$BASE_DIR" &> /dev/null
-        # rename the directory to the leaf minus the .zip of OUTPUT
-        LEAF=$(echo "$OUTPUT" | sed -e "s:.*\.zip/::" | sed -e "s:.zip$::")
-        mv * "$LEAF"
-        # zip it
-        zip $V -qr "$TMP_ZIP" "$LEAF"
-    popd &> /dev/null
-
-    cp $V "$OUTPUT_TMP_ZIP" "$OUTPUT"
-    echo "Combined SDK available at $OUTPUT"
-else
-    OUT_DIR="${OUTPUT//.zip/}"
-    mv $V "$BASE_DIR"/* "$OUT_DIR"
-    echo "Unzipped combined SDK available at $OUT_DIR"
-fi
-
-rm $V -rf "$TMP"
-
diff --git a/tools/scripts/divide_and_compress.py b/tools/scripts/divide_and_compress.py
deleted file mode 100755
index d369be4..0000000
--- a/tools/scripts/divide_and_compress.py
+++ /dev/null
@@ -1,352 +0,0 @@
-#!/usr/bin/python2.4
-#
-# Copyright (C) 2008 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""Module to compress directories in to series of zip files.
-
-This module will take a directory and compress all its contents, including
-child directories into a series of zip files named N.zip where 'N' ranges from
-0 to infinity. The zip files will all be below a certain specified maximum
-threshold.
-
-The directory is compressed with a depth first traversal, each directory's
-file contents being compressed as it is visisted, before the compression of any
-child directory's contents. In this way the files within an archive are ordered
-and the archives themselves are ordered.
-
-The class also constructs a 'main.py' file intended for use with Google App
-Engine with a custom App Engine program not currently distributed with this
-code base. The custom App Engine runtime can leverage the index files written
-out by this class to more quickly locate which zip file to serve a given URL
-from.
-"""
-
-__author__ = 'jmatt@google.com (Justin Mattson)'
-
-from optparse import OptionParser
-import os
-import stat
-import sys
-import zipfile
-from zipfile import ZipFile
-import divide_and_compress_constants
-
-
-def Main(argv):
-  parser = CreateOptionsParser()
-  (options, args) = parser.parse_args()
-  VerifyArguments(options, parser)
-  zipper = DirectoryZipper(options.destination, 
-                           options.sourcefiles, 
-                           ParseSize(options.filesize),
-                           options.compress)
-  zipper.StartCompress()
-  
-
-def CreateOptionsParser():
-  rtn = OptionParser()
-  rtn.add_option('-s', '--sourcefiles', dest='sourcefiles', default=None,
-                 help='The directory containing the files to compress')
-  rtn.add_option('-d', '--destination', dest='destination', default=None,
-                 help=('Where to put the archive files, this should not be'
-                       ' a child of where the source files exist.'))
-  rtn.add_option('-f', '--filesize', dest='filesize', default='1M',
-                 help=('Maximum size of archive files. A number followed by' 
-                       'a magnitude indicator, eg. 1000000B == one million '
-                       'BYTES, 500K == five hundred KILOBYTES, 1.2M == one '
-                       'point two MEGABYTES. 1M == 1048576 BYTES'))
-  rtn.add_option('-n', '--nocompress', action='store_false', dest='compress',
-                 default=True, 
-                 help=('Whether the archive files should be compressed, or '
-                       'just a concatenation of the source files'))
-  return rtn
-
-
-def VerifyArguments(options, parser):
-  try:
-    if options.sourcefiles is None or options.destination is None:
-      parser.print_help()
-      sys.exit(-1)
-  except (AttributeError), err:
-    parser.print_help()
-    sys.exit(-1)
-
-
-def ParseSize(size_str):
-  if len(size_str) < 2:
-    raise ValueError(('filesize argument not understood, please include'
-                      ' a numeric value and magnitude indicator'))
-  magnitude = size_str[len(size_str)-1:]
-  if not magnitude in ('K', 'B', 'M'):
-    raise ValueError(('filesize magnitude indicator not valid, must be \'K\','
-                      '\'B\', or \'M\''))
-  numeral = float(size_str[0:len(size_str)-1])
-  if magnitude == 'K':
-    numeral *= 1024
-  elif magnitude == 'M':
-    numeral *= 1048576
-  return int(numeral)
-
-
-class DirectoryZipper(object):
-  """Class to compress a directory and all its sub-directories."""  
-  current_archive = None
-  output_dir = None
-  base_path = None
-  max_size = None
-  compress = None
-  index_fp = None
-
-  def __init__(self, output_path, base_dir, archive_size, enable_compression):
-    """DirectoryZipper constructor.
-
-    Args:
-      output_path: the path to write the archives and index file to
-      base_dir: the directory to compress
-      archive_size: the maximum size, in bytes, of a single archive file
-      enable_compression: whether or not compression should be enabled, if
-        disabled, the files will be written into an uncompresed zip
-    """
-    self.output_dir = output_path
-    self.current_archive = '0.zip'
-    self.base_path = base_dir
-    self.max_size = archive_size
-    self.compress = enable_compression
-
-  def StartCompress(self):
-    """Start compress of the directory.
-
-    This will start the compression process and write the archives to the
-    specified output directory. It will also produce an 'index.txt' file in the
-    output directory that maps from file to archive.
-    """
-    self.index_fp = open(''.join([self.output_dir, 'main.py']), 'w')
-    self.index_fp.write(divide_and_compress_constants.file_preamble)
-    os.path.walk(self.base_path, self.CompressDirectory, 1)
-    self.index_fp.write(divide_and_compress_constants.file_endpiece)
-    self.index_fp.close()
-
-  def RemoveLastFile(self, archive_path=None):
-    """Removes the last item in the archive.
-
-    This removes the last item in the archive by reading the items out of the
-    archive, adding them to a new archive, deleting the old archive, and
-    moving the new archive to the location of the old archive.
-
-    Args:
-      archive_path: Path to the archive to modify. This archive should not be
-        open elsewhere, since it will need to be deleted.
-    Return:
-      A new ZipFile object that points to the modified archive file
-    """
-    if archive_path is None:
-      archive_path = ''.join([self.output_dir, self.current_archive])
-
-    # Move the old file and create a new one at its old location
-    ext_offset = archive_path.rfind('.')
-    old_archive = ''.join([archive_path[0:ext_offset], '-old',
-                           archive_path[ext_offset:]])
-    os.rename(archive_path, old_archive)
-    old_fp = self.OpenZipFileAtPath(old_archive, mode='r')
-
-    if self.compress:
-      new_fp = self.OpenZipFileAtPath(archive_path,
-                                      mode='w',
-                                      compress=zipfile.ZIP_DEFLATED)
-    else:
-      new_fp = self.OpenZipFileAtPath(archive_path,
-                                      mode='w',
-                                      compress=zipfile.ZIP_STORED)
-    
-    # Read the old archive in a new archive, except the last one
-    zip_members = enumerate(old_fp.infolist())
-    num_members = len(old_fp.infolist())
-    while num_members > 1:
-      this_member = zip_members.next()[1]
-      new_fp.writestr(this_member.filename, old_fp.read(this_member.filename))
-      num_members -= 1
-
-    # Close files and delete the old one
-    old_fp.close()
-    new_fp.close()
-    os.unlink(old_archive)
-
-  def OpenZipFileAtPath(self, path, mode=None, compress=zipfile.ZIP_DEFLATED):
-    """This method is mainly for testing purposes, eg dependency injection."""
-    if mode is None:
-      if os.path.exists(path):
-        mode = 'a'
-      else:
-        mode = 'w'
-
-    if mode == 'r':
-      return ZipFile(path, mode)
-    else:
-      return ZipFile(path, mode, compress)
-
-  def CompressDirectory(self, irrelevant, dir_path, dir_contents):
-    """Method to compress the given directory.
-
-    This method compresses the directory 'dir_path'. It will add to an existing
-    zip file that still has space and create new ones as necessary to keep zip
-    file sizes under the maximum specified size. This also writes out the
-    mapping of files to archives to the self.index_fp file descriptor
-
-    Args:
-      irrelevant: a numeric identifier passed by the os.path.walk method, this
-        is not used by this method
-      dir_path: the path to the directory to compress
-      dir_contents: a list of directory contents to be compressed
-    """
-    
-    # construct the queue of files to be added that this method will use
-    # it seems that dir_contents is given in reverse alphabetical order,
-    # so put them in alphabetical order by inserting to front of the list
-    dir_contents.sort()
-    zip_queue = []
-    if dir_path[len(dir_path) - 1:] == os.sep:
-      for filename in dir_contents:
-        zip_queue.append(''.join([dir_path, filename]))
-    else:
-      for filename in dir_contents:
-        zip_queue.append(''.join([dir_path, os.sep, filename]))
-    compress_bit = zipfile.ZIP_DEFLATED
-    if not self.compress:
-      compress_bit = zipfile.ZIP_STORED
-
-    # zip all files in this directory, adding to existing archives and creating
-    # as necessary
-    while len(zip_queue) > 0:
-      target_file = zip_queue[0]
-      if os.path.isfile(target_file):
-        self.AddFileToArchive(target_file, compress_bit)
-        
-        # see if adding the new file made our archive too large
-        if not self.ArchiveIsValid():
-          
-          # IF fixing fails, the last added file was to large, skip it
-          # ELSE the current archive filled normally, make a new one and try
-          #  adding the file again
-          if not self.FixArchive('SIZE'):
-            zip_queue.pop(0)
-          else:
-            self.current_archive = '%i.zip' % (
-                int(self.current_archive[
-                    0:self.current_archive.rfind('.zip')]) + 1)
-        else:
-
-          # if this the first file in the archive, write an index record
-          self.WriteIndexRecord()
-          zip_queue.pop(0)
-      else:
-        zip_queue.pop(0)
-
-  def WriteIndexRecord(self):
-    """Write an index record to the index file.
-
-    Only write an index record if this is the first file to go into archive
-
-    Returns:
-      True if an archive record is written, False if it isn't
-    """
-    archive = self.OpenZipFileAtPath(
-        ''.join([self.output_dir, self.current_archive]), 'r')
-    archive_index = archive.infolist()
-    if len(archive_index) == 1:
-      self.index_fp.write(
-          '[\'%s\', \'%s\'],\n' % (self.current_archive,
-                                   archive_index[0].filename))
-      archive.close()
-      return True
-    else:
-      archive.close()
-      return False
-
-  def FixArchive(self, problem):
-    """Make the archive compliant.
-
-    Args:
-      problem: the reason the archive is invalid
-
-    Returns:
-      Whether the file(s) removed to fix the archive could conceivably be
-      in an archive, but for some reason can't be added to this one.
-    """
-    archive_path = ''.join([self.output_dir, self.current_archive])
-    rtn_value = None
-    
-    if problem == 'SIZE':
-      archive_obj = self.OpenZipFileAtPath(archive_path, mode='r')
-      num_archive_files = len(archive_obj.infolist())
-      
-      # IF there is a single file, that means its too large to compress,
-      # delete the created archive
-      # ELSE do normal finalization
-      if num_archive_files == 1:
-        print ('WARNING: %s%s is too large to store.' % (
-            self.base_path, archive_obj.infolist()[0].filename))
-        archive_obj.close()
-        os.unlink(archive_path)
-        rtn_value = False
-      else:
-        self.RemoveLastFile(''.join([self.output_dir, self.current_archive]))
-        archive_obj.close()
-        print 'Final archive size for %s is %i' % (
-            self.current_archive, os.stat(archive_path)[stat.ST_SIZE])
-        rtn_value = True
-    return rtn_value
-
-  def AddFileToArchive(self, filepath, compress_bit):
-    """Add the file at filepath to the current archive.
-
-    Args:
-      filepath: the path of the file to add
-      compress_bit: whether or not this fiel should be compressed when added
-
-    Returns:
-      True if the file could be added (typically because this is a file) or
-      False if it couldn't be added (typically because its a directory)
-    """
-    curr_archive_path = ''.join([self.output_dir, self.current_archive])
-    if os.path.isfile(filepath):
-      if os.stat(filepath)[stat.ST_SIZE] > 1048576:
-        print 'Warning: %s is potentially too large to serve on GAE' % filepath
-      archive = self.OpenZipFileAtPath(curr_archive_path,
-                                       compress=compress_bit)
-      # add the file to the archive
-      archive.write(filepath, filepath[len(self.base_path):])
-      archive.close()
-      return True
-    else:
-      return False
-
-  def ArchiveIsValid(self):
-    """Check whether the archive is valid.
-
-    Currently this only checks whether the archive is under the required size.
-    The thought is that eventually this will do additional validation
-
-    Returns:
-      True if the archive is valid, False if its not
-    """
-    archive_path = ''.join([self.output_dir, self.current_archive])
-    if os.stat(archive_path)[stat.ST_SIZE] > self.max_size:
-      return False
-    else:
-      return True
-
-if __name__ == '__main__':
-  Main(sys.argv)
diff --git a/tools/scripts/divide_and_compress_constants.py b/tools/scripts/divide_and_compress_constants.py
deleted file mode 100644
index 4e11b6f..0000000
--- a/tools/scripts/divide_and_compress_constants.py
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/usr/bin/python2.4
-#
-# Copyright (C) 2008 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""Constants for the divide_and_compress script and DirectoryZipper class."""
-
-__author__ = 'jmatt@google.com (Justin Mattson)'
-
-file_preamble = ('#!/usr/bin/env python\n'
-                 '#\n'
-                 '# Copyright 2008 Google Inc.\n'
-                 '#\n'                                                       
-                 '# Licensed under the Apache License, Version 2.0 (the' 
-                 '\"License");\n'                               
-                 '# you may not use this file except in compliance with the '
-                 'License.\n'                                                 
-                 '# You may obtain a copy of the License at\n'           
-                 '#\n'
-                 '#     http://www.apache.org/licenses/LICENSE-2.0\n'
-                 '#\n'
-                 '# Unless required by applicable law or agreed to in writing,'
-                 ' software\n'                                              
-                 '# distributed under the License is distributed on an \"AS' 
-                 'IS\" BASIS,\n'
-                 '# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either '
-                 'express or implied.\n'
-                 '# See the License for the specific language governing' 
-                 ' permissions and\n'
-                 '# limitations under the License.\n'
-                 '#\n\n'
-                 'import wsgiref.handlers\n'
-                 'from google.appengine.ext import zipserve\n'
-                 'from google.appengine.ext import webapp\n'
-                 'import memcache_zipserve\n\n\n'
-                 'class MainHandler(webapp.RequestHandler):\n\n'
-                 '  def get(self):\n'
-                 '    self.response.out.write(\'Hello world!\')\n\n'
-                 'def main():\n'
-                 '  application = webapp.WSGIApplication([(\'/(.*)\','
-                 ' memcache_zipserve.create_handler([')
-
-file_endpiece = ('])),\n'
-                 '],\n'
-                 'debug=False)\n'
-                 '  wsgiref.handlers.CGIHandler().run(application)\n\n'
-                 'if __name__ == \'__main__\':\n'
-                 '  main()')
diff --git a/tools/scripts/iml.template b/tools/scripts/iml.template
deleted file mode 100644
index c4fe3a3..0000000
--- a/tools/scripts/iml.template
+++ /dev/null
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module version="4" relativePaths="true" type="JAVA_MODULE">
-  <component name="ModuleRootManager" />
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$">
-      <sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="library" name="android" level="project" />
-    <orderEntry type="inheritedJdk" />
-    <orderEntryProperties />
-  </component>
-</module>
diff --git a/tools/scripts/ipr.template b/tools/scripts/ipr.template
deleted file mode 100644
index cb3d65e..0000000
--- a/tools/scripts/ipr.template
+++ /dev/null
@@ -1,232 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4" relativePaths="false">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-    <buildFile url="file://$PROJECT_DIR$/build.xml">
-      <additionalClassPath />
-      <antReference projectDefault="true" />
-      <customJdkName value="" />
-      <maximumHeapSize value="128" />
-      <properties />
-    </buildFile>
-  </component>
-  <component name="BuildJarProjectSettings">
-    <option name="BUILD_JARS_ON_MAKE" value="false" />
-  </component>
-  <component name="CodeStyleProjectProfileManger">
-    <option name="PROJECT_PROFILE" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-  </component>
-  <component name="CodeStyleSettingsManager">
-    <option name="PER_PROJECT_SETTINGS" />
-    <option name="USE_PER_PROJECT_SETTINGS" value="false" />
-  </component>
-  <component name="CompilerConfiguration">
-    <option name="DEFAULT_COMPILER" value="Javac" />
-    <option name="DEPLOY_AFTER_MAKE" value="0" />
-    <resourceExtensions>
-      <entry name=".+\.(properties|xml|html|dtd|tld)" />
-      <entry name=".+\.(gif|png|jpeg|jpg)" />
-    </resourceExtensions>
-    <wildcardResourcePatterns>
-      <entry name="?*.properties" />
-      <entry name="?*.xml" />
-      <entry name="?*.gif" />
-      <entry name="?*.png" />
-      <entry name="?*.jpeg" />
-      <entry name="?*.jpg" />
-      <entry name="?*.html" />
-      <entry name="?*.dtd" />
-      <entry name="?*.tld" />
-    </wildcardResourcePatterns>
-  </component>
-  <component name="DataSourceManagerImpl" />
-  <component name="DependenciesAnalyzeManager">
-    <option name="myForwardDirection" value="false" />
-  </component>
-  <component name="DependencyValidationManager" />
-  <component name="EclipseCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EclipseEmbeddedCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EntryPointsManager">
-    <entry_points />
-  </component>
-  <component name="ExportToHTMLSettings">
-    <option name="PRINT_LINE_NUMBERS" value="false" />
-    <option name="OPEN_IN_BROWSER" value="false" />
-    <option name="OUTPUT_DIRECTORY" />
-  </component>
-  <component name="GUI Designer component loader factory" />
-  <component name="IdProvider" IDEtalkID="F6EC4D80E2C03FEF19EDD201903A6DFE" />
-  <component name="InspectionProjectProfileManager">
-    <option name="PROJECT_PROFILE" value="Project Default" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-    <scopes />
-    <profiles>
-      <profile version="1.0" is_locked="false">
-        <option name="myName" value="Project Default" />
-        <option name="myLocal" value="false" />
-        <used_levels>
-          <error>
-            <option name="myName" value="ERROR" />
-            <option name="myVal" value="400" />
-          </error>
-          <warning>
-            <option name="myName" value="WARNING" />
-            <option name="myVal" value="300" />
-          </warning>
-          <information>
-            <option name="myName" value="INFO" />
-            <option name="myVal" value="200" />
-          </information>
-          <server>
-            <option name="myName" value="SERVER PROBLEM" />
-            <option name="myVal" value="100" />
-          </server>
-        </used_levels>
-        <inspection_tool class="ClassReferencesSubclass" level="WARNING" enabled="true" />
-        <inspection_tool class="MissingOverrideAnnotation" level="WARNING" enabled="true" />
-        <inspection_tool class="Finalize" level="WARNING" enabled="true" />
-        <inspection_tool class="UnusedImport" level="WARNING" enabled="true" />
-        <inspection_tool class="StaticInheritance" level="WARNING" enabled="true" />
-        <inspection_tool class="RedundantMethodOverride" level="WARNING" enabled="true" />
-        <inspection_tool class="AbstractMethodCallInConstructor" level="WARNING" enabled="true" />
-        <inspection_tool class="RawUseOfParameterizedType" level="WARNING" enabled="true">
-          <option name="ignoreObjectConstruction" value="true" />
-          <option name="ignoreTypeCasts" value="false" />
-        </inspection_tool>
-        <inspection_tool class="SystemGC" level="WARNING" enabled="true" />
-        <inspection_tool class="ConstantNamingConvention" level="WARNING" enabled="true">
-          <option name="m_regex" value="[A-Z_\d]*" />
-          <option name="m_minLength" value="5" />
-          <option name="m_maxLength" value="32" />
-        </inspection_tool>
-        <inspection_tool class="EnumeratedConstantNamingConvention" level="WARNING" enabled="true">
-          <option name="m_regex" value="[A-Z][A-Za-z\d]*" />
-          <option name="m_minLength" value="5" />
-          <option name="m_maxLength" value="32" />
-        </inspection_tool>
-        <inspection_tool class="DivideByZero" level="WARNING" enabled="true" />
-        <inspection_tool class="CloneCallsConstructors" level="WARNING" enabled="true" />
-        <inspection_tool class="CloneDeclaresCloneNotSupported" level="WARNING" enabled="false" />
-        <inspection_tool class="CloneInNonCloneableClass" level="WARNING" enabled="true" />
-        <inspection_tool class="UtilityClassWithoutPrivateConstructor" level="WARNING" enabled="true">
-          <option name="ignoreClassesWithOnlyMain" value="false" />
-        </inspection_tool>
-        <inspection_tool class="UtilityClassWithPublicConstructor" level="WARNING" enabled="true" />
-        <inspection_tool class="ConditionalExpressionWithIdenticalBranches" level="WARNING" enabled="true" />
-        <inspection_tool class="CanBeFinal" level="WARNING" enabled="false">
-          <option name="REPORT_CLASSES" value="false" />
-          <option name="REPORT_METHODS" value="false" />
-          <option name="REPORT_FIELDS" value="true" />
-        </inspection_tool>
-        <inspection_tool class="ThisEscapedInConstructor" level="WARNING" enabled="true" />
-        <inspection_tool class="NonThreadSafeLazyInitialization" level="WARNING" enabled="true" />
-        <inspection_tool class="FieldMayBeStatic" level="WARNING" enabled="true" />
-        <inspection_tool class="InnerClassMayBeStatic" level="WARNING" enabled="true" />
-        <inspection_tool class="MethodMayBeStatic" level="WARNING" enabled="true">
-          <option name="m_onlyPrivateOrFinal" value="false" />
-          <option name="m_ignoreEmptyMethods" value="true" />
-        </inspection_tool>
-        <inspection_tool class="ComponentRegistrationProblems" level="ERROR" enabled="false">
-          <option name="CHECK_PLUGIN_XML" value="true" />
-          <option name="CHECK_JAVA_CODE" value="true" />
-          <option name="CHECK_ACTIONS" value="true" />
-        </inspection_tool>
-        <inspection_tool class="ComponentNotRegistered" level="WARNING" enabled="false">
-          <option name="CHECK_ACTIONS" value="true" />
-          <option name="IGNORE_NON_PUBLIC" value="true" />
-        </inspection_tool>
-        <inspection_tool class="BusyWait" level="WARNING" enabled="true" />
-        <inspection_tool class="UnconditionalWait" level="WARNING" enabled="true" />
-        <inspection_tool class="WaitNotInLoop" level="WARNING" enabled="true" />
-      </profile>
-    </profiles>
-  </component>
-  <component name="JavacSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="DEPRECATION" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="JavadocGenerationManager">
-    <option name="OUTPUT_DIRECTORY" />
-    <option name="OPTION_SCOPE" value="protected" />
-    <option name="OPTION_HIERARCHY" value="true" />
-    <option name="OPTION_NAVIGATOR" value="true" />
-    <option name="OPTION_INDEX" value="true" />
-    <option name="OPTION_SEPARATE_INDEX" value="true" />
-    <option name="OPTION_DOCUMENT_TAG_USE" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_AUTHOR" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_VERSION" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
-    <option name="OPTION_DEPRECATED_LIST" value="true" />
-    <option name="OTHER_OPTIONS" value="" />
-    <option name="HEAP_SIZE" />
-    <option name="LOCALE" />
-    <option name="OPEN_IN_BROWSER" value="true" />
-  </component>
-  <component name="JikesSettings">
-    <option name="JIKES_PATH" value="" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="DEPRECATION" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="IS_EMACS_ERRORS_MODE" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="LogConsolePreferences">
-    <option name="FILTER_ERRORS" value="false" />
-    <option name="FILTER_WARNINGS" value="false" />
-    <option name="FILTER_INFO" value="true" />
-    <option name="CUSTOM_FILTER" />
-  </component>
-  <component name="ProjectModuleManager">
-    <modules>
-      <module fileurl="file://$PROJECT_DIR$/ACTIVITY_NAME.iml" filepath="$PROJECT_DIR$/ACTIVITY_NAME.iml" />
-    </modules>
-  </component>
-  <component name="ProjectRootManager" version="2" assert-keyword="true" jdk-15="true" project-jdk-name="1.5" project-jdk-type="JavaSDK">
-    <output url="file://$PROJECT_DIR$/bin" />
-  </component>
-  <component name="ProjectRunConfigurationManager" />
-  <component name="RmicSettings">
-    <option name="IS_EANABLED" value="false" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="GENERATE_IIOP_STUBS" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="StarteamVcsAdapter" />
-  <component name="XSLT-Support.FileAssociationsManager" />
-  <component name="com.intellij.jsf.UserDefinedFacesConfigs">
-    <option name="USER_DEFINED_CONFIGS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </component>
-  <component name="libraryTable">
-    <library name="android">
-      <CLASSES>
-        <root url="jar://ANDROID_SDK_FOLDER/android.jar!/" />
-      </CLASSES>
-      <JAVADOC>
-        <root url="file://ANDROID_SDK_FOLDER/docs/reference" />
-      </JAVADOC>
-      <SOURCES />
-    </library>
-  </component>
-  <UsedPathMacros />
-</project>
diff --git a/tools/scripts/iws.template b/tools/scripts/iws.template
deleted file mode 100644
index 67d2053..0000000
--- a/tools/scripts/iws.template
+++ /dev/null
@@ -1,470 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4" relativePaths="false">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-    <buildFile url="file://$PROJECT_DIR$/build.xml">
-      <additionalClassPath />
-      <antReference projectDefault="true" />
-      <customJdkName value="" />
-      <maximumHeapSize value="128" />
-      <properties />
-    </buildFile>
-  </component>
-  <component name="BookmarkManager" />
-  <component name="ChangeBrowserSettings">
-    <option name="MAIN_SPLITTER_PROPORTION" value="0.3" />
-    <option name="MESSAGES_SPLITTER_PROPORTION" value="0.8" />
-    <option name="USE_DATE_BEFORE_FILTER" value="false" />
-    <option name="USE_DATE_AFTER_FILTER" value="false" />
-    <option name="USE_CHANGE_BEFORE_FILTER" value="false" />
-    <option name="USE_CHANGE_AFTER_FILTER" value="false" />
-    <option name="DATE_BEFORE" value="" />
-    <option name="DATE_AFTER" value="" />
-    <option name="CHANGE_BEFORE" value="" />
-    <option name="CHANGE_AFTER" value="" />
-    <option name="USE_USER_FILTER" value="false" />
-    <option name="USER" value="" />
-  </component>
-  <component name="ChangeListManager">
-    <list default="true" name="Default" comment="" />
-  </component>
-  <component name="ChangeListSynchronizer" />
-  <component name="ChangesViewManager" flattened_view="true" />
-  <component name="CheckinPanelState" />
-  <component name="Commander">
-    <leftPanel />
-    <rightPanel />
-    <splitter proportion="0.5" />
-  </component>
-  <component name="CompilerWorkspaceConfiguration">
-    <option name="COMPILE_IN_BACKGROUND" value="false" />
-    <option name="AUTO_SHOW_ERRORS_IN_EDITOR" value="true" />
-    <option name="CLOSE_MESSAGE_VIEW_IF_SUCCESS" value="true" />
-    <option name="COMPILE_DEPENDENT_FILES" value="false" />
-    <option name="CLEAR_OUTPUT_DIRECTORY" value="false" />
-    <option name="ASSERT_NOT_NULL" value="true" />
-  </component>
-  <component name="CoverageDataManager" />
-  <component name="Cvs2Configuration">
-    <option name="PRUNE_EMPTY_DIRECTORIES" value="true" />
-    <option name="MERGING_MODE" value="0" />
-    <option name="MERGE_WITH_BRANCH1_NAME" value="HEAD" />
-    <option name="MERGE_WITH_BRANCH2_NAME" value="HEAD" />
-    <option name="RESET_STICKY" value="false" />
-    <option name="CREATE_NEW_DIRECTORIES" value="true" />
-    <option name="DEFAULT_TEXT_FILE_SUBSTITUTION" value="kv" />
-    <option name="PROCESS_UNKNOWN_FILES" value="false" />
-    <option name="PROCESS_DELETED_FILES" value="false" />
-    <option name="PROCESS_IGNORED_FILES" value="false" />
-    <option name="RESERVED_EDIT" value="false" />
-    <option name="CHECKOUT_DATE_OR_REVISION_SETTINGS">
-      <value>
-        <option name="BRANCH" value="" />
-        <option name="DATE" value="" />
-        <option name="USE_BRANCH" value="false" />
-        <option name="USE_DATE" value="false" />
-      </value>
-    </option>
-    <option name="UPDATE_DATE_OR_REVISION_SETTINGS">
-      <value>
-        <option name="BRANCH" value="" />
-        <option name="DATE" value="" />
-        <option name="USE_BRANCH" value="false" />
-        <option name="USE_DATE" value="false" />
-      </value>
-    </option>
-    <option name="SHOW_CHANGES_REVISION_SETTINGS">
-      <value>
-        <option name="BRANCH" value="" />
-        <option name="DATE" value="" />
-        <option name="USE_BRANCH" value="false" />
-        <option name="USE_DATE" value="false" />
-      </value>
-    </option>
-    <option name="SHOW_OUTPUT" value="false" />
-    <option name="ADD_WATCH_INDEX" value="0" />
-    <option name="REMOVE_WATCH_INDEX" value="0" />
-    <option name="UPDATE_KEYWORD_SUBSTITUTION" />
-    <option name="MAKE_NEW_FILES_READONLY" value="false" />
-    <option name="SHOW_CORRUPTED_PROJECT_FILES" value="0" />
-    <option name="TAG_AFTER_PROJECT_COMMIT" value="false" />
-    <option name="OVERRIDE_EXISTING_TAG_FOR_PROJECT" value="true" />
-    <option name="TAG_AFTER_PROJECT_COMMIT_NAME" value="" />
-    <option name="CLEAN_COPY" value="false" />
-  </component>
-  <component name="DaemonCodeAnalyzer">
-    <disable_hints />
-  </component>
-  <component name="DebuggerManager">
-    <breakpoint_any>
-      <breakpoint>
-        <option name="NOTIFY_CAUGHT" value="true" />
-        <option name="NOTIFY_UNCAUGHT" value="true" />
-        <option name="ENABLED" value="false" />
-        <option name="SUSPEND_POLICY" value="SuspendAll" />
-        <option name="LOG_ENABLED" value="false" />
-        <option name="LOG_EXPRESSION_ENABLED" value="false" />
-        <option name="COUNT_FILTER_ENABLED" value="false" />
-        <option name="COUNT_FILTER" value="0" />
-        <option name="CONDITION_ENABLED" value="false" />
-        <option name="CLASS_FILTERS_ENABLED" value="false" />
-        <option name="INSTANCE_FILTERS_ENABLED" value="false" />
-        <option name="CONDITION" value="" />
-        <option name="LOG_MESSAGE" value="" />
-      </breakpoint>
-      <breakpoint>
-        <option name="NOTIFY_CAUGHT" value="true" />
-        <option name="NOTIFY_UNCAUGHT" value="true" />
-        <option name="ENABLED" value="false" />
-        <option name="SUSPEND_POLICY" value="SuspendAll" />
-        <option name="LOG_ENABLED" value="false" />
-        <option name="LOG_EXPRESSION_ENABLED" value="false" />
-        <option name="COUNT_FILTER_ENABLED" value="false" />
-        <option name="COUNT_FILTER" value="0" />
-        <option name="CONDITION_ENABLED" value="false" />
-        <option name="CLASS_FILTERS_ENABLED" value="false" />
-        <option name="INSTANCE_FILTERS_ENABLED" value="false" />
-        <option name="CONDITION" value="" />
-        <option name="LOG_MESSAGE" value="" />
-      </breakpoint>
-    </breakpoint_any>
-    <breakpoint_rules />
-    <ui_properties />
-  </component>
-  <component name="ErrorTreeViewConfiguration">
-    <option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
-    <option name="HIDE_WARNINGS" value="false" />
-  </component>
-  <component name="FavoritesManager">
-    <favorites_list name="LunarLander" />
-  </component>
-  <component name="FavoritesProjectViewPane" />
-	<component name="FileEditorManager">
-    <leaf>
-      <file leaf-file-name="ACTIVITY_NAME.java" pinned="false" current="true" current-in-tab="true">
-        <entry file="file://$PROJECT_DIR$/src/PACKAGE_PATH/ACTIVITY_NAME.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.08211144">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-    </leaf>
-  </component>
-  <component name="FindManager">
-    <FindUsagesManager>
-      <setting name="OPEN_NEW_TAB" value="false" />
-    </FindUsagesManager>
-  </component>
-  <component name="HierarchyBrowserManager">
-    <option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
-    <option name="SORT_ALPHABETICALLY" value="false" />
-    <option name="HIDE_CLASSES_WHERE_METHOD_NOT_IMPLEMENTED" value="false" />
-  </component>
-  <component name="InspectionManager">
-    <option name="AUTOSCROLL_TO_SOURCE" value="false" />
-    <option name="SPLITTER_PROPORTION" value="0.5" />
-    <option name="GROUP_BY_SEVERITY" value="false" />
-    <option name="FILTER_RESOLVED_ITEMS" value="true" />
-    <option name="ANALYZE_TEST_SOURCES" value="true" />
-    <option name="SHOW_DIFF_WITH_PREVIOUS_RUN" value="false" />
-    <option name="SCOPE_TYPE" value="1" />
-    <option name="CUSTOM_SCOPE_NAME" value="" />
-    <option name="SHOW_ONLY_DIFF" value="false" />
-    <option name="myCurrentProfileName" value="Default" />
-  </component>
-  <component name="J2EEProjectPane" />
-  <component name="JspContextManager" />
-  <component name="ModuleEditorState">
-    <option name="LAST_EDITED_MODULE_NAME" />
-    <option name="LAST_EDITED_TAB_NAME" />
-  </component>
-  <component name="NamedScopeManager" />
-  <component name="PackagesPane">
-    <subPane>
-      <PATH>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="ACTIVITY_NAME.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PackageViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="ACTIVITY_NAME" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PackageViewModuleNode" />
-        </PATH_ELEMENT>
-      </PATH>
-    </subPane>
-  </component>
-  <component name="PerforceChangeBrowserSettings">
-    <option name="USE_CLIENT_FILTER" value="true" />
-    <option name="CLIENT" value="" />
-  </component>
-  <component name="PerforceDirect.Settings">
-    <option name="useP4CONFIG" value="true" />
-    <option name="port" value="&lt;perforce_server&gt;:1666" />
-    <option name="client" value="" />
-    <option name="user" value="" />
-    <option name="passwd" value="" />
-    <option name="showCmds" value="false" />
-    <option name="useNativeApi" value="false" />
-    <option name="pathToExec" value="p4" />
-    <option name="useCustomPathToExec" value="false" />
-    <option name="SYNC_FORCE" value="false" />
-    <option name="SYNC_RUN_RESOLVE" value="true" />
-    <option name="REVERT_UNCHANGED_FILES" value="true" />
-    <option name="CHARSET" value="none" />
-    <option name="SHOW_BRANCHES_HISTORY" value="true" />
-    <option name="ENABLED" value="true" />
-    <option name="USE_LOGIN" value="false" />
-    <option name="LOGIN_SILENTLY" value="false" />
-    <option name="INTEGRATE_RUN_RESOLVE" value="true" />
-    <option name="INTEGRATE_REVERT_UNCHANGED" value="true" />
-    <option name="SERVER_TIMEOUT" value="20000" />
-  </component>
-  <component name="ProjectLevelVcsManager">
-    <OptionsSetting value="true" id="Add" />
-    <OptionsSetting value="true" id="Remove" />
-    <OptionsSetting value="true" id="Checkin" />
-    <OptionsSetting value="true" id="Checkout" />
-    <OptionsSetting value="true" id="Update" />
-    <OptionsSetting value="true" id="Status" />
-    <OptionsSetting value="true" id="Edit" />
-    <ConfirmationsSetting value="0" id="Add" />
-    <ConfirmationsSetting value="0" id="Remove" />
-  </component>
-  <component name="ProjectPane">
-    <subPane>
-      <PATH>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="ACTIVITY_NAME.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="ACTIVITY_NAME" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
-        </PATH_ELEMENT>
-      </PATH>
-    </subPane>
-  </component>
-  <component name="ProjectReloadState">
-    <option name="STATE" value="0" />
-  </component>
-  <component name="ProjectView">
-    <navigator currentView="ProjectPane" proportions="0.1" version="1" splitterProportion="0.5">
-      <flattenPackages />
-      <showMembers />
-      <showModules />
-      <showLibraryContents />
-      <hideEmptyPackages />
-      <abbreviatePackageNames />
-      <showStructure PackagesPane="false" ProjectPane="false" />
-      <autoscrollToSource />
-      <autoscrollFromSource />
-      <sortByType />
-    </navigator>
-  </component>
-  <component name="PropertiesComponent">
-    <property name="MemberChooser.copyJavadoc" value="false" />
-    <property name="GoToClass.includeLibraries" value="false" />
-    <property name="MemberChooser.showClasses" value="true" />
-    <property name="MemberChooser.sorted" value="false" />
-    <property name="GoToFile.includeJavaFiles" value="false" />
-    <property name="GoToClass.toSaveIncludeLibraries" value="false" />
-  </component>
-  <component name="ReadonlyStatusHandler">
-    <option name="SHOW_DIALOG" value="true" />
-  </component>
-  <component name="RecentsManager" />
-  <component name="RestoreUpdateTree" />
-  <component name="RunManager">
-    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
-      <option name="MAIN_CLASS_NAME" />
-      <option name="VM_PARAMETERS" />
-      <option name="PROGRAM_PARAMETERS" />
-      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-      <option name="ENABLE_SWING_INSPECTOR" value="false" />
-      <module name="" />
-    </configuration>
-    <configuration default="true" type="Applet" factoryName="Applet">
-      <module name="" />
-      <option name="MAIN_CLASS_NAME" />
-      <option name="HTML_FILE_NAME" />
-      <option name="HTML_USED" value="false" />
-      <option name="WIDTH" value="400" />
-      <option name="HEIGHT" value="300" />
-      <option name="POLICY_FILE" value="/Developer/Applications/IntelliJ IDEA 6.0.4.app/bin/appletviewer.policy" />
-      <option name="VM_PARAMETERS" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-    </configuration>
-    <configuration default="true" type="JUnit" factoryName="JUnit" enabled="false" merge="false">
-      <module name="" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-      <option name="PACKAGE_NAME" />
-      <option name="MAIN_CLASS_NAME" />
-      <option name="METHOD_NAME" />
-      <option name="TEST_OBJECT" value="class" />
-      <option name="VM_PARAMETERS" />
-      <option name="PARAMETERS" />
-      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
-      <option name="ADDITIONAL_CLASS_PATH" />
-      <option name="TEST_SEARCH_SCOPE">
-        <value defaultName="wholeProject" />
-      </option>
-    </configuration>
-    <configuration default="true" type="Remote" factoryName="Remote">
-      <option name="USE_SOCKET_TRANSPORT" value="true" />
-      <option name="SERVER_MODE" value="false" />
-      <option name="SHMEM_ADDRESS" value="javadebug" />
-      <option name="HOST" value="localhost" />
-      <option name="PORT" value="5005" />
-    </configuration>
-  </component>
-  <component name="ScopeViewComponent" />
-  <component name="SelectInManager" />
-  <component name="StarteamConfiguration">
-    <option name="SERVER" value="" />
-    <option name="PORT" value="49201" />
-    <option name="USER" value="" />
-    <option name="PASSWORD" value="" />
-    <option name="PROJECT" value="" />
-    <option name="VIEW" value="" />
-    <option name="ALTERNATIVE_WORKING_PATH" value="" />
-    <option name="LOCK_ON_CHECKOUT" value="false" />
-    <option name="UNLOCK_ON_CHECKIN" value="false" />
-  </component>
-  <component name="StructuralSearchPlugin" />
-  <component name="StructureViewFactory">
-    <option name="AUTOSCROLL_MODE" value="true" />
-    <option name="AUTOSCROLL_FROM_SOURCE" value="false" />
-    <option name="ACTIVE_ACTIONS" value="" />
-  </component>
-  <component name="Struts Assistant">
-    <option name="showInputs" value="true" />
-    <option name="resources">
-      <value>
-        <option name="strutsPath" />
-        <option name="strutsHelp" />
-      </value>
-    </option>
-    <option name="selectedTaglibs" />
-    <option name="selectedTaglibs" />
-    <option name="myStrutsValidationEnabled" value="true" />
-    <option name="myTilesValidationEnabled" value="true" />
-    <option name="myValidatorValidationEnabled" value="true" />
-    <option name="myReportErrorsAsWarnings" value="true" />
-  </component>
-  <component name="SvnChangesBrowserSettings">
-    <option name="USE_AUTHOR_FIELD" value="true" />
-    <option name="AUTHOR" value="" />
-    <option name="LOCATION" value="" />
-    <option name="USE_PROJECT_SETTINGS" value="true" />
-    <option name="USE_ALTERNATE_LOCATION" value="false" />
-  </component>
-  <component name="SvnConfiguration">
-    <option name="USER" value="" />
-    <option name="PASSWORD" value="" />
-    <option name="PROCESS_UNRESOLVED" value="false" />
-    <option name="LAST_MERGED_REVISION" />
-    <option name="UPDATE_RUN_STATUS" value="false" />
-    <option name="UPDATE_RECURSIVELY" value="true" />
-    <option name="MERGE_DRY_RUN" value="false" />
-    <upgradeMode>auto</upgradeMode>
-  </component>
-  <component name="TodoView" selected-index="0">
-    <todo-panel id="selected-file">
-      <are-packages-shown value="false" />
-      <are-modules-shown value="false" />
-      <flatten-packages value="false" />
-      <is-autoscroll-to-source value="true" />
-    </todo-panel>
-    <todo-panel id="all">
-      <are-packages-shown value="true" />
-      <are-modules-shown value="false" />
-      <flatten-packages value="false" />
-      <is-autoscroll-to-source value="true" />
-    </todo-panel>
-  </component>
-  <component name="ToolWindowManager">
-    <frame x="0" y="22" width="1440" height="834" extended-state="0" />
-    <editor active="false" />
-    <layout>
-      <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="IDEtalk" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="7" />
-      <window_info id="Project" active="true" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.24946082" order="0" />
-      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="1" />
-      <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="1" />
-      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" order="6" />
-      <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="1" />
-      <window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
-      <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="2" />
-      <window_info id="File View" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" order="4" />
-      <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.4" order="0" />
-      <window_info id="IDEtalk Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="-1" />
-      <window_info id="Web" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="2" />
-      <window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="0" />
-      <window_info id="EJB" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="3" />
-      <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" order="5" />
-    </layout>
-  </component>
-  <component name="VCS.FileViewConfiguration">
-    <option name="SELECTED_STATUSES" value="DEFAULT" />
-    <option name="SELECTED_COLUMNS" value="DEFAULT" />
-    <option name="SHOW_FILTERS" value="true" />
-    <option name="CUSTOMIZE_VIEW" value="true" />
-    <option name="SHOW_FILE_HISTORY_AS_TREE" value="true" />
-  </component>
-  <component name="VcsManagerConfiguration">
-    <option name="OFFER_MOVE_TO_ANOTHER_CHANGELIST_ON_PARTIAL_COMMIT" value="true" />
-    <option name="CHECK_CODE_SMELLS_BEFORE_PROJECT_COMMIT" value="true" />
-    <option name="PERFORM_UPDATE_IN_BACKGROUND" value="false" />
-    <option name="PERFORM_COMMIT_IN_BACKGROUND" value="false" />
-    <option name="PUT_FOCUS_INTO_COMMENT" value="false" />
-    <option name="FORCE_NON_EMPTY_COMMENT" value="false" />
-    <option name="LAST_COMMIT_MESSAGE" />
-    <option name="SAVE_LAST_COMMIT_MESSAGE" value="true" />
-    <option name="CHECKIN_DIALOG_SPLITTER_PROPORTION" value="0.8" />
-    <option name="OPTIMIZE_IMPORTS_BEFORE_PROJECT_COMMIT" value="false" />
-    <option name="REFORMAT_BEFORE_PROJECT_COMMIT" value="false" />
-    <option name="REFORMAT_BEFORE_FILE_COMMIT" value="false" />
-    <option name="FILE_HISTORY_DIALOG_COMMENTS_SPLITTER_PROPORTION" value="0.8" />
-    <option name="FILE_HISTORY_DIALOG_SPLITTER_PROPORTION" value="0.5" />
-    <option name="ERROR_OCCURED" value="false" />
-    <option name="ACTIVE_VCS_NAME" value="CVS" />
-    <option name="UPDATE_GROUP_BY_PACKAGES" value="false" />
-    <option name="SHOW_FILE_HISTORY_AS_TREE" value="false" />
-    <option name="FILE_HISTORY_SPLITTER_PROPORTION" value="0.6" />
-  </component>
-  <component name="XPathView.XPathProjectComponent">
-    <history />
-    <find-history />
-  </component>
-  <component name="XSLT-Support.FileAssociationsSettings" />
-  <component name="antWorkspaceConfiguration">
-    <option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
-    <option name="FILTER_TARGETS" value="false" />
-  </component>
-  <component name="com.intellij.ide.util.scopeChooser.ScopeChooserConfigurable" proportions="" version="1">
-    <option name="myLastEditedConfigurable" />
-  </component>
-  <component name="com.intellij.openapi.roots.ui.configuration.projectRoot.ProjectRootMasterDetailsConfigurable" proportions="0.1" version="1">
-    <option name="myPlainMode" value="false" />
-    <option name="myLastEditedConfigurable" value="android" />
-  </component>
-  <component name="com.intellij.profile.ui.ErrorOptionsConfigurable" proportions="" version="1">
-    <option name="myLastEditedConfigurable" />
-  </component>
-  <component name="editorHistoryManager" />
-</project>
\ No newline at end of file
diff --git a/tools/scripts/java_file.template b/tools/scripts/java_file.template
deleted file mode 100644
index aeb541f..0000000
--- a/tools/scripts/java_file.template
+++ /dev/null
@@ -1,15 +0,0 @@
-package PACKAGE;
-
-import android.app.Activity;
-import android.os.Bundle;
-
-public class ACTIVITY_NAME extends Activity
-{
-    /** Called when the activity is first created. */
-    @Override
-    public void onCreate(Bundle savedInstanceState)
-    {
-        super.onCreate(savedInstanceState);
-        setContentView(R.layout.main);
-    }
-}
diff --git a/tools/scripts/java_tests_file.template b/tools/scripts/java_tests_file.template
deleted file mode 100644
index 7781a33..0000000
--- a/tools/scripts/java_tests_file.template
+++ /dev/null
@@ -1,21 +0,0 @@
-package PACKAGE;
-
-import android.test.ActivityInstrumentationTestCase;
-
-/**
- * This is a simple framework for a test of an Application.  See
- * {@link android.test.ApplicationTestCase ApplicationTestCase} for more information on
- * how to write and extend Application tests.
- * <p/>
- * To run this test, you can type:
- * adb shell am instrument -w \
- * -e class PACKAGE.ACTIVITY_NAMETest \
- * PACKAGE.tests/android.test.InstrumentationTestRunner
- */
-public class ACTIVITY_NAMETest extends ActivityInstrumentationTestCase<ACTIVITY_NAME> {
-
-    public ACTIVITY_NAMETest() {
-        super("PACKAGE", ACTIVITY_NAME.class);
-    }
-
-}
\ No newline at end of file
diff --git a/tools/scripts/layout.template b/tools/scripts/layout.template
deleted file mode 100644
index 864e997..0000000
--- a/tools/scripts/layout.template
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:orientation="vertical"
-    android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-    >
-<TextView  
-    android:layout_width="fill_parent" 
-    android:layout_height="wrap_content" 
-    android:text="Hello World, ACTIVITY_NAME"
-    />
-</LinearLayout>
-
diff --git a/tools/scripts/plugin.prop b/tools/scripts/plugin.prop
deleted file mode 100644
index 99dba4a..0000000
--- a/tools/scripts/plugin.prop
+++ /dev/null
@@ -1,4 +0,0 @@
-# begin plugin.prop
-plugin.version=0.9.0
-plugin.platform=android
-# end plugin.prop
\ No newline at end of file
diff --git a/tools/scripts/sdk_clean.sh b/tools/scripts/sdk_clean.sh
deleted file mode 100755
index 467d560..0000000
--- a/tools/scripts/sdk_clean.sh
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/bin/bash
-#
-# This script processes a set of files given as arguments as sample code to be  released
-# in the SDK.
-#
-# Note that these files are modified in-place.
-#
-
-DIR=$1
-
-#
-# Remove BEGIN_INCLUDE and END_INCLUDE lines used by the javadoc.
-#
-# This does it by replacing these lines with blank lines so line numbers aren't
-# changed in the process, making it easier to match 3rd party complaints/questions
-# with the source tree.
-#
-# sed on Mac OS takes -i SUFFIX and sed on Linux takes -iSUFFIX
-#
-if [ $HOST_OS = darwin ] ; then
-find $DIR -name "*.java" -o -name "*.xml" | xargs -n 1 \
-    sed \
-        -e "s/.*BEGIN_INCLUDE(.*//" \
-        -e "s/.*END_INCLUDE(.*//" \
-        -i ""
-else
-find $DIR -name "*.java" -o -name "*.xml" | xargs -n 1 \
-    sed \
-        -e "s/.*BEGIN_INCLUDE(.*//" \
-        -e "s/.*END_INCLUDE(.*//" \
-        -i
-fi
-
-#
-# Fix up the line endings of all text files
-#
-if [ $HOST_OS = windows ] ; then
-    ENDING_TYPE=dos
-else
-    ENDING_TYPE=unix
-fi
-find $DIR -name "*.aidl" -o -name "*.css" -o -name "*.html" -o -name "*.java" \
-                     -o -name "*.js" -o -name "*.prop" -o -name "*.py" \
-                     -o -name "*.template" -o -name "*.txt" -o -name "*.windows" \
-                     -o -name "*.xml" \
-        | xargs $HOST_OUT_EXECUTABLES/line_endings $ENDING_TYPE
-
-
diff --git a/tools/scripts/strings.template b/tools/scripts/strings.template
deleted file mode 100644
index acc28e2..0000000
--- a/tools/scripts/strings.template
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
-    <string name="app_name">ACTIVITY_NAME</string>
-</resources>
diff --git a/tools/scripts/test_divide_and_compress.py b/tools/scripts/test_divide_and_compress.py
deleted file mode 100755
index d0d27b3..0000000
--- a/tools/scripts/test_divide_and_compress.py
+++ /dev/null
@@ -1,490 +0,0 @@
-#!/usr/bin/python2.4
-#
-# Copyright (C) 2008 Google Inc.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-"""Tests for divide_and_compress.py.
-
-TODO: Add tests for module methods.
-"""
-
-__author__ = 'jmatt@google.com (Justin Mattson)'
-
-import os
-import stat
-import unittest
-import zipfile
-from zipfile import ZipFile
-
-import divide_and_compress
-from mox import mox
-
-
-class BagOfParts(object):
-  """Just a generic class that I can use to assign random attributes to."""
-
-  def NoOp(self):
-    x = 1
-
-    
-class ValidAndRemoveTests(unittest.TestCase):
-  """Test the ArchiveIsValid and RemoveLastFile methods."""
-  
-  def setUp(self):
-    """Prepare the test.
-
-    Construct some mock objects for use with the tests.
-    """
-    self.my_mox = mox.Mox()
-    file1 = BagOfParts()
-    file1.filename = 'file1.txt'
-    file1.contents = 'This is a test file'
-    file2 = BagOfParts()
-    file2.filename = 'file2.txt'
-    file2.contents = ('akdjfk;djsf;kljdslkfjslkdfjlsfjkdvn;kn;2389rtu4i'
-                      'tn;ghf8:89H*hp748FJw80fu9WJFpwf39pujens;fihkhjfk'
-                      'sdjfljkgsc n;iself')
-    self.files = {'file1': file1, 'file2': file2}
-
-  def testArchiveIsValid(self):
-    """Test the DirectoryZipper.ArchiveIsValid method.
-
-    Run two tests, one that we expect to pass and one that we expect to fail
-    """
-    test_file_size = 1056730
-    self.my_mox.StubOutWithMock(os, 'stat')
-    os.stat('/foo/0.zip').AndReturn([test_file_size])
-    self.my_mox.StubOutWithMock(stat, 'ST_SIZE')
-    stat.ST_SIZE = 0
-    os.stat('/baz/0.zip').AndReturn([test_file_size])
-    mox.Replay(os.stat)
-    test_target = divide_and_compress.DirectoryZipper('/foo/', 'bar', 
-                                                      test_file_size - 1, True)
-
-    self.assertEqual(False, test_target.ArchiveIsValid(),
-                     msg=('ERROR: Test failed, ArchiveIsValid should have '
-                          'returned false, but returned true'))
-
-    test_target = divide_and_compress.DirectoryZipper('/baz/', 'bar',
-                                                      test_file_size + 1, True)
-    self.assertEqual(True, test_target.ArchiveIsValid(),
-                     msg=('ERROR: Test failed, ArchiveIsValid should have'
-                          ' returned true, but returned false'))
-
-  def testRemoveLastFile(self):
-    """Test DirectoryZipper.RemoveLastFile method.
-
-    Construct a ZipInfo mock object with two records, verify that write is
-    only called once on the new ZipFile object.
-    """
-    source = self.CreateZipSource()
-    dest = self.CreateZipDestination()
-    source_path = ''.join([os.getcwd(), '/0-old.zip'])
-    dest_path = ''.join([os.getcwd(), '/0.zip'])
-    test_target = divide_and_compress.DirectoryZipper(
-        ''.join([os.getcwd(), '/']), 'dummy', 1024*1024, True)
-    self.my_mox.StubOutWithMock(test_target, 'OpenZipFileAtPath')
-    test_target.OpenZipFileAtPath(source_path, mode='r').AndReturn(source)
-    test_target.OpenZipFileAtPath(dest_path,
-                                  compress=zipfile.ZIP_DEFLATED,
-                                  mode='w').AndReturn(dest)
-    self.my_mox.StubOutWithMock(os, 'rename')
-    os.rename(dest_path, source_path)
-    self.my_mox.StubOutWithMock(os, 'unlink')
-    os.unlink(source_path)
-    
-    self.my_mox.ReplayAll()
-    test_target.RemoveLastFile()
-    self.my_mox.VerifyAll()    
-
-  def CreateZipSource(self):
-    """Create a mock zip sourec object.
-
-    Read should only be called once, because the second file is the one
-    being removed.
-
-    Returns:
-      A configured mocked
-    """
-    
-    source_zip = self.my_mox.CreateMock(ZipFile)
-    source_zip.infolist().AndReturn([self.files['file1'], self.files['file1']])
-    source_zip.infolist().AndReturn([self.files['file1'], self.files['file1']])
-    source_zip.read(self.files['file1'].filename).AndReturn(
-        self.files['file1'].contents)
-    source_zip.close()
-    return source_zip
-
-  def CreateZipDestination(self):
-    """Create mock destination zip.
-
-    Write should only be called once, because there are two files in the
-    source zip and we expect the second to be removed.
-
-    Returns:
-      A configured mocked
-    """
-    
-    dest_zip = mox.MockObject(ZipFile)
-    dest_zip.writestr(self.files['file1'].filename,
-                      self.files['file1'].contents)
-    dest_zip.close()
-    return dest_zip
-
-  def tearDown(self):
-    """Remove any stubs we've created."""
-    self.my_mox.UnsetStubs()
-
-
-class FixArchiveTests(unittest.TestCase):
-  """Tests for the DirectoryZipper.FixArchive method."""
-  
-  def setUp(self):
-    """Create a mock file object."""
-    self.my_mox = mox.Mox()
-    self.file1 = BagOfParts()
-    self.file1.filename = 'file1.txt'
-    self.file1.contents = 'This is a test file'
-
-  def _InitMultiFileData(self):
-    """Create an array of mock file objects.
-
-    Create three mock file objects that we can use for testing.
-    """
-    self.multi_file_dir = []
-    
-    file1 = BagOfParts()
-    file1.filename = 'file1.txt'
-    file1.contents = 'kjaskl;jkdjfkja;kjsnbvjnvnbuewklriujalvjsd'
-    self.multi_file_dir.append(file1)
-
-    file2 = BagOfParts()
-    file2.filename = 'file2.txt'
-    file2.contents = ('He entered the room and there in the center, it was.'
-                      ' Looking upon the thing, suddenly he could not remember'
-                      ' whether he had actually seen it before or whether'
-                      ' his memory of it was merely the effect of something'
-                      ' so often being imagined that it had long since become '
-                      ' manifest in his mind.')
-    self.multi_file_dir.append(file2)
-
-    file3 = BagOfParts()
-    file3.filename = 'file3.txt'
-    file3.contents = 'Whoa, what is \'file2.txt\' all about?'
-    self.multi_file_dir.append(file3)
-    
-  def testSingleFileArchive(self):
-    """Test behavior of FixArchive when the archive has a single member.
-
-    We expect that when this method is called with an archive that has a
-    single member that it will return False and unlink the archive.
-    """
-    test_target = divide_and_compress.DirectoryZipper(
-        ''.join([os.getcwd(), '/']), 'dummy', 1024*1024, True)
-    self.my_mox.StubOutWithMock(test_target, 'OpenZipFileAtPath')
-    test_target.OpenZipFileAtPath(
-        ''.join([os.getcwd(), '/0.zip']), mode='r').AndReturn(
-            self.CreateSingleFileMock())
-    self.my_mox.StubOutWithMock(os, 'unlink')
-    os.unlink(''.join([os.getcwd(), '/0.zip']))
-    self.my_mox.ReplayAll()
-    self.assertEqual(False, test_target.FixArchive('SIZE'))
-    self.my_mox.VerifyAll()
-
-  def CreateSingleFileMock(self):
-    """Create a mock ZipFile object for testSingleFileArchive.
-
-    We just need it to return a single member infolist twice
-
-    Returns:
-      A configured mock object
-    """
-    mock_zip = self.my_mox.CreateMock(ZipFile)
-    mock_zip.infolist().AndReturn([self.file1])
-    mock_zip.infolist().AndReturn([self.file1])
-    mock_zip.close()
-    return mock_zip
-
-  def testMultiFileArchive(self):
-    """Test behavior of DirectoryZipper.FixArchive with a multi-file archive.
-
-    We expect that FixArchive will rename the old archive, adding '-old' before
-    '.zip', read all the members except the last one of '-old' into a new
-    archive with the same name as the original, and then unlink the '-old' copy
-    """
-    test_target = divide_and_compress.DirectoryZipper(
-        ''.join([os.getcwd(), '/']), 'dummy', 1024*1024, True)
-    self.my_mox.StubOutWithMock(test_target, 'OpenZipFileAtPath')
-    test_target.OpenZipFileAtPath(
-        ''.join([os.getcwd(), '/0.zip']), mode='r').AndReturn(
-            self.CreateMultiFileMock())
-    self.my_mox.StubOutWithMock(test_target, 'RemoveLastFile')
-    test_target.RemoveLastFile(''.join([os.getcwd(), '/0.zip']))
-    self.my_mox.StubOutWithMock(os, 'stat')
-    os.stat(''.join([os.getcwd(), '/0.zip'])).AndReturn([49302])
-    self.my_mox.StubOutWithMock(stat, 'ST_SIZE')
-    stat.ST_SIZE = 0
-    self.my_mox.ReplayAll()
-    self.assertEqual(True, test_target.FixArchive('SIZE'))
-    self.my_mox.VerifyAll()
-
-  def CreateMultiFileMock(self):
-    """Create mock ZipFile object for use with testMultiFileArchive.
-
-    The mock just needs to return the infolist mock that is prepared in
-    InitMultiFileData()
-
-    Returns:
-      A configured mock object
-    """
-    self._InitMultiFileData()
-    mock_zip = self.my_mox.CreateMock(ZipFile)
-    mock_zip.infolist().AndReturn(self.multi_file_dir)
-    mock_zip.close()
-    return mock_zip
-
-  def tearDown(self):
-    """Unset any mocks that we've created."""
-    self.my_mox.UnsetStubs()
-
-
-class AddFileToArchiveTest(unittest.TestCase):
-  """Test behavior of method to add a file to an archive."""
-
-  def setUp(self):
-    """Setup the arguments for the DirectoryZipper object."""
-    self.my_mox = mox.Mox()
-    self.output_dir = '%s/' % os.getcwd()
-    self.file_to_add = 'file.txt'
-    self.input_dir = '/foo/bar/baz/'
-
-  def testAddFileToArchive(self):
-    """Test the DirectoryZipper.AddFileToArchive method.
-
-    We are testing a pretty trivial method, we just expect it to look at the
-    file its adding, so that it possible can through out a warning.
-    """
-    test_target = divide_and_compress.DirectoryZipper(self.output_dir,
-                                                      self.input_dir,
-                                                      1024*1024, True)
-    self.my_mox.StubOutWithMock(test_target, 'OpenZipFileAtPath')
-    archive_mock = self.CreateArchiveMock()
-    test_target.OpenZipFileAtPath(
-        ''.join([self.output_dir, '0.zip']),
-        compress=zipfile.ZIP_DEFLATED).AndReturn(archive_mock)
-    self.StubOutOsModule()
-    self.my_mox.ReplayAll()
-    test_target.AddFileToArchive(''.join([self.input_dir, self.file_to_add]),
-                                 zipfile.ZIP_DEFLATED)
-    self.my_mox.VerifyAll()
-
-  def StubOutOsModule(self):
-    """Create a mock for the os.path and os.stat objects.
-
-    Create a stub that will return the type (file or directory) and size of the
-    object that is to be added.
-    """
-    self.my_mox.StubOutWithMock(os.path, 'isfile')
-    os.path.isfile(''.join([self.input_dir, self.file_to_add])).AndReturn(True)
-    self.my_mox.StubOutWithMock(os, 'stat')
-    os.stat(''.join([self.input_dir, self.file_to_add])).AndReturn([39480])
-    self.my_mox.StubOutWithMock(stat, 'ST_SIZE')
-    stat.ST_SIZE = 0
-    
-  def CreateArchiveMock(self):
-    """Create a mock ZipFile for use with testAddFileToArchive.
-
-    Just verify that write is called with the file we expect and that the
-    archive is closed after the file addition
-
-    Returns:
-      A configured mock object
-    """
-    archive_mock = self.my_mox.CreateMock(ZipFile)
-    archive_mock.write(''.join([self.input_dir, self.file_to_add]),
-                       self.file_to_add)
-    archive_mock.close()
-    return archive_mock
-
-  def tearDown(self):
-    self.my_mox.UnsetStubs()
-
-
-class CompressDirectoryTest(unittest.TestCase):
-  """Test the master method of the class.
-
-  Testing with the following directory structure.
-  /dir1/
-  /dir1/file1.txt
-  /dir1/file2.txt
-  /dir1/dir2/
-  /dir1/dir2/dir3/
-  /dir1/dir2/dir4/
-  /dir1/dir2/dir4/file3.txt
-  /dir1/dir5/
-  /dir1/dir5/file4.txt
-  /dir1/dir5/file5.txt
-  /dir1/dir5/file6.txt
-  /dir1/dir5/file7.txt
-  /dir1/dir6/
-  /dir1/dir6/file8.txt
-
-  file1.txt., file2.txt, file3.txt should be in 0.zip
-  file4.txt should be in 1.zip
-  file5.txt, file6.txt should be in 2.zip
-  file7.txt will not be stored since it will be too large compressed
-  file8.txt should b in 3.zip
-  """
-
-  def setUp(self):
-    """Setup all the mocks for this test."""
-    self.my_mox = mox.Mox()
-
-    self.base_dir = '/dir1'
-    self.output_path = '/out_dir/'
-    self.test_target = divide_and_compress.DirectoryZipper(
-        self.output_path, self.base_dir, 1024*1024, True)
-    
-    self.InitArgLists()
-    self.InitOsDotPath()
-    self.InitArchiveIsValid()
-    self.InitWriteIndexRecord()
-    self.InitAddFileToArchive()
-
-  def tearDown(self):
-    self.my_mox.UnsetStubs()
-
-  def testCompressDirectory(self):
-    """Test the DirectoryZipper.CompressDirectory method."""
-    self.my_mox.ReplayAll()
-    for arguments in self.argument_lists:
-      self.test_target.CompressDirectory(None, arguments[0], arguments[1])
-    self.my_mox.VerifyAll()
-
-  def InitAddFileToArchive(self):
-    """Setup mock for DirectoryZipper.AddFileToArchive.
-
-    Make sure that the files are added in the order we expect.
-    """
-    self.my_mox.StubOutWithMock(self.test_target, 'AddFileToArchive')
-    self.test_target.AddFileToArchive('/dir1/file1.txt', zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/file2.txt', zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir2/dir4/file3.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file4.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file4.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file5.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file5.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file6.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file7.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir5/file7.txt',
-                                      zipfile.ZIP_DEFLATED)
-    self.test_target.AddFileToArchive('/dir1/dir6/file8.txt',
-                                      zipfile.ZIP_DEFLATED)
-  
-  def InitWriteIndexRecord(self):
-    """Setup mock for DirectoryZipper.WriteIndexRecord."""
-    self.my_mox.StubOutWithMock(self.test_target, 'WriteIndexRecord')
-
-    # we are trying to compress 8 files, but we should only attempt to
-    # write an index record 7 times, because one file is too large to be stored
-    self.test_target.WriteIndexRecord().AndReturn(True)
-    self.test_target.WriteIndexRecord().AndReturn(False)
-    self.test_target.WriteIndexRecord().AndReturn(False)
-    self.test_target.WriteIndexRecord().AndReturn(True)
-    self.test_target.WriteIndexRecord().AndReturn(True)
-    self.test_target.WriteIndexRecord().AndReturn(False)
-    self.test_target.WriteIndexRecord().AndReturn(True)
-
-  def InitArchiveIsValid(self):
-    """Mock out DirectoryZipper.ArchiveIsValid and DirectoryZipper.FixArchive.
-
-    Mock these methods out such that file1, file2, and file3 go into one
-    archive. file4 then goes into the next archive, file5 and file6 in the
-    next, file 7 should appear too large to compress into an archive, and
-    file8 goes into the final archive
-    """
-    self.my_mox.StubOutWithMock(self.test_target, 'ArchiveIsValid')
-    self.my_mox.StubOutWithMock(self.test_target, 'FixArchive')
-    self.test_target.ArchiveIsValid().AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-
-    # should be file4.txt
-    self.test_target.ArchiveIsValid().AndReturn(False)
-    self.test_target.FixArchive('SIZE').AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-
-    # should be file5.txt
-    self.test_target.ArchiveIsValid().AndReturn(False)
-    self.test_target.FixArchive('SIZE').AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-
-    # should be file7.txt
-    self.test_target.ArchiveIsValid().AndReturn(False)
-    self.test_target.FixArchive('SIZE').AndReturn(True)
-    self.test_target.ArchiveIsValid().AndReturn(False)
-    self.test_target.FixArchive('SIZE').AndReturn(False)
-    self.test_target.ArchiveIsValid().AndReturn(True)
-    
-  def InitOsDotPath(self):
-    """Mock out os.path.isfile.
-
-    Mock this out so the things we want to appear as files appear as files and
-    the things we want to appear as directories appear as directories. Also
-    make sure that the order of file visits is as we expect (which is why
-    InAnyOrder isn't used here).
-    """
-    self.my_mox.StubOutWithMock(os.path, 'isfile')
-    os.path.isfile('/dir1/dir2').AndReturn(False)
-    os.path.isfile('/dir1/dir5').AndReturn(False)
-    os.path.isfile('/dir1/dir6').AndReturn(False)
-    os.path.isfile('/dir1/file1.txt').AndReturn(True)
-    os.path.isfile('/dir1/file2.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir2/dir3').AndReturn(False)
-    os.path.isfile('/dir1/dir2/dir4').AndReturn(False)
-    os.path.isfile('/dir1/dir2/dir4/file3.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file4.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file4.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file5.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file5.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file6.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file7.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir5/file7.txt').AndReturn(True)
-    os.path.isfile('/dir1/dir6/file8.txt').AndReturn(True)
-
-  def InitArgLists(self):
-    """Create the directory path => directory contents mappings."""
-    self.argument_lists = []
-    self.argument_lists.append(['/dir1',
-                                ['file1.txt', 'file2.txt', 'dir2', 'dir5',
-                                 'dir6']])
-    self.argument_lists.append(['/dir1/dir2', ['dir3', 'dir4']])
-    self.argument_lists.append(['/dir1/dir2/dir3', []])
-    self.argument_lists.append(['/dir1/dir2/dir4', ['file3.txt']])
-    self.argument_lists.append(['/dir1/dir5',
-                                ['file4.txt', 'file5.txt', 'file6.txt',
-                                 'file7.txt']])
-    self.argument_lists.append(['/dir1/dir6', ['file8.txt']])
-      
-if __name__ == '__main__':
-  unittest.main()
diff --git a/tools/sdkmanager/Android.mk b/tools/sdkmanager/Android.mk
deleted file mode 100644
index 30df7f1..0000000
--- a/tools/sdkmanager/Android.mk
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-SDKMANAGER_LOCAL_DIR := $(call my-dir)
-include $(SDKMANAGER_LOCAL_DIR)/app/Android.mk
-include $(SDKMANAGER_LOCAL_DIR)/libs/Android.mk
diff --git a/tools/sdkmanager/MODULE_LICENSE_APACHE2 b/tools/sdkmanager/MODULE_LICENSE_APACHE2
deleted file mode 100644
index e69de29..0000000
--- a/tools/sdkmanager/MODULE_LICENSE_APACHE2
+++ /dev/null
diff --git a/tools/sdkmanager/app/.classpath b/tools/sdkmanager/app/.classpath
deleted file mode 100644
index cbd9d37..0000000
--- a/tools/sdkmanager/app/.classpath
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="src" path="tests"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkUiLib"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/sdkmanager/app/.project b/tools/sdkmanager/app/.project
deleted file mode 100644
index e12c17d..0000000
--- a/tools/sdkmanager/app/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>SdkManager</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/sdkmanager/app/Android.mk b/tools/sdkmanager/app/Android.mk
deleted file mode 100644
index 24ba61f..0000000
--- a/tools/sdkmanager/app/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-SDKMANAGERAPP_LOCAL_DIR := $(call my-dir)
-include $(SDKMANAGERAPP_LOCAL_DIR)/etc/Android.mk
-include $(SDKMANAGERAPP_LOCAL_DIR)/src/Android.mk
diff --git a/tools/sdkmanager/app/etc/Android.mk b/tools/sdkmanager/app/etc/Android.mk
deleted file mode 100644
index 8723cd8..0000000
--- a/tools/sdkmanager/app/etc/Android.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := android
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/sdkmanager/app/etc/android b/tools/sdkmanager/app/etc/android
deleted file mode 100755
index af4042b..0000000
--- a/tools/sdkmanager/app/etc/android
+++ /dev/null
@@ -1,84 +0,0 @@
-#!/bin/sh
-# Copyright 2005-2007, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/`basename "${prog}"`
-cd "${oldwd}"
-
-jarfile=sdkmanager.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo `basename "$prog"`": can't find $jarfile"
-    exit 1
-fi
-
-
-# Check args.
-if [ debug = "$1" ]; then
-    # add this in for debugging
-    java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-else
-    java_debug=
-fi
-
-# Mac OS X needs an additional arg, or you get an "illegal thread" complaint.
-if [ `uname` = "Darwin" ]; then
-    os_opts="-XstartOnFirstThread"
-    #because Java 1.6 is 64 bits only and SWT doesn't support this, we force the usage of java 1.5
-    java_cmd="/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Commands/java"
-else
-    os_opts=
-    java_cmd="java"
-fi
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-# need to use "java.ext.dirs" because "-jar" causes classpath to be ignored
-# might need more memory, e.g. -Xmx128M
-exec "$java_cmd" -Xmx256M $os_opts $java_debug -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -Dcom.android.sdkmanager.toolsdir="$progdir" -jar "$jarpath" "$@"
diff --git a/tools/sdkmanager/app/etc/android.bat b/tools/sdkmanager/app/etc/android.bat
deleted file mode 100755
index 1af1e47..0000000
--- a/tools/sdkmanager/app/etc/android.bat
+++ /dev/null
@@ -1,51 +0,0 @@
-@echo off
-rem Copyright (C) 2007 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Grab current directory before we change it
-set workdir=%cd%
-
-rem Change current directory to where ddms is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=sdkmanager.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-    set libdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-    set libdir=..\lib\
-
-:JarFileOk
-
-if debug NEQ "%1" goto NoDebug
-    set java_debug=-agentlib:jdwp=transport=dt_socket,server=y,address=8050,suspend=y
-    shift 1
-:NoDebug
-
-set jarpath=%frameworkdir%%jarfile%
-
-call java %java_debug% -Djava.ext.dirs=%frameworkdir% -Djava.library.path=%libdir% -Dcom.android.sdkmanager.toolsdir= -Dcom.android.sdkmanager.workdir="%workdir%" -jar %jarpath% %*
diff --git a/tools/sdkmanager/app/etc/manifest.txt b/tools/sdkmanager/app/etc/manifest.txt
deleted file mode 100644
index 5676634..0000000
--- a/tools/sdkmanager/app/etc/manifest.txt
+++ /dev/null
@@ -1 +0,0 @@
-Main-Class: com.android.sdkmanager.Main
diff --git a/tools/sdkmanager/app/src/Android.mk b/tools/sdkmanager/app/src/Android.mk
deleted file mode 100644
index b508076..0000000
--- a/tools/sdkmanager/app/src/Android.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	androidprefs \
-	sdklib \
-	sdkuilib
-LOCAL_MODULE := sdkmanager
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/sdkmanager/app/src/com/android/sdkmanager/CommandLineProcessor.java b/tools/sdkmanager/app/src/com/android/sdkmanager/CommandLineProcessor.java
deleted file mode 100644
index 9f3fb99..0000000
--- a/tools/sdkmanager/app/src/com/android/sdkmanager/CommandLineProcessor.java
+++ /dev/null
@@ -1,791 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.sdklib.ISdkLog;
-
-import java.util.HashMap;
-import java.util.Map.Entry;
-
-/**
- * Parses the command-line and stores flags needed or requested.
- * <p/>
- * This is a base class. To be useful you want to:
- * <ul>
- * <li>override it.
- * <li>pass an action array to the constructor.
- * <li>define flags for your actions.
- * </ul> 
- * <p/>
- * To use, call {@link #parseArgs(String[])} and then
- * call {@link #getValue(String, String, String)}.
- */
-public class CommandLineProcessor {
-
-    /** Internal verb name for internally hidden flags. */
-    public final static String GLOBAL_FLAG_VERB = "@@internal@@";
-    
-    /** String to use when the verb doesn't need any object. */
-    public final static String NO_VERB_OBJECT = "";
-    
-    /** The global help flag. */ 
-    public static final String KEY_HELP = "help";
-    /** The global verbose flag. */
-    public static final String KEY_VERBOSE = "verbose";
-    /** The global silent flag. */
-    public static final String KEY_SILENT = "silent";
-    
-    /** Verb requested by the user. Null if none specified, which will be an error. */
-    private String mVerbRequested;
-    /** Direct object requested by the user. Can be null. */
-    private String mDirectObjectRequested;
-
-    /**
-     * Action definitions.
-     * <p/>
-     * Each entry is a string array with:
-     * <ul>
-     * <li> the verb.
-     * <li> a direct object (use #NO_VERB_OBJECT if there's no object).
-     * <li> a description.
-     * <li> an alternate form for the object (e.g. plural).
-     * </ul>
-     */
-    private final String[][] mActions;
-    
-    private static final int ACTION_VERB_INDEX = 0;
-    private static final int ACTION_OBJECT_INDEX = 1;
-    private static final int ACTION_DESC_INDEX = 2;
-    private static final int ACTION_ALT_OBJECT_INDEX = 3;
-
-    /**
-     * The map of all defined arguments.
-     * <p/>
-     * The key is a string "verb/directObject/longName".
-     */
-    private final HashMap<String, Arg> mArguments = new HashMap<String, Arg>();
-    /** Logger */
-    private final ISdkLog mLog;
-    
-    public CommandLineProcessor(ISdkLog logger, String[][] actions) {
-        mLog = logger;
-        mActions = actions;
-
-        define(MODE.BOOLEAN, false, GLOBAL_FLAG_VERB, NO_VERB_OBJECT, "v", KEY_VERBOSE,
-                "Verbose mode: errors, warnings and informational messages are printed.",
-                false);
-        define(MODE.BOOLEAN, false, GLOBAL_FLAG_VERB, NO_VERB_OBJECT, "s", KEY_SILENT,
-                "Silent mode: only errors are printed out.",
-                false);
-        define(MODE.BOOLEAN, false, GLOBAL_FLAG_VERB, NO_VERB_OBJECT, "h", KEY_HELP,
-                "This help.",
-                false);
-    }
-    
-    //------------------
-    // Helpers to get flags values
-
-    /** Helper that returns true if --verbose was requested. */
-    public boolean isVerbose() {
-        return ((Boolean) getValue(GLOBAL_FLAG_VERB, NO_VERB_OBJECT, KEY_VERBOSE)).booleanValue();
-    }
-
-    /** Helper that returns true if --silent was requested. */
-    public boolean isSilent() {
-        return ((Boolean) getValue(GLOBAL_FLAG_VERB, NO_VERB_OBJECT, KEY_SILENT)).booleanValue();
-    }
-
-    /** Helper that returns true if --help was requested. */
-    public boolean isHelpRequested() {
-        return ((Boolean) getValue(GLOBAL_FLAG_VERB, NO_VERB_OBJECT, KEY_HELP)).booleanValue();
-    }
-    
-    /** Returns the verb name from the command-line. Can be null. */
-    public String getVerb() {
-        return mVerbRequested;
-    }
-
-    /** Returns the direct object name from the command-line. Can be null. */
-    public String getDirectObject() {
-        return mDirectObjectRequested;
-    }
-    
-    //------------------
-    
-    /**
-     * Raw access to parsed parameter values.
-     * <p/>
-     * The default is to scan all parameters. Parameters that have been explicitly set on the
-     * command line are returned first. Otherwise one with a non-null value is returned.
-     * <p/>
-     * Both a verb and a direct object filter can be specified. When they are non-null they limit
-     * the scope of the search. 
-     * <p/>
-     * If nothing has been found, return the last default value seen matching the filter.
-     * 
-     * @param verb The verb name, including {@link #GLOBAL_FLAG_VERB}. If null, all possible
-     *             verbs that match the direct object condition will be examined and the first
-     *             value set will be used.
-     * @param directObject The direct object name, including {@link #NO_VERB_OBJECT}. If null,
-     *             all possible direct objects that match the verb condition will be examined and
-     *             the first value set will be used.
-     * @param longFlagName The long flag name for the given action. Mandatory. Cannot be null.
-     * @return The current value object stored in the parameter, which depends on the argument mode.
-     */
-    public Object getValue(String verb, String directObject, String longFlagName) {
-
-        if (verb != null && directObject != null) {
-            String key = verb + "/" + directObject + "/" + longFlagName;
-            Arg arg = mArguments.get(key);
-            return arg.getCurrentValue();
-        }
-        
-        Object lastDefault = null;
-        for (Arg arg : mArguments.values()) {
-            if (arg.getLongArg().equals(longFlagName)) {
-                if (verb == null || arg.getVerb().equals(verb)) {
-                    if (directObject == null || arg.getDirectObject().equals(directObject)) {
-                        if (arg.isInCommandLine()) {
-                            return arg.getCurrentValue();
-                        }
-                        if (arg.getCurrentValue() != null) {
-                            lastDefault = arg.getCurrentValue();
-                        }
-                    }
-                }
-            }
-        }
-        
-        return lastDefault;
-    }
-
-    /**
-     * Internal setter for raw parameter value.
-     * @param verb The verb name, including {@link #GLOBAL_FLAG_VERB}.
-     * @param directObject The direct object name, including {@link #NO_VERB_OBJECT}.
-     * @param longFlagName The long flag name for the given action.
-     * @param value The new current value object stored in the parameter, which depends on the
-     *              argument mode.
-     */
-    protected void setValue(String verb, String directObject, String longFlagName, Object value) {
-        String key = verb + "/" + directObject + "/" + longFlagName;
-        Arg arg = mArguments.get(key);
-        arg.setCurrentValue(value);
-    }
-
-    /**
-     * Parses the command-line arguments.
-     * <p/>
-     * This method will exit and not return if a parsing error arise.
-     * 
-     * @param args The arguments typically received by a main method.
-     */
-    public void parseArgs(String[] args) {
-        String needsHelp = null;
-        String verb = null;
-        String directObject = null;
-
-        try {
-            int n = args.length;
-            for (int i = 0; i < n; i++) {
-                Arg arg = null;
-                String a = args[i];
-                if (a.startsWith("--")) {
-                    arg = findLongArg(verb, directObject, a.substring(2));
-                } else if (a.startsWith("-")) {
-                    arg = findShortArg(verb, directObject, a.substring(1));
-                }
-                
-                // No matching argument name found
-                if (arg == null) {
-                    // Does it looks like a dashed parameter?
-                    if (a.startsWith("-")) {
-                        if (verb == null || directObject == null) {
-                            // It looks like a dashed parameter and we don't have a a verb/object
-                            // set yet, the parameter was just given too early.
-    
-                            needsHelp = String.format(
-                                "Flag '%1$s' is not a valid global flag. Did you mean to specify it after the verb/object name?",
-                                a);
-                            return;
-                        } else {
-                            // It looks like a dashed parameter and but it is unknown by this
-                            // verb-object combination
-                            
-                            needsHelp = String.format(
-                                    "Flag '%1$s' is not valid for '%2$s %3$s'.",
-                                    a, verb, directObject);
-                            return;
-                        }
-                    }
-                    
-                    if (verb == null) {
-                        // Fill verb first. Find it.
-                        for (String[] actionDesc : mActions) {
-                            if (actionDesc[ACTION_VERB_INDEX].equals(a)) {
-                                verb = a;
-                                break;
-                            }
-                        }
-                        
-                        // Error if it was not a valid verb
-                        if (verb == null) {
-                            needsHelp = String.format(
-                                "Expected verb after global parameters but found '%1$s' instead.",
-                                a);
-                            return;
-                        }
-    
-                    } else if (directObject == null) {
-                        // Then fill the direct object. Find it.
-                        for (String[] actionDesc : mActions) {
-                            if (actionDesc[ACTION_VERB_INDEX].equals(verb)) {
-                                if (actionDesc[ACTION_OBJECT_INDEX].equals(a)) {
-                                    directObject = a;
-                                    break;
-                                } else if (actionDesc.length > ACTION_ALT_OBJECT_INDEX &&
-                                        actionDesc[ACTION_ALT_OBJECT_INDEX].equals(a)) {
-                                    // if the alternate form exist and is used, we internally
-                                    // only memorize the default direct object form.
-                                    directObject = actionDesc[ACTION_OBJECT_INDEX];
-                                    break;
-                                }
-                            }
-                        }
-                        
-                        // Error if it was not a valid object for that verb
-                        if (directObject == null) {
-                            needsHelp = String.format(
-                                "Expected verb after global parameters but found '%1$s' instead.",
-                                a);
-                            return;
-                            
-                        }
-                    }
-                } else if (arg != null) {
-                    // This argument was present on the command line
-                    arg.setInCommandLine(true);
-                    
-                    // Process keyword
-                    String error = null;
-                    if (arg.getMode().needsExtra()) {
-                        if (++i >= n) {
-                            needsHelp = String.format("Missing argument for flag %1$s.", a);
-                            return;
-                        }
-                        
-                        error = arg.getMode().process(arg, args[i]);
-                    } else {
-                        error = arg.getMode().process(arg, null);
-    
-                        // If we just toggled help, we want to exit now without printing any error.
-                        // We do this test here only when a Boolean flag is toggled since booleans
-                        // are the only flags that don't take parameters and help is a boolean.
-                        if (isHelpRequested()) {
-                            printHelpAndExit(null);
-                            // The call above should terminate however in unit tests we override
-                            // it so we still need to return here.
-                            return;
-                        }
-                    }
-                    
-                    if (error != null) {
-                        needsHelp = String.format("Invalid usage for flag %1$s: %2$s.", a, error);
-                        return;
-                    }
-                }
-            }
-        
-            if (needsHelp == null) {
-                if (verb == null) {
-                    needsHelp = "Missing verb name.";
-                } else {
-                    if (directObject == null) {
-                        // Make sure this verb has an optional direct object
-                        for (String[] actionDesc : mActions) {
-                            if (actionDesc[ACTION_VERB_INDEX].equals(verb) &&
-                                    actionDesc[ACTION_OBJECT_INDEX].equals(NO_VERB_OBJECT)) {
-                                directObject = NO_VERB_OBJECT;
-                                break;
-                            }
-                        }
-    
-                        if (directObject == null) {
-                            needsHelp = String.format("Missing object name for verb '%1$s'.", verb);
-                            return;
-                        }
-                    }
-                    
-                    // Validate that all mandatory arguments are non-null for this action
-                    String missing = null;
-                    boolean plural = false;
-                    for (Entry<String, Arg> entry : mArguments.entrySet()) {
-                        Arg arg = entry.getValue();
-                        if (arg.getVerb().equals(verb) &&
-                                arg.getDirectObject().equals(directObject)) {
-                            if (arg.isMandatory() && arg.getCurrentValue() == null) {
-                                if (missing == null) {
-                                    missing = "--" + arg.getLongArg();
-                                } else {
-                                    missing += ", --" + arg.getLongArg();
-                                    plural = true;
-                                }
-                            }
-                        }
-                    }
-    
-                    if (missing != null) {
-                        needsHelp  = String.format(
-                                "The %1$s %2$s must be defined for action '%3$s %4$s'",
-                                plural ? "parameters" : "parameter",
-                                missing,
-                                verb,
-                                directObject);
-                    }
-
-                    mVerbRequested = verb;
-                    mDirectObjectRequested = directObject;
-                }
-            }
-        } finally {
-            if (needsHelp != null) {
-                printHelpAndExitForAction(verb, directObject, needsHelp);
-            }
-        }
-    }
-    
-    /**
-     * Finds an {@link Arg} given an action name and a long flag name.
-     * @return The {@link Arg} found or null.
-     */
-    protected Arg findLongArg(String verb, String directObject, String longName) {
-        if (verb == null) {
-            verb = GLOBAL_FLAG_VERB;
-        }
-        if (directObject == null) {
-            directObject = NO_VERB_OBJECT;
-        }
-        String key = verb + "/" + directObject + "/" + longName;
-        return mArguments.get(key);
-    }
-
-    /**
-     * Finds an {@link Arg} given an action name and a short flag name.
-     * @return The {@link Arg} found or null.
-     */
-    protected Arg findShortArg(String verb, String directObject, String shortName) {
-        if (verb == null) {
-            verb = GLOBAL_FLAG_VERB;
-        }
-        if (directObject == null) {
-            directObject = NO_VERB_OBJECT;
-        }
-
-        for (Entry<String, Arg> entry : mArguments.entrySet()) {
-            Arg arg = entry.getValue();
-            if (arg.getVerb().equals(verb) && arg.getDirectObject().equals(directObject)) {
-                if (shortName.equals(arg.getShortArg())) {
-                    return arg;
-                }
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Prints the help/usage and exits.
-     * 
-     * @param errorFormat Optional error message to print prior to usage using String.format 
-     * @param args Arguments for String.format
-     */
-    public void printHelpAndExit(String errorFormat, Object... args) {
-        printHelpAndExitForAction(null /*verb*/, null /*directObject*/, errorFormat, args);
-    }
-    
-    /**
-     * Prints the help/usage and exits.
-     * 
-     * @param verb If null, displays help for all verbs. If not null, display help only
-     *          for that specific verb. In all cases also displays general usage and action list.
-     * @param directObject If null, displays help for all verb objects.
-     *          If not null, displays help only for that specific action
-     *          In all cases also display general usage and action list.
-     * @param errorFormat Optional error message to print prior to usage using String.format 
-     * @param args Arguments for String.format
-     */
-    public void printHelpAndExitForAction(String verb, String directObject,
-            String errorFormat, Object... args) {
-        if (errorFormat != null) {
-            stderr(errorFormat, args);
-        }
-        
-        /*
-         * usage should fit in 80 columns
-         *   12345678901234567890123456789012345678901234567890123456789012345678901234567890
-         */
-        stdout("\n" +
-            "Usage:\n" +
-            "  android [global options] action [action options]\n" +
-            "\n" +
-            "Global options:");
-        listOptions(GLOBAL_FLAG_VERB, NO_VERB_OBJECT);
-
-        if (verb == null || directObject == null) {
-            stdout("\nValid actions are composed of a verb and an optional direct object:");
-            for (String[] action : mActions) {
-                
-                stdout("- %1$6s %2$-7s: %3$s",
-                        action[ACTION_VERB_INDEX],
-                        action[ACTION_OBJECT_INDEX],
-                        action[ACTION_DESC_INDEX]);
-            }
-        }
-        
-        for (String[] action : mActions) {
-            if (verb == null || verb.equals(action[ACTION_VERB_INDEX])) {
-                if (directObject == null || directObject.equals(action[ACTION_OBJECT_INDEX])) {
-                    stdout("\nAction \"%1$s %2$s\":",
-                            action[ACTION_VERB_INDEX],
-                            action[ACTION_OBJECT_INDEX]);
-                    stdout("  %1$s", action[ACTION_DESC_INDEX]);
-                    stdout("Options:");
-                    listOptions(action[ACTION_VERB_INDEX], action[ACTION_OBJECT_INDEX]);
-                }
-            }
-        }
-        
-        exit();
-    }
-
-    /**
-     * Internal helper to print all the option flags for a given action name.
-     */
-    protected void listOptions(String verb, String directObject) {
-        int numOptions = 0;
-        for (Entry<String, Arg> entry : mArguments.entrySet()) {
-            Arg arg = entry.getValue();
-            if (arg.getVerb().equals(verb) && arg.getDirectObject().equals(directObject)) {
-                
-                String value = "";
-                if (arg.getDefaultValue() instanceof String[]) {
-                    for (String v : (String[]) arg.getDefaultValue()) {
-                        if (value.length() > 0) {
-                            value += ", ";
-                        }
-                        value += v;
-                    }
-                } else if (arg.getDefaultValue() != null) {
-                    value = arg.getDefaultValue().toString();
-                }
-                if (value.length() > 0) {
-                    value = " (" + value + ")";
-                }
-                
-                String required = arg.isMandatory() ? " [required]" : "";
-
-                stdout("  -%1$s %2$-10s %3$s%4$s%5$s",
-                        arg.getShortArg(),
-                        "--" + arg.getLongArg(),
-                        arg.getDescription(),
-                        value,
-                        required);
-                numOptions++;
-            }
-        }
-        
-        if (numOptions == 0) {
-            stdout("  No options");
-        }
-    }
-
-    //----
-    
-    /**
-     * The mode of an argument specifies the type of variable it represents,
-     * whether an extra parameter is required after the flag and how to parse it.
-     */
-    static enum MODE {
-        /** Argument value is a Boolean. Default value is a Boolean. */
-        BOOLEAN {
-            @Override
-            public boolean needsExtra() {
-                return false;
-            }
-            @Override
-            public String process(Arg arg, String extra) {
-                // Toggle the current value
-                arg.setCurrentValue(! ((Boolean) arg.getCurrentValue()).booleanValue());
-                return null;
-            }
-        },
-
-        /** Argument value is an Integer. Default value is an Integer. */
-        INTEGER {
-            @Override
-            public boolean needsExtra() {
-                return true;
-            }
-            @Override
-            public String process(Arg arg, String extra) {
-                try {
-                    arg.setCurrentValue(Integer.parseInt(extra));
-                    return null;
-                } catch (NumberFormatException e) {
-                    return String.format("Failed to parse '%1$s' as an integer: %2%s",
-                            extra, e.getMessage());
-                }
-            }
-        },
-        
-        /** Argument value is a String. Default value is a String[]. */
-        ENUM {
-            @Override
-            public boolean needsExtra() {
-                return true;
-            }
-            @Override
-            public String process(Arg arg, String extra) {
-                StringBuilder desc = new StringBuilder();
-                String[] values = (String[]) arg.getDefaultValue();
-                for (String value : values) {
-                    if (value.equals(extra)) {
-                        arg.setCurrentValue(extra);
-                        return null;
-                    }
-                    
-                    if (desc.length() != 0) {
-                        desc.append(", ");
-                    }
-                    desc.append(value);
-                }
-
-                return String.format("'%1$s' is not one of %2$s", extra, desc.toString());
-            }
-        },
-        
-        /** Argument value is a String. Default value is a null. */
-        STRING {
-            @Override
-            public boolean needsExtra() {
-                return true;
-            }
-            @Override
-            public String process(Arg arg, String extra) {
-                arg.setCurrentValue(extra);
-                return null;
-            }
-        };
-        
-        /**
-         * Returns true if this mode requires an extra parameter.
-         */
-        public abstract boolean needsExtra();
-
-        /**
-         * Processes the flag for this argument.
-         * 
-         * @param arg The argument being processed.
-         * @param extra The extra parameter. Null if {@link #needsExtra()} returned false. 
-         * @return An error string or null if there's no error.
-         */
-        public abstract String process(Arg arg, String extra);
-    }
-
-    /**
-     * An argument accepted by the command-line, also called "a flag".
-     * Arguments must have a short version (one letter), a long version name and a description.
-     * They can have a default value, or it can be null.
-     * Depending on the {@link MODE}, the default value can be a Boolean, an Integer, a String
-     * or a String array (in which case the first item is the current by default.)  
-     */
-    static class Arg {
-        /** Verb for that argument. Never null. */
-        private final String mVerb;
-        /** Direct Object for that argument. Never null, but can be empty string. */
-        private final String mDirectObject;
-        /** The 1-letter short name of the argument, e.g. -v. */
-        private final String mShortName;
-        /** The long name of the argument, e.g. --verbose. */
-        private final String mLongName;
-        /** A description. Never null. */
-        private final String mDescription;
-        /** A default value. Can be null. */
-        private final Object mDefaultValue;
-        /** The argument mode (type + process method). Never null. */
-        private final MODE mMode;
-        /** True if this argument is mandatory for this verb/directobject. */
-        private final boolean mMandatory;
-        /** Current value. Initially set to the default value. */
-        private Object mCurrentValue;
-        /** True if the argument has been used on the command line. */
-        private boolean mInCommandLine;
-
-        /**
-         * Creates a new argument flag description.
-         * 
-         * @param mode The {@link MODE} for the argument.
-         * @param mandatory True if this argument is mandatory for this action. 
-         * @param directObject The action name. Can be #NO_VERB_OBJECT or #INTERNAL_FLAG.
-         * @param shortName The one-letter short argument name. Cannot be empty nor null.
-         * @param longName The long argument name. Cannot be empty nor null.
-         * @param description The description. Cannot be null.
-         * @param defaultValue The default value (or values), which depends on the selected {@link MODE}.
-         */
-        public Arg(MODE mode,
-                   boolean mandatory,
-                   String verb,
-                   String directObject,
-                   String shortName,
-                   String longName,
-                   String description,
-                   Object defaultValue) {
-            mMode = mode;
-            mMandatory = mandatory;
-            mVerb = verb;
-            mDirectObject = directObject;
-            mShortName = shortName;
-            mLongName = longName;
-            mDescription = description;
-            mDefaultValue = defaultValue;
-            mInCommandLine = false;
-            if (defaultValue instanceof String[]) {
-                mCurrentValue = ((String[])defaultValue)[0];
-            } else {
-                mCurrentValue = mDefaultValue;
-            }
-        }
-        
-        /** Return true if this argument is mandatory for this verb/directobject. */
-        public boolean isMandatory() {
-            return mMandatory;
-        }
-        
-        /** Returns the 1-letter short name of the argument, e.g. -v. */
-        public String getShortArg() {
-            return mShortName;
-        }
-        
-        /** Returns the long name of the argument, e.g. --verbose. */
-        public String getLongArg() {
-            return mLongName;
-        }
-        
-        /** Returns the description. Never null. */
-        public String getDescription() {
-            return mDescription;
-        }
-        
-        /** Returns the verb for that argument. Never null. */
-        public String getVerb() {
-            return mVerb;
-        }
-
-        /** Returns the direct Object for that argument. Never null, but can be empty string. */
-        public String getDirectObject() {
-            return mDirectObject;
-        }
-        
-        /** Returns the default value. Can be null. */
-        public Object getDefaultValue() {
-            return mDefaultValue;
-        }
-        
-        /** Returns the current value. Initially set to the default value. Can be null. */
-        public Object getCurrentValue() {
-            return mCurrentValue;
-        }
-
-        /** Sets the current value. Can be null. */
-        public void setCurrentValue(Object currentValue) {
-            mCurrentValue = currentValue;
-        }
-        
-        /** Returns the argument mode (type + process method). Never null. */
-        public MODE getMode() {
-            return mMode;
-        }
-        
-        /** Returns true if the argument has been used on the command line. */
-        public boolean isInCommandLine() {
-            return mInCommandLine;
-        }
-        
-        /** Sets if the argument has been used on the command line. */
-        public void setInCommandLine(boolean inCommandLine) {
-            mInCommandLine = inCommandLine;
-        }
-    }
-    
-    /**
-     * Internal helper to define a new argument for a give action.
-     * 
-     * @param mode The {@link MODE} for the argument.
-     * @param verb The verb name. Can be #INTERNAL_VERB.
-     * @param directObject The action name. Can be #NO_VERB_OBJECT or #INTERNAL_FLAG.
-     * @param shortName The one-letter short argument name. Cannot be empty nor null.
-     * @param longName The long argument name. Cannot be empty nor null.
-     * @param description The description. Cannot be null.
-     * @param defaultValue The default value (or values), which depends on the selected {@link MODE}.
-     */
-    protected void define(MODE mode,
-            boolean mandatory,
-            String verb,
-            String directObject,
-            String shortName, String longName,
-            String description, Object defaultValue) {
-        assert(mandatory || mode == MODE.BOOLEAN); // a boolean mode cannot be mandatory
-        
-        if (directObject == null) {
-            directObject = NO_VERB_OBJECT;
-        }
-        
-        String key = verb + "/" + directObject + "/" + longName;
-        mArguments.put(key, new Arg(mode, mandatory,
-                verb, directObject, shortName, longName, description, defaultValue));
-    }
-
-    /**
-     * Exits in case of error.
-     * This is protected so that it can be overridden in unit tests.
-     */
-    protected void exit() {
-        System.exit(1);
-    }
-
-    /**
-     * Prints a line to stdout.
-     * This is protected so that it can be overridden in unit tests.
-     * 
-     * @param format The string to be formatted. Cannot be null.
-     * @param args Format arguments.
-     */
-    protected void stdout(String format, Object...args) {
-        mLog.printf(format + "\n", args);
-    }
-
-    /**
-     * Prints a line to stderr.
-     * This is protected so that it can be overridden in unit tests.
-     * 
-     * @param format The string to be formatted. Cannot be null.
-     * @param args Format arguments.
-     */
-    protected void stderr(String format, Object...args) {
-        mLog.error(null, format, args);
-    }
-}
diff --git a/tools/sdkmanager/app/src/com/android/sdkmanager/Main.java b/tools/sdkmanager/app/src/com/android/sdkmanager/Main.java
deleted file mode 100644
index 1a15fce..0000000
--- a/tools/sdkmanager/app/src/com/android/sdkmanager/Main.java
+++ /dev/null
@@ -1,811 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.prefs.AndroidLocation;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkConstants;
-import com.android.sdklib.SdkManager;
-import com.android.sdklib.IAndroidTarget.IOptionalLibrary;
-import com.android.sdklib.avd.AvdManager;
-import com.android.sdklib.avd.HardwareProperties;
-import com.android.sdklib.avd.AvdManager.AvdInfo;
-import com.android.sdklib.avd.HardwareProperties.HardwareProperty;
-import com.android.sdklib.project.ProjectCreator;
-import com.android.sdklib.project.ProjectCreator.OutputLevel;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Main class for the 'android' application.
- */
-class Main {
-
-    /** Java property that defines the location of the sdk/tools directory. */
-    private final static String TOOLSDIR = "com.android.sdkmanager.toolsdir";
-    /** Java property that defines the working directory. On Windows the current working directory
-     *  is actually the tools dir, in which case this is used to get the original CWD. */
-    private final static String WORKDIR = "com.android.sdkmanager.workdir";
-    
-    private final static String[] BOOLEAN_YES_REPLIES = new String[] { "yes", "y" };
-    private final static String[] BOOLEAN_NO_REPLIES = new String[] { "no", "n" };
-
-    /** Path to the SDK folder. This is the parent of {@link #TOOLSDIR}. */
-    private String mSdkFolder;
-    /** Logger object. Use this to print normal output, warnings or errors. */
-    private ISdkLog mSdkLog;
-    /** The SDK manager parses the SDK folder and gives access to the content. */
-    private SdkManager mSdkManager;
-    /** Command-line processor with options specific to SdkManager. */
-    private SdkCommandLine mSdkCommandLine;
-    /** The working directory, either null or set to an existing absolute canonical directory. */
-    private File mWorkDir;
-
-    public static void main(String[] args) {
-        new Main().run(args);
-    }
-    
-    /**
-     * Runs the sdk manager app
-     */
-    private void run(String[] args) {
-        createLogger();
-        init();
-        mSdkCommandLine.parseArgs(args);
-        parseSdk();
-        doAction();
-    }
-
-    /**
-     * Creates the {@link #mSdkLog} object.
-     * <p/>
-     * This must be done before {@link #init()} as it will be used to report errors.
-     */
-    private void createLogger() {
-        mSdkLog = new ISdkLog() {
-            public void error(Throwable t, String errorFormat, Object... args) {
-                if (errorFormat != null) {
-                    System.err.printf("Error: " + errorFormat, args);
-                    if (!errorFormat.endsWith("\n")) {
-                        System.err.printf("\n");
-                    }
-                }
-                if (t != null) {
-                    System.err.printf("Error: %s\n", t.getMessage());
-                }
-            }
-
-            public void warning(String warningFormat, Object... args) {
-                if (mSdkCommandLine.isVerbose()) {
-                    System.out.printf("Warning: " + warningFormat, args);
-                    if (!warningFormat.endsWith("\n")) {
-                        System.out.printf("\n");
-                    }
-                }
-            }
-
-            public void printf(String msgFormat, Object... args) {
-                System.out.printf(msgFormat, args);
-            }
-        };
-    }
-
-    /**
-     * Init the application by making sure the SDK path is available and
-     * doing basic parsing of the SDK.
-     */
-    private void init() {
-        mSdkCommandLine = new SdkCommandLine(mSdkLog);
-
-        // We get passed a property for the tools dir
-        String toolsDirProp = System.getProperty(TOOLSDIR);
-        if (toolsDirProp == null) {
-            // for debugging, it's easier to override using the process environment
-            toolsDirProp = System.getenv(TOOLSDIR);
-        }
-    
-        if (toolsDirProp != null) {
-            // got back a level for the SDK folder
-            File tools;
-            if (toolsDirProp.length() > 0) {
-                tools = new File(toolsDirProp);
-                mSdkFolder = tools.getParent();
-            } else {
-                try {
-                    tools = new File(".").getCanonicalFile();
-                    mSdkFolder = tools.getParent();
-                } catch (IOException e) {
-                    // Will print an error below since mSdkFolder is not defined
-                }
-            }
-        }
-
-        if (mSdkFolder == null) {
-            errorAndExit("The tools directory property is not set, please make sure you are executing %1$s",
-                SdkConstants.androidCmdName());
-        }
-        
-        // We might get passed a property for the working directory
-        // Either it is a valid directory and mWorkDir is set to it's absolute canonical value
-        // or mWorkDir remains null.
-        String workDirProp = System.getProperty(WORKDIR);
-        if (workDirProp == null) {
-            workDirProp = System.getenv(WORKDIR);
-        }
-        if (workDirProp != null) {
-            // This should be a valid directory
-            mWorkDir = new File(workDirProp);
-            try {
-                mWorkDir = mWorkDir.getCanonicalFile().getAbsoluteFile();
-            } catch (IOException e) {
-                mWorkDir = null;
-            }
-            if (mWorkDir == null || !mWorkDir.isDirectory()) {
-                errorAndExit("The working directory does not seem to be valid: '%1$s", workDirProp);
-            }
-        }
-    }
-
-    /**
-     * Does the basic SDK parsing required for all actions
-     */
-    private void parseSdk() {
-        mSdkManager = SdkManager.createManager(mSdkFolder, mSdkLog);
-        
-        if (mSdkManager == null) {
-            errorAndExit("Unable to parse SDK content.");
-        }
-    }
-    
-    /**
-     * Actually do an action...
-     */
-    private void doAction() {
-        String verb = mSdkCommandLine.getVerb();
-        String directObject = mSdkCommandLine.getDirectObject();
-        
-        if (SdkCommandLine.VERB_LIST.equals(verb)) {
-            // list action.
-            if (SdkCommandLine.OBJECT_TARGET.equals(directObject)) {
-                displayTargetList();
-            } else if (SdkCommandLine.OBJECT_AVD.equals(directObject)) {
-                displayAvdList();
-            } else {
-                displayTargetList();
-                displayAvdList();
-            }
-
-        } else if (SdkCommandLine.VERB_CREATE.equals(verb) &&
-                SdkCommandLine.OBJECT_AVD.equals(directObject)) {
-            createAvd();
-
-        } else if (SdkCommandLine.VERB_DELETE.equals(verb) &&
-                SdkCommandLine.OBJECT_AVD.equals(directObject)) {
-            deleteAvd();
-
-        } else if (SdkCommandLine.VERB_MOVE.equals(verb) &&
-                SdkCommandLine.OBJECT_AVD.equals(directObject)) {
-            moveAvd();
-
-        } else if (SdkCommandLine.VERB_CREATE.equals(verb) &&
-                SdkCommandLine.OBJECT_PROJECT.equals(directObject)) {
-            createProject();
-
-        } else if (SdkCommandLine.VERB_UPDATE.equals(verb) &&
-                SdkCommandLine.OBJECT_PROJECT.equals(directObject)) {
-            updateProject();
-        } else {
-            mSdkCommandLine.printHelpAndExit(null);
-        }
-    }
-
-    /**
-     * Creates a new Android project based on command-line parameters 
-     */
-    private void createProject() {
-        // get the target and try to resolve it.
-        int targetId = mSdkCommandLine.getParamTargetId();
-        IAndroidTarget[] targets = mSdkManager.getTargets();
-        if (targetId < 1 || targetId > targets.length) {
-            errorAndExit("Target id is not valid. Use '%s list targets' to get the target ids.",
-                    SdkConstants.androidCmdName());
-        }
-        IAndroidTarget target = targets[targetId - 1];
-        
-        ProjectCreator creator = new ProjectCreator(mSdkFolder,
-                mSdkCommandLine.isVerbose() ? OutputLevel.VERBOSE :
-                    mSdkCommandLine.isSilent() ? OutputLevel.SILENT :
-                        OutputLevel.NORMAL,
-                mSdkLog);
-
-        String projectDir = getProjectLocation(mSdkCommandLine.getParamLocationPath());
-        
-        creator.createProject(projectDir,
-                mSdkCommandLine.getParamName(),
-                mSdkCommandLine.getParamProjectPackage(),
-                mSdkCommandLine.getParamProjectActivity(),
-                target,
-                false /* isTestProject*/);
-    }
-
-    /**
-     * Updates an existing Android project based on command-line parameters 
-     */
-    private void updateProject() {
-        // get the target and try to resolve it.
-        IAndroidTarget target = null;
-        int targetId = mSdkCommandLine.getParamTargetId();
-        if (targetId >= 0) {
-            IAndroidTarget[] targets = mSdkManager.getTargets();
-            if (targetId < 1 || targetId > targets.length) {
-                errorAndExit("Target id is not valid. Use '%s list targets' to get the target ids.",
-                        SdkConstants.androidCmdName());
-            }
-            target = targets[targetId - 1];
-        }
-        
-        ProjectCreator creator = new ProjectCreator(mSdkFolder,
-                mSdkCommandLine.isVerbose() ? OutputLevel.VERBOSE :
-                    mSdkCommandLine.isSilent() ? OutputLevel.SILENT :
-                        OutputLevel.NORMAL,
-                mSdkLog);
-
-        String projectDir = getProjectLocation(mSdkCommandLine.getParamLocationPath());
-        
-        creator.updateProject(projectDir,
-                target,
-                mSdkCommandLine.getParamName());
-    }
-
-    /**
-     * Adjusts the project location to make it absolute & canonical relative to the
-     * working directory, if any.
-     * 
-     * @return The project absolute path relative to {@link #mWorkDir} or the original
-     *         newProjectLocation otherwise.
-     */
-    private String getProjectLocation(String newProjectLocation) {
-        
-        // If the new project location is absolute, use it as-is
-        File projectDir = new File(newProjectLocation);
-        if (projectDir.isAbsolute()) {
-            return newProjectLocation;
-        }
-
-        // if there's no working directory, just use the project location as-is.
-        if (mWorkDir == null) {
-            return newProjectLocation;
-        }
-
-        // Combine then and get an absolute canonical directory
-        try {
-            projectDir = new File(mWorkDir, newProjectLocation).getCanonicalFile();
-            
-            return projectDir.getPath();
-        } catch (IOException e) {
-            errorAndExit("Failed to combine working directory '%1$s' with project location '%2$s': %3$s",
-                    mWorkDir.getPath(),
-                    newProjectLocation,
-                    e.getMessage());
-            return null;
-        }
-    }
-
-    /**
-     * Displays the list of available Targets (Platforms and Add-ons)
-     */
-    private void displayTargetList() {
-        mSdkLog.printf("Available Android targets:\n");
-
-        int index = 1;
-        for (IAndroidTarget target : mSdkManager.getTargets()) {
-            if (target.isPlatform()) {
-                mSdkLog.printf("[%d] %s\n", index, target.getName());
-                mSdkLog.printf("     API level: %d\n", target.getApiVersionNumber());
-            } else {
-                mSdkLog.printf("[%d] Add-on: %s\n", index, target.getName());
-                mSdkLog.printf("     Vendor: %s\n", target.getVendor());
-                if (target.getDescription() != null) {
-                    mSdkLog.printf("     Description: %s\n", target.getDescription());
-                }
-                mSdkLog.printf("     Based on Android %s (API level %d)\n",
-                        target.getApiVersionName(), target.getApiVersionNumber());
-                
-                // display the optional libraries.
-                IOptionalLibrary[] libraries = target.getOptionalLibraries();
-                if (libraries != null) {
-                    mSdkLog.printf("     Libraries:\n");
-                    for (IOptionalLibrary library : libraries) {
-                        mSdkLog.printf("     * %1$s (%2$s)\n",
-                                library.getName(), library.getJarName());
-                        mSdkLog.printf(String.format(
-                                "         %1$s\n", library.getDescription()));
-                    }
-                }
-            }
-
-            // get the target skins
-            displaySkinList(target, "     Skins: ");
-            
-            index++;
-        }
-    }
-
-    /**
-     * Displays the skins valid for the given target.
-     */
-    private void displaySkinList(IAndroidTarget target, String message) {
-        String[] skins = target.getSkins();
-        String defaultSkin = target.getDefaultSkin();
-        mSdkLog.printf(message);
-        if (skins != null) {
-            boolean first = true;
-            for (String skin : skins) {
-                if (first == false) {
-                    mSdkLog.printf(", ");
-                } else {
-                    first = false;
-                }
-                mSdkLog.printf(skin);
-                
-                if (skin.equals(defaultSkin)) {
-                    mSdkLog.printf(" (default)");
-                }
-            }
-            mSdkLog.printf("\n");
-        } else {
-            mSdkLog.printf("no skins.\n");
-        }
-    }
-    
-    /**
-     * Displays the list of available AVDs.
-     */
-    private void displayAvdList() {
-        try {
-            AvdManager avdManager = new AvdManager(mSdkManager, null /* sdklog */);
-
-            mSdkLog.printf("Available Android Virtual Devices:\n");
-
-            int index = 1;
-            for (AvdInfo info : avdManager.getAvds()) {
-                mSdkLog.printf("[%d] %s\n", index, info.getName());
-                mSdkLog.printf("      Path: %s\n", info.getPath());
-
-                // get the target of the AVD
-                IAndroidTarget target = info.getTarget();
-                if (target.isPlatform()) {
-                    mSdkLog.printf("    Target: %s (API level %d)\n", target.getName(),
-                            target.getApiVersionNumber());
-                } else {
-                    mSdkLog.printf("    Target: %s (%s)\n", target.getName(), target
-                            .getVendor());
-                    mSdkLog.printf("            Based on Android %s (API level %d)\n", target
-                            .getApiVersionName(), target.getApiVersionNumber());
-                }
-                
-                // display some extra values.
-                Map<String, String> properties = info.getProperties();
-                String skin = properties.get(AvdManager.AVD_INI_SKIN_NAME);
-                if (skin != null) {
-                    mSdkLog.printf("      Skin: %s\n", skin);
-                }
-                String sdcard = properties.get(AvdManager.AVD_INI_SDCARD_SIZE);
-                if (sdcard == null) {
-                    sdcard = properties.get(AvdManager.AVD_INI_SDCARD_PATH);
-                }
-                if (sdcard != null) {
-                    mSdkLog.printf("    Sdcard: %s\n", sdcard);
-                }
-
-                index++;
-            }
-        } catch (AndroidLocationException e) {
-            errorAndExit(e.getMessage());
-        }
-    }
-    
-    /**
-     * Creates a new AVD. This is a text based creation with command line prompt.
-     */
-    private void createAvd() {
-        // find a matching target
-        int targetId = mSdkCommandLine.getParamTargetId();
-        IAndroidTarget target = null;
-        
-        if (targetId >= 1 && targetId <= mSdkManager.getTargets().length) {
-            target = mSdkManager.getTargets()[targetId-1]; // target it is 1-based
-        } else {
-            errorAndExit("Target id is not valid. Use '%s list targets' to get the target ids.",
-                    SdkConstants.androidCmdName());
-        }
-
-        try {
-            boolean removePrevious = false;
-            AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog);
-
-            String avdName = mSdkCommandLine.getParamName();
-            AvdInfo info = avdManager.getAvd(avdName);
-            if (info != null) {
-                if (mSdkCommandLine.getFlagForce()) {
-                    removePrevious = true;
-                    mSdkLog.warning(
-                            "Android Virtual Device '%s' already exists and will be replaced.",
-                            avdName);
-                } else {
-                    errorAndExit("Android Virtual Device '%s' already exists.", avdName);
-                    return;
-                }
-            }
-
-            String paramFolderPath = mSdkCommandLine.getParamLocationPath();
-            File avdFolder = null;
-            if (paramFolderPath != null) {
-                avdFolder = new File(paramFolderPath);
-            } else {
-                avdFolder = new File(AndroidLocation.getFolder() + AndroidLocation.FOLDER_AVD,
-                        avdName + AvdManager.AVD_FOLDER_EXTENSION);
-            }
-
-            Map<String, String> hardwareConfig = null;
-            if (target.isPlatform()) {
-                try {
-                    hardwareConfig = promptForHardware(target);
-                } catch (IOException e) {
-                    errorAndExit(e.getMessage());
-                }
-            }
-
-            AvdInfo oldAvdInfo = null;
-            if (removePrevious) {
-                oldAvdInfo = avdManager.getAvd(avdName);
-            }
-            
-            // Validate skin is either default (empty) or NNNxMMM or a valid skin name.
-            String skin = mSdkCommandLine.getParamSkin();
-            if (skin != null && skin.length() == 0) {
-                skin = null;
-            }
-            if (skin != null) {
-                boolean valid = false;
-                // Is it a know skin name for this target?
-                for (String s : target.getSkins()) {
-                    if (skin.equalsIgnoreCase(s)) {
-                        skin = s;  // Make skin names case-insensitive.
-                        valid = true;
-                        break;
-                    }
-                }
-                
-                // Is it NNNxMMM?
-                if (!valid) {
-                    valid = skin.matches("[0-9]{2,}x[0-9]{2,}");
-                }
-
-                if (!valid) {
-                    displaySkinList(target, "Valid skins: ");
-                    errorAndExit("'%s' is not a valid skin name or size (NNNxMMM)", skin);
-                    return;
-                }
-            }
-            
-            AvdInfo newAvdInfo = avdManager.createAvd(avdFolder,
-                    avdName,
-                    target,
-                    skin,
-                    mSdkCommandLine.getParamSdCard(),
-                    hardwareConfig,
-                    removePrevious,
-                    mSdkLog);
-            
-            if (newAvdInfo != null && 
-                    oldAvdInfo != null &&
-                    !oldAvdInfo.getPath().equals(newAvdInfo.getPath())) {
-                mSdkLog.warning("Removing previous AVD directory at %s", oldAvdInfo.getPath());
-                // Remove the old data directory
-                File dir = new File(oldAvdInfo.getPath());
-                avdManager.recursiveDelete(dir);
-                dir.delete();
-                // Remove old avd info from manager
-                avdManager.removeAvd(oldAvdInfo);
-            }
-            
-        } catch (AndroidLocationException e) {
-            errorAndExit(e.getMessage());
-        }
-    }
-
-    /**
-     * Delete an AVD.
-     */
-    private void deleteAvd() {
-        try {
-            String avdName = mSdkCommandLine.getParamName();
-            AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog);
-            AvdInfo info = avdManager.getAvd(avdName);
-    
-            if (info == null) {
-                errorAndExit("There is no Android Virtual Device named '%s'.", avdName);
-                return;
-            }
-    
-            avdManager.deleteAvd(info, mSdkLog);
-        } catch (AndroidLocationException e) {
-            errorAndExit(e.getMessage());
-        }
-    }
-    
-    /**
-     * Move an AVD.
-     */
-    private void moveAvd() {
-        try {
-            String avdName = mSdkCommandLine.getParamName();
-            AvdManager avdManager = new AvdManager(mSdkManager, mSdkLog);
-            AvdInfo info = avdManager.getAvd(avdName);
-    
-            if (info == null) {
-                errorAndExit("There is no Android Virtual Device named '%s'.", avdName);
-                return;
-            }
-            
-            // This is a rename if there's a new name for the AVD
-            String newName = mSdkCommandLine.getParamMoveNewName();
-            if (newName != null && newName.equals(info.getName())) {
-                // same name, not actually a rename operation
-                newName = null;
-            }
-
-            // This is a move (of the data files) if there's a new location path
-            String paramFolderPath = mSdkCommandLine.getParamLocationPath();
-            if (paramFolderPath != null) {
-                // check if paths are the same. Use File methods to account for OS idiosyncrasies.
-                try {
-                    File f1 = new File(paramFolderPath).getCanonicalFile();
-                    File f2 = new File(info.getPath()).getCanonicalFile();
-                    if (f1.equals(f2)) {
-                        // same canonical path, so not actually a move
-                        paramFolderPath = null;
-                    }
-                } catch (IOException e) {
-                    // Fail to resolve canonical path. Fail now since a move operation might fail
-                    // later and be harder to recover from. 
-                    errorAndExit(e.getMessage());
-                    return;
-                }
-            }
-            
-            if (newName == null && paramFolderPath == null) {
-                mSdkLog.warning("Move operation aborted: same AVD name, same canonical data path");
-                return;
-            }
-            
-            // If a rename was requested and no data move was requested, check if the original
-            // data path is our default constructed from the AVD name. In this case we still want
-            // to rename that folder too.
-            if (newName != null && paramFolderPath == null) {
-                // Compute the original data path
-                File originalFolder = new File(
-                        AndroidLocation.getFolder() + AndroidLocation.FOLDER_AVD,
-                        info.getName() + AvdManager.AVD_FOLDER_EXTENSION);
-                if (originalFolder.equals(info.getPath())) {
-                    try {
-                        // The AVD is using the default data folder path based on the AVD name.
-                        // That folder needs to be adjusted to use the new name.
-                        File f = new File(AndroidLocation.getFolder() + AndroidLocation.FOLDER_AVD,
-                                     newName + AvdManager.AVD_FOLDER_EXTENSION);
-                        paramFolderPath = f.getCanonicalPath();
-                    } catch (IOException e) {
-                        // Fail to resolve canonical path. Fail now rather than later. 
-                        errorAndExit(e.getMessage());
-                    }
-                }
-            }
-            
-            // Check for conflicts
-            
-            if (newName != null && avdManager.getAvd(newName) != null) {
-                errorAndExit("There is already an AVD named '%s'.", newName);
-                return;
-            }
-            if (newName != null) {
-                if (avdManager.getAvd(newName) != null) {
-                    errorAndExit("There is already an AVD named '%s'.", newName);
-                    return;
-                }
-
-                File ini = info.getIniFile();
-                if (ini.equals(AvdInfo.getIniFile(newName))) {
-                    errorAndExit("The AVD file '%s' is in the way.", ini.getCanonicalPath());
-                    return;
-                }
-            }
-
-            if (paramFolderPath != null && new File(paramFolderPath).exists()) {
-                errorAndExit(
-                        "There is already a file or directory at '%s'.\nUse --path to specify a different data folder.",
-                        paramFolderPath);
-            }
-            
-            avdManager.moveAvd(info, newName, paramFolderPath, mSdkLog);
-        } catch (AndroidLocationException e) {
-            errorAndExit(e.getMessage());
-        } catch (IOException e) {
-            errorAndExit(e.getMessage());
-        }
-    }
-    
-    /**
-     * Prompts the user to setup a hardware config for a Platform-based AVD.
-     * @throws IOException 
-     */
-    private Map<String, String> promptForHardware(IAndroidTarget createTarget) throws IOException {
-        byte[] readLineBuffer = new byte[256];
-        String result;
-        String defaultAnswer = "no";
-        
-        mSdkLog.printf("%s is a basic Android platform.\n", createTarget.getName());
-        mSdkLog.printf("Do you wish to create a custom hardware profile [%s]",
-                defaultAnswer);
-        
-        result = readLine(readLineBuffer).trim();
-        // handle default:
-        if (result.length() == 0) {
-            result = defaultAnswer;
-        }
-
-        if (getBooleanReply(result) == false) {
-            // no custom config.
-            return null;
-        }
-        
-        mSdkLog.printf("\n"); // empty line
-        
-        // get the list of possible hardware properties
-        File hardwareDefs = new File (mSdkFolder + File.separator +
-                SdkConstants.OS_SDK_TOOLS_LIB_FOLDER, SdkConstants.FN_HARDWARE_INI);
-        List<HardwareProperty> list = HardwareProperties.parseHardwareDefinitions(hardwareDefs,
-                null /*sdkLog*/);
-        
-        HashMap<String, String> map = new HashMap<String, String>();
-        
-        for (int i = 0 ; i < list.size() ;) {
-            HardwareProperty property = list.get(i);
-
-            String description = property.getDescription();
-            if (description != null) {
-                mSdkLog.printf("%s: %s\n", property.getAbstract(), description);
-            } else {
-                mSdkLog.printf("%s\n", property.getAbstract());
-            }
-
-            String defaultValue = property.getDefault();
-            
-            if (defaultValue != null) {
-                mSdkLog.printf("%s [%s]:", property.getName(), defaultValue);
-            } else {
-                mSdkLog.printf("%s (%s):", property.getName(), property.getType());
-            }
-            
-            result = readLine(readLineBuffer);
-            if (result.length() == 0) {
-                if (defaultValue != null) {
-                    mSdkLog.printf("\n"); // empty line
-                    i++; // go to the next property if we have a valid default value.
-                         // if there's no default, we'll redo this property
-                }
-                continue;
-            }
-            
-            switch (property.getType()) {
-                case BOOLEAN:
-                    try {
-                        if (getBooleanReply(result)) {
-                            map.put(property.getName(), "yes");
-                            i++; // valid reply, move to next property
-                        } else {
-                            map.put(property.getName(), "no");
-                            i++; // valid reply, move to next property
-                        }
-                    } catch (IOException e) {
-                        // display error, and do not increment i to redo this property
-                        mSdkLog.printf("\n%s\n", e.getMessage());
-                    }
-                    break;
-                case INTEGER:
-                    try {
-                        Integer.parseInt(result);
-                        map.put(property.getName(), result);
-                        i++; // valid reply, move to next property
-                    } catch (NumberFormatException e) {
-                        // display error, and do not increment i to redo this property
-                        mSdkLog.printf("\n%s\n", e.getMessage());
-                    }
-                    break;
-                case DISKSIZE:
-                    // TODO check validity
-                    map.put(property.getName(), result);
-                    i++; // valid reply, move to next property
-                    break;
-            }
-            
-            mSdkLog.printf("\n"); // empty line
-        }
-
-        return map;
-    }
-    
-    /**
-     * Reads the line from the input stream.
-     * @param buffer
-     * @throws IOException
-     */
-    private String readLine(byte[] buffer) throws IOException {
-        int count = System.in.read(buffer);
-        
-        // is the input longer than the buffer?
-        if (count == buffer.length && buffer[count-1] != 10) {
-            // create a new temp buffer
-            byte[] tempBuffer = new byte[256];
-
-            // and read the rest
-            String secondHalf = readLine(tempBuffer);
-            
-            // return a concat of both
-            return new String(buffer, 0, count) + secondHalf;
-        }
-
-        // ignore end whitespace
-        while (count > 0 && (buffer[count-1] == '\r' || buffer[count-1] == '\n')) {
-            count--;
-        }
-        
-        return new String(buffer, 0, count);
-    }
-    
-    /**
-     * Returns the boolean value represented by the string.
-     * @throws IOException If the value is not a boolean string.
-     */
-    private boolean getBooleanReply(String reply) throws IOException {
-        
-        for (String valid : BOOLEAN_YES_REPLIES) {
-            if (valid.equalsIgnoreCase(reply)) {
-                return true;
-            }
-        }
-
-        for (String valid : BOOLEAN_NO_REPLIES) {
-            if (valid.equalsIgnoreCase(reply)) {
-                return false;
-            }
-        }
-
-        throw new IOException(String.format("%s is not a valid reply", reply));
-    }
-    
-    private void errorAndExit(String format, Object...args) {
-        mSdkLog.error(null, format, args);
-        System.exit(1);
-    }
-}
\ No newline at end of file
diff --git a/tools/sdkmanager/app/src/com/android/sdkmanager/SdkCommandLine.java b/tools/sdkmanager/app/src/com/android/sdkmanager/SdkCommandLine.java
deleted file mode 100644
index 34a69bd..0000000
--- a/tools/sdkmanager/app/src/com/android/sdkmanager/SdkCommandLine.java
+++ /dev/null
@@ -1,220 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkManager;
-
-
-/**
- * Specific command-line flags for the {@link SdkManager}.
- */
-public class SdkCommandLine extends CommandLineProcessor {
-
-    public final static String VERB_LIST   = "list";
-    public final static String VERB_CREATE = "create";
-    public final static String VERB_MOVE   = "move";
-    public final static String VERB_DELETE = "delete";
-    public final static String VERB_UPDATE = "update";
-
-    public static final String OBJECT_AVD      = "avd";
-    public static final String OBJECT_AVDS     = "avds";
-    public static final String OBJECT_TARGET   = "target";
-    public static final String OBJECT_TARGETS  = "targets";
-    public static final String OBJECT_PROJECT  = "project";
-
-    public static final String ARG_ALIAS    = "alias";
-    public static final String ARG_ACTIVITY = "activity";
-
-    public static final String KEY_ACTIVITY  = ARG_ACTIVITY;
-    public static final String KEY_PACKAGE   = "package";
-    public static final String KEY_MODE      = "mode";
-    public static final String KEY_TARGET_ID = OBJECT_TARGET;
-    public static final String KEY_NAME      = "name";
-    public static final String KEY_PATH      = "path";
-    public static final String KEY_FILTER    = "filter";
-    public static final String KEY_SKIN      = "skin";
-    public static final String KEY_SDCARD    = "sdcard";
-    public static final String KEY_FORCE     = "force";
-    public static final String KEY_RENAME    = "rename";
-
-    /**
-     * Action definitions for SdkManager command line.
-     * <p/>
-     * Each entry is a string array with:
-     * <ul>
-     * <li> the verb.
-     * <li> an object (use #NO_VERB_OBJECT if there's no object).
-     * <li> a description.
-     * <li> an alternate form for the object (e.g. plural).
-     * </ul>
-     */
-    private final static String[][] ACTIONS = {
-            { VERB_LIST, NO_VERB_OBJECT,
-                "Lists existing targets or virtual devices." },
-            { VERB_LIST, OBJECT_AVD,
-                "Lists existing Android Virtual Devices.",
-                OBJECT_AVDS },
-            { VERB_LIST, OBJECT_TARGET,
-                "Lists existing targets.",
-                OBJECT_TARGETS },
-    
-            { VERB_CREATE, OBJECT_AVD,
-                "Creates a new Android Virtual Device." },
-            { VERB_MOVE, OBJECT_AVD,
-                "Moves or renames an Android Virtual Device." },
-            { VERB_DELETE, OBJECT_AVD,
-                "Deletes an Android Virtual Device." },
-    
-            { VERB_CREATE, OBJECT_PROJECT,
-                "Creates a new Android Project." },
-            { VERB_UPDATE, OBJECT_PROJECT,
-                "Updates an Android Project (must have an AndroidManifest.xml)." },
-        };
-    
-    public SdkCommandLine(ISdkLog logger) {
-        super(logger, ACTIONS);
-
-        // --- create avd ---
-        
-        define(MODE.STRING, false, 
-                VERB_CREATE, OBJECT_AVD, "p", KEY_PATH,
-                "Location path of the directory where the new AVD will be created", null);
-        define(MODE.STRING, true, 
-                VERB_CREATE, OBJECT_AVD, "n", KEY_NAME,
-                "Name of the new AVD", null);
-        define(MODE.INTEGER, true, 
-                VERB_CREATE, OBJECT_AVD, "t", KEY_TARGET_ID,
-                "Target id of the new AVD", null);
-        define(MODE.STRING, false, 
-                VERB_CREATE, OBJECT_AVD, "s", KEY_SKIN,
-                "Skin of the new AVD", null);
-        define(MODE.STRING, false, 
-                VERB_CREATE, OBJECT_AVD, "c", KEY_SDCARD,
-                "Path to a shared SD card image, or size of a new sdcard for the new AVD", null);
-        define(MODE.BOOLEAN, false, 
-                VERB_CREATE, OBJECT_AVD, "f", KEY_FORCE,
-                "Force creation (override an existing AVD)", false);
-
-        // --- delete avd ---
-        
-        define(MODE.STRING, true, 
-                VERB_DELETE, OBJECT_AVD, "n", KEY_NAME,
-                "Name of the AVD to delete", null);
-
-        // --- move avd ---
-        
-        define(MODE.STRING, true, 
-                VERB_MOVE, OBJECT_AVD, "n", KEY_NAME,
-                "Name of the AVD to move or rename", null);
-        define(MODE.STRING, false, 
-                VERB_MOVE, OBJECT_AVD, "r", KEY_RENAME,
-                "New name of the AVD to rename", null);
-        define(MODE.STRING, false, 
-                VERB_MOVE, OBJECT_AVD, "p", KEY_PATH,
-                "New location path of the directory where to move the AVD", null);
-
-        // --- create project ---
-
-        define(MODE.ENUM, true, 
-                VERB_CREATE, OBJECT_PROJECT, "m", KEY_MODE,
-                "Project mode", new String[] { ARG_ACTIVITY, ARG_ALIAS });
-        define(MODE.STRING, true, 
-                VERB_CREATE, OBJECT_PROJECT,
-                "p", KEY_PATH,
-                "Location path of new project", null);
-        define(MODE.INTEGER, true, 
-                VERB_CREATE, OBJECT_PROJECT, "t", KEY_TARGET_ID,
-                "Target id of the new project", null);
-        define(MODE.STRING, true, 
-                VERB_CREATE, OBJECT_PROJECT, "k", KEY_PACKAGE,
-                "Package name", null);
-        define(MODE.STRING, true, 
-                VERB_CREATE, OBJECT_PROJECT, "a", KEY_ACTIVITY,
-                "Activity name", null);
-        define(MODE.STRING, false, 
-                VERB_CREATE, OBJECT_PROJECT, "n", KEY_NAME,
-                "Project name", null);
-
-        // --- update project ---
-
-        define(MODE.STRING, true, 
-                VERB_UPDATE, OBJECT_PROJECT,
-                "p", KEY_PATH,
-                "Location path of the project", null);
-        define(MODE.INTEGER, true, 
-                VERB_UPDATE, OBJECT_PROJECT,
-                "t", KEY_TARGET_ID,
-                "Target id to set for the project", -1);
-        define(MODE.STRING, false, 
-                VERB_UPDATE, OBJECT_PROJECT,
-                "n", KEY_NAME,
-                "Project name", null);
-    }
-    
-    // -- some helpers for generic action flags
-    
-    /** Helper to retrieve the --path value. */
-    public String getParamLocationPath() {
-        return ((String) getValue(null, null, KEY_PATH));
-    }
-    
-    /** Helper to retrieve the --target id value. */
-    public int getParamTargetId() {
-        return ((Integer) getValue(null, null, KEY_TARGET_ID)).intValue();
-    }
-
-    /** Helper to retrieve the --name value. */
-    public String getParamName() {
-        return ((String) getValue(null, null, KEY_NAME));
-    }
-    
-    /** Helper to retrieve the --skin value. */
-    public String getParamSkin() {
-        return ((String) getValue(null, null, KEY_SKIN));
-    }
-
-    /** Helper to retrieve the --sdcard value. */
-    public String getParamSdCard() {
-        return ((String) getValue(null, null, KEY_SDCARD));
-    }
-    
-    /** Helper to retrieve the --force flag. */
-    public boolean getFlagForce() {
-        return ((Boolean) getValue(null, null, KEY_FORCE)).booleanValue();
-    }
-
-    // -- some helpers for avd action flags
-
-    /** Helper to retrieve the --rename value for a move verb. */
-    public String getParamMoveNewName() {
-        return ((String) getValue(VERB_MOVE, null, KEY_RENAME));
-    }
-
-
-    // -- some helpers for project action flags
-    
-    /** Helper to retrieve the --package value. */
-    public String getParamProjectPackage() {
-        return ((String) getValue(null, OBJECT_PROJECT, KEY_PACKAGE));
-    }
-
-    /** Helper to retrieve the --activity for the new project action. */
-    public String getParamProjectActivity() {
-        return ((String) getValue(null, OBJECT_PROJECT, KEY_ACTIVITY));
-    }
-}
diff --git a/tools/sdkmanager/app/tests/com/android/sdkmanager/CommandLineProcessorTest.java b/tools/sdkmanager/app/tests/com/android/sdkmanager/CommandLineProcessorTest.java
deleted file mode 100644
index 918591b..0000000
--- a/tools/sdkmanager/app/tests/com/android/sdkmanager/CommandLineProcessorTest.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.sdklib.ISdkLog;
-
-import junit.framework.TestCase;
-
-
-public class CommandLineProcessorTest extends TestCase {
-
-    private MockStdLogger mLog;
-    
-    /**
-     * A mock version of the {@link CommandLineProcessor} class that does not
-     * exits and captures its stdout/stderr output.
-     */
-    public static class MockCommandLineProcessor extends CommandLineProcessor {
-        private boolean mExitCalled;
-        private boolean mHelpCalled;
-        private String mStdOut = "";
-        private String mStdErr = "";
-        
-        public MockCommandLineProcessor(ISdkLog logger) {
-            super(logger,
-                  new String[][] {
-                    { "verb1", "action1", "Some action" },
-                    { "verb1", "action2", "Another action" },
-            });
-            define(MODE.STRING, false /*mandatory*/,
-                    "verb1", "action1", "1", "first", "non-mandatory flag", null);
-            define(MODE.STRING, true /*mandatory*/,
-                    "verb1", "action1", "2", "second", "mandatory flag", null);
-        }
-        
-        @Override
-        public void printHelpAndExitForAction(String verb, String directObject,
-                String errorFormat, Object... args) {
-            mHelpCalled = true;
-            super.printHelpAndExitForAction(verb, directObject, errorFormat, args);
-        }
-        
-        @Override
-        protected void exit() {
-            mExitCalled = true;
-        }
-        
-        @Override
-        protected void stdout(String format, Object... args) {
-            String s = String.format(format, args);
-            mStdOut += s + "\n";
-            // don't call super to avoid printing stuff
-        }
-        
-        @Override
-        protected void stderr(String format, Object... args) {
-            String s = String.format(format, args);
-            mStdErr += s + "\n";
-            // don't call super to avoid printing stuff
-        }
-        
-        public boolean wasHelpCalled() {
-            return mHelpCalled;
-        }
-        
-        public boolean wasExitCalled() {
-            return mExitCalled;
-        }
-        
-        public String getStdOut() {
-            return mStdOut;
-        }
-        
-        public String getStdErr() {
-            return mStdErr;
-        }
-    }
-
-    @Override
-    protected void setUp() throws Exception {
-        mLog = new MockStdLogger();
-        super.setUp();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-    }
-
-    public final void testPrintHelpAndExit() {
-        MockCommandLineProcessor c = new MockCommandLineProcessor(mLog);        
-        assertFalse(c.wasExitCalled());
-        assertFalse(c.wasHelpCalled());
-        assertTrue(c.getStdOut().equals(""));
-        assertTrue(c.getStdErr().equals(""));
-        c.printHelpAndExit(null);
-        assertTrue(c.getStdOut().indexOf("-v") != -1);
-        assertTrue(c.getStdOut().indexOf("--verbose") != -1);
-        assertTrue(c.getStdErr().equals(""));
-        assertTrue(c.wasExitCalled());
-
-        c = new MockCommandLineProcessor(mLog);        
-        assertFalse(c.wasExitCalled());
-        assertTrue(c.getStdOut().equals(""));
-        assertTrue(c.getStdErr().indexOf("Missing parameter") == -1);
-
-        c.printHelpAndExit("Missing %s", "parameter");
-        assertTrue(c.wasExitCalled());
-        assertFalse(c.getStdOut().equals(""));
-        assertTrue(c.getStdErr().indexOf("Missing parameter") != -1);
-    }
-    
-    public final void testVerbose() {
-        MockCommandLineProcessor c = new MockCommandLineProcessor(mLog);        
-
-        assertFalse(c.isVerbose());
-        c.parseArgs(new String[] { "-v" });
-        assertTrue(c.isVerbose());
-        assertTrue(c.wasExitCalled());
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.getStdErr().indexOf("Missing verb name.") != -1);
-
-        c = new MockCommandLineProcessor(mLog);        
-        c.parseArgs(new String[] { "--verbose" });
-        assertTrue(c.isVerbose());
-        assertTrue(c.wasExitCalled());
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.getStdErr().indexOf("Missing verb name.") != -1);
-    }
-    
-    public final void testHelp() {
-        MockCommandLineProcessor c = new MockCommandLineProcessor(mLog);        
-
-        c.parseArgs(new String[] { "-h" });
-        assertTrue(c.wasExitCalled());
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.getStdErr().indexOf("Missing verb name.") == -1);
-
-        c = new MockCommandLineProcessor(mLog);        
-        c.parseArgs(new String[] { "--help" });
-        assertTrue(c.wasExitCalled());
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.getStdErr().indexOf("Missing verb name.") == -1);
-    }
-
-    public final void testMandatory() {
-        MockCommandLineProcessor c = new MockCommandLineProcessor(mLog);        
-
-        c.parseArgs(new String[] { "verb1", "action1", "-1", "value1", "-2", "value2" });
-        assertFalse(c.wasExitCalled());
-        assertFalse(c.wasHelpCalled());
-        assertEquals("", c.getStdErr());
-        assertEquals("value1", c.getValue("verb1", "action1", "first"));
-        assertEquals("value2", c.getValue("verb1", "action1", "second"));
-
-        c = new MockCommandLineProcessor(mLog);        
-        c.parseArgs(new String[] { "verb1", "action1", "-2", "value2" });
-        assertFalse(c.wasExitCalled());
-        assertFalse(c.wasHelpCalled());
-        assertEquals("", c.getStdErr());
-        assertEquals(null, c.getValue("verb1", "action1", "first"));
-        assertEquals("value2", c.getValue("verb1", "action1", "second"));
-
-        c = new MockCommandLineProcessor(mLog);        
-        c.parseArgs(new String[] { "verb1", "action1" });
-        assertTrue(c.wasExitCalled());
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.getStdErr().indexOf("must be defined") != -1);
-        assertEquals(null, c.getValue("verb1", "action1", "first"));
-        assertEquals(null, c.getValue("verb1", "action1", "second"));
-    }
-}
diff --git a/tools/sdkmanager/app/tests/com/android/sdkmanager/MockStdLogger.java b/tools/sdkmanager/app/tests/com/android/sdkmanager/MockStdLogger.java
deleted file mode 100644
index 961e88d..0000000
--- a/tools/sdkmanager/app/tests/com/android/sdkmanager/MockStdLogger.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * 
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.sdklib.ISdkLog;
-
-/**
- * 
- */
-public class MockStdLogger implements ISdkLog {
-
-    public void error(Throwable t, String errorFormat, Object... args) {
-        if (errorFormat != null) {
-            System.err.printf("Error: " + errorFormat, args);
-            if (!errorFormat.endsWith("\n")) {
-                System.err.printf("\n");
-            }
-        }
-        if (t != null) {
-            System.err.printf("Error: %s\n", t.getMessage());
-        }
-    }
-
-    public void warning(String warningFormat, Object... args) {
-        System.out.printf("Warning: " + warningFormat, args);
-        if (!warningFormat.endsWith("\n")) {
-            System.out.printf("\n");
-        }
-    }
-
-    public void printf(String msgFormat, Object... args) {
-        System.out.printf(msgFormat, args);
-    }
-}
diff --git a/tools/sdkmanager/app/tests/com/android/sdkmanager/SdkCommandLineTest.java b/tools/sdkmanager/app/tests/com/android/sdkmanager/SdkCommandLineTest.java
deleted file mode 100644
index 07a32e0..0000000
--- a/tools/sdkmanager/app/tests/com/android/sdkmanager/SdkCommandLineTest.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkmanager;
-
-import com.android.sdklib.ISdkLog;
-
-import junit.framework.TestCase;
-
-public class SdkCommandLineTest extends TestCase {
-
-    private MockStdLogger mLog;
-    
-    /**
-     * A mock version of the {@link SdkCommandLine} class that does not
-     * exits and discards its stdout/stderr output.
-     */
-    public static class MockSdkCommandLine extends SdkCommandLine {
-        private boolean mExitCalled;
-        private boolean mHelpCalled;
-        
-        public MockSdkCommandLine(ISdkLog logger) {
-            super(logger);
-        }
-
-        @Override
-        public void printHelpAndExitForAction(String verb, String directObject,
-                String errorFormat, Object... args) {
-            mHelpCalled = true;
-            super.printHelpAndExitForAction(verb, directObject, errorFormat, args);
-        }
-
-        @Override
-        protected void exit() {
-            mExitCalled = true;
-        }
-        
-        @Override
-        protected void stdout(String format, Object... args) {
-            // discard
-        }
-        
-        @Override
-        protected void stderr(String format, Object... args) {
-            // discard
-        }
-
-        public boolean wasExitCalled() {
-            return mExitCalled;
-        }
-        
-        public boolean wasHelpCalled() {
-            return mHelpCalled;
-        }
-    }
-
-    @Override
-    protected void setUp() throws Exception {
-        mLog = new MockStdLogger();
-        super.setUp();
-    }
-
-    @Override
-    protected void tearDown() throws Exception {
-        super.tearDown();
-    }
-
-    /** Test list */
-    public final void testList_Avd_Verbose() {
-        MockSdkCommandLine c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "-v", "list", "avd" });
-        assertFalse(c.wasHelpCalled());
-        assertFalse(c.wasExitCalled());
-        assertEquals("list", c.getVerb());
-        assertEquals("avd", c.getDirectObject());
-        assertTrue(c.isVerbose());
-    }
-
-    public final void testList_Target() {
-        MockSdkCommandLine c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "list", "target" });
-        assertFalse(c.wasHelpCalled());
-        assertFalse(c.wasExitCalled());
-        assertEquals("list", c.getVerb());
-        assertEquals("target", c.getDirectObject());
-        assertFalse(c.isVerbose());
-    }
-
-    public final void testList_None() {
-        MockSdkCommandLine c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "list" });
-        assertFalse(c.wasHelpCalled());
-        assertFalse(c.wasExitCalled());
-        assertEquals("list", c.getVerb());
-        assertEquals("", c.getDirectObject());
-        assertFalse(c.isVerbose());
-    }
-
-    public final void testList_Invalid() {
-        MockSdkCommandLine c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "list", "unknown" });
-        assertTrue(c.wasHelpCalled());
-        assertTrue(c.wasExitCalled());
-        assertEquals(null, c.getVerb());
-        assertEquals(null, c.getDirectObject());
-        assertFalse(c.isVerbose());
-    }
-
-    public final void testList_Plural() {
-        MockSdkCommandLine c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "list", "avds" });
-        assertFalse(c.wasHelpCalled());
-        assertFalse(c.wasExitCalled());
-        assertEquals("list", c.getVerb());
-        // we get the non-plural form
-        assertEquals("avd", c.getDirectObject());
-        assertFalse(c.isVerbose());
-
-        c = new MockSdkCommandLine(mLog);
-        c.parseArgs(new String[] { "list", "targets" });
-        assertFalse(c.wasHelpCalled());
-        assertFalse(c.wasExitCalled());
-        assertEquals("list", c.getVerb());
-        // we get the non-plural form
-        assertEquals("target", c.getDirectObject());
-        assertFalse(c.isVerbose());
-    }
-}
diff --git a/tools/sdkmanager/libs/Android.mk b/tools/sdkmanager/libs/Android.mk
deleted file mode 100644
index a934aa7..0000000
--- a/tools/sdkmanager/libs/Android.mk
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-SDKLIBS_LOCAL_DIR := $(call my-dir)
-include $(SDKLIBS_LOCAL_DIR)/sdklib/Android.mk
-include $(SDKLIBS_LOCAL_DIR)/sdkuilib/Android.mk
diff --git a/tools/sdkmanager/libs/sdklib/.classpath b/tools/sdkmanager/libs/sdklib/.classpath
deleted file mode 100644
index fc17a43..0000000
--- a/tools/sdkmanager/libs/sdklib/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/sdkmanager/libs/sdklib/.project b/tools/sdkmanager/libs/sdklib/.project
deleted file mode 100644
index 97a8578..0000000
--- a/tools/sdkmanager/libs/sdklib/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>SdkLib</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/sdkmanager/libs/sdklib/Android.mk b/tools/sdkmanager/libs/sdklib/Android.mk
deleted file mode 100644
index 509c573..0000000
--- a/tools/sdkmanager/libs/sdklib/Android.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-SDKLIB_LOCAL_DIR := $(call my-dir)
-include $(SDKLIB_LOCAL_DIR)/src/Android.mk
diff --git a/tools/sdkmanager/libs/sdklib/src/Android.mk b/tools/sdkmanager/libs/sdklib/src/Android.mk
deleted file mode 100644
index a059a46..0000000
--- a/tools/sdkmanager/libs/sdklib/src/Android.mk
+++ /dev/null
@@ -1,27 +0,0 @@
-#
-# Copyright (C) 2008 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-LOCAL_JAVA_LIBRARIES := \
-        androidprefs
-
-LOCAL_MODULE := sdklib
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/AddOnTarget.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/AddOnTarget.java
deleted file mode 100644
index 0a59107..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/AddOnTarget.java
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-import java.io.File;
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.Map;
-import java.util.Map.Entry;
-
-/**
- * Represents an add-on target in the SDK.
- * An add-on extends a standard {@link PlatformTarget}.
- */
-final class AddOnTarget implements IAndroidTarget {
-    /**
-     * String to compute hash for add-on targets.
-     * Format is vendor:name:apiVersion
-     * */
-    private final static String ADD_ON_FORMAT = "%s:%s:%d"; //$NON-NLS-1$
-    
-    private final static class OptionalLibrary implements IOptionalLibrary {
-        private final String mJarName;
-        private final String mJarPath;
-        private final String mName;
-        private final String mDescription;
-
-        OptionalLibrary(String jarName, String jarPath, String name, String description) {
-            mJarName = jarName;
-            mJarPath = jarPath;
-            mName = name;
-            mDescription = description;
-        }
-
-        public String getJarName() {
-            return mJarName;
-        }
-
-        public String getJarPath() {
-            return mJarPath;
-        }
-
-        public String getName() {
-            return mName;
-        }
-        
-        public String getDescription() {
-            return mDescription;
-        }
-    }
-    
-    private final String mLocation;
-    private final PlatformTarget mBasePlatform;
-    private final String mName;
-    private final String mVendor;
-    private final String mDescription;
-    private String[] mSkins;
-    private String mDefaultSkin;
-    private IOptionalLibrary[] mLibraries;
-
-    /**
-     * Creates a new add-on
-     * @param location the OS path location of the add-on
-     * @param name the name of the add-on
-     * @param vendor the vendor name of the add-on
-     * @param description the add-on description
-     * @param libMap A map containing the optional libraries. The map key is the fully-qualified
-     * library name. The value is a 2 string array with the .jar filename, and the description.
-     * @param basePlatform the platform the add-on is extending.
-     */
-    AddOnTarget(String location, String name, String vendor, String description,
-            Map<String, String[]> libMap, PlatformTarget basePlatform) {
-        if (location.endsWith(File.separator) == false) {
-            location = location + File.separator;
-        }
-
-        mLocation = location;
-        mName = name;
-        mVendor = vendor;
-        mDescription = description;
-        mBasePlatform = basePlatform;
-        
-        // handle the optional libraries.
-        if (libMap != null) {
-            mLibraries = new IOptionalLibrary[libMap.size()];
-            int index = 0;
-            for (Entry<String, String[]> entry : libMap.entrySet()) {
-                String jarFile = entry.getValue()[0];
-                String desc = entry.getValue()[1];
-                mLibraries[index++] = new OptionalLibrary(jarFile,
-                        mLocation + SdkConstants.OS_ADDON_LIBS_FOLDER + jarFile,
-                        entry.getKey(), desc);
-            }
-        }
-    }
-    
-    public String getLocation() {
-        return mLocation;
-    }
-    
-    public String getName() {
-        return mName;
-    }
-    
-    public String getVendor() {
-        return mVendor;
-    }
-    
-    public String getFullName() {
-        return String.format("%1$s (%2$s)", mName, mVendor);
-    }
-    
-    public String getDescription() {
-        return mDescription;
-    }
-
-    public String getApiVersionName() {
-        // this is always defined by the base platform
-        return mBasePlatform.getApiVersionName();
-    }
-
-    public int getApiVersionNumber() {
-        // this is always defined by the base platform
-        return mBasePlatform.getApiVersionNumber();
-    }
-    
-    public boolean isPlatform() {
-        return false;
-    }
-    
-    public IAndroidTarget getParent() {
-        return mBasePlatform;
-    }
-    
-    public String getPath(int pathId) {
-        switch (pathId) {
-            case IMAGES:
-                return mLocation + SdkConstants.OS_IMAGES_FOLDER;
-            case SKINS:
-                return mLocation + SdkConstants.OS_SKINS_FOLDER;
-            case DOCS:
-                return mLocation + SdkConstants.FD_DOCS + File.separator;
-            default :
-                return mBasePlatform.getPath(pathId);
-        }
-    }
-
-    public String[] getSkins() {
-        return mSkins;
-    }
-    
-    public String getDefaultSkin() {
-        return mDefaultSkin;
-    }
-
-    public IOptionalLibrary[] getOptionalLibraries() {
-        return mLibraries;
-    }
-    
-    public boolean isCompatibleBaseFor(IAndroidTarget target) {
-        // basic test
-        if (target == this) {
-            return true;
-        }
-
-        // if the receiver has no optional library, then anything with api version number >= to
-        // the receiver is compatible.
-        if (mLibraries.length == 0) {
-            return target.getApiVersionNumber() >= getApiVersionNumber();
-        }
-
-        // Otherwise, target is only compatible if the vendor and name are equals with the api
-        // number greater or equal (ie target is a newer version of this add-on).
-        if (target.isPlatform() == false) {
-            return (mVendor.equals(target.getVendor()) && mName.equals(target.getName()) &&
-                    target.getApiVersionNumber() >= getApiVersionNumber());
-        }
-
-        return false;
-    }
-    
-    public String hashString() {
-        return String.format(ADD_ON_FORMAT, mVendor, mName, mBasePlatform.getApiVersionNumber());
-    }
-    
-    @Override
-    public int hashCode() {
-        return hashString().hashCode();
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof AddOnTarget) {
-            AddOnTarget addon = (AddOnTarget)obj;
-            
-            return mVendor.equals(addon.mVendor) && mName.equals(addon.mName) &&
-                mBasePlatform.getApiVersionNumber() == addon.mBasePlatform.getApiVersionNumber();
-        }
-
-        return super.equals(obj);
-    }
-    
-    /*
-     * Always return +1 if the object we compare to is a platform.
-     * Otherwise, do vendor then name then api version comparison.
-     * (non-Javadoc)
-     * @see java.lang.Comparable#compareTo(java.lang.Object)
-     */
-    public int compareTo(IAndroidTarget target) {
-        if (target.isPlatform()) {
-            return +1;
-        }
-        
-        // vendor
-        int value = mVendor.compareTo(target.getVendor());
-
-        // name
-        if (value == 0) {
-            value = mName.compareTo(target.getName());
-        }
-        
-        // api version
-        if (value == 0) {
-            value = getApiVersionNumber() - target.getApiVersionNumber();
-        }
-        
-        return value;
-    }
-
-    
-    // ---- local methods.
-
-
-    public void setSkins(String[] skins, String defaultSkin) {
-        mDefaultSkin = defaultSkin;
-
-        // we mix the add-on and base platform skins
-        HashSet<String> skinSet = new HashSet<String>();
-        skinSet.addAll(Arrays.asList(skins));
-        skinSet.addAll(Arrays.asList(mBasePlatform.getSkins()));
-        
-        mSkins = skinSet.toArray(new String[skinSet.size()]);
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/IAndroidTarget.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/IAndroidTarget.java
deleted file mode 100644
index fa462bd..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/IAndroidTarget.java
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-
-/**
- * A version of Android that application can target when building. 
- */
-public interface IAndroidTarget extends Comparable<IAndroidTarget> {
-    
-    /** OS Path to the "android.jar" file. */
-    public static int ANDROID_JAR         = 1;
-    /** OS Path to the "framework.aidl" file. */
-    public static int ANDROID_AIDL        = 2;
-    /** OS Path to "images" folder which contains the emulator system images. */
-    public static int IMAGES              = 3;
-    /** OS Path to the "samples" folder which contains sample projects. */
-    public static int SAMPLES             = 4;
-    /** OS Path to the "skins" folder which contains the emulator skins. */ 
-    public static int SKINS               = 5;
-    /** OS Path to the "templates" folder which contains the templates for new projects. */
-    public static int TEMPLATES           = 6;
-    /** OS Path to the "data" folder which contains data & libraries for the SDK tools. */
-    public static int DATA                = 7;
-    /** OS Path to the "attrs.xml" file. */
-    public static int ATTRIBUTES          = 8;
-    /** OS Path to the "attrs_manifest.xml" file. */
-    public static int MANIFEST_ATTRIBUTES = 9;
-    /** OS Path to the "data/layoutlib.jar" library. */
-    public static int LAYOUT_LIB          = 10;
-    /** OS Path to the "data/res" folder. */
-    public static int RESOURCES           = 11;
-    /** OS Path to the "data/fonts" folder. */
-    public static int FONTS               = 12;
-    /** OS Path to the "data/widgets.txt" file. */
-    public static int WIDGETS             = 13;
-    /** OS Path to the "data/activity_actions.txt" file. */
-    public static int ACTIONS_ACTIVITY    = 14;
-    /** OS Path to the "data/broadcast_actions.txt" file. */
-    public static int ACTIONS_BROADCAST   = 15;
-    /** OS Path to the "data/service_actions.txt" file. */
-    public static int ACTIONS_SERVICE     = 16;
-    /** OS Path to the "data/categories.txt" file. */
-    public static int CATEGORIES          = 17;
-    /** OS Path to the "sources" folder. */
-    public static int SOURCES             = 18;
-    /** OS Path to the target specific docs */
-    public static int DOCS                = 19;
-    /** OS Path to the target's version of the aapt tool. */
-    public static int AAPT                = 20;
-    /** OS Path to the target's version of the aidl tool. */
-    public static int AIDL                = 21;
-    /** OS Path to the target's version of the dx too. */
-    public static int DX                  = 22;
-    /** OS Path to the target's version of the dx.jar file. */
-    public static int DX_JAR              = 23;
-    
-    public interface IOptionalLibrary {
-        String getName();
-        String getJarName();
-        String getJarPath();
-        String getDescription();
-    }
-
-    /**
-     * Returns the target location.
-     */
-    String getLocation();
-
-    /**
-     * Returns the name of the vendor of the target.
-     */
-    String getVendor();
-
-    /**
-     * Returns the name of the target.
-     */
-    String getName();
-    
-    /**
-     * Returns the full name of the target, possibly including vendor name.
-     */
-    String getFullName();
-    
-    /**
-     * Returns the description of the target.
-     */
-    String getDescription();
-    
-    /**
-     * Returns the api version as an integer.
-     */
-    int getApiVersionNumber();
-
-    /**
-     * Returns the platform version as a readable string.
-     */
-    String getApiVersionName();
-    
-    /**
-     * Returns true if the target is a standard Android platform.
-     */
-    boolean isPlatform();
-    
-    /**
-     * Returns the parent target. This is likely to only be non <code>null</code> if
-     * {@link #isPlatform()} returns <code>false</code>
-     */
-    IAndroidTarget getParent();
-    
-    /**
-     * Returns the path of a platform component.
-     * @param pathId the id representing the path to return. Any of the constants defined in the
-     * {@link IAndroidTarget} interface can be used.
-     */
-    String getPath(int pathId);
-    
-    /**
-     * Returns the available skins for this target.
-     */
-    String[] getSkins();
-    
-    /**
-     * Returns the default skin for this target.
-     */
-    String getDefaultSkin();
-    
-    /**
-     * Returns the available optional libraries for this target.
-     * @return an array of optional libraries or <code>null</code> if there is none.
-     */
-    IOptionalLibrary[] getOptionalLibraries();
-    
-    /**
-     * Returns whether the given target is compatible with the receiver.
-     * <p/>A target is considered compatible if applications developed for the receiver can run on
-     * the given target.
-     *
-     * @param target the IAndroidTarget to test.
-     */
-    boolean isCompatibleBaseFor(IAndroidTarget target);
-    
-    /**
-     * Returns a string able to uniquely identify a target.
-     * Typically the target will encode information such as api level, whether it's a platform
-     * or add-on, and if it's an add-on vendor and add-on name.
-     */
-    String hashString();
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/ISdkLog.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/ISdkLog.java
deleted file mode 100644
index 4894517..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/ISdkLog.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-import java.util.Formatter;
-
-/**
- * Interface used to display warnings/errors while parsing the SDK content.
- */
-public interface ISdkLog {
-    
-    /**
-     * Prints a warning message on stdout.
-     * <p/>
-     * Implementations should only display warnings in verbose mode.
-     * The message should be prefixed with "Warning:".
-     * 
-     * @param warningFormat is an optional error format. If non-null, it will be printed
-     *          using a {@link Formatter} with the provided arguments.
-     * @param args provides the arguments for warningFormat.
-     */
-    void warning(String warningFormat, Object... args);
-    
-    /**
-     * Prints an error message on stderr.
-     * <p/>
-     * Implementation should always display errors, independent of verbose mode.
-     * The message should be prefixed with "Error:".
-     * 
-     * @param t is an optional {@link Throwable} or {@link Exception}. If non-null, it's
-     *          message will be printed out.
-     * @param errorFormat is an optional error format. If non-null, it will be printed
-     *          using a {@link Formatter} with the provided arguments.
-     * @param args provides the arguments for errorFormat.
-     */
-    void error(Throwable t, String errorFormat, Object... args);
-    
-    /**
-     * Prints a message as-is on stdout.
-     * <p/>
-     * Implementation should always display errors, independent of verbose mode.
-     * No prefix is used, the message is printed as-is after formatting.
-     * 
-     * @param msgFormat is an optional error format. If non-null, it will be printed
-     *          using a {@link Formatter} with the provided arguments.
-     * @param args provides the arguments for msgFormat.
-     */
-    void printf(String msgFormat, Object... args);
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/PlatformTarget.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/PlatformTarget.java
deleted file mode 100644
index a3da70e..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/PlatformTarget.java
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-import java.io.File;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * Represents a platform target in the SDK. 
- */
-final class PlatformTarget implements IAndroidTarget {
-    /** String used to get a hash to the platform target */
-    private final static String PLATFORM_HASH = "android-%d";
-    
-    private final static String PLATFORM_VENDOR = "Android";
-    private final static String PLATFORM_NAME = "Android %s";
-
-    private final String mLocation;
-    private final String mName;
-    private final int mApiVersionNumber;
-    private final String mApiVersionName;
-    private final Map<String, String> mProperties;
-    private final Map<Integer, String> mPaths = new HashMap<Integer, String>();
-    private String[] mSkins;
-    
-    PlatformTarget(String location, Map<String, String> properties,
-            int apiNumber, String apiName) {
-        mName = String.format(PLATFORM_NAME, apiName);
-        if (location.endsWith(File.separator) == false) {
-            location = location + File.separator;
-        }
-        mLocation = location;
-        mProperties = Collections.unmodifiableMap(properties);
-        mApiVersionNumber = apiNumber;
-        mApiVersionName = apiName;
-        
-        // pre-build the path to the platform components
-        mPaths.put(ANDROID_JAR, mLocation + SdkConstants.FN_FRAMEWORK_LIBRARY);
-        mPaths.put(SOURCES, mLocation + SdkConstants.FD_ANDROID_SOURCES);
-        mPaths.put(ANDROID_AIDL, mLocation + SdkConstants.FN_FRAMEWORK_AIDL);
-        mPaths.put(IMAGES, mLocation + SdkConstants.OS_IMAGES_FOLDER);
-        mPaths.put(SAMPLES, mLocation + SdkConstants.OS_PLATFORM_SAMPLES_FOLDER);
-        mPaths.put(SKINS, mLocation + SdkConstants.OS_SKINS_FOLDER);
-        mPaths.put(TEMPLATES, mLocation + SdkConstants.OS_PLATFORM_TEMPLATES_FOLDER);
-        mPaths.put(DATA, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER);
-        mPaths.put(ATTRIBUTES, mLocation + SdkConstants.OS_PLATFORM_ATTRS_XML);
-        mPaths.put(MANIFEST_ATTRIBUTES, mLocation + SdkConstants.OS_PLATFORM_ATTRS_MANIFEST_XML);
-        mPaths.put(RESOURCES, mLocation + SdkConstants.OS_PLATFORM_RESOURCES_FOLDER);
-        mPaths.put(FONTS, mLocation + SdkConstants.OS_PLATFORM_FONTS_FOLDER);
-        mPaths.put(LAYOUT_LIB, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_LAYOUTLIB_JAR);
-        mPaths.put(WIDGETS, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_WIDGETS);
-        mPaths.put(ACTIONS_ACTIVITY, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_INTENT_ACTIONS_ACTIVITY);
-        mPaths.put(ACTIONS_BROADCAST, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_INTENT_ACTIONS_BROADCAST);
-        mPaths.put(ACTIONS_SERVICE, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_INTENT_ACTIONS_SERVICE);
-        mPaths.put(CATEGORIES, mLocation + SdkConstants.OS_PLATFORM_DATA_FOLDER +
-                SdkConstants.FN_INTENT_CATEGORIES);
-        mPaths.put(AAPT, mLocation + SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_AAPT);
-        mPaths.put(AIDL, mLocation + SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_AIDL);
-        mPaths.put(DX, mLocation + SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_DX);
-        mPaths.put(DX_JAR, mLocation + SdkConstants.OS_SDK_TOOLS_LIB_FOLDER +
-                SdkConstants.FN_DX_JAR);
-    }
-    
-    public String getLocation() {
-        return mLocation;
-    }
-    
-    /*
-     * (non-Javadoc)
-     * 
-     * For Platform, the vendor name is always "Android".
-     * 
-     * @see com.android.sdklib.IAndroidTarget#getVendor()
-     */
-    public String getVendor() {
-        return PLATFORM_VENDOR;
-    }
-
-    public String getName() {
-        return mName;
-    }
-    
-    public String getFullName() {
-        return mName;
-    }
-
-    /*
-     * (non-Javadoc)
-     * 
-     * Description for the Android platform is dynamically generated.
-     * 
-     * @see com.android.sdklib.IAndroidTarget#getDescription()
-     */
-    public String getDescription() {
-        return String.format("Standard Android platform %s", mApiVersionName);
-    }
-    
-    public int getApiVersionNumber(){
-        return mApiVersionNumber;
-    }
-    
-    public String getApiVersionName() {
-        return mApiVersionName;
-    }
-    
-    public boolean isPlatform() {
-        return true;
-    }
-    
-    public IAndroidTarget getParent() {
-        return null;
-    }
-    
-    public String getPath(int pathId) {
-        return mPaths.get(pathId);
-    }
-    
-    public String[] getSkins() {
-        return mSkins;
-    }
-    
-    public String getDefaultSkin() {
-        // at this time, this is the default skin for all the platform.
-        return "HVGA";
-    }
-
-    /*
-     * Always returns null, as a standard platforms have no optional libraries.
-     * 
-     * (non-Javadoc)
-     * @see com.android.sdklib.IAndroidTarget#getOptionalLibraries()
-     */
-    public IOptionalLibrary[] getOptionalLibraries() {
-        return null;
-    }
-    
-    public boolean isCompatibleBaseFor(IAndroidTarget target) {
-        // basic test
-        if (target == this) {
-            return true;
-        }
-
-        // target is compatible wit the receiver as long as its api version number is greater or
-        // equal.
-        return target.getApiVersionNumber() >= mApiVersionNumber;
-    }
-    
-    public String hashString() {
-        return String.format(PLATFORM_HASH, mApiVersionNumber);
-    }
-
-    @Override
-    public int hashCode() {
-        return hashString().hashCode();
-    }
-    
-    @Override
-    public boolean equals(Object obj) {
-        if (obj instanceof PlatformTarget) {
-            return mApiVersionNumber == ((PlatformTarget)obj).mApiVersionNumber;
-        }
-        
-        return super.equals(obj);
-    }
-
-    /*
-     * Always return -1 if the object we compare to is an addon.
-     * Otherwise, compare api level.
-     * (non-Javadoc)
-     * @see java.lang.Comparable#compareTo(java.lang.Object)
-     */
-    public int compareTo(IAndroidTarget target) {
-        if (target.isPlatform() == false) {
-            return -1;
-        }
-
-        return mApiVersionNumber - target.getApiVersionNumber();
-    }
-
-    // ---- platform only methods.
-    
-    public String getProperty(String name) {
-        return mProperties.get(name);
-    }
-    
-    public Map<String, String> getProperties() {
-        return mProperties; // mProperties is unmodifiable.
-    }
-
-    void setSkins(String[] skins) {
-        mSkins = skins;
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkConstants.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkConstants.java
deleted file mode 100644
index 87f9b56..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkConstants.java
+++ /dev/null
@@ -1,280 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-import java.io.File;
-
-/**
- * Constant definition class.<br>
- * <br>
- * Most constants have a prefix defining the content.
- * <ul>
- * <li><code>OS_</code> OS path constant. These paths are different depending on the platform.</li>
- * <li><code>FN_</code> File name constant.</li>
- * <li><code>FD_</code> Folder name constant.</li>
- * </ul>
- *
- */
-public final class SdkConstants {
-    public final static int PLATFORM_UNKNOWN = 0;
-    public final static int PLATFORM_LINUX = 1;
-    public final static int PLATFORM_WINDOWS = 2;
-    public final static int PLATFORM_DARWIN = 3;
-
-    /**
-     * Returns current platform, one of {@link #PLATFORM_WINDOWS}, {@link #PLATFORM_DARWIN},
-     * {@link #PLATFORM_LINUX} or {@link #PLATFORM_UNKNOWN}.
-     */
-    public final static int CURRENT_PLATFORM = currentPlatform();
-
-    
-    /** An SDK Project's AndroidManifest.xml file */
-    public static final String FN_ANDROID_MANIFEST_XML= "AndroidManifest.xml";
-    /** An SDK Project's build.xml file */
-    public final static String FN_BUILD_XML = "build.xml";
-
-    /** Name of the framework library, i.e. "android.jar" */
-    public static final String FN_FRAMEWORK_LIBRARY = "android.jar";
-    /** Name of the layout attributes, i.e. "attrs.xml" */
-    public static final String FN_ATTRS_XML = "attrs.xml";
-    /** Name of the layout attributes, i.e. "attrs_manifest.xml" */
-    public static final String FN_ATTRS_MANIFEST_XML = "attrs_manifest.xml";
-    /** framework aidl import file */
-    public static final String FN_FRAMEWORK_AIDL = "framework.aidl";
-    /** layoutlib.jar file */
-    public static final String FN_LAYOUTLIB_JAR = "layoutlib.jar";
-    /** widget list file */
-    public static final String FN_WIDGETS = "widgets.txt";
-    /** Intent activity actions list file */
-    public static final String FN_INTENT_ACTIONS_ACTIVITY = "activity_actions.txt";
-    /** Intent broadcast actions list file */
-    public static final String FN_INTENT_ACTIONS_BROADCAST = "broadcast_actions.txt";
-    /** Intent service actions list file */
-    public static final String FN_INTENT_ACTIONS_SERVICE = "service_actions.txt";
-    /** Intent category list file */
-    public static final String FN_INTENT_CATEGORIES = "categories.txt";
-
-    /** platform build property file */
-    public final static String FN_BUILD_PROP = "build.prop";
-    /** plugin properties file */
-    public final static String FN_PLUGIN_PROP = "plugin.prop";
-    /** add-on manifest file */
-    public final static String FN_MANIFEST_INI = "manifest.ini";
-    /** hardware properties definition file */
-    public final static String FN_HARDWARE_INI = "hardware-properties.ini";
-
-    /** Skin layout file */
-    public final static String FN_SKIN_LAYOUT = "layout";//$NON-NLS-1$
-
-    /** dex.jar file */
-    public static final String FN_DX_JAR = "dx.jar"; //$NON-NLS-1$
-
-    /** dx executable */
-    public final static String FN_DX = (CURRENT_PLATFORM == PLATFORM_WINDOWS) ?
-            "dx.bat" : "dx"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    /** aapt executable */
-    public final static String FN_AAPT = (CURRENT_PLATFORM == PLATFORM_WINDOWS) ?
-            "aapt.exe" : "aapt"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    /** aidl executable */
-    public final static String FN_AIDL = (CURRENT_PLATFORM == PLATFORM_WINDOWS) ?
-            "aidl.exe" : "aidl"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    /* Folder Names for Android Projects . */
-
-    /** Resources folder name, i.e. "res". */
-    public final static String FD_RESOURCES = "res"; //$NON-NLS-1$
-    /** Assets folder name, i.e. "assets" */
-    public final static String FD_ASSETS = "assets"; //$NON-NLS-1$
-    /** Default source folder name, i.e. "src" */
-    public final static String FD_SOURCES = "src"; //$NON-NLS-1$
-    /** Default native library folder name inside the project, i.e. "libs"
-     * While the folder inside the .apk is "lib", we call that one libs because
-     * that's what we use in ant for both .jar and .so and we need to make the 2 development ways
-     * compatible. */
-    public final static String FD_NATIVE_LIBS = "libs"; //$NON-NLS-1$
-    /** Native lib folder inside the APK: "lib" */
-    public final static String FD_APK_NATIVE_LIBS = "lib"; //$NON-NLS-1$
-    /** Default output folder name, i.e. "bin" */
-    public final static String FD_OUTPUT = "bin"; //$NON-NLS-1$
-    /** Default anim resource folder name, i.e. "anim" */
-    public final static String FD_ANIM = "anim"; //$NON-NLS-1$
-    /** Default color resource folder name, i.e. "color" */
-    public final static String FD_COLOR = "color"; //$NON-NLS-1$
-    /** Default drawable resource folder name, i.e. "drawable" */
-    public final static String FD_DRAWABLE = "drawable"; //$NON-NLS-1$
-    /** Default layout resource folder name, i.e. "layout" */
-    public final static String FD_LAYOUT = "layout"; //$NON-NLS-1$
-    /** Default menu resource folder name, i.e. "menu" */
-    public final static String FD_MENU = "menu"; //$NON-NLS-1$
-    /** Default values resource folder name, i.e. "values" */
-    public final static String FD_VALUES = "values"; //$NON-NLS-1$
-    /** Default xml resource folder name, i.e. "xml" */
-    public final static String FD_XML = "xml"; //$NON-NLS-1$
-    /** Default raw resource folder name, i.e. "raw" */
-    public final static String FD_RAW = "raw"; //$NON-NLS-1$
-
-    /* Folder Names for the Android SDK */
-    
-    /** Name of the SDK platforms folder. */
-    public final static String FD_PLATFORMS = "platforms";
-    /** Name of the SDK addons folder. */
-    public final static String FD_ADDONS = "add-ons";
-    /** Name of the SDK tools folder. */
-    public final static String FD_TOOLS = "tools";
-    /** Name of the SDK tools/lib folder. */
-    public final static String FD_LIB = "lib";
-    /** Name of the SDK docs folder. */
-    public final static String FD_DOCS = "docs";
-    /** Name of the SDK images folder. */
-    public final static String FD_IMAGES = "images";
-    /** Name of the SDK skins folder. */
-    public final static String FD_SKINS = "skins";
-    /** Name of the SDK samples folder. */
-    public final static String FD_SAMPLES = "samples";
-    /** Name of the SDK templates folder, i.e. "templates" */
-    public final static String FD_TEMPLATES = "templates";
-    /** Name of the SDK data folder, i.e. "data" */
-    public final static String FD_DATA = "data";
-    /** Name of the SDK resources folder, i.e. "res" */
-    public final static String FD_RES = "res";
-    /** Name of the SDK font folder, i.e. "fonts" */
-    public final static String FD_FONTS = "fonts";
-    /** Name of the android sources directory */
-    public static final String FD_ANDROID_SOURCES = "sources";
-    /** Name of the addon libs folder. */
-    public final static String FD_ADDON_LIBS = "libs";
-
-    /** Namespace for the resource XML, i.e. "http://schemas.android.com/apk/res/android" */
-    public final static String NS_RESOURCES = "http://schemas.android.com/apk/res/android";
-
-    /* Folder path relative to the SDK root */
-    /** Path of the documentation directory relative to the sdk folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_SDK_DOCS_FOLDER = FD_DOCS + File.separator;
-
-    /** Path of the tools directory relative to the sdk folder, or to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_SDK_TOOLS_FOLDER = FD_TOOLS + File.separator;
-
-    /** Path of the lib directory relative to the sdk folder, or to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_SDK_TOOLS_LIB_FOLDER =
-            OS_SDK_TOOLS_FOLDER + FD_LIB + File.separator;
-
-    /* Folder paths relative to a platform or add-on folder */
-    
-    /** Path of the images directory relative to a platform or addon folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_IMAGES_FOLDER = FD_IMAGES + File.separator;
-
-    /** Path of the skin directory relative to a platform or addon folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_SKINS_FOLDER = FD_SKINS + File.separator;
-
-    /* Folder paths relative to a Platform folder */
-
-    /** Path of the data directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_DATA_FOLDER = FD_DATA + File.separator;
-
-    /** Path of the samples directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_SAMPLES_FOLDER = FD_SAMPLES + File.separator;
-
-    /** Path of the resources directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_RESOURCES_FOLDER =
-            OS_PLATFORM_DATA_FOLDER + FD_RES + File.separator;
-
-    /** Path of the fonts directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_FONTS_FOLDER =
-            OS_PLATFORM_DATA_FOLDER + FD_FONTS + File.separator;
-
-    /** Path of the android source directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_SOURCES_FOLDER = FD_ANDROID_SOURCES + File.separator;
-
-    /** Path of the android templates directory relative to a platform folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_PLATFORM_TEMPLATES_FOLDER = FD_TEMPLATES + File.separator;
-
-    /** Path of the attrs.xml file relative to a platform folder. */
-    public final static String OS_PLATFORM_ATTRS_XML =
-            OS_PLATFORM_RESOURCES_FOLDER + FD_VALUES + File.separator + FN_ATTRS_XML;
-
-    /** Path of the attrs_manifest.xml file relative to a platform folder. */
-    public final static String OS_PLATFORM_ATTRS_MANIFEST_XML =
-            OS_PLATFORM_RESOURCES_FOLDER + FD_VALUES + File.separator + FN_ATTRS_MANIFEST_XML;
-
-    /** Path of the layoutlib.jar file relative to a platform folder. */
-    public final static String OS_PLATFORM_LAYOUTLIB_JAR =
-            OS_PLATFORM_DATA_FOLDER + FN_LAYOUTLIB_JAR;
-    
-    /* Folder paths relative to a addon folder */
-
-    /** Path of the images directory relative to a folder folder.
-     *  This is an OS path, ending with a separator. */
-    public final static String OS_ADDON_LIBS_FOLDER = FD_ADDON_LIBS + File.separator;
-    
-    
-    /** Skin default **/
-    public final static String SKIN_DEFAULT = "default";
-
-    /** Returns the appropriate name for the 'android' command, which is 'android.bat' for
-     * Windows and 'android' for all other platforms. */
-    public static String androidCmdName() {
-        String os = System.getProperty("os.name");
-        String cmd = "android";
-        if (os.startsWith("Windows")) {
-            cmd += ".bat";
-        }
-        return cmd;
-    }
-
-    /** Returns the appropriate name for the 'mksdcard' command, which is 'mksdcard.exe' for
-     * Windows and 'mkdsdcard' for all other platforms. */
-    public static String mkSdCardCmdName() {
-        String os = System.getProperty("os.name");
-        String cmd = "mksdcard";
-        if (os.startsWith("Windows")) {
-            cmd += ".exe";
-        }
-        return cmd;
-    }
-
-    /**
-     * Returns current platform
-     * 
-     * @return one of {@link #PLATFORM_WINDOWS}, {@link #PLATFORM_DARWIN},
-     * {@link #PLATFORM_LINUX} or {@link #PLATFORM_UNKNOWN}.
-     */
-    private static int currentPlatform() {
-        String os = System.getProperty("os.name");          //$NON-NLS-1$
-        if (os.startsWith("Mac OS")) {                      //$NON-NLS-1$
-            return PLATFORM_DARWIN;
-        } else if (os.startsWith("Windows")) {              //$NON-NLS-1$
-            return PLATFORM_WINDOWS;
-        } else if (os.startsWith("Linux")) {                //$NON-NLS-1$
-            return PLATFORM_LINUX;
-        }
-
-        return PLATFORM_UNKNOWN;
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkManager.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkManager.java
deleted file mode 100644
index 28227c6..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/SdkManager.java
+++ /dev/null
@@ -1,511 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * The SDK manager parses the SDK folder and gives access to the content.
- * @see PlatformTarget
- * @see AddOnTarget 
- */
-public final class SdkManager {
-    
-    public final static String PROP_VERSION_SDK = "ro.build.version.sdk";
-    public final static String PROP_VERSION_RELEASE = "ro.build.version.release";
-    
-    private final static String ADDON_NAME = "name";
-    private final static String ADDON_VENDOR = "vendor";
-    private final static String ADDON_API = "api";
-    private final static String ADDON_DESCRIPTION = "description";
-    private final static String ADDON_LIBRARIES = "libraries";
-    private final static String ADDON_DEFAULT_SKIN = "skin";
-    
-    private final static Pattern PATTERN_PROP = Pattern.compile(
-            "^([a-zA-Z0-9._-]+)\\s*=\\s*(.*)\\s*$");
-    
-    private final static Pattern PATTERN_LIB_DATA = Pattern.compile(
-            "^([a-zA-Z0-9._-]+\\.jar);(.*)$", Pattern.CASE_INSENSITIVE);
-    
-    /** List of items in the platform to check when parsing it. These paths are relative to the
-     * platform root folder. */
-    private final static String[] sPlatformContentList = new String[] {
-        SdkConstants.FN_FRAMEWORK_LIBRARY,
-        SdkConstants.FN_FRAMEWORK_AIDL,
-        SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_AAPT,
-        SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_AIDL,
-        SdkConstants.OS_SDK_TOOLS_FOLDER + SdkConstants.FN_DX,
-        SdkConstants.OS_SDK_TOOLS_LIB_FOLDER + SdkConstants.FN_DX_JAR,
-    };
-
-    /** the location of the SDK */
-    private final String mSdkLocation;
-    private IAndroidTarget[] mTargets;
-
-    /**
-     * Creates an {@link SdkManager} for a given sdk location.
-     * @param sdkLocation the location of the SDK.
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     * @return the created {@link SdkManager} or null if the location is not valid.
-     */
-    public static SdkManager createManager(String sdkLocation, ISdkLog log) {
-        try {
-            SdkManager manager = new SdkManager(sdkLocation);
-            ArrayList<IAndroidTarget> list = new ArrayList<IAndroidTarget>();
-            manager.loadPlatforms(list, log);
-            manager.loadAddOns(list, log);
-            
-            // sort the targets/add-ons
-            Collections.sort(list);
-            
-            manager.setTargets(list.toArray(new IAndroidTarget[list.size()]));
-            
-            return manager;
-        } catch (IllegalArgumentException e) {
-            if (log != null) {
-                log.error(e, "Error parsing the sdk.");
-            }
-        }
-        
-        return null;
-    }
-    
-    /**
-     * Returns the location of the SDK.
-     */
-    public String getLocation() {
-        return mSdkLocation;
-    }
-    
-    /**
-     * Returns the targets that are available in the SDK.
-     */
-    public IAndroidTarget[] getTargets() {
-        return mTargets;
-    }
-    
-    /**
-     * Returns a target from a hash that was generated by {@link IAndroidTarget#hashString()}.
-     * 
-     * @param hash the {@link IAndroidTarget} hash string.
-     * @return The matching {@link IAndroidTarget} or null.
-     */
-    public IAndroidTarget getTargetFromHashString(String hash) {
-        if (hash != null) {
-            for (IAndroidTarget target : mTargets) {
-                if (hash.equals(target.hashString())) {
-                    return target;
-                }
-            }
-        }
-
-        return null;
-    }
-
-
-    private SdkManager(String sdkLocation) {
-        mSdkLocation = sdkLocation;
-    }
-    
-    private void setTargets(IAndroidTarget[] targets) {
-        mTargets = targets;
-    }
-
-    /**
-     * Loads the Platforms from the SDK.
-     * @param list the list to fill with the platforms.
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     */
-    private void loadPlatforms(ArrayList<IAndroidTarget> list, ISdkLog log) {
-        File platformFolder = new File(mSdkLocation, SdkConstants.FD_PLATFORMS);
-        if (platformFolder.isDirectory()) {
-            File[] platforms  = platformFolder.listFiles();
-            
-            for (File platform : platforms) {
-                if (platform.isDirectory()) {
-                    PlatformTarget target = loadPlatform(platform, log);
-                    if (target != null) {
-                        list.add(target);
-                    }
-                } else if (log != null) {
-                    log.warning("Ignoring platform '%1$s', not a folder.", platform.getName());
-                }
-            }
-            
-            return;
-        }
-
-        String message = null;
-        if (platformFolder.exists() == false) {
-            message = "%s is missing.";
-        } else {
-            message = "%s is not a folder.";
-        }
-
-        throw new IllegalArgumentException(String.format(message,
-                platformFolder.getAbsolutePath()));
-    }
-
-    /**
-     * Loads a specific Platform at a given location.
-     * @param platform the location of the platform.
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     */
-    private PlatformTarget loadPlatform(File platform, ISdkLog log) {
-        File buildProp = new File(platform, SdkConstants.FN_BUILD_PROP);
-        
-        if (buildProp.isFile()) {
-            Map<String, String> map = parsePropertyFile(buildProp, log);
-            
-            if (map != null) {
-                // look for some specific values in the map.
-                try {
-                    String apiNumber = map.get(PROP_VERSION_SDK);
-                    String apiName = map.get(PROP_VERSION_RELEASE);
-                    if (apiNumber != null && apiName != null) {
-                        // api number and name looks valid, perform a few more checks
-                        if (checkPlatformContent(platform, log) == false) {
-                            return null;
-                        }
-                        // create the target.
-                        PlatformTarget target = new PlatformTarget(
-                                platform.getAbsolutePath(),
-                                map,
-                                Integer.parseInt(apiNumber),
-                                apiName);
-                        
-                        // need to parse the skins.
-                        String[] skins = parseSkinFolder(target.getPath(IAndroidTarget.SKINS));
-                        target.setSkins(skins);
-
-                        return target;
-                    }
-                } catch (NumberFormatException e) {
-                    // looks like apiNumber does not parse to a number.
-                    // Ignore this platform.
-                    if (log != null) {
-                        log.error(null,
-                                "Ignoring platform '%1$s': %2$s is not a valid number in %3$s.",
-                                platform.getName(), PROP_VERSION_SDK, SdkConstants.FN_BUILD_PROP);
-                    }
-                }
-            }
-        } else if (log != null) {
-            log.error(null, "Ignoring platform '%1$s': %2$s is missing.", platform.getName(),
-                    SdkConstants.FN_BUILD_PROP);
-        }
-        
-        return null;
-    }
-
-    /**
-     * Loads the Add-on from the SDK.
-     * @param list the list to fill with the add-ons.
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     */
-    private void loadAddOns(ArrayList<IAndroidTarget> list, ISdkLog log) {
-        File addonFolder = new File(mSdkLocation, SdkConstants.FD_ADDONS);
-        if (addonFolder.isDirectory()) {
-            File[] addons  = addonFolder.listFiles();
-            
-            for (File addon : addons) {
-                // Add-ons have to be folders. Ignore files and no need to warn about them.
-                if (addon.isDirectory()) {
-                    AddOnTarget target = loadAddon(addon, list, log);
-                    if (target != null) {
-                        list.add(target);
-                    }
-                }
-            }
-
-            return;
-        }
-
-        String message = null;
-        if (addonFolder.exists() == false) {
-            message = "%s is missing.";
-        } else {
-            message = "%s is not a folder.";
-        }
-
-        throw new IllegalArgumentException(String.format(message,
-                addonFolder.getAbsolutePath()));
-    }
-    
-    /**
-     * Loads a specific Add-on at a given location.
-     * @param addon the location of the addon.
-     * @param list 
-     * @param log 
-     */
-    private AddOnTarget loadAddon(File addon, ArrayList<IAndroidTarget> list, ISdkLog log) {
-        File addOnManifest = new File(addon, SdkConstants.FN_MANIFEST_INI);
-        
-        if (addOnManifest.isFile()) {
-            Map<String, String> propertyMap = parsePropertyFile(addOnManifest, log);
-            
-            if (propertyMap != null) {
-                // look for some specific values in the map.
-                // we require name, vendor, and api
-                String name = propertyMap.get(ADDON_NAME);
-                if (name == null) {
-                    displayAddonManifestError(log, addon.getName(), ADDON_NAME);
-                    return null;
-                }
-                
-                String vendor = propertyMap.get(ADDON_VENDOR);
-                if (vendor == null) {
-                    displayAddonManifestError(log, addon.getName(), ADDON_VENDOR);
-                    return null;
-                }
-
-                String api = propertyMap.get(ADDON_API);
-                PlatformTarget baseTarget = null;
-                if (api == null) {
-                    displayAddonManifestError(log, addon.getName(), ADDON_API);
-                    return null;
-                } else {
-                    try {
-                        int apiValue = Integer.parseInt(api);
-                        for (IAndroidTarget target : list) {
-                            if (target.isPlatform() &&
-                                    target.getApiVersionNumber() == apiValue) {
-                                baseTarget = (PlatformTarget)target;
-                                break;
-                            }
-                        }
-                        
-                        if (baseTarget == null) {
-                            if (log != null) {
-                                log.error(null,
-                                        "Ignoring add-on '%1$s': Unable to find base platform with API level %2$d",
-                                        addon.getName(), apiValue);
-                            }
-
-                            return null;
-                        }
-                    } catch (NumberFormatException e) {
-                        // looks like apiNumber does not parse to a number.
-                        // Ignore this add-on.
-                        if (log != null) {
-                            log.error(null,
-                                    "Ignoring add-on '%1$s': %2$s is not a valid number in %3$s.",
-                                    addon.getName(), ADDON_API, SdkConstants.FN_BUILD_PROP);
-                        }
-                        return null;
-                    }
-                }
-                
-                // get the optional description
-                String description = propertyMap.get(ADDON_DESCRIPTION);
-                
-                // get the optional libraries
-                String librariesValue = propertyMap.get(ADDON_LIBRARIES);
-                Map<String, String[]> libMap = null;
-                
-                if (librariesValue != null) {
-                    librariesValue = librariesValue.trim();
-                    if (librariesValue.length() > 0) {
-                        // split in the string into the libraries name
-                        String[] libraries = librariesValue.split(";");
-                        if (libraries.length > 0) {
-                            libMap = new HashMap<String, String[]>();
-                            for (String libName : libraries) {
-                                libName = libName.trim();
-
-                                // get the library data from the properties
-                                String libData = propertyMap.get(libName);
-                                
-                                if (libData != null) {
-                                    // split the jar file from the description
-                                    Matcher m = PATTERN_LIB_DATA.matcher(libData);
-                                    if (m.matches()) {
-                                        libMap.put(libName, new String[] {
-                                                m.group(1), m.group(2) });
-                                    } else if (log != null) {
-                                        log.error(null,
-                                                "Ignoring library '%1$s', property value has wrong format\n\t%2$s",
-                                                libName, libData);
-                                    }
-                                } else if (log != null) {
-                                    log.error(null,
-                                            "Ignoring library '%1$s', missing property value",
-                                            libName, libData);
-                                }
-                            }
-                        }
-                    }
-                }
-
-                AddOnTarget target = new AddOnTarget(addon.getAbsolutePath(), name, vendor,
-                        description, libMap, baseTarget);
-                
-                // need to parse the skins.
-                String[] skins = parseSkinFolder(target.getPath(IAndroidTarget.SKINS));
-                
-                // get the default skin, or take it from the base platform if needed.
-                String defaultSkin = propertyMap.get(ADDON_DEFAULT_SKIN);
-                
-                if (defaultSkin == null) {
-                    if (skins.length == 1) {
-                        defaultSkin = skins[1];
-                    } else {
-                        defaultSkin = baseTarget.getDefaultSkin();
-                    }
-                }
-                
-                target.setSkins(skins, defaultSkin);
-
-                return target;
-            }
-        } else if (log != null) {
-            log.error(null, "Ignoring add-on '%1$s': %2$s is missing.", addon.getName(),
-                    SdkConstants.FN_MANIFEST_INI);
-        }
-        
-        return null;
-    }
-    
-    private void displayAddonManifestError(ISdkLog log, String addonName, String valueName) {
-        if (log != null) {
-            log.error(null, "Ignoring add-on '%1$s': '%2$s' is missing from %3$s.",
-                    addonName, valueName, SdkConstants.FN_MANIFEST_INI);
-        }
-    }
-    
-    /**
-     * Checks the given platform has all the required files, and returns true if they are all
-     * present.
-     * <p/>This checks the presence of the following files: android.jar, framework.aidl, aapt(.exe),
-     * aidl(.exe), dx(.bat), and dx.jar
-     */
-    private boolean checkPlatformContent(File platform, ISdkLog log) {
-        for (String relativePath : sPlatformContentList) {
-            File f = new File(platform, relativePath);
-            if (f.exists() == false) {
-                log.error(null,
-                        "Ignoring platform '%1$s': %2$s is missing.",
-                        platform.getName(), relativePath);
-                return false;
-            }
-            
-        }
-        return true;
-    }
-
-    
-    /**
-     * Parses a property file and returns
-     * @param buildProp the property file to parse
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     * @return the map of (key,value) pairs, or null if the parsing failed.
-     */
-    public static Map<String, String> parsePropertyFile(File buildProp, ISdkLog log) {
-        FileInputStream fis = null;
-        BufferedReader reader = null;
-        try {
-            fis = new FileInputStream(buildProp);
-            reader = new BufferedReader(new InputStreamReader(fis));
-
-            String line = null;
-            Map<String, String> map = new HashMap<String, String>();
-            while ((line = reader.readLine()) != null) {
-                if (line.length() > 0 && line.charAt(0) != '#') {
-                    
-                    Matcher m = PATTERN_PROP.matcher(line);
-                    if (m.matches()) {
-                        map.put(m.group(1), m.group(2));
-                    } else {
-                        log.warning("Error parsing '%1$s': \"%2$s\" is not a valid syntax",
-                                buildProp.getAbsolutePath(), line);
-                        return null;
-                    }
-                }
-            }
-            
-            return map;
-        } catch (FileNotFoundException e) {
-            // this should not happen since we usually test the file existence before
-            // calling the method.
-            // Return null below.
-        } catch (IOException e) {
-            if (log != null) {
-                log.warning("Error parsing '%1$s': %2$s.", buildProp.getAbsolutePath(),
-                        e.getMessage());
-            }
-        } finally {
-            if (reader != null) {
-                try {
-                    reader.close();
-                } catch (IOException e) {
-                    // pass
-                }
-            }
-            if (fis != null) {
-                try {
-                    fis.close();
-                } catch (IOException e) {
-                    // pass
-                }
-            }
-        }
-
-        return null;
-    }
-    
-    /**
-     * Parses the skin folder and builds the skin list.
-     * @param osPath The path of the skin root folder.
-     */
-    private String[] parseSkinFolder(String osPath) {
-        File skinRootFolder = new File(osPath);
-
-        if (skinRootFolder.isDirectory()) {
-            ArrayList<String> skinList = new ArrayList<String>();
-
-            File[] files = skinRootFolder.listFiles();
-
-            for (File skinFolder : files) {
-                if (skinFolder.isDirectory()) {
-                    // check for layout file
-                    File layout = new File(skinFolder, SdkConstants.FN_SKIN_LAYOUT);
-
-                    if (layout.isFile()) {
-                        // for now we don't parse the content of the layout and
-                        // simply add the directory to the list.
-                        skinList.add(skinFolder.getName());
-                    }
-                }
-            }
-
-            return skinList.toArray(new String[skinList.size()]);
-        }
-        
-        return new String[0];
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/AvdManager.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/AvdManager.java
deleted file mode 100644
index b44cf01..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/AvdManager.java
+++ /dev/null
@@ -1,768 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib.avd;
-
-import com.android.prefs.AndroidLocation;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkConstants;
-import com.android.sdklib.SdkManager;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.FileWriter;
-import java.io.FilenameFilter;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Map.Entry;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-/**
- * Android Virtual Device Manager to manage AVDs.
- */
-public final class AvdManager {
-    
-    public static final String AVD_FOLDER_EXTENSION = ".avd";
-
-    private final static String AVD_INFO_PATH = "path";
-    private final static String AVD_INFO_TARGET = "target";
-    
-    public final static String AVD_INI_SKIN_PATH = "skin.path";
-    public final static String AVD_INI_SKIN_NAME = "skin.name";
-    public final static String AVD_INI_SDCARD_PATH = "sdcard.path";
-    public final static String AVD_INI_SDCARD_SIZE = "sdcard.size";
-    public final static String AVD_INI_IMAGES_1 = "image.sysdir.1";
-    public final static String AVD_INI_IMAGES_2 = "image.sysdir.2";
-
-    private final static String USERDATA_IMG = "userdata.img";
-    private final static String CONFIG_INI = "config.ini";
-    private final static String SDCARD_IMG = "sdcard.img";
-
-    private final static String INI_EXTENSION = ".ini";
-    private final static Pattern INI_NAME_PATTERN = Pattern.compile("(.+)\\" + INI_EXTENSION + "$",
-            Pattern.CASE_INSENSITIVE);
-
-    private final static Pattern SDCARD_SIZE_PATTERN = Pattern.compile("\\d+[MK]?");
-
-    /** An immutable structure describing an Android Virtual Device. */
-    public static final class AvdInfo {
-        private final String mName;
-        private final String mPath;
-        private final IAndroidTarget mTarget;
-        private final Map<String, String> mProperties;
-        
-        /** Creates a new AVD info. Valures are immutable. 
-         * @param properties */
-        public AvdInfo(String name, String path, IAndroidTarget target,
-                Map<String, String> properties) {
-            mName = name;
-            mPath = path;
-            mTarget = target;
-            mProperties = properties;
-        }
-
-        /** Returns the name of the AVD. */
-        public String getName() {
-            return mName;
-        }
-
-        /** Returns the path of the AVD data directory. */
-        public String getPath() {
-            return mPath;
-        }
-
-        /** Returns the target of the AVD. */
-        public IAndroidTarget getTarget() {
-            return mTarget;
-        }
-
-        /** 
-         * Helper method that returns the .ini {@link File} for a given AVD name. 
-         * @throws AndroidLocationException if there's a problem getting android root directory.
-         */
-        public static File getIniFile(String name) throws AndroidLocationException {
-            String avdRoot;
-            avdRoot = AndroidLocation.getFolder() + AndroidLocation.FOLDER_AVD;
-            return new File(avdRoot, name + INI_EXTENSION);
-        }
-        
-        /** 
-         * Returns the .ini {@link File} for this AVD. 
-         * @throws AndroidLocationException if there's a problem getting android root directory.
-         */
-        public File getIniFile() throws AndroidLocationException {
-            return getIniFile(mName);
-        }
-        
-        /**
-         * Returns a map of properties for the AVD.
-         */
-        public Map<String, String> getProperties() {
-            return mProperties;
-        }
-    }
-
-    private final ArrayList<AvdInfo> mAvdList = new ArrayList<AvdInfo>();
-    private ISdkLog mSdkLog;
-    private final SdkManager mSdk;
-
-    public AvdManager(SdkManager sdk, ISdkLog sdkLog) throws AndroidLocationException {
-        mSdk = sdk;
-        mSdkLog = sdkLog;
-        buildAvdList();
-    }
-
-    /**
-     * Returns the existing AVDs.
-     * @return a newly allocated array containing all the AVDs.
-     */
-    public AvdInfo[] getAvds() {
-        return mAvdList.toArray(new AvdInfo[mAvdList.size()]);
-    }
-
-    /**
-     * Returns the {@link AvdInfo} matching the given <var>name</var>.
-     * @return the matching AvdInfo or <code>null</code> if none were found.
-     */
-    public AvdInfo getAvd(String name) {
-        for (AvdInfo info : mAvdList) {
-            if (info.getName().equals(name)) {
-                return info;
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Creates a new AVD. It is expected that there is no existing AVD with this name already.
-     * @param avdFolder the data folder for the AVD. It will be created as needed.
-     * @param name the name of the AVD
-     * @param target the target of the AVD
-     * @param skinName the name of the skin. Can be null. Must have been verified by caller.
-     * @param sdcard the parameter value for the sdCard. Can be null. This is either a path to
-     * an existing sdcard image or a sdcard size (\d+, \d+K, \dM).
-     * @param hardwareConfig the hardware setup for the AVD
-     * @param removePrevious If true remove any previous files.
-     */
-    public AvdInfo createAvd(File avdFolder, String name, IAndroidTarget target,
-            String skinName, String sdcard, Map<String,String> hardwareConfig,
-            boolean removePrevious, ISdkLog log) {
-        
-        File iniFile = null;
-        boolean needCleanup = false;
-        try {
-            if (avdFolder.exists()) {
-                if (removePrevious) {
-                    // AVD already exists and removePrevious is set, try to remove the
-                    // directory's content first (but not the directory itself).
-                    recursiveDelete(avdFolder);
-                } else {
-                    // AVD shouldn't already exist if removePrevious is false.
-                    if (log != null) {
-                        log.error(null,
-                                "Folder %s is in the way. Use --force if you want to overwrite.",
-                                avdFolder.getAbsolutePath());
-                    }
-                    return null;
-                }
-            } else {
-                // create the AVD folder.
-                avdFolder.mkdir();
-            }
-
-            // actually write the ini file
-            iniFile = createAvdIniFile(name, avdFolder, target);
-
-            // writes the userdata.img in it.
-            String imagePath = target.getPath(IAndroidTarget.IMAGES);
-            File userdataSrc = new File(imagePath, USERDATA_IMG);
-            
-            if (userdataSrc.exists() == false && target.isPlatform() == false) {
-                imagePath = target.getParent().getPath(IAndroidTarget.IMAGES);
-                userdataSrc = new File(imagePath, USERDATA_IMG);
-            }
-            
-            if (userdataSrc.exists() == false) {
-                log.error(null, "Unable to find a '%1$s' file to copy into the AVD folder.",
-                        USERDATA_IMG);
-                needCleanup = true;
-                return null;
-            }
-            
-            FileInputStream fis = new FileInputStream(userdataSrc);
-            
-            File userdataDest = new File(avdFolder, USERDATA_IMG);
-            FileOutputStream fos = new FileOutputStream(userdataDest);
-            
-            byte[] buffer = new byte[4096];
-            int count;
-            while ((count = fis.read(buffer)) != -1) {
-                fos.write(buffer, 0, count);
-            }
-            
-            fos.close();
-            fis.close();
-            
-            // Config file.
-            HashMap<String, String> values = new HashMap<String, String>();
-
-            // First the image folders of the target itself
-            imagePath = getImageRelativePath(target, log);
-            if (imagePath == null) {
-                needCleanup = true;
-                return null;
-            }
-            
-            values.put(AVD_INI_IMAGES_1, imagePath);
-            
-            // If the target is an add-on we need to add the Platform image as a backup.
-            IAndroidTarget parent = target.getParent();
-            if (parent != null) {
-                imagePath = getImageRelativePath(parent, log);
-                if (imagePath == null) {
-                    needCleanup = true;
-                    return null;
-                }
-
-                values.put(AVD_INI_IMAGES_2, imagePath);
-            }
-            
-            
-            // Now the skin.
-            if (skinName == null) {
-                skinName = target.getDefaultSkin();
-            }
-
-            // get the path of the skin (relative to the SDK)
-            // assume skin name is valid
-            String skinPath = getSkinRelativePath(skinName, target, log);
-            if (skinPath == null) {
-                needCleanup = true;
-                return null;
-            }
-
-            values.put(AVD_INI_SKIN_PATH, skinPath);
-            values.put(AVD_INI_SKIN_NAME, skinName);
-
-            if (sdcard != null) {
-                File sdcardFile = new File(sdcard);
-                if (sdcardFile.isFile()) {
-                    // sdcard value is an external sdcard, so we put its path into the config.ini
-                    values.put(AVD_INI_SDCARD_PATH, sdcard);
-                } else {
-                    // Sdcard is possibly a size. In that case we create a file called 'sdcard.img'
-                    // in the AVD folder, and do not put any value in config.ini.
-                    
-                    // First, check that it matches the pattern for sdcard size
-                    Matcher m = SDCARD_SIZE_PATTERN.matcher(sdcard);
-                    if (m.matches()) {
-                        // create the sdcard.
-                        sdcardFile = new File(avdFolder, SDCARD_IMG);
-                        String path = sdcardFile.getAbsolutePath();
-                        
-                        // execute mksdcard with the proper parameters.
-                        File toolsFolder = new File(mSdk.getLocation(), SdkConstants.FD_TOOLS);
-                        File mkSdCard = new File(toolsFolder, SdkConstants.mkSdCardCmdName());
-                        
-                        if (mkSdCard.isFile() == false) {
-                            log.error(null, "'%1$s' is missing from the SDK tools folder.",
-                                    mkSdCard.getName());
-                            needCleanup = true;
-                            return null;
-                        }
-                        
-                        if (createSdCard(mkSdCard.getAbsolutePath(), sdcard, path, log) == false) {
-                            needCleanup = true;
-                            return null; // mksdcard output has already been displayed, no need to
-                                         // output anything else.
-                        }
-                        
-                        // add a property containing the size of the sdcard for display purpose
-                        // only when the dev does 'android list avd'
-                        values.put(AVD_INI_SDCARD_SIZE, sdcard);
-                    } else {
-                        log.error(null,
-                                "'%1$s' is not recognized as a valid sdcard value.\n" +
-                                "Value should be:\n" +
-                                "1. path to an sdcard.\n" +
-                                "2. size of the sdcard to create: <size>[K|M]",
-                                sdcard);
-                        needCleanup = true;
-                        return null;
-                    }
-                }
-            }
-
-            if (hardwareConfig != null) {
-                values.putAll(hardwareConfig);
-            }
-
-            File configIniFile = new File(avdFolder, CONFIG_INI);
-            createConfigIni(configIniFile, values);
-            
-            if (log != null) {
-                if (target.isPlatform()) {
-                    log.printf("Created AVD '%s' based on %s\n", name, target.getName());
-                } else {
-                    log.printf("Created AVD '%s' based on %s (%s)\n", name, target.getName(),
-                               target.getVendor());
-                }
-            }
-            
-            // create the AvdInfo object, and add it to the list
-            AvdInfo avdInfo = new AvdInfo(name, avdFolder.getAbsolutePath(), target, values);
-            
-            mAvdList.add(avdInfo);
-            
-            return avdInfo;
-        } catch (AndroidLocationException e) {
-            if (log != null) {
-                log.error(e, null);
-            }
-        } catch (IOException e) {
-            if (log != null) {
-                log.error(e, null);
-            }
-        } finally {
-            if (needCleanup) {
-                if (iniFile != null && iniFile.exists()) {
-                    iniFile.delete();
-                }
-                
-                recursiveDelete(avdFolder);
-                avdFolder.delete();
-            }
-        }
-        
-        return null;
-    }
-
-    /**
-     * Returns the path to the target images folder as a relative path to the SDK.
-     */
-    private String getImageRelativePath(IAndroidTarget target, ISdkLog log) {
-        String imageFullPath = target.getPath(IAndroidTarget.IMAGES);
-
-        // make this path relative to the SDK location
-        String sdkLocation = mSdk.getLocation();
-        if (imageFullPath.startsWith(sdkLocation) == false) {
-            // this really really should not happen.
-            log.error(null, "Target location is not inside the SDK.");
-            assert false;
-            return null;
-        }
-
-        imageFullPath = imageFullPath.substring(sdkLocation.length());
-        if (imageFullPath.charAt(0) == File.separatorChar) {
-            imageFullPath = imageFullPath.substring(1);
-        }
-        return imageFullPath;
-    }
-    
-    /**
-     * Returns the path to the skin, as a relative path to the SDK.
-     */
-    private String getSkinRelativePath(String skinName, IAndroidTarget target, ISdkLog log) {
-        // first look to see if the skin is in the target
-        
-        String path = target.getPath(IAndroidTarget.SKINS);
-        File skin = new File(path, skinName);
-        
-        if (skin.exists() == false && target.isPlatform() == false) {
-            target = target.getParent();
-
-            path = target.getPath(IAndroidTarget.SKINS);
-            skin = new File(path, skinName);
-        }
-        
-        // skin really does not exist!
-        if (skin.exists() == false) {
-            log.error(null, "Skin '%1$s' does not exist.", skinName);
-            return null;
-        }
-        
-        // get the skin path
-        path = skin.getAbsolutePath();
-
-        // make this path relative to the SDK location
-        String sdkLocation = mSdk.getLocation();
-        if (path.startsWith(sdkLocation) == false) {
-            // this really really should not happen.
-            log.error(null, "Target location is not inside the SDK.");
-            assert false;
-            return null;
-        }
-
-        path = path.substring(sdkLocation.length());
-        if (path.charAt(0) == File.separatorChar) {
-            path = path.substring(1);
-        }
-        return path;
-    }
-
-    /**
-     * Creates the ini file for an AVD.
-     * 
-     * @param name of the AVD.
-     * @param avdFolder path for the data folder of the AVD.
-     * @param target of the AVD.
-     * @throws AndroidLocationException if there's a problem getting android root directory.
-     * @throws IOException if {@link File#getAbsolutePath()} fails.
-     */
-    private File createAvdIniFile(String name, File avdFolder, IAndroidTarget target)
-            throws AndroidLocationException, IOException {
-        HashMap<String, String> values = new HashMap<String, String>();
-        File iniFile = AvdInfo.getIniFile(name);
-        values.put(AVD_INFO_PATH, avdFolder.getAbsolutePath());
-        values.put(AVD_INFO_TARGET, target.hashString());
-        createConfigIni(iniFile, values);
-        
-        return iniFile;
-    }
-    
-    /**
-     * Creates the ini file for an AVD.
-     * 
-     * @param info of the AVD.
-     * @throws AndroidLocationException if there's a problem getting android root directory.
-     * @throws IOException if {@link File#getAbsolutePath()} fails.
-     */
-    private File createAvdIniFile(AvdInfo info) throws AndroidLocationException, IOException {
-        return createAvdIniFile(info.getName(), new File(info.getPath()), info.getTarget());
-    }
-
-    /**
-     * Actually deletes the files of an existing AVD.
-     * <p/>
-     * This also remove it from the manager's list, The caller does not need to
-     * call {@link #removeAvd(AvdInfo)} afterwards.
-     * 
-     * @param avdInfo the information on the AVD to delete
-     */
-    public void deleteAvd(AvdInfo avdInfo, ISdkLog log) {
-        try {
-            File f = avdInfo.getIniFile();
-            if (f.exists()) {
-                log.warning("Deleting file %s", f.getCanonicalPath());
-                if (!f.delete()) {
-                    log.error(null, "Failed to delete %s", f.getCanonicalPath());
-                }
-            }
-            
-            f = new File(avdInfo.getPath());
-            if (f.exists()) {
-                log.warning("Deleting folder %s", f.getCanonicalPath());
-                recursiveDelete(f);
-                if (!f.delete()) {
-                    log.error(null, "Failed to delete %s", f.getCanonicalPath());
-                }
-            }
-
-            removeAvd(avdInfo);
-        } catch (AndroidLocationException e) {
-            log.error(e, null);
-        } catch (IOException e) {
-            log.error(e, null);
-        }
-    }
-    
-    /**
-     * Moves and/or rename an existing AVD and its files.
-     * This also change it in the manager's list.
-     * <p/>
-     * The caller should make sure the name or path given are valid, do not exist and are
-     * actually different than current values.
-     * 
-     * @param avdInfo the information on the AVD to move.
-     * @param newName the new name of the AVD if non null.
-     * @param paramFolderPath the new data folder if non null.
-     * @return True if the move succeeded or there was nothing to do.
-     *         If false, this method will have had already output error in the log. 
-     */
-    public boolean moveAvd(AvdInfo avdInfo, String newName, String paramFolderPath, ISdkLog log) {
-        
-        try {
-            if (paramFolderPath != null) {
-                File f = new File(avdInfo.getPath());
-                log.warning("Moving '%s' to '%s'.", avdInfo.getPath(), paramFolderPath);
-                if (!f.renameTo(new File(paramFolderPath))) {
-                    log.error(null, "Failed to move '%s' to '%s'.",
-                            avdInfo.getPath(), paramFolderPath);
-                    return false;
-                }
-    
-                // update avd info
-                AvdInfo info = new AvdInfo(avdInfo.getName(), paramFolderPath, avdInfo.getTarget(),
-                        avdInfo.getProperties());
-                mAvdList.remove(avdInfo);
-                mAvdList.add(info);
-                avdInfo = info;
-
-                // update the ini file
-                createAvdIniFile(avdInfo);
-            }
-
-            if (newName != null) {
-                File oldIniFile = avdInfo.getIniFile();
-                File newIniFile = AvdInfo.getIniFile(newName);
-                
-                log.warning("Moving '%s' to '%s'.", oldIniFile.getPath(), newIniFile.getPath());
-                if (!oldIniFile.renameTo(newIniFile)) {
-                    log.error(null, "Failed to move '%s' to '%s'.", 
-                            oldIniFile.getPath(), newIniFile.getPath());
-                    return false;
-                }
-
-                // update avd info
-                AvdInfo info = new AvdInfo(newName, avdInfo.getPath(), avdInfo.getTarget(),
-                        avdInfo.getProperties());
-                mAvdList.remove(avdInfo);
-                mAvdList.add(info);
-            }
-        } catch (AndroidLocationException e) {
-            log.error(e, null);
-        } catch (IOException e) {
-            log.error(e, null);
-        }
-
-        // nothing to do or succeeded
-        return true;
-    }
-
-    /**
-     * Helper method to recursively delete a folder's content (but not the folder itself).
-     * 
-     * @throws SecurityException like {@link File#delete()} does if file/folder is not writable.
-     */
-    public void recursiveDelete(File folder) {
-        for (File f : folder.listFiles()) {
-            if (f.isDirectory()) {
-                recursiveDelete(folder);
-            }
-            f.delete();
-        }
-    }
-
-    private void buildAvdList() throws AndroidLocationException {
-        // get the Android prefs location.
-        String avdRoot = AndroidLocation.getFolder() + AndroidLocation.FOLDER_AVD;
-        
-        // ensure folder validity.
-        File folder = new File(avdRoot);
-        if (folder.isFile()) {
-            throw new AndroidLocationException(String.format("%s is not a valid folder.", avdRoot));
-        } else if (folder.exists() == false) {
-            // folder is not there, we create it and return
-            folder.mkdirs();
-            return;
-        }
-        
-        File[] avds = folder.listFiles(new FilenameFilter() {
-            public boolean accept(File parent, String name) {
-                if (INI_NAME_PATTERN.matcher(name).matches()) {
-                    // check it's a file and not a folder
-                    return new File(parent, name).isFile();
-                }
-
-                return false;
-            }
-        });
-        
-        for (File avd : avds) {
-            AvdInfo info = parseAvdInfo(avd);
-            if (info != null) {
-                mAvdList.add(info);
-            }
-        }
-    }
-    
-    private AvdInfo parseAvdInfo(File path) {
-        Map<String, String> map = SdkManager.parsePropertyFile(path, mSdkLog);
-        
-        String avdPath = map.get(AVD_INFO_PATH);
-        if (avdPath == null) {
-            return null;
-        }
-        
-        String targetHash = map.get(AVD_INFO_TARGET);
-        if (targetHash == null) {
-            return null;
-        }
-
-        IAndroidTarget target = mSdk.getTargetFromHashString(targetHash);
-        if (target == null) {
-            return null;
-        }
-        
-        // load the avd properties.
-        File configIniFile = new File(avdPath, CONFIG_INI);
-        Map<String, String> properties = SdkManager.parsePropertyFile(configIniFile, mSdkLog);
-
-        Matcher matcher = INI_NAME_PATTERN.matcher(path.getName());
-
-        AvdInfo info = new AvdInfo(
-                matcher.matches() ? matcher.group(1) : path.getName(), // should not happen
-                avdPath,
-                target,
-                properties);
-        
-        return info;
-    }
-
-    private static void createConfigIni(File iniFile, Map<String, String> values)
-            throws IOException {
-        FileWriter writer = new FileWriter(iniFile);
-        
-        for (Entry<String, String> entry : values.entrySet()) {
-            writer.write(String.format("%s=%s\n", entry.getKey(), entry.getValue()));
-        }
-        writer.close();
-
-    }
-    
-    private boolean createSdCard(String toolLocation, String size, String location, ISdkLog log) {
-        try {
-            String[] command = new String[3];
-            command[0] = toolLocation;
-            command[1] = size;
-            command[2] = location;
-            Process process = Runtime.getRuntime().exec(command);
-    
-            ArrayList<String> errorOutput = new ArrayList<String>();
-            ArrayList<String> stdOutput = new ArrayList<String>();
-            int status = grabProcessOutput(process, errorOutput, stdOutput,
-                    true /* waitForReaders */);
-    
-            if (status != 0) {
-                log.error(null, "Failed to create the SD card.");
-                for (String error : errorOutput) {
-                    log.error(null, error);
-                }
-                
-                return false;
-            }
-
-            return true;
-        } catch (InterruptedException e) {
-            log.error(null, "Failed to create the SD card.");
-        } catch (IOException e) {
-            log.error(null, "Failed to create the SD card.");
-        }
-        
-        return false;
-    }
-    
-    /**
-     * Gets the stderr/stdout outputs of a process and returns when the process is done.
-     * Both <b>must</b> be read or the process will block on windows.
-     * @param process The process to get the ouput from
-     * @param errorOutput The array to store the stderr output. cannot be null.
-     * @param stdOutput The array to store the stdout output. cannot be null.
-     * @param waitforReaders if true, this will wait for the reader threads. 
-     * @return the process return code.
-     * @throws InterruptedException
-     */
-    private int grabProcessOutput(final Process process, final ArrayList<String> errorOutput,
-            final ArrayList<String> stdOutput, boolean waitforReaders)
-            throws InterruptedException {
-        assert errorOutput != null;
-        assert stdOutput != null;
-        // read the lines as they come. if null is returned, it's
-        // because the process finished
-        Thread t1 = new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                // create a buffer to read the stderr output
-                InputStreamReader is = new InputStreamReader(process.getErrorStream());
-                BufferedReader errReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = errReader.readLine();
-                        if (line != null) {
-                            errorOutput.add(line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        Thread t2 = new Thread("") { //$NON-NLS-1$
-            @Override
-            public void run() {
-                InputStreamReader is = new InputStreamReader(process.getInputStream());
-                BufferedReader outReader = new BufferedReader(is);
-
-                try {
-                    while (true) {
-                        String line = outReader.readLine();
-                        if (line != null) {
-                            stdOutput.add(line);
-                        } else {
-                            break;
-                        }
-                    }
-                } catch (IOException e) {
-                    // do nothing.
-                }
-            }
-        };
-
-        t1.start();
-        t2.start();
-
-        // it looks like on windows process#waitFor() can return
-        // before the thread have filled the arrays, so we wait for both threads and the
-        // process itself.
-        if (waitforReaders) {
-            try {
-                t1.join();
-            } catch (InterruptedException e) {
-            }
-            try {
-                t2.join();
-            } catch (InterruptedException e) {
-            }
-        }
-
-        // get the return code from the process
-        return process.waitFor();
-    }
-
-    /**
-     * Removes an {@link AvdInfo} from the internal list.
-     * 
-     * @param avdInfo The {@link AvdInfo} to remove.
-     * @return true if this {@link AvdInfo} was present and has been removed.
-     */
-    public boolean removeAvd(AvdInfo avdInfo) {
-        return mAvdList.remove(avdInfo);
-    }
-
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/HardwareProperties.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/HardwareProperties.java
deleted file mode 100644
index ed5b949..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/avd/HardwareProperties.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib.avd;
-
-import com.android.sdklib.ISdkLog;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-public class HardwareProperties {
-    private final static Pattern PATTERN_PROP = Pattern.compile(
-    "^([a-zA-Z0-9._-]+)\\s*=\\s*(.*)\\s*$");
-    
-    private final static String HW_PROP_NAME = "name";
-    private final static String HW_PROP_TYPE = "type";
-    private final static String HW_PROP_DEFAULT = "default";
-    private final static String HW_PROP_ABSTRACT = "abstract";
-    private final static String HW_PROP_DESC = "description";
-    
-    public enum ValueType {
-        INTEGER("integer"),
-        BOOLEAN("boolean"),
-        DISKSIZE("diskSize");
-        
-        private String mValue;
-
-        ValueType(String value) {
-            mValue = value;
-        }
-        
-        public static ValueType getEnum(String value) {
-            for (ValueType type : values()) {
-                if (type.mValue.equals(value)) {
-                    return type;
-                }
-            }
-            
-            return null;
-        }
-    }
-    
-    public static final class HardwareProperty {
-        private String mName;
-        private ValueType mType;
-        /** the string representation of the default value. can be null. */
-        private String mDefault;
-        private String mAbstract;
-        private String mDescription;
-        
-        public String getName() {
-            return mName;
-        }
-        
-        public ValueType getType() {
-            return mType;
-        }
-        
-        public String getDefault() {
-            return mDefault;
-        }
-        
-        public String getAbstract() {
-            return mAbstract;
-        }
-        
-        public String getDescription() {
-            return mDescription;
-        }
-    }
-    
-    /**
-     * Parses the hardware definition file.
-     * @param file the property file to parse
-     * @param log the ISdkLog object receiving warning/error from the parsing.
-     * @return the map of (key,value) pairs, or null if the parsing failed.
-     */
-    public static List<HardwareProperty> parseHardwareDefinitions(File file, ISdkLog log) {
-        try {
-            FileInputStream fis = new FileInputStream(file);
-            BufferedReader reader = new BufferedReader(new InputStreamReader(fis));
-
-            List<HardwareProperty> map = new ArrayList<HardwareProperty>();
-
-            String line = null;
-            HardwareProperty prop = null;
-            while ((line = reader.readLine()) != null) {
-                if (line.length() > 0 && line.charAt(0) != '#') {
-                    Matcher m = PATTERN_PROP.matcher(line);
-                    if (m.matches()) {
-                        String valueName = m.group(1);
-                        String value = m.group(2);
-
-                        if (HW_PROP_NAME.equals(valueName)) {
-                            prop = new HardwareProperty();
-                            prop.mName = value;
-                            map.add(prop);
-                        }
-                        
-                        if (prop == null) {
-                            log.warning("Error parsing '%1$s': missing '%2$s'",
-                                    file.getAbsolutePath(), HW_PROP_NAME);
-                            return null;
-                        }
-                        
-                        if (HW_PROP_TYPE.equals(valueName)) {
-                            prop.mType = ValueType.getEnum(value);
-                        } else if (HW_PROP_DEFAULT.equals(valueName)) {
-                            prop.mDefault = value;
-                        } else if (HW_PROP_ABSTRACT.equals(valueName)) {
-                            prop.mAbstract = value;
-                        } else if (HW_PROP_DESC.equals(valueName)) {
-                            prop.mDescription = value;
-                        }
-                    } else {
-                        log.warning("Error parsing '%1$s': \"%2$s\" is not a valid syntax",
-                                file.getAbsolutePath(), line);
-                        return null;
-                    }
-                }
-            }
-            
-            return map;
-        } catch (FileNotFoundException e) {
-            // this should not happen since we usually test the file existence before
-            // calling the method.
-            // Return null below.
-        } catch (IOException e) {
-            if (log != null) {
-                log.warning("Error parsing '%1$s': %2$s.", file.getAbsolutePath(),
-                        e.getMessage());
-            }
-        }
-
-        return null;
-    }
-
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ApkConfigurationHelper.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ApkConfigurationHelper.java
deleted file mode 100644
index ab43f46..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ApkConfigurationHelper.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Copyright (C) 2009 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib.project;
-
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-/**
- * Helper class to read and write Apk Configuration into a {@link ProjectProperties} file.
- */
-public class ApkConfigurationHelper {
-
-    /**
-     * Reads the Apk Configurations from a {@link ProjectProperties} file and returns them as a map.
-     * <p/>If there are no defined configurations, the returned map will be empty.
-     */
-    public static Map<String, String> getConfigs(ProjectProperties properties) {
-        HashMap<String, String> configMap = new HashMap<String, String>();
-
-        // get the list of configs.
-        String configList = properties.getProperty(ProjectProperties.PROPERTY_CONFIGS);
-        if (configList != null) {
-            // this is a comma separated list
-            String[] configs = configList.split(","); //$NON-NLS-1$
-            
-            // read the value of each config and store it in a map
-            
-            for (String config : configs) {
-                String configValue = properties.getProperty(config);
-                if (configValue != null) {
-                    configMap.put(config, configValue);
-                }
-            }
-        }
-        
-        return configMap;
-    }
-    
-    /**
-     * Writes the Apk Configurations from a given map into a {@link ProjectProperties}.
-     * @return true if the {@link ProjectProperties} contained Apk Configuration that were not
-     * present in the map. 
-     */
-    public static boolean setConfigs(ProjectProperties properties, Map<String, String> configMap) {
-        // load the current configs, in order to remove the value properties for each of them
-        // in case a config was removed.
-        
-        // get the list of configs.
-        String configList = properties.getProperty(ProjectProperties.PROPERTY_CONFIGS);
-        
-        // this is a comma separated list
-        String[] configs = configList.split(","); //$NON-NLS-1$
-        
-        boolean hasRemovedConfig = false;
-        
-        for (String config : configs) {
-            if (configMap.containsKey(config) == false) {
-                hasRemovedConfig = true;
-                properties.removeProperty(config);
-            }
-        }
-        
-        // now add the properties.
-        Set<Entry<String, String>> entrySet = configMap.entrySet();
-        StringBuilder sb = new StringBuilder();
-        for (Entry<String, String> entry : entrySet) {
-            if (sb.length() > 0) {
-                sb.append(",");
-            }
-            sb.append(entry.getKey());
-            properties.setProperty(entry.getKey(), entry.getValue());
-        }
-        properties.setProperty(ProjectProperties.PROPERTY_CONFIGS, sb.toString());
-        
-        return hasRemovedConfig;
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectCreator.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectCreator.java
deleted file mode 100644
index 18e2ac9..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectCreator.java
+++ /dev/null
@@ -1,738 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib.project;
-
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.ISdkLog;
-import com.android.sdklib.SdkConstants;
-import com.android.sdklib.project.ProjectProperties.PropertyType;
-
-import org.w3c.dom.NodeList;
-import org.xml.sax.InputSource;
-
-import java.io.BufferedReader;
-import java.io.BufferedWriter;
-import java.io.File;
-import java.io.FileReader;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.regex.Pattern;
-
-import javax.xml.XMLConstants;
-import javax.xml.namespace.NamespaceContext;
-import javax.xml.xpath.XPath;
-import javax.xml.xpath.XPathConstants;
-import javax.xml.xpath.XPathExpressionException;
-import javax.xml.xpath.XPathFactory;
-
-/**
- * Creates the basic files needed to get an Android project up and running. Also
- * allows creation of IntelliJ project files.
- *
- * @hide
- */
-public class ProjectCreator {
-    
-    /** Package path substitution string used in template files, i.e. "PACKAGE_PATH" */
-    private final static String PH_JAVA_FOLDER = "PACKAGE_PATH";
-    /** Package name substitution string used in template files, i.e. "PACKAGE" */
-    private final static String PH_PACKAGE = "PACKAGE";
-    /** Activity name substitution string used in template files, i.e. "ACTIVITY_NAME". */
-    private final static String PH_ACTIVITY_NAME = "ACTIVITY_NAME";
-    /** Project name substitution string used in template files, i.e. "PROJECT_NAME". */
-    private final static String PH_PROJECT_NAME = "PROJECT_NAME";
-    
-    private final static String FOLDER_TESTS = "tests";
-    
-    public enum OutputLevel {
-        /** Silent mode. Project creation will only display errors. */
-        SILENT,
-        /** Normal mode. Project creation will display what's being done, display
-         * error but not warnings. */
-        NORMAL,
-        /** Verbose mode. Project creation will display what's being done, errors and warnings. */
-        VERBOSE;
-    }
-
-    /**
-     * Exception thrown when a project creation fails, typically because a template
-     * file cannot be written.
-     */
-    private static class ProjectCreateException extends Exception {
-        /** default UID. This will not be serialized anyway. */
-        private static final long serialVersionUID = 1L;
-        
-        ProjectCreateException(String message) {
-            super(message);
-        }
-        
-        ProjectCreateException(Throwable t, String format, Object... args) {
-            super(format != null ? String.format(format, args) : format, t);
-        }
-
-        ProjectCreateException(String format, Object... args) {
-            super(String.format(format, args));
-        }
-    }
-    
-    private final OutputLevel mLevel;
-
-    private final ISdkLog mLog;
-    private final String mSdkFolder;
-    
-    public ProjectCreator(String sdkFolder, OutputLevel level, ISdkLog log) {
-        mSdkFolder = sdkFolder;
-        mLevel = level;
-        mLog = log;
-    }
-    
-    /**
-     * Creates a new project.
-     * 
-     * @param folderPath the folder of the project to create.
-     * @param projectName the name of the project.
-     * @param packageName the package of the project.
-     * @param activityName the activity of the project as it will appear in the manifest.
-     * @param target the project target.
-     * @param isTestProject whether the project to create is a test project.
-     */
-    public void createProject(String folderPath, String projectName,
-            String packageName, String activityName, IAndroidTarget target,
-            boolean isTestProject) {
-        
-        // create project folder if it does not exist
-        File projectFolder = new File(folderPath);
-        if (!projectFolder.exists()) {
-
-            boolean created = false;
-            Throwable t = null;
-            try {
-                created = projectFolder.mkdirs();
-            } catch (Exception e) {
-                t = e;
-            }
-            
-            if (created) {
-                println("Created project directory: %1$s", projectFolder);
-            } else {
-                mLog.error(t, "Could not create directory: %1$s", projectFolder);
-                return;
-            }
-        } else {
-            Exception e = null;
-            String error = null;
-            try {
-                String[] content = projectFolder.list();
-                if (content == null) {
-                    error = "Project folder '%1$s' is not a directory.";
-                } else if (content.length != 0) {
-                    error = "Project folder '%1$s' is not empty. Please consider using '%2$s update' instead.";
-                }
-            } catch (Exception e1) {
-                e = e1;
-            }
-            
-            if (e != null || error != null) {
-                mLog.error(e, error, projectFolder, SdkConstants.androidCmdName());
-            }
-        }
-
-        try {
-            // first create the project properties.
-
-            // location of the SDK goes in localProperty
-            ProjectProperties localProperties = ProjectProperties.create(folderPath,
-                    PropertyType.LOCAL);
-            localProperties.setProperty(ProjectProperties.PROPERTY_SDK, mSdkFolder);
-            localProperties.save();
-
-            // target goes in default properties
-            ProjectProperties defaultProperties = ProjectProperties.create(folderPath,
-                    PropertyType.DEFAULT);
-            defaultProperties.setAndroidTarget(target);
-            defaultProperties.save();
-            
-            // create an empty build.properties
-            ProjectProperties buildProperties = ProjectProperties.create(folderPath,
-                    PropertyType.BUILD);
-            buildProperties.save();
-
-            // create the map for place-holders of values to replace in the templates
-            final HashMap<String, String> keywords = new HashMap<String, String>();
-
-            // create the required folders.
-            // compute src folder path
-            final String packagePath =
-                stripString(packageName.replace(".", File.separator),
-                        File.separatorChar);
-
-            // put this path in the place-holder map for project files that needs to list
-            // files manually.
-            keywords.put(PH_JAVA_FOLDER, packagePath);
-
-            keywords.put(PH_PACKAGE, packageName);
-            if (activityName != null) {
-                keywords.put(PH_ACTIVITY_NAME, activityName);
-            }
-
-            // Take the project name from the command line if there's one
-            if (projectName != null) {
-                keywords.put(PH_PROJECT_NAME, projectName);
-            } else {
-                if (activityName != null) {
-                    // Use the activity as project name 
-                    keywords.put(PH_PROJECT_NAME, activityName);
-                } else {
-                    // We need a project name. Just pick up the basename of the project
-                    // directory.
-                    projectName = projectFolder.getName();
-                    keywords.put(PH_PROJECT_NAME, projectName);                    
-                }
-            }
-            
-            // create the source folder and the java package folders.
-            final String srcFolderPath = SdkConstants.FD_SOURCES + File.separator + packagePath;
-            File sourceFolder = createDirs(projectFolder, srcFolderPath);
-            String javaTemplate = "java_file.template";
-            String activityFileName = activityName + ".java";
-            if (isTestProject) {
-                javaTemplate = "java_tests_file.template";
-                activityFileName = activityName + "Test.java";
-            }
-            installTemplate(javaTemplate, new File(sourceFolder, activityFileName),
-                    keywords, target);
-
-            // create other useful folders
-            File resourceFodler = createDirs(projectFolder, SdkConstants.FD_RESOURCES);
-            createDirs(projectFolder, SdkConstants.FD_OUTPUT);
-            createDirs(projectFolder, SdkConstants.FD_NATIVE_LIBS);
-
-            if (isTestProject == false) {
-                /* Make res files only for non test projects */
-                File valueFolder = createDirs(resourceFodler, SdkConstants.FD_VALUES);
-                installTemplate("strings.template", new File(valueFolder, "strings.xml"),
-                        keywords, target);
-
-                File layoutFolder = createDirs(resourceFodler, SdkConstants.FD_LAYOUT);
-                installTemplate("layout.template", new File(layoutFolder, "main.xml"),
-                        keywords, target);
-            }
-
-            /* Make AndroidManifest.xml and build.xml files */
-            String manifestTemplate = "AndroidManifest.template";
-            if (isTestProject) {
-                manifestTemplate = "AndroidManifest.tests.template"; 
-            }
-
-            installTemplate(manifestTemplate,
-                    new File(projectFolder, SdkConstants.FN_ANDROID_MANIFEST_XML),
-                    keywords, target);
-            
-            installTemplate("build.template",
-                    new File(projectFolder, SdkConstants.FN_BUILD_XML),
-                    keywords);
-
-            // if this is not a test project, then we create one.
-            if (isTestProject == false) {
-                // create the test project folder.
-                createDirs(projectFolder, FOLDER_TESTS);
-                File testProjectFolder = new File(folderPath, FOLDER_TESTS);
-                
-                createProject(testProjectFolder.getAbsolutePath(), projectName, packageName,
-                        activityName, target, true /*isTestProject*/);
-            }
-        } catch (ProjectCreateException e) {
-            mLog.error(e, null);
-        } catch (IOException e) {
-            mLog.error(e, null);
-        }
-    }
-    
-    /**
-     * Updates an existing project.
-     * <p/>
-     * Workflow:
-     * <ul>
-     * <li> Check AndroidManifest.xml is present (required)
-     * <li> Check there's a default.properties with a target *or* --target was specified
-     * <li> Update default.prop if --target was specified
-     * <li> Refresh/create "sdk" in local.properties
-     * <li> Build.xml: create if not present or no <androidinit(\w|/>) in it
-     * </ul>
-     * 
-     * @param folderPath the folder of the project to update. This folder must exist.
-     * @param target the project target. Can be null.
-     * @param projectName The project name from --name. Can be null.
-     */
-    public void updateProject(String folderPath, IAndroidTarget target, String projectName ) {
-        // project folder must exist and be a directory, since this is an update
-        File projectFolder = new File(folderPath);
-        if (!projectFolder.isDirectory()) {
-            mLog.error(null, "Project folder '%1$s' is not a valid directory, this is not an Android project you can update.",
-                    projectFolder);
-            return;
-        }
-
-        // Check AndroidManifest.xml is present
-        File androidManifest = new File(projectFolder, SdkConstants.FN_ANDROID_MANIFEST_XML);
-        if (!androidManifest.isFile()) {
-            mLog.error(null,
-                    "%1$s not found in '%2$s', this is not an Android project you can update.",
-                    SdkConstants.FN_ANDROID_MANIFEST_XML,
-                    folderPath);
-            return;
-        }
-        
-        // Check there's a default.properties with a target *or* --target was specified
-        ProjectProperties props = ProjectProperties.load(folderPath, PropertyType.DEFAULT);
-        if (props == null || props.getProperty(ProjectProperties.PROPERTY_TARGET) == null) {
-            if (target == null) {
-                mLog.error(null,
-                    "There is no %1$s file in '%2$s'. Please provide a --target to the '%3$s update' command.",
-                    PropertyType.DEFAULT.getFilename(),
-                    folderPath,
-                    SdkConstants.androidCmdName());
-                return;
-            }
-        }
-
-        // Update default.prop if --target was specified
-        if (target != null) {
-            // we already attempted to load the file earlier, if that failed, create it.
-            if (props == null) {
-                props = ProjectProperties.create(folderPath, PropertyType.DEFAULT);
-            }
-            
-            // set or replace the target
-            props.setAndroidTarget(target);
-            try {
-                props.save();
-                println("Updated %1$s", PropertyType.DEFAULT.getFilename());
-            } catch (IOException e) {
-                mLog.error(e, "Failed to write %1$s file in '%2$s'",
-                        PropertyType.DEFAULT.getFilename(),
-                        folderPath);
-                return;
-            }
-        }
-        
-        // Refresh/create "sdk" in local.properties
-        // because the file may already exists and contain other values (like apk config),
-        // we first try to load it.
-        props = ProjectProperties.load(folderPath, PropertyType.LOCAL);
-        if (props == null) {
-            props = ProjectProperties.create(folderPath, PropertyType.LOCAL);
-        }
-        
-        // set or replace the sdk location.
-        props.setProperty(ProjectProperties.PROPERTY_SDK, mSdkFolder);
-        try {
-            props.save();
-            println("Updated %1$s", PropertyType.LOCAL.getFilename());
-        } catch (IOException e) {
-            mLog.error(e, "Failed to write %1$s file in '%2$s'",
-                    PropertyType.LOCAL.getFilename(),
-                    folderPath);
-            return;
-        }
-        
-        // Build.xml: create if not present or no <androidinit/> in it
-        File buildXml = new File(projectFolder, SdkConstants.FN_BUILD_XML);
-        boolean needsBuildXml = projectName != null || !buildXml.exists();
-        if (!needsBuildXml) {
-            // Note that "<androidinit" must be followed by either a whitespace, a "/" (for the
-            // XML /> closing tag) or an end-of-line. This way we know the XML tag is really this
-            // one and later we will be able to use an "androidinit2" tag or such as necessary.
-            needsBuildXml = !checkFileContainsRegexp(buildXml, "<androidinit(?:\\s|/|$)");
-            if (needsBuildXml) {
-                println("File %1$s is too old and needs to be updated.", SdkConstants.FN_BUILD_XML);
-            }
-        }
-        
-        if (needsBuildXml) {
-            // create the map for place-holders of values to replace in the templates
-            final HashMap<String, String> keywords = new HashMap<String, String>();
-
-            // Take the project name from the command line if there's one
-            if (projectName != null) {
-                keywords.put(PH_PROJECT_NAME, projectName);
-            } else {
-                extractPackageFromManifest(androidManifest, keywords);
-                if (keywords.containsKey(PH_ACTIVITY_NAME)) {
-                    // Use the activity as project name 
-                    keywords.put(PH_PROJECT_NAME, keywords.get(PH_ACTIVITY_NAME));
-                } else {
-                    // We need a project name. Just pick up the basename of the project
-                    // directory.
-                    projectName = projectFolder.getName();
-                    keywords.put(PH_PROJECT_NAME, projectName);                    
-                }
-            }
-
-            if (mLevel == OutputLevel.VERBOSE) {
-                println("Regenerating %1$s with project name %2$s",
-                        SdkConstants.FN_BUILD_XML,
-                        keywords.get(PH_PROJECT_NAME));
-            }
-            
-            try {
-                installTemplate("build.template",
-                        new File(projectFolder, SdkConstants.FN_BUILD_XML),
-                        keywords);
-            } catch (ProjectCreateException e) {
-                mLog.error(e, null);
-            }
-        }
-    }
-
-    /**
-     * Returns true if any line of the input file contains the requested regexp.
-     */
-    private boolean checkFileContainsRegexp(File file, String regexp) {
-        Pattern p = Pattern.compile(regexp);
-
-        try {
-            BufferedReader in = new BufferedReader(new FileReader(file));
-            String line;
-            
-            while ((line = in.readLine()) != null) {
-                if (p.matcher(line).find()) {
-                    return true;
-                }
-            }
-            
-            in.close();
-        } catch (Exception e) {
-            // ignore
-        }
-        
-        return false;
-    }
-
-    /**
-     * Extracts a "full" package & activity name from an AndroidManifest.xml.
-     * <p/>
-     * The keywords dictionary is always filed the package name under the key {@link #PH_PACKAGE}.
-     * If an activity name can be found, it is filed under the key {@link #PH_ACTIVITY_NAME}.
-     * When no activity is found, this key is not created.
-     *  
-     * @param manifestFile The AndroidManifest.xml file 
-     * @param outKeywords  Place where to put the out parameters: package and activity names.
-     * @return True if the package/activity was parsed and updated in the keyword dictionary.
-     */
-    private boolean extractPackageFromManifest(File manifestFile,
-            Map<String, String> outKeywords) {
-        try {
-            final String nsPrefix = "android";
-            final String nsURI = SdkConstants.NS_RESOURCES;
-            
-            XPath xpath = XPathFactory.newInstance().newXPath();
-            
-            xpath.setNamespaceContext(new NamespaceContext() {
-                public String getNamespaceURI(String prefix) {
-                    if (nsPrefix.equals(prefix)) {
-                        return nsURI;
-                    }
-                    return XMLConstants.NULL_NS_URI;
-                }
-
-                public String getPrefix(String namespaceURI) {
-                    if (nsURI.equals(namespaceURI)) {
-                        return nsPrefix;
-                    }
-                    return null;
-                }
-
-                @SuppressWarnings("unchecked")
-                public Iterator getPrefixes(String namespaceURI) {
-                    if (nsURI.equals(namespaceURI)) {
-                        ArrayList<String> list = new ArrayList<String>();
-                        list.add(nsPrefix);
-                        return list.iterator();
-                    }
-                    return null;
-                }
-                
-            });
-            
-            InputSource source = new InputSource(new FileReader(manifestFile));
-            String packageName = xpath.evaluate("/manifest/@package", source);
-
-            source = new InputSource(new FileReader(manifestFile)); 
-            
-            // Select the "android:name" attribute of all <activity> nodes but only if they
-            // contain a sub-node <intent-filter><action> with an "android:name" attribute which
-            // is 'android.intent.action.MAIN' and an <intent-filter><category> with an
-            // "android:name" attribute which is 'android.intent.category.LAUNCHER'  
-            String expression = String.format("/manifest/application/activity" +
-                    "[intent-filter/action/@%1$s:name='android.intent.action.MAIN' and " +
-                    "intent-filter/category/@%1$s:name='android.intent.category.LAUNCHER']" +
-                    "/@%1$s:name", nsPrefix);
-
-            NodeList activityNames = (NodeList) xpath.evaluate(expression, source,
-                    XPathConstants.NODESET);
-
-            // If we get here, both XPath expressions were valid so we're most likely dealing
-            // with an actual AndroidManifest.xml file. The nodes may not have the requested
-            // attributes though, if which case we should warn.
-            
-            if (packageName == null || packageName.length() == 0) {
-                mLog.error(null,
-                        "Missing <manifest package=\"...\"> in '%1$s'",
-                        manifestFile.getName());
-                return false;
-            }
-
-            // Get the first activity that matched earlier. If there is no activity,
-            // activityName is set to an empty string and the generated "combined" name
-            // will be in the form "package." (with a dot at the end).
-            String activityName = "";
-            if (activityNames.getLength() > 0) {
-                activityName = activityNames.item(0).getNodeValue();
-            }
-
-            if (mLevel == OutputLevel.VERBOSE && activityNames.getLength() > 1) {
-                println("WARNING: There is more than one activity defined in '%1$s'.\n" +
-                        "Only the first one will be used. If this is not appropriate, you need\n" +
-                        "to specify one of these values manually instead:",
-                        manifestFile.getName());
-                
-                for (int i = 0; i < activityNames.getLength(); i++) {
-                    String name = activityNames.item(i).getNodeValue();
-                    name = combinePackageActivityNames(packageName, name);
-                    println("- %1$s", name);
-                }
-            }
-            
-            if (activityName.length() == 0) {
-                mLog.warning("Missing <activity %1$s:name=\"...\"> in '%2$s'.\n" +
-                        "No activity will be generated.",
-                        nsPrefix, manifestFile.getName());
-            } else {
-                outKeywords.put(PH_ACTIVITY_NAME, activityName);
-            }
-
-            outKeywords.put(PH_PACKAGE, packageName);
-            return true;
-            
-        } catch (IOException e) {
-            mLog.error(e, "Failed to read %1$s", manifestFile.getName());
-        } catch (XPathExpressionException e) {
-            Throwable t = e.getCause();
-            mLog.error(t == null ? e : t,
-                    "Failed to parse %1$s",
-                    manifestFile.getName());
-        }
-        
-        return false;
-    }
-    
-    private String combinePackageActivityNames(String packageName, String activityName) {
-        // Activity Name can have 3 forms:
-        // - ".Name" means this is a class name in the given package name.
-        //    The full FQCN is thus packageName + ".Name"
-        // - "Name" is an older variant of the former. Full FQCN is packageName + "." + "Name"
-        // - "com.blah.Name" is a full FQCN. Ignore packageName and use activityName as-is.
-        //   To be valid, the package name should have at least two components. This is checked
-        //   later during the creation of the build.xml file, so we just need to detect there's
-        //   a dot but not at pos==0.
-        
-        int pos = activityName.indexOf('.');
-        if (pos == 0) {
-            return packageName + activityName;
-        } else if (pos > 0) {
-            return activityName;
-        } else {
-            return packageName + "." + activityName;
-        }
-    }
-
-    /**
-     * Installs a new file that is based on a template file provided by a given target.
-     * Each match of each key from the place-holder map in the template will be replaced with its
-     * corresponding value in the created file.
-     * 
-     * @param templateName the name of to the template file
-     * @param destFile the path to the destination file, relative to the project
-     * @param placeholderMap a map of (place-holder, value) to create the file from the template.
-     * @param target the Target of the project that will be providing the template.
-     * @throws ProjectCreateException 
-     */
-    private void installTemplate(String templateName, File destFile,
-            Map<String, String> placeholderMap, IAndroidTarget target)
-            throws ProjectCreateException {
-        // query the target for its template directory
-        String templateFolder = target.getPath(IAndroidTarget.TEMPLATES);
-        final String sourcePath = templateFolder + File.separator + templateName;
-
-        installFullPathTemplate(sourcePath, destFile, placeholderMap);
-    }
-
-    /**
-     * Installs a new file that is based on a template file provided by the tools folder.
-     * Each match of each key from the place-holder map in the template will be replaced with its
-     * corresponding value in the created file.
-     * 
-     * @param templateName the name of to the template file
-     * @param destFile the path to the destination file, relative to the project
-     * @param placeholderMap a map of (place-holder, value) to create the file from the template.
-     * @throws ProjectCreateException 
-     */
-    private void installTemplate(String templateName, File destFile,
-            Map<String, String> placeholderMap)
-            throws ProjectCreateException {
-        // query the target for its template directory
-        String templateFolder = mSdkFolder + File.separator + SdkConstants.OS_SDK_TOOLS_LIB_FOLDER;
-        final String sourcePath = templateFolder + File.separator + templateName;
-
-        installFullPathTemplate(sourcePath, destFile, placeholderMap);
-    }
-
-    /**
-     * Installs a new file that is based on a template.
-     * Each match of each key from the place-holder map in the template will be replaced with its
-     * corresponding value in the created file.
-     * 
-     * @param sourcePath the full path to the source template file
-     * @param destFile the destination file
-     * @param placeholderMap a map of (place-holder, value) to create the file from the template.
-     * @throws ProjectCreateException 
-     */
-    private void installFullPathTemplate(String sourcePath, File destFile,
-            Map<String, String> placeholderMap) throws ProjectCreateException {
-        
-        boolean existed = destFile.exists();
-        
-        try {
-            BufferedWriter out = new BufferedWriter(new FileWriter(destFile));
-            BufferedReader in = new BufferedReader(new FileReader(sourcePath));
-            String line;
-            
-            while ((line = in.readLine()) != null) {
-                for (String key : placeholderMap.keySet()) {
-                    line = line.replace(key, placeholderMap.get(key));
-                }
-                
-                out.write(line);
-                out.newLine();
-            }
-            
-            out.close();
-            in.close();
-        } catch (Exception e) {
-            throw new ProjectCreateException(e, "Could not access %1$s: %2$s",
-                    destFile, e.getMessage());
-        }
-        
-        println("%1$s file %2$s",
-                existed ? "Updated" : "Added",
-                destFile);
-    }
-
-    /**
-     * Prints a message unless silence is enabled.
-     * <p/>
-     * This is just a convenience wrapper around {@link ISdkLog#printf(String, Object...)} from
-     * {@link #mLog} after testing if ouput level is {@link OutputLevel#VERBOSE}.
-     * 
-     * @param format Format for String.format
-     * @param args Arguments for String.format
-     */
-    private void println(String format, Object... args) {
-        if (mLevel != OutputLevel.SILENT) {
-            if (!format.endsWith("\n")) {
-                format += "\n";
-            }
-            mLog.printf(format, args);
-        }
-    }
-
-    /**
-     * Creates a new folder, along with any parent folders that do not exists.
-     * 
-     * @param parent the parent folder
-     * @param name the name of the directory to create.
-     * @throws ProjectCreateException 
-     */
-    private File createDirs(File parent, String name) throws ProjectCreateException {
-        final File newFolder = new File(parent, name);
-        boolean existedBefore = true;
-
-        if (!newFolder.exists()) {
-            if (!newFolder.mkdirs()) {
-                throw new ProjectCreateException("Could not create directory: %1$s", newFolder);
-            }
-            existedBefore = false;
-        }
-
-        if (newFolder.isDirectory()) {
-            if (!newFolder.canWrite()) {
-                throw new ProjectCreateException("Path is not writable: %1$s", newFolder);
-            }
-        } else {
-            throw new ProjectCreateException("Path is not a directory: %1$s", newFolder);
-        }
-
-        if (!existedBefore) {
-            try {
-                println("Created directory %1$s", newFolder.getCanonicalPath());
-            } catch (IOException e) {
-                throw new ProjectCreateException(
-                        "Could not determine canonical path of created directory", e);
-            }
-        }
-        
-        return newFolder;
-    }
-
-    /**
-     * Strips the string of beginning and trailing characters (multiple
-     * characters will be stripped, example stripString("..test...", '.')
-     * results in "test";
-     * 
-     * @param s the string to strip
-     * @param strip the character to strip from beginning and end
-     * @return the stripped string or the empty string if everything is stripped.
-     */
-    private static String stripString(String s, char strip) {
-        final int sLen = s.length();
-        int newStart = 0, newEnd = sLen - 1;
-        
-        while (newStart < sLen && s.charAt(newStart) == strip) {
-          newStart++;
-        }
-        while (newEnd >= 0 && s.charAt(newEnd) == strip) {
-          newEnd--;
-        }
-        
-        /*
-         * newEnd contains a char we want, and substring takes end as being
-         * exclusive
-         */
-        newEnd++;
-        
-        if (newStart >= sLen || newEnd < 0) {
-            return "";
-        }
-        
-        return s.substring(newStart, newEnd);
-    }
-}
diff --git a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectProperties.java b/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectProperties.java
deleted file mode 100644
index 1f6a047..0000000
--- a/tools/sdkmanager/libs/sdklib/src/com/android/sdklib/project/ProjectProperties.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdklib.project;
-
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.SdkManager;
-
-import java.io.File;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Map.Entry;
-
-/**
- * Class to load and save project properties for both ADT and Ant-based build.
- *
- */
-public final class ProjectProperties {
-    /** The property name for the project target */
-    public final static String PROPERTY_TARGET = "target";
-    public final static String PROPERTY_CONFIGS = "configs";
-    public final static String PROPERTY_SDK = "sdk-location";
-    
-    public static enum PropertyType {
-        BUILD("build.properties", BUILD_HEADER),
-        DEFAULT("default.properties", DEFAULT_HEADER),
-        LOCAL("local.properties", LOCAL_HEADER);
-        
-        private final String mFilename;
-        private final String mHeader;
-
-        PropertyType(String filename, String header) {
-            mFilename = filename;
-            mHeader = header;
-        }
-        
-        public String getFilename() {
-            return mFilename;
-        }
-    }
-    
-    private final static String LOCAL_HEADER =
-//           1-------10--------20--------30--------40--------50--------60--------70--------80        
-            "# This file is automatically generated by Android Tools.\n" +
-            "# Do not modify this file -- YOUR CHANGES WILL BE ERASED!\n" +
-            "# \n" +
-            "# This file must *NOT* be checked in Version Control Systems,\n" +
-            "# as it contains information specific to your local configuration.\n" +
-            "\n";
-
-    private final static String DEFAULT_HEADER =
-//          1-------10--------20--------30--------40--------50--------60--------70--------80        
-           "# This file is automatically generated by Android Tools.\n" +
-           "# Do not modify this file -- YOUR CHANGES WILL BE ERASED!\n" +
-           "# \n" +
-           "# This file must be checked in Version Control Systems.\n" +
-           "# \n" +
-           "# To customize properties used by the Ant build system use,\n" +
-           "# \"build.properties\", and override values to adapt the script to your\n" +
-           "# project structure.\n" +
-           "\n";
-
-    private final static String BUILD_HEADER =
-//          1-------10--------20--------30--------40--------50--------60--------70--------80        
-           "# This file is used to override default values used by the Ant build system.\n" +
-           "# \n" +
-           "# This file must be checked in Version Control Systems, as it is\n" +
-           "# integral to the build system of your project.\n" +
-           "\n" +
-           "# The name of your application package as defined in the manifest.\n" +
-           "# Used by the 'uninstall' rule.\n"+
-           "#application-package=com.example.myproject\n" +
-           "\n" +
-           "# The name of the source folder.\n" +
-           "#source-folder=src\n" +
-           "\n" +
-           "# The name of the output folder.\n" +
-           "#out-folder=bin\n" +
-           "\n";
-
-    private final static Map<String, String> COMMENT_MAP = new HashMap<String, String>();
-    static {
-//               1-------10--------20--------30--------40--------50--------60--------70--------80        
-        COMMENT_MAP.put(PROPERTY_TARGET,
-                "# Project target.\n");
-        COMMENT_MAP.put(PROPERTY_SDK, "# location of the SDK. This is only used by Ant\n" +
-                "# For customization when using a Version Control System, please read the\n" +
-                "# header note.\n");
-    }
-    
-    private final String mProjectFolderOsPath;
-    private final Map<String, String> mProperties;
-    private final PropertyType mType;
-
-    /**
-     * Loads a project properties file and return a {@link ProjectProperties} object
-     * containing the properties
-     * 
-     * @param projectFolderOsPath the project folder.
-     * @param type One the possible {@link PropertyType}s. 
-     */
-    public static ProjectProperties load(String projectFolderOsPath, PropertyType type) {
-        File projectFolder = new File(projectFolderOsPath);
-        if (projectFolder.isDirectory()) {
-            File defaultFile = new File(projectFolder, type.mFilename);
-            if (defaultFile.isFile()) {
-                Map<String, String> map = SdkManager.parsePropertyFile(defaultFile, null /* log */);
-                if (map != null) {
-                    return new ProjectProperties(projectFolderOsPath, map, type);
-                }
-            }
-        }
-        return null;
-    }
- 
-    /**
-     * Merges all properties from the given file into the current properties.
-     * <p/>
-     * This emulates the Ant behavior: existing properties are <em>not</em> overriden.
-     * Only new undefined properties become defined.
-     * <p/>
-     * Typical usage:
-     * <ul>
-     * <li>Create a ProjectProperties with {@link PropertyType#BUILD}
-     * <li>Merge in values using {@link PropertyType#DEFAULT}
-     * <li>The result is that this contains all the properties from default plus those
-     *     overridden by the build.properties file.
-     * </ul>
-     * 
-     * @param type One the possible {@link PropertyType}s. 
-     * @return this object, for chaining.
-     */
-    public ProjectProperties merge(PropertyType type) {
-        File projectFolder = new File(mProjectFolderOsPath);
-        if (projectFolder.isDirectory()) {
-            File defaultFile = new File(projectFolder, type.mFilename);
-            if (defaultFile.isFile()) {
-                Map<String, String> map = SdkManager.parsePropertyFile(defaultFile, null /* log */);
-                if (map != null) {
-                    for(Entry<String, String> entry : map.entrySet()) {
-                        String key = entry.getKey();
-                        String value = entry.getValue();
-                        if (!mProperties.containsKey(key) && value != null) {
-                            mProperties.put(key, value);
-                        }
-                    }
-                }
-            }
-        }
-        return this;
-    }
-
-    /**
-     * Creates a new project properties object, with no properties.
-     * <p/>The file is not created until {@link #save()} is called.
-     * @param projectFolderOsPath the project folder.
-     * @param type
-     */
-    public static ProjectProperties create(String projectFolderOsPath, PropertyType type) {
-        // create and return a ProjectProperties with an empty map.
-        return new ProjectProperties(projectFolderOsPath, new HashMap<String, String>(), type);
-    }
-    
-    /**
-     * Sets a new properties. If a property with the same name already exists, it is replaced.
-     * @param name the name of the property.
-     * @param value the value of the property.
-     */
-    public void setProperty(String name, String value) {
-        mProperties.put(name, value);
-    }
-    
-    /**
-     * Sets the target property to the given {@link IAndroidTarget} object.
-     * @param target the Android target.
-     */
-    public void setAndroidTarget(IAndroidTarget target) {
-        assert mType == PropertyType.DEFAULT;
-        mProperties.put(PROPERTY_TARGET, target.hashString());
-    }
-    
-    /**
-     * Returns the value of a property.
-     * @param name the name of the property.
-     * @return the property value or null if the property is not set.
-     */
-    public String getProperty(String name) {
-        return mProperties.get(name);
-    }
-    
-    /**
-     * Removes a property and returns its previous value (or null if the property did not exist).
-     * @param name the name of the property to remove.
-     */
-    public String removeProperty(String name) {
-        return mProperties.remove(name);
-    }
-
-    /**
-     * Saves the property file.
-     * @throws IOException
-     */
-    public void save() throws IOException {
-        File toSave = new File(mProjectFolderOsPath, mType.mFilename);
-        
-        FileWriter writer = new FileWriter(toSave);
-        
-        // write the header
-        writer.write(mType.mHeader);
-        
-        // write the properties.
-        for (Entry<String, String> entry : mProperties.entrySet()) {
-            String comment = COMMENT_MAP.get(entry.getKey());
-            if (comment != null) {
-                writer.write(comment);
-            }
-            writer.write(String.format("%s=%s\n", entry.getKey(), entry.getValue()));
-        }
-        
-        // close the file to flush
-        writer.close();
-    }
-    
-    /**
-     * Private constructor.
-     * <p/>
-     * Use {@link #load(String, PropertyType)} or {@link #create(String, PropertyType)}
-     * to instantiate.
-     */
-    private ProjectProperties(String projectFolderOsPath, Map<String, String> map,
-            PropertyType type) {
-        mProjectFolderOsPath = projectFolderOsPath;
-        mProperties = map;
-        mType = type;
-    }
-}
diff --git a/tools/sdkmanager/libs/sdkuilib/.classpath b/tools/sdkmanager/libs/sdkuilib/.classpath
deleted file mode 100644
index eb5af7e..0000000
--- a/tools/sdkmanager/libs/sdkuilib/.classpath
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_SWT"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkLib"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/sdkmanager/libs/sdkuilib/.project b/tools/sdkmanager/libs/sdkuilib/.project
deleted file mode 100644
index da430c8..0000000
--- a/tools/sdkmanager/libs/sdkuilib/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>SdkUiLib</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/sdkmanager/libs/sdkuilib/Android.mk b/tools/sdkmanager/libs/sdkuilib/Android.mk
deleted file mode 100644
index 8e0bc23..0000000
--- a/tools/sdkmanager/libs/sdkuilib/Android.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-SDKUILIB_LOCAL_DIR := $(call my-dir)
-include $(SDKUILIB_LOCAL_DIR)/src/Android.mk
diff --git a/tools/sdkmanager/libs/sdkuilib/README b/tools/sdkmanager/libs/sdkuilib/README
deleted file mode 100644
index d66b84a..0000000
--- a/tools/sdkmanager/libs/sdkuilib/README
+++ /dev/null
@@ -1,11 +0,0 @@
-Using the Eclipse projects for ddmuilib.
-
-ddmuilib requires SWT to compile.
-
-SWT is available in the depot under prebuild/<platform>/swt
-
-Because the build path cannot contain relative path that are not inside the project directory,
-the .classpath file references a user library called ANDROID_SWT.
-
-In order to compile the project, make a user library called ANDROID_SWT containing the jar
-available at prebuild/<platform>/swt.
\ No newline at end of file
diff --git a/tools/sdkmanager/libs/sdkuilib/src/Android.mk b/tools/sdkmanager/libs/sdkuilib/src/Android.mk
deleted file mode 100644
index 2d3c774..0000000
--- a/tools/sdkmanager/libs/sdkuilib/src/Android.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-# Copyright 2008 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-
-# no resources yet.
-# LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_JAVA_LIBRARIES := \
-	sdklib \
-	swt \
-	org.eclipse.jface_3.2.0.I20060605-1400 \
-	org.eclipse.equinox.common_3.2.0.v20060603 \
-	org.eclipse.core.commands_3.2.0.I20060605-1400
-	
-LOCAL_MODULE := sdkuilib
-
-include $(BUILD_HOST_JAVA_LIBRARY)
-
diff --git a/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/AvdSelector.java b/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/AvdSelector.java
deleted file mode 100644
index 9d0b928..0000000
--- a/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/AvdSelector.java
+++ /dev/null
@@ -1,418 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkuilib;
-
-import com.android.sdklib.IAndroidTarget;
-import com.android.sdklib.avd.AvdManager.AvdInfo;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.ArrayList;
-
-
-/**
- * The AVD selector is a table that is added to the given parent composite.
- * <p/>
- * To use, create it using {@link #AvdSelector(Composite, AvdInfo[], boolean)} then
- * call {@link #setSelection(AvdInfo)}, {@link #setSelectionListener(SelectionListener)}
- * and finally use {@link #getFirstSelected()} or {@link #getAllSelected()} to retrieve the
- * selection.
- */
-public final class AvdSelector {
-    
-    private AvdInfo[] mAvds;
-    private final boolean mAllowMultipleSelection;
-    private SelectionListener mSelectionListener;
-    private Table mTable;
-    private Label mDescription;
-
-    /**
-     * Creates a new SDK Target Selector, and fills it with a list of {@link AvdInfo}, filtered
-     * by a {@link IAndroidTarget}.
-     * <p/>Only the {@link AvdInfo} able to run application developed for the given
-     * {@link IAndroidTarget} will be displayed.
-     * 
-     * @param parent The parent composite where the selector will be added.
-     * @param avds The list of AVDs. This is <em>not</em> copied, the caller must not modify.
-     * @param allowMultipleSelection True if more than one SDK target can be selected at the same
-     *        time.
-     */
-    public AvdSelector(Composite parent, AvdInfo[] avds, IAndroidTarget filter,
-            boolean allowMultipleSelection) {
-        mAvds = avds;
-
-        // Layout has 1 column
-        Composite group = new Composite(parent, SWT.NONE);
-        group.setLayout(new GridLayout());
-        group.setLayoutData(new GridData(GridData.FILL_BOTH));
-        group.setFont(parent.getFont());
-        
-        mAllowMultipleSelection = allowMultipleSelection;
-        mTable = new Table(group, SWT.CHECK | SWT.FULL_SELECTION | SWT.SINGLE | SWT.BORDER);
-        mTable.setHeaderVisible(true);
-        mTable.setLinesVisible(false);
-
-        GridData data = new GridData();
-        data.grabExcessVerticalSpace = true;
-        data.grabExcessHorizontalSpace = true;
-        data.horizontalAlignment = GridData.FILL;
-        data.verticalAlignment = GridData.FILL;
-        mTable.setLayoutData(data);
-
-        mDescription = new Label(group, SWT.WRAP);
-        mDescription.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // create the table columns
-        final TableColumn column0 = new TableColumn(mTable, SWT.NONE);
-        column0.setText("AVD Name");
-        final TableColumn column1 = new TableColumn(mTable, SWT.NONE);
-        column1.setText("Target Name");
-        final TableColumn column2 = new TableColumn(mTable, SWT.NONE);
-        column2.setText("API Level");
-        final TableColumn column3 = new TableColumn(mTable, SWT.NONE);
-        column3.setText("SDK");
-
-        adjustColumnsWidth(mTable, column0, column1, column2, column3);
-        setupSelectionListener(mTable);
-        fillTable(mTable, filter);
-        setupTooltip(mTable);
-    }
-    
-    /**
-     * Creates a new SDK Target Selector, and fills it with a list of {@link AvdInfo}.
-     * 
-     * @param parent The parent composite where the selector will be added.
-     * @param avds The list of AVDs. This is <em>not</em> copied, the caller must not modify.
-     * @param allowMultipleSelection True if more than one SDK target can be selected at the same
-     *        time.
-     */
-    public AvdSelector(Composite parent, AvdInfo[] avds, boolean allowMultipleSelection) {
-        this(parent, avds, null /* filter */, allowMultipleSelection);
-    }
-
-    
-    public void setTableHeightHint(int heightHint) {
-        GridData data = new GridData();
-        data.heightHint = heightHint;
-        data.grabExcessVerticalSpace = true;
-        data.grabExcessHorizontalSpace = true;
-        data.horizontalAlignment = GridData.FILL;
-        data.verticalAlignment = GridData.FILL;
-        mTable.setLayoutData(data);
-    }
-    
-    /**
-     * Sets a new set of AVD, with an optional filter.
-     * <p/>This must be called from the UI thread.
-     * 
-     * @param avds The list of AVDs. This is <em>not</em> copied, the caller must not modify.
-     * @param filter An IAndroidTarget. If non-null, only AVD whose target are compatible with the
-     * filter target will displayed an available for selection.
-     */
-    public void setAvds(AvdInfo[] avds, IAndroidTarget filter) {
-        mAvds = avds;
-        fillTable(mTable, filter);
-    }
-
-    /**
-     * Returns the list of known AVDs.
-     * <p/>
-     * This is not a copy. Callers must <em>not</em> modify this array.
-     */
-    public AvdInfo[] getAvds() {
-        return mAvds;
-    }
-
-    /**
-     * Sets a selection listener. Set it to null to remove it.
-     * The listener will be called <em>after</em> this table processed its selection
-     * events so that the caller can see the updated state.
-     * <p/>
-     * The event's item contains a {@link TableItem}.
-     * The {@link TableItem#getData()} contains an {@link IAndroidTarget}.
-     * <p/>
-     * It is recommended that the caller uses the {@link #getFirstSelected()} and
-     * {@link #getAllSelected()} methods instead.
-     * 
-     * @param selectionListener The new listener or null to remove it.
-     */
-    public void setSelectionListener(SelectionListener selectionListener) {
-        mSelectionListener = selectionListener;
-    }
-    
-    /**
-     * Sets the current target selection.
-     * <p/>
-     * If the selection is actually changed, this will invoke the selection listener
-     * (if any) with a null event.
-     * 
-     * @param target the target to be selection
-     * @return true if the target could be selected, false otherwise.
-     */
-    public boolean setSelection(AvdInfo target) {
-        boolean found = false;
-        boolean modified = false;
-        for (TableItem i : mTable.getItems()) {
-            if ((AvdInfo) i.getData() == target) {
-                found = true;
-                if (!i.getChecked()) {
-                    modified = true;
-                    i.setChecked(true);
-                }
-            } else if (i.getChecked()) {
-                modified = true;
-                i.setChecked(false);
-            }
-        }
-        
-        if (modified && mSelectionListener != null) {
-            mSelectionListener.widgetSelected(null);
-        }
-        
-        return found;
-    }
-
-    /**
-     * Returns all selected items.
-     * This is useful when the table is in multiple-selection mode.
-     * 
-     * @see #getFirstSelected()
-     * @return An array of selected items. The list can be empty but not null.
-     */
-    public AvdInfo[] getAllSelected() {
-        ArrayList<IAndroidTarget> list = new ArrayList<IAndroidTarget>();
-        for (TableItem i : mTable.getItems()) {
-            if (i.getChecked()) {
-                list.add((IAndroidTarget) i.getData());
-            }
-        }
-        return list.toArray(new AvdInfo[list.size()]);
-    }
-
-    /**
-     * Returns the first selected item.
-     * This is useful when the table is in single-selection mode.
-     * 
-     * @see #getAllSelected()
-     * @return The first selected item or null.
-     */
-    public AvdInfo getFirstSelected() {
-        for (TableItem i : mTable.getItems()) {
-            if (i.getChecked()) {
-                return (AvdInfo) i.getData();
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Enables the receiver if the argument is true, and disables it otherwise.
-     * A disabled control is typically not selectable from the user interface
-     * and draws with an inactive or "grayed" look.
-     * 
-     * @param enabled the new enabled state.
-     */
-    public void setEnabled(boolean enabled) {
-        mTable.setEnabled(enabled);
-        mDescription.setEnabled(enabled);
-    }
-
-    /**
-     * Adds a listener to adjust the columns width when the parent is resized.
-     * <p/>
-     * If we need something more fancy, we might want to use this:
-     * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet77.java?view=co
-     */
-    private void adjustColumnsWidth(final Table table,
-            final TableColumn column0,
-            final TableColumn column1,
-            final TableColumn column2,
-            final TableColumn column3) {
-        // Add a listener to resize the column to the full width of the table
-        table.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Rectangle r = table.getClientArea();
-                column0.setWidth(r.width * 30 / 100); // 30%  
-                column1.setWidth(r.width * 45 / 100); // 45%
-                column2.setWidth(r.width * 15 / 100); // 15%
-                column3.setWidth(r.width * 10 / 100); // 10%
-            }
-        });
-    }
-
-
-    /**
-     * Creates a selection listener that will check or uncheck the whole line when
-     * double-clicked (aka "the default selection").
-     */
-    private void setupSelectionListener(final Table table) {
-        // Add a selection listener that will check/uncheck items when they are double-clicked
-        table.addSelectionListener(new SelectionListener() {
-            /** Default selection means double-click on "most" platforms */
-            public void widgetDefaultSelected(SelectionEvent e) {
-                if (e.item instanceof TableItem) {
-                    TableItem i = (TableItem) e.item;
-                    i.setChecked(!i.getChecked());
-                    enforceSingleSelection(i);
-                    updateDescription(i);
-                }
-
-                if (mSelectionListener != null) {
-                    mSelectionListener.widgetDefaultSelected(e);
-                }
-            }
-            
-            public void widgetSelected(SelectionEvent e) {
-                if (e.item instanceof TableItem) {
-                    TableItem i = (TableItem) e.item;
-                    enforceSingleSelection(i);
-                    updateDescription(i);
-                }
-
-                if (mSelectionListener != null) {
-                    mSelectionListener.widgetSelected(e);
-                }
-            }
-
-            /**
-             * If we're not in multiple selection mode, uncheck all other
-             * items when this one is selected.
-             */
-            private void enforceSingleSelection(TableItem item) {
-                if (!mAllowMultipleSelection && item.getChecked()) {
-                    Table parentTable = item.getParent();
-                    for (TableItem i2 : parentTable.getItems()) {
-                        if (i2 != item && i2.getChecked()) {
-                            i2.setChecked(false);
-                        }
-                    }
-                }
-            }
-        });
-    }
-
-    /**
-     * Fills the table with all AVD.
-     * The table columns are:
-     * <ul>
-     * <li>column 0: sdk name
-     * <li>column 1: sdk vendor
-     * <li>column 2: sdk api name
-     * <li>column 3: sdk version
-     * </ul>
-     */
-    private void fillTable(final Table table, IAndroidTarget filter) {
-        table.removeAll();
-        if (mAvds != null && mAvds.length > 0) {
-            table.setEnabled(true);
-            for (AvdInfo avd : mAvds) {
-                if (filter == null || filter.isCompatibleBaseFor(avd.getTarget())) {
-                    TableItem item = new TableItem(table, SWT.NONE);
-                    item.setData(avd);
-                    item.setText(0, avd.getName());
-                    IAndroidTarget target = avd.getTarget();
-                    item.setText(1, target.getFullName());
-                    item.setText(2, target.getApiVersionName());
-                    item.setText(3, Integer.toString(target.getApiVersionNumber()));
-                }
-            }
-        }
-        
-        if (table.getItemCount() == 0) {
-            table.setEnabled(false);
-            TableItem item = new TableItem(table, SWT.NONE);
-            item.setData(null);
-            item.setText(0, "--");
-            item.setText(1, "No AVD available");
-            item.setText(2, "--");
-            item.setText(3, "--");
-        }
-    }
-
-    /**
-     * Sets up a tooltip that displays the current item description.
-     * <p/>
-     * Displaying a tooltip over the table looks kind of odd here. Instead we actually
-     * display the description in a label under the table.
-     */
-    private void setupTooltip(final Table table) {
-        /*
-         * Reference: 
-         * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet125.java?view=markup
-         */
-        
-        final Listener listener = new Listener() {
-            public void handleEvent(Event event) {
-                
-                switch(event.type) {
-                case SWT.KeyDown:
-                case SWT.MouseExit:
-                case SWT.MouseDown:
-                    return;
-                    
-                case SWT.MouseHover:
-                    updateDescription(table.getItem(new Point(event.x, event.y)));
-                    break;
-                    
-                case SWT.Selection:
-                    if (event.item instanceof TableItem) {
-                        updateDescription((TableItem) event.item);
-                    }
-                    break;
-                    
-                default:
-                    return;
-                }
-
-            }
-        };
-        
-        table.addListener(SWT.Dispose, listener);
-        table.addListener(SWT.KeyDown, listener);
-        table.addListener(SWT.MouseMove, listener);
-        table.addListener(SWT.MouseHover, listener);
-    }
-
-    /**
-     * Updates the description label with the path of the item's AVD, if any.
-     */
-    private void updateDescription(TableItem item) {
-        if (item != null) {
-            Object data = item.getData();
-            if (data instanceof AvdInfo) {
-                String newTooltip = ((AvdInfo) data).getPath();
-                mDescription.setText(newTooltip == null ? "" : newTooltip);  //$NON-NLS-1$
-            }
-        }
-    }
-}
diff --git a/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/SdkTargetSelector.java b/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/SdkTargetSelector.java
deleted file mode 100644
index fc951f2..0000000
--- a/tools/sdkmanager/libs/sdkuilib/src/com/android/sdkuilib/SdkTargetSelector.java
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * Licensed under the Eclipse Public License, Version 1.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.eclipse.org/org/documents/epl-v10.php
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkuilib;
-
-import com.android.sdklib.IAndroidTarget;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-
-import java.util.ArrayList;
-
-
-/**
- * The SDK target selector is a table that is added to the given parent composite.
- * <p/>
- * To use, create it using {@link #SdkTargetSelector(Composite, IAndroidTarget[], boolean)} then
- * call {@link #setSelection(IAndroidTarget)}, {@link #setSelectionListener(SelectionListener)}
- * and finally use {@link #getFirstSelected()} or {@link #getAllSelected()} to retrieve the
- * selection.
- */
-public class SdkTargetSelector {
-    
-    private final IAndroidTarget[] mTargets;
-    private final boolean mAllowMultipleSelection;
-    private SelectionListener mSelectionListener;
-    private Table mTable;
-    private Label mDescription;
-
-    /**
-     * Creates a new SDK Target Selector.
-     * 
-     * @param parent The parent composite where the selector will be added.
-     * @param targets The list of targets. This is <em>not</em> copied, the caller must not modify.
-     * @param allowMultipleSelection True if more than one SDK target can be selected at the same
-     *        time.
-     */
-    public SdkTargetSelector(Composite parent, IAndroidTarget[] targets,
-            boolean allowMultipleSelection) {
-        mTargets = targets;
-
-        // Layout has 1 column
-        Composite group = new Composite(parent, SWT.NONE);
-        group.setLayout(new GridLayout());
-        group.setLayoutData(new GridData(GridData.FILL_BOTH));
-        group.setFont(parent.getFont());
-        
-        mAllowMultipleSelection = allowMultipleSelection;
-        mTable = new Table(group, SWT.CHECK | SWT.FULL_SELECTION | SWT.SINGLE | SWT.BORDER);
-        mTable.setHeaderVisible(true);
-        mTable.setLinesVisible(false);
-
-        GridData data = new GridData();
-        data.grabExcessVerticalSpace = true;
-        data.grabExcessHorizontalSpace = true;
-        data.horizontalAlignment = GridData.FILL;
-        data.verticalAlignment = GridData.FILL;
-        mTable.setLayoutData(data);
-
-        mDescription = new Label(group, SWT.WRAP);
-        mDescription.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // create the table columns
-        final TableColumn column0 = new TableColumn(mTable, SWT.NONE);
-        column0.setText("SDK Target");
-        final TableColumn column1 = new TableColumn(mTable, SWT.NONE);
-        column1.setText("Vendor");
-        final TableColumn column2 = new TableColumn(mTable, SWT.NONE);
-        column2.setText("API Level");
-        final TableColumn column3 = new TableColumn(mTable, SWT.NONE);
-        column3.setText("SDK");
-
-        adjustColumnsWidth(mTable, column0, column1, column2, column3);
-        setupSelectionListener(mTable);
-        fillTable(mTable);
-        setupTooltip(mTable);
-    }
-
-    /**
-     * Returns the list of known targets.
-     * <p/>
-     * This is not a copy. Callers must <em>not</em> modify this array.
-     */
-    public IAndroidTarget[] getTargets() {
-        return mTargets;
-    }
-
-    /**
-     * Sets a selection listener. Set it to null to remove it.
-     * The listener will be called <em>after</em> this table processed its selection
-     * events so that the caller can see the updated state.
-     * <p/>
-     * The event's item contains a {@link TableItem}.
-     * The {@link TableItem#getData()} contains an {@link IAndroidTarget}.
-     * <p/>
-     * It is recommended that the caller uses the {@link #getFirstSelected()} and
-     * {@link #getAllSelected()} methods instead.
-     * 
-     * @param selectionListener The new listener or null to remove it.
-     */
-    public void setSelectionListener(SelectionListener selectionListener) {
-        mSelectionListener = selectionListener;
-    }
-    
-    /**
-     * Sets the current target selection.
-     * <p/>
-     * If the selection is actually changed, this will invoke the selection listener
-     * (if any) with a null event.
-     * 
-     * @param target the target to be selection
-     * @return true if the target could be selected, false otherwise.
-     */
-    public boolean setSelection(IAndroidTarget target) {
-        boolean found = false;
-        boolean modified = false;
-        for (TableItem i : mTable.getItems()) {
-            if ((IAndroidTarget) i.getData() == target) {
-                found = true;
-                if (!i.getChecked()) {
-                    modified = true;
-                    i.setChecked(true);
-                }
-            } else if (i.getChecked()) {
-                modified = true;
-                i.setChecked(false);
-            }
-        }
-        
-        if (modified && mSelectionListener != null) {
-            mSelectionListener.widgetSelected(null);
-        }
-        
-        return found;
-    }
-
-    /**
-     * Returns all selected items.
-     * This is useful when the table is in multiple-selection mode.
-     * 
-     * @see #getFirstSelected()
-     * @return An array of selected items. The list can be empty but not null.
-     */
-    public IAndroidTarget[] getAllSelected() {
-        ArrayList<IAndroidTarget> list = new ArrayList<IAndroidTarget>();
-        for (TableItem i : mTable.getItems()) {
-            if (i.getChecked()) {
-                list.add((IAndroidTarget) i.getData());
-            }
-        }
-        return list.toArray(new IAndroidTarget[list.size()]);
-    }
-
-    /**
-     * Returns the first selected item.
-     * This is useful when the table is in single-selection mode.
-     * 
-     * @see #getAllSelected()
-     * @return The first selected item or null.
-     */
-    public IAndroidTarget getFirstSelected() {
-        for (TableItem i : mTable.getItems()) {
-            if (i.getChecked()) {
-                return (IAndroidTarget) i.getData();
-            }
-        }
-        return null;
-    }
-
-    /**
-     * Adds a listener to adjust the columns width when the parent is resized.
-     * <p/>
-     * If we need something more fancy, we might want to use this:
-     * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet77.java?view=co
-     */
-    private void adjustColumnsWidth(final Table table,
-            final TableColumn column0,
-            final TableColumn column1,
-            final TableColumn column2,
-            final TableColumn column3) {
-        // Add a listener to resize the column to the full width of the table
-        table.addControlListener(new ControlAdapter() {
-            @Override
-            public void controlResized(ControlEvent e) {
-                Rectangle r = table.getClientArea();
-                column0.setWidth(r.width * 30 / 100); // 30%  
-                column1.setWidth(r.width * 45 / 100); // 45%
-                column2.setWidth(r.width * 15 / 100); // 15%
-                column3.setWidth(r.width * 10 / 100); // 10%
-            }
-        });
-    }
-
-
-    /**
-     * Creates a selection listener that will check or uncheck the whole line when
-     * double-clicked (aka "the default selection").
-     */
-    private void setupSelectionListener(final Table table) {
-        // Add a selection listener that will check/uncheck items when they are double-clicked
-        table.addSelectionListener(new SelectionListener() {
-            /** Default selection means double-click on "most" platforms */
-            public void widgetDefaultSelected(SelectionEvent e) {
-                if (e.item instanceof TableItem) {
-                    TableItem i = (TableItem) e.item;
-                    i.setChecked(!i.getChecked());
-                    enforceSingleSelection(i);
-                    updateDescription(i);
-                }
-
-                if (mSelectionListener != null) {
-                    mSelectionListener.widgetDefaultSelected(e);
-                }
-            }
-            
-            public void widgetSelected(SelectionEvent e) {
-                if (e.item instanceof TableItem) {
-                    TableItem i = (TableItem) e.item;
-                    enforceSingleSelection(i);
-                    updateDescription(i);
-                }
-
-                if (mSelectionListener != null) {
-                    mSelectionListener.widgetSelected(e);
-                }
-            }
-
-            /**
-             * If we're not in multiple selection mode, uncheck all other
-             * items when this one is selected.
-             */
-            private void enforceSingleSelection(TableItem item) {
-                if (!mAllowMultipleSelection && item.getChecked()) {
-                    Table parentTable = item.getParent();
-                    for (TableItem i2 : parentTable.getItems()) {
-                        if (i2 != item && i2.getChecked()) {
-                            i2.setChecked(false);
-                        }
-                    }
-                }
-            }
-        });
-    }
-
-
-    /**
-     * Fills the table with all SDK targets.
-     * The table columns are:
-     * <ul>
-     * <li>column 0: sdk name
-     * <li>column 1: sdk vendor
-     * <li>column 2: sdk api name
-     * <li>column 3: sdk version
-     * </ul>
-     */
-    private void fillTable(final Table table) {
-        if (mTargets != null && mTargets.length > 0) {
-            table.setEnabled(true);
-            for (IAndroidTarget target : mTargets) {
-                TableItem item = new TableItem(table, SWT.NONE);
-                item.setData(target);
-                item.setText(0, target.getName());
-                item.setText(1, target.getVendor());
-                item.setText(2, target.getApiVersionName());
-                item.setText(3, Integer.toString(target.getApiVersionNumber()));
-            }
-        } else {
-            table.setEnabled(false);
-            TableItem item = new TableItem(table, SWT.NONE);
-            item.setData(null);
-            item.setText(0, "--");
-            item.setText(1, "No target available");
-            item.setText(2, "--");
-            item.setText(3, "--");
-        }
-    }
-
-    /**
-     * Sets up a tooltip that displays the current item description.
-     * <p/>
-     * Displaying a tooltip over the table looks kind of odd here. Instead we actually
-     * display the description in a label under the table.
-     */
-    private void setupTooltip(final Table table) {
-        /*
-         * Reference: 
-         * http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet125.java?view=markup
-         */
-        
-        final Listener listener = new Listener() {
-            public void handleEvent(Event event) {
-                
-                switch(event.type) {
-                case SWT.KeyDown:
-                case SWT.MouseExit:
-                case SWT.MouseDown:
-                    return;
-                    
-                case SWT.MouseHover:
-                    updateDescription(table.getItem(new Point(event.x, event.y)));
-                    break;
-                    
-                case SWT.Selection:
-                    if (event.item instanceof TableItem) {
-                        updateDescription((TableItem) event.item);
-                    }
-                    break;
-                    
-                default:
-                    return;
-                }
-
-            }
-        };
-        
-        table.addListener(SWT.Dispose, listener);
-        table.addListener(SWT.KeyDown, listener);
-        table.addListener(SWT.MouseMove, listener);
-        table.addListener(SWT.MouseHover, listener);
-    }
-
-    /**
-     * Updates the description label with the description of the item's android target, if any.
-     */
-    private void updateDescription(TableItem item) {
-        if (item != null) {
-            Object data = item.getData();
-            if (data instanceof IAndroidTarget) {
-                String newTooltip = ((IAndroidTarget) data).getDescription();
-                mDescription.setText(newTooltip == null ? "" : newTooltip);  //$NON-NLS-1$
-            }
-        }
-    }
-}
diff --git a/tools/sdkstats/.classpath b/tools/sdkstats/.classpath
deleted file mode 100644
index 73b1af5..0000000
--- a/tools/sdkstats/.classpath
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_SWT"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/AndroidPrefs"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/sdkstats/.project b/tools/sdkstats/.project
deleted file mode 100644
index 4dbfa87..0000000
--- a/tools/sdkstats/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>SdkStatsService</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/sdkstats/Android.mk b/tools/sdkstats/Android.mk
deleted file mode 100644
index f4cabdc..0000000
--- a/tools/sdkstats/Android.mk
+++ /dev/null
@@ -1,4 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-SDKSTATS_LOCAL_DIR := $(call my-dir)
-include $(SDKSTATS_LOCAL_DIR)/src/Android.mk
diff --git a/tools/sdkstats/README b/tools/sdkstats/README
deleted file mode 100644
index 8ed0880..0000000
--- a/tools/sdkstats/README
+++ /dev/null
@@ -1,11 +0,0 @@
-How to use the Eclipse projects for SdkStats.
-
-SdkStats requires SWT to compile.
-
-SWT is available in the depot under //device/prebuild/<platform>/swt
-
-Because the build path cannot contain relative path that are not inside the project directory,
-the .classpath file references a user library called ANDROID_SWT.
-
-In order to compile the project, make a user library called ANDROID_SWT containing the jar
-available at //device/prebuild/<platform>/swt.
diff --git a/tools/sdkstats/src/Android.mk b/tools/sdkstats/src/Android.mk
deleted file mode 100644
index bff43f3..0000000
--- a/tools/sdkstats/src/Android.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAVA_LIBRARIES := \
-	androidprefs \
-	swt \
-	org.eclipse.jface_3.2.0.I20060605-1400 \
-	org.eclipse.equinox.common_3.2.0.v20060603 \
-	org.eclipse.core.commands_3.2.0.I20060605-1400
-LOCAL_MODULE := sdkstats
-
-include $(BUILD_HOST_JAVA_LIBRARY)
diff --git a/tools/sdkstats/src/com/android/sdkstats/SdkStatsService.java b/tools/sdkstats/src/com/android/sdkstats/SdkStatsService.java
deleted file mode 100644
index 0b3d41b..0000000
--- a/tools/sdkstats/src/com/android/sdkstats/SdkStatsService.java
+++ /dev/null
@@ -1,416 +0,0 @@
-/*
- * Copyright (C) 2007 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.sdkstats;
-
-import com.android.prefs.AndroidLocation;
-import com.android.prefs.AndroidLocation.AndroidLocationException;
-
-import org.eclipse.jface.preference.PreferenceStore;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.program.Program;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Link;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.net.HttpURLConnection;
-import java.net.URL;
-import java.net.URLEncoder;
-import java.util.Random;
-
-/** Utility class to send "ping" usage reports to the server. */
-public class SdkStatsService {
-
-    /** Minimum interval between ping, in milliseconds. */
-    private static final long PING_INTERVAL_MSEC = 86400 * 1000;  // 1 day
-
-    /* Text strings displayed in the opt-out dialog. */
-    private static final String WINDOW_TITLE_TEXT =
-        "Android SDK";
-
-    private static final String HEADER_TEXT =
-        "Thanks for using the Android SDK!";
-
-    private static final String NOTICE_TEXT =
-        "We know you just want to get started but please read this first.";
-
-    /** Used in the preference pane (PrefsDialog) as well. */
-    public static final String BODY_TEXT =
-        "By choosing to send certain usage statistics to Google, you can " +
-        "help us improve the Android SDK.  These usage statistics let us " +
-        "measure things like active usage of the SDK and let us know things " +
-        "like which versions of the SDK are in use and which tools are the " +
-        "most popular with developers.  This limited data is not associated " +
-        "with personal information about you, is examined on an aggregate " +
-        "basis, and is maintained in accordance with the " +
-        "<a href=\"http://www.google.com/intl/en/privacy.html\">Google " +
-        "Privacy Policy</a>.";
-
-    /** Used in the preference pane (PrefsDialog) as well. */
-    public static final String CHECKBOX_TEXT =
-        "Send usage statistics to Google.";
-
-    private static final String FOOTER_TEXT =
-        "If you later decide to change this setting, you can do so in the " +
-        "\"ddms\" tool under \"File\" > \"Preferences\" > \"Usage Stats\".";
-
-    private static final String BUTTON_TEXT =
-        "   Proceed   ";
-
-    /** List of Linux browser commands to try, in order (see openUrl). */
-    private static final String[] LINUX_BROWSERS = new String[] {
-        "firefox -remote openurl(%URL%,new-window)",  // $NON-NLS-1$ running FF
-        "mozilla -remote openurl(%URL%,new-window)",  // $NON-NLS-1$ running Moz
-        "firefox %URL%",                              // $NON-NLS-1$ new FF
-        "mozilla %URL%",                              // $NON-NLS-1$ new Moz
-        "kfmclient openURL %URL%",                    // $NON-NLS-1$ Konqueror
-        "opera -newwindow %URL%",                     // $NON-NLS-1$ Opera
-    };
-    
-    public final static String PING_OPT_IN = "pingOptIn"; //$NON-NLS-1$
-    public final static String PING_TIME = "pingTime"; //$NON-NLS-1$
-    public final static String PING_ID = "pingId"; //$NON-NLS-1$
-
-
-    private static PreferenceStore sPrefStore;
-    
-    /**
-     * Send a "ping" to the Google toolbar server, if enough time has
-     * elapsed since the last ping, and if the user has not opted out.
-     * If this is the first time, notify the user and offer an opt-out.
-     * Note: UI operations (if any) are synchronous, but the actual ping
-     * (if any) is sent in a <i>non-daemon</i> background thread.
-     *
-     * @param app name to report in the ping
-     * @param version to report in the ping
-     */
-    public static void ping(final String app, final String version) {
-        // Validate the application and version input.
-        final String normalVersion = normalizeVersion(app, version);
-
-        // Unique, randomly assigned ID for this installation.
-        PreferenceStore prefs = getPreferenceStore();
-        if (prefs != null) {
-            if (!prefs.contains(PING_ID)) {
-                // First time: make up a new ID.  TODO: Use something more random?
-                prefs.setValue(PING_ID, new Random().nextLong());
-    
-                // Also give them a chance to opt out.
-                prefs.setValue(PING_OPT_IN, getUserPermission());
-                try {
-                    prefs.save();
-                }
-                catch (IOException ioe) {
-                }
-            }
-    
-            // If the user has not opted in, do nothing and quietly return.
-            if (!prefs.getBoolean(PING_OPT_IN)) {
-                // user opted out.
-                return;
-            }
-    
-            // If the last ping *for this app* was too recent, do nothing.
-            String timePref = PING_TIME + "." + app;  // $NON-NLS-1$
-            long now = System.currentTimeMillis();
-            long then = prefs.getLong(timePref);
-            if (now - then < PING_INTERVAL_MSEC) {
-                // too soon after a ping.
-                return;
-            }
-    
-            // Record the time of the attempt, whether or not it succeeds.
-            prefs.setValue(timePref, now);
-            try {
-                prefs.save();
-            }
-            catch (IOException ioe) {
-            }
-    
-            // Send the ping itself in the background (don't block if the
-            // network is down or slow or confused).
-            final long id = prefs.getLong(PING_ID);
-            new Thread() {
-                @Override
-                public void run() {
-                    try {
-                        actuallySendPing(app, normalVersion, id);
-                    } catch (IOException e) {
-                        e.printStackTrace();
-                    }
-                }
-            }.start();
-        }
-    }
-    
-    /**
-     * Returns the DDMS {@link PreferenceStore}.
-     */
-    public static synchronized PreferenceStore getPreferenceStore() {
-        if (sPrefStore == null) {
-            // get the location of the preferences
-            String homeDir = null;
-            try {
-                homeDir = AndroidLocation.getFolder();
-            } catch (AndroidLocationException e1) {
-                // pass, we'll do a dummy store since homeDir is null
-            }
-
-            if (homeDir != null) {
-                String rcFileName = homeDir + "ddms.cfg"; //$NON-NLS-1$
-                
-                // also look for an old pref file in the previous location
-                String oldPrefPath = System.getProperty("user.home") //$NON-NLS-1$
-                    + File.separator + ".ddmsrc"; //$NON-NLS-1$
-                File oldPrefFile = new File(oldPrefPath);
-                if (oldPrefFile.isFile()) {
-                    try {
-                        PreferenceStore oldStore = new PreferenceStore(oldPrefPath);
-                        oldStore.load();
-                        
-                        oldStore.save(new FileOutputStream(rcFileName), "");
-                        oldPrefFile.delete();
-                        
-                        PreferenceStore newStore = new PreferenceStore(rcFileName);
-                        newStore.load();
-                        sPrefStore = newStore;
-                    } catch (IOException e) {
-                        // create a new empty store.
-                        sPrefStore = new PreferenceStore(rcFileName);
-                    }
-                } else {
-                    sPrefStore = new PreferenceStore(rcFileName);
-
-                    try {
-                        sPrefStore.load();
-                    } catch (IOException e) {
-                        System.err.println("Error Loading Preferences");
-                    }
-                }
-            } else {
-                sPrefStore = new PreferenceStore();
-            }
-        }
-        
-        return sPrefStore;
-    }
-    
-    /**
-     * Unconditionally send a "ping" request to the Google toolbar server.
-     *
-     * @param app name to report in the ping
-     * @param version to report in the ping (dotted numbers, no more than four)
-     * @param id of the local installation
-     * @throws IOException if the ping failed
-     */
-    @SuppressWarnings("deprecation")
-    private static void actuallySendPing(String app, String version, long id)
-        throws IOException {
-        // Detect and report the host OS.
-        String os = System.getProperty("os.name");          // $NON-NLS-1$
-        if (os.startsWith("Mac OS")) {                      // $NON-NLS-1$
-            os = "mac";                                     // $NON-NLS-1$
-        } else if (os.startsWith("Windows")) {              // $NON-NLS-1$
-            os = "win";                                     // $NON-NLS-1$
-        } else if (os.startsWith("Linux")) {                // $NON-NLS-1$
-            os = "linux";                                   // $NON-NLS-1$
-        } else {
-            // Unknown -- surprising -- send it verbatim so we can see it.
-            os = URLEncoder.encode(os);
-        }
-
-        // Include the application's name as part of the as= value.
-        // Share the user ID for all apps, to allow unified activity reports.
-
-        URL url = new URL(
-            "http",                                         // $NON-NLS-1$
-            "tools.google.com",                             // $NON-NLS-1$
-            "/service/update?as=androidsdk_" + app +        // $NON-NLS-1$
-                "&id=" + Long.toHexString(id) +             // $NON-NLS-1$
-                "&version=" + version +                     // $NON-NLS-1$
-                "&os=" + os);                               // $NON-NLS-1$
-
-        // Discard the actual response, but make sure it reads OK
-        HttpURLConnection conn = (HttpURLConnection) url.openConnection();
-
-        // Believe it or not, a 404 response indicates success:
-        // the ping was logged, but no update is configured.
-        if (conn.getResponseCode() != HttpURLConnection.HTTP_OK &&
-            conn.getResponseCode() != HttpURLConnection.HTTP_NOT_FOUND) {
-            throw new IOException(
-                conn.getResponseMessage() + ": " + url);    // $NON-NLS-1$
-        }
-    }
-
-    /**
-     * Prompt the user for whether they want to opt out of reporting.
-     * @return whether the user allows reporting (they do not opt out).
-     */
-    private static boolean getUserPermission() {
-        // Use dialog trim for the shell, but without a close button.
-        final Display display = new Display();
-        final Shell shell = new Shell(display, SWT.TITLE | SWT.BORDER);
-        shell.setText(WINDOW_TITLE_TEXT);
-        shell.setLayout(new GridLayout(1, false));  // 1 column
-
-        // Take the default font and scale it up for the title.
-        final Label title = new Label(shell, SWT.CENTER | SWT.WRAP);
-        final FontData[] fontdata = title.getFont().getFontData();
-        for (int i = 0; i < fontdata.length; i++) {
-            fontdata[i].setHeight(fontdata[i].getHeight() * 4 / 3);
-        }
-        title.setFont(new Font(display, fontdata));
-        title.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        title.setText(HEADER_TEXT);
-
-        final Label notice = new Label(shell, SWT.WRAP);
-        notice.setFont(title.getFont());
-        notice.setForeground(new Color(display, 255, 0, 0));
-        notice.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        notice.setText(NOTICE_TEXT);
-
-        final Link text = new Link(shell, SWT.WRAP);
-        text.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        text.setText(BODY_TEXT);
-        text.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent event) {
-                openUrl(event.text);
-            }
-        });
-
-        final Button checkbox = new Button(shell, SWT.CHECK);
-        checkbox.setSelection(true);  // Opt-in by default.
-        checkbox.setText(CHECKBOX_TEXT);
-
-        final Link footer = new Link(shell, SWT.WRAP);
-        footer.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        footer.setText(FOOTER_TEXT);
-
-        // Whether the user gave permission (size-1 array for writing to).
-        // Initialize to false, set when the user clicks the button.
-        final boolean[] permission = new boolean[] { false };
-
-        final Button button = new Button(shell, SWT.PUSH);
-        button.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_CENTER));
-        button.setText(BUTTON_TEXT);
-        button.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent event) {
-                permission[0] = checkbox.getSelection();
-                shell.close();
-            }
-        });
-
-        // Size the window to a fixed width, as high as necessary, centered.
-        final Point size = shell.computeSize(450, SWT.DEFAULT, true);
-        final Rectangle screen = display.getClientArea();
-        shell.setBounds(
-            screen.x + screen.width / 2 - size.x / 2,
-            screen.y + screen.height / 2 - size.y / 2,
-            size.x, size.y);
-
-        shell.open();
-        while (!shell.isDisposed()) {
-            if (!display.readAndDispatch())
-                display.sleep();
-        }
-
-        display.dispose();  // Otherwise ddms' own Display can't be created
-        return permission[0];
-    }
-
-    /**
-     * Open a URL in an external browser.
-     * @param url to open - MUST be sanitized and properly formed!
-     */
-    public static void openUrl(final String url) {
-        // TODO: consider using something like BrowserLauncher2
-        // (http://browserlaunch2.sourceforge.net/) instead of these hacks.
-
-        // SWT's Program.launch() should work on Mac, Windows, and GNOME
-        // (because the OS shell knows how to launch a default browser).
-        if (!Program.launch(url)) {
-            // Must be Linux non-GNOME (or something else broke).
-            // Try a few Linux browser commands in the background.
-            new Thread() {
-                @Override
-                public void run() {
-                    for (String cmd : LINUX_BROWSERS) {
-                        cmd = cmd.replaceAll("%URL%", url);  // $NON-NLS-1$
-                        try {
-                            Process proc = Runtime.getRuntime().exec(cmd);
-                            if (proc.waitFor() == 0) break;  // Success!
-                        } catch (InterruptedException e) {
-                            // Should never happen!
-                            throw new RuntimeException(e);
-                        } catch (IOException e) {
-                            // Swallow the exception and try the next browser.
-                        }
-                    }
-
-                    // TODO: Pop up some sort of error here?
-                    // (We're in a new thread; can't use the existing Display.)
-                }
-            }.start();
-        }
-    }
-
-    /**
-     * Validate the supplied application version, and normalize the version.
-     * @param app to report
-     * @param version supplied by caller
-     * @return normalized dotted quad version
-     */
-    private static String normalizeVersion(String app, String version) {
-        // Application name must contain only word characters (no punctuaation)
-        if (!app.matches("\\w+")) {
-            throw new IllegalArgumentException("Bad app name: " + app);
-        }
-
-        // Version must be between 1 and 4 dotted numbers
-        String[] numbers = version.split("\\.");
-        if (numbers.length > 4) {
-            throw new IllegalArgumentException("Bad version: " + version);
-        }
-        for (String part: numbers) {
-            if (!part.matches("\\d+")) {
-                throw new IllegalArgumentException("Bad version: " + version);
-            }
-        }
-
-        // Always output 4 numbers, even if fewer were supplied (pad with .0)
-        StringBuffer normal = new StringBuffer(numbers[0]);
-        for (int i = 1; i < 4; i++) {
-            normal.append(".").append(i < numbers.length ? numbers[i] : "0");
-        }
-        return normal.toString();
-    }
-}
diff --git a/tools/traceview/.classpath b/tools/traceview/.classpath
deleted file mode 100644
index e71cb61..0000000
--- a/tools/traceview/.classpath
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.USER_LIBRARY/ANDROID_SWT"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/SdkStatsService"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/tools/traceview/.project b/tools/traceview/.project
deleted file mode 100644
index 692297f..0000000
--- a/tools/traceview/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>traceview</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
diff --git a/tools/traceview/Android.mk b/tools/traceview/Android.mk
deleted file mode 100644
index 2ce7b80..0000000
--- a/tools/traceview/Android.mk
+++ /dev/null
@@ -1,5 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-TRACEVIEW_LOCAL_DIR := $(call my-dir)
-include $(TRACEVIEW_LOCAL_DIR)/etc/Android.mk
-include $(TRACEVIEW_LOCAL_DIR)/src/Android.mk
diff --git a/tools/traceview/README b/tools/traceview/README
deleted file mode 100644
index 6f4576a..0000000
--- a/tools/traceview/README
+++ /dev/null
@@ -1,11 +0,0 @@
-Using the Eclipse projects for traceview.
-
-traceview requires SWT to compile.
-
-SWT is available in the depot under //device/prebuild/<platform>/swt
-
-Because the build path cannot contain relative path that are not inside the project directory,
-the .classpath file references a user library called ANDROID_SWT.
-
-In order to compile the project, make a user library called ANDROID_SWT containing the jar
-available at //device/prebuild/<platform>/swt.
diff --git a/tools/traceview/etc/Android.mk b/tools/traceview/etc/Android.mk
deleted file mode 100644
index f26b19e..0000000
--- a/tools/traceview/etc/Android.mk
+++ /dev/null
@@ -1,8 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_PREBUILT_EXECUTABLES := traceview
-include $(BUILD_HOST_PREBUILT)
-
diff --git a/tools/traceview/etc/manifest.txt b/tools/traceview/etc/manifest.txt
deleted file mode 100644
index 6cdbc7e..0000000
--- a/tools/traceview/etc/manifest.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-Main-Class: com.android.traceview.MainWindow
-Class-Path: swt.jar org.eclipse.equinox.common_3.2.0.v20060603.jar org.eclipse.jface_3.2.0.I20060605-1400.jar org.eclipse.core.commands_3.2.0.I20060605-1400.jar
diff --git a/tools/traceview/etc/traceview b/tools/traceview/etc/traceview
deleted file mode 100755
index 1cc913d..0000000
--- a/tools/traceview/etc/traceview
+++ /dev/null
@@ -1,101 +0,0 @@
-#!/bin/bash
-#
-# Copyright 2005-2006, The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# This script assumes that the path to this script is something like:
-#
-# /somepath/outdir/archdir/hostdir/bindir/traceview
-#
-# where "somepath" is some pathname (like "/work/android/device/")
-#       "outdir"   is a subdirectory (like "out")
-#       "archdir"  is a subdirectory (like "linux-x86-release")
-#       "hostdir"  is a subdirectory (like "host")
-#       "bindir"   is a subdirectory (like "bin")
-#
-# e.g. /work/android/device/out/linux-x86-release/host/bin/traceview
-#
-# and that the following directories also exist:
-#
-# /somepath/outdir/archdir/hostdir/lib/
-# /somepath/outdir/archdir/hostdir/framework/
-#
-# where:
-#       "lib", and "framework" are at the same level as "bindir",
-#        and are the literal names.
-
-# Set up prog to be the path of this script, including following symlinks,
-# and set up progdir to be the fully-qualified pathname of its directory.
-prog="$0"
-while [ -h "${prog}" ]; do
-    newProg=`/bin/ls -ld "${prog}"`
-    newProg=`expr "${newProg}" : ".* -> \(.*\)$"`
-    if expr "x${newProg}" : 'x/' >/dev/null; then
-        prog="${newProg}"
-    else
-        progdir=`dirname "${prog}"`
-        prog="${progdir}/${newProg}"
-    fi
-done
-oldwd=`pwd`
-progdir=`dirname "${prog}"`
-progname=`basename "${prog}"`
-cd "${progdir}"
-progdir=`pwd`
-prog="${progdir}"/"${progname}"
-cd "${oldwd}"
-
-jarfile=traceview.jar
-frameworkdir="$progdir"
-libdir="$progdir"
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/tools/lib
-    libdir=`dirname "$progdir"`/tools/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    frameworkdir=`dirname "$progdir"`/framework
-    libdir=`dirname "$progdir"`/lib
-fi
-if [ ! -r "$frameworkdir/$jarfile" ]
-then
-    echo "${progname}: can't find $jarfile"
-    exit 1
-fi
-
-os=`uname`
-if [ $os == 'Darwin' ]; then
-  javaOpts="-Xmx1600M -XstartOnFirstThread"
-  javaCmd="/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Commands/java"
-else
-  javaOpts="-Xmx1600M"
-  javaCmd="java"
-fi
-
-while expr "x$1" : 'x-J' >/dev/null; do
-    opt=`expr "$1" : '-J\(.*\)'`
-    javaOpts="${javaOpts} -${opt}"
-    shift
-done
-
-if [ "$OSTYPE" = "cygwin" ] ; then
-    jarpath=`cygpath -w  "$frameworkdir/$jarfile"`
-    progdir=`cygpath -w  "$progdir"`
-else
-    jarpath="$frameworkdir/$jarfile"
-fi
-
-
-exec "$javaCmd" $javaOpts -Djava.ext.dirs="$frameworkdir" -Djava.library.path="$libdir" -jar "$jarpath" "$@"
diff --git a/tools/traceview/etc/traceview.bat b/tools/traceview/etc/traceview.bat
deleted file mode 100755
index d074f42..0000000
--- a/tools/traceview/etc/traceview.bat
+++ /dev/null
@@ -1,43 +0,0 @@
-@echo off
-rem Copyright (C) 2007 The Android Open Source Project
-rem
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with the License.
-rem You may obtain a copy of the License at
-rem
-rem      http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-rem don't modify the caller's environment
-setlocal
-
-rem Set up prog to be the path of this script, including following symlinks,
-rem and set up progdir to be the fully-qualified pathname of its directory.
-set prog=%~f0
-
-rem Change current directory to where traceview is, to avoid issues with directories
-rem containing whitespaces.
-cd %~dp0
-
-set jarfile=traceview.jar
-set frameworkdir=
-set libdir=
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=lib\
-    set libdir=lib\
-
-if exist %frameworkdir%%jarfile% goto JarFileOk
-    set frameworkdir=..\framework\
-    set libdir=..\lib\
-
-:JarFileOk
-
-set jarpath=%frameworkdir%%jarfile%
-
-java -Djava.ext.dirs=%frameworkdir% -Djava.library.path=%libdir% -jar %jarpath% %*
diff --git a/tools/traceview/src/Android.mk b/tools/traceview/src/Android.mk
deleted file mode 100644
index 7a006de..0000000
--- a/tools/traceview/src/Android.mk
+++ /dev/null
@@ -1,19 +0,0 @@
-# Copyright 2007 The Android Open Source Project
-#
-LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_JAVA_RESOURCE_DIRS := resources
-
-LOCAL_SRC_FILES := $(call all-subdir-java-files)
-LOCAL_JAR_MANIFEST := ../etc/manifest.txt
-LOCAL_JAVA_LIBRARIES := \
-	androidprefs \
-	sdkstats \
-	swt \
-	org.eclipse.jface_3.2.0.I20060605-1400 \
-	org.eclipse.equinox.common_3.2.0.v20060603 \
-	org.eclipse.core.commands_3.2.0.I20060605-1400
-LOCAL_MODULE := traceview
-
-include $(BUILD_HOST_JAVA_LIBRARY)
diff --git a/tools/traceview/src/com/android/traceview/Call.java b/tools/traceview/src/com/android/traceview/Call.java
deleted file mode 100644
index 40ac244..0000000
--- a/tools/traceview/src/com/android/traceview/Call.java
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import org.eclipse.swt.graphics.Color;
-
-class Call implements TimeLineView.Block {
-    
-    // Values for bits within the mFlags field.
-    private static final int METHOD_ACTION_MASK = 0x3;
-    private static final int IS_RECURSIVE = 0x10;
-
-    private int mThreadId;
-    private int mFlags;
-    MethodData mMethodData;
-    
-    /** 0-based thread-local start time */
-    long mThreadStartTime;
-    
-    /**  global start time */
-    long mGlobalStartTime;
-
-    /** global end time */
-    long mGlobalEndTime;
-    
-    private String mName;
-
-    /**
-     * This constructor is used for the root of a Call tree. The name is
-     * the name of the corresponding thread. 
-     */
-    Call(String name, MethodData methodData) {
-        mName = name;
-        mMethodData = methodData;
-    }
-
-    Call() {
-    }
-    
-    Call(int threadId, MethodData methodData, long time, int methodAction) {
-        mThreadId = threadId;
-        mMethodData = methodData;
-        mThreadStartTime = time;
-        mFlags = methodAction & METHOD_ACTION_MASK;
-        mName = methodData.getProfileName();
-    }
-    
-    public void set(int threadId, MethodData methodData, long time, int methodAction) {
-        mThreadId = threadId;
-        mMethodData = methodData;
-        mThreadStartTime = time;
-        mFlags = methodAction & METHOD_ACTION_MASK;
-        mName = methodData.getProfileName();
-    }
-
-    public void updateName() {
-        mName = mMethodData.getProfileName();
-    }
-
-    public double addWeight(int x, int y, double weight) {
-        return mMethodData.addWeight(x, y, weight);
-    }
-
-    public void clearWeight() {
-        mMethodData.clearWeight();
-    }
-
-    public long getStartTime() {
-        return mGlobalStartTime;
-    }
-
-    public long getEndTime() {
-        return mGlobalEndTime;
-    }
-
-    public Color getColor() {
-        return mMethodData.getColor();
-    }
-
-    public void addExclusiveTime(long elapsed) {
-        mMethodData.addElapsedExclusive(elapsed);
-        if ((mFlags & IS_RECURSIVE) == 0) {
-            mMethodData.addTopExclusive(elapsed);
-        }
-    }
-
-    public void addInclusiveTime(long elapsed, Call parent) {
-        boolean isRecursive = (mFlags & IS_RECURSIVE) != 0;
-        mMethodData.addElapsedInclusive(elapsed, isRecursive, parent);
-    }
-
-    public String getName() {
-        return mName;
-    }
-
-    public void setName(String name) {
-        mName = name;
-    }
-
-    int getThreadId() {
-        return mThreadId;
-    }
-
-    public MethodData getMethodData() {
-        return mMethodData;
-    }
-
-    int getMethodAction() {
-        return mFlags & METHOD_ACTION_MASK;
-    }
-
-    public void dump() {
-        System.out.printf("%s [%d, %d]\n", mName, mGlobalStartTime, mGlobalEndTime);
-    }
-
-    public void setRecursive(boolean isRecursive) {
-        if (isRecursive) {
-            mFlags |= IS_RECURSIVE;
-        } else {
-            mFlags &= ~IS_RECURSIVE;
-        }
-    }
-
-    public boolean isRecursive() {
-        return (mFlags & IS_RECURSIVE) != 0;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ColorController.java b/tools/traceview/src/com/android/traceview/ColorController.java
deleted file mode 100644
index f5e4c0d..0000000
--- a/tools/traceview/src/com/android/traceview/ColorController.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.HashMap;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.widgets.Display;
-
-public class ColorController {
-    private static final int[] systemColors = { SWT.COLOR_BLUE, SWT.COLOR_RED,
-        SWT.COLOR_GREEN, SWT.COLOR_CYAN, SWT.COLOR_MAGENTA, SWT.COLOR_DARK_BLUE,
-        SWT.COLOR_DARK_RED, SWT.COLOR_DARK_GREEN, SWT.COLOR_DARK_YELLOW,
-        SWT.COLOR_DARK_CYAN, SWT.COLOR_DARK_MAGENTA, SWT.COLOR_BLACK };
-
-    private static RGB[] rgbColors = { new RGB(90, 90, 255), // blue
-            new RGB(0, 240, 0), // green
-            new RGB(255, 0, 0), // red
-            new RGB(0, 255, 255), // cyan
-            new RGB(255, 80, 255), // magenta
-            new RGB(200, 200, 0), // yellow
-            new RGB(40, 0, 200), // dark blue
-            new RGB(150, 255, 150), // light green
-            new RGB(150, 0, 0), // dark red
-            new RGB(30, 150, 150), // dark cyan
-            new RGB(200, 200, 255), // light blue
-            new RGB(0, 120, 0), // dark green
-            new RGB(255, 150, 150), // light red
-            new RGB(140, 80, 140), // dark magenta
-            new RGB(150, 100, 50), // brown
-            new RGB(70, 70, 70), // dark grey
-    };
-
-    private static HashMap<Integer, Color> colorCache = new HashMap<Integer, Color>();
-    private static HashMap<Integer, Image> imageCache = new HashMap<Integer, Image>();
-
-    public ColorController() {
-    }
-
-    public static Color requestColor(Display display, RGB rgb) {
-        return requestColor(display, rgb.red, rgb.green, rgb.blue);
-    }
-
-    public static Image requestColorSquare(Display display, RGB rgb) {
-        return requestColorSquare(display, rgb.red, rgb.green, rgb.blue);
-    }
-
-    public static Color requestColor(Display display, int red, int green, int blue) {
-        int key = (red << 16) | (green << 8) | blue;
-        Color color = colorCache.get(key);
-        if (color == null) {
-            color = new Color(display, red, green, blue);
-            colorCache.put(key, color);
-        }
-        return color;
-    }
-
-    public static Image requestColorSquare(Display display, int red, int green, int blue) {
-        int key = (red << 16) | (green << 8) | blue;
-        Image image = imageCache.get(key);
-        if (image == null) {
-            image = new Image(display, 8, 14);
-            GC gc = new GC(image);
-            Color color = requestColor(display, red, green, blue);
-            gc.setBackground(color);
-            gc.fillRectangle(image.getBounds());
-            gc.dispose();
-            imageCache.put(key, image);
-        }
-        return image;
-    }
-
-    public static void assignMethodColors(Display display, MethodData[] methods) {
-        int nextColorIndex = 0;
-        for (MethodData md : methods) {
-            RGB rgb = rgbColors[nextColorIndex];
-            if (++nextColorIndex == rgbColors.length)
-                nextColorIndex = 0;
-            Color color = requestColor(display, rgb);
-            Image image = requestColorSquare(display, rgb);
-            md.setColor(color);
-            md.setImage(image);
-
-            // Compute and set a faded color
-            int fadedRed = 150 + rgb.red / 4;
-            int fadedGreen = 150 + rgb.green / 4;
-            int fadedBlue = 150 + rgb.blue / 4;
-            RGB faded = new RGB(fadedRed, fadedGreen, fadedBlue);
-            color = requestColor(display, faded);
-            image = requestColorSquare(display, faded);
-            md.setFadedColor(color);
-            md.setFadedImage(image);
-        }
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/DmTraceReader.java b/tools/traceview/src/com/android/traceview/DmTraceReader.java
deleted file mode 100644
index 5a19c19..0000000
--- a/tools/traceview/src/com/android/traceview/DmTraceReader.java
+++ /dev/null
@@ -1,602 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.IOException;
-import java.nio.BufferUnderflowException;
-import java.nio.ByteOrder;
-import java.nio.MappedByteBuffer;
-import java.nio.channels.FileChannel;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-public class DmTraceReader extends TraceReader {
-
-    private int mVersionNumber = 0;
-    private boolean mDebug = false;
-    private static final int TRACE_MAGIC = 0x574f4c53;
-    private boolean mRegression;
-    private ProfileProvider mProfileProvider;
-    private String mTraceFileName;
-    private MethodData mTopLevel;
-    private ArrayList<Call> mCallList;
-    private ArrayList<Call> mSwitchList;
-    private HashMap<Integer, MethodData> mMethodMap;
-    private HashMap<Integer, ThreadData> mThreadMap;
-    private ThreadData[] mSortedThreads;
-    private MethodData[] mSortedMethods;
-    private long mGlobalEndTime;
-    private MethodData mContextSwitch;
-    private int mOffsetToData;
-    private byte[] mBytes = new byte[8];
-
-    // A regex for matching the thread "id name" lines in the .key file
-    private static final Pattern mIdNamePattern = Pattern.compile("(\\d+)\t(.*)");  // $NON-NLS-1$
-
-    DmTraceReader(String traceFileName, boolean regression) {
-        mTraceFileName = traceFileName;
-        mRegression = regression;
-        mMethodMap = new HashMap<Integer, MethodData>();
-        mThreadMap = new HashMap<Integer, ThreadData>();
-
-        // Create a single top-level MethodData object to hold the profile data
-        // for time spent in the unknown caller.
-        mTopLevel = new MethodData(0, "(toplevel)");
-        mContextSwitch = new MethodData(-1, "(context switch)");
-        mMethodMap.put(0, mTopLevel);
-        generateTrees();
-        // dumpTrees();
-    }
-
-    void generateTrees() {
-        try {
-            long offset = parseKeys();
-            parseData(offset);
-            analyzeData();
-        } catch (IOException e) {
-            System.err.println(e.getMessage());
-            System.exit(1);
-        }
-    }
-
-    @Override
-    public ProfileProvider getProfileProvider() {
-        if (mProfileProvider == null)
-            mProfileProvider = new ProfileProvider(this);
-        return mProfileProvider;
-    }
-
-    Call readCall(MappedByteBuffer buffer, Call call) {
-        int threadId;
-        int methodId;
-        long time;
-        
-        try {
-            if (mVersionNumber == 1)
-                threadId = buffer.get();
-            else
-                threadId = buffer.getShort();
-            methodId = buffer.getInt();
-            time = buffer.getInt();
-        } catch (BufferUnderflowException ex) {
-            return null;
-        }
-        
-        int methodAction = methodId & 0x03;
-        methodId = methodId & ~0x03;
-        MethodData methodData = mMethodMap.get(methodId);
-        if (methodData == null) {
-            String name = String.format("(0x%1$x)", methodId);  // $NON-NLS-1$
-            methodData = new MethodData(methodId, name);
-        }
-        
-        if (call != null) {
-            call.set(threadId, methodData, time, methodAction);
-        } else {
-            call = new Call(threadId, methodData, time, methodAction);
-        }
-        return call;
-    }
-    
-    private MappedByteBuffer mapFile(String filename, long offset) {
-        MappedByteBuffer buffer = null;
-        try {
-            FileInputStream dataFile = new FileInputStream(filename);
-            File file = new File(filename);
-            FileChannel fc = dataFile.getChannel();
-            buffer = fc.map(FileChannel.MapMode.READ_ONLY, offset, file.length() - offset);
-            buffer.order(ByteOrder.LITTLE_ENDIAN);
-        } catch (FileNotFoundException ex) {
-            System.err.println(ex.getMessage());
-            System.exit(1);
-        } catch (IOException ex) {
-            System.err.println(ex.getMessage());
-            System.exit(1);
-        }
-        
-        return buffer;
-    }
-    
-    private void readDataFileHeader(MappedByteBuffer buffer) {
-        int magic = buffer.getInt();
-        if (magic != TRACE_MAGIC) {
-            System.err.printf(
-                    "Error: magic number mismatch; got 0x%x, expected 0x%x\n",
-                    magic, TRACE_MAGIC);
-            throw new RuntimeException();
-        }
-        // read version
-        int version = buffer.getShort();
-        
-        // read offset
-        mOffsetToData = buffer.getShort() - 16;
-        
-        // read startWhen
-        buffer.getLong();
-        
-        // Skip over "mOffsetToData" bytes
-        for (int ii = 0; ii < mOffsetToData; ii++) {
-            buffer.get();
-        }
-        
-        // Save this position so that we can re-read the data later
-        buffer.mark();
-    }
-
-    private void parseData(long offset) {
-        MappedByteBuffer buffer = mapFile(mTraceFileName, offset);
-        readDataFileHeader(buffer);
-        parseDataPass1(buffer);
-        
-        buffer.reset();
-        parseDataPass2(buffer);
-    }
-    
-    private void parseDataPass1(MappedByteBuffer buffer) {
-        mSwitchList = new ArrayList<Call>();
-
-        // Read the first call so that we can set "prevThreadData"
-        Call call = new Call();
-        call = readCall(buffer, call);
-        if (call == null)
-            return;
-        long callTime = call.mThreadStartTime;
-        long prevCallTime = 0;
-        ThreadData threadData = mThreadMap.get(call.getThreadId());
-        if (threadData == null) {
-            String name = String.format("[%1$d]", call.getThreadId());  // $NON-NLS-1$
-            threadData = new ThreadData(call.getThreadId(), name, mTopLevel);
-            mThreadMap.put(call.getThreadId(), threadData);
-        }
-        ThreadData prevThreadData = threadData;
-        while (true) {
-            // If a context switch occurred, then insert a placeholder "call"
-            // record so that we can do something reasonable with the global
-            // timestamps.
-            if (prevThreadData != threadData) {
-                Call switchEnter = new Call(prevThreadData.getId(),
-                        mContextSwitch, prevCallTime, 0);
-                prevThreadData.setLastContextSwitch(switchEnter);
-                mSwitchList.add(switchEnter);
-                Call contextSwitch = threadData.getLastContextSwitch();
-                if (contextSwitch != null) {
-                    long prevStartTime = contextSwitch.mThreadStartTime;
-                    long elapsed = callTime - prevStartTime;
-                    long beforeSwitch = elapsed / 2;
-                    long afterSwitch = elapsed - beforeSwitch;
-                    long exitTime = callTime - afterSwitch;
-                    contextSwitch.mThreadStartTime = prevStartTime + beforeSwitch;
-                    Call switchExit = new Call(threadData.getId(),
-                            mContextSwitch, exitTime, 1);
-                    
-                    mSwitchList.add(switchExit);
-                }
-                prevThreadData = threadData;
-            }
-
-            // Read the next call
-            call = readCall(buffer, call);
-            if (call == null) {
-                break;
-            }
-            prevCallTime = callTime;
-            callTime = call.mThreadStartTime;
-
-            threadData = mThreadMap.get(call.getThreadId());
-            if (threadData == null) {
-                String name = String.format("[%d]", call.getThreadId());
-                threadData = new ThreadData(call.getThreadId(), name, mTopLevel);
-                mThreadMap.put(call.getThreadId(), threadData);
-            }
-        }
-    }
-
-    void parseDataPass2(MappedByteBuffer buffer) {
-        mCallList = new ArrayList<Call>();
-
-        // Read the first call so that we can set "prevThreadData"
-        Call call = readCall(buffer, null);
-        long callTime = call.mThreadStartTime;
-        long prevCallTime = callTime;
-        ThreadData threadData = mThreadMap.get(call.getThreadId());
-        ThreadData prevThreadData = threadData;
-        threadData.setGlobalStartTime(0);
-        
-        int nthContextSwitch = 0;
-
-        // Assign a global timestamp to each event.
-        long globalTime = 0;
-        while (true) {
-            long elapsed = callTime - prevCallTime;
-            if (threadData != prevThreadData) {
-                // Get the next context switch.  This one is entered
-                // by the previous thread.
-                Call contextSwitch = mSwitchList.get(nthContextSwitch++);
-                mCallList.add(contextSwitch);
-                elapsed = contextSwitch.mThreadStartTime - prevCallTime;
-                globalTime += elapsed;
-                elapsed = 0;
-                contextSwitch.mGlobalStartTime = globalTime;
-                prevThreadData.handleCall(contextSwitch, globalTime);
-                
-                if (!threadData.isEmpty()) {
-                    // This context switch is exited by the current thread.
-                    contextSwitch = mSwitchList.get(nthContextSwitch++);
-                    mCallList.add(contextSwitch);
-                    contextSwitch.mGlobalStartTime = globalTime;
-                    elapsed = callTime - contextSwitch.mThreadStartTime;
-                    threadData.handleCall(contextSwitch, globalTime);
-                }
-
-                // If the thread's global start time has not been set yet,
-                // then set it.
-                if (threadData.getGlobalStartTime() == -1)
-                    threadData.setGlobalStartTime(globalTime);
-                prevThreadData = threadData;
-            }
-
-            globalTime += elapsed;
-            call.mGlobalStartTime = globalTime;
-            
-            threadData.handleCall(call, globalTime);
-            mCallList.add(call);
-            
-            // Read the next call
-            call = readCall(buffer, null);
-            if (call == null) {
-                break;
-            }
-            prevCallTime = callTime;
-            callTime = call.mThreadStartTime;
-            threadData = mThreadMap.get(call.getThreadId());
-        }
-
-        // Allow each thread to do any cleanup of the call stack.
-        // Also add the elapsed time for each thread to the toplevel
-        // method's inclusive time.
-        for (int id : mThreadMap.keySet()) {
-            threadData = mThreadMap.get(id);
-            long endTime = threadData.endTrace();
-            if (endTime > 0)
-                mTopLevel.addElapsedInclusive(endTime, false, null);
-        }
-
-        mGlobalEndTime = globalTime;
-        
-        if (mRegression) {
-            dumpCallTimes();
-        }
-    }
-
-    static final int PARSE_VERSION = 0;
-    static final int PARSE_THREADS = 1;
-    static final int PARSE_METHODS = 2;
-    static final int PARSE_OPTIONS = 4;
-
-    long parseKeys() throws IOException {
-        BufferedReader in = null;
-        try {
-            in = new BufferedReader(new FileReader(mTraceFileName));
-        } catch (FileNotFoundException ex) {
-            System.err.println(ex.getMessage());
-        }
-
-        long offset = 0;
-        int mode = PARSE_VERSION;
-        String line = null;
-        while (true) {
-            line = in.readLine();
-            if (line == null) {
-                throw new IOException("Key section does not have an *end marker");
-            }
-            
-            // Calculate how much we have read from the file so far.  The
-            // extra byte is for the line ending not included by readLine().
-            offset += line.length() + 1;
-            if (line.startsWith("*")) {
-                if (line.equals("*version")) {
-                    mode = PARSE_VERSION;
-                    continue;
-                }
-                if (line.equals("*threads")) {
-                    mode = PARSE_THREADS;
-                    continue;
-                }
-                if (line.equals("*methods")) {
-                    mode = PARSE_METHODS;
-                    continue;
-                }
-                if (line.equals("*end")) {
-                    return offset;
-                }
-            }
-            switch (mode) {
-            case PARSE_VERSION:
-                mVersionNumber = Integer.decode(line);
-                mode = PARSE_OPTIONS;
-                break;
-            case PARSE_THREADS:
-                parseThread(line);
-                break;
-            case PARSE_METHODS:
-                parseMethod(line);
-                break;
-            case PARSE_OPTIONS:
-                break;
-            }
-        }
-    }
-
-    void parseThread(String line) {
-        String idStr = null;
-        String name = null;
-        Matcher matcher = mIdNamePattern.matcher(line);
-        if (matcher.find()) {
-            idStr = matcher.group(1);
-            name = matcher.group(2);
-        }
-        if (idStr == null) return;
-        if (name == null) name = "(unknown)";
-
-        int id = Integer.decode(idStr);
-        mThreadMap.put(id, new ThreadData(id, name, mTopLevel));
-    }
-
-    void parseMethod(String line) {
-        String[] tokens = line.split("\t");
-        int id = Long.decode(tokens[0]).intValue();
-        String className = tokens[1];
-        String methodName = null;
-        String signature = null;
-        String pathname = null;
-        int lineNumber = -1;
-        if (tokens.length == 6) {
-            methodName = tokens[2];
-            signature = tokens[3];
-            pathname = tokens[4];
-            lineNumber = Integer.decode(tokens[5]);
-            pathname = constructPathname(className, pathname);
-        } else if (tokens.length > 2) {
-            if (tokens[3].startsWith("(")) {
-                methodName = tokens[2];
-                signature = tokens[3];
-            } else {
-                pathname = tokens[2];
-                lineNumber = Integer.decode(tokens[3]);
-            }
-        }
-
-        mMethodMap.put(id, new MethodData(id, className, methodName, signature,
-                pathname, lineNumber));
-    }
-
-    private String constructPathname(String className, String pathname) {
-        int index = className.lastIndexOf('/');
-        if (index > 0 && index < className.length() - 1
-                && pathname.endsWith(".java"))
-            pathname = className.substring(0, index + 1) + pathname;
-        return pathname;
-    }
-
-    private void analyzeData() {
-        // Sort the threads into decreasing cpu time
-        Collection<ThreadData> tv = mThreadMap.values();
-        mSortedThreads = tv.toArray(new ThreadData[tv.size()]);
-        Arrays.sort(mSortedThreads, new Comparator<ThreadData>() {
-            public int compare(ThreadData td1, ThreadData td2) {
-                if (td2.getCpuTime() > td1.getCpuTime())
-                    return 1;
-                if (td2.getCpuTime() < td1.getCpuTime())
-                    return -1;
-                return td2.getName().compareTo(td1.getName());
-            }
-        });
-
-        // Analyze the call tree so that we can label the "worst" children.
-        // Also set all the root pointers in each node in the call tree.
-        long sum = 0;
-        for (ThreadData t : mSortedThreads) {
-            if (t.isEmpty() == false) {
-                Call root = t.getCalltreeRoot();
-                root.mGlobalStartTime = t.getGlobalStartTime();
-            }
-        }
-
-        // Sort the methods into decreasing inclusive time
-        Collection<MethodData> mv = mMethodMap.values();
-        MethodData[] methods;
-        methods = mv.toArray(new MethodData[mv.size()]);
-        Arrays.sort(methods, new Comparator<MethodData>() {
-            public int compare(MethodData md1, MethodData md2) {
-                if (md2.getElapsedInclusive() > md1.getElapsedInclusive())
-                    return 1;
-                if (md2.getElapsedInclusive() < md1.getElapsedInclusive())
-                    return -1;
-                return md1.getName().compareTo(md2.getName());
-            }
-        });
-
-        // Count the number of methods with non-zero inclusive time
-        int nonZero = 0;
-        for (MethodData md : methods) {
-            if (md.getElapsedInclusive() == 0)
-                break;
-            nonZero += 1;
-        }
-
-        // Copy the methods with non-zero time
-        mSortedMethods = new MethodData[nonZero];
-        int ii = 0;
-        for (MethodData md : methods) {
-            if (md.getElapsedInclusive() == 0)
-                break;
-            md.setRank(ii);
-            mSortedMethods[ii++] = md;
-        }
-
-        // Let each method analyze its profile data
-        for (MethodData md : mSortedMethods) {
-            md.analyzeData();
-        }
-
-        // Update all the calls to include the method rank in
-        // their name.
-        for (Call call : mCallList) {
-            call.updateName();
-        }
-        
-        if (mRegression) {
-            dumpMethodStats();
-        }
-    }
-
-    /*
-     * This method computes a list of records that describe the the execution
-     * timeline for each thread. Each record is a pair: (row, block) where: row:
-     * is the ThreadData object block: is the call (containing the start and end
-     * times)
-     */
-    @Override
-    public ArrayList<TimeLineView.Record> getThreadTimeRecords() {
-        TimeLineView.Record record;
-        ArrayList<TimeLineView.Record> timeRecs;
-        timeRecs = new ArrayList<TimeLineView.Record>();
-
-        // For each thread, push a "toplevel" call that encompasses the
-        // entire execution of the thread.
-        for (ThreadData threadData : mSortedThreads) {
-            if (!threadData.isEmpty() && threadData.getId() != 0) {
-                Call call = new Call(threadData.getId(), mTopLevel,
-                        threadData.getGlobalStartTime(), 0);
-                call.mGlobalStartTime = threadData.getGlobalStartTime();
-                call.mGlobalEndTime = threadData.getGlobalEndTime();
-                record = new TimeLineView.Record(threadData, call);
-                timeRecs.add(record);
-            }
-        }
-
-        for (Call call : mCallList) {
-            if (call.getMethodAction() != 0 || call.getThreadId() == 0)
-                continue;
-            ThreadData threadData = mThreadMap.get(call.getThreadId());
-            record = new TimeLineView.Record(threadData, call);
-            timeRecs.add(record);
-        }
-        
-        if (mRegression) {
-            dumpTimeRecs(timeRecs);
-            System.exit(0);
-        }
-        return timeRecs;
-    }
-        
-    private void dumpCallTimes() {
-        String action;
-        
-        System.out.format("id thread  global start,end   method\n");
-        for (Call call : mCallList) {
-            if (call.getMethodAction() == 0) {
-                action = "+";
-            } else {
-                action = " ";
-            }
-            long callTime = call.mThreadStartTime;
-            System.out.format("%2d %6d %8d %8d %s %s\n",
-                    call.getThreadId(), callTime, call.mGlobalStartTime,
-                    call.mGlobalEndTime, action, call.getMethodData().getName());
-//            if (call.getMethodAction() == 0 && call.getGlobalEndTime() < call.getGlobalStartTime()) {
-//                System.out.printf("endtime %d < startTime %d\n",
-//                        call.getGlobalEndTime(), call.getGlobalStartTime());
-//            }
-        }
-    }
-    
-    private void dumpMethodStats() {
-        System.out.format("\nExclusive Inclusive     Calls  Method\n");
-        for (MethodData md : mSortedMethods) {
-            System.out.format("%9d %9d %9s  %s\n",
-                    md.getElapsedExclusive(), md.getElapsedInclusive(),
-                    md.getCalls(), md.getProfileName());
-        }
-    }
-
-    private void dumpTimeRecs(ArrayList<TimeLineView.Record> timeRecs) {
-        System.out.format("\nid thread  global start,end  method\n");
-        for (TimeLineView.Record record : timeRecs) {
-            Call call = (Call) record.block;
-            long callTime = call.mThreadStartTime;
-            System.out.format("%2d %6d %8d %8d  %s\n",
-                    call.getThreadId(), callTime,
-                    call.mGlobalStartTime, call.mGlobalEndTime,
-                    call.getMethodData().getName());
-        }
-    }
-
-    @Override
-    public HashMap<Integer, String> getThreadLabels() {
-        HashMap<Integer, String> labels = new HashMap<Integer, String>();
-        for (ThreadData t : mThreadMap.values()) {
-            labels.put(t.getId(), t.getName());
-        }
-        return labels;
-    }
-
-    @Override
-    public MethodData[] getMethods() {
-        return mSortedMethods;
-    }
-
-    @Override
-    public ThreadData[] getThreads() {
-        return mSortedThreads;
-    }
-
-    @Override
-    public long getEndTime() {
-        return mGlobalEndTime;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/MainWindow.java b/tools/traceview/src/com/android/traceview/MainWindow.java
deleted file mode 100644
index b0c24e9..0000000
--- a/tools/traceview/src/com/android/traceview/MainWindow.java
+++ /dev/null
@@ -1,192 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import com.android.sdkstats.SdkStatsService;
-
-import org.eclipse.jface.window.ApplicationWindow;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.SashForm;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-
-import java.io.File;
-import java.io.IOException;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.nio.channels.FileChannel;
-import java.util.HashMap;
-
-public class MainWindow extends ApplicationWindow {
-    
-    private final static String PING_NAME = "Traceview";
-    private final static String PING_VERSION = "1.0";
-
-    private TraceReader mReader;
-    private String mTraceName;
-
-    // A global cache of string names.
-    public static HashMap<String, String> sStringCache = new HashMap<String, String>();
-
-    public MainWindow(String traceName, TraceReader reader) {
-        super(null);
-        mReader = reader;
-        mTraceName = traceName;
-    }
-
-    public void run() {
-        setBlockOnOpen(true);
-        open();
-        Display.getCurrent().dispose();
-    }
-
-    @Override
-    protected void configureShell(Shell shell) {
-        super.configureShell(shell);
-        shell.setText("Traceview: " + mTraceName);
-        shell.setBounds(100, 10, 1282, 900);
-    }
-
-    @Override
-    protected Control createContents(Composite parent) {
-        ColorController.assignMethodColors(parent.getDisplay(), mReader.getMethods());
-        SelectionController selectionController = new SelectionController();
-
-        GridLayout gridLayout = new GridLayout(1, false);
-        gridLayout.marginWidth = 0;
-        gridLayout.marginHeight = 0;
-        gridLayout.horizontalSpacing = 0;
-        gridLayout.verticalSpacing = 0;
-        parent.setLayout(gridLayout);
-
-        Display display = parent.getDisplay();
-        Color darkGray = display.getSystemColor(SWT.COLOR_DARK_GRAY);
-
-        // Create a sash form to separate the timeline view (on top)
-        // and the profile view (on bottom)
-        SashForm sashForm1 = new SashForm(parent, SWT.VERTICAL);
-        sashForm1.setBackground(darkGray);
-        sashForm1.SASH_WIDTH = 3;
-        GridData data = new GridData(GridData.FILL_BOTH);
-        sashForm1.setLayoutData(data);
-
-        // Create the timeline view
-        new TimeLineView(sashForm1, mReader, selectionController);
-
-        // Create the profile view
-        new ProfileView(sashForm1, mReader, selectionController);
-        return sashForm1;
-    }
-
-    /**
-     * Convert the old two-file format into the current concatenated one.
-     * 
-     * @param base Base path of the two files, i.e. base.key and base.data
-     * @return Path to a temporary file that will be deleted on exit.
-     * @throws IOException 
-     */
-    private static String makeTempTraceFile(String base) throws IOException {
-        // Make a temporary file that will go away on exit and prepare to
-        // write into it.
-        File temp = File.createTempFile(base, ".trace");
-        temp.deleteOnExit();
-        FileChannel dstChannel = new FileOutputStream(temp).getChannel();
-
-        // First copy the contents of the key file into our temp file.
-        FileChannel srcChannel = new FileInputStream(base + ".key").getChannel();
-        long size = dstChannel.transferFrom(srcChannel, 0, srcChannel.size());
-        srcChannel.close();
-
-        // Then concatenate the data file.
-        srcChannel = new FileInputStream(base + ".data").getChannel();
-        dstChannel.transferFrom(srcChannel, size, srcChannel.size());
-
-        // Clean up.
-        srcChannel.close();
-        dstChannel.close();
-
-        // Return the path of the temp file.
-        return temp.getPath();
-    }
-    
-    public static void main(String[] args) {
-        TraceReader reader = null;
-        boolean regression = false;
-        
-        // ping the usage server
-        SdkStatsService.ping(PING_NAME, PING_VERSION);
-
-        // Process command line arguments
-        int argc = 0;
-        int len = args.length;
-        while (argc < len) {
-            String arg = args[argc];
-            if (arg.charAt(0) != '-') {
-                break;
-            }
-            if (arg.equals("-r")) {
-                regression = true;
-            } else {
-                break;
-            }
-            argc++;
-        }
-        if (argc != len - 1) {
-            System.out.printf("Usage: java %s [-r] trace%n", MainWindow.class.getName());
-            System.out.printf("  -r   regression only%n");
-            return;
-        }
-
-        String traceName = args[len - 1];
-        File file = new File(traceName);
-        if (file.exists() && file.isDirectory()) {
-            System.out.printf("Qemu trace files not supported yet.\n");
-            System.exit(1);
-            // reader = new QtraceReader(traceName);
-        } else {
-            // If the filename as given doesn't exist...
-            if (!file.exists()) {
-                // Try appending .trace.
-                if (new File(traceName + ".trace").exists()) {
-                    traceName = traceName + ".trace";
-                // Next, see if it is the old two-file trace.
-                } else if (new File(traceName + ".data").exists()
-                    && new File(traceName + ".key").exists()) {
-                    try {
-                        traceName = makeTempTraceFile(traceName);
-                    } catch (IOException e) {
-                        System.err.printf("cannot convert old trace file '%s'\n", traceName);
-                        System.exit(1);
-                    }
-                // Otherwise, give up.
-                } else {
-                    System.err.printf("trace file '%s' not found\n", traceName);
-                    System.exit(1);
-                }
-            }
-
-            reader = new DmTraceReader(traceName, regression);
-        }
-        reader.getTraceUnits().setTimeScale(TraceUnits.TimeScale.MilliSeconds);
-        new MainWindow(traceName, reader).run();
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/MethodData.java b/tools/traceview/src/com/android/traceview/MethodData.java
deleted file mode 100644
index 0bc9853..0000000
--- a/tools/traceview/src/com/android/traceview/MethodData.java
+++ /dev/null
@@ -1,458 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Comparator;
-import java.util.HashMap;
-
-public class MethodData {
-
-    private int mId;
-    private int mRank = -1;
-    private String mClassName;
-    private String mMethodName;
-    private String mSignature;
-    private String mName;
-    private String mProfileName;
-    private String mPathname;
-    private int mLineNumber;
-    private long mElapsedExclusive;
-    private long mElapsedInclusive;
-    private long mTopExclusive;
-    private int[] mNumCalls = new int[2]; // index 0=normal, 1=recursive
-    private Color mColor;
-    private Color mFadedColor;
-    private Image mImage;
-    private Image mFadedImage;
-    private HashMap<Integer, ProfileData> mParents;
-    private HashMap<Integer, ProfileData> mChildren;
-    
-    // The parents of this method when this method was in a recursive call
-    private HashMap<Integer, ProfileData> mRecursiveParents;
-    
-    // The children of this method when this method was in a recursive call
-    private HashMap<Integer, ProfileData> mRecursiveChildren;
-
-    private ProfileNode[] mProfileNodes;
-    private int mX;
-    private int mY;
-    private double mWeight;
-
-    public MethodData(int id, String className) {
-        mId = id;
-        mClassName = className;
-        mMethodName = null;
-        mSignature = null;
-        mPathname = null;
-        mLineNumber = -1;
-        computeName();
-        computeProfileName();
-    }
-
-    public MethodData(int id, String className, String methodName,
-            String signature, String pathname, int lineNumber) {
-        mId = id;
-        mClassName = className;
-        mMethodName = methodName;
-        mSignature = signature;
-        mPathname = pathname;
-        mLineNumber = lineNumber;
-        computeName();
-        computeProfileName();
-    }
-
-    private Comparator<ProfileData> mByElapsedInclusive = new Comparator<ProfileData>() {
-        public int compare(ProfileData pd1, ProfileData pd2) {
-            if (pd2.getElapsedInclusive() > pd1.getElapsedInclusive())
-                return 1;
-            if (pd2.getElapsedInclusive() < pd1.getElapsedInclusive())
-                return -1;
-            return 0;
-        }
-    };
-
-    public double addWeight(int x, int y, double weight) {
-        if (mX == x && mY == y)
-            mWeight += weight;
-        else {
-            mX = x;
-            mY = y;
-            mWeight = weight;
-        }
-        return mWeight;
-    }
-
-    public void clearWeight() {
-        mWeight = 0;
-    }
-
-    public int getRank() {
-        return mRank;
-    }
-
-    public void setRank(int rank) {
-        mRank = rank;
-        computeProfileName();
-    }
-
-    public void addElapsedExclusive(long time) {
-        mElapsedExclusive += time;
-    }
-
-    public void addElapsedInclusive(long time, boolean isRecursive, Call parent) {
-        if (isRecursive == false) {
-            mElapsedInclusive += time;
-            mNumCalls[0] += 1;
-        } else {
-            mNumCalls[1] += 1;
-        }
-
-        if (parent == null)
-            return;
-
-        // Find the child method in the parent
-        MethodData parentMethod = parent.mMethodData;
-        if (parent.isRecursive()) {
-            parentMethod.mRecursiveChildren = updateInclusive(time,
-                    parentMethod, this, false,
-                    parentMethod.mRecursiveChildren);
-        } else {
-            parentMethod.mChildren = updateInclusive(time,
-                    parentMethod, this, false, parentMethod.mChildren);
-        }
-
-        // Find the parent method in the child
-        if (isRecursive) {
-            mRecursiveParents = updateInclusive(time, this, parentMethod, true,
-                    mRecursiveParents);
-        } else {
-            mParents = updateInclusive(time, this, parentMethod, true,
-                    mParents);
-        }
-    }
-    
-    private HashMap<Integer, ProfileData> updateInclusive(long time,
-            MethodData contextMethod, MethodData elementMethod,
-            boolean elementIsParent, HashMap<Integer, ProfileData> map) {
-        if (map == null) {
-            map = new HashMap<Integer, ProfileData>(4);
-        } else {
-            ProfileData profileData = map.get(elementMethod.mId);
-            if (profileData != null) {
-                profileData.addElapsedInclusive(time);
-                return map;
-            }
-        }
-
-        ProfileData elementData = new ProfileData(contextMethod,
-                elementMethod, elementIsParent);
-        elementData.setElapsedInclusive(time);
-        elementData.setNumCalls(1);
-        map.put(elementMethod.mId, elementData);
-        return map;
-    }
-
-    public void analyzeData() {
-        // Sort the parents and children into decreasing inclusive time
-        ProfileData[] sortedParents;
-        ProfileData[] sortedChildren;
-        ProfileData[] sortedRecursiveParents;
-        ProfileData[] sortedRecursiveChildren;
-        
-        sortedParents = sortProfileData(mParents);
-        sortedChildren = sortProfileData(mChildren);
-        sortedRecursiveParents = sortProfileData(mRecursiveParents);
-        sortedRecursiveChildren = sortProfileData(mRecursiveChildren);
-        
-        // Add "self" time to the top of the sorted children
-        sortedChildren = addSelf(sortedChildren);
-        
-        // Create the ProfileNode objects that we need
-        ArrayList<ProfileNode> nodes = new ArrayList<ProfileNode>();
-        ProfileNode profileNode;
-        if (mParents != null) {
-            profileNode = new ProfileNode("Parents", this, sortedParents,
-                    true, false);
-            nodes.add(profileNode);
-        }
-        if (mChildren != null) {
-            profileNode = new ProfileNode("Children", this, sortedChildren,
-                    false, false);
-            nodes.add(profileNode);
-        }
-        if (mRecursiveParents!= null) {
-            profileNode = new ProfileNode("Parents while recursive", this,
-                    sortedRecursiveParents, true, true);
-            nodes.add(profileNode);
-        }
-        if (mRecursiveChildren != null) {
-            profileNode = new ProfileNode("Children while recursive", this,
-                    sortedRecursiveChildren, false, true);
-            nodes.add(profileNode);
-        }
-        mProfileNodes = nodes.toArray(new ProfileNode[nodes.size()]);
-    }
-    
-    // Create and return a ProfileData[] array that is a sorted copy
-    // of the given HashMap values.
-    private ProfileData[] sortProfileData(HashMap<Integer, ProfileData> map) {
-        if (map == null)
-            return null;
-
-        // Convert the hash values to an array of ProfileData
-        Collection<ProfileData> values = map.values();
-        ProfileData[] sorted = values.toArray(new ProfileData[values.size()]);
-        
-        // Sort the array by elapsed inclusive time
-        Arrays.sort(sorted, mByElapsedInclusive);
-        return sorted;
-    }
-    
-    private ProfileData[] addSelf(ProfileData[] children) {
-        ProfileData[] pdata;
-        if (children == null) {
-            pdata = new ProfileData[1];
-        } else {
-            pdata = new ProfileData[children.length + 1];
-            System.arraycopy(children, 0, pdata, 1, children.length);
-        }
-        pdata[0] = new ProfileSelf(this);
-        return pdata;
-    }
-
-    public void addTopExclusive(long time) {
-        mTopExclusive += time;
-    }
-
-    public long getTopExclusive() {
-        return mTopExclusive;
-    }
-
-    public int getId() {
-        return mId;
-    }
-
-    private void computeName() {
-        if (mMethodName == null) {
-            mName = mClassName;
-            return;
-        }
-
-        StringBuilder sb = new StringBuilder();
-        sb.append(mClassName);
-        sb.append(".");  //$NON-NLS-1$
-        sb.append(mMethodName);
-        sb.append(" ");  //$NON-NLS-1$
-        sb.append(mSignature);
-        mName = sb.toString();
-    }
-
-    public String getName() {
-        return mName;
-    }
-
-    public String getClassName() {
-        return mClassName;
-    }
-
-    public String getMethodName() {
-        return mMethodName;
-    }
-
-    public String getProfileName() {
-        return mProfileName;
-    }
-
-    public void computeProfileName() {
-        if (mRank == -1) {
-            mProfileName = mName;
-            return;
-        }
-        
-        StringBuilder sb = new StringBuilder();
-        sb.append(mRank);
-        sb.append(" ");  //$NON-NLS-1$
-        sb.append(getName());
-        mProfileName = sb.toString();
-    }
-
-    public String getCalls() {
-        return String.format("%d+%d", mNumCalls[0], mNumCalls[1]);
-    }
-
-    public int getTotalCalls() {
-        return mNumCalls[0] + mNumCalls[1];
-    }
-
-    public Color getColor() {
-        return mColor;
-    }
-
-    public void setColor(Color color) {
-        mColor = color;
-    }
-
-    public void setImage(Image image) {
-        mImage = image;
-    }
-
-    public Image getImage() {
-        return mImage;
-    }
-
-    @Override
-    public String toString() {
-        return getName();
-    }
-
-    public long getElapsedExclusive() {
-        return mElapsedExclusive;
-    }
-
-    public long getElapsedInclusive() {
-        return mElapsedInclusive;
-    }
-
-    public void setFadedColor(Color fadedColor) {
-        mFadedColor = fadedColor;
-    }
-
-    public Color getFadedColor() {
-        return mFadedColor;
-    }
-
-    public void setFadedImage(Image fadedImage) {
-        mFadedImage = fadedImage;
-    }
-
-    public Image getFadedImage() {
-        return mFadedImage;
-    }
-
-    public void setPathname(String pathname) {
-        mPathname = pathname;
-    }
-
-    public String getPathname() {
-        return mPathname;
-    }
-
-    public void setLineNumber(int lineNumber) {
-        mLineNumber = lineNumber;
-    }
-
-    public int getLineNumber() {
-        return mLineNumber;
-    }
-
-    public ProfileNode[] getProfileNodes() {
-        return mProfileNodes;
-    }
-
-    public static class Sorter implements Comparator<MethodData> {
-        public int compare(MethodData md1, MethodData md2) {
-            if (mColumn == Column.BY_NAME) {
-                int result = md1.getName().compareTo(md2.getName());
-                return (mDirection == Direction.INCREASING) ? result : -result;
-            }
-            if (mColumn == Column.BY_INCLUSIVE) {
-                if (md2.getElapsedInclusive() > md1.getElapsedInclusive())
-                    return (mDirection == Direction.INCREASING) ? -1 : 1;
-                if (md2.getElapsedInclusive() < md1.getElapsedInclusive())
-                    return (mDirection == Direction.INCREASING) ? 1 : -1;
-                return md1.getName().compareTo(md2.getName());
-            }
-            if (mColumn == Column.BY_EXCLUSIVE) {
-                if (md2.getElapsedExclusive() > md1.getElapsedExclusive())
-                    return (mDirection == Direction.INCREASING) ? -1 : 1;
-                if (md2.getElapsedExclusive() < md1.getElapsedExclusive())
-                    return (mDirection == Direction.INCREASING) ? 1 : -1;
-                return md1.getName().compareTo(md2.getName());
-            }
-            if (mColumn == Column.BY_CALLS) {
-                int result = md1.getTotalCalls() - md2.getTotalCalls();
-                if (result == 0)
-                    return md1.getName().compareTo(md2.getName());
-                return (mDirection == Direction.INCREASING) ? result : -result;
-            }
-            if (mColumn == Column.BY_TIME_PER_CALL) {
-                double time1 = md1.getElapsedInclusive();
-                time1 = time1 / md1.getTotalCalls();
-                double time2 = md2.getElapsedInclusive();
-                time2 = time2 / md2.getTotalCalls();
-                double diff = time1 - time2;
-                int result = 0;
-                if (diff < 0)
-                    result = -1;
-                else if (diff > 0)
-                    result = 1;
-                if (result == 0)
-                    return md1.getName().compareTo(md2.getName());
-                return (mDirection == Direction.INCREASING) ? result : -result;
-            }
-            return 0;
-        }
-
-        public void setColumn(Column column) {
-            // If the sort column specified is the same as last time,
-            // then reverse the sort order.
-            if (mColumn == column) {
-                // Reverse the sort order
-                if (mDirection == Direction.INCREASING)
-                    mDirection = Direction.DECREASING;
-                else
-                    mDirection = Direction.INCREASING;
-            } else {
-                // Sort names into increasing order, data into decreasing order.
-                if (column == Column.BY_NAME)
-                    mDirection = Direction.INCREASING;
-                else
-                    mDirection = Direction.DECREASING;
-            }
-            mColumn = column;
-        }
-
-        public Column getColumn() {
-            return mColumn;
-        }
-
-        public void setDirection(Direction direction) {
-            mDirection = direction;
-        }
-
-        public Direction getDirection() {
-            return mDirection;
-        }
-
-        public static enum Column {
-            BY_NAME, BY_EXCLUSIVE, BY_INCLUSIVE, BY_CALLS, BY_TIME_PER_CALL
-        };
-
-        public static enum Direction {
-            INCREASING, DECREASING
-        };
-
-        private Column mColumn;
-        private Direction mDirection;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ProfileData.java b/tools/traceview/src/com/android/traceview/ProfileData.java
deleted file mode 100644
index f0c1d61..0000000
--- a/tools/traceview/src/com/android/traceview/ProfileData.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-
-public class ProfileData {
-
-    protected MethodData mElement;
-    
-    /** mContext is either the parent or child of mElement */
-    protected MethodData mContext;
-    protected boolean mElementIsParent;
-    protected long mElapsedInclusive;
-    protected int mNumCalls;
-
-    public ProfileData() {
-    }
-
-    public ProfileData(MethodData context, MethodData element,
-            boolean elementIsParent) {
-        mContext = context;
-        mElement = element;
-        mElementIsParent = elementIsParent;
-    }
-
-    public String getProfileName() {
-        return mElement.getProfileName();
-    }
-
-    public MethodData getMethodData() {
-        return mElement;
-    }
-
-    public void addElapsedInclusive(long elapsedInclusive) {
-        mElapsedInclusive += elapsedInclusive;
-        mNumCalls += 1;
-    }
-
-    public void setElapsedInclusive(long elapsedInclusive) {
-        mElapsedInclusive = elapsedInclusive;
-    }
-
-    public long getElapsedInclusive() {
-        return mElapsedInclusive;
-    }
-
-    public void setNumCalls(int numCalls) {
-        mNumCalls = numCalls;
-    }
-
-    public String getNumCalls() {
-        int totalCalls;
-        if (mElementIsParent)
-            totalCalls = mContext.getTotalCalls();
-        else
-            totalCalls = mElement.getTotalCalls();
-        return String.format("%d/%d", mNumCalls, totalCalls);
-    }
-
-    public boolean isParent() {
-        return mElementIsParent;
-    }
-
-    public MethodData getContext() {
-        return mContext;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ProfileNode.java b/tools/traceview/src/com/android/traceview/ProfileNode.java
deleted file mode 100644
index 7cb0b5d..0000000
--- a/tools/traceview/src/com/android/traceview/ProfileNode.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-public class ProfileNode {
-
-    private String mLabel;
-    private MethodData mMethodData;
-    private ProfileData[] mChildren;
-    private boolean mIsParent;
-    private boolean mIsRecursive;
-
-    public ProfileNode(String label, MethodData methodData,
-            ProfileData[] children, boolean isParent, boolean isRecursive) {
-        mLabel = label;
-        mMethodData = methodData;
-        mChildren = children;
-        mIsParent = isParent;
-        mIsRecursive = isRecursive;
-    }
-
-    public String getLabel() {
-        return mLabel;
-    }
-    
-    public ProfileData[] getChildren() {
-        return mChildren;
-    }
-
-    public boolean isParent() {
-        return mIsParent;
-    }
-
-    public boolean isRecursive() {
-        return mIsRecursive;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ProfileProvider.java b/tools/traceview/src/com/android/traceview/ProfileProvider.java
deleted file mode 100644
index fe5c832..0000000
--- a/tools/traceview/src/com/android/traceview/ProfileProvider.java
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.io.InputStream;
-import java.util.Arrays;
-import java.util.regex.Pattern;
-
-import org.eclipse.jface.viewers.IColorProvider;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeColumn;
-import org.eclipse.swt.widgets.TreeItem;
-
-class ProfileProvider implements ITreeContentProvider {
-
-    private MethodData[] mRoots;
-    private SelectionAdapter mListener;
-    private TreeViewer mTreeViewer;
-    private TraceReader mReader;
-    private Image mSortUp;
-    private Image mSortDown;
-    private String mColumnNames[] = { "Name", "Incl %", "Inclusive", "Excl %",
-            "Exclusive", "Calls+Recur\nCalls/Total", "Time/Call" };
-    private int mColumnWidths[] = { 370, 70, 70, 70, 70, 90, 70 };
-    private int mColumnAlignments[] = { SWT.LEFT, SWT.RIGHT, SWT.RIGHT,
-            SWT.RIGHT, SWT.RIGHT, SWT.CENTER, SWT.RIGHT };
-    private static final int COL_NAME = 0;
-    private static final int COL_INCLUSIVE_PER = 1;
-    private static final int COL_INCLUSIVE = 2;
-    private static final int COL_EXCLUSIVE_PER = 3;
-    private static final int COL_EXCLUSIVE = 4;
-    private static final int COL_CALLS = 5;
-    private static final int COL_TIME_PER_CALL = 6;
-    private long mTotalTime;
-    private Pattern mUppercase;
-    private int mPrevMatchIndex = -1;
-
-    public ProfileProvider(TraceReader reader) {
-        mRoots = reader.getMethods();
-        mReader = reader;
-        mTotalTime = reader.getEndTime();
-        Display display = Display.getCurrent();
-        InputStream in = getClass().getClassLoader().getResourceAsStream(
-                "icons/sort_up.png");
-        mSortUp = new Image(display, in);
-        in = getClass().getClassLoader().getResourceAsStream(
-                "icons/sort_down.png");
-        mSortDown = new Image(display, in);
-        mUppercase = Pattern.compile("[A-Z]");
-    }
-
-    private MethodData doMatchName(String name, int startIndex) {
-        // Check if the given "name" has any uppercase letters
-        boolean hasUpper = mUppercase.matcher(name).matches();
-        for (int ii = startIndex; ii < mRoots.length; ++ii) {
-            MethodData md = mRoots[ii];
-            String fullName = md.getName();
-            // If there were no upper case letters in the given name,
-            // then ignore case when matching.
-            if (!hasUpper)
-                fullName = fullName.toLowerCase();
-            if (fullName.indexOf(name) != -1) {
-                mPrevMatchIndex = ii;
-                return md;
-            }
-        }
-        mPrevMatchIndex = -1;
-        return null;
-    }
-
-    public MethodData findMatchingName(String name) {
-        return doMatchName(name, 0);
-    }
-
-    public MethodData findNextMatchingName(String name) {
-        return doMatchName(name, mPrevMatchIndex + 1);
-    }
-
-    public MethodData findMatchingTreeItem(TreeItem item) {
-        if (item == null)
-            return null;
-        String text = item.getText();
-        if (Character.isDigit(text.charAt(0)) == false)
-            return null;
-        int spaceIndex = text.indexOf(' ');
-        String numstr = text.substring(0, spaceIndex);
-        int rank = Integer.valueOf(numstr);
-        for (MethodData md : mRoots) {
-            if (md.getRank() == rank)
-                return md;
-        }
-        return null;
-    }
-
-    public void setTreeViewer(TreeViewer treeViewer) {
-        mTreeViewer = treeViewer;
-    }
-
-    public String[] getColumnNames() {
-        return mColumnNames;
-    }
-
-    public int[] getColumnWidths() {
-        return mColumnWidths;
-    }
-
-    public int[] getColumnAlignments() {
-        return mColumnAlignments;
-    }
-
-    public Object[] getChildren(Object element) {
-        if (element instanceof MethodData) {
-            MethodData md = (MethodData) element;
-            return md.getProfileNodes();
-        }
-        if (element instanceof ProfileNode) {
-            ProfileNode pn = (ProfileNode) element;
-            return pn.getChildren();
-        }
-        return new Object[0];
-    }
-
-    public Object getParent(Object element) {
-        return null;
-    }
-
-    public boolean hasChildren(Object element) {
-        if (element instanceof MethodData)
-            return true;
-        if (element instanceof ProfileNode)
-            return true;
-        return false;
-    }
-
-    public Object[] getElements(Object element) {
-        return mRoots;
-    }
-
-    public void dispose() {
-    }
-
-    public void inputChanged(Viewer arg0, Object arg1, Object arg2) {
-    }
-
-    public Object getRoot() {
-        return "root";
-    }
-
-    public SelectionAdapter getColumnListener() {
-        if (mListener == null)
-            mListener = new ColumnListener();
-        return mListener;
-    }
-
-    public LabelProvider getLabelProvider() {
-        return new ProfileLabelProvider();
-    }
-
-    class ProfileLabelProvider extends LabelProvider implements
-            ITableLabelProvider, IColorProvider {
-        Color colorRed;
-        Color colorParentsBack;
-        Color colorChildrenBack;
-        TraceUnits traceUnits;
-
-        public ProfileLabelProvider() {
-            Display display = Display.getCurrent();
-            colorRed = display.getSystemColor(SWT.COLOR_RED);
-            colorParentsBack = new Color(display, 230, 230, 255); // blue
-            colorChildrenBack = new Color(display, 255, 255, 210); // yellow
-            traceUnits = mReader.getTraceUnits();
-        }
-
-        public String getColumnText(Object element, int col) {
-            if (element instanceof MethodData) {
-                MethodData md = (MethodData) element;
-                if (col == COL_NAME)
-                    return md.getProfileName();
-                if (col == COL_EXCLUSIVE) {
-                    double val = md.getElapsedExclusive();
-                    val = traceUnits.getScaledValue(val);
-                    return String.format("%.3f", val);
-                }
-                if (col == COL_EXCLUSIVE_PER) {
-                    double val = md.getElapsedExclusive();
-                    double per = val * 100.0 / mTotalTime;
-                    return String.format("%.1f%%", per);
-                }
-                if (col == COL_INCLUSIVE) {
-                    double val = md.getElapsedInclusive();
-                    val = traceUnits.getScaledValue(val);
-                    return String.format("%.3f", val);
-                }
-                if (col == COL_INCLUSIVE_PER) {
-                    double val = md.getElapsedInclusive();
-                    double per = val * 100.0 / mTotalTime;
-                    return String.format("%.1f%%", per);
-                }
-                if (col == COL_CALLS)
-                    return md.getCalls();
-                if (col == COL_TIME_PER_CALL) {
-                    int numCalls = md.getTotalCalls();
-                    double val = md.getElapsedInclusive();
-                    val = val / numCalls;
-                    val = traceUnits.getScaledValue(val);
-                    return String.format("%.3f", val);
-                }
-            } else if (element instanceof ProfileSelf) {
-                ProfileSelf ps = (ProfileSelf) element;
-                if (col == COL_NAME)
-                    return ps.getProfileName();
-                if (col == COL_INCLUSIVE) {
-                    double val = ps.getElapsedInclusive();
-                    val = traceUnits.getScaledValue(val);
-                    return String.format("%.3f", val);
-                }
-                if (col == COL_INCLUSIVE_PER) {
-                    double total;
-                    double val = ps.getElapsedInclusive();
-                    MethodData context = ps.getContext();
-                    total = context.getElapsedInclusive();
-                    double per = val * 100.0 / total;
-                    return String.format("%.1f%%", per);
-                }
-                return "";
-            } else if (element instanceof ProfileData) {
-                ProfileData pd = (ProfileData) element;
-                if (col == COL_NAME)
-                    return pd.getProfileName();
-                if (col == COL_INCLUSIVE) {
-                    double val = pd.getElapsedInclusive();
-                    val = traceUnits.getScaledValue(val);
-                    return String.format("%.3f", val);
-                }
-                if (col == COL_INCLUSIVE_PER) {
-                    double total;
-                    double val = pd.getElapsedInclusive();
-                    MethodData context = pd.getContext();
-                    total = context.getElapsedInclusive();
-                    double per = val * 100.0 / total;
-                    return String.format("%.1f%%", per);
-                }
-                if (col == COL_CALLS)
-                    return pd.getNumCalls();
-                return "";
-            } else if (element instanceof ProfileNode) {
-                ProfileNode pn = (ProfileNode) element;
-                if (col == COL_NAME)
-                    return pn.getLabel();
-                return "";
-            }
-            return "col" + col;
-        }
-
-        public Image getColumnImage(Object element, int col) {
-            if (col != COL_NAME)
-                return null;
-            if (element instanceof MethodData) {
-                MethodData md = (MethodData) element;
-                return md.getImage();
-            }
-            if (element instanceof ProfileData) {
-                ProfileData pd = (ProfileData) element;
-                MethodData md = pd.getMethodData();
-                return md.getImage();
-            }
-            return null;
-        }
-
-        public Color getForeground(Object element) {
-            return null;
-        }
-
-        public Color getBackground(Object element) {
-            if (element instanceof ProfileData) {
-                ProfileData pd = (ProfileData) element;
-                if (pd.isParent())
-                    return colorParentsBack;
-                return colorChildrenBack;
-            }
-            if (element instanceof ProfileNode) {
-                ProfileNode pn = (ProfileNode) element;
-                if (pn.isParent())
-                    return colorParentsBack;
-                return colorChildrenBack;
-            }
-            return null;
-        }
-    }
-
-    class ColumnListener extends SelectionAdapter {
-        MethodData.Sorter sorter = new MethodData.Sorter();
-
-        @Override
-        public void widgetSelected(SelectionEvent event) {
-            TreeColumn column = (TreeColumn) event.widget;
-            String name = column.getText();
-            Tree tree = column.getParent();
-            tree.setRedraw(false);
-            TreeColumn[] columns = tree.getColumns();
-            for (TreeColumn col : columns) {
-                col.setImage(null);
-            }
-            if (name == mColumnNames[COL_NAME]) {
-                // Sort names alphabetically
-                sorter.setColumn(MethodData.Sorter.Column.BY_NAME);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_EXCLUSIVE]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_EXCLUSIVE);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_EXCLUSIVE_PER]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_EXCLUSIVE);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_INCLUSIVE]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_INCLUSIVE);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_INCLUSIVE_PER]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_INCLUSIVE);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_CALLS]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_CALLS);
-                Arrays.sort(mRoots, sorter);
-            } else if (name == mColumnNames[COL_TIME_PER_CALL]) {
-                sorter.setColumn(MethodData.Sorter.Column.BY_TIME_PER_CALL);
-                Arrays.sort(mRoots, sorter);
-            }
-            MethodData.Sorter.Direction direction = sorter.getDirection();
-            if (direction == MethodData.Sorter.Direction.INCREASING)
-                column.setImage(mSortDown);
-            else
-                column.setImage(mSortUp);
-            tree.setRedraw(true);
-            mTreeViewer.refresh();
-        }
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ProfileSelf.java b/tools/traceview/src/com/android/traceview/ProfileSelf.java
deleted file mode 100644
index 3a4f3d9..0000000
--- a/tools/traceview/src/com/android/traceview/ProfileSelf.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-public class ProfileSelf extends ProfileData {
-    public ProfileSelf(MethodData methodData) {
-        mElement = methodData;
-        mContext = methodData;
-    }
-
-    @Override
-    public String getProfileName() {
-        return "self";
-    }
-
-    @Override
-    public long getElapsedInclusive() {
-        return mElement.getTopExclusive();
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ProfileView.java b/tools/traceview/src/com/android/traceview/ProfileView.java
deleted file mode 100644
index e48cb56..0000000
--- a/tools/traceview/src/com/android/traceview/ProfileView.java
+++ /dev/null
@@ -1,308 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.ArrayList;
-import java.util.Observable;
-import java.util.Observer;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITreeViewerListener;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeExpansionEvent;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.swt.widgets.TreeColumn;
-import org.eclipse.swt.widgets.TreeItem;
-
-public class ProfileView extends Composite implements Observer {
-    
-    private TreeViewer mTreeViewer;
-    private Text mSearchBox;
-    private SelectionController mSelectionController;
-    private ProfileProvider mProfileProvider;
-    private Color mColorNoMatch;
-    private Color mColorMatch;
-    private MethodData mCurrentHighlightedMethod;
-
-    public ProfileView(Composite parent, TraceReader reader,
-            SelectionController selectController) {
-        super(parent, SWT.NONE);
-        setLayout(new GridLayout(1, false));
-        this.mSelectionController = selectController;
-        mSelectionController.addObserver(this);
-
-        // Add a tree viewer at the top
-        mTreeViewer = new TreeViewer(this, SWT.MULTI | SWT.NONE);
-        mTreeViewer.setUseHashlookup(true);
-        mProfileProvider = reader.getProfileProvider();
-        mProfileProvider.setTreeViewer(mTreeViewer);
-        SelectionAdapter listener = mProfileProvider.getColumnListener();
-        final Tree tree = mTreeViewer.getTree();
-        tree.setHeaderVisible(true);
-        tree.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // Get the column names from the ProfileProvider
-        String[] columnNames = mProfileProvider.getColumnNames();
-        int[] columnWidths = mProfileProvider.getColumnWidths();
-        int[] columnAlignments = mProfileProvider.getColumnAlignments();
-        for (int ii = 0; ii < columnWidths.length; ++ii) {
-            TreeColumn column = new TreeColumn(tree, SWT.LEFT);
-            column.setText(columnNames[ii]);
-            column.setWidth(columnWidths[ii]);
-            column.setMoveable(true);
-            column.addSelectionListener(listener);
-            column.setAlignment(columnAlignments[ii]);
-        }
-
-        // Add a listener to the tree so that we can make the row
-        // height smaller.
-        tree.addListener(SWT.MeasureItem, new Listener() {
-            public void handleEvent(Event event) {
-                int fontHeight = event.gc.getFontMetrics().getHeight();
-                event.height = fontHeight;
-            }
-        });
-
-        mTreeViewer.setContentProvider(mProfileProvider);
-        mTreeViewer.setLabelProvider(mProfileProvider.getLabelProvider());
-        mTreeViewer.setInput(mProfileProvider.getRoot());
-
-        // Create another composite to hold the label and text box
-        Composite composite = new Composite(this, SWT.NONE);
-        composite.setLayout(new GridLayout(2, false));
-        composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        // Add a label for the search box
-        Label label = new Label(composite, SWT.NONE);
-        label.setText("Find:");
-
-        // Add a text box for searching for method names
-        mSearchBox = new Text(composite, SWT.BORDER);
-        mSearchBox.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        Display display = getDisplay();
-        mColorNoMatch = new Color(display, 255, 200, 200);
-        mColorMatch = mSearchBox.getBackground();
-
-        mSearchBox.addModifyListener(new ModifyListener() {
-            public void modifyText(ModifyEvent ev) {
-                String query = mSearchBox.getText();
-                if (query.length() == 0)
-                    return;
-                findName(query);
-            }
-        });
-
-        // Add a key listener to the text box so that we can clear
-        // the text box if the user presses <ESC>.
-        mSearchBox.addKeyListener(new KeyAdapter() {
-            @Override
-            public void keyPressed(KeyEvent event) {
-                if (event.keyCode == SWT.ESC) {
-                    mSearchBox.setText("");
-                } else if (event.keyCode == SWT.CR) {
-                    String query = mSearchBox.getText();
-                    if (query.length() == 0)
-                        return;
-                    findNextName(query);
-                }
-            }
-        });
-
-        // Also add a key listener to the tree viewer so that the
-        // user can just start typing anywhere in the tree view.
-        tree.addKeyListener(new KeyAdapter() {
-            @Override
-            public void keyPressed(KeyEvent event) {
-                if (event.keyCode == SWT.ESC) {
-                    mSearchBox.setText("");
-                } else if (event.keyCode == SWT.BS) {
-                    // Erase the last character from the search box
-                    String text = mSearchBox.getText();
-                    int len = text.length();
-                    String chopped;
-                    if (len <= 1)
-                        chopped = "";
-                    else
-                        chopped = text.substring(0, len - 1);
-                    mSearchBox.setText(chopped);
-                } else if (event.keyCode == SWT.CR) {
-                    String query = mSearchBox.getText();
-                    if (query.length() == 0)
-                        return;
-                    findNextName(query);
-                } else {
-                    // Append the given character to the search box
-                    String str = String.valueOf(event.character);
-                    mSearchBox.append(str);
-                }
-                event.doit = false;
-            }
-        });
-
-        // Add a selection listener to the tree so that the user can click
-        // on a method that is a child or parent and jump to that method.
-        mTreeViewer
-                .addSelectionChangedListener(new ISelectionChangedListener() {
-                    public void selectionChanged(SelectionChangedEvent ev) {
-                        ISelection sel = ev.getSelection();
-                        if (sel.isEmpty())
-                            return;
-                        if (sel instanceof IStructuredSelection) {
-                            IStructuredSelection selection = (IStructuredSelection) sel;
-                            Object element = selection.getFirstElement();
-                            if (element == null)
-                                return;
-                            if (element instanceof MethodData) {
-                                MethodData md = (MethodData) element;
-                                highlightMethod(md, true);
-                            }
-                            if (element instanceof ProfileData) {
-                                MethodData md = ((ProfileData) element)
-                                        .getMethodData();
-                                highlightMethod(md, true);
-                            }
-                        }
-                    }
-                });
-        
-        // Add a tree listener so that we can expand the parents and children
-        // of a method when a method is expanded.
-        mTreeViewer.addTreeListener(new ITreeViewerListener() {
-            public void treeExpanded(TreeExpansionEvent event) {
-                Object element = event.getElement();
-                if (element instanceof MethodData) {
-                    MethodData md = (MethodData) element;
-                    expandNode(md);
-                }
-            }
-            public void treeCollapsed(TreeExpansionEvent event) {
-            }
-        });
-
-        tree.addListener(SWT.MouseDown, new Listener() {
-            public void handleEvent(Event event) {
-                Point point = new Point(event.x, event.y);
-                TreeItem treeItem = tree.getItem(point);
-                MethodData md = mProfileProvider.findMatchingTreeItem(treeItem);
-                if (md == null)
-                    return;
-                ArrayList<Selection> selections = new ArrayList<Selection>();
-                selections.add(Selection.highlight("MethodData", md));
-                mSelectionController.change(selections, "ProfileView");
-            }
-        });
-    }
-
-    private void findName(String query) {
-        MethodData md = mProfileProvider.findMatchingName(query);
-        selectMethod(md);
-    }
-
-    private void findNextName(String query) {
-        MethodData md = mProfileProvider.findNextMatchingName(query);
-        selectMethod(md);
-    }
-
-    private void selectMethod(MethodData md) {
-        if (md == null) {
-            mSearchBox.setBackground(mColorNoMatch);
-            return;
-        }
-        mSearchBox.setBackground(mColorMatch);
-        highlightMethod(md, false);
-    }
-
-    public void update(Observable objservable, Object arg) {
-        // Ignore updates from myself
-        if (arg == "ProfileView")
-            return;
-        // System.out.printf("profileview update from %s\n", arg);
-        ArrayList<Selection> selections;
-        selections = mSelectionController.getSelections();
-        for (Selection selection : selections) {
-            Selection.Action action = selection.getAction();
-            if (action != Selection.Action.Highlight)
-                continue;
-            String name = selection.getName();
-            if (name == "MethodData") {
-                MethodData md = (MethodData) selection.getValue();
-                highlightMethod(md, true);
-                return;
-            }
-            if (name == "Call") {
-                Call call = (Call) selection.getValue();
-                MethodData md = call.mMethodData;
-                highlightMethod(md, true);
-                return;
-            }
-        }
-    }
-
-    private void highlightMethod(MethodData md, boolean clearSearch) {
-        if (md == null)
-            return;
-        // Avoid an infinite recursion
-        if (md == mCurrentHighlightedMethod)
-            return;
-        if (clearSearch) {
-            mSearchBox.setText("");
-            mSearchBox.setBackground(mColorMatch);
-        }
-        mCurrentHighlightedMethod = md;
-        mTreeViewer.collapseAll();
-        // Expand this node and its children
-        expandNode(md);
-        StructuredSelection sel = new StructuredSelection(md);
-        mTreeViewer.setSelection(sel, true);
-        Tree tree = mTreeViewer.getTree();
-        TreeItem[] items = tree.getSelection();
-        tree.setTopItem(items[0]);
-        // workaround a Mac bug by adding showItem().
-        tree.showItem(items[0]);
-    }
-
-    private void expandNode(MethodData md) {
-        ProfileNode[] nodes = md.getProfileNodes();
-        mTreeViewer.setExpandedState(md, true);
-        // Also expand the "Parents" and "Children" nodes.
-        for (ProfileNode node : nodes) {
-            if (node.isRecursive() == false)
-                mTreeViewer.setExpandedState(node, true);
-        }
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/QtraceReader.java b/tools/traceview/src/com/android/traceview/QtraceReader.java
deleted file mode 100644
index c4db4a2..0000000
--- a/tools/traceview/src/com/android/traceview/QtraceReader.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-
-public class QtraceReader extends TraceReader {
-    QtraceReader(String traceName) {
-    }
-
-    @Override
-    public MethodData[] getMethods() {
-        return null;
-    }
-
-    @Override
-    public HashMap<Integer, String> getThreadLabels() {
-        return null;
-    }
-
-    @Override
-    public ArrayList<TimeLineView.Record> getThreadTimeRecords() {
-        return null;
-    }
-
-    @Override
-    public ProfileProvider getProfileProvider() {
-        return null;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/Selection.java b/tools/traceview/src/com/android/traceview/Selection.java
deleted file mode 100644
index 3764619..0000000
--- a/tools/traceview/src/com/android/traceview/Selection.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-public class Selection {
-
-    private Action mAction;
-    private String mName;
-    private Object mValue;
-
-    public Selection(Action action, String name, Object value) {
-        mAction = action;
-        mName = name;
-        mValue = value;
-    }
-
-    public static Selection highlight(String name, Object value) {
-        return new Selection(Action.Highlight, name, value);
-    }
-
-    public static Selection include(String name, Object value) {
-        return new Selection(Action.Include, name, value);
-    }
-
-    public static Selection exclude(String name, Object value) {
-        return new Selection(Action.Exclude, name, value);
-    }
-
-    public void setName(String name) {
-        mName = name;
-    }
-
-    public String getName() {
-        return mName;
-    }
-
-    public void setValue(Object value) {
-        mValue = value;
-    }
-
-    public Object getValue() {
-        return mValue;
-    }
-
-    public void setAction(Action action) {
-        mAction = action;
-    }
-
-    public Action getAction() {
-        return mAction;
-    }
-
-    public static enum Action {
-        Highlight, Include, Exclude, Aggregate
-    };
-}
diff --git a/tools/traceview/src/com/android/traceview/SelectionController.java b/tools/traceview/src/com/android/traceview/SelectionController.java
deleted file mode 100644
index 4c930ea..0000000
--- a/tools/traceview/src/com/android/traceview/SelectionController.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.ArrayList;
-import java.util.Observable;
-
-public class SelectionController extends Observable {
-
-    private ArrayList<Selection> mSelections;
-
-    public void change(ArrayList<Selection> selections, Object arg) {
-        this.mSelections = selections;
-        setChanged();
-        notifyObservers(arg);
-    }
-
-    public ArrayList<Selection> getSelections() {
-        return mSelections;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/ThreadData.java b/tools/traceview/src/com/android/traceview/ThreadData.java
deleted file mode 100644
index 54ea891..0000000
--- a/tools/traceview/src/com/android/traceview/ThreadData.java
+++ /dev/null
@@ -1,228 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-
-class ThreadData implements TimeLineView.Row {
-
-    private int mId;
-    private String mName;
-    private long mGlobalStartTime = -1;
-    private long mGlobalEndTime = -1;
-    private long mLastEventTime;
-    private long mCpuTime;
-    private Call mRoot;
-    private Call mCurrent;
-    private Call mLastContextSwitch;
-    private ArrayList<Call> mStack = new ArrayList<Call>();
-    
-    // This is a hash of all the methods that are currently on the stack.
-    private HashMap<MethodData, Integer> mStackMethods = new HashMap<MethodData, Integer>();
-    
-    // True if no calls have ever been added to this thread
-    private boolean mIsEmpty;
-
-    ThreadData(int id, String name, MethodData topLevel) {
-        mId = id;
-        mName = String.format("[%d] %s", id, name);
-        mRoot = new Call(mName, topLevel);
-        mCurrent = mRoot;
-        mIsEmpty = true;
-    }
-
-    public boolean isEmpty() {
-        return mIsEmpty;
-    }
-
-    public String getName() {
-        return mName;
-    }
-
-    public Call getCalltreeRoot() {
-        return mRoot;
-    }
-
-    void handleCall(Call call, long globalTime) {
-        mIsEmpty = false;
-        long currentTime = call.mThreadStartTime;
-        if (currentTime < mLastEventTime) {
-            System.err
-            .printf(
-                    "ThreadData: '%1$s' call time (%2$d) is less than previous time (%3$d) for thread '%4$s'\n",
-                    call.getName(), currentTime, mLastEventTime, mName);
-            System.exit(1);
-        }
-        long elapsed = currentTime - mLastEventTime;
-        mCpuTime += elapsed;
-        if (call.getMethodAction() == 0) {
-            // This is a method entry.
-            enter(call, elapsed);
-        } else {
-            // This is a method exit.
-            exit(call, elapsed, globalTime);
-        }
-        mLastEventTime = currentTime;
-        mGlobalEndTime = globalTime;
-    }
-
-    private void enter(Call c, long elapsed) {
-        Call caller = mCurrent;
-        push(c);
-        
-        // Check the stack for a matching method to determine if this call
-        // is recursive.
-        MethodData md = c.mMethodData;
-        Integer num = mStackMethods.get(md);
-        if (num == null) {
-            num = 0;
-        } else if (num > 0) {
-            c.setRecursive(true);
-        }
-        num += 1;
-        mStackMethods.put(md, num);
-        mCurrent = c;
-
-        // Add the elapsed time to the caller's exclusive time
-        caller.addExclusiveTime(elapsed);
-    }
-
-    private void exit(Call c, long elapsed, long globalTime) {
-        mCurrent.mGlobalEndTime = globalTime;
-        Call top = pop();
-        if (top == null) {
-            return;
-        }
-
-        if (mCurrent.mMethodData != c.mMethodData) {
-            String error = "Method exit (" + c.getName()
-                    + ") does not match current method (" + mCurrent.getName()
-                    + ")";
-            throw new RuntimeException(error);
-        } else {
-            long duration = c.mThreadStartTime - mCurrent.mThreadStartTime;
-            Call caller = top();
-            mCurrent.addExclusiveTime(elapsed);
-            mCurrent.addInclusiveTime(duration, caller);
-            if (caller == null) {
-                caller = mRoot;
-            }
-            mCurrent = caller;
-        }
-    }
-
-    public void push(Call c) {
-        mStack.add(c);
-    }
-
-    public Call pop() {
-        ArrayList<Call> stack = mStack;
-        if (stack.size() == 0)
-            return null;
-        Call top = stack.get(stack.size() - 1);
-        stack.remove(stack.size() - 1);
-        
-        // Decrement the count on the method in the hash table and remove
-        // the entry when it goes to zero.
-        MethodData md = top.mMethodData;
-        Integer num = mStackMethods.get(md);
-        if (num != null) {
-            num -= 1;
-            if (num <= 0) {
-                mStackMethods.remove(md);
-            } else {
-                mStackMethods.put(md, num);
-            }
-        }
-        return top;
-    }
-
-    public Call top() {
-        ArrayList<Call> stack = mStack;
-        if (stack.size() == 0)
-            return null;
-        return stack.get(stack.size() - 1);
-    }
-
-    public long endTrace() {
-        // If we have calls on the stack when the trace ends, then clean up
-        // the stack and compute the inclusive time of the methods by pretending
-        // that we are exiting from their methods now.
-        while (mCurrent != mRoot) {
-            long duration = mLastEventTime - mCurrent.mThreadStartTime;
-            pop();
-            Call caller = top();
-            mCurrent.addInclusiveTime(duration, caller);
-            mCurrent.mGlobalEndTime = mGlobalEndTime;
-            if (caller == null) {
-                caller = mRoot;
-            }
-            mCurrent = caller;
-        }
-        return mLastEventTime;
-    }
-
-    @Override
-    public String toString() {
-        return mName;
-    }
-
-    public int getId() {
-        return mId;
-    }
-
-    public void setCpuTime(long cpuTime) {
-        mCpuTime = cpuTime;
-    }
-
-    public long getCpuTime() {
-        return mCpuTime;
-    }
-
-    public void setGlobalStartTime(long globalStartTime) {
-        mGlobalStartTime = globalStartTime;
-    }
-
-    public long getGlobalStartTime() {
-        return mGlobalStartTime;
-    }
-
-    public void setLastEventTime(long lastEventTime) {
-        mLastEventTime = lastEventTime;
-    }
-
-    public long getLastEventTime() {
-        return mLastEventTime;
-    }
-
-    public void setGlobalEndTime(long globalEndTime) {
-        mGlobalEndTime = globalEndTime;
-    }
-
-    public long getGlobalEndTime() {
-        return mGlobalEndTime;
-    }
-
-    public void setLastContextSwitch(Call lastContextSwitch) {
-        mLastContextSwitch = lastContextSwitch;
-    }
-
-    public Call getLastContextSwitch() {
-        return mLastContextSwitch;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/TickScaler.java b/tools/traceview/src/com/android/traceview/TickScaler.java
deleted file mode 100644
index 79fa160..0000000
--- a/tools/traceview/src/com/android/traceview/TickScaler.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-class TickScaler {
-
-    private double mMinVal; // required input
-    private double mMaxVal; // required input
-    private double mRangeVal;
-    private int mNumPixels; // required input
-    private int mPixelsPerTick; // required input
-    private double mPixelsPerRange;
-    private double mTickIncrement;
-    private double mMinMajorTick;
-
-    TickScaler(double minVal, double maxVal, int numPixels, int pixelsPerTick) {
-        mMinVal = minVal;
-        mMaxVal = maxVal;
-        mNumPixels = numPixels;
-        mPixelsPerTick = pixelsPerTick;
-    }
-
-    public void setMinVal(double minVal) {
-        mMinVal = minVal;
-    }
-
-    public double getMinVal() {
-        return mMinVal;
-    }
-
-    public void setMaxVal(double maxVal) {
-        mMaxVal = maxVal;
-    }
-
-    public double getMaxVal() {
-        return mMaxVal;
-    }
-
-    public void setNumPixels(int numPixels) {
-        mNumPixels = numPixels;
-    }
-
-    public int getNumPixels() {
-        return mNumPixels;
-    }
-
-    public void setPixelsPerTick(int pixelsPerTick) {
-        mPixelsPerTick = pixelsPerTick;
-    }
-
-    public int getPixelsPerTick() {
-        return mPixelsPerTick;
-    }
-
-    public void setPixelsPerRange(double pixelsPerRange) {
-        mPixelsPerRange = pixelsPerRange;
-    }
-
-    public double getPixelsPerRange() {
-        return mPixelsPerRange;
-    }
-
-    public void setTickIncrement(double tickIncrement) {
-        mTickIncrement = tickIncrement;
-    }
-
-    public double getTickIncrement() {
-        return mTickIncrement;
-    }
-
-    public void setMinMajorTick(double minMajorTick) {
-        mMinMajorTick = minMajorTick;
-    }
-
-    public double getMinMajorTick() {
-        return mMinMajorTick;
-    }
-
-    // Convert a time value to a 0-based pixel value
-    public int valueToPixel(double value) {
-        return (int) Math.ceil(mPixelsPerRange * (value - mMinVal) - 0.5);
-    }
-
-    // Convert a time value to a 0-based fractional pixel
-    public double valueToPixelFraction(double value) {
-        return mPixelsPerRange * (value - mMinVal);
-    }
-
-    // Convert a 0-based pixel value to a time value
-    public double pixelToValue(int pixel) {
-        return mMinVal + (pixel / mPixelsPerRange);
-    }
-
-    public void computeTicks(boolean useGivenEndPoints) {
-        int numTicks = mNumPixels / mPixelsPerTick;
-        mRangeVal = mMaxVal - mMinVal;
-        mTickIncrement = mRangeVal / numTicks;
-        double dlogTickIncrement = Math.log10(mTickIncrement);
-        int logTickIncrement = (int) Math.floor(dlogTickIncrement);
-        double scale = Math.pow(10, logTickIncrement);
-        double scaledTickIncr = mTickIncrement / scale;
-        if (scaledTickIncr > 5.0)
-            scaledTickIncr = 10;
-        else if (scaledTickIncr > 2)
-            scaledTickIncr = 5;
-        else if (scaledTickIncr > 1)
-            scaledTickIncr = 2;
-        else
-            scaledTickIncr = 1;
-        mTickIncrement = scaledTickIncr * scale;
-
-        if (!useGivenEndPoints) {
-            // Round up the max val to the next minor tick
-            double minorTickIncrement = mTickIncrement / 5;
-            double dval = mMaxVal / minorTickIncrement;
-            int ival = (int) dval;
-            if (ival != dval)
-                mMaxVal = (ival + 1) * minorTickIncrement;
-
-            // Round down the min val to a multiple of tickIncrement
-            ival = (int) (mMinVal / mTickIncrement);
-            mMinVal = ival * mTickIncrement;
-            mMinMajorTick = mMinVal;
-        } else {
-            int ival = (int) (mMinVal / mTickIncrement);
-            mMinMajorTick = ival * mTickIncrement;
-            if (mMinMajorTick < mMinVal)
-                mMinMajorTick = mMinMajorTick + mTickIncrement;
-        }
-
-        mRangeVal = mMaxVal - mMinVal;
-        mPixelsPerRange = (double) mNumPixels / mRangeVal;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/TimeLineView.java b/tools/traceview/src/com/android/traceview/TimeLineView.java
deleted file mode 100644
index 67dc97b..0000000
--- a/tools/traceview/src/com/android/traceview/TimeLineView.java
+++ /dev/null
@@ -1,1961 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import org.eclipse.jface.resource.FontRegistry;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.SashForm;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.MouseMoveListener;
-import org.eclipse.swt.events.PaintEvent;
-import org.eclipse.swt.events.PaintListener;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Cursor;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Canvas;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.ScrollBar;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.Observable;
-import java.util.Observer;
-
-public class TimeLineView extends Composite implements Observer {
-
-    private HashMap<String, RowData> mRowByName;
-    private double mTotalElapsed;
-    private RowData[] mRows;
-    private Segment[] mSegments;
-    private ArrayList<Segment> mSegmentList = new ArrayList<Segment>();
-    private HashMap<Integer, String> mThreadLabels;
-    private Timescale mTimescale;
-    private Surface mSurface;
-    private RowLabels mLabels;
-    private SashForm mSashForm;
-    private int mScrollOffsetY;
-
-    public static final int PixelsPerTick = 50;
-    private TickScaler mScaleInfo = new TickScaler(0, 0, 0, PixelsPerTick);
-    private static final int LeftMargin = 10; // blank space on left
-    private static final int RightMargin = 60; // blank space on right
-
-    private Color mColorBlack;
-    private Color mColorGray;
-    private Color mColorDarkGray;
-    private Color mColorForeground;
-    private Color mColorRowBack;
-    private Color mColorZoomSelection;
-    private FontRegistry mFontRegistry;
-
-    /** vertical height of drawn blocks in each row */
-    private static final int rowHeight = 20;
-
-    /** the blank space between rows */
-    private static final int rowYMargin = 12;
-    private static final int rowYMarginHalf = rowYMargin / 2;
-
-    /** total vertical space for row */
-    private static final int rowYSpace = rowHeight + rowYMargin;
-    private static final int majorTickLength = 8;
-    private static final int minorTickLength = 4;
-    private static final int timeLineOffsetY = 38;
-    private static final int tickToFontSpacing = 2;
-
-    /** start of first row */
-    private static final int topMargin = 70;
-    private int mMouseRow = -1;
-    private int mNumRows;
-    private int mStartRow;
-    private int mEndRow;
-    private TraceUnits mUnits;
-    private int mSmallFontWidth;
-    private int mSmallFontHeight;
-    private int mMediumFontWidth;
-    private SelectionController mSelectionController;
-    private MethodData mHighlightMethodData;
-    private Call mHighlightCall;
-    private static final int MinInclusiveRange = 3;
-
-    /** Setting the fonts looks good on Linux but bad on Macs */
-    private boolean mSetFonts = false;
-
-    public static interface Block {
-        public String getName();
-        public MethodData getMethodData();
-        public long getStartTime();
-        public long getEndTime();
-        public Color getColor();
-        public double addWeight(int x, int y, double weight);
-        public void clearWeight();
-    }
-
-    public static interface Row {
-        public int getId();
-        public String getName();
-    }
-
-    public static class Record {
-        Row row;
-        Block block;
-
-        public Record(Row row, Block block) {
-            this.row = row;
-            this.block = block;
-        }
-    }
-
-    public TimeLineView(Composite parent, TraceReader reader,
-            SelectionController selectionController) {
-        super(parent, SWT.NONE);
-        mRowByName = new HashMap<String, RowData>();
-        this.mSelectionController = selectionController;
-        selectionController.addObserver(this);
-        mUnits = reader.getTraceUnits();
-        mThreadLabels = reader.getThreadLabels();
-
-        Display display = getDisplay();
-        mColorGray = display.getSystemColor(SWT.COLOR_GRAY);
-        mColorDarkGray = display.getSystemColor(SWT.COLOR_DARK_GRAY);
-        mColorBlack = display.getSystemColor(SWT.COLOR_BLACK);
-        // mColorBackground = display.getSystemColor(SWT.COLOR_WHITE);
-        mColorForeground = display.getSystemColor(SWT.COLOR_BLACK);
-        mColorRowBack = new Color(display, 240, 240, 255);
-        mColorZoomSelection = new Color(display, 230, 230, 230);
-
-        mFontRegistry = new FontRegistry(display);
-        mFontRegistry.put("small",  // $NON-NLS-1$
-                new FontData[] { new FontData("Arial", 8, SWT.NORMAL) });  // $NON-NLS-1$
-        mFontRegistry.put("courier8",  // $NON-NLS-1$
-                new FontData[] { new FontData("Courier New", 8, SWT.BOLD) });  // $NON-NLS-1$
-        mFontRegistry.put("medium",  // $NON-NLS-1$
-                new FontData[] { new FontData("Courier New", 10, SWT.NORMAL) });  // $NON-NLS-1$
-
-        Image image = new Image(display, new Rectangle(100, 100, 100, 100));
-        GC gc = new GC(image);
-        if (mSetFonts) {
-            gc.setFont(mFontRegistry.get("small"));  // $NON-NLS-1$
-        }
-        mSmallFontWidth = gc.getFontMetrics().getAverageCharWidth();
-        mSmallFontHeight = gc.getFontMetrics().getHeight();
-
-        if (mSetFonts) {
-            gc.setFont(mFontRegistry.get("medium"));  // $NON-NLS-1$
-        }
-        mMediumFontWidth = gc.getFontMetrics().getAverageCharWidth();
-
-        image.dispose();
-        gc.dispose();
-
-        setLayout(new FillLayout());
-
-        // Create a sash form for holding two canvas views, one for the
-        // thread labels and one for the thread timeline.
-        mSashForm = new SashForm(this, SWT.HORIZONTAL);
-        mSashForm.setBackground(mColorGray);
-        mSashForm.SASH_WIDTH = 3;
-
-        // Create a composite for the left side of the sash
-        Composite composite = new Composite(mSashForm, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true /* make columns equal width */);
-        layout.marginHeight = 0;
-        layout.marginWidth = 0;
-        layout.verticalSpacing = 1;
-        composite.setLayout(layout);
-        
-        // Create a blank corner space in the upper left corner
-        BlankCorner corner = new BlankCorner(composite);
-        GridData gridData = new GridData(GridData.FILL_HORIZONTAL);
-        gridData.heightHint = topMargin;
-        corner.setLayoutData(gridData);
-        
-        // Add the thread labels below the blank corner.
-        mLabels = new RowLabels(composite);
-        gridData = new GridData(GridData.FILL_BOTH);
-        mLabels.setLayoutData(gridData);
-        
-        // Create another composite for the right side of the sash
-        composite = new Composite(mSashForm, SWT.NONE);
-        layout = new GridLayout(1, true /* make columns equal width */);
-        layout.marginHeight = 0;
-        layout.marginWidth = 0;
-        layout.verticalSpacing = 1;
-        composite.setLayout(layout);
-
-        mTimescale = new Timescale(composite);
-        gridData = new GridData(GridData.FILL_HORIZONTAL);
-        gridData.heightHint = topMargin;
-        mTimescale.setLayoutData(gridData);
-
-        mSurface = new Surface(composite);
-        gridData = new GridData(GridData.FILL_BOTH);
-        mSurface.setLayoutData(gridData);
-        mSashForm.setWeights(new int[] { 1, 5 });
-
-        final ScrollBar vBar = mSurface.getVerticalBar();
-        vBar.addListener(SWT.Selection, new Listener() {
-           public void handleEvent(Event e) {
-               mScrollOffsetY = vBar.getSelection();
-               Point dim = mSurface.getSize();
-               int newScrollOffsetY = computeVisibleRows(dim.y);
-               if (newScrollOffsetY != mScrollOffsetY) {
-                   mScrollOffsetY = newScrollOffsetY;
-                   vBar.setSelection(newScrollOffsetY);
-               }
-               mLabels.redraw();
-               mSurface.redraw();
-           }
-        });
-        
-        mSurface.addListener(SWT.Resize, new Listener() {
-            public void handleEvent(Event e) {
-                Point dim = mSurface.getSize();
-                
-                // If we don't need the scroll bar then don't display it.
-                if (dim.y >= mNumRows * rowYSpace) {
-                    vBar.setVisible(false);
-                } else {
-                    vBar.setVisible(true);
-                }
-                int newScrollOffsetY = computeVisibleRows(dim.y);
-                if (newScrollOffsetY != mScrollOffsetY) {
-                    mScrollOffsetY = newScrollOffsetY;
-                    vBar.setSelection(newScrollOffsetY);
-                }
-                
-                int spaceNeeded = mNumRows * rowYSpace;
-                vBar.setMaximum(spaceNeeded);
-                vBar.setThumb(dim.y);
-
-                mLabels.redraw();
-                mSurface.redraw();
-            }
-        });
-
-        mSurface.addMouseListener(new MouseAdapter() {
-            @Override
-            public void mouseUp(MouseEvent me) {
-                mSurface.mouseUp(me);
-            }
-
-            @Override
-            public void mouseDown(MouseEvent me) {
-                mSurface.mouseDown(me);
-            }
-
-            @Override
-            public void mouseDoubleClick(MouseEvent me) {
-                mSurface.mouseDoubleClick(me);
-            }
-        });
-        
-        mSurface.addMouseMoveListener(new MouseMoveListener() {
-            public void mouseMove(MouseEvent me) {
-                mSurface.mouseMove(me);
-            }
-        });
-
-        mTimescale.addMouseListener(new MouseAdapter() {
-            @Override
-            public void mouseUp(MouseEvent me) {
-                mTimescale.mouseUp(me);
-            }
-
-            @Override
-            public void mouseDown(MouseEvent me) {
-                mTimescale.mouseDown(me);
-            }
-
-            @Override
-            public void mouseDoubleClick(MouseEvent me) {
-                mTimescale.mouseDoubleClick(me);
-            }
-        });
-        
-        mTimescale.addMouseMoveListener(new MouseMoveListener() {
-            public void mouseMove(MouseEvent me) {
-                mTimescale.mouseMove(me);
-            }
-        });
-
-        mLabels.addMouseMoveListener(new MouseMoveListener() {
-            public void mouseMove(MouseEvent me) {
-                mLabels.mouseMove(me);
-            }
-        });
-
-        setData(reader.getThreadTimeRecords());
-    }
-
-    public void update(Observable objservable, Object arg) {
-        // Ignore updates from myself
-        if (arg == "TimeLineView")  // $NON-NLS-1$
-            return;
-        // System.out.printf("timeline update from %s\n", arg);
-        boolean foundHighlight = false;
-        ArrayList<Selection> selections;
-        selections = mSelectionController.getSelections();
-        for (Selection selection : selections) {
-            Selection.Action action = selection.getAction();
-            if (action != Selection.Action.Highlight)
-                continue;
-            String name = selection.getName();
-            // System.out.printf(" timeline highlight %s from %s\n", name, arg);
-            if (name == "MethodData") {  // $NON-NLS-1$
-                foundHighlight = true;
-                mHighlightMethodData = (MethodData) selection.getValue();
-                // System.out.printf(" method %s\n",
-                // highlightMethodData.getName());
-                mHighlightCall = null;
-                startHighlighting();
-            } else if (name == "Call") {  // $NON-NLS-1$
-                foundHighlight = true;
-                mHighlightCall = (Call) selection.getValue();
-                // System.out.printf(" call %s\n", highlightCall.getName());
-                mHighlightMethodData = null;
-                startHighlighting();
-            }
-        }
-        if (foundHighlight == false)
-            mSurface.clearHighlights();
-    }
-
-    public void setData(ArrayList<Record> records) {
-        if (records == null)
-            records = new ArrayList<Record>();
-
-        if (false) {
-            System.out.println("TimelineView() list of records:");  // $NON-NLS-1$
-            for (Record r : records) {
-                System.out.printf("row '%s' block '%s' [%d, %d]\n", r.row  // $NON-NLS-1$
-                        .getName(), r.block.getName(), r.block.getStartTime(),
-                        r.block.getEndTime());
-                if (r.block.getStartTime() > r.block.getEndTime()) {
-                    System.err.printf("Error: block startTime > endTime\n");  // $NON-NLS-1$
-                    System.exit(1);
-                }
-            }
-        }
-
-        // Sort the records into increasing start time, and decreasing end time
-        Collections.sort(records, new Comparator<Record>() {
-            public int compare(Record r1, Record r2) {
-                long start1 = r1.block.getStartTime();
-                long start2 = r2.block.getStartTime();
-                if (start1 > start2)
-                    return 1;
-                if (start1 < start2)
-                    return -1;
-
-                // The start times are the same, so compare the end times
-                long end1 = r1.block.getEndTime();
-                long end2 = r2.block.getEndTime();
-                if (end1 > end2)
-                    return -1;
-                if (end1 < end2)
-                    return 1;
-
-                return 0;
-            }
-        });
-
-        // The records are sorted into increasing start time,
-        // so the minimum start time is the start time of the first record.
-        double minVal = 0;
-        if (records.size() > 0)
-            minVal = records.get(0).block.getStartTime();
-
-        // Sum the time spent in each row and block, and
-        // keep track of the maximum end time.
-        double maxVal = 0;
-        for (Record rec : records) {
-            Row row = rec.row;
-            Block block = rec.block;
-            String rowName = row.getName();
-            RowData rd = mRowByName.get(rowName);
-            if (rd == null) {
-                rd = new RowData(row);
-                mRowByName.put(rowName, rd);
-            }
-            long blockStartTime = block.getStartTime();
-            long blockEndTime = block.getEndTime();
-            if (blockEndTime > rd.mEndTime) {
-                long start = Math.max(blockStartTime, rd.mEndTime);
-                rd.mElapsed += blockEndTime - start;
-                mTotalElapsed += blockEndTime - start;
-                rd.mEndTime = blockEndTime;
-            }
-            if (blockEndTime > maxVal)
-                maxVal = blockEndTime;
-
-            // Keep track of nested blocks by using a stack (for each row).
-            // Create a Segment object for each visible part of a block.
-            Block top = rd.top();
-            if (top == null) {
-                rd.push(block);
-                continue;
-            }
-
-            long topStartTime = top.getStartTime();
-            long topEndTime = top.getEndTime();
-            if (topEndTime >= blockStartTime) {
-                // Add this segment if it has a non-zero elapsed time.
-                if (topStartTime < blockStartTime) {
-                    Segment segment = new Segment(rd, top, topStartTime,
-                            blockStartTime);
-                    mSegmentList.add(segment);
-                }
-
-                // If this block starts where the previous (top) block ends,
-                // then pop off the top block.
-                if (topEndTime == blockStartTime)
-                    rd.pop();
-                rd.push(block);
-            } else {
-                // We may have to pop several frames here.
-                popFrames(rd, top, blockStartTime);
-                rd.push(block);
-            }
-        }
-
-        // Clean up the stack of each row
-        for (RowData rd : mRowByName.values()) {
-            Block top = rd.top();
-            popFrames(rd, top, Integer.MAX_VALUE);
-        }
-
-        mSurface.setRange(minVal, maxVal);
-        mSurface.setLimitRange(minVal, maxVal);
-
-        // Sort the rows into decreasing elapsed time
-        Collection<RowData> rv = mRowByName.values();
-        mRows = rv.toArray(new RowData[rv.size()]);
-        Arrays.sort(mRows, new Comparator<RowData>() {
-            public int compare(RowData rd1, RowData rd2) {
-                return (int) (rd2.mElapsed - rd1.mElapsed);
-            }
-        });
-
-        // Assign ranks to the sorted rows
-        for (int ii = 0; ii < mRows.length; ++ii) {
-            mRows[ii].mRank = ii;
-        }
-
-        // Compute the number of rows with data
-        mNumRows = 0;
-        for (int ii = 0; ii < mRows.length; ++ii) {
-            if (mRows[ii].mElapsed == 0)
-                break;
-            mNumRows += 1;
-        }
-
-        // Sort the blocks into increasing rows, and within rows into
-        // increasing start values.
-        mSegments = mSegmentList.toArray(new Segment[mSegmentList.size()]);
-        Arrays.sort(mSegments, new Comparator<Segment>() {
-            public int compare(Segment bd1, Segment bd2) {
-                RowData rd1 = bd1.mRowData;
-                RowData rd2 = bd2.mRowData;
-                int diff = rd1.mRank - rd2.mRank;
-                if (diff == 0) {
-                    long timeDiff = bd1.mStartTime - bd2.mStartTime;
-                    if (timeDiff == 0)
-                        timeDiff = bd1.mEndTime - bd2.mEndTime;
-                    return (int) timeDiff;
-                }
-                return diff;
-            }
-        });
-
-        if (false) {
-            for (Segment segment : mSegments) {
-                System.out.printf("seg '%s' [%6d, %6d] %s\n",
-                        segment.mRowData.mName, segment.mStartTime,
-                        segment.mEndTime, segment.mBlock.getName());
-                if (segment.mStartTime > segment.mEndTime) {
-                    System.err.printf("Error: segment startTime > endTime\n");
-                    System.exit(1);
-                }
-            }
-        }
-    }
-
-    private void popFrames(RowData rd, Block top, long startTime) {
-        long topEndTime = top.getEndTime();
-        long lastEndTime = top.getStartTime();
-        while (topEndTime <= startTime) {
-            if (topEndTime > lastEndTime) {
-                Segment segment = new Segment(rd, top, lastEndTime, topEndTime);
-                mSegmentList.add(segment);
-                lastEndTime = topEndTime;
-            }
-            rd.pop();
-            top = rd.top();
-            if (top == null)
-                return;
-            topEndTime = top.getEndTime();
-        }
-
-        // If we get here, then topEndTime > startTime
-        if (lastEndTime < startTime) {
-            Segment bd = new Segment(rd, top, lastEndTime, startTime);
-            mSegmentList.add(bd);
-        }
-    }
-
-    private class RowLabels extends Canvas {
-
-        /** The space between the row label and the sash line */
-        private static final int labelMarginX = 2;
-
-        public RowLabels(Composite parent) {
-            super(parent, SWT.NO_BACKGROUND);
-            addPaintListener(new PaintListener() {
-                public void paintControl(PaintEvent pe) {
-                    draw(pe.display, pe.gc);
-                }
-            });
-        }
-
-        private void mouseMove(MouseEvent me) {
-            int rownum = (me.y + mScrollOffsetY) / rowYSpace;
-            if (mMouseRow != rownum) {
-                mMouseRow = rownum;
-                redraw();
-                mSurface.redraw();
-            }
-        }
-
-        private void draw(Display display, GC gc) {
-            if (mSegments.length == 0) {
-                // gc.setBackground(colorBackground);
-                // gc.fillRectangle(getBounds());
-                return;
-            }
-            Point dim = getSize();
-
-            // Create an image for double-buffering
-            Image image = new Image(display, getBounds());
-
-            // Set up the off-screen gc
-            GC gcImage = new GC(image);
-            if (mSetFonts)
-                gcImage.setFont(mFontRegistry.get("medium"));  // $NON-NLS-1$
-
-            if (mNumRows > 2) {
-                // Draw the row background stripes
-                gcImage.setBackground(mColorRowBack);
-                for (int ii = 1; ii < mNumRows; ii += 2) {
-                    RowData rd = mRows[ii];
-                    int y1 = rd.mRank * rowYSpace - mScrollOffsetY;
-                    gcImage.fillRectangle(0, y1, dim.x, rowYSpace);
-                }
-            }
-
-            // Draw the row labels
-            int offsetY = rowYMarginHalf - mScrollOffsetY;
-            for (int ii = mStartRow; ii <= mEndRow; ++ii) {
-                RowData rd = mRows[ii];
-                int y1 = rd.mRank * rowYSpace + offsetY;
-                Point extent = gcImage.stringExtent(rd.mName);
-                int x1 = dim.x - extent.x - labelMarginX;
-                gcImage.drawString(rd.mName, x1, y1, true);
-            }
-
-            // Draw a highlight box on the row where the mouse is.
-            if (mMouseRow >= mStartRow && mMouseRow <= mEndRow) {
-                gcImage.setForeground(mColorGray);
-                int y1 = mMouseRow * rowYSpace - mScrollOffsetY;
-                gcImage.drawRectangle(0, y1, dim.x, rowYSpace);
-            }
-
-            // Draw the off-screen buffer to the screen
-            gc.drawImage(image, 0, 0);
-
-            // Clean up
-            image.dispose();
-            gcImage.dispose();
-        }
-    }
-    
-    private class BlankCorner extends Canvas {
-        public BlankCorner(Composite parent) {
-            //super(parent, SWT.NO_BACKGROUND);
-            super(parent, SWT.NONE);
-            addPaintListener(new PaintListener() {
-                public void paintControl(PaintEvent pe) {
-                    draw(pe.display, pe.gc);
-                }
-            });
-        }
-
-        private void draw(Display display, GC gc) {
-            // Create a blank image and draw it to the canvas
-            Image image = new Image(display, getBounds());
-            gc.drawImage(image, 0, 0);
-
-            // Clean up
-            image.dispose();
-        }
-    }
-
-    private class Timescale extends Canvas {
-        private Point mMouse = new Point(LeftMargin, 0);
-        private Cursor mZoomCursor;
-        private String mMethodName = null;
-        private Color mMethodColor = null;
-        private int mMethodStartY;
-        private int mMarkStartX;
-        private int mMarkEndX;
-        
-        /** The space between the colored block and the method name */
-        private static final int METHOD_BLOCK_MARGIN = 10;
-
-        public Timescale(Composite parent) {
-            //super(parent, SWT.NO_BACKGROUND);
-            super(parent, SWT.NONE);
-            Display display = getDisplay();
-            mZoomCursor = new Cursor(display, SWT.CURSOR_SIZEWE);
-            setCursor(mZoomCursor);
-            mMethodStartY = mSmallFontHeight + 1;
-            addPaintListener(new PaintListener() {
-                public void paintControl(PaintEvent pe) {
-                    draw(pe.display, pe.gc);
-                }
-            });
-        }
-
-        public void setVbarPosition(int x) {
-            mMouse.x = x;
-        }
-
-        public void setMarkStart(int x) {
-            mMarkStartX = x;
-        }
-
-        public void setMarkEnd(int x) {
-            mMarkEndX = x;
-        }
-        
-        public void setMethodName(String name) {
-            mMethodName = name;
-        }
-        
-        public void setMethodColor(Color color) {
-            mMethodColor = color;
-        }
-        
-        private void mouseMove(MouseEvent me) {
-            me.y = -1;
-            mSurface.mouseMove(me);
-        }
-        
-        private void mouseDown(MouseEvent me) {
-            mSurface.startScaling(me.x);
-            mSurface.redraw();
-        }
-        
-        private void mouseUp(MouseEvent me) {
-            mSurface.stopScaling(me.x);
-        }
-        
-        private void mouseDoubleClick(MouseEvent me) {
-            mSurface.resetScale();
-            mSurface.redraw();
-        }
-
-        private void draw(Display display, GC gc) {
-            Point dim = getSize();
-
-            // Create an image for double-buffering
-            Image image = new Image(display, getBounds());
-
-            // Set up the off-screen gc
-            GC gcImage = new GC(image);
-            if (mSetFonts)
-                gcImage.setFont(mFontRegistry.get("medium"));  // $NON-NLS-1$
-
-            if (mSurface.drawingSelection()) {
-                drawSelection(display, gcImage);
-            }
-            
-            drawTicks(display, gcImage);
-
-            // Draw the vertical bar where the mouse is
-            gcImage.setForeground(mColorDarkGray);
-            gcImage.drawLine(mMouse.x, timeLineOffsetY, mMouse.x, dim.y);
-            
-            // Draw the current millseconds
-            drawTickLegend(display, gcImage);
-            
-            // Draw the method name and color, if needed
-            drawMethod(display, gcImage);
-            
-            // Draw the off-screen buffer to the screen
-            gc.drawImage(image, 0, 0);
-
-            // Clean up
-            image.dispose();
-            gcImage.dispose();
-        }
-        
-        private void drawSelection(Display display, GC gc) {
-            Point dim = getSize();
-            gc.setForeground(mColorGray);
-            gc.drawLine(mMarkStartX, timeLineOffsetY, mMarkStartX, dim.y);
-            gc.setBackground(mColorZoomSelection);
-            int x, width;
-            if (mMarkStartX < mMarkEndX) {
-                x = mMarkStartX;
-                width = mMarkEndX - mMarkStartX;
-            } else {
-                x = mMarkEndX;
-                width = mMarkStartX - mMarkEndX;
-            }
-            if (width > 1) {
-                gc.fillRectangle(x, timeLineOffsetY, width, dim.y);
-            }
-        }
-
-        private void drawTickLegend(Display display, GC gc) {
-            int mouseX = mMouse.x - LeftMargin;
-            double mouseXval = mScaleInfo.pixelToValue(mouseX);
-            String info = mUnits.labelledString(mouseXval);
-            gc.setForeground(mColorForeground);
-            gc.drawString(info, LeftMargin + 2, 1, true);
-
-            // Display the maximum data value
-            double maxVal = mScaleInfo.getMaxVal();
-            info = mUnits.labelledString(maxVal);
-            info = String.format(" max %s ", info);  // $NON-NLS-1$
-            Point extent = gc.stringExtent(info);
-            Point dim = getSize();
-            int x1 = dim.x - RightMargin - extent.x;
-            gc.drawString(info, x1, 1, true);
-        }
-        
-        private void drawMethod(Display display, GC gc) {
-            if (mMethodName == null) {
-                return;
-            }
-
-            int x1 = LeftMargin;
-            int y1 = mMethodStartY;
-            gc.setBackground(mMethodColor);
-            int width = 2 * mSmallFontWidth;
-            gc.fillRectangle(x1, y1, width, mSmallFontHeight);
-            x1 += width + METHOD_BLOCK_MARGIN;
-            gc.drawString(mMethodName, x1, y1, true);
-        }
-        
-        private void drawTicks(Display display, GC gc) {
-            Point dim = getSize();
-            int y2 = majorTickLength + timeLineOffsetY;
-            int y3 = minorTickLength + timeLineOffsetY;
-            int y4 = y2 + tickToFontSpacing;
-            gc.setForeground(mColorForeground);
-            gc.drawLine(LeftMargin, timeLineOffsetY, dim.x - RightMargin,
-                    timeLineOffsetY);
-            double minVal = mScaleInfo.getMinVal();
-            double maxVal = mScaleInfo.getMaxVal();
-            double minMajorTick = mScaleInfo.getMinMajorTick();
-            double tickIncrement = mScaleInfo.getTickIncrement();
-            double minorTickIncrement = tickIncrement / 5;
-            double pixelsPerRange = mScaleInfo.getPixelsPerRange();
-            
-            // Draw the initial minor ticks, if any
-            if (minVal < minMajorTick) {
-                gc.setForeground(mColorGray);
-                double xMinor = minMajorTick;
-                for (int ii = 1; ii <= 4; ++ii) {
-                    xMinor -= minorTickIncrement;
-                    if (xMinor < minVal)
-                        break;
-                    int x1 = LeftMargin
-                            + (int) (0.5 + (xMinor - minVal) * pixelsPerRange);
-                    gc.drawLine(x1, timeLineOffsetY, x1, y3);
-                }
-            }
-            
-            if (tickIncrement <= 10) {
-                // TODO avoid rendering the loop when tickIncrement is invalid. It can be zero
-                // or too small.
-                // System.out.println(String.format("Timescale.drawTicks error: tickIncrement=%1f", tickIncrement));
-                return;
-            }
-            for (double x = minMajorTick; x <= maxVal; x += tickIncrement) {
-                int x1 = LeftMargin
-                        + (int) (0.5 + (x - minVal) * pixelsPerRange);
-
-                // Draw a major tick
-                gc.setForeground(mColorForeground);
-                gc.drawLine(x1, timeLineOffsetY, x1, y2);
-                if (x > maxVal)
-                    break;
-
-                // Draw the tick text
-                String tickString = mUnits.valueOf(x);
-                gc.drawString(tickString, x1, y4, true);
-
-                // Draw 4 minor ticks between major ticks
-                gc.setForeground(mColorGray);
-                double xMinor = x;
-                for (int ii = 1; ii <= 4; ii++) {
-                    xMinor += minorTickIncrement;
-                    if (xMinor > maxVal)
-                        break;
-                    x1 = LeftMargin
-                            + (int) (0.5 + (xMinor - minVal) * pixelsPerRange);
-                    gc.drawLine(x1, timeLineOffsetY, x1, y3);
-                }
-            }
-        }
-    }
-
-    private static enum GraphicsState {
-        Normal, Marking, Scaling, Animating
-    };
-
-    private class Surface extends Canvas {
-
-        public Surface(Composite parent) {
-            super(parent, SWT.NO_BACKGROUND | SWT.V_SCROLL);
-            Display display = getDisplay();
-            mNormalCursor = new Cursor(display, SWT.CURSOR_CROSS);
-            mIncreasingCursor = new Cursor(display, SWT.CURSOR_SIZEE);
-            mDecreasingCursor = new Cursor(display, SWT.CURSOR_SIZEW);
-
-            initZoomFractionsWithExp();
-
-            addPaintListener(new PaintListener() {
-                public void paintControl(PaintEvent pe) {
-                    draw(pe.display, pe.gc);
-                }
-            });
-
-            mZoomAnimator = new Runnable() {
-                public void run() {
-                    animateZoom();
-                }
-            };
-
-            mHighlightAnimator = new Runnable() {
-                public void run() {
-                    animateHighlight();
-                }
-            };
-        }
-
-        private void initZoomFractionsWithExp() {
-            mZoomFractions = new double[ZOOM_STEPS];
-            int next = 0;
-            for (int ii = 0; ii < ZOOM_STEPS / 2; ++ii, ++next) {
-                mZoomFractions[next] = (double) (1 << ii)
-                        / (double) (1 << (ZOOM_STEPS / 2));
-                // System.out.printf("%d %f\n", next, zoomFractions[next]);
-            }
-            for (int ii = 2; ii < 2 + ZOOM_STEPS / 2; ++ii, ++next) {
-                mZoomFractions[next] = (double) ((1 << ii) - 1)
-                        / (double) (1 << ii);
-                // System.out.printf("%d %f\n", next, zoomFractions[next]);
-            }
-        }
-
-        @SuppressWarnings("unused")
-        private void initZoomFractionsWithSinWave() {
-            mZoomFractions = new double[ZOOM_STEPS];
-            for (int ii = 0; ii < ZOOM_STEPS; ++ii) {
-                double offset = Math.PI * (double) ii / (double) ZOOM_STEPS;
-                mZoomFractions[ii] = (Math.sin((1.5 * Math.PI + offset)) + 1.0) / 2.0;
-                // System.out.printf("%d %f\n", ii, zoomFractions[ii]);
-            }
-        }
-
-        public void setRange(double minVal, double maxVal) {
-            mMinDataVal = minVal;
-            mMaxDataVal = maxVal;
-            mScaleInfo.setMinVal(minVal);
-            mScaleInfo.setMaxVal(maxVal);
-        }
-
-        public void setLimitRange(double minVal, double maxVal) {
-            mLimitMinVal = minVal;
-            mLimitMaxVal = maxVal;
-        }
-        
-        public void resetScale() {
-            mScaleInfo.setMinVal(mLimitMinVal);
-            mScaleInfo.setMaxVal(mLimitMaxVal);
-        }
-
-        private void draw(Display display, GC gc) {
-            if (mSegments.length == 0) {
-                // gc.setBackground(colorBackground);
-                // gc.fillRectangle(getBounds());
-                return;
-            }
-
-            // Create an image for double-buffering
-            Image image = new Image(display, getBounds());
-
-            // Set up the off-screen gc
-            GC gcImage = new GC(image);
-            if (mSetFonts)
-                gcImage.setFont(mFontRegistry.get("small"));  // $NON-NLS-1$
-
-            // Draw the background
-            // gcImage.setBackground(colorBackground);
-            // gcImage.fillRectangle(image.getBounds());
-
-            if (mGraphicsState == GraphicsState.Scaling) {
-                double diff = mMouse.x - mMouseMarkStartX;
-                if (diff > 0) {
-                    double newMinVal = mScaleMinVal - diff / mScalePixelsPerRange;
-                    if (newMinVal < mLimitMinVal)
-                        newMinVal = mLimitMinVal;
-                    mScaleInfo.setMinVal(newMinVal);
-                    // System.out.printf("diff %f scaleMin %f newMin %f\n",
-                    // diff, scaleMinVal, newMinVal);
-                } else if (diff < 0) {
-                    double newMaxVal = mScaleMaxVal - diff / mScalePixelsPerRange;
-                    if (newMaxVal > mLimitMaxVal)
-                        newMaxVal = mLimitMaxVal;
-                    mScaleInfo.setMaxVal(newMaxVal);
-                    // System.out.printf("diff %f scaleMax %f newMax %f\n",
-                    // diff, scaleMaxVal, newMaxVal);
-                }
-            }
-
-            // Recompute the ticks and strips only if the size has changed,
-            // or we scrolled so that a new row is visible.
-            Point dim = getSize();
-            if (mStartRow != mCachedStartRow || mEndRow != mCachedEndRow 
-                    || mScaleInfo.getMinVal() != mCachedMinVal
-                    || mScaleInfo.getMaxVal() != mCachedMaxVal) {
-                mCachedStartRow = mStartRow;
-                mCachedEndRow = mEndRow;
-                int xdim = dim.x - TotalXMargin;
-                mScaleInfo.setNumPixels(xdim);
-                boolean forceEndPoints = (mGraphicsState == GraphicsState.Scaling
-                        || mGraphicsState == GraphicsState.Animating);
-                mScaleInfo.computeTicks(forceEndPoints);
-                mCachedMinVal = mScaleInfo.getMinVal();
-                mCachedMaxVal = mScaleInfo.getMaxVal();
-                if (mLimitMinVal > mScaleInfo.getMinVal())
-                    mLimitMinVal = mScaleInfo.getMinVal();
-                if (mLimitMaxVal < mScaleInfo.getMaxVal())
-                    mLimitMaxVal = mScaleInfo.getMaxVal();
-
-                // Compute the strips
-                computeStrips();
-            }
-
-            if (mNumRows > 2) {
-                // Draw the row background stripes
-                gcImage.setBackground(mColorRowBack);
-                for (int ii = 1; ii < mNumRows; ii += 2) {
-                    RowData rd = mRows[ii];
-                    int y1 = rd.mRank * rowYSpace - mScrollOffsetY;
-                    gcImage.fillRectangle(0, y1, dim.x, rowYSpace);
-                }
-            }
-
-            if (drawingSelection()) {
-                drawSelection(display, gcImage);
-            }
-
-            String blockName = null;
-            Color blockColor = null;
-
-            if (mDebug) {
-                double pixelsPerRange = mScaleInfo.getPixelsPerRange();
-                System.out
-                        .printf(
-                                "dim.x %d pixels %d minVal %f, maxVal %f ppr %f rpp %f\n",
-                                dim.x, dim.x - TotalXMargin, mScaleInfo
-                                        .getMinVal(), mScaleInfo.getMaxVal(),
-                                pixelsPerRange, 1.0 / pixelsPerRange);
-            }
-
-            // Draw the strips
-            Block selectBlock = null;
-            for (Strip strip : mStripList) {
-                if (strip.mColor == null) {
-                    // System.out.printf("strip.color is null\n");
-                    continue;
-                }
-                gcImage.setBackground(strip.mColor);
-                gcImage.fillRectangle(strip.mX, strip.mY - mScrollOffsetY, strip.mWidth,
-                        strip.mHeight);
-                if (mMouseRow == strip.mRowData.mRank) {
-                    if (mMouse.x >= strip.mX
-                            && mMouse.x < strip.mX + strip.mWidth) {
-                        blockName = strip.mSegment.mBlock.getName();
-                        blockColor = strip.mColor;
-                    }
-                    if (mMouseSelect.x >= strip.mX
-                            && mMouseSelect.x < strip.mX + strip.mWidth) {
-                        selectBlock = strip.mSegment.mBlock;
-                    }
-                }
-            }
-            mMouseSelect.x = 0;
-            mMouseSelect.y = 0;
-
-            if (selectBlock != null) {
-                ArrayList<Selection> selections = new ArrayList<Selection>();
-                // Get the row label
-                RowData rd = mRows[mMouseRow];
-                selections.add(Selection.highlight("Thread", rd.mName));  // $NON-NLS-1$
-                selections.add(Selection.highlight("Call", selectBlock));  // $NON-NLS-1$
-
-                int mouseX = mMouse.x - LeftMargin;
-                double mouseXval = mScaleInfo.pixelToValue(mouseX);
-                selections.add(Selection.highlight("Time", mouseXval));  // $NON-NLS-1$
-                
-                mSelectionController.change(selections, "TimeLineView");  // $NON-NLS-1$
-                mHighlightMethodData = null;
-                mHighlightCall = (Call) selectBlock;
-                startHighlighting();
-            }
-
-            // Draw a highlight box on the row where the mouse is.
-            // Except don't draw the box if we are animating the
-            // highlighing of a call or method because the inclusive
-            // highlight bar passes through the highlight box and
-            // causes an annoying flashing artifact.
-            if (mMouseRow >= 0 && mMouseRow < mNumRows && mHighlightStep == 0) {
-                gcImage.setForeground(mColorGray);
-                int y1 = mMouseRow * rowYSpace - mScrollOffsetY;
-                gcImage.drawLine(0, y1, dim.x, y1);
-                gcImage.drawLine(0, y1 + rowYSpace, dim.x, y1 + rowYSpace);
-            }
-
-            // Highlight a selected method, if any
-            drawHighlights(gcImage, dim);
-
-            // Draw a vertical line where the mouse is.
-            gcImage.setForeground(mColorDarkGray);
-            int lineEnd = Math.min(dim.y, mNumRows * rowYSpace);
-            gcImage.drawLine(mMouse.x, 0, mMouse.x, lineEnd);
-
-            if (blockName != null) {
-                mTimescale.setMethodName(blockName);
-                mTimescale.setMethodColor(blockColor);
-                mShowHighlightName = false;
-            } else if (mShowHighlightName) {
-                // Draw the highlighted method name
-                MethodData md = mHighlightMethodData;
-                if (md == null && mHighlightCall != null)
-                    md = mHighlightCall.getMethodData();
-                if (md == null)
-                    System.out.printf("null highlight?\n");  // $NON-NLS-1$
-                if (md != null) {
-                    mTimescale.setMethodName(md.getProfileName());
-                    mTimescale.setMethodColor(md.getColor());
-                }
-            } else {
-                mTimescale.setMethodName(null);
-                mTimescale.setMethodColor(null);
-            }
-            mTimescale.redraw();
-
-            // Draw the off-screen buffer to the screen
-            gc.drawImage(image, 0, 0);
-
-            // Clean up
-            image.dispose();
-            gcImage.dispose();
-        }
-
-        private void drawHighlights(GC gc, Point dim) {
-            int height = highlightHeight;
-            if (height <= 0)
-                return;
-            for (Range range : mHighlightExclusive) {
-                gc.setBackground(range.mColor);
-                int xStart = range.mXdim.x;
-                int width = range.mXdim.y;
-                gc.fillRectangle(xStart, range.mY - height - mScrollOffsetY, width, height);
-            }
-
-            // Draw the inclusive lines a bit shorter
-            height -= 1;
-            if (height <= 0)
-                height = 1;
-
-            // Highlight the inclusive ranges
-            gc.setForeground(mColorDarkGray);
-            gc.setBackground(mColorDarkGray);
-            for (Range range : mHighlightInclusive) {
-                int x1 = range.mXdim.x;
-                int x2 = range.mXdim.y;
-                boolean drawLeftEnd = false;
-                boolean drawRightEnd = false;
-                if (x1 >= LeftMargin)
-                    drawLeftEnd = true;
-                else
-                    x1 = LeftMargin;
-                if (x2 >= LeftMargin)
-                    drawRightEnd = true;
-                else
-                    x2 = dim.x - RightMargin;
-                int y1 = range.mY + rowHeight + 2 - mScrollOffsetY;
-
-                // If the range is very narrow, then just draw a small
-                // rectangle.
-                if (x2 - x1 < MinInclusiveRange) {
-                    int width = x2 - x1;
-                    if (width < 2)
-                        width = 2;
-                    gc.fillRectangle(x1, y1, width, height);
-                    continue;
-                }
-                if (drawLeftEnd) {
-                    if (drawRightEnd) {
-                        // Draw both ends
-                        int[] points = { x1, y1, x1, y1 + height, x2,
-                                y1 + height, x2, y1 };
-                        gc.drawPolyline(points);
-                    } else {
-                        // Draw the left end
-                        int[] points = { x1, y1, x1, y1 + height, x2,
-                                y1 + height };
-                        gc.drawPolyline(points);
-                    }
-                } else {
-                    if (drawRightEnd) {
-                        // Draw the right end
-                        int[] points = { x1, y1 + height, x2, y1 + height, x2,
-                                y1 };
-                        gc.drawPolyline(points);
-                    } else {
-                        // Draw neither end, just the line
-                        int[] points = { x1, y1 + height, x2, y1 + height };
-                        gc.drawPolyline(points);
-                    }
-                }
-
-                // Draw the arrowheads, if necessary
-                if (drawLeftEnd == false) {
-                    int[] points = { x1 + 7, y1 + height - 4, x1, y1 + height,
-                            x1 + 7, y1 + height + 4 };
-                    gc.fillPolygon(points);
-                }
-                if (drawRightEnd == false) {
-                    int[] points = { x2 - 7, y1 + height - 4, x2, y1 + height,
-                            x2 - 7, y1 + height + 4 };
-                    gc.fillPolygon(points);
-                }
-            }
-        }
-
-        private boolean drawingSelection() {
-            return mGraphicsState == GraphicsState.Marking
-                    || mGraphicsState == GraphicsState.Animating;
-        }
-        
-        private void drawSelection(Display display, GC gc) {
-            Point dim = getSize();
-            gc.setForeground(mColorGray);
-            gc.drawLine(mMouseMarkStartX, 0, mMouseMarkStartX, dim.y);
-            gc.setBackground(mColorZoomSelection);
-            int width;
-            int mouseX = (mGraphicsState == GraphicsState.Animating) ? mMouseMarkEndX : mMouse.x;
-            int x;
-            if (mMouseMarkStartX < mouseX) {
-                x = mMouseMarkStartX;
-                width = mouseX - mMouseMarkStartX;
-            } else {
-                x = mouseX;
-                width = mMouseMarkStartX - mouseX;
-            }
-            gc.fillRectangle(x, 0, width, dim.y);
-        }
-
-        private void computeStrips() {
-            double minVal = mScaleInfo.getMinVal();
-            double maxVal = mScaleInfo.getMaxVal();
-
-            // Allocate space for the pixel data
-            Pixel[] pixels = new Pixel[mNumRows];
-            for (int ii = 0; ii < mNumRows; ++ii)
-                pixels[ii] = new Pixel();
-
-            // Clear the per-block pixel data
-            for (int ii = 0; ii < mSegments.length; ++ii) {
-                mSegments[ii].mBlock.clearWeight();
-            }
-
-            mStripList.clear();
-            mHighlightExclusive.clear();
-            mHighlightInclusive.clear();
-            MethodData callMethod = null;
-            long callStart = 0;
-            long callEnd = -1;
-            RowData callRowData = null;
-            int prevMethodStart = -1;
-            int prevCallStart = -1;
-            if (mHighlightCall != null) {
-                int callPixelStart = -1;
-                int callPixelEnd = -1;
-                callStart = mHighlightCall.mGlobalStartTime;
-                callEnd = mHighlightCall.mGlobalEndTime;
-                callMethod = mHighlightCall.mMethodData;
-                if (callStart >= minVal)
-                    callPixelStart = mScaleInfo.valueToPixel(callStart);
-                if (callEnd <= maxVal)
-                    callPixelEnd = mScaleInfo.valueToPixel(callEnd);
-                // System.out.printf("callStart,End %d,%d minVal,maxVal %f,%f
-                // callPixelStart,End %d,%d\n",
-                // callStart, callEnd, minVal, maxVal, callPixelStart,
-                // callPixelEnd);
-                int threadId = mHighlightCall.getThreadId();
-                String threadName = mThreadLabels.get(threadId);
-                callRowData = mRowByName.get(threadName);
-                int y1 = callRowData.mRank * rowYSpace + rowYMarginHalf;
-                Color color = callMethod.getColor();
-                mHighlightInclusive.add(new Range(callPixelStart + LeftMargin,
-                        callPixelEnd + LeftMargin, y1, color));
-            }
-            for (Segment segment : mSegments) {
-                if (segment.mEndTime <= minVal)
-                    continue;
-                if (segment.mStartTime >= maxVal)
-                    continue;
-                Block block = segment.mBlock;
-                Color color = block.getColor();
-                if (color == null)
-                    continue;
-
-                double recordStart = Math.max(segment.mStartTime, minVal);
-                double recordEnd = Math.min(segment.mEndTime, maxVal);
-                if (recordStart == recordEnd)
-                    continue;
-                int pixelStart = mScaleInfo.valueToPixel(recordStart);
-                int pixelEnd = mScaleInfo.valueToPixel(recordEnd);
-                int width = pixelEnd - pixelStart;
-
-                RowData rd = segment.mRowData;
-                MethodData md = block.getMethodData();
-
-                // We will add the scroll offset later when we draw the strips
-                int y1 = rd.mRank * rowYSpace + rowYMarginHalf;
-
-                // If we can't display any more rows, then quit
-                if (rd.mRank > mEndRow)
-                    break;
-
-                // System.out.printf("segment %s val: [%.1f, %.1f] frac [%f, %f]
-                // pixel: [%d, %d] pix.start %d weight %.2f %s\n",
-                // block.getName(), recordStart, recordEnd,
-                // scaleInfo.valueToPixelFraction(recordStart),
-                // scaleInfo.valueToPixelFraction(recordEnd),
-                // pixelStart, pixelEnd, pixels[rd.rank].start,
-                // pixels[rd.rank].maxWeight,
-                // pixels[rd.rank].segment != null
-                // ? pixels[rd.rank].segment.block.getName()
-                // : "null");
-
-                if (mHighlightMethodData != null) {
-                    if (mHighlightMethodData == md) {
-                        if (prevMethodStart != pixelStart) {
-                            prevMethodStart = pixelStart;
-                            int rangeWidth = width;
-                            if (rangeWidth == 0)
-                                rangeWidth = 1;
-                            mHighlightExclusive.add(new Range(pixelStart
-                                    + LeftMargin, rangeWidth, y1, color));
-                            Call call = (Call) block;
-                            callStart = call.mGlobalStartTime;
-                            int callPixelStart = -1;
-                            if (callStart >= minVal)
-                                callPixelStart = mScaleInfo.valueToPixel(callStart);
-                            if (prevCallStart != callPixelStart) {
-                                prevCallStart = callPixelStart;
-                                int callPixelEnd = -1;
-                                callEnd = call.mGlobalEndTime;
-                                if (callEnd <= maxVal)
-                                    callPixelEnd = mScaleInfo.valueToPixel(callEnd);
-                                mHighlightInclusive.add(new Range(
-                                        callPixelStart + LeftMargin,
-                                        callPixelEnd + LeftMargin, y1, color));
-                            }
-                        }
-                    } else if (mFadeColors) {
-                        color = md.getFadedColor();
-                    }
-                } else if (mHighlightCall != null) {
-                    if (segment.mStartTime >= callStart
-                            && segment.mEndTime <= callEnd && callMethod == md
-                            && callRowData == rd) {
-                        if (prevMethodStart != pixelStart) {
-                            prevMethodStart = pixelStart;
-                            int rangeWidth = width;
-                            if (rangeWidth == 0)
-                                rangeWidth = 1;
-                            mHighlightExclusive.add(new Range(pixelStart
-                                    + LeftMargin, rangeWidth, y1, color));
-                        }
-                    } else if (mFadeColors) {
-                        color = md.getFadedColor();
-                    }
-                }
-
-                // Cases:
-                // 1. This segment starts on a different pixel than the
-                // previous segment started on. In this case, emit
-                // the pixel strip, if any, and:
-                // A. If the width is 0, then add this segment's
-                // weight to the Pixel.
-                // B. If the width > 0, then emit a strip for this
-                // segment (no partial Pixel data).
-                //
-                // 2. Otherwise (the new segment starts on the same
-                // pixel as the previous segment): add its "weight"
-                // to the current pixel, and:
-                // A. If the new segment has width 1,
-                // then emit the pixel strip and then
-                // add the segment's weight to the pixel.
-                // B. If the new segment has width > 1,
-                // then emit the pixel strip, and emit the rest
-                // of the strip for this segment (no partial Pixel
-                // data).
-
-                Pixel pix = pixels[rd.mRank];
-                if (pix.mStart != pixelStart) {
-                    if (pix.mSegment != null) {
-                        // Emit the pixel strip. This also clears the pixel.
-                        emitPixelStrip(rd, y1, pix);
-                    }
-
-                    if (width == 0) {
-                        // Compute the "weight" of this segment for the first
-                        // pixel. For a pixel N, the "weight" of a segment is
-                        // how much of the region [N - 0.5, N + 0.5] is covered
-                        // by the segment.
-                        double weight = computeWeight(recordStart, recordEnd,
-                                pixelStart);
-                        weight = block.addWeight(pixelStart, rd.mRank, weight);
-                        if (weight > pix.mMaxWeight) {
-                            pix.setFields(pixelStart, weight, segment, color,
-                                    rd);
-                        }
-                    } else {
-                        int x1 = pixelStart + LeftMargin;
-                        Strip strip = new Strip(x1, y1, width, rowHeight, rd,
-                                segment, color);
-                        mStripList.add(strip);
-                    }
-                } else {
-                    double weight = computeWeight(recordStart, recordEnd,
-                            pixelStart);
-                    weight = block.addWeight(pixelStart, rd.mRank, weight);
-                    if (weight > pix.mMaxWeight) {
-                        pix.setFields(pixelStart, weight, segment, color, rd);
-                    }
-                    if (width == 1) {
-                        // Emit the pixel strip. This also clears the pixel.
-                        emitPixelStrip(rd, y1, pix);
-
-                        // Compute the weight for the next pixel
-                        pixelStart += 1;
-                        weight = computeWeight(recordStart, recordEnd,
-                                pixelStart);
-                        weight = block.addWeight(pixelStart, rd.mRank, weight);
-                        pix.setFields(pixelStart, weight, segment, color, rd);
-                    } else if (width > 1) {
-                        // Emit the pixel strip. This also clears the pixel.
-                        emitPixelStrip(rd, y1, pix);
-
-                        // Emit a strip for the rest of the segment.
-                        pixelStart += 1;
-                        width -= 1;
-                        int x1 = pixelStart + LeftMargin;
-                        Strip strip = new Strip(x1, y1, width, rowHeight, rd,
-                                segment, color);
-                        mStripList.add(strip);
-                    }
-                }
-            }
-
-            // Emit the last pixels of each row, if any
-            for (int ii = 0; ii < mNumRows; ++ii) {
-                Pixel pix = pixels[ii];
-                if (pix.mSegment != null) {
-                    RowData rd = pix.mRowData;
-                    int y1 = rd.mRank * rowYSpace + rowYMarginHalf;
-                    // Emit the pixel strip. This also clears the pixel.
-                    emitPixelStrip(rd, y1, pix);
-                }
-            }
-
-            if (false) {
-                System.out.printf("computeStrips()\n");
-                for (Strip strip : mStripList) {
-                    System.out.printf("%3d, %3d width %3d height %d %s\n",
-                            strip.mX, strip.mY, strip.mWidth, strip.mHeight,
-                            strip.mSegment.mBlock.getName());
-                }
-            }
-        }
-
-        private double computeWeight(double start, double end, int pixel) {
-            double pixelStartFraction = mScaleInfo.valueToPixelFraction(start);
-            double pixelEndFraction = mScaleInfo.valueToPixelFraction(end);
-            double leftEndPoint = Math.max(pixelStartFraction, pixel - 0.5);
-            double rightEndPoint = Math.min(pixelEndFraction, pixel + 0.5);
-            double weight = rightEndPoint - leftEndPoint;
-            return weight;
-        }
-
-        private void emitPixelStrip(RowData rd, int y, Pixel pixel) {
-            Strip strip;
-
-            if (pixel.mSegment == null)
-                return;
-
-            int x = pixel.mStart + LeftMargin;
-            // Compute the percentage of the row height proportional to
-            // the weight of this pixel. But don't let the proportion
-            // exceed 3/4 of the row height so that we can easily see
-            // if a given time range includes more than one method.
-            int height = (int) (pixel.mMaxWeight * rowHeight * 0.75);
-            if (height < mMinStripHeight)
-                height = mMinStripHeight;
-            int remainder = rowHeight - height;
-            if (remainder > 0) {
-                strip = new Strip(x, y, 1, remainder, rd, pixel.mSegment,
-                        mFadeColors ? mColorGray : mColorBlack);
-                mStripList.add(strip);
-                // System.out.printf("emitPixel (%d, %d) height %d black\n",
-                // x, y, remainder);
-            }
-            strip = new Strip(x, y + remainder, 1, height, rd, pixel.mSegment,
-                    pixel.mColor);
-            mStripList.add(strip);
-            // System.out.printf("emitPixel (%d, %d) height %d %s\n",
-            // x, y + remainder, height, pixel.segment.block.getName());
-            pixel.mSegment = null;
-            pixel.mMaxWeight = 0.0;
-        }
-
-        private void mouseMove(MouseEvent me) {
-            if (false) {
-                if (mHighlightMethodData != null) {
-                    mHighlightMethodData = null;
-                    // Force a recomputation of the strip colors
-                    mCachedEndRow = -1;
-                }
-            }
-            Point dim = mSurface.getSize();
-            int x = me.x;
-            if (x < LeftMargin)
-                x = LeftMargin;
-            if (x > dim.x - RightMargin)
-                x = dim.x - RightMargin;
-            mMouse.x = x;
-            mMouse.y = me.y;
-            mTimescale.setVbarPosition(x);
-            if (mGraphicsState == GraphicsState.Marking) {
-                mTimescale.setMarkEnd(x);
-            }
-
-            if (mGraphicsState == GraphicsState.Normal) {
-                // Set the cursor to the normal state.
-                mSurface.setCursor(mNormalCursor);
-            } else if (mGraphicsState == GraphicsState.Marking) {
-                // Make the cursor point in the direction of the sweep
-                if (mMouse.x >= mMouseMarkStartX)
-                    mSurface.setCursor(mIncreasingCursor);
-                else
-                    mSurface.setCursor(mDecreasingCursor);
-            }
-            int rownum = (mMouse.y + mScrollOffsetY) / rowYSpace;
-            if (me.y < 0 || me.y >= dim.y) {
-                rownum = -1;
-            }
-            if (mMouseRow != rownum) {
-                mMouseRow = rownum;
-                mLabels.redraw();
-            }
-            redraw();
-        }
-
-        private void mouseDown(MouseEvent me) {
-            Point dim = mSurface.getSize();
-            int x = me.x;
-            if (x < LeftMargin)
-                x = LeftMargin;
-            if (x > dim.x - RightMargin)
-                x = dim.x - RightMargin;
-            mMouseMarkStartX = x;
-            mGraphicsState = GraphicsState.Marking;
-            mSurface.setCursor(mIncreasingCursor);
-            mTimescale.setMarkStart(mMouseMarkStartX);
-            mTimescale.setMarkEnd(mMouseMarkStartX);
-            redraw();
-        }
-
-        private void mouseUp(MouseEvent me) {
-            mSurface.setCursor(mNormalCursor);
-            if (mGraphicsState != GraphicsState.Marking) {
-                mGraphicsState = GraphicsState.Normal;
-                return;
-            }
-            mGraphicsState = GraphicsState.Animating;
-            Point dim = mSurface.getSize();
-
-            // If the user released the mouse outside the drawing area then
-            // cancel the zoom.
-            if (me.y <= 0 || me.y >= dim.y) {
-                mGraphicsState = GraphicsState.Normal;
-                redraw();
-                return;
-            }
-
-            int x = me.x;
-            if (x < LeftMargin)
-                x = LeftMargin;
-            if (x > dim.x - RightMargin)
-                x = dim.x - RightMargin;
-            mMouseMarkEndX = x;
-
-            // If the user clicked and released the mouse at the same point
-            // (+/- a pixel or two) then cancel the zoom (but select the
-            // method).
-            int dist = mMouseMarkEndX - mMouseMarkStartX;
-            if (dist < 0)
-                dist = -dist;
-            if (dist <= 2) {
-                mGraphicsState = GraphicsState.Normal;
-
-                // Select the method underneath the mouse
-                mMouseSelect.x = mMouseMarkStartX;
-                mMouseSelect.y = me.y;
-                redraw();
-                return;
-            }
-
-            // Make mouseEndX be the higher end point
-            if (mMouseMarkEndX < mMouseMarkStartX) {
-                int temp = mMouseMarkEndX;
-                mMouseMarkEndX = mMouseMarkStartX;
-                mMouseMarkStartX = temp;
-            }
-
-            // If the zoom area is the whole window (or nearly the whole
-            // window) then cancel the zoom.
-            if (mMouseMarkStartX <= LeftMargin + MinZoomPixelMargin
-                    && mMouseMarkEndX >= dim.x - RightMargin - MinZoomPixelMargin) {
-                mGraphicsState = GraphicsState.Normal;
-                redraw();
-                return;
-            }
-
-            // Compute some variables needed for zooming.
-            // It's probably easiest to explain by an example. There
-            // are two scales (or dimensions) involved: one for the pixels
-            // and one for the values (microseconds). To keep the example
-            // simple, suppose we have pixels in the range [0,16] and
-            // values in the range [100, 260], and suppose the user
-            // selects a zoom window from pixel 4 to pixel 8.
-            //
-            // usec: 100 140 180 260
-            // |-------|ZZZZZZZ|---------------|
-            // pixel: 0 4 8 16
-            //
-            // I've drawn the pixels starting at zero for simplicity, but
-            // in fact the drawable area is offset from the left margin
-            // by the value of "LeftMargin".
-            //
-            // The "pixels-per-range" (ppr) in this case is 0.1 (a tenth of
-            // a pixel per usec). What we want is to redraw the screen in
-            // several steps, each time increasing the zoom window until the
-            // zoom window fills the screen. For simplicity, assume that
-            // we want to zoom in four equal steps. Then the snapshots
-            // of the screen at each step would look something like this:
-            //
-            // usec: 100 140 180 260
-            // |-------|ZZZZZZZ|---------------|
-            // pixel: 0 4 8 16
-            //
-            // usec: ? 140 180 ?
-            // |-----|ZZZZZZZZZZZZZ|-----------|
-            // pixel: 0 3 10 16
-            //
-            // usec: ? 140 180 ?
-            // |---|ZZZZZZZZZZZZZZZZZZZ|-------|
-            // pixel: 0 2 12 16
-            //
-            // usec: ?140 180 ?
-            // |-|ZZZZZZZZZZZZZZZZZZZZZZZZZ|---|
-            // pixel: 0 1 14 16
-            //
-            // usec: 140 180
-            // |ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ|
-            // pixel: 0 16
-            //
-            // The problem is how to compute the endpoints (denoted by ?)
-            // for each step. This is a little tricky. We first need to
-            // compute the "fixed point": this is the point in the selection
-            // that doesn't move left or right. Then we can recompute the
-            // "ppr" (pixels per range) at each step and then find the
-            // endpoints. The computation of the end points is done
-            // in animateZoom(). This method computes the fixed point
-            // and some other variables needed in animateZoom().
-
-            double minVal = mScaleInfo.getMinVal();
-            double maxVal = mScaleInfo.getMaxVal();
-            double ppr = mScaleInfo.getPixelsPerRange();
-            mZoomMin = minVal + ((mMouseMarkStartX - LeftMargin) / ppr);
-            mZoomMax = minVal + ((mMouseMarkEndX - LeftMargin) / ppr);
-
-            // Clamp the min and max values to the actual data min and max
-            if (mZoomMin < mMinDataVal)
-                mZoomMin = mMinDataVal;
-            if (mZoomMax > mMaxDataVal)
-                mZoomMax = mMaxDataVal;
-
-            // Snap the min and max points to the grid determined by the
-            // TickScaler
-            // before we zoom.
-            int xdim = dim.x - TotalXMargin;
-            TickScaler scaler = new TickScaler(mZoomMin, mZoomMax, xdim,
-                    PixelsPerTick);
-            scaler.computeTicks(false);
-            mZoomMin = scaler.getMinVal();
-            mZoomMax = scaler.getMaxVal();
-
-            // Also snap the mouse points (in pixel space) to be consistent with
-            // zoomMin and zoomMax (in value space).
-            mMouseMarkStartX = (int) ((mZoomMin - minVal) * ppr + LeftMargin);
-            mMouseMarkEndX = (int) ((mZoomMax - minVal) * ppr + LeftMargin);
-            mTimescale.setMarkStart(mMouseMarkStartX);
-            mTimescale.setMarkEnd(mMouseMarkEndX);
-
-            // Compute the mouse selection end point distances
-            mMouseEndDistance = dim.x - RightMargin - mMouseMarkEndX;
-            mMouseStartDistance = mMouseMarkStartX - LeftMargin;
-            mZoomMouseStart = mMouseMarkStartX;
-            mZoomMouseEnd = mMouseMarkEndX;
-            mZoomStep = 0;
-
-            // Compute the fixed point in both value space and pixel space.
-            mMin2ZoomMin = mZoomMin - minVal;
-            mZoomMax2Max = maxVal - mZoomMax;
-            mZoomFixed = mZoomMin + (mZoomMax - mZoomMin) * mMin2ZoomMin
-                    / (mMin2ZoomMin + mZoomMax2Max);
-            mZoomFixedPixel = (mZoomFixed - minVal) * ppr + LeftMargin;
-            mFixedPixelStartDistance = mZoomFixedPixel - LeftMargin;
-            mFixedPixelEndDistance = dim.x - RightMargin - mZoomFixedPixel;
-
-            mZoomMin2Fixed = mZoomFixed - mZoomMin;
-            mFixed2ZoomMax = mZoomMax - mZoomFixed;
-
-            getDisplay().timerExec(ZOOM_TIMER_INTERVAL, mZoomAnimator);
-            redraw();
-            update();
-        }
-
-        // No defined behavior yet for double-click.
-        private void mouseDoubleClick(MouseEvent me) {
-        }
-        
-        public void startScaling(int mouseX) {
-            Point dim = mSurface.getSize();
-            int x = mouseX;
-            if (x < LeftMargin)
-                x = LeftMargin;
-            if (x > dim.x - RightMargin)
-                x = dim.x - RightMargin;
-            mMouseMarkStartX = x;
-            mGraphicsState = GraphicsState.Scaling;
-            mScalePixelsPerRange = mScaleInfo.getPixelsPerRange();
-            mScaleMinVal = mScaleInfo.getMinVal();
-            mScaleMaxVal = mScaleInfo.getMaxVal();
-        }
-
-        public void stopScaling(int mouseX) {
-            mGraphicsState = GraphicsState.Normal;
-        }
-        
-        private void animateHighlight() {
-            mHighlightStep += 1;
-            if (mHighlightStep >= HIGHLIGHT_STEPS) {
-                mFadeColors = false;
-                mHighlightStep = 0;
-                // Force a recomputation of the strip colors
-                mCachedEndRow = -1;
-            } else {
-                mFadeColors = true;
-                mShowHighlightName = true;
-                highlightHeight = highlightHeights[mHighlightStep];
-                getDisplay().timerExec(HIGHLIGHT_TIMER_INTERVAL, mHighlightAnimator);
-            }
-            redraw();
-        }
-
-        private void clearHighlights() {
-            // System.out.printf("clearHighlights()\n");
-            mShowHighlightName = false;
-            highlightHeight = 0;
-            mHighlightMethodData = null;
-            mHighlightCall = null;
-            mFadeColors = false;
-            mHighlightStep = 0;
-            // Force a recomputation of the strip colors
-            mCachedEndRow = -1;
-            redraw();
-        }
-
-        private void animateZoom() {
-            mZoomStep += 1;
-            if (mZoomStep > ZOOM_STEPS) {
-                mGraphicsState = GraphicsState.Normal;
-                // Force a normal recomputation
-                mCachedMinVal = mScaleInfo.getMinVal() + 1;
-            } else if (mZoomStep == ZOOM_STEPS) {
-                mScaleInfo.setMinVal(mZoomMin);
-                mScaleInfo.setMaxVal(mZoomMax);
-                mMouseMarkStartX = LeftMargin;
-                Point dim = getSize();
-                mMouseMarkEndX = dim.x - RightMargin;
-                mTimescale.setMarkStart(mMouseMarkStartX);
-                mTimescale.setMarkEnd(mMouseMarkEndX);
-                getDisplay().timerExec(ZOOM_TIMER_INTERVAL, mZoomAnimator);
-            } else {
-                // Zoom in slowly at first, then speed up, then slow down.
-                // The zoom fractions are precomputed to save time.
-                double fraction = mZoomFractions[mZoomStep];
-                mMouseMarkStartX = (int) (mZoomMouseStart - fraction * mMouseStartDistance);
-                mMouseMarkEndX = (int) (mZoomMouseEnd + fraction * mMouseEndDistance);
-                mTimescale.setMarkStart(mMouseMarkStartX);
-                mTimescale.setMarkEnd(mMouseMarkEndX);
-
-                // Compute the new pixels-per-range. Avoid division by zero.
-                double ppr;
-                if (mZoomMin2Fixed >= mFixed2ZoomMax)
-                    ppr = (mZoomFixedPixel - mMouseMarkStartX) / mZoomMin2Fixed;
-                else
-                    ppr = (mMouseMarkEndX - mZoomFixedPixel) / mFixed2ZoomMax;
-                double newMin = mZoomFixed - mFixedPixelStartDistance / ppr;
-                double newMax = mZoomFixed + mFixedPixelEndDistance / ppr;
-                mScaleInfo.setMinVal(newMin);
-                mScaleInfo.setMaxVal(newMax);
-
-                getDisplay().timerExec(ZOOM_TIMER_INTERVAL, mZoomAnimator);
-            }
-            redraw();
-        }
-
-        private static final int TotalXMargin = LeftMargin + RightMargin;
-        private static final int yMargin = 1; // blank space on top
-        // The minimum margin on each side of the zoom window, in pixels.
-        private static final int MinZoomPixelMargin = 10;
-        private GraphicsState mGraphicsState = GraphicsState.Normal;
-        private Point mMouse = new Point(LeftMargin, 0);
-        private int mMouseMarkStartX;
-        private int mMouseMarkEndX;
-        private boolean mDebug = false;
-        private ArrayList<Strip> mStripList = new ArrayList<Strip>();
-        private ArrayList<Range> mHighlightExclusive = new ArrayList<Range>();
-        private ArrayList<Range> mHighlightInclusive = new ArrayList<Range>();
-        private int mMinStripHeight = 2;
-        private double mCachedMinVal;
-        private double mCachedMaxVal;
-        private int mCachedStartRow;
-        private int mCachedEndRow;
-        private double mScalePixelsPerRange;
-        private double mScaleMinVal;
-        private double mScaleMaxVal;
-        private double mLimitMinVal;
-        private double mLimitMaxVal;
-        private double mMinDataVal;
-        private double mMaxDataVal;
-        private Cursor mNormalCursor;
-        private Cursor mIncreasingCursor;
-        private Cursor mDecreasingCursor;
-        private static final int ZOOM_TIMER_INTERVAL = 10;
-        private static final int HIGHLIGHT_TIMER_INTERVAL = 50;
-        private static final int ZOOM_STEPS = 8; // must be even
-        private int highlightHeight = 4;
-        private final int[] highlightHeights = { 0, 2, 4, 5, 6, 5, 4, 2, 4, 5,
-                6 };
-        private final int HIGHLIGHT_STEPS = highlightHeights.length;
-        private boolean mFadeColors;
-        private boolean mShowHighlightName;
-        private double[] mZoomFractions;
-        private int mZoomStep;
-        private int mZoomMouseStart;
-        private int mZoomMouseEnd;
-        private int mMouseStartDistance;
-        private int mMouseEndDistance;
-        private Point mMouseSelect = new Point(0, 0);
-        private double mZoomFixed;
-        private double mZoomFixedPixel;
-        private double mFixedPixelStartDistance;
-        private double mFixedPixelEndDistance;
-        private double mZoomMin2Fixed;
-        private double mMin2ZoomMin;
-        private double mFixed2ZoomMax;
-        private double mZoomMax2Max;
-        private double mZoomMin;
-        private double mZoomMax;
-        private Runnable mZoomAnimator;
-        private Runnable mHighlightAnimator;
-        private int mHighlightStep;
-    }
-
-    private int computeVisibleRows(int ydim) {
-        // If we resize, then move the bottom row down.  Don't allow the scroll
-        // to waste space at the bottom.
-        int offsetY = mScrollOffsetY;
-        int spaceNeeded = mNumRows * rowYSpace;
-        if (offsetY + ydim > spaceNeeded) {
-            offsetY = spaceNeeded - ydim;
-            if (offsetY < 0) {
-                offsetY = 0;
-            }
-        }
-        mStartRow = offsetY / rowYSpace;
-        mEndRow = (offsetY + ydim) / rowYSpace;
-        if (mEndRow >= mNumRows) {
-            mEndRow = mNumRows - 1;
-        }
-        
-        return offsetY;
-    }
-
-    private void startHighlighting() {
-        // System.out.printf("startHighlighting()\n");
-        mSurface.mHighlightStep = 0;
-        mSurface.mFadeColors = true;
-        // Force a recomputation of the color strips
-        mSurface.mCachedEndRow = -1;
-        getDisplay().timerExec(0, mSurface.mHighlightAnimator);
-    }
-
-    private static class RowData {
-        RowData(Row row) {
-            mName = row.getName();
-            mStack = new ArrayList<Block>();
-        }
-
-        public void push(Block block) {
-            mStack.add(block);
-        }
-
-        public Block top() {
-            if (mStack.size() == 0)
-                return null;
-            return mStack.get(mStack.size() - 1);
-        }
-
-        public void pop() {
-            if (mStack.size() == 0)
-                return;
-            mStack.remove(mStack.size() - 1);
-        }
-
-        private String mName;
-        private int mRank;
-        private long mElapsed;
-        private long mEndTime;
-        private ArrayList<Block> mStack;
-    }
-
-    private static class Segment {
-        Segment(RowData rowData, Block block, long startTime, long endTime) {
-            mRowData = rowData;
-            mBlock = block;
-            mStartTime = startTime;
-            mEndTime = endTime;
-        }
-
-        private RowData mRowData;
-        private Block mBlock;
-        private long mStartTime;
-        private long mEndTime;
-    }
-
-    private static class Strip {
-        Strip(int x, int y, int width, int height, RowData rowData,
-                Segment segment, Color color) {
-            mX = x;
-            mY = y;
-            mWidth = width;
-            mHeight = height;
-            mRowData = rowData;
-            mSegment = segment;
-            mColor = color;
-        }
-
-        int mX;
-        int mY;
-        int mWidth;
-        int mHeight;
-        RowData mRowData;
-        Segment mSegment;
-        Color mColor;
-    }
-
-    private static class Pixel {
-        public void setFields(int start, double weight, Segment segment,
-                Color color, RowData rowData) {
-            mStart = start;
-            mMaxWeight = weight;
-            mSegment = segment;
-            mColor = color;
-            mRowData = rowData;
-        }
-
-        int mStart = -2; // some value that won't match another pixel
-        double mMaxWeight;
-        Segment mSegment;
-        Color mColor; // we need the color here because it may be faded
-        RowData mRowData;
-    }
-
-    private static class Range {
-        Range(int xStart, int width, int y, Color color) {
-            mXdim.x = xStart;
-            mXdim.y = width;
-            mY = y;
-            mColor = color;
-        }
-
-        Point mXdim = new Point(0, 0);
-        int mY;
-        Color mColor;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/TraceReader.java b/tools/traceview/src/com/android/traceview/TraceReader.java
deleted file mode 100644
index ae75876..0000000
--- a/tools/traceview/src/com/android/traceview/TraceReader.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-
-public abstract class TraceReader {
-
-    private TraceUnits mTraceUnits;
-
-    public TraceUnits getTraceUnits() {
-        if (mTraceUnits == null)
-            mTraceUnits = new TraceUnits();
-        return mTraceUnits;
-    }
-
-    public ArrayList<TimeLineView.Record> getThreadTimeRecords() {
-        return null;
-    }
-
-    public HashMap<Integer, String> getThreadLabels() {
-        return null;
-    }
-
-    public MethodData[] getMethods() {
-        return null;
-    }
-
-    public ThreadData[] getThreads() {
-        return null;
-    }
-
-    public long getEndTime() {
-        return 0;
-    }
-
-    public ProfileProvider getProfileProvider() {
-        return null;
-    }
-}
diff --git a/tools/traceview/src/com/android/traceview/TraceUnits.java b/tools/traceview/src/com/android/traceview/TraceUnits.java
deleted file mode 100644
index 20938f5..0000000
--- a/tools/traceview/src/com/android/traceview/TraceUnits.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Copyright (C) 2006 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.traceview;
-
-import java.text.DecimalFormat;
-
-// This should be a singleton.
-public class TraceUnits {
-
-    private TimeScale mTimeScale = TimeScale.MicroSeconds;
-    private double mScale = 1.0;
-    DecimalFormat mFormatter = new DecimalFormat();
-
-    public double getScaledValue(long value) {
-        return value * mScale;
-    }
-
-    public double getScaledValue(double value) {
-        return value * mScale;
-    }
-
-    public String valueOf(long value) {
-        return valueOf((double) value);
-    }
-
-    public String valueOf(double value) {
-        String pattern;
-        double scaled = value * mScale;
-        if ((int) scaled == scaled)
-            pattern = "###,###";
-        else
-            pattern = "###,###.###";
-        mFormatter.applyPattern(pattern);
-        return mFormatter.format(scaled);
-    }
-
-    public String labelledString(double value) {
-        String units = label();
-        String num = valueOf(value);
-        return String.format("%s: %s", units, num);
-    }
-
-    public String labelledString(long value) {
-        return labelledString((double) value);
-    }
-
-    public String label() {
-        if (mScale == 1.0)
-            return "usec";
-        if (mScale == 0.001)
-            return "msec";
-        if (mScale == 0.000001)
-            return "sec";
-        return null;
-    }
-
-    public void setTimeScale(TimeScale val) {
-        mTimeScale = val;
-        switch (val) {
-        case Seconds:
-            mScale = 0.000001;
-            break;
-        case MilliSeconds:
-            mScale = 0.001;
-            break;
-        case MicroSeconds:
-            mScale = 1.0;
-            break;
-        }
-    }
-
-    public TimeScale getTimeScale() {
-        return mTimeScale;
-    }
-
-    public enum TimeScale {
-        Seconds, MilliSeconds, MicroSeconds
-    };
-}
diff --git a/tools/traceview/src/resources/icons/sort_down.png b/tools/traceview/src/resources/icons/sort_down.png
deleted file mode 100644
index de6a2a0..0000000
--- a/tools/traceview/src/resources/icons/sort_down.png
+++ /dev/null
Binary files differ
diff --git a/tools/traceview/src/resources/icons/sort_up.png b/tools/traceview/src/resources/icons/sort_up.png
deleted file mode 100644
index 8578a87..0000000
--- a/tools/traceview/src/resources/icons/sort_up.png
+++ /dev/null
Binary files differ
diff --git a/tools/zoneinfo/ZoneCompactor.java b/tools/zoneinfo/ZoneCompactor.java
deleted file mode 100644
index eea7dd4..0000000
--- a/tools/zoneinfo/ZoneCompactor.java
+++ /dev/null
@@ -1,158 +0,0 @@
-
-import java.io.*;
-import java.util.*;
-
-// usage: java ZoneCompiler <setup file> <top-level directory>
-//
-// Compile a set of tzfile-formatted files into a single file plus
-// an index file.
-//
-// The compilation is controlled by a setup file, which is provided as a
-// command-line argument.  The setup file has the form:
-//
-// Link <toName> <fromName>
-// ...
-// <zone filename>
-// ...
-//
-// Note that the links must be declared prior to the zone names.  A
-// zone name is a filename relative to the source directory such as
-// 'GMT', 'Africa/Dakar', or 'America/Argentina/Jujuy'.
-//
-// Use the 'zic' command-line tool to convert from flat files
-// (e.g., 'africa', 'northamerica') into a suitable source directory
-// hierarchy for this tool (e.g., 'data/Africa/Abidjan').
-//
-// Example:
-//     zic -d data tz2007h
-//     javac ZoneCompactor.java
-//     java ZoneCompactor setup data
-//     <produces zoneinfo.dat and zoneinfo.idx>
-
-public class ZoneCompactor {
-
-    // Zone name synonyms
-    Map<String,String> links = new HashMap<String,String>();
-
-    // File starting bytes by zone name
-    Map<String,Integer> starts = new HashMap<String,Integer>();
-
-    // File lengths by zone name
-    Map<String,Integer> lengths = new HashMap<String,Integer>();
-
-    // Raw GMT offsets by zone name
-    Map<String,Integer> offsets = new HashMap<String,Integer>();
-    int start = 0;
-
-    // Maximum number of characters in a zone name, including '\0' terminator
-    private static final int MAXNAME = 40;
-
-    // Concatenate the contents of 'inFile' onto 'out'
-    private static void copyFile(File inFile, OutputStream out)
-        throws Exception {
-        InputStream in = new FileInputStream(inFile);
-        byte[] buf = new byte[8192];
-        while (true) {
-            int nbytes = in.read(buf);
-            if (nbytes == -1) {
-                break;
-            }
-            out.write(buf, 0, nbytes);
-        }
-        out.flush();
-        return;
-    }
-    
-    // Write a 32-bit integer in network byte order
-    private void writeInt(OutputStream os, int x) throws IOException {
-        os.write((x >> 24) & 0xff);
-        os.write((x >> 16) & 0xff);
-        os.write((x >>  8) & 0xff);
-        os.write( x        & 0xff);
-    }
-
-    public ZoneCompactor(String setupFilename, String dirName)
-        throws Exception {
-        File zoneInfoFile = new File("zoneinfo.dat");
-        zoneInfoFile.delete();
-        OutputStream zoneInfo = new FileOutputStream(zoneInfoFile);
-
-        BufferedReader rdr = new BufferedReader(new FileReader(setupFilename));
-    
-        String s;
-        while ((s = rdr.readLine()) != null) {
-            s = s.trim();
-            if (s.startsWith("Link")) {
-                StringTokenizer st = new StringTokenizer(s);
-                st.nextToken();
-                String to = st.nextToken();
-                String from = st.nextToken();
-                links.put(from, to);
-            } else {
-                String link = links.get(s);
-                if (link == null) {
-                    File f = new File(dirName, s);
-                    long length = f.length();
-                    starts.put(s, new Integer(start));
-                    lengths.put(s, new Integer((int)length));
-
-                    TimeZone tz = TimeZone.getTimeZone(s);
-                    int gmtOffset = tz.getRawOffset();
-                    offsets.put(s, new Integer(gmtOffset));
-
-                    start += length;
-                    copyFile(f, zoneInfo);
-                }
-            }
-        }
-        zoneInfo.close();
-
-        // Fill in fields for links
-        Iterator<String> iter = links.keySet().iterator();
-        while (iter.hasNext()) {
-            String from = iter.next();
-            String to = links.get(from);
-
-            starts.put(from, starts.get(to));
-            lengths.put(from, lengths.get(to));
-            offsets.put(from, offsets.get(to));
-        }
-
-        File idxFile = new File("zoneinfo.idx");
-        idxFile.delete();
-        FileOutputStream idx = new FileOutputStream(idxFile);
-
-        ArrayList l = new ArrayList();
-        l.addAll(starts.keySet());
-        Collections.sort(l);
-        Iterator<String> ziter = l.iterator();
-        while (ziter.hasNext()) {
-            String zname = ziter.next();
-            if (zname.length() >= MAXNAME) {
-                System.err.println("Error - zone filename exceeds " +
-                                   (MAXNAME - 1) + " characters!");
-            }
-
-            byte[] znameBuf = new byte[MAXNAME];
-            for (int i = 0; i < zname.length(); i++) {
-                znameBuf[i] = (byte)zname.charAt(i);
-            }
-            idx.write(znameBuf);
-            writeInt(idx, starts.get(zname).intValue());
-            writeInt(idx, lengths.get(zname).intValue());
-            writeInt(idx, offsets.get(zname).intValue());
-        }
-        idx.close();
-
-        // System.out.println("maxLength = " + maxLength);
-    }
-
-    public static void main(String[] args) throws Exception {
-        if (args.length != 2) {
-            System.err.println("usage: java ZoneCompactor <setup> <data dir>");
-            System.exit(0);
-        }
-        new ZoneCompactor(args[0], args[1]);
-    }
-
-}
diff --git a/tools/zoneinfo/generate b/tools/zoneinfo/generate
deleted file mode 100755
index 0b087a8..0000000
--- a/tools/zoneinfo/generate
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/bin/sh
-
-version=tzdata2008h
-
-mkdir data
-
-for i in $version/africa \
-    $version/antarctica \
-    $version/asia \
-    $version/australasia \
-    $version/etcetera \
-    $version/europe \
-    $version/factory \
-    $version/northamerica \
-    $version/solar87 \
-    $version/solar88 \
-    $version/solar89 \
-    $version/southamerica
-do
-    zic -d data $i
-done
-
-javac -target 1.5 ZoneCompactor.java
-
-(
-    cat $version/* | grep '^Link' | awk '{print $1, $2, $3}'
-    (
-        cat $version/* | grep '^Zone' | awk '{print $2}'
-        cat $version/* | grep '^Link' | awk '{print $3}'
-    ) | LC_ALL="C" sort
-) | grep -v Riyadh8 > setup
-
-java ZoneCompactor setup data
-
-cp zoneinfo.dat zoneinfo.idx ../../../data/zoneinfo
diff --git a/tools/zoneinfo/tzdata2008h/MODULE_LICENSE_PUBLIC_DOMAIN b/tools/zoneinfo/tzdata2008h/MODULE_LICENSE_PUBLIC_DOMAIN
deleted file mode 100644
index e69de29..0000000
--- a/tools/zoneinfo/tzdata2008h/MODULE_LICENSE_PUBLIC_DOMAIN
+++ /dev/null
diff --git a/tools/zoneinfo/tzdata2008h/africa b/tools/zoneinfo/tzdata2008h/africa
deleted file mode 100644
index 34a62b9..0000000
--- a/tools/zoneinfo/tzdata2008h/africa
+++ /dev/null
@@ -1,840 +0,0 @@
-# @(#)africa	8.17
-# <pre>
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (2006-03-22):
-#
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1990, and IATA SSIM is the source for entries afterwards.
-#
-# Another source occasionally used is Edward W. Whitman, World Time Differences,
-# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which
-# I found in the UCLA library.
-#
-# A reliable and entertaining source about time zones is
-# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997).
-#
-# Previous editions of this database used WAT, CAT, SAT, and EAT
-# for +0:00 through +3:00, respectively,
-# but Mark R V Murray reports that
-# `SAST' is the official abbreviation for +2:00 in the country of South Africa,
-# `CAT' is commonly used for +2:00 in countries north of South Africa, and
-# `WAT' is probably the best name for +1:00, as the common phrase for
-# the area that includes Nigeria is ``West Africa''.
-# He has heard of ``Western Sahara Time'' for +0:00 but can find no reference.
-#
-# To make things confusing, `WAT' seems to have been used for -1:00 long ago;
-# I'd guess that this was because people needed _some_ name for -1:00,
-# and at the time, far west Africa was the only major land area in -1:00.
-# This usage is now obsolete, as the last use of -1:00 on the African
-# mainland seems to have been 1976 in Western Sahara.
-#
-# To summarize, the following abbreviations seem to have some currency:
-#	-1:00	WAT	West Africa Time (no longer used)
-#	 0:00	GMT	Greenwich Mean Time
-#	 2:00	CAT	Central Africa Time
-#	 2:00	SAST	South Africa Standard Time
-# and Murray suggests the following abbreviation:
-#	 1:00	WAT	West Africa Time
-# I realize that this leads to `WAT' being used for both -1:00 and 1:00
-# for times before 1976, but this is the best I can think of
-# until we get more information.
-#
-# I invented the following abbreviations; corrections are welcome!
-#	 2:00	WAST	West Africa Summer Time
-#	 2:30	BEAT	British East Africa Time (no longer used)
-#	 2:44:45 BEAUT	British East Africa Unified Time (no longer used)
-#	 3:00	CAST	Central Africa Summer Time (no longer used)
-#	 3:00	SAST	South Africa Summer Time (no longer used)
-#	 3:00	EAT	East Africa Time
-#	 4:00	EAST	East Africa Summer Time (no longer used)
-
-# Algeria
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Algeria	1916	only	-	Jun	14	23:00s	1:00	S
-Rule	Algeria	1916	1919	-	Oct	Sun>=1	23:00s	0	-
-Rule	Algeria	1917	only	-	Mar	24	23:00s	1:00	S
-Rule	Algeria	1918	only	-	Mar	 9	23:00s	1:00	S
-Rule	Algeria	1919	only	-	Mar	 1	23:00s	1:00	S
-Rule	Algeria	1920	only	-	Feb	14	23:00s	1:00	S
-Rule	Algeria	1920	only	-	Oct	23	23:00s	0	-
-Rule	Algeria	1921	only	-	Mar	14	23:00s	1:00	S
-Rule	Algeria	1921	only	-	Jun	21	23:00s	0	-
-Rule	Algeria	1939	only	-	Sep	11	23:00s	1:00	S
-Rule	Algeria	1939	only	-	Nov	19	 1:00	0	-
-Rule	Algeria	1944	1945	-	Apr	Mon>=1	 2:00	1:00	S
-Rule	Algeria	1944	only	-	Oct	 8	 2:00	0	-
-Rule	Algeria	1945	only	-	Sep	16	 1:00	0	-
-Rule	Algeria	1971	only	-	Apr	25	23:00s	1:00	S
-Rule	Algeria	1971	only	-	Sep	26	23:00s	0	-
-Rule	Algeria	1977	only	-	May	 6	 0:00	1:00	S
-Rule	Algeria	1977	only	-	Oct	21	 0:00	0	-
-Rule	Algeria	1978	only	-	Mar	24	 1:00	1:00	S
-Rule	Algeria	1978	only	-	Sep	22	 3:00	0	-
-Rule	Algeria	1980	only	-	Apr	25	 0:00	1:00	S
-Rule	Algeria	1980	only	-	Oct	31	 2:00	0	-
-# Shanks & Pottenger give 0:09:20 for Paris Mean Time; go with Howse's
-# more precise 0:09:21.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Algiers	0:12:12 -	LMT	1891 Mar 15 0:01
-			0:09:21	-	PMT	1911 Mar 11    # Paris Mean Time
-			0:00	Algeria	WE%sT	1940 Feb 25 2:00
-			1:00	Algeria	CE%sT	1946 Oct  7
-			0:00	-	WET	1956 Jan 29
-			1:00	-	CET	1963 Apr 14
-			0:00	Algeria	WE%sT	1977 Oct 21
-			1:00	Algeria	CE%sT	1979 Oct 26
-			0:00	Algeria	WE%sT	1981 May
-			1:00	-	CET
-
-# Angola
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Luanda	0:52:56	-	LMT	1892
-			0:52:04	-	AOT	1911 May 26 # Angola Time
-			1:00	-	WAT
-
-# Benin
-# Whitman says they switched to 1:00 in 1946, not 1934;
-# go with Shanks & Pottenger.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Porto-Novo	0:10:28	-	LMT	1912
-			0:00	-	GMT	1934 Feb 26
-			1:00	-	WAT
-
-# Botswana
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Gaborone	1:43:40 -	LMT	1885
-			2:00	-	CAT	1943 Sep 19 2:00
-			2:00	1:00	CAST	1944 Mar 19 2:00
-			2:00	-	CAT
-
-# Burkina Faso
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Ouagadougou	-0:06:04 -	LMT	1912
-			 0:00	-	GMT
-
-# Burundi
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Bujumbura	1:57:28	-	LMT	1890
-			2:00	-	CAT
-
-# Cameroon
-# Whitman says they switched to 1:00 in 1920; go with Shanks & Pottenger.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Douala	0:38:48	-	LMT	1912
-			1:00	-	WAT
-
-# Cape Verde
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/Cape_Verde -1:34:04 -	LMT	1907			# Praia
-			-2:00	-	CVT	1942 Sep
-			-2:00	1:00	CVST	1945 Oct 15
-			-2:00	-	CVT	1975 Nov 25 2:00
-			-1:00	-	CVT
-
-# Central African Republic
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Bangui	1:14:20	-	LMT	1912
-			1:00	-	WAT
-
-# Chad
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Ndjamena	1:00:12 -	LMT	1912
-			1:00	-	WAT	1979 Oct 14
-			1:00	1:00	WAST	1980 Mar  8
-			1:00	-	WAT
-
-# Comoros
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Comoro	2:53:04 -	LMT	1911 Jul   # Moroni, Gran Comoro
-			3:00	-	EAT
-
-# Democratic Republic of Congo
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Kinshasa	1:01:12 -	LMT	1897 Nov 9
-			1:00	-	WAT
-Zone Africa/Lubumbashi	1:49:52 -	LMT	1897 Nov 9
-			2:00	-	CAT
-
-# Republic of the Congo
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Brazzaville	1:01:08 -	LMT	1912
-			1:00	-	WAT
-
-# Cote D'Ivoire
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Abidjan	-0:16:08 -	LMT	1912
-			 0:00	-	GMT
-
-# Djibouti
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Djibouti	2:52:36 -	LMT	1911 Jul
-			3:00	-	EAT
-
-###############################################################################
-
-# Egypt
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Egypt	1940	only	-	Jul	15	0:00	1:00	S
-Rule	Egypt	1940	only	-	Oct	 1	0:00	0	-
-Rule	Egypt	1941	only	-	Apr	15	0:00	1:00	S
-Rule	Egypt	1941	only	-	Sep	16	0:00	0	-
-Rule	Egypt	1942	1944	-	Apr	 1	0:00	1:00	S
-Rule	Egypt	1942	only	-	Oct	27	0:00	0	-
-Rule	Egypt	1943	1945	-	Nov	 1	0:00	0	-
-Rule	Egypt	1945	only	-	Apr	16	0:00	1:00	S
-Rule	Egypt	1957	only	-	May	10	0:00	1:00	S
-Rule	Egypt	1957	1958	-	Oct	 1	0:00	0	-
-Rule	Egypt	1958	only	-	May	 1	0:00	1:00	S
-Rule	Egypt	1959	1981	-	May	 1	1:00	1:00	S
-Rule	Egypt	1959	1965	-	Sep	30	3:00	0	-
-Rule	Egypt	1966	1994	-	Oct	 1	3:00	0	-
-Rule	Egypt	1982	only	-	Jul	25	1:00	1:00	S
-Rule	Egypt	1983	only	-	Jul	12	1:00	1:00	S
-Rule	Egypt	1984	1988	-	May	 1	1:00	1:00	S
-Rule	Egypt	1989	only	-	May	 6	1:00	1:00	S
-Rule	Egypt	1990	1994	-	May	 1	1:00	1:00	S
-# IATA (after 1990) says transitions are at 0:00.
-# Go with IATA starting in 1995, except correct 1995 entry from 09-30 to 09-29.
-Rule	Egypt	1995	max	-	Apr	lastFri	 0:00s	1:00	S
-Rule	Egypt	1995	2005	-	Sep	lastThu	23:00s	0	-
-# From Steffen Thorsen (2006-09-19):
-# The Egyptian Gazette, issue 41,090 (2006-09-18), page 1, reports:
-# Egypt will turn back clocks by one hour at the midnight of Thursday
-# after observing the daylight saving time since May.
-# http://news.gom.com.eg/gazette/pdf/2006/09/18/01.pdf
-Rule	Egypt	2006	only	-	Sep	21	23:00s	0	-
-# From Dirk Losch (2007-08-14):
-# I received a mail from an airline which says that the daylight
-# saving time in Egypt will end in the night of 2007-09-06 to 2007-09-07.
-# From Jesper Norgaard Welen (2007-08-15): [The following agree:]
-# http://www.nentjes.info/Bill/bill5.htm 
-# http://www.timeanddate.com/worldclock/city.html?n=53
-# From Steffen Thorsen (2007-09-04): The official information...:
-# http://www.sis.gov.eg/En/EgyptOnline/Miscellaneous/000002/0207000000000000001580.htm
-Rule	Egypt	2007	only	-	Sep	Thu>=1	23:00s	0	-
-# From Abdelrahman Hassan (2007-09-06):
-# Due to the Hijri (lunar Islamic calendar) year being 11 days shorter
-# than the year of the Gregorian calendar, Ramadan shifts earlier each
-# year. This year it will be observed September 13 (September is quite
-# hot in Egypt), and the idea is to make fasting easier for workers by
-# shifting business hours one hour out of daytime heat. Consequently,
-# unless discontinued, next DST may end Thursday 28 August 2008.
-# From Paul Eggert (2007-08-17):
-# For lack of better info, assume the new rule is last Thursday in August.
-Rule	Egypt	2008	max	-	Aug	lastThu	23:00s	0	-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Cairo	2:05:00 -	LMT	1900 Oct
-			2:00	Egypt	EE%sT
-
-# Equatorial Guinea
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Malabo	0:35:08 -	LMT	1912
-			0:00	-	GMT	1963 Dec 15
-			1:00	-	WAT
-
-# Eritrea
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Asmara	2:35:32 -	LMT	1870
-			2:35:32	-	AMT	1890	      # Asmara Mean Time
-			2:35:20	-	ADMT	1936 May 5    # Adis Dera MT
-			3:00	-	EAT
-
-# Ethiopia
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that Ethiopia had six narrowly-spaced time zones
-# between 1870 and 1890, and that they merged to 38E50 (2:35:20) in 1890.
-# We'll guess that 38E50 is for Adis Dera.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Addis_Ababa	2:34:48 -	LMT	1870
-			2:35:20	-	ADMT	1936 May 5    # Adis Dera MT
-			3:00	-	EAT
-
-# Gabon
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Libreville	0:37:48 -	LMT	1912
-			1:00	-	WAT
-
-# Gambia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Banjul	-1:06:36 -	LMT	1912
-			-1:06:36 -	BMT	1935	# Banjul Mean Time
-			-1:00	-	WAT	1964
-			 0:00	-	GMT
-
-# Ghana
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Whitman says DST was observed from 1931 to ``the present'';
-# go with Shanks & Pottenger.
-Rule	Ghana	1936	1942	-	Sep	 1	0:00	0:20	GHST
-Rule	Ghana	1936	1942	-	Dec	31	0:00	0	GMT
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Accra	-0:00:52 -	LMT	1918
-			 0:00	Ghana	%s
-
-# Guinea
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Conakry	-0:54:52 -	LMT	1912
-			 0:00	-	GMT	1934 Feb 26
-			-1:00	-	WAT	1960
-			 0:00	-	GMT
-
-# Guinea-Bissau
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Bissau	-1:02:20 -	LMT	1911 May 26
-			-1:00	-	WAT	1975
-			 0:00	-	GMT
-
-# Kenya
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Nairobi	2:27:16	-	LMT	1928 Jul
-			3:00	-	EAT	1930
-			2:30	-	BEAT	1940
-			2:44:45	-	BEAUT	1960
-			3:00	-	EAT
-
-# Lesotho
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Maseru	1:50:00 -	LMT	1903 Mar
-			2:00	-	SAST	1943 Sep 19 2:00
-			2:00	1:00	SAST	1944 Mar 19 2:00
-			2:00	-	SAST
-
-# Liberia
-# From Paul Eggert (2006-03-22):
-# In 1972 Liberia was the last country to switch
-# from a UTC offset that was not a multiple of 15 or 20 minutes.
-# Howse reports that it was in honor of their president's birthday.
-# Shank & Pottenger report the date as May 1, whereas Howse reports Jan;
-# go with Shanks & Pottenger.
-# For Liberia before 1972, Shanks & Pottenger report -0:44, whereas Howse and
-# Whitman each report -0:44:30; go with the more precise figure.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Monrovia	-0:43:08 -	LMT	1882
-			-0:43:08 -	MMT	1919 Mar # Monrovia Mean Time
-			-0:44:30 -	LRT	1972 May # Liberia Time
-			 0:00	-	GMT
-
-###############################################################################
-
-# Libya
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Libya	1951	only	-	Oct	14	2:00	1:00	S
-Rule	Libya	1952	only	-	Jan	 1	0:00	0	-
-Rule	Libya	1953	only	-	Oct	 9	2:00	1:00	S
-Rule	Libya	1954	only	-	Jan	 1	0:00	0	-
-Rule	Libya	1955	only	-	Sep	30	0:00	1:00	S
-Rule	Libya	1956	only	-	Jan	 1	0:00	0	-
-Rule	Libya	1982	1984	-	Apr	 1	0:00	1:00	S
-Rule	Libya	1982	1985	-	Oct	 1	0:00	0	-
-Rule	Libya	1985	only	-	Apr	 6	0:00	1:00	S
-Rule	Libya	1986	only	-	Apr	 4	0:00	1:00	S
-Rule	Libya	1986	only	-	Oct	 3	0:00	0	-
-Rule	Libya	1987	1989	-	Apr	 1	0:00	1:00	S
-Rule	Libya	1987	1989	-	Oct	 1	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Tripoli	0:52:44 -	LMT	1920
-			1:00	Libya	CE%sT	1959
-			2:00	-	EET	1982
-			1:00	Libya	CE%sT	1990 May  4
-# The following entries are from Shanks & Pottenger;
-# the IATA SSIM data contain some obvious errors.
-			2:00	-	EET	1996 Sep 30
-			1:00	-	CET	1997 Apr  4
-			1:00	1:00	CEST	1997 Oct  4
-			2:00	-	EET
-
-# Madagascar
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Indian/Antananarivo 3:10:04 -	LMT	1911 Jul
-			3:00	-	EAT	1954 Feb 27 23:00s
-			3:00	1:00	EAST	1954 May 29 23:00s
-			3:00	-	EAT
-
-# Malawi
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Blantyre	2:20:00 -	LMT	1903 Mar
-			2:00	-	CAT
-
-# Mali
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Bamako	-0:32:00 -	LMT	1912
-			 0:00	-	GMT	1934 Feb 26
-			-1:00	-	WAT	1960 Jun 20
-			 0:00	-	GMT
-
-# Mauritania
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Nouakchott	-1:03:48 -	LMT	1912
-			 0:00	-	GMT	1934 Feb 26
-			-1:00	-	WAT	1960 Nov 28
-			 0:00	-	GMT
-
-# Mauritius
-
-# From Steffen Thorsen (2008-06-25):
-# Mauritius plans to observe DST from 2008-11-01 to 2009-03-31 on a trial
-# basis....
-# It seems that Mauritius observed daylight saving time from 1982-10-10 to 
-# 1983-03-20 as well, but that was not successful....
-# http://www.timeanddate.com/news/time/mauritius-daylight-saving-time.html
-
-# From Alex Krivenyshev (2008-06-25):
-# http://economicdevelopment.gov.mu/portal/site/Mainhomepage/menuitem.a42b24128104d9845dabddd154508a0c/?content_id=0a7cee8b5d69a110VgnVCM1000000a04a8c0RCRD
-
-# From Arthur David Olson (2008-06-30):
-# The www.timeanddate.com article cited by Steffen Thorsen notes that "A
-# final decision has yet to be made on the times that daylight saving
-# would begin and end on these dates." As a place holder, use midnight.
-
-# From Paul Eggert (2008-06-30):
-# Follow Thorsen on DST in 1982/1983, instead of Shanks & Pottenger.
-
-# From Steffen Thorsen (2008-07-10):
-# According to
-# <a href="http://www.lexpress.mu/display_article.php?news_id=111216">
-# http://www.lexpress.mu/display_article.php?news_id=111216
-# </a>
-# (in French), Mauritius will start and end their DST a few days earlier
-# than previously announced (2008-11-01 to 2009-03-31).  The new start
-# date is 2008-10-26 at 02:00 and the new end date is 2009-03-27 (no time
-# given, but it is probably at either 2 or 3 wall clock time).
-# 
-# A little strange though, since the article says that they moved the date 
-# to align itself with Europe and USA which also change time on that date, 
-# but that means they have not paid attention to what happened in 
-# USA/Canada last year (DST ends first Sunday in November). I also wonder 
-# why that they end on a Friday, instead of aligning with Europe which 
-# changes two days later.
-
-# From Alex Krivenyshev (2008-07-11):
-# Seems that English language article "The revival of daylight saving
-# time:  Energy conservation?"-# No. 16578 (07/11/2008) was originally
-# published on Monday, June 30, 2008...
-#
-# I guess that article in French "Le gouvernement avance l'introduction
-# de l'heure d'ete" stating that DST in Mauritius starting on October 26
-# and ending on March 27, 2009 is the most recent one.
-# ...
-# <a href="http://www.worldtimezone.com/dst_news/dst_news_mauritius02.html">
-# http://www.worldtimezone.com/dst_news/dst_news_mauritius02.html
-# </a>
-
-# From Riad M. Hossen Ally (2008-08-03):
-# The Government of Mauritius weblink
-# <a href="http://www.gov.mu/portal/site/pmosite/menuitem.4ca0efdee47462e7440a600248a521ca/?content_id=3D4728ca68b2a5b110VgnVCM1000000a04a8c0RCRD">
-# http://www.gov.mu/portal/site/pmosite/menuitem.4ca0efdee47462e7440a600248a521ca/?content_id=3D4728ca68b2a5b110VgnVCM1000000a04a8c0RCRD
-# </a>
-# Cabinet Decision of July 18th, 2008 states as follows:
-#
-# 4. ...Cabinet has agreed to the introduction into the National Assembly
-# of the Time Bill which provides for the introduction of summer time in
-# Mauritius. The summer time period which will be of one hour ahead of
-# the standard time, will be aligned with that in Europe and the United
-# States of America. It will start at two o'clock in the morning on the
-# last Sunday of October and will end at two o'clock in the morning on
-# the last Sunday of March the following year. The summer time for the
-# year 2008 - 2009 will, therefore, be effective as from 26 October 2008
-# and end on 29 March 2009.
-
-# From Ed Maste (2008-10-07):
-# THE TIME BILL (No. XXVII of 2008) Explanatory Memorandum states the
-# beginning / ending of summer time is 2 o'clock standard time in the
-# morning of the last Sunday of October / last Sunday of March.
-# <a href="http://www.gov.mu/portal/goc/assemblysite/file/bill2708.pdf">
-# http://www.gov.mu/portal/goc/assemblysite/file/bill2708.pdf
-# </a>
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule Mauritius	1982	only	-	Oct	10	0:00	1:00	S
-Rule Mauritius	1983	only	-	Mar	21	0:00	0	-
-Rule Mauritius	2008	max	-	Oct	lastSun	2:00s	1:00	S
-Rule Mauritius	2009	max	-	Mar	lastSun	2:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Indian/Mauritius	3:50:00 -	LMT	1907		# Port Louis
-			4:00 Mauritius	MU%sT	# Mauritius Time
-# Agalega Is, Rodriguez
-# no information; probably like Indian/Mauritius
-
-# Mayotte
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Mayotte	3:00:56 -	LMT	1911 Jul	# Mamoutzou
-			3:00	-	EAT
-
-# Morocco
-# See the `europe' file for Spanish Morocco (Africa/Ceuta).
-
-# From Alex Krivenyshev (2008-05-09):
-# Here is an article that Morocco plan to introduce Daylight Saving Time between
-# 1 June, 2008 and 27 September, 2008.
-#
-# "... Morocco is to save energy by adjusting its clock during summer so it will
-# be one hour ahead of GMT between 1 June and 27 September, according to
-# Communication Minister and Gov ernment Spokesman, Khalid Naciri...."
-#
-# <a href="http://www.worldtimezone.net/dst_news/dst_news_morocco01.html">
-# http://www.worldtimezone.net/dst_news/dst_news_morocco01.html
-# </a>
-# OR
-# <a href="http://en.afrik.com/news11892.html">
-# http://en.afrik.com/news11892.html
-# </a>
-
-# From Alex Krivenyshev (2008-05-09):
-# The Morocco time change can be confirmed on Morocco web site Maghreb Arabe Presse:
-# <a href="http://www.map.ma/eng/sections/box3/morocco_shifts_to_da/view">
-# http://www.map.ma/eng/sections/box3/morocco_shifts_to_da/view
-# </a>
-#
-# Morocco shifts to daylight time on June 1st through September 27, Govt.
-# spokesman.
-
-# From Patrice Scattolin (2008-05-09):
-# According to this article:
-# <a href="http://www.avmaroc.com/actualite/heure-dete-comment-a127896.html">
-# http://www.avmaroc.com/actualite/heure-dete-comment-a127896.html
-# </a>
-# (and republished here:
-# <a href="http://www.actu.ma/heure-dete-comment_i127896_0.html">
-# http://www.actu.ma/heure-dete-comment_i127896_0.html
-# </a>
-# )
-# the changes occurs at midnight:
-#
-# saturday night may 31st at midnight (which in french is to be
-# intrepreted as the night between saturday and sunday)
-# sunday night the 28th  at midnight
-#
-# Seeing that the 28th is monday, I am guessing that she intends to say
-# the midnight of the 28th which is the midnight between sunday and
-# monday, which jives with other sources that say that it's inclusive
-# june1st to sept 27th.
-#
-# The decision was taken by decree *2-08-224 *but I can't find the decree
-# published on the web.
-#
-# It's also confirmed here:
-# <a href="http://www.maroc.ma/NR/exeres/FACF141F-D910-44B0-B7FA-6E03733425D1.htm">
-# http://www.maroc.ma/NR/exeres/FACF141F-D910-44B0-B7FA-6E03733425D1.htm
-# </a>
-# on a government portal as being  between june 1st and sept 27th (not yet
-# posted in english).
-#
-# The following google query will generate many relevant hits:
-# <a href="http://www.google.com/search?hl=en&q=Conseil+de+gouvernement+maroc+heure+avance&btnG=Search">
-# http://www.google.com/search?hl=en&q=Conseil+de+gouvernement+maroc+heure+avance&btnG=Search
-# </a>
-
-# From Alex Krivenyshev (2008-05-09):
-# Is Western Sahara (part which administrated by Morocco) going to follow
-# Morocco DST changes?  Any information?  What about other part of
-# Western Sahara - under administration of POLISARIO Front (also named
-# SADR Saharawi Arab Democratic Republic)?
-
-# From Arthur David Olson (2008-05-09):
-# XXX--guess that it is only Morocco for now; guess only 2008 for now.
-
-# From Steffen Thorsen (2008-08-27):
-# Morocco will change the clocks back on the midnight between August 31 
-# and September 1. They originally planned to observe DST to near the end 
-# of September:
-#
-# One article about it (in French):
-# <a href="http://www.menara.ma/fr/Actualites/Maroc/Societe/ci.retour_a_l_heure_gmt_a_partir_du_dimanche_31_aout_a_minuit_officiel_.default">
-# http://www.menara.ma/fr/Actualites/Maroc/Societe/ci.retour_a_l_heure_gmt_a_partir_du_dimanche_31_aout_a_minuit_officiel_.default
-# </a>
-#
-# We have some further details posted here:
-# <a href="http://www.timeanddate.com/news/time/morocco-ends-dst-early-2008.html">
-# http://www.timeanddate.com/news/time/morocco-ends-dst-early-2008.html
-# </a>
-# RULE	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-
-Rule	Morocco	1939	only	-	Sep	12	 0:00	1:00	S
-Rule	Morocco	1939	only	-	Nov	19	 0:00	0	-
-Rule	Morocco	1940	only	-	Feb	25	 0:00	1:00	S
-Rule	Morocco	1945	only	-	Nov	18	 0:00	0	-
-Rule	Morocco	1950	only	-	Jun	11	 0:00	1:00	S
-Rule	Morocco	1950	only	-	Oct	29	 0:00	0	-
-Rule	Morocco	1967	only	-	Jun	 3	12:00	1:00	S
-Rule	Morocco	1967	only	-	Oct	 1	 0:00	0	-
-Rule	Morocco	1974	only	-	Jun	24	 0:00	1:00	S
-Rule	Morocco	1974	only	-	Sep	 1	 0:00	0	-
-Rule	Morocco	1976	1977	-	May	 1	 0:00	1:00	S
-Rule	Morocco	1976	only	-	Aug	 1	 0:00	0	-
-Rule	Morocco	1977	only	-	Sep	28	 0:00	0	-
-Rule	Morocco	1978	only	-	Jun	 1	 0:00	1:00	S
-Rule	Morocco	1978	only	-	Aug	 4	 0:00	0	-
-Rule	Morocco	2008	only	-	Jun	 1	 0:00	1:00	S
-Rule	Morocco	2008	only	-	Sep	 1	 0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Casablanca	-0:30:20 -	LMT	1913 Oct 26
-			 0:00	Morocco	WE%sT	1984 Mar 16
-			 1:00	-	CET	1986
-			 0:00	Morocco	WE%sT
-# Western Sahara
-Zone Africa/El_Aaiun	-0:52:48 -	LMT	1934 Jan
-			-1:00	-	WAT	1976 Apr 14
-			 0:00	-	WET
-
-# Mozambique
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Maputo	2:10:20 -	LMT	1903 Mar
-			2:00	-	CAT
-
-# Namibia
-# The 1994-04-03 transition is from Shanks & Pottenger.
-# Shanks & Pottenger report no DST after 1998-04; go with IATA.
-
-# From Petronella Sibeene (2007-03-30) in
-# <http://allafrica.com/stories/200703300178.html>:
-# While the entire country changes its time, Katima Mulilo and other
-# settlements in Caprivi unofficially will not because the sun there
-# rises and sets earlier compared to other regions.  Chief of
-# Forecasting Riaan van Zyl explained that the far eastern parts of
-# the country are close to 40 minutes earlier in sunrise than the rest
-# of the country.
-# 
-# From Paul Eggert (2007-03-31):
-# Apparently the Caprivi Strip informally observes Botswana time, but
-# we have no details.  In the meantime people there can use Africa/Gaborone.
-
-# RULE	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Namibia	1994	max	-	Sep	Sun>=1	2:00	1:00	S
-Rule	Namibia	1995	max	-	Apr	Sun>=1	2:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Windhoek	1:08:24 -	LMT	1892 Feb 8
-			1:30	-	SWAT	1903 Mar	# SW Africa Time
-			2:00	-	SAST	1942 Sep 20 2:00
-			2:00	1:00	SAST	1943 Mar 21 2:00
-			2:00	-	SAST	1990 Mar 21 # independence
-			2:00	-	CAT	1994 Apr  3
-			1:00	Namibia	WA%sT
-
-# Niger
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Niamey	 0:08:28 -	LMT	1912
-			-1:00	-	WAT	1934 Feb 26
-			 0:00	-	GMT	1960
-			 1:00	-	WAT
-
-# Nigeria
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Lagos	0:13:36 -	LMT	1919 Sep
-			1:00	-	WAT
-
-# Reunion
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Reunion	3:41:52 -	LMT	1911 Jun	# Saint-Denis
-			4:00	-	RET	# Reunion Time
-#
-# Scattered Islands (Iles Eparses) administered from Reunion are as follows.
-# The following information about them is taken from
-# Iles Eparses (www.outre-mer.gouv.fr/domtom/ile.htm, 1997-07-22, in French;
-# no longer available as of 1999-08-17).
-# We have no info about their time zone histories.
-#
-# Bassas da India - uninhabited
-# Europa Island - inhabited from 1905 to 1910 by two families
-# Glorioso Is - inhabited until at least 1958
-# Juan de Nova - uninhabited
-# Tromelin - inhabited until at least 1958
-
-# Rwanda
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Kigali	2:00:16 -	LMT	1935 Jun
-			2:00	-	CAT
-
-# St Helena
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/St_Helena	-0:22:48 -	LMT	1890		# Jamestown
-			-0:22:48 -	JMT	1951	# Jamestown Mean Time
-			 0:00	-	GMT
-# The other parts of the St Helena territory are similar:
-#	Tristan da Cunha: on GMT, say Whitman and the CIA
-#	Ascension: on GMT, says usno1995 and the CIA
-#	Gough (scientific station since 1955; sealers wintered previously):
-#		on GMT, says the CIA
-#	Inaccessible, Nightingale: no information, but probably GMT
-
-# Sao Tome and Principe
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Sao_Tome	 0:26:56 -	LMT	1884
-			-0:36:32 -	LMT	1912	# Lisbon Mean Time
-			 0:00	-	GMT
-
-# Senegal
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Dakar	-1:09:44 -	LMT	1912
-			-1:00	-	WAT	1941 Jun
-			 0:00	-	GMT
-
-# Seychelles
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Mahe	3:41:48 -	LMT	1906 Jun	# Victoria
-			4:00	-	SCT	# Seychelles Time
-# From Paul Eggert (2001-05-30):
-# Aldabra, Farquhar, and Desroches, originally dependencies of the
-# Seychelles, were transferred to the British Indian Ocean Territory
-# in 1965 and returned to Seychelles control in 1976.  We don't know
-# whether this affected their time zone, so omit this for now.
-# Possibly the islands were uninhabited.
-
-# Sierra Leone
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Whitman gives Mar 31 - Aug 31 for 1931 on; go with Shanks & Pottenger.
-Rule	SL	1935	1942	-	Jun	 1	0:00	0:40	SLST
-Rule	SL	1935	1942	-	Oct	 1	0:00	0	WAT
-Rule	SL	1957	1962	-	Jun	 1	0:00	1:00	SLST
-Rule	SL	1957	1962	-	Sep	 1	0:00	0	GMT
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Freetown	-0:53:00 -	LMT	1882
-			-0:53:00 -	FMT	1913 Jun # Freetown Mean Time
-			-1:00	SL	%s	1957
-			 0:00	SL	%s
-
-# Somalia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Mogadishu	3:01:28 -	LMT	1893 Nov
-			3:00	-	EAT	1931
-			2:30	-	BEAT	1957
-			3:00	-	EAT
-
-# South Africa
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	SA	1942	1943	-	Sep	Sun>=15	2:00	1:00	-
-Rule	SA	1943	1944	-	Mar	Sun>=15	2:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Johannesburg 1:52:00 -	LMT	1892 Feb 8
-			1:30	-	SAST	1903 Mar
-			2:00	SA	SAST
-# Marion and Prince Edward Is
-# scientific station since 1947
-# no information
-
-# Sudan
-#
-# From <a href="http://www.sunanews.net/sn13jane.html">
-# Sudan News Agency (2000-01-13)
-# </a>, also reported by Michael De Beukelaer-Dossche via Steffen Thorsen:
-# Clocks will be moved ahead for 60 minutes all over the Sudan as of noon
-# Saturday....  This was announced Thursday by Caretaker State Minister for
-# Manpower Abdul-Rahman Nur-Eddin.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Sudan	1970	only	-	May	 1	0:00	1:00	S
-Rule	Sudan	1970	1985	-	Oct	15	0:00	0	-
-Rule	Sudan	1971	only	-	Apr	30	0:00	1:00	S
-Rule	Sudan	1972	1985	-	Apr	lastSun	0:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Khartoum	2:10:08 -	LMT	1931
-			2:00	Sudan	CA%sT	2000 Jan 15 12:00
-			3:00	-	EAT
-
-# Swaziland
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Mbabane	2:04:24 -	LMT	1903 Mar
-			2:00	-	SAST
-
-# Tanzania
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Africa/Dar_es_Salaam 2:37:08 -	LMT	1931
-			3:00	-	EAT	1948
-			2:44:45	-	BEAUT	1961
-			3:00	-	EAT
-
-# Togo
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Lome	0:04:52 -	LMT	1893
-			0:00	-	GMT
-
-# Tunisia
-
-# From Gwillim Law (2005-04-30):
-# My correspondent, Risto Nykanen, has alerted me to another adoption of DST,
-# this time in Tunisia.  According to Yahoo France News
-# <http://fr.news.yahoo.com/050426/5/4dumk.html>, in a story attributed to AP
-# and dated 2005-04-26, "Tunisia has decided to advance its official time by
-# one hour, starting on Sunday, May 1.  Henceforth, Tunisian time will be
-# UTC+2 instead of UTC+1.  The change will take place at 23:00 UTC next
-# Saturday."  (My translation)
-#
-# From Oscar van Vlijmen (2005-05-02):
-# LaPresse, the first national daily newspaper ...
-# <http://www.lapresse.tn/archives/archives280405/actualites/lheure.html>
-# ... DST for 2005: on: Sun May 1 0h standard time, off: Fri Sept. 30,
-# 1h standard time.
-#
-# From Atef Loukil (2006-03-28):
-# The daylight saving time will be the same each year:
-# Beginning      : the last Sunday of March at 02:00
-# Ending         : the last Sunday of October at 03:00 ...
-# http://www.tap.info.tn/en/index.php?option=com_content&task=view&id=1188&Itemid=50
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Tunisia	1939	only	-	Apr	15	23:00s	1:00	S
-Rule	Tunisia	1939	only	-	Nov	18	23:00s	0	-
-Rule	Tunisia	1940	only	-	Feb	25	23:00s	1:00	S
-Rule	Tunisia	1941	only	-	Oct	 6	 0:00	0	-
-Rule	Tunisia	1942	only	-	Mar	 9	 0:00	1:00	S
-Rule	Tunisia	1942	only	-	Nov	 2	 3:00	0	-
-Rule	Tunisia	1943	only	-	Mar	29	 2:00	1:00	S
-Rule	Tunisia	1943	only	-	Apr	17	 2:00	0	-
-Rule	Tunisia	1943	only	-	Apr	25	 2:00	1:00	S
-Rule	Tunisia	1943	only	-	Oct	 4	 2:00	0	-
-Rule	Tunisia	1944	1945	-	Apr	Mon>=1	 2:00	1:00	S
-Rule	Tunisia	1944	only	-	Oct	 8	 0:00	0	-
-Rule	Tunisia	1945	only	-	Sep	16	 0:00	0	-
-Rule	Tunisia	1977	only	-	Apr	30	 0:00s	1:00	S
-Rule	Tunisia	1977	only	-	Sep	24	 0:00s	0	-
-Rule	Tunisia	1978	only	-	May	 1	 0:00s	1:00	S
-Rule	Tunisia	1978	only	-	Oct	 1	 0:00s	0	-
-Rule	Tunisia	1988	only	-	Jun	 1	 0:00s	1:00	S
-Rule	Tunisia	1988	1990	-	Sep	lastSun	 0:00s	0	-
-Rule	Tunisia	1989	only	-	Mar	26	 0:00s	1:00	S
-Rule	Tunisia	1990	only	-	May	 1	 0:00s	1:00	S
-Rule	Tunisia	2005	only	-	May	 1	 0:00s	1:00	S
-Rule	Tunisia	2005	only	-	Sep	30	 1:00s	0	-
-Rule	Tunisia	2006	max	-	Mar	lastSun	 2:00s	1:00	S
-Rule	Tunisia	2006	max	-	Oct	lastSun	 2:00s	0	-
-# Shanks & Pottenger give 0:09:20 for Paris Mean Time; go with Howse's
-# more precise 0:09:21.
-# Shanks & Pottenger say the 1911 switch was on Mar 9; go with Howse's Mar 11.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Tunis	0:40:44 -	LMT	1881 May 12
-			0:09:21	-	PMT	1911 Mar 11    # Paris Mean Time
-			1:00	Tunisia	CE%sT
-
-# Uganda
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Kampala	2:09:40 -	LMT	1928 Jul
-			3:00	-	EAT	1930
-			2:30	-	BEAT	1948
-			2:44:45	-	BEAUT	1957
-			3:00	-	EAT
-
-# Zambia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Lusaka	1:53:08 -	LMT	1903 Mar
-			2:00	-	CAT
-
-# Zimbabwe
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Africa/Harare	2:04:12 -	LMT	1903 Mar
-			2:00	-	CAT
diff --git a/tools/zoneinfo/tzdata2008h/antarctica b/tools/zoneinfo/tzdata2008h/antarctica
deleted file mode 100644
index ef279cb..0000000
--- a/tools/zoneinfo/tzdata2008h/antarctica
+++ /dev/null
@@ -1,327 +0,0 @@
-# @(#)antarctica	8.4
-# <pre>
-
-# From Paul Eggert (1999-11-15):
-# To keep things manageable, we list only locations occupied year-round; see
-# <a href="http://www.comnap.aq/comnap/comnap.nsf/P/Stations/">
-# COMNAP - Stations and Bases
-# </a>
-# and
-# <a href="http://www.spri.cam.ac.uk/bob/periant.htm">
-# Summary of the Peri-Antarctic Islands (1998-07-23)
-# </a>
-# for information.
-# Unless otherwise specified, we have no time zone information.
-#
-# Except for the French entries,
-# I made up all time zone abbreviations mentioned here; corrections welcome!
-# FORMAT is `zzz' and GMTOFF is 0 for locations while uninhabited.
-
-# These rules are stolen from the `europe' file.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	RussAQ	1981	1984	-	Apr	 1	 0:00	1:00	S
-Rule	RussAQ	1981	1983	-	Oct	 1	 0:00	0	-
-Rule	RussAQ	1984	1991	-	Sep	lastSun	 2:00s	0	-
-Rule	RussAQ	1985	1991	-	Mar	lastSun	 2:00s	1:00	S
-Rule	RussAQ	1992	only	-	Mar	lastSat	 23:00	1:00	S
-Rule	RussAQ	1992	only	-	Sep	lastSat	 23:00	0	-
-Rule	RussAQ	1993	max	-	Mar	lastSun	 2:00s	1:00	S
-Rule	RussAQ	1993	1995	-	Sep	lastSun	 2:00s	0	-
-Rule	RussAQ	1996	max	-	Oct	lastSun	 2:00s	0	-
-
-# These rules are stolen from the `southamerica' file.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	ArgAQ	1964	1966	-	Mar	 1	0:00	0	-
-Rule	ArgAQ	1964	1966	-	Oct	15	0:00	1:00	S
-Rule	ArgAQ	1967	only	-	Apr	 2	0:00	0	-
-Rule	ArgAQ	1967	1968	-	Oct	Sun>=1	0:00	1:00	S
-Rule	ArgAQ	1968	1969	-	Apr	Sun>=1	0:00	0	-
-Rule	ArgAQ	1974	only	-	Jan	23	0:00	1:00	S
-Rule	ArgAQ	1974	only	-	May	 1	0:00	0	-
-Rule	ChileAQ	1972	1986	-	Mar	Sun>=9	3:00u	0	-
-Rule	ChileAQ	1974	1987	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	ChileAQ	1987	only	-	Apr	12	3:00u	0	-
-Rule	ChileAQ	1988	1989	-	Mar	Sun>=9	3:00u	0	-
-Rule	ChileAQ	1988	only	-	Oct	Sun>=1	4:00u	1:00	S
-Rule	ChileAQ	1989	only	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	ChileAQ	1990	only	-	Mar	18	3:00u	0	-
-Rule	ChileAQ	1990	only	-	Sep	16	4:00u	1:00	S
-Rule	ChileAQ	1991	1996	-	Mar	Sun>=9	3:00u	0	-
-Rule	ChileAQ	1991	1997	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	ChileAQ	1997	only	-	Mar	30	3:00u	0	-
-Rule	ChileAQ	1998	only	-	Mar	Sun>=9	3:00u	0	-
-Rule	ChileAQ	1998	only	-	Sep	27	4:00u	1:00	S
-Rule	ChileAQ	1999	only	-	Apr	 4	3:00u	0	-
-Rule	ChileAQ	1999	max	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	ChileAQ	2000	max	-	Mar	Sun>=9	3:00u	0	-
-
-
-# Argentina - year-round bases
-# Belgrano II, Confin Coast, -770227-0343737, since 1972-02-05
-# Esperanza, San Martin Land, -6323-05659, since 1952-12-17
-# Jubany, Potter Peninsula, King George Island, -6414-0602320, since 1982-01
-# Marambio, Seymour I, -6414-05637, since 1969-10-29
-# Orcadas, Laurie I, -6016-04444, since 1904-02-22
-# San Martin, Debenham I, -6807-06708, since 1951-03-21
-#	(except 1960-03 / 1976-03-21)
-
-# Australia - territories
-# Heard Island, McDonald Islands (uninhabited)
-#	previously sealers and scientific personnel wintered
-#	<a href="http://web.archive.org/web/20021204222245/http://www.dstc.qut.edu.au/DST/marg/daylight.html">
-#	Margaret Turner reports
-#	</a> (1999-09-30) that they're UTC+5, with no DST;
-#	presumably this is when they have visitors.
-#
-# year-round bases
-# Casey, Bailey Peninsula, -6617+11032, since 1969
-# Davis, Vestfold Hills, -6835+07759, since 1957-01-13
-#	(except 1964-11 - 1969-02)
-# Mawson, Holme Bay, -6736+06253, since 1954-02-13
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/Casey	0	-	zzz	1969
-			8:00	-	WST	# Western (Aus) Standard Time
-Zone Antarctica/Davis	0	-	zzz	1957 Jan 13
-			7:00	-	DAVT	1964 Nov # Davis Time
-			0	-	zzz	1969 Feb
-			7:00	-	DAVT
-Zone Antarctica/Mawson	0	-	zzz	1954 Feb 13
-			6:00	-	MAWT	# Mawson Time
-# References:
-# <a href="http://www.antdiv.gov.au/aad/exop/sfo/casey/casey_aws.html">
-# Casey Weather (1998-02-26)
-# </a>
-# <a href="http://www.antdiv.gov.au/aad/exop/sfo/davis/video.html">
-# Davis Station, Antarctica (1998-02-26)
-# </a>
-# <a href="http://www.antdiv.gov.au/aad/exop/sfo/mawson/video.html">
-# Mawson Station, Antarctica (1998-02-25)
-# </a>
-
-# Brazil - year-round base
-# Comandante Ferraz, King George Island, -6205+05824, since 1983/4
-
-# Chile - year-round bases and towns
-# Escudero, South Shetland Is, -621157-0585735, since 1994
-# Presidente Eduadro Frei, King George Island, -6214-05848, since 1969-03-07
-# General Bernardo O'Higgins, Antarctic Peninsula, -6319-05704, since 1948-02
-# Capitan Arturo Prat, -6230-05941
-# Villa Las Estrellas (a town), around the Frei base, since 1984-04-09
-# These locations have always used Santiago time; use TZ='America/Santiago'.
-
-# China - year-round bases
-# Great Wall, King George Island, -6213-05858, since 1985-02-20
-# Zhongshan, Larsemann Hills, Prydz Bay, -6922+07623, since 1989-02-26
-
-# France - year-round bases
-#
-# From Antoine Leca (1997-01-20):
-# Time data are from Nicole Pailleau at the IFRTP
-# (French Institute for Polar Research and Technology).
-# She confirms that French Southern Territories and Terre Adelie bases
-# don't observe daylight saving time, even if Terre Adelie supplies came
-# from Tasmania.
-#
-# French Southern Territories with year-round inhabitants
-#
-# Martin-de-Vivies Base, Amsterdam Island, -374105+0773155, since 1950
-# Alfred-Faure Base, Crozet Islands, -462551+0515152, since 1964
-# Port-aux-Francais, Kerguelen Islands, -492110+0701303, since 1951;
-#	whaling & sealing station operated 1908/1914, 1920/1929, and 1951/1956
-#
-# St Paul Island - near Amsterdam, uninhabited
-#	fishing stations operated variously 1819/1931
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Indian/Kerguelen	0	-	zzz	1950	# Port-aux-Francais
-			5:00	-	TFT	# ISO code TF Time
-#
-# year-round base in the main continent
-# Dumont-d'Urville, Ile des Petrels, -6640+14001, since 1956-11
-#
-# Another base at Port-Martin, 50km east, began operation in 1947.
-# It was destroyed by fire on 1952-01-14.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/DumontDUrville 0 -	zzz	1947
-			10:00	-	PMT	1952 Jan 14 # Port-Martin Time
-			0	-	zzz	1956 Nov
-			10:00	-	DDUT	# Dumont-d'Urville Time
-# Reference:
-# <a href="http://en.wikipedia.org/wiki/Dumont_d'Urville_Station">
-# Dumont d'Urville Station (2005-12-05)
-# </a>
-
-# Germany - year-round base
-# Georg von Neumayer, -7039-00815
-
-# India - year-round base
-# Dakshin Gangotri, -7005+01200
-
-# Japan - year-round bases
-# Dome Fuji, -7719+03942
-# Syowa, -690022+0393524
-#
-# From Hideyuki Suzuki (1999-02-06):
-# In all Japanese stations, +0300 is used as the standard time.
-#
-# Syowa station, which is the first antarctic station of Japan,
-# was established on 1957-01-29.  Since Syowa station is still the main
-# station of Japan, it's appropriate for the principal location.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/Syowa	0	-	zzz	1957 Jan 29
-			3:00	-	SYOT	# Syowa Time
-# See:
-# <a href="http://www.nipr.ac.jp/english/ara01.html">
-# NIPR Antarctic Research Activities (1999-08-17)
-# </a>
-
-# S Korea - year-round base
-# King Sejong, King George Island, -6213-05847, since 1988
-
-# New Zealand - claims
-# Balleny Islands (never inhabited)
-# Scott Island (never inhabited)
-#
-# year-round base
-# Scott, Ross Island, since 1957-01, is like Antarctica/McMurdo.
-#
-# These rules for New Zealand are stolen from the `australasia' file.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	NZAQ	1974	only	-	Nov	 3	2:00s	1:00	D
-Rule	NZAQ	1975	1988	-	Oct	lastSun	2:00s	1:00	D
-Rule	NZAQ	1989	only	-	Oct	 8	2:00s	1:00	D
-Rule	NZAQ	1990	2006	-	Oct	Sun>=1	2:00s	1:00	D
-Rule	NZAQ	1975	only	-	Feb	23	2:00s	0	S
-Rule	NZAQ	1976	1989	-	Mar	Sun>=1	2:00s	0	S
-Rule	NZAQ	1990	2007	-	Mar	Sun>=15	2:00s	0	S
-Rule	NZAQ	2007	max	-	Sep	lastSun	2:00s	1:00	D
-Rule	NZAQ	2008	max	-	Apr	Sun>=1	2:00s	0	S
-
-# Norway - territories
-# Bouvet (never inhabited)
-#
-# claims
-# Peter I Island (never inhabited)
-
-# Poland - year-round base
-# Arctowski, King George Island, -620945-0582745, since 1977
-
-# Russia - year-round bases
-# Bellingshausen, King George Island, -621159-0585337, since 1968-02-22
-# Mirny, Davis coast, -6633+09301, since 1956-02
-# Molodezhnaya, Alasheyev Bay, -6740+04551,
-#	year-round from 1962-02 to 1999-07-01
-# Novolazarevskaya, Queen Maud Land, -7046+01150,
-#	year-round from 1960/61 to 1992
-
-# Vostok, since 1957-12-16, temporarily closed 1994-02/1994-11
-# <a href="http://quest.arc.nasa.gov/antarctica/QA/computers/Directions,Time,ZIP">
-# From Craig Mundell (1994-12-15)</a>:
-# Vostok, which is one of the Russian stations, is set on the same
-# time as Moscow, Russia.
-#
-# From Lee Hotz (2001-03-08):
-# I queried the folks at Columbia who spent the summer at Vostok and this is
-# what they had to say about time there:
-# ``in the US Camp (East Camp) we have been on New Zealand (McMurdo)
-# time, which is 12 hours ahead of GMT. The Russian Station Vostok was
-# 6 hours behind that (although only 2 miles away, i.e. 6 hours ahead
-# of GMT). This is a time zone I think two hours east of Moscow. The
-# natural time zone is in between the two: 8 hours ahead of GMT.''
-#
-# From Paul Eggert (2001-05-04):
-# This seems to be hopelessly confusing, so I asked Lee Hotz about it
-# in person.  He said that some Antartic locations set their local
-# time so that noon is the warmest part of the day, and that this
-# changes during the year and does not necessarily correspond to mean
-# solar noon.  So the Vostok time might have been whatever the clocks
-# happened to be during their visit.  So we still don't really know what time
-# it is at Vostok.  But we'll guess UTC+6.
-#
-Zone Antarctica/Vostok	0	-	zzz	1957 Dec 16
-			6:00	-	VOST	# Vostok time
-
-# S Africa - year-round bases
-# Marion Island, -4653+03752
-# Sanae, -7141-00250
-
-# UK
-#
-# British Antarctic Territories (BAT) claims
-# South Orkney Islands
-#	scientific station from 1903
-#	whaling station at Signy I 1920/1926
-# South Shetland Islands
-#
-# year-round bases
-# Bird Island, South Georgia, -5400-03803, since 1983
-# Deception Island, -6259-06034, whaling station 1912/1931,
-#	scientific station 1943/1967,
-#	previously sealers and a scientific expedition wintered by accident,
-#	and a garrison was deployed briefly
-# Halley, Coates Land, -7535-02604, since 1956-01-06
-#	Halley is on a moving ice shelf and is periodically relocated
-#	so that it is never more than 10km from its nominal location.
-# Rothera, Adelaide Island, -6734-6808, since 1976-12-01
-#
-# From Paul Eggert (2002-10-22)
-# <http://webexhibits.org/daylightsaving/g.html> says Rothera is -03 all year.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/Rothera	0	-	zzz	1976 Dec  1
-			-3:00	-	ROTT	# Rothera time
-
-# Uruguay - year round base
-# Artigas, King George Island, -621104-0585107
-
-# USA - year-round bases
-#
-# Palmer, Anvers Island, since 1965 (moved 2 miles in 1968)
-#
-# From Ethan Dicks (1996-10-06):
-# It keeps the same time as Punta Arenas, Chile, because, just like us
-# and the South Pole, that's the other end of their supply line....
-# I verified with someone who was there that since 1980,
-# Palmer has followed Chile.  Prior to that, before the Falklands War,
-# Palmer used to be supplied from Argentina.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/Palmer	0	-	zzz	1965
-			-4:00	ArgAQ	AR%sT	1969 Oct 5
-			-3:00	ArgAQ	AR%sT	1982 May
-			-4:00	ChileAQ	CL%sT
-#
-#
-# McMurdo, Ross Island, since 1955-12
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Antarctica/McMurdo	0	-	zzz	1956
-			12:00	NZAQ	NZ%sT
-#
-# Amundsen-Scott, South Pole, continuously occupied since 1956-11-20
-#
-# From Paul Eggert (1996-09-03):
-# Normally it wouldn't have a separate entry, since it's like the
-# larger Antarctica/McMurdo since 1970, but it's too famous to omit.
-#
-# From Chris Carrier (1996-06-27):
-# Siple, the first commander of the South Pole station,
-# stated that he would have liked to have kept GMT at the station,
-# but that he found it more convenient to keep GMT+12
-# as supplies for the station were coming from McMurdo Sound,
-# which was on GMT+12 because New Zealand was on GMT+12 all year
-# at that time (1957).  (Source: Siple's book 90 degrees SOUTH.)
-#
-# From Susan Smith
-# http://www.cybertours.com/whs/pole10.html
-# (1995-11-13 16:24:56 +1300, no longer available):
-# We use the same time as McMurdo does.
-# And they use the same time as Christchurch, NZ does....
-# One last quirk about South Pole time.
-# All the electric clocks are usually wrong.
-# Something about the generators running at 60.1hertz or something
-# makes all of the clocks run fast.  So every couple of days,
-# we have to go around and set them back 5 minutes or so.
-# Maybe if we let them run fast all of the time, we'd get to leave here sooner!!
-#
-Link	Antarctica/McMurdo	Antarctica/South_Pole
diff --git a/tools/zoneinfo/tzdata2008h/asia b/tools/zoneinfo/tzdata2008h/asia
deleted file mode 100644
index eb9f411..0000000
--- a/tools/zoneinfo/tzdata2008h/asia
+++ /dev/null
@@ -1,2043 +0,0 @@
-# @(#)asia	8.24
-# <pre>
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (2006-03-22):
-#
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1990, and IATA SSIM is the source for entries afterwards.
-#
-# Another source occasionally used is Edward W. Whitman, World Time Differences,
-# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which
-# I found in the UCLA library.
-#
-# A reliable and entertaining source about time zones is
-# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997).
-#
-# I invented the abbreviations marked `*' in the following table;
-# the rest are from earlier versions of this file, or from other sources.
-# Corrections are welcome!
-#	     std  dst
-#	     LMT	Local Mean Time
-#	2:00 EET  EEST	Eastern European Time
-#	2:00 IST  IDT	Israel
-#	3:00 AST  ADT	Arabia*
-#	3:30 IRST IRDT	Iran
-#	4:00 GST	Gulf*
-#	5:30 IST	India
-#	7:00 ICT	Indochina*
-#	7:00 WIT	west Indonesia
-#	8:00 CIT	central Indonesia
-#	8:00 CST	China
-#	9:00 CJT	Central Japanese Time (1896/1937)*
-#	9:00 EIT	east Indonesia
-#	9:00 JST  JDT	Japan
-#	9:00 KST  KDT	Korea
-#	9:30 CST	(Australian) Central Standard Time
-#
-# See the `europe' file for Russia and Turkey in Asia.
-
-# From Guy Harris:
-# Incorporates data for Singapore from Robert Elz' asia 1.1, as well as
-# additional information from Tom Yap, Sun Microsystems Intercontinental
-# Technical Support (including a page from the Official Airline Guide -
-# Worldwide Edition).  The names for time zones are guesses.
-
-###############################################################################
-
-# These rules are stolen from the `europe' file.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	EUAsia	1981	max	-	Mar	lastSun	 1:00u	1:00	S
-Rule	EUAsia	1979	1995	-	Sep	lastSun	 1:00u	0	-
-Rule	EUAsia	1996	max	-	Oct	lastSun	 1:00u	0	-
-Rule E-EurAsia	1981	max	-	Mar	lastSun	 0:00	1:00	S
-Rule E-EurAsia	1979	1995	-	Sep	lastSun	 0:00	0	-
-Rule E-EurAsia	1996	max	-	Oct	lastSun	 0:00	0	-
-Rule RussiaAsia	1981	1984	-	Apr	1	 0:00	1:00	S
-Rule RussiaAsia	1981	1983	-	Oct	1	 0:00	0	-
-Rule RussiaAsia	1984	1991	-	Sep	lastSun	 2:00s	0	-
-Rule RussiaAsia	1985	1991	-	Mar	lastSun	 2:00s	1:00	S
-Rule RussiaAsia	1992	only	-	Mar	lastSat	23:00	1:00	S
-Rule RussiaAsia	1992	only	-	Sep	lastSat	23:00	0	-
-Rule RussiaAsia	1993	max	-	Mar	lastSun	 2:00s	1:00	S
-Rule RussiaAsia	1993	1995	-	Sep	lastSun	 2:00s	0	-
-Rule RussiaAsia	1996	max	-	Oct	lastSun	 2:00s	0	-
-
-# Afghanistan
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Kabul	4:36:48 -	LMT	1890
-			4:00	-	AFT	1945
-			4:30	-	AFT
-
-# Armenia
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger have Yerevan switching to 3:00 (with Russian DST)
-# in spring 1991, then to 4:00 with no DST in fall 1995, then
-# readopting Russian DST in 1997.  Go with Shanks & Pottenger, even
-# when they disagree with others.  Edgar Der-Danieliantz
-# reported (1996-05-04) that Yerevan probably wouldn't use DST
-# in 1996, though it did use DST in 1995.  IATA SSIM (1991/1998) reports that
-# Armenia switched from 3:00 to 4:00 in 1998 and observed DST after 1991,
-# but started switching at 3:00s in 1998.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Yerevan	2:58:00 -	LMT	1924 May  2
-			3:00	-	YERT	1957 Mar    # Yerevan Time
-			4:00 RussiaAsia YER%sT	1991 Mar 31 2:00s
-			3:00	1:00	YERST	1991 Sep 23 # independence
-			3:00 RussiaAsia	AM%sT	1995 Sep 24 2:00s
-			4:00	-	AMT	1997
-			4:00 RussiaAsia	AM%sT
-
-# Azerbaijan
-# From Rustam Aliyev of the Azerbaijan Internet Forum (2005-10-23):
-# According to the resolution of Cabinet of Ministers, 1997
-# Resolution available at: http://aif.az/docs/daylight_res.pdf
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Azer	1997	max	-	Mar	lastSun	 4:00	1:00	S
-Rule	Azer	1997	max	-	Oct	lastSun	 5:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Baku	3:19:24 -	LMT	1924 May  2
-			3:00	-	BAKT	1957 Mar    # Baku Time
-			4:00 RussiaAsia BAK%sT	1991 Mar 31 2:00s
-			3:00	1:00	BAKST	1991 Aug 30 # independence
-			3:00 RussiaAsia	AZ%sT	1992 Sep lastSat 23:00
-			4:00	-	AZT	1996 # Azerbaijan time
-			4:00	EUAsia	AZ%sT	1997
-			4:00	Azer	AZ%sT
-
-# Bahrain
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Bahrain	3:22:20 -	LMT	1920		# Al Manamah
-			4:00	-	GST	1972 Jun
-			3:00	-	AST
-
-# Bangladesh
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Dhaka	6:01:40 -	LMT	1890
-			5:53:20	-	HMT	1941 Oct    # Howrah Mean Time?
-			6:30	-	BURT	1942 May 15 # Burma Time
-			5:30	-	IST	1942 Sep
-			6:30	-	BURT	1951 Sep 30
-			6:00	-	DACT	1971 Mar 26 # Dacca Time
-			6:00	-	BDT	# Bangladesh Time
-
-# Bhutan
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Thimphu	5:58:36 -	LMT	1947 Aug 15 # or Thimbu
-			5:30	-	IST	1987 Oct
-			6:00	-	BTT	# Bhutan Time
-
-# British Indian Ocean Territory
-# Whitman and the 1995 CIA time zone map say 5:00, but the
-# 1997 and later maps say 6:00.  Assume the switch occurred in 1996.
-# We have no information as to when standard time was introduced;
-# assume it occurred in 1907, the same year as Mauritius (which
-# then contained the Chagos Archipelago).
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Chagos	4:49:40	-	LMT	1907
-			5:00	-	IOT	1996 # BIOT Time
-			6:00	-	IOT
-
-# Brunei
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Brunei	7:39:40 -	LMT	1926 Mar   # Bandar Seri Begawan
-			7:30	-	BNT	1933
-			8:00	-	BNT
-
-# Burma / Myanmar
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Rangoon	6:24:40 -	LMT	1880		# or Yangon
-			6:24:36	-	RMT	1920	   # Rangoon Mean Time?
-			6:30	-	BURT	1942 May   # Burma Time
-			9:00	-	JST	1945 May 3
-			6:30	-	MMT		   # Myanmar Time
-
-# Cambodia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Phnom_Penh	6:59:40 -	LMT	1906 Jun  9
-			7:06:20	-	SMT	1911 Mar 11 0:01 # Saigon MT?
-			7:00	-	ICT	1912 May
-			8:00	-	ICT	1931 May
-			7:00	-	ICT
-
-# China
-
-# From Guy Harris:
-# People's Republic of China.  Yes, they really have only one time zone.
-
-# From Bob Devine (1988-01-28):
-# No they don't.  See TIME mag, 1986-02-17 p.52.  Even though
-# China is across 4 physical time zones, before Feb 1, 1986 only the
-# Peking (Bejing) time zone was recognized.  Since that date, China
-# has two of 'em -- Peking's and Urumqi (named after the capital of
-# the Xinjiang Uyghur Autonomous Region).  I don't know about DST for it.
-#
-# . . .I just deleted the DST table and this editor makes it too
-# painful to suck in another copy..  So, here is what I have for
-# DST start/end dates for Peking's time zone (info from AP):
-#
-#     1986 May 4 - Sept 14
-#     1987 mid-April - ??
-
-# From U. S. Naval Observatory (1989-01-19):
-# CHINA               8 H  AHEAD OF UTC  ALL OF CHINA, INCL TAIWAN
-# CHINA               9 H  AHEAD OF UTC  APR 17 - SEP 10
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that China (except for Hong Kong and Macau)
-# has had a single time zone since 1980 May 1, observing summer DST
-# from 1986 through 1991; this contradicts Devine's
-# note about Time magazine, though apparently _something_ happened in 1986.
-# Go with Shanks & Pottenger for now.  I made up names for the other
-# pre-1980 time zones.
-
-# From Shanks & Pottenger:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Shang	1940	only	-	Jun	 3	0:00	1:00	D
-Rule	Shang	1940	1941	-	Oct	 1	0:00	0	S
-Rule	Shang	1941	only	-	Mar	16	0:00	1:00	D
-Rule	PRC	1986	only	-	May	 4	0:00	1:00	D
-Rule	PRC	1986	1991	-	Sep	Sun>=11	0:00	0	S
-Rule	PRC	1987	1991	-	Apr	Sun>=10	0:00	1:00	D
-
-# From Anthony Fok (2001-12-20):
-# BTW, I did some research on-line and found some info regarding these five
-# historic timezones from some Taiwan websites.  And yes, there are official
-# Chinese names for these locales (before 1949).
-#
-# From Jesper Norgaard Welen (2006-07-14):
-# I have investigated the timezones around 1970 on the
-# http://www.astro.com/atlas site [with provinces and county
-# boundaries summarized below]....  A few other exceptions were two
-# counties on the Sichuan side of the Xizang-Sichuan border,
-# counties Dege and Baiyu which lies on the Sichuan side and are
-# therefore supposed to be GMT+7, Xizang region being GMT+6, but Dege
-# county is GMT+8 according to astro.com while Baiyu county is GMT+6
-# (could be true), for the moment I am assuming that those two
-# counties are mistakes in the astro.com data.
-
-# From Paul Eggert (2008-02-11):
-# I just now checked Google News for western news sources that talk
-# about China's single time zone, and couldn't find anything before 1986
-# talking about China being in one time zone.  (That article was: Jim
-# Mann, "A clumsy embrace for another western custom: China on daylight
-# time--sort of", Los Angeles Times, 1986-05-05.  By the way, this
-# article confirms the tz database's data claiming that China began
-# observing daylight saving time in 1986.
-#
-# From Thomas S. Mullaney (2008-02-11):
-# I think you're combining two subjects that need to treated 
-# separately: daylight savings (which, you're correct, wasn't 
-# implemented until the 1980s) and the unified time zone centered near 
-# Beijing (which was implemented in 1949). Briefly, there was also a 
-# "Lhasa Time" in Tibet and "Urumqi Time" in Xinjiang. The first was 
-# ceased, and the second eventually recognized (again, in the 1980s).
-#
-# From Paul Eggert (2008-06-30):
-# There seems to be a good chance China switched to a single time zone in 1949
-# rather than in 1980 as Shanks & Pottenger have it, but we don't have a
-# reliable documentary source saying so yet, so for now we still go with
-# Shanks & Pottenger.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Changbai Time ("Long-white Time", Long-white = Heilongjiang area)
-# Heilongjiang (except Mohe county), Jilin
-Zone	Asia/Harbin	8:26:44	-	LMT	1928 # or Haerbin
-			8:30	-	CHAT	1932 Mar # Changbai Time
-			8:00	-	CST	1940
-			9:00	-	CHAT	1966 May
-			8:30	-	CHAT	1980 May
-			8:00	PRC	C%sT
-# Zhongyuan Time ("Central plain Time")
-# most of China
-Zone	Asia/Shanghai	8:05:52	-	LMT	1928
-			8:00	Shang	C%sT	1949
-			8:00	PRC	C%sT
-# Long-shu Time (probably due to Long and Shu being two names of that area)
-# Guangxi, Guizhou, Hainan, Ningxia, Sichuan, Shaanxi, and Yunnan;
-# most of Gansu; west Inner Mongolia; west Qinghai; and the Guangdong
-# counties Deqing, Enping, Kaiping, Luoding, Taishan, Xinxing,
-# Yangchun, Yangjiang, Yu'nan, and Yunfu.
-Zone	Asia/Chongqing	7:06:20	-	LMT	1928 # or Chungking
-			7:00	-	LONT	1980 May # Long-shu Time
-			8:00	PRC	C%sT
-# Xin-zang Time ("Xinjiang-Tibet Time")
-# The Gansu counties Aksay, Anxi, Dunhuang, Subei; west Qinghai;
-# the Guangdong counties  Xuwen, Haikang, Suixi, Lianjiang,
-# Zhanjiang, Wuchuan, Huazhou, Gaozhou, Maoming, Dianbai, and Xinyi;
-# east Tibet, including Lhasa, Chamdo, Shigaise, Jimsar, Shawan and Hutubi;
-# east Xinjiang, including Urumqi, Turpan, Karamay, Korla, Minfeng, Jinghe,
-# Wusu, Qiemo, Xinyan, Wulanwusu, Jinghe, Yumin, Tacheng, Tuoli, Emin,
-# Shihezi, Changji, Yanqi, Heshuo, Tuokexun, Tulufan, Shanshan, Hami,
-# Fukang, Kuitun, Kumukuli, Miquan, Qitai, and Turfan.
-Zone	Asia/Urumqi	5:50:20	-	LMT	1928 # or Urumchi
-			6:00	-	URUT	1980 May # Urumqi Time
-			8:00	PRC	C%sT
-# Kunlun Time
-# West Tibet, including Pulan, Aheqi, Shufu, Shule;
-# West Xinjiang, including Aksu, Atushi, Yining, Hetian, Cele, Luopu, Nileke,
-# Zhaosu, Tekesi, Gongliu, Chabuchaer, Huocheng, Bole, Pishan, Suiding,
-# and Yarkand.
-Zone	Asia/Kashgar	5:03:56	-	LMT	1928 # or Kashi or Kaxgar
-			5:30	-	KAST	1940	 # Kashgar Time
-			5:00	-	KAST	1980 May
-			8:00	PRC	C%sT
-
-# Hong Kong (Xianggang)
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	HK	1946	only	-	Apr	20	3:30	1:00	S
-Rule	HK	1946	only	-	Dec	1	3:30	0	-
-Rule	HK	1947	only	-	Apr	13	3:30	1:00	S
-Rule	HK	1947	only	-	Dec	30	3:30	0	-
-Rule	HK	1948	only	-	May	2	3:30	1:00	S
-Rule	HK	1948	1952	-	Oct	lastSun	3:30	0	-
-Rule	HK	1949	1953	-	Apr	Sun>=1	3:30	1:00	S
-Rule	HK	1953	only	-	Nov	1	3:30	0	-
-Rule	HK	1954	1964	-	Mar	Sun>=18	3:30	1:00	S
-Rule	HK	1954	only	-	Oct	31	3:30	0	-
-Rule	HK	1955	1964	-	Nov	Sun>=1	3:30	0	-
-Rule	HK	1965	1977	-	Apr	Sun>=16	3:30	1:00	S
-Rule	HK	1965	1977	-	Oct	Sun>=16	3:30	0	-
-Rule	HK	1979	1980	-	May	Sun>=8	3:30	1:00	S
-Rule	HK	1979	1980	-	Oct	Sun>=16	3:30	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Hong_Kong	7:36:36 -	LMT	1904 Oct 30
-			8:00	HK	HK%sT
-
-
-###############################################################################
-
-# Taiwan
-
-# Shanks & Pottenger write that Taiwan observed DST during 1945, when it
-# was still controlled by Japan.  This is hard to believe, but we don't
-# have any other information.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Taiwan	1945	1951	-	May	1	0:00	1:00	D
-Rule	Taiwan	1945	1951	-	Oct	1	0:00	0	S
-Rule	Taiwan	1952	only	-	Mar	1	0:00	1:00	D
-Rule	Taiwan	1952	1954	-	Nov	1	0:00	0	S
-Rule	Taiwan	1953	1959	-	Apr	1	0:00	1:00	D
-Rule	Taiwan	1955	1961	-	Oct	1	0:00	0	S
-Rule	Taiwan	1960	1961	-	Jun	1	0:00	1:00	D
-Rule	Taiwan	1974	1975	-	Apr	1	0:00	1:00	D
-Rule	Taiwan	1974	1975	-	Oct	1	0:00	0	S
-Rule	Taiwan	1980	only	-	Jun	30	0:00	1:00	D
-Rule	Taiwan	1980	only	-	Sep	30	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Taipei	8:06:00 -	LMT	1896 # or Taibei or T'ai-pei
-			8:00	Taiwan	C%sT
-
-# Macau (Macao, Aomen)
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Macau	1961	1962	-	Mar	Sun>=16	3:30	1:00	S
-Rule	Macau	1961	1964	-	Nov	Sun>=1	3:30	0	-
-Rule	Macau	1963	only	-	Mar	Sun>=16	0:00	1:00	S
-Rule	Macau	1964	only	-	Mar	Sun>=16	3:30	1:00	S
-Rule	Macau	1965	only	-	Mar	Sun>=16	0:00	1:00	S
-Rule	Macau	1965	only	-	Oct	31	0:00	0	-
-Rule	Macau	1966	1971	-	Apr	Sun>=16	3:30	1:00	S
-Rule	Macau	1966	1971	-	Oct	Sun>=16	3:30	0	-
-Rule	Macau	1972	1974	-	Apr	Sun>=15	0:00	1:00	S
-Rule	Macau	1972	1973	-	Oct	Sun>=15	0:00	0	-
-Rule	Macau	1974	1977	-	Oct	Sun>=15	3:30	0	-
-Rule	Macau	1975	1977	-	Apr	Sun>=15	3:30	1:00	S
-Rule	Macau	1978	1980	-	Apr	Sun>=15	0:00	1:00	S
-Rule	Macau	1978	1980	-	Oct	Sun>=15	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Macau	7:34:20 -	LMT	1912
-			8:00	Macau	MO%sT	1999 Dec 20 # return to China
-			8:00	PRC	C%sT
-
-
-###############################################################################
-
-# Cyprus
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Cyprus	1975	only	-	Apr	13	0:00	1:00	S
-Rule	Cyprus	1975	only	-	Oct	12	0:00	0	-
-Rule	Cyprus	1976	only	-	May	15	0:00	1:00	S
-Rule	Cyprus	1976	only	-	Oct	11	0:00	0	-
-Rule	Cyprus	1977	1980	-	Apr	Sun>=1	0:00	1:00	S
-Rule	Cyprus	1977	only	-	Sep	25	0:00	0	-
-Rule	Cyprus	1978	only	-	Oct	2	0:00	0	-
-Rule	Cyprus	1979	1997	-	Sep	lastSun	0:00	0	-
-Rule	Cyprus	1981	1998	-	Mar	lastSun	0:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Nicosia	2:13:28 -	LMT	1921 Nov 14
-			2:00	Cyprus	EE%sT	1998 Sep
-			2:00	EUAsia	EE%sT
-# IATA SSIM (1998-09) has Cyprus using EU rules for the first time.
-
-# Classically, Cyprus belongs to Asia; e.g. see Herodotus, Histories, I.72.
-# However, for various reasons many users expect to find it under Europe.
-Link	Asia/Nicosia	Europe/Nicosia
-
-# Georgia
-# From Paul Eggert (1994-11-19):
-# Today's _Economist_ (p 60) reports that Georgia moved its clocks forward
-# an hour recently, due to a law proposed by Zurab Murvanidze,
-# an MP who went on a hunger strike for 11 days to force discussion about it!
-# We have no details, but we'll guess they didn't move the clocks back in fall.
-#
-# From Mathew Englander, quoting AP (1996-10-23 13:05-04):
-# Instead of putting back clocks at the end of October, Georgia
-# will stay on daylight savings time this winter to save energy,
-# President Eduard Shevardnadze decreed Wednesday.
-#
-# From the BBC via Joseph S. Myers (2004-06-27):
-#
-# Georgia moved closer to Western Europe on Sunday...  The former Soviet
-# republic has changed its time zone back to that of Moscow.  As a result it
-# is now just four hours ahead of Greenwich Mean Time, rather than five hours
-# ahead.  The switch was decreed by the pro-Western president of Georgia,
-# Mikhail Saakashvili, who said the change was partly prompted by the process
-# of integration into Europe.
-
-# From Teimuraz Abashidze (2005-11-07):
-# Government of Georgia ... decided to NOT CHANGE daylight savings time on
-# [Oct.] 30, as it was done before during last more than 10 years.
-# Currently, we are in fact GMT +4:00, as before 30 October it was GMT
-# +3:00.... The problem is, there is NO FORMAL LAW or governmental document
-# about it.  As far as I can find, I was told, that there is no document,
-# because we just DIDN'T ISSUE document about switching to winter time....
-# I don't know what can be done, especially knowing that some years ago our
-# DST rules where changed THREE TIMES during one month.
-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Tbilisi	2:59:16 -	LMT	1880
-			2:59:16	-	TBMT	1924 May  2 # Tbilisi Mean Time
-			3:00	-	TBIT	1957 Mar    # Tbilisi Time
-			4:00 RussiaAsia TBI%sT	1991 Mar 31 2:00s
-			3:00	1:00	TBIST	1991 Apr  9 # independence
-			3:00 RussiaAsia GE%sT	1992 # Georgia Time
-			3:00 E-EurAsia	GE%sT	1994 Sep lastSun
-			4:00 E-EurAsia	GE%sT	1996 Oct lastSun
-			4:00	1:00	GEST	1997 Mar lastSun
-			4:00 E-EurAsia	GE%sT	2004 Jun 27
-			3:00 RussiaAsia	GE%sT	2005 Mar lastSun 2:00
-			4:00	-	GET
-
-# East Timor
-
-# See Indonesia for the 1945 transition.
-
-# From Joao Carrascalao, brother of the former governor of East Timor, in
-# <a href="http://etan.org/et99c/december/26-31/30ETMAY.htm">
-# East Timor may be late for its millennium
-# </a> (1999-12-26/31):
-# Portugal tried to change the time forward in 1974 because the sun
-# rises too early but the suggestion raised a lot of problems with the
-# Timorese and I still don't think it would work today because it
-# conflicts with their way of life.
-
-# From Paul Eggert (2000-12-04):
-# We don't have any record of the above attempt.
-# Most likely our records are incomplete, but we have no better data.
-
-# <a href="http://www.hri.org/news/world/undh/last/00-08-16.undh.html">
-# From Manoel de Almeida e Silva, Deputy Spokesman for the UN Secretary-General
-# (2000-08-16)</a>:
-# The Cabinet of the East Timor Transition Administration decided
-# today to advance East Timor's time by one hour.  The time change,
-# which will be permanent, with no seasonal adjustment, will happen at
-# midnight on Saturday, September 16.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Dili	8:22:20 -	LMT	1912
-			8:00	-	TLT	1942 Feb 21 23:00 # E Timor Time
-			9:00	-	JST	1945 Sep 23
-			9:00	-	TLT	1976 May  3
-			8:00	-	CIT	2000 Sep 17 00:00
-			9:00	-	TLT
-
-# India
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Kolkata	5:53:28 -	LMT	1880	# Kolkata
-			5:53:20	-	HMT	1941 Oct    # Howrah Mean Time?
-			6:30	-	BURT	1942 May 15 # Burma Time
-			5:30	-	IST	1942 Sep
-			5:30	1:00	IST	1945 Oct 15
-			5:30	-	IST
-# The following are like Asia/Kolkata:
-#	Andaman Is
-#	Lakshadweep (Laccadive, Minicoy and Amindivi Is)
-#	Nicobar Is
-
-# Indonesia
-#
-# From Gwillim Law (2001-05-28), overriding Shanks & Pottenger:
-# <http://www.sumatera-inc.com/go_to_invest/about_indonesia.asp#standtime>
-# says that Indonesia's time zones changed on 1988-01-01.  Looking at some
-# time zone maps, I think that must refer to Western Borneo (Kalimantan Barat
-# and Kalimantan Tengah) switching from UTC+8 to UTC+7.
-#
-# From Paul Eggert (2007-03-10):
-# Here is another correction to Shanks & Pottenger.
-# JohnTWB writes that Japanese forces did not surrender control in
-# Indonesia until 1945-09-01 00:00 at the earliest (in Jakarta) and
-# other formal surrender ceremonies were September 9, 11, and 13, plus
-# September 12 for the regional surrender to Mountbatten in Singapore.
-# These would be the earliest possible times for a change.
-# Regimes horaires pour le monde entier, by Henri Le Corre, (Editions
-# Traditionnelles, 1987, Paris) says that Java and Madura switched
-# from JST to UTC+07:30 on 1945-09-23, and gives 1944-09-01 for Jayapura
-# (Hollandia).  For now, assume all Indonesian locations other than Jayapura
-# switched on 1945-09-23.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Asia/Jakarta	7:07:12 -	LMT	1867 Aug 10
-# Shanks & Pottenger say the next transition was at 1924 Jan 1 0:13,
-# but this must be a typo.
-			7:07:12	-	JMT	1923 Dec 31 23:47:12 # Jakarta
-			7:20	-	JAVT	1932 Nov	 # Java Time
-			7:30	-	WIT	1942 Mar 23
-			9:00	-	JST	1945 Sep 23
-			7:30	-	WIT	1948 May
-			8:00	-	WIT	1950 May
-			7:30	-	WIT	1964
-			7:00	-	WIT
-Zone Asia/Pontianak	7:17:20	-	LMT	1908 May
-			7:17:20	-	PMT	1932 Nov    # Pontianak MT
-			7:30	-	WIT	1942 Jan 29
-			9:00	-	JST	1945 Sep 23
-			7:30	-	WIT	1948 May
-			8:00	-	WIT	1950 May
-			7:30	-	WIT	1964
-			8:00	-	CIT	1988 Jan  1
-			7:00	-	WIT
-Zone Asia/Makassar	7:57:36 -	LMT	1920
-			7:57:36	-	MMT	1932 Nov    # Macassar MT
-			8:00	-	CIT	1942 Feb  9
-			9:00	-	JST	1945 Sep 23
-			8:00	-	CIT
-Zone Asia/Jayapura	9:22:48 -	LMT	1932 Nov
-			9:00	-	EIT	1944 Sep  1
-			9:30	-	CST	1964
-			9:00	-	EIT
-
-# Iran
-
-# From Roozbeh Pournader (2003-03-15):
-# This is an English translation of what I just found (originally in Persian).
-# The Gregorian dates in brackets are mine:
-#
-#	Official Newspaper No. 13548-1370/6/25 [1991-09-16]
-#	No. 16760/T233 H				1370/6/10 [1991-09-01]
-#
-#	The Rule About Change of the Official Time of the Country
-#
-#	The Board of Ministers, in the meeting dated 1370/5/23 [1991-08-14],
-#	based on the suggestion number 2221/D dated 1370/4/22 [1991-07-13]
-#	of the Country's Organization for Official and Employment Affairs,
-#	and referring to the law for equating the working hours of workers
-#	and officers in the whole country dated 1359/4/23 [1980-07-14], and
-#	for synchronizing the official times of the country, agreed that:
-#
-#	The official time of the country will should move forward one hour
-#	at the 24[:00] hours of the first day of Farvardin and should return
-#	to its previous state at the 24[:00] hours of the 30th day of
-#	Shahrivar.
-#
-#	First Deputy to the President - Hassan Habibi
-#
-# From personal experience, that agrees with what has been followed
-# for at least the last 5 years.  Before that, for a few years, the
-# date used was the first Thursday night of Farvardin and the last
-# Thursday night of Shahrivar, but I can't give exact dates....
-# I have also changed the abbreviations to what is considered correct
-# here in Iran, IRST for regular time and IRDT for daylight saving time.
-#
-# From Roozbeh Pournader (2005-04-05):
-# The text of the Iranian law, in effect since 1925, clearly mentions
-# that the true solar year is the measure, and there is no arithmetic
-# leap year calculation involved.  There has never been any serious
-# plan to change that law....
-#
-# From Paul Eggert (2006-03-22):
-# Go with Shanks & Pottenger before Sept. 1991, and with Pournader thereafter.
-# I used Ed Reingold's cal-persia in GNU Emacs 21.2 to check Persian dates,
-# stopping after 2037 when 32-bit time_t's overflow.
-# That cal-persia used Birashk's approximation, which disagrees with the solar
-# calendar predictions for the year 2025, so I corrected those dates by hand.
-#
-# From Oscar van Vlijmen (2005-03-30), writing about future
-# discrepancies between cal-persia and the Iranian calendar:
-# For 2091 solar-longitude-after yields 2091-03-20 08:40:07.7 UT for
-# the vernal equinox and that gets so close to 12:00 some local
-# Iranian time that the definition of the correct location needs to be
-# known exactly, amongst other factors.  2157 is even closer:
-# 2157-03-20 08:37:15.5 UT.  But the Gregorian year 2025 should give
-# no interpretation problem whatsoever.  By the way, another instant
-# in the near future where there will be a discrepancy between
-# arithmetical and astronomical Iranian calendars will be in 2058:
-# vernal equinox on 2058-03-20 09:03:05.9 UT.  The Java version of
-# Reingold's/Dershowitz' calculator gives correctly the Gregorian date
-# 2058-03-21 for 1 Farvardin 1437 (astronomical).
-#
-# From Steffen Thorsen (2006-03-22):
-# Several of my users have reported that Iran will not observe DST anymore:
-# http://www.irna.ir/en/news/view/line-17/0603193812164948.htm
-#
-# From Reuters (2007-09-16), with a heads-up from Jesper Norgaard Welen:
-# ... the Guardian Council ... approved a law on Sunday to re-introduce
-# daylight saving time ...
-# http://uk.reuters.com/article/oilRpt/idUKBLA65048420070916
-#
-# From Roozbeh Pournader (2007-11-05):
-# This is quoted from Official Gazette of the Islamic Republic of
-# Iran, Volume 63, Number 18242, dated Tuesday 1386/6/24
-# [2007-10-16]. I am doing the best translation I can:...
-# The official time of the country will be moved forward for one hour
-# on the 24 hours of the first day of the month of Farvardin and will
-# be changed back to its previous state on the 24 hours of the
-# thirtieth day of Shahrivar.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Iran	1978	1980	-	Mar	21	0:00	1:00	D
-Rule	Iran	1978	only	-	Oct	21	0:00	0	S
-Rule	Iran	1979	only	-	Sep	19	0:00	0	S
-Rule	Iran	1980	only	-	Sep	23	0:00	0	S
-Rule	Iran	1991	only	-	May	 3	0:00	1:00	D
-Rule	Iran	1992	1995	-	Mar	22	0:00	1:00	D
-Rule	Iran	1991	1995	-	Sep	22	0:00	0	S
-Rule	Iran	1996	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	1996	only	-	Sep	21	0:00	0	S
-Rule	Iran	1997	1999	-	Mar	22	0:00	1:00	D
-Rule	Iran	1997	1999	-	Sep	22	0:00	0	S
-Rule	Iran	2000	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2000	only	-	Sep	21	0:00	0	S
-Rule	Iran	2001	2003	-	Mar	22	0:00	1:00	D
-Rule	Iran	2001	2003	-	Sep	22	0:00	0	S
-Rule	Iran	2004	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2004	only	-	Sep	21	0:00	0	S
-Rule	Iran	2005	only	-	Mar	22	0:00	1:00	D
-Rule	Iran	2005	only	-	Sep	22	0:00	0	S
-Rule	Iran	2008	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2008	only	-	Sep	21	0:00	0	S
-Rule	Iran	2009	2011	-	Mar	22	0:00	1:00	D
-Rule	Iran	2009	2011	-	Sep	22	0:00	0	S
-Rule	Iran	2012	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2012	only	-	Sep	21	0:00	0	S
-Rule	Iran	2013	2015	-	Mar	22	0:00	1:00	D
-Rule	Iran	2013	2015	-	Sep	22	0:00	0	S
-Rule	Iran	2016	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2016	only	-	Sep	21	0:00	0	S
-Rule	Iran	2017	2019	-	Mar	22	0:00	1:00	D
-Rule	Iran	2017	2019	-	Sep	22	0:00	0	S
-Rule	Iran	2020	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2020	only	-	Sep	21	0:00	0	S
-Rule	Iran	2021	2023	-	Mar	22	0:00	1:00	D
-Rule	Iran	2021	2023	-	Sep	22	0:00	0	S
-Rule	Iran	2024	only	-	Mar	21	0:00	1:00	D
-Rule	Iran	2024	only	-	Sep	21	0:00	0	S
-Rule	Iran	2025	2027	-	Mar	22	0:00	1:00	D
-Rule	Iran	2025	2027	-	Sep	22	0:00	0	S
-Rule	Iran	2028	2029	-	Mar	21	0:00	1:00	D
-Rule	Iran	2028	2029	-	Sep	21	0:00	0	S
-Rule	Iran	2030	2031	-	Mar	22	0:00	1:00	D
-Rule	Iran	2030	2031	-	Sep	22	0:00	0	S
-Rule	Iran	2032	2033	-	Mar	21	0:00	1:00	D
-Rule	Iran	2032	2033	-	Sep	21	0:00	0	S
-Rule	Iran	2034	2035	-	Mar	22	0:00	1:00	D
-Rule	Iran	2034	2035	-	Sep	22	0:00	0	S
-Rule	Iran	2036	2037	-	Mar	21	0:00	1:00	D
-Rule	Iran	2036	2037	-	Sep	21	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Tehran	3:25:44	-	LMT	1916
-			3:25:44	-	TMT	1946	# Tehran Mean Time
-			3:30	-	IRST	1977 Nov
-			4:00	Iran	IR%sT	1979
-			3:30	Iran	IR%sT
-
-
-# Iraq
-#
-# From Jonathan Lennox (2000-06-12):
-# An article in this week's Economist ("Inside the Saddam-free zone", p. 50 in
-# the U.S. edition) on the Iraqi Kurds contains a paragraph:
-# "The three northern provinces ... switched their clocks this spring and
-# are an hour ahead of Baghdad."
-#
-# But Rives McDow (2000-06-18) quotes a contact in Iraqi-Kurdistan as follows:
-# In the past, some Kurdish nationalists, as a protest to the Iraqi
-# Government, did not adhere to daylight saving time.  They referred
-# to daylight saving as Saddam time.  But, as of today, the time zone
-# in Iraqi-Kurdistan is on standard time with Baghdad, Iraq.
-#
-# So we'll ignore the Economist's claim.
-
-# From Steffen Thorsen (2008-03-10):
-# The cabinet in Iraq abolished DST last week, according to the following
-# news sources (in Arabic):
-# <a href="http://www.aljeeran.net/wesima_articles/news-20080305-98602.html">
-# http://www.aljeeran.net/wesima_articles/news-20080305-98602.html
-# </a>
-# <a href="http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10">
-# http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10
-# </a>
-#
-# We have published a short article in English about the change:
-# <a href="http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html">
-# http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html
-# </a>
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Iraq	1982	only	-	May	1	0:00	1:00	D
-Rule	Iraq	1982	1984	-	Oct	1	0:00	0	S
-Rule	Iraq	1983	only	-	Mar	31	0:00	1:00	D
-Rule	Iraq	1984	1985	-	Apr	1	0:00	1:00	D
-Rule	Iraq	1985	1990	-	Sep	lastSun	1:00s	0	S
-Rule	Iraq	1986	1990	-	Mar	lastSun	1:00s	1:00	D
-# IATA SSIM (1991/1996) says Apr 1 12:01am UTC; guess the `:01' is a typo.
-# Shanks & Pottenger say Iraq did not observe DST 1992/1997; ignore this.
-#
-Rule	Iraq	1991	2007	-	Apr	 1	3:00s	1:00	D
-Rule	Iraq	1991	2007	-	Oct	 1	3:00s	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Baghdad	2:57:40	-	LMT	1890
-			2:57:36	-	BMT	1918	    # Baghdad Mean Time?
-			3:00	-	AST	1982 May
-			3:00	Iraq	A%sT
-
-
-###############################################################################
-
-# Israel
-
-# From Ephraim Silverberg (2001-01-11):
-#
-# I coined "IST/IDT" circa 1988.  Until then there were three
-# different abbreviations in use:
-#
-# JST  Jerusalem Standard Time [Danny Braniss, Hebrew University]
-# IZT  Israel Zonal (sic) Time [Prof. Haim Papo, Technion]
-# EEST Eastern Europe Standard Time [used by almost everyone else]
-#
-# Since timezones should be called by country and not capital cities,
-# I ruled out JST.  As Israel is in Asia Minor and not Eastern Europe,
-# EEST was equally unacceptable.  Since "zonal" was not compatible with
-# any other timezone abbreviation, I felt that 'IST' was the way to go
-# and, indeed, it has received almost universal acceptance in timezone
-# settings in Israeli computers.
-#
-# In any case, I am happy to share timezone abbreviations with India,
-# high on my favorite-country list (and not only because my wife's
-# family is from India).
-
-# From Shanks & Pottenger:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Zion	1940	only	-	Jun	 1	0:00	1:00	D
-Rule	Zion	1942	1944	-	Nov	 1	0:00	0	S
-Rule	Zion	1943	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	1944	only	-	Apr	 1	0:00	1:00	D
-Rule	Zion	1945	only	-	Apr	16	0:00	1:00	D
-Rule	Zion	1945	only	-	Nov	 1	2:00	0	S
-Rule	Zion	1946	only	-	Apr	16	2:00	1:00	D
-Rule	Zion	1946	only	-	Nov	 1	0:00	0	S
-Rule	Zion	1948	only	-	May	23	0:00	2:00	DD
-Rule	Zion	1948	only	-	Sep	 1	0:00	1:00	D
-Rule	Zion	1948	1949	-	Nov	 1	2:00	0	S
-Rule	Zion	1949	only	-	May	 1	0:00	1:00	D
-Rule	Zion	1950	only	-	Apr	16	0:00	1:00	D
-Rule	Zion	1950	only	-	Sep	15	3:00	0	S
-Rule	Zion	1951	only	-	Apr	 1	0:00	1:00	D
-Rule	Zion	1951	only	-	Nov	11	3:00	0	S
-Rule	Zion	1952	only	-	Apr	20	2:00	1:00	D
-Rule	Zion	1952	only	-	Oct	19	3:00	0	S
-Rule	Zion	1953	only	-	Apr	12	2:00	1:00	D
-Rule	Zion	1953	only	-	Sep	13	3:00	0	S
-Rule	Zion	1954	only	-	Jun	13	0:00	1:00	D
-Rule	Zion	1954	only	-	Sep	12	0:00	0	S
-Rule	Zion	1955	only	-	Jun	11	2:00	1:00	D
-Rule	Zion	1955	only	-	Sep	11	0:00	0	S
-Rule	Zion	1956	only	-	Jun	 3	0:00	1:00	D
-Rule	Zion	1956	only	-	Sep	30	3:00	0	S
-Rule	Zion	1957	only	-	Apr	29	2:00	1:00	D
-Rule	Zion	1957	only	-	Sep	22	0:00	0	S
-Rule	Zion	1974	only	-	Jul	 7	0:00	1:00	D
-Rule	Zion	1974	only	-	Oct	13	0:00	0	S
-Rule	Zion	1975	only	-	Apr	20	0:00	1:00	D
-Rule	Zion	1975	only	-	Aug	31	0:00	0	S
-Rule	Zion	1985	only	-	Apr	14	0:00	1:00	D
-Rule	Zion	1985	only	-	Sep	15	0:00	0	S
-Rule	Zion	1986	only	-	May	18	0:00	1:00	D
-Rule	Zion	1986	only	-	Sep	 7	0:00	0	S
-Rule	Zion	1987	only	-	Apr	15	0:00	1:00	D
-Rule	Zion	1987	only	-	Sep	13	0:00	0	S
-Rule	Zion	1988	only	-	Apr	 9	0:00	1:00	D
-Rule	Zion	1988	only	-	Sep	 3	0:00	0	S
-
-# From Ephraim Silverberg
-# (1997-03-04, 1998-03-16, 1998-12-28, 2000-01-17, 2000-07-25, 2004-12-22,
-# and 2005-02-17):
-
-# According to the Office of the Secretary General of the Ministry of
-# Interior, there is NO set rule for Daylight-Savings/Standard time changes.
-# One thing is entrenched in law, however: that there must be at least 150
-# days of daylight savings time annually.  From 1993-1998, the change to
-# daylight savings time was on a Friday morning from midnight IST to
-# 1 a.m IDT; up until 1998, the change back to standard time was on a
-# Saturday night from midnight daylight savings time to 11 p.m. standard
-# time.  1996 is an exception to this rule where the change back to standard
-# time took place on Sunday night instead of Saturday night to avoid
-# conflicts with the Jewish New Year.  In 1999, the change to
-# daylight savings time was still on a Friday morning but from
-# 2 a.m. IST to 3 a.m. IDT; furthermore, the change back to standard time
-# was also on a Friday morning from 2 a.m. IDT to 1 a.m. IST for
-# 1999 only.  In the year 2000, the change to daylight savings time was
-# similar to 1999, but although the change back will be on a Friday, it
-# will take place from 1 a.m. IDT to midnight IST.  Starting in 2001, all
-# changes to/from will take place at 1 a.m. old time, but now there is no
-# rule as to what day of the week it will take place in as the start date
-# (except in 2003) is the night after the Passover Seder (i.e. the eve
-# of the 16th of Nisan in the lunar Hebrew calendar) and the end date
-# (except in 2002) is three nights before Yom Kippur [Day of Atonement]
-# (the eve of the 7th of Tishrei in the lunar Hebrew calendar).
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Zion	1989	only	-	Apr	30	0:00	1:00	D
-Rule	Zion	1989	only	-	Sep	 3	0:00	0	S
-Rule	Zion	1990	only	-	Mar	25	0:00	1:00	D
-Rule	Zion	1990	only	-	Aug	26	0:00	0	S
-Rule	Zion	1991	only	-	Mar	24	0:00	1:00	D
-Rule	Zion	1991	only	-	Sep	 1	0:00	0	S
-Rule	Zion	1992	only	-	Mar	29	0:00	1:00	D
-Rule	Zion	1992	only	-	Sep	 6	0:00	0	S
-Rule	Zion	1993	only	-	Apr	 2	0:00	1:00	D
-Rule	Zion	1993	only	-	Sep	 5	0:00	0	S
-
-# The dates for 1994-1995 were obtained from Office of the Spokeswoman for the
-# Ministry of Interior, Jerusalem, Israel.  The spokeswoman can be reached by
-# calling the office directly at 972-2-6701447 or 972-2-6701448.
-
-# Rule	NAME    FROM    TO      TYPE    IN      ON      AT      SAVE    LETTER/S
-Rule	Zion	1994	only	-	Apr	 1	0:00	1:00	D
-Rule	Zion	1994	only	-	Aug	28	0:00	0	S
-Rule	Zion	1995	only	-	Mar	31	0:00	1:00	D
-Rule	Zion	1995	only	-	Sep	 3	0:00	0	S
-
-# The dates for 1996 were determined by the Minister of Interior of the
-# time, Haim Ramon.  The official announcement regarding 1996-1998
-# (with the dates for 1997-1998 no longer being relevant) can be viewed at:
-#
-#   ftp://ftp.cs.huji.ac.il/pub/tz/announcements/1996-1998.ramon.ps.gz
-#
-# The dates for 1997-1998 were altered by his successor, Rabbi Eli Suissa.
-#
-# The official announcements for the years 1997-1999 can be viewed at:
-#
-#   ftp://ftp.cs.huji.ac.il/pub/tz/announcements/YYYY.ps.gz
-#
-#       where YYYY is the relevant year.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Zion	1996	only	-	Mar	15	0:00	1:00	D
-Rule	Zion	1996	only	-	Sep	16	0:00	0	S
-Rule	Zion	1997	only	-	Mar	21	0:00	1:00	D
-Rule	Zion	1997	only	-	Sep	14	0:00	0	S
-Rule	Zion	1998	only	-	Mar	20	0:00	1:00	D
-Rule	Zion	1998	only	-	Sep	 6	0:00	0	S
-Rule	Zion	1999	only	-	Apr	 2	2:00	1:00	D
-Rule	Zion	1999	only	-	Sep	 3	2:00	0	S
-
-# The Knesset Interior Committee has changed the dates for 2000 for
-# the third time in just over a year and have set new dates for the
-# years 2001-2004 as well.
-#
-# The official announcement for the start date of 2000 can be viewed at:
-#
-#	ftp://ftp.cs.huji.ac.il/pub/tz/announcements/2000-start.ps.gz
-#
-# The official announcement for the end date of 2000 and the dates
-# for the years 2001-2004 can be viewed at:
-#
-#	ftp://ftp.cs.huji.ac.il/pub/tz/announcements/2000-2004.ps.gz
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Zion	2000	only	-	Apr	14	2:00	1:00	D
-Rule	Zion	2000	only	-	Oct	 6	1:00	0	S
-Rule	Zion	2001	only	-	Apr	 9	1:00	1:00	D
-Rule	Zion	2001	only	-	Sep	24	1:00	0	S
-Rule	Zion	2002	only	-	Mar	29	1:00	1:00	D
-Rule	Zion	2002	only	-	Oct	 7	1:00	0	S
-Rule	Zion	2003	only	-	Mar	28	1:00	1:00	D
-Rule	Zion	2003	only	-	Oct	 3	1:00	0	S
-Rule	Zion	2004	only	-	Apr	 7	1:00	1:00	D
-Rule	Zion	2004	only	-	Sep	22	1:00	0	S
-
-# The proposed law agreed upon by the Knesset Interior Committee on
-# 2005-02-14 is that, for 2005 and beyond, DST starts at 02:00 the
-# last Friday before April 2nd (i.e. the last Friday in March or April
-# 1st itself if it falls on a Friday) and ends at 02:00 on the Saturday
-# night _before_ the fast of Yom Kippur.
-#
-# Those who can read Hebrew can view the announcement at:
-#
-#	ftp://ftp.cs.huji.ac.il/pub/tz/announcements/2005+beyond.ps
-
-# From Paul Eggert (2005-02-22):
-# I used Ephraim Silverberg's dst-israel.el program
-# <ftp://ftp.cs.huji.ac.il/pub/tz/software/dst-israel.el> (2005-02-20)
-# along with Ed Reingold's cal-hebrew in GNU Emacs 21.4,
-# to generate the transitions in this list.
-# (I replaced "lastFri" with "Fri>=26" by hand.)
-# The spring transitions below all correspond to the following Rule:
-#
-# Rule	Zion	2005	max	-	Mar	Fri>=26	2:00	1:00	D
-#
-# but older zic implementations (e.g., Solaris 8) do not support
-# "Fri>=26" to mean April 1 in years like 2005, so for now we list the
-# springtime transitions explicitly.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Zion	2005	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	2005	only	-	Oct	 9	2:00	0	S
-Rule	Zion	2006	2010	-	Mar	Fri>=26	2:00	1:00	D
-Rule	Zion	2006	only	-	Oct	 1	2:00	0	S
-Rule	Zion	2007	only	-	Sep	16	2:00	0	S
-Rule	Zion	2008	only	-	Oct	 5	2:00	0	S
-Rule	Zion	2009	only	-	Sep	27	2:00	0	S
-Rule	Zion	2010	only	-	Sep	12	2:00	0	S
-Rule	Zion	2011	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	2011	only	-	Oct	 2	2:00	0	S
-Rule	Zion	2012	2015	-	Mar	Fri>=26	2:00	1:00	D
-Rule	Zion	2012	only	-	Sep	23	2:00	0	S
-Rule	Zion	2013	only	-	Sep	 8	2:00	0	S
-Rule	Zion	2014	only	-	Sep	28	2:00	0	S
-Rule	Zion	2015	only	-	Sep	20	2:00	0	S
-Rule	Zion	2016	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	2016	only	-	Oct	 9	2:00	0	S
-Rule	Zion	2017	2021	-	Mar	Fri>=26	2:00	1:00	D
-Rule	Zion	2017	only	-	Sep	24	2:00	0	S
-Rule	Zion	2018	only	-	Sep	16	2:00	0	S
-Rule	Zion	2019	only	-	Oct	 6	2:00	0	S
-Rule	Zion	2020	only	-	Sep	27	2:00	0	S
-Rule	Zion	2021	only	-	Sep	12	2:00	0	S
-Rule	Zion	2022	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	2022	only	-	Oct	 2	2:00	0	S
-Rule	Zion	2023	2032	-	Mar	Fri>=26	2:00	1:00	D
-Rule	Zion	2023	only	-	Sep	24	2:00	0	S
-Rule	Zion	2024	only	-	Oct	 6	2:00	0	S
-Rule	Zion	2025	only	-	Sep	28	2:00	0	S
-Rule	Zion	2026	only	-	Sep	20	2:00	0	S
-Rule	Zion	2027	only	-	Oct	10	2:00	0	S
-Rule	Zion	2028	only	-	Sep	24	2:00	0	S
-Rule	Zion	2029	only	-	Sep	16	2:00	0	S
-Rule	Zion	2030	only	-	Oct	 6	2:00	0	S
-Rule	Zion	2031	only	-	Sep	21	2:00	0	S
-Rule	Zion	2032	only	-	Sep	12	2:00	0	S
-Rule	Zion	2033	only	-	Apr	 1	2:00	1:00	D
-Rule	Zion	2033	only	-	Oct	 2	2:00	0	S
-Rule	Zion	2034	2037	-	Mar	Fri>=26	2:00	1:00	D
-Rule	Zion	2034	only	-	Sep	17	2:00	0	S
-Rule	Zion	2035	only	-	Oct	 7	2:00	0	S
-Rule	Zion	2036	only	-	Sep	28	2:00	0	S
-Rule	Zion	2037	only	-	Sep	13	2:00	0	S
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Jerusalem	2:20:56 -	LMT	1880
-			2:20:40	-	JMT	1918	# Jerusalem Mean Time?
-			2:00	Zion	I%sT
-
-
-
-###############################################################################
-
-# Japan
-
-# `9:00' and `JST' is from Guy Harris.
-
-# From Paul Eggert (1995-03-06):
-# Today's _Asahi Evening News_ (page 4) reports that Japan had
-# daylight saving between 1948 and 1951, but ``the system was discontinued
-# because the public believed it would lead to longer working hours.''
-
-# From Mayumi Negishi in the 2005-08-10 Japan Times
-# <http://www.japantimes.co.jp/cgi-bin/getarticle.pl5?nn20050810f2.htm>:
-# Occupation authorities imposed daylight-saving time on Japan on
-# [1948-05-01]....  But lack of prior debate and the execution of
-# daylight-saving time just three days after the bill was passed generated
-# deep hatred of the concept....  The Diet unceremoniously passed a bill to
-# dump the unpopular system in October 1951, less than a month after the San
-# Francisco Peace Treaty was signed.  (A government poll in 1951 showed 53%
-# of the Japanese wanted to scrap daylight-saving time, as opposed to 30% who
-# wanted to keep it.)
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that DST in Japan during those years was as follows:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Japan	1948	only	-	May	Sun>=1	2:00	1:00	D
-Rule	Japan	1948	1951	-	Sep	Sat>=8	2:00	0	S
-Rule	Japan	1949	only	-	Apr	Sun>=1	2:00	1:00	D
-Rule	Japan	1950	1951	-	May	Sun>=1	2:00	1:00	D
-# but the only locations using it (for birth certificates, presumably, since
-# their audience is astrologers) were US military bases.  For now, assume
-# that for most purposes daylight-saving time was observed; otherwise, what
-# would have been the point of the 1951 poll?
-
-# From Hideyuki Suzuki (1998-11-09):
-# 'Tokyo' usually stands for the former location of Tokyo Astronomical
-# Observatory: E 139 44' 40".90 (9h 18m 58s.727), N 35 39' 16".0.
-# This data is from 'Rika Nenpyou (Chronological Scientific Tables) 1996'
-# edited by National Astronomical Observatory of Japan....
-# JST (Japan Standard Time) has been used since 1888-01-01 00:00 (JST).
-# The law is enacted on 1886-07-07.
-
-# From Hideyuki Suzuki (1998-11-16):
-# The ordinance No. 51 (1886) established "standard time" in Japan,
-# which stands for the time on E 135 degree.
-# In the ordinance No. 167 (1895), "standard time" was renamed to "central
-# standard time".  And the same ordinance also established "western standard
-# time", which stands for the time on E 120 degree....  But "western standard
-# time" was abolished in the ordinance No. 529 (1937).  In the ordinance No.
-# 167, there is no mention regarding for what place western standard time is
-# standard....
-#
-# I wrote "ordinance" above, but I don't know how to translate.
-# In Japanese it's "chokurei", which means ordinance from emperor.
-
-# Shanks & Pottenger claim JST in use since 1896, and that a few
-# places (e.g. Ishigaki) use +0800; go with Suzuki.  Guess that all
-# ordinances took effect on Jan 1.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Tokyo	9:18:59	-	LMT	1887 Dec 31 15:00u
-			9:00	-	JST	1896
-			9:00	-	CJT	1938
-			9:00	Japan	J%sT
-# Since 1938, all Japanese possessions have been like Asia/Tokyo.
-
-# Jordan
-#
-# From <a href="http://star.arabia.com/990701/JO9.html">
-# Jordan Week (1999-07-01) </a> via Steffen Thorsen (1999-09-09):
-# Clocks in Jordan were forwarded one hour on Wednesday at midnight,
-# in accordance with the government's decision to implement summer time
-# all year round.
-#
-# From <a href="http://star.arabia.com/990930/JO9.html">
-# Jordan Week (1999-09-30) </a> via Steffen Thorsen (1999-11-09):
-# Winter time starts today Thursday, 30 September. Clocks will be turned back
-# by one hour.  This is the latest government decision and it's final!
-# The decision was taken because of the increase in working hours in
-# government's departments from six to seven hours.
-#
-# From Paul Eggert (2005-11-22):
-# Starting 2003 transitions are from Steffen Thorsen's web site timeanddate.com.
-#
-# From Steffen Thorsen (2005-11-23):
-# For Jordan I have received multiple independent user reports every year
-# about DST end dates, as the end-rule is different every year.
-#
-# From Steffen Thorsen (2006-10-01), after a heads-up from Hilal Malawi:
-# http://www.petranews.gov.jo/nepras/2006/Sep/05/4000.htm
-# "Jordan will switch to winter time on Friday, October 27".
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Jordan	1973	only	-	Jun	6	0:00	1:00	S
-Rule	Jordan	1973	1975	-	Oct	1	0:00	0	-
-Rule	Jordan	1974	1977	-	May	1	0:00	1:00	S
-Rule	Jordan	1976	only	-	Nov	1	0:00	0	-
-Rule	Jordan	1977	only	-	Oct	1	0:00	0	-
-Rule	Jordan	1978	only	-	Apr	30	0:00	1:00	S
-Rule	Jordan	1978	only	-	Sep	30	0:00	0	-
-Rule	Jordan	1985	only	-	Apr	1	0:00	1:00	S
-Rule	Jordan	1985	only	-	Oct	1	0:00	0	-
-Rule	Jordan	1986	1988	-	Apr	Fri>=1	0:00	1:00	S
-Rule	Jordan	1986	1990	-	Oct	Fri>=1	0:00	0	-
-Rule	Jordan	1989	only	-	May	8	0:00	1:00	S
-Rule	Jordan	1990	only	-	Apr	27	0:00	1:00	S
-Rule	Jordan	1991	only	-	Apr	17	0:00	1:00	S
-Rule	Jordan	1991	only	-	Sep	27	0:00	0	-
-Rule	Jordan	1992	only	-	Apr	10	0:00	1:00	S
-Rule	Jordan	1992	1993	-	Oct	Fri>=1	0:00	0	-
-Rule	Jordan	1993	1998	-	Apr	Fri>=1	0:00	1:00	S
-Rule	Jordan	1994	only	-	Sep	Fri>=15	0:00	0	-
-Rule	Jordan	1995	1998	-	Sep	Fri>=15	0:00s	0	-
-Rule	Jordan	1999	only	-	Jul	 1	0:00s	1:00	S
-Rule	Jordan	1999	2002	-	Sep	lastThu	0:00s	0	-
-Rule	Jordan	2000	max	-	Mar	lastThu	0:00s	1:00	S
-Rule	Jordan	2003	only	-	Oct	24	0:00s	0	-
-Rule	Jordan	2004	only	-	Oct	15	0:00s	0	-
-Rule	Jordan	2005	only	-	Sep	lastFri	0:00s	0	-
-Rule	Jordan	2006	max	-	Oct	lastFri	0:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Amman	2:23:44 -	LMT	1931
-			2:00	Jordan	EE%sT
-
-
-# Kazakhstan
-
-# From Paul Eggert (1996-11-22):
-# Andrew Evtichov (1996-04-13) writes that Kazakhstan
-# stayed in sync with Moscow after 1990, and that Aqtobe (formerly Aktyubinsk)
-# and Aqtau (formerly Shevchenko) are the largest cities in their zones.
-# Guess that Aqtau and Aqtobe diverged in 1995, since that's the first time
-# IATA SSIM mentions a third time zone in Kazakhstan.
-
-# From Paul Eggert (2006-03-22):
-# German Iofis, ELSI, Almaty (2001-10-09) reports that Kazakhstan uses
-# RussiaAsia rules, instead of switching at 00:00 as the IATA has it.
-# Go with Shanks & Pottenger, who have them always using RussiaAsia rules.
-# Also go with the following claims of Shanks & Pottenger:
-#
-# - Kazakhstan did not observe DST in 1991.
-# - Qyzylorda switched from +5:00 to +6:00 on 1992-01-19 02:00.
-# - Oral switched from +5:00 to +4:00 in spring 1989.
-
-# <a href="http://www.kazsociety.org.uk/news/2005/03/30.htm">
-# From Kazakhstan Embassy's News Bulletin #11 (2005-03-21):
-# </a>
-# The Government of Kazakhstan passed a resolution March 15 abolishing
-# daylight saving time citing lack of economic benefits and health
-# complications coupled with a decrease in productivity.
-#
-# From Branislav Kojic (in Astana) via Gwillim Law (2005-06-28):
-# ... what happened was that the former Kazakhstan Eastern time zone
-# was "blended" with the Central zone.  Therefore, Kazakhstan now has
-# two time zones, and difference between them is one hour.  The zone
-# closer to UTC is the former Western zone (probably still called the
-# same), encompassing four provinces in the west: Aqtobe, Atyrau,
-# Mangghystau, and West Kazakhstan.  The other zone encompasses
-# everything else....  I guess that would make Kazakhstan time zones
-# de jure UTC+5 and UTC+6 respectively.
-
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-#
-# Almaty (formerly Alma-Ata), representing most locations in Kazakhstan
-Zone	Asia/Almaty	5:07:48 -	LMT	1924 May  2 # or Alma-Ata
-			5:00	-	ALMT	1930 Jun 21 # Alma-Ata Time
-			6:00 RussiaAsia ALM%sT	1991
-			6:00	-	ALMT	1992
-			6:00 RussiaAsia	ALM%sT	2005 Mar 15
-			6:00	-	ALMT
-# Qyzylorda (aka Kyzylorda, Kizilorda, Kzyl-Orda, etc.)
-Zone	Asia/Qyzylorda	4:21:52 -	LMT	1924 May  2
-			4:00	-	KIZT	1930 Jun 21 # Kizilorda Time
-			5:00	-	KIZT	1981 Apr  1
-			5:00	1:00	KIZST	1981 Oct  1
-			6:00	-	KIZT	1982 Apr  1
-			5:00 RussiaAsia	KIZ%sT	1991
-			5:00	-	KIZT	1991 Dec 16 # independence
-			5:00	-	QYZT	1992 Jan 19 2:00
-			6:00 RussiaAsia	QYZ%sT	2005 Mar 15
-			6:00	-	QYZT
-# Aqtobe (aka Aktobe, formerly Akt'ubinsk)
-Zone	Asia/Aqtobe	3:48:40	-	LMT	1924 May  2
-			4:00	-	AKTT	1930 Jun 21 # Aktyubinsk Time
-			5:00	-	AKTT	1981 Apr  1
-			5:00	1:00	AKTST	1981 Oct  1
-			6:00	-	AKTT	1982 Apr  1
-			5:00 RussiaAsia	AKT%sT	1991
-			5:00	-	AKTT	1991 Dec 16 # independence
-			5:00 RussiaAsia	AQT%sT	2005 Mar 15 # Aqtobe Time
-			5:00	-	AQTT
-# Mangghystau
-# Aqtau was not founded until 1963, but it represents an inhabited region,
-# so include time stamps before 1963.
-Zone	Asia/Aqtau	3:21:04	-	LMT	1924 May  2
-			4:00	-	FORT	1930 Jun 21 # Fort Shevchenko T
-			5:00	-	FORT	1963
-			5:00	-	SHET	1981 Oct  1 # Shevchenko Time
-			6:00	-	SHET	1982 Apr  1
-			5:00 RussiaAsia	SHE%sT	1991
-			5:00	-	SHET	1991 Dec 16 # independence
-			5:00 RussiaAsia	AQT%sT	1995 Mar lastSun 2:00 # Aqtau Time
-			4:00 RussiaAsia	AQT%sT	2005 Mar 15
-			5:00	-	AQTT
-# West Kazakhstan
-Zone	Asia/Oral	3:25:24	-	LMT	1924 May  2 # or Ural'sk
-			4:00	-	URAT	1930 Jun 21 # Ural'sk time
-			5:00	-	URAT	1981 Apr  1
-			5:00	1:00	URAST	1981 Oct  1
-			6:00	-	URAT	1982 Apr  1
-			5:00 RussiaAsia	URA%sT	1989 Mar 26 2:00
-			4:00 RussiaAsia	URA%sT	1991
-			4:00	-	URAT	1991 Dec 16 # independence
-			4:00 RussiaAsia	ORA%sT	2005 Mar 15 # Oral Time
-			5:00	-	ORAT
-
-# Kyrgyzstan (Kirgizstan)
-# Transitions through 1991 are from Shanks & Pottenger.
-
-# From Paul Eggert (2005-08-15):
-# According to an article dated today in the Kyrgyzstan Development Gateway
-# <http://eng.gateway.kg/cgi-bin/page.pl?id=1&story_name=doc9979.shtml>
-# Kyrgyzstan is canceling the daylight saving time system.  I take the article
-# to mean that they will leave their clocks at 6 hours ahead of UTC.
-# From Malik Abdugaliev (2005-09-21):
-# Our government cancels daylight saving time 6th of August 2005.
-# From 2005-08-12 our GMT-offset is +6, w/o any daylight saving.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Kyrgyz	1992	1996	-	Apr	Sun>=7	0:00s	1:00	S
-Rule	Kyrgyz	1992	1996	-	Sep	lastSun	0:00	0	-
-Rule	Kyrgyz	1997	2005	-	Mar	lastSun	2:30	1:00	S
-Rule	Kyrgyz	1997	2004	-	Oct	lastSun	2:30	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Bishkek	4:58:24 -	LMT	1924 May  2
-			5:00	-	FRUT	1930 Jun 21 # Frunze Time
-			6:00 RussiaAsia FRU%sT	1991 Mar 31 2:00s
-			5:00	1:00	FRUST	1991 Aug 31 2:00 # independence
-			5:00	Kyrgyz	KG%sT	2005 Aug 12    # Kyrgyzstan Time
-			6:00	-	KGT
-
-###############################################################################
-
-# Korea (North and South)
-
-# From Annie I. Bang (2006-07-10) in
-# <http://www.koreaherald.co.kr/SITE/data/html_dir/2006/07/10/200607100012.asp>:
-# The Ministry of Commerce, Industry and Energy has already
-# commissioned a research project [to reintroduce DST] and has said
-# the system may begin as early as 2008....  Korea ran a daylight
-# saving program from 1949-61 but stopped it during the 1950-53 Korean War.
-
-# From Shanks & Pottenger:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	ROK	1960	only	-	May	15	0:00	1:00	D
-Rule	ROK	1960	only	-	Sep	13	0:00	0	S
-Rule	ROK	1987	1988	-	May	Sun>=8	0:00	1:00	D
-Rule	ROK	1987	1988	-	Oct	Sun>=8	0:00	0	S
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Seoul	8:27:52	-	LMT	1890
-			8:30	-	KST	1904 Dec
-			9:00	-	KST	1928
-			8:30	-	KST	1932
-			9:00	-	KST	1954 Mar 21
-			8:00	ROK	K%sT	1961 Aug 10
-			8:30	-	KST	1968 Oct
-			9:00	ROK	K%sT
-Zone	Asia/Pyongyang	8:23:00 -	LMT	1890
-			8:30	-	KST	1904 Dec
-			9:00	-	KST	1928
-			8:30	-	KST	1932
-			9:00	-	KST	1954 Mar 21
-			8:00	-	KST	1961 Aug 10
-			9:00	-	KST
-
-###############################################################################
-
-# Kuwait
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# From the Arab Times (2007-03-14):
-# The Civil Service Commission (CSC) has approved a proposal forwarded
-# by MP Ahmad Baqer on implementing the daylight saving time (DST) in
-# Kuwait starting from April until the end of Sept this year, reports Al-Anba.
-# <http://www.arabtimesonline.com/arabtimes/kuwait/Viewdet.asp?ID=9950>.
-# From Paul Eggert (2007-03-29):
-# We don't know the details, or whether the approval means it'll happen,
-# so for now we assume no DST.
-Zone	Asia/Kuwait	3:11:56 -	LMT	1950
-			3:00	-	AST
-
-# Laos
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Vientiane	6:50:24 -	LMT	1906 Jun  9 # or Viangchan
-			7:06:20	-	SMT	1911 Mar 11 0:01 # Saigon MT?
-			7:00	-	ICT	1912 May
-			8:00	-	ICT	1931 May
-			7:00	-	ICT
-
-# Lebanon
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Lebanon	1920	only	-	Mar	28	0:00	1:00	S
-Rule	Lebanon	1920	only	-	Oct	25	0:00	0	-
-Rule	Lebanon	1921	only	-	Apr	3	0:00	1:00	S
-Rule	Lebanon	1921	only	-	Oct	3	0:00	0	-
-Rule	Lebanon	1922	only	-	Mar	26	0:00	1:00	S
-Rule	Lebanon	1922	only	-	Oct	8	0:00	0	-
-Rule	Lebanon	1923	only	-	Apr	22	0:00	1:00	S
-Rule	Lebanon	1923	only	-	Sep	16	0:00	0	-
-Rule	Lebanon	1957	1961	-	May	1	0:00	1:00	S
-Rule	Lebanon	1957	1961	-	Oct	1	0:00	0	-
-Rule	Lebanon	1972	only	-	Jun	22	0:00	1:00	S
-Rule	Lebanon	1972	1977	-	Oct	1	0:00	0	-
-Rule	Lebanon	1973	1977	-	May	1	0:00	1:00	S
-Rule	Lebanon	1978	only	-	Apr	30	0:00	1:00	S
-Rule	Lebanon	1978	only	-	Sep	30	0:00	0	-
-Rule	Lebanon	1984	1987	-	May	1	0:00	1:00	S
-Rule	Lebanon	1984	1991	-	Oct	16	0:00	0	-
-Rule	Lebanon	1988	only	-	Jun	1	0:00	1:00	S
-Rule	Lebanon	1989	only	-	May	10	0:00	1:00	S
-Rule	Lebanon	1990	1992	-	May	1	0:00	1:00	S
-Rule	Lebanon	1992	only	-	Oct	4	0:00	0	-
-Rule	Lebanon	1993	max	-	Mar	lastSun	0:00	1:00	S
-Rule	Lebanon	1993	1998	-	Sep	lastSun	0:00	0	-
-Rule	Lebanon	1999	max	-	Oct	lastSun	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Beirut	2:22:00 -	LMT	1880
-			2:00	Lebanon	EE%sT
-
-# Malaysia
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	NBorneo	1935	1941	-	Sep	14	0:00	0:20	TS # one-Third Summer
-Rule	NBorneo	1935	1941	-	Dec	14	0:00	0	-
-#
-# peninsular Malaysia
-# The data here are taken from Mok Ly Yng (2003-10-30)
-# <http://www.math.nus.edu.sg/aslaksen/teaching/timezone.html>.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Asia/Kuala_Lumpur	6:46:46 -	LMT	1901 Jan  1
-			6:55:25	-	SMT	1905 Jun  1 # Singapore M.T.
-			7:00	-	MALT	1933 Jan  1 # Malaya Time
-			7:00	0:20	MALST	1936 Jan  1
-			7:20	-	MALT	1941 Sep  1
-			7:30	-	MALT	1942 Feb 16
-			9:00	-	JST	1945 Sep 12
-			7:30	-	MALT	1982 Jan  1
-			8:00	-	MYT	# Malaysia Time
-# Sabah & Sarawak
-# From Paul Eggert (2006-03-22):
-# The data here are mostly from Shanks & Pottenger, but the 1942, 1945 and 1982
-# transition dates are from Mok Ly Yng.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Asia/Kuching	7:21:20	-	LMT	1926 Mar
-			7:30	-	BORT	1933	# Borneo Time
-			8:00	NBorneo	BOR%sT	1942 Feb 16
-			9:00	-	JST	1945 Sep 12
-			8:00	-	BORT	1982 Jan  1
-			8:00	-	MYT
-
-# Maldives
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Maldives	4:54:00 -	LMT	1880	# Male
-			4:54:00	-	MMT	1960	# Male Mean Time
-			5:00	-	MVT		# Maldives Time
-
-# Mongolia
-
-# Shanks & Pottenger say that Mongolia has three time zones, but
-# usno1995 and the CIA map Standard Time Zones of the World (2005-03)
-# both say that it has just one.
-
-# From Oscar van Vlijmen (1999-12-11):
-# <a href="http://www.mongoliatourism.gov.mn/general.htm">
-# General Information Mongolia
-# </a> (1999-09)
-# "Time: Mongolia has two time zones. Three westernmost provinces of
-# Bayan-Ulgii, Uvs, and Hovd are one hour earlier than the capital city, and
-# the rest of the country follows the Ulaanbaatar time, which is UTC/GMT plus
-# eight hours."
-
-# From Rives McDow (1999-12-13):
-# Mongolia discontinued the use of daylight savings time in 1999; 1998
-# being the last year it was implemented.  The dates of implementation I am
-# unsure of, but most probably it was similar to Russia, except for the time
-# of implementation may have been different....
-# Some maps in the past have indicated that there was an additional time
-# zone in the eastern part of Mongolia, including the provinces of Dornod,
-# Suhbaatar, and possibly Khentij.
-
-# From Paul Eggert (1999-12-15):
-# Naming and spelling is tricky in Mongolia.
-# We'll use Hovd (also spelled Chovd and Khovd) to represent the west zone;
-# the capital of the Hovd province is sometimes called Hovd, sometimes Dund-Us,
-# and sometimes Jirgalanta (with variant spellings), but the name Hovd
-# is good enough for our purposes.
-
-# From Rives McDow (2001-05-13):
-# In addition to Mongolia starting daylight savings as reported earlier
-# (adopted DST on 2001-04-27 02:00 local time, ending 2001-09-28),
-# there are three time zones.
-#
-# Provinces [at 7:00]: Bayan-ulgii, Uvs, Khovd, Zavkhan, Govi-Altai
-# Provinces [at 8:00]: Khovsgol, Bulgan, Arkhangai, Khentii, Tov,
-#	Bayankhongor, Ovorkhangai, Dundgovi, Dornogovi, Omnogovi
-# Provinces [at 9:00]: Dornod, Sukhbaatar
-#
-# [The province of Selenge is omitted from the above lists.]
-
-# From Ganbold Ts., Ulaanbaatar (2004-04-17):
-# Daylight saving occurs at 02:00 local time last Saturday of March.
-# It will change back to normal at 02:00 local time last Saturday of
-# September.... As I remember this rule was changed in 2001.
-#
-# From Paul Eggert (2004-04-17):
-# For now, assume Rives McDow's informant got confused about Friday vs
-# Saturday, and that his 2001 dates should have 1 added to them.
-
-# From Paul Eggert (2005-07-26):
-# We have wildly conflicting information about Mongolia's time zones.
-# Bill Bonnet (2005-05-19) reports that the US Embassy in Ulaanbaatar says
-# there is only one time zone and that DST is observed, citing Microsoft
-# Windows XP as the source.  Risto Nykanen (2005-05-16) reports that
-# travelmongolia.org says there are two time zones (UTC+7, UTC+8) with no DST.
-# Oscar van Vlijmen (2005-05-20) reports that the Mongolian Embassy in
-# Washington, DC says there are two time zones, with DST observed.
-# He also found
-# <http://ubpost.mongolnews.mn/index.php?subaction=showcomments&id=1111634894&archive=&start_from=&ucat=1&>
-# which also says that there is DST, and which has a comment by "Toddius"
-# (2005-03-31 06:05 +0700) saying "Mongolia actually has 3.5 time zones.
-# The West (OLGII) is +7 GMT, most of the country is ULAT is +8 GMT
-# and some Eastern provinces are +9 GMT but Sukhbaatar Aimag is SUHK +8.5 GMT.
-# The SUKH timezone is new this year, it is one of the few things the
-# parliament passed during the tumultuous winter session."
-# For now, let's ignore this information, until we have more confirmation.
-
-# From Ganbold Ts. (2007-02-26):
-# Parliament of Mongolia has just changed the daylight-saving rule in February.
-# They decided not to adopt daylight-saving time....
-# http://www.mongolnews.mn/index.php?module=unuudur&sec=view&id=15742
-
-# From Deborah Goldsmith (2008-03-30):
-# We received a bug report claiming that the tz database UTC offset for
-# Asia/Choibalsan (GMT+09:00) is incorrect, and that it should be GMT
-# +08:00 instead. Different sources appear to disagree with the tz
-# database on this, e.g.:
-#
-# <a href="http://www.timeanddate.com/worldclock/city.html?n=1026">
-# http://www.timeanddate.com/worldclock/city.html?n=1026
-# </a>
-# <a href="http://www.worldtimeserver.com/current_time_in_MN.aspx">
-# http://www.worldtimeserver.com/current_time_in_MN.aspx
-# </a>
-#
-# both say GMT+08:00.
-
-# From Steffen Thorsen (2008-03-31):
-# eznis airways, which operates several domestic flights, has a flight
-# schedule here:
-# <a href="http://www.eznis.com/Container.jsp?id=112">
-# http://www.eznis.com/Container.jsp?id=112
-# </a>
-# (click the English flag for English)
-#
-# There it appears that flights between Choibalsan and Ulaanbatar arrive
-# about 1:35 - 1:50 hours later in local clock time, no matter the
-# direction, while Ulaanbaatar-Khvod takes 2 hours in the Eastern
-# direction and 3:35 back, which indicates that Ulaanbatar and Khvod are
-# in different time zones (like we know about), while Choibalsan and
-# Ulaanbatar are in the same time zone (correction needed).
-
-# From Arthur David Olson (2008-05-19):
-# Assume that Choibalsan is indeed offset by 8:00.
-# XXX--in the absence of better information, assume that transition
-# was at the start of 2008-03-31 (the day of Steffen Thorsen's report);
-# this is almost surely wrong.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Mongol	1983	1984	-	Apr	1	0:00	1:00	S
-Rule	Mongol	1983	only	-	Oct	1	0:00	0	-
-# Shanks & Pottenger and IATA SSIM say 1990s switches occurred at 00:00,
-# but McDow says the 2001 switches occurred at 02:00.  Also, IATA SSIM
-# (1996-09) says 1996-10-25.  Go with Shanks & Pottenger through 1998.
-#
-# Shanks & Pottenger say that the Sept. 1984 through Sept. 1990 switches
-# in Choibalsan (more precisely, in Dornod and Sukhbaatar) took place
-# at 02:00 standard time, not at 00:00 local time as in the rest of
-# the country.  That would be odd, and possibly is a result of their
-# correction of 02:00 (in the previous edition) not being done correctly
-# in the latest edition; so ignore it for now.
-
-Rule	Mongol	1985	1998	-	Mar	lastSun	0:00	1:00	S
-Rule	Mongol	1984	1998	-	Sep	lastSun	0:00	0	-
-# IATA SSIM (1999-09) says Mongolia no longer observes DST.
-Rule	Mongol	2001	only	-	Apr	lastSat	2:00	1:00	S
-Rule	Mongol	2001	2006	-	Sep	lastSat	2:00	0	-
-Rule	Mongol	2002	2006	-	Mar	lastSat	2:00	1:00	S
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Hovd, a.k.a. Chovd, Dund-Us, Dzhargalant, Khovd, Jirgalanta
-Zone	Asia/Hovd	6:06:36 -	LMT	1905 Aug
-			6:00	-	HOVT	1978	# Hovd Time
-			7:00	Mongol	HOV%sT
-# Ulaanbaatar, a.k.a. Ulan Bataar, Ulan Bator, Urga
-Zone	Asia/Ulaanbaatar 7:07:32 -	LMT	1905 Aug
-			7:00	-	ULAT	1978	# Ulaanbaatar Time
-			8:00	Mongol	ULA%sT
-# Choibalsan, a.k.a. Bajan Tuemen, Bajan Tumen, Chojbalsan,
-# Choybalsan, Sanbejse, Tchoibalsan
-Zone	Asia/Choibalsan	7:38:00 -	LMT	1905 Aug
-			7:00	-	ULAT	1978
-			8:00	-	ULAT	1983 Apr
-			9:00	Mongol	CHO%sT	2008 Mar 31 # Choibalsan Time
-			8:00	Mongol	CHO%sT
-
-# Nepal
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Katmandu	5:41:16 -	LMT	1920
-			5:30	-	IST	1986
-			5:45	-	NPT	# Nepal Time
-
-# Oman
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Muscat	3:54:20 -	LMT	1920
-			4:00	-	GST
-
-# Pakistan
-
-# From Rives McDow (2002-03-13):
-# I have been advised that Pakistan has decided to adopt dst on a
-# TRIAL basis for one year, starting 00:01 local time on April 7, 2002
-# and ending at 00:01 local time October 6, 2002.  This is what I was
-# told, but I believe that the actual time of change may be 00:00; the
-# 00:01 was to make it clear which day it was on.
-
-# From Paul Eggert (2002-03-15):
-# Jesper Norgaard found this URL:
-# http://www.pak.gov.pk/public/news/app/app06_dec.htm
-# (dated 2001-12-06) which says that the Cabinet adopted a scheme "to
-# advance the clocks by one hour on the night between the first
-# Saturday and Sunday of April and revert to the original position on
-# 15th October each year".  This agrees with McDow's 04-07 at 00:00,
-# but disagrees about the October transition, and makes it sound like
-# it's not on a trial basis.  Also, the "between the first Saturday
-# and Sunday of April" phrase, if taken literally, means that the
-# transition takes place at 00:00 on the first Sunday on or after 04-02.
-
-# From Paul Eggert (2003-02-09):
-# DAWN <http://www.dawn.com/2002/10/06/top13.htm> reported on 2002-10-05
-# that 2002 DST ended that day at midnight.  Go with McDow for now.
-
-# From Steffen Thorsen (2003-03-14):
-# According to http://www.dawn.com/2003/03/07/top15.htm
-# there will be no DST in Pakistan this year:
-#
-# ISLAMABAD, March 6: Information and Media Development Minister Sheikh
-# Rashid Ahmed on Thursday said the cabinet had reversed a previous
-# decision to advance clocks by one hour in summer and put them back by
-# one hour in winter with the aim of saving light hours and energy.
-#
-# The minister told a news conference that the experiment had rather
-# shown 8 per cent higher consumption of electricity.
-
-# From Alex Krivenyshev (2008-05-15):
-# 
-# Here is an article that Pakistan plan to introduce Daylight Saving Time 
-# on June 1, 2008 for 3 months.
-# 
-# "... The federal cabinet on Wednesday announced a new conservation plan to help 
-# reduce load shedding by approving the closure of commercial centres at 9pm and 
-# moving clocks forward by one hour for the next three months. 
-# ...."
-# 
-# <a href="http://www.worldtimezone.net/dst_news/dst_news_pakistan01.html">
-# http://www.worldtimezone.net/dst_news/dst_news_pakistan01.html
-# </a>
-# OR
-# <a href="http://www.dailytimes.com.pk/default.asp?page=2008%5C05%5C15%5Cstory_15-5-2008_pg1_4">
-# http://www.dailytimes.com.pk/default.asp?page=2008%5C05%5C15%5Cstory_15-5-2008_pg1_4
-# </a>
-
-# From Arthur David Olson (2008-05-19):
-# XXX--midnight transitions is a guess; 2008 only is a guess.
-
-# From Alexander Krivenyshev (2008-08-28):
-# Pakistan government has decided to keep the watches one-hour advanced
-# for another 2 months--plan to return to Standard Time on October 31
-# instead of August 31.
-#
-# <a href="http://www.worldtimezone.com/dst_news/dst_news_pakistan02.html">
-# http://www.worldtimezone.com/dst_news/dst_news_pakistan02.html
-# </a>
-# OR
-# <a href="http://dailymailnews.com/200808/28/news/dmbrn03.html">
-# http://dailymailnews.com/200808/28/news/dmbrn03.html
-# </a>
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule Pakistan	2002	only	-	Apr	Sun>=2	0:01	1:00	S
-Rule Pakistan	2002	only	-	Oct	Sun>=2	0:01	0	-
-Rule Pakistan	2008	only	-	Jun	1	0:00	1:00	S
-Rule Pakistan	2008	only	-	Nov	1	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Karachi	4:28:12 -	LMT	1907
-			5:30	-	IST	1942 Sep
-			5:30	1:00	IST	1945 Oct 15
-			5:30	-	IST	1951 Sep 30
-			5:00	-	KART	1971 Mar 26 # Karachi Time
-			5:00 Pakistan	PK%sT	# Pakistan Time
-
-# Palestine
-
-# From Amos Shapir (1998-02-15):
-#
-# From 1917 until 1948-05-15, all of Palestine, including the parts now
-# known as the Gaza Strip and the West Bank, was under British rule.
-# Therefore the rules given for Israel for that period, apply there too...
-#
-# The Gaza Strip was under Egyptian rule between 1948-05-15 until 1967-06-05
-# (except a short occupation by Israel from 1956-11 till 1957-03, but no
-# time zone was affected then).  It was never formally annexed to Egypt,
-# though.
-#
-# The rest of Palestine was under Jordanian rule at that time, formally
-# annexed in 1950 as the West Bank (and the word "Trans" was dropped from
-# the country's previous name of "the Hashemite Kingdom of the
-# Trans-Jordan").  So the rules for Jordan for that time apply.  Major
-# towns in that area are Nablus (Shchem), El-Halil (Hebron), Ramallah, and
-# East Jerusalem.
-#
-# Both areas were occupied by Israel in June 1967, but not annexed (except
-# for East Jerusalem).  They were on Israel time since then; there might
-# have been a Military Governor's order about time zones, but I'm not aware
-# of any (such orders may have been issued semi-annually whenever summer
-# time was in effect, but maybe the legal aspect of time was just neglected).
-#
-# The Palestinian Authority was established in 1993, and got hold of most
-# towns in the West Bank and Gaza by 1995.  I know that in order to
-# demonstrate...independence, they have been switching to
-# summer time and back on a different schedule than Israel's, but I don't
-# know when this was started, or what algorithm is used (most likely the
-# Jordanian one).
-#
-# To summarize, the table should probably look something like that:
-#
-# Area \ when | 1918-1947 | 1948-1967 | 1967-1995 | 1996-
-# ------------+-----------+-----------+-----------+-----------
-# Israel      | Zion      | Zion      | Zion      | Zion
-# West bank   | Zion      | Jordan    | Zion      | Jordan
-# Gaza        | Zion      | Egypt     | Zion      | Jordan
-#
-# I guess more info may be available from the PA's web page (if/when they
-# have one).
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that Gaza did not observe DST until 1957, but go
-# with Shapir and assume that it observed DST from 1940 through 1947,
-# and that it used Jordanian rules starting in 1996.
-# We don't yet need a separate entry for the West Bank, since
-# the only differences between it and Gaza that we know about
-# occurred before our cutoff date of 1970.
-# However, as we get more information, we may need to add entries
-# for parts of the West Bank as they transitioned from Israel's rules
-# to Palestine's rules.  If you have more info about this, please
-# send it to tz@elsie.nci.nih.gov for incorporation into future editions.
-
-# From IINS News Service - Israel - 1998-03-23 10:38:07 Israel time,
-# forwarded by Ephraim Silverberg:
-#
-# Despite the fact that Israel changed over to daylight savings time
-# last week, the PLO Authority (PA) has decided not to turn its clocks
-# one-hour forward at this time.  As a sign of independence from Israeli rule,
-# the PA has decided to implement DST in April.
-
-# From Paul Eggert (1999-09-20):
-# Daoud Kuttab writes in
-# <a href="http://www.jpost.com/com/Archive/22.Apr.1999/Opinion/Article-2.html">
-# Holiday havoc
-# </a> (Jerusalem Post, 1999-04-22) that
-# the Palestinian National Authority changed to DST on 1999-04-15.
-# I vaguely recall that they switch back in October (sorry, forgot the source).
-# For now, let's assume that the spring switch was at 24:00,
-# and that they switch at 0:00 on the 3rd Fridays of April and October.
-
-# From Paul Eggert (2005-11-22):
-# Starting 2004 transitions are from Steffen Thorsen's web site timeanddate.com.
-
-# From Steffen Thorsen (2005-11-23):
-# A user from Gaza reported that Gaza made the change early because of
-# the Ramadan.  Next year Ramadan will be even earlier, so I think
-# there is a good chance next year's end date will be around two weeks
-# earlier--the same goes for Jordan.
-
-# From Steffen Thorsen (2006-08-17):
-# I was informed by a user in Bethlehem that in Bethlehem it started the
-# same day as Israel, and after checking with other users in the area, I
-# was informed that they started DST one day after Israel.  I was not
-# able to find any authoritative sources at the time, nor details if
-# Gaza changed as well, but presumed Gaza to follow the same rules as
-# the West Bank.
-
-# From Steffen Thorsen (2006-09-26):
-# according to the Palestine News Network (2006-09-19):
-# http://english.pnn.ps/index.php?option=com_content&task=view&id=596&Itemid=5
-# > The Council of Ministers announced that this year its winter schedule
-# > will begin early, as of midnight Thursday.  It is also time to turn
-# > back the clocks for winter.  Friday will begin an hour late this week.
-# I guess it is likely that next year's date will be moved as well,
-# because of the Ramadan.
-
-# From Jesper Norgaard Welen (2007-09-18):
-# According to Steffen Thorsen's web site the Gaza Strip and the rest of the
-# Palestinian territories left DST early on 13.th. of September at 2:00.
-
-# From Paul Eggert (2007-09-20):
-# My understanding is that Gaza and the West Bank disagree even over when
-# the weekend is (Thursday+Friday versus Friday+Saturday), so I'd be a bit
-# surprised if they agreed about DST.  But for now, assume they agree.
-# For lack of better information, predict that future changes will be
-# the 2nd Thursday of September at 02:00.
-
-# From Alexander Krivenyshev (2008-08-28):
-# Here is an article, that Mideast running on different clocks at Ramadan.
-#
-# Gaza Strip (as Egypt) ended DST at midnight Thursday (Aug 28, 2008), while
-# the West Bank will end Daylight Saving Time at midnight Sunday (Aug 31, 2008).
-#
-# <a href="http://www.guardian.co.uk/world/feedarticle/7759001">
-# http://www.guardian.co.uk/world/feedarticle/7759001
-# </a>
-# <a href="http://www.abcnews.go.com/International/wireStory?id=5676087">
-# http://www.abcnews.go.com/International/wireStory?id=5676087
-# </a>
-# or
-# <a href="http://www.worldtimezone.com/dst_news/dst_news_gazastrip01.html">
-# http://www.worldtimezone.com/dst_news/dst_news_gazastrip01.html
-# </a>
-
-# The rules for Egypt are stolen from the `africa' file.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule EgyptAsia	1957	only	-	May	10	0:00	1:00	S
-Rule EgyptAsia	1957	1958	-	Oct	 1	0:00	0	-
-Rule EgyptAsia	1958	only	-	May	 1	0:00	1:00	S
-Rule EgyptAsia	1959	1967	-	May	 1	1:00	1:00	S
-Rule EgyptAsia	1959	1965	-	Sep	30	3:00	0	-
-Rule EgyptAsia	1966	only	-	Oct	 1	3:00	0	-
-
-Rule Palestine	1999	2005	-	Apr	Fri>=15	0:00	1:00	S
-Rule Palestine	1999	2003	-	Oct	Fri>=15	0:00	0	-
-Rule Palestine	2004	only	-	Oct	 1	1:00	0	-
-Rule Palestine	2005	only	-	Oct	 4	2:00	0	-
-Rule Palestine	2006	max	-	Apr	 1	0:00	1:00	S
-Rule Palestine	2006	only	-	Sep	22	0:00	0	-
-Rule Palestine	2007	only	-	Sep	Thu>=8	2:00	0	-
-Rule Palestine	2008	max	-	Aug	lastThu	2:00	0	-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Gaza	2:17:52	-	LMT	1900 Oct
-			2:00	Zion	EET	1948 May 15
-			2:00 EgyptAsia	EE%sT	1967 Jun  5
-			2:00	Zion	I%sT	1996
-			2:00	Jordan	EE%sT	1999
-			2:00 Palestine	EE%sT
-
-# Paracel Is
-# no information
-
-# Philippines
-# On 1844-08-16, Narciso Claveria, governor-general of the
-# Philippines, issued a proclamation announcing that 1844-12-30 was to
-# be immediately followed by 1845-01-01.  Robert H. van Gent has a
-# transcript of the decree in <http://www.phys.uu.nl/~vgent/idl/idl.htm>.
-# The rest of the data are from Shanks & Pottenger.
-
-# From Paul Eggert (2006-04-25):
-# Tomorrow's Manila Standard reports that the Philippines Department of
-# Trade and Industry is considering adopting DST this June when the
-# rainy season begins.  See
-# <http://www.manilastandardtoday.com/?page=politics02_april26_2006>.
-# For now, we'll ignore this, since it's not definite and we lack details.
-#
-# From Jesper Norgaard Welen (2006-04-26):
-# ... claims that Philippines had DST last time in 1990:
-# http://story.philippinetimes.com/p.x/ct/9/id/145be20cc6b121c0/cid/3e5bbccc730d258c/
-# [a story dated 2006-04-25 by Cris Larano of Dow Jones Newswires,
-# but no details]
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Phil	1936	only	-	Nov	1	0:00	1:00	S
-Rule	Phil	1937	only	-	Feb	1	0:00	0	-
-Rule	Phil	1954	only	-	Apr	12	0:00	1:00	S
-Rule	Phil	1954	only	-	Jul	1	0:00	0	-
-Rule	Phil	1978	only	-	Mar	22	0:00	1:00	S
-Rule	Phil	1978	only	-	Sep	21	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Manila	-15:56:00 -	LMT	1844 Dec 31
-			8:04:00 -	LMT	1899 May 11
-			8:00	Phil	PH%sT	1942 May
-			9:00	-	JST	1944 Nov
-			8:00	Phil	PH%sT
-
-# Qatar
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Qatar	3:26:08 -	LMT	1920	# Al Dawhah / Doha
-			4:00	-	GST	1972 Jun
-			3:00	-	AST
-
-# Saudi Arabia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Riyadh	3:06:52 -	LMT	1950
-			3:00	-	AST
-
-# Singapore
-# The data here are taken from Mok Ly Yng (2003-10-30)
-# <http://www.math.nus.edu.sg/aslaksen/teaching/timezone.html>.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Singapore	6:55:25 -	LMT	1901 Jan  1
-			6:55:25	-	SMT	1905 Jun  1 # Singapore M.T.
-			7:00	-	MALT	1933 Jan  1 # Malaya Time
-			7:00	0:20	MALST	1936 Jan  1
-			7:20	-	MALT	1941 Sep  1
-			7:30	-	MALT	1942 Feb 16
-			9:00	-	JST	1945 Sep 12
-			7:30	-	MALT	1965 Aug  9 # independence
-			7:30	-	SGT	1982 Jan  1 # Singapore Time
-			8:00	-	SGT
-
-# Spratly Is
-# no information
-
-# Sri Lanka
-# From Paul Eggert (1996-09-03):
-# "Sri Lanka advances clock by an hour to avoid blackout"
-# (www.virtual-pc.com/lankaweb/news/items/240596-2.html, 1996-05-24,
-# no longer available as of 1999-08-17)
-# reported ``the country's standard time will be put forward by one hour at
-# midnight Friday (1830 GMT) `in the light of the present power crisis'.''
-#
-# From Dharmasiri Senanayake, Sri Lanka Media Minister (1996-10-24), as quoted
-# by Shamindra in
-# <a href="news:54rka5$m5h@mtinsc01-mgt.ops.worldnet.att.net">
-# Daily News - Hot News Section (1996-10-26)
-# </a>:
-# With effect from 12.30 a.m. on 26th October 1996
-# Sri Lanka will be six (06) hours ahead of GMT.
-
-# From Jesper Norgaard Welen (2006-04-14), quoting Sri Lanka News Online
-# <http://news.sinhalaya.com/wmview.php?ArtID=11002> (2006-04-13):
-# 0030 hrs on April 15, 2006 (midnight of April 14, 2006 +30 minutes)
-# at present, become 2400 hours of April 14, 2006 (midnight of April 14, 2006).
-
-# From Peter Apps and Ranga Sirila of Reuters (2006-04-12) in:
-# <http://today.reuters.co.uk/news/newsArticle.aspx?type=scienceNews&storyID=2006-04-12T172228Z_01_COL295762_RTRIDST_0_SCIENCE-SRILANKA-TIME-DC.XML>
-# [The Tamil Tigers] never accepted the original 1996 time change and simply
-# kept their clocks set five and a half hours ahead of Greenwich Mean
-# Time (GMT), in line with neighbor India.
-# From Paul Eggert (2006-04-18):
-# People who live in regions under Tamil control can use [TZ='Asia/Kolkata'],
-# as that zone has agreed with the Tamil areas since our cutoff date of 1970.
-
-# From K Sethu (2006-04-25):
-# I think the abbreviation LKT originated from the world of computers at
-# the time of or subsequent to the time zone changes by SL Government
-# twice in 1996 and probably SL Government or its standardization
-# agencies never declared an abbreviation as a national standard.
-#
-# I recollect before the recent change the government annoucemments
-# mentioning it as simply changing Sri Lanka Standard Time or Sri Lanka
-# Time and no mention was made about the abbreviation.
-#
-# If we look at Sri Lanka Department of Government's "Official News
-# Website of Sri Lanka" ... http://www.news.lk/ we can see that they
-# use SLT as abbreviation in time stamp at the beginning of each news
-# item....
-#
-# Within Sri Lanka I think LKT is well known among computer users and
-# adminsitrators.  In my opinion SLT may not be a good choice because the
-# nation's largest telcom / internet operator Sri Lanka Telcom is well
-# known by that abbreviation - simply as SLT (there IP domains are
-# slt.lk and sltnet.lk).
-#
-# But if indeed our government has adopted SLT as standard abbreviation
-# (that we have not known so far) then  it is better that it be used for
-# all computers.
-
-# From Paul Eggert (2006-04-25):
-# One possibility is that we wait for a bit for the dust to settle down
-# and then see what people actually say in practice.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Colombo	5:19:24 -	LMT	1880
-			5:19:32	-	MMT	1906	# Moratuwa Mean Time
-			5:30	-	IST	1942 Jan  5
-			5:30	0:30	IHST	1942 Sep
-			5:30	1:00	IST	1945 Oct 16 2:00
-			5:30	-	IST	1996 May 25 0:00
-			6:30	-	LKT	1996 Oct 26 0:30
-			6:00	-	LKT	2006 Apr 15 0:30
-			5:30	-	IST
-
-# Syria
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Syria	1920	1923	-	Apr	Sun>=15	2:00	1:00	S
-Rule	Syria	1920	1923	-	Oct	Sun>=1	2:00	0	-
-Rule	Syria	1962	only	-	Apr	29	2:00	1:00	S
-Rule	Syria	1962	only	-	Oct	1	2:00	0	-
-Rule	Syria	1963	1965	-	May	1	2:00	1:00	S
-Rule	Syria	1963	only	-	Sep	30	2:00	0	-
-Rule	Syria	1964	only	-	Oct	1	2:00	0	-
-Rule	Syria	1965	only	-	Sep	30	2:00	0	-
-Rule	Syria	1966	only	-	Apr	24	2:00	1:00	S
-Rule	Syria	1966	1976	-	Oct	1	2:00	0	-
-Rule	Syria	1967	1978	-	May	1	2:00	1:00	S
-Rule	Syria	1977	1978	-	Sep	1	2:00	0	-
-Rule	Syria	1983	1984	-	Apr	9	2:00	1:00	S
-Rule	Syria	1983	1984	-	Oct	1	2:00	0	-
-Rule	Syria	1986	only	-	Feb	16	2:00	1:00	S
-Rule	Syria	1986	only	-	Oct	9	2:00	0	-
-Rule	Syria	1987	only	-	Mar	1	2:00	1:00	S
-Rule	Syria	1987	1988	-	Oct	31	2:00	0	-
-Rule	Syria	1988	only	-	Mar	15	2:00	1:00	S
-Rule	Syria	1989	only	-	Mar	31	2:00	1:00	S
-Rule	Syria	1989	only	-	Oct	1	2:00	0	-
-Rule	Syria	1990	only	-	Apr	1	2:00	1:00	S
-Rule	Syria	1990	only	-	Sep	30	2:00	0	-
-Rule	Syria	1991	only	-	Apr	 1	0:00	1:00	S
-Rule	Syria	1991	1992	-	Oct	 1	0:00	0	-
-Rule	Syria	1992	only	-	Apr	 8	0:00	1:00	S
-Rule	Syria	1993	only	-	Mar	26	0:00	1:00	S
-Rule	Syria	1993	only	-	Sep	25	0:00	0	-
-# IATA SSIM (1998-02) says 1998-04-02;
-# (1998-09) says 1999-03-29 and 1999-09-29; (1999-02) says 1999-04-02,
-# 2000-04-02, and 2001-04-02; (1999-09) says 2000-03-31 and 2001-03-31;
-# (2006) says 2006-03-31 and 2006-09-22;
-# for now ignore all these claims and go with Shanks & Pottenger,
-# except for the 2006-09-22 claim (which seems right for Ramadan).
-Rule	Syria	1994	1996	-	Apr	 1	0:00	1:00	S
-Rule	Syria	1994	2005	-	Oct	 1	0:00	0	-
-Rule	Syria	1997	1998	-	Mar	lastMon	0:00	1:00	S
-Rule	Syria	1999	2006	-	Apr	 1	0:00	1:00	S
-# From Stephen Colebourne (2006-09-18):
-# According to IATA data, Syria will change DST on 21st September [21:00 UTC]
-# this year [only]....  This is probably related to Ramadan, like Egypt.
-Rule	Syria	2006	only	-	Sep	22	0:00	0	-
-# From Paul Eggert (2007-03-29):
-# Today the AP reported "Syria will switch to summertime at midnight Thursday."
-# http://www.iht.com/articles/ap/2007/03/29/africa/ME-GEN-Syria-Time-Change.php
-Rule	Syria	2007	only	-	Mar	lastFri	0:00	1:00	S
-# From Jesper Norgard (2007-10-27):
-# The sister center ICARDA of my work CIMMYT is confirming that Syria DST will
-# not take place 1.st November at 0:00 o'clock but 1.st November at 24:00 or
-# rather Midnight between Thursday and Friday. This does make more sence than
-# having it between Wednesday and Thursday (two workdays in Syria) since the
-# weekend in Syria is not Saturday and Sunday, but Friday and Saturday. So now
-# it is implemented at midnight of the last workday before weekend...
-# 
-# From Steffen Thorsen (2007-10-27):
-# Jesper Norgaard Welen wrote:
-# 
-# > "Winter local time in Syria will be observed at midnight of Thursday 1
-# > November 2007, and the clock will be put back 1 hour."
-# 
-# I found confirmation on this in this gov.sy-article (Arabic):
-# http://wehda.alwehda.gov.sy/_print_veiw.asp?FileName=12521710520070926111247
-# 
-# which using Google's translate tools says:
-# Council of Ministers also approved the commencement of work on 
-# identifying the winter time as of Friday, 2/11/2007 where the 60th 
-# minute delay at midnight Thursday 1/11/2007.
-Rule	Syria	2007	only	-	Nov	 Fri>=1	0:00	0	-
-
-# From Stephen Colebourne (2008-03-17):
-# For everyone's info, I saw an IATA time zone change for [Syria] for
-# this month (March 2008) in the last day or so...This is the data IATA
-# are now using:
-# Country     Time Standard   --- DST Start ---   --- DST End ---  DST
-# Name        Zone Variation   Time    Date        Time    Date
-# Variation
-# Syrian Arab
-# Republic    SY    +0200      2200  03APR08       2100  30SEP08   +0300
-#                              2200  02APR09       2100  30SEP09   +0300
-#                              2200  01APR10       2100  30SEP10   +0300
-
-# From Arthur David Olson (2008-03-17):
-# Here's a link to English-language coverage by the Syrian Arab News
-# Agency (SANA)...
-# <a href="http://www.sana.sy/eng/21/2008/03/11/165173.htm">
-# http://www.sana.sy/eng/21/2008/03/11/165173.htm
-# </a>...which reads (in part) "The Cabinet approved the suggestion of the
-# Ministry of Electricity to begin daylight savings time on Friday April
-# 4th, advancing clocks one hour ahead on midnight of Thursday April 3rd."
-# Since Syria is two hours east of UTC, the 2200 and 2100 transition times
-# shown above match up with midnight in Syria.
-
-# From Arthur David Olson (2008-03-18):
-# My buest guess at a Syrian rule is "the Friday nearest April 1";
-# coding that involves either using a "Mar Fri>=29" construct that old time zone
-# compilers can't handle  or having multiple Rules (a la Israel).
-# For now, use "Apr Fri>=1", and go with IATA on a uniform Sep 30 end.
-
-# From Steffen Thorsen (2008-10-07):
-# Syria has now officially decided to end DST on 2008-11-01 this year,
-# according to the following article in the Syrian Arab News Agency (SANA).
-#
-# The article is in Arabic, and seems to tell that they will go back to
-# winter time on 2008-11-01 at 00:00 local daylight time (delaying/setting
-# clocks back 60 minutes).
-#
-# <a href="http://sana.sy/ara/2/2008/10/07/195459.htm">
-# http://sana.sy/ara/2/2008/10/07/195459.htm
-# </a>
-
-Rule	Syria	2008	max	-	Apr	Fri>=1	0:00	1:00	S
-Rule	Syria	2008	max	-	Nov	1	0:00	0	-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Damascus	2:25:12 -	LMT	1920	# Dimashq
-			2:00	Syria	EE%sT
-
-# Tajikistan
-# From Shanks & Pottenger.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Dushanbe	4:35:12 -	LMT	1924 May  2
-			5:00	-	DUST	1930 Jun 21 # Dushanbe Time
-			6:00 RussiaAsia DUS%sT	1991 Mar 31 2:00s
-			5:00	1:00	DUSST	1991 Sep  9 2:00s
-			5:00	-	TJT		    # Tajikistan Time
-
-# Thailand
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Bangkok	6:42:04	-	LMT	1880
-			6:42:04	-	BMT	1920 Apr # Bangkok Mean Time
-			7:00	-	ICT
-
-# Turkmenistan
-# From Shanks & Pottenger.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Ashgabat	3:53:32 -	LMT	1924 May  2 # or Ashkhabad
-			4:00	-	ASHT	1930 Jun 21 # Ashkhabad Time
-			5:00 RussiaAsia	ASH%sT	1991 Mar 31 2:00
-			4:00 RussiaAsia	ASH%sT	1991 Oct 27 # independence
-			4:00 RussiaAsia	TM%sT	1992 Jan 19 2:00
-			5:00	-	TMT
-
-# United Arab Emirates
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Dubai	3:41:12 -	LMT	1920
-			4:00	-	GST
-
-# Uzbekistan
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Samarkand	4:27:12 -	LMT	1924 May  2
-			4:00	-	SAMT	1930 Jun 21 # Samarkand Time
-			5:00	-	SAMT	1981 Apr  1
-			5:00	1:00	SAMST	1981 Oct  1
-			6:00	-	TAST	1982 Apr  1 # Tashkent Time
-			5:00 RussiaAsia	SAM%sT	1991 Sep  1 # independence
-			5:00 RussiaAsia	UZ%sT	1992
-			5:00	-	UZT
-Zone	Asia/Tashkent	4:37:12 -	LMT	1924 May  2
-			5:00	-	TAST	1930 Jun 21 # Tashkent Time
-			6:00 RussiaAsia	TAS%sT	1991 Mar 31 2:00
-			5:00 RussiaAsia	TAS%sT	1991 Sep  1 # independence
-			5:00 RussiaAsia	UZ%sT	1992
-			5:00	-	UZT
-
-# Vietnam
-
-# From Arthur David Olson (2008-03-18):
-# The English-language name of Vietnam's most populous city is "Ho Chi Min City";
-# we use Ho_Chi_Minh below to avoid a name of more than 14 characters.
-
-# From Shanks & Pottenger:
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Ho_Chi_Minh	7:06:40 -	LMT	1906 Jun  9
-			7:06:20	-	SMT	1911 Mar 11 0:01 # Saigon MT?
-			7:00	-	ICT	1912 May
-			8:00	-	ICT	1931 May
-			7:00	-	ICT
-
-# Yemen
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Aden	3:00:48	-	LMT	1950
-			3:00	-	AST
diff --git a/tools/zoneinfo/tzdata2008h/australasia b/tools/zoneinfo/tzdata2008h/australasia
deleted file mode 100644
index 41608cd..0000000
--- a/tools/zoneinfo/tzdata2008h/australasia
+++ /dev/null
@@ -1,1454 +0,0 @@
-# @(#)australasia	8.9
-# <pre>
-
-# This file also includes Pacific islands.
-
-# Notes are at the end of this file
-
-###############################################################################
-
-# Australia
-
-# Please see the notes below for the controversy about "EST" versus "AEST" etc.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Aus	1917	only	-	Jan	 1	0:01	1:00	-
-Rule	Aus	1917	only	-	Mar	25	2:00	0	-
-Rule	Aus	1942	only	-	Jan	 1	2:00	1:00	-
-Rule	Aus	1942	only	-	Mar	29	2:00	0	-
-Rule	Aus	1942	only	-	Sep	27	2:00	1:00	-
-Rule	Aus	1943	1944	-	Mar	lastSun	2:00	0	-
-Rule	Aus	1943	only	-	Oct	 3	2:00	1:00	-
-# Go with Whitman and the Australian National Standards Commission, which
-# says W Australia didn't use DST in 1943/1944.  Ignore Whitman's claim that
-# 1944/1945 was just like 1943/1944.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Northern Territory
-Zone Australia/Darwin	 8:43:20 -	LMT	1895 Feb
-			 9:00	-	CST	1899 May
-			 9:30	Aus	CST
-# Western Australia
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AW	1974	only	-	Oct	lastSun	2:00s	1:00	-
-Rule	AW	1975	only	-	Mar	Sun>=1	2:00s	0	-
-Rule	AW	1983	only	-	Oct	lastSun	2:00s	1:00	-
-Rule	AW	1984	only	-	Mar	Sun>=1	2:00s	0	-
-Rule	AW	1991	only	-	Nov	17	2:00s	1:00	-
-Rule	AW	1992	only	-	Mar	Sun>=1	2:00s	0	-
-Rule	AW	2006	only	-	Dec	 3	2:00s	1:00	-
-Rule	AW	2007	2009	-	Mar	lastSun	2:00s	0	-
-Rule	AW	2007	2008	-	Oct	lastSun	2:00s	1:00	-
-Zone Australia/Perth	 7:43:24 -	LMT	1895 Dec
-			 8:00	Aus	WST	1943 Jul
-			 8:00	AW	WST
-Zone Australia/Eucla	 8:35:28 -	LMT	1895 Dec
-			 8:45	Aus	CWST	1943 Jul
-			 8:45	AW	CWST
-
-# Queensland
-#
-# From Alex Livingston (1996-11-01):
-# I have heard or read more than once that some resort islands off the coast
-# of Queensland chose to keep observing daylight-saving time even after
-# Queensland ceased to.
-#
-# From Paul Eggert (1996-11-22):
-# IATA SSIM (1993-02/1994-09) say that the Holiday Islands (Hayman, Lindeman,
-# Hamilton) observed DST for two years after the rest of Queensland stopped.
-# Hamilton is the largest, but there is also a Hamilton in Victoria,
-# so use Lindeman.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AQ	1971	only	-	Oct	lastSun	2:00s	1:00	-
-Rule	AQ	1972	only	-	Feb	lastSun	2:00s	0	-
-Rule	AQ	1989	1991	-	Oct	lastSun	2:00s	1:00	-
-Rule	AQ	1990	1992	-	Mar	Sun>=1	2:00s	0	-
-Rule	Holiday	1992	1993	-	Oct	lastSun	2:00s	1:00	-
-Rule	Holiday	1993	1994	-	Mar	Sun>=1	2:00s	0	-
-Zone Australia/Brisbane	10:12:08 -	LMT	1895
-			10:00	Aus	EST	1971
-			10:00	AQ	EST
-Zone Australia/Lindeman  9:55:56 -	LMT	1895
-			10:00	Aus	EST	1971
-			10:00	AQ	EST	1992 Jul
-			10:00	Holiday	EST
-
-# South Australia
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AS	1971	1985	-	Oct	lastSun	2:00s	1:00	-
-Rule	AS	1986	only	-	Oct	19	2:00s	1:00	-
-Rule	AS	1987	2007	-	Oct	lastSun	2:00s	1:00	-
-Rule	AS	1972	only	-	Feb	27	2:00s	0	-
-Rule	AS	1973	1985	-	Mar	Sun>=1	2:00s	0	-
-Rule	AS	1986	1989	-	Mar	Sun>=15	2:00s	0	-
-Rule	AS	1990	only	-	Mar	Sun>=18	2:00s	0	-
-Rule	AS	1991	only	-	Mar	Sun>=1	2:00s	0	-
-Rule	AS	1992	only	-	Mar	Sun>=18	2:00s	0	-
-Rule	AS	1993	only	-	Mar	Sun>=1	2:00s	0	-
-Rule	AS	1994	only	-	Mar	Sun>=18	2:00s	0	-
-Rule	AS	1995	2005	-	Mar	lastSun	2:00s	0	-
-Rule	AS	2006	only	-	Apr	Sun>=1	2:00s	0	-
-Rule	AS	2007	only	-	Mar	lastSun	2:00s	0	-
-Rule	AS	2008	max	-	Apr	Sun>=1	2:00s	0	-
-Rule	AS	2008	max	-	Oct	Sun>=1	2:00s	1:00	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Australia/Adelaide	9:14:20 -	LMT	1895 Feb
-			9:00	-	CST	1899 May
-			9:30	Aus	CST	1971
-			9:30	AS	CST
-
-# Tasmania
-#
-# From Paul Eggert (2005-08-16):
-# <http://www.bom.gov.au/climate/averages/tables/dst_times.shtml>
-# says King Island didn't observe DST from WWII until late 1971.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AT	1967	only	-	Oct	Sun>=1	2:00s	1:00	-
-Rule	AT	1968	only	-	Mar	lastSun	2:00s	0	-
-Rule	AT	1968	1985	-	Oct	lastSun	2:00s	1:00	-
-Rule	AT	1969	1971	-	Mar	Sun>=8	2:00s	0	-
-Rule	AT	1972	only	-	Feb	lastSun	2:00s	0	-
-Rule	AT	1973	1981	-	Mar	Sun>=1	2:00s	0	-
-Rule	AT	1982	1983	-	Mar	lastSun	2:00s	0	-
-Rule	AT	1984	1986	-	Mar	Sun>=1	2:00s	0	-
-Rule	AT	1986	only	-	Oct	Sun>=15	2:00s	1:00	-
-Rule	AT	1987	1990	-	Mar	Sun>=15	2:00s	0	-
-Rule	AT	1987	only	-	Oct	Sun>=22	2:00s	1:00	-
-Rule	AT	1988	1990	-	Oct	lastSun	2:00s	1:00	-
-Rule	AT	1991	1999	-	Oct	Sun>=1	2:00s	1:00	-
-Rule	AT	1991	2005	-	Mar	lastSun	2:00s	0	-
-Rule	AT	2000	only	-	Aug	lastSun	2:00s	1:00	-
-Rule	AT	2001	max	-	Oct	Sun>=1	2:00s	1:00	-
-Rule	AT	2006	only	-	Apr	Sun>=1	2:00s	0	-
-Rule	AT	2007	only	-	Mar	lastSun	2:00s	0	-
-Rule	AT	2008	max	-	Apr	Sun>=1	2:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Australia/Hobart	9:49:16	-	LMT	1895 Sep
-			10:00	-	EST	1916 Oct 1 2:00
-			10:00	1:00	EST	1917 Feb
-			10:00	Aus	EST	1967
-			10:00	AT	EST
-Zone Australia/Currie	9:35:28	-	LMT	1895 Sep
-			10:00	-	EST	1916 Oct 1 2:00
-			10:00	1:00	EST	1917 Feb
-			10:00	Aus	EST	1971 Jul
-			10:00	AT	EST
-
-# Victoria
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AV	1971	1985	-	Oct	lastSun	2:00s	1:00	-
-Rule	AV	1972	only	-	Feb	lastSun	2:00s	0	-
-Rule	AV	1973	1985	-	Mar	Sun>=1	2:00s	0	-
-Rule	AV	1986	1990	-	Mar	Sun>=15	2:00s	0	-
-Rule	AV	1986	1987	-	Oct	Sun>=15	2:00s	1:00	-
-Rule	AV	1988	1999	-	Oct	lastSun	2:00s	1:00	-
-Rule	AV	1991	1994	-	Mar	Sun>=1	2:00s	0	-
-Rule	AV	1995	2005	-	Mar	lastSun	2:00s	0	-
-Rule	AV	2000	only	-	Aug	lastSun	2:00s	1:00	-
-Rule	AV	2001	2007	-	Oct	lastSun	2:00s	1:00	-
-Rule	AV	2006	only	-	Apr	Sun>=1	2:00s	0	-
-Rule	AV	2007	only	-	Mar	lastSun	2:00s	0	-
-Rule	AV	2008	max	-	Apr	Sun>=1	2:00s	0	-
-Rule	AV	2008	max	-	Oct	Sun>=1	2:00s	1:00	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Australia/Melbourne 9:39:52 -	LMT	1895 Feb
-			10:00	Aus	EST	1971
-			10:00	AV	EST
-
-# New South Wales
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	AN	1971	1985	-	Oct	lastSun	2:00s	1:00	-
-Rule	AN	1972	only	-	Feb	27	2:00s	0	-
-Rule	AN	1973	1981	-	Mar	Sun>=1	2:00s	0	-
-Rule	AN	1982	only	-	Apr	Sun>=1	2:00s	0	-
-Rule	AN	1983	1985	-	Mar	Sun>=1	2:00s	0	-
-Rule	AN	1986	1989	-	Mar	Sun>=15	2:00s	0	-
-Rule	AN	1986	only	-	Oct	19	2:00s	1:00	-
-Rule	AN	1987	1999	-	Oct	lastSun	2:00s	1:00	-
-Rule	AN	1990	1995	-	Mar	Sun>=1	2:00s	0	-
-Rule	AN	1996	2005	-	Mar	lastSun	2:00s	0	-
-Rule	AN	2000	only	-	Aug	lastSun	2:00s	1:00	-
-Rule	AN	2001	2007	-	Oct	lastSun	2:00s	1:00	-
-Rule	AN	2006	only	-	Apr	Sun>=1	2:00s	0	-
-Rule	AN	2007	only	-	Mar	lastSun	2:00s	0	-
-Rule	AN	2008	max	-	Apr	Sun>=1	2:00s	0	-
-Rule	AN	2008	max	-	Oct	Sun>=1	2:00s	1:00	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Australia/Sydney	10:04:52 -	LMT	1895 Feb
-			10:00	Aus	EST	1971
-			10:00	AN	EST
-Zone Australia/Broken_Hill 9:25:48 -	LMT	1895 Feb
-			10:00	-	EST	1896 Aug 23
-			9:00	-	CST	1899 May
-			9:30	Aus	CST	1971
-			9:30	AN	CST	2000
-			9:30	AS	CST
-
-# Lord Howe Island
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	LH	1981	1984	-	Oct	lastSun	2:00	1:00	-
-Rule	LH	1982	1985	-	Mar	Sun>=1	2:00	0	-
-Rule	LH	1985	only	-	Oct	lastSun	2:00	0:30	-
-Rule	LH	1986	1989	-	Mar	Sun>=15	2:00	0	-
-Rule	LH	1986	only	-	Oct	19	2:00	0:30	-
-Rule	LH	1987	1999	-	Oct	lastSun	2:00	0:30	-
-Rule	LH	1990	1995	-	Mar	Sun>=1	2:00	0	-
-Rule	LH	1996	2005	-	Mar	lastSun	2:00	0	-
-Rule	LH	2000	only	-	Aug	lastSun	2:00	0:30	-
-Rule	LH	2001	2007	-	Oct	lastSun	2:00	0:30	-
-Rule	LH	2006	only	-	Apr	Sun>=1	2:00	0	-
-Rule	LH	2007	only	-	Mar	lastSun	2:00	0	-
-Rule	LH	2008	max	-	Apr	Sun>=1	2:00	0	-
-Rule	LH	2008	max	-	Oct	Sun>=1	2:00	0:30	-
-Zone Australia/Lord_Howe 10:36:20 -	LMT	1895 Feb
-			10:00	-	EST	1981 Mar
-			10:30	LH	LHST
-
-# Australian miscellany
-#
-# Ashmore Is, Cartier
-# no indigenous inhabitants; only seasonal caretakers
-# no times are set
-#
-# Coral Sea Is
-# no indigenous inhabitants; only meteorologists
-# no times are set
-#
-# Macquarie
-# permanent occupation (scientific station) since 1948;
-# sealing and penguin oil station operated 1888/1917
-# like Australia/Hobart
-
-# Christmas
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Indian/Christmas	7:02:52 -	LMT	1895 Feb
-			7:00	-	CXT	# Christmas Island Time
-
-# Cook Is
-# From Shanks & Pottenger:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Cook	1978	only	-	Nov	12	0:00	0:30	HS
-Rule	Cook	1979	1991	-	Mar	Sun>=1	0:00	0	-
-Rule	Cook	1979	1990	-	Oct	lastSun	0:00	0:30	HS
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Rarotonga	-10:39:04 -	LMT	1901		# Avarua
-			-10:30	-	CKT	1978 Nov 12	# Cook Is Time
-			-10:00	Cook	CK%sT
-
-# Cocos
-# These islands were ruled by the Ross family from about 1830 to 1978.
-# We don't know when standard time was introduced; for now, we guess 1900.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Indian/Cocos	6:27:40	-	LMT	1900
-			6:30	-	CCT	# Cocos Islands Time
-
-# Fiji
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Fiji	1998	1999	-	Nov	Sun>=1	2:00	1:00	S
-Rule	Fiji	1999	2000	-	Feb	lastSun	3:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Fiji	11:53:40 -	LMT	1915 Oct 26	# Suva
-			12:00	Fiji	FJ%sT	# Fiji Time
-
-# French Polynesia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Gambier	 -8:59:48 -	LMT	1912 Oct	# Rikitea
-			 -9:00	-	GAMT	# Gambier Time
-Zone	Pacific/Marquesas -9:18:00 -	LMT	1912 Oct
-			 -9:30	-	MART	# Marquesas Time
-Zone	Pacific/Tahiti	 -9:58:16 -	LMT	1912 Oct	# Papeete
-			-10:00	-	TAHT	# Tahiti Time
-# Clipperton (near North America) is administered from French Polynesia;
-# it is uninhabited.
-
-# Guam
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Guam	-14:21:00 -	LMT	1844 Dec 31
-			 9:39:00 -	LMT	1901		# Agana
-			10:00	-	GST	2000 Dec 23	# Guam
-			10:00	-	ChST	# Chamorro Standard Time
-
-# Kiribati
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Tarawa	 11:32:04 -	LMT	1901		# Bairiki
-			 12:00	-	GILT		 # Gilbert Is Time
-Zone Pacific/Enderbury	-11:24:20 -	LMT	1901
-			-12:00	-	PHOT	1979 Oct # Phoenix Is Time
-			-11:00	-	PHOT	1995
-			 13:00	-	PHOT
-Zone Pacific/Kiritimati	-10:29:20 -	LMT	1901
-			-10:40	-	LINT	1979 Oct # Line Is Time
-			-10:00	-	LINT	1995
-			 14:00	-	LINT
-
-# N Mariana Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Saipan	-14:17:00 -	LMT	1844 Dec 31
-			 9:43:00 -	LMT	1901
-			 9:00	-	MPT	1969 Oct # N Mariana Is Time
-			10:00	-	MPT	2000 Dec 23
-			10:00	-	ChST	# Chamorro Standard Time
-
-# Marshall Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Majuro	11:24:48 -	LMT	1901
-			11:00	-	MHT	1969 Oct # Marshall Islands Time
-			12:00	-	MHT
-Zone Pacific/Kwajalein	11:09:20 -	LMT	1901
-			11:00	-	MHT	1969 Oct
-			-12:00	-	KWAT	1993 Aug 20	# Kwajalein Time
-			12:00	-	MHT
-
-# Micronesia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Truk	10:07:08 -	LMT	1901
-			10:00	-	TRUT			# Truk Time
-Zone Pacific/Ponape	10:32:52 -	LMT	1901		# Kolonia
-			11:00	-	PONT			# Ponape Time
-Zone Pacific/Kosrae	10:51:56 -	LMT	1901
-			11:00	-	KOST	1969 Oct	# Kosrae Time
-			12:00	-	KOST	1999
-			11:00	-	KOST
-
-# Nauru
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Nauru	11:07:40 -	LMT	1921 Jan 15	# Uaobe
-			11:30	-	NRT	1942 Mar 15	# Nauru Time
-			9:00	-	JST	1944 Aug 15
-			11:30	-	NRT	1979 May
-			12:00	-	NRT
-
-# New Caledonia
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	NC	1977	1978	-	Dec	Sun>=1	0:00	1:00	S
-Rule	NC	1978	1979	-	Feb	27	0:00	0	-
-Rule	NC	1996	only	-	Dec	 1	2:00s	1:00	S
-# Shanks & Pottenger say the following was at 2:00; go with IATA.
-Rule	NC	1997	only	-	Mar	 2	2:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Noumea	11:05:48 -	LMT	1912 Jan 13
-			11:00	NC	NC%sT
-
-
-###############################################################################
-
-# New Zealand
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	NZ	1927	only	-	Nov	 6	2:00	1:00	S
-Rule	NZ	1928	only	-	Mar	 4	2:00	0	M
-Rule	NZ	1928	1933	-	Oct	Sun>=8	2:00	0:30	S
-Rule	NZ	1929	1933	-	Mar	Sun>=15	2:00	0	M
-Rule	NZ	1934	1940	-	Apr	lastSun	2:00	0	M
-Rule	NZ	1934	1940	-	Sep	lastSun	2:00	0:30	S
-Rule	NZ	1946	only	-	Jan	 1	0:00	0	S
-# Since 1957 Chatham has been 45 minutes ahead of NZ, but there's no
-# convenient notation for this so we must duplicate the Rule lines.
-Rule	NZ	1974	only	-	Nov	Sun>=1	2:00s	1:00	D
-Rule	Chatham	1974	only	-	Nov	Sun>=1	2:45s	1:00	D
-Rule	NZ	1975	only	-	Feb	lastSun	2:00s	0	S
-Rule	Chatham	1975	only	-	Feb	lastSun	2:45s	0	S
-Rule	NZ	1975	1988	-	Oct	lastSun	2:00s	1:00	D
-Rule	Chatham	1975	1988	-	Oct	lastSun	2:45s	1:00	D
-Rule	NZ	1976	1989	-	Mar	Sun>=1	2:00s	0	S
-Rule	Chatham	1976	1989	-	Mar	Sun>=1	2:45s	0	S
-Rule	NZ	1989	only	-	Oct	Sun>=8	2:00s	1:00	D
-Rule	Chatham	1989	only	-	Oct	Sun>=8	2:45s	1:00	D
-Rule	NZ	1990	2006	-	Oct	Sun>=1	2:00s	1:00	D
-Rule	Chatham	1990	2006	-	Oct	Sun>=1	2:45s	1:00	D
-Rule	NZ	1990	2007	-	Mar	Sun>=15	2:00s	0	S
-Rule	Chatham	1990	2007	-	Mar	Sun>=15	2:45s	0	S
-Rule	NZ	2007	max	-	Sep	lastSun	2:00s	1:00	D
-Rule	Chatham	2007	max	-	Sep	lastSun	2:45s	1:00	D
-Rule	NZ	2008	max	-	Apr	Sun>=1	2:00s	0	S
-Rule	Chatham	2008	max	-	Apr	Sun>=1	2:45s	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Auckland	11:39:04 -	LMT	1868 Nov  2
-			11:30	NZ	NZ%sT	1946 Jan  1
-			12:00	NZ	NZ%sT
-Zone Pacific/Chatham	12:13:48 -	LMT	1957 Jan  1
-			12:45	Chatham	CHA%sT
-
-
-# Auckland Is
-# uninhabited; Maori and Moriori, colonial settlers, pastoralists, sealers,
-# and scientific personnel have wintered
-
-# Campbell I
-# minor whaling stations operated 1909/1914
-# scientific station operated 1941/1995;
-# previously whalers, sealers, pastoralists, and scientific personnel wintered
-# was probably like Pacific/Auckland
-
-###############################################################################
-
-
-# Niue
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Niue	-11:19:40 -	LMT	1901		# Alofi
-			-11:20	-	NUT	1951	# Niue Time
-			-11:30	-	NUT	1978 Oct 1
-			-11:00	-	NUT
-
-# Norfolk
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Norfolk	11:11:52 -	LMT	1901		# Kingston
-			11:12	-	NMT	1951	# Norfolk Mean Time
-			11:30	-	NFT		# Norfolk Time
-
-# Palau (Belau)
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Palau	8:57:56 -	LMT	1901		# Koror
-			9:00	-	PWT	# Palau Time
-
-# Papua New Guinea
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Port_Moresby 9:48:40 -	LMT	1880
-			9:48:32	-	PMMT	1895	# Port Moresby Mean Time
-			10:00	-	PGT		# Papua New Guinea Time
-
-# Pitcairn
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Pitcairn	-8:40:20 -	LMT	1901		# Adamstown
-			-8:30	-	PNT	1998 Apr 27 00:00
-			-8:00	-	PST	# Pitcairn Standard Time
-
-# American Samoa
-Zone Pacific/Pago_Pago	 12:37:12 -	LMT	1879 Jul  5
-			-11:22:48 -	LMT	1911
-			-11:30	-	SAMT	1950		# Samoa Time
-			-11:00	-	NST	1967 Apr	# N=Nome
-			-11:00	-	BST	1983 Nov 30	# B=Bering
-			-11:00	-	SST			# S=Samoa
-
-# Samoa
-Zone Pacific/Apia	 12:33:04 -	LMT	1879 Jul  5
-			-11:26:56 -	LMT	1911
-			-11:30	-	SAMT	1950		# Samoa Time
-			-11:00	-	WST			# Samoa Time
-
-# Solomon Is
-# excludes Bougainville, for which see Papua New Guinea
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Guadalcanal 10:39:48 -	LMT	1912 Oct	# Honiara
-			11:00	-	SBT	# Solomon Is Time
-
-# Tokelau Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Fakaofo	-11:24:56 -	LMT	1901
-			-10:00	-	TKT	# Tokelau Time
-
-# Tonga
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Tonga	1999	only	-	Oct	 7	2:00s	1:00	S
-Rule	Tonga	2000	only	-	Mar	19	2:00s	0	-
-Rule	Tonga	2000	2001	-	Nov	Sun>=1	2:00	1:00	S
-Rule	Tonga	2001	2002	-	Jan	lastSun	2:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Tongatapu	12:19:20 -	LMT	1901
-			12:20	-	TOT	1941 # Tonga Time
-			13:00	-	TOT	1999
-			13:00	Tonga	TO%sT
-
-# Tuvalu
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Funafuti	11:56:52 -	LMT	1901
-			12:00	-	TVT	# Tuvalu Time
-
-
-# US minor outlying islands
-
-# Howland, Baker
-# Howland was mined for guano by American companies 1857-1878 and British
-# 1886-1891; Baker was similar but exact dates are not known.
-# Inhabited by civilians 1935-1942; U.S. military bases 1943-1944;
-# uninhabited thereafter.
-# Howland observed Hawaii Standard Time (UTC-10:30) in 1937;
-# see page 206 of Elgen M. Long and Marie K. Long,
-# Amelia Earhart: the Mystery Solved, Simon & Schuster (2000).
-# So most likely Howland and Baker observed Hawaii Time from 1935
-# until they were abandoned after the war.
-
-# Jarvis
-# Mined for guano by American companies 1857-1879 and British 1883?-1891?.
-# Inhabited by civilians 1935-1942; IGY scientific base 1957-1958;
-# uninhabited thereafter.
-# no information; was probably like Pacific/Kiritimati
-
-# Johnston
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Johnston	-10:00	-	HST
-
-# Kingman
-# uninhabited
-
-# Midway
-#
-# From Mark Brader (2005-01-23):
-# [Fallacies and Fantasies of Air Transport History, by R.E.G. Davies,
-# published 1994 by Paladwr Press, McLean, VA, USA; ISBN 0-9626483-5-3]
-# reproduced a Pan American Airways timeables from 1936, for their weekly
-# "Orient Express" flights between San Francisco and Manila, and connecting
-# flights to Chicago and the US East Coast.  As it uses some time zone
-# designations that I've never seen before:....
-# Fri. 6:30A Lv. HONOLOLU (Pearl Harbor), H.I.   H.L.T. Ar. 5:30P Sun.
-#  "   3:00P Ar. MIDWAY ISLAND . . . . . . . . . M.L.T. Lv. 6:00A  "
-#
-Zone Pacific/Midway	-11:49:28 -	LMT	1901
-			-11:00	-	NST	1956 Jun  3
-			-11:00	1:00	NDT	1956 Sep  2
-			-11:00	-	NST	1967 Apr	# N=Nome
-			-11:00	-	BST	1983 Nov 30	# B=Bering
-			-11:00	-	SST			# S=Samoa
-
-# Palmyra
-# uninhabited since World War II; was probably like Pacific/Kiritimati
-
-# Wake
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Wake	11:06:28 -	LMT	1901
-			12:00	-	WAKT	# Wake Time
-
-
-# Vanuatu
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Vanuatu	1983	only	-	Sep	25	0:00	1:00	S
-Rule	Vanuatu	1984	1991	-	Mar	Sun>=23	0:00	0	-
-Rule	Vanuatu	1984	only	-	Oct	23	0:00	1:00	S
-Rule	Vanuatu	1985	1991	-	Sep	Sun>=23	0:00	1:00	S
-Rule	Vanuatu	1992	1993	-	Jan	Sun>=23	0:00	0	-
-Rule	Vanuatu	1992	only	-	Oct	Sun>=23	0:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Efate	11:13:16 -	LMT	1912 Jan 13		# Vila
-			11:00	Vanuatu	VU%sT	# Vanuatu Time
-
-# Wallis and Futuna
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Pacific/Wallis	12:15:20 -	LMT	1901
-			12:00	-	WFT	# Wallis & Futuna Time
-
-###############################################################################
-
-# NOTES
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (2006-03-22):
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1990, and IATA SSIM is the source for entries afterwards.
-#
-# Another source occasionally used is Edward W. Whitman, World Time Differences,
-# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which
-# I found in the UCLA library.
-#
-# A reliable and entertaining source about time zones is
-# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997).
-#
-# I invented the abbreviations marked `*' in the following table;
-# the rest are from earlier versions of this file, or from other sources.
-# Corrections are welcome!
-#		std dst
-#		LMT	Local Mean Time
-#	  8:00	WST WST	Western Australia
-#	  8:45	CWST CWST Central Western Australia*
-#	  9:00	JST	Japan
-#	  9:30	CST CST	Central Australia
-#	 10:00	EST EST	Eastern Australia
-#	 10:00	ChST	Chamorro
-#	 10:30	LHST LHST Lord Howe*
-#	 11:30	NZMT NZST New Zealand through 1945
-#	 12:00	NZST NZDT New Zealand 1946-present
-#	 12:45	CHAST CHADT Chatham*
-#	-11:00	SST	Samoa
-#	-10:00	HST	Hawaii
-#	- 8:00	PST	Pitcairn*
-#
-# See the `northamerica' file for Hawaii.
-# See the `southamerica' file for Easter I and the Galapagos Is.
-
-###############################################################################
-
-# Australia
-
-# From Paul Eggert (2005-12-08):
-# <a href="http://www.bom.gov.au/climate/averages/tables/dst_times.shtml">
-# Implementation Dates of Daylight Saving Time within Australia
-# </a> summarizes daylight saving issues in Australia.
-
-# From Arthur David Olson (2005-12-12):
-# <a href="http://www.lawlink.nsw.gov.au/lawlink/Corporate/ll_agdinfo.nsf/pages/community_relations_daylight_saving">
-# Lawlink NSW:Daylight Saving in New South Wales
-# </a> covers New South Wales in particular.
-
-# From John Mackin (1991-03-06):
-# We in Australia have _never_ referred to DST as `daylight' time.
-# It is called `summer' time.  Now by a happy coincidence, `summer'
-# and `standard' happen to start with the same letter; hence, the
-# abbreviation does _not_ change...
-# The legislation does not actually define abbreviations, at least
-# in this State, but the abbreviation is just commonly taken to be the
-# initials of the phrase, and the legislation here uniformly uses
-# the phrase `summer time' and does not use the phrase `daylight
-# time'.
-# Announcers on the Commonwealth radio network, the ABC (for Australian
-# Broadcasting Commission), use the phrases `Eastern Standard Time'
-# or `Eastern Summer Time'.  (Note, though, that as I say in the
-# current australasia file, there is really no such thing.)  Announcers
-# on its overseas service, Radio Australia, use the same phrases
-# prefixed by the word `Australian' when referring to local times;
-# time announcements on that service, naturally enough, are made in UTC.
-
-# From Arthur David Olson (1992-03-08):
-# Given the above, what's chosen for year-round use is:
-#	CST	for any place operating at a GMTOFF of 9:30
-#	WST	for any place operating at a GMTOFF of 8:00
-#	EST	for any place operating at a GMTOFF of 10:00
-
-# From Chuck Soper (2006-06-01):
-# I recently found this Australian government web page on time zones:
-# <http://www.australia.gov.au/about-australia-13time>
-# And this government web page lists time zone names and abbreviations:
-# <http://www.bom.gov.au/climate/averages/tables/daysavtm.shtml>
-
-# From Paul Eggert (2001-04-05), summarizing a long discussion about "EST"
-# versus "AEST" etc.:
-#
-# I see the following points of dispute:
-#
-# * How important are unique time zone abbreviations?
-#
-#   Here I tend to agree with the point (most recently made by Chris
-#   Newman) that unique abbreviations should not be essential for proper
-#   operation of software.  We have other instances of ambiguity
-#   (e.g. "IST" denoting both "Israel Standard Time" and "Indian
-#   Standard Time"), and they are not likely to go away any time soon.
-#   In the old days, some software mistakenly relied on unique
-#   abbreviations, but this is becoming less true with time, and I don't
-#   think it's that important to cater to such software these days.
-#
-#   On the other hand, there is another motivation for unambiguous
-#   abbreviations: it cuts down on human confusion.  This is
-#   particularly true for Australia, where "EST" can mean one thing for
-#   time T and a different thing for time T plus 1 second.
-#
-# * Does the relevant legislation indicate which abbreviations should be used?
-#
-#   Here I tend to think that things are a mess, just as they are in
-#   many other countries.  We Americans are currently disagreeing about
-#   which abbreviation to use for the newly legislated Chamorro Standard
-#   Time, for example.
-#
-#   Personally, I would prefer to use common practice; I would like to
-#   refer to legislation only for examples of common practice, or as a
-#   tiebreaker.
-#
-# * Do Australians more often use "Eastern Daylight Time" or "Eastern
-#   Summer Time"?  Do they typically prefix the time zone names with
-#   the word "Australian"?
-#
-#   My own impression is that both "Daylight Time" and "Summer Time" are
-#   common and are widely understood, but that "Summer Time" is more
-#   popular; and that the leading "A" is also common but is omitted more
-#   often than not.  I just used AltaVista advanced search and got the
-#   following count of page hits:
-#
-#     1,103 "Eastern Summer Time" AND domain:au
-#       971 "Australian Eastern Summer Time" AND domain:au
-#       613 "Eastern Daylight Time" AND domain:au
-#       127 "Australian Eastern Daylight Time" AND domain:au
-#
-#   Here "Summer" seems quite a bit more popular than "Daylight",
-#   particularly when we know the time zone is Australian and not US,
-#   say.  The "Australian" prefix seems to be popular for Eastern Summer
-#   Time, but unpopular for Eastern Daylight Time.
-#
-#   For abbreviations, tools like AltaVista are less useful because of
-#   ambiguity.  Many hits are not really time zones, unfortunately, and
-#   many hits denote US time zones and not Australian ones.  But here
-#   are the hit counts anyway:
-#
-#     161,304 "EST" and domain:au
-#      25,156 "EDT" and domain:au
-#      18,263 "AEST" and domain:au
-#      10,416 "AEDT" and domain:au
-#
-#      14,538 "CST" and domain:au
-#       5,728 "CDT" and domain:au
-#         176 "ACST" and domain:au
-#          29 "ACDT" and domain:au
-#
-#       7,539 "WST" and domain:au
-#          68 "AWST" and domain:au
-#
-#   This data suggest that Australians tend to omit the "A" prefix in
-#   practice.  The situation for "ST" versus "DT" is less clear, given
-#   the ambiguities involved.
-#
-# * How do Australians feel about the abbreviations in the tz database?
-#
-#   If you just count Australians on this list, I count 2 in favor and 3
-#   against.  One of the "against" votes (David Keegel) counseled delay,
-#   saying that both AEST/AEDT and EST/EST are widely used and
-#   understood in Australia.
-
-# From Paul Eggert (1995-12-19):
-# Shanks & Pottenger report 2:00 for all autumn changes in Australia and NZ.
-# Mark Prior writes that his newspaper
-# reports that NSW's fall 1995 change will occur at 2:00,
-# but Robert Elz says it's been 3:00 in Victoria since 1970
-# and perhaps the newspaper's `2:00' is referring to standard time.
-# For now we'll continue to assume 2:00s for changes since 1960.
-
-# From Eric Ulevik (1998-01-05):
-#
-# Here are some URLs to Australian time legislation. These URLs are stable,
-# and should probably be included in the data file. There are probably more
-# relevant entries in this database.
-#
-# NSW (including LHI and Broken Hill):
-# <a href="http://www.austlii.edu.au/au/legis/nsw/consol_act/sta1987137/index.html">
-# Standard Time Act 1987 (updated 1995-04-04)
-# </a>
-# ACT
-# <a href="http://www.austlii.edu.au/au/legis/act/consol_act/stasta1972279/index.html">
-# Standard Time and Summer Time Act 1972
-# </a>
-# SA
-# <a href="http://www.austlii.edu.au/au/legis/sa/consol_act/sta1898137/index.html">
-# Standard Time Act, 1898
-# </a>
-
-# From David Grosz (2005-06-13):
-# It was announced last week that Daylight Saving would be extended by
-# one week next year to allow for the 2006 Commonwealth Games.
-# Daylight Saving is now to end for next year only on the first Sunday
-# in April instead of the last Sunday in March.
-#
-# From Gwillim Law (2005-06-14):
-# I did some Googling and found that all of those states (and territory) plan
-# to extend DST together in 2006.
-# ACT: http://www.cmd.act.gov.au/mediareleases/fileread.cfm?file=86.txt
-# New South Wales: http://www.thecouriermail.news.com.au/common/story_page/0,5936,15538869%255E1702,00.html
-# South Australia: http://www.news.com.au/story/0,10117,15555031-1246,00.html
-# Tasmania: http://www.media.tas.gov.au/release.php?id=14772
-# Victoria: I wasn't able to find anything separate, but the other articles
-# allude to it.
-# But not Queensland
-# http://www.news.com.au/story/0,10117,15564030-1248,00.html.
-
-# Northern Territory
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# # The NORTHERN TERRITORY..  [ Courtesy N.T. Dept of the Chief Minister ]
-# #					[ Nov 1990 ]
-# #	N.T. have never utilised any DST due to sub-tropical/tropical location.
-# ...
-# Zone        Australia/North         9:30    -       CST
-
-# From Bradley White (1991-03-04):
-# A recent excerpt from an Australian newspaper...
-# the Northern Territory do[es] not have daylight saving.
-
-# Western Australia
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# #  The state of WESTERN AUSTRALIA..  [ Courtesy W.A. dept Premier+Cabinet ]
-# #						[ Nov 1990 ]
-# #	W.A. suffers from a great deal of public and political opposition to
-# #	DST in principle. A bill is brought before parliament in most years, but
-# #	usually defeated either in the upper house, or in party caucus
-# #	before reaching parliament.
-# ...
-# Zone	Australia/West		8:00	AW	%sST
-# ...
-# Rule	AW	1974	only	-	Oct	lastSun	2:00	1:00	D
-# Rule	AW	1975	only	-	Mar	Sun>=1	3:00	0	W
-# Rule	AW	1983	only	-	Oct	lastSun	2:00	1:00	D
-# Rule	AW	1984	only	-	Mar	Sun>=1	3:00	0	W
-
-# From Bradley White (1991-03-04):
-# A recent excerpt from an Australian newspaper...
-# Western Australia...do[es] not have daylight saving.
-
-# From John D. Newman via Bradley White (1991-11-02):
-# Western Australia is still on "winter time". Some DH in Sydney
-# rang me at home a few days ago at 6.00am. (He had just arrived at
-# work at 9.00am.)
-# W.A. is switching to Summer Time on Nov 17th just to confuse
-# everybody again.
-
-# From Arthur David Olson (1992-03-08):
-# The 1992 ending date used in the rules is a best guess;
-# it matches what was used in the past.
-
-# <a href="http://www.bom.gov.au/faq/faqgen.htm">
-# The Australian Bureau of Meteorology FAQ
-# </a> (1999-09-27) writes that Giles Meteorological Station uses
-# South Australian time even though it's located in Western Australia.
-
-# Queensland
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# #   The state of QUEENSLAND.. [ Courtesy Qld. Dept Premier Econ&Trade Devel ]
-# #						[ Dec 1990 ]
-# ...
-# Zone	Australia/Queensland	10:00	AQ	%sST
-# ...
-# Rule	AQ	1971	only	-	Oct	lastSun	2:00	1:00	D
-# Rule	AQ	1972	only	-	Feb	lastSun	3:00	0	E
-# Rule	AQ	1989	max	-	Oct	lastSun	2:00	1:00	D
-# Rule	AQ	1990	max	-	Mar	Sun>=1	3:00	0	E
-
-# From Bradley White (1989-12-24):
-# "Australia/Queensland" now observes daylight time (i.e. from
-# October 1989).
-
-# From Bradley White (1991-03-04):
-# A recent excerpt from an Australian newspaper...
-# ...Queensland...[has] agreed to end daylight saving
-# at 3am tomorrow (March 3)...
-
-# From John Mackin (1991-03-06):
-# I can certainly confirm for my part that Daylight Saving in NSW did in fact
-# end on Sunday, 3 March.  I don't know at what hour, though.  (It surprised
-# me.)
-
-# From Bradley White (1992-03-08):
-# ...there was recently a referendum in Queensland which resulted
-# in the experimental daylight saving system being abandoned. So, ...
-# ...
-# Rule	QLD	1989	1991	-	Oct	lastSun	2:00	1:00	D
-# Rule	QLD	1990	1992	-	Mar	Sun>=1	3:00	0	S
-# ...
-
-# From Arthur David Olson (1992-03-08):
-# The chosen rules the union of the 1971/1972 change and the 1989-1992 changes.
-
-# From Christopher Hunt (2006-11-21), after an advance warning
-# from Jesper Norgaard Welen (2006-11-01):
-# WA are trialing DST for three years.
-# <http://www.parliament.wa.gov.au/parliament/bills.nsf/9A1B183144403DA54825721200088DF1/$File/Bill175-1B.pdf>
-
-# From Rives McDow (2002-04-09):
-# The most interesting region I have found consists of three towns on the
-# southern coast....  South Australia observes daylight saving time; Western
-# Australia does not.  The two states are one and a half hours apart.  The
-# residents decided to forget about this nonsense of changing the clock so
-# much and set the local time 20 hours and 45 minutes from the
-# international date line, or right in the middle of the time of South
-# Australia and Western Australia....
-#
-# From Paul Eggert (2002-04-09):
-# This is confirmed by the section entitled
-# "What's the deal with time zones???" in
-# <http://www.earthsci.unimelb.edu.au/~awatkins/null.html>.
-#
-# From Alex Livingston (2006-12-07):
-# ... it was just on four years ago that I drove along the Eyre Highway,
-# which passes through eastern Western Australia close to the southern
-# coast of the continent.
-#
-# I paid particular attention to the time kept there. There can be no
-# dispute that UTC+08:45 was considered "the time" from the border
-# village just inside the border with South Australia to as far west
-# as just east of Caiguna. There can also be no dispute that Eucla is
-# the largest population centre in this zone....
-#
-# Now that Western Australia is observing daylight saving, the
-# question arose whether this part of the state would follow suit. I
-# just called the border village and confirmed that indeed they have,
-# meaning that they are now observing UTC+09:45.
-#
-# (2006-12-09):
-# I personally doubt that either experimentation with daylight saving
-# in WA or its introduction in SA had anything to do with the genesis
-# of this time zone.  My hunch is that it's been around since well
-# before 1975.  I remember seeing it noted on road maps decades ago.
-
-# From Paul Eggert (2006-12-15):
-# For lack of better info, assume the tradition dates back to the
-# introduction of standard time in 1895.
-
-
-# southeast Australia
-#
-# From Paul Eggert (2007-07-23):
-# Starting autumn 2008 Victoria, NSW, South Australia, Tasmania and the ACT
-# end DST the first Sunday in April and start DST the first Sunday in October.
-# http://www.theage.com.au/news/national/daylight-savings-to-span-six-months/2007/06/27/1182623966703.html
-
-
-# South Australia
-
-# From Bradley White (1991-03-04):
-# A recent excerpt from an Australian newspaper...
-# ...South Australia...[has] agreed to end daylight saving
-# at 3am tomorrow (March 3)...
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# #   The state of SOUTH AUSTRALIA....[ Courtesy of S.A. Dept of Labour ]
-# #						[ Nov 1990 ]
-# ...
-# Zone	Australia/South		9:30	AS	%sST
-# ...
-# Rule	 AS	1971	max	-	Oct	lastSun	2:00	1:00	D
-# Rule	 AS	1972	1985	-	Mar	Sun>=1	3:00	0	C
-# Rule	 AS	1986	1990	-	Mar	Sun>=15	3:00	0	C
-# Rule	 AS	1991	max	-	Mar	Sun>=1	3:00	0	C
-
-# From Bradley White (1992-03-11):
-# Recent correspondence with a friend in Adelaide
-# contained the following exchange:  "Due to the Adelaide Festival,
-# South Australia delays setting back our clocks for a few weeks."
-
-# From Robert Elz (1992-03-13):
-# I heard that apparently (or at least, it appears that)
-# South Aus will have an extra 3 weeks daylight saving every even
-# numbered year (from 1990).  That's when the Adelaide Festival
-# is on...
-
-# From Robert Elz (1992-03-16, 00:57:07 +1000):
-# DST didn't end in Adelaide today (yesterday)....
-# But whether it's "4th Sunday" or "2nd last Sunday" I have no idea whatever...
-# (it's just as likely to be "the Sunday we pick for this year"...).
-
-# From Bradley White (1994-04-11):
-# If Sun, 15 March, 1992 was at +1030 as kre asserts, but yet Sun, 20 March,
-# 1994 was at +0930 as John Connolly's customer seems to assert, then I can
-# only conclude that the actual rule is more complicated....
-
-# From John Warburton (1994-10-07):
-# The new Daylight Savings dates for South Australia ...
-# was gazetted in the Government Hansard on Sep 26 1994....
-# start on last Sunday in October and end in last sunday in March.
-
-# From Paul Eggert (2007-07-23):
-# See "southeast Australia" above for 2008 and later.
-
-# Tasmania
-
-# The rules for 1967 through 1991 were reported by George Shepherd
-# via Simon Woodhead via Robert Elz (1991-03-06):
-# #  The state of TASMANIA.. [Courtesy Tasmanian Dept of Premier + Cabinet ]
-# #					[ Nov 1990 ]
-
-# From Bill Hart via Guy Harris (1991-10-10):
-# Oh yes, the new daylight savings rules are uniquely tasmanian, we have
-# 6 weeks a year now when we are out of sync with the rest of Australia
-# (but nothing new about that).
-
-# From Alex Livingston (1999-10-04):
-# I heard on the ABC (Australian Broadcasting Corporation) radio news on the
-# (long) weekend that Tasmania, which usually goes its own way in this regard,
-# has decided to join with most of NSW, the ACT, and most of Victoria
-# (Australia) and start daylight saving on the last Sunday in August in 2000
-# instead of the first Sunday in October.
-
-# Sim Alam (2000-07-03) reported a legal citation for the 2000/2001 rules:
-# http://www.thelaw.tas.gov.au/fragview/42++1968+GS3A@EN+2000070300
-
-# From Paul Eggert (2007-07-23):
-# See "southeast Australia" above for 2008 and later.
-
-# Victoria
-
-# The rules for 1971 through 1991 were reported by George Shepherd
-# via Simon Woodhead via Robert Elz (1991-03-06):
-# #   The state of VICTORIA.. [ Courtesy of Vic. Dept of Premier + Cabinet ]
-# #						[ Nov 1990 ]
-
-# From Scott Harrington (2001-08-29):
-# On KQED's "City Arts and Lectures" program last night I heard an
-# interesting story about daylight savings time.  Dr. John Heilbron was
-# discussing his book "The Sun in the Church: Cathedrals as Solar
-# Observatories"[1], and in particular the Shrine of Remembrance[2] located
-# in Melbourne, Australia.
-#
-# Apparently the shrine's main purpose is a beam of sunlight which
-# illuminates a special spot on the floor at the 11th hour of the 11th day
-# of the 11th month (Remembrance Day) every year in memory of Australia's
-# fallen WWI soldiers.  And if you go there on Nov. 11, at 11am local time,
-# you will indeed see the sunbeam illuminate the special spot at the
-# expected time.
-#
-# However, that is only because of some special mirror contraption that had
-# to be employed, since due to daylight savings time, the true solar time of
-# the remembrance moment occurs one hour later (or earlier?).  Perhaps
-# someone with more information on this jury-rig can tell us more.
-#
-# [1] http://www.hup.harvard.edu/catalog/HEISUN.html
-# [2] http://www.shrine.org.au
-
-# From Paul Eggert (2007-07-23):
-# See "southeast Australia" above for 2008 and later.
-
-# New South Wales
-
-# From Arthur David Olson:
-# New South Wales and subjurisdictions have their own ideas of a fun time.
-# Based on law library research by John Mackin,
-# who notes:
-#	In Australia, time is not legislated federally, but rather by the
-#	individual states.  Thus, while such terms as ``Eastern Standard Time''
-#	[I mean, of course, Australian EST, not any other kind] are in common
-#	use, _they have NO REAL MEANING_, as they are not defined in the
-#	legislation.  This is very important to understand.
-#	I have researched New South Wales time only...
-
-# From Eric Ulevik (1999-05-26):
-# DST will start in NSW on the last Sunday of August, rather than the usual
-# October in 2000.  [See: Matthew Moore,
-# <a href="http://www.smh.com.au/news/9905/26/pageone/pageone4.html">
-# Two months more daylight saving
-# </a>
-# Sydney Morning Herald (1999-05-26).]
-
-# From Paul Eggert (1999-09-27):
-# See the following official NSW source:
-# <a href="http://dir.gis.nsw.gov.au/cgi-bin/genobject/document/other/daylightsaving/tigGmZ">
-# Daylight Saving in New South Wales.
-# </a>
-#
-# Narrabri Shire (NSW) council has announced it will ignore the extension of
-# daylight saving next year.  See:
-# <a href="http://abc.net.au/news/regionals/neweng/monthly/regeng-22jul1999-1.htm">
-# Narrabri Council to ignore daylight saving
-# </a> (1999-07-22).  For now, we'll wait to see if this really happens.
-#
-# Victoria will following NSW.  See:
-# <a href="http://abc.net.au/local/news/olympics/1999/07/item19990728112314_1.htm">
-# Vic to extend daylight saving
-# </a> (1999-07-28).
-#
-# However, South Australia rejected the DST request.  See:
-# <a href="http://abc.net.au/news/olympics/1999/07/item19990719151754_1.htm">
-# South Australia rejects Olympics daylight savings request
-# </a> (1999-07-19).
-#
-# Queensland also will not observe DST for the Olympics.  See:
-# <a href="http://abc.net.au/news/olympics/1999/06/item19990601114608_1.htm">
-# Qld says no to daylight savings for Olympics
-# </a> (1999-06-01), which quotes Queensland Premier Peter Beattie as saying
-# ``Look you've got to remember in my family when this came up last time
-# I voted for it, my wife voted against it and she said to me it's all very
-# well for you, you don't have to worry about getting the children out of
-# bed, getting them to school, getting them to sleep at night.
-# I've been through all this argument domestically...my wife rules.''
-#
-# Broken Hill will stick with South Australian time in 2000.  See:
-# <a href="http://abc.net.au/news/regionals/brokenh/monthly/regbrok-21jul1999-6.htm">
-# Broken Hill to be behind the times
-# </a> (1999-07-21).
-
-# IATA SSIM (1998-09) says that the spring 2000 change for Australian
-# Capital Territory, New South Wales except Lord Howe Island and Broken
-# Hill, and Victoria will be August 27, presumably due to the Sydney Olympics.
-
-# From Eric Ulevik, referring to Sydney's Sun Herald (2000-08-13), page 29:
-# The Queensland Premier Peter Beattie is encouraging northern NSW
-# towns to use Queensland time.
-
-# From Paul Eggert (2007-07-23):
-# See "southeast Australia" above for 2008 and later.
-
-# Yancowinna
-
-# From John Mackin (1989-01-04):
-# `Broken Hill' means the County of Yancowinna.
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# # YANCOWINNA..  [ Confirmation courtesy of Broken Hill Postmaster ]
-# #					[ Dec 1990 ]
-# ...
-# # Yancowinna uses Central Standard Time, despite [its] location on the
-# # New South Wales side of the S.A. border. Most business and social dealings
-# # are with CST zones, therefore CST is legislated by local government
-# # although the switch to Summer Time occurs in line with N.S.W. There have
-# # been years when this did not apply, but the historical data is not
-# # presently available.
-# Zone	Australia/Yancowinna	9:30	 AY	%sST
-# ...
-# Rule	 AY	1971	1985	-	Oct	lastSun	2:00	1:00	D
-# Rule	 AY	1972	only	-	Feb	lastSun	3:00	0	C
-# [followed by other Rules]
-
-# Lord Howe Island
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# LHI...		[ Courtesy of Pauline Van Winsen ]
-#					[ Dec 1990 ]
-# Lord Howe Island is located off the New South Wales coast, and is half an
-# hour ahead of NSW time.
-
-# From James Lonergan, Secretary, Lord Howe Island Board (2000-01-27):
-# Lord Howe Island summer time in 2000/2001 will commence on the same
-# date as the rest of NSW (i.e. 2000-08-27).  For your information the
-# Lord Howe Island Board (controlling authority for the Island) is
-# seeking the community's views on various options for summer time
-# arrangements on the Island, e.g. advance clocks by 1 full hour
-# instead of only 30 minutes.  Dependant on the wishes of residents
-# the Board may approach the NSW government to change the existing
-# arrangements.  The starting date for summer time on the Island will
-# however always coincide with the rest of NSW.
-
-# From James Lonergan, Secretary, Lord Howe Island Board (2000-10-25):
-# Lord Howe Island advances clocks by 30 minutes during DST in NSW and retards
-# clocks by 30 minutes when DST finishes. Since DST was most recently
-# introduced in NSW, the "changeover" time on the Island has been 02:00 as
-# shown on clocks on LHI. I guess this means that for 30 minutes at the start
-# of DST, LHI is actually 1 hour ahead of the rest of NSW.
-
-# From Paul Eggert (2006-03-22):
-# For Lord Howe dates we use Shanks & Pottenger through 1989, and
-# Lonergan thereafter.  For times we use Lonergan.
-
-# From Paul Eggert (2007-07-23):
-# See "southeast Australia" above for 2008 and later.
-
-###############################################################################
-
-# New Zealand
-
-# From Mark Davies (1990-10-03):
-# the 1989/90 year was a trial of an extended "daylight saving" period.
-# This trial was deemed successful and the extended period adopted for
-# subsequent years (with the addition of a further week at the start).
-# source -- phone call to Ministry of Internal Affairs Head Office.
-
-# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06):
-# # The Country of New Zealand   (Australia's east island -) Gee they hate that!
-# #				   or is Australia the west island of N.Z.
-# #	[ courtesy of Geoff Tribble.. Auckland N.Z. ]
-# #				[ Nov 1990 ]
-# ...
-# Rule	NZ      1974    1988	-	Oct	lastSun	2:00	1:00	D
-# Rule	NZ	1989	max	-	Oct	Sun>=1	2:00	1:00	D
-# Rule	NZ      1975    1989	-	Mar	Sun>=1	3:00	0	S
-# Rule	NZ	1990	max	-	Mar	lastSun	3:00	0	S
-# ...
-# Zone	NZ			12:00	NZ		NZ%sT	# New Zealand
-# Zone	NZ-CHAT			12:45	-		NZ-CHAT # Chatham Island
-
-# From Arthur David Olson (1992-03-08):
-# The chosen rules use the Davies October 8 values for the start of DST in 1989
-# rather than the October 1 value.
-
-# From Paul Eggert (1995-12-19);
-# Shank & Pottenger report 2:00 for all autumn changes in Australia and NZ.
-# Robert Uzgalis writes that the New Zealand Daylight
-# Savings Time Order in Council dated 1990-06-18 specifies 2:00 standard
-# time on both the first Sunday in October and the third Sunday in March.
-# As with Australia, we'll assume the tradition is 2:00s, not 2:00.
-#
-# From Paul Eggert (2006-03-22):
-# The Department of Internal Affairs (DIA) maintains a brief history,
-# as does Carol Squires; see tz-link.htm for the full references.
-# Use these sources in preference to Shanks & Pottenger.
-#
-# For Chatham, IATA SSIM (1991/1999) gives the NZ rules but with
-# transitions at 2:45 local standard time; this confirms that Chatham
-# is always exactly 45 minutes ahead of Auckland.
-
-# From Colin Sharples (2007-04-30):
-# DST will now start on the last Sunday in September, and end on the
-# first Sunday in April.  The changes take effect this year, meaning
-# that DST will begin on 2007-09-30 2008-04-06.
-# http://www.dia.govt.nz/diawebsite.nsf/wpg_URL/Services-Daylight-Saving-Daylight-saving-to-be-extended
-
-###############################################################################
-
-
-# Fiji
-
-# Howse writes (p 153) that in 1879 the British governor of Fiji
-# enacted an ordinance standardizing the islands on Antipodean Time
-# instead of the American system (which was one day behind).
-
-# From Rives McDow (1998-10-08):
-# Fiji will introduce DST effective 0200 local time, 1998-11-01
-# until 0300 local time 1999-02-28.  Each year the DST period will
-# be from the first Sunday in November until the last Sunday in February.
-
-# From Paul Eggert (2000-01-08):
-# IATA SSIM (1999-09) says DST ends 0100 local time.  Go with McDow.
-
-# From the BBC World Service (1998-10-31 11:32 UTC):
-# The Fijiian government says the main reasons for the time change is to
-# improve productivity and reduce road accidents.  But correspondents say it
-# also hopes the move will boost Fiji's ability to compete with other pacific
-# islands in the effort to attract tourists to witness the dawning of the new
-# millenium.
-
-# http://www.fiji.gov.fj/press/2000_09/2000_09_13-05.shtml (2000-09-13)
-# reports that Fiji has discontinued DST.
-
-# Johnston
-
-# Johnston data is from usno1995.
-
-
-# Kiribati
-
-# From Paul Eggert (1996-01-22):
-# Today's _Wall Street Journal_ (page 1) reports that Kiribati
-# ``declared it the same day throught the country as of Jan. 1, 1995''
-# as part of the competition to be first into the 21st century.
-
-
-# Kwajalein
-
-# In comp.risks 14.87 (26 August 1993), Peter Neumann writes:
-# I wonder what happened in Kwajalein, where there was NO Friday,
-# 1993-08-20.  Thursday night at midnight Kwajalein switched sides with
-# respect to the International Date Line, to rejoin its fellow islands,
-# going from 11:59 p.m. Thursday to 12:00 m. Saturday in a blink.
-
-
-# N Mariana Is, Guam
-
-# Howse writes (p 153) ``The Spaniards, on the other hand, reached the
-# Philippines and the Ladrones from America,'' and implies that the Ladrones
-# (now called the Marianas) kept American date for quite some time.
-# For now, we assume the Ladrones switched at the same time as the Philippines;
-# see Asia/Manila.
-
-# US Public Law 106-564 (2000-12-23) made UTC+10 the official standard time,
-# under the name "Chamorro Standard Time".  There is no official abbreviation,
-# but Congressman Robert A. Underwood, author of the bill that became law,
-# wrote in a press release (2000-12-27) that he will seek the use of "ChST".
-
-
-# Micronesia
-
-# Alan Eugene Davis writes (1996-03-16),
-# ``I am certain, having lived there for the past decade, that "Truk"
-# (now properly known as Chuuk) ... is in the time zone GMT+10.''
-#
-# Shanks & Pottenger write that Truk switched from UTC+10 to UTC+11
-# on 1978-10-01; ignore this for now.
-
-# From Paul Eggert (1999-10-29):
-# The Federated States of Micronesia Visitors Board writes in
-# <a href="http://www.fsmgov.org/info/clocks.html">
-# The Federated States of Micronesia - Visitor Information
-# </a> (1999-01-26)
-# that Truk and Yap are UTC+10, and Ponape and Kosrae are UTC+11.
-# We don't know when Kosrae switched from UTC+12; assume January 1 for now.
-
-
-# Midway
-
-# From Charles T O'Connor, KMTH DJ (1956),
-# quoted in the KTMH section of the Radio Heritage Collection
-# <http://radiodx.com/spdxr/KMTH.htm> (2002-12-31):
-# For the past two months we've been on what is known as Daylight
-# Saving Time.  This time has put us on air at 5am in the morning,
-# your time down there in New Zealand.  Starting September 2, 1956
-# we'll again go back to Standard Time.  This'll mean that we'll go to
-# air at 6am your time.
-#
-# From Paul Eggert (2003-03-23):
-# We don't know the date of that quote, but we'll guess they
-# started DST on June 3.  Possibly DST was observed other years
-# in Midway, but we have no record of it.
-
-
-# Pitcairn
-
-# From Rives McDow (1999-11-08):
-# A Proclamation was signed by the Governor of Pitcairn on the 27th March 1998
-# with regard to Pitcairn Standard Time.  The Proclamation is as follows.
-#
-#	The local time for general purposes in the Islands shall be
-#	Co-ordinated Universal time minus 8 hours and shall be known
-#	as Pitcairn Standard Time.
-#
-# ... I have also seen Pitcairn listed as UTC minus 9 hours in several
-# references, and can only assume that this was an error in interpretation
-# somehow in light of this proclamation.
-
-# From Rives McDow (1999-11-09):
-# The Proclamation regarding Pitcairn time came into effect on 27 April 1998
-# ... at midnight.
-
-# From Howie Phelps (1999-11-10), who talked to a Pitcairner via shortwave:
-# Betty Christian told me yesterday that their local time is the same as
-# Pacific Standard Time. They used to be 1/2 hour different from us here in
-# Sacramento but it was changed a couple of years ago.
-
-
-# Samoa
-
-# Howse writes (p 153, citing p 10 of the 1883-11-18 New York Herald)
-# that in 1879 the King of Samoa decided to change
-# ``the date in his kingdom from the Antipodean to the American system,
-# ordaining -- by a masterpiece of diplomatic flattery -- that
-# the Fourth of July should be celebrated twice in that year.''
-
-
-# Tonga
-
-# From Paul Eggert (1996-01-22):
-# Today's _Wall Street Journal_ (p 1) reports that ``Tonga has been plotting
-# to sneak ahead of [New Zealanders] by introducing daylight-saving time.''
-# Since Kiribati has moved the Date Line it's not clear what Tonga will do.
-
-# Don Mundell writes in the 1997-02-20 Tonga Chronicle
-# <a href="http://www.tongatapu.net.to/tonga/homeland/timebegins.htm">
-# How Tonga became `The Land where Time Begins'
-# </a>:
-
-# Until 1941 Tonga maintained a standard time 50 minutes ahead of NZST
-# 12 hours and 20 minutes ahead of GMT.  When New Zealand adjusted its
-# standard time in 1940s, Tonga had the choice of subtracting from its
-# local time to come on the same standard time as New Zealand or of
-# advancing its time to maintain the differential of 13 degrees
-# (approximately 50 minutes ahead of New Zealand time).
-#
-# Because His Majesty King Taufa'ahau Tupou IV, then Crown Prince
-# Tungi, preferred to ensure Tonga's title as the land where time
-# begins, the Legislative Assembly approved the latter change.
-#
-# But some of the older, more conservative members from the outer
-# islands objected. "If at midnight on Dec. 31, we move ahead 40
-# minutes, as your Royal Highness wishes, what becomes of the 40
-# minutes we have lost?"
-#
-# The Crown Prince, presented an unanswerable argument: "Remember that
-# on the World Day of Prayer, you would be the first people on Earth
-# to say your prayers in the morning."
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say the transition was on 1968-10-01; go with Mundell.
-
-# From Eric Ulevik (1999-05-03):
-# Tonga's director of tourism, who is also secretary of the National Millenium
-# Committee, has a plan to get Tonga back in front.
-# He has proposed a one-off move to tropical daylight saving for Tonga from
-# October to March, which has won approval in principle from the Tongan
-# Government.
-
-# From Steffen Thorsen (1999-09-09):
-# * Tonga will introduce DST in November
-#
-# I was given this link by John Letts:
-# <a href="http://news.bbc.co.uk/hi/english/world/asia-pacific/newsid_424000/424764.stm">
-# http://news.bbc.co.uk/hi/english/world/asia-pacific/newsid_424000/424764.stm
-# </a>
-#
-# I have not been able to find exact dates for the transition in November
-# yet. By reading this article it seems like Fiji will be 14 hours ahead
-# of UTC as well, but as far as I know Fiji will only be 13 hours ahead
-# (12 + 1 hour DST).
-
-# From Arthur David Olson (1999-09-20):
-# According to <a href="http://www.tongaonline.com/news/sept1799.html">
-# http://www.tongaonline.com/news/sept1799.html
-# </a>:
-# "Daylight Savings Time will take effect on Oct. 2 through April 15, 2000
-# and annually thereafter from the first Saturday in October through the
-# third Saturday of April.  Under the system approved by Privy Council on
-# Sept. 10, clocks must be turned ahead one hour on the opening day and
-# set back an hour on the closing date."
-# Alas, no indication of the time of day.
-
-# From Rives McDow (1999-10-06):
-# Tonga started its Daylight Saving on Saturday morning October 2nd at 0200am.
-# Daylight Saving ends on April 16 at 0300am which is Sunday morning.
-
-# From Steffen Thorsen (2000-10-31):
-# Back in March I found a notice on the website http://www.tongaonline.com
-# that Tonga changed back to standard time one month early, on March 19
-# instead of the original reported date April 16. Unfortunately, the article
-# is no longer available on the site, and I did not make a copy of the
-# text, and I have forgotten to report it here.
-# (Original URL was: http://www.tongaonline.com/news/march162000.htm )
-
-# From Rives McDow (2000-12-01):
-# Tonga is observing DST as of 2000-11-04 and will stop on 2001-01-27.
-
-# From Sione Moala-Mafi (2001-09-20) via Rives McDow:
-# At 2:00am on the first Sunday of November, the standard time in the Kingdom
-# shall be moved forward by one hour to 3:00am.  At 2:00am on the last Sunday
-# of January the standard time in the Kingdom shall be moved backward by one
-# hour to 1:00am.
-
-# From Pulu 'Anau (2002-11-05):
-# The law was for 3 years, supposedly to get renewed.  It wasn't.
-
-
-# Wake
-
-# From Vernice Anderson, Personal Secretary to Philip Jessup,
-# US Ambassador At Large (oral history interview, 1971-02-02):
-#
-# Saturday, the 14th [of October, 1950] -- ...  The time was all the
-# more confusing at that point, because we had crossed the
-# International Date Line, thus getting two Sundays.  Furthermore, we
-# discovered that Wake Island had two hours of daylight saving time
-# making calculation of time in Washington difficult if not almost
-# impossible.
-#
-# http://www.trumanlibrary.org/wake/meeting.htm
-
-# From Paul Eggert (2003-03-23):
-# We have no other report of DST in Wake Island, so omit this info for now.
-
-###############################################################################
-
-# The International Date Line
-
-# From Gwillim Law (2000-01-03):
-#
-# The International Date Line is not defined by any international standard,
-# convention, or treaty.  Mapmakers are free to draw it as they please.
-# Reputable mapmakers will simply ensure that every point of land appears on
-# the correct side of the IDL, according to the date legally observed there.
-#
-# When Kiribati adopted a uniform date in 1995, thereby moving the Phoenix and
-# Line Islands to the west side of the IDL (or, if you prefer, moving the IDL
-# to the east side of the Phoenix and Line Islands), I suppose that most
-# mapmakers redrew the IDL following the boundary of Kiribati.  Even that line
-# has a rather arbitrary nature.  The straight-line boundaries between Pacific
-# island nations that are shown on many maps are based on an international
-# convention, but are not legally binding national borders.... The date is
-# governed by the IDL; therefore, even on the high seas, there may be some
-# places as late as fourteen hours later than UTC.  And, since the IDL is not
-# an international standard, there are some places on the high seas where the
-# correct date is ambiguous.
-
-# From Wikipedia <http://en.wikipedia.org/wiki/Time_zone> (2005-08-31):
-# Before 1920, all ships kept local apparent time on the high seas by setting
-# their clocks at night or at the morning sight so that, given the ship's
-# speed and direction, it would be 12 o'clock when the Sun crossed the ship's
-# meridian (12 o'clock = local apparent noon).  During 1917, at the
-# Anglo-French Conference on Time-keeping at Sea, it was recommended that all
-# ships, both military and civilian, should adopt hourly standard time zones
-# on the high seas.  Whenever a ship was within the territorial waters of any
-# nation it would use that nation's standard time.  The captain was permitted
-# to change his ship's clocks at a time of his choice following his ship's
-# entry into another zone time--he often chose midnight.  These zones were
-# adopted by all major fleets between 1920 and 1925 but not by many
-# independent merchant ships until World War II.
-
-# From Paul Eggert, using references suggested by Oscar van Vlijmen
-# (2005-03-20):
-#
-# The American Practical Navigator (2002)
-# <http://pollux.nss.nima.mil/pubs/pubs_j_apn_sections.html?rid=187>
-# talks only about the 180-degree meridian with respect to ships in
-# international waters; it ignores the international date line.
diff --git a/tools/zoneinfo/tzdata2008h/backward b/tools/zoneinfo/tzdata2008h/backward
deleted file mode 100644
index a65991c..0000000
--- a/tools/zoneinfo/tzdata2008h/backward
+++ /dev/null
@@ -1,112 +0,0 @@
-# @(#)backward	8.6
-
-# This file provides links between current names for time zones
-# and their old names.  Many names changed in late 1993.
-
-Link	Africa/Asmara		Africa/Asmera
-Link	Africa/Bamako		Africa/Timbuktu
-Link	America/Argentina/Catamarca	America/Argentina/ComodRivadavia
-Link	America/Adak		America/Atka
-Link	America/Argentina/Buenos_Aires	America/Buenos_Aires
-Link	America/Argentina/Catamarca	America/Catamarca
-Link	America/Atikokan	America/Coral_Harbour
-Link	America/Argentina/Cordoba	America/Cordoba
-Link	America/Tijuana		America/Ensenada
-Link	America/Indiana/Indianapolis	America/Fort_Wayne
-Link	America/Indiana/Indianapolis	America/Indianapolis
-Link	America/Argentina/Jujuy	America/Jujuy
-Link	America/Indiana/Knox	America/Knox_IN
-Link	America/Kentucky/Louisville	America/Louisville
-Link	America/Argentina/Mendoza	America/Mendoza
-Link	America/Rio_Branco	America/Porto_Acre
-Link	America/Argentina/Cordoba	America/Rosario
-Link	America/St_Thomas	America/Virgin
-Link	Asia/Ashgabat		Asia/Ashkhabad
-Link	Asia/Chongqing		Asia/Chungking
-Link	Asia/Dhaka		Asia/Dacca
-Link	Asia/Kolkata		Asia/Calcutta
-Link	Asia/Macau		Asia/Macao
-Link	Asia/Jerusalem		Asia/Tel_Aviv
-Link	Asia/Ho_Chi_Minh	Asia/Saigon
-Link	Asia/Thimphu		Asia/Thimbu
-Link	Asia/Makassar		Asia/Ujung_Pandang
-Link	Asia/Ulaanbaatar	Asia/Ulan_Bator
-Link	Atlantic/Faroe		Atlantic/Faeroe
-Link	Europe/Oslo		Atlantic/Jan_Mayen
-Link	Australia/Sydney	Australia/ACT
-Link	Australia/Sydney	Australia/Canberra
-Link	Australia/Lord_Howe	Australia/LHI
-Link	Australia/Sydney	Australia/NSW
-Link	Australia/Darwin	Australia/North
-Link	Australia/Brisbane	Australia/Queensland
-Link	Australia/Adelaide	Australia/South
-Link	Australia/Hobart	Australia/Tasmania
-Link	Australia/Melbourne	Australia/Victoria
-Link	Australia/Perth		Australia/West
-Link	Australia/Broken_Hill	Australia/Yancowinna
-Link	America/Rio_Branco	Brazil/Acre
-Link	America/Noronha		Brazil/DeNoronha
-Link	America/Sao_Paulo	Brazil/East
-Link	America/Manaus		Brazil/West
-Link	America/Halifax		Canada/Atlantic
-Link	America/Winnipeg	Canada/Central
-Link	America/Regina		Canada/East-Saskatchewan
-Link	America/Toronto		Canada/Eastern
-Link	America/Edmonton	Canada/Mountain
-Link	America/St_Johns	Canada/Newfoundland
-Link	America/Vancouver	Canada/Pacific
-Link	America/Regina		Canada/Saskatchewan
-Link	America/Whitehorse	Canada/Yukon
-Link	America/Santiago	Chile/Continental
-Link	Pacific/Easter		Chile/EasterIsland
-Link	America/Havana		Cuba
-Link	Africa/Cairo		Egypt
-Link	Europe/Dublin		Eire
-Link	Europe/London		Europe/Belfast
-Link	Europe/Chisinau		Europe/Tiraspol
-Link	Europe/London		GB
-Link	Europe/London		GB-Eire
-Link	Etc/GMT			GMT+0
-Link	Etc/GMT			GMT-0
-Link	Etc/GMT			GMT0
-Link	Etc/GMT			Greenwich
-Link	Asia/Hong_Kong		Hongkong
-Link	Atlantic/Reykjavik	Iceland
-Link	Asia/Tehran		Iran
-Link	Asia/Jerusalem		Israel
-Link	America/Jamaica		Jamaica
-Link	Asia/Tokyo		Japan
-Link	Pacific/Kwajalein	Kwajalein
-Link	Africa/Tripoli		Libya
-Link	America/Tijuana		Mexico/BajaNorte
-Link	America/Mazatlan	Mexico/BajaSur
-Link	America/Mexico_City	Mexico/General
-Link	Pacific/Auckland	NZ
-Link	Pacific/Chatham		NZ-CHAT
-Link	America/Denver		Navajo
-Link	Asia/Shanghai		PRC
-Link	Pacific/Pago_Pago	Pacific/Samoa
-Link	Pacific/Truk		Pacific/Yap
-Link	Europe/Warsaw		Poland
-Link	Europe/Lisbon		Portugal
-Link	Asia/Taipei		ROC
-Link	Asia/Seoul		ROK
-Link	Asia/Singapore		Singapore
-Link	Europe/Istanbul		Turkey
-Link	Etc/UCT			UCT
-Link	America/Anchorage	US/Alaska
-Link	America/Adak		US/Aleutian
-Link	America/Phoenix		US/Arizona
-Link	America/Chicago		US/Central
-Link	America/Indiana/Indianapolis	US/East-Indiana
-Link	America/New_York	US/Eastern
-Link	Pacific/Honolulu	US/Hawaii
-Link	America/Indiana/Knox	US/Indiana-Starke
-Link	America/Detroit		US/Michigan
-Link	America/Denver		US/Mountain
-Link	America/Los_Angeles	US/Pacific
-Link	Pacific/Pago_Pago	US/Samoa
-Link	Etc/UTC			UTC
-Link	Etc/UTC			Universal
-Link	Europe/Moscow		W-SU
-Link	Etc/UTC			Zulu
diff --git a/tools/zoneinfo/tzdata2008h/etcetera b/tools/zoneinfo/tzdata2008h/etcetera
deleted file mode 100644
index cddbe8a..0000000
--- a/tools/zoneinfo/tzdata2008h/etcetera
+++ /dev/null
@@ -1,80 +0,0 @@
-# @(#)etcetera	8.1
-
-# These entries are mostly present for historical reasons, so that
-# people in areas not otherwise covered by the tz files could "zic -l"
-# to a time zone that was right for their area.  These days, the
-# tz files cover almost all the inhabited world, and the only practical
-# need now for the entries that are not on UTC are for ships at sea
-# that cannot use POSIX TZ settings.
-
-Zone	Etc/GMT		0	-	GMT
-Zone	Etc/UTC		0	-	UTC
-Zone	Etc/UCT		0	-	UCT
-
-# The following link uses older naming conventions,
-# but it belongs here, not in the file `backward',
-# as functions like gmtime load the "GMT" file to handle leap seconds properly.
-# We want this to work even on installations that omit the other older names.
-Link	Etc/GMT				GMT
-
-Link	Etc/UTC				Etc/Universal
-Link	Etc/UTC				Etc/Zulu
-
-Link	Etc/GMT				Etc/Greenwich
-Link	Etc/GMT				Etc/GMT-0
-Link	Etc/GMT				Etc/GMT+0
-Link	Etc/GMT				Etc/GMT0
-
-# We use POSIX-style signs in the Zone names and the output abbreviations,
-# even though this is the opposite of what many people expect.
-# POSIX has positive signs west of Greenwich, but many people expect
-# positive signs east of Greenwich.  For example, TZ='Etc/GMT+4' uses
-# the abbreviation "GMT+4" and corresponds to 4 hours behind UTC
-# (i.e. west of Greenwich) even though many people would expect it to
-# mean 4 hours ahead of UTC (i.e. east of Greenwich).
-#
-# In the draft 5 of POSIX 1003.1-200x, the angle bracket notation
-# (which is not yet supported by the tz code) allows for
-# TZ='<GMT-4>+4'; if you want time zone abbreviations conforming to
-# ISO 8601 you can use TZ='<-0400>+4'.  Thus the commonly-expected
-# offset is kept within the angle bracket (and is used for display)
-# while the POSIX sign is kept outside the angle bracket (and is used
-# for calculation).
-#
-# Do not use a TZ setting like TZ='GMT+4', which is four hours behind
-# GMT but uses the completely misleading abbreviation "GMT".
-
-# Earlier incarnations of this package were not POSIX-compliant,
-# and had lines such as
-#		Zone	GMT-12		-12	-	GMT-1200
-# We did not want things to change quietly if someone accustomed to the old
-# way does a
-#		zic -l GMT-12
-# so we moved the names into the Etc subdirectory.
-
-Zone	Etc/GMT-14	14	-	GMT-14	# 14 hours ahead of GMT
-Zone	Etc/GMT-13	13	-	GMT-13
-Zone	Etc/GMT-12	12	-	GMT-12
-Zone	Etc/GMT-11	11	-	GMT-11
-Zone	Etc/GMT-10	10	-	GMT-10
-Zone	Etc/GMT-9	9	-	GMT-9
-Zone	Etc/GMT-8	8	-	GMT-8
-Zone	Etc/GMT-7	7	-	GMT-7
-Zone	Etc/GMT-6	6	-	GMT-6
-Zone	Etc/GMT-5	5	-	GMT-5
-Zone	Etc/GMT-4	4	-	GMT-4
-Zone	Etc/GMT-3	3	-	GMT-3
-Zone	Etc/GMT-2	2	-	GMT-2
-Zone	Etc/GMT-1	1	-	GMT-1
-Zone	Etc/GMT+1	-1	-	GMT+1
-Zone	Etc/GMT+2	-2	-	GMT+2
-Zone	Etc/GMT+3	-3	-	GMT+3
-Zone	Etc/GMT+4	-4	-	GMT+4
-Zone	Etc/GMT+5	-5	-	GMT+5
-Zone	Etc/GMT+6	-6	-	GMT+6
-Zone	Etc/GMT+7	-7	-	GMT+7
-Zone	Etc/GMT+8	-8	-	GMT+8
-Zone	Etc/GMT+9	-9	-	GMT+9
-Zone	Etc/GMT+10	-10	-	GMT+10
-Zone	Etc/GMT+11	-11	-	GMT+11
-Zone	Etc/GMT+12	-12	-	GMT+12
diff --git a/tools/zoneinfo/tzdata2008h/europe b/tools/zoneinfo/tzdata2008h/europe
deleted file mode 100644
index 7bb9864..0000000
--- a/tools/zoneinfo/tzdata2008h/europe
+++ /dev/null
@@ -1,2594 +0,0 @@
-# @(#)europe	8.18
-# <pre>
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (2006-03-22):
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1991, and IATA SSIM is the source for entries afterwards.
-#
-# Other sources occasionally used include:
-#
-#	Edward W. Whitman, World Time Differences,
-#	Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated),
-#	which I found in the UCLA library.
-#
-#	<a href="http://www.pettswoodvillage.co.uk/Daylight_Savings_William_Willett.pdf">
-#	William Willett, The Waste of Daylight, 19th edition
-#	</a> (1914-03)
-#
-#	Brazil's Departamento Servico da Hora (DSH),
-#	<a href="http://pcdsh01.on.br/HISTHV.htm">
-#	History of Summer Time
-#	</a> (1998-09-21, in Portuguese)
-
-#
-# I invented the abbreviations marked `*' in the following table;
-# the rest are from earlier versions of this file, or from other sources.
-# Corrections are welcome!
-#                   std dst  2dst
-#                   LMT           Local Mean Time
-#       -4:00       AST ADT       Atlantic
-#       -3:00       WGT WGST      Western Greenland*
-#       -1:00       EGT EGST      Eastern Greenland*
-#        0:00       GMT BST  BDST Greenwich, British Summer
-#        0:00       GMT IST       Greenwich, Irish Summer
-#        0:00       WET WEST WEMT Western Europe
-#        0:19:32.13 AMT NST       Amsterdam, Netherlands Summer (1835-1937)*
-#        0:20       NET NEST      Netherlands (1937-1940)*
-#        1:00       CET CEST CEMT Central Europe
-#        1:00:14    SET           Swedish (1879-1899)*
-#        2:00       EET EEST      Eastern Europe
-#        3:00       MSK MSD       Moscow
-#
-# A reliable and entertaining source about time zones, especially in Britain,
-# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997).
-
-# From Peter Ilieve (1994-12-04),
-# The original six [EU members]: Belgium, France, (West) Germany, Italy,
-# Luxembourg, the Netherlands.
-# Plus, from 1 Jan 73: Denmark, Ireland, United Kingdom.
-# Plus, from 1 Jan 81: Greece.
-# Plus, from 1 Jan 86: Spain, Portugal.
-# Plus, from 1 Jan 95: Austria, Finland, Sweden. (Norway negotiated terms for
-# entry but in a referendum on 28 Nov 94 the people voted No by 52.2% to 47.8%
-# on a turnout of 88.6%. This was almost the same result as Norway's previous
-# referendum in 1972, they are the only country to have said No twice.
-# Referendums in the other three countries voted Yes.)
-# ...
-# Estonia ... uses EU dates but not at 01:00 GMT, they use midnight GMT.
-# I don't think they know yet what they will do from 1996 onwards.
-# ...
-# There shouldn't be any [current members who are not using EU rules].
-# A Directive has the force of law, member states are obliged to enact
-# national law to implement it. The only contentious issue was the
-# different end date for the UK and Ireland, and this was always allowed
-# in the Directive.
-
-
-###############################################################################
-
-# Britain (United Kingdom) and Ireland (Eire)
-
-# From Peter Ilieve (1994-07-06):
-#
-# On 17 Jan 1994 the Independent, a UK quality newspaper, had a piece about
-# historical vistas along the Thames in west London. There was a photo
-# and a sketch map showing some of the sightlines involved. One paragraph
-# of the text said:
-#
-# `An old stone obelisk marking a forgotten terrestrial meridian stands
-# beside the river at Kew. In the 18th century, before time and longitude
-# was standardised by the Royal Observatory in Greenwich, scholars observed
-# this stone and the movement of stars from Kew Observatory nearby. They
-# made their calculations and set the time for the Horse Guards and Parliament,
-# but now the stone is obscured by scrubwood and can only be seen by walking
-# along the towpath within a few yards of it.'
-#
-# I have a one inch to one mile map of London and my estimate of the stone's
-# position is 51 deg. 28' 30" N, 0 deg. 18' 45" W. The longitude should
-# be within about +-2". The Ordnance Survey grid reference is TQ172761.
-#
-# [This yields GMTOFF = -0:01:15 for London LMT in the 18th century.]
-
-# From Paul Eggert (1993-11-18):
-#
-# Howse writes that Britain was the first country to use standard time.
-# The railways cared most about the inconsistencies of local mean time,
-# and it was they who forced a uniform time on the country.
-# The original idea was credited to Dr. William Hyde Wollaston (1766-1828)
-# and was popularized by Abraham Follett Osler (1808-1903).
-# The first railway to adopt London time was the Great Western Railway
-# in November 1840; other railways followed suit, and by 1847 most
-# (though not all) railways used London time.  On 1847-09-22 the
-# Railway Clearing House, an industry standards body, recommended that GMT be
-# adopted at all stations as soon as the General Post Office permitted it.
-# The transition occurred on 12-01 for the L&NW, the Caledonian,
-# and presumably other railways; the January 1848 Bradshaw's lists many
-# railways as using GMT.  By 1855 the vast majority of public
-# clocks in Britain were set to GMT (though some, like the great clock
-# on Tom Tower at Christ Church, Oxford, were fitted with two minute hands,
-# one for local time and one for GMT).  The last major holdout was the legal
-# system, which stubbornly stuck to local time for many years, leading
-# to oddities like polls opening at 08:13 and closing at 16:13.
-# The legal system finally switched to GMT when the Statutes (Definition
-# of Time) Act took effect; it received the Royal Assent on 1880-08-02.
-#
-# In the tables below, we condense this complicated story into a single
-# transition date for London, namely 1847-12-01.  We don't know as much
-# about Dublin, so we use 1880-08-02, the legal transition time.
-
-# From Paul Eggert (2003-09-27):
-# Summer Time was first seriously proposed by William Willett (1857-1915),
-# a London builder and member of the Royal Astronomical Society
-# who circulated a pamphlet ``The Waste of Daylight'' (1907)
-# that proposed advancing clocks 20 minutes on each of four Sundays in April,
-# and retarding them by the same amount on four Sundays in September.
-# A bill was drafted in 1909 and introduced in Parliament several times,
-# but it met with ridicule and opposition, especially from farming interests.
-# Later editions of the pamphlet proposed one-hour summer time, and
-# it was eventually adopted as a wartime measure in 1916.
-# See: Summer Time Arrives Early, The Times (2000-05-18).
-# A monument to Willett was unveiled on 1927-05-21, in an open space in
-# a 45-acre wood near Chislehurst, Kent that was purchased by popular
-# subscription and open to the public.  On the south face of the monolith,
-# designed by G. W. Miller, is the the William Willett Memorial Sundial,
-# which is permanently set to Summer Time.
-
-# From Winston Churchill (1934-04-28):
-# It is one of the paradoxes of history that we should owe the boon of
-# summer time, which gives every year to the people of this country
-# between 160 and 170 hours more daylight leisure, to a war which
-# plunged Europe into darkness for four years, and shook the
-# foundations of civilization throughout the world.
-#	-- <a href="http://www.winstonchurchill.org/fh114willett.htm">
-#	"A Silent Toast to William Willett", Pictorial Weekly
-#	</a>
-
-# From Paul Eggert (1996-09-03):
-# The OED Supplement says that the English originally said ``Daylight Saving''
-# when they were debating the adoption of DST in 1908; but by 1916 this
-# term appears only in quotes taken from DST's opponents, whereas the
-# proponents (who eventually won the argument) are quoted as using ``Summer''.
-
-# From Arthur David Olson (1989-01-19):
-#
-# A source at the British Information Office in New York avers that it's
-# known as "British" Summer Time in all parts of the United Kingdom.
-
-# Date: 4 Jan 89 08:57:25 GMT (Wed)
-# From: Jonathan Leffler
-# [British Summer Time] is fixed annually by Act of Parliament.
-# If you can predict what Parliament will do, you should be in
-# politics making a fortune, not computing.
-
-# From Chris Carrier (1996-06-14):
-# I remember reading in various wartime issues of the London Times the
-# acronym BDST for British Double Summer Time.  Look for the published
-# time of sunrise and sunset in The Times, when BDST was in effect, and
-# if you find a zone reference it will say, "All times B.D.S.T."
-
-# From Joseph S. Myers (1999-09-02):
-# ... some military cables (WO 219/4100 - this is a copy from the
-# main SHAEF archives held in the US National Archives, SHAEF/5252/8/516)
-# agree that the usage is BDST (this appears in a message dated 17 Feb 1945).
-
-# From Joseph S. Myers (2000-10-03):
-# On 18th April 1941, Sir Stephen Tallents of the BBC wrote to Sir
-# Alexander Maxwell of the Home Office asking whether there was any
-# official designation; the reply of the 21st was that there wasn't
-# but he couldn't think of anything better than the "Double British
-# Summer Time" that the BBC had been using informally.
-# http://student.cusu.cam.ac.uk/~jsm28/british-time/bbc-19410418.png
-# http://student.cusu.cam.ac.uk/~jsm28/british-time/ho-19410421.png
-
-# From Sir Alexander Maxwell in the above-mentioned letter (1941-04-21):
-# [N]o official designation has as far as I know been adopted for the time
-# which is to be introduced in May....
-# I cannot think of anything better than "Double British Summer Time"
-# which could not be said to run counter to any official description.
-
-# From Paul Eggert (2000-10-02):
-# Howse writes (p 157) `DBST' too, but `BDST' seems to have been common
-# and follows the more usual convention of putting the location name first,
-# so we use `BDST'.
-
-# Peter Ilieve (1998-04-19) described at length
-# the history of summer time legislation in the United Kingdom.
-# Since 1998 Joseph S. Myers has been updating
-# and extending this list, which can be found in
-# <a href="http://student.cusu.cam.ac.uk/~jsm28/british-time/">
-# History of legal time in Britain
-# </a>
-
-# From Joseph S. Myers (1998-01-06):
-#
-# The legal time in the UK outside of summer time is definitely GMT, not UTC;
-# see Lord Tanlaw's speech
-# <a href="http://www.parliament.the-stationery-office.co.uk/pa/ld199697/ldhansrd/pdvn/lds97/text/70611-20.htm#70611-20_head0">
-# (Lords Hansard 11 June 1997 columns 964 to 976)
-# </a>.
-
-# From Paul Eggert (2006-03-22):
-#
-# For lack of other data, follow Shanks & Pottenger for Eire in 1940-1948.
-#
-# Given Ilieve and Myers's data, the following claims by Shanks & Pottenger
-# are incorrect:
-#     * Wales did not switch from GMT to daylight saving time until
-#	1921 Apr 3, when they began to conform with the rest of Great Britain.
-# Actually, Wales was identical after 1880.
-#     * Eire had two transitions on 1916 Oct 1.
-# It actually just had one transition.
-#     * Northern Ireland used single daylight saving time throughout WW II.
-# Actually, it conformed to Britain.
-#     * GB-Eire changed standard time to 1 hour ahead of GMT on 1968-02-18.
-# Actually, that date saw the usual switch to summer time.
-# Standard time was not changed until 1968-10-27 (the clocks didn't change).
-#
-# Here is another incorrect claim by Shanks & Pottenger:
-#     * Jersey, Guernsey, and the Isle of Man did not switch from GMT
-#	to daylight saving time until 1921 Apr 3, when they began to
-#	conform with Great Britain.
-# S.R.&O. 1916, No. 382 and HO 45/10811/312364 (quoted above) say otherwise.
-#
-# The following claim by Shanks & Pottenger is possible though doubtful;
-# we'll ignore it for now.
-#     * Dublin's 1971-10-31 switch was at 02:00, even though London's was 03:00.
-#
-#
-# Whitman says Dublin Mean Time was -0:25:21, which is more precise than
-# Shanks & Pottenger.
-# Perhaps this was Dunsink Observatory Time, as Dunsink Observatory
-# (8 km NW of Dublin's center) seemingly was to Dublin as Greenwich was
-# to London.  For example:
-#
-#   "Timeball on the ballast office is down.  Dunsink time."
-#   -- James Joyce, Ulysses
-
-# From Joseph S. Myers (2005-01-26):
-# Irish laws are available online at www.irishstatutebook.ie.  These include
-# various relating to legal time, for example:
-#
-# ZZA13Y1923.html ZZA12Y1924.html ZZA8Y1925.html ZZSIV20PG1267.html
-#
-# ZZSI71Y1947.html ZZSI128Y1948.html ZZSI23Y1949.html ZZSI41Y1950.html
-# ZZSI27Y1951.html ZZSI73Y1952.html
-#
-# ZZSI11Y1961.html ZZSI232Y1961.html ZZSI182Y1962.html
-# ZZSI167Y1963.html ZZSI257Y1964.html ZZSI198Y1967.html
-# ZZA23Y1968.html ZZA17Y1971.html
-#
-# ZZSI67Y1981.html ZZSI212Y1982.html ZZSI45Y1986.html
-# ZZSI264Y1988.html ZZSI52Y1990.html ZZSI371Y1992.html
-# ZZSI395Y1994.html ZZSI484Y1997.html ZZSI506Y2001.html
-#
-# [These are all relative to the root, e.g., the first is
-# <http://www.irishstatutebook.ie/ZZA13Y1923.html>.]
-#
-# (These are those I found, but there could be more.  In any case these
-# should allow various updates to the comments in the europe file to cover
-# the laws applicable in Ireland.)
-#
-# (Note that the time in the Republic of Ireland since 1968 has been defined
-# in terms of standard time being GMT+1 with a period of winter time when it
-# is GMT, rather than standard time being GMT with a period of summer time
-# being GMT+1.)
-
-# From Paul Eggert (1999-03-28):
-# Clive Feather (<news:859845706.26043.0@office.demon.net>, 1997-03-31)
-# reports that Folkestone (Cheriton) Shuttle Terminal uses Concession Time
-# (CT), equivalent to French civil time.
-# Julian Hill (<news:36118128.5A14@virgin.net>, 1998-09-30) reports that
-# trains between Dollands Moor (the freight facility next door)
-# and Frethun run in CT.
-# My admittedly uninformed guess is that the terminal has two authorities,
-# the French concession operators and the British civil authorities,
-# and that the time depends on who you're talking to.
-# If, say, the British police were called to the station for some reason,
-# I would expect the official police report to use GMT/BST and not CET/CEST.
-# This is a borderline case, but for now let's stick to GMT/BST.
-
-# From an anonymous contributor (1996-06-02):
-# The law governing time in Ireland is under Statutory Instrument SI 395/94,
-# which gives force to European Union 7th Council Directive # 94/21/EC.
-# Under this directive, the Minister for Justice in Ireland makes appropriate
-# regulations. I spoke this morning with the Secretary of the Department of
-# Justice (tel +353 1 678 9711) who confirmed to me that the correct name is
-# "Irish Summer Time", abbreviated to "IST".
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Summer Time Act, 1916
-Rule	GB-Eire	1916	only	-	May	21	2:00s	1:00	BST
-Rule	GB-Eire	1916	only	-	Oct	 1	2:00s	0	GMT
-# S.R.&O. 1917, No. 358
-Rule	GB-Eire	1917	only	-	Apr	 8	2:00s	1:00	BST
-Rule	GB-Eire	1917	only	-	Sep	17	2:00s	0	GMT
-# S.R.&O. 1918, No. 274
-Rule	GB-Eire	1918	only	-	Mar	24	2:00s	1:00	BST
-Rule	GB-Eire	1918	only	-	Sep	30	2:00s	0	GMT
-# S.R.&O. 1919, No. 297
-Rule	GB-Eire	1919	only	-	Mar	30	2:00s	1:00	BST
-Rule	GB-Eire	1919	only	-	Sep	29	2:00s	0	GMT
-# S.R.&O. 1920, No. 458
-Rule	GB-Eire	1920	only	-	Mar	28	2:00s	1:00	BST
-# S.R.&O. 1920, No. 1844
-Rule	GB-Eire	1920	only	-	Oct	25	2:00s	0	GMT
-# S.R.&O. 1921, No. 363
-Rule	GB-Eire	1921	only	-	Apr	 3	2:00s	1:00	BST
-Rule	GB-Eire	1921	only	-	Oct	 3	2:00s	0	GMT
-# S.R.&O. 1922, No. 264
-Rule	GB-Eire	1922	only	-	Mar	26	2:00s	1:00	BST
-Rule	GB-Eire	1922	only	-	Oct	 8	2:00s	0	GMT
-# The Summer Time Act, 1922
-Rule	GB-Eire	1923	only	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1923	1924	-	Sep	Sun>=16	2:00s	0	GMT
-Rule	GB-Eire	1924	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1925	1926	-	Apr	Sun>=16	2:00s	1:00	BST
-# The Summer Time Act, 1925
-Rule	GB-Eire	1925	1938	-	Oct	Sun>=2	2:00s	0	GMT
-Rule	GB-Eire	1927	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1928	1929	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1930	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1931	1932	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1933	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1934	only	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1935	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1936	1937	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1938	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1939	only	-	Apr	Sun>=16	2:00s	1:00	BST
-# S.R.&O. 1939, No. 1379
-Rule	GB-Eire	1939	only	-	Nov	Sun>=16	2:00s	0	GMT
-# S.R.&O. 1940, No. 172 and No. 1883
-Rule	GB-Eire	1940	only	-	Feb	Sun>=23	2:00s	1:00	BST
-# S.R.&O. 1941, No. 476
-Rule	GB-Eire	1941	only	-	May	Sun>=2	1:00s	2:00	BDST
-Rule	GB-Eire	1941	1943	-	Aug	Sun>=9	1:00s	1:00	BST
-# S.R.&O. 1942, No. 506
-Rule	GB-Eire	1942	1944	-	Apr	Sun>=2	1:00s	2:00	BDST
-# S.R.&O. 1944, No. 932
-Rule	GB-Eire	1944	only	-	Sep	Sun>=16	1:00s	1:00	BST
-# S.R.&O. 1945, No. 312
-Rule	GB-Eire	1945	only	-	Apr	Mon>=2	1:00s	2:00	BDST
-Rule	GB-Eire	1945	only	-	Jul	Sun>=9	1:00s	1:00	BST
-# S.R.&O. 1945, No. 1208
-Rule	GB-Eire	1945	1946	-	Oct	Sun>=2	2:00s	0	GMT
-Rule	GB-Eire	1946	only	-	Apr	Sun>=9	2:00s	1:00	BST
-# The Summer Time Act, 1947
-Rule	GB-Eire	1947	only	-	Mar	16	2:00s	1:00	BST
-Rule	GB-Eire	1947	only	-	Apr	13	1:00s	2:00	BDST
-Rule	GB-Eire	1947	only	-	Aug	10	1:00s	1:00	BST
-Rule	GB-Eire	1947	only	-	Nov	 2	2:00s	0	GMT
-# Summer Time Order, 1948 (S.I. 1948/495)
-Rule	GB-Eire	1948	only	-	Mar	14	2:00s	1:00	BST
-Rule	GB-Eire	1948	only	-	Oct	31	2:00s	0	GMT
-# Summer Time Order, 1949 (S.I. 1949/373)
-Rule	GB-Eire	1949	only	-	Apr	 3	2:00s	1:00	BST
-Rule	GB-Eire	1949	only	-	Oct	30	2:00s	0	GMT
-# Summer Time Order, 1950 (S.I. 1950/518)
-# Summer Time Order, 1951 (S.I. 1951/430)
-# Summer Time Order, 1952 (S.I. 1952/451)
-Rule	GB-Eire	1950	1952	-	Apr	Sun>=14	2:00s	1:00	BST
-Rule	GB-Eire	1950	1952	-	Oct	Sun>=21	2:00s	0	GMT
-# revert to the rules of the Summer Time Act, 1925
-Rule	GB-Eire	1953	only	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1953	1960	-	Oct	Sun>=2	2:00s	0	GMT
-Rule	GB-Eire	1954	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1955	1956	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1957	only	-	Apr	Sun>=9	2:00s	1:00	BST
-Rule	GB-Eire	1958	1959	-	Apr	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1960	only	-	Apr	Sun>=9	2:00s	1:00	BST
-# Summer Time Order, 1961 (S.I. 1961/71)
-# Summer Time (1962) Order, 1961 (S.I. 1961/2465)
-# Summer Time Order, 1963 (S.I. 1963/81)
-Rule	GB-Eire	1961	1963	-	Mar	lastSun	2:00s	1:00	BST
-Rule	GB-Eire	1961	1968	-	Oct	Sun>=23	2:00s	0	GMT
-# Summer Time (1964) Order, 1963 (S.I. 1963/2101)
-# Summer Time Order, 1964 (S.I. 1964/1201)
-# Summer Time Order, 1967 (S.I. 1967/1148)
-Rule	GB-Eire	1964	1967	-	Mar	Sun>=19	2:00s	1:00	BST
-# Summer Time Order, 1968 (S.I. 1968/117)
-Rule	GB-Eire	1968	only	-	Feb	18	2:00s	1:00	BST
-# The British Standard Time Act, 1968
-#	(no summer time)
-# The Summer Time Act, 1972
-Rule	GB-Eire	1972	1980	-	Mar	Sun>=16	2:00s	1:00	BST
-Rule	GB-Eire	1972	1980	-	Oct	Sun>=23	2:00s	0	GMT
-# Summer Time Order, 1980 (S.I. 1980/1089)
-# Summer Time Order, 1982 (S.I. 1982/1673)
-# Summer Time Order, 1986 (S.I. 1986/223)
-# Summer Time Order, 1988 (S.I. 1988/931)
-Rule	GB-Eire	1981	1995	-	Mar	lastSun	1:00u	1:00	BST
-Rule	GB-Eire 1981	1989	-	Oct	Sun>=23	1:00u	0	GMT
-# Summer Time Order, 1989 (S.I. 1989/985)
-# Summer Time Order, 1992 (S.I. 1992/1729)
-# Summer Time Order 1994 (S.I. 1994/2798)
-Rule	GB-Eire 1990	1995	-	Oct	Sun>=22	1:00u	0	GMT
-# Summer Time Order 1997 (S.I. 1997/2982)
-# See EU for rules starting in 1996.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/London	-0:01:15 -	LMT	1847 Dec  1 0:00s
-			 0:00	GB-Eire	%s	1968 Oct 27
-			 1:00	-	BST	1971 Oct 31 2:00u
-			 0:00	GB-Eire	%s	1996
-			 0:00	EU	GMT/BST
-Link	Europe/London	Europe/Jersey
-Link	Europe/London	Europe/Guernsey
-Link	Europe/London	Europe/Isle_of_Man
-Zone	Europe/Dublin	-0:25:00 -	LMT	1880 Aug  2
-			-0:25:21 -	DMT	1916 May 21 2:00
-			-0:25:21 1:00	IST	1916 Oct  1 2:00s
-			 0:00	GB-Eire	%s	1921 Dec  6 # independence
-			 0:00	GB-Eire	GMT/IST	1940 Feb 25 2:00
-			 0:00	1:00	IST	1946 Oct  6 2:00
-			 0:00	-	GMT	1947 Mar 16 2:00
-			 0:00	1:00	IST	1947 Nov  2 2:00
-			 0:00	-	GMT	1948 Apr 18 2:00
-			 0:00	GB-Eire	GMT/IST	1968 Oct 27
-			 1:00	-	IST	1971 Oct 31 2:00u
-			 0:00	GB-Eire	GMT/IST	1996
-			 0:00	EU	GMT/IST
-
-###############################################################################
-
-# Europe
-
-# EU rules are for the European Union, previously known as the EC, EEC,
-# Common Market, etc.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	EU	1977	1980	-	Apr	Sun>=1	 1:00u	1:00	S
-Rule	EU	1977	only	-	Sep	lastSun	 1:00u	0	-
-Rule	EU	1978	only	-	Oct	 1	 1:00u	0	-
-Rule	EU	1979	1995	-	Sep	lastSun	 1:00u	0	-
-Rule	EU	1981	max	-	Mar	lastSun	 1:00u	1:00	S
-Rule	EU	1996	max	-	Oct	lastSun	 1:00u	0	-
-# The most recent directive covers the years starting in 2002.  See:
-# <a href="http://europa.eu.int/eur-lex/en/lif/dat/2000/en_300L0084.html">
-# Directive 2000/84/EC of the European Parliament and of the Council
-# of 19 January 2001 on summer-time arrangements.
-# </a>
-
-# W-Eur differs from EU only in that W-Eur uses standard time.
-Rule	W-Eur	1977	1980	-	Apr	Sun>=1	 1:00s	1:00	S
-Rule	W-Eur	1977	only	-	Sep	lastSun	 1:00s	0	-
-Rule	W-Eur	1978	only	-	Oct	 1	 1:00s	0	-
-Rule	W-Eur	1979	1995	-	Sep	lastSun	 1:00s	0	-
-Rule	W-Eur	1981	max	-	Mar	lastSun	 1:00s	1:00	S
-Rule	W-Eur	1996	max	-	Oct	lastSun	 1:00s	0	-
-
-# Older C-Eur rules are for convenience in the tables.
-# From 1977 on, C-Eur differs from EU only in that C-Eur uses standard time.
-Rule	C-Eur	1916	only	-	Apr	30	23:00	1:00	S
-Rule	C-Eur	1916	only	-	Oct	 1	 1:00	0	-
-Rule	C-Eur	1917	1918	-	Apr	Mon>=15	 2:00s	1:00	S
-Rule	C-Eur	1917	1918	-	Sep	Mon>=15	 2:00s	0	-
-Rule	C-Eur	1940	only	-	Apr	 1	 2:00s	1:00	S
-Rule	C-Eur	1942	only	-	Nov	 2	 2:00s	0	-
-Rule	C-Eur	1943	only	-	Mar	29	 2:00s	1:00	S
-Rule	C-Eur	1943	only	-	Oct	 4	 2:00s	0	-
-Rule	C-Eur	1944	1945	-	Apr	Mon>=1	 2:00s	1:00	S
-# Whitman gives 1944 Oct 7; go with Shanks & Pottenger.
-Rule	C-Eur	1944	only	-	Oct	 2	 2:00s	0	-
-# From Jesper Norgaard Welen (2008-07-13):
-#
-# I found what is probably a typo of 2:00 which should perhaps be 2:00s
-# in the C-Eur rule from tz database version 2008d (this part was
-# corrected in version 2008d). The circumstancial evidence is simply the
-# tz database itself, as seen below:
-#
-# Zone Europe/Paris 0:09:21 - LMT 1891 Mar 15  0:01
-#    0:00 France WE%sT 1945 Sep 16  3:00
-#
-# Zone Europe/Monaco 0:29:32 - LMT 1891 Mar 15
-#    0:00 France WE%sT 1945 Sep 16 3:00
-#
-# Zone Europe/Belgrade 1:22:00 - LMT 1884
-#    1:00 1:00 CEST 1945 Sep 16  2:00s
-#
-# Rule France 1945 only - Sep 16  3:00 0 -
-# Rule Belgium 1945 only - Sep 16  2:00s 0 -
-# Rule Neth 1945 only - Sep 16 2:00s 0 -
-#
-# The rule line to be changed is:
-#
-# Rule C-Eur 1945 only - Sep 16  2:00 0 -
-#
-# It seems that Paris, Monaco, Rule France, Rule Belgium all agree on
-# 2:00 standard time, e.g. 3:00 local time.  However there are no
-# countries that use C-Eur rules in September 1945, so the only items
-# affected are apparently these ficticious zones that translates acronyms
-# CET and MET:
-#
-# Zone CET  1:00 C-Eur CE%sT
-# Zone MET  1:00 C-Eur ME%sT
-#
-# It this is right then the corrected version would look like:
-#
-# Rule C-Eur 1945 only - Sep 16  2:00s 0 -
-#
-# A small step for mankind though 8-)
-Rule	C-Eur	1945	only	-	Sep	16	 2:00s	0	-
-Rule	C-Eur	1977	1980	-	Apr	Sun>=1	 2:00s	1:00	S
-Rule	C-Eur	1977	only	-	Sep	lastSun	 2:00s	0	-
-Rule	C-Eur	1978	only	-	Oct	 1	 2:00s	0	-
-Rule	C-Eur	1979	1995	-	Sep	lastSun	 2:00s	0	-
-Rule	C-Eur	1981	max	-	Mar	lastSun	 2:00s	1:00	S
-Rule	C-Eur	1996	max	-	Oct	lastSun	 2:00s	0	-
-
-# E-Eur differs from EU only in that E-Eur switches at midnight local time.
-Rule	E-Eur	1977	1980	-	Apr	Sun>=1	 0:00	1:00	S
-Rule	E-Eur	1977	only	-	Sep	lastSun	 0:00	0	-
-Rule	E-Eur	1978	only	-	Oct	 1	 0:00	0	-
-Rule	E-Eur	1979	1995	-	Sep	lastSun	 0:00	0	-
-Rule	E-Eur	1981	max	-	Mar	lastSun	 0:00	1:00	S
-Rule	E-Eur	1996	max	-	Oct	lastSun	 0:00	0	-
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Russia	1917	only	-	Jul	 1	23:00	1:00	MST	# Moscow Summer Time
-Rule	Russia	1917	only	-	Dec	28	 0:00	0	MMT	# Moscow Mean Time
-Rule	Russia	1918	only	-	May	31	22:00	2:00	MDST	# Moscow Double Summer Time
-Rule	Russia	1918	only	-	Sep	16	 1:00	1:00	MST
-Rule	Russia	1919	only	-	May	31	23:00	2:00	MDST
-Rule	Russia	1919	only	-	Jul	 1	 2:00	1:00	S
-Rule	Russia	1919	only	-	Aug	16	 0:00	0	-
-Rule	Russia	1921	only	-	Feb	14	23:00	1:00	S
-Rule	Russia	1921	only	-	Mar	20	23:00	2:00	M # Midsummer
-Rule	Russia	1921	only	-	Sep	 1	 0:00	1:00	S
-Rule	Russia	1921	only	-	Oct	 1	 0:00	0	-
-# Act No.925 of the Council of Ministers of the USSR (1980-10-24):
-Rule	Russia	1981	1984	-	Apr	 1	 0:00	1:00	S
-Rule	Russia	1981	1983	-	Oct	 1	 0:00	0	-
-# Act No.967 of the Council of Ministers of the USSR (1984-09-13), repeated in
-# Act No.227 of the Council of Ministers of the USSR (1989-03-14):
-Rule	Russia	1984	1991	-	Sep	lastSun	 2:00s	0	-
-Rule	Russia	1985	1991	-	Mar	lastSun	 2:00s	1:00	S
-#
-Rule	Russia	1992	only	-	Mar	lastSat	 23:00	1:00	S
-Rule	Russia	1992	only	-	Sep	lastSat	 23:00	0	-
-Rule	Russia	1993	max	-	Mar	lastSun	 2:00s	1:00	S
-Rule	Russia	1993	1995	-	Sep	lastSun	 2:00s	0	-
-Rule	Russia	1996	max	-	Oct	lastSun	 2:00s	0	-
-
-# These are for backward compatibility with older versions.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	WET		0:00	EU	WE%sT
-Zone	CET		1:00	C-Eur	CE%sT
-Zone	MET		1:00	C-Eur	ME%sT
-Zone	EET		2:00	EU	EE%sT
-
-# Previous editions of this database used abbreviations like MET DST
-# for Central European Summer Time, but this didn't agree with common usage.
-
-# From Markus Kuhn (1996-07-12):
-# The official German names ... are
-#
-#	Mitteleuropaeische Zeit (MEZ)         = UTC+01:00
-#	Mitteleuropaeische Sommerzeit (MESZ)  = UTC+02:00
-#
-# as defined in the German Time Act (Gesetz ueber die Zeitbestimmung (ZeitG),
-# 1978-07-25, Bundesgesetzblatt, Jahrgang 1978, Teil I, S. 1110-1111)....
-# I wrote ... to the German Federal Physical-Technical Institution
-#
-#	Physikalisch-Technische Bundesanstalt (PTB)
-#	Laboratorium 4.41 "Zeiteinheit"
-#	Postfach 3345
-#	D-38023 Braunschweig
-#	phone: +49 531 592-0
-#
-# ... I received today an answer letter from Dr. Peter Hetzel, head of the PTB
-# department for time and frequency transmission.  He explained that the
-# PTB translates MEZ and MESZ into English as
-#
-#	Central European Time (CET)         = UTC+01:00
-#	Central European Summer Time (CEST) = UTC+02:00
-
-
-# Albania
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Albania	1940	only	-	Jun	16	0:00	1:00	S
-Rule	Albania	1942	only	-	Nov	 2	3:00	0	-
-Rule	Albania	1943	only	-	Mar	29	2:00	1:00	S
-Rule	Albania	1943	only	-	Apr	10	3:00	0	-
-Rule	Albania	1974	only	-	May	 4	0:00	1:00	S
-Rule	Albania	1974	only	-	Oct	 2	0:00	0	-
-Rule	Albania	1975	only	-	May	 1	0:00	1:00	S
-Rule	Albania	1975	only	-	Oct	 2	0:00	0	-
-Rule	Albania	1976	only	-	May	 2	0:00	1:00	S
-Rule	Albania	1976	only	-	Oct	 3	0:00	0	-
-Rule	Albania	1977	only	-	May	 8	0:00	1:00	S
-Rule	Albania	1977	only	-	Oct	 2	0:00	0	-
-Rule	Albania	1978	only	-	May	 6	0:00	1:00	S
-Rule	Albania	1978	only	-	Oct	 1	0:00	0	-
-Rule	Albania	1979	only	-	May	 5	0:00	1:00	S
-Rule	Albania	1979	only	-	Sep	30	0:00	0	-
-Rule	Albania	1980	only	-	May	 3	0:00	1:00	S
-Rule	Albania	1980	only	-	Oct	 4	0:00	0	-
-Rule	Albania	1981	only	-	Apr	26	0:00	1:00	S
-Rule	Albania	1981	only	-	Sep	27	0:00	0	-
-Rule	Albania	1982	only	-	May	 2	0:00	1:00	S
-Rule	Albania	1982	only	-	Oct	 3	0:00	0	-
-Rule	Albania	1983	only	-	Apr	18	0:00	1:00	S
-Rule	Albania	1983	only	-	Oct	 1	0:00	0	-
-Rule	Albania	1984	only	-	Apr	 1	0:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Tirane	1:19:20 -	LMT	1914
-			1:00	-	CET	1940 Jun 16
-			1:00	Albania	CE%sT	1984 Jul
-			1:00	EU	CE%sT
-
-# Andorra
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Andorra	0:06:04 -	LMT	1901
-			0:00	-	WET	1946 Sep 30
-			1:00	-	CET	1985 Mar 31 2:00
-			1:00	EU	CE%sT
-
-# Austria
-
-# From Paul Eggert (2006-03-22): Shanks & Pottenger give 1918-06-16 and
-# 1945-11-18, but the Austrian Federal Office of Metrology and
-# Surveying (BEV) gives 1918-09-16 and for Vienna gives the "alleged"
-# date of 1945-04-12 with no time.  For the 1980-04-06 transition
-# Shanks & Pottenger give 02:00, the BEV 00:00.  Go with the BEV,
-# and guess 02:00 for 1945-04-12.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Austria	1920	only	-	Apr	 5	2:00s	1:00	S
-Rule	Austria	1920	only	-	Sep	13	2:00s	0	-
-Rule	Austria	1946	only	-	Apr	14	2:00s	1:00	S
-Rule	Austria	1946	1948	-	Oct	Sun>=1	2:00s	0	-
-Rule	Austria	1947	only	-	Apr	 6	2:00s	1:00	S
-Rule	Austria	1948	only	-	Apr	18	2:00s	1:00	S
-Rule	Austria	1980	only	-	Apr	 6	0:00	1:00	S
-Rule	Austria	1980	only	-	Sep	28	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Vienna	1:05:20 -	LMT	1893 Apr
-			1:00	C-Eur	CE%sT	1920
-			1:00	Austria	CE%sT	1940 Apr  1 2:00s
-			1:00	C-Eur	CE%sT	1945 Apr  2 2:00s
-			1:00	1:00	CEST	1945 Apr 12 2:00s
-			1:00	-	CET	1946
-			1:00	Austria	CE%sT	1981
-			1:00	EU	CE%sT
-
-# Belarus
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Minsk	1:50:16 -	LMT	1880
-			1:50	-	MMT	1924 May 2 # Minsk Mean Time
-			2:00	-	EET	1930 Jun 21
-			3:00	-	MSK	1941 Jun 28
-			1:00	C-Eur	CE%sT	1944 Jul  3
-			3:00	Russia	MSK/MSD	1990
-			3:00	-	MSK	1991 Mar 31 2:00s
-			2:00	1:00	EEST	1991 Sep 29 2:00s
-			2:00	-	EET	1992 Mar 29 0:00s
-			2:00	1:00	EEST	1992 Sep 27 0:00s
-			2:00	Russia	EE%sT
-
-# Belgium
-#
-# From Paul Eggert (1997-07-02):
-# Entries from 1918 through 1991 are taken from:
-#	Annuaire de L'Observatoire Royal de Belgique,
-#	Avenue Circulaire, 3, B-1180 BRUXELLES, CLVIIe annee, 1991
-#	(Imprimerie HAYEZ, s.p.r.l., Rue Fin, 4, 1080 BRUXELLES, MCMXC),
-#	pp 8-9.
-# LMT before 1892 was 0:17:30, according to the official journal of Belgium:
-#	Moniteur Belge, Samedi 30 Avril 1892, N.121.
-# Thanks to Pascal Delmoitie for these references.
-# The 1918 rules are listed for completeness; they apply to unoccupied Belgium.
-# Assume Brussels switched to WET in 1918 when the armistice took effect.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Belgium	1918	only	-	Mar	 9	 0:00s	1:00	S
-Rule	Belgium	1918	1919	-	Oct	Sat>=1	23:00s	0	-
-Rule	Belgium	1919	only	-	Mar	 1	23:00s	1:00	S
-Rule	Belgium	1920	only	-	Feb	14	23:00s	1:00	S
-Rule	Belgium	1920	only	-	Oct	23	23:00s	0	-
-Rule	Belgium	1921	only	-	Mar	14	23:00s	1:00	S
-Rule	Belgium	1921	only	-	Oct	25	23:00s	0	-
-Rule	Belgium	1922	only	-	Mar	25	23:00s	1:00	S
-Rule	Belgium	1922	1927	-	Oct	Sat>=1	23:00s	0	-
-Rule	Belgium	1923	only	-	Apr	21	23:00s	1:00	S
-Rule	Belgium	1924	only	-	Mar	29	23:00s	1:00	S
-Rule	Belgium	1925	only	-	Apr	 4	23:00s	1:00	S
-# DSH writes that a royal decree of 1926-02-22 specified the Sun following 3rd
-# Sat in Apr (except if it's Easter, in which case it's one Sunday earlier),
-# to Sun following 1st Sat in Oct, and that a royal decree of 1928-09-15
-# changed the transition times to 02:00 GMT.
-Rule	Belgium	1926	only	-	Apr	17	23:00s	1:00	S
-Rule	Belgium	1927	only	-	Apr	 9	23:00s	1:00	S
-Rule	Belgium	1928	only	-	Apr	14	23:00s	1:00	S
-Rule	Belgium	1928	1938	-	Oct	Sun>=2	 2:00s	0	-
-Rule	Belgium	1929	only	-	Apr	21	 2:00s	1:00	S
-Rule	Belgium	1930	only	-	Apr	13	 2:00s	1:00	S
-Rule	Belgium	1931	only	-	Apr	19	 2:00s	1:00	S
-Rule	Belgium	1932	only	-	Apr	 3	 2:00s	1:00	S
-Rule	Belgium	1933	only	-	Mar	26	 2:00s	1:00	S
-Rule	Belgium	1934	only	-	Apr	 8	 2:00s	1:00	S
-Rule	Belgium	1935	only	-	Mar	31	 2:00s	1:00	S
-Rule	Belgium	1936	only	-	Apr	19	 2:00s	1:00	S
-Rule	Belgium	1937	only	-	Apr	 4	 2:00s	1:00	S
-Rule	Belgium	1938	only	-	Mar	27	 2:00s	1:00	S
-Rule	Belgium	1939	only	-	Apr	16	 2:00s	1:00	S
-Rule	Belgium	1939	only	-	Nov	19	 2:00s	0	-
-Rule	Belgium	1940	only	-	Feb	25	 2:00s	1:00	S
-Rule	Belgium	1944	only	-	Sep	17	 2:00s	0	-
-Rule	Belgium	1945	only	-	Apr	 2	 2:00s	1:00	S
-Rule	Belgium	1945	only	-	Sep	16	 2:00s	0	-
-Rule	Belgium	1946	only	-	May	19	 2:00s	1:00	S
-Rule	Belgium	1946	only	-	Oct	 7	 2:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Brussels	0:17:30 -	LMT	1880
-			0:17:30	-	BMT	1892 May  1 12:00 # Brussels MT
-			0:00	-	WET	1914 Nov  8
-			1:00	-	CET	1916 May  1  0:00
-			1:00	C-Eur	CE%sT	1918 Nov 11 11:00u
-			0:00	Belgium	WE%sT	1940 May 20  2:00s
-			1:00	C-Eur	CE%sT	1944 Sep  3
-			1:00	Belgium	CE%sT	1977
-			1:00	EU	CE%sT
-
-# Bosnia and Herzegovina
-# see Serbia
-
-# Bulgaria
-#
-# From Plamen Simenov via Steffen Thorsen (1999-09-09):
-# A document of Government of Bulgaria (No.94/1997) says:
-# EET --> EETDST is in 03:00 Local time in last Sunday of March ...
-# EETDST --> EET is in 04:00 Local time in last Sunday of October
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Bulg	1979	only	-	Mar	31	23:00	1:00	S
-Rule	Bulg	1979	only	-	Oct	 1	 1:00	0	-
-Rule	Bulg	1980	1982	-	Apr	Sat>=1	23:00	1:00	S
-Rule	Bulg	1980	only	-	Sep	29	 1:00	0	-
-Rule	Bulg	1981	only	-	Sep	27	 2:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Sofia	1:33:16 -	LMT	1880
-			1:56:56	-	IMT	1894 Nov 30 # Istanbul MT?
-			2:00	-	EET	1942 Nov  2  3:00
-			1:00	C-Eur	CE%sT	1945
-			1:00	-	CET	1945 Apr 2 3:00
-			2:00	-	EET	1979 Mar 31 23:00
-			2:00	Bulg	EE%sT	1982 Sep 26  2:00
-			2:00	C-Eur	EE%sT	1991
-			2:00	E-Eur	EE%sT	1997
-			2:00	EU	EE%sT
-
-# Croatia
-# see Serbia
-
-# Cyprus
-# Please see the `asia' file for Asia/Nicosia.
-
-# Czech Republic
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Czech	1945	only	-	Apr	 8	2:00s	1:00	S
-Rule	Czech	1945	only	-	Nov	18	2:00s	0	-
-Rule	Czech	1946	only	-	May	 6	2:00s	1:00	S
-Rule	Czech	1946	1949	-	Oct	Sun>=1	2:00s	0	-
-Rule	Czech	1947	only	-	Apr	20	2:00s	1:00	S
-Rule	Czech	1948	only	-	Apr	18	2:00s	1:00	S
-Rule	Czech	1949	only	-	Apr	 9	2:00s	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Prague	0:57:44 -	LMT	1850
-			0:57:44	-	PMT	1891 Oct     # Prague Mean Time
-			1:00	C-Eur	CE%sT	1944 Sep 17 2:00s
-			1:00	Czech	CE%sT	1979
-			1:00	EU	CE%sT
-
-# Denmark, Faroe Islands, and Greenland
-
-# From Jesper Norgaard Welen (2005-04-26):
-# http://www.hum.aau.dk/~poe/tid/tine/DanskTid.htm says that the law
-# [introducing standard time] was in effect from 1894-01-01....
-# The page http://www.retsinfo.dk/_GETDOCI_/ACCN/A18930008330-REGL
-# confirms this, and states that the law was put forth 1893-03-29.
-#
-# The EU treaty with effect from 1973:
-# http://www.retsinfo.dk/_GETDOCI_/ACCN/A19722110030-REGL
-#
-# This provoked a new law from 1974 to make possible summer time changes
-# in subsequenet decrees with the law
-# http://www.retsinfo.dk/_GETDOCI_/ACCN/A19740022330-REGL
-#
-# It seems however that no decree was set forward until 1980.  I have
-# not found any decree, but in another related law, the effecting DST
-# changes are stated explicitly to be from 1980-04-06 at 02:00 to
-# 1980-09-28 at 02:00.  If this is true, this differs slightly from
-# the EU rule in that DST runs to 02:00, not 03:00.  We don't know
-# when Denmark began using the EU rule correctly, but we have only
-# confirmation of the 1980-time, so I presume it was correct in 1981:
-# The law is about the management of the extra hour, concerning
-# working hours reported and effect on obligatory-rest rules (which
-# was suspended on that night):
-# http://www.retsinfo.dk/_GETDOCI_/ACCN/C19801120554-REGL
-
-# From Jesper Norgaard Welen (2005-06-11):
-# The Herning Folkeblad (1980-09-26) reported that the night between
-# Saturday and Sunday the clock is set back from three to two.
-
-# From Paul Eggert (2005-06-11):
-# Hence the "02:00" of the 1980 law refers to standard time, not
-# wall-clock time, and so the EU rules were in effect in 1980.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Denmark	1916	only	-	May	14	23:00	1:00	S
-Rule	Denmark	1916	only	-	Sep	30	23:00	0	-
-Rule	Denmark	1940	only	-	May	15	 0:00	1:00	S
-Rule	Denmark	1945	only	-	Apr	 2	 2:00s	1:00	S
-Rule	Denmark	1945	only	-	Aug	15	 2:00s	0	-
-Rule	Denmark	1946	only	-	May	 1	 2:00s	1:00	S
-Rule	Denmark	1946	only	-	Sep	 1	 2:00s	0	-
-Rule	Denmark	1947	only	-	May	 4	 2:00s	1:00	S
-Rule	Denmark	1947	only	-	Aug	10	 2:00s	0	-
-Rule	Denmark	1948	only	-	May	 9	 2:00s	1:00	S
-Rule	Denmark	1948	only	-	Aug	 8	 2:00s	0	-
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Copenhagen	 0:50:20 -	LMT	1890
-			 0:50:20 -	CMT	1894 Jan  1 # Copenhagen MT
-			 1:00	Denmark	CE%sT	1942 Nov  2 2:00s
-			 1:00	C-Eur	CE%sT	1945 Apr  2 2:00
-			 1:00	Denmark	CE%sT	1980
-			 1:00	EU	CE%sT
-Zone Atlantic/Faroe	-0:27:04 -	LMT	1908 Jan 11	# Torshavn
-			 0:00	-	WET	1981
-			 0:00	EU	WE%sT
-#
-# From Paul Eggert (2004-10-31):
-# During World War II, Germany maintained secret manned weather stations in
-# East Greenland and Franz Josef Land, but we don't know their time zones.
-# My source for this is Wilhelm Dege's book mentioned under Svalbard.
-#
-# From Paul Eggert (2006-03-22):
-# Greenland joined the EU as part of Denmark, obtained home rule on 1979-05-01,
-# and left the EU on 1985-02-01.  It therefore should have been using EU
-# rules at least through 1984.  Shanks & Pottenger say Scoresbysund and Godthab
-# used C-Eur rules after 1980, but IATA SSIM (1991/1996) says they use EU
-# rules since at least 1991.  Assume EU rules since 1980.
-
-# From Gwillin Law (2001-06-06), citing
-# <http://www.statkart.no/efs/efshefter/2001/efs5-2001.pdf> (2001-03-15),
-# and with translations corrected by Steffen Thorsen:
-#
-# Greenland has four local times, and the relation to UTC
-# is according to the following time line:
-#
-# The military zone near Thule	UTC-4
-# Standard Greenland time	UTC-3
-# Scoresbysund			UTC-1
-# Danmarkshavn			UTC
-#
-# In the military area near Thule and in Danmarkshavn DST will not be
-# introduced.
-
-# From Rives McDow (2001-11-01):
-#
-# I correspond regularly with the Dansk Polarcenter, and wrote them at
-# the time to clarify the situation in Thule.  Unfortunately, I have
-# not heard back from them regarding my recent letter.  [But I have
-# info from earlier correspondence.]
-#
-# According to the center, a very small local time zone around Thule
-# Air Base keeps the time according to UTC-4, implementing daylight
-# savings using North America rules, changing the time at 02:00 local time....
-#
-# The east coast of Greenland north of the community of Scoresbysund
-# uses UTC in the same way as in Iceland, year round, with no dst.
-# There are just a few stations on this coast, including the
-# Danmarkshavn ICAO weather station mentioned in your September 29th
-# email.  The other stations are two sledge patrol stations in
-# Mestersvig and Daneborg, the air force base at Station Nord, and the
-# DPC research station at Zackenberg.
-#
-# Scoresbysund and two small villages nearby keep time UTC-1 and use
-# the same daylight savings time period as in West Greenland (Godthab).
-#
-# The rest of Greenland, including Godthab (this area, although it
-# includes central Greenland, is known as west Greenland), keeps time
-# UTC-3, with daylight savings methods according to European rules.
-#
-# It is common procedure to use UTC 0 in the wilderness of East and
-# North Greenland, because it is mainly Icelandic aircraft operators
-# maintaining traffic in these areas.  However, the official status of
-# this area is that it sticks with Godthab time.  This area might be
-# considered a dual time zone in some respects because of this.
-
-# From Rives McDow (2001-11-19):
-# I heard back from someone stationed at Thule; the time change took place
-# there at 2:00 AM.
-
-# From Paul Eggert (2006-03-22):
-# From 1997 on the CIA map shows Danmarkshavn on GMT;
-# the 1995 map as like Godthab.
-# For lack of better info, assume they were like Godthab before 1996.
-# startkart.no says Thule does not observe DST, but this is clearly an error,
-# so go with Shanks & Pottenger for Thule transitions until this year.
-# For 2007 on assume Thule will stay in sync with US DST rules.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Thule	1991	1992	-	Mar	lastSun	2:00	1:00	D
-Rule	Thule	1991	1992	-	Sep	lastSun	2:00	0	S
-Rule	Thule	1993	2006	-	Apr	Sun>=1	2:00	1:00	D
-Rule	Thule	1993	2006	-	Oct	lastSun	2:00	0	S
-Rule	Thule	2007	max	-	Mar	Sun>=8	2:00	1:00	D
-Rule	Thule	2007	max	-	Nov	Sun>=1	2:00	0	S
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Danmarkshavn -1:14:40 -	LMT	1916 Jul 28
-			-3:00	-	WGT	1980 Apr  6 2:00
-			-3:00	EU	WG%sT	1996
-			0:00	-	GMT
-Zone America/Scoresbysund -1:27:52 -	LMT	1916 Jul 28 # Ittoqqortoormiit
-			-2:00	-	CGT	1980 Apr  6 2:00
-			-2:00	C-Eur	CG%sT	1981 Mar 29
-			-1:00	EU	EG%sT
-Zone America/Godthab	-3:26:56 -	LMT	1916 Jul 28 # Nuuk
-			-3:00	-	WGT	1980 Apr  6 2:00
-			-3:00	EU	WG%sT
-Zone America/Thule	-4:35:08 -	LMT	1916 Jul 28 # Pituffik air base
-			-4:00	Thule	A%sT
-
-# Estonia
-# From Peter Ilieve (1994-10-15):
-# A relative in Tallinn confirms the accuracy of the data for 1989 onwards
-# [through 1994] and gives the legal authority for it,
-# a regulation of the Government of Estonia, No. 111 of 1989....
-#
-# From Peter Ilieve (1996-10-28):
-# [IATA SSIM (1992/1996) claims that the Baltic republics switch at 01:00s,
-# but a relative confirms that Estonia still switches at 02:00s, writing:]
-# ``I do not [know] exactly but there are some little different
-# (confusing) rules for International Air and Railway Transport Schedules
-# conversion in Sunday connected with end of summer time in Estonia....
-# A discussion is running about the summer time efficiency and effect on
-# human physiology.  It seems that Estonia maybe will not change to
-# summer time next spring.''
-
-# From Peter Ilieve (1998-11-04), heavily edited:
-# <a href="http://trip.rk.ee/cgi-bin/thw?${BASE}=akt&${OOHTML}=rtd&TA=1998&TO=1&AN=1390">
-# The 1998-09-22 Estonian time law
-# </a>
-# refers to the Eighth Directive and cites the association agreement between
-# the EU and Estonia, ratified by the Estonian law (RT II 1995, 22--27, 120).
-#
-# I also asked [my relative] whether they use any standard abbreviation
-# for their standard and summer times. He says no, they use "suveaeg"
-# (summer time) and "talveaeg" (winter time).
-
-# From <a href="http://www.baltictimes.com/">The Baltic Times</a> (1999-09-09)
-# via Steffen Thorsen:
-# This year will mark the last time Estonia shifts to summer time,
-# a council of the ruling coalition announced Sept. 6....
-# But what this could mean for Estonia's chances of joining the European
-# Union are still unclear.  In 1994, the EU declared summer time compulsory
-# for all member states until 2001.  Brussels has yet to decide what to do
-# after that.
-
-# From Mart Oruaas (2000-01-29):
-# Regulation no. 301 (1999-10-12) obsoletes previous regulation
-# no. 206 (1998-09-22) and thus sticks Estonia to +02:00 GMT for all
-# the year round.  The regulation is effective 1999-11-01.
-
-# From Toomas Soome (2002-02-21):
-# The Estonian government has changed once again timezone politics.
-# Now we are using again EU rules.
-#
-# From Urmet Jaanes (2002-03-28):
-# The legislative reference is Government decree No. 84 on 2002-02-21.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Tallinn	1:39:00	-	LMT	1880
-			1:39:00	-	TMT	1918 Feb # Tallinn Mean Time
-			1:00	C-Eur	CE%sT	1919 Jul
-			1:39:00	-	TMT	1921 May
-			2:00	-	EET	1940 Aug  6
-			3:00	-	MSK	1941 Sep 15
-			1:00	C-Eur	CE%sT	1944 Sep 22
-			3:00	Russia	MSK/MSD	1989 Mar 26 2:00s
-			2:00	1:00	EEST	1989 Sep 24 2:00s
-			2:00	C-Eur	EE%sT	1998 Sep 22
-			2:00	EU	EE%sT	1999 Nov  1
-			2:00	-	EET	2002 Feb 21
-			2:00	EU	EE%sT
-
-# Finland
-#
-# From Hannu Strang (1994-09-25 06:03:37 UTC):
-# Well, here in Helsinki we're just changing from summer time to regular one,
-# and it's supposed to change at 4am...
-#
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say Finland has switched at 02:00 standard time
-# since 1981.  Go with Strang instead.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Finland	1942	only	-	Apr	3	0:00	1:00	S
-Rule	Finland	1942	only	-	Oct	3	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Helsinki	1:39:52 -	LMT	1878 May 31
-			1:39:52	-	HMT	1921 May    # Helsinki Mean Time
-			2:00	Finland	EE%sT	1981 Mar 29 2:00
-			2:00	EU	EE%sT
-
-# Aaland Is
-Link	Europe/Helsinki	Europe/Mariehamn
-
-
-# France
-
-# From Ciro Discepolo (2000-12-20):
-#
-# Henri Le Corre, Regimes Horaires pour le monde entier, Editions
-# Traditionnelles - Paris 2 books, 1993
-#
-# Gabriel, Traite de l'heure dans le monde, Guy Tredaniel editeur,
-# Paris, 1991
-#
-# Francoise Gauquelin, Problemes de l'heure resolus en astrologie,
-# Guy tredaniel, Paris 1987
-
-
-#
-# Shank & Pottenger seem to use `24:00' ambiguously; resolve it with Whitman.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	France	1916	only	-	Jun	14	23:00s	1:00	S
-Rule	France	1916	1919	-	Oct	Sun>=1	23:00s	0	-
-Rule	France	1917	only	-	Mar	24	23:00s	1:00	S
-Rule	France	1918	only	-	Mar	 9	23:00s	1:00	S
-Rule	France	1919	only	-	Mar	 1	23:00s	1:00	S
-Rule	France	1920	only	-	Feb	14	23:00s	1:00	S
-Rule	France	1920	only	-	Oct	23	23:00s	0	-
-Rule	France	1921	only	-	Mar	14	23:00s	1:00	S
-Rule	France	1921	only	-	Oct	25	23:00s	0	-
-Rule	France	1922	only	-	Mar	25	23:00s	1:00	S
-# DSH writes that a law of 1923-05-24 specified 3rd Sat in Apr at 23:00 to 1st
-# Sat in Oct at 24:00; and that in 1930, because of Easter, the transitions
-# were Apr 12 and Oct 5.  Go with Shanks & Pottenger.
-Rule	France	1922	1938	-	Oct	Sat>=1	23:00s	0	-
-Rule	France	1923	only	-	May	26	23:00s	1:00	S
-Rule	France	1924	only	-	Mar	29	23:00s	1:00	S
-Rule	France	1925	only	-	Apr	 4	23:00s	1:00	S
-Rule	France	1926	only	-	Apr	17	23:00s	1:00	S
-Rule	France	1927	only	-	Apr	 9	23:00s	1:00	S
-Rule	France	1928	only	-	Apr	14	23:00s	1:00	S
-Rule	France	1929	only	-	Apr	20	23:00s	1:00	S
-Rule	France	1930	only	-	Apr	12	23:00s	1:00	S
-Rule	France	1931	only	-	Apr	18	23:00s	1:00	S
-Rule	France	1932	only	-	Apr	 2	23:00s	1:00	S
-Rule	France	1933	only	-	Mar	25	23:00s	1:00	S
-Rule	France	1934	only	-	Apr	 7	23:00s	1:00	S
-Rule	France	1935	only	-	Mar	30	23:00s	1:00	S
-Rule	France	1936	only	-	Apr	18	23:00s	1:00	S
-Rule	France	1937	only	-	Apr	 3	23:00s	1:00	S
-Rule	France	1938	only	-	Mar	26	23:00s	1:00	S
-Rule	France	1939	only	-	Apr	15	23:00s	1:00	S
-Rule	France	1939	only	-	Nov	18	23:00s	0	-
-Rule	France	1940	only	-	Feb	25	 2:00	1:00	S
-# The French rules for 1941-1944 were not used in Paris, but Shanks & Pottenger
-# write that they were used in Monaco and in many French locations.
-# Le Corre writes that the upper limit of the free zone was Arneguy, Orthez,
-# Mont-de-Marsan, Bazas, Langon, Lamotte-Montravel, Marouil, La
-# Rochefoucault, Champagne-Mouton, La Roche-Posay, La Haye-Decartes,
-# Loches, Montrichard, Vierzon, Bourges, Moulins, Digoin,
-# Paray-le-Monial, Montceau-les-Mines, Chalons-sur-Saone, Arbois,
-# Dole, Morez, St-Claude, and Collognes (Haute-Savioe).
-Rule	France	1941	only	-	May	 5	 0:00	2:00	M # Midsummer
-# Shanks & Pottenger say this transition occurred at Oct 6 1:00,
-# but go with Denis Excoffier (1997-12-12),
-# who quotes the Ephemerides Astronomiques for 1998 from Bureau des Longitudes
-# as saying 5/10/41 22hUT.
-Rule	France	1941	only	-	Oct	 6	 0:00	1:00	S
-Rule	France	1942	only	-	Mar	 9	 0:00	2:00	M
-Rule	France	1942	only	-	Nov	 2	 3:00	1:00	S
-Rule	France	1943	only	-	Mar	29	 2:00	2:00	M
-Rule	France	1943	only	-	Oct	 4	 3:00	1:00	S
-Rule	France	1944	only	-	Apr	 3	 2:00	2:00	M
-Rule	France	1944	only	-	Oct	 8	 1:00	1:00	S
-Rule	France	1945	only	-	Apr	 2	 2:00	2:00	M
-Rule	France	1945	only	-	Sep	16	 3:00	0	-
-# Shanks & Pottenger give Mar 28 2:00 and Sep 26 3:00;
-# go with Excoffier's 28/3/76 0hUT and 25/9/76 23hUT.
-Rule	France	1976	only	-	Mar	28	 1:00	1:00	S
-Rule	France	1976	only	-	Sep	26	 1:00	0	-
-# Shanks & Pottenger give 0:09:20 for Paris Mean Time, and Whitman 0:09:05,
-# but Howse quotes the actual French legislation as saying 0:09:21.
-# Go with Howse.  Howse writes that the time in France was officially based
-# on PMT-0:09:21 until 1978-08-09, when the time base finally switched to UTC.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Paris	0:09:21 -	LMT	1891 Mar 15  0:01
-			0:09:21	-	PMT	1911 Mar 11  0:01  # Paris MT
-# Shanks & Pottenger give 1940 Jun 14 0:00; go with Excoffier and Le Corre.
-			0:00	France	WE%sT	1940 Jun 14 23:00
-# Le Corre says Paris stuck with occupied-France time after the liberation;
-# go with Shanks & Pottenger.
-			1:00	C-Eur	CE%sT	1944 Aug 25
-			0:00	France	WE%sT	1945 Sep 16  3:00
-			1:00	France	CE%sT	1977
-			1:00	EU	CE%sT
-
-# Germany
-
-# From Markus Kuhn (1998-09-29):
-# The German time zone web site by the Physikalisch-Technische
-# Bundesanstalt contains DST information back to 1916.
-# [See tz-link.htm for the URL.]
-
-# From Joerg Schilling (2002-10-23):
-# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by
-# <a href="http://www.dhm.de/lemo/html/biografien/BersarinNikolai/">
-# General [Nikolai] Bersarin</a>.
-
-# From Paul Eggert (2003-03-08):
-# <a href="http://www.parlament-berlin.de/pds-fraktion.nsf/727459127c8b66ee8525662300459099/defc77cb784f180ac1256c2b0030274b/$FILE/bersarint.pdf">
-# http://www.parlament-berlin.de/pds-fraktion.nsf/727459127c8b66ee8525662300459099/defc77cb784f180ac1256c2b0030274b/$FILE/bersarint.pdf
-# </a>
-# says that Bersarin issued an order to use Moscow time on May 20.
-# However, Moscow did not observe daylight saving in 1945, so
-# this was equivalent to CEMT (GMT+3), not GMT+4.
-
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Germany	1946	only	-	Apr	14	2:00s	1:00	S
-Rule	Germany	1946	only	-	Oct	 7	2:00s	0	-
-Rule	Germany	1947	1949	-	Oct	Sun>=1	2:00s	0	-
-# http://www.ptb.de/de/org/4/44/441/salt.htm says the following transition
-# occurred at 3:00 MEZ, not the 2:00 MEZ given in Shanks & Pottenger.
-# Go with the PTB.
-Rule	Germany	1947	only	-	Apr	 6	3:00s	1:00	S
-Rule	Germany	1947	only	-	May	11	2:00s	2:00	M
-Rule	Germany	1947	only	-	Jun	29	3:00	1:00	S
-Rule	Germany	1948	only	-	Apr	18	2:00s	1:00	S
-Rule	Germany	1949	only	-	Apr	10	2:00s	1:00	S
-
-Rule SovietZone	1945	only	-	May	24	2:00	2:00	M # Midsummer
-Rule SovietZone	1945	only	-	Sep	24	3:00	1:00	S
-Rule SovietZone	1945	only	-	Nov	18	2:00s	0	-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Berlin	0:53:28 -	LMT	1893 Apr
-			1:00	C-Eur	CE%sT	1945 May 24 2:00
-			1:00 SovietZone	CE%sT	1946
-			1:00	Germany	CE%sT	1980
-			1:00	EU	CE%sT
-
-# Georgia
-# Please see the "asia" file for Asia/Tbilisi.
-# Herodotus (Histories, IV.45) says Georgia north of the Phasis (now Rioni)
-# is in Europe.  Our reference location Tbilisi is in the Asian part.
-
-# Gibraltar
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Gibraltar	-0:21:24 -	LMT	1880 Aug  2 0:00s
-			0:00	GB-Eire	%s	1957 Apr 14 2:00
-			1:00	-	CET	1982
-			1:00	EU	CE%sT
-
-# Greece
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Whitman gives 1932 Jul 5 - Nov 1; go with Shanks & Pottenger.
-Rule	Greece	1932	only	-	Jul	 7	0:00	1:00	S
-Rule	Greece	1932	only	-	Sep	 1	0:00	0	-
-# Whitman gives 1941 Apr 25 - ?; go with Shanks & Pottenger.
-Rule	Greece	1941	only	-	Apr	 7	0:00	1:00	S
-# Whitman gives 1942 Feb 2 - ?; go with Shanks & Pottenger.
-Rule	Greece	1942	only	-	Nov	 2	3:00	0	-
-Rule	Greece	1943	only	-	Mar	30	0:00	1:00	S
-Rule	Greece	1943	only	-	Oct	 4	0:00	0	-
-# Whitman gives 1944 Oct 3 - Oct 31; go with Shanks & Pottenger.
-Rule	Greece	1952	only	-	Jul	 1	0:00	1:00	S
-Rule	Greece	1952	only	-	Nov	 2	0:00	0	-
-Rule	Greece	1975	only	-	Apr	12	0:00s	1:00	S
-Rule	Greece	1975	only	-	Nov	26	0:00s	0	-
-Rule	Greece	1976	only	-	Apr	11	2:00s	1:00	S
-Rule	Greece	1976	only	-	Oct	10	2:00s	0	-
-Rule	Greece	1977	1978	-	Apr	Sun>=1	2:00s	1:00	S
-Rule	Greece	1977	only	-	Sep	26	2:00s	0	-
-Rule	Greece	1978	only	-	Sep	24	4:00	0	-
-Rule	Greece	1979	only	-	Apr	 1	9:00	1:00	S
-Rule	Greece	1979	only	-	Sep	29	2:00	0	-
-Rule	Greece	1980	only	-	Apr	 1	0:00	1:00	S
-Rule	Greece	1980	only	-	Sep	28	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Athens	1:34:52 -	LMT	1895 Sep 14
-			1:34:52	-	AMT	1916 Jul 28 0:01     # Athens MT
-			2:00	Greece	EE%sT	1941 Apr 30
-			1:00	Greece	CE%sT	1944 Apr  4
-			2:00	Greece	EE%sT	1981
-			# Shanks & Pottenger say it switched to C-Eur in 1981;
-			# go with EU instead, since Greece joined it on Jan 1.
-			2:00	EU	EE%sT
-
-# Hungary
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Hungary	1918	only	-	Apr	 1	 3:00	1:00	S
-Rule	Hungary	1918	only	-	Sep	29	 3:00	0	-
-Rule	Hungary	1919	only	-	Apr	15	 3:00	1:00	S
-Rule	Hungary	1919	only	-	Sep	15	 3:00	0	-
-Rule	Hungary	1920	only	-	Apr	 5	 3:00	1:00	S
-Rule	Hungary	1920	only	-	Sep	30	 3:00	0	-
-Rule	Hungary	1945	only	-	May	 1	23:00	1:00	S
-Rule	Hungary	1945	only	-	Nov	 3	 0:00	0	-
-Rule	Hungary	1946	only	-	Mar	31	 2:00s	1:00	S
-Rule	Hungary	1946	1949	-	Oct	Sun>=1	 2:00s	0	-
-Rule	Hungary	1947	1949	-	Apr	Sun>=4	 2:00s	1:00	S
-Rule	Hungary	1950	only	-	Apr	17	 2:00s	1:00	S
-Rule	Hungary	1950	only	-	Oct	23	 2:00s	0	-
-Rule	Hungary	1954	1955	-	May	23	 0:00	1:00	S
-Rule	Hungary	1954	1955	-	Oct	 3	 0:00	0	-
-Rule	Hungary	1956	only	-	Jun	Sun>=1	 0:00	1:00	S
-Rule	Hungary	1956	only	-	Sep	lastSun	 0:00	0	-
-Rule	Hungary	1957	only	-	Jun	Sun>=1	 1:00	1:00	S
-Rule	Hungary	1957	only	-	Sep	lastSun	 3:00	0	-
-Rule	Hungary	1980	only	-	Apr	 6	 1:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Budapest	1:16:20 -	LMT	1890 Oct
-			1:00	C-Eur	CE%sT	1918
-			1:00	Hungary	CE%sT	1941 Apr  6  2:00
-			1:00	C-Eur	CE%sT	1945
-			1:00	Hungary	CE%sT	1980 Sep 28  2:00s
-			1:00	EU	CE%sT
-
-# Iceland
-#
-# From Adam David (1993-11-06):
-# The name of the timezone in Iceland for system / mail / news purposes is GMT.
-#
-# (1993-12-05):
-# This material is paraphrased from the 1988 edition of the University of
-# Iceland Almanak.
-#
-# From January 1st, 1908 the whole of Iceland was standardised at 1 hour
-# behind GMT. Previously, local mean solar time was used in different parts
-# of Iceland, the almanak had been based on Reykjavik mean solar time which
-# was 1 hour and 28 minutes behind GMT.
-#
-# "first day of winter" referred to [below] means the first day of the 26 weeks
-# of winter, according to the old icelandic calendar that dates back to the
-# time the norsemen first settled Iceland.  The first day of winter is always
-# Saturday, but is not dependent on the Julian or Gregorian calendars.
-#
-# (1993-12-10):
-# I have a reference from the Oxford Icelandic-English dictionary for the
-# beginning of winter, which ties it to the ecclesiastical calendar (and thus
-# to the julian/gregorian calendar) over the period in question.
-#	the winter begins on the Saturday next before St. Luke's day
-#	(old style), or on St. Luke's day, if a Saturday.
-# St. Luke's day ought to be traceable from ecclesiastical sources. "old style"
-# might be a reference to the Julian calendar as opposed to Gregorian, or it
-# might mean something else (???).
-#
-# From Paul Eggert (2006-03-22):
-# The Iceland Almanak, Shanks & Pottenger, and Whitman disagree on many points.
-# We go with the Almanak, except for one claim from Shanks & Pottenger, namely
-# that Reykavik was 21W57 from 1837 to 1908, local mean time before that.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Iceland	1917	1918	-	Feb	19	23:00	1:00	S
-Rule	Iceland	1917	only	-	Oct	21	 1:00	0	-
-Rule	Iceland	1918	only	-	Nov	16	 1:00	0	-
-Rule	Iceland	1939	only	-	Apr	29	23:00	1:00	S
-Rule	Iceland	1939	only	-	Nov	29	 2:00	0	-
-Rule	Iceland	1940	only	-	Feb	25	 2:00	1:00	S
-Rule	Iceland	1940	only	-	Nov	 3	 2:00	0	-
-Rule	Iceland	1941	only	-	Mar	 2	 1:00s	1:00	S
-Rule	Iceland	1941	only	-	Nov	 2	 1:00s	0	-
-Rule	Iceland	1942	only	-	Mar	 8	 1:00s	1:00	S
-Rule	Iceland	1942	only	-	Oct	25	 1:00s	0	-
-# 1943-1946 - first Sunday in March until first Sunday in winter
-Rule	Iceland	1943	1946	-	Mar	Sun>=1	 1:00s	1:00	S
-Rule	Iceland	1943	1948	-	Oct	Sun>=22	 1:00s	0	-
-# 1947-1967 - first Sunday in April until first Sunday in winter
-Rule	Iceland	1947	1967	-	Apr	Sun>=1	 1:00s	1:00	S
-# 1949 Oct transition delayed by 1 week
-Rule	Iceland	1949	only	-	Oct	30	 1:00s	0	-
-Rule	Iceland	1950	1966	-	Oct	Sun>=22	 1:00s	0	-
-Rule	Iceland	1967	only	-	Oct	29	 1:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/Reykjavik	-1:27:24 -	LMT	1837
-			-1:27:48 -	RMT	1908 # Reykjavik Mean Time?
-			-1:00	Iceland	IS%sT	1968 Apr 7 1:00s
-			 0:00	-	GMT
-
-# Italy
-#
-# From Paul Eggert (2001-03-06):
-# Sicily and Sardinia each had their own time zones from 1866 to 1893,
-# called Palermo Time (+00:53:28) and Cagliari Time (+00:36:32).
-# During World War II, German-controlled Italy used German time.
-# But these events all occurred before the 1970 cutoff,
-# so record only the time in Rome.
-#
-# From Paul Eggert (2006-03-22):
-# For Italian DST we have three sources: Shanks & Pottenger, Whitman, and
-# F. Pollastri
-# <a href="http://toi.iriti.cnr.it/uk/ienitlt.html">
-# Day-light Saving Time in Italy (2006-02-03)
-# </a>
-# (`FP' below), taken from an Italian National Electrotechnical Institute
-# publication. When the three sources disagree, guess who's right, as follows:
-#
-# year	FP	Shanks&P. (S)	Whitman (W)	Go with:
-# 1916	06-03	06-03 24:00	06-03 00:00	FP & W
-#	09-30	09-30 24:00	09-30 01:00	FP; guess 24:00s
-# 1917	04-01	03-31 24:00	03-31 00:00	FP & S
-#	09-30	09-29 24:00	09-30 01:00	FP & W
-# 1918	03-09	03-09 24:00	03-09 00:00	FP & S
-#	10-06	10-05 24:00	10-06 01:00	FP & W
-# 1919	03-01	03-01 24:00	03-01 00:00	FP & S
-#	10-04	10-04 24:00	10-04 01:00	FP; guess 24:00s
-# 1920	03-20	03-20 24:00	03-20 00:00	FP & S
-#	09-18	09-18 24:00	10-01 01:00	FP; guess 24:00s
-# 1944	04-02	04-03 02:00			S (see C-Eur)
-#	09-16	10-02 03:00			FP; guess 24:00s
-# 1945	09-14	09-16 24:00			FP; guess 24:00s
-# 1970	05-21	05-31 00:00			S
-#	09-20	09-27 00:00			S
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Italy	1916	only	-	Jun	 3	0:00s	1:00	S
-Rule	Italy	1916	only	-	Oct	 1	0:00s	0	-
-Rule	Italy	1917	only	-	Apr	 1	0:00s	1:00	S
-Rule	Italy	1917	only	-	Sep	30	0:00s	0	-
-Rule	Italy	1918	only	-	Mar	10	0:00s	1:00	S
-Rule	Italy	1918	1919	-	Oct	Sun>=1	0:00s	0	-
-Rule	Italy	1919	only	-	Mar	 2	0:00s	1:00	S
-Rule	Italy	1920	only	-	Mar	21	0:00s	1:00	S
-Rule	Italy	1920	only	-	Sep	19	0:00s	0	-
-Rule	Italy	1940	only	-	Jun	15	0:00s	1:00	S
-Rule	Italy	1944	only	-	Sep	17	0:00s	0	-
-Rule	Italy	1945	only	-	Apr	 2	2:00	1:00	S
-Rule	Italy	1945	only	-	Sep	15	0:00s	0	-
-Rule	Italy	1946	only	-	Mar	17	2:00s	1:00	S
-Rule	Italy	1946	only	-	Oct	 6	2:00s	0	-
-Rule	Italy	1947	only	-	Mar	16	0:00s	1:00	S
-Rule	Italy	1947	only	-	Oct	 5	0:00s	0	-
-Rule	Italy	1948	only	-	Feb	29	2:00s	1:00	S
-Rule	Italy	1948	only	-	Oct	 3	2:00s	0	-
-Rule	Italy	1966	1968	-	May	Sun>=22	0:00	1:00	S
-Rule	Italy	1966	1969	-	Sep	Sun>=22	0:00	0	-
-Rule	Italy	1969	only	-	Jun	 1	0:00	1:00	S
-Rule	Italy	1970	only	-	May	31	0:00	1:00	S
-Rule	Italy	1970	only	-	Sep	lastSun	0:00	0	-
-Rule	Italy	1971	1972	-	May	Sun>=22	0:00	1:00	S
-Rule	Italy	1971	only	-	Sep	lastSun	1:00	0	-
-Rule	Italy	1972	only	-	Oct	 1	0:00	0	-
-Rule	Italy	1973	only	-	Jun	 3	0:00	1:00	S
-Rule	Italy	1973	1974	-	Sep	lastSun	0:00	0	-
-Rule	Italy	1974	only	-	May	26	0:00	1:00	S
-Rule	Italy	1975	only	-	Jun	 1	0:00s	1:00	S
-Rule	Italy	1975	1977	-	Sep	lastSun	0:00s	0	-
-Rule	Italy	1976	only	-	May	30	0:00s	1:00	S
-Rule	Italy	1977	1979	-	May	Sun>=22	0:00s	1:00	S
-Rule	Italy	1978	only	-	Oct	 1	0:00s	0	-
-Rule	Italy	1979	only	-	Sep	30	0:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Rome	0:49:56 -	LMT	1866 Sep 22
-			0:49:56	-	RMT	1893 Nov  1 0:00s # Rome Mean
-			1:00	Italy	CE%sT	1942 Nov  2 2:00s
-			1:00	C-Eur	CE%sT	1944 Jul
-			1:00	Italy	CE%sT	1980
-			1:00	EU	CE%sT
-
-Link	Europe/Rome	Europe/Vatican
-Link	Europe/Rome	Europe/San_Marino
-
-# Latvia
-
-# From Liene Kanepe (1998-09-17):
-
-# I asked about this matter Scientific Secretary of the Institute of Astronomy
-# of The University of Latvia Dr. paed Mr. Ilgonis Vilks. I also searched the
-# correct data in juridical acts and I found some juridical documents about
-# changes in the counting of time in Latvia from 1981....
-#
-# Act No.35 of the Council of Ministers of Latvian SSR of 1981-01-22 ...
-# according to the Act No.925 of the Council of Ministers of USSR of 1980-10-24
-# ...: all year round the time of 2nd time zone + 1 hour, in addition turning
-# the hands of the clock 1 hour forward on 1 April at 00:00 (GMT 31 March 21:00)
-# and 1 hour backward on the 1 October at 00:00 (GMT 30 September 20:00).
-#
-# Act No.592 of the Council of Ministers of Latvian SSR of 1984-09-24 ...
-# according to the Act No.967 of the Council of Ministers of USSR of 1984-09-13
-# ...: all year round the time of 2nd time zone + 1 hour, in addition turning
-# the hands of the clock 1 hour forward on the last Sunday of March at 02:00
-# (GMT 23:00 on the previous day) and 1 hour backward on the last Sunday of
-# September at 03:00 (GMT 23:00 on the previous day).
-#
-# Act No.81 of the Council of Ministers of Latvian SSR of 1989-03-22 ...
-# according to the Act No.227 of the Council of Ministers of USSR of 1989-03-14
-# ...: since the last Sunday of March 1989 in Lithuanian SSR, Latvian SSR,
-# Estonian SSR and Kaliningrad region of Russian Federation all year round the
-# time of 2nd time zone (Moscow time minus one hour). On the territory of Latvia
-# transition to summer time is performed on the last Sunday of March at 02:00
-# (GMT 00:00), turning the hands of the clock 1 hour forward.  The end of
-# daylight saving time is performed on the last Sunday of September at 03:00
-# (GMT 00:00), turning the hands of the clock 1 hour backward. Exception is
-# 1989-03-26, when we must not turn the hands of the clock....
-#
-# The Regulations of the Cabinet of Ministers of the Republic of Latvia of
-# 1997-01-21 on transition to Summer time ... established the same order of
-# daylight savings time settings as in the States of the European Union.
-
-# From Andrei Ivanov (2000-03-06):
-# This year Latvia will not switch to Daylight Savings Time (as specified in
-# <a href="http://www.lv-laiks.lv/wwwraksti/2000/071072/vd4.htm">
-# The Regulations of the Cabinet of Ministers of the Rep. of Latvia of
-# 29-Feb-2000 (#79)</a>, in Latvian for subscribers only).
-
-# <a href="http://www.rferl.org/newsline/2001/01/3-CEE/cee-030101.html">
-# From RFE/RL Newsline (2001-01-03), noted after a heads-up by Rives McDow:
-# </a>
-# The Latvian government on 2 January decided that the country will
-# institute daylight-saving time this spring, LETA reported.
-# Last February the three Baltic states decided not to turn back their
-# clocks one hour in the spring....
-# Minister of Economy Aigars Kalvitis noted that Latvia had too few
-# daylight hours and thus decided to comply with a draft European
-# Commission directive that provides for instituting daylight-saving
-# time in EU countries between 2002 and 2006. The Latvian government
-# urged Lithuania and Estonia to adopt a similar time policy, but it
-# appears that they will not do so....
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Latvia	1989	1996	-	Mar	lastSun	 2:00s	1:00	S
-Rule	Latvia	1989	1996	-	Sep	lastSun	 2:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Riga	1:36:24	-	LMT	1880
-			1:36:24	-	RMT	1918 Apr 15 2:00 #Riga Mean Time
-			1:36:24	1:00	LST	1918 Sep 16 3:00 #Latvian Summer
-			1:36:24	-	RMT	1919 Apr  1 2:00
-			1:36:24	1:00	LST	1919 May 22 3:00
-			1:36:24	-	RMT	1926 May 11
-			2:00	-	EET	1940 Aug  5
-			3:00	-	MSK	1941 Jul
-			1:00	C-Eur	CE%sT	1944 Oct 13
-			3:00	Russia	MSK/MSD	1989 Mar lastSun 2:00s
-			2:00	1:00	EEST	1989 Sep lastSun 2:00s
-			2:00	Latvia	EE%sT	1997 Jan 21
-			2:00	EU	EE%sT	2000 Feb 29
-			2:00	-	EET	2001 Jan  2
-			2:00	EU	EE%sT
-
-# Liechtenstein
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Vaduz	0:38:04 -	LMT	1894 Jun
-			1:00	-	CET	1981
-			1:00	EU	CE%sT
-
-# Lithuania
-
-# From Paul Eggert (1996-11-22):
-# IATA SSIM (1992/1996) says Lithuania uses W-Eur rules, but since it is
-# known to be wrong about Estonia and Latvia, assume it's wrong here too.
-
-# From Marius Gedminas (1998-08-07):
-# I would like to inform that in this year Lithuanian time zone
-# (Europe/Vilnius) was changed.
-
-# From <a href="http://www.elta.lt/">ELTA</a> No. 972 (2582) (1999-09-29),
-# via Steffen Thorsen:
-# Lithuania has shifted back to the second time zone (GMT plus two hours)
-# to be valid here starting from October 31,
-# as decided by the national government on Wednesday....
-# The Lithuanian government also announced plans to consider a
-# motion to give up shifting to summer time in spring, as it was
-# already done by Estonia.
-
-# From the <a href="http://www.tourism.lt/informa/ff.htm">
-# Fact File, Lithuanian State Department of Tourism
-# </a> (2000-03-27): Local time is GMT+2 hours ..., no daylight saving.
-
-# From a user via Klaus Marten (2003-02-07):
-# As a candidate for membership of the European Union, Lithuania will
-# observe Summer Time in 2003, changing its clocks at the times laid
-# down in EU Directive 2000/84 of 19.I.01 (i.e. at the same times as its
-# neighbour Latvia). The text of the Lithuanian government Order of
-# 7.XI.02 to this effect can be found at
-# http://www.lrvk.lt/nut/11/n1749.htm
-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Vilnius	1:41:16	-	LMT	1880
-			1:24:00	-	WMT	1917	    # Warsaw Mean Time
-			1:35:36	-	KMT	1919 Oct 10 # Kaunas Mean Time
-			1:00	-	CET	1920 Jul 12
-			2:00	-	EET	1920 Oct  9
-			1:00	-	CET	1940 Aug  3
-			3:00	-	MSK	1941 Jun 24
-			1:00	C-Eur	CE%sT	1944 Aug
-			3:00	Russia	MSK/MSD	1991 Mar 31 2:00s
-			2:00	1:00	EEST	1991 Sep 29 2:00s
-			2:00	C-Eur	EE%sT	1998
-			2:00	-	EET	1998 Mar 29 1:00u
-			1:00	EU	CE%sT	1999 Oct 31 1:00u
-			2:00	-	EET	2003 Jan  1
-			2:00	EU	EE%sT
-
-# Luxembourg
-# Whitman disagrees with most of these dates in minor ways;
-# go with Shanks & Pottenger.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Lux	1916	only	-	May	14	23:00	1:00	S
-Rule	Lux	1916	only	-	Oct	 1	 1:00	0	-
-Rule	Lux	1917	only	-	Apr	28	23:00	1:00	S
-Rule	Lux	1917	only	-	Sep	17	 1:00	0	-
-Rule	Lux	1918	only	-	Apr	Mon>=15	 2:00s	1:00	S
-Rule	Lux	1918	only	-	Sep	Mon>=15	 2:00s	0	-
-Rule	Lux	1919	only	-	Mar	 1	23:00	1:00	S
-Rule	Lux	1919	only	-	Oct	 5	 3:00	0	-
-Rule	Lux	1920	only	-	Feb	14	23:00	1:00	S
-Rule	Lux	1920	only	-	Oct	24	 2:00	0	-
-Rule	Lux	1921	only	-	Mar	14	23:00	1:00	S
-Rule	Lux	1921	only	-	Oct	26	 2:00	0	-
-Rule	Lux	1922	only	-	Mar	25	23:00	1:00	S
-Rule	Lux	1922	only	-	Oct	Sun>=2	 1:00	0	-
-Rule	Lux	1923	only	-	Apr	21	23:00	1:00	S
-Rule	Lux	1923	only	-	Oct	Sun>=2	 2:00	0	-
-Rule	Lux	1924	only	-	Mar	29	23:00	1:00	S
-Rule	Lux	1924	1928	-	Oct	Sun>=2	 1:00	0	-
-Rule	Lux	1925	only	-	Apr	 5	23:00	1:00	S
-Rule	Lux	1926	only	-	Apr	17	23:00	1:00	S
-Rule	Lux	1927	only	-	Apr	 9	23:00	1:00	S
-Rule	Lux	1928	only	-	Apr	14	23:00	1:00	S
-Rule	Lux	1929	only	-	Apr	20	23:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Luxembourg	0:24:36 -	LMT	1904 Jun
-			1:00	Lux	CE%sT	1918 Nov 25
-			0:00	Lux	WE%sT	1929 Oct  6 2:00s
-			0:00	Belgium	WE%sT	1940 May 14 3:00
-			1:00	C-Eur	WE%sT	1944 Sep 18 3:00
-			1:00	Belgium	CE%sT	1977
-			1:00	EU	CE%sT
-
-# Macedonia
-# see Serbia
-
-# Malta
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Malta	1973	only	-	Mar	31	0:00s	1:00	S
-Rule	Malta	1973	only	-	Sep	29	0:00s	0	-
-Rule	Malta	1974	only	-	Apr	21	0:00s	1:00	S
-Rule	Malta	1974	only	-	Sep	16	0:00s	0	-
-Rule	Malta	1975	1979	-	Apr	Sun>=15	2:00	1:00	S
-Rule	Malta	1975	1980	-	Sep	Sun>=15	2:00	0	-
-Rule	Malta	1980	only	-	Mar	31	2:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Malta	0:58:04 -	LMT	1893 Nov  2 0:00s # Valletta
-			1:00	Italy	CE%sT	1942 Nov  2 2:00s
-			1:00	C-Eur	CE%sT	1945 Apr  2 2:00s
-			1:00	Italy	CE%sT	1973 Mar 31
-			1:00	Malta	CE%sT	1981
-			1:00	EU	CE%sT
-
-# Moldova
-
-# From Paul Eggert (2006-03-22):
-# A previous version of this database followed Shanks & Pottenger, who write
-# that Tiraspol switched to Moscow time on 1992-01-19 at 02:00.
-# However, this is most likely an error, as Moldova declared independence
-# on 1991-08-27 (the 1992-01-19 date is that of a Russian decree).
-# In early 1992 there was large-scale interethnic violence in the area
-# and it's possible that some Russophones continued to observe Moscow time.
-# But [two people] separately reported via
-# Jesper Norgaard that as of 2001-01-24 Tiraspol was like Chisinau.
-# The Tiraspol entry has therefore been removed for now.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Chisinau	1:55:20 -	LMT	1880
-			1:55	-	CMT	1918 Feb 15 # Chisinau MT
-			1:44:24	-	BMT	1931 Jul 24 # Bucharest MT
-			2:00	Romania	EE%sT	1940 Aug 15
-			2:00	1:00	EEST	1941 Jul 17
-			1:00	C-Eur	CE%sT	1944 Aug 24
-			3:00	Russia	MSK/MSD	1990
-			3:00	-	MSK	1990 May 6
-			2:00	-	EET	1991
-			2:00	Russia	EE%sT	1992
-			2:00	E-Eur	EE%sT	1997
-# See Romania commentary for the guessed 1997 transition to EU rules.
-			2:00	EU	EE%sT
-
-# Monaco
-# Shanks & Pottenger give 0:09:20 for Paris Mean Time; go with Howse's
-# more precise 0:09:21.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Monaco	0:29:32 -	LMT	1891 Mar 15
-			0:09:21	-	PMT	1911 Mar 11    # Paris Mean Time
-			0:00	France	WE%sT	1945 Sep 16 3:00
-			1:00	France	CE%sT	1977
-			1:00	EU	CE%sT
-
-# Montenegro
-# see Serbia
-
-# Netherlands
-
-# Howse writes that the Netherlands' railways used GMT between 1892 and 1940,
-# but for other purposes the Netherlands used Amsterdam mean time.
-
-# However, Robert H. van Gent writes (2001-04-01):
-# Howse's statement is only correct up to 1909. From 1909-05-01 (00:00:00
-# Amsterdam mean time) onwards, the whole of the Netherlands (including
-# the Dutch railways) was required by law to observe Amsterdam mean time
-# (19 minutes 32.13 seconds ahead of GMT). This had already been the
-# common practice (except for the railways) for many decades but it was
-# not until 1909 when the Dutch government finally defined this by law.
-# On 1937-07-01 this was changed to 20 minutes (exactly) ahead of GMT and
-# was generally known as Dutch Time ("Nederlandse Tijd").
-#
-# (2001-04-08):
-# 1892-05-01 was the date when the Dutch railways were by law required to
-# observe GMT while the remainder of the Netherlands adhered to the common
-# practice of following Amsterdam mean time.
-#
-# (2001-04-09):
-# In 1835 the authorities of the province of North Holland requested the
-# municipal authorities of the towns and cities in the province to observe
-# Amsterdam mean time but I do not know in how many cases this request was
-# actually followed.
-#
-# From 1852 onwards the Dutch telegraph offices were by law required to
-# observe Amsterdam mean time. As the time signals from the observatory of
-# Leiden were also distributed by the telegraph system, I assume that most
-# places linked up with the telegraph (and railway) system automatically
-# adopted Amsterdam mean time.
-#
-# Although the early Dutch railway companies initially observed a variety
-# of times, most of them had adopted Amsterdam mean time by 1858 but it
-# was not until 1866 when they were all required by law to observe
-# Amsterdam mean time.
-
-# The data before 1945 are taken from
-# <http://www.phys.uu.nl/~vgent/wettijd/wettijd.htm>.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Neth	1916	only	-	May	 1	0:00	1:00	NST	# Netherlands Summer Time
-Rule	Neth	1916	only	-	Oct	 1	0:00	0	AMT	# Amsterdam Mean Time
-Rule	Neth	1917	only	-	Apr	16	2:00s	1:00	NST
-Rule	Neth	1917	only	-	Sep	17	2:00s	0	AMT
-Rule	Neth	1918	1921	-	Apr	Mon>=1	2:00s	1:00	NST
-Rule	Neth	1918	1921	-	Sep	lastMon	2:00s	0	AMT
-Rule	Neth	1922	only	-	Mar	lastSun	2:00s	1:00	NST
-Rule	Neth	1922	1936	-	Oct	Sun>=2	2:00s	0	AMT
-Rule	Neth	1923	only	-	Jun	Fri>=1	2:00s	1:00	NST
-Rule	Neth	1924	only	-	Mar	lastSun	2:00s	1:00	NST
-Rule	Neth	1925	only	-	Jun	Fri>=1	2:00s	1:00	NST
-# From 1926 through 1939 DST began 05-15, except that it was delayed by a week
-# in years when 05-15 fell in the Pentecost weekend.
-Rule	Neth	1926	1931	-	May	15	2:00s	1:00	NST
-Rule	Neth	1932	only	-	May	22	2:00s	1:00	NST
-Rule	Neth	1933	1936	-	May	15	2:00s	1:00	NST
-Rule	Neth	1937	only	-	May	22	2:00s	1:00	NST
-Rule	Neth	1937	only	-	Jul	 1	0:00	1:00	S
-Rule	Neth	1937	1939	-	Oct	Sun>=2	2:00s	0	-
-Rule	Neth	1938	1939	-	May	15	2:00s	1:00	S
-Rule	Neth	1945	only	-	Apr	 2	2:00s	1:00	S
-Rule	Neth	1945	only	-	Sep	16	2:00s	0	-
-#
-# Amsterdam Mean Time was +00:19:32.13 exactly, but the .13 is omitted
-# below because the current format requires GMTOFF to be an integer.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Amsterdam	0:19:32 -	LMT	1835
-			0:19:32	Neth	%s	1937 Jul  1
-			0:20	Neth	NE%sT	1940 May 16 0:00 # Dutch Time
-			1:00	C-Eur	CE%sT	1945 Apr  2 2:00
-			1:00	Neth	CE%sT	1977
-			1:00	EU	CE%sT
-
-# Norway
-# http://met.no/met/met_lex/q_u/sommertid.html (2004-01) agrees with Shanks &
-# Pottenger.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Norway	1916	only	-	May	22	1:00	1:00	S
-Rule	Norway	1916	only	-	Sep	30	0:00	0	-
-Rule	Norway	1945	only	-	Apr	 2	2:00s	1:00	S
-Rule	Norway	1945	only	-	Oct	 1	2:00s	0	-
-Rule	Norway	1959	1964	-	Mar	Sun>=15	2:00s	1:00	S
-Rule	Norway	1959	1965	-	Sep	Sun>=15	2:00s	0	-
-Rule	Norway	1965	only	-	Apr	25	2:00s	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Oslo	0:43:00 -	LMT	1895 Jan  1
-			1:00	Norway	CE%sT	1940 Aug 10 23:00
-			1:00	C-Eur	CE%sT	1945 Apr  2  2:00
-			1:00	Norway	CE%sT	1980
-			1:00	EU	CE%sT
-
-# Svalbard & Jan Mayen
-
-# From Steffen Thorsen (2001-05-01):
-# Although I could not find it explicitly, it seems that Jan Mayen and
-# Svalbard have been using the same time as Norway at least since the
-# time they were declared as parts of Norway.  Svalbard was declared
-# as a part of Norway by law of 1925-07-17 no 11, section 4 and Jan
-# Mayen by law of 1930-02-27 no 2, section 2. (From
-# http://www.lovdata.no/all/nl-19250717-011.html and
-# http://www.lovdata.no/all/nl-19300227-002.html).  The law/regulation
-# for normal/standard time in Norway is from 1894-06-29 no 1 (came
-# into operation on 1895-01-01) and Svalbard/Jan Mayen seem to be a
-# part of this law since 1925/1930. (From
-# http://www.lovdata.no/all/nl-18940629-001.html ) I have not been
-# able to find if Jan Mayen used a different time zone (e.g. -0100)
-# before 1930. Jan Mayen has only been "inhabitated" since 1921 by
-# Norwegian meteorologists and maybe used the same time as Norway ever
-# since 1921.  Svalbard (Arctic/Longyearbyen) has been inhabited since
-# before 1895, and therefore probably changed the local time somewhere
-# between 1895 and 1925 (inclusive).
-
-# From Paul Eggert (2001-05-01):
-#
-# Actually, Jan Mayen was never occupied by Germany during World War II,
-# so it must have diverged from Oslo time during the war, as Oslo was
-# keeping Berlin time.
-#
-# <http://home.no.net/janmayen/history.htm> says that the meteorologists
-# burned down their station in 1940 and left the island, but returned in
-# 1941 with a small Norwegian garrison and continued operations despite
-# frequent air ttacks from Germans.  In 1943 the Americans established a
-# radiolocating station on the island, called "Atlantic City".  Possibly
-# the UTC offset changed during the war, but I think it unlikely that
-# Jan Mayen used German daylight-saving rules.
-#
-# Svalbard is more complicated, as it was raided in August 1941 by an
-# Allied party that evacuated the civilian population to England (says
-# <http://www.bartleby.com/65/sv/Svalbard.html>).  The Svalbard FAQ
-# <http://www.svalbard.com/SvalbardFAQ.html> says that the Germans were
-# expelled on 1942-05-14.  However, small parties of Germans did return,
-# and according to Wilhelm Dege's book "War North of 80" (1954)
-# <http://www.ucalgary.ca/UofC/departments/UP/1-55238/1-55238-110-2.html>
-# the German armed forces at the Svalbard weather station code-named
-# Haudegen did not surrender to the Allies until September 1945.
-#
-# All these events predate our cutoff date of 1970.  Unless we can
-# come up with more definitive info about the timekeeping during the
-# war years it's probably best just do do the following for now:
-Link	Europe/Oslo	Arctic/Longyearbyen
-
-# Poland
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Poland	1918	1919	-	Sep	16	2:00s	0	-
-Rule	Poland	1919	only	-	Apr	15	2:00s	1:00	S
-Rule	Poland	1944	only	-	Apr	 3	2:00s	1:00	S
-# Whitman gives 1944 Nov 30; go with Shanks & Pottenger.
-Rule	Poland	1944	only	-	Oct	 4	2:00	0	-
-# For 1944-1948 Whitman gives the previous day; go with Shanks & Pottenger.
-Rule	Poland	1945	only	-	Apr	29	0:00	1:00	S
-Rule	Poland	1945	only	-	Nov	 1	0:00	0	-
-# For 1946 on the source is Kazimierz Borkowski,
-# Torun Center for Astronomy, Dept. of Radio Astronomy, Nicolaus Copernicus U.,
-# <http://www.astro.uni.torun.pl/~kb/Artykuly/U-PA/Czas2.htm#tth_tAb1>
-# Thanks to Przemyslaw Augustyniak (2005-05-28) for this reference.
-# He also gives these further references:
-# Mon Pol nr 13, poz 162 (1995) <http://www.abc.com.pl/serwis/mp/1995/0162.htm>
-# Druk nr 2180 (2003) <http://www.senat.gov.pl/k5/dok/sejm/053/2180.pdf>
-Rule	Poland	1946	only	-	Apr	14	0:00s	1:00	S
-Rule	Poland	1946	only	-	Oct	 7	2:00s	0	-
-Rule	Poland	1947	only	-	May	 4	2:00s	1:00	S
-Rule	Poland	1947	1949	-	Oct	Sun>=1	2:00s	0	-
-Rule	Poland	1948	only	-	Apr	18	2:00s	1:00	S
-Rule	Poland	1949	only	-	Apr	10	2:00s	1:00	S
-Rule	Poland	1957	only	-	Jun	 2	1:00s	1:00	S
-Rule	Poland	1957	1958	-	Sep	lastSun	1:00s	0	-
-Rule	Poland	1958	only	-	Mar	30	1:00s	1:00	S
-Rule	Poland	1959	only	-	May	31	1:00s	1:00	S
-Rule	Poland	1959	1961	-	Oct	Sun>=1	1:00s	0	-
-Rule	Poland	1960	only	-	Apr	 3	1:00s	1:00	S
-Rule	Poland	1961	1964	-	May	lastSun	1:00s	1:00	S
-Rule	Poland	1962	1964	-	Sep	lastSun	1:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Warsaw	1:24:00 -	LMT	1880
-			1:24:00	-	WMT	1915 Aug  5   # Warsaw Mean Time
-			1:00	C-Eur	CE%sT	1918 Sep 16 3:00
-			2:00	Poland	EE%sT	1922 Jun
-			1:00	Poland	CE%sT	1940 Jun 23 2:00
-			1:00	C-Eur	CE%sT	1944 Oct
-			1:00	Poland	CE%sT	1977
-			1:00	W-Eur	CE%sT	1988
-			1:00	EU	CE%sT
-
-# Portugal
-#
-# From Rui Pedro Salgueiro (1992-11-12):
-# Portugal has recently (September, 27) changed timezone
-# (from WET to MET or CET) to harmonize with EEC.
-#
-# Martin Bruckmann (1996-02-29) reports via Peter Ilieve
-# that Portugal is reverting to 0:00 by not moving its clocks this spring.
-# The new Prime Minister was fed up with getting up in the dark in the winter.
-#
-# From Paul Eggert (1996-11-12):
-# IATA SSIM (1991-09) reports several 1991-09 and 1992-09 transitions
-# at 02:00u, not 01:00u.  Assume that these are typos.
-# IATA SSIM (1991/1992) reports that the Azores were at -1:00.
-# IATA SSIM (1993-02) says +0:00; later issues (through 1996-09) say -1:00.
-# Guess that the Azores changed to EU rules in 1992 (since that's when Portugal
-# harmonized with the EU), and that they stayed +0:00 that winter.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# DSH writes that despite Decree 1,469 (1915), the change to the clocks was not
-# done every year, depending on what Spain did, because of railroad schedules.
-# Go with Shanks & Pottenger.
-Rule	Port	1916	only	-	Jun	17	23:00	1:00	S
-# Whitman gives 1916 Oct 31; go with Shanks & Pottenger.
-Rule	Port	1916	only	-	Nov	 1	 1:00	0	-
-Rule	Port	1917	only	-	Feb	28	23:00s	1:00	S
-Rule	Port	1917	1921	-	Oct	14	23:00s	0	-
-Rule	Port	1918	only	-	Mar	 1	23:00s	1:00	S
-Rule	Port	1919	only	-	Feb	28	23:00s	1:00	S
-Rule	Port	1920	only	-	Feb	29	23:00s	1:00	S
-Rule	Port	1921	only	-	Feb	28	23:00s	1:00	S
-Rule	Port	1924	only	-	Apr	16	23:00s	1:00	S
-Rule	Port	1924	only	-	Oct	14	23:00s	0	-
-Rule	Port	1926	only	-	Apr	17	23:00s	1:00	S
-Rule	Port	1926	1929	-	Oct	Sat>=1	23:00s	0	-
-Rule	Port	1927	only	-	Apr	 9	23:00s	1:00	S
-Rule	Port	1928	only	-	Apr	14	23:00s	1:00	S
-Rule	Port	1929	only	-	Apr	20	23:00s	1:00	S
-Rule	Port	1931	only	-	Apr	18	23:00s	1:00	S
-# Whitman gives 1931 Oct 8; go with Shanks & Pottenger.
-Rule	Port	1931	1932	-	Oct	Sat>=1	23:00s	0	-
-Rule	Port	1932	only	-	Apr	 2	23:00s	1:00	S
-Rule	Port	1934	only	-	Apr	 7	23:00s	1:00	S
-# Whitman gives 1934 Oct 5; go with Shanks & Pottenger.
-Rule	Port	1934	1938	-	Oct	Sat>=1	23:00s	0	-
-# Shanks & Pottenger give 1935 Apr 30; go with Whitman.
-Rule	Port	1935	only	-	Mar	30	23:00s	1:00	S
-Rule	Port	1936	only	-	Apr	18	23:00s	1:00	S
-# Whitman gives 1937 Apr 2; go with Shanks & Pottenger.
-Rule	Port	1937	only	-	Apr	 3	23:00s	1:00	S
-Rule	Port	1938	only	-	Mar	26	23:00s	1:00	S
-Rule	Port	1939	only	-	Apr	15	23:00s	1:00	S
-# Whitman gives 1939 Oct 7; go with Shanks & Pottenger.
-Rule	Port	1939	only	-	Nov	18	23:00s	0	-
-Rule	Port	1940	only	-	Feb	24	23:00s	1:00	S
-# Shanks & Pottenger give 1940 Oct 7; go with Whitman.
-Rule	Port	1940	1941	-	Oct	 5	23:00s	0	-
-Rule	Port	1941	only	-	Apr	 5	23:00s	1:00	S
-Rule	Port	1942	1945	-	Mar	Sat>=8	23:00s	1:00	S
-Rule	Port	1942	only	-	Apr	25	22:00s	2:00	M # Midsummer
-Rule	Port	1942	only	-	Aug	15	22:00s	1:00	S
-Rule	Port	1942	1945	-	Oct	Sat>=24	23:00s	0	-
-Rule	Port	1943	only	-	Apr	17	22:00s	2:00	M
-Rule	Port	1943	1945	-	Aug	Sat>=25	22:00s	1:00	S
-Rule	Port	1944	1945	-	Apr	Sat>=21	22:00s	2:00	M
-Rule	Port	1946	only	-	Apr	Sat>=1	23:00s	1:00	S
-Rule	Port	1946	only	-	Oct	Sat>=1	23:00s	0	-
-Rule	Port	1947	1949	-	Apr	Sun>=1	 2:00s	1:00	S
-Rule	Port	1947	1949	-	Oct	Sun>=1	 2:00s	0	-
-# Shanks & Pottenger say DST was observed in 1950; go with Whitman.
-# Whitman gives Oct lastSun for 1952 on; go with Shanks & Pottenger.
-Rule	Port	1951	1965	-	Apr	Sun>=1	 2:00s	1:00	S
-Rule	Port	1951	1965	-	Oct	Sun>=1	 2:00s	0	-
-Rule	Port	1977	only	-	Mar	27	 0:00s	1:00	S
-Rule	Port	1977	only	-	Sep	25	 0:00s	0	-
-Rule	Port	1978	1979	-	Apr	Sun>=1	 0:00s	1:00	S
-Rule	Port	1978	only	-	Oct	 1	 0:00s	0	-
-Rule	Port	1979	1982	-	Sep	lastSun	 1:00s	0	-
-Rule	Port	1980	only	-	Mar	lastSun	 0:00s	1:00	S
-Rule	Port	1981	1982	-	Mar	lastSun	 1:00s	1:00	S
-Rule	Port	1983	only	-	Mar	lastSun	 2:00s	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Shanks & Pottenger say the transition from LMT to WET occurred 1911-05-24;
-# Willett says 1912-01-01.  Go with Willett.
-Zone	Europe/Lisbon	-0:36:32 -	LMT	1884
-			-0:36:32 -	LMT	1912 Jan  1  # Lisbon Mean Time
-			 0:00	Port	WE%sT	1966 Apr  3 2:00
-			 1:00	-	CET	1976 Sep 26 1:00
-			 0:00	Port	WE%sT	1983 Sep 25 1:00s
-			 0:00	W-Eur	WE%sT	1992 Sep 27 1:00s
-			 1:00	EU	CE%sT	1996 Mar 31 1:00u
-			 0:00	EU	WE%sT
-Zone Atlantic/Azores	-1:42:40 -	LMT	1884		# Ponta Delgada
-			-1:54:32 -	HMT	1911 May 24  # Horta Mean Time
-			-2:00	Port	AZO%sT	1966 Apr  3 2:00 # Azores Time
-			-1:00	Port	AZO%sT	1983 Sep 25 1:00s
-			-1:00	W-Eur	AZO%sT	1992 Sep 27 1:00s
-			 0:00	EU	WE%sT	1993 Mar 28 1:00u
-			-1:00	EU	AZO%sT
-Zone Atlantic/Madeira	-1:07:36 -	LMT	1884		# Funchal
-			-1:07:36 -	FMT	1911 May 24  # Funchal Mean Time
-			-1:00	Port	MAD%sT	1966 Apr  3 2:00 # Madeira Time
-			 0:00	Port	WE%sT	1983 Sep 25 1:00s
-			 0:00	EU	WE%sT
-
-# Romania
-#
-# From Paul Eggert (1999-10-07):
-# <a href="http://www.nineoclock.ro/POL/1778pol.html">
-# Nine O'clock</a> (1998-10-23) reports that the switch occurred at
-# 04:00 local time in fall 1998.  For lack of better info,
-# assume that Romania and Moldova switched to EU rules in 1997,
-# the same year as Bulgaria.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Romania	1932	only	-	May	21	 0:00s	1:00	S
-Rule	Romania	1932	1939	-	Oct	Sun>=1	 0:00s	0	-
-Rule	Romania	1933	1939	-	Apr	Sun>=2	 0:00s	1:00	S
-Rule	Romania	1979	only	-	May	27	 0:00	1:00	S
-Rule	Romania	1979	only	-	Sep	lastSun	 0:00	0	-
-Rule	Romania	1980	only	-	Apr	 5	23:00	1:00	S
-Rule	Romania	1980	only	-	Sep	lastSun	 1:00	0	-
-Rule	Romania	1991	1993	-	Mar	lastSun	 0:00s	1:00	S
-Rule	Romania	1991	1993	-	Sep	lastSun	 0:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Bucharest	1:44:24 -	LMT	1891 Oct
-			1:44:24	-	BMT	1931 Jul 24	# Bucharest MT
-			2:00	Romania	EE%sT	1981 Mar 29 2:00s
-			2:00	C-Eur	EE%sT	1991
-			2:00	Romania	EE%sT	1994
-			2:00	E-Eur	EE%sT	1997
-			2:00	EU	EE%sT
-
-# Russia
-
-# From Paul Eggert (2006-03-22):
-# Except for Moscow after 1919-07-01, I invented the time zone abbreviations.
-# Moscow time zone abbreviations after 1919-07-01, and Moscow rules after 1991,
-# are from Andrey A. Chernov.  The rest is from Shanks & Pottenger,
-# except we follow Chernov's report that 1992 DST transitions were Sat
-# 23:00, not Sun 02:00s.
-#
-# From Stanislaw A. Kuzikowski (1994-06-29):
-# But now it is some months since Novosibirsk is 3 hours ahead of Moscow!
-# I do not know why they have decided to make this change;
-# as far as I remember it was done exactly during winter->summer switching
-# so we (Novosibirsk) simply did not switch.
-#
-# From Andrey A. Chernov (1996-10-04):
-# `MSK' and `MSD' were born and used initially on Moscow computers with
-# UNIX-like OSes by several developer groups (e.g. Demos group, Kiae group)....
-# The next step was the UUCP network, the Relcom predecessor
-# (used mainly for mail), and MSK/MSD was actively used there.
-#
-# From Chris Carrier (1996-10-30):
-# According to a friend of mine who rode the Trans-Siberian Railroad from
-# Moscow to Irkutsk in 1995, public air and rail transport in Russia ...
-# still follows Moscow time, no matter where in Russia it is located.
-#
-# For Grozny, Chechnya, we have the following story from
-# John Daniszewski, "Scavengers in the Rubble", Los Angeles Times (2001-02-07):
-# News--often false--is spread by word of mouth.  A rumor that it was
-# time to move the clocks back put this whole city out of sync with
-# the rest of Russia for two weeks--even soldiers stationed here began
-# enforcing curfew at the wrong time.
-#
-# From Gwillim Law (2001-06-05):
-# There's considerable evidence that Sakhalin Island used to be in
-# UTC+11, and has changed to UTC+10, in this decade.  I start with the
-# SSIM, which listed Yuzhno-Sakhalinsk in zone RU10 along with Magadan
-# until February 1997, and then in RU9 with Khabarovsk and Vladivostok
-# since September 1997....  Although the Kuril Islands are
-# administratively part of Sakhalin oblast', they appear to have
-# remained on UTC+11 along with Magadan.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-#
-# Kaliningradskaya oblast'.
-Zone Europe/Kaliningrad	 1:22:00 -	LMT	1893 Apr
-			 1:00	C-Eur	CE%sT	1945
-			 2:00	Poland	CE%sT	1946
-			 3:00	Russia	MSK/MSD	1991 Mar 31 2:00s
-			 2:00	Russia	EE%sT
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Respublika Adygeya, Arkhangel'skaya oblast',
-# Belgorodskaya oblast', Bryanskaya oblast', Vladimirskaya oblast',
-# Vologodskaya oblast', Voronezhskaya oblast',
-# Respublika Dagestan, Ivanovskaya oblast', Respublika Ingushetiya,
-# Kabarbino-Balkarskaya Respublika, Respublika Kalmykiya,
-# Kalyzhskaya oblast', Respublika Karachaevo-Cherkessiya,
-# Respublika Kareliya, Respublika Komi,
-# Kostromskaya oblast', Krasnodarskij kraj, Kurskaya oblast',
-# Leningradskaya oblast', Lipetskaya oblast', Respublika Marij El,
-# Respublika Mordoviya, Moskva, Moskovskaya oblast',
-# Murmanskaya oblast', Nenetskij avtonomnyj okrug,
-# Nizhegorodskaya oblast', Novgorodskaya oblast', Orlovskaya oblast',
-# Penzenskaya oblast', Pskovskaya oblast', Rostovskaya oblast',
-# Ryazanskaya oblast', Sankt-Peterburg,
-# Respublika Severnaya Osetiya, Smolenskaya oblast',
-# Stavropol'skij kraj, Tambovskaya oblast', Respublika Tatarstan,
-# Tverskaya oblast', Tyl'skaya oblast', Ul'yanovskaya oblast',
-# Chechenskaya Respublika, Chuvashskaya oblast',
-# Yaroslavskaya oblast'
-Zone Europe/Moscow	 2:30:20 -	LMT	1880
-			 2:30	-	MMT	1916 Jul  3 # Moscow Mean Time
-			 2:30:48 Russia	%s	1919 Jul  1 2:00
-			 3:00	Russia	MSK/MSD	1922 Oct
-			 2:00	-	EET	1930 Jun 21
-			 3:00	Russia	MSK/MSD	1991 Mar 31 2:00s
-			 2:00	Russia	EE%sT	1992 Jan 19 2:00s
-			 3:00	Russia	MSK/MSD
-#
-# Astrakhanskaya oblast', Kirovskaya oblast', Saratovskaya oblast',
-# Volgogradskaya oblast'.  Shanks & Pottenger say Kirov is still at +0400
-# but Wikipedia (2006-05-09) says +0300.  Perhaps it switched after the
-# others?  But we have no data.
-Zone Europe/Volgograd	 2:57:40 -	LMT	1920 Jan  3
-			 3:00	-	TSAT	1925 Apr  6 # Tsaritsyn Time
-			 3:00	-	STAT	1930 Jun 21 # Stalingrad Time
-			 4:00	-	STAT	1961 Nov 11
-			 4:00	Russia	VOL%sT	1989 Mar 26 2:00s # Volgograd T
-			 3:00	Russia	VOL%sT	1991 Mar 31 2:00s
-			 4:00	-	VOLT	1992 Mar 29 2:00s
-			 3:00	Russia	VOL%sT
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Samarskaya oblast', Udmyrtskaya respublika
-Zone Europe/Samara	 3:20:36 -	LMT	1919 Jul  1 2:00
-			 3:00	-	SAMT	1930 Jun 21
-			 4:00	-	SAMT	1935 Jan 27
-			 4:00	Russia	KUY%sT	1989 Mar 26 2:00s # Kuybyshev
-			 3:00	Russia	KUY%sT	1991 Mar 31 2:00s
-			 2:00	Russia	KUY%sT	1991 Sep 29 2:00s
-			 3:00	-	KUYT	1991 Oct 20 3:00
-			 4:00	Russia	SAM%sT	# Samara Time
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Respublika Bashkortostan, Komi-Permyatskij avtonomnyj okrug,
-# Kurganskaya oblast', Orenburgskaya oblast', Permskaya oblast',
-# Sverdlovskaya oblast', Tyumenskaya oblast',
-# Khanty-Manskijskij avtonomnyj okrug, Chelyabinskaya oblast',
-# Yamalo-Nenetskij avtonomnyj okrug.
-Zone Asia/Yekaterinburg	 4:02:24 -	LMT	1919 Jul 15 4:00
-			 4:00	-	SVET	1930 Jun 21 # Sverdlovsk Time
-			 5:00	Russia	SVE%sT	1991 Mar 31 2:00s
-			 4:00	Russia	SVE%sT	1992 Jan 19 2:00s
-			 5:00	Russia	YEK%sT	# Yekaterinburg Time
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Respublika Altaj, Altajskij kraj, Omskaya oblast'.
-Zone Asia/Omsk		 4:53:36 -	LMT	1919 Nov 14
-			 5:00	-	OMST	1930 Jun 21 # Omsk TIme
-			 6:00	Russia	OMS%sT	1991 Mar 31 2:00s
-			 5:00	Russia	OMS%sT	1992 Jan 19 2:00s
-			 6:00	Russia	OMS%sT
-#
-# From Paul Eggert (2006-08-19): I'm guessing about Tomsk here; it's
-# not clear when it switched from +7 to +6.
-# Novosibirskaya oblast', Tomskaya oblast'.
-Zone Asia/Novosibirsk	 5:31:40 -	LMT	1919 Dec 14 6:00
-			 6:00	-	NOVT	1930 Jun 21 # Novosibirsk Time
-			 7:00	Russia	NOV%sT	1991 Mar 31 2:00s
-			 6:00	Russia	NOV%sT	1992 Jan 19 2:00s
-			 7:00	Russia	NOV%sT	1993 May 23 # say Shanks & P.
-			 6:00	Russia	NOV%sT
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
-# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
-# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
-Zone Asia/Krasnoyarsk	 6:11:20 -	LMT	1920 Jan  6
-			 6:00	-	KRAT	1930 Jun 21 # Krasnoyarsk Time
-			 7:00	Russia	KRA%sT	1991 Mar 31 2:00s
-			 6:00	Russia	KRA%sT	1992 Jan 19 2:00s
-			 7:00	Russia	KRA%sT
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Respublika Buryatiya, Irkutskaya oblast',
-# Ust'-Ordynskij Buryatskij avtonomnyj okrug.
-Zone Asia/Irkutsk	 6:57:20 -	LMT	1880
-			 6:57:20 -	IMT	1920 Jan 25 # Irkutsk Mean Time
-			 7:00	-	IRKT	1930 Jun 21 # Irkutsk Time
-			 8:00	Russia	IRK%sT	1991 Mar 31 2:00s
-			 7:00	Russia	IRK%sT	1992 Jan 19 2:00s
-			 8:00	Russia	IRK%sT
-#
-# From Oscar van Vlijmen (2003-10-18): [This region consists of]
-# Aginskij Buryatskij avtonomnyj okrug, Amurskaya oblast',
-# [parts of] Respublika Sakha (Yakutiya), Chitinskaya oblast'.
-# The Sakha districts are: Aldanskij, Amginskij, Anabarskij,
-# Bulunskij, Verkhnekolymskij, Verkhnevilyujskij, Vilyujskij, Gornyj,
-# Zhiganskij, Kobyajskij, Lenskij, Megino-Kangalasskij, Mirninskij,
-# Namskij, Nyurbinskij, Olenekskij, Olekminskij, Srednekolymskij,
-# Suntarskij, Tattinskij, Ust'-Aldanskij, Khangalasskij,
-# Churapchinskij, Eveno-Bytantajskij.
-Zone Asia/Yakutsk	 8:38:40 -	LMT	1919 Dec 15
-			 8:00	-	YAKT	1930 Jun 21 # Yakutsk Time
-			 9:00	Russia	YAK%sT	1991 Mar 31 2:00s
-			 8:00	Russia	YAK%sT	1992 Jan 19 2:00s
-			 9:00	Russia	YAK%sT
-#
-# From Oscar van Vlijmen (2003-10-18): [This region consists of]
-# Evrejskaya avtonomnaya oblast', Khabarovskij kraj, Primorskij kraj,
-# [parts of] Respublika Sakha (Yakutiya).
-# The Sakha districts are: Verkhoyanskij, Tomponskij, Ust'-Majskij,
-# Ust'-Yanskij.
-Zone Asia/Vladivostok	 8:47:44 -	LMT	1922 Nov 15
-			 9:00	-	VLAT	1930 Jun 21 # Vladivostok Time
-			10:00	Russia	VLA%sT	1991 Mar 31 2:00s
-			 9:00	Russia	VLA%sST	1992 Jan 19 2:00s
-			10:00	Russia	VLA%sT
-#
-# Sakhalinskaya oblast'.
-# The Zone name should be Yuzhno-Sakhalinsk, but that's too long.
-Zone Asia/Sakhalin	 9:30:48 -	LMT	1905 Aug 23
-			 9:00	-	CJT	1938
-			 9:00	-	JST	1945 Aug 25
-			11:00	Russia	SAK%sT	1991 Mar 31 2:00s # Sakhalin T.
-			10:00	Russia	SAK%sT	1992 Jan 19 2:00s
-			11:00	Russia	SAK%sT	1997 Mar lastSun 2:00s
-			10:00	Russia	SAK%sT
-#
-# From Oscar van Vlijmen (2003-10-18): [This region consists of]
-# Magadanskaya oblast', Respublika Sakha (Yakutiya).
-# Probably also: Kuril Islands.
-# The Sakha districts are: Abyjskij, Allaikhovskij, Momskij,
-# Nizhnekolymskij, Ojmyakonskij.
-Zone Asia/Magadan	10:03:12 -	LMT	1924 May  2
-			10:00	-	MAGT	1930 Jun 21 # Magadan Time
-			11:00	Russia	MAG%sT	1991 Mar 31 2:00s
-			10:00	Russia	MAG%sT	1992 Jan 19 2:00s
-			11:00	Russia	MAG%sT
-#
-# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kamchatskaya oblast', Koryakskij avtonomnyj okrug.
-#
-# The Zone name should be Asia/Petropavlovsk-Kamchatski, but that's too long.
-Zone Asia/Kamchatka	10:34:36 -	LMT	1922 Nov 10
-			11:00	-	PETT	1930 Jun 21 # P-K Time
-			12:00	Russia	PET%sT	1991 Mar 31 2:00s
-			11:00	Russia	PET%sT	1992 Jan 19 2:00s
-			12:00	Russia	PET%sT
-#
-# Chukotskij avtonomnyj okrug
-Zone Asia/Anadyr	11:49:56 -	LMT	1924 May  2
-			12:00	-	ANAT	1930 Jun 21 # Anadyr Time
-			13:00	Russia	ANA%sT	1982 Apr  1 0:00s
-			12:00	Russia	ANA%sT	1991 Mar 31 2:00s
-			11:00	Russia	ANA%sT	1992 Jan 19 2:00s
-			12:00	Russia	ANA%sT
-
-# Serbia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Belgrade	1:22:00	-	LMT	1884
-			1:00	-	CET	1941 Apr 18 23:00
-			1:00	C-Eur	CE%sT	1945
-			1:00	-	CET	1945 May 8 2:00s
-			1:00	1:00	CEST	1945 Sep 16  2:00s
-# Metod Kozelj reports that the legal date of
-# transition to EU rules was 1982-11-27, for all of Yugoslavia at the time.
-# Shanks & Pottenger don't give as much detail, so go with Kozelj.
-			1:00	-	CET	1982 Nov 27
-			1:00	EU	CE%sT
-Link Europe/Belgrade Europe/Ljubljana	# Slovenia
-Link Europe/Belgrade Europe/Podgorica	# Montenegro
-Link Europe/Belgrade Europe/Sarajevo	# Bosnia and Herzegovina
-Link Europe/Belgrade Europe/Skopje	# Macedonia
-Link Europe/Belgrade Europe/Zagreb	# Croatia
-
-# Slovakia
-Link Europe/Prague Europe/Bratislava
-
-# Slovenia
-# see Serbia
-
-# Spain
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# For 1917-1919 Whitman gives Apr Sat>=1 - Oct Sat>=1;
-# go with Shanks & Pottenger.
-Rule	Spain	1917	only	-	May	 5	23:00s	1:00	S
-Rule	Spain	1917	1919	-	Oct	 6	23:00s	0	-
-Rule	Spain	1918	only	-	Apr	15	23:00s	1:00	S
-Rule	Spain	1919	only	-	Apr	 5	23:00s	1:00	S
-# Whitman gives 1921 Feb 28 - Oct 14; go with Shanks & Pottenger.
-Rule	Spain	1924	only	-	Apr	16	23:00s	1:00	S
-# Whitman gives 1924 Oct 14; go with Shanks & Pottenger.
-Rule	Spain	1924	only	-	Oct	 4	23:00s	0	-
-Rule	Spain	1926	only	-	Apr	17	23:00s	1:00	S
-# Whitman says no DST in 1929; go with Shanks & Pottenger.
-Rule	Spain	1926	1929	-	Oct	Sat>=1	23:00s	0	-
-Rule	Spain	1927	only	-	Apr	 9	23:00s	1:00	S
-Rule	Spain	1928	only	-	Apr	14	23:00s	1:00	S
-Rule	Spain	1929	only	-	Apr	20	23:00s	1:00	S
-# Whitman gives 1937 Jun 16, 1938 Apr 16, 1940 Apr 13;
-# go with Shanks & Pottenger.
-Rule	Spain	1937	only	-	May	22	23:00s	1:00	S
-Rule	Spain	1937	1939	-	Oct	Sat>=1	23:00s	0	-
-Rule	Spain	1938	only	-	Mar	22	23:00s	1:00	S
-Rule	Spain	1939	only	-	Apr	15	23:00s	1:00	S
-Rule	Spain	1940	only	-	Mar	16	23:00s	1:00	S
-# Whitman says no DST 1942-1945; go with Shanks & Pottenger.
-Rule	Spain	1942	only	-	May	 2	22:00s	2:00	M # Midsummer
-Rule	Spain	1942	only	-	Sep	 1	22:00s	1:00	S
-Rule	Spain	1943	1946	-	Apr	Sat>=13	22:00s	2:00	M
-Rule	Spain	1943	only	-	Oct	 3	22:00s	1:00	S
-Rule	Spain	1944	only	-	Oct	10	22:00s	1:00	S
-Rule	Spain	1945	only	-	Sep	30	 1:00	1:00	S
-Rule	Spain	1946	only	-	Sep	30	 0:00	0	-
-Rule	Spain	1949	only	-	Apr	30	23:00	1:00	S
-Rule	Spain	1949	only	-	Sep	30	 1:00	0	-
-Rule	Spain	1974	1975	-	Apr	Sat>=13	23:00	1:00	S
-Rule	Spain	1974	1975	-	Oct	Sun>=1	 1:00	0	-
-Rule	Spain	1976	only	-	Mar	27	23:00	1:00	S
-Rule	Spain	1976	1977	-	Sep	lastSun	 1:00	0	-
-Rule	Spain	1977	1978	-	Apr	 2	23:00	1:00	S
-Rule	Spain	1978	only	-	Oct	 1	 1:00	0	-
-# The following rules are copied from Morocco from 1967 through 1978.
-Rule SpainAfrica 1967	only	-	Jun	 3	12:00	1:00	S
-Rule SpainAfrica 1967	only	-	Oct	 1	 0:00	0	-
-Rule SpainAfrica 1974	only	-	Jun	24	 0:00	1:00	S
-Rule SpainAfrica 1974	only	-	Sep	 1	 0:00	0	-
-Rule SpainAfrica 1976	1977	-	May	 1	 0:00	1:00	S
-Rule SpainAfrica 1976	only	-	Aug	 1	 0:00	0	-
-Rule SpainAfrica 1977	only	-	Sep	28	 0:00	0	-
-Rule SpainAfrica 1978	only	-	Jun	 1	 0:00	1:00	S
-Rule SpainAfrica 1978	only	-	Aug	 4	 0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Madrid	-0:14:44 -	LMT	1901 Jan  1  0:00s
-			 0:00	Spain	WE%sT	1946 Sep 30
-			 1:00	Spain	CE%sT	1979
-			 1:00	EU	CE%sT
-Zone	Africa/Ceuta	-0:21:16 -	LMT	1901
-			 0:00	-	WET	1918 May  6 23:00
-			 0:00	1:00	WEST	1918 Oct  7 23:00
-			 0:00	-	WET	1924
-			 0:00	Spain	WE%sT	1929
-			 0:00 SpainAfrica WE%sT 1984 Mar 16
-			 1:00	-	CET	1986
-			 1:00	EU	CE%sT
-Zone	Atlantic/Canary	-1:01:36 -	LMT	1922 Mar # Las Palmas de Gran C.
-			-1:00	-	CANT	1946 Sep 30 1:00 # Canaries Time
-			 0:00	-	WET	1980 Apr  6 0:00s
-			 0:00	1:00	WEST	1980 Sep 28 0:00s
-			 0:00	EU	WE%sT
-# IATA SSIM (1996-09) says the Canaries switch at 2:00u, not 1:00u.
-# Ignore this for now, as the Canaries are part of the EU.
-
-# Sweden
-
-# From Ivan Nilsson (2001-04-13), superseding Shanks & Pottenger:
-#
-# The law "Svensk forfattningssamling 1878, no 14" about standard time in 1879:
-# From the beginning of 1879 (that is 01-01 00:00) the time for all
-# places in the country is "the mean solar time for the meridian at
-# three degrees, or twelve minutes of time, to the west of the
-# meridian of the Observatory of Stockholm".  The law is dated 1878-05-31.
-#
-# The observatory at that time had the meridian 18 degrees 03' 30"
-# eastern longitude = 01:12:14 in time.  Less 12 minutes gives the
-# national standard time as 01:00:14 ahead of GMT....
-#
-# About the beginning of CET in Sweden. The lawtext ("Svensk
-# forfattningssamling 1899, no 44") states, that "from the beginning
-# of 1900... ... the same as the mean solar time for the meridian at
-# the distance of one hour of time from the meridian of the English
-# observatory at Greenwich, or at 12 minutes 14 seconds to the west
-# from the meridian of the Observatory of Stockholm". The law is dated
-# 1899-06-16.  In short: At 1900-01-01 00:00:00 the new standard time
-# in Sweden is 01:00:00 ahead of GMT.
-#
-# 1916: The lawtext ("Svensk forfattningssamling 1916, no 124") states
-# that "1916-05-15 is considered to begin one hour earlier". It is
-# pretty obvious that at 05-14 23:00 the clocks are set to 05-15 00:00....
-# Further the law says, that "1916-09-30 is considered to end one hour later".
-#
-# The laws regulating [DST] are available on the site of the Swedish
-# Parliament beginning with 1985 - the laws regulating 1980/1984 are
-# not available on the site (to my knowledge they are only available
-# in Swedish): <http://www.riksdagen.se/english/work/sfst.asp> (type
-# "sommartid" without the quotes in the field "Fritext" and then click
-# the Sok-button).
-#
-# (2001-05-13):
-#
-# I have now found a newspaper stating that at 1916-10-01 01:00
-# summertime the church-clocks etc were set back one hour to show
-# 1916-10-01 00:00 standard time.  The article also reports that some
-# people thought the switch to standard time would take place already
-# at 1916-10-01 00:00 summer time, but they had to wait for another
-# hour before the event took place.
-#
-# Source: The newspaper "Dagens Nyheter", 1916-10-01, page 7 upper left.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Europe/Stockholm	1:12:12 -	LMT	1879 Jan  1
-			1:00:14	-	SET	1900 Jan  1	# Swedish Time
-			1:00	-	CET	1916 May 14 23:00
-			1:00	1:00	CEST	1916 Oct  1 01:00
-			1:00	-	CET	1980
-			1:00	EU	CE%sT
-
-# Switzerland
-# From Howse:
-# By the end of the 18th century clocks and watches became commonplace
-# and their performance improved enormously.  Communities began to keep
-# mean time in preference to apparent time -- Geneva from 1780 ....
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# From Whitman (who writes ``Midnight?''):
-Rule	Swiss	1940	only	-	Nov	 2	0:00	1:00	S
-Rule	Swiss	1940	only	-	Dec	31	0:00	0	-
-# From Shanks & Pottenger:
-Rule	Swiss	1941	1942	-	May	Sun>=1	2:00	1:00	S
-Rule	Swiss	1941	1942	-	Oct	Sun>=1	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Zurich	0:34:08 -	LMT	1848 Sep 12
-			0:29:44	-	BMT	1894 Jun # Bern Mean Time
-			1:00	Swiss	CE%sT	1981
-			1:00	EU	CE%sT
-
-# Turkey
-
-# From Amar Devegowda (2007-01-03):
-# The time zone rules for Istanbul, Turkey have not been changed for years now.
-# ... The latest rules are available at -
-# http://www.timeanddate.com/worldclock/timezone.html?n=107
-# From Steffen Thorsen (2007-01-03):
-# I have been able to find press records back to 1996 which all say that
-# DST started 01:00 local time and end at 02:00 local time.  I am not sure
-# what happened before that.  One example for each year from 1996 to 2001:
-# http://newspot.byegm.gov.tr/arsiv/1996/21/N4.htm
-# http://www.byegm.gov.tr/YAYINLARIMIZ/CHR/ING97/03/97X03X25.TXT
-# http://www.byegm.gov.tr/YAYINLARIMIZ/CHR/ING98/03/98X03X02.HTM
-# http://www.byegm.gov.tr/YAYINLARIMIZ/CHR/ING99/10/99X10X26.HTM#%2016
-# http://www.byegm.gov.tr/YAYINLARIMIZ/CHR/ING2000/03/00X03X06.HTM#%2021
-# http://www.byegm.gov.tr/YAYINLARIMIZ/CHR/ING2001/03/23x03x01.HTM#%2027
-# From Paul Eggert (2007-01-03):
-# Prefer the above source to Shanks & Pottenger for time stamps after 1990.
-
-# From Steffen Thorsen (2007-03-09):
-# Starting 2007 though, it seems that they are adopting EU's 1:00 UTC
-# start/end time, according to the following page (2007-03-07):
-# http://www.ntvmsnbc.com/news/402029.asp
-# The official document is located here - it is in Turkish...:
-# http://rega.basbakanlik.gov.tr/eskiler/2007/03/20070307-7.htm
-# I was able to locate the following seemingly official document
-# (on a non-government server though) describing dates between 2002 and 2006:
-# http://www.alomaliye.com/bkk_2002_3769.htm
-
-# From Sue Williams (2008-08-11):
-# I spotted this news article about a potential change in Turkey.
-#
-# <a href="http://www.hurriyet.com.tr/english/domestic/9626174.asp?scr=1">
-# http://www.hurriyet.com.tr/english/domestic/9626174.asp?scr=1
-# </a>
-
-# From Sue Williams (2008-08-20):
-# This article says that around the end of March 2011, Turkey wants to
-# adjust the clocks forward by 1/2 hour and stay that way permanently.
-# The article indicates that this is a change in timezone offset in addition
-# to stopping observance of DST.
-# This proposal has not yet been approved.
-#
-# Read more here...
-#
-# Turkey to abandon daylight saving time in 2011
-# <a href="http://www.turkishdailynews.com.tr/article.php?enewsid=112989">
-# http://www.turkishdailynews.com.tr/article.php?enewsid=112989
-# </a>
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Turkey	1916	only	-	May	 1	0:00	1:00	S
-Rule	Turkey	1916	only	-	Oct	 1	0:00	0	-
-Rule	Turkey	1920	only	-	Mar	28	0:00	1:00	S
-Rule	Turkey	1920	only	-	Oct	25	0:00	0	-
-Rule	Turkey	1921	only	-	Apr	 3	0:00	1:00	S
-Rule	Turkey	1921	only	-	Oct	 3	0:00	0	-
-Rule	Turkey	1922	only	-	Mar	26	0:00	1:00	S
-Rule	Turkey	1922	only	-	Oct	 8	0:00	0	-
-# Whitman gives 1923 Apr 28 - Sep 16 and no DST in 1924-1925;
-# go with Shanks & Pottenger.
-Rule	Turkey	1924	only	-	May	13	0:00	1:00	S
-Rule	Turkey	1924	1925	-	Oct	 1	0:00	0	-
-Rule	Turkey	1925	only	-	May	 1	0:00	1:00	S
-Rule	Turkey	1940	only	-	Jun	30	0:00	1:00	S
-Rule	Turkey	1940	only	-	Oct	 5	0:00	0	-
-Rule	Turkey	1940	only	-	Dec	 1	0:00	1:00	S
-Rule	Turkey	1941	only	-	Sep	21	0:00	0	-
-Rule	Turkey	1942	only	-	Apr	 1	0:00	1:00	S
-# Whitman omits the next two transition and gives 1945 Oct 1;
-# go with Shanks & Pottenger.
-Rule	Turkey	1942	only	-	Nov	 1	0:00	0	-
-Rule	Turkey	1945	only	-	Apr	 2	0:00	1:00	S
-Rule	Turkey	1945	only	-	Oct	 8	0:00	0	-
-Rule	Turkey	1946	only	-	Jun	 1	0:00	1:00	S
-Rule	Turkey	1946	only	-	Oct	 1	0:00	0	-
-Rule	Turkey	1947	1948	-	Apr	Sun>=16	0:00	1:00	S
-Rule	Turkey	1947	1950	-	Oct	Sun>=2	0:00	0	-
-Rule	Turkey	1949	only	-	Apr	10	0:00	1:00	S
-Rule	Turkey	1950	only	-	Apr	19	0:00	1:00	S
-Rule	Turkey	1951	only	-	Apr	22	0:00	1:00	S
-Rule	Turkey	1951	only	-	Oct	 8	0:00	0	-
-Rule	Turkey	1962	only	-	Jul	15	0:00	1:00	S
-Rule	Turkey	1962	only	-	Oct	 8	0:00	0	-
-Rule	Turkey	1964	only	-	May	15	0:00	1:00	S
-Rule	Turkey	1964	only	-	Oct	 1	0:00	0	-
-Rule	Turkey	1970	1972	-	May	Sun>=2	0:00	1:00	S
-Rule	Turkey	1970	1972	-	Oct	Sun>=2	0:00	0	-
-Rule	Turkey	1973	only	-	Jun	 3	1:00	1:00	S
-Rule	Turkey	1973	only	-	Nov	 4	3:00	0	-
-Rule	Turkey	1974	only	-	Mar	31	2:00	1:00	S
-Rule	Turkey	1974	only	-	Nov	 3	5:00	0	-
-Rule	Turkey	1975	only	-	Mar	30	0:00	1:00	S
-Rule	Turkey	1975	1976	-	Oct	lastSun	0:00	0	-
-Rule	Turkey	1976	only	-	Jun	 1	0:00	1:00	S
-Rule	Turkey	1977	1978	-	Apr	Sun>=1	0:00	1:00	S
-Rule	Turkey	1977	only	-	Oct	16	0:00	0	-
-Rule	Turkey	1979	1980	-	Apr	Sun>=1	3:00	1:00	S
-Rule	Turkey	1979	1982	-	Oct	Mon>=11	0:00	0	-
-Rule	Turkey	1981	1982	-	Mar	lastSun	3:00	1:00	S
-Rule	Turkey	1983	only	-	Jul	31	0:00	1:00	S
-Rule	Turkey	1983	only	-	Oct	 2	0:00	0	-
-Rule	Turkey	1985	only	-	Apr	20	0:00	1:00	S
-Rule	Turkey	1985	only	-	Sep	28	0:00	0	-
-Rule	Turkey	1986	1990	-	Mar	lastSun	2:00s	1:00	S
-Rule	Turkey	1986	1990	-	Sep	lastSun	2:00s	0	-
-Rule	Turkey	1991	2006	-	Mar	lastSun	1:00s	1:00	S
-Rule	Turkey	1991	1995	-	Sep	lastSun	1:00s	0	-
-Rule	Turkey	1996	2006	-	Oct	lastSun	1:00s	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Europe/Istanbul	1:55:52 -	LMT	1880
-			1:56:56	-	IMT	1910 Oct # Istanbul Mean Time?
-			2:00	Turkey	EE%sT	1978 Oct 15
-			3:00	Turkey	TR%sT	1985 Apr 20 # Turkey Time
-			2:00	Turkey	EE%sT	2007
-			2:00	EU	EE%sT
-Link	Europe/Istanbul	Asia/Istanbul	# Istanbul is in both continents.
-
-# Ukraine
-#
-# From Igor Karpov, who works for the Ukranian Ministry of Justice,
-# via Garrett Wollman (2003-01-27):
-# BTW, I've found the official document on this matter. It's goverment
-# regulations number 509, May 13, 1996. In my poor translation it says:
-# "Time in Ukraine is set to second timezone (Kiev time). Each last Sunday
-# of March at 3am the time is changing to 4am and each last Sunday of
-# October the time at 4am is changing to 3am"
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Most of Ukraine since 1970 has been like Kiev.
-# "Kyiv" is the transliteration of the Ukrainian name, but
-# "Kiev" is more common in English.
-Zone Europe/Kiev	2:02:04 -	LMT	1880
-			2:02:04	-	KMT	1924 May  2 # Kiev Mean Time
-			2:00	-	EET	1930 Jun 21
-			3:00	-	MSK	1941 Sep 20
-			1:00	C-Eur	CE%sT	1943 Nov  6
-			3:00	Russia	MSK/MSD	1990
-			3:00	-	MSK	1990 Jul  1 2:00
-			2:00	-	EET	1992
-			2:00	E-Eur	EE%sT	1995
-			2:00	EU	EE%sT
-# Ruthenia used CET 1990/1991.
-# "Uzhhorod" is the transliteration of the Ukrainian name, but
-# "Uzhgorod" is more common in English.
-Zone Europe/Uzhgorod	1:29:12 -	LMT	1890 Oct
-			1:00	-	CET	1940
-			1:00	C-Eur	CE%sT	1944 Oct
-			1:00	1:00	CEST	1944 Oct 26
-			1:00	-	CET	1945 Jun 29
-			3:00	Russia	MSK/MSD	1990
-			3:00	-	MSK	1990 Jul  1 2:00
-			1:00	-	CET	1991 Mar 31 3:00
-			2:00	-	EET	1992
-			2:00	E-Eur	EE%sT	1995
-			2:00	EU	EE%sT
-# Zaporozh'ye and eastern Lugansk oblasts observed DST 1990/1991.
-# "Zaporizhia" is the transliteration of the Ukrainian name, but
-# "Zaporozh'ye" is more common in English.  Use the common English
-# spelling, except omit the apostrophe as it is not allowed in
-# portable Posix file names.
-Zone Europe/Zaporozhye	2:20:40 -	LMT	1880
-			2:20	-	CUT	1924 May  2 # Central Ukraine T
-			2:00	-	EET	1930 Jun 21
-			3:00	-	MSK	1941 Aug 25
-			1:00	C-Eur	CE%sT	1943 Oct 25
-			3:00	Russia	MSK/MSD	1991 Mar 31 2:00
-			2:00	E-Eur	EE%sT	1995
-			2:00	EU	EE%sT
-# Central Crimea used Moscow time 1994/1997.
-Zone Europe/Simferopol	2:16:24 -	LMT	1880
-			2:16	-	SMT	1924 May  2 # Simferopol Mean T
-			2:00	-	EET	1930 Jun 21
-			3:00	-	MSK	1941 Nov
-			1:00	C-Eur	CE%sT	1944 Apr 13
-			3:00	Russia	MSK/MSD	1990
-			3:00	-	MSK	1990 Jul  1 2:00
-			2:00	-	EET	1992
-# From Paul Eggert (2006-03-22):
-# The _Economist_ (1994-05-28, p 45) reports that central Crimea switched
-# from Kiev to Moscow time sometime after the January 1994 elections.
-# Shanks (1999) says ``date of change uncertain'', but implies that it happened
-# sometime between the 1994 DST switches.  Shanks & Pottenger simply say
-# 1994-09-25 03:00, but that can't be right.  For now, guess it
-# changed in May.
-			2:00	E-Eur	EE%sT	1994 May
-# From IATA SSIM (1994/1997), which also says that Kerch is still like Kiev.
-			3:00	E-Eur	MSK/MSD	1996 Mar 31 3:00s
-			3:00	1:00	MSD	1996 Oct 27 3:00s
-# IATA SSIM (1997-09) says Crimea switched to EET/EEST.
-# Assume it happened in March by not changing the clocks.
-			3:00	Russia	MSK/MSD	1997
-			3:00	-	MSK	1997 Mar lastSun 1:00u
-			2:00	EU	EE%sT
-
-###############################################################################
-
-# One source shows that Bulgaria, Cyprus, Finland, and Greece observe DST from
-# the last Sunday in March to the last Sunday in September in 1986.
-# The source shows Romania changing a day later than everybody else.
-#
-# According to Bernard Sieloff's source, Poland is in the MET time zone but
-# uses the WE DST rules.  The Western USSR uses EET+1 and ME DST rules.
-# Bernard Sieloff's source claims Romania switches on the same day, but at
-# 00:00 standard time (i.e., 01:00 DST).  It also claims that Turkey
-# switches on the same day, but switches on at 01:00 standard time
-# and off at 00:00 standard time (i.e., 01:00 DST)
-
-# ...
-# Date: Wed, 28 Jan 87 16:56:27 -0100
-# From: Tom Hofmann
-# ...
-#
-# ...the European time rules are...standardized since 1981, when
-# most European coun[tr]ies started DST.  Before that year, only
-# a few countries (UK, France, Italy) had DST, each according
-# to own national rules.  In 1981, however, DST started on
-# 'Apr firstSun', and not on 'Mar lastSun' as in the following
-# years...
-# But also since 1981 there are some more national exceptions
-# than listed in 'europe': Switzerland, for example, joined DST
-# one year later, Denmark ended DST on 'Oct 1' instead of 'Sep
-# lastSun' in 1981---I don't know how they handle now.
-#
-# Finally, DST ist always from 'Apr 1' to 'Oct 1' in the
-# Soviet Union (as far as I know).
-#
-# Tom Hofmann, Scientific Computer Center, CIBA-GEIGY AG,
-# 4002 Basle, Switzerland
-# ...
-
-# ...
-# Date: Wed, 4 Feb 87 22:35:22 +0100
-# From: Dik T. Winter
-# ...
-#
-# The information from Tom Hofmann is (as far as I know) not entirely correct.
-# After a request from chongo at amdahl I tried to retrieve all information
-# about DST in Europe.  I was able to find all from about 1969.
-#
-# ...standardization on DST in Europe started in about 1977 with switches on
-# first Sunday in April and last Sunday in September...
-# In 1981 UK joined Europe insofar that
-# the starting day for both shifted to last Sunday in March.  And from 1982
-# the whole of Europe used DST, with switch dates April 1 and October 1 in
-# the Sov[i]et Union.  In 1985 the SU reverted to standard Europe[a]n switch
-# dates...
-#
-# It should also be remembered that time-zones are not constants; e.g.
-# Portugal switched in 1976 from MET (or CET) to WET with DST...
-# Note also that though there were rules for switch dates not
-# all countries abided to these dates, and many individual deviations
-# occurred, though not since 1982 I believe.  Another note: it is always
-# assumed that DST is 1 hour ahead of normal time, this need not be the
-# case; at least in the Netherlands there have been times when DST was 2 hours
-# in advance of normal time.
-#
-# ...
-# dik t. winter, cwi, amsterdam, nederland
-# ...
-
-# From Bob Devine (1988-01-28):
-# ...
-# Greece: Last Sunday in April to last Sunday in September (iffy on dates).
-# Since 1978.  Change at midnight.
-# ...
-# Monaco: has same DST as France.
-# ...
diff --git a/tools/zoneinfo/tzdata2008h/factory b/tools/zoneinfo/tzdata2008h/factory
deleted file mode 100644
index 946063c..0000000
--- a/tools/zoneinfo/tzdata2008h/factory
+++ /dev/null
@@ -1,8 +0,0 @@
-# @(#)factory	8.1
-
-# For companies who don't want to put time zone specification in
-# their installation procedures.  When users run date, they'll get the message.
-# Also useful for the "comp.sources" version.
-
-# Zone	NAME	GMTOFF	RULES	FORMAT
-Zone	Factory	0	- "Local time zone must be set--see zic manual page"
diff --git a/tools/zoneinfo/tzdata2008h/iso3166.tab b/tools/zoneinfo/tzdata2008h/iso3166.tab
deleted file mode 100644
index 8d62399..0000000
--- a/tools/zoneinfo/tzdata2008h/iso3166.tab
+++ /dev/null
@@ -1,269 +0,0 @@
-# ISO 3166 alpha-2 country codes
-#
-# @(#)iso3166.tab	8.5
-#
-# From Paul Eggert (2006-09-27):
-#
-# This file contains a table with the following columns:
-# 1.  ISO 3166-1 alpha-2 country code, current as of
-#     ISO 3166-1 Newsletter VI-1 (2007-09-21).  See:
-#     <a href="http://www.iso.org/iso/en/prods-services/iso3166ma/index.html">
-#     ISO 3166 Maintenance agency (ISO 3166/MA)
-#     </a>.
-# 2.  The usual English name for the country,
-#     chosen so that alphabetic sorting of subsets produces helpful lists.
-#     This is not the same as the English name in the ISO 3166 tables.
-#
-# Columns are separated by a single tab.
-# The table is sorted by country code.
-#
-# Lines beginning with `#' are comments.
-#
-#country-
-#code	country name
-AD	Andorra
-AE	United Arab Emirates
-AF	Afghanistan
-AG	Antigua & Barbuda
-AI	Anguilla
-AL	Albania
-AM	Armenia
-AN	Netherlands Antilles
-AO	Angola
-AQ	Antarctica
-AR	Argentina
-AS	Samoa (American)
-AT	Austria
-AU	Australia
-AW	Aruba
-AX	Aaland Islands
-AZ	Azerbaijan
-BA	Bosnia & Herzegovina
-BB	Barbados
-BD	Bangladesh
-BE	Belgium
-BF	Burkina Faso
-BG	Bulgaria
-BH	Bahrain
-BI	Burundi
-BJ	Benin
-BL	St Barthelemy
-BM	Bermuda
-BN	Brunei
-BO	Bolivia
-BR	Brazil
-BS	Bahamas
-BT	Bhutan
-BV	Bouvet Island
-BW	Botswana
-BY	Belarus
-BZ	Belize
-CA	Canada
-CC	Cocos (Keeling) Islands
-CD	Congo (Dem. Rep.)
-CF	Central African Rep.
-CG	Congo (Rep.)
-CH	Switzerland
-CI	Cote d'Ivoire
-CK	Cook Islands
-CL	Chile
-CM	Cameroon
-CN	China
-CO	Colombia
-CR	Costa Rica
-CU	Cuba
-CV	Cape Verde
-CX	Christmas Island
-CY	Cyprus
-CZ	Czech Republic
-DE	Germany
-DJ	Djibouti
-DK	Denmark
-DM	Dominica
-DO	Dominican Republic
-DZ	Algeria
-EC	Ecuador
-EE	Estonia
-EG	Egypt
-EH	Western Sahara
-ER	Eritrea
-ES	Spain
-ET	Ethiopia
-FI	Finland
-FJ	Fiji
-FK	Falkland Islands
-FM	Micronesia
-FO	Faroe Islands
-FR	France
-GA	Gabon
-GB	Britain (UK)
-GD	Grenada
-GE	Georgia
-GF	French Guiana
-GG	Guernsey
-GH	Ghana
-GI	Gibraltar
-GL	Greenland
-GM	Gambia
-GN	Guinea
-GP	Guadeloupe
-GQ	Equatorial Guinea
-GR	Greece
-GS	South Georgia & the South Sandwich Islands
-GT	Guatemala
-GU	Guam
-GW	Guinea-Bissau
-GY	Guyana
-HK	Hong Kong
-HM	Heard Island & McDonald Islands
-HN	Honduras
-HR	Croatia
-HT	Haiti
-HU	Hungary
-ID	Indonesia
-IE	Ireland
-IL	Israel
-IM	Isle of Man
-IN	India
-IO	British Indian Ocean Territory
-IQ	Iraq
-IR	Iran
-IS	Iceland
-IT	Italy
-JE	Jersey
-JM	Jamaica
-JO	Jordan
-JP	Japan
-KE	Kenya
-KG	Kyrgyzstan
-KH	Cambodia
-KI	Kiribati
-KM	Comoros
-KN	St Kitts & Nevis
-KP	Korea (North)
-KR	Korea (South)
-KW	Kuwait
-KY	Cayman Islands
-KZ	Kazakhstan
-LA	Laos
-LB	Lebanon
-LC	St Lucia
-LI	Liechtenstein
-LK	Sri Lanka
-LR	Liberia
-LS	Lesotho
-LT	Lithuania
-LU	Luxembourg
-LV	Latvia
-LY	Libya
-MA	Morocco
-MC	Monaco
-MD	Moldova
-ME	Montenegro
-MF	St Martin (French part)
-MG	Madagascar
-MH	Marshall Islands
-MK	Macedonia
-ML	Mali
-MM	Myanmar (Burma)
-MN	Mongolia
-MO	Macau
-MP	Northern Mariana Islands
-MQ	Martinique
-MR	Mauritania
-MS	Montserrat
-MT	Malta
-MU	Mauritius
-MV	Maldives
-MW	Malawi
-MX	Mexico
-MY	Malaysia
-MZ	Mozambique
-NA	Namibia
-NC	New Caledonia
-NE	Niger
-NF	Norfolk Island
-NG	Nigeria
-NI	Nicaragua
-NL	Netherlands
-NO	Norway
-NP	Nepal
-NR	Nauru
-NU	Niue
-NZ	New Zealand
-OM	Oman
-PA	Panama
-PE	Peru
-PF	French Polynesia
-PG	Papua New Guinea
-PH	Philippines
-PK	Pakistan
-PL	Poland
-PM	St Pierre & Miquelon
-PN	Pitcairn
-PR	Puerto Rico
-PS	Palestine
-PT	Portugal
-PW	Palau
-PY	Paraguay
-QA	Qatar
-RE	Reunion
-RO	Romania
-RS	Serbia
-RU	Russia
-RW	Rwanda
-SA	Saudi Arabia
-SB	Solomon Islands
-SC	Seychelles
-SD	Sudan
-SE	Sweden
-SG	Singapore
-SH	St Helena
-SI	Slovenia
-SJ	Svalbard & Jan Mayen
-SK	Slovakia
-SL	Sierra Leone
-SM	San Marino
-SN	Senegal
-SO	Somalia
-SR	Suriname
-ST	Sao Tome & Principe
-SV	El Salvador
-SY	Syria
-SZ	Swaziland
-TC	Turks & Caicos Is
-TD	Chad
-TF	French Southern & Antarctic Lands
-TG	Togo
-TH	Thailand
-TJ	Tajikistan
-TK	Tokelau
-TL	East Timor
-TM	Turkmenistan
-TN	Tunisia
-TO	Tonga
-TR	Turkey
-TT	Trinidad & Tobago
-TV	Tuvalu
-TW	Taiwan
-TZ	Tanzania
-UA	Ukraine
-UG	Uganda
-UM	US minor outlying islands
-US	United States
-UY	Uruguay
-UZ	Uzbekistan
-VA	Vatican City
-VC	St Vincent
-VE	Venezuela
-VG	Virgin Islands (UK)
-VI	Virgin Islands (US)
-VN	Vietnam
-VU	Vanuatu
-WF	Wallis & Futuna
-WS	Samoa (western)
-YE	Yemen
-YT	Mayotte
-ZA	South Africa
-ZM	Zambia
-ZW	Zimbabwe
diff --git a/tools/zoneinfo/tzdata2008h/leapseconds b/tools/zoneinfo/tzdata2008h/leapseconds
deleted file mode 100644
index a2f4f0b..0000000
--- a/tools/zoneinfo/tzdata2008h/leapseconds
+++ /dev/null
@@ -1,92 +0,0 @@
-# @(#)leapseconds	8.6
-
-# Allowance for leapseconds added to each timezone file.
-
-# The International Earth Rotation Service periodically uses leap seconds
-# to keep UTC to within 0.9 s of UT1
-# (which measures the true angular orientation of the earth in space); see
-# Terry J Quinn, The BIPM and the accurate measure of time,
-# Proc IEEE 79, 7 (July 1991), 894-905.
-# There were no leap seconds before 1972, because the official mechanism
-# accounting for the discrepancy between atomic time and the earth's rotation
-# did not exist until the early 1970s.
-
-# The correction (+ or -) is made at the given time, so lines
-# will typically look like:
-#	Leap	YEAR	MON	DAY	23:59:60	+	R/S
-# or
-#	Leap	YEAR	MON	DAY	23:59:59	-	R/S
-
-# If the leapsecond is Rolling (R) the given time is local time
-# If the leapsecond is Stationary (S) the given time is UTC
-
-# Leap	YEAR	MONTH	DAY	HH:MM:SS	CORR	R/S
-Leap	1972	Jun	30	23:59:60	+	S
-Leap	1972	Dec	31	23:59:60	+	S
-Leap	1973	Dec	31	23:59:60	+	S
-Leap	1974	Dec	31	23:59:60	+	S
-Leap	1975	Dec	31	23:59:60	+	S
-Leap	1976	Dec	31	23:59:60	+	S
-Leap	1977	Dec	31	23:59:60	+	S
-Leap	1978	Dec	31	23:59:60	+	S
-Leap	1979	Dec	31	23:59:60	+	S
-Leap	1981	Jun	30	23:59:60	+	S
-Leap	1982	Jun	30	23:59:60	+	S
-Leap	1983	Jun	30	23:59:60	+	S
-Leap	1985	Jun	30	23:59:60	+	S
-Leap	1987	Dec	31	23:59:60	+	S
-Leap	1989	Dec	31	23:59:60	+	S
-Leap	1990	Dec	31	23:59:60	+	S
-Leap	1992	Jun	30	23:59:60	+	S
-Leap	1993	Jun	30	23:59:60	+	S
-Leap	1994	Jun	30	23:59:60	+	S
-Leap	1995	Dec	31	23:59:60	+	S
-Leap	1997	Jun	30	23:59:60	+	S
-Leap	1998	Dec	31	23:59:60	+	S
-Leap	2005	Dec	31	23:59:60	+	S
-Leap	2008	Dec	31	23:59:60	+	S
-
-# INTERNATIONAL EARTH ROTATION AND REFERENCE SYSTEMS SERVICE (IERS)
-#
-# SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE ET DES SYSTEMES DE REFERENCE
-#
-# SERVICE DE LA ROTATION TERRESTRE
-# OBSERVATOIRE DE PARIS
-# 61, Av. de l'Observatoire 75014 PARIS (France)
-# Tel.      : 33 (0) 1 40 51 22 26
-# FAX       : 33 (0) 1 40 51 22 91
-# e-mail    : services.iers@obspm.fr
-# http://hpiers.obspm.fr/eop-pc
-#
-# Paris, 4 July 2008
-#
-# Bulletin C 36
-#
-# To authorities responsible
-# for the measurement and
-# distribution of time
-#
-# UTC TIME STEP
-# on the 1st of January 2009
-#
-# A positive leap second will be introduced at the end of December 2008.
-# The sequence of dates of the UTC second markers will be:		
-#
-# 2008 December 31,     23h 59m 59s
-# 2008 December 31,     23h 59m 60s
-# 2009 January   1,      0h  0m  0s
-#
-# The difference between UTC and the International Atomic Time TAI is:
-#
-# from 2006 January 1, 0h UTC, to 2009 January 1  0h UTC  : UTC-TAI = - 33s
-# from 2009 January 1, 0h UTC, until further notice       : UTC-TAI = - 34s
-#
-# Leap seconds can be introduced in UTC at the end of the months of December
-# or June, depending on the evolution of UT1-TAI. Bulletin C is mailed every
-# six months, either to announce a time step in UTC or to confirm that there
-# will be no time step at the next possible date.
-#
-# Daniel GAMBIS
-# Head		
-# Earth Orientation Center of IERS
-# Observatoire de Paris, France
diff --git a/tools/zoneinfo/tzdata2008h/northamerica b/tools/zoneinfo/tzdata2008h/northamerica
deleted file mode 100644
index b8b333c..0000000
--- a/tools/zoneinfo/tzdata2008h/northamerica
+++ /dev/null
@@ -1,2651 +0,0 @@
-# @(#)northamerica	8.24
-# <pre>
-
-# also includes Central America and the Caribbean
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (1999-03-22):
-# A reliable and entertaining source about time zones is
-# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997).
-
-###############################################################################
-
-# United States
-
-# From Paul Eggert (1999-03-31):
-# Howse writes (pp 121-125) that time zones were invented by
-# Professor Charles Ferdinand Dowd (1825-1904),
-# Principal of Temple Grove Ladies' Seminary (Saratoga Springs, NY).
-# His pamphlet ``A System of National Time for Railroads'' (1870)
-# was the result of his proposals at the Convention of Railroad Trunk Lines
-# in New York City (1869-10).  His 1870 proposal was based on Washington, DC,
-# but in 1872-05 he moved the proposed origin to Greenwich.
-# His proposal was adopted by the railroads on 1883-11-18 at 12:00,
-# and the most of the country soon followed suit.
-
-# From Paul Eggert (2005-04-16):
-# That 1883 transition occurred at 12:00 new time, not at 12:00 old time.
-# See p 46 of David Prerau, Seize the daylight, Thunder's Mouth Press (2005).
-
-# From Paul Eggert (2006-03-22):
-# A good source for time zone historical data in the US is
-# Thomas G. Shanks, The American Atlas (5th edition),
-# San Diego: ACS Publications, Inc. (1991).
-# Make sure you have the errata sheet; the book is somewhat useless without it.
-# It is the source for most of the pre-1991 US entries below.
-
-# From Paul Eggert (2001-03-06):
-# Daylight Saving Time was first suggested as a joke by Benjamin Franklin
-# in his whimsical essay ``An Economical Project for Diminishing the Cost
-# of Light'' published in the Journal de Paris (1784-04-26).
-# Not everyone is happy with the results:
-#
-#	I don't really care how time is reckoned so long as there is some
-#	agreement about it, but I object to being told that I am saving
-#	daylight when my reason tells me that I am doing nothing of the kind.
-#	I even object to the implication that I am wasting something
-#	valuable if I stay in bed after the sun has risen.  As an admirer
-#	of moonlight I resent the bossy insistence of those who want to
-#	reduce my time for enjoying it.  At the back of the Daylight Saving
-#	scheme I detect the bony, blue-fingered hand of Puritanism, eager
-#	to push people into bed earlier, and get them up earlier, to make
-#	them healthy, wealthy and wise in spite of themselves.
-#
-#	-- Robertson Davies, The diary of Samuel Marchbanks,
-#	   Clarke, Irwin (1947), XIX, Sunday
-#
-# For more about the first ten years of DST in the United States, see
-# Robert Garland's <a href="http://www.clpgh.org/exhibit/dst.html">
-# Ten years of daylight saving from the Pittsburgh standpoint
-# (Carnegie Library of Pittsburgh, 1927)</a>.
-#
-# Shanks says that DST was called "War Time" in the US in 1918 and 1919.
-# However, DST was imposed by the Standard Time Act of 1918, which
-# was the first nationwide legal time standard, and apparently
-# time was just called "Standard Time" or "Daylight Saving Time".
-
-# From Arthur David Olson:
-# US Daylight Saving Time ended on the last Sunday of *October* in 1974.
-# See, for example, the front page of the Saturday, 1974-10-26
-# and Sunday, 1974-10-27 editions of the Washington Post.
-
-# From Arthur David Olson:
-# Before the Uniform Time Act of 1966 took effect in 1967, observance of
-# Daylight Saving Time in the US was by local option, except during wartime.
-
-# From Arthur David Olson (2000-09-25):
-# Last night I heard part of a rebroadcast of a 1945 Arch Oboler radio drama.
-# In the introduction, Oboler spoke of "Eastern Peace Time."
-# An AltaVista search turned up
-# <a href="http://rowayton.org/rhs/hstaug45.html">:
-# "When the time is announced over the radio now, it is 'Eastern Peace
-# Time' instead of the old familiar 'Eastern War Time.'  Peace is wonderful."
-# </a> (August 1945) by way of confirmation.
-
-# From Joseph Gallant citing
-# George H. Douglas, _The Early Days of Radio Broadcasting_ (1987):
-# At 7 P.M. (Eastern War Time) [on 1945-08-14], the networks were set
-# to switch to London for Attlee's address, but the American people
-# never got to hear his speech live. According to one press account,
-# CBS' Bob Trout was first to announce the word of Japan's surrender,
-# but a few seconds later, NBC, ABC and Mutual also flashed the word
-# of surrender, all of whom interrupting the bells of Big Ben in
-# London which were to precede Mr. Attlee's speech.
-
-# From Paul Eggert (2003-02-09): It was Robert St John, not Bob Trout.  From
-# Myrna Oliver's obituary of St John on page B16 of today's Los Angeles Times:
-#
-# ... a war-weary U.S. clung to radios, awaiting word of Japan's surrender.
-# Any announcement from Asia would reach St. John's New York newsroom on a
-# wire service teletype machine, which had prescribed signals for major news.
-# Associated Press, for example, would ring five bells before spewing out
-# typed copy of an important story, and 10 bells for news "of transcendental
-# importance."
-#
-# On Aug. 14, stalling while talking steadily into the NBC networks' open
-# microphone, St. John heard five bells and waited only to hear a sixth bell,
-# before announcing confidently: "Ladies and gentlemen, World War II is over.
-# The Japanese have agreed to our surrender terms."
-#
-# He had scored a 20-second scoop on other broadcasters.
-
-# From Arthur David Olson (2005-08-22):
-# Paul has been careful to use the "US" rules only in those locations
-# that are part of the United States; this reflects the real scope of
-# U.S. government action.  So even though the "US" rules have changed
-# in the latest release, other countries won't be affected.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	US	1918	1919	-	Mar	lastSun	2:00	1:00	D
-Rule	US	1918	1919	-	Oct	lastSun	2:00	0	S
-Rule	US	1942	only	-	Feb	9	2:00	1:00	W # War
-Rule	US	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	US	1945	only	-	Sep	30	2:00	0	S
-Rule	US	1967	2006	-	Oct	lastSun	2:00	0	S
-Rule	US	1967	1973	-	Apr	lastSun	2:00	1:00	D
-Rule	US	1974	only	-	Jan	6	2:00	1:00	D
-Rule	US	1975	only	-	Feb	23	2:00	1:00	D
-Rule	US	1976	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	US	1987	2006	-	Apr	Sun>=1	2:00	1:00	D
-Rule	US	2007	max	-	Mar	Sun>=8	2:00	1:00	D
-Rule	US	2007	max	-	Nov	Sun>=1	2:00	0	S
-
-# From Arthur David Olson, 2005-12-19
-# We generate the files specified below to guard against old files with
-# obsolete information being left in the time zone binary directory.
-# We limit the list to names that have appeared in previous versions of
-# this time zone package.
-# We do these as separate Zones rather than as Links to avoid problems if
-# a particular place changes whether it observes DST.
-# We put these specifications here in the northamerica file both to
-# increase the chances that they'll actually get compiled and to
-# avoid the need to duplicate the US rules in another file.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	EST		 -5:00	-	EST
-Zone	MST		 -7:00	-	MST
-Zone	HST		-10:00	-	HST
-Zone	EST5EDT		 -5:00	US	E%sT
-Zone	CST6CDT		 -6:00	US	C%sT
-Zone	MST7MDT		 -7:00	US	M%sT
-Zone	PST8PDT		 -8:00	US	P%sT
-
-# From Bob Devine (1988-01-28):
-# ...Alaska (and Hawaii) had the timezone names changed in 1967.
-#    old			 new
-#    Pacific Standard Time(PST)  -same-
-#    Yukon Standard Time(YST)    -same-
-#    Central Alaska S.T. (CAT)   Alaska-Hawaii St[an]dard Time (AHST)
-#    Nome Standard Time (NT)     Bering Standard Time (BST)
-#
-# ...Alaska's timezone lines were redrawn in 1983 to give only 2 tz.
-#    The YST zone now covers nearly all of the state, AHST just part
-#    of the Aleutian islands.   No DST.
-
-# From Paul Eggert (1995-12-19):
-# The tables below use `NST', not `NT', for Nome Standard Time.
-# I invented `CAWT' for Central Alaska War Time.
-
-# From U. S. Naval Observatory (1989-01-19):
-# USA  EASTERN       5 H  BEHIND UTC    NEW YORK, WASHINGTON
-# USA  EASTERN       4 H  BEHIND UTC    APR 3 - OCT 30
-# USA  CENTRAL       6 H  BEHIND UTC    CHICAGO, HOUSTON
-# USA  CENTRAL       5 H  BEHIND UTC    APR 3 - OCT 30
-# USA  MOUNTAIN      7 H  BEHIND UTC    DENVER
-# USA  MOUNTAIN      6 H  BEHIND UTC    APR 3 - OCT 30
-# USA  PACIFIC       8 H  BEHIND UTC    L.A., SAN FRANCISCO
-# USA  PACIFIC       7 H  BEHIND UTC    APR 3 - OCT 30
-# USA  ALASKA STD    9 H  BEHIND UTC    MOST OF ALASKA     (AKST)
-# USA  ALASKA STD    8 H  BEHIND UTC    APR 3 - OCT 30 (AKDT)
-# USA  ALEUTIAN     10 H  BEHIND UTC    ISLANDS WEST OF 170W
-# USA  - " -         9 H  BEHIND UTC    APR 3 - OCT 30
-# USA  HAWAII       10 H  BEHIND UTC
-# USA  BERING       11 H  BEHIND UTC    SAMOA, MIDWAY
-
-# From Arthur David Olson (1989-01-21):
-# The above dates are for 1988.
-# Note the "AKST" and "AKDT" abbreviations, the claim that there's
-# no DST in Samoa, and the claim that there is DST in Alaska and the
-# Aleutians.
-
-# From Arthur David Olson (1988-02-13):
-# Legal standard time zone names, from United States Code (1982 Edition and
-# Supplement III), Title 15, Chapter 6, Section 260 and forward.  First, names
-# up to 1967-04-01 (when most provisions of the Uniform Time Act of 1966
-# took effect), as explained in sections 263 and 261:
-#	(none)
-#	United States standard eastern time
-#	United States standard mountain time
-#	United States standard central time
-#	United States standard Pacific time
-#	(none)
-#	United States standard Alaska time
-#	(none)
-# Next, names from 1967-04-01 until 1983-11-30 (the date for
-# public law 98-181):
-#	Atlantic standard time
-#	eastern standard time
-#	central standard time
-#	mountain standard time
-#	Pacific standard time
-#	Yukon standard time
-#	Alaska-Hawaii standard time
-#	Bering standard time
-# And after 1983-11-30:
-#	Atlantic standard time
-#	eastern standard time
-#	central standard time
-#	mountain standard time
-#	Pacific standard time
-#	Alaska standard time
-#	Hawaii-Aleutian standard time
-#	Samoa standard time
-# The law doesn't give abbreviations.
-#
-# From Paul Eggert (2000-01-08), following a heads-up from Rives McDow:
-# Public law 106-564 (2000-12-23) introduced the abbreviation
-# "Chamorro Standard Time" for time in Guam and the Northern Marianas.
-# See the file "australasia".
-
-# From Arthur David Olson, 2005-08-09
-# The following was signed into law on 2005-08-08.
-#
-# H.R. 6, Energy Policy Act of 2005, SEC. 110. DAYLIGHT SAVINGS.
-#   (a) Amendment- Section 3(a) of the Uniform Time Act of 1966 (15
-#   U.S.C. 260a(a)) is amended--
-#     (1) by striking `first Sunday of April' and inserting `second
-#     Sunday of March'; and
-#     (2) by striking `last Sunday of October' and inserting `first
-#     Sunday of November'.
-#   (b) Effective Date- Subsection (a) shall take effect 1 year after the
-#   date of enactment of this Act or March 1, 2007, whichever is later.
-#   (c) Report to Congress- Not later than 9 months after the effective
-#   date stated in subsection (b), the Secretary shall report to Congress
-#   on the impact of this section on energy consumption in the United
-#   States.
-#   (d) Right to Revert- Congress retains the right to revert the
-#   Daylight Saving Time back to the 2005 time schedules once the
-#   Department study is complete.
-
-# US eastern time, represented by New York
-
-# Connecticut, Delaware, District of Columbia, most of Florida,
-# Georgia, southeast Indiana (Dearborn and Ohio counties), eastern Kentucky
-# (except America/Kentucky/Louisville below), Maine, Maryland, Massachusetts,
-# New Hampshire, New Jersey, New York, North Carolina, Ohio,
-# Pennsylvania, Rhode Island, South Carolina, eastern Tennessee,
-# Vermont, Virginia, West Virginia
-
-# From Dave Cantor (2004-11-02):
-# Early this summer I had the occasion to visit the Mount Washington
-# Observatory weather station atop (of course!) Mount Washington [, NH]....
-# One of the staff members said that the station was on Eastern Standard Time
-# and didn't change their clocks for Daylight Saving ... so that their
-# reports will always have times which are 5 hours behind UTC.
-
-# From Paul Eggert (2005-08-26):
-# According to today's Huntsville Times
-# <http://www.al.com/news/huntsvilletimes/index.ssf?/base/news/1125047783228320.xml&coll=1>
-# a few towns on Alabama's "eastern border with Georgia, such as Phenix City
-# in Russell County, Lanett in Chambers County and some towns in Lee County,
-# set their watches and clocks on Eastern time."  It quotes H.H. "Bubba"
-# Roberts, city administrator in Phenix City. as saying "We are in the Central
-# time zone, but we do go by the Eastern time zone because so many people work
-# in Columbus."
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	NYC	1920	only	-	Mar	lastSun	2:00	1:00	D
-Rule	NYC	1920	only	-	Oct	lastSun	2:00	0	S
-Rule	NYC	1921	1966	-	Apr	lastSun	2:00	1:00	D
-Rule	NYC	1921	1954	-	Sep	lastSun	2:00	0	S
-Rule	NYC	1955	1966	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/New_York	-4:56:02 -	LMT	1883 Nov 18 12:03:58
-			-5:00	US	E%sT	1920
-			-5:00	NYC	E%sT	1942
-			-5:00	US	E%sT	1946
-			-5:00	NYC	E%sT	1967
-			-5:00	US	E%sT
-
-# US central time, represented by Chicago
-
-# Alabama, Arkansas, Florida panhandle (Bay, Calhoun, Escambia,
-# Gulf, Holmes, Jackson, Okaloosa, Santa Rosa, Walton, and
-# Washington counties), Illinois, western Indiana
-# (Gibson, Jasper, Lake, LaPorte, Newton, Porter, Posey, Spencer,
-# Vanderburgh, and Warrick counties), Iowa, most of Kansas, western
-# Kentucky, Louisiana, Minnesota, Mississippi, Missouri, eastern
-# Nebraska, eastern North Dakota, Oklahoma, eastern South Dakota,
-# western Tennessee, most of Texas, Wisconsin
-
-# From Larry M. Smith (2006-04-26) re Wisconsin:
-# http://www.legis.state.wi.us/statutes/Stat0175.pdf ...
-# is currently enforced at the 01:00 time of change.  Because the local
-# "bar time" in the state corresponds to 02:00, a number of citations
-# are issued for the "sale of class 'B' alcohol after prohibited
-# hours" within the deviated hour of this change every year....
-#
-# From Douglas R. Bomberg (2007-03-12):
-# Wisconsin has enacted (nearly eleventh-hour) legislation to get WI
-# Statue 175 closer in synch with the US Congress' intent....
-# http://www.legis.state.wi.us/2007/data/acts/07Act3.pdf
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Chicago	1920	only	-	Jun	13	2:00	1:00	D
-Rule	Chicago	1920	1921	-	Oct	lastSun	2:00	0	S
-Rule	Chicago	1921	only	-	Mar	lastSun	2:00	1:00	D
-Rule	Chicago	1922	1966	-	Apr	lastSun	2:00	1:00	D
-Rule	Chicago	1922	1954	-	Sep	lastSun	2:00	0	S
-Rule	Chicago	1955	1966	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Chicago	-5:50:36 -	LMT	1883 Nov 18 12:09:24
-			-6:00	US	C%sT	1920
-			-6:00	Chicago	C%sT	1936 Mar  1 2:00
-			-5:00	-	EST	1936 Nov 15 2:00
-			-6:00	Chicago	C%sT	1942
-			-6:00	US	C%sT	1946
-			-6:00	Chicago	C%sT	1967
-			-6:00	US	C%sT
-# Oliver County, ND switched from mountain to central time on 1992-10-25.
-Zone America/North_Dakota/Center -6:45:12 - LMT	1883 Nov 18 12:14:48
-			-7:00	US	M%sT	1992 Oct 25 02:00
-			-6:00	US	C%sT
-# Morton County, ND, switched from mountain to central time on
-# 2003-10-26, except for the area around Mandan which was already central time.
-# See <http://dmses.dot.gov/docimages/p63/135818.pdf>.
-# Officially this switch also included part of Sioux County, and
-# Jones, Mellette, and Todd Counties in South Dakota;
-# but in practice these other counties were already observing central time.
-# See <http://www.epa.gov/fedrgstr/EPA-IMPACT/2003/October/Day-28/i27056.htm>.
-Zone America/North_Dakota/New_Salem -6:45:39 - LMT 1883 Nov 18 12:14:21
-			-7:00	US	M%sT	2003 Oct 26 02:00
-			-6:00	US	C%sT
-
-# US mountain time, represented by Denver
-#
-# Colorado, far western Kansas, Montana, western
-# Nebraska, Nevada border (Jackpot, Owyhee, and Mountain City),
-# New Mexico, southwestern North Dakota,
-# western South Dakota, far western Texas (El Paso County, Hudspeth County,
-# and Pine Springs and Nickel Creek in Culberson County), Utah, Wyoming
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Denver	1920	1921	-	Mar	lastSun	2:00	1:00	D
-Rule	Denver	1920	only	-	Oct	lastSun	2:00	0	S
-Rule	Denver	1921	only	-	May	22	2:00	0	S
-Rule	Denver	1965	1966	-	Apr	lastSun	2:00	1:00	D
-Rule	Denver	1965	1966	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Denver	-6:59:56 -	LMT	1883 Nov 18 12:00:04
-			-7:00	US	M%sT	1920
-			-7:00	Denver	M%sT	1942
-			-7:00	US	M%sT	1946
-			-7:00	Denver	M%sT	1967
-			-7:00	US	M%sT
-
-# US Pacific time, represented by Los Angeles
-#
-# California, northern Idaho (Benewah, Bonner, Boundary, Clearwater,
-# Idaho, Kootenai, Latah, Lewis, Nez Perce, and Shoshone counties,
-# and the northern three-quarters of Idaho county),
-# most of Nevada, most of Oregon, and Washington
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	CA	1948	only	-	Mar	14	2:00	1:00	D
-Rule	CA	1949	only	-	Jan	 1	2:00	0	S
-Rule	CA	1950	1966	-	Apr	lastSun	2:00	1:00	D
-Rule	CA	1950	1961	-	Sep	lastSun	2:00	0	S
-Rule	CA	1962	1966	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Los_Angeles -7:52:58 -	LMT	1883 Nov 18 12:07:02
-			-8:00	US	P%sT	1946
-			-8:00	CA	P%sT	1967
-			-8:00	US	P%sT
-
-# Alaska
-# AK%sT is the modern abbreviation for -9:00 per USNO.
-#
-# From Paul Eggert (2001-05-30):
-# Howse writes that Alaska switched from the Julian to the Gregorian calendar,
-# and from east-of-GMT to west-of-GMT days, when the US bought it from Russia.
-# This was on 1867-10-18, a Friday; the previous day was 1867-10-06 Julian,
-# also a Friday.  Include only the time zone part of this transition,
-# ignoring the switch from Julian to Gregorian, since we can't represent
-# the Julian calendar.
-#
-# As far as we know, none of the exact locations mentioned below were
-# permanently inhabited in 1867 by anyone using either calendar.
-# (Yakutat was colonized by the Russians in 1799, but the settlement
-# was destroyed in 1805 by a Yakutat-kon war party.)  However, there
-# were nearby inhabitants in some cases and for our purposes perhaps
-# it's best to simply use the official transition.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Juneau	 15:02:19 -	LMT	1867 Oct 18
-			 -8:57:41 -	LMT	1900 Aug 20 12:00
-			 -8:00	-	PST	1942
-			 -8:00	US	P%sT	1946
-			 -8:00	-	PST	1969
-			 -8:00	US	P%sT	1983 Oct 30 2:00
-			 -9:00	US	Y%sT	1983 Nov 30
-			 -9:00	US	AK%sT
-Zone America/Yakutat	 14:41:05 -	LMT	1867 Oct 18
-			 -9:18:55 -	LMT	1900 Aug 20 12:00
-			 -9:00	-	YST	1942
-			 -9:00	US	Y%sT	1946
-			 -9:00	-	YST	1969
-			 -9:00	US	Y%sT	1983 Nov 30
-			 -9:00	US	AK%sT
-Zone America/Anchorage	 14:00:24 -	LMT	1867 Oct 18
-			 -9:59:36 -	LMT	1900 Aug 20 12:00
-			-10:00	-	CAT	1942
-			-10:00	US	CAT/CAWT 1945 Aug 14 23:00u
-			-10:00	US	CAT/CAPT 1946 # Peace
-			-10:00	-	CAT	1967 Apr
-			-10:00	-	AHST	1969
-			-10:00	US	AH%sT	1983 Oct 30 2:00
-			 -9:00	US	Y%sT	1983 Nov 30
-			 -9:00	US	AK%sT
-Zone America/Nome	 12:58:21 -	LMT	1867 Oct 18
-			-11:01:38 -	LMT	1900 Aug 20 12:00
-			-11:00	-	NST	1942
-			-11:00	US	N%sT	1946
-			-11:00	-	NST	1967 Apr
-			-11:00	-	BST	1969
-			-11:00	US	B%sT	1983 Oct 30 2:00
-			 -9:00	US	Y%sT	1983 Nov 30
-			 -9:00	US	AK%sT
-Zone America/Adak	 12:13:21 -	LMT	1867 Oct 18
-			-11:46:38 -	LMT	1900 Aug 20 12:00
-			-11:00	-	NST	1942
-			-11:00	US	N%sT	1946
-			-11:00	-	NST	1967 Apr
-			-11:00	-	BST	1969
-			-11:00	US	B%sT	1983 Oct 30 2:00
-			-10:00	US	AH%sT	1983 Nov 30
-			-10:00	US	HA%sT
-# The following switches don't quite make our 1970 cutoff.
-#
-# Shanks writes that part of southwest Alaska (e.g. Aniak)
-# switched from -11:00 to -10:00 on 1968-09-22 at 02:00,
-# and another part (e.g. Akiak) made the same switch five weeks later.
-#
-# From David Flater (2004-11-09):
-# In e-mail, 2004-11-02, Ray Hudson, historian/liaison to the Unalaska
-# Historic Preservation Commission, provided this information, which
-# suggests that Unalaska deviated from statutory time from early 1967
-# possibly until 1983:
-#
-#  Minutes of the Unalaska City Council Meeting, January 10, 1967:
-#  "Except for St. Paul and Akutan, Unalaska is the only important
-#  location not on Alaska Standard Time.  The following resolution was
-#  made by William Robinson and seconded by Henry Swanson:  Be it
-#  resolved that the City of Unalaska hereby goes to Alaska Standard
-#  Time as of midnight Friday, January 13, 1967 (1 A.M. Saturday,
-#  January 14, Alaska Standard Time.)  This resolution was passed with
-#  three votes for and one against."
-
-# Hawaii
-#
-# From Arthur David Olson:
-# And then there's Hawaii.
-# DST was observed for one day in 1933;
-# standard time was changed by half an hour in 1947;
-# it's always standard as of 1986.
-#
-# From Paul Eggert:
-# Shanks says the 1933 experiment lasted for three weeks.  Go with Shanks.
-#
-Zone Pacific/Honolulu	-10:31:26 -	LMT	1900 Jan  1 12:00
-			-10:30	-	HST	1933 Apr 30 2:00
-			-10:30	1:00	HDT	1933 May 21 2:00
-			-10:30	US	H%sT	1947 Jun  8 2:00
-			-10:00	-	HST
-
-# Now we turn to US areas that have diverged from the consensus since 1970.
-
-# Arizona mostly uses MST.
-
-# From Paul Eggert (2002-10-20):
-#
-# The information in the rest of this paragraph is derived from the
-# <a href="http://www.dlapr.lib.az.us/links/daylight.htm">
-# Daylight Saving Time web page (2002-01-23)</a> maintained by the
-# Arizona State Library, Archives and Public Records.
-# Between 1944-01-01 and 1944-04-01 the State of Arizona used standard
-# time, but by federal law railroads, airlines, bus lines, military
-# personnel, and some engaged in interstate commerce continued to
-# observe war (i.e., daylight saving) time.  The 1944-03-17 Phoenix
-# Gazette says that was the date the law changed, and that 04-01 was
-# the date the state's clocks would change.  In 1945 the State of
-# Arizona used standard time all year, again with exceptions only as
-# mandated by federal law.  Arizona observed DST in 1967, but Arizona
-# Laws 1968, ch. 183 (effective 1968-03-21) repealed DST.
-#
-# Shanks says the 1944 experiment came to an end on 1944-03-17.
-# Go with the Arizona State Library instead.
-
-Zone America/Phoenix	-7:28:18 -	LMT	1883 Nov 18 11:31:42
-			-7:00	US	M%sT	1944 Jan  1 00:01
-			-7:00	-	MST	1944 Apr  1 00:01
-			-7:00	US	M%sT	1944 Oct  1 00:01
-			-7:00	-	MST	1967
-			-7:00	US	M%sT	1968 Mar 21
-			-7:00	-	MST
-# From Arthur David Olson (1988-02-13):
-# A writer from the Inter Tribal Council of Arizona, Inc.,
-# notes in private correspondence dated 1987-12-28 that "Presently, only the
-# Navajo Nation participates in the Daylight Saving Time policy, due to its
-# large size and location in three states."  (The "only" means that other
-# tribal nations don't use DST.)
-
-Link America/Denver America/Shiprock
-
-# Southern Idaho (Ada, Adams, Bannock, Bear Lake, Bingham, Blaine,
-# Boise, Bonneville, Butte, Camas, Canyon, Caribou, Cassia, Clark,
-# Custer, Elmore, Franklin, Fremont, Gem, Gooding, Jefferson, Jerome,
-# Lemhi, Lincoln, Madison, Minidoka, Oneida, Owyhee, Payette, Power,
-# Teton, Twin Falls, Valley, Washington counties, and the southern
-# quarter of Idaho county) and eastern Oregon (most of Malheur County)
-# switched four weeks late in 1974.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Boise	-7:44:49 -	LMT	1883 Nov 18 12:15:11
-			-8:00	US	P%sT	1923 May 13 2:00
-			-7:00	US	M%sT	1974
-			-7:00	-	MST	1974 Feb  3 2:00
-			-7:00	US	M%sT
-
-# Indiana
-#
-# For a map of Indiana's time zone regions, see:
-# <a href="http://www.mccsc.edu/time.html">
-# What time is it in Indiana?
-# </a> (2006-03-01)
-#
-# From Paul Eggert (2007-08-17):
-# Since 1970, most of Indiana has been like America/Indiana/Indianapolis,
-# with the following exceptions:
-#
-# - Gibson, Jasper, Lake, LaPorte, Newton, Porter, Posey, Spencer,
-#   Vandenburgh, and Warrick counties have been like America/Chicago.
-#
-# - Dearborn and Ohio counties have been like America/New_York.
-#
-# - Clark, Floyd, and Harrison counties have been like
-#   America/Kentucky/Louisville.
-#
-# - Crawford, Daviess, Dubois, Knox, Martin, Perry, Pike, Pulaski, Starke,
-#   and Switzerland counties have their own time zone histories as noted below.
-#
-# Shanks partitioned Indiana into 345 regions, each with its own time history,
-# and wrote ``Even newspaper reports present contradictory information.''
-# Those Hoosiers!  Such a flighty and changeable people!
-# Fortunately, most of the complexity occurred before our cutoff date of 1970.
-#
-# Other than Indianapolis, the Indiana place names are so nondescript
-# that they would be ambiguous if we left them at the `America' level.
-# So we reluctantly put them all in a subdirectory `America/Indiana'.
-
-# From Paul Eggert (2005-08-16):
-# http://www.mccsc.edu/time.html says that Indiana will use DST starting 2006.
-
-# From Nathan Stratton Treadway (2006-03-30):
-# http://www.dot.gov/affairs/dot0406.htm [3705 B]
-# From Deborah Goldsmith (2006-01-18):
-# http://dmses.dot.gov/docimages/pdf95/382329_web.pdf [2.9 MB]
-# From Paul Eggert (2006-01-20):
-# It says "DOT is relocating the time zone boundary in Indiana to move Starke,
-# Pulaski, Knox, Daviess, Martin, Pike, Dubois, and Perry Counties from the
-# Eastern Time Zone to the Central Time Zone.... The effective date of
-# this rule is 2:OO a.m. EST Sunday, April 2, 2006, which is the
-# changeover date from standard time to Daylight Saving Time."
-# Strictly speaking, this means the affected counties will change their
-# clocks twice that night, but this obviously is in error.  The intent
-# is that 01:59:59 EST be followed by 02:00:00 CDT.
-
-# From Gwillim Law (2007-02-10):
-# The Associated Press has been reporting that Pulaski County, Indiana is
-# going to switch from Central to Eastern Time on March 11, 2007....
-# http://www.indystar.com/apps/pbcs.dll/article?AID=/20070207/LOCAL190108/702070524/0/LOCAL
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule Indianapolis 1941	only	-	Jun	22	2:00	1:00	D
-Rule Indianapolis 1941	1954	-	Sep	lastSun	2:00	0	S
-Rule Indianapolis 1946	1954	-	Apr	lastSun	2:00	1:00	D
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Indianapolis -5:44:38 - LMT 1883 Nov 18 12:15:22
-			-6:00	US	C%sT	1920
-			-6:00 Indianapolis C%sT	1942
-			-6:00	US	C%sT	1946
-			-6:00 Indianapolis C%sT	1955 Apr 24 2:00
-			-5:00	-	EST	1957 Sep 29 2:00
-			-6:00	-	CST	1958 Apr 27 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1971
-			-5:00	-	EST	2006
-			-5:00	US	E%sT
-#
-# Eastern Crawford County, Indiana, left its clocks alone in 1974,
-# as well as from 1976 through 2005.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Marengo	1951	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Marengo	1951	only	-	Sep	lastSun	2:00	0	S
-Rule	Marengo	1954	1960	-	Apr	lastSun	2:00	1:00	D
-Rule	Marengo	1954	1960	-	Sep	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Marengo -5:45:23 -	LMT	1883 Nov 18 12:14:37
-			-6:00	US	C%sT	1951
-			-6:00	Marengo	C%sT	1961 Apr 30 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1974 Jan  6 2:00
-			-6:00	1:00	CDT	1974 Oct 27 2:00
-			-5:00	US	E%sT	1976
-			-5:00	-	EST	2006
-			-5:00	US	E%sT
-#
-# Daviess, Dubois, Knox, and Martin Counties, Indiana,
-# switched from eastern to central time in April 2006, then switched back
-# in November 2007.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule Vincennes	1946	only	-	Apr	lastSun	2:00	1:00	D
-Rule Vincennes	1946	only	-	Sep	lastSun	2:00	0	S
-Rule Vincennes	1953	1954	-	Apr	lastSun	2:00	1:00	D
-Rule Vincennes	1953	1959	-	Sep	lastSun	2:00	0	S
-Rule Vincennes	1955	only	-	May	 1	0:00	1:00	D
-Rule Vincennes	1956	1963	-	Apr	lastSun	2:00	1:00	D
-Rule Vincennes	1960	only	-	Oct	lastSun	2:00	0	S
-Rule Vincennes	1961	only	-	Sep	lastSun	2:00	0	S
-Rule Vincennes	1962	1963	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Vincennes -5:50:07 - LMT	1883 Nov 18 12:09:53
-			-6:00	US	C%sT	1946
-			-6:00 Vincennes	C%sT	1964 Apr 26 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1971
-			-5:00	-	EST	2006 Apr  2 2:00
-			-6:00	US	C%sT	2007 Nov  4 2:00
-			-5:00	US	E%sT
-#
-# Perry County, Indiana, switched from eastern to central time in April 2006.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule Perry	1946	only	-	Apr	lastSun	2:00	1:00	D
-Rule Perry	1946	only	-	Sep	lastSun	2:00	0	S
-Rule Perry	1953	1954	-	Apr	lastSun	2:00	1:00	D
-Rule Perry	1953	1959	-	Sep	lastSun	2:00	0	S
-Rule Perry	1955	only	-	May	 1	0:00	1:00	D
-Rule Perry	1956	1963	-	Apr	lastSun	2:00	1:00	D
-Rule Perry	1960	only	-	Oct	lastSun	2:00	0	S
-Rule Perry	1961	only	-	Sep	lastSun	2:00	0	S
-Rule Perry	1962	1963	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Tell_City -5:47:03 - LMT	1883 Nov 18 12:12:57
-			-6:00	US	C%sT	1946
-			-6:00 Perry	C%sT	1964 Apr 26 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1971
-			-5:00	-	EST	2006 Apr  2 2:00
-			-6:00	US	C%sT
-#
-# Pike County, Indiana moved from central to eastern time in 1977,
-# then switched back in 2006, then switched back again in 2007.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Pike	1955	only	-	May	 1	0:00	1:00	D
-Rule	Pike	1955	1960	-	Sep	lastSun	2:00	0	S
-Rule	Pike	1956	1964	-	Apr	lastSun	2:00	1:00	D
-Rule	Pike	1961	1964	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Petersburg -5:49:07 - LMT	1883 Nov 18 12:10:53
-			-6:00	US	C%sT	1955
-			-6:00	Pike	C%sT	1965 Apr 25 2:00
-			-5:00	-	EST	1966 Oct 30 2:00
-			-6:00	US	C%sT	1977 Oct 30 2:00
-			-5:00	-	EST	2006 Apr  2 2:00
-			-6:00	US	C%sT	2007 Nov  4 2:00
-			-5:00	US	E%sT
-#
-# Starke County, Indiana moved from central to eastern time in 1991,
-# then switched back in 2006.
-# From Arthur David Olson (1991-10-28):
-# An article on page A3 of the Sunday, 1991-10-27 Washington Post
-# notes that Starke County switched from Central time to Eastern time as of
-# 1991-10-27.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Starke	1947	1961	-	Apr	lastSun	2:00	1:00	D
-Rule	Starke	1947	1954	-	Sep	lastSun	2:00	0	S
-Rule	Starke	1955	1956	-	Oct	lastSun	2:00	0	S
-Rule	Starke	1957	1958	-	Sep	lastSun	2:00	0	S
-Rule	Starke	1959	1961	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Knox -5:46:30 -	LMT	1883 Nov 18 12:13:30
-			-6:00	US	C%sT	1947
-			-6:00	Starke	C%sT	1962 Apr 29 2:00
-			-5:00	-	EST	1963 Oct 27 2:00
-			-6:00	US	C%sT	1991 Oct 27 2:00
-			-5:00	-	EST	2006 Apr  2 2:00
-			-6:00	US	C%sT
-#
-# Pulaski County, Indiana, switched from eastern to central time in
-# April 2006 and then switched back in March 2007.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Pulaski	1946	1960	-	Apr	lastSun	2:00	1:00	D
-Rule	Pulaski	1946	1954	-	Sep	lastSun	2:00	0	S
-Rule	Pulaski	1955	1956	-	Oct	lastSun	2:00	0	S
-Rule	Pulaski	1957	1960	-	Sep	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Winamac -5:46:25 - LMT	1883 Nov 18 12:13:35
-			-6:00	US	C%sT	1946
-			-6:00	Pulaski	C%sT	1961 Apr 30 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1971
-			-5:00	-	EST	2006 Apr  2 2:00
-			-6:00	US	C%sT	2007 Mar 11 2:00
-			-5:00	US	E%sT
-#
-# Switzerland County, Indiana, did not observe DST from 1973 through 2005.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Indiana/Vevay -5:40:16 -	LMT	1883 Nov 18 12:19:44
-			-6:00	US	C%sT	1954 Apr 25 2:00
-			-5:00	-	EST	1969
-			-5:00	US	E%sT	1973
-			-5:00	-	EST	2006
-			-5:00	US	E%sT
-
-# Part of Kentucky left its clocks alone in 1974.
-# This also includes Clark, Floyd, and Harrison counties in Indiana.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule Louisville	1921	only	-	May	1	2:00	1:00	D
-Rule Louisville	1921	only	-	Sep	1	2:00	0	S
-Rule Louisville	1941	1961	-	Apr	lastSun	2:00	1:00	D
-Rule Louisville	1941	only	-	Sep	lastSun	2:00	0	S
-Rule Louisville	1946	only	-	Jun	2	2:00	0	S
-Rule Louisville	1950	1955	-	Sep	lastSun	2:00	0	S
-Rule Louisville	1956	1960	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Kentucky/Louisville -5:43:02 -	LMT	1883 Nov 18 12:16:58
-			-6:00	US	C%sT	1921
-			-6:00 Louisville C%sT	1942
-			-6:00	US	C%sT	1946
-			-6:00 Louisville C%sT	1961 Jul 23 2:00
-			-5:00	-	EST	1968
-			-5:00	US	E%sT	1974 Jan  6 2:00
-			-6:00	1:00	CDT	1974 Oct 27 2:00
-			-5:00	US	E%sT
-#
-# Wayne County, Kentucky
-#
-# From
-# <a href="http://www.lake-cumberland.com/life/archive/news990129time.shtml">
-# Lake Cumberland LIFE
-# </a> (1999-01-29) via WKYM-101.7:
-# Clinton County has joined Wayne County in asking the DoT to change from
-# the Central to the Eastern time zone....  The Wayne County government made
-# the same request in December.  And while Russell County officials have not
-# taken action, the majority of respondents to a poll conducted there in
-# August indicated they would like to change to "fast time" also.
-# The three Lake Cumberland counties are the farthest east of any U.S.
-# location in the Central time zone.
-#
-# From Rich Wales (2000-08-29):
-# After prolonged debate, and despite continuing deep differences of opinion,
-# Wayne County (central Kentucky) is switching from Central (-0600) to Eastern
-# (-0500) time.  They won't "fall back" this year.  See Sara Shipley,
-# The difference an hour makes, Nando Times (2000-08-29 15:33 -0400).
-#
-# From Paul Eggert (2001-07-16):
-# The final rule was published in the
-# <a href="http://frwebgate.access.gpo.gov/cgi-bin/getdoc.cgi?dbname=2000_register&docid=fr17au00-22">
-# Federal Register 65, 160 (2000-08-17), page 50154-50158.
-# </a>
-#
-Zone America/Kentucky/Monticello -5:39:24 - LMT	1883 Nov 18 12:20:36
-			-6:00	US	C%sT	1946
-			-6:00	-	CST	1968
-			-6:00	US	C%sT	2000 Oct 29  2:00
-			-5:00	US	E%sT
-
-
-# From Rives McDow (2000-08-30):
-# Here ... are all the changes in the US since 1985.
-# Kearny County, KS (put all of county on central;
-#	previously split between MST and CST) ... 1990-10
-# Starke County, IN (from CST to EST) ... 1991-10
-# Oliver County, ND (from MST to CST) ... 1992-10
-# West Wendover, NV (from PST TO MST) ... 1999-10
-# Wayne County, KY (from CST to EST) ... 2000-10
-#
-# From Paul Eggert (2001-07-17):
-# We don't know where the line used to be within Kearny County, KS,
-# so omit that change for now.
-# See America/Indiana/Knox for the Starke County, IN change.
-# See America/North_Dakota/Center for the Oliver County, ND change.
-# West Wendover, NV officially switched from Pacific to mountain time on
-# 1999-10-31.  See the
-# <a href="http://frwebgate.access.gpo.gov/cgi-bin/getdoc.cgi?dbname=1999_register&docid=fr21oc99-15">
-# Federal Register 64, 203 (1999-10-21), page 56705-56707.
-# </a>
-# However, the Federal Register says that West Wendover already operated
-# on mountain time, and the rule merely made this official;
-# hence a separate tz entry is not needed.
-
-# Michigan
-#
-# From Bob Devine (1988-01-28):
-# Michigan didn't observe DST from 1968 to 1973.
-#
-# From Paul Eggert (1999-03-31):
-# Shanks writes that Michigan started using standard time on 1885-09-18,
-# but Howse writes (pp 124-125, referring to Popular Astronomy, 1901-01)
-# that Detroit kept
-#
-#	local time until 1900 when the City Council decreed that clocks should
-#	be put back twenty-eight minutes to Central Standard Time.  Half the
-#	city obeyed, half refused.  After considerable debate, the decision
-#	was rescinded and the city reverted to Sun time.  A derisive offer to
-#	erect a sundial in front of the city hall was referred to the
-#	Committee on Sewers.  Then, in 1905, Central time was adopted
-#	by city vote.
-#
-# This story is too entertaining to be false, so go with Howse over Shanks.
-#
-# From Paul Eggert (2001-03-06):
-# Garland (1927) writes ``Cleveland and Detroit advanced their clocks
-# one hour in 1914.''  This change is not in Shanks.  We have no more
-# info, so omit this for now.
-#
-# Most of Michigan observed DST from 1973 on, but was a bit late in 1975.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule	Detroit	1948	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Detroit	1948	only	-	Sep	lastSun	2:00	0	S
-Rule	Detroit	1967	only	-	Jun	14	2:00	1:00	D
-Rule	Detroit	1967	only	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Detroit	-5:32:11 -	LMT	1905
-			-6:00	-	CST	1915 May 15 2:00
-			-5:00	-	EST	1942
-			-5:00	US	E%sT	1946
-			-5:00	Detroit	E%sT	1973
-			-5:00	US	E%sT	1975
-			-5:00	-	EST	1975 Apr 27 2:00
-			-5:00	US	E%sT
-#
-# Dickinson, Gogebic, Iron, and Menominee Counties, Michigan,
-# switched from EST to CST/CDT in 1973.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER
-Rule Menominee	1946	only	-	Apr	lastSun	2:00	1:00	D
-Rule Menominee	1946	only	-	Sep	lastSun	2:00	0	S
-Rule Menominee	1966	only	-	Apr	lastSun	2:00	1:00	D
-Rule Menominee	1966	only	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Menominee	-5:50:27 -	LMT	1885 Sep 18 12:00
-			-6:00	US	C%sT	1946
-			-6:00 Menominee	C%sT	1969 Apr 27 2:00
-			-5:00	-	EST	1973 Apr 29 2:00
-			-6:00	US	C%sT
-
-# Navassa
-# administered by the US Fish and Wildlife Service
-# claimed by US under the provisions of the 1856 Guano Islands Act
-# also claimed by Haiti
-# occupied 1857/1900 by the Navassa Phosphate Co
-# US lighthouse 1917/1996-09
-# currently uninhabited
-# see Mark Fineman, ``An Isle Rich in Guano and Discord'',
-# _Los Angeles Times_ (1998-11-10), A1, A10; it cites
-# Jimmy Skaggs, _The Great Guano Rush_ (1994).
-
-################################################################################
-
-
-# From Paul Eggert (2006-03-22):
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1990, and IATA SSIM is the source for entries afterwards.
-#
-# Other sources occasionally used include:
-#
-#	Edward W. Whitman, World Time Differences,
-#	Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated),
-#	which I found in the UCLA library.
-#
-#	<a href="http://www.pettswoodvillage.co.uk/Daylight_Savings_William_Willett.pdf">
-#	William Willett, The Waste of Daylight, 19th edition
-#	</a> (1914-03)
-#
-# See the `europe' file for Greenland.
-
-# Canada
-
-# From Alain LaBont<e'> (1994-11-14):
-# I post here the time zone abbreviations standardized in Canada
-# for both English and French in the CAN/CSA-Z234.4-89 standard....
-#
-#	UTC	Standard time	Daylight savings time
-#	offset	French	English	French	English
-#	-2:30	-	-	HAT	NDT
-#	-3	-	-	HAA	ADT
-#	-3:30	HNT	NST	-	-
-#	-4	HNA	AST	HAE	EDT
-#	-5	HNE	EST	HAC	CDT
-#	-6	HNC	CST	HAR	MDT
-#	-7	HNR	MST	HAP	PDT
-#	-8	HNP	PST	HAY	YDT
-#	-9	HNY	YST	-	-
-#
-#	HN: Heure Normale	ST: Standard Time
-#	HA: Heure Avanc<e'>e	DT: Daylight saving Time
-#
-#	A: de l'Atlantique	Atlantic
-#	C: du Centre		Central
-#	E: de l'Est		Eastern
-#	M:			Mountain
-#	N:			Newfoundland
-#	P: du Pacifique		Pacific
-#	R: des Rocheuses
-#	T: de Terre-Neuve
-#	Y: du Yukon		Yukon
-#
-# From Paul Eggert (1994-11-22):
-# Alas, this sort of thing must be handled by localization software.
-
-# Unless otherwise specified, the data for Canada are all from Shanks
-# & Pottenger.
-
-# From Chris Walton (2006-04-01, 2006-04-25, 2006-06-26, 2007-01-31,
-# 2007-03-01):
-# The British Columbia government announced yesterday that it will
-# adjust daylight savings next year to align with changes in the
-# U.S. and the rest of Canada....
-# http://www2.news.gov.bc.ca/news_releases_2005-2009/2006AG0014-000330.htm
-# ...
-# Nova Scotia
-# Daylight saving time will be extended by four weeks starting in 2007....
-# http://www.gov.ns.ca/just/regulations/rg2/2006/ma1206.pdf
-#
-# [For New Brunswick] the new legislation dictates that the time change is to
-# be done at 02:00 instead of 00:01.
-# http://www.gnb.ca/0062/acts/BBA-2006/Chap-19.pdf
-# ...
-# Manitoba has traditionally changed the clock every fall at 03:00.
-# As of 2006, the transition is to take place one hour earlier at 02:00.
-# http://web2.gov.mb.ca/laws/statutes/ccsm/o030e.php
-# ...
-# [Alberta, Ontario, Quebec] will follow US rules.
-# http://www.qp.gov.ab.ca/documents/spring/CH03_06.CFM
-# http://www.e-laws.gov.on.ca/DBLaws/Source/Regs/English/2006/R06111_e.htm
-# http://www2.publicationsduquebec.gouv.qc.ca/dynamicSearch/telecharge.php?type=5&file=2006C39A.PDF
-# ...
-# P.E.I. will follow US rules....
-# http://www.assembly.pe.ca/bills/pdf_chapter/62/3/chapter-41.pdf
-# ...
-# Province of Newfoundland and Labrador....
-# http://www.hoa.gov.nl.ca/hoa/bills/Bill0634.htm
-# ...
-# Yukon
-# http://www.gov.yk.ca/legislation/regs/oic2006_127.pdf
-# ...
-# N.W.T. will follow US rules.  Whoever maintains the government web site
-# does not seem to believe in bookmarks.  To see the news release, click the
-# following link and search for "Daylight Savings Time Change".  Press the
-# "Daylight Savings Time Change" link; it will fire off a popup using
-# JavaScript.
-# http://www.exec.gov.nt.ca/currentnews/currentPR.asp?mode=archive
-# ...
-# Nunavut
-# An amendment to the Interpretation Act was registered on February 19/2007....
-# http://action.attavik.ca/home/justice-gn/attach/2007/gaz02part2.pdf
-
-# From Paul Eggert (2006-04-25):
-# H. David Matthews and Mary Vincent's map
-# <a href="http://www.canadiangeographic.ca/Magazine/SO98/geomap.asp">
-# "It's about TIME", _Canadian Geographic_ (September-October 1998)
-# </a> contains detailed boundaries for regions observing nonstandard
-# time and daylight saving time arrangements in Canada circa 1998.
-#
-# INMS, the Institute for National Measurement Standards in Ottawa, has <a
-# href="http://inms-ienm.nrc-cnrc.gc.ca/en/time_services/daylight_saving_e.php">
-# information about standard and daylight saving time zones in Canada.
-# </a> (updated periodically).
-# Its unofficial information is often taken from Matthews and Vincent.
-
-# From Paul Eggert (2006-06-27):
-# For now, assume all of DST-observing Canada will fall into line with the
-# new US DST rules,
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Canada	1918	only	-	Apr	14	2:00	1:00	D
-Rule	Canada	1918	only	-	Oct	31	2:00	0	S
-Rule	Canada	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	Canada	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	Canada	1945	only	-	Sep	30	2:00	0	S
-Rule	Canada	1974	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	Canada	1974	2006	-	Oct	lastSun	2:00	0	S
-Rule	Canada	1987	2006	-	Apr	Sun>=1	2:00	1:00	D
-Rule	Canada	2007	max	-	Mar	Sun>=8	2:00	1:00	D
-Rule	Canada	2007	max	-	Nov	Sun>=1	2:00	0	S
-
-
-# Newfoundland and Labrador
-
-# From Paul Eggert (2000-10-02):
-# Matthews and Vincent (1998) write that Labrador should use NST/NDT,
-# but the only part of Labrador that follows the rules is the
-# southeast corner, including Port Hope Simpson and Mary's Harbour,
-# but excluding, say, Black Tickle.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	StJohns	1917	only	-	Apr	 8	2:00	1:00	D
-Rule	StJohns	1917	only	-	Sep	17	2:00	0	S
-# Whitman gives 1919 Apr 5 and 1920 Apr 5; go with Shanks & Pottenger.
-Rule	StJohns	1919	only	-	May	 5	23:00	1:00	D
-Rule	StJohns	1919	only	-	Aug	12	23:00	0	S
-# For 1931-1935 Whitman gives Apr same date; go with Shanks & Pottenger.
-Rule	StJohns	1920	1935	-	May	Sun>=1	23:00	1:00	D
-Rule	StJohns	1920	1935	-	Oct	lastSun	23:00	0	S
-# For 1936-1941 Whitman gives May Sun>=8 and Oct Sun>=1; go with Shanks &
-# Pottenger.
-Rule	StJohns	1936	1941	-	May	Mon>=9	0:00	1:00	D
-Rule	StJohns	1936	1941	-	Oct	Mon>=2	0:00	0	S
-# Whitman gives the following transitions:
-# 1942 03-01/12-31, 1943 05-30/09-05, 1944 07-10/09-02, 1945 01-01/10-07
-# but go with Shanks & Pottenger and assume they used Canadian rules.
-# For 1946-9 Whitman gives May 5,4,9,1 - Oct 1,5,3,2, and for 1950 he gives
-# Apr 30 - Sep 24; go with Shanks & Pottenger.
-Rule	StJohns	1946	1950	-	May	Sun>=8	2:00	1:00	D
-Rule	StJohns	1946	1950	-	Oct	Sun>=2	2:00	0	S
-Rule	StJohns	1951	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	StJohns	1951	1959	-	Sep	lastSun	2:00	0	S
-Rule	StJohns	1960	1986	-	Oct	lastSun	2:00	0	S
-# From Paul Eggert (2000-10-02):
-# INMS (2000-09-12) says that, since 1988 at least, Newfoundland switches
-# at 00:01 local time.  For now, assume it started in 1987.
-Rule	StJohns	1987	only	-	Apr	Sun>=1	0:01	1:00	D
-Rule	StJohns	1987	2006	-	Oct	lastSun	0:01	0	S
-Rule	StJohns	1988	only	-	Apr	Sun>=1	0:01	2:00	DD
-Rule	StJohns	1989	2006	-	Apr	Sun>=1	0:01	1:00	D
-Rule	StJohns	2007	max	-	Mar	Sun>=8	0:01	1:00	D
-Rule	StJohns	2007	max	-	Nov	Sun>=1	0:01	0	S
-#
-# St John's has an apostrophe, but Posix file names can't have apostrophes.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/St_Johns	-3:30:52 -	LMT	1884
-			-3:30:52 StJohns N%sT	1918
-			-3:30:52 Canada	N%sT	1919
-			-3:30:52 StJohns N%sT	1935 Mar 30
-			-3:30	StJohns	N%sT	1942 May 11
-			-3:30	Canada	N%sT	1946
-			-3:30	StJohns	N%sT
-
-# most of east Labrador
-
-# The name `Happy Valley-Goose Bay' is too long; use `Goose Bay'.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Goose_Bay	-4:01:40 -	LMT	1884 # Happy Valley-Goose Bay
-			-3:30:52 -	NST	1918
-			-3:30:52 Canada N%sT	1919
-			-3:30:52 -	NST	1935 Mar 30
-			-3:30	-	NST	1936
-			-3:30	StJohns	N%sT	1942 May 11
-			-3:30	Canada	N%sT	1946
-			-3:30	StJohns	N%sT	1966 Mar 15 2:00
-			-4:00	StJohns	A%sT
-
-
-# west Labrador, Nova Scotia, Prince Edward I
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that since 1970 most of this region has been like
-# Halifax.  Many locales did not observe peacetime DST until 1972;
-# Glace Bay, NS is the largest that we know of.
-# Shanks & Pottenger also write that Liverpool, NS was the only town
-# in Canada to observe DST in 1971 but not 1970; for now we'll assume
-# this is a typo.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Halifax	1916	only	-	Apr	 1	0:00	1:00	D
-Rule	Halifax	1916	only	-	Oct	 1	0:00	0	S
-Rule	Halifax	1920	only	-	May	 9	0:00	1:00	D
-Rule	Halifax	1920	only	-	Aug	29	0:00	0	S
-Rule	Halifax	1921	only	-	May	 6	0:00	1:00	D
-Rule	Halifax	1921	1922	-	Sep	 5	0:00	0	S
-Rule	Halifax	1922	only	-	Apr	30	0:00	1:00	D
-Rule	Halifax	1923	1925	-	May	Sun>=1	0:00	1:00	D
-Rule	Halifax	1923	only	-	Sep	 4	0:00	0	S
-Rule	Halifax	1924	only	-	Sep	15	0:00	0	S
-Rule	Halifax	1925	only	-	Sep	28	0:00	0	S
-Rule	Halifax	1926	only	-	May	16	0:00	1:00	D
-Rule	Halifax	1926	only	-	Sep	13	0:00	0	S
-Rule	Halifax	1927	only	-	May	 1	0:00	1:00	D
-Rule	Halifax	1927	only	-	Sep	26	0:00	0	S
-Rule	Halifax	1928	1931	-	May	Sun>=8	0:00	1:00	D
-Rule	Halifax	1928	only	-	Sep	 9	0:00	0	S
-Rule	Halifax	1929	only	-	Sep	 3	0:00	0	S
-Rule	Halifax	1930	only	-	Sep	15	0:00	0	S
-Rule	Halifax	1931	1932	-	Sep	Mon>=24	0:00	0	S
-Rule	Halifax	1932	only	-	May	 1	0:00	1:00	D
-Rule	Halifax	1933	only	-	Apr	30	0:00	1:00	D
-Rule	Halifax	1933	only	-	Oct	 2	0:00	0	S
-Rule	Halifax	1934	only	-	May	20	0:00	1:00	D
-Rule	Halifax	1934	only	-	Sep	16	0:00	0	S
-Rule	Halifax	1935	only	-	Jun	 2	0:00	1:00	D
-Rule	Halifax	1935	only	-	Sep	30	0:00	0	S
-Rule	Halifax	1936	only	-	Jun	 1	0:00	1:00	D
-Rule	Halifax	1936	only	-	Sep	14	0:00	0	S
-Rule	Halifax	1937	1938	-	May	Sun>=1	0:00	1:00	D
-Rule	Halifax	1937	1941	-	Sep	Mon>=24	0:00	0	S
-Rule	Halifax	1939	only	-	May	28	0:00	1:00	D
-Rule	Halifax	1940	1941	-	May	Sun>=1	0:00	1:00	D
-Rule	Halifax	1946	1949	-	Apr	lastSun	2:00	1:00	D
-Rule	Halifax	1946	1949	-	Sep	lastSun	2:00	0	S
-Rule	Halifax	1951	1954	-	Apr	lastSun	2:00	1:00	D
-Rule	Halifax	1951	1954	-	Sep	lastSun	2:00	0	S
-Rule	Halifax	1956	1959	-	Apr	lastSun	2:00	1:00	D
-Rule	Halifax	1956	1959	-	Sep	lastSun	2:00	0	S
-Rule	Halifax	1962	1973	-	Apr	lastSun	2:00	1:00	D
-Rule	Halifax	1962	1973	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Halifax	-4:14:24 -	LMT	1902 Jun 15
-			-4:00	Halifax	A%sT	1918
-			-4:00	Canada	A%sT	1919
-			-4:00	Halifax	A%sT	1942 Feb  9 2:00s
-			-4:00	Canada	A%sT	1946
-			-4:00	Halifax	A%sT	1974
-			-4:00	Canada	A%sT
-Zone America/Glace_Bay	-3:59:48 -	LMT	1902 Jun 15
-			-4:00	Canada	A%sT	1953
-			-4:00	Halifax	A%sT	1954
-			-4:00	-	AST	1972
-			-4:00	Halifax	A%sT	1974
-			-4:00	Canada	A%sT
-
-# New Brunswick
-
-# From Paul Eggert (2007-01-31):
-# The Time Definition Act <http://www.gnb.ca/0062/PDF-acts/t-06.pdf>
-# says they changed at 00:01 through 2006, and
-# <http://www.canlii.org/nb/laws/sta/t-6/20030127/whole.html> makes it
-# clear that this was the case since at least 1993.
-# For now, assume it started in 1993.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Moncton	1933	1935	-	Jun	Sun>=8	1:00	1:00	D
-Rule	Moncton	1933	1935	-	Sep	Sun>=8	1:00	0	S
-Rule	Moncton	1936	1938	-	Jun	Sun>=1	1:00	1:00	D
-Rule	Moncton	1936	1938	-	Sep	Sun>=1	1:00	0	S
-Rule	Moncton	1939	only	-	May	27	1:00	1:00	D
-Rule	Moncton	1939	1941	-	Sep	Sat>=21	1:00	0	S
-Rule	Moncton	1940	only	-	May	19	1:00	1:00	D
-Rule	Moncton	1941	only	-	May	 4	1:00	1:00	D
-Rule	Moncton	1946	1972	-	Apr	lastSun	2:00	1:00	D
-Rule	Moncton	1946	1956	-	Sep	lastSun	2:00	0	S
-Rule	Moncton	1957	1972	-	Oct	lastSun	2:00	0	S
-Rule	Moncton	1993	2006	-	Apr	Sun>=1	0:01	1:00	D
-Rule	Moncton	1993	2006	-	Oct	lastSun	0:01	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Moncton	-4:19:08 -	LMT	1883 Dec  9
-			-5:00	-	EST	1902 Jun 15
-			-4:00	Canada	A%sT	1933
-			-4:00	Moncton	A%sT	1942
-			-4:00	Canada	A%sT	1946
-			-4:00	Moncton	A%sT	1973
-			-4:00	Canada	A%sT	1993
-			-4:00	Moncton	A%sT	2007
-			-4:00	Canada	A%sT
-
-# Quebec
-
-# From Paul Eggert (2006-07-09):
-# Shanks & Pottenger write that since 1970 most of Quebec has been
-# like Montreal.
-
-# From Paul Eggert (2006-06-27):
-# Matthews and Vincent (1998) also write that Quebec east of the -63
-# meridian is supposed to observe AST, but residents as far east as
-# Natashquan use EST/EDT, and residents east of Natashquan use AST.
-# In "Official time in Quebec" the Quebec department of justice writes in
-# http://www.justice.gouv.qc.ca/english/publications/generale/temps-regl-1-a.htm
-# that "The residents of the Municipality of the
-# Cote-Nord-du-Golfe-Saint-Laurent and the municipalities of Saint-Augustin,
-# Bonne-Esperance and Blanc-Sablon apply the Official Time Act as it is
-# written and use Atlantic standard time all year round. The same applies to
-# the residents of the Native facilities along the lower North Shore."
-# <http://www.assnat.qc.ca/eng/37legislature2/Projets-loi/Publics/06-a002.htm>
-# says this common practice was codified into law as of 2007.
-# For lack of better info, guess this practice began around 1970, contra to
-# Shanks & Pottenger who have this region observing AST/ADT.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Mont	1917	only	-	Mar	25	2:00	1:00	D
-Rule	Mont	1917	only	-	Apr	24	0:00	0	S
-Rule	Mont	1919	only	-	Mar	31	2:30	1:00	D
-Rule	Mont	1919	only	-	Oct	25	2:30	0	S
-Rule	Mont	1920	only	-	May	 2	2:30	1:00	D
-Rule	Mont	1920	1922	-	Oct	Sun>=1	2:30	0	S
-Rule	Mont	1921	only	-	May	 1	2:00	1:00	D
-Rule	Mont	1922	only	-	Apr	30	2:00	1:00	D
-Rule	Mont	1924	only	-	May	17	2:00	1:00	D
-Rule	Mont	1924	1926	-	Sep	lastSun	2:30	0	S
-Rule	Mont	1925	1926	-	May	Sun>=1	2:00	1:00	D
-# The 1927-to-1937 rules can be expressed more simply as
-# Rule	Mont	1927	1937	-	Apr	lastSat	24:00	1:00	D
-# Rule	Mont	1927	1937	-	Sep	lastSat	24:00	0	S
-# The rules below avoid use of 24:00
-# (which pre-1998 versions of zic cannot handle).
-Rule	Mont	1927	only	-	May	1	0:00	1:00	D
-Rule	Mont	1927	1932	-	Sep	lastSun	0:00	0	S
-Rule	Mont	1928	1931	-	Apr	lastSun	0:00	1:00	D
-Rule	Mont	1932	only	-	May	1	0:00	1:00	D
-Rule	Mont	1933	1940	-	Apr	lastSun	0:00	1:00	D
-Rule	Mont	1933	only	-	Oct	1	0:00	0	S
-Rule	Mont	1934	1939	-	Sep	lastSun	0:00	0	S
-Rule	Mont	1946	1973	-	Apr	lastSun	2:00	1:00	D
-Rule	Mont	1945	1948	-	Sep	lastSun	2:00	0	S
-Rule	Mont	1949	1950	-	Oct	lastSun	2:00	0	S
-Rule	Mont	1951	1956	-	Sep	lastSun	2:00	0	S
-Rule	Mont	1957	1973	-	Oct	lastSun	2:00	0	S
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Blanc-Sablon -3:48:28 -	LMT	1884
-			-4:00	Canada	A%sT	1970
-			-4:00	-	AST
-Zone America/Montreal	-4:54:16 -	LMT	1884
-			-5:00	Mont	E%sT	1918
-			-5:00	Canada	E%sT	1919
-			-5:00	Mont	E%sT	1942 Feb  9 2:00s
-			-5:00	Canada	E%sT	1946
-			-5:00	Mont	E%sT	1974
-			-5:00	Canada	E%sT
-
-
-# Ontario
-
-# From Paul Eggert (2006-07-09):
-# Shanks & Pottenger write that since 1970 most of Ontario has been like
-# Toronto.
-# Thunder Bay skipped DST in 1973.
-# Many smaller locales did not observe peacetime DST until 1974;
-# Nipigon (EST) and Rainy River (CST) are the largest that we know of.
-# Far west Ontario is like Winnipeg; far east Quebec is like Halifax.
-
-# From Mark Brader (2003-07-26):
-# [According to the Toronto Star] Orillia, Ontario, adopted DST
-# effective Saturday, 1912-06-22, 22:00; the article mentions that
-# Port Arthur (now part of Thunder Bay, Ontario) as well as Moose Jaw
-# have already done so.  In Orillia DST was to run until Saturday,
-# 1912-08-31 (no time mentioned), but it was met with considerable
-# hostility from certain segments of the public, and was revoked after
-# only two weeks -- I copied it as Saturday, 1912-07-07, 22:00, but
-# presumably that should be -07-06.  (1912-06-19, -07-12; also letters
-# earlier in June).
-#
-# Kenora, Ontario, was to abandon DST on 1914-06-01 (-05-21).
-
-# From Paul Eggert (1997-10-17):
-# Mark Brader writes that an article in the 1997-10-14 Toronto Star
-# says that Atikokan, Ontario currently does not observe DST,
-# but will vote on 11-10 whether to use EST/EDT.
-# He also writes that the
-# <a href="http://www.gov.on.ca/MBS/english/publications/statregs/conttext.html">
-# Ontario Time Act (1990, Chapter T.9)
-# </a>
-# says that Ontario east of 90W uses EST/EDT, and west of 90W uses CST/CDT.
-# Officially Atikokan is therefore on CST/CDT, and most likely this report
-# concerns a non-official time observed as a matter of local practice.
-#
-# From Paul Eggert (2000-10-02):
-# Matthews and Vincent (1998) write that Atikokan, Pickle Lake, and
-# New Osnaburgh observe CST all year, that Big Trout Lake observes
-# CST/CDT, and that Upsala and Shebandowan observe EST/EDT, all in
-# violation of the official Ontario rules.
-#
-# From Paul Eggert (2006-07-09):
-# Chris Walton (2006-07-06) mentioned an article by Stephanie MacLellan in the
-# 2005-07-21 Chronicle-Journal, which said:
-#
-#	The clocks in Atikokan stay set on standard time year-round.
-#	This means they spend about half the time on central time and
-#	the other half on eastern time.
-#
-#	For the most part, the system works, Mayor Dennis Brown said.
-#
-#	"The majority of businesses in Atikokan deal more with Eastern
-#	Canada, but there are some that deal with Western Canada," he
-#	said.  "I don't see any changes happening here."
-#
-# Walton also writes "Supposedly Pickle Lake and Mishkeegogamang
-# [New Osnaburgh] follow the same practice."
-
-# From Garry McKinnon (2006-07-14) via Chris Walton:
-# I chatted with a member of my board who has an outstanding memory
-# and a long history in Atikokan (and in the telecom industry) and he
-# can say for certain that Atikokan has been practicing the current
-# time keeping since 1952, at least.
-
-# From Paul Eggert (2006-07-17):
-# Shanks & Pottenger say that Atikokan has agreed with Rainy River
-# ever since standard time was introduced, but the information from
-# McKinnon sounds more authoritative.  For now, assume that Atikokan
-# switched to EST immediately after WWII era daylight saving time
-# ended.  This matches the old (less-populous) America/Coral_Harbour
-# entry since our cutoff date of 1970, so we can move
-# America/Coral_Harbour to the 'backward' file.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Toronto	1919	only	-	Mar	30	23:30	1:00	D
-Rule	Toronto	1919	only	-	Oct	26	0:00	0	S
-Rule	Toronto	1920	only	-	May	 2	2:00	1:00	D
-Rule	Toronto	1920	only	-	Sep	26	0:00	0	S
-Rule	Toronto	1921	only	-	May	15	2:00	1:00	D
-Rule	Toronto	1921	only	-	Sep	15	2:00	0	S
-Rule	Toronto	1922	1923	-	May	Sun>=8	2:00	1:00	D
-# Shanks & Pottenger say 1923-09-19; assume it's a typo and that "-16"
-# was meant.
-Rule	Toronto	1922	1926	-	Sep	Sun>=15	2:00	0	S
-Rule	Toronto	1924	1927	-	May	Sun>=1	2:00	1:00	D
-# The 1927-to-1939 rules can be expressed more simply as
-# Rule	Toronto	1927	1937	-	Sep	Sun>=25	2:00	0	S
-# Rule	Toronto	1928	1937	-	Apr	Sun>=25	2:00	1:00	D
-# Rule	Toronto	1938	1940	-	Apr	lastSun	2:00	1:00	D
-# Rule	Toronto	1938	1939	-	Sep	lastSun	2:00	0	S
-# The rules below avoid use of Sun>=25
-# (which pre-2004 versions of zic cannot handle).
-Rule	Toronto	1927	1932	-	Sep	lastSun	2:00	0	S
-Rule	Toronto	1928	1931	-	Apr	lastSun	2:00	1:00	D
-Rule	Toronto	1932	only	-	May	1	2:00	1:00	D
-Rule	Toronto	1933	1940	-	Apr	lastSun	2:00	1:00	D
-Rule	Toronto	1933	only	-	Oct	1	2:00	0	S
-Rule	Toronto	1934	1939	-	Sep	lastSun	2:00	0	S
-Rule	Toronto	1945	1946	-	Sep	lastSun	2:00	0	S
-Rule	Toronto	1946	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Toronto	1947	1949	-	Apr	lastSun	0:00	1:00	D
-Rule	Toronto	1947	1948	-	Sep	lastSun	0:00	0	S
-Rule	Toronto	1949	only	-	Nov	lastSun	0:00	0	S
-Rule	Toronto	1950	1973	-	Apr	lastSun	2:00	1:00	D
-Rule	Toronto	1950	only	-	Nov	lastSun	2:00	0	S
-Rule	Toronto	1951	1956	-	Sep	lastSun	2:00	0	S
-# Shanks & Pottenger say Toronto ended DST a week early in 1971,
-# namely on 1971-10-24, but Mark Brader wrote (2003-05-31) that this
-# is wrong, and that he had confirmed it by checking the 1971-10-30
-# Toronto Star, which said that DST was ending 1971-10-31 as usual.
-Rule	Toronto	1957	1973	-	Oct	lastSun	2:00	0	S
-
-# From Paul Eggert (2003-07-27):
-# Willett (1914-03) writes (p. 17) "In the Cities of Fort William, and
-# Port Arthur, Ontario, the principle of the Bill has been in
-# operation for the past three years, and in the City of Moose Jaw,
-# Saskatchewan, for one year."
-
-# From David Bryan via Tory Tronrud, Director/Curator,
-# Thunder Bay Museum (2003-11-12):
-# There is some suggestion, however, that, by-law or not, daylight
-# savings time was being practiced in Fort William and Port Arthur
-# before 1909.... [I]n 1910, the line between the Eastern and Central
-# Time Zones was permanently moved about two hundred miles west to
-# include the Thunder Bay area....  When Canada adopted daylight
-# savings time in 1916, Fort William and Port Arthur, having done so
-# already, did not change their clocks....  During the Second World
-# War,... [t]he cities agreed to implement DST during the summer
-# months for the remainder of the war years.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Toronto	-5:17:32 -	LMT	1895
-			-5:00	Canada	E%sT	1919
-			-5:00	Toronto	E%sT	1942 Feb  9 2:00s
-			-5:00	Canada	E%sT	1946
-			-5:00	Toronto	E%sT	1974
-			-5:00	Canada	E%sT
-Zone America/Thunder_Bay -5:57:00 -	LMT	1895
-			-6:00	-	CST	1910
-			-5:00	-	EST	1942
-			-5:00	Canada	E%sT	1970
-			-5:00	Mont	E%sT	1973
-			-5:00	-	EST	1974
-			-5:00	Canada	E%sT
-Zone America/Nipigon	-5:53:04 -	LMT	1895
-			-5:00	Canada	E%sT	1940 Sep 29
-			-5:00	1:00	EDT	1942 Feb  9 2:00s
-			-5:00	Canada	E%sT
-Zone America/Rainy_River -6:18:16 -	LMT	1895
-			-6:00	Canada	C%sT	1940 Sep 29
-			-6:00	1:00	CDT	1942 Feb  9 2:00s
-			-6:00	Canada	C%sT
-Zone America/Atikokan	-6:06:28 -	LMT	1895
-			-6:00	Canada	C%sT	1940 Sep 29
-			-6:00	1:00	CDT	1942 Feb  9 2:00s
-			-6:00	Canada	C%sT	1945 Sep 30 2:00
-			-5:00	-	EST
-
-
-# Manitoba
-
-# From Rob Douglas (2006-04-06):
-# the old Manitoba Time Act - as amended by Bill 2, assented to
-# March 27, 1987 ... said ...
-# "between two o'clock Central Standard Time in the morning of
-# the first Sunday of April of each year and two o'clock Central
-# Standard Time in the morning of the last Sunday of October next
-# following, one hour in advance of Central Standard Time."...
-# I believe that the English legislation [of the old time act] had =
-# been assented to (March 22, 1967)....
-# Also, as far as I can tell, there was no order-in-council varying
-# the time of Daylight Saving Time for 2005 and so the provisions of
-# the 1987 version would apply - the changeover was at 2:00 Central
-# Standard Time (i.e. not until 3:00 Central Daylight Time).
-
-# From Paul Eggert (2006-04-10):
-# Shanks & Pottenger say Manitoba switched at 02:00 (not 02:00s)
-# starting 1966.  Since 02:00s is clearly correct for 1967 on, assume
-# it was also 02:00s in 1966.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Winn	1916	only	-	Apr	23	0:00	1:00	D
-Rule	Winn	1916	only	-	Sep	17	0:00	0	S
-Rule	Winn	1918	only	-	Apr	14	2:00	1:00	D
-Rule	Winn	1918	only	-	Oct	31	2:00	0	S
-Rule	Winn	1937	only	-	May	16	2:00	1:00	D
-Rule	Winn	1937	only	-	Sep	26	2:00	0	S
-Rule	Winn	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	Winn	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	Winn	1945	only	-	Sep	lastSun	2:00	0	S
-Rule	Winn	1946	only	-	May	12	2:00	1:00	D
-Rule	Winn	1946	only	-	Oct	13	2:00	0	S
-Rule	Winn	1947	1949	-	Apr	lastSun	2:00	1:00	D
-Rule	Winn	1947	1949	-	Sep	lastSun	2:00	0	S
-Rule	Winn	1950	only	-	May	 1	2:00	1:00	D
-Rule	Winn	1950	only	-	Sep	30	2:00	0	S
-Rule	Winn	1951	1960	-	Apr	lastSun	2:00	1:00	D
-Rule	Winn	1951	1958	-	Sep	lastSun	2:00	0	S
-Rule	Winn	1959	only	-	Oct	lastSun	2:00	0	S
-Rule	Winn	1960	only	-	Sep	lastSun	2:00	0	S
-Rule	Winn	1963	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Winn	1963	only	-	Sep	22	2:00	0	S
-Rule	Winn	1966	1986	-	Apr	lastSun	2:00s	1:00	D
-Rule	Winn	1966	2005	-	Oct	lastSun	2:00s	0	S
-Rule	Winn	1987	2005	-	Apr	Sun>=1	2:00s	1:00	D
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Winnipeg	-6:28:36 -	LMT	1887 Jul 16
-			-6:00	Winn	C%sT	2006
-			-6:00	Canada	C%sT
-
-
-# Saskatchewan
-
-# From Mark Brader (2003-07-26):
-# The first actual adoption of DST in Canada was at the municipal
-# level.  As the [Toronto] Star put it (1912-06-07), "While people
-# elsewhere have long been talking of legislation to save daylight,
-# the city of Moose Jaw [Saskatchewan] has acted on its own hook."
-# DST in Moose Jaw began on Saturday, 1912-06-01 (no time mentioned:
-# presumably late evening, as below), and would run until "the end of
-# the summer".  The discrepancy between municipal time and railroad
-# time was noted.
-
-# From Paul Eggert (2003-07-27):
-# Willett (1914-03) notes that DST "has been in operation ... in the
-# City of Moose Jaw, Saskatchewan, for one year."
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say that since 1970 this region has mostly been as Regina.
-# Some western towns (e.g. Swift Current) switched from MST/MDT to CST in 1972.
-# Other western towns (e.g. Lloydminster) are like Edmonton.
-# Matthews and Vincent (1998) write that Denare Beach and Creighton
-# are like Winnipeg, in violation of Saskatchewan law.
-
-# From W. Jones (1992-11-06):
-# The. . .below is based on information I got from our law library, the
-# provincial archives, and the provincial Community Services department.
-# A precise history would require digging through newspaper archives, and
-# since you didn't say what you wanted, I didn't bother.
-#
-# Saskatchewan is split by a time zone meridian (105W) and over the years
-# the boundary became pretty ragged as communities near it reevaluated
-# their affiliations in one direction or the other.  In 1965 a provincial
-# referendum favoured legislating common time practices.
-#
-# On 15 April 1966 the Time Act (c. T-14, Revised Statutes of
-# Saskatchewan 1978) was proclaimed, and established that the eastern
-# part of Saskatchewan would use CST year round, that districts in
-# northwest Saskatchewan would by default follow CST but could opt to
-# follow Mountain Time rules (thus 1 hour difference in the winter and
-# zero in the summer), and that districts in southwest Saskatchewan would
-# by default follow MT but could opt to follow CST.
-#
-# It took a few years for the dust to settle (I know one story of a town
-# on one time zone having its school in another, such that a mom had to
-# serve her family lunch in two shifts), but presently it seems that only
-# a few towns on the border with Alberta (e.g. Lloydminster) follow MT
-# rules any more; all other districts appear to have used CST year round
-# since sometime in the 1960s.
-
-# From Chris Walton (2006-06-26):
-# The Saskatchewan time act which was last updated in 1996 is about 30 pages
-# long and rather painful to read.
-# http://www.qp.gov.sk.ca/documents/English/Statutes/Statutes/T14.pdf
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Regina	1918	only	-	Apr	14	2:00	1:00	D
-Rule	Regina	1918	only	-	Oct	31	2:00	0	S
-Rule	Regina	1930	1934	-	May	Sun>=1	0:00	1:00	D
-Rule	Regina	1930	1934	-	Oct	Sun>=1	0:00	0	S
-Rule	Regina	1937	1941	-	Apr	Sun>=8	0:00	1:00	D
-Rule	Regina	1937	only	-	Oct	Sun>=8	0:00	0	S
-Rule	Regina	1938	only	-	Oct	Sun>=1	0:00	0	S
-Rule	Regina	1939	1941	-	Oct	Sun>=8	0:00	0	S
-Rule	Regina	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	Regina	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	Regina	1945	only	-	Sep	lastSun	2:00	0	S
-Rule	Regina	1946	only	-	Apr	Sun>=8	2:00	1:00	D
-Rule	Regina	1946	only	-	Oct	Sun>=8	2:00	0	S
-Rule	Regina	1947	1957	-	Apr	lastSun	2:00	1:00	D
-Rule	Regina	1947	1957	-	Sep	lastSun	2:00	0	S
-Rule	Regina	1959	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Regina	1959	only	-	Oct	lastSun	2:00	0	S
-#
-Rule	Swift	1957	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Swift	1957	only	-	Oct	lastSun	2:00	0	S
-Rule	Swift	1959	1961	-	Apr	lastSun	2:00	1:00	D
-Rule	Swift	1959	only	-	Oct	lastSun	2:00	0	S
-Rule	Swift	1960	1961	-	Sep	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Regina	-6:58:36 -	LMT	1905 Sep
-			-7:00	Regina	M%sT	1960 Apr lastSun 2:00
-			-6:00	-	CST
-Zone America/Swift_Current -7:11:20 -	LMT	1905 Sep
-			-7:00	Canada	M%sT	1946 Apr lastSun 2:00
-			-7:00	Regina	M%sT	1950
-			-7:00	Swift	M%sT	1972 Apr lastSun 2:00
-			-6:00	-	CST
-
-
-# Alberta
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Edm	1918	1919	-	Apr	Sun>=8	2:00	1:00	D
-Rule	Edm	1918	only	-	Oct	31	2:00	0	S
-Rule	Edm	1919	only	-	May	27	2:00	0	S
-Rule	Edm	1920	1923	-	Apr	lastSun	2:00	1:00	D
-Rule	Edm	1920	only	-	Oct	lastSun	2:00	0	S
-Rule	Edm	1921	1923	-	Sep	lastSun	2:00	0	S
-Rule	Edm	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	Edm	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	Edm	1945	only	-	Sep	lastSun	2:00	0	S
-Rule	Edm	1947	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Edm	1947	only	-	Sep	lastSun	2:00	0	S
-Rule	Edm	1967	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Edm	1967	only	-	Oct	lastSun	2:00	0	S
-Rule	Edm	1969	only	-	Apr	lastSun	2:00	1:00	D
-Rule	Edm	1969	only	-	Oct	lastSun	2:00	0	S
-Rule	Edm	1972	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	Edm	1972	2006	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Edmonton	-7:33:52 -	LMT	1906 Sep
-			-7:00	Edm	M%sT	1987
-			-7:00	Canada	M%sT
-
-
-# British Columbia
-
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger write that since 1970 most of this region has
-# been like Vancouver.
-# Dawson Creek uses MST.  Much of east BC is like Edmonton.
-# Matthews and Vincent (1998) write that Creston is like Dawson Creek.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Vanc	1918	only	-	Apr	14	2:00	1:00	D
-Rule	Vanc	1918	only	-	Oct	31	2:00	0	S
-Rule	Vanc	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	Vanc	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	Vanc	1945	only	-	Sep	30	2:00	0	S
-Rule	Vanc	1946	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	Vanc	1946	only	-	Oct	13	2:00	0	S
-Rule	Vanc	1947	1961	-	Sep	lastSun	2:00	0	S
-Rule	Vanc	1962	2006	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Vancouver	-8:12:28 -	LMT	1884
-			-8:00	Vanc	P%sT	1987
-			-8:00	Canada	P%sT
-Zone America/Dawson_Creek -8:00:56 -	LMT	1884
-			-8:00	Canada	P%sT	1947
-			-8:00	Vanc	P%sT	1972 Aug 30 2:00
-			-7:00	-	MST
-
-
-# Northwest Territories, Nunavut, Yukon
-
-# From Paul Eggert (2006-03-22):
-# Dawson switched to PST in 1973.  Inuvik switched to MST in 1979.
-# Mathew Englander (1996-10-07) gives the following refs:
-#	* 1967. Paragraph 28(34)(g) of the Interpretation Act, S.C. 1967-68,
-#	c. 7 defines Yukon standard time as UTC-9.  This is still valid;
-#	see Interpretation Act, R.S.C. 1985, c. I-21, s. 35(1).
-#	* C.O. 1973/214 switched Yukon to PST on 1973-10-28 00:00.
-#	* O.I.C. 1980/02 established DST.
-#	* O.I.C. 1987/056 changed DST to Apr firstSun 2:00 to Oct lastSun 2:00.
-# Shanks & Pottenger say Yukon's 1973-10-28 switch was at 2:00; go
-# with Englander.
-# From Chris Walton (2006-06-26):
-# Here is a link to the old daylight saving portion of the interpretation
-# act which was last updated in 1987:
-# http://www.gov.yk.ca/legislation/regs/oic1987_056.pdf
-
-# From Rives McDow (1999-09-04):
-# Nunavut ... moved ... to incorporate the whole territory into one time zone.
-# <a href="http://www.nunatsiaq.com/nunavut/nvt90903_13.html">
-# Nunavut moves to single time zone Oct. 31
-# </a>
-#
-# From Antoine Leca (1999-09-06):
-# We then need to create a new timezone for the Kitikmeot region of Nunavut
-# to differentiate it from the Yellowknife region.
-
-# From Paul Eggert (1999-09-20):
-# <a href="http://www.nunavut.com/basicfacts/english/basicfacts_1territory.html">
-# Basic Facts: The New Territory
-# </a> (1999) reports that Pangnirtung operates on eastern time,
-# and that Coral Harbour does not observe DST.  We don't know when
-# Pangnirtung switched to eastern time; we'll guess 1995.
-
-# From Rives McDow (1999-11-08):
-# On October 31, when the rest of Nunavut went to Central time,
-# Pangnirtung wobbled.  Here is the result of their wobble:
-#
-# The following businesses and organizations in Pangnirtung use Central Time:
-#
-#	First Air, Power Corp, Nunavut Construction, Health Center, RCMP,
-#	Eastern Arctic National Parks, A & D Specialist
-#
-# The following businesses and organizations in Pangnirtung use Eastern Time:
-#
-#	Hamlet office, All other businesses, Both schools, Airport operator
-#
-# This has made for an interesting situation there, which warranted the news.
-# No one there that I spoke with seems concerned, or has plans to
-# change the local methods of keeping time, as it evidently does not
-# really interfere with any activities or make things difficult locally.
-# They plan to celebrate New Year's turn-over twice, one hour apart,
-# so it appears that the situation will last at least that long.
-# The Nunavut Intergovernmental Affairs hopes that they will "come to
-# their senses", but the locals evidently don't see any problem with
-# the current state of affairs.
-
-# From Michaela Rodrigue, writing in the
-# <a href="http://www.nunatsiaq.com/archives/nunavut991130/nvt91119_17.html">
-# Nunatsiaq News (1999-11-19)</a>:
-# Clyde River, Pangnirtung and Sanikiluaq now operate with two time zones,
-# central - or Nunavut time - for government offices, and eastern time
-# for municipal offices and schools....  Igloolik [was similar but then]
-# made the switch to central time on Saturday, Nov. 6.
-
-# From Paul Eggert (2000-10-02):
-# Matthews and Vincent (1998) say the following, but we lack histories
-# for these potential new Zones.
-#
-# The Canadian Forces station at Alert uses Eastern Time while the
-# handful of residents at the Eureka weather station [in the Central
-# zone] skip daylight savings.  Baffin Island, which is crossed by the
-# Central, Eastern and Atlantic Time zones only uses Eastern Time.
-# Gjoa Haven, Taloyoak and Pelly Bay all use Mountain instead of
-# Central Time and Southampton Island [in the Central zone] is not
-# required to use daylight savings.
-
-# From
-# <a href="http://www.nunatsiaq.com/archives/nunavut001130/nvt21110_02.html">
-# Nunavut now has two time zones
-# </a> (2000-11-10):
-# The Nunavut government would allow its employees in Kugluktuk and
-# Cambridge Bay to operate on central time year-round, putting them
-# one hour behind the rest of Nunavut for six months during the winter.
-# At the end of October the two communities had rebelled against
-# Nunavut's unified time zone, refusing to shift to eastern time with
-# the rest of the territory for the winter.  Cambridge Bay remained on
-# central time, while Kugluktuk, even farther west, reverted to
-# mountain time, which they had used before the advent of Nunavut's
-# unified time zone in 1999.
-#
-# From Rives McDow (2001-01-20), quoting the Nunavut government:
-# The preceding decision came into effect at midnight, Saturday Nov 4, 2000.
-
-# From Paul Eggert (2000-12-04):
-# Let's just keep track of the official times for now.
-
-# From Rives McDow (2001-03-07):
-# The premier of Nunavut has issued a ministerial statement advising
-# that effective 2001-04-01, the territory of Nunavut will revert
-# back to three time zones (mountain, central, and eastern).  Of the
-# cities in Nunavut, Coral Harbor is the only one that I know of that
-# has said it will not observe dst, staying on EST year round.  I'm
-# checking for more info, and will get back to you if I come up with
-# more.
-# [Also see <http://www.nunatsiaq.com/nunavut/nvt10309_06.html> (2001-03-09).]
-
-# From Gwillim Law (2005-05-21):
-# According to maps at
-# http://inms-ienm.nrc-cnrc.gc.ca/images/time_services/TZ01SWE.jpg
-# http://inms-ienm.nrc-cnrc.gc.ca/images/time_services/TZ01SSE.jpg
-# (both dated 2003), and
-# http://www.canadiangeographic.ca/Magazine/SO98/geomap.asp
-# (from a 1998 Canadian Geographic article), the de facto and de jure time
-# for Southampton Island (at the north end of Hudson Bay) is UTC-5 all year
-# round.  Using Google, it's easy to find other websites that confirm this.
-# I wasn't able to find how far back this time regimen goes, but since it
-# predates the creation of Nunavut, it probably goes back many years....
-# The Inuktitut name of Coral Harbour is Sallit, but it's rarely used.
-#
-# From Paul Eggert (2005-07-26):
-# For lack of better information, assume that Southampton Island observed
-# daylight saving only during wartime.
-
-# From Chris Walton (2007-03-01):
-# ... the community of Resolute (located on Cornwallis Island in
-# Nunavut) moved from Central Time to Eastern Time last November.
-# Basically the community did not change its clocks at the end of
-# daylight saving....
-# http://www.nnsl.com/frames/newspapers/2006-11/nov13_06none.html
-
-# From Chris Walton (2007-03-14):
-# Today I phoned the "hamlet office" to find out what Resolute was doing with
-# its clocks.
-#
-# The individual that answered the phone confirmed that the clocks did not
-# move at the end of daylight saving on October 29/2006.  He also told me that
-# the clocks did not move this past weekend (March 11/2007)....
-#
-# America/Resolute should use the "Canada" Rule up to October 29/2006.
-# After that it should be fixed on Eastern Standard Time until further notice.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	NT_YK	1918	only	-	Apr	14	2:00	1:00	D
-Rule	NT_YK	1918	only	-	Oct	27	2:00	0	S
-Rule	NT_YK	1919	only	-	May	25	2:00	1:00	D
-Rule	NT_YK	1919	only	-	Nov	 1	0:00	0	S
-Rule	NT_YK	1942	only	-	Feb	 9	2:00	1:00	W # War
-Rule	NT_YK	1945	only	-	Aug	14	23:00u	1:00	P # Peace
-Rule	NT_YK	1945	only	-	Sep	30	2:00	0	S
-Rule	NT_YK	1965	only	-	Apr	lastSun	0:00	2:00	DD
-Rule	NT_YK	1965	only	-	Oct	lastSun	2:00	0	S
-Rule	NT_YK	1980	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	NT_YK	1980	2006	-	Oct	lastSun	2:00	0	S
-Rule	NT_YK	1987	2006	-	Apr	Sun>=1	2:00	1:00	D
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# aka Panniqtuuq
-Zone America/Pangnirtung 0	-	zzz	1921 # trading post est.
-			-4:00	NT_YK	A%sT	1995 Apr Sun>=1 2:00
-			-5:00	Canada	E%sT	1999 Oct 31 2:00
-			-6:00	Canada	C%sT	2000 Oct 29 2:00
-			-5:00	Canada	E%sT
-# formerly Frobisher Bay
-Zone America/Iqaluit	0	-	zzz	1942 Aug # Frobisher Bay est.
-			-5:00	NT_YK	E%sT	1999 Oct 31 2:00
-			-6:00	Canada	C%sT	2000 Oct 29 2:00
-			-5:00	Canada	E%sT
-# aka Qausuittuq
-Zone America/Resolute	0	-	zzz	1947 Aug 31 # Resolute founded
-			-6:00	NT_YK	C%sT	2000 Oct 29 2:00
-			-5:00	-	EST	2001 Apr  1 3:00
-			-6:00	Canada	C%sT	2006 Oct 29 2:00
-			-5:00	-	EST
-# aka Kangiqiniq
-Zone America/Rankin_Inlet 0	-	zzz	1957 # Rankin Inlet founded
-			-6:00	NT_YK	C%sT	2000 Oct 29 2:00
-			-5:00	-	EST	2001 Apr  1 3:00
-			-6:00	Canada	C%sT
-# aka Iqaluktuuttiaq
-Zone America/Cambridge_Bay 0	-	zzz	1920 # trading post est.?
-			-7:00	NT_YK	M%sT	1999 Oct 31 2:00
-			-6:00	Canada	C%sT	2000 Oct 29 2:00
-			-5:00	-	EST	2000 Nov  5 0:00
-			-6:00	-	CST	2001 Apr  1 3:00
-			-7:00	Canada	M%sT
-Zone America/Yellowknife 0	-	zzz	1935 # Yellowknife founded?
-			-7:00	NT_YK	M%sT	1980
-			-7:00	Canada	M%sT
-Zone America/Inuvik	0	-	zzz	1953 # Inuvik founded
-			-8:00	NT_YK	P%sT	1979 Apr lastSun 2:00
-			-7:00	NT_YK	M%sT	1980
-			-7:00	Canada	M%sT
-Zone America/Whitehorse	-9:00:12 -	LMT	1900 Aug 20
-			-9:00	NT_YK	Y%sT	1966 Jul 1 2:00
-			-8:00	NT_YK	P%sT	1980
-			-8:00	Canada	P%sT
-Zone America/Dawson	-9:17:40 -	LMT	1900 Aug 20
-			-9:00	NT_YK	Y%sT	1973 Oct 28 0:00
-			-8:00	NT_YK	P%sT	1980
-			-8:00	Canada	P%sT
-
-
-###############################################################################
-
-# Mexico
-
-# From Paul Eggert (2001-03-05):
-# The Investigation and Analysis Service of the
-# Mexican Library of Congress (MLoC) has published a
-# <a href="http://www.cddhcu.gob.mx/bibliot/publica/inveyana/polisoc/horver/">
-# history of Mexican local time (in Spanish)
-# </a>.
-#
-# Here are the discrepancies between Shanks & Pottenger (S&P) and the MLoC.
-# (In all cases we go with the MLoC.)
-# S&P report that Baja was at -8:00 in 1922/1923.
-# S&P say the 1930 transition in Baja was 1930-11-16.
-# S&P report no DST during summer 1931.
-# S&P report a transition at 1932-03-30 23:00, not 1932-04-01.
-
-# From Gwillim Law (2001-02-20):
-# There are some other discrepancies between the Decrees page and the
-# tz database.  I think they can best be explained by supposing that
-# the researchers who prepared the Decrees page failed to find some of
-# the relevant documents.
-
-# From Alan Perry (1996-02-15):
-# A guy from our Mexico subsidiary finally found the Presidential Decree
-# outlining the timezone changes in Mexico.
-#
-# ------------- Begin Forwarded Message -------------
-#
-# I finally got my hands on the Official Presidential Decree that sets up the
-# rules for the DST changes. The rules are:
-#
-# 1. The country is divided in 3 timezones:
-#    - Baja California Norte (the Mexico/BajaNorte TZ)
-#    - Baja California Sur, Nayarit, Sinaloa and Sonora (the Mexico/BajaSur TZ)
-#    - The rest of the country (the Mexico/General TZ)
-#
-# 2. From the first Sunday in April at 2:00 AM to the last Sunday in October
-#    at 2:00 AM, the times in each zone are as follows:
-#    BajaNorte: GMT+7
-#    BajaSur:   GMT+6
-#    General:   GMT+5
-#
-# 3. The rest of the year, the times are as follows:
-#    BajaNorte: GMT+8
-#    BajaSur:   GMT+7
-#    General:   GMT+6
-#
-# The Decree was published in Mexico's Official Newspaper on January 4th.
-#
-# -------------- End Forwarded Message --------------
-# From Paul Eggert (1996-06-12):
-# For an English translation of the decree, see
-# <a href="http://mexico-travel.com/extra/timezone_eng.html">
-# ``Diario Oficial: Time Zone Changeover'' (1996-01-04).
-# </a>
-
-# From Rives McDow (1998-10-08):
-# The State of Quintana Roo has reverted back to central STD and DST times
-# (i.e. UTC -0600 and -0500 as of 1998-08-02).
-
-# From Rives McDow (2000-01-10):
-# Effective April 4, 1999 at 2:00 AM local time, Sonora changed to the time
-# zone 5 hours from the International Date Line, and will not observe daylight
-# savings time so as to stay on the same time zone as the southern part of
-# Arizona year round.
-
-# From Jesper Norgaard, translating
-# <http://www.reforma.com/nacional/articulo/064327/> (2001-01-17):
-# In Oaxaca, the 55.000 teachers from the Section 22 of the National
-# Syndicate of Education Workers, refuse to apply daylight saving each
-# year, so that the more than 10,000 schools work at normal hour the
-# whole year.
-
-# From Gwillim Law (2001-01-19):
-# <http://www.reforma.com/negocios_y_dinero/articulo/064481/> ... says
-# (translated):...
-# January 17, 2000 - The Energy Secretary, Ernesto Martens, announced
-# that Summer Time will be reduced from seven to five months, starting
-# this year....
-# <http://www.publico.com.mx/scripts/texto3.asp?action=pagina&pag=21&pos=p&secc=naci&date=01/17/2001>
-# [translated], says "summer time will ... take effect on the first Sunday
-# in May, and end on the last Sunday of September.
-
-# From Arthur David Olson (2001-01-25):
-# The 2001-01-24 traditional Washington Post contained the page one
-# story "Timely Issue Divides Mexicans."...
-# http://www.washingtonpost.com/wp-dyn/articles/A37383-2001Jan23.html
-# ... Mexico City Mayor Lopez Obrador "...is threatening to keep
-# Mexico City and its 20 million residents on a different time than
-# the rest of the country..." In particular, Lopez Obrador would abolish
-# observation of Daylight Saving Time.
-
-# <a href="http://www.conae.gob.mx/ahorro/decretohorver2001.html#decre">
-# Official statute published by the Energy Department
-# </a> (2001-02-01) shows Baja and Chihauhua as still using US DST rules,
-# and Sonora with no DST.  This was reported by Jesper Norgaard (2001-02-03).
-
-# From Paul Eggert (2001-03-03):
-#
-# <a href="http://www.latimes.com/news/nation/20010303/t000018766.html">
-# James F. Smith writes in today's LA Times
-# </a>
-# * Sonora will continue to observe standard time.
-# * Last week Mexico City's mayor Andres Manuel Lopez Obrador decreed that
-#   the Federal District will not adopt DST.
-# * 4 of 16 district leaders announced they'll ignore the decree.
-# * The decree does not affect federal-controlled facilities including
-#   the airport, banks, hospitals, and schools.
-#
-# For now we'll assume that the Federal District will bow to federal rules.
-
-# From Jesper Norgaard (2001-04-01):
-# I found some references to the Mexican application of daylight
-# saving, which modifies what I had already sent you, stating earlier
-# that a number of northern Mexican states would go on daylight
-# saving. The modification reverts this to only cover Baja California
-# (Norte), while all other states (except Sonora, who has no daylight
-# saving all year) will follow the original decree of president
-# Vicente Fox, starting daylight saving May 6, 2001 and ending
-# September 30, 2001.
-# References: "Diario de Monterrey" <www.diariodemonterrey.com/index.asp>
-# Palabra <http://palabra.infosel.com/010331/primera/ppri3101.pdf> (2001-03-31)
-
-# From Reuters (2001-09-04):
-# Mexico's Supreme Court on Tuesday declared that daylight savings was
-# unconstitutional in Mexico City, creating the possibility the
-# capital will be in a different time zone from the rest of the nation
-# next year....  The Supreme Court's ruling takes effect at 2:00
-# a.m. (0800 GMT) on Sept. 30, when Mexico is scheduled to revert to
-# standard time. "This is so residents of the Federal District are not
-# subject to unexpected time changes," a statement from the court said.
-
-# From Jesper Norgaard Welen (2002-03-12):
-# ... consulting my local grocery store(!) and my coworkers, they all insisted
-# that a new decision had been made to reinstate US style DST in Mexico....
-# http://www.conae.gob.mx/ahorro/horaver2001_m1_2002.html (2002-02-20)
-# confirms this.  Sonora as usual is the only state where DST is not applied.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Mexico	1939	only	-	Feb	5	0:00	1:00	D
-Rule	Mexico	1939	only	-	Jun	25	0:00	0	S
-Rule	Mexico	1940	only	-	Dec	9	0:00	1:00	D
-Rule	Mexico	1941	only	-	Apr	1	0:00	0	S
-Rule	Mexico	1943	only	-	Dec	16	0:00	1:00	W # War
-Rule	Mexico	1944	only	-	May	1	0:00	0	S
-Rule	Mexico	1950	only	-	Feb	12	0:00	1:00	D
-Rule	Mexico	1950	only	-	Jul	30	0:00	0	S
-Rule	Mexico	1996	2000	-	Apr	Sun>=1	2:00	1:00	D
-Rule	Mexico	1996	2000	-	Oct	lastSun	2:00	0	S
-Rule	Mexico	2001	only	-	May	Sun>=1	2:00	1:00	D
-Rule	Mexico	2001	only	-	Sep	lastSun	2:00	0	S
-Rule	Mexico	2002	max	-	Apr	Sun>=1	2:00	1:00	D
-Rule	Mexico	2002	max	-	Oct	lastSun	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-# Quintana Roo
-Zone America/Cancun	-5:47:04 -	LMT	1922 Jan  1  0:12:56
-			-6:00	-	CST	1981 Dec 23
-			-5:00	Mexico	E%sT	1998 Aug  2  2:00
-			-6:00	Mexico	C%sT
-# Campeche, Yucatan
-Zone America/Merida	-5:58:28 -	LMT	1922 Jan  1  0:01:32
-			-6:00	-	CST	1981 Dec 23
-			-5:00	-	EST	1982 Dec  2
-			-6:00	Mexico	C%sT
-# Coahuila, Durango, Nuevo Leon, Tamaulipas
-Zone America/Monterrey	-6:41:16 -	LMT	1921 Dec 31 23:18:44
-			-6:00	-	CST	1988
-			-6:00	US	C%sT	1989
-			-6:00	Mexico	C%sT
-# Central Mexico
-Zone America/Mexico_City -6:36:36 -	LMT	1922 Jan  1  0:23:24
-			-7:00	-	MST	1927 Jun 10 23:00
-			-6:00	-	CST	1930 Nov 15
-			-7:00	-	MST	1931 May  1 23:00
-			-6:00	-	CST	1931 Oct
-			-7:00	-	MST	1932 Apr  1
-			-6:00	Mexico	C%sT	2001 Sep 30 02:00
-			-6:00	-	CST	2002 Feb 20
-			-6:00	Mexico	C%sT
-# Chihuahua
-Zone America/Chihuahua	-7:04:20 -	LMT	1921 Dec 31 23:55:40
-			-7:00	-	MST	1927 Jun 10 23:00
-			-6:00	-	CST	1930 Nov 15
-			-7:00	-	MST	1931 May  1 23:00
-			-6:00	-	CST	1931 Oct
-			-7:00	-	MST	1932 Apr  1
-			-6:00	-	CST	1996
-			-6:00	Mexico	C%sT	1998
-			-6:00	-	CST	1998 Apr Sun>=1 3:00
-			-7:00	Mexico	M%sT
-# Sonora
-Zone America/Hermosillo	-7:23:52 -	LMT	1921 Dec 31 23:36:08
-			-7:00	-	MST	1927 Jun 10 23:00
-			-6:00	-	CST	1930 Nov 15
-			-7:00	-	MST	1931 May  1 23:00
-			-6:00	-	CST	1931 Oct
-			-7:00	-	MST	1932 Apr  1
-			-6:00	-	CST	1942 Apr 24
-			-7:00	-	MST	1949 Jan 14
-			-8:00	-	PST	1970
-			-7:00	Mexico	M%sT	1999
-			-7:00	-	MST
-# Baja California Sur, Nayarit, Sinaloa
-Zone America/Mazatlan	-7:05:40 -	LMT	1921 Dec 31 23:54:20
-			-7:00	-	MST	1927 Jun 10 23:00
-			-6:00	-	CST	1930 Nov 15
-			-7:00	-	MST	1931 May  1 23:00
-			-6:00	-	CST	1931 Oct
-			-7:00	-	MST	1932 Apr  1
-			-6:00	-	CST	1942 Apr 24
-			-7:00	-	MST	1949 Jan 14
-			-8:00	-	PST	1970
-			-7:00	Mexico	M%sT
-# Baja California
-Zone America/Tijuana	-7:48:04 -	LMT	1922 Jan  1  0:11:56
-			-7:00	-	MST	1924
-			-8:00	-	PST	1927 Jun 10 23:00
-			-7:00	-	MST	1930 Nov 15
-			-8:00	-	PST	1931 Apr  1
-			-8:00	1:00	PDT	1931 Sep 30
-			-8:00	-	PST	1942 Apr 24
-			-8:00	1:00	PWT	1945 Aug 14 23:00u
-			-8:00	1:00	PPT	1945 Nov 12 # Peace
-			-8:00	-	PST	1948 Apr  5
-			-8:00	1:00	PDT	1949 Jan 14
-			-8:00	-	PST	1954
-			-8:00	CA	P%sT	1961
-			-8:00	-	PST	1976
-			-8:00	US	P%sT	1996
-			-8:00	Mexico	P%sT	2001
-			-8:00	US	P%sT	2002 Feb 20
-			-8:00	Mexico	P%sT
-# From Paul Eggert (2006-03-22):
-# Formerly there was an America/Ensenada zone, which differed from
-# America/Tijuana only in that it did not observe DST from 1976
-# through 1995.  This was as per Shanks (1999).  But Shanks & Pottenger say
-# Ensenada did not observe DST from 1948 through 1975.  Guy Harris reports
-# that the 1987 OAG says "Only Ensenada, Mexicale, San Felipe and
-# Tijuana observe DST," which agrees with Shanks & Pottenger but implies that
-# DST-observance was a town-by-town matter back then.  This concerns
-# data after 1970 so most likely there should be at least one Zone
-# other than America/Tijuana for Baja, but it's not clear yet what its
-# name or contents should be.
-#
-# Revillagigedo Is
-# no information
-
-###############################################################################
-
-# Anguilla
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Anguilla	-4:12:16 -	LMT	1912 Mar 2
-			-4:00	-	AST
-
-# Antigua and Barbuda
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Antigua	-4:07:12 -	LMT	1912 Mar 2
-			-5:00	-	EST	1951
-			-4:00	-	AST
-
-# Bahamas
-#
-# From Sue Williams (2006-12-07):
-# The Bahamas announced about a month ago that they plan to change their DST
-# rules to sync with the U.S. starting in 2007....
-# http://www.jonesbahamas.com/?c=45&a=10412
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Bahamas	1964	1975	-	Oct	lastSun	2:00	0	S
-Rule	Bahamas	1964	1975	-	Apr	lastSun	2:00	1:00	D
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Nassau	-5:09:24 -	LMT	1912 Mar 2
-			-5:00	Bahamas	E%sT	1976
-			-5:00	US	E%sT
-
-# Barbados
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Barb	1977	only	-	Jun	12	2:00	1:00	D
-Rule	Barb	1977	1978	-	Oct	Sun>=1	2:00	0	S
-Rule	Barb	1978	1980	-	Apr	Sun>=15	2:00	1:00	D
-Rule	Barb	1979	only	-	Sep	30	2:00	0	S
-Rule	Barb	1980	only	-	Sep	25	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Barbados	-3:58:28 -	LMT	1924		# Bridgetown
-			-3:58:28 -	BMT	1932	  # Bridgetown Mean Time
-			-4:00	Barb	A%sT
-
-# Belize
-# Whitman entirely disagrees with Shanks; go with Shanks & Pottenger.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Belize	1918	1942	-	Oct	Sun>=2	0:00	0:30	HD
-Rule	Belize	1919	1943	-	Feb	Sun>=9	0:00	0	S
-Rule	Belize	1973	only	-	Dec	 5	0:00	1:00	D
-Rule	Belize	1974	only	-	Feb	 9	0:00	0	S
-Rule	Belize	1982	only	-	Dec	18	0:00	1:00	D
-Rule	Belize	1983	only	-	Feb	12	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Belize	-5:52:48 -	LMT	1912 Apr
-			-6:00	Belize	C%sT
-
-# Bermuda
-
-# From Dan Jones, reporting in The Royal Gazette (2006-06-26):
-
-# Next year, however, clocks in the US will go forward on the second Sunday
-# in March, until the first Sunday in November.  And, after the Time Zone
-# (Seasonal Variation) Bill 2006 was passed in the House of Assembly on
-# Friday, the same thing will happen in Bermuda.
-# http://www.theroyalgazette.com/apps/pbcs.dll/article?AID=/20060529/NEWS/105290135
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/Bermuda	-4:19:04 -	LMT	1930 Jan  1 2:00    # Hamilton
-			-4:00	-	AST	1974 Apr 28 2:00
-			-4:00	Bahamas	A%sT	1976
-			-4:00	US	A%sT
-
-# Cayman Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Cayman	-5:25:32 -	LMT	1890		# Georgetown
-			-5:07:12 -	KMT	1912 Feb    # Kingston Mean Time
-			-5:00	-	EST
-
-# Costa Rica
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	CR	1979	1980	-	Feb	lastSun	0:00	1:00	D
-Rule	CR	1979	1980	-	Jun	Sun>=1	0:00	0	S
-Rule	CR	1991	1992	-	Jan	Sat>=15	0:00	1:00	D
-# IATA SSIM (1991-09) says the following was at 1:00;
-# go with Shanks & Pottenger.
-Rule	CR	1991	only	-	Jul	 1	0:00	0	S
-Rule	CR	1992	only	-	Mar	15	0:00	0	S
-# There are too many San Joses elsewhere, so we'll use `Costa Rica'.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Costa_Rica	-5:36:20 -	LMT	1890		# San Jose
-			-5:36:20 -	SJMT	1921 Jan 15 # San Jose Mean Time
-			-6:00	CR	C%sT
-# Coco
-# no information; probably like America/Costa_Rica
-
-# Cuba
-
-# From Arthur David Olson (1999-03-29):
-# The 1999-03-28 exhibition baseball game held in Havana, Cuba, between
-# the Cuban National Team and the Baltimore Orioles was carried live on
-# the Orioles Radio Network, including affiliate WTOP in Washington, DC.
-# During the game, play-by-play announcer Jim Hunter noted that
-# "We'll be losing two hours of sleep...Cuba switched to Daylight Saving
-# Time today."  (The "two hour" remark referred to losing one hour of
-# sleep on 1999-03-28--when the announcers were in Cuba as it switched
-# to DST--and one more hour on 1999-04-04--when the announcers will have
-# returned to Baltimore, which switches on that date.)
-
-# From Evert van der Veer via Steffen Thorsen (2004-10-28):
-# Cuba is not going back to standard time this year.
-# From Paul Eggert (2006-03-22):
-# http://www.granma.cu/ingles/2004/septiembre/juev30/41medid-i.html
-# says that it's due to a problem at the Antonio Guiteras
-# thermoelectric plant, and says "This October there will be no return
-# to normal hours (after daylight saving time)".
-# For now, let's assume that it's a temporary measure.
-
-# From Carlos A. Carnero Delgado (2005-11-12):
-# This year (just like in 2004-2005) there's no change in time zone
-# adjustment in Cuba.  We will stay in daylight saving time:
-# http://www.granma.cu/espanol/2005/noviembre/mier9/horario.html
-
-# From Jesper Norgaard Welen (2006-10-21):
-# An article in GRANMA INTERNACIONAL claims that Cuba will end
-# the 3 years of permanent DST next weekend, see
-# http://www.granma.cu/ingles/2006/octubre/lun16/43horario.html
-# "On Saturday night, October 28 going into Sunday, October 29, at 01:00,
-# watches should be set back one hour -- going back to 00:00 hours -- returning
-# to the normal schedule....
-
-# From Paul Eggert (2007-03-02):
-# http://www.granma.cubaweb.cu/english/news/art89.html, dated yesterday,
-# says Cuban clocks will advance at midnight on March 10.
-# For lack of better information, assume Cuba will use US rules,
-# except that it switches at midnight standard time as usual.
-#
-# From Steffen Thorsen (2007-10-25):
-# Carlos Alberto Fonseca Arauz informed me that Cuba will end DST one week 
-# earlier - on the last Sunday of October, just like in 2006.
-# 
-# He supplied these references:
-# 
-# http://www.prensalatina.com.mx/article.asp?ID=%7B4CC32C1B-A9F7-42FB-8A07-8631AFC923AF%7D&language=ES
-# http://actualidad.terra.es/sociedad/articulo/cuba_llama_ahorrar_energia_cambio_1957044.htm
-# 
-# From Alex Kryvenishev (2007-10-25):
-# Here is also article from Granma (Cuba):
-# 
-# [Regira] el Horario Normal desde el [proximo] domingo 28 de octubre
-# http://www.granma.cubaweb.cu/2007/10/24/nacional/artic07.html
-# 
-# http://www.worldtimezone.com/dst_news/dst_news_cuba03.html
-
-# From Arthur David Olson (2008-03-09):
-# I'm in Maryland which is now observing United States Eastern Daylight
-# Time. At 9:44 local time I used RealPlayer to listen to
-# <a href="http://media.enet.cu/radioreloj">
-# http://media.enet.cu/radioreloj
-# </a>, a Cuban information station, and heard
-# the time announced as "ocho cuarenta y cuatro" ("eight forty-four"),
-# indicating that Cuba is still on standard time.
-
-# From Steffen Thorsen (2008-03-12):
-# It seems that Cuba will start DST on Sunday, 2007-03-16...
-# It was announced yesterday, according to this source (in Spanish):
-# <a href="http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm">
-# http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm
-# </a>
-#
-# Some more background information is posted here:
-# <a href="http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html">
-# http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html
-# </a>
-#
-# The article also says that Cuba has been observing DST since 1963,
-# while Shanks (and tzdata) has 1965 as the first date (except in the
-# 1940's). Many other web pages in Cuba also claim that it has been
-# observed since 1963, but with the exception of 1970 - an exception
-# which is not present in tzdata/Shanks. So there is a chance we need to
-# change some historic records as well.
-#
-# One example:
-# <a href="http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm">
-# http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm
-# </a>
-
-# From Jesper Norgaard Welen (2008-03-13):
-# The Cuban time change has just been confirmed on the most authoritative
-# web site, the Granma.  Please check out
-# <a href="http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html">
-# http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html
-# </a>
-#
-# Basically as expected after Steffen Thorsens information, the change
-# will take place midnight between Saturday and Sunday.
-
-# From Arthur David Olson (2008-03-12):
-# Assume Sun>=15 (third Sunday) going forward.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Cuba	1928	only	-	Jun	10	0:00	1:00	D
-Rule	Cuba	1928	only	-	Oct	10	0:00	0	S
-Rule	Cuba	1940	1942	-	Jun	Sun>=1	0:00	1:00	D
-Rule	Cuba	1940	1942	-	Sep	Sun>=1	0:00	0	S
-Rule	Cuba	1945	1946	-	Jun	Sun>=1	0:00	1:00	D
-Rule	Cuba	1945	1946	-	Sep	Sun>=1	0:00	0	S
-Rule	Cuba	1965	only	-	Jun	1	0:00	1:00	D
-Rule	Cuba	1965	only	-	Sep	30	0:00	0	S
-Rule	Cuba	1966	only	-	May	29	0:00	1:00	D
-Rule	Cuba	1966	only	-	Oct	2	0:00	0	S
-Rule	Cuba	1967	only	-	Apr	8	0:00	1:00	D
-Rule	Cuba	1967	1968	-	Sep	Sun>=8	0:00	0	S
-Rule	Cuba	1968	only	-	Apr	14	0:00	1:00	D
-Rule	Cuba	1969	1977	-	Apr	lastSun	0:00	1:00	D
-Rule	Cuba	1969	1971	-	Oct	lastSun	0:00	0	S
-Rule	Cuba	1972	1974	-	Oct	8	0:00	0	S
-Rule	Cuba	1975	1977	-	Oct	lastSun	0:00	0	S
-Rule	Cuba	1978	only	-	May	7	0:00	1:00	D
-Rule	Cuba	1978	1990	-	Oct	Sun>=8	0:00	0	S
-Rule	Cuba	1979	1980	-	Mar	Sun>=15	0:00	1:00	D
-Rule	Cuba	1981	1985	-	May	Sun>=5	0:00	1:00	D
-Rule	Cuba	1986	1989	-	Mar	Sun>=14	0:00	1:00	D
-Rule	Cuba	1990	1997	-	Apr	Sun>=1	0:00	1:00	D
-Rule	Cuba	1991	1995	-	Oct	Sun>=8	0:00s	0	S
-Rule	Cuba	1996	only	-	Oct	 6	0:00s	0	S
-Rule	Cuba	1997	only	-	Oct	12	0:00s	0	S
-Rule	Cuba	1998	1999	-	Mar	lastSun	0:00s	1:00	D
-Rule	Cuba	1998	2003	-	Oct	lastSun	0:00s	0	S
-Rule	Cuba	2000	2006	-	Apr	Sun>=1	0:00s	1:00	D
-Rule	Cuba	2006	max	-	Oct	lastSun	0:00s	0	S
-Rule	Cuba	2007	only	-	Mar	Sun>=8	0:00s	1:00	D
-Rule	Cuba	2008	max	-	Mar	Sun>=15	0:00s	1:00	D
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Havana	-5:29:28 -	LMT	1890
-			-5:29:36 -	HMT	1925 Jul 19 12:00 # Havana MT
-			-5:00	Cuba	C%sT
-
-# Dominica
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Dominica	-4:05:36 -	LMT	1911 Jul 1 0:01		# Roseau
-			-4:00	-	AST
-
-# Dominican Republic
-
-# From Steffen Thorsen (2000-10-30):
-# Enrique Morales reported to me that the Dominican Republic has changed the
-# time zone to Eastern Standard Time as of Sunday 29 at 2 am....
-# http://www.listin.com.do/antes/261000/republica/princi.html
-
-# From Paul Eggert (2000-12-04):
-# That URL (2000-10-26, in Spanish) says they planned to use US-style DST.
-
-# From Rives McDow (2000-12-01):
-# Dominican Republic changed its mind and presidential decree on Tuesday,
-# November 28, 2000, with a new decree.  On Sunday, December 3 at 1:00 AM the
-# Dominican Republic will be reverting to 8 hours from the International Date
-# Line, and will not be using DST in the foreseeable future.  The reason they
-# decided to use DST was to be in synch with Puerto Rico, who was also going
-# to implement DST.  When Puerto Rico didn't implement DST, the president
-# decided to revert.
-
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	DR	1966	only	-	Oct	30	0:00	1:00	D
-Rule	DR	1967	only	-	Feb	28	0:00	0	S
-Rule	DR	1969	1973	-	Oct	lastSun	0:00	0:30	HD
-Rule	DR	1970	only	-	Feb	21	0:00	0	S
-Rule	DR	1971	only	-	Jan	20	0:00	0	S
-Rule	DR	1972	1974	-	Jan	21	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Santo_Domingo -4:39:36 -	LMT	1890
-			-4:40	-	SDMT	1933 Apr  1 12:00 # S. Dom. MT
-			-5:00	DR	E%sT	1974 Oct 27
-			-4:00	-	AST	2000 Oct 29 02:00
-			-5:00	US	E%sT	2000 Dec  3 01:00
-			-4:00	-	AST
-
-# El Salvador
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Salv	1987	1988	-	May	Sun>=1	0:00	1:00	D
-Rule	Salv	1987	1988	-	Sep	lastSun	0:00	0	S
-# There are too many San Salvadors elsewhere, so use America/El_Salvador
-# instead of America/San_Salvador.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/El_Salvador -5:56:48 -	LMT	1921		# San Salvador
-			-6:00	Salv	C%sT
-
-# Grenada
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Grenada	-4:07:00 -	LMT	1911 Jul	# St George's
-			-4:00	-	AST
-
-# Guadeloupe
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Guadeloupe	-4:06:08 -	LMT	1911 Jun 8	# Pointe a Pitre
-			-4:00	-	AST
-# St Barthelemy
-Link America/Guadeloupe	America/St_Barthelemy
-# St Martin (French part)
-Link America/Guadeloupe	America/Marigot
-
-# Guatemala
-#
-# From Gwillim Law (2006-04-22), after a heads-up from Oscar van Vlijmen:
-# Diario Co Latino, at
-# http://www.diariocolatino.com/internacionales/detalles.asp?NewsID=8079,
-# says in an article dated 2006-04-19 that the Guatemalan government had
-# decided on that date to advance official time by 60 minutes, to lessen the
-# impact of the elevated cost of oil....  Daylight saving time will last from
-# 2006-04-29 24:00 (Guatemalan standard time) to 2006-09-30 (time unspecified).
-# From Paul Eggert (2006-06-22):
-# The Ministry of Energy and Mines, press release CP-15/2006
-# (2006-04-19), says DST ends at 24:00.  See
-# <http://www.sieca.org.gt/Sitio_publico/Energeticos/Doc/Medidas/Cambio_Horario_Nac_190406.pdf>.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Guat	1973	only	-	Nov	25	0:00	1:00	D
-Rule	Guat	1974	only	-	Feb	24	0:00	0	S
-Rule	Guat	1983	only	-	May	21	0:00	1:00	D
-Rule	Guat	1983	only	-	Sep	22	0:00	0	S
-Rule	Guat	1991	only	-	Mar	23	0:00	1:00	D
-Rule	Guat	1991	only	-	Sep	 7	0:00	0	S
-Rule	Guat	2006	only	-	Apr	30	0:00	1:00	D
-Rule	Guat	2006	only	-	Oct	 1	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Guatemala	-6:02:04 -	LMT	1918 Oct 5
-			-6:00	Guat	C%sT
-
-# Haiti
-# From Gwillim Law (2005-04-15):
-# Risto O. Nykanen wrote me that Haiti is now on DST.
-# I searched for confirmation, and I found a
-# <a href="http://www.haitianconsulate.org/time.doc"> press release
-# on the Web page of the Haitian Consulate in Chicago (2005-03-31),
-# </a>.  Translated from French, it says:
-#
-#  "The Prime Minister's Communication Office notifies the public in general
-#   and the press in particular that, following a decision of the Interior
-#   Ministry and the Territorial Collectivities [I suppose that means the
-#   provinces], Haiti will move to Eastern Daylight Time in the night from next
-#   Saturday the 2nd to Sunday the 3rd.
-#
-#  "Consequently, the Prime Minister's Communication Office wishes to inform
-#   the population that the country's clocks will be set forward one hour
-#   starting at midnight.  This provision will hold until the last Saturday in
-#   October 2005.
-#
-#  "Port-au-Prince, March 31, 2005"
-#
-# From Steffen Thorsen (2006-04-04):
-# I have been informed by users that Haiti observes DST this year like
-# last year, so the current "only" rule for 2005 might be changed to a
-# "max" rule or to last until 2006. (Who knows if they will observe DST
-# next year or if they will extend their DST like US/Canada next year).
-#
-# I have found this article about it (in French):
-# http://www.haitipressnetwork.com/news.cfm?articleID=7612
-#
-# The reason seems to be an energy crisis.
-
-# From Stephen Colebourne (2007-02-22):
-# Some IATA info: Haiti won't be having DST in 2007.
-
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Haiti	1983	only	-	May	8	0:00	1:00	D
-Rule	Haiti	1984	1987	-	Apr	lastSun	0:00	1:00	D
-Rule	Haiti	1983	1987	-	Oct	lastSun	0:00	0	S
-# Shanks & Pottenger say AT is 2:00, but IATA SSIM (1991/1997) says 1:00s.
-# Go with IATA.
-Rule	Haiti	1988	1997	-	Apr	Sun>=1	1:00s	1:00	D
-Rule	Haiti	1988	1997	-	Oct	lastSun	1:00s	0	S
-Rule	Haiti	2005	2006	-	Apr	Sun>=1	0:00	1:00	D
-Rule	Haiti	2005	2006	-	Oct	lastSun	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Port-au-Prince -4:49:20 -	LMT	1890
-			-4:49	-	PPMT	1917 Jan 24 12:00 # P-a-P MT
-			-5:00	Haiti	E%sT
-
-# Honduras
-# Shanks & Pottenger say 1921 Jan 1; go with Whitman's more precise Apr 1.
-
-# From Paul Eggert (2006-05-05):
-# worldtimezone.com reports a 2006-05-02 Spanish-language AP article
-# saying Honduras will start using DST midnight Saturday, effective 4
-# months until September.  La Tribuna reported today
-# <http://www.latribuna.hn/99299.html> that Manuel Zelaya, the president
-# of Honduras, refused to back down on this.
-
-# From Jesper Norgaard Welen (2006-08-08):
-# It seems that Honduras has returned from DST to standard time this Monday at
-# 00:00 hours (prolonging Sunday to 25 hours duration).
-# http://www.worldtimezone.com/dst_news/dst_news_honduras04.html
-
-# From Paul Eggert (2006-08-08):
-# Also see Diario El Heraldo, The country returns to standard time (2006-08-08)
-# <http://www.elheraldo.hn/nota.php?nid=54941&sec=12>.
-# It mentions executive decree 18-2006.
-
-# From Steffen Thorsen (2006-08-17):
-# Honduras will observe DST from 2007 to 2009, exact dates are not
-# published, I have located this authoritative source:
-# http://www.presidencia.gob.hn/noticia.aspx?nId=47
-
-# From Steffen Thorsen (2007-03-30):
-# http://www.laprensahn.com/pais_nota.php?id04962=7386
-# So it seems that Honduras will not enter DST this year....
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Hond	1987	1988	-	May	Sun>=1	0:00	1:00	D
-Rule	Hond	1987	1988	-	Sep	lastSun	0:00	0	S
-Rule	Hond	2006	only	-	May	Sun>=1	0:00	1:00	D
-Rule	Hond	2006	only	-	Aug	Mon>=1	0:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Tegucigalpa -5:48:52 -	LMT	1921 Apr
-			-6:00	Hond	C%sT
-#
-# Great Swan I ceded by US to Honduras in 1972
-
-# Jamaica
-
-# From Bob Devine (1988-01-28):
-# Follows US rules.
-
-# From U. S. Naval Observatory (1989-01-19):
-# JAMAICA             5 H  BEHIND UTC
-
-# From Shanks & Pottenger:
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Jamaica	-5:07:12 -	LMT	1890		# Kingston
-			-5:07:12 -	KMT	1912 Feb    # Kingston Mean Time
-			-5:00	-	EST	1974 Apr 28 2:00
-			-5:00	US	E%sT	1984
-			-5:00	-	EST
-
-# Martinique
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Martinique	-4:04:20 -      LMT	1890		# Fort-de-France
-			-4:04:20 -	FFMT	1911 May     # Fort-de-France MT
-			-4:00	-	AST	1980 Apr  6
-			-4:00	1:00	ADT	1980 Sep 28
-			-4:00	-	AST
-
-# Montserrat
-# From Paul Eggert (2006-03-22):
-# In 1995 volcanic eruptions forced evacuation of Plymouth, the capital.
-# world.gazetteer.com says Cork Hill is the most populous location now.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Montserrat	-4:08:52 -	LMT	1911 Jul 1 0:01   # Cork Hill
-			-4:00	-	AST
-
-# Nicaragua
-#
-# This uses Shanks & Pottenger for times before 2005.
-#
-# From Steffen Thorsen (2005-04-12):
-# I've got reports from 8 different people that Nicaragua just started
-# DST on Sunday 2005-04-10, in order to save energy because of
-# expensive petroleum.  The exact end date for DST is not yet
-# announced, only "September" but some sites also say "mid-September".
-# Some background information is available on the President's official site:
-# http://www.presidencia.gob.ni/Presidencia/Files_index/Secretaria/Notas%20de%20Prensa/Presidente/2005/ABRIL/Gobierno-de-nicaragua-adelanta-hora-oficial-06abril.htm
-# The Decree, no 23-2005 is available here:
-# http://www.presidencia.gob.ni/buscador_gaceta/BD/DECRETOS/2005/Decreto%2023-2005%20Se%20adelanta%20en%20una%20hora%20en%20todo%20el%20territorio%20nacional%20apartir%20de%20las%2024horas%20del%2009%20de%20Abril.pdf
-#
-# From Paul Eggert (2005-05-01):
-# The decree doesn't say anything about daylight saving, but for now let's
-# assume that it is daylight saving....
-#
-# From Gwillim Law (2005-04-21):
-# The Associated Press story on the time change, which can be found at
-# http://www.lapalmainteractivo.com/guias/content/gen/ap/America_Latina/AMC_GEN_NICARAGUA_HORA.html
-# and elsewhere, says (fifth paragraph, translated from Spanish):  "The last
-# time that a change of clocks was applied to save energy was in the year 2000
-# during the Arnoldo Aleman administration."...
-# The northamerica file says that Nicaragua has been on UTC-6 continuously
-# since December 1998.  I wasn't able to find any details of Nicaraguan time
-# changes in 2000.  Perhaps a note could be added to the northamerica file, to
-# the effect that we have indirect evidence that DST was observed in 2000.
-#
-# From Jesper Norgaard Welen (2005-11-02):
-# Nicaragua left DST the 2005-10-02 at 00:00 (local time).
-# http://www.presidencia.gob.ni/presidencia/files_index/secretaria/comunicados/2005/septiembre/26septiembre-cambio-hora.htm
-# (2005-09-26)
-#
-# From Jesper Norgaard Welen (2006-05-05):
-# http://www.elnuevodiario.com.ni/2006/05/01/nacionales/18410
-# (my informal translation)
-# By order of the president of the republic, Enrique Bolanos, Nicaragua
-# advanced by sixty minutes their official time, yesterday at 2 in the
-# morning, and will stay that way until 30.th. of september.
-#
-# From Jesper Norgaard Welen (2006-09-30):
-# http://www.presidencia.gob.ni/buscador_gaceta/BD/DECRETOS/2006/D-063-2006P-PRN-Cambio-Hora.pdf
-# My informal translation runs:
-# The natural sun time is restored in all the national territory, in that the
-# time is returned one hour at 01:00 am of October 1 of 2006.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Nic	1979	1980	-	Mar	Sun>=16	0:00	1:00	D
-Rule	Nic	1979	1980	-	Jun	Mon>=23	0:00	0	S
-Rule	Nic	2005	only	-	Apr	10	0:00	1:00	D
-Rule	Nic	2005	only	-	Oct	Sun>=1	0:00	0	S
-Rule	Nic	2006	only	-	Apr	30	2:00	1:00	D
-Rule	Nic	2006	only	-	Oct	Sun>=1	1:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Managua	-5:45:08 -	LMT	1890
-			-5:45:12 -	MMT	1934 Jun 23 # Managua Mean Time?
-			-6:00	-	CST	1973 May
-			-5:00	-	EST	1975 Feb 16
-			-6:00	Nic	C%sT	1992 Jan  1 4:00
-			-5:00	-	EST	1992 Sep 24
-			-6:00	-	CST	1993
-			-5:00	-	EST	1997
-			-6:00	Nic	C%sT
-
-# Panama
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Panama	-5:18:08 -	LMT	1890
-			-5:19:36 -	CMT	1908 Apr 22   # Colon Mean Time
-			-5:00	-	EST
-
-# Puerto Rico
-# There are too many San Juans elsewhere, so we'll use `Puerto_Rico'.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Puerto_Rico -4:24:25 -	LMT	1899 Mar 28 12:00    # San Juan
-			-4:00	-	AST	1942 May  3
-			-4:00	US	A%sT	1946
-			-4:00	-	AST
-
-# St Kitts-Nevis
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/St_Kitts	-4:10:52 -	LMT	1912 Mar 2	# Basseterre
-			-4:00	-	AST
-
-# St Lucia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/St_Lucia	-4:04:00 -	LMT	1890		# Castries
-			-4:04:00 -	CMT	1912	    # Castries Mean Time
-			-4:00	-	AST
-
-# St Pierre and Miquelon
-# There are too many St Pierres elsewhere, so we'll use `Miquelon'.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Miquelon	-3:44:40 -	LMT	1911 May 15	# St Pierre
-			-4:00	-	AST	1980 May
-			-3:00	-	PMST	1987 # Pierre & Miquelon Time
-			-3:00	Canada	PM%sT
-
-# St Vincent and the Grenadines
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/St_Vincent	-4:04:56 -	LMT	1890		# Kingstown
-			-4:04:56 -	KMT	1912	   # Kingstown Mean Time
-			-4:00	-	AST
-
-# Turks and Caicos
-#
-# From Chris Dunn in
-# <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=415007>
-# (2007-03-15): In the Turks & Caicos Islands (America/Grand_Turk) the
-# daylight saving dates for time changes have been adjusted to match
-# the recent U.S. change of dates.
-#
-# From Brian Inglis (2007-04-28):
-# http://www.turksandcaicos.tc/calendar/index.htm [2007-04-26]
-# there is an entry for Nov 4 "Daylight Savings Time Ends 2007" and three
-# rows before that there is an out of date entry for Oct:
-# "Eastern Standard Times Begins 2007
-# Clocks are set back one hour at 2:00 a.m. local Daylight Saving Time"
-# indicating that the normal ET rules are followed.
-#
-# From Paul Eggert (2006-05-01):
-# Shanks & Pottenger say they use US DST rules, but IATA SSIM (1991/1998)
-# says they switch at midnight.  Go with Shanks & Pottenger.
-#
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	TC	1979	1986	-	Apr	lastSun	2:00	1:00	D
-Rule	TC	1979	2006	-	Oct	lastSun	2:00	0	S
-Rule	TC	1987	2006	-	Apr	Sun>=1	2:00	1:00	D
-Rule	TC	2007	max	-	Mar	Sun>=8	2:00	1:00	D
-Rule	TC	2007	max	-	Nov	Sun>=1	2:00	0	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Grand_Turk	-4:44:32 -	LMT	1890
-			-5:07:12 -	KMT	1912 Feb    # Kingston Mean Time
-			-5:00	TC	E%sT
-
-# British Virgin Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Tortola	-4:18:28 -	LMT	1911 Jul    # Road Town
-			-4:00	-	AST
-
-# Virgin Is
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/St_Thomas	-4:19:44 -	LMT	1911 Jul    # Charlotte Amalie
-			-4:00	-	AST
diff --git a/tools/zoneinfo/tzdata2008h/pacificnew b/tools/zoneinfo/tzdata2008h/pacificnew
deleted file mode 100644
index 667940b..0000000
--- a/tools/zoneinfo/tzdata2008h/pacificnew
+++ /dev/null
@@ -1,26 +0,0 @@
-# @(#)pacificnew	8.1
-
-# From Arthur David Olson (1989-04-05):
-# On 1989-04-05, the U. S. House of Representatives passed (238-154) a bill
-# establishing "Pacific Presidential Election Time"; it was not acted on
-# by the Senate or signed into law by the President.
-# You might want to change the "PE" (Presidential Election) below to
-# "Q" (Quadrennial) to maintain three-character zone abbreviations.
-# If you're really conservative, you might want to change it to "D".
-# Avoid "L" (Leap Year), which won't be true in 2100.
-
-# If Presidential Election Time is ever established, replace "XXXX" below
-# with the year the law takes effect and uncomment the "##" lines.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-## Rule	Twilite	XXXX	max	-	Apr	Sun>=1	2:00	1:00	D
-## Rule	Twilite	XXXX	max	uspres	Oct	lastSun	2:00	1:00	PE
-## Rule	Twilite	XXXX	max	uspres	Nov	Sun>=7	2:00	0	S
-## Rule	Twilite	XXXX	max	nonpres	Oct	lastSun	2:00	0	S
-
-# Zone	NAME			GMTOFF	RULES/SAVE	FORMAT	[UNTIL]
-## Zone	America/Los_Angeles-PET	-8:00	US		P%sT	XXXX
-##				-8:00	Twilite		P%sT
-
-# For now...
-Link	America/Los_Angeles	US/Pacific-New	##
diff --git a/tools/zoneinfo/tzdata2008h/solar87 b/tools/zoneinfo/tzdata2008h/solar87
deleted file mode 100644
index 7183932..0000000
--- a/tools/zoneinfo/tzdata2008h/solar87
+++ /dev/null
@@ -1,388 +0,0 @@
-# @(#)solar87	8.1
-
-# So much for footnotes about Saudi Arabia.
-# Apparent noon times below are for Riyadh; your mileage will vary.
-# Times were computed using formulas in the U.S. Naval Observatory's
-# Almanac for Computers 1987; the formulas "will give EqT to an accuracy of
-# [plus or minus two] seconds during the current year."
-#
-# Rounding to the nearest five seconds results in fewer than
-# 256 different "time types"--a limit that's faced because time types are
-# stored on disk as unsigned chars.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	sol87	1987	only	-	Jan	1	12:03:20s -0:03:20 -
-Rule	sol87	1987	only	-	Jan	2	12:03:50s -0:03:50 -
-Rule	sol87	1987	only	-	Jan	3	12:04:15s -0:04:15 -
-Rule	sol87	1987	only	-	Jan	4	12:04:45s -0:04:45 -
-Rule	sol87	1987	only	-	Jan	5	12:05:10s -0:05:10 -
-Rule	sol87	1987	only	-	Jan	6	12:05:40s -0:05:40 -
-Rule	sol87	1987	only	-	Jan	7	12:06:05s -0:06:05 -
-Rule	sol87	1987	only	-	Jan	8	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Jan	9	12:06:55s -0:06:55 -
-Rule	sol87	1987	only	-	Jan	10	12:07:20s -0:07:20 -
-Rule	sol87	1987	only	-	Jan	11	12:07:45s -0:07:45 -
-Rule	sol87	1987	only	-	Jan	12	12:08:10s -0:08:10 -
-Rule	sol87	1987	only	-	Jan	13	12:08:30s -0:08:30 -
-Rule	sol87	1987	only	-	Jan	14	12:08:55s -0:08:55 -
-Rule	sol87	1987	only	-	Jan	15	12:09:15s -0:09:15 -
-Rule	sol87	1987	only	-	Jan	16	12:09:35s -0:09:35 -
-Rule	sol87	1987	only	-	Jan	17	12:09:55s -0:09:55 -
-Rule	sol87	1987	only	-	Jan	18	12:10:15s -0:10:15 -
-Rule	sol87	1987	only	-	Jan	19	12:10:35s -0:10:35 -
-Rule	sol87	1987	only	-	Jan	20	12:10:55s -0:10:55 -
-Rule	sol87	1987	only	-	Jan	21	12:11:10s -0:11:10 -
-Rule	sol87	1987	only	-	Jan	22	12:11:30s -0:11:30 -
-Rule	sol87	1987	only	-	Jan	23	12:11:45s -0:11:45 -
-Rule	sol87	1987	only	-	Jan	24	12:12:00s -0:12:00 -
-Rule	sol87	1987	only	-	Jan	25	12:12:15s -0:12:15 -
-Rule	sol87	1987	only	-	Jan	26	12:12:30s -0:12:30 -
-Rule	sol87	1987	only	-	Jan	27	12:12:40s -0:12:40 -
-Rule	sol87	1987	only	-	Jan	28	12:12:55s -0:12:55 -
-Rule	sol87	1987	only	-	Jan	29	12:13:05s -0:13:05 -
-Rule	sol87	1987	only	-	Jan	30	12:13:15s -0:13:15 -
-Rule	sol87	1987	only	-	Jan	31	12:13:25s -0:13:25 -
-Rule	sol87	1987	only	-	Feb	1	12:13:35s -0:13:35 -
-Rule	sol87	1987	only	-	Feb	2	12:13:40s -0:13:40 -
-Rule	sol87	1987	only	-	Feb	3	12:13:50s -0:13:50 -
-Rule	sol87	1987	only	-	Feb	4	12:13:55s -0:13:55 -
-Rule	sol87	1987	only	-	Feb	5	12:14:00s -0:14:00 -
-Rule	sol87	1987	only	-	Feb	6	12:14:05s -0:14:05 -
-Rule	sol87	1987	only	-	Feb	7	12:14:10s -0:14:10 -
-Rule	sol87	1987	only	-	Feb	8	12:14:10s -0:14:10 -
-Rule	sol87	1987	only	-	Feb	9	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	10	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	11	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	12	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	13	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	14	12:14:15s -0:14:15 -
-Rule	sol87	1987	only	-	Feb	15	12:14:10s -0:14:10 -
-Rule	sol87	1987	only	-	Feb	16	12:14:10s -0:14:10 -
-Rule	sol87	1987	only	-	Feb	17	12:14:05s -0:14:05 -
-Rule	sol87	1987	only	-	Feb	18	12:14:00s -0:14:00 -
-Rule	sol87	1987	only	-	Feb	19	12:13:55s -0:13:55 -
-Rule	sol87	1987	only	-	Feb	20	12:13:50s -0:13:50 -
-Rule	sol87	1987	only	-	Feb	21	12:13:45s -0:13:45 -
-Rule	sol87	1987	only	-	Feb	22	12:13:35s -0:13:35 -
-Rule	sol87	1987	only	-	Feb	23	12:13:30s -0:13:30 -
-Rule	sol87	1987	only	-	Feb	24	12:13:20s -0:13:20 -
-Rule	sol87	1987	only	-	Feb	25	12:13:10s -0:13:10 -
-Rule	sol87	1987	only	-	Feb	26	12:13:00s -0:13:00 -
-Rule	sol87	1987	only	-	Feb	27	12:12:50s -0:12:50 -
-Rule	sol87	1987	only	-	Feb	28	12:12:40s -0:12:40 -
-Rule	sol87	1987	only	-	Mar	1	12:12:30s -0:12:30 -
-Rule	sol87	1987	only	-	Mar	2	12:12:20s -0:12:20 -
-Rule	sol87	1987	only	-	Mar	3	12:12:05s -0:12:05 -
-Rule	sol87	1987	only	-	Mar	4	12:11:55s -0:11:55 -
-Rule	sol87	1987	only	-	Mar	5	12:11:40s -0:11:40 -
-Rule	sol87	1987	only	-	Mar	6	12:11:25s -0:11:25 -
-Rule	sol87	1987	only	-	Mar	7	12:11:15s -0:11:15 -
-Rule	sol87	1987	only	-	Mar	8	12:11:00s -0:11:00 -
-Rule	sol87	1987	only	-	Mar	9	12:10:45s -0:10:45 -
-Rule	sol87	1987	only	-	Mar	10	12:10:30s -0:10:30 -
-Rule	sol87	1987	only	-	Mar	11	12:10:15s -0:10:15 -
-Rule	sol87	1987	only	-	Mar	12	12:09:55s -0:09:55 -
-Rule	sol87	1987	only	-	Mar	13	12:09:40s -0:09:40 -
-Rule	sol87	1987	only	-	Mar	14	12:09:25s -0:09:25 -
-Rule	sol87	1987	only	-	Mar	15	12:09:10s -0:09:10 -
-Rule	sol87	1987	only	-	Mar	16	12:08:50s -0:08:50 -
-Rule	sol87	1987	only	-	Mar	17	12:08:35s -0:08:35 -
-Rule	sol87	1987	only	-	Mar	18	12:08:15s -0:08:15 -
-Rule	sol87	1987	only	-	Mar	19	12:08:00s -0:08:00 -
-Rule	sol87	1987	only	-	Mar	20	12:07:40s -0:07:40 -
-Rule	sol87	1987	only	-	Mar	21	12:07:25s -0:07:25 -
-Rule	sol87	1987	only	-	Mar	22	12:07:05s -0:07:05 -
-Rule	sol87	1987	only	-	Mar	23	12:06:50s -0:06:50 -
-Rule	sol87	1987	only	-	Mar	24	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Mar	25	12:06:10s -0:06:10 -
-Rule	sol87	1987	only	-	Mar	26	12:05:55s -0:05:55 -
-Rule	sol87	1987	only	-	Mar	27	12:05:35s -0:05:35 -
-Rule	sol87	1987	only	-	Mar	28	12:05:15s -0:05:15 -
-Rule	sol87	1987	only	-	Mar	29	12:05:00s -0:05:00 -
-Rule	sol87	1987	only	-	Mar	30	12:04:40s -0:04:40 -
-Rule	sol87	1987	only	-	Mar	31	12:04:25s -0:04:25 -
-Rule	sol87	1987	only	-	Apr	1	12:04:05s -0:04:05 -
-Rule	sol87	1987	only	-	Apr	2	12:03:45s -0:03:45 -
-Rule	sol87	1987	only	-	Apr	3	12:03:30s -0:03:30 -
-Rule	sol87	1987	only	-	Apr	4	12:03:10s -0:03:10 -
-Rule	sol87	1987	only	-	Apr	5	12:02:55s -0:02:55 -
-Rule	sol87	1987	only	-	Apr	6	12:02:35s -0:02:35 -
-Rule	sol87	1987	only	-	Apr	7	12:02:20s -0:02:20 -
-Rule	sol87	1987	only	-	Apr	8	12:02:05s -0:02:05 -
-Rule	sol87	1987	only	-	Apr	9	12:01:45s -0:01:45 -
-Rule	sol87	1987	only	-	Apr	10	12:01:30s -0:01:30 -
-Rule	sol87	1987	only	-	Apr	11	12:01:15s -0:01:15 -
-Rule	sol87	1987	only	-	Apr	12	12:00:55s -0:00:55 -
-Rule	sol87	1987	only	-	Apr	13	12:00:40s -0:00:40 -
-Rule	sol87	1987	only	-	Apr	14	12:00:25s -0:00:25 -
-Rule	sol87	1987	only	-	Apr	15	12:00:10s -0:00:10 -
-Rule	sol87	1987	only	-	Apr	16	11:59:55s 0:00:05 -
-Rule	sol87	1987	only	-	Apr	17	11:59:45s 0:00:15 -
-Rule	sol87	1987	only	-	Apr	18	11:59:30s 0:00:30 -
-Rule	sol87	1987	only	-	Apr	19	11:59:15s 0:00:45 -
-Rule	sol87	1987	only	-	Apr	20	11:59:05s 0:00:55 -
-Rule	sol87	1987	only	-	Apr	21	11:58:50s 0:01:10 -
-Rule	sol87	1987	only	-	Apr	22	11:58:40s 0:01:20 -
-Rule	sol87	1987	only	-	Apr	23	11:58:25s 0:01:35 -
-Rule	sol87	1987	only	-	Apr	24	11:58:15s 0:01:45 -
-Rule	sol87	1987	only	-	Apr	25	11:58:05s 0:01:55 -
-Rule	sol87	1987	only	-	Apr	26	11:57:55s 0:02:05 -
-Rule	sol87	1987	only	-	Apr	27	11:57:45s 0:02:15 -
-Rule	sol87	1987	only	-	Apr	28	11:57:35s 0:02:25 -
-Rule	sol87	1987	only	-	Apr	29	11:57:25s 0:02:35 -
-Rule	sol87	1987	only	-	Apr	30	11:57:15s 0:02:45 -
-Rule	sol87	1987	only	-	May	1	11:57:10s 0:02:50 -
-Rule	sol87	1987	only	-	May	2	11:57:00s 0:03:00 -
-Rule	sol87	1987	only	-	May	3	11:56:55s 0:03:05 -
-Rule	sol87	1987	only	-	May	4	11:56:50s 0:03:10 -
-Rule	sol87	1987	only	-	May	5	11:56:45s 0:03:15 -
-Rule	sol87	1987	only	-	May	6	11:56:40s 0:03:20 -
-Rule	sol87	1987	only	-	May	7	11:56:35s 0:03:25 -
-Rule	sol87	1987	only	-	May	8	11:56:30s 0:03:30 -
-Rule	sol87	1987	only	-	May	9	11:56:25s 0:03:35 -
-Rule	sol87	1987	only	-	May	10	11:56:25s 0:03:35 -
-Rule	sol87	1987	only	-	May	11	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	12	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	13	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	14	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	15	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	16	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	17	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	18	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	May	19	11:56:25s 0:03:35 -
-Rule	sol87	1987	only	-	May	20	11:56:25s 0:03:35 -
-Rule	sol87	1987	only	-	May	21	11:56:30s 0:03:30 -
-Rule	sol87	1987	only	-	May	22	11:56:35s 0:03:25 -
-Rule	sol87	1987	only	-	May	23	11:56:40s 0:03:20 -
-Rule	sol87	1987	only	-	May	24	11:56:45s 0:03:15 -
-Rule	sol87	1987	only	-	May	25	11:56:50s 0:03:10 -
-Rule	sol87	1987	only	-	May	26	11:56:55s 0:03:05 -
-Rule	sol87	1987	only	-	May	27	11:57:00s 0:03:00 -
-Rule	sol87	1987	only	-	May	28	11:57:10s 0:02:50 -
-Rule	sol87	1987	only	-	May	29	11:57:15s 0:02:45 -
-Rule	sol87	1987	only	-	May	30	11:57:25s 0:02:35 -
-Rule	sol87	1987	only	-	May	31	11:57:30s 0:02:30 -
-Rule	sol87	1987	only	-	Jun	1	11:57:40s 0:02:20 -
-Rule	sol87	1987	only	-	Jun	2	11:57:50s 0:02:10 -
-Rule	sol87	1987	only	-	Jun	3	11:58:00s 0:02:00 -
-Rule	sol87	1987	only	-	Jun	4	11:58:10s 0:01:50 -
-Rule	sol87	1987	only	-	Jun	5	11:58:20s 0:01:40 -
-Rule	sol87	1987	only	-	Jun	6	11:58:30s 0:01:30 -
-Rule	sol87	1987	only	-	Jun	7	11:58:40s 0:01:20 -
-Rule	sol87	1987	only	-	Jun	8	11:58:50s 0:01:10 -
-Rule	sol87	1987	only	-	Jun	9	11:59:05s 0:00:55 -
-Rule	sol87	1987	only	-	Jun	10	11:59:15s 0:00:45 -
-Rule	sol87	1987	only	-	Jun	11	11:59:30s 0:00:30 -
-Rule	sol87	1987	only	-	Jun	12	11:59:40s 0:00:20 -
-Rule	sol87	1987	only	-	Jun	13	11:59:50s 0:00:10 -
-Rule	sol87	1987	only	-	Jun	14	12:00:05s -0:00:05 -
-Rule	sol87	1987	only	-	Jun	15	12:00:15s -0:00:15 -
-Rule	sol87	1987	only	-	Jun	16	12:00:30s -0:00:30 -
-Rule	sol87	1987	only	-	Jun	17	12:00:45s -0:00:45 -
-Rule	sol87	1987	only	-	Jun	18	12:00:55s -0:00:55 -
-Rule	sol87	1987	only	-	Jun	19	12:01:10s -0:01:10 -
-Rule	sol87	1987	only	-	Jun	20	12:01:20s -0:01:20 -
-Rule	sol87	1987	only	-	Jun	21	12:01:35s -0:01:35 -
-Rule	sol87	1987	only	-	Jun	22	12:01:50s -0:01:50 -
-Rule	sol87	1987	only	-	Jun	23	12:02:00s -0:02:00 -
-Rule	sol87	1987	only	-	Jun	24	12:02:15s -0:02:15 -
-Rule	sol87	1987	only	-	Jun	25	12:02:25s -0:02:25 -
-Rule	sol87	1987	only	-	Jun	26	12:02:40s -0:02:40 -
-Rule	sol87	1987	only	-	Jun	27	12:02:50s -0:02:50 -
-Rule	sol87	1987	only	-	Jun	28	12:03:05s -0:03:05 -
-Rule	sol87	1987	only	-	Jun	29	12:03:15s -0:03:15 -
-Rule	sol87	1987	only	-	Jun	30	12:03:30s -0:03:30 -
-Rule	sol87	1987	only	-	Jul	1	12:03:40s -0:03:40 -
-Rule	sol87	1987	only	-	Jul	2	12:03:50s -0:03:50 -
-Rule	sol87	1987	only	-	Jul	3	12:04:05s -0:04:05 -
-Rule	sol87	1987	only	-	Jul	4	12:04:15s -0:04:15 -
-Rule	sol87	1987	only	-	Jul	5	12:04:25s -0:04:25 -
-Rule	sol87	1987	only	-	Jul	6	12:04:35s -0:04:35 -
-Rule	sol87	1987	only	-	Jul	7	12:04:45s -0:04:45 -
-Rule	sol87	1987	only	-	Jul	8	12:04:55s -0:04:55 -
-Rule	sol87	1987	only	-	Jul	9	12:05:05s -0:05:05 -
-Rule	sol87	1987	only	-	Jul	10	12:05:15s -0:05:15 -
-Rule	sol87	1987	only	-	Jul	11	12:05:20s -0:05:20 -
-Rule	sol87	1987	only	-	Jul	12	12:05:30s -0:05:30 -
-Rule	sol87	1987	only	-	Jul	13	12:05:40s -0:05:40 -
-Rule	sol87	1987	only	-	Jul	14	12:05:45s -0:05:45 -
-Rule	sol87	1987	only	-	Jul	15	12:05:50s -0:05:50 -
-Rule	sol87	1987	only	-	Jul	16	12:06:00s -0:06:00 -
-Rule	sol87	1987	only	-	Jul	17	12:06:05s -0:06:05 -
-Rule	sol87	1987	only	-	Jul	18	12:06:10s -0:06:10 -
-Rule	sol87	1987	only	-	Jul	19	12:06:15s -0:06:15 -
-Rule	sol87	1987	only	-	Jul	20	12:06:15s -0:06:15 -
-Rule	sol87	1987	only	-	Jul	21	12:06:20s -0:06:20 -
-Rule	sol87	1987	only	-	Jul	22	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Jul	23	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Jul	24	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Jul	25	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Jul	26	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Jul	27	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Jul	28	12:06:30s -0:06:30 -
-Rule	sol87	1987	only	-	Jul	29	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Jul	30	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Jul	31	12:06:25s -0:06:25 -
-Rule	sol87	1987	only	-	Aug	1	12:06:20s -0:06:20 -
-Rule	sol87	1987	only	-	Aug	2	12:06:15s -0:06:15 -
-Rule	sol87	1987	only	-	Aug	3	12:06:10s -0:06:10 -
-Rule	sol87	1987	only	-	Aug	4	12:06:05s -0:06:05 -
-Rule	sol87	1987	only	-	Aug	5	12:06:00s -0:06:00 -
-Rule	sol87	1987	only	-	Aug	6	12:05:55s -0:05:55 -
-Rule	sol87	1987	only	-	Aug	7	12:05:50s -0:05:50 -
-Rule	sol87	1987	only	-	Aug	8	12:05:40s -0:05:40 -
-Rule	sol87	1987	only	-	Aug	9	12:05:35s -0:05:35 -
-Rule	sol87	1987	only	-	Aug	10	12:05:25s -0:05:25 -
-Rule	sol87	1987	only	-	Aug	11	12:05:15s -0:05:15 -
-Rule	sol87	1987	only	-	Aug	12	12:05:05s -0:05:05 -
-Rule	sol87	1987	only	-	Aug	13	12:04:55s -0:04:55 -
-Rule	sol87	1987	only	-	Aug	14	12:04:45s -0:04:45 -
-Rule	sol87	1987	only	-	Aug	15	12:04:35s -0:04:35 -
-Rule	sol87	1987	only	-	Aug	16	12:04:25s -0:04:25 -
-Rule	sol87	1987	only	-	Aug	17	12:04:10s -0:04:10 -
-Rule	sol87	1987	only	-	Aug	18	12:04:00s -0:04:00 -
-Rule	sol87	1987	only	-	Aug	19	12:03:45s -0:03:45 -
-Rule	sol87	1987	only	-	Aug	20	12:03:30s -0:03:30 -
-Rule	sol87	1987	only	-	Aug	21	12:03:15s -0:03:15 -
-Rule	sol87	1987	only	-	Aug	22	12:03:00s -0:03:00 -
-Rule	sol87	1987	only	-	Aug	23	12:02:45s -0:02:45 -
-Rule	sol87	1987	only	-	Aug	24	12:02:30s -0:02:30 -
-Rule	sol87	1987	only	-	Aug	25	12:02:15s -0:02:15 -
-Rule	sol87	1987	only	-	Aug	26	12:02:00s -0:02:00 -
-Rule	sol87	1987	only	-	Aug	27	12:01:40s -0:01:40 -
-Rule	sol87	1987	only	-	Aug	28	12:01:25s -0:01:25 -
-Rule	sol87	1987	only	-	Aug	29	12:01:05s -0:01:05 -
-Rule	sol87	1987	only	-	Aug	30	12:00:50s -0:00:50 -
-Rule	sol87	1987	only	-	Aug	31	12:00:30s -0:00:30 -
-Rule	sol87	1987	only	-	Sep	1	12:00:10s -0:00:10 -
-Rule	sol87	1987	only	-	Sep	2	11:59:50s 0:00:10 -
-Rule	sol87	1987	only	-	Sep	3	11:59:35s 0:00:25 -
-Rule	sol87	1987	only	-	Sep	4	11:59:15s 0:00:45 -
-Rule	sol87	1987	only	-	Sep	5	11:58:55s 0:01:05 -
-Rule	sol87	1987	only	-	Sep	6	11:58:35s 0:01:25 -
-Rule	sol87	1987	only	-	Sep	7	11:58:15s 0:01:45 -
-Rule	sol87	1987	only	-	Sep	8	11:57:55s 0:02:05 -
-Rule	sol87	1987	only	-	Sep	9	11:57:30s 0:02:30 -
-Rule	sol87	1987	only	-	Sep	10	11:57:10s 0:02:50 -
-Rule	sol87	1987	only	-	Sep	11	11:56:50s 0:03:10 -
-Rule	sol87	1987	only	-	Sep	12	11:56:30s 0:03:30 -
-Rule	sol87	1987	only	-	Sep	13	11:56:10s 0:03:50 -
-Rule	sol87	1987	only	-	Sep	14	11:55:45s 0:04:15 -
-Rule	sol87	1987	only	-	Sep	15	11:55:25s 0:04:35 -
-Rule	sol87	1987	only	-	Sep	16	11:55:05s 0:04:55 -
-Rule	sol87	1987	only	-	Sep	17	11:54:45s 0:05:15 -
-Rule	sol87	1987	only	-	Sep	18	11:54:20s 0:05:40 -
-Rule	sol87	1987	only	-	Sep	19	11:54:00s 0:06:00 -
-Rule	sol87	1987	only	-	Sep	20	11:53:40s 0:06:20 -
-Rule	sol87	1987	only	-	Sep	21	11:53:15s 0:06:45 -
-Rule	sol87	1987	only	-	Sep	22	11:52:55s 0:07:05 -
-Rule	sol87	1987	only	-	Sep	23	11:52:35s 0:07:25 -
-Rule	sol87	1987	only	-	Sep	24	11:52:15s 0:07:45 -
-Rule	sol87	1987	only	-	Sep	25	11:51:55s 0:08:05 -
-Rule	sol87	1987	only	-	Sep	26	11:51:35s 0:08:25 -
-Rule	sol87	1987	only	-	Sep	27	11:51:10s 0:08:50 -
-Rule	sol87	1987	only	-	Sep	28	11:50:50s 0:09:10 -
-Rule	sol87	1987	only	-	Sep	29	11:50:30s 0:09:30 -
-Rule	sol87	1987	only	-	Sep	30	11:50:10s 0:09:50 -
-Rule	sol87	1987	only	-	Oct	1	11:49:50s 0:10:10 -
-Rule	sol87	1987	only	-	Oct	2	11:49:35s 0:10:25 -
-Rule	sol87	1987	only	-	Oct	3	11:49:15s 0:10:45 -
-Rule	sol87	1987	only	-	Oct	4	11:48:55s 0:11:05 -
-Rule	sol87	1987	only	-	Oct	5	11:48:35s 0:11:25 -
-Rule	sol87	1987	only	-	Oct	6	11:48:20s 0:11:40 -
-Rule	sol87	1987	only	-	Oct	7	11:48:00s 0:12:00 -
-Rule	sol87	1987	only	-	Oct	8	11:47:45s 0:12:15 -
-Rule	sol87	1987	only	-	Oct	9	11:47:25s 0:12:35 -
-Rule	sol87	1987	only	-	Oct	10	11:47:10s 0:12:50 -
-Rule	sol87	1987	only	-	Oct	11	11:46:55s 0:13:05 -
-Rule	sol87	1987	only	-	Oct	12	11:46:40s 0:13:20 -
-Rule	sol87	1987	only	-	Oct	13	11:46:25s 0:13:35 -
-Rule	sol87	1987	only	-	Oct	14	11:46:10s 0:13:50 -
-Rule	sol87	1987	only	-	Oct	15	11:45:55s 0:14:05 -
-Rule	sol87	1987	only	-	Oct	16	11:45:45s 0:14:15 -
-Rule	sol87	1987	only	-	Oct	17	11:45:30s 0:14:30 -
-Rule	sol87	1987	only	-	Oct	18	11:45:20s 0:14:40 -
-Rule	sol87	1987	only	-	Oct	19	11:45:05s 0:14:55 -
-Rule	sol87	1987	only	-	Oct	20	11:44:55s 0:15:05 -
-Rule	sol87	1987	only	-	Oct	21	11:44:45s 0:15:15 -
-Rule	sol87	1987	only	-	Oct	22	11:44:35s 0:15:25 -
-Rule	sol87	1987	only	-	Oct	23	11:44:25s 0:15:35 -
-Rule	sol87	1987	only	-	Oct	24	11:44:20s 0:15:40 -
-Rule	sol87	1987	only	-	Oct	25	11:44:10s 0:15:50 -
-Rule	sol87	1987	only	-	Oct	26	11:44:05s 0:15:55 -
-Rule	sol87	1987	only	-	Oct	27	11:43:55s 0:16:05 -
-Rule	sol87	1987	only	-	Oct	28	11:43:50s 0:16:10 -
-Rule	sol87	1987	only	-	Oct	29	11:43:45s 0:16:15 -
-Rule	sol87	1987	only	-	Oct	30	11:43:45s 0:16:15 -
-Rule	sol87	1987	only	-	Oct	31	11:43:40s 0:16:20 -
-Rule	sol87	1987	only	-	Nov	1	11:43:40s 0:16:20 -
-Rule	sol87	1987	only	-	Nov	2	11:43:35s 0:16:25 -
-Rule	sol87	1987	only	-	Nov	3	11:43:35s 0:16:25 -
-Rule	sol87	1987	only	-	Nov	4	11:43:35s 0:16:25 -
-Rule	sol87	1987	only	-	Nov	5	11:43:35s 0:16:25 -
-Rule	sol87	1987	only	-	Nov	6	11:43:40s 0:16:20 -
-Rule	sol87	1987	only	-	Nov	7	11:43:40s 0:16:20 -
-Rule	sol87	1987	only	-	Nov	8	11:43:45s 0:16:15 -
-Rule	sol87	1987	only	-	Nov	9	11:43:50s 0:16:10 -
-Rule	sol87	1987	only	-	Nov	10	11:43:55s 0:16:05 -
-Rule	sol87	1987	only	-	Nov	11	11:44:00s 0:16:00 -
-Rule	sol87	1987	only	-	Nov	12	11:44:05s 0:15:55 -
-Rule	sol87	1987	only	-	Nov	13	11:44:15s 0:15:45 -
-Rule	sol87	1987	only	-	Nov	14	11:44:20s 0:15:40 -
-Rule	sol87	1987	only	-	Nov	15	11:44:30s 0:15:30 -
-Rule	sol87	1987	only	-	Nov	16	11:44:40s 0:15:20 -
-Rule	sol87	1987	only	-	Nov	17	11:44:50s 0:15:10 -
-Rule	sol87	1987	only	-	Nov	18	11:45:05s 0:14:55 -
-Rule	sol87	1987	only	-	Nov	19	11:45:15s 0:14:45 -
-Rule	sol87	1987	only	-	Nov	20	11:45:30s 0:14:30 -
-Rule	sol87	1987	only	-	Nov	21	11:45:45s 0:14:15 -
-Rule	sol87	1987	only	-	Nov	22	11:46:00s 0:14:00 -
-Rule	sol87	1987	only	-	Nov	23	11:46:15s 0:13:45 -
-Rule	sol87	1987	only	-	Nov	24	11:46:30s 0:13:30 -
-Rule	sol87	1987	only	-	Nov	25	11:46:50s 0:13:10 -
-Rule	sol87	1987	only	-	Nov	26	11:47:10s 0:12:50 -
-Rule	sol87	1987	only	-	Nov	27	11:47:25s 0:12:35 -
-Rule	sol87	1987	only	-	Nov	28	11:47:45s 0:12:15 -
-Rule	sol87	1987	only	-	Nov	29	11:48:05s 0:11:55 -
-Rule	sol87	1987	only	-	Nov	30	11:48:30s 0:11:30 -
-Rule	sol87	1987	only	-	Dec	1	11:48:50s 0:11:10 -
-Rule	sol87	1987	only	-	Dec	2	11:49:10s 0:10:50 -
-Rule	sol87	1987	only	-	Dec	3	11:49:35s 0:10:25 -
-Rule	sol87	1987	only	-	Dec	4	11:50:00s 0:10:00 -
-Rule	sol87	1987	only	-	Dec	5	11:50:25s 0:09:35 -
-Rule	sol87	1987	only	-	Dec	6	11:50:50s 0:09:10 -
-Rule	sol87	1987	only	-	Dec	7	11:51:15s 0:08:45 -
-Rule	sol87	1987	only	-	Dec	8	11:51:40s 0:08:20 -
-Rule	sol87	1987	only	-	Dec	9	11:52:05s 0:07:55 -
-Rule	sol87	1987	only	-	Dec	10	11:52:30s 0:07:30 -
-Rule	sol87	1987	only	-	Dec	11	11:53:00s 0:07:00 -
-Rule	sol87	1987	only	-	Dec	12	11:53:25s 0:06:35 -
-Rule	sol87	1987	only	-	Dec	13	11:53:55s 0:06:05 -
-Rule	sol87	1987	only	-	Dec	14	11:54:25s 0:05:35 -
-Rule	sol87	1987	only	-	Dec	15	11:54:50s 0:05:10 -
-Rule	sol87	1987	only	-	Dec	16	11:55:20s 0:04:40 -
-Rule	sol87	1987	only	-	Dec	17	11:55:50s 0:04:10 -
-Rule	sol87	1987	only	-	Dec	18	11:56:20s 0:03:40 -
-Rule	sol87	1987	only	-	Dec	19	11:56:50s 0:03:10 -
-Rule	sol87	1987	only	-	Dec	20	11:57:20s 0:02:40 -
-Rule	sol87	1987	only	-	Dec	21	11:57:50s 0:02:10 -
-Rule	sol87	1987	only	-	Dec	22	11:58:20s 0:01:40 -
-Rule	sol87	1987	only	-	Dec	23	11:58:50s 0:01:10 -
-Rule	sol87	1987	only	-	Dec	24	11:59:20s 0:00:40 -
-Rule	sol87	1987	only	-	Dec	25	11:59:50s 0:00:10 -
-Rule	sol87	1987	only	-	Dec	26	12:00:20s -0:00:20 -
-Rule	sol87	1987	only	-	Dec	27	12:00:45s -0:00:45 -
-Rule	sol87	1987	only	-	Dec	28	12:01:15s -0:01:15 -
-Rule	sol87	1987	only	-	Dec	29	12:01:45s -0:01:45 -
-Rule	sol87	1987	only	-	Dec	30	12:02:15s -0:02:15 -
-Rule	sol87	1987	only	-	Dec	31	12:02:45s -0:02:45 -
-
-# Riyadh is at about 46 degrees 46 minutes East:  3 hrs, 7 mins, 4 secs
-# Before and after 1987, we'll operate on local mean solar time.
-
-# Zone	NAME		GMTOFF	RULES/SAVE	FORMAT	[UNTIL]
-Zone	Asia/Riyadh87	3:07:04	-		zzz	1987
-			3:07:04	sol87		zzz	1988
-			3:07:04	-		zzz
-# For backward compatibility...
-Link	Asia/Riyadh87	Mideast/Riyadh87
diff --git a/tools/zoneinfo/tzdata2008h/solar88 b/tools/zoneinfo/tzdata2008h/solar88
deleted file mode 100644
index b4cfe8e..0000000
--- a/tools/zoneinfo/tzdata2008h/solar88
+++ /dev/null
@@ -1,388 +0,0 @@
-# @(#)solar88	8.1
-
-# Apparent noon times below are for Riyadh; they're a bit off for other places.
-# Times were computed using formulas in the U.S. Naval Observatory's
-# Almanac for Computers 1988; the formulas "will give EqT to an accuracy of
-# [plus or minus two] seconds during the current year."
-#
-# Rounding to the nearest five seconds results in fewer than
-# 256 different "time types"--a limit that's faced because time types are
-# stored on disk as unsigned chars.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	sol88	1988	only	-	Jan	1	12:03:15s -0:03:15 -
-Rule	sol88	1988	only	-	Jan	2	12:03:40s -0:03:40 -
-Rule	sol88	1988	only	-	Jan	3	12:04:10s -0:04:10 -
-Rule	sol88	1988	only	-	Jan	4	12:04:40s -0:04:40 -
-Rule	sol88	1988	only	-	Jan	5	12:05:05s -0:05:05 -
-Rule	sol88	1988	only	-	Jan	6	12:05:30s -0:05:30 -
-Rule	sol88	1988	only	-	Jan	7	12:06:00s -0:06:00 -
-Rule	sol88	1988	only	-	Jan	8	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jan	9	12:06:50s -0:06:50 -
-Rule	sol88	1988	only	-	Jan	10	12:07:15s -0:07:15 -
-Rule	sol88	1988	only	-	Jan	11	12:07:40s -0:07:40 -
-Rule	sol88	1988	only	-	Jan	12	12:08:05s -0:08:05 -
-Rule	sol88	1988	only	-	Jan	13	12:08:25s -0:08:25 -
-Rule	sol88	1988	only	-	Jan	14	12:08:50s -0:08:50 -
-Rule	sol88	1988	only	-	Jan	15	12:09:10s -0:09:10 -
-Rule	sol88	1988	only	-	Jan	16	12:09:30s -0:09:30 -
-Rule	sol88	1988	only	-	Jan	17	12:09:50s -0:09:50 -
-Rule	sol88	1988	only	-	Jan	18	12:10:10s -0:10:10 -
-Rule	sol88	1988	only	-	Jan	19	12:10:30s -0:10:30 -
-Rule	sol88	1988	only	-	Jan	20	12:10:50s -0:10:50 -
-Rule	sol88	1988	only	-	Jan	21	12:11:05s -0:11:05 -
-Rule	sol88	1988	only	-	Jan	22	12:11:25s -0:11:25 -
-Rule	sol88	1988	only	-	Jan	23	12:11:40s -0:11:40 -
-Rule	sol88	1988	only	-	Jan	24	12:11:55s -0:11:55 -
-Rule	sol88	1988	only	-	Jan	25	12:12:10s -0:12:10 -
-Rule	sol88	1988	only	-	Jan	26	12:12:25s -0:12:25 -
-Rule	sol88	1988	only	-	Jan	27	12:12:40s -0:12:40 -
-Rule	sol88	1988	only	-	Jan	28	12:12:50s -0:12:50 -
-Rule	sol88	1988	only	-	Jan	29	12:13:00s -0:13:00 -
-Rule	sol88	1988	only	-	Jan	30	12:13:10s -0:13:10 -
-Rule	sol88	1988	only	-	Jan	31	12:13:20s -0:13:20 -
-Rule	sol88	1988	only	-	Feb	1	12:13:30s -0:13:30 -
-Rule	sol88	1988	only	-	Feb	2	12:13:40s -0:13:40 -
-Rule	sol88	1988	only	-	Feb	3	12:13:45s -0:13:45 -
-Rule	sol88	1988	only	-	Feb	4	12:13:55s -0:13:55 -
-Rule	sol88	1988	only	-	Feb	5	12:14:00s -0:14:00 -
-Rule	sol88	1988	only	-	Feb	6	12:14:05s -0:14:05 -
-Rule	sol88	1988	only	-	Feb	7	12:14:10s -0:14:10 -
-Rule	sol88	1988	only	-	Feb	8	12:14:10s -0:14:10 -
-Rule	sol88	1988	only	-	Feb	9	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	10	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	11	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	12	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	13	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	14	12:14:15s -0:14:15 -
-Rule	sol88	1988	only	-	Feb	15	12:14:10s -0:14:10 -
-Rule	sol88	1988	only	-	Feb	16	12:14:10s -0:14:10 -
-Rule	sol88	1988	only	-	Feb	17	12:14:05s -0:14:05 -
-Rule	sol88	1988	only	-	Feb	18	12:14:00s -0:14:00 -
-Rule	sol88	1988	only	-	Feb	19	12:13:55s -0:13:55 -
-Rule	sol88	1988	only	-	Feb	20	12:13:50s -0:13:50 -
-Rule	sol88	1988	only	-	Feb	21	12:13:45s -0:13:45 -
-Rule	sol88	1988	only	-	Feb	22	12:13:40s -0:13:40 -
-Rule	sol88	1988	only	-	Feb	23	12:13:30s -0:13:30 -
-Rule	sol88	1988	only	-	Feb	24	12:13:20s -0:13:20 -
-Rule	sol88	1988	only	-	Feb	25	12:13:15s -0:13:15 -
-Rule	sol88	1988	only	-	Feb	26	12:13:05s -0:13:05 -
-Rule	sol88	1988	only	-	Feb	27	12:12:55s -0:12:55 -
-Rule	sol88	1988	only	-	Feb	28	12:12:45s -0:12:45 -
-Rule	sol88	1988	only	-	Feb	29	12:12:30s -0:12:30 -
-Rule	sol88	1988	only	-	Mar	1	12:12:20s -0:12:20 -
-Rule	sol88	1988	only	-	Mar	2	12:12:10s -0:12:10 -
-Rule	sol88	1988	only	-	Mar	3	12:11:55s -0:11:55 -
-Rule	sol88	1988	only	-	Mar	4	12:11:45s -0:11:45 -
-Rule	sol88	1988	only	-	Mar	5	12:11:30s -0:11:30 -
-Rule	sol88	1988	only	-	Mar	6	12:11:15s -0:11:15 -
-Rule	sol88	1988	only	-	Mar	7	12:11:00s -0:11:00 -
-Rule	sol88	1988	only	-	Mar	8	12:10:45s -0:10:45 -
-Rule	sol88	1988	only	-	Mar	9	12:10:30s -0:10:30 -
-Rule	sol88	1988	only	-	Mar	10	12:10:15s -0:10:15 -
-Rule	sol88	1988	only	-	Mar	11	12:10:00s -0:10:00 -
-Rule	sol88	1988	only	-	Mar	12	12:09:45s -0:09:45 -
-Rule	sol88	1988	only	-	Mar	13	12:09:30s -0:09:30 -
-Rule	sol88	1988	only	-	Mar	14	12:09:10s -0:09:10 -
-Rule	sol88	1988	only	-	Mar	15	12:08:55s -0:08:55 -
-Rule	sol88	1988	only	-	Mar	16	12:08:40s -0:08:40 -
-Rule	sol88	1988	only	-	Mar	17	12:08:20s -0:08:20 -
-Rule	sol88	1988	only	-	Mar	18	12:08:05s -0:08:05 -
-Rule	sol88	1988	only	-	Mar	19	12:07:45s -0:07:45 -
-Rule	sol88	1988	only	-	Mar	20	12:07:30s -0:07:30 -
-Rule	sol88	1988	only	-	Mar	21	12:07:10s -0:07:10 -
-Rule	sol88	1988	only	-	Mar	22	12:06:50s -0:06:50 -
-Rule	sol88	1988	only	-	Mar	23	12:06:35s -0:06:35 -
-Rule	sol88	1988	only	-	Mar	24	12:06:15s -0:06:15 -
-Rule	sol88	1988	only	-	Mar	25	12:06:00s -0:06:00 -
-Rule	sol88	1988	only	-	Mar	26	12:05:40s -0:05:40 -
-Rule	sol88	1988	only	-	Mar	27	12:05:20s -0:05:20 -
-Rule	sol88	1988	only	-	Mar	28	12:05:05s -0:05:05 -
-Rule	sol88	1988	only	-	Mar	29	12:04:45s -0:04:45 -
-Rule	sol88	1988	only	-	Mar	30	12:04:25s -0:04:25 -
-Rule	sol88	1988	only	-	Mar	31	12:04:10s -0:04:10 -
-Rule	sol88	1988	only	-	Apr	1	12:03:50s -0:03:50 -
-Rule	sol88	1988	only	-	Apr	2	12:03:35s -0:03:35 -
-Rule	sol88	1988	only	-	Apr	3	12:03:15s -0:03:15 -
-Rule	sol88	1988	only	-	Apr	4	12:03:00s -0:03:00 -
-Rule	sol88	1988	only	-	Apr	5	12:02:40s -0:02:40 -
-Rule	sol88	1988	only	-	Apr	6	12:02:25s -0:02:25 -
-Rule	sol88	1988	only	-	Apr	7	12:02:05s -0:02:05 -
-Rule	sol88	1988	only	-	Apr	8	12:01:50s -0:01:50 -
-Rule	sol88	1988	only	-	Apr	9	12:01:35s -0:01:35 -
-Rule	sol88	1988	only	-	Apr	10	12:01:15s -0:01:15 -
-Rule	sol88	1988	only	-	Apr	11	12:01:00s -0:01:00 -
-Rule	sol88	1988	only	-	Apr	12	12:00:45s -0:00:45 -
-Rule	sol88	1988	only	-	Apr	13	12:00:30s -0:00:30 -
-Rule	sol88	1988	only	-	Apr	14	12:00:15s -0:00:15 -
-Rule	sol88	1988	only	-	Apr	15	12:00:00s 0:00:00 -
-Rule	sol88	1988	only	-	Apr	16	11:59:45s 0:00:15 -
-Rule	sol88	1988	only	-	Apr	17	11:59:30s 0:00:30 -
-Rule	sol88	1988	only	-	Apr	18	11:59:20s 0:00:40 -
-Rule	sol88	1988	only	-	Apr	19	11:59:05s 0:00:55 -
-Rule	sol88	1988	only	-	Apr	20	11:58:55s 0:01:05 -
-Rule	sol88	1988	only	-	Apr	21	11:58:40s 0:01:20 -
-Rule	sol88	1988	only	-	Apr	22	11:58:30s 0:01:30 -
-Rule	sol88	1988	only	-	Apr	23	11:58:15s 0:01:45 -
-Rule	sol88	1988	only	-	Apr	24	11:58:05s 0:01:55 -
-Rule	sol88	1988	only	-	Apr	25	11:57:55s 0:02:05 -
-Rule	sol88	1988	only	-	Apr	26	11:57:45s 0:02:15 -
-Rule	sol88	1988	only	-	Apr	27	11:57:35s 0:02:25 -
-Rule	sol88	1988	only	-	Apr	28	11:57:30s 0:02:30 -
-Rule	sol88	1988	only	-	Apr	29	11:57:20s 0:02:40 -
-Rule	sol88	1988	only	-	Apr	30	11:57:10s 0:02:50 -
-Rule	sol88	1988	only	-	May	1	11:57:05s 0:02:55 -
-Rule	sol88	1988	only	-	May	2	11:56:55s 0:03:05 -
-Rule	sol88	1988	only	-	May	3	11:56:50s 0:03:10 -
-Rule	sol88	1988	only	-	May	4	11:56:45s 0:03:15 -
-Rule	sol88	1988	only	-	May	5	11:56:40s 0:03:20 -
-Rule	sol88	1988	only	-	May	6	11:56:35s 0:03:25 -
-Rule	sol88	1988	only	-	May	7	11:56:30s 0:03:30 -
-Rule	sol88	1988	only	-	May	8	11:56:25s 0:03:35 -
-Rule	sol88	1988	only	-	May	9	11:56:25s 0:03:35 -
-Rule	sol88	1988	only	-	May	10	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	11	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	12	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	13	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	14	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	15	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	16	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	17	11:56:20s 0:03:40 -
-Rule	sol88	1988	only	-	May	18	11:56:25s 0:03:35 -
-Rule	sol88	1988	only	-	May	19	11:56:25s 0:03:35 -
-Rule	sol88	1988	only	-	May	20	11:56:30s 0:03:30 -
-Rule	sol88	1988	only	-	May	21	11:56:35s 0:03:25 -
-Rule	sol88	1988	only	-	May	22	11:56:40s 0:03:20 -
-Rule	sol88	1988	only	-	May	23	11:56:45s 0:03:15 -
-Rule	sol88	1988	only	-	May	24	11:56:50s 0:03:10 -
-Rule	sol88	1988	only	-	May	25	11:56:55s 0:03:05 -
-Rule	sol88	1988	only	-	May	26	11:57:00s 0:03:00 -
-Rule	sol88	1988	only	-	May	27	11:57:05s 0:02:55 -
-Rule	sol88	1988	only	-	May	28	11:57:15s 0:02:45 -
-Rule	sol88	1988	only	-	May	29	11:57:20s 0:02:40 -
-Rule	sol88	1988	only	-	May	30	11:57:30s 0:02:30 -
-Rule	sol88	1988	only	-	May	31	11:57:40s 0:02:20 -
-Rule	sol88	1988	only	-	Jun	1	11:57:50s 0:02:10 -
-Rule	sol88	1988	only	-	Jun	2	11:57:55s 0:02:05 -
-Rule	sol88	1988	only	-	Jun	3	11:58:05s 0:01:55 -
-Rule	sol88	1988	only	-	Jun	4	11:58:15s 0:01:45 -
-Rule	sol88	1988	only	-	Jun	5	11:58:30s 0:01:30 -
-Rule	sol88	1988	only	-	Jun	6	11:58:40s 0:01:20 -
-Rule	sol88	1988	only	-	Jun	7	11:58:50s 0:01:10 -
-Rule	sol88	1988	only	-	Jun	8	11:59:00s 0:01:00 -
-Rule	sol88	1988	only	-	Jun	9	11:59:15s 0:00:45 -
-Rule	sol88	1988	only	-	Jun	10	11:59:25s 0:00:35 -
-Rule	sol88	1988	only	-	Jun	11	11:59:35s 0:00:25 -
-Rule	sol88	1988	only	-	Jun	12	11:59:50s 0:00:10 -
-Rule	sol88	1988	only	-	Jun	13	12:00:00s 0:00:00 -
-Rule	sol88	1988	only	-	Jun	14	12:00:15s -0:00:15 -
-Rule	sol88	1988	only	-	Jun	15	12:00:25s -0:00:25 -
-Rule	sol88	1988	only	-	Jun	16	12:00:40s -0:00:40 -
-Rule	sol88	1988	only	-	Jun	17	12:00:55s -0:00:55 -
-Rule	sol88	1988	only	-	Jun	18	12:01:05s -0:01:05 -
-Rule	sol88	1988	only	-	Jun	19	12:01:20s -0:01:20 -
-Rule	sol88	1988	only	-	Jun	20	12:01:30s -0:01:30 -
-Rule	sol88	1988	only	-	Jun	21	12:01:45s -0:01:45 -
-Rule	sol88	1988	only	-	Jun	22	12:02:00s -0:02:00 -
-Rule	sol88	1988	only	-	Jun	23	12:02:10s -0:02:10 -
-Rule	sol88	1988	only	-	Jun	24	12:02:25s -0:02:25 -
-Rule	sol88	1988	only	-	Jun	25	12:02:35s -0:02:35 -
-Rule	sol88	1988	only	-	Jun	26	12:02:50s -0:02:50 -
-Rule	sol88	1988	only	-	Jun	27	12:03:00s -0:03:00 -
-Rule	sol88	1988	only	-	Jun	28	12:03:15s -0:03:15 -
-Rule	sol88	1988	only	-	Jun	29	12:03:25s -0:03:25 -
-Rule	sol88	1988	only	-	Jun	30	12:03:40s -0:03:40 -
-Rule	sol88	1988	only	-	Jul	1	12:03:50s -0:03:50 -
-Rule	sol88	1988	only	-	Jul	2	12:04:00s -0:04:00 -
-Rule	sol88	1988	only	-	Jul	3	12:04:10s -0:04:10 -
-Rule	sol88	1988	only	-	Jul	4	12:04:25s -0:04:25 -
-Rule	sol88	1988	only	-	Jul	5	12:04:35s -0:04:35 -
-Rule	sol88	1988	only	-	Jul	6	12:04:45s -0:04:45 -
-Rule	sol88	1988	only	-	Jul	7	12:04:55s -0:04:55 -
-Rule	sol88	1988	only	-	Jul	8	12:05:05s -0:05:05 -
-Rule	sol88	1988	only	-	Jul	9	12:05:10s -0:05:10 -
-Rule	sol88	1988	only	-	Jul	10	12:05:20s -0:05:20 -
-Rule	sol88	1988	only	-	Jul	11	12:05:30s -0:05:30 -
-Rule	sol88	1988	only	-	Jul	12	12:05:35s -0:05:35 -
-Rule	sol88	1988	only	-	Jul	13	12:05:45s -0:05:45 -
-Rule	sol88	1988	only	-	Jul	14	12:05:50s -0:05:50 -
-Rule	sol88	1988	only	-	Jul	15	12:05:55s -0:05:55 -
-Rule	sol88	1988	only	-	Jul	16	12:06:00s -0:06:00 -
-Rule	sol88	1988	only	-	Jul	17	12:06:05s -0:06:05 -
-Rule	sol88	1988	only	-	Jul	18	12:06:10s -0:06:10 -
-Rule	sol88	1988	only	-	Jul	19	12:06:15s -0:06:15 -
-Rule	sol88	1988	only	-	Jul	20	12:06:20s -0:06:20 -
-Rule	sol88	1988	only	-	Jul	21	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jul	22	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jul	23	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jul	24	12:06:30s -0:06:30 -
-Rule	sol88	1988	only	-	Jul	25	12:06:30s -0:06:30 -
-Rule	sol88	1988	only	-	Jul	26	12:06:30s -0:06:30 -
-Rule	sol88	1988	only	-	Jul	27	12:06:30s -0:06:30 -
-Rule	sol88	1988	only	-	Jul	28	12:06:30s -0:06:30 -
-Rule	sol88	1988	only	-	Jul	29	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jul	30	12:06:25s -0:06:25 -
-Rule	sol88	1988	only	-	Jul	31	12:06:20s -0:06:20 -
-Rule	sol88	1988	only	-	Aug	1	12:06:15s -0:06:15 -
-Rule	sol88	1988	only	-	Aug	2	12:06:15s -0:06:15 -
-Rule	sol88	1988	only	-	Aug	3	12:06:10s -0:06:10 -
-Rule	sol88	1988	only	-	Aug	4	12:06:05s -0:06:05 -
-Rule	sol88	1988	only	-	Aug	5	12:05:55s -0:05:55 -
-Rule	sol88	1988	only	-	Aug	6	12:05:50s -0:05:50 -
-Rule	sol88	1988	only	-	Aug	7	12:05:45s -0:05:45 -
-Rule	sol88	1988	only	-	Aug	8	12:05:35s -0:05:35 -
-Rule	sol88	1988	only	-	Aug	9	12:05:25s -0:05:25 -
-Rule	sol88	1988	only	-	Aug	10	12:05:20s -0:05:20 -
-Rule	sol88	1988	only	-	Aug	11	12:05:10s -0:05:10 -
-Rule	sol88	1988	only	-	Aug	12	12:05:00s -0:05:00 -
-Rule	sol88	1988	only	-	Aug	13	12:04:50s -0:04:50 -
-Rule	sol88	1988	only	-	Aug	14	12:04:35s -0:04:35 -
-Rule	sol88	1988	only	-	Aug	15	12:04:25s -0:04:25 -
-Rule	sol88	1988	only	-	Aug	16	12:04:15s -0:04:15 -
-Rule	sol88	1988	only	-	Aug	17	12:04:00s -0:04:00 -
-Rule	sol88	1988	only	-	Aug	18	12:03:50s -0:03:50 -
-Rule	sol88	1988	only	-	Aug	19	12:03:35s -0:03:35 -
-Rule	sol88	1988	only	-	Aug	20	12:03:20s -0:03:20 -
-Rule	sol88	1988	only	-	Aug	21	12:03:05s -0:03:05 -
-Rule	sol88	1988	only	-	Aug	22	12:02:50s -0:02:50 -
-Rule	sol88	1988	only	-	Aug	23	12:02:35s -0:02:35 -
-Rule	sol88	1988	only	-	Aug	24	12:02:20s -0:02:20 -
-Rule	sol88	1988	only	-	Aug	25	12:02:00s -0:02:00 -
-Rule	sol88	1988	only	-	Aug	26	12:01:45s -0:01:45 -
-Rule	sol88	1988	only	-	Aug	27	12:01:30s -0:01:30 -
-Rule	sol88	1988	only	-	Aug	28	12:01:10s -0:01:10 -
-Rule	sol88	1988	only	-	Aug	29	12:00:50s -0:00:50 -
-Rule	sol88	1988	only	-	Aug	30	12:00:35s -0:00:35 -
-Rule	sol88	1988	only	-	Aug	31	12:00:15s -0:00:15 -
-Rule	sol88	1988	only	-	Sep	1	11:59:55s 0:00:05 -
-Rule	sol88	1988	only	-	Sep	2	11:59:35s 0:00:25 -
-Rule	sol88	1988	only	-	Sep	3	11:59:20s 0:00:40 -
-Rule	sol88	1988	only	-	Sep	4	11:59:00s 0:01:00 -
-Rule	sol88	1988	only	-	Sep	5	11:58:40s 0:01:20 -
-Rule	sol88	1988	only	-	Sep	6	11:58:20s 0:01:40 -
-Rule	sol88	1988	only	-	Sep	7	11:58:00s 0:02:00 -
-Rule	sol88	1988	only	-	Sep	8	11:57:35s 0:02:25 -
-Rule	sol88	1988	only	-	Sep	9	11:57:15s 0:02:45 -
-Rule	sol88	1988	only	-	Sep	10	11:56:55s 0:03:05 -
-Rule	sol88	1988	only	-	Sep	11	11:56:35s 0:03:25 -
-Rule	sol88	1988	only	-	Sep	12	11:56:15s 0:03:45 -
-Rule	sol88	1988	only	-	Sep	13	11:55:50s 0:04:10 -
-Rule	sol88	1988	only	-	Sep	14	11:55:30s 0:04:30 -
-Rule	sol88	1988	only	-	Sep	15	11:55:10s 0:04:50 -
-Rule	sol88	1988	only	-	Sep	16	11:54:50s 0:05:10 -
-Rule	sol88	1988	only	-	Sep	17	11:54:25s 0:05:35 -
-Rule	sol88	1988	only	-	Sep	18	11:54:05s 0:05:55 -
-Rule	sol88	1988	only	-	Sep	19	11:53:45s 0:06:15 -
-Rule	sol88	1988	only	-	Sep	20	11:53:25s 0:06:35 -
-Rule	sol88	1988	only	-	Sep	21	11:53:00s 0:07:00 -
-Rule	sol88	1988	only	-	Sep	22	11:52:40s 0:07:20 -
-Rule	sol88	1988	only	-	Sep	23	11:52:20s 0:07:40 -
-Rule	sol88	1988	only	-	Sep	24	11:52:00s 0:08:00 -
-Rule	sol88	1988	only	-	Sep	25	11:51:40s 0:08:20 -
-Rule	sol88	1988	only	-	Sep	26	11:51:15s 0:08:45 -
-Rule	sol88	1988	only	-	Sep	27	11:50:55s 0:09:05 -
-Rule	sol88	1988	only	-	Sep	28	11:50:35s 0:09:25 -
-Rule	sol88	1988	only	-	Sep	29	11:50:15s 0:09:45 -
-Rule	sol88	1988	only	-	Sep	30	11:49:55s 0:10:05 -
-Rule	sol88	1988	only	-	Oct	1	11:49:35s 0:10:25 -
-Rule	sol88	1988	only	-	Oct	2	11:49:20s 0:10:40 -
-Rule	sol88	1988	only	-	Oct	3	11:49:00s 0:11:00 -
-Rule	sol88	1988	only	-	Oct	4	11:48:40s 0:11:20 -
-Rule	sol88	1988	only	-	Oct	5	11:48:25s 0:11:35 -
-Rule	sol88	1988	only	-	Oct	6	11:48:05s 0:11:55 -
-Rule	sol88	1988	only	-	Oct	7	11:47:50s 0:12:10 -
-Rule	sol88	1988	only	-	Oct	8	11:47:30s 0:12:30 -
-Rule	sol88	1988	only	-	Oct	9	11:47:15s 0:12:45 -
-Rule	sol88	1988	only	-	Oct	10	11:47:00s 0:13:00 -
-Rule	sol88	1988	only	-	Oct	11	11:46:45s 0:13:15 -
-Rule	sol88	1988	only	-	Oct	12	11:46:30s 0:13:30 -
-Rule	sol88	1988	only	-	Oct	13	11:46:15s 0:13:45 -
-Rule	sol88	1988	only	-	Oct	14	11:46:00s 0:14:00 -
-Rule	sol88	1988	only	-	Oct	15	11:45:45s 0:14:15 -
-Rule	sol88	1988	only	-	Oct	16	11:45:35s 0:14:25 -
-Rule	sol88	1988	only	-	Oct	17	11:45:20s 0:14:40 -
-Rule	sol88	1988	only	-	Oct	18	11:45:10s 0:14:50 -
-Rule	sol88	1988	only	-	Oct	19	11:45:00s 0:15:00 -
-Rule	sol88	1988	only	-	Oct	20	11:44:45s 0:15:15 -
-Rule	sol88	1988	only	-	Oct	21	11:44:40s 0:15:20 -
-Rule	sol88	1988	only	-	Oct	22	11:44:30s 0:15:30 -
-Rule	sol88	1988	only	-	Oct	23	11:44:20s 0:15:40 -
-Rule	sol88	1988	only	-	Oct	24	11:44:10s 0:15:50 -
-Rule	sol88	1988	only	-	Oct	25	11:44:05s 0:15:55 -
-Rule	sol88	1988	only	-	Oct	26	11:44:00s 0:16:00 -
-Rule	sol88	1988	only	-	Oct	27	11:43:55s 0:16:05 -
-Rule	sol88	1988	only	-	Oct	28	11:43:50s 0:16:10 -
-Rule	sol88	1988	only	-	Oct	29	11:43:45s 0:16:15 -
-Rule	sol88	1988	only	-	Oct	30	11:43:40s 0:16:20 -
-Rule	sol88	1988	only	-	Oct	31	11:43:40s 0:16:20 -
-Rule	sol88	1988	only	-	Nov	1	11:43:35s 0:16:25 -
-Rule	sol88	1988	only	-	Nov	2	11:43:35s 0:16:25 -
-Rule	sol88	1988	only	-	Nov	3	11:43:35s 0:16:25 -
-Rule	sol88	1988	only	-	Nov	4	11:43:35s 0:16:25 -
-Rule	sol88	1988	only	-	Nov	5	11:43:40s 0:16:20 -
-Rule	sol88	1988	only	-	Nov	6	11:43:40s 0:16:20 -
-Rule	sol88	1988	only	-	Nov	7	11:43:45s 0:16:15 -
-Rule	sol88	1988	only	-	Nov	8	11:43:45s 0:16:15 -
-Rule	sol88	1988	only	-	Nov	9	11:43:50s 0:16:10 -
-Rule	sol88	1988	only	-	Nov	10	11:44:00s 0:16:00 -
-Rule	sol88	1988	only	-	Nov	11	11:44:05s 0:15:55 -
-Rule	sol88	1988	only	-	Nov	12	11:44:10s 0:15:50 -
-Rule	sol88	1988	only	-	Nov	13	11:44:20s 0:15:40 -
-Rule	sol88	1988	only	-	Nov	14	11:44:30s 0:15:30 -
-Rule	sol88	1988	only	-	Nov	15	11:44:40s 0:15:20 -
-Rule	sol88	1988	only	-	Nov	16	11:44:50s 0:15:10 -
-Rule	sol88	1988	only	-	Nov	17	11:45:00s 0:15:00 -
-Rule	sol88	1988	only	-	Nov	18	11:45:15s 0:14:45 -
-Rule	sol88	1988	only	-	Nov	19	11:45:25s 0:14:35 -
-Rule	sol88	1988	only	-	Nov	20	11:45:40s 0:14:20 -
-Rule	sol88	1988	only	-	Nov	21	11:45:55s 0:14:05 -
-Rule	sol88	1988	only	-	Nov	22	11:46:10s 0:13:50 -
-Rule	sol88	1988	only	-	Nov	23	11:46:30s 0:13:30 -
-Rule	sol88	1988	only	-	Nov	24	11:46:45s 0:13:15 -
-Rule	sol88	1988	only	-	Nov	25	11:47:05s 0:12:55 -
-Rule	sol88	1988	only	-	Nov	26	11:47:20s 0:12:40 -
-Rule	sol88	1988	only	-	Nov	27	11:47:40s 0:12:20 -
-Rule	sol88	1988	only	-	Nov	28	11:48:00s 0:12:00 -
-Rule	sol88	1988	only	-	Nov	29	11:48:25s 0:11:35 -
-Rule	sol88	1988	only	-	Nov	30	11:48:45s 0:11:15 -
-Rule	sol88	1988	only	-	Dec	1	11:49:05s 0:10:55 -
-Rule	sol88	1988	only	-	Dec	2	11:49:30s 0:10:30 -
-Rule	sol88	1988	only	-	Dec	3	11:49:55s 0:10:05 -
-Rule	sol88	1988	only	-	Dec	4	11:50:15s 0:09:45 -
-Rule	sol88	1988	only	-	Dec	5	11:50:40s 0:09:20 -
-Rule	sol88	1988	only	-	Dec	6	11:51:05s 0:08:55 -
-Rule	sol88	1988	only	-	Dec	7	11:51:35s 0:08:25 -
-Rule	sol88	1988	only	-	Dec	8	11:52:00s 0:08:00 -
-Rule	sol88	1988	only	-	Dec	9	11:52:25s 0:07:35 -
-Rule	sol88	1988	only	-	Dec	10	11:52:55s 0:07:05 -
-Rule	sol88	1988	only	-	Dec	11	11:53:20s 0:06:40 -
-Rule	sol88	1988	only	-	Dec	12	11:53:50s 0:06:10 -
-Rule	sol88	1988	only	-	Dec	13	11:54:15s 0:05:45 -
-Rule	sol88	1988	only	-	Dec	14	11:54:45s 0:05:15 -
-Rule	sol88	1988	only	-	Dec	15	11:55:15s 0:04:45 -
-Rule	sol88	1988	only	-	Dec	16	11:55:45s 0:04:15 -
-Rule	sol88	1988	only	-	Dec	17	11:56:15s 0:03:45 -
-Rule	sol88	1988	only	-	Dec	18	11:56:40s 0:03:20 -
-Rule	sol88	1988	only	-	Dec	19	11:57:10s 0:02:50 -
-Rule	sol88	1988	only	-	Dec	20	11:57:40s 0:02:20 -
-Rule	sol88	1988	only	-	Dec	21	11:58:10s 0:01:50 -
-Rule	sol88	1988	only	-	Dec	22	11:58:40s 0:01:20 -
-Rule	sol88	1988	only	-	Dec	23	11:59:10s 0:00:50 -
-Rule	sol88	1988	only	-	Dec	24	11:59:40s 0:00:20 -
-Rule	sol88	1988	only	-	Dec	25	12:00:10s -0:00:10 -
-Rule	sol88	1988	only	-	Dec	26	12:00:40s -0:00:40 -
-Rule	sol88	1988	only	-	Dec	27	12:01:10s -0:01:10 -
-Rule	sol88	1988	only	-	Dec	28	12:01:40s -0:01:40 -
-Rule	sol88	1988	only	-	Dec	29	12:02:10s -0:02:10 -
-Rule	sol88	1988	only	-	Dec	30	12:02:35s -0:02:35 -
-Rule	sol88	1988	only	-	Dec	31	12:03:05s -0:03:05 -
-
-# Riyadh is at about 46 degrees 46 minutes East:  3 hrs, 7 mins, 4 secs
-# Before and after 1988, we'll operate on local mean solar time.
-
-# Zone	NAME		GMTOFF	RULES/SAVE	FORMAT	[UNTIL]
-Zone	Asia/Riyadh88	3:07:04	-		zzz	1988
-			3:07:04	sol88		zzz	1989
-			3:07:04	-		zzz
-# For backward compatibility...
-Link	Asia/Riyadh88	Mideast/Riyadh88
diff --git a/tools/zoneinfo/tzdata2008h/solar89 b/tools/zoneinfo/tzdata2008h/solar89
deleted file mode 100644
index 8c48531..0000000
--- a/tools/zoneinfo/tzdata2008h/solar89
+++ /dev/null
@@ -1,393 +0,0 @@
-# @(#)solar89	8.1
-
-# Apparent noon times below are for Riyadh; they're a bit off for other places.
-# Times were computed using a formula provided by the U. S. Naval Observatory:
-#	eqt = -105.8 * sin(l) + 596.2 * sin(2 * l) + 4.4 * sin(3 * l)
-#		-12.7 * sin(4 * l) - 429.0 * cos(l) - 2.1 * cos (2 * l)
-#		+ 19.3 * cos(3 * l);
-# where l is the "mean longitude of the Sun" given by
-#	l = 279.642 degrees + 0.985647 * d
-# and d is the interval in days from January 0, 0 hours Universal Time
-# (equaling the day of the year plus the fraction of a day from zero hours).
-# The accuracy of the formula is plus or minus three seconds.
-#
-# Rounding to the nearest five seconds results in fewer than
-# 256 different "time types"--a limit that's faced because time types are
-# stored on disk as unsigned chars.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	sol89	1989	only	-	Jan	1	12:03:35s -0:03:35 -
-Rule	sol89	1989	only	-	Jan	2	12:04:05s -0:04:05 -
-Rule	sol89	1989	only	-	Jan	3	12:04:30s -0:04:30 -
-Rule	sol89	1989	only	-	Jan	4	12:05:00s -0:05:00 -
-Rule	sol89	1989	only	-	Jan	5	12:05:25s -0:05:25 -
-Rule	sol89	1989	only	-	Jan	6	12:05:50s -0:05:50 -
-Rule	sol89	1989	only	-	Jan	7	12:06:15s -0:06:15 -
-Rule	sol89	1989	only	-	Jan	8	12:06:45s -0:06:45 -
-Rule	sol89	1989	only	-	Jan	9	12:07:10s -0:07:10 -
-Rule	sol89	1989	only	-	Jan	10	12:07:35s -0:07:35 -
-Rule	sol89	1989	only	-	Jan	11	12:07:55s -0:07:55 -
-Rule	sol89	1989	only	-	Jan	12	12:08:20s -0:08:20 -
-Rule	sol89	1989	only	-	Jan	13	12:08:45s -0:08:45 -
-Rule	sol89	1989	only	-	Jan	14	12:09:05s -0:09:05 -
-Rule	sol89	1989	only	-	Jan	15	12:09:25s -0:09:25 -
-Rule	sol89	1989	only	-	Jan	16	12:09:45s -0:09:45 -
-Rule	sol89	1989	only	-	Jan	17	12:10:05s -0:10:05 -
-Rule	sol89	1989	only	-	Jan	18	12:10:25s -0:10:25 -
-Rule	sol89	1989	only	-	Jan	19	12:10:45s -0:10:45 -
-Rule	sol89	1989	only	-	Jan	20	12:11:05s -0:11:05 -
-Rule	sol89	1989	only	-	Jan	21	12:11:20s -0:11:20 -
-Rule	sol89	1989	only	-	Jan	22	12:11:35s -0:11:35 -
-Rule	sol89	1989	only	-	Jan	23	12:11:55s -0:11:55 -
-Rule	sol89	1989	only	-	Jan	24	12:12:10s -0:12:10 -
-Rule	sol89	1989	only	-	Jan	25	12:12:20s -0:12:20 -
-Rule	sol89	1989	only	-	Jan	26	12:12:35s -0:12:35 -
-Rule	sol89	1989	only	-	Jan	27	12:12:50s -0:12:50 -
-Rule	sol89	1989	only	-	Jan	28	12:13:00s -0:13:00 -
-Rule	sol89	1989	only	-	Jan	29	12:13:10s -0:13:10 -
-Rule	sol89	1989	only	-	Jan	30	12:13:20s -0:13:20 -
-Rule	sol89	1989	only	-	Jan	31	12:13:30s -0:13:30 -
-Rule	sol89	1989	only	-	Feb	1	12:13:40s -0:13:40 -
-Rule	sol89	1989	only	-	Feb	2	12:13:45s -0:13:45 -
-Rule	sol89	1989	only	-	Feb	3	12:13:55s -0:13:55 -
-Rule	sol89	1989	only	-	Feb	4	12:14:00s -0:14:00 -
-Rule	sol89	1989	only	-	Feb	5	12:14:05s -0:14:05 -
-Rule	sol89	1989	only	-	Feb	6	12:14:10s -0:14:10 -
-Rule	sol89	1989	only	-	Feb	7	12:14:10s -0:14:10 -
-Rule	sol89	1989	only	-	Feb	8	12:14:15s -0:14:15 -
-Rule	sol89	1989	only	-	Feb	9	12:14:15s -0:14:15 -
-Rule	sol89	1989	only	-	Feb	10	12:14:20s -0:14:20 -
-Rule	sol89	1989	only	-	Feb	11	12:14:20s -0:14:20 -
-Rule	sol89	1989	only	-	Feb	12	12:14:20s -0:14:20 -
-Rule	sol89	1989	only	-	Feb	13	12:14:15s -0:14:15 -
-Rule	sol89	1989	only	-	Feb	14	12:14:15s -0:14:15 -
-Rule	sol89	1989	only	-	Feb	15	12:14:10s -0:14:10 -
-Rule	sol89	1989	only	-	Feb	16	12:14:10s -0:14:10 -
-Rule	sol89	1989	only	-	Feb	17	12:14:05s -0:14:05 -
-Rule	sol89	1989	only	-	Feb	18	12:14:00s -0:14:00 -
-Rule	sol89	1989	only	-	Feb	19	12:13:55s -0:13:55 -
-Rule	sol89	1989	only	-	Feb	20	12:13:50s -0:13:50 -
-Rule	sol89	1989	only	-	Feb	21	12:13:40s -0:13:40 -
-Rule	sol89	1989	only	-	Feb	22	12:13:35s -0:13:35 -
-Rule	sol89	1989	only	-	Feb	23	12:13:25s -0:13:25 -
-Rule	sol89	1989	only	-	Feb	24	12:13:15s -0:13:15 -
-Rule	sol89	1989	only	-	Feb	25	12:13:05s -0:13:05 -
-Rule	sol89	1989	only	-	Feb	26	12:12:55s -0:12:55 -
-Rule	sol89	1989	only	-	Feb	27	12:12:45s -0:12:45 -
-Rule	sol89	1989	only	-	Feb	28	12:12:35s -0:12:35 -
-Rule	sol89	1989	only	-	Mar	1	12:12:25s -0:12:25 -
-Rule	sol89	1989	only	-	Mar	2	12:12:10s -0:12:10 -
-Rule	sol89	1989	only	-	Mar	3	12:12:00s -0:12:00 -
-Rule	sol89	1989	only	-	Mar	4	12:11:45s -0:11:45 -
-Rule	sol89	1989	only	-	Mar	5	12:11:35s -0:11:35 -
-Rule	sol89	1989	only	-	Mar	6	12:11:20s -0:11:20 -
-Rule	sol89	1989	only	-	Mar	7	12:11:05s -0:11:05 -
-Rule	sol89	1989	only	-	Mar	8	12:10:50s -0:10:50 -
-Rule	sol89	1989	only	-	Mar	9	12:10:35s -0:10:35 -
-Rule	sol89	1989	only	-	Mar	10	12:10:20s -0:10:20 -
-Rule	sol89	1989	only	-	Mar	11	12:10:05s -0:10:05 -
-Rule	sol89	1989	only	-	Mar	12	12:09:50s -0:09:50 -
-Rule	sol89	1989	only	-	Mar	13	12:09:30s -0:09:30 -
-Rule	sol89	1989	only	-	Mar	14	12:09:15s -0:09:15 -
-Rule	sol89	1989	only	-	Mar	15	12:09:00s -0:09:00 -
-Rule	sol89	1989	only	-	Mar	16	12:08:40s -0:08:40 -
-Rule	sol89	1989	only	-	Mar	17	12:08:25s -0:08:25 -
-Rule	sol89	1989	only	-	Mar	18	12:08:05s -0:08:05 -
-Rule	sol89	1989	only	-	Mar	19	12:07:50s -0:07:50 -
-Rule	sol89	1989	only	-	Mar	20	12:07:30s -0:07:30 -
-Rule	sol89	1989	only	-	Mar	21	12:07:15s -0:07:15 -
-Rule	sol89	1989	only	-	Mar	22	12:06:55s -0:06:55 -
-Rule	sol89	1989	only	-	Mar	23	12:06:35s -0:06:35 -
-Rule	sol89	1989	only	-	Mar	24	12:06:20s -0:06:20 -
-Rule	sol89	1989	only	-	Mar	25	12:06:00s -0:06:00 -
-Rule	sol89	1989	only	-	Mar	26	12:05:40s -0:05:40 -
-Rule	sol89	1989	only	-	Mar	27	12:05:25s -0:05:25 -
-Rule	sol89	1989	only	-	Mar	28	12:05:05s -0:05:05 -
-Rule	sol89	1989	only	-	Mar	29	12:04:50s -0:04:50 -
-Rule	sol89	1989	only	-	Mar	30	12:04:30s -0:04:30 -
-Rule	sol89	1989	only	-	Mar	31	12:04:10s -0:04:10 -
-Rule	sol89	1989	only	-	Apr	1	12:03:55s -0:03:55 -
-Rule	sol89	1989	only	-	Apr	2	12:03:35s -0:03:35 -
-Rule	sol89	1989	only	-	Apr	3	12:03:20s -0:03:20 -
-Rule	sol89	1989	only	-	Apr	4	12:03:00s -0:03:00 -
-Rule	sol89	1989	only	-	Apr	5	12:02:45s -0:02:45 -
-Rule	sol89	1989	only	-	Apr	6	12:02:25s -0:02:25 -
-Rule	sol89	1989	only	-	Apr	7	12:02:10s -0:02:10 -
-Rule	sol89	1989	only	-	Apr	8	12:01:50s -0:01:50 -
-Rule	sol89	1989	only	-	Apr	9	12:01:35s -0:01:35 -
-Rule	sol89	1989	only	-	Apr	10	12:01:20s -0:01:20 -
-Rule	sol89	1989	only	-	Apr	11	12:01:05s -0:01:05 -
-Rule	sol89	1989	only	-	Apr	12	12:00:50s -0:00:50 -
-Rule	sol89	1989	only	-	Apr	13	12:00:35s -0:00:35 -
-Rule	sol89	1989	only	-	Apr	14	12:00:20s -0:00:20 -
-Rule	sol89	1989	only	-	Apr	15	12:00:05s -0:00:05 -
-Rule	sol89	1989	only	-	Apr	16	11:59:50s 0:00:10 -
-Rule	sol89	1989	only	-	Apr	17	11:59:35s 0:00:25 -
-Rule	sol89	1989	only	-	Apr	18	11:59:20s 0:00:40 -
-Rule	sol89	1989	only	-	Apr	19	11:59:10s 0:00:50 -
-Rule	sol89	1989	only	-	Apr	20	11:58:55s 0:01:05 -
-Rule	sol89	1989	only	-	Apr	21	11:58:45s 0:01:15 -
-Rule	sol89	1989	only	-	Apr	22	11:58:30s 0:01:30 -
-Rule	sol89	1989	only	-	Apr	23	11:58:20s 0:01:40 -
-Rule	sol89	1989	only	-	Apr	24	11:58:10s 0:01:50 -
-Rule	sol89	1989	only	-	Apr	25	11:58:00s 0:02:00 -
-Rule	sol89	1989	only	-	Apr	26	11:57:50s 0:02:10 -
-Rule	sol89	1989	only	-	Apr	27	11:57:40s 0:02:20 -
-Rule	sol89	1989	only	-	Apr	28	11:57:30s 0:02:30 -
-Rule	sol89	1989	only	-	Apr	29	11:57:20s 0:02:40 -
-Rule	sol89	1989	only	-	Apr	30	11:57:15s 0:02:45 -
-Rule	sol89	1989	only	-	May	1	11:57:05s 0:02:55 -
-Rule	sol89	1989	only	-	May	2	11:57:00s 0:03:00 -
-Rule	sol89	1989	only	-	May	3	11:56:50s 0:03:10 -
-Rule	sol89	1989	only	-	May	4	11:56:45s 0:03:15 -
-Rule	sol89	1989	only	-	May	5	11:56:40s 0:03:20 -
-Rule	sol89	1989	only	-	May	6	11:56:35s 0:03:25 -
-Rule	sol89	1989	only	-	May	7	11:56:30s 0:03:30 -
-Rule	sol89	1989	only	-	May	8	11:56:30s 0:03:30 -
-Rule	sol89	1989	only	-	May	9	11:56:25s 0:03:35 -
-Rule	sol89	1989	only	-	May	10	11:56:25s 0:03:35 -
-Rule	sol89	1989	only	-	May	11	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	12	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	13	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	14	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	15	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	16	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	17	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	May	18	11:56:25s 0:03:35 -
-Rule	sol89	1989	only	-	May	19	11:56:25s 0:03:35 -
-Rule	sol89	1989	only	-	May	20	11:56:30s 0:03:30 -
-Rule	sol89	1989	only	-	May	21	11:56:35s 0:03:25 -
-Rule	sol89	1989	only	-	May	22	11:56:35s 0:03:25 -
-Rule	sol89	1989	only	-	May	23	11:56:40s 0:03:20 -
-Rule	sol89	1989	only	-	May	24	11:56:45s 0:03:15 -
-Rule	sol89	1989	only	-	May	25	11:56:55s 0:03:05 -
-Rule	sol89	1989	only	-	May	26	11:57:00s 0:03:00 -
-Rule	sol89	1989	only	-	May	27	11:57:05s 0:02:55 -
-Rule	sol89	1989	only	-	May	28	11:57:15s 0:02:45 -
-Rule	sol89	1989	only	-	May	29	11:57:20s 0:02:40 -
-Rule	sol89	1989	only	-	May	30	11:57:30s 0:02:30 -
-Rule	sol89	1989	only	-	May	31	11:57:35s 0:02:25 -
-Rule	sol89	1989	only	-	Jun	1	11:57:45s 0:02:15 -
-Rule	sol89	1989	only	-	Jun	2	11:57:55s 0:02:05 -
-Rule	sol89	1989	only	-	Jun	3	11:58:05s 0:01:55 -
-Rule	sol89	1989	only	-	Jun	4	11:58:15s 0:01:45 -
-Rule	sol89	1989	only	-	Jun	5	11:58:25s 0:01:35 -
-Rule	sol89	1989	only	-	Jun	6	11:58:35s 0:01:25 -
-Rule	sol89	1989	only	-	Jun	7	11:58:45s 0:01:15 -
-Rule	sol89	1989	only	-	Jun	8	11:59:00s 0:01:00 -
-Rule	sol89	1989	only	-	Jun	9	11:59:10s 0:00:50 -
-Rule	sol89	1989	only	-	Jun	10	11:59:20s 0:00:40 -
-Rule	sol89	1989	only	-	Jun	11	11:59:35s 0:00:25 -
-Rule	sol89	1989	only	-	Jun	12	11:59:45s 0:00:15 -
-Rule	sol89	1989	only	-	Jun	13	12:00:00s 0:00:00 -
-Rule	sol89	1989	only	-	Jun	14	12:00:10s -0:00:10 -
-Rule	sol89	1989	only	-	Jun	15	12:00:25s -0:00:25 -
-Rule	sol89	1989	only	-	Jun	16	12:00:35s -0:00:35 -
-Rule	sol89	1989	only	-	Jun	17	12:00:50s -0:00:50 -
-Rule	sol89	1989	only	-	Jun	18	12:01:05s -0:01:05 -
-Rule	sol89	1989	only	-	Jun	19	12:01:15s -0:01:15 -
-Rule	sol89	1989	only	-	Jun	20	12:01:30s -0:01:30 -
-Rule	sol89	1989	only	-	Jun	21	12:01:40s -0:01:40 -
-Rule	sol89	1989	only	-	Jun	22	12:01:55s -0:01:55 -
-Rule	sol89	1989	only	-	Jun	23	12:02:10s -0:02:10 -
-Rule	sol89	1989	only	-	Jun	24	12:02:20s -0:02:20 -
-Rule	sol89	1989	only	-	Jun	25	12:02:35s -0:02:35 -
-Rule	sol89	1989	only	-	Jun	26	12:02:45s -0:02:45 -
-Rule	sol89	1989	only	-	Jun	27	12:03:00s -0:03:00 -
-Rule	sol89	1989	only	-	Jun	28	12:03:10s -0:03:10 -
-Rule	sol89	1989	only	-	Jun	29	12:03:25s -0:03:25 -
-Rule	sol89	1989	only	-	Jun	30	12:03:35s -0:03:35 -
-Rule	sol89	1989	only	-	Jul	1	12:03:45s -0:03:45 -
-Rule	sol89	1989	only	-	Jul	2	12:04:00s -0:04:00 -
-Rule	sol89	1989	only	-	Jul	3	12:04:10s -0:04:10 -
-Rule	sol89	1989	only	-	Jul	4	12:04:20s -0:04:20 -
-Rule	sol89	1989	only	-	Jul	5	12:04:30s -0:04:30 -
-Rule	sol89	1989	only	-	Jul	6	12:04:40s -0:04:40 -
-Rule	sol89	1989	only	-	Jul	7	12:04:50s -0:04:50 -
-Rule	sol89	1989	only	-	Jul	8	12:05:00s -0:05:00 -
-Rule	sol89	1989	only	-	Jul	9	12:05:10s -0:05:10 -
-Rule	sol89	1989	only	-	Jul	10	12:05:20s -0:05:20 -
-Rule	sol89	1989	only	-	Jul	11	12:05:25s -0:05:25 -
-Rule	sol89	1989	only	-	Jul	12	12:05:35s -0:05:35 -
-Rule	sol89	1989	only	-	Jul	13	12:05:40s -0:05:40 -
-Rule	sol89	1989	only	-	Jul	14	12:05:50s -0:05:50 -
-Rule	sol89	1989	only	-	Jul	15	12:05:55s -0:05:55 -
-Rule	sol89	1989	only	-	Jul	16	12:06:00s -0:06:00 -
-Rule	sol89	1989	only	-	Jul	17	12:06:05s -0:06:05 -
-Rule	sol89	1989	only	-	Jul	18	12:06:10s -0:06:10 -
-Rule	sol89	1989	only	-	Jul	19	12:06:15s -0:06:15 -
-Rule	sol89	1989	only	-	Jul	20	12:06:20s -0:06:20 -
-Rule	sol89	1989	only	-	Jul	21	12:06:20s -0:06:20 -
-Rule	sol89	1989	only	-	Jul	22	12:06:25s -0:06:25 -
-Rule	sol89	1989	only	-	Jul	23	12:06:25s -0:06:25 -
-Rule	sol89	1989	only	-	Jul	24	12:06:30s -0:06:30 -
-Rule	sol89	1989	only	-	Jul	25	12:06:30s -0:06:30 -
-Rule	sol89	1989	only	-	Jul	26	12:06:30s -0:06:30 -
-Rule	sol89	1989	only	-	Jul	27	12:06:30s -0:06:30 -
-Rule	sol89	1989	only	-	Jul	28	12:06:30s -0:06:30 -
-Rule	sol89	1989	only	-	Jul	29	12:06:25s -0:06:25 -
-Rule	sol89	1989	only	-	Jul	30	12:06:25s -0:06:25 -
-Rule	sol89	1989	only	-	Jul	31	12:06:20s -0:06:20 -
-Rule	sol89	1989	only	-	Aug	1	12:06:20s -0:06:20 -
-Rule	sol89	1989	only	-	Aug	2	12:06:15s -0:06:15 -
-Rule	sol89	1989	only	-	Aug	3	12:06:10s -0:06:10 -
-Rule	sol89	1989	only	-	Aug	4	12:06:05s -0:06:05 -
-Rule	sol89	1989	only	-	Aug	5	12:06:00s -0:06:00 -
-Rule	sol89	1989	only	-	Aug	6	12:05:50s -0:05:50 -
-Rule	sol89	1989	only	-	Aug	7	12:05:45s -0:05:45 -
-Rule	sol89	1989	only	-	Aug	8	12:05:35s -0:05:35 -
-Rule	sol89	1989	only	-	Aug	9	12:05:30s -0:05:30 -
-Rule	sol89	1989	only	-	Aug	10	12:05:20s -0:05:20 -
-Rule	sol89	1989	only	-	Aug	11	12:05:10s -0:05:10 -
-Rule	sol89	1989	only	-	Aug	12	12:05:00s -0:05:00 -
-Rule	sol89	1989	only	-	Aug	13	12:04:50s -0:04:50 -
-Rule	sol89	1989	only	-	Aug	14	12:04:40s -0:04:40 -
-Rule	sol89	1989	only	-	Aug	15	12:04:30s -0:04:30 -
-Rule	sol89	1989	only	-	Aug	16	12:04:15s -0:04:15 -
-Rule	sol89	1989	only	-	Aug	17	12:04:05s -0:04:05 -
-Rule	sol89	1989	only	-	Aug	18	12:03:50s -0:03:50 -
-Rule	sol89	1989	only	-	Aug	19	12:03:35s -0:03:35 -
-Rule	sol89	1989	only	-	Aug	20	12:03:25s -0:03:25 -
-Rule	sol89	1989	only	-	Aug	21	12:03:10s -0:03:10 -
-Rule	sol89	1989	only	-	Aug	22	12:02:55s -0:02:55 -
-Rule	sol89	1989	only	-	Aug	23	12:02:40s -0:02:40 -
-Rule	sol89	1989	only	-	Aug	24	12:02:20s -0:02:20 -
-Rule	sol89	1989	only	-	Aug	25	12:02:05s -0:02:05 -
-Rule	sol89	1989	only	-	Aug	26	12:01:50s -0:01:50 -
-Rule	sol89	1989	only	-	Aug	27	12:01:30s -0:01:30 -
-Rule	sol89	1989	only	-	Aug	28	12:01:15s -0:01:15 -
-Rule	sol89	1989	only	-	Aug	29	12:00:55s -0:00:55 -
-Rule	sol89	1989	only	-	Aug	30	12:00:40s -0:00:40 -
-Rule	sol89	1989	only	-	Aug	31	12:00:20s -0:00:20 -
-Rule	sol89	1989	only	-	Sep	1	12:00:00s 0:00:00 -
-Rule	sol89	1989	only	-	Sep	2	11:59:45s 0:00:15 -
-Rule	sol89	1989	only	-	Sep	3	11:59:25s 0:00:35 -
-Rule	sol89	1989	only	-	Sep	4	11:59:05s 0:00:55 -
-Rule	sol89	1989	only	-	Sep	5	11:58:45s 0:01:15 -
-Rule	sol89	1989	only	-	Sep	6	11:58:25s 0:01:35 -
-Rule	sol89	1989	only	-	Sep	7	11:58:05s 0:01:55 -
-Rule	sol89	1989	only	-	Sep	8	11:57:45s 0:02:15 -
-Rule	sol89	1989	only	-	Sep	9	11:57:20s 0:02:40 -
-Rule	sol89	1989	only	-	Sep	10	11:57:00s 0:03:00 -
-Rule	sol89	1989	only	-	Sep	11	11:56:40s 0:03:20 -
-Rule	sol89	1989	only	-	Sep	12	11:56:20s 0:03:40 -
-Rule	sol89	1989	only	-	Sep	13	11:56:00s 0:04:00 -
-Rule	sol89	1989	only	-	Sep	14	11:55:35s 0:04:25 -
-Rule	sol89	1989	only	-	Sep	15	11:55:15s 0:04:45 -
-Rule	sol89	1989	only	-	Sep	16	11:54:55s 0:05:05 -
-Rule	sol89	1989	only	-	Sep	17	11:54:35s 0:05:25 -
-Rule	sol89	1989	only	-	Sep	18	11:54:10s 0:05:50 -
-Rule	sol89	1989	only	-	Sep	19	11:53:50s 0:06:10 -
-Rule	sol89	1989	only	-	Sep	20	11:53:30s 0:06:30 -
-Rule	sol89	1989	only	-	Sep	21	11:53:10s 0:06:50 -
-Rule	sol89	1989	only	-	Sep	22	11:52:45s 0:07:15 -
-Rule	sol89	1989	only	-	Sep	23	11:52:25s 0:07:35 -
-Rule	sol89	1989	only	-	Sep	24	11:52:05s 0:07:55 -
-Rule	sol89	1989	only	-	Sep	25	11:51:45s 0:08:15 -
-Rule	sol89	1989	only	-	Sep	26	11:51:25s 0:08:35 -
-Rule	sol89	1989	only	-	Sep	27	11:51:05s 0:08:55 -
-Rule	sol89	1989	only	-	Sep	28	11:50:40s 0:09:20 -
-Rule	sol89	1989	only	-	Sep	29	11:50:20s 0:09:40 -
-Rule	sol89	1989	only	-	Sep	30	11:50:00s 0:10:00 -
-Rule	sol89	1989	only	-	Oct	1	11:49:45s 0:10:15 -
-Rule	sol89	1989	only	-	Oct	2	11:49:25s 0:10:35 -
-Rule	sol89	1989	only	-	Oct	3	11:49:05s 0:10:55 -
-Rule	sol89	1989	only	-	Oct	4	11:48:45s 0:11:15 -
-Rule	sol89	1989	only	-	Oct	5	11:48:30s 0:11:30 -
-Rule	sol89	1989	only	-	Oct	6	11:48:10s 0:11:50 -
-Rule	sol89	1989	only	-	Oct	7	11:47:50s 0:12:10 -
-Rule	sol89	1989	only	-	Oct	8	11:47:35s 0:12:25 -
-Rule	sol89	1989	only	-	Oct	9	11:47:20s 0:12:40 -
-Rule	sol89	1989	only	-	Oct	10	11:47:00s 0:13:00 -
-Rule	sol89	1989	only	-	Oct	11	11:46:45s 0:13:15 -
-Rule	sol89	1989	only	-	Oct	12	11:46:30s 0:13:30 -
-Rule	sol89	1989	only	-	Oct	13	11:46:15s 0:13:45 -
-Rule	sol89	1989	only	-	Oct	14	11:46:00s 0:14:00 -
-Rule	sol89	1989	only	-	Oct	15	11:45:50s 0:14:10 -
-Rule	sol89	1989	only	-	Oct	16	11:45:35s 0:14:25 -
-Rule	sol89	1989	only	-	Oct	17	11:45:20s 0:14:40 -
-Rule	sol89	1989	only	-	Oct	18	11:45:10s 0:14:50 -
-Rule	sol89	1989	only	-	Oct	19	11:45:00s 0:15:00 -
-Rule	sol89	1989	only	-	Oct	20	11:44:50s 0:15:10 -
-Rule	sol89	1989	only	-	Oct	21	11:44:40s 0:15:20 -
-Rule	sol89	1989	only	-	Oct	22	11:44:30s 0:15:30 -
-Rule	sol89	1989	only	-	Oct	23	11:44:20s 0:15:40 -
-Rule	sol89	1989	only	-	Oct	24	11:44:10s 0:15:50 -
-Rule	sol89	1989	only	-	Oct	25	11:44:05s 0:15:55 -
-Rule	sol89	1989	only	-	Oct	26	11:44:00s 0:16:00 -
-Rule	sol89	1989	only	-	Oct	27	11:43:50s 0:16:10 -
-Rule	sol89	1989	only	-	Oct	28	11:43:45s 0:16:15 -
-Rule	sol89	1989	only	-	Oct	29	11:43:40s 0:16:20 -
-Rule	sol89	1989	only	-	Oct	30	11:43:40s 0:16:20 -
-Rule	sol89	1989	only	-	Oct	31	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	1	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	2	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	3	11:43:30s 0:16:30 -
-Rule	sol89	1989	only	-	Nov	4	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	5	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	6	11:43:35s 0:16:25 -
-Rule	sol89	1989	only	-	Nov	7	11:43:40s 0:16:20 -
-Rule	sol89	1989	only	-	Nov	8	11:43:45s 0:16:15 -
-Rule	sol89	1989	only	-	Nov	9	11:43:50s 0:16:10 -
-Rule	sol89	1989	only	-	Nov	10	11:43:55s 0:16:05 -
-Rule	sol89	1989	only	-	Nov	11	11:44:00s 0:16:00 -
-Rule	sol89	1989	only	-	Nov	12	11:44:05s 0:15:55 -
-Rule	sol89	1989	only	-	Nov	13	11:44:15s 0:15:45 -
-Rule	sol89	1989	only	-	Nov	14	11:44:25s 0:15:35 -
-Rule	sol89	1989	only	-	Nov	15	11:44:35s 0:15:25 -
-Rule	sol89	1989	only	-	Nov	16	11:44:45s 0:15:15 -
-Rule	sol89	1989	only	-	Nov	17	11:44:55s 0:15:05 -
-Rule	sol89	1989	only	-	Nov	18	11:45:10s 0:14:50 -
-Rule	sol89	1989	only	-	Nov	19	11:45:20s 0:14:40 -
-Rule	sol89	1989	only	-	Nov	20	11:45:35s 0:14:25 -
-Rule	sol89	1989	only	-	Nov	21	11:45:50s 0:14:10 -
-Rule	sol89	1989	only	-	Nov	22	11:46:05s 0:13:55 -
-Rule	sol89	1989	only	-	Nov	23	11:46:25s 0:13:35 -
-Rule	sol89	1989	only	-	Nov	24	11:46:40s 0:13:20 -
-Rule	sol89	1989	only	-	Nov	25	11:47:00s 0:13:00 -
-Rule	sol89	1989	only	-	Nov	26	11:47:20s 0:12:40 -
-Rule	sol89	1989	only	-	Nov	27	11:47:35s 0:12:25 -
-Rule	sol89	1989	only	-	Nov	28	11:47:55s 0:12:05 -
-Rule	sol89	1989	only	-	Nov	29	11:48:20s 0:11:40 -
-Rule	sol89	1989	only	-	Nov	30	11:48:40s 0:11:20 -
-Rule	sol89	1989	only	-	Dec	1	11:49:00s 0:11:00 -
-Rule	sol89	1989	only	-	Dec	2	11:49:25s 0:10:35 -
-Rule	sol89	1989	only	-	Dec	3	11:49:50s 0:10:10 -
-Rule	sol89	1989	only	-	Dec	4	11:50:15s 0:09:45 -
-Rule	sol89	1989	only	-	Dec	5	11:50:35s 0:09:25 -
-Rule	sol89	1989	only	-	Dec	6	11:51:00s 0:09:00 -
-Rule	sol89	1989	only	-	Dec	7	11:51:30s 0:08:30 -
-Rule	sol89	1989	only	-	Dec	8	11:51:55s 0:08:05 -
-Rule	sol89	1989	only	-	Dec	9	11:52:20s 0:07:40 -
-Rule	sol89	1989	only	-	Dec	10	11:52:50s 0:07:10 -
-Rule	sol89	1989	only	-	Dec	11	11:53:15s 0:06:45 -
-Rule	sol89	1989	only	-	Dec	12	11:53:45s 0:06:15 -
-Rule	sol89	1989	only	-	Dec	13	11:54:10s 0:05:50 -
-Rule	sol89	1989	only	-	Dec	14	11:54:40s 0:05:20 -
-Rule	sol89	1989	only	-	Dec	15	11:55:10s 0:04:50 -
-Rule	sol89	1989	only	-	Dec	16	11:55:40s 0:04:20 -
-Rule	sol89	1989	only	-	Dec	17	11:56:05s 0:03:55 -
-Rule	sol89	1989	only	-	Dec	18	11:56:35s 0:03:25 -
-Rule	sol89	1989	only	-	Dec	19	11:57:05s 0:02:55 -
-Rule	sol89	1989	only	-	Dec	20	11:57:35s 0:02:25 -
-Rule	sol89	1989	only	-	Dec	21	11:58:05s 0:01:55 -
-Rule	sol89	1989	only	-	Dec	22	11:58:35s 0:01:25 -
-Rule	sol89	1989	only	-	Dec	23	11:59:05s 0:00:55 -
-Rule	sol89	1989	only	-	Dec	24	11:59:35s 0:00:25 -
-Rule	sol89	1989	only	-	Dec	25	12:00:05s -0:00:05 -
-Rule	sol89	1989	only	-	Dec	26	12:00:35s -0:00:35 -
-Rule	sol89	1989	only	-	Dec	27	12:01:05s -0:01:05 -
-Rule	sol89	1989	only	-	Dec	28	12:01:35s -0:01:35 -
-Rule	sol89	1989	only	-	Dec	29	12:02:00s -0:02:00 -
-Rule	sol89	1989	only	-	Dec	30	12:02:30s -0:02:30 -
-Rule	sol89	1989	only	-	Dec	31	12:03:00s -0:03:00 -
-
-# Riyadh is at about 46 degrees 46 minutes East:  3 hrs, 7 mins, 4 secs
-# Before and after 1989, we'll operate on local mean solar time.
-
-# Zone	NAME		GMTOFF	RULES/SAVE	FORMAT	[UNTIL]
-Zone	Asia/Riyadh89	3:07:04	-		zzz	1989
-			3:07:04	sol89		zzz	1990
-			3:07:04	-		zzz
-# For backward compatibility...
-Link	Asia/Riyadh89	Mideast/Riyadh89
diff --git a/tools/zoneinfo/tzdata2008h/southamerica b/tools/zoneinfo/tzdata2008h/southamerica
deleted file mode 100644
index 5dae61a..0000000
--- a/tools/zoneinfo/tzdata2008h/southamerica
+++ /dev/null
@@ -1,1390 +0,0 @@
-# @(#)southamerica	8.30
-# <pre>
-
-# This data is by no means authoritative; if you think you know better,
-# go ahead and edit the file (and please send any changes to
-# tz@elsie.nci.nih.gov for general use in the future).
-
-# From Paul Eggert (2006-03-22):
-# A good source for time zone historical data outside the U.S. is
-# Thomas G. Shanks and Rique Pottenger, The International Atlas (6th edition),
-# San Diego: ACS Publications, Inc. (2003).
-#
-# Gwillim Law writes that a good source
-# for recent time zone data is the International Air Transport
-# Association's Standard Schedules Information Manual (IATA SSIM),
-# published semiannually.  Law sent in several helpful summaries
-# of the IATA's data after 1990.
-#
-# Except where otherwise noted, Shanks & Pottenger is the source for
-# entries through 1990, and IATA SSIM is the source for entries afterwards.
-#
-# Earlier editions of these tables used the North American style (e.g. ARST and
-# ARDT for Argentine Standard and Daylight Time), but the following quote
-# suggests that it's better to use European style (e.g. ART and ARST).
-#	I suggest the use of _Summer time_ instead of the more cumbersome
-#	_daylight-saving time_.  _Summer time_ seems to be in general use
-#	in Europe and South America.
-#	-- E O Cutler, _New York Times_ (1937-02-14), quoted in
-#	H L Mencken, _The American Language: Supplement I_ (1960), p 466
-#
-# Earlier editions of these tables also used the North American style
-# for time zones in Brazil, but this was incorrect, as Brazilians say
-# "summer time".  Reinaldo Goulart, a Sao Paulo businessman active in
-# the railroad sector, writes (1999-07-06):
-#	The subject of time zones is currently a matter of discussion/debate in
-#	Brazil.  Let's say that "the Brasilia time" is considered the
-#	"official time" because Brasilia is the capital city.
-#	The other three time zones are called "Brasilia time "minus one" or
-#	"plus one" or "plus two".  As far as I know there is no such
-#	name/designation as "Eastern Time" or "Central Time".
-# So I invented the following (English-language) abbreviations for now.
-# Corrections are welcome!
-#		std	dst
-#	-2:00	FNT	FNST	Fernando de Noronha
-#	-3:00	BRT	BRST	Brasilia
-#	-4:00	AMT	AMST	Amazon
-#	-5:00	ACT	ACST	Acre
-
-###############################################################################
-
-###############################################################################
-
-# Argentina
-
-# From Bob Devine (1988-01-28):
-# Argentina: first Sunday in October to first Sunday in April since 1976.
-# Double Summer time from 1969 to 1974.  Switches at midnight.
-
-# From U. S. Naval Observatory (1988-01-199):
-# ARGENTINA           3 H BEHIND   UTC
-
-# From Hernan G. Otero (1995-06-26):
-# I am sending modifications to the Argentine time zone table...
-# AR was chosen because they are the ISO letters that represent Argentina.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Arg	1930	only	-	Dec	 1	0:00	1:00	S
-Rule	Arg	1931	only	-	Apr	 1	0:00	0	-
-Rule	Arg	1931	only	-	Oct	15	0:00	1:00	S
-Rule	Arg	1932	1940	-	Mar	 1	0:00	0	-
-Rule	Arg	1932	1939	-	Nov	 1	0:00	1:00	S
-Rule	Arg	1940	only	-	Jul	 1	0:00	1:00	S
-Rule	Arg	1941	only	-	Jun	15	0:00	0	-
-Rule	Arg	1941	only	-	Oct	15	0:00	1:00	S
-Rule	Arg	1943	only	-	Aug	 1	0:00	0	-
-Rule	Arg	1943	only	-	Oct	15	0:00	1:00	S
-Rule	Arg	1946	only	-	Mar	 1	0:00	0	-
-Rule	Arg	1946	only	-	Oct	 1	0:00	1:00	S
-Rule	Arg	1963	only	-	Oct	 1	0:00	0	-
-Rule	Arg	1963	only	-	Dec	15	0:00	1:00	S
-Rule	Arg	1964	1966	-	Mar	 1	0:00	0	-
-Rule	Arg	1964	1966	-	Oct	15	0:00	1:00	S
-Rule	Arg	1967	only	-	Apr	 2	0:00	0	-
-Rule	Arg	1967	1968	-	Oct	Sun>=1	0:00	1:00	S
-Rule	Arg	1968	1969	-	Apr	Sun>=1	0:00	0	-
-Rule	Arg	1974	only	-	Jan	23	0:00	1:00	S
-Rule	Arg	1974	only	-	May	 1	0:00	0	-
-Rule	Arg	1988	only	-	Dec	 1	0:00	1:00	S
-#
-# From Hernan G. Otero (1995-06-26):
-# These corrections were contributed by InterSoft Argentina S.A.,
-# obtaining the data from the:
-# Talleres de Hidrografia Naval Argentina
-# (Argentine Naval Hydrography Institute)
-Rule	Arg	1989	1993	-	Mar	Sun>=1	0:00	0	-
-Rule	Arg	1989	1992	-	Oct	Sun>=15	0:00	1:00	S
-#
-# From Hernan G. Otero (1995-06-26):
-# From this moment on, the law that mandated the daylight saving
-# time corrections was derogated and no more modifications
-# to the time zones (for daylight saving) are now made.
-#
-# From Rives McDow (2000-01-10):
-# On October 3, 1999, 0:00 local, Argentina implemented daylight savings time,
-# which did not result in the switch of a time zone, as they stayed 9 hours
-# from the International Date Line.
-Rule	Arg	1999	only	-	Oct	Sun>=1	0:00	1:00	S
-# From Paul Eggert (2007-12-28):
-# DST was set to expire on March 5, not March 3, but since it was converted
-# to standard time on March 3 it's more convenient for us to pretend that
-# it ended on March 3.
-Rule	Arg	2000	only	-	Mar	3	0:00	0	-
-#
-# From Peter Gradelski via Steffen Thorsen (2000-03-01):
-# We just checked with our Sao Paulo office and they say the government of
-# Argentina decided not to become one of the countries that go on or off DST.
-# So Buenos Aires should be -3 hours from GMT at all times.
-#
-# From Fabian L. Arce Jofre (2000-04-04):
-# The law that claimed DST for Argentina was derogated by President Fernando
-# de la Rua on March 2, 2000, because it would make people spend more energy
-# in the winter time, rather than less.  The change took effect on March 3.
-#
-# From Mariano Absatz (2001-06-06):
-# one of the major newspapers here in Argentina said that the 1999
-# Timezone Law (which never was effectively applied) will (would?) be
-# in effect.... The article is at
-# http://ar.clarin.com/diario/2001-06-06/e-01701.htm
-# ... The Law itself is "Ley No 25155", sanctioned on 1999-08-25, enacted
-# 1999-09-17, and published 1999-09-21.  The official publication is at:
-# http://www.boletin.jus.gov.ar/BON/Primera/1999/09-Septiembre/21/PDF/BO21-09-99LEG.PDF
-# Regretfully, you have to subscribe (and pay) for the on-line version....
-#
-# (2001-06-12):
-# the timezone for Argentina will not change next Sunday.
-# Apparently it will do so on Sunday 24th....
-# http://ar.clarin.com/diario/2001-06-12/s-03501.htm
-#
-# (2001-06-25):
-# Last Friday (yes, the last working day before the date of the change), the
-# Senate annulled the 1999 law that introduced the changes later postponed.
-# http://www.clarin.com.ar/diario/2001-06-22/s-03601.htm
-# It remains the vote of the Deputies..., but it will be the same....
-# This kind of things had always been done this way in Argentina.
-# We are still -03:00 all year round in all of the country.
-#
-# From Steffen Thorsen (2007-12-21):
-# A user (Leonardo Chaim) reported that Argentina will adopt DST....
-# all of the country (all Zone-entries) are affected.  News reports like
-# http://www.lanacion.com.ar/opinion/nota.asp?nota_id=973037 indicate
-# that Argentina will use DST next year as well, from October to
-# March, although exact rules are not given.
-#
-# From Jesper Norgaard Welen (2007-12-26)
-# The last hurdle of Argentina DST is over, the proposal was approved in
-# the lower chamber too (Deputados) with a vote 192 for and 2 against.
-# By the way thanks to Mariano Absatz and Daniel Mario Vega for the link to
-# the original scanned proposal, where the dates and the zero hours are
-# clear and unambiguous...This is the article about final approval:
-# <a href="http://www.lanacion.com.ar/politica/nota.asp?nota_id=973996">
-# http://www.lanacion.com.ar/politica/nota.asp?nota_id=973996
-# </a>
-#
-# From Paul Eggert (2007-12-22):
-# For dates after mid-2008, the following rules are my guesses and
-# are quite possibly wrong, but are more likely than no DST at all.
-
-# From Alexander Krivenyshev (2008-09-05):
-# As per message from Carlos Alberto Fonseca Arauz (Nicaragua),
-# Argentina will start DST on Sunday October 19, 2008.
-#
-# <a href="http://www.worldtimezone.com/dst_news/dst_news_argentina03.html">
-# http://www.worldtimezone.com/dst_news/dst_news_argentina03.html
-# </a>
-# OR
-# <a href="http://www.impulsobaires.com.ar/nota.php?id=57832 (in spanish)">
-# http://www.impulsobaires.com.ar/nota.php?id=57832 (in spanish)
-# </a>
-
-# From Rodrigo Severo (2008-10-06):
-# Here is some info available at a Gentoo bug related to TZ on Argentina's DST:
-# ...
-# ------- Comment #1 from [jmdocile]  2008-10-06 16:28 0000 -------
-# Hi, there is a problem with timezone-data-2008e and maybe with
-# timezone-data-2008f
-# Argentinian law [Number] 25.155 is no longer valid.
-# <a href="http://www.infoleg.gov.ar/infolegInternet/anexos/60000-64999/60036/norma.htm">
-# http://www.infoleg.gov.ar/infolegInternet/anexos/60000-64999/60036/norma.htm
-# </a>
-# The new one is law [Number] 26.350
-# <a href="http://www.infoleg.gov.ar/infolegInternet/anexos/135000-139999/136191/norma.htm">
-# http://www.infoleg.gov.ar/infolegInternet/anexos/135000-139999/136191/norma.htm
-# </a>
-# So there is no summer time in Argentina for now.
-
-Rule	Arg	2007	only	-	Dec	30	0:00	1:00	S
-Rule	Arg	2008	max	-	Mar	Sun>=15	0:00	0	-
-Rule	Arg	2008	max	-	Oct	Sun>=15	0:00	1:00	S
- 
-# From Mariano Absatz (2004-05-21):
-# Today it was officially published that the Province of Mendoza is changing
-# its timezone this winter... starting tomorrow night....
-# http://www.gobernac.mendoza.gov.ar/boletin/pdf/20040521-27158-normas.pdf
-# From Paul Eggert (2004-05-24):
-# It's Law No. 7,210.  This change is due to a public power emergency, so for
-# now we'll assume it's for this year only.
-#
-# From Paul Eggert (2006-03-22):
-# <a href="http://www.spicasc.net/horvera.html">
-# Hora de verano para la Republica Argentina (2003-06-08)
-# </a> says that standard time in Argentina from 1894-10-31
-# to 1920-05-01 was -4:16:48.25.  Go with this more-precise value
-# over Shanks & Pottenger.
-#
-# From Mariano Absatz (2004-06-05):
-# These media articles from a major newspaper mostly cover the current state:
-# http://www.lanacion.com.ar/04/05/27/de_604825.asp
-# http://www.lanacion.com.ar/04/05/28/de_605203.asp
-#
-# The following eight (8) provinces pulled clocks back to UTC-04:00 at
-# midnight Monday May 31st. (that is, the night between 05/31 and 06/01).
-# Apparently, all nine provinces would go back to UTC-03:00 at the same
-# time in October 17th.
-#
-# Catamarca, Chubut, La Rioja, San Juan, San Luis, Santa Cruz,
-# Tierra del Fuego, Tucuman.
-#
-# From Mariano Absatz (2004-06-14):
-# ... this weekend, the Province of Tucuman decided it'd go back to UTC-03:00
-# yesterday midnight (that is, at 24:00 Saturday 12th), since the people's
-# annoyance with the change is much higher than the power savings obtained....
-#
-# From Gwillim Law (2004-06-14):
-# http://www.lanacion.com.ar/04/06/10/de_609078.asp ...
-#     "The time change in Tierra del Fuego was a conflicted decision from
-#   the start.  The government had decreed that the measure would take
-#   effect on June 1, but a normative error forced the new time to begin
-#   three days earlier, from a Saturday to a Sunday....
-# Our understanding was that the change was originally scheduled to take place
-# on June 1 at 00:00 in Chubut, Santa Cruz, Tierra del Fuego (and some other
-# provinces).  Sunday was May 30, only two days earlier.  So the article
-# contains a contradiction.  I would give more credence to the Saturday/Sunday
-# date than the "three days earlier" phrase, and conclude that Tierra del
-# Fuego set its clocks back at 2004-05-30 00:00.
-#
-# From Steffen Thorsen (2004-10-05):
-# The previous law 7210 which changed the province of Mendoza's time zone
-# back in May have been modified slightly in a new law 7277, which set the
-# new end date to 2004-09-26 (original date was 2004-10-17).
-# http://www.gobernac.mendoza.gov.ar/boletin/pdf/20040924-27244-normas.pdf
-#
-# From Mariano Absatz (2004-10-05):
-# San Juan changed from UTC-03:00 to UTC-04:00 at midnight between
-# Sunday, May 30th and Monday, May 31st.  It changed back to UTC-03:00
-# at midnight between Saturday, July 24th and Sunday, July 25th....
-# http://www.sanjuan.gov.ar/prensa/archivo/000329.html
-# http://www.sanjuan.gov.ar/prensa/archivo/000426.html
-# http://www.sanjuan.gov.ar/prensa/archivo/000441.html
-
-# From Alex Krivenyshev (2008-01-17):
-# Here are articles that Argentina Province San Luis is planning to end DST
-# as earlier as upcoming Monday January 21, 2008 or February 2008:
-#
-# Provincia argentina retrasa reloj y marca diferencia con resto del pais
-# (Argentine Province delayed clock and mark difference with the rest of the
-# country)
-# <a href="http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel">
-# http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel
-# </a>
-#
-# Es inminente que en San Luis atrasen una hora los relojes
-# (It is imminent in San Luis clocks one hour delay)
-# <a href="http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414">
-# http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414
-# </a>
-#
-# <a href="http://www.worldtimezone.net/dst_news/dst_news_argentina02.html">
-# http://www.worldtimezone.net/dst_news/dst_news_argentina02.html
-# </a>
-
-# From Jesper Norgaard Welen (2008-01-18):
-# The page of the San Luis provincial government
-# <a href="http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812">
-# http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812
-# </a>
-# confirms what Alex Krivenyshev has earlier sent to the tz
-# emailing list about that San Luis plans to return to standard
-# time much earlier than the rest of the country. It also
-# confirms that upon request the provinces San Juan and Mendoza 
-# refused to follow San Luis in this change. 
-# 
-# The change is supposed to take place Monday the 21.st at 0:00
-# hours. As far as I understand it if this goes ahead, we need
-# a new timezone for San Luis (although there are also documented
-# independent changes in the southamerica file of San Luis in
-# 1990 and 1991 which has not been confirmed).
-
-# From Jesper Norgaard Welen (2008-01-25):
-# Unfortunately the below page has become defunct, about the San Luis
-# time change. Perhaps because it now is part of a group of pages "Most
-# important pages of 2008."
-#
-# You can use
-# <a href="http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834">
-# http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834
-# </a>
-# instead it seems. Or use "Buscador" from the main page of the San Luis
-# government, and fill in "huso" and click OK, and you will get 3 pages
-# from which the first one is identical to the above.
-
-# From Mariano Absatz (2008-01-28):
-# I can confirm that the Province of San Luis (and so far only that
-# province) decided to go back to UTC-3 effective midnight Jan 20th 2008
-# (that is, Monday 21st at 0:00 is the time the clocks were delayed back
-# 1 hour), and they intend to keep UTC-3 as their timezone all year round
-# (that is, unless they change their mind any minute now).
-#
-# So we'll have to add yet another city to 'southamerica' (I think San
-# Luis city is the mos populated city in the Province, so it'd be
-# America/Argentina/San_Luis... of course I can't remember if San Luis's
-# history of particular changes goes along with Mendoza or San Juan :-(
-# (I only remember not being able to collect hard facts about San Luis
-# back in 2004, when these provinces changed to UTC-4 for a few days, I
-# mailed them personally and never got an answer).
-
-# From Paul Eggert (2008-06-30):
-# Unless otherwise specified, data are from Shanks & Pottenger through 1992,
-# from the IATA otherwise.  As noted below, Shanks & Pottenger say that
-# America/Cordoba split into 6 subregions during 1991/1992, one of which
-# was America/San_Luis, but we haven't verified this yet so for now we'll
-# keep America/Cordoba a single region rather than splitting it into the
-# other 5 subregions.
-
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-#
-# Buenos Aires (BA), Capital Federal (CF),
-Zone America/Argentina/Buenos_Aires -3:53:48 - LMT 1894 Oct 31
-			-4:16:48 -	CMT	1920 May # Cordoba Mean Time
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	Arg	AR%sT
-#
-# Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN), Chaco (CC),
-# Formosa (FM), Salta (SA), Santiago del Estero (SE), Cordoba (CB),
-# La Pampa (LP), Neuquen (NQ), Rio Negro (RN)
-#
-# Shanks & Pottenger also make the following claims, which we haven't verified:
-# - Formosa switched to -3:00 on 1991-01-07.
-# - Misiones switched to -3:00 on 1990-12-29.
-# - Chaco switched to -3:00 on 1991-01-04.
-# - Santiago del Estero switched to -4:00 on 1991-04-01,
-#   then to -3:00 on 1991-04-26.
-#
-Zone America/Argentina/Cordoba -4:16:48 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1991 Mar  3
-			-4:00	-	WART	1991 Oct 20
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	Arg	AR%sT
-#
-# Tucuman (TM)
-Zone America/Argentina/Tucuman -4:20:52 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1991 Mar  3
-			-4:00	-	WART	1991 Oct 20
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 Jun  1
-			-4:00	-	WART	2004 Jun 13
-			-3:00	Arg	AR%sT
-#
-# La Rioja (LR)
-Zone America/Argentina/La_Rioja -4:27:24 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1991 Mar  1
-			-4:00	-	WART	1991 May  7
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 Jun  1
-			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
-#
-# San Juan (SJ)
-Zone America/Argentina/San_Juan -4:34:04 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1991 Mar  1
-			-4:00	-	WART	1991 May  7
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 May 31
-			-4:00	-	WART	2004 Jul 25
-			-3:00	Arg	AR%sT
-#
-# Jujuy (JY)
-Zone America/Argentina/Jujuy -4:21:12 -	LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1990 Mar  4
-			-4:00	-	WART	1990 Oct 28
-			-4:00	1:00	WARST	1991 Mar 17
-			-4:00	-	WART	1991 Oct  6
-			-3:00	1:00	ARST	1992
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	Arg	AR%sT
-#
-# Catamarca (CT), Chubut (CH)
-Zone America/Argentina/Catamarca -4:23:08 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1991 Mar  3
-			-4:00	-	WART	1991 Oct 20
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 Jun  1
-			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
-#
-# Mendoza (MZ)
-Zone America/Argentina/Mendoza -4:35:16 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1990 Mar  4
-			-4:00	-	WART	1990 Oct 15
-			-4:00	1:00	WARST	1991 Mar  1
-			-4:00	-	WART	1991 Oct 15
-			-4:00	1:00	WARST	1992 Mar  1
-			-4:00	-	WART	1992 Oct 18
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 May 23
-			-4:00	-	WART	2004 Sep 26
-			-3:00	Arg	AR%sT
-#
-# San Luis (SL)
-Zone America/Argentina/San_Luis -4:25:24 - LMT	1894 Oct 31
-			-4:16:48 -	CMT	1920 May
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1990
-			-3:00	1:00	ARST	1990 Mar 14
-			-4:00	-	WART	1990 Oct 15
-			-4:00	1:00	WARST	1991 Mar  1
-			-4:00	-	WART	1991 Jun  1
-			-3:00	-	ART	1999 Oct  3
-			-4:00	1:00	WARST	2000 Mar  3
-			-3:00	-	ART	2004 May 31
-			-4:00	-	WART	2004 Jul 25
-			-3:00	Arg	AR%sT	2008 Jan 21
-			-3:00	-	ART
-#
-# Santa Cruz (SC)
-Zone America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 Oct 31
-			-4:16:48 -	CMT	1920 May # Cordoba Mean Time
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 Jun  1
-			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
-#
-# Tierra del Fuego, Antartida e Islas del Atlantico Sur (TF)
-Zone America/Argentina/Ushuaia -4:33:12 - LMT 1894 Oct 31
-			-4:16:48 -	CMT	1920 May # Cordoba Mean Time
-			-4:00	-	ART	1930 Dec
-			-4:00	Arg	AR%sT	1969 Oct  5
-			-3:00	Arg	AR%sT	1999 Oct  3
-			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	-	ART	2004 May 30
-			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
-
-# Aruba
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Aruba	-4:40:24 -	LMT	1912 Feb 12	# Oranjestad
-			-4:30	-	ANT	1965 # Netherlands Antilles Time
-			-4:00	-	AST
-
-# Bolivia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/La_Paz	-4:32:36 -	LMT	1890
-			-4:32:36 -	CMT	1931 Oct 15 # Calamarca MT
-			-4:32:36 1:00	BOST	1932 Mar 21 # Bolivia ST
-			-4:00	-	BOT	# Bolivia Time
-
-# Brazil
-
-# From Paul Eggert (1993-11-18):
-# The mayor of Rio recently attempted to change the time zone rules
-# just in his city, in order to leave more summer time for the tourist trade.
-# The rule change lasted only part of the day;
-# the federal government refused to follow the city's rules, and business
-# was in a chaos, so the mayor backed down that afternoon.
-
-# From IATA SSIM (1996-02):
-# _Only_ the following states in BR1 observe DST: Rio Grande do Sul (RS),
-# Santa Catarina (SC), Parana (PR), Sao Paulo (SP), Rio de Janeiro (RJ),
-# Espirito Santo (ES), Minas Gerais (MG), Bahia (BA), Goias (GO),
-# Distrito Federal (DF), Tocantins (TO), Sergipe [SE] and Alagoas [AL].
-# [The last three states are new to this issue of the IATA SSIM.]
-
-# From Gwillim Law (1996-10-07):
-# Geography, history (Tocantins was part of Goias until 1989), and other
-# sources of time zone information lead me to believe that AL, SE, and TO were
-# always in BR1, and so the only change was whether or not they observed DST....
-# The earliest issue of the SSIM I have is 2/91.  Each issue from then until
-# 9/95 says that DST is observed only in the ten states I quoted from 9/95,
-# along with Mato Grosso (MT) and Mato Grosso do Sul (MS), which are in BR2
-# (UTC-4)....  The other two time zones given for Brazil are BR3, which is
-# UTC-5, no DST, and applies only in the state of Acre (AC); and BR4, which is
-# UTC-2, and applies to Fernando de Noronha (formerly FN, but I believe it's
-# become part of the state of Pernambuco).  The boundary between BR1 and BR2
-# has never been clearly stated.  They've simply been called East and West.
-# However, some conclusions can be drawn from another IATA manual: the Airline
-# Coding Directory, which lists close to 400 airports in Brazil.  For each
-# airport it gives a time zone which is coded to the SSIM.  From that
-# information, I'm led to conclude that the states of Amapa (AP), Ceara (CE),
-# Maranhao (MA), Paraiba (PR), Pernambuco (PE), Piaui (PI), and Rio Grande do
-# Norte (RN), and the eastern part of Para (PA) are all in BR1 without DST.
-
-# From Marcos Tadeu (1998-09-27):
-# <a href="http://pcdsh01.on.br/verao1.html">
-# Brazilian official page
-# </a>
-
-# From Jesper Norgaard (2000-11-03):
-# [For an official list of which regions in Brazil use which time zones, see:]
-# http://pcdsh01.on.br/Fusbr.htm
-# http://pcdsh01.on.br/Fusbrhv.htm
-
-# From Celso Doria via David Madeo (2002-10-09):
-# The reason for the delay this year has to do with elections in Brazil.
-#
-# Unlike in the United States, elections in Brazil are 100% computerized and
-# the results are known almost immediately.  Yesterday, it was the first
-# round of the elections when 115 million Brazilians voted for President,
-# Governor, Senators, Federal Deputies, and State Deputies.  Nobody is
-# counting (or re-counting) votes anymore and we know there will be a second
-# round for the Presidency and also for some Governors.  The 2nd round will
-# take place on October 27th.
-#
-# The reason why the DST will only begin November 3rd is that the thousands
-# of electoral machines used cannot have their time changed, and since the
-# Constitution says the elections must begin at 8:00 AM and end at 5:00 PM,
-# the Government decided to postpone DST, instead of changing the Constitution
-# (maybe, for the next elections, it will be possible to change the clock)...
-
-# From Rodrigo Severo (2004-10-04):
-# It's just the biannual change made necessary by the much hyped, supposedly
-# modern Brazilian eletronic voting machines which, apparently, can't deal
-# with a time change between the first and the second rounds of the elections.
-
-# From Steffen Thorsen (2007-09-20):
-# Brazil will start DST on 2007-10-14 00:00 and end on 2008-02-17 00:00:
-# http://www.mme.gov.br/site/news/detail.do;jsessionid=BBA06811AFCAAC28F0285210913513DA?newsId=13975
-
-# From Paul Schulze (2008-06-24):
-# ...by law number 11.662 of April 24, 2008 (published in the "Diario
-# Oficial da Uniao"...) in Brazil there are changes in the timezones,
-# effective today (00:00am at June 24, 2008) as follows:
-#
-# a) The timezone UTC+5 is e[x]tinguished, with all the Acre state and the
-# part of the Amazonas state that had this timezone now being put to the
-# timezone UTC+4
-# b) The whole Para state now is put at timezone UTC+3, instead of just
-# part of it, as was before.
-#
-# This change follows a proposal of senator Tiao Viana of Acre state, that
-# proposed it due to concerns about open television channels displaying
-# programs inappropriate to youths in the states that had the timezone
-# UTC+5 too early in the night. In the occasion, some more corrections
-# were proposed, trying to unify the timezones of any given state. This
-# change modifies timezone rules defined in decree 2.784 of 18 June,
-# 1913.
-
-# From Rodrigo Severo (2008-06-24):
-# Just correcting the URL:
-# <a href="https://www.in.gov.br/imprensa/visualiza/index.jsp?jornal=3Ddo&secao=3D1&pagina=3D1&data=3D25/04/2008">
-# https://www.in.gov.br/imprensa/visualiza/index.jsp?jornal=3Ddo&secao=3D1&pagina=3D1&data=3D25/04/2008
-# </a>
-#
-# As a result of the above Decree I believe the America/Rio_Branco
-# timezone shall be modified from UTC-5 to UTC-4 and a new timezone shall
-# be created to represent the the west side of the Para State. I
-# suggest this new timezone be called Santarem as the most
-# important/populated city in the affected area.
-#
-# This new timezone would be the same as the Rio_Branco timezone up to
-# the 2008/06/24 change which would be to UTC-3 instead of UTC-4.
-
-# From Alex Krivenyshev (2008-06-24):
-# This is a quick reference page for New and Old Brazil Time Zones map.
-# <a href="http://www.worldtimezone.com/brazil-time-new-old.php">
-# http://www.worldtimezone.com/brazil-time-new-old.php
-# </a>
-#
-# - 4 time zones replaced by 3 time zones-eliminating time zone UTC- 05
-# (state Acre and the part of the Amazonas will be UTC/GMT- 04) - western
-# part of Par state is moving to one timezone UTC- 03 (from UTC -04).
-
-# From Paul Eggert (2002-10-10):
-# The official decrees referenced below are mostly taken from
-# <a href="http://pcdsh01.on.br/DecHV.html">
-# Decretos sobre o Horario de Verao no Brasil
-# </a>.
-
-# From Steffen Thorsen (2008-08-29):
-# As announced by the government and many newspapers in Brazil late
-# yesterday, Brazil will start DST on 2008-10-19 (need to change rule) and
-# it will end on 2009-02-15 (current rule for Brazil is fine). Based on
-# past years experience with the elections, there was a good chance that
-# the start was postponed to November, but it did not happen this year.
-#
-# It has not yet been posted to http://pcdsh01.on.br/DecHV.html
-#
-# An official page about it:
-# <a href="http://www.mme.gov.br/site/news/detail.do?newsId=16722">
-# http://www.mme.gov.br/site/news/detail.do?newsId=16722
-# </a>
-# Note that this link does not always work directly, but must be accessed
-# by going to
-# <a href="http://www.mme.gov.br/first">
-# http://www.mme.gov.br/first
-# </a>
-#
-# One example link that works directly:
-# <a href="http://jornale.com.br/index.php?option=com_content&task=view&id=13530&Itemid=54">
-# http://jornale.com.br/index.php?option=com_content&task=view&id=13530&Itemid=54
-# (Portuguese)
-# </a>
-#
-# We have a written a short article about it as well:
-# <a href="http://www.timeanddate.com/news/time/brazil-dst-2008-2009.html">
-# http://www.timeanddate.com/news/time/brazil-dst-2008-2009.html
-# </a>
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Decree <a href="http://pcdsh01.on.br/HV20466.htm">20,466</a> (1931-10-01)
-# Decree <a href="http://pcdsh01.on.br/HV21896.htm">21,896</a> (1932-01-10)
-Rule	Brazil	1931	only	-	Oct	 3	11:00	1:00	S
-Rule	Brazil	1932	1933	-	Apr	 1	 0:00	0	-
-Rule	Brazil	1932	only	-	Oct	 3	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/HV23195.htm">23,195</a> (1933-10-10)
-# revoked DST.
-# Decree <a href="http://pcdsh01.on.br/HV27496.htm">27,496</a> (1949-11-24)
-# Decree <a href="http://pcdsh01.on.br/HV27998.htm">27,998</a> (1950-04-13)
-Rule	Brazil	1949	1952	-	Dec	 1	 0:00	1:00	S
-Rule	Brazil	1950	only	-	Apr	16	 1:00	0	-
-Rule	Brazil	1951	1952	-	Apr	 1	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV32308.htm">32,308</a> (1953-02-24)
-Rule	Brazil	1953	only	-	Mar	 1	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV34724.htm">34,724</a> (1953-11-30)
-# revoked DST.
-# Decree <a href="http://pcdsh01.on.br/HV52700.htm">52,700</a> (1963-10-18)
-# established DST from 1963-10-23 00:00 to 1964-02-29 00:00
-# in SP, RJ, GB, MG, ES, due to the prolongation of the drought.
-# Decree <a href="http://pcdsh01.on.br/HV53071.htm">53,071</a> (1963-12-03)
-# extended the above decree to all of the national territory on 12-09.
-Rule	Brazil	1963	only	-	Dec	 9	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/HV53604.htm">53,604</a> (1964-02-25)
-# extended summer time by one day to 1964-03-01 00:00 (start of school).
-Rule	Brazil	1964	only	-	Mar	 1	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV55639.htm">55,639</a> (1965-01-27)
-Rule	Brazil	1965	only	-	Jan	31	 0:00	1:00	S
-Rule	Brazil	1965	only	-	Mar	31	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV57303.htm">57,303</a> (1965-11-22)
-Rule	Brazil	1965	only	-	Dec	 1	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/HV57843.htm">57,843</a> (1966-02-18)
-Rule	Brazil	1966	1968	-	Mar	 1	 0:00	0	-
-Rule	Brazil	1966	1967	-	Nov	 1	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/HV63429.htm">63,429</a> (1968-10-15)
-# revoked DST.
-# Decree <a href="http://pcdsh01.on.br/HV91698.htm">91,698</a> (1985-09-27)
-Rule	Brazil	1985	only	-	Nov	 2	 0:00	1:00	S
-# Decree 92,310 (1986-01-21)
-# Decree 92,463 (1986-03-13)
-Rule	Brazil	1986	only	-	Mar	15	 0:00	0	-
-# Decree 93,316 (1986-10-01)
-Rule	Brazil	1986	only	-	Oct	25	 0:00	1:00	S
-Rule	Brazil	1987	only	-	Feb	14	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV94922.htm">94,922</a> (1987-09-22)
-Rule	Brazil	1987	only	-	Oct	25	 0:00	1:00	S
-Rule	Brazil	1988	only	-	Feb	 7	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV96676.htm">96,676</a> (1988-09-12)
-# except for the states of AC, AM, PA, RR, RO, and AP (then a territory)
-Rule	Brazil	1988	only	-	Oct	16	 0:00	1:00	S
-Rule	Brazil	1989	only	-	Jan	29	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV98077.htm">98,077</a> (1989-08-21)
-# with the same exceptions
-Rule	Brazil	1989	only	-	Oct	15	 0:00	1:00	S
-Rule	Brazil	1990	only	-	Feb	11	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV99530.htm">99,530</a> (1990-09-17)
-# adopted by RS, SC, PR, SP, RJ, ES, MG, GO, MS, DF.
-# Decree 99,629 (1990-10-19) adds BA, MT.
-Rule	Brazil	1990	only	-	Oct	21	 0:00	1:00	S
-Rule	Brazil	1991	only	-	Feb	17	 0:00	0	-
-# <a href="http://pcdsh01.on.br/HV1991.htm">Unnumbered decree</a> (1991-09-25)
-# adopted by RS, SC, PR, SP, RJ, ES, MG, BA, GO, MT, MS, DF.
-Rule	Brazil	1991	only	-	Oct	20	 0:00	1:00	S
-Rule	Brazil	1992	only	-	Feb	 9	 0:00	0	-
-# <a href="http://pcdsh01.on.br/HV1992.htm">Unnumbered decree</a> (1992-10-16)
-# adopted by same states.
-Rule	Brazil	1992	only	-	Oct	25	 0:00	1:00	S
-Rule	Brazil	1993	only	-	Jan	31	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV942.htm">942</a> (1993-09-28)
-# adopted by same states, plus AM.
-# Decree <a href="http://pcdsh01.on.br/HV1252.htm">1,252</a> (1994-09-22;
-# web page corrected 2004-01-07) adopted by same states, minus AM.
-# Decree <a href="http://pcdsh01.on.br/HV1636.htm">1,636</a> (1995-09-14)
-# adopted by same states, plus MT and TO.
-# Decree <a href="http://pcdsh01.on.br/HV1674.htm">1,674</a> (1995-10-13)
-# adds AL, SE.
-Rule	Brazil	1993	1995	-	Oct	Sun>=11	 0:00	1:00	S
-Rule	Brazil	1994	1995	-	Feb	Sun>=15	 0:00	0	-
-Rule	Brazil	1996	only	-	Feb	11	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/HV2000.htm">2,000</a> (1996-09-04)
-# adopted by same states, minus AL, SE.
-Rule	Brazil	1996	only	-	Oct	 6	 0:00	1:00	S
-Rule	Brazil	1997	only	-	Feb	16	 0:00	0	-
-# From Daniel C. Sobral (1998-02-12):
-# In 1997, the DS began on October 6. The stated reason was that
-# because international television networks ignored Brazil's policy on DS,
-# they bought the wrong times on satellite for coverage of Pope's visit.
-# This year, the ending date of DS was postponed to March 1
-# to help dealing with the shortages of electric power.
-#
-# Decree 2,317 (1997-09-04), adopted by same states.
-Rule	Brazil	1997	only	-	Oct	 6	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/figuras/HV2495.JPG">2,495</a>
-# (1998-02-10)
-Rule	Brazil	1998	only	-	Mar	 1	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/figuras/Hv98.jpg">2,780</a> (1998-09-11)
-# adopted by the same states as before.
-Rule	Brazil	1998	only	-	Oct	11	 0:00	1:00	S
-Rule	Brazil	1999	only	-	Feb	21	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/figuras/HV3150.gif">3,150</a>
-# (1999-08-23) adopted by same states.
-# Decree <a href="http://pcdsh01.on.br/DecHV99.gif">3,188</a> (1999-09-30)
-# adds SE, AL, PB, PE, RN, CE, PI, MA and RR.
-Rule	Brazil	1999	only	-	Oct	 3	 0:00	1:00	S
-Rule	Brazil	2000	only	-	Feb	27	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/DEC3592.htm">3,592</a> (2000-09-06)
-# adopted by the same states as before.
-# Decree <a href="http://pcdsh01.on.br/Dec3630.jpg">3,630</a> (2000-10-13)
-# repeals DST in PE and RR, effective 2000-10-15 00:00.
-# Decree <a href="http://pcdsh01.on.br/Dec3632.jpg">3,632</a> (2000-10-17)
-# repeals DST in SE, AL, PB, RN, CE, PI and MA, effective 2000-10-22 00:00.
-# Decree <a href="http://pcdsh01.on.br/figuras/HV3916.gif">3,916</a>
-# (2001-09-13) reestablishes DST in AL, CE, MA, PB, PE, PI, RN, SE.
-Rule	Brazil	2000	2001	-	Oct	Sun>=8	 0:00	1:00	S
-Rule	Brazil	2001	2006	-	Feb	Sun>=15	 0:00	0	-
-# Decree 4,399 (2002-10-01) repeals DST in AL, CE, MA, PB, PE, PI, RN, SE.
-# <a href="http://www.presidencia.gov.br/CCIVIL/decreto/2002/D4399.htm">4,399</a>
-Rule	Brazil	2002	only	-	Nov	 3	 0:00	1:00	S
-# Decree 4,844 (2003-09-24; corrected 2003-09-26) repeals DST in BA, MT, TO.
-# <a href="http://www.presidencia.gov.br/CCIVIL/decreto/2003/D4844.htm">4,844</a>
-Rule	Brazil	2003	only	-	Oct	19	 0:00	1:00	S
-# Decree 5,223 (2004-10-01) reestablishes DST in MT.
-# <a href="http://www.planalto.gov.br/ccivil_03/_Ato2004-2006/2004/Decreto/D5223.htm">5,223</a>
-Rule	Brazil	2004	only	-	Nov	 2	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/DecHV5539.gif">5,539</a> (2005-09-19),
-# adopted by the same states as before.
-Rule	Brazil	2005	only	-	Oct	16	 0:00	1:00	S
-# Decree <a href="http://pcdsh01.on.br/DecHV5920.gif">5,920</a> (2006-10-03),
-# adopted by the same states as before.
-Rule	Brazil	2006	only	-	Nov	 5	 0:00	1:00	S
-Rule	Brazil	2007	only	-	Feb	25	 0:00	0	-
-# Decree <a href="http://pcdsh01.on.br/DecHV6212.gif">6,212</a> (2007-09-26),
-# adopted by the same states as before.
-Rule	Brazil	2007	only	-	Oct	Sun>=8	 0:00	1:00	S
-# From Frederico A. C. Neves (2008-09-10):
-# Acording to this decree
-# <a href="http://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm">
-# http://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm
-# </a>
-# [t]he DST period in Brazil now on will be from the 3rd Oct Sunday to the
-# 3rd Feb Sunday. There is an exception on the return date when this is
-# the Carnival Sunday then the return date will be the next Sunday...
-Rule	Brazil	2008	max	-	Oct	Sun>=15	0:00	1:00	S
-Rule	Brazil	2008	2011	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2012	only	-	Feb	Sun>=22	0:00	0	-
-Rule	Brazil	2013	2014	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2015	only	-	Feb	Sun>=22	0:00	0	-
-Rule	Brazil	2016	2022	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2023	only	-	Feb	Sun>=22	0:00	0	-
-Rule	Brazil	2024	2025	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2026	only	-	Feb	Sun>=22	0:00	0	-
-Rule	Brazil	2027	2033	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2034	only	-	Feb	Sun>=22	0:00	0	-
-Rule	Brazil	2035	2036	-	Feb	Sun>=15	0:00	0	-
-Rule	Brazil	2037	only	-	Feb	Sun>=22	0:00	0	-
-# From Arthur David Olson (2008-09-29):
-# The next is wrong in some years but is better than nothing.
-Rule	Brazil	2038	max	-	Feb	Sun>=15	0:00	0	-
-
-# The latest ruleset listed above says that the following states observe DST:
-# DF, ES, GO, MG, MS, MT, PR, RJ, RS, SC, SP.
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-#
-# Fernando de Noronha (administratively part of PE)
-Zone America/Noronha	-2:09:40 -	LMT	1914
-			-2:00	Brazil	FN%sT	1990 Sep 17
-			-2:00	-	FNT	1999 Sep 30
-			-2:00	Brazil	FN%sT	2000 Oct 15
-			-2:00	-	FNT	2001 Sep 13
-			-2:00	Brazil	FN%sT	2002 Oct  1
-			-2:00	-	FNT
-# Other Atlantic islands have no permanent settlement.
-# These include Trindade and Martin Vaz (administratively part of ES),
-# Atol das Rocas (RN), and Penedos de Sao Pedro e Sao Paulo (PE).
-# Fernando de Noronha was a separate territory from 1942-09-02 to 1989-01-01;
-# it also included the Penedos.
-#
-# Amapa (AP), east Para (PA)
-# East Para includes Belem, Maraba, Serra Norte, and Sao Felix do Xingu.
-# The division between east and west Para is the river Xingu.
-# In the north a very small part from the river Javary (now Jari I guess,
-# the border with Amapa) to the Amazon, then to the Xingu.
-Zone America/Belem	-3:13:56 -	LMT	1914
-			-3:00	Brazil	BR%sT	1988 Sep 12
-			-3:00	-	BRT
-#
-# west Para (PA)
-# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem.
-Zone America/Santarem	-3:38:48 -	LMT	1914
-			-4:00	Brazil	AM%sT	1988 Sep 12
-			-4:00	-	AMT	2008 Jun 24 00:00
-			-3:00	-	BRT
-#
-# Maranhao (MA), Piaui (PI), Ceara (CE), Rio Grande do Norte (RN),
-# Paraiba (PB)
-Zone America/Fortaleza	-2:34:00 -	LMT	1914
-			-3:00	Brazil	BR%sT	1990 Sep 17
-			-3:00	-	BRT	1999 Sep 30
-			-3:00	Brazil	BR%sT	2000 Oct 22
-			-3:00	-	BRT	2001 Sep 13
-			-3:00	Brazil	BR%sT	2002 Oct  1
-			-3:00	-	BRT
-#
-# Pernambuco (PE) (except Atlantic islands)
-Zone America/Recife	-2:19:36 -	LMT	1914
-			-3:00	Brazil	BR%sT	1990 Sep 17
-			-3:00	-	BRT	1999 Sep 30
-			-3:00	Brazil	BR%sT	2000 Oct 15
-			-3:00	-	BRT	2001 Sep 13
-			-3:00	Brazil	BR%sT	2002 Oct  1
-			-3:00	-	BRT
-#
-# Tocantins (TO)
-Zone America/Araguaina	-3:12:48 -	LMT	1914
-			-3:00	Brazil	BR%sT	1990 Sep 17
-			-3:00	-	BRT	1995 Sep 14
-			-3:00	Brazil	BR%sT	2003 Sep 24
-			-3:00	-	BRT
-#
-# Alagoas (AL), Sergipe (SE)
-Zone America/Maceio	-2:22:52 -	LMT	1914
-			-3:00	Brazil	BR%sT	1990 Sep 17
-			-3:00	-	BRT	1995 Oct 13
-			-3:00	Brazil	BR%sT	1996 Sep  4
-			-3:00	-	BRT	1999 Sep 30
-			-3:00	Brazil	BR%sT	2000 Oct 22
-			-3:00	-	BRT	2001 Sep 13
-			-3:00	Brazil	BR%sT	2002 Oct  1
-			-3:00	-	BRT
-#
-# Bahia (BA)
-# There are too many Salvadors elsewhere, so use America/Bahia instead
-# of America/Salvador.
-Zone America/Bahia	-2:34:04 -	LMT	1914
-			-3:00	Brazil	BR%sT	2003 Sep 24
-			-3:00	-	BRT
-#
-# Goias (GO), Distrito Federal (DF), Minas Gerais (MG),
-# Espirito Santo (ES), Rio de Janeiro (RJ), Sao Paulo (SP), Parana (PR),
-# Santa Catarina (SC), Rio Grande do Sul (RS)
-Zone America/Sao_Paulo	-3:06:28 -	LMT	1914
-			-3:00	Brazil	BR%sT	1963 Oct 23 00:00
-			-3:00	1:00	BRST	1964
-			-3:00	Brazil	BR%sT
-#
-# Mato Grosso do Sul (MS)
-Zone America/Campo_Grande -3:38:28 -	LMT	1914
-			-4:00	Brazil	AM%sT
-#
-# Mato Grosso (MT)
-Zone America/Cuiaba	-3:44:20 -	LMT	1914
-			-4:00	Brazil	AM%sT	2003 Sep 24
-			-4:00	-	AMT	2004 Oct  1
-			-4:00	Brazil	AM%sT
-#
-# Rondonia (RO)
-Zone America/Porto_Velho -4:15:36 -	LMT	1914
-			-4:00	Brazil	AM%sT	1988 Sep 12
-			-4:00	-	AMT
-#
-# Roraima (RR)
-Zone America/Boa_Vista	-4:02:40 -	LMT	1914
-			-4:00	Brazil	AM%sT	1988 Sep 12
-			-4:00	-	AMT	1999 Sep 30
-			-4:00	Brazil	AM%sT	2000 Oct 15
-			-4:00	-	AMT
-#
-# east Amazonas (AM): Boca do Acre, Jutai, Manaus, Floriano Peixoto
-# The great circle line from Tabatinga to Porto Acre divides
-# east from west Amazonas.
-Zone America/Manaus	-4:00:04 -	LMT	1914
-			-4:00	Brazil	AM%sT	1988 Sep 12
-			-4:00	-	AMT	1993 Sep 28
-			-4:00	Brazil	AM%sT	1994 Sep 22
-			-4:00	-	AMT
-#
-# west Amazonas (AM): Atalaia do Norte, Boca do Maoco, Benjamin Constant,
-#	Eirunepe, Envira, Ipixuna
-Zone America/Eirunepe	-4:39:28 -	LMT	1914
-			-5:00	Brazil	AC%sT	1988 Sep 12
-			-5:00	-	ACT	1993 Sep 28
-			-5:00	Brazil	AC%sT	1994 Sep 22
-			-5:00	-	ACT	2008 Jun 24 00:00
-			-4:00	-	AMT
-#
-# Acre (AC)
-Zone America/Rio_Branco	-4:31:12 -	LMT	1914
-			-5:00	Brazil	AC%sT	1988 Sep 12
-			-5:00	-	ACT	2008 Jun 24 00:00
-			-4:00	-	AMT
-
-# Chile
-
-# From Eduardo Krell (1995-10-19):
-# The law says to switch to DST at midnight [24:00] on the second SATURDAY
-# of October....  The law is the same for March and October.
-# (1998-09-29):
-# Because of the drought this year, the government decided to go into
-# DST earlier (saturday 9/26 at 24:00). This is a one-time change only ...
-# (unless there's another dry season next year, I guess).
-
-# From Julio I. Pacheco Troncoso (1999-03-18):
-# Because of the same drought, the government decided to end DST later,
-# on April 3, (one-time change).
-
-# From Oscar van Vlijmen (2006-10-08):
-# http://www.horaoficial.cl/cambio.htm
-
-# From Jesper Norgaard Welen (2006-10-08):
-# I think that there are some obvious mistakes in the suggested link
-# from Oscar van Vlijmen,... for instance entry 66 says that GMT-4
-# ended 1990-09-12 while entry 67 only begins GMT-3 at 1990-09-15
-# (they should have been 1990-09-15 and 1990-09-16 respectively), but
-# anyhow it clears up some doubts too.
-
-# From Paul Eggert (2006-12-27):
-# The following data for Chile and America/Santiago are from
-# <http://www.horaoficial.cl/horaof.htm> (2006-09-20), transcribed by
-# Jesper Norgaard Welen.  The data for Pacific/Easter are from Shanks
-# & Pottenger, except with DST transitions after 1932 cloned from
-# America/Santiago.  The pre-1980 Pacific/Easter data are dubious,
-# but we have no other source.
-
-# From German Poo-Caaman~o (2008-03-03):
-# Due to drought, Chile extends Daylight Time in three weeks.  This
-# is one-time change (Saturday 3/29 at 24:00 for America/Santiago
-# and Saturday 3/29 at 22:00 for Pacific/Easter)
-# The Supreme Decree is located at 
-# <a href="http://www.shoa.cl/servicios/supremo316.pdf">
-# http://www.shoa.cl/servicios/supremo316.pdf
-# </a>
-# and the instructions for 2008 are located in:
-# <a href="http://www.horaoficial.cl/cambio.htm">
-# http://www.horaoficial.cl/cambio.htm
-# </a>.
-
-# From Jose Miguel Garrido (2008-03-05):
-# ...
-# You could see the announces of the change on 
-# <a href="http://www.shoa.cl/noticias/2008/04hora/hora.htm">
-# http://www.shoa.cl/noticias/2008/04hora/hora.htm
-# </a>.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Chile	1927	1932	-	Sep	 1	0:00	1:00	S
-Rule	Chile	1928	1932	-	Apr	 1	0:00	0	-
-Rule	Chile	1942	only	-	Jun	 1	4:00u	0	-
-Rule	Chile	1942	only	-	Aug	 1	5:00u	1:00	S
-Rule	Chile	1946	only	-	Jul	15	4:00u	1:00	S
-Rule	Chile	1946	only	-	Sep	 1	3:00u	0:00	-
-Rule	Chile	1947	only	-	Apr	 1	4:00u	0	-
-Rule	Chile	1968	only	-	Nov	 3	4:00u	1:00	S
-Rule	Chile	1969	only	-	Mar	30	3:00u	0	-
-Rule	Chile	1969	only	-	Nov	23	4:00u	1:00	S
-Rule	Chile	1970	only	-	Mar	29	3:00u	0	-
-Rule	Chile	1971	only	-	Mar	14	3:00u	0	-
-Rule	Chile	1970	1972	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	1972	1986	-	Mar	Sun>=9	3:00u	0	-
-Rule	Chile	1973	only	-	Sep	30	4:00u	1:00	S
-Rule	Chile	1974	1987	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	1987	only	-	Apr	12	3:00u	0	-
-Rule	Chile	1988	1989	-	Mar	Sun>=9	3:00u	0	-
-Rule	Chile	1988	only	-	Oct	Sun>=1	4:00u	1:00	S
-Rule	Chile	1989	only	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	1990	only	-	Mar	18	3:00u	0	-
-Rule	Chile	1990	only	-	Sep	16	4:00u	1:00	S
-Rule	Chile	1991	1996	-	Mar	Sun>=9	3:00u	0	-
-Rule	Chile	1991	1997	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	1997	only	-	Mar	30	3:00u	0	-
-Rule	Chile	1998	only	-	Mar	Sun>=9	3:00u	0	-
-Rule	Chile	1998	only	-	Sep	27	4:00u	1:00	S
-Rule	Chile	1999	only	-	Apr	 4	3:00u	0	-
-Rule	Chile	1999	max	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	2000	2007	-	Mar	Sun>=9	3:00u	0	-
-# N.B.: the end of March 29 in Chile is March 30 in Universal time,
-# which is used below in specifying the transition.
-Rule	Chile	2008	only	-	Mar	30	3:00u	0	-
-Rule	Chile	2009	max	-	Mar	Sun>=9	3:00u	0	-
-# IATA SSIM anomalies: (1992-02) says 1992-03-14;
-# (1996-09) says 1998-03-08.  Ignore these.
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Santiago	-4:42:46 -	LMT	1890
-			-4:42:46 -	SMT	1910 	    # Santiago Mean Time
-			-5:00	-	CLT	1916 Jul  1 # Chile Time
-			-4:42:46 -	SMT	1918 Sep  1 # Santiago Mean Time
-			-4:00	-	CLT	1919 Jul  1 # Chile Time
-			-4:42:46 -	SMT	1927 Sep  1 # Santiago Mean Time
-			-5:00	Chile	CL%sT	1947 May 22 # Chile Time
-			-4:00	Chile	CL%sT
-Zone Pacific/Easter	-7:17:44 -	LMT	1890
-			-7:17:28 -	EMT	1932 Sep    # Easter Mean Time
-			-7:00	Chile	EAS%sT	1982 Mar 13 21:00 # Easter I Time
-			-6:00	Chile	EAS%sT
-#
-# Sala y Gomez Island is like Pacific/Easter.
-# Other Chilean locations, including Juan Fernandez Is, San Ambrosio,
-# San Felix, and Antarctic bases, are like America/Santiago.
-
-# Colombia
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	CO	1992	only	-	May	 3	0:00	1:00	S
-Rule	CO	1993	only	-	Apr	 4	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Bogota	-4:56:20 -	LMT	1884 Mar 13
-			-4:56:20 -	BMT	1914 Nov 23 # Bogota Mean Time
-			-5:00	CO	CO%sT	# Colombia Time
-# Malpelo, Providencia, San Andres
-# no information; probably like America/Bogota
-
-# Curacao
-#
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say that The Bottom and Philipsburg have been at
-# -4:00 since standard time was introduced on 1912-03-02; and that
-# Kralendijk and Rincon used Kralendijk Mean Time (-4:33:08) from
-# 1912-02-02 to 1965-01-01.  The former is dubious, since S&P also say
-# Saba Island has been like Curacao.
-# This all predates our 1970 cutoff, though.
-#
-# By July 2007 Curacao and St Maarten are planned to become
-# associated states within the Netherlands, much like Aruba;
-# Bonaire, Saba and St Eustatius would become directly part of the
-# Netherlands as Kingdom Islands.  This won't affect their time zones
-# though, as far as we know.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Curacao	-4:35:44 -	LMT	1912 Feb 12	# Willemstad
-			-4:30	-	ANT	1965 # Netherlands Antilles Time
-			-4:00	-	AST
-
-# Ecuador
-#
-# From Paul Eggert (2007-03-04):
-# Apparently Ecuador had a failed experiment with DST in 1992.
-# <http://midena.gov.ec/content/view/1261/208/> (2007-02-27) and
-# <http://www.hoy.com.ec/NoticiaNue.asp?row_id=249856> (2006-11-06) both
-# talk about "hora Sixto".  Leave this alone for now, as we have no data.
-#
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Guayaquil	-5:19:20 -	LMT	1890
-			-5:14:00 -	QMT	1931 # Quito Mean Time
-			-5:00	-	ECT	     # Ecuador Time
-Zone Pacific/Galapagos	-5:58:24 -	LMT	1931 # Puerto Baquerizo Moreno
-			-5:00	-	ECT	1986
-			-6:00	-	GALT	     # Galapagos Time
-
-# Falklands
-
-# From Paul Eggert (2006-03-22):
-# Between 1990 and 2000 inclusive, Shanks & Pottenger and the IATA agree except
-# the IATA gives 1996-09-08.  Go with Shanks & Pottenger.
-
-# From Falkland Islands Government Office, London (2001-01-22)
-# via Jesper Norgaard:
-# ... the clocks revert back to Local Mean Time at 2 am on Sunday 15
-# April 2001 and advance one hour to summer time at 2 am on Sunday 2
-# September.  It is anticipated that the clocks will revert back at 2
-# am on Sunday 21 April 2002 and advance to summer time at 2 am on
-# Sunday 1 September.
-
-# From Rives McDow (2001-02-13):
-#
-# I have communicated several times with people there, and the last
-# time I had communications that was helpful was in 1998.  Here is
-# what was said then:
-#
-# "The general rule was that Stanley used daylight saving and the Camp
-# did not. However for various reasons many people in the Camp have
-# started to use daylight saving (known locally as 'Stanley Time')
-# There is no rule as to who uses daylight saving - it is a matter of
-# personal choice and so it is impossible to draw a map showing who
-# uses it and who does not. Any list would be out of date as soon as
-# it was produced. This year daylight saving ended on April 18/19th
-# and started again on September 12/13th.  I do not know what the rule
-# is, but can find out if you like.  We do not change at the same time
-# as UK or Chile."
-#
-# I did have in my notes that the rule was "Second Saturday in Sep at
-# 0:00 until third Saturday in Apr at 0:00".  I think that this does
-# not agree in some cases with Shanks; is this true?
-#
-# Also, there is no mention in the list that some areas in the
-# Falklands do not use DST.  I have found in my communications there
-# that these areas are on the western half of East Falkland and all of
-# West Falkland.  Stanley is the only place that consistently observes
-# DST.  Again, as in other places in the world, the farmers don't like
-# it.  West Falkland is almost entirely sheep farmers.
-#
-# I know one lady there that keeps a list of which farm keeps DST and
-# which doesn't each year.  She runs a shop in Stanley, and says that
-# the list changes each year.  She uses it to communicate to her
-# customers, catching them when they are home for lunch or dinner.
-
-# From Paul Eggert (2001-03-05):
-# For now, we'll just record the time in Stanley, since we have no
-# better info.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Falk	1937	1938	-	Sep	lastSun	0:00	1:00	S
-Rule	Falk	1938	1942	-	Mar	Sun>=19	0:00	0	-
-Rule	Falk	1939	only	-	Oct	1	0:00	1:00	S
-Rule	Falk	1940	1942	-	Sep	lastSun	0:00	1:00	S
-Rule	Falk	1943	only	-	Jan	1	0:00	0	-
-Rule	Falk	1983	only	-	Sep	lastSun	0:00	1:00	S
-Rule	Falk	1984	1985	-	Apr	lastSun	0:00	0	-
-Rule	Falk	1984	only	-	Sep	16	0:00	1:00	S
-Rule	Falk	1985	2000	-	Sep	Sun>=9	0:00	1:00	S
-Rule	Falk	1986	2000	-	Apr	Sun>=16	0:00	0	-
-Rule	Falk	2001	max	-	Apr	Sun>=15	2:00	0	-
-Rule	Falk	2001	max	-	Sep	Sun>=1	2:00	1:00	S
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/Stanley	-3:51:24 -	LMT	1890
-			-3:51:24 -	SMT	1912 Mar 12  # Stanley Mean Time
-			-4:00	Falk	FK%sT	1983 May     # Falkland Is Time
-			-3:00	Falk	FK%sT	1985 Sep 15
-			-4:00	Falk	FK%sT
-
-# French Guiana
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Cayenne	-3:29:20 -	LMT	1911 Jul
-			-4:00	-	GFT	1967 Oct # French Guiana Time
-			-3:00	-	GFT
-
-# Guyana
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Guyana	-3:52:40 -	LMT	1915 Mar	# Georgetown
-			-3:45	-	GBGT	1966 May 26 # Br Guiana Time
-			-3:45	-	GYT	1975 Jul 31 # Guyana Time
-			-3:00	-	GYT	1991
-# IATA SSIM (1996-06) says -4:00.  Assume a 1991 switch.
-			-4:00	-	GYT
-
-# Paraguay
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say that spring transitions are from 01:00 -> 02:00,
-# and autumn transitions are from 00:00 -> 23:00.  Go with pre-1999
-# editions of Shanks, and with the IATA, who say transitions occur at 00:00.
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Para	1975	1988	-	Oct	 1	0:00	1:00	S
-Rule	Para	1975	1978	-	Mar	 1	0:00	0	-
-Rule	Para	1979	1991	-	Apr	 1	0:00	0	-
-Rule	Para	1989	only	-	Oct	22	0:00	1:00	S
-Rule	Para	1990	only	-	Oct	 1	0:00	1:00	S
-Rule	Para	1991	only	-	Oct	 6	0:00	1:00	S
-Rule	Para	1992	only	-	Mar	 1	0:00	0	-
-Rule	Para	1992	only	-	Oct	 5	0:00	1:00	S
-Rule	Para	1993	only	-	Mar	31	0:00	0	-
-Rule	Para	1993	1995	-	Oct	 1	0:00	1:00	S
-Rule	Para	1994	1995	-	Feb	lastSun	0:00	0	-
-Rule	Para	1996	only	-	Mar	 1	0:00	0	-
-# IATA SSIM (2000-02) says 1999-10-10; ignore this for now.
-# From Steffen Thorsen (2000-10-02):
-# I have three independent reports that Paraguay changed to DST this Sunday
-# (10-01).
-#
-# Translated by Gwillim Law (2001-02-27) from
-# <a href="http://www.diarionoticias.com.py/011000/nacional/naciona1.htm">
-# Noticias, a daily paper in Asuncion, Paraguay (2000-10-01)
-# </a>:
-# Starting at 0:00 today, the clock will be set forward 60 minutes, in
-# fulfillment of Decree No. 7,273 of the Executive Power....  The time change
-# system has been operating for several years.  Formerly there was a separate
-# decree each year; the new law has the same effect, but permanently.  Every
-# year, the time will change on the first Sunday of October; likewise, the
-# clock will be set back on the first Sunday of March.
-#
-Rule	Para	1996	2001	-	Oct	Sun>=1	0:00	1:00	S
-# IATA SSIM (1997-09) says Mar 1; go with Shanks & Pottenger.
-Rule	Para	1997	only	-	Feb	lastSun	0:00	0	-
-# Shanks & Pottenger say 1999-02-28; IATA SSIM (1999-02) says 1999-02-27, but
-# (1999-09) reports no date; go with above sources and Gerd Knops (2001-02-27).
-Rule	Para	1998	2001	-	Mar	Sun>=1	0:00	0	-
-# From Rives McDow (2002-02-28):
-# A decree was issued in Paraguay (no. 16350) on 2002-02-26 that changed the
-# dst method to be from the first Sunday in September to the first Sunday in
-# April.
-Rule	Para	2002	2004	-	Apr	Sun>=1	0:00	0	-
-Rule	Para	2002	2003	-	Sep	Sun>=1	0:00	1:00	S
-#
-# From Jesper Norgaard Welen (2005-01-02):
-# There are several sources that claim that Paraguay made
-# a timezone rule change in autumn 2004.
-# From Steffen Thorsen (2005-01-05):
-# Decree 1,867 (2004-03-05)
-# From Carlos Raul Perasso via Jesper Norgaard Welen (2006-10-13)
-# <http://www.presidencia.gov.py/decretos/D1867.pdf>
-Rule	Para	2004	max	-	Oct	Sun>=15	0:00	1:00	S
-Rule	Para	2005	max	-	Mar	Sun>=8	0:00	0	-
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Asuncion	-3:50:40 -	LMT	1890
-			-3:50:40 -	AMT	1931 Oct 10 # Asuncion Mean Time
-			-4:00	-	PYT	1972 Oct # Paraguay Time
-			-3:00	-	PYT	1974 Apr
-			-4:00	Para	PY%sT
-
-# Peru
-#
-# <a href="news:xrGmb.39935$gA1.13896113@news4.srv.hcvlny.cv.net">
-# From Evelyn C. Leeper via Mark Brader (2003-10-26):</a>
-# When we were in Peru in 1985-1986, they apparently switched over
-# sometime between December 29 and January 3 while we were on the Amazon.
-#
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger don't have this transition.  Assume 1986 was like 1987.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Peru	1938	only	-	Jan	 1	0:00	1:00	S
-Rule	Peru	1938	only	-	Apr	 1	0:00	0	-
-Rule	Peru	1938	1939	-	Sep	lastSun	0:00	1:00	S
-Rule	Peru	1939	1940	-	Mar	Sun>=24	0:00	0	-
-Rule	Peru	1986	1987	-	Jan	 1	0:00	1:00	S
-Rule	Peru	1986	1987	-	Apr	 1	0:00	0	-
-Rule	Peru	1990	only	-	Jan	 1	0:00	1:00	S
-Rule	Peru	1990	only	-	Apr	 1	0:00	0	-
-# IATA is ambiguous for 1993/1995; go with Shanks & Pottenger.
-Rule	Peru	1994	only	-	Jan	 1	0:00	1:00	S
-Rule	Peru	1994	only	-	Apr	 1	0:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Lima	-5:08:12 -	LMT	1890
-			-5:08:36 -	LMT	1908 Jul 28 # Lima Mean Time?
-			-5:00	Peru	PE%sT	# Peru Time
-
-# South Georgia
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Atlantic/South_Georgia -2:26:08 -	LMT	1890		# Grytviken
-			-2:00	-	GST	# South Georgia Time
-
-# South Sandwich Is
-# uninhabited; scientific personnel have wintered
-
-# Suriname
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Paramaribo	-3:40:40 -	LMT	1911
-			-3:40:52 -	PMT	1935     # Paramaribo Mean Time
-			-3:40:36 -	PMT	1945 Oct # The capital moved?
-			-3:30	-	NEGT	1975 Nov 20 # Dutch Guiana Time
-			-3:30	-	SRT	1984 Oct # Suriname Time
-			-3:00	-	SRT
-
-# Trinidad and Tobago
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Port_of_Spain -4:06:04 -	LMT	1912 Mar 2
-			-4:00	-	AST
-
-# Uruguay
-# From Paul Eggert (1993-11-18):
-# Uruguay wins the prize for the strangest peacetime manipulation of the rules.
-# From Shanks & Pottenger:
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-# Whitman gives 1923 Oct 1; go with Shanks & Pottenger.
-Rule	Uruguay	1923	only	-	Oct	 2	 0:00	0:30	HS
-Rule	Uruguay	1924	1926	-	Apr	 1	 0:00	0	-
-Rule	Uruguay	1924	1925	-	Oct	 1	 0:00	0:30	HS
-Rule	Uruguay	1933	1935	-	Oct	lastSun	 0:00	0:30	HS
-# Shanks & Pottenger give 1935 Apr 1 0:00 & 1936 Mar 30 0:00; go with Whitman.
-Rule	Uruguay	1934	1936	-	Mar	Sat>=25	23:30s	0	-
-Rule	Uruguay	1936	only	-	Nov	 1	 0:00	0:30	HS
-Rule	Uruguay	1937	1941	-	Mar	lastSun	 0:00	0	-
-# Whitman gives 1937 Oct 3; go with Shanks & Pottenger.
-Rule	Uruguay	1937	1940	-	Oct	lastSun	 0:00	0:30	HS
-# Whitman gives 1941 Oct 24 - 1942 Mar 27, 1942 Dec 14 - 1943 Apr 13,
-# and 1943 Apr 13 ``to present time''; go with Shanks & Pottenger.
-Rule	Uruguay	1941	only	-	Aug	 1	 0:00	0:30	HS
-Rule	Uruguay	1942	only	-	Jan	 1	 0:00	0	-
-Rule	Uruguay	1942	only	-	Dec	14	 0:00	1:00	S
-Rule	Uruguay	1943	only	-	Mar	14	 0:00	0	-
-Rule	Uruguay	1959	only	-	May	24	 0:00	1:00	S
-Rule	Uruguay	1959	only	-	Nov	15	 0:00	0	-
-Rule	Uruguay	1960	only	-	Jan	17	 0:00	1:00	S
-Rule	Uruguay	1960	only	-	Mar	 6	 0:00	0	-
-Rule	Uruguay	1965	1967	-	Apr	Sun>=1	 0:00	1:00	S
-Rule	Uruguay	1965	only	-	Sep	26	 0:00	0	-
-Rule	Uruguay	1966	1967	-	Oct	31	 0:00	0	-
-Rule	Uruguay	1968	1970	-	May	27	 0:00	0:30	HS
-Rule	Uruguay	1968	1970	-	Dec	 2	 0:00	0	-
-Rule	Uruguay	1972	only	-	Apr	24	 0:00	1:00	S
-Rule	Uruguay	1972	only	-	Aug	15	 0:00	0	-
-Rule	Uruguay	1974	only	-	Mar	10	 0:00	0:30	HS
-Rule	Uruguay	1974	only	-	Dec	22	 0:00	1:00	S
-Rule	Uruguay	1976	only	-	Oct	 1	 0:00	0	-
-Rule	Uruguay	1977	only	-	Dec	 4	 0:00	1:00	S
-Rule	Uruguay	1978	only	-	Apr	 1	 0:00	0	-
-Rule	Uruguay	1979	only	-	Oct	 1	 0:00	1:00	S
-Rule	Uruguay	1980	only	-	May	 1	 0:00	0	-
-Rule	Uruguay	1987	only	-	Dec	14	 0:00	1:00	S
-Rule	Uruguay	1988	only	-	Mar	14	 0:00	0	-
-Rule	Uruguay	1988	only	-	Dec	11	 0:00	1:00	S
-Rule	Uruguay	1989	only	-	Mar	12	 0:00	0	-
-Rule	Uruguay	1989	only	-	Oct	29	 0:00	1:00	S
-# Shanks & Pottenger say no DST was observed in 1990/1 and 1991/2,
-# and that 1992/3's DST was from 10-25 to 03-01.  Go with IATA.
-Rule	Uruguay	1990	1992	-	Mar	Sun>=1	 0:00	0	-
-Rule	Uruguay	1990	1991	-	Oct	Sun>=21	 0:00	1:00	S
-Rule	Uruguay	1992	only	-	Oct	18	 0:00	1:00	S
-Rule	Uruguay	1993	only	-	Feb	28	 0:00	0	-
-# From Eduardo Cota (2004-09-20):
-# The uruguayan government has decreed a change in the local time....
-# http://www.presidencia.gub.uy/decretos/2004091502.htm
-Rule	Uruguay	2004	only	-	Sep	19	 0:00	1:00	S
-# From Steffen Thorsen (2005-03-11):
-# Uruguay's DST was scheduled to end on Sunday, 2005-03-13, but in order to
-# save energy ... it was postponed two weeks....
-# http://www.presidencia.gub.uy/_Web/noticias/2005/03/2005031005.htm
-Rule	Uruguay	2005	only	-	Mar	27	 2:00	0	-
-# From Eduardo Cota (2005-09-27):
-# http://www.presidencia.gub.uy/_Web/decretos/2005/09/CM%20119_09%2009%202005_00001.PDF
-# This means that from 2005-10-09 at 02:00 local time, until 2006-03-12 at
-# 02:00 local time, official time in Uruguay will be at GMT -2.
-Rule	Uruguay	2005	only	-	Oct	 9	 2:00	1:00	S
-Rule	Uruguay	2006	only	-	Mar	12	 2:00	0	-
-# From Jesper Norgaard Welen (2006-09-06):
-# http://www.presidencia.gub.uy/_web/decretos/2006/09/CM%20210_08%2006%202006_00001.PDF
-Rule	Uruguay	2006	max	-	Oct	Sun>=1	 2:00	1:00	S
-Rule	Uruguay	2007	max	-	Mar	Sun>=8	 2:00	0	-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone America/Montevideo	-3:44:44 -	LMT	1898 Jun 28
-			-3:44:44 -	MMT	1920 May  1	# Montevideo MT
-			-3:30	Uruguay	UY%sT	1942 Dec 14	# Uruguay Time
-			-3:00	Uruguay	UY%sT
-
-# Venezuela
-#
-# From John Stainforth (2007-11-28):
-# ... the change for Venezuela originally expected for 2007-12-31 has
-# been brought forward to 2007-12-09.  The official announcement was
-# published today in the "Gaceta Oficial de la Republica Bolivariana
-# de Venezuela, numero 38.819" (official document for all laws or
-# resolution publication)
-# http://www.globovision.com/news.php?nid=72208
-
-# Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	America/Caracas	-4:27:44 -	LMT	1890
-			-4:27:40 -	CMT	1912 Feb 12 # Caracas Mean Time?
-			-4:30	-	VET	1965	     # Venezuela Time
-			-4:00	-	VET	2007 Dec  9 03:00
-			-4:30	-	VET
diff --git a/tools/zoneinfo/tzdata2008h/systemv b/tools/zoneinfo/tzdata2008h/systemv
deleted file mode 100644
index 6cf9645..0000000
--- a/tools/zoneinfo/tzdata2008h/systemv
+++ /dev/null
@@ -1,36 +0,0 @@
-# @(#)systemv	8.1
-
-# Old rules, should the need arise.
-# No attempt is made to handle Newfoundland, since it cannot be expressed
-# using the System V "TZ" scheme (half-hour offset), or anything outside
-# North America (no support for non-standard DST start/end dates), nor
-# the changes in the DST rules in the US after 1976 (which occurred after
-# the old rules were written).
-#
-# If you need the old rules, uncomment ## lines.
-# Compile this *without* leap second correction for true conformance.
-
-# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	SystemV	min	1973	-	Apr	lastSun	2:00	1:00	D
-Rule	SystemV	min	1973	-	Oct	lastSun	2:00	0	S
-Rule	SystemV	1974	only	-	Jan	6	2:00	1:00	D
-Rule	SystemV	1974	only	-	Nov	lastSun	2:00	0	S
-Rule	SystemV	1975	only	-	Feb	23	2:00	1:00	D
-Rule	SystemV	1975	only	-	Oct	lastSun	2:00	0	S
-Rule	SystemV	1976	max	-	Apr	lastSun	2:00	1:00	D
-Rule	SystemV	1976	max	-	Oct	lastSun	2:00	0	S
-
-# Zone	NAME		GMTOFF	RULES/SAVE	FORMAT	[UNTIL]
-## Zone	SystemV/AST4ADT	-4:00	SystemV		A%sT
-## Zone	SystemV/EST5EDT	-5:00	SystemV		E%sT
-## Zone	SystemV/CST6CDT	-6:00	SystemV		C%sT
-## Zone	SystemV/MST7MDT	-7:00	SystemV		M%sT
-## Zone	SystemV/PST8PDT	-8:00	SystemV		P%sT
-## Zone	SystemV/YST9YDT	-9:00	SystemV		Y%sT
-## Zone	SystemV/AST4	-4:00	-		AST
-## Zone	SystemV/EST5	-5:00	-		EST
-## Zone	SystemV/CST6	-6:00	-		CST
-## Zone	SystemV/MST7	-7:00	-		MST
-## Zone	SystemV/PST8	-8:00	-		PST
-## Zone	SystemV/YST9	-9:00	-		YST
-## Zone	SystemV/HST10	-10:00	-		HST
diff --git a/tools/zoneinfo/tzdata2008h/yearistype.sh b/tools/zoneinfo/tzdata2008h/yearistype.sh
deleted file mode 100644
index 66dbf89..0000000
--- a/tools/zoneinfo/tzdata2008h/yearistype.sh
+++ /dev/null
@@ -1,40 +0,0 @@
-#! /bin/sh
-
-: 'This file is in the public domain, so clarified as of'
-: '2006-07-17 by Arthur David Olson.'
-
-: '@(#)yearistype.sh	8.2'
-
-case $#-$1 in
-	2-|2-0*|2-*[!0-9]*)
-		echo "$0: wild year - $1" >&2
-		exit 1 ;;
-esac
-
-case $#-$2 in
-	2-even)
-		case $1 in
-			*[24680])			exit 0 ;;
-			*)				exit 1 ;;
-		esac ;;
-	2-nonpres|2-nonuspres)
-		case $1 in
-			*[02468][048]|*[13579][26])	exit 1 ;;
-			*)				exit 0 ;;
-		esac ;;
-	2-odd)
-		case $1 in
-			*[13579])			exit 0 ;;
-			*)				exit 1 ;;
-		esac ;;
-	2-uspres)
-		case $1 in
-			*[02468][048]|*[13579][26])	exit 0 ;;
-			*)				exit 1 ;;
-		esac ;;
-	2-*)
-		echo "$0: wild type - $2" >&2 ;;
-esac
-
-echo "$0: usage is $0 year even|odd|uspres|nonpres|nonuspres" >&2
-exit 1
diff --git a/tools/zoneinfo/tzdata2008h/zone.tab b/tools/zoneinfo/tzdata2008h/zone.tab
deleted file mode 100644
index ca9c76b..0000000
--- a/tools/zoneinfo/tzdata2008h/zone.tab
+++ /dev/null
@@ -1,424 +0,0 @@
-# @(#)zone.tab	8.19
-#
-# TZ zone descriptions
-#
-# From Paul Eggert (1996-08-05):
-#
-# This file contains a table with the following columns:
-# 1.  ISO 3166 2-character country code.  See the file `iso3166.tab'.
-# 2.  Latitude and longitude of the zone's principal location
-#     in ISO 6709 sign-degrees-minutes-seconds format,
-#     either +-DDMM+-DDDMM or +-DDMMSS+-DDDMMSS,
-#     first latitude (+ is north), then longitude (+ is east).
-# 3.  Zone name used in value of TZ environment variable.
-# 4.  Comments; present if and only if the country has multiple rows.
-#
-# Columns are separated by a single tab.
-# The table is sorted first by country, then an order within the country that
-# (1) makes some geographical sense, and
-# (2) puts the most populous zones first, where that does not contradict (1).
-#
-# Lines beginning with `#' are comments.
-#
-#country-
-#code	coordinates	TZ			comments
-AD	+4230+00131	Europe/Andorra
-AE	+2518+05518	Asia/Dubai
-AF	+3431+06912	Asia/Kabul
-AG	+1703-06148	America/Antigua
-AI	+1812-06304	America/Anguilla
-AL	+4120+01950	Europe/Tirane
-AM	+4011+04430	Asia/Yerevan
-AN	+1211-06900	America/Curacao
-AO	-0848+01314	Africa/Luanda
-AQ	-7750+16636	Antarctica/McMurdo	McMurdo Station, Ross Island
-AQ	-9000+00000	Antarctica/South_Pole	Amundsen-Scott Station, South Pole
-AQ	-6734-06808	Antarctica/Rothera	Rothera Station, Adelaide Island
-AQ	-6448-06406	Antarctica/Palmer	Palmer Station, Anvers Island
-AQ	-6736+06253	Antarctica/Mawson	Mawson Station, Holme Bay
-AQ	-6835+07758	Antarctica/Davis	Davis Station, Vestfold Hills
-AQ	-6617+11031	Antarctica/Casey	Casey Station, Bailey Peninsula
-AQ	-7824+10654	Antarctica/Vostok	Vostok Station, S Magnetic Pole
-AQ	-6640+14001	Antarctica/DumontDUrville	Dumont-d'Urville Station, Terre Adelie
-AQ	-690022+0393524	Antarctica/Syowa	Syowa Station, E Ongul I
-AR	-3436-05827	America/Argentina/Buenos_Aires	Buenos Aires (BA, CF)
-AR	-3124-06411	America/Argentina/Cordoba	most locations (CB, CC, CN, ER, FM, LP, MN, NQ, RN, SA, SE, SF)
-AR	-3319-06621	America/Argentina/San_Luis	San Luis (SL)
-AR	-2411-06518	America/Argentina/Jujuy	Jujuy (JY)
-AR	-2649-06513	America/Argentina/Tucuman	Tucuman (TM)
-AR	-2828-06547	America/Argentina/Catamarca	Catamarca (CT), Chubut (CH)
-AR	-2926-06651	America/Argentina/La_Rioja	La Rioja (LR)
-AR	-3132-06831	America/Argentina/San_Juan	San Juan (SJ)
-AR	-3253-06849	America/Argentina/Mendoza	Mendoza (MZ)
-AR	-5138-06913	America/Argentina/Rio_Gallegos	Santa Cruz (SC)
-AR	-5448-06818	America/Argentina/Ushuaia	Tierra del Fuego (TF)
-AS	-1416-17042	Pacific/Pago_Pago
-AT	+4813+01620	Europe/Vienna
-AU	-3133+15905	Australia/Lord_Howe	Lord Howe Island
-AU	-4253+14719	Australia/Hobart	Tasmania - most locations
-AU	-3956+14352	Australia/Currie	Tasmania - King Island
-AU	-3749+14458	Australia/Melbourne	Victoria
-AU	-3352+15113	Australia/Sydney	New South Wales - most locations
-AU	-3157+14127	Australia/Broken_Hill	New South Wales - Yancowinna
-AU	-2728+15302	Australia/Brisbane	Queensland - most locations
-AU	-2016+14900	Australia/Lindeman	Queensland - Holiday Islands
-AU	-3455+13835	Australia/Adelaide	South Australia
-AU	-1228+13050	Australia/Darwin	Northern Territory
-AU	-3157+11551	Australia/Perth	Western Australia - most locations
-AU	-3143+12852	Australia/Eucla	Western Australia - Eucla area
-AW	+1230-06958	America/Aruba
-AX	+6006+01957	Europe/Mariehamn
-AZ	+4023+04951	Asia/Baku
-BA	+4352+01825	Europe/Sarajevo
-BB	+1306-05937	America/Barbados
-BD	+2343+09025	Asia/Dhaka
-BE	+5050+00420	Europe/Brussels
-BF	+1222-00131	Africa/Ouagadougou
-BG	+4241+02319	Europe/Sofia
-BH	+2623+05035	Asia/Bahrain
-BI	-0323+02922	Africa/Bujumbura
-BJ	+0629+00237	Africa/Porto-Novo
-BL	+1753-06251	America/St_Barthelemy
-BM	+3217-06446	Atlantic/Bermuda
-BN	+0456+11455	Asia/Brunei
-BO	-1630-06809	America/La_Paz
-BR	-0351-03225	America/Noronha	Atlantic islands
-BR	-0127-04829	America/Belem	Amapa, E Para
-BR	-0343-03830	America/Fortaleza	NE Brazil (MA, PI, CE, RN, PB)
-BR	-0803-03454	America/Recife	Pernambuco
-BR	-0712-04812	America/Araguaina	Tocantins
-BR	-0940-03543	America/Maceio	Alagoas, Sergipe
-BR	-1259-03831	America/Bahia	Bahia
-BR	-2332-04637	America/Sao_Paulo	S & SE Brazil (GO, DF, MG, ES, RJ, SP, PR, SC, RS)
-BR	-2027-05437	America/Campo_Grande	Mato Grosso do Sul
-BR	-1535-05605	America/Cuiaba	Mato Grosso
-BR	-0226-05452	America/Santarem	W Para
-BR	-0846-06354	America/Porto_Velho	Rondonia
-BR	+0249-06040	America/Boa_Vista	Roraima
-BR	-0308-06001	America/Manaus	E Amazonas
-BR	-0640-06952	America/Eirunepe	W Amazonas
-BR	-0958-06748	America/Rio_Branco	Acre
-BS	+2505-07721	America/Nassau
-BT	+2728+08939	Asia/Thimphu
-BW	-2545+02555	Africa/Gaborone
-BY	+5354+02734	Europe/Minsk
-BZ	+1730-08812	America/Belize
-CA	+4734-05243	America/St_Johns	Newfoundland Time, including SE Labrador
-CA	+4439-06336	America/Halifax	Atlantic Time - Nova Scotia (most places), PEI
-CA	+4612-05957	America/Glace_Bay	Atlantic Time - Nova Scotia - places that did not observe DST 1966-1971
-CA	+4606-06447	America/Moncton	Atlantic Time - New Brunswick
-CA	+5320-06025	America/Goose_Bay	Atlantic Time - Labrador - most locations
-CA	+5125-05707	America/Blanc-Sablon	Atlantic Standard Time - Quebec - Lower North Shore
-CA	+4531-07334	America/Montreal	Eastern Time - Quebec - most locations
-CA	+4339-07923	America/Toronto	Eastern Time - Ontario - most locations
-CA	+4901-08816	America/Nipigon	Eastern Time - Ontario & Quebec - places that did not observe DST 1967-1973
-CA	+4823-08915	America/Thunder_Bay	Eastern Time - Thunder Bay, Ontario
-CA	+6344-06828	America/Iqaluit	Eastern Time - east Nunavut - most locations
-CA	+6608-06544	America/Pangnirtung	Eastern Time - Pangnirtung, Nunavut
-CA	+744144-0944945	America/Resolute	Eastern Time - Resolute, Nunavut
-CA	+484531-0913718	America/Atikokan	Eastern Standard Time - Atikokan, Ontario and Southampton I, Nunavut
-CA	+624900-0920459	America/Rankin_Inlet	Central Time - central Nunavut
-CA	+4953-09709	America/Winnipeg	Central Time - Manitoba & west Ontario
-CA	+4843-09434	America/Rainy_River	Central Time - Rainy River & Fort Frances, Ontario
-CA	+5024-10439	America/Regina	Central Standard Time - Saskatchewan - most locations
-CA	+5017-10750	America/Swift_Current	Central Standard Time - Saskatchewan - midwest
-CA	+5333-11328	America/Edmonton	Mountain Time - Alberta, east British Columbia & west Saskatchewan
-CA	+690650-1050310	America/Cambridge_Bay	Mountain Time - west Nunavut
-CA	+6227-11421	America/Yellowknife	Mountain Time - central Northwest Territories
-CA	+682059-1334300	America/Inuvik	Mountain Time - west Northwest Territories
-CA	+5946-12014	America/Dawson_Creek	Mountain Standard Time - Dawson Creek & Fort Saint John, British Columbia
-CA	+4916-12307	America/Vancouver	Pacific Time - west British Columbia
-CA	+6043-13503	America/Whitehorse	Pacific Time - south Yukon
-CA	+6404-13925	America/Dawson	Pacific Time - north Yukon
-CC	-1210+09655	Indian/Cocos
-CD	-0418+01518	Africa/Kinshasa	west Dem. Rep. of Congo
-CD	-1140+02728	Africa/Lubumbashi	east Dem. Rep. of Congo
-CF	+0422+01835	Africa/Bangui
-CG	-0416+01517	Africa/Brazzaville
-CH	+4723+00832	Europe/Zurich
-CI	+0519-00402	Africa/Abidjan
-CK	-2114-15946	Pacific/Rarotonga
-CL	-3327-07040	America/Santiago	most locations
-CL	-2709-10926	Pacific/Easter	Easter Island & Sala y Gomez
-CM	+0403+00942	Africa/Douala
-CN	+3114+12128	Asia/Shanghai	east China - Beijing, Guangdong, Shanghai, etc.
-CN	+4545+12641	Asia/Harbin	Heilongjiang (except Mohe), Jilin
-CN	+2934+10635	Asia/Chongqing	central China - Sichuan, Yunnan, Guangxi, Shaanxi, Guizhou, etc.
-CN	+4348+08735	Asia/Urumqi	most of Tibet & Xinjiang
-CN	+3929+07559	Asia/Kashgar	west Tibet & Xinjiang
-CO	+0436-07405	America/Bogota
-CR	+0956-08405	America/Costa_Rica
-CU	+2308-08222	America/Havana
-CV	+1455-02331	Atlantic/Cape_Verde
-CX	-1025+10543	Indian/Christmas
-CY	+3510+03322	Asia/Nicosia
-CZ	+5005+01426	Europe/Prague
-DE	+5230+01322	Europe/Berlin
-DJ	+1136+04309	Africa/Djibouti
-DK	+5540+01235	Europe/Copenhagen
-DM	+1518-06124	America/Dominica
-DO	+1828-06954	America/Santo_Domingo
-DZ	+3647+00303	Africa/Algiers
-EC	-0210-07950	America/Guayaquil	mainland
-EC	-0054-08936	Pacific/Galapagos	Galapagos Islands
-EE	+5925+02445	Europe/Tallinn
-EG	+3003+03115	Africa/Cairo
-EH	+2709-01312	Africa/El_Aaiun
-ER	+1520+03853	Africa/Asmara
-ES	+4024-00341	Europe/Madrid	mainland
-ES	+3553-00519	Africa/Ceuta	Ceuta & Melilla
-ES	+2806-01524	Atlantic/Canary	Canary Islands
-ET	+0902+03842	Africa/Addis_Ababa
-FI	+6010+02458	Europe/Helsinki
-FJ	-1808+17825	Pacific/Fiji
-FK	-5142-05751	Atlantic/Stanley
-FM	+0725+15147	Pacific/Truk	Truk (Chuuk) and Yap
-FM	+0658+15813	Pacific/Ponape	Ponape (Pohnpei)
-FM	+0519+16259	Pacific/Kosrae	Kosrae
-FO	+6201-00646	Atlantic/Faroe
-FR	+4852+00220	Europe/Paris
-GA	+0023+00927	Africa/Libreville
-GB	+513030-0000731	Europe/London
-GD	+1203-06145	America/Grenada
-GE	+4143+04449	Asia/Tbilisi
-GF	+0456-05220	America/Cayenne
-GG	+4927-00232	Europe/Guernsey
-GH	+0533-00013	Africa/Accra
-GI	+3608-00521	Europe/Gibraltar
-GL	+6411-05144	America/Godthab	most locations
-GL	+7646-01840	America/Danmarkshavn	east coast, north of Scoresbysund
-GL	+7029-02158	America/Scoresbysund	Scoresbysund / Ittoqqortoormiit
-GL	+7634-06847	America/Thule	Thule / Pituffik
-GM	+1328-01639	Africa/Banjul
-GN	+0931-01343	Africa/Conakry
-GP	+1614-06132	America/Guadeloupe
-GQ	+0345+00847	Africa/Malabo
-GR	+3758+02343	Europe/Athens
-GS	-5416-03632	Atlantic/South_Georgia
-GT	+1438-09031	America/Guatemala
-GU	+1328+14445	Pacific/Guam
-GW	+1151-01535	Africa/Bissau
-GY	+0648-05810	America/Guyana
-HK	+2217+11409	Asia/Hong_Kong
-HN	+1406-08713	America/Tegucigalpa
-HR	+4548+01558	Europe/Zagreb
-HT	+1832-07220	America/Port-au-Prince
-HU	+4730+01905	Europe/Budapest
-ID	-0610+10648	Asia/Jakarta	Java & Sumatra
-ID	-0002+10920	Asia/Pontianak	west & central Borneo
-ID	-0507+11924	Asia/Makassar	east & south Borneo, Celebes, Bali, Nusa Tengarra, west Timor
-ID	-0232+14042	Asia/Jayapura	Irian Jaya & the Moluccas
-IE	+5320-00615	Europe/Dublin
-IL	+3146+03514	Asia/Jerusalem
-IM	+5409-00428	Europe/Isle_of_Man
-IN	+2232+08822	Asia/Kolkata
-IO	-0720+07225	Indian/Chagos
-IQ	+3321+04425	Asia/Baghdad
-IR	+3540+05126	Asia/Tehran
-IS	+6409-02151	Atlantic/Reykjavik
-IT	+4154+01229	Europe/Rome
-JE	+4912-00207	Europe/Jersey
-JM	+1800-07648	America/Jamaica
-JO	+3157+03556	Asia/Amman
-JP	+353916+1394441	Asia/Tokyo
-KE	-0117+03649	Africa/Nairobi
-KG	+4254+07436	Asia/Bishkek
-KH	+1133+10455	Asia/Phnom_Penh
-KI	+0125+17300	Pacific/Tarawa	Gilbert Islands
-KI	-0308-17105	Pacific/Enderbury	Phoenix Islands
-KI	+0152-15720	Pacific/Kiritimati	Line Islands
-KM	-1141+04316	Indian/Comoro
-KN	+1718-06243	America/St_Kitts
-KP	+3901+12545	Asia/Pyongyang
-KR	+3733+12658	Asia/Seoul
-KW	+2920+04759	Asia/Kuwait
-KY	+1918-08123	America/Cayman
-KZ	+4315+07657	Asia/Almaty	most locations
-KZ	+4448+06528	Asia/Qyzylorda	Qyzylorda (Kyzylorda, Kzyl-Orda)
-KZ	+5017+05710	Asia/Aqtobe	Aqtobe (Aktobe)
-KZ	+4431+05016	Asia/Aqtau	Atyrau (Atirau, Gur'yev), Mangghystau (Mankistau)
-KZ	+5113+05121	Asia/Oral	West Kazakhstan
-LA	+1758+10236	Asia/Vientiane
-LB	+3353+03530	Asia/Beirut
-LC	+1401-06100	America/St_Lucia
-LI	+4709+00931	Europe/Vaduz
-LK	+0656+07951	Asia/Colombo
-LR	+0618-01047	Africa/Monrovia
-LS	-2928+02730	Africa/Maseru
-LT	+5441+02519	Europe/Vilnius
-LU	+4936+00609	Europe/Luxembourg
-LV	+5657+02406	Europe/Riga
-LY	+3254+01311	Africa/Tripoli
-MA	+3339-00735	Africa/Casablanca
-MC	+4342+00723	Europe/Monaco
-MD	+4700+02850	Europe/Chisinau
-ME	+4226+01916	Europe/Podgorica
-MF	+1804-06305	America/Marigot
-MG	-1855+04731	Indian/Antananarivo
-MH	+0709+17112	Pacific/Majuro	most locations
-MH	+0905+16720	Pacific/Kwajalein	Kwajalein
-MK	+4159+02126	Europe/Skopje
-ML	+1239-00800	Africa/Bamako
-MM	+1647+09610	Asia/Rangoon
-MN	+4755+10653	Asia/Ulaanbaatar	most locations
-MN	+4801+09139	Asia/Hovd	Bayan-Olgiy, Govi-Altai, Hovd, Uvs, Zavkhan
-MN	+4804+11430	Asia/Choibalsan	Dornod, Sukhbaatar
-MO	+2214+11335	Asia/Macau
-MP	+1512+14545	Pacific/Saipan
-MQ	+1436-06105	America/Martinique
-MR	+1806-01557	Africa/Nouakchott
-MS	+1643-06213	America/Montserrat
-MT	+3554+01431	Europe/Malta
-MU	-2010+05730	Indian/Mauritius
-MV	+0410+07330	Indian/Maldives
-MW	-1547+03500	Africa/Blantyre
-MX	+1924-09909	America/Mexico_City	Central Time - most locations
-MX	+2105-08646	America/Cancun	Central Time - Quintana Roo
-MX	+2058-08937	America/Merida	Central Time - Campeche, Yucatan
-MX	+2540-10019	America/Monterrey	Central Time - Coahuila, Durango, Nuevo Leon, Tamaulipas
-MX	+2313-10625	America/Mazatlan	Mountain Time - S Baja, Nayarit, Sinaloa
-MX	+2838-10605	America/Chihuahua	Mountain Time - Chihuahua
-MX	+2904-11058	America/Hermosillo	Mountain Standard Time - Sonora
-MX	+3232-11701	America/Tijuana	Pacific Time
-MY	+0310+10142	Asia/Kuala_Lumpur	peninsular Malaysia
-MY	+0133+11020	Asia/Kuching	Sabah & Sarawak
-MZ	-2558+03235	Africa/Maputo
-NA	-2234+01706	Africa/Windhoek
-NC	-2216+16530	Pacific/Noumea
-NE	+1331+00207	Africa/Niamey
-NF	-2903+16758	Pacific/Norfolk
-NG	+0627+00324	Africa/Lagos
-NI	+1209-08617	America/Managua
-NL	+5222+00454	Europe/Amsterdam
-NO	+5955+01045	Europe/Oslo
-NP	+2743+08519	Asia/Katmandu
-NR	-0031+16655	Pacific/Nauru
-NU	-1901-16955	Pacific/Niue
-NZ	-3652+17446	Pacific/Auckland	most locations
-NZ	-4357-17633	Pacific/Chatham	Chatham Islands
-OM	+2336+05835	Asia/Muscat
-PA	+0858-07932	America/Panama
-PE	-1203-07703	America/Lima
-PF	-1732-14934	Pacific/Tahiti	Society Islands
-PF	-0900-13930	Pacific/Marquesas	Marquesas Islands
-PF	-2308-13457	Pacific/Gambier	Gambier Islands
-PG	-0930+14710	Pacific/Port_Moresby
-PH	+1435+12100	Asia/Manila
-PK	+2452+06703	Asia/Karachi
-PL	+5215+02100	Europe/Warsaw
-PM	+4703-05620	America/Miquelon
-PN	-2504-13005	Pacific/Pitcairn
-PR	+182806-0660622	America/Puerto_Rico
-PS	+3130+03428	Asia/Gaza
-PT	+3843-00908	Europe/Lisbon	mainland
-PT	+3238-01654	Atlantic/Madeira	Madeira Islands
-PT	+3744-02540	Atlantic/Azores	Azores
-PW	+0720+13429	Pacific/Palau
-PY	-2516-05740	America/Asuncion
-QA	+2517+05132	Asia/Qatar
-RE	-2052+05528	Indian/Reunion
-RO	+4426+02606	Europe/Bucharest
-RS	+4450+02030	Europe/Belgrade
-RU	+5443+02030	Europe/Kaliningrad	Moscow-01 - Kaliningrad
-RU	+5545+03735	Europe/Moscow	Moscow+00 - west Russia
-RU	+4844+04425	Europe/Volgograd	Moscow+00 - Caspian Sea
-RU	+5312+05009	Europe/Samara	Moscow+01 - Samara, Udmurtia
-RU	+5651+06036	Asia/Yekaterinburg	Moscow+02 - Urals
-RU	+5500+07324	Asia/Omsk	Moscow+03 - west Siberia
-RU	+5502+08255	Asia/Novosibirsk	Moscow+03 - Novosibirsk
-RU	+5601+09250	Asia/Krasnoyarsk	Moscow+04 - Yenisei River
-RU	+5216+10420	Asia/Irkutsk	Moscow+05 - Lake Baikal
-RU	+6200+12940	Asia/Yakutsk	Moscow+06 - Lena River
-RU	+4310+13156	Asia/Vladivostok	Moscow+07 - Amur River
-RU	+4658+14242	Asia/Sakhalin	Moscow+07 - Sakhalin Island
-RU	+5934+15048	Asia/Magadan	Moscow+08 - Magadan
-RU	+5301+15839	Asia/Kamchatka	Moscow+09 - Kamchatka
-RU	+6445+17729	Asia/Anadyr	Moscow+10 - Bering Sea
-RW	-0157+03004	Africa/Kigali
-SA	+2438+04643	Asia/Riyadh
-SB	-0932+16012	Pacific/Guadalcanal
-SC	-0440+05528	Indian/Mahe
-SD	+1536+03232	Africa/Khartoum
-SE	+5920+01803	Europe/Stockholm
-SG	+0117+10351	Asia/Singapore
-SH	-1555-00542	Atlantic/St_Helena
-SI	+4603+01431	Europe/Ljubljana
-SJ	+7800+01600	Arctic/Longyearbyen
-SK	+4809+01707	Europe/Bratislava
-SL	+0830-01315	Africa/Freetown
-SM	+4355+01228	Europe/San_Marino
-SN	+1440-01726	Africa/Dakar
-SO	+0204+04522	Africa/Mogadishu
-SR	+0550-05510	America/Paramaribo
-ST	+0020+00644	Africa/Sao_Tome
-SV	+1342-08912	America/El_Salvador
-SY	+3330+03618	Asia/Damascus
-SZ	-2618+03106	Africa/Mbabane
-TC	+2128-07108	America/Grand_Turk
-TD	+1207+01503	Africa/Ndjamena
-TF	-492110+0701303	Indian/Kerguelen
-TG	+0608+00113	Africa/Lome
-TH	+1345+10031	Asia/Bangkok
-TJ	+3835+06848	Asia/Dushanbe
-TK	-0922-17114	Pacific/Fakaofo
-TL	-0833+12535	Asia/Dili
-TM	+3757+05823	Asia/Ashgabat
-TN	+3648+01011	Africa/Tunis
-TO	-2110+17510	Pacific/Tongatapu
-TR	+4101+02858	Europe/Istanbul
-TT	+1039-06131	America/Port_of_Spain
-TV	-0831+17913	Pacific/Funafuti
-TW	+2503+12130	Asia/Taipei
-TZ	-0648+03917	Africa/Dar_es_Salaam
-UA	+5026+03031	Europe/Kiev	most locations
-UA	+4837+02218	Europe/Uzhgorod	Ruthenia
-UA	+4750+03510	Europe/Zaporozhye	Zaporozh'ye, E Lugansk / Zaporizhia, E Luhansk
-UA	+4457+03406	Europe/Simferopol	central Crimea
-UG	+0019+03225	Africa/Kampala
-UM	+1645-16931	Pacific/Johnston	Johnston Atoll
-UM	+2813-17722	Pacific/Midway	Midway Islands
-UM	+1917+16637	Pacific/Wake	Wake Island
-US	+404251-0740023	America/New_York	Eastern Time
-US	+421953-0830245	America/Detroit	Eastern Time - Michigan - most locations
-US	+381515-0854534	America/Kentucky/Louisville	Eastern Time - Kentucky - Louisville area
-US	+364947-0845057	America/Kentucky/Monticello	Eastern Time - Kentucky - Wayne County
-US	+394606-0860929	America/Indiana/Indianapolis	Eastern Time - Indiana - most locations
-US	+384038-0873143	America/Indiana/Vincennes	Eastern Time - Indiana - Daviess, Dubois, Knox & Martin Counties
-US	+411745-0863730	America/Indiana/Knox	Eastern Time - Indiana - Starke County
-US	+410305-0863611	America/Indiana/Winamac	Eastern Time - Indiana - Pulaski County
-US	+382232-0862041	America/Indiana/Marengo	Eastern Time - Indiana - Crawford County
-US	+384452-0850402	America/Indiana/Vevay	Eastern Time - Indiana - Switzerland County
-US	+415100-0873900	America/Chicago	Central Time
-US	+375711-0864541	America/Indiana/Tell_City	Central Time - Indiana - Perry County
-US	+382931-0871643	America/Indiana/Petersburg	Central Time - Indiana - Pike County
-US	+450628-0873651	America/Menominee	Central Time - Michigan - Dickinson, Gogebic, Iron & Menominee Counties
-US	+470659-1011757	America/North_Dakota/Center	Central Time - North Dakota - Oliver County
-US	+465042-1012439	America/North_Dakota/New_Salem	Central Time - North Dakota - Morton County (except Mandan area)
-US	+394421-1045903	America/Denver	Mountain Time
-US	+433649-1161209	America/Boise	Mountain Time - south Idaho & east Oregon
-US	+364708-1084111	America/Shiprock	Mountain Time - Navajo
-US	+332654-1120424	America/Phoenix	Mountain Standard Time - Arizona
-US	+340308-1181434	America/Los_Angeles	Pacific Time
-US	+611305-1495401	America/Anchorage	Alaska Time
-US	+581807-1342511	America/Juneau	Alaska Time - Alaska panhandle
-US	+593249-1394338	America/Yakutat	Alaska Time - Alaska panhandle neck
-US	+643004-1652423	America/Nome	Alaska Time - west Alaska
-US	+515248-1763929	America/Adak	Aleutian Islands
-US	+211825-1575130	Pacific/Honolulu	Hawaii
-UY	-3453-05611	America/Montevideo
-UZ	+3940+06648	Asia/Samarkand	west Uzbekistan
-UZ	+4120+06918	Asia/Tashkent	east Uzbekistan
-VA	+4154+01227	Europe/Vatican
-VC	+1309-06114	America/St_Vincent
-VE	+1030-06656	America/Caracas
-VG	+1827-06437	America/Tortola
-VI	+1821-06456	America/St_Thomas
-VN	+1045+10640	Asia/Ho_Chi_Minh
-VU	-1740+16825	Pacific/Efate
-WF	-1318-17610	Pacific/Wallis
-WS	-1350-17144	Pacific/Apia
-YE	+1245+04512	Asia/Aden
-YT	-1247+04514	Indian/Mayotte
-ZA	-2615+02800	Africa/Johannesburg
-ZM	-1525+02817	Africa/Lusaka
-ZW	-1750+03103	Africa/Harare